Author Archives: ibasit

google cloud run 503 “service unavailable”

Recently I have been deploying PHP service on a google cloud run and I have encountered a 503 service unavailable error.   Problem On the first execution, there is a 503 error, however, any other request after the first one works fine.   Solution After investigation, I have seen that if you are using an […]

Sonata Admin Bundle nested list or has child list

Post (parent) to display comments (child) list. Creating list of rows on sonata admin bundle is fairly easily with there documentation. But when you want to go bit advance on creating sub list of parent entity, then you would be scratching your head.  Luckily this post will help you overcome this very easily. Assuming you already have PostAdmin and […]

Angular2 ngFor skip first index

Simply use angular2 pipe slice by appending at the end of array. <li *ngFor=”#user of users | slice:1″> {{ user.name }} is {{ user.age }} years old. </li>

Symfony 3 should I upgrade or stay with Symfony 2

Everyone is excited about Symfony 3, including myself 🙂 Symfony 3 or Symfony 2? Symfony 2.8 is exactly same as Symfony 3. But wait, then what’s the difference? Symfony 3 mostly have new directory structure for logs, cache and console. Also all the previous deprecated functions are removed. Should I upgrade then, if its same? […]

Symfony3 Auto Wiring – Auto Creating Dependency Services

Previously if you ever had dependency for your object, you had to make sure the names for dependency services are correctly passed down to your new service before you can start using it. Since Symfony 2.8 which is official exact version of Symfony 3 (removing all the deprecated functions). Now you can create services without […]

Change input name of the form fields in Symfony3

Remove form type name from the form Sometimes we need to integrate third party application or form, which requires us to remove any array type form names.  Problem Normal form will create FormTypeName[fieldName] <input type=”text” value=”” name=”formTypeName[fieldName]”> Our final outcome should look like field name only without any form type name. <input type=”text” value=”” name=”fieldName”> […]

Symfony3 Container Dependency Injection

It’s 2016, you can use trait which will help you extend same class with multiple libraries. I keep seeing container class get extended into another class, which then extends to another, before you know it you have extended 5 different classes just to use libraries. What if you can include 5 different libraries into 1 object without extending? […]

Quick Setup Mailgun with CloudFlare + Gmail

Mailgun Setup Create a Mailgun account Add your domain name (no www)domain.com Keep the page open and open a new tab to CloudFlare Cloudflare Choose your site and select DNS Settings Add the two Text records Add the CNAME record Make sure the cloudflare cloud is gray and not orange/active Add the two MX records […]

Setup Environment UAT + LIVE – GITHUB (Auto Deploy)

We will cover UAT and Live environments and exclude developer environment. DEV environment for developer to code and test, before he push his commits to remote repository (github.com),  which will be auto deploy to UAT environment for everyone to test with other developers changes. Note – we wont be covering DEV environment. UAT environment for […]

WordPress FIX HTML parsing issue – for Developers

It’s really annoying and waste loads of hours trying to fix how can one show example of php code, while still use visual editor for quick snapshots or fancy tools of tinyMCE and able to show color coding examples using google prettify.

Back to top