Would it be possible to route WordPress Through an MVC Application

Well, it looks like my latest idea proved correct. Simply including the index file for wordpress was enough to get permalinks working for blog posts.

$app->slim->notFound(function() use($app) { 
    //to make pretty url's work with turdpress, we must see if that request was intended for our blog route.
    if(strpos($app->slim->request->getPath(),'/blog/') !== false){
        include __DIR__ . '/../../blog/index.php';
    }else{
        $app->args['title'] .='404 Not Found';
        $app->args['scripts'] = 'js/404.js';
        echo $app->loadTemplate('404.twig')->render($app->args); 
    }
}); 

I am curious to know if anyone thinks this is dangerous.

deneme bonusu veren sitelerbahis casinomakrobetceltabetpinbahispolobetpolobet girişpinbahis girişmakrobet girişpulibet girişmobilbahis girişkolaybet giriş