Roundcube Community Forum

Third Party Contributions => API Based Plugins => Topic started by: jamil_isayyed on October 09, 2013, 04:50:47 AM

Title: template renderring <roundcube:object />
Post by: jamil_isayyed on October 09, 2013, 04:50:47 AM
Hello Folks,

i am stuck in this problem, i have successfully implemented my plugin but i am facing a problem in my templates. i have added the following code in the html template:

<roundcube:object name="plugin.myTestContent" />


and as in the documentation i have added the handling in the plugin php file as follow:

//in the init
$this->register_handler('plugin.myTestContent', array($this, 'processMyTestContent'));

//i have added a function
function processMyTestContent($args)
  {
                $content = "i am a test content";
                return ($content);
   }



the problem is this is not resolved and i don't see the text in the view (page), but in case i used <roundcube:object name="version" /> this tag is processed and i get the value?!!!

so any idea why my tag i snot processed? what i should do?

Thanks in advance.
Jamil Isayyed
Title: Re: template renderring <roundcube:object />
Post by: jamil_isayyed on October 09, 2013, 05:38:00 AM
Well i have changed the roundcube: object to a container as follow:


<div id="contenttest">
<roundcube:container name="plugin.myTestContent" id="contenttest"/>
</div>


and still facing the same problem, any idea about how to solve this issue?

Thanks,
Jamil Isayyed