Você está na página 1de 8

Web FAQ’s

1. What is the difference between Authentication and Authorization?

Answer:

Authentication is any process by which you verify that someone is who they claim they
are. This usually involves a username and a password.

Authorization is finding out if the person, once identified, is permitted to have the
resource. This is usually determined by finding out if that person is a part of a particular
group, if that person has paid admission, or has a particular level of security clearance.

2. How do you restrict the user to authenticate over the web?

Answer:

By assigning the ‘No Access’ to the ‘Anonymous’ entry in the ACL of the particular
Database

3. I am having the form in which I have placed so many buttons but I am unable to
see those buttons when I access that form through the web. What might be the
problem? And instead of showing the buttons I am able to see the submit button
alone why?

Answer:

There might be unchecked the database web property ‘Use Java script when generation
pages’ in the basic tab.

Domino by default generate the submit button until ‘Use Java script when generation
pages’ database property is enabled.

4. When I submit form I am getting the ‘Form Processed’ message. So I want to


customize that message or I want to redirect to some other page how?

Answer:

Just take a reserved field ‘$$Return’ over the form and give your message you like or if
you want to redirect to any page just mention the related URL in default formula.

5. I am having hidden fields over the form. I am trying to get the hidden field value
through JavaScript then getting the error message like ‘Object is required’ why?

Answer:
The form property ‘Generate HTML for all fields’ for web access should be enabled to
get access the hidden objects through JavaScript

6. But I want to get the hidden field value with out enabling the property you said
above. How will you do?

Answer:

Remove the Hidewhen formula or property for those hidden fields and then put all those
hidden fields in the div tag and give style ‘none’ for that div then you can get the hidden
field values using JavaScript.

7. How do you get the normal text field value through JavaScript?

Answer:

By writing the syntax like below,


var value = Window.document.forms[0].fieldname.value

7. How do you get the check box or radio box field value through JavaScript?

Answer:

By writing the syntax like below,


var value = window.document.forms[0].fieldname[index].value

8. How do you get the dialog box field value through JavaScript?

Answer:

By writing the syntax like below,


var value = window.document.forms[0].fieldname.options[Index].value

9. How do you get the selected check box or radio box field option value through
JavaScript?

Answer:

By writing the syntax like below,

var len = window.document.forms[0].chkfiledname.length

For(i=0;i<len;i++)
{
If(window.document.forms[0].chkfieldname[i].checked == true)
{
var selectedoptionvalue = window.document.forms[0].chkfieldname[i].value
}
}

10. How do you get the selected dialog box field option value through JavaScript?

Answer:

By writing the syntax like below,

var value = window.document.forms[0].fieldname.options[=


window.document.forms[0].fieldname.selectedIndex].value

11. How do you get the child window field value by staying in parent window?

Answer:

By writing the syntax like below,


var value = Window.opener.document.childwindowfieldname.value

Note: In reverse also same syntax will work

12. The window is divided into two frames I am having some x form in one frame and y
form in another form. I want to get x form field values by staying in the other frame
where you are displayed y form how?

By writing the syntax like below,

var value = Window.parent.framename.document.forms[0].fieldname.value

12. I want to get content of the div.how can you get it?

Answer:

By writing the syntax like below,


Var content = window.document.getelementById(“dividname”).innerHTML

13. I want to assign some content to div how can you do?

Answer:

By writing the syntax like below,


window.document.getelementById(“dividname”).innerHTML = somevalue
14. Which event will fire first i.e. ‘webquerypopen’ or ‘onload’ when form loads in
the browser?

Answer:

Webquerypopen

15. What are all the places we can write the HTML in the domino?

Answer:

Over the form or page, HTML head content and in the HTML tab at the other field and in
the agent and in the formula

16. What are all the places we can write the CSS in the domino?

Answer:

Over the form or page, HTML head content and in the HTML tab at the style field and in
the agent and in the formula

16. How can call the style sheet page in form?

Answer:

In HTML head content write the below syntax;


"<link href=\"/" + DBPath + "/global.css\" rel=\"stylesheet\" type=\"text/css\">"

17. When will ‘WebQueryOpen’ and ‘WebQuerySave’ events will fire?

Answer:

WebQueryOpen event will fire before loading the form over the web

WebQuerySave event will fire before form is going to save over the web

18. What are all places agent can be run over the web?

Answer:

Hotspot click event, WebQueryOpen event , WebQuerySave event and all Javascript
events.
18. What are the ways to run the web agent?

Answer:

