AmitDiwan has Published 10744 Articles

HTML DOM Location origin Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

115 Views

The Location origin property returns the string corresponding to the URL’s protocol, hostname, host port number (if specified).SyntaxFollowing is the syntax −Returning value of the origin propertylocation.originExampleLet us see an example for Location origin property − Live Demo Location origin    form {       width:70%;   ... Read More

HTML DOM Location pathname Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

113 Views

The Location pathname property returns/sets the string corresponding to the URL pathname.SyntaxFollowing is the syntax −Returning value of the pathname propertylocation.pathnameValue of the href property setlocation.pathname = pathOfHostExampleLet us see an example for Location pathname property − Live Demo Location pathname    form {       width:70%;   ... Read More

HTML DOM Location port Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

113 Views

The Location port property returns/sets the port number (if specified) for a URL. Port number might not get displayed if not explicitly specified.SyntaxFollowing is the syntax −Returning value of the port propertylocation.portValue of the port property setlocation.port = portNumberExampleLet us see an example for Location port property − Live Demo ... Read More

HTML DOM Location protocol Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

110 Views

The Location protocol property returns/sets a string corresponding to the protocol used for a URL. Protocol can be set to ‘file:’, ‘http:’, ‘https:’, etc..SyntaxFollowing is the syntax −Returning value of the protocol propertylocation.protocolValue of the protocol property setlocation.protocol = protocolStringExampleLet us see an example for Location protocol property − Live Demo ... Read More

HTML DOM Location reload() method

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

289 Views

The HTML DOM Location reload() method is used for re – rendering the current document. It provides the same functionality as the reload button in the browser.SyntaxFollowing is the syntax −location.reload(forceGetParameter)ParametersHere, “forceGetParameter” can be the following −forceGetParameterDetailstrueIt defines that current document is reloaded from server.falseIt defines that current document is ... Read More

HTML DOM Location replace() method

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

210 Views

The HTML DOM Location replace() method is used for rendering a new document replacing the current document. It also removes the current document URL from document history disabling navigation to old document using ‘back’ button.SyntaxFollowing is the syntax −location.replace(URLString)ExampleLet us see an example for Location replace() property − Live Demo ... Read More

HTML DOM Input Email type Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

115 Views

The HTML DOM Input Email type property returns/sets type of Input Email.SyntaxFollowing is the syntax −Returning string valueinputEmailObject.typeSetting type to string valueinputEmailObject.type = stringValueString ValuesHere, “stringValue” can be the following −stringValueDetailsemailIt defines that input type is emaildatetime-localIt defines that input type is datetime-localradioIt defines that input type is radiotelIt defines ... Read More

HTML DOM Input Email value Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

147 Views

The HTML DOM Input Email value property returns a string, which is the value attribute of input Email. User can also set it to a new string.SyntaxFollowing is the syntax −Returning string valueinputEmailObject.valueSetting value attribute to a string valueinputEmailObject.value = ‘String’ExampleLet us see an example of Input Email value property − Live ... Read More

HTML DOM Input FileUpload accept Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

113 Views

The HTML DOM Input FileUpload accept property returns a string, which is the value of the accept attribute of FileUpload. User can also set it to a new value.SyntaxFollowing is the syntax −Returning string valueinputFileUploadObject.acceptSetting value attribute to a string valueinputFileUploadObject.accept = valueExampleLet us see an example of Input FileUpload ... Read More

HTML DOM Input FileUpload autofocus Property

AmitDiwan

AmitDiwan

Updated on 30-Jul-2019 22:30:26

113 Views

The HTML DOM Input FileUpload autofocus property sets/returns whether Input FileUpload is focused upon initial page load.SyntaxFollowing is the syntax −Returning boolean value - true/falseinputFileUploadObject.autofocusSetting autofocus to booleanValueinputFileUploadObject.autofocus = booleanValueBoolean ValuesHere, “booleanValue” can be the following −booleanValueDetailstrueIt defines that input will be autofocused on page load.falseIt is the default value ... Read More

Advertisements