ReactJS Vs AngularJS – Which One to Pick?

ReactJS and AngularJS are both extremely popular frameworks used by any mobile app development company. Both are great in their own ways and have their advantages and disadvantages depending on what developers are looking for. Lets analyse features of both major cutting edge players and you can decide which one to pick.

AngularJS

Angular is pretty much the perfect solution for handling data binding. Data binding in Angular apps involves the automatic synchronization of data between the model (or customer input source) and the “view”. When the model changes, the view mirrors the change, and vice versa. By cutting out multiple steps, Angular can be a very appealing option.

ReactJS

ReactJS is an exceptional framework for managing the DOM (Document Object Model), especially when dealing with vast amounts of data. React mainly works by creating a virtual DOM in JavaScript that behaves as an intermediate representation of the DOM. This representation makes it easy to decide which elements to change in the DOM and what the results may be.

Comparison:

Age:

React has just started while Angular has been there since long. So support for Angular is much better. While Angular’s coding is more complex, React is easier to use so you need less help from the support communities.

Speed & features:

Angular JS is more powerful but is little less in speed than React. When there is a huge database to pull data from, users might experience a slight delay. React is faster than Angular JS so works fine while rendering large data.

It uses full MVC architecture so it is great for experienced coders to use. It uses only the view component so it less features rich than Angular JS. Beginners should use React.

Deployment:

Angular JS functions from HTML perspective and provides limited scope of tools for packaging and deploying the code. While React functions from Javascript perspective and provide a library like RequireJS to load the code.

Debugging:

With Angular JS its easy to write the code but difficult to debug. With React, its much easier to debug. You can get React Developers Tools extension for chrome and get started.

Who wins:

Well the answer is both! Lets use them with each other and not against. React’s pure JavaScript environment gives developers more flexibility and ease of learning. When Angular restricts something, you can expect React to provide full freedom.Equally powerful, use a combination of both in your next big project.

First Thoughts on HTML5 and CSS3

The arrival of new software is always greeted with enthusiasm. And so it was when I first tried out HTML5 and CSS3. I was looking forward to having gradients work without error, and having an easy way to create boxes with curvy corners. Also CSS has lots of named colours, rather than cryptic RGB hexadecimal numbers.

I am still coming to grips with the shock horror at the deprecation of the “Center” Tag. And the denigration of the usage of Tables. Grumble, grumble.

The new features of HTML5

Many of the constructs of old have been simplified or omitted – although the old version will still work.

The standards for HTML construction have been eased, perhaps to too great an extent. Microsoft’s Visual Studio enforces a stricter standard, and for a change I am in complete agreement with Microsoft (well, it had to happen, sometime!).

And then there are the new features of HTML5, formerly the domain of JavaScript. There is now Video, Audio, Forms, Validation, Sliders, Date Pickers, Colour Pickers, Geolocation, Local Storage, Offline Web Applications, Placeholders, Autofocus, and a lot more. No JavaScript is needed.

And then there are the new Semantic Elements.

The Semantic Elements

The new Semantic Elements had me reasonably baffled. I wasn’t too sure what Semantics had to do with Websites. It sounded more the field of expertise for a professor of linguistics.

There are now new Elements for Sections, Headers, Footers, Navigation, Articles, etc. The idea, I discovered, was simple enough. The HTML structure should be understandable by coders as well as Search Engine spiders.

But the new structures, together with the CSS, do not seem to simplify the coding at all. The complexity of Headers within Sections within Articles within Headers is daunting. And then there is the complexity of the CSS3 involved. The Website coder will need to be a graduate with a degree in Logic and Semantic Differentials, before being able to fully comprehend what the new Semantic Elements features are all about.

I cannot see results oriented Website designers being bothered to use the new Semantic Elements.

The Search Engines

Whether the Search Engines gain from the new Semantic Elements is debatable. One thing for sure, they will need to have much additional logic to cope with both the traditional coding, and the new structures.

And it won’t take long before some inventive coder befuddles the Elements and Structures in order to gain better rankings.

The Older Browsers

The number of people worldwide using Internet Explorer 6 has diminished to less than 1%. IE6 usage is low enough to be ignored, but IE7 and IE8 user numbers are still too high to be disregarded.

With some minor additions, the old Browsers can handle the new features without too much bother. There is “Modernizr” which will detect support, or lack of support, for HTML5 and CSS3 features in the user’s Browser. The Progressive Internet Explorer (PIE) will add Polyfill features like rounded corners, shadows and gradients.

HTML5, CSS3 and Mobiles

The explosion in growth of the Mobile has fostered a growth in the popularity of HTML5, CSS3 and JavaScript – the language of choice.

