Blog

If you have an old admin account for Google Apps and you can't sign in, try this little trick that just worked for us.

We had a phone number set as our primary verification method, but when we went to sign in, we were getting an error that the system was unable to send us a verification message and that our mobile number was recently...


The upgrade path from Drupal 9 to Drupal 10 depends on the modules and themes you have installed and on the custom ones your team have developed.

Following the official guide of this upgrade will hopefully take you through the process and resolve all the issues you might encounter.

In our case we had a custom built theme started on...


When programming and working with your preferred version control system, Git of course, you might find yourself committing a change with a misspelled or wrong message.

Luckily for us developers, there is a simple Git command to change the most recent local commit which is usually the one you want to modify. Just run the below...


During web development and testing you might need to setup redirections from one domain name or URL to another. Google Chrome will cache those redirects for a long time and if you need to change them you'll need to clear the HTTP 301 redirections first and then setup new ones if still needed.

Below we present three methods you can...


Introduction

During the development and testing phases of a website's frontend, finding and fixing horizontal overflow issues can be challenging.

In some cases, it might be easy via DevTools to find and select the element that is wider than the document is and then fixing its CSS accordingly.

Most times though such elements are...


A responsive logo is one with design elements that adapt slightly depending on the device or screen size on which they are displayed without compromising the brand identity.

Design elements that might be replaced or changed may include icons or symbols, company names and slogans, colors, backgrounds, outlines, and other small...


Introduction

As a web developer, you often set your JavaScript files to open with a text editor instead of being executed. As a result, such files open for code reading and editing do not pose any security threat.

However, the operating system still thinks that JavaScript files are run when double clicked and tries to protect you from...


Introduction

This post is a quick summary of the number of keys found on standard keyboards. I wanted to order some switches for one of my keyboards and a quick Google search didn't reveal much results and as such, for now and for future reference, I'm creating this blog post.

There are plenty of keyboard layouts currently on the...


Deep work is a concept coined by Cal Newport, a renowned author and computer science professor at Georgetown University, in a 2012 blog post and expanded upon in his 2016 bestselling book, Deep Work: Rules for Focused Success in a Distracted World.

By Newport's definition, deep work refers to: "Professional activity performed in a...


The Anne Pro 2 is a wireless sixty percent mechanical keyboard also known as poker size keyboard. It's a tiny keyboard and it might not be for you especially if you need dedicated arrow keys or nav cluster keys like page up and page down.

As Tae Keyboards puts it, this is a 60% keyboard, having just the main area of the keyboard,...


The HyperX Alloy FPS Pro is a high quality tenkeyless or TKL mechanical keyboard. As such, it's a keyboard that's missing the standard numeric keypad or numpad. If you're not an accountant, you basically rarely use the numpad anyways and this keyboard will be a great fit.

We use it for day to day programming work since mechanical...


What is DPI

DPI stands for dots per inch and is also sometimes called PPI which stands for pixels per inch. Technically, DPI is for printing whereas PPI is for screens but in our context they are both used and just mean the same thing.

So basically, you just need to measure how many pixels your cursor moves when you move your mouse an...


Introduction

Neil deGrasse Tyson is my favorite scientist for a multitude of reasons. He's capable of presenting high level concepts and ideas in their simplest of forms. A rare combination of a brilliant scientist and a sensitive educator.

I'll keep this post as short as possible and present a couple of concepts showing why he's my...


Introduction

Custom website theme development in Drupal 7 is, basically, where you define how each element and part of the website will look to the end user. This is done via manipulating theme files and writing our own custom web theming code in HTML, CSS, and JavaScript.

Luckily for us, Drupal is a well organized framework and...


What is Reddit

Reddit is an online community site with more than a million sub communities known as subreddits each covering a different topic.

You can browse sub reddits by visiting the reddit homepage for the top most news or going to, for example, /r/boardgames which is a subreddit for people to discuss board games.

You can also...


Specifications

One or two 16m2 rooms available in a shared 150m2 office in a strategic location at the intersection of Slaf Street and Hayek highway at Dekwaneh.

One of the rooms also contains a wall closet of about 2m2.

Shared Balcony space of 22m2 with an open view, 13m2 kitchen with its balcony, and 2 bathrooms and a hallway are...


This is a little tip to help programmers and system admins shave off a few milliseconds from their daily command line interface workflow. For the uninitiated, please note that some programmers, including yours truly, have been reported to spend hours or even days trying to automate a repetitive task that takes 5 seconds to execute....


Google is getting smarter and smarter everyday. Not only it's the main search engine almost universally, it's also becoming a go to tool for live smart computations and unit conversions. Basically, you can think of Google as a search engine and also a smart question answer tool.


Introduction

