Saturday, February 14, 2015

Converting Coordinates between map projections using Python

Python can be used very nicely to quickly convert coordinates from one projection into another using the pyproj package, as usual available here. This example does it from command line, but you can built it into your script, of course, as well. The easiest way is to find the EPSG code for your projections, for example on this page. You then initialize the projections you want, in this example unprojected lat/long into EPSG:3575:

>>> EPSG4326 = pyproj.Proj("+init=EPSG:4326")
>>> EPSG3575 = pyproj.Proj("+init=EPSG:3575")


Alternatively you can use the Proj.4 definition, so the following two lines are doing the same, you can use either of them

EPSG3995 = pyproj.Proj("+proj=stere +lat_0=90 +lat_ts=71 +lon_0=0 +k=1 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs ")
EPSG3995 = pyproj.Proj("+init=EPSG:3995")


Now you can define the input coordinates and transform them, in this example you transform values from EPSG:4326 to EPSG:3575:

>>> lat = 79
>>> long = -5
>>> x, y = pyproj.transform(EPSG4326, EPSG3575, long, lat)
>>> x,y
(8768866.779113682, -3366052.584518589)

Official documentation can be found here

Top IT Certification Programs for Beginners in 2014

Top IT Certification Programs for Beginners in 2014

Getting certifications has been marked as a surefire approach to boost your career in the Information Technology industry. It does not matter if you work for the government, a small business, health care or merely for an enterprise that employs IT experts, your best bet to boost your career prospects is to validate your knowledge and skill set via a carefully picked combination of certification programs.

Constant new updates in technology give rise to fresh job opportunities and also become challenges for the leading companies in the world of Information Technology (IT). The organizations would do anything to maintain their high status by doing their best to adopt the latest networks and software. One way of doing so is to hire IT professionals and specialists who have the latest skills and knowledge in the IT world.

Also Read: Computer Networking Professional: Does This Sound Like You?

By taking about latest certifications with Selftest Training, It can be said that by getting these certifications an individual’s chance of getting a job in an excellent organization increases. It also helps him in attaining a better position in the company. Moreover, a significant rise in the employment rate of IT sector has been noticed and it has been reported that further acceleration will be witnessed in the future.

The Best IT certifications for Beginners in 2014
Here is a list of the best IT certifications for beginners that ensure a higher pay and an excellent job in the upcoming year.

1. CCNP or Cisco Certified Network Professional
The CCNP or Cisco certified network professional is a certification that acts as a verification for the skills and knowledge that are necessary for the designing application, troubleshooting and verification of wide and local area networks. Individuals who have this IT certification can take up positions as network engineers, system engineers, support engineers, or network technicians.

2. MCITP or Microsoft Certified Information Technology Professional
This IT certification makes use of the Microsoft technology to the fullest and employers give it high consideration, as it shows that an individual has the ability, skills and knowledge to perform complex tasks related to IT.

3. ITIL v3 Foundation
The demand for this IT certification is high in the IT market, so make sure to have it on your resume in the coming year. The professionals with this certification are highly paid. Furthermore, its demand will surely increase in the next year.

Also Read: List of Biggest and Popular Programming Contests

4. CCNA or Cisco Certified Network Associate
The Cisco certified Network associate or CCNA is an IT certification for beginners in the field of network engineering. In order to be an eligible candidate for this IT certification, a person must have three years of work experience as a network engineer. Those individuals who have this certification on their resume have the skills and knowledge that are necessary for the configuration, installation, operation, and troubleshooting of medium sized networks that use routers and switches. According to Selftest Training with this certification, you can get a job as a network specialist, network administrator or a support engineer in networking.

Author Bio:
The Author is well known blogger and writer, she is blogging from last 3 years, In her free time She loves to watch movies with her family, dancing and sometimes cooking.

Image Source: http://coretechnigeria.com/I.T%20TRAINING.html

Create Dynamic Menu in ASP NET MVC A Complete How to Guide

A menu plays a significant role in lending an amazing UX by making an application easily navigable. It can be used to make accessibility to a particular section a breeze.

If you want to ensure a surefire application, it is essential that elements of your application must be accessed with ease. It must appear intuitive and intriguing, so that users can execute them with a flair. You may create multiple modules within a project and depending upon the users permissions, an appropriate menu can be implemented dynamically via ASP.NET.


