Have you seen our video tutorials? Check 'em out!

Translate button

cchinopoulos - 3 weeks ago

In the video module tutorial if i use a button like this:

'videos' => [ 'buttons' => [ 'create' => [ 'text' => 'Add', 'icon' => 'fa fa-plus', 'type' => 'success', ], ], ],

how to 'target' it in order to translate it from within the resources/lang/en/button.php file.

cchinopoulos - 3 weeks ago

I've tried:

'create' => 'Add NEW Video',

but it doesn't work as if i had used a magic button

'new_video' => 'Add NEW Video',

ryanthompson - 3 weeks ago

You've already provided the text in the button definition so remove that and the key will be revealed - in your case it would be create which is defaulted anyways. If you did new_video => ... or create_video => ... then you could customize it.

You can also change the text property to a translatable string!