Web Technology Questions

Q:

How to read and write a file using javascript?

Answer

Files can be read and written by using java script functions – fopen(),fread() and fwrite().


The function fopen() takes two parameters – 1. Path and 2. Mode (0 for reading and 3 for writing). The fopen() function returns -1, if the file is successfully opened.


Ex: file=fopen(getScriptPath(),0);


 


The function fread() is used for reading the file content.


Ex: str = fread(file,flength(file));


 


The function fwrite() is used to write the contents to the file.


Ex(): file = fopen("c:\MyFile.txt", 3);// opens the file for writing


fwrite(file, str);// str is the content that is to be written into the file.

Report Error

View answer Workspace Report Error Discuss

0 3635
Q:

Does javascript have the concept level scope?

Answer

No. JavaScript does not have block level scope, all the variables declared inside a function possess the same level of scope unlike c,c++,java.

Report Error

View answer Workspace Report Error Discuss

0 3445
Q:

JavaScript is designed for following purpose

A) To add interactivity to HTML Pages. B) To Execute Query Related to DB on Server
C) To Style HTML Pages D) To Perform Server Side Scripting Opertion
 
Answer & Explanation Answer: A) To add interactivity to HTML Pages.

Explanation:
Report Error

View Answer Report Error Discuss

0 3444
Q:

Which one of the following is not used to generate dynamic web pages ?

A) PHP B) ASP.NET
C) JSP D) none of the mentioned
 
Answer & Explanation Answer: D) none of the mentioned

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Web Technology - Technology
Job Role: Analyst

1 3384
Q:

The Internet was launched in 1969 and was originally called ?

A) AARPNET B) CERNET
C) ARPANET D) CERN
 
Answer & Explanation Answer: C) ARPANET

Explanation:

The Internet was originally called Advanced Research Project Agency Network (ARPANET).

Report Error

View Answer Report Error Discuss

Filed Under: Web Technology - Technology
Job Role: Analyst

2 3353
Q:

Text/Html is called the __________ of the page

A) content type B) MIME type
C) content type/MIME type D) None of these
 
Answer & Explanation Answer: C) content type/MIME type

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Web Technology - Technology

1 3308
Q:

Which tag is used to display the numbered list?

 

1) <ol> </ol>    2) <li></li>     3) <ul> </ul>    4) <dl> </dl>

A) 1 B) 2
C) 3 D) 4
 
Answer & Explanation Answer: A) 1

Explanation:

Use HTML tag <ol> element to define an ordered list.

Use the HTML type attribute to define the numbering type. Use the HTML <li> element to define a list item. Use the HTML <dl> element to define a description list.

 

Hence, as numbered list come under ordered list tag <ol> tag is used for numbered list.

Report Error

View Answer Report Error Discuss

2 3292
Q:

How can you make sure the web application is fit for release ?

Answer


1. We can operate majority of test cases, but importantly we can make use testing techniques such as Pair-wise testing to reduce combinations, and/or model based testing to plan user journeys to ensure major functionality of web application works or not.


2. We can also use analytics to get insight into what users do on the website, which page is most popular and which feature is most used by the users.



Report Error

View answer Workspace Report Error Discuss

9 3278