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
<IfModule mod_rewrite.c> | |
Options -MultiViews | |
RewriteEngine On | |
# Redirect Trailing Slashes... | |
RewriteRule ^(.*)/$ /$1 [L,R=301] | |
# Force https |
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
function init_custom_routes() { | |
// Map a route to a function. Don't use a beginning or trailing / | |
$routes = array( | |
'gform/save' => 'custom_save_process', | |
); | |
$request_uri = trim($_SERVER['REQUEST_URI'], '/'); | |
// Try to call the a function named the same as the value in the routes array. |
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
'/^(https?:\/\/)?([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w \.-]*)*\/?$/' |
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 | |
/** | |
* WordPress Query Comprehensive Reference | |
* Compiled by luetkemj - luetkemj.com | |
* | |
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters | |
* Source: https://core.trac.wordpress.org/browser/tags/3.9/src/wp-includes/query.php | |
*/ | |
$args = array( |
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
; Commands for setting up new drupal site | |
; --------------- | |
; mkdir newsite | |
; cd newsite | |
; drush make ../GA_Drupal.make -y | |
; drush site-install standard --db-url=mysql://root:root@localhost/local_newsite --site-name=NewSite --account-name=admin --account-pass=password | |
; ---------------- | |
; ---------------- | |
; Generated makefile from http://drushmake.me |
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
Array | |
( | |
[hook_menu] => 6744 | |
[hook_uninstall] => 4742 | |
[hook_perm(ission)] => 4012 | |
[hook_install] => 3751 | |
[hook_theme] => 3525 | |
[hook_schema] => 3003 | |
[hook_help] => 2465 | |
[hook_form_alter] => 2273 |
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
// CUSTOM ADMIN LOGIN HEADER LOGO | |
function my_custom_login_logo() | |
{ | |
echo '<style type="text/css"> h1 a { background-image:url('.get_bloginfo('template_directory').'/images/logo-connect.png) !important; margin-bottom:50px; background-size: 206px 69px !important; height: 90px !important; } </style>'; | |
} | |
add_action('login_head', 'my_custom_login_logo'); |
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
//Boostrap Drupal in standalone script file to access drupal functions | |
define('DRUPAL_ROOT', getcwd()); | |
require_once './includes/bootstrap.inc'; | |
drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL); |
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
//Run make file | |
drush make-generate drupaldev.make name_of_directory | |
//Site install | |
drush site-install standard --account-name=admin --account-pass=admin --db-url=mysql://root:root@localhost/YourMySQLDatabase | |
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
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteCond %{HTTP_HOST} ^example.com$ [OR] | |
RewriteCond %{HTTP_HOST} ^www.example.com$ [NC] | |
RewriteRule ^(.*)$ http://www.redirecttopage.com [L,R=301] | |
RewriteBase / | |
</IfModule> |
NewerOlder