getNbGoogleResults

getNbGoogleResults ( string searchExpression , string[default:google.com] _search_engine , string[default:en] _language , int[default:US] _country , closure _actionOnError , string _method ) : int

Returns the number of results found by Google. It is the information after the search box on Google, the number in "About X results (Y seconds)".
It can be interesting to use this expression on Google "site:toto.com", because if you use site: before a host, you have a good estimation of the number of pages of a website.

This function can have long pause times (up to 5 minutes) in case of difficulty to communicate with Google. Conflict resolution procedures are included in the function.

Parameters

searchExpression

search expression in the Google text field

_search_engine (optional)

The domain name of google. Ex: google.com, google.fr, google.de

_language (optional)

The language you nedd (en, fr, de, nl, it, etc.). It is the hl parameter.
Language codeLanguage
te??????
haw??lelo Hawai?i
pcmNigerian Pidgin
gaaGa
fyFrysk
tt?????
roromân?
pa??????
fisuomi
mk??????????
trTürkçe
omOromoo
htHaitian Creole
tlhKlingon
rnIkirundi
tnTswana
tktürkmen dili
gaGaeilge
bg?????????
uk??????????
kriKrio (Sierra Leone)
chr???
gu???????
soSoomaali
xhisiXhosa
swKiswahili
lgLuganda
kn?????
ug????????
ar???????
my??????
tumTumbuka
hi??????
ko???
yi??????
ckb?????? ???????
svsvenska
eteesti
deDeutsch
miM?ori
achAcoli
azaz?rbaycan
gdGàidhlig
humagyar
hrhrvatski
brbrezhoneg
frfrançais
ta?????
mr?????
uzo‘zbek
es-419español (Latinoamérica)
ocOccitan
sksloven?ina
be??????????
ru???????
yoÈdè Yorùbá
pt-PTportuguês (Portugal)
rwKinyarwanda
snchiShona
sr??????
slslovenš?ina
cebBinisaya
isíslenska
nsoNorthern Sotho
crsSeychellois Creole
idIndonesia
or?????
mgMalagasy
bemIchibemba
iainterlingua
sd????
lnlingála
filFilipino
laLatin
si?????
ltlietuvi?
mtMalti
quRunasimi
nynRunyankore
xx-hackerHacker
xx-piratePirate
jwJawa
cacatalà
zh-CN?? (??)
fa?????
plpolski
tolea fakatonga
ne??????
suSundanese
afAfrikaans
cs?eština
lvlatviešu
hy???????
kk????? ????
nlNederlands
xx-elmerElmer Fudd
tlFilipino
ja???
sr-MEsrpski (Crna Gora)
ur????
nonorsk
ky????????
pt-BRportuguês (Brasil)
zh-TW?? (??)
ka???????
mn??????
th???
haHausa
esespañol
lo???
ititaliano
enEnglish
coCorsican
zuisiZulu
stSouthern Sotho
glgalego
mfekreol morisien
sqshqip
nnnynorsk
iw?????
cyCymraeg
woWolof
tg??????
bsbosanski
el????????
ti????
eeE?egbe
sr-Latnsrpski (latinica)
foføroyskt
viTi?ng Vi?t
gnGuarani
nyNyanja
ml??????
xx-borkBork, bork, bork!
akAkan
kgKongo
bn?????
km?????
am????
eoesperanto
igAs?s? Igbo
twTwi
msMelayu
banBalinese
rmrumantsch
luaLuba-Lulua
dadansk
lozLozi

_country (optional)

Country code. It is the gl parameter.
Country codeCountry
TJTajikistan
MYMalaysia
BZBelize
INIndia
PLPoland
FMMicronesia
SHSt. Helena
CKCook Islands
TRTurkey
ARArgentina
QAQatar
VNVietnam
LYLibya
IDIndonesia
KIKiribati
MDMoldova
UYUruguay
BABosnia & Herzegovina
MKNorth Macedonia
LALaos
MXMexico
SMSan Marino
GMGambia
AGAntigua & Barbuda
PAPanama
BTBhutan
UZUzbekistan
KWKuwait
MGMadagascar
TTTrinidad & Tobago
MTMalta
SCSeychelles
DJDjibouti
TWTaiwan
PKPakistan
KZKazakhstan
BSBahamas
DMDominica
GGGuernsey
AFAfghanistan
BHBahrain
CFCentral African Republic
BFBurkina Faso
RURussia
KHCambodia
PHPhilippines
MZMozambique
GRGreece
BJBenin
NENiger
MLMali
UAUkraine
NONorway
TDChad
LTLithuania
CICôte d’Ivoire
JPJapan
GBUnited Kingdom
VEVenezuela
CHSwitzerland
PTPortugal
GTGuatemala
AOAngola
DODominican Republic
IEIreland
JMJamaica
OMOman
BYBelarus
SOSomalia
TNTunisia
SNSenegal
CYCyprus
TMTurkmenistan
NUNiue
DZAlgeria
MSMontserrat
NRNauru
MWMalawi
ILIsrael
CGCongo - Brazzaville
JOJordan
BGBulgaria
BOBolivia
KGKyrgyzstan
GLGreenland
GAGabon
MAMorocco
VIU.S. Virgin Islands
SBSolomon Islands
LVLatvia
FIFinland
HKHong Kong
SVEl Salvador
AIAnguilla
GIGibraltar
NPNepal
FRFrance
SLSierra Leone
ESSpain
ASAmerican Samoa
BEBelgium
USUnited States
HNHonduras
CLChile
NZNew Zealand
BRBrazil
LSLesotho
FJFiji
LBLebanon
AUAustralia
CZCzechia
TLTimor-Leste
LULuxembourg
MVMaldives
BDBangladesh
MMMyanmar (Burma)
ITItaly
RWRwanda
IMIsle of Man
CVCape Verde
ZWZimbabwe
AMArmenia
AEUnited Arab Emirates
SESweden
BNBrunei
CUCuba
BIBurundi
PYParaguay
COColombia
PNPitcairn Islands
IQIraq
VUVanuatu
ETEthiopia
NLNetherlands
HUHungary
SASaudi Arabia
AZAzerbaijan
NANamibia
PEPeru
ZMZambia
CRCosta Rica
VGBritish Virgin Islands
TZTanzania
KEKenya
PGPapua New Guinea
EGEgypt
CMCameroon
RSSerbia
ADAndorra
WSSamoa
LILiechtenstein
GEGeorgia
CDCongo - Kinshasa
SGSingapore
JEJersey
SRSuriname
ISIceland
RORomania
KRSouth Korea
ATAustria
DKDenmark
TGTogo
THThailand
BWBotswana
DEGermany
ALAlbania
HRCroatia
NGNigeria
PSPalestine
ECEcuador
TOTonga
MUMauritius
NINicaragua
GYGuyana
SKSlovakia
PRPuerto Rico
STSão Tomé & Príncipe
MEMontenegro
UGUganda
MNMongolia
EEEstonia
HTHaiti
CACanada
LKSri Lanka
SISlovenia
VCSt. Vincent & Grenadines
GHGhana
ZASouth Africa

_actionOnError (optional)

Execute an action if Google return an error. Very useful to change IP when Google think you are a robot.
serpGoogle("keyword",null,null,null,null,null,null, {-> changeProxy(["method":"nordvpn_by_command","zone":"europe"]) })

_method (optional)

• "firefox" (by default): uses Firefox and the extension of firefox to communicate with Google. With this option, you must specify the Grimport key of the Firefox extension.
• "internalRequests": uses a series of queries programmed in Grimport to communicate with Google.