Hello,
I have delete the facebook plugin now facebook works fine but it load blank pages, does anybody have solution, working this up. I really need facebook to work properly. Anyone can suggest solution !
Printable View
Hello,
I have delete the facebook plugin now facebook works fine but it load blank pages, does anybody have solution, working this up. I really need facebook to work properly. Anyone can suggest solution !
I have two files in my plugins folder, you might need both too. One makes it use the mobile version and I have no idea what the other does but it can't hurt to have it.
The first is facebook.com.php (copy code and save as... then upload):and the second is fbcdn.net.php (ditto):Code:<?php
/*****************************************************************
* Plugin: Facebook
* Description:
* Changes the user-agent so Facebook sends us the mobile version.
******************************************************************/
function preRequest() {
global $toSet;
$toSet[CURLOPT_USERAGENT] = 'Mozilla/4.0 (compatible; MSIE 6.0; Windows CE; IEMobile 6.1)';
}
Give those a try, hope it helps :cool:Code:<?php
/*****************************************************************
* Plugin: Facebook
* Description:
* (1) Disables the "Queue transfers" option for external stylesheets
* and javascript on Facebook, allowing a faster pageload time.
* Lag is especially noticeable on Facebook due to the huge number
* of external resources required. Anything to reduce the lag is useful!
* (2) Fixes an AJAX problem avoiding the "Network Error #1001" message
* (3) Fixes a major navigation issue when Facebook attempts to change the URL
* on-the-fly.
******************************************************************/
$CONFIG['queue_transfers'] = false;
/**
* Pre-parser for changes before the main proxy parser.
* @param string $input
* @param string $type can be "javascript", "css" or "html"
* @return string
*/
function preParse($input, $type) {
// What type of document do we have?
switch ( $type ) {
case 'javascript':
global $URL;
// Apply changes to the main javascript file
if ( strpos($URL['filename'], '84ccno2p1zc44848.pkg.js') !== false ) {
// Target: _interpretTransportResponse for parsing the AJAX reply
// Problem: uses eval() to interpret response but our eval() wrapper
// creates a scoping issue, resulting in no response getting back
// Change: use the return value instead of setting a value within the eval()
// Line: 801
#$input = str_replace("eval('response = ('+safeResponse+')')","response = eval('('+safeResponse+')')", $input);
// Target: unknown
// Problem: as above but another fix is required somewhere.
// To do: find out where and do a more specific change.
$input = str_replace("eval", 'base_eval', $input);
// Target: _filter() function for determining if Facebook should mess with the URL
// defaults to true after checking for various special cases
// Problem: unknown, just that it tries to take us to the wrong URL and hangs
// Change: always return false
// Line: 613
# $input = str_replace('return true;},getProtocol:f', 'return false;},getProtocol:f', $input);
}
break;
}
return $input;
}
I'm also offering one in exchange for linkbacks (see here).
@UncleP Thank you, you always been very very helpful. Keep it up and i just installed the version you suggested, working great. :)
@Codename Thank you so much, but the script you have, has got loads of bugs so its not fully functional, i would rather keep my visitor stucked with mobile version.
Alright. I'll keep working on the script. Hopefully I'll be able to eke more functionality out of it :)
If anyone who knows anything about AJAX wants to help me, I'm open to offers.