linbo
linbo

Reputation: 2431

css display:none doesn't work on android2.1 emulators webview

My HTML hidden some element using CSS display:none, and I render HTML in Webview, hidden elements still show up on Android 2.1 emulators.

Test on android 2.2 / 4.0 emulators, it works fine.

Anyone know the solution?

CSS file content:

.hidden{
display:none;

}

and add class for the hidden element

<input> type="text" class="hidden" id="uid" name='uid'></input>

Upvotes: 0

Views: 904

Answers (1)

Knu
Knu

Reputation: 15134

You should use a self-closing tag, " instead of ' and remove that > which close the tag prematurely.

<input type="text" class="hidden" id="uid" name="uid" />

Upvotes: 2

Related Questions