rlb1
asked on
RELATED: How do I structure this drop down correctly w/regex?
Kaufmed & Experts,
I have attempted to structure this statement, however I am having an issue with the lookahead. How do I fix this?
Thanks for your help!!
Original source:
<select name="SKU_0" size="1" onchange="javascript:Chang eItemId(do cument.for m1.varitem id_0,docum ent.form1. SKU_0);">
<option value="BSC11" selected>Black
<option value="BSC12" >Blue
<option value="BSC13" >Red
<option value="BSC14" >Green
<option value="BSC15 >Yellow
<option value="BSC16" >Gray
</select>
I have attempted to structure this statement, however I am having an issue with the lookahead. How do I fix this?
Thanks for your help!!
Original source:
<select name="SKU_0" size="1" onchange="javascript:Chang
<option value="BSC11" selected>Black
<option value="BSC12" >Blue
<option value="BSC13" >Red
<option value="BSC14" >Green
<option value="BSC15 >Yellow
<option value="BSC16" >Gray
</select>
preg_match_all('%<option value="(.*?)" ?=(selected)>([a-zA-Z]{10})%',$buffer,$matches39,PREG_SET_ORDER);
foreach ($matches39 as $val39) {
$option1=$val39[1];
$option2=$val39[2];
$option3=$val39[3];
$option4=$val39[4];
$option5=$val39[5];
$option6=$val39[6];
$option7=$val39[7];
$option8=$val39[8];
Can you clarify what it is you are trying to capture?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you for your help Terry & Kaufmed!
I can't in good conscience accept points for my comment... Terry's really the one who got you sorted out, though I appreciate the gesture = )
ASKER
Kaufmed, you and Terry have been exceptionally good to me on EE! Thanks for helping me learn this stuff!!