Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <style>
- .card-selection-area input[type="radio"] {
- display: none;
- }
- .card-selection-area input[type="radio"]:checked + label {
- background-color: #312f59;
- border-color: #312f59;
- color: #fff;
- }
- .card-selection-area table {
- margin: 0 85px;
- }
- .card-selection-area td {
- padding: 2px 10px;
- text-align: center;
- }
- .card-selection-area label {
- display: inline-block;
- background-color: #fff;
- font-family: Arial;
- font-size: 16px;
- width: 30px;
- height: 30px;
- line-height: 30px;
- border: 1px solid #a69981;
- border-radius: 15px;
- text-align: center;
- cursor: pointer;
- }
- .img-inline {
- display: inline-block;
- margin: 0 5px;
- max-width: 100%;
- }
- .img-inline, .img-block {
- vertical-align: middle;
- }
- .img-block {
- display: block;
- margin: 5px auto;
- max-width: 100%;
- }
- #exam-form, #exam-form *:not(.label) {
- font-size: 16px !important;
- line-height: 150% !important;
- }
- </style>
- <form id="exam-form">
- <div class="row">
- <div class="col-xs-6 ref-wrapper">
- <div class="q2_box q2_box_w">At once community college, the cost per credit hour for in-state students has been decrease by $2 a year. In another community college, it has been decreasing by 4% per year. This year, the cost is $70 at both colleges. To the nearest dollar, what was the positive difference in costs 3 years ago?</div> </div>
- <div class="col-xs-6">
- <h3><span class="q2_box"></span></h3><h4><span class="q2_box"></span><span class="q2_box">Please click on the answer sheet below.</span></h4> <div class="card-selection-area">
- <div id="review-feedback" style="display: none;"></div>
- <table>
- <tr>
- <td><input type="text" size="1"></td>
- <td><input type="text" size="1"></td>
- <td><input type="text" size="1"></td>
- <td><input type="text" size="1"></td>
- </tr>
- <tr>
- <td></td>
- <td><input type="radio" name="decimal" id="fractionLine1" data-digit="2" value="/"><label for="fractionLine1">/</label></td>
- <td><input type="radio" name="decimal" id="fractionLine2" data-digit="3" value="/"><label for="fractionLine2">/</label></td>
- <td></td>
- </tr>
- <tr>
- <td><input type="radio" name="decimal" id="decimalPoint1" data-digit="1" value="."><label for="decimalPoint1">.</label></td>
- <td><input type="radio" name="decimal" id="decimalPoint2" data-digit="2" value="."><label for="decimalPoint2">.</label></td>
- <td><input type="radio" name="decimal" id="decimalPoint3" data-digit="3" value="."><label for="decimalPoint3">.</label></td>
- <td><input type="radio" name="decimal" id="decimalPoint4" data-digit="4" value="."><label for="decimalPoint4">.</label></td>
- </tr>
- <tr>
- <td></td>
- <td><input type="radio" name="digit2" id="digit2-0" value="0" data-digit="2"><label for="digit2-0">0</label></td>
- <td><input type="radio" name="digit3" id="digit3-0" value="0" data-digit="3"><label for="digit3-0">0</label></td>
- <td><input type="radio" name="digit4" id="digit4-0" value="0" data-digit="4"><label for="digit4-0">0</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-1" value="1" data-digit="1"><label for="digit1-1">1</label></td>
- <td><input type="radio" name="digit2" id="digit2-1" value="1" data-digit="2"><label for="digit2-1">1</label></td>
- <td><input type="radio" name="digit3" id="digit3-1" value="1" data-digit="3"><label for="digit3-1">1</label></td>
- <td><input type="radio" name="digit4" id="digit4-1" value="1" data-digit="4"><label for="digit4-1">1</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-2" value="2" data-digit="1"><label for="digit1-2">2</label></td>
- <td><input type="radio" name="digit2" id="digit2-2" value="2" data-digit="2"><label for="digit2-2">2</label></td>
- <td><input type="radio" name="digit3" id="digit3-2" value="2" data-digit="3"><label for="digit3-2">2</label></td>
- <td><input type="radio" name="digit4" id="digit4-2" value="2" data-digit="4"><label for="digit4-2">2</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-3" value="3" data-digit="1"><label for="digit1-3">3</label></td>
- <td><input type="radio" name="digit2" id="digit2-3" value="3" data-digit="2"><label for="digit2-3">3</label></td>
- <td><input type="radio" name="digit3" id="digit3-3" value="3" data-digit="3"><label for="digit3-3">3</label></td>
- <td><input type="radio" name="digit4" id="digit4-3" value="3" data-digit="4"><label for="digit4-3">3</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-4" value="4" data-digit="1"><label for="digit1-4">4</label></td>
- <td><input type="radio" name="digit2" id="digit2-4" value="4" data-digit="2"><label for="digit2-4">4</label></td>
- <td><input type="radio" name="digit3" id="digit3-4" value="4" data-digit="3"><label for="digit3-4">4</label></td>
- <td><input type="radio" name="digit4" id="digit4-4" value="4" data-digit="4"><label for="digit4-4">4</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-5" value="5" data-digit="1"><label for="digit1-5">5</label></td>
- <td><input type="radio" name="digit2" id="digit2-5" value="5" data-digit="2"><label for="digit2-5">5</label></td>
- <td><input type="radio" name="digit3" id="digit3-5" value="5" data-digit="3"><label for="digit3-5">5</label></td>
- <td><input type="radio" name="digit4" id="digit4-5" value="5" data-digit="4"><label for="digit4-5">5</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-6" value="6" data-digit="1"><label for="digit1-6">6</label></td>
- <td><input type="radio" name="digit2" id="digit2-6" value="6" data-digit="2"><label for="digit2-6">6</label></td>
- <td><input type="radio" name="digit3" id="digit3-6" value="6" data-digit="3"><label for="digit3-6">6</label></td>
- <td><input type="radio" name="digit4" id="digit4-6" value="6" data-digit="4"><label for="digit4-6">6</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-7" value="7" data-digit="1"><label for="digit1-7">7</label></td>
- <td><input type="radio" name="digit2" id="digit2-7" value="7" data-digit="2"><label for="digit2-7">7</label></td>
- <td><input type="radio" name="digit3" id="digit3-7" value="7" data-digit="3"><label for="digit3-7">7</label></td>
- <td><input type="radio" name="digit4" id="digit4-7" value="7" data-digit="4"><label for="digit4-7">7</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-8" value="8" data-digit="1"><label for="digit1-8">8</label></td>
- <td><input type="radio" name="digit2" id="digit2-8" value="8" data-digit="2"><label for="digit2-8">8</label></td>
- <td><input type="radio" name="digit3" id="digit3-8" value="8" data-digit="3"><label for="digit3-8">8</label></td>
- <td><input type="radio" name="digit4" id="digit4-8" value="8" data-digit="4"><label for="digit4-8">8</label></td>
- </tr>
- <tr>
- <td><input type="radio" name="digit1" id="digit1-9" value="9" data-digit="1"><label for="digit1-9">9</label></td>
- <td><input type="radio" name="digit2" id="digit2-9" value="9" data-digit="2"><label for="digit2-9">9</label></td>
- <td><input type="radio" name="digit3" id="digit3-9" value="9" data-digit="3"><label for="digit3-9">9</label></td>
- <td><input type="radio" name="digit4" id="digit4-9" value="9" data-digit="4"><label for="digit4-9">9</label></td>
- </tr>
- </table>
- </div>
- </div>
- </div>
- <div class="row text-center">
- <button id="exam-submit" type="button" class="btn btn-lg btn-primary">Next</button>
- </div>
- <input type="hidden" id="q_option" name="q_option" value="">
- <input type="hidden" id="answer_type" name="answer_type" value="0">
- <input type="hidden" id="correct_ans" name="correct_ans" value="3">
- </form>
- <div id="solving" style="display: none;">
- <hr>
- </div>
- <script>
- var studentAns = {
- 'text': '',
- 'value': 0
- };
- $(document).off('click change');
- $(document).on('click', '.card-selection-area label', function(e) {
- e.preventDefault();
- var target = $('.card-selection-area input[type=radio][id="' + $(this).attr('for') + '"]');
- target.prop('checked', !target.prop('checked'));
- target.trigger('change');
- }).on('change', '.card-selection-area input[type=radio]', function() {
- var result = 0;
- if ($(this).prop('checked') == true) {
- if ($(this).attr('name') == 'decimal') {
- $('[name=digit' + $(this).attr('data-digit') + ']:checked').prop('checked', false);
- } else {
- $('[name=decimal][data-digit=' + $(this).attr('data-digit') + ']:checked').prop('checked', false);
- }
- }
- var inputStr = (
- (typeof $('[data-digit=1]:checked').val() != 'undefined' ? $('[data-digit=1]:checked').val().toString() : '')
- + (typeof $('[data-digit=2]:checked').val() != 'undefined' ? $('[data-digit=2]:checked').val().toString() : '')
- + (typeof $('[data-digit=3]:checked').val() != 'undefined' ? $('[data-digit=3]:checked').val().toString() : '')
- + (typeof $('[data-digit=4]:checked').val() != 'undefined' ? $('[data-digit=4]:checked').val().toString() : '')
- );
- //console.log(inputStr);
- var regExp = /^(\d{1,2})\/(\d{1,2})$/g;
- var matches = regExp.exec(inputStr);
- if (inputStr.substr(0, 1) == '.') {
- inputStr = '0' + inputStr;
- }
- if (matches !== null) {
- //console.log(matches);
- var denominator = parseInt(matches[2]),
- numerator = parseInt(matches[1]);
- result = (numerator / denominator);
- if (result > 10) {
- result = result.toFixed(1);
- } else {
- result = result.toFixed(2);
- }
- } else if (inputStr.match(/^\d{1,3}\.{0,1}\d{0,3}$/)) {
- result = parseFloat(inputStr).toFixed(4);
- }
- result = parseFloat(result);
- for (var t = 0; t <= 3; t++) {
- $('.card-selection-area input[type=text]').eq(t).val((typeof $('[data-digit=' + (t + 1).toString() + ']:checked').val() != 'undefined' ? $('[data-digit=' + (t + 1).toString() + ']:checked').val().toString() : ''));
- }
- /* Save student answer in global varible */
- window.studentAns.text = inputStr;
- window.studentAns.value = result;
- console.log(window.studentAns);
- $('#q_option').val(window.studentAns.text + '|' + window.studentAns.value);
- })
- $('#exam-submit').click(function() {
- var btn = this;
- btn.disabled = true;
- if (check_submit() === true) {
- exam_submit();
- } else {
- submit_error();
- }
- });
- function submit_error() {
- BootstrapDialog.show({
- title: 'Error',
- message: 'Error! Please answer the question before you submit.',
- type: BootstrapDialog.TYPE_DANGER,
- buttons: [{
- cssClass: 'btn-danger',
- label: 'Confirm',
- action: function(dialog) {
- dialog.close();
- }
- }],
- onhide: function() {
- $('#exam-submit').prop('disabled', false);
- }
- });
- }
- function check_submit() {
- var checked = $('input[type=hidden][name=q_option]').first().val().trim().length > 0;
- /*if ($('input[type=radio][name=q_option]:checked').length == 0) {
- if ($('input[type=checkbox][name="q_option[]"]:checked').length == 0) {
- if ($('input[type=hidden][name=q_option]').length == 0) {
- checked = ($('input[type=checkbox], input[type=radio], input[type=text], textarea').length == 0);
- } else {
- checked = ($('input[type=hidden][name=q_option]').val().trim().length > 0);
- }
- }
- }*/
- return checked;
- }
- function review_submit() {
- if (check_submit() === true) {
- show_solving();
- } else {
- submit_error();
- }
- }
- function show_solving() {
- var feedback = (window.studentAns.value == $('#correct_ans').val() ? '<h3 class="text-success">Correct!</h3>' : '<h3 class="text-danger">Incorrect! Correct answer is ' + $('#correct_ans').val() + '.</h3>');
- $('#exam-question').trigger('detach.ScrollToFixed');
- $('#review-feedback').html(feedback).slideDown();
- $('#solving').slideDown();
- }
- </script><script type="text/javascript">
- var auto_submit_timer;
- if(auto_submit_timer)
- {
- console.log('clean auto submit');
- clearInterval(auto_submit_timer);
- auto_submit_timer = 0;
- }
- </script>
- <script type="text/javascript">
- //判斷是否正在計時的flag
- var examtime = true;
- //正數計時器(紀錄作答時間)
- var timer1 = new timer('timer_1');
- //不要自動更新顯示時間(原本是正數,我要改成倒數)
- timer1.auto_change_display = false;
- //N分鐘後鎖定螢幕
- var lock_time = 540
- //cookie時間,題型有設定exam才會開啟 Daky、Lewis 1040624
- if(typeof($.cookie("time")) != 'undefined' && $.cookie("self_id") == '1467881649067050'){
- var cookietime = $.cookie("time");
- lock_time = cookietime;
- }
- else {
- $.removeCookie('time');
- $.removeCookie('self_id');
- }
- //kenny的閱讀題型
- //重作的時間要另外計算
- if (typeof(redo_lock_time) != 'undefined' && redo_lock_time > 0) {
- lock_time = redo_lock_time;
- redo_lock_time = 0;
- }
- //N分鐘後開放放棄此題
- var giveup_time = (1 * 60);
- //計時器計時時也會執行這個function(每秒執行1次)
- timer1.timer_custom_func = function() {
- var eta_sec = lock_time - this.timer_number;
- //如果是考試的題型,每秒要去修改時間 Daky、Lewis 1040624
- if(eta_sec <= 0){
- //如果有设定不要时间到跳题,就不会跳题
- $.post('../common/exam_timeout.php', {
- }, function(res) {
- console.log(res);
- $.removeCookie('time');
- //window.location.href = 'main.php';
- if(typeof(exam_submit) !=='undefined'){ //如果function 不是undefined 就呼叫強制送出
- exam_submit();
- }
- });
- return false;
- }else{
- $.cookie("time", eta_sec, { expires: 1 });
- $.cookie("self_id", '1467881649067050', { expires: 1 });
- }
- //控制是否顯示時間
- if ($('#eta_time').attr('data-no-show') !== 'true') {
- //console.log(eta_sec);
- if(eta_sec>=0) $('#' + this.display_id).text(eta_sec.toString().toHHMMSS()); //時間大於0,才去更新時間 Daky
- }else {
- $('#' + this.display_id).text('显示');
- }
- //剩下不到30秒時,時鐘變紅
- if (eta_sec < 30) { $('#' + this.display_id).css('color', '#f00'); }
- else { $('#' + this.display_id).css('color', 'inherit'); }
- //如果不是考試的題型,會有鎖專心碼 Lewis 1040625
- //如果是體驗課,加上nolock就不會鎖了 Daky 1040922
- }
- //题号
- var main_question_id = ('30996'!='')?'<span id="main_question_id" style="float: right;color: gainsboro;">System Question ID:30996</span>':'';
- //面包屑
- $('#course_title').html('SAT >> Homework – Math 2 >> Unit 4 ' + main_question_id);
- function exam_submit() {
- //轉轉轉
- showLoading();
- //送出時計時暫停
- timer1.timer_pause();
- //表格題
- if ($('.panel-info').length > 0) {
- //alert($('.panel-info').length);
- var raw_q_option = $('#exam-form input[name=q_option]').val();
- var options_num = new Array();
- $('.panel-info').each(function() {
- var span_num = 0;
- var _this = $(this);
- _this.find('span.droppable').each(function() {
- if ($(this).html() != ' ') {
- span_num += 1;
- }
- });
- options_num.push(span_num);
- });
- var q_options = raw_q_option.split('|');
- var new_q_options = new Array();
- var opt_k = 0;
- $(options_num).each(function(k, v) {
- var tmp_arr = new Array();
- for (i = 0; i < v; i++) {
- tmp_arr.push(q_options[opt_k]);
- opt_k += 1;
- }
- new_q_options.push(tmp_arr);
- });
- $('#exam-form input[name=q_option]').val(JSON.stringify(new_q_options));
- //return false;
- }
- //上傳筆記檔案
- if($(':file').length > 0 && $(':file').change()){
- var formData = new FormData(document.getElementById("exam-form"));
- $.ajax({
- url: '../exam/check_lewis.php', //Server script to process data
- type: 'POST',
- //Form data
- data: formData,
- //Options to tell jQuery not to process data or worry about content-type.
- cache: false,
- contentType: false,
- processData: false,
- success: function(res) {
- $('#Images').attr({'value':res});
- }
- });
- }
- //把exam-form裡面element的值都抓出來,塞進submit_data這個變數
- var submit_data = $('#exam-form').serialize();
- $.ajax({
- url: '../exam/check.php',
- type: 'POST',
- data: submit_data + '&qid=30996&spend=' + timer1.timer_number, //timer_number
- success: function(res) {
- if (res !== '') {
- var res_obj = $.parseJSON(res);
- if (res_obj !== null && typeof(res_obj) !== 'undefined') {
- if (res_obj.res_type == "dialog") {
- //拿掉轉轉轉
- hideLoading();
- $('#loadingOverlay').hide();
- $('body').css('overflow', 'auto');
- message_dialog(res_obj.dialog_msg, res_obj.dialog_title, res_obj.dialog_type, function() {
- $('#loadingOverlay').show();
- $('body').css('overflow', 'hidden');
- exam_load();
- });
- }
- }
- else {
- //如果有其他訊息,顯示在console裡面
- console.log(res);
- exam_load();
- }
- }
- else { exam_load(); }
- }
- });
- }
- function exam_initial() {
- //重設計時器(從0開始)
- timer1.timer_reset();
- timer1.timer_play();
- $('#eta_time').click(function() {
- var cur_stat = ($(this).attr('data-no-show') === undefined) ? false : ($(this).attr('data-no-show') === 'true' ? true : false);
- $(this).attr('data-no-show', !cur_stat);
- });
- //把目前單元的tooltip直接顯示出來
- //$(selector).tooltip('show') => 顯示
- //$(selector).tooltip('hide') => 隱藏
- $('[data-toggle="tooltip"]').tooltip({
- html: true
- });
- //如果.task-now跟.task-redo兩個同時存在的話,顯示.task-now就好
- if ($('.task-now').length > 0 && $('.task-redo').length > 0) {
- $('.task-now, #eta_time').tooltip('show');
- $('.task-redo').css('border', '5px solid transparent');
- }
- else {
- $('.task-now, .task-redo, #eta_time').tooltip('show');
- }
- if (typeof(tooltip_timeout) != 'undefined') { clearTimeout(tooltip_timeout); }
- //5秒後隱藏
- tooltip_timeout = setTimeout(function() {
- $('.task-now, .task-redo, #eta_time').tooltip('hide');
- }, 5000);
- //顯示tooltip時先把其他的隱藏
- $('[data-toggle="tooltip"]').on('show.bs.tooltip', function() {
- $('[data-toggle="tooltip"]').not($(this)).tooltip('hide');
- });
- //回報難點
- $('#btn_hard').unbind();//20160603 Daky 避免重複綁定多次點擊
- $('#btn_hard').bind('click', function() {
- //轉轉轉
- showLoading();
- //回報時間
- var report_time = getDateTime();
- //回報內容
- var text = "請於下方輸入您的困難點 或 想詢問老師的問題。";
- //彈出輸入框
- var comment = prompt(text, "");
- if (comment != null) {
- $.post('../common/log.php', {
- 'log_type': 'hard_point',
- 'log_content': encodeURI(JSON.stringify({
- 'qid': '30996',
- 'comment':comment,
- 'chapter':$('#course_title').text(),
- 'report_time': report_time
- })),
- 'qid': '30996'
- }, function(res) {
- hideLoading();
- var result = $.parseJSON(res);
- message_dialog(result.message, result.title, result.type);
- });
- return false;
- }
- else {
- //拿掉轉轉轉
- hideLoading();
- }
- });
- //暫停
- $('#btn_stop').unbind();//20160603 Daky 避免重複綁定多次點擊
- $('#btn_stop').bind('click', function() {
- if(examtime) {
- //如果該題有定義恢復時要做什麼,就呼叫他
- if(typeof(exam_stop) == 'function'){ exam_stop(); }
- //時間暫停
- timer1.timer_pause();
- //寫入暫停的log
- var pause_time = getDateTime();
- $.post('../common/log.php', {
- 'log_type': 'pause',
- 'log_content': encodeURI(JSON.stringify({
- 'pause_time': pause_time
- }))
- });
- //黑屏
- $('<div></div>',{'id': 'pauseOverlay'}).css({
- 'position': 'fixed',
- 'left': '0',
- 'top': '0',
- 'width': '100%',
- 'height': '100%',
- 'z-index': '9998',
- 'background-color': 'rgba(0, 0, 0, 0.8)'
- }).appendTo('body');
- //暫停文字
- $('<h2></h2>').text('暂停中').css({
- 'position': 'absolute',
- 'width': '200px',
- 'height': '52px',
- 'left': '50%',
- 'top': '50%',
- 'font-size': '52px',
- 'letter-spacing': '14px',
- 'line-height': '52px',
- 'color': 'rgb(255, 255, 255)',
- 'margin': '-120px 0px 0px -90px',
- 'z-index': '9999'
- }).appendTo('#pauseOverlay');;
- //恢復按鈕
- $('<button></button>').text('继续作答').addClass('btn btn-primary').attr('id', 'btn_go').css({
- 'position': 'absolute',
- 'height': '53px',
- 'width': '152px',
- 'left': '50%',
- 'top': '50%',
- 'font-size': '26px',
- 'margin': '-34px 0px 0px -76px',
- 'z-index': '9999'
- }).click(function() {
- //如果該題有定義恢復時要做什麼,就呼叫他
- if(typeof(exam_continue) == 'function'){ exam_continue(); }
- //寫入恢復的log
- var resume_time = getDateTime();
- $.post('../common/log.php', {
- 'log_type': 'resume',
- 'log_content': encodeURI(JSON.stringify({
- 'resume_time': resume_time,
- 'pause_time': pause_time
- }))
- });
- //移除黑屏
- $('#pauseOverlay').remove();
- //啟用背景卷軸
- $('body').css('overflow', 'auto');
- //將判斷是否正在計時的flag設為true
- examtime = true;
- //時間繼續
- timer1.timer_play();
- }).appendTo('#pauseOverlay');
- //停用背景卷軸
- $('body').css('overflow', 'hidden');
- }
- //如果有正在播放的影片就暫停
- if ($('video:visible').length > 0) {
- $('video:visible').get(0).pause();
- }
- examtime = !examtime;
- return false;
- });
- //掃盲
- $('#btn_scan').click(function() {
- //轉轉轉
- showLoading();
- $.post('../main/scan_info.php', {
- 'id': '15110504028',
- }, function(res) {
- hideLoading();
- message_dialog(res, '掃盲紀錄', 'info');
- });
- return false;
- });
- //求救
- $('#btn_help').click(function() {
- //轉轉轉
- //showLoading();
- //求救時間
- var help_time = getDateTime();
- $.post('../common/log.php', {
- 'log_type': 'help',
- 'log_content': encodeURI(JSON.stringify({
- 'qid': '30996',
- 'help_time': help_time
- })),
- 'qid': '30996',
- 'qtype': '80',
- }, function(res){
- //console.log(res);
- if(res.length != 2){
- var result = $.parseJSON(res);
- message_dialog(result.message, result.title, result.type);
- }
- });
- return false;
- });
- hideLoading();
- }
- function exam_load() {
- showLoading();
- //載入題目
- $('#question_field').load('question_inc.php', function() {
- //載入上方進度圖
- $('#main_header_inner').load('main_header.php', function() {
- //載入完成後觸發
- exam_initial();
- $('.correct-answer').parent().css('background', '#F9F9F9');
- });
- });
- }
- function getDateTime() {
- var now = new Date();
- var year = now.getFullYear();
- var month = now.getMonth()+1;
- var day = now.getDate();
- var hour = now.getHours();
- var minute = now.getMinutes();
- var second = now.getSeconds();
- if(month.toString().length == 1) { var month = '0' + month; }
- if(day.toString().length == 1) { var day = '0' + day; }
- if(hour.toString().length == 1) { var hour = '0' + hour; }
- if(minute.toString().length == 1) { var minute = '0' + minute; }
- if(second.toString().length == 1) { var second = '0' + second; }
- var dateTime = year + '/' + month + '/' + day + ' ' + hour + ':' + minute + ':' + second;
- return dateTime;
- }
- </script>
Advertisement
Add Comment
Please, Sign In to add comment