This file contains 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
# | |
# Sources: | |
# http://stackoverflow.com/questions/7704624/how-can-i-use-gzip-compression-for-css-and-js-files-on-my-websites | |
# http://codex.wordpress.org/Output_Compression | |
# http://www.perun.net/2009/06/06/wordpress-websites-beschleuinigen-4-ein-zwischenergebnis/#comment-61086 | |
# http://www.smashingmagazine.com/smashing-book-1/performance-optimization-for-websites-part-2-of-2/ | |
# http://gtmetrix.com/configure-entity-tags-etags.html | |
# http://de.slideshare.net/walterebert/die-htaccessrichtignutzenwchh2014 | |
# http://de.slideshare.net/walterebert/mehr-performance-fr-wordpress | |
# https://andreashecht-blog.de/4183/ |
This file contains 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 | |
/* http://codex.wordpress.org/Customizing_the_Read_More */ | |
function remove_more_jump_link($link) { | |
$offset = strpos($link, '#more-'); | |
if ($offset) { | |
$end = strpos($link, '"',$offset); | |
} | |
if ($end) { | |
$link = substr_replace($link, '', $offset, $end-$offset); |
This file contains 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 | |
/** | |
* Plugin Name: Threaded Comment Feed Enhancer | |
* Plugin URI: http://torstenlandsiedel.de | |
* Text Domain: threaded-comment-feed-enhancer | |
* Domain Path: /languages | |
* Description: Enhances the threaded comments feed | |
* Version: 1.2.0 | |
* Author: Torstenlandsiedel | |
* Author URI: http://torstenlandsiedel.de |
This file contains 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
# Don't show errors which contain full path diclosure (FPD) | |
# Use that line only if PHP is installed as a module and not per CGI | |
# try using a php.ini in that case. | |
# Change mod_php5.c to mod_php7.c if you are running PHP7 | |
<IfModule mod_php5.c> | |
php_flag display_errors Off | |
</IfModule> | |
# Don't list directories | |
<IfModule mod_autoindex.c> |
This file contains 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 | |
function twentytwelve_child_scripts() { | |
wp_deregister_style( 'twentytwelve-style' ); | |
wp_register_style( 'twentytwelve-style', get_template_directory_uri() . '/style.css' ); | |
wp_enqueue_style( 'twentytwelve-child-style', get_stylesheet_uri(), array( 'twentytwelve-style' ) ); | |
} | |
add_action( 'wp_enqueue_scripts', 'twentytwelve_child_scripts', 11 ); |
This file contains 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 | |
function tl_umlaut_repair( $content ) { | |
/* | |
* Why? | |
* For everyone getting this warning from W3C: "Text run is not in Unicode Normalization Form C." | |
* http://www.w3.org/International/docs/charmod-norm/#choice-of-normalization-form | |
*/ | |
/* |
This file contains 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 | |
add_filter('comment_form_default_fields', 'url_filtered'); | |
function url_filtered($fields) | |
{ | |
if(isset($fields['url'])) | |
unset($fields['url']); | |
return $fields; | |
} |
This file contains 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 | |
function md_filter_curly_double_quotes( $translations, $text, $context, $domain ) { | |
if ( 'opening curly double quote' == $context && '“' == $text ) { | |
$translations = '„'; | |
} else if ( 'closing curly double quote' == $context && '”' == $text ) { | |
$translations = '“'; | |
} | |
return $translations; |
This file contains 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 | |
/* | |
Plugin Name: Show PHP Version | |
Description: Shows the current PHP version in the "At a Glance" admin dashboard widget. | |
Version: 1.1 | |
Requires at least: 3.8 | |
Author: Torsten Landsiedel | |
Author URI: http://torstenlandsiedel.de | |
*/ |
This file contains 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
// Disabling the plugin and theme editor for more security | |
define('DISALLOW_FILE_EDIT', true); | |
// Check for a local config file | |
if ( file_exists( dirname( __FILE__ ) . '/wp-local-config.php' ) ) { | |
/* Get the settings for the development site */ | |
include( dirname( __FILE__ ) . '/wp-local-config.php' ); | |
} else { | |
// Settings for live site |
OlderNewer