Align
serpisor2 - March 21, 2008 - 23:32
| Project: | jRating |
| Version: | 5.x-1.0 |
| Component: | Code |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Description
Hello,
I am having a little problem with jrating involving alignment in views tables. All my table views have center alignment, but jrating seems to not obey this. I looked at the html and it is like this:
<td class="view-field view-field-jrating-votingapi-cache-value"><span class="rating" id="rating-mean-296"><div class="star avg on"><a style="width: 100%;" onclick="return false;"> </a></div>
I then tried to add the following to my theme style.css:
.rating {
text-align:center;
}
.view-field-jrating-votingapi-cache-value {
text-align:center;
}But nothing changed... After that i tried the jrating.css where i added text-align:center; to all classes and remove the floats (just to test) and still i couldn't get a center alignment. I also added text-align:center; in the jrating.module like so:
<?php
$stars[] = '<div class="star avg on"><a style="width: 100%; text-align:center;" onclick="return false;"> </a></div>';
$stars[] = '<div class="star avg on"><a style="width: 50%; text-align:center;" onclick="return false;"> </a></div>';
$stars[] = '<div class="star avg"><a style="width: 100%; text-align:center;" onclick="return false;"> </a></div>';
?>
Again, no success. I am really new to css so if someone could point me in the right direction i'd greatly appreciate it.
P.S. I am using the VotingAPI: Average vote field in views.
