hide alt tag in firefox

neeraj picture neeraj · Oct 1, 2012 · Viewed 11.8k times · Source

As per the default behavior, alt attribute is rendered first time just before the image rendering. I am displaying 25 images in a grid so it looks bit awkward as all alt attributes are displayed first.

Is it possible to hide alt attributes in Firefox?

Note: alt attributes contain dynamic names in my case.

Answer

user unknown picture user unknown · Jan 22, 2014

After trying all the other methods here, I found this method works best which makes the text transparent until the image loads:

.yourClass img {
    color: transparent;
}