e107inc / vstore

Simple shopping cart system for e107 v2.x Bootstrap CMS
GNU General Public License v3.0
17 stars 12 forks source link

Vstore language use #181

Closed tgtje closed 3 years ago

tgtje commented 3 years ago

Hoping compilation is fine now, incorporated the latest changes ( 04/05-03 = 37b2927 )

Tested local php 8.0.1 php 7.4.10 live.

No changing of button text for Gateway communication (R,N,C etc..) since unsure how gateway reacts communicating back. (those could be altered in newer release by more info available). 4 lang.packs provided : English, Dutch, French, German.

tgtje commented 3 years ago

Closing due to recent update for CC issue; 3 files in question need to contain LAN's (although confident, need to test).

tgtje commented 3 years ago

Thanks for the appreciated instructions. I will take them into consideration. Using the {LAN= ias (as seen in core latest) is a new method.. . Of course i agree it should be clean. Just informational : i used more LAN's in global because 'similar sentences/words' occurs throughout the plugin eg in admin and front etc.. hence to reduce the amount of defines.... Well lets see how far i can succeed.

tgtje commented 3 years ago

Just a quick question before applying changes in regards to For all template files use: {LAN=VSTORE_XXX } (without the '. .' ) which will render LAN_VSTORE_XXX

Since i am unaware iff it will function, should { return constant($lan); } elseif(defined('LAN_'.$lan)) { return constant('LAN_'.$lan); } elseif(ADMIN) like 11 days ago put in for LAN constants for core templates > added in shortcode/single/lan.php > also work for templates in plugin ? Just asking as Vstore is not in core. (edit : info for plugin builders would be in place too? eg plugin builder or alike...just idea ?)

CaMer0n commented 3 years ago

Thank you @tgtje !

Yes, you'll need to use the latest github version with has that change in lan.php, so you can omit the LAN_ from the beginning of the variable.

For the LANs, if a term appears in both the frontend and the backend (admin), just put them in English_front.php - we can always load the English_front in the admin area as well as English_admin.php

English_global.php is loaded on every page of the site, so it should only ever contain a few defines at most.

tgtje commented 3 years ago

Thank you