Posts

Showing posts from March, 2017

JavaScript for Beginners - JavaScript Comments (P: IV)

Image
Not all JavaScript statements are “executed”. Code after a double slash //, or between /* and */, is treated as a comment. Comment are ignored, and are not executed. Single Line comments use double slashes Result: Everything you write between /* and */ will be considered as a multi-line comment Here is an example  Note: comments are used to describe and explain what the code is doing Next Post:  JavaScript for Beginners - Variables (P:V)

JavaScript for Beginners - External JavaScript (P: III)

Image
External JavaScript Scripts can also be placed in external files. External scripts are useful and practical when the same code is used in a number of different web pages JavaScript file have the file extension .js Below we’ve created a new text file, and called it as customScript.js To use an external script, put the name of the script file in the src (source) attribute of the <script> tag. Here is an example: Your customScript.js file includes the following JavaScript: The result of the above example will be identical to the result when we included the JavaScript within the HTML file You can place an external script reference in <head> or <body>, whichever you prefer. The script will behave as if it were located exactly where the <script> tag is located. Note: External scripts cannot contain <scripts> tags. Note: Placing a JavaScript in an external file has the following advantages It separates HTML and code ...

JavaScript for Beginners - Creating Your First JavaScript (P: II)

Image
Your First JavaScript JavaScript lives inside the HTML document. Below is a sample HTML document with <head> and <body> tags, in which we will write our JavaScript code In HTML JavaScript code must be inserted between <script> and </script> tags: JavaScript can be placed in the HTML page’s <body> and <head> sections. In the example I Placed it within the <body> tag. Let’s use JavaScript to print “Hello Sri Lanka” to the browser The document.write() function writes a string into out HTML document. This function can be used to write text, HTML or both. Output Note: It is a good idea to place scripts at the bottom of the <body> element. This can improve page load, because HTML display is not blocked by scripts loading  Next Post:  JavaScript for Beginners - External JavaScript (P: III)

JavaScript for Beginners - Overview (P: I)

Image
Welcome To JavaScript JavaScript adds interactivity to a webpage. JavaScript works together with HTML and CSS to create attractive, interactive webpages Before starting with JavaScript, it is recommending that you gain basic knowledge of HTML and CSS Using JavaScript, you can  Display  information,  validate  forms data,  create  cookies,  Change  page content,  Detect  browser detail and many more JavaScript scripting language works inside the web browser. Client Side Language Web site scripts either run on client-side or server side. The client side of a website refers to the web browser that is viewing it. The server-side of a website is the server that hosts it. PHP, Ruby, on Rails, ASP.NET are among the most popular server-side languages. They are called server side languages because their scripts run in the server that hosts the website, rather than on the user’s computer. JavaScript is a client-side ...

FIX : stsadm is not recognized as an internal command

Image
If you try to run SharePoint STSADM.exe in powerShell and getting this error To resolve the error message you need to edit the profile.ps1 file Its located in C:WINDOWS\SYSTEM 32\WindowsPowerShellL\v1.0\ if the profile.ps1 file dose not exists, just create a new file and add the following code Set-Alias -Name stsadm -Value $env:CommonProgramFiles"\Microsoft Shared\Web Server Extensions\15\BIN\STSADM.EXE" Happy Coding  !!!

FIX : The password supplied with the username Domain\Username was not correct. Verify that it was entered correctly and try again.

Image
This will happen often while trying to create a new web application in SharePoint 2013 central administration site. It gives the following error This usually occur when farm account password is expire and it's password is changed or simply farm account password is changed. In that case, sometimes password stored in SharePoint database is different in Active Directory, so unable to create web application from central admin.  In order to resolve this problem you need to update SharePoint 2013 farm credentials using "STSADM" tool. For that Open PowerShell in administration mode then write the following code stsadm -o updatefarmcredentials -userlogin <UserAccount> -password <New-password> Example : Once you receive operation completed successfully message do a IIS reset !! FYI : In case if you getting an error message " stsadm not recognized as an internal command " Follow these instructions.. Happy Coding !! ...