I am using PHP Regex to see if a pattern is in my string. Simply put, I want one of two words followed by a number. So, here's my pattern:
#(guitare|piano)[0-9]#
Basically, if the string contains the word "guitare", I don't want it to be matched, only if I have "guitare9" or "piano0"
At this point, If I use this pattern for the follwing string:
J'aime la guitare9
The array of the preg_match() returns guitare and guitare9: http://www.phpliveregex.com/p/7tZ
What do I have to change in my regex to only match guitare9 ?