Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1034429
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T14:23:26+00:00 2026-05-16T14:23:26+00:00

In my CSS, I’m currently using this: img.info { max-width: 620px; max-height: 800px; }

  • 0

In my CSS, I’m currently using this:

img.info {
    max-width: 620px;
    max-height: 800px;
}

Unfortunately, when my image is smaller than max-width and max-height, it gets upscaled. I thought the standard behavior was that no scaling would occur, but apparently, this is not the case. Is there any way to prevent the image from upscaling?

EDIT: I found the source of the problem, it lies in a totally different part of my program. The code I posted above works just fine. Sorry for this unnecessary post!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T14:23:26+00:00Added an answer on May 16, 2026 at 2:23 pm

    It works just fine with the following minimalist example:

    <style>
        img.a {
            max-width: 640px;
            max-height: 640px;
        }
    </style>
    
    <img src="(my local image file)" class="a">
    

    The image doesn’t get scaled up. Of course, it does if I also add width and height attributes. Therefore, check if you have any other CSS properties that might apply to your image. You can use Firebug to find out exactly which CSS properties apply to your image.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

// CSS #popupUser{width:180px; height:180px; position:absolute; background:#FFFFFF; border:#000000 2px solid; display:none;} .viewUser{width:173px; float:left; padding:10px; margin-left:20px;
My css looks like this; p:not(.dummy):after { content: url(../../irhiddenchars/img/afterimage_9x9.gif); } I wish to take
My CSS Sprite here The problem is that the image changes position even when
Odd CSS behavior. When i set the visited color using CSS(a.nav:hover as below example)
CSS & html id0 is the class for the div that's got background as
CSS allows an HTML element to have multiple classes: <div class=cat persian happy big>
CSS #web { position:absolute; left:26%; top: 60%; HTML <div class=web> HI </div> I don't
CSS decimal list style type, the hanging number doesnt have the same baseline as
In CSS, how do I achieve the following layout? xxxxxxxxxxxxxR1xxxxxxxxxxxxx xxxxxxxxxxxxxR1xxxxxxxxxxxxx xxxxxxxxxxxxxR1xxxxxxxxxxxxx xR2.1x xxxxxxxxxR2.1xxxxxx
Can css be applied to controls of the page.aspx? To anything and everything?

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.