HTML Tutorial


 Forum HomeForum Home   FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
RegisterRegister - Not registered yet? Got something to say? Join HTML Code Tutorial!
Image rescaling for large images only
Post new topic   Reply to topic    HTML Help Forum Index -> CSS
View previous topic :: View next topic  

About this question...
Phew... thats a hard one, your on your own form here
0%
 0%  [ 0 ]
Come on!! Even a kid could do that!
100%
 100%  [ 1 ]
Total Votes : 1

Author Message
Daniël



Joined: 31 Mar 2005
Posts: 9

PostPosted: Thu Dec 01, 2005 4:15 am     Image rescaling for large images only Reply with quote

Hi,

I think I want the impossible, but do you think it is possible to only resize large images, eg. the ones which are to big for the screen (or CSS-box), and at the same time leave the smaller images untouched?

In our wiki people can add pictures, and it would be nice if they would be rescaled when they are too large, but pictures which are relatively small will get extremely strange when resized.

Compare for example http://wikimaas.org/cgi-bin/wiki.pl/2005-12-01_Gonzo and http://wikimaas.org/cgi-bin/wiki.pl/2005-11-30_workshop_acrobatics

I think I need some javascript-css merger which decides on the image classe according to the specs of the image? Would that be possible?

Daniel
Wikimaas
Corey Bryant



Joined: 15 May 2004
Posts: 8154
Location: Castle Rock CO USA

PostPosted: Thu Dec 01, 2005 9:19 am     Reply with quote

ASP has components caled csImage and ASPJPG which can re-size image(s) on the server according to the code. I am sure there are PHP codes as well to accomplish this.
supak0ma



Joined: 17 Dec 2005
Posts: 3

PostPosted: Sat Dec 17, 2005 9:08 am     Reply with quote

yep, it can be easily done in PHP, check out PHP image functions.
Daniël



Joined: 31 Mar 2005
Posts: 9

PostPosted: Tue Jan 03, 2006 8:30 am     Reply with quote

OK, the solution is:
Code:
 max-width:80%;

Works flawless, except ofcourse in IE, but that doesnt stop us, right?
Corey Bryant



Joined: 15 May 2004
Posts: 8154
Location: Castle Rock CO USA

PostPosted: Tue Jan 03, 2006 8:44 am     Reply with quote

Keep in mind that is not reducing the size though, only dimensions
Display posts from previous:   
Post new topic   Reply to topic    HTML Help Forum Index -> CSS All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
HTML Help Archive
Powered by phpBB © 2001, 2005 phpBB Group
 
HOSTING / DESIGN
MAKE MONEY

Home
  |   Tutorials   |   Forum   |   Quick List   |   About
Copyright ©1997-2002 Idocs and ©2002-2007 HTML Code Tutorial