Discussion :  SOU CS Classes The fastest message board... ever.
Forum for discussion, questions, and replies relating to Web Development I 
Goto Thread: PreviousNext
Goto: Forum ListMessage ListNew TopicSearchLog In
Week 5 - Wednesday Discussion
Posted by: harveyd (IP Logged)
Date: October 24, 2007 02:36PM

1. What is a scripting language?
2. What is a site that has free JavaScript code?
3. Tell us something about the history of JavaScript.
4. Tell us something interesting about how JavaScript is different from Java.
5. What are some problems with coding in JavaScript?
6. How do you link to an external JavaScript file?
7. What are other scripting languages besides JavaScript? How do they relate to what we are doing in this course?
8. What is a difference between interpreted and compiled programming languages?
9. What is a variable?
10. What variable types does JavaScript support?
11. What is a difference between a string and a number?
12. What does concatenation mean? How do you do it in JavaScript?
13. How do you declare a variable in JavaScript?
14. What is the difference between client-side and server side scripting?
15. What is the '.net' environment?
16. Find an interesting article about any scripting language of your choice.
17. Find an interesting article about the '.net' environment and how it relates to web-design.
18. How do languages like flash or java applets fit into web-design?
19. What is a Java servelet?
20. What are some neat things you can do in JavaScript that are not possible in HTML?
21. What is a similarity between JavaScript and CSS?
22. Find an article that either likes, or dislikes JavaScript.
23. Find a JavaScript script that you think nice. What does it do?
24. How do you debug your JavaScript instructions?
25. Find a free development environment that makes it easer to debug you JavaScript.
26. Tell us something about setting up a server.
27. What is Java bytecode?
28. Tell us something interesting about the Java language.

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: October 24, 2007 06:34PM

1. What is a scripting language? interpretive languages designed for a special purpose
2. What is a site that has free JavaScript code? www.javascript.com
3. Tell us something about the history of JavaScript. It's initial purpose was to Validate client-side forms, now it is used to make browsers more useful
4. Tell us something interesting about how JavaScript is different from Java.
JavaScript is a mini-language that executes in a browser,
5. What are some problems with coding in JavaScript? There can be syntax, logic or runtime, and management errors when using Javascript.

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: October 25, 2007 03:22AM

6. How do you link to an external JavaScript file?

An external JavaScript file is a text file that has been saved with a .js extension. The file must contain only JavaScript code (no HTML elements). To use the code stored in an external file, simply add a src attribute to the source document's <script> element:
<script src="firstCode.js" type="text/javascript"></script>

11. What is a difference between a string and a number?

A string refers to a string of characters, that is text. A string in JavaScript, we indicate by enclosing it in either single or double quotation marks, such as "Hello" or 'Hello' or "123" or '456'. These we called string, even the numbers; that is, JavaScript stores them as text and they cannot be used in mathematical calculations.

A number, we leave off the quotation marks. Number can be integers (positive or negative whole numbers) or real numbers (so-called floating point numbers) with decimal points.

27. What is Java bytecode?

Java bytecode is the form of instructions that the Java virtual machine executes. Each bytecode instruction is one byte in length (hence the name), thus the number of bytecodes is limited to 256. Not all 256 possible bytecode values are used. In fact, Sun Microsystems, the original creators of the Java programming language, the Java virtual machine and other components of the Java Runtime Environment, have set aside a number of values to be permanently unimplemented

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: October 27, 2007 06:54PM

There is a question in the Friday Discussion questions that asks if there are any mistakes in the online material, and here's a little typo:

What is a Java servelet?

It should be servlet.

I'll go ahead and answer this question:

A Java servlet is a Java program which resides and executes on a server (as opposed to client side) to provide functionality to the server or processing of data on the server.

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: October 28, 2007 09:28PM

8. What is a difference between interpreted and compiled programming languages?
Interpreted languages are programs that are executed one line at a time where a compiled program is executed all at once. This makes a compiled language faster because an additional program is not needed to interpret the instructions.

9. What is a variable?
A variable is a location in memory. Using a variable name means that we don't need to reference the memory directly and lets us concentrate on the programming. Variables can contain any manner of data - Object, strings, booleans, integers...

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: October 28, 2007 11:38PM

24. How do you debug your JavaScript instructions?