Create Dynamic Menu in ASP.NET MVC - A Complete How to Guide

ASP.NET is an open source server side framework that augments web app development with great efficiency and precision. It is the core of the popular Content Management Systems (CRM), eCommerce, and so forth that deliver utile features.

Also Read: 5 Things You Must Consider Before Using ASP.NET Development

Here is a comprehensive guide that offers a complete tutorial for creating a user-friendly dynamic menu via ASP.NET MVC. The process is extremely simple with only 5 easy steps at a glance.

Lets distill the process and explore how dynamic menus can be created efficiently.

Create Dynamic Menu in ASP.NET MVC

Step 1: Create a database table

To create dynamic menus in ASP.NET MVC, the very first step is to generate a database table that can hold all the menu items in a designed hierarchy (if any). The database table can be created with a simple query as mentioned below.


Create Table Menus(ID int Primary Key Identity(1,1), ParentID int foreign key References Menus(ID), Title varchar(50), Description varchar(250))


This query will create a table Menus that will hold four values. These values are:

ID: is the primary key and auto generated
Parent ID: is the foreign key
Title: Name of the field
Description: is the information that you want to display when a user hovers over the menu.

With this, a desired table will be created in the database.


Step 2: Insert values into the table

A simple insert query can be used for adding the data into the table. Now, there are two possibilities, that is, your menu may possess multiple parent items that further possess child items or there may be parent items only. So, you must insert the values as per your app requirements.

Query to insert values into the table Menus.

Insert Into Menus(null, Item One, Desc) // First Parent Item
Insert Into Menus(null, Item Two, Desc) // Second Parent Item
Insert Into Menus(null, Item Three, Desc) // Third Parent Item

Insert Into Menus(1, Item Sub One, Desc) // Child of First Parent Item
Insert Into Menus(2, Item Sub Two, Desc) // Child of Second Parent Item
Insert Into Menus(3 Item Sub Three, Desc) // Child of Third Parent Item

By implementing the above mentioned queries, your Menus table will contain three items in the Menu and each item will further have a child item.


Step 3: Fetch the data from the table

Now, the next step is to fetch the menu items from the table Menus that was created in the step 1, and return a list of all the items.

For this, a GetMenus() function is created in MyMenu class. In this function, there is a loop that will help fetch the items of the Menu and return them via a list. The lines of code for the same is as follows.

Code Snippet for model:


public static class MyMenu
{
/// <summary>
/// Get List of All Menu Items from Database
/// </summary>
/// <returns>Returns List<Menus> object</returns>
public static List<Menus> GetMenus()
{
using(var context = new ProjectEntities())
{
return context.Menu.ToList();
}
}
}


Step 4: Display the created menu on the screen

Now, when the Menu items has been fetched from the database, it is the time to represent it in the view.

Code Snippet for View:


@{
List<Menus> myMenu = MyMenu.GetMenus();
var plist = myMenu.Where(m => m.ParentID == null).ToList(); // This will list main menu items on which well apply loop to display them.
if (plist != null && plist.Count > 0)
{
<ul class="nav">
@foreach (var pitem in plist)
{
<li>
<a href="{URL-Required} title="@Description">@pitem.Title</a>
@{
var clist = myMenu.Where(m => m.ParentID == pitem.ID).ToList();
if (clist != null && clist.Count > 0)
{
<ul>
@foreach (var citem in clist)
{
<li><a href="{URL-Required}"title="@Description">@citem.Title</a></li>
}
</ul>
}
}
</li>
}
</ul>
}
}

Here, ui and li HTML tags are used in the loop. This will help display the created menu in the view. Now, move to the next step.


Also Read: 5 Facile Yet Incredibly Valuable Ways to Enhance ASP.NET Developer’s Efficiency


Step 5: Beautify the menu to make it appear captivating

To ensure an enticing and easily readable menu, it is essential to make it appear visually appealing and intriguing. You may use the CSS appropriately to enhance the look and feel of the menu in a desired fashion. Here, I have incorporated the following chunk of code in the CSS file to boost the navigation ease and ensure an attractive Menu.

Code Snippet CSS:


