5

I'm using MVC3 and I would like to set just one single CSS value differently if I am using Firefox. This concerns the paddings on buttons which seems to not be the same across all browsers.

How can I detect if my browser is Firefox.

Hope someone knows the answer.

thanks,

0

1 Answer 1

2

I needed myself a browser detection script, so I found this js script browserDetect.js (Sorry, I didn't find the official project site)

This script let's you manipulate CSS very easily. So if for example you have like:

#my-id { padding: 5px; } 

And in Firefox 4, for instance you want another setting for #my-id, you can do something like this:

.browserFirefox4 #my-id { padding: 10px; } 

And it detects the majority of the browsers.

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.