Whether the success of HTML5 and CSS3 in the Mobile market will translate to the desktop and Websites is debatable. Starting from fresh to program a new iPad is one thing – converting 700 million Websites is yet another.

Current Website Practices

In order to get a feeling for the implementation of HTML5, I viewed a few popular Websites:

  • The Google Search uses HTML5. I am not too sure how meaningful this is. The secure site seems mainly constructed to prevent automated reading attempts to determine Website rankings. And the HTML code is comprised entirely of Scripting. No Semantic Elements did I see.
  • The Microsoft, Amazon and Hewlett Packard Websites are still using XHMTL 1.0 transitional.
  • Intel is one step ahead – they are using XHTML 1.0 Strict.
  • Walmart is on HTML5 – but none of the new Semantic Elements are being used.

My Conclusions

I guess we can conclude that there is no rush to use the new standards or features.

Where there is a Website that is to be upgraded to HTML5 and CSS3, I feel that most coders will follow the Walmart example. That is the functionality of HTML5 and CSS3 will be used, but not the Semantic Elements. This will make the upgrade as easy as can be.

For a new and simple Website, some intrepid coders may try their hand experimenting with the new Semantic Elements.

In SEO, What is the Most Important Thing to Do?

There really is nothing more important than the inbound link if we are talking about getting a site listed well in the SERPs (search engine results pages). I have seen this proven, time and again, when a site will pop up into a high position with nothing other than a few links pointing at the site from other, relevant and important, sites.

It’s important to note that these links we are talking about are one way inbound links. These are not reciprocal links. They are also from sites with a high PageRank or importance and also the links utilize important keywords, i.e., the same keyword or phrase as the listing we are talking about.

Next in importance would be the title tag. I have also seen sites pop into the high listings simply from improving on the title tag. Of course everything depends on the competition levels, the higher the competition level, the more difficult it will be to get listings. I have had good luck with title tags in the 12 word range and using keywords within it that appear on the page within the body content.

I would say the most important things with the title tag is to make sure that the keywords you use actually show up in the content of the site. Don’t put keywords into the title tag that do not appear on the page itself. Always spend some time on creating a title tag that is relevant to that particular page.

Next in importance is probably the heading tag. H1 in particular. This should be the most important keyword for the page, and, be what the page is all about. It’s not smart to stuff this tag. I have no real proof that any number of words in better than any other, but in general I look at this tag as a title for the page and hence, try to keep it simple and under five words. Often one, two or three words is enough to define the page. Make sure you use the most important keyword for the particular page. Make sure this tag is defining what this page is all about.

Navigation can make or break you site. Javascript navigation looks really nice but it can’t be read by the spiders. Did you know that? I have seen many clients sites where the main home page gets indexed, but no other pages. More often than not this is caused by the navigation being javascript and the engines never even finding any other pages. I like to repeat the most important navigation along the bottom of the page, horizontally and in a smaller size type. I like this for two reasons, one is gives the engines another place to find the links to the rest of the site, and it also allows for the user to click a link to the next part of the site they want to see, right at the end of what they are reading.

The text used in these links should be keyword rich and definitive of the location you are pointing at. Click here just doesn’t cut it. You want this anchor text to be informative and define where you are going. That is for the engines, but it doesn’t hurt the user either!

I might get in trouble saying that I think code attributes are important. Some folk just don’t agree. I have seen some sites rise in the listings after only changing (or adding) the alt= attribute on the image tags. Use your keywords, don’t stuff them, and make them relevant to what the image itself is. Consulting Logo is a better alt attribute than logo is.

There is a lot more, and it should be known that everything you do to optimize a site works together… there is no silver bullet, no one thing to do, no magic. It takes a lot of small steel parts to build a skyscraper. It takes a lot of code improvements and linking to build a website. Everything works together the same way 30 instruments can create a symphony, or a cacophony of noise!

Best Place to Learn Programming

Nowadays, Programming is not just for computer geeks anymore, it has become a “must have skill” to stay in the market.

Coding is an incredibly much valuable skill for employers and members of any business team. With programming, you can make your own website, mobile app. If you learn to program, you can take your entrepreneurship skills to the next level.

Everyone holds the equal potential, and the chance to learn programming language easily. Today, we will show you a list of top websites that will help to learn to program.

Code Academy

Code Academy is one of the best places to learn programming languages. It is a well known first stop for those who are looking to begin their programming education.

Students can learn to code from their several different courses like:

  • HTML & CSS
  • JAVA
  • PHP
  • JavaScript
  • Make a Website
  • Ruby on Rails
  • Angular JS
  • SQl
  • Python
  • jQuery

MIT Open Courseware

If you want to learn to code in a high-class university level – then MIT Open Courseware is the best place for you. So take advantage of this opportunity and check out top courses like:

