예제 #1
0
     // because we know it already.
     // @todo Add checks if too many rows have been parsed
     if ($_row == MEGAMEDIA_ADDRESS_FINAL) {
         if ($current_page == 1) {
             $status = BEGINING_CONTENTS_PAGE;
         } else {
             $status = BEGINING_PRODUCT_PAGE;
         }
     }
     break;
 case BEGINING_CONTENTS_PAGE:
     // Check if the contents page has ended and
     // verify the order number just in case
     if (mb_stristr($_row, $page_heading)) {
         $numberArray = explode(' ', $_row);
         $Offer->verifyEnquiryNumber($numberArray[1]);
     } else {
         if (stristr($_row, $last_row_before_contents) || $_row == $last_row_before_contents) {
             $status = CONTENTS;
         } else {
             if (stristr($_row, $subject_start)) {
                 $Offer->setSubject(str_replace('Sagsnavn:', '', $_row));
             }
         }
     }
     break;
 case CONTENTS:
     // Check if the products have ended
     // otherwise parse the prodct data
     if ($_row == $contents_end) {
         $current_page++;