Home » General » Website work continuing

Website work continuing

Work continues on updating the site but I have a lot of housekeeping to do. I have a lot of PHP scripts that were running in the background that were using depreciated functions like mysql_connect(). This isn’t challenging work, but it takes time to remember what I was doing and why. The last two nights, I updated the RandomQuoteGenerator™ so that it can hold additional data. Instead of just displaying a random quote, it will also tell you where it’s from. Always wanted to do that but never got around to it. So needed to update an ancient MySQL table to include that additional information and then populate it. Once that was complete, I had to update the code behind it.

The code behind the scenes used to occasionally throw an error on a specific query. I can only attribute it to the fact that I was referencing a column by it’s numerical value instead of row number, so if it found a blank, it would vomit all over itself. Changed the code to reflect that because I’m sure I’ve deleted a record or two in the last 10 years but instead of soft deleting, I removed the record entirely. Whoops.

After that, it was on to fixing the code that displayed all the available quotes in the database. I had another ancient PHP page to upgrade and then give a facelift. With so many nice CSS styles out there, I came across a sortable table but with a terrible color scheme. Decided to drop it for the one below. I may just borrow the code behind the sorting and keep the color scheme here. Best of both worlds would be great. I’m probably going to push the dev site to production and just code it live. Because I don’t always test my code, but when I do, I do it in production.

More to come.


Leave a Reply

Your email address will not be published. Required fields are marked *