Introduction to Computer Science and Programming, Introduction to Programming in Java and Practical Programming in C.

Coursera

Coursera is an educational technology company that has offered more than 2,000 courses from 150 top institutions around the world.

If you want to improve the beauty of your CV, you can get a paid certificate from coursera. So learn to code from Coursera and become a top programmer.

edX

edX is the leading online-learning platform that is the open source instead of for-profit. Founded by the top universities like Harvard University and MIT in 2012. you should know that you’ll learn about the latest cutting-edge technologies and theories.

edX offers tons of free programs, including courses on programming.

Khan Academy

Khan Academy is actually my favorite to place to learn programming. If you are looking to learn to program in an interactive way then khan academy is the best place to do so. Offering free programs like:

HTML / CSS

JavaScript

SQL

Animation

and many more…

Udacity

Udacity is the project of Stanford University. It is one of many sites that make college courses available online for free. Stop thinking that how to learn programming.

Learn high-quality courses from the high quality website.

Udemy

Founded in 2010, Udemy is an online learning platform through which you can not only learn to program every programming language. But you can also learn almost every skill available on the internet. Yes! you heard it Right. There are many courses you have to pay for, also, there are several free programming courses, which are taught via interactive video lessons.

Google Android Course

Want to learn Android development, why not learn from the king of the internet Google. Offers free courses on mobile/android development (beginner to expert level). Android development is the trending skill that you can learn to get a well-paid job.

GitHub

Need a reference book to learn programming? At GitHub, you can find more than 700 free programming books that cover more than 80 different programming languages.

7 Efficient Apps That Are Suitable for Doing Programming on the iPad

This is an undeniable fact that the iPad is not the most favoured hardware choice for programming purpose. However, with the increasing popularity of this device, many developers are dedicating themselves to devise such applications that work well on the iPad and are not offering very unsatisfying services! Here is a list of 7 efficient programming apps that work well on the iPad without creating many complications.

#1 Coda

Initially, Coda started its journey as a Mac editor only. However, now, Coda offers an impressive and dynamic iPad and iPhone text editor as well. Due to its utmost efficiency, many developers are looking forward to this programming app. Some of its remarkable features are:

It provides necessary support to syntax highlighting for several programming languages such as C, Apache, HTML, CSS, Go, PHP, Python, Perl, JavaScript etc.

This application includes remote as well as local file management along with a diverse collection of remote protocols like WebDAV, SFTP, DreamObjects and Amazon S3.

Using Coda, you can avail facility of ‘Clips’ that is a smooth way to store the most commonly used bits of codes.

#2 Buffer Editor

Another top-notch code editor is Buffer. With the help of Buffer, you can effortlessly connect a plethora of remote services like Github, Dropbox, SFTP, FTP servers and iCloud SSH. What are the other features? Read on to know more.

It features Vim coding support, a Unicode support along with an extended keyboard.

Buffer offers facility of code auto completion and syntax highlighting for many programming languages that include AWK, Ada, ASP, ActionScript, C++, C, Arduino, C#, Python, Ruby, SQL, JavaScript, Java, PHP, Perl, Puppet, INI, CSS, R, Progress etc.

#3 Textastic Code Editor 6

If you are looking for a Textmate-compatible markup language editor that efficiently works on the iPad, this Textastic Code Editor 6 is just the perfect choice for you. It not only offers facility of syntax highlighting for a long list of programming languages but offers the same for markup languages as well. Additional features of this editor are as follows:

It provides auto code completion for CSS, JavaScript along with PHP functions at the time of editing.

This editor comes up with its own server of WebDAV.

It can effortlessly communicate with SFTP, FTP, Dropbox.

#4 OmniGraffle 2

If you are looking for an editor that is extremely useful for diagramming, you can put your trust on the OmniGraffle 2. The process of a site planning becomes utterly smooth using this version of the editor. Yes, this package is a bit costly compared to the other options mentioned in the list but once you use it, you would understand that it is worthy of its price. Some of its remarkable features are:

A great variety of in-app purchase options is available in OmniGraffle 2.

Smart guides are available to help you with optimising the diagram in flash.

Using it, you can easily draw various shapes and drag the objects.

Visio Support is also available in this package.

#5 Pythonista 3

Pythonsia 3 is famous for offering a complete scripting environment to the users, who use a Python compatible iPad, iPhone and iPod Touch. To run it, you would need iOS version 8. Additional advantages of using this editor are as follows.

Not only auto code completion and syntax highlighting but support are available as well for the Python version 2.7 and 3.5.

It features third-party modules like Bottle, SciPy, BeautifulSoup etc.

Matplotlib and NumPy integration are available for scientific visualisation.

#6 CodeToGo

