Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $words = array('поставя','темата', 'продавал'); // Allowed words
- $content = file_get_contents('https://www.wallflux.com/feed/101392669928073'); // Feed url
- $xml = new SimpleXmlElement($content);
- foreach($xml->channel->item as $row) {
- foreach($words as $word) {
- if(strpos($row->description, $word) !== false) {
- /*
- Check in DB from $row->pubDate
- False = send email (url to post - $row->link), write on DB
- True = continue
- */
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement