EasyUI
Home
Demo
Tutorial
Documentation
Download
Extension
Contact
Forum
EasyUI Forum
May 05, 2024, 06:41:26 PM
Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News
:
Home
Help
Search
Login
Register
EasyUI Forum
>
General Category
>
EasyUI for jQuery
>
[solved] input (textbox) set focus
Pages: [
1
]
« previous
next »
Print
Author
Topic: [solved] input (textbox) set focus (Read 8065 times)
frankz
Newbie
Posts: 16
[solved] input (textbox) set focus
«
on:
October 31, 2017, 05:39:52 AM »
I have a problem setting focus in textbox in a modal windows form.
the HTML code:
<form id = "ff" method = "post">
<div style = "margin-bottom: 20px">
<input id = "user" type = "text" name = "user">
</ Div>
....
the javascript code:
$ ( '# User'). Textbox ({
label: 'Password:',
labelPosition: 'top',
required: true,
width: 80% ',
});
$ ( '# User'). Textbox.focus ();
but it does not work, where am I wrong?
«
Last Edit: November 18, 2017, 01:39:50 AM by frankz
»
Logged
Pierre
Sr. Member
Posts: 439
Re: input (textbox) set focus
«
Reply #1 on:
October 31, 2017, 06:37:43 AM »
Try this:
$('#User').focus();
or
document.getElementById("User").focus();
Logged
frankz
Newbie
Posts: 16
Re: input (textbox) set focus
«
Reply #2 on:
October 31, 2017, 09:49:29 AM »
I tried the two solutions, but they did not work.
can it depend on other settings?
Logged
tumbas
Newbie
Posts: 5
Re: input (textbox) set focus
«
Reply #3 on:
November 05, 2017, 06:28:27 AM »
try this bro
Quote
$('#user').textbox('textbox').focus();
Logged
frankz
Newbie
Posts: 16
Re:[SOLVED] input (textbox) set focus
«
Reply #4 on:
November 18, 2017, 01:30:41 AM »
i have resolved so:
$('#user').textbox('clear').textbox('textbox').focus();
and the windows:
$('#win').window({
width:300,
height:250,
modal:true,
title:"LOGIN",
collapsible:false,
minimizable:false,
maximizable:false,
closable:false
});
Logged
Pages: [
1
]
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General Category
-----------------------------
=> News
=> General Discussion
=> EasyUI for jQuery
=> EasyUI for Angular
=> EasyUI for Vue
=> EasyUI for React
=> Bug Report
Loading...