CodeToGo is extremely easy-to-use and very intuitive. The main reason for the popularity of this editor is simplicity. Here are some of its satisfactory features.

It provides facility of writing and running code in almost 50 distinct programming languages. Moreover, syntax highlighting is available languages like Python, Ruby, Perl, Java etc.

Communicating with the Dropbox becomes easier using CodeToGo.

The process of file transfer to and from the computer becomes smoother using iTunes File Sharing system.

After writing the code, using ideone.com API, you can test it on CodeToGo and can see the output.

#7 Codea

This editor is very useful for developing simulators and games. Why is this editor becoming popular? Here are the reasons.

It offers visual editing and syntax highlighting facility for Lua.

Codea includes shader support, a graphics renderer, touch support along with a Physics engine, camera and accelerometer.

Apart from all the above-mentioned iPad programming apps, iOctocat, AppCooker, JavaScript Anywhere etc. are also trending in today’s market.

Why Choose Node JS Development?

Since the time of its launch, Node JS development is successfully doing its market as most of the developers find it perfect for building real-time, multi-user, speedy web applications. Written in JavaScript, this cross-platform runtime open source environment helps to devise networking tools and web servers as well. Here in this article, you are going to get the list of persuasive reasons to choose Node JS development. Read on to know why this development is so trending today.

Perfect for Real-Time Applications

Thinking of developing gaming apps or chat applications? To build such real-time applications, Node JS is the best option for you. This is also a reliable choice for such programs that need both event-based server and non-blocking driven servers. Worldwide immensely popular platforms like eBay, PayPal, LinkedIn etc. are the successful outcomes of fruitful Node JS development.

Fast

Google came up with the V8 engine. It has a remarkable running speed and Node JS uses it. Additionally, it makes the code running (written by the experts while devising the program) processes faster. Developers only need to focus on writing proper code and this platform would take care of the framework’s speed.

It Enriches Sharing

Creating effective web solutions using this platform becomes remarkably easier as it includes NPM (Node Package Manager) with the repository of almost 50,000 packages. Developers can easily share, update or reuse the code with the help of this inbuilt NPM.

Potent Single Codebase

Another reason Node JS is serving as a game-changing technology in the web development field is, that the developers can effortlessly work on both server-side as well as client-side with JavaScript coding. This feature not only helps to save valuable time for the developers but also helps to synchronise different data automatically between these client-side and server-side.

Offers Services as A Proxy Server

If a server-side web application dedicatedly communicates with different third party resources to collect data, to store images, this platform can act as the proxy server when an enterprise does not have enough professional proxy infrastructure.

Smooth Data Streaming

If you want to access a particular file while uploading it, Node JS would allow you to do so. This feature is extremely beneficial for the developers when they are working with real-time video or audio encoding. It makes sure to diminish the entire processing time. Nothing can really beat the efficiency of this platform in the case of data streaming from diverse sources.

Today, Node JS development is so popular among the worldwide developers that the market is full of handful options of such frameworks, on which you can smoothly build the web applications. Sails.js, Express.js, NestJS, Meteor.js etc. are some of the popular choices. Do your own research, consult with the experts and choose the most workable option for your next project.

AngularJS Techniques

Start Working With AngularJS

AngularJS is a Javascript MVC framework created by Google to build properly architectured and maintenable web applications.

AngularJS takes another approach. It attempts to minimize the impedance mismatch between document centric HTML and what an application needs by creating new HTML constructs. AngularJS teaches the browser new syntax through a construct we call directives. Examples include:

Data binding, as in {{}}.

DOM control structures for repeating, showing and hiding DOM fragments.

Support for forms and form validation.

Attaching new behavior to DOM elements, such as DOM event handling.

Grouping of HTML into reusable components.

Why AngularJS?

AngularJS is a MVC framework that defines numerous concepts to properly organize our web application. Our application is defined with modules that can depend from one to the others. It enhances HTML by attaching directives to your pages with new attributes or tags and expressions in order to define very powerful templates directly in your HTML. It also encapsulates the behavior of your application in controllers which are instanciated thanks to dependency injection. Thanks to the use of dependency injection, AngularJS helps you structure and test your Javascript code very easily. Finally, utility code can easily be factorized into services that can be injected in your controllers. Now let’s have a closer look at all those features.

Feature 1: Two Way Data-Binding

Think of your model as the single-source-of-truth for your application. Your model is where you go to to read or update anything in your application.

Data-binding is probably the coolest and most useful feature in AngularJS. It will save you from writing a considerable amount of boilerplate code. A typical web application may contain up to 80% of its code base, dedicated to traversing, manipulating, and listening to the DOM. Data-binding makes this code disappear, so we can focus on our application.

