Attaching JS and CSS Assets in Drupal 8

Drupal 8 has introduced a different way of attaching JavaScript and CSS to themes and custom modules via a new concept called libraries, which are covered in Day 9. Libraries are essentially .yml files that define different groups of assets that can later be attached via module code. When I started working with the theme layer in Drupal 8, I quickly realized that certain things are very different from Drupal 7. One of the main gotchas for anyone new to Drupal 8 is the idea that JavaScript libraries are now only loaded where they are needed. In contrast to Drupal 7 where jQuery for example, was loaded on every page, in Drupal 8 jQuery is no longer automatically loaded. This provides for a better optimized site with only the required libraries included in areas that they are needed. ...

August 15, 2016 · 3 min · 491 words · icarnaghan

Drupal 8 Plugin System

There is a lot of new terminology in Drupal 8 and for anyone not familiar with Object Oriented programming, some of it can be downright confusing. For myself, I have worked with OOP for quite a while, however I have not spent as much time writing custom modules for Drupal 7. While I am familiar on the surface with the hook system and API at a very novice level, I have never really had to do any intense back end development in D7. Now that I am working in Drupal 8, things are quite different with my projects at work. Thankfully my OOP background has filled in some of the gaps, however my lack of Drupal 7 module development knowledge has proven to be a burden. ...

August 14, 2016 · 3 min · 542 words · icarnaghan

Cron Queuing in Drupal 8

Day 7 focuses mainly on the Drupal Queue API. The main resource for this card is an article called Drupal 8 Queue API – Powerful Manual and Cron Queueing, which I had referenced in an earlier post. Before completing any of the materials, I had no previous experience with the Queue API, nor hook_entity_insert, which was used to create a demo queue system in the referenced article. After going through the article I gained a better understanding of how the queue system works. At a high level the following steps outline the process of constructing the module that is documented in this article along with relevant links to the API. ...

August 13, 2016 · 5 min · 963 words · icarnaghan

Is Shared hosting bad for SEO and is it safe for your site?

SH is a type of hosting in which your site will run along with several other websites on the same server. If you are planning to purchase a web hosting plan, you may be having a doubt whether shared hosting is bad for SEO and is it safe? I will try to clear the confusion for you but before that, you should know the below important points. Shared website hosting assigns: ...

August 12, 2016 · 2 min · 406 words · prhost78

Services and Dependency Injection

For several years I have worked as an ASP.NET MVC developer and have become intimately familiar with terms such as services and dependency injection and services. It is refreshing to see some of these familiar concepts surfacing in Drupal 8. Day 6 focuses mainly on introducing us to services and dependency injection via several online resources. There is no exercises or tasks in this card as the aim is to simply gain an understanding of some of these concepts. I saw a lot of overlap in terms of syntax and how dependency injection is handled in Drupal 8 compared with Unity and StuctureMap in ASP.NET, so anyone from background or other traditional object oriented languages such as Java will be familiar with a lot of this. I have outlined the main takeaways I got from the Day 6 below. ...

August 12, 2016 · 6 min · 1071 words · icarnaghan

Drupal 8 Migration

I have had some exposure to the migrate module in the past, mostly with Drupal 7 and more recently for a Drupal 8 migration project that required importing of a small (under 1000) set of records stored in a CSV file. Todays D8Card focuses on the new migration module that comes partly with core and also partly in the form of contributed modules. Migrate Core & Migrate Contrib The purpose of todays set of tasks was to import a couple of small CSV files using migrate and some of the contributed modules. I started out by reviewing the links posted in the card and then proceeded to download and install migrate_tools, migrate_plus, and migrate_source_csv. What comes with Drupal 8 core out of the box is pretty limited and only contains migration functionality for moving content from previous Drupal sites. It definitely makes the upgrade process less painful, however if you want to get into migration code that can manage a multitude of external sources, then you will want to grab to contrib modules above. ...

August 11, 2016 · 6 min · 1071 words · icarnaghan

StudioPress Genesis Pro Plus Package : All themes at great price

StudioPress Genesis Framework powers 1000s of WordPress sites. It is better than Thesis and many other WP frameworks. It is SEO friendly, mobile optimized, lightweight, and fast. SGF includes several intuitive features. It includes special modules that save your money. Example, you won’t need a premium opt-in form aka newsletter plugin if you use SGF. Many top bloggers who earn six figure income per month use SGF. StudioPress Genesis is the highest rated and most successful WordPress product. ...

August 11, 2016 · 3 min · 507 words · prhost78

The New Block System in Drupal 8

Among the many changes in Drupal 8, the blocks system received an overhaul, which has improved much of its functionality significantly. Some of the most notable take aways include the new block page layout and UI for updating, adding, and editing blocks, the addition of custom blocks and fieldable types (similar to content types), and integration with display view modes to allow for rendering changes based on block placement. Day 5 directs you to a good introductory video of the new blocks system by the Drupalize.me team. ...

August 11, 2016 · 4 min · 722 words · icarnaghan

Best AdSense alternatives to earn dollars not cents (2018)

AdSense is a great platform for making money online. But getting approved for it or having a five or six figure AdSense revenue is a difficult task. People have a misunderstanding that GA is the only advertiser with which they can make them rich. They are wrong. Nothing is predictable in the world of internet. Hence, you should always try out different strategies for maximizing revenue from the blog. There are many methods of monetizing a website. This is what I have learned from my 3 years of experience as a blogger. People make a mistake by depending only on AdSense aka a single source for their earnings. They don’t experiment with other monetization programs aka AdSense alternatives. ...

August 10, 2016 · 4 min · 685 words · prhost78

Building Configuration Forms

In Day 3 we are starting to accelerate in terms of skills developed by the cards. This card has us create our first Drupal 8 module, learn about Drupal 8 Form API and learn about the Configuration API. The card starts off with directing you to several Drupal.org documentation pages including Creating a Custom Page, Defining and using your own configuration in Drupal 8, Providing Default configuration, and Simple Configuration API. Except for the Creating a Custom Page document, everything else here is focused on giving you a solid overview of the configuration system within Drupal 8. ...

August 9, 2016 · 5 min · 1036 words · icarnaghan