Worse, actually, though it's a neat idea, which I might get some value from at another time, but for this particular task, all I need is to pass mysql a query containing a PHP constant.
Well, I don't need to do that, Kludge (a) above works just fine, it's simply that I don't like it because it's a kludge. In this example it only introduces one unnecessary local variable and one extra line of code, but there will doubtless be other examples in the future and it would be good to know what the proper way to do this is.
To answer your question, the constant MINYEAR is hard coded in an include file, alongside maybe 20 other constants. I think it's a good idea to use constants wherever possible in php. For one thing, they have global scope so you don't have to fiddle about passing them to your functions or issuing global $xyz" all the time. For another thing, you can't accidentally assign a different value to them. And finally, they are good for your if/then logic because they can help catch errors where you mistake an "=" for an "==".
So I try to list as many constant values as possible all in the one place where they ae easy to find and change. This MINYEAR example is perhaps a poor one, as I'm unlikely to ever change it, but the matching pair for it, MAXYEAR, is particularly useful. I have no idea how many line of my code reference MAXYEAR - at a guess, 10 or 20, in maybe 5 or 6 different files. But when I started adding the latest (2008 ) pictures a week or two ago, I didn't need to know that stuff, all I had to do was change one line in my include file (and make a new thumbnail picture because some of the links and indexes use graphical "click-the-picture" linking). If I'd written "2007" instead of MAXYEAR in my code, I'd have had to hunt through the entire codebase looking for instances.