Think of your model as the single-source-of-truth for your application. Your model is where you go to to read or update anything in your application. The data-binding directives provide a projection of your model to the application view. This projection is seamless, and occurs without any effort from you.

Traditionally, when the model changes, the developer is responsible for manually manipulating the DOM elements and attributes to reflect these changes. This is a two-way street. In one direction, the model changes drive change in DOM elements. In the other, DOM element changes necessitate changes in the model. This is further complicated by user interaction, since the developer is then responsible for interpreting the interactions, merging them into a model, and updating the view. This is a very manual and cumbersome process, which becomes difficult to control, as an application grows in size and complexity.

There must be a better way! AngularJS’ two-way data-binding handles the synchronization between the DOM and the model, and vice versa.

Here is a simple example, which demonstrates how to bind an input value to an

element.

Name:

Enter a name here

Hello, {{yourName}}!

This is extremely simple to set up, and almost magical…

Feature 2: Templates

It’s important to realize that at no point does AngularJS manipulate the template as strings. It’s all the browser DOM.

In AngularJS, a template is just plain-old-HTML. The HTML vocabulary is extended, to contain instructions on how the model should be projected into the view.

The HTML templates are parsed by the browser into the DOM. The DOM then becomes the input to the AngularJS compiler. AngularJS traverses the DOM template for rendering instructions, which are called directives. Collectively, the directives are responsible for setting up the data-binding for your application view.

It is important to realize that at no point does AngularJS manipulate the template as strings. The input to AngularJS is browser DOM and not an HTML string. The data-bindings are DOM transformations, not string concatenations or inner HTML changes. Using the DOM as the input, rather than strings, is the biggest differentiation AngularJS has from its sibling frameworks. Using the DOM is what allows you to extend the directive vocabulary and build your own directives, or even abstract them into reusable components!

One of the greatest advantages to this approach is that it creates a tight workflow between designers and developers. Designers can mark up their HTML as they normally would, and then developers take the baton and hook in functionality, via bindings with very little effort.

Here is an example where I am using the ng-repeat directive to loop over the images array and populate what is essentially an img template.

function AlbumCtrl($scope) {

scope.images = [

{“thumbnail”:”img/image_01.png”, “description”:”Image 01 description”},

{“thumbnail”:”img/image_02.png”, “description”:”Image 02 description”},

{“thumbnail”:”img/image_03.png”, “description”:”Image 03 description”},

{“thumbnail”:”img/image_04.png”, “description”:”Image 04 description”},

{“thumbnail”:”img/image_05.png”, “description”:”Image 05 description”}

];

}

{{image.description}}

It is also worth mentioning, as a side note, that AngularJS does not force you to learn a new syntax or extract your templates from your application.

Feature 3: MVC

AngularJS incorporates the basic principles behind the original MVC software design pattern into how it builds client-side web applications.

The MVC or Model-View-Controller pattern means a lot of different things to different people. AngularJS does not implement MVC in the traditional sense, but rather something closer to MVVM (Model-View-ViewModel).

The Model

The model is simply the data in the application. The model is just plain old JavaScript objects. There is no need to inherit from framework classes, wrap it in proxy objects, or use special getter/setter methods to access it. The fact that we are dealing with vanilla JavaScript is a really nice feature, which cuts down on the application boilerplate.

The ViewModel

A viewmodel is an object that provides specific data and methods to maintain specific views.

The viewmodel is the $scope object that lives within the AngularJS application. $scope is just a simple JavaScript object with a small API designed to detect and broadcast changes to its state.

The Controller

The controller is responsible for setting initial state and augmenting $scope with methods to control behavior. It is worth noting that the controller does not store state and does not interact with remote services.

The View

The view is the HTML that exists after AngularJS has parsed and compiled the HTML to include rendered markup and bindings.

This division creates a solid foundation to architect your application. The $scope has a reference to the data, the controller defines behavior, and the view handles the layout and handing off interaction to the controller to respond accordingly.

Feature 4: Dependency Injection

AngularJS has a built-in dependency injection subsystem that helps the developer by making the application easier to develop, understand, and test.

Dependency Injection (DI) allows you to ask for your dependencies, rather than having to go look for them or make them yourself. Think of it as a way of saying “Hey I need X’, and the DI is responsible for creating and providing it for you.

To gain access to core AngularJS services, it is simply a matter of adding that service as a parameter; AngularJS will detect that you need that service and provide an instance for you.

function EditCtrl($scope, $location, $routeParams) {

// Something clever here…

}

You are also able to define your own custom services and make those available for injection as well.

angular.

module(‘MyServiceModule’, []).

factory(‘notify’, [‘$window’, function (win) {

return function (msg) {

win.alert(msg);

};

}]);

