I have a <s:actionmessage />
that displays a message upon successful execution of an action.
success.jsp
:
<s:if test="hasActionMessages()">
<div class="messages justify">
<s:actionmessage />
</div>
</s:if>
CSS:
.messages {
background-color: #80FF80;
border: 1px solid #000000;
width: 600px;
color: #000000;
padding: 0;
margin: 0;
}
.messages li {
list-style-type: none;
padding: 0;
margin: 0;
}
.justify {
text-align: justify;
}
Output:
By default, it appears <s:actionmessage />
, displays a <li>
, so I have modified the CSS to remove its default style.
But, there is still an uneven padding on the left of the div, even with setting to
padding: 0; margin: 0;
.
How to make both sides even?
EDIT: (Inspect Element)
<div class="messages justify">
<ul class="actionMessage">
<li>
<span>
You have successfully changed your password. This is just to make the message long, so it will have to go to the second line of the div.
</span>
</li>
</ul>
</div>