When you develop on your IDE (in our case PhpStorm) is very handy to know at least base keyboard shortcuts and save your time. Personally I’m trying to avoid using a mouse and I feel it’s more funny and professional to work without it.
You cannot miss those commands:
Full keymap you can find in PhpStorm -> Help -> Keymap Reference, or directly here:
A curated list of amazingly awesome PHP libraries, resources and shiny things.
Even php code can be clean, good organized and readable. If you are php developer, you should read this http://www.phptherightway.com/ and use it in practice, especially useful for beginners!
Download appropriate oracle instant client
(base and sdk packages important!)
Extract those files in a directory
Set oracle home variable
Create symlinks for libraries
ln -s /opt/instantclient_11_2/libclntsh.so.11.1 /opt/instantclient_11_2/libclntsh.so
ln -s /opt/instantclient_11_2/libocci.so.11.1 /opt/instantclient_11_2/libocci.so
ln -s /opt/instantclient_11_2/ /opt/instantclient_11_2/lib
If you already have php installed, you can compile only the PDO_OCI from PHP source. (Do not install with pecl because it’s deprecated)
- Download the PHP source with same version that you have installed
- Change to directory php-YOUR-VERSION/ext/pdo_oci
Run commands to compile PDO_OCI
make && make install
echo "extension=pdo_oci.so" > /etc/php.d/pdo_oci.ini
Restart web server
service httpd restart
Sometimes, we have important updates on our box, and it’s good to renew it.
Type this command to export box, where Vagrantfile is located:
vagrant package --output new-updated.box
Type command to import new box, to your machine:
vagrant box add mynewbox mynew.box
Hey, I was thinking about a code that we write and how good it is. As developers we always have to struggle with deadlines and business changes. Sometimes we just have to do the job and then we don’t write such a clear code.
The problem is that there aren’t any boundaries in perfection and our code won’t be perfect after many years when new technologies come. I’m not trying to say that we shouldn’t use best practices and write a clean code, but we just have to do the job and maybe correct some places in the future when we have to deal with them.
In the end I would like to say: “Working application is more valuable than a perfect code”
Hi fellas, in this post I’d like to share an example how I use docker with Symfony. Docker is good tool for web developers, and there are a lot of articles about it, but how it should be used with symfony (or other framework)? I’m going to show it below:
First we need to install docker, and docker-compose (for easier containers management). You can read more about docker technology on their official website.
Create docker folder to store php / nginx settings and logs. Also I was needed custom php extensions that’s why I created php-fpm folder with Dockerfile.
Create docker-compose.yml file in your project root directory
command: elasticsearch -Des.network.host=0.0.0.0
At the end build your image if you need and run in terminal “docker-compose up -d”, it will create containers and loads it.
You can find full example of using docker with symfony: