Net::Lujoyglamour is a model/control part of a framework intended for creating short URLs. Inherits from DBIx::Class; adds functionality for creating a keeping a table of long/short URLs. Funky name comes from the novel lujoyglamour.net , in Spanish, which I also wrote (and obtained a literary price), and you can check out at http://lujoyglamour.es or buy at http://compra.lujoyglamour.net.
The module has been tested with SQLite and MySQL, and is in fact running using both. You just need to change the $dsn for using either. It hasn't been tested using other databases; would be grateful if anybody tried/patched for these.
SYNOPSIS
use Net::Lujoyglamour qw(is_valid);
#Deploy database
my $dsn = 'dbi:SQLite:dbname=:memory:';
my $schema = Net::Lujoyglamour->connect($dsn);
$schema->deploy({ add_drop_tables => 1});
#Most straighforward way to use
if ( is_valid( "shortie" ) {
$schema->create_new_short( "very.long.url/like/this",
"shortie" );
}
$schema->create_new_short( "even.longer.url/this/and/that" );
Product's homepage
Requirements:
· Perl