how to create custom filter in zend framework 2

Okay, i have just passed 4 bloody hours googling about this issue :|. since i am a forgetful person i will write about how to create custom filter in zend framework 2 as my note if someday i need it again.

1. create new a file in your_module/Filter/Test.php

(more…)

how to use table gateway or database in view helper zend 2

last time i wrote about tutorial how to create view helper in zend framework 2. now i am going to share how to use model table gateway in view helper. i will use the code in last tutorial that mentioned before so you have to look this tutorial create view helper in zend framework 2 to follow this tutorial.

(more…)

How to create view helper zend 2

in tutorial zend framework 2 now i will share how to create view helper in zend 2, since i am forgetful person :P so i decided to write in my blog. ” view helper ” as you can see by its name this is a class that you can call or access it in your view file ” file.phtml “. so when you need a class in your view file like a function to calculate total or anything else. you need to create “view helper” it’s difference with “action helper ” because “Action helper” is intended to just call from action controller.

(more…)