static function sendEmail(&$msgobj, &$config, $to_email, $msg_type, &$messg_model = null) { //$messg_model =& $this->getModel('Message'); JTable::addIncludePath(JPATH_COMPONENT_ADMINISTRATOR . DS . 'tables'); $msg_id = $messg_model->getMsgID($msg_type); $msg = $messg_model->getMsg($msg_id); $from = $config->reply_to; $fromname = $config->organisation; $subject = str_replace('[jobtitle]', $msgobj->title, $msg->subject); $subject = str_replace('[jobid]', $msgobj->job_id, $subject); $subject = str_replace('[toname]', $msgobj->first_name, $subject); $subject = str_replace('[tosurname]', $msgobj->last_name, $subject); $subject = str_replace('[fromname]', $fromname, $subject); $body = str_replace('[jobid]', $msgobj->job_id, $msg->body); $body = str_replace('[jobtitle]', $msgobj->title, $body); $body = str_replace('[toname]', $msgobj->first_name, $body); $body = str_replace('[tosurname]', $msgobj->last_name, $body); $body = str_replace('[fromname]', $fromname, $body); if ($msg_type == 'adminupdate_application') { $status_tbl =& JTable::getInstance('Status', 'Table'); $status_tbl->load($msgobj->status); $user =& JFactory::getUser(); $body = str_replace('[appladmin]', $user->name, $body); $body = str_replace('[department]', $msgobj->dept_name, $body); $body = str_replace('[applstatus]', $status_tbl->status_description, $body); } return JobBoardHelper::dispatchEmail($from, $fromname, $to_email, $subject, $body); }
function display($tpl = null) { $app = JFactory::getApplication(); $document =& JFactory::getDocument(); $this->_addScripts(); if ($this->published) { jimport('joomla.utilities.date'); //$this->config = & $this->get('ShareConfig', 'Config'); $this->assign('setstate', JobBoardHelper::renderJobBoard()); if ($this->config->use_location) { $job_location = $this->data->country_name != 'COM_JOBBOARD_DB_ANYWHERE_CNAME' ? ', ' . $this->data->city : ', ' . JText::_('WORK_FROM_ANYWHERE'); } else { $job_location = ''; } $ref_num = $this->data->ref_num != '' ? ' (' . JText::_('COM_JOBBOARD_ENT_REF') . ': ' . $this->data->ref_num . ')' : ''; $document->setTitle(JText::_('EMAIL_JOB') . ': ' . $this->data->job_title . $job_location . $ref_num); } else { $document->setTitle(JText::_('COM_JOBBOARD_JOB_DISABLED')); } $this->itemid = JRequest::getInt('Itemid'); $this->user_entry_point = 'com_users'; if (version_compare(JVERSION, '2.5.0', 'ge') || version_compare(JVERSION, '1.7.0', 'ge') || version_compare(JVERSION, '1.6.0', 'ge')) { $this->user_entry_point = 'com_users'; } elseif (version_compare(JVERSION, '1.5.0', 'ge')) { $this->user_entry_point = 'com_user'; } $retries = $app->getUserState('com_jobboard.member.retry', 0, 'int'); $this->retries = $retries; parent::display($tpl); }
function display($tpl = null) { $app = JFactory::getApplication(); $rows =& $this->get('data'); $pagination =& $this->get('pagination'); $this->search =& $this->get('search'); $this->search = !empty($this->search) ? $this->escape($this->search) : $this->search; $this->assignRef('rows', $rows); $this->assignRef('pagination', $pagination); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $lists['order'] = $app->getUserStateFromRequest('com_jobboard.applicants.filterOrder', 'filter_order', 'request_date'); $lists['orderDirection'] = $app->getUserStateFromRequest('com_jobboard.applicants.filterOrderDirection', 'filter_order_Dir', 'ASC', 'cmd'); $lists['orderDirection'] = strtoupper($lists['orderDirection']) == 'ASC' ? 'ASC' : 'DESC'; $this->assignRef('lists', $lists); $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->long_day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%a' : 'D'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; jimport('joomla.environment.browser'); $document =& JFactory::getDocument(); $browser =& JBrowser::getInstance(); if (is_int(strpos($browser->getBrowser(), 'msie'))) { if (intval($browser->getVersion()) > 7) { $cleafix = ".clearfix {display: block;}"; $document->addStyleDeclaration($cleafix); } } $_format = JRequest::getString('tmpl', ''); $this->is_modal = $_format == 'component' ? true : false; if (!$this->is_modal) { require_once JPATH_COMPONENT_ADMINISTRATOR . DS . 'helpers' . DS . 'jobboard_behavior.php'; } parent::display($tpl); }
function display($tpl = null) { $rows =& $this->get('data'); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $this->assignRef('rows', $rows); parent::display($tpl); }
function display($tpl = null) { $app =& JFactory::getApplication(); $today =& JFactory::getDate(); $uri =& JURI::getInstance(); $this->uri = $uri->getScheme() . '://' . $uri->getHost() . $uri->getPath(); $itemid = JRequest::getInt('Itemid'); $this->step = isset($this->step) ? $this->step : 0; $this->assignRef('today', $today); if ($this->step != 1 && $this->step > 0) { $this->assignRef('av_date', $today); } $_format = JRequest::getString('tmpl', ''); $this->is_modal = $_format == 'component' ? true : false; $this->_addScripts($this->step, $this->is_modal); $user =& JFactory::getUser(); $this->assignRef('user', $user); $this->setstate = JobBoardHelper::renderJobBoard(); $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; $this->user_entry_point = 'com_users'; if (version_compare(JVERSION, '1.6.0', 'ge')) { $this->user_entry_point = 'com_users'; } elseif (version_compare(JVERSION, '1.5.0', 'ge')) { $this->user_entry_point = 'com_user'; } parent::display($tpl); }
function display($tpl = null) { $document =& JFactory::getDocument(); $app = JFactory::getApplication(); $this->config =& $this->get('JobConfig', 'Config'); if ($this->published) { jimport('joomla.utilities.date'); require_once JPATH_COMPONENT_ADMINISTRATOR . DS . 'helpers' . DS . 'jobboard_job.php'; $this->assign('post_date', JobBoardJobHelper::formatDate($this->data->post_date)); $this->assign('setstate', JobBoardHelper::renderJobBoard()); $extra_keywords = strlen($this->data->job_tags) > 1 ? ', ' . $this->data->job_tags : ''; if ($this->config->use_location) { $job_location = $this->data->country_name != 'COM_JOBBOARD_DB_ANYWHERE_CNAME' ? ', ' . $this->data->city : ', ' . JText::_('WORK_FROM_ANYWHERE'); } else { $job_location = ''; } $ref_num = $this->data->ref_num != '' ? ' (' . JText::_('COM_JOBBOARD_ENT_REF') . ': ' . $this->data->ref_num . ')' : ''; $params =& JComponentHelper::getParams('com_jobboard'); $title_string = $this->data->job_title . $job_location . $ref_num; $menus =& JSite::getMenu(); $menu = $menus->getActive(); $uri =& JURI::getInstance(); $this->uri = $uri->getScheme() . '://' . $uri->getHost() . $uri->getPath(); if (is_object($menu) && isset($menu->query['view']) && $menu->query['view'] == 'job' && isset($menu->query['id']) && $menu->query['id'] == $item->id) { $menu_params = new JParameter($menu->params); if (!$menu_params->get('page_title')) { $params->set('page_title', $title_string); } } else { $params->set('page_title', $title_string); } $document->setTitle($params->get('page_title')); } else { $document->setTitle(JText::_('COM_JOBBOARD_JOB_DISABLED')); } $this->rformat = JRequest::getVar('format', ''); $this->user_entry_point = 'com_users'; $retries = $app->getUserState('com_jobboard.member.retry', 0, 'int'); $this->retries = $retries; if (version_compare(JVERSION, '2.5.0', 'ge') || version_compare(JVERSION, '1.7.0', 'ge') || version_compare(JVERSION, '1.6.0', 'ge')) { $this->user_entry_point = 'com_users'; } elseif (version_compare(JVERSION, '1.5.0', 'ge')) { $this->user_entry_point = 'com_user'; } $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->long_day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%a' : 'D'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; $_format = JRequest::getString('tmpl', ''); $this->is_modal = $_format == 'component' ? true : false; $this->itemid = JRequest::getInt('Itemid'); $this->_addScripts($this->is_modal); parent::display($tpl); }
function display($tpl = null) { if (version_compare(JVERSION, '1.7.0', 'ge')) { // Options button. if (JFactory::getUser()->authorise('core.admin', 'com_jobboard')) { JToolBarHelper::preferences('com_jobboard'); } } $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); parent::display($tpl); }
function display($tpl = null) { $task = JRequest::getVar('task', ''); $row =& JTable::getInstance('Education', 'Table'); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $cid = JRequest::getVar('cid', array(0), '', 'array'); $id = intval($cid[0]); $row->load($id); $this->assignRef('row', $row); parent::display($tpl); }
function display($tpl = null) { $cid = JRequest::getVar('cid', false, 'DEFAULT', 'array'); if ($cid) { $id = $cid[0]; } else { $id = JRequest::getInt('id', 0); } $newjob = $id > 0 ? false : true; if ($newjob) { $cfigt = JTable::getInstance('Config', 'Table'); $cfigt->load(1); $this->assignRef('config', $cfigt); } $lang =& JFactory::getLanguage()->getTag(); $lang = explode('-', $lang); $document =& JFactory::getDocument(); $_format = JRequest::getVar('format', ''); jimport('joomla.environment.browser'); $browser =& JBrowser::getInstance(); if (is_int(strpos($browser->getBrowser(), 'msie'))) { if (intval($browser->getVersion()) > 7) { $cleafix = ".clearfix {display: block;}"; $document->addStyleDeclaration($cleafix); } } if ($this->config->use_location == 1) { if (empty($_format)) { $this->maps_online = JobBoardHelper::getSite('maps.google.com'); JHTML::_('behavior.mootools'); if ($this->maps_online) { $document->addScript('http://maps.google.com/maps/api/js?v=3&sensor=false&language=' . $lang[0]); } $js_vars = 'var tandolin = tandolin || {}; var mapSlide, windowScroll, jobMap, mapInstrctns; var presentCoords = "' . JText::_('COM_JOBBOARD_TXT_PRESENT_COORDINATES') . '";'; $js_vars .= 'var mapDiv, focusOn, infoSpans, vMapTrigger, mapOpen, jobForm; '; $js_vars .= "window.addEvent('domready', function(){\n jobForm = document.forms['adminForm'];\n infoSpans = document.getElementById('calc_loc').getElements('span');\n });\n "; $document->addScriptDeclaration($js_vars); } } $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $this->assign('newjob', $newjob); $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->long_day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%a' : 'D'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; $_format = JRequest::getString('tmpl', ''); $this->is_modal = $_format == 'component' ? true : false; if (!$this->is_modal) { require_once JPATH_COMPONENT_ADMINISTRATOR . DS . 'helpers' . DS . 'jobboard_behavior.php'; } parent::display($tpl); }
function setLocationVars() { $lang =& JFactory::getLanguage()->getTag(); $lang = explode('-', $lang); $document =& JFactory::getDocument(); $this->maps_online = JobBoardHelper::getSite('maps.google.com'); if ($this->maps_online) { $document->addScript('http://maps.google.com/maps/api/js?v=3&sensor=false&language=' . $lang[0]); } $js_vars = 'var mapSlide, windowScroll, jobMap, mapInstrctns; var presentCoords = "' . JText::_('COM_JOBBOARD_TXT_PRESENT_COORDINATES') . '";'; $js_vars .= 'var mapDiv, focusOn, infoSpans, vMapTrigger, mapOpen; '; $js_vars .= "window.addEvent('domready', function(){\n infoSpans = document.getElementById('calc_loc').getElements('span');\n });\n "; $document->addScriptDeclaration($js_vars); }
function display($tpl = null) { $app = JFactory::getApplication(); $rows =& $this->get('data'); $this->assignRef('rows', $rows); $pagination =& $this->get('pagination'); $this->assignRef('pagination', $pagination); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $lists['order'] = $app->getUserStateFromRequest('com_jobboard.education.filterOrder', 'filter_order', 'level'); $lists['orderDirection'] = $app->getUserStateFromRequest('com_jobboard.education.filterOrderDirection', 'filter_order_Dir', 'DESC', 'cmd'); $lists['orderDirection'] = strtoupper($lists['orderDirection']) == 'ASC' ? 'ASC' : 'DESC'; $this->assignRef('lists', $lists); parent::display($tpl); }
function display($tpl = null) { $task = JRequest::getVar('task', ''); $row =& JTable::getInstance('Category', 'Table'); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $cid = JRequest::getVar('cid', array(0), '', 'array'); $id = $cid[0]; $row->load($id); $this->assignRef('row', $row); $this->assignRef('id', $id); $this->assignRef('type', $type); $this->assignRef('enabled', $enabled); parent::display($tpl); }
function display($tpl = null) { $task = JRequest::getVar('task', ''); $row =& $this->get('data'); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $this->assignRef('config', JRequest::getVar('config', '')); $this->assignRef('row', $row); $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->long_day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%a' : 'D'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; parent::display($tpl); }
function display($tpl = null) { $task = JRequest::getVar('task', ''); $row =& JTable::getInstance('Messages', 'Table'); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $cid = JRequest::getVar('cid', array(0), '', 'array'); $id = $cid[0]; $row->load($id); $this->assignRef('row', $row); $this->assignRef('id', $id); $this->assignRef('type', $lang_id); $this->assignRef('subject', $variable); $this->assignRef('body', $langtext); parent::display($tpl); }
function display($tpl = null) { $app = JFactory::getApplication(); $rows =& $this->get('data'); $this->search =& $this->get('search'); $this->search = !empty($this->search) ? $this->escape($this->search) : $this->search; $pagination =& $this->get('pagination'); $this->assignRef('rows', $rows); $this->assignRef('pagination', $pagination); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $lists['order'] = $app->getUserStateFromRequest('com_jobboard.departments.filterOrder', 'filter_order', 'name', 'word'); $lists['orderDirection'] = $app->getUserStateFromRequest('com_jobboard.departments.filterOrderDirection', 'filter_order_Dir', 'ASC', 'cmd'); $lists['orderDirection'] = strtoupper($lists['orderDirection']) == 'ASC' ? 'ASC' : 'DESC'; $this->assignRef('lists', $lists); parent::display($tpl); }
function display($tpl = null) { jimport('joomla.utilities.date'); $app = JFactory::getApplication(); $this->data =& $this->get('Data'); $featured_count = $this->countFeatured(&$this->data); $locsrch = $this->escape($this->locsrch); if ($featured_count > 0 && $locsrch != '') { $this->data = $this->sortFeatured(&$this->data); } $this->config =& $this->get('Querycfg', 'Config'); $this->jobsearch =& $this->get('Search'); $this->jobtypes =& $this->get('JobTypes'); $this->jobcareerlvls =& $this->get('Careerlvls'); $this->jobedlvls =& $this->get('Edlvls'); if ($this->config->use_location == true) { $this->radii =& $this->get('Distances'); $this->dist_symbol = $this->config->distance_unit == 0 ? JText::_('COM_JOBBOARD_DIST_METRIC') : JText::_('COM_JOBBOARD_DIST_IMPERIAL'); $this->sel_distance = $app->getUserStateFromRequest("com_jobboard.sel_distance", 'sel_distance', $this->config->default_distance, 'int'); $geo_address = $app->getUserState('com_jobboard.geo_address'); $this->assign('geo_address', $geo_address); } $this->featured_count = $featured_count; $this->filter_job_type = $app->getUserStateFromRequest("com_jobboard.filter_job_type", 'filter_job_type', array(), 'array'); $this->filter_careerlvl = $app->getUserStateFromRequest("com_jobboard.filter_careerlvl", 'filter_careerlvl', array(), 'array'); $this->filter_edulevel = $app->getUserStateFromRequest("com_jobboard.filter_edulevel", 'filter_edulevel', array(), 'array'); $this->pagination =& $this->get('Pagination'); $this->categories =& $this->get('Categories'); $this->setstate = JobBoardHelper::renderJobBoard(); $this->jobsearch = $this->escape($this->jobsearch); $this->keysrch = $this->escape($this->keysrch); $this->locsrch = $locsrch; $retries = $app->getUserState('com_jobboard.member.retry', 0, 'int'); $this->retries = $retries; $this->user_entry_point = 'com_users'; if (version_compare(JVERSION, '2.5.0', 'ge') || version_compare(JVERSION, '1.7.0', 'ge') || version_compare(JVERSION, '1.6.0', 'ge')) { $this->user_entry_point = 'com_users'; } elseif (version_compare(JVERSION, '1.5.0', 'ge')) { $this->user_entry_point = 'com_user'; } $this->_addScripts(); $this->rss_on = JobBoardListHelper::rssEnabled(); $document =& JFactory::getDocument(); parent::display($tpl); }
function display($tpl = null) { $task = JRequest::getVar('task', ''); $row =& $this->get('data'); $this->assignRef('row', $row); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->long_day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%a' : 'D'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; $_format = JRequest::getString('tmpl', ''); $this->is_modal = $_format == 'component' ? true : false; if (!$this->is_modal) { require_once JPATH_COMPONENT_ADMINISTRATOR . DS . 'helpers' . DS . 'jobboard_behavior.php'; } parent::display($tpl); }
function display($tpl = null) { $app = JFactory::getApplication(); $rows =& $this->get('data'); $pagination =& $this->get('pagination'); $app = JFactory::getApplication(); $this->group = $app->getUserState("com_jobboard.users.group"); $this->config =& $this->get('ListConfig'); $this->search = $this->get('search'); $this->assignRef('rows', $rows); $this->assignRef('pagination', $pagination); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $lists['order'] = $app->getUserStateFromRequest('com_jobboard.users.filterOrder', 'filter_order', 'id'); $lists['orderDirection'] = $app->getUserStateFromRequest('com_jobboard.users.filterOrderDirection', 'filter_order_Dir', 'ASC', 'cmd'); $lists['orderDirection'] = strtoupper($lists['orderDirection']) == 'ASC' ? 'ASC' : 'DESC'; $this->assignRef('lists', $lists); if (!empty($this->search)) { $this->search = $this->escape($this->search); } parent::display($tpl); }
function display($tpl = null) { $app = JFactory::getApplication(); $rows =& $this->get('data'); $pagination =& $this->get('pagination'); $search = $this->get('search'); $this->assignRef('rows', $rows); $this->assignRef('pagination', $pagination); $this->assign('search', $search); $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); $lists['order'] = $app->getUserStateFromRequest('com_jobboard.unsolicited.filterOrder', 'filter_order', 'request_date'); $lists['orderDirection'] = $app->getUserStateFromRequest('com_jobboard.unsolicited.filterOrderDirection', 'filter_order_Dir', 'DESC', 'cmd'); $lists['orderDirection'] = strtoupper($lists['orderDirection']) == 'ASC' ? 'ASC' : 'DESC'; $this->assignRef('lists', $lists); $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->long_day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%a' : 'D'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; parent::display($tpl); }
function display($tpl = null) { if (version_compare(JVERSION, '1.7.0', 'ge')) { // Options button. if (JFactory::getUser()->authorise('core.admin', 'com_jobboard')) { JToolBarHelper::preferences('com_jobboard'); } } $task = JRequest::getVar('task', ''); //get config data $row =& JTable::getInstance('Config', 'Table'); $id = 1; //there is only one config record, with the id=1 (set during installation) so we don't need to look at the cid even though it might be sent if (!$row->load($id)) { JError::raiseError(500, $row->getError()); } else { $this->assignRef('row', $row); } switch ($this->section) { case 'general': break; case 'users': $this->user_groups =& $this->get('UserGroups'); break; case 'jobs': $this->dist_array = array(10, 15, 20, 30, 50, 70, 100, 300, 500, 1000, 5000, 10000); break; default: break; } /* $this->assignRef('depts', JRequest::getVar('depts', '')); $this->assignRef('countries', JRequest::getVar('countries', '')); $this->assignRef('careers', JRequest::getVar('careers', '')); $this->assignRef('edu', JRequest::getVar('edu', '')); $this->assignRef('jobtypes', JRequest::getVar('jobtypes', '')); $this->assignRef('categories', JRequest::getVar('categories', ''));*/ $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); parent::display($tpl); }
function display($tpl = null) { $app = JFactory::getApplication(); $this->_addScripts(); $this->assign('setstate', JobBoardHelper::renderJobBoard()); $this->assign('errors', JRequest::getVar('errors', 0)); $this->itemid = JRequest::getInt('Itemid'); $retries = $app->getUserState('com_jobboard.member.retry', 0, 'int'); $this->retries = $retries; $document =& JFactory::getDocument(); $document->setTitle(JText::_('SUBMIT_YOUR_CV_RESUME')); if ($this->errors == 1) { $this->fields = $app->getUserState('com_jobboard.fields', null); } $this->user_entry_point = 'com_users'; if (version_compare(JVERSION, '2.5.0', 'ge') || version_compare(JVERSION, '1.7.0', 'ge') || version_compare(JVERSION, '1.6.0', 'ge')) { $this->user_entry_point = 'com_users'; } elseif (version_compare(JVERSION, '1.5.0', 'ge')) { $this->user_entry_point = 'com_user'; } parent::display($tpl); }
function authenticateUser() { JRequest::checkToken() or jexit('Invalid Token'); require_once JPATH_COMPONENT_ADMINISTRATOR . DS . 'helpers' . DS . 'jobboard_member.php'; $app =& JFactory::getApplication(); $retries = $app->getUserState('com_jobboard.member.retry', 0, 'int'); $app->setUserState('com_jobboard.member.initial_view', 'login', 'string'); if (JobBoardHelper::verifyLogin()) { if (!JobBoardMemberHelper::matchHumanCode(JRequest::getString('human_ver', ''))) { $retries += 1; $app->setUserState('com_jobboard.member.retry', $retries, 'int'); $app->redirect(JRoute::_('index.php?option=com_jobboard&view=member'), JText::_('COM_JOBBOARD_FORM_CAPTCHA_FAILMSG'), 'error'); return; } } $user = array(); $user['username'] = JRequest::getString('username', ''); $user['password'] = JRequest::getString('password', ''); $return = JRequest::getString('redirect', ''); $remember = JRequest::getString('remember', ''); $remember = $remember == 'yes' ? true : false; $this->_login($user, $remember, $return); }
function display($tpl = null) { $task = JRequest::getVar('task', ''); $cid = JRequest::getVar('cid', false, 'DEFAULT', 'array'); if ($cid) { $id = $cid[0]; } else { $id = JRequest::getInt('id', 0); } $newjob = $id > 0 ? false : true; if ($newjob) { /* $cfigt = JTable::getInstance('Config', 'Table'); $cfigt->load(1); $this->assignRef('config', $cfigt);*/ } $this->day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%d' : 'd'; $this->long_day_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%a' : 'D'; $this->month_long_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%B' : 'F'; $this->month_short_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%b' : 'M'; $this->year_format = !version_compare(JVERSION, '1.6.0', 'ge') ? '%Y' : 'Y'; $this->assign('jb_render', JobBoardHelper::renderJobBoardx()); // $this->assign('newjob', $newjob); parent::display($tpl); }
function revokeLinkedInToken() { $step = 4; $linkedin_imported = 0; $view =& $this->getView('user', 'html'); $layout_style = $this->_umodel->getLayoutConfig(); $pp_status = JobBoardHelper::checkProfilePicStatus($this->_uid, $this->_umodel); JPluginHelper::importPlugin('Jobboard'); $dispatcher =& JDispatcher::getInstance(); $linkedin_arr = $dispatcher->trigger('onCallLinkedInApi', array(array('uid' => &$this->_uid, 'type' => 'revoke'))); $view->setLayout('user'); $view->assign('context', 'addcv'); $view->assign('linkedin_imported', $linkedin_imported); $view->assign('step', $step); $view->assignRef('linkedin_arr', $linkedin_arr); $view->assign('is_profile_pic', $pp_status['is_profile_pic']); $view->assign('imgthumb', $pp_status['urithumb']); $view->assign('layout_style', $layout_style); $view->assignRef('user_auth', $this->_user_cred); $view->display(); }
(<?php echo strtolower(JText::sprintf('COM_JOBBOARD_PAST_N_DAYS', $daterange)); ?> )<?php } ?> <?php if ($selcat == 1 && $daterange > 0) { echo JText::sprintf('COM_JOBBOARD_PAST_N_DAYS', $daterange); } ?> <?php } elseif ($this->country_id != 0) { ?> <?php $filter_countryname = JobBoardHelper::getCountryName($this->country_id); ?> <?php if ($this->country_id == 266) { $filter_countryname = JText::_($filter_countryname); } ?> <?php if ($selcat != 1 && $daterange < 1) { echo $seldesc; ?> (<?php echo $filter_countryname; ?> )<?php }
$app = JFactory::getApplication(); ?> <?php $afields = $app->getUserState('com_jobboard.sfields'); ?> <?php } ?> <?php $req_marker = '*'; ?> <?php $path = 'index.php?option=com_jobboard&view=job&task=share&Itemid=' . $this->itemid; ?> <?php $verify_humans = JobBoardHelper::verifyHumans(); ?> <div id="aplpwrapper"> <h3><?php echo JText::_('EMAIL_JOB_POSTING'); ?> </h3> <div <?php if ($this->config->sharing_job_summary == 1) { echo 'id="contleft"'; } ?> > <form method="post" action="<?php echo JRoute::_($path); ?>
function sendEmail($msgobj, $config, $to_email, $msg_type) { $messg_model =& $this->getModel('Message'); $msg_id = $messg_model->getMsgID($msg_type); $msg = $messg_model->getMsg($msg_id); $from = $config->reply_to; $fromname = $config->organisation; $subject = str_replace('[toname]', $msgobj['first_name'], $msg->subject); $subject = str_replace('[tosurname]', $msgobj['last_name'], $subject); $body = str_replace('[toname]', $msgobj['first_name'], $msg->body); $body = str_replace('[tosurname]', $msgobj['last_name'], $body); $user =& JFactory::getUser(); $body = str_replace('[appladmin]', $user->name, $body); if ($msg_type == 'adminnew_application') { $subject = str_replace('[jobtitle]', $msgobj['title'], $subject); $subject = str_replace('[jobid]', $msgobj['job_id'], $subject); $subject = str_replace('[fromname]', $fromname, $subject); $body = str_replace('[jobid]', $msgobj['job_id'], $body); $body = str_replace('[jobtitle]', $msgobj['title'], $body); $body = str_replace('[fromname]', $fromname, $body); $status_tbl =& JTable::getInstance('Status', 'Table'); $status_tbl->load($msgobj['status']); $body = str_replace('[department]', $msgobj['dept_name'], $body); $body = str_replace('[applstatus]', $status_tbl->status_description, $body); } if ($msg_type == 'adminupdate_unsolicited') { $body = str_replace('[applicantid]', $msgobj['id'], $body); } return JobBoardHelper::dispatchEmail($from, $fromname, $to_email, $subject, $body); }
function sendEmail($msgobj, $config, $to_email, $msg_type) { $messg_model =& $this->getModel('Message'); $msg_id = $messg_model->getMsgID($msg_type); $msg = $messg_model->getMsg($msg_id); $from = $config->reply_to; $fromname = $config->organisation; /* $to_email = $msgobj->email;*/ $job_status = $msgobj->published == 1 ? JText::_('COM_JOBBOARD_ACTIVE') : JText::_('COM_JOBBOARD_INACT'); $subject = str_replace('[jobtitle]', $msgobj->job_title, $msg->subject); $subject = str_replace('[jobid]', $msgobj->id, $subject); $subject = str_replace('[location]', $msgobj->city, $subject); $subject = str_replace('[department]', $msgobj->dept_name, $subject); $subject = str_replace('[status]', $job_status, $subject); $body = str_replace('[jobid]', $msgobj->id, $msg->body); $body = str_replace('[jobtitle]', $msgobj->job_title, $body); $body = str_replace('[location]', $msgobj->city, $body); $body = str_replace('[department]', $msgobj->dept_name, $body); $body = str_replace('[status]', $job_status, $body); if ($msg_type == 'adminupdate' || ($msg_type = 'adminnew')) { $user =& JFactory::getUser(); $body = str_replace('[appladmin]', $user->name, $body); } return JobBoardHelper::dispatchEmail($from, $fromname, $to_email, $subject, $body); }
function display($tpl = null) { jimport('joomla.utilities.date'); $app = JFactory::getApplication(); $app->setUserState("com_jobboard.jobsearch", ''); $app->setUserState("com_jobboard.keysrch", ''); $app->setUserState("com_jobboard.locsrch", ''); $app->setUserState('com_jobboard.daterange', 0); $app->setUserState('com_jobboard.list.country_id', 0); $app->setUserState('com_jobboard.list.sort', ''); $app->setUserState('com_jobboard.list.order', ''); $app->setUserState('com_jobboard.list.selcat', 1); $app->setUserState("com_jobboard.sel_distance", null); $app->setUserState("com_jobboard.filter_job_type", array()); $app->setUserState("com_jobboard.filter_careerlvl", array()); $app->setUserState("com_jobboard.filter_edulevel", array()); $app->setUserState('com_jobboard.list.layout', 'table'); $this->data =& $this->get('Data'); $app->setUserState('com_jobboard.list.layout', $this->layout); $featured_count = $this->countFeatured(&$this->data); $locsrch = $this->escape($this->locsrch); if ($featured_count > 0) { $split_data = $this->sortFeatured(&$this->data); $this->featured_jobs = $split_data[0]; $this->latest_jobs = $split_data[1]; unset($split_data, $this->data); } else { $this->featured_jobs = array(); $latest_jobs = array(); for ($j = 0; $j < 5; $j++) { if (isset($this->data[$j])) { $latest_jobs[] = $this->data[$j]; } } $this->latest_jobs = $latest_jobs; unset($latest_jobs, $this->data); } $this->config =& $this->get('Querycfg', 'Config'); $this->jobsearch =& $this->get('Search'); $this->jobtypes =& $this->get('JobTypes'); $this->jobcareerlvls =& $this->get('Careerlvls'); $this->jobedlvls =& $this->get('Edlvls'); $this->intro_cats =& $this->get('IntroCats', 'Jobboard'); if ($this->config->use_location == true) { $this->radii =& $this->get('Distances'); $this->dist_symbol = $this->config->distance_unit == 0 ? JText::_('COM_JOBBOARD_DIST_METRIC') : JText::_('COM_JOBBOARD_DIST_IMPERIAL'); $this->sel_distance = $app->setUserState("com_jobboard.sel_distance", $this->config->default_distance, 'int'); $geo_address = $app->getUserState('com_jobboard.geo_address'); $this->assign('geo_address', $geo_address); } $this->featured_count = $featured_count; $this->filter_job_type = $app->getUserStateFromRequest("com_jobboard.filter_job_type", 'filter_job_type', array(), 'array'); $this->filter_careerlvl = $app->getUserStateFromRequest("com_jobboard.filter_careerlvl", 'filter_careerlvl', array(), 'array'); $this->filter_edulevel = $app->getUserStateFromRequest("com_jobboard.filter_edulevel", 'filter_edulevel', array(), 'array'); $this->categories =& $this->get('Categories'); $this->setstate = JobBoardHelper::renderJobBoard(); $this->jobsearch = $this->escape($this->jobsearch); $this->keysrch = $this->escape($this->keysrch); $this->locsrch = $locsrch; $retries = $app->getUserState('com_jobboard.member.retry', 0, 'int'); $this->retries = $retries; $this->user_entry_point = 'com_users'; if (version_compare(JVERSION, '2.5.0', 'ge') || version_compare(JVERSION, '1.7.0', 'ge') || version_compare(JVERSION, '1.6.0', 'ge')) { $this->user_entry_point = 'com_users'; } elseif (version_compare(JVERSION, '1.5.0', 'ge')) { $this->user_entry_point = 'com_user'; } $this->_addScripts(); $this->rss_on = JobBoardListHelper::rssEnabled(); $document =& JFactory::getDocument(); parent::display($tpl); }
function sendEmail($msgobj, $recipient) { $messg_model =& $this->getModel('Message'); $msg_id = $messg_model->getMsgID('sharejpriv'); $msg = $messg_model->getMsg($msg_id); $from = $msgobj->sender_email; $fromname = $msgobj->sender_name; $to_email = $recipient; $subject = $msg->subject; $body = $msgobj->personal_message; $body_b = str_replace('[location]', $msgobj->job_city, $msg->body); $body_b = str_replace('[jobtitle]', $msgobj->job_title, $body_b); $body = $body . $body_b . JText::_('MESSAGE_LINK_TEXT') . ': ' . $msgobj->link; return JobBoardHelper::dispatchEmail($from, $fromname, $to_email, $subject, $body); }