fix API fetching to variables

This commit is contained in:
thecashewtrader 2024-05-24 14:13:21 +05:30
parent ddcac1b168
commit cc44911ea1
2 changed files with 51 additions and 51 deletions

File diff suppressed because one or more lines are too long

100
index.php
View file

@ -66,56 +66,56 @@ $time_cg = date("H:i:s", $api_cg->time);
$time = $time_cg; $time = $time_cg;
// Holt die einzelnen Werte für die Berechnung // Holt die einzelnen Werte für die Berechnung
$BTC = $api_cg->btc->lastValue; $BTC = $api_cg->btc;
$EUR = $api_cg->eur->lastValue; $EUR = $api_cg->eur;
$USD = $api_cg->usd->lastValue; $USD = $api_cg->usd;
$CHF = $api_cg->chf->lastValue; $CHF = $api_cg->chf;
$LTC = $api_cg->ltc->lastValue; $LTC = $api_cg->ltc;
$CAD = $api_cg->cad->lastValue; $CAD = $api_cg->cad;
$AUD = $api_cg->aud->lastValue; $AUD = $api_cg->aud;
$HKD = $api_cg->hkd->lastValue; $HKD = $api_cg->hkd;
$SGD = $api_cg->sgd->lastValue; $SGD = $api_cg->sgd;
$GBP = $api_cg->gbp->lastValue; $GBP = $api_cg->gbp;
$RUB = $api_cg->rub->lastValue; $RUB = $api_cg->rub;
$ZAR = $api_cg->zar->lastValue; $ZAR = $api_cg->zar;
$TRY = $api_cg->try->lastValue; $TRY = $api_cg->try;
$JPY = $api_cg->jpy->lastValue; $JPY = $api_cg->jpy;
$PLN = $api_cg->pln->lastValue; $PLN = $api_cg->pln;
$INR = $api_cg->inr->lastValue; $INR = $api_cg->inr;
$AED = $api_cg->aed->lastValue; $AED = $api_cg->aed;
$ETH = $api_cg->eth->lastValue; $ETH = $api_cg->eth;
$UAH = $api_cg->uah->lastValue; $UAH = $api_cg->uah;
$KRW = $api_cg->krw->lastValue; $KRW = $api_cg->krw;
$BRL = $api_cg->brl->lastValue; $BRL = $api_cg->brl;
$MYR = $api_cg->myr->lastValue; $MYR = $api_cg->myr;
$CNY = $api_cg->cny->lastValue; $CNY = $api_cg->cny;
$XAU = $api_cg->xau->lastValue; $XAU = $api_cg->xau;
$XAG = $api_cg->xag->lastValue; $XAG = $api_cg->xag;
$VND = $api_cg->vnd->lastValue; $VND = $api_cg->vnd;
$VEF = $api_cg->vef->lastValue; $VEF = $api_cg->vef;
$THB = $api_cg->thb->lastValue; $THB = $api_cg->thb;
$SAR = $api_cg->sar->lastValue; $SAR = $api_cg->sar;
$SEK = $api_cg->sek->lastValue; $SEK = $api_cg->sek;
$PKR = $api_cg->pkr->lastValue; $PKR = $api_cg->pkr;
$NOK = $api_cg->nok->lastValue; $NOK = $api_cg->nok;
$LKR = $api_cg->lkr->lastValue; $LKR = $api_cg->lkr;
$MMK = $api_cg->mmk->lastValue; $MMK = $api_cg->mmk;
$HUF = $api_cg->huf->lastValue; $HUF = $api_cg->huf;
$ILS = $api_cg->ils->lastValue; $ILS = $api_cg->ils;
$KWD = $api_cg->kwd->lastValue; $KWD = $api_cg->kwd;
$NGN = $api_cg->ngn->lastValue; $NGN = $api_cg->ngn;
$NZD = $api_cg->nzd->lastValue; $NZD = $api_cg->nzd;
$PHP = $api_cg->php->lastValue; $PHP = $api_cg->php;
$IDR = $api_cg->idr->lastValue; $IDR = $api_cg->idr;
$TWD = $api_cg->twd->lastValue; $TWD = $api_cg->twd;
$ARS = $api_cg->ars->lastValue; $ARS = $api_cg->ars;
$BDT = $api_cg->bdt->lastValue; $BDT = $api_cg->bdt;
$BHD = $api_cg->bhd->lastValue; $BHD = $api_cg->bhd;
$BMD = $api_cg->bmd->lastValue; $BMD = $api_cg->bmd;
$CLP = $api_cg->clp->lastValue; $CLP = $api_cg->clp;
$CZK = $api_cg->czk->lastValue; $CZK = $api_cg->czk;
$DKK = $api_cg->dkk->lastValue; $DKK = $api_cg->dkk;
$MXN = $api_cg->mxn->lastValue; $MXN = $api_cg->mxn;
// Lädt die Sprachdatei, nach der Sprache die im Browser eingestellt wurde // Lädt die Sprachdatei, nach der Sprache die im Browser eingestellt wurde
if(array_key_exists('HTTP_ACCEPT_LANGUAGE', $_SERVER)){ if(array_key_exists('HTTP_ACCEPT_LANGUAGE', $_SERVER)){