Using PHP to call a Java app, the Java app returns a string encapsulated by "[....]", I need to remove the outside brackets and maintain what's inside -a mix of integers, strings, and other special chars like (, etc.. I'm using sscanf successfully later in the process, so I'm a little lost as to why this particular step is so difficult.
Input:
$str = [(123)[334.5 : 765.1] string]
Non-functional code:
$format = '[%s]';
sscanf($str,$format,$output);
Later in the process I'm successfully using sscanf to parse the inside string using:
$format = '(%d) [%f : %f] %s';
I'm missing something big here...