Problem: Cant install pecl packages on Alpine PHP7 Docker Image.
Since PHP Container is based on Alpine 3.4 which in turn does not have library memcached available.
It seems Alpine 3.4 is meant to work with PHP5. Thus creating a gap with the availability of packages for PHP7 and up. Luckily newer versions are switching to the alpine 3.7 where all the packages already available from the distro’s package source.
[Read More]
Angular Component Communication
In This example I demonstrate communication between the components. This is very useful to separate concerns and have components be responsible for itself.
Angular Templates
Templates for Angular Development Prototyping.
One of the exciting feature of Angular 1.5 Is accent on use of Components. Something that changes the way how you think about reusable parts of your application. It helps to organised your thought around notion of independent components that serve focused job, and responsible for themselves only. That approach will help avoid most common problems of angular development called “Scope Soup”. If you have seen this $scope.
[Read More]
Video Reviews for Woocommerce & Site Comments, 2 Easy Solutions.
Have you ever wanted to include video reviews to your Woocommerce store? Or allow users to post videos with comments, which works same as reviews. Well now we will see how to achieve this with two ways.
First Solution is to have users to post comment with necessary html code for embed the video. To make this work our default user role need to have necessary (unfiltered_html) permission. Dont be scared its easy to do with 2 lines of code.
[Read More]
Sensei is a Learning Platform Plugin tuning
Sensei is a Learning Platform Plugin, with build-in Woocommerce integration. It is also developed by Woothemes, company which was recently purchased by Automatic (Owner of Wordpress) to simplify building of e-commerce websites. Sensei is premium plugin, means you need to buy it, but its also GPL, and has its development open on https://github.com/woothemes/sensei.
By The Default Sensei Supports only multiple choice, fill in the blank, and true and false, auto-grading. However in the recent project I have worked on I have encountered need for auto-grading the questions of the single line, multi-line and file upload types.
[Read More]
Wordpress - Creating Site specific plugin
Why create wordpress modification as a plugin? That allow us to keep theme files (function.php) clean of setup or plugin specific modifications. With that said lets begin.
Create a folder in the plugin directory of your wordpress website. Create index.php file with following content as template for plugin:
<?php /* Plugin Name: Description: */ /* Below this line content of the plugin */ ?> As you can see its pretty simple.
[Read More]
Modification of plugin's hooks and actions regardless of load order.
To have access to all other plugins hooks, we need run our script when wordpress done loading plugin. Use following workaround.
Place your hooks in to the function, and call it when plugins_loaded.
add_action('plugins_loaded','modify_actions_custom'); function modify_actions_custom(){ }
Reference: Wordpress Codex with loading structure.