I am happy. I have reached a new height regarding PHP. I created my own PHP class.
I looked at my RSS feed creator and i thought, "Wow... what's this?" I wondered how I could clean it up and make all of my feed writers as efficient at the same time. It then dawned on me... this would be a perfect place to implement a class.
In case you didn't know, a class in object-oriented programming (OOP) is a set of variables and functions that work together to organize the code better. Java is an example of a completely OOP language. PHP is mostly procedural, but can support objects.
PHP Object support was really poor in version 4. Even when it improved, I never found use for it. I could always do the same thing without objects, but that wasn't always the most efficient. I wanted to be more efficient now, but I didn't care for it in my earlier days. I had no clue what a-do for OOP, but as I learned Java, it all began to make sense why one would use it.
Anyway, I toiled on my little AtomFeed class. I chose Atom over RSS because it seemed better. It could change with the times, as opposed to the frozen state of atom. It also seemed more structured. But anyway, I managed to create it. It's set for PHP 4. I hope to move to PHP5 and I won't mind updating the code accordingly. One has to change with the times, after all.
Then, I updated the data transfer scripts to take the info from the database and put it into the new class. When I tested (and thoroughly debugged) it, By Jove, it worked! That made me happy.
Thus, my second titular news: feeds are updated. I abandoned RSS in favor of Atom. I now only have one main feed, removing the RSS version, and I transferred the mini-entry feed to Atom. Thus, I now have a standard way to modify my scripts.
Now back to programming. Java. My AP test is in two days. I haven't read much of the book, but I know enough PHP to know enough Java. The thing about programming is one only needs to know the basics: variables, types, comparisons, arrays, and control structures. Then learn common functions. After that, each language has its own refined points, so just learn them. Of course, this is just based on my limited knowledge of Javascript, PHP, and Java. I have dabbled in C and C++ and seen that they're quite similar. This does not apply to assembly lanuages or certain novelty languages. But yeah, I should read more on Java. I just got done with polymorphism and inheritence. I have quite a few more chapters to go, but I didn't do badly on the practice exam. Doesn't mean I can't improve, of course.
On the topic of PHP, I must remind myself to implement tag deletion on my entry edit page. This is my reminder. Oh yeah... comment fixin's. (Not a possessive 's, just to clarify)
And another topic. I noticed myself using a lot of "anyways" and random digressions. I've been Catcher in the Rye'd?