Click here to Skip to main content
15,886,519 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hey guys, we have recently been updating our application, we added some jquery and some new css styles. The wierd thing that is happening is that all the images are getting set really small for some reason. I can't find anywhere in the newly added code that is doing this, there's no refrence to images in these files but they are obviously the issue. If I set the sizes in a new css file the are fine. There are 100's of pictures throughout the application so this is not a practical solution, if anyone can help it will be very much apreciated, cheers guys.
Posted

1 solution

This problem may be caused by CSS Cascade. Means it can easily happen that you have same class(or ID) being reset some where on the same CSS file or in InLine CSS on html page.

Also two CSS files that you are linking to a page can have same class name. If this is the case then last file will reset the previous style on any element. Try changing the order of the CSS files and check the result.

You can check the applied css on any element in the page using FireBug in firefox or in Google Chrome just right click and click on view element to check the CSS.

I am sure this way you can get your mistake and fix that.

Thanks and please reply if this helps you.
 
Share this answer
 
Comments
frostcox 23-Oct-12 3:44am    
Hey thanks for your reply, I have checked the files and there are no duplicate class names in the CSS files. Our application can only be ran on IE so I cannot use Firebug. This is a very strange one. Any more ideas? Thanks very much.
frostcox 9-Nov-12 4:53am    
Hey sorry for not accepting your solution sooner, you were right, it turns out that one of our developers had hardcoded the image tag values so they were getting overwritten thank you so much.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900