CodeIgniter Forums
ERROR: adding CSS in codeigniter - 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: ERROR: adding CSS in codeigniter (/showthread.php?tid=58557)



ERROR: adding CSS in codeigniter - El Forum - 06-24-2013

[eluser]21stnomad[/eluser]
error:

Code:
A PHP Error was encountered

Severity: Notice

Message: Use of undefined constant css - assumed 'css'

in config file:

Code:
$config['css'] = "mystyles.css";

showing this error...

can anyone please help me to sort out this...

thanks in advance


ERROR: adding CSS in codeigniter - El Forum - 06-24-2013

[eluser]Pert[/eluser]
This error message makes sense if you forgot quotes around array index.
Code:
$config[css] = "mystyles.css";

Are you sure this is the right file / right line that throws the error?



ERROR: adding CSS in codeigniter - El Forum - 06-24-2013

[eluser]21stnomad[/eluser]
code is correct...

i checked it...


ERROR: adding CSS in codeigniter - El Forum - 06-24-2013

[eluser]Pert[/eluser]
Sure, but the error message you pasted here does not show file name or line number. The only way this error would be displayed is if quotes around array index are missing - but your configuration file line seems to be correct. That's why I suggested it could be either different file or different line in the code.

If anything I would suggest changing double quotes around file name to single quotes, just better practice and that way PHP will not try to repace substrings in the code ( "$varname gets replaced" ).


ERROR: adding CSS in codeigniter - El Forum - 06-24-2013

[eluser]21stnomad[/eluser]
thanks

i will do that and check it again.