var presentation = ["Cinderella<\/word>","Cinderella II: Dreams Come True<\/word>","Cinderella III: A Twist in Time<\/word>","American singer and actress<\/word>","fictional character<\/word>","Walt Disney Productions<\/word>","animated feature film<\/word>","its sequels<\/word>","original film<\/word>","Ilene Woods<\/word>","Cinderella<\/strong> is a fictional character<\/strong> who appears in Walt Disney Productions<\/strong>' 12th animated feature film<\/strong> Cinderella<\/strong> and its sequels<\/strong> Cinderella II: Dreams Come True<\/strong> and Cinderella III: A Twist in Time<\/strong>. In the original film<\/strong>, Cinderella<\/strong> is voiced by American singer and actress<\/strong> Ilene Woods<\/strong>.<\/phrase>","Cinderella<\/word>","film critics<\/word>","passive<\/word>","one-dimensional<\/word>","less interesting<\/word>","found her endearing<\/word>","charming<\/word>","timeless<\/word>","silver gown<\/word>","transformation<\/word>","Oprah.com<\/word>","Reception<\/word>","Other critics<\/word>","vocal performance<\/word>","recognizable princesses<\/word>","iconic glass slippers<\/word>","on-screen makeovers<\/word>","fashion icon<\/word>","accolades and recognition<\/word>","InStyle<\/word>","Entertainment Weekly<\/word>","Glamour<\/word>","Reception<\/strong> towards Cinderella<\/strong> has been mixed, with some film critics<\/strong> describing the character as much too passive<\/strong>, one-dimensional<\/strong>, and less interesting<\/strong> than the film's supporting characters. Other critics<\/strong> found her endearing<\/strong>, charming<\/strong>, and timeless<\/strong>. Woods' vocal performance<\/strong> has also been praised. Panned or praised, Cinderella<\/strong> has nonetheless become one of the most famous and recognizable princesses<\/strong> in the history of film. With her iconic glass slippers<\/strong>, silver gown<\/strong>, hairstyle, and transformation<\/strong>, one of the first on-screen makeovers<\/strong> of its kind, the character has been established as a fashion icon<\/strong>, receiving accolades and recognition<\/strong> from InStyle<\/strong>, Entertainment Weekly<\/strong>, Glamour<\/strong> and Oprah.com<\/strong>.<\/phrase>","Cinderella<\/word>","birds<\/word>","mice<\/word>","Gus<\/word>","Jaq<\/word>","pet dog Bruno<\/word>","her father's horse Major<\/word>","start<\/word>","titular character<\/word>","scullery maid<\/word>","own home<\/word>","her cruel<\/word>","Lady Tremaine<\/word>","two stepsisters<\/word>","Anastasia<\/word>","Drizella<\/word>","only friends<\/word>","At the start<\/strong> of Cinderella<\/strong>, the titular character<\/strong> Cinderella<\/strong> is working as a scullery maid<\/strong> in her own home<\/strong> for her cruel<\/strong> stepmother named Lady Tremaine<\/strong> and her two stepsisters<\/strong> named Anastasia<\/strong> and Drizella<\/strong>. Her only friends<\/strong> are the birds<\/strong>, the mice<\/strong> who also live in the manor, including Gus<\/strong> and Jaq<\/strong>, her pet dog Bruno<\/strong> and her father's horse Major<\/strong>.<\/phrase>","invitation to the ball<\/word>","Cinderella<\/word>","finish her chores<\/word>","find something suitable to wear<\/word>","old party dress<\/word>","modern<\/word>","regular chores<\/word>","attend<\/word>","fix<\/word>","She prepares breakfast for the animals and for her stepfamily before beginning her regular chores<\/strong>. An invitation to the ball<\/strong> arrives at the door and Cinderella<\/strong> wants to attend<\/strong>. Her stepmother tells her she may go under the condition that she must finish her chores<\/strong> and find something suitable to wear<\/strong>. Cinderella<\/strong> discovers her deceased mother's old party dress<\/strong> and hopes to fix<\/strong> it to make it more modern<\/strong>, but she is too busy to do so.<\/phrase>","mice<\/word>","Cinderella<\/word>","Jaq<\/word>","Gus<\/word>","unwanted items<\/word>","fix up the dress<\/word>","not be able to attend the ball<\/word>","altered dress<\/word>","stealing<\/word>","tear the dress to shreds<\/word>","use<\/word>","Later<\/word>","recognize<\/word>","Meanwhile, when the mice<\/strong> see shadows of Cinderella<\/strong>'s stepsisters throwing down their old sash and beads, Jaq<\/strong> and Gus<\/strong> are forced to quietly retrieve them. The mice<\/strong> use<\/strong> the unwanted items<\/strong> to fix up the dress<\/strong>. Later<\/strong>, Cinderella<\/strong> fears she will not be done working in time and will not be able to attend the ball<\/strong>, but her friends reveal the altered dress<\/strong>. Cinderella<\/strong> is overjoyed and thanks her friends. She races down the steps just in time, but her stepsisters recognize<\/strong> their discarded items and accuse her of stealing<\/strong> their sash and beads. They tear the dress to shreds<\/strong>, leaving Cinderella<\/strong> all by herself, and she runs out to the garden, crying.<\/phrase>","transforms<\/word>","torn dress<\/word>","silver gown<\/word>","Cinderella<\/word>","spell will be broken<\/word>","midnight<\/word>","Prince Charming<\/word>","fall in love<\/word>","prevent the spell<\/word>","caught by her stepmother or stepsisters<\/word>","Fairy Godmother<\/word>","dreams come true<\/word>","cause<\/word>","Her Fairy Godmother<\/strong> appears to make her dreams come true<\/strong> and transforms<\/strong> her torn dress<\/strong> into a beautiful shimmering silver gown<\/strong>. Before Cinderella<\/strong> leaves, her godmother warns her that the spell will be broken<\/strong> at midnight<\/strong>. At the ball, Cinderella<\/strong> dances with Prince Charming<\/strong> and they immediately fall in love<\/strong> with each other. As twelve o'clock approaches, she hurries to leave, hoping to prevent the spell<\/strong> from breaking at the ball, which could cause<\/strong> her to get caught by her stepmother or stepsisters<\/strong>.<\/phrase>","loses one of her glass slippers<\/word>","Cinderella<\/word>","rags<\/word>","reminiscing her dance<\/word>","glass slipper<\/word>","coach<\/word>","spell<\/word>","marry<\/word>","In her haste, she loses one of her glass slippers<\/strong> on the staircase but fails to retrieve it in time. Cinderella<\/strong> hurries into her coach<\/strong> as it prepares to leave. The spell<\/strong> breaks and Cinderella<\/strong> is in rags<\/strong> once more before reminiscing her dance<\/strong> with the prince and thanking her godmother for all she's done for her. The next day, the prince announces he will marry<\/strong> the maiden whose foot fits into the glass slipper<\/strong>.<\/phrase>","Cinderella<\/word>","Prince Charming<\/word>","locked in the tower<\/word>","try on the slipper<\/word>","help her escape<\/word>","glass slipper<\/word>","shatter the slipper<\/word>","She and the Prince are married<\/word>","Lady Tremaine<\/word>","love<\/word>","trip<\/word>","Lady Tremaine<\/strong> hears Cinderella<\/strong> humming the same song that had played at the ball and figures out Cinderella<\/strong> was the girl Prince Charming<\/strong> fell in love<\/strong> with. Cinderella<\/strong> is locked in the tower<\/strong> by her stepmother, who refuses to let her have the opportunity to try on the slipper<\/strong>, but her animal friends help her escape<\/strong>. She hurries downstairs to try on the glass slipper<\/strong>. Knowing the slipper will fit her, Lady Tremaine<\/strong> intentionally causes the footman to trip<\/strong> and shatter the slipper<\/strong>. Cinderella<\/strong> reveals that she has kept the other slipper. She tries it on, and it fits perfectly. She and the Prince are married<\/strong> soon after.<\/phrase>"]; var currentPosition = 0; var totalPositions = 0; var timePerWord = 1500; var timePerPhraseWord = 120 var readAheadPlayerTimer; var autoPlay = true; var setMinimized = false; var wordSpeedOptions = {'Slower':2000,'Moderate':1200,'Fast':800}; var phraseSpeedOptions = {'Slower':280,'Moderate':200,'Fast':80}; var defaultWordSpeedOption = 'Moderate'; var defaultPhraseSpeedOption = 'Moderate'; var logToLTI = false; $(window).load(function(){ totalPositions = presentation.length; if (totalPositions > 0){ $('body').prepend('
'); $('body').prepend('
'); $('#read_ahead_player').prepend('
'); initializeReadAheadControls(); initializeReadAheadSlider(); initializeReadAheadSpeedOptions(); currentReadAheadControls(); resumeReadAheadPlayback(); } }); $(document).keyup(function(e){ switch(e.which) { case 37: pauseReadAheadPresentation(); priorReadAheadPresentationItem(); break; case 39: pauseReadAheadPresentation(); nextReadAheadPresentationItem(); break; default: break; } }); function initializeReadAheadControls(){ var s = ''; s += ''; s += ''; s += ''; s += '
'; s += ''; s += ''; s += ''; s += ''; s += ''; s += ''; s += ''; s += ''; s += ''; s += '
'; $('#read_ahead_player').append(s); } function initializeReadAheadSlider(){ var s = ''; s += '
'; s += '
'; s += '
'; $('#read_ahead_controls').prepend(s); updateReadAheadSliderPosition(); } function initializeReadAheadSpeedOptions(){ var s = '
'; s += '
'; s += ' Word Speed
'; s += '
'; optionCount = 0; for (index in wordSpeedOptions) { optionCount++; } optionWidth = 100 / optionCount; for (index in wordSpeedOptions) { var option = wordSpeedOptions[index]; if (index == defaultWordSpeedOption) { s += ''; updateReadAheadWordSpeed(option); } else { s += ''; } } s += '
'; s += '
'; s += '
'; s += ' Phrase Speed
'; s += '
'; optionCount = 0; for (index in phraseSpeedOptions) { optionCount++; } optionWidth = 100 / optionCount; for (index in phraseSpeedOptions) { var option = phraseSpeedOptions[index]; if (index == defaultWordSpeedOption) { s += ''; updateReadAheadPhraseSpeed(option); } else { s += ''; } } s += '
'; s += '
'; s += '
'; $('#read_ahead_controls').append(s); } function updateReadAheadWordSpeed(microseconds,sender) { microseconds = microseconds != undefined && microseconds > 0 ? microseconds : 0; if (microseconds > 0) { timePerWord = microseconds; } if (sender!=undefined) { $('#slider_control_word_speed').find('a').removeClass('current_speed'); $(sender).addClass('current_speed'); } logReadAheadPlayerAction('updateReadAheadWordSpeed','Presentation',microseconds); } function updateReadAheadPhraseSpeed(microseconds,sender) { microseconds = microseconds != undefined && microseconds > 0 ? microseconds : 0; if (microseconds > 0 ) { timePerPhraseWord = microseconds; } if (sender!=undefined) { $('#slider_control_phrase_speed').find('a').removeClass('current_speed'); $(sender).addClass('current_speed'); } logReadAheadPlayerAction('updateReadAheadPhraseSpeed','Presentation',microseconds); } function updateReadAheadSliderPosition(){ var currentSliderBarWidth = 100 - (100 / totalPositions * (currentPosition + 1)); $('#readAheadSliderBar').css('width',currentSliderBarWidth+'%'); } function currentReadAheadControls(){ $('#read_ahead_player_pause_play').show(); if (currentPosition < totalPositions - 1) { $('#read_ahead_player_next_word').removeClass('disabled'); } else { $('#read_ahead_player_next_word').addClass('disabled'); } if (currentPosition > 0) { $('#read_ahead_player_previous_word').removeClass('disabled'); } else { $('#read_ahead_player_previous_word').addClass('disabled'); } } function restartReadAheadPresentation(){ currentPosition = 0; logReadAheadPlayerAction('restartReadAheadPresentation','Presentation',''); resumeReadAheadPlayback(); } function resumeReadAheadPlayback(){ $('.fa-repeat').removeClass('fa-repeat').addClass('fa-play'); $('#read_ahead_player_pause_play').each(function(){ $(this).find('.fa-play').removeClass('fa-play').addClass('fa-pause'); $(this).off('click'); $(this).attr('onclick','pauseReadAheadPresentation()'); }); logReadAheadPlayerAction('resumeReadAheadPlayback','Presentation',''); playReadAheadPresentation(); } function pauseReadAheadPresentation(){ $('#read_ahead_player_pause_play').each(function(){ $(this).find('.fa-pause').removeClass('fa-pause').addClass('fa-play'); $(this).off('click'); $(this).attr('onclick','resumeReadAheadPlayback()'); }); logReadAheadPlayerAction('pauseReadAheadPresentation','Presentation',''); read_ahead_pause(); } function endReadAheadPresentation(){ $('.fa-play').removeClass('fa-play').addClass('fa-repeat'); $('.fa-pause').removeClass('fa-pause').addClass('fa-repeat'); $('#read_ahead_player_pause_play').each(function(){ $(this).off('click'); $(this).attr('onclick','restartReadAheadPresentation()'); }); logReadAheadPlayerAction('endReadAheadPresentation','Presentation',''); logLTIEndPresentation(); } function playReadAheadPresentation(){ autoPlay=true; currentPosition--; logReadAheadPlayerAction('playReadAheadPresentation','Presentation',''); nextReadAheadPresentationItem(); } function startReadAheadStepper(timeDisplayWord){ clearInterval(readAheadPlayerTimer); readAheadPlayerTimer = setTimeout(function() { read_ahead_step(); },timeDisplayWord); } function stopReadAheadStepper(){ clearInterval(readAheadPlayerTimer); } function read_ahead_step(){ if (autoPlay) { nextReadAheadPresentationItem(); } } function read_ahead_pause(){ autoPlay=false; stopReadAheadStepper(); } function showReadAheadPresentationItem(index){ currentPosition = index; currentPresentationItem = presentation[currentPosition] != undefined ? presentation[currentPosition].trim() : ""; if (currentPresentationItem != "") { currentItemWordCount = presentation[currentPosition].replace("\n","").split(" ").length; if (currentPresentationItem.startsWith("")){ startReadAheadStepper(currentItemWordCount*timePerWord); $('#read_ahead_player_field').html('
'+currentPresentationItem+'
'); logReadAheadPlayerAction('showReadAheadPresentationItem','Word',currentPresentationItem); } else { startReadAheadStepper(currentItemWordCount*timePerPhraseWord); $('#read_ahead_player_field').html('
'+currentPresentationItem.replace("\n","
")+'
'); logReadAheadPlayerAction('showReadAheadPresentationItem','Phrase',''); } } else { if (currentPosition < totalPositions) { nextReadAheadPresentationItem(); } else { endReadAheadPresentation(); read_ahead_minimize(); } } currentReadAheadControls(); updateReadAheadSliderPosition(); saveReadAheadPosition(); } function priorReadAheadPresentationItem(){ stopReadAheadStepper(); logReadAheadPlayerAction('priorReadAheadPresentationItem','Controls',''); showReadAheadPresentationItem(currentPosition-1); } function nextReadAheadPresentationItem(){ stopReadAheadStepper(); logReadAheadPlayerAction('nextReadAheadPresentationItem','Controls',''); showReadAheadPresentationItem(currentPosition+1); } function read_ahead_playAgain(){ currentWordIndex = 0; logReadAheadPlayerAction('read_ahead_playAgain','Controls',''); playReadAheadPresentation(); } function read_ahead_minimize(){ setMinimized = true; logReadAheadPlayerAction('read_ahead_minimize','Controls',''); read_ahead_switch_min_max(); } function read_ahead_maximize(){ setMinimized = false; logReadAheadPlayerAction('read_ahead_maximize','Controls',''); read_ahead_switch_min_max(); } function read_ahead_switch_min_max(forceSwitch){ forceSwitch = forceSwitch != undefined ? forceSwitch : false; if (forceSwitch) { setMinimized = !setMinimized; } if (setMinimized) { $('#read_ahead_player_back').fadeOut(); $('#read_ahead_player').addClass('minimize'); $('.player-icons .fa-stack').removeClass('fa-lg').addClass('fa-sm'); $('.player-icons .fa-minus').removeClass('fa-minus').addClass('fa-expand'); logReadAheadPlayerAction('read_ahead_switch_min_max','Min',''); //$('#read_ahead_player_max_min').each(function(){ // $(this).off('click'); // $(this).attr('onclick','read_ahead_maximize()'); //}); } else { $('#read_ahead_player_back').fadeIn(); $('#read_ahead_player').removeClass('minimize'); $('.player-icons .fa-stack').removeClass('fa-sm').addClass('fa-lg'); $('.player-icons .fa-expand').removeClass('fa-expand').addClass('fa-minus'); logReadAheadPlayerAction('read_ahead_switch_min_max','Max',''); //$('#read_ahead_player_max_min').each(function(){ // $(this).off('click'); // $(this).attr('onclick','read_ahead_minimize()'); //}); } } function saveReadAheadPosition(){ $.ajax({ type:'POST', url:'/ajax/save_user_presentation_position.php', data: { 'id':1571, 'position': currentPosition } }) .done(function(results){ }) .fail(function( jqXHR, textStatus ) { alert( "Request failed: " + textStatus ); }); } function logLTIEndPresentation(action) { if (!logToLTI) { return; } $.ajax({ type:'POST', url:'/lti/presentationEnded.php', data: { 'documentId':1571, 'userId':0, } }) } function logReadAheadPlayerAction(action,area,details){ var d = new Date(); var t = d.getTime(); action = action != undefined ? action.trim() : 'UNKNOWN'; area = area != undefined ? area.trim() : ''; details = details != undefined ? details : ''; // If we are about to show a new word, increase the number of keywords // reinforced so we can log that for the Dashboard page. if (area == 'Word') { window.keywordCount++; } $.ajax({ type:'POST', url:'/logging/logPlayerAction.php', data: { 'documentId':1571, 'userId':0, 'playerAction':action, 'playerArea':area, 'details':details, 'timestamp': t } }) .done(function(results){ }) .fail(function( jqXHR, textStatus ) { alert( "Request failed: " + textStatus ); }); }