While working on a Drupal 8 project we suddenly encountered this error after pushing the site to the development server. This had not occurred in our local machines which caught us off guard. A little debugging on the error log revealed the cause of this Drupal message.
If you encounter this error unexpectedly, the first thing you should do is to check the error log of the server which is what we did. However, if you do not have access to the error log it and if the issue is only occurring in a particular server after deployment then it is most likely to be a DB issue.
Technical Blog
You can create your custom color box styles instead of using a plugin provided styles. For creating custom color box style go to /sites/all/modules/contrib/color box/styles copy any one of the folders. (You can find plain, default, and Stockholm syndrome styles there).Place the copied folder into your theme folder. Rename the folder with your custom name. Also, rename the CSS and js files.
Drupal 8 was released on Nov 19th, 2015. Though Drupal 6 end of life was declared on February 24th, 2016, there are still over 84,845 Drupal 6 websites on the web.
What does end of Life Mean for Drupal 6?
As per Drupal 6 end of life, the security team will no longer provide support or security advisories for Drupal 6 and the core of Drupal 6 will no longer receive community support.
In one of my project I want to create user roles programmatically and the role should be enable and disable while module install and uninstall process. So first of all I need to create a YAML file based on the user role name with necessary definitions. The name of the YAML file should be the format user.role.sample.yml. Here sample is my user role id. To make the role enable and disable while module installation and uninstall we have to add dependency with enforced property.
You might be getting the most from your Drupal 6 website, but with versions 7 and 8 already on full gear, you might hurt your web presence sooner than later.
Drupal 7 And 8 Offerings You Cannot Disregard
It’s time to make a planned move to a more recent Drupal version now. Some of the features that make Drupal 8 move worthwhile include:
Better Content Management Experience
The content management experience is even more flexible and efficient with in place editing and advanced image handling.
To load a node details using its id in Drupal 8 use the following syntax:
$node_details = Node::load($nid);
$node_details->field_FIELD_NAME->value;
I want to programmatically create taxonomy vocabulary and it should be enabled and disabled while the module installs and uninstalls the process. So first of all I have created a YAML file based on the vocabulary name with necessary definitions.
In this article lets see how to import and export translation strings to Drupal site. Drupal uses the .po (portable object) and .pot (portable object template) extensions for the translation files. Difference between .po and .pot files:
To process very large data is very much time-consuming, it may lead to PHP timeout error. To process very large data, Drupal offers a batch API. The Batch API allows you to run one or more operations on a large set of data without timeout and feedback on the progress of the operation.
Advantage of Batch API:
Avoid PHP timeout.
Display the progress of the process.
Avoid out of memory situations.
Let's look a simple example in Drupal 6 that use batch API:
We were asked to provide an estimate for a Joomla client who wanted to know the feasibility of converting their Joomla site to Drupal. Before we provide an estimate it is our practice to review the existing setup of the client. The version of the CMS is what we check first when we do the review. Read on to know how to know the version of Joomla sit without admin access.
Advanced REST Client API is used to test interaction between various levels of software components. Testing is done using the API endpoints validation is performed based on the return value. Response can be Success true or Success false which can be tested by common testing techniques.
Drupal 8's routing system works with the Symfony HTTP Kernel. To do basic route operations, you don't need to learn very much about the Symfony HTTP Kernel.
Routing system in Drupal 8 is introduced by replacing the routing parts of hook_menu() in Drupal 7, and its parts, used for creating tabs, menu entries, contextual links, access arguments and actions are taken over by other sub-systems of YAML files (.yml) that provide metadata about each item and its corresponding PHP classes that serves the underlying logic.
This article covers, how to send email programmatically in your Drupal 8 site. There are two main steps to send an email using Drupal 8. First we need to implement hook_mail() to define email templates and the second step is to use the mail manager to send emails using these templates. Let's see an example for sending an email from the custom module, also the following name spaces.
DrupalCon Dublin is right around the corner, and the preparations are going full steam ahead. DrupalCon is like a Carnival that has come to town for the Drupal developers especially those in Europe. The excitement is rocketing sky high with a thousand and one things to get done before the 26th of September. The conference is to be held at The Convention Centre Dublin, Ireland from 26th September to the 30th September.
In one of my Drupal 8 work I needed to configure SMTP using swiftmailer Module. The module extends the basic mail sending functionality which is provided by Drupal by delegating all mail handling to Swift Mailer library. This library provides features, such as :
This article covers, how to send email programmatically in your Drupal 8 site. There are two main steps to send an email using Drupal 8. First we need to implement hook_mail() to define email templates and the second step is to use the mail manager to send emails using these templates. Let's see an example for sending an email from the custom module, also the following name spaces.
In Drupal 7 we can upgrade a module in many ways but we fail on upgrade feeds excel module. The reason being the newer version of the module is entirely different from the old version folder structure and file naming. We can overcome this situation by uninstalling the older version and installing the new version. Sometimes we cannot uninstall the module due to the module dependency and data lock. We can achieve this manually using the following steps.
In Drupal 8, variable_set() and variable_get() is deprecated. The variables database table in Drupal 7 is now removed in Drupal 8, and is replaced with config table. We can create a variable while installing the module using MODULE.setting.yml and MODULE.schema.yml files.
Drupal has established itself as a solid platform for Educational websites. The fact that all Ivy League colleges have Drupal websites is proof enough of Drupal’s popularity as a great Content Management Framework to build educational websites. Brown University, Columbia University, Cornell University, Dartmouth College, Harvard University, University of Pennsylvania, Princeton University and Yale University are the eight old and distinguished colleges in the north east of US are the highly sought after Ivy League colleges.
Security Audits play a crucial role in an organization’s ongoing effort to address security concerns. After identifying any potential security issues, remedial steps need to adopt; in fact, a Security audit is one of the first steps that need to be taken. No organization in its right mind would want to leave its websites vulnerable to hacking, and conducting a security audit is the best way to tackle security issues.