473,383 Members | 1,855 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

OOP: asp vs. php

What are the differences between ASP's OOP and Php's?

/Jacob

Jul 17 '05 #1
11 4770
ASP is full OOP with all the feature of OOP, PHP is not yet OOP but the
version 5 is almost near. Hope the next version (PHP6 ?) will be more OOP.

Savut

"Jacob Larsen" <po**@jfl.dk> wrote in message
news:3f***********************@dread15.news.tele.d k...
What are the differences between ASP's OOP and Php's?

/Jacob

Jul 17 '05 #2
"Savut" <we***@hotmail.com> wrote in message
news:Xc******************@news20.bellglobal.com...
ASP is full OOP with all the feature of OOP, PHP is not yet OOP but the
version 5 is almost near. Hope the next version (PHP6 ?) will be more OOP.

ASP is nothing of the sort, sir!

Asp can use JScript or VBScript as a server-side
scripting language. Both is what commonly refered
to as "OBject Based", but definitely not Object-Oriented.

As a matter of fact, ASP isn't a language at all,
it's a framework.

It can use several scripting-engines in adition to
the default VBScript or JScript. None of which have,
among other things, inheritance. One of the tree
cornerstones of OO.

--
Dag.


Savut

"Jacob Larsen" <po**@jfl.dk> wrote in message
news:3f***********************@dread15.news.tele.d k...
What are the differences between ASP's OOP and Php's?

/Jacob


Jul 17 '05 #3
Dag Sunde wrote:
"Savut" <we***@hotmail.com> wrote in message
news:Xc******************@news20.bellglobal.com...
ASP is full OOP with all the feature of OOP, PHP is not yet OOP but the
version 5 is almost near. Hope the next version (PHP6 ?) will be more OOP.


ASP is nothing of the sort, sir!

Asp can use JScript or VBScript as a server-side
scripting language. Both is what commonly refered
to as "OBject Based", but definitely not Object-Oriented.

As a matter of fact, ASP isn't a language at all,
it's a framework.

It can use several scripting-engines in adition to
the default VBScript or JScript. None of which have,
among other things, inheritance. One of the tree
cornerstones of OO.


Hell, if you want to, you can use PHP syntax to do your ASP stuff as
well through the use of the supplied php4activescript.dll (or one of
those DLL files anyway).

--
Justin Koivisto - sp**@koivi.com
PHP POSTERS: Please use comp.lang.php for PHP related questions,
alt.php* groups are not recommended.

Jul 17 '05 #4
You are wrong as in the fact, VBScript can create class, class metamorphis,
class inherance, and private / public variable, so it's full OOP. I'm not
again PHP as it'm my main web scripting language, but still ASP VBScript and
C# are more OOP than PHP for sure.

Savut

"Dag Sunde" <da******@orion.no.way> wrote in message
news:3f********@news.wineasy.se...
"Savut" <we***@hotmail.com> wrote in message
news:Xc******************@news20.bellglobal.com...
ASP is full OOP with all the feature of OOP, PHP is not yet OOP but the
version 5 is almost near. Hope the next version (PHP6 ?) will be more
OOP.

ASP is nothing of the sort, sir!

Asp can use JScript or VBScript as a server-side
scripting language. Both is what commonly refered
to as "OBject Based", but definitely not Object-Oriented.

As a matter of fact, ASP isn't a language at all,
it's a framework.

It can use several scripting-engines in adition to
the default VBScript or JScript. None of which have,
among other things, inheritance. One of the tree
cornerstones of OO.

--
Dag.


Savut

"Jacob Larsen" <po**@jfl.dk> wrote in message
news:3f***********************@dread15.news.tele.d k...
What are the differences between ASP's OOP and Php's?

/Jacob



Jul 17 '05 #5
Savut wrote:
You are wrong as in the fact, VBScript can create class, class metamorphis,
class inherance, and private / public variable, so it's full OOP. I'm not
again PHP as it'm my main web scripting language, but still ASP VBScript and
C# are more OOP than PHP for sure.

Savut


Dude's (Savut) talking about asp.net

asp is a framework. .net is a framework. asp.net is the new asp
framework and is a subframework of the .net framework. everything is
made more confusing by asp, asp+ and asp3 -- which all came before
asp.net. Now to make things confusing (if it ain't confusing enough for
ya), they released versions of VBscript to co-incide with versions(?) of
the asp framework. Hence people confusing asp with VBscript in asp
(which makes sense really). Anyway, I haven't been keeping track of it
all (gave up a long time ago and just used PHP instead), but the version
of VBScript that came out with asp3 (prior to the current asp.net which
is completely different) could do classes (happy day) -- by which stage
PHP had been doing classes for years.

