I downloaded the site from the server and put it to run on localhost. However, it is not calling the files correctly. First, it calls " link " and then the folder path, with backslash.
Thereisarulesettocallallfiles:
<?phpdefine("MY_BASE_DIR", 'C:');
define("SITE_PATH", __DIR__ . '/');
define("SITE_VIRTUAL_DIR", str_replace($_SERVER["DOCUMENT_ROOT"], "", SITE_PATH));
define("ENGINE_PATH", SITE_PATH.'includes/fw/'); // caminho pro FW
define("CMS_ENGINE_PATH", SITE_PATH.'includes/cms/cms.php');
I tried to change this rule, but without success.
This backslash configuration is some snippet in the code files that have either been modified or is my local server configuration (I'm using WampServer)?
----------------------------- UPDATE -------------- ----------------
This is the file that gives way to the files:
public function Setup()
{
parent::Setup();
if (\Browser::Obsolet())
{
$this->context->UpdateYourBrowser();
}
if(!defined("ADMIN_DIR")){
define("ADMIN_DIR", dirname($_SERVER["SCRIPT_NAME"]) . "/");
define("ADMIN_URL", DOMAIN . ADMIN_DIR );
}
if(!defined("ADMIN_PATH"))
{
throw new \Exception("Para acessar um módulo do backend você precisa esta no diretorio do admin/");
}
// configura a sessao do usuario
$this->context->set("USER.SESSION", $this->context->get("USER.SESSION") . ADMIN_PATH . "_ADMIN");
// configura o template do ADMIN
// checa se o usuario especificou algum caminho para o template do ADMIN
$templatePath = $this->context->get("CMS.ADMIN.TEMPLATE_PATH");
if(!$templatePath){
$templatePath = ADMIN_PATH;
}
$this->context->setTemplatePath($templatePath); //diretorio raiz de templates?
$this->context->setTemplate($this->context->get('CMS.ADMIN.TEMPLATE')); // seta o template configurado no config.php
// checa se o usuario especificou algum caminho para o template do ADMIN
$templateUrl = $this->context->get("CMS.ADMIN.TEMPLATE_URL");
if(!$templateUrl){
$templateUrl = ADMIN_DIR; // URI do admin: http://localhost/admin/
}
if(!defined("TEMPLATE_URL"))
define("TEMPLATE_URL", $templateUrl . $this->context->TemplateDir() . $this->context->getTemplate() . "/");
}
@Rafaelphp Files are being called through TEMPLATE_URL
:
<link rel="stylesheet" href="<?php echo TEMPLATE_URL ?>static/css/bootstrap.min.css" rel="stylesheet">
I'm still trying to get him to call straight, but to no avail.