Displaying Dynamic Content in Custom *.tpl from *.php

I am trying to follow this blog guideline http://blog.oxid-esales.com/2009/05/how-extend-oxid-eshop-part2/

but when calling the function ‘isWorkingHours()’ I got this error

“Function ‘isWorkingHours’ does not exist or is not accessible! (Tpl)
#0 /kligmlld/update/tmp/722eb1d6aa705492eda60445ba0ca537^%%59^590^59025401%%newsletter_templete.tpl.php(125): oxSuperCfg->__call(‘isWorkingHours’, Array)
#1 /kligmlld/update/tmp/722eb1d6aa705492eda60445ba0ca537^%%59^590^59025401%%newsletter_templete.tpl.php(125): Tpl->isWorkingHours()
#2 /kligmlld/update/core/smarty/Smarty.class.php(1263): include(’/kligmlld/updat…’)
#3 /kligmlld/update/views/oxshopcontrol.php(446): Smarty->fetch(‘custom/newslett…’, ‘ox|0|0|1|0’)
#4 /kligmlld/update/views/oxshopcontrol.php(317): oxShopControl->_render(Object(Tpl))
#5 /kligmlld/update/views/oxshopcontrol.php(114): oxShopControl->_process(‘tpl’, NULL)
#6 /kligmlld/update/index.php(103): oxShopControl->start()
#7 {main};”

Any help will be appreciated. Thanks in Advance!

This tutorial is more than six years old and a lot has changed in the shop especially regarding modules since then. Maybe you better take a look at the ones by the community guide Marco Steinhäuser, e.g.: http://www.marco-steinhaeuser.de/how-to-write-a-module-for-oxid-eshop-display-you-will-save-x-percent-on-the-product-details-page.html
They’re more recent and most of the stuff is still true for the current shop versions.

From the stack trace it seems that you are calling a controller tpl which does not have a method isWorkingHours(). In the tutorial the controller is called staff if I saw it correctly. So probably you are doing something different than in the tutorial.

Thanks @martin.wegele