Okay
  Public Ticket #141890
WPML Portfolio translation
Closed

Comments

  • Karl started the conversation
    Hey there, I'ld like to make sure of something before I lose too much time doing it. I just bought WPML to get my site translated properly and noticed that there's not portfolio item translation. So I'm guessing that what I have to do is to manually create other portfolio pages (I have 4 portfolio pages all in French version), create a new Primary Menu and then recreate all my portfolio items and assign them to those new portfolio pages? Is that it? Or is there something I'm missing here? Thanks, k
  •  1,077
    ThemeNectar replied

    Hey Karl!

    There's actually a checkbox at the bottom of your portfolio items that allow you to make it translatable - see the screenshot attached :)

    Cheers

  • Karl replied

    Well that's useful to know.

    Thanks! :)

  • Karl replied

    Actually, I have a bigger problem now.
    After clicking on the check box, the site doesn't recognize any of my initial portfolio pages (French).

    So if I translate a portfolio page (ie : http://karlouellette.com/en/portfolio/no-ticket/) it's working.
    But the original language is giving me a 404 page (http://karlouellette.com/portfolio/no-ticket/)

    Any idea what might be the issue?
    Or is there a tutorial somewhere?

    Thanks,

  •  1,077
    ThemeNectar replied

    Hey Karl - see my response to John2332 at the top of these search results http://themeforest.net/author_dashboard?utf8=%E2%9C%93&filter=all&term=portfolio_register+WPML

    I believe you're experiencing the same issue.

    Cheers :)

  • Karl replied

    Hey Phil,

    I tried the same thing but nothing changes.
    I opened a ticket as well with WPML support. So far, they're saying that everything is installed and configured properly.
    So we're all looking to find what may cause this problem.

    Weird thing is, even if I disable all WPML plugins, none of my projects are recognized anymore. (Even if I create new ones...)
    In other word... my site is down... eheh

    Let me know if you think of something!
    Thanks,

  • Karl replied

    Alright, so they finally fixed it!
    Here's the tread if it ever happends to someone who's not good with PHP just like me! :)

     

    ———-

    John2332, 14 days ago:

    Hello there,

    Since I’ve installed WPML on my clients website, single portfolio pages aren’t loading anymore. To explain it a little bit more: my client website has two different languages, Dutch (main) and English (second). Strange enough, the portfolio works pretty well on the English website. Unfortunately, when I want to visit the same portfolio post on the Dutch website, it gives a 404 error.

    I’ve tried to change the slug and update the permalinks, neither of them are working. The portfolio page itself works perfect, pagination etc works like a charm on both languages.

    Do you know any solution? Thanks!


    ThemeNectar AUTHOR 12 days ago Flag:

    Hey John, try opening the functions.php file and making a little edit for me to see if it helps. Find this:
    function portfolio_register()
    and then down from there a little change this:
    'rewrite' => array('slug' => $custom_slug,'with_front' => false),
    to
    'rewrite' => array('slug' => _x( 'projects', 'URL slug', NECTAR_THEME_NAME ) ,'with_front' => false),
    Cheers  [:)]


    John2332 12 days ago Flag:

    Yes I did, like I’ve said previously. I did translate the string in WPML, but that didn’t help either.  [:(]


    John2332 11 days ago Flag:
    Hey again,

    I’ve fixed the issue by myself. I had to translate the slug /project/ in WPML to /projecten/ for their Dutch translation. Everything works well now.  [:)]

    Thanks for your help! Best wishes for 2014!

    Regards, John


    ---------------------------------------------

    WPML Solution for that problem

    ---------------------------------------------

     

    Hello Karl,

    What the theme author mentioned made think and I finally adjusted your "functions.php" a tiny bit..
    –> http://pastebin.com/UGc8Behs – I changed your line 21 to my line 22

    Then the URL portfolio slug appeared under "WPML > String Translation" where then saved the French translation. Now these links work:

    FR: http://karlouellette.com/portfolio/no-ticket/
    EN: http://karlouellette.com/en/portfolio/no-ticket/

    Are the slugs ok like that?

  •  1,077
    ThemeNectar replied

    Hey Karl!

    Thanks a lot for posting that :)

    Cheers!