Initial release of mage woo event booking manager
This commit is contained in:
parent
213cf47c76
commit
88a25a962d
|
@ -0,0 +1,339 @@
|
||||||
|
GNU GENERAL PUBLIC LICENSE
|
||||||
|
Version 2, June 1991
|
||||||
|
|
||||||
|
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
|
||||||
|
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
Everyone is permitted to copy and distribute verbatim copies
|
||||||
|
of this license document, but changing it is not allowed.
|
||||||
|
|
||||||
|
Preamble
|
||||||
|
|
||||||
|
The licenses for most software are designed to take away your
|
||||||
|
freedom to share and change it. By contrast, the GNU General Public
|
||||||
|
License is intended to guarantee your freedom to share and change free
|
||||||
|
software--to make sure the software is free for all its users. This
|
||||||
|
General Public License applies to most of the Free Software
|
||||||
|
Foundation's software and to any other program whose authors commit to
|
||||||
|
using it. (Some other Free Software Foundation software is covered by
|
||||||
|
the GNU Lesser General Public License instead.) You can apply it to
|
||||||
|
your programs, too.
|
||||||
|
|
||||||
|
When we speak of free software, we are referring to freedom, not
|
||||||
|
price. Our General Public Licenses are designed to make sure that you
|
||||||
|
have the freedom to distribute copies of free software (and charge for
|
||||||
|
this service if you wish), that you receive source code or can get it
|
||||||
|
if you want it, that you can change the software or use pieces of it
|
||||||
|
in new free programs; and that you know you can do these things.
|
||||||
|
|
||||||
|
To protect your rights, we need to make restrictions that forbid
|
||||||
|
anyone to deny you these rights or to ask you to surrender the rights.
|
||||||
|
These restrictions translate to certain responsibilities for you if you
|
||||||
|
distribute copies of the software, or if you modify it.
|
||||||
|
|
||||||
|
For example, if you distribute copies of such a program, whether
|
||||||
|
gratis or for a fee, you must give the recipients all the rights that
|
||||||
|
you have. You must make sure that they, too, receive or can get the
|
||||||
|
source code. And you must show them these terms so they know their
|
||||||
|
rights.
|
||||||
|
|
||||||
|
We protect your rights with two steps: (1) copyright the software, and
|
||||||
|
(2) offer you this license which gives you legal permission to copy,
|
||||||
|
distribute and/or modify the software.
|
||||||
|
|
||||||
|
Also, for each author's protection and ours, we want to make certain
|
||||||
|
that everyone understands that there is no warranty for this free
|
||||||
|
software. If the software is modified by someone else and passed on, we
|
||||||
|
want its recipients to know that what they have is not the original, so
|
||||||
|
that any problems introduced by others will not reflect on the original
|
||||||
|
authors' reputations.
|
||||||
|
|
||||||
|
Finally, any free program is threatened constantly by software
|
||||||
|
patents. We wish to avoid the danger that redistributors of a free
|
||||||
|
program will individually obtain patent licenses, in effect making the
|
||||||
|
program proprietary. To prevent this, we have made it clear that any
|
||||||
|
patent must be licensed for everyone's free use or not licensed at all.
|
||||||
|
|
||||||
|
The precise terms and conditions for copying, distribution and
|
||||||
|
modification follow.
|
||||||
|
|
||||||
|
GNU GENERAL PUBLIC LICENSE
|
||||||
|
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||||
|
|
||||||
|
0. This License applies to any program or other work which contains
|
||||||
|
a notice placed by the copyright holder saying it may be distributed
|
||||||
|
under the terms of this General Public License. The "Program", below,
|
||||||
|
refers to any such program or work, and a "work based on the Program"
|
||||||
|
means either the Program or any derivative work under copyright law:
|
||||||
|
that is to say, a work containing the Program or a portion of it,
|
||||||
|
either verbatim or with modifications and/or translated into another
|
||||||
|
language. (Hereinafter, translation is included without limitation in
|
||||||
|
the term "modification".) Each licensee is addressed as "you".
|
||||||
|
|
||||||
|
Activities other than copying, distribution and modification are not
|
||||||
|
covered by this License; they are outside its scope. The act of
|
||||||
|
running the Program is not restricted, and the output from the Program
|
||||||
|
is covered only if its contents constitute a work based on the
|
||||||
|
Program (independent of having been made by running the Program).
|
||||||
|
Whether that is true depends on what the Program does.
|
||||||
|
|
||||||
|
1. You may copy and distribute verbatim copies of the Program's
|
||||||
|
source code as you receive it, in any medium, provided that you
|
||||||
|
conspicuously and appropriately publish on each copy an appropriate
|
||||||
|
copyright notice and disclaimer of warranty; keep intact all the
|
||||||
|
notices that refer to this License and to the absence of any warranty;
|
||||||
|
and give any other recipients of the Program a copy of this License
|
||||||
|
along with the Program.
|
||||||
|
|
||||||
|
You may charge a fee for the physical act of transferring a copy, and
|
||||||
|
you may at your option offer warranty protection in exchange for a fee.
|
||||||
|
|
||||||
|
2. You may modify your copy or copies of the Program or any portion
|
||||||
|
of it, thus forming a work based on the Program, and copy and
|
||||||
|
distribute such modifications or work under the terms of Section 1
|
||||||
|
above, provided that you also meet all of these conditions:
|
||||||
|
|
||||||
|
a) You must cause the modified files to carry prominent notices
|
||||||
|
stating that you changed the files and the date of any change.
|
||||||
|
|
||||||
|
b) You must cause any work that you distribute or publish, that in
|
||||||
|
whole or in part contains or is derived from the Program or any
|
||||||
|
part thereof, to be licensed as a whole at no charge to all third
|
||||||
|
parties under the terms of this License.
|
||||||
|
|
||||||
|
c) If the modified program normally reads commands interactively
|
||||||
|
when run, you must cause it, when started running for such
|
||||||
|
interactive use in the most ordinary way, to print or display an
|
||||||
|
announcement including an appropriate copyright notice and a
|
||||||
|
notice that there is no warranty (or else, saying that you provide
|
||||||
|
a warranty) and that users may redistribute the program under
|
||||||
|
these conditions, and telling the user how to view a copy of this
|
||||||
|
License. (Exception: if the Program itself is interactive but
|
||||||
|
does not normally print such an announcement, your work based on
|
||||||
|
the Program is not required to print an announcement.)
|
||||||
|
|
||||||
|
These requirements apply to the modified work as a whole. If
|
||||||
|
identifiable sections of that work are not derived from the Program,
|
||||||
|
and can be reasonably considered independent and separate works in
|
||||||
|
themselves, then this License, and its terms, do not apply to those
|
||||||
|
sections when you distribute them as separate works. But when you
|
||||||
|
distribute the same sections as part of a whole which is a work based
|
||||||
|
on the Program, the distribution of the whole must be on the terms of
|
||||||
|
this License, whose permissions for other licensees extend to the
|
||||||
|
entire whole, and thus to each and every part regardless of who wrote it.
|
||||||
|
|
||||||
|
Thus, it is not the intent of this section to claim rights or contest
|
||||||
|
your rights to work written entirely by you; rather, the intent is to
|
||||||
|
exercise the right to control the distribution of derivative or
|
||||||
|
collective works based on the Program.
|
||||||
|
|
||||||
|
In addition, mere aggregation of another work not based on the Program
|
||||||
|
with the Program (or with a work based on the Program) on a volume of
|
||||||
|
a storage or distribution medium does not bring the other work under
|
||||||
|
the scope of this License.
|
||||||
|
|
||||||
|
3. You may copy and distribute the Program (or a work based on it,
|
||||||
|
under Section 2) in object code or executable form under the terms of
|
||||||
|
Sections 1 and 2 above provided that you also do one of the following:
|
||||||
|
|
||||||
|
a) Accompany it with the complete corresponding machine-readable
|
||||||
|
source code, which must be distributed under the terms of Sections
|
||||||
|
1 and 2 above on a medium customarily used for software interchange; or,
|
||||||
|
|
||||||
|
b) Accompany it with a written offer, valid for at least three
|
||||||
|
years, to give any third party, for a charge no more than your
|
||||||
|
cost of physically performing source distribution, a complete
|
||||||
|
machine-readable copy of the corresponding source code, to be
|
||||||
|
distributed under the terms of Sections 1 and 2 above on a medium
|
||||||
|
customarily used for software interchange; or,
|
||||||
|
|
||||||
|
c) Accompany it with the information you received as to the offer
|
||||||
|
to distribute corresponding source code. (This alternative is
|
||||||
|
allowed only for noncommercial distribution and only if you
|
||||||
|
received the program in object code or executable form with such
|
||||||
|
an offer, in accord with Subsection b above.)
|
||||||
|
|
||||||
|
The source code for a work means the preferred form of the work for
|
||||||
|
making modifications to it. For an executable work, complete source
|
||||||
|
code means all the source code for all modules it contains, plus any
|
||||||
|
associated interface definition files, plus the scripts used to
|
||||||
|
control compilation and installation of the executable. However, as a
|
||||||
|
special exception, the source code distributed need not include
|
||||||
|
anything that is normally distributed (in either source or binary
|
||||||
|
form) with the major components (compiler, kernel, and so on) of the
|
||||||
|
operating system on which the executable runs, unless that component
|
||||||
|
itself accompanies the executable.
|
||||||
|
|
||||||
|
If distribution of executable or object code is made by offering
|
||||||
|
access to copy from a designated place, then offering equivalent
|
||||||
|
access to copy the source code from the same place counts as
|
||||||
|
distribution of the source code, even though third parties are not
|
||||||
|
compelled to copy the source along with the object code.
|
||||||
|
|
||||||
|
4. You may not copy, modify, sublicense, or distribute the Program
|
||||||
|
except as expressly provided under this License. Any attempt
|
||||||
|
otherwise to copy, modify, sublicense or distribute the Program is
|
||||||
|
void, and will automatically terminate your rights under this License.
|
||||||
|
However, parties who have received copies, or rights, from you under
|
||||||
|
this License will not have their licenses terminated so long as such
|
||||||
|
parties remain in full compliance.
|
||||||
|
|
||||||
|
5. You are not required to accept this License, since you have not
|
||||||
|
signed it. However, nothing else grants you permission to modify or
|
||||||
|
distribute the Program or its derivative works. These actions are
|
||||||
|
prohibited by law if you do not accept this License. Therefore, by
|
||||||
|
modifying or distributing the Program (or any work based on the
|
||||||
|
Program), you indicate your acceptance of this License to do so, and
|
||||||
|
all its terms and conditions for copying, distributing or modifying
|
||||||
|
the Program or works based on it.
|
||||||
|
|
||||||
|
6. Each time you redistribute the Program (or any work based on the
|
||||||
|
Program), the recipient automatically receives a license from the
|
||||||
|
original licensor to copy, distribute or modify the Program subject to
|
||||||
|
these terms and conditions. You may not impose any further
|
||||||
|
restrictions on the recipients' exercise of the rights granted herein.
|
||||||
|
You are not responsible for enforcing compliance by third parties to
|
||||||
|
this License.
|
||||||
|
|
||||||
|
7. If, as a consequence of a court judgment or allegation of patent
|
||||||
|
infringement or for any other reason (not limited to patent issues),
|
||||||
|
conditions are imposed on you (whether by court order, agreement or
|
||||||
|
otherwise) that contradict the conditions of this License, they do not
|
||||||
|
excuse you from the conditions of this License. If you cannot
|
||||||
|
distribute so as to satisfy simultaneously your obligations under this
|
||||||
|
License and any other pertinent obligations, then as a consequence you
|
||||||
|
may not distribute the Program at all. For example, if a patent
|
||||||
|
license would not permit royalty-free redistribution of the Program by
|
||||||
|
all those who receive copies directly or indirectly through you, then
|
||||||
|
the only way you could satisfy both it and this License would be to
|
||||||
|
refrain entirely from distribution of the Program.
|
||||||
|
|
||||||
|
If any portion of this section is held invalid or unenforceable under
|
||||||
|
any particular circumstance, the balance of the section is intended to
|
||||||
|
apply and the section as a whole is intended to apply in other
|
||||||
|
circumstances.
|
||||||
|
|
||||||
|
It is not the purpose of this section to induce you to infringe any
|
||||||
|
patents or other property right claims or to contest validity of any
|
||||||
|
such claims; this section has the sole purpose of protecting the
|
||||||
|
integrity of the free software distribution system, which is
|
||||||
|
implemented by public license practices. Many people have made
|
||||||
|
generous contributions to the wide range of software distributed
|
||||||
|
through that system in reliance on consistent application of that
|
||||||
|
system; it is up to the author/donor to decide if he or she is willing
|
||||||
|
to distribute software through any other system and a licensee cannot
|
||||||
|
impose that choice.
|
||||||
|
|
||||||
|
This section is intended to make thoroughly clear what is believed to
|
||||||
|
be a consequence of the rest of this License.
|
||||||
|
|
||||||
|
8. If the distribution and/or use of the Program is restricted in
|
||||||
|
certain countries either by patents or by copyrighted interfaces, the
|
||||||
|
original copyright holder who places the Program under this License
|
||||||
|
may add an explicit geographical distribution limitation excluding
|
||||||
|
those countries, so that distribution is permitted only in or among
|
||||||
|
countries not thus excluded. In such case, this License incorporates
|
||||||
|
the limitation as if written in the body of this License.
|
||||||
|
|
||||||
|
9. The Free Software Foundation may publish revised and/or new versions
|
||||||
|
of the General Public License from time to time. Such new versions will
|
||||||
|
be similar in spirit to the present version, but may differ in detail to
|
||||||
|
address new problems or concerns.
|
||||||
|
|
||||||
|
Each version is given a distinguishing version number. If the Program
|
||||||
|
specifies a version number of this License which applies to it and "any
|
||||||
|
later version", you have the option of following the terms and conditions
|
||||||
|
either of that version or of any later version published by the Free
|
||||||
|
Software Foundation. If the Program does not specify a version number of
|
||||||
|
this License, you may choose any version ever published by the Free Software
|
||||||
|
Foundation.
|
||||||
|
|
||||||
|
10. If you wish to incorporate parts of the Program into other free
|
||||||
|
programs whose distribution conditions are different, write to the author
|
||||||
|
to ask for permission. For software which is copyrighted by the Free
|
||||||
|
Software Foundation, write to the Free Software Foundation; we sometimes
|
||||||
|
make exceptions for this. Our decision will be guided by the two goals
|
||||||
|
of preserving the free status of all derivatives of our free software and
|
||||||
|
of promoting the sharing and reuse of software generally.
|
||||||
|
|
||||||
|
NO WARRANTY
|
||||||
|
|
||||||
|
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
|
||||||
|
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
|
||||||
|
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
|
||||||
|
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
|
||||||
|
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||||
|
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
|
||||||
|
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
|
||||||
|
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
|
||||||
|
REPAIR OR CORRECTION.
|
||||||
|
|
||||||
|
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||||
|
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
|
||||||
|
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
|
||||||
|
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
|
||||||
|
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
|
||||||
|
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
|
||||||
|
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
|
||||||
|
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
|
||||||
|
POSSIBILITY OF SUCH DAMAGES.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
How to Apply These Terms to Your New Programs
|
||||||
|
|
||||||
|
If you develop a new program, and you want it to be of the greatest
|
||||||
|
possible use to the public, the best way to achieve this is to make it
|
||||||
|
free software which everyone can redistribute and change under these terms.
|
||||||
|
|
||||||
|
To do so, attach the following notices to the program. It is safest
|
||||||
|
to attach them to the start of each source file to most effectively
|
||||||
|
convey the exclusion of warranty; and each file should have at least
|
||||||
|
the "copyright" line and a pointer to where the full notice is found.
|
||||||
|
|
||||||
|
<one line to give the program's name and a brief idea of what it does.>
|
||||||
|
Copyright (C) <year> <name of author>
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation; either version 2 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along
|
||||||
|
with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
|
||||||
|
Also add information on how to contact you by electronic and paper mail.
|
||||||
|
|
||||||
|
If the program is interactive, make it output a short notice like this
|
||||||
|
when it starts in an interactive mode:
|
||||||
|
|
||||||
|
Gnomovision version 69, Copyright (C) year name of author
|
||||||
|
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||||
|
This is free software, and you are welcome to redistribute it
|
||||||
|
under certain conditions; type `show c' for details.
|
||||||
|
|
||||||
|
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||||
|
parts of the General Public License. Of course, the commands you use may
|
||||||
|
be called something other than `show w' and `show c'; they could even be
|
||||||
|
mouse-clicks or menu items--whatever suits your program.
|
||||||
|
|
||||||
|
You should also get your employer (if you work as a programmer) or your
|
||||||
|
school, if any, to sign a "copyright disclaimer" for the program, if
|
||||||
|
necessary. Here is a sample; alter the names:
|
||||||
|
|
||||||
|
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
|
||||||
|
`Gnomovision' (which makes passes at compilers) written by James Hacker.
|
||||||
|
|
||||||
|
<signature of Ty Coon>, 1 April 1989
|
||||||
|
Ty Coon, President of Vice
|
||||||
|
|
||||||
|
This General Public License does not permit incorporating your program into
|
||||||
|
proprietary programs. If your program is a subroutine library, you may
|
||||||
|
consider it more useful to permit linking proprietary applications with the
|
||||||
|
library. If this is what you want to do, use the GNU Lesser General
|
||||||
|
Public License instead of this License.
|
|
@ -0,0 +1,34 @@
|
||||||
|
|
||||||
|
.inside .sec {
|
||||||
|
display: block;
|
||||||
|
font-size: 15px;
|
||||||
|
font-weight: normal;
|
||||||
|
margin: 15px 0;
|
||||||
|
}
|
||||||
|
.sec label {
|
||||||
|
font-size: 16px;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
.mep_status .active {
|
||||||
|
background: green none repeat scroll 0 0;
|
||||||
|
color: #fff;
|
||||||
|
padding: 6px 10px;
|
||||||
|
}
|
||||||
|
.mep_status .err {
|
||||||
|
background: red none repeat scroll 0 0;
|
||||||
|
color: #fff;
|
||||||
|
padding: 6px 10px;
|
||||||
|
}
|
||||||
|
#mep_uid {
|
||||||
|
width: 65px;
|
||||||
|
}
|
||||||
|
.inside .sec input {
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
padding: 5px;
|
||||||
|
width: 100%;
|
||||||
|
color: #000;
|
||||||
|
}
|
||||||
|
.inside .sec label {
|
||||||
|
font-weight: normal;
|
||||||
|
display: block;
|
||||||
|
}
|
|
@ -0,0 +1,30 @@
|
||||||
|
.ui-timepicker-div .ui-widget-header { margin-bottom: 8px; }
|
||||||
|
.ui-timepicker-div dl { text-align: left; }
|
||||||
|
.ui-timepicker-div dl dt { float: left; clear:left; padding: 0 0 0 5px; }
|
||||||
|
.ui-timepicker-div dl dd { margin: 0 10px 10px 40%; }
|
||||||
|
.ui-timepicker-div td { font-size: 90%; }
|
||||||
|
.ui-tpicker-grid-label { background: none; border: none; margin: 0; padding: 0; }
|
||||||
|
.ui-timepicker-div .ui_tpicker_unit_hide{ display: none; }
|
||||||
|
|
||||||
|
.ui-timepicker-div .ui_tpicker_time .ui_tpicker_time_input { background: none; color: inherit; border: none; outline: none; border-bottom: solid 1px #555; width: 95%; }
|
||||||
|
.ui-timepicker-div .ui_tpicker_time .ui_tpicker_time_input:focus { border-bottom-color: #aaa; }
|
||||||
|
|
||||||
|
.ui-timepicker-rtl{ direction: rtl; }
|
||||||
|
.ui-timepicker-rtl dl { text-align: right; padding: 0 5px 0 0; }
|
||||||
|
.ui-timepicker-rtl dl dt{ float: right; clear: right; }
|
||||||
|
.ui-timepicker-rtl dl dd { margin: 0 40% 10px 10px; }
|
||||||
|
|
||||||
|
/* Shortened version style */
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine { padding-right: 2px; }
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine .ui_tpicker_time,
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dt { display: none; }
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine .ui_tpicker_time_label { display: block; padding-top: 2px; }
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dl { text-align: right; }
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dl dd,
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dl dd > div { display:inline-block; margin:0; }
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dl dd.ui_tpicker_minute:before,
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dl dd.ui_tpicker_second:before { content:':'; display:inline-block; }
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dl dd.ui_tpicker_millisec:before,
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine dl dd.ui_tpicker_microsec:before { content:'.'; display:inline-block; }
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine .ui_tpicker_unit_hide,
|
||||||
|
.ui-timepicker-div.ui-timepicker-oneLine .ui_tpicker_unit_hide:before{ display: none; }
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,182 @@
|
||||||
|
.ac-container{
|
||||||
|
display: block;
|
||||||
|
height: auto;
|
||||||
|
margin: 0 auto;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
.ac-container label{
|
||||||
|
border: 1px solid #ccc;
|
||||||
|
color: #777;
|
||||||
|
cursor: pointer;
|
||||||
|
display: block;
|
||||||
|
font-size: 18px;
|
||||||
|
height: auto;
|
||||||
|
line-height: 33px;
|
||||||
|
padding: 0 10px;
|
||||||
|
position: relative;
|
||||||
|
z-index: 20;
|
||||||
|
}
|
||||||
|
.ac-container label:hover{
|
||||||
|
background: #fff;
|
||||||
|
}
|
||||||
|
.ac-container input:checked + label,
|
||||||
|
.ac-container input:checked + label:hover{
|
||||||
|
background: #c6e1ec;
|
||||||
|
color: #3d7489;
|
||||||
|
text-shadow: 0px 1px 1px rgba(255,255,255, 0.6);
|
||||||
|
box-shadow:
|
||||||
|
0px 0px 0px 1px rgba(155,155,155,0.3),
|
||||||
|
0px 2px 2px rgba(0,0,0,0.1);
|
||||||
|
}
|
||||||
|
.ac-container label::after, .ac-container input:checked + label::after {
|
||||||
|
background: transparent url("../images/arrow_down.png") no-repeat scroll center center;
|
||||||
|
content: "";
|
||||||
|
height: 24px;
|
||||||
|
position: absolute;
|
||||||
|
right: 13px;
|
||||||
|
top: 7px;
|
||||||
|
width: 24px;
|
||||||
|
}
|
||||||
|
.ac-container input:checked + label:hover:after{
|
||||||
|
background-image: url(../images/arrow_up.png);
|
||||||
|
}
|
||||||
|
.ac-container input{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
.ac-container article{
|
||||||
|
background: rgba(255, 255, 255, 0.5);
|
||||||
|
margin-top: -1px;
|
||||||
|
overflow: hidden;
|
||||||
|
height: 0px;
|
||||||
|
position: relative;
|
||||||
|
z-index: 10;
|
||||||
|
transition:
|
||||||
|
height 0.3s ease-in-out,
|
||||||
|
box-shadow 0.6s linear;
|
||||||
|
}
|
||||||
|
.ac-container input:checked ~ article{
|
||||||
|
transition:
|
||||||
|
min-height 0.5s ease-in-out,
|
||||||
|
box-shadow 0.1s linear;
|
||||||
|
|
||||||
|
}
|
||||||
|
.ac-container article p{
|
||||||
|
color: #333;
|
||||||
|
font-size: 14px;
|
||||||
|
font-style: normal;
|
||||||
|
line-height: 23px;
|
||||||
|
padding: 10px;
|
||||||
|
text-shadow: none;
|
||||||
|
}
|
||||||
|
.ac-container input:checked ~ article.ac-small{
|
||||||
|
height: auto;
|
||||||
|
min-height: 140px;
|
||||||
|
border: 1px solid #ccc;
|
||||||
|
}
|
||||||
|
.ac-container input:checked ~ article.ac-medium{
|
||||||
|
min-height: 180px;
|
||||||
|
height: auto;
|
||||||
|
border: 1px solid #ccc;
|
||||||
|
}
|
||||||
|
.ac-container input:checked ~ article.ac-large{
|
||||||
|
min-height: 230px;
|
||||||
|
height: auto;
|
||||||
|
border: 1px solid #ccc;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mkb-select-list {
|
||||||
|
border-bottom: 1px solid #ddd;
|
||||||
|
display: block;
|
||||||
|
margin: 10px auto;
|
||||||
|
}
|
||||||
|
.mkb-select-list select {
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
padding: 5px;
|
||||||
|
}
|
||||||
|
.btn.mkb-btn {
|
||||||
|
border-radius: 0;
|
||||||
|
display: inline-block;
|
||||||
|
margin: -5px 0 4px -6px;
|
||||||
|
padding: 9px;
|
||||||
|
}
|
||||||
|
.mkb-leftbar-content {
|
||||||
|
display: block;
|
||||||
|
margin: 0 auto;
|
||||||
|
overflow: hidden;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
.mkb-leftbar {
|
||||||
|
float: left;
|
||||||
|
padding: 0 5px;
|
||||||
|
width: 25%;
|
||||||
|
}
|
||||||
|
.mkb-lf-content {
|
||||||
|
float: left;
|
||||||
|
width: 75%;
|
||||||
|
}
|
||||||
|
.mkb-leftbar ul {
|
||||||
|
list-style: outside none none;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
.mkb-leftbar li a {
|
||||||
|
border-bottom: 1px dashed #ddd;
|
||||||
|
box-shadow: none;
|
||||||
|
color: #333;
|
||||||
|
display: block;
|
||||||
|
font-size: 15px;
|
||||||
|
padding: 2px 0;
|
||||||
|
}
|
||||||
|
.mkb-leftbar li {
|
||||||
|
border: 0 none;
|
||||||
|
}
|
||||||
|
.mkb-content h3 {
|
||||||
|
border-radius: 0;
|
||||||
|
}
|
||||||
|
.mkb-content div {
|
||||||
|
margin: 0;
|
||||||
|
padding: 10px!important;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
.ui-accordion .ui-accordion-content {
|
||||||
|
border-radius: 0;
|
||||||
|
}
|
||||||
|
.ui-icon {
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
display: inline-block;
|
||||||
|
margin-top: -0.25em;
|
||||||
|
overflow: hidden;
|
||||||
|
position: relative;
|
||||||
|
text-indent: 0;
|
||||||
|
vertical-align: middle;
|
||||||
|
background: none!important;
|
||||||
|
}
|
||||||
|
.ui-accordion-header-icon.ui-icon.fa.fa-arrow-circle-right, .ui-accordion-header-icon.ui-icon.fa.fa-arrow-circle-left {
|
||||||
|
height: 20px;
|
||||||
|
margin-left: 0;
|
||||||
|
margin-top: 0;
|
||||||
|
width: 16px;
|
||||||
|
}
|
||||||
|
.ui-accordion-header-icon.ui-icon.fa.fa-arrow-circle-down {
|
||||||
|
height: 20px;
|
||||||
|
margin-left: 0;
|
||||||
|
margin-top: 0;
|
||||||
|
width: 16px;
|
||||||
|
}
|
||||||
|
.ui-accordion .ui-accordion-content {
|
||||||
|
padding: 10px 5px;
|
||||||
|
}
|
||||||
|
.mkb-group-title {
|
||||||
|
border-bottom: 1px solid #ddd;
|
||||||
|
margin: 10px 0 !important;
|
||||||
|
padding: 7px 0;
|
||||||
|
text-transform: capitalize !important;
|
||||||
|
}
|
||||||
|
.mkb-group-items {
|
||||||
|
display: block;
|
||||||
|
overflow: hidden;
|
||||||
|
margin: 50px 0;
|
||||||
|
}
|
||||||
|
.mkb-content h3, .mkb-contents h3 {
|
||||||
|
font-weight: normal !important;
|
||||||
|
}
|
|
@ -0,0 +1,263 @@
|
||||||
|
.maparea {
|
||||||
|
height: 50vh;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mep-events-wrapper {
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
padding: 0px;
|
||||||
|
}
|
||||||
|
.mep-events-header {
|
||||||
|
border-bottom: 1px solid #ddd;
|
||||||
|
text-align: center;
|
||||||
|
padding:0;
|
||||||
|
}
|
||||||
|
.col-2 {
|
||||||
|
width: 50%;
|
||||||
|
float: left;
|
||||||
|
padding: 20px 0;
|
||||||
|
}
|
||||||
|
.mep-event-date-time {
|
||||||
|
overflow: hidden;
|
||||||
|
display: block;
|
||||||
|
border-bottom: 1px solid #ddd;
|
||||||
|
}
|
||||||
|
.mep-events-details {
|
||||||
|
padding: 20px 0;
|
||||||
|
}
|
||||||
|
.mep-event-location-price {
|
||||||
|
overflow: hidden;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
.btn-mep-event-cart {
|
||||||
|
background: #007acc;
|
||||||
|
display: block;
|
||||||
|
color: #fff !important;
|
||||||
|
padding: 15px 30px;
|
||||||
|
text-decoration: navajowhite;
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: bold;
|
||||||
|
text-transform: uppercase;
|
||||||
|
}
|
||||||
|
.cart-btn-sec {
|
||||||
|
text-align: center;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.mep-top-part, .mep-btn-part, .mep-content-part {
|
||||||
|
overflow: hidden;
|
||||||
|
float: none;
|
||||||
|
border-bottom: 1px solid #ddd;
|
||||||
|
}
|
||||||
|
.mep-left-col {
|
||||||
|
width: 65%;
|
||||||
|
float: left;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.mep-right-col {
|
||||||
|
width: 35%;
|
||||||
|
float: left;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.mep-event-thumbnail {
|
||||||
|
height: 280px;
|
||||||
|
}
|
||||||
|
.mep-event-title-header {
|
||||||
|
overflow: hidden;
|
||||||
|
height: auto;
|
||||||
|
padding: 20px;
|
||||||
|
margin-top: 0px;
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
.mep-event-title-header h2 {
|
||||||
|
font-size: 25px;
|
||||||
|
line-height: 30px;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
.mep-btn-part {
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
.mep-event-meta {
|
||||||
|
font-size: 18px;
|
||||||
|
padding-top: 0px;
|
||||||
|
}
|
||||||
|
.mep-event-details {
|
||||||
|
padding: 20px;
|
||||||
|
}
|
||||||
|
.mep-desc-title {
|
||||||
|
font-size: 20px;
|
||||||
|
display: block;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
.mep-event-details p {
|
||||||
|
font-size: 16px;
|
||||||
|
line-height: 27px;
|
||||||
|
}
|
||||||
|
.mep-event-datetime, .mep-event-location {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
.mep-event-datetime h3, .mep-event-location h3 {
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 20px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
.mep-event-datetime p, .mep-event-location p {
|
||||||
|
font-size: 15px;
|
||||||
|
line-height: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mep-event-datetime p{
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
.mep-reg-btn-sec {
|
||||||
|
margin: 10px 0;
|
||||||
|
padding: 0 10px 0 0;
|
||||||
|
}
|
||||||
|
.mep-event-title-header p a {
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
.mep-social-share {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
list-style: none;
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
.mep-social-share li {
|
||||||
|
display: inline-block;
|
||||||
|
padding: 10px 0;
|
||||||
|
}
|
||||||
|
.mep-social-share li a {
|
||||||
|
border: 1px solid;
|
||||||
|
color: #000;
|
||||||
|
border-radius: 0;
|
||||||
|
padding: 0;
|
||||||
|
height: 30px;
|
||||||
|
display: block;
|
||||||
|
vertical-align: middle;
|
||||||
|
width: 40px;
|
||||||
|
text-align: center;
|
||||||
|
margin: 0 2px;
|
||||||
|
font-size: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mep_event_list {
|
||||||
|
display: block;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.mep_event_list_item {
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
padding: 5px;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.mep_list_thumb {
|
||||||
|
width: 30%;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
.mep_list_event_details {
|
||||||
|
width: 67%;
|
||||||
|
float: left;
|
||||||
|
overflow: hidden;
|
||||||
|
padding-left: 20px;
|
||||||
|
padding-top: 5px;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
.mep_list_title {
|
||||||
|
font-size: 20px;
|
||||||
|
font-weight: bold;
|
||||||
|
display: block;
|
||||||
|
margin-bottom: 8px!important;
|
||||||
|
}
|
||||||
|
.mep_list_date {
|
||||||
|
font-size: 16px;
|
||||||
|
font-style: italic;
|
||||||
|
display: block;
|
||||||
|
margin: 0 0 10px 0!important;
|
||||||
|
}
|
||||||
|
.mep_list_event_details p {
|
||||||
|
font-size: 17px;
|
||||||
|
line-height: 25px;
|
||||||
|
}
|
||||||
|
.mep_event_list .list-details-btn {
|
||||||
|
background: #0066cc;
|
||||||
|
color: #fff;
|
||||||
|
padding: 5px 10px;
|
||||||
|
position: absolute;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
text-decoration: none;
|
||||||
|
text-transform: uppercase;
|
||||||
|
font-size: 15px;
|
||||||
|
}
|
||||||
|
.mep_list_event_details a {
|
||||||
|
color: #000;
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mep_cat-details {
|
||||||
|
display: block;
|
||||||
|
overflow: hidden;
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 10px!important;
|
||||||
|
}
|
||||||
|
.mep_cat-details h1 {
|
||||||
|
margin-bottom: 14px!important;
|
||||||
|
font-size: 25px;
|
||||||
|
}
|
||||||
|
.mep_cat-details p {
|
||||||
|
font-size: 15px;
|
||||||
|
line-height: 24px;
|
||||||
|
}
|
||||||
|
.event-expire-btn {
|
||||||
|
display: block;
|
||||||
|
background: red;
|
||||||
|
color: #fff;
|
||||||
|
padding: 16px;
|
||||||
|
font-size: 17px;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
.mep_google_map{
|
||||||
|
width: 100%;
|
||||||
|
min-height: 250px;
|
||||||
|
}
|
||||||
|
.mep-event-title-header h5 {
|
||||||
|
margin: 10px 0;
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
.event_addt_price {
|
||||||
|
display: block;
|
||||||
|
font-size: 17px;
|
||||||
|
margin: 10px 0;
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
#usertotal {
|
||||||
|
display: block;
|
||||||
|
text-align: left;
|
||||||
|
font-size: 17px;
|
||||||
|
margin: 10px 0;
|
||||||
|
}
|
||||||
|
.eventtotal {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
.cart-btn-sec .event_addt_price input {
|
||||||
|
margin-right: 10px;
|
||||||
|
}
|
||||||
|
.mep-event-title-header h3 {
|
||||||
|
font-size: 18px;
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
.mep-event-datetime h3 {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0 0 5px 0;
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
.mep-event-datetime {
|
||||||
|
padding-left: 5px;
|
||||||
|
}
|
||||||
|
.mep-event-location h3 {
|
||||||
|
padding: 0;
|
||||||
|
margin: 20px 0 5px 0;
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
After Width: | Height: | Size: 1.0 KiB |
|
@ -0,0 +1,62 @@
|
||||||
|
<?php
|
||||||
|
if ( ! defined( 'ABSPATH' ) ) { die; } // Cannot access pages directly.
|
||||||
|
// Create MKB CPT
|
||||||
|
function mep_cpt() {
|
||||||
|
|
||||||
|
|
||||||
|
$labels = array(
|
||||||
|
'name' => _x( 'Events', 'mep' ),
|
||||||
|
'singular_name' => _x( 'Events', 'mep' ),
|
||||||
|
'menu_name' => __( 'Events', 'mep' ),
|
||||||
|
'name_admin_bar' => __( 'Events', 'mep' ),
|
||||||
|
'archives' => __( 'Events List', 'mep' ),
|
||||||
|
'attributes' => __( 'Events List', 'mep' ),
|
||||||
|
'parent_item_colon' => __( 'Event Item:', 'mep' ),
|
||||||
|
'all_items' => __( 'All Events', 'mep' ),
|
||||||
|
'add_new_item' => __( 'Add New Event', 'mep' ),
|
||||||
|
'add_new' => __( 'Add New Event', 'mep' ),
|
||||||
|
'new_item' => __( 'New Event', 'mep' ),
|
||||||
|
'edit_item' => __( 'Edit Event', 'mep' ),
|
||||||
|
'update_item' => __( 'Update Event', 'mep' ),
|
||||||
|
'view_item' => __( 'View Event', 'mep' ),
|
||||||
|
'view_items' => __( 'View Event', 'mep' ),
|
||||||
|
'search_items' => __( 'Search Event', 'mep' ),
|
||||||
|
'not_found' => __( 'Event Not found', 'mep' ),
|
||||||
|
'not_found_in_trash' => __( 'Event Not found in Trash', 'mep' ),
|
||||||
|
'featured_image' => __( 'Event Feature Image', 'mep' ),
|
||||||
|
'set_featured_image' => __( 'Set Event featured image', 'mep' ),
|
||||||
|
'remove_featured_image' => __( 'Remove Event featured image', 'mep' ),
|
||||||
|
'use_featured_image' => __( 'Use as Event featured image', 'mep' ),
|
||||||
|
'insert_into_item' => __( 'Insert into Event', 'mep' ),
|
||||||
|
'uploaded_to_this_item' => __( 'Uploaded to this Event', 'mep' ),
|
||||||
|
'items_list' => __( 'Event list', 'mep' ),
|
||||||
|
'items_list_navigation' => __( 'Event list navigation', 'mep' ),
|
||||||
|
'filter_items_list' => __( 'Filter Event list', 'mep' ),
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$args = array(
|
||||||
|
'public' => true,
|
||||||
|
'labels' => $labels,
|
||||||
|
'menu_icon' => 'dashicons-calendar-alt',
|
||||||
|
'supports' => array('title','editor','thumbnail'),
|
||||||
|
'rewrite' => array('slug' => 'events')
|
||||||
|
|
||||||
|
);
|
||||||
|
register_post_type( 'mep_events', $args );
|
||||||
|
|
||||||
|
|
||||||
|
$argsl = array(
|
||||||
|
'public' => true,
|
||||||
|
'label' => 'Event Attendees',
|
||||||
|
'menu_icon' => 'dashicons-id',
|
||||||
|
'supports' => array('title'),
|
||||||
|
'show_in_menu' => 'edit.php?post_type=mep_events'
|
||||||
|
|
||||||
|
);
|
||||||
|
register_post_type( 'mep_events_attendees', $argsl );
|
||||||
|
|
||||||
|
}
|
||||||
|
add_action( 'init', 'mep_cpt' );
|
|
@ -0,0 +1,226 @@
|
||||||
|
<?php
|
||||||
|
if ( ! defined( 'ABSPATH' ) ) { die; } // Cannot access pages directly.
|
||||||
|
add_action( 'add_meta_boxes', 'mep_event_meta_box_add' );
|
||||||
|
function mep_event_meta_box_add(){
|
||||||
|
add_meta_box( 'mep-event-meta', 'Event Venue', 'mep_event_venue_meta_box_cb', 'mep_events', 'normal', 'high' );
|
||||||
|
|
||||||
|
add_meta_box( 'mep-event-price', 'Event Price', 'mep_event_price_meta_box_cb', 'mep_events', 'normal', 'high' );
|
||||||
|
|
||||||
|
add_meta_box( 'mep-event-date', 'Event Date & Time', 'mep_event_date_meta_box_cb', 'mep_events', 'normal', 'high' );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function mep_event_venue_meta_box_cb($post){
|
||||||
|
$values = get_post_custom( $post->ID );
|
||||||
|
?>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_1"> Seat Capacity: </label>
|
||||||
|
<span><input id='mep_ev_1' type="number" name='mep_total_seat' value='<?php echo $values['mep_total_seat'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_2"> Location/Venue: </label>
|
||||||
|
<span><input id='mep_ev_2' type="text" name='mep_location_venue' value='<?php echo $values['mep_location_venue'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_3"> Street: </label>
|
||||||
|
<span><input id='mep_ev_3' type="text" name='mep_street' value='<?php echo $values['mep_street'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_4"> City: </label>
|
||||||
|
<span><input id='mep_ev_4' type="text" name='mep_city' value='<?php echo $values['mep_city'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_5"> State: </label>
|
||||||
|
<span><input id='mep_ev_5' type="text" name='mep_state' value='<?php echo $values['mep_state'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_6"> Postcode: </label>
|
||||||
|
<span><input id='mep_ev_6' type="text" name='mep_postcode' value='<?php echo $values['mep_postcode'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_7"> Country: </label>
|
||||||
|
<span><input id='mep_ev_7' type="text" name='mep_country' value='<?php echo $values['mep_country'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function mep_event_price_meta_box_cb($post){
|
||||||
|
$values = get_post_custom( $post->ID );
|
||||||
|
?>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_8"> Price Label: </label>
|
||||||
|
<span><input id='mep_ev_8' type="text" name='mep_price_label' value='<?php echo $values['mep_price_label'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="mep_ev_9"> Price: </label>
|
||||||
|
<span><input id='mep_ev_9' type="number" name='_price' value='<?php echo $values['_price'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function mep_event_date_meta_box_cb($post){
|
||||||
|
$values = get_post_custom( $post->ID );
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="event_start_date"> Start Date & Time: </label>
|
||||||
|
<span><input class='event_start' id='event_start_date' type="text" name='mep_event_start_date' value='<?php echo $values['mep_event_start_date'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="event_end_date"> End Date & Time: </label>
|
||||||
|
<span><input class='event_end' id='event_end_date' type="text" name='mep_event_end_date' value='<?php echo $values['mep_event_end_date'][0]; ?>'> </span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
add_action('save_post','mep_events_meta_save');
|
||||||
|
function mep_events_meta_save($post_id){
|
||||||
|
global $post;
|
||||||
|
$pid = $post->ID;
|
||||||
|
if ($post->post_type != 'mep_events'){
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//if you get here then it's your post type so do your thing....
|
||||||
|
$seat = strip_tags($_POST['mep_total_seat']);
|
||||||
|
$mep_location_venue = strip_tags($_POST['mep_location_venue']);
|
||||||
|
$mep_street = strip_tags($_POST['mep_street']);
|
||||||
|
$mep_city = strip_tags($_POST['mep_city']);
|
||||||
|
$mep_state = strip_tags($_POST['mep_state']);
|
||||||
|
$mep_postcode = strip_tags($_POST['mep_postcode']);
|
||||||
|
$mep_country = strip_tags($_POST['mep_country']);
|
||||||
|
$mep_price_label = strip_tags($_POST['mep_price_label']);
|
||||||
|
$_price = strip_tags($_POST['_price']);
|
||||||
|
$mep_event_start_date = strip_tags($_POST['mep_event_start_date']);
|
||||||
|
$mep_event_end_date = strip_tags($_POST['mep_event_end_date']);
|
||||||
|
|
||||||
|
|
||||||
|
$update_seat = update_post_meta( $pid, 'mep_total_seat', $seat);
|
||||||
|
$update_location = update_post_meta( $pid, 'mep_location_venue', $mep_location_venue);
|
||||||
|
$update_mep_street = update_post_meta( $pid, 'mep_street', $mep_street);
|
||||||
|
$update_city = update_post_meta( $pid, 'mep_city', $mep_city);
|
||||||
|
$update_mep_state = update_post_meta( $pid, 'mep_state', $mep_state);
|
||||||
|
$update_postcode = update_post_meta( $pid, 'mep_postcode', $mep_postcode);
|
||||||
|
$update_conuntry = update_post_meta( $pid, 'mep_country', $mep_country);
|
||||||
|
$update_price_label = update_post_meta( $pid, 'mep_price_label', $mep_price_label);
|
||||||
|
$update_price = update_post_meta( $pid, '_price', $_price);
|
||||||
|
$update_start = update_post_meta( $pid, 'mep_event_start_date', $mep_event_start_date);
|
||||||
|
$update_end = update_post_meta( $pid, 'mep_event_end_date', $mep_event_end_date);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
add_action( 'add_meta_boxes', 'mep_meta_box_add' );
|
||||||
|
function mep_meta_box_add(){
|
||||||
|
add_meta_box( 'my-meta-box-id', 'Information', 'mep_meta_box_cb', 'mep_events_attendees', 'normal', 'high' );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function mep_meta_box_cb($post){
|
||||||
|
$values = get_post_custom( $post->ID );
|
||||||
|
?>
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text"> Event: </label>
|
||||||
|
<span><?php echo $values['ea_event_name'][0]; ?> </span>
|
||||||
|
</div>
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text"> Full Name: </label>
|
||||||
|
<span><?php echo $values['ea_first_name'][0]; ?> <?php echo $values['ea_last_name'][0]; ?></span>
|
||||||
|
</div>
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">Company: </label>
|
||||||
|
<span><?php echo $values['ea_company_name'][0]; ?></span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">Email: </label>
|
||||||
|
<span><?php echo $values['ea_email'][0]; ?></span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">Phone: </label>
|
||||||
|
<span><?php echo $values['ea_phone'][0]; ?></span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">Addres: </label>
|
||||||
|
<span>
|
||||||
|
<?php echo $values['ea_address_1'][0]; ?>
|
||||||
|
<?php echo $values['ea_address_2'][0]; ?>
|
||||||
|
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">State: </label>
|
||||||
|
<span>
|
||||||
|
<?php echo $values['ea_state'][0]; ?>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">City: </label>
|
||||||
|
<span>
|
||||||
|
<?php echo $values['ea_city'][0]; ?>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">Country: </label>
|
||||||
|
<span>
|
||||||
|
<?php echo $values['ea_country'][0]; ?>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class='sec'>
|
||||||
|
<label for="my_meta_box_text">Order ID: </label>
|
||||||
|
<span>
|
||||||
|
<?php echo $values['ea_order_id'][0]; ?>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<div class='sec'>
|
||||||
|
<span>
|
||||||
|
<a href="<?php echo get_site_url(); ?>/wp-admin/post.php?post=<?php echo $values['ea_order_id'][0]; ?>&action=edit" class='button button-primary button-large'>View Order</a>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
}
|
|
@ -0,0 +1,70 @@
|
||||||
|
<?php
|
||||||
|
if ( ! defined( 'ABSPATH' ) ) { die; } // Cannot access pages directly.
|
||||||
|
add_shortcode( 'event-list', 'mep_event_list' );
|
||||||
|
function mep_event_list($atts, $content=null){
|
||||||
|
$defaults = array(
|
||||||
|
"cat" => "0",
|
||||||
|
);
|
||||||
|
|
||||||
|
$params = shortcode_atts($defaults, $atts);
|
||||||
|
$cat = $params['cat'];
|
||||||
|
ob_start();
|
||||||
|
?>
|
||||||
|
<div class='mep_event_list'>
|
||||||
|
<div class="mep_cat-details">
|
||||||
|
<h1><?php echo get_queried_object()->name; ?></h1>
|
||||||
|
<p><?php echo get_queried_object()->description; ?></p>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
if($cat>0){
|
||||||
|
$args_search_qqq = array (
|
||||||
|
'post_type' => array( 'mep_events' ),
|
||||||
|
'posts_per_page' => -1,
|
||||||
|
'tax_query' => array(
|
||||||
|
array(
|
||||||
|
'taxonomy' => 'mep_cat',
|
||||||
|
'field' => 'term_id',
|
||||||
|
'terms' => $cat
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
);
|
||||||
|
}else{
|
||||||
|
$args_search_qqq = array (
|
||||||
|
'post_type' => array( 'mep_events' ),
|
||||||
|
'posts_per_page' => -1
|
||||||
|
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
$loop = new WP_Query( $args_search_qqq );
|
||||||
|
while ($loop->have_posts()) {
|
||||||
|
$loop->the_post();
|
||||||
|
$event_meta = get_post_custom(get_the_id());
|
||||||
|
|
||||||
|
$time = strtotime($event_meta['mep_event_start_date'][0]);
|
||||||
|
$newformat = date('Y-m-d H:i:s',$time);
|
||||||
|
|
||||||
|
|
||||||
|
if(time() < strtotime($newformat)){
|
||||||
|
?>
|
||||||
|
<div class='mep_event_list_item'>
|
||||||
|
<div class="mep_list_thumb"><?php the_post_thumbnail('medium'); ?></div>
|
||||||
|
<div class="mep_list_event_details"><a href="<?php the_permalink(); ?>">
|
||||||
|
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||||
|
<h3 class='mep_list_date'>on <?php echo $event_meta['mep_event_start_date'][0]; ?> - <?php echo $event_meta['mep_event_end_date'][0]; ?></h3>
|
||||||
|
|
||||||
|
<p><?php echo $event_meta['mep_location_venue'][0]; ?>,<?php echo $event_meta['mep_street'][0]; ?>, <?php echo $event_meta['mep_city'][0]; ?>,<?php echo $event_meta['mep_state'][0]; ?>,<?php echo $event_meta['mep_postcode'][0]; ?>,<?php echo $event_meta['mep_country'][0]; ?></p>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$content = ob_get_clean();
|
||||||
|
return $content;
|
||||||
|
}
|
|
@ -0,0 +1,80 @@
|
||||||
|
<?php
|
||||||
|
if ( ! defined( 'ABSPATH' ) ) { die; } // Cannot access pages directly.
|
||||||
|
function mep_cpt_tax(){
|
||||||
|
|
||||||
|
|
||||||
|
$labels = array(
|
||||||
|
'name' => _x( 'Event Category','mep' ),
|
||||||
|
'singular_name' => _x( 'Event Category','mep' ),
|
||||||
|
'menu_name' => __( 'Category', 'mep' ),
|
||||||
|
'all_items' => __( 'All Event Category', 'mep' ),
|
||||||
|
'parent_item' => __( 'Parent Category', 'mep' ),
|
||||||
|
'parent_item_colon' => __( 'Parent Category:', 'mep' ),
|
||||||
|
'new_item_name' => __( 'New Category Name', 'mep' ),
|
||||||
|
'add_new_item' => __( 'Add New Category', 'mep' ),
|
||||||
|
'edit_item' => __( 'Edit Category', 'mep' ),
|
||||||
|
'update_item' => __( 'Update Category', 'mep' ),
|
||||||
|
'view_item' => __( 'View Category', 'mep' ),
|
||||||
|
'separate_items_with_commas' => __( 'Separate Category with commas', 'mep' ),
|
||||||
|
'add_or_remove_items' => __( 'Add or remove Category', 'mep' ),
|
||||||
|
'choose_from_most_used' => __( 'Choose from the most used', 'mep' ),
|
||||||
|
'popular_items' => __( 'Popular Category', 'mep' ),
|
||||||
|
'search_items' => __( 'Search Category', 'mep' ),
|
||||||
|
'not_found' => __( 'Not Found', 'mep' ),
|
||||||
|
'no_terms' => __( 'No Category', 'mep' ),
|
||||||
|
'items_list' => __( 'Category list', 'mep' ),
|
||||||
|
'items_list_navigation' => __( 'Category list navigation', 'mep' ),
|
||||||
|
);
|
||||||
|
|
||||||
|
$args = array(
|
||||||
|
'hierarchical' => true,
|
||||||
|
"public" => true,
|
||||||
|
'labels' => $labels,
|
||||||
|
'show_ui' => true,
|
||||||
|
'show_admin_column' => true,
|
||||||
|
'update_count_callback' => '_update_post_term_count',
|
||||||
|
'query_var' => true,
|
||||||
|
'rewrite' => array( 'slug' => 'event-category' ),
|
||||||
|
);
|
||||||
|
register_taxonomy('mep_cat', 'mep_events', $args);
|
||||||
|
|
||||||
|
|
||||||
|
$labelso = array(
|
||||||
|
'name' => _x( 'Event Organizer','mep' ),
|
||||||
|
'singular_name' => _x( 'Event Organizer','mep' ),
|
||||||
|
'menu_name' => __( 'Organizer', 'mep' ),
|
||||||
|
'all_items' => __( 'All Event Organizer', 'mep' ),
|
||||||
|
'parent_item' => __( 'Parent Organizer', 'mep' ),
|
||||||
|
'parent_item_colon' => __( 'Parent Organizer:', 'mep' ),
|
||||||
|
'new_item_name' => __( 'New Organizer Name', 'mep' ),
|
||||||
|
'add_new_item' => __( 'Add New Organizer', 'mep' ),
|
||||||
|
'edit_item' => __( 'Edit Organizer', 'mep' ),
|
||||||
|
'update_item' => __( 'Update Organizer', 'mep' ),
|
||||||
|
'view_item' => __( 'View Organizer', 'mep' ),
|
||||||
|
'separate_items_with_commas' => __( 'Separate Organizer with commas', 'mep' ),
|
||||||
|
'add_or_remove_items' => __( 'Add or remove Organizer', 'mep' ),
|
||||||
|
'choose_from_most_used' => __( 'Choose from the most used', 'mep' ),
|
||||||
|
'popular_items' => __( 'Popular Organizer', 'mep' ),
|
||||||
|
'search_items' => __( 'Search Organizer', 'mep' ),
|
||||||
|
'not_found' => __( 'Not Found', 'mep' ),
|
||||||
|
'no_terms' => __( 'No Organizer', 'mep' ),
|
||||||
|
'items_list' => __( 'Organizer list', 'mep' ),
|
||||||
|
'items_list_navigation' => __( 'Organizer list navigation', 'mep' ),
|
||||||
|
);
|
||||||
|
|
||||||
|
$argso = array(
|
||||||
|
'hierarchical' => true,
|
||||||
|
"public" => true,
|
||||||
|
'labels' => $labelso,
|
||||||
|
'show_ui' => true,
|
||||||
|
'show_admin_column' => true,
|
||||||
|
'update_count_callback' => '_update_post_term_count',
|
||||||
|
'query_var' => true,
|
||||||
|
'rewrite' => array( 'slug' => 'event-organizer' ),
|
||||||
|
);
|
||||||
|
register_taxonomy('mep_org', 'mep_events', $argso);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
add_action("init","mep_cpt_tax",10);
|
|
@ -0,0 +1,91 @@
|
||||||
|
/*
|
||||||
|
* jQuery UI Slider Access
|
||||||
|
* By: Trent Richardson [http://trentrichardson.com]
|
||||||
|
* Version 0.3
|
||||||
|
* Last Modified: 10/20/2012
|
||||||
|
*
|
||||||
|
* Copyright 2011 Trent Richardson
|
||||||
|
* Dual licensed under the MIT and GPL licenses.
|
||||||
|
* http://trentrichardson.com/Impromptu/GPL-LICENSE.txt
|
||||||
|
* http://trentrichardson.com/Impromptu/MIT-LICENSE.txt
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
(function($){
|
||||||
|
|
||||||
|
$.fn.extend({
|
||||||
|
sliderAccess: function(options){
|
||||||
|
options = options || {};
|
||||||
|
options.touchonly = options.touchonly !== undefined? options.touchonly : true; // by default only show it if touch device
|
||||||
|
|
||||||
|
if(options.touchonly === true && !("ontouchend" in document)){
|
||||||
|
return $(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $(this).each(function(i,obj){
|
||||||
|
var $t = $(this),
|
||||||
|
o = $.extend({},{
|
||||||
|
where: 'after',
|
||||||
|
step: $t.slider('option','step'),
|
||||||
|
upIcon: 'ui-icon-plus',
|
||||||
|
downIcon: 'ui-icon-minus',
|
||||||
|
text: false,
|
||||||
|
upText: '+',
|
||||||
|
downText: '-',
|
||||||
|
buttonset: true,
|
||||||
|
buttonsetTag: 'span',
|
||||||
|
isRTL: false
|
||||||
|
}, options),
|
||||||
|
$buttons = $('<'+ o.buttonsetTag +' class="ui-slider-access">'+
|
||||||
|
'<button data-icon="'+ o.downIcon +'" data-step="'+ (o.isRTL? o.step : o.step*-1) +'">'+ o.downText +'</button>'+
|
||||||
|
'<button data-icon="'+ o.upIcon +'" data-step="'+ (o.isRTL? o.step*-1 : o.step) +'">'+ o.upText +'</button>'+
|
||||||
|
'</'+ o.buttonsetTag +'>');
|
||||||
|
|
||||||
|
$buttons.children('button').each(function(j, jobj){
|
||||||
|
var $jt = $(this);
|
||||||
|
$jt.button({
|
||||||
|
text: o.text,
|
||||||
|
icons: { primary: $jt.data('icon') }
|
||||||
|
})
|
||||||
|
.click(function(e){
|
||||||
|
var step = $jt.data('step'),
|
||||||
|
curr = $t.slider('value'),
|
||||||
|
newval = curr += step*1,
|
||||||
|
minval = $t.slider('option','min'),
|
||||||
|
maxval = $t.slider('option','max'),
|
||||||
|
slidee = $t.slider("option", "slide") || function(){},
|
||||||
|
stope = $t.slider("option", "stop") || function(){};
|
||||||
|
|
||||||
|
e.preventDefault();
|
||||||
|
|
||||||
|
if(newval < minval || newval > maxval){
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$t.slider('value', newval);
|
||||||
|
|
||||||
|
slidee.call($t, null, { value: newval });
|
||||||
|
stope.call($t, null, { value: newval });
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
// before or after
|
||||||
|
$t[o.where]($buttons);
|
||||||
|
|
||||||
|
if(o.buttonset){
|
||||||
|
$buttons.removeClass('ui-corner-right').removeClass('ui-corner-left').buttonset();
|
||||||
|
$buttons.eq(0).addClass('ui-corner-left');
|
||||||
|
$buttons.eq(1).addClass('ui-corner-right');
|
||||||
|
}
|
||||||
|
|
||||||
|
// adjust the width so we don't break the original layout
|
||||||
|
var bOuterWidth = $buttons.css({
|
||||||
|
marginLeft: ((o.where === 'after' && !o.isRTL) || (o.where === 'before' && o.isRTL)? 10:0),
|
||||||
|
marginRight: ((o.where === 'before' && !o.isRTL) || (o.where === 'after' && o.isRTL)? 10:0)
|
||||||
|
}).outerWidth(true) + 5;
|
||||||
|
var tOuterWidth = $t.outerWidth(true);
|
||||||
|
$t.css('display','inline-block').width(tOuterWidth-bOuterWidth);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
})(jQuery);
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,50 @@
|
||||||
|
function initialize() {
|
||||||
|
var hlat = parseFloat(helper.lat)||39.0000;
|
||||||
|
var hlng = parseFloat(helper.lng)||22.0000;
|
||||||
|
|
||||||
|
var myLatLng = new google.maps.LatLng(hlat,hlng);
|
||||||
|
var mapOptions = {
|
||||||
|
center: myLatLng,
|
||||||
|
zoom: 5
|
||||||
|
};
|
||||||
|
var map = new google.maps.Map(document.getElementById('map-canvas'),
|
||||||
|
mapOptions);
|
||||||
|
var marker = new google.maps.Marker({position: myLatLng, map: map, draggable: true});
|
||||||
|
marker.setMap(map);
|
||||||
|
|
||||||
|
google.maps.event.addListener(marker, 'dragend', function(event) {
|
||||||
|
placeMarker(event.latLng);
|
||||||
|
});
|
||||||
|
|
||||||
|
// Create the search box and link it to the UI element.
|
||||||
|
var input = document.getElementById('pac-input');
|
||||||
|
var searchBox = new google.maps.places.SearchBox(input);
|
||||||
|
map.controls[google.maps.ControlPosition.TOP_LEFT].push(input);
|
||||||
|
|
||||||
|
// Bias the SearchBox results towards current map's viewport.
|
||||||
|
map.addListener('bounds_changed', function() {
|
||||||
|
searchBox.setBounds(map.getBounds());
|
||||||
|
});
|
||||||
|
|
||||||
|
function placeMarker(location) {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if (marker == undefined){
|
||||||
|
marker = new google.maps.Marker({
|
||||||
|
position: location,
|
||||||
|
map: map,
|
||||||
|
animation: google.maps.Animation.DROP
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
marker.setPosition(location);
|
||||||
|
}
|
||||||
|
map.setCenter(location);
|
||||||
|
//console.log(location.lat()+" "+location.lng()); // click debug
|
||||||
|
document.getElementById("latitude").value = location.lat();
|
||||||
|
document.getElementById("longitude").value = location.lng();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
google.maps.event.addDomListener(window, 'load', initialize);
|
|
@ -0,0 +1,11 @@
|
||||||
|
.mkb_cats {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
.mkb_cats {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
.mkb_custom_css_code .regular-text {
|
||||||
|
border: 1px solid #999;
|
||||||
|
width: 100%;
|
||||||
|
min-height: 300px;
|
||||||
|
}
|
|
@ -0,0 +1,20 @@
|
||||||
|
jQuery(document).ready( function() {
|
||||||
|
|
||||||
|
var kaka = jQuery('.regular_mkb_type').val();
|
||||||
|
if(kaka == 6){
|
||||||
|
jQuery(".mkb_cats").show();
|
||||||
|
}
|
||||||
|
|
||||||
|
jQuery('.regular_mkb_type').on('change', function() {
|
||||||
|
var thtype = this.value;
|
||||||
|
if(thtype == 6){
|
||||||
|
jQuery(".mkb_cats").show();
|
||||||
|
}else{
|
||||||
|
jQuery(".mkb_cats").hide();
|
||||||
|
jQuery(".regular_mkb_cats").val(0);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
});
|
|
@ -0,0 +1,67 @@
|
||||||
|
jQuery(document).ready( function() {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
var icons = {
|
||||||
|
header: "fa fa-angle-double-right",
|
||||||
|
activeHeader: "fa fa-angle-double-down"
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
jQuery( "#accordion" ).accordion({
|
||||||
|
collapsible: true,
|
||||||
|
icons: icons,
|
||||||
|
active: false
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Ajax Call for mkb Dropdown (Theme 1)
|
||||||
|
jQuery("#tr_go").click(function(e) {
|
||||||
|
e.preventDefault();
|
||||||
|
var trcat = jQuery("#trcat").val();
|
||||||
|
var bimg = jQuery("#bimg").val();
|
||||||
|
var bc = jQuery("#bc").val();
|
||||||
|
jQuery( "#showmsg" ).prepend("<div align='center' class='alertes alert-successes'>Loading Data...</div>");
|
||||||
|
jQuery( ".mkb-rr" ).remove();
|
||||||
|
jQuery.ajax({
|
||||||
|
type: 'POST',
|
||||||
|
url:mkbAjax.ajaxurl,
|
||||||
|
data: {"action": "mkb_dropdown_ajax", "trcat":trcat,"bc":bc,"bimg":bimg},
|
||||||
|
success:function(data) {
|
||||||
|
jQuery( ".alert-successes" ).remove();
|
||||||
|
jQuery( "#showmsg" ).append("<div class='alertes alert-successes mkb-rr'>"+data+"</div>");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
// Ajax Call for mkb Dropdown (Theme 2)
|
||||||
|
jQuery(".leftm").click(function(e) {
|
||||||
|
e.preventDefault();
|
||||||
|
var trcat = jQuery(this).attr("data-id");
|
||||||
|
var bimglb = jQuery("#bimglb").val();
|
||||||
|
var bclb = jQuery("#bclb").val();
|
||||||
|
jQuery( "#showmsglb" ).prepend("<div align='center' class='alertes alert-successes'>Loading Data...</div>");
|
||||||
|
jQuery( ".mkb-llb" ).remove();
|
||||||
|
jQuery.ajax({
|
||||||
|
type: 'POST',
|
||||||
|
url:mkbAjax.ajaxurl,
|
||||||
|
data: {"action": "mkb_lfb_ajax", "trcat":trcat,"bclb":bclb,"bimglb":bimglb},
|
||||||
|
success:function(data) {
|
||||||
|
jQuery( ".alert-successes" ).remove();
|
||||||
|
jQuery( "#showmsglb" ).append("<div class='alertes alert-successes mkb-llb'>"+data+"</div>");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
});
|
|
@ -0,0 +1,53 @@
|
||||||
|
=== Mage Woo Event Booking Manager ===
|
||||||
|
Contributors: MagePeople Team
|
||||||
|
Tags: event, event with woocommerce, woocommerce event, wordpress event plugin, event management wordpress, event booking for woocommerce, best wordpress event plugin, event booking manager wordpress, wordpress event
|
||||||
|
Requires at least: 3.7
|
||||||
|
Tested up to: 4.9
|
||||||
|
Stable tag: 1.0
|
||||||
|
License: GPLv2 or later
|
||||||
|
|
||||||
|
Mage Woo Event Booking Manager is a Event Plugin for WordPress which is based on WooCommerce.
|
||||||
|
|
||||||
|
== Description ==
|
||||||
|
|
||||||
|
This is one of the best and simple event management plugin is WordPress directory, Its used Woocommerce for making payment so Its freedom to use any payment gateway via WooCommerce. This plugin will run with Woocommerce but it will work as event post it will not take any effect on woocommerce products so if you want you can sale your product along with it.
|
||||||
|
|
||||||
|
Features:
|
||||||
|
|
||||||
|
* Shortcode Powred
|
||||||
|
* Unlimited Category
|
||||||
|
* Unlimited Organization
|
||||||
|
* Unlimited Event
|
||||||
|
* Open Source
|
||||||
|
* Developer Friendly
|
||||||
|
* Woocommerce Ready
|
||||||
|
* Use Shortcode [event-list] for showing all faq question. if you want to show a event list of any particular category use [event-list cat=ID].
|
||||||
|
* Live demo http://demo.wp-people.net/mage-woo-event-booking-manager-free/
|
||||||
|
|
||||||
|
== Installation ==
|
||||||
|
|
||||||
|
Upload the Mage FAQ plugin to your blog, Activate it, then use shortcode as your need).
|
||||||
|
|
||||||
|
1, 2, 3: You're done!
|
||||||
|
|
||||||
|
|
||||||
|
== Frequently Asked Questions ==
|
||||||
|
|
||||||
|
= Is Mage Woo Event Booking Manager Free? =
|
||||||
|
Yes! Mage Woo Event Booking Manager is free.
|
||||||
|
|
||||||
|
You can check the demo of this plugin from here http://demo.wp-people.net/mage-woo-event-booking-manager-free/
|
||||||
|
|
||||||
|
= How its work? =
|
||||||
|
Mage Woo Event Booking Manager one of the simple event plugin for WordPress which is based on Woocommerce. Its work as an individual event and its payment functionality handle with woocommerce so there are no worries about payment gateway you can use every payment gateway which is support woocommerce. The interesting part is the event post type is completely different there is no connection with woocommerce product so if you can sell anything from woocommerce product.
|
||||||
|
|
||||||
|
= How can i get the attendee list? =
|
||||||
|
After successfull booking user data will be saved under event attendee list, You can find the list from Events -> attendee list or Go to event list and click on the attendee list on right side of event to get that particular event attendee list.
|
||||||
|
|
||||||
|
= How can i display event list? =
|
||||||
|
You can display the event list on any page by using the ShortCode. Just use this shortcode to display all events list [event-list]. If you want to display any particular category events just use [event-list cat=ID] here ID will be the category id which will you find in the category section of the dashboard.
|
||||||
|
|
||||||
|
== Changelog ==
|
||||||
|
|
||||||
|
= 1.0 =
|
||||||
|
*Initial Release Date - 02 February 2018*
|
|
@ -0,0 +1,83 @@
|
||||||
|
<?php
|
||||||
|
get_header();
|
||||||
|
the_post();
|
||||||
|
global $post;
|
||||||
|
global $woocommerce;
|
||||||
|
$event_meta = get_post_custom(get_the_id());
|
||||||
|
$author_terms = get_the_terms(get_the_id(), 'mep_org');
|
||||||
|
$book_count = get_post_meta(get_the_id(),'total_booking', true);
|
||||||
|
if($book_count){ $total_book = $book_count; }else{ $total_book = 0; }
|
||||||
|
?>
|
||||||
|
<div class="mep-events-wrapper">
|
||||||
|
<div class="mep-event-detailsss">
|
||||||
|
<div class="mep-top-part">
|
||||||
|
<div class="mep-left-col">
|
||||||
|
<div class="mep-event-thumbnail">
|
||||||
|
<?php the_post_thumbnail('full'); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="mep-right-col">
|
||||||
|
<div class="mep-event-title-header">
|
||||||
|
<h2><?php the_title(); ?></h2>
|
||||||
|
<?php if($author_terms){ ?><p> <?php _e('By:','mep'); ?> <a href="<?php echo get_term_link( $author_terms[0]->term_id, 'mep_org' ); ?>"><?php echo $author_terms[0]->name; ?></a></p><?php } ?>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
if($event_meta['_price'][0]>0){
|
||||||
|
if($event_meta['mep_price_label'][0]){
|
||||||
|
?>
|
||||||
|
<h3><?php echo $event_meta['mep_price_label'][0]; ?>: </h3>
|
||||||
|
<?php } echo get_woocommerce_currency_symbol().$event_meta['_price'][0]; ?>
|
||||||
|
<?php } else{ _e('<h3>Free</h3>','mep'); }?>
|
||||||
|
<?php if($event_meta['mep_total_seat'][0]){
|
||||||
|
?>
|
||||||
|
|
||||||
|
<h5><strong><?php _e('Total Seat:','mep'); ?></strong> <?php echo $event_meta['mep_total_seat'][0]; ?> (<strong><?php echo ($event_meta['mep_total_seat'][0]- $total_book); ?></strong> Left)</h5>
|
||||||
|
<?php } ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="mep-btn-part">
|
||||||
|
<div class="mep-left-col">
|
||||||
|
<div class="mep-event-meta">
|
||||||
|
<?php _e('Share This Event:','mep'); ?> <?php mep_social_share(); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="mep-right-col">
|
||||||
|
<div class="mep-event-datetime">
|
||||||
|
<h3><?php _e('Date and Time:','mep'); ?></h3>
|
||||||
|
<p><?php echo $event_meta['mep_event_start_date'][0]; ?> - <?php echo $event_meta['mep_event_end_date'][0]; ?></p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="mep-content-part">
|
||||||
|
<div class="mep-left-col">
|
||||||
|
<div class="mep-event-details">
|
||||||
|
<h3 class="mep-desc-title"><?php _e('Description','mep'); ?></h3>
|
||||||
|
<?php the_content(); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="mep-right-col">
|
||||||
|
<div class="mep-reg-btn-sec">
|
||||||
|
<?php
|
||||||
|
if($event_meta['_price'][0]>0){
|
||||||
|
?>
|
||||||
|
<div class="cart-btn-sec">
|
||||||
|
<?php mep_get_event_reg_btn(get_the_id()); ?>
|
||||||
|
</div>
|
||||||
|
<?php }?>
|
||||||
|
</div>
|
||||||
|
<div class="mep-event-location">
|
||||||
|
<h3><?php _e('Event Location:','mep'); ?></h3>
|
||||||
|
<p><?php echo $event_meta['mep_location_venue'][0]; ?><br/>
|
||||||
|
<?php echo $event_meta['mep_street'][0]; ?><br/>
|
||||||
|
<?php echo $event_meta['mep_city'][0]; ?><br/>
|
||||||
|
<?php echo $event_meta['mep_state'][0]; ?>,
|
||||||
|
<?php echo $event_meta['mep_postcode'][0]; ?><br/>
|
||||||
|
<?php echo $event_meta['mep_country'][0]; ?></p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<?php get_footer(); ?>
|
|
@ -0,0 +1,53 @@
|
||||||
|
<?php
|
||||||
|
get_header();
|
||||||
|
the_post();
|
||||||
|
$term_id = get_queried_object()->term_id;
|
||||||
|
// print_r(get_queried_object());
|
||||||
|
?>
|
||||||
|
|
||||||
|
<div class='mep_event_list'>
|
||||||
|
<div class="mep_cat-details">
|
||||||
|
<h1><?php echo get_queried_object()->name; ?></h1>
|
||||||
|
<p><?php echo get_queried_object()->description; ?></p>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
$args_search_qqq = array (
|
||||||
|
'post_type' => array( 'mep_events' ),
|
||||||
|
'posts_per_page' => -1,
|
||||||
|
'tax_query' => array(
|
||||||
|
array(
|
||||||
|
'taxonomy' => 'mep_org',
|
||||||
|
'field' => 'term_id',
|
||||||
|
'terms' => $term_id
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
);
|
||||||
|
$loop = new WP_Query( $args_search_qqq );
|
||||||
|
while ($loop->have_posts()) {
|
||||||
|
$loop->the_post();
|
||||||
|
$event_meta = get_post_meta(get_the_id(),'mep_event_meta',true);
|
||||||
|
$time = strtotime($event_meta['event_start_date']);
|
||||||
|
$newformat = date('Y-m-d H:i:s',$time);
|
||||||
|
|
||||||
|
|
||||||
|
if(time() < strtotime($newformat)){
|
||||||
|
|
||||||
|
?>
|
||||||
|
<div class='mep_event_list_item'>
|
||||||
|
<div class="mep_list_thumb"><?php the_post_thumbnail('medium'); ?></div>
|
||||||
|
<div class="mep_list_event_details"><a href="<?php the_permalink(); ?>">
|
||||||
|
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||||
|
<h3 class='mep_list_date'>on <?php echo $event_meta['event_start_date']; ?> - <?php echo $event_meta['event_end_date']; ?></h3>
|
||||||
|
<p><?php echo $event_meta['event_venue']; ?>,<?php echo $event_meta['event_street']; ?>, <?php echo $event_meta['event_city']; ?>,<?php echo $event_meta['event_state']; ?>,<?php echo $event_meta['event_postcode']; ?>,<?php echo $event_meta['event_country']; ?></p>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
get_footer();
|
||||||
|
?>
|
|
@ -0,0 +1,56 @@
|
||||||
|
<?php
|
||||||
|
get_header();
|
||||||
|
the_post();
|
||||||
|
|
||||||
|
$term_id = get_queried_object()->term_id;
|
||||||
|
// print_r(get_queried_object());
|
||||||
|
?>
|
||||||
|
|
||||||
|
<div class='mep_event_list'>
|
||||||
|
|
||||||
|
<div class="mep_cat-details">
|
||||||
|
<h1><?php echo get_queried_object()->name; ?></h1>
|
||||||
|
<p><?php echo get_queried_object()->description; ?></p>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
$args_search_qqq = array (
|
||||||
|
'post_type' => array( 'mep_events' ),
|
||||||
|
'posts_per_page' => -1,
|
||||||
|
'tax_query' => array(
|
||||||
|
array(
|
||||||
|
'taxonomy' => 'mep_org',
|
||||||
|
'field' => 'term_id',
|
||||||
|
'terms' => $term_id
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
);
|
||||||
|
$loop = new WP_Query( $args_search_qqq );
|
||||||
|
while ($loop->have_posts()) {
|
||||||
|
$loop->the_post();
|
||||||
|
$event_meta = get_post_meta(get_the_id(),'mep_event_meta',true);
|
||||||
|
$time = strtotime($event_meta['event_start_date']);
|
||||||
|
$newformat = date('Y-m-d H:i:s',$time);
|
||||||
|
|
||||||
|
|
||||||
|
if(time() < strtotime($newformat)){
|
||||||
|
|
||||||
|
?>
|
||||||
|
<div class='mep_event_list_item'>
|
||||||
|
<div class="mep_list_thumb"><?php the_post_thumbnail('medium'); ?></div>
|
||||||
|
<div class="mep_list_event_details"><a href="<?php the_permalink(); ?>">
|
||||||
|
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||||
|
<h3 class='mep_list_date'>on <?php echo $event_meta['event_start_date']; ?> - <?php echo $event_meta['event_end_date']; ?></h3>
|
||||||
|
<p><?php echo $event_meta['event_venue']; ?>,<?php echo $event_meta['event_street']; ?>, <?php echo $event_meta['event_city']; ?>,<?php echo $event_meta['event_state']; ?>,<?php echo $event_meta['event_postcode']; ?>,<?php echo $event_meta['event_country']; ?></p>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
get_footer();
|
||||||
|
?>
|
|
@ -0,0 +1,544 @@
|
||||||
|
<?php
|
||||||
|
/**
|
||||||
|
* Plugin Name: Mage Woo Event Booking Manager
|
||||||
|
* Plugin URI: http://mage-people.com
|
||||||
|
* Description: A Complete Event Solution for WordPress by MagePeople..
|
||||||
|
* Version: 1.0
|
||||||
|
* Author: MagePeople Team
|
||||||
|
* Author URI: http://www.mage-people.com/
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if ( ! defined( 'ABSPATH' ) ) { die; } // Cannot access pages directly.
|
||||||
|
|
||||||
|
require_once(dirname(__FILE__) . "/inc/mep_cpt.php");
|
||||||
|
require_once(dirname(__FILE__) . "/inc/mep_tax.php");
|
||||||
|
require_once(dirname(__FILE__) . "/inc/mep_event_meta.php");
|
||||||
|
require_once(dirname(__FILE__) . "/inc/mep_shortcode.php");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Enqueue Scripts for admin dashboard
|
||||||
|
add_action('admin_enqueue_scripts', 'mep_event_admin_scripts');
|
||||||
|
function mep_event_admin_scripts() {
|
||||||
|
wp_enqueue_script('jquery-ui-datepicker');
|
||||||
|
wp_enqueue_script('jquery-ui-core');
|
||||||
|
wp_enqueue_script('jquery-ui-timepicker-addon',plugin_dir_url( __FILE__ ).'js/jquery-ui-timepicker-addon.js',array('jquery','jquery-ui-core'),1,true);
|
||||||
|
wp_enqueue_script('jquery-ui-timepicker-addon',plugin_dir_url( __FILE__ ).'js/jquery-ui-sliderAccess.js',array('jquery','jquery-ui-core','jquery-ui-timepicker-addon'),1,true);
|
||||||
|
wp_enqueue_style('jquery-ui-timepicker-addon',plugin_dir_url( __FILE__ ).'css/jquery-ui-timepicker-addon.css',array());
|
||||||
|
wp_enqueue_style('mep-admin-style',plugin_dir_url( __FILE__ ).'css/admin_style.css',array());
|
||||||
|
wp_enqueue_style('mep-jquery-ui-style',plugin_dir_url( __FILE__ ).'css/jquery-ui.css',array());
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Enqueue Scripts for frontend
|
||||||
|
add_action('wp_enqueue_scripts', 'mep_event_enqueue_scripts');
|
||||||
|
function mep_event_enqueue_scripts() {
|
||||||
|
wp_enqueue_style('mep-event-style',plugin_dir_url( __FILE__ ).'css/style.css',array());
|
||||||
|
wp_enqueue_style ('font-awesome-css-cdn',"https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.4.0/css/font-awesome.min.css",null,1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Datepicker code for admin dashboard load in footer section
|
||||||
|
add_action('admin_footer','mep_admin_footer_script',10,99);
|
||||||
|
function mep_admin_footer_script(){
|
||||||
|
global $pagenow, $typenow;
|
||||||
|
if ($typenow=='mep_events') {
|
||||||
|
?>
|
||||||
|
<script type="text/javascript">
|
||||||
|
jQuery(document).ready(function($){
|
||||||
|
var startDateTextBox = jQuery('.event_start');
|
||||||
|
var endDateTextBox = jQuery('.event_end');
|
||||||
|
jQuery.timepicker.datetimeRange(
|
||||||
|
startDateTextBox,
|
||||||
|
endDateTextBox,
|
||||||
|
{
|
||||||
|
minInterval: (1000*60*60), // 1hr
|
||||||
|
dateFormat: 'dd M yy',
|
||||||
|
timeFormat: 'HH:mm',
|
||||||
|
start: {}, // start picker options
|
||||||
|
end: {} // end picker options
|
||||||
|
}
|
||||||
|
);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Class for Linking with Woocommerce with Event Pricing
|
||||||
|
add_action('plugins_loaded', 'mep_load_wc_class');
|
||||||
|
function mep_load_wc_class() {
|
||||||
|
|
||||||
|
if ( class_exists('WC_Product_Data_Store_CPT') ) {
|
||||||
|
|
||||||
|
class MEP_Product_Data_Store_CPT extends WC_Product_Data_Store_CPT {
|
||||||
|
|
||||||
|
public function read( &$product ) {
|
||||||
|
|
||||||
|
$product->set_defaults();
|
||||||
|
|
||||||
|
if ( ! $product->get_id() || ! ( $post_object = get_post( $product->get_id() ) ) || ! in_array( $post_object->post_type, array( 'mep_events', 'product' ) ) ) { // change birds with your post type
|
||||||
|
throw new Exception( __( 'Invalid product.', 'woocommerce' ) );
|
||||||
|
}
|
||||||
|
|
||||||
|
$id = $product->get_id();
|
||||||
|
|
||||||
|
$product->set_props( array(
|
||||||
|
'name' => $post_object->post_title,
|
||||||
|
'slug' => $post_object->post_name,
|
||||||
|
'date_created' => 0 < $post_object->post_date_gmt ? wc_string_to_timestamp( $post_object->post_date_gmt ) : null,
|
||||||
|
'date_modified' => 0 < $post_object->post_modified_gmt ? wc_string_to_timestamp( $post_object->post_modified_gmt ) : null,
|
||||||
|
'status' => $post_object->post_status,
|
||||||
|
'description' => $post_object->post_content,
|
||||||
|
'short_description' => $post_object->post_excerpt,
|
||||||
|
'parent_id' => $post_object->post_parent,
|
||||||
|
'menu_order' => $post_object->menu_order,
|
||||||
|
'reviews_allowed' => 'open' === $post_object->comment_status,
|
||||||
|
) );
|
||||||
|
|
||||||
|
$this->read_attributes( $product );
|
||||||
|
$this->read_downloads( $product );
|
||||||
|
$this->read_visibility( $product );
|
||||||
|
$this->read_product_data( $product );
|
||||||
|
$this->read_extra_data( $product );
|
||||||
|
$product->set_object_read( true );
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the product type based on product ID.
|
||||||
|
*
|
||||||
|
* @since 3.0.0
|
||||||
|
* @param int $product_id
|
||||||
|
* @return bool|string
|
||||||
|
*/
|
||||||
|
public function get_product_type( $product_id ) {
|
||||||
|
$post_type = get_post_type( $product_id );
|
||||||
|
if ( 'product_variation' === $post_type ) {
|
||||||
|
return 'variation';
|
||||||
|
} elseif ( in_array( $post_type, array( 'mep_events', 'product' ) ) ) { // change birds with your post type
|
||||||
|
$terms = get_the_terms( $product_id, 'product_type' );
|
||||||
|
return ! empty( $terms ) ? sanitize_title( current( $terms )->name ) : 'simple';
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
add_filter( 'woocommerce_data_stores', 'mep_woocommerce_data_stores' );
|
||||||
|
function mep_woocommerce_data_stores ( $stores ) {
|
||||||
|
$stores['product'] = 'MEP_Product_Data_Store_CPT';
|
||||||
|
return $stores;
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
|
||||||
|
add_action('admin_notices', 'wc_not_loaded');
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
add_action('woocommerce_before_checkout_form', 'mep_displays_cart_products_feature_image');
|
||||||
|
|
||||||
|
function mep_displays_cart_products_feature_image() {
|
||||||
|
foreach ( WC()->cart->get_cart() as $cart_item ) {
|
||||||
|
$item = $cart_item['data'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Get user information and save to attendee list after order confirmation
|
||||||
|
add_action( 'woocommerce_order_status_completed_notification', 'mep_set_event_attendee_data' );
|
||||||
|
function mep_set_event_attendee_data( $order_id ) {
|
||||||
|
|
||||||
|
if ( ! $order_id )
|
||||||
|
return;
|
||||||
|
|
||||||
|
// Getting an instance of the order object
|
||||||
|
$order = wc_get_order( $order_id );
|
||||||
|
$order_meta = get_post_meta($order_id);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Iterating through each order items (WC_Order_Item_Product objects in WC 3+)
|
||||||
|
foreach ( $order->get_items() as $item_id => $item_values ) {
|
||||||
|
$product_id = $item_values->get_product_id();
|
||||||
|
$item_data = $item_values->get_data();
|
||||||
|
$product_id = $item_data['product_id'];
|
||||||
|
$product = get_page_by_title( $item_data['name'], OBJECT, 'mep_events' );
|
||||||
|
$event_name = $item_data['name'];
|
||||||
|
$event_id = $product->ID;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
$first_name = $order_meta['_billing_first_name'][0];
|
||||||
|
$last_name = $order_meta['_billing_last_name'][0];
|
||||||
|
$company_name = $order_meta['_billing_company'][0];
|
||||||
|
$address_1 = $order_meta['_billing_address_1'][0];
|
||||||
|
$address_2 = $order_meta['_billing_address_2'][0];
|
||||||
|
$city = $order_meta['_billing_city'][0];
|
||||||
|
$state = $order_meta['_billing_state'][0];
|
||||||
|
$postcode = $order_meta['_billing_postcode'][0];
|
||||||
|
$country = $order_meta['_billing_country'][0];
|
||||||
|
$email = $order_meta['_billing_email'][0];
|
||||||
|
$phone = $order_meta['_billing_phone'][0];
|
||||||
|
$billing_intotal = $order_meta['_billing_address_index'][0];
|
||||||
|
$payment_method = $order_meta['_payment_method_title'][0];
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// ADD THE FORM INPUT TO $new_post ARRAY
|
||||||
|
$new_post = array(
|
||||||
|
'post_title' => $first_name." ".$last_name,
|
||||||
|
'post_content' => '',
|
||||||
|
'post_category' => array(), // Usable for custom taxonomies too
|
||||||
|
'tags_input' => array(),
|
||||||
|
'post_status' => 'publish', // Choose: publish, preview, future, draft, etc.
|
||||||
|
'post_type' => 'mep_events_attendees' //'post',page' or use a custom post type if you want to
|
||||||
|
);
|
||||||
|
|
||||||
|
//SAVE THE POST
|
||||||
|
$pid = wp_insert_post($new_post);
|
||||||
|
$update_fname = update_post_meta( $pid, 'ea_first_name', $first_name);
|
||||||
|
$update_lname = update_post_meta( $pid, 'ea_last_name', $last_name);
|
||||||
|
$update_company = update_post_meta( $pid, 'ea_company_name', $company_name);
|
||||||
|
$update_ad1 = update_post_meta( $pid, 'ea_address_1', $address_1);
|
||||||
|
$update_ad2 = update_post_meta( $pid, 'ea_address_2', $address_2);
|
||||||
|
$update_city = update_post_meta( $pid, 'ea_city', $city);
|
||||||
|
$update_state = update_post_meta( $pid, 'ea_state', $state);
|
||||||
|
$update_postcode = update_post_meta( $pid, 'ea_postcode', $postcode);
|
||||||
|
$update_country = update_post_meta( $pid, 'ea_country', $country);
|
||||||
|
$update_email = update_post_meta( $pid, 'ea_email', $email);
|
||||||
|
$update_phone = update_post_meta( $pid, 'ea_phone', $phone);
|
||||||
|
$update_pym = update_post_meta( $pid, 'ea_payment_method', $payment_method);
|
||||||
|
$update_event_name = update_post_meta( $pid, 'ea_event_name', $event_name);
|
||||||
|
$update_eid = update_post_meta( $pid, 'ea_event_id', $event_id);
|
||||||
|
$update_oid = update_post_meta( $pid, 'ea_order_id', $order_id);
|
||||||
|
|
||||||
|
$mep_total_booking = get_post_meta($event_id,'total_booking', true);
|
||||||
|
$update_total_booking = update_post_meta( $event_id, 'total_booking', ($mep_total_booking+1));
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
add_action('restrict_manage_posts', 'mep_filter_post_type_by_taxonomy');
|
||||||
|
function mep_filter_post_type_by_taxonomy() {
|
||||||
|
global $typenow;
|
||||||
|
$post_type = 'mep_events'; // change to your post type
|
||||||
|
$taxonomy = 'mep_cat'; // change to your taxonomy
|
||||||
|
if ($typenow == $post_type) {
|
||||||
|
$selected = isset($_GET[$taxonomy]) ? $_GET[$taxonomy] : '';
|
||||||
|
$info_taxonomy = get_taxonomy($taxonomy);
|
||||||
|
wp_dropdown_categories(array(
|
||||||
|
'show_option_all' => __("Show All {$info_taxonomy->label}"),
|
||||||
|
'taxonomy' => $taxonomy,
|
||||||
|
'name' => $taxonomy,
|
||||||
|
'orderby' => 'name',
|
||||||
|
'selected' => $selected,
|
||||||
|
'show_count' => true,
|
||||||
|
'hide_empty' => true,
|
||||||
|
));
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
add_filter('parse_query', 'mep_convert_id_to_term_in_query');
|
||||||
|
function mep_convert_id_to_term_in_query($query) {
|
||||||
|
global $pagenow;
|
||||||
|
$post_type = 'mep_events'; // change to your post type
|
||||||
|
$taxonomy = 'mep_cat'; // change to your taxonomy
|
||||||
|
$q_vars = &$query->query_vars;
|
||||||
|
|
||||||
|
if ( $pagenow == 'edit.php' && isset($q_vars['post_type']) && $q_vars['post_type'] == $post_type && isset($q_vars[$taxonomy]) && is_numeric($q_vars[$taxonomy]) && $q_vars[$taxonomy] != 0 ) {
|
||||||
|
$term = get_term_by('id', $q_vars[$taxonomy], $taxonomy);
|
||||||
|
$q_vars[$taxonomy] = $term->slug;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
add_filter('parse_query', 'mep_attendee_filter_query');
|
||||||
|
function mep_attendee_filter_query($query) {
|
||||||
|
global $pagenow;
|
||||||
|
$post_type = 'mep_events_attendees';
|
||||||
|
$q_vars = &$query->query_vars;
|
||||||
|
|
||||||
|
if ( $pagenow == 'edit.php' && isset($_GET['post_type']) && $_GET['post_type'] == $post_type && isset($_GET['meta_value']) && $_GET['meta_value'] != 0) {
|
||||||
|
|
||||||
|
$q_vars['meta_key'] = 'ea_event_id';
|
||||||
|
$q_vars['meta_value'] = $_GET['meta_value'];
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
add_filter( 'post_row_actions', 'mep_remove_row_actions', 10, 1 );
|
||||||
|
function mep_remove_row_actions( $actions )
|
||||||
|
{
|
||||||
|
if( get_post_type() === 'mep_events_attendees' )
|
||||||
|
unset( $actions['edit'] );
|
||||||
|
// unset( $actions['view'] );
|
||||||
|
unset( $actions['trash'] );
|
||||||
|
unset( $actions['inline hide-if-no-js'] );
|
||||||
|
return $actions;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Add the custom columns to the book post type:
|
||||||
|
add_filter( 'manage_mep_events_posts_columns', 'mep_set_custom_edit_event_columns' );
|
||||||
|
function mep_set_custom_edit_event_columns($columns) {
|
||||||
|
|
||||||
|
unset( $columns['date'] );
|
||||||
|
|
||||||
|
$columns['mep_status'] = __( 'Status', 'mep' );
|
||||||
|
$columns['mep_atten'] = __( 'Attendees', 'mep' );
|
||||||
|
|
||||||
|
return $columns;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Add the data to the custom columns for the book post type:
|
||||||
|
add_action( 'manage_mep_events_posts_custom_column' , 'mep_custom_event_column', 10, 2 );
|
||||||
|
function mep_custom_event_column( $column, $post_id ) {
|
||||||
|
switch ( $column ) {
|
||||||
|
case 'mep_status' :
|
||||||
|
$values = get_post_custom( $post_id );
|
||||||
|
echo mep_get_event_status($values['mep_event_start_date'][0]);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'mep_atten' :
|
||||||
|
echo '<a class="button button-primary button-large" href="'.get_site_url().'/wp-admin/edit.php?post_type=mep_events_attendees&meta_value='.$post_id.'">Attendees List</a>';
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Getting event exprie date & time
|
||||||
|
function mep_get_event_status($startdatetime){
|
||||||
|
|
||||||
|
$time = strtotime($startdatetime);
|
||||||
|
$newformat = date('Y-m-d H:i:s',$time);
|
||||||
|
$datetime1 = new DateTime();
|
||||||
|
$datetime2 = new DateTime($newformat);
|
||||||
|
$interval = $datetime1->diff($datetime2);
|
||||||
|
|
||||||
|
if(time() > strtotime($newformat)){
|
||||||
|
return "<span class=err>Expired</span>";
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
$days = $interval->days;
|
||||||
|
$hours = $interval->h;
|
||||||
|
$minutes = $interval->i;
|
||||||
|
if($days>0){ $dd = $days." days "; }else{ $dd=""; }
|
||||||
|
if($hours>0){ $hh = $hours." hours "; }else{ $hh=""; }
|
||||||
|
if($minutes>0){ $mm = $minutes." minutes "; }else{ $mm=""; }
|
||||||
|
return "<span class='active'>$dd $hh $mm</span>";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Get Event Registration Button
|
||||||
|
function mep_get_event_reg_btn($post_id){
|
||||||
|
|
||||||
|
// $event_meta = get_post_meta($post_id, 'mep_event_meta',true);
|
||||||
|
$event_meta = get_post_custom(get_the_id());
|
||||||
|
$event_expire_date = $event_meta['mep_event_start_date'][0];
|
||||||
|
$event_ecternal_link = '';
|
||||||
|
// $event_ecternal_url = $event_meta['ex_reg_url'][0];
|
||||||
|
|
||||||
|
|
||||||
|
$time = strtotime($event_expire_date);
|
||||||
|
$newformat = date('Y-m-d H:i:s',$time);
|
||||||
|
$datetime1 = new DateTime();
|
||||||
|
$datetime2 = new DateTime($newformat);
|
||||||
|
$interval = $datetime1->diff($datetime2);
|
||||||
|
|
||||||
|
if(time() > strtotime($newformat)){
|
||||||
|
echo "<span class=event-expire-btn>Event Expired</span>";
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
$days = $interval->d;
|
||||||
|
$hours = $interval->h;
|
||||||
|
$minutes = $interval->i;
|
||||||
|
if($days>0){ $dd = $days." days "; }else{ $dd=""; }
|
||||||
|
if($hours>0){ $hh = $hours." hours "; }else{ $hh=""; }
|
||||||
|
if($minutes>0){ $mm = $minutes." minutes "; }else{ $mm=""; }
|
||||||
|
|
||||||
|
|
||||||
|
?>
|
||||||
|
<form action="" method='post'>
|
||||||
|
<?php //do_action('event_kaku_before_reg_btn'); ?>
|
||||||
|
<span id="usertotal"> </span>
|
||||||
|
<button type="submit" name="add-to-cart" value="<?php echo esc_attr($post_id); ?>" class="single_add_to_cart_button button alt btn-mep-event-cart">Register This Event </button>
|
||||||
|
</form>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Redirect to Checkout after successfuly event registration
|
||||||
|
add_filter ('add_to_cart_redirect', 'mep_event_redirect_to_checkout');
|
||||||
|
function mep_event_redirect_to_checkout() {
|
||||||
|
global $woocommerce;
|
||||||
|
$checkout_url = $woocommerce->cart->get_checkout_url();
|
||||||
|
return $checkout_url;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// Add the custom columns to the book post type:
|
||||||
|
add_filter( 'manage_mep_events_attendees_posts_columns', 'mep_set_custom_events_attendees_columns' );
|
||||||
|
function mep_set_custom_events_attendees_columns($columns) {
|
||||||
|
|
||||||
|
unset( $columns['title'] );
|
||||||
|
unset( $columns['date'] );
|
||||||
|
|
||||||
|
$columns['mep_uid'] = __( 'Unique ID', 'mep' );
|
||||||
|
$columns['mep_fn'] = __( 'Full Name', 'mep' );
|
||||||
|
$columns['mep_email'] = __( 'email', 'mep' );
|
||||||
|
$columns['mep_phone'] = __( 'Phone', 'mep' );
|
||||||
|
$columns['mep_address'] = __( 'Addresss', 'mep' );
|
||||||
|
$columns['mep_evnt'] = __( 'Event', 'mep' );
|
||||||
|
|
||||||
|
return $columns;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Add the data to the custom columns for the book post type:
|
||||||
|
add_action( 'manage_mep_events_attendees_posts_custom_column' , 'mep_events_attendees_column', 10, 2 );
|
||||||
|
function mep_events_attendees_column( $column, $post_id ) {
|
||||||
|
switch ( $column ) {
|
||||||
|
|
||||||
|
case 'mep_uid' :
|
||||||
|
echo get_post_meta( $post_id, 'ea_order_id', true );
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'mep_fn' :
|
||||||
|
echo get_post_meta( $post_id, 'ea_first_name', true )." ".get_post_meta( $post_id, 'ea_last_name', true );
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'mep_email' :
|
||||||
|
echo get_post_meta( $post_id, 'ea_email', true );
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'mep_phone' :
|
||||||
|
echo get_post_meta( $post_id, 'ea_phone', true );
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'mep_address' :
|
||||||
|
echo get_post_meta( $post_id, 'ea_address_1', true )."<br/>".get_post_meta( $post_id, 'ea_address_2', true )."<br/>".get_post_meta( $post_id, 'ea_state', true ).", ".get_post_meta( $post_id, 'ea_city', true ).", ".get_post_meta( $post_id, 'ea_country', true );
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'mep_evnt' :
|
||||||
|
echo get_post_meta( $post_id, 'ea_event_name', true );
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'mep_atten' :
|
||||||
|
echo '<a class="button button-primary button-large" href="'.get_site_url().'/wp-admin/edit.php?post_type=mep_events_attendees&meta_value='.$post_id.'">Attendees List</a>';
|
||||||
|
break;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function mep_disable_new_posts() {
|
||||||
|
// Hide sidebar link
|
||||||
|
global $submenu;
|
||||||
|
unset($submenu['edit.php?post_type=mep_events_attendees'][10]);
|
||||||
|
// // Hide link on listing page
|
||||||
|
if (isset($_GET['post_type']) && $_GET['post_type'] == 'mep_events_attendees') {
|
||||||
|
echo '<style type="text/css">
|
||||||
|
#favorite-actions, .add-new-h2, .tablenav, .page-title-action { display:none; }
|
||||||
|
</style>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
add_action('admin_menu', 'mep_disable_new_posts');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function mep_load_events_templates($template) {
|
||||||
|
global $post;
|
||||||
|
|
||||||
|
// Is this a "my-custom-post-type" post?
|
||||||
|
if ($post->post_type == "mep_events"){
|
||||||
|
|
||||||
|
//Your plugin path
|
||||||
|
$plugin_path = plugin_dir_path( __FILE__ );
|
||||||
|
|
||||||
|
// The name of custom post type single template
|
||||||
|
$template_name = 'templates/single-events.php';
|
||||||
|
|
||||||
|
// A specific single template for my custom post type exists in theme folder? Or it also doesn't exist in my plugin?
|
||||||
|
if($template === get_stylesheet_directory() . '/' . $template_name
|
||||||
|
|| !file_exists($plugin_path . $template_name)) {
|
||||||
|
|
||||||
|
//Then return "single.php" or "single-my-custom-post-type.php" from theme directory.
|
||||||
|
return $template;
|
||||||
|
}
|
||||||
|
|
||||||
|
// If not, return my plugin custom post type template.
|
||||||
|
return $plugin_path . $template_name;
|
||||||
|
}
|
||||||
|
|
||||||
|
//This is not my custom post type, do nothing with $template
|
||||||
|
return $template;
|
||||||
|
}
|
||||||
|
add_filter('single_template', 'mep_load_events_templates');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
add_filter('template_include', 'mep_organizer_set_template');
|
||||||
|
function mep_organizer_set_template( $template ){
|
||||||
|
|
||||||
|
if( is_tax('mep_org')){
|
||||||
|
$template = plugin_dir_path( __FILE__ ).'templates/taxonomy-organozer.php';
|
||||||
|
}
|
||||||
|
|
||||||
|
if( is_tax('mep_cat')){
|
||||||
|
$template = plugin_dir_path( __FILE__ ).'templates/taxonomy-category.php';
|
||||||
|
}
|
||||||
|
|
||||||
|
return $template;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function mep_social_share(){
|
||||||
|
?>
|
||||||
|
<ul class='mep-social-share'>
|
||||||
|
<li> <a data-toggle="tooltip" title="" class="facebook" onclick="window.open('https://www.facebook.com/sharer.php?u=<?php the_permalink(); ?>','Facebook','width=600,height=300,left='+(screen.availWidth/2-300)+',top='+(screen.availHeight/2-150)+''); return false;" href="http://www.facebook.com/sharer.php?u=<?php the_permalink(); ?>" data-original-title="Share on Facebook"><i class="fa fa-facebook"></i></a></li>
|
||||||
|
|
||||||
|
<li><a data-toggle="tooltip" title="" class="gpuls" onclick="window.open('https://plus.google.com/share?url=<?php the_permalink(); ?>','Google plus','width=585,height=666,left='+(screen.availWidth/2-292)+',top='+(screen.availHeight/2-333)+''); return false;" href="https://plus.google.com/share?url=<?php the_permalink(); ?>" data-original-title="Share on Google Plus"><i class="fa fa-google-plus"></i></a> </li>
|
||||||
|
|
||||||
|
<li><a data-toggle="tooltip" title="" class="twitter" onclick="window.open('https_ssl_verify://twitter.com/share?url=<?php the_permalink(); ?>&text=<?php the_title(); ?>','Twitter share','width=600,height=300,left='+(screen.availWidth/2-300)+',top='+(screen.availHeight/2-150)+''); return false;" href="http://twitter.com/share?url=<?php the_permalink(); ?>&text=<?php the_title(); ?>" data-original-title="Twittet it"><i class="fa fa-twitter"></i></a></li>
|
||||||
|
</ul>
|
||||||
|
<?php
|
||||||
|
}
|
Loading…
Reference in New Issue