I know that there is some way to do this using the translatable code but that seems like a hack to me. I would rather just have control over the text directly. I am using SS 2.4.3 but I tried to just use the old way of creating my own instance of a SearchField but I get errors when I try to submit it.
We've moved the forum!
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
Its *meant* to be done via a custom translatable file... Otherwise you modify the core or you have to redundantly replace it.
The point of the _t function is so you can do exactly what you're asking to do.
I see what you mean however I don't see the logic in use a system meant for localization to be used to change the text of something when there is only one localization and it should be the default. Localization is only used when you have more than one and need to change the default to another language. So I can certainly do it that way but it is still a hack in my opinion.
In case anyone is looking for a solution to changing 'go' to Other Text or an image this worked for me:
In en_US.php or your relevent language file change line 689(approx) -
$lang['en_US']['SearchForm']['GO'] = 'Go';
to
$lang['en_US']['SearchForm']['GO'] = 'Other Text';
or
$lang['en_US']['SearchForm']['GO'] = '';
if you want to add an image instead using background-image in .search form input.action in the search css