developer resources
Codebales holds an ever growing number of solutions to problems that we have experienced in our day to day code writing
Selected filter
152
results
Andrew Fletcher
•
Loading the node
To query the node, I prefer to create a series of functions to mange the process in a class. However, keeping this simple, this can be achieved through:
$node = \Drupal\node\Entity\Node::load($nid);Otherwise if you require to load multiple nodes, where the list of node.nids is in an array.
$nodes = \Drupal::entityTypeManager()->getStorage('node');
$this->list = $nodes->loadMultiple($this->nids);
Whereas, if you are looking to query the node database for...
Andrew Fletcher
•
If you are like me you probably have searched for clues to and found little......
Andrew Fletcher
•
Registering a user via REST is an important process particularly when the...
Andrew Fletcher
•
As a process I apply patches locally first, then using git upload the update(s)...
Andrew Fletcher
•
While the Drupal site has a great outline of the steps to follow, I found we...
Andrew Fletcher
•
First transfer the drupal-8.8.x.tar.gz file to your directory
Via your ssh program (for us Terminal on OSX), enter the path to the directory where you transferred the drupal-8.8.x file
gunzip -c drupal-8.8.0.tar.gz | tar xopf -
rm -rf /var/www/vhosts/example.com/subdir/drupal-8.8.0.tar.gz
rm -rf /var/www/vhosts/example.com/subdir/core
; rm -rf /var/www/vhosts/example.com/subdir/modules
; rm -rf /var/www/vhosts/example.com/subdir/profiles
; rm -rf...
Andrew Fletcher
•
Whatever you are coding - code clarity is your goal.
Before you scream and...
Andrew Fletcher
•
To create a .pem file, is quick once you have your .p12 certificate. I...
Andrew Fletcher
•
I had the issue where I needed to filter an array list by a specific column....
Andrew Fletcher
•
A handy resource list of fonts for iOS:
iOS Font List -...
Andrew Fletcher
•
https://github.com/kylebrowning/waterwheel.swift
After a short amount searching I came across Kyle Browning Waterwheel Pod. I flipped down to installation and there it is in three steps. Super. But wait. Step one, CocoaPods. What are pods?
https://cocoapods.org/
Easy to follow, in no time cocoapods are added.
Using terminal you need to initialise the pod to the directory where the Xcode project is located.
cd ~/Path/To/Your/Project/
pod init pod update
This...
Andrew Fletcher
•
Ha you have read it before, one of those throw away lines that is written "just...
Andrew Fletcher
•
After coding for 16 years... I have decided to have a go at building apps in...
Andrew Fletcher
•
While I have posted an article about how to POST an image using REST in Drupal...
Andrew Fletcher
•
In Drupal 8.x hiding the subject line is a quick task.
In the admin area of your...