Slightbox CSS Watermark

15 years 11 months ago #62824 by teryaki
Slightbox CSS Watermark was created by teryaki
I have been looking for a way to automatically watermark uploaded images. It seems that the easiest way to go about it would be to define some CSS like this...

[code:1]#watermark_box {
position:relative;
display:block;
}
img.watermark {
position: absolute;
top: 4px;
left: 4px;
}[/code:1]

Then add some HTML something like this...

[code:1]<div id="watermark_box">
<img src="your-image.jpg" alt="Your image"/>
<img src="watermark.png" class="watermark" alt="Watermark image" />
</div>[/code:1]

But when I try adding the code to the pre-existing php...

[code:1] . "<div id="watermark_box"><img src=\"" . $pgitemthumbuserpath . "\" border=\"0\" height=\"$newtn_height\" width=\"$newtn_width\" alt=\"\" title=\"" . $html_pgitemdescription . "\" <img src="watermark.png" class="watermark" alt="Watermark image" /></div>/>"[/code:1]

It breaks my page.

Anyone care to take a crack at helping me make this work? Seems like a lot of people have requested this feature.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.164 seconds

Facebook Twitter LinkedIn