Change Font within dynamic collection

I d like to have a collection that defines different brand elements.
When switching between those brands i d like to have my dynamic cms site to have a different font for each brand. Is that possible with native ways of the cms / dynamic elements or maybe only with a js / jq workaround?

Regards
Daniel

e.g. you have a product page, that holds a dynamic collection with porsche and crysler. but

.xyz Domain Names | Join Generation XYZ - should have another font because of its ci definitions than
.xyz Domain Names | Join Generation XYZ


Here is my public share link: LINK
(how to access public share link)

1 Like

I had to use script, but its working …

<script>
var url = window.location.href;
var test = url.substring(url.lastIndexOf('/') + 1);

$('document').ready(function() {
	$.detectfont = function(x) {
		if (test == 'brand1') {
  		$(".css-class-name-of-text").css("font-family", "brand1-font-name");
  	} else if (test == 'brand2') {
  		$(".css-class-name-of-text").css("font-family", "brand2-font-name");
  	}
	}
  $.detectfont();
});
</script>
1 Like