Neither PHP or the VBScript offered with asp3 have a "full feature set"
that is typically associated with OO. If you are hell-bent on OO for OO
sake, then you will probably get advised to use somthing with a "full
feature set" (like Java or .net).

Personally, the principle is more important than the implementation. All
my applications are 100% object oriented and they use PHP which
apparently doesn't have 100% of the object-oriented feature set -- who
cares? I don't, my apps are still architected well using and object
orientation and many associated design patterns. At the end of the day,
that's what matters.

Oh, and choice matters. Choice of operating system, choice of web
server, choice of unlimited seats (in terms of licencing) choice of
technology extensions... PHP can integrate with Java as well as COM. I
don't have time for vendor specific technologies which don't have my
interests in first place.

At the end of the day, you have to decide what "really" matters to you.
That may or may not involve a technology that supports abstract classes
and interfaces or not (for example).
Jul 17 '05 #6
Yes, VBScript can create classes and be polymorphic,
but is does NOT support inheritance!

And if you're talking about the .NET platform, you should
have said so, because that is a completely different
animal.

--
Dag.
"Savut" <we***@hotmail.com> wrote in message
news:SY*****************@news20.bellglobal.com...
You are wrong as in the fact, VBScript can create class, class metamorphis, class inherance, and private / public variable, so it's full OOP. I'm not
again PHP as it'm my main web scripting language, but still ASP VBScript and C# are more OOP than PHP for sure.

Savut

"Dag Sunde" <da******@orion.no.way> wrote in message
news:3f********@news.wineasy.se...
"Savut" <we***@hotmail.com> wrote in message
news:Xc******************@news20.bellglobal.com...
ASP is full OOP with all the feature of OOP, PHP is not yet OOP but the version 5 is almost near. Hope the next version (PHP6 ?) will be more

OOP.


ASP is nothing of the sort, sir!

Asp can use JScript or VBScript as a server-side
scripting language. Both is what commonly refered
to as "OBject Based", but definitely not Object-Oriented.

As a matter of fact, ASP isn't a language at all,
it's a framework.

It can use several scripting-engines in adition to
the default VBScript or JScript. None of which have,
among other things, inheritance. One of the tree
cornerstones of OO.

--
Dag.


Savut

"Jacob Larsen" <po**@jfl.dk> wrote in message
news:3f***********************@dread15.news.tele.d k...
> What are the differences between ASP's OOP and Php's?
>
> /Jacob
>



Jul 17 '05 #7
Jacob Larsen wrote:
What are the differences between ASP's OOP and Php's?


ASP-VBScript has private members/ methods (variables/ functions). I
missed that in PHP. ASP-VBS also doesn't need any this-> keyword. What
ASP-VBS lacks are optional parameters in functions, which is a not so
nice thing, especially for later refactoring of bigger web apps. PHP of
course has optional parameters. ASP-VBS has a "let" syntax which even
OOP languages like Java don't have (not in any easy way, e.g. operator
overloading). This means it can be shielded from someone accessing the
class whether something is a public function or a public variable, and
this also can be changed later on without changing code accessing the
class. This is not available in ASP-JS AFAIK.

Overall I would say ASP-VBS has better OOP than PHP simply for the lack
of private members/ methods. ASP-VBS however does not have any
inheritance. But object composition (vs object inheritance -- "has a"
or "is a kind of" can test which is appropriate*) should be preferred
in most cases anyway, and that's possible in both PHP and ASP-VBS.

* A car _has a_ tire -> object composition, useful for most cases
An employee _is a kind of_ person -> inheritance, sometimes useful,
can easily add complexity of its own
Jul 17 '05 #8
Just add, Jacob, you dont really need to know about OOP of each, you make
your choice of what language you use, and you code how you can with it...
Live with it or throw it. Anyway, they all tend to be fully OOP soon. For
last post, sorry I was talking about ASP.NET and didn't mention it.

Savut

"Jacob Larsen" <po**@jfl.dk> wrote in message
news:3f***********************@dread15.news.tele.d k...
What are the differences between ASP's OOP and Php's?

/Jacob

Jul 17 '05 #9
In ASP, and ASP.NET especially, OOP is almost mandatory, whereas in PHP you
can do OOP if you feel like it, or not use it if you don't.

I don't understand why people think a more OOP language is somehow better.
Yes, you can better manage complexity using OOP principles, but my question
is, how much complexity should there be in a web application? At the end of
the day all it does is scrible something in the database and produce some
HTML code. It shouldn't be that complicated. When it is, you're probably
overdesigning the thing.

