Blog Software | Miklas Njor

Jetpack related posts and qTranslate-X fix

Problem:
I had some trouble getting Jetpack’s Related Posts to play nice with qTranslate-X. The issue I had, was that Jetpacks Related Posts did not translate the post’s headlines and link title tags, and since this site is mulitlingual and most of the articles are both in Danish and English, this is a big problem.

 Obviously with the many settings in the WordPress eco system, the fault could lie elsewhere, however a lot of switching off of plugins and settings, clearing caches and looking under the hood etc., led me to believe, that the fault is with Jetpack. The fix is pretty simple, except it will be overridden next time I update the plugin, so I have notified the developers of Jetpack.

In line 3, in the code snippet below, the original code is

which means that the posts title is returned to the system and stripped of all HTML tags (syntax). The title is however not internationalised, in the sense that the system doesn’t account for any translations of the post title string.

The solution
The solution is to add __() around the $post_title so the line becomes

The place to make changes is: wp-content/plugins/jetpack/modules/related-posts/jetpack-related-posts.php on line 697 (in version: 20150408 of the plugin)

{ IPTC:Headline | }

A look at two CMS – SilverStripe and Joomla

 Joomla vs silverstripe CMS

SilverStripe: Easy to get a site up and running with a minimum of fuss. Easy to edit content. Changes to menus and navigation is limited, but would work well for minor sites. For larger sites a web developer would have to be hired.
Joomla: very easy to setup and tweek. Most users would find the basic features easy to use. For more advanced features a web developer should be hired.

SilverStripe vs. Joomla

Here is a look at SilverStripe and Joomla.

Target audiences

  SilverStripe Joomla
Target group Beginners and experienced web designers Beginners and experienced web designers
Usage Mostly small-size websites Small and large websites
Typical users Professional and personal http://www.silverstripe.org/comm unity-showcase/ Professional and personal sites. http://community.joomla.org/showcase/

Cost of Operation


  SilverStripe Joomla
CMS Free (Open Source) Free (Open Source)
Themes Unknown Free and Commercial
Modules/Plugins/ Add ons Few but free add ons/modules/themes  

System Requirements & Hosting Environment?

Apache, MySQL and PHP SilverStripe Joomla
Linux AMP Yes Yes
Windows AMP Yes Yes
Mac AMP Yes Yes
X AMP Unknown Yes – but not for live sites
  http://www.silverstripe.org/system-requirements/ http://www.joomla.org/technical-requirements.html

Documentation of SilverStripe and Joomla

SilverStripe Joomla
Pretty straightforward installation. Kind of like WordPress “Famous Five Minute Install”.
Also lots of documentation on http://doc.silverstripe.org – A few dead links
Yes. Plenty on the Joomla site. It is set up as a wiki. There is also a forum.

Content publishing and workflow

  SilverStripe Joomla
How is content published Through a standard WYSIWYG editor. Pages are easily created and can be moved around in the site-tree by drag and drop. Through a standard WYSIWYG editor. Although there is (to me) some confusion as to where content gets placed. There are so many features in Joomla that production of content is almost drowned out.
Workflow Very straightforward workflow with logical constraints. Feels like a steep learning curve because of the many options and supposedly necessary steps before content can be published..

The SilverStripe Navigation/Site-tree

The SilverStripe Navigation/Site-tree.

Publishing Areas of SiverStripe and Joomla

SilverStripe Publishing area

SilverStripe Publishing area.

Joomla publishing area

Joomla publishing area.

User roles and rights

  SilverStripe Joomla
User Roles Admin can create unlimited groups and roles Ten levels from SuperUser to Public. New groups and user levels can be created.
User Rights On/off switches for admin section, modules admin, site content, role management. Very granular permission system. Each user is supplied with a role that matches his function. e.i. editor, author, registered user, Shop owner.

Public Theme vs. Admin Theme

SilverStripe Joomla
Public and admin theme design is very basic out of the box, but the public theme can be modified. Public theme is very advanced out of the box. It can be modified. Admin theme seems very cluttered and but could be a matter of getting used too.

Content: SilverStripe and Joomla

Organisation of content in SilverStripe and Joomla

SilverStripe Joomla
A curious feature of SilverStripe is how it deals with nested pages. A sub-page of a page is added to a sidebar on the “top” page. It is in many ways logical to forcefully add local navigation for the user, although it would be nice with an option to include it in a dropdown of the main navigation. If a page is a “top”-page it will be featured in the main menu unless unchecked. It uses automatically generated, but editable, pretty- permalinks. Joomla gives the content creator great control over how to structure the site’s content. Either by categories or by ordering of the prioritised order (set by user), publishing date, language, hits and who created the content.
Menus can be authored to a very granular level.

How do SilverStripe and Joomla handle images, text and video?

  SilverStripe Joomla
Text WYSIWYG editor only WYSIWYG editor with the option to turn it off. Different levels of sanitising content depending on user role.
Image Media library where you can upload images (one at a time). When you click to insert images in a page, images from the library appear alongside the option to upload images. Images can be upload to a media library
Video Could not get it to work Could not get it to work

Search

SilverStripe Joomla
Silverstripe has something called search in the admin area, but I was unable to insert a search box on the site. Joomla searches text, titles and metadata if there is any. There is automatically a search box inserted on the standard theme.

How is the presentation layer controlled?

SilverStripe Joomla
SilverStripes templates can be transformed to your hearts content. The template syntax is a string process language. See illustration below. Template Design in Joomla is a mix of PHP, XML, HTML templates and tweeks to modules in the admin section. It comes of as being overly complicated.

SilverStripes template syntax

SilverStripes template syntax.

SilverStripe vs. Joomla

What is each CMS good at?

SilverStripe Joomla
SilverStripe is ideal for websites that need to built very fast and don’t need updating too often. Although it has a framwork feel to it, like Drupal, it feels like Drupal without the huff and puff. I’d imagine that if the content is of static nature, many of the sites being built using WordPress or Drupal could be made using SilverStripe. Joomla makes for good use regarding small or big websites. The main focus seems to be on larger sites that need lots of functions and it would perhaps be overkill to use Joomla for smaller- sized sites with static content. The possibilities seem endless.

Aimed at beginners or experts?

  SilverStripe Joomla
Beginners Yes Yes
Experts Yes Yes

System User Interface

SilverStripe Joomla
Pretty basic and crude design of the admin area, but it works and is easy to navigate. Many options of which almost all can be reached via the top menu in the admin section. As pointed out before, Joomla can be finetuned, but it is not always clear what functions do and where they are controlled.

Do SilverStripe and Joomla do what is says on the box?

SilverStripe Joomla
Easy to get a site up and running with a minimum of fuss. Easy to edit content. Changes to menus and navigation is limited, but would work well for minor sites. For larger sites a web developer would have to be hired. I installed the CMS via Joomla’s cloudservice which allows for 30 days free hosting with the option to export the setup and go elsewhere afterwards, or stay on and pay a hosting fee.
It seems very easy to setup and tweek and I’m sure most users would find the basic features easy to use. For more advanced features a web developer should be hired.