Haxe 真的适合 php 目标服务器端开发吗?

发布于 2024-12-05 14:18:28 字数 603 浏览 0 评论 0原文

我有这样的想法,使用一些 php/mysql 托管服务构建一个简单的 Web 应用程序。我还想创建该应用程序的本地版本。本地版本应该与在线版本类似(id使用浏览器作为ui)并且具有与服务器通信的能力。我希望它尽可能轻。

从专业角度来说,我是 ac#/.net 程序员。我对 c/c++、javascript、python 和 java 也有一些经验。我对 php 知之甚少,老实说,我不喜欢用这种语言编码的感觉,因此,没有太大的意愿去深入研究它。 .Net、python 或 java 它们都太笨重了,我不能强迫用户安装它们中的任何一个。所以我想到了haxe的多目标。如果我要在 haxe 中编写该项目(对于具有我背景的人来说,学习起来似乎很简单),我可能会在服务器和客户端上使用相同的逻辑,同时针对 php 和 neko。

作为一个新手,我有一些疑问。我不确定 php 的 haxe 是否已经足够成熟来完成这种工作。我知道haxe是ActionScript的近亲,它主要针对AS,而且由于作者也是nekoVM的发明者,因此,这两个目标应该没问题。但是,呃,php 怎么样?这真的也有好处吗?有什么提示或建议吗? haxe 的内置库适合简单的 Web 应用程序还是我应该使用框架? neko 有 httpRequest 功能吗?

预先非常感谢。

I have such a conception, to build a simple web application using some php/mysql hosting service. I'd also like to create a local version of that app. The local version should work similarly as the online one (i.d. using browser as the ui) and have the ability to communicate with the server. I want it to be as lightweight as possible.

Professionally, I'm a c#/.net programmer. I also have some experience with c/c++,javascript, python and java. I know very little about php, and honestly, I don't like the feeling coding in that language, hence, don't have much willingness to dig into it. .Net, python or java they're all too unwieldy, I can't force the users to install any of them. So I thought about haxe's multi-targeting. If I were to code the project in haxe (it seems pretty straight forward to learn, for some one with my background), I might use the same logic on both side of the server and the client, by targeting both php and neko.

As a novice, I have some doubts. I'm not sure if haxe for php alreadly mature enough for this kinda job. I know haxe is a cousin of ActionScript, it primarily targets AS, and because the author is also the inventor of nekoVM, therefore, these two targets should be fine. But uh, how about php? Is it really good for that as well? Any hints or suggestions? Is haxe's builtin libraries ok for a simple web app or should I use a framework? Does neko have a httpRequest functionality at all?

Much gratitude in advance.

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

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

发布评论

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

评论(1

陌生 2024-12-12 14:18:28

直接的答案是 Haxe/PHP 似乎非常适合您。那是因为你的背景。我在几个项目中使用了 Haxe/PHP(碰巧我也是它的作者),速度对我来说从来都不是问题。如果存在瓶颈,通常也有方法来优化这些部分以获得更好的性能,如果最终您的应用程序扩展到数十亿用户,您始终可以选择切换到 neko 或 C++/cgi 组合。
关于框架也有一些选项: Web " Haxe 在 PHP 环境中部署的“框架”?

The straight answer is that Haxe/PHP seems to really fit well for you. That because of you background. I used Haxe/PHP in several projects (it happens that I am also its author) and speed has never been an issue for me. If there are bottlenecks usually there are also ways to optimize those portions for better performances, and if in the end you application scales to billions of users you can always opt to switch to neko or a C++/cgi combo.
About the frameworks there are a few options too: Web "frameworks" for Haxe to deploy in a PHP environment?

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