Using a Paint-layout to Determine What Banner to Use


(Nick Papadatos) #1

Version 5.3.4.2

I have a paint layout with the following

banner raw html nested
asset contents
footer raw html nested

I also have a metadata schema applied to my one-page /landing > related asset field.
The rational is that the footer will always remain but the banner could change based on campaign. so rather than creating a new paint-layout for each new banner (that’s nested) I’d like to use the related asset field to change / choose another banner instead.

My guess would be to have something like the following:

 top div section
    %begin_asset_metadata_banner^gt:0%
      I want to nest the relevant banner?
     %end_asset_metadata_banner%
     middle div section
    %asset_contents%
   footer div section
   is nesting the footer raw html

Hope this makes sense and is there a better way

regards
NickyP


(Bart Banda) #2

Yep, pretty much. Then inside that %begin% %end% you;d just have a keyword like this to get the contents of that banner:
%asset_metadata_banner^as_asset:asset_contents_raw%


(Nick Papadatos) #3

Thanks Bart,
That did it - I tried something similar just had my keyword a tad jumbled
Cheers
NickyP