I want to replace the 3 last characters of file, just before the dot in extension.
I know there is a command to do it but i just can't fine it.
I want it to go like this
[code= Javascript]
Var file = self.location.t oString();
Var MyVar= ( 3 last characters before extension)
If MyVar="_en" replace with "_gr"
else replace with "_en"
end if
[/code]
To give you an idea of what i'm trying to do,
In the end i want it to be able to replace "SomePage_e n" with "Somepage_g r" and the opposite
Excuse my ignorance in Java but i just started using it today.
I know there is a command to do it but i just can't fine it.
I want it to go like this
[code= Javascript]
Var file = self.location.t oString();
Var MyVar= ( 3 last characters before extension)
If MyVar="_en" replace with "_gr"
else replace with "_en"
end if
[/code]
To give you an idea of what i'm trying to do,
In the end i want it to be able to replace "SomePage_e n" with "Somepage_g r" and the opposite
Excuse my ignorance in Java but i just started using it today.
Comment