using javascript to get the type attribute of an input where type='time' returns "text"

REOPENED
Unassigned

Status

()

P5
normal
REOPENED
5 years ago
4 months ago

People

(Reporter: jezra, Unassigned)

Tracking

({dev-doc-needed})

23 Branch
ARM
Gonk (Firefox OS)
dev-doc-needed
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

5 years ago
User Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.57 Safari/537.36

Steps to reproduce:

1. create an html page containing <input type='time' id='time_input'>
2. run some javascript to check the input's 'type' attribute, Ex: 
var input = document.getElementById('time_input');
console.log(input.type);


Actual results:

"text" was printed to the console


Expected results:

"time" should have been printed to the console

Comment 1

5 years ago
Attach a testcase as .html, please.
Flags: needinfo?(jezra)
Keywords: testcase-wanted
(Reporter)

Comment 2

5 years ago
Created attachment 797270 [details]
test file for reproducing the bug
Flags: needinfo?(jezra)

Updated

5 years ago
Attachment #797270 - Attachment mime type: text/plain → text/html

Updated

5 years ago
Keywords: testcase-wanted

Updated

5 years ago
Component: Untriaged → DOM: Core & HTML
Product: Firefox → Core
Version: unspecified → 23 Branch

Updated

5 years ago
Status: UNCONFIRMED → NEW
Ever confirmed: true

Comment 3

5 years ago
FYI
dom.experimental_forms = true fixes.
Yep.  This is the behavior the spec requires if time inputs are not supported yet.  You'd get the same with <input type="somethingILike">.
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 825294
(Reporter)

Comment 5

5 years ago
I first notices this bug on FireFox OS where the input behaves as a time input but does not return the proper type when using javascript.
(Reporter)

Comment 6

5 years ago
While this issue is similar to 825294, I found this issue while using the mobile Firefox browser on FireFoxOS and therefor I consider this to be a mobile browser issue. It should be noted that this issue does not exists on firefox browser for Android.
Status: RESOLVED → REOPENED
OS: Linux → Gonk (Firefox OS)
Hardware: x86_64 → ARM
Resolution: DUPLICATE → ---
Last I've heard, "dom.experimental_forms" should be set to "true" in Firefox OS and Firefox for Android. Did that change?
Flags: needinfo?(jonas)
Not to my knowledge. I think we're still supporting most form controls in B2G.

Checking with Vivien that that should still remain true.
Flags: needinfo?(jonas)

Comment 9

5 years ago
(In reply to Jonas Sicking (:sicking) from comment #8)
> Checking with Vivien that that should still remain true.

What's the result?
Vivien, any reason that <input type=time> shouldn't work in B2G these days?
Flags: needinfo?(21)
(In reply to Jonas Sicking (:sicking) Please ni? if you want feedback from comment #10)
> Vivien, any reason that <input type=time> shouldn't work in B2G these days?

Nothing I know about. Sounds like the preference has landed in august though (http://hg.mozilla.org/mozilla-central/rev/38190b5c8d29) so I wonder if this could be that the  FirefosOS version used to check is too old.

Jezra, cwhich version of FirefosOS are you using?
Flags: needinfo?(21) → needinfo?(jezra)
(Reporter)

Comment 12

5 years ago
I am using version 1.0.1.0 on a ZTE Open
Flags: needinfo?(jezra)
(In reply to jezra from comment #12)
> I am using version 1.0.1.0 on a ZTE Open

Makes sense then. The fix has landed only on 1.2 iirc.
Argh. The patch has landed in August but 2012. Maybe there is something else here.

Updated

5 years ago
Keywords: dev-doc-needed
https://bugzilla.mozilla.org/show_bug.cgi?id=1472046

Move all DOM bugs that haven't been updated in more than 3 years and has no one currently assigned to P5.

If you have questions, please contact :mdaly.
Priority: -- → P5
You need to log in before you can comment on or make changes to this bug.