Grepping for Terms on Separate Lines but Near Each Other

I wanted a way to search through the ~200 themes we have on WordPress.com to find out which ones registered sidebar areas for the home page, and this is what I came up with: find . -print0 |xargs -0 grep 'register_sidebar' -s -A 2 |grep 'home\|front' |more That’d have to be customized to fit other […]

Continue reading...

Including External View Files in WordPress Widgets

I ran into a problem today while cleaning up and modifying some widgets. I moved all of the markup inside widget() to an external view file, and then included it via require_once(), which worked fine. I then tried to do the same thing inside form(), but didn’t get any output. It turns out that you […]

Continue reading...