forked from lolcat/4get
added greppr support also btw im not dead
This commit is contained in:
@@ -36,7 +36,7 @@ class backend{
|
||||
}
|
||||
|
||||
// this function is also called directly on nextpage
|
||||
public function assign_proxy(&$curlproc, $ip){
|
||||
public function assign_proxy(&$curlproc, string $ip){
|
||||
|
||||
// parse proxy line
|
||||
[
|
||||
@@ -91,7 +91,7 @@ class backend{
|
||||
/*
|
||||
Next page stuff
|
||||
*/
|
||||
public function store($payload, $page, $proxy){
|
||||
public function store(string $payload, string $page, string $proxy){
|
||||
|
||||
$key = sodium_crypto_secretbox_keygen();
|
||||
$nonce = random_bytes(SODIUM_CRYPTO_SECRETBOX_NONCEBYTES);
|
||||
@@ -120,7 +120,7 @@ class backend{
|
||||
rtrim(strtr(base64_encode($key), '+/', '-_'), '=');
|
||||
}
|
||||
|
||||
public function get($npt, $page){
|
||||
public function get(string $npt, string $page){
|
||||
|
||||
$page = $page[0];
|
||||
$explode = explode(".", $npt, 2);
|
||||
|
@@ -925,6 +925,7 @@ class frontend{
|
||||
"google" => "Google",
|
||||
"qwant" => "Qwant",
|
||||
"yep" => "Yep",
|
||||
"greppr" => "Greppr",
|
||||
"crowdview" => "Crowdview",
|
||||
"mwmbl" => "Mwmbl",
|
||||
"mojeek" => "Mojeek",
|
||||
|
@@ -321,11 +321,11 @@ class fuckhtml{
|
||||
|
||||
throw new Exception("(getTextContent) Supplied array doesn't contain an innerHTML index");
|
||||
}
|
||||
|
||||
$html = $html["innerHTML"];
|
||||
}
|
||||
|
||||
$html =
|
||||
preg_split('/\n|<\/?br>/i', $html);
|
||||
$html = preg_split('/\n|<\/?br>/i', $html);
|
||||
|
||||
$out = "";
|
||||
for($i=0; $i<count($html); $i++){
|
||||
|
Reference in New Issue
Block a user