× Got a CSS, HTML or webdesign question? Ask it here!

Shrink wrapping images on our sites.

2 years 3 weeks ago - 2 years 3 weeks ago #14947 by TournamentWear
I understand imitation is a form of flattery, however, seeing our designs on overseas companies websites stinks. Is there any way you can put in the code from your end to shrink wrap all of our images? I believe all of us would be grateful. Or at least tell or show us how to do this from our end. Here is the code.

Laugh maniacally at frustrating one more image thief in the world!
Here is the <table> HTML Code I used to shrink wrap the above image. I’ll go through the code line by line and then give you the entire code below. If you are already an HTML master, feel free to skip the explanation and go straight to the complete code at the bottom of the page:

<table style=”display: inline;” border=”0″ cellspacing=”0″ cellpadding=”0″><tbody> <tr height=”199″>

The first line of the code sets the table border, cellspacing, and cellpadding to “0” so there is no space around the two images. Remember to set the <tr height> to the size of the picture you are trying to protect.

<td style=”background-image: url( the-image-that-you-are-trying-to-protect.jpg );” width=”300″>

This is the code for the image that you are trying to protect. We are telling it to be the bottom image in our image sandwich. Remember to change the <width> tag here to match the width of your actual image.

<img title=”Name-of-your-protected-image” src=”the-generic-file-name-of-your-clear-image.gif” alt=”” width=”300″ height=”180″ />

</td> </tr> </tbody> </table>

This final bit of code puts the second “clear” image on top of the previous image creating our completed image sandwich. Notice that the <height> tag here doesn’t match up exactly with the height of the original image. Sometimes this adjustment is necessary in order to avoid a “tiling” effect of the original image. Depending upon your image, you may want to start with the original height and then make it smaller as necessary.



Read more at: skinnyartist.com/how-to-shrink-wrap-your-images/
The following user(s) said Thank You: EvaK

Please Log in or Create an account to join the conversation.

Time to create page: 0.122 seconds
Powered by Kunena Forum

Latest from our blog

DecoNetwork 8 - Update 3: GDPR Compliance (+56 tasks completed)

DecoNetwork 8 - Update 3: GDPR Compliance (+56 tasks completed) In this release, DecoNetwork updated its Privacy Policy and Terms of Use, effective May 23, 2018. These changes were made primarily in preparation...Read More

This Week in Catalog - May 18, 2018

This Week in Catalog - May 18, 2018 I have two big announcements to make in regards to the DecoNetwork catalogs. We read and listen to your complaints and suggestions. Recently, I...Read More

DecoNetwork 8 - Available Now!

DecoNetwork 8 - Available Now! After an incredible amount of work in design, development, and testing, DecoNetwork 8 is here! With version 8, we recommitted ourselves...Read More

This Week in Catalog: May 11, 2018

This Week in Catalog: May 11, 2018 Lately, we've been getting a lot of new products in each week. More than is typical. All those new products (mostly in the S&S Activewear...Read More

DecoNetwork 8 - Update 2 now available: SEO Improvements and more (+75 tasks implemented)

DecoNetwork 8 - Update 2 now available: SEO Improvements and more (+75  tasks implemented) DecoNetwork 8 was released just ten days ago, but we have already a second update (8.002) available for you with many improvements and fixes...Read More