Drupal
more_horiz
close

on 03rd August 2017 / by emily.mathew
Drupal is a scalable and secure content management framework which help organizations build their digital platforms. In this article I am presenting a situation where Drupal helped implement a feature for one of our client, without affecting the site's scalability and secure nature. The client’s site went down to maintenance mode for some users unexpectedly. This happens very rarely and there was no immediate visible reason that could point to the cause of it. So it was imperative that we log when the site goes offline in order to debug the issue. A simple and fast solution would have been to hack the core by adding a line of code that logs the back trace at the time when the site goes offline. But hacking the core leaves us open to security vulnerabilities and may have unintended consequences affecting other contributed modules and make it difficult to update. So it is always a good practice to use Drupal’s high value opportunities for customization, instead of hacking core. Drupal, as a powerful content management framework gives us the flexibility to do almost any kind of customization by using custom modules and themes without hacking core. So here we overrode the maintenance page theme in our custom theme to include the back trace log function to find and fix the root cause. Do you know other reasons why core should not be hacked. Or why is it difficult to update when core is hacked? Share your comments... Drupal Leave a reply Your email address will not be published. Required fields are marker * Deepa N (not verified) access_time 22 Apr 2019 - 03:40 This is a good article. I would like to explain a bit more about how it makes difficult to update when the module/core when hacked? I have seen that, people do hacking not just for fixing or debugging issues but for implementing some features as well. If we are not careful enough, the feature code will be lost while updating the contributed module/core automatically as the code will be replaced which will lead to non-functioning of those features or causing errors. If we know that there are some hacks/patches applied in the module/core then we need to manually make the changes them without affecting the feature code. This will make the updating difficult and time-consuming. The hacks can go cumulative if the developer is not putting a conscious effort to follow the standards (not hacking core is a Drupal standard). Over a period the code becomes messy and non-manageable. Also, we need to keep proper documentation about the patches applied in each module or core. Otherwise this will result in a vendor lock-in. Since, a new vendor is unable to understand these hacks easily and even a minor update made to the module can break the site. So, it is always better to follow Drupal standards. Hope this helps! Add new comment
more_horiz
close