If you want to declare an array as a constant in PHP, you need to look further than what PHP provides as standard. Technically, if you look at PHP's Constants Syntax, it's not possible to define an array as constant, except from PHP 5.6 onwards. As of this writing, PHP 5.6 is still not widely available, and hence here's...


Introduction

Source code management, also known as code version control, source control, and revision control, is essential to say the least. For programming, it was and it always will be even more than essential. For other types of documents, it is becoming more and more essential and we are seeing business managers and graphic...


Introduction

In a previous blog post, we explained what hierarchical paths are, gave examples, and solved a problem with the pathauto module of Drupal 7 that caused certain links to contain a buggy "front" slug.

In this blog post, we will go deeper into all the issues that come with implementing a proper URL paths hierarchy in Drupal...


Generating hierarchical paths in Drupal 7 based on the pathauto module is not an easy task. First, in a nutshell, hierarchical paths are ones that follow a certain hierarchy, a tree structure, or even called multi level or multi depth. For example...


Introduction

As soon as you start developing reliable websites in Drupal 7, the need to create custom modules arises. There will be plenty of situations where you need to create custom hooks to handle certain business requirements for your Drupal website; and those hooks have to live inside a custom module. For example, check our...


Preventing your Drupal 7 website editors from deleting content, under certain conditions, is not that difficult if you know the proper Drupal hooks to use. However, finding those hooks isn't easy and we're sharing this blog post with you in the hope that it will save you a few programming headaches...


If you're looking for a well written and tested function to recursively retrieve all child menu items in Drupal 7, you've come to the right place. All you have to do is pass it a valid node path such as 'node/123'.

The terminology you use might differ. You might call them sub menu links, deeper level menu links, sub nodes, or links...


The time() function in PHP returns the current Unix timestamp; which is the time measured in the number of seconds since the Unix Epoch. Very useful in certain cases, but not always. This function, like most other PHP functions, is also cross platform compatible as it works on Unix, Linux, Windows, and Mac.

PHP's microtime()...


Open source is the future and is a main driver for development on many levels including but not limited to technical, social, and economic development. In our part of the world, we're not playing an important role in open source, we're not benefiting from it to the maximum, and Arabized features are still lacking in many areas. My lightning talk will hopefully persuade developers to take action, contribute more and more to open source, and assist in taking the whole ecosystem to the next level.

 


Securing Zend Framework

If you have a PHP web application built using the Zend Framework, securing all its pages becomes very easy. You just go ahead and add the following tiny function to your Bootstrap file:

[CODE]

What this does is that it captures any non-secure request (Over plain HTTP) and redirects it to HTTPS (HTTP Secure). As...


Introduction

Generating ANSI (or ASCII) command line colors, or terminal colors, or whatever you call them, is easy with PHP. As I have said in my previous post, ANSI Command Line Colors under Windows, having colored text in the command line is a great help for spotting error or success messages. So here’s a quick and dirty function...


Steps

Having colored text in the command line is a great help for spotting error or success messages. Unfortunately, those of us developing under Windows do not have this feature by default. Here’s how to enable it.

  1. Download ANSICON from: https://github.com/adoxa/ansicon
  2. Extract the proper files (Depending on if you have a 32 or...

Why change the default Look and Feel?

Aesthetics apart, every developer should change the default Look and Feel of NetBeans. Why? because it has an annoying bug. Here’s what happens: you’re pumping code in the NetBeans code editor like crazy. You need to switch to another window for a quick copy / paste from your eternal library...


Introduction

Zend Framework is currently one of the best MVC-based frameworks in the PHP world. Zend_Mail is part of Zend Framework and it provides the ability to easily send email messages. If you’re like me, most web applications you have developed are setup to use Google Apps as their email provider. Here’s how to send email...


Introduction

You are programming in PHP and you have an array variable that you'd like to explore at different execution paths. Of course, the best way is to use a PHP debugger like xdebug or Zend Debugger, but, what happens when you're too lazy to install a debugger? What happens when you don't want or can't install a debugger and...


Hide Gmail's Spam Count
December 06, 2010

An Introduction and a Rant

Does the spam count in Gmail bother you? It certainly does.

Are you too lazy to delete your spam messages every few minutes? Of course you are.

Would you like to preserve your spam messages just in case they might contain a legitimate email? Of course you would love to.

You hate using third party tools such...


What is URL Rewriting?

URL rewriting provides shorter and more relevant-looking links to web pages on your site. This improves the readability and the search rankings of your URLs. For example, URL "a" can be rewritten as URL "b".

[CODE]

There are many articles on the web discussing the benefits of shorter and more relevant URLs. Let...


Hello World!
August 02, 2010

We are Online!

The ubiquitous Hello World post is here to stay. For the sake of programming traditions, we're not removing it. But we do promise that our next posts will be more useful.

Below is a list of Hello World program examples in our favorite programming languages. Consult Wikipedia's Hello world program page if you're...