Version Description
Download this release
Release Info
Developer | sandesh055 |
Plugin | Funnel Builder by CartFlows – Create High Converting Sales Funnels For WordPress |
Version | 1.5.9 |
Comparing to | |
See all releases |
Code changes from version 1.5.8 to 1.5.9
- admin/assets/css/global-admin-rtl.css +141 -8
- admin/assets/css/global-admin.css +141 -8
- admin/assets/js/global-admin.js +2 -2
- admin/meta-assets/css/admin-edit-rtl.css +35 -9
- admin/meta-assets/css/admin-edit.css +35 -9
- admin/meta-assets/js/admin-edit.js +95 -79
- assets/css/checkout-template-divi-rtl.css +47 -3
- assets/css/checkout-template-divi.css +47 -3
- assets/js/checkout-template.js +1 -1
- assets/js/frontend.js +2 -1
- assets/min-css/checkout-template-divi-rtl.min.css +1 -1
- assets/min-css/checkout-template-divi.min.css +1 -1
- assets/min-js/checkout-template.min.js +1 -1
- assets/min-js/frontend.min.js +1 -1
- cartflows.php +1 -1
- changelog.txt +5 -0
- classes/class-cartflows-functions.php +539 -539
- classes/class-cartflows-loader.php +6 -4
- classes/class-cartflows-meta-fields.php +919 -835
- classes/class-cartflows-utils.php +591 -461
- includes/meta-fields/generate-product-repeater.php +99 -0
- includes/meta-fields/get-field.php +42 -0
- includes/meta-fields/get-product-selection-repeater.php +117 -0
- languages/cartflows.pot +2045 -2001
- modules/checkout/classes/class-cartflows-checkout-markup.php +1260 -1158
- modules/checkout/classes/class-cartflows-checkout-meta.php +959 -915
- modules/flow/classes/class-cartflows-step-post-type.php +496 -498
- readme.txt +7 -2
- theme-support/astra/class-cartflows-astra-compatibility.php +113 -113
admin/assets/css/global-admin-rtl.css
CHANGED
@@ -665,12 +665,11 @@ input[type="text"].error:focus{
|
|
665 |
}
|
666 |
|
667 |
.wcf-cb-fields .wcf-field-row-heading,
|
668 |
-
.wcf-sb-fields .wcf-field-row-heading
|
669 |
-
width: 50% !important;
|
670 |
-
}
|
671 |
-
|
672 |
.wcf-cb-fields .wcf-field-row-content,
|
673 |
-
.wcf-sb-fields .wcf-field-row-content
|
|
|
|
|
674 |
width: 50% !important;
|
675 |
}
|
676 |
|
@@ -775,26 +774,160 @@ input[type="text"].error:focus{
|
|
775 |
margin-bottom: 5px;
|
776 |
}
|
777 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields{
|
|
|
778 |
padding: 0px;
|
|
|
|
|
|
|
|
|
|
|
|
|
779 |
}
|
780 |
|
781 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-row-actions{
|
782 |
float: none;
|
783 |
display: inline-block;
|
784 |
text-align: center;
|
785 |
-
margin
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
786 |
}
|
787 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
788 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove{
|
789 |
vertical-align: middle;
|
790 |
padding: 5px;
|
791 |
-
line-height:
|
792 |
font-size: 13px;
|
793 |
}
|
794 |
|
795 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove .dashicons{
|
796 |
vertical-align: middle;
|
797 |
-
font-size:
|
|
|
|
|
|
|
|
|
798 |
}
|
799 |
|
800 |
.field-wcf-tq-advance-options-fields{
|
665 |
}
|
666 |
|
667 |
.wcf-cb-fields .wcf-field-row-heading,
|
668 |
+
.wcf-sb-fields .wcf-field-row-heading,
|
|
|
|
|
|
|
669 |
.wcf-cb-fields .wcf-field-row-content,
|
670 |
+
.wcf-sb-fields .wcf-field-row-content,
|
671 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-heading,
|
672 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-content{
|
673 |
width: 50% !important;
|
674 |
}
|
675 |
|
774 |
margin-bottom: 5px;
|
775 |
}
|
776 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields{
|
777 |
+
position: relative;
|
778 |
padding: 0px;
|
779 |
+
height: auto;
|
780 |
+
min-height: 20px;
|
781 |
+
width: 100%;
|
782 |
+
display: flex;
|
783 |
+
justify-content: space-between;
|
784 |
+
align-items: center;
|
785 |
}
|
786 |
|
787 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-row-actions{
|
788 |
float: none;
|
789 |
display: inline-block;
|
790 |
text-align: center;
|
791 |
+
margin: 0 10px 0 0;
|
792 |
+
}
|
793 |
+
/*sonali*/
|
794 |
+
.wcf-table-container .wcf-repeatable-fields .select2-container .select2-selection--single {
|
795 |
+
height: 34px;
|
796 |
+
}
|
797 |
+
|
798 |
+
.wcf-table-container .wcf-repeatable-fields .select2-container .select2-selection--single .select2-selection__rendered {
|
799 |
+
line-height: 34px;
|
800 |
+
}
|
801 |
+
|
802 |
+
.wcf-table-container .wcf-repeatable-row-advance-fields .wcf-field-row-advance-content{
|
803 |
+
width:70%;
|
804 |
+
}
|
805 |
+
|
806 |
+
.wcf-repeatable-row-standard-fields .wcf-checkout-products-dashicon{
|
807 |
+
cursor: move;
|
808 |
+
}
|
809 |
+
|
810 |
+
|
811 |
+
.wcf-repeatable-row-standard-fields .wcf-checkout-products-dashicon,
|
812 |
+
.wcf-repeatable-row-standard-fields .wcf-sel-product{
|
813 |
+
display: inline-block;
|
814 |
+
vertical-align: middle;
|
815 |
+
margin: 0px;
|
816 |
+
display: flex;
|
817 |
+
align-items: center;
|
818 |
+
}
|
819 |
+
|
820 |
+
.wcf-repeatable-row-standard-fields .wcf-sel-product {
|
821 |
+
margin: 0 10px 0 0;
|
822 |
+
max-width: 90%;
|
823 |
}
|
824 |
|
825 |
+
.wcf-repeatable-row-standard-fields .wcf_toggle_advance_fields{
|
826 |
+
display: inline-flex;
|
827 |
+
font-size: 12px;
|
828 |
+
float: left;
|
829 |
+
position: relative;
|
830 |
+
left: 0px;
|
831 |
+
margin: 0;
|
832 |
+
vertical-align: middle;
|
833 |
+
}
|
834 |
+
|
835 |
+
.wcf-repeatables-wrap .wcf-repeatable-row.active .wcf-repeatable-row-advance-fields{
|
836 |
+
display: block;
|
837 |
+
background: rgb(236, 236, 236, 0.2);
|
838 |
+
}
|
839 |
+
|
840 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-repeatable-row-advance-fields{
|
841 |
+
display: none;
|
842 |
+
width: auto;
|
843 |
+
padding: 15px;
|
844 |
+
position: relative;
|
845 |
+
z-index: 10;
|
846 |
+
border: 1px solid #ececec;
|
847 |
+
border-top: none;
|
848 |
+
box-shadow: 0 1px 1px rgba(0,0,0,0.04);
|
849 |
+
}
|
850 |
+
|
851 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row{
|
852 |
+
display: flex;
|
853 |
+
padding: 5px 0 5px 2px;
|
854 |
+
}
|
855 |
+
|
856 |
+
.wcf-repeatables-wrap .wcf-repeatable-row.active .wcf-repeatable-row-advance-fields .wcf-field-row{
|
857 |
+
/*overflow: visible;*/
|
858 |
+
}
|
859 |
+
|
860 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-heading {
|
861 |
+
font-size: 12px;
|
862 |
+
width: 30%;
|
863 |
+
height: 100%;
|
864 |
+
display: inline-block;
|
865 |
+
line-height: 1.5em;
|
866 |
+
vertical-align: middle;
|
867 |
+
min-height: 28px;
|
868 |
+
}
|
869 |
+
|
870 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-content {
|
871 |
+
width: auto;
|
872 |
+
display: inline-block;
|
873 |
+
font-size: 12px;
|
874 |
+
vertical-align: middle;
|
875 |
+
}
|
876 |
+
|
877 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row input[type="text"],
|
878 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row input[type="text"],
|
879 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row select,
|
880 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row select{
|
881 |
+
width: 100%;
|
882 |
+
margin-left: 10px;
|
883 |
+
background-color: #fff;
|
884 |
+
max-width: 100%;
|
885 |
+
}
|
886 |
+
|
887 |
+
.wcf-hide-advance{
|
888 |
+
display:none;
|
889 |
+
}
|
890 |
+
|
891 |
+
.wcf-checkout-general .wcf-repeatables-wrap .wcf-repeatable-row{
|
892 |
+
background: #fff;
|
893 |
+
/*border-bottom: 1px solid #eee;*/
|
894 |
+
margin-bottom: 10px;
|
895 |
+
}
|
896 |
+
|
897 |
+
.wcf-checkout-general .wcf-repeatables-wrap .wcf-repeater-fields-head-wrap {
|
898 |
+
margin: 0;
|
899 |
+
padding: 10px 12px;
|
900 |
+
border: 1px solid #eee;
|
901 |
+
clear: both;
|
902 |
+
cursor: pointer;
|
903 |
+
line-height: 1.5em;
|
904 |
+
position: relative;
|
905 |
+
border: 1px solid #eee;
|
906 |
+
|
907 |
+
}
|
908 |
+
.wcf_toggle_advance_fields{
|
909 |
+
vertical-align:top;
|
910 |
+
}
|
911 |
+
/*.wcf-repeatable-row{
|
912 |
+
border-bottom: 1px solid #E7E7E7;
|
913 |
+
}*/
|
914 |
+
|
915 |
+
/*sonali*/
|
916 |
+
|
917 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove{
|
918 |
vertical-align: middle;
|
919 |
padding: 5px;
|
920 |
+
line-height: 15px;
|
921 |
font-size: 13px;
|
922 |
}
|
923 |
|
924 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove .dashicons{
|
925 |
vertical-align: middle;
|
926 |
+
font-size: 1em;
|
927 |
+
line-height: 1em;
|
928 |
+
width: 14px;
|
929 |
+
height: 16px;
|
930 |
+
text-align: left;
|
931 |
}
|
932 |
|
933 |
.field-wcf-tq-advance-options-fields{
|
admin/assets/css/global-admin.css
CHANGED
@@ -665,12 +665,11 @@ input[type="text"].error:focus{
|
|
665 |
}
|
666 |
|
667 |
.wcf-cb-fields .wcf-field-row-heading,
|
668 |
-
.wcf-sb-fields .wcf-field-row-heading
|
669 |
-
width: 50% !important;
|
670 |
-
}
|
671 |
-
|
672 |
.wcf-cb-fields .wcf-field-row-content,
|
673 |
-
.wcf-sb-fields .wcf-field-row-content
|
|
|
|
|
674 |
width: 50% !important;
|
675 |
}
|
676 |
|
@@ -775,26 +774,160 @@ input[type="text"].error:focus{
|
|
775 |
margin-bottom: 5px;
|
776 |
}
|
777 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields{
|
|
|
778 |
padding: 0px;
|
|
|
|
|
|
|
|
|
|
|
|
|
779 |
}
|
780 |
|
781 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-row-actions{
|
782 |
float: none;
|
783 |
display: inline-block;
|
784 |
text-align: center;
|
785 |
-
margin
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
786 |
}
|
787 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
788 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove{
|
789 |
vertical-align: middle;
|
790 |
padding: 5px;
|
791 |
-
line-height:
|
792 |
font-size: 13px;
|
793 |
}
|
794 |
|
795 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove .dashicons{
|
796 |
vertical-align: middle;
|
797 |
-
font-size:
|
|
|
|
|
|
|
|
|
798 |
}
|
799 |
|
800 |
.field-wcf-tq-advance-options-fields{
|
665 |
}
|
666 |
|
667 |
.wcf-cb-fields .wcf-field-row-heading,
|
668 |
+
.wcf-sb-fields .wcf-field-row-heading,
|
|
|
|
|
|
|
669 |
.wcf-cb-fields .wcf-field-row-content,
|
670 |
+
.wcf-sb-fields .wcf-field-row-content,
|
671 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-heading,
|
672 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-content{
|
673 |
width: 50% !important;
|
674 |
}
|
675 |
|
774 |
margin-bottom: 5px;
|
775 |
}
|
776 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields{
|
777 |
+
position: relative;
|
778 |
padding: 0px;
|
779 |
+
height: auto;
|
780 |
+
min-height: 20px;
|
781 |
+
width: 100%;
|
782 |
+
display: flex;
|
783 |
+
justify-content: space-between;
|
784 |
+
align-items: center;
|
785 |
}
|
786 |
|
787 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-row-actions{
|
788 |
float: none;
|
789 |
display: inline-block;
|
790 |
text-align: center;
|
791 |
+
margin: 0 0 0 10px;
|
792 |
+
}
|
793 |
+
/*sonali*/
|
794 |
+
.wcf-table-container .wcf-repeatable-fields .select2-container .select2-selection--single {
|
795 |
+
height: 34px;
|
796 |
+
}
|
797 |
+
|
798 |
+
.wcf-table-container .wcf-repeatable-fields .select2-container .select2-selection--single .select2-selection__rendered {
|
799 |
+
line-height: 34px;
|
800 |
+
}
|
801 |
+
|
802 |
+
.wcf-table-container .wcf-repeatable-row-advance-fields .wcf-field-row-advance-content{
|
803 |
+
width:70%;
|
804 |
+
}
|
805 |
+
|
806 |
+
.wcf-repeatable-row-standard-fields .wcf-checkout-products-dashicon{
|
807 |
+
cursor: move;
|
808 |
+
}
|
809 |
+
|
810 |
+
|
811 |
+
.wcf-repeatable-row-standard-fields .wcf-checkout-products-dashicon,
|
812 |
+
.wcf-repeatable-row-standard-fields .wcf-sel-product{
|
813 |
+
display: inline-block;
|
814 |
+
vertical-align: middle;
|
815 |
+
margin: 0px;
|
816 |
+
display: flex;
|
817 |
+
align-items: center;
|
818 |
+
}
|
819 |
+
|
820 |
+
.wcf-repeatable-row-standard-fields .wcf-sel-product {
|
821 |
+
margin: 0 0 0 10px;
|
822 |
+
max-width: 90%;
|
823 |
}
|
824 |
|
825 |
+
.wcf-repeatable-row-standard-fields .wcf_toggle_advance_fields{
|
826 |
+
display: inline-flex;
|
827 |
+
font-size: 12px;
|
828 |
+
float: right;
|
829 |
+
position: relative;
|
830 |
+
right: 0px;
|
831 |
+
margin: 0;
|
832 |
+
vertical-align: middle;
|
833 |
+
}
|
834 |
+
|
835 |
+
.wcf-repeatables-wrap .wcf-repeatable-row.active .wcf-repeatable-row-advance-fields{
|
836 |
+
display: block;
|
837 |
+
background: rgb(236, 236, 236, 0.2);
|
838 |
+
}
|
839 |
+
|
840 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-repeatable-row-advance-fields{
|
841 |
+
display: none;
|
842 |
+
width: auto;
|
843 |
+
padding: 15px;
|
844 |
+
position: relative;
|
845 |
+
z-index: 10;
|
846 |
+
border: 1px solid #ececec;
|
847 |
+
border-top: none;
|
848 |
+
box-shadow: 0 1px 1px rgba(0,0,0,0.04);
|
849 |
+
}
|
850 |
+
|
851 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row{
|
852 |
+
display: flex;
|
853 |
+
padding: 5px 2px 5px 0;
|
854 |
+
}
|
855 |
+
|
856 |
+
.wcf-repeatables-wrap .wcf-repeatable-row.active .wcf-repeatable-row-advance-fields .wcf-field-row{
|
857 |
+
/*overflow: visible;*/
|
858 |
+
}
|
859 |
+
|
860 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-heading {
|
861 |
+
font-size: 12px;
|
862 |
+
width: 30%;
|
863 |
+
height: 100%;
|
864 |
+
display: inline-block;
|
865 |
+
line-height: 1.5em;
|
866 |
+
vertical-align: middle;
|
867 |
+
min-height: 28px;
|
868 |
+
}
|
869 |
+
|
870 |
+
.wcf-repeatables-wrap .wcf-repeatable-row .wcf-field-row-content {
|
871 |
+
width: auto;
|
872 |
+
display: inline-block;
|
873 |
+
font-size: 12px;
|
874 |
+
vertical-align: middle;
|
875 |
+
}
|
876 |
+
|
877 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row input[type="text"],
|
878 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row input[type="text"],
|
879 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row select,
|
880 |
+
.wcf-repeatables-wrap .wcf-repeatable-row-advance-fields .wcf-field-row select{
|
881 |
+
width: 100%;
|
882 |
+
margin-right: 10px;
|
883 |
+
background-color: #fff;
|
884 |
+
max-width: 100%;
|
885 |
+
}
|
886 |
+
|
887 |
+
.wcf-hide-advance{
|
888 |
+
display:none;
|
889 |
+
}
|
890 |
+
|
891 |
+
.wcf-checkout-general .wcf-repeatables-wrap .wcf-repeatable-row{
|
892 |
+
background: #fff;
|
893 |
+
/*border-bottom: 1px solid #eee;*/
|
894 |
+
margin-bottom: 10px;
|
895 |
+
}
|
896 |
+
|
897 |
+
.wcf-checkout-general .wcf-repeatables-wrap .wcf-repeater-fields-head-wrap {
|
898 |
+
margin: 0;
|
899 |
+
padding: 10px 12px;
|
900 |
+
border: 1px solid #eee;
|
901 |
+
clear: both;
|
902 |
+
cursor: pointer;
|
903 |
+
line-height: 1.5em;
|
904 |
+
position: relative;
|
905 |
+
border: 1px solid #eee;
|
906 |
+
|
907 |
+
}
|
908 |
+
.wcf_toggle_advance_fields{
|
909 |
+
vertical-align:top;
|
910 |
+
}
|
911 |
+
/*.wcf-repeatable-row{
|
912 |
+
border-bottom: 1px solid #E7E7E7;
|
913 |
+
}*/
|
914 |
+
|
915 |
+
/*sonali*/
|
916 |
+
|
917 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove{
|
918 |
vertical-align: middle;
|
919 |
padding: 5px;
|
920 |
+
line-height: 15px;
|
921 |
font-size: 13px;
|
922 |
}
|
923 |
|
924 |
.wcf-repeatables-wrap .wcf-repeatable-row-standard-fields .wcf-repeatable-remove .dashicons{
|
925 |
vertical-align: middle;
|
926 |
+
font-size: 1em;
|
927 |
+
line-height: 1em;
|
928 |
+
width: 14px;
|
929 |
+
height: 16px;
|
930 |
+
text-align: right;
|
931 |
}
|
932 |
|
933 |
.field-wcf-tq-advance-options-fields{
|
admin/assets/js/global-admin.js
CHANGED
@@ -185,11 +185,11 @@
|
|
185 |
var wcf_add_tool_tip_msg = function(){
|
186 |
var tooltip = false;
|
187 |
|
188 |
-
$('.wcf-field-heading-help'
|
189 |
var tip_wrap = $(this).closest('.wcf-field-row');
|
190 |
closest_tooltip = tip_wrap.find('.wcf-tooltip-text');
|
191 |
|
192 |
-
|
193 |
});
|
194 |
};
|
195 |
|
185 |
var wcf_add_tool_tip_msg = function(){
|
186 |
var tooltip = false;
|
187 |
|
188 |
+
$( '.postbox' ).on('click', '.wcf-field-heading-help', function(){
|
189 |
var tip_wrap = $(this).closest('.wcf-field-row');
|
190 |
closest_tooltip = tip_wrap.find('.wcf-tooltip-text');
|
191 |
|
192 |
+
closest_tooltip.toggleClass('display_tool_tip');
|
193 |
});
|
194 |
};
|
195 |
|
admin/meta-assets/css/admin-edit-rtl.css
CHANGED
@@ -87,12 +87,9 @@ body li.select2-results__option.select2-results__message {
|
|
87 |
}
|
88 |
|
89 |
/* Repeater Product Field */
|
90 |
-
.wcf-product-repeater-field-row .wcf-field-row-content {
|
91 |
-
width: 100% !important;
|
92 |
-
}
|
93 |
|
94 |
.wcf-product-repeater-field-row .wcf-field-row-content {
|
95 |
-
width: 100
|
96 |
}
|
97 |
|
98 |
.wcf-repeatable-row {
|
@@ -119,12 +116,11 @@ body li.select2-results__option.select2-results__message {
|
|
119 |
.wcf-repeatable-row-setting-field {
|
120 |
display: inline-block;
|
121 |
}
|
122 |
-
|
123 |
-
width: 25%;
|
124 |
-
}
|
125 |
.wcf-repeatable-row-setting-field {
|
126 |
-
width:
|
127 |
-
|
|
|
128 |
|
129 |
.wcf-repeatable-fields {
|
130 |
margin-bottom: 10px;
|
@@ -199,3 +195,33 @@ body li.select2-results__option.select2-results__message {
|
|
199 |
cursor: pointer;
|
200 |
}
|
201 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
87 |
}
|
88 |
|
89 |
/* Repeater Product Field */
|
|
|
|
|
|
|
90 |
|
91 |
.wcf-product-repeater-field-row .wcf-field-row-content {
|
92 |
+
max-width: 100% !important;
|
93 |
}
|
94 |
|
95 |
.wcf-repeatable-row {
|
116 |
.wcf-repeatable-row-setting-field {
|
117 |
display: inline-block;
|
118 |
}
|
119 |
+
|
|
|
|
|
120 |
.wcf-repeatable-row-setting-field {
|
121 |
+
width: 95%;
|
122 |
+
max-width: calc( 100% - 100px );
|
123 |
+
}
|
124 |
|
125 |
.wcf-repeatable-fields {
|
126 |
margin-bottom: 10px;
|
195 |
cursor: pointer;
|
196 |
}
|
197 |
|
198 |
+
/*.wcf-repeatables-wrap.ui-sortable {
|
199 |
+
width: 60%;
|
200 |
+
}*/
|
201 |
+
|
202 |
+
|
203 |
+
|
204 |
+
|
205 |
+
@media screen and (min-width:439px) and (max-width:1180px){
|
206 |
+
.wcf-repeatable-row-setting-field {
|
207 |
+
width:60%;
|
208 |
+
}
|
209 |
+
.wcf-repeatable-row-standard-fields{
|
210 |
+
display:flex;
|
211 |
+
}
|
212 |
+
}
|
213 |
+
|
214 |
+
.wcf_toggle_advance_fields{
|
215 |
+
pointer-events: none;
|
216 |
+
}
|
217 |
+
|
218 |
+
|
219 |
+
/* Color Picker Field Fixes */
|
220 |
+
.wcf-table-container .wcf-column-right .wcf-field-color-picker .wcf-field-row-content {
|
221 |
+
vertical-align: top;
|
222 |
+
}
|
223 |
+
|
224 |
+
.wcf-field-color-picker .button.wp-picker-clear {
|
225 |
+
margin-right: 7px;
|
226 |
+
min-height: 30px;
|
227 |
+
}
|
admin/meta-assets/css/admin-edit.css
CHANGED
@@ -87,12 +87,9 @@ body li.select2-results__option.select2-results__message {
|
|
87 |
}
|
88 |
|
89 |
/* Repeater Product Field */
|
90 |
-
.wcf-product-repeater-field-row .wcf-field-row-content {
|
91 |
-
width: 100% !important;
|
92 |
-
}
|
93 |
|
94 |
.wcf-product-repeater-field-row .wcf-field-row-content {
|
95 |
-
width: 100
|
96 |
}
|
97 |
|
98 |
.wcf-repeatable-row {
|
@@ -119,12 +116,11 @@ body li.select2-results__option.select2-results__message {
|
|
119 |
.wcf-repeatable-row-setting-field {
|
120 |
display: inline-block;
|
121 |
}
|
122 |
-
|
123 |
-
width: 25%;
|
124 |
-
}
|
125 |
.wcf-repeatable-row-setting-field {
|
126 |
-
width:
|
127 |
-
|
|
|
128 |
|
129 |
.wcf-repeatable-fields {
|
130 |
margin-bottom: 10px;
|
@@ -199,3 +195,33 @@ body li.select2-results__option.select2-results__message {
|
|
199 |
cursor: pointer;
|
200 |
}
|
201 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
87 |
}
|
88 |
|
89 |
/* Repeater Product Field */
|
|
|
|
|
|
|
90 |
|
91 |
.wcf-product-repeater-field-row .wcf-field-row-content {
|
92 |
+
max-width: 100% !important;
|
93 |
}
|
94 |
|
95 |
.wcf-repeatable-row {
|
116 |
.wcf-repeatable-row-setting-field {
|
117 |
display: inline-block;
|
118 |
}
|
119 |
+
|
|
|
|
|
120 |
.wcf-repeatable-row-setting-field {
|
121 |
+
width: 95%;
|
122 |
+
max-width: calc( 100% - 100px );
|
123 |
+
}
|
124 |
|
125 |
.wcf-repeatable-fields {
|
126 |
margin-bottom: 10px;
|
195 |
cursor: pointer;
|
196 |
}
|
197 |
|
198 |
+
/*.wcf-repeatables-wrap.ui-sortable {
|
199 |
+
width: 60%;
|
200 |
+
}*/
|
201 |
+
|
202 |
+
|
203 |
+
|
204 |
+
|
205 |
+
@media screen and (min-width:439px) and (max-width:1180px){
|
206 |
+
.wcf-repeatable-row-setting-field {
|
207 |
+
width:60%;
|
208 |
+
}
|
209 |
+
.wcf-repeatable-row-standard-fields{
|
210 |
+
display:flex;
|
211 |
+
}
|
212 |
+
}
|
213 |
+
|
214 |
+
.wcf_toggle_advance_fields{
|
215 |
+
pointer-events: none;
|
216 |
+
}
|
217 |
+
|
218 |
+
|
219 |
+
/* Color Picker Field Fixes */
|
220 |
+
.wcf-table-container .wcf-column-right .wcf-field-color-picker .wcf-field-row-content {
|
221 |
+
vertical-align: top;
|
222 |
+
}
|
223 |
+
|
224 |
+
.wcf-field-color-picker .button.wp-picker-clear {
|
225 |
+
margin-left: 7px;
|
226 |
+
min-height: 30px;
|
227 |
+
}
|
admin/meta-assets/js/admin-edit.js
CHANGED
@@ -222,7 +222,7 @@
|
|
222 |
|
223 |
// Call color picker
|
224 |
$('.wcf-color-picker').wpColorPicker();
|
225 |
-
}
|
226 |
var wcf_woo_product_search_init = function() {
|
227 |
|
228 |
var $product_search = $('.wcf-product-search:not(.wc-product-search)');
|
@@ -233,7 +233,7 @@
|
|
233 |
|
234 |
$(document.body).trigger('wc-enhanced-select-init');
|
235 |
}
|
236 |
-
}
|
237 |
|
238 |
var wcf_woo_coupon_search_init = function() {
|
239 |
|
@@ -311,18 +311,76 @@
|
|
311 |
});
|
312 |
};
|
313 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
314 |
var wcf_add_repeatable_product = function() {
|
315 |
|
316 |
$('.wcf-add-repeatable').on('click', function(e) {
|
317 |
|
318 |
-
var $this
|
319 |
field_name = $this.data('name'),
|
320 |
-
wrap
|
321 |
-
template
|
322 |
-
highest
|
323 |
-
new_key
|
|
|
324 |
|
325 |
wrap.find('.wcf-repeatable-row').each(function(er) {
|
|
|
326 |
var r_row = $(this),
|
327 |
key = r_row.data('key');
|
328 |
|
@@ -330,21 +388,20 @@
|
|
330 |
highest = key;
|
331 |
}
|
332 |
});
|
333 |
-
|
334 |
new_key = highest + 1;
|
335 |
-
|
336 |
template = template.replace( /{{id}}/g, new_key );
|
|
|
337 |
|
338 |
-
|
339 |
-
$( template ).insertBefore( ".wcf-add-repeatable-row" );
|
340 |
|
341 |
/* Woo Product Search */
|
342 |
wcf_woo_product_search_init();
|
343 |
-
|
344 |
e.preventDefault();
|
345 |
});
|
346 |
-
|
347 |
-
}
|
348 |
|
349 |
var wcf_remove_repeatable_product = function() {
|
350 |
$(document).on( 'click', '.wcf-repeatable-remove', function(e) {
|
@@ -361,7 +418,7 @@
|
|
361 |
deletable_row.remove();
|
362 |
}
|
363 |
} );
|
364 |
-
}
|
365 |
|
366 |
/* Simple Quantity */
|
367 |
var wcf_set_variation_mode_option = function() {
|
@@ -391,57 +448,7 @@
|
|
391 |
quantity_data.hide();
|
392 |
}
|
393 |
});
|
394 |
-
}
|
395 |
-
|
396 |
-
var wcf_add_quantity_data = function() {
|
397 |
-
|
398 |
-
$(document).on('click', '.wcf-quantity-add-option', function(e) {
|
399 |
-
|
400 |
-
e.preventDefault();
|
401 |
-
|
402 |
-
var $this = $(this),
|
403 |
-
wrap = $this.closest('.wcf-quantity-data'),
|
404 |
-
template = $('#tmpl-wcf-product-simple-quantity').html(),
|
405 |
-
highest = 0,
|
406 |
-
new_key = 0,
|
407 |
-
main_wrap = $this.closest('.wcf-repeatable-row'),
|
408 |
-
main_key = main_wrap.data('key');
|
409 |
-
|
410 |
-
wrap.find('.wcf-quantity-repeatable-row').each(function(er) {
|
411 |
-
var r_row = $(this),
|
412 |
-
key = r_row.data('key');
|
413 |
-
|
414 |
-
if ( key > highest ) {
|
415 |
-
highest = key;
|
416 |
-
}
|
417 |
-
});
|
418 |
-
|
419 |
-
new_key = highest + 1;
|
420 |
-
|
421 |
-
template = template.replace( /{{id}}/g, main_key );
|
422 |
-
template = template.replace( /{{data_id}}/g, new_key );
|
423 |
-
|
424 |
-
$( template ).insertAfter( wrap.find('.wcf-quantity-repeatable-row').last() );
|
425 |
-
});
|
426 |
-
}
|
427 |
-
|
428 |
-
var wcf_remove_quantity_data = function() {
|
429 |
-
|
430 |
-
$(document).on( 'click', '.wcf-quanity-remove', function(e) {
|
431 |
-
|
432 |
-
var $this = $(this),
|
433 |
-
deletable_row = $this.closest('.wcf-quantity-repeatable-row'),
|
434 |
-
wrap = $this.closest('.wcf-quantity-data');
|
435 |
-
|
436 |
-
var all_rows = wrap.find('.wcf-quantity-repeatable-row');
|
437 |
-
|
438 |
-
if ( all_rows.length === 1 ) {
|
439 |
-
alert("You cannot remove this product.");
|
440 |
-
}else{
|
441 |
-
deletable_row.remove();
|
442 |
-
}
|
443 |
-
} );
|
444 |
-
}
|
445 |
|
446 |
/* Custom Fields Hide / Show */
|
447 |
var wcf_custom_fields_events = function() {
|
@@ -453,7 +460,7 @@
|
|
453 |
$('.wcf-column-right .wcf-checkout-custom-fields .wcf-cc-fields .wcf-cc-checkbox-field input:checkbox').on('change', function(e) {
|
454 |
wcf_custom_fields();
|
455 |
});
|
456 |
-
}
|
457 |
|
458 |
/* Disable/Enable Custom Field section*/
|
459 |
var wcf_custom_fields = function() {
|
@@ -476,7 +483,7 @@
|
|
476 |
wrap.find( val ).hide();
|
477 |
});
|
478 |
}
|
479 |
-
}
|
480 |
|
481 |
/* Advance Style Fields Hide / Show */
|
482 |
var wcf_advance_style_fields_events = function() {
|
@@ -501,7 +508,7 @@
|
|
501 |
});
|
502 |
|
503 |
|
504 |
-
}
|
505 |
|
506 |
var wcf_thankyou_advance_style_fields = function() {
|
507 |
var wrap = $('.wcf-thankyou-table'),
|
@@ -521,7 +528,7 @@
|
|
521 |
wrap.find( val ).hide();
|
522 |
});
|
523 |
}
|
524 |
-
}
|
525 |
|
526 |
var wcf_thankyou_settings_fields = function() {
|
527 |
var wrap = $('.wcf-thankyou-table'),
|
@@ -540,7 +547,7 @@
|
|
540 |
wrap.find( val ).hide();
|
541 |
});
|
542 |
}
|
543 |
-
}
|
544 |
|
545 |
/* Disable/Enable Advance Style Field section*/
|
546 |
var wcf_advance_style_fields = function() {
|
@@ -565,7 +572,7 @@
|
|
565 |
wrap.find( val ).hide();
|
566 |
});
|
567 |
}
|
568 |
-
}
|
569 |
|
570 |
var wcf_settings_tab = function() {
|
571 |
|
@@ -596,7 +603,14 @@
|
|
596 |
$( '.' + tab_class ).addClass('active');
|
597 |
}
|
598 |
});
|
599 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
600 |
|
601 |
var wcf_input_file_init = function() {
|
602 |
|
@@ -658,7 +672,7 @@
|
|
658 |
button.hide();
|
659 |
|
660 |
});
|
661 |
-
}
|
662 |
|
663 |
$(document).ready(function($) {
|
664 |
|
@@ -684,6 +698,11 @@
|
|
684 |
/* Repeateble Product */
|
685 |
wcf_add_repeatable_product();
|
686 |
|
|
|
|
|
|
|
|
|
|
|
687 |
/* Custom Fields Show Hide */
|
688 |
wcf_custom_fields_events();
|
689 |
|
@@ -693,10 +712,7 @@
|
|
693 |
/* Advance Style Fields Show Hide */
|
694 |
wcf_advance_style_fields_events();
|
695 |
|
696 |
-
/*
|
697 |
-
|
698 |
-
wcf_remove_quantity_data();
|
699 |
});
|
700 |
-
|
701 |
-
|
702 |
})(jQuery);
|
222 |
|
223 |
// Call color picker
|
224 |
$('.wcf-color-picker').wpColorPicker();
|
225 |
+
};
|
226 |
var wcf_woo_product_search_init = function() {
|
227 |
|
228 |
var $product_search = $('.wcf-product-search:not(.wc-product-search)');
|
233 |
|
234 |
$(document.body).trigger('wc-enhanced-select-init');
|
235 |
}
|
236 |
+
};
|
237 |
|
238 |
var wcf_woo_coupon_search_init = function() {
|
239 |
|
311 |
});
|
312 |
};
|
313 |
|
314 |
+
var wcf_hide_discount_value_field= function(){
|
315 |
+
|
316 |
+
var show_hide_discount_field = function($this,value){
|
317 |
+
|
318 |
+
if( '' === value ){
|
319 |
+
$this.closest('.wcf-repeatable-row-advance-fields').find('.wcf-repeatable-row-discount-field').hide();
|
320 |
+
}else{
|
321 |
+
$this.closest('.wcf-repeatable-row-advance-fields').find('.wcf-repeatable-row-discount-field').show();
|
322 |
+
}
|
323 |
+
};
|
324 |
+
|
325 |
+
wrap = $('.wcf-repeatable-row-advance-fields');
|
326 |
+
|
327 |
+
wrap.find('.wcf-repeatable-discount-type-field select').each(function(e){
|
328 |
+
$this = $(this);
|
329 |
+
var value = $this.val();
|
330 |
+
show_hide_discount_field($this,value);
|
331 |
+
});
|
332 |
+
|
333 |
+
/* On changes */
|
334 |
+
$(document).on( 'change', '.wcf-repeatable-discount-type-field select', function(e) {
|
335 |
+
$this = $(this);
|
336 |
+
var value = $this.val();
|
337 |
+
show_hide_discount_field($this,value);
|
338 |
+
});
|
339 |
+
|
340 |
+
/* Quanity field non zero value */
|
341 |
+
$('.wcf-repeatable-row-advance-fields input[type=number]').on('keyup', function(e) {
|
342 |
+
|
343 |
+
var value = $(this).val();
|
344 |
+
var number = parseInt( value );
|
345 |
+
|
346 |
+
if( value !== '' && ( number < 1 || isNaN( number ) ) ) {
|
347 |
+
$(this).val(1);
|
348 |
+
}
|
349 |
+
});
|
350 |
+
};
|
351 |
+
|
352 |
+
var wcf_toggle_view_repeatable_fields = function() {
|
353 |
+
|
354 |
+
$(document.body).on('click','.wcf-repeater-fields-head-wrap', function (e) {
|
355 |
+
|
356 |
+
var e_target = $(e.target);
|
357 |
+
|
358 |
+
if( ! e_target.hasClass('wcf-repeatable-row-standard-fields') && ! e_target.hasClass('wcf-repeater-fields-head-wrap') ) {
|
359 |
+
return;
|
360 |
+
}
|
361 |
+
|
362 |
+
var $this = $(this),
|
363 |
+
fields_wrapper = $this.closest('.wcf-repeatable-row');
|
364 |
+
|
365 |
+
fields_wrapper.toggleClass("active");
|
366 |
+
$this.find('i').toggleClass('dashicons-arrow-up dashicons-arrow-down');
|
367 |
+
});
|
368 |
+
};
|
369 |
+
|
370 |
var wcf_add_repeatable_product = function() {
|
371 |
|
372 |
$('.wcf-add-repeatable').on('click', function(e) {
|
373 |
|
374 |
+
var $this = $(this),
|
375 |
field_name = $this.data('name'),
|
376 |
+
wrap = $this.closest('.wcf-field-row-content').find('.wcf-repeatables-wrap'),
|
377 |
+
template = $('#tmpl-wcf-product-repeater').html(),
|
378 |
+
highest = 0,
|
379 |
+
new_key = 0,
|
380 |
+
unique_id = Math.random().toString(36).substring(2, 10);
|
381 |
|
382 |
wrap.find('.wcf-repeatable-row').each(function(er) {
|
383 |
+
|
384 |
var r_row = $(this),
|
385 |
key = r_row.data('key');
|
386 |
|
388 |
highest = key;
|
389 |
}
|
390 |
});
|
391 |
+
|
392 |
new_key = highest + 1;
|
393 |
+
|
394 |
template = template.replace( /{{id}}/g, new_key );
|
395 |
+
template = template.replace( /{{unique_id}}/g, unique_id );
|
396 |
|
397 |
+
$( template ).insertBefore( ".wcf-add-fields" );
|
|
|
398 |
|
399 |
/* Woo Product Search */
|
400 |
wcf_woo_product_search_init();
|
401 |
+
|
402 |
e.preventDefault();
|
403 |
});
|
404 |
+
};
|
|
|
405 |
|
406 |
var wcf_remove_repeatable_product = function() {
|
407 |
$(document).on( 'click', '.wcf-repeatable-remove', function(e) {
|
418 |
deletable_row.remove();
|
419 |
}
|
420 |
} );
|
421 |
+
};
|
422 |
|
423 |
/* Simple Quantity */
|
424 |
var wcf_set_variation_mode_option = function() {
|
448 |
quantity_data.hide();
|
449 |
}
|
450 |
});
|
451 |
+
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
452 |
|
453 |
/* Custom Fields Hide / Show */
|
454 |
var wcf_custom_fields_events = function() {
|
460 |
$('.wcf-column-right .wcf-checkout-custom-fields .wcf-cc-fields .wcf-cc-checkbox-field input:checkbox').on('change', function(e) {
|
461 |
wcf_custom_fields();
|
462 |
});
|
463 |
+
};
|
464 |
|
465 |
/* Disable/Enable Custom Field section*/
|
466 |
var wcf_custom_fields = function() {
|
483 |
wrap.find( val ).hide();
|
484 |
});
|
485 |
}
|
486 |
+
};
|
487 |
|
488 |
/* Advance Style Fields Hide / Show */
|
489 |
var wcf_advance_style_fields_events = function() {
|
508 |
});
|
509 |
|
510 |
|
511 |
+
};
|
512 |
|
513 |
var wcf_thankyou_advance_style_fields = function() {
|
514 |
var wrap = $('.wcf-thankyou-table'),
|
528 |
wrap.find( val ).hide();
|
529 |
});
|
530 |
}
|
531 |
+
};
|
532 |
|
533 |
var wcf_thankyou_settings_fields = function() {
|
534 |
var wrap = $('.wcf-thankyou-table'),
|
547 |
wrap.find( val ).hide();
|
548 |
});
|
549 |
}
|
550 |
+
};
|
551 |
|
552 |
/* Disable/Enable Advance Style Field section*/
|
553 |
var wcf_advance_style_fields = function() {
|
572 |
wrap.find( val ).hide();
|
573 |
});
|
574 |
}
|
575 |
+
};
|
576 |
|
577 |
var wcf_settings_tab = function() {
|
578 |
|
603 |
$( '.' + tab_class ).addClass('active');
|
604 |
}
|
605 |
});
|
606 |
+
};
|
607 |
+
|
608 |
+
var wcf_products_sortable = function(){
|
609 |
+
$('.wcf-checkout-general .wcf-repeatables-wrap').sortable({
|
610 |
+
forcePlaceholderSize: true,
|
611 |
+
placeholder: "sortable-placeholder",
|
612 |
+
});
|
613 |
+
};
|
614 |
|
615 |
var wcf_input_file_init = function() {
|
616 |
|
672 |
button.hide();
|
673 |
|
674 |
});
|
675 |
+
};
|
676 |
|
677 |
$(document).ready(function($) {
|
678 |
|
698 |
/* Repeateble Product */
|
699 |
wcf_add_repeatable_product();
|
700 |
|
701 |
+
/* Repeateble Product */
|
702 |
+
wcf_toggle_view_repeatable_fields();
|
703 |
+
|
704 |
+
wcf_hide_discount_value_field();
|
705 |
+
|
706 |
/* Custom Fields Show Hide */
|
707 |
wcf_custom_fields_events();
|
708 |
|
712 |
/* Advance Style Fields Show Hide */
|
713 |
wcf_advance_style_fields_events();
|
714 |
|
715 |
+
/*sortable products*/
|
716 |
+
wcf_products_sortable();
|
|
|
717 |
});
|
|
|
|
|
718 |
})(jQuery);
|
assets/css/checkout-template-divi-rtl.css
CHANGED
@@ -6,9 +6,9 @@
|
|
6 |
}
|
7 |
|
8 |
/* Added to for Pro Support */
|
9 |
-
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,
|
10 |
/* Added to for Pro Support */
|
11 |
-
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{
|
12 |
display: inline-block;
|
13 |
width: 55%;
|
14 |
float: right;
|
@@ -44,6 +44,18 @@
|
|
44 |
padding: 3px 3px 0 3px;
|
45 |
}
|
46 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
47 |
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,
|
48 |
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{
|
49 |
font-size: 13px;
|
@@ -64,6 +76,13 @@
|
|
64 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message,
|
65 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message{
|
66 |
color: inherit !important;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
67 |
}
|
68 |
|
69 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,
|
@@ -86,7 +105,32 @@
|
|
86 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{
|
87 |
font-weight: 400;
|
88 |
}
|
89 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
90 |
/*.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:checked,
|
91 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:not(:checked){
|
92 |
color: #666;
|
6 |
}
|
7 |
|
8 |
/* Added to for Pro Support */
|
9 |
+
.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .col2-set,
|
10 |
/* Added to for Pro Support */
|
11 |
+
.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .wcf-col2-set{
|
12 |
display: inline-block;
|
13 |
width: 55%;
|
14 |
float: right;
|
44 |
padding: 3px 3px 0 3px;
|
45 |
}
|
46 |
|
47 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login{
|
48 |
+
border:1px solid #d3ced2;
|
49 |
+
margin: 1em 0;
|
50 |
+
padding: 20px;
|
51 |
+
}
|
52 |
+
|
53 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .lost_password {
|
54 |
+
text-align: left;
|
55 |
+
margin-top: 0px;
|
56 |
+
margin-bottom: 0px;
|
57 |
+
}
|
58 |
+
|
59 |
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,
|
60 |
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{
|
61 |
font-size: 13px;
|
76 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message,
|
77 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message{
|
78 |
color: inherit !important;
|
79 |
+
padding: 1em 2.0em 0.4em 2em;
|
80 |
+
border-top: none;
|
81 |
+
background-color: inherit;
|
82 |
+
font-size: 14px;
|
83 |
+
font-weight: 500;
|
84 |
+
text-align: right;
|
85 |
+
margin: 0px;
|
86 |
}
|
87 |
|
88 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,
|
105 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{
|
106 |
font-weight: 400;
|
107 |
}
|
108 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-billing-fields [type="checkbox"],
|
109 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],
|
110 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"],
|
111 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],
|
112 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-account-fields input[type=checkbox] {
|
113 |
+
border: 1px solid #b4b9be;
|
114 |
+
background: #fff;
|
115 |
+
color: #555;
|
116 |
+
clear: none;
|
117 |
+
cursor: pointer;
|
118 |
+
display: inline-block;
|
119 |
+
line-height: 0;
|
120 |
+
height: 16px;
|
121 |
+
margin: -4px 0 0 4px;
|
122 |
+
outline: 0;
|
123 |
+
padding: 0!important;
|
124 |
+
text-align: center;
|
125 |
+
vertical-align: middle;
|
126 |
+
width: 16px;
|
127 |
+
min-width: 16px;
|
128 |
+
-webkit-appearance: none;
|
129 |
+
-webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,.1);
|
130 |
+
box-shadow: inset 0 1px 2px rgba(0,0,0,.1);
|
131 |
+
-webkit-transition: .05s border-color ease-in-out;
|
132 |
+
transition: .05s border-color ease-in-out;
|
133 |
+
}
|
134 |
/*.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:checked,
|
135 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:not(:checked){
|
136 |
color: #666;
|
assets/css/checkout-template-divi.css
CHANGED
@@ -6,9 +6,9 @@
|
|
6 |
}
|
7 |
|
8 |
/* Added to for Pro Support */
|
9 |
-
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,
|
10 |
/* Added to for Pro Support */
|
11 |
-
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{
|
12 |
display: inline-block;
|
13 |
width: 55%;
|
14 |
float: left;
|
@@ -44,6 +44,18 @@
|
|
44 |
padding: 3px 3px 0 3px;
|
45 |
}
|
46 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
47 |
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,
|
48 |
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{
|
49 |
font-size: 13px;
|
@@ -64,6 +76,13 @@
|
|
64 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message,
|
65 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message{
|
66 |
color: inherit !important;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
67 |
}
|
68 |
|
69 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,
|
@@ -86,7 +105,32 @@
|
|
86 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{
|
87 |
font-weight: 400;
|
88 |
}
|
89 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
90 |
/*.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:checked,
|
91 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:not(:checked){
|
92 |
color: #666;
|
6 |
}
|
7 |
|
8 |
/* Added to for Pro Support */
|
9 |
+
.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .col2-set,
|
10 |
/* Added to for Pro Support */
|
11 |
+
.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .wcf-col2-set{
|
12 |
display: inline-block;
|
13 |
width: 55%;
|
14 |
float: left;
|
44 |
padding: 3px 3px 0 3px;
|
45 |
}
|
46 |
|
47 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login{
|
48 |
+
border:1px solid #d3ced2;
|
49 |
+
margin: 1em 0;
|
50 |
+
padding: 20px;
|
51 |
+
}
|
52 |
+
|
53 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .lost_password {
|
54 |
+
text-align: right;
|
55 |
+
margin-top: 0px;
|
56 |
+
margin-bottom: 0px;
|
57 |
+
}
|
58 |
+
|
59 |
.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,
|
60 |
.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{
|
61 |
font-size: 13px;
|
76 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message,
|
77 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message{
|
78 |
color: inherit !important;
|
79 |
+
padding: 1em 2em 0.4em 2.0em;
|
80 |
+
border-top: none;
|
81 |
+
background-color: inherit;
|
82 |
+
font-size: 14px;
|
83 |
+
font-weight: 500;
|
84 |
+
text-align: left;
|
85 |
+
margin: 0px;
|
86 |
}
|
87 |
|
88 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,
|
105 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{
|
106 |
font-weight: 400;
|
107 |
}
|
108 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-billing-fields [type="checkbox"],
|
109 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],
|
110 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"],
|
111 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],
|
112 |
+
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-account-fields input[type=checkbox] {
|
113 |
+
border: 1px solid #b4b9be;
|
114 |
+
background: #fff;
|
115 |
+
color: #555;
|
116 |
+
clear: none;
|
117 |
+
cursor: pointer;
|
118 |
+
display: inline-block;
|
119 |
+
line-height: 0;
|
120 |
+
height: 16px;
|
121 |
+
margin: -4px 4px 0 0;
|
122 |
+
outline: 0;
|
123 |
+
padding: 0!important;
|
124 |
+
text-align: center;
|
125 |
+
vertical-align: middle;
|
126 |
+
width: 16px;
|
127 |
+
min-width: 16px;
|
128 |
+
-webkit-appearance: none;
|
129 |
+
-webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,.1);
|
130 |
+
box-shadow: inset 0 1px 2px rgba(0,0,0,.1);
|
131 |
+
-webkit-transition: .05s border-color ease-in-out;
|
132 |
+
transition: .05s border-color ease-in-out;
|
133 |
+
}
|
134 |
/*.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:checked,
|
135 |
.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type="checkbox"]:not(:checked){
|
136 |
color: #666;
|
assets/js/checkout-template.js
CHANGED
@@ -242,7 +242,7 @@
|
|
242 |
|
243 |
|
244 |
$(window).load(function(){
|
245 |
-
$( 'body' ).trigger( 'update_checkout' );
|
246 |
});
|
247 |
|
248 |
var wcf_checkout_coupons = {
|
242 |
|
243 |
|
244 |
$(window).load(function(){
|
245 |
+
// $( 'body' ).trigger( 'update_checkout' );
|
246 |
});
|
247 |
|
248 |
var wcf_checkout_coupons = {
|
assets/js/frontend.js
CHANGED
@@ -86,7 +86,6 @@
|
|
86 |
var ga_purchase_event = cartflows.wcf_ga_active['enable_purchase_event'];
|
87 |
var ga_add_to_cart = cartflows.wcf_ga_active['enable_add_to_cart'];
|
88 |
var cookies = $.cookie('wcf_ga_trans_data');
|
89 |
-
var ga_order_details = jQuery.parseJSON(cookies);
|
90 |
var is_checkout_page = cartflows.is_checkout_page;
|
91 |
|
92 |
if( 'disable' === ga_for_other_page ){
|
@@ -119,6 +118,8 @@
|
|
119 |
}
|
120 |
|
121 |
if( typeof cookies !== 'undefined' ){
|
|
|
|
|
122 |
var purchase_data = {
|
123 |
send_to: google_a_id,
|
124 |
event_category: "ecommerce",
|
86 |
var ga_purchase_event = cartflows.wcf_ga_active['enable_purchase_event'];
|
87 |
var ga_add_to_cart = cartflows.wcf_ga_active['enable_add_to_cart'];
|
88 |
var cookies = $.cookie('wcf_ga_trans_data');
|
|
|
89 |
var is_checkout_page = cartflows.is_checkout_page;
|
90 |
|
91 |
if( 'disable' === ga_for_other_page ){
|
118 |
}
|
119 |
|
120 |
if( typeof cookies !== 'undefined' ){
|
121 |
+
var ga_order_details = jQuery.parseJSON(cookies);
|
122 |
+
|
123 |
var purchase_data = {
|
124 |
send_to: google_a_id,
|
125 |
event_category: "ecommerce",
|
assets/min-css/checkout-template-divi-rtl.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c!important}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{display:inline-block;width:55%;float:right;padding-left:40px;margin:50px 0 0}.et_pb_module #wcf-embed-checkout-form .select2-container--default .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row select,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea{display:block;width:100%;min-height:34px;padding:11px 12px;font-family:inherit;font-weight:inherit;font-size:14px;line-height:1.42857143!important;color:#555;background-color:#fff;background-image:none;border:1px solid #d4d4d4;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;box-shadow:none}.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row{margin-bottom:1.1em;padding:3px 3px 0 3px}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{font-size:13px;line-height:1em;letter-spacing:.3px;font-family:inherit;font-weight:inherit;margin-bottom:8px}.cartflows-canvas #page-container{padding-top:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-info,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message{color:inherit!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error{background-color:#fff6f6!important;border:dashed 1px #a00!important;padding:25px 25px 20px!important;color:#a00!important;margin:1rem 0 1rem!important;font-size:14px!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error li{font-weight:400!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{font-weight:400}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{content:"\e600";margin:0;color:#f16334}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]{border:1px solid #b4b9be;background:#fff;color:#555;clear:none;cursor:pointer;display:inline-block;line-height:0;height:16px;margin:-4px 0 0 4px;outline:0;padding:0!important;text-align:center;vertical-align:middle;width:16px;min-width:16px;-webkit-appearance:none;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1);-webkit-transition:.05s border-color ease-in-out;transition:.05s border-color ease-in-out}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:focus{border-color:#f16334;-webkit-box-shadow:0 0 2px rgba(241,99,52,.8);box-shadow:0 0 2px rgba(241,99,52,.8)}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before{background-color:#f16334;-webkit-border-radius:50px;border-radius:50px;content:"\2022";font-size:24px;height:6px;line-height:16px;margin:4px;text-indent:-9999px;width:6px}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{display:inline-block;float:right;font:normal 15px/1 cartflows-icon;speak:none;vertical-align:middle;width:6px;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.et_pb_module #wcf-embed-checkout-form #order_review_heading,.et_pb_module #wcf-embed-checkout-form .woocommerce #ship-to-different-address,.et_pb_module #wcf-embed-checkout-form .woocommerce-additional-fields>h3,.et_pb_module #wcf-embed-checkout-form .woocommerce-billing-fields>h3{font-family:inherit;font-weight:600;font-size:20px;margin:0 0 25px 0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:inline-block!important;font-family:inherit;font-weight:600;width:45%;margin:50px 0 0;padding:0 10px 20px;border:none;border-bottom:none}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods{padding:1em 0;margin:0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #add_payment_method #payment ul.payment_methods li,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods li{line-height:2;text-align:right;margin:0;list-style:none;font-weight:inherit}.et_pb_module #wcf-embed-checkout-form #payment .woocommerce-privacy-policy-text p{font-family:inherit;font-weight:inherit;color:#444;margin-top:0;margin-bottom:1.5em}.et_pb_module #wcf-embed-checkout-form .woocommerce .shop_table #shipping_method li{list-style:none}.et_pb_module #wcf-embed-checkout-form .woocommerce a{color:#f16334;text-decoration:none}.et_pb_module #wcf-embed-checkout-form .wcf-custom-coupon-field{-js-display:flex;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;margin-bottom:25px;margin-top:25px;border-top:1px solid #dcdcdc;padding-top:25px}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message{color:inherit!important;border:none!important;background-color:transparent!important;padding:0 2em 1.2em 2em!important;font-size:14px!important;margin:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error::before,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message::before{display:block!important}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .col2-set,.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .wcf-col2-set{display:block;margin-top:10px;padding-left:0;width:100%}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce-checkout #order_review_heading{display:block!important;margin:20px 0 0;width:100%}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-wrap{display:block;float:none;margin:1em auto 1em;overflow:hidden}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1{background:#f1f1f1;border-style:none;border-width:2px;border-color:red;-webkit-border-radius:3px;border-radius:3px;display:inline-block}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2{border:2px red dashed;-webkit-border-radius:3px;border-radius:3px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-field-wrap{border-style:none;border-width:2px;border-color:red;padding:20px 25px;margin:0;font-size:1.1em;display:block;background:#ddd}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-content-container{padding:25px 0}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-offer{padding:0 25px 10px;font-size:1.2em}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-desc{padding:0 25px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-offer{padding:20px 25px;font-size:1.1em;font-weight:600}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-desc{padding:0 25px 20px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-field-wrap{border-top:2px red dashed;padding:15px 25px;margin:0;font-size:1.1em;display:block}.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c}@media only screen and (max-width:768px){.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{display:block;float:none;padding-left:0;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:block!important;float:none;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review{display:block;float:none;width:100%}}@media (max-width:767px){.et_pb_module #wcf-embed-checkout-form .woocommerce .form-row{width:100%!important}}
|
1 |
+
.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c!important}.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .wcf-col2-set{display:inline-block;width:55%;float:right;padding-left:40px;margin:50px 0 0}.et_pb_module #wcf-embed-checkout-form .select2-container--default .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row select,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea{display:block;width:100%;min-height:34px;padding:11px 12px;font-family:inherit;font-weight:inherit;font-size:14px;line-height:1.42857143!important;color:#555;background-color:#fff;background-image:none;border:1px solid #d4d4d4;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;box-shadow:none}.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row{margin-bottom:1.1em;padding:3px 3px 0 3px}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login{border:1px solid #d3ced2;margin:1em 0;padding:20px}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .lost_password{text-align:left;margin-top:0;margin-bottom:0}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{font-size:13px;line-height:1em;letter-spacing:.3px;font-family:inherit;font-weight:inherit;margin-bottom:8px}.cartflows-canvas #page-container{padding-top:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-info,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message{color:inherit!important;padding:1em 2em .4em 2em;border-top:none;background-color:inherit;font-size:14px;font-weight:500;text-align:right;margin:0}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error{background-color:#fff6f6!important;border:dashed 1px #a00!important;padding:25px 25px 20px!important;color:#a00!important;margin:1rem 0 1rem!important;font-size:14px!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error li{font-weight:400!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{font-weight:400}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-account-fields input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-billing-fields [type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]{border:1px solid #b4b9be;background:#fff;color:#555;clear:none;cursor:pointer;display:inline-block;line-height:0;height:16px;margin:-4px 0 0 4px;outline:0;padding:0!important;text-align:center;vertical-align:middle;width:16px;min-width:16px;-webkit-appearance:none;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1);-webkit-transition:.05s border-color ease-in-out;transition:.05s border-color ease-in-out}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{content:"\e600";margin:0;color:#f16334}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]{border:1px solid #b4b9be;background:#fff;color:#555;clear:none;cursor:pointer;display:inline-block;line-height:0;height:16px;margin:-4px 0 0 4px;outline:0;padding:0!important;text-align:center;vertical-align:middle;width:16px;min-width:16px;-webkit-appearance:none;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1);-webkit-transition:.05s border-color ease-in-out;transition:.05s border-color ease-in-out}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:focus{border-color:#f16334;-webkit-box-shadow:0 0 2px rgba(241,99,52,.8);box-shadow:0 0 2px rgba(241,99,52,.8)}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before{background-color:#f16334;-webkit-border-radius:50px;border-radius:50px;content:"\2022";font-size:24px;height:6px;line-height:16px;margin:4px;text-indent:-9999px;width:6px}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{display:inline-block;float:right;font:normal 15px/1 cartflows-icon;speak:none;vertical-align:middle;width:6px;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.et_pb_module #wcf-embed-checkout-form #order_review_heading,.et_pb_module #wcf-embed-checkout-form .woocommerce #ship-to-different-address,.et_pb_module #wcf-embed-checkout-form .woocommerce-additional-fields>h3,.et_pb_module #wcf-embed-checkout-form .woocommerce-billing-fields>h3{font-family:inherit;font-weight:600;font-size:20px;margin:0 0 25px 0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:inline-block!important;font-family:inherit;font-weight:600;width:45%;margin:50px 0 0;padding:0 10px 20px;border:none;border-bottom:none}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods{padding:1em 0;margin:0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #add_payment_method #payment ul.payment_methods li,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods li{line-height:2;text-align:right;margin:0;list-style:none;font-weight:inherit}.et_pb_module #wcf-embed-checkout-form #payment .woocommerce-privacy-policy-text p{font-family:inherit;font-weight:inherit;color:#444;margin-top:0;margin-bottom:1.5em}.et_pb_module #wcf-embed-checkout-form .woocommerce .shop_table #shipping_method li{list-style:none}.et_pb_module #wcf-embed-checkout-form .woocommerce a{color:#f16334;text-decoration:none}.et_pb_module #wcf-embed-checkout-form .wcf-custom-coupon-field{-js-display:flex;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;margin-bottom:25px;margin-top:25px;border-top:1px solid #dcdcdc;padding-top:25px}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message{color:inherit!important;border:none!important;background-color:transparent!important;padding:0 2em 1.2em 2em!important;font-size:14px!important;margin:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error::before,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message::before{display:block!important}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .col2-set,.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .wcf-col2-set{display:block;margin-top:10px;padding-left:0;width:100%}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce-checkout #order_review_heading{display:block!important;margin:20px 0 0;width:100%}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-wrap{display:block;float:none;margin:1em auto 1em;overflow:hidden}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1{background:#f1f1f1;border-style:none;border-width:2px;border-color:red;-webkit-border-radius:3px;border-radius:3px;display:inline-block}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2{border:2px red dashed;-webkit-border-radius:3px;border-radius:3px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-field-wrap{border-style:none;border-width:2px;border-color:red;padding:20px 25px;margin:0;font-size:1.1em;display:block;background:#ddd}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-content-container{padding:25px 0}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-offer{padding:0 25px 10px;font-size:1.2em}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-desc{padding:0 25px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-offer{padding:20px 25px;font-size:1.1em;font-weight:600}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-desc{padding:0 25px 20px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-field-wrap{border-top:2px red dashed;padding:15px 25px;margin:0;font-size:1.1em;display:block}.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c}@media only screen and (max-width:768px){.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{display:block;float:none;padding-left:0;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:block!important;float:none;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review{display:block;float:none;width:100%}}@media (max-width:767px){.et_pb_module #wcf-embed-checkout-form .woocommerce .form-row{width:100%!important}}
|
assets/min-css/checkout-template-divi.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c!important}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{display:inline-block;width:55%;float:left;padding-right:40px;margin:50px 0 0}.et_pb_module #wcf-embed-checkout-form .select2-container--default .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row select,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea{display:block;width:100%;min-height:34px;padding:11px 12px;font-family:inherit;font-weight:inherit;font-size:14px;line-height:1.42857143!important;color:#555;background-color:#fff;background-image:none;border:1px solid #d4d4d4;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;box-shadow:none}.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row{margin-bottom:1.1em;padding:3px 3px 0 3px}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{font-size:13px;line-height:1em;letter-spacing:.3px;font-family:inherit;font-weight:inherit;margin-bottom:8px}.cartflows-canvas #page-container{padding-top:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-info,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message{color:inherit!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error{background-color:#fff6f6!important;border:dashed 1px #a00!important;padding:25px 25px 20px!important;color:#a00!important;margin:1rem 0 1rem!important;font-size:14px!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error li{font-weight:400!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{font-weight:400}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{content:"\e600";margin:0;color:#f16334}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]{border:1px solid #b4b9be;background:#fff;color:#555;clear:none;cursor:pointer;display:inline-block;line-height:0;height:16px;margin:-4px 4px 0 0;outline:0;padding:0!important;text-align:center;vertical-align:middle;width:16px;min-width:16px;-webkit-appearance:none;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1);-webkit-transition:.05s border-color ease-in-out;transition:.05s border-color ease-in-out}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:focus{border-color:#f16334;-webkit-box-shadow:0 0 2px rgba(241,99,52,.8);box-shadow:0 0 2px rgba(241,99,52,.8)}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before{background-color:#f16334;-webkit-border-radius:50px;border-radius:50px;content:"\2022";font-size:24px;height:6px;line-height:16px;margin:4px;text-indent:-9999px;width:6px}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{display:inline-block;float:left;font:normal 15px/1 cartflows-icon;speak:none;vertical-align:middle;width:6px;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.et_pb_module #wcf-embed-checkout-form #order_review_heading,.et_pb_module #wcf-embed-checkout-form .woocommerce #ship-to-different-address,.et_pb_module #wcf-embed-checkout-form .woocommerce-additional-fields>h3,.et_pb_module #wcf-embed-checkout-form .woocommerce-billing-fields>h3{font-family:inherit;font-weight:600;font-size:20px;margin:0 0 25px 0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:inline-block!important;font-family:inherit;font-weight:600;width:45%;margin:50px 0 0;padding:0 10px 20px;border:none;border-bottom:none}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods{padding:1em 0;margin:0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #add_payment_method #payment ul.payment_methods li,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods li{line-height:2;text-align:left;margin:0;list-style:none;font-weight:inherit}.et_pb_module #wcf-embed-checkout-form #payment .woocommerce-privacy-policy-text p{font-family:inherit;font-weight:inherit;color:#444;margin-top:0;margin-bottom:1.5em}.et_pb_module #wcf-embed-checkout-form .woocommerce .shop_table #shipping_method li{list-style:none}.et_pb_module #wcf-embed-checkout-form .woocommerce a{color:#f16334;text-decoration:none}.et_pb_module #wcf-embed-checkout-form .wcf-custom-coupon-field{-js-display:flex;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;margin-bottom:25px;margin-top:25px;border-top:1px solid #dcdcdc;padding-top:25px}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message{color:inherit!important;border:none!important;background-color:transparent!important;padding:0 2em 1.2em 2em!important;font-size:14px!important;margin:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error::before,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message::before{display:block!important}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .col2-set,.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .wcf-col2-set{display:block;margin-top:10px;padding-right:0;width:100%}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce-checkout #order_review_heading{display:block!important;margin:20px 0 0;width:100%}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-wrap{display:block;float:none;margin:1em auto 1em;overflow:hidden}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1{background:#f1f1f1;border-style:none;border-width:2px;border-color:red;-webkit-border-radius:3px;border-radius:3px;display:inline-block}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2{border:2px red dashed;-webkit-border-radius:3px;border-radius:3px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-field-wrap{border-style:none;border-width:2px;border-color:red;padding:20px 25px;margin:0;font-size:1.1em;display:block;background:#ddd}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-content-container{padding:25px 0}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-offer{padding:0 25px 10px;font-size:1.2em}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-desc{padding:0 25px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-offer{padding:20px 25px;font-size:1.1em;font-weight:600}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-desc{padding:0 25px 20px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-field-wrap{border-top:2px red dashed;padding:15px 25px;margin:0;font-size:1.1em;display:block}.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c}@media only screen and (max-width:768px){.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{display:block;float:none;padding-right:0;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:block!important;float:none;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review{display:block;float:none;width:100%}}@media (max-width:767px){.et_pb_module #wcf-embed-checkout-form .woocommerce .form-row{width:100%!important}}
|
1 |
+
.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c!important}.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form-two-column .woocommerce-checkout .wcf-col2-set{display:inline-block;width:55%;float:left;padding-right:40px;margin:50px 0 0}.et_pb_module #wcf-embed-checkout-form .select2-container--default .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row select,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea{display:block;width:100%;min-height:34px;padding:11px 12px;font-family:inherit;font-weight:inherit;font-size:14px;line-height:1.42857143!important;color:#555;background-color:#fff;background-image:none;border:1px solid #d4d4d4;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;box-shadow:none}.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row{margin-bottom:1.1em;padding:3px 3px 0 3px}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login{border:1px solid #d3ced2;margin:1em 0;padding:20px}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .lost_password{text-align:right;margin-top:0;margin-bottom:0}.et_pb_module #wcf-embed-checkout-form .woocommerce form.woocommerce-form-login .form-row label,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .form-row label{font-size:13px;line-height:1em;letter-spacing:.3px;font-family:inherit;font-weight:inherit;margin-bottom:8px}.cartflows-canvas #page-container{padding-top:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-message,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-info,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-message{color:inherit!important;padding:1em 2em .4em 2em;border-top:none;background-color:inherit;font-size:14px;font-weight:500;text-align:left;margin:0}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error{background-color:#fff6f6!important;border:dashed 1px #a00!important;padding:25px 25px 20px!important;color:#a00!important;margin:1rem 0 1rem!important;font-size:14px!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-NoticeGroup .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-notices-wrapper .woocommerce-error li{font-weight:400!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-error li strong{font-weight:400}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-account-fields input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-billing-fields [type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]{border:1px solid #b4b9be;background:#fff;color:#555;clear:none;cursor:pointer;display:inline-block;line-height:0;height:16px;margin:-4px 4px 0 0;outline:0;padding:0!important;text-align:center;vertical-align:middle;width:16px;min-width:16px;-webkit-appearance:none;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1);-webkit-transition:.05s border-color ease-in-out;transition:.05s border-color ease-in-out}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{content:"\e600";margin:0;color:#f16334}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox],.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio],.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]{border:1px solid #b4b9be;background:#fff;color:#555;clear:none;cursor:pointer;display:inline-block;line-height:0;height:16px;margin:-4px 4px 0 0;outline:0;padding:0!important;text-align:center;vertical-align:middle;width:16px;min-width:16px;-webkit-appearance:none;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1);-webkit-transition:.05s border-color ease-in-out;transition:.05s border-color ease-in-out}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:focus,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:focus{border-color:#f16334;-webkit-box-shadow:0 0 2px rgba(241,99,52,.8);box-shadow:0 0 2px rgba(241,99,52,.8)}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before{background-color:#f16334;-webkit-border-radius:50px;border-radius:50px;content:"\2022";font-size:24px;height:6px;line-height:16px;margin:4px;text-indent:-9999px;width:6px}.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=checkbox]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce #payment input[type=radio]:checked:before,.et_pb_module #wcf-embed-checkout-form .woocommerce .woocommerce-shipping-fields [type=checkbox]:checked:before{display:inline-block;float:left;font:normal 15px/1 cartflows-icon;speak:none;vertical-align:middle;width:6px;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.et_pb_module #wcf-embed-checkout-form #order_review_heading,.et_pb_module #wcf-embed-checkout-form .woocommerce #ship-to-different-address,.et_pb_module #wcf-embed-checkout-form .woocommerce-additional-fields>h3,.et_pb_module #wcf-embed-checkout-form .woocommerce-billing-fields>h3{font-family:inherit;font-weight:600;font-size:20px;margin:0 0 25px 0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:inline-block!important;font-family:inherit;font-weight:600;width:45%;margin:50px 0 0;padding:0 10px 20px;border:none;border-bottom:none}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods{padding:1em 0;margin:0}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #add_payment_method #payment ul.payment_methods li,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #payment ul.payment_methods li{line-height:2;text-align:left;margin:0;list-style:none;font-weight:inherit}.et_pb_module #wcf-embed-checkout-form #payment .woocommerce-privacy-policy-text p{font-family:inherit;font-weight:inherit;color:#444;margin-top:0;margin-bottom:1.5em}.et_pb_module #wcf-embed-checkout-form .woocommerce .shop_table #shipping_method li{list-style:none}.et_pb_module #wcf-embed-checkout-form .woocommerce a{color:#f16334;text-decoration:none}.et_pb_module #wcf-embed-checkout-form .wcf-custom-coupon-field{-js-display:flex;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;margin-bottom:25px;margin-top:25px;border-top:1px solid #dcdcdc;padding-top:25px}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message{color:inherit!important;border:none!important;background-color:transparent!important;padding:0 2em 1.2em 2em!important;font-size:14px!important;margin:0!important}.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-error::before,.et_pb_module #wcf-embed-checkout-form .woocommerce .wcf-custom-coupon-field .woocommerce-message::before{display:block!important}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .col2-set,.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce .wcf-col2-set{display:block;margin-top:10px;padding-right:0;width:100%}.et_pb_module #wcf-embed-checkout-form.wcf-embed-checkout-form-one-column .woocommerce-checkout #order_review_heading{display:block!important;margin:20px 0 0;width:100%}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-wrap{display:block;float:none;margin:1em auto 1em;overflow:hidden}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1{background:#f1f1f1;border-style:none;border-width:2px;border-color:red;-webkit-border-radius:3px;border-radius:3px;display:inline-block}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2{border:2px red dashed;-webkit-border-radius:3px;border-radius:3px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-field-wrap{border-style:none;border-width:2px;border-color:red;padding:20px 25px;margin:0;font-size:1.1em;display:block;background:#ddd}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-content-container{padding:25px 0}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-offer{padding:0 25px 10px;font-size:1.2em}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-1 .wcf-bump-order-desc{padding:0 25px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-offer{padding:20px 25px;font-size:1.1em;font-weight:600}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-desc{padding:0 25px 20px}.et_pb_module #wcf-embed-checkout-form .wcf-bump-order-style-2 .wcf-bump-order-field-wrap{border-top:2px red dashed;padding:15px 25px;margin:0;font-size:1.1em;display:block}.et_pb_module #wcf-embed-checkout-form .select2-container--default.field-required .select2-selection--single,.et_pb_module #wcf-embed-checkout-form .woocommerce #order_review .input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row input.input-text.field-required,.et_pb_module #wcf-embed-checkout-form .woocommerce form .form-row textarea.input-text.field-required{border-color:#e2401c}@media only screen and (max-width:768px){.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .col2-set,.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout .wcf-col2-set{display:block;float:none;padding-right:0;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review_heading{display:block!important;float:none;width:100%}.et_pb_module #wcf-embed-checkout-form .woocommerce-checkout #order_review{display:block;float:none;width:100%}}@media (max-width:767px){.et_pb_module #wcf-embed-checkout-form .woocommerce .form-row{width:100%!important}}
|
assets/min-js/checkout-template.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(a){function o(){function r(e,o,c,t){""==e||"select"==t&&" "==e?o.hasClass("validate-required")&&c.addClass("field-required"):c.removeClass("field-required")}var e=a("form.woocommerce-checkout #customer_details"),o=e.find("input, textarea"),c=e.find("select");o.blur(function(){var e=a(this),o=e.attr("type"),c=e.closest("p.form-row"),t=e.val();r(t,c,e,o)}),c.blur(function(){var e=a(this).closest("p.form-row"),o=e.find(".select2-container--default"),c=e.find("select").val();r(c,e,o,"select")})}function c(){if("yes"==cartflows.allow_persistance&&!1!==function(){var e="test";try{return localStorage.setItem(e,e),localStorage.removeItem(e),!0}catch(e){return!1}}()){var e="form.woocommerce-checkout #customer_details",o=function(){var e=[],o=a("form.woocommerce-checkout #customer_details");localStorage.removeItem("cartflows_checkout_form"),o.find("input[type=text], select, input[type=email], input[type=tel]").each(function(){e.push({name:this.name,value:this.value})}),cartflows_checkout_form=JSON.stringify(e),localStorage.setItem("cartflows_checkout_form",cartflows_checkout_form)};(function(){if(null!=localStorage.getItem("cartflows_checkout_form")){checkout_data=JSON.parse(localStorage.getItem("cartflows_checkout_form"));for(var e=0;e<checkout_data.length;e++)a("form.woocommerce-checkout [name="+checkout_data[e].name+"]").hasClass("select2-hidden-accessible")?a("form.woocommerce-checkout [name="+checkout_data[e].name+"]").selectWoo("val",[checkout_data[e].value]):a("form.woocommerce-checkout [name="+checkout_data[e].name+"]").val(checkout_data[e].value)}})(),a(e+" input, "+e+" select").change(function(){o()})}}a(window).load(function(){
|
1 |
+
!function(a){function o(){function r(e,o,c,t){""==e||"select"==t&&" "==e?o.hasClass("validate-required")&&c.addClass("field-required"):c.removeClass("field-required")}var e=a("form.woocommerce-checkout #customer_details"),o=e.find("input, textarea"),c=e.find("select");o.blur(function(){var e=a(this),o=e.attr("type"),c=e.closest("p.form-row"),t=e.val();r(t,c,e,o)}),c.blur(function(){var e=a(this).closest("p.form-row"),o=e.find(".select2-container--default"),c=e.find("select").val();r(c,e,o,"select")})}function c(){if("yes"==cartflows.allow_persistance&&!1!==function(){var e="test";try{return localStorage.setItem(e,e),localStorage.removeItem(e),!0}catch(e){return!1}}()){var e="form.woocommerce-checkout #customer_details",o=function(){var e=[],o=a("form.woocommerce-checkout #customer_details");localStorage.removeItem("cartflows_checkout_form"),o.find("input[type=text], select, input[type=email], input[type=tel]").each(function(){e.push({name:this.name,value:this.value})}),cartflows_checkout_form=JSON.stringify(e),localStorage.setItem("cartflows_checkout_form",cartflows_checkout_form)};(function(){if(null!=localStorage.getItem("cartflows_checkout_form")){checkout_data=JSON.parse(localStorage.getItem("cartflows_checkout_form"));for(var e=0;e<checkout_data.length;e++)a("form.woocommerce-checkout [name="+checkout_data[e].name+"]").hasClass("select2-hidden-accessible")?a("form.woocommerce-checkout [name="+checkout_data[e].name+"]").selectWoo("val",[checkout_data[e].value]):a("form.woocommerce-checkout [name="+checkout_data[e].name+"]").val(checkout_data[e].value)}})(),a(e+" input, "+e+" select").change(function(){o()})}}a(window).load(function(){});var t={init:function(){a(document.body).on("click",".wcf-submit-coupon",this.submit_coupon),a(document.body).on("click",".wcf-remove-coupon",this.remove_coupon)},submit_coupon:function(e){e.preventDefault();var o=a(".wcf-custom-coupon-field").find(".wcf-coupon-code-input"),c=o.val();if(""==c)return o.addClass("field-required"),!1;o.removeClass("field-required");var t={coupon_code:c,action:"wcf_woo_apply_coupon",security:cartflows.wcf_validate_coupon_nonce};a.ajax({type:"POST",url:cartflows.ajax_url,data:t,success:function(e){var o=a(".wcf-custom-coupon-field");o.find(".woocommerce-error, .woocommerce-message").remove();var c=JSON.parse(e);1==c.status&&a(document.body).trigger("update_checkout",{update_shipping_method:!1}),o.prepend(c.msg)}})},remove_coupon:function(e){e.preventDefault();var o={coupon_code:a(this).attr("data-coupon"),action:"wcf_woo_remove_coupon",security:cartflows.wcf_validate_remove_coupon_nonce};a.ajax({type:"POST",url:cartflows.ajax_url,data:o,success:function(e){var o=a(".wcf-custom-coupon-field");o.find(".woocommerce-error, .woocommerce-message").hide(),e&&(a(document.body).trigger("update_checkout",{update_shipping_method:!1}),o.prepend(e))}})}};a(document).ready(function(e){c(),o(),function(){a(".cartflows-container").find(".wcf-embed-checkout-form-two-column");var e=a(".wcf-embed-checkout-form .woocommerce-checkout").find("#billing_address_1_field"),o=a(".wcf-embed-checkout-form .woocommerce-checkout").find("#billing_address_2_field");e.hasClass("form-row-wide")&&(e.removeClass("form-row-wide"),e.addClass("form-row-first")),o.hasClass("form-row-wide")&&(o.removeClass("form-row-wide"),o.addClass("form-row-last"),o.find("label").hasClass("screen-reader-text")?o.addClass("mt20"):o.removeClass("mt20"));var c=a(".wcf-embed-checkout-form .woocommerce-checkout").find("#shipping_address_1_field"),t=a(".wcf-embed-checkout-form .woocommerce-checkout").find("#shipping_address_2_field");c.hasClass("form-row-wide")&&(c.removeClass("form-row-wide"),c.addClass("form-row-first")),t.hasClass("form-row-wide")&&(t.removeClass("form-row-wide"),t.addClass("form-row-last"),t.find("label").hasClass("screen-reader-text")?t.addClass("mt20"):t.removeClass("mt20")),a(".wcf-embed-checkout-form .woocommerce-checkout").find("#billing_country").on("change",function(e){}),a(".wcf-embed-checkout-form .woocommerce-checkout").find("#shipping_country").on("change",function(e){})}(),a(document.body).on("click","#wcf-embed-checkout-form .remove",function(e){e.preventDefault();var c=a(this).attr("data-id"),o={p_key:a(this).attr("data-item-key"),p_id:c,action:"wcf_woo_remove_cart_product",security:cartflows.wcf_validate_remove_cart_product_nonce};a.ajax({type:"POST",url:cartflows.ajax_url,data:o,success:function(e){var o=JSON.parse(e);0==o.need_shipping&&a("#wcf-embed-checkout-form").find("#ship-to-different-address-checkbox").attr("checked",!1),a("#wcf-embed-checkout-form").find(".woocommerce-notices-wrapper").first().html(o.msg),a(document).trigger("cartflows_remove_product",[c]),a("#wcf-embed-checkout-form").trigger("update_checkout")}})}),t.init()})}(jQuery);
|
assets/min-js/frontend.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(w){w(document).on("click",'a[href*="wcf-next-step"]',function(e){if(e.preventDefault(),void 0===cartflows.is_pb_preview||"1"!=cartflows.is_pb_preview)return window.location.href=cartflows.next_step,!1;e.stopPropagation()}),w(document).on("click",".wcf-next-step-link",function(e){if(void 0!==cartflows.is_pb_preview&&"1"==cartflows.is_pb_preview)return e.preventDefault(),e.stopPropagation(),!1});w(document).ready(function(e){var a=e('a[href*="wcf-next-step"]');0<a.length&&void 0!==cartflows.next_step&&(a.addClass("wcf-next-step-link"),a.attr("href",cartflows.next_step)),function(){if("OceanWP"===cartflows.current_theme&&"default"!==cartflows.page_template){var e=document.getElementById("oceanwp-style-css");null!=e&&e.remove()}}(),"1"!==cartflows.is_pb_preview&&(function(){if("enable"===cartflows.fb_active.facebook_pixel_tracking&&""!=cartflows.fb_active.facebook_pixel_id){var e=cartflows.fb_active.facebook_pixel_id,a=cartflows.fb_active.facebook_pixel_initiate_checkout,t=cartflows.fb_active.facebook_pixel_purchase_complete,c=cartflows.fb_active.facebook_pixel_add_payment_info,o=(cartflows.fb_active.facebook_pixel_tracking_for_site,cartflows.is_checkout_page);if(fbq("init",e),fbq("track","PageView",{plugin:"CartFlows"}),"enable"===a&&"1"===o&&(fbq("track","AddToCart",cartflows.params),fbq("track","InitiateCheckout",cartflows.params)),"enable"===t){var n=w.cookie("wcf_order_details");void 0!==n&&(fbq("track","Purchase",jQuery.parseJSON(n)),w.removeCookie("wcf_order_details",{path:"/"}))}"enable"===c&&jQuery("form.woocommerce-checkout").on("submit",function(){var e=cartflows.params;fbq("track","AddPaymentInfo",e)})}}(),function(){if("enable"===cartflows.wcf_ga_active.enable_google_analytics){var e=cartflows.wcf_ga_active.google_analytics_id,a=cartflows.wcf_ga_active.enable_google_analytics_for_site,t=cartflows.wcf_ga_active.enable_begin_checkout,c=cartflows.wcf_ga_active.enable_add_payment_info,o=cartflows.wcf_ga_active.enable_purchase_event,n=cartflows.wcf_ga_active.enable_add_to_cart,i=w.cookie("wcf_ga_trans_data"),r=
|
1 |
+
!function(w){w(document).on("click",'a[href*="wcf-next-step"]',function(e){if(e.preventDefault(),void 0===cartflows.is_pb_preview||"1"!=cartflows.is_pb_preview)return window.location.href=cartflows.next_step,!1;e.stopPropagation()}),w(document).on("click",".wcf-next-step-link",function(e){if(void 0!==cartflows.is_pb_preview&&"1"==cartflows.is_pb_preview)return e.preventDefault(),e.stopPropagation(),!1});w(document).ready(function(e){var a=e('a[href*="wcf-next-step"]');0<a.length&&void 0!==cartflows.next_step&&(a.addClass("wcf-next-step-link"),a.attr("href",cartflows.next_step)),function(){if("OceanWP"===cartflows.current_theme&&"default"!==cartflows.page_template){var e=document.getElementById("oceanwp-style-css");null!=e&&e.remove()}}(),"1"!==cartflows.is_pb_preview&&(function(){if("enable"===cartflows.fb_active.facebook_pixel_tracking&&""!=cartflows.fb_active.facebook_pixel_id){var e=cartflows.fb_active.facebook_pixel_id,a=cartflows.fb_active.facebook_pixel_initiate_checkout,t=cartflows.fb_active.facebook_pixel_purchase_complete,c=cartflows.fb_active.facebook_pixel_add_payment_info,o=(cartflows.fb_active.facebook_pixel_tracking_for_site,cartflows.is_checkout_page);if(fbq("init",e),fbq("track","PageView",{plugin:"CartFlows"}),"enable"===a&&"1"===o&&(fbq("track","AddToCart",cartflows.params),fbq("track","InitiateCheckout",cartflows.params)),"enable"===t){var n=w.cookie("wcf_order_details");void 0!==n&&(fbq("track","Purchase",jQuery.parseJSON(n)),w.removeCookie("wcf_order_details",{path:"/"}))}"enable"===c&&jQuery("form.woocommerce-checkout").on("submit",function(){var e=cartflows.params;fbq("track","AddPaymentInfo",e)})}}(),function(){if("enable"===cartflows.wcf_ga_active.enable_google_analytics){var e=cartflows.wcf_ga_active.google_analytics_id,a=cartflows.wcf_ga_active.enable_google_analytics_for_site,t=cartflows.wcf_ga_active.enable_begin_checkout,c=cartflows.wcf_ga_active.enable_add_payment_info,o=cartflows.wcf_ga_active.enable_purchase_event,n=cartflows.wcf_ga_active.enable_add_to_cart,i=w.cookie("wcf_ga_trans_data"),r=cartflows.is_checkout_page;if("disable"===a&>ag("event","page_view",{send_to:e,non_interaction:!0}),"1"===r){var _=cartflows.ga_param,f={send_to:e,event_category:"ecommerce",items:_,non_interaction:!0};"enable"===t&>ag("event","begin_checkout",f),"enable"===n&>ag("event","add_to_cart",f),"enable"===c&&jQuery("form.woocommerce-checkout").on("submit",function(){gtag("event","add_payment_info",{send_to:e,non_interaction:!0})})}if(void 0!==i){var s=jQuery.parseJSON(i),l={send_to:e,event_category:"ecommerce",transaction_id:s.transaction_id,value:s.value,currency:s.currency,shipping:s.shipping,tax:s.tax,items:s.items,non_interaction:!0};"enable"===o&&(gtag("event","purchase",l),w.removeCookie("wcf_ga_trans_data",{path:"/"}))}}}())})}(jQuery);
|
cartflows.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: CartFlows
|
4 |
* Plugin URI: https://cartflows.com/
|
5 |
* Description: Create beautiful checkout pages & sales flows for WooCommerce.
|
6 |
-
* Version: 1.5.
|
7 |
* Author: CartFlows Inc
|
8 |
* Author URI: https://cartflows.com/
|
9 |
* Text Domain: cartflows
|
3 |
* Plugin Name: CartFlows
|
4 |
* Plugin URI: https://cartflows.com/
|
5 |
* Description: Create beautiful checkout pages & sales flows for WooCommerce.
|
6 |
+
* Version: 1.5.9
|
7 |
* Author: CartFlows Inc
|
8 |
* Author URI: https://cartflows.com/
|
9 |
* Text Domain: cartflows
|
changelog.txt
CHANGED
@@ -1,3 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
1 |
Version 1.5.8 - Saturday, 9th May 2020
|
2 |
- Fix: Incorrect required field error messages with PayPal.
|
3 |
|
1 |
+
Version 1.5.9 - Thursday, 14th May 2020
|
2 |
+
- New: Added quantity and discount options for the product.
|
3 |
+
- Fix: Google Analytics JS error.
|
4 |
+
- Fix: Astra theme PHP notice when WooCommerce was not activated.
|
5 |
+
|
6 |
Version 1.5.8 - Saturday, 9th May 2020
|
7 |
- Fix: Incorrect required field error messages with PayPal.
|
8 |
|
classes/class-cartflows-functions.php
CHANGED
@@ -1,539 +1,539 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* CartFlows Functions.
|
4 |
-
*
|
5 |
-
* @package CARTFLOWS
|
6 |
-
*/
|
7 |
-
|
8 |
-
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
-
exit; // Exit if accessed directly.
|
10 |
-
}
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Fatal error mb_strpos fallback.
|
14 |
-
*
|
15 |
-
* @param string $string string where to find.
|
16 |
-
* @param string $search string to search.
|
17 |
-
* @since 1.0.0
|
18 |
-
*/
|
19 |
-
function wcf_mb_strpos( $string, $search ) {
|
20 |
-
|
21 |
-
if ( function_exists( 'mb_strpos' ) ) {
|
22 |
-
return mb_strpos( $string, $search, 0, 'utf-8' );
|
23 |
-
} else {
|
24 |
-
return strpos( $string, $search );
|
25 |
-
}
|
26 |
-
}
|
27 |
-
|
28 |
-
/**
|
29 |
-
* Check if cartflows pro activated.
|
30 |
-
*
|
31 |
-
* @since 1.0.0
|
32 |
-
*/
|
33 |
-
function _is_cartflows_pro() {
|
34 |
-
|
35 |
-
if ( defined( 'CARTFLOWS_PRO_FILE' ) ) {
|
36 |
-
return true;
|
37 |
-
}
|
38 |
-
|
39 |
-
return false;
|
40 |
-
|
41 |
-
}
|
42 |
-
|
43 |
-
/**
|
44 |
-
* Returns pro version number.
|
45 |
-
*
|
46 |
-
* @param int $version version number.
|
47 |
-
* @since 1.0.0
|
48 |
-
*/
|
49 |
-
function _is_cartflows_pro_ver_less_than( $version ) {
|
50 |
-
|
51 |
-
if ( defined( 'CARTFLOWS_PRO_VER' ) && version_compare( CARTFLOWS_PRO_VER, $version, '<' ) ) {
|
52 |
-
return true;
|
53 |
-
}
|
54 |
-
|
55 |
-
return false;
|
56 |
-
}
|
57 |
-
|
58 |
-
/**
|
59 |
-
* Returns step id.
|
60 |
-
*
|
61 |
-
* @since 1.0.0
|
62 |
-
*/
|
63 |
-
function _get_wcf_post_id() {
|
64 |
-
|
65 |
-
global $post;
|
66 |
-
|
67 |
-
if ( isset( $post->ID ) ) {
|
68 |
-
return $post->ID;
|
69 |
-
}
|
70 |
-
|
71 |
-
return 0;
|
72 |
-
}
|
73 |
-
|
74 |
-
/**
|
75 |
-
* Returns step id.
|
76 |
-
*
|
77 |
-
* @since 1.0.0
|
78 |
-
*/
|
79 |
-
function _get_wcf_step_id() {
|
80 |
-
|
81 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
82 |
-
|
83 |
-
global $post;
|
84 |
-
|
85 |
-
return $post->ID;
|
86 |
-
}
|
87 |
-
|
88 |
-
return false;
|
89 |
-
}
|
90 |
-
|
91 |
-
/**
|
92 |
-
* Check if it is a landing page?
|
93 |
-
*
|
94 |
-
* @since 1.0.0
|
95 |
-
*/
|
96 |
-
function _is_wcf_landing_type() {
|
97 |
-
|
98 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
99 |
-
|
100 |
-
global $post;
|
101 |
-
|
102 |
-
if ( 'landing' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
103 |
-
|
104 |
-
return true;
|
105 |
-
}
|
106 |
-
}
|
107 |
-
|
108 |
-
return false;
|
109 |
-
}
|
110 |
-
|
111 |
-
/**
|
112 |
-
* Returns landing id.
|
113 |
-
*
|
114 |
-
* @since 1.0.0
|
115 |
-
*/
|
116 |
-
function _get_wcf_landing_id() {
|
117 |
-
|
118 |
-
if ( _is_wcf_landing_type() ) {
|
119 |
-
|
120 |
-
global $post;
|
121 |
-
|
122 |
-
return $post->ID;
|
123 |
-
}
|
124 |
-
|
125 |
-
return false;
|
126 |
-
}
|
127 |
-
|
128 |
-
/**
|
129 |
-
* Is custom checkout?
|
130 |
-
*
|
131 |
-
* @param int $checkout_id checkout ID.
|
132 |
-
* @since 1.0.0
|
133 |
-
*/
|
134 |
-
function _is_wcf_meta_custom_checkout( $checkout_id ) {
|
135 |
-
|
136 |
-
$is_custom = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-custom-checkout-fields' );
|
137 |
-
|
138 |
-
if ( 'yes' === $is_custom ) {
|
139 |
-
|
140 |
-
return true;
|
141 |
-
}
|
142 |
-
|
143 |
-
return false;
|
144 |
-
}
|
145 |
-
|
146 |
-
/**
|
147 |
-
* Check if page is cartflow checkout.
|
148 |
-
*
|
149 |
-
* @since 1.0.0
|
150 |
-
* @return bool
|
151 |
-
*/
|
152 |
-
function _is_wcf_checkout_type() {
|
153 |
-
|
154 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
155 |
-
|
156 |
-
global $post;
|
157 |
-
|
158 |
-
if ( 'checkout' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
159 |
-
|
160 |
-
return true;
|
161 |
-
}
|
162 |
-
}
|
163 |
-
|
164 |
-
return false;
|
165 |
-
}
|
166 |
-
|
167 |
-
/**
|
168 |
-
* Check if AJAX call is in progress.
|
169 |
-
*
|
170 |
-
* @since 1.0.0
|
171 |
-
* @return bool
|
172 |
-
*/
|
173 |
-
function _is_wcf_doing_checkout_ajax() {
|
174 |
-
|
175 |
-
if ( wp_doing_ajax() || isset( $_GET['wc-ajax'] ) ) { //phpcs:ignore
|
176 |
-
|
177 |
-
if ( isset( $_GET['wc-ajax'] ) && //phpcs:ignore
|
178 |
-
isset( $_POST['_wcf_checkout_id'] ) //phpcs:ignore
|
179 |
-
) {
|
180 |
-
return true;
|
181 |
-
}
|
182 |
-
}
|
183 |
-
|
184 |
-
return false;
|
185 |
-
}
|
186 |
-
|
187 |
-
/**
|
188 |
-
* Check if optin AJAX call is in progress.
|
189 |
-
*
|
190 |
-
* @since 1.0.0
|
191 |
-
* @return bool
|
192 |
-
*/
|
193 |
-
function _is_wcf_doing_optin_ajax() {
|
194 |
-
|
195 |
-
if ( wp_doing_ajax() || isset( $_GET['wc-ajax'] ) ) { //phpcs:ignore
|
196 |
-
|
197 |
-
if ( isset( $_GET['wc-ajax'] ) && //phpcs:ignore
|
198 |
-
isset( $_POST['_wcf_optin_id'] ) //phpcs:ignore
|
199 |
-
) {
|
200 |
-
return true;
|
201 |
-
}
|
202 |
-
}
|
203 |
-
|
204 |
-
return false;
|
205 |
-
}
|
206 |
-
|
207 |
-
/**
|
208 |
-
* Returns checkout ID.
|
209 |
-
*
|
210 |
-
* @since 1.0.0
|
211 |
-
* @return int/bool
|
212 |
-
*/
|
213 |
-
function _get_wcf_checkout_id() {
|
214 |
-
|
215 |
-
if ( _is_wcf_checkout_type() ) {
|
216 |
-
|
217 |
-
global $post;
|
218 |
-
|
219 |
-
return $post->ID;
|
220 |
-
}
|
221 |
-
|
222 |
-
return false;
|
223 |
-
}
|
224 |
-
|
225 |
-
/**
|
226 |
-
* Check if it is checkout shortcode.
|
227 |
-
*
|
228 |
-
* @since 1.0.0
|
229 |
-
* @return bool
|
230 |
-
*/
|
231 |
-
function _is_wcf_checkout_shortcode() {
|
232 |
-
|
233 |
-
global $post;
|
234 |
-
|
235 |
-
if ( ! empty( $post ) && has_shortcode( $post->post_content, 'cartflows_checkout' ) ) {
|
236 |
-
|
237 |
-
return true;
|
238 |
-
}
|
239 |
-
|
240 |
-
return false;
|
241 |
-
}
|
242 |
-
|
243 |
-
/**
|
244 |
-
* Check if it is checkout shortcode.
|
245 |
-
*
|
246 |
-
* @since 1.0.0
|
247 |
-
* @param string $content shortcode content.
|
248 |
-
* @return bool
|
249 |
-
*/
|
250 |
-
function _get_wcf_checkout_id_from_shortcode( $content = '' ) {
|
251 |
-
|
252 |
-
$checkout_id = 0;
|
253 |
-
|
254 |
-
if ( ! empty( $content ) ) {
|
255 |
-
|
256 |
-
$regex_pattern = get_shortcode_regex( array( 'cartflows_checkout' ) );
|
257 |
-
|
258 |
-
preg_match( '/' . $regex_pattern . '/s', $content, $regex_matches );
|
259 |
-
|
260 |
-
if ( ! empty( $regex_matches ) ) {
|
261 |
-
|
262 |
-
if ( 'cartflows_checkout' == $regex_matches[2] ) {
|
263 |
-
|
264 |
-
$attribure_str = str_replace( ' ', '&', trim( $regex_matches[3] ) );
|
265 |
-
$attribure_str = str_replace( '"', '', $attribure_str );
|
266 |
-
|
267 |
-
$attributes = wp_parse_args( $attribure_str );
|
268 |
-
|
269 |
-
if ( isset( $attributes['id'] ) ) {
|
270 |
-
$checkout_id = $attributes['id'];
|
271 |
-
}
|
272 |
-
}
|
273 |
-
}
|
274 |
-
}
|
275 |
-
|
276 |
-
return $checkout_id;
|
277 |
-
}
|
278 |
-
|
279 |
-
/**
|
280 |
-
* Check if post type is upsell.
|
281 |
-
*
|
282 |
-
* @since 1.0.0
|
283 |
-
* @return bool
|
284 |
-
*/
|
285 |
-
function _is_wcf_upsell_type() {
|
286 |
-
|
287 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
288 |
-
|
289 |
-
global $post;
|
290 |
-
|
291 |
-
if ( 'upsell' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
292 |
-
|
293 |
-
return true;
|
294 |
-
}
|
295 |
-
}
|
296 |
-
|
297 |
-
return false;
|
298 |
-
}
|
299 |
-
|
300 |
-
/**
|
301 |
-
* Returns upsell ID.
|
302 |
-
*
|
303 |
-
* @since 1.0.0
|
304 |
-
* @return int/bool
|
305 |
-
*/
|
306 |
-
function _get_wcf_upsell_id() {
|
307 |
-
|
308 |
-
if ( _is_wcf_upsell_type() ) {
|
309 |
-
|
310 |
-
global $post;
|
311 |
-
|
312 |
-
return $post->ID;
|
313 |
-
}
|
314 |
-
|
315 |
-
return false;
|
316 |
-
}
|
317 |
-
|
318 |
-
/**
|
319 |
-
* Check if post is of type downsell.
|
320 |
-
*
|
321 |
-
* @since 1.0.0
|
322 |
-
* @return int/bool
|
323 |
-
*/
|
324 |
-
function _is_wcf_downsell_type() {
|
325 |
-
|
326 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
327 |
-
|
328 |
-
global $post;
|
329 |
-
|
330 |
-
if ( 'downsell' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
331 |
-
|
332 |
-
return true;
|
333 |
-
}
|
334 |
-
}
|
335 |
-
|
336 |
-
return false;
|
337 |
-
}
|
338 |
-
|
339 |
-
/**
|
340 |
-
* Get downsell page ID.
|
341 |
-
*
|
342 |
-
* @since 1.0.0
|
343 |
-
* @return int/bool
|
344 |
-
*/
|
345 |
-
function _get_wcf_downsell_id() {
|
346 |
-
|
347 |
-
if ( _is_wcf_downsell_type() ) {
|
348 |
-
|
349 |
-
global $post;
|
350 |
-
|
351 |
-
return $post->ID;
|
352 |
-
}
|
353 |
-
|
354 |
-
return false;
|
355 |
-
}
|
356 |
-
|
357 |
-
/**
|
358 |
-
* Check if page is of thank you type.
|
359 |
-
*
|
360 |
-
* @since 1.0.0
|
361 |
-
* @return int/bool
|
362 |
-
*/
|
363 |
-
function _is_wcf_thankyou_type() {
|
364 |
-
|
365 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
366 |
-
|
367 |
-
global $post;
|
368 |
-
|
369 |
-
if ( 'thankyou' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
370 |
-
|
371 |
-
return true;
|
372 |
-
}
|
373 |
-
}
|
374 |
-
|
375 |
-
return false;
|
376 |
-
}
|
377 |
-
|
378 |
-
/**
|
379 |
-
* Get thank you page ID.
|
380 |
-
*
|
381 |
-
* @since 1.0.0
|
382 |
-
* @return int/bool
|
383 |
-
*/
|
384 |
-
function _get_wcf_thankyou_id() {
|
385 |
-
|
386 |
-
if ( _is_wcf_thankyou_type() ) {
|
387 |
-
|
388 |
-
global $post;
|
389 |
-
|
390 |
-
return $post->ID;
|
391 |
-
}
|
392 |
-
|
393 |
-
return false;
|
394 |
-
}
|
395 |
-
|
396 |
-
|
397 |
-
/**
|
398 |
-
* Check if post type is upsell.
|
399 |
-
*
|
400 |
-
* @since 1.0.0
|
401 |
-
* @return bool
|
402 |
-
*/
|
403 |
-
function _is_wcf_base_offer_type() {
|
404 |
-
|
405 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
406 |
-
|
407 |
-
global $post;
|
408 |
-
|
409 |
-
$step_type = get_post_meta( $post->ID, 'wcf-step-type', true );
|
410 |
-
|
411 |
-
if ( 'upsell' === $step_type || 'downsell' === $step_type ) {
|
412 |
-
|
413 |
-
return true;
|
414 |
-
}
|
415 |
-
}
|
416 |
-
|
417 |
-
return false;
|
418 |
-
}
|
419 |
-
|
420 |
-
/**
|
421 |
-
* Returns upsell ID.
|
422 |
-
*
|
423 |
-
* @since 1.0.0
|
424 |
-
* @return int/bool
|
425 |
-
*/
|
426 |
-
function _get_wcf_base_offer_id() {
|
427 |
-
|
428 |
-
if ( _is_wcf_base_offer_type() ) {
|
429 |
-
|
430 |
-
global $post;
|
431 |
-
|
432 |
-
return $post->ID;
|
433 |
-
}
|
434 |
-
|
435 |
-
return false;
|
436 |
-
}
|
437 |
-
|
438 |
-
/**
|
439 |
-
* Check if page is of optin type.
|
440 |
-
*
|
441 |
-
* @since 1.0.0
|
442 |
-
* @return int/bool
|
443 |
-
*/
|
444 |
-
function _is_wcf_optin_type() {
|
445 |
-
|
446 |
-
if ( wcf()->utils->is_step_post_type() ) {
|
447 |
-
|
448 |
-
global $post;
|
449 |
-
|
450 |
-
if ( 'optin' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
451 |
-
|
452 |
-
return true;
|
453 |
-
}
|
454 |
-
}
|
455 |
-
|
456 |
-
return false;
|
457 |
-
}
|
458 |
-
|
459 |
-
/**
|
460 |
-
* Get optin page ID.
|
461 |
-
*
|
462 |
-
* @since 1.0.0
|
463 |
-
* @return int/bool
|
464 |
-
*/
|
465 |
-
function _get_wcf_optin_id() {
|
466 |
-
|
467 |
-
if ( _is_wcf_optin_type() ) {
|
468 |
-
|
469 |
-
global $post;
|
470 |
-
|
471 |
-
return $post->ID;
|
472 |
-
}
|
473 |
-
|
474 |
-
return false;
|
475 |
-
}
|
476 |
-
|
477 |
-
/**
|
478 |
-
* Define a constant if it is not already defined.
|
479 |
-
*
|
480 |
-
* @since 3.0.0
|
481 |
-
* @param string $name Constant name.
|
482 |
-
* @param mixed $value Value.
|
483 |
-
*/
|
484 |
-
function wcf_maybe_define_constant( $name, $value ) {
|
485 |
-
if ( ! defined( $name ) ) {
|
486 |
-
define( $name, $value );
|
487 |
-
}
|
488 |
-
}
|
489 |
-
|
490 |
-
|
491 |
-
if ( ! function_exists( 'wp_body_open' ) ) {
|
492 |
-
/**
|
493 |
-
* Fire the wp_body_open action.
|
494 |
-
*
|
495 |
-
* Added for backwards compatibility to support WordPress versions prior to 5.2.0.
|
496 |
-
*/
|
497 |
-
function wp_body_open() {
|
498 |
-
/**
|
499 |
-
* Triggered after the opening <body> tag.
|
500 |
-
*/
|
501 |
-
do_action( 'wp_body_open' );
|
502 |
-
}
|
503 |
-
}
|
504 |
-
|
505 |
-
/**
|
506 |
-
* Check if type is optin by id.
|
507 |
-
*
|
508 |
-
* @param int $post_id post id.
|
509 |
-
*
|
510 |
-
* @return int/bool
|
511 |
-
* @since 1.0.0
|
512 |
-
*/
|
513 |
-
function _wcf_check_is_optin_by_id( $post_id ) {
|
514 |
-
|
515 |
-
if ( 'optin' === get_post_meta( $post_id, 'wcf-step-type', true ) ) {
|
516 |
-
|
517 |
-
return true;
|
518 |
-
}
|
519 |
-
|
520 |
-
return false;
|
521 |
-
}
|
522 |
-
|
523 |
-
/**
|
524 |
-
* Supported Page Template
|
525 |
-
*
|
526 |
-
* @param string $page_template current page template.
|
527 |
-
*
|
528 |
-
* @return int/bool
|
529 |
-
* @since 1.5.7
|
530 |
-
*/
|
531 |
-
function _wcf_supported_template( $page_template ) {
|
532 |
-
|
533 |
-
if ( in_array( $page_template, array( 'cartflows-default', 'cartflows-canvas' ), true ) ) {
|
534 |
-
|
535 |
-
return true;
|
536 |
-
}
|
537 |
-
|
538 |
-
return false;
|
539 |
-
}
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* CartFlows Functions.
|
4 |
+
*
|
5 |
+
* @package CARTFLOWS
|
6 |
+
*/
|
7 |
+
|
8 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
+
exit; // Exit if accessed directly.
|
10 |
+
}
|
11 |
+
|
12 |
+
/**
|
13 |
+
* Fatal error mb_strpos fallback.
|
14 |
+
*
|
15 |
+
* @param string $string string where to find.
|
16 |
+
* @param string $search string to search.
|
17 |
+
* @since 1.0.0
|
18 |
+
*/
|
19 |
+
function wcf_mb_strpos( $string, $search ) {
|
20 |
+
|
21 |
+
if ( function_exists( 'mb_strpos' ) ) {
|
22 |
+
return mb_strpos( $string, $search, 0, 'utf-8' );
|
23 |
+
} else {
|
24 |
+
return strpos( $string, $search );
|
25 |
+
}
|
26 |
+
}
|
27 |
+
|
28 |
+
/**
|
29 |
+
* Check if cartflows pro activated.
|
30 |
+
*
|
31 |
+
* @since 1.0.0
|
32 |
+
*/
|
33 |
+
function _is_cartflows_pro() {
|
34 |
+
|
35 |
+
if ( defined( 'CARTFLOWS_PRO_FILE' ) ) {
|
36 |
+
return true;
|
37 |
+
}
|
38 |
+
|
39 |
+
return false;
|
40 |
+
|
41 |
+
}
|
42 |
+
|
43 |
+
/**
|
44 |
+
* Returns pro version number.
|
45 |
+
*
|
46 |
+
* @param int $version version number.
|
47 |
+
* @since 1.0.0
|
48 |
+
*/
|
49 |
+
function _is_cartflows_pro_ver_less_than( $version ) {
|
50 |
+
|
51 |
+
if ( defined( 'CARTFLOWS_PRO_VER' ) && version_compare( CARTFLOWS_PRO_VER, $version, '<' ) ) {
|
52 |
+
return true;
|
53 |
+
}
|
54 |
+
|
55 |
+
return false;
|
56 |
+
}
|
57 |
+
|
58 |
+
/**
|
59 |
+
* Returns step id.
|
60 |
+
*
|
61 |
+
* @since 1.0.0
|
62 |
+
*/
|
63 |
+
function _get_wcf_post_id() {
|
64 |
+
|
65 |
+
global $post;
|
66 |
+
|
67 |
+
if ( isset( $post->ID ) ) {
|
68 |
+
return $post->ID;
|
69 |
+
}
|
70 |
+
|
71 |
+
return 0;
|
72 |
+
}
|
73 |
+
|
74 |
+
/**
|
75 |
+
* Returns step id.
|
76 |
+
*
|
77 |
+
* @since 1.0.0
|
78 |
+
*/
|
79 |
+
function _get_wcf_step_id() {
|
80 |
+
|
81 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
82 |
+
|
83 |
+
global $post;
|
84 |
+
|
85 |
+
return $post->ID;
|
86 |
+
}
|
87 |
+
|
88 |
+
return false;
|
89 |
+
}
|
90 |
+
|
91 |
+
/**
|
92 |
+
* Check if it is a landing page?
|
93 |
+
*
|
94 |
+
* @since 1.0.0
|
95 |
+
*/
|
96 |
+
function _is_wcf_landing_type() {
|
97 |
+
|
98 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
99 |
+
|
100 |
+
global $post;
|
101 |
+
|
102 |
+
if ( 'landing' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
103 |
+
|
104 |
+
return true;
|
105 |
+
}
|
106 |
+
}
|
107 |
+
|
108 |
+
return false;
|
109 |
+
}
|
110 |
+
|
111 |
+
/**
|
112 |
+
* Returns landing id.
|
113 |
+
*
|
114 |
+
* @since 1.0.0
|
115 |
+
*/
|
116 |
+
function _get_wcf_landing_id() {
|
117 |
+
|
118 |
+
if ( _is_wcf_landing_type() ) {
|
119 |
+
|
120 |
+
global $post;
|
121 |
+
|
122 |
+
return $post->ID;
|
123 |
+
}
|
124 |
+
|
125 |
+
return false;
|
126 |
+
}
|
127 |
+
|
128 |
+
/**
|
129 |
+
* Is custom checkout?
|
130 |
+
*
|
131 |
+
* @param int $checkout_id checkout ID.
|
132 |
+
* @since 1.0.0
|
133 |
+
*/
|
134 |
+
function _is_wcf_meta_custom_checkout( $checkout_id ) {
|
135 |
+
|
136 |
+
$is_custom = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-custom-checkout-fields' );
|
137 |
+
|
138 |
+
if ( 'yes' === $is_custom ) {
|
139 |
+
|
140 |
+
return true;
|
141 |
+
}
|
142 |
+
|
143 |
+
return false;
|
144 |
+
}
|
145 |
+
|
146 |
+
/**
|
147 |
+
* Check if page is cartflow checkout.
|
148 |
+
*
|
149 |
+
* @since 1.0.0
|
150 |
+
* @return bool
|
151 |
+
*/
|
152 |
+
function _is_wcf_checkout_type() {
|
153 |
+
|
154 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
155 |
+
|
156 |
+
global $post;
|
157 |
+
|
158 |
+
if ( 'checkout' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
159 |
+
|
160 |
+
return true;
|
161 |
+
}
|
162 |
+
}
|
163 |
+
|
164 |
+
return false;
|
165 |
+
}
|
166 |
+
|
167 |
+
/**
|
168 |
+
* Check if AJAX call is in progress.
|
169 |
+
*
|
170 |
+
* @since 1.0.0
|
171 |
+
* @return bool
|
172 |
+
*/
|
173 |
+
function _is_wcf_doing_checkout_ajax() {
|
174 |
+
|
175 |
+
if ( wp_doing_ajax() || isset( $_GET['wc-ajax'] ) ) { //phpcs:ignore
|
176 |
+
|
177 |
+
if ( isset( $_GET['wc-ajax'] ) && //phpcs:ignore
|
178 |
+
isset( $_POST['_wcf_checkout_id'] ) //phpcs:ignore
|
179 |
+
) {
|
180 |
+
return true;
|
181 |
+
}
|
182 |
+
}
|
183 |
+
|
184 |
+
return false;
|
185 |
+
}
|
186 |
+
|
187 |
+
/**
|
188 |
+
* Check if optin AJAX call is in progress.
|
189 |
+
*
|
190 |
+
* @since 1.0.0
|
191 |
+
* @return bool
|
192 |
+
*/
|
193 |
+
function _is_wcf_doing_optin_ajax() {
|
194 |
+
|
195 |
+
if ( wp_doing_ajax() || isset( $_GET['wc-ajax'] ) ) { //phpcs:ignore
|
196 |
+
|
197 |
+
if ( isset( $_GET['wc-ajax'] ) && //phpcs:ignore
|
198 |
+
isset( $_POST['_wcf_optin_id'] ) //phpcs:ignore
|
199 |
+
) {
|
200 |
+
return true;
|
201 |
+
}
|
202 |
+
}
|
203 |
+
|
204 |
+
return false;
|
205 |
+
}
|
206 |
+
|
207 |
+
/**
|
208 |
+
* Returns checkout ID.
|
209 |
+
*
|
210 |
+
* @since 1.0.0
|
211 |
+
* @return int/bool
|
212 |
+
*/
|
213 |
+
function _get_wcf_checkout_id() {
|
214 |
+
|
215 |
+
if ( _is_wcf_checkout_type() ) {
|
216 |
+
|
217 |
+
global $post;
|
218 |
+
|
219 |
+
return $post->ID;
|
220 |
+
}
|
221 |
+
|
222 |
+
return false;
|
223 |
+
}
|
224 |
+
|
225 |
+
/**
|
226 |
+
* Check if it is checkout shortcode.
|
227 |
+
*
|
228 |
+
* @since 1.0.0
|
229 |
+
* @return bool
|
230 |
+
*/
|
231 |
+
function _is_wcf_checkout_shortcode() {
|
232 |
+
|
233 |
+
global $post;
|
234 |
+
|
235 |
+
if ( ! empty( $post ) && has_shortcode( $post->post_content, 'cartflows_checkout' ) ) {
|
236 |
+
|
237 |
+
return true;
|
238 |
+
}
|
239 |
+
|
240 |
+
return false;
|
241 |
+
}
|
242 |
+
|
243 |
+
/**
|
244 |
+
* Check if it is checkout shortcode.
|
245 |
+
*
|
246 |
+
* @since 1.0.0
|
247 |
+
* @param string $content shortcode content.
|
248 |
+
* @return bool
|
249 |
+
*/
|
250 |
+
function _get_wcf_checkout_id_from_shortcode( $content = '' ) {
|
251 |
+
|
252 |
+
$checkout_id = 0;
|
253 |
+
|
254 |
+
if ( ! empty( $content ) ) {
|
255 |
+
|
256 |
+
$regex_pattern = get_shortcode_regex( array( 'cartflows_checkout' ) );
|
257 |
+
|
258 |
+
preg_match( '/' . $regex_pattern . '/s', $content, $regex_matches );
|
259 |
+
|
260 |
+
if ( ! empty( $regex_matches ) ) {
|
261 |
+
|
262 |
+
if ( 'cartflows_checkout' == $regex_matches[2] ) {
|
263 |
+
|
264 |
+
$attribure_str = str_replace( ' ', '&', trim( $regex_matches[3] ) );
|
265 |
+
$attribure_str = str_replace( '"', '', $attribure_str );
|
266 |
+
|
267 |
+
$attributes = wp_parse_args( $attribure_str );
|
268 |
+
|
269 |
+
if ( isset( $attributes['id'] ) ) {
|
270 |
+
$checkout_id = $attributes['id'];
|
271 |
+
}
|
272 |
+
}
|
273 |
+
}
|
274 |
+
}
|
275 |
+
|
276 |
+
return $checkout_id;
|
277 |
+
}
|
278 |
+
|
279 |
+
/**
|
280 |
+
* Check if post type is upsell.
|
281 |
+
*
|
282 |
+
* @since 1.0.0
|
283 |
+
* @return bool
|
284 |
+
*/
|
285 |
+
function _is_wcf_upsell_type() {
|
286 |
+
|
287 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
288 |
+
|
289 |
+
global $post;
|
290 |
+
|
291 |
+
if ( 'upsell' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
292 |
+
|
293 |
+
return true;
|
294 |
+
}
|
295 |
+
}
|
296 |
+
|
297 |
+
return false;
|
298 |
+
}
|
299 |
+
|
300 |
+
/**
|
301 |
+
* Returns upsell ID.
|
302 |
+
*
|
303 |
+
* @since 1.0.0
|
304 |
+
* @return int/bool
|
305 |
+
*/
|
306 |
+
function _get_wcf_upsell_id() {
|
307 |
+
|
308 |
+
if ( _is_wcf_upsell_type() ) {
|
309 |
+
|
310 |
+
global $post;
|
311 |
+
|
312 |
+
return $post->ID;
|
313 |
+
}
|
314 |
+
|
315 |
+
return false;
|
316 |
+
}
|
317 |
+
|
318 |
+
/**
|
319 |
+
* Check if post is of type downsell.
|
320 |
+
*
|
321 |
+
* @since 1.0.0
|
322 |
+
* @return int/bool
|
323 |
+
*/
|
324 |
+
function _is_wcf_downsell_type() {
|
325 |
+
|
326 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
327 |
+
|
328 |
+
global $post;
|
329 |
+
|
330 |
+
if ( 'downsell' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
331 |
+
|
332 |
+
return true;
|
333 |
+
}
|
334 |
+
}
|
335 |
+
|
336 |
+
return false;
|
337 |
+
}
|
338 |
+
|
339 |
+
/**
|
340 |
+
* Get downsell page ID.
|
341 |
+
*
|
342 |
+
* @since 1.0.0
|
343 |
+
* @return int/bool
|
344 |
+
*/
|
345 |
+
function _get_wcf_downsell_id() {
|
346 |
+
|
347 |
+
if ( _is_wcf_downsell_type() ) {
|
348 |
+
|
349 |
+
global $post;
|
350 |
+
|
351 |
+
return $post->ID;
|
352 |
+
}
|
353 |
+
|
354 |
+
return false;
|
355 |
+
}
|
356 |
+
|
357 |
+
/**
|
358 |
+
* Check if page is of thank you type.
|
359 |
+
*
|
360 |
+
* @since 1.0.0
|
361 |
+
* @return int/bool
|
362 |
+
*/
|
363 |
+
function _is_wcf_thankyou_type() {
|
364 |
+
|
365 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
366 |
+
|
367 |
+
global $post;
|
368 |
+
|
369 |
+
if ( 'thankyou' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
370 |
+
|
371 |
+
return true;
|
372 |
+
}
|
373 |
+
}
|
374 |
+
|
375 |
+
return false;
|
376 |
+
}
|
377 |
+
|
378 |
+
/**
|
379 |
+
* Get thank you page ID.
|
380 |
+
*
|
381 |
+
* @since 1.0.0
|
382 |
+
* @return int/bool
|
383 |
+
*/
|
384 |
+
function _get_wcf_thankyou_id() {
|
385 |
+
|
386 |
+
if ( _is_wcf_thankyou_type() ) {
|
387 |
+
|
388 |
+
global $post;
|
389 |
+
|
390 |
+
return $post->ID;
|
391 |
+
}
|
392 |
+
|
393 |
+
return false;
|
394 |
+
}
|
395 |
+
|
396 |
+
|
397 |
+
/**
|
398 |
+
* Check if post type is upsell.
|
399 |
+
*
|
400 |
+
* @since 1.0.0
|
401 |
+
* @return bool
|
402 |
+
*/
|
403 |
+
function _is_wcf_base_offer_type() {
|
404 |
+
|
405 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
406 |
+
|
407 |
+
global $post;
|
408 |
+
|
409 |
+
$step_type = get_post_meta( $post->ID, 'wcf-step-type', true );
|
410 |
+
|
411 |
+
if ( 'upsell' === $step_type || 'downsell' === $step_type ) {
|
412 |
+
|
413 |
+
return true;
|
414 |
+
}
|
415 |
+
}
|
416 |
+
|
417 |
+
return false;
|
418 |
+
}
|
419 |
+
|
420 |
+
/**
|
421 |
+
* Returns upsell ID.
|
422 |
+
*
|
423 |
+
* @since 1.0.0
|
424 |
+
* @return int/bool
|
425 |
+
*/
|
426 |
+
function _get_wcf_base_offer_id() {
|
427 |
+
|
428 |
+
if ( _is_wcf_base_offer_type() ) {
|
429 |
+
|
430 |
+
global $post;
|
431 |
+
|
432 |
+
return $post->ID;
|
433 |
+
}
|
434 |
+
|
435 |
+
return false;
|
436 |
+
}
|
437 |
+
|
438 |
+
/**
|
439 |
+
* Check if page is of optin type.
|
440 |
+
*
|
441 |
+
* @since 1.0.0
|
442 |
+
* @return int/bool
|
443 |
+
*/
|
444 |
+
function _is_wcf_optin_type() {
|
445 |
+
|
446 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
447 |
+
|
448 |
+
global $post;
|
449 |
+
|
450 |
+
if ( 'optin' === get_post_meta( $post->ID, 'wcf-step-type', true ) ) {
|
451 |
+
|
452 |
+
return true;
|
453 |
+
}
|
454 |
+
}
|
455 |
+
|
456 |
+
return false;
|
457 |
+
}
|
458 |
+
|
459 |
+
/**
|
460 |
+
* Get optin page ID.
|
461 |
+
*
|
462 |
+
* @since 1.0.0
|
463 |
+
* @return int/bool
|
464 |
+
*/
|
465 |
+
function _get_wcf_optin_id() {
|
466 |
+
|
467 |
+
if ( _is_wcf_optin_type() ) {
|
468 |
+
|
469 |
+
global $post;
|
470 |
+
|
471 |
+
return $post->ID;
|
472 |
+
}
|
473 |
+
|
474 |
+
return false;
|
475 |
+
}
|
476 |
+
|
477 |
+
/**
|
478 |
+
* Define a constant if it is not already defined.
|
479 |
+
*
|
480 |
+
* @since 3.0.0
|
481 |
+
* @param string $name Constant name.
|
482 |
+
* @param mixed $value Value.
|
483 |
+
*/
|
484 |
+
function wcf_maybe_define_constant( $name, $value ) {
|
485 |
+
if ( ! defined( $name ) ) {
|
486 |
+
define( $name, $value );
|
487 |
+
}
|
488 |
+
}
|
489 |
+
|
490 |
+
|
491 |
+
if ( ! function_exists( 'wp_body_open' ) ) {
|
492 |
+
/**
|
493 |
+
* Fire the wp_body_open action.
|
494 |
+
*
|
495 |
+
* Added for backwards compatibility to support WordPress versions prior to 5.2.0.
|
496 |
+
*/
|
497 |
+
function wp_body_open() {
|
498 |
+
/**
|
499 |
+
* Triggered after the opening <body> tag.
|
500 |
+
*/
|
501 |
+
do_action( 'wp_body_open' );
|
502 |
+
}
|
503 |
+
}
|
504 |
+
|
505 |
+
/**
|
506 |
+
* Check if type is optin by id.
|
507 |
+
*
|
508 |
+
* @param int $post_id post id.
|
509 |
+
*
|
510 |
+
* @return int/bool
|
511 |
+
* @since 1.0.0
|
512 |
+
*/
|
513 |
+
function _wcf_check_is_optin_by_id( $post_id ) {
|
514 |
+
|
515 |
+
if ( 'optin' === get_post_meta( $post_id, 'wcf-step-type', true ) ) {
|
516 |
+
|
517 |
+
return true;
|
518 |
+
}
|
519 |
+
|
520 |
+
return false;
|
521 |
+
}
|
522 |
+
|
523 |
+
/**
|
524 |
+
* Supported Page Template
|
525 |
+
*
|
526 |
+
* @param string $page_template current page template.
|
527 |
+
*
|
528 |
+
* @return int/bool
|
529 |
+
* @since 1.5.7
|
530 |
+
*/
|
531 |
+
function _wcf_supported_template( $page_template ) {
|
532 |
+
|
533 |
+
if ( in_array( $page_template, array( 'cartflows-default', 'cartflows-canvas' ), true ) ) {
|
534 |
+
|
535 |
+
return true;
|
536 |
+
}
|
537 |
+
|
538 |
+
return false;
|
539 |
+
}
|
classes/class-cartflows-loader.php
CHANGED
@@ -125,7 +125,7 @@ if ( ! class_exists( 'Cartflows_Loader' ) ) {
|
|
125 |
define( 'CARTFLOWS_BASE', plugin_basename( CARTFLOWS_FILE ) );
|
126 |
define( 'CARTFLOWS_DIR', plugin_dir_path( CARTFLOWS_FILE ) );
|
127 |
define( 'CARTFLOWS_URL', plugins_url( '/', CARTFLOWS_FILE ) );
|
128 |
-
define( 'CARTFLOWS_VER', '1.5.
|
129 |
define( 'CARTFLOWS_SLUG', 'cartflows' );
|
130 |
define( 'CARTFLOWS_SETTINGS', 'cartflows_settings' );
|
131 |
|
@@ -201,7 +201,7 @@ if ( ! class_exists( 'Cartflows_Loader' ) ) {
|
|
201 |
return;
|
202 |
}
|
203 |
|
204 |
-
if ( version_compare( CARTFLOWS_PRO_VER, '1.4
|
205 |
add_action( 'admin_notices', array( $this, 'required_cartflows_pro_notice' ) );
|
206 |
}
|
207 |
}
|
@@ -215,7 +215,7 @@ if ( ! class_exists( 'Cartflows_Loader' ) ) {
|
|
215 |
*/
|
216 |
public function required_cartflows_pro_notice() {
|
217 |
|
218 |
-
$required_pro_version = '1.4
|
219 |
|
220 |
$class = 'notice notice-warning';
|
221 |
/* translators: %s: html tags */
|
@@ -281,7 +281,9 @@ if ( ! class_exists( 'Cartflows_Loader' ) ) {
|
|
281 |
include_once CARTFLOWS_DIR . 'classes/class-cartflows-compatibility.php';
|
282 |
|
283 |
/* Theme support */
|
284 |
-
|
|
|
|
|
285 |
|
286 |
/* Admin Meta Fields*/
|
287 |
include_once CARTFLOWS_DIR . 'classes/fields/typography/class-cartflows-font-families.php';
|
125 |
define( 'CARTFLOWS_BASE', plugin_basename( CARTFLOWS_FILE ) );
|
126 |
define( 'CARTFLOWS_DIR', plugin_dir_path( CARTFLOWS_FILE ) );
|
127 |
define( 'CARTFLOWS_URL', plugins_url( '/', CARTFLOWS_FILE ) );
|
128 |
+
define( 'CARTFLOWS_VER', '1.5.9' );
|
129 |
define( 'CARTFLOWS_SLUG', 'cartflows' );
|
130 |
define( 'CARTFLOWS_SETTINGS', 'cartflows_settings' );
|
131 |
|
201 |
return;
|
202 |
}
|
203 |
|
204 |
+
if ( version_compare( CARTFLOWS_PRO_VER, '1.5.4', '<' ) ) {
|
205 |
add_action( 'admin_notices', array( $this, 'required_cartflows_pro_notice' ) );
|
206 |
}
|
207 |
}
|
215 |
*/
|
216 |
public function required_cartflows_pro_notice() {
|
217 |
|
218 |
+
$required_pro_version = '1.5.4';
|
219 |
|
220 |
$class = 'notice notice-warning';
|
221 |
/* translators: %s: html tags */
|
281 |
include_once CARTFLOWS_DIR . 'classes/class-cartflows-compatibility.php';
|
282 |
|
283 |
/* Theme support */
|
284 |
+
if ( $this->is_woo_active ) {
|
285 |
+
include_once CARTFLOWS_DIR . 'classes/class-cartflows-theme-support.php';
|
286 |
+
}
|
287 |
|
288 |
/* Admin Meta Fields*/
|
289 |
include_once CARTFLOWS_DIR . 'classes/fields/typography/class-cartflows-font-families.php';
|
classes/class-cartflows-meta-fields.php
CHANGED
@@ -1,835 +1,919 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
|
4 |
-
*
|
5 |
-
*
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
*
|
16 |
-
*
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
$
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
wp_enqueue_script(
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
'
|
79 |
-
'
|
80 |
-
|
81 |
-
|
82 |
-
'
|
83 |
-
'
|
84 |
-
'
|
85 |
-
'
|
86 |
-
'
|
87 |
-
'
|
88 |
-
'
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
'
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
|
141 |
-
|
142 |
-
|
143 |
-
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
$
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
$
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
'
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
$
|
180 |
-
$
|
181 |
-
$
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
-
|
192 |
-
|
193 |
-
|
194 |
-
|
195 |
-
|
196 |
-
|
197 |
-
|
198 |
-
|
199 |
-
|
200 |
-
|
201 |
-
|
202 |
-
|
203 |
-
|
204 |
-
|
205 |
-
|
206 |
-
|
207 |
-
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
$search =
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
|
229 |
-
|
230 |
-
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
|
236 |
-
|
237 |
-
|
238 |
-
|
239 |
-
|
240 |
-
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
|
251 |
-
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
|
257 |
-
|
258 |
-
|
259 |
-
|
260 |
-
|
261 |
-
|
262 |
-
|
263 |
-
|
264 |
-
|
265 |
-
$
|
266 |
-
|
267 |
-
|
268 |
-
|
269 |
-
|
270 |
-
|
271 |
-
|
272 |
-
|
273 |
-
|
274 |
-
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
|
280 |
-
|
281 |
-
|
282 |
-
|
283 |
-
|
284 |
-
|
285 |
-
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
-
|
290 |
-
|
291 |
-
|
292 |
-
|
293 |
-
|
294 |
-
|
295 |
-
|
296 |
-
|
297 |
-
|
298 |
-
|
299 |
-
|
300 |
-
|
301 |
-
|
302 |
-
|
303 |
-
|
304 |
-
|
305 |
-
|
306 |
-
|
307 |
-
|
308 |
-
|
309 |
-
|
310 |
-
|
311 |
-
|
312 |
-
|
313 |
-
|
314 |
-
|
315 |
-
|
316 |
-
|
317 |
-
$
|
318 |
-
|
319 |
-
|
320 |
-
|
321 |
-
|
322 |
-
|
323 |
-
|
324 |
-
|
325 |
-
|
326 |
-
|
327 |
-
|
328 |
-
|
329 |
-
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
338 |
-
|
339 |
-
|
340 |
-
|
341 |
-
|
342 |
-
|
343 |
-
|
344 |
-
|
345 |
-
|
346 |
-
|
347 |
-
|
348 |
-
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
|
354 |
-
|
355 |
-
|
356 |
-
|
357 |
-
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
372 |
-
|
373 |
-
$
|
374 |
-
|
375 |
-
|
376 |
-
|
377 |
-
|
378 |
-
|
379 |
-
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
393 |
-
|
394 |
-
|
395 |
-
|
396 |
-
|
397 |
-
|
398 |
-
|
399 |
-
|
400 |
-
|
401 |
-
|
402 |
-
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
$
|
411 |
-
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
|
418 |
-
|
419 |
-
|
420 |
-
|
421 |
-
|
422 |
-
|
423 |
-
|
424 |
-
|
425 |
-
|
426 |
-
|
427 |
-
$
|
428 |
-
$
|
429 |
-
|
430 |
-
|
431 |
-
|
432 |
-
|
433 |
-
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
|
444 |
-
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
$
|
455 |
-
|
456 |
-
|
457 |
-
|
458 |
-
|
459 |
-
|
460 |
-
|
461 |
-
|
462 |
-
|
463 |
-
$
|
464 |
-
|
465 |
-
|
466 |
-
$field_content .= '
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
|
473 |
-
|
474 |
-
|
475 |
-
|
476 |
-
|
477 |
-
|
478 |
-
|
479 |
-
|
480 |
-
|
481 |
-
|
482 |
-
|
483 |
-
|
484 |
-
|
485 |
-
|
486 |
-
|
487 |
-
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
|
495 |
-
|
496 |
-
|
497 |
-
|
498 |
-
|
499 |
-
|
500 |
-
|
501 |
-
|
502 |
-
|
503 |
-
|
504 |
-
|
505 |
-
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
$
|
512 |
-
|
513 |
-
|
514 |
-
|
515 |
-
|
516 |
-
|
517 |
-
|
518 |
-
|
519 |
-
|
520 |
-
|
521 |
-
|
522 |
-
|
523 |
-
|
524 |
-
$field_content
|
525 |
-
|
526 |
-
|
527 |
-
|
528 |
-
|
529 |
-
|
530 |
-
|
531 |
-
$
|
532 |
-
|
533 |
-
$
|
534 |
-
|
535 |
-
|
536 |
-
|
537 |
-
|
538 |
-
|
539 |
-
|
540 |
-
|
541 |
-
|
542 |
-
|
543 |
-
|
544 |
-
|
545 |
-
|
546 |
-
|
547 |
-
|
548 |
-
|
549 |
-
|
550 |
-
|
551 |
-
|
552 |
-
|
553 |
-
|
554 |
-
|
555 |
-
|
556 |
-
|
557 |
-
|
558 |
-
|
559 |
-
|
560 |
-
|
561 |
-
|
562 |
-
|
563 |
-
|
564 |
-
|
565 |
-
|
566 |
-
|
567 |
-
|
568 |
-
|
569 |
-
|
570 |
-
|
571 |
-
|
572 |
-
$
|
573 |
-
|
574 |
-
$
|
575 |
-
|
576 |
-
|
577 |
-
|
578 |
-
|
579 |
-
|
580 |
-
|
581 |
-
|
582 |
-
|
583 |
-
|
584 |
-
|
585 |
-
|
586 |
-
|
587 |
-
|
588 |
-
|
589 |
-
|
590 |
-
|
591 |
-
|
592 |
-
|
593 |
-
|
594 |
-
|
595 |
-
|
596 |
-
|
597 |
-
|
598 |
-
|
599 |
-
|
600 |
-
|
601 |
-
|
602 |
-
|
603 |
-
|
604 |
-
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
-
|
609 |
-
|
610 |
-
|
611 |
-
|
612 |
-
|
613 |
-
|
614 |
-
|
615 |
-
|
616 |
-
|
617 |
-
|
618 |
-
|
619 |
-
|
620 |
-
|
621 |
-
|
622 |
-
|
623 |
-
|
624 |
-
|
625 |
-
$
|
626 |
-
|
627 |
-
|
628 |
-
|
629 |
-
|
630 |
-
|
631 |
-
|
632 |
-
|
633 |
-
|
634 |
-
|
635 |
-
|
636 |
-
|
637 |
-
|
638 |
-
|
639 |
-
|
640 |
-
|
641 |
-
|
642 |
-
|
643 |
-
|
644 |
-
|
645 |
-
|
646 |
-
|
647 |
-
|
648 |
-
|
649 |
-
|
650 |
-
|
651 |
-
|
652 |
-
|
653 |
-
|
654 |
-
|
655 |
-
|
656 |
-
|
657 |
-
|
658 |
-
|
659 |
-
|
660 |
-
|
661 |
-
|
662 |
-
|
663 |
-
|
664 |
-
|
665 |
-
|
666 |
-
|
667 |
-
|
668 |
-
|
669 |
-
|
670 |
-
|
671 |
-
|
672 |
-
|
673 |
-
|
674 |
-
|
675 |
-
|
676 |
-
|
677 |
-
|
678 |
-
|
679 |
-
|
680 |
-
|
681 |
-
|
682 |
-
|
683 |
-
|
684 |
-
|
685 |
-
|
686 |
-
|
687 |
-
|
688 |
-
|
689 |
-
|
690 |
-
|
691 |
-
|
692 |
-
|
693 |
-
|
694 |
-
|
695 |
-
$
|
696 |
-
|
697 |
-
|
698 |
-
|
699 |
-
|
700 |
-
|
701 |
-
|
702 |
-
|
703 |
-
|
704 |
-
|
705 |
-
|
706 |
-
|
707 |
-
|
708 |
-
|
709 |
-
|
710 |
-
|
711 |
-
|
712 |
-
|
713 |
-
|
714 |
-
|
715 |
-
|
716 |
-
|
717 |
-
|
718 |
-
|
719 |
-
|
720 |
-
|
721 |
-
|
722 |
-
|
723 |
-
|
724 |
-
|
725 |
-
|
726 |
-
|
727 |
-
|
728 |
-
|
729 |
-
$
|
730 |
-
|
731 |
-
|
732 |
-
|
733 |
-
|
734 |
-
|
735 |
-
|
736 |
-
|
737 |
-
|
738 |
-
|
739 |
-
|
740 |
-
|
741 |
-
|
742 |
-
|
743 |
-
|
744 |
-
|
745 |
-
|
746 |
-
|
747 |
-
|
748 |
-
|
749 |
-
|
750 |
-
|
751 |
-
|
752 |
-
|
753 |
-
|
754 |
-
|
755 |
-
|
756 |
-
|
757 |
-
|
758 |
-
|
759 |
-
|
760 |
-
|
761 |
-
|
762 |
-
|
763 |
-
|
764 |
-
|
765 |
-
|
766 |
-
|
767 |
-
|
768 |
-
|
769 |
-
|
770 |
-
|
771 |
-
|
772 |
-
|
773 |
-
|
774 |
-
|
775 |
-
|
776 |
-
|
777 |
-
|
778 |
-
|
779 |
-
|
780 |
-
|
781 |
-
|
782 |
-
|
783 |
-
|
784 |
-
|
785 |
-
|
786 |
-
|
787 |
-
|
788 |
-
|
789 |
-
|
790 |
-
|
791 |
-
|
792 |
-
|
793 |
-
|
794 |
-
|
795 |
-
|
796 |
-
|
797 |
-
|
798 |
-
|
799 |
-
|
800 |
-
|
801 |
-
|
802 |
-
|
803 |
-
|
804 |
-
|
805 |
-
|
806 |
-
|
807 |
-
*
|
808 |
-
*
|
809 |
-
* @param array
|
810 |
-
|
811 |
-
|
812 |
-
|
813 |
-
|
814 |
-
|
815 |
-
|
816 |
-
|
817 |
-
|
818 |
-
|
819 |
-
|
820 |
-
|
821 |
-
|
822 |
-
|
823 |
-
|
824 |
-
|
825 |
-
|
826 |
-
|
827 |
-
|
828 |
-
|
829 |
-
|
830 |
-
|
831 |
-
|
832 |
-
|
833 |
-
|
834 |
-
|
835 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Meta Fields.
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
/**
|
9 |
+
* Class Cartflows_Meta_Fields.
|
10 |
+
*/
|
11 |
+
class Cartflows_Meta_Fields {
|
12 |
+
|
13 |
+
/**
|
14 |
+
* Instance
|
15 |
+
*
|
16 |
+
* @var $instance
|
17 |
+
*/
|
18 |
+
private static $instance;
|
19 |
+
|
20 |
+
/**
|
21 |
+
* Initiator
|
22 |
+
*/
|
23 |
+
public static function get_instance() {
|
24 |
+
if ( ! isset( self::$instance ) ) {
|
25 |
+
self::$instance = new self();
|
26 |
+
}
|
27 |
+
|
28 |
+
return self::$instance;
|
29 |
+
}
|
30 |
+
|
31 |
+
/**
|
32 |
+
* Constructor
|
33 |
+
*/
|
34 |
+
public function __construct() {
|
35 |
+
|
36 |
+
/* Add Scripts */
|
37 |
+
add_action( 'admin_enqueue_scripts', array( $this, 'admin_meta_scripts' ), 20 );
|
38 |
+
|
39 |
+
add_action( 'wp_ajax_wcf_json_search_coupons', array( $this, 'json_search_coupons' ) );
|
40 |
+
|
41 |
+
add_action( 'wp_ajax_wcf_json_search_pages', array( $this, 'json_search_pages' ) );
|
42 |
+
|
43 |
+
add_filter( 'cartflows_admin_js_localize', array( $this, 'localize_vars' ) );
|
44 |
+
}
|
45 |
+
|
46 |
+
/**
|
47 |
+
* Admin meta scripts
|
48 |
+
*/
|
49 |
+
public function admin_meta_scripts() {
|
50 |
+
|
51 |
+
global $pagenow;
|
52 |
+
global $post;
|
53 |
+
|
54 |
+
$screen = get_current_screen();
|
55 |
+
|
56 |
+
if (
|
57 |
+
( 'post-new.php' == $pagenow || 'post.php' == $pagenow ) &&
|
58 |
+
wcf()->utils->is_step_post_type( $screen->post_type )
|
59 |
+
) {
|
60 |
+
|
61 |
+
wp_enqueue_style( 'woocommerce_admin_styles' );
|
62 |
+
|
63 |
+
wp_enqueue_script( 'select2' );
|
64 |
+
wp_enqueue_script( 'wc-enhanced-select' );
|
65 |
+
|
66 |
+
wp_enqueue_script(
|
67 |
+
'wcf-admin-meta',
|
68 |
+
CARTFLOWS_URL . 'admin/meta-assets/js/admin-edit.js',
|
69 |
+
array( 'jquery', 'wp-color-picker' ),
|
70 |
+
CARTFLOWS_VER,
|
71 |
+
true
|
72 |
+
);
|
73 |
+
|
74 |
+
wp_enqueue_style( 'wcf-admin-meta', CARTFLOWS_URL . 'admin/meta-assets/css/admin-edit.css', array( 'wp-color-picker' ), CARTFLOWS_VER );
|
75 |
+
wp_style_add_data( 'wcf-admin-meta', 'rtl', 'replace' );
|
76 |
+
|
77 |
+
$localize = array(
|
78 |
+
'ajax_url' => admin_url( 'admin-ajax.php' ),
|
79 |
+
'google_fonts' => CartFlows_Font_Families::get_google_fonts(),
|
80 |
+
'system_fonts' => CartFlows_Font_Families::get_system_fonts(),
|
81 |
+
'font_weights' => array(
|
82 |
+
'100' => __( 'Thin 100', 'cartflows' ),
|
83 |
+
'200' => __( 'Extra-Light 200', 'cartflows' ),
|
84 |
+
'300' => __( 'Light 300', 'cartflows' ),
|
85 |
+
'400' => __( 'Normal 400', 'cartflows' ),
|
86 |
+
'500' => __( 'Medium 500', 'cartflows' ),
|
87 |
+
'600' => __( 'Semi-Bold 600', 'cartflows' ),
|
88 |
+
'700' => __( 'Bold 700', 'cartflows' ),
|
89 |
+
'800' => __( 'Extra-Bold 800', 'cartflows' ),
|
90 |
+
'900' => __( 'Ultra-Bold 900', 'cartflows' ),
|
91 |
+
),
|
92 |
+
);
|
93 |
+
|
94 |
+
wp_localize_script( 'jquery', 'wcf', apply_filters( 'wcf_js_localize', $localize ) );
|
95 |
+
|
96 |
+
do_action( 'cartflows_admin_meta_scripts' );
|
97 |
+
}
|
98 |
+
}
|
99 |
+
|
100 |
+
/**
|
101 |
+
* Function to search coupons
|
102 |
+
*/
|
103 |
+
public function json_search_coupons() {
|
104 |
+
|
105 |
+
check_admin_referer( 'wcf-json-search-coupons', 'security' );
|
106 |
+
|
107 |
+
global $wpdb;
|
108 |
+
|
109 |
+
$term = (string) urldecode( sanitize_text_field( wp_unslash( $_GET['term'] ) ) ); // phpcs:ignore
|
110 |
+
|
111 |
+
if ( empty( $term ) ) {
|
112 |
+
die();
|
113 |
+
}
|
114 |
+
|
115 |
+
$posts = wp_cache_get( 'wcf_search_coupons', 'wcf_funnel_Cart' );
|
116 |
+
|
117 |
+
if ( false === $posts ) {
|
118 |
+
$posts = $wpdb->get_results( // phpcs:ignore
|
119 |
+
$wpdb->prepare(
|
120 |
+
"SELECT *
|
121 |
+
FROM {$wpdb->prefix}posts
|
122 |
+
WHERE post_type = %s
|
123 |
+
AND post_title LIKE %s
|
124 |
+
AND post_status = %s",
|
125 |
+
'shop_coupon',
|
126 |
+
$wpdb->esc_like( $term ) . '%',
|
127 |
+
'publish'
|
128 |
+
)
|
129 |
+
);
|
130 |
+
wp_cache_set( 'wcf_search_coupons', $posts, 'wcf_funnel_Cart' );
|
131 |
+
}
|
132 |
+
|
133 |
+
$coupons_found = array();
|
134 |
+
$all_discount_types = wc_get_coupon_types();
|
135 |
+
|
136 |
+
if ( $posts ) {
|
137 |
+
foreach ( $posts as $post ) {
|
138 |
+
|
139 |
+
$discount_type = get_post_meta( $post->ID, 'discount_type', true );
|
140 |
+
|
141 |
+
if ( ! empty( $all_discount_types[ $discount_type ] ) ) {
|
142 |
+
$coupons_found[ get_the_title( $post->ID ) ] = get_the_title( $post->ID ) . ' (Type: ' . $all_discount_types[ $discount_type ] . ')';
|
143 |
+
}
|
144 |
+
}
|
145 |
+
}
|
146 |
+
|
147 |
+
wp_send_json( $coupons_found );
|
148 |
+
}
|
149 |
+
|
150 |
+
/**
|
151 |
+
* Function to search coupons
|
152 |
+
*/
|
153 |
+
public function json_search_pages() {
|
154 |
+
|
155 |
+
check_ajax_referer( 'wcf-json-search-pages', 'security' );
|
156 |
+
|
157 |
+
$term = (string) urldecode( sanitize_text_field( wp_unslash( $_GET['term'] ) ) ); // phpcs:ignore
|
158 |
+
|
159 |
+
if ( empty( $term ) ) {
|
160 |
+
die( 'not found' );
|
161 |
+
}
|
162 |
+
|
163 |
+
$search_string = $term;
|
164 |
+
$data = array();
|
165 |
+
$result = array();
|
166 |
+
|
167 |
+
add_filter( 'posts_search', array( $this, 'search_only_titles' ), 10, 2 );
|
168 |
+
|
169 |
+
$query = new WP_Query(
|
170 |
+
array(
|
171 |
+
's' => $search_string,
|
172 |
+
'post_type' => 'page',
|
173 |
+
'posts_per_page' => -1,
|
174 |
+
)
|
175 |
+
);
|
176 |
+
|
177 |
+
if ( $query->have_posts() ) {
|
178 |
+
while ( $query->have_posts() ) {
|
179 |
+
$query->the_post();
|
180 |
+
$title = get_the_title();
|
181 |
+
$title .= ( 0 != $query->post->post_parent ) ? ' (' . get_the_title( $query->post->post_parent ) . ')' : '';
|
182 |
+
$id = get_the_id();
|
183 |
+
$data[] = array(
|
184 |
+
'id' => $id,
|
185 |
+
'text' => $title,
|
186 |
+
);
|
187 |
+
}
|
188 |
+
}
|
189 |
+
|
190 |
+
if ( is_array( $data ) && ! empty( $data ) ) {
|
191 |
+
$result[] = array(
|
192 |
+
'text' => '',
|
193 |
+
'children' => $data,
|
194 |
+
);
|
195 |
+
}
|
196 |
+
|
197 |
+
wp_reset_postdata();
|
198 |
+
|
199 |
+
// return the result in json.
|
200 |
+
wp_send_json( $result );
|
201 |
+
}
|
202 |
+
|
203 |
+
/**
|
204 |
+
* Search only titles.
|
205 |
+
*
|
206 |
+
* @param string $search Field data.
|
207 |
+
* @param object $wp_query Query.
|
208 |
+
*
|
209 |
+
* @return array.
|
210 |
+
*/
|
211 |
+
public function search_only_titles( $search, $wp_query ) {
|
212 |
+
if ( ! empty( $search ) && ! empty( $wp_query->query_vars['search_terms'] ) ) {
|
213 |
+
global $wpdb;
|
214 |
+
|
215 |
+
$q = $wp_query->query_vars;
|
216 |
+
$n = ! empty( $q['exact'] ) ? '' : '%';
|
217 |
+
|
218 |
+
$search = array();
|
219 |
+
|
220 |
+
foreach ( (array) $q['search_terms'] as $term ) {
|
221 |
+
$search[] = $wpdb->prepare( "$wpdb->posts.post_title LIKE %s", $n . $wpdb->esc_like( $term ) . $n );
|
222 |
+
}
|
223 |
+
|
224 |
+
if ( ! is_user_logged_in() ) {
|
225 |
+
$search[] = "$wpdb->posts.post_password = ''";
|
226 |
+
}
|
227 |
+
|
228 |
+
$search = ' AND ' . implode( ' AND ', $search );
|
229 |
+
}
|
230 |
+
|
231 |
+
return $search;
|
232 |
+
}
|
233 |
+
|
234 |
+
/**
|
235 |
+
* Get field.
|
236 |
+
*
|
237 |
+
* @param array $field_data Field data.
|
238 |
+
* @param string $field_content Field content.
|
239 |
+
*
|
240 |
+
* @return string field.
|
241 |
+
*/
|
242 |
+
public function get_field( $field_data, $field_content ) {
|
243 |
+
|
244 |
+
$field_data['generated_content'] = $field_content;
|
245 |
+
|
246 |
+
return $this->get_meta_field_template(
|
247 |
+
'get-field.php',
|
248 |
+
$field_data
|
249 |
+
);
|
250 |
+
}
|
251 |
+
|
252 |
+
/**
|
253 |
+
* Text field.
|
254 |
+
*
|
255 |
+
* @param array $field_data Field data.
|
256 |
+
*
|
257 |
+
* @return string field.
|
258 |
+
*/
|
259 |
+
public function get_text_field( $field_data ) {
|
260 |
+
|
261 |
+
$value = $field_data['value'];
|
262 |
+
|
263 |
+
$attr = '';
|
264 |
+
|
265 |
+
if ( isset( $field_data['attr'] ) && is_array( $field_data['attr'] ) ) {
|
266 |
+
|
267 |
+
foreach ( $field_data['attr'] as $attr_key => $attr_value ) {
|
268 |
+
$attr .= ' ' . $attr_key . '="' . $attr_value . '"';
|
269 |
+
}
|
270 |
+
}
|
271 |
+
|
272 |
+
$field_content = '<input type="text" name="' . $field_data['name'] . '" value="' . esc_attr( $value ) . '" ' . $attr . '>';
|
273 |
+
|
274 |
+
return $this->get_field( $field_data, $field_content );
|
275 |
+
}
|
276 |
+
|
277 |
+
/**
|
278 |
+
* Shortcode field.
|
279 |
+
*
|
280 |
+
* @param array $field_data Field data.
|
281 |
+
*
|
282 |
+
* @return string field.
|
283 |
+
*/
|
284 |
+
public function get_shortcode_field( $field_data ) {
|
285 |
+
|
286 |
+
$attr = '';
|
287 |
+
|
288 |
+
$attr_fields = array(
|
289 |
+
'readonly' => 'readonly',
|
290 |
+
'onfocus' => 'this.select()',
|
291 |
+
'onmouseup' => 'return false',
|
292 |
+
);
|
293 |
+
|
294 |
+
if ( $attr_fields && is_array( $attr_fields ) ) {
|
295 |
+
|
296 |
+
foreach ( $attr_fields as $attr_key => $attr_value ) {
|
297 |
+
$attr .= ' ' . $attr_key . '="' . $attr_value . '"';
|
298 |
+
}
|
299 |
+
}
|
300 |
+
|
301 |
+
$field_content = '<input type="text" name="' . $field_data['name'] . '" value="' . $field_data['content'] . '" ' . $attr . '>';
|
302 |
+
|
303 |
+
return $this->get_field( $field_data, $field_content );
|
304 |
+
}
|
305 |
+
|
306 |
+
/**
|
307 |
+
* Display field.
|
308 |
+
*
|
309 |
+
* @param array $field_data Field data.
|
310 |
+
*
|
311 |
+
* @return string field.
|
312 |
+
*/
|
313 |
+
public function get_display_field( $field_data ) {
|
314 |
+
|
315 |
+
$field_content = $field_data['content'];
|
316 |
+
|
317 |
+
return $this->get_field( $field_data, $field_content );
|
318 |
+
}
|
319 |
+
|
320 |
+
/**
|
321 |
+
* Hr linke field.
|
322 |
+
*
|
323 |
+
* @param array $field_data Field data.
|
324 |
+
*
|
325 |
+
* @return string field.
|
326 |
+
*/
|
327 |
+
public function get_hr_line_field( $field_data ) {
|
328 |
+
|
329 |
+
$field_data = array(
|
330 |
+
'name' => 'wcf-hr-line',
|
331 |
+
'content' => '<hr>',
|
332 |
+
);
|
333 |
+
|
334 |
+
$field_content = $field_data['content'];
|
335 |
+
|
336 |
+
return $this->get_field( $field_data, $field_content );
|
337 |
+
}
|
338 |
+
|
339 |
+
/**
|
340 |
+
* Number field.
|
341 |
+
*
|
342 |
+
* @param array $field_data Field data.
|
343 |
+
*
|
344 |
+
* @return string field.
|
345 |
+
*/
|
346 |
+
public function get_number_field( $field_data ) {
|
347 |
+
|
348 |
+
$value = $field_data['value'];
|
349 |
+
|
350 |
+
$attr = '';
|
351 |
+
|
352 |
+
if ( isset( $field_data['attr'] ) && is_array( $field_data['attr'] ) ) {
|
353 |
+
|
354 |
+
foreach ( $field_data['attr'] as $attr_key => $attr_value ) {
|
355 |
+
$attr .= ' ' . $attr_key . '="' . $attr_value . '"';
|
356 |
+
}
|
357 |
+
}
|
358 |
+
|
359 |
+
$field_content = '<input type="number" name="' . $field_data['name'] . '" value="' . $value . '" ' . $attr . '>';
|
360 |
+
|
361 |
+
return $this->get_field( $field_data, $field_content );
|
362 |
+
}
|
363 |
+
|
364 |
+
/**
|
365 |
+
* Hidden field.
|
366 |
+
*
|
367 |
+
* @param array $field_data Field data.
|
368 |
+
*
|
369 |
+
* @return string field.
|
370 |
+
*/
|
371 |
+
public function get_hidden_field( $field_data ) {
|
372 |
+
|
373 |
+
$value = $field_data['value'];
|
374 |
+
|
375 |
+
$attr = '';
|
376 |
+
|
377 |
+
if ( isset( $field_data['attr'] ) && is_array( $field_data['attr'] ) ) {
|
378 |
+
|
379 |
+
foreach ( $field_data['attr'] as $attr_key => $attr_value ) {
|
380 |
+
$attr .= ' ' . $attr_key . '="' . $attr_value . '"';
|
381 |
+
}
|
382 |
+
}
|
383 |
+
|
384 |
+
$field_content = '<input type="hidden" id="' . $field_data['name'] . '" name="' . $field_data['name'] . '" value="' . $value . '" ' . $attr . '>';
|
385 |
+
|
386 |
+
return $this->get_field( $field_data, $field_content );
|
387 |
+
}
|
388 |
+
|
389 |
+
/**
|
390 |
+
* Text area field.
|
391 |
+
*
|
392 |
+
* @param array $field_data Field data.
|
393 |
+
*
|
394 |
+
* @return string field.
|
395 |
+
*/
|
396 |
+
public function get_area_field( $field_data ) {
|
397 |
+
|
398 |
+
$value = $field_data['value'];
|
399 |
+
|
400 |
+
$attr = '';
|
401 |
+
|
402 |
+
if ( isset( $field_data['attr'] ) && is_array( $field_data['attr'] ) ) {
|
403 |
+
|
404 |
+
foreach ( $field_data['attr'] as $attr_key => $attr_value ) {
|
405 |
+
$attr .= ' ' . $attr_key . '="' . $attr_value . '"';
|
406 |
+
}
|
407 |
+
}
|
408 |
+
|
409 |
+
$field_content = '<textarea name="' . $field_data['name'] . '" rows="10" cols="50" ' . $attr . '>';
|
410 |
+
$field_content .= $value;
|
411 |
+
$field_content .= '</textarea>';
|
412 |
+
|
413 |
+
return $this->get_field( $field_data, $field_content );
|
414 |
+
}
|
415 |
+
|
416 |
+
/**
|
417 |
+
* Only checkbox field.
|
418 |
+
*
|
419 |
+
* @param array $field_data Field data.
|
420 |
+
*
|
421 |
+
* @return string field.
|
422 |
+
*/
|
423 |
+
public function get_only_checkbox_field( $field_data ) {
|
424 |
+
|
425 |
+
$value = $field_data['value'];
|
426 |
+
|
427 |
+
$field_content = '';
|
428 |
+
if ( isset( $field_data['before'] ) ) {
|
429 |
+
$field_content .= '<span>' . $field_data['before'] . '</span>';
|
430 |
+
}
|
431 |
+
$field_content .= '<input type="hidden" name="' . $field_data['name'] . '" value="no">';
|
432 |
+
$field_content .= '<input type="checkbox" name="' . $field_data['name'] . '" value="yes" ' . checked( 'yes', $value, false ) . '>';
|
433 |
+
|
434 |
+
if ( isset( $field_data['after'] ) ) {
|
435 |
+
$field_content .= '<span>' . $field_data['after'] . '</span>';
|
436 |
+
}
|
437 |
+
|
438 |
+
if ( isset( $field_data['after_html'] ) ) {
|
439 |
+
$field_content .= '<span>' . $field_data['after_html'] . '</span>';
|
440 |
+
}
|
441 |
+
|
442 |
+
return $field_content;
|
443 |
+
}
|
444 |
+
|
445 |
+
/**
|
446 |
+
* Checkbox field.
|
447 |
+
*
|
448 |
+
* @param array $field_data Field data.
|
449 |
+
*
|
450 |
+
* @return string field.
|
451 |
+
*/
|
452 |
+
public function get_checkbox_field( $field_data ) {
|
453 |
+
|
454 |
+
$value = $field_data['value'];
|
455 |
+
|
456 |
+
$field_content = '';
|
457 |
+
if ( isset( $field_data['before'] ) ) {
|
458 |
+
$field_content .= '<span>' . $field_data['before'] . '</span>';
|
459 |
+
}
|
460 |
+
|
461 |
+
$toggle_data = '';
|
462 |
+
if ( isset( $field_data['toggle'] ) ) {
|
463 |
+
$toggle_data .= 'toggle="' . htmlspecialchars( wp_json_encode( $field_data['toggle'] ) ) . '"'; //phpcs:ignore
|
464 |
+
}
|
465 |
+
|
466 |
+
$field_content .= '<input type="hidden" name="' . $field_data['name'] . '" value="no">';
|
467 |
+
$field_content .= '<input type="checkbox" id="' . $field_data['name'] . '" name="' . $field_data['name'] . '" value="yes" ' . checked( 'yes', $value, false ) . ' ' . $toggle_data . '>';
|
468 |
+
|
469 |
+
if ( isset( $field_data['after'] ) ) {
|
470 |
+
$field_content .= '<span>' . $field_data['after'] . '</span>';
|
471 |
+
}
|
472 |
+
|
473 |
+
return $this->get_field( $field_data, $field_content );
|
474 |
+
}
|
475 |
+
|
476 |
+
/**
|
477 |
+
* Radio field.
|
478 |
+
*
|
479 |
+
* @param array $field_data Field data.
|
480 |
+
*
|
481 |
+
* @return string field.
|
482 |
+
*/
|
483 |
+
public function get_radio_field( $field_data ) {
|
484 |
+
|
485 |
+
$value = $field_data['value'];
|
486 |
+
$field_content = '';
|
487 |
+
|
488 |
+
if ( is_array( $field_data['options'] ) && ! empty( $field_data['options'] ) ) {
|
489 |
+
|
490 |
+
foreach ( $field_data['options'] as $data_key => $data_value ) {
|
491 |
+
|
492 |
+
$field_content .= '<div class="wcf-radio-option">';
|
493 |
+
$field_content .= '<input type="radio" name="' . $field_data['name'] . '" value="' . $data_key . '" ' . checked( $data_key, $value, false ) . '>';
|
494 |
+
$field_content .= $data_value;
|
495 |
+
$field_content .= '</div>';
|
496 |
+
}
|
497 |
+
}
|
498 |
+
|
499 |
+
return $this->get_field( $field_data, $field_content );
|
500 |
+
}
|
501 |
+
|
502 |
+
/**
|
503 |
+
* Font family field.
|
504 |
+
*
|
505 |
+
* @param array $field_data Field data.
|
506 |
+
*
|
507 |
+
* @return string field.
|
508 |
+
*/
|
509 |
+
public function get_font_family_field( $field_data ) {
|
510 |
+
|
511 |
+
$value = $field_data['value'];
|
512 |
+
|
513 |
+
$pro_options = isset( $field_data['pro-options'] ) ? $field_data['pro-options'] : array();
|
514 |
+
|
515 |
+
$field_content = '<select class="wcf-field-font-family" data-for="' . $field_data['for'] . '" name="' . $field_data['name'] . '">';
|
516 |
+
|
517 |
+
$field_content .= '<option value="" ' . selected( '', $value, false ) . '>Default</option>';
|
518 |
+
|
519 |
+
$field_content .= '<optgroup label="Other System Fonts">';
|
520 |
+
foreach ( CartFlows_Font_Families::get_system_fonts() as $name => $variants ) {
|
521 |
+
$field_content .= '<option value="' . esc_attr( $name ) . '" ' . selected( $name, $value, false ) . '>' . esc_attr( $name ) . '</option>';
|
522 |
+
}
|
523 |
+
$field_content .= '</optgroup>';
|
524 |
+
$field_content .= '<optgroup label="Google">';
|
525 |
+
foreach ( CartFlows_Font_Families::get_google_fonts() as $name => $single_font ) {
|
526 |
+
$variants = wcf_get_prop( $single_font, '0' );
|
527 |
+
$category = wcf_get_prop( $single_font, '1' );
|
528 |
+
$font_value = '\'' . esc_attr( $name ) . '\', ' . esc_attr( $category );
|
529 |
+
$field_content .= '<option value="' . esc_attr( $font_value ) . '" ' . selected( $font_value, $value, false ) . '>' . esc_attr( $name ) . '</option>';
|
530 |
+
}
|
531 |
+
$field_content .= '</optgroup>';
|
532 |
+
|
533 |
+
$field_content .= '</select>';
|
534 |
+
|
535 |
+
return $this->get_field( $field_data, $field_content );
|
536 |
+
}
|
537 |
+
|
538 |
+
/**
|
539 |
+
* Font weight field.
|
540 |
+
*
|
541 |
+
* @param array $field_data Field data.
|
542 |
+
*
|
543 |
+
* @return string field.
|
544 |
+
*/
|
545 |
+
public function get_font_weight_field( $field_data ) {
|
546 |
+
|
547 |
+
$value = $field_data['value'];
|
548 |
+
|
549 |
+
$pro_options = isset( $field_data['pro-options'] ) ? $field_data['pro-options'] : array();
|
550 |
+
|
551 |
+
$field_content = '<select data-selected="' . esc_attr( $value ) . '" class="wcf-field-font-weight" data-for="' . $field_data['for'] . '" name="' . $field_data['name'] . '">';
|
552 |
+
|
553 |
+
$field_content .= '<option value="" ' . selected( '', $value, false ) . '>Default</option>';
|
554 |
+
|
555 |
+
$field_content .= '</select>';
|
556 |
+
|
557 |
+
return $this->get_field( $field_data, $field_content );
|
558 |
+
}
|
559 |
+
|
560 |
+
/**
|
561 |
+
* Select field.
|
562 |
+
*
|
563 |
+
* @param array $field_data Field data.
|
564 |
+
*
|
565 |
+
* @return string field.
|
566 |
+
*/
|
567 |
+
public function get_select_field( $field_data ) {
|
568 |
+
|
569 |
+
$value = $field_data['value'];
|
570 |
+
$pro_options = isset( $field_data['pro-options'] ) ? $field_data['pro-options'] : array();
|
571 |
+
|
572 |
+
$field_content = '<select name="' . $field_data['name'] . '">';
|
573 |
+
|
574 |
+
if ( is_array( $field_data['options'] ) && ! empty( $field_data['options'] ) ) {
|
575 |
+
|
576 |
+
foreach ( $field_data['options'] as $data_key => $data_value ) {
|
577 |
+
|
578 |
+
$disabled = '';
|
579 |
+
|
580 |
+
if ( array_key_exists( $data_key, $pro_options ) ) {
|
581 |
+
$disabled = 'disabled ';
|
582 |
+
$data_value = $pro_options[ $data_key ];
|
583 |
+
}
|
584 |
+
|
585 |
+
$field_content .= '<option value="' . $data_key . '" ' . selected( $value, $data_key, false ) . ' ' . $disabled . '>' . $data_value . '</option>';
|
586 |
+
}
|
587 |
+
}
|
588 |
+
|
589 |
+
$field_content .= '</select>';
|
590 |
+
|
591 |
+
if ( isset( $field_data['after'] ) ) {
|
592 |
+
$field_content .= '<span>' . $field_data['after'] . '</span>';
|
593 |
+
}
|
594 |
+
|
595 |
+
return $this->get_field( $field_data, $field_content );
|
596 |
+
}
|
597 |
+
|
598 |
+
/**
|
599 |
+
* Color picker field.
|
600 |
+
*
|
601 |
+
* @param array $field_data Field data.
|
602 |
+
*
|
603 |
+
* @return string field.
|
604 |
+
*/
|
605 |
+
public function get_color_picker_field( $field_data ) {
|
606 |
+
|
607 |
+
$value = $field_data['value'];
|
608 |
+
|
609 |
+
$field_data['field_type'] = 'color-picker';
|
610 |
+
|
611 |
+
$field_content = '<input class="wcf-color-picker" type="text" name="' . $field_data['name'] . '" value="' . $value . '">';
|
612 |
+
|
613 |
+
return $this->get_field( $field_data, $field_content );
|
614 |
+
}
|
615 |
+
|
616 |
+
/**
|
617 |
+
* Product selection field.
|
618 |
+
*
|
619 |
+
* @param array $field_data Field data.
|
620 |
+
*
|
621 |
+
* @return string field.
|
622 |
+
*/
|
623 |
+
public function get_product_selection_field( $field_data ) {
|
624 |
+
|
625 |
+
$value = $field_data['value'];
|
626 |
+
|
627 |
+
$multiple = '';
|
628 |
+
|
629 |
+
if ( isset( $field_data['multiple'] ) && $field_data['multiple'] ) {
|
630 |
+
$multiple = ' multiple="multiple"';
|
631 |
+
}
|
632 |
+
|
633 |
+
$allow_clear = '';
|
634 |
+
|
635 |
+
if ( isset( $field_data['allow_clear'] ) && $field_data['allow_clear'] ) {
|
636 |
+
$allow_clear = ' data-allow_clear="allow_clear"';
|
637 |
+
}
|
638 |
+
|
639 |
+
$field_content = '<select
|
640 |
+
name="' . $field_data['name'] . '[]"
|
641 |
+
class="wcf-product-search" ' . $multiple . $allow_clear . '
|
642 |
+
data-placeholder="' . __( 'Search for a product…', 'cartflows' ) . '"
|
643 |
+
data-action="woocommerce_json_search_products_and_variations">';
|
644 |
+
|
645 |
+
if ( is_array( $value ) && ! empty( $value ) ) {
|
646 |
+
|
647 |
+
foreach ( $value as $data_key => $product_id ) {
|
648 |
+
|
649 |
+
$product = wc_get_product( $product_id );
|
650 |
+
|
651 |
+
// posts.
|
652 |
+
if ( ! empty( $product ) ) {
|
653 |
+
$post_title = $product->get_name() . ' (#' . $product_id . ')';
|
654 |
+
|
655 |
+
$field_content .= '<option value="' . $product_id . '" selected="selected" >' . $post_title . '</option>';
|
656 |
+
}
|
657 |
+
}
|
658 |
+
}
|
659 |
+
$field_content .= '</select>';
|
660 |
+
|
661 |
+
return $this->get_field( $field_data, $field_content );
|
662 |
+
}
|
663 |
+
|
664 |
+
/**
|
665 |
+
* Coupon selection field.
|
666 |
+
*
|
667 |
+
* @param array $field_data Field data.
|
668 |
+
*
|
669 |
+
* @return string field.
|
670 |
+
*/
|
671 |
+
public function get_coupon_selection_field( $field_data ) {
|
672 |
+
|
673 |
+
$value = $field_data['value'];
|
674 |
+
|
675 |
+
$multiple = '';
|
676 |
+
|
677 |
+
if ( isset( $field_data['multiple'] ) && $field_data['multiple'] ) {
|
678 |
+
$multiple = ' multiple="multiple"';
|
679 |
+
}
|
680 |
+
|
681 |
+
$allow_clear = '';
|
682 |
+
|
683 |
+
if ( isset( $field_data['allow_clear'] ) && $field_data['allow_clear'] ) {
|
684 |
+
$allow_clear = ' data-allow_clear="allow_clear"';
|
685 |
+
}
|
686 |
+
|
687 |
+
$field_content = '<select
|
688 |
+
name="' . $field_data['name'] . '[]"
|
689 |
+
class="wc-coupon-search wcf-coupon-search" ' . $multiple . $allow_clear . '
|
690 |
+
data-placeholder="' . __( 'Search for a coupon…', 'cartflows' ) . '"
|
691 |
+
data-action="wcf_json_search_coupons">';
|
692 |
+
|
693 |
+
if ( is_array( $value ) && ! empty( $value ) ) {
|
694 |
+
|
695 |
+
$all_discount_types = wc_get_coupon_types();
|
696 |
+
|
697 |
+
foreach ( $value as $coupon_title ) {
|
698 |
+
|
699 |
+
$coupon = new WC_Coupon( $coupon_title );
|
700 |
+
|
701 |
+
$discount_type = $coupon->get_discount_type();
|
702 |
+
|
703 |
+
if ( isset( $discount_type ) && $discount_type ) {
|
704 |
+
$discount_type = ' ( Type: ' . $all_discount_types[ $discount_type ] . ' )';
|
705 |
+
}
|
706 |
+
|
707 |
+
$field_content .= '<option value="' . $coupon_title . '" selected="selected">' . $coupon_title . $discount_type . '</option>';
|
708 |
+
}
|
709 |
+
}
|
710 |
+
|
711 |
+
$field_content .= '</select>';
|
712 |
+
|
713 |
+
return $this->get_field( $field_data, $field_content );
|
714 |
+
}
|
715 |
+
|
716 |
+
/**
|
717 |
+
* Page selction field.
|
718 |
+
*
|
719 |
+
* @param array $field_data Field data.
|
720 |
+
*
|
721 |
+
* @return string field.
|
722 |
+
*/
|
723 |
+
public function get_page_selection_field( $field_data ) {
|
724 |
+
|
725 |
+
$value = $field_data['value'];
|
726 |
+
|
727 |
+
$multiple = '';
|
728 |
+
|
729 |
+
if ( isset( $field_data['multiple'] ) && $field_data['multiple'] ) {
|
730 |
+
$multiple = 'multiple="multiple"';
|
731 |
+
}
|
732 |
+
|
733 |
+
$field_content = '<select
|
734 |
+
name="' . $field_data['name'] . '[]"
|
735 |
+
class="wcf-search-pages" ' . $multiple . '"
|
736 |
+
data-action="wcf_json_search_pages">';
|
737 |
+
|
738 |
+
if ( is_array( $value ) && ! empty( $value ) ) {
|
739 |
+
|
740 |
+
foreach ( $value as $data_key => $data_value ) {
|
741 |
+
|
742 |
+
$field_content .= '<option value="' . $data_value . '">' . get_the_title( $data_value ) . '</option>';
|
743 |
+
}
|
744 |
+
}
|
745 |
+
|
746 |
+
$field_content .= '</select>';
|
747 |
+
|
748 |
+
return $this->get_field( $field_data, $field_content );
|
749 |
+
}
|
750 |
+
|
751 |
+
/**
|
752 |
+
* Get section field.
|
753 |
+
*
|
754 |
+
* @param array $field_data Field data.
|
755 |
+
*
|
756 |
+
* @return string field.
|
757 |
+
*/
|
758 |
+
public function get_section( $field_data ) {
|
759 |
+
$field_html = '<div class="wcf-field-row wcf-field-section">';
|
760 |
+
$field_html .= '<div class="wcf-field-section-heading" colspan="2">';
|
761 |
+
$field_html .= '<label>' . esc_html( $field_data['label'] ) . '</label>';
|
762 |
+
|
763 |
+
if ( isset( $field_data['help'] ) ) {
|
764 |
+
$field_html .= '<i class="wcf-field-heading-help dashicons dashicons-editor-help" title="' . esc_attr( $field_data['help'] ) . '"></i>';
|
765 |
+
}
|
766 |
+
$field_html .= '</div>';
|
767 |
+
$field_html .= '</div>';
|
768 |
+
return $field_html;
|
769 |
+
}
|
770 |
+
|
771 |
+
/**
|
772 |
+
* Description field.
|
773 |
+
*
|
774 |
+
* @param array $field_data Field data.
|
775 |
+
*
|
776 |
+
* @return string field.
|
777 |
+
*/
|
778 |
+
public function get_description_field( $field_data ) {
|
779 |
+
|
780 |
+
$field_html = '<div class="wcf-field-row wcf-field-desc ' . $field_data['name'] . '">';
|
781 |
+
$field_html .= '<div class="wcf-field-desc-content">';
|
782 |
+
$field_html .= $field_data['content'];
|
783 |
+
$field_html .= '</div>';
|
784 |
+
$field_html .= '</div>';
|
785 |
+
|
786 |
+
return $field_html;
|
787 |
+
}
|
788 |
+
|
789 |
+
/**
|
790 |
+
* Product selection repeater field.
|
791 |
+
*
|
792 |
+
* @param array $field_data Field data.
|
793 |
+
*
|
794 |
+
* @return string field.
|
795 |
+
*/
|
796 |
+
public function get_product_selection_repeater( $field_data ) {
|
797 |
+
|
798 |
+
return $this->get_meta_field_template(
|
799 |
+
'get-product-selection-repeater.php',
|
800 |
+
$field_data
|
801 |
+
);
|
802 |
+
}
|
803 |
+
|
804 |
+
/**
|
805 |
+
* Generate product repeater html.
|
806 |
+
*
|
807 |
+
* @param string $id ID.
|
808 |
+
* @param string $options Options.
|
809 |
+
* @param array $selected_data Discount_data.
|
810 |
+
*
|
811 |
+
* @return string field.
|
812 |
+
*/
|
813 |
+
public function generate_product_repeater_html( $id, $options = '', $selected_data = '' ) {
|
814 |
+
|
815 |
+
ob_start();
|
816 |
+
|
817 |
+
include CARTFLOWS_DIR . 'includes/meta-fields/generate-product-repeater.php';
|
818 |
+
|
819 |
+
return ob_get_clean();
|
820 |
+
}
|
821 |
+
|
822 |
+
/**
|
823 |
+
* Image field.
|
824 |
+
*
|
825 |
+
* @param array $field_data Field data.
|
826 |
+
*
|
827 |
+
* @return string field.
|
828 |
+
*/
|
829 |
+
public function get_image_field( $field_data ) {
|
830 |
+
|
831 |
+
global $post;
|
832 |
+
$value = $field_data['value'];
|
833 |
+
|
834 |
+
$attr = '';
|
835 |
+
|
836 |
+
if ( isset( $field_data['attr'] ) && is_array( $field_data['attr'] ) ) {
|
837 |
+
|
838 |
+
foreach ( $field_data['attr'] as $attr_key => $attr_value ) {
|
839 |
+
$attr .= ' ' . $attr_key . '="' . $attr_value . '"';
|
840 |
+
}
|
841 |
+
}
|
842 |
+
|
843 |
+
$display_preview_box = ( isset( $value ) && '' != $value ) ? 'display:block;' : 'display:none';
|
844 |
+
|
845 |
+
$field_content = '<div id="wcf-image-preview" style="' . $display_preview_box . '">';
|
846 |
+
|
847 |
+
if ( isset( $value ) ) {
|
848 |
+
|
849 |
+
$field_content .= '<img src="' . $field_data['value'] . '" class="saved-image" name="' . $field_data['name'] . '" width="150">';
|
850 |
+
}
|
851 |
+
|
852 |
+
$field_content .= '</div>';
|
853 |
+
|
854 |
+
$image_data = htmlentities( serialize( get_post_meta( $post->ID, $field_data['name'] . '-obj' ) ) ); // phpcs:ignore
|
855 |
+
|
856 |
+
$field_content .= '<input type="hidden" id="' . $field_data['name'] . '" class="wcf-image" name="' . $field_data['name'] . '" value="' . $value . '">'; // phpcs:ignore
|
857 |
+
|
858 |
+
$field_content .= '<input type="hidden" id="' . $field_data['name'] . '-obj' . '" class="wcf-image-obj" name="' . $field_data['name'] . '-obj' . '" value="' . $image_data . '">'; // phpcs:ignore
|
859 |
+
|
860 |
+
$field_content .= '<button type="button" ' . $attr . ' class="wcf-select-image button-secondary">Select Image</button>';
|
861 |
+
|
862 |
+
$display_remove_button = ( isset( $value ) && '' != $value ) ? 'display:inline-block; margin-left: 5px;' : 'display:none';
|
863 |
+
|
864 |
+
$field_content .= '<button type="button" class="wcf-remove-image button-secondary" style="' . $display_remove_button . '">Remove Image</button>';
|
865 |
+
|
866 |
+
return $this->get_field( $field_data, $field_content );
|
867 |
+
}
|
868 |
+
|
869 |
+
/**
|
870 |
+
* Localize variables in admin
|
871 |
+
*
|
872 |
+
* @param array $vars variables.
|
873 |
+
*/
|
874 |
+
public function localize_vars( $vars ) {
|
875 |
+
|
876 |
+
$ajax_actions = array(
|
877 |
+
'wcf_json_search_pages',
|
878 |
+
'wcf_json_search_coupons',
|
879 |
+
);
|
880 |
+
|
881 |
+
foreach ( $ajax_actions as $action ) {
|
882 |
+
|
883 |
+
$vars[ $action . '_nonce' ] = wp_create_nonce( str_replace( '_', '-', $action ) );
|
884 |
+
}
|
885 |
+
|
886 |
+
/* Add product from iframe */
|
887 |
+
$product_src = esc_url_raw(
|
888 |
+
add_query_arg(
|
889 |
+
array(
|
890 |
+
'post_type' => 'product',
|
891 |
+
'wcf-woo-iframe' => 'true',
|
892 |
+
),
|
893 |
+
admin_url( 'post-new.php' )
|
894 |
+
)
|
895 |
+
);
|
896 |
+
|
897 |
+
$vars['create_product_src'] = $product_src;
|
898 |
+
/* Add product from iframe End */
|
899 |
+
|
900 |
+
return $vars;
|
901 |
+
}
|
902 |
+
|
903 |
+
/**
|
904 |
+
* Get meta field template.
|
905 |
+
*
|
906 |
+
* @param string $template file name.
|
907 |
+
* @param array $field_data Field data.
|
908 |
+
*
|
909 |
+
* @return string.
|
910 |
+
*/
|
911 |
+
public function get_meta_field_template( $template, $field_data ) {
|
912 |
+
|
913 |
+
ob_start();
|
914 |
+
|
915 |
+
include CARTFLOWS_DIR . 'includes/meta-fields/' . $template;
|
916 |
+
|
917 |
+
return ob_get_clean();
|
918 |
+
}
|
919 |
+
}
|
classes/class-cartflows-utils.php
CHANGED
@@ -1,461 +1,591 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Utils.
|
4 |
-
*
|
5 |
-
* @package CARTFLOWS
|
6 |
-
*/
|
7 |
-
|
8 |
-
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
-
exit; // Exit if accessed directly.
|
10 |
-
}
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Class Cartflows_Utils.
|
14 |
-
*/
|
15 |
-
class Cartflows_Utils {
|
16 |
-
|
17 |
-
/**
|
18 |
-
* Member Variable
|
19 |
-
*
|
20 |
-
* @var instance
|
21 |
-
*/
|
22 |
-
private static $instance;
|
23 |
-
|
24 |
-
/**
|
25 |
-
*
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
*
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
*
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
*
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
*
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
|
141 |
-
|
142 |
-
|
143 |
-
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
*
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
|
180 |
-
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
-
|
192 |
-
|
193 |
-
|
194 |
-
|
195 |
-
|
196 |
-
|
197 |
-
|
198 |
-
|
199 |
-
|
200 |
-
|
201 |
-
|
202 |
-
|
203 |
-
|
204 |
-
|
205 |
-
|
206 |
-
|
207 |
-
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
|
229 |
-
|
230 |
-
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
|
236 |
-
|
237 |
-
|
238 |
-
|
239 |
-
|
240 |
-
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
|
251 |
-
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
|
257 |
-
|
258 |
-
|
259 |
-
|
260 |
-
|
261 |
-
|
262 |
-
|
263 |
-
|
264 |
-
|
265 |
-
|
266 |
-
|
267 |
-
|
268 |
-
|
269 |
-
|
270 |
-
|
271 |
-
|
272 |
-
|
273 |
-
|
274 |
-
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
|
280 |
-
|
281 |
-
|
282 |
-
|
283 |
-
|
284 |
-
|
285 |
-
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
-
|
290 |
-
|
291 |
-
|
292 |
-
|
293 |
-
|
294 |
-
|
295 |
-
|
296 |
-
|
297 |
-
|
298 |
-
|
299 |
-
|
300 |
-
|
301 |
-
|
302 |
-
|
303 |
-
|
304 |
-
|
305 |
-
|
306 |
-
|
307 |
-
|
308 |
-
|
309 |
-
|
310 |
-
|
311 |
-
|
312 |
-
|
313 |
-
|
314 |
-
|
315 |
-
|
316 |
-
|
317 |
-
|
318 |
-
|
319 |
-
|
320 |
-
|
321 |
-
|
322 |
-
|
323 |
-
|
324 |
-
|
325 |
-
|
326 |
-
|
327 |
-
|
328 |
-
|
329 |
-
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
338 |
-
|
339 |
-
|
340 |
-
|
341 |
-
|
342 |
-
|
343 |
-
|
344 |
-
|
345 |
-
|
346 |
-
|
347 |
-
|
348 |
-
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
|
354 |
-
|
355 |
-
|
356 |
-
|
357 |
-
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
372 |
-
|
373 |
-
|
374 |
-
|
375 |
-
|
376 |
-
|
377 |
-
|
378 |
-
|
379 |
-
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
393 |
-
|
394 |
-
$
|
395 |
-
|
396 |
-
|
397 |
-
'
|
398 |
-
'
|
399 |
-
|
400 |
-
|
401 |
-
|
402 |
-
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
|
411 |
-
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
|
418 |
-
|
419 |
-
|
420 |
-
|
421 |
-
|
422 |
-
|
423 |
-
|
424 |
-
|
425 |
-
|
426 |
-
|
427 |
-
|
428 |
-
|
429 |
-
|
430 |
-
|
431 |
-
|
432 |
-
|
433 |
-
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
|
444 |
-
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
|
455 |
-
|
456 |
-
|
457 |
-
|
458 |
-
|
459 |
-
|
460 |
-
|
461 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Utils.
|
4 |
+
*
|
5 |
+
* @package CARTFLOWS
|
6 |
+
*/
|
7 |
+
|
8 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
+
exit; // Exit if accessed directly.
|
10 |
+
}
|
11 |
+
|
12 |
+
/**
|
13 |
+
* Class Cartflows_Utils.
|
14 |
+
*/
|
15 |
+
class Cartflows_Utils {
|
16 |
+
|
17 |
+
/**
|
18 |
+
* Member Variable
|
19 |
+
*
|
20 |
+
* @var instance
|
21 |
+
*/
|
22 |
+
private static $instance;
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Member Variable
|
26 |
+
*
|
27 |
+
* @var checkout_products
|
28 |
+
*/
|
29 |
+
public $checkout_products = array();
|
30 |
+
|
31 |
+
|
32 |
+
/**
|
33 |
+
* Initiator
|
34 |
+
*/
|
35 |
+
public static function get_instance() {
|
36 |
+
if ( ! isset( self::$instance ) ) {
|
37 |
+
self::$instance = new self();
|
38 |
+
}
|
39 |
+
return self::$instance;
|
40 |
+
}
|
41 |
+
|
42 |
+
/**
|
43 |
+
* Constructor
|
44 |
+
*/
|
45 |
+
public function __construct() {
|
46 |
+
}
|
47 |
+
|
48 |
+
/**
|
49 |
+
* Get current post type
|
50 |
+
*
|
51 |
+
* @param string $post_type post type.
|
52 |
+
* @return string
|
53 |
+
*/
|
54 |
+
public function current_post_type( $post_type = '' ) {
|
55 |
+
|
56 |
+
if ( '' === $post_type ) {
|
57 |
+
$post_type = get_post_type();
|
58 |
+
}
|
59 |
+
|
60 |
+
return $post_type;
|
61 |
+
}
|
62 |
+
|
63 |
+
/**
|
64 |
+
* Check if post type is of step.
|
65 |
+
*
|
66 |
+
* @param string $post_type post type.
|
67 |
+
* @return bool
|
68 |
+
*/
|
69 |
+
public function is_step_post_type( $post_type = '' ) {
|
70 |
+
|
71 |
+
if ( $this->get_step_post_type() === $this->current_post_type( $post_type ) ) {
|
72 |
+
|
73 |
+
return true;
|
74 |
+
}
|
75 |
+
|
76 |
+
return false;
|
77 |
+
}
|
78 |
+
|
79 |
+
/**
|
80 |
+
* Check if post type is of flow.
|
81 |
+
*
|
82 |
+
* @param string $post_type post type.
|
83 |
+
* @return bool
|
84 |
+
*/
|
85 |
+
public function is_flow_post_type( $post_type = '' ) {
|
86 |
+
|
87 |
+
if ( $this->get_flow_post_type() === $this->current_post_type( $post_type ) ) {
|
88 |
+
|
89 |
+
return true;
|
90 |
+
}
|
91 |
+
|
92 |
+
return false;
|
93 |
+
}
|
94 |
+
|
95 |
+
/**
|
96 |
+
* Get post type of step.
|
97 |
+
*
|
98 |
+
* @return string
|
99 |
+
*/
|
100 |
+
public function get_step_post_type() {
|
101 |
+
|
102 |
+
return CARTFLOWS_STEP_POST_TYPE;
|
103 |
+
}
|
104 |
+
|
105 |
+
/**
|
106 |
+
* Get post type of flow.
|
107 |
+
*
|
108 |
+
* @return string
|
109 |
+
*/
|
110 |
+
public function get_flow_post_type() {
|
111 |
+
|
112 |
+
return CARTFLOWS_FLOW_POST_TYPE;
|
113 |
+
}
|
114 |
+
|
115 |
+
/**
|
116 |
+
* Get flow id
|
117 |
+
*
|
118 |
+
* @return int
|
119 |
+
*/
|
120 |
+
public function get_flow_id() {
|
121 |
+
|
122 |
+
global $post;
|
123 |
+
|
124 |
+
return get_post_meta( $post->ID, 'wcf-flow-id', true );
|
125 |
+
}
|
126 |
+
|
127 |
+
/**
|
128 |
+
* Get flow id by step
|
129 |
+
*
|
130 |
+
* @param int $step_id step ID.
|
131 |
+
* @return int
|
132 |
+
*/
|
133 |
+
public function get_flow_id_from_step_id( $step_id ) {
|
134 |
+
|
135 |
+
return get_post_meta( $step_id, 'wcf-flow-id', true );
|
136 |
+
}
|
137 |
+
|
138 |
+
/**
|
139 |
+
* Get flow steps by id
|
140 |
+
*
|
141 |
+
* @param int $flow_id flow ID.
|
142 |
+
* @return int
|
143 |
+
*/
|
144 |
+
public function get_flow_steps( $flow_id ) {
|
145 |
+
|
146 |
+
$steps = get_post_meta( $flow_id, 'wcf-steps', true );
|
147 |
+
|
148 |
+
if ( is_array( $steps ) && ! empty( $steps ) ) {
|
149 |
+
return $steps;
|
150 |
+
}
|
151 |
+
|
152 |
+
return false;
|
153 |
+
}
|
154 |
+
|
155 |
+
/**
|
156 |
+
* Get template type of step
|
157 |
+
*
|
158 |
+
* @param int $step_id step ID.
|
159 |
+
* @return int
|
160 |
+
*/
|
161 |
+
public function get_step_type( $step_id ) {
|
162 |
+
|
163 |
+
return get_post_meta( $step_id, 'wcf-step-type', true );
|
164 |
+
}
|
165 |
+
|
166 |
+
/**
|
167 |
+
* Get next id for step
|
168 |
+
*
|
169 |
+
* @param int $flow_id flow ID.
|
170 |
+
* @param int $step_id step ID.
|
171 |
+
* @return bool
|
172 |
+
*/
|
173 |
+
public function get_next_step_id( $flow_id, $step_id ) {
|
174 |
+
|
175 |
+
$steps = $this->get_flow_steps( $flow_id );
|
176 |
+
$step_id = intval( $step_id );
|
177 |
+
|
178 |
+
if ( ! $steps ) {
|
179 |
+
return false;
|
180 |
+
}
|
181 |
+
|
182 |
+
foreach ( $steps as $i => $step ) {
|
183 |
+
|
184 |
+
if ( intval( $step['id'] ) === $step_id ) {
|
185 |
+
|
186 |
+
$next_i = $i + 1;
|
187 |
+
|
188 |
+
if ( isset( $steps[ $next_i ] ) ) {
|
189 |
+
|
190 |
+
$navigation = $steps[ $next_i ];
|
191 |
+
|
192 |
+
return intval( $navigation['id'] );
|
193 |
+
}
|
194 |
+
|
195 |
+
break;
|
196 |
+
}
|
197 |
+
}
|
198 |
+
|
199 |
+
return false;
|
200 |
+
}
|
201 |
+
|
202 |
+
/**
|
203 |
+
* Get next id for step
|
204 |
+
*
|
205 |
+
* @param int $order_id order ID.
|
206 |
+
* @return int
|
207 |
+
*/
|
208 |
+
public function get_flow_id_from_order( $order_id ) {
|
209 |
+
|
210 |
+
$flow_id = get_post_meta( $order_id, '_wcf_flow_id', true );
|
211 |
+
|
212 |
+
return intval( $flow_id );
|
213 |
+
}
|
214 |
+
|
215 |
+
/**
|
216 |
+
* Get checkout id for order
|
217 |
+
*
|
218 |
+
* @param int $order_id order ID.
|
219 |
+
* @return int
|
220 |
+
*/
|
221 |
+
public function get_checkout_id_from_order( $order_id ) {
|
222 |
+
|
223 |
+
$checkout_id = get_post_meta( $order_id, '_wcf_checkout_id', true );
|
224 |
+
|
225 |
+
return intval( $checkout_id );
|
226 |
+
}
|
227 |
+
|
228 |
+
/**
|
229 |
+
* We are using this function mostly in ajax on checkout page
|
230 |
+
*
|
231 |
+
* @return bool
|
232 |
+
*/
|
233 |
+
public function get_checkout_id_from_post_data() {
|
234 |
+
|
235 |
+
if ( isset( $_POST['_wcf_checkout_id'] ) ) { //phpcs:ignore
|
236 |
+
|
237 |
+
$checkout_id = filter_var( wp_unslash( $_POST['_wcf_checkout_id'] ), FILTER_SANITIZE_NUMBER_INT ); //phpcs:ignore
|
238 |
+
|
239 |
+
return intval( $checkout_id );
|
240 |
+
}
|
241 |
+
|
242 |
+
return false;
|
243 |
+
}
|
244 |
+
|
245 |
+
/**
|
246 |
+
* We are using this function mostly in ajax on checkout page
|
247 |
+
*
|
248 |
+
* @return bool
|
249 |
+
*/
|
250 |
+
public function get_flow_id_from_post_data() {
|
251 |
+
|
252 |
+
if ( isset( $_POST['_wcf_flow_id'] ) ) { //phpcs:ignore
|
253 |
+
|
254 |
+
$flow_id = filter_var( wp_unslash( $_POST['_wcf_flow_id'] ), FILTER_SANITIZE_NUMBER_INT ); //phpcs:ignore
|
255 |
+
|
256 |
+
return intval( $flow_id );
|
257 |
+
}
|
258 |
+
|
259 |
+
return false;
|
260 |
+
}
|
261 |
+
|
262 |
+
/**
|
263 |
+
* Get optin id for order
|
264 |
+
*
|
265 |
+
* @param int $order_id order ID.
|
266 |
+
* @return int
|
267 |
+
*/
|
268 |
+
public function get_optin_id_from_order( $order_id ) {
|
269 |
+
|
270 |
+
$optin_id = get_post_meta( $order_id, '_wcf_optin_id', true );
|
271 |
+
|
272 |
+
return intval( $optin_id );
|
273 |
+
}
|
274 |
+
|
275 |
+
/**
|
276 |
+
* We are using this function mostly in ajax on checkout page
|
277 |
+
*
|
278 |
+
* @return bool
|
279 |
+
*/
|
280 |
+
public function get_optin_id_from_post_data() {
|
281 |
+
|
282 |
+
if ( isset( $_POST['_wcf_optin_id'] ) ) { //phpcs:ignore
|
283 |
+
|
284 |
+
$optin_id = filter_var( wp_unslash( $_POST['_wcf_optin_id'] ), FILTER_SANITIZE_NUMBER_INT ); //phpcs:ignore
|
285 |
+
|
286 |
+
return intval( $optin_id );
|
287 |
+
}
|
288 |
+
|
289 |
+
return false;
|
290 |
+
}
|
291 |
+
|
292 |
+
/**
|
293 |
+
* Check for thank you page
|
294 |
+
*
|
295 |
+
* @param int $step_id step ID.
|
296 |
+
* @return bool
|
297 |
+
*/
|
298 |
+
public function check_is_thankyou_page( $step_id ) {
|
299 |
+
|
300 |
+
$step_type = $this->get_step_type( $step_id );
|
301 |
+
|
302 |
+
if ( 'thankyou' === $step_type ) {
|
303 |
+
|
304 |
+
return true;
|
305 |
+
}
|
306 |
+
|
307 |
+
return false;
|
308 |
+
}
|
309 |
+
|
310 |
+
/**
|
311 |
+
* Check for offer page
|
312 |
+
*
|
313 |
+
* @param int $step_id step ID.
|
314 |
+
* @return bool
|
315 |
+
*/
|
316 |
+
public function check_is_offer_page( $step_id ) {
|
317 |
+
|
318 |
+
$step_type = $this->get_step_type( $step_id );
|
319 |
+
|
320 |
+
if ( 'upsell' === $step_type || 'downsell' === $step_type ) {
|
321 |
+
|
322 |
+
return true;
|
323 |
+
}
|
324 |
+
|
325 |
+
return false;
|
326 |
+
}
|
327 |
+
|
328 |
+
/**
|
329 |
+
* Check if loaded page requires woo.
|
330 |
+
*
|
331 |
+
* @return bool
|
332 |
+
*/
|
333 |
+
public function check_is_woo_required_page() {
|
334 |
+
|
335 |
+
global $post;
|
336 |
+
$step_id = $post->ID;
|
337 |
+
$woo_not_required_type = array( 'landing' );
|
338 |
+
$step_type = $this->get_step_type( $step_id );
|
339 |
+
return ( ! in_array( $step_type, $woo_not_required_type, true ) );
|
340 |
+
}
|
341 |
+
|
342 |
+
/**
|
343 |
+
* Define constant for cache
|
344 |
+
*
|
345 |
+
* @return void
|
346 |
+
*/
|
347 |
+
public function do_not_cache() {
|
348 |
+
|
349 |
+
global $post;
|
350 |
+
|
351 |
+
if ( ! apply_filters( 'cartflows_do_not_cache_step', true, $post->ID ) ) {
|
352 |
+
return;
|
353 |
+
}
|
354 |
+
|
355 |
+
wcf_maybe_define_constant( 'DONOTCACHEPAGE', true );
|
356 |
+
wcf_maybe_define_constant( 'DONOTCACHEOBJECT', true );
|
357 |
+
wcf_maybe_define_constant( 'DONOTCACHEDB', true );
|
358 |
+
|
359 |
+
nocache_headers();
|
360 |
+
}
|
361 |
+
|
362 |
+
/**
|
363 |
+
* Get linking url
|
364 |
+
*
|
365 |
+
* @param array $args query args.
|
366 |
+
* @return string
|
367 |
+
*/
|
368 |
+
public function get_linking_url( $args = array() ) {
|
369 |
+
|
370 |
+
$url = get_home_url();
|
371 |
+
|
372 |
+
$url = add_query_arg( $args, $url );
|
373 |
+
|
374 |
+
return $url;
|
375 |
+
}
|
376 |
+
|
377 |
+
/**
|
378 |
+
* Get assets urls
|
379 |
+
*
|
380 |
+
* @return array
|
381 |
+
* @since 1.1.6
|
382 |
+
*/
|
383 |
+
public function get_assets_path() {
|
384 |
+
|
385 |
+
$rtl = '';
|
386 |
+
|
387 |
+
if ( is_rtl() ) {
|
388 |
+
$rtl = '-rtl';
|
389 |
+
}
|
390 |
+
|
391 |
+
$file_prefix = '';
|
392 |
+
$dir_name = '';
|
393 |
+
|
394 |
+
$is_min = apply_filters( 'cartflows_load_min_assets', false );
|
395 |
+
|
396 |
+
if ( $is_min ) {
|
397 |
+
$file_prefix = '.min';
|
398 |
+
$dir_name = 'min-';
|
399 |
+
}
|
400 |
+
|
401 |
+
$js_gen_path = CARTFLOWS_URL . 'assets/' . $dir_name . 'js/';
|
402 |
+
$css_gen_path = CARTFLOWS_URL . 'assets/' . $dir_name . 'css/';
|
403 |
+
|
404 |
+
return array(
|
405 |
+
'css' => $css_gen_path,
|
406 |
+
'js' => $js_gen_path,
|
407 |
+
'file_prefix' => $file_prefix,
|
408 |
+
'rtl' => $rtl,
|
409 |
+
);
|
410 |
+
}
|
411 |
+
|
412 |
+
/**
|
413 |
+
* Get assets css url
|
414 |
+
*
|
415 |
+
* @param string $file file name.
|
416 |
+
* @return string
|
417 |
+
* @since 1.1.6
|
418 |
+
*/
|
419 |
+
public function get_css_url( $file ) {
|
420 |
+
|
421 |
+
$assets_vars = wcf()->assets_vars;
|
422 |
+
|
423 |
+
$url = $assets_vars['css'] . $file . $assets_vars['rtl'] . $assets_vars['file_prefix'] . '.css';
|
424 |
+
|
425 |
+
return $url;
|
426 |
+
}
|
427 |
+
|
428 |
+
/**
|
429 |
+
* Get assets js url
|
430 |
+
*
|
431 |
+
* @param string $file file name.
|
432 |
+
* @return string
|
433 |
+
* @since 1.1.6
|
434 |
+
*/
|
435 |
+
public function get_js_url( $file ) {
|
436 |
+
|
437 |
+
$assets_vars = wcf()->assets_vars;
|
438 |
+
|
439 |
+
$url = $assets_vars['js'] . $file . $assets_vars['file_prefix'] . '.js';
|
440 |
+
|
441 |
+
return $url;
|
442 |
+
}
|
443 |
+
|
444 |
+
/**
|
445 |
+
* Get unique id.
|
446 |
+
*
|
447 |
+
* @param int $length Length.
|
448 |
+
*
|
449 |
+
* @return string
|
450 |
+
*/
|
451 |
+
public function get_unique_id( $length = 8 ) {
|
452 |
+
|
453 |
+
return substr( md5( microtime() ), 0, $length );
|
454 |
+
}
|
455 |
+
|
456 |
+
/**
|
457 |
+
* Get selected checkout products and data
|
458 |
+
*
|
459 |
+
* @param int $checkout_id Checkout id..
|
460 |
+
* @param array $saved_products Saved product.
|
461 |
+
*
|
462 |
+
* @return array
|
463 |
+
*/
|
464 |
+
public function get_selected_checkout_products( $checkout_id = '', $saved_products = array() ) {
|
465 |
+
|
466 |
+
if ( empty( $checkout_id ) ) {
|
467 |
+
|
468 |
+
global $post;
|
469 |
+
|
470 |
+
$checkout_id = $post->ID;
|
471 |
+
}
|
472 |
+
|
473 |
+
if ( ! isset( $this->checkout_products[ $checkout_id ] ) ) {
|
474 |
+
|
475 |
+
if ( ! empty( $saved_products ) ) {
|
476 |
+
|
477 |
+
$products = $saved_products;
|
478 |
+
} else {
|
479 |
+
|
480 |
+
$products = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-checkout-products' );
|
481 |
+
}
|
482 |
+
|
483 |
+
$verify_url_data = false;
|
484 |
+
$default_add_to_cart = false;
|
485 |
+
$default_ids = array();
|
486 |
+
$default_add_to_cart = true;
|
487 |
+
|
488 |
+
if ( isset( $_GET['wcf-default'] ) ) { //phpcs:ignore
|
489 |
+
//phpcs:ignore WordPress.Security.NonceVerification.Recommended
|
490 |
+
$default_sequence = sanitize_text_field( wp_unslash( $_GET['wcf-default'] ) );
|
491 |
+
$default_ids = array_map( 'intval', explode( ',', $default_sequence ) );
|
492 |
+
$verify_url_data = true;
|
493 |
+
}
|
494 |
+
|
495 |
+
if ( is_array( $products ) ) {
|
496 |
+
|
497 |
+
foreach ( $products as $in => $data ) {
|
498 |
+
|
499 |
+
if ( $verify_url_data ) {
|
500 |
+
|
501 |
+
$default_add_to_cart = false;
|
502 |
+
$sequence = $in + 1;
|
503 |
+
|
504 |
+
if ( in_array( $sequence, $default_ids, true ) ) {
|
505 |
+
$default_add_to_cart = true;
|
506 |
+
}
|
507 |
+
}
|
508 |
+
|
509 |
+
$default_data = array(
|
510 |
+
'quantity' => 1,
|
511 |
+
'discount_type' => '',
|
512 |
+
'discount_value' => '',
|
513 |
+
'unique_id' => $this->get_unique_id(),
|
514 |
+
'add_to_cart' => $default_add_to_cart,
|
515 |
+
);
|
516 |
+
|
517 |
+
$products[ $in ] = wp_parse_args( $products[ $in ], $default_data );
|
518 |
+
}
|
519 |
+
}
|
520 |
+
|
521 |
+
$this->checkout_products[ $checkout_id ] = $products;
|
522 |
+
}
|
523 |
+
|
524 |
+
return $this->checkout_products[ $checkout_id ];
|
525 |
+
}
|
526 |
+
|
527 |
+
/**
|
528 |
+
* Get selected checkout products and data
|
529 |
+
*
|
530 |
+
* @param int $checkout_id Checkout id..
|
531 |
+
* @param array $products_data Saved product.
|
532 |
+
*
|
533 |
+
* @return array
|
534 |
+
*/
|
535 |
+
public function set_selcted_checkout_products( $checkout_id = '', $products_data = array() ) {
|
536 |
+
|
537 |
+
if ( empty( $checkout_id ) ) {
|
538 |
+
|
539 |
+
global $post;
|
540 |
+
|
541 |
+
$checkout_id = $post->ID;
|
542 |
+
}
|
543 |
+
|
544 |
+
if ( isset( $this->checkout_products[ $checkout_id ] ) ) {
|
545 |
+
|
546 |
+
$products = $this->checkout_products[ $checkout_id ];
|
547 |
+
} else {
|
548 |
+
$products = $this->get_selected_checkout_products( $checkout_id );
|
549 |
+
}
|
550 |
+
|
551 |
+
if ( is_array( $products ) && ! empty( $products_data ) ) {
|
552 |
+
|
553 |
+
foreach ( $products as $in => $data ) {
|
554 |
+
|
555 |
+
if ( isset( $products_data[ $in ] ) ) {
|
556 |
+
$products[ $in ] = wp_parse_args( $products_data[ $in ], $products[ $in ] );
|
557 |
+
}
|
558 |
+
}
|
559 |
+
}
|
560 |
+
|
561 |
+
$this->checkout_products[ $checkout_id ] = $products;
|
562 |
+
|
563 |
+
return $this->checkout_products[ $checkout_id ];
|
564 |
+
}
|
565 |
+
}
|
566 |
+
|
567 |
+
/**
|
568 |
+
* Get a specific property of an array without needing to check if that property exists.
|
569 |
+
*
|
570 |
+
* Provide a default value if you want to return a specific value if the property is not set.
|
571 |
+
*
|
572 |
+
* @param array $array Array from which the property's value should be retrieved.
|
573 |
+
* @param string $prop Name of the property to be retrieved.
|
574 |
+
* @param string $default Optional. Value that should be returned if the property is not set or empty. Defaults to null.
|
575 |
+
*
|
576 |
+
* @return null|string|mixed The value
|
577 |
+
*/
|
578 |
+
function wcf_get_prop( $array, $prop, $default = null ) {
|
579 |
+
|
580 |
+
if ( ! is_array( $array ) && ! ( is_object( $array ) && $array instanceof ArrayAccess ) ) {
|
581 |
+
return $default;
|
582 |
+
}
|
583 |
+
|
584 |
+
if ( isset( $array[ $prop ] ) ) {
|
585 |
+
$value = $array[ $prop ];
|
586 |
+
} else {
|
587 |
+
$value = '';
|
588 |
+
}
|
589 |
+
|
590 |
+
return empty( $value ) && null !== $default ? $default : $value;
|
591 |
+
}
|
includes/meta-fields/generate-product-repeater.php
ADDED
@@ -0,0 +1,99 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Generate product repeater.
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
$hide_advance = 'wcf-hide-advance';
|
9 |
+
|
10 |
+
if ( empty( $selected_data ) ) {
|
11 |
+
|
12 |
+
$selected_data = array(
|
13 |
+
'quantity' => 1,
|
14 |
+
'discount_type' => '',
|
15 |
+
'discount_value' => '',
|
16 |
+
'unique_id' => '',
|
17 |
+
);
|
18 |
+
}
|
19 |
+
|
20 |
+
?>
|
21 |
+
|
22 |
+
<div class="wcf-repeatable-row" data-key="<?php echo $id; ?>">
|
23 |
+
<div class="wcf_display_advance_fields wcf-repeater-fields-head-wrap">
|
24 |
+
<div class="wcf-repeatable-row-standard-fields">
|
25 |
+
<div class="wcf-checkout-products-dashicon dashicons dashicons-menu"></div>
|
26 |
+
|
27 |
+
<!-- Product Name -->
|
28 |
+
<div class="wcf-repeatable-fields wcf-sel-product">
|
29 |
+
<span class="wcf-repeatable-row-setting-field">
|
30 |
+
<select name="wcf-checkout-products[<?php echo $id; ?>][product]" class="wcf-product-search" data-allow_clear="allow_clear" data-placeholder="<?php echo __( 'Search for a product…', 'cartflows' ); ?>" data-action="woocommerce_json_search_products_and_variations"><?php echo $options; ?></select>
|
31 |
+
</span>
|
32 |
+
|
33 |
+
<span class="wcf-repeatable-row-actions">
|
34 |
+
<a class="wcf-remove-row wcf-repeatable-remove button" data-type="product">
|
35 |
+
<span class="dashicons dashicons-trash"></span>
|
36 |
+
<span class="wcf-repeatable-remove-button"><?php echo __( 'Remove', 'cartflows' ); ?></span>
|
37 |
+
</a>
|
38 |
+
</span>
|
39 |
+
</div>
|
40 |
+
|
41 |
+
<div class="wcf_toggle_advance_fields"><i class="dashicons dashicons-arrow-down"></i></div>
|
42 |
+
</div>
|
43 |
+
</div>
|
44 |
+
|
45 |
+
<div class="wcf-repeatable-row-advance-fields <?php echo $hide_advance; ?>">
|
46 |
+
|
47 |
+
<!-- Qty field. -->
|
48 |
+
<div class="wcf-repeatable-row-qty-field wcf-checkout-products-qty-<?php echo $id; ?>">
|
49 |
+
<div class="wcf-field-row">
|
50 |
+
<div class="wcf-field-row-heading">
|
51 |
+
<label><?php echo __( 'Product Quantity', 'cartflows' ); ?></label>
|
52 |
+
</div>
|
53 |
+
|
54 |
+
<div class="wcf-field-row-content wcf-field-row-advance-content">
|
55 |
+
<input type="number" class="input-text qty text" step="1" min="1" max="" name="wcf-checkout-products[<?php echo $id; ?>][quantity]" value="<?php echo $selected_data['quantity']; ?>" title="Qty" inputmode="numeric">
|
56 |
+
</div>
|
57 |
+
</div>
|
58 |
+
</div>
|
59 |
+
<!-- Qty field end -->
|
60 |
+
|
61 |
+
<!-- Type field. -->
|
62 |
+
<div class="wcf-repeatable-discount-type-field">
|
63 |
+
<div class="wcf-field-row">
|
64 |
+
<div class="wcf-field-row-heading">
|
65 |
+
<label><?php echo __( 'Discount Type', 'cartflows' ); ?></label>
|
66 |
+
</div>
|
67 |
+
|
68 |
+
<div class="wcf-field-row-content wcf-field-row-advance-content">
|
69 |
+
<select name="wcf-checkout-products[<?php echo $id; ?>][discount_type]" data-allow_clear="allow_clear" data-placeholder="<?php echo __( 'Select Discount Type', 'cartflows' ); ?>">
|
70 |
+
<option value="" <?php selected( $selected_data['discount_type'], '', true ); ?>><?php echo __( 'Original', 'cartflows' ); ?></option>
|
71 |
+
<option value="discount_percent" <?php selected( $selected_data['discount_type'], 'discount_percent', true ); ?>><?php echo __( 'Percentage', 'cartflows' ); ?></option>
|
72 |
+
<option value="discount_price" <?php selected( $selected_data['discount_type'], 'discount_price', true ); ?>><?php echo __( 'Price', 'cartflows' ); ?></option>
|
73 |
+
</select>
|
74 |
+
</div>
|
75 |
+
</div>
|
76 |
+
</div>
|
77 |
+
<!-- Type field end -->
|
78 |
+
|
79 |
+
<!-- Discount field -->
|
80 |
+
<div class="wcf-repeatable-row-discount-field <?php echo $hide_advance; ?> wcf-checkout-products-discount-<?php echo $id; ?>">
|
81 |
+
<div class="wcf-field-row">
|
82 |
+
<div class="wcf-field-row-heading">
|
83 |
+
<label><?php echo __( 'Discount Value', 'cartflows' ); ?></label>
|
84 |
+
<i class="wcf-field-heading-help dashicons dashicons-editor-help"></i>
|
85 |
+
<span class="wcf-tooltip-text"><?php echo __( 'Discount value will apply for each quantity of product.', 'cartflows' ); ?></span>
|
86 |
+
</div>
|
87 |
+
<div class="wcf-field-row-content wcf-field-row-advance-content">
|
88 |
+
<input type="text" class="input-text text" name="wcf-checkout-products[<?php echo $id; ?>][discount_value]" value="<?php echo $selected_data['discount_value']; ?>" title="" inputmode="numeric">
|
89 |
+
</div>
|
90 |
+
</div>
|
91 |
+
</div>
|
92 |
+
|
93 |
+
<div class="wcf-repeatable-row-unique-id-field">
|
94 |
+
<input name="wcf-checkout-products[<?php echo $id; ?>][unique_id]" type="hidden" class="wcf-checkout-product-unique" value="<?php echo $selected_data['unique_id']; ?>">
|
95 |
+
</div>
|
96 |
+
|
97 |
+
<?php do_action( 'cartflows_repeatable_row_advance_fields', $id ); ?>
|
98 |
+
</div>
|
99 |
+
</div>
|
includes/meta-fields/get-field.php
ADDED
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Get Field.
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
$label = isset( $field_data['label'] ) ? $field_data['label'] : '';
|
9 |
+
$help = isset( $field_data['help'] ) ? $field_data['help'] : '';
|
10 |
+
$after_html = isset( $field_data['after_html'] ) ? $field_data['after_html'] : '';
|
11 |
+
|
12 |
+
$name_class = 'field-' . $field_data['name'];
|
13 |
+
|
14 |
+
if ( isset( $field_data['field_type'] ) ) {
|
15 |
+
$name_class .= ' wcf-field-' . $field_data['field_type'];
|
16 |
+
}
|
17 |
+
?>
|
18 |
+
|
19 |
+
<div class="wcf-field-row <?php echo $name_class; ?>">
|
20 |
+
|
21 |
+
<?php if ( ! empty( $label ) || ! empty( $help ) ) { ?>
|
22 |
+
<div class="wcf-field-row-heading">
|
23 |
+
|
24 |
+
<?php if ( ! empty( $label ) ) { ?>
|
25 |
+
<label><?php echo esc_html( $label ); ?></label>
|
26 |
+
<?php } ?>
|
27 |
+
|
28 |
+
<?php if ( ! empty( $help ) ) { ?>
|
29 |
+
<i class="wcf-field-heading-help dashicons dashicons-editor-help"></i>
|
30 |
+
<span class="wcf-tooltip-text"><?php echo $help; ?></span>
|
31 |
+
<?php } ?>
|
32 |
+
</div>
|
33 |
+
<?php } ?>
|
34 |
+
|
35 |
+
<div class="wcf-field-row-content"><?php echo $field_data['generated_content']; ?>
|
36 |
+
<?php
|
37 |
+
if ( ! empty( $after_html ) ) {
|
38 |
+
echo $after_html;
|
39 |
+
}
|
40 |
+
?>
|
41 |
+
</div>
|
42 |
+
</div>
|
includes/meta-fields/get-product-selection-repeater.php
ADDED
@@ -0,0 +1,117 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Get product selection repeater.
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
$value = $field_data['value'];
|
9 |
+
|
10 |
+
if ( ! is_array( $value ) ) {
|
11 |
+
|
12 |
+
$value[0] = array(
|
13 |
+
'product' => '',
|
14 |
+
);
|
15 |
+
} else {
|
16 |
+
|
17 |
+
if ( ! isset( $value[0] ) ) {
|
18 |
+
|
19 |
+
$value[0] = array(
|
20 |
+
'product' => '',
|
21 |
+
);
|
22 |
+
}
|
23 |
+
}
|
24 |
+
|
25 |
+
$name_class = 'field-' . $field_data['name'];
|
26 |
+
|
27 |
+
?>
|
28 |
+
|
29 |
+
<!-- Repeater template -->
|
30 |
+
<script type="text/html" id="tmpl-wcf-product-repeater">
|
31 |
+
<?php
|
32 |
+
$template_data = array(
|
33 |
+
'quantity' => 1,
|
34 |
+
'discount_type' => '',
|
35 |
+
'discount_value' => '',
|
36 |
+
'unique_id' => '{{unique_id}}',
|
37 |
+
);
|
38 |
+
echo $this->generate_product_repeater_html( '{{id}}', '', $template_data );
|
39 |
+
?>
|
40 |
+
</script>
|
41 |
+
<!-- Repeater template end -->
|
42 |
+
|
43 |
+
<div class="wcf-field-row wcf-product-repeater-field-row <?php echo $name_class; ?>">
|
44 |
+
<div class="wcf-field-row-content">
|
45 |
+
<div class="wcf-repeatables-wrap">
|
46 |
+
<?php
|
47 |
+
|
48 |
+
if ( is_array( $value ) ) {
|
49 |
+
|
50 |
+
$repeater_html = '';
|
51 |
+
$product_data_new = array();
|
52 |
+
|
53 |
+
foreach ( $value as $p_key => $p_data ) {
|
54 |
+
|
55 |
+
$selected_options = '';
|
56 |
+
$selected_data = array(
|
57 |
+
'product' => 0,
|
58 |
+
'quantity' => 1,
|
59 |
+
'discount_type' => '',
|
60 |
+
'discount_value' => '',
|
61 |
+
'unique_id' => wcf()->utils->get_unique_id(),
|
62 |
+
);
|
63 |
+
|
64 |
+
if ( isset( $p_data['product'] ) ) {
|
65 |
+
|
66 |
+
$product = wc_get_product( $p_data['product'] );
|
67 |
+
|
68 |
+
|
69 |
+
// posts.
|
70 |
+
if ( ! empty( $product ) ) {
|
71 |
+
|
72 |
+
$post_title = $product->get_name() . ' (#' . $p_data['product'] . ')';
|
73 |
+
$selected_options = '<option value="' . $p_data['product'] . '" selected="selected" >' . $post_title . '</option>';
|
74 |
+
}
|
75 |
+
|
76 |
+
$selected_data['product'] = $p_data['product'];
|
77 |
+
}
|
78 |
+
|
79 |
+
if ( isset( $p_data['quantity'] ) ) {
|
80 |
+
$selected_data['quantity'] = $p_data['quantity'];
|
81 |
+
}
|
82 |
+
|
83 |
+
|
84 |
+
if ( isset( $p_data['discount_type'] ) ) {
|
85 |
+
$selected_data['discount_type'] = $p_data['discount_type'];
|
86 |
+
|
87 |
+
}
|
88 |
+
|
89 |
+
if ( isset( $p_data['discount_value'] ) ) {
|
90 |
+
$selected_data['discount_value'] = $p_data['discount_value'];
|
91 |
+
}
|
92 |
+
|
93 |
+
if ( isset( $p_data['unique_id'] ) && ! empty( $p_data['unique_id'] ) ) {
|
94 |
+
$selected_data['unique_id'] = $p_data['unique_id'];
|
95 |
+
}
|
96 |
+
|
97 |
+
$repeater_html .= $this->generate_product_repeater_html( $p_key, $selected_options, $selected_data );
|
98 |
+
|
99 |
+
$product_data_new[] = $selected_data;
|
100 |
+
}
|
101 |
+
|
102 |
+
wcf()->utils->set_selcted_checkout_products( '', $product_data_new );
|
103 |
+
|
104 |
+
echo $repeater_html;
|
105 |
+
}
|
106 |
+
?>
|
107 |
+
|
108 |
+
<div class="wcf-add-fields"></div>
|
109 |
+
</div>
|
110 |
+
<div class="wcf-add-repeatable-row">
|
111 |
+
<div class="submit wcf-add-repeatable-wrap">
|
112 |
+
<button class="button-primary wcf-add-repeatable" data-name="wcf-checkout-products"><?php echo __( 'Add New Product', 'cartflows' ); ?></button>
|
113 |
+
<a href="#!" class="button button-primary wcf-create-woo-product" data-name="wcf-create-woo-product"><?php echo __( 'Create Product', 'cartflows' ); ?></a>
|
114 |
+
</div>
|
115 |
+
</div>
|
116 |
+
</div>
|
117 |
+
</div>
|
languages/cartflows.pot
CHANGED
@@ -1,2002 +1,2046 @@
|
|
1 |
-
# Copyright (C) 2020 CartFlows Inc
|
2 |
-
# This file is distributed under the same license as the CartFlows package.
|
3 |
-
msgid ""
|
4 |
-
msgstr ""
|
5 |
-
"Project-Id-Version: CartFlows 1.5.
|
6 |
-
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/cartflows\n"
|
7 |
-
"POT-Creation-Date: 2020-05-
|
8 |
-
"MIME-Version: 1.0\n"
|
9 |
-
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
-
"Content-Transfer-Encoding: 8bit\n"
|
11 |
-
"PO-Revision-Date: 2020-MO-DA HO:MI+ZONE\n"
|
12 |
-
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
13 |
-
"Language-Team: LANGUAGE <LL@li.org>\n"
|
14 |
-
"Language: en\n"
|
15 |
-
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
16 |
-
"X-Poedit-Country: United States\n"
|
17 |
-
"X-Poedit-SourceCharset: UTF-8\n"
|
18 |
-
"X-Poedit-KeywordsList: "
|
19 |
-
"__;_e;_x:1,2c;_ex:1,2c;_n:1,2;_nx:1,2,4c;_n_noop:1,2;_nx_noop:1,2,3c;esc_"
|
20 |
-
"attr__;esc_html__;esc_attr_e;esc_html_e;esc_attr_x:1,2c;esc_html_x:1,2c;\n"
|
21 |
-
"X-Poedit-Basepath: ../\n"
|
22 |
-
"X-Poedit-SearchPath-0: .\n"
|
23 |
-
"X-Poedit-Bookmarks: \n"
|
24 |
-
"X-Textdomain-Support: yes\n"
|
25 |
-
"X-Generator: grunt-wp-i18n 1.0.3\n"
|
26 |
-
|
27 |
-
#: classes/batch-process/class-cartflows-importer-elementor.php:44
|
28 |
-
msgid "Invalid content."
|
29 |
-
msgstr ""
|
30 |
-
|
31 |
-
#: classes/batch-process/class-cartflows-importer-elementor.php:52
|
32 |
-
msgid "Invalid content. Expected an array."
|
33 |
-
msgstr ""
|
34 |
-
|
35 |
-
#: classes/batch-process/helpers/class-wp-background-process.php:435
|
36 |
-
msgid "Every %d Minutes"
|
37 |
-
msgstr ""
|
38 |
-
|
39 |
-
#: classes/class-cartflows-admin-fields.php:231
|
40 |
-
msgid "Select"
|
41 |
-
msgstr ""
|
42 |
-
|
43 |
-
#: classes/class-cartflows-admin-fields.php:234
|
44 |
-
msgid "No Checkout Steps"
|
45 |
-
msgstr ""
|
46 |
-
|
47 |
-
#: classes/class-cartflows-admin-fields.php:260
|
48 |
-
#. translators: %s: link
|
49 |
-
msgid ""
|
50 |
-
"Be sure not to add any product in above selected Global Checkout step. "
|
51 |
-
"Please read information about how to set up Global Checkout %1$shere%2$s."
|
52 |
-
msgstr ""
|
53 |
-
|
54 |
-
#: classes/class-cartflows-admin.php:153 classes/class-cartflows-admin.php:154
|
55 |
-
#: includes/admin/cartflows-general-bck.php:34
|
56 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:150
|
57 |
-
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:148
|
58 |
-
msgid "Settings"
|
59 |
-
msgstr ""
|
60 |
-
|
61 |
-
#: classes/class-cartflows-admin.php:436
|
62 |
-
msgid "Installing and activating.."
|
63 |
-
msgstr ""
|
64 |
-
|
65 |
-
#: classes/class-cartflows-admin.php:437
|
66 |
-
msgid "There was an error with the installation of plugin."
|
67 |
-
msgstr ""
|
68 |
-
|
69 |
-
#: classes/class-cartflows-admin.php:491
|
70 |
-
msgid "Flows Library"
|
71 |
-
msgstr ""
|
72 |
-
|
73 |
-
#: classes/class-cartflows-admin.php:498
|
74 |
-
#: modules/flow/view/meta-flow-steps.php:156
|
75 |
-
msgid "Ready Templates"
|
76 |
-
msgstr ""
|
77 |
-
|
78 |
-
#: classes/class-cartflows-admin.php:501
|
79 |
-
#: modules/flow/view/meta-flow-steps.php:159
|
80 |
-
msgid "Create Your Own"
|
81 |
-
msgstr ""
|
82 |
-
|
83 |
-
#: classes/class-cartflows-admin.php:512
|
84 |
-
#: modules/flow/view/meta-flow-steps.php:171
|
85 |
-
msgid "Search Sites"
|
86 |
-
msgstr ""
|
87 |
-
|
88 |
-
#: classes/class-cartflows-admin.php:513
|
89 |
-
#: modules/flow/view/meta-flow-steps.php:172
|
90 |
-
msgid "Search Flow..."
|
91 |
-
msgstr ""
|
92 |
-
|
93 |
-
#: classes/class-cartflows-admin.php:530
|
94 |
-
msgid "Design Your Flow"
|
95 |
-
msgstr ""
|
96 |
-
|
97 |
-
#: classes/class-cartflows-admin.php:531
|
98 |
-
#: classes/class-cartflows-importer.php:637
|
99 |
-
#: classes/class-cartflows-importer.php:736
|
100 |
-
#: modules/flow/view/meta-flow-steps.php:202
|
101 |
-
msgid "Learn How"
|
102 |
-
msgstr ""
|
103 |
-
|
104 |
-
#: classes/class-cartflows-api.php:368
|
105 |
-
msgid "Request successfully processed!"
|
106 |
-
msgstr ""
|
107 |
-
|
108 |
-
#: classes/class-cartflows-cloning.php:423
|
109 |
-
msgid "Clone this flow"
|
110 |
-
msgstr ""
|
111 |
-
|
112 |
-
#: classes/class-cartflows-cloning.php:423
|
113 |
-
#: modules/flow/view/meta-flow-steps.php:115
|
114 |
-
msgid "Clone"
|
115 |
-
msgstr ""
|
116 |
-
|
117 |
-
#: classes/class-cartflows-default-meta.php:741
|
118 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:487
|
119 |
-
msgid "Submit"
|
120 |
-
msgstr ""
|
121 |
-
|
122 |
-
#: classes/class-cartflows-flow-frontend.php:53
|
123 |
-
msgid ""
|
124 |
-
"Test mode is active — which displays random products for previewing. It can "
|
125 |
-
"be deactivated from the flow settings in the admin dashboard."
|
126 |
-
msgstr ""
|
127 |
-
|
128 |
-
#: classes/class-cartflows-flow-frontend.php:58
|
129 |
-
msgid "Click here to disable it"
|
130 |
-
msgstr ""
|
131 |
-
|
132 |
-
#: classes/class-cartflows-importer.php:81
|
133 |
-
msgid "Export this flow"
|
134 |
-
msgstr ""
|
135 |
-
|
136 |
-
#: classes/class-cartflows-importer.php:81 includes/exporter.php:18
|
137 |
-
msgid "Export"
|
138 |
-
msgstr ""
|
139 |
-
|
140 |
-
#: classes/class-cartflows-importer.php:92
|
141 |
-
msgid "Flow Export"
|
142 |
-
msgstr ""
|
143 |
-
|
144 |
-
#: classes/class-cartflows-importer.php:93
|
145 |
-
msgid "Flow Import"
|
146 |
-
msgstr ""
|
147 |
-
|
148 |
-
#: classes/class-cartflows-importer.php:104
|
149 |
-
msgid "No post to export has been supplied!"
|
150 |
-
msgstr ""
|
151 |
-
|
152 |
-
#: classes/class-cartflows-importer.php:295
|
153 |
-
msgid "Please upload a valid .json file"
|
154 |
-
msgstr ""
|
155 |
-
|
156 |
-
#: classes/class-cartflows-importer.php:301
|
157 |
-
msgid "Please upload a file to import"
|
158 |
-
msgstr ""
|
159 |
-
|
160 |
-
#: classes/class-cartflows-importer.php:478
|
161 |
-
msgid "Successfully imported flows."
|
162 |
-
msgstr ""
|
163 |
-
|
164 |
-
#: classes/class-cartflows-importer.php:510
|
165 |
-
msgid "Loading Steps"
|
166 |
-
msgstr ""
|
167 |
-
|
168 |
-
#: classes/class-cartflows-importer.php:512
|
169 |
-
msgid "Getting steps from the cloud. Please wait for the moment."
|
170 |
-
msgstr ""
|
171 |
-
|
172 |
-
#: classes/class-cartflows-importer.php:523
|
173 |
-
msgid "Searching Template.."
|
174 |
-
msgstr ""
|
175 |
-
|
176 |
-
#: classes/class-cartflows-importer.php:525
|
177 |
-
msgid "Getting templates from the cloud. Please wait for the moment."
|
178 |
-
msgstr ""
|
179 |
-
|
180 |
-
#: classes/class-cartflows-importer.php:534
|
181 |
-
msgid "Importing.."
|
182 |
-
msgstr ""
|
183 |
-
|
184 |
-
#: classes/class-cartflows-importer.php:543
|
185 |
-
#: classes/class-cartflows-importer.php:583
|
186 |
-
msgid "Imported"
|
187 |
-
msgstr ""
|
188 |
-
|
189 |
-
#: classes/class-cartflows-importer.php:544
|
190 |
-
#: classes/class-cartflows-importer.php:584
|
191 |
-
msgid "Thanks for patience"
|
192 |
-
msgstr ""
|
193 |
-
|
194 |
-
#: classes/class-cartflows-importer.php:553
|
195 |
-
#: classes/class-cartflows-importer.php:565
|
196 |
-
msgid "Coming Soon!"
|
197 |
-
msgstr ""
|
198 |
-
|
199 |
-
#: classes/class-cartflows-importer.php:584
|
200 |
-
msgid "Redirecting to the Elementor edit window."
|
201 |
-
msgstr ""
|
202 |
-
|
203 |
-
#: classes/class-cartflows-importer.php:630
|
204 |
-
#: classes/class-cartflows-importer.php:746
|
205 |
-
msgid "Pro"
|
206 |
-
msgstr ""
|
207 |
-
|
208 |
-
#: classes/class-cartflows-importer.php:671
|
209 |
-
#: classes/class-cartflows-importer.php:778
|
210 |
-
msgid "Activate License"
|
211 |
-
msgstr ""
|
212 |
-
|
213 |
-
#: classes/class-cartflows-importer.php:673
|
214 |
-
#: classes/class-cartflows-importer.php:780
|
215 |
-
#: modules/flow/classes/class-cartflows-flow-meta.php:474
|
216 |
-
msgid "Get Pro"
|
217 |
-
msgstr ""
|
218 |
-
|
219 |
-
#: classes/class-cartflows-importer.php:698
|
220 |
-
msgid "Create"
|
221 |
-
msgstr ""
|
222 |
-
|
223 |
-
#: classes/class-cartflows-importer.php:797
|
224 |
-
msgid "Under Maintenance.."
|
225 |
-
msgstr ""
|
226 |
-
|
227 |
-
#: classes/class-cartflows-importer.php:798
|
228 |
-
msgid ""
|
229 |
-
"If you are seeing this message, most likely our servers are under routine "
|
230 |
-
"maintenance and we will be back shortly."
|
231 |
-
msgstr ""
|
232 |
-
|
233 |
-
#: classes/class-cartflows-importer.php:799
|
234 |
-
msgid ""
|
235 |
-
"In rare case, it is possible your website is having trouble connecting with "
|
236 |
-
"ours. If you need help, please feel free to get in touch with us from our "
|
237 |
-
"website.."
|
238 |
-
msgstr ""
|
239 |
-
|
240 |
-
#: classes/class-cartflows-importer.php:829
|
241 |
-
#. translators: %s: Plugin string
|
242 |
-
msgid ""
|
243 |
-
"%1$s to see CartFlows templates. If you prefer another page builder tool, "
|
244 |
-
"you can <a href=\"%2$s\" target=\"blank\">select it here</a>."
|
245 |
-
msgstr ""
|
246 |
-
|
247 |
-
#: classes/class-cartflows-importer.php:844
|
248 |
-
msgid "All"
|
249 |
-
msgstr ""
|
250 |
-
|
251 |
-
#: classes/class-cartflows-importer.php:847
|
252 |
-
msgid "Select Step Type"
|
253 |
-
msgstr ""
|
254 |
-
|
255 |
-
#: classes/class-cartflows-importer.php:931
|
256 |
-
msgid "Import from Cloud"
|
257 |
-
msgstr ""
|
258 |
-
|
259 |
-
#: classes/class-cartflows-importer.php:1230
|
260 |
-
msgid "Sales Landing"
|
261 |
-
msgstr ""
|
262 |
-
|
263 |
-
#: classes/class-cartflows-importer.php:1234
|
264 |
-
#: modules/flow/classes/class-cartflows-step-post-type.php:253
|
265 |
-
#: modules/flow/view/meta-flow-steps.php:12
|
266 |
-
msgid "Checkout (Woo)"
|
267 |
-
msgstr ""
|
268 |
-
|
269 |
-
#: classes/class-cartflows-importer.php:1238
|
270 |
-
#: modules/flow/classes/class-cartflows-step-post-type.php:260
|
271 |
-
#: modules/flow/view/meta-flow-steps.php:13
|
272 |
-
msgid "Thank You (Woo)"
|
273 |
-
msgstr ""
|
274 |
-
|
275 |
-
#: classes/class-cartflows-importer.php:1246
|
276 |
-
#: modules/flow/classes/class-cartflows-step-post-type.php:239
|
277 |
-
#: modules/flow/view/meta-flow-steps.php:11
|
278 |
-
msgid "Landing"
|
279 |
-
msgstr ""
|
280 |
-
|
281 |
-
#: classes/class-cartflows-importer.php:1250
|
282 |
-
msgid "Thank You"
|
283 |
-
msgstr ""
|
284 |
-
|
285 |
-
#: classes/class-cartflows-importer.php:1360
|
286 |
-
#. translators: %s: template ID
|
287 |
-
msgid "Invalid template id %1$s or post id %2$s."
|
288 |
-
msgstr ""
|
289 |
-
|
290 |
-
#: classes/class-cartflows-importer.php:1422
|
291 |
-
#. translators: %s: flow ID
|
292 |
-
msgid "Invalid flow id %1$s OR step type %2$s."
|
293 |
-
msgstr ""
|
294 |
-
|
295 |
-
#: classes/class-cartflows-importer.php:1547
|
296 |
-
msgid ""
|
297 |
-
"Elementor is not activated. Please activate plugin Elementor Page Builder "
|
298 |
-
"to import the step."
|
299 |
-
msgstr ""
|
300 |
-
|
301 |
-
#: classes/class-cartflows-importer.php:1650
|
302 |
-
msgid "Action failed. Invalid Security Nonce."
|
303 |
-
msgstr ""
|
304 |
-
|
305 |
-
#: classes/class-cartflows-importer.php:1657
|
306 |
-
msgid "User have not plugin install permissions."
|
307 |
-
msgstr ""
|
308 |
-
|
309 |
-
#: classes/class-cartflows-importer.php:1679
|
310 |
-
msgid "Plugin Successfully Activated"
|
311 |
-
msgstr ""
|
312 |
-
|
313 |
-
#: classes/class-cartflows-learndash-compatibility.php:86
|
314 |
-
msgid "None"
|
315 |
-
msgstr ""
|
316 |
-
|
317 |
-
#: classes/class-cartflows-learndash-compatibility.php:113
|
318 |
-
#. translators: 1: anchor start, 2: anchor close
|
319 |
-
msgid ""
|
320 |
-
"Non-enrolled students will redirect to the selected CartFlows template. If "
|
321 |
-
"you have not created any Flow already, add new Flow from %1$shere%2$s."
|
322 |
-
msgstr ""
|
323 |
-
|
324 |
-
#: classes/class-cartflows-learndash-compatibility.php:119
|
325 |
-
msgid "Select CartFlows Template for this Course"
|
326 |
-
msgstr ""
|
327 |
-
|
328 |
-
#: classes/class-cartflows-loader.php:222
|
329 |
-
#. translators: %s: html tags
|
330 |
-
msgid ""
|
331 |
-
"You are using an older version of %1$sCartFlows Pro%2$s. Please update "
|
332 |
-
"%1$sCartFlows Pro%2$s plugin to version %1$s%3$s%2$s or higher."
|
333 |
-
msgstr ""
|
334 |
-
|
335 |
-
#: classes/class-cartflows-loader.php:
|
336 |
-
#. translators: %s: html tags
|
337 |
-
msgid ""
|
338 |
-
"This %1$sCartFlows%2$s page requires %1$sWooCommerce%2$s plugin installed & "
|
339 |
-
"activated."
|
340 |
-
msgstr ""
|
341 |
-
|
342 |
-
#: classes/class-cartflows-loader.php:
|
343 |
-
msgid "Activate WooCommerce"
|
344 |
-
msgstr ""
|
345 |
-
|
346 |
-
#: classes/class-cartflows-loader.php:
|
347 |
-
msgid "Install WooCommerce"
|
348 |
-
msgstr ""
|
349 |
-
|
350 |
-
#: classes/class-cartflows-logger.php:161
|
351 |
-
msgid "Action failed. Please refresh the page and retry."
|
352 |
-
msgstr ""
|
353 |
-
|
354 |
-
#: classes/class-cartflows-meta-fields.php:
|
355 |
-
msgid "Thin 100"
|
356 |
-
msgstr ""
|
357 |
-
|
358 |
-
#: classes/class-cartflows-meta-fields.php:
|
359 |
-
msgid "Extra-Light 200"
|
360 |
-
msgstr ""
|
361 |
-
|
362 |
-
#: classes/class-cartflows-meta-fields.php:
|
363 |
-
msgid "Light 300"
|
364 |
-
msgstr ""
|
365 |
-
|
366 |
-
#: classes/class-cartflows-meta-fields.php:
|
367 |
-
msgid "Normal 400"
|
368 |
-
msgstr ""
|
369 |
-
|
370 |
-
#: classes/class-cartflows-meta-fields.php:
|
371 |
-
msgid "Medium 500"
|
372 |
-
msgstr ""
|
373 |
-
|
374 |
-
#: classes/class-cartflows-meta-fields.php:
|
375 |
-
msgid "Semi-Bold 600"
|
376 |
-
msgstr ""
|
377 |
-
|
378 |
-
#: classes/class-cartflows-meta-fields.php:
|
379 |
-
msgid "Bold 700"
|
380 |
-
msgstr ""
|
381 |
-
|
382 |
-
#: classes/class-cartflows-meta-fields.php:
|
383 |
-
msgid "Extra-Bold 800"
|
384 |
-
msgstr ""
|
385 |
-
|
386 |
-
#: classes/class-cartflows-meta-fields.php:
|
387 |
-
msgid "Ultra-Bold 900"
|
388 |
-
msgstr ""
|
389 |
-
|
390 |
-
#: classes/class-cartflows-meta-fields.php:
|
391 |
-
#:
|
392 |
-
msgid "Search for a product…"
|
393 |
-
msgstr ""
|
394 |
-
|
395 |
-
#: classes/class-cartflows-meta-fields.php:
|
396 |
-
msgid "Search for a coupon…"
|
397 |
-
msgstr ""
|
398 |
-
|
399 |
-
#: classes/class-cartflows-meta
|
400 |
-
msgid "
|
401 |
-
msgstr ""
|
402 |
-
|
403 |
-
#: classes/class-cartflows-meta
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
|
411 |
-
#: classes/class-cartflows-meta.php:
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
#:
|
418 |
-
msgid "
|
419 |
-
|
420 |
-
|
421 |
-
|
422 |
-
|
423 |
-
#:
|
424 |
-
|
425 |
-
|
426 |
-
|
427 |
-
|
428 |
-
|
429 |
-
|
430 |
-
|
431 |
-
|
432 |
-
"
|
433 |
-
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
|
444 |
-
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
|
455 |
-
|
456 |
-
|
457 |
-
|
458 |
-
#:
|
459 |
-
msgid "
|
460 |
-
msgstr ""
|
461 |
-
|
462 |
-
#: classes/class-cartflows-wizard.php:
|
463 |
-
msgid "
|
464 |
-
msgstr ""
|
465 |
-
|
466 |
-
#: classes/class-cartflows-wizard.php:
|
467 |
-
msgid "
|
468 |
-
msgstr ""
|
469 |
-
|
470 |
-
#: classes/class-cartflows-wizard.php:
|
471 |
-
msgid "
|
472 |
-
msgstr ""
|
473 |
-
|
474 |
-
#: classes/class-cartflows-wizard.php:
|
475 |
-
msgid "
|
476 |
-
msgstr ""
|
477 |
-
|
478 |
-
#: classes/class-cartflows-wizard.php:
|
479 |
-
msgid "
|
480 |
-
|
481 |
-
|
482 |
-
|
483 |
-
|
484 |
-
|
485 |
-
|
486 |
-
|
487 |
-
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
"
|
495 |
-
msgstr ""
|
496 |
-
|
497 |
-
#: classes/class-cartflows-wizard.php:
|
498 |
-
msgid "
|
499 |
-
msgstr ""
|
500 |
-
|
501 |
-
#: classes/class-cartflows-wizard.php:
|
502 |
-
|
503 |
-
|
504 |
-
|
505 |
-
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
|
512 |
-
|
513 |
-
|
514 |
-
|
515 |
-
|
516 |
-
|
517 |
-
|
518 |
-
|
519 |
-
|
520 |
-
|
521 |
-
|
522 |
-
|
523 |
-
|
524 |
-
|
525 |
-
|
526 |
-
|
527 |
-
#: classes/class-cartflows-wizard.php:
|
528 |
-
#:
|
529 |
-
msgid "
|
530 |
-
msgstr ""
|
531 |
-
|
532 |
-
#: classes/class-cartflows-wizard.php:
|
533 |
-
msgid ""
|
534 |
-
|
535 |
-
|
536 |
-
|
537 |
-
|
538 |
-
|
539 |
-
|
540 |
-
#: classes/class-cartflows-wizard.php:
|
541 |
-
msgid "
|
542 |
-
msgstr ""
|
543 |
-
|
544 |
-
#: classes/class-cartflows-wizard.php:
|
545 |
-
msgid "
|
546 |
-
|
547 |
-
|
548 |
-
|
549 |
-
|
550 |
-
|
551 |
-
|
552 |
-
|
553 |
-
|
554 |
-
msgstr ""
|
555 |
-
|
556 |
-
#: classes/class-cartflows-wizard.php:
|
557 |
-
msgid ""
|
558 |
-
|
559 |
-
|
560 |
-
|
561 |
-
|
562 |
-
|
563 |
-
|
564 |
-
|
565 |
-
"
|
566 |
-
msgstr ""
|
567 |
-
|
568 |
-
#: classes/class-cartflows-wizard.php:
|
569 |
-
|
570 |
-
|
571 |
-
|
572 |
-
|
573 |
-
|
574 |
-
|
575 |
-
|
576 |
-
|
577 |
-
|
578 |
-
|
579 |
-
|
580 |
-
|
581 |
-
#: classes/class-cartflows-wizard.php:
|
582 |
-
msgid "
|
583 |
-
|
584 |
-
|
585 |
-
|
586 |
-
|
587 |
-
|
588 |
-
|
589 |
-
|
590 |
-
|
591 |
-
|
592 |
-
|
593 |
-
|
594 |
-
|
595 |
-
|
596 |
-
|
597 |
-
"
|
598 |
-
|
599 |
-
|
600 |
-
|
601 |
-
|
602 |
-
|
603 |
-
|
604 |
-
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
-
|
609 |
-
|
610 |
-
|
611 |
-
|
612 |
-
msgstr ""
|
613 |
-
|
614 |
-
#: classes/class-cartflows-
|
615 |
-
|
616 |
-
|
617 |
-
|
618 |
-
|
619 |
-
|
620 |
-
|
621 |
-
|
622 |
-
|
623 |
-
|
624 |
-
|
625 |
-
|
626 |
-
|
627 |
-
|
628 |
-
|
629 |
-
|
630 |
-
|
631 |
-
|
632 |
-
|
633 |
-
|
634 |
-
|
635 |
-
|
636 |
-
|
637 |
-
|
638 |
-
|
639 |
-
|
640 |
-
|
641 |
-
|
642 |
-
#: includes/admin/cartflows-
|
643 |
-
|
644 |
-
|
645 |
-
|
646 |
-
|
647 |
-
|
648 |
-
|
649 |
-
|
650 |
-
|
651 |
-
|
652 |
-
|
653 |
-
|
654 |
-
|
655 |
-
|
656 |
-
#:
|
657 |
-
msgid "
|
658 |
-
msgstr ""
|
659 |
-
|
660 |
-
#: includes/admin/cartflows-
|
661 |
-
msgid "
|
662 |
-
msgstr ""
|
663 |
-
|
664 |
-
#: includes/admin/cartflows-
|
665 |
-
|
666 |
-
|
667 |
-
|
668 |
-
|
669 |
-
|
670 |
-
|
671 |
-
|
672 |
-
|
673 |
-
|
674 |
-
|
675 |
-
|
676 |
-
|
677 |
-
#: includes/admin/cartflows-general.php:
|
678 |
-
|
679 |
-
|
680 |
-
|
681 |
-
|
682 |
-
|
683 |
-
|
684 |
-
|
685 |
-
|
686 |
-
|
687 |
-
|
688 |
-
|
689 |
-
|
690 |
-
|
691 |
-
|
692 |
-
msgstr ""
|
693 |
-
|
694 |
-
#: includes/admin/cartflows-general.php:
|
695 |
-
msgid "
|
696 |
-
msgstr ""
|
697 |
-
|
698 |
-
#: includes/admin/cartflows-general.php:
|
699 |
-
|
700 |
-
|
701 |
-
|
702 |
-
"
|
703 |
-
|
704 |
-
|
705 |
-
|
706 |
-
|
707 |
-
|
708 |
-
|
709 |
-
|
710 |
-
#:
|
711 |
-
#:
|
712 |
-
|
713 |
-
|
714 |
-
|
715 |
-
|
716 |
-
|
717 |
-
|
718 |
-
|
719 |
-
|
720 |
-
|
721 |
-
|
722 |
-
|
723 |
-
#:
|
724 |
-
msgid "
|
725 |
-
msgstr ""
|
726 |
-
|
727 |
-
#: includes/admin/cartflows-general.php:
|
728 |
-
msgid "
|
729 |
-
msgstr ""
|
730 |
-
|
731 |
-
#: includes/admin/cartflows-general.php:
|
732 |
-
msgid "
|
733 |
-
msgstr ""
|
734 |
-
|
735 |
-
#: includes/admin/cartflows-general.php:
|
736 |
-
msgid "
|
737 |
-
msgstr ""
|
738 |
-
|
739 |
-
#: includes/admin/cartflows-general.php:
|
740 |
-
msgid "
|
741 |
-
msgstr ""
|
742 |
-
|
743 |
-
#: includes/admin/cartflows-general.php:
|
744 |
-
msgid "
|
745 |
-
msgstr ""
|
746 |
-
|
747 |
-
#: includes/admin/cartflows-general.php:
|
748 |
-
msgid "
|
749 |
-
msgstr ""
|
750 |
-
|
751 |
-
#: includes/admin/cartflows-general.php:
|
752 |
-
msgid "
|
753 |
-
msgstr ""
|
754 |
-
|
755 |
-
#: includes/admin/cartflows-general.php:
|
756 |
-
|
757 |
-
|
758 |
-
|
759 |
-
|
760 |
-
|
761 |
-
|
762 |
-
|
763 |
-
|
764 |
-
|
765 |
-
|
766 |
-
|
767 |
-
|
768 |
-
|
769 |
-
|
770 |
-
|
771 |
-
|
772 |
-
|
773 |
-
|
774 |
-
|
775 |
-
|
776 |
-
|
777 |
-
|
778 |
-
|
779 |
-
|
780 |
-
|
781 |
-
|
782 |
-
|
783 |
-
|
784 |
-
|
785 |
-
|
786 |
-
#: includes/admin/cartflows-general.php:
|
787 |
-
msgid "
|
788 |
-
msgstr ""
|
789 |
-
|
790 |
-
#: includes/admin/cartflows-general.php:
|
791 |
-
msgid "
|
792 |
-
msgstr ""
|
793 |
-
|
794 |
-
#: includes/admin/cartflows-general.php:
|
795 |
-
msgid "Google Analytics
|
796 |
-
msgstr ""
|
797 |
-
|
798 |
-
#: includes/admin/cartflows-general.php:
|
799 |
-
msgid "
|
800 |
-
|
801 |
-
|
802 |
-
|
803 |
-
|
804 |
-
|
805 |
-
|
806 |
-
|
807 |
-
|
808 |
-
|
809 |
-
|
810 |
-
|
811 |
-
|
812 |
-
|
813 |
-
|
814 |
-
"
|
815 |
-
msgstr ""
|
816 |
-
|
817 |
-
#: includes/admin/cartflows-general.php:
|
818 |
-
msgid "
|
819 |
-
|
820 |
-
|
821 |
-
|
822 |
-
|
823 |
-
|
824 |
-
|
825 |
-
|
826 |
-
|
827 |
-
|
828 |
-
|
829 |
-
|
830 |
-
|
831 |
-
|
832 |
-
|
833 |
-
"
|
834 |
-
msgstr ""
|
835 |
-
|
836 |
-
#: includes/admin/cartflows-general.php:
|
837 |
-
msgid "
|
838 |
-
msgstr ""
|
839 |
-
|
840 |
-
#: includes/admin/cartflows-general.php:
|
841 |
-
msgid "
|
842 |
-
|
843 |
-
|
844 |
-
|
845 |
-
|
846 |
-
|
847 |
-
|
848 |
-
|
849 |
-
|
850 |
-
|
851 |
-
|
852 |
-
|
853 |
-
|
854 |
-
|
855 |
-
"
|
856 |
-
msgstr ""
|
857 |
-
|
858 |
-
#: includes/admin/cartflows-general.php:
|
859 |
-
msgid "
|
860 |
-
msgstr ""
|
861 |
-
|
862 |
-
#: includes/admin/cartflows-general.php:
|
863 |
-
msgid "
|
864 |
-
msgstr ""
|
865 |
-
|
866 |
-
#: includes/admin/cartflows-general.php:
|
867 |
-
msgid "
|
868 |
-
|
869 |
-
|
870 |
-
|
871 |
-
|
872 |
-
|
873 |
-
|
874 |
-
|
875 |
-
|
876 |
-
|
877 |
-
|
878 |
-
|
879 |
-
|
880 |
-
|
881 |
-
"
|
882 |
-
msgstr ""
|
883 |
-
|
884 |
-
#: includes/
|
885 |
-
msgid "
|
886 |
-
|
887 |
-
|
888 |
-
|
889 |
-
|
890 |
-
|
891 |
-
|
892 |
-
|
893 |
-
|
894 |
-
|
895 |
-
|
896 |
-
|
897 |
-
|
898 |
-
|
899 |
-
|
900 |
-
msgstr ""
|
901 |
-
|
902 |
-
#: includes/
|
903 |
-
msgid "
|
904 |
-
msgstr ""
|
905 |
-
|
906 |
-
#: includes/
|
907 |
-
msgid "
|
908 |
-
msgstr ""
|
909 |
-
|
910 |
-
#: includes/
|
911 |
-
msgid "
|
912 |
-
msgstr ""
|
913 |
-
|
914 |
-
#:
|
915 |
-
|
916 |
-
|
917 |
-
|
918 |
-
|
919 |
-
"
|
920 |
-
msgstr ""
|
921 |
-
|
922 |
-
#:
|
923 |
-
|
924 |
-
|
925 |
-
|
926 |
-
|
927 |
-
|
928 |
-
|
929 |
-
|
930 |
-
|
931 |
-
|
932 |
-
|
933 |
-
|
934 |
-
#:
|
935 |
-
|
936 |
-
|
937 |
-
|
938 |
-
|
939 |
-
|
940 |
-
|
941 |
-
|
942 |
-
|
943 |
-
|
944 |
-
|
945 |
-
|
946 |
-
|
947 |
-
|
948 |
-
|
949 |
-
|
950 |
-
|
951 |
-
|
952 |
-
|
953 |
-
|
954 |
-
#: modules/checkout/classes/class-cartflows-checkout-markup.php:
|
955 |
-
|
956 |
-
|
957 |
-
|
958 |
-
|
959 |
-
|
960 |
-
|
961 |
-
|
962 |
-
|
963 |
-
|
964 |
-
|
965 |
-
|
966 |
-
|
967 |
-
#: modules/
|
968 |
-
msgid "
|
969 |
-
msgstr ""
|
970 |
-
|
971 |
-
#: modules/checkout/classes/class-cartflows-checkout-markup.php:
|
972 |
-
msgid "
|
973 |
-
|
974 |
-
|
975 |
-
|
976 |
-
|
977 |
-
|
978 |
-
|
979 |
-
|
980 |
-
|
981 |
-
|
982 |
-
|
983 |
-
|
984 |
-
|
985 |
-
#: modules/
|
986 |
-
#: modules/
|
987 |
-
msgid "
|
988 |
-
msgstr ""
|
989 |
-
|
990 |
-
#: modules/checkout/classes/class-cartflows-checkout-
|
991 |
-
#: modules/
|
992 |
-
msgid "
|
993 |
-
msgstr ""
|
994 |
-
|
995 |
-
#: modules/checkout/classes/class-cartflows-checkout-
|
996 |
-
msgid "
|
997 |
-
msgstr ""
|
998 |
-
|
999 |
-
#: modules/checkout/classes/class-cartflows-checkout-
|
1000 |
-
msgid "
|
1001 |
-
msgstr ""
|
1002 |
-
|
1003 |
-
#: modules/checkout/classes/class-cartflows-checkout-
|
1004 |
-
msgid "
|
1005 |
-
msgstr ""
|
1006 |
-
|
1007 |
-
#: modules/checkout/classes/class-cartflows-checkout-
|
1008 |
-
msgid "
|
1009 |
-
msgstr ""
|
1010 |
-
|
1011 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1012 |
-
msgid "Checkout
|
1013 |
-
msgstr ""
|
1014 |
-
|
1015 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1016 |
-
|
1017 |
-
|
1018 |
-
|
1019 |
-
|
1020 |
-
|
1021 |
-
|
1022 |
-
|
1023 |
-
#: modules/
|
1024 |
-
|
1025 |
-
|
1026 |
-
|
1027 |
-
|
1028 |
-
|
1029 |
-
|
1030 |
-
|
1031 |
-
|
1032 |
-
msgid "
|
1033 |
-
msgstr ""
|
1034 |
-
|
1035 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1036 |
-
|
1037 |
-
|
1038 |
-
|
1039 |
-
|
1040 |
-
|
1041 |
-
|
1042 |
-
|
1043 |
-
|
1044 |
-
|
1045 |
-
|
1046 |
-
|
1047 |
-
|
1048 |
-
"
|
1049 |
-
"
|
1050 |
-
|
1051 |
-
|
1052 |
-
|
1053 |
-
|
1054 |
-
|
1055 |
-
|
1056 |
-
|
1057 |
-
|
1058 |
-
|
1059 |
-
|
1060 |
-
|
1061 |
-
|
1062 |
-
|
1063 |
-
|
1064 |
-
|
1065 |
-
|
1066 |
-
|
1067 |
-
|
1068 |
-
|
1069 |
-
|
1070 |
-
|
1071 |
-
|
1072 |
-
|
1073 |
-
|
1074 |
-
|
1075 |
-
|
1076 |
-
msgid "
|
1077 |
-
msgstr ""
|
1078 |
-
|
1079 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1080 |
-
#. translators: %s: link
|
1081 |
-
msgid "
|
1082 |
-
msgstr ""
|
1083 |
-
|
1084 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1085 |
-
|
1086 |
-
|
1087 |
-
|
1088 |
-
|
1089 |
-
|
1090 |
-
|
1091 |
-
|
1092 |
-
|
1093 |
-
|
1094 |
-
msgstr ""
|
1095 |
-
|
1096 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1097 |
-
|
1098 |
-
|
1099 |
-
|
1100 |
-
|
1101 |
-
|
1102 |
-
|
1103 |
-
|
1104 |
-
|
1105 |
-
|
1106 |
-
|
1107 |
-
|
1108 |
-
|
1109 |
-
|
1110 |
-
|
1111 |
-
|
1112 |
-
|
1113 |
-
|
1114 |
-
|
1115 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1116 |
-
|
1117 |
-
|
1118 |
-
|
1119 |
-
#: modules/
|
1120 |
-
|
1121 |
-
|
1122 |
-
|
1123 |
-
|
1124 |
-
|
1125 |
-
|
1126 |
-
|
1127 |
-
|
1128 |
-
|
1129 |
-
|
1130 |
-
|
1131 |
-
|
1132 |
-
|
1133 |
-
|
1134 |
-
|
1135 |
-
|
1136 |
-
|
1137 |
-
|
1138 |
-
|
1139 |
-
|
1140 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1141 |
-
|
1142 |
-
|
1143 |
-
|
1144 |
-
|
1145 |
-
|
1146 |
-
|
1147 |
-
|
1148 |
-
#: modules/
|
1149 |
-
msgid "
|
1150 |
-
msgstr ""
|
1151 |
-
|
1152 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1153 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:
|
1154 |
-
msgid "
|
1155 |
-
msgstr ""
|
1156 |
-
|
1157 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1158 |
-
#: modules/
|
1159 |
-
|
1160 |
-
|
1161 |
-
|
1162 |
-
#: modules/
|
1163 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:
|
1164 |
-
|
1165 |
-
|
1166 |
-
|
1167 |
-
|
1168 |
-
|
1169 |
-
#: modules/
|
1170 |
-
|
1171 |
-
|
1172 |
-
|
1173 |
-
|
1174 |
-
#: modules/
|
1175 |
-
|
1176 |
-
|
1177 |
-
|
1178 |
-
|
1179 |
-
|
1180 |
-
|
1181 |
-
|
1182 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1183 |
-
#: modules/
|
1184 |
-
#: modules/
|
1185 |
-
|
1186 |
-
|
1187 |
-
|
1188 |
-
|
1189 |
-
|
1190 |
-
|
1191 |
-
#: modules/
|
1192 |
-
|
1193 |
-
|
1194 |
-
|
1195 |
-
|
1196 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1197 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:
|
1198 |
-
|
1199 |
-
|
1200 |
-
|
1201 |
-
|
1202 |
-
#: modules/
|
1203 |
-
|
1204 |
-
|
1205 |
-
|
1206 |
-
|
1207 |
-
|
1208 |
-
|
1209 |
-
|
1210 |
-
|
1211 |
-
#: modules/
|
1212 |
-
#: modules/
|
1213 |
-
|
1214 |
-
|
1215 |
-
|
1216 |
-
|
1217 |
-
|
1218 |
-
#: modules/
|
1219 |
-
#: modules/
|
1220 |
-
|
1221 |
-
|
1222 |
-
|
1223 |
-
|
1224 |
-
|
1225 |
-
#: modules/
|
1226 |
-
#: modules/
|
1227 |
-
|
1228 |
-
|
1229 |
-
|
1230 |
-
|
1231 |
-
|
1232 |
-
|
1233 |
-
|
1234 |
-
|
1235 |
-
#: modules/
|
1236 |
-
|
1237 |
-
|
1238 |
-
|
1239 |
-
|
1240 |
-
|
1241 |
-
|
1242 |
-
#: modules/
|
1243 |
-
|
1244 |
-
|
1245 |
-
|
1246 |
-
|
1247 |
-
|
1248 |
-
|
1249 |
-
#: modules/
|
1250 |
-
|
1251 |
-
|
1252 |
-
|
1253 |
-
|
1254 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1255 |
-
|
1256 |
-
|
1257 |
-
|
1258 |
-
|
1259 |
-
|
1260 |
-
|
1261 |
-
|
1262 |
-
|
1263 |
-
#: modules/
|
1264 |
-
|
1265 |
-
|
1266 |
-
|
1267 |
-
|
1268 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1269 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:
|
1270 |
-
|
1271 |
-
|
1272 |
-
|
1273 |
-
|
1274 |
-
#: modules/
|
1275 |
-
|
1276 |
-
|
1277 |
-
|
1278 |
-
|
1279 |
-
|
1280 |
-
|
1281 |
-
|
1282 |
-
#: modules/
|
1283 |
-
msgid "
|
1284 |
-
msgstr ""
|
1285 |
-
|
1286 |
-
#: modules/checkout/classes/class-cartflows-checkout-meta.php:
|
1287 |
-
|
1288 |
-
|
1289 |
-
|
1290 |
-
|
1291 |
-
|
1292 |
-
|
1293 |
-
|
1294 |
-
#: modules/
|
1295 |
-
msgid "
|
1296 |
-
msgstr ""
|
1297 |
-
|
1298 |
-
#: modules/checkout/
|
1299 |
-
msgid "
|
1300 |
-
msgstr ""
|
1301 |
-
|
1302 |
-
#: modules/
|
1303 |
-
|
1304 |
-
msgid "
|
1305 |
-
msgstr ""
|
1306 |
-
|
1307 |
-
#: modules/
|
1308 |
-
|
1309 |
-
msgid "
|
1310 |
-
msgstr ""
|
1311 |
-
|
1312 |
-
#: modules/
|
1313 |
-
|
1314 |
-
msgid "
|
1315 |
-
msgstr ""
|
1316 |
-
|
1317 |
-
#: modules/
|
1318 |
-
|
1319 |
-
msgid "
|
1320 |
-
msgstr ""
|
1321 |
-
|
1322 |
-
#: modules/
|
1323 |
-
msgid "
|
1324 |
-
msgstr ""
|
1325 |
-
|
1326 |
-
#: modules/
|
1327 |
-
|
1328 |
-
|
1329 |
-
|
1330 |
-
|
1331 |
-
|
1332 |
-
|
1333 |
-
|
1334 |
-
|
1335 |
-
|
1336 |
-
|
1337 |
-
|
1338 |
-
|
1339 |
-
|
1340 |
-
|
1341 |
-
|
1342 |
-
|
1343 |
-
|
1344 |
-
|
1345 |
-
|
1346 |
-
#: modules/flow/
|
1347 |
-
|
1348 |
-
|
1349 |
-
|
1350 |
-
|
1351 |
-
|
1352 |
-
|
1353 |
-
|
1354 |
-
|
1355 |
-
|
1356 |
-
|
1357 |
-
|
1358 |
-
|
1359 |
-
|
1360 |
-
|
1361 |
-
|
1362 |
-
|
1363 |
-
msgid "
|
1364 |
-
msgstr ""
|
1365 |
-
|
1366 |
-
#: modules/flow/classes/class-cartflows-flow-
|
1367 |
-
msgid "
|
1368 |
-
msgstr ""
|
1369 |
-
|
1370 |
-
#: modules/flow/classes/class-cartflows-flow-
|
1371 |
-
|
1372 |
-
|
1373 |
-
|
1374 |
-
|
1375 |
-
#: modules/flow/classes/class-cartflows-flow-
|
1376 |
-
|
1377 |
-
|
1378 |
-
|
1379 |
-
|
1380 |
-
|
1381 |
-
|
1382 |
-
|
1383 |
-
|
1384 |
-
|
1385 |
-
|
1386 |
-
|
1387 |
-
msgstr ""
|
1388 |
-
|
1389 |
-
#: modules/flow/classes/class-cartflows-flow-
|
1390 |
-
|
1391 |
-
|
1392 |
-
|
1393 |
-
|
1394 |
-
|
1395 |
-
|
1396 |
-
|
1397 |
-
|
1398 |
-
|
1399 |
-
|
1400 |
-
|
1401 |
-
|
1402 |
-
#: modules/flow/classes/class-cartflows-flow-post-type.php:
|
1403 |
-
|
1404 |
-
|
1405 |
-
|
1406 |
-
|
1407 |
-
|
1408 |
-
|
1409 |
-
|
1410 |
-
#: modules/flow/classes/class-cartflows-
|
1411 |
-
|
1412 |
-
|
1413 |
-
|
1414 |
-
|
1415 |
-
|
1416 |
-
|
1417 |
-
|
1418 |
-
|
1419 |
-
|
1420 |
-
|
1421 |
-
#: modules/flow/classes/class-cartflows-
|
1422 |
-
|
1423 |
-
|
1424 |
-
|
1425 |
-
|
1426 |
-
|
1427 |
-
|
1428 |
-
|
1429 |
-
#: modules/flow/classes/class-cartflows-
|
1430 |
-
|
1431 |
-
|
1432 |
-
|
1433 |
-
|
1434 |
-
|
1435 |
-
|
1436 |
-
|
1437 |
-
|
1438 |
-
|
1439 |
-
|
1440 |
-
|
1441 |
-
#: modules/flow/classes/class-cartflows-
|
1442 |
-
|
1443 |
-
|
1444 |
-
|
1445 |
-
|
1446 |
-
#: modules/flow/classes/class-cartflows-flow-post-type.php:
|
1447 |
-
#: modules/flow/classes/class-cartflows-step-post-type.php:
|
1448 |
-
|
1449 |
-
|
1450 |
-
|
1451 |
-
|
1452 |
-
|
1453 |
-
#: modules/flow/classes/class-cartflows-
|
1454 |
-
|
1455 |
-
|
1456 |
-
|
1457 |
-
|
1458 |
-
|
1459 |
-
#: modules/
|
1460 |
-
|
1461 |
-
|
1462 |
-
|
1463 |
-
|
1464 |
-
|
1465 |
-
|
1466 |
-
|
1467 |
-
|
1468 |
-
|
1469 |
-
|
1470 |
-
|
1471 |
-
|
1472 |
-
#: modules/flow/
|
1473 |
-
|
1474 |
-
|
1475 |
-
|
1476 |
-
|
1477 |
-
|
1478 |
-
|
1479 |
-
|
1480 |
-
|
1481 |
-
|
1482 |
-
|
1483 |
-
|
1484 |
-
|
1485 |
-
#: modules/flow/classes/class-cartflows-step-post-type.php:
|
1486 |
-
|
1487 |
-
|
1488 |
-
|
1489 |
-
|
1490 |
-
|
1491 |
-
|
1492 |
-
|
1493 |
-
|
1494 |
-
|
1495 |
-
|
1496 |
-
|
1497 |
-
#: modules/flow/classes/class-cartflows-step-post-type.php:
|
1498 |
-
|
1499 |
-
msgid "
|
1500 |
-
msgstr ""
|
1501 |
-
|
1502 |
-
#: modules/flow/classes/class-cartflows-
|
1503 |
-
#: modules/
|
1504 |
-
msgid "
|
1505 |
-
msgstr ""
|
1506 |
-
|
1507 |
-
#: modules/flow/classes/class-cartflows-step-post-type.php:
|
1508 |
-
|
1509 |
-
|
1510 |
-
|
1511 |
-
|
1512 |
-
|
1513 |
-
|
1514 |
-
|
1515 |
-
|
1516 |
-
#: modules/flow/view/meta-flow-steps.php:
|
1517 |
-
msgid "
|
1518 |
-
msgstr ""
|
1519 |
-
|
1520 |
-
#: modules/flow/
|
1521 |
-
|
1522 |
-
|
1523 |
-
|
1524 |
-
|
1525 |
-
|
1526 |
-
|
1527 |
-
|
1528 |
-
|
1529 |
-
|
1530 |
-
|
1531 |
-
|
1532 |
-
|
1533 |
-
|
1534 |
-
|
1535 |
-
|
1536 |
-
|
1537 |
-
|
1538 |
-
|
1539 |
-
|
1540 |
-
|
1541 |
-
|
1542 |
-
|
1543 |
-
|
1544 |
-
|
1545 |
-
|
1546 |
-
|
1547 |
-
|
1548 |
-
|
1549 |
-
|
1550 |
-
|
1551 |
-
|
1552 |
-
#: modules/
|
1553 |
-
msgid "
|
1554 |
-
msgstr ""
|
1555 |
-
|
1556 |
-
#: modules/
|
1557 |
-
msgid "
|
1558 |
-
msgstr ""
|
1559 |
-
|
1560 |
-
#: modules/
|
1561 |
-
msgid ""
|
1562 |
-
|
1563 |
-
|
1564 |
-
|
1565 |
-
|
1566 |
-
|
1567 |
-
|
1568 |
-
|
1569 |
-
|
1570 |
-
|
1571 |
-
|
1572 |
-
|
1573 |
-
|
1574 |
-
|
1575 |
-
|
1576 |
-
|
1577 |
-
|
1578 |
-
|
1579 |
-
|
1580 |
-
#: modules/
|
1581 |
-
msgid "
|
1582 |
-
msgstr ""
|
1583 |
-
|
1584 |
-
#: modules/
|
1585 |
-
msgid "
|
1586 |
-
msgstr ""
|
1587 |
-
|
1588 |
-
#: modules/
|
1589 |
-
msgid "
|
1590 |
-
msgstr ""
|
1591 |
-
|
1592 |
-
#: modules/
|
1593 |
-
msgid "
|
1594 |
-
msgstr ""
|
1595 |
-
|
1596 |
-
#: modules/
|
1597 |
-
msgid "
|
1598 |
-
msgstr ""
|
1599 |
-
|
1600 |
-
#: modules/optin/classes/class-cartflows-optin-
|
1601 |
-
msgid "
|
1602 |
-
msgstr ""
|
1603 |
-
|
1604 |
-
#: modules/optin/classes/class-cartflows-optin-
|
1605 |
-
msgid "
|
1606 |
-
|
1607 |
-
|
1608 |
-
|
1609 |
-
|
1610 |
-
|
1611 |
-
"
|
1612 |
-
msgstr ""
|
1613 |
-
|
1614 |
-
#: modules/optin/classes/class-cartflows-optin-
|
1615 |
-
|
1616 |
-
|
1617 |
-
|
1618 |
-
|
1619 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:
|
1620 |
-
msgid "
|
1621 |
-
msgstr ""
|
1622 |
-
|
1623 |
-
#: modules/optin/classes/class-cartflows-optin-meta.php:
|
1624 |
-
|
1625 |
-
|
1626 |
-
|
1627 |
-
|
1628 |
-
|
1629 |
-
msgid ""
|
1630 |
-
|
1631 |
-
|
1632 |
-
|
1633 |
-
|
1634 |
-
|
1635 |
-
|
1636 |
-
|
1637 |
-
|
1638 |
-
|
1639 |
-
|
1640 |
-
|
1641 |
-
|
1642 |
-
|
1643 |
-
|
1644 |
-
|
1645 |
-
|
1646 |
-
|
1647 |
-
|
1648 |
-
|
1649 |
-
|
1650 |
-
|
1651 |
-
|
1652 |
-
|
1653 |
-
|
1654 |
-
|
1655 |
-
|
1656 |
-
|
1657 |
-
|
1658 |
-
|
1659 |
-
|
1660 |
-
|
1661 |
-
|
1662 |
-
|
1663 |
-
#: modules/
|
1664 |
-
msgid "
|
1665 |
-
msgstr ""
|
1666 |
-
|
1667 |
-
#: modules/
|
1668 |
-
msgid "
|
1669 |
-
msgstr ""
|
1670 |
-
|
1671 |
-
#: modules/
|
1672 |
-
|
1673 |
-
|
1674 |
-
|
1675 |
-
|
1676 |
-
|
1677 |
-
|
1678 |
-
|
1679 |
-
|
1680 |
-
|
1681 |
-
|
1682 |
-
|
1683 |
-
|
1684 |
-
|
1685 |
-
|
1686 |
-
|
1687 |
-
|
1688 |
-
|
1689 |
-
|
1690 |
-
|
1691 |
-
|
1692 |
-
|
1693 |
-
|
1694 |
-
|
1695 |
-
|
1696 |
-
|
1697 |
-
|
1698 |
-
|
1699 |
-
|
1700 |
-
|
1701 |
-
|
1702 |
-
|
1703 |
-
|
1704 |
-
|
1705 |
-
|
1706 |
-
|
1707 |
-
|
1708 |
-
|
1709 |
-
|
1710 |
-
|
1711 |
-
|
1712 |
-
|
1713 |
-
|
1714 |
-
|
1715 |
-
|
1716 |
-
|
1717 |
-
|
1718 |
-
|
1719 |
-
|
1720 |
-
|
1721 |
-
|
1722 |
-
|
1723 |
-
|
1724 |
-
|
1725 |
-
|
1726 |
-
|
1727 |
-
|
1728 |
-
|
1729 |
-
|
1730 |
-
|
1731 |
-
|
1732 |
-
|
1733 |
-
|
1734 |
-
|
1735 |
-
|
1736 |
-
|
1737 |
-
|
1738 |
-
|
1739 |
-
|
1740 |
-
|
1741 |
-
|
1742 |
-
|
1743 |
-
|
1744 |
-
|
1745 |
-
|
1746 |
-
|
1747 |
-
|
1748 |
-
|
1749 |
-
|
1750 |
-
|
1751 |
-
|
1752 |
-
|
1753 |
-
|
1754 |
-
|
1755 |
-
|
1756 |
-
|
1757 |
-
|
1758 |
-
|
1759 |
-
|
1760 |
-
|
1761 |
-
|
1762 |
-
#: woocommerce/template/
|
1763 |
-
|
1764 |
-
|
1765 |
-
|
1766 |
-
|
1767 |
-
|
1768 |
-
|
1769 |
-
|
1770 |
-
|
1771 |
-
|
1772 |
-
|
1773 |
-
|
1774 |
-
|
1775 |
-
|
1776 |
-
|
1777 |
-
|
1778 |
-
|
1779 |
-
|
1780 |
-
|
1781 |
-
|
1782 |
-
|
1783 |
-
|
1784 |
-
|
1785 |
-
|
1786 |
-
|
1787 |
-
msgid "
|
1788 |
-
msgstr ""
|
1789 |
-
|
1790 |
-
#:
|
1791 |
-
msgid "
|
1792 |
-
msgstr ""
|
1793 |
-
|
1794 |
-
#:
|
1795 |
-
msgid "
|
1796 |
-
msgstr ""
|
1797 |
-
|
1798 |
-
#:
|
1799 |
-
msgid "
|
1800 |
-
msgstr ""
|
1801 |
-
|
1802 |
-
#:
|
1803 |
-
msgid "
|
1804 |
-
msgstr ""
|
1805 |
-
|
1806 |
-
#: woocommerce/template/
|
1807 |
-
|
1808 |
-
|
1809 |
-
|
1810 |
-
|
1811 |
-
|
1812 |
-
|
1813 |
-
|
1814 |
-
|
1815 |
-
|
1816 |
-
|
1817 |
-
|
1818 |
-
|
1819 |
-
|
1820 |
-
|
1821 |
-
|
1822 |
-
|
1823 |
-
|
1824 |
-
|
1825 |
-
|
1826 |
-
|
1827 |
-
|
1828 |
-
|
1829 |
-
|
1830 |
-
|
1831 |
-
msgid "
|
1832 |
-
msgstr ""
|
1833 |
-
|
1834 |
-
#: woocommerce/template/
|
1835 |
-
msgid "
|
1836 |
-
msgstr ""
|
1837 |
-
|
1838 |
-
#: woocommerce/template/checkout/form-
|
1839 |
-
msgid "
|
1840 |
-
msgstr ""
|
1841 |
-
|
1842 |
-
#: woocommerce/template/checkout/form-
|
1843 |
-
msgid ""
|
1844 |
-
|
1845 |
-
|
1846 |
-
|
1847 |
-
|
1848 |
-
|
1849 |
-
|
1850 |
-
|
1851 |
-
|
1852 |
-
|
1853 |
-
|
1854 |
-
|
1855 |
-
|
1856 |
-
|
1857 |
-
|
1858 |
-
|
1859 |
-
"
|
1860 |
-
"
|
1861 |
-
|
1862 |
-
|
1863 |
-
|
1864 |
-
|
1865 |
-
|
1866 |
-
|
1867 |
-
|
1868 |
-
|
1869 |
-
|
1870 |
-
|
1871 |
-
"
|
1872 |
-
|
1873 |
-
|
1874 |
-
|
1875 |
-
|
1876 |
-
|
1877 |
-
|
1878 |
-
|
1879 |
-
|
1880 |
-
|
1881 |
-
|
1882 |
-
|
1883 |
-
|
1884 |
-
|
1885 |
-
|
1886 |
-
#: woocommerce/template/checkout/
|
1887 |
-
|
1888 |
-
|
1889 |
-
|
1890 |
-
|
1891 |
-
|
1892 |
-
|
1893 |
-
|
1894 |
-
|
1895 |
-
|
1896 |
-
|
1897 |
-
"
|
1898 |
-
|
1899 |
-
|
1900 |
-
|
1901 |
-
|
1902 |
-
|
1903 |
-
|
1904 |
-
|
1905 |
-
|
1906 |
-
|
1907 |
-
|
1908 |
-
|
1909 |
-
|
1910 |
-
|
1911 |
-
|
1912 |
-
|
1913 |
-
|
1914 |
-
|
1915 |
-
|
1916 |
-
|
1917 |
-
|
1918 |
-
|
1919 |
-
|
1920 |
-
|
1921 |
-
|
1922 |
-
|
1923 |
-
|
1924 |
-
|
1925 |
-
|
1926 |
-
|
1927 |
-
|
1928 |
-
|
1929 |
-
|
1930 |
-
#: woocommerce/template/
|
1931 |
-
|
1932 |
-
|
1933 |
-
|
1934 |
-
|
1935 |
-
|
1936 |
-
|
1937 |
-
|
1938 |
-
|
1939 |
-
|
1940 |
-
|
1941 |
-
|
1942 |
-
|
1943 |
-
|
1944 |
-
msgstr ""
|
1945 |
-
|
1946 |
-
#: woocommerce/template/
|
1947 |
-
msgid "
|
1948 |
-
msgstr ""
|
1949 |
-
|
1950 |
-
#: woocommerce/template/
|
1951 |
-
msgid "
|
1952 |
-
msgstr ""
|
1953 |
-
|
1954 |
-
#: woocommerce/template/
|
1955 |
-
msgid "
|
1956 |
-
msgstr ""
|
1957 |
-
|
1958 |
-
|
1959 |
-
msgid "
|
1960 |
-
msgstr ""
|
1961 |
-
|
1962 |
-
|
1963 |
-
msgid "
|
1964 |
-
msgstr ""
|
1965 |
-
|
1966 |
-
|
1967 |
-
msgid "
|
1968 |
-
msgstr ""
|
1969 |
-
|
1970 |
-
|
1971 |
-
msgid "
|
1972 |
-
msgstr ""
|
1973 |
-
|
1974 |
-
#:
|
1975 |
-
|
1976 |
-
|
1977 |
-
|
1978 |
-
|
1979 |
-
|
1980 |
-
|
1981 |
-
|
1982 |
-
|
1983 |
-
|
1984 |
-
|
1985 |
-
|
1986 |
-
|
1987 |
-
|
1988 |
-
|
1989 |
-
|
1990 |
-
|
1991 |
-
msgid "
|
1992 |
-
msgstr ""
|
1993 |
-
|
1994 |
-
#:
|
1995 |
-
|
1996 |
-
|
1997 |
-
|
1998 |
-
|
1999 |
-
|
2000 |
-
|
2001 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2002 |
msgstr ""
|
1 |
+
# Copyright (C) 2020 CartFlows Inc
|
2 |
+
# This file is distributed under the same license as the CartFlows package.
|
3 |
+
msgid ""
|
4 |
+
msgstr ""
|
5 |
+
"Project-Id-Version: CartFlows 1.5.9\n"
|
6 |
+
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/cartflows\n"
|
7 |
+
"POT-Creation-Date: 2020-05-14 10:01:55+00:00\n"
|
8 |
+
"MIME-Version: 1.0\n"
|
9 |
+
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
+
"Content-Transfer-Encoding: 8bit\n"
|
11 |
+
"PO-Revision-Date: 2020-MO-DA HO:MI+ZONE\n"
|
12 |
+
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
13 |
+
"Language-Team: LANGUAGE <LL@li.org>\n"
|
14 |
+
"Language: en\n"
|
15 |
+
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
16 |
+
"X-Poedit-Country: United States\n"
|
17 |
+
"X-Poedit-SourceCharset: UTF-8\n"
|
18 |
+
"X-Poedit-KeywordsList: "
|
19 |
+
"__;_e;_x:1,2c;_ex:1,2c;_n:1,2;_nx:1,2,4c;_n_noop:1,2;_nx_noop:1,2,3c;esc_"
|
20 |
+
"attr__;esc_html__;esc_attr_e;esc_html_e;esc_attr_x:1,2c;esc_html_x:1,2c;\n"
|
21 |
+
"X-Poedit-Basepath: ../\n"
|
22 |
+
"X-Poedit-SearchPath-0: .\n"
|
23 |
+
"X-Poedit-Bookmarks: \n"
|
24 |
+
"X-Textdomain-Support: yes\n"
|
25 |
+
"X-Generator: grunt-wp-i18n 1.0.3\n"
|
26 |
+
|
27 |
+
#: classes/batch-process/class-cartflows-importer-elementor.php:44
|
28 |
+
msgid "Invalid content."
|
29 |
+
msgstr ""
|
30 |
+
|
31 |
+
#: classes/batch-process/class-cartflows-importer-elementor.php:52
|
32 |
+
msgid "Invalid content. Expected an array."
|
33 |
+
msgstr ""
|
34 |
+
|
35 |
+
#: classes/batch-process/helpers/class-wp-background-process.php:435
|
36 |
+
msgid "Every %d Minutes"
|
37 |
+
msgstr ""
|
38 |
+
|
39 |
+
#: classes/class-cartflows-admin-fields.php:231
|
40 |
+
msgid "Select"
|
41 |
+
msgstr ""
|
42 |
+
|
43 |
+
#: classes/class-cartflows-admin-fields.php:234
|
44 |
+
msgid "No Checkout Steps"
|
45 |
+
msgstr ""
|
46 |
+
|
47 |
+
#: classes/class-cartflows-admin-fields.php:260
|
48 |
+
#. translators: %s: link
|
49 |
+
msgid ""
|
50 |
+
"Be sure not to add any product in above selected Global Checkout step. "
|
51 |
+
"Please read information about how to set up Global Checkout %1$shere%2$s."
|
52 |
+
msgstr ""
|
53 |
+
|
54 |
+
#: classes/class-cartflows-admin.php:153 classes/class-cartflows-admin.php:154
|
55 |
+
#: includes/admin/cartflows-general-bck.php:34
|
56 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:150
|
57 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:148
|
58 |
+
msgid "Settings"
|
59 |
+
msgstr ""
|
60 |
+
|
61 |
+
#: classes/class-cartflows-admin.php:436
|
62 |
+
msgid "Installing and activating.."
|
63 |
+
msgstr ""
|
64 |
+
|
65 |
+
#: classes/class-cartflows-admin.php:437
|
66 |
+
msgid "There was an error with the installation of plugin."
|
67 |
+
msgstr ""
|
68 |
+
|
69 |
+
#: classes/class-cartflows-admin.php:491
|
70 |
+
msgid "Flows Library"
|
71 |
+
msgstr ""
|
72 |
+
|
73 |
+
#: classes/class-cartflows-admin.php:498
|
74 |
+
#: modules/flow/view/meta-flow-steps.php:156
|
75 |
+
msgid "Ready Templates"
|
76 |
+
msgstr ""
|
77 |
+
|
78 |
+
#: classes/class-cartflows-admin.php:501
|
79 |
+
#: modules/flow/view/meta-flow-steps.php:159
|
80 |
+
msgid "Create Your Own"
|
81 |
+
msgstr ""
|
82 |
+
|
83 |
+
#: classes/class-cartflows-admin.php:512
|
84 |
+
#: modules/flow/view/meta-flow-steps.php:171
|
85 |
+
msgid "Search Sites"
|
86 |
+
msgstr ""
|
87 |
+
|
88 |
+
#: classes/class-cartflows-admin.php:513
|
89 |
+
#: modules/flow/view/meta-flow-steps.php:172
|
90 |
+
msgid "Search Flow..."
|
91 |
+
msgstr ""
|
92 |
+
|
93 |
+
#: classes/class-cartflows-admin.php:530
|
94 |
+
msgid "Design Your Flow"
|
95 |
+
msgstr ""
|
96 |
+
|
97 |
+
#: classes/class-cartflows-admin.php:531
|
98 |
+
#: classes/class-cartflows-importer.php:637
|
99 |
+
#: classes/class-cartflows-importer.php:736
|
100 |
+
#: modules/flow/view/meta-flow-steps.php:202
|
101 |
+
msgid "Learn How"
|
102 |
+
msgstr ""
|
103 |
+
|
104 |
+
#: classes/class-cartflows-api.php:368
|
105 |
+
msgid "Request successfully processed!"
|
106 |
+
msgstr ""
|
107 |
+
|
108 |
+
#: classes/class-cartflows-cloning.php:423
|
109 |
+
msgid "Clone this flow"
|
110 |
+
msgstr ""
|
111 |
+
|
112 |
+
#: classes/class-cartflows-cloning.php:423
|
113 |
+
#: modules/flow/view/meta-flow-steps.php:115
|
114 |
+
msgid "Clone"
|
115 |
+
msgstr ""
|
116 |
+
|
117 |
+
#: classes/class-cartflows-default-meta.php:741
|
118 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:487
|
119 |
+
msgid "Submit"
|
120 |
+
msgstr ""
|
121 |
+
|
122 |
+
#: classes/class-cartflows-flow-frontend.php:53
|
123 |
+
msgid ""
|
124 |
+
"Test mode is active — which displays random products for previewing. It can "
|
125 |
+
"be deactivated from the flow settings in the admin dashboard."
|
126 |
+
msgstr ""
|
127 |
+
|
128 |
+
#: classes/class-cartflows-flow-frontend.php:58
|
129 |
+
msgid "Click here to disable it"
|
130 |
+
msgstr ""
|
131 |
+
|
132 |
+
#: classes/class-cartflows-importer.php:81
|
133 |
+
msgid "Export this flow"
|
134 |
+
msgstr ""
|
135 |
+
|
136 |
+
#: classes/class-cartflows-importer.php:81 includes/exporter.php:18
|
137 |
+
msgid "Export"
|
138 |
+
msgstr ""
|
139 |
+
|
140 |
+
#: classes/class-cartflows-importer.php:92
|
141 |
+
msgid "Flow Export"
|
142 |
+
msgstr ""
|
143 |
+
|
144 |
+
#: classes/class-cartflows-importer.php:93
|
145 |
+
msgid "Flow Import"
|
146 |
+
msgstr ""
|
147 |
+
|
148 |
+
#: classes/class-cartflows-importer.php:104
|
149 |
+
msgid "No post to export has been supplied!"
|
150 |
+
msgstr ""
|
151 |
+
|
152 |
+
#: classes/class-cartflows-importer.php:295
|
153 |
+
msgid "Please upload a valid .json file"
|
154 |
+
msgstr ""
|
155 |
+
|
156 |
+
#: classes/class-cartflows-importer.php:301
|
157 |
+
msgid "Please upload a file to import"
|
158 |
+
msgstr ""
|
159 |
+
|
160 |
+
#: classes/class-cartflows-importer.php:478
|
161 |
+
msgid "Successfully imported flows."
|
162 |
+
msgstr ""
|
163 |
+
|
164 |
+
#: classes/class-cartflows-importer.php:510
|
165 |
+
msgid "Loading Steps"
|
166 |
+
msgstr ""
|
167 |
+
|
168 |
+
#: classes/class-cartflows-importer.php:512
|
169 |
+
msgid "Getting steps from the cloud. Please wait for the moment."
|
170 |
+
msgstr ""
|
171 |
+
|
172 |
+
#: classes/class-cartflows-importer.php:523
|
173 |
+
msgid "Searching Template.."
|
174 |
+
msgstr ""
|
175 |
+
|
176 |
+
#: classes/class-cartflows-importer.php:525
|
177 |
+
msgid "Getting templates from the cloud. Please wait for the moment."
|
178 |
+
msgstr ""
|
179 |
+
|
180 |
+
#: classes/class-cartflows-importer.php:534
|
181 |
+
msgid "Importing.."
|
182 |
+
msgstr ""
|
183 |
+
|
184 |
+
#: classes/class-cartflows-importer.php:543
|
185 |
+
#: classes/class-cartflows-importer.php:583
|
186 |
+
msgid "Imported"
|
187 |
+
msgstr ""
|
188 |
+
|
189 |
+
#: classes/class-cartflows-importer.php:544
|
190 |
+
#: classes/class-cartflows-importer.php:584
|
191 |
+
msgid "Thanks for patience"
|
192 |
+
msgstr ""
|
193 |
+
|
194 |
+
#: classes/class-cartflows-importer.php:553
|
195 |
+
#: classes/class-cartflows-importer.php:565
|
196 |
+
msgid "Coming Soon!"
|
197 |
+
msgstr ""
|
198 |
+
|
199 |
+
#: classes/class-cartflows-importer.php:584
|
200 |
+
msgid "Redirecting to the Elementor edit window."
|
201 |
+
msgstr ""
|
202 |
+
|
203 |
+
#: classes/class-cartflows-importer.php:630
|
204 |
+
#: classes/class-cartflows-importer.php:746
|
205 |
+
msgid "Pro"
|
206 |
+
msgstr ""
|
207 |
+
|
208 |
+
#: classes/class-cartflows-importer.php:671
|
209 |
+
#: classes/class-cartflows-importer.php:778
|
210 |
+
msgid "Activate License"
|
211 |
+
msgstr ""
|
212 |
+
|
213 |
+
#: classes/class-cartflows-importer.php:673
|
214 |
+
#: classes/class-cartflows-importer.php:780
|
215 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:474
|
216 |
+
msgid "Get Pro"
|
217 |
+
msgstr ""
|
218 |
+
|
219 |
+
#: classes/class-cartflows-importer.php:698
|
220 |
+
msgid "Create"
|
221 |
+
msgstr ""
|
222 |
+
|
223 |
+
#: classes/class-cartflows-importer.php:797
|
224 |
+
msgid "Under Maintenance.."
|
225 |
+
msgstr ""
|
226 |
+
|
227 |
+
#: classes/class-cartflows-importer.php:798
|
228 |
+
msgid ""
|
229 |
+
"If you are seeing this message, most likely our servers are under routine "
|
230 |
+
"maintenance and we will be back shortly."
|
231 |
+
msgstr ""
|
232 |
+
|
233 |
+
#: classes/class-cartflows-importer.php:799
|
234 |
+
msgid ""
|
235 |
+
"In rare case, it is possible your website is having trouble connecting with "
|
236 |
+
"ours. If you need help, please feel free to get in touch with us from our "
|
237 |
+
"website.."
|
238 |
+
msgstr ""
|
239 |
+
|
240 |
+
#: classes/class-cartflows-importer.php:829
|
241 |
+
#. translators: %s: Plugin string
|
242 |
+
msgid ""
|
243 |
+
"%1$s to see CartFlows templates. If you prefer another page builder tool, "
|
244 |
+
"you can <a href=\"%2$s\" target=\"blank\">select it here</a>."
|
245 |
+
msgstr ""
|
246 |
+
|
247 |
+
#: classes/class-cartflows-importer.php:844
|
248 |
+
msgid "All"
|
249 |
+
msgstr ""
|
250 |
+
|
251 |
+
#: classes/class-cartflows-importer.php:847
|
252 |
+
msgid "Select Step Type"
|
253 |
+
msgstr ""
|
254 |
+
|
255 |
+
#: classes/class-cartflows-importer.php:931
|
256 |
+
msgid "Import from Cloud"
|
257 |
+
msgstr ""
|
258 |
+
|
259 |
+
#: classes/class-cartflows-importer.php:1230
|
260 |
+
msgid "Sales Landing"
|
261 |
+
msgstr ""
|
262 |
+
|
263 |
+
#: classes/class-cartflows-importer.php:1234
|
264 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:253
|
265 |
+
#: modules/flow/view/meta-flow-steps.php:12
|
266 |
+
msgid "Checkout (Woo)"
|
267 |
+
msgstr ""
|
268 |
+
|
269 |
+
#: classes/class-cartflows-importer.php:1238
|
270 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:260
|
271 |
+
#: modules/flow/view/meta-flow-steps.php:13
|
272 |
+
msgid "Thank You (Woo)"
|
273 |
+
msgstr ""
|
274 |
+
|
275 |
+
#: classes/class-cartflows-importer.php:1246
|
276 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:239
|
277 |
+
#: modules/flow/view/meta-flow-steps.php:11
|
278 |
+
msgid "Landing"
|
279 |
+
msgstr ""
|
280 |
+
|
281 |
+
#: classes/class-cartflows-importer.php:1250
|
282 |
+
msgid "Thank You"
|
283 |
+
msgstr ""
|
284 |
+
|
285 |
+
#: classes/class-cartflows-importer.php:1360
|
286 |
+
#. translators: %s: template ID
|
287 |
+
msgid "Invalid template id %1$s or post id %2$s."
|
288 |
+
msgstr ""
|
289 |
+
|
290 |
+
#: classes/class-cartflows-importer.php:1422
|
291 |
+
#. translators: %s: flow ID
|
292 |
+
msgid "Invalid flow id %1$s OR step type %2$s."
|
293 |
+
msgstr ""
|
294 |
+
|
295 |
+
#: classes/class-cartflows-importer.php:1547
|
296 |
+
msgid ""
|
297 |
+
"Elementor is not activated. Please activate plugin Elementor Page Builder "
|
298 |
+
"to import the step."
|
299 |
+
msgstr ""
|
300 |
+
|
301 |
+
#: classes/class-cartflows-importer.php:1650
|
302 |
+
msgid "Action failed. Invalid Security Nonce."
|
303 |
+
msgstr ""
|
304 |
+
|
305 |
+
#: classes/class-cartflows-importer.php:1657
|
306 |
+
msgid "User have not plugin install permissions."
|
307 |
+
msgstr ""
|
308 |
+
|
309 |
+
#: classes/class-cartflows-importer.php:1679
|
310 |
+
msgid "Plugin Successfully Activated"
|
311 |
+
msgstr ""
|
312 |
+
|
313 |
+
#: classes/class-cartflows-learndash-compatibility.php:86
|
314 |
+
msgid "None"
|
315 |
+
msgstr ""
|
316 |
+
|
317 |
+
#: classes/class-cartflows-learndash-compatibility.php:113
|
318 |
+
#. translators: 1: anchor start, 2: anchor close
|
319 |
+
msgid ""
|
320 |
+
"Non-enrolled students will redirect to the selected CartFlows template. If "
|
321 |
+
"you have not created any Flow already, add new Flow from %1$shere%2$s."
|
322 |
+
msgstr ""
|
323 |
+
|
324 |
+
#: classes/class-cartflows-learndash-compatibility.php:119
|
325 |
+
msgid "Select CartFlows Template for this Course"
|
326 |
+
msgstr ""
|
327 |
+
|
328 |
+
#: classes/class-cartflows-loader.php:222
|
329 |
+
#. translators: %s: html tags
|
330 |
+
msgid ""
|
331 |
+
"You are using an older version of %1$sCartFlows Pro%2$s. Please update "
|
332 |
+
"%1$sCartFlows Pro%2$s plugin to version %1$s%3$s%2$s or higher."
|
333 |
+
msgstr ""
|
334 |
+
|
335 |
+
#: classes/class-cartflows-loader.php:464
|
336 |
+
#. translators: %s: html tags
|
337 |
+
msgid ""
|
338 |
+
"This %1$sCartFlows%2$s page requires %1$sWooCommerce%2$s plugin installed & "
|
339 |
+
"activated."
|
340 |
+
msgstr ""
|
341 |
+
|
342 |
+
#: classes/class-cartflows-loader.php:474
|
343 |
+
msgid "Activate WooCommerce"
|
344 |
+
msgstr ""
|
345 |
+
|
346 |
+
#: classes/class-cartflows-loader.php:482
|
347 |
+
msgid "Install WooCommerce"
|
348 |
+
msgstr ""
|
349 |
+
|
350 |
+
#: classes/class-cartflows-logger.php:161
|
351 |
+
msgid "Action failed. Please refresh the page and retry."
|
352 |
+
msgstr ""
|
353 |
+
|
354 |
+
#: classes/class-cartflows-meta-fields.php:82
|
355 |
+
msgid "Thin 100"
|
356 |
+
msgstr ""
|
357 |
+
|
358 |
+
#: classes/class-cartflows-meta-fields.php:83
|
359 |
+
msgid "Extra-Light 200"
|
360 |
+
msgstr ""
|
361 |
+
|
362 |
+
#: classes/class-cartflows-meta-fields.php:84
|
363 |
+
msgid "Light 300"
|
364 |
+
msgstr ""
|
365 |
+
|
366 |
+
#: classes/class-cartflows-meta-fields.php:85
|
367 |
+
msgid "Normal 400"
|
368 |
+
msgstr ""
|
369 |
+
|
370 |
+
#: classes/class-cartflows-meta-fields.php:86
|
371 |
+
msgid "Medium 500"
|
372 |
+
msgstr ""
|
373 |
+
|
374 |
+
#: classes/class-cartflows-meta-fields.php:87
|
375 |
+
msgid "Semi-Bold 600"
|
376 |
+
msgstr ""
|
377 |
+
|
378 |
+
#: classes/class-cartflows-meta-fields.php:88
|
379 |
+
msgid "Bold 700"
|
380 |
+
msgstr ""
|
381 |
+
|
382 |
+
#: classes/class-cartflows-meta-fields.php:89
|
383 |
+
msgid "Extra-Bold 800"
|
384 |
+
msgstr ""
|
385 |
+
|
386 |
+
#: classes/class-cartflows-meta-fields.php:90
|
387 |
+
msgid "Ultra-Bold 900"
|
388 |
+
msgstr ""
|
389 |
+
|
390 |
+
#: classes/class-cartflows-meta-fields.php:642
|
391 |
+
#: includes/meta-fields/generate-product-repeater.php:30
|
392 |
+
msgid "Search for a product…"
|
393 |
+
msgstr ""
|
394 |
+
|
395 |
+
#: classes/class-cartflows-meta-fields.php:690
|
396 |
+
msgid "Search for a coupon…"
|
397 |
+
msgstr ""
|
398 |
+
|
399 |
+
#: classes/class-cartflows-meta.php:34
|
400 |
+
msgid "Update"
|
401 |
+
msgstr ""
|
402 |
+
|
403 |
+
#: classes/class-cartflows-meta.php:42
|
404 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:95
|
405 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:733
|
406 |
+
msgid "Back to edit Flow"
|
407 |
+
msgstr ""
|
408 |
+
|
409 |
+
#: classes/class-cartflows-meta.php:63
|
410 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:198
|
411 |
+
#: modules/landing/classes/class-cartflows-landing-meta.php:136
|
412 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:156
|
413 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:154
|
414 |
+
msgid "Custom Script"
|
415 |
+
msgstr ""
|
416 |
+
|
417 |
+
#: classes/class-cartflows-meta.php:66
|
418 |
+
msgid ""
|
419 |
+
"Custom script lets you add your own custom script on front end of this flow "
|
420 |
+
"page."
|
421 |
+
msgstr ""
|
422 |
+
|
423 |
+
#: classes/class-cartflows-metabox.php:59
|
424 |
+
msgid "Flow Details"
|
425 |
+
msgstr ""
|
426 |
+
|
427 |
+
#: classes/class-cartflows-wizard.php:83
|
428 |
+
msgid "Thanks for installing and using CartFlows!"
|
429 |
+
msgstr ""
|
430 |
+
|
431 |
+
#: classes/class-cartflows-wizard.php:84
|
432 |
+
msgid ""
|
433 |
+
"It is easy to use the CartFlows. Please use the setup wizard to quick start "
|
434 |
+
"setup."
|
435 |
+
msgstr ""
|
436 |
+
|
437 |
+
#: classes/class-cartflows-wizard.php:86
|
438 |
+
msgid "Start Wizard"
|
439 |
+
msgstr ""
|
440 |
+
|
441 |
+
#: classes/class-cartflows-wizard.php:87
|
442 |
+
msgid "Skip Setup"
|
443 |
+
msgstr ""
|
444 |
+
|
445 |
+
#: classes/class-cartflows-wizard.php:117
|
446 |
+
#: includes/admin/cartflows-general-bck.php:24
|
447 |
+
msgid "Welcome"
|
448 |
+
msgstr ""
|
449 |
+
|
450 |
+
#: classes/class-cartflows-wizard.php:122
|
451 |
+
msgid "Page Builder"
|
452 |
+
msgstr ""
|
453 |
+
|
454 |
+
#: classes/class-cartflows-wizard.php:126
|
455 |
+
msgid "Checkout"
|
456 |
+
msgstr ""
|
457 |
+
|
458 |
+
#: classes/class-cartflows-wizard.php:130
|
459 |
+
msgid "Training"
|
460 |
+
msgstr ""
|
461 |
+
|
462 |
+
#: classes/class-cartflows-wizard.php:134
|
463 |
+
msgid "Ready!"
|
464 |
+
msgstr ""
|
465 |
+
|
466 |
+
#: classes/class-cartflows-wizard.php:209
|
467 |
+
msgid "CartFlows Setup"
|
468 |
+
msgstr ""
|
469 |
+
|
470 |
+
#: classes/class-cartflows-wizard.php:235
|
471 |
+
msgid "Exit Setup Wizard"
|
472 |
+
msgstr ""
|
473 |
+
|
474 |
+
#: classes/class-cartflows-wizard.php:288
|
475 |
+
msgid "Welcome to CartFlows!"
|
476 |
+
msgstr ""
|
477 |
+
|
478 |
+
#: classes/class-cartflows-wizard.php:289
|
479 |
+
msgid ""
|
480 |
+
"Thank you for choosing CartFlows to get more leads, increase conversions, & "
|
481 |
+
"maximize profits. This short setup wizard will guide you though configuring "
|
482 |
+
"CartFlows and creating your first funnel."
|
483 |
+
msgstr ""
|
484 |
+
|
485 |
+
#: classes/class-cartflows-wizard.php:295
|
486 |
+
msgid "Lets Go »"
|
487 |
+
msgstr ""
|
488 |
+
|
489 |
+
#: classes/class-cartflows-wizard.php:322
|
490 |
+
msgid "Page Builder Setup"
|
491 |
+
msgstr ""
|
492 |
+
|
493 |
+
#: classes/class-cartflows-wizard.php:323
|
494 |
+
msgid "Please select a page builder you would like to use with CartFlows."
|
495 |
+
msgstr ""
|
496 |
+
|
497 |
+
#: classes/class-cartflows-wizard.php:328
|
498 |
+
msgid "Select Page Builder"
|
499 |
+
msgstr ""
|
500 |
+
|
501 |
+
#: classes/class-cartflows-wizard.php:335
|
502 |
+
#: includes/admin/cartflows-general.php:94
|
503 |
+
msgid "Elementor"
|
504 |
+
msgstr ""
|
505 |
+
|
506 |
+
#: classes/class-cartflows-wizard.php:345
|
507 |
+
msgid "Beaver Builder Plugin (Lite Version)"
|
508 |
+
msgstr ""
|
509 |
+
|
510 |
+
#: classes/class-cartflows-wizard.php:355
|
511 |
+
#: includes/admin/cartflows-general.php:96
|
512 |
+
msgid "Divi"
|
513 |
+
msgstr ""
|
514 |
+
|
515 |
+
#: classes/class-cartflows-wizard.php:365
|
516 |
+
#: includes/admin/cartflows-general.php:97
|
517 |
+
msgid "Other"
|
518 |
+
msgstr ""
|
519 |
+
|
520 |
+
#: classes/class-cartflows-wizard.php:387
|
521 |
+
msgid ""
|
522 |
+
"While CartFlows Should work with most page builders, we offer templates for "
|
523 |
+
"the above page builders."
|
524 |
+
msgstr ""
|
525 |
+
|
526 |
+
#: classes/class-cartflows-wizard.php:390
|
527 |
+
#: classes/class-cartflows-wizard.php:435
|
528 |
+
#: classes/class-cartflows-wizard.php:622
|
529 |
+
msgid "« Previous"
|
530 |
+
msgstr ""
|
531 |
+
|
532 |
+
#: classes/class-cartflows-wizard.php:393
|
533 |
+
msgid "Skip this step"
|
534 |
+
msgstr ""
|
535 |
+
|
536 |
+
#: classes/class-cartflows-wizard.php:394
|
537 |
+
msgid "Next »"
|
538 |
+
msgstr ""
|
539 |
+
|
540 |
+
#: classes/class-cartflows-wizard.php:413
|
541 |
+
msgid "Choose a checkout"
|
542 |
+
msgstr ""
|
543 |
+
|
544 |
+
#: classes/class-cartflows-wizard.php:416
|
545 |
+
msgid ""
|
546 |
+
"While CartFlows is designed to use WooCommerce sell digital and physical "
|
547 |
+
"products, not all funnels need a checkout system."
|
548 |
+
msgstr ""
|
549 |
+
|
550 |
+
#: classes/class-cartflows-wizard.php:418
|
551 |
+
msgid ""
|
552 |
+
"Would you like to install WooCommerce to sell digital and physical products "
|
553 |
+
"in your funnels?"
|
554 |
+
msgstr ""
|
555 |
+
|
556 |
+
#: classes/class-cartflows-wizard.php:425
|
557 |
+
msgid "The following plugin will be installed and activated for you:"
|
558 |
+
msgstr ""
|
559 |
+
|
560 |
+
#: classes/class-cartflows-wizard.php:426
|
561 |
+
msgid "WooCommerce"
|
562 |
+
msgstr ""
|
563 |
+
|
564 |
+
#: classes/class-cartflows-wizard.php:427
|
565 |
+
msgid "WooCommerce Cart Abandonment Recovery"
|
566 |
+
msgstr ""
|
567 |
+
|
568 |
+
#: classes/class-cartflows-wizard.php:438
|
569 |
+
#: classes/class-cartflows-wizard.php:625
|
570 |
+
msgid "No thanks"
|
571 |
+
msgstr ""
|
572 |
+
|
573 |
+
#: classes/class-cartflows-wizard.php:439
|
574 |
+
msgid "Yes"
|
575 |
+
msgstr ""
|
576 |
+
|
577 |
+
#: classes/class-cartflows-wizard.php:558
|
578 |
+
msgid "Congratulations, You Did It!"
|
579 |
+
msgstr ""
|
580 |
+
|
581 |
+
#: classes/class-cartflows-wizard.php:565
|
582 |
+
msgid ""
|
583 |
+
"CartFlows is ready to use on your website. You've successfully completed "
|
584 |
+
"the setup process and all that is left for you to do is create your first "
|
585 |
+
"flow."
|
586 |
+
msgstr ""
|
587 |
+
|
588 |
+
#: classes/class-cartflows-wizard.php:579
|
589 |
+
msgid "Create a flow"
|
590 |
+
msgstr ""
|
591 |
+
|
592 |
+
#: classes/class-cartflows-wizard.php:596
|
593 |
+
msgid "Exclusive CartFlows Training Course Offer"
|
594 |
+
msgstr ""
|
595 |
+
|
596 |
+
#: classes/class-cartflows-wizard.php:607
|
597 |
+
msgid ""
|
598 |
+
"We want you to get off to a great start using CartFlows, so we would like "
|
599 |
+
"to give access to our exclusive training course."
|
600 |
+
msgstr ""
|
601 |
+
|
602 |
+
#: classes/class-cartflows-wizard.php:608
|
603 |
+
msgid "Get access to this couse, for free, by entering your email below."
|
604 |
+
msgstr ""
|
605 |
+
|
606 |
+
#: classes/class-cartflows-wizard.php:610
|
607 |
+
msgid "Enter Email address"
|
608 |
+
msgstr ""
|
609 |
+
|
610 |
+
#: classes/class-cartflows-wizard.php:626
|
611 |
+
msgid "Allow"
|
612 |
+
msgstr ""
|
613 |
+
|
614 |
+
#: classes/logger/class-cartflows-log-handler-file.php:351
|
615 |
+
#: classes/logger/class-cartflows-log-handler-file.php:371
|
616 |
+
msgid "This method should not be called before plugins_loaded."
|
617 |
+
msgstr ""
|
618 |
+
|
619 |
+
#: classes/logger/class-cartflows-wc-logger.php:58
|
620 |
+
#. translators: 1: class name 2: Cartflows_Log_Handler_Interface
|
621 |
+
msgid "The provided handler %1$s does not implement %2$s."
|
622 |
+
msgstr ""
|
623 |
+
|
624 |
+
#: classes/logger/class-cartflows-wc-logger.php:136
|
625 |
+
#. translators: 1: Cartflows_WC_Logger::log 2: level
|
626 |
+
msgid "%1$s was called with an invalid level \"%2$s\"."
|
627 |
+
msgstr ""
|
628 |
+
|
629 |
+
#: includes/admin/cartflows-admin.php:19
|
630 |
+
#: includes/admin/cartflows-general.php:48
|
631 |
+
msgid "Modernizing WordPress eCommerce!"
|
632 |
+
msgstr ""
|
633 |
+
|
634 |
+
#: includes/admin/cartflows-admin.php:29
|
635 |
+
msgid "Settings saved successfully."
|
636 |
+
msgstr ""
|
637 |
+
|
638 |
+
#: includes/admin/cartflows-error-log.php:36
|
639 |
+
msgid "%1$s at %2$s"
|
640 |
+
msgstr ""
|
641 |
+
|
642 |
+
#: includes/admin/cartflows-error-log.php:41
|
643 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:225
|
644 |
+
#: modules/flow/view/meta-flow-steps.php:104
|
645 |
+
msgid "View"
|
646 |
+
msgstr ""
|
647 |
+
|
648 |
+
#: includes/admin/cartflows-error-log.php:65
|
649 |
+
msgid "Delete log"
|
650 |
+
msgstr ""
|
651 |
+
|
652 |
+
#: includes/admin/cartflows-error-log.php:70
|
653 |
+
msgid "There are currently no logs to view."
|
654 |
+
msgstr ""
|
655 |
+
|
656 |
+
#: includes/admin/cartflows-general-bck.php:10
|
657 |
+
msgid "Selec"
|
658 |
+
msgstr ""
|
659 |
+
|
660 |
+
#: includes/admin/cartflows-general-bck.php:22
|
661 |
+
msgid "General"
|
662 |
+
msgstr ""
|
663 |
+
|
664 |
+
#: includes/admin/cartflows-general.php:31
|
665 |
+
#: includes/admin/cartflows-general.php:58
|
666 |
+
msgid "General Settings"
|
667 |
+
msgstr ""
|
668 |
+
|
669 |
+
#: includes/admin/cartflows-general.php:40
|
670 |
+
msgid "Getting Started"
|
671 |
+
msgstr ""
|
672 |
+
|
673 |
+
#: includes/admin/cartflows-general.php:71
|
674 |
+
msgid "Disallow search engines from indexing flows"
|
675 |
+
msgstr ""
|
676 |
+
|
677 |
+
#: includes/admin/cartflows-general.php:81
|
678 |
+
#: modules/flow/view/meta-flow-steps.php:93
|
679 |
+
msgid "Global Checkout"
|
680 |
+
msgstr ""
|
681 |
+
|
682 |
+
#: includes/admin/cartflows-general.php:90
|
683 |
+
msgid "Show Templates designed with"
|
684 |
+
msgstr ""
|
685 |
+
|
686 |
+
#: includes/admin/cartflows-general.php:91
|
687 |
+
msgid ""
|
688 |
+
"CartFlows offers flow templates that can be imported in one click. These "
|
689 |
+
"templates are available in few different page builders. Please choose your "
|
690 |
+
"preferred page builder from the list so you will only see templates that "
|
691 |
+
"are made using that page builder.."
|
692 |
+
msgstr ""
|
693 |
+
|
694 |
+
#: includes/admin/cartflows-general.php:95
|
695 |
+
msgid "Beaver Builder"
|
696 |
+
msgstr ""
|
697 |
+
|
698 |
+
#: includes/admin/cartflows-general.php:106
|
699 |
+
#: includes/admin/cartflows-general.php:190
|
700 |
+
#: includes/admin/cartflows-general.php:296
|
701 |
+
#: includes/admin/cartflows-general.php:413
|
702 |
+
msgid "Save Changes"
|
703 |
+
msgstr ""
|
704 |
+
|
705 |
+
#: includes/admin/cartflows-general.php:116
|
706 |
+
msgid "Permalink Settings"
|
707 |
+
msgstr ""
|
708 |
+
|
709 |
+
#: includes/admin/cartflows-general.php:131
|
710 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:647
|
711 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:380
|
712 |
+
msgid "Default"
|
713 |
+
msgstr ""
|
714 |
+
|
715 |
+
#: includes/admin/cartflows-general.php:137
|
716 |
+
msgid "Flow and Step Slug"
|
717 |
+
msgstr ""
|
718 |
+
|
719 |
+
#: includes/admin/cartflows-general.php:143
|
720 |
+
msgid "Flow Slug"
|
721 |
+
msgstr ""
|
722 |
+
|
723 |
+
#: includes/admin/cartflows-general.php:149
|
724 |
+
msgid "Step Slug"
|
725 |
+
msgstr ""
|
726 |
+
|
727 |
+
#: includes/admin/cartflows-general.php:161
|
728 |
+
msgid "Post Type Permalink Base"
|
729 |
+
msgstr ""
|
730 |
+
|
731 |
+
#: includes/admin/cartflows-general.php:169
|
732 |
+
msgid "Step Base"
|
733 |
+
msgstr ""
|
734 |
+
|
735 |
+
#: includes/admin/cartflows-general.php:179
|
736 |
+
msgid "Flow Base"
|
737 |
+
msgstr ""
|
738 |
+
|
739 |
+
#: includes/admin/cartflows-general.php:191
|
740 |
+
msgid "Set Default"
|
741 |
+
msgstr ""
|
742 |
+
|
743 |
+
#: includes/admin/cartflows-general.php:205
|
744 |
+
msgid "Facebook Pixel Settings"
|
745 |
+
msgstr ""
|
746 |
+
|
747 |
+
#: includes/admin/cartflows-general.php:220
|
748 |
+
msgid "Enable Facebook Pixel Tracking"
|
749 |
+
msgstr ""
|
750 |
+
|
751 |
+
#: includes/admin/cartflows-general.php:233
|
752 |
+
msgid "Enable for the whole site"
|
753 |
+
msgstr ""
|
754 |
+
|
755 |
+
#: includes/admin/cartflows-general.php:241
|
756 |
+
#: includes/admin/cartflows-general.php:340
|
757 |
+
msgid "If this option is unchecked, it will only apply to CartFlows steps."
|
758 |
+
msgstr ""
|
759 |
+
|
760 |
+
#: includes/admin/cartflows-general.php:251
|
761 |
+
msgid "Enter Facebook pixel ID"
|
762 |
+
msgstr ""
|
763 |
+
|
764 |
+
#: includes/admin/cartflows-general.php:259
|
765 |
+
#: includes/admin/cartflows-general.php:358
|
766 |
+
msgid "Enable Events:"
|
767 |
+
msgstr ""
|
768 |
+
|
769 |
+
#: includes/admin/cartflows-general.php:268
|
770 |
+
msgid "Initiate Checkout"
|
771 |
+
msgstr ""
|
772 |
+
|
773 |
+
#: includes/admin/cartflows-general.php:277
|
774 |
+
#: includes/admin/cartflows-general.php:384
|
775 |
+
msgid "Add Payment Info"
|
776 |
+
msgstr ""
|
777 |
+
|
778 |
+
#: includes/admin/cartflows-general.php:286
|
779 |
+
msgid "Purchase Complete"
|
780 |
+
msgstr ""
|
781 |
+
|
782 |
+
#: includes/admin/cartflows-general.php:308
|
783 |
+
msgid "Google Analytics Settings"
|
784 |
+
msgstr ""
|
785 |
+
|
786 |
+
#: includes/admin/cartflows-general.php:319
|
787 |
+
msgid "Enable Google Analytics Tracking"
|
788 |
+
msgstr ""
|
789 |
+
|
790 |
+
#: includes/admin/cartflows-general.php:332
|
791 |
+
msgid "Enable for the whole website"
|
792 |
+
msgstr ""
|
793 |
+
|
794 |
+
#: includes/admin/cartflows-general.php:350
|
795 |
+
msgid "Google Analytics ID"
|
796 |
+
msgstr ""
|
797 |
+
|
798 |
+
#: includes/admin/cartflows-general.php:352
|
799 |
+
msgid ""
|
800 |
+
"Log into your <a href=\"https://analytics.google.com/\" "
|
801 |
+
"target=\"_blank\">google analytics account</a> to find your ID. eg: "
|
802 |
+
"UA-XXXXXX-X."
|
803 |
+
msgstr ""
|
804 |
+
|
805 |
+
#: includes/admin/cartflows-general.php:366
|
806 |
+
msgid "Begin Checkout"
|
807 |
+
msgstr ""
|
808 |
+
|
809 |
+
#: includes/admin/cartflows-general.php:375
|
810 |
+
msgid "Add To Cart"
|
811 |
+
msgstr ""
|
812 |
+
|
813 |
+
#: includes/admin/cartflows-general.php:393
|
814 |
+
msgid "Purchase"
|
815 |
+
msgstr ""
|
816 |
+
|
817 |
+
#: includes/admin/cartflows-general.php:401
|
818 |
+
msgid ""
|
819 |
+
"Google Analytics not working correctly? <a "
|
820 |
+
"href=\"https://cartflows.com/docs/troubleshooting-google-analytics-tracking-"
|
821 |
+
"issues/\" > Click here </a> to know more. "
|
822 |
+
msgstr ""
|
823 |
+
|
824 |
+
#: includes/admin/cartflows-general.php:434
|
825 |
+
msgid "Knowledge Base"
|
826 |
+
msgstr ""
|
827 |
+
|
828 |
+
#: includes/admin/cartflows-general.php:438
|
829 |
+
msgid "Not sure how something works? Take a peek at the knowledge base and learn."
|
830 |
+
msgstr ""
|
831 |
+
|
832 |
+
#: includes/admin/cartflows-general.php:441
|
833 |
+
msgid "Visit Knowledge Base »"
|
834 |
+
msgstr ""
|
835 |
+
|
836 |
+
#: includes/admin/cartflows-general.php:449
|
837 |
+
msgid "Community"
|
838 |
+
msgstr ""
|
839 |
+
|
840 |
+
#: includes/admin/cartflows-general.php:453
|
841 |
+
msgid ""
|
842 |
+
"Join the community of super helpful CartFlows users. Say hello, ask "
|
843 |
+
"questions, give feedback and help each other!"
|
844 |
+
msgstr ""
|
845 |
+
|
846 |
+
#: includes/admin/cartflows-general.php:456
|
847 |
+
msgid "Join Our Facebook Group »"
|
848 |
+
msgstr ""
|
849 |
+
|
850 |
+
#: includes/admin/cartflows-general.php:464
|
851 |
+
msgid "Five Star Support"
|
852 |
+
msgstr ""
|
853 |
+
|
854 |
+
#: includes/admin/cartflows-general.php:468
|
855 |
+
msgid "Got a question? Get in touch with CartFlows developers. We're happy to help!"
|
856 |
+
msgstr ""
|
857 |
+
|
858 |
+
#: includes/admin/cartflows-general.php:471
|
859 |
+
msgid "Submit a Ticket »"
|
860 |
+
msgstr ""
|
861 |
+
|
862 |
+
#: includes/admin/cartflows-general.php:481
|
863 |
+
msgid "Load Minified CSS"
|
864 |
+
msgstr ""
|
865 |
+
|
866 |
+
#: includes/admin/cartflows-general.php:486
|
867 |
+
msgid ""
|
868 |
+
"Load the Minified CSS from here. Just Enable it by checking the below given "
|
869 |
+
"checkbox."
|
870 |
+
msgstr ""
|
871 |
+
|
872 |
+
#: includes/admin/cartflows-general.php:493
|
873 |
+
msgid "Load minified CSS & JS Files"
|
874 |
+
msgstr ""
|
875 |
+
|
876 |
+
#: includes/admin/cartflows-general.php:498
|
877 |
+
msgid "Save"
|
878 |
+
msgstr ""
|
879 |
+
|
880 |
+
#: includes/exporter.php:12
|
881 |
+
msgid "Export Flows to a JSON file"
|
882 |
+
msgstr ""
|
883 |
+
|
884 |
+
#: includes/exporter.php:13
|
885 |
+
msgid ""
|
886 |
+
"This tool allows you to generate and download a JSON file containing a list "
|
887 |
+
"of all flows."
|
888 |
+
msgstr ""
|
889 |
+
|
890 |
+
#: includes/importer.php:12
|
891 |
+
msgid "Import Flows to a JSON file"
|
892 |
+
msgstr ""
|
893 |
+
|
894 |
+
#: includes/importer.php:13
|
895 |
+
msgid "This tool allows you to import the flows from the JSON file."
|
896 |
+
msgstr ""
|
897 |
+
|
898 |
+
#: includes/importer.php:21
|
899 |
+
msgid "Import"
|
900 |
+
msgstr ""
|
901 |
+
|
902 |
+
#: includes/meta-fields/generate-product-repeater.php:36
|
903 |
+
msgid "Remove"
|
904 |
+
msgstr ""
|
905 |
+
|
906 |
+
#: includes/meta-fields/generate-product-repeater.php:51
|
907 |
+
msgid "Product Quantity"
|
908 |
+
msgstr ""
|
909 |
+
|
910 |
+
#: includes/meta-fields/generate-product-repeater.php:65
|
911 |
+
msgid "Discount Type"
|
912 |
+
msgstr ""
|
913 |
+
|
914 |
+
#: includes/meta-fields/generate-product-repeater.php:69
|
915 |
+
msgid "Select Discount Type"
|
916 |
+
msgstr ""
|
917 |
+
|
918 |
+
#: includes/meta-fields/generate-product-repeater.php:70
|
919 |
+
msgid "Original"
|
920 |
+
msgstr ""
|
921 |
+
|
922 |
+
#: includes/meta-fields/generate-product-repeater.php:71
|
923 |
+
msgid "Percentage"
|
924 |
+
msgstr ""
|
925 |
+
|
926 |
+
#: includes/meta-fields/generate-product-repeater.php:72
|
927 |
+
msgid "Price"
|
928 |
+
msgstr ""
|
929 |
+
|
930 |
+
#: includes/meta-fields/generate-product-repeater.php:83
|
931 |
+
msgid "Discount Value"
|
932 |
+
msgstr ""
|
933 |
+
|
934 |
+
#: includes/meta-fields/generate-product-repeater.php:85
|
935 |
+
msgid "Discount value will apply for each quantity of product."
|
936 |
+
msgstr ""
|
937 |
+
|
938 |
+
#: includes/meta-fields/get-product-selection-repeater.php:112
|
939 |
+
msgid "Add New Product"
|
940 |
+
msgstr ""
|
941 |
+
|
942 |
+
#: includes/meta-fields/get-product-selection-repeater.php:113
|
943 |
+
msgid "Create Product"
|
944 |
+
msgstr ""
|
945 |
+
|
946 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:256
|
947 |
+
#: modules/optin/classes/class-cartflows-optin-markup.php:146
|
948 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-markup.php:90
|
949 |
+
msgid ""
|
950 |
+
"WooCommerce functions do not exist. If you are in an IFrame, please reload "
|
951 |
+
"it."
|
952 |
+
msgstr ""
|
953 |
+
|
954 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:257
|
955 |
+
#: modules/optin/classes/class-cartflows-optin-markup.php:147
|
956 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-markup.php:91
|
957 |
+
msgid "Click Here to Reload"
|
958 |
+
msgstr ""
|
959 |
+
|
960 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:275
|
961 |
+
msgid "Checkout ID not found"
|
962 |
+
msgstr ""
|
963 |
+
|
964 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:338
|
965 |
+
#: modules/checkout/templates/embed/checkout-template-simple.php:25
|
966 |
+
#: modules/checkout/templates/wcf-template.php:36
|
967 |
+
#: modules/optin/templates/optin-template-simple.php:25
|
968 |
+
msgid "Your cart is currently empty."
|
969 |
+
msgstr ""
|
970 |
+
|
971 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:404
|
972 |
+
msgid ""
|
973 |
+
"No product is selected. Please select products from the checkout meta "
|
974 |
+
"settings to continue."
|
975 |
+
msgstr ""
|
976 |
+
|
977 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:493
|
978 |
+
msgid "Variations Not set"
|
979 |
+
msgstr ""
|
980 |
+
|
981 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:501
|
982 |
+
msgid "This product can't be purchased"
|
983 |
+
msgstr ""
|
984 |
+
|
985 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:946
|
986 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:989
|
987 |
+
msgid "Coupon Code"
|
988 |
+
msgstr ""
|
989 |
+
|
990 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:947
|
991 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:998
|
992 |
+
msgid "Apply"
|
993 |
+
msgstr ""
|
994 |
+
|
995 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:1154
|
996 |
+
msgid "Sorry there was a problem removing this coupon."
|
997 |
+
msgstr ""
|
998 |
+
|
999 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:1157
|
1000 |
+
msgid "Coupon has been removed."
|
1001 |
+
msgstr ""
|
1002 |
+
|
1003 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:1176
|
1004 |
+
msgid "Sorry there was a problem removing "
|
1005 |
+
msgstr ""
|
1006 |
+
|
1007 |
+
#: modules/checkout/classes/class-cartflows-checkout-markup.php:1179
|
1008 |
+
msgid " has been removed."
|
1009 |
+
msgstr ""
|
1010 |
+
|
1011 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:65
|
1012 |
+
msgid "Checkout Layout"
|
1013 |
+
msgstr ""
|
1014 |
+
|
1015 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:150
|
1016 |
+
#: modules/landing/classes/class-cartflows-landing-meta.php:130
|
1017 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:126
|
1018 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:130
|
1019 |
+
msgid "Shortcodes"
|
1020 |
+
msgstr ""
|
1021 |
+
|
1022 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:156
|
1023 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:132
|
1024 |
+
msgid "Select Product"
|
1025 |
+
msgstr ""
|
1026 |
+
|
1027 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:162
|
1028 |
+
msgid "Product Options"
|
1029 |
+
msgstr ""
|
1030 |
+
|
1031 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:168
|
1032 |
+
msgid "Order Bump"
|
1033 |
+
msgstr ""
|
1034 |
+
|
1035 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:174
|
1036 |
+
msgid "Checkout Offer"
|
1037 |
+
msgstr ""
|
1038 |
+
|
1039 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:180
|
1040 |
+
msgid "Checkout Design"
|
1041 |
+
msgstr ""
|
1042 |
+
|
1043 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:186
|
1044 |
+
msgid "Checkout Fields"
|
1045 |
+
msgstr ""
|
1046 |
+
|
1047 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:192
|
1048 |
+
msgid "Checkout Settings"
|
1049 |
+
msgstr ""
|
1050 |
+
|
1051 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:209
|
1052 |
+
msgid "Logo (Optional)"
|
1053 |
+
msgstr ""
|
1054 |
+
|
1055 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:270
|
1056 |
+
#. translators: %s: link
|
1057 |
+
msgid "Upgrade to %1$sCartFlows Pro%2$s for Product Options feature."
|
1058 |
+
msgstr ""
|
1059 |
+
|
1060 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:281
|
1061 |
+
#. translators: %s: link.
|
1062 |
+
msgid "Update %1$sCartFlows Pro%2$s to %3$s or above for Product Options"
|
1063 |
+
msgstr ""
|
1064 |
+
|
1065 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:309
|
1066 |
+
msgid "Add this shortcode to your checkout page"
|
1067 |
+
msgstr ""
|
1068 |
+
|
1069 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:345
|
1070 |
+
#. translators: %s: link
|
1071 |
+
msgid "Upgrade to %1$sCartFlows Pro%2$s for Pre-applied Coupon."
|
1072 |
+
msgstr ""
|
1073 |
+
|
1074 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:372
|
1075 |
+
#. translators: %s: link
|
1076 |
+
msgid "Upgrade to %1$sCartFlows Pro%2$s for Checkout Offer feature"
|
1077 |
+
msgstr ""
|
1078 |
+
|
1079 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:382
|
1080 |
+
#. translators: %s: link
|
1081 |
+
msgid "Update to %1$sCartFlows Pro%2$s to %3$s or above for Checkout Offer feature"
|
1082 |
+
msgstr ""
|
1083 |
+
|
1084 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:409
|
1085 |
+
#. translators: %s: link
|
1086 |
+
msgid "Upgrade to %1$sCartFlows Pro%2$s for animate browser tab feature"
|
1087 |
+
msgstr ""
|
1088 |
+
|
1089 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:419
|
1090 |
+
#. translators: %s: link
|
1091 |
+
msgid ""
|
1092 |
+
"Update to %1$sCartFlows Pro%2$s to %3$s or above for animate browser tab "
|
1093 |
+
"feature"
|
1094 |
+
msgstr ""
|
1095 |
+
|
1096 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:442
|
1097 |
+
#. translators: %s: link
|
1098 |
+
msgid "Upgrade to %1$sCartFlows Pro%2$s for Order Bump feature."
|
1099 |
+
msgstr ""
|
1100 |
+
|
1101 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:469
|
1102 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:267
|
1103 |
+
#. translators: %s: link
|
1104 |
+
msgid "Upgrade to %1$sCartFlows Pro%2$s for Custom Fields feature."
|
1105 |
+
msgstr ""
|
1106 |
+
|
1107 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:492
|
1108 |
+
msgid "Place Order Button Text"
|
1109 |
+
msgstr ""
|
1110 |
+
|
1111 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:496
|
1112 |
+
msgid "Place order"
|
1113 |
+
msgstr ""
|
1114 |
+
|
1115 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:498
|
1116 |
+
msgid "It will change the Place Order Button text on checkout page."
|
1117 |
+
msgstr ""
|
1118 |
+
|
1119 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:508
|
1120 |
+
msgid "Enable cart editing on checkout"
|
1121 |
+
msgstr ""
|
1122 |
+
|
1123 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:516
|
1124 |
+
#. translators: %s: link
|
1125 |
+
msgid "Users will able to remove products from the checkout page."
|
1126 |
+
msgstr ""
|
1127 |
+
|
1128 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:546
|
1129 |
+
msgid "One Column (Available in CartFlows Pro) "
|
1130 |
+
msgstr ""
|
1131 |
+
|
1132 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:547
|
1133 |
+
msgid "Two Step (Available in CartFlows Pro) "
|
1134 |
+
msgstr ""
|
1135 |
+
|
1136 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:553
|
1137 |
+
msgid "Checkout Skin"
|
1138 |
+
msgstr ""
|
1139 |
+
|
1140 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:557
|
1141 |
+
msgid "One Column"
|
1142 |
+
msgstr ""
|
1143 |
+
|
1144 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:558
|
1145 |
+
msgid "Two Column"
|
1146 |
+
msgstr ""
|
1147 |
+
|
1148 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:559
|
1149 |
+
msgid "Two Step"
|
1150 |
+
msgstr ""
|
1151 |
+
|
1152 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:568
|
1153 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:343
|
1154 |
+
msgid "Primary Color"
|
1155 |
+
msgstr ""
|
1156 |
+
|
1157 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:577
|
1158 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:612
|
1159 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:658
|
1160 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:750
|
1161 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:352
|
1162 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:391
|
1163 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:503
|
1164 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:209
|
1165 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:240
|
1166 |
+
msgid "Font Family"
|
1167 |
+
msgstr ""
|
1168 |
+
|
1169 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:585
|
1170 |
+
msgid "Advance Options"
|
1171 |
+
msgstr ""
|
1172 |
+
|
1173 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:597
|
1174 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:225
|
1175 |
+
msgid "Heading"
|
1176 |
+
msgstr ""
|
1177 |
+
|
1178 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:603
|
1179 |
+
msgid "Heading Color"
|
1180 |
+
msgstr ""
|
1181 |
+
|
1182 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:621
|
1183 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:667
|
1184 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:759
|
1185 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:400
|
1186 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:512
|
1187 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:249
|
1188 |
+
msgid "Font Weight"
|
1189 |
+
msgstr ""
|
1190 |
+
|
1191 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:629
|
1192 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:363
|
1193 |
+
msgid "Input Fields"
|
1194 |
+
msgstr ""
|
1195 |
+
|
1196 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:637
|
1197 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:370
|
1198 |
+
msgid "Floating Labels (Available in CartFlows Pro)"
|
1199 |
+
msgstr ""
|
1200 |
+
|
1201 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:643
|
1202 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:376
|
1203 |
+
msgid "Style"
|
1204 |
+
msgstr ""
|
1205 |
+
|
1206 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:648
|
1207 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:381
|
1208 |
+
msgid "Floating Labels"
|
1209 |
+
msgstr ""
|
1210 |
+
|
1211 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:675
|
1212 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:767
|
1213 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:408
|
1214 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:520
|
1215 |
+
msgid "Size"
|
1216 |
+
msgstr ""
|
1217 |
+
|
1218 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:679
|
1219 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:771
|
1220 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:412
|
1221 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:524
|
1222 |
+
msgid "Extra Small"
|
1223 |
+
msgstr ""
|
1224 |
+
|
1225 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:680
|
1226 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:772
|
1227 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:413
|
1228 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:525
|
1229 |
+
msgid "Small"
|
1230 |
+
msgstr ""
|
1231 |
+
|
1232 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:681
|
1233 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:773
|
1234 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:414
|
1235 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:526
|
1236 |
+
msgid "Medium"
|
1237 |
+
msgstr ""
|
1238 |
+
|
1239 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:682
|
1240 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:774
|
1241 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:415
|
1242 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:527
|
1243 |
+
msgid "Large"
|
1244 |
+
msgstr ""
|
1245 |
+
|
1246 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:683
|
1247 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:775
|
1248 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:416
|
1249 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:528
|
1250 |
+
msgid "Extra Large"
|
1251 |
+
msgstr ""
|
1252 |
+
|
1253 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:684
|
1254 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:776
|
1255 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:417
|
1256 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:529
|
1257 |
+
msgid "Custom"
|
1258 |
+
msgstr ""
|
1259 |
+
|
1260 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:691
|
1261 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:783
|
1262 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:424
|
1263 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:536
|
1264 |
+
msgid "Top Bottom Spacing"
|
1265 |
+
msgstr ""
|
1266 |
+
|
1267 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:699
|
1268 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:791
|
1269 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:432
|
1270 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:544
|
1271 |
+
msgid "Left Right Spacing"
|
1272 |
+
msgstr ""
|
1273 |
+
|
1274 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:707
|
1275 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:448
|
1276 |
+
msgid "Text / Placeholder Color"
|
1277 |
+
msgstr ""
|
1278 |
+
|
1279 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:715
|
1280 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:815
|
1281 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:456
|
1282 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:581
|
1283 |
+
msgid "Background Color"
|
1284 |
+
msgstr ""
|
1285 |
+
|
1286 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:723
|
1287 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:831
|
1288 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:464
|
1289 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:597
|
1290 |
+
msgid "Border Color"
|
1291 |
+
msgstr ""
|
1292 |
+
|
1293 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:730
|
1294 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:440
|
1295 |
+
msgid "Label Color"
|
1296 |
+
msgstr ""
|
1297 |
+
|
1298 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:743
|
1299 |
+
msgid "Buttons"
|
1300 |
+
msgstr ""
|
1301 |
+
|
1302 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:799
|
1303 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:565
|
1304 |
+
msgid "Text Color"
|
1305 |
+
msgstr ""
|
1306 |
+
|
1307 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:807
|
1308 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:573
|
1309 |
+
msgid "Text Hover Color"
|
1310 |
+
msgstr ""
|
1311 |
+
|
1312 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:823
|
1313 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:589
|
1314 |
+
msgid "Background Hover Color"
|
1315 |
+
msgstr ""
|
1316 |
+
|
1317 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:839
|
1318 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:605
|
1319 |
+
msgid "Border Hover Color"
|
1320 |
+
msgstr ""
|
1321 |
+
|
1322 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:852
|
1323 |
+
msgid "Sections"
|
1324 |
+
msgstr ""
|
1325 |
+
|
1326 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:858
|
1327 |
+
msgid "Highlight Area Background Color"
|
1328 |
+
msgstr ""
|
1329 |
+
|
1330 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:897
|
1331 |
+
msgid "Header Logo"
|
1332 |
+
msgstr ""
|
1333 |
+
|
1334 |
+
#: modules/checkout/classes/class-cartflows-checkout-meta.php:905
|
1335 |
+
msgid "Logo Width (In px)"
|
1336 |
+
msgstr ""
|
1337 |
+
|
1338 |
+
#: modules/checkout/templates/wcf-template.php:46
|
1339 |
+
msgid "Copyright ©"
|
1340 |
+
msgstr ""
|
1341 |
+
|
1342 |
+
#: modules/checkout/templates/wcf-template.php:50
|
1343 |
+
msgid "All Rights Reserved"
|
1344 |
+
msgstr ""
|
1345 |
+
|
1346 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:263
|
1347 |
+
#. translators: %s flow id
|
1348 |
+
msgid "Step not deleted for flow - %s"
|
1349 |
+
msgstr ""
|
1350 |
+
|
1351 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:294
|
1352 |
+
#. translators: %s flow id
|
1353 |
+
msgid "Step deleted for flow - %s"
|
1354 |
+
msgstr ""
|
1355 |
+
|
1356 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:322
|
1357 |
+
#. translators: %s flow id
|
1358 |
+
msgid "Steps not sorted for flow - %s"
|
1359 |
+
msgstr ""
|
1360 |
+
|
1361 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:345
|
1362 |
+
#. translators: %s flow id
|
1363 |
+
msgid "Steps sorted for flow - %s"
|
1364 |
+
msgstr ""
|
1365 |
+
|
1366 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:456
|
1367 |
+
msgid "Analytics"
|
1368 |
+
msgstr ""
|
1369 |
+
|
1370 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:473
|
1371 |
+
#. translators: %s: link
|
1372 |
+
msgid "Upgrade to %1$sCartFlows Pro%2$s for Analytics feature"
|
1373 |
+
msgstr ""
|
1374 |
+
|
1375 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:491
|
1376 |
+
msgid "Flow Settings"
|
1377 |
+
msgstr ""
|
1378 |
+
|
1379 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:576
|
1380 |
+
msgid "Enable Test Mode"
|
1381 |
+
msgstr ""
|
1382 |
+
|
1383 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:583
|
1384 |
+
msgid ""
|
1385 |
+
"If you are using WooCommerce plugin then test mode will add random products "
|
1386 |
+
"in your flow, so you can preview it easily while testing."
|
1387 |
+
msgstr ""
|
1388 |
+
|
1389 |
+
#: modules/flow/classes/class-cartflows-flow-meta.php:702
|
1390 |
+
#: modules/flow/view/meta-flow-steps.php:133
|
1391 |
+
msgid "Add New Step"
|
1392 |
+
msgstr ""
|
1393 |
+
|
1394 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:69
|
1395 |
+
msgid "Flow: "
|
1396 |
+
msgstr ""
|
1397 |
+
|
1398 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:69
|
1399 |
+
msgid "Name: "
|
1400 |
+
msgstr ""
|
1401 |
+
|
1402 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:101
|
1403 |
+
msgid "Search Flows"
|
1404 |
+
msgstr ""
|
1405 |
+
|
1406 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:102
|
1407 |
+
msgid "All Flows"
|
1408 |
+
msgstr ""
|
1409 |
+
|
1410 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:103
|
1411 |
+
msgid "Edit Flow"
|
1412 |
+
msgstr ""
|
1413 |
+
|
1414 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:104
|
1415 |
+
msgid "View Flow"
|
1416 |
+
msgstr ""
|
1417 |
+
|
1418 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:105
|
1419 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:107
|
1420 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:167
|
1421 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:169
|
1422 |
+
msgid "Add New"
|
1423 |
+
msgstr ""
|
1424 |
+
|
1425 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:106
|
1426 |
+
msgid "Update Flow"
|
1427 |
+
msgstr ""
|
1428 |
+
|
1429 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:108
|
1430 |
+
msgid "New Flow Name"
|
1431 |
+
msgstr ""
|
1432 |
+
|
1433 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:190
|
1434 |
+
msgid "Upgrade to CartFlows Pro"
|
1435 |
+
msgstr ""
|
1436 |
+
|
1437 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:209
|
1438 |
+
msgid "Slug"
|
1439 |
+
msgstr ""
|
1440 |
+
|
1441 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:332
|
1442 |
+
msgid "Flows"
|
1443 |
+
msgstr ""
|
1444 |
+
|
1445 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:354
|
1446 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:360
|
1447 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:397
|
1448 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:403
|
1449 |
+
#. translators: %s: singular custom post type name
|
1450 |
+
msgid "%s updated."
|
1451 |
+
msgstr ""
|
1452 |
+
|
1453 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:356
|
1454 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:399
|
1455 |
+
#. translators: %s: singular custom post type name
|
1456 |
+
msgid "Custom %s updated."
|
1457 |
+
msgstr ""
|
1458 |
+
|
1459 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:358
|
1460 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:401
|
1461 |
+
#. translators: %s: singular custom post type name
|
1462 |
+
msgid "Custom %s deleted."
|
1463 |
+
msgstr ""
|
1464 |
+
|
1465 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:362
|
1466 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:405
|
1467 |
+
#. translators: %1$s: singular custom post type name ,%2$s: date and time of
|
1468 |
+
#. the revision
|
1469 |
+
msgid "%1$s restored to revision from %2$s"
|
1470 |
+
msgstr ""
|
1471 |
+
|
1472 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:364
|
1473 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:407
|
1474 |
+
#. translators: %s: singular custom post type name
|
1475 |
+
msgid "%s published."
|
1476 |
+
msgstr ""
|
1477 |
+
|
1478 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:366
|
1479 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:409
|
1480 |
+
#. translators: %s: singular custom post type name
|
1481 |
+
msgid "%s saved."
|
1482 |
+
msgstr ""
|
1483 |
+
|
1484 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:368
|
1485 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:411
|
1486 |
+
#. translators: %s: singular custom post type name
|
1487 |
+
msgid "%s submitted."
|
1488 |
+
msgstr ""
|
1489 |
+
|
1490 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:370
|
1491 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:413
|
1492 |
+
#. translators: %s: singular custom post type name
|
1493 |
+
msgid "%s scheduled for."
|
1494 |
+
msgstr ""
|
1495 |
+
|
1496 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:372
|
1497 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:415
|
1498 |
+
#. translators: %s: singular custom post type name
|
1499 |
+
msgid "%s draft updated."
|
1500 |
+
msgstr ""
|
1501 |
+
|
1502 |
+
#: modules/flow/classes/class-cartflows-flow-shortcodes.php:148
|
1503 |
+
#: modules/widgets/class-cartflows-next-step.php:78
|
1504 |
+
msgid "Next Step"
|
1505 |
+
msgstr ""
|
1506 |
+
|
1507 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:163
|
1508 |
+
msgid "Search Steps"
|
1509 |
+
msgstr ""
|
1510 |
+
|
1511 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:164
|
1512 |
+
msgid "All Steps"
|
1513 |
+
msgstr ""
|
1514 |
+
|
1515 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:165
|
1516 |
+
#: modules/flow/view/meta-flow-steps.php:106
|
1517 |
+
msgid "Edit Step"
|
1518 |
+
msgstr ""
|
1519 |
+
|
1520 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:166
|
1521 |
+
#: modules/flow/view/meta-flow-steps.php:102
|
1522 |
+
msgid "View Step"
|
1523 |
+
msgstr ""
|
1524 |
+
|
1525 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:168
|
1526 |
+
msgid "Update Step"
|
1527 |
+
msgstr ""
|
1528 |
+
|
1529 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:170
|
1530 |
+
msgid "New Step Name"
|
1531 |
+
msgstr ""
|
1532 |
+
|
1533 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:211
|
1534 |
+
msgid "Step Type"
|
1535 |
+
msgstr ""
|
1536 |
+
|
1537 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:221
|
1538 |
+
msgid "Step Flow"
|
1539 |
+
msgstr ""
|
1540 |
+
|
1541 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:246
|
1542 |
+
#: modules/flow/view/meta-flow-steps.php:16
|
1543 |
+
msgid "Optin (Woo)"
|
1544 |
+
msgstr ""
|
1545 |
+
|
1546 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:267
|
1547 |
+
#: modules/flow/view/meta-flow-steps.php:14
|
1548 |
+
msgid "Upsell (Woo)"
|
1549 |
+
msgstr ""
|
1550 |
+
|
1551 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:274
|
1552 |
+
#: modules/flow/view/meta-flow-steps.php:15
|
1553 |
+
msgid "Downsell (Woo)"
|
1554 |
+
msgstr ""
|
1555 |
+
|
1556 |
+
#: modules/flow/view/meta-flow-steps.php:85
|
1557 |
+
msgid "No Product Assigned"
|
1558 |
+
msgstr ""
|
1559 |
+
|
1560 |
+
#: modules/flow/view/meta-flow-steps.php:89
|
1561 |
+
msgid "Global Checkout - Remove selected checkout product"
|
1562 |
+
msgstr ""
|
1563 |
+
|
1564 |
+
#: modules/flow/view/meta-flow-steps.php:108
|
1565 |
+
msgid "Edit"
|
1566 |
+
msgstr ""
|
1567 |
+
|
1568 |
+
#: modules/flow/view/meta-flow-steps.php:113
|
1569 |
+
msgid "Clone Step"
|
1570 |
+
msgstr ""
|
1571 |
+
|
1572 |
+
#: modules/flow/view/meta-flow-steps.php:118
|
1573 |
+
msgid "Delete Step"
|
1574 |
+
msgstr ""
|
1575 |
+
|
1576 |
+
#: modules/flow/view/meta-flow-steps.php:120
|
1577 |
+
msgid "Delete"
|
1578 |
+
msgstr ""
|
1579 |
+
|
1580 |
+
#: modules/flow/view/meta-flow-steps.php:149
|
1581 |
+
msgid "Steps Library"
|
1582 |
+
msgstr ""
|
1583 |
+
|
1584 |
+
#: modules/flow/view/meta-flow-steps.php:198
|
1585 |
+
msgid "Create Step"
|
1586 |
+
msgstr ""
|
1587 |
+
|
1588 |
+
#: modules/flow/view/meta-flow-steps.php:200
|
1589 |
+
msgid "You need a Cartflows Pro version to import Upsell / Downsell"
|
1590 |
+
msgstr ""
|
1591 |
+
|
1592 |
+
#: modules/landing/classes/class-cartflows-landing-meta.php:66
|
1593 |
+
msgid "Landing Page Settings"
|
1594 |
+
msgstr ""
|
1595 |
+
|
1596 |
+
#: modules/landing/classes/class-cartflows-landing-meta.php:169
|
1597 |
+
msgid "Next Step Link"
|
1598 |
+
msgstr ""
|
1599 |
+
|
1600 |
+
#: modules/optin/classes/class-cartflows-optin-markup.php:165
|
1601 |
+
msgid "Please place shortcode on Optin step-type only."
|
1602 |
+
msgstr ""
|
1603 |
+
|
1604 |
+
#: modules/optin/classes/class-cartflows-optin-markup.php:225
|
1605 |
+
msgid ""
|
1606 |
+
"No product is selected. Please select a Simple, Virtual and Free product "
|
1607 |
+
"from the meta settings."
|
1608 |
+
msgstr ""
|
1609 |
+
|
1610 |
+
#: modules/optin/classes/class-cartflows-optin-markup.php:242
|
1611 |
+
msgid "Please update the selected product's price to zero (0)."
|
1612 |
+
msgstr ""
|
1613 |
+
|
1614 |
+
#: modules/optin/classes/class-cartflows-optin-markup.php:251
|
1615 |
+
#: modules/optin/classes/class-cartflows-optin-markup.php:255
|
1616 |
+
msgid "Please select a Simple, Virtual and Free product."
|
1617 |
+
msgstr ""
|
1618 |
+
|
1619 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:65
|
1620 |
+
msgid "Optin Settings"
|
1621 |
+
msgstr ""
|
1622 |
+
|
1623 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:138
|
1624 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:136
|
1625 |
+
msgid "Design"
|
1626 |
+
msgstr ""
|
1627 |
+
|
1628 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:144
|
1629 |
+
msgid "Form Fields"
|
1630 |
+
msgstr ""
|
1631 |
+
|
1632 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:213
|
1633 |
+
msgid "Add this shortcode to your optin page"
|
1634 |
+
msgstr ""
|
1635 |
+
|
1636 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:238
|
1637 |
+
msgid "Select Free Product"
|
1638 |
+
msgstr ""
|
1639 |
+
|
1640 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:239
|
1641 |
+
msgid "Select Free and Virtual product only."
|
1642 |
+
msgstr ""
|
1643 |
+
|
1644 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:290
|
1645 |
+
msgid "Pass Fields as URL Parameters"
|
1646 |
+
msgstr ""
|
1647 |
+
|
1648 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:293
|
1649 |
+
msgid "Enable"
|
1650 |
+
msgstr ""
|
1651 |
+
|
1652 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:294
|
1653 |
+
msgid ""
|
1654 |
+
"You can pass specific fields from the form to next step as URL query "
|
1655 |
+
"parameters."
|
1656 |
+
msgstr ""
|
1657 |
+
|
1658 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:305
|
1659 |
+
msgid "Enter form field"
|
1660 |
+
msgstr ""
|
1661 |
+
|
1662 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:308
|
1663 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:318
|
1664 |
+
msgid "Enter comma seprated field name. E.g. first_name, last_name"
|
1665 |
+
msgstr ""
|
1666 |
+
|
1667 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:310
|
1668 |
+
msgid "Fields to pass, separated by commas"
|
1669 |
+
msgstr ""
|
1670 |
+
|
1671 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:320
|
1672 |
+
#. translators: %s: link
|
1673 |
+
msgid ""
|
1674 |
+
"You can pass field value as a URL parameter to the next step. %1$sClick "
|
1675 |
+
"here%2$s for more information."
|
1676 |
+
msgstr ""
|
1677 |
+
|
1678 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:477
|
1679 |
+
msgid "Submit Button"
|
1680 |
+
msgstr ""
|
1681 |
+
|
1682 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:483
|
1683 |
+
msgid "Button Text"
|
1684 |
+
msgstr ""
|
1685 |
+
|
1686 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:494
|
1687 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:217
|
1688 |
+
msgid "Font Size"
|
1689 |
+
msgstr ""
|
1690 |
+
|
1691 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:552
|
1692 |
+
msgid "Position"
|
1693 |
+
msgstr ""
|
1694 |
+
|
1695 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:556
|
1696 |
+
msgid "Left"
|
1697 |
+
msgstr ""
|
1698 |
+
|
1699 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:557
|
1700 |
+
msgid "Center"
|
1701 |
+
msgstr ""
|
1702 |
+
|
1703 |
+
#: modules/optin/classes/class-cartflows-optin-meta.php:558
|
1704 |
+
msgid "Right"
|
1705 |
+
msgstr ""
|
1706 |
+
|
1707 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:65
|
1708 |
+
msgid "Thank You Page Settings"
|
1709 |
+
msgstr ""
|
1710 |
+
|
1711 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:142
|
1712 |
+
msgid "Edit Fields"
|
1713 |
+
msgstr ""
|
1714 |
+
|
1715 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:182
|
1716 |
+
msgid "Order Details"
|
1717 |
+
msgstr ""
|
1718 |
+
|
1719 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:194
|
1720 |
+
msgid "Text"
|
1721 |
+
msgstr ""
|
1722 |
+
|
1723 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:200
|
1724 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:231
|
1725 |
+
msgid "Color"
|
1726 |
+
msgstr ""
|
1727 |
+
|
1728 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:257
|
1729 |
+
msgid "Advanced Options"
|
1730 |
+
msgstr ""
|
1731 |
+
|
1732 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:267
|
1733 |
+
msgid "Container Width (In px)"
|
1734 |
+
msgstr ""
|
1735 |
+
|
1736 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:275
|
1737 |
+
msgid "Section Background Color"
|
1738 |
+
msgstr ""
|
1739 |
+
|
1740 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:289
|
1741 |
+
msgid "Enable Order Overview "
|
1742 |
+
msgstr ""
|
1743 |
+
|
1744 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:297
|
1745 |
+
msgid "Enable Order Details "
|
1746 |
+
msgstr ""
|
1747 |
+
|
1748 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:305
|
1749 |
+
msgid "Enable Billing Details "
|
1750 |
+
msgstr ""
|
1751 |
+
|
1752 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:313
|
1753 |
+
msgid "Enable Shipping Details "
|
1754 |
+
msgstr ""
|
1755 |
+
|
1756 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:329
|
1757 |
+
msgid "Thank You Page Text"
|
1758 |
+
msgstr ""
|
1759 |
+
|
1760 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:333
|
1761 |
+
#: woocommerce/template/checkout/thankyou.php:41
|
1762 |
+
#: woocommerce/template/checkout/thankyou.php:83
|
1763 |
+
msgid "Thank you. Your order has been received."
|
1764 |
+
msgstr ""
|
1765 |
+
|
1766 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:335
|
1767 |
+
msgid "It will change the default text on thank you page."
|
1768 |
+
msgstr ""
|
1769 |
+
|
1770 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:343
|
1771 |
+
msgid "Redirect After Purchase"
|
1772 |
+
msgstr ""
|
1773 |
+
|
1774 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:352
|
1775 |
+
msgid "Redirect Link"
|
1776 |
+
msgstr ""
|
1777 |
+
|
1778 |
+
#: modules/thankyou/classes/class-cartflows-thankyou-meta.php:356
|
1779 |
+
msgid "https://"
|
1780 |
+
msgstr ""
|
1781 |
+
|
1782 |
+
#: modules/widgets/class-cartflows-next-step.php:24
|
1783 |
+
msgid "CartFlows Next Step"
|
1784 |
+
msgstr ""
|
1785 |
+
|
1786 |
+
#: modules/widgets/class-cartflows-next-step.php:26
|
1787 |
+
msgid "Next Step Widgets"
|
1788 |
+
msgstr ""
|
1789 |
+
|
1790 |
+
#: modules/widgets/class-cartflows-next-step.php:106
|
1791 |
+
msgid "New title"
|
1792 |
+
msgstr ""
|
1793 |
+
|
1794 |
+
#: modules/widgets/class-cartflows-next-step.php:123
|
1795 |
+
msgid "Title:"
|
1796 |
+
msgstr ""
|
1797 |
+
|
1798 |
+
#: modules/widgets/class-cartflows-next-step.php:127
|
1799 |
+
msgid "Flow ID:"
|
1800 |
+
msgstr ""
|
1801 |
+
|
1802 |
+
#: modules/widgets/class-cartflows-next-step.php:131
|
1803 |
+
msgid "Step ID:"
|
1804 |
+
msgstr ""
|
1805 |
+
|
1806 |
+
#: woocommerce/template/cart/cart-shipping.php:51
|
1807 |
+
#. Translators: $s shipping destination.
|
1808 |
+
msgid "Estimate for %s."
|
1809 |
+
msgstr ""
|
1810 |
+
|
1811 |
+
#: woocommerce/template/cart/cart-shipping.php:52
|
1812 |
+
msgid "Change address"
|
1813 |
+
msgstr ""
|
1814 |
+
|
1815 |
+
#: woocommerce/template/cart/cart-shipping.php:54
|
1816 |
+
msgid "This is only an estimate. Prices will be updated during checkout."
|
1817 |
+
msgstr ""
|
1818 |
+
|
1819 |
+
#: woocommerce/template/cart/cart-shipping.php:61
|
1820 |
+
msgid "Enter your address to view shipping options."
|
1821 |
+
msgstr ""
|
1822 |
+
|
1823 |
+
#: woocommerce/template/cart/cart-shipping.php:63
|
1824 |
+
msgid ""
|
1825 |
+
"There are no shipping methods available. Please ensure that your address "
|
1826 |
+
"has been entered correctly, or contact us if you need any help."
|
1827 |
+
msgstr ""
|
1828 |
+
|
1829 |
+
#: woocommerce/template/cart/cart-shipping.php:66
|
1830 |
+
#. Translators: $s shipping destination.
|
1831 |
+
msgid "No shipping options were found for %s."
|
1832 |
+
msgstr ""
|
1833 |
+
|
1834 |
+
#: woocommerce/template/cart/cart-shipping.php:67
|
1835 |
+
msgid "Enter a different address"
|
1836 |
+
msgstr ""
|
1837 |
+
|
1838 |
+
#: woocommerce/template/checkout/form-billing.php:27
|
1839 |
+
msgid "Billing & Shipping"
|
1840 |
+
msgstr ""
|
1841 |
+
|
1842 |
+
#: woocommerce/template/checkout/form-billing.php:31
|
1843 |
+
msgid "Billing details"
|
1844 |
+
msgstr ""
|
1845 |
+
|
1846 |
+
#: woocommerce/template/checkout/form-billing.php:59
|
1847 |
+
msgid "Create an account?"
|
1848 |
+
msgstr ""
|
1849 |
+
|
1850 |
+
#: woocommerce/template/checkout/form-checkout.php:26
|
1851 |
+
msgid "You must be logged in to checkout."
|
1852 |
+
msgstr ""
|
1853 |
+
|
1854 |
+
#: woocommerce/template/checkout/form-checkout.php:52
|
1855 |
+
msgid "Your order"
|
1856 |
+
msgstr ""
|
1857 |
+
|
1858 |
+
#: woocommerce/template/checkout/form-coupon.php:26
|
1859 |
+
msgid "Have a coupon?"
|
1860 |
+
msgstr ""
|
1861 |
+
|
1862 |
+
#: woocommerce/template/checkout/form-coupon.php:26
|
1863 |
+
msgid "Click here to enter your code"
|
1864 |
+
msgstr ""
|
1865 |
+
|
1866 |
+
#: woocommerce/template/checkout/form-coupon.php:31
|
1867 |
+
msgid "If you have a coupon code, please apply it below."
|
1868 |
+
msgstr ""
|
1869 |
+
|
1870 |
+
#: woocommerce/template/checkout/form-coupon.php:34
|
1871 |
+
msgid "Coupon code"
|
1872 |
+
msgstr ""
|
1873 |
+
|
1874 |
+
#: woocommerce/template/checkout/form-coupon.php:38
|
1875 |
+
msgid "Apply coupon"
|
1876 |
+
msgstr ""
|
1877 |
+
|
1878 |
+
#: woocommerce/template/checkout/form-login.php:26
|
1879 |
+
msgid "Returning customer?"
|
1880 |
+
msgstr ""
|
1881 |
+
|
1882 |
+
#: woocommerce/template/checkout/form-login.php:26
|
1883 |
+
msgid "Click here to login"
|
1884 |
+
msgstr ""
|
1885 |
+
|
1886 |
+
#: woocommerce/template/checkout/form-login.php:32
|
1887 |
+
msgid ""
|
1888 |
+
"If you have shopped with us before, please enter your details below. If you "
|
1889 |
+
"are a new customer, please proceed to the Billing & Shipping section."
|
1890 |
+
msgstr ""
|
1891 |
+
|
1892 |
+
#: woocommerce/template/checkout/form-shipping.php:26
|
1893 |
+
msgid "Ship to a different address?"
|
1894 |
+
msgstr ""
|
1895 |
+
|
1896 |
+
#: woocommerce/template/checkout/form-shipping.php:57
|
1897 |
+
msgid "Additional information"
|
1898 |
+
msgstr ""
|
1899 |
+
|
1900 |
+
#: woocommerce/template/checkout/payment.php:33
|
1901 |
+
msgid ""
|
1902 |
+
"Sorry, it seems that there are no available payment methods for your state. "
|
1903 |
+
"Please contact us if you require assistance or wish to make alternate "
|
1904 |
+
"arrangements."
|
1905 |
+
msgstr ""
|
1906 |
+
|
1907 |
+
#: woocommerce/template/checkout/payment.php:33
|
1908 |
+
msgid "Please fill in your details above to see available payment methods."
|
1909 |
+
msgstr ""
|
1910 |
+
|
1911 |
+
#: woocommerce/template/checkout/payment.php:42
|
1912 |
+
#. translators: $1 and $2 opening and closing emphasis tags respectively
|
1913 |
+
msgid ""
|
1914 |
+
"Since your browser does not support JavaScript, or it is disabled, please "
|
1915 |
+
"ensure you click the %1$sUpdate Totals%2$s button before placing your "
|
1916 |
+
"order. You may be charged more than the amount stated above if you fail to "
|
1917 |
+
"do so."
|
1918 |
+
msgstr ""
|
1919 |
+
|
1920 |
+
#: woocommerce/template/checkout/payment.php:44
|
1921 |
+
msgid "Update totals"
|
1922 |
+
msgstr ""
|
1923 |
+
|
1924 |
+
#: woocommerce/template/checkout/review-order.php:26
|
1925 |
+
#: woocommerce/template/order/order-details.php:51
|
1926 |
+
msgid "Product"
|
1927 |
+
msgstr ""
|
1928 |
+
|
1929 |
+
#: woocommerce/template/checkout/review-order.php:27
|
1930 |
+
#: woocommerce/template/checkout/review-order.php:107
|
1931 |
+
#: woocommerce/template/order/order-details.php:52
|
1932 |
+
msgid "Total"
|
1933 |
+
msgstr ""
|
1934 |
+
|
1935 |
+
#: woocommerce/template/checkout/review-order.php:60
|
1936 |
+
msgid "Subtotal"
|
1937 |
+
msgstr ""
|
1938 |
+
|
1939 |
+
#: woocommerce/template/checkout/thankyou.php:30
|
1940 |
+
msgid ""
|
1941 |
+
"Unfortunately your order cannot be processed as the originating "
|
1942 |
+
"bank/merchant has declined your transaction. Please attempt your purchase "
|
1943 |
+
"again."
|
1944 |
+
msgstr ""
|
1945 |
+
|
1946 |
+
#: woocommerce/template/checkout/thankyou.php:33
|
1947 |
+
msgid "Pay"
|
1948 |
+
msgstr ""
|
1949 |
+
|
1950 |
+
#: woocommerce/template/checkout/thankyou.php:35
|
1951 |
+
msgid "My account"
|
1952 |
+
msgstr ""
|
1953 |
+
|
1954 |
+
#: woocommerce/template/checkout/thankyou.php:46
|
1955 |
+
msgid "Order number:"
|
1956 |
+
msgstr ""
|
1957 |
+
|
1958 |
+
#: woocommerce/template/checkout/thankyou.php:51
|
1959 |
+
msgid "Date:"
|
1960 |
+
msgstr ""
|
1961 |
+
|
1962 |
+
#: woocommerce/template/checkout/thankyou.php:57
|
1963 |
+
msgid "Email:"
|
1964 |
+
msgstr ""
|
1965 |
+
|
1966 |
+
#: woocommerce/template/checkout/thankyou.php:63
|
1967 |
+
msgid "Total:"
|
1968 |
+
msgstr ""
|
1969 |
+
|
1970 |
+
#: woocommerce/template/checkout/thankyou.php:69
|
1971 |
+
msgid "Payment method:"
|
1972 |
+
msgstr ""
|
1973 |
+
|
1974 |
+
#: woocommerce/template/global/form-login.php:34
|
1975 |
+
msgid "Username or email"
|
1976 |
+
msgstr ""
|
1977 |
+
|
1978 |
+
#: woocommerce/template/global/form-login.php:38
|
1979 |
+
msgid "Password"
|
1980 |
+
msgstr ""
|
1981 |
+
|
1982 |
+
#: woocommerce/template/global/form-login.php:48
|
1983 |
+
msgid "Login"
|
1984 |
+
msgstr ""
|
1985 |
+
|
1986 |
+
#: woocommerce/template/global/form-login.php:53
|
1987 |
+
msgid "Remember me"
|
1988 |
+
msgstr ""
|
1989 |
+
|
1990 |
+
#: woocommerce/template/global/form-login.php:57
|
1991 |
+
msgid "Lost your password?"
|
1992 |
+
msgstr ""
|
1993 |
+
|
1994 |
+
#: woocommerce/template/order/order-details.php:45
|
1995 |
+
msgid "Order details"
|
1996 |
+
msgstr ""
|
1997 |
+
|
1998 |
+
#: woocommerce/template/order/order-details.php:93
|
1999 |
+
msgid "Note:"
|
2000 |
+
msgstr ""
|
2001 |
+
|
2002 |
+
#. Plugin Name of the plugin/theme
|
2003 |
+
msgid "CartFlows"
|
2004 |
+
msgstr ""
|
2005 |
+
|
2006 |
+
#. Author URI of the plugin/theme
|
2007 |
+
msgid "https://cartflows.com/"
|
2008 |
+
msgstr ""
|
2009 |
+
|
2010 |
+
#. Description of the plugin/theme
|
2011 |
+
msgid "Create beautiful checkout pages & sales flows for WooCommerce."
|
2012 |
+
msgstr ""
|
2013 |
+
|
2014 |
+
#. Author of the plugin/theme
|
2015 |
+
msgid "CartFlows Inc"
|
2016 |
+
msgstr ""
|
2017 |
+
|
2018 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:99
|
2019 |
+
msgctxt "flow general name"
|
2020 |
+
msgid "Flows"
|
2021 |
+
msgstr ""
|
2022 |
+
|
2023 |
+
#: modules/flow/classes/class-cartflows-flow-post-type.php:100
|
2024 |
+
msgctxt "flow singular name"
|
2025 |
+
msgid "Flow"
|
2026 |
+
msgstr ""
|
2027 |
+
|
2028 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:161
|
2029 |
+
msgctxt "flow step general name"
|
2030 |
+
msgid "Steps"
|
2031 |
+
msgstr ""
|
2032 |
+
|
2033 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:162
|
2034 |
+
msgctxt "flow step singular name"
|
2035 |
+
msgid "Step"
|
2036 |
+
msgstr ""
|
2037 |
+
|
2038 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:315
|
2039 |
+
msgctxt "cartflows"
|
2040 |
+
msgid "CartFlows — Boxed"
|
2041 |
+
msgstr ""
|
2042 |
+
|
2043 |
+
#: modules/flow/classes/class-cartflows-step-post-type.php:316
|
2044 |
+
msgctxt "cartflows"
|
2045 |
+
msgid "Template for Page Builders"
|
2046 |
msgstr ""
|
modules/checkout/classes/class-cartflows-checkout-markup.php
CHANGED
@@ -1,1158 +1,1260 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Checkout markup.
|
4 |
-
*
|
5 |
-
* @package CartFlows
|
6 |
-
*/
|
7 |
-
|
8 |
-
/**
|
9 |
-
* Checkout Markup
|
10 |
-
*
|
11 |
-
* @since 1.0.0
|
12 |
-
*/
|
13 |
-
class Cartflows_Checkout_Markup {
|
14 |
-
|
15 |
-
/**
|
16 |
-
* Member Variable
|
17 |
-
*
|
18 |
-
* @var object instance
|
19 |
-
*/
|
20 |
-
private static $instance;
|
21 |
-
|
22 |
-
/**
|
23 |
-
* Initiator
|
24 |
-
*/
|
25 |
-
public static function get_instance() {
|
26 |
-
if ( ! isset( self::$instance ) ) {
|
27 |
-
self::$instance = new self();
|
28 |
-
}
|
29 |
-
return self::$instance;
|
30 |
-
}
|
31 |
-
|
32 |
-
/**
|
33 |
-
* Constructor
|
34 |
-
*/
|
35 |
-
public function __construct() {
|
36 |
-
|
37 |
-
/* Set is checkout flag */
|
38 |
-
add_filter( 'woocommerce_is_checkout', array( $this, 'woo_checkout_flag' ), 9999 );
|
39 |
-
|
40 |
-
add_action( 'woocommerce_checkout_update_order_meta', array( $this, 'save_checkout_fields' ), 10, 2 );
|
41 |
-
|
42 |
-
/* Show notice if cart is empty */
|
43 |
-
add_action( 'cartflows_checkout_cart_empty', array( $this, 'display_woo_notices' ) );
|
44 |
-
|
45 |
-
/* Checkout Shortcode */
|
46 |
-
add_shortcode( 'cartflows_checkout', array( $this, 'checkout_shortcode_markup' ) );
|
47 |
-
|
48 |
-
/* Preconfigured cart data */
|
49 |
-
add_action( 'wp', array( $this, 'preconfigured_cart_data' ), 1 );
|
50 |
-
|
51 |
-
/* Embed Checkout */
|
52 |
-
add_action( 'wp', array( $this, 'shortcode_load_data' ), 999 );
|
53 |
-
|
54 |
-
/* Ajax Endpoint */
|
55 |
-
add_filter( 'woocommerce_ajax_get_endpoint', array( $this, 'get_ajax_endpoint' ), 10, 2 );
|
56 |
-
|
57 |
-
add_filter( 'cartflows_add_before_main_section', array( $this, 'enable_logo_in_header' ) );
|
58 |
-
|
59 |
-
add_filter( 'cartflows_primary_container_bottom', array( $this, 'show_cartflows_copyright_message' ) );
|
60 |
-
|
61 |
-
add_filter( 'woocommerce_login_redirect', array( $this, 'after_login_redirect' ), 10, 2 );
|
62 |
-
|
63 |
-
add_action( 'wp_ajax_wcf_woo_apply_coupon', array( $this, 'apply_coupon' ) );
|
64 |
-
add_action( 'wp_ajax_nopriv_wcf_woo_apply_coupon', array( $this, 'apply_coupon' ) );
|
65 |
-
|
66 |
-
add_filter( 'global_cartflows_js_localize', array( $this, 'add_localize_vars' ) );
|
67 |
-
|
68 |
-
/* Global Checkout */
|
69 |
-
add_action( 'template_redirect', array( $this, 'global_checkout_template_redirect' ), 1 );
|
70 |
-
|
71 |
-
add_action( 'wp_ajax_wcf_woo_remove_coupon', array( $this, 'remove_coupon' ) );
|
72 |
-
add_action( 'wp_ajax_nopriv_wcf_woo_remove_coupon', array( $this, 'remove_coupon' ) );
|
73 |
-
|
74 |
-
add_action( 'wp_ajax_wcf_woo_remove_cart_product', array( $this, 'wcf_woo_remove_cart_product' ) );
|
75 |
-
add_action( 'wp_ajax_nopriv_wcf_woo_remove_cart_product', array( $this, 'wcf_woo_remove_cart_product' ) );
|
76 |
-
|
77 |
-
add_filter( 'woocommerce_paypal_args', array( $this, 'modify_paypal_args' ), 10, 2 );
|
78 |
-
|
79 |
-
add_filter( 'woocommerce_cart_item_name', array( $this, 'wcf_add_remove_label' ), 10, 3 );
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
*
|
86 |
-
*
|
87 |
-
* @
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
*
|
107 |
-
*
|
108 |
-
* @param string $
|
109 |
-
* @
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
|
141 |
-
|
142 |
-
*
|
143 |
-
*
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
|
164 |
-
*
|
165 |
-
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
*
|
178 |
-
|
179 |
-
|
180 |
-
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
-
|
192 |
-
|
193 |
-
|
194 |
-
|
195 |
-
|
196 |
-
|
197 |
-
|
198 |
-
$
|
199 |
-
|
200 |
-
$
|
201 |
-
|
202 |
-
|
203 |
-
|
204 |
-
|
205 |
-
|
206 |
-
// ignore on
|
207 |
-
false === wcf_mb_strpos( esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ), '/' . $
|
208 |
-
// ignore
|
209 |
-
false === wcf_mb_strpos( esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ), $
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
*
|
229 |
-
*
|
230 |
-
* @
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
|
236 |
-
|
237 |
-
|
238 |
-
|
239 |
-
|
240 |
-
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
*
|
249 |
-
*
|
250 |
-
|
251 |
-
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
|
257 |
-
|
258 |
-
|
259 |
-
|
260 |
-
|
261 |
-
|
262 |
-
|
263 |
-
|
264 |
-
|
265 |
-
|
266 |
-
|
267 |
-
|
268 |
-
|
269 |
-
|
270 |
-
|
271 |
-
|
272 |
-
|
273 |
-
|
274 |
-
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
|
280 |
-
|
281 |
-
|
282 |
-
|
283 |
-
|
284 |
-
|
285 |
-
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
-
$
|
290 |
-
|
291 |
-
$
|
292 |
-
|
293 |
-
|
294 |
-
|
295 |
-
|
296 |
-
include $
|
297 |
-
}
|
298 |
-
|
299 |
-
|
300 |
-
|
301 |
-
|
302 |
-
|
303 |
-
|
304 |
-
|
305 |
-
|
306 |
-
|
307 |
-
*
|
308 |
-
*
|
309 |
-
* @
|
310 |
-
|
311 |
-
|
312 |
-
|
313 |
-
|
314 |
-
|
315 |
-
|
316 |
-
|
317 |
-
|
318 |
-
|
319 |
-
|
320 |
-
|
321 |
-
|
322 |
-
|
323 |
-
|
324 |
-
|
325 |
-
|
326 |
-
|
327 |
-
|
328 |
-
$checkout_id =
|
329 |
-
}
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
338 |
-
|
339 |
-
|
340 |
-
|
341 |
-
|
342 |
-
|
343 |
-
|
344 |
-
|
345 |
-
|
346 |
-
|
347 |
-
|
348 |
-
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
$products =
|
354 |
-
}
|
355 |
-
|
356 |
-
|
357 |
-
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
'
|
364 |
-
'
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
'
|
370 |
-
|
371 |
-
|
372 |
-
|
373 |
-
|
374 |
-
|
375 |
-
|
376 |
-
'
|
377 |
-
|
378 |
-
|
379 |
-
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
393 |
-
|
394 |
-
|
395 |
-
|
396 |
-
|
397 |
-
|
398 |
-
|
399 |
-
|
400 |
-
|
401 |
-
|
402 |
-
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
|
411 |
-
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
|
418 |
-
|
419 |
-
|
420 |
-
|
421 |
-
|
422 |
-
|
423 |
-
|
424 |
-
|
425 |
-
if (
|
426 |
-
|
427 |
-
|
428 |
-
|
429 |
-
|
430 |
-
|
431 |
-
|
432 |
-
|
433 |
-
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
|
444 |
-
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
|
455 |
-
|
456 |
-
|
457 |
-
|
458 |
-
|
459 |
-
|
460 |
-
|
461 |
-
|
462 |
-
|
463 |
-
|
464 |
-
|
465 |
-
|
466 |
-
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
|
473 |
-
|
474 |
-
|
475 |
-
|
476 |
-
|
477 |
-
|
478 |
-
|
479 |
-
|
480 |
-
|
481 |
-
|
482 |
-
|
483 |
-
|
484 |
-
|
485 |
-
|
486 |
-
|
487 |
-
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
|
495 |
-
|
496 |
-
|
497 |
-
|
498 |
-
|
499 |
-
|
500 |
-
|
501 |
-
|
502 |
-
|
503 |
-
|
504 |
-
|
505 |
-
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
|
512 |
-
|
513 |
-
|
514 |
-
|
515 |
-
|
516 |
-
|
517 |
-
|
518 |
-
|
519 |
-
|
520 |
-
|
521 |
-
|
522 |
-
|
523 |
-
|
524 |
-
|
525 |
-
|
526 |
-
|
527 |
-
|
528 |
-
|
529 |
-
|
530 |
-
|
531 |
-
|
532 |
-
|
533 |
-
|
534 |
-
|
535 |
-
|
536 |
-
|
537 |
-
|
538 |
-
|
539 |
-
|
540 |
-
|
541 |
-
|
542 |
-
|
543 |
-
|
544 |
-
|
545 |
-
|
546 |
-
|
547 |
-
|
548 |
-
|
549 |
-
|
550 |
-
|
551 |
-
|
552 |
-
|
553 |
-
|
554 |
-
|
555 |
-
|
556 |
-
|
557 |
-
|
558 |
-
|
559 |
-
|
560 |
-
|
561 |
-
|
562 |
-
|
563 |
-
|
564 |
-
|
565 |
-
|
566 |
-
|
567 |
-
|
568 |
-
|
569 |
-
|
570 |
-
|
571 |
-
|
572 |
-
|
573 |
-
|
574 |
-
|
575 |
-
|
576 |
-
|
577 |
-
|
578 |
-
|
579 |
-
*
|
580 |
-
*
|
581 |
-
|
582 |
-
|
583 |
-
|
584 |
-
|
585 |
-
|
586 |
-
|
587 |
-
|
588 |
-
|
589 |
-
|
590 |
-
|
591 |
-
|
592 |
-
|
593 |
-
|
594 |
-
|
595 |
-
|
596 |
-
|
597 |
-
|
598 |
-
|
599 |
-
|
600 |
-
|
601 |
-
|
602 |
-
|
603 |
-
|
604 |
-
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
-
|
609 |
-
|
610 |
-
|
611 |
-
|
612 |
-
|
613 |
-
|
614 |
-
|
615 |
-
|
616 |
-
|
617 |
-
|
618 |
-
|
619 |
-
|
620 |
-
|
621 |
-
|
622 |
-
|
623 |
-
|
624 |
-
|
625 |
-
|
626 |
-
|
627 |
-
|
628 |
-
|
629 |
-
|
630 |
-
|
631 |
-
|
632 |
-
|
633 |
-
|
634 |
-
|
635 |
-
|
636 |
-
|
637 |
-
|
638 |
-
|
639 |
-
|
640 |
-
|
641 |
-
|
642 |
-
|
643 |
-
|
644 |
-
|
645 |
-
|
646 |
-
|
647 |
-
|
648 |
-
|
649 |
-
|
650 |
-
|
651 |
-
|
652 |
-
|
653 |
-
|
654 |
-
|
655 |
-
|
656 |
-
|
657 |
-
|
658 |
-
|
659 |
-
|
660 |
-
|
661 |
-
|
662 |
-
|
663 |
-
|
664 |
-
|
665 |
-
|
666 |
-
|
667 |
-
|
668 |
-
|
669 |
-
|
670 |
-
|
671 |
-
|
672 |
-
$
|
673 |
-
|
674 |
-
$
|
675 |
-
|
676 |
-
$
|
677 |
-
|
678 |
-
$
|
679 |
-
|
680 |
-
|
681 |
-
|
682 |
-
|
683 |
-
|
684 |
-
|
685 |
-
|
686 |
-
|
687 |
-
|
688 |
-
|
689 |
-
|
690 |
-
|
691 |
-
|
692 |
-
|
693 |
-
|
694 |
-
|
695 |
-
|
696 |
-
|
697 |
-
|
698 |
-
|
699 |
-
|
700 |
-
|
701 |
-
|
702 |
-
|
703 |
-
|
704 |
-
|
705 |
-
|
706 |
-
|
707 |
-
|
708 |
-
|
709 |
-
|
710 |
-
|
711 |
-
|
712 |
-
|
713 |
-
|
714 |
-
|
715 |
-
|
716 |
-
|
717 |
-
|
718 |
-
|
719 |
-
|
720 |
-
|
721 |
-
|
722 |
-
|
723 |
-
|
724 |
-
|
725 |
-
|
726 |
-
|
727 |
-
|
728 |
-
|
729 |
-
|
730 |
-
|
731 |
-
|
732 |
-
|
733 |
-
|
734 |
-
|
735 |
-
|
736 |
-
|
737 |
-
|
738 |
-
|
739 |
-
|
740 |
-
|
741 |
-
|
742 |
-
|
743 |
-
|
744 |
-
|
745 |
-
|
746 |
-
|
747 |
-
|
748 |
-
|
749 |
-
|
750 |
-
|
751 |
-
|
752 |
-
|
753 |
-
|
754 |
-
|
755 |
-
|
756 |
-
|
757 |
-
|
758 |
-
|
759 |
-
|
760 |
-
|
761 |
-
|
762 |
-
|
763 |
-
|
764 |
-
|
765 |
-
|
766 |
-
|
767 |
-
|
768 |
-
|
769 |
-
|
770 |
-
|
771 |
-
|
772 |
-
|
773 |
-
|
774 |
-
|
775 |
-
|
776 |
-
|
777 |
-
|
778 |
-
|
779 |
-
|
780 |
-
|
781 |
-
|
782 |
-
|
783 |
-
|
784 |
-
|
785 |
-
|
786 |
-
|
787 |
-
|
788 |
-
|
789 |
-
|
790 |
-
|
791 |
-
|
792 |
-
|
793 |
-
|
794 |
-
|
795 |
-
|
796 |
-
|
797 |
-
|
798 |
-
|
799 |
-
|
800 |
-
|
801 |
-
|
802 |
-
|
803 |
-
|
804 |
-
|
805 |
-
|
806 |
-
|
807 |
-
|
808 |
-
|
809 |
-
|
810 |
-
|
811 |
-
|
812 |
-
|
813 |
-
|
814 |
-
|
815 |
-
|
816 |
-
|
817 |
-
|
818 |
-
|
819 |
-
|
820 |
-
|
821 |
-
|
822 |
-
|
823 |
-
|
824 |
-
|
825 |
-
|
826 |
-
|
827 |
-
|
828 |
-
|
829 |
-
|
830 |
-
|
831 |
-
|
832 |
-
|
833 |
-
|
834 |
-
|
835 |
-
|
836 |
-
|
837 |
-
|
838 |
-
|
839 |
-
|
840 |
-
|
841 |
-
|
842 |
-
|
843 |
-
|
844 |
-
|
845 |
-
|
846 |
-
|
847 |
-
|
848 |
-
|
849 |
-
|
850 |
-
|
851 |
-
|
852 |
-
|
853 |
-
|
854 |
-
|
855 |
-
|
856 |
-
|
857 |
-
|
858 |
-
$
|
859 |
-
|
860 |
-
|
861 |
-
|
862 |
-
|
863 |
-
|
864 |
-
|
865 |
-
|
866 |
-
}
|
867 |
-
|
868 |
-
/**
|
869 |
-
*
|
870 |
-
*
|
871 |
-
* @
|
872 |
-
|
873 |
-
|
874 |
-
|
875 |
-
|
876 |
-
|
877 |
-
|
878 |
-
|
879 |
-
$checkout_id =
|
880 |
-
|
881 |
-
|
882 |
-
|
883 |
-
|
884 |
-
|
885 |
-
|
886 |
-
|
887 |
-
|
888 |
-
|
889 |
-
|
890 |
-
|
891 |
-
|
892 |
-
|
893 |
-
|
894 |
-
|
895 |
-
|
896 |
-
|
897 |
-
|
898 |
-
|
899 |
-
|
900 |
-
$
|
901 |
-
|
902 |
-
|
903 |
-
'class'
|
904 |
-
|
905 |
-
|
906 |
-
|
907 |
-
|
908 |
-
|
909 |
-
|
910 |
-
|
911 |
-
|
912 |
-
|
913 |
-
|
914 |
-
|
915 |
-
|
916 |
-
|
917 |
-
|
918 |
-
|
919 |
-
|
920 |
-
|
921 |
-
|
922 |
-
|
923 |
-
|
924 |
-
|
925 |
-
|
926 |
-
|
927 |
-
|
928 |
-
|
929 |
-
|
930 |
-
|
931 |
-
|
932 |
-
|
933 |
-
|
934 |
-
|
935 |
-
|
936 |
-
|
937 |
-
|
938 |
-
|
939 |
-
|
940 |
-
|
941 |
-
|
942 |
-
|
943 |
-
|
944 |
-
|
945 |
-
|
946 |
-
|
947 |
-
|
948 |
-
|
949 |
-
|
950 |
-
|
951 |
-
|
952 |
-
|
953 |
-
|
954 |
-
|
955 |
-
|
956 |
-
|
957 |
-
|
958 |
-
|
959 |
-
|
960 |
-
|
961 |
-
|
962 |
-
|
963 |
-
|
964 |
-
|
965 |
-
|
966 |
-
|
967 |
-
|
968 |
-
|
969 |
-
|
970 |
-
|
971 |
-
|
972 |
-
|
973 |
-
|
974 |
-
|
975 |
-
|
976 |
-
|
977 |
-
|
978 |
-
|
979 |
-
|
980 |
-
|
981 |
-
|
982 |
-
|
983 |
-
|
984 |
-
*
|
985 |
-
|
986 |
-
|
987 |
-
|
988 |
-
|
989 |
-
|
990 |
-
|
991 |
-
|
992 |
-
|
993 |
-
|
994 |
-
|
995 |
-
|
996 |
-
|
997 |
-
|
998 |
-
|
999 |
-
|
1000 |
-
|
1001 |
-
|
1002 |
-
*
|
1003 |
-
*/
|
1004 |
-
public function
|
1005 |
-
|
1006 |
-
|
1007 |
-
|
1008 |
-
|
1009 |
-
|
1010 |
-
|
1011 |
-
}
|
1012 |
-
|
1013 |
-
|
1014 |
-
|
1015 |
-
|
1016 |
-
|
1017 |
-
|
1018 |
-
|
1019 |
-
|
1020 |
-
|
1021 |
-
|
1022 |
-
|
1023 |
-
|
1024 |
-
|
1025 |
-
|
1026 |
-
|
1027 |
-
|
1028 |
-
|
1029 |
-
|
1030 |
-
|
1031 |
-
|
1032 |
-
|
1033 |
-
|
1034 |
-
|
1035 |
-
|
1036 |
-
|
1037 |
-
|
1038 |
-
|
1039 |
-
|
1040 |
-
|
1041 |
-
|
1042 |
-
|
1043 |
-
|
1044 |
-
|
1045 |
-
|
1046 |
-
|
1047 |
-
|
1048 |
-
|
1049 |
-
|
1050 |
-
|
1051 |
-
|
1052 |
-
|
1053 |
-
|
1054 |
-
|
1055 |
-
|
1056 |
-
|
1057 |
-
|
1058 |
-
|
1059 |
-
|
1060 |
-
|
1061 |
-
|
1062 |
-
|
1063 |
-
|
1064 |
-
|
1065 |
-
|
1066 |
-
|
1067 |
-
$fields['
|
1068 |
-
|
1069 |
-
|
1070 |
-
|
1071 |
-
|
1072 |
-
|
1073 |
-
|
1074 |
-
$fields['
|
1075 |
-
|
1076 |
-
|
1077 |
-
|
1078 |
-
|
1079 |
-
|
1080 |
-
|
1081 |
-
|
1082 |
-
|
1083 |
-
|
1084 |
-
|
1085 |
-
|
1086 |
-
|
1087 |
-
|
1088 |
-
|
1089 |
-
|
1090 |
-
|
1091 |
-
|
1092 |
-
|
1093 |
-
|
1094 |
-
|
1095 |
-
|
1096 |
-
|
1097 |
-
|
1098 |
-
|
1099 |
-
|
1100 |
-
|
1101 |
-
|
1102 |
-
|
1103 |
-
|
1104 |
-
|
1105 |
-
|
1106 |
-
|
1107 |
-
|
1108 |
-
|
1109 |
-
|
1110 |
-
|
1111 |
-
|
1112 |
-
|
1113 |
-
}
|
1114 |
-
|
1115 |
-
|
1116 |
-
|
1117 |
-
|
1118 |
-
|
1119 |
-
|
1120 |
-
|
1121 |
-
|
1122 |
-
|
1123 |
-
|
1124 |
-
|
1125 |
-
|
1126 |
-
|
1127 |
-
|
1128 |
-
|
1129 |
-
|
1130 |
-
|
1131 |
-
|
1132 |
-
|
1133 |
-
|
1134 |
-
|
1135 |
-
|
1136 |
-
|
1137 |
-
|
1138 |
-
|
1139 |
-
|
1140 |
-
|
1141 |
-
|
1142 |
-
|
1143 |
-
|
1144 |
-
|
1145 |
-
|
1146 |
-
|
1147 |
-
|
1148 |
-
|
1149 |
-
|
1150 |
-
|
1151 |
-
|
1152 |
-
|
1153 |
-
|
1154 |
-
|
1155 |
-
|
1156 |
-
|
1157 |
-
|
1158 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Checkout markup.
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
/**
|
9 |
+
* Checkout Markup
|
10 |
+
*
|
11 |
+
* @since 1.0.0
|
12 |
+
*/
|
13 |
+
class Cartflows_Checkout_Markup {
|
14 |
+
|
15 |
+
/**
|
16 |
+
* Member Variable
|
17 |
+
*
|
18 |
+
* @var object instance
|
19 |
+
*/
|
20 |
+
private static $instance;
|
21 |
+
|
22 |
+
/**
|
23 |
+
* Initiator
|
24 |
+
*/
|
25 |
+
public static function get_instance() {
|
26 |
+
if ( ! isset( self::$instance ) ) {
|
27 |
+
self::$instance = new self();
|
28 |
+
}
|
29 |
+
return self::$instance;
|
30 |
+
}
|
31 |
+
|
32 |
+
/**
|
33 |
+
* Constructor
|
34 |
+
*/
|
35 |
+
public function __construct() {
|
36 |
+
|
37 |
+
/* Set is checkout flag */
|
38 |
+
add_filter( 'woocommerce_is_checkout', array( $this, 'woo_checkout_flag' ), 9999 );
|
39 |
+
|
40 |
+
add_action( 'woocommerce_checkout_update_order_meta', array( $this, 'save_checkout_fields' ), 10, 2 );
|
41 |
+
|
42 |
+
/* Show notice if cart is empty */
|
43 |
+
add_action( 'cartflows_checkout_cart_empty', array( $this, 'display_woo_notices' ) );
|
44 |
+
|
45 |
+
/* Checkout Shortcode */
|
46 |
+
add_shortcode( 'cartflows_checkout', array( $this, 'checkout_shortcode_markup' ) );
|
47 |
+
|
48 |
+
/* Preconfigured cart data */
|
49 |
+
add_action( 'wp', array( $this, 'preconfigured_cart_data' ), 1 );
|
50 |
+
|
51 |
+
/* Embed Checkout */
|
52 |
+
add_action( 'wp', array( $this, 'shortcode_load_data' ), 999 );
|
53 |
+
|
54 |
+
/* Ajax Endpoint */
|
55 |
+
add_filter( 'woocommerce_ajax_get_endpoint', array( $this, 'get_ajax_endpoint' ), 10, 2 );
|
56 |
+
|
57 |
+
add_filter( 'cartflows_add_before_main_section', array( $this, 'enable_logo_in_header' ) );
|
58 |
+
|
59 |
+
add_filter( 'cartflows_primary_container_bottom', array( $this, 'show_cartflows_copyright_message' ) );
|
60 |
+
|
61 |
+
add_filter( 'woocommerce_login_redirect', array( $this, 'after_login_redirect' ), 10, 2 );
|
62 |
+
|
63 |
+
add_action( 'wp_ajax_wcf_woo_apply_coupon', array( $this, 'apply_coupon' ) );
|
64 |
+
add_action( 'wp_ajax_nopriv_wcf_woo_apply_coupon', array( $this, 'apply_coupon' ) );
|
65 |
+
|
66 |
+
add_filter( 'global_cartflows_js_localize', array( $this, 'add_localize_vars' ) );
|
67 |
+
|
68 |
+
/* Global Checkout */
|
69 |
+
add_action( 'template_redirect', array( $this, 'global_checkout_template_redirect' ), 1 );
|
70 |
+
|
71 |
+
add_action( 'wp_ajax_wcf_woo_remove_coupon', array( $this, 'remove_coupon' ) );
|
72 |
+
add_action( 'wp_ajax_nopriv_wcf_woo_remove_coupon', array( $this, 'remove_coupon' ) );
|
73 |
+
|
74 |
+
add_action( 'wp_ajax_wcf_woo_remove_cart_product', array( $this, 'wcf_woo_remove_cart_product' ) );
|
75 |
+
add_action( 'wp_ajax_nopriv_wcf_woo_remove_cart_product', array( $this, 'wcf_woo_remove_cart_product' ) );
|
76 |
+
|
77 |
+
add_filter( 'woocommerce_paypal_args', array( $this, 'modify_paypal_args' ), 10, 2 );
|
78 |
+
|
79 |
+
add_filter( 'woocommerce_cart_item_name', array( $this, 'wcf_add_remove_label' ), 10, 3 );
|
80 |
+
|
81 |
+
add_action( 'woocommerce_before_calculate_totals', array( $this, 'custom_price_to_cart_item' ), 9999 );
|
82 |
+
}
|
83 |
+
|
84 |
+
/**
|
85 |
+
* Modify WooCommerce paypal arguments.
|
86 |
+
*
|
87 |
+
* @param array $args argumenets for payment.
|
88 |
+
* @param WC_Order $order order data.
|
89 |
+
* @return array
|
90 |
+
*/
|
91 |
+
public function modify_paypal_args( $args, $order ) {
|
92 |
+
|
93 |
+
$checkout_id = wcf()->utils->get_checkout_id_from_post_data();
|
94 |
+
|
95 |
+
if ( ! $checkout_id ) {
|
96 |
+
return $args;
|
97 |
+
}
|
98 |
+
|
99 |
+
// Set cancel return URL.
|
100 |
+
$args['cancel_return'] = esc_url_raw( $order->get_cancel_order_url_raw( get_permalink( $checkout_id ) ) );
|
101 |
+
|
102 |
+
return $args;
|
103 |
+
}
|
104 |
+
|
105 |
+
/**
|
106 |
+
* Modify WooCommerce paypal arguments.
|
107 |
+
*
|
108 |
+
* @param string $product_name product name.
|
109 |
+
* @param object $cart_item cart item.
|
110 |
+
* @param string $cart_item_key cart item key.
|
111 |
+
* @return string
|
112 |
+
*/
|
113 |
+
public function wcf_add_remove_label( $product_name, $cart_item, $cart_item_key ) {
|
114 |
+
|
115 |
+
$checkout_id = get_the_ID();
|
116 |
+
if ( ! $checkout_id ) {
|
117 |
+
$checkout_id = ( isset( $_POST['option']['checkout_id'] ) ) ? wp_unslash( $_POST['option']['checkout_id'] ) : '';//phpcs:ignore
|
118 |
+
}
|
119 |
+
|
120 |
+
if ( ! empty( $checkout_id ) ) {
|
121 |
+
$is_remove_product_option = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-remove-product-field' );
|
122 |
+
if ( 'checkout' === get_post_meta( $checkout_id, 'wcf-step-type', true ) && ( 'yes' === $is_remove_product_option ) ) {
|
123 |
+
$remove_label = apply_filters(
|
124 |
+
'woocommerce_cart_item_remove_link',
|
125 |
+
sprintf(
|
126 |
+
'<a href="#" rel="nofollow" class="remove cartflows-icon-close" data-id="%s" data-item-key="%s" ></a>',
|
127 |
+
esc_attr( $cart_item['product_id'] ),
|
128 |
+
$cart_item_key
|
129 |
+
),
|
130 |
+
$cart_item_key
|
131 |
+
);
|
132 |
+
|
133 |
+
$product_name = $remove_label . $product_name;
|
134 |
+
}
|
135 |
+
}
|
136 |
+
|
137 |
+
return $product_name;
|
138 |
+
|
139 |
+
}
|
140 |
+
|
141 |
+
/**
|
142 |
+
* Change order button text .
|
143 |
+
*
|
144 |
+
* @param string $woo_button_text place order.
|
145 |
+
* @return string
|
146 |
+
*/
|
147 |
+
public function place_order_button_text( $woo_button_text ) {
|
148 |
+
|
149 |
+
$checkout_id = get_the_ID();
|
150 |
+
if ( ! $checkout_id ) {
|
151 |
+
$checkout_id = ( isset( $_POST['option']['checkout_id'] ) ) ? intval( $_POST['option']['checkout_id'] ) : 0; //phpcs:ignore
|
152 |
+
}
|
153 |
+
|
154 |
+
$wcf_order_button_text = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-checkout-place-order-button-text' );
|
155 |
+
|
156 |
+
if ( ! empty( $wcf_order_button_text ) ) {
|
157 |
+
$woo_button_text = $wcf_order_button_text;
|
158 |
+
}
|
159 |
+
|
160 |
+
return $woo_button_text;
|
161 |
+
}
|
162 |
+
|
163 |
+
/**
|
164 |
+
* Display all WooCommerce notices.
|
165 |
+
*
|
166 |
+
* @since 1.1.5
|
167 |
+
*/
|
168 |
+
public function display_woo_notices() {
|
169 |
+
|
170 |
+
if ( null != WC()->session && function_exists( 'woocommerce_output_all_notices' ) ) {
|
171 |
+
woocommerce_output_all_notices();
|
172 |
+
}
|
173 |
+
}
|
174 |
+
|
175 |
+
|
176 |
+
/**
|
177 |
+
* Redirect from default to the global checkout page
|
178 |
+
*
|
179 |
+
* @since 1.0.0
|
180 |
+
*/
|
181 |
+
public function global_checkout_template_redirect() {
|
182 |
+
|
183 |
+
if ( ! is_checkout() ) {
|
184 |
+
return;
|
185 |
+
}
|
186 |
+
|
187 |
+
if ( wcf()->utils->is_step_post_type() ) {
|
188 |
+
return;
|
189 |
+
}
|
190 |
+
|
191 |
+
// Return if the key OR Order paramater is found in the URL for certain Payment gateways.
|
192 |
+
if ( isset( $_GET['key'] ) || isset( $_GET['order'] ) ) { //phpcs:ignore
|
193 |
+
return;
|
194 |
+
}
|
195 |
+
|
196 |
+
// redirect only for cartflows checkout pages.
|
197 |
+
$order_pay_endpoint = get_option( 'woocommerce_checkout_pay_endpoint', 'order-pay' );
|
198 |
+
$order_received_endpoint = get_option( 'woocommerce_checkout_order_received_endpoint', 'order-received' );
|
199 |
+
|
200 |
+
$common = Cartflows_Helper::get_common_settings();
|
201 |
+
|
202 |
+
$global_checkout = $common['global_checkout'];
|
203 |
+
|
204 |
+
if (
|
205 |
+
isset( $_SERVER['REQUEST_URI'] ) &&
|
206 |
+
// ignore on order-pay.
|
207 |
+
false === wcf_mb_strpos( esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ), '/' . $order_pay_endpoint . '/' ) &&
|
208 |
+
// ignore on TY page.
|
209 |
+
false === wcf_mb_strpos( esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ), '/' . $order_received_endpoint . '/' ) &&
|
210 |
+
// ignore if order-pay in query param.
|
211 |
+
false === wcf_mb_strpos( esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ), $order_pay_endpoint . '=' )
|
212 |
+
) {
|
213 |
+
|
214 |
+
if ( '' !== $global_checkout ) {
|
215 |
+
|
216 |
+
$link = apply_filters( 'cartflows_global_checkout_url', get_permalink( $global_checkout ) );
|
217 |
+
|
218 |
+
if ( ! empty( $link ) ) {
|
219 |
+
|
220 |
+
wp_safe_redirect( $link );
|
221 |
+
die();
|
222 |
+
}
|
223 |
+
}
|
224 |
+
}
|
225 |
+
}
|
226 |
+
|
227 |
+
/**
|
228 |
+
* Check for checkout flag
|
229 |
+
*
|
230 |
+
* @param bool $is_checkout is checkout.
|
231 |
+
*
|
232 |
+
* @return bool
|
233 |
+
*/
|
234 |
+
public function woo_checkout_flag( $is_checkout ) {
|
235 |
+
|
236 |
+
if ( ! is_admin() ) {
|
237 |
+
|
238 |
+
if ( _is_wcf_checkout_type() || _is_wcf_checkout_shortcode() ) {
|
239 |
+
|
240 |
+
$is_checkout = true;
|
241 |
+
}
|
242 |
+
}
|
243 |
+
|
244 |
+
return $is_checkout;
|
245 |
+
}
|
246 |
+
|
247 |
+
/**
|
248 |
+
* Render checkout shortcode markup.
|
249 |
+
*
|
250 |
+
* @param array $atts attributes.
|
251 |
+
* @return string
|
252 |
+
*/
|
253 |
+
public function checkout_shortcode_markup( $atts ) {
|
254 |
+
|
255 |
+
if ( ! function_exists( 'wc_print_notices' ) ) {
|
256 |
+
$notice_out = '<p class="woocommerce-notice">' . __( 'WooCommerce functions do not exist. If you are in an IFrame, please reload it.', 'cartflows' ) . '</p>';
|
257 |
+
$notice_out .= '<button onClick="location.reload()">' . __( 'Click Here to Reload', 'cartflows' ) . '</button>';
|
258 |
+
|
259 |
+
return $notice_out;
|
260 |
+
}
|
261 |
+
|
262 |
+
$atts = shortcode_atts(
|
263 |
+
array(
|
264 |
+
'id' => 0,
|
265 |
+
),
|
266 |
+
$atts
|
267 |
+
);
|
268 |
+
|
269 |
+
$checkout_id = intval( $atts['id'] );
|
270 |
+
|
271 |
+
if ( empty( $checkout_id ) ) {
|
272 |
+
|
273 |
+
if ( ! _is_wcf_checkout_type() ) {
|
274 |
+
|
275 |
+
return '<h4>' . __( 'Checkout ID not found', 'cartflows' ) . '</h4>';
|
276 |
+
}
|
277 |
+
|
278 |
+
global $post;
|
279 |
+
|
280 |
+
$checkout_id = intval( $post->ID );
|
281 |
+
}
|
282 |
+
|
283 |
+
$output = '';
|
284 |
+
|
285 |
+
ob_start();
|
286 |
+
|
287 |
+
do_action( 'cartflows_checkout_form_before', $checkout_id );
|
288 |
+
|
289 |
+
$checkout_layout = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-checkout-layout' );
|
290 |
+
|
291 |
+
$template_default = CARTFLOWS_CHECKOUT_DIR . 'templates/embed/checkout-template-simple.php';
|
292 |
+
|
293 |
+
$template_layout = apply_filters( 'cartflows_checkout_layout_template', $checkout_layout );
|
294 |
+
|
295 |
+
if ( file_exists( $template_layout ) ) {
|
296 |
+
include $template_layout;
|
297 |
+
} else {
|
298 |
+
include $template_default;
|
299 |
+
}
|
300 |
+
|
301 |
+
$output .= ob_get_clean();
|
302 |
+
|
303 |
+
return $output;
|
304 |
+
}
|
305 |
+
|
306 |
+
/**
|
307 |
+
* Configure Cart Data.
|
308 |
+
*
|
309 |
+
* @since 1.0.0
|
310 |
+
*
|
311 |
+
* @return void
|
312 |
+
*/
|
313 |
+
public function preconfigured_cart_data() {
|
314 |
+
|
315 |
+
if ( is_admin() ) {
|
316 |
+
return;
|
317 |
+
}
|
318 |
+
|
319 |
+
global $post;
|
320 |
+
|
321 |
+
if ( _is_wcf_checkout_type() || _is_wcf_checkout_shortcode() ) {
|
322 |
+
|
323 |
+
if ( wp_doing_ajax() ) {
|
324 |
+
return;
|
325 |
+
} else {
|
326 |
+
|
327 |
+
if ( _is_wcf_checkout_type() ) {
|
328 |
+
$checkout_id = $post->ID;
|
329 |
+
} else {
|
330 |
+
$checkout_id = _get_wcf_checkout_id_from_shortcode( $post->post_content );
|
331 |
+
}
|
332 |
+
|
333 |
+
$global_checkout = intval( Cartflows_Helper::get_common_setting( 'global_checkout' ) );
|
334 |
+
|
335 |
+
if ( ! empty( $global_checkout ) && $checkout_id === $global_checkout ) {
|
336 |
+
|
337 |
+
if ( WC()->cart->is_empty() ) {
|
338 |
+
wc_add_notice( __( 'Your cart is currently empty.', 'cartflows' ), 'error' );
|
339 |
+
}
|
340 |
+
|
341 |
+
return;
|
342 |
+
}
|
343 |
+
|
344 |
+
if ( apply_filters( 'cartflows_skip_configure_cart', false, $checkout_id ) ) {
|
345 |
+
return;
|
346 |
+
}
|
347 |
+
|
348 |
+
do_action( 'cartflows_checkout_before_configure_cart', $checkout_id );
|
349 |
+
|
350 |
+
$flow_id = wcf()->utils->get_flow_id_from_step_id( $checkout_id );
|
351 |
+
|
352 |
+
if ( wcf()->flow->is_flow_testmode( $flow_id ) ) {
|
353 |
+
$products = 'dummy';
|
354 |
+
} else {
|
355 |
+
$products = wcf()->utils->get_selected_checkout_products( $checkout_id );
|
356 |
+
}
|
357 |
+
|
358 |
+
if ( ! is_array( $products ) ) {
|
359 |
+
|
360 |
+
if ( 'dummy' === $products ) {
|
361 |
+
|
362 |
+
$args = array(
|
363 |
+
'posts_per_page' => 1,
|
364 |
+
'orderby' => 'rand',
|
365 |
+
'post_type' => 'product',
|
366 |
+
'meta_query' => array( //phpcs:ignore
|
367 |
+
// Exclude out of stock products.
|
368 |
+
array(
|
369 |
+
'key' => '_stock_status',
|
370 |
+
'value' => 'outofstock',
|
371 |
+
'compare' => 'NOT IN',
|
372 |
+
),
|
373 |
+
),
|
374 |
+
'tax_query' => array( //phpcs:ignore
|
375 |
+
array(
|
376 |
+
'taxonomy' => 'product_type',
|
377 |
+
'field' => 'slug',
|
378 |
+
'terms' => 'simple',
|
379 |
+
),
|
380 |
+
),
|
381 |
+
);
|
382 |
+
|
383 |
+
$random_product = get_posts( $args );
|
384 |
+
|
385 |
+
if ( isset( $random_product[0]->ID ) ) {
|
386 |
+
$products = array(
|
387 |
+
array(
|
388 |
+
'product' => $random_product[0]->ID,
|
389 |
+
'add_to_cart' => true,
|
390 |
+
),
|
391 |
+
);
|
392 |
+
} else {
|
393 |
+
return;
|
394 |
+
}
|
395 |
+
} else {
|
396 |
+
return;
|
397 |
+
}
|
398 |
+
}
|
399 |
+
|
400 |
+
/* Empty the current cart */
|
401 |
+
WC()->cart->empty_cart();
|
402 |
+
|
403 |
+
if ( is_array( $products ) && empty( $products[0]['product'] ) ) {
|
404 |
+
wc_add_notice( __( 'No product is selected. Please select products from the checkout meta settings to continue.', 'cartflows' ), 'error' );
|
405 |
+
return;
|
406 |
+
}
|
407 |
+
|
408 |
+
/* Set customer session if not set */
|
409 |
+
if ( ! is_user_logged_in() && WC()->cart->is_empty() ) {
|
410 |
+
WC()->session->set_customer_session_cookie( true );
|
411 |
+
}
|
412 |
+
|
413 |
+
$cart_product_count = 0;
|
414 |
+
$cart_key = '';
|
415 |
+
$products_new = array();
|
416 |
+
|
417 |
+
$products = apply_filters( 'cartflows_selected_checkout_products', $products, $checkout_id );
|
418 |
+
|
419 |
+
foreach ( $products as $index => $data ) {
|
420 |
+
|
421 |
+
if ( ! isset( $data['product'] ) ) {
|
422 |
+
continue;
|
423 |
+
}
|
424 |
+
|
425 |
+
if ( empty( $data['add_to_cart'] ) ) {
|
426 |
+
continue;
|
427 |
+
}
|
428 |
+
|
429 |
+
if ( apply_filters( 'cartflows_skip_other_products', false, $cart_product_count ) ) {
|
430 |
+
break;
|
431 |
+
}
|
432 |
+
|
433 |
+
$product_id = $data['product'];
|
434 |
+
$_product = wc_get_product( $product_id );
|
435 |
+
|
436 |
+
if ( ! empty( $_product ) ) {
|
437 |
+
|
438 |
+
$quantity = 1;
|
439 |
+
|
440 |
+
if ( isset( $data['quantity'] ) && ! empty( $data['quantity'] ) ) {
|
441 |
+
$quantity = $data['quantity'];
|
442 |
+
}
|
443 |
+
|
444 |
+
$discount_type = isset( $data['discount_type'] ) ? $data['discount_type'] : '';
|
445 |
+
$discount_value = ! empty( $data['discount_value'] ) ? $data['discount_value'] : '';
|
446 |
+
$_product_price = $_product->get_price( $data['product'] );
|
447 |
+
|
448 |
+
$custom_price = $this->calculate_discount( '', $discount_type, $discount_value, $_product_price );
|
449 |
+
|
450 |
+
$cart_item_data = array();
|
451 |
+
|
452 |
+
if ( ! empty( $custom_price ) ) {
|
453 |
+
|
454 |
+
$cart_item_data = array(
|
455 |
+
'custom_price' => $custom_price,
|
456 |
+
);
|
457 |
+
}
|
458 |
+
|
459 |
+
if ( ! $_product->is_type( 'grouped' ) && ! $_product->is_type( 'external' ) ) {
|
460 |
+
|
461 |
+
if ( $_product->is_type( 'variable' ) ) {
|
462 |
+
|
463 |
+
$default_attributes = $_product->get_default_attributes();
|
464 |
+
|
465 |
+
if ( ! empty( $default_attributes ) ) {
|
466 |
+
|
467 |
+
foreach ( $_product->get_children() as $variation_id ) {
|
468 |
+
|
469 |
+
$single_variation = new WC_Product_Variation( $variation_id );
|
470 |
+
|
471 |
+
if ( $default_attributes == $single_variation->get_attributes() ) {
|
472 |
+
$cart_key = WC()->cart->add_to_cart( $variation_id, $quantity, 0, array(), $cart_item_data );
|
473 |
+
$cart_product_count++;
|
474 |
+
}
|
475 |
+
}
|
476 |
+
} else {
|
477 |
+
|
478 |
+
$product_childrens = $_product->get_children();
|
479 |
+
|
480 |
+
if ( isset( $product_childrens[0] ) ) {
|
481 |
+
$variation = wc_get_product( $product_childrens[0] );
|
482 |
+
$_product_price = $variation->get_price();
|
483 |
+
$custom_price = $this->calculate_discount( '', $discount_type, $discount_value, $_product_price );
|
484 |
+
if ( ! empty( $custom_price ) ) {
|
485 |
+
$cart_item_data = array(
|
486 |
+
'custom_price' => $custom_price,
|
487 |
+
'data' => $data,
|
488 |
+
);
|
489 |
+
}
|
490 |
+
$cart_key = WC()->cart->add_to_cart( $product_childrens[0], $quantity, 0, array(), $cart_item_data );
|
491 |
+
$cart_product_count++;
|
492 |
+
} else {
|
493 |
+
echo '<p>' . esc_html__( 'Variations Not set', 'cartflows' ) . '</p>';
|
494 |
+
}
|
495 |
+
}
|
496 |
+
} else {
|
497 |
+
$cart_key = WC()->cart->add_to_cart( $product_id, $quantity, 0, array(), $cart_item_data );
|
498 |
+
$cart_product_count++;
|
499 |
+
}
|
500 |
+
} else {
|
501 |
+
$wrong_product_notice = __( 'This product can\'t be purchased', 'cartflows' );
|
502 |
+
wc_add_notice( $wrong_product_notice );
|
503 |
+
/**
|
504 |
+
WC()->cart->add_to_cart( $product_id, $quantity );.
|
505 |
+
*/
|
506 |
+
}
|
507 |
+
}
|
508 |
+
$products_new[ $index ] = array(
|
509 |
+
'cart_item_key' => $cart_key,
|
510 |
+
);
|
511 |
+
}
|
512 |
+
|
513 |
+
/* Set checkout products data */
|
514 |
+
wcf()->utils->set_selcted_checkout_products( $checkout_id, $products_new );
|
515 |
+
|
516 |
+
/* Since 1.2.2 */
|
517 |
+
wcf_do_action_deprecated( 'cartflows_checkout_aftet_configure_cart', array( $checkout_id ), '1.2.2', 'cartflows_checkout_after_configure_cart' );
|
518 |
+
do_action( 'cartflows_checkout_after_configure_cart', $checkout_id );
|
519 |
+
}
|
520 |
+
}
|
521 |
+
}
|
522 |
+
|
523 |
+
/**
|
524 |
+
* Load shortcode data.
|
525 |
+
*
|
526 |
+
* @return void
|
527 |
+
*/
|
528 |
+
public function shortcode_load_data() {
|
529 |
+
|
530 |
+
if ( _is_wcf_checkout_type() || _is_wcf_checkout_shortcode() ) {
|
531 |
+
|
532 |
+
add_action( 'wp_enqueue_scripts', array( $this, 'shortcode_scripts' ), 21 );
|
533 |
+
|
534 |
+
add_action( 'wp_enqueue_scripts', array( $this, 'compatibility_scripts' ), 101 );
|
535 |
+
|
536 |
+
/* Show notices if cart has errors */
|
537 |
+
add_action( 'woocommerce_cart_has_errors', 'woocommerce_output_all_notices' );
|
538 |
+
|
539 |
+
add_action( 'woocommerce_checkout_after_customer_details', array( $this, 'order_wrap_div_start' ), 99 );
|
540 |
+
|
541 |
+
add_action( 'woocommerce_checkout_after_order_review', array( $this, 'order_wrap_div_end' ), 99 );
|
542 |
+
|
543 |
+
// Outputting the hidden field in checkout page.
|
544 |
+
add_action( 'woocommerce_after_order_notes', array( $this, 'checkout_shortcode_post_id' ), 99 );
|
545 |
+
add_action( 'woocommerce_login_form_end', array( $this, 'checkout_shortcode_post_id' ), 99 );
|
546 |
+
|
547 |
+
remove_all_actions( 'woocommerce_checkout_billing' );
|
548 |
+
remove_all_actions( 'woocommerce_checkout_shipping' );
|
549 |
+
|
550 |
+
// Hook in actions once.
|
551 |
+
add_action( 'woocommerce_checkout_billing', array( WC()->checkout, 'checkout_form_billing' ) );
|
552 |
+
add_action( 'woocommerce_checkout_shipping', array( WC()->checkout, 'checkout_form_shipping' ) );
|
553 |
+
|
554 |
+
remove_action( 'woocommerce_before_checkout_form', 'woocommerce_checkout_coupon_form' );
|
555 |
+
|
556 |
+
add_action( 'woocommerce_checkout_order_review', array( $this, 'display_custom_coupon_field' ) );
|
557 |
+
|
558 |
+
add_filter( 'woocommerce_checkout_fields', array( $this, 'add_three_column_layout_fields' ) );
|
559 |
+
|
560 |
+
add_filter( 'woocommerce_cart_totals_coupon_html', array( $this, 'remove_coupon_text' ) );
|
561 |
+
|
562 |
+
add_filter( 'woocommerce_order_button_text', array( $this, 'place_order_button_text' ), 10, 1 );
|
563 |
+
|
564 |
+
global $post;
|
565 |
+
|
566 |
+
if ( _is_wcf_checkout_type() ) {
|
567 |
+
$checkout_id = $post->ID;
|
568 |
+
} else {
|
569 |
+
$checkout_id = _get_wcf_checkout_id_from_shortcode( $post->post_content );
|
570 |
+
}
|
571 |
+
|
572 |
+
do_action( 'cartflows_checkout_before_shortcode', $checkout_id );
|
573 |
+
}
|
574 |
+
}
|
575 |
+
|
576 |
+
/**
|
577 |
+
* Render checkout ID hidden field.
|
578 |
+
*
|
579 |
+
* @param array $checkout checkout session data.
|
580 |
+
* @return void
|
581 |
+
*/
|
582 |
+
public function checkout_shortcode_post_id( $checkout ) {
|
583 |
+
|
584 |
+
global $post;
|
585 |
+
|
586 |
+
if ( _is_wcf_checkout_type() ) {
|
587 |
+
$checkout_id = $post->ID;
|
588 |
+
} else {
|
589 |
+
$checkout_id = _get_wcf_checkout_id_from_shortcode( $post->post_content );
|
590 |
+
}
|
591 |
+
|
592 |
+
$flow_id = get_post_meta( $checkout_id, 'wcf-flow-id', true );
|
593 |
+
|
594 |
+
echo '<input type="hidden" class="input-hidden _wcf_flow_id" name="_wcf_flow_id" value="' . intval( $flow_id ) . '">';
|
595 |
+
echo '<input type="hidden" class="input-hidden _wcf_checkout_id" name="_wcf_checkout_id" value="' . intval( $checkout_id ) . '">';
|
596 |
+
}
|
597 |
+
|
598 |
+
/**
|
599 |
+
* Load shortcode scripts.
|
600 |
+
*
|
601 |
+
* @return void
|
602 |
+
*/
|
603 |
+
public function shortcode_scripts() {
|
604 |
+
|
605 |
+
wp_enqueue_style( 'wcf-checkout-template', wcf()->utils->get_css_url( 'checkout-template' ), '', CARTFLOWS_VER );
|
606 |
+
|
607 |
+
wp_enqueue_script(
|
608 |
+
'wcf-checkout-template',
|
609 |
+
wcf()->utils->get_js_url( 'checkout-template' ),
|
610 |
+
array( 'jquery' ),
|
611 |
+
CARTFLOWS_VER,
|
612 |
+
true
|
613 |
+
);
|
614 |
+
|
615 |
+
do_action( 'cartflows_checkout_scripts' );
|
616 |
+
|
617 |
+
$style = $this->generate_style();
|
618 |
+
|
619 |
+
wp_add_inline_style( 'wcf-checkout-template', $style );
|
620 |
+
|
621 |
+
}
|
622 |
+
|
623 |
+
/**
|
624 |
+
* Load compatibility scripts.
|
625 |
+
*
|
626 |
+
* @return void
|
627 |
+
*/
|
628 |
+
public function compatibility_scripts() {
|
629 |
+
|
630 |
+
global $post;
|
631 |
+
|
632 |
+
if ( _is_wcf_checkout_type() ) {
|
633 |
+
$checkout_id = $post->ID;
|
634 |
+
} else {
|
635 |
+
$checkout_id = _get_wcf_checkout_id_from_shortcode( $post->post_content );
|
636 |
+
}
|
637 |
+
|
638 |
+
// Add DIVI Compatibility css if DIVI theme is enabled.
|
639 |
+
if ( Cartflows_Compatibility::get_instance()->is_divi_enabled() ||
|
640 |
+
Cartflows_Compatibility::get_instance()->is_divi_builder_enabled( $checkout_id )
|
641 |
+
) {
|
642 |
+
wp_enqueue_style( 'wcf-checkout-template-divi', wcf()->utils->get_css_url( 'checkout-template-divi' ), '', CARTFLOWS_VER );
|
643 |
+
}
|
644 |
+
|
645 |
+
// Add Flatsome Compatibility css if Flatsome theme is enabled.
|
646 |
+
if ( Cartflows_Compatibility::get_instance()->is_flatsome_enabled() ) {
|
647 |
+
wp_enqueue_style( 'wcf-checkout-template-flatsome', wcf()->utils->get_css_url( 'checkout-template-flatsome' ), '', CARTFLOWS_VER );
|
648 |
+
}
|
649 |
+
|
650 |
+
// Add The7 Compatibility css if The7 theme is enabled.
|
651 |
+
if ( Cartflows_Compatibility::get_instance()->is_the_seven_enabled() ) {
|
652 |
+
wp_enqueue_style( 'wcf-checkout-template-the-seven', wcf()->utils->get_css_url( 'checkout-template-the-seven' ), '', CARTFLOWS_VER );
|
653 |
+
}
|
654 |
+
}
|
655 |
+
|
656 |
+
/**
|
657 |
+
* Generate styles.
|
658 |
+
*
|
659 |
+
* @return string
|
660 |
+
*/
|
661 |
+
public function generate_style() {
|
662 |
+
|
663 |
+
global $post;
|
664 |
+
|
665 |
+
if ( _is_wcf_checkout_type() ) {
|
666 |
+
$checkout_id = $post->ID;
|
667 |
+
} else {
|
668 |
+
$checkout_id = _get_wcf_checkout_id_from_shortcode( $post->post_content );
|
669 |
+
}
|
670 |
+
|
671 |
+
/*Output css variable */
|
672 |
+
$output = '';
|
673 |
+
|
674 |
+
CartFlows_Font_Families::render_fonts( $checkout_id );
|
675 |
+
|
676 |
+
$primary_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-primary-color' );
|
677 |
+
|
678 |
+
$base_font_family = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-base-font-family' );
|
679 |
+
|
680 |
+
$header_logo_width = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-header-logo-width' );
|
681 |
+
|
682 |
+
/**
|
683 |
+
$base_font_weight = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-base-font-weight' );*/
|
684 |
+
$r = '';
|
685 |
+
$g = '';
|
686 |
+
$b = '';
|
687 |
+
|
688 |
+
$field_tb_padding = '';
|
689 |
+
$field_lr_padding = '';
|
690 |
+
|
691 |
+
$field_heading_color = '';
|
692 |
+
$field_color = '';
|
693 |
+
$field_bg_color = '';
|
694 |
+
$field_border_color = '';
|
695 |
+
$field_label_color = '';
|
696 |
+
$submit_tb_padding = '';
|
697 |
+
$submit_lr_padding = '';
|
698 |
+
$hl_bg_color = '';
|
699 |
+
$field_input_size = '';
|
700 |
+
$box_border_color = '';
|
701 |
+
$section_bg_color = '';
|
702 |
+
$submit_button_height = '';
|
703 |
+
$submit_color = '';
|
704 |
+
$submit_bg_color = $primary_color;
|
705 |
+
$submit_border_color = $primary_color;
|
706 |
+
|
707 |
+
$submit_hover_color = '';
|
708 |
+
$submit_bg_hover_color = $primary_color;
|
709 |
+
$submit_border_hover_color = $primary_color;
|
710 |
+
|
711 |
+
$section_heading_color = '';
|
712 |
+
|
713 |
+
$is_advance_option = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-advance-options-fields' );
|
714 |
+
|
715 |
+
$button_font_family = '';
|
716 |
+
$button_font_weight = '';
|
717 |
+
$input_font_family = '';
|
718 |
+
$input_font_weight = '';
|
719 |
+
$heading_font_family = '';
|
720 |
+
$heading_font_weight = '';
|
721 |
+
$base_font_family = $base_font_family;
|
722 |
+
/**
|
723 |
+
$base_font_weight = $base_font_weight;*/
|
724 |
+
|
725 |
+
if ( 'yes' == $is_advance_option ) {
|
726 |
+
|
727 |
+
/**
|
728 |
+
* Get Font Family and Font Weight weight values
|
729 |
+
*/
|
730 |
+
$section_bg_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-section-bg-color' );
|
731 |
+
|
732 |
+
$heading_font_family = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-heading-font-family' );
|
733 |
+
$heading_font_weight = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-heading-font-weight' );
|
734 |
+
$section_heading_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-heading-color' );
|
735 |
+
$button_font_family = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-button-font-family' );
|
736 |
+
$button_font_weight = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-button-font-weight' );
|
737 |
+
$input_font_family = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-input-font-family' );
|
738 |
+
$input_font_weight = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-input-font-weight' );
|
739 |
+
$field_tb_padding = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-field-tb-padding' );
|
740 |
+
$field_lr_padding = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-field-lr-padding' );
|
741 |
+
$field_input_size = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-input-field-size' );
|
742 |
+
|
743 |
+
$field_heading_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-field-heading-color' );
|
744 |
+
|
745 |
+
$field_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-field-color' );
|
746 |
+
|
747 |
+
$field_bg_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-field-bg-color' );
|
748 |
+
|
749 |
+
$field_border_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-field-border-color' );
|
750 |
+
|
751 |
+
$field_label_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-field-label-color' );
|
752 |
+
|
753 |
+
$submit_tb_padding = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-tb-padding' );
|
754 |
+
|
755 |
+
$submit_lr_padding = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-lr-padding' );
|
756 |
+
|
757 |
+
$submit_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-color' );
|
758 |
+
|
759 |
+
$submit_bg_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-bg-color', $primary_color );
|
760 |
+
|
761 |
+
$submit_border_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-border-color', $primary_color );
|
762 |
+
|
763 |
+
$submit_border_hover_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-border-hover-color', $primary_color );
|
764 |
+
|
765 |
+
$submit_hover_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-hover-color' );
|
766 |
+
|
767 |
+
$submit_bg_hover_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-submit-bg-hover-color', $primary_color );
|
768 |
+
|
769 |
+
$hl_bg_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-hl-bg-color' );
|
770 |
+
|
771 |
+
$box_border_color = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-box-border-color' );
|
772 |
+
|
773 |
+
$submit_button_height = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-input-button-size' );
|
774 |
+
|
775 |
+
/**
|
776 |
+
* Get font values
|
777 |
+
*/
|
778 |
+
|
779 |
+
if ( 'custom' == $submit_button_height ) {
|
780 |
+
$submit_button_height = '38px';
|
781 |
+
}
|
782 |
+
|
783 |
+
if ( 'custom' == $field_input_size ) {
|
784 |
+
$field_input_size = '38px';
|
785 |
+
}
|
786 |
+
}
|
787 |
+
if ( isset( $primary_color ) ) {
|
788 |
+
|
789 |
+
list($r, $g, $b) = sscanf( $primary_color, '#%02x%02x%02x' );
|
790 |
+
}
|
791 |
+
|
792 |
+
if ( Cartflows_Compatibility::get_instance()->is_divi_enabled() ||
|
793 |
+
Cartflows_Compatibility::get_instance()->is_divi_builder_enabled( $checkout_id ) ) {
|
794 |
+
|
795 |
+
include CARTFLOWS_CHECKOUT_DIR . 'includes/checkout-dynamic-divi-css.php';
|
796 |
+
|
797 |
+
} else {
|
798 |
+
include CARTFLOWS_CHECKOUT_DIR . 'includes/checkout-dynamic-css.php';
|
799 |
+
}
|
800 |
+
|
801 |
+
return $output;
|
802 |
+
}
|
803 |
+
|
804 |
+
/**
|
805 |
+
* Get ajax end points.
|
806 |
+
*
|
807 |
+
* @param string $endpoint_url end point URL.
|
808 |
+
* @param string $request end point request.
|
809 |
+
* @return string
|
810 |
+
*/
|
811 |
+
public function get_ajax_endpoint( $endpoint_url, $request ) {
|
812 |
+
|
813 |
+
global $post;
|
814 |
+
|
815 |
+
if ( ! empty( $post ) && ! empty( $_SERVER['REQUEST_URI'] ) ) {
|
816 |
+
|
817 |
+
if ( _is_wcf_checkout_type() ) {
|
818 |
+
|
819 |
+
if ( mb_strpos( $endpoint_url, 'checkout', 0, 'utf-8' ) === false ) {
|
820 |
+
|
821 |
+
if ( '' === $request ) {
|
822 |
+
$query_args = array(
|
823 |
+
'wc-ajax' => '%%endpoint%%',
|
824 |
+
);
|
825 |
+
} else {
|
826 |
+
$query_args = array(
|
827 |
+
'wc-ajax' => $request,
|
828 |
+
);
|
829 |
+
}
|
830 |
+
|
831 |
+
$uri = explode( '?', $_SERVER['REQUEST_URI'], 2 ); //phpcs:ignore
|
832 |
+
$uri = $uri[0];
|
833 |
+
|
834 |
+
$endpoint_url = esc_url( add_query_arg( $query_args, $uri ) );
|
835 |
+
}
|
836 |
+
}
|
837 |
+
}
|
838 |
+
|
839 |
+
return $endpoint_url;
|
840 |
+
}
|
841 |
+
|
842 |
+
|
843 |
+
/**
|
844 |
+
* Save checkout fields.
|
845 |
+
*
|
846 |
+
* @param int $order_id order id.
|
847 |
+
* @param array $posted posted data.
|
848 |
+
* @return void
|
849 |
+
*/
|
850 |
+
public function save_checkout_fields( $order_id, $posted ) {
|
851 |
+
|
852 |
+
if ( isset( $_POST['_wcf_checkout_id'] ) ) { //phpcs:ignore
|
853 |
+
|
854 |
+
$checkout_id = wc_clean( intval( $_POST['_wcf_checkout_id'] ) ); //phpcs:ignore
|
855 |
+
|
856 |
+
update_post_meta( $order_id, '_wcf_checkout_id', $checkout_id );
|
857 |
+
|
858 |
+
if ( isset( $_POST['_wcf_flow_id'] ) ) { //phpcs:ignore
|
859 |
+
|
860 |
+
$flow_id = wc_clean( intval( $_POST['_wcf_flow_id'] ) ); //phpcs:ignore
|
861 |
+
|
862 |
+
update_post_meta( $order_id, '_wcf_flow_id', $flow_id );
|
863 |
+
}
|
864 |
+
}
|
865 |
+
|
866 |
+
}
|
867 |
+
|
868 |
+
/**
|
869 |
+
* Enable Logo In Header Of Checkout Page
|
870 |
+
*
|
871 |
+
* @return void
|
872 |
+
*/
|
873 |
+
public function enable_logo_in_header() {
|
874 |
+
global $post;
|
875 |
+
|
876 |
+
if ( _is_wcf_checkout_type() ) {
|
877 |
+
$checkout_id = $post->ID;
|
878 |
+
} else {
|
879 |
+
$checkout_id = _get_wcf_checkout_id_from_shortcode( $post->post_content );
|
880 |
+
}
|
881 |
+
|
882 |
+
$header_logo_image = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-header-logo-image' );
|
883 |
+
$add_image_markup = '';
|
884 |
+
|
885 |
+
if ( isset( $header_logo_image ) && ! empty( $header_logo_image ) ) {
|
886 |
+
$add_image_markup = '<div class="wcf-checkout-header-image">';
|
887 |
+
$add_image_markup .= '<img src="' . $header_logo_image . '" />';
|
888 |
+
$add_image_markup .= '</div>';
|
889 |
+
}
|
890 |
+
|
891 |
+
echo $add_image_markup;
|
892 |
+
}
|
893 |
+
|
894 |
+
/**
|
895 |
+
* Add text to the bootom of the checkout page.
|
896 |
+
*
|
897 |
+
* @return void
|
898 |
+
*/
|
899 |
+
public function show_cartflows_copyright_message() {
|
900 |
+
$output_string = '';
|
901 |
+
|
902 |
+
$output_string .= '<div class="wcf-footer-primary">';
|
903 |
+
$output_string .= '<div class="wcf-footer-content">';
|
904 |
+
$output_string .= '<p class="wcf-footer-message">';
|
905 |
+
$output_string .= 'Checkout powered by CartFlows';
|
906 |
+
$output_string .= '</p>';
|
907 |
+
$output_string .= '</div>';
|
908 |
+
$output_string .= '</div>';
|
909 |
+
|
910 |
+
echo $output_string;
|
911 |
+
}
|
912 |
+
|
913 |
+
/**
|
914 |
+
* Redirect users to our checkout if hidden param
|
915 |
+
*
|
916 |
+
* @param string $redirect redirect url.
|
917 |
+
* @param object $user user.
|
918 |
+
* @return string
|
919 |
+
*/
|
920 |
+
public function after_login_redirect( $redirect, $user ) {
|
921 |
+
|
922 |
+
if ( isset( $_POST['_wcf_checkout_id'] ) ) { //phpcs:ignore
|
923 |
+
|
924 |
+
$checkout_id = intval( $_POST['_wcf_checkout_id'] ); //phpcs:ignore
|
925 |
+
|
926 |
+
$redirect = get_permalink( $checkout_id );
|
927 |
+
}
|
928 |
+
|
929 |
+
return $redirect;
|
930 |
+
}
|
931 |
+
|
932 |
+
/**
|
933 |
+
* Display coupon code field after review order fields.
|
934 |
+
*/
|
935 |
+
public function display_custom_coupon_field() {
|
936 |
+
|
937 |
+
$coupon_enabled = apply_filters( 'woocommerce_coupons_enabled', true );
|
938 |
+
$show_coupon = apply_filters( 'cartflows_show_coupon_field', true );
|
939 |
+
|
940 |
+
if ( ! ( $coupon_enabled && $show_coupon ) ) {
|
941 |
+
return;
|
942 |
+
|
943 |
+
}
|
944 |
+
|
945 |
+
$coupon_field = array(
|
946 |
+
'field_text' => __( 'Coupon Code', 'cartflows' ),
|
947 |
+
'button_text' => __( 'Apply', 'cartflows' ),
|
948 |
+
'class' => '',
|
949 |
+
);
|
950 |
+
|
951 |
+
$coupon_field = apply_filters( 'cartflows_coupon_field_options', $coupon_field );
|
952 |
+
|
953 |
+
ob_start();
|
954 |
+
?>
|
955 |
+
<div class="wcf-custom-coupon-field <?php echo $coupon_field['class']; ?>" id="wcf_custom_coupon_field">
|
956 |
+
<div class="wcf-coupon-col-1">
|
957 |
+
<span>
|
958 |
+
<input type="text" name="coupon_code" class="input-text wcf-coupon-code-input" placeholder="<?php echo $coupon_field['field_text']; ?>" id="coupon_code" value="">
|
959 |
+
</span>
|
960 |
+
</div>
|
961 |
+
<div class="wcf-coupon-col-2">
|
962 |
+
<span>
|
963 |
+
<button type="button" class="button wcf-submit-coupon wcf-btn-small" name="apply_coupon" value="Apply"><?php echo $coupon_field['button_text']; ?></button>
|
964 |
+
</span>
|
965 |
+
</div>
|
966 |
+
</div>
|
967 |
+
<?php
|
968 |
+
echo ob_get_clean();
|
969 |
+
}
|
970 |
+
|
971 |
+
/**
|
972 |
+
* Apply filter to change class of remove coupon field.
|
973 |
+
*
|
974 |
+
* @param string $coupon coupon.
|
975 |
+
* @return string
|
976 |
+
*/
|
977 |
+
public function remove_coupon_text( $coupon ) {
|
978 |
+
|
979 |
+
$coupon = str_replace( 'woocommerce-remove-coupon', 'wcf-remove-coupon', $coupon );
|
980 |
+
return $coupon;
|
981 |
+
|
982 |
+
}
|
983 |
+
/**
|
984 |
+
* Apply filter to change the placeholder text of coupon field.
|
985 |
+
*
|
986 |
+
* @return string
|
987 |
+
*/
|
988 |
+
public function coupon_field_placeholder() {
|
989 |
+
return apply_filters( 'cartflows_coupon_field_placeholder', __( 'Coupon Code', 'cartflows' ) );
|
990 |
+
}
|
991 |
+
|
992 |
+
/**
|
993 |
+
* Apply filter to change the button text of coupon field.
|
994 |
+
*
|
995 |
+
* @return string
|
996 |
+
*/
|
997 |
+
public function coupon_button_text() {
|
998 |
+
return apply_filters( 'cartflows_coupon_button_text', __( 'Apply', 'cartflows' ) );
|
999 |
+
}
|
1000 |
+
|
1001 |
+
/**
|
1002 |
+
* Apply coupon on submit of custom coupon form.
|
1003 |
+
*/
|
1004 |
+
public function apply_coupon() {
|
1005 |
+
|
1006 |
+
$response = '';
|
1007 |
+
|
1008 |
+
check_ajax_referer( 'wcf-apply-coupon', 'security' );
|
1009 |
+
if ( ! empty( $_POST['coupon_code'] ) ) {
|
1010 |
+
$result = WC()->cart->add_discount( sanitize_text_field( wp_unslash( $_POST['coupon_code'] ) ) );
|
1011 |
+
} else {
|
1012 |
+
wc_add_notice( WC_Coupon::get_generic_coupon_error( WC_Coupon::E_WC_COUPON_PLEASE_ENTER ), 'error' );
|
1013 |
+
}
|
1014 |
+
|
1015 |
+
$response = array(
|
1016 |
+
'status' => $result,
|
1017 |
+
'msg' => wc_print_notices( true ),
|
1018 |
+
);
|
1019 |
+
|
1020 |
+
echo wp_json_encode( $response );
|
1021 |
+
|
1022 |
+
die();
|
1023 |
+
}
|
1024 |
+
|
1025 |
+
|
1026 |
+
/**
|
1027 |
+
* Added ajax nonce to localize variable.
|
1028 |
+
*
|
1029 |
+
* @param array $vars localize variables.
|
1030 |
+
*/
|
1031 |
+
public function add_localize_vars( $vars ) {
|
1032 |
+
|
1033 |
+
$vars['wcf_validate_coupon_nonce'] = wp_create_nonce( 'wcf-apply-coupon' );
|
1034 |
+
|
1035 |
+
$vars['wcf_validate_remove_coupon_nonce'] = wp_create_nonce( 'wcf-remove-coupon' );
|
1036 |
+
|
1037 |
+
$vars['wcf_validate_remove_cart_product_nonce'] = wp_create_nonce( 'wcf-remove-cart-product' );
|
1038 |
+
|
1039 |
+
$vars['allow_persistance'] = apply_filters( 'cartflows_allow_persistace', 'yes' );
|
1040 |
+
|
1041 |
+
return $vars;
|
1042 |
+
}
|
1043 |
+
|
1044 |
+
/**
|
1045 |
+
* Add custom class to the fields to change the UI to three column.
|
1046 |
+
*
|
1047 |
+
* @param array $fields fields.
|
1048 |
+
*/
|
1049 |
+
public function add_three_column_layout_fields( $fields ) {
|
1050 |
+
|
1051 |
+
if ( empty( $fields['billing']['billing_address_2'] ) ) {
|
1052 |
+
|
1053 |
+
if ( isset( $fields['billing']['billing_address_1'] ) && is_array( $fields['billing']['billing_address_1'] ) ) {
|
1054 |
+
$fields['billing']['billing_address_1']['class'][] = 'form-row-full';
|
1055 |
+
}
|
1056 |
+
}
|
1057 |
+
|
1058 |
+
if ( ! empty( $fields['billing']['billing_company'] ) ) {
|
1059 |
+
|
1060 |
+
if ( isset( $fields['billing']['billing_company'] ) && is_array( $fields['billing']['billing_company'] ) ) {
|
1061 |
+
$fields['billing']['billing_company']['class'][] = 'form-row-full';
|
1062 |
+
}
|
1063 |
+
}
|
1064 |
+
|
1065 |
+
if ( ! empty( $fields['shipping']['shipping_company'] ) ) {
|
1066 |
+
|
1067 |
+
if ( isset( $fields['shipping']['shipping_company'] ) && is_array( $fields['shipping']['shipping_company'] ) ) {
|
1068 |
+
$fields['shipping']['shipping_company']['class'][] = 'form-row-full';
|
1069 |
+
}
|
1070 |
+
}
|
1071 |
+
|
1072 |
+
if ( ! empty( $fields['billing']['billing_country'] ) ) {
|
1073 |
+
|
1074 |
+
if ( isset( $fields['billing']['billing_country'] ) && is_array( $fields['billing']['billing_country'] ) ) {
|
1075 |
+
$fields['billing']['billing_country']['class'][] = 'form-row-full';
|
1076 |
+
}
|
1077 |
+
}
|
1078 |
+
|
1079 |
+
if ( ! empty( $fields['shipping']['shipping_country'] ) ) {
|
1080 |
+
|
1081 |
+
if ( isset( $fields['shipping']['shipping_country'] ) && is_array( $fields['shipping']['shipping_country'] ) ) {
|
1082 |
+
$fields['shipping']['shipping_country']['class'][] = 'form-row-full';
|
1083 |
+
}
|
1084 |
+
}
|
1085 |
+
|
1086 |
+
if ( ! empty( $fields['billing']['billing_phone'] ) ) {
|
1087 |
+
|
1088 |
+
if ( isset( $fields['billing']['billing_phone'] ) && is_array( $fields['billing']['billing_phone'] ) ) {
|
1089 |
+
$fields['billing']['billing_phone']['class'][] = 'form-row-full';
|
1090 |
+
}
|
1091 |
+
}
|
1092 |
+
|
1093 |
+
if ( ! empty( $fields['billing']['billing_email'] ) ) {
|
1094 |
+
|
1095 |
+
if ( isset( $fields['billing']['billing_email'] ) && is_array( $fields['billing']['billing_email'] ) ) {
|
1096 |
+
$fields['billing']['billing_email']['class'][] = 'form-row-full';
|
1097 |
+
}
|
1098 |
+
}
|
1099 |
+
|
1100 |
+
if ( empty( $fields['shipping']['shipping_address_2'] ) ) {
|
1101 |
+
|
1102 |
+
if ( isset( $fields['shipping']['shipping_address_1'] ) && is_array( $fields['shipping']['shipping_address_1'] ) ) {
|
1103 |
+
$fields['shipping']['shipping_address_1']['class'][] = 'form-row-full';
|
1104 |
+
}
|
1105 |
+
}
|
1106 |
+
|
1107 |
+
if ( isset( $fields['billing']['billing_city'] ) &&
|
1108 |
+
isset( $fields['billing']['billing_state'] ) && isset( $fields['billing']['billing_postcode'] ) ) {
|
1109 |
+
|
1110 |
+
$fields['billing']['billing_city']['class'][] = 'wcf-column-33';
|
1111 |
+
$fields['billing']['billing_state']['class'][] = 'wcf-column-33';
|
1112 |
+
$fields['billing']['billing_postcode']['class'][] = 'wcf-column-33';
|
1113 |
+
}
|
1114 |
+
|
1115 |
+
if ( isset( $fields['shipping']['shipping_city'] ) &&
|
1116 |
+
isset( $fields['shipping']['shipping_state'] ) && isset( $fields['shipping']['shipping_postcode'] ) ) {
|
1117 |
+
|
1118 |
+
$fields['shipping']['shipping_city']['class'][] = 'wcf-column-33';
|
1119 |
+
$fields['shipping']['shipping_state']['class'][] = 'wcf-column-33';
|
1120 |
+
$fields['shipping']['shipping_postcode']['class'][] = 'wcf-column-33';
|
1121 |
+
}
|
1122 |
+
|
1123 |
+
return $fields;
|
1124 |
+
}
|
1125 |
+
|
1126 |
+
/**
|
1127 |
+
* Add opening dev
|
1128 |
+
*
|
1129 |
+
* @since 1.0.0
|
1130 |
+
*/
|
1131 |
+
public function order_wrap_div_start() {
|
1132 |
+
|
1133 |
+
echo "<div class='wcf-order-wrap'> ";
|
1134 |
+
}
|
1135 |
+
|
1136 |
+
/**
|
1137 |
+
* Add closing dev
|
1138 |
+
*
|
1139 |
+
* @since 1.0.0
|
1140 |
+
*/
|
1141 |
+
public function order_wrap_div_end() {
|
1142 |
+
|
1143 |
+
echo '</div> ';
|
1144 |
+
}
|
1145 |
+
/**
|
1146 |
+
* Remove coupon.
|
1147 |
+
*/
|
1148 |
+
public function remove_coupon() {
|
1149 |
+
|
1150 |
+
check_ajax_referer( 'wcf-remove-coupon', 'security' );
|
1151 |
+
$coupon = isset( $_POST['coupon_code'] ) ? wc_clean( wp_unslash( $_POST['coupon_code'] ) ) : false; //phpcs:ignore
|
1152 |
+
|
1153 |
+
if ( empty( $coupon ) ) {
|
1154 |
+
echo "<div class='woocommerce-error'>" . esc_html__( 'Sorry there was a problem removing this coupon.', 'cartflows' );
|
1155 |
+
} else {
|
1156 |
+
WC()->cart->remove_coupon( $coupon );
|
1157 |
+
echo "<div class='woocommerce-error'>" . esc_html__( 'Coupon has been removed.', 'cartflows' ) . '</div>';
|
1158 |
+
}
|
1159 |
+
wc_print_notices();
|
1160 |
+
wp_die();
|
1161 |
+
}
|
1162 |
+
|
1163 |
+
/**
|
1164 |
+
* Remove cart item.
|
1165 |
+
*/
|
1166 |
+
public function wcf_woo_remove_cart_product() {
|
1167 |
+
|
1168 |
+
check_ajax_referer( 'wcf-remove-cart-product', 'security' );
|
1169 |
+
$product_key = isset( $_POST['p_key'] ) ? wc_clean( wp_unslash( $_POST['p_key'] ) ) : false; //phpcs:ignore
|
1170 |
+
$product_id = isset( $_POST['p_id'] ) ? wc_clean( wp_unslash( $_POST['p_id'] ) ) : ''; //phpcs:ignore
|
1171 |
+
$product_title = get_the_title( $product_id );
|
1172 |
+
|
1173 |
+
$needs_shipping = false;
|
1174 |
+
|
1175 |
+
if ( empty( $product_key ) ) {
|
1176 |
+
$msg = "<div class='woocommerce-message'>" . __( 'Sorry there was a problem removing ', 'cartflows' ) . $product_title;
|
1177 |
+
} else {
|
1178 |
+
WC()->cart->remove_cart_item( $product_key );
|
1179 |
+
$msg = "<div class='woocommerce-message'>" . $product_title . __( ' has been removed.', 'cartflows' ) . '</div>';
|
1180 |
+
}
|
1181 |
+
|
1182 |
+
foreach ( WC()->cart->get_cart() as $cart_item_key => $values ) {
|
1183 |
+
if ( $values['data']->needs_shipping() ) {
|
1184 |
+
$needs_shipping = true;
|
1185 |
+
break;
|
1186 |
+
}
|
1187 |
+
}
|
1188 |
+
|
1189 |
+
$response = array(
|
1190 |
+
'need_shipping' => $needs_shipping,
|
1191 |
+
'msg' => $msg,
|
1192 |
+
);
|
1193 |
+
|
1194 |
+
echo wp_json_encode( $response );
|
1195 |
+
wp_die();
|
1196 |
+
}
|
1197 |
+
|
1198 |
+
/**
|
1199 |
+
* Calculate discount for product.
|
1200 |
+
*
|
1201 |
+
* @param string $discount_coupon discount coupon.
|
1202 |
+
* @param string $discount_type discount type.
|
1203 |
+
* @param int $discount_value discount value.
|
1204 |
+
* @param int $_product_price product price.
|
1205 |
+
* @return int
|
1206 |
+
* @since 1.1.5
|
1207 |
+
*/
|
1208 |
+
public function calculate_discount( $discount_coupon, $discount_type, $discount_value, $_product_price ) {
|
1209 |
+
|
1210 |
+
$custom_price = '';
|
1211 |
+
|
1212 |
+
if ( ! empty( $discount_type ) ) {
|
1213 |
+
if ( 'discount_percent' === $discount_type ) {
|
1214 |
+
|
1215 |
+
if ( $discount_value > 0 ) {
|
1216 |
+
$custom_price = $_product_price - ( ( $_product_price * $discount_value ) / 100 );
|
1217 |
+
}
|
1218 |
+
} elseif ( 'discount_price' === $discount_type ) {
|
1219 |
+
|
1220 |
+
if ( $discount_value > 0 ) {
|
1221 |
+
$custom_price = $_product_price - $discount_value;
|
1222 |
+
}
|
1223 |
+
} elseif ( 'coupon' === $discount_type ) {
|
1224 |
+
|
1225 |
+
if ( ! empty( $discount_coupon ) ) {
|
1226 |
+
WC()->cart->add_discount( $discount_coupon );
|
1227 |
+
}
|
1228 |
+
}
|
1229 |
+
}
|
1230 |
+
|
1231 |
+
return $custom_price;
|
1232 |
+
}
|
1233 |
+
|
1234 |
+
/**
|
1235 |
+
* Preserve the custom item price added by Variations & Quantity feature
|
1236 |
+
*
|
1237 |
+
* @param array $cart_object cart object.
|
1238 |
+
* @since 1.0.0
|
1239 |
+
*/
|
1240 |
+
public function custom_price_to_cart_item( $cart_object ) {
|
1241 |
+
|
1242 |
+
if ( wp_doing_ajax() && ! WC()->session->__isset( 'reload_checkout' ) ) {
|
1243 |
+
|
1244 |
+
foreach ( $cart_object->cart_contents as $key => $value ) {
|
1245 |
+
|
1246 |
+
if ( isset( $value['custom_price'] ) ) {
|
1247 |
+
|
1248 |
+
$custom_price = floatval( $value['custom_price'] );
|
1249 |
+
$value['data']->set_price( $custom_price );
|
1250 |
+
}
|
1251 |
+
}
|
1252 |
+
}
|
1253 |
+
}
|
1254 |
+
|
1255 |
+
}
|
1256 |
+
|
1257 |
+
/**
|
1258 |
+
* Kicking this off by calling 'get_instance()' method
|
1259 |
+
*/
|
1260 |
+
Cartflows_Checkout_Markup::get_instance();
|
modules/checkout/classes/class-cartflows-checkout-meta.php
CHANGED
@@ -1,915 +1,959 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Checkout post meta
|
4 |
-
*
|
5 |
-
* @package CartFlows
|
6 |
-
*/
|
7 |
-
|
8 |
-
/**
|
9 |
-
* Meta Boxes setup
|
10 |
-
*/
|
11 |
-
class Cartflows_Checkout_Meta extends Cartflows_Meta {
|
12 |
-
|
13 |
-
|
14 |
-
/**
|
15 |
-
* Instance
|
16 |
-
*
|
17 |
-
* @var $instance
|
18 |
-
*/
|
19 |
-
private static $instance;
|
20 |
-
|
21 |
-
/**
|
22 |
-
* Meta Option
|
23 |
-
*
|
24 |
-
* @var $meta_option
|
25 |
-
*/
|
26 |
-
private static $meta_option = null;
|
27 |
-
|
28 |
-
/**
|
29 |
-
* Initiator
|
30 |
-
*/
|
31 |
-
public static function get_instance() {
|
32 |
-
if ( ! isset( self::$instance ) ) {
|
33 |
-
self::$instance = new self();
|
34 |
-
}
|
35 |
-
|
36 |
-
return self::$instance;
|
37 |
-
}
|
38 |
-
|
39 |
-
/**
|
40 |
-
* Constructor
|
41 |
-
*/
|
42 |
-
public function __construct() {
|
43 |
-
|
44 |
-
/* Init Metabox */
|
45 |
-
add_action( 'load-post.php', array( $this, 'init_metabox' ) );
|
46 |
-
add_action( 'load-post-new.php', array( $this, 'init_metabox' ) );
|
47 |
-
}
|
48 |
-
/**
|
49 |
-
* Init Metabox
|
50 |
-
*/
|
51 |
-
public function init_metabox() {
|
52 |
-
|
53 |
-
add_action( 'add_meta_boxes', array( $this, 'setup_meta_box' ) );
|
54 |
-
add_action( 'save_post', array( $this, 'save_meta_box' ) );
|
55 |
-
}
|
56 |
-
|
57 |
-
/**
|
58 |
-
* Setup Metabox
|
59 |
-
*/
|
60 |
-
public function setup_meta_box() {
|
61 |
-
|
62 |
-
if ( _is_wcf_checkout_type() ) {
|
63 |
-
add_meta_box(
|
64 |
-
'wcf-checkout-settings', // Id.
|
65 |
-
__( 'Checkout Layout', 'cartflows' ), // Title.
|
66 |
-
array( $this, 'markup_meta_box' ), // Callback.
|
67 |
-
wcf()->utils->get_step_post_type(), // Post_type.
|
68 |
-
'normal', // Context.
|
69 |
-
'high' // Priority.
|
70 |
-
);
|
71 |
-
}
|
72 |
-
}
|
73 |
-
|
74 |
-
/**
|
75 |
-
* Metabox Markup
|
76 |
-
*
|
77 |
-
* @param object $post Post object.
|
78 |
-
* @return void
|
79 |
-
*/
|
80 |
-
public function markup_meta_box( $post ) {
|
81 |
-
|
82 |
-
wp_nonce_field( 'save-nonce-checkout-step-meta', 'nonce-checkout-step-meta' );
|
83 |
-
|
84 |
-
$stored = get_post_meta( $post->ID );
|
85 |
-
|
86 |
-
$checkout_meta = self::get_meta_option( $post->ID );
|
87 |
-
|
88 |
-
// Set stored and override defaults.
|
89 |
-
foreach ( $stored as $key => $value ) {
|
90 |
-
if ( array_key_exists( $key, $checkout_meta ) ) {
|
91 |
-
self::$meta_option[ $key ]['default'] = ( isset( $stored[ $key ][0] ) ) ? maybe_unserialize( $stored[ $key ][0] ) : '';
|
92 |
-
} else {
|
93 |
-
self::$meta_option[ $key ]['default'] = ( isset( $stored[ $key ][0] ) ) ? $stored[ $key ][0] : '';
|
94 |
-
}
|
95 |
-
}
|
96 |
-
|
97 |
-
// Get defaults.
|
98 |
-
$meta = self::get_meta_option( $post->ID );
|
99 |
-
$checkout_data = array();
|
100 |
-
|
101 |
-
foreach ( $meta as $key => $value ) {
|
102 |
-
$checkout_data[ $key ] = $meta[ $key ]['default'];
|
103 |
-
}
|
104 |
-
|
105 |
-
/**
|
106 |
-
$billing_fields = Cartflows_Helper::get_checkout_fields( 'billing', $post->ID );
|
107 |
-
|
108 |
-
// For loop
|
109 |
-
foreach ( $billing_fields as $key => $value ) {
|
110 |
-
|
111 |
-
$checkout_data[ 'wcf-' . $key ] = $meta[ 'wcf-' . $key ]['default'];
|
112 |
-
}
|
113 |
-
|
114 |
-
$shipping_fields = Cartflows_Helper::get_checkout_fields( 'shipping', $post->ID );
|
115 |
-
|
116 |
-
foreach ( $shipping_fields as $key => $value ) {
|
117 |
-
|
118 |
-
$checkout_data[ 'wcf-' . $key ] = $meta[ 'wcf-' . $key ]['default'];
|
119 |
-
}
|
120 |
-
|
121 |
-
$additional_fields = Cartflows_Helper::get_checkout_fields( 'additional', $post->ID );
|
122 |
-
|
123 |
-
foreach ( $additional_fields as $key => $value ) {
|
124 |
-
|
125 |
-
$checkout_data[ 'wcf-' . $key ] = $meta[ 'wcf-' . $key ]['default'];
|
126 |
-
}
|
127 |
-
*/
|
128 |
-
|
129 |
-
do_action( 'wcf_checkout_settings_markup_before' );
|
130 |
-
$this->tabs_markup( $checkout_data, $post->ID );
|
131 |
-
do_action( 'wcf_checkout_settings_markup_after' );
|
132 |
-
}
|
133 |
-
|
134 |
-
/**
|
135 |
-
* Page Header Tabs
|
136 |
-
*
|
137 |
-
* @param array $options options.
|
138 |
-
* @param int $post_id post ID.
|
139 |
-
*/
|
140 |
-
public function tabs_markup( $options, $post_id ) {
|
141 |
-
|
142 |
-
$active_tab = get_post_meta( $post_id, 'wcf-active-tab', true );
|
143 |
-
|
144 |
-
if ( empty( $active_tab ) ) {
|
145 |
-
$active_tab = 'wcf-checkout-shortcodes';
|
146 |
-
}
|
147 |
-
|
148 |
-
$tab_array = array(
|
149 |
-
array(
|
150 |
-
'title' => __( 'Shortcodes', 'cartflows' ),
|
151 |
-
'id' => 'wcf-checkout-shortcodes',
|
152 |
-
'class' => 'wcf-checkout-shortcodes' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
153 |
-
'icon' => 'dashicons-editor-code',
|
154 |
-
),
|
155 |
-
array(
|
156 |
-
'title' => __( 'Select Product', 'cartflows' ),
|
157 |
-
'id' => 'wcf-checkout-general',
|
158 |
-
'class' => 'wcf-checkout-general' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
159 |
-
'icon' => 'dashicons-info',
|
160 |
-
),
|
161 |
-
array(
|
162 |
-
'title' => __( '
|
163 |
-
'id' => 'wcf-product-
|
164 |
-
'class' => 'wcf-product-
|
165 |
-
'icon' => 'dashicons-
|
166 |
-
),
|
167 |
-
array(
|
168 |
-
'title' => __( '
|
169 |
-
'id' => 'wcf-
|
170 |
-
'class' => 'wcf-
|
171 |
-
'icon' => 'dashicons-
|
172 |
-
),
|
173 |
-
array(
|
174 |
-
'title' => __( 'Checkout
|
175 |
-
'id' => 'wcf-checkout-
|
176 |
-
'class' => 'wcf-checkout-
|
177 |
-
'icon' => 'dashicons-
|
178 |
-
),
|
179 |
-
array(
|
180 |
-
'title' => __( 'Checkout
|
181 |
-
'id' => 'wcf-checkout-
|
182 |
-
'class' => 'wcf-checkout-
|
183 |
-
'icon' => 'dashicons-
|
184 |
-
),
|
185 |
-
array(
|
186 |
-
'title' => __( 'Checkout
|
187 |
-
'id' => 'wcf-checkout-custom-
|
188 |
-
'class' => 'wcf-checkout-custom-
|
189 |
-
'icon' => 'dashicons-
|
190 |
-
),
|
191 |
-
array(
|
192 |
-
'title' => __( '
|
193 |
-
'id' => 'wcf-checkout-custom-
|
194 |
-
'class' => 'wcf-checkout-custom-
|
195 |
-
'icon' => 'dashicons-
|
196 |
-
),
|
197 |
-
|
198 |
-
|
199 |
-
|
200 |
-
|
201 |
-
|
202 |
-
|
203 |
-
|
204 |
-
|
205 |
-
|
206 |
-
|
207 |
-
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
|
229 |
-
|
230 |
-
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
|
236 |
-
<?php $this->
|
237 |
-
<?php $this->
|
238 |
-
<?php $this->
|
239 |
-
<?php
|
240 |
-
<?php $this->
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
|
251 |
-
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
|
257 |
-
|
258 |
-
|
259 |
-
|
260 |
-
|
261 |
-
|
262 |
-
|
263 |
-
|
264 |
-
|
265 |
-
|
266 |
-
)
|
267 |
-
|
268 |
-
|
269 |
-
|
270 |
-
|
271 |
-
|
272 |
-
|
273 |
-
|
274 |
-
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
|
280 |
-
|
281 |
-
|
282 |
-
|
283 |
-
|
284 |
-
|
285 |
-
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
-
|
290 |
-
|
291 |
-
|
292 |
-
|
293 |
-
|
294 |
-
|
295 |
-
|
296 |
-
|
297 |
-
|
298 |
-
|
299 |
-
|
300 |
-
|
301 |
-
|
302 |
-
|
303 |
-
|
304 |
-
|
305 |
-
|
306 |
-
|
307 |
-
|
308 |
-
|
309 |
-
|
310 |
-
|
311 |
-
|
312 |
-
|
313 |
-
|
314 |
-
|
315 |
-
|
316 |
-
|
317 |
-
|
318 |
-
|
319 |
-
|
320 |
-
|
321 |
-
|
322 |
-
|
323 |
-
|
324 |
-
|
325 |
-
|
326 |
-
|
327 |
-
|
328 |
-
|
329 |
-
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
338 |
-
|
339 |
-
|
340 |
-
);
|
341 |
-
|
342 |
-
|
343 |
-
|
344 |
-
|
345 |
-
|
346 |
-
|
347 |
-
|
348 |
-
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
|
354 |
-
|
355 |
-
|
356 |
-
|
357 |
-
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
)
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
372 |
-
|
373 |
-
|
374 |
-
|
375 |
-
|
376 |
-
|
377 |
-
|
378 |
-
|
379 |
-
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
393 |
-
|
394 |
-
|
395 |
-
|
396 |
-
|
397 |
-
|
398 |
-
|
399 |
-
|
400 |
-
|
401 |
-
|
402 |
-
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
|
411 |
-
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
|
418 |
-
|
419 |
-
|
420 |
-
|
421 |
-
|
422 |
-
|
423 |
-
|
424 |
-
|
425 |
-
|
426 |
-
|
427 |
-
|
428 |
-
|
429 |
-
|
430 |
-
|
431 |
-
|
432 |
-
|
433 |
-
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
|
444 |
-
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
|
455 |
-
|
456 |
-
|
457 |
-
|
458 |
-
|
459 |
-
|
460 |
-
|
461 |
-
|
462 |
-
|
463 |
-
|
464 |
-
|
465 |
-
|
466 |
-
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
|
473 |
-
|
474 |
-
|
475 |
-
|
476 |
-
|
477 |
-
|
478 |
-
|
479 |
-
|
480 |
-
|
481 |
-
|
482 |
-
|
483 |
-
|
484 |
-
|
485 |
-
|
486 |
-
|
487 |
-
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
|
495 |
-
|
496 |
-
|
497 |
-
|
498 |
-
|
499 |
-
|
500 |
-
|
501 |
-
|
502 |
-
|
503 |
-
|
504 |
-
|
505 |
-
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
|
512 |
-
|
513 |
-
|
514 |
-
|
515 |
-
|
516 |
-
|
517 |
-
|
518 |
-
|
519 |
-
|
520 |
-
|
521 |
-
|
522 |
-
|
523 |
-
|
524 |
-
|
525 |
-
|
526 |
-
|
527 |
-
|
528 |
-
|
529 |
-
|
530 |
-
|
531 |
-
|
532 |
-
|
533 |
-
|
534 |
-
|
535 |
-
|
536 |
-
|
537 |
-
|
538 |
-
|
539 |
-
|
540 |
-
|
541 |
-
|
542 |
-
|
543 |
-
|
544 |
-
|
545 |
-
|
546 |
-
|
547 |
-
|
548 |
-
|
549 |
-
|
550 |
-
|
551 |
-
echo wcf()->meta->
|
552 |
-
array(
|
553 |
-
'label'
|
554 |
-
|
555 |
-
|
556 |
-
|
557 |
-
|
558 |
-
|
559 |
-
|
560 |
-
|
561 |
-
'
|
562 |
-
|
563 |
-
|
564 |
-
|
565 |
-
|
566 |
-
|
567 |
-
|
568 |
-
'label' =>
|
569 |
-
'name' => 'wcf-
|
570 |
-
'value' => $options['wcf-
|
571 |
-
)
|
572 |
-
);
|
573 |
-
|
574 |
-
echo wcf()->meta->
|
575 |
-
array(
|
576 |
-
'for' => 'wcf-
|
577 |
-
'label' => esc_html__( 'Font
|
578 |
-
'name' => 'wcf-
|
579 |
-
'value' => $options['wcf-
|
580 |
-
)
|
581 |
-
);
|
582 |
-
|
583 |
-
echo wcf()->meta->
|
584 |
-
array(
|
585 |
-
'label' => __( '
|
586 |
-
|
587 |
-
|
588 |
-
|
589 |
-
|
590 |
-
|
591 |
-
|
592 |
-
|
593 |
-
|
594 |
-
|
595 |
-
|
596 |
-
|
597 |
-
|
598 |
-
|
599 |
-
|
600 |
-
|
601 |
-
|
602 |
-
|
603 |
-
|
604 |
-
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
-
|
609 |
-
)
|
610 |
-
|
611 |
-
|
612 |
-
|
613 |
-
'
|
614 |
-
'
|
615 |
-
|
616 |
-
|
617 |
-
|
618 |
-
)
|
619 |
-
|
620 |
-
|
621 |
-
|
622 |
-
'
|
623 |
-
'
|
624 |
-
|
625 |
-
|
626 |
-
|
627 |
-
)
|
628 |
-
|
629 |
-
|
630 |
-
|
631 |
-
|
632 |
-
|
633 |
-
|
634 |
-
|
635 |
-
|
636 |
-
|
637 |
-
|
638 |
-
|
639 |
-
|
640 |
-
|
641 |
-
|
642 |
-
|
643 |
-
|
644 |
-
|
645 |
-
|
646 |
-
|
647 |
-
|
648 |
-
|
649 |
-
|
650 |
-
|
651 |
-
|
652 |
-
|
653 |
-
|
654 |
-
|
655 |
-
|
656 |
-
|
657 |
-
'
|
658 |
-
|
659 |
-
|
660 |
-
|
661 |
-
|
662 |
-
|
663 |
-
|
664 |
-
|
665 |
-
|
666 |
-
|
667 |
-
|
668 |
-
|
669 |
-
|
670 |
-
|
671 |
-
|
672 |
-
|
673 |
-
|
674 |
-
|
675 |
-
|
676 |
-
|
677 |
-
|
678 |
-
|
679 |
-
|
680 |
-
|
681 |
-
|
682 |
-
|
683 |
-
|
684 |
-
|
685 |
-
|
686 |
-
|
687 |
-
|
688 |
-
|
689 |
-
|
690 |
-
|
691 |
-
|
692 |
-
|
693 |
-
|
694 |
-
|
695 |
-
|
696 |
-
|
697 |
-
echo wcf()->meta->
|
698 |
-
array(
|
699 |
-
'label' => __( '
|
700 |
-
|
701 |
-
|
702 |
-
|
703 |
-
|
704 |
-
|
705 |
-
|
706 |
-
|
707 |
-
'
|
708 |
-
'
|
709 |
-
|
710 |
-
|
711 |
-
|
712 |
-
|
713 |
-
|
714 |
-
|
715 |
-
'label' =>
|
716 |
-
'name' => 'wcf-
|
717 |
-
'value' => $options['wcf-
|
718 |
-
)
|
719 |
-
);
|
720 |
-
|
721 |
-
echo wcf()->meta->
|
722 |
-
array(
|
723 |
-
'label'
|
724 |
-
'name'
|
725 |
-
'value'
|
726 |
-
|
727 |
-
|
728 |
-
|
729 |
-
|
730 |
-
|
731 |
-
|
732 |
-
|
733 |
-
|
734 |
-
|
735 |
-
|
736 |
-
|
737 |
-
|
738 |
-
|
739 |
-
|
740 |
-
|
741 |
-
|
742 |
-
|
743 |
-
|
744 |
-
|
745 |
-
|
746 |
-
|
747 |
-
|
748 |
-
|
749 |
-
'
|
750 |
-
|
751 |
-
|
752 |
-
|
753 |
-
|
754 |
-
|
755 |
-
|
756 |
-
|
757 |
-
|
758 |
-
|
759 |
-
|
760 |
-
|
761 |
-
|
762 |
-
|
763 |
-
|
764 |
-
|
765 |
-
|
766 |
-
|
767 |
-
|
768 |
-
|
769 |
-
|
770 |
-
|
771 |
-
|
772 |
-
|
773 |
-
|
774 |
-
|
775 |
-
|
776 |
-
|
777 |
-
|
778 |
-
|
779 |
-
|
780 |
-
|
781 |
-
|
782 |
-
|
783 |
-
|
784 |
-
|
785 |
-
|
786 |
-
|
787 |
-
|
788 |
-
|
789 |
-
|
790 |
-
|
791 |
-
|
792 |
-
|
793 |
-
|
794 |
-
|
795 |
-
|
796 |
-
|
797 |
-
|
798 |
-
|
799 |
-
|
800 |
-
|
801 |
-
|
802 |
-
|
803 |
-
|
804 |
-
|
805 |
-
|
806 |
-
|
807 |
-
|
808 |
-
'
|
809 |
-
|
810 |
-
|
811 |
-
|
812 |
-
|
813 |
-
|
814 |
-
|
815 |
-
'
|
816 |
-
'
|
817 |
-
|
818 |
-
|
819 |
-
|
820 |
-
|
821 |
-
|
822 |
-
|
823 |
-
'
|
824 |
-
|
825 |
-
|
826 |
-
|
827 |
-
|
828 |
-
|
829 |
-
|
830 |
-
|
831 |
-
|
832 |
-
|
833 |
-
|
834 |
-
|
835 |
-
|
836 |
-
|
837 |
-
|
838 |
-
|
839 |
-
|
840 |
-
|
841 |
-
|
842 |
-
|
843 |
-
|
844 |
-
|
845 |
-
|
846 |
-
|
847 |
-
|
848 |
-
|
849 |
-
|
850 |
-
|
851 |
-
|
852 |
-
|
853 |
-
|
854 |
-
|
855 |
-
|
856 |
-
|
857 |
-
|
858 |
-
|
859 |
-
|
860 |
-
|
861 |
-
|
862 |
-
|
863 |
-
|
864 |
-
|
865 |
-
|
866 |
-
|
867 |
-
|
868 |
-
|
869 |
-
|
870 |
-
|
871 |
-
|
872 |
-
|
873 |
-
|
874 |
-
|
875 |
-
|
876 |
-
|
877 |
-
|
878 |
-
|
879 |
-
|
880 |
-
|
881 |
-
|
882 |
-
|
883 |
-
|
884 |
-
|
885 |
-
|
886 |
-
|
887 |
-
|
888 |
-
|
889 |
-
|
890 |
-
|
891 |
-
|
892 |
-
|
893 |
-
|
894 |
-
|
895 |
-
|
896 |
-
|
897 |
-
|
898 |
-
|
899 |
-
|
900 |
-
|
901 |
-
|
902 |
-
|
903 |
-
|
904 |
-
|
905 |
-
|
906 |
-
|
907 |
-
|
908 |
-
|
909 |
-
|
910 |
-
|
911 |
-
|
912 |
-
|
913 |
-
|
914 |
-
|
915 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Checkout post meta
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
/**
|
9 |
+
* Meta Boxes setup
|
10 |
+
*/
|
11 |
+
class Cartflows_Checkout_Meta extends Cartflows_Meta {
|
12 |
+
|
13 |
+
|
14 |
+
/**
|
15 |
+
* Instance
|
16 |
+
*
|
17 |
+
* @var $instance
|
18 |
+
*/
|
19 |
+
private static $instance;
|
20 |
+
|
21 |
+
/**
|
22 |
+
* Meta Option
|
23 |
+
*
|
24 |
+
* @var $meta_option
|
25 |
+
*/
|
26 |
+
private static $meta_option = null;
|
27 |
+
|
28 |
+
/**
|
29 |
+
* Initiator
|
30 |
+
*/
|
31 |
+
public static function get_instance() {
|
32 |
+
if ( ! isset( self::$instance ) ) {
|
33 |
+
self::$instance = new self();
|
34 |
+
}
|
35 |
+
|
36 |
+
return self::$instance;
|
37 |
+
}
|
38 |
+
|
39 |
+
/**
|
40 |
+
* Constructor
|
41 |
+
*/
|
42 |
+
public function __construct() {
|
43 |
+
|
44 |
+
/* Init Metabox */
|
45 |
+
add_action( 'load-post.php', array( $this, 'init_metabox' ) );
|
46 |
+
add_action( 'load-post-new.php', array( $this, 'init_metabox' ) );
|
47 |
+
}
|
48 |
+
/**
|
49 |
+
* Init Metabox
|
50 |
+
*/
|
51 |
+
public function init_metabox() {
|
52 |
+
|
53 |
+
add_action( 'add_meta_boxes', array( $this, 'setup_meta_box' ) );
|
54 |
+
add_action( 'save_post', array( $this, 'save_meta_box' ) );
|
55 |
+
}
|
56 |
+
|
57 |
+
/**
|
58 |
+
* Setup Metabox
|
59 |
+
*/
|
60 |
+
public function setup_meta_box() {
|
61 |
+
|
62 |
+
if ( _is_wcf_checkout_type() ) {
|
63 |
+
add_meta_box(
|
64 |
+
'wcf-checkout-settings', // Id.
|
65 |
+
__( 'Checkout Layout', 'cartflows' ), // Title.
|
66 |
+
array( $this, 'markup_meta_box' ), // Callback.
|
67 |
+
wcf()->utils->get_step_post_type(), // Post_type.
|
68 |
+
'normal', // Context.
|
69 |
+
'high' // Priority.
|
70 |
+
);
|
71 |
+
}
|
72 |
+
}
|
73 |
+
|
74 |
+
/**
|
75 |
+
* Metabox Markup
|
76 |
+
*
|
77 |
+
* @param object $post Post object.
|
78 |
+
* @return void
|
79 |
+
*/
|
80 |
+
public function markup_meta_box( $post ) {
|
81 |
+
|
82 |
+
wp_nonce_field( 'save-nonce-checkout-step-meta', 'nonce-checkout-step-meta' );
|
83 |
+
|
84 |
+
$stored = get_post_meta( $post->ID );
|
85 |
+
|
86 |
+
$checkout_meta = self::get_meta_option( $post->ID );
|
87 |
+
|
88 |
+
// Set stored and override defaults.
|
89 |
+
foreach ( $stored as $key => $value ) {
|
90 |
+
if ( array_key_exists( $key, $checkout_meta ) ) {
|
91 |
+
self::$meta_option[ $key ]['default'] = ( isset( $stored[ $key ][0] ) ) ? maybe_unserialize( $stored[ $key ][0] ) : '';
|
92 |
+
} else {
|
93 |
+
self::$meta_option[ $key ]['default'] = ( isset( $stored[ $key ][0] ) ) ? $stored[ $key ][0] : '';
|
94 |
+
}
|
95 |
+
}
|
96 |
+
|
97 |
+
// Get defaults.
|
98 |
+
$meta = self::get_meta_option( $post->ID );
|
99 |
+
$checkout_data = array();
|
100 |
+
|
101 |
+
foreach ( $meta as $key => $value ) {
|
102 |
+
$checkout_data[ $key ] = $meta[ $key ]['default'];
|
103 |
+
}
|
104 |
+
|
105 |
+
/**
|
106 |
+
$billing_fields = Cartflows_Helper::get_checkout_fields( 'billing', $post->ID );
|
107 |
+
|
108 |
+
// For loop
|
109 |
+
foreach ( $billing_fields as $key => $value ) {
|
110 |
+
|
111 |
+
$checkout_data[ 'wcf-' . $key ] = $meta[ 'wcf-' . $key ]['default'];
|
112 |
+
}
|
113 |
+
|
114 |
+
$shipping_fields = Cartflows_Helper::get_checkout_fields( 'shipping', $post->ID );
|
115 |
+
|
116 |
+
foreach ( $shipping_fields as $key => $value ) {
|
117 |
+
|
118 |
+
$checkout_data[ 'wcf-' . $key ] = $meta[ 'wcf-' . $key ]['default'];
|
119 |
+
}
|
120 |
+
|
121 |
+
$additional_fields = Cartflows_Helper::get_checkout_fields( 'additional', $post->ID );
|
122 |
+
|
123 |
+
foreach ( $additional_fields as $key => $value ) {
|
124 |
+
|
125 |
+
$checkout_data[ 'wcf-' . $key ] = $meta[ 'wcf-' . $key ]['default'];
|
126 |
+
}
|
127 |
+
*/
|
128 |
+
|
129 |
+
do_action( 'wcf_checkout_settings_markup_before' );
|
130 |
+
$this->tabs_markup( $checkout_data, $post->ID );
|
131 |
+
do_action( 'wcf_checkout_settings_markup_after' );
|
132 |
+
}
|
133 |
+
|
134 |
+
/**
|
135 |
+
* Page Header Tabs
|
136 |
+
*
|
137 |
+
* @param array $options options.
|
138 |
+
* @param int $post_id post ID.
|
139 |
+
*/
|
140 |
+
public function tabs_markup( $options, $post_id ) {
|
141 |
+
|
142 |
+
$active_tab = get_post_meta( $post_id, 'wcf-active-tab', true );
|
143 |
+
|
144 |
+
if ( empty( $active_tab ) ) {
|
145 |
+
$active_tab = 'wcf-checkout-shortcodes';
|
146 |
+
}
|
147 |
+
|
148 |
+
$tab_array = array(
|
149 |
+
array(
|
150 |
+
'title' => __( 'Shortcodes', 'cartflows' ),
|
151 |
+
'id' => 'wcf-checkout-shortcodes',
|
152 |
+
'class' => 'wcf-checkout-shortcodes' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
153 |
+
'icon' => 'dashicons-editor-code',
|
154 |
+
),
|
155 |
+
array(
|
156 |
+
'title' => __( 'Select Product', 'cartflows' ),
|
157 |
+
'id' => 'wcf-checkout-general',
|
158 |
+
'class' => 'wcf-checkout-general' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
159 |
+
'icon' => 'dashicons-info',
|
160 |
+
),
|
161 |
+
array(
|
162 |
+
'title' => __( 'Product Options', 'cartflows' ),
|
163 |
+
'id' => 'wcf-product-options',
|
164 |
+
'class' => 'wcf-product-options' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
165 |
+
'icon' => 'dashicons dashicons-screenoptions',
|
166 |
+
),
|
167 |
+
array(
|
168 |
+
'title' => __( 'Order Bump', 'cartflows' ),
|
169 |
+
'id' => 'wcf-product-order-bump',
|
170 |
+
'class' => 'wcf-product-order-bump' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
171 |
+
'icon' => 'dashicons-cart',
|
172 |
+
),
|
173 |
+
array(
|
174 |
+
'title' => __( 'Checkout Offer', 'cartflows' ),
|
175 |
+
'id' => 'wcf-pre-checkout-offer',
|
176 |
+
'class' => 'wcf-pre-checkout-offer' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
177 |
+
'icon' => 'dashicons-arrow-up-alt',
|
178 |
+
),
|
179 |
+
array(
|
180 |
+
'title' => __( 'Checkout Design', 'cartflows' ),
|
181 |
+
'id' => 'wcf-checkout-style',
|
182 |
+
'class' => 'wcf-checkout-style' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
183 |
+
'icon' => 'dashicons-admin-customizer',
|
184 |
+
),
|
185 |
+
array(
|
186 |
+
'title' => __( 'Checkout Fields', 'cartflows' ),
|
187 |
+
'id' => 'wcf-checkout-custom-fields',
|
188 |
+
'class' => 'wcf-checkout-custom-fields' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
189 |
+
'icon' => 'dashicons-welcome-widgets-menus',
|
190 |
+
),
|
191 |
+
array(
|
192 |
+
'title' => __( 'Checkout Settings', 'cartflows' ),
|
193 |
+
'id' => 'wcf-checkout-custom-settings',
|
194 |
+
'class' => 'wcf-checkout-custom-settings' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
195 |
+
'icon' => 'dashicons-admin-generic',
|
196 |
+
),
|
197 |
+
array(
|
198 |
+
'title' => __( 'Custom Script', 'cartflows' ),
|
199 |
+
'id' => 'wcf-checkout-custom-script-header',
|
200 |
+
'class' => 'wcf-checkout-custom-script-header' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
201 |
+
'icon' => 'dashicons-format-aside',
|
202 |
+
),
|
203 |
+
);
|
204 |
+
|
205 |
+
$show_logo = filter_input( INPUT_GET, 'logo-tab', FILTER_VALIDATE_BOOLEAN );
|
206 |
+
|
207 |
+
if ( $show_logo ) {
|
208 |
+
$logo_tab = array(
|
209 |
+
'title' => __( 'Logo (Optional)', 'cartflows' ),
|
210 |
+
'id' => 'wcf-checkout-header',
|
211 |
+
'class' => 'wcf-checkout-header' === $active_tab ? 'wcf-tab wp-ui-text-highlight active' : 'wcf-tab',
|
212 |
+
'icon' => 'dashicons-format-image',
|
213 |
+
);
|
214 |
+
array_push( $tab_array, $logo_tab );
|
215 |
+
}
|
216 |
+
|
217 |
+
$tabs = apply_filters( 'cartflows_checkout_tabs', $tab_array, $active_tab );
|
218 |
+
|
219 |
+
?>
|
220 |
+
<div class="wcf-checkout-table wcf-metabox-wrap widefat">
|
221 |
+
<div class="wcf-table-container">
|
222 |
+
<div class="wcf-column-left">
|
223 |
+
<div class="wcf-tab-wrapper">
|
224 |
+
|
225 |
+
<?php foreach ( $tabs as $key => $tab ) { ?>
|
226 |
+
<div class="<?php echo esc_attr( $tab['class'] ); ?>" data-tab="<?php echo esc_attr( $tab['id'] ); ?>">
|
227 |
+
<span class="dashicons <?php echo esc_attr( $tab['icon'] ); ?>"></span>
|
228 |
+
<span class="wcf-tab-title"><?php echo esc_html( $tab['title'] ); ?></span>
|
229 |
+
</div>
|
230 |
+
<?php } ?>
|
231 |
+
|
232 |
+
<input type="hidden" id="wcf-active-tab" name="wcf-active-tab" value="<?php echo esc_attr( $active_tab ); ?>" />
|
233 |
+
</div>
|
234 |
+
</div>
|
235 |
+
<div class="wcf-column-right">
|
236 |
+
<?php $this->tab_shortcodes( $options, $post_id ); ?>
|
237 |
+
<?php $this->tab_general( $options, $post_id ); ?>
|
238 |
+
<?php $this->tab_product_options( $options, $post_id ); ?>
|
239 |
+
<?php $this->tab_style( $options, $post_id ); ?>
|
240 |
+
<?php $this->tab_pre_checkout_offer( $options, $post_id ); ?>
|
241 |
+
<?php $this->tab_product_bump( $options, $post_id ); ?>
|
242 |
+
<?php $this->tab_custom_fields( $options, $post_id ); ?>
|
243 |
+
<?php $this->tab_custom_settings( $options, $post_id ); ?>
|
244 |
+
<?php $this->tab_header_content( $options, $post_id ); ?>
|
245 |
+
<?php $this->tab_custom_script( $options, $post_id ); ?>
|
246 |
+
<?php do_action( 'cartflows_checkout_tabs_content', $options, $post_id ); ?>
|
247 |
+
<?php $this->right_column_footer( $options, $post_id ); ?>
|
248 |
+
</div>
|
249 |
+
</div>
|
250 |
+
</div>
|
251 |
+
|
252 |
+
<?php
|
253 |
+
}
|
254 |
+
|
255 |
+
/**
|
256 |
+
* Product options tab.
|
257 |
+
*
|
258 |
+
* @param array $options options.
|
259 |
+
* @param int $post_id post ID.
|
260 |
+
*/
|
261 |
+
public function tab_product_options( $options, $post_id ) {
|
262 |
+
?>
|
263 |
+
<div class="wcf-product-options wcf-tab-content widefat">
|
264 |
+
<?php
|
265 |
+
if ( ! _is_cartflows_pro() ) {
|
266 |
+
echo wcf()->meta->get_description_field(
|
267 |
+
array(
|
268 |
+
'name' => 'wcf-upgrade-to-pro',
|
269 |
+
/* translators: %s: link */
|
270 |
+
'content' => '<i>' . sprintf( esc_html__( 'Upgrade to %1$sCartFlows Pro%2$s for Product Options feature.', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>' ) . '</i>',
|
271 |
+
)
|
272 |
+
);
|
273 |
+
} elseif ( _is_cartflows_pro() && _is_cartflows_pro_ver_less_than( '1.5.4' ) ) {
|
274 |
+
$version = '1.5.4';
|
275 |
+
$file_path = 'cartflows-pro/cartflows-pro.php';
|
276 |
+
$upgrade_link = wp_nonce_url( self_admin_url( 'update.php?action=upgrade-plugin&plugin=' ) . $file_path, 'upgrade-plugin_' . $file_path );
|
277 |
+
echo wcf()->meta->get_description_field(
|
278 |
+
array(
|
279 |
+
'name' => 'wcf-upgrade-to-pro',
|
280 |
+
// translators: %s: link.
|
281 |
+
'content' => '<i>' . sprintf( esc_html__( 'Update %1$sCartFlows Pro%2$s to %3$s or above for Product Options', 'cartflows' ), '<a href="' . $upgrade_link . '" target="_blank">', '</a>', $version ) . '</i>',
|
282 |
+
)
|
283 |
+
);
|
284 |
+
}
|
285 |
+
|
286 |
+
do_action( 'cartflows_product_options_tab_content', $options, $post_id );
|
287 |
+
?>
|
288 |
+
</div>
|
289 |
+
<?php
|
290 |
+
}
|
291 |
+
|
292 |
+
/**
|
293 |
+
* Shortcodes tab
|
294 |
+
*
|
295 |
+
* @param array $options options.
|
296 |
+
* @param int $post_id post ID.
|
297 |
+
*/
|
298 |
+
public function tab_shortcodes( $options, $post_id ) {
|
299 |
+
?>
|
300 |
+
<div class="wcf-checkout-shortcodes wcf-tab-content widefat">
|
301 |
+
|
302 |
+
<?php
|
303 |
+
|
304 |
+
echo wcf()->meta->get_shortcode_field(
|
305 |
+
array(
|
306 |
+
'label' => 'Checkout Page',
|
307 |
+
'name' => 'wcf-checkout-shortcode',
|
308 |
+
'content' => '[cartflows_checkout]',
|
309 |
+
'help' => esc_html__( 'Add this shortcode to your checkout page', 'cartflows' ),
|
310 |
+
)
|
311 |
+
);
|
312 |
+
?>
|
313 |
+
</div>
|
314 |
+
<?php
|
315 |
+
}
|
316 |
+
|
317 |
+
|
318 |
+
/**
|
319 |
+
* General tab
|
320 |
+
*
|
321 |
+
* @param array $options options.
|
322 |
+
* @param int $post_id post ID.
|
323 |
+
*/
|
324 |
+
public function tab_general( $options, $post_id ) {
|
325 |
+
?>
|
326 |
+
<div class="wcf-checkout-general wcf-tab-content widefat">
|
327 |
+
|
328 |
+
<?php
|
329 |
+
|
330 |
+
echo wcf()->meta->get_product_selection_repeater(
|
331 |
+
array(
|
332 |
+
'name' => 'wcf-checkout-products',
|
333 |
+
'value' => $options['wcf-checkout-products'],
|
334 |
+
'allow_clear' => true,
|
335 |
+
)
|
336 |
+
);
|
337 |
+
|
338 |
+
if ( ! _is_cartflows_pro() ) {
|
339 |
+
|
340 |
+
echo wcf()->meta->get_hr_line_field( array() );
|
341 |
+
echo wcf()->meta->get_description_field(
|
342 |
+
array(
|
343 |
+
'name' => 'wcf-upgrade-to-pro',
|
344 |
+
/* translators: %s: link */
|
345 |
+
'content' => '<i>' . sprintf( esc_html__( 'Upgrade to %1$sCartFlows Pro%2$s for Pre-applied Coupon.', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>' ) . '</i>',
|
346 |
+
)
|
347 |
+
);
|
348 |
+
}
|
349 |
+
|
350 |
+
do_action( 'cartflows_checkout_general_tab_content', $options, $post_id );
|
351 |
+
|
352 |
+
?>
|
353 |
+
</div>
|
354 |
+
<?php
|
355 |
+
}
|
356 |
+
|
357 |
+
/**
|
358 |
+
* Pre Checkout tab
|
359 |
+
*
|
360 |
+
* @param array $options options.
|
361 |
+
* @param int $post_id post ID.
|
362 |
+
*/
|
363 |
+
public function tab_pre_checkout_offer( $options, $post_id ) {
|
364 |
+
?>
|
365 |
+
<div class="wcf-pre-checkout-offer wcf-tab-content widefat">
|
366 |
+
<?php
|
367 |
+
if ( ! _is_cartflows_pro() ) {
|
368 |
+
echo wcf()->meta->get_description_field(
|
369 |
+
array(
|
370 |
+
'name' => 'wcf-upgrade-to-pro',
|
371 |
+
/* translators: %s: link */
|
372 |
+
'content' => '<i>' . sprintf( esc_html__( 'Upgrade to %1$sCartFlows Pro%2$s for Checkout Offer feature', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>' ) . '</i>',
|
373 |
+
)
|
374 |
+
);
|
375 |
+
} elseif ( _is_cartflows_pro_ver_less_than( '1.2.0' ) ) {
|
376 |
+
|
377 |
+
$version = '1.2.0';
|
378 |
+
echo wcf()->meta->get_description_field(
|
379 |
+
array(
|
380 |
+
'name' => 'wcf-upgrade-to-pro',
|
381 |
+
/* translators: %s: link */
|
382 |
+
'content' => '<i>' . sprintf( esc_html__( 'Update to %1$sCartFlows Pro%2$s to %3$s or above for Checkout Offer feature', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>', $version ) . '</i>',
|
383 |
+
)
|
384 |
+
);
|
385 |
+
}
|
386 |
+
?>
|
387 |
+
|
388 |
+
<?php do_action( 'cartflows_pre_checkout_offer_tab_content', $options, $post_id ); ?>
|
389 |
+
</div>
|
390 |
+
<?php
|
391 |
+
}
|
392 |
+
|
393 |
+
|
394 |
+
/**
|
395 |
+
* Pre Checkout tab
|
396 |
+
*
|
397 |
+
* @param array $options options.
|
398 |
+
* @param int $post_id post ID.
|
399 |
+
*/
|
400 |
+
public function animate_title_settings( $options, $post_id ) {
|
401 |
+
|
402 |
+
echo wcf()->meta->get_hr_line_field( array() );
|
403 |
+
|
404 |
+
if ( ! _is_cartflows_pro() ) {
|
405 |
+
echo wcf()->meta->get_description_field(
|
406 |
+
array(
|
407 |
+
'name' => 'wcf-upgrade-to-pro',
|
408 |
+
/* translators: %s: link */
|
409 |
+
'content' => '<i>' . sprintf( __( 'Upgrade to %1$sCartFlows Pro%2$s for animate browser tab feature', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>' ) . '</i>',
|
410 |
+
)
|
411 |
+
);
|
412 |
+
} elseif ( _is_cartflows_pro_ver_less_than( '1.4.0' ) ) {
|
413 |
+
|
414 |
+
$version = '1.4.0';
|
415 |
+
echo wcf()->meta->get_description_field(
|
416 |
+
array(
|
417 |
+
'name' => 'wcf-upgrade-to-pro',
|
418 |
+
/* translators: %s: link */
|
419 |
+
'content' => '<i>' . sprintf( __( 'Update to %1$sCartFlows Pro%2$s to %3$s or above for animate browser tab feature', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>', $version ) . '</i>',
|
420 |
+
)
|
421 |
+
);
|
422 |
+
}
|
423 |
+
|
424 |
+
do_action( 'cartflows_animate_browser_tab_settings', $options, $post_id );
|
425 |
+
}
|
426 |
+
|
427 |
+
/**
|
428 |
+
* Product bump tab
|
429 |
+
*
|
430 |
+
* @param array $options options.
|
431 |
+
* @param int $post_id post ID.
|
432 |
+
*/
|
433 |
+
public function tab_product_bump( $options, $post_id ) {
|
434 |
+
?>
|
435 |
+
<div class="wcf-product-order-bump wcf-tab-content widefat">
|
436 |
+
<?php
|
437 |
+
if ( ! _is_cartflows_pro() ) {
|
438 |
+
echo wcf()->meta->get_description_field(
|
439 |
+
array(
|
440 |
+
'name' => 'wcf-upgrade-to-pro',
|
441 |
+
/* translators: %s: link */
|
442 |
+
'content' => '<i>' . sprintf( esc_html__( 'Upgrade to %1$sCartFlows Pro%2$s for Order Bump feature.', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>' ) . '</i>',
|
443 |
+
)
|
444 |
+
);
|
445 |
+
}
|
446 |
+
?>
|
447 |
+
|
448 |
+
<?php do_action( 'cartflows_order_bump_tab_content', $options, $post_id ); ?>
|
449 |
+
</div>
|
450 |
+
<?php
|
451 |
+
}
|
452 |
+
/**
|
453 |
+
* Tab custom fields
|
454 |
+
*
|
455 |
+
* @param array $options options.
|
456 |
+
* @param int $post_id post ID.
|
457 |
+
*/
|
458 |
+
public function tab_custom_fields( $options, $post_id ) {
|
459 |
+
?>
|
460 |
+
<div class="wcf-checkout-custom-fields wcf-tab-content widefat">
|
461 |
+
<?php
|
462 |
+
/* Custom Checkout Fields Section */
|
463 |
+
|
464 |
+
if ( ! _is_cartflows_pro() ) {
|
465 |
+
echo wcf()->meta->get_description_field(
|
466 |
+
array(
|
467 |
+
'name' => 'wcf-upgrade-to-pro',
|
468 |
+
/* translators: %s: link */
|
469 |
+
'content' => '<i>' . sprintf( esc_html__( 'Upgrade to %1$sCartFlows Pro%2$s for Custom Fields feature.', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>' ) . '</i>',
|
470 |
+
)
|
471 |
+
);
|
472 |
+
}
|
473 |
+
?>
|
474 |
+
<?php do_action( 'cartflows_custom_fields_tab_content', $options, $post_id ); ?>
|
475 |
+
</div>
|
476 |
+
<?php
|
477 |
+
}
|
478 |
+
/**
|
479 |
+
* Tab custom settings
|
480 |
+
*
|
481 |
+
* @param array $options options.
|
482 |
+
* @param int $post_id post ID.
|
483 |
+
*/
|
484 |
+
public function tab_custom_settings( $options, $post_id ) {
|
485 |
+
?>
|
486 |
+
<div class="wcf-checkout-custom-settings wcf-tab-content widefat">
|
487 |
+
<div class="wcf-custom-settings-fields">
|
488 |
+
<?php
|
489 |
+
|
490 |
+
echo wcf()->meta->get_text_field(
|
491 |
+
array(
|
492 |
+
'label' => __( 'Place Order Button Text', 'cartflows' ),
|
493 |
+
'name' => 'wcf-checkout-place-order-button-text',
|
494 |
+
'value' => $options['wcf-checkout-place-order-button-text'],
|
495 |
+
'attr' => array(
|
496 |
+
'placeholder' => __( 'Place order', 'cartflows' ),
|
497 |
+
),
|
498 |
+
'help' => __( 'It will change the Place Order Button text on checkout page.', 'cartflows' ),
|
499 |
+
)
|
500 |
+
);
|
501 |
+
|
502 |
+
echo wcf()->meta->get_hr_line_field( array() );
|
503 |
+
|
504 |
+
echo wcf()->meta->get_checkbox_field(
|
505 |
+
array(
|
506 |
+
'name' => 'wcf-remove-product-field',
|
507 |
+
'value' => $options['wcf-remove-product-field'],
|
508 |
+
'after' => esc_html__( 'Enable cart editing on checkout', 'cartflows' ),
|
509 |
+
)
|
510 |
+
);
|
511 |
+
|
512 |
+
echo wcf()->meta->get_description_field(
|
513 |
+
array(
|
514 |
+
'name' => '',
|
515 |
+
/* translators: %s: link */
|
516 |
+
'content' => '<i>' . sprintf( esc_html__( 'Users will able to remove products from the checkout page.', 'cartflows' ), '<a href="https://cartflows.com/" target="_blank">', '</a>' ) . '</i>',
|
517 |
+
)
|
518 |
+
);
|
519 |
+
|
520 |
+
$this->animate_title_settings( $options, $post_id );
|
521 |
+
?>
|
522 |
+
</div>
|
523 |
+
<?php do_action( 'cartflows_custom_settings_tab_content', $options, $post_id ); ?>
|
524 |
+
</div>
|
525 |
+
<?php
|
526 |
+
}
|
527 |
+
|
528 |
+
/**
|
529 |
+
* Tab style
|
530 |
+
*
|
531 |
+
* @param array $options options.
|
532 |
+
* @param int $post_id post ID.
|
533 |
+
*/
|
534 |
+
public function tab_style( $options, $post_id ) {
|
535 |
+
?>
|
536 |
+
|
537 |
+
<div class="wcf-checkout-style wcf-tab-content widefat">
|
538 |
+
<div class="wcf-cs-fields">
|
539 |
+
<div class="wcf-cs-checkbox-field">
|
540 |
+
<?php
|
541 |
+
|
542 |
+
$layout_pro_option = array();
|
543 |
+
|
544 |
+
if ( ! _is_cartflows_pro() ) {
|
545 |
+
$layout_pro_option = array(
|
546 |
+
'one-column' => __( 'One Column (Available in CartFlows Pro) ', 'cartflows' ),
|
547 |
+
'two-step' => __( 'Two Step (Available in CartFlows Pro) ', 'cartflows' ),
|
548 |
+
);
|
549 |
+
}
|
550 |
+
|
551 |
+
echo wcf()->meta->get_select_field(
|
552 |
+
array(
|
553 |
+
'label' => __( 'Checkout Skin', 'cartflows' ),
|
554 |
+
'name' => 'wcf-checkout-layout',
|
555 |
+
'value' => $options['wcf-checkout-layout'],
|
556 |
+
'options' => array(
|
557 |
+
'one-column' => esc_html__( 'One Column', 'cartflows' ),
|
558 |
+
'two-column' => esc_html__( 'Two Column', 'cartflows' ),
|
559 |
+
'two-step' => esc_html__( 'Two Step', 'cartflows' ),
|
560 |
+
),
|
561 |
+
'pro-options' => $layout_pro_option,
|
562 |
+
|
563 |
+
)
|
564 |
+
);
|
565 |
+
|
566 |
+
echo wcf()->meta->get_color_picker_field(
|
567 |
+
array(
|
568 |
+
'label' => __( 'Primary Color', 'cartflows' ),
|
569 |
+
'name' => 'wcf-primary-color',
|
570 |
+
'value' => $options['wcf-primary-color'],
|
571 |
+
)
|
572 |
+
);
|
573 |
+
|
574 |
+
echo wcf()->meta->get_font_family_field(
|
575 |
+
array(
|
576 |
+
'for' => 'wcf-base',
|
577 |
+
'label' => esc_html__( 'Font Family', 'cartflows' ),
|
578 |
+
'name' => 'wcf-base-font-family',
|
579 |
+
'value' => $options['wcf-base-font-family'],
|
580 |
+
)
|
581 |
+
);
|
582 |
+
|
583 |
+
echo wcf()->meta->get_checkbox_field(
|
584 |
+
array(
|
585 |
+
'label' => __( 'Advance Options', 'cartflows' ),
|
586 |
+
'name' => 'wcf-advance-options-fields',
|
587 |
+
'value' => $options['wcf-advance-options-fields'],
|
588 |
+
'after' => 'Enable',
|
589 |
+
)
|
590 |
+
);
|
591 |
+
?>
|
592 |
+
</div>
|
593 |
+
<div class="wcf-cs-fields-options">
|
594 |
+
<?php
|
595 |
+
echo wcf()->meta->get_section(
|
596 |
+
array(
|
597 |
+
'label' => __( 'Heading', 'cartflows' ),
|
598 |
+
)
|
599 |
+
);
|
600 |
+
|
601 |
+
echo wcf()->meta->get_color_picker_field(
|
602 |
+
array(
|
603 |
+
'label' => __( 'Heading Color', 'cartflows' ),
|
604 |
+
'name' => 'wcf-heading-color',
|
605 |
+
'value' => $options['wcf-heading-color'],
|
606 |
+
)
|
607 |
+
);
|
608 |
+
|
609 |
+
echo wcf()->meta->get_font_family_field(
|
610 |
+
array(
|
611 |
+
'for' => 'wcf-heading',
|
612 |
+
'label' => esc_html__( 'Font Family', 'cartflows' ),
|
613 |
+
'name' => 'wcf-heading-font-family',
|
614 |
+
'value' => $options['wcf-heading-font-family'],
|
615 |
+
)
|
616 |
+
);
|
617 |
+
|
618 |
+
echo wcf()->meta->get_font_weight_field(
|
619 |
+
array(
|
620 |
+
'for' => 'wcf-heading',
|
621 |
+
'label' => esc_html__( 'Font Weight', 'cartflows' ),
|
622 |
+
'name' => 'wcf-heading-font-weight',
|
623 |
+
'value' => $options['wcf-heading-font-weight'],
|
624 |
+
)
|
625 |
+
);
|
626 |
+
|
627 |
+
echo wcf()->meta->get_section(
|
628 |
+
array(
|
629 |
+
'label' => __( 'Input Fields', 'cartflows' ),
|
630 |
+
)
|
631 |
+
);
|
632 |
+
|
633 |
+
$fields_skin_pro_option = array();
|
634 |
+
|
635 |
+
if ( ! _is_cartflows_pro() ) {
|
636 |
+
$fields_skin_pro_option = array(
|
637 |
+
'style-one' => __( 'Floating Labels (Available in CartFlows Pro)', 'cartflows' ),
|
638 |
+
);
|
639 |
+
}
|
640 |
+
|
641 |
+
echo wcf()->meta->get_select_field(
|
642 |
+
array(
|
643 |
+
'label' => __( 'Style', 'cartflows' ),
|
644 |
+
'name' => 'wcf-fields-skins',
|
645 |
+
'value' => $options['wcf-fields-skins'],
|
646 |
+
'options' => array(
|
647 |
+
'default' => esc_html__( 'Default', 'cartflows' ),
|
648 |
+
'style-one' => esc_html__( 'Floating Labels', 'cartflows' ),
|
649 |
+
),
|
650 |
+
'pro-options' => $fields_skin_pro_option,
|
651 |
+
|
652 |
+
)
|
653 |
+
);
|
654 |
+
|
655 |
+
echo wcf()->meta->get_font_family_field(
|
656 |
+
array(
|
657 |
+
'for' => 'wcf-input',
|
658 |
+
'label' => esc_html__( 'Font Family', 'cartflows' ),
|
659 |
+
'name' => 'wcf-input-font-family',
|
660 |
+
'value' => $options['wcf-input-font-family'],
|
661 |
+
)
|
662 |
+
);
|
663 |
+
|
664 |
+
echo wcf()->meta->get_font_weight_field(
|
665 |
+
array(
|
666 |
+
'for' => 'wcf-input',
|
667 |
+
'label' => esc_html__( 'Font Weight', 'cartflows' ),
|
668 |
+
'name' => 'wcf-input-font-weight',
|
669 |
+
'value' => $options['wcf-input-font-weight'],
|
670 |
+
)
|
671 |
+
);
|
672 |
+
|
673 |
+
echo wcf()->meta->get_select_field(
|
674 |
+
array(
|
675 |
+
'label' => __( 'Size', 'cartflows' ),
|
676 |
+
'name' => 'wcf-input-field-size',
|
677 |
+
'value' => $options['wcf-input-field-size'],
|
678 |
+
'options' => array(
|
679 |
+
'33px' => esc_html__( 'Extra Small', 'cartflows' ),
|
680 |
+
'38px' => esc_html__( 'Small', 'cartflows' ),
|
681 |
+
'44px' => esc_html__( 'Medium', 'cartflows' ),
|
682 |
+
'58px' => esc_html__( 'Large', 'cartflows' ),
|
683 |
+
'68px' => esc_html__( 'Extra Large', 'cartflows' ),
|
684 |
+
'custom' => esc_html__( 'Custom', 'cartflows' ),
|
685 |
+
),
|
686 |
+
)
|
687 |
+
);
|
688 |
+
|
689 |
+
echo wcf()->meta->get_number_field(
|
690 |
+
array(
|
691 |
+
'label' => __( 'Top Bottom Spacing', 'cartflows' ),
|
692 |
+
'name' => 'wcf-field-tb-padding',
|
693 |
+
'value' => $options['wcf-field-tb-padding'],
|
694 |
+
)
|
695 |
+
);
|
696 |
+
|
697 |
+
echo wcf()->meta->get_number_field(
|
698 |
+
array(
|
699 |
+
'label' => __( 'Left Right Spacing', 'cartflows' ),
|
700 |
+
'name' => 'wcf-field-lr-padding',
|
701 |
+
'value' => $options['wcf-field-lr-padding'],
|
702 |
+
)
|
703 |
+
);
|
704 |
+
|
705 |
+
echo wcf()->meta->get_color_picker_field(
|
706 |
+
array(
|
707 |
+
'label' => __( 'Text / Placeholder Color', 'cartflows' ),
|
708 |
+
'name' => 'wcf-field-color',
|
709 |
+
'value' => $options['wcf-field-color'],
|
710 |
+
)
|
711 |
+
);
|
712 |
+
|
713 |
+
echo wcf()->meta->get_color_picker_field(
|
714 |
+
array(
|
715 |
+
'label' => __( 'Background Color', 'cartflows' ),
|
716 |
+
'name' => 'wcf-field-bg-color',
|
717 |
+
'value' => $options['wcf-field-bg-color'],
|
718 |
+
)
|
719 |
+
);
|
720 |
+
|
721 |
+
echo wcf()->meta->get_color_picker_field(
|
722 |
+
array(
|
723 |
+
'label' => __( 'Border Color', 'cartflows' ),
|
724 |
+
'name' => 'wcf-field-border-color',
|
725 |
+
'value' => $options['wcf-field-border-color'],
|
726 |
+
)
|
727 |
+
);
|
728 |
+
echo wcf()->meta->get_color_picker_field(
|
729 |
+
array(
|
730 |
+
'label' => __( 'Label Color', 'cartflows' ),
|
731 |
+
'name' => 'wcf-field-label-color',
|
732 |
+
'value' => $options['wcf-field-label-color'],
|
733 |
+
)
|
734 |
+
);
|
735 |
+
|
736 |
+
?>
|
737 |
+
</div>
|
738 |
+
<div class="wcf-cs-button-options">
|
739 |
+
<?php
|
740 |
+
|
741 |
+
echo wcf()->meta->get_section(
|
742 |
+
array(
|
743 |
+
'label' => __( 'Buttons', 'cartflows' ),
|
744 |
+
)
|
745 |
+
);
|
746 |
+
|
747 |
+
echo wcf()->meta->get_font_family_field(
|
748 |
+
array(
|
749 |
+
'for' => 'wcf-button',
|
750 |
+
'label' => esc_html__( 'Font Family', 'cartflows' ),
|
751 |
+
'name' => 'wcf-button-font-family',
|
752 |
+
'value' => $options['wcf-button-font-family'],
|
753 |
+
)
|
754 |
+
);
|
755 |
+
|
756 |
+
echo wcf()->meta->get_font_weight_field(
|
757 |
+
array(
|
758 |
+
'for' => 'wcf-button',
|
759 |
+
'label' => esc_html__( 'Font Weight', 'cartflows' ),
|
760 |
+
'name' => 'wcf-button-font-weight',
|
761 |
+
'value' => $options['wcf-button-font-weight'],
|
762 |
+
)
|
763 |
+
);
|
764 |
+
|
765 |
+
echo wcf()->meta->get_select_field(
|
766 |
+
array(
|
767 |
+
'label' => __( 'Size', 'cartflows' ),
|
768 |
+
'name' => 'wcf-input-button-size',
|
769 |
+
'value' => $options['wcf-input-button-size'],
|
770 |
+
'options' => array(
|
771 |
+
'33px' => esc_html__( 'Extra Small', 'cartflows' ),
|
772 |
+
'38px' => esc_html__( 'Small', 'cartflows' ),
|
773 |
+
'44px' => esc_html__( 'Medium', 'cartflows' ),
|
774 |
+
'58px' => esc_html__( 'Large', 'cartflows' ),
|
775 |
+
'68px' => esc_html__( 'Extra Large', 'cartflows' ),
|
776 |
+
'custom' => esc_html__( 'Custom', 'cartflows' ),
|
777 |
+
),
|
778 |
+
)
|
779 |
+
);
|
780 |
+
|
781 |
+
echo wcf()->meta->get_number_field(
|
782 |
+
array(
|
783 |
+
'label' => __( 'Top Bottom Spacing', 'cartflows' ),
|
784 |
+
'name' => 'wcf-submit-tb-padding',
|
785 |
+
'value' => $options['wcf-submit-tb-padding'],
|
786 |
+
)
|
787 |
+
);
|
788 |
+
|
789 |
+
echo wcf()->meta->get_number_field(
|
790 |
+
array(
|
791 |
+
'label' => __( 'Left Right Spacing', 'cartflows' ),
|
792 |
+
'name' => 'wcf-submit-lr-padding',
|
793 |
+
'value' => $options['wcf-submit-lr-padding'],
|
794 |
+
)
|
795 |
+
);
|
796 |
+
|
797 |
+
echo wcf()->meta->get_color_picker_field(
|
798 |
+
array(
|
799 |
+
'label' => __( 'Text Color', 'cartflows' ),
|
800 |
+
'name' => 'wcf-submit-color',
|
801 |
+
'value' => $options['wcf-submit-color'],
|
802 |
+
)
|
803 |
+
);
|
804 |
+
|
805 |
+
echo wcf()->meta->get_color_picker_field(
|
806 |
+
array(
|
807 |
+
'label' => __( 'Text Hover Color', 'cartflows' ),
|
808 |
+
'name' => 'wcf-submit-hover-color',
|
809 |
+
'value' => $options['wcf-submit-hover-color'],
|
810 |
+
)
|
811 |
+
);
|
812 |
+
|
813 |
+
echo wcf()->meta->get_color_picker_field(
|
814 |
+
array(
|
815 |
+
'label' => __( 'Background Color', 'cartflows' ),
|
816 |
+
'name' => 'wcf-submit-bg-color',
|
817 |
+
'value' => $options['wcf-submit-bg-color'],
|
818 |
+
)
|
819 |
+
);
|
820 |
+
|
821 |
+
echo wcf()->meta->get_color_picker_field(
|
822 |
+
array(
|
823 |
+
'label' => __( 'Background Hover Color', 'cartflows' ),
|
824 |
+
'name' => 'wcf-submit-bg-hover-color',
|
825 |
+
'value' => $options['wcf-submit-bg-hover-color'],
|
826 |
+
)
|
827 |
+
);
|
828 |
+
|
829 |
+
echo wcf()->meta->get_color_picker_field(
|
830 |
+
array(
|
831 |
+
'label' => __( 'Border Color', 'cartflows' ),
|
832 |
+
'name' => 'wcf-submit-border-color',
|
833 |
+
'value' => $options['wcf-submit-border-color'],
|
834 |
+
)
|
835 |
+
);
|
836 |
+
|
837 |
+
echo wcf()->meta->get_color_picker_field(
|
838 |
+
array(
|
839 |
+
'label' => __( 'Border Hover Color', 'cartflows' ),
|
840 |
+
'name' => 'wcf-submit-border-hover-color',
|
841 |
+
'value' => $options['wcf-submit-border-hover-color'],
|
842 |
+
)
|
843 |
+
);
|
844 |
+
|
845 |
+
?>
|
846 |
+
</div>
|
847 |
+
<div class="wcf-cs-section-options">
|
848 |
+
<?php
|
849 |
+
|
850 |
+
echo wcf()->meta->get_section(
|
851 |
+
array(
|
852 |
+
'label' => __( 'Sections', 'cartflows' ),
|
853 |
+
)
|
854 |
+
);
|
855 |
+
|
856 |
+
echo wcf()->meta->get_color_picker_field(
|
857 |
+
array(
|
858 |
+
'label' => __( 'Highlight Area Background Color', 'cartflows' ),
|
859 |
+
'name' => 'wcf-hl-bg-color',
|
860 |
+
'value' => $options['wcf-hl-bg-color'],
|
861 |
+
)
|
862 |
+
);
|
863 |
+
|
864 |
+
echo wcf()->meta->get_hidden_field(
|
865 |
+
array(
|
866 |
+
'name' => 'wcf-field-google-font-url',
|
867 |
+
'value' => $options['wcf-field-google-font-url'],
|
868 |
+
)
|
869 |
+
);
|
870 |
+
?>
|
871 |
+
</div>
|
872 |
+
<?php do_action( 'cartflows_checkout_style_tab_content', $options, $post_id ); ?>
|
873 |
+
</div>
|
874 |
+
</div>
|
875 |
+
<?php
|
876 |
+
}
|
877 |
+
|
878 |
+
|
879 |
+
/**
|
880 |
+
* Tab Header (Used for add logo into header)
|
881 |
+
*
|
882 |
+
* @param array $options options.
|
883 |
+
* @param int $post_id post ID.
|
884 |
+
*/
|
885 |
+
public function tab_header_content( $options, $post_id ) {
|
886 |
+
?>
|
887 |
+
|
888 |
+
<div class="wcf-checkout-header wcf-tab-content widefat">
|
889 |
+
<?php
|
890 |
+
|
891 |
+
$layout_pro_option = array();
|
892 |
+
|
893 |
+
echo wcf()->meta->get_image_field(
|
894 |
+
array(
|
895 |
+
'name' => 'wcf-header-logo-image',
|
896 |
+
'value' => $options['wcf-header-logo-image'],
|
897 |
+
'label' => esc_html__( 'Header Logo', 'cartflows' ),
|
898 |
+
)
|
899 |
+
);
|
900 |
+
|
901 |
+
echo wcf()->meta->get_number_field(
|
902 |
+
array(
|
903 |
+
'name' => 'wcf-header-logo-width',
|
904 |
+
'value' => $options['wcf-header-logo-width'],
|
905 |
+
'label' => esc_html__( 'Logo Width (In px)', 'cartflows' ),
|
906 |
+
)
|
907 |
+
);
|
908 |
+
?>
|
909 |
+
<?php do_action( 'cartflows_checkout_header_tab_content', $options, $post_id ); ?>
|
910 |
+
</div>
|
911 |
+
<?php
|
912 |
+
}
|
913 |
+
/**
|
914 |
+
* Get metabox options
|
915 |
+
*
|
916 |
+
* @param int $post_id post ID.
|
917 |
+
*/
|
918 |
+
public static function get_meta_option( $post_id ) {
|
919 |
+
|
920 |
+
if ( null === self::$meta_option ) {
|
921 |
+
|
922 |
+
/**
|
923 |
+
* Set metabox options
|
924 |
+
*
|
925 |
+
* @see http://php.net/manual/en/filter.filters.sanitize.php
|
926 |
+
*/
|
927 |
+
self::$meta_option = wcf()->options->get_checkout_fields( $post_id );
|
928 |
+
}
|
929 |
+
|
930 |
+
return self::$meta_option;
|
931 |
+
}
|
932 |
+
|
933 |
+
/**
|
934 |
+
* Metabox Save
|
935 |
+
*
|
936 |
+
* @param number $post_id Post ID.
|
937 |
+
* @return void
|
938 |
+
*/
|
939 |
+
public function save_meta_box( $post_id ) {
|
940 |
+
|
941 |
+
// Checks save status.
|
942 |
+
$is_autosave = wp_is_post_autosave( $post_id );
|
943 |
+
$is_revision = wp_is_post_revision( $post_id );
|
944 |
+
|
945 |
+
$is_valid_nonce = ( isset( $_POST['nonce-checkout-step-meta'] ) && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['nonce-checkout-step-meta'] ) ), 'save-nonce-checkout-step-meta' ) ) ? true : false;
|
946 |
+
|
947 |
+
// Exits script depending on save status.
|
948 |
+
if ( $is_autosave || $is_revision || ! $is_valid_nonce ) {
|
949 |
+
return;
|
950 |
+
}
|
951 |
+
|
952 |
+
wcf()->options->save_checkout_fields( $post_id );
|
953 |
+
}
|
954 |
+
}
|
955 |
+
|
956 |
+
/**
|
957 |
+
* Kicking this off by calling 'get_instance()' method
|
958 |
+
*/
|
959 |
+
Cartflows_Checkout_Meta::get_instance();
|
modules/flow/classes/class-cartflows-step-post-type.php
CHANGED
@@ -1,498 +1,496 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Step post type.
|
4 |
-
*
|
5 |
-
* @package CartFlows
|
6 |
-
*/
|
7 |
-
|
8 |
-
/**
|
9 |
-
* Initialization
|
10 |
-
*
|
11 |
-
* @since 1.0.0
|
12 |
-
*/
|
13 |
-
class Cartflows_Step_Post_Type {
|
14 |
-
|
15 |
-
|
16 |
-
/**
|
17 |
-
* Member Variable
|
18 |
-
*
|
19 |
-
* @var instance
|
20 |
-
*/
|
21 |
-
private static $instance;
|
22 |
-
|
23 |
-
/**
|
24 |
-
* Member Variable
|
25 |
-
*
|
26 |
-
* @var body_classes
|
27 |
-
*/
|
28 |
-
private $body_classes = array();
|
29 |
-
|
30 |
-
/**
|
31 |
-
* Initiator
|
32 |
-
*/
|
33 |
-
public static function get_instance() {
|
34 |
-
if ( ! isset( self::$instance ) ) {
|
35 |
-
self::$instance = new self();
|
36 |
-
}
|
37 |
-
return self::$instance;
|
38 |
-
}
|
39 |
-
|
40 |
-
/**
|
41 |
-
* Constructor
|
42 |
-
*/
|
43 |
-
public function __construct() {
|
44 |
-
|
45 |
-
add_action( 'init', array( $this, 'step_post_type' ) );
|
46 |
-
add_action( 'init', array( $this, 'add_wp_templates_support' ) );
|
47 |
-
add_filter( 'post_updated_messages', array( $this, 'post_update_messages' ) );
|
48 |
-
|
49 |
-
add_filter( 'wp_unique_post_slug', array( $this, 'prevent_slug_duplicates' ), 10, 6 );
|
50 |
-
|
51 |
-
add_filter( 'template_include', array( $this, 'load_page_template' ), 90 );
|
52 |
-
add_filter( 'template_redirect', array( $this, 'query_fix' ), 3 );
|
53 |
-
|
54 |
-
add_action( 'admin_init', array( $this, 'disallowed_admin_all_steps_view' ) );
|
55 |
-
}
|
56 |
-
|
57 |
-
/**
|
58 |
-
* Trys to load page.php for a header, footer or part theme layout.
|
59 |
-
*
|
60 |
-
* @since 1.0.0
|
61 |
-
* @param string $template The current template to be loaded.
|
62 |
-
* @return string
|
63 |
-
*/
|
64 |
-
public function load_page_template( $template ) {
|
65 |
-
|
66 |
-
global $post;
|
67 |
-
|
68 |
-
if ( 'string' == gettype( $template ) && is_object( $post ) && CARTFLOWS_STEP_POST_TYPE === $post->post_type ) {
|
69 |
-
|
70 |
-
/**
|
71 |
-
* Remove Next/Prev Navigation
|
72 |
-
* add_filter('next_post_link', '__return_empty_string');
|
73 |
-
* add_filter('previous_post_link', '__return_empty_string');
|
74 |
-
*
|
75 |
-
* $page = locate_template( array( 'page.php' ) );
|
76 |
-
*
|
77 |
-
* if ( ! empty( $page ) ) {
|
78 |
-
* return $page;
|
79 |
-
* }
|
80 |
-
*/
|
81 |
-
|
82 |
-
/* Remove Next / Previous Rel Link */
|
83 |
-
remove_action( 'wp_head', 'adjacent_posts_rel_link_wp_head', 10, 0 );
|
84 |
-
add_filter( 'next_post_rel_link', '__return_empty_string' );
|
85 |
-
add_filter( 'previous_post_rel_link', '__return_empty_string' );
|
86 |
-
|
87 |
-
$page_template = get_post_meta( _get_wcf_step_id(), '_wp_page_template', true );
|
88 |
-
|
89 |
-
$page_template = apply_filters( 'cartflows_page_template', $page_template );
|
90 |
-
|
91 |
-
$file = '';
|
92 |
-
|
93 |
-
switch ( $page_template ) {
|
94 |
-
|
95 |
-
case 'cartflows-default':
|
96 |
-
$file = CARTFLOWS_FLOW_DIR . 'templates/template-default.php';
|
97 |
-
$this->body_classes[] = $page_template;
|
98 |
-
break;
|
99 |
-
case 'cartflows-canvas':
|
100 |
-
$file = CARTFLOWS_FLOW_DIR . 'templates/template-canvas.php';
|
101 |
-
$this->body_classes[] = $page_template;
|
102 |
-
break;
|
103 |
-
default:
|
104 |
-
/**
|
105 |
-
* Remove Next/Prev Navigation
|
106 |
-
*/
|
107 |
-
add_filter( 'next_post_link', '__return_empty_string' );
|
108 |
-
add_filter( 'previous_post_link', '__return_empty_string' );
|
109 |
-
|
110 |
-
$page = locate_template( array( 'page.php' ) );
|
111 |
-
|
112 |
-
if ( ! empty( $page ) ) {
|
113 |
-
$file = $page;
|
114 |
-
}
|
115 |
-
|
116 |
-
break;
|
117 |
-
|
118 |
-
/**
|
119 |
-
* Default:
|
120 |
-
* $file = CARTFLOWS_FLOW_DIR . 'templates/template-default.php';
|
121 |
-
* $this->body_classes[] = 'cartflows-default';
|
122 |
-
* break;
|
123 |
-
*/
|
124 |
-
}
|
125 |
-
|
126 |
-
// Just to be safe, we check if the file exist first.
|
127 |
-
if ( file_exists( $file ) ) {
|
128 |
-
|
129 |
-
/* Add Body Class */
|
130 |
-
add_filter( 'body_class', array( $this, 'body_class' ) );
|
131 |
-
|
132 |
-
return $file;
|
133 |
-
} else {
|
134 |
-
echo $file;
|
135 |
-
}
|
136 |
-
}
|
137 |
-
|
138 |
-
return $template;
|
139 |
-
}
|
140 |
-
|
141 |
-
/**
|
142 |
-
* Body classes.
|
143 |
-
*
|
144 |
-
* @since 1.0.0
|
145 |
-
* @param array $classes Body classes.
|
146 |
-
* @return array
|
147 |
-
*/
|
148 |
-
public function body_class( $classes = array() ) {
|
149 |
-
|
150 |
-
$classes = array_merge( $classes, $this->body_classes );
|
151 |
-
|
152 |
-
return $classes;
|
153 |
-
}
|
154 |
-
|
155 |
-
/**
|
156 |
-
* Create custom post type
|
157 |
-
*/
|
158 |
-
public function step_post_type() {
|
159 |
-
|
160 |
-
$labels = array(
|
161 |
-
'name' => esc_html_x( 'Steps', 'flow step general name', 'cartflows' ),
|
162 |
-
'singular_name' => esc_html_x( 'Step', 'flow step singular name', 'cartflows' ),
|
163 |
-
'search_items' => esc_html__( 'Search Steps', 'cartflows' ),
|
164 |
-
'all_items' => esc_html__( 'All Steps', 'cartflows' ),
|
165 |
-
'edit_item' => esc_html__( 'Edit Step', 'cartflows' ),
|
166 |
-
'view_item' => esc_html__( 'View Step', 'cartflows' ),
|
167 |
-
'add_new' => esc_html__( 'Add New', 'cartflows' ),
|
168 |
-
'update_item' => esc_html__( 'Update Step', 'cartflows' ),
|
169 |
-
'add_new_item' => esc_html__( 'Add New', 'cartflows' ),
|
170 |
-
'new_item_name' => esc_html__( 'New Step Name', 'cartflows' ),
|
171 |
-
);
|
172 |
-
|
173 |
-
$permalink_settings = Cartflows_Helper::get_permalink_settings();
|
174 |
-
|
175 |
-
$args = array(
|
176 |
-
'labels' => $labels,
|
177 |
-
'public' => true,
|
178 |
-
'query_var' => true,
|
179 |
-
'can_export' => true,
|
180 |
-
'exclude_from_search' => true,
|
181 |
-
'show_ui' => true,
|
182 |
-
'show_in_menu' => false,
|
183 |
-
'show_in_admin_bar' => true,
|
184 |
-
'show_in_rest' => true,
|
185 |
-
'supports' => array( 'title', 'editor', 'elementor', 'revisions' ),
|
186 |
-
'capability_type' => 'post',
|
187 |
-
'capabilities' => array(
|
188 |
-
'create_posts' => 'do_not_allow', // Prior to Wordpress 4.5, this was false.
|
189 |
-
),
|
190 |
-
'map_meta_cap' => true,
|
191 |
-
);
|
192 |
-
|
193 |
-
if ( isset( $permalink_settings['permalink_structure'] ) && ! empty( $permalink_settings['permalink_structure'] ) ) {
|
194 |
-
$args['rewrite'] = array(
|
195 |
-
'slug' => $permalink_settings['permalink_structure'],
|
196 |
-
'with_front' => false,
|
197 |
-
);
|
198 |
-
|
199 |
-
} elseif ( isset( $permalink_settings['permalink'] ) && ! empty( $permalink_settings['permalink'] ) ) {
|
200 |
-
|
201 |
-
$args['rewrite'] = array(
|
202 |
-
'slug' => $permalink_settings['permalink'],
|
203 |
-
'with_front' => false,
|
204 |
-
);
|
205 |
-
}
|
206 |
-
|
207 |
-
register_post_type( CARTFLOWS_STEP_POST_TYPE, $args );
|
208 |
-
|
209 |
-
// Step Type.
|
210 |
-
$args = array(
|
211 |
-
'label' => __( 'Step Type', 'cartflows' ),
|
212 |
-
'public' => false,
|
213 |
-
'rewrite' => false,
|
214 |
-
'hierarchical' => false,
|
215 |
-
);
|
216 |
-
|
217 |
-
register_taxonomy( CARTFLOWS_TAXONOMY_STEP_TYPE, CARTFLOWS_STEP_POST_TYPE, $args );
|
218 |
-
|
219 |
-
// Step Flow.
|
220 |
-
$args = array(
|
221 |
-
'label' => __( 'Step Flow', 'cartflows' ),
|
222 |
-
'public' => false,
|
223 |
-
'rewrite' => false,
|
224 |
-
'hierarchical' => false,
|
225 |
-
);
|
226 |
-
|
227 |
-
register_taxonomy( CARTFLOWS_TAXONOMY_STEP_FLOW, CARTFLOWS_STEP_POST_TYPE, $args );
|
228 |
-
|
229 |
-
if ( is_admin() ) {
|
230 |
-
/**
|
231 |
-
* Register 'Elementor' & 'Beaver Builder' site types.
|
232 |
-
*
|
233 |
-
* @see self::add_terms();
|
234 |
-
*/
|
235 |
-
$taxonomy = CARTFLOWS_TAXONOMY_STEP_TYPE;
|
236 |
-
|
237 |
-
$terms = array(
|
238 |
-
array(
|
239 |
-
'name' => __( 'Landing', 'cartflows' ),
|
240 |
-
'slug' => 'landing',
|
241 |
-
'args' => array(
|
242 |
-
'slug' => 'landing',
|
243 |
-
),
|
244 |
-
),
|
245 |
-
array(
|
246 |
-
'name' => __( 'Optin (Woo)', 'cartflows' ),
|
247 |
-
'slug' => 'optin',
|
248 |
-
'args' => array(
|
249 |
-
'slug' => 'optin',
|
250 |
-
),
|
251 |
-
),
|
252 |
-
array(
|
253 |
-
'name' => __( 'Checkout (Woo)', 'cartflows' ),
|
254 |
-
'slug' => 'checkout',
|
255 |
-
'args' => array(
|
256 |
-
'slug' => 'checkout',
|
257 |
-
),
|
258 |
-
),
|
259 |
-
array(
|
260 |
-
'name' => __( 'Thank You (Woo)', 'cartflows' ),
|
261 |
-
'slug' => 'thankyou',
|
262 |
-
'args' => array(
|
263 |
-
'slug' => 'thankyou',
|
264 |
-
),
|
265 |
-
),
|
266 |
-
array(
|
267 |
-
'name' => __( 'Upsell (Woo)', 'cartflows' ),
|
268 |
-
'slug' => 'upsell',
|
269 |
-
'args' => array(
|
270 |
-
'slug' => 'upsell',
|
271 |
-
),
|
272 |
-
),
|
273 |
-
array(
|
274 |
-
'name' => __( 'Downsell (Woo)', 'cartflows' ),
|
275 |
-
'slug' => 'downsell',
|
276 |
-
'args' => array(
|
277 |
-
'slug' => 'downsell',
|
278 |
-
),
|
279 |
-
),
|
280 |
-
);
|
281 |
-
|
282 |
-
$this->add_terms( $taxonomy, $terms );
|
283 |
-
|
284 |
-
}
|
285 |
-
}
|
286 |
-
|
287 |
-
/**
|
288 |
-
* Add WordPress templates.
|
289 |
-
*
|
290 |
-
* Adds Cartflows templates to steps
|
291 |
-
*
|
292 |
-
* @since 1.0.0
|
293 |
-
* @access public
|
294 |
-
*/
|
295 |
-
public function add_wp_templates_support() {
|
296 |
-
add_filter( 'theme_' . CARTFLOWS_STEP_POST_TYPE . '_templates', array( $this, 'add_page_templates' ), 99, 4 );
|
297 |
-
}
|
298 |
-
|
299 |
-
/**
|
300 |
-
* Add page templates.
|
301 |
-
*
|
302 |
-
* @since 1.0.0
|
303 |
-
* @access public
|
304 |
-
*
|
305 |
-
* @param array $page_templates Array of page templates.
|
306 |
-
*
|
307 |
-
* @param object $wp_theme wp theme.
|
308 |
-
* @param object $post post.
|
309 |
-
*
|
310 |
-
* @return array Page templates.
|
311 |
-
*/
|
312 |
-
public function add_page_templates( $page_templates, $wp_theme, $post ) {
|
313 |
-
|
314 |
-
$page_templates = array(
|
315 |
-
'cartflows-default' => _x( 'CartFlows — Boxed', 'cartflows' ),
|
316 |
-
'cartflows-canvas' => _x( 'Template for Page Builders', 'cartflows' ),
|
317 |
-
);
|
318 |
-
|
319 |
-
return $page_templates;
|
320 |
-
}
|
321 |
-
|
322 |
-
|
323 |
-
|
324 |
-
|
325 |
-
*
|
326 |
-
*
|
327 |
-
|
328 |
-
|
329 |
-
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
338 |
-
|
339 |
-
|
340 |
-
*
|
341 |
-
*
|
342 |
-
* @param string $
|
343 |
-
* @param
|
344 |
-
* @param
|
345 |
-
* @param string $
|
346 |
-
* @
|
347 |
-
|
348 |
-
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
|
354 |
-
|
355 |
-
|
356 |
-
)
|
357 |
-
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
372 |
-
|
373 |
-
|
374 |
-
|
375 |
-
|
376 |
-
|
377 |
-
|
378 |
-
|
379 |
-
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
*
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
$custom_post_type
|
391 |
-
|
392 |
-
|
393 |
-
|
394 |
-
$
|
395 |
-
|
396 |
-
|
397 |
-
|
398 |
-
/* translators: %s: singular custom post type name */
|
399 |
-
|
400 |
-
/* translators: %s: singular custom post type name */
|
401 |
-
|
402 |
-
/* translators: %s: singular custom post type name */
|
403 |
-
|
404 |
-
/* translators: %s: singular custom post type name */
|
405 |
-
|
406 |
-
/* translators: %
|
407 |
-
|
408 |
-
/* translators: %s: singular custom post type name */
|
409 |
-
|
410 |
-
/* translators: %s: singular custom post type name */
|
411 |
-
|
412 |
-
/* translators: %s: singular custom post type name */
|
413 |
-
|
414 |
-
/* translators: %s: singular custom post type name */
|
415 |
-
|
416 |
-
|
417 |
-
|
418 |
-
|
419 |
-
|
420 |
-
|
421 |
-
|
422 |
-
|
423 |
-
|
424 |
-
|
425 |
-
*
|
426 |
-
*
|
427 |
-
*
|
428 |
-
*
|
429 |
-
*
|
430 |
-
*
|
431 |
-
*
|
432 |
-
*
|
433 |
-
*
|
434 |
-
*
|
435 |
-
*
|
436 |
-
*
|
437 |
-
*
|
438 |
-
*
|
439 |
-
*
|
440 |
-
*
|
441 |
-
*
|
442 |
-
*
|
443 |
-
* @
|
444 |
-
* @
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
|
455 |
-
|
456 |
-
|
457 |
-
*
|
458 |
-
|
459 |
-
|
460 |
-
|
461 |
-
|
462 |
-
|
463 |
-
|
464 |
-
|
465 |
-
$term['
|
466 |
-
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
|
473 |
-
|
474 |
-
*
|
475 |
-
|
476 |
-
|
477 |
-
|
478 |
-
|
479 |
-
|
480 |
-
|
481 |
-
|
482 |
-
|
483 |
-
|
484 |
-
|
485 |
-
|
486 |
-
|
487 |
-
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
|
495 |
-
|
496 |
-
|
497 |
-
*/
|
498 |
-
Cartflows_Step_Post_Type::get_instance();
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Step post type.
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
/**
|
9 |
+
* Initialization
|
10 |
+
*
|
11 |
+
* @since 1.0.0
|
12 |
+
*/
|
13 |
+
class Cartflows_Step_Post_Type {
|
14 |
+
|
15 |
+
|
16 |
+
/**
|
17 |
+
* Member Variable
|
18 |
+
*
|
19 |
+
* @var instance
|
20 |
+
*/
|
21 |
+
private static $instance;
|
22 |
+
|
23 |
+
/**
|
24 |
+
* Member Variable
|
25 |
+
*
|
26 |
+
* @var body_classes
|
27 |
+
*/
|
28 |
+
private $body_classes = array();
|
29 |
+
|
30 |
+
/**
|
31 |
+
* Initiator
|
32 |
+
*/
|
33 |
+
public static function get_instance() {
|
34 |
+
if ( ! isset( self::$instance ) ) {
|
35 |
+
self::$instance = new self();
|
36 |
+
}
|
37 |
+
return self::$instance;
|
38 |
+
}
|
39 |
+
|
40 |
+
/**
|
41 |
+
* Constructor
|
42 |
+
*/
|
43 |
+
public function __construct() {
|
44 |
+
|
45 |
+
add_action( 'init', array( $this, 'step_post_type' ) );
|
46 |
+
add_action( 'init', array( $this, 'add_wp_templates_support' ) );
|
47 |
+
add_filter( 'post_updated_messages', array( $this, 'post_update_messages' ) );
|
48 |
+
|
49 |
+
add_filter( 'wp_unique_post_slug', array( $this, 'prevent_slug_duplicates' ), 10, 6 );
|
50 |
+
|
51 |
+
add_filter( 'template_include', array( $this, 'load_page_template' ), 90 );
|
52 |
+
add_filter( 'template_redirect', array( $this, 'query_fix' ), 3 );
|
53 |
+
|
54 |
+
add_action( 'admin_init', array( $this, 'disallowed_admin_all_steps_view' ) );
|
55 |
+
}
|
56 |
+
|
57 |
+
/**
|
58 |
+
* Trys to load page.php for a header, footer or part theme layout.
|
59 |
+
*
|
60 |
+
* @since 1.0.0
|
61 |
+
* @param string $template The current template to be loaded.
|
62 |
+
* @return string
|
63 |
+
*/
|
64 |
+
public function load_page_template( $template ) {
|
65 |
+
|
66 |
+
global $post;
|
67 |
+
|
68 |
+
if ( 'string' == gettype( $template ) && is_object( $post ) && CARTFLOWS_STEP_POST_TYPE === $post->post_type ) {
|
69 |
+
|
70 |
+
/**
|
71 |
+
* Remove Next/Prev Navigation
|
72 |
+
* add_filter('next_post_link', '__return_empty_string');
|
73 |
+
* add_filter('previous_post_link', '__return_empty_string');
|
74 |
+
*
|
75 |
+
* $page = locate_template( array( 'page.php' ) );
|
76 |
+
*
|
77 |
+
* if ( ! empty( $page ) ) {
|
78 |
+
* return $page;
|
79 |
+
* }
|
80 |
+
*/
|
81 |
+
|
82 |
+
/* Remove Next / Previous Rel Link */
|
83 |
+
remove_action( 'wp_head', 'adjacent_posts_rel_link_wp_head', 10, 0 );
|
84 |
+
add_filter( 'next_post_rel_link', '__return_empty_string' );
|
85 |
+
add_filter( 'previous_post_rel_link', '__return_empty_string' );
|
86 |
+
|
87 |
+
$page_template = get_post_meta( _get_wcf_step_id(), '_wp_page_template', true );
|
88 |
+
|
89 |
+
$page_template = apply_filters( 'cartflows_page_template', $page_template );
|
90 |
+
|
91 |
+
$file = '';
|
92 |
+
|
93 |
+
switch ( $page_template ) {
|
94 |
+
|
95 |
+
case 'cartflows-default':
|
96 |
+
$file = CARTFLOWS_FLOW_DIR . 'templates/template-default.php';
|
97 |
+
$this->body_classes[] = $page_template;
|
98 |
+
break;
|
99 |
+
case 'cartflows-canvas':
|
100 |
+
$file = CARTFLOWS_FLOW_DIR . 'templates/template-canvas.php';
|
101 |
+
$this->body_classes[] = $page_template;
|
102 |
+
break;
|
103 |
+
default:
|
104 |
+
/**
|
105 |
+
* Remove Next/Prev Navigation
|
106 |
+
*/
|
107 |
+
add_filter( 'next_post_link', '__return_empty_string' );
|
108 |
+
add_filter( 'previous_post_link', '__return_empty_string' );
|
109 |
+
|
110 |
+
$page = locate_template( array( 'page.php' ) );
|
111 |
+
|
112 |
+
if ( ! empty( $page ) ) {
|
113 |
+
$file = $page;
|
114 |
+
}
|
115 |
+
|
116 |
+
break;
|
117 |
+
|
118 |
+
/**
|
119 |
+
* Default:
|
120 |
+
* $file = CARTFLOWS_FLOW_DIR . 'templates/template-default.php';
|
121 |
+
* $this->body_classes[] = 'cartflows-default';
|
122 |
+
* break;
|
123 |
+
*/
|
124 |
+
}
|
125 |
+
|
126 |
+
// Just to be safe, we check if the file exist first.
|
127 |
+
if ( file_exists( $file ) ) {
|
128 |
+
|
129 |
+
/* Add Body Class */
|
130 |
+
add_filter( 'body_class', array( $this, 'body_class' ) );
|
131 |
+
|
132 |
+
return $file;
|
133 |
+
} else {
|
134 |
+
echo $file;
|
135 |
+
}
|
136 |
+
}
|
137 |
+
|
138 |
+
return $template;
|
139 |
+
}
|
140 |
+
|
141 |
+
/**
|
142 |
+
* Body classes.
|
143 |
+
*
|
144 |
+
* @since 1.0.0
|
145 |
+
* @param array $classes Body classes.
|
146 |
+
* @return array
|
147 |
+
*/
|
148 |
+
public function body_class( $classes = array() ) {
|
149 |
+
|
150 |
+
$classes = array_merge( $classes, $this->body_classes );
|
151 |
+
|
152 |
+
return $classes;
|
153 |
+
}
|
154 |
+
|
155 |
+
/**
|
156 |
+
* Create custom post type
|
157 |
+
*/
|
158 |
+
public function step_post_type() {
|
159 |
+
|
160 |
+
$labels = array(
|
161 |
+
'name' => esc_html_x( 'Steps', 'flow step general name', 'cartflows' ),
|
162 |
+
'singular_name' => esc_html_x( 'Step', 'flow step singular name', 'cartflows' ),
|
163 |
+
'search_items' => esc_html__( 'Search Steps', 'cartflows' ),
|
164 |
+
'all_items' => esc_html__( 'All Steps', 'cartflows' ),
|
165 |
+
'edit_item' => esc_html__( 'Edit Step', 'cartflows' ),
|
166 |
+
'view_item' => esc_html__( 'View Step', 'cartflows' ),
|
167 |
+
'add_new' => esc_html__( 'Add New', 'cartflows' ),
|
168 |
+
'update_item' => esc_html__( 'Update Step', 'cartflows' ),
|
169 |
+
'add_new_item' => esc_html__( 'Add New', 'cartflows' ),
|
170 |
+
'new_item_name' => esc_html__( 'New Step Name', 'cartflows' ),
|
171 |
+
);
|
172 |
+
|
173 |
+
$permalink_settings = Cartflows_Helper::get_permalink_settings();
|
174 |
+
|
175 |
+
$args = array(
|
176 |
+
'labels' => $labels,
|
177 |
+
'public' => true,
|
178 |
+
'query_var' => true,
|
179 |
+
'can_export' => true,
|
180 |
+
'exclude_from_search' => true,
|
181 |
+
'show_ui' => true,
|
182 |
+
'show_in_menu' => false,
|
183 |
+
'show_in_admin_bar' => true,
|
184 |
+
'show_in_rest' => true,
|
185 |
+
'supports' => array( 'title', 'editor', 'elementor', 'revisions' ),
|
186 |
+
'capability_type' => 'post',
|
187 |
+
'capabilities' => array(
|
188 |
+
'create_posts' => 'do_not_allow', // Prior to Wordpress 4.5, this was false.
|
189 |
+
),
|
190 |
+
'map_meta_cap' => true,
|
191 |
+
);
|
192 |
+
|
193 |
+
if ( isset( $permalink_settings['permalink_structure'] ) && ! empty( $permalink_settings['permalink_structure'] ) ) {
|
194 |
+
$args['rewrite'] = array(
|
195 |
+
'slug' => $permalink_settings['permalink_structure'],
|
196 |
+
'with_front' => false,
|
197 |
+
);
|
198 |
+
|
199 |
+
} elseif ( isset( $permalink_settings['permalink'] ) && ! empty( $permalink_settings['permalink'] ) ) {
|
200 |
+
|
201 |
+
$args['rewrite'] = array(
|
202 |
+
'slug' => $permalink_settings['permalink'],
|
203 |
+
'with_front' => false,
|
204 |
+
);
|
205 |
+
}
|
206 |
+
|
207 |
+
register_post_type( CARTFLOWS_STEP_POST_TYPE, $args );
|
208 |
+
|
209 |
+
// Step Type.
|
210 |
+
$args = array(
|
211 |
+
'label' => __( 'Step Type', 'cartflows' ),
|
212 |
+
'public' => false,
|
213 |
+
'rewrite' => false,
|
214 |
+
'hierarchical' => false,
|
215 |
+
);
|
216 |
+
|
217 |
+
register_taxonomy( CARTFLOWS_TAXONOMY_STEP_TYPE, CARTFLOWS_STEP_POST_TYPE, $args );
|
218 |
+
|
219 |
+
// Step Flow.
|
220 |
+
$args = array(
|
221 |
+
'label' => __( 'Step Flow', 'cartflows' ),
|
222 |
+
'public' => false,
|
223 |
+
'rewrite' => false,
|
224 |
+
'hierarchical' => false,
|
225 |
+
);
|
226 |
+
|
227 |
+
register_taxonomy( CARTFLOWS_TAXONOMY_STEP_FLOW, CARTFLOWS_STEP_POST_TYPE, $args );
|
228 |
+
|
229 |
+
if ( is_admin() ) {
|
230 |
+
/**
|
231 |
+
* Register 'Elementor' & 'Beaver Builder' site types.
|
232 |
+
*
|
233 |
+
* @see self::add_terms();
|
234 |
+
*/
|
235 |
+
$taxonomy = CARTFLOWS_TAXONOMY_STEP_TYPE;
|
236 |
+
|
237 |
+
$terms = array(
|
238 |
+
array(
|
239 |
+
'name' => __( 'Landing', 'cartflows' ),
|
240 |
+
'slug' => 'landing',
|
241 |
+
'args' => array(
|
242 |
+
'slug' => 'landing',
|
243 |
+
),
|
244 |
+
),
|
245 |
+
array(
|
246 |
+
'name' => __( 'Optin (Woo)', 'cartflows' ),
|
247 |
+
'slug' => 'optin',
|
248 |
+
'args' => array(
|
249 |
+
'slug' => 'optin',
|
250 |
+
),
|
251 |
+
),
|
252 |
+
array(
|
253 |
+
'name' => __( 'Checkout (Woo)', 'cartflows' ),
|
254 |
+
'slug' => 'checkout',
|
255 |
+
'args' => array(
|
256 |
+
'slug' => 'checkout',
|
257 |
+
),
|
258 |
+
),
|
259 |
+
array(
|
260 |
+
'name' => __( 'Thank You (Woo)', 'cartflows' ),
|
261 |
+
'slug' => 'thankyou',
|
262 |
+
'args' => array(
|
263 |
+
'slug' => 'thankyou',
|
264 |
+
),
|
265 |
+
),
|
266 |
+
array(
|
267 |
+
'name' => __( 'Upsell (Woo)', 'cartflows' ),
|
268 |
+
'slug' => 'upsell',
|
269 |
+
'args' => array(
|
270 |
+
'slug' => 'upsell',
|
271 |
+
),
|
272 |
+
),
|
273 |
+
array(
|
274 |
+
'name' => __( 'Downsell (Woo)', 'cartflows' ),
|
275 |
+
'slug' => 'downsell',
|
276 |
+
'args' => array(
|
277 |
+
'slug' => 'downsell',
|
278 |
+
),
|
279 |
+
),
|
280 |
+
);
|
281 |
+
|
282 |
+
$this->add_terms( $taxonomy, $terms );
|
283 |
+
|
284 |
+
}
|
285 |
+
}
|
286 |
+
|
287 |
+
/**
|
288 |
+
* Add WordPress templates.
|
289 |
+
*
|
290 |
+
* Adds Cartflows templates to steps
|
291 |
+
*
|
292 |
+
* @since 1.0.0
|
293 |
+
* @access public
|
294 |
+
*/
|
295 |
+
public function add_wp_templates_support() {
|
296 |
+
add_filter( 'theme_' . CARTFLOWS_STEP_POST_TYPE . '_templates', array( $this, 'add_page_templates' ), 99, 4 );
|
297 |
+
}
|
298 |
+
|
299 |
+
/**
|
300 |
+
* Add page templates.
|
301 |
+
*
|
302 |
+
* @since 1.0.0
|
303 |
+
* @access public
|
304 |
+
*
|
305 |
+
* @param array $page_templates Array of page templates.
|
306 |
+
*
|
307 |
+
* @param object $wp_theme wp theme.
|
308 |
+
* @param object $post post.
|
309 |
+
*
|
310 |
+
* @return array Page templates.
|
311 |
+
*/
|
312 |
+
public function add_page_templates( $page_templates, $wp_theme, $post ) {
|
313 |
+
|
314 |
+
$page_templates = array(
|
315 |
+
'cartflows-default' => _x( 'CartFlows — Boxed', 'cartflows' ),
|
316 |
+
'cartflows-canvas' => _x( 'Template for Page Builders', 'cartflows' ),
|
317 |
+
);
|
318 |
+
|
319 |
+
return $page_templates;
|
320 |
+
}
|
321 |
+
|
322 |
+
/**
|
323 |
+
* Query fixe throwing error on 404 page due our post type changes.
|
324 |
+
* We are setting post_type as empty array to fix the issue.
|
325 |
+
* Ther error was throwing due to redirect_canonical function
|
326 |
+
* This fix is apply for 404 page only
|
327 |
+
*/
|
328 |
+
public function query_fix() {
|
329 |
+
|
330 |
+
global $wp_query;
|
331 |
+
|
332 |
+
if ( $wp_query->is_404() ) {
|
333 |
+
$wp_query->set( 'post_type', array() );
|
334 |
+
}
|
335 |
+
}
|
336 |
+
|
337 |
+
/**
|
338 |
+
* Prevent slug duplicated
|
339 |
+
*
|
340 |
+
* @param string $slug post slug.
|
341 |
+
* @param int $post_ID post id.
|
342 |
+
* @param string $post_status post status.
|
343 |
+
* @param string $post_type post type.
|
344 |
+
* @param int $post_parent post parent id.
|
345 |
+
* @param string $original_slug original slug.
|
346 |
+
* @return string
|
347 |
+
*/
|
348 |
+
public function prevent_slug_duplicates( $slug, $post_ID, $post_status, $post_type, $post_parent, $original_slug ) {
|
349 |
+
|
350 |
+
$check_post_types = array(
|
351 |
+
'post',
|
352 |
+
'page',
|
353 |
+
CARTFLOWS_STEP_POST_TYPE,
|
354 |
+
);
|
355 |
+
|
356 |
+
if ( ! in_array( $post_type, $check_post_types, true ) ) {
|
357 |
+
return $slug;
|
358 |
+
}
|
359 |
+
|
360 |
+
if ( CARTFLOWS_STEP_POST_TYPE == $post_type ) {
|
361 |
+
// Saving a post, check for duplicates in POST or PAGE post types.
|
362 |
+
$post_match = get_page_by_path( $slug, 'OBJECT', 'post' );
|
363 |
+
$page_match = get_page_by_path( $slug, 'OBJECT', 'page' );
|
364 |
+
|
365 |
+
if ( $post_match || $page_match ) {
|
366 |
+
$slug .= '-2';
|
367 |
+
}
|
368 |
+
} else {
|
369 |
+
|
370 |
+
// Saving a POST or PAGE, check for duplicates in CARTFLOWS_STEP_POST_TYPE post type.
|
371 |
+
$custom_post_type_match = get_page_by_path( $slug, 'OBJECT', CARTFLOWS_STEP_POST_TYPE );
|
372 |
+
|
373 |
+
if ( $custom_post_type_match ) {
|
374 |
+
$slug .= '-2';
|
375 |
+
}
|
376 |
+
}
|
377 |
+
|
378 |
+
return $slug;
|
379 |
+
}
|
380 |
+
|
381 |
+
/**
|
382 |
+
* Add Update messages for any custom post type
|
383 |
+
*
|
384 |
+
* @param array $messages Array of default messages.
|
385 |
+
*/
|
386 |
+
public function post_update_messages( $messages ) {
|
387 |
+
|
388 |
+
$custom_post_type = get_post_type( get_the_ID() );
|
389 |
+
|
390 |
+
if ( CARTFLOWS_STEP_POST_TYPE == $custom_post_type ) {
|
391 |
+
|
392 |
+
$obj = get_post_type_object( $custom_post_type );
|
393 |
+
$singular_name = $obj->labels->singular_name;
|
394 |
+
$messages[ $custom_post_type ] = array(
|
395 |
+
0 => '', // Unused. Messages start at index 1.
|
396 |
+
/* translators: %s: singular custom post type name */
|
397 |
+
1 => sprintf( __( '%s updated.', 'cartflows' ), $singular_name ),
|
398 |
+
/* translators: %s: singular custom post type name */
|
399 |
+
2 => sprintf( __( 'Custom %s updated.', 'cartflows' ), $singular_name ),
|
400 |
+
/* translators: %s: singular custom post type name */
|
401 |
+
3 => sprintf( __( 'Custom %s deleted.', 'cartflows' ), $singular_name ),
|
402 |
+
/* translators: %s: singular custom post type name */
|
403 |
+
4 => sprintf( __( '%s updated.', 'cartflows' ), $singular_name ),
|
404 |
+
/* translators: %1$s: singular custom post type name ,%2$s: date and time of the revision */
|
405 |
+
5 => isset( $_GET['revision'] ) ? sprintf( __( '%1$s restored to revision from %2$s', 'cartflows' ), $singular_name, wp_post_revision_title( (int) $_GET['revision'], false ) ) : false, //phpcs:ignore
|
406 |
+
/* translators: %s: singular custom post type name */
|
407 |
+
6 => sprintf( __( '%s published.', 'cartflows' ), $singular_name ),
|
408 |
+
/* translators: %s: singular custom post type name */
|
409 |
+
7 => sprintf( __( '%s saved.', 'cartflows' ), $singular_name ),
|
410 |
+
/* translators: %s: singular custom post type name */
|
411 |
+
8 => sprintf( __( '%s submitted.', 'cartflows' ), $singular_name ),
|
412 |
+
/* translators: %s: singular custom post type name */
|
413 |
+
9 => sprintf( __( '%s scheduled for.', 'cartflows' ), $singular_name ),
|
414 |
+
/* translators: %s: singular custom post type name */
|
415 |
+
10 => sprintf( __( '%s draft updated.', 'cartflows' ), $singular_name ),
|
416 |
+
);
|
417 |
+
}
|
418 |
+
|
419 |
+
return $messages;
|
420 |
+
}
|
421 |
+
|
422 |
+
/**
|
423 |
+
* Add Terms for Taxonomy.
|
424 |
+
*
|
425 |
+
* => Example.
|
426 |
+
*
|
427 |
+
* $taxonomy = '{taxonomy}';
|
428 |
+
* $terms = array(
|
429 |
+
* array(
|
430 |
+
* 'name' => 'Landing',
|
431 |
+
* 'slug' => 'landing',
|
432 |
+
* ),
|
433 |
+
* array(
|
434 |
+
* 'name' => 'Checkout',
|
435 |
+
* 'slug' => 'checkout',
|
436 |
+
* ),
|
437 |
+
* );
|
438 |
+
*
|
439 |
+
* self::add_terms( $taxonomy, $terms );
|
440 |
+
*
|
441 |
+
* @since 1.0.0
|
442 |
+
* @param string $taxonomy Taxonomy Name.
|
443 |
+
* @param array $terms Terms list.
|
444 |
+
* @return void
|
445 |
+
*/
|
446 |
+
public function add_terms( $taxonomy = '', $terms = array() ) {
|
447 |
+
|
448 |
+
foreach ( $terms as $key => $term ) {
|
449 |
+
|
450 |
+
$term_exist = term_exists( $term['slug'], $taxonomy );
|
451 |
+
|
452 |
+
if ( empty( $term_exist ) ) {
|
453 |
+
|
454 |
+
/**
|
455 |
+
* Add additional args if passed from request.
|
456 |
+
*
|
457 |
+
* @see https://codex.wordpress.org/Function_Reference/wp_insert_term
|
458 |
+
*/
|
459 |
+
if ( array_key_exists( 'args', $term ) ) {
|
460 |
+
wp_insert_term( $term['name'], $taxonomy, $term['args'] );
|
461 |
+
} else {
|
462 |
+
|
463 |
+
$term['args'] = array( $term['slug'] );
|
464 |
+
|
465 |
+
wp_insert_term( $term['name'], $taxonomy, $term['args'] );
|
466 |
+
}
|
467 |
+
}
|
468 |
+
}
|
469 |
+
}
|
470 |
+
|
471 |
+
/**
|
472 |
+
* Redirect admin pages.
|
473 |
+
*
|
474 |
+
* @return void
|
475 |
+
*/
|
476 |
+
public function disallowed_admin_all_steps_view() {
|
477 |
+
|
478 |
+
global $pagenow;
|
479 |
+
|
480 |
+
// Check current admin page. If step post type view redirect it to flow.
|
481 |
+
if ( 'edit.php' === $pagenow && isset( $_GET['post_type'] ) && CARTFLOWS_STEP_POST_TYPE === $_GET['post_type'] ) { //phpcs:ignore
|
482 |
+
|
483 |
+
if ( isset( $_GET['debug'] ) && $_GET['debug'] ) { //phpcs:ignore
|
484 |
+
return;
|
485 |
+
}
|
486 |
+
|
487 |
+
wp_safe_redirect( admin_url( 'edit.php?post_type=' . CARTFLOWS_FLOW_POST_TYPE ) );
|
488 |
+
exit;
|
489 |
+
}
|
490 |
+
}
|
491 |
+
}
|
492 |
+
|
493 |
+
/**
|
494 |
+
* Kicking this off by calling 'get_instance()' method
|
495 |
+
*/
|
496 |
+
Cartflows_Step_Post_Type::get_instance();
|
|
|
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.me/BrainstormForce
|
|
4 |
Tags: woocommerce, funnel builder, sales funnels, elementor, beaver builder
|
5 |
Requires at least: 4.4
|
6 |
Tested up to: 5.4
|
7 |
-
Stable tag: 1.5.
|
8 |
Requires PHP: 5.6
|
9 |
License: GPLv2 or later
|
10 |
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
@@ -125,8 +125,13 @@ Glad you asked! CartFlows Pro is an optional add-on to CartFlows that adds addit
|
|
125 |
|
126 |
== Changelog ==
|
127 |
|
|
|
|
|
|
|
|
|
|
|
128 |
= Version 1.5.8 - Saturday, 9th May 2020 =
|
129 |
-
|
130 |
|
131 |
= Version 1.5.7 - Monday, 4th May 2020 =
|
132 |
* New: Gutenberg support added for steps.
|
4 |
Tags: woocommerce, funnel builder, sales funnels, elementor, beaver builder
|
5 |
Requires at least: 4.4
|
6 |
Tested up to: 5.4
|
7 |
+
Stable tag: 1.5.9
|
8 |
Requires PHP: 5.6
|
9 |
License: GPLv2 or later
|
10 |
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
125 |
|
126 |
== Changelog ==
|
127 |
|
128 |
+
= Version 1.5.9 - Thursday, 14th May 2020 =
|
129 |
+
* New: Added quantity and discount options for the product.
|
130 |
+
* Fix: Google Analytics JS error.
|
131 |
+
* Fix: Astra theme PHP notice when WooCommerce was not activated.
|
132 |
+
|
133 |
= Version 1.5.8 - Saturday, 9th May 2020 =
|
134 |
+
* Fix: Incorrect required field error messages with PayPal.
|
135 |
|
136 |
= Version 1.5.7 - Monday, 4th May 2020 =
|
137 |
* New: Gutenberg support added for steps.
|
theme-support/astra/class-cartflows-astra-compatibility.php
CHANGED
@@ -1,113 +1,113 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Astra theme compatibility
|
4 |
-
*
|
5 |
-
* @package CartFlows
|
6 |
-
*/
|
7 |
-
|
8 |
-
if ( ! class_exists( 'Cartflows_Astra_Compatibility' ) ) :
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Class for Astra theme compatibility
|
12 |
-
*/
|
13 |
-
class Cartflows_Astra_Compatibility {
|
14 |
-
|
15 |
-
/**
|
16 |
-
* Member Variable
|
17 |
-
*
|
18 |
-
* @var instance
|
19 |
-
*/
|
20 |
-
private static $instance;
|
21 |
-
|
22 |
-
/**
|
23 |
-
* Initiator
|
24 |
-
*
|
25 |
-
* @since 1.5.7
|
26 |
-
*/
|
27 |
-
public static function get_instance() {
|
28 |
-
if ( ! isset( self::$instance ) ) {
|
29 |
-
self::$instance = new self();
|
30 |
-
}
|
31 |
-
return self::$instance;
|
32 |
-
}
|
33 |
-
|
34 |
-
/**
|
35 |
-
* Constructor
|
36 |
-
*
|
37 |
-
* @since 1.5.7
|
38 |
-
*/
|
39 |
-
public function __construct() {
|
40 |
-
|
41 |
-
add_action( 'cartflows_checkout_before_shortcode', array( $this, 'cartflows_theme_compatibility_astra' ) );
|
42 |
-
add_action( 'cartflows_optin_before_shortcode', array( $this, 'cartflows_theme_compatibility_astra' ) );
|
43 |
-
|
44 |
-
add_action( 'wp', array( $this, 'cartflows_load_wp_actions_for_astra' ), 56 );
|
45 |
-
}
|
46 |
-
|
47 |
-
|
48 |
-
/**
|
49 |
-
* Function to remove the astra hooks.
|
50 |
-
*
|
51 |
-
* @since 1.5.7
|
52 |
-
*
|
53 |
-
* @return void
|
54 |
-
*/
|
55 |
-
public function cartflows_theme_compatibility_astra() {
|
56 |
-
remove_action( 'woocommerce_checkout_before_customer_details', 'astra_two_step_checkout_form_wrapper_div', 1 );
|
57 |
-
remove_action( 'woocommerce_checkout_before_customer_details', 'astra_two_step_checkout_form_ul_wrapper', 2 );
|
58 |
-
remove_action( 'woocommerce_checkout_order_review', 'astra_woocommerce_div_wrapper_close', 30 );
|
59 |
-
remove_action( 'woocommerce_checkout_order_review', 'astra_woocommerce_ul_close', 30 );
|
60 |
-
remove_action( 'woocommerce_checkout_before_customer_details', 'astra_two_step_checkout_address_li_wrapper', 5 );
|
61 |
-
remove_action( 'woocommerce_checkout_after_customer_details', 'astra_woocommerce_li_close' );
|
62 |
-
remove_action( 'woocommerce_checkout_before_order_review', 'astra_two_step_checkout_order_review_wrap', 1 );
|
63 |
-
remove_action( 'woocommerce_checkout_after_order_review', 'astra_woocommerce_li_close', 40 );
|
64 |
-
|
65 |
-
add_filter( 'astra_theme_woocommerce_dynamic_css', '__return_empty_string' );
|
66 |
-
}
|
67 |
-
|
68 |
-
|
69 |
-
/**
|
70 |
-
* Function to add/remove the actions/hooks on wp action.
|
71 |
-
*
|
72 |
-
* @since 1.5.7
|
73 |
-
*
|
74 |
-
* @return void
|
75 |
-
*/
|
76 |
-
public function cartflows_load_wp_actions_for_astra() {
|
77 |
-
|
78 |
-
// Return if not the CartFlows page.
|
79 |
-
if ( ! wcf()->utils->is_step_post_type() ) {
|
80 |
-
return;
|
81 |
-
}
|
82 |
-
|
83 |
-
$page_template = get_post_meta( _get_wcf_step_id(), '_wp_page_template', true );
|
84 |
-
|
85 |
-
if ( _wcf_supported_template( $page_template ) ) {
|
86 |
-
return;
|
87 |
-
}
|
88 |
-
|
89 |
-
add_action( 'wp_enqueue_scripts', array( $this, 'astra_compatibility_external_css' ), 101 );
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
}
|
95 |
-
|
96 |
-
/**
|
97 |
-
* Load the CSS
|
98 |
-
*
|
99 |
-
* @since 1.5.7
|
100 |
-
*
|
101 |
-
* @return void
|
102 |
-
*/
|
103 |
-
public function astra_compatibility_external_css() {
|
104 |
-
|
105 |
-
wp_enqueue_style( 'wcf-checkout-astra-compatibility', CARTFLOWS_URL . 'theme-support/astra/css/astra-compatibility.css', '', CARTFLOWS_VER );
|
106 |
-
}
|
107 |
-
}
|
108 |
-
/**
|
109 |
-
* Kicking this off by calling 'get_instance()' method
|
110 |
-
*/
|
111 |
-
Cartflows_Astra_Compatibility::get_instance();
|
112 |
-
|
113 |
-
endif;
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Astra theme compatibility
|
4 |
+
*
|
5 |
+
* @package CartFlows
|
6 |
+
*/
|
7 |
+
|
8 |
+
if ( ! class_exists( 'Cartflows_Astra_Compatibility' ) ) :
|
9 |
+
|
10 |
+
/**
|
11 |
+
* Class for Astra theme compatibility
|
12 |
+
*/
|
13 |
+
class Cartflows_Astra_Compatibility {
|
14 |
+
|
15 |
+
/**
|
16 |
+
* Member Variable
|
17 |
+
*
|
18 |
+
* @var instance
|
19 |
+
*/
|
20 |
+
private static $instance;
|
21 |
+
|
22 |
+
/**
|
23 |
+
* Initiator
|
24 |
+
*
|
25 |
+
* @since 1.5.7
|
26 |
+
*/
|
27 |
+
public static function get_instance() {
|
28 |
+
if ( ! isset( self::$instance ) ) {
|
29 |
+
self::$instance = new self();
|
30 |
+
}
|
31 |
+
return self::$instance;
|
32 |
+
}
|
33 |
+
|
34 |
+
/**
|
35 |
+
* Constructor
|
36 |
+
*
|
37 |
+
* @since 1.5.7
|
38 |
+
*/
|
39 |
+
public function __construct() {
|
40 |
+
|
41 |
+
add_action( 'cartflows_checkout_before_shortcode', array( $this, 'cartflows_theme_compatibility_astra' ) );
|
42 |
+
add_action( 'cartflows_optin_before_shortcode', array( $this, 'cartflows_theme_compatibility_astra' ) );
|
43 |
+
|
44 |
+
add_action( 'wp', array( $this, 'cartflows_load_wp_actions_for_astra' ), 56 );
|
45 |
+
}
|
46 |
+
|
47 |
+
|
48 |
+
/**
|
49 |
+
* Function to remove the astra hooks.
|
50 |
+
*
|
51 |
+
* @since 1.5.7
|
52 |
+
*
|
53 |
+
* @return void
|
54 |
+
*/
|
55 |
+
public function cartflows_theme_compatibility_astra() {
|
56 |
+
remove_action( 'woocommerce_checkout_before_customer_details', 'astra_two_step_checkout_form_wrapper_div', 1 );
|
57 |
+
remove_action( 'woocommerce_checkout_before_customer_details', 'astra_two_step_checkout_form_ul_wrapper', 2 );
|
58 |
+
remove_action( 'woocommerce_checkout_order_review', 'astra_woocommerce_div_wrapper_close', 30 );
|
59 |
+
remove_action( 'woocommerce_checkout_order_review', 'astra_woocommerce_ul_close', 30 );
|
60 |
+
remove_action( 'woocommerce_checkout_before_customer_details', 'astra_two_step_checkout_address_li_wrapper', 5 );
|
61 |
+
remove_action( 'woocommerce_checkout_after_customer_details', 'astra_woocommerce_li_close' );
|
62 |
+
remove_action( 'woocommerce_checkout_before_order_review', 'astra_two_step_checkout_order_review_wrap', 1 );
|
63 |
+
remove_action( 'woocommerce_checkout_after_order_review', 'astra_woocommerce_li_close', 40 );
|
64 |
+
|
65 |
+
add_filter( 'astra_theme_woocommerce_dynamic_css', '__return_empty_string' );
|
66 |
+
}
|
67 |
+
|
68 |
+
|
69 |
+
/**
|
70 |
+
* Function to add/remove the actions/hooks on wp action.
|
71 |
+
*
|
72 |
+
* @since 1.5.7
|
73 |
+
*
|
74 |
+
* @return void
|
75 |
+
*/
|
76 |
+
public function cartflows_load_wp_actions_for_astra() {
|
77 |
+
|
78 |
+
// Return if not the CartFlows page.
|
79 |
+
if ( ! wcf()->utils->is_step_post_type() ) {
|
80 |
+
return;
|
81 |
+
}
|
82 |
+
|
83 |
+
$page_template = get_post_meta( _get_wcf_step_id(), '_wp_page_template', true );
|
84 |
+
|
85 |
+
if ( _wcf_supported_template( $page_template ) ) {
|
86 |
+
return;
|
87 |
+
}
|
88 |
+
|
89 |
+
add_action( 'wp_enqueue_scripts', array( $this, 'astra_compatibility_external_css' ), 101 );
|
90 |
+
|
91 |
+
// Re-add the WooCommerce's styles & script swhich are form Astra.
|
92 |
+
$astra_woo = Astra_Woocommerce::get_instance();
|
93 |
+
add_filter( 'woocommerce_enqueue_styles', array( $astra_woo, 'woo_filter_style' ), 9999 );
|
94 |
+
}
|
95 |
+
|
96 |
+
/**
|
97 |
+
* Load the CSS
|
98 |
+
*
|
99 |
+
* @since 1.5.7
|
100 |
+
*
|
101 |
+
* @return void
|
102 |
+
*/
|
103 |
+
public function astra_compatibility_external_css() {
|
104 |
+
|
105 |
+
wp_enqueue_style( 'wcf-checkout-astra-compatibility', CARTFLOWS_URL . 'theme-support/astra/css/astra-compatibility.css', '', CARTFLOWS_VER );
|
106 |
+
}
|
107 |
+
}
|
108 |
+
/**
|
109 |
+
* Kicking this off by calling 'get_instance()' method
|
110 |
+
*/
|
111 |
+
Cartflows_Astra_Compatibility::get_instance();
|
112 |
+
|
113 |
+
endif;
|