Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By Jim@drupal.be on
I've used the above snippet to display all users belonging to a certain role.
The user names are longer than the width of the resulting table. Making the table bigger doesn't change a thing because the actual data that goes in the table is cut off like "username..."
Guess i need to change the following code
$output .= theme('table', $header, $rows);
$output .= theme('pager', NULL, 50, 0);
to look like
$output .= theme('wide_table', $header, $rows);
$output .= theme('pager', NULL, 50, 0);
and somehow create a new wide_table function that does the exact same thig but creates an auto-width table.
Anyone got any ideas as where i'm suppossed to find these "theme" functions??
Comments
$output .= theme('table',
$output .= theme('table', $header, $rows, $attributes = array('width' => '250px;'));
Digging into the API and found the above to work. The width is adjusted.
Theme_username seems to be the function cutting off the log usernames.
Copying this fuction to the username.tpl.php file and changed the cott-off value from 20 to 30.
Everything seems to work just fine now.
http://www.activiteitenkalender.be/?q=node/13
There are no stupid questions. Only stupid anwsers.