Plugin Directory

Changeset 2393208


Ignore:
Timestamp:
10/04/2020 06:10:35 PM (5 years ago)
Author:
setriosoft
Message:

BizCalendar Web 1.0.6.6

Location:
bizcalendar-web
Files:
150 added
6 edited

Legend:

Unmodified
Added
Removed
  • bizcalendar-web/trunk/bizcalendar.php

    r2311433 r2393208  
    22/**
    33 * @package BizCalendarWeb
    4  * @version 1.0.6.5
     4 * @version 1.0.6.6
    55 */
    66/*
     
    99Description: Modul de programări online pentru clinicile medicale care folosesc BizMedica / Online appointments form for medical clinics using BizMedica software
    1010Author: Setrio Soft
    11 Version: 1.0.6.5
     11Version: 1.0.6.6
    1212Author URI: http://www.setrio.ro/
    1313*/
     
    3030
    3131add_filter('body_class', 'setrio_bizcal_add_customer_body_class');
     32add_filter('clean_url', 'setrio_bizcal_add_async_forrecaptcha', 11, 1);
    3233
    3334/// Admin
  • bizcalendar-web/trunk/css/bizcalendar.css

    r2311189 r2393208  
    280280}
    281281
    282 .bizcal-main-box div.g-recaptcha {
     282.bizcal-main-box div.zzzg-recaptcha {
    283283    float: left;
    284284    clear: left;
     
    740740
    741741body._35200141_digestmed_srl .bizcal-main-box span.ui-dialog-title {
    742     color: white;
     742    color: white;
    743743}
    744744
    745745body._35200141_digestmed_srl .bizcal-main-box div.ui-dialog {
    746     z-index: 999990 !important;
     746    z-index: 999990 !important;
    747747}
    748748
     
    754754
    755755div.hurmuz-med .bizcal-main-box div.g-recaptcha {
    756     float: left;
    757     clear: both;
     756    float: left;
     757    clear: both;
    758758}
    759759
    760760div.hurmuz-med .bizcal-main-box #bizcal-register-appointment-button {
    761     float: left;
    762     clear: both;
     761    float: left;
     762    clear: both;
    763763}
    764764
     
    772772
    773773body._37155047_sofimed_iasi_srl div.bizcal-sel-appointment-params-container {
    774     float: left;
    775     width: 50%;
     774    float: left;
     775    width: 50%;
    776776}
    777777
    778778body._37155047_sofimed_iasi_srl div.bizcal-sel-appointment-date-container {
    779     float: right;
    780     width: 48%;
     779    float: right;
     780    width: 48%;
    781781}
    782782
    783783body._37155047_sofimed_iasi_srl div.bizcal-ra-last-name-container, body._37155047_sofimed_iasi_srl div.bizcal-ra-phone-container {
    784     clear: left;
    785     float: left;
    786     width: 50%;
     784    clear: left;
     785    float: left;
     786    width: 50%;
    787787}
    788788
    789789body._37155047_sofimed_iasi_srl div.bizcal-ra-first-name-container, body._37155047_sofimed_iasi_srl div.bizcal-ra-email-container {
    790     float: right;
    791     width: 48%;
     790    float: right;
     791    width: 48%;
    792792}
    793793
     
    803803
    804804div.imd-fluid-layout div.bizcal-main-box {
    805     margin-left: 25%;
    806     margin-right: 25%;
     805    margin-left: 25%;
     806    margin-right: 25%;
    807807}
    808808
     
    819819
    820820div.imd-fluid-layout .bizcal-main-box .ui-state-default, div.imd-fluid-layout .bizcal-main-box .ui-widget-content .ui-state-default {
    821     border-radius: 0;
    822     font-size: 100%;
     821    border-radius: 0;
     822    font-size: 100%;
    823823}
    824824
    825825div.imd-fluid-layout .bizcal-main-box .ui-widget-header {
    826     background-color: #006591;
    827     border-color: #016692;
    828     background-image: none;
     826    background-color: #006591;
     827    border-color: #016692;
     828    background-image: none;
    829829}
    830830
    831831div.imd-fluid-layout .bizcal-main-box .ui-widget-header .ui-icon {
    832     background-image: url("images/ui-icons_ffffff_256x240.png");
     832    background-image: url("images/ui-icons_ffffff_256x240.png");
    833833}
    834834
    835835div.imd-fluid-layout .bizcal-main-box .ui-dialog-titlebar-close, div.imd-fluid-layout .bizcal-main-box .ui-datepicker-prev, div.imd-fluid-layout .bizcal-main-box .ui-datepicker-next {
    836     background-color: #006591;
     836    background-color: #006591;
    837837}
    838838
    839839div.imd-fluid-layout .bizcal-main-box .ui-dialog-titlebar-close {
    840     background-image: url("images/ui-icons_ffffff_256x240.png");
    841     background-position: -94px -126px;
     840    background-image: url("images/ui-icons_ffffff_256x240.png");
     841    background-position: -94px -126px;
    842842}
    843843
    844844div.imd-fluid-layout .bizcal-main-box .ui-dialog-titlebar-close:hover, div.imd-fluid-layout .bizcal-main-box .ui-datepicker-prev:hover,
    845845div.imd-fluid-layout .bizcal-main-box .ui-datepicker-next:hover, div.imd-fluid-layout .bizcal-main-box .ui-state-hover {
    846     background-color: #1075a1;
     846    background-color: #1075a1;
    847847}
    848848
    849849div.imd-fluid-layout .bizcal-main-box .setrio-bizcal-available-physician-name {
    850     color: black;
     850    color: black;
    851851}
    852852
    853853div.imd-fluid-layout .bizcal-main-box a.bizcal-bme-logo {
    854     border-radius: 0;
    855     width: calc(100% - 340px);
    856     background-color: transparent;
    857 }
    858    
     854    border-radius: 0;
     855    width: calc(100% - 340px);
     856    background-color: transparent;
     857}
     858   
    859859/* VITALITY */
    860860
    861861div.zn_pb_wrapper .bizcal-main-box div.g-recaptcha {
    862     float: left;
    863     clear: both;
     862    float: left;
     863    clear: both;
    864864}
    865865
     
    871871
    872872div.zn_pb_wrapper .bizcal-main-box .ui-widget-header {
    873     background-color: #78c1b9;
    874     background-image: url('#');
    875     border-color: #78c1b9;
     873    background-color: #78c1b9;
     874    background-image: url('#');
     875    border-color: #78c1b9;
    876876}
    877877
     
    879879
    880880body.fusion-avatar-square .bizcal-main-box div.g-recaptcha {
    881     float: left;
    882     clear: both;
     881    float: left;
     882    clear: both;
    883883}
    884884
     
    889889
    890890body.fusion-avatar-square .bizcal-main-box span.select2-selection__arrow {
    891     height: inherit !important;
     891    height: inherit !important;
    892892}
    893893
    894894body.fusion-avatar-square .bizcal-main-box .select2-selection__rendered {
    895     line-height: 29px !important;   
    896     padding-right: 50px;
     895    line-height: 29px !important;   
     896    padding-right: 50px;
    897897}
    898898
    899899body.fusion-avatar-square .bizcal-main-box .ui-widget-header {
    900     background-color: #812e2f;
    901     border-color: #822f2e;
    902     background-image: none;
     900    background-color: #812e2f;
     901    border-color: #822f2e;
     902    background-image: none;
    903903}
    904904
    905905body.fusion-avatar-square .bizcal-main-box .ui-button {
    906     color: #812e2f;
     906    color: #812e2f;
    907907}
    908908
    909909body.fusion-avatar-square .bizcal-main-box #bizcal-register-appointment-button {
    910     background-color: #812e2f;
    911     border-color: #822f2e;
    912     background-image: none;
    913     color: white;
     910    background-color: #812e2f;
     911    border-color: #822f2e;
     912    background-image: none;
     913    color: white;
    914914}
    915915
    916916body.fusion-avatar-square .bizcal-main-box .ui-state-focus,
    917     body.fusion-avatar-square .bizcal-main-box .ui-widget-content .ui-state-focus,
    918     body.fusion-avatar-square .bizcal-main-box .ui-widget-header .ui-state-focus,
    919     body.fusion-avatar-square .bizcal-main-box .ui-button:focus,
    920     body.fusion-avatar-square .bizcal-main-box #bizcal-sel-time .ui-selected{
    921     background-color: #812e2f;
    922     border-color: #822f2e;
    923     background-image: none;
    924     color: white;
     917    body.fusion-avatar-square .bizcal-main-box .ui-widget-content .ui-state-focus,
     918    body.fusion-avatar-square .bizcal-main-box .ui-widget-header .ui-state-focus,
     919    body.fusion-avatar-square .bizcal-main-box .ui-button:focus,
     920    body.fusion-avatar-square .bizcal-main-box #bizcal-sel-time .ui-selected{
     921    background-color: #812e2f;
     922    border-color: #822f2e;
     923    background-image: none;
     924    color: white;
    925925}
    926926
    927927body.fusion-avatar-square .bizcal-main-box .ui-state-hover,
    928     body.fusion-avatar-square .bizcal-main-box .ui-widget-content .ui-state-hover,
    929     body.fusion-avatar-square .bizcal-main-box .ui-widget-header .ui-state-hover,
    930     body.fusion-avatar-square .bizcal-main-box .ui-button:hover {
    931     background-color: #af2123;
    932     border-color: #ae2224;
    933     background-image: none;
    934     color: white;
     928    body.fusion-avatar-square .bizcal-main-box .ui-widget-content .ui-state-hover,
     929    body.fusion-avatar-square .bizcal-main-box .ui-widget-header .ui-state-hover,
     930    body.fusion-avatar-square .bizcal-main-box .ui-button:hover {
     931    background-color: #af2123;
     932    border-color: #ae2224;
     933    background-image: none;
     934    color: white;
    935935}
    936936
     
    938938
    939939body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget {
    940     z-index: auto !important;
     940    z-index: auto !important;
    941941}
    942942
    943943body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-header {
    944     padding: 0;
     944    padding: 0;
    945945}
    946946
    947947body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-header .ui-datepicker-prev,
    948948body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-header .ui-datepicker-next {
    949     height: 32px;
     949    height: 32px;
    950950}
    951951
     
    954954body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-header .ui-datepicker-prev-hover,
    955955body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-header .ui-datepicker-next-hover {
    956     line-height: 1em;
     956    line-height: 1em;
    957957}
    958958
    959959body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-calendar {
    960     line-height: 16px;
     960    line-height: 16px;
    961961}
    962962
    963963body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-calendar th {
    964     padding: 8px 2px;
     964    padding: 8px 2px;
    965965}
    966966
     
    969969body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-calendar td a.ui-state-hover,
    970970body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-calendar td a:hover {
    971     padding: 8px 2px;
    972     margin: 0;
    973     border: solid 1px transparent;
     971    padding: 8px 2px;
     972    margin: 0;
     973    border: solid 1px transparent;
    974974}
    975975
    976976body._32107197_sante_vera_med_srl .bizcal-main-box .ui-datepicker.ui-widget .ui-datepicker-calendar th span {
    977     padding: 0;
     977    padding: 0;
    978978}
    979979
    980980body._32107197_sante_vera_med_srl .bizcal-main-box .col-lg-8 {
    981     width: 65%;
    982     float: left;
     981    width: 65%;
     982    float: left;
    983983}
    984984
    985985body._32107197_sante_vera_med_srl .bizcal-main-box .col-lg-4 {
    986     width: 33%;
    987     float: right;
    988     clear: right;
     986    width: 33%;
     987    float: right;
     988    clear: right;
    989989}
    990990
     
    995995body._32107197_sante_vera_med_srl .bizcal-main-box span#select2-bizcal-sel-med-container,
    996996body._32107197_sante_vera_med_srl .bizcal-main-box span#select2-bizcal-sel-preferred-physician-container {
    997     padding: 0 20px 0 8px;
    998     text-align: left;
     997    padding: 0 20px 0 8px;
     998    text-align: left;
    999999}
    10001000
     
    10051005body._32107197_sante_vera_med_srl ul#select2-bizcal-sel-med-results .select2-results__option,
    10061006body._32107197_sante_vera_med_srl ul#select2-bizcal-sel-preferred-physician-results .select2-results__option {
    1007     min-height: 24px;
    1008     height: auto;
     1007    min-height: 24px;
     1008    height: auto;
    10091009}
    10101010
     
    10211021body._32107197_sante_vera_med_srl ul#select2-bizcal-sel-preferred-physician-results .select2-results__option--highlighted[aria-selected],
    10221022body._32107197_sante_vera_med_srl ul#select2-bizcal-sel-preferred-physician-results .select2-results__option--highlighted[data-selected] {
    1023     background-color: #5897fb;
     1023    background-color: #5897fb;
    10241024}
    10251025
    10261026body._32107197_sante_vera_med_srl .bizcal-main-box #bizcal-register-appointment-button {
    1027     background-color: #03433f;
    1028     color: white;
    1029     font-size: 120%;
    1030     font-weight: bold;
     1027    background-color: #03433f;
     1028    color: white;
     1029    font-size: 120%;
     1030    font-weight: bold;
    10311031}
    10321032
    10331033body._32107197_sante_vera_med_srl .bizcal-main-box li.setrio-bizcal-available-physician {
    1034     text-align: left;
     1034    text-align: left;
    10351035}
    10361036
    10371037body._32107197_sante_vera_med_srl .bizcal-main-box label {
    1038     text-align: left;
     1038    text-align: left;
    10391039}
    10401040
    10411041body._32107197_sante_vera_med_srl .bizcal-main-box {
    1042     margin-top: 2em;
     1042    margin-top: 2em;
    10431043}
    10441044
     
    10461046
    10471047body._34640950_neurology_clinic_srl #select2-bizcal-sel-serv-results li div.price {
    1048     font-size: 12pt !important;
    1049     font-weight: 400 !important;
     1048    font-size: 12pt !important;
     1049    font-weight: 400 !important;
    10501050}
    10511051
     
    10531053
    10541054body._30421621_innovative_constanta .bizcal-main-box div.ui-dialog {
    1055     z-index: 1040;
     1055    z-index: 1040;
    10561056}
    10571057
     
    10621062
    10631063body._30421621_innovative_constanta .bizcal-main-box .ui-widget-header {
    1064     background-color: #C4001D;
    1065     border-color: #C4001D;
    1066     background-image: none;
     1064    background-color: #C4001D;
     1065    border-color: #C4001D;
     1066    background-image: none;
    10671067}
    10681068
    10691069body._30421621_innovative_constanta .bizcal-main-box .ui-dialog-titlebar-close {
    1070     background-image: none;
    1071     background-color: #C4001D;
     1070    background-image: none;
     1071    background-color: #C4001D;
    10721072}
    10731073
    10741074body._30421621_innovative_constanta .bizcal-main-box .ui-widget-header .ui-icon {
    1075     background-image: url("images/ui-icons_ffffff_256x240.png");
    1076     background-color: #D4102D;
     1075    background-image: url("images/ui-icons_ffffff_256x240.png");
     1076    background-color: #D4102D;
    10771077}
    10781078
    10791079body._30421621_innovative_constanta .bizcal-main-box .ui-dialog-titlebar-close, body._30421621_innovative_constanta .bizcal-main-box .ui-datepicker-prev,
    10801080    body._30421621_innovative_constanta .bizcal-main-box .ui-datepicker-next {
    1081     background-color: #D4102D;
     1081    background-color: #D4102D;
    10821082}
    10831083
    10841084body._112121_30421621_innovative_constanta .bizcal-main-box .ui-dialog-titlebar-close {
    1085     background-image: url("images/ui-icons_ffffff_256x240.png");
    1086     background-position: -94px -126px;
     1085    background-image: url("images/ui-icons_ffffff_256x240.png");
     1086    background-position: -94px -126px;
    10871087}
    10881088body._30421621_innovative_constanta .bizcal-main-box .ui-dialog-titlebar-close:hover,
    10891089    body._30421621_innovative_constanta .bizcal-main-box .ui-datepicker-prev:hover,
    10901090    body._30421621_innovative_constanta .bizcal-main-box .ui-datepicker-next:hover,
    1091     body._30421621_innovative_constanta #bizcal-sel-date .ui-state-hover {
    1092         background-color: #D4102D !important;
    1093         background-image: none;
     1091    body._30421621_innovative_constanta #bizcal-sel-date .ui-state-hover {
     1092        background-color: #D4102D !important;
     1093        background-image: none;
    10941094}
    10951095
     
    11881188
    11891189body._34556214_opticlinic_bucegi .bizcal-main-box .ui-widget-content .col-lg-8,
    1190     body._34556214_opticlinic_bucegi .bizcal-main-box .ui-widget-content .col-xl-8
     1190    body._34556214_opticlinic_bucegi .bizcal-main-box .ui-widget-content .col-xl-8
    11911191{
    11921192               flex-basis: 61.6667%;
     
    12351235    text-align: center;
    12361236}
     1237
     1238/* MISO MEDICAL SRL */
     1239
     1240body._ro34807898_miso_medical_srl .bizcal-main-box .selection-box:before {
     1241    right: 11px;
     1242    top: -9px;
     1243}
     1244
     1245body._ro34807898_miso_medical_srl .bizcal-main-box .selection-box:after {
     1246    width: 36px;
     1247    height: 36px;
     1248}
     1249
     1250body._ro34807898_miso_medical_srl .bizcal-main-box input[type="search"],
     1251    body._ro34807898_miso_medical_srl .bizcal-main-box input[type="text"],
     1252    body._ro34807898_miso_medical_srl .bizcal-main-box input.text {
     1253    height: 36px;
     1254}
     1255
     1256body._ro34807898_miso_medical_srl .bizcal-main-box div.ui-dialog {
     1257    z-index: 999990 !important;
     1258}
     1259
     1260body._ro34807898_miso_medical_srl .select2-container--open {
     1261    z-index: 999991 !important;
     1262}
     1263
     1264body._ro34807898_miso_medical_srl .bizcal-main-box .ui-widget-header {
     1265    background-color: #7a2f53;
     1266    border-color: #b65483;
     1267    background-image: none;
     1268}
     1269
     1270body._ro34807898_miso_medical_srl .bizcal-main-box .ui-dialog-titlebar-close:hover,
     1271    body._ro34807898_miso_medical_srl .bizcal-main-box .ui-datepicker-prev:hover,
     1272    body._ro34807898_miso_medical_srl .bizcal-main-box .ui-datepicker-next:hover,
     1273    body._ro34807898_miso_medical_srl #bizcal-sel-date .ui-state-hover {
     1274        background-color: #b65483 !important;
     1275        color: white;
     1276        background-image: none;
     1277        border-color: #b68453;
     1278}
     1279
     1280body._ro34807898_miso_medical_srl .bizcal-main-box div#bizcal-sel-time-container .ui-selected,
     1281body._ro34807898_miso_medical_srl .bizcal-main-box div#bizcal-sel-time-container li.ui-selected:hover,
     1282body._ro34807898_miso_medical_srl .bizcal-main-box div#bizcal-sel-time-container li.ui-selected:focus {
     1283    background: #7a2f53;
     1284    color: white;
     1285    border-color: #b68453;
     1286}
     1287
     1288body._ro34807898_miso_medical_srl .bizcal-main-box .ui-dialog-titlebar-close {
     1289    background-image: none;
     1290    background-color: #7a2f53;
     1291}
     1292
     1293body._ro34807898_miso_medical_srl .bizcal-main-box .ui-icon-closethick {
     1294    background-image: url("images/ui-icons_ffffff_256x240.png");
     1295}
     1296
     1297body._ro34807898_miso_medical_srl #bizcal-sel-date a.ui-state-active {
     1298    background-color: #7a2f53;
     1299    background-image: none;
     1300}
     1301
     1302body._ro34807898_miso_medical_srl .bizcal-main-box .ui-state-default,
     1303    body._ro34807898_miso_medical_srl .bizcal-main-box .ui-widget-content .ui-state-default {
     1304        color: #7a2f53;
     1305        border-color: #b68453;
     1306}
     1307
     1308body._ro34807898_miso_medical_srl .bizcal-main-box div#bizcal-sel-time-container .ui-button:hover,
     1309body._ro34807898_miso_medical_srl .bizcal-main-box div#bizcal-sel-time-container .ui-button:focus {
     1310    border: 1px solid #b68453;
     1311    background-color: #7a2f53;
     1312    background-image: none;
     1313    font-weight: bold;
     1314    color: #ffffff;
     1315}
  • bizcalendar-web/trunk/js/bizcalendar.js

    r2311433 r2393208  
    4545    return str;
    4646};
     47
     48function BizcalRenderCaptcha()
     49{
     50    grecaptcha.render('bizcal-g-recaptcha', {'sitekey' : setrio_bizcal_ajax.g_site_key});
     51}
    4752
    4853function compareMedicalSpecialities(a, b)
     
    350355function wsGetMedicalServices(speciality_code)
    351356{
     357    selectedLocationUID = null;
     358    if (setrio_bizcal_ajax.enable_multiple_locations)
     359    {
     360        selectedLocationUID = getSelectedLocationUID();
     361        if (selectedLocationUID == "")
     362        {
     363            jQuery(".bizcal-sel-serv").attr("data-placeholder", setrio_bizcal_ajax.msg_medical_service_placeholder);
     364            jQuery("span#select2-bizcal-sel-serv-container span.select2-selection__placeholder").text(setrio_bizcal_ajax.msg_medical_service_placeholder);
     365            return;
     366        }
     367    }
     368   
    352369    if (bizcalReqGetMedicalServices != null)
    353370    {
     
    355372        bizcalReqGetMedicalServices = null;
    356373    }
    357    
    358     selectedLocationUID = null;
    359     if (setrio_bizcal_ajax.enable_multiple_locations)
    360         selectedLocationUID = getSelectedLocationUID();
    361374   
    362375    jQuery(".bizcal-sel-serv").val(null).trigger("change");
     
    788801    console.log("INIT - wsGetMedicalServicesPriceList");
    789802   
     803    selectedLocationUID = null;
     804    if (setrio_bizcal_ajax.enable_multiple_locations)
     805    {
     806        selectedLocationUID = getSelectedLocationUID();
     807        if (selectedLocationUID == "")
     808        {
     809            jQuery(".bizcal-sel-serv").attr("data-placeholder", setrio_bizcal_ajax.msg_medical_service_placeholder);
     810            jQuery("span#select2-bizcal-sel-serv-container span.select2-selection__placeholder").text(setrio_bizcal_ajax.msg_medical_service_placeholder);
     811            return;
     812        }
     813    }
     814   
    790815    if (bizcalReqGetMedicalServices != null)
    791816    {
     
    793818        bizcalReqGetMedicalServices = null;
    794819    }
    795    
    796     selectedLocationUID = null;
    797     if (setrio_bizcal_ajax.enable_multiple_locations)
    798         selectedLocationUID = getSelectedLocationUID();
    799    
     820 
    800821    bizcalReqGetMedicalServices = jQuery.post({
    801822            url: setrio_bizcal_ajax.ajax_url,
     
    14091430    resetTips();
    14101431   
    1411     bizcalRAReCaptcha = jQuery("#g-recaptcha-response");
     1432    bizcalRAReCaptcha = jQuery("div#bizcal-g-recaptcha textarea.g-recaptcha-response");
    14121433 
    14131434    valid = checkLength(bizcalRAPhysicianUID, setrio_bizcal_ajax.msg_fld_physician) && valid;
  • bizcalendar-web/trunk/main.php

    r2311421 r2393208  
    1212
    1313// INREGISTRARE PLUGIN IN WORDPRESS
     14
     15function setrio_bizcal_add_async_forrecaptcha($url)
     16{
     17    if (strpos($url, '#bizcalgrecaptchaload')===false)
     18        return $url;
     19    else if (is_admin())
     20        return str_replace('#bizcalgrecaptchaload', '', $url);
     21    else
     22        return str_replace('#bizcalgrecaptchaload', '&hl=ro&onload=BizcalRenderCaptcha&render=explicit', $url)."' async='async' defer='defer";
     23}
     24
    1425
    1526function setrio_bizcal_enqueue_scripts($hook)
     
    2435    wp_enqueue_script('jquery-ui-datepicker-ro');
    2536    wp_enqueue_script('jquery-ui-dialog');
    26     wp_enqueue_script('setrio-bizcal-recaptcha', 'https://www.google.com/recaptcha/api.js?hl=ro', [], false, true);
     37    wp_enqueue_script('setrio-bizcal-recaptcha', 'https://www.google.com/recaptcha/api.js?#bizcalgrecaptchaload', [], false, true);
    2738    wp_enqueue_script('setrio-bizcal-select2-script', plugins_url( '/select2/js/select2.full.js', __FILE__ ), array('jquery'));
    2839    wp_enqueue_script('setrio-bizcal-select2-script-jui', plugins_url( '/select2/js/select2-jquery-ui.js', __FILE__ ), array('jquery'));
     
    5970    $minDaysToAppointment = (int)get_option('setrio_bizcal_min_days_to_appointment', 0);
    6071    $appointmentParamOrder = (int)get_option('setrio_bizcal_appointment_param_order', 0);
     72    $reCaptchaSiteKey = get_option('setrio_bizcal_g_site_key', '');
    6173   
    6274    wp_localize_script('setrio-bizcalendar', 'setrio_bizcal_ajax', array(
     
    7789        'min_days_to_appointment' => $minDaysToAppointment,
    7890        'appointment_param_order' => $appointmentParamOrder,
     91        'g_site_key' => $reCaptchaSiteKey,
    7992        'msg_error' => setrio_bizcal_message('msgError'),
    8093        'msg_warning' => setrio_bizcal_message('msgWarning'),
     
    126139    $setrio_bizcal_reCaptchaResponse = null;
    127140    if (($setrio_bizcal_reCaptchaSiteKey) && ($setrio_bizcal_reCaptchaSecretKey))
    128         $setrio_bizcal_reCaptcha = new ReCaptcha($setrio_bizcal_reCaptchaSecretKey);   
     141        $setrio_bizcal_reCaptcha = new BizcalReCaptcha($setrio_bizcal_reCaptchaSecretKey);   
    129142    else
    130143        $setrio_bizcal_reCaptcha = null;
     
    346359
    347360        if (($setrio_bizcal_reCaptchaSiteKey) && ($setrio_bizcal_reCaptchaSecretKey))
    348             $o .= "\n\t\t\t\t\t\t\t\t<div class=\"g-recaptcha\" data-size\"compact\" style=\"margin-top: 0.5em\" data-sitekey=\"$setrio_bizcal_reCaptchaSiteKey\"></div>";
     361            $o .= "\n\t\t\t\t\t\t\t\t<div class=\"zzzg-recaptcha\" id=\"bizcal-g-recaptcha\" style=\"margin-top: 0.5em\" data-sitekey=\"$setrio_bizcal_reCaptchaSiteKey\"></div>";
    349362
    350363        $o .= "\n\t\t\t\t\t\t\t\t<button type=\"submit\" id=\"bizcal-register-appointment-button\" class=\"ui-corner-all ui-button\" style=\"margin-top: 0.5em\">".setrio_bizcal_message('btnRequestAppointment')."</button>";
     
    11401153                    );
    11411154               
    1142                 if (($setrio_bizcal_reCaptchaResponse == null) || (!$setrio_bizcal_reCaptchaResponse->success))
    1143                     throw new Exception(setrio_bizcal_message('lblReCaptchaMissing'));
     1155                if ($setrio_bizcal_reCaptchaResponse == null)
     1156                    throw new Exception(setrio_bizcal_message('lblReCaptchaMissing')." (1)");
     1157                if (!$setrio_bizcal_reCaptchaResponse->success)
     1158                    throw new Exception(setrio_bizcal_message('lblReCaptchaMissing')." (2)".print_r($setrio_bizcal_reCaptchaResponse, true));
    11441159            }
    11451160            else
    1146                 throw new Exception(setrio_bizcal_message('lblReCaptchaMissing'));
     1161                throw new Exception(setrio_bizcal_message('lblReCaptchaMissing')." (3)");
    11471162        }
    11481163       
  • bizcalendar-web/trunk/readme.txt

    r2311433 r2393208  
    33Tags: setrio bizmedica bizcalendar online appointments programari
    44Requires at least: 3.3
    5 Tested up to: 5.4.1
     5Tested up to: 5.5.1
    66Requires PHP: 5.3.0
    77Stable tag: trunk
     
    5252== Changelog ==
    5353
     54= 1.0.6.6 =
     55  * RO: cateva corectii de erori
     56  * EN: small bugfixes
    5457= 1.0.6.5 =
    5558  * RO: cateva corectii de erori
     
    137140== Upgrade Notice ==
    138141
     142= 1.0.6.6 =
     143  RO: Această versiune remediază unele erori minore, actualizați dacă întâmpinați probleme cu versiunea curentă
     144  EN: This version fixes some minor bugs, upgrade if you have any issues with the current version
    139145= 1.0.6.5 =
    140146  RO: Această versiune remediază unele erori descoperite în versiunea 1.0.6.0, faceti actualizarea daca ați trecut la versiunea 1.0.6.0
  • bizcalendar-web/trunk/recaptcha/recaptchalib.php

    r2271980 r2393208  
    3434 * A ReCaptchaResponse is returned from checkAnswer().
    3535 */
    36 class ReCaptchaResponse
     36class BizcalReCaptchaResponse
    3737{
    3838    public $success;
     
    4040}
    4141
    42 class ReCaptcha
     42class BizcalReCaptcha
    4343{
    4444    private static $_signupUrl = "https://www.google.com/recaptcha/admin";
     
    9191    private function _submitHTTPGet($path, $data)
    9292    {
    93         $req = $this->_encodeQS($data);
    94         $response = file_get_contents($path . $req);
    95         return $response;
     93        try
     94        {
     95            $req = $this->_encodeQS($data);
     96           
     97            $result = wp_remote_get($path . $req);
     98            $response = wp_remote_retrieve_body($result);
     99           
     100            //$response = file_get_contents($path . $req);
     101            return $response;
     102        }
     103        catch (Exception $ex)
     104        {
     105            return $ex->message;
     106        }
    96107    }
    97108
     
    106117     */
    107118    public function verifyResponse($remoteIp, $response)
    108     {
     119    {     
    109120        // Discard empty solution submissions
    110121        if ($response == null || strlen($response) == 0) {
    111             $recaptchaResponse = new ReCaptchaResponse();
     122            $recaptchaResponse = new BizcalReCaptchaResponse();
    112123            $recaptchaResponse->success = false;
    113124            $recaptchaResponse->errorCodes = 'missing-input';
     
    125136        );
    126137        $answers = json_decode($getResponse, true);
    127         $recaptchaResponse = new ReCaptchaResponse();
     138        $recaptchaResponse = new BizcalReCaptchaResponse();
     139            $recaptchaResponse->success = false;
     140            $recaptchaResponse->errorCodes = print_r($getResponse, true);
     141        return $recaptchaResponse;
    128142
     143       
    129144        if (trim($answers ['success']) == true) {
    130145            $recaptchaResponse->success = true;
Note: See TracChangeset for help on using the changeset viewer.