I'm trying to adjust the column width with the following work around, but I can't seem to get it to work. Nothing is changing. I'm using Version 1.92+ Build 120822. Here is the work around:
docs.limesurvey.org/tiki-index.php?page=...lumn_widths_in_array
Here is what I put in the source of the question, with question id Q1. I removed the onload function, since I read that it's no longer necessary, but I did try it that way first, exactly as written in the work around. What am I doing wrong?
<script>
jQuery(document).ready(function() {
// Get rid of all the widths that the API imposes
$( 'div#questionQ1 table.question col' ).attr('width', '');
$( 'div#questionQ1 table.question thead td' ).attr('width', '');
// Define a width for the question table so we can do so for its children
// NOTE: Keep this to 95% or less so IE will behave
$( 'div#questionQ1 table.question' ).attr('width', '95%');
// Define the column widths
// Add or remove columns and adjust widths as necessary but widths should add up to 100%
// NOTE: Columns must be sequentially numbered starting at 0 - eg, td:eq(0), td:eq(1), td:eq(2).....
$( 'div#questionQ1 table.question tbody th:eq(0)' ).css({ 'width':'60%' }); // Answer text column
$( 'div#questionQ1 table.question tbody td:eq(0)' ).css({ 'width':'20%' }); // First answer column
$( 'div#questionQ1 table.question tbody td:eq(1)' ).css({ 'width':'20%' }); // Second answer column
// Push the text input widths to 95% of their parent containers
$( 'div#questionQ1 table.question input[type="text"]' ).css({ 'width':'95%' });
// Align the answer text - feel free to experiment
$( 'div#questionQ1 table.question tbody th' ).css({'text-align':'center'});
});
</script>