Symfony: find all default global variables in twig

Twig ships with some default global variables that you can use. Where does this variables come from?

app/console twig:debug

You will see a Globals section. Take the ‘app’ variable for example, you can find all the variables available in that file. That is why {{ app.user }} works. To see all the variables in app.user, {{ dump(app.user) }}

Useful tools in chrome

chrome can be a really cool tool, not just a browser. Some cools extensions are: qsnap – for capturing and annotating screenshots. markdown viewer – for viewing markdown and auto refreshing if there are changes.

Install drush in cpanel

* you will need root access to the server If composer fails, it is most likely you dont have some extensions. If using cpanel, If all is working “drush core-status” should be working

Cleaning up git history with git rebase

Git rebase is good when you want to combine some historical commits into one commit. This might be a good idea because your history contains too many unncessary test commits, or if you want to cut down the size of your git objects. On the other hand, changing history can be a dangerous thing, it … Continue reading

bursa escort bayan

Selam ben Yildirim escort Ayse Butun yorgunlugunuzu alip siradan hayatinizi canlandiracak zihninizi butunescort bursa bayanlari escort mugla bayan tekirdag escort ilanlari olumsuzluklardan arindirip hayati size daha pozitif ve olumlu yasatacak buyulu bir elin sizi bu karanlik dunyadan kurtaracagi ani hala bekliyorsaniz buna artik son vermenizin zamani geldi hemen simdi beni arayarak monoton yasantiniza bir geceligine … Continue reading

Simple way to redirect user if Mobile

Javascript can detect screen size and redirect users if they are using mobile. I’ve found that checking the screen size and redirecting users based on that can cover 99% of the use cases rather than injecting some complicated browser detection javascript libraries. The screen width of IPAD is 768px and screen width of a bigger … Continue reading

The most time consuming part of software development process

People seem to think that the most time consuming and tedious part of developing a software is the coding of the software. This is wrong. The most tedious process is to get the right requirements for the project. Good business requirements without loopholes give good boundary of how the software will evolve. Screenshots and user … Continue reading

Software developer survival skills

To have a career as a developer, you need to have some important basic skill sets. All (new) technologies are built on top or around some commonly used technologies. People always say, “WOW, this technology is really hot now, you should learn it!”. Yes, but to even know the basics, it will take years to … Continue reading

Why Symfony?

Choosing the best framework for rapid development has been a topic that has been debated to death. Today, there is no longer “the best framework” because all modern day framework is scalable and robust, they learn from each other. They are all adapting very fast to new techniques of doing things. At the time of … Continue reading

Symfony2: Installation

The official installation doc is As a best practice, don’t install symfony in MAC or Windows, install in Linux and use Linux for development because you will be using Linux for hosting. For consistency in development, develop in virtual machine. The spec of the virtual machine should be the same as the production server. … Continue reading