Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
06-14-2003, 12:16 AM
|
#1
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Rep:
|
Why JSP and XML?
Hello,everyone .I am learning PHP right now for quite several months.Meanwhile,I am wondering why some of the firms (Big enterprise) use JSP as their server-side language.Why don't they use PHP?Not secure?Not popular?Not scalable?Or what?I don't know.Do you have any ideas?And why do they use XML? XML is pretty new to me and not very popular.What's the advantages of XML?
I would be appreciative if you could respond to my questions.
|
|
|
06-14-2003, 12:41 PM
|
#2
|
Member
Registered: Feb 2002
Location: Mission Viejo, California, USA
Distribution: Gentoo
Posts: 707
Rep:
|
Re: Why JSP and XML?
Quote:
Originally posted by Swift&Smart
Meanwhile,I am wondering why some of the firms (Big enterprise) use JSP as their server-side language.Why don't they use PHP?
|
Everyone has their preferences.
Quote:
Originally posted by Swift&Smart
And why do they use XML? XML is pretty new to me and not very popular.What's the advantages of XML?
|
XML is a nice way to store data of many kinds.
|
|
|
06-14-2003, 11:24 PM
|
#3
|
Member
Registered: Dec 2002
Location: Singapore
Distribution: Fedora Core 6
Posts: 647
Rep:
|
Re: Why JSP and XML?
Quote:
Originally posted by Swift&Smart
And why do they use XML? XML is pretty new to me and not very popular.What's the advantages of XML?
|
Are you kidding?
XML is very popular and everything is using XML today. It can be used for platform independent data transfer, data storage, and configuration, etc. For example, web services (both ".Net" and "J2EE") are using "XML" to transfer the data platform-independently. And development tools like "Ant" (java build tool) , "Ghost installer" (windows installer making tool), and so many other tools are using XML to configure. And WML (formatting language for WAP) is based on XML. And some databases use XML to store data. And even XML based programming language is going to be developed in future.
Last edited by moeminhtun; 06-14-2003 at 11:26 PM.
|
|
|
06-15-2003, 10:32 PM
|
#4
|
Member
Registered: Dec 2002
Location: Singapore
Distribution: Fedora Core 6
Posts: 647
Rep:
|
Re: Why JSP and XML?
Quote:
Originally posted by Swift&Smart
Meanwhile,I am wondering why some of the firms (Big enterprise) use JSP as their server-side language.Why don't they use PHP?
|
Here are some advantages of java over php.
- java supports multithreading.
- java is fully Object Oriented while PHP has partially implemented OO paradigm.
- You can create almost everything with Java, from style-sheet application, games, client/server applications, etc. but PHP is quite limited. Eg: you cannot create a server application using PHP without the help of web server.
This article is about comparing Java and PHP. It explains why PHP is suitable for small web applications while Java is suitable for big applications.
http://www.tek271.com/articles/JavaOrPhp.html
Last edited by moeminhtun; 06-16-2003 at 09:28 PM.
|
|
|
06-18-2003, 06:00 AM
|
#5
|
Member
Registered: Jun 2003
Posts: 481
Rep:
|
^^
I'm pretty sure that JSP uses Javascript rather than Java applets... if this is the case then a lot of what you said is moot.
|
|
|
06-18-2003, 11:12 AM
|
#6
|
Member
Registered: Dec 2002
Location: Singapore
Distribution: Fedora Core 6
Posts: 647
Rep:
|
Quote:
Originally posted by nowonmai
^^
I'm pretty sure that JSP uses Javascript rather than Java applets... if this is the case then a lot of what you said is moot.
|
I don't know what u mean. JSP is serverside programming and JavaScript and Java applet are client side programming. It has nothing to do with each other. Ofcourse you can insert both JavaScript and Applet inside JSP code.
Please!
A lot of people make this mistake.
Javascript and Java is TOTALLY different technologies. It's just their names are similier. JavaScript is NOT from Sun. It's from Netscape. JavaScritp has nothing to do with Java.
Last edited by moeminhtun; 06-18-2003 at 12:36 PM.
|
|
|
06-19-2003, 04:29 AM
|
#7
|
Member
Registered: Feb 2002
Location: Mission Viejo, California, USA
Distribution: Gentoo
Posts: 707
Rep:
|
Quote:
Originally posted by nowonmai
^^
I'm pretty sure that JSP uses Javascript rather than Java applets... if this is the case then a lot of what you said is moot.
|
I'd have to agree with moe. JSP doesn't depend on Javascript or Java applets. It's serverside, similar to PHP. This comparison is pretty good.
|
|
|
06-19-2003, 05:10 AM
|
#8
|
LQ Guru
Registered: Nov 2002
Location: Durham, England
Distribution: Fedora Core 4
Posts: 1,565
Rep:
|
We use JSP at work as it is based on an actual programming language - this means our business logic can be written in a strong OOP language with good XML suppot and many 3rd party libraries, with the presentational code being done using JSP.
Well in fact what I do is use JSP to write out XML, then use XSLT to do the presentation. But I'm just perverse
|
|
|
06-20-2003, 04:36 AM
|
#9
|
Member
Registered: Dec 2002
Location: Australia
Distribution: Gentoo
Posts: 161
Rep:
|
I read this last night. I'm not a big fan of XML, I think it's too over-the-top and just another way to do something, not THE way.
Here is an article that (at last) didn't just blabber about how good it is, but actually looked at XML a bit more critically.
http://newsforge.com/newsforge/03/06...17.shtml?tid=5
|
|
|
06-20-2003, 05:49 AM
|
#10
|
Member
Registered: Sep 2002
Location: Canada
Distribution: Redhat 9.0
Posts: 637
Rep:
|
Good article. I would question the whole concept of web services and middleware (in the way that the vendors are building it up), but if you have all these people running out to spend their money, while you save your money and work with GPL and LGPL, than let them use XML!
|
|
|
06-20-2003, 09:28 PM
|
#11
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Original Poster
Rep:
|
Cost money?
I have read all you guys messages and one of the introduction chapter of J2EE. I can conclude that J2EE seems like having many components and very complicated,but it turns out that the functions are pretty similar with PHP.
I don't know what Java Servlet,JavaBeans actually mean before.However,I realized that they are very simple functions in PHP.Like others,one of the weaknesses of PHP is OOP(Object Oriented Programming) architecture.They don't have "PRIVATE" or "PUBLIC" mindset.As far as I know,OOP will be improved in PHP5.However,I actually don't know why "BIG ENTERPRISE" doesn't give PHP a shot.I have seen many "BIG ENTERPRISE" using JSP.And I plan to learn it anyway while they use it.
By the way,I have a quesiton on GtkUser,is it costs much money to use XML?And XML seems like progressing very very slowly....
|
|
|
All times are GMT -5. The time now is 03:02 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|