Re: location of the PHP executable

From: Date: Wed, 11 Apr 2007 22:09:33 +0000
Subject: Re: location of the PHP executable
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-252641@lists.php.net to get a copy of this message
Em Quarta 11 Abril 2007 18:50, Jarrel Cobb escreveu: > Don't you have to run locate -u first to generate the database before using > locate? You can't just assume a database exists already can you? > If you can use locate, you can use which... =P BTW, do something to check OS then: IF OS == *nix THEN IF exists /usr/bin/which THEN which php ELSE IF exists /usr/bin/locate THEN IF db not exists THEN locate -u END-IF locate php | grep -iE "php$" ELSE IF exists /usr/bin/find THEN find / -name php | grep -iE "php$" ELSE cd / && ls php -Rv END-IF END-IF END-IF ELSE cd \ dir php*.exe /s END-IF Check if I don't miss any END-IF... =P []s -- Davi Vidal davividal@siscompar.com.br davividal@gmail.com -- Agora com fortune: "rugged, adj.: Too heavy to lift."

« previous php.general (#252641) next »