Topic: PHPAll Posts

SVG Embedding

If you use an img tag to add an #SVG to your web page, you can't use #CSS to style it. Which is a shame, because I want to change the colors interactively or use the same icon with multiple colors quite often. Actually, almost as often as I use SVGs. But, I don't want to see the actual definition of the SVG repeated all over the place in my #code. There are probably a few solutions to this, but #PHP readfile() is my current favorite. Simply call #readfile to output the contents of a file. You might have to edit the SVG to remove some cruft, but it won't affect the way it looks. Plus you might want to add some classes to it. Then you just treat it as an inline SVG for styling purposes. Handy, right?


Posted 2 May 2019 by Brian

Symbolic Links Revisited

I think they're broken. On #Windows anyway. As far as my logic understands, any running program should not know that they even exist. But #xampp can tell. Or at least, I think Windows is just feeding it directories as if it could tell. This is a little rough to explain.

Say we have a #PHP file on an #Apache server in a directory, but that directory is actually what Windows calls a junction (A type of symbolic link). If I 'require' another php file with a relative link like '../', where is the server going to look?

My first guess? The directory above the junction. It took me nearly an hour to determine that it was looking in the directory above the TARGET of the junction. Maybe that's the way that should work for some reason. But I do not know what that reason is. If Windows had any kind of proper sandboxing, it'd be a major security hole.

I do seem to be good at finding the #CornerCases.

Posted 8 Mar 2019 by Brian


You found me! I'm Brian Bogedin. This is my website and blog. Obviously. Anyway, I'm a full stack web developer and game programmer operating in Southeast Michigan. I do freelance, too, so feel free to contact me with business inquiries. Thanks for stopping by!

Ping me:


This blog!

I'm making this blog from scratch. No CMS, frameworks or libraries! Just MySQL, PHP, JS, HTML and CSS. Is it necessary to create a blog from scratch? No, but it is great for learning, and customization. Does your blog have hashtags?

Website for a youtube channel that creates instructional and entertainment videos about illustration. I built the site and manage giveaways there from time to time. Currently working on a miniature custom CMS so that the site owner can administer the giveaways without my assistance.

SECO Tools

I do some work here and there for a company that sells mill tooling. Most recently built a batch processor for their tool converter. Basically, it takes a bunch of competitor product numbers and returns the information on tools offered by SECO with similar specs. Still needs some user friendliness enhancement, but it's currently only for internal use.


This is a small couch multiplayer game made in gamemaker for a game jam I organized with some friends. Up to 6 players use controllers or the keyboard to fire rockets on the side of their city to rotate a planet and avoid incoming missile. The trouble is, everyone else is trying to rotate the same planet! Download it on!


Mulitimedia engine being developed by my friend, Josh Powlison. Plays audio, video, comics, text, and kinetic novels. Cool stuff. I'm helping out a tiny bit. See the demo here.