Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > it.comp.www.php > #20210

Re: caricare file

From liftman <liftman_antispam_@moredifficult.org>
Newsgroups it.comp.www.php
Subject Re: caricare file
Date 2016-01-14 17:52 +0100
Organization Aioe.org NNTP Server
Message-ID <n78jo9$1pb3$1@gioia.aioe.org> (permalink)
References <n6mn1f$uee$1@solani.org> <n72q6q$2ub9$1@adenine.netfront.net> <n755e3$fho$1@solani.org> <n77t2l$ool$1@adenine.netfront.net> <n78csl$hoo$1@solani.org>

Show all headers | View raw


Il 14/01/2016 15:55, Greg ha scritto:

>> <?php
>> echo $_SERVER['DOCUMENT_ROOT'];exit();
>>
>> Se ne esce:
>> '/var/www/html'

> Con questa funzione:
>
> <?php
> $path = getcwd();
> echo "percorso: ";
> echo $path;
> ?>
>
> eseguita qualche giorno fa mi dava /membri/miosito
> ma magari avranno cambiato

usando il sistema proposto da Alex ottengo:

echo $_SERVER['DOCUMENT_ROOT'];exit();
percorso: /var/www/html

con il tuo sistema invece ottengo:

$path = getcwd();
echo "percorso: ";
echo $path;
percorso: /membri/miosito

ovviamente sul medesimo dominio :-)
Il perchè del diverso comportamento non lo so, ma immagino che il primo 
mostri la root del webserver (terminologia forse inappropriata, ma 
abbiate pietà...), ed il secondo la directory dove si trovano i file 
php|html. In pratica sono 2 funzioni simili ma diverse :-)

-- 
Fri(END), Boyfri(END), Girlfri(END), Bestfri(END). Everything has an END 
except...Fam(ILY)! It Has 3 Letters that say I LOVE YOU

Back to it.comp.www.php | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

caricare file Greg <greg@alicie.com> - 2016-01-07 22:58 +0100
  Re: caricare file "ciccio" <21669invalid@mynewsgate.net> - 2016-01-07 22:08 +0000
    Re: caricare file Greg <greg@alicie.com> - 2016-01-07 23:41 +0100
      Re: caricare file Greg <greg@alicie.com> - 2016-01-08 00:07 +0100
        Re: caricare file Greg <greg@alicie.com> - 2016-01-08 00:23 +0100
      Re: caricare file Alessandro Pellizzari <shuriken@amiran.it> - 2016-01-09 08:05 +0000
  Re: caricare file liftman <liftman_antispam_@moredifficult.org> - 2016-01-08 00:34 +0100
    Re: caricare file Greg <greg@alicie.com> - 2016-01-08 08:40 +0100
      Re: caricare file liftman <liftman_antispam_@moredifficult.org> - 2016-01-08 12:08 +0100
        Re: caricare file Greg <greg@alicie.com> - 2016-01-08 13:41 +0100
          Re: caricare file liftman <liftman_antispam_@moredifficult.org> - 2016-01-08 15:18 +0100
            Re: caricare file Greg <greg@alicie.com> - 2016-01-08 20:32 +0100
              Re: caricare file Andrea D'Amore <anddam+NOSPAM@brapi.net> - 2016-01-08 21:01 +0100
                Re: caricare file Greg <greg@alicie.com> - 2016-01-08 22:11 +0100
                Re: caricare file Andrea D'Amore <anddam+NOSPAM@brapi.net> - 2016-01-09 08:04 +0100
                Re: caricare file Greg <greg@alicie.com> - 2016-01-09 08:19 +0100
                Re: caricare file logicmind <npaolini_no_spam_@_no_spam_ennepisoft.it> - 2016-01-09 12:39 +0100
                Re: caricare file Greg <greg@alicie.com> - 2016-01-09 13:44 +0100
                Re: caricare file Alessandro Pellizzari <shuriken@amiran.it> - 2016-01-09 15:57 +0000
                Re: caricare file "ciccio" <21669invalid@mynewsgate.net> - 2016-01-09 16:03 +0000
                Re: caricare file Greg <greg@alicie.com> - 2016-01-09 20:37 +0100
  Re: caricare file Andrea D'Amore <anddam+NOSPAM@brapi.net> - 2016-01-08 07:17 +0100
  Re: caricare file Alex <tommaso5ita@yahoo.it> - 2016-01-12 13:04 +0100
    Re: caricare file Greg <greg@alicie.com> - 2016-01-13 10:29 +0100
      Re: caricare file liftman <liftman_antispam_@moredifficult.org> - 2016-01-13 14:13 +0100
      Re: caricare file Alex <tommaso5ita@yahoo.it> - 2016-01-14 11:24 +0100
        Re: caricare file Greg <greg@alicie.com> - 2016-01-14 15:55 +0100
          Re: caricare file Alex <tommaso5ita@yahoo.it> - 2016-01-14 17:21 +0100
          Re: caricare file Alex <tommaso5ita@yahoo.it> - 2016-01-14 17:27 +0100
          Re: caricare file liftman <liftman_antispam_@moredifficult.org> - 2016-01-14 17:52 +0100
            Re: caricare file Greg <greg@alicie.com> - 2016-01-16 15:24 +0100
              Re: caricare file Alessandro Pellizzari <shuriken@amiran.it> - 2016-01-16 18:37 +0000
                Re: caricare file Greg <greg@alicie.com> - 2016-01-16 19:57 +0100
                Re: caricare file Andrea D'Amore <anddam+NOSPAM@brapi.net> - 2016-01-16 21:45 +0100
                Re: caricare file Greg <greg@alicie.com> - 2016-01-16 22:10 +0100
                Re: caricare file Andrea D'Amore <anddam+NOSPAM@brapi.net> - 2016-01-17 09:02 +0100
  Re: caricare file fmigliori <fmigliori@gmail.com> - 2016-01-17 04:09 -0800
    Re: caricare file "ciccio" <21669invalid@mynewsgate.net> - 2016-01-17 12:34 +0000
      Re: caricare file Greg <greg@alicie.com> - 2016-01-18 09:52 +0100
        Re: caricare file "ciccio" <21669invalid@mynewsgate.net> - 2016-01-18 09:08 +0000
          Re: caricare file Greg <greg@alicie.com> - 2016-01-19 16:30 +0100
    Re: caricare file Andrea D'Amore <anddam+NOSPAM@brapi.net> - 2016-01-18 17:11 +0100

csiph-web