Title: [Plugin: Codestyling Localization] Problem with encoded tab character
Last modified: August 20, 2016

---

# [Plugin: Codestyling Localization] Problem with encoded tab character

 *  Resolved [Alexander Gieg](https://wordpress.org/support/users/alexgieg/)
 * (@alexgieg)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/plugin-codestyling-localization-problem-with-encoded-tab-character/)
 * I noticed a bug that I think is related to [my previously reported one](http://wordpress.org/support/topic/plugin-codestyling-localization-bug-when-original-string-ends-in-apostrophe).
   Sometimes an original string has an encoded tab character `\t`. If I try including
   it in the translation, CSL converts it to `\\t`, causing a literal slash-followed-
   by-t to be output rather than the actual tab character. The workaround is to 
   not include it, causing pure textual output to become misaligned.
 * [http://wordpress.org/extend/plugins/codestyling-localization/](http://wordpress.org/extend/plugins/codestyling-localization/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [codestyling](https://wordpress.org/support/users/codestyling/)
 * (@codestyling)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/plugin-codestyling-localization-problem-with-encoded-tab-character/#post-3057394)
 * Please provide a code snippet out of!
    It dependends on how it’s done.
 *  Thread Starter [Alexander Gieg](https://wordpress.org/support/users/alexgieg/)
 * (@alexgieg)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/plugin-codestyling-localization-problem-with-encoded-tab-character/#post-3057401)
 * Sorry for the delay in replying. No, what I meant wasn’t in the code, but in 
   the editing. For example, let’s say an original string is like this (I’ll type[
   tab] where a tab character should appear:
 * `[tab]Something something something.`
 * This appears in the CSL translatable string as:
 * `\tSomething something something.`
 * So, I translated it by typing these exact characters:
 * `\tTranslated text translated text.`
 * And save. But CSL, instead of storing the typed ‘\t’ as a tab character, saves
   it as a slash-followed-by-a-t, meaning internally it becomes this:
 * `\\tTranslated text translated text.`
 * And thus, when WordPress finally displays this string, it appears in the rendered
   output as:
 * `\tTranslated text translated text.`
 * And not as it should, which would be:
 * `[tab]Translated text translated text.`
 * The workaround then is to translate this:
 * `\tSomething something something.`
 * To this:
 * `Translated text translated text.`
 * What causes the output on, for example, `pre`-wrapped sections, to become misaligned.
   Or maybe to this:
 * `&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Something something something.`
 * Which, although it’ll appear right, isn’t semantically the same.
 * I hope this helps!
 *  Plugin Author [codestyling](https://wordpress.org/support/users/codestyling/)
 * (@codestyling)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/plugin-codestyling-localization-problem-with-encoded-tab-character/#post-3057403)
 * This is a known bug, not yet solved. The WordPress main file contains also a \
   t character but doesn’t meen [TAB] with it.
    It’s not that easy to solve this
   at all occurances, will be handled with later updates. Next update will fix some
   bugs introduced during WP 3.5 compatibility.
 *  Plugin Author [codestyling](https://wordpress.org/support/users/codestyling/)
 * (@codestyling)
 * [13 years, 5 months ago](https://wordpress.org/support/topic/plugin-codestyling-localization-problem-with-encoded-tab-character/#post-3057410)
 * Improved TAB charactor handling won’t make it into 1.x versions from now on because
   the 2.0 reaches beta state soon. This will be handled with scope of 2.0 version
   only.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘[Plugin: Codestyling Localization] Problem with encoded tab character’
is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/codestyling-localization_e6e1e3.svg)
 * [Codestyling Localization](https://wordpress.org/plugins/codestyling-localization/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/codestyling-localization/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/codestyling-localization/)
 * [Active Topics](https://wordpress.org/support/plugin/codestyling-localization/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/codestyling-localization/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/codestyling-localization/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [codestyling](https://wordpress.org/support/users/codestyling/)
 * Last activity: [13 years, 5 months ago](https://wordpress.org/support/topic/plugin-codestyling-localization-problem-with-encoded-tab-character/#post-3057410)
 * Status: resolved