View woocommerce-lightbox-aktivieren.php
<?php | |
add_action( 'after_setup_theme', 'name_des_themes' ); | |
function name_des_themes() { | |
add_theme_support( 'wc-product-gallery-zoom' ); | |
add_theme_support( 'wc-product-gallery-lightbox' ); | |
add_theme_support( 'wc-product-gallery-slider' ); | |
} |
View kurzlink-im-header.php
function kurzlink() { | |
echo "<link rel='alternate shortlink' href='" . wp_get_shortlink() . "' />"; | |
} | |
add_action('wp_head','kurzlink'); |
View kurzlink.php
// Kurzlink in WP zurückholen | |
if ( function_exists( 'add_filter' ) ) { | |
add_filter( 'get_shortlink', function ( $shortlink ) { | |
return $shortlink; | |
} ); | |
} |
View dachzeile-benutzerdefiniertes-feld.php
<?php $unterzeile = get_post_meta($post->ID, 'unterzeile', true); | |
if ($unterzeile) { ?> | |
<div class="unterzeile"> | |
<?php echo $unterzeile; ?> | |
</div> | |
<?php } ?> |
View auszug-als-dachzeile.php
<?php | |
// Code für die Überschrift und die Metadaten | |
if(!empty($post->post_excerpt)) { | |
echo '<div class="auszug">'; | |
the_excerpt(); | |
echo '</div>'; | |
} | |
// Code für die Ausgabe des Haupttextes |
View .htaccess
# Dateien cachen | |
<FilesMatch "\.(ico|jpg|jpeg|png|gif|js|css|swf)$"> | |
ExpiresActive on | |
ExpiresDefault "access plus 35 days" | |
Header unset ETag | |
FileETag None | |
</FilesMatch> |
View .htaccess
# mod_deflate aktivieren | |
<FilesMatch "\\.(js|css|html|htm|php|xml|svg)$"> | |
SetOutputFilter DEFLATE | |
</FilesMatch> |
View .htaccess
# Zugriff auf die xmlrpc.php unterbinden | |
<files xmlrpc.php> | |
Order deny,allow | |
deny from all | |
</files> |
View jetpack-js-gravatar-entfernen.php
<?php | |
// Jetpack-JS für Gravatar entfernen | |
function dequeue_devicepx() { | |
wp_dequeue_script( 'devicepx' ); | |
} | |
add_action( 'wp_enqueue_scripts', 'dequeue_devicepx', 20 ); |
NewerOlder