miguelbalparda / mb_translate Goto Github PK
View Code? Open in Web Editor NEWTranslate CMS Pages in Magento
Translate CMS Pages in Magento
En primer lugar, enhorabuena por la extensión. Gran trabajo, una funcionalidad así me parece indispensable.
Utilizándola he encontrado dos cuestiones, que quería consultarte si serían sencillas de aplicar:
Habría algún modo de usar esta técnica de traducción tb para las URLs? De otro modo aunq con esto podamos traducir los textos del contenido, la url debería ser la misma para todos los idiomas, no?
Veo que en el título del contenido del CMS se puede usar el código de traducción. Al visualizar la página sale todo bien, a excepción de las migas de pan, donde veo que sale todo el chorreo:
Inicio > {{translate text="pagina cms cualquiera"}}
Gracias de antemano y enhorabuena por el trabajo.
Hi, could the config be updated to allow the translate directive to be applied to the page title in addition to the cms page content?
In the way is built now all the texts are translated using the page
module.
You should be able to pass a module name to the translate directive:
{{translate text="some text here" module="catalog"}}
This can be achieved by doing this:
public function translateDirective($construction)
{
$params = $this->_getIncludeParameters($construction[2]);
$text = $params['text'];
$module = (!empty($params['module'])) ? $params['module'] : 'page';
return Mage::helper($module)->__($text);
}
Hello,
please add release tag "0.1.0" under https://github.com/miguelbalparda/MB_Translate/releases to ensure functionality with composer and http://packages.firegento.com. Thanks!
The configuration page doesn't show up in System > Config > Content Management
as expected.
I wanted to change module name.
What is the config path for default_module
?
The filter model used by the CMS pages is Mage_Widget_Model_Template_Filter
. (see app/code/core/Mage/Widget/etc/config.xml
)
<cms>
<page>
<tempate_filter>widget/template_filter</tempate_filter>
</page>
<block>
<tempate_filter>widget/template_filter</tempate_filter>
</block>
</cms>
If you don't extend that class you can lose the {{widget ...}}
directive
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.