attr('title','Discipling the Nations: Resources'); $page->content('resources.php'); $page->addCSSFile('resources.css'); $page->addJSFile('ssm.js','ssmItems.js','ssmItems_resources.js'); # get the random verse and pass it to the template $page->data('verse',xml_random_child($FILES['verses'])); # get the resources data from xml files $xml = array(); $res_files = array('articles','books','links','onleadership','teachingoutlines', 'toolsforministry','toolsforpersonal'); $res_path = $DOCROOT.'/site/data/resources'; foreach($res_files as $key => $value) { $xml[$value] = new SimpleXMLElement(file_get_contents($res_path.'/'.$value.'.xml')); unset($xml[$key]); } $page->data('xml',$xml); $page->process(); ?>