Skip to content

Instantly share code, notes, and snippets.

d.iframe.one("load", function () {
f = true;
if (g) {
e.resolveWith(d)
} else {
setTimeout(function () {
e.rejectWith(d, ["ready timeout"])
}, d.sensitivity)
}
});
<?php
function create_rewrites() {
add_rewrite_rule(
'pamelding/([^/]+)/?$',
'index.php?pagename=pamelding&courseid=$matches[1]',
'top'
);
add_rewrite_rule(
'kursdetaljer/([^/]+)/([^/]+)/?$',
'index.php?pagename=kursdetaljer&courseid=$matches[1]',
<?php
function breadcrumbs() {
if( ! is_home() ){
global $post;
?>
<a href="<?php bloginfo( 'wpurl' ); ?>">Home</a> &raquo;
<?php $parent = $post->post_parent;
$parent_title = get_the_title( $parent );
echo '<a href="'.get_permalink( $parent ) .'">' . $parent_title . ( '' ); ?> </a> &raquo;
<?php the_title( '' ); ?>
@Clorith
Clorith / gist:5254369
Created March 27, 2013 14:02
WordPress default .htaccess
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /wordpress_clean/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /wordpress_clean/index.php [L]
</IfModule>