Ver Mensaje Individual
  #1 (permalink)  
Antiguo 18/03/2009, 18:19
chcma
 
Fecha de Ingreso: junio-2003
Ubicación: Asturias
Mensajes: 2.429
Antigüedad: 20 años, 11 meses
Puntos: 7
Duda con include... no sé si es por el DirectorioVirtual o si tengo algo mal

Buenas foreros !!!

Vereis, tengo un directorio virtual en apache apuntando a un directorio, con esta configuracion (Pongo lo que creo es relevante):

Código:
DocumentRoot "C:/webs"

<Directory "C:/webs">	
    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.2/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   Options FileInfo AuthConfig Limit
    #
    AllowOverride None

    #
    # Controls who can get stuff from this server.
    #
    Order allow,deny
    Allow from all

</Directory>


Alias /webPisosBasura "C:\WEBS\Proyecto PisosBasura"
<Directory "C:/webs/Proyecto PisosBasura">	
    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.2/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   Options FileInfo AuthConfig Limit
    #
    AllowOverride None

    #
    # Controls who can get stuff from this server.
    #
    Order allow,deny
    Allow from all
</Directory>
Muy bien, dento de "C:\WEBS\Proyecto PisosBasura" tengo una página .php que está intentando hacer un inlcude de otro fichero.php que está dentro de una carpeta.

include('/capaBL/PisosBL.php'); //ASI ME FALLA

include('capaBL/PisosBL.php'); //ASI ME FUNCIONA


No sé si estoy haciendo algo mal, o es que el include no entiendo que quiero que busque el archivo desde la raiz del directorio virtual....

Mi intención es que cuando en una página .php que esté dentro de una carpeta, también pueda incluir los ficheros .php, de una forma cómoda, es decir, buscándolos desde el raiz del directorio...

¿Qué es lo que hago mal?
__________________
Charlie.