• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

loading call for the textdomain

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Internationalization and Translations › loading call for the textdomain

This topic is: not resolved

Tagged: genesis init line, textdomain

  • This topic has 7 replies, 3 voices, and was last updated 10 years ago by Roeland.
Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • January 29, 2013 at 4:11 pm #16151
    Roeland
    Member

    Hi I'am Roeland,

    And i'am trying to translate the agentpress theme.

    David Decker said on the old forum

    That's because search results are handled by the theme template files. So you have to use translation files for the AgentPress child theme as well!

    It's prepared for translation but has no loading call for the textdomain. You can add that yourself to functions.php file (backup file before!):

    PHP Code:
    /** Localization */
    load_child_theme_textdomain( 'agentpress', get_stylesheet_directory() . '/lib/languages' );

    -> place directly after genesis init line
    -> create a subfolder wp-content/themes/agentpress/lib/languages/
    -> place your language files there as: nl_NL.mo and nl_NL.po

    I have created the folder, and the mo an po files. But i don't know where to place te PHP Code: What is the genesis init line in the functions.php?

    January 29, 2013 at 5:30 pm #16196
    SoZo
    Member

    The init line he is referring to is at the top of functions.php

    <?php
    /** Start the engine */
    require_once( get_template_directory() . '/lib/init.php' );

    John “Nicolas Flamel” Wright | SoZo’s design| John Wright Photography

    January 30, 2013 at 3:43 am #16352
    Roeland
    Member

    Tank you so much John!

    I have yet placed it there, But unfortunately it still doesn't work. Do you have any idea what i do wrong?

    <?php
    /** Start the engine */
    require_once( get_template_directory() . '/lib/init.php' );

    /** Localization */
    load_child_theme_textdomain( 'agentpress', get_stylesheet_directory() . '/lib/languages' );

    /** Create additional color style options */
    add_theme_support( 'genesis-style-selector', array( 'agentpress-gray' => 'Gray', 'agentpress-green' => 'Green', 'agentpress-red' => 'Red', 'agentpress-tan' => 'Tan' ) );

    /** Child theme (do not remove) */
    define( 'CHILD_THEME_NAME', 'AgentPress Theme' );
    define( 'CHILD_THEME_URL', 'http://www.studiopress.com/themes/agentpress' );

    $content_width = apply_filters( 'content_width', 600, 430, 920 );

    I'am using a dutch wordpress version and in wp-config.php is writtesn

    define('WPLANG', 'nl_NL')

    This is how i made the folders.

    www/wp-content/themes/agentpress/lib/languages/agentpress-nl_NL.mo
    www/wp-content/themes/agentpress/lib/languages/agentpress-nl_NL.po

    Can there be something wrong with the translation?

    Below a part of the translation

    msgid ""
    msgstr ""
    "Project-Id-Version: AgentPress Two Child Theme 2.x for Genesis Framework\n"
    "Report-Msgid-Bugs-To: http://www.studiopress.com/support/forumdisplay.php?"
    "f=188\n"
    "POT-Creation-Date: 2011-09-27 12:03+0100\n"
    "PO-Revision-Date: \n"
    "Last-Translator: Roeland van Spijk <[email protected]>\n"
    "Language-Team: \n"
    "MIME-Version: 1.0\n"
    "Content-Type: text/plain; charset=UTF-8\n"
    "Content-Transfer-Encoding: 8bit\n"
    "Plural-Forms: nplurals=2; plural=n != 1;\n"
    "X-Poedit-SourceCharset: utf-8\n"
    "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
    "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
    "X-Textdomain-Support: yes\n"
    "X-Generator: Poedit 1.5.4\n"
    "X-Poedit-SearchPath-0: .\n"

    # @ agentpress
    # @ apl
    #: archive-listing.php:33 functions.php:111 taxonomy.php:33
    msgid "View Listing"
    msgstr "Bekijk Aanbod"

    # @ apl
    #: functions.php:75
    msgid "Price:"
    msgstr "Prijs:"

    # @ apl
    #: functions.php:76
    msgid "Address:"
    msgstr "Adres:"

    # @ apl
    #: functions.php:77
    msgid "City:"
    msgstr "Plaats:"

    # @ apl
    #: functions.php:78
    msgid "State:"
    msgstr "Provincie:"

    January 30, 2013 at 3:49 am #16354
    Remkus de Vries
    Member

    The AgentPress theme is already translated to Dutch.


    Translate the Genesis Framework with the Genesis Translations plugin.

    January 30, 2013 at 4:15 am #16357
    Roeland
    Member

    Hoi Remkus,

    You are great! Tanks.

    Now i have placed your translation via FTP in the translations folder.  But it is still not translated.

    Do you have any suggestions?

    Groeten Roeland.

    Yesterday i have read your blog. Now i never want to eat kipnuggets again:)

    January 30, 2013 at 3:53 pm #16518
    Roeland
    Member

    Hi John and/or Remkus,

    I don't know what i do wrong, but my agentpress is still in English.

    Can you help me?

    Blessings,

    Roeland van Spijk

    February 1, 2013 at 2:29 am #17016
    Remkus de Vries
    Member

    In which folder did you place which files? Screenshot of the folder structure and files would help.


    Translate the Genesis Framework with the Genesis Translations plugin.

    February 1, 2013 at 3:30 am #17018
    Roeland
    Member

    Sorry Remkus,

     

    But how do i upload this screenshot.

  • Author
    Posts
Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.
Log In

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble