scorm player height wrong - 1.9.12

scorm player height wrong - 1.9.12

by Richard Clark -
Number of replies: 15

I am new to moodle, but have read a lot. I have had a problem which I've been on for 2 days now. I have extensively read up on help here in the forum to try and solve the problem. I have read moodledocs. Despite following the advice for what is clearly quite common, none of the solutions from the forum have worked. My moodle is version 1.9.12.

I have been given the task of taking over the admin of a moodle. The problem is that new scorm objects do not display at the correct height, as below.

http://www.rasheff.com/show_scorm_object_height.gif

You can see the vertical scrollbar on the scorm player, it is only playing at 115 px deep. Scorm object is 700 px deep. The blue bar at the bottom is the footer and the top blue bar and above is the header. Manually setting the dimensions of the scorm player in moodle does not work. What does work, is opening the scorm course in a new window. Then it runs at proper height (depth). Changing the theme to another them e.g. standard moodle does NOT solve the problem.

Any suggestions? Any suggestions as to which files to check? Any coding in any files I can check anywhere? Is there a place that definitively sets the wdith & height of the scorm player? I have rigorously followed each suggestion on this thread, without success.

http://moodle.org/mod/forum/discuss.php?d=112909&parent=558536

I don't feel that I can upgrade to moodle 2.0 because I have read that themes in 1.9 aren't going to work in version 2. So I have stuck wtih 1.9.12. This right?

I do not know if it would interest anyone, but I have uploaded the theme folder and the moodle folder (installation) for if anyone was interested in looking.

moodle instal folder (29mb download)

http://www.rasheff.com/moodle.zip

theme folder (611 kb download)

http://www.rasheff.com/theme.zip

Thanks for any input. smile

Average of ratings: -
In reply to Richard Clark

Re: scorm player height wrong - 1.9.12

by Amy Groshek -
Hi Richard,

You've done a great job of providing info here. Can you post a screenshot of your SCORM settings for this activity?

Regards,
Amy
In reply to Amy Groshek

Re: scorm player height wrong - 1.9.12

by Richard Clark -

Hi Amy,

Here are screenshots of the scorm settings for this activity as requested. Should be 2 images. Thanks. smile

http://www.rasheff.com/scorm_settings_first_part.jpg

http://www.rasheff.com/scorm_settings_second_part.jpg

 

In reply to Richard Clark

Re: scorm player height wrong - 1.9.12

by Amy Groshek -
I installed 1.9.12 to test this just for you. smile Works fine for me in FF and Chrome, using a default theme.

What happens when you use a default Moodle theme, do the size settings work then?
Have you tested in a different browser?
Have you drilled down in FF with Firebug to see what's controlling the size of that iframe?

In reply to Amy Groshek

Re: scorm player height wrong - 1.9.12

by Amy Groshek -
#mod-scorm-player #scormobject { height: auto !important; }

Looks normal for me once I disable that height setting from your theme. It's always a bad idea to use !important in your css.

Average of ratings: Useful (1)
In reply to Amy Groshek

Re: scorm player height wrong - 1.9.12

by Richard Clark -

Hi Amy,

Thanks for your suggestion to use firebug. I haven't resolved the problem but am a lot closer, thanks to your suggestion to use firebug to take a deeper look. big grin

So where am I? Well, I have found the bit of code that is setting the the player height to 150. I have screenshotted below with a big red blob underneath the "150". The 2nd screenshot is the same screenshot, just a little more to the right.

In firebug, if I change that 150 to 750, then my scorm player is 750 deep. Great! However, I thought it would be easy to then search my moodle folder for that code and do a hard code change from 150 to 750. I have not been able to do this. I cannot find that code anywhere. I have searched for the class "scoframe". It isn't in there. I really don't know where that "150" is being set. Any ideas of where to look? Thanks.

http://www.rasheff.com/firebug1.gif

http://www.rasheff.com/firebug2.gif

In reply to Richard Clark

Re: scorm player height wrong - 1.9.12

by Amy Groshek -
There's no need for a hardcode change. Anyway, it would be a hassle later, when you had a SCORM package of a different size. What you really need to do is prevent your theme from overriding the height settings the scorm player is inserting. See my above post for the problematic css. Search your theme css for that height: auto !important; setting.
In reply to Amy Groshek

Re: scorm player height wrong - 1.9.12

by Richard Clark -

still not working for me. I get below when I get rid of that style. The footer has gone down but the actual scorm object is still only running in a 150px high frame. The only thing that works in firebug is to change that 150 to a greater number. But this is what is concerning me. In the html it is specifying the height as being 150px, not in a picked up style. I am thinking that this height is created dynamically, prob thru php as it believes it has to be 150px for some hard reason. If there is a way for me to change it, I would be more than happy. Any suggestions? Thanks. smile

http://www.rasheff.com/update1.gif

In reply to Richard Clark

Re: scorm player height wrong - 1.9.12

by Richard Clark -

I have now worked out that if I add a height to the below in italics, my scorm object will not play at 150px height but will play at the height I want it to play at. i.e. a height where you can see it.

.mod-scorm .scoframe{ margin-bottom:30px!important;  overflow-y: hidden !important; height:750px;}

However this now means that my bottom bar is underneath the scorm object. The new problem is that I don't seem to be able to set the height of the content area. If my scorm object is now running nicely at 750px height, the content area is only 630px high, so I can't see the bottom bar. Anybody know how to set the height of the content area? If I can do that then hopefully, it should work. Thanks. smile

In reply to Richard Clark

Re: scorm player height wrong - 1.9.12

by Richard Clark -

Ok I got it sorted. To increase the content size I just went to edit the scorm activity in moodle as you would usually, you know, where you set the width and height for the scorm activity.  However, to get my scorm object running at 750px height rather than 150px (goodness knows why it does that), I had to edit the following style. The bold being the addition.

.mod-scorm .scoframe{ margin-bottom:30px!important;  overflow-y: hidden !important; height:750px;}

Sorting this problem was pain. sad But it seems to be ok now. I hope this post here helps anybody who also gets themselves into rough seas on scorm sizing. Let's hope that is me sorted now. we'll see.

Amy, you are a STAR! heart

In reply to Richard Clark

Re: scorm player height wrong - 1.9.12

by Vinodh Soundarajan -

Sorry to reopen this old topic....

I have moodle 2.2.1 [$version = 2011120501.02; $release = '2.2.1+ (Build: 20120119)'; ]

I see the following hardcoded code in moodle\mod\scorm\module.js that is causing my SCORM window height to get downsized to 600.  Is there any specific reason for this hard code?  I had the same problem Richard mentioned.  I set this the  "if" conditional statement to "newheight = 750" and the problem is now gone...

// calculate the rough new height
newheight = YAHOO.util.Dom.getViewportHeight() *.82;
if (newheight < 600) {
newheight = 600;
}

I am wondering why the hardcode is there in the first place.

Thanks a lot

In reply to Vinodh Soundarajan

Re: scorm player height wrong - 1.9.12

by Vinodh Soundarajan -

Additional Observation:  The above code changes results in right height in Firefox and Safari, but not in Chrome.  Any ideas?

In reply to Richard Clark

Re: scorm player height wrong - 1.9.12

by Vanessa Rodriguez -

Hello, i am having the same issue. Where did you add ".mod-scorm .scoframe{ margin-bottom:30px!important;  overflow-y: hidden !important; height:750px;}"?

In reply to Vanessa Rodriguez

Re: scorm player height wrong - 1.9.12

by Dan Marsden -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Plugins guardians Picture of Testers Picture of Translators
are you really having this issue with a Moodle 1.9 installation? - You can't expect your Moodle site to work with modern browsers if you are running such an old Moodle release.
In reply to Dan Marsden

Re: scorm player height wrong - 1.9.12

by Vanessa Rodriguez -

Hi Dan, moodle version being used is 2.2.2 (Build: 20120312). To be honest i have little understanding of how moodle works and how to even go about updating plugins. I am fairly new to Moodle and need some major help understanding how plugins work and if they can be updated. How do i know if our current plugins are compatible with our verison of moodle? Any feedback or quick overview would be greatly appreciated.