I have a string that I'm trying to extract information from…
Subject: =?iso-8859-1?Q?=A1=F1?= text =?iso-8859-1?B?KJLHDHmnflkjheJKLJVC=?=
I want my regex to extract…
=?iso-8859-1?Q?=A1=F1?=
and =?iso-8859-1?B?KJLHDHmnflkjheJKLJVC=?=
The Regex I have at the moment…
I've written the following Regex - which is nearly, but not quite, right…
=\?(.*?)\?=
The problem
The problem is that this extracts the following…
=?iso-8859-1?Q?=
and =?iso-8859-1?B?KJLHDHmnflkjheJKLJVC=?=
As you can see, the Regex is confused by the ?=
following Q - despite the fact that this is not the last occurrence of this string after the initial opening =?
.
Does anyone have any idea on how I can fix this?