Lipyantar Slugs

설명

When a post title is written in Gujarati or Devanagari, WordPress builds its URL from percent-encoded bytes. “ગુજરાતી સમાચાર” becomes %e0%aa%97%e0%ab%81%e0%aa%9c..., which is long, hard to read and awkward to share.

Lipyantar Slugs transliterates these letters into Latin while the slug is created (“lipyantar” means transliteration in Gujarati and Hindi):

  • ગુજરાતી સમાચાર gujarati-samachar
  • નવરાત્રી ૨૦૨૬ navratri-2026
  • हिंदी समाचार hindi-samachar
  • प्रधानमंत्री pradhanmantri
  • गणपती बाप्पा मोरया ganpati-bappa-morya

It works for:

  • Post, page and custom post type slugs
  • Category, tag and custom taxonomy term slugs
  • Names of uploaded media files

Supported scripts in this version: Gujarati and Devanagari (Hindi, Marathi and other languages written in Devanagari).

The plugin has no settings. Activate it and new slugs are created in Latin.

How it works

The letters are converted by rules, not by a word list, so any word is handled. The hidden “a” of a consonant is dropped where it is not pronounced (navratri, garba), and Gujarati and Devanagari digits become 0–9. A short built-in list fixes a few common words that the rules would spell differently, such as gujarati and vadodara.

Nothing is sent to any external service and nothing is stored in the database.

Existing URLs are not changed

Only new slugs are affected. Slugs that already exist keep working, and a slug you type yourself in Latin letters is left as it is. To give an existing post a Latin slug, clear its URL slug and save the post again.

For developers

Add or change whole-word spellings with the lipyantar_slugs_exceptions filter:

add_filter( 'lipyantar_slugs_exceptions', function ( $words ) {
    $words['સુરત'] = 'surat';
    return $words;
} );

설치

  1. Upload the lipyantar-slugs folder to /wp-content/plugins/, or install it from the Plugins screen.
  2. Activate the plugin.
  3. Write a post with a Gujarati, Hindi or Marathi title. The slug is created in Latin.

FAQ

Will my old links break?

No. Existing slugs are not changed.

A word is spelled differently from how I would write it. What can I do?

Edit the slug of that post as usual, or add the word with the lipyantar_slugs_exceptions filter.

Does it translate the title?

No. It transliterates: the words stay the same, only the letters change.

Which languages are supported?

Gujarati and languages written in Devanagari, such as Hindi and Marathi. Other Indian scripts may be added in future versions.

후기

이 플러그인에 대한 평가가 없습니다.

기여자 & 개발자

“Lipyantar Slugs”(은)는 오픈 소스 소프트웨어입니다. 다음의 사람들이 이 플러그인에 기여하였습니다.

기여자

자국어로 “Lipyantar Slugs”(을)를 번역하세요.

개발에 관심이 있으십니까?

코드 탐색하기는, SVN 저장소를 확인하시거나, 개발 기록을 RSS로 구독하세요.

변경이력

1.0.0

  • First release.