sciolism

Playing around with technology

Tag archive: Plugin


Categories: Projects

Introducing e.nigma buttons

e.nigma buttons

You all now that: You are using a software which brings a lot of functionality but there is always the one feature that is missing. In WordPress this situation is not as disappointing as for other software because WordPress allows the user to extend its functionality with plugins.

Some weeks ago I started writing on the e.nigma 2015 theme (which is already submitted to the WordPress.org repository but is still in review). Here and there I wanted to extend the theme’s functionality with shortcodes that allow the user to easily add buttons to their blog posts and pages. However, I missed that the WordPress team says1 that custom shortcodes should come with plugins, not with themes. Consequently, I transferred the button functionality to a WordPress plugin: e.nigma buttons.

Read more…

Categories: Technology

Tumblr Crosspostr

Tumblr Crosspostr posts to Tumblr whenever you hit the “Publish” (or “Save Draft”) button. It can import your reblogs on Tumblr as native WordPress posts. It even downloads the images in your Photo posts and saves them in the WordPress Media Library.

Mein persönliches WordPress Plugin der Woche! Wer sich jetzt fragt wofür ich das Plugin brauche: dafür.


Get the Flattr WordPress plugin ready for HTML5

If you are using the Flattr WordPress plugin you can choose between three different modes of button presentation:

If you choose one of the static variants everything is fine using HTML5 markup. Now, if you choose the Dynamic javascript version this will result in an non-valid source code. The reason for that is that the rel attribute is no longer supported in HTML5, what is also said on the Flattr website. However, the fix for that issue is quite simple. Just replace the function getButtonCode (line 644) in the flattr.php in the plugins directory. Note that I don’t check for empty values for the category and the tags field anymore, as my workflow does not include empty categories or tags.

protected function getButtonCode($params) {
  return '
  (!empty($params['title']) ? ' title=" ' . esc_attr($params['title']) . '"' : '') .
  ' data-flattr-uid="' . $params['user_id'] . '"' .
  ' data-flattr-category="' . $params['category'] . '"' .
  ' data-flattr-tags="' . htmlspecialchars($params['tags']) . '"' .
  '>' .
  esc_html(empty($params['description']) ? '' : $params['description']) .
  '</a>';
}

Now your markup should be valid.