MyBB Community Forums

Full Version: Part of a message only visible for registered members
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Those that I can not make you understand is that the problem is not the MyCode itself but the variable I use it. Of the myCodes the "$" is detected as an object or replace the variable name should be changed ..
(2013-09-02, 07:58 PM)Traxmix Wrote: [ -> ]Those that I can not make you understand is that the problem is not the MyCode itself but the variable I use it. Of the myCodes the "$" is detected as an object or replace the variable name should be changed ..

That makes no sense at all

as you use a plugin to use conditionals within the mycode there is a chance the plugin can not see the variable that mycode sees so will simply return $1 or whatever as null and will never evaluate the statement
So there is no way then?
(2013-09-02, 08:14 PM)Traxmix Wrote: [ -> ]So there is no way then?

there is a way but you need to have a plugin written that adjusts the message between custom tags ... the evaluation is then done via the plugin and the message text returned to mybb parser for display. I have written a plugin (not released) that replaces custom tag contents with what needs to be displayed. I could alter the code I have written to suit your needs.

example
you type

[usergroup=1] text to display to user group 1 [/usergroup]
in a message
mybb returns to members of user group 1
text to display to user group 1
in the message this could be expanded to suit your needs
Can you send me this plugin via PM or another .. And tell me whom I should enter my myCodes?
Thank you.
Pages: 1 2 3