Postingan

Menampilkan postingan dari 2020

Cara Update Drupal Core dengan Drush

To upgrade Drupal core (say for a new security release) while running Aegir stable, this method should work, but make sure to test on a development instance before running on your production environment: 1. Become the Aegir user.     * sudo -Hsu aegir 2. Upgrade Drupal core.     * drush @hostmaster pm-updatecode drupal 3. Verify the upgraded platform.     * drush @platform_hostmaster provision-verify 4. Verify the Hostmaster site.     * drush @hostmaster provision-verify

Views konten sesuai kategori user dan konten

  Here is a slightly different approach: * Create a  user  view. * Add a contextual filter on user: uid. If no filter value is present, build a default value using the currently logged in user. (This will give you exactly one user object in your view -- the logged in user.) * Add a relationship, using the relevant taxonomy reference field on the user accounts. This will bring you information about the "interest" term for the logged in user. * Add another relationship, called "term: nodes marked with term" (or something like that). This will bring you information about all nodes marked with the interest term for the logged in user. * Either set the view to display node teasers, or select a number of fields to display. * Add a display as usual. Done! Two things to note: 1) I haven't actually done this myself, so I *might* be missing something. It should work, though. 2) "Contextual filters" are called "arguments" in previous versions of Views. ...

Menampilkan User and Flagged content

Gambar
  order by                             active                           oldest                           votes                       Up vote 0 Down vote I had the same issue where I wanted to show the title of the content flagged with a certain flag by each user. I solved it as follows: Created 2 views - 1 of users and another of content In the user view, add 'Flags: User's flaggings' relationship ( Refer attachment user_view ) In the content view, add 'Flags: Node flag' relationship and 'Flags: User uid' contextual filter ( Refer attachment content_view ) Select 'Display contents of "No results found"' for 'WHEN THE FILTER VALUE IS NOT IN THE URL' in the co...

Menampilkan author name pada views drupal

Pada tab 'Relationships' di 'Advanced' options and click 'add' Select the option 'Content: Author' and apply Now when you go to add fields you will notice several new fields, including 'User: Name' When configuring 'User: Name' make sure that the relationship field matches what was set as the identifier under the 'Relationship'. If you have only one relationship set then it should be selected automatically.

Cara menambahkan user dengan akses root dan copy ssh key root

Di debian 10 1. #adduser masmalik 2. #usermod -aG sudo masmalik 3. #mkdir /home/masmalik/.ssh 4. #touch /home/masmalik/.ssh/authorized_keys 5. #cat /root/.ssh/authorized_keys > /home/masmalik/.ssh/authorized_keys 4. #chown -R masmalik:masmalik /home/masmalik/ 5. #chown root:root /home/masmalik 6. #chmod 700 /home/masmalik/.ssh 7. #chmod 644 /home/masmalik/.ssh/authorized_keys

Urutan setup upload project ke github

    1  git config --global user.name "nama_akun_git_kamu"     4  git config --global user.email email_git_kamu@xyz.com     5  git list     6  git config list     7  git config --list Pada direktori kerja setelah git Bash Here     8  git init     9  git add *    10  git commit -m "nama_repo_kamu"    11  git remote add origin https://github.com/xxxxx/nama_repo_kamu.git    12  git pull origin master    13  git push origin master Tambahan aja ini :D    16  history | grep "git " > setup_git_dariawal    17  history | grep "git " > setup_git_dariawal.txt

Cara mengatasi error: Warning: Use of undefined constant _ - assumed '_' (this will throw an Error in a future version of PHP)

Gambar
Error tersebut terjadi karena tidak adanya tanda petik (') yang mengapit kode, misalnya saya menemukan error tersebut di drupal 7 ketika dijalankan dengan php 7.3. Pada modul book terjadi error seperti judul diatas, dan solusinya adalah dengan menambahkan tanda petik yang mengapit kata article yang saya buat menjadi 'article'.

Perintah instalasi Drupal 9 dengan Composer

Gambar
Untuk melakukan instalasi drupal 9 melalui composer, dapat dilakukan dengan perintah C:\apache2\htdoc> composer create-project --prefer-dist --no-dev drupal/drupal drup9