[英]CodeIgniter base_url() failure
My base url function is not working in the latest version of code igniter. 我的基本url函数在最新版本的代码点火器中不起作用。 Trying to use it in a style sheet path, and then just echoed it on a view to see if it worked there, to no avail.
尝试在样式表路径中使用它,然后在视图上回显它以查看它是否在那里工作,但无济于事。
calling it this way: 这样称呼它:
<?php echo base_url(); ?>
and then with the style sheet like so: 然后使用如下样式表:
<link rel="stylesheet" href="<?php echo base_url(); ?>css/style.css" type="text/css" media="screen" charset="utf-8"/>
And here it is assigned in my config.php file: 这是在我的config.php文件中分配的:
$config['base_url'] = 'http://www.codeigniter.dev/';
$config['server_root'] = $_SERVER['DOCUMENT_ROOT'];
Any ideas? 有任何想法吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.