Tag Archives: core

Rewrite rules and permalink issues dump

WordPress 404 Permalink Rewrite Problems

Produce a raw dump of some of the core parts that should help shed some light on issues regarding WordPress rewrite rules, permalinks and missing template files when a 404 is encountered. Fork, improve, comment. This is for environments with no fancy IDEs, Xdebug, debug plugins.

Continue reading



WordPress.org APIs

It is no secret that the WordPress Core interacts with remote APIs maintained by WordPress DOT org team. The most direct manifestation of these calls are plugin, theme and Core update notifications, and XML feeds in the Dashboard. Let’s take a look at all (hopefully) of the calls that WordPress is able to make, analyze the protocols and the data being exchanged.

WordPress.org APIs

Continue reading



WordPress trunk news #8

Another great week of WordPress 3.4 development and polishing, with everyone hoping to see beta this week, it has been postponed to later this weekend or sometime next week. 163 tickets (at the time of writing) are assigned to the WordPress 3.4 milestone.

WordPress trunk news #8

Continue reading



WordPress trunk news #7

Sometime this weekend or next week (or maybe next week) WordPress development will feature freeze, meaning no more features will be added. And will be left with more or less some of the features that are expected in WordPress 3.4.

WordPress trunk news 7

Ready. Steady. Go!

Continue reading



WordPress trunk news #6

Today’s been the craziest day I’ve had for quite a long long time. It’s 5AM and I still haven’t done my WordPress trunk roundup for this week. So hot cup of fresh tea ready (by the way, from today on you can hook me up with some tea to keep me going day and night :D), off we go!

WordPress trunk news #6

Continue reading



On WordPress Pingbacks

WordPress supports Pingbacks and these are enabled by default. Having noticed a missing pingback from one of my posts and having made sure that it wasn’t caught as spam or still pending, I decided to investigate a bit and try to resend it manually.

On WordPress Pingbacks

Armed with the Pingback specification, and the XML-RPC RFC, I was able to successfully have a request cURLed over.

curl "http://.../xmlrpc.php" --header "Content-Type: text/xml" --data "<?xmlversion="1.0"?><methodCall><methodName>pingback.ping</methodName><params><param><value><string>http://.../</string></value></param><param><value><string>http://.../</string></value></param></params></methodCall>"

<?xml version="1.0"?>
<methodCall>
   <methodName>pingback.ping</methodName>
   <params>
      <param>
        <value><string>http://.source./</string></value>
      </param>
      <param>
        <value><string>http://.target./</string></value>
      </param>
   </params>
</methodCall>

For which I got a nice response:

<?xml version="1.0"?>
<methodResponse>
  <params>
    <param>
      <value>
      <string>Pingback from http://.source./ to http://.target./ registered. Keep the web talking! :-)</string>
      </value>
    </param>
  </params>
</methodResponse>

Mission accomplished, got the Pingback thorough, great! But what if…?

Continue reading



WordPress Escape Functions

The process of escaping data an important one, since the lack of thereof can lead to XSS and other naughty and unexpected things, among the legit data that just breaks specific data formats.

WordPress Escape Functions

Consider HTML attributes. Imagine you have the following simple code:

$image_src = get_uploaded_image_src(); // not any specific function
echo '<img src="' . $image_src . '" />';

What if the uploaded image is called “Horizons” by LTJ Bukem.jpg? You end up with broken HTML: <img src=""Horizons" by LTJ Bukem.jpg" />… not to worry though, WordPress comes a dozen escape functions for taking care of all these sorts of things. However, with the myriad of escaping functions provided in WordPress, it is often times difficult to remember which is which and whether there is an escape function for a specific case.

Continue reading



WordPress trunk news #5

Last week’s edition of WordPress trunk news provided an overview of some of the major happenings in the very exciting Project Gandalf and the WordPress Theme API.

WordPress Trunk News #5

Here’s what happened in the WordPress trunk this past weekend and this week.

Continue reading



WordPress trunk news #4

Compared to last week’s changesets, this week has seen a little more exciting action throughout the trunk. Moreover, a 20000-commit milestone has been reached this week.

WordPress Trunk News 4

Continue reading



Custom Post Type Archives In WordPress Menus!

You may have read about the Custom Post Type Archives In WordPress Menus dilemma that I brushed over quickly yesterday. Today, after a bit of sleep, I’m ready to publish some concept code that adds Custom Post Type archives to the WordPress-powered menus. It’s going to get dirty, you’ve been warned.

Custom Post Type Archives in WordPress Menus

Continue reading