Ajax Talk - Asynchronous javascript and xml discussion board
 FAQ   Search    Usergroups      Register   Profile   Check your messages   Log in 
Signup now to enjoy a range of free membership advantages !!
Ajax Talk - Moderators Wanted
How to prevent images posting bigger than 480px width

 
Post new topic   Reply to topic    Ajaxtalk.com Forum Index -> XML
View previous topic :: View next topic  
Author Message
deejay
Forum Assistant
Forum Assistant


Joined: 17 May 2006
Posts: 78
Location: Netherlands

PostPosted: Thu Jul 06, 2006 3:20 pm    Post subject: How to prevent images posting bigger than 480px width Reply with quote

add this to your stylesheet in wordpress, or somewhere else,

this works for the default template;

Code:
.entry img {max-width:480px;}
.entry img {width: expression(this.width > 480 ? 480: true);}

this works for the pool template

Code:
p img  {width: expression(this.width > 533 ? 533: true);


(533 pix width)

hope this helps.
_________________
please correct me if i am wrong
seo-expertglobalwarming
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Snyke
Forum Assistant
Forum Assistant


Joined: 20 Jun 2006
Posts: 87
Location: Zurich

PostPosted: Sun Aug 06, 2006 12:28 pm    Post subject: Reply with quote

Is this standard CSS?
_________________
[::[ Snyke.net ]::]
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
admin
Assistant Forum Supervisor
Assistant Forum Supervisor


Joined: 29 Oct 2003
Posts: 154

PostPosted: Mon Aug 07, 2006 7:06 am    Post subject: hehe Reply with quote

Hi Snyke,

You mean if it is not XML ?

I think it is standard css although its not common practice.

Rgds, DJ
Back to top
View user's profile Send private message
Snyke
Forum Assistant
Forum Assistant


Joined: 20 Jun 2006
Posts: 87
Location: Zurich

PostPosted: Mon Aug 07, 2006 10:59 am    Post subject: Reply with quote

Guess what: it is not standard!
It's just a cheap workaround added by Internet Explorer in version 5.0 to correct some problem IE had with max-width...
Oh how I hate IE...

See CSS Validator here
_________________
[::[ Snyke.net ]::]
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
admin
Assistant Forum Supervisor
Assistant Forum Supervisor


Joined: 29 Oct 2003
Posts: 154

PostPosted: Mon Aug 07, 2006 11:08 am    Post subject: hehe Reply with quote

Hi Snyke,

It cheap but i like it because when you are not in control of which images are posted on your site, it automatically resizes.

and yes the first line is (.entry img {max-width:480px;} ) is for all 'normal' browsers.

the hack is for ie.

so much for the valid css link Sad Sad

i wish firefox had the marketshare of ie

rgds
Back to top
View user's profile Send private message
Jesdisciple
Frequent Poster
Frequent Poster


Joined: 20 Oct 2007
Posts: 36
Location: Tejas

PostPosted: Sun Oct 21, 2007 8:34 pm    Post subject: Reply with quote

I think you could generate equivalent standard CSS with PHP (that is, if you can access the width of an image in PHP). See http://jesdisciple.wordpress.com/2007/09/14/html-isnt-phps-only-application/.
_________________
In ALL things, strive for ><>,
Chris
Back to top
View user's profile Send private message Visit poster's website AIM Address MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Ajaxtalk.com Forum Index -> XML All times are GMT
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
 Advertisements
 XML & Copyright Notice 
    


Powered by phpBB © 2001, 2005 phpBB Group

What is according to Wikipedia: Ajax Web2.0 XML E4X


Link to our site:

  


del.icio.us digg spurl wists simpy newsvine blinklist furl blogmarks yahoo! myweb smarking ma.gnolia segnalo reddit fark technorati cosmos


Normal Bookmark


Partner Button Links:
Codecrunch.com: Webmaster Tutorials    One Ajax


Partner Text Links:
quomon | web20log | ajaxmatters | tableless | 456bereastreet | music charts | gift ideas | competitions | free xbox 360 | link trade ?


Credits:
it consultancy & project management lead generation zoekmachine optimalisatie steal these buttons seo expert