![]() |
[1.5.1 RELEASED] COMPER Template Parser - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: [1.5.1 RELEASED] COMPER Template Parser (/showthread.php?tid=29868) |
[1.5.1 RELEASED] COMPER Template Parser - El Forum - 01-26-2011 [eluser]Tominator[/eluser] Of course, it's possible: Code: $data = array(); Or .. if you will not parse anything between them, you can use: Code: $data = array(); Because $this->parser->content contains last parsered template. In TPL, it's simple (main.tpl: Code: <!-- INCLUDE overall_header --> Enjoy! [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]-[/eluser] hi everyone, help me .. give one example of a package; I use codeignitor_reactor2 1. controller / controller_themes.php 2. views / controller_views.tpl I am confused to make his controller ... thanks, good jobs 'COMPER Template Parser' sorry I'm not good at all with English, ... [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]Tominator[/eluser] Do you mean you are using CI 2.0? If yes continue reading. In docs I am using: /application/controller/controller_file.php /application/library/Parser.php (it's library, you have downloaded it) /application/views/template_file.tpl Enjoy! (If you are not using CI 2.0 please send a link for CI reactor 2, I'll try to help you ...) Tom [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]-[/eluser] I use CodeIgniter-reactor-v2.0.0.zip (https: / / bitbucket.org / ellislab / CodeIgniter-reactor / downloads) please give an example for the controller and view ... I still try and error on localhost PC ... Thanks. I Hope you can do..... ![]() [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]-[/eluser] I have Parser_CI.php (libraries), do? should I rename it with Parser.php (sourcefile:http://parser.comper.sk/en/download/) [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]-[/eluser] themes.php --------------------------------------------- <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); class Themes extends Parser_CI { function __construct() { parent::__construct(); } function themes() { $this->load->library('parser'); $this->parser->parse('themes'); } } /* End of file themes.php */ /* Location: ./application/controllers/themes.php */ themes.tpl --------------------------- <html> <head> <title>Testing</title> </head> <body> Static Content </body> </html> -------------------------------- ??........... help me... 404 Page Not Found The page you requested was not found. ;using' CodeIgniter-reactor-v2.0.0.zip (https: / / bitbucket.org / ellislab / CodeIgniter-reactor / downloads) [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]Tominator[/eluser] No ... ![]() 1, I'm sorry you really have to rewrite Parser_CI.php to Parser.php ... I'm sorry, my mistake 2, Themes are not working this way, because: A, you don't need to make special file for theme B, you have to specify theme So: /application/controllers/controller_file.php Code: <?php /application/views/default/tpl/template_file.tpl Code: <html> That's all. Hope it's working! More informations on docs, here or helpdesk. Enjoy! [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]Tominator[/eluser] My question is: Do you really need themes? It's additional or optional feature. I'm just making sure, you know about it ... [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]-[/eluser] "My question is: Do you really need themes? It’s additional or optional feature. I’m just making sure, you know about it ... " @Tominator : thanks,... yes I'm trying to create themes, just learning, I'm a beginner, thank you 'script', above, are able to walk,,... im happy... running.... [1.5.1 RELEASED] COMPER Template Parser - El Forum - 02-10-2011 [eluser]Tominator[/eluser] You are welcome! ![]() |