[Cartoweb-users] Folder Structures

Alexandre Saunier alexandre.saunier at camptocamp.com
Mon Nov 28 08:09:53 EST 2005


Hello,

here are a few guidelines and minimal instructions to build a new project:

* create the main project file in <cartoweb_root>/htdocs/ (in your case 
c:\wamp\www\cartoweb3\htdocs\) for instance by copying demoCW3.php and 
updating the ENV variable with your project name

* create a new directory in <cartoweb_root>/projects/ and name it with 
your project name.

* in the latter directory, add your project specific files. 
Subdirectories structure must be copied on the upstream structure 
(directories outside of <cartoweb_root>/projects/) or on the demoCW3 
project structure.

* in a command line prompt, go to <cartoweb_root>/ and run:
cw3setup.php --install --base-url http://localhost/cartoweb3/htdocs/
This command is needed to make the project resources available in 
<cartoweb_root>/htdocs/ which should be the only web-accessible 
directory on a well-configured production site.

=> this is the reason why some files seems duplicated in 
<cartoweb_root>/htdocs/<your_project>/
=> DO NOT EDIT files outside of <cartoweb_root>/projects/<your_project>/
If your need to update the associated resource, run cw3setup.php 
--install... after your changes in the project directory.

Finally, note that the demoCW3 project is a convenient example on how to 
  build a project but it is not always the best start point. In most 
cases  it is easier to build a project from scratch and only add the 
files you really need.

AS


Paul Shapley wrote:
> Hello again,
> 
> I just need to understand a couple of things about the folder
> structure of Cartoweb3. Firstly, i'm assuming that in order for the
> demo to work with my own data i need to ensure that 'cw3setup.php' is
> pointing to the ../cartoweb3/htdocs folder.
> 
> Secondly, there are two 'My_Project' folders in the following locations
> 
> .../cartoweb3/htdocs/My_Project/ ...and
> .../cartoweb3/Projects/My_Project/
> 
> again i'm assuming that the 'htdocs' is the only one i need to concern
> myself with.
> 
> Could someone confirm my confusion (easily done)!.
> 
> As i understand this i need to copy the 'demoCW3' folder from
> .../cartoweb3/htdocs to the '.../cartoweb3/htdocs/My_Project' folder
> and copy the demoCW3.php (from htdocs) into the same location
> (My_Project). I then change the 'ENV variable' to 'My_Project' and
> save with an alternative name to demoCW3.php (this last bit i'm not
> sure i've understood).
> 
> Can you confirm that i'm pointing the files in the right places.
> 
> Many thanks,
> 
> Paul Shapley
> 
> P.S Sorry to go on about this, i just need to understand the setup in
> 'laymans' terms.
> 
> _______________________________________________
> Cartoweb-users mailing list
> Cartoweb-users at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/cartoweb-users


More information about the Cartoweb-users mailing list