Skip to content

Commit

Permalink
tag hidden attribute now works
Browse files Browse the repository at this point in the history
Might have to come back to this and update,
since hidden attribute normally doesn't take a value.
Maybe will hard code type="hidden"
  • Loading branch information
w00fpack committed Nov 25, 2021
1 parent 11577dd commit afdecdb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/form.cc
Original file line number Diff line number Diff line change
Expand Up @@ -453,6 +453,11 @@ void Html_tag_open_input(DilloHtml *html, const char *tag, int tagsize)
name = a_Html_get_attr_wdef(html, tag, tagsize, "name", NULL);
type = a_Html_get_attr_wdef(html, tag, tagsize, "type", "");

if (a_Html_get_attr(html, tag, tagsize, "hidden")) {
// TODO: set type to 'hidden' directly, since I don't think attribute is used
type = a_Html_get_attr_wdef(html, tag, tagsize, "type", "hidden");
}

init_str = NULL;
inp_type = DILLO_HTML_INPUT_UNKNOWN;
if (!dStrAsciiCasecmp(type, "password")) {
Expand Down

0 comments on commit afdecdb

Please sign in to comment.