After years of using a spreadsheet to organize my podcast, I finally realized that a database could make things much easier. A lot of my problems with the podcast are related to my illness. There is the flakiness factor: I forget to write down which songs I have already requested or for which songs I got permission. Then, there is the manual dexterity issue: I have trouble moving the cursor to the right place in a template to put in the necessary information. Then, there is the visual confusion: I have trouble looking at a lot of code sometimes. When I put this all together, it means that the administrative tasks behind the podcast can be difficult/stressful.
It is much easier for me to enter things into a form on a webpage. I have a big area that I can click on. I don't have to look at a lot of code, and I can make the screen very simple and visually uncluttered. Instead of having to note that I got permission (or requested permission) in several places, I can just do it in the database (and potentially use the database to set the field in the ID3 tag of the MP3 file to indicate that I got permission). I can use the database to generate the text I need for a request (instead of having to edit the template). It can tell me where to send the request. It can generate the episode webpage for me.
Since much of the podcast website is already automated to some extent, I was able to import the information for all 140 episodes into the database. Today, I finished creating pages to add all the entries in various dropdown menus and entering in all the data. There's one more of those left to do, I think.
What I'm really looking forward to is getting songs imported into the database. There is a library for PHP (listed on the main PHP page) to parse ID3 tags, but it turns out that it is no longer supported and doesn't work with modern versions of PHP. It took me hours to understand this, find a replacement, and get it working. However, I now have a script that parses information from ID3 tags. Yay! (And thank goodness for the RSS reader that I wrote. There was one section that was in some kind of XML array that isn't really an array. However, I had encountered it when working on the RSS reader, so I just had to look at that code instead of spending hours (as I did previously) trying to figure out how to access the data.) When I started thinking about how to get these songs and all their related data into the database most efficiently, I realized that they are dependent on a bunch of other data. For example, I can't link the song to the episode it was in until all the episodes have been imported. I can't mark which track it was in that episode until I have the dropdown list of possible tracks. And on and on. As I said, I'm almost done with that. However, there are a lot of dependencies involved in importing the songs, since a song is in an album (which has many songs) by an artist (who may have many albums). That means that the album and artist are both in different tables from each other and from the song. Anyway, I'm having a good time working on it, but there is a lot to be done.
While setting up the ID3 library, I realized that many of my other databases are using old (and not really supported anymore) versions of PHP, so I went through and moved them all to the most recent release version. That caused some interesting errors, which I've been fixing over the last couple of days. Between that and the podcast database, I've fixed up some functions that weren't quite right. However, this really points out to me that I need to clean up my shared libraries. I have a lot of duplicated code, and because I'm not always processing at peak efficiency, I didn't know how to avoid this. For example, I would need a new part of a function, like adding a timezone to the function that validates dates from forms. So, I made a new function to do this, because I didn't want to change the old function and then have to track down every time I used it and change the inputs. I might have called the old function, but (at least for the timezone problem) that didn't work. Finally, in the shower, I realized that I was looking at it backwards. I don't need to call the old function. I need to make the old function into a wrapper and use it to call the new function. If it doesn't have a timezone, I can just set that to NULL and then check for it in the new function. Of course, this will work better and enable me to have to maintain fewer functions. Now, I just need to have the time to do this. The queue looks something like: finish the podcast database, finish adding the last element of the new section of my health database that tracks doctor visits, upgrade the login page of my to do list to the default one for better smartphone support, then upgrade food database website to allow easier editing. I think that during this last step, I will already be making sure that the webpages are using the right form input validation code, so I can probably clean up that code at the same time.
I'm sure that I won't get every last cool feature done during this round of work on the podcast database website. I'll get enough done to (hopefully) get the next podcast put out with its help, and then I'll try to finish up the work on the health database's doctor pages. However, I really look forward to getting this all done. I've also started having more problems with getting errors where my pages just refuse to load, so I'm going to have to look into that.... Anyway, it never ends.
It is much easier for me to enter things into a form on a webpage. I have a big area that I can click on. I don't have to look at a lot of code, and I can make the screen very simple and visually uncluttered. Instead of having to note that I got permission (or requested permission) in several places, I can just do it in the database (and potentially use the database to set the field in the ID3 tag of the MP3 file to indicate that I got permission). I can use the database to generate the text I need for a request (instead of having to edit the template). It can tell me where to send the request. It can generate the episode webpage for me.
Since much of the podcast website is already automated to some extent, I was able to import the information for all 140 episodes into the database. Today, I finished creating pages to add all the entries in various dropdown menus and entering in all the data. There's one more of those left to do, I think.
What I'm really looking forward to is getting songs imported into the database. There is a library for PHP (listed on the main PHP page) to parse ID3 tags, but it turns out that it is no longer supported and doesn't work with modern versions of PHP. It took me hours to understand this, find a replacement, and get it working. However, I now have a script that parses information from ID3 tags. Yay! (And thank goodness for the RSS reader that I wrote. There was one section that was in some kind of XML array that isn't really an array. However, I had encountered it when working on the RSS reader, so I just had to look at that code instead of spending hours (as I did previously) trying to figure out how to access the data.) When I started thinking about how to get these songs and all their related data into the database most efficiently, I realized that they are dependent on a bunch of other data. For example, I can't link the song to the episode it was in until all the episodes have been imported. I can't mark which track it was in that episode until I have the dropdown list of possible tracks. And on and on. As I said, I'm almost done with that. However, there are a lot of dependencies involved in importing the songs, since a song is in an album (which has many songs) by an artist (who may have many albums). That means that the album and artist are both in different tables from each other and from the song. Anyway, I'm having a good time working on it, but there is a lot to be done.
While setting up the ID3 library, I realized that many of my other databases are using old (and not really supported anymore) versions of PHP, so I went through and moved them all to the most recent release version. That caused some interesting errors, which I've been fixing over the last couple of days. Between that and the podcast database, I've fixed up some functions that weren't quite right. However, this really points out to me that I need to clean up my shared libraries. I have a lot of duplicated code, and because I'm not always processing at peak efficiency, I didn't know how to avoid this. For example, I would need a new part of a function, like adding a timezone to the function that validates dates from forms. So, I made a new function to do this, because I didn't want to change the old function and then have to track down every time I used it and change the inputs. I might have called the old function, but (at least for the timezone problem) that didn't work. Finally, in the shower, I realized that I was looking at it backwards. I don't need to call the old function. I need to make the old function into a wrapper and use it to call the new function. If it doesn't have a timezone, I can just set that to NULL and then check for it in the new function. Of course, this will work better and enable me to have to maintain fewer functions. Now, I just need to have the time to do this. The queue looks something like: finish the podcast database, finish adding the last element of the new section of my health database that tracks doctor visits, upgrade the login page of my to do list to the default one for better smartphone support, then upgrade food database website to allow easier editing. I think that during this last step, I will already be making sure that the webpages are using the right form input validation code, so I can probably clean up that code at the same time.
I'm sure that I won't get every last cool feature done during this round of work on the podcast database website. I'll get enough done to (hopefully) get the next podcast put out with its help, and then I'll try to finish up the work on the health database's doctor pages. However, I really look forward to getting this all done. I've also started having more problems with getting errors where my pages just refuse to load, so I'm going to have to look into that.... Anyway, it never ends.