PHP in Templates and Template Conditionals - Printable Version +- MyBB Community Forums (https://community.mybb.com) +-- Forum: Extensions (https://community.mybb.com/forum-201.html) +--- Forum: Plugins (https://community.mybb.com/forum-73.html) +---- Forum: Plugin Support (https://community.mybb.com/forum-72.html) +---- Thread: PHP in Templates and Template Conditionals (/thread-31860.html) |
RE: PHP in Templates and Template Conditionals - Yumi - 2010-02-28 (2010-02-27, 01:06 PM)bosss Wrote: I make changes ok and after changes works not code what i put in index template (throught admincp), that only guest can see slideshow - result was that all usergroups can see slideshow, (mean members of board) - that is what i try to explain to you!Did you try my uploaded file? Otherwise, I don't know how to help you, as the code you posted works fine for me here, and I can't really see any reason why it shouldn't. Could you test it on a clean MyBB install with just the plugin file I uploaded? (2010-02-27, 01:06 PM)bosss Wrote: for now have problem with characters in posts (croatian)... maybe you have some solutions?I don't think this would be caused by this plugin, but is your database in UTF-8? RE: PHP in Templates and Template Conditionals - RateU - 2010-02-28 I have tried this plugin with My Tracker and Game Section. I don't have any problem at all. Even I run a conditional in My Tracker template. I don't know about the merge system. I never try that. RE: PHP in Templates and Template Conditionals - Yumi - 2010-02-28 Just updated this plugin with the ability to call templates easily from within templates, eg <template my_custom_template>. Useful if you have common code you wish to share between multiple templates. Do note that it's rather basic, so no pre-caching of templates is done. This shouldn't be an issue if you're only calling one or two templates, but do take note if you're calling a lot of different templates. Also, it doesn't do any recursion checking, so don't get a template to call itself, or get it caught in a cycle of template calls. RE: PHP in Templates and Template Conditionals - bosss - 2010-02-28 I uploaded your file (phptpl.php) and now works - mean guests see only that slideshow - not members - thanks! my mybb database is utf-8 and vb database is latin1 and i know that is have nothing to do with your plugin! Thanks bosss RE: PHP in Templates and Template Conditionals - Yumi - 2010-02-28 (2010-02-28, 08:53 AM)bosss Wrote: my mybb database is utf-8 and vb database is latin1 and i know that is have nothing to do with your plugin!Probably a conversion issue then. You need to ensure that your latin1 -> UTF-8 conversion is successful. Glad that you got it working. Thanks. RE: PHP in Templates and Template Conditionals - Onloac - 2010-03-16 Works great! Thanks for putting time into this plug-in for us!! RE: PHP in Templates and Template Conditionals - gokufg - 2010-03-22 Hi Yumi, thanks a lot for your plugin!!! Is it possible to add "some staff" in every first post of multipage thread? I mean that when I go in page 2 (or 1, or 3, or 4.......) of a thread I wanna see in first post this "some staff". Fortunately I can suggest you http://www.webbando.com/come-realizzare-un-sito-gratis-senza-conoscere-codice-html-o-php-2401.html where you can find a way to know how to made it without any code. Is it possibile? RE: PHP in Templates and Template Conditionals - Yumi - 2010-03-22 Could you elaborate more? Did you mean "some stuff" or "some staff" as in names of moderators? Did you want the thread's first post to appear on every page, or did you want something just to show up on whatever post is displayed first on each page? RE: PHP in Templates and Template Conditionals - gokufg - 2010-03-23 (2010-03-22, 11:16 PM)Yumi Wrote: Could you elaborate more?I want something just to show up on whatever post is displayed first on each page Is it possible? Thanks a lot!! RE: PHP in Templates and Template Conditionals - Yumi - 2010-03-23 Maybe try something like this in the postbit template:
|