WordPress.org

Ready to get started?Download WordPress

Forums

Bogo
[resolved] Add current language as a body class (4 posts)

  1. Jordan Wellington Lint
    Member
    Posted 1 year ago #

    Hi,

    I would like to know if it's possible to add the current language to the body class. For example: <body class="en">

    Thnak you!

    http://wordpress.org/extend/plugins/bogo/

  2. Takayuki Miyoshi
    Member
    Plugin Author

    Posted 1 year ago #

    You already have it. If you don't see it, probably your theme has problems. Try with the default theme.

  3. Jordan Wellington Lint
    Member
    Posted 1 year ago #

    Thank you, Takayuki! I really love your plugin! Thank you for maintaining it as simple as powerful and beautiful. :)

    I just found the plugin uses the body_function so I added <?php body_class($class); ?> to the body tag and now it works! Thank you for pointing it out! I build my themes from scratch and that's the reason the function wasn't there. Anyway, this is solved!

    I have another problem: URL (pages?) for languages other than the default doesn't work. For example, mydomain.com/es or mydomain.com/de show a Not Found. That's because I'm missing something necessary in my theme? I don't have a page.php... that's the reason? I checked the .htaccess rewrite rules and everything is fine.

    Thank you for your support!

  4. Takayuki Miyoshi
    Member
    Plugin Author

    Posted 1 year ago #

    Please open a new topic for another question.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic