Here is some string I have to evaluate against a regex:
The regex I use is:
ereg("piece_([0-9]+)_(Y|N)_([^_]+)_(.+)", $key, $regs)
// $regs = $key = le nom de la variable au complet
// $regs = position
// $regs = Y ou N (inFormula)
// $regs = price
// $regs = Component's name
The problem I have is when the price contains a dot in it (like the last 2 string I gave above).
I only get 0
I tried changing ([^_]+) to ([0-9.]+) without luck
If someone could explain me what's wrong with this, I'd appreciate it.