* Graham * tiaxgame The macro for karma post rating uses a value of post_id so you could probably tack some other javascript on to that macro as it is called for every post in a thread
2014-04-27 14:55 (edited 2014-04-27 14:56 by Graham ) · (0)
* tiaxgame * Graham {% set a="tiax" %}
{% set b="tiaxtest" %}
{{ b|replace(a: "") }}
I want output = "test", but "replace not action! Why!?
2014-04-28 02:24 · (0)
* tiaxgame * Graham And:
{% set c|split(' ') %}tiax test{% endset %}
{{ c[1] }}
Output "test" !?
2014-04-28 03:10 · (0)
* Graham * tiaxgame First one
{% set a="tiax" %}
{% set b="tiaxtest" %}
{{ b|replace({(a) : ""}) }}

Copy code

To use a variable it must be enclosed in ( ) as if it was an expression
you were also missing a set of { }
2014-04-28 10:43 (edited 2014-04-28 11:26 by Graham ) · (0)
* tiaxgame * Graham thank! Else "split"
I can't used "array"
Ex: #23

I want output = "test" =>{{ c[1] }}
But! It's not action ! :(
2014-04-28 11:02 · (0)
* Graham * tiaxgame Your example made no sense
{% set c='tiax test'|split(' ') %}
{{ c[1] }}

Copy code

returns "test"
2014-04-28 11:40 (edited 2014-04-28 11:48 by Graham ) · (1)
* tiaxgame * Graham in "view_thread.js'
{% set d %}{{ block('thread') }}
{% endset %}{% set d %}{{ d|striptags|replace({(thread.title): ""})|split(' ') }}{% endset %}{{ 'total comment: 'd[0] }}

Copy code

I can't fix it! It isn't action
2014-04-28 12:41 · (0)
* Graham * tiaxgame No that will not work for lots of reasons
What are you trying to do ?
2014-04-28 15:12 · (0)
* tiaxgame * Graham http://aichat.wap.sh/index.php/__xt/test/thread-osr2ak8om6guvx3i5ed3ed2mw8ay6sghj3u5.html
Is "Total: (3) 1"
I want to have "total comment" and "total online" of thread
2014-04-28 23:52 · (0)
* tiaxgame * Graham ok! I was fixed, thank
2014-04-29 02:31 · (0)

Online: Guests: 1