[ic] Use one table for product descriptions in different languages

Daniel Davenport ddavenport at newagedigital.com
Mon Jul 11 09:18:27 EDT 2005



>>> lars.tode at bpanet.de 07/08/05 12:34 PM >>>
> Hallo list.
> 
> One of our customers thought about translate his shop in different
> languages. The biggest part of the translation is done by the locale.txt
> There is just one exception, the title and description of each product.
> 
> One possible solution is to use different ProductFile for each language,
> using the ProductFiles directive in the locale.txt
> In this solution, I'd to create more than one product table and to
> update both tables if something changed (data, table structure etc).
> This idea is not bad, but i search for something different.
> 
> Another solution I found today on www.icdevgroup.org, DescriptionField.
> I think the solution ist not so bad, except if you add more languages.
> 
> My idea is just add one more table where every descption for every
> language and item is stored in.
> 
> I thought about following table layout :
> 
> item_code
> ianguage_id
> title
> description
> 
> Is there a possibillity the modify/configure Interchange in that way,
> that it can handle this kind of table?
> Or is the only way to create an own usertag, which reads the data from
> the second table?
> 
> Thanx in advanced,
> 
> Lars

You'd have a hard time telling IC to look at both the sku and the language with a scheme like that.

[data table=descriptions field=description key=1
    foreign.item_code=[scratch sku]
    foreign.language_id=[scratch current_language]
]

looks like it might grab the data you need, assuming you've [tmp]ed or [set] your sku and language.
If you want it simpler than that in a page, you'll probably need to write a tag....but the tag could just be a wrapper around the data tag above.

/




More information about the interchange-users mailing list