Bug Tracker

Changes between Version 12 and Version 14 of Ticket #9106


Ignore:
Timestamp:
Jun 3, 2011, 10:39:28 AM (9 years ago)
Author:
Rick Waldron
Comment:

@anonymous the problem with this is that when an end developer changes the _default_ display style property of an element, there is _NO_WAY_ to find out what it should really be without creating an iframe and appending a temporary test element to that iframe. We've been down this road and explored a breadth of potential solutions.

The fact is that changing the default display of an element as shown in the given example is a broken approach and in general a bad practice.

You could achieve exactly the same effect by using a class:

html:

<html class="toggler">
    <body>
        test
    </body>
</html>

css:

.toggler {
    display: none;
}

jquery:

$('html').show();

See: http://jsbin.com/udaso4

I move to close as invalid.

Legend:

Unmodified
Added
Removed
Modified