
This is the map that Jack made. And below the post-bytovuha, which does not carry valuable information. The so-called "startup weekdays."
Last Monday, I was overtaken by the idea that a self-respecting tour resource should have a travel card.
On Tuesday, I sat down to work, with the intention of doing everything until Thursday, since I wanted to drink on Friday, I had a birthday on Saturday, on Sunday I planned to watch the n-th number of episodes of “Desperate Housewives” (no joke, a terrible infection ), and it is better to bring the creation to the world by Monday or Tuesday - the most active day in RuNet, according to my observations. Then your presentation post in LiveJournal will appreciate more people.
The program part did not represent special difficulties. The GD library superbly imposes transparent pngs on each other. It seems to me here and there can be no other solution - we make the map a substrate, and we hang red countries on it.
On Tuesday I experimented. That is, I tested the technology. By the end of the day he was armed with bricks of which a script was supposed to be built - pieces of working code, and a plan for how this should work. The simple case was slightly complicated by the fact that all of this was written as a module for Drupal, with preservation of information about countries in the database for registered users, and in principle had to be made on any other Drupal site.
')
Wednesday was a painful day. Work that cannot be automated - cut a map into 200 countries,
write to the script the mixture of this country from the upper left corner in pixels. There also add the width and height of the resulting country. In general, I realized that if I did not master it in one day, there would be no second - I’ll quit. I probably spent about 14 hours. At the end, the automatism was such that the movement of the arms could be traced only with the help of slow motion shots. But in the 4th night when the countries ended, I was happy. In addition, I learned a lot of new things. For example, that in the world of dohrena of milypizdrichesky island countries with funny flags and for some reason decided that in time I will live in Micronesia.
Thursday was again under the flag ctrl-c ctrl-v. Form with checkboxes for countries, entering into the database, removal from the database, etc. There were some stupid problems. For example, I did not know how to set the checked attribute for checkboxes in Drupal. Forms in Drupal are created very funny - an array of forms is made with attributes of type
$ form ['euro'] ['countries2'] = array (
'#title' => t ('Countries'),
'#type' => 'checkboxes',
'#description' => t ('Please select your favorite color'),
'#options' => array ('s001' => 'Albania', 's002' => 'Honduras'),
'#value' => array ('s001' => "checked", 's002' => NULL),
);
and then this array is passed to the drupal_get_form () function, which already draws everything.
In general, by the evening of Thursday there was nothing ready.
Friday. Stakhanovskim pace painting lawns in green, I finished off the script, because the prospect loomed or do not drink or drink in a bad mood. And lo and behold, for hours to three everything worked. True to five I struggled with “kosyachkami”, after which my mood improved again (for the second time in a week)
Well, Friday night went well.
PS: 50% percent of the world map tour is made on the basis of some ancient core map. My got in the same list next :)