<?php
require_once dirname(dirname(dirname(dirname(__FILE__)))).'/config.core.php';
require_once MODX_CORE_PATH.'config/'.MODX_CONFIG_KEY.'.inc.php';
require_once MODX_CONNECTORS_PATH.'index.php';
 
$corePath = $modx->getOption('trosk.core_path',null,$modx->getOption('core_path').'components/trosk/');
require_once $corePath.'model/trosk/trosk.class.php';
$modx->trosk = new Trosk($modx);
 
$modx->lexicon->load('trosk:default');
 
/* handle request */
$path = $modx->getOption('processorsPath',$modx->trosk->config,$corePath.'processors/');
$modx->request->handleRequest(array(
    'processors_path' => $path,
    'location' => '',
));