If there is something you want to clarify about the item, you can use note (like the ID does not belong to people using it).
Discussion is for things more relevant to history of the item than the real device (like information source).
Both note and discussion is optional.';
- genHtmlTail();
+ genHtmlFooter( 1, $req, $args );
return OK;
}
my $addr = PciIds::Address::new( $req->uri() );
genCustomHead( $req, $args, $addr, 'ID collision', [ [ 'Add other item', 'newitem' ], $addr->canDiscuss() ? [ 'Discuss', 'newhistory' ] : (), ], [ logItem( $auth ) ] );
print '<p>Sorry, this ID already exists.';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
} elsif( $result ) {
return genNewItemForm( $req, $args, $auth, $tables, $result, $data );
You must provide at last name or discussion or deletion request.
<p>
If you provide note, you must provide name too.';
- genHtmlTail();
+ genHtmlFooter( 1, $req, $args );
return OK;
}
genHtmlHead( $req, 'Search results', undef );
print "<div class='top'>\n";
print "<h1>Search results</h1>\n";
- genMenu( $req, $address, $args, $auth, [ [ 'Help', 'help', 'jump' ], [ '', 'jump' ] ] );
+ genMenu( $req, $address, $args, $auth, [ [ 'Help', 'help', 'jump' ] ] );
print "<div class='clear'></div>\n";
print "</div>\n";
genPath( $req, $address, 1 );
return "<a href='$prefix".$address->get()."$suffix'>".encode( $address->fullPretty() )."</a>";
} ], sub { 1; }, sub { ' class="item"'; } );
genTableTail();
- genHtmlTail();
+ genHtmlFooter( 1, $req, $args );
return OK;
}
}
genForm( [ [ 'Email:', 'text', 'email', 'maxlength="255"' ],
[ '', 'submit', 'register', 'value="Register"' ] ], $values );
print '</table></form>';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
print '<p>
An email containing further information has been sent to you.
Please follow these instruction to finish the registration process.';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
[ 'Confirm password:', 'password', 'confirm_password' ],
[ '', 'submit', 'register', 'value=Register' ] ], $values );
print '</table></form>';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
An account for this address is already registered.
Please, reset or remember your password or start again with a different address.
</div>';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return 0;
}
This registration request is invalid.
Are you sure you got it from the registration email?
</div>';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return 0;
} elsif( $tables->hasEmail( $email ) ) {
return usedAddress( $req, $args );
genCustomHead( $req, $args, PciIds::Address::new( $req->uri() ), 'Registered', [ [ 'Help', 'help', 'account' ] ], [ [ 'Log in', 'login' ] ] );
print '<p>
You have registered successfully.';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
[ 'Password:', 'password', 'password' ],
[ '', 'submit', 'login', 'value="Login"' ] ], $values );
print '</table></form>';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
genForm( [ [ 'Email:', 'text', 'email', 'maxlength="255"' ],
[ '', 'submit', 'respass', 'value="Send"' ] ], $values );
print '</table></form>';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
genHtmlHead( $req, 'Reset password', undef );
genCustomHead( $req, $args, PciIds::Address::new( $req->uri() ), 'Reset password', [ [ 'Help', 'help', 'account' ] ], [ [ 'Log in', 'login' ] ] );
print "<p>An email with information has been sent to your address.\n";
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
} else {
$error = '<p>This email address is not registered. Check it for typos or register it.';
print "</table>";
print "<input type='hidden' name='email' value='".encode( $email )."'><input type='hidden' name='hash' value='".encode( $hash )."'>\n";
print "</form>\n";
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
print "<h1>Reset password</h1>\n";
print "<p>Provided link is not valid. Did you use it already?\n";
print "<p>You can get a <a href='".$req->uri()."?action=respass'>new one</a>.\n";
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
}
genHtmlHead( $req, 'Reset password', undef );
genCustomHead( $req, $args, PciIds::Address::new( $req->uri() ), 'Reset password', [ [ 'Help', 'help', 'account' ] ], [ [ 'Log in', 'login' ] ] );
print "<p>Your password was successfuly changed.\n";
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
} else {
return genResetPasswdConfigForm( $req, $args, $error, $data, $email, $hash );
[ 'Xmpp batch time (min):', 'text', 'xmpp_time', 'maxlength="10"' ],
[ '', 'submit', 'profile', 'value="Submit"' ] ], $data );
print '</table></form>';
- genHtmlTail();
+ genHtmlFooter( 0, undef, undef );
return OK;
}
use Apache2::Const qw(:common :http);
use APR::Table;
-our @EXPORT = qw(&genHtmlHead &htmlDiv &genHtmlTail &genTableHead &genTableTail &parseArgs &buildExcept &buildArgs &genMenu &genCustomMenu &encode &setAddrPrefix &HTTPRedirect &genPath &logItem &genLocMenu &genCustomHead &genPathBare &protoName);
+our @EXPORT = qw(&genHtmlHead &htmlDiv &genHtmlTail &genTableHead &genTableTail &parseArgs &buildExcept &buildArgs &genMenu &genCustomMenu &encode &setAddrPrefix &HTTPRedirect &genPath &logItem &genLocMenu &genCustomHead &genPathBare &protoName &genHtmlFooter);
sub encode( $ ) {
return encode_entities( shift, "\"'&<>" );
print '</body></html>';
}
+sub genHtmlFooter( $$$ ) {
+ my( $jump, $req, $args ) = @_;
+ if( $jump ) {
+ require PciIds::Html::Jump;
+ PciIds::Html::Jump::jumpWindow( $req, $args );
+ }
+ print '<hr>
+<table width="100%">
+<tr>
+<td>
+Maintained by <a href="http://mj.ucw.cz/">Martin Mares</a> and <a href="http://vorner.pretel.cz/">Michal
+Vaner</a> with great help by volunteers from the <a href="http://www.sourceforge.net/projects/pciids/">pciids project</a>
+at <a href="http://www.sourceforge.net/">SourceForge</a>.
+</td><td rowspan=2>
+<a href="http://www.anybrowser.org/campaign/"><img src="/static/anybrowser.png" width=88 height=31 alt="Best viewed with any browser."></a>
+</td><td rowspan=2>
+<a href="http://sourceforge.net/"><img src="http://sourceforge.net/sflogo.php?group_id=35833" width="88" height="31" border="0" alt="SourceForge"></a>
+</td></tr>
+<tr><td><span style="display: block">No counters, no frames, no syntax
+errors.</span></td></tr>
+</table>
+</div>';
+}
+
sub htmlDiv( $$ ) {
my( $class, $text ) = @_;
return '<div class="'.$class.'">'.$text.'</div>';