I'm trying to make a plugin in Craft 3 but want it to be possible to set different settings for each separate site or locale. How would I go about doing this?
1
Edit
OP updated the question to specify Craft 3, so this is no longer relevant.
You can define a separate value for each locale, as described in the localisation documentation:
<?php
return [
'flagName' => [
'de' => 'Bundesflagge',
'fr' => 'Tricolore',
],
];
-
I can't seem to get this to work, I'm trying to do this in Craft 3 though, are you sure it's the same? – Rias May 8 '17 at 8:16
-
Ah, I see you updated the question. I'm not sure about Craft 3, but I suspect it's different. – Stephen Lewis May 8 '17 at 15:52
-
I'm pretty sure that the above only ever applied to the
siteUrl
and wasn't generalized to work for any setting – andrew.welch Jul 12 '18 at 4:45