เพิ่ม Zip package to Drupal using composer (ตัวอย่าง : CKEditor colorbutton as drupal-library)
ตัวอย่างใน composer.json
ตัวอย่างใน composer.json
สำหรับ Global
git config --global user.name "Your global username"
git config --global user.email "[email protected]"
ตรวจสอบค่า config
git config --global --get user.name
git config --global --get user.email
สำหรับ Project
Note
tar -zcvf name-folder-giz.tar.gz folder-name/
Update แบบ fix field นั้นๆ ว่าจะเป็นค่าอะไร
mytheme.libraries.yml:
jquery-custom:
remote: https://github.com/jquery/jquery
version: "2.2.4"
license:
name: MIT
url: https://github.com/jquery/jquery/blob/2.2.4/LICENSE.txt
gpl-compatible: true
js:
js/jquery-2.2.4.min.js: { minified: true, weight: -20 }
mytheme.info.yml:
libraries-override:
# Replace an entire library.
core/jquery: mytheme/jquery-custom
ตัวอย่าง
.center {
height: 200px;
position: relative;
border: 3px solid green;
}
.center p {
margin: 0;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
settings.php
$conf['image_suppress_itok_output'] = TRUE;
$conf['image_allow_insecure_derivatives'] = TRUE;