This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes prototype issue Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark " prototype issue" Watch " prototype issue" New topic
Author prototype issue

Sanjiv Jivan
Ranch Hand

Joined: Nov 03, 2005
Posts: 52
I was trying to write some OO Javascript where I have some code like

function Base() {} = function(){

Child.superclass = Base.prototype;

function Child(){} = function() {;

The foo() function in Child works on some IE JS versions, however I get a javascript error on some javascript versions stating that the "call" property is not defined in the line ";"

I tried googling but could not find an definite answers as to which JS version the "call" functionality was introduced. Is there a better/alternate way to call a superclasses method?

Also is there a way to tell which JS version is running? The machine where I'm getting the error is also running IE 6, but seems to have an older JS version installed on it.

[ June 02, 2006: Message edited by: Sanjiv Jivan ]
Eric Pascarello

Joined: Nov 08, 2001
Posts: 15385
call() and apply() should work on IE 5.5 or greater.

I do not have time to look at your code right now to see if there is a problem.

Have you checked out Aspose?
subject: prototype issue
It's not a secret anymore!