i18next and JQuery doesn't work in form's drop down list -
i using jquery mobile mobile website, , localization using i18next. have issue in form, here :
<form id="form" method="post" action="webservices/action.php"> <select id="subject"> <option value='0' data-i18n="contact.email" selected></option> <option value='1' data-i18n="contact.name"></option> <option value='2' data-i18n="contact.object"></option> </select> </form>
the localization works fine, have desired text displayed. however, first option not displayed , not possible select (it possible select other options). when looking @ select object in javascript, seems correct index selected., therfore ui problem.
i don't have problem when not using i18next.
anyone have idea how fix issue ?
i found workaround. noticed when sent form , reset it, dropdown list correclty displayed. after initializing i18n, used this:
document.getelementbyid("form").reset();
the form displayed correctly.
Comments
Post a Comment