skip to Main Content
+971 55 881 1725 hmimthiaz @ imthi.com

Symfony Doctrine Many to Many Relationship (ManyToMany)

Many to many relations are one of the mostly used relations in the relational database. It took a while for me to figure how to properly configure this relation in Symfony Doctrine. I am sharing this so it might be useful for someone.

Used very simple example students and course. A student can opt for multiple courses and a single course can be opted by multiple students.

And Entity class should be like this…

The above entities will create the following SQL and it will also create the cross-reference table.

Hope this helps 😉

Why do we need to upgrade PHP 5.6 to PHP 7.2?

Rest in peace PHP 5.6

  • The current version of PHP which is 5.6 has reached the end of life on 19th Jan 2017. PHP team has stopped support for 5.6, and no more new features added.
  • Security support for 5.6 is up to Jan 2019. On Jan 2019 PHP 5.6 officially dead.
  • The newer version of Linux and server software has already stopped supporting PHP 5.6 which creates a huge security risk.
  • Updating old server will be hard as it may break the PHP due to compatibility issues.
  • All major PHP libraries and frameworks will drop support for PHP 5.6
  • 7.2 end of life is in Jan 2021
  • 7.2 is so much faster than 5.6
  • 7.X has new Zend Engine
  • Reduction in the memory usage
  • Consistent 64bit support
  • Better Error handling
  • More secure & better handling with SSL and cryptography

TinyMCE remove height & width from image

It is so annoying the TinyMCE editor image plugin saving the height and width of the image. You can turn it off in the settings.

There are other settings available for the image plugin please visit here for details.

Twitter Security Issue, Don’t use your main password

Today my friend was writing a small application to post updates to twitter. We found that the API is not secure (does not use SSL). I installed network packet capture programs and was able to capture the request headers what the twitter client was sending. It was basic authorization which is encoded using base64.

twitter-post-request-header

Is there anyway you can avoid this?

  • For now use simple password until twitter updates their API with SSL
  • Don’t fight with your network administrators 😉

Google web monopoly next milestone Chrome

Google has released its new browser “Chrome” today. It is released as beta (I really don’t understand what is the meaning of beta in Google. Can you believe Gmail) for windows alone. This browser is based on webkit rendering engine. which gives web developers a big relief in rendering issues and web standards. The good feature in chrome I really loved about is each tab runs in its own sand boxed environment. When an tab crashes it only the tab and not the whole browser.

Next step was to download the browser and test it. It was amazingly fast. And really felt the browser was really light. I loved the simple and efficent GUI. Creating application out web was really smart move. There is no option for extending the browser with extension and themes. May be it is on it way.

Will Google target it like Adobe Air?
Will Google create more API inside chrome to support their web application ?
Have thousands of question rising up my mind and only time will tell those answers. But these guys are planning big time to reach more market share in web. They have already started to advertise about the new browser on Google homepage.

Google Chrome Browser

Will chrome dominate the browser wars by end of this decade ?????

Back To Top