Blog Archives

MySQL Insert

The INSERT statement is used to insert new records in a table. Syntax: It is possible to write the INSERT statement in two forms. The first form doesn’t specify the column names where the data will be inserted, only their

Posted in MySQL

MySQL Select

SELECT, which is used to get information from the database, so that its data can be used in our PHP script. Syntax: SELECT * FROM table_name; and SELECT column_name(s) FROM table_name Note: SQL is not case sensitive. SELECT is the

Posted in MySQL

MySQL Tutorial

  MySQL is currently the most popular open source database server in existence. On top of that, it is very commonly used in conjunction with PHP scripts to create powerful and dynamic server-side applications. As the world’s most popular open

Posted in MySQL

JavaScript Form Validation

JavaScript can be used to validate data in HTML forms before sending off the content to a server. JavaScript also lets you display helpful alerts to inform the user what information they have entered incorrectly and how they can fix

Posted in Javascript

Javascript innerHTML

The innerHTML property can be used to modify your document’s HTML on the fly. If you want to access the text within a non-input HTML element, then you are going to have to use the innerHTML property instead of value.

Posted in Javascript

JavaScript tagName

It returns the name of the element. Consider below example, <script type="text/javascript"> function gettagname() { var name_element = document.getElementById('txt_name'); alert("I am a " + name_element.tagName + " element") } </script> <input type="text" name="name" id="txt_name" value="learn web development"> <input type="button" value="Get

Posted in Javascript

JavaScript getElementById

Accessing Form Elements using getElementById In order to access the form element, we can use the method getElementById() like this: var name_element = document.getElementById(‘txt_name’); Here txt_name is id of any form fields. Consider this form input element, <input type=”text” name=”name”

Posted in Javascript Tagged with:

JavaScript Window.Location

The window.location() is used to know the current page name (current url) and also used to redirect to new url. If you want to redirect all your visitors to www.learnwebdevelopment.info site when they arrived at your site, you would just

Posted in Javascript Tagged with:

Javascript popup

In JavaScript you can create three kinds of popup boxes: Alert box, Confirm box, and Prompt box. Alert Box An alert box is often used if you want to know input from user. When an alert box pops up, the

Posted in Javascript Tagged with:

JavaScript document.write

document.write() – This simply prints the specified text to the HTML page. To print text literally, enter the text in single quote marks inside parentheses like so: Syntax: document.write(‘Learn web development!’); Example: <html> <body> <h1> <script type=”text/javascript”> document.write(‘Learn web development!’);

Posted in Javascript Tagged with: