Qtranslate-slug

Adds support for permalink translations and fix some QTranslate deficiencies since wordpress 3.0

Qtranslate Slug logo

View the Project on GitHub not-only-code/qtranslate-slug

Description

Qtranslate is a nice plugin but unfortunately today is outdated. Qtranslate Slug is an addon to QTranslate, which adds support for permalinks translations and fix some QTranslate deficiencies since wordpress 3.0.

Version 1.0 has been written from scratch using OOP. The code has been structured better, the functions have been marked and commented and everything is better integrated with Wordpress API.

This plugin works with Qtranslate since 2.5.8.

What is new?

You can also check the project website hosted on GitHub. Thanks for use this plugin!

Installation

This plugins requires Qtranslate installed previously, if not, it will not activate.

  1. Upload qtranslate-slug to the /wp-content/plugins/ directory.
  2. Activate the plugin through the 'Plugins' menu in WordPress.
  3. That's all!

Changing base permastructs

  1. In admin: navigate to Settings/Slug options.
  2. Set the base permastructs for post types and taxonomies (If you setup a base permastruct for categories or tags in Settings/Permalinks, these will be overwritten by the translated ones).
  3. Save settings and that's all!

Frequently Asked Questions

It works with posts and pages, but with other content type?

This plugin allows to translate slugs of: posts, pages, custom post types, categories, tags and custom taxonomies.

Do I have to configure anything?

If you want to translate also the base permastructs (ex. category, tag, etc). Visit the plugin settings page in the admin Settings/Slug options

How can i insert a language selector in my theme ?

You can choose to:

Appears an error 404, what can i do?

In the admin go to Settings/Permalinks or Settings/Slug options and save.

I can't manage translations in Nav Menus.

That's because language selector metabox is hidden, if you are in admin nav menus screen, press the button Screen options (on top and right) and after, check the option Languages. It will appear a Language meta box on top of the left sidebar.

Screenshots

Edit pageEdit page for: post / page / post_type, you can see the meta box for translated slugs on top and right

Taxonomy pageAdd new taxonomy page

Edit taxonomy pageEdit taxonomy page

Options pageQtranslate Slug options page for translate base permastructs of post_types and taxonomies

Changelog

1.0

0.9

0.8

0.7 Zapo

0.5 and 0.6 enhanched by Marco Del Percio

Upgrade Notice

1.0
Major version, the plugin has been rewritten. Better performance, and some enhancements.

0.9
This version fix some bugs and allow multilanguage in nav-menus.

0.8
A lot of slugs content allowed

0.7 This version allows TLD domain option for a different Qtranslate fork maded by Zappo

Other notes

Plugin filters reference:

qts_validate_post_slug

filter to process the post slug before is saved on the database.
args: $post (object), $slug (string), $lang (string)

qts_validate_term_slug

filter to process the term slug before is saved on the database.
args: $term (object), $slug (string), $lang (string)

qts_url_args

filter to process the entire url after it has been generated.
args: $url (string), $lang (string)

qts_permastruct

filter to process the permastruct, used for change the base.
args: $permastruct (string), $name (string)

Todo