LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (http://www.linuxquestions.org/questions/programming-9/)
-   -   What topics do I need to study for *web* client server programming - Web service? (http://www.linuxquestions.org/questions/programming-9/what-topics-do-i-need-to-study-for-%2Aweb%2A-client-server-programming-web-service-4175430938/)

TheIndependentAquarius 10-07-2012 05:32 AM

What topics do I need to study for *web* client server programming - Web service?
 
I know about client server programming through sockets in C/C++.

What topics do I need to study for website related client server programming?

- The database which we'll be using will be either MySQL or Postgress.
- The platform will be Linux.
- I don't know which language should be preferred here.

I just don't know where to start.
Please guide.

suttiwit 10-07-2012 08:13 AM

Well, if you mean "web development (cgi, etc)", Python is a good language.

theNbomr 10-07-2012 09:33 AM

For CGI applications using Linux, you can use any language that can read/write stdio, can access the Linux environment, and can access it's own commandline arguments. This accommodates HTTP GET & POST requests, and Apache and most other web servers. If you are already familiar with C/C++, you can use that, although compiled languages are less traditional than scripting languages.
If you are going to be building full-fledged applications, you may wish to consider some kind of application-building framework, such as Ruby-On-Rails, Django, and numerous others. These will provide a lot of working code, as well as a well designed structure upon which to build. Most will assume the use of one particular programming language, and which language(s) you prefer will influence which framework is best suited to you.
If you are planning to write your own web server or even browser, then don't. There are already enough of those available and the selection covers the spectrum of needs quite well. Many open-source packages exist, and the use of these as a basis for study or extension would be a good idea.
No matter what aspect of website creation you will be doing, it is almost certainly useful to understand HTTP & HTML, if not in detail, then at least in general. It may also be useful to understand some HTML-related subjects such as CSS, Javascript, XML, and perhaps Java as it relates to client-side applets.
Enjoy the buzzword soup.

--- rod.

dugan 10-07-2012 01:25 PM

First, what exactly is "website related client server programming"? I assume you're asking how to write a website. So...

"The Platform will be Linux"? So any web framework that can be hosted on Linux will be acceptable? You can't go wrong with Django (a Python web framework).

Ruby on Rails is another popular option.

To "start", visit their homepages and go through the tutorials you find there.

And do not, under any circumstances, even consider PHP.

Also, I've noticed that you like the answer you got on StackExchange:
http://programmers.stackexchange.com/a/167866/16764

amboxer21 10-07-2012 05:32 PM

http://nodejs.org/ maybe??

WIKI -> http://en.wikipedia.org/wiki/Nodejs

TheIndependentAquarius 10-07-2012 10:59 PM

Quote:

Originally Posted by dugan (Post 4799537)
First, what exactly is "website related client server programming"? I assume you're asking how to write a website. So...

Actually, I have been told that there will be a website which will act
like a server and another website will act like a client. The client
website will ask for a data from the server website.

Quote:

Originally Posted by dugan (Post 4799537)
"The Platform will be Linux"? So any web framework that can be hosted on Linux will be acceptable? You can't go wrong with Django (a Python web framework).

Thanks, will study about Django. We'll prefer something with GPL 2 license
probably. This thing will be probably sold.

Quote:

Originally Posted by dugan (Post 4799537)
Ruby on Rails is another popular option.

Which is considered easier among them?

Quote:

Originally Posted by dugan (Post 4799537)
And do not, under any circumstances, even consider PHP.

What's the reason? Please explain.

Quote:

Originally Posted by dugan (Post 4799537)
Also, I've noticed that you like the answer you got on StackExchange:
http://programmers.stackexchange.com/a/167866/16764

Is that a non-so-correct answer? What was your point in linking that here?

Quote:

Originally Posted by theNbomr (Post 4799384)
For CGI applications using Linux, you can use any language that can read/write stdio, can access the Linux environment, and can access it's own commandline arguments. This accommodates HTTP GET & POST requests, and Apache and most other web servers. If you are already familiar with C/C++, you can use that, although compiled languages are less traditional than scripting languages.

I am not familiar with any other scripting language that PHP and Python.
Will using C/C++ be problematic?

Quote:

Originally Posted by theNbomr (Post 4799384)
If you are going to be building full-fledged applications, you may wish to consider some kind of application-building framework, such as Ruby-On-Rails, Django, and numerous others. These will provide a lot of working code, as well as a well designed structure upon which to build. Most will assume the use of one particular programming language, and which language(s) you prefer will influence which framework is best suited to you.

Many thanks for the info.

Quote:

Originally Posted by theNbomr (Post 4799384)
If you are planning to write your own web server or even browser, then don't.

I don't know whether that server website will be already existing or I'll
have to write one - I'll find out.

Quote:

Originally Posted by theNbomr (Post 4799384)
No matter what aspect of website creation you will be doing, it is almost certainly useful to understand HTTP & HTML, if not in detail, then at least in general. It may also be useful to understand some HTML-related subjects such as CSS, Javascript, XML, and perhaps Java as it relates to client-side applets.

Lots of thanks to you for letting me know the keywords.

dugan 10-07-2012 11:15 PM

Quote:

Originally Posted by Anisha Kaul (Post 4799849)
Actually, I have been told that there will be a website which will act like a server and another website will act like a client. The client website will ask for a data from the server website.

I see.

The "website the acts as a server" will actually be a web service. A web service is usually a set of URLs that return and take data in some serializable format such as JSON. I've had good experiences building them with Django and Tastypie. Node.js (which amboxer recommended) is a pretty trendy choice these days too.

The client website will use Ajax to consume the web service. Use jQuery for that.

TheIndependentAquarius 10-07-2012 11:17 PM

Many thanks Dugan, will look into that stuff.
It would be helpful if you could clarify about the PHP thing.

:-)


Thanks to amboxer21, for mentioning the nodejs.

dugan 10-07-2012 11:19 PM

Quote:

Originally Posted by Anisha Kaul (Post 4799859)
Many thanks Dugan, will look into that stuff.
It would be helpful if you could clarify about the PHP thing.

:-)

It's just a horribly designed language, has a horribly designed standard library, and is a nightmare to work with.

http://me.veekun.com/blog/2012/04/09...of-bad-design/

theNbomr 03-15-2013 10:53 AM

Please start your own thread for such unrelated subjects, and don't hijack a thread started by someone else. Your subject line should have something to do with building 'something'; there doesn't seem to be a kernel-related aspect to what you've written here.


All times are GMT -5. The time now is 03:53 AM.