Articles of markup

Calling PHP Titles inside Javascript Markup

I have a video gallery, and all the titles are generated by php. They are coming from my WordPress media library’s attachment titles. The lightbox for these videos, however, is customized in javascript. How can I put the php titles inside the iframe markup? PHP – need to use $attachment_data[‘title’]: <?php $the_query = new WP_Query(array( […]

Modifying the markup in the Tag Cloud widget?

I need to modify the markup of the tag cloud widget. Can someone tell me how to go about doing this without modifying any of the files outside of the theme directory so my changes don’t get overwritten when updating WordPress?

Create custom markup to use in posts?

Is there some way – a plugin, a technique, some file to edit – to define some custom markup to be interpreted, parsed and replaced with custom, generated content when generating posts? The simplest example of what I want would be smileys, getting a 🙂 or in text of the post replaced by a specific […]

Rewrite inline image markup

Is there a way of writing a function that will replace the standard markup of an inline image within the_content, with a way that moves the size class to a parent container, and a series of data attributes for different sizes of the image? I’ve tried using a preg_match function, originally written to remove the […]

How can I get WordPress to save comments in markdown format?

I love markdown, and I have the WordPress markdown-for-wordpress-and-bbpress parsing markdown in my posts and comments. However, I’ve noticed that WordPress saves the comments rendered in html format. This makes it more difficult to go back and edit comments. How can I get wordpress to save comments in markdown format? I couldn’t find a plugin […]

Make wp_link_pages() suitable for Twitter Bootstrap markup

Below there’s the WordPress code found in post-template.php for the wp_link_pages() function – this function generates a page navigation for posts or pages having the content split into multiple pages. function wp_link_pages($args = ”) { $defaults = array( ‘before’ => ‘<p>’ . __(‘Pages:’), ‘after’ => ‘</p>’, ‘link_before’ => ”, ‘link_after’ => ”, ‘next_or_number’ => ‘number’, […]

ShortCode and extra </p>

[box id=’1′ text=”some texte”] the shortcode, at one point is outputting text the html result is : </p> some text </p> There is an extra closing paragraph in the start and and opening at the end… WHY ? where those come from ?…. any idea ?.. it screw my w3 validation ! ** note i […]

Following WordPress Markup Is mandatory, got awkward resultyby wordpress standard markup?

I had used the standard wordpress class entry-title, entry-meta etc, First my theme worked well later all at once the width changed vigorously. Do WordPress generate css properties or can i use my custom markup for posts loop or is it mandatory to follow.

Using Schema with `the_excerpt`

I’m currently developing a WordPress site and want to use Schema, I have been some what successful so far but have now hit a stone wall. I want to use: itemprop=”description” to the <p>the_exerpt</p>. Since I was able to the itemprop easily to the_post_thumbnail using: <?php the_post_thumbnail(‘post-thumbnail’,array(‘itemprop’=>’image’)); ?> I assumed this would be a easy […]

Add itemprop Schema.org Markup to li Elements in wp_nav_menu

I currently call menus with a basic wp_nav_menu code: <?php wp_nav_menu( array(‘theme_location’ => ‘primary’) ); ?> I am trying to find the easiest way to add itemprop=”url” to the line elements for the purpose of Schema.org markup. However, all of the codes I have found seem overly complex. Any help is greatly appreciated. Is there […]