on 11th July 2017 / by webmaster
Many Drupal users wanted to know if there was a functionality similar to UberCart test_gateway for Drupal Commerce for emulating the collection of credit cards. If you are faced with the same question while running Drupal Commerce on your Drupal site then read on to know the possible solutions. The Drupal Commerce Kickstart module has the Commerce Kickstart Payment Example which provides exactly the same functionality. You can simply obtain it from the Commerce Kickstart repository and you are good to go. Hope that helps. The easiest way to solve a Drupal issue is to hand it to the Drupal experts. We can provide a wide range of Drupal services to help you maintain and manage your Drupal websites. Get in touch with us to know more. Reference: http://drupal.org/node/1781508 Drupal Drupal 7 Drupal Issues Drupal Commerce Kickstart Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 12th April 2017 / by webmaster
We had earlier published a list of Fortune 500 companies and their websites. We evaluated these websites and have identified those that run on Drupal. The following is the list of Fortune 500 companies from 2014 that use Drupal for their corporate websites. Do note that this data is for the list of fortune 500 companies for year 2014. The current list of fortune 500 companies using Drupal is also available. Fortune 500 Ranking Company Website 9 General Electric www.ge.com 12 CVS Caremark info.cvscaremark.com 39 Johnson & Johnson www.jnj.com 51 Pfizer www.pfizer.com 71 World Fuel Services Corporation www.wfscorp.com 102 Time Warner Inc. www.timewarner.com 120 Qualcomm Incorporated www.qualcomm.com 148 PBF Energy Inc. www,pbfenergy.com 149 Danaher Corporation www.danaher.com 165 TRW Automotive Holdings Corp. www.trw.com 180 eBay Inc. www.ebayinc.com 218 Whole Foods Market, Inc. www.wholefoodsmarket.com 255 Stanley Black & Decker, Inc. www.stanleyblackanddecker.com 288 KKR & Co. L.P. www.kkr.com 313 Crown Holdings, Inc. www.crowncork.com 327 Newmont Mining Corporation www.newmont.com 346 Core-Mark Holding Company, Inc. www.core-mark.com 350 Applied Materials, Inc. www.appliedmaterials.com 356 Jarden Corporation www.jarden.com 389 Casey's General Stores, Inc. www.caseys.com 403 Mattel, Inc. www.mattel.com 442 Leidos Holdings Inc. www.leidos.com 494 Wyndham Worldwide Corporation www.wyndhamworldwide.com The complete list of fortune 500 companies and their websites is available as a google document at http://bit.ly/1kkTv2A Drupal Lists Marketing Drupal Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 30th December 2016 / by akhila.vn
In one of my work, I want to programmatically uncheck the checkbox option of 'Generate automatic url alias' for a specific node editing form. For this, I have created the following form alter for the content type. I have added a custom after build function for the necessary content type in the form alter. /** * Implements hook_form_alter(). */ function MYMODULE_form_alter(&$form, &$form_state, $form_id) { if (isset($form['#node_edit_form']) && $form['#node_edit_form'] == TRUE && $form['type']['#value'] == 'MYCONTENTTYPE_MACHINENAME') { $form['#after_build'][] = 'MYMODULE_node_after_build'; } } /** * Custom node form after build function. */ function MYMODULE_node_after_build($form, &$form_state) { // Unchecks the checkbox for Generate automatic URL alias, if path exists. if (isset($form['path']['pathauto']) && $form['path']['pid']['#value']) { $form['path']['pathauto']['#checked'] = FALSE; } return $form; }Hope this tip helps for any of your specific node editing form for handling the url alias, if the path is already created without affecting other nodes and configurations. Drupal Drupal 7 Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 19th December 2016 / by dhanya.girish
Commerce gift card module is used for creating Gift card Product types and sell it through the site. This module works with the Drupal commerce module. The module automatically create a Product of type Gift card and enables the site admin to sell those Gift cards via the site. This Gift card can be used by the customer itself or can be gifted to any others. There is an option to send the Gift card by email. Each Gift coupon will contains a coupon code associated with them and this code can be used for future product purchases through that site. The discount associated with that coupon code will be applied to the purchase made. Users will have the option to view their Git coupon balance also. A major issue I faced while installing this module is its dependency with the Commerce coupon user module, which is a sub-module of commerce coupon module. This sub-module is not available with recommended release (7.x-1.0-beta7) of Commerce coupon module. That sub-module is available with the 7.x-2.0-rc2 release of the commerce coupon module. So if our existing system uses the commerce coupon 7.x-1.0-beta7 release, we need to upgrade it to the new release, apply the patches (if there is any) and then enable the commerce gift coupon module. If you need any further assistance, please feel free to get in touch with us. Drupal Drupal 7 Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 07th December 2016 / by deepak.r
Docker is an open source platform for system administrators and developers to build, ship and to run distributed applications, whether its on the cloud, data center VMs, or on the laptops. Docker helps to automate the deployment of Linux applications inside software containers. Docker4Drupal (A native docker-based local environment for Drupal) is an open source initiative by Wodby to setup Drupal local environments. Docker4Drupal is supported for both Drupal 7 and Drupal 8 versions. This write up helps you to set up a local Drupal environment in seconds. You have to install the Docker for Linux to start with. For Linux platform, you have to additionally install Docker Compose. You can install the docker-compose by the following command in your Ubuntu terminal. $ pip install docker-composeClone the Docker4Drupal to your local machine by running the following command in your Ubuntu terminal or alternatively download the package. $ git clone https://github.com/Wodby/docker4drupal.gitUsing the Docker compose file (docker-compose.yml) we can set up local environment for Drupal using a native Docker app on Linux, Mac OS X and Windows as well. Before running the compose file, you have to update the configurations to meet your needs. You can also have a look at the available containers in the Drupal bundle. Place the Docker compose file in your Drupal Webroot. Navigate to the Drupal webroot in terminal and run the compose file using the following command. $ docker-compose up -dYou will be able to access the Drupal site at http://localhost:8000, phpMyAdmin at http://localhost:8001, Mailhog at http://localhost:8002, Apache solr at http://localhost:8003 and Memcache Admin at http://localhost:8006/index.php by default (If you have not customized the port numbers in compose file). Accessing containers You can connect to any container in the Drupal bundle by executing the following command. Replace SERVICE with the name of the service (e.g. php, mariadb, nginx, etc). $ docker-compose exec SERVICE shHope this helps! Please feel free to get in touch with us if you need any further assistance. Drupal Docker Ubuntu Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 07th December 2016 / by alfred.paul
OpenMeeting is an open source and independent alternative for Google Hangouts. It allows video/audio conference, collaborative editing, screen sharing, instant messaging etc. OpenMeeting community provides plugins for integrating to common platforms like moodle, Sakai, Jira, Joomla, Bitrix, Confluence, SugraCRM, Redmine. Unfortunately, the Drupal plugin for openmeeting is not opensource. A good news is, OpenMeeting provides a SOAP API for integrating OpenMeeting with other platforms. I will explain how to create a new conference via OpenMeeting's SOAP API. First, the user need to retrieve session ID for doing particular actions to be done using SOAP API. This can be retrieved by making a call tohttp://[host]:[port]/openmeetings/services/UserService/getSession Return will be an XML. We need to parse session ID from the XML. Then login using admin credential. For that, we can make call to http://localhost:5080/openmeetings/services/UserService/loginUser?SID=VALUE&username=VALUE&userpass=VALUESID is the value we retrieved in the first request. To create a new conference, we can make use of the API gateway method addRoomWithModerationQuestionsAndAudioType. For example, http://localhost:5080/openmeetings/services/RoomService/addRoomWithModerationQuestionsAndAudioType?SID=VALUE&name=VALUE&roomtypes_id=VALUE&comment=VALUE&numberOfPartizipants=VALUE&ispublic=VALUE&appointment=VALUE&isDemoRoom=VALUE&demoTime=VALUE&isModeratedRoom=VALUE&allowUserQuestions=VALUE&isAudioOnly=VALUE SID = The SID of the User. This SID must be marked as Loggedin name = Name of the Room roomtypes_id = Type of that room (1 = Conference, 2 = Audience, 3 = Restricted, 4 = Interview) comment = any comment numberOfPartizipants = the maximum users allowed in this room ispublic = If this room is public (use true if you don't deal with different Organizations) [boolean] appointment = is it a Calendar Room (use false by default) isDemoRoom = is it a Demo Room with limited time (use false by default) demoTime = time in seconds after the user will be logged out (only enabled if isDemoRoom is true) isModeratedRoom = Users have to wait until a Moderator arrives. Use the becomeModerator param in setUserObjectAndGenerateRoomHash to set a user as default Moderator allowUserQuestions = enable or disable the button to allow users to apply for moderation isAudioOnly = enable or disable the video / or audio-only Detailed documentation is given in the link: http://openmeetings.apache.org/openmeetings-webservice/apidocs/index.ht… Hope this helps. Please feel free to get in touch with us if you have any further queries. Drupal API Ubuntu Apache Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 05th December 2016 / by deepak.r
Everyone knows Drush is a very important tool in Drupal development, to execute things faster and to manage Drupal websites remotely. Drupal specifically built its shell function to update its configurations, managing modules, running drupal updates, etc. For Drupal 8 older versions of Drush will not work as part of changes that Drupal 8 put forward. If you want to setup the latest version of Drush, you can follow these steps to ensure that latest version of Drush has been installed and which is compatible for Drupal 8. Else, you can update Drush using composer. Open a terminal window and type: cd ~/ Download the latest version of Drush: php -r "readfile('http://files.drush.org/drush.phar');" > drush Make the newly downloaded version executable: sudo chmod +x ~/drush Depending on the setup, You may need to find current install path of Drush by typing: which drush It will return something like '/usr/bin/local', which can be different depending on the package manager in the system Create a backup for current Drush installation: sudo cp /yourpath/to/install/drush /yourpath/to/install/drush_older Delete the older version from your install path ('/usr/bin/local'): sudo rm /yourpath/to/install/drush Move the newly downloaded version to the install path: sudo mv ~/drush /yourpath/to/install/drush Initialize the newest version of Drush: /yourpath/to/install/drush init Navigate to the Drupal 8 root in terminal and simply type 'drush'. If everything is fine, a list of commands will be available for you. By following this, you can ensure that Drush has been updated to the latest version, preserving the older copy of installation, which can be used to switch between Drush versions later. Hope this helps! Drupal Drupal 8 Drush Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 02nd December 2016 / by dhanyamol.kv
When I planned to use media upload in CKeditor for uploading files to the site, I faced one problem, i.e. I could use only predefined image style as preset to style my image. I wanted to use a custom preset to media upload. To achieve that we have to do some customization. Add following custom code in our custom module. /** * Function to add custom preset. * */ function custom_entity_info_alter(&$entity_info) { // Support the media module, Here Medium and Full width - 1300*810 are custom preset. $entity_info['file']['view modes']['media_medium'] = array('label' => t('Medium'), 'custom settings' => TRUE); $entity_info['file']['view modes']['media_full_width'] = array('label' => t('Full width - 1300*810'), 'custom settings' => TRUE); } Create new image styles and then edit the media file display: admin/config/media/file-types/manage/image/file-display to assign new image styles for custom presets. Hope this helps! Please feel free to get in touch with us if any queries. Drupal Drupal 7 CKEditor Leave a reply Your email address will not be published. Required fields are marker *
more_horiz
close

on 01st December 2016 / by deepak.r
While setting up local environments for Drupal 8, everyone may find difficulty in login to the site, if the password is unknown In Drupal core there is a script file that return the hashed password, which is core/scripts/password-hash.sh. Run the following command to get the hashed string for '123' in terminal. ./core/scripts/password-hash.sh 123Update the returned string in the password field in the users table for required users via command line or any MySQL (or any database systems like PostgreSQL, MariaDB, MongoDB) GUI tools. Hope this helps! Please feel free to get in touch with us if any queries. Drupal Drupal 8 Leave a reply Your email address will not be published. Required fields are marker *