Issue Details (XML | Word | Printable)

Key: MDL-13410
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Urs Hunkler
Reporter: Howard Miller
Votes: 0
Watchers: 1
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle

Course view misaligned

Created: 11/Feb/08 08:44 PM   Updated: 13/Aug/09 03:10 AM
Return to search
Component/s: Themes
Affects Version/s: 2.0
Fix Version/s: None

File Attachments: None
Image Attachments:

1. Picture 3.png
(64 kB)
Issue Links:
Dependency
 

Participants: Gareth Barnard, Howard Miller, Tim Hunt and Urs Hunkler
Security Level: None
Affected Branches: MOODLE_20_STABLE


 Description  « Hide
Tried in Custom Corners, Standard and Formal White. Course view is all over the place, see attached screendump for example. Tested on both Firefox and Safari on a Mac.

 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Tim Hunt added a comment - 03/Feb/09 04:56 PM
I think this was caused by work on MDL-9306.

Gareth Barnard added a comment - 05/Aug/09 05:54 AM
Hi,

In trying to solve a simar issue with my course format 'topcoll' for Moodle 2 - as I have had to reapply my changes to the topic format's format.php and use, so I found a website:

http://css.maxdesign.com.au/floatutorial/tutorial0916.htm

After a bit of testing, realising that the web browser needed something more to push everything to the right to fill width for the <li> container, so I added:

echo '<div style="clear: both; margin: 0;height: 0px;"></div>';

just after the <li> and just before the </li> in format.php, around lines 178 and 245 respectively in version 1.102

e.g:

echo '<li id="section-'.$section.'" class="section main'.$sectionstyle.'" >'; //'<div class="left side"> </div>';

echo '<div style="clear: both; margin: 0;height: 0px;"></div>';
echo '<div class="left side">'.$currenttext.$section.'</div>';
// Note, 'right side' is BEFORE content.

and

if ($PAGE->user_is_editing()) { print_section_add_menus($course, $section, $modnames); }
}

echo '</div>';
echo '<div style="clear: both; margin: 0;height: 0px;"></div>';
echo "</li>\n";

respectivly.

I have tested on Firefox 3.5.2 and IE 8 - on which compatibility mode shows more space, but could it be a possible part solution which could then be fully put in css to make the code shorter?

Cheers,

Gareth


Gareth Barnard added a comment - 13/Aug/09 03:10 AM
Hi,

Working on the similar issue with my format, I have been able to sort things out from the information found on:

http://css-tricks.com/all-about-floats/
&
http://perishablepress.com/press/2008/02/05/lessons-learned-concerning-the-clearfix-css-hack/

Where I then implement the following css:

li.section:after { visibility: hidden; display: block; font-size: 0; content: " "; clear: both; height: 0; }

li.section {
display: inline-block;
padding: 0 0;
width: 100%;
}
/* start commented backslash hack */

  • html li.section { height: 1%; }
    li.section {
    display: block;
    width: 100%;
    }
    /* close commented backslash hack */

Which gets a near perfect solution.

I hope this helps,

Cheers,

Gareth