Articles of markup

Adding JSON Structured Data to WordPress

I’d like to add some Structured Data, following Google’s recommendations. Following the instructions on their site, it says: Markup is placed inside a script tag in the head of the HTML page. The markup does not have to be interleaved with the user-visible text, which makes nested data items easier to express, such as the […]

Remove 'rel' attributes from the_category() output

I am trying to get the categories associated with a post in it’s meta section by using the following code: <div>FILED AS: <span class=”gf-post-meta-result”><?php the_category(‘ &bull; ‘) ?></span></div> WordPress is generating the markup as: <div>FILED AS: <span class=”gf-post-meta-result”> <a href=”http://localhost/test/category/uncategorized/” title=”View all posts in Uncategorized” rel=”category tag”>Uncategorized</a> </span></div> This part rel=”category tag” is making my […]

Cite-Tag for blockquotes

I want to have a cite underneath my blockquote, that has a certain style. “Blockquotes are an essential part of a fancy website.” – Cite The markup should look like this: <blockquote><p>Blockquotes are an essential part of a fancy website.”</p> <cite>Cite</cite></blockquote> But the WYSIWYG-Editor does not offer me the possibility to define a cite for […]

Snippet: Use classes instead of inline styles for text alignment

WordPress’ TinyMCE (WYSIWYG) editor is adding inline stlyes to the markup when you change the text alignment. This behaviour is hard coded in wp-includes/class-wp-editor.php. Can the inline styles be changed to classes instead?

Pinterest Integration Using functions.php

I use a theme to build an portfolio. I´d like to add an pinterest “pin-it button” into the fuctions.php: Facebook, Google+ an Twitter were done, just the pinterest won´t work. Can´t found the the wrong code. This ist my code: function share_this($content){ if ( is_singular( ‘portfolio’ ) ) { $content .= ‘<div class=”share-this”>’ . /* […]

Comment Reply javascript

I am working on a client site which is a very stripped down theme. It has no standard html markups as a result of which the reply box doesn’t move upto the place of being just below the comment to which you hit the reply button. Can anyone point me to the minimum markup required? […]

How can I alter the markup?

I would like to change the markup created by from what is it as standard (dl) to a unordered-list with a difference. Below is the desired markup: <ul> <li><a href=”/path/to/image.jpg”><img src=”/path/to/image.jpg” /></a></li> <li><a href=”/path/to/image2.jpg”><img src=”/path/to/image2.jpg” /></a></li> <!– And so on, all in one ul –> </ul> I want the main image source for the link […]