To remove the first character of a string, use myString[1] - this tells SM to start reading the string from the first byte, rather than the zeroth. To remove the last character, simply set it to null, and the string terminates one character earlier.
Here's an example from the Signal code:
PHP Code:
new start = 0;
new lastchar = strlen(arguments) - 1;
if (arguments[lastchar] == '"') {
arguments[lastchar] = '\0';
start = 1;
}
From that point on, use "arguments[start]" as the string, rather than "arguments".
__________________