URL);
$BlockStart = '
';
$BlockEnd = '
';
$Content = GetTextBetween($Content, $BlockStart, $BlockEnd);
if ($Content == '')
{
$Output .= 'Main block not isolated.';
return $Output;
}
$ItemStart = '";
while (strpos($Content, $ItemStart) !== false)
{
$Item = GetTextBetween($Content, $ItemStart, $ItemEnd);
$MeetItem = new MeetItem();
$Gender = trim(html_entity_decode(GetTextBetween($Item, 'class="kategorie">', 'Gender = Gender::Female;
else if ($Gender == 'Hledám partnerku') $MeetItem->Gender = Gender::Male;
else $MeetItem->Gender = Gender::Undefined;
$MeetItem->Name = trim(html_entity_decode(GetTextBetween($Item, 'Vložil/a', ',')));
$Time = trim(GetTextBetween($Item, ' ', ''));
$MeetItem->Time = HumanDateTimeToTime($Time);
$MeetItem->Height = trim(GetTextBetween($Item, "výška:", 'cm'));
$MeetItem->Message = trim(html_entity_decode(strip_tags(GetTextBetween($Item, '
', ' | '))));
// Replace unicode non-breakable space by normal space
$MeetItem->Message = str_replace("\xc2\xa0", "\x20", $MeetItem->Message);
$MeetItem->Age = GetAgeFromText($MeetItem->Message);
$MeetItem->Height = GetHeightFromText($MeetItem->Message);
$MeetItem->Weight = GetWeightFromText($MeetItem->Message);
$MeetItem->Location = GetLocationFromText($MeetItem->Message);
$MeetItem->Email = trim(GetTextBetween($Item, '', ''));
$MeetItem->Phone = trim(html_entity_decode(strip_tags(GetTextBetween($Item, 'Telefon:', ''))));
if ($MeetItem->Phone == 'neuveden') $MeetItem->Phone = '';
$MeetItem->Link = '';
$MeetItem->Database = $this->Database;
$MeetItem->Source = $this->Id;
$this->MeetItems[] = $MeetItem;
}
return $Output;
}
}