1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.4 Xenforo syntax for targeting styles

Discussion in 'Styling and Customization Questions' started by Adam K M, Nov 1, 2014.

  1. Adam K M

    Adam K M Active Member

    Hello,

    I was wondering what the Xenforo template syntax (if it exists) is for displaying certain content when the user is using a specific style. (The reason being that we've got some images which we want to change when the user is using a 'dark' theme versus one of our lighter themes.)

    Any help is greatly appreciated,
    Thanks!
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    Change the image path for the styles and upload the dark and light images to the respective style directories.
     
  3. Adam K M

    Adam K M Active Member

    Hmmm...
    What if the two themes/styles use the same image path? What then? (I'm looking at pretty much re-colored versions of the same theme)
    I'm helping @Proutie87 and I'm willing to guess that the styles are children to one larger parent, so it makes no sense to change the @imagepath to just fix the one image.
    Going to have to request this XenForo Syntax feature... it'd have much larger uses than just being for images, I can imagine. Like telling a user that their style is depreciated or something.
     

Share This Page