![]() |
Message: Undefined variable: meta - 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: Message: Undefined variable: meta (/showthread.php?tid=22327) Pages:
1
2
|
Message: Undefined variable: meta - El Forum - 09-05-2009 [eluser]doubleplusgood[/eluser] Awesome! Worked perfectly, thank you so much. Looks like the CI User Guide needs updating. ![]() [quote author="LuckyFella73" date="1252182196"]I didn't test this, but maybe this works Code: <?php Message: Undefined variable: meta - El Forum - 09-05-2009 [eluser]LuckyFella73[/eluser] You're welcome! Glad I could help a bit Message: Undefined variable: meta - El Forum - 09-05-2009 [eluser]SitesByJoe[/eluser] I can't believe I missed that he was loading the view before assigning the arrays and not even passing the data over....how embarrassing... Message: Undefined variable: meta - El Forum - 09-05-2009 [eluser]doubleplusgood[/eluser] [quote author="SitesByJoe" date="1252188142"]I can't believe I missed that he was loading the view before assigning the arrays and not even passing the data over....how embarrassing...[/quote] Heh, we won't tell anyone. ![]() Thank you very much for your help guys. I'm now on the search for a script helper so that I can add script references in the head, but the html helper doesn't seem to offer this. ![]() Message: Undefined variable: meta - El Forum - 09-05-2009 [eluser]LuckyFella73[/eluser] If you need a solution to load javascripts depending on the page that is loaded I can tell you what I do (there may be better ways of course) I have a config file where I define all needed javascripts - for example: Code: $this->js_formscript_news ='<scri+pt type="text/java+scri+pt" src="'.base_url().'js/formscripts_news.js"></scri+pt>'; In the contructor of my controller I load the config file Code: $this->load->file('system/application/config/config_admin.php', true); // for example In the different functions (before calling the view files I set the needed js in case I need one or more like this: Code: $data['js_import'] = array ($this->js_formscript_news,$this->js_formscript_press); And at last in view file (header part of course) I have this: Code: <?php If somebody has a better solution I would be really interested in! |