PHP 论坛软件的 RESTful 接口

发布于 2024-12-11 19:42:24 字数 1484 浏览 0 评论 0原文

我希望将轻量级论坛功能集成到现有的 GWT 网站中。前端用GWT/SmartGWT编写,后端用PHP编写。通信是通过使用 JSON 的 RESTful API 进行的。

我查看了一些流行软件(SMF、phpBB 等)的论坛,但无法找到任何对 RESTful Web API 的引用,以便更轻松地集成到现有的非 PHP 站点。我最接近的是 vBulletin 的移动 API - https://www. vbulletin.com/forum/content.php/334-mobile-api。不幸的是,vBulletin 不是免费的。

我最近在一些论坛上看到的一些帖子基本上都说用户应该围绕内部 API 编写自己的 Web 服务包装器。然而,这似乎是一个糟糕的解决方案,可能会导致各种额外的错误。

所以,我的问题是 - 有谁知道现有的免费论坛软件(PHP、Perl、Ruby 可以,但不是 Java)可以提供 RESTful Web 服务界面?

一个附带问题是:有人使用过 Restler (http://luracast.com/products/restler/< /a>) 将论坛软件发布的 API 转换为 RESTful 接口?我确信这种方法会充满潜在的问题,但人们总是可以抱有希望。

PS:我在 stackoverflow 上看到了以下较旧的问题,但它们似乎没有那么有用,而且现在已经有点旧了:

I'm looking to integrate a light-weight forum feature into an existing GWT website. The front-end is written in GWT/SmartGWT and the backend is written in PHP. The communication is through a RESTful API using JSON.

I have looked into the forums of some popular software (SMF, phpBB, etc.) but was unable to find any references to a RESTful web API to make integration into an existing non-PHP site easier. The closest I came is to vBulletin's Mobile API - https://www.vbulletin.com/forum/content.php/334-mobile-api. Unfortunately, vBulletin isn't free.

Some recent threads I have seen on some of the forums basically say that the user should write their own web services wrapper around the internal API. However, that seem like a bad solution that can lead to all kinds of additional bugs.

So, my question is this - does anyone know of an existing, free forum software (PHP, Perl, Ruby OK, but NOT Java) that provides a RESTful web services interface?

An ancillary question to this is: has anyone used Restler (http://luracast.com/products/restler/) to turn a forum software's published API into a RESTful interface? I'm sure this method would be fraught with potential problems, but one can always hope.

PS: I saw the following older questions on stackoverflow, but they don't seem to be that helpful and are now kind of old:

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

洛阳烟雨空心柳 2024-12-18 19:42:25

看来 Vanilla Forums 符合您的要求,他们支持 基于 JSON/XML 的 API

Looks like Vanilla Forums fits your bill, they support JSON/XML based API

怪我闹别瞎闹 2024-12-18 19:42:25

我为 SMF 论坛编写了一个半 RESTful API,除了创建和销毁 SMF cookie(登录/注销)之外,它可以执行您喜欢的任何操作,您可以使用 cURL 自己完成此操作
http://www.simplemachines.org/community/index.php?topic=458832.0
我想可能是你发帖询问并给了我这个想法

I wrote a semi-RESTful API for SMF forums that will do anything you like except create and destroy the SMF cookie (login/logout), which you might be able to accomplish yourself using cURL
http://www.simplemachines.org/community/index.php?topic=458832.0
I think it might have been you who posted there asking for it and gave me the idea

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文