or download this
#!/usr/bin/env perl
use strict;
...
my $twig = XML::Twig -> new ( twig_roots => { 'Account' => \&parsing }
+ ); #'twig_roots' mode builds only the required sub-trees from the do
+cument while ignoring everything outside that twig.
$twig -> parsefile ($file);