开发者

What would you recommend as a transition language on the desktop for a PHP programmer? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.

Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.

Closed 3 years ago.

Improve this question

I've been using PHP for some time now, and though I certainly don't claim I am a PHP guru, I feel I know my way around the language enough to get most things done elegantly enough.

Up 'til now, I haven't really wanted to do much desktop programming. I've hacked together ti开发者_如何学编程ny things with AutoHotKey and (I'm sure) rather poorly written C#, but I have never gotten into these languages in the same way that I have with PHP.

Now, I'm looking to change that, so I am asking you guys what you think would be the best language for me to try for programming on the desktop. Preferably, I would like something that is

  • Typed similarly to PHP (Wikipedia lists it as "dynamically/weakly" typed
  • Interpreted
  • Can be compiled (or at least packed) to an executable, and easily

Thanks in advance for any help!

EDIT:

Thank you all for the helpful answers - I wish I could have accepted all of them. I decided to try learn into Python, keeping in mind the differences between web and desktop development. Thank you all for your generous help!


My recommendation would be to try python. It is dynamically/strongly typed, and has syntax and features relatively similar to php. It can't be compiled to an executable, but it can be compiled to byte-code, like java is.

I have been programming in php for several years and recently picked up python and have really enjoyed it. I have also used c++ and java quite a bit and find them to be more difficult to master, and more frustrating to use.


There's not much value is learning a "PHP for the desktop language". I'd recommend that you explore language with different principles (say Python or Ruby) and use Desktop apps as your learning vehicle. PHP is written to be embedded inside a web page and that carries over even when you use it as a regular scripting language.

You can learn the ropes a little before picking up a new language by using something like PHP GTK.


PHP's design principles are fine on server side, but in many places they don't really fit in the world of Desktop development. For example, native Windows applications follow entirely different paradigms. Being able to work with these in a PHP-like language requires an additional (performance-intensive) layer between your language and the Windows API.

Bottom line: Much of Desktop app programming is so fundamentally different from how a PHP web app works, you won't get far with PHP's paradigms anyway.

I would therefore recommend to drop the requirements, and look/ask for the optimal language for the task instead. I don't know your situation of course, but if you have the time, chance and inclination at all, it's a great way to expand the programming horizon; also from a professional and CV perspective, it doesn't hurt to have another language under your belt.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