Good combination of web application languages - programming-languages

I've looked around some of the asked questions and I noticed many questions dealing with THE best web application language. I'm curious into looking into a combination of web application languages, possibly some that would compliment each other well. At the moment my list of possible web app languages at the moment are:
PHP
Ruby on Rails
JavaScript
AJAX (not really a language on its own)
Grails
I know that certain ones like JavaScript and AJAX work well together but I'm curious about the rest. What about PHP and JavaScript? Does Rails play well with others? Is looking to use a combination of languages even a possibility? I know that some may be used for different kinds of applications but I would like to focus on more than just 1 of them. Thanks for the help. Any and all comments are appreciated.

You are mixing everything up.
PHP and RoR (Ruby on Rails) are server-sided scripting technologies (and Rails is not really a programming language). They can generate content that is served to the user (ie: HTML files), but they can do a lot more. You NEED a server-side language if you want to interact with your users (ie: allow them to leave comments, and etc.).
Javascript (and AJAX, partially) on the other hand runs completely on the client side. You'll mainly use JS and Ajax to improve user experience, but remember to code your site in such a way it works even if JS is off.
Generally, as a complement to your server-side scripts you need a database, and among them the most popular ones are relational DB's that support SQL (Structured Query Language), like MySQL, SQL Server, Oracle, etc.
So, what's the "best" combination for you? It really depends. Hosting with PHP+MySQL is widely available and it's cheap, and PHP has a massive user community, and many freely available libraries and frameworks for you to use. So if you are just getting into web development, I'd suggest starting with PHP+MySQL.

