Skip to content

Instantly share code, notes, and snippets.

View dbolser's full-sized avatar
💭
Reversing the polarity

Dan B dbolser

💭
Reversing the polarity
View GitHub Profile
--
-- Table structure for table `Biodatabasepage`
--
DROP TABLE IF EXISTS `Biodatabasepage`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `Biodatabasepage` (
`page_id` int(8) unsigned NOT NULL AUTO_INCREMENT,
`page_namespace` int(11) NOT NULL,
<!-- login form -->
<form action="http://seqanswers.com/forums/login.php?do=login" method="post" onsubmit="md5hash(vb_login_password, vb_login_md5password, vb_login_md5password_utf, 0)">
<script type="text/javascript" src="http://seqanswers.com/forums/clientscript/vbulletin_md5.js?v=386"></script>
<table cellpadding="0" cellspacing="3" border="0">
<tr>
<td class="smallfont" style="white-space: nowrap;"><label for="navbar_username">User Name</label></td>
<td><input type="text" class="bginput" style="font-size: 11px" name="vb_login_username" id="navbar_username" size="10" accesskey="u" tabindex="101" value="User Name" onfocus="if (this.value == 'User Name') this.value = '';" /></td>
<td class="smallfont" nowrap="nowrap"><label for="cb_cookieuser_navbar"><input type="checkbox" name="cookieuser" value="1" tabindex="103" id="cb_cookieuser_navbar" accesskey="c" />Remember Me?</label></td>
</tr>
<tr>
@dbolser
dbolser / gist:1093841
Created July 19, 2011 21:58
Sort with missing values?
...
my @rows = sort spec @{$data{$_}};
print
join("\t", @{$_}[0..2,9,14,19]), "\n"
for @rows;
...
sub spec {
my @rowx = @$a;
#!/usr/bin/perl -w
use strict;
use HTML::TreeBuilder;
die "pass an HTML file\n"
unless @ARGV && -s $ARGV[0];
my $html_file = $ARGV[0];
[www@ml370 semantic-bundle]$ diff -u SemanticBundleSettings.sample.php~ SemanticBundleSettings.sample.php
--- SemanticBundleSettings.sample.php~ 2011-09-12 14:41:19.000000000 +0200
+++ SemanticBundleSettings.sample.php 2011-09-12 16:30:28.000000000 +0200
@@ -31,7 +31,7 @@
# More info: http://www.mediawiki.org/wiki/Extension:Semantic_Drilldown#Installation
#include_once( "$IP/extensions/SemanticDrilldown/SemanticDrilldown.php" );
-# Validator, Maps and Semantic Maps
+# Maps and Semantic Maps
# If you're planning to use Google Maps or Yahoo! Maps, you should also set
package TplPzr;
use strict;
use warnings;
use base qw( Parser::MGC );
use constant pattern_ident => qr{([[:alnum:]\w])+};
sub parse {
package TplPzr;
use strict;
use warnings;
use base qw( Parser::MGC );
#use constant pattern_ident => qr{([[:alnum:]\w])+};
sub parse {
sub{package TplPzr;
use strict;
use warnings;
use base qw( Parser::MGC );
## Extend the notion of an identifier to cover the values allowed by
## MediaWiki, see:
## http://www.mediawiki.org/wiki/Manual:Title.php#Article_name
## I'm going to use MediaWiki::API to load, so I'll install local::lib
## using cpanm.
## Step 1, install a local cpanm (and some deps)
curl -k -L http://cpanmin.us \
| perl - -l local-lib App::cpanminus
<?php
/**
*/
/**
*/
# Copyright (C) 2004 Brion Vibber <brion@pobox.com>
# http://www.mediawiki.org/
#
# This program is free software; you can redistribute it and/or modify