• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

dot notation in cfc

New Here ,
May 29, 2007 May 29, 2007

Copy link to clipboard

Copied

Hi,
Can someone help me with this?
I have a directory that uses a dot in its name, like robedob.com as the name of the directory. in this directory I have a cfc directory. How can I use dot notation to invoke a cfc object like that:
<cfobject component="dev.[directory name].cfc.Client" name="ObjClient"> if the directory name has a dot in it?

Will this work? <cfobject component="dev.robedob.com.cfc.Client" name="ObjClient">
TOPICS
Advanced techniques

Views

1.1K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Engaged , Jun 14, 2007 Jun 14, 2007
Ask your host to create a named virtual directory to that folder for you and reference that instead.

Votes

Translate

Translate
LEGEND ,
May 29, 2007 May 29, 2007

Copy link to clipboard

Copied

What happened when you tried it?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 14, 2007 Jun 14, 2007

Copy link to clipboard

Copied

Sorry for the delay. I get this message:
Could not find the ColdFusion Component dev.robedob.com.cfc.Client

So, it looks for the following path:
dev/robedob/com/cfc
instead of this:
dev/robedob.com/cfc

Any suggestion?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Jun 14, 2007 Jun 14, 2007

Copy link to clipboard

Copied

Try

<cfobject component="/dev/robedob.com/cfc/Client" name="ObjClient">

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 14, 2007 Jun 14, 2007

Copy link to clipboard

Copied

Got the same result but with the slashes instead of the dots in the answer.

If nothing else works, i will place the cfcs in the same directory as the calling page, which is the application.cfm. It's just bugging me this dot notation. I also tried with a backshlash like that:
dev.robedob\.com.cfc.Client
and the forward slash like that:
dev.robedob\.com.cfc.client
but had no better luck.

I'm still hoping there is a solution to that problem.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jun 14, 2007 Jun 14, 2007

Copy link to clipboard

Copied

Do you have a default location for components on your administrator?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 14, 2007 Jun 14, 2007

Copy link to clipboard

Copied

No. I'm on a shared server and the administrator will not let me set it up.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 14, 2007 Jun 14, 2007

Copy link to clipboard

Copied

Ask your host to create a named virtual directory to that folder for you and reference that instead.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jun 18, 2007 Jun 18, 2007

Copy link to clipboard

Copied

I am confused. If in the base of your web site, you have a folder called
cfcs/my/component.cfc. All you should have to do is call it by:

cfcs.my.component or <cfobject name=MyObject"
component="cfcs.my.component"/>

Where ever the first index.cfm for your site is located (the home page) is
the base of your site.

I am on shared hosting and the path to my cfcs are pet/store/cfcs/. It comes
up as www.mysite.com/pet/store/cfcs.

The location to my component (myComponent.cfc) is then:

<cfobject name="MyPetObject" component="pets.store.cfcs.myComponent"/>

Does that help?


Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jun 18, 2007 Jun 18, 2007

Copy link to clipboard

Copied

one last piece:

The actual web root on my web hosting is
E:/wwwroot/mywebsite.com/pet/store/cfcs/. So the first part does not matter
because the actually hosting maps your site to E:/wwwroot/mywebsite.com so
it actually starts with the pet folder at the base.

Judging by how you listed your site it may just be

<cfobject name="ClientObj" component="cfc.Client"/>


Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 18, 2007 Jun 18, 2007

Copy link to clipboard

Copied

LATEST
Thanks for the information. It sure helps. I will give it a try to see if this works. Since my last post, I was able to convince my colocation web administrator to create a path in cf admin, and it works since he created that path.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation