Hi i'm stuck on where to add my Do While Loop statement ... below is the section of the coding that is being processed. what is happening is the source is examined and the version codes are grabbed. but, it needs to loop through the source and grab all version codes and not just the first one.
thanks in advance
	Code:
	                $resp = curl_exec($ch); 
                //echo "$resp\n"; 
                curl_close($ch);       
                $startkey = "<024version>"; 
                $stopkey = "</024version>";         
                $startpos = strpos($resp, $startkey);  
                if ($startpos !hahahaha false) {  
                    $startpos += strlen($startkey);  
                    $endpos = strpos($resp, $stopkey, $startpos); 
                    $len = ($endpos - $startpos);  
                    $writecontent .= substr($resp, $startpos, $len)."\n";  
                    echo "$writecontent\n"; 
     
                } 
$fp = fopen($outputfile,"w"); 
fwrite($fp,$writecontent); 
fclose($fp);