-
1. Re: a4j:commandbutton selected background color change with control skinning
ilya_shaikovsky Mar 10, 2010 2:54 AM (in response to jsfgeeks)We using bg-image in skinning. So if you need to work with bg-color - you should define also bg-image as none. -
2. Re: a4j:commandbutton selected background color change with control skinning
jsfgeeks Mar 11, 2010 12:35 AM (in response to ilya_shaikovsky)hello,
thanks for reply.
actually i want to set background-image for button and i have successfully set background image for button. but problem is button text wont display if i set custom background-image.
<a4j:commandButton value="Say Hello" type="submit" image="graph/hori_bg1.jpg" style="width:100px;top: 140px; left: 410px; position: absolute;height:26px" ></a4j:commandButton>
-
3. Re: a4j:commandbutton selected background color change with control skinning
nbelaevski Mar 11, 2010 5:22 AM (in response to jsfgeeks)Hi,
You are not assigning background-image correctly. "image" attribute is not intended for this, use CSS style or class.
-
4. Re: a4j:commandbutton selected background color change with control skinning
jsfgeeks Mar 12, 2010 12:04 AM (in response to nbelaevski)hi,
thanks
i have tried as you suggested, but still not successfull.
<a4j:commandButton value="hello" styleClass="btn" > Say Hello</a4j:commandButton>
<style type="text/css">
.btn{
background-image: url('graph/hori_bg1.jpg');
width:100px;top: 140px; left: 410px; position: absolute;height:26px
}
</style> -
5. Re: a4j:commandbutton selected background color change with control skinning
nbelaevski Mar 12, 2010 4:38 AM (in response to jsfgeeks)It should work. Check what's wrong with your styling - maybe incorrect placement for style tag? -
6. Re: a4j:commandbutton selected background color change with control skinning
jsfgeeks Mar 17, 2010 6:54 AM (in response to nbelaevski)thanks,my code is like below, but still i am not getting btn background-image with text.
<f:view locale="#{skinBean.currentlang}">
<html>
<a4j:loadBundle basename="com.myapp.struts.ApplicationResource" var="loginpg" />
<head>
<style type="text/css">
.btn{
background-image: url('graph/hori_bg1.jpg');
width:100px;top: 140px; left: 410px; position: absolute;height:26px;
}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title>welcome</title>
</head>
<body bgcolor="${skinBean.pagebackground}">
<h:form id="form">
<a4j:commandButton value="hello" styleClass="btn" > </a4j:commandButton></h:form>
</body>
</html>
</f:view> -
7. Re: a4j:commandbutton selected background color change with control skinning
ilya_shaikovsky Mar 17, 2010 11:53 AM (in response to jsfgeeks)Check please with fireBug backGround image applied.. it could be the problems of absolute path to the image..