{"id":113,"date":"2017-06-16T12:51:39","date_gmt":"2017-06-16T12:51:39","guid":{"rendered":"http:\/\/dev.novembit.com\/certy\/florist\/?page_id=113"},"modified":"2017-06-16T12:51:39","modified_gmt":"2017-06-16T12:51:39","slug":"calendar","status":"publish","type":"page","link":"https:\/\/certy.px-lab.com\/florist\/calendar\/","title":{"rendered":"calendar"},"content":{"rendered":"<p><strong>\n    <script type='text\/javascript'>\n    jQuery(document).ready(function() {\n        jQuery('#calendar').fullCalendar({\n            header: {\n                left: 'prev,next today',\n                center: 'title',\n                right: 'month,agendaWeek,agendaDay'\n            },\n            titleFormat: {\n                month: ' MMMM yyyy',                                \/\/ September 2009\n                week: \"MMM d[ yyyy]{ '&#8212;'[ MMM] d yyyy}\",      \/\/ Sep 7 - 13 2009\n                day: 'dddd, MMM d, yyyy'                            \/\/ Tuesday, Sep 8, 2009\n            },\n            editable: false,\n            weekends: true,\n            timeFormat: 'h:mm{-h:mmtt }',\n            axisFormat: 'h:mm{-h:mmtt }',\n                        firstDay: 1,\n            slotMinutes: 30,\n            defaultView: 'month',\n            minTime: 10,\n\n            maxTime: 17,\n            monthNames: [\"January\",\"February\",\"March\",\"April\",\"May\",\"June\",\"July\", \"August\", \"September\", \"October\", \"November\", \"December\" ],\n            monthNamesShort: [\"Jan\",\"Feb\",\"Mar\",\"Apr\",\"May\",\"Jun\",\"Jul\",\"Aug\",\"Sept\",\"Oct\",\"Nov\",\"Dec\"],\n            dayNames: [\"Sunday\",\"Monday\",\"Tuesday\",\"Wednesday\",\"Thursday\",\"Friday\",\"Saturday\"],\n            dayNamesShort: [\"Sun\",\"Mon\", \"Tue\", \"Wed\", \"Thus\", \"Fri\", \"Sat\"],\n            buttonText: {\n                today: \"Today\",\n                day: \"Day\",\n                week:\"Week\",\n                month:\"Month\"\n            },\n            selectable: false,\n            selectHelper: false,\n            select: function(start, end, allDay) {\n                    jQuery('#AppFirstModal').show();\n                },\n\n            events: [\n                                        {\n                            title: \"Booked\",\n                            start: new Date(2017, 6, 13, 10, 00),\n                            end: new Date(2017, 6, 13, 10, 30),\n                            allDay: false,\n                            backgroundColor : \"#1FCB4A\",\n                            textColor: \"black\",\n                        },                         {\n                            title: \"Booked\",\n                            start: new Date(2017, 5, 22, 16, 30),\n                            end: new Date(2017, 5, 22, 17, 00),\n                            allDay: false,\n                            backgroundColor : \"#1FCB4A\",\n                            textColor: \"black\",\n                        },                         {\n                        }\n            ]\n        });\n\n        \/\/jQuery UI date picker on modal for\n        \/\/document.addnewappointment.appdate.value = jQuery.datepicker.formatDate('', new Date());\n        \/*jQuery(function(){\n            jQuery(\"#datepicker\").datepicker({\n                inline: true,\n                minDate: 0,\n                altField: '#alternate',\n                firstDay: ,\n                \/\/beforeShowDay: unavailable,\n                onSelect: function(dateText, inst) {\n                    var dateAsString = dateText;\n                    var seleteddate = jQuery.datepicker.formatDate('', new Date(dateAsString));\n                    var seleteddate2 = jQuery.datepicker.formatDate('dd-mm-yy', new Date(dateAsString));\n                    document.addnewappointment.appdate.value = seleteddate;\n                },\n            });\n            \/\/jQuery( \"#datepicker\" ).datepicker( jQuery.datepicker.regional[ \"af\" ] );\n        });*\/\n\n        \/\/Modal Form Works - show frist modal\n        jQuery('#addappointment').click(function(){\n            var todaydate = jQuery.fullCalendar.formatDate(new Date(),'dd-MM-yyyy');\n            jQuery('#appdate').val(todaydate);\n            jQuery('#AppFirstModal').show();\n        });\n\n        \/\/hide modal\n        jQuery('#close').click(function(){\n            jQuery('#AppFirstModal').hide();\n        });\n\n        \/\/AppFirstModal Validation\n        jQuery('#next1').click(function(){\n            jQuery(\".apcal-error\").hide();\n            if(jQuery('#service').val() == 0) {\n                jQuery(\"#service\").after(\"<span class='apcal-error'><br><strong>Select any service.<\/strong><\/span>\");\n                return false;\n            }\n            var ServiceId =  jQuery('#service').val();\n            var AppDate =  jQuery('#appdate').val();\n            var SecondData = \"ServiceId=\" + ServiceId + \"&AppDate=\" + AppDate;\n            jQuery('#loading1').show(); \/\/ loading button onclick next1 at first modal\n            jQuery('#next1').hide();    \/\/ hide next button\n            jQuery.ajax({\n            dataType : 'html',\n            type: 'GET',\n            url : location.href,\n            cache: false,\n            data : SecondData,\n            complete : function() {  },\n            success: function(data) {\n                    data = jQuery(data).find('div#AppSecondModal');\n                    jQuery('#loading1').hide();\n                    jQuery('#AppFirstModal').hide();\n                    jQuery('#AppSecondModalDiv').show();\n                    jQuery('#AppSecondModalDiv').html(data);\n                }\n            });\n        });\n\n        \/\/Second Modal form validation\n        jQuery('#booknowapp').click(function(){\n            jQuery(\".apcal-error\").hide();\n            var start_time = jQuery('input[name=start_time]:radio:checked').val();\n            if(!start_time) {\n                jQuery(\"#selecttimediv\").after(\"<span class='apcal-error'><br><strong>Select any time.<\/strong><\/span>\");\n                return false;\n            }\n\n            if( !jQuery('#clientname').val() ) {\n                jQuery(\"#clientname\").after(\"<span class='apcal-error'><br><strong>Name required.<\/strong><\/span>\");\n                return false;\n            } else if(!isNaN( jQuery('#clientname').val() )) {\n                jQuery(\"#clientname\").after(\"<span class='apcal-error'><p><strong>Invalid name.<\/strong><\/p><\/span>\");\n                return false;\n            }\n\n            var regex = \/^([a-zA-Z0-9_\\.\\-\\+])+\\@(([a-zA-Z0-9\\-])+\\.)+([a-zA-Z0-9]{2,4})+$\/;\n            if( !jQuery('#clientemail').val() ) {\n                jQuery(\"#clientemail\").after(\"<span class='apcal-error'><br><strong>Email required.<\/strong><\/span>\");\n                return false;\n            } else {\n                if(regex.test(jQuery('#clientemail').val()) == false ) {\n                    jQuery(\"#clientemail\").after(\"<span class='apcal-error'><p><strong>Invalid Email.<\/strong><\/p><\/span>\");\n                    return false;\n                }\n            }\n\n            if( !jQuery('#clientphone').val() ) {\n                jQuery(\"#clientphone\").after(\"<span class='apcal-error'><br><strong>Phone required.<\/strong><\/span>\");\n                return false;\n            } else if(isNaN( jQuery('#clientphone').val() )) {\n                jQuery(\"#clientphone\").after(\"<span class='apcal-error'><p><strong>Invalid phone number.<\/strong><\/p><\/span>\");\n                return false;\n            }\n        });\n\n        \/\/back button show first modal\n        jQuery('#back').click(function(){\n            jQuery('#AppFirstModal').show();\n            jQuery('#AppSecondModal').hide();\n        });\n    });\n\n\n    \/\/Modal Form Works\n    function Backbutton() {\n        jQuery('#AppFirstModal').show();\n        jQuery('#AppSecondModalDiv').hide();\n        jQuery('#next1').show();\n    }\n\n    \/\/validation on second modal form submissions == appointment_register_nonce_field\n    function CheckValidation() {\n        jQuery(\".apcal-error\").hide();\n        var start_time = jQuery('input[name=start_time]:radio:checked').val();\n        if(!start_time) {\n            jQuery(\"#selecttimediv\").after(\"<p style='width:350px; padding:2px;' class='apcal-error'><strong>Select any time.<\/strong><\/p>\");\n            return false;\n        }\n\n        if( !jQuery('#clientname').val() ) {\n            jQuery(\"#clientname\").after(\"<span class='apcal-error'><br><strong>Name required.<\/strong><\/span>\");\n            return false;\n        } else if(!isNaN( jQuery('#clientname').val() )) {\n            jQuery(\"#clientname\").after(\"<span class='apcal-error'><br><strong>Invalid Name<\/strong><\/span>\");\n            return false;\n        }\n\n        var regex = \/^([a-zA-Z0-9_\\.\\-\\+])+\\@(([a-zA-Z0-9\\-])+\\.)+([a-zA-Z0-9]{2,4})+$\/;\n        if( !jQuery('#clientemail').val() ) {\n            jQuery(\"#clientemail\").after(\"<span class='apcal-error'><br><strong>Email required.<\/strong><\/span>\");\n            return false;\n        } else {\n            if(regex.test(jQuery('#clientemail').val()) == false ) {\n                jQuery(\"#clientemail\").after(\"<span class='apcal-error'><br><strong>Invalid Email<\/strong><\/span>\");\n                return false;\n            }\n        }\n\n        if( !jQuery('#clientphone').val() ) {\n            jQuery(\"#clientphone\").after(\"<span class='apcal-error'><br><strong>Phone required.<\/strong><\/span>\");\n            return false;\n        } else if(isNaN( jQuery('#clientphone').val() )) {\n            jQuery(\"#clientphone\").after(\"<span class='apcal-error'><br><strong>Invalid phone number.<\/strong><\/span>\");\n            return false;\n        }\n\t\t\n\t\tvar wp_nonce = jQuery('#appointment_register_nonce_field').val();\n\t\t \n        var ServiceId = jQuery('#serviceid').val();\n        var AppDate = jQuery('#appointmentdate').val();\n        var  ServiceDuration =  jQuery('#serviceduration').val();\n        var StartTime = jQuery('input[name=start_time]:radio:checked').val();\n        var Client_Name =  jQuery('#clientname').val();\n        var Client_Email =  jQuery('#clientemail').val();\n        var Client_Phone =  jQuery('#clientphone').val();\n        var Client_Note =  jQuery('#clientnote').val();\n        var currenturl = jQuery(location).attr('href');\n        var SecondData = \"ServiceId=\" + ServiceId + \"&AppDate=\" + AppDate + \"&StartTime=\" + StartTime + '&Client_Name=' + Client_Name +'&Client_Email=' + Client_Email +'&Client_Phone=' + Client_Phone +'&Client_Note=' + Client_Note+'&Service_Duration=' + ServiceDuration + '&wp_nonce=' + wp_nonce;\n        var currenturl = jQuery(location).attr('href');\n        var url = currenturl;\n        jQuery('#loading2').show();     \/\/ loading button onclick next1 at first modal\n        jQuery('#buttonbox').hide();    \/\/ loading button onclick book now at first modal\n        jQuery.ajax({\n            dataType : 'html',\n            type: 'POST',\n            url : url,\n            cache: false,\n            data : SecondData,\n            complete : function() {  },\n            success: function() {\n                jQuery('#AppSecondModalDiv').hide();\n                alert(\"Thank you for scheduling appointment with us. A confirmation mail will be forward to you soon after admin approval.\");\n                var currenturl = jQuery(location).attr('href');\n                var url = currenturl.replace(\"#\",\"\");\n                window.location = url;\n            }\n        });\n    }\n    <\/script>\n    <style type='text\/css'>\n    .apcal-error{\n        color: #FF0000;\n    }\n    <\/style>\n\n    <!---Display Booking Instruction--->\n        <div id=\"bookinginstructions\" align=\"center\">\n        Put your booking instructions here.<br>Or you can save It blank in case of nothing want to display.    <\/div>\n    \n    <!---Schedule New New Appointment Button--->\n    <div id=\"bkbtndiv\" align=\"center\" style=\"padding:5px;\">\n        <button name=\"addappointment\" class=\"apcal_btn apcal_btn-primary apcal_btn-large\" type=\"submit\" id=\"addappointment\">\n            <strong><\/strong><i class=\"icon-calendar icon-white\"><\/i>\n                Schedule An Appointment            <\/strong>\n        <\/button>\n    <\/div>\n\n\n    <!---AppFirstModal For Schedule New Appointment--->\n    <div id=\"AppFirstModal\" style=\"display:none\">\n        <div class=\"apcal_modal\" id=\"myModal\" style=\"z-index:99999;\">\n            <form action=\"\" method=\"post\" name=\"addnewappointment\" id=\"addnewappointment\" >\n                <div class=\"apcal_modal-info\">\n                    <div class=\"apcal_alert apcal_alert-info\">\n                        <div><a href=\"#\" style=\"float:right; margin-right:-4px;\" id=\"close\"><i class=\"icon-remove\"><\/i><\/a>\n                        <\/div>\n                        <p><strong>Schedule New Appointment<\/strong><\/p>\n                        <div>Select Date & Service<\/div>\n                    <\/div>\n                <\/div>\n\n                <div class=\"apcal_modal-body\">\n                    <div id=\"firdiv\" style=\"float:left;\">\n                        <div id=\"datepicker\"><\/div>\n\n                         <!--PHP Date-picker -->\n                         <form id=\"form1\" name=\"form1\" method=\"post\" action=\"\">\n\t\t\t\t\t\t \n                         <SCRIPT TYPE=\"text\/javascript\" LANGUAGE=\"JavaScript\">\n<!--\n\/\/\tJS strings\n\tvar l_lang = \"en_US\";\n\tvar l_sel_date = \"Select Date\";\n\tvar l_not_allowed = \"This date is not allowed to be selected\";\n\tvar l_date_before = \"Please choose a date before %s\";\n\tvar l_date_after = \"Please choose a date after %s\";\n\tvar l_date_between = \"Please choose a date between\\n%s and %s\";\n\tvar l_use_ymd_drop = \"0\";\n\tvar l_day = \"Day\";\n\tvar l_month = \"Month\";\n\tvar l_year = \"Year\";\n\/\/\tLong Month Names\n\tvar l_january = \"January\";\n\tvar l_february = \"February\";\n\tvar l_march = \"March\";\n\tvar l_april = \"April\";\n\tvar l_may = \"May\";\n\tvar l_june = \"June\";\n\tvar l_july = \"July\";\n\tvar l_august = \"August\";\n\tvar l_september = \"September\";\n\tvar l_october = \"October\";\n\tvar l_november = \"November\";\n\tvar l_december = \"December\";\nif(l_lang == \"el_GR\"){\n\/\/\tDate Month Names Greek\n\tvar l_januaryu = \"\";\n\tvar l_februaryu = \"\";\n\tvar l_marchu = \"\";\n\tvar l_aprilu = \"\";\n\tvar l_mayu = \"\";\n\tvar l_juneu = \"\";\n\tvar l_julyu = \"\";\n\tvar l_augustu = \"\";\n\tvar l_septemberu = \"\";\n\tvar l_octoberu = \"\";\n\tvar l_novemberu = \"\";\n\tvar l_decemberu = \"\";\n}\n\/\/\tShort Month Names\n\tvar s_jan = \"Jan\";\n\tvar s_feb = \"Feb\";\n\tvar s_mar = \"Mar\";\n\tvar s_apr = \"Apr\";\n\tvar s_may = \"May\";\n\tvar s_jun = \"Jun\";\n\tvar s_jul = \"Jul\";\n\tvar s_aug = \"Aug\";\n\tvar s_sep = \"Sep\";\n\tvar s_oct = \"Oct\";\n\tvar s_nov = \"Nov\";\n\tvar s_dec = \"Dec\";\n\/\/\tLong Day Names\n\tvar l_monday = \"Monday\";\n\tvar l_tuesday = \"Tuesday\";\n\tvar l_wednesday = \"Wednesday\";\n\tvar l_thursday = \"Thursday\";\n\tvar l_friday = \"Friday\";\n\tvar l_saturday = \"Saturday\";\n\tvar l_sunday = \"Sunday\";\n\/\/\tShort Day Names\n\tvar s_mon = \"Mo\";\n\tvar s_tue = \"Tu\";\n\tvar s_wed = \"We\";\n\tvar s_thu = \"Th\";\n\tvar s_fri = \"Fr\";\n\tvar s_sat = \"Sa\";\n\tvar s_sun = \"Su\";\n\/\/ -->\n<\/SCRIPT>\n<input type=\"hidden\" name=\"date1\" id=\"date1\" value=\"2026-04-06\" \/><input type=\"hidden\" name=\"date1_dp\" id=\"date1_dp\" value=\"\" \/><input type=\"hidden\" name=\"date1_year_start\" id=\"date1_year_start\" value=\"2026\" \/><input type=\"hidden\" name=\"date1_year_end\" id=\"date1_year_end\" value=\"2035\" \/><input type=\"hidden\" name=\"date1_da1\" id=\"date1_da1\" value=\"1775347200\" \/><input type=\"hidden\" name=\"date1_da2\" id=\"date1_da2\" value=\"2051222400\" \/><input type=\"hidden\" name=\"date1_sna\" id=\"date1_sna\" value=\"\" \/><input type=\"hidden\" name=\"date1_aut\" id=\"date1_aut\" value=\"\" \/><input type=\"hidden\" name=\"date1_frm\" id=\"date1_frm\" value=\"\" \/><input type=\"hidden\" name=\"date1_tar\" id=\"date1_tar\" value=\"\" \/><input type=\"hidden\" name=\"date1_inp\" id=\"date1_inp\" value=\"1\" \/><input type=\"hidden\" name=\"date1_fmt\" id=\"date1_fmt\" value=\"F j, Y\" \/><input type=\"hidden\" name=\"date1_dis\" id=\"date1_dis\" value=\"\" \/><input type=\"hidden\" name=\"date1_pr1\" id=\"date1_pr1\" value=\"\" \/><input type=\"hidden\" name=\"date1_pr2\" id=\"date1_pr2\" value=\"\" \/><input type=\"hidden\" name=\"date1_prv\" id=\"date1_prv\" value=\"\" \/><input type=\"hidden\" name=\"date1_pth\" id=\"date1_pth\" value=\"https:\/\/certy.px-lab.com\/florist\/wp-content\/plugins\/appointment-calendar\/calendar\/\" \/><input type=\"hidden\" name=\"date1_spd\" id=\"date1_spd\" value=\"[[],[],[]]\" \/><input type=\"hidden\" name=\"date1_spt\" id=\"date1_spt\" value=\"0\" \/><input type=\"hidden\" name=\"date1_och\" id=\"date1_och\" value=\"myChanged%28%29\" \/><input type=\"hidden\" name=\"date1_str\" id=\"date1_str\" value=\"0\" \/><input type=\"hidden\" name=\"date1_rtl\" id=\"date1_rtl\" value=\"0\" \/><input type=\"hidden\" name=\"date1_wks\" id=\"date1_wks\" value=\"\" \/><input type=\"hidden\" name=\"date1_int\" id=\"date1_int\" value=\"1\" \/><input type=\"hidden\" name=\"date1_hid\" id=\"date1_hid\" value=\"1\" \/><input type=\"hidden\" name=\"date1_hdt\" id=\"date1_hdt\" value=\"1000\" \/><input type=\"hidden\" name=\"date1_hl\" id=\"date1_hl\" value=\"en_US\" \/><div id=\"div_date1\" style=\"position:relative;visibility:visible;z-index:100;;margin-left:20px\" class=\"div_calendar calendar-border\"   onmouseover=\"javascript:cancelHide('date1');\"><IFRAME id=\"date1_frame\" src=\"https:\/\/certy.px-lab.com\/florist\/wp-content\/plugins\/appointment-calendar\/calendar\/calendar_form.php?objname=date1&selected_day=06&selected_month=04&selected_year=2026&year_start=2026&year_end=2035&dp=0&da1=1775347200&da2=2051222400&sna=&aut=&frm=&tar=&inp=1&fmt=F j, Y&dis=&pr1=&pr2=&prv=&pth=https:\/\/certy.px-lab.com\/florist\/wp-content\/plugins\/appointment-calendar\/calendar\/&spd=[[],[],[]]&spt=0&och=myChanged%28%29&str=0&rtl=0&wks=&int=1&hid=1&hdt=1000&hl=en_US\" frameBorder=\"0\" scrolling=\"no\" allowtransparency=\"true\" width=\"250px\" height=\"100%\" style=\"z-index: 100;height:201px;\" margin-left=20px><\/IFRAME><\/div>\t\t\t\t\t\t\t\n                        <\/form>\n\n                        <script language=\"javascript\">\n                        function myChanged() {\n                            var x = document.getElementById('date1').value;\n                            x = moment(x).format('DD-MM-YYYY');\n                            document.getElementById('appdate').value = x;\n                        }\n                        <\/script>\n                    <\/div>\n\n                    <div id=\"secdiv\" style=\"float:right;\">\n                        <strong>Your Appointment Date:<\/strong><br>\n                        <input name=\"appdate\" id=\"appdate\" type=\"text\" readonly=\"\" height=\"30px;\" style=\"height:30px;\" \/>\n                        \n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t<br \/><br \/>\n                        <strong>Select Service:<\/strong><br \/>\n                        <select name=\"service\" id=\"service\">\n                            <option value=\"0\">Select Service<\/option>\n                                                                                                                                            <option value=\"1\">\n                                        Default (30min\/$100)                                    <\/option>\n                                                        <\/select>\n                        <br>\n                        <button name=\"next1\" class=\"apcal_btn\" type=\"button\" id=\"next1\" value=\"next1\">Next <i class=\"icon-arrow-right\"><\/i><\/button>\n                        <div id=\"loading1\" style=\"display:none;\">Loading...<img src=\"https:\/\/certy.px-lab.com\/florist\/wp-content\/plugins\/appointment-calendar\/images\/loading.gif\" \/><\/div>\n                    <\/div>\n                <\/div>\n            <\/form>\n          <\/div>\n    <\/div>\n    <!---AppSecondModal For Schedule New Appointment--->\n\t\n    <\/strong><\/p>\n<!-- AddThis Advanced Settings generic via filter on the_content --><!-- AddThis Share Buttons generic via filter on the_content -->","protected":false},"excerpt":{"rendered":"<p><!-- AddThis Advanced Settings generic via filter on get_the_excerpt --><!-- AddThis Share Buttons generic via filter on get_the_excerpt --><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_mi_skip_tracking":false},"acf":[],"_links":{"self":[{"href":"https:\/\/certy.px-lab.com\/florist\/wp-json\/wp\/v2\/pages\/113"}],"collection":[{"href":"https:\/\/certy.px-lab.com\/florist\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/certy.px-lab.com\/florist\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/certy.px-lab.com\/florist\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/certy.px-lab.com\/florist\/wp-json\/wp\/v2\/comments?post=113"}],"version-history":[{"count":0,"href":"https:\/\/certy.px-lab.com\/florist\/wp-json\/wp\/v2\/pages\/113\/revisions"}],"wp:attachment":[{"href":"https:\/\/certy.px-lab.com\/florist\/wp-json\/wp\/v2\/media?parent=113"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}