Jump to content

Settings theme in if

Featured Replies

Posted
{{if $comment->author()->inGroup( \IPS\Theme::i()->setting( 'aXenTopics_1' ) ) AND theme.aXenMFluent_Pro_1 == 1 AND theme.aXenMFluent_Pro_1_Topic == 1}}aXenTopicsProfile_1{{endif}}

Hi,
I would like to pull the setting value to the style bit and paste it into the if. I wanted to do something like this, but writing is not possible.

\IPS\Theme::i()->setting( 'aXenTopics_1' )

What is wrong?

Edited by aXen | 1s2k

1 hour ago, aXen | 1s2k said:

{{if $comment->author()->inGroup( \IPS\Theme::i()->setting( 'aXenTopics_1' ) ) AND theme.aXenMFluent_Pro_1 == 1 AND theme.aXenMFluent_Pro_1_Topic == 1}}aXenTopicsProfile_1{{endif}}

Hi,
I would like to pull the setting value to the style bit and paste it into the if. I wanted to do something like this, but writing is not possible.


\IPS\Theme::i()->setting( 'aXenTopics_1' )

What is wrong?

I am guessing trying settings to theme template ? if so your example will not work that more for hook/application back end code.

  • Author

image.thumb.png.3b2ffea14b21b43b0e59e8123ed15f68.png

image.png.9680c4467c5cf9ade36aa7f99332012d.png

It is in theme.

Edited by aXen | 1s2k

  • Author

It's working!

{{if $comment->author()->inGroup( theme.aXenTopics_1 ) AND theme.aXenMFluent_Pro_1 == 1 AND theme.aXenMFluent_Pro_1_Topic == 1}}aXenTopicsProfile_1{{endif}}

I forgot that you need to add the phrase 'theme'.

x factor omg GIF by X Factor Global

Archived

This topic is now archived and is closed to further replies.

Recently Browsing 0

  • No registered users viewing this page.