本文介绍了如何使用javascript使文本框中的文本变为粗体移动焦点在它上面?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hi
当使用javascript将标签从它移动到下一个文本框时,如何使文本框中的文本变为粗体?



i有一个文本框如下所示/>


< input type =   text name =   useremail value =   Email ... size =   20 
onfocus = alert(this.value.fontsize(6 )) $ b $bönblur= this.style.background ='red'; this。 style.font-weight ='bold'
/>
< input type = text name = useremail value = 电子邮件... size = 20
onfocus = this.style.background ='#0b385f' $ b $bönblur= this.style.background ='#1a527d' />

< input type = text name = useremail value = 电子邮件... size = 20
onfocus = this.style.background ='#0b385f' $ b $bönblur= this.style.background ='#1a527d' />

< input type = text name = useremail value = 电子邮件... size = 20
onfocus = this.style.background ='#0b385f' $ b $bönblur= this.style.background ='#1a527d' />





i想要从文本框移动焦点时将这些文本框文本设为粗体。



谢谢..

解决方案

Hi How to make a text in textbox bold when moving tab from it to next textbox using javascript?

i have a textbox as below

<input type="text" name="useremail" value="Email..." size="20"
onfocus="alert(this.value.fontsize(6) )"
 önblur="this.style.background  =  'red';this.style.font-weight='bold'"
 />
<input type="text" name="useremail" value="Email..." size="20"
onfocus="this.style.background  = '#0b385f'"
 önblur="this.style.background  =  '#1a527d'" />

<input type="text" name="useremail" value="Email..." size="20"
onfocus="this.style.background  = '#0b385f'"
 önblur="this.style.background  =  '#1a527d'" />

<input type="text" name="useremail" value="Email..." size="20"
onfocus="this.style.background  = '#0b385f'"
 önblur="this.style.background  =  '#1a527d'" />



i want to make these textbox text to bold when moving focus from textbox.

Thanks..

解决方案


这篇关于如何使用javascript使文本框中的文本变为粗体移动焦点在它上面?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-02 09:28