Title: facebook parser
Last modified: August 21, 2016

---

# facebook parser

 *  [tigaszzz](https://wordpress.org/support/users/tigaszzz/)
 * (@tigaszzz)
 * [12 years ago](https://wordpress.org/support/topic/facebook-parser/)
 * Hi,
 * is there anyway to avoid redirection when facebook tries to parse the content
   of the urls?
 * regards
 * [https://wordpress.org/plugins/geographical-redirect/](https://wordpress.org/plugins/geographical-redirect/)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [rmmoul](https://wordpress.org/support/users/rmmoul/)
 * (@rmmoul)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/facebook-parser/#post-4935466)
 * I’d like to get an answer on this as well. Right now, this plugin is preventing
   facebook from properly getting site data.
 * Checking the facebook debugger shows errors about the redirects. Disabling the
   plugin allows facebook to properly scrape the content.
 *  [rmmoul](https://wordpress.org/support/users/rmmoul/)
 * (@rmmoul)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/facebook-parser/#post-4935467)
 * I hacked up a fix for this:
 * in the plugin file geo-redirect.php, go to the end of the file and replace the
   line:
 *     ```
       if (!is_admin()) {
           do_action('check_client_location');
       }
       ```
   
 * with:
 *     ```
       if (strpos($_SERVER['HTTP_USER_AGENT'],'facebook') === false) {
           if (!is_admin()) {
               do_action('check_client_location');
           }
       }
       ```
   
 * This will check the useragent string to see if it contains the word facebook,
   and will stop the redirection if it does. This shouldn’t be an issue for facebook
   since users will probably be sharing links that already went through the redirection
   to the proper language page, so facebook should still get the proper language
   without the redirect.
 *  [Phll](https://wordpress.org/support/users/phll/)
 * (@phll)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/facebook-parser/#post-4935503)
 * Hi rmmoul, help! 🙂
 * I have the same issue with WC Social Login..
    When I click on the Facebook Login
   button on the redirected pages, I got errors because the Facebook app auth links
   are redirected too.. (I tried to hack the WC SL plugin adding ?noredirect on 
   generated links but it doesn’t work in this direction)
 * The url should be [http://domain.com/wc-api/auth/facebook/int_callback](http://domain.com/wc-api/auth/facebook/int_callback)?,
   but it become [http://domain.com/languagesubfolder/wc-api/auth/facebook/int_callback](http://domain.com/languagesubfolder/wc-api/auth/facebook/int_callback)?
   and my Facebook app doesn’t connect..
 * I tried your fix but it doesn’t work.
 * Do you have any idea of how I can override the geo redirection to not work on
   this link?
 * Thanks!
 * Phil

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘facebook parser’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/geographical-redirect.svg)
 * [Geo Redirect](https://wordpress.org/plugins/geographical-redirect/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/geographical-redirect/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/geographical-redirect/)
 * [Active Topics](https://wordpress.org/support/plugin/geographical-redirect/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/geographical-redirect/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/geographical-redirect/reviews/)

 * 3 replies
 * 3 participants
 * Last reply from: [Phll](https://wordpress.org/support/users/phll/)
 * Last activity: [11 years, 1 month ago](https://wordpress.org/support/topic/facebook-parser/#post-4935503)
 * Status: not resolved