Community Events problem with urls in multilingual website

Home Forums Calendar Products Community Events Community Events problem with urls in multilingual website

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #50282
    Evangelia
    Participant

    Hello Modern Tribe Team!
    I have the Community Events plugin in a website working perfectly in Greek for a year now. Recently, I turned the website multilingual using WPML to add the English language.
    I have managed to solve all bugs and have everything working apart from this:
    I cannot access the Community Events pages in English.
    I use different directories for the different languages, so I have the following url structures:
    Greek: mydomain/events/community/add –> Works
    English: mydomain/en/events/community/add –> 404
    Same thing for editing an event etc.
    I believe that there is something wrong with the routing rules, i.e. “ce-add-route”, in the the-events-calendar-community-events/lib/tribe-community-events.class.php file, but cannot figure it out.
    My guess is that the regular expressions used for the paths do not match the english urls, but I haven’t managed to sort things out.

    Do you have any advice for my situation?
    Have you encountered a similar case before?

    I would deeply appreciate a solution, as it is rather ugly to have this section of my website in Greek only…

    BR,
    Kelly

    #50376
    Barry
    Member

    Hi Kelly,

    I’m not sure there is too much we can offer here. Numerous users have reported problems with WPML and this is a multi-faceted problem that we don’t have a spot fix for.

    Have you tried seeking support via WPML’s own support channels?

    #50381
    Evangelia
    Participant

    Hi Barry!
    I have not tried WPLM support yet, but I have digged into the TEC code and found the WP_router add_route functions that handle routing for the custom TEC urls (events/community/add).
    I added a new route to handle the path for the english event creation (i.e. en/events/community/add), but something is wrong and I cannot be redirected to the New Event form in English, I get a 404 page instead.
    I have read all thread related to WPML in your forum, but nobody mentions TEC.
    I do not believe that what I am trying to do is exotic and I find it quite peculiar that nobody else encountered WPML-TEC compatibility issues.
    Do you have any suggestions on what might be wrong with my routing rules?
    I have used Rewrite Analyzer plugin and I am positive that my new rule is registered and correctly maps the en/events/community/add url.
    Why do I get a 404 error page?

    BR,
    Kelly

    #50383
    Barry
    Member

    We’ve had a number of people encountering WPML/TEC integration issues, it certainly isn’t just you, and we do hope to investigate whether there is anything we can do to improve the situation at some point.

    Regarding the 404 on your new custom route, I’m not too sure – have you tried flushing the permalinks?

    #50388
    Evangelia
    Participant

    Yes, I have flushed my permalinks several times, after each route update, but unfortunately made no difference…
    The only thing I can tell is that the page_callback of my new routing rule seems not to be triggered.
    Any ideas?

    #50401
    Barry
    Member

    Can you share your code (via a link to Pastebin, Gist or a similar service)?

    I’d be happy to take a look but can’t guarantee anything since we’re dealing with custom code here 🙂

    #50406
    Evangelia
    Participant

    Hi Barry,

    please find my code for the routing of the event creation in english here:
    http://pastebin.com/H63LdQqp

    Nothing special, it is almost the same code that you use to parse the normal ‘Add an Event’ url i.e. mydomain/events/community/add,
    apart from the fact that I try to parse the language part of the url
    i.e. mydomain/en/events/community/add.

    I realized that the page_callback (addCallback) is not executed in my routing, because I slightly modified the callback to echo a debug message.
    I had that message echoed when running the default url, but I am stuck with 404 when running the english version. I guess this means that the callback is not triggered in this case.

    You can test the situation for yourself on my development site http://www.kellydamalou.eu

    Thank you for your help!
    Kelly

    #50408
    Evangelia
    Participant

    FYI, this is the debug version of the page_callback that I am using for test purposes
    http://pastebin.com/mJiUAezn

    #50415
    Evangelia
    Participant

    Another update is that I contacted the WPML team about the issues and they just informed me that they are contacting you to cooperate in investigating the compatibility issues.
    I hope you do want to dedicate the effort to sort things out, I believe it will significantly add value to your plugin.

    Thanks!

    #50426
    Barry
    Member

    We definitely do want to work with the WPML team to improve things, but to be completely transparent we are focusing on our 3.0 release first and foremost.

    Once that is complete we will certainly be taking WPML/onTheGoSystems up on their offer to cooperate and try to find some ways forward here.

    #50465
    Evangelia
    Participant

    When is the 3.0 release scheduled? Any time estimate for the integration efforts with WPML?
    I believe that I have come really close to solving this issue, all I need is a small push from your side to get things rolling?
    Don’t you have any workarounds before you “officially” try to tackle the issues with WPML?

    #50481
    Barry
    Member

    We don’t have a fixed deadline for the 3.0 release, but we hvae now completed the beta testing phase and are basically dotting the i’s and crossing the t’s – so it should be released shortly.

    I believe that I have come really close to solving this issue, all I need is a small push from your side to get things rolling?

    It does look like you’ve come close and we’d love to help more – I did actually touch base with one of the devs (who is very experienced with WP Router, the component you are interacting with) and our fear is we would have to spend a disproportionate amount of time on this to get it working.

    Even then it would be a very specific solution that in all probability many others would not find useful. Given that and the fact that we have many users to support we will unfortunately have to bow out and leave this one to you – though it would of course be great to see your final solution.

    Don’t you have any workarounds before you “officially” try to tackle the issues with WPML?

    No, none that I am aware of or I’d certainly have pointed you to them – you might find ideas and hacks on the forum but just be aware these too are likely to be very specific and may not work for you.

    Sorry we can’t do more.

Viewing 12 posts - 1 through 12 (of 12 total)
  • The topic ‘Community Events problem with urls in multilingual website’ is closed to new replies.