I am having to place the css for this in my style's common.css because it want work in the html replacement.
My question... Is there a way to make the css work in the html replacement or will I have to create and extension for this?
BBCode usage
Code: Select all
[flip={URL1},{NUMBER1},{NUMBER2}]{URL2}[/flip]
Code: Select all
<style>
.flip-bbcode {
display: inline-block;
}
.flip-bbcode .flip-box {
background: transparent;
width: 100%;
height: 100%;
perspective: 1000px;
}
.flip-bbcode .flip-box-inner {
display: flex;
position: relative;
width: 100%;
height: 100%;
align-items: center;
justify-content: center;
text-align: center;
transition: transform 1.0s;
transform-style: preserve-3d;
}
.flip-bbcode .flip-box:hover .flip-box-inner {
transform: rotateX(180deg);
}
.flip-bbcode .flip-box-front, .flip-bbcode .flip-box-back {
position: absolute;
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
}
.flip-bbcode .flip-box-back {
transform: rotateX(180deg);
}
</style>
<div class="flip-bbcode" style="width: {NUMBER1}px;height: {NUMBER2}px">
<div class="flip-box">
<div class="flip-box-inner">
<div class="flip-box-front">
<img src="{URL1}" alt="" />
</div>
<div class="flip-box-back">
<img src="{URL2}" alt="" />
</div>
</div>
</div>
</div>
Code: Select all
Flip image: [flip=front-image-url,width-number,height-number]back-image-url[/flip]