Hi all,
I have a load of php templates which uses a custom translate function "__", i.e.
<?php echo __("Hello"); ?>
I need to write a script which will look for all these function calls (there are about 200 templates).
I.e. it will find __("Hello") and add it to a sentences to be translated array. For example it will find:
$sentences[] = "Hello";
$sentences[] = "Goodbye";
$sentences[] = "Random sentence to be translated";
Basically i need to find the strings which need to be translated.
Which do you think is the best language for doing the script in? and do you think it will be best to use a regular expression?
Any help to point me in the right direction would be superb!
Thanks