Comments (7)
For anyone having this issue more recently, this is now implemented like so: <img data-src="holder.js/100px100?auto">
.
from holder.
Have you tried percentage widths for both dimensions? Something like <div style="width:500px;height:200px"><img data-src="holder.js/100%x100%"></div>
from holder.
Too many unnecessary divs that way for my liking. Normally a responsive image only needs to be declared with:
max-width: 100%;
height: auto;
To fill the width of it's parent container automatically, assuming the image is wide enough, while the height works itself out. I'd rather not have to wrap each image in an extra div to accomplish the same thing.
from holder.
This is now implemented, using the auto
flag on a fluid image, like so: <img data-src="holder.js/100%x100/auto">
from holder.
Edit: sorry, misread the post. Downloaded the new version and it's great, thank you very much!
from holder.
Have you downloaded the latest file?
On Oct 22, 2013, at 4:43 PM, Brad Shaw [email protected] wrote:
I tried that, but it doesn't work. Height stays at whatever you set it to. In your example above the height stays pegged at 100px while the width adapts to the container width.
—
Reply to this email directly or view it on GitHub.
from holder.
Yep, got it and it's working great. Thank you very much!
from holder.
Related Issues (20)
- Support Turbolinks 5 HOT 1
- (angular) binding to data-src HOT 3
- [Enhancement] Diagonal lines/border? HOT 8
- Support outline for rounded corners
- How to make images scaled down? HOT 1
- Image with no text HOT 2
- "size" attribute has no affect when using 100% width HOT 1
- Add support for specified aspect ratios. HOT 1
- holderjs not working inside tinymce [fiddle included] HOT 2
- 100% x 100% giving <svg> error in Chrome Canary Version 69.0.3494.0 (Official Build) canary (64-bit) HOT 1
- Could not set size lesser than certain value HOT 1
- holder.js does not work when the page renders twice in React HOT 14
- Refer to FontAwesome icons by their class names HOT 1
- high cpu usage HOT 2
- Issue with rendering in React using state variables HOT 2
- old dependency version prevent install with engine-strict=true HOT 3
- Need to replace `robloach/component-installer` HOT 3
- yoieh:patch-1
- Holderjs with Vite
- How can I use Holder.js in Next.js App Router?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from holder.