Jump to content

Site profile location in a var?


BUCKHORN
 Share

Recommended Posts

Hi, I can't seem to find a variable that would point me to the site profile folder. 

Need to create path to:

root/site/new_folder

the vars that I'm aware of only point to folders within templates. e.g.

root/site/assets

root/site/modules

root/site/templates

etc., but I can't find one for...

root/site

root/site-two (in the case of core multi site)

I know I can can simply remove the last part of the templates path, but there's got to be a cleaner way to do this, or Ryan did this intentionally to enforce the htaccess protection of php files inside the templates directory. (i probably just answered my question and will have to put my folder inside of templates)

Link to comment
Share on other sites

Thanks guys!

Nothing listed in cheatsheet for this variable. I thought about using $config->paths->root, however the site folder name is variable (as in the case of multi site), so I'm not sure how to find the variable name of the site folder to append to $config->paths->root. For example, my module wants a path to "site" for the default website and "site-website1" or "site-site2" or "site-whatever-i-name-this" in the case of multi-site. Maybe I have to use the config variable set in index-config.php, but I can't figure out how to access it. 

I know I can just use $config->paths->templates to get the site directory name, but it just seems to me that there ought to be something like what Teppo had mentioned... $config->paths->site. 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...