$GLOBALS['start_time'],'endtime'=>microtime(),'totaltime' => (microtime() - $GLOBALS['start_time']))); if ($_COOKIE['model_id'] != ''){ $_REQUEST['emptycookies'] = '1'; } if ($_REQUEST['emptycookies'] == '1'){ setcookie('make','',time()+(60*60*24*5),'/'); setcookie('model','',time()+(60*60*24*5),'/'); setcookie('site_model_id','',time()+(60*60*24*5),'/'); setcookie('year','',time()+(60*60*24*5),'/'); $_REQUEST['make'] = ''; $_REQUEST['model'] = ''; $_REQUEST['site_model_id'] = ''; $_REQUEST['year'] = ''; $_COOKIE['make'] = ''; $_COOKIE['model'] = ''; $_COOKIE['site_model_id'] = ''; $_COOKIE['year'] = ''; } app_log(LOGCHANNEL_INTERNAL,__FILE__,__CLASS__,__FUNCTION__,__LINE__,LOGTYPE_INFO,"Displaying page"); /** * set up the page.. initializes the templater and standard functions * to override one of the template functions, re-call the $template->addContent() with replace set to yes */ include_once('../includes_site/site_page_setup.inc'); app_log(LOGCHANNEL_INTERNAL,__FILE__,__CLASS__,__FUNCTION__,__LINE__,LOGTYPE_INFO,"Wrote titles and menus, preparing to write screen",array('starttime'=>$GLOBALS['start_time'],'endtime'=>microtime(),'totaltime' => (microtime() - $GLOBALS['start_time']))); /** * Start of page-specific content */ //do we already know their make/model combo? $image_list = array( 'akrapovic' => array('Akrapovic','Fantastic Fantasticness from akrapovic.'), 'galespeed' => array('GaleSpeed','Fantastic Fantasticness from galespeed.'), 'gilles_tooling' => array('Gilles','Fantastic Fantasticness from gilles.'), 'hyperpro' => array('HyperPro','Fantastic Fantasticness from hyperpro.'), 'remus' => array('Remus','Fantastic Fantasticness from remus.'), 'sprint' => array('Sprint','Fantastic Fantasticness from sprint.'), 'supersprox' => array('Super Sprox','Fantastic Fantasticness from supersprox.'), 'zerogravity' => array('Zero Gravity','Fantastic Fantasticness from zero gravity.'), ); foreach ($image_list as $image => $text_data){ $title = $text_data[0]; $body = $text_data[1]; $image = str_replace('.','',$image); $scroll_list .= <<
$title
$body
SCLIST; } $template->addContent('-SCROLLING_PANEL_WIDTH-',count($image_list)*232); $template->addContent('-SCROLLING_PANEL-',$scroll_list); if ($_REQUEST['utm_source'] == 'Visordown'){ $template->addContent('',''); } //get all makes $make = new model(); $makes = $make->getAllRecords("SELECT model_id FROM model GROUP BY make"); if (is_array($makes)){ foreach ($makes as $make) { $make_dropdown_list .= ''; } } $template->addContent('-MAKE_DROPDOWN_LIST-',$make_dropdown_list); ?> addContent('-WELCOMEBACK-',""); ?> output(); app_log(LOGCHANNEL_INTERNAL,__FILE__,__CLASS__,__FUNCTION__,__LINE__,LOGTYPE_INFO,"Page generation complete",array('starttime'=>$GLOBALS['start_time'],'endtime'=>microtime(),'totaltime' => (microtime() - $GLOBALS['start_time']))); ?>