Results 11 to 13 of 13
-
18th Aug 2011, 10:50 AM #11MemberWebsite's:
scrls.co.ukI cant seem to sort the full fileserve and also create a wupload one to work aswell, i will keep trying but they are the only problems i am encountering.
-
18th Aug 2011, 11:36 AM #12Respected MemberWebsite's:
DL4Everything.com Soft2050.inBetter check the post by v3g3ta in your thread:
To use it with phpuploader:
Open includes/functions.php
Replace existing "fscurl" function with:
PHP Code:function fscurl($link, $postfields = '', $cookie = '')
{
$ch = curl_init($link);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($ch, CURLOPT_REFERER, 'http://www.fileserve.com/');
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Expect:'));
if ($postfields) {
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields);
}
if ($cookie) {
curl_setopt($ch, CURLOPT_COOKIE, $cookie);
curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie);
curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie);
}
$page = curl_exec($ch);
return($page);
curl_close($ch);
}
PHP Code:function rndNum($lg) {
$str = "0123456789";
for ($i = 1; $i<=$lg; $i++) {
$st = rand(0, 9);
$pnt = substr($str, $st, 1);
}
return $pnt;
}
PHP Code:function uploadtofs($filelocation, $ufsuser, $ufspass)
{
$post = array();
$post["autoLogin"] = true;
$post["loginUserName"] = $ufsuser;
$post["loginUserPassword"] = $ufspass;
$post["loginFormSubmit"] = "LOGIN";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "http://fileserve.com/login.php");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($ch, CURLOPT_UNRESTRICTED_AUTH, 1);
curl_setopt($ch, CURLOPT_REFERER, "http://www.fileserve.com/");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)");
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Expect:'));
$result = curl_exec($ch);
curl_close($ch);
preg_match("/cookie=[a-zA-Z0-9%]+/i", $result, $matches);
$doughnut = $matches[0]; //This is the cookie
$result = fscurl("http://www.fileserve.com/", "", $doughnut);
preg_match('#action="http://upload.fileserve.com/upload/(.*)"#', $result, $matches);
$rnd = time() . rndNum(3);
$rnd_id = rndNum(5);
$server = 'http://upload.fileserve.com/upload/' . $matches[1];
$page = fscurl($server . "?callback=jsonp" . $rnd . "&_=" . $rnd_id, "", $doughnut);
preg_match('#sessionId\:\'(.*)\'}#', $page, $match);
$uploadSessionId = $match[1].'/';
$postfields = array();
$postfields['file'] = "@$filelocation";
$page = fscurl($server . $uploadSessionId, $postfields, $doughnut);
preg_match('#"shortenCode":"(.*)"}#', $page, $match);
$linkId = $match[1];
if ($match[1])
$downloadlink = 'http://www.fileserve.com/file/' . $match[1];
else
$downloadlink = FALSE;
return $downloadlink;
}
Edit: You need to update the function "uploadtofs" in plugins/uploadhosts.php
1. Filelocation - leave it as it was
2. Username = usually $ufsuser
3. Password = usually $ufspass
It works!
-
18th Aug 2011, 11:39 AM #13MemberWebsite's:
scrls.co.ukdamn, i was doing that but i forgot to change the variable lol .. thanks for that mate +1
Sponsored Links
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
any update for phpuploader??
By mr-cracker in forum General DiscussionReplies: 2Last Post: 27th Apr 2011, 09:34 PM -
phpUploader v2.1 Vanilla
By djakil in forum Webmaster DiscussionReplies: 7Last Post: 29th Dec 2010, 10:47 AM -
[Selling] phpUploader 2.5 ($ 4)
By ShareShiz in forum Completed TransactionsReplies: 18Last Post: 10th Oct 2010, 09:02 AM -
[WTB] VPS for TF and phpUploader
By t3od0r in forum Hosting DiscussionReplies: 5Last Post: 29th Sep 2010, 11:17 AM -
phpUploader or RapidLeech or RDP?
By iFlames in forum Polling PlazaReplies: 28Last Post: 19th Sep 2010, 02:22 PM
themaLeecher - leech and manage...
Version 5.03 released. Open older version (or...