Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 65 lines (56 sloc) 1.76 kb
38feed9 @saltcod Changes to index.html
authored
1 <!doctype html>
2 <html lang="en">
3 <head>
4 <meta charset="utf-8">
5 <title>Terry's Github Page</title>
6 <meta name="description" content="The HTML5 Herald">
7 <meta name="author" content="SitePoint">
8 <link rel="stylesheet" href="css/styles.css?v=1.0">
9 <!--[if lt IE 9]>
10 <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
11 <![endif]-->
12 </head>
13 <body>
19ffc7e @saltcod Site title
authored
14 <h1>WordPress tips that won't quit</h2>
738b116 @saltcod added wordpress maintence mode code
authored
15 <h2> Maintenance Mode</h2>
8d35056 @saltcod added wordpress maintence mode code
authored
16 <pre>
17 function wpr_maintenance_mode() {
18 if ( !current_user_can( 'edit_themes' ) || !is_user_logged_in() ) {
19 wp_die('Maintenance, please come back soon.');
20 }
21 }
22 add_action('get_header', 'wpr_maintenance_mode');
23 </pre>
7ee4458 @saltcod i am sam
authored
24
a189f1d @saltcod Added a single page query.
authored
25
26 <h2>Query a single page</h2>
27 <pre>
28 <?php $my_query = new WP_Query("showposts=1&post_type=page&page_id=31");
29 while ($my_query->have_posts()) : $my_query->the_post();
30 $do_not_duplicate = $post->ID; ?>
31 <?php the_content(); ?>
32 <?php endwhile; ?>
33 </pre>
b1bf865 @saltcod Added maintence mode code
authored
34
ded64ed @saltcod Added maintence mode code
authored
35 <h2>Maintenance Mode</h2>
b1bf865 @saltcod Added maintence mode code
authored
36 <pre>
37 function wpr_maintenance_mode() {
38 if ( !current_user_can( 'edit_themes' ) || !is_user_logged_in() ) {
ded64ed @saltcod Added maintence mode code
authored
39 wp_die('<h2>Maintenance </h2><p>Doing a small upgrade, please come back in about an hour!');
b1bf865 @saltcod Added maintence mode code
authored
40 }
41 }
42 add_action('get_header', 'wpr_maintenance_mode');
43 </pre>
44
4db1af2 @saltcod Add git command for removing a file
authored
45 <h2>Remove wp-config.php after creating .gitignore</h2>
46 git rm --cached wp-config.php
a189f1d @saltcod Added a single page query.
authored
47
0d6923e @saltcod TextMate shortcut section
authored
48
49 <h2> TextMate Shortcuts</h2>
50 Insert close tag
51 Opt + Cmd + .
52 Move selection
53 Ctrl + Cmd and use the arrow keys to move the text up and down or left and right
54 Wrap selection in open/close tag
55 Ctrl + Shift + W
56 Wrap multiple lines in separate elements
57 Ctrl + Shift + Cmd + W
58 Wrap Word/Selection as Link
59 Ctrl + Shift + L
60
61
38feed9 @saltcod Changes to index.html
authored
62 <script src="js/scripts.js"></script>
63 </body>
64 </html>
Something went wrong with that request. Please try again.