Finishing this guide you'll get:
- A running WordPress installation
- Nginx proxy with PHP and Fast CGI
- MySQL server accessible with phpMyAdmin
Specification of latest running installation:
- Date: 03.03.2014
| { | |
| "basics": { | |
| "name": "Jose Carlos Pajuelo Sh.", | |
| "picture": "https://jcpsh.xyz/img/jcpsh.jpg", | |
| "label": "Web Developer", | |
| "headline": "", | |
| "summary": "", | |
| "website": "https://jcpsh.xyz", | |
| "projects_url": "https://jcpsh.xyz/projects", | |
| "username": "josecarlospsh", |
| // JS for grabbing utm params and parsing into url | |
| var getRefQueryParam = function() { | |
| var temp = {}; | |
| document.location.search.replace(/\??(?:([^=]+)=([^&]*)&?)/g, function() { | |
| var decode = function(s) { | |
| return decodeURIComponent(s.split("+").join(" ")); | |
| }; | |
| temp[decode(arguments[1])] = decode(arguments[2]); | |
| }); | |
| return temp; |
| <?php | |
| function get_page_id_by_slug( $page_slug ) { | |
| $page = get_page_by_path( $page_slug ); | |
| if ( $page ) { | |
| return $page->ID; | |
| } else { | |
| return null; | |
| } | |
| } | |
| ?> |
| <?php | |
| //add following line to your wp-config.php file | |
| define( 'WPCF7_AUTOP', false ); | |
| ?> |
| <?php | |
| /*Remove <span></span> tag from Contact Form 7*/ | |
| add_filter('wpcf7_form_elements', function($content) { | |
| $content = preg_replace('/<(span).*?class="\s*(?:.*\s)?wpcf7-form-control-wrap(?:\s[^"]+)?\s*"[^\>]*>(.*)<\/\1>/i', '\2', $content); | |
| $content = str_replace('<br />', '', $content); | |
| return $content; | |
| }); | |
| ?> |
| <?php | |
| function my_custom_submenu() { | |
| global $post; | |
| $menu_items = wp_get_nav_menu_items('Menu'); | |
| $current_menu_id = 0; | |
| // get current top level menu item id | |
| foreach ( $menu_items as $item ) { |
Finishing this guide you'll get:
Specification of latest running installation: