LemonStand Forum: Theme resource directory and cms template folder - LemonStand Forum

Jump to content

Severity 0 - None Assigned Status
Version - Fixed in -

Page 1 of 1
  • Cannot start a new Issue
  • You cannot reply to this issue

Report ID #186: Theme resource directory and cms template folder

#1 User is offline  
EHLOVader 

  • LemonElite
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 309
  • Joined: 05-May 11

Posted 04 April 2012 - 09:36 PM

It appears that using custom file based theme / template folders isn't translating to the theme's resource directory.

/theme/ is hard coded in the CMS_theme class

		public static function get_themes_path($absolute = true)
		{
			$result = "/themes/";
			if (!$absolute)
				return $result;
				
			return PATH_APP.$result;
		}


I believe it should be using the CMS_settingsmanager get_templates_dir_path method right? or was I still required to keep the themes directory for resources only?

I also found that the resources dir is hardcoded into the theme resource. Is there any way to define the folder which should be used?

		/**
		 * Returns path to the theme resources directory 
		 * relative to the application root directory.
		 * @return string
		 */
		public function get_resources_path()
		{
			return self::get_themes_path(false).$this->code.'/resources';
		}


not sure if that could use CMS_settingsManager's resources_dir_path directly.

This post has been edited by EHLOVader: 11 April 2012 - 01:30 PM



Page 1 of 1  
  • Cannot start a new Issue
  • You cannot reply to this issue

Replies (1 - 1)

#2 User is offline  
EHLOVader 

  • LemonElite
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 309
  • Joined: 05-May 11

Posted 11 April 2012 - 01:42 PM

I am trying to think about this, and I am not sure if file based cms should go into the same folders as the resources. If anyone was using HTM file extensions it could expose files. Although I use PHP extension and would be fond of having all the theme stuff in the same folder, I will retract my previous assumptions and move files on my server.

Thanks


Page 1 of 1
  • Cannot start a new Issue
  • You cannot reply to this issue

0 User(s) are reading this issue
0 Guests and 0 Anonymous Users