running a script in a php module - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: running a script in a php module (/showthread.php?tid=78498) Pages:
1
2
|
RE: running a script in a php module - craig - 02-01-2021 In that case I don't know why it's not loading. Do other assets like CSS and JS load properly? Where are those located? RE: running a script in a php module - richb201 - 02-03-2021 I managed to solve this. Turns out that one of my paths was missing a space, and that was the one that I was hod coding for testing. I got this working. Now I need to use this same logic to modify the menus for the different versions (or perhaps grey out some choices?) RE: running a script in a php module - richb201 - 02-03-2021 I am trying to do something similar here but am having trouble with the <script></script> section. PHP Code: <?php RE: running a script in a php module - craig - 02-03-2021 Why are you inserting <script> tags? They're only for Javascript. RE: running a script in a php module - richb201 - 02-03-2021 How do I tell it that this next line is not php (ie li)? I switched over to: $type=$this->session->userdata('type'); //type of campaign (ir software, pharma, etc) if ($type==2) //this is for software { echo "li ><a href = '<?php echo site_url('Configure / IUS_management')?>' > IUS</a ></li >"; } But that is not working. RE: running a script in a php module - craig - 02-03-2021 Either end the PHP parsing with '?>', or you can use echo to output the HTML tags and stay in PHP: PHP Code: $url = site_url('Configure / IUS_management'); RE: running a script in a php module - richb201 - 02-03-2021 Works. Thanks. |