Page 2 of 2 FirstFirst 12
Results 16 to 18 of 18

Thread: multilanguage indexu

  1. #16
    Join Date
    Apr 2005
    Posts
    8

    Default

    Hello Frank,

    As mentioned in my previous post, once you have added the format_text() function into misc.lib, all you would need to do thereafter is parse cat and links names in the appropriate classes:

    For example in 'category.class.php':
    Code:
    $tpl->assign('cat_description', format_text($cat_description));
    To avoid any confusion with dody's vars, I created my own vars and replaced $title and $url by $parsedtitle and $parsedurl in the frontend templates. Then I added the following lines in the link.class.php:
    Code:
    $tpl->assign('parsedtitle', format_text($title));
    $tpl->assign('parsedurl', format_text($url));
    Unfortunately my changes were very intuitive so I can't really write a complete HOWTO... Must be intermediate or advanced PHP programmer to implement this mod.

    It was fairly easy to modify the CheckUrl.php to scan two URLs per multilang entry (my site is asymmetrical, some links are English, about 25% is both in English and French) but my endeavor was successful (my code is so ugly though ... I'll post it only if an advanced developer agrees to review it ...)


    Cheers,

    Seb

  2. #17
    Join Date
    Nov 2004
    Posts
    36

    Default

    How bout creating a new table for your categories or links. say you have a category called Horses on your site but you wanna add it as Spanish, on cat edit you select add spanish and you enter all the info again in spanish, it is then stored in the new table with a couple extra fields like language id and related to store which cats are other translations maybe. Then on your site all a person has to do is click a different language to set a cookie with the language variable to determine which table/cats links are loaded for them. Just thinking off the top of my head

  3. #18
    Join Date
    Apr 2005
    Posts
    8

    Default

    Hello Player-

    I'm not a big fan of duplicating, especially database tables, because you will quickly loose control over one version or another, especially when clients are managing their own site... I'm new to regex pattern matching and I think its a useful and most powerful feature to accomplish just that: multilang entries are in a single field and clients can’t miss it: if they edit one lang, they see and edit the other right from the same text box… I got this idea from my recent experience with Moodle which is successfully using this approach. Moreover, duplicating databases is quite burdensome as you need to alter all Dody's queries…

    I had to develop this multilang filter real quick as I had only a few days to make the product work. With this filter I have nothing more to do but string parsing here and there + it allows for asymmetrical content (which becomes a problem with mirrored tables).

    Even though my project is finished I would like to hear more suggestions.

    Kind Regards,

    Seb

Similar Threads

  1. Replies: 26
    Last Post: 06-25-2007, 09:45 PM
  2. INDEXU v4.0 preview website.
    By dody in forum v5.x
    Replies: 93
    Last Post: 04-19-2005, 12:02 PM
  3. Indexu 4 ???? or Indexu PPC?
    By nooralam in forum v5.x
    Replies: 15
    Last Post: 06-07-2004, 04:04 PM
  4. Indexu v4 part 2
    By TLC in forum v5.x
    Replies: 5
    Last Post: 05-14-2004, 08:22 AM
  5. multilanguage indexu
    By ste in forum Help Wanted/Job Request
    Replies: 1
    Last Post: 07-22-2003, 08:30 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •