Monthly Archives: September 2016

Python Overview

Hi all,
The PYTHON is a programming language. Python is a general-purpose interpreted, object-oriented, interactive, and high-level programming language.
The python language was created by Guido van Rossum during 1985- 1990.



  • Python is Interpreted: The PYTHON is an interpreted language. And it is processed at runtime by the interpreter. You can’t compile your program before executing it.
  • Python is Object-Oriented: The PYTHON language support object oriented styles.
    PYTHON language structure supports various concepts such as: multiple inheritance,operation overloading and polymorphism.
  • Python is Interactive:Python prompt and interact with the interpreter directly to write your programs.
  • Python is a Beginner’s Language: Python is a great language for the beginner-level programmers and supports the development of a wide range of applications from simple text processing to WWW browsers to games.

Why PYTHON




  1. It’s simple language.
  2. It’s procedural language
  3. It’s object oriented and interpreted language.

Python Features

  1. Open source programming language
  2. Easy to learn: It’s clear and easy syntax. Its simple structure and clearly defined syntax.
  3. Easy to read
  4. Easy to maintain: The source code of python is fairly easy-to-maintain.
  5. Portable: Python is portable and can be used on Windows, Linux, Solaris, Macintosh, Amiga, FreeBSD, OS/2, AROS, AS/400 and many more.Python can run on a wide variety of hardware platforms.
  6. Extendable
  7. GUI Programming
  8. It support high level programming language.

Install Python 3.2 on Windows 7/ Windows 8 / Windows 10




Download .msi file of Python from http://www.python.org/getit/releases/3.2/. Once downloaded, double click the file to install Python 3.2 on Windows 7.

Start Installation

python-install-windows-step-1

Select Installation folder

python-install-windows-step-2

Wait now till the installation process is finished.





python-install-windows-step-3

Click Finish button at this stage abd that’s it. You may open Python command line form Start Menu and you may run python commands as shown bellow:

python-command-prompt

Simple example


>>> print "Welcome To Python!"

OR

>>> print("Welcome To Python!")

The output will be:

Welcome To Python!

It’s very easy to develope python script.




If anyone has doubts on this topic then please do let me know by leaving comments or send me an email.

Making content editable – HTML

In HTML page we can edit any document. The javascript helps to overcome this problem. The contenteditable attribute helps whether the content of an element is editable or not.
In contenteditable attribute there are three values are available. They are TRUE, FALSE, INHERIT.

contenteditable=”” or contenteditable=”true”
Indicates that the element is editable.
contenteditable=”false”
Indicates that the element is not editable.
contenteditable=”inherit”
Indicates that the element is editable if its immediate parent element is editable. This is the default value.




Syntax

  

Attribute Values

Value Description
true Specifies that the element is editable.
false Specifies that the element is not editable

Simple Example





	  

Test

Here’s the above HTML in action:

Test

This text can be edited by the user.

The contentEditable attribute is very easy method. If the contentEditable attributes is set as true that shows the HTML elements will become editable.




If anyone has doubts on this topic then please do let me know by leaving comments or send me an email.

Display Current Date and Time – PHP

Good Morning to all,
Some website used to display the current date or time in frond-end. This is very simple method to display the data or time using php.In PHP5, to display date and time provide inbuilt function for solve this problem.




The PHP date() function return the current date and time according to the built-in clock of the web server on which the script has been executed.

The PHP Date() Function




To display date in php page the date() helps to find this solution. The date() function in PHP convert a timestamp to a more readable time and date.

Syntax


date(format,timestamp)




Parameter Description
format Required. Specifies the format of the timestamp.


d – Represents the day of the month (01 to 31).


m – Represents a month (01 to 12)


Y – Represents a year (in four digits)
timestamp Optional. Default is the current date and time

The format parameter in the date() function is required which specifies the format of returned date and time. However the timestamp is an optional parameter, if not included then current date and time will be used. The following statement displays today’s date:

Example


The output will be:






Today is 2016/09/06

The PHP time() Function

To dispaly time in php page the time() helps to find the solution.

h – 12-hour format of an hour with leading zeros (01 to 12).


i – Minutes with leading zeros (00 to 59).


s – Seconds with leading zeros (00 to 59).


a – Lowercase Ante meridiem and Post meridiem (am or pm).

