Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/86.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/jsf/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
使用jquery css进行命令链接_Jquery_Jsf_Hover_Slide_Jquery Hover - Fatal编程技术网

使用jquery css进行命令链接

使用jquery css进行命令链接,jquery,jsf,hover,slide,jquery-hover,Jquery,Jsf,Hover,Slide,Jquery Hover,代码如下 我面临什么问题?我希望jquery按钮幻灯片能够用于jsf代码中的命令链接。我尝试了各种选择,但没有得到适当的输出。 Jquery: $(函数(){ $('.button_bLeft')。悬停( 函数(){ var$this=$(this); var$slidelem=$this.prev(); $slidelem.stop().animate({'width':'225px'},300); $slidelm.find('span').stop(true,true.fadeIn();

代码如下 我面临什么问题?我希望jquery按钮幻灯片能够用于jsf代码中的命令链接。我尝试了各种选择,但没有得到适当的输出。 Jquery:


$(函数(){
$('.button_bLeft')。悬停(
函数(){
var$this=$(this);
var$slidelem=$this.prev();
$slidelem.stop().animate({'width':'225px'},300);
$slidelm.find('span').stop(true,true.fadeIn();
$this.addClass('button_c');
},
函数(){
var$this=$(this);
var$slidelem=$this.prev();
$slidelem.stop().animate({'width':'70px'},200);
$slidelem.find('span').stop(true,true.fadeOut();
$this.removeClass('button_c');
}
);
});
Html代码-

        <a class="button_aLeft"><span>Sign In</span></a>
        <a class="button_bLeft">Sign</a>
登录
签名
JSF:


您的JSF代码没有任何意义<代码><代码>?你读书吗

在任何情况下,前提是你确实在问以下问题:

如何使用JSF
,最终生成以下HTML输出

<a class="button_aLeft"><span>Sign In</span></a>
<a class="button_bLeft">Sign</a>
登录
签名
那么答案是:

<h:commandLink styleClass="button_aLeft"><span>Sign In</span></h:commandLink>
<h:commandLink styleClass="button_bLeft">Sign</h:commandLink>
登录
签名

这是生成的所有html吗?你能发布完整的HTML吗?我的意思是,有名单的地方,桌子。。。动画代码看起来不错,问题只在JSF部分,因为JQuery只影响HTML生成的代码
<a class="button_aLeft"><span>Sign In</span></a>
<a class="button_bLeft">Sign</a>
<h:commandLink styleClass="button_aLeft"><span>Sign In</span></h:commandLink>
<h:commandLink styleClass="button_bLeft">Sign</h:commandLink>