This is just a small nerd post for those of you who may be trying to use the beta 3.0 series of EasyPayPal for WordPress. The script has a very common bug in it that shows up if you don’t configure any categories to be hidden unless purchased in the options. The fix is very simple and I’m rather amazed it hasn’t been committed yet. All that has to be done is to initialize the $cats variable to an empty array since the variable is only created inside a conditional (bad coding!).
Read more…
It’s been a very, very long time since I last touched php_template and just out of the blue today I decided I’d finally get off my ass and create a Visual C++ project out of it so I could compile it for Windows users.
Well, after several hours of tinkering and encountering PHP source code “bugs”, I finally got it to compile. I had to do a few fixes too apparently – I was missing some TSRM junk to the parse_tag() function (and I believe that’s because it passes a zval around, so it needs the thread-safe stuff with it), and I had some calls to strlen() which needed to be explicitly cast to avoid warnings. This got rid of some of the compile-time warnings (there are still warnings about strcat() and cousins being used, but I’m smart and know how to use them properly) generated by VC++ 2005 and popped out a tasty php_template.dll for PHP 5.2.1.
Read more…
I was fooling around with some stuff when I noticed one of the scripts I was trying to use had some hard-coded paths in it meaning I couldn’t rename it’s base directory (which really wasn’t a good name to begin with). Anyways, I thought I’d post a few simple things every PHP programmer can add to their repository of useful junk which may help them deal with using relative paths to include files in both their PHP scripts and any HTML pages that need relative source paths too.
Read more…
I just finished spending a few hours messing with this flickr junk which everyone seems to put on their sites (which means I’m not cool unless I have it too!). It wouldn’t have been so bad but at first I didn’t even know that you could create a flickr badge – then it took me even longer to figure out where on flickr’s site I could go to get info on making one
Anyways, right now I’m trying out this flickrRSS plugin which isn’t bad, but honestly doesn’t do anything spectacular, and it’s not as feature rich as using a flickr badge (though it doesn’t put a requirement of JavaScript on the client which is nice). I would prefer to use the flickr badge for now, but the default WordPress theme I’m using is horribly written (though I will say it looks rather nice – but the HTML/CSS coding causes all sorts of problems when you try to add to it) to be honest and was pissing me off as I was trying to display images as floated block elements, though this caused the rest of the sidenav to flow as if the entire image div was a floated inline block. Of course clearing all floats doesn’t work since the entire sidenav is floated itself (argh!).
Read more…