This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <h3>You have a new contact from enquirey!</h3><br> | |
| <p> | |
| <strong>Time:</strong><?= $time ?> | |
| </p> | |
| <p> | |
| <strong>Name:</strong><?= $name ?> | |
| </p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| require 'ContactFormAction.php'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /* | |
| Template Name: Contact Page | |
| */ | |
| ?> | |
| <form action="<?= ContactFormAction::url() ?>" method="post" enctype="multipart/form-data"> | |
| <input type="hidden" name="from_action" value="<?= ContactFormAction::getActionName() ?>"> | |
| <input type="text" name="full_name"><br /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| $email = (new WP_Mail) | |
| ->to([ | |
| '[email protected]', | |
| '[email protected]', | |
| ]) | |
| ->cc('[email protected]') | |
| ->bcc([ | |
| '[email protected]', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <h1>Hello {{name}},</h1> | |
| <p>I have found a great class from a developer in {{location}}.</p> | |
| <a href="{{link}}">Check it out on GitHub</a> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| $email = WP_Mail::init() | |
| ->to('[email protected]') | |
| ->subject('WP_Mail is great!') | |
| ->attach(ABSPATH . 'wp-content/uploads/2018/6/image.png') | |
| ->template(get_template_directory() .'/emails/demo.php', [ | |
| 'name' => 'Anthony Budd', | |
| 'location' => 'London', | |
| 'skills' => [ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // functions.php | |
| function forceLogin(){ | |
| if(!is_user_logged_in()){ | |
| $redirect = TRUE; | |
| foreach(['wp-admin', 'wp-login'] as $url) { | |
| if(strpos($_SERVER['REQUEST_URI'], $url) !== FALSE){ | |
| $redirect = FALSE; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <table id="bodyTable" border="0" width="100%" cellspacing="0" cellpadding="0" align="left"> | |
| <tbody> | |
| <tr> | |
| <td id="bodyCell" style="padding-bottom: 40px;" align="center" valign="top"> | |
| <!-- BEGIN TEMPLATE // --> | |
| <table border="0" width="100%" cellspacing="0" cellpadding="0"> | |
| <tbody> | |
| <tr> | |
| <td align="center" valign="top"> | |
| <!-- BEGIN PREHEADER // --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <center></center> | |
| <table id="bodyTable" border="0" width="100%" cellspacing="0" cellpadding="0" align="left"> | |
| <tbody> | |
| <tr> | |
| <td id="bodyCell" style="padding-bottom: 40px;" align="center" valign="top"><!-- BEGIN TEMPLATE // --> | |
| <table border="0" width="100%" cellspacing="0" cellpadding="0"> | |
| <tbody> | |
| <tr> | |
| <td align="center" valign="top"><!-- BEGIN PREHEADER // --> | |
| <!-- // END PREHEADER --></td> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| register_post_type( 'book', array( | |
| 'public' => true, | |
| 'label' => __( 'Books', 'textdomain' ), | |
| )); |