Drupal Blog

User login

Why Drupal Commerce?

Drupal Commerce is a collection of modules that lets you expand into the world of selling online. It uses the strength of other modules such as Views and Rules, and it provides a flexible framework which can be used to build complicated business solutions.

Drupal Commerce provides a truly flexible, solid foundation for building even very complex business applications. Some of the reasons it stands out as an excellent and secure solution are the following:

Shopify social media code snippet

      {%- assign social_accounts = 'facebook, twitter, pinterest, instagram, snapchat, tumblr, youtube, vimeo, linkedin,' | split: ', ' -%}
      <div class="social-sharing d-flex align-items-center">
            {% include 'social-links' %}
            
        {% for social in social_accounts %}
          {%- assign social_handle = social | handleize -%}
          {% capture social_link %}social_{{ social_handle }}_link{% endcapture %}

Example of using this with a date field from a node in order to get it to format the date in the correct timezone

use Drupal\Core\Datetime\DrupalDateTime;

$date = new DrupalDateTime($mynode->field_my_date_field->value, 'UTC');
$formatted_date = \Drupal::service('date.formatter')->format($date->getTimestamp(), 'custom', 'F j, Y h:ia');

blog:

Drupal Commerce

Drupal Commerce provides a truly flexible, solid foundation for building even very complex business applications. Some of the reasons it stands out as an excellent and secure solution are the following:

Create a new administrator account in drupal with drush

In otder to create a new user in your website using drush, you'll need to run the following commands:

$ drush user-create YourUsername --mail="your@mail.com" --password="YourPassword"

This will create a new user in the website.

In order to assign the role administrator to the user run:

$ drush user-add-role "administrator" YourUsername

Pages

Subscribe to Drupal Blog