I got to go to some Web sites that I manage, and thumbnail images (which may include the lightbox or Fansiboks ), Lines are of great size: I have no exemption on the full path (many people posting pages again) or shortening file names (there are so many pictures in it), there The path is not It would be easy to do with jQuery - for example ... However, This is just a link to copy Yvhar - you also should see your lightbox code works, it If you want to do this in another way (only on the link), I can do something when the page loads. However, it does not appear for every
& lt; A href = "http://www.site.com/images/this-would-be-the-picture-we-want-x-treat-size.jpg" & gt; & Lt; Img src = "http://www.site.com/images/this-would-be-the-picture-we-want-x-plus-image.jpg" "width = 200> gt; & lt; / A & Gt;
$ ('img') .click (function () {window.location.href = $ (this) .attr ('src');});
& lt; a & gt; is links can be used as a trigger that can bypass using up .
$ (document) Ready (function () {$ ('one') Each (function () {$ (this) .append ('& lt; img src = "' + $ (this) .attr ('href') + 'width =" 200 "& gt;');}) ; });
& lt; A & gt; will address the link so that you want to use a class to trigger this behavior.
Sunday 15 August 2010
html - CSS or jQuery to cut down on matching A HREF and IMG SRC? -
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment