I am not a programmer. I know a little PHP (I took courses about 20 hours), but I never wrote more than 15 lines of code. But recently, inspired by the
experiment of Meth Cutts , I decided to conduct a similar experiment on myself. I wondered if I could create at least a small finished product in 30 days and at the same time learn PHP. Check how difficult it is to force yourself to do something not ordinary every day. I also decided to periodically take notes on how my work was progressing and this is what came of it.
Day 1In order to improve my PHP skills and stop wasting time after work, I decided to write a WordPress plugin for managing meta robots.
')
Based on your old script metarobots.php. About 2 hours I studied the documentation for the development of plug-ins for WordPress - everything turned out to be quite not difficult. Made all the main logic, now it remains to make the settings page. I did not think that I would have so much time for the first day.
Day 4The settings page turned out to be harder than I thought. For a newcomer like me, writing and reading files was also not an easy task. Spent for 3 days of hours 6. The browser is constantly open pieces of 40 tabs, google every tag. As a result, almost finished plugin. It remains to make one control function and can be tested on a real site. An additional plus is that I understand the shielding and the basics of regulatory expressions, rewrote the logic of the original script. I begin to understand why, after reviewing the code of my first script on toster, they said that I program as a third-grader.
Day 5Finished the settings page for the plugin or almost finished, we'll see. I noticed that I started to google less and dig more in the documentation for the engine, but maybe the task was not difficult. Today, for the first time, I wrote the working code right away, kodil for 15 minutes, launched it - and it all worked right away! No bugs! Great feeling. It is interesting that playing and stupid on the Internet does not pull, although I work for a maximum of 2 hours, it may just not bother you.
Day 6St.Patrick 's Day. One eye looked at the code. Mark out a bit. I highly doubt that is correct. Good night.
Day 7Yesterday, my head ached. I threw my code to my friend: the plug-in did not start the first time. After consulting with knowledgeable php people, got rid of the toughest crutch. Now the plugin equally works on LAN and hosting. Wrote 99% of all logic. It remains to format the code, create language files, write a readme file and you can upload it to the plugin library.
Day 9I thought that I would format my code for at least a couple of hours, but I found
beautifyphp.com - this is just a super cool service for people like me! Automatic code formatting in seconds.
Those who know PHP scared with stories about code theft through similar services, now I’m a little nervous.
Day 12,13I added a plugin, wrote a readme.txt, I gave it for translation. I want to put the plugin on wordpress.org
I started writing a plugin for Joomla, especially with the indexing there are usually more problems than in WP. The body of the plugin rewrote for half an hour. Tomorrow I will test. Transferring a small plugin from Wordpress to Joomla turned out to be very easy, a bit of reading the documentation, the rest is copy-paste and autochange.
Day 142 hours trying to figure out how to raise the second domain on LAN using Open Server. It did not work, I hope I can tomorrow. Could not test plugin under joomla. In short, a day at idle.
I looked through my notes, I lost a few days somewhere.)) Strange.
Tomorrow is 15th day - the middle of my marathon.
Day 19The last days are very few programs. It turns out that writing a working code once is not all. Constantly find bugs. Not enough time to finish everything humanly. Got sick I'm starting to be lazy and mow off work. We must get together and finish everything in time.
Day 21Made a plugin blog
page . Sent for moderation.
To be honest, it is very pleasant to understand that in 21 days, in spite of laziness, it turned out to make a finished product, albeit not at all difficult. Recently I thought: how wrong we use modern computers. Technologies have reached a level where each of us can automate part of our work using simple programs. Get rid of heaps of routine work.
I hope I have time to finish the plugin for Joomla in 9 days.
Day 22Today I received a response from Wordpress, I did not think that they would respond so quickly: there were about 70 plug-ins in the queue for testing. As I expected the code with errors, I did not think at all about security. Corrected everything and sent it again.
Tomorrow I will sit behind the plugin for Joomla, something does not work in it, but I still do not understand what.
Day 24Got another email from wordpres.org, my plugin has been tested. That's cool! I feel like a real tyzh programmer. But now a new thing - SVN. I read the instructions and can not figure out how to upload files there. I understand that this is probably very convenient and safe, but I have more and more suspicions. It seems that the developers come up with a bunch of additional technologies to make it easier for the beginner to get used to. Another feature is the readme.txt markup. Seriously: why use an incomprehensible markup syntax that partially supports html, instead of immediately making readme.html? Exactly plot.
Did not do anything today. Marked readme.txt, read about SVN.
Day 25SVN is not as difficult as it seemed. I installed Tortoisesvn, figured it out and uploaded the plugin in half an hour. Now I have
a wordpress.org page . I sit, smile like a fool.
Day 32My 30 day programming marathon is over, even a little sad. Last days I worked on the plugin very little. But, nevertheless, I am satisfied with my results. Suppose I could not make a plugin under Joomla (I will definitely do it), but I finished the plugin under WP, as planned. Poured it on wordpres.org and joined to some great common cause. It is very nice to know that the plan has been completed - it gives confidence and I want to work further.
There are many plans:It is necessary to learn OOP
Add a plugin under Joomla, maybe Drupal
Modify plugin under WP (localization, support for Canonical)
Summarizing
Summing up my experiment, I can say: this small marathon turned out to be really useful for me. I learned PHP, as well as a little insight into new topics: documenting code, SSH vulnerabilities, version control systems. And if I'm not a programmer, but now I understand them much better. In addition to practical knowledge, this 30 day experiment gave me more confidence in my abilities. It's amazing how a small effort every day allows you to quietly move the project, which at the very beginning seemed quite difficult, and see how this gives a result.
And I also noticed that doing some work every day for several weeks, this work becomes a habit. A good habit that helps replace time wasting with something useful.
Now I think to make such marathons regular.If you have long postponed an interesting project or wanted to learn something, but you didn’t have time, try the 30 day marathon. At a minimum, you will start an interesting project for you, and ideally you will do something worthwhile and earn a good habit.