We can run the agent through @command ‘ToolsRunMacro’


We can run the agent through formula @UrlOpen
We can run the agent through javascript by wirting th syntax below

Location.href = “http://hostname/dbname/agentname?openagent”

19. Is there any difference running the agent through ‘ToolsRunMacro’ command
and through javascript?

Answer:

Yes there is difference running the agent through ‘ToolsRunMacro’ command and
through javascript.If you run the agent through javascript we can not handle the front end
document.If you run the agent through ‘ToolsRunMacro’ command you can handle the
front end document.

20. How do you pass the arguments to the agent?

Answer:

By passing the querysting variable to that particular agent. Syntax as follows,

Location.href = “http://hostname/dbname/agentname?openagent&QV=nag”

21. Can you write the javascript in the agent? .If yes how?

Answer:

By using the ‘print ‘keyword’ you can achieve the same. Syntax as follows,
ltdbpath = assign some url
Print "<script>"
Print "window.opener.location.href='"+ltdbpath+"'</script>"
Print "<script>window.close()</script>"

22. How do you achieve the picklist functionality over the web?

Answer:
Create one form in which take list box .write the formula in the list box that to get show
some values in it. And provide ‘Ok’ button also in the same form. Show this particular
form to user when user click on the button in the main form.

24. How do you transfer values from one form to other form in the web?

Answer:

Step1: Take reserved field ‘Quesry_String_Decode’ over the form to get the information
of the querystring variable

Step2: When redirect the form assign the necessary information to URL as form of
querystring variable.

Step3: Extract the information from ‘Query_String_Decode’ field in to the required filed

25. When select the option in the dialog box I need to get the some information from
the backend document based on the keyword which is selected by the user with out
refreshing the document. How can you achieve this one?

Answer:

Step1. Covert the notes data in to the xml format .

Step2.Take the XML object over the form.Synatax is as below,


<xml id="xmlVehicleData" src=""></xml>
Source should be the view which you made xml format.Syntax is as below,
"/" + DBPath + "/vehicles.xml?OpenView&Count=100"

Step3: Write the function in the JS header to get the data based on the key.Function is
like below,
function updateCategories (frm, manufacturer) {

//Get a handle on the XML Data Island's root element and then the required manufacturer
node
var xmlDoc = document.all.xmlVehicleData;
var objNodeList =
xmlDoc.documentElement.selectSingleNode("//manufacturer[@name='" + manufacturer
+ "']");

kwd = frm.sMake.options[frm.sMake.selectedIndex].text;

frm.sModel.length = 0; //Remove current options!!


frm.sModel.length = objNodeList.childNodes.length; //Add new options container!!
//Loop through the "model" nodes and add all the new values...
for (var i=0; i < objNodeList.childNodes.length; i++){
document.forms[0].sModel[i].text = objNodeList.childNodes[i].text;
document.forms[0].sModel[0].selected=true;
}
}

Step4: Call the above function in the ‘onchange’ event of the dialogbox

26. Can you say some reserved fields which you have used in your application?

Answer:

Server_Name, Query_String, Query_String_Decoded, Remote_Host, Remote_User etc..

27. What is the difference between ‘Quesr_String’ and ‘Quesr_String_Decode’

Answer:

Query_String retunrs the query variable value in unformatted way

Quesr_String_Decode retrun the query variable value in way which we have passed
thequery variable

28. is there any difference that opening the form in ‘OpenForm’ and ‘ReadForm’
url?

Answer:

When you open the form using ‘ReadForm’ url , it display form with out showing its
edtable fields

When you open the form using ‘OpenForm’ url form, , it display form as normal

29.How do you force the user to authenticate regardless of the database access
control list?

Answer:

By appending the following command to any domino URL to force user authentication
regardless of the database access control list

Location.href = http://hostname/dbname/formname?openform&login
30. Encryption will work on the web?
Answer:

NO

31. I want to run the agent by web user instead of the signer of the agent how?

Answer:

Just enable the ‘Run as web user’ property in the security tab of the agent properties.

32.How do you handle the web document?

Answer:

By setting notes document object as below,


Set NotesDocument = NotesSession.DocumentContext

33. I want to hide and show the piece of information based on the user selects the
options from the dialog box with our refreshing the form?

Answer:

Step1: Put the required information in the Div tag

Step2: When user selects the dialog box option hide or show the div. Syntax is like below,
Window.document.all.divid.style = ‘none’ for hiding
Window.document.all.divid.style = ‘block’ for showing

Você também pode gostar