Best language or framework to use for a web application?

I have made minor web applications in the past and have always used php. However, I have recently started to get into django and also have been messing around with node js. I am thinking about making a larger scale web app for my friend that needs to be very secure and also fast. Was just wondering what many of the web developers here thought would be best for developing an open source web application.

1 Like

Security and performance are quite complex topics so much so that if you have ask questions like what you have; youā€™re not ready to be worrying about it.

There essentially isnā€™t a ā€˜bestā€™ language there may be a few features and paradigms that make a language stand out for specific tasks however. If I remember correctly our web team is using a combination of Django and Python for Ore (our module repo)

2 Likes

Well PHP tends to be one of the most common scripting languages that I know of for web applications, like forums and such. For Minecraft stuff, then Java tends to be more common than PHP by what Iā€™ve seen.

If what your planning on doing has some sort of daemon aspect to it, then one of the other languages might be better, like Java, Python, or Perl. Outside of web stuff, I havenā€™t seen PHP used for advanced stuff where itā€™s designed to run as its own server(a daemon.), Iā€™ve only seen more or less simple scripts with it.

2 Likes

One can use every language for webserver development, but if you go for secure use something all ready existing like joomla wordpress. The speed is always variable on the host mashine and the connection between client, webserver and databaseserver.
Anyway I programmed in both languages (Python and PHP) and i never noticed a speed difference, but i think php is easier for the web since more webhostings support it. And for the non-Web applications Python (or Java) it has allot more calcuation power and is cross-compatible.
In your case @Enter_ I would go with PHP.
@cartman2000 There are very complicated PHP scripts available on the NET (example is Facebook or any good CMS Site)

1 Like

Often, PHP is ā€œentiteledā€ as a simple language for simple, small projects. However, itā€™ve recently seen a statistic that about 70% of all websites use PHP, and as Facebook is written in PHP, it is powerful enough to host a website with your needs.

I would go with PHP as itā€™s really easy to learn

1 Like

I second that. Also, PHP is built for the web and already comes with a large amount of inbuilt tools and useful functions.

Iā€™m kinda surprised that nobody mentione Ruby on Rails in here yet. :wink:

3 Likes

I thought about Ruby on Rails, but Iā€™ve never used this myself, so I donā€™t have any experiences with it.

1 Like

I was going to go into ruby on rails but I have yet to actually hear from or see anyone who has used it or any similar examples of it used anywhere.

1 Like

Itā€™s supposed to be great. I personally havenā€™t ever gotten too deep into ruby on rails. All I know is that it looks very verbose and cryptic and is not something to start off with.

I would also agree, that PHP is one of the easier languages to learn for starting out with.

1 Like

To be clear Facebook is not written in php. It is written in a Php variant using C++ as itā€™s core, to go faster. Ruby on Rails is more for visual things. However PHP is more for a backend in my personal experience.

1 Like

Depends what youā€™re looking to do. I like Ruby on Rails for larger scale sites, that require large amounts of time to develop because Rails provides a lot of the basics for you, like forms, database integration, security, etc. PHP however, without a framework at least, is going to be very insecure, and youā€™ll have to make sure that you work out security measures on your own, which can be quite a bit of work. Iā€™m also a fan of NodeJS, which is what we built Crafatar on. Itā€™s fast, and based on a fairly easy language to learn. In my experience, it slows down the development process a little, but it might be worth it in the end.

Also, ignore the post above mineā€¦ā€œruby on rails is more for visual thingsā€ā€¦okayā€¦

1 Like

Thatā€™s what I feel like. Which the OP was asking for our experiences. In my opinion (which I admit I havenā€™t done much web development what it seems itā€™s used for)

If you obviously have no experience, it would probably be best not to comment and cause confusion.

As far as I know, Facebook invented PHP-NG (PHP-NextGeneration) and/or HHVM (Hip Hop Virtual Machine). You are right, they have rewritten large parts of PHP using C++ and stuff, but PHP-NG will be part of the next major PHP release (v6 I think)

Well I can guarantee you FB probably will still have a different version of PHP specialized for them. And @Jake0oo0 I never said I didnā€™t have any experience. I have backend experience (all be it perhaps not that much). I was giving my opinion that in my experience backend was easier over PHP because I could customize it however I wanted, while in RoR I felt it was more set up to help frontend development. A little experience != none, and just because my opinion is a little different from yours does not mean it should be silenced.

2 Likes

I would like to say thank you to everyone for your advice so far. I will be writing this one in php but will most likely make any future ones in node or RoR depending on what resources I can find for learning each of them.

1 Like

PHP is easy to learn, however really hard to master. Reason is simple: there is a lot of freedom in this technology, which explains why beginners feel at ease with it, but also explains why PHP projects often goes messy.

As already said, thereā€™s no best web technology. There could be a best pick in your case depending on parameters like:

  • Which architecture will you be working with?
    For example if youā€™re going to interact with Minecraft/Sponge, a Java web server could be a nice choice.

  • Which technology has good docs/community? Or which would be easy to learn by fellow developers? PHP Frameworks (symfony, yiiā€¦), nodejs fullstack frameworks (meanjs, meteor, mojito)

  • What do you already know?
    Capitalize as much as possible on what you already know, and like.

  • Will you need to work with mobile devices?
    Web apps now are often meant to be used by mobile devices. Some frameworks may be more friendly to it

  • Do you want to be modern, cutting-edge?
    If you want to dare using the technologies of the future right now, for example javascript servers like meteor js and client frameworks like angular 2.

As you can see possibilities really are numerous. In my case, I started long ago with pure PHP, then PHP frameworks. I got bored by it by seeing new technologies but I keep a special place for PHP because many servers with only FTP access are PHP-ready. Then I worked with heavy Java apps. With these, you should be able to do powerful and flexible things but with really heavy coding structure.

Then Javascript, I mean modern Javascript. Node brings to the ease of Javascript a powerful environment for servers, allowing to use the same language client and server side, which is a unique benefit. Thatā€™s why I really like it. Moreover, the community is purely great, serious and progress-oriented. Same risk as PHP though for project structure and rigor, but node is package oriented so the risk is lower.

I would just not recommend learning a language + a framework. That would be too much for you and for possible collaborators. That said, up to you!

3 Likes

You are totally correct. One tip I can give you: try to build a MVC (model-view-controller) application and give your variables good names like b_somename for boolean variables, i_somename for integers etc. That will help (a bit) when you have tons of codeā€¦ I really need to have an eye to Java (Tomcat etc) as I am currently working with PHP at home/hobby and ASP.NET MVC at work.

1 Like

PHP is a language that is the most preferred for web development. As an amateur, I would actually say PHP is the best language but the catch lies that PHP might be easy to learn but mastering it is a difficult task. There are a lot of loopholes in PHP which might lead your project go haywire. I would say that Javascript is the best language to use for a web application. As a web developer working in a professional website development company I would want a language that makes my job easier and can be used singularly to develop all modules of a website. With the introduction of node.js, Javascript has become more powerful as the need to switch between javascript in browsers and some other language in server-side has been eliminated. Javascript is compatible across all browsers which further makes it the best language for web development.