????JFIF??x?x????'
| Server IP : 79.136.114.73 / Your IP : 216.73.216.37 Web Server : Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.29 OpenSSL/1.0.1f System : Linux b8009 3.13.0-170-generic #220-Ubuntu SMP Thu May 9 12:40:49 UTC 2019 x86_64 User : www-data ( 33) PHP Version : 5.5.9-1ubuntu4.29 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /var/www/appsrv.astacus.se/apps/school/www_old4/Html/LevelE/Category2/ |
Upload File : |
<!doctype html>
<html>
<head>
<title>Calendar task</title>
<script type="text/javascript" src="../../../js/allScriptsForLessonsHtml.js"></script>
<script>
var _colorRed = 'rgba(250, 0, 0, 0.3)';
var _colorGreen = 'rgba(0, 250, 0, 0.3)';
var _colorBlue = 'rgba(0, 0, 250, 0.3)';
var _currentColor = _colorRed;
var _currentColorForValidation = 'red';
var _isShowClapsAnimation = false;
var _isTdClicked = false;
function page_preLoad()
{
shared_setDeviceTypeLevelCategoryLastLesson(Level.E, Category.No2);
shared_set_tblMainiPadBodyWidthHeight('id_tblMainiPadBody', 'id_meta');
shared_setHeaderTable('id_tblHeader', shared_title_page, shared_getSubTitle(Level.E, Category.No2, 8), true, true);
shared_setFooterTable('id_tblFooter', true, true, true, true, true);
var ids_headings = ['id_td_heading1'];
var ids_texts = ['id_td_text1', 'id_td_text2', 'id_td_text3', 'id_td_text4', 'id_td_text5', 'id_td_text6'];
var ids_All = ids_headings.concat(ids_texts);
shared_adjust_fontSize_for_ids_all_devices(ids_All, 70);
setSelectColors();
set_td_widths_according_to_device_type();
}
function page_onLoad()
{
setCanvasWidthHeightAsTdWidthHeight();
}
function set_td_widths_according_to_device_type()
{
if (shared_currentDeviceType == shared_DeviceTypeAndroid)
{
var eTd1 = document.getElementById('id_td_text1');
var eTd2 = document.getElementById('id_td_text2');
eTd1.width = '25%';
eTd2.width = '25%';
}
}
function setSelectColors()
{
var eTdRed = document.getElementById('id_td_redColor');
var eTdGreen = document.getElementById('id_td_greenColor');
var eTdBlue = document.getElementById('id_td_blueColor');
var eTdCurrentColor = document.getElementById('id_td_currentColor');
eTdRed.style.background = _colorRed;
eTdGreen.style.background = _colorGreen;
eTdBlue.style.background = _colorBlue;
eTdCurrentColor.style.background = _currentColor;
}
function setCanvasWidthHeightAsTdWidthHeight()
{
for (var i=1; i<=12; i++)
{
var eCanvas = document.getElementById('id_canvas_' + i);
var eTd = document.getElementById('id_td_' + i);
var eTdRectangle = eTd.getBoundingClientRect();
eCanvas.width = eTdRectangle.width;// + 'px';
eCanvas.height = eTdRectangle.height;// + 'px';
var pScrolledXY = shared_getScrolledXY();
eCanvas.style.left = eTdRectangle.left + pScrolledXY.x + 'px';
eCanvas.style.top = eTdRectangle.top + pScrolledXY.y + 'px';
}
}
function redColor_click()
{
_currentColor = _colorRed;
_currentColorForValidation = 'red';
setLableColor();
}
function greenColor_click()
{
_currentColor = _colorGreen;
_currentColorForValidation = 'green';
setLableColor();
}
function blueColor_click()
{
_currentColor = _colorBlue;
_currentColorForValidation = 'blue';
setLableColor();
}
function setLableColor()
{
var eCurrentColor = document.getElementById('id_td_currentColor');
eCurrentColor.style.background = _currentColor;
}
function tdMonth_click(id_canvas)
{
_isTdClicked = true;
var eCanvas = document.getElementById(id_canvas);
if (eCanvas.style.display == 'block')
{
eCanvas.style.display = 'none';
eCanvas.userColor = 'none';
}
else
{
eCanvas.style.display = 'block';
eCanvas.userColor = _currentColorForValidation;
}
eCanvas.style.background = _currentColor;
}
function btnValidate_click()
{
_isShowClapsAnimation = false;
for (var i=1; i<=12; i++)
{
var eCanvas = document.getElementById('id_canvas_' + i);
if ((i == 1) || (i == 2) || (i == 11) || (i == 12))
{
if (eCanvas.userColor == 'green')
{
_isShowClapsAnimation = true;
}
else
{
_isShowClapsAnimation = false;
break;
}
}
else if ((i == 3) || (i == 4) || (i == 5) || (i == 6))
{
if (eCanvas.userColor == 'red')
{
_isShowClapsAnimation = true;
}
else
{
_isShowClapsAnimation = false;
break;
}
}
else if ((i == 7) || (i == 8) || (i == 9) || (i == 10))
{
if (eCanvas.userColor == 'blue')
{
_isShowClapsAnimation = true;
}
else
{
_isShowClapsAnimation = false;
break;
}
}
}
if (_isShowClapsAnimation)
{
shared_show_claps_animation('shared_id_div_claps_image');
}
else if (!_isTdClicked)
{
shared_show_message_info(shared_title_application, "Please fill all months with colors!", MessageOption.OK);
show_message_info();
}
else
{
shared_show_message_info(shared_title_application, "There is a wrong selection. Try again!", MessageOption.OK);
show_message_info();
}
}
function btnHome_click()
{
shared_btnHomeCategories_click('LevelE');
}
function btnPrevious_click()
{
window.location = 'LevelECat2Lesson7.html';
}
function btnNext_click()
{
window.location = 'LevelECat2Lesson9.html';
}
</script>
</head>
<body onload="page_onLoad()">
<div id="shared_id_div_claps_image">
</div>
<div id="shared_id_div_message">
</div>
<table id="id_tblMainiPadBody" border="1px" cellspacing="0" cellpadding="0">
<tr height="8%">
<td>
<div id="id_tblHeader"></div>
</td>
</tr>
<tr height="*" data-role="page"> <!-- for swiping left and right especially for Android device -->
<td>
<table id="id_table1" width="100%" height="100%" border="0" cellpadding="2%" cellspacing="0">
<tr height="5%">
<td>
<table width="100%" height="100%" border="1" cellpadding="0" cellspacing="0" style="border: none">
<tr>
<td align="center" id="id_td_heading1" class="shared_style_options_blue_24px_bold" style="border-bottom: none">Calendar</td>
</tr>
<tr>
<td id="id_td_text6" class="shared_style_blue_24px_padding_left_2_percent" style="border-top: none" align="center">(Click on month to color it)</td>
</tr>
</table>
</td>
</tr>
<tr height="5%">
<td>
<table id="id_table2" width="100%" height="100%" border="1" cellpadding="0" cellspacing="0" style="border: none">
<tr>
<td id="id_td_text1" class="shared_style_blue_24px_padding_left_2_percent" width="22%" align="center" style="border-top: none; border-bottom: none; border-left: none">Current color:</td>
<td id="id_td_currentColor" width="8%" align="center"></td>
<td width="*" align="center" style="border: none"> </td>
<td id="id_td_text2" class="shared_style_blue_24px_padding_left_2_percent" width="20%" align="center" style="border: none">Select color:</td>
<td id="id_td_redColor" width="8%" align="center" onclick="redColor_click()"></td>
<td id="id_td_greenColor" width="8%" align="center" onclick="greenColor_click()"></td>
<td id="id_td_blueColor" width="8%" align="center" onclick="blueColor_click()"></td>
</tr>
</table>
</td>
</tr>
<tr height="50%">
<td>
<table id="id_table3" width="100%" height="100%" border="1" cellpadding="0" cellspacing="0">
<tr height="33.3%">
<td id="id_td_1" width="25%" align="center" onClick="tdMonth_click('id_canvas_1')">
<img width="90%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/january.png" alt=""/>
<canvas id="id_canvas_1" style="position: absolute"></canvas>
</td>
<td id="id_td_2" width="25%" align="center" onClick="tdMonth_click('id_canvas_2')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/february.png" alt=""/>
<canvas id="id_canvas_2" style="position: absolute"></canvas>
</td>
<td id="id_td_3" width="25%" align="center" onClick="tdMonth_click('id_canvas_3')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/march.png" alt=""/>
<canvas id="id_canvas_3" style="position: absolute"></canvas>
</td>
<td id="id_td_4" width="*" align="center" onClick="tdMonth_click('id_canvas_4')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/april.png" alt=""/>
<canvas id="id_canvas_4" style="position: absolute"></canvas>
</td>
</tr>
<tr height="33.3%">
<td id="id_td_5" width="25%" align="center" onClick="tdMonth_click('id_canvas_5')">
<img width="90%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/may.png" alt=""/>
<canvas id="id_canvas_5" style="position: absolute"></canvas>
</td>
<td id="id_td_6" width="25%" align="center" onClick="tdMonth_click('id_canvas_6')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/june.png" alt=""/>
<canvas id="id_canvas_6" style="position: absolute"></canvas>
</td>
<td id="id_td_7" width="25%" align="center" onClick="tdMonth_click('id_canvas_7')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/july.png" alt=""/>
<canvas id="id_canvas_7" style="position: absolute"></canvas>
</td>
<td id="id_td_8" width="*" align="center" onClick="tdMonth_click('id_canvas_8')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/august.png" alt=""/>
<canvas id="id_canvas_8" style="position: absolute"></canvas>
</td>
</tr>
<tr height="33.3%">
<td id="id_td_9" width="25%" align="center" onClick="tdMonth_click('id_canvas_9')">
<img width="90%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/september.png" alt=""/>
<canvas id="id_canvas_9" style="position: absolute"></canvas>
</td>
<td id="id_td_10" width="25%" align="center" onClick="tdMonth_click('id_canvas_10')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/october.png" alt=""/>
<canvas id="id_canvas_10" style="position: absolute"></canvas>
</td>
<td id="id_td_11" width="25%" align="center" onClick="tdMonth_click('id_canvas_11')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/november.png" alt=""/>
<canvas id="id_canvas_11" style="position: absolute"></canvas>
</td>
<td id="id_td_12" width="*" align="center" onClick="tdMonth_click('id_canvas_12')">
<img width="80%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/december.png" alt=""/>
<canvas id="id_canvas_12" style="position: absolute"></canvas>
</td>
</tr>
</table>
</td>
</tr>
<tr height="*">
<td>
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse">
<tr height="33.3%">
<td id="id_td_text3" class="shared_style_blue_24px_padding_left_2_percent" width="50%">Colour summer months with red</td>
<td width="*"> </td>
</tr>
<tr height="33.3%">
<td id="id_td_text4" class="shared_style_blue_24px_padding_left_2_percent" width="50%">Colour winter months with green</td>
<td width="*">
<img width="20%" height="auto" src="../../../img/LevelE/Category2/LevelECat2Lesson8/man.png" alt=""/>
</td>
</tr>
<tr height="33.3%">
<td id="id_td_text5" class="shared_style_blue_24px_padding_left_2_percent" width="50%">Colour rainy months with blue.</td>
<td width="*"> </td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr height="8%">
<td>
<div id="id_tblFooter"></div>
</td>
</tr>
</table>
<script>
page_preLoad();
</script>
</body>
</html>