b6849213 by Chris Boden

Organized Branding file

1 parent 4bf8d834
1 <?php 1 <?php
2 add_action('admin_print_styles', 'load_styles'); 2 class Branding {
3 3 public static function make() {
4 function load_styles() { 4 add_actions('Branding_Actions');
5 _enqueue_style('branding-style', plugins_url('css/tenzing.css', __FILE__)); 5 }
6
7 }
8
9 add_action('admin_head','custom_header',11);
10 function custom_header() {
11 global $plugin_url;
12 global $current_user;
13
14 include('views/header.php');
15 }
16
17 add_action('admin_footer', 'custom_footer');
18 function custom_footer() {
19 include('views/footer.php');
20 }
21
22 add_action('login_head', 'custom_login',11);
23 function custom_login() {
24 global $plugin_url;
25 echo "
26 <style type='text/css'>
27
28 #login {
29 background: #3b0d32 url('".$plugin_url."images/tenzing.gif') top right no-repeat;
30 padding-top:70px;
31 }
32
33 #login {}
34
35 .login #nav a {
36 color:#fff !important;
37 color:#fff;
38 }
39
40 #login h1 {
41 display:none;
42 } 6 }
43 7
8 class Branding_Actions {
9 public static function admin_print_styles() {
10 _enqueue_style('branding-style', plugins_url('css/tenzing.css', __FILE__));
11 }
44 12
45 #login form { 13 public static function admin_head() {
46 -moz-border-radius: 0px; 14 global $current_user;
47 -khtml-border-radius: 0; 15 get_currentuserinfo();
48 -webkit-border-radius: 0;
49 -moz-box-shadow:none;
50 -webkit-box-shadow: none;
51 -khtml-box-shadow: none;
52 box-shadow: none;
53 border-radius: 0px;
54 border: none;
55 background : transparent;
56 margin-left:0px;
57
58 }
59 form { margin-left:0px;}
60 form {
61 padding: 0px 16px 40px;
62 }
63 16
64 #login_error, .message { 17 include('views/header.php');
65 -moz-border-radius: 0px; 18 }
66 border:none;
67 margin: 0 8px 16px 8px;
68 border:1px solid #f7bd55;
69 background-color:#b197ad;
70 }
71 .updated, .login .message {
72 background-color:#b197ad;
73 color:#fff;
74 }
75 19
76 label { 20 public static function admin_footer() {
77 color: #f7bd55; 21 include('views/footer.php');
78 font-size:11px; 22 }
79 }
80 23
81 #nav { 24 public static function login_head() {
82 text-shadow:none; 25 echo '<link rel="stylesheet" type="text/css" href="' . plugins_url('css/tz_login.css', __FILE__) . '" />';
83 text-shadow:0px; 26 }
84 margin:0;
85 padding:16px;
86 padding-top:0px;
87 } 27 }
88 28
89 html {background-color:#3b0d32;} 29 Branding::make();
90
91 body.login {
92 border-top-color:#3b0d32;
93
94 }
95
96 p#backtoblog { display:block; }
97
98 </style>
99
100
101 ";
102 }
103 30
104 ?> 31 ?>
...\ No newline at end of file ...\ No newline at end of file
......
1 #login {
2 background: #3b0d32 url(../images/tenzing.gif) top right no-repeat;
3 padding-top:70px;
4 }
5
6 #login {}
7
8 .login #nav a {
9 color:#fff !important;
10 color:#fff;
11 }
12
13 #login h1 {
14 display:none;
15 }
16
17
18 #login form {
19 -moz-border-radius: 0px;
20 -khtml-border-radius: 0;
21 -webkit-border-radius: 0;
22 -moz-box-shadow:none;
23 -webkit-box-shadow: none;
24 -khtml-box-shadow: none;
25 box-shadow: none;
26 border-radius: 0px;
27 border: none;
28 background : transparent;
29 margin-left:0px;
30
31 }
32 form { margin-left:0px;}
33 form {
34 padding: 0px 16px 40px;
35 }
36
37 #login_error, .message {
38 -moz-border-radius: 0px;
39 border:none;
40 margin: 0 8px 16px 8px;
41 border:1px solid #f7bd55;
42 background-color:#b197ad;
43 }
44 .updated, .login .message {
45 background-color:#b197ad;
46 color:#fff;
47 }
48
49 label {
50 color: #f7bd55;
51 font-size:11px;
52 }
53
54 #nav {
55 text-shadow:none;
56 text-shadow:0px;
57 margin:0;
58 padding:16px;
59 padding-top:0px;
60 }
61
62 html {background-color:#3b0d32;}
63
64 body.login {
65 border-top-color:#3b0d32;
66
67 }
68
69 p#backtoblog { display:block; }
...\ No newline at end of file ...\ No newline at end of file
1 <div id="TzBrandingHeader"> 1 <div id="TzBrandingHeader">
2 <div id="TzBrandingHeader_UtilityMenu"> 2 <div id="TzBrandingHeader_UtilityMenu">
3 Tenzing Content Management System v1.0<br /> 3 Tenzing CMS built on WordPress<br />
4 Howdy, 4 Howdy,
5 <a href="<?php echo get_settings('siteurl');?>/wp-admin/profile.php"><?php 5 <a href="<?php echo get_settings('siteurl');?>/wp-admin/profile.php"><?php
6 if (isset($current_user->user_firstname)){ 6 if (isset($current_user->user_firstname)){
7 get_currentuserinfo(); echo($current_user->user_firstname); 7 echo($current_user->user_firstname);
8 } else { 8 } else {
9 get_currentuserinfo(); echo($current_user->user_login); 9 echo($current_user->user_login);
10 } 10 }
11 ?></a> | <a href="<?php echo wp_logout_url(); ?>">Log Out</a> 11 ?></a> | <a href="<?php echo wp_logout_url(); ?>">Log Out</a>
12 </div> 12 </div>
......