Object constructor : Object : Object Oriented JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Object Oriented » Object »

 

Object constructor

















<html>
<head>
<script language="Javascript" type = "text/javascript">
<!--
function EmployeeObj (name, address, phone, email) {
    this.name = name;
    this.address = address;
    this.telephone = phone;
    this.emailaddress = email;
}
var newCust = new EmployeeObj("FirstName, LastName""city, state""555-555-5555""fl@website.com");

alert("Hello " + newCust.name);
//-->
</script>
</head>
<body>
</body>
</html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Object Oriented
» Object