URLやコードをコピーさせたいときなど、テキストボックスを選択した瞬間に、テキストを全選択状態にする。
$(document).ready(function(){
$("#textid").click(function(){
$(this).select();
});
});
<input type="text" id="textid" value="Copy this text please." />
Go to list of users who liked
More than 5 years have passed since last update.
URLやコードをコピーさせたいときなど、テキストボックスを選択した瞬間に、テキストを全選択状態にする。
$(document).ready(function(){
$("#textid").click(function(){
$(this).select();
});
});
<input type="text" id="textid" value="Copy this text please." />
Register as a new user and use Qiita more conveniently
Go to list of users who liked