I'm opening a file first, then parsing the contents with my_object function, and then I'd like to feed that output into another object.
Unfortunately though, the second object only accepts files instead of code on-the-fly as it were. Rather than start messing around with my template object, I'm wondering if there is another way I could feed in my code and have it accepted as a file.
I'll be running my code through my own class roughly something like this
The assign_var_from_handle expects a file, not code.
I'm basically wrapping the index.tpl in my own larger javascript/html file which is produced by my object.
Unfortunately though, the second object only accepts files instead of code on-the-fly as it were. Rather than start messing around with my template object, I'm wondering if there is another way I could feed in my code and have it accepted as a file.
I'll be running my code through my own class roughly something like this
Code:
$temp_code = $my_object -> output('index.tpl');
$template->set_filenames( 'index' => $temp_code );
$template->assign_vars( 'VAR_1' => $row1 );
$template->assign_var_from_handle('INDEX' , 'index' );
$template->pparse('body');
The assign_var_from_handle expects a file, not code.
I'm basically wrapping the index.tpl in my own larger javascript/html file which is produced by my object.