This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * @file | |
| * The PHP page that serves all page requests on a Drupal installation. | |
| * | |
| * All Drupal code is released under the GNU General Public License. | |
| * See COPYRIGHT.txt and LICENSE.txt files in the "core" directory. | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <title>Site en Maintenance</title> | |
| <style> | |
| body { | |
| text-align: center; | |
| padding: 200px; | |
| background-color: #f7f7f7 | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(document).on('ready', function() { | |
| $(".lazy").slick({ | |
| arrows: true, | |
| dots: true, | |
| slidesToShow: 1, | |
| slidesToScroll: 1, | |
| infinite: true, | |
| autoplay: true, | |
| autoplaySpeed: 2000, | |
| lazyLoad: 'ondemand', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const arr1 = ['JAN', 'FEB', 'MAR', 'APR', 'MAY']; | |
| let arr2; | |
| (function() { | |
| "use strict"; | |
| arr2 = [...arr1]; // change this line | |
| })(); | |
| console.log(arr2); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* Vars */ | |
| /* Fonts Sizes */ | |
| $base-font-size : 16px; | |
| /** | |
| * Raw colors | |
| */ | |
| $c-black : #000; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** Implement Hook_drush_command **/ | |
| function module_name_all_export_drush_command() { | |
| $items = array(); | |
| $items['krug-export-all-user'] = array( | |
| 'description' => "Export Krug User", | |
| 'aliases' => array(), | |
| 'callback' => 'userExportByDrush', | |
| ); | |
| return $items; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function UserWithTokenExport(){ | |
| $query = db_select('users','u'); | |
| $query->leftjoin('field_data_field_civility', 'user_civility', 'u.uid = user_civility.entity_id'); | |
| $query->leftjoin('field_data_field_first_name', 'first_name', 'u.uid = first_name.entity_id'); | |
| $query->leftjoin('field_data_field_last_name', 'last_name', 'u.uid = last_name.entity_id'); | |
| $query->leftjoin('field_data_field_date_of_birth', 'date_of_birth', 'u.uid = date_of_birth.entity_id'); | |
| $query->leftjoin('field_data_field_mobile_phone', 'mobile_phone', 'u.uid = mobile_phone.entity_id'); | |
| $query->leftjoin('field_data_field_user_address', 'user_address', 'u.uid = user_address.entity_id'); | |
| $query->leftjoin('field_data_field_zip_code', 'zip_code', 'u.uid = zip_code.entity_id'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| Redirection if 404 | |
| (Page|to|type) | |
| Ex : | |
| node/1234|front|301 | |
| node/1234|node/321|302 | |
| **/ | |
| function redirectNode404ToAnotherPage(){ | |
| $dataList = array(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** Function OGTAG **/ | |
| function classic_ogtag ($title,$description,$image){ | |
| $html_head_title = array( | |
| /*'meta_title' => array( | |
| '#tag' => 'title', | |
| '#value' => !empty($title) ? $title." | Krug" : "Krug Stories | Krug", | |
| ),*/ | |
| 'meta_fb_api_id' => array( | |
| '#tag' => 'meta', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** Check if it's an Object **/ | |
| function checkIsObject($object,$method_name ){ | |
| if(isset($object)){ | |
| if(is_object($object)){ | |
| $methodeExiste = method_exists($object,$method_name); | |
| if($methodeExiste){ | |
| return true; | |
| }else{ | |
| return false; |