function myController(scope, notifyService) {

scope.callNotify = function (msg) {

notifyService(msg);

};

}

myController.$inject = [‘$scope’, ‘notify’];

Feature 5: Directives

Directives are my personal favorite feature of AngularJS. Have you ever wished that your browser would do new tricks for you? Well, now it can! This is one of my favorite parts of AngularJS. It is also probably the most challenging aspect of AngularJS.

Directives can be used to create custom HTML tags that serve as new, custom widgets. They can also be used to “decorate” elements with behavior and manipulate DOM attributes in interesting ways.

Here is a simple example of a directive that listens for an event and updates its $scope, accordingly.

myModule.directive(‘myComponent’, function(mySharedService) {

return {

restrict: ‘E’,

controller: function($scope, $attrs, mySharedService) {

$scope.$on(‘handleBroadcast’, function() {

$scope.message = ‘Directive: ‘ + mySharedService.message;

});

},

replace: true,

template: ‘



};

});

Then, you can use this custom directive, like so.

Creating your application as a composition of discrete components makes it incredibly easy to add, update or delete functionality as needed.

we will discuss here about how to set up AngularJS library to be used in web application development. We will also briefly study the directory structure and its contents.

When you open the link https://angularjs.org/, you will see there are two options to download AngularJS library –

AngularJS Download

View on GitHub – Click on this button to go to GitHub and get all of the latest scripts.

Download AngularJS 1 – Or click on this button, a screen as below would be seen –

AngularJS Download

This screen gives various options of using Angular JS as follows –

Downloading and hosting files locally

There are two different options legacy and latest. The names itself are self descriptive. legacy has version less than 1.2.x and latest has 1.5.x version.

We can also go with the minified, uncompressed or zipped version.

CDN access – You also have access to a CDN. The CDN will give you access around the world to regional data centers that in this case, Google host. This means using CDN moves the responsibility of hosting files from your own servers to a series of external ones. This also offers an advantage that if the visitor to your webpage has already downloaded a copy of AngularJS from the same CDN, it won’t have to be re-downloaded.

Try the new angularJS 2 – Click on this button to download Angular JS beta 2 version.This version is very fast, mobile supported and flexible compare to legacy and

latest of AngularJS 1

We are using the CDN versions of the library throughout this tutorial.

Example

Now let us write a simple example using AngularJS library. Let us create an HTML file myfirstexample.HTML as below –

Welcome {{helloTo.title}} to the world of Tutorialspoint!

Following sections describe the above code in detail –

Include AngularJS

We have included the AngularJS JavaScript file in the HTML page so we can use AngularJS –

If you want to update into latest version of Angular JS, use the following script source or else Check the latest version of AngularJS on their official website. Point to AngularJS app Next we tell what part of the HTML contains the AngularJS app. This done by adding the ng-app attribute to the root HTML element of the AngularJS app. You can either add it to HTML element or body element as shown below –

View

The view is this part –

Welcome {{helloTo.title}} to the world of Tutorialspoint!

ng-controller tells AngularJS what controller to use with this view. helloTo.title tells AngularJS to write the “model” value named helloTo.title to the HTML at this

location.

Controller

The controller part is –

This code registers a controller function named HelloController in the angular module named myapp. We will study more about modules and controllers in their respective chapters. The controller function is registered in angular via the angular.module(… ).controller(… ) function call.

The $scope parameter passed to the controller function is the model. The controller function adds a helloTo JavaScript object, and in that object it adds a title field.

Execution

Save the above code as myfirstexample.HTML and open it in any browser. You will see an output as below –

Welcome AngularJS to the world of Tutorialspoint!

When the page is loaded in the browser, following things happen –

HTML document is loaded into the browser, and evaluated by the browser. AngularJS JavaScript file is loaded, the angular global object is created. Next, JavaScript which registers controller functions is executed.

Next AngularJS scans through the HTML to look for AngularJS apps and views. Once view is located, it connects that view to the corresponding controller function.

Next, AngularJS executes the controller functions. It then renders the views with data from the model populated by the controller. The page is now ready.

4 Top Cross Platform Mobile App Development Tools

Cross platform mobile development refers to a technique of developing mobile applications which can be used on multiple mobile platforms. As there are numerous platforms, device fragmentation was one of the major challenges which made it difficult for the developers to create apps that runs on all mobile devices. Cross-platform mobile development tools were developed to solve this issue which ensures uniformity by offering common device functionality features.

As today’s mobile application developers are trying to be agile, they use the best tools to develop a mobile application. Below listed are the 4 best cross platform mobile app development tools.

1. PhoneGap / Apache Cordova

2. Appcelerator Titanium

3. Adobe Air

4. Sencha Touch

