Can you display an image with just CSS? - css

I'm making externally hosted CSS files for use by other people. I want to be able to create a small logo in the bottom left corner that links back to my page. Is this possible using just CSS? I cannot use HTML for the image/link because people can and will remove my credit.

Related

Creating the thumbnails for an image gallery

I am a back-end developer and I'd like to create a little website using angular and boostrap.
I would like to create a galerie, and I have been looking around to see how it's done. I found a correct example on the following link : https://blueimp.github.io/Bootstrap-Image-Gallery/
In that case, the images are taken from flickr api, which sends 2 different pictures (small and large). The small one is the thumbnail, and when you click on it, it opens the large one.
My question is the following one : let's say I have all my images of different sizes, and that I would like to have thumbnails of those (same size, but responsive !) to create my gallery, what would be the way to do that? With css only?
Create parent <div> with fix width then add img inside by applying width:100% on image and height:auto. Please try to implement the example you found and if you find any issues post with your code.

Difference between IMAGE MAPS and CSS SPRITES

I could not find the clear difference between IMAGE MAPS and CSS SPRITES. Both are looking like combining the images in the page into one? So we can reduce multiple requests to the server. So what is the real difference?
Image Map:
A single image in a page, with different areas you can click on, which then have different effects (eg launching different links).
There's a description of this here: http://www.javascriptkit.com/howto/imagemap.shtml
CSS Sprites:
Combining the images behind a number of css classes into a single file to improve performance - eg reducing number of requests and often overall download size.
For example you might combine various border elements of a colorbox dialog into a single image, or combine the clicked and unclicked images for a button.
The best description I've found of CSS sprites is this one: http://css-tricks.com/css-sprites/
An image map is one image that you can turn into an image map and place multiple links on top of the image.
A CSS sprite is one image made up of mutiple images that youy use CSS background positioning to display this reducing http requests.
An Image Map is the definition of coordinates that are lying over the image to be able to react to events on this areas.
a css sprite are two or more images joint in one image.
I know it been asked a year ago, just let me try to explain in own my words.
CSS Sprite is like a single file image repository that you can pull out any portion of it via css and place them individually in arbitrary area in your webpage real estate, while image map (to-url) , as it name suggest is a image that has a clickable area that maps to your target url.

Add weblink as watermark to image

I am presently working for watermarking site and I have done completely and everyting is working fine.Now I would like to add a weblink to image as watermark instead of text.
I have tried by taking a hyperlink and adding to Image but it just draws the text and dosen't add it as a URL.
Is it possible to do so?I so how can I achieve this?
This is how I tried to do it:
pth.AddString(txtLink.NavigateUrl, New FontFamily(DropFont.SelectedValue), 0, Integer.Parse(DropFontSize.SelectedValue), New Point(left, top), StringFormat.GenericTypographic)
Two approaches come to mind:
Use anchor elements - <a> around your images with the appropriate link.
Use image maps with your images.
Images are images - they don't have links embedded in them that you can click on - you need something extra in order to make them clickable.

Various Adobe Fireworks CS4 queries

I am new to Fireworks CS4 and keen to learn to use it right but I am having difficulty understanding the whole slicing and exporting mechanism, so that I can also use in Dreamweaver CS4.
What I have is a header banner image where I also have the name of the site to the left of this header banner.
On this same header image, I want to place two buttons (with rollover effects if possible), to the top right area of the header image, with links to another URL.
Now the things that I am unsure how to do are based on the above description are:
1) How can I make the name of the site section only, to the left of the banner as a link to a url when the user hovers over the name part only, the mouse hand turns into a pointer and gets redirected to url
2) The same goes for the two buttons that I have created as two individual symbols?
3) How can I slice the above two queries, so that I can export into Dreamweaver, so that all the required code comes across with all the desired effects, that is, when previewing in Firefox, all hovering on site name and two buttons work as required?
I am unsure how to slice it? Do I have to assign hotspots to the sections? I am unsure how to export it.
There is a slice layer in Fireworks. It is always the top layer. It lets you draw shapes over parts of your graphic, which show up in translucent green. When you click on one, you have the option of adding a URL and other parameters of a link. At that point, you have the option of exporting as sliced images, an HTML page, etc. If exported as HTML, the images will be contained in anchor tags with the URLs you gave them. Or you can just export the slices and assign the links in Dreamweaver.

Change background of image maps on mouse hover

In my website I have an image as the navigation bar and have created hotspots to link them to different pages. The problem is since the text is a part of the image, I cannot change the style of the text on hover. Whereas I want the text/the hotspot to stand out on mouseover, so I learn the background color could be changed on mouse over. Is that possible? Is there a way to do that in CSS, using the area or maps. If Javascript is to be used, could someone help me out with it.
Is there a reason you've used a single image as the nav bar?
Instead of a single image with hotspots, I'd use an individual image for each navigation link. That way you can easily change the image (or use CSS image positioning) on hover. This is described here:
http://css-tricks.com/video-screencasts/7-three-state-menu/
along with many other places I'm sure.
I don't think it's a good idea to use neither image maps nor individual images.
Instead, use CSS sprites: a single image file, add that as a background image to the menu links, but position the background images differently. See this Line 25 tutorial for more information.

Resources