I have got the following response for one of my HTTP request in JMeter:
<div class="container">
<h2>Choose your departure city:</h2>
<form action="reserve.php" method="post">
<select name="fromPort" class="form-inline">
<option value="Paris">Paris</option>
<option value="Philadelphia">Philadelphia</option>
<option value="Boston">Boston</option>
<option value="Portland">Portland</option>
<option value="San Diego">San Diego</option>
<option value="Mexico City">Mexico City</option>
<option value="São Paolo">São Paolo</option>
</select>
<p>
<h2>Choose your destination city:</h2>
<select name="toPort" class="form-inline">
<option value="Buenos Aires">Buenos Aires</option>
<option value="Rome">Rome</option>
<option value="London">London</option>
<option value="Berlin">Berlin</option>
<option value="New York">New York</option>
<option value="Dublin">Dublin</option>
<option value="Cairo">Cairo</option>
</select>
Now I want to select the fromPort values and also the toPort values in two different variables and then pass it on to the next request. I build the regex expression but it captures all the values of fromPort and toPort in a single array. I need to extract these in two different arrays and then call them. So I want to know about the right regex for this ??