Example





The output will be:


The time is 10:28:26am

Happy Coding

If anyone has doubts on this topic then please do let me know by leaving comments or send me an email.

Image Caption Hover Animations with CSS3 Transitions and Transforms

In this article, we are discuss how to create stylish image caption on hover effect using CSS3. The advantage of this program is that, there is no javascript needed for develope this operation.
In here there are four types of hover effect are described below.

Table Of Content

demo




  1. HTML
  2. CSS3

HTML

Specify the image and caption text in html.




CSS3

The CSS3 is very powerful. We can develope hover effect in javascript, but in here there is no javascript needed.
We use pure CSS used to develope the hover effect in HTML. CSS is very important part in developing website.




If anyone has doubts on this topic then please do let me know by leaving comments or send me an email.

How to Rename Images and Media Files in WordPress

Hi all,
If you want to change an image file name after uploading fileinto wordpress dashboard. All are familure with how to change file title, description, caption etc.
But nobody knows how to change the file name through wordpress dashboard. Normally there is no option to change image file name from wordpress dashboard.
Based on these situation i try to solve this problem into simple steps. In this article shows how to rename images or media file name in wordpresss.



Steps To Rename media name in wordpress

To rename the media file name , first we login wordpress admin area with correct user name and password. After login admin area we move following steps. They are describe below
Step 1: Activate the rename plugin from wordpress plugin directory. First install and activate Media File Renamer pluginfrom https://wordpress.org/ plugin directory.
Step 2: If your media library is not displayed in list view then first you switch grid view to list view.
rename_file_name1




In the list view, you will notice a new column labeled ‘Rename’. This column will show the status of your image, other media file names, and the title.

rename_file_name2



Exmaple

Select file from media file displayed as list view.




rename_file_name3

Edit the file. Change the file title the click update button for save editting.

rename_file_name4




Final result will be:




rename_file_name5

If anyone has doubts on this topic then please do let me know by leaving comments or send me an email.

Removing Database and User – MYSQL

In this post, we will discuss detailed information based on how to delete MySQL usernames and MySQL databases from your hosting account.

Removing Privileged User from a database

If you would like to remove a privileged user. We remove user privileged from a database. This you can easy develope and implement.
remove_user1
A confirmation message for the removal will be displayed. This means that the username no longer has any privileges to the database.

Removing a MySQL database

If you would like a MySQL database removed this can be easily accomplished by clicking on the Delete Database button under the Actions area.




remove_user2

You will get a confirmation screen when the database is removed.




remove_user3
Again a confirmation screen will be shown upon successful removal.

If anyone has doubts on this topic then please do let me know by leaving comments or send me an email.

What is a database? What is SQL?

What is a Database?

A database is a collection of data or information. Databases make data management easy. Databases support manipulation and storage of data.
The database can easily be managed, accessed and updated. The databases can be classified based on types of content: full-text, bibliographic, numeric, and images.




What is a Database Management System (DBMS)?

The DBMS is a collection of programs, it helps to control access to the database. Which enables its users to manipulate data, access database, representation/reporting of data .

Types of DBMS

typesofdbms

Basically there are four types of DBMS.

  1. Hierarchical – This type of DBMS employs the “parent-child” relationship of storing data.
    This type of DBMS is rarely used nowadays. Its structure is like a tree with nodes representing records and branches representing fields.
    The windows registry used in Windows XP is an example of a hierarchical database. Configuration settings are stored as tree structures with nodes.
  2. Network DBMS – The DBMS supports many-to many relations. This usually results in complex database structures.



  3. Relational DBMS – This type of DBMS defines database relationships in form of tables, also known as relations.
    The network RDBMS, DBMS does not support many to many relationships. Relational DBMS usually have pre-defined data types that they can support.
    This is the most popular DBMS type in the market. Relational database management systems include Oracle, MySQL and Microsoft SQL Server.
  4. Object Oriented Relation DBMS – This type supports storage of new data types. The data to be stored is in form of objects.
    The objects to be stored in the database have attributes and methods that define what to do with the data.

SQL

SQL can be effectively used to search, insert, delete, update database records.

Example





SELECT * FROM Members WHERE salary > 30

If anyone has doubts on this topic then please do let me know by leaving comments or send me an email.