CodeIgniter Forums
base_url() giving error - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: base_url() giving error (/showthread.php?tid=3540)



base_url() giving error - El Forum - 10-09-2007

[eluser]bohara[/eluser]
This code in my layout file
Code:
<link rel="stylesheet" href="<?=base_url()?>css/blueprint/screen.css" type="text/css" media="screen, projection">

Gives this error when output
Code:
Call to undefined function: base_url() in <b>/Library/WebServer/Documents/ci/system/application/views/layout.php

It stops ouput right after the page title and I only see the error message when I view source.

Not sure what i am doing incorrectly here?


base_url() giving error - El Forum - 10-09-2007

[eluser]Derek Allard[/eluser]
Are you loading or autoloading the url helper?


base_url() giving error - El Forum - 10-09-2007

[eluser]bohara[/eluser]
No, I will try that. Thanks.