JavaScript
Article
By Sam Deering

jQuery Mobile 2 fields on one line example

By Sam Deering

Just logging some code for getting two jquery mobile form inputs on one line.

Should look something like this:

Image

--ADVERTISEMENT--

HTML

*First Name: *Last Name:

CSS

/* register fields span 2 */
.halffield span.label {
    width: 120px !important;
    display: inline-block;
    margin-left: 15px;
}
.halffield input {
    width: 240px !important;
}
.halffield input:last-child {
    margin-right: 10px;
}
Recommended
Sponsors
The most important and interesting stories in tech. Straight to your inbox, daily. Get Versioning.
Login or Create Account to Comment
Login Create Account