The real measure of a computer language is the amount of functionality you
get for the amount of complexity you have to deal with. In this regard PHP
beats ASP hands down.

Uzytkownik "Jacob Larsen" <po**@jfl.dk> napisal w wiadomosci
news:3f***********************@dread15.news.tele.d k...
What are the differences between ASP's OOP and Php's?

/Jacob

Jul 17 '05 #10
Yeah, in PHP we don't have things like

System.Object
System.Web.UI.Control
System.Web.UI.HtmlControls.HtmlControl
System.Web.UI.HtmlControls.HtmlContainerControl
System.Web.UI.HtmlControls.HtmlGenericControl

Such tragedy to program without polymorphic, namespace-segregated <p> tags!

Uzytkownik "Savut" <we***@hotmail.com> napisal w wiadomosci
news:SY*****************@news20.bellglobal.com...
You are wrong as in the fact, VBScript can create class, class metamorphis, class inherance, and private / public variable, so it's full OOP. I'm not
again PHP as it'm my main web scripting language, but still ASP VBScript and C# are more OOP than PHP for sure.

Savut

"Dag Sunde" <da******@orion.no.way> wrote in message
news:3f********@news.wineasy.se...
"Savut" <we***@hotmail.com> wrote in message
news:Xc******************@news20.bellglobal.com...
ASP is full OOP with all the feature of OOP, PHP is not yet OOP but the version 5 is almost near. Hope the next version (PHP6 ?) will be more

OOP.


ASP is nothing of the sort, sir!

Asp can use JScript or VBScript as a server-side
scripting language. Both is what commonly refered
to as "OBject Based", but definitely not Object-Oriented.

As a matter of fact, ASP isn't a language at all,
it's a framework.

It can use several scripting-engines in adition to
the default VBScript or JScript. None of which have,
among other things, inheritance. One of the tree
cornerstones of OO.

--
Dag.


Savut

"Jacob Larsen" <po**@jfl.dk> wrote in message
news:3f***********************@dread15.news.tele.d k...
> What are the differences between ASP's OOP and Php's?
>
> /Jacob
>



Jul 17 '05 #11
> ASP-VBScript has private members/ methods (variables/ functions). I
missed that in PHP. Smalltalk has no private methods, not in the C++ sense that you can not call
them from outside the class. And though all 'fields' are effectively
'protected' there still is a backdoor for getting and setting their values.
Now do you mean that Smalltalk is not 100% OOP?

Henk Verhoeven,
www.metaclass.nl

"Philipp Lenssen" <in**@outer-court.com> wrote in message
news:bq*************@ID-203055.news.uni-berlin.de... Jacob Larsen wrote:
What are the differences between ASP's OOP and Php's?


ASP-VBScript has private members/ methods (variables/ functions). I
missed that in PHP. ASP-VBS also doesn't need any this-> keyword. What
ASP-VBS lacks are optional parameters in functions, which is a not so
nice thing, especially for later refactoring of bigger web apps. PHP of
course has optional parameters. ASP-VBS has a "let" syntax which even
OOP languages like Java don't have (not in any easy way, e.g. operator
overloading). This means it can be shielded from someone accessing the
class whether something is a public function or a public variable, and
this also can be changed later on without changing code accessing the
class. This is not available in ASP-JS AFAIK.

Overall I would say ASP-VBS has better OOP than PHP simply for the lack
of private members/ methods. ASP-VBS however does not have any
inheritance. But object composition (vs object inheritance -- "has a"
or "is a kind of" can test which is appropriate*) should be preferred
in most cases anyway, and that's possible in both PHP and ASP-VBS.

* A car _has a_ tire -> object composition, useful for most cases
An employee _is a kind of_ person -> inheritance, sometimes useful,
can easily add complexity of its own


Jul 17 '05 #12

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

77
by: nospam | last post by:
Reasons for a 3-tier achitecture for the WEB? (NOTE: I said, WEB, NOT WINDOWS. DON'T shoot your mouth off if you don't understand the difference.) I hear only one reason and that's to switch a...
51
by: nospam | last post by:
THIS IS the DOTNETJUNKIES MESSAGE ------------------------- We're Sorry As many of you know we have recently launched SqlJunkies.com. We have overhauled our runtime and will be using it on...
34
by: Pmb | last post by:
Hi. I'm new to this group. I'm refreshing/learning C++ and am starting to learn Object Oriented Programming (OOP). In discussing this with people I came up short as to what the benefits of OOP are....
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.