7 Replies Latest reply on May 19, 2017 2:58 PM by Steve Sommers

    How to instantiate a component inside a directory containing a dot (.) character without a mapping?


      Path to the CFC I'm trying to instantiate is:




      where "/webroot" is a ColdFusion mapping to the actual web root. I'm trying to make this work *without* having to create a mapping.


      I'm using CreateObject(). I can't use the dot-notation format (webroot.client.com.cllient.www.model.SomeComponent) because the directory name "com.client.www" would be interpreted as 3 levels deep which is wrong, it's one directory name. So, I'm using the path instead. However a path with a directory with a dot in the name appears to confuse ColdFusion. For example, this works:


      CreateObject("component", "/webroot/client/website/model/SomeComponent")


      but this does not:


      CreateObject("component", "/webroot/client/com.client.www/model/SomeComponent")


      Clearly the dots are causing some trouble. The reverse domain name format I've got here is a silly old thing that we're migrating away from, but in the mean time old projects have this format so we've got to deal with it.


      I've done a lot of Googling and can't find anything other than a lone blog page from 7 years ago saying that you've got to create a CF mapping. Surely there is another way! Thanks for any help you can provide!


      EDIT: Running ColdFusion Server 9,0,2,282541 on Ubuntu.