soflyy / oxygen-bugs-and-features

Bug Reports & Feature Requests for Oxygen
https://oxygenbuilder.com/
316 stars 31 forks source link

Support for WPML plugin #938

Open raykai opened 4 years ago

raykai commented 4 years ago

Describe the feature you'd like to see included in Oxygen. Support for WPML https://wpml.org plugin would be good to have for Oxygen

What are the use cases for this feature? Language Accessibility

Examples of this feature or functionality. It would allow users to use more than one language on their sites when they build using Oxygen. I live in a country where we need two languages on our sites so having support for WPML is almost a must for us.

marcorubiol commented 2 years ago

We need that

spinoWeb2 commented 2 years ago

+1

d-packs commented 2 years ago

In order to see translated templates when not logged in, modify /component-framework/admin/cpt-template.php. Please note that this will make the templates publicly_queryable.

...
function ct_add_templates_cpt() {

- if(!oxygen_vsb_current_user_can_access()) {
-     return;
- }

  $labels = array(
      'name'               => _x( 'Templates', 'post type general name', 'component-theme' ),
       ...

Instead of removing that block, you can move it two blocks lower, after the $args definition and replace its content to make sure the templates are not publicly queryable and don't have a publicly accessible archive. But even better you don't touch Oxygen's code because you lose the changes on update.

Luckily ct_add_templates_cpt() is being called via a hook. so we just need to unhook it and hook our modified function instead. So simply paste this code in your own plugin or via your own method of adding custom code to Oxygen:

add_action( 'plugins_loaded', 'myslug_oxy_loaded' );
function myslug_oxy_loaded() {
    remove_action( 'init', 'ct_add_templates_cpt' );
    add_action( 'init', 'myslug_ct_add_templates_cpt' );
}

function myslug_ct_add_templates_cpt() {

    $labels = array(
        'name'               => _x( 'Templates', 'post type general name', 'component-theme' ),
        'singular_name'      => _x( 'Template', 'post type singular name', 'component-theme' ),
        'menu_name'          => _x( 'Templates', 'admin menu', 'component-theme' ),
        'name_admin_bar'     => _x( 'Template', 'add new on admin bar', 'component-theme' ),
        'add_new'            => _x( 'Add New Template', 'template', 'component-theme' ),
        'add_new_item'       => __( 'Add New Template', 'component-theme' ),
        'new_item'           => __( 'New Template', 'component-theme' ),
        'edit_item'          => __( 'Edit Template', 'component-theme' ),
        'view_item'          => __( 'View Template', 'component-theme' ),
        'all_items'          => __( 'Templates', 'component-theme' ),
        'search_items'       => __( 'Search Templates', 'component-theme' ),
        'parent_item_colon'  => __( 'Parent Templates:', 'component-theme' ),
        'not_found'          => __( 'No templates found.', 'component-theme' ),
        'not_found_in_trash' => __( 'No templates found in Trash.', 'component-theme' )
    );

    $args = array(
        'exclude_from_search' => true,
        'labels'              => $labels,
        'public'              => true,
        'publicly_queryable'  => true,
        'has_archive'         => true,
        'show_ui'             => true,
        'show_in_menu'        => 'ct_template',
        'rewrite'             => false,
        'query_var'           => true,
        'capability_type'     => 'post',
        'hierarchical'        => false,
        'menu_position'       => null,
        'supports'            => array( 'title' )
    );
    // We add back our logged in user check and make sure the template is not publicly queryable, 
    // nor does it have an archive, as we don't want it crawled by bots by mistake.
    if ( ! oxygen_vsb_current_user_can_access() ) {
        $args['has_archive']        = false;
        $args['query_var']          = false;
        $args['publicly_queryable'] = false;
    }

    register_post_type( 'ct_template', $args );
    //no rewrite rules need to be flushed if user is not logged in
    if ( oxygen_vsb_current_user_can_access() ) {
        // flush rewrite rules if needed
        $flag = get_option( "oxygen_rewrite_rules_updated" );
        if ( $flag !== "1" ) {
            flush_rewrite_rules();
            update_option( "oxygen_rewrite_rules_updated", "1" );
        }
    }
}
zjoko commented 2 years ago

+1

d-packs commented 2 years ago

@zjoko the code snippet above makes the templates translatable and it works well with WPML. I know it's not the same as having it built into oxygen and it requires adding the code somehow, but it works.

JamboMedia commented 2 years ago

+1

aleknovkovski commented 2 years ago

+1

webjoko commented 2 years ago

@zjoko the code snippet above makes the templates translatable and it works well with WPML. I know it's not the same as having it built into oxygen and it requires adding the code somehow, but it works.

Thank you. I appreciate that.

marcorubiol commented 2 years ago

I'm adding the code above to wordpress and I can see the strings in WPML string translation but is not render in the frontend.

Someone know what I'0m doing wrong

btw, @d-packs thank you for the code

lindebjerg commented 2 years ago

+1 vote from me. I have used WPML on several Sites since more than 10 years. For me the only Plugin to setup multilingual sites. I would love to see WPML work perfect with Oxygen, for me The Ultimate Visual Site Builder for WordPress!

ewokee commented 2 years ago

+1

Brandinwebdesign commented 2 years ago

Please there need A wpml intergation!! Its now a nightmare

Sabaidi59 commented 2 years ago

+1

Jehu commented 2 years ago

Please take a look in this topic with WPML team. i18n is such an important issue for many websites.

Since Version 4 (JSON instead of Shortcode) translation via import of XLIFF is no more working because just the shortcode is updated on import. We have to stay on Oxygen 3.9 until this is fixed.

Oxygen people - please hear the need of your community.

followleohans commented 2 years ago

+1

sergiobellini commented 2 years ago

+1

Manuelfaraone commented 2 years ago

+1 Support Oxygen for WPML plugin!

sergiobellini commented 2 years ago

+1

DeveloperCorsaro commented 2 years ago

+1

birralight13 commented 2 years ago

+1

paulo-carvajal commented 2 years ago

+1

nuriarita commented 2 years ago

+1

little-gatsby commented 2 years ago

+1

grldf commented 2 years ago

+1

pad52 commented 2 years ago

+1

uhlhosting commented 2 years ago

Any ETA on this matter? Would love to see wpml support in oxygen.

Vladulescu commented 2 years ago

+1

davidperroud commented 2 years ago

+1 Support Oxygen for WPML Plugin ! Maybe go with the Go Global Programm of WPML ?

I worked for 2 years on a multilingual website, with Oxygen and WPML, and everything was working fine before the version 4. Know i have to "hack" the Oxygen plugin if i want my visitors to get access to the website in all languages...

LEloffel commented 2 years ago

+1 for WPML support! Please

CallanAH commented 2 years ago

+1

sercanvirlan commented 2 years ago

+1

wieseljonas commented 1 year ago

+1

fily1212 commented 1 year ago

+1, please!

visionlabit commented 1 year ago

+1 Support Oxygen for WPML Plugin Please!

Alex-Rubio commented 1 year ago

+1 please! WPML so useful

mnwalker commented 1 year ago

+1

jorgetbruno commented 1 year ago

+1

uhlhosting commented 1 year ago

@Spellhammer why this lack of reply from Oxygen? WPML says they are in real need for your collaboration to solve these issues. We are dealing here with years of working with WPML, LTD license that served us well on all websites without oxygen. This is a point where Elementor and other competition is doing steps while Oxygen lacks, either you folks don't know how to say f**k off since silence is not golden, ignorance is not bliss. Funny that you worked integrations that are not even so needed, yet the fact that oxygen websites cannot be translated properly with one of oldest, and most used translation plugins does not seem to bother anyone in this team. Such a shame having people to +1 + +1+1+11+1111+11111 here without any results from your side. Over 2 years now and wind is blowing. I start loosing trust that you really care about the customers in any way.

lowcut commented 1 year ago

+1

omicronn commented 1 year ago

+1

TSMadmin commented 1 year ago

+1

ediger86 commented 1 year ago

+1. This is badly needed

Globoris commented 1 year ago

+1 @ediger86 is right: This is badly needed!

convernaticspeter commented 1 year ago

how can this still be unsolved? unbelievable!

jtlg28 commented 1 year ago

+1

psomby commented 1 year ago

WPML support would be very much appreciated!!

mark88008 commented 1 year ago

How is it progressing with WPML support for Oxygen?

TSMadmin commented 1 year ago

Currently we are not using Oxygen with WPML because there is no support.

From: Michael Blechinger @.> Date: Monday, January 9, 2023 at 5:51 AM To: soflyy/oxygen-bugs-and-features @.> Cc: Admin Accounts List @.>, Comment @.> Subject: Re: [soflyy/oxygen-bugs-and-features] Support for WPML plugin (#938)

How is it progressing with WPML support for Oxygen?

— Reply to this email directly, view it on GitHubhttps://github.com/soflyy/oxygen-bugs-and-features/issues/938#issuecomment-1375424711, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AWOIXVETET5H7K5PIUNCE23WRPUTVANCNFSM4LZBCWYQ. You are receiving this because you commented.Message ID: @.***>

V0IDNIL commented 1 year ago

Me, I act under the assumption that support for WPML will never come to Oxygen. I would be pleasantly surprised if it happens, but hope I have absolutely none.

I strongly dislike WPML. It’s a sluggish, bloated mess of a plugin and their “support” is very much hit and miss. I’d like to use Weglot (which Louis Reingold publicly voiced support for) for each of my WordPress projects but have to use WPML (sometimes Polylang) most of the time. I’m based in Japan and practically each website I make is at least bilingual (Japanese/English), often three or more languages (usually Mandarin Chinese, Korean, Thai …). Weglot’s approach is to have identical site structures for each language (I know there’s a hack to hide content through css selectors, but that’s a hack, nothing workable for a client). That approach works fine if you have a simple website and/or your languages are culturally relatively similar (like European languages). In my case, practically all my Japanese clients (close to a hundred over the past five years) demand a different site structure for their Japanese visitors and their international visitors. Sometimes it’s just one extra page, often it’s much more. Not even to speak of those cases that have some e-commerce solution, in which case Weglot is completely unusable. That’s why I need to use something like WPML because it allows me to build independent websites for each language.

And that’s why I’ve turned my back on Oxygen and use another builder that natively supports WPML. I think you should all evaluate if you really need WPML or if you can instead use some alternative like WeGlot . And those of you who really need WPML, I recommend giving up all hope on Oxygen and use some other builder, and just start building your multilingual websites. Oxygen is fantastic when it works, but the current state of Oxygen+WPML is the stuff of nightmares.

kotkotan commented 1 year ago

Vote to fix WPML for Oxygen!