Where do you put your resource files?

I've been putting my resources folder in the same location as my system, index.php, and application folders. I try to hide my application and system paths as much as possible and I feel that the tendency to need to put full path names for certain objects will reveal the existence of my app and system folders if I put the resources there. But I've seen other people suggest putting resources in you application folder. Where do you put yours, and why?

I put mine like this:

-- assets
---- css
---- js
---- img
---- ico
---- media


Right. Closely coupling a set of assets with a given application. And that makes sense like that. Do you hide your paths in your output html in some way? Just for security I don't want "application" to show up in my paths if I can help it (or whatever the application folder is called).

It was your suggesting that very structure that prompted me to start this thread.

I personally do it like:
- index.php
- favicon.ico
- application
- assets
-- css
-- imgs
-- js
- system

Ah! Another user of XAMPP here. Smile

I've been tending to classify my favicon as an asset and moving it into that folder for consistency. Other than the obligatory index.php and .htaccess files I try to keep my root clear of anything but folders.

I prefer to keep my assets/resources outside of the CI app. Generally I just create a directory called "assets" in the web root and drop my css, images, js, etc, in there.

If it's a themed app, I keep the assets with the theme.

Where do you put the theme?

- /application
- /codeigniter_X.X
- /public_html
  - index.php
  - .htaccess
  - /public
    - /css
    - /js
    - /img
Only index.php and public are accessible from 'the outside'.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.