4,512 reputation
523
bio website vyznev.net
location Helsinki, Finland
age
visits member for 2 years, 3 months
seen yesterday

I like programming in Perl and C. I know Java and PHP too (I'm a MediaWiki developer), but I can't really say I like them. I keep meaning to learn Python some day, but never seem to get around to it.

I'm working on a Ph.D. in biomathematics. I also like programming puzzles and cryptography.

Please consider any (original) code I post to Stack Overflow (and other Stack Exchange sites) to be released under CC-Zero unless stated otherwise. You may do whatever you want with it and don't have to credit me in any way, although of course that would be nice.


Mar
18
comment Combine user-agents in robots.txt
The original robots.txt spec agrees: "If more than one User-agent field is present the record describes an identical access policy for more than one robot."
Feb
23
comment Submit example.com/#!/page URLs to Google
...and you're just toggling the visibility of the <li>s, rather than actually loading the content via AJAX? In that case, you could just add some code to your index.php so that, if it receives an _escaped_fragment_ parameter, it styles the matching <li> with display:block and all the others with display:none (or omits them entirely). Oh, and you probably should a) change your <title> to describe the page being shown, and b) use the <meta name="fragment" content="!"> trick for the main page.
Feb
23
comment Submit example.com/#!/page URLs to Google
"There is no way to directly submit this to Google" is kind of misleading, since, in fact, the instructions you've linked to say you should directly submit such URLs to Google in your sitemap. You just needs some extra server-side support to let Googlebot fetch them.
Jan
27
comment Does the 'Server' header serve any purpose?
A 100-byte header, like the one quoted in the question, might well cause the combined length of the response headers and content to spill over into an extra packet. Besides, packet-counting tells the whole story only for purely latency-limited connections. In (at least partially) bandwidth-limited situations (such as slow mobile connections, or large data centers with a huge request volume), the total amount of bytes transmitted starts to matter too.
Jan
10
comment What is the purpose of leading slash in HTML URLs?
@DisgruntledGoat: Probably way earlier than that. In fact, I'd go on a limb and just say "every browser ever"; that syntax has been part of the URL standard from the very beginning.
Jan
10
comment Mass Deletion of Spam Revisions in Mediawiki
There's no point in trying to delete spam links from externallinks, since that's a redundant metadata table that's basically only used for things like Special:LinkSearch; once you've cleaned up the actual pages, you can just run rebuildall.php to wipe and rebuild it. Ditto for searchindex.
Jan
10
comment Should the English website use href=“x-default” when it doesn't auto-redirect to the user's language or country?
What if I'm using a Spanish-language browser (maybe in an Internet cafe in Spain?) but I want to read your pages in English? Is there some link I can click, or am I SOL? (Ps. One reason I'm asking this is that I think the answer may affect the hreflang markup you should use.)
Nov
10
comment Blatant copyright theft
The GPL (v3, section 7) allows you to "supplement the terms of this License with terms [...] c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version", but does not include such terms by itself. It does, however, require modified versions to include your copyright notice (sections 4 and 5).
Nov
10
comment Google indexes 301 source, with the destination content
@AlexisWilke: What I'm saying is that the reason this happens with TinyURL is that they (sometimes) include a 302 or other temporary redirect in the redirect chain. It does not, AFAIK, happen if only 301 redirects are involved, or at least it did not back when I wrote this answer. (That said, this is for TinyURL links that have always been redirects; I'm perfectly willing to believe that Google might be slow in updating their index, or that, as Stephen Ostermiller suggests, they might simply be treating the 301 as a 302 just because the target URL doesn't look like a permanent one.)
Oct
13
comment How to implement hreflang on a single domain?
+1 for the link.
Aug
27
comment How did Google find my unlinked newly created pages?
That's odd, then. Still, it only takes one link. You might want to look at the links to your wiki pages on GWT and see if you can spot any from outside the wiki.
Aug
27
comment How did Google find my unlinked newly created pages?
Actually, AFAIK, MediaWiki normally doesn't do that. But if you added the new pages to an existing wiki that Google knew about, then it could've reached them via any number of pages (e.g. Special:Recentchanges, Special:Allpages, Special:Random...).
Aug
27
comment How did Google find my unlinked newly created pages?
Are you using a CMS / wiki / blog / etc. platform of some kind? Some of those ping Google whenever you add new pages.
Aug
22
comment Adding direct advertisements to a mediawiki installation
I'm not sure why this was closed as "asking for recommendations", given that you explicitly say that you want to implement the ads yourself. Still, you question is kind of vague, but the general solution to "How do I add things to the sidebar?" is to use a SkinBuildSidebar hook.
Aug
22
comment One million redirects
+1. Of course, if you can write a program to generate the new URLs from the old ones, then you won't even need to store them in a database. (Also, if you do use a database, creating an index on the old URL column is highly recommended...)
Jul
24
comment With Robots.txt disallow all, why was my site still getting traffic?
Related, possibly duplicate: Why do Google search results include pages disallowed in robots.txt? (Disclosure: Asked and answered by me.)
Jul
21
comment How to implement an unspammable email address
In that case, ignore the lower part of my answer.
Jul
1
comment .htaccess file to implement multiple redirects
No, not without more information from you, I can't. Answer me this: Imagine that I'm your webserver. Given the URL domain.com/my-new-page, how am I supposed to tell that it should be rewritten to manual-page.php rather than to flights.php? If you can tell me that, maybe I can tell you how to program your actual webserver to do it.
Jul
1
comment .htaccess file to implement multiple redirects
@RobMorta: As I said, first you need to decide how you're going to tell the two kinds of clean URLs apart. Come back once you've figured that out.
Jul
1
comment Getting a lot of '/_' errors from webmaster tools
That's strange. This similar question and this answer to another related question suggest that these URLs might once have been linked from somewhere, and perhaps might have actually worked, and Google now keeps trying to recrawl them because it thinks there used to be something there. Sending a "410 Gone" response or redirecting them to a working URL might help, as might using the URL removal tool on Webmaster Tools.