Rails is not a language, it's a framework. Ruby is the language.
Grails is not a language, it's a framework. The language is Groovy.
Ajax is not a language, it's a marketing term coined to describe DHTML, which was a marketing term coined to describe using JavaScript to manipulate DOM elements and styles.
Regardless if it's PHP and Python, Perl and Java, JavaScript and Erlang, you can use any languages together depending on what you're trying to accomplish.
If you're looking for something learn, I'd say JavaScript (and get down and dirty and really learn it... don't rely on a framework as a crutch) because it's the primary front-end language in the web-world. But that's just my preference.
If you could give us a little more insight into what you're working on then maybe someone can give you a better suggestion of languages to pair up.

A programming language is just a means of achieving a goal, hence the focus should always be on the goal. Just as human languages the goal is communication, hence the languages is relatively not important.
Javascript is client side scripting language, while rest of the things that you have mentioned are serverside scripting languages. No matter what server side language you use you would have to use Javascript for client side scripting.
The rest of the 3 languages are opensource languages. Personally I would choose the most popular technology because
a. There is a big community, which ensures that the technology is widely adapted because I would like other third party applications gelling well with my application.
b. Lesser no. of flaws, since someone or the other would report it and the community would try to fix.
c. Dynamic future release: Since the community would like to see feature which are there is some competitive technology they would always want to add the feature. An excellent technology which has very less community built around it dies its own death since there are no future release and slowly it falls behind the competition.
The next important criteria would be is the tech really suits my application. Like if I am using a very slow embedded system processor, I cannot use python I will have to use C.
Well in all above cases I personally love PHP. PHP has some of the best CMS s/w, which makes life easy and there is lots of code available for free and widely adapted by even enterprises.

Related

What would be the disadvantages of building a website purely in Eiffel using EWF (Eiffel Web Framework)?

We are looking to build a website on top of an existing Eiffel business-tier core, which is sitting over a MS SQL Server database. I am presently considering the advantages and disadvantages of writing the web and mobile tiers either purely in Eiffel, purely in typical web-stacks, or some hybrid.
For us, there are clear advantages to pure Eiffel, not the least of which are:
Inheritance and other language notation mechanisms not found in other languages.
The compiler cannot see into code from other languages, so we are at the same disadvantage one we cross out of Eiffel into something else.
Auto-Test is something we heavily rely on in our Eiffel code, which takes clear advantage of Design by Contract. In other languages, we lose this power and are left with TDD (e.g. their version of Auto-Test in Eiffel).
We now have to learn more than: Eiffel, HTML-5, CSS-3, JS, and whatever JS framework(s) we use.
Every new language and tool adds more complexity to the project.
Eiffel programs are compiled to C --> EXEs, which are far faster than their scripted and interpreted counterparts.
I think there are also some clear advantages to existing, non-Eiffel languages as well:
Existing frameworks and tools can develop simple to moderate web sites and mobile applications rather quickly.
Existing "best-practices" are not terrible and producing reasonably reliable and maintainable code.
I am not sure what all of the advantages and disadvantages are, so I am asking. However, at the end of the day: Our core business suite is pure Eiffel. That will never change.
Thanks in advance for the feedback!
Here is what I can say from my own experience (I have create several web applications in different frameworks including one in Eiffel). First, the Eiffel Web Framework is quite usable right now. The advantage of other frameworks are their features. Here is a list of the major problems I encounter when I created my web application with Eiffel:
I had to create the MVC design myself (other frameworks like Django, Rails or Laravel does that automatically).
Eiffel lack is a good templating system. The Smarty library is ok, but it really lack some really good template features that other has. Also, trying to work with UTF-8 file in Smarty can be quite difficult (this has been a pain for me).
I had to do some session management based on cookies because the one in Eiffel Web Framework was quite primitive.
The release process (removing Nino) was not easy and lack good documentation (I was using Apache, I don't know about IIS)
That's it, other than that, every thing went quite smoothly.
The next list of disadvantages is from my naïve point of view:
The EWF package is not finished, it's going to have more nice capabilities in the future, therefore you may need to follow the new development to take advantage of new functionality.
Eiffel compiler makes it impossible to update a web program on the fly, it needs to be recompiled and redeployed.
If the program is going to be multithreaded, you need to learn a structured way to deal with concurrency based on the SCOOP model.
Some tools (e.g., XSLT processors) are not readily integrated into EWF, you may need to do this yourself.
The current EWF API is rather low-level, so before higher-level frameworks built on top of EWF become widespread, you may need to do more low-level programming than expected (by low-level I mostly mean the way to generate HTML/XML/or some other format your web service is going to produce).
Having to use just one language to do both application logic and HTML generation, that allows for easy debugging, may lower the requirements for the developers and their skills, that may affect your business model.
There are several tools that address specific needs like wiki, simple web-page creation, authorization, etc., but you may need to enhance them to get richer functionality as well as to design the architecture of your software, because some idioms and usage patterns are not established yet.

Web Designer looking to learn back-end programming [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 8 years ago.
Improve this question
my name is Tabetha and I have a question...
I am a web designer, but I always find that while designing the layout and coding the design I come up with great ideas for websites. I would like to know where I need to start in order to learn back-end programming not only for the knowledge, but also for the challenge of it.
I have searched online but can't seem to find the information I am looking for. If anyone can give me a simple, straight-forward "this is what language you need to learn" answer, or perhaps guide me in the right direction I would appreciate it ten-fold.
I am a complete noob when it comes to this, so even the most basic information is probably a pearl of wisdom for me. :)
With this type of question you will never one simple, straight-forward answer :) Are you a Mac person? If so, you'll probably want to learn PHP or Ruby on Rails for server-side programming, along with MySQL for your database. These technologies are widely used on other operating systems, including Windows. The Apache web server and PHP is included in Mac OS X; Rails is easy to set up. Most hosting providers will offer cheap LAMP hosting packages (Linux, Apache, MySQL, PHP) (Google "LAMP tutorial")
If you're a PC person, you might want to learn about .NET (VB or C#), SQL Server and IIS. There are many similarities in the development practices between the different technologies, with MVC being the recommended design pattern. Understanding MVC is important.
There are many other "back-end" technologies, including JAVA, ColdFusion, etc, but PHP/MySQL is the most common.
You could also learn about server-side content management systems, like Drupal, Wordpress or Joomla to name a few. These systems take care of much of the low level data handling, leaving you to focus more on the content and appearance, while sacrificing some flexibility.
Good luck!
Just to add my two cents. Programming language is in reality not as important as having general knowledge of the principles. Look at it this way: knowing how to program is the same as knowing how to design. Programming language is then only a tool, like photoshop, that you can excel in, but it won't make you a designer by itself.
The concepts that are important for web back-end development and actually a must-know if you're in for a challenge, are object-oriented programming, separation of presentation and computational logic, database abstraction, networking protocols (http specifically).
Understanding these essentials will pay off greatly as compared to learning the quick-and-dirty ways of combining php with html.
PHP is probably the most commonly used backend end language, and will probably give the least problems when setting it up in a server. I would recommend using a Framework (at least to start), both for ease of use and security issues. For this I'd recommend the Zend Framework. There's a great tutorial for getting started here: http://www.survivethedeepend.com/.
I am a heavy advocate of .NET languages for beginners. The .NET framework is nice and easy to wrap your head around because Microsoft is great with documentation, tutorials, and giving a complete package.
As you already have knowledge of HTML I would look into ASP .NET or ASP .NET MVC. This website from Microsoft will take you from start to finish in developing a website in ASP .NET and ASP .NET MVC.
Once you start programming with Visual Studio you will see how easy Microsoft makes it for you.
To get you started with backend development, i would suggest u learn how a database (db) works and the various database management systems (DBMS), particularly relational DBMS (RDBMS) such as MySQL, SQL server, oracle, postGRESQL, Microsoft Access, etc. You will come 2 know that most DBMS allow u to communicate with them and issues commands to them by speaking to them a language called Structured Query Language (SQL). So u will need to invest some time to learn the basics of speaking the SQL language to create a database, store new data or modify existing data, fetch data from the db, or even delete data that is no longer needed from your db. In particular i suggest u learn how MySQL works and issuing commands to MySQL since it is the most widely used DBMS in most web projects. Then, you will need to spend some time to learn about computer programming (issuing instructions to computer) and programming languages (the languages used for writing the instructions). You can zero down to learning how to speak a particular computer language such as PHP. The reason u have to learn how programming languages work is that u will need to speak a computer language (programming language) to write the logic for interacting with your database (e.g verifying that some conditions hold true before certain data can be fetched). I suggest u start by learning the PHP language as your backend programming language, since it is the most widely used in web projects. In the programming langnuage u have chosen to learn (e.g php), find out how to issue SQL commands to a RDBMS from that language. In summary, i recommend you learn the combination of PHP and MySQL since this combination is the most widely used for backend web development. But once u get a grasp of how things really work, you can always switch to whatever combination of technologies works best for your particular project. I hope this helps.

secure server side language

Looking around the horizon of the web server side, I see that scripted languages like PHP are quite popular,
probably due to the speed of development and ease of programming.
However scripted languages are human readable so isn't code security would be an issue here.
I would like to know that if I am keen of security of my code on the server what server language/technology would be most suitable.
When you use any server side language, only people with access to the FTP protocol (or SSH), can see the files. When you are regularly browsing the web, you cannot see PHP, or any other scripting language.
In terms of the actual language security, little bugs can be found, but you will get that in every language.
The security of your script depends on how you design it.
For the most part, every language is secure, but not every programmer is.
scripted languages are human readable
so isn't code security would be an
issue here.
No, users on the web will never see the code of your serverside programms - unless you publish the source.
Some security problems in web applications stem from the type of language used on the server side: buffer overflow is a security problem typical of C. So a scripting language would actually be more secure in this regard.
Typical security problems in web apps today stem from the interaction of client, server, database and user-entered data:
SQL Injection
Cross Site Scripting
Cross Site Request Forgery
...
A modern Web Framework like Ruby on Rails (or many others) will help you avoid some of these problems. But you still will have to learn a lot about web security!
"Staying away from Javascript" is a bit like "staying away from cars" because they are dangerous. Javascript is an integral part of modern web applications.
All serious (ignoring Piet, Malbolge, etc) programming languages are human-readable. Whether or not an explicit compilation step is required has no effect whatsoever on application security.
If you want to be very careful about security, use a language which supports easy verification and/or proofs, such as Haskell or Ada. A typical web application probably would be OK with a modern dynamic language, such as Python or Ruby. Java and C# are also popular, for performance reasons. Any of these will make developing secure applications significantly easier than in legacy platforms such as PHP, Perl/CGI, or classic ASP.
Lastly, as a small pet peeve -- PHP, Python, Ruby, Perl, etc, are not scripting languages.
I would say that the only really safe way to protect your code is by using ISAPI or CGI, and developing the application with some hard compiled language like C, C++, VB 5 or higher but any .NET, Delphi 5 or higher and so on. Any bytecode or interpretated language can be decompied, no matter what you do. New obfuscation methods may hold the crackers for a while, but they will always find a way to get the source. The source is there, the decompilation routine is there, the source must be revealed to be used by the framework, so all the crackers have to do is to catch it on the way.
the language has a small part to do with it. however, a lot has to do with how you actually design and write the code.
ASP.NET get compiled into dll's, so the code is not human readable on the server. But even in PHP, the code gets executed on the server.
Just stay away from JavaScript as that is visible on the client, and human readable.
My main preference is .NET, however even with the scripting languages like PHP they are not seeing your raw code unless you're giving people access to read the raw code files. I've seen some very secure PHP sites. If you're concerned about what people can see and access, then you need to watch what you are putting into the client side scripting languages like Javascript.
For 'hiding' the code there are a few different languages that support this. .NET languages can be compiled, which generates DLLs without containing the original source code on the server. These, however, can be read with something like .NET Reflector, so to escape that you would run something like Dotfuscator on your code, making it more difficult to read.
For PHP, there are solutions such as ionCube that encode your script and they must be ran with an additional decoder on the server to execute them. Usually this is used when reselling scripts, so clients can't look at or modify the source.

Web programming language

I want to go learn web programming,but besides names and a little of html I don't know anything.So I ask you what programming languages you recommend,why,what can be done with it,tools to learn ,etc.I don't know if it matters but I program in a Linux enviroment(Ubuntu).
I don't want to do hardcore web programming ,I only want to be able to develop complete websites and understand network concepts.
Well, most cheap/free web hosts support PHP, MySQL, and most browsers support Javascript.
Target those and you'll be on a reasonably good path.
Some support Ruby and Python, and you might choose that path if you want to learn those languages.
Good luck!
-Adam
Definitely start with HTML, and basic CSS. These are the core of web programming, and you need to understand them well to do anything of consequence.
Once you've got those down, you'll want to move on to a server-side language. The easiest is PHP, but be careful of picking up bad habits, since it's a loose environment; if you stick with PHP, you'll eventually want to use it with an MVC framework such as CodeIgniter, which encourage separating presentation and logic. To get a little more advanced, you can also try Python or Ruby. Get yourself some server space to mess around with; most shared hosting plans are $5-10/month.
For Javascript/AJAX, you'll probably want to start by using Firebug or Firefox's DOM inspector to learn the relationship between the HTML of a page and the DOM object which Javascript uses to interact with it. Once you understand how the DOM works, toy around with jQuery to start doing useful (and fun!) stuff.
You'll also eventually want to learn MySQL (or a similar SQL variant), but that can probably wait, since you can do lots of interesting things without tackling database stuff.
Above all, be patient and persistent, and make use of every resource at your disposal: books, Google, Stack Overflow, and cheat sheets.
Ruby all the way. It's exactly what you need if you're interested in web dev and completely starting from scratch programming-wise. From the basics of Ruby it's pretty easy to get into Rails, which is a very beginner-friendly web framework.
Many great books on Amazon (look for the highest rated of course) on both Ruby and Rails.
Great starting point for links:
http://www.ruby-lang.org/en/documentation/
As well check out Learn to Program
Now get learnin'.
Google App Engine offers free hosting for applications that do not exceed the specified limits. The server-side language is Python, the client-side language is JavaScript inside Django templates. Everything has worked nicely for me in Ubuntu 8.10.
GREAT Question,
a couple of years ago I was in the same place -
What HONESTLY Helped me was using Dreamweaver, I set it in split mode and started watching the code
I used this and started delving into the PHP Application world and could see what was going on (sort of)
I know you can use dreamweaver with wine on the linux, and it can help you do a TON
granted if you continue it has the potential to limit you to the dreamweaver world... but can help you learn and create at the same time
(I build full php apps from scratch now with a notepad... but I started with DW)
The question I'd have is what kind of scale on web programming are you wanting to do? If it is small stuff then the LAMP stack would be my suggestion while if you want to get more into 3-tier architecture then Java or ASP.Net may be worth getting into for middleware or business logic code.
With the exception of the reference to the LAMP stack above, there has been no Perl recommendations. I like Perl as it is easy enough to build a fairly full featured web application (using CGI, or mod_perl). Of course, you are going to have to learn HTML/CSS if you are going to do anything on the web. I feel Perl is a good choice for web development as it is fairly robust and full featured with all of the modules available on CPAN. Combine with an application framework like CGI::Application or Catalyst and you can build sophisticated web apps in a short amount of time. Also, using a tool like XAMPP can help as you won't have to worry about web server or database cofigurations to get started.

best language / framework for a web CRUD app with roles on Linux

I have a Linux web server and I'd like to make some database tables (currently in Access) available on the web for CRUD. There needs to role-based security. What's the quickest path to develop this?
Also, which database would be best? I already have mySQL running on that box if it makes any difference.
I agree with Chuck, the question shouldn't really be about the language, but about the framework you choose.
I did something similar to you a while back, and ended up using Ruby on Rails, and the activescaffold plugin (http://www.activescaffold.com/) to provide a pretty front end. The actual code I ended up writing was extremely minimal. There are other plugins for Rails which provide role based security too (which I didn't bother with, I just had "you're either logged in and have write access, or you're not logged in and you don't") and which also mean you don't have to write much stuff yourself.
So put me in the camp for Rails come the religious war ;)
Edit: MySQL is a perfect database to use, so you don't have to worry there.
This will turn into a religious war between the Ruby on Rails camp and the Python camp, with a good smattering of the PHP and Perl. You should evaluate the langauges yourself and decide what is best for you. There are, of course, other choices, however listing those would just elicit mroe religious battles. Although, I would say all of those I listed would be reasonable choices. You can usually create a good design in spite of any shortcommings your chosen language may have.
I don't think language is the question you should be asking. There's no language particularly well-suited to CRUD Web apps. There are many frameworks designed for that sort of thing, though, in many different languages, and those are probably what you'll want to look at.
I think Rails is the best in general, and that's what I use for most projects. It's very well-suited to CRUD apps (to the point where it allows you to create a simple one without writing any code at all). But if there really were an undisputed "best" choice, you'd probably already know about it. Instead, some apps are made with Rails, some with Django, some with Cake, and so on and so forth.
If you want a solid, clean, stable CRUD web app that can be maintained and expanded for years to come, stick with the standards: PHP, Perl, JavaScript, CSS, and HTML. Learn those roots languages well. Take the time to do it right and focus on good coding habits like clarity, consistency, and organization. Practice good reuse of code, good naming, good commenting, and good database design. Test, document, and refactor. Take pride in the craftsmanship of your CRUD app. Learn it inside and out. Set the stage so you can later maintain and expand it. Your goal is to build something that will work well, last a long time, and make a great return on the business investment. Someone once said that it takes 10 years to become a good coder.
As for frameworks, plugins, and external libraries, that's wonderful icing to put on your cake. But never confuse the icing with the cake. If you want to learn to code, take the time to learn it right. If you're not comfortable coding a simple CRUD app, you'll be even less comfortable trying to navigate the framework-generated code. Coding is a wonderful gig. But never mistake the sizzle for the steak.

Resources