forked from zenithtech/wordpress-react
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpage-CustomPage1.php
More file actions
executable file
·46 lines (39 loc) · 821 Bytes
/
page-CustomPage1.php
File metadata and controls
executable file
·46 lines (39 loc) · 821 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?php
/**
* Template Name: CustomPage1
*/
include('inc/page-header.php');
if( isset($via_ajax) ) { ?>
<style type="text/css">
body {
background-color: #222;
color: #fff;
}
#react_header {
background-color: #0275d8;
}
#footer {
background-color: #0275d8;
}
#footer .site-navigation a {
color: #fff;
}
</style>
<div class="container">
<p>
Custom template <b>page-CustomPage1.php</b>
</p>
<p>
This is custom template, you can include shortcodes, custom CSS, JS, and PHP.
</p>
<p>
Time via PHP within custom template: <?php echo date('Y-m-d G:i:s'); ?>
</p>
</div>
<script>
alert('This is an alert from the custom template page-CustomPage1.php.');
</script>
<script>
alert('Multiple script tags. Another alert in another script tag.');
</script>
<?php } include('inc/page-footer.php'); ?>