Unfortunately, rss-bridge cannot fetch the requested page.
Facebook wants rss-bridge to resolve the following captcha:
Response:
EOD; die($message); } /** * Checks if a capture response was received and tries to load the contents * @return mixed null if no capture response was received, simplhtmldom document otherwise */ private function handleCaptchaResponse() { if (isset($_POST['captcha_response'])) { if (session_status() == PHP_SESSION_NONE) session_start(); if (isset($_SESSION['captcha_fields'], $_SESSION['captcha_action'])) { $captcha_action = $_SESSION['captcha_action']; $captcha_fields = $_SESSION['captcha_fields']; $captcha_fields['captcha_response'] = preg_replace('/[^a-zA-Z0-9]+/', '', $_POST['captcha_response']); $header = array( 'Content-type: application/x-www-form-urlencoded', 'Referer: ' . $captcha_action, 'Cookie: noscript=1' ); $opts = array( CURLOPT_POST => 1, CURLOPT_POSTFIELDS => http_build_query($captcha_fields) ); $html = getSimpleHTMLDOM($captcha_action, $header, $opts); return $html; } unset($_SESSION['captcha_fields']); unset($_SESSION['captcha_action']); } return null; } private function collectUserData(){ $html = $this->handleCaptchaResponse(); // Retrieve page contents if(is_null($html)) { if(getEnv('HTTP_ACCEPT_LANGUAGE')) { $header = array('Accept-Language: ' . getEnv('HTTP_ACCEPT_LANGUAGE')); } else { $header = array(); } $html = getSimpleHTMLDOM($this->getURI(), $header); } // Handle captcha form? $captcha = $html->find('div.captcha_interstitial', 0); if (!is_null($captcha)) { $this->returnCaptchaMessage($captcha); } // No captcha? We can carry on retrieving page contents :) // First, we check whether the page is public or not $loginForm = $html->find('._585r', 0); if($loginForm != null) { returnServerError('You must be logged in to view this page. This is not supported by RSS-Bridge.'); } $element = $html ->find('#pagelet_timeline_main_column')[0] ->children(0) ->children(0) ->next_sibling() ->children(0); if(isset($element)) { $author = str_replace(' - Posts | Facebook', '', $html->find('title#pageTitle', 0)->innertext); $profilePic = $html->find('meta[property="og:image"]', 0)->content; $this->authorName = $author; foreach($element->children() as $cell) { // Manage summary posts if(strpos($cell->class, '_3xaf') !== false) { $posts = $cell->children(); } else { $posts = array($cell); } // Optionally skip reviews if($this->getInput('skip_reviews') && !is_null($cell->find('#review_composer_container', 0))) { continue; } foreach($posts as $post) { // Check media type switch($this->getInput('media_type')) { case 'all': break; case 'video': if(empty($post->find('[aria-label=Video]'))) continue 2; break; case 'novideo': if(!empty($post->find('[aria-label=Video]'))) continue 2; break; default: break; } $item = array(); if(count($post->find('abbr')) > 0) { $content = $post->find('.userContentWrapper', 0); // This array specifies filters applied to all posts in order of appearance $content_filters = array( '._5mly', // Remove embedded videos (the preview image remains) '._2ezg', // Remove "Views ..." '.hidden_elem', // Remove hidden elements (they are hidden anyway) '.timestampContent', // Remove relative timestamp '._6spk', // Remove redundant separator ); foreach($content_filters as $filter) { foreach($content->find($filter) as $subject) { $subject->outertext = ''; } } // Change origin tag for embedded media from div to paragraph foreach($content->find('._59tj') as $subject) { $subject->outertext = '' . $subject->innertext . '
'; } // Change title tag for embedded media from anchor to paragraph foreach($content->find('._3n1k a') as $anchor) { $anchor->outertext = '' . $anchor->innertext . '
'; } $content = preg_replace( '/(?i)>'); $content = $this->unescape_fb_link($content); // Clean useless html tag properties and fix link closing tags foreach (array( 'onmouseover', 'onclick', 'target', 'ajaxify', 'tabindex', 'class', 'style', 'data-[^=]*', 'aria-[^=]*', 'role', 'rel', 'id') as $property_name) { $content = preg_replace('/ ' . $property_name . '=\"[^"]*\"/i', '', $content); } $content = preg_replace('/<\/a [^>]+>/i', '
', $content); $this->unescape_fb_emote($content); // Restore links in the post before further parsing $post = defaultLinkTo($post, self::URI); // Restore links in the content before adding to the item $content = defaultLinkTo($content, self::URI); $content = $this->remove_tracking_codes($content); // Retrieve date of the post $date = $post->find('abbr')[0]; if(isset($date) && $date->hasAttribute('data-utime')) { $date = $date->getAttribute('data-utime'); } else { $date = 0; } // Build title from content $title = strip_tags($post->find('.userContent', 0)->innertext); if(strlen($title) > 64) $title = substr($title, 0, strpos(wordwrap($title, 64), "\n")) . '...'; $uri = $post->find('abbr')[0]->parent()->getAttribute('href'); // Extract fbid and patch link if (strpos($uri, '?') !== false) { $query = substr($uri, strpos($uri, '?') + 1); parse_str($query, $query_params); if (isset($query_params['story_fbid'])) { $uri = self::URI . $query_params['story_fbid']; } else { $uri = substr($uri, 0, strpos($uri, '?')); } } //Build and add final item $item['uri'] = htmlspecialchars_decode($uri, ENT_QUOTES); $item['content'] = htmlspecialchars_decode($content, ENT_QUOTES); $item['title'] = htmlspecialchars_decode($title, ENT_QUOTES); $item['author'] = htmlspecialchars_decode($author, ENT_QUOTES); $item['timestamp'] = $date; if(strpos($item['content'], 'items[] = $item; } } } } } #endregion (User) }