1. PhoneGap / Apache Cordova:

It is an open source framework which lets you create mobile applications using standardized web interface for the platforms you care about.

Advantages:

* It doesn’t require the knowledge of dense programming languages as it follows basic development languages like JavaScript, HTML and CSS.

* It lets you develop apps easily without any major investment.

* Installation of PhoneGap app is similar to the installation of a native app.

Disadvantages:

* Mobile app developer himself has to write the plugin if it’s not available.

* Performance will be affected if the developer uses many graphics.

2. Appcelerator Titanium:

It is an open and extensible development environment used for creating beautiful native apps across different mobile devices.

Advantages:

* It lets you develop an application in a flexible way with its rapid prototyping.

* Uses JavaScript, HTML and CSS for creating the app.

* Uses standard user-interface elements like tables, buttons etc.

* It lets you store the data locally.

* Supports asynchronous module definition (AMD) and common JS.

Disadvantages:

* Access is restricted for certain components of a mobile OS.

* It offers limited access to device resources like camera.

3. Adobe Air:

It is a new-generation technology which allows you to develop applications easily using HTML, JavaScript, Ajax, Adobe Flash and Adobe Flex.

Advantages:

* Assures a rich user experience.

* It lets you create apps with rich media content which require flash.

* Easy to install.

* Plays high-quality HD videos with industry-standard codecs.

Disadvantages:

* Database access is limited to SQLite or web services.

* Developer needs to have a good knowledge on complex languages to use Adobe Air.

4. Sencha Touch:

It is a mobile application framework which enables you to build powerful applications that work on iOS, Android Windows and other platforms.

Advantages:

* Delivers a rich experience as expected by the users.

* It provides rich set of documentation and screencast which makes you more productive.

* It ensures pixel perfection with its advanced layout engine.

Disadvantages:

* Chances of vendor getting locked in are high as it is not an open source.

* It works only on JavaScript which may create issues while creating mobile apps.

Fortune innovation brisbane’s expert designers help you in developing smarter mobile applications while deciding which cross-platform framework is ideal for you. Kindly get in touch with us for any requirements on the development of mobile applications.

Web Programming Services You Can Employ for Effective Web Development

Every internet user is familiar with the term WWW or World Wide Web. The World Wide Web is nothing but a system of interlinked hypertext documents. These documents are generally written in Hyper Text Markup Language or HTML. HTML supports internal and external linking and you can link your document with graphics, audio, video etc. These days we can’t think of a world without internet. People share information, communicate with each other, market products or services through internet.

Web programming is the soul of Web. Without programming, nothing can work on the internet. It is the building block of every website. A web programmer writes codes and utilizes programming tools like CSS, XML, Javascript, HTML and any other programming languages that are necessary to develop a website.

Here are some of the popular web programming services that web developers use to create complex and feature rich websites. Using these web programming tools they write cleaner codes and help your site rank high in search engine results.

  1. AJAX- The full form of AJAX is Asynchronous JavaScript and XML. It’s a method of developing interrelated web developments that process user requests instantly. AJAX uses several programming tools.
    • For presentation purpose it uses Dynamic HTML (DHTML) and Cascading Style Sheets (CSS).
    • For data manipulation and data display it uses Extensible Markup Language (XML).
    • For dynamic display of data and interaction purpose it uses Document Object Model (DOM).
    • It also uses JavaScript to synchronize all the functions.

    Google map is an Ajax based application. That is why it allows you to manipulate the data on the map. In Google map, you can immediately find any location from a global map and add favorites to your most searched places.

  2. Web 2.0 Programming- Web 2.0 programming is the most popular trend these days. It offers better user interface and provides more freedom to the users. Web 2.0 is also known as “social bookmarking.” Some of the popular Web 2.0 sites are Furl, Blinklist, Del.icio.us, Blogmarks, Kaboodle etc. Social bookmarking improves search engine ranking. When a number of web users like a website and bookmark it, that site gets a top spot in search engine ranking.
  3. CGI (Common Gateway Interface)- With the help of CGI a server can send or fetch data to databases, documents and other programs. The core programming language in CGI is Perl. When you search for something on a website, CGI inspects the content and gives an appropriate response. Websites like Facebook, Yahoo and WikiPedia use CGI as their web development platform.

Web programming is all about adding functionalities to a website. With the help of programming, you can customize the features of your website and give your users an enjoyable experience.

Web programming is a complicated process. If you want to develop a functional and user friendly website, hire a professional web programming company for the job. However, before you hire a company, make sure that they have the infrastructure to provide you quality service. Meet with their programmers and discuss your requirements with them. If you are satisfied with their knowledge, only then you should hand over your project.

A Guide to Understanding Ad Blocked Traffic in Google Analytics

Ad Blocker software doesn’t care about your terms and conditions, or how hard you work to create your content. In the process of blocking your ads, it messes up your Google Analytics tracking – and it leaves you guessing.

  • Are my ads not loading properly?
  • Are my ads underperforming?
  • How many of my visitors never actually see them?
  • Who’s blocking my ads?

Just to make things clear, we’ll say it again, we’re not going to tell you how to do anything illegal. In fact, we’re just going to utilize a smart code strategy. It’s one that gives us a way to detect when ad blockers are being used. Let’s ask Mr. Doyle why that’s important:

“It is a capital mistake to theorize before one has data” – Arthur Conan Doyle

Uncloaking the Ad Blocker Data

Ad Blockers are definitely not as invisible as they might like to think. Of course, that’s not really their primary goal anyway. We’ll tell you, step by step, how to copy-paste a little piece of JavaScript code to better understand your ad blocking traffic.

We’re going to give you detailed configuration instructions. We’ll also explain how to understand your new Google Analytics data. So what’s the end result?

  • You’ll know what percentage of your visitors are using ad blockers
  • You’ll be able to determine the impact it has on your Ad revenue

It’s kind of a big deal. Ad blocking cost publishers an estimated $22 billion during 2015. Usage grew by 41% worldwide in the last year. Gulp.

First Things First – Your Prerequisites

To use this strategy, your site must have both Google Analytics and Google AdSense installed.

We use these as the key elements of the detection hack, which by the way is by courtesy of the great contributors at Webmaster World. They detect when AdSense isn’t running as expected, which indicates that an ad blocker is in place. So that means ads from any network are most likely getting blocked too. All of your ads are gone… just like that.

FYI – For the purposes of our strategy, we’re ignoring users who are disabling JavaScript entirely. This is a very small segment of your traffic. And they are very hard to track. They are likely highly techie/experienced users who are willing to accept a degraded presentation across the entire web.

Here’s the TL;DR

You need this JavaScript snippet:

<script>

if(typeof adsbygoogle!== “undefined”) {

window.addEventListener(‘load’, function() {

if(typeof ga!== “undefined”) {

if(typeof adsbygoogle.loaded === “undefined”) {

ga(‘send’, ‘event’, ‘AdSense’, ‘Ads blocked’, { “nonInteraction”: 1 });

} else {

ga(‘send’, ‘event’, ‘AdSense’, ‘Ads not blocked’, { “nonInteraction”: 1 });

}

}

}, false);

}

</script>

If you want to track only “Ads blocked” events, you can use this modified version:

<script>

if(typeof adsbygoogle!== “undefined”) {

window.addEventListener(‘load’, function() {

if(typeof adsbygoogle.loaded === “undefined” && typeof ga!== “undefined”) {

ga(‘send’, ‘event’, ‘AdSense’, ‘Ads blocked’, { “nonInteraction”: 1 });

}

}, false);

}

</script>

Now that you’ve pasted the above, let’s go over to Google Analytics and get down to business:

  1. Create a Custom Segment
  2. Create New Segment for “Ads blocked”
  3. Configure new segment to grab data for the event created in the above JavaScript.
  4. Repeat for “Ads not blocked”
  5. Extra credit: Create a custom dimension

How to install the ad blocker tracking code

If you’ve installed snippets of code on your site before, you’re good to go. If not, we really recommend you add a tag management system like Google Tag Manager. Otherwise, please contact your friendly neighborhood web developer for a quick code update.

Paste the code snippet just before the ending </body> tag of your site template. It needs to show up on every page. That’s all you need for the code installation part.

Note: For this hack to work, your Google Analytics has to be Universal Analytics or the version containing “analytics.js.”

What does the JavaScript code do?

This isn’t a coding tutorial, so we won’t bore you to death with any more technical complexity than needed. It’s just a bit of really smart JavaScript. Here is what is happening step by step:

  1. Wait for the page to load, and then check to see if Google Analytics successfully loaded.
  2. If GA loaded JavaScript, then it is working, so check to see if your Google AdSense loaded too.
  3. Send some data to your Google Analytics account to indicate whether the ad was blocked or not.

If your pages load up and your Google Analytics is doing what it’s supposed to do, you check your AdSense.

And if AdSense doesn’t load? Then we can reasonably infer that it was prevented from loading by an ad blocker. Busted!

That’s it. Some slick code using some smart logic to segment the users that are ad blocking and those who are not. Then it sends this information into Google Analytics for your to review.

A single line of code tells Google Analytics to store an event for us. That event tells us whether we detected the ad blocked or not. That’s it.

There are also extra features for advanced users but that’s for another article.

Freelance Web Designer | Web Design | WordPress | Hong Kong