>Syntax check your Javascript code.
>Test your code immediatley after writing it.
>Evaluate your functions at run time.
>One-click debugging with breakpoints and line-by-line execution.

13. How do you declare a variable in JavaScript?

To declare a variable in JavaScript, you will write something like this:
<HEAD>
<SCRIPT language="JavaScript">
<!--hide from old browsers

var name=value;

//-->
</SCRIPT>
</HEAD>

Here is what these commands mean:
>var
This indicates you are about to declare a variable.
>name
This is the name you give the variable. Give it any name you like (other than a JavaScript reserved word such as "function" or "onMouseover".).
>value
This is the initial value you want the variable to have. It can be a number, words, true, false, or null.

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: October 30, 2007 04:52PM

21. What is a similarity between JavaScript and CSS?

Both JavaScript and CSS can be placed in an external file and referred to from within the html document.

Both are intended to work with and enhance HTML. Both can enhance the presentation of an HTML document.

Both JavaScript and CSS use /*comments within these characters*/ although JavaScript comments using these characters are specifically multi-line comments.

12. What does concatenation mean? How do you do it in JavaScript?

Concatenation is the operation of joining two character strings end to end. An example is the character string "Java" and the character string "Script" Using the "+" symbol as an operator between the two strings (Java+Script) would produce the output: "JavaScript". Operators act on values.

An example of its use in JavaScript could be the joining of two variables expressed as character strings. For example:
var cityState, city = "San Francisco", state = "California"
cityState = city + ", " + state
The output of this example would be "San Francisco, California".

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: October 31, 2007 05:20AM

7. What are other scripting languages besides JavaScript? How do they relate to what we are doing in this course?

Jscript by Microsoft, Java

These are basically the same syntax, so if you know one you can pretty much run them all.

Note from Dan: Actually, Java is not a scripting language. It does have the same syntax as JavaScript. Scripting languages are text that an interpreter program executes.


20. What are some neat things you can do in JavaScript that are not possible in HTML?

You can program games, have picture slide shows, have roll-over images. Any thing that needs client-side interaction needs JavaScript



Edited 1 time(s). Last edit at 10/31/2007 02:53PM by harveyd.

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: November 02, 2007 09:38AM

1. What is a scripting language?
A scripting language is built into a specific application and allows the user to automate certain tasks and increase the usefulness of that software.

2. What is a site that has free JavaScript code?
[www.js-x.com]

3. Tell us something about the history of JavaScript.
Javascript was first called Livescript, but when Java became popular. Netscape, the creator of LiveScript, quickly joined the Java craze by changing the name of LiveScript to JavaScript.

6. How do you link to an external JavaScript file?
<script src="hello.js" type="text/javascript"></script>


8. What is a difference between interpreted and compiled programming languages?
Interpreted takes the programmer's source code and translates it one line at a time and executes that line of command before translating the next line.
Compiled translates the entire code before performing its commands.

21. What is a similarity between JavaScript and CSS?
You can place your Javascript on an external document and have the webpage link to that document.

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: November 06, 2007 04:25AM

4. JavaScript and Java are very similar; both are the same type of language except Java is a much more advanced language. Java can be used to create "stand alone" applications whereas JavaScript must be placed in a HTML document. Another difference is that once a Java application is created, it must be ran by another computer program which codes it into a smaller language--once a Java program is created, it cannot be altered without breaking the program. JavaScript, on the other hand, can be changed over and over again without breaking the site.

14. Client side programming is used because the browser is separated from the server. By including code within a web page, a number of features can be added to a Web page without asking the server. Server side programming is used to manipulate a page before the server sends it back to the client. One type of server side programming is a visitor counter--the server keeps track of how many times your web page is asked for on the client end.

18. Both flash and Java applets are files/applications that must be downloaded into your web page. The files will automatically be downloaded when the web site is opened and then will wait for a command within the site itself before executing. Entire web pages can be created using Java Applets; the problem being that the pages will take longer to download and your browser must host the specific application before the page(s) will run correctly.

Re: Week 5 - Wednesday Discussion
Posted by: (IP Logged)
Date: April 09, 2010 07:37AM


Attachments: hanfsamen.html (13.6KB)  


Sorry, only registered users may post in this forum.
This forum powered by Phorum.