i specifically say "percentage of itself" because by default,
width=50%
...will make it 50% of the browser window.
what i really want to do is make an image thinner. don't ask why. will this be possible?
thank you.
i specifically say "percentage of itself" because by default,
width=50%
...will make it 50% of the browser window.
what i really want to do is make an image thinner. don't ask why. will this be possible?
thank you.
thinner??
say you have a table and the tables width is 100(width=100) and inside that table you habe a image and inside that img tag you have 50%(img src="" width=50%) but when you see this in plain veiw it will show half of what the table is... understand..
example..
table=100
img width=50%
divided=the width will equal 50
another example....
table=240
imd width=20%
divided=the width will equal 12
same with height...
I hope this is what you want..
Hey new design new look, goto xudas for personal webdsign help..(:
Well, there's no way to make it a percent of itself with a simple number.
Just do some math on the dimensions.
You could use Javascript or PHP to generate this dynamically, but it would be a good bit of work.
something like
image.width = image.width/2;
But that would mean you have already set image as that element on the page.
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
actually, i think i might have something working. i was going to try something with tables awhile ago, but figured it wouldn't work.
not so skilled with either js or php, and i don't want to use any fixed numbers as i'm going to be using this for multiple pages for different sized images.
like i was saying, i think i have something working with tables. if you don't set table width or height, it'll default to whatever the original image dimensions are. then within the img tag, denote the width and height (in percent), and it'll make it a percent of what the table is. the table won't "shrink" to the newly resized image or anything.
did not realize this would work, but it does.
ImageMagick:Code:prompt$ convert -sample 50%x100% image.png image-thin.png
Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!
Bookmarks