Announcement

Collapse
No announcement yet.

Show random readthytheme content section

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Show random readthytheme content section

    I have a little red animated section of html on my SFNT page http://www.allfrom1supply.com/ (currently: >> Need Locks? Check Out Our Great Selection! ) and was thinking of moving it into a readtheme content section so I could randomly feature different messages on SFNT load.

    I don't want to bog the page down but if there is an efficient way to randomly show say any of 3 or 4 content sections ie sfnt_txtmessage_1, sfnt_txtmessage_2, sfnt_txtmessage_3, sfnt_txtmessage_4 and someone can share that would be appreciated.

    #2
    You can use readytheme content sections for this or content on the storefront mixed with some mivascript to do this. I also have a content module (procontent) that will automatically randomize content for you and do what you're describing. Or you could do something like:

    <mvt:assign name="l.settings:content0" value="'something'" />
    <mvt:assign name="l.settings:content1" value="'something else'" />
    <mvt:assign name="l.settings:content2" value="'something completely different'" />

    <mvt:eval expr="miva_variable_value('l.settings:content' $ random(2))" />
    M.A.D.* since 1997

    http://www.scotsscripts.com

    *miva application developers

    Comment


      #3
      Thank you Scott. It's not critical functionality so not sure I'll throw a module at it, but will take a look for future reference - you have some good useful addons and we are using a couple of them already.

      Comment

      Working...
      X