This topic contains 4 replies, has 3 voices. Last updated by Jason (Lead Developer) 3 years, 11 months ago.
Topic Author | Topic |
---|---|
Posted: Saturday Jan 26th, 2013 at 3:26 pm #39704 | |
Hmmm, Jason’s post about “Changing Words/Phrases In s2Member” is useful, but… https://www.s2member.com/kb/changing-words-phrase/ As far as I can tell, s2Member wraps boatloads of text inside _x() that will never actually get translated. This occurs when the text is part of JavaScript delivered to the browser in a way that appears to suggest it is being prepped on the fly by PHP (but maybe it isn’t?). For example, I’d like to change the JavaScript validation code’s standard error header of “— Oops, you missed something: —”. (Personally, I find this quite rude to be saying to someone who has just paid money to access a site.) Unfortunately, even though this apparently translatable text is peppered through authnet.js, paypal.js, s2member.js, etc., and even though files like these appear to be prepared and output generated on the fly by s2member-o.php, as far as I can tell none of this text ever gets translated. (At least, filtering using the example given in Jason’s article appears to have no effect. In fact, placing a filter on gettext_with_context and var_dump-ing anything that comes through with the word ‘oops’ in it yields nothing.) Am I wrong about this? I hope so! |