Skip to content

Language switcher is missing. #16

@richardevcom

Description

@richardevcom

After including the file like this in main theme (i'm not using child theme) functions file like this (i'm using predefined constants with full directory addresses):
require_once(PN_LIBRARIES_DIR . '/customizer-polylang/customizer-polylang.php');
the language switcher is missing.

[UPDATE]
In Console i get this error:

Loading failed for the <script> with source “http://localhost/project/back-end/wp-content/themes/project/js/customizer-polylang.js?ver=1438771592”. customize.php:1602:1
ReferenceError: PSPolyLang is not defined

If I change 246 line in customizer-polylang.php to also use constant with full directory URL like so:
$src = PN_LIBRARIES_URL . '/customizer-polylang/js/customizer-polylang.js';
Then I get it working.

Is this issue because I'm using it in main theme and not in child theme?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions