Create Drupal 8 Custom Page Template

Simply place the following code in the .theme (theme_name.theme) file that is located inside your theme folder. Replace theme_name with the actual name of your Drupal theme.

function theme_name_theme_suggestions_page_alter(array &$suggestions, array $variables) {
// Add content type suggestions.
if ($node = \Drupal::request()->attributes->get('node')) {
array_splice($suggestions, 1, 0, 'page__' . $node->getType());
}
}

Then create a file under the template folder and name it according to your node content type e.g.

page--page.html.twig

Then add your custom code for that particular page.

I’m back …..

Four years ago, I decided to move my blog to a paid domain and hosting and this one took a long hiatus. I then changed my domain from http://thekenyangeek.com to http://brian.co.ke. I guess growing old was coming into effect. LOL.

However, my main site is now taking a hiatus as I think what to write on next (possibly deeper tech., social and engineering stuff). My current site had this kind of content  but I think it was not satisfactory. Recently, I came into my 30s and it has got me to rethink stuff about life. So as I think about what I’ll be writing, I’ll resume posting here. My current site is offline for the moment until I setup an elaborate plan as God guides me.

Happy New Year and a blessed 2017.

Centering on God, not self

The Bible is full of faithful affirmations centering on God, not self. When scripture speaks of self, it usually commends self-denial and self-control and condemns self-worship. Self love is acceptable and encouraged as long as its understood within its proper context (Mathew 22:39; self-regard).

Galatians 6:14: “May I never boast except in the cross of our Lord Jesus Christ, through which the world has been crucified to me, and I to the world.”

1 Corinthians 15:9-10:”For I am the least of the apostles and do not even deserve to be called an apostle, because I persecuted the church of God. But by the grace of God I Read More

Moved….

Its been a great journey using this blog platform to post my thoughts and lessons on my Christian journey. Fortunately or unfortunately, I’ve moved to my self-hosted blog. So future posts related to this blog will appear on thekenyangeek.com where I also share my passion for science, technology and education. That’s a wrap, for this particular blog but still sharing about Christ 🙂

So join me at thekenyangeek.com

Our Foundation, Our Future

Children are the foundation to any society as I had learnt at a Saturday retreat for my church’s children ministry. The future of the society depends on how they are brought up. Instilling values that are godly brings hope to the society but if the children do not learn theses values then the society is doomed.

These days kids are very smart and knowledgeable for their ages. Yesterday, I saw one of the kids (10 years old) I teach using an Android smart phone. I got my first mobile phone at the age of 18. And no, it wasn’t a smart phone. Simple enough to text and call and it had a mono-chromatic screen (no colours). They know so much that you can actually discuss current political issues with them. In fact yesterday I was sharing about the Good Samaritan (Luke 10:25-37) with them and the story basically teaches us that a neighbour is one who’s in need of help and that we shouldn’t discriminate others because they belong to another tribe since here in Kenya, our societal problems stem from tribal issues, nepotism, political party loyalty alignment and Read More

We love complaining….

Habakkuk 1:2-4

How long, Lord, must I call for help,
but you do not listen?
Or cry out to you, “Violence!”
but you do not save?
 Why do you make me look at injustice?
Why do you tolerate wrongdoing?
Destruction and violence are before me;
there is strife, and conflict abounds.
 Therefore the law is paralyzed,
and justice never prevails.
The wicked hem in the righteous,
so that justice is perverted.

Lesson:

We struggle to comprehend God not remembering that He’s sovereign.

Man Night – Rock Church, San Diego

Hi,

Just sharing an interesting sermon I watched today evening, targeting men and how they ought to relate with God. Its by Pastor Miles McPherson of Rock Church, San Diego, USA. It was a blessing to me and I hope it will bless you too. Oh! And a quote that caught my hear, from the sermon 🙂

If God gives you a woman, love her to death.

[youtube=http://youtu.be/V_FxdlosM8k]

The Mindset of Christ

Adapted from Leading Transformation in Africa by Delanyo Adadevoh.

To know the mind of Christ is to know the will of God. The will of God is in constant pace with His nature and character of God and has been revealed to humankind through the person of Jesus Christ.

If anyone is new in Christ, he is a new creature; the old things passed away; behold new things have come. – 2 Corinthians 5:17 (NASB)

Same Script, Different actors; we find ourselves seeing things from the worldly perspective. We have relied for too long on a mindset that is not only godless but has no positive lasting impact. But God sent His Son so that we may know His will for us the lost sheep.

Characteristics of the mind of Christ

The mind of Christ:

  1. Seeks to honour God – John 5:19-20
  2. Is a humble mind – Philippians 2:1-9
  3. Seeks the abundant life – John 10:10
  4. Is a productive time – Mathew 25:14-30
  5. Values the human above the material – Mathew 16:26
  6. Values the eternal above the temporal – Mathew 10:28
  7. Values godliness over external religious performances – Mark 7:20-22
  8. Is spiritual – 1 Corinthians 2:6-16
  9. Loves all without partiality – Luke 10:25-37; John 4:4-26; Mathew 19:14
  10. Is sacrificial – Mathew 20:28
  11. Seeks the salvation of the lost – Luke 19:10
  12. Is a kingdom mind

So, lets all start seeing things in God’s perspective. Its all starts with prayer 🙂