首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Flex ColdFusion CFC定位

Flex ColdFusion CFC定位
EN

Stack Overflow用户
提问于 2009-04-21 14:02:18
回答 3查看 1.2K关注 0票数 3

我是一个ColdFusion开发人员,想要破解Flex。我有两个测试Flex应用程序,我正在工作,但有问题,连接到我的CFCs。我试过:

  • 在CFAdmin中创建映射,
  • 将CFC放在与Flex应用程序相同的文件夹中,
  • 将CFC放入C:\Coldfusion8 8\Gateway\CFC文件夹,

一切都没有结果。

每次,我都会收到“无法找到ColdFusion组件或接口”错误。我遗漏了什么?

下面是如何调用CFC来使用Flex。

代码语言:javascript
复制
 <mx:RemoteObject id="conn" destination="ColdFusion" source="cfc.bulkmail"
    result="orderGrid.dataProvider = event.result;" showBusyCursor="true">
EN

回答 3

Stack Overflow用户

回答已采纳

发布于 2009-04-21 14:32:23

C:\Coldfusion8\wwwroot\Gateway\CFC是正确的文件夹,cfc.bulkmail是正确的源。

起作用了,我一定是在某种程度上没有找到合适的情况。

但对于将来有同样问题的人来说,这是一个答案。

票数 0
EN

Stack Overflow用户

发布于 2009-04-21 17:26:25

您还可以进入远程-config.xml文件(coldfusionRootwwwroot\WEB\flex),并启用对coldfusion实例的映射。默认情况下,不允许Flex使用映射来定位cfc实例。

代码语言:javascript
复制
<destination id="ColdFusion">
    <channels>
        <channel ref="my-cfamf"/>
    </channels>
    <properties>
        <source>*</source>
        <!-- define the resolution rules and access level of the cfc being invoked -->
        <access>
            <!-- Use the ColdFusion mappings to find CFCs, by default only CFC files under your webroot can be found. -->
            <use-mappings>false</use-mappings>
            <!-- allow "public and remote" or just "remote" methods to be invoked -->
            <method-access-level>remote</method-access-level>
        </access>

        <property-case>
            <!-- cfc property names -->
            <force-cfc-lowercase>false</force-cfc-lowercase>
            <!-- Query column names -->
            <force-query-lowercase>false</force-query-lowercase>
            <!-- struct keys -->
            <force-struct-lowercase>false</force-struct-lowercase>
        </property-case>
    </properties>
</destination>

你所看到的是默认的。将使用映射键更改为true,您的映射现在就可以工作了。

票数 2
EN

Stack Overflow用户

发布于 2009-04-21 14:25:45

我在某些服务器上也有类似的问题。我认为这与如何在您的网站上设置安全性有关。最后,我选择了一条简单的路线,并将我的CFC方法远程访问,并将它们称为WebServices。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/772732

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档