5

嘿,我有一个关于 ColdFusion 和 PHP 兼容性的问题。

我们建立了一个基于 ColdFusion 的社区网站。是否完全可以用 PHP 向我们的网站添加诸如博客和其他社区功能之类的功能?

我的意思是将 PHP 和 ColdFusion 结合在一起。

非常感谢您的帮助!

4

5 回答 5

4

如果您使用的是 ColdFusion 8,我认为可以做到。我知道 Sean Corfield 在 RIAForge 上有一个项目正在做这种事情,他的博客上有一系列帖子,从这个开始:

http://corfield.org/blog/index.cfm/do/blog.entry/entry/ColdFusion_8_running_PHP

综上所述,集成来自相同核心语言的产品会更容易。ColdFusion 中有数百个用于不同事物的开源选项。RIAForge.org是一个很好的起点。

于 2009-02-06T18:09:23.497 回答
3

Your question wasn't really focused enough to give a single direct correct answer.

We built a community website which is based on ColdFusion. Is it altogether possible to add features such as blogs, and other community features to our website in PHP?

I mean to combine both PHP and ColdFusion together.

When you say you want to "combine" them, what exactly do you mean? They can both co-exist on a web server and both have access to the same database; so if you want both PHP and ColdFusion applications to have access to the same data, that is not a problem at all. There would be some concerns about locking and race conditions, but from an "is this possible?" standpoint, the answer is undoubtedly YES.

Sharing session, client, or other special scopes/variables from CF to PHP should be possible with some clever programming, but would be tricky. It would depend entirely on your needs and your implementation.

If you're looking for applications to add to your community, I would recommend that you try to find something in CFML that suits your needs before you go the route of attempting to mix CFML and PHP. There are tons of free open source applications including blogs and wikis written in CFML available on RIAForge, and other websites. Canvas Wiki, and Codex Wiki are solutions that focus strictly on Wiki functionality, and there are others that include Wiki functionality as part of a larger package. Searching for "blog" in the ColdFusion category on RIAForge shows no less than 6 blogging applications like BlogCFC and others, and that doesn't even include my personal favorite, Mango Blog.

于 2009-02-07T16:22:34.460 回答
3

是的,这是可能的。您可能必须将 PHP 应用程序的会话管理集成到您的 Coldfusion 应用程序的会话管理中。

我最近在 Coldfusion 中使用 PHP 购物车做到了这一点,因为我没有时间或资源来在 Coldfusion 中获得相同的结果——通常 CF 中出色且精美的部分可能会花费一些钱,而使用 PHP 是一场赌博或者一个时间坑,让它随心所欲地跳舞。

其次,在 Coldfusion 中可能已经有适合您需求的博客、论坛等。去看一下。您可能会更倾向于一个平台。您可能需要一个 PHP 解决方案,因为它有插件或其他您不想编程的东西。

我喜欢你最好的方法,Coldfusion 总体上比开源有更多的商业开发,当涉及到功能令人难以置信的大型软件包时。

祝你好运,一定要分享你最终做了什么。


于 2009-02-06T19:46:25.907 回答
2

我认为 Corfield 的方式不是(非常)适合博客和论坛等独立应用程序。但它可以帮助共享会话。

另一方面,这些类型的软件在 CF 世界中并不是那么好。

我最好建议使用网络服务器设置。关于 IIS 不能说太多,但在 Apache 中,您通常对 .cfm 和 .php 文件使用不同的处理程序。这里可能的问题是索引文件,可以是 index.cfm 或 index.php。在这种情况下 .htaccess 规则应该会有所帮助。

因此,调整网络服务器允许在 CF 应用程序的子目录中使用 PHP 应用程序。

其他可能性是使用子域,这更容易设置,可以满足您的需求。比如说 blog.website.com 和 forum.website.com

希望这可以帮助。

于 2009-02-06T18:21:04.130 回答
1

向楼主提问:抱歉这么奇怪的回复,我还不能在这里发表评论。也为小型机顶感到抱歉。

致 Ray Camden:是的,我是说CF 的开源论坛/博客不如 PHP 好。我很高兴知道 Galleon 和 BlogCFC。但如果谈论特性——它们是 2006 年的 PHP 类似物,尤其是 Galleon。BlogCFC 快速成长并变得更好。

无论如何,我怀疑许多 BlogCFC 用户使用它,因为它是用 CFML 编写的。我也是,部分。

问题不在于这两个应用程序,它们可以满足某人的需求。问题是没有其他选择。或者也许我在这里错了,还有很多这些类型的其他很酷的应用程序?

是的。也许还有其他令人惊叹的专有博客/论坛,但我们现在不是在谈论它们,对吧?

于 2009-02-06T21:50:19.247 回答