ul, ol, li {list-style: outside none none;}
.nav {float: left;padding: 0;background-color: #5eab1f;}
.nav li {display: inline-block;position: relative;vertical-align: middle;}
.nav li:hover, .nav li.active {background-color: #4c9312;}
.nav li a {color: #fff;float: left;font-size: 15px;padding: 16px 14px; text-decoration: none;}
.nav li ul {background-color: #fff;border-radius: 0 0 5px 5px;box-shadow: 0 2px 3px #000;display: none;min-width: 200px;padding: 20px 0;position: absolute;top: 48px;z-index: 9999;}
.nav li ul:before {border-bottom: 8px solid #fff;border-left: 8px solid transparent;border-right: 8px solid transparent;content: "";left: 28%;position: absolute;top: -8px;}
.nav ul li {float: left;width: 100%;}
.nav ul li a {color: #333;float: left;font-size: 15px;padding: 10px 5%;width: 90%;}
.nav li:hover, .nav li.active {background-color: #4c9312;}

This CSS has been created considering a few requirements, you may develop it in a desired fashion to bring substantial changes in the visual appearance. Therefore, you may streamline the CSS as per your UX and design needs.


Wrapping Up

By following this absolute guide, you can efficiently create beautiful dynamic menus via the ASP.NET MVC. It is advisable to thoroughly go through each step and design desirable menu while ensuring utmost navigation ease.

Author Bio
Sarah Parker is an experienced PSD to WordPress service provider, and a web designer. She loves to share her thoughts on web design and web development trends.

Friday, February 13, 2015

Free Identity PSD Mockups Design

Free Identity Mockups Design

Free Download Identity PSD Mockups Design. A special package containing a full corporate identity design mockups set. Enjoy!

Type : PSD
Category : Mockups
License : Free
Author : Weareutopia
Download

Nested if else in C

In the previous tutorial we have learnt about if-else statements. Those statements provide the flexibility to check for two possible faces of answer. But it is also possible that there will be more than two options for the answer. To make things more precise, take an example of school grading system. Suppose if you want to create a program that will print the grade of student based on his/her percentage marks. Then in that case you will need at least 4 conditions to check.

So to put those things on work we have to use nested if-else statements.


What are nested if-else statements?

As the name suggests, nesting means writing if-else statements inside another if or else block. Basically there is no limit of nesting. But generally programmers nest up to 3 blocks only.

General form of nested if-else statements is given below.

if (condition)
{
Statement 1
Statement 2 and so on
}

else
{
if (condition)
{
Statement a
Statement b
}
else
{
Statement c
Statement d
}
}

It’s a bit complex structure for beginners so lets try to understand its general form.

As you can see, I have nested another if-else block inside one else block. So while executing in this form. The compiler first check the condition if (primary or first) block. If it fails then it will move on to the else block. In the else block it will check the condition of secondary if statement, if it also fails then it will execute the statements under else block.

In our general form I have nested if-else block in else block. You can also nest that if-else statement under first if statement. This will also work.

Now lets try implement our knowledge in one program.

Question: Take one number from the user. Check it whether it is negative, zero or positive and print the message for it.


#include <stdio.h>

void main()
{
int num;
printf("Enter any number:");
scanf("%d",&num);

if (num < 0)
printf("number is negative");

else
{
if (num==0)
printf("number is 0");
else
printf("number is positive");
}
}


Output

Nested if-else in C - Output

Explanation

I have deliberately write that program which is similar to the last one. As I want to show the importance of if-else nesting inside C programming.

Initial statements of the program are self-explainable. So I will start my explanation with if-else statement.
  • In the first if statement, I have given a condition i.e. num<0, it will check the number whether it is negative or not. If it is negative then it will print the message "number is negative". But if condition fails then it will skip the statements under if block.
  • Am I forget to write curly braces {} after if statement? The program will also work by dropping them in our case. This is because the default scope of if statement is one statement after it. As I have written only one statement, so there is no need to use curly braces in it. However if you write more than one statements under that block then you have to insert curly braces.
  • After that I gave another else block. And inside that else block I have nested one if-else block. It means after entering the control inside else block it will check the condition of 2nd if block. If the condition turns out to be true then it will print the message "number is 0". Otherwise the control will transfer to the else block and it will print "number is positive".
  • In the above program you can clearly see the secondary if-else block. Because I have indented the 2nd if-else block to increase the readability of program. So it is advised to use indentation while using nested if-else.