1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Lack of Interest [suggestion/bug?] Allow absolute paths for $config['development']['directory']

Discussion in 'Closed Suggestions' started by Mike Tougeron, Sep 8, 2011.

  1. Mike Tougeron

    Mike Tougeron Well-Known Member

    Would it be possible to allow absolute paths for $config['development']['directory'] ?

    XenForo_Model_Template::getTemplateDevelopmentDirectory() line 459:
    PHP:
    if ( substr($config->development->directory01) == '/' )
    {
        return 
    $config->development->directory '/file_output/templates';
    }
    else
    {
        return 
    XenForo_Application::getInstance()->getRootDir() . '/' $config->development->directory '/file_output/templates';
    }
     
  2. ragtek

    ragtek Guest

  3. Mike Tougeron

    Mike Tougeron Well-Known Member

    Nope. The current code prefixes the setting with XenForo_Application::getInstance()->getRootDir(). I want the development directory to be *outside* of the rootDir and I didn't want to use '../../' :p
    Yeah, I'm working on a patch for this as well so that it saves off every change someone makes so that we can save it into git. Working on another add-on that'll import templates for you as part of a "publish" process.
     
  4. ragtek

    ragtek Guest

    Sorry:D you're right. That's the standard behaviour in xf. I've forgotten that i changed this too.
     
  5. Jeremy

    Jeremy XenForo Moderator Staff Member

    I like this. Do you plan to release this?
     
  6. Mike Tougeron

    Mike Tougeron Well-Known Member

    Probably not. Depends on how 1.1.0-b3 works (I haven't had a chance to test it yet) since that allows you to use templates directly from the file system.
     
  7. Jeremy

    Jeremy XenForo Moderator Staff Member

    I don't have a link on hand, but I know Kier said it is compiled versions, so we can't utilize it to send templates to something via git, and have the <xen: syntax written and such. Something like this would be very useful for me. :)
     
  8. Mike Tougeron

    Mike Tougeron Well-Known Member

    Yeah, I need to look at the latest code before I decide for sure.
     

Share This Page