Current script check-url.pl checks URL found in 856$u by sending HTTP
requests, one by one. The next request can't be sent before the previous
one get a result, which can be very slow for dead URL. I propose a new
script which send multiple requests simultaneously which improve
drastically URL checking execution time.
This script is based on AnyEvent and AnyEvent::HTTP CPAN modules.
Add new dependencies AnyEvent & AnyEvent::HTTP.
See doc: perldoc check-url-quick.pl
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Patch by Judit with a small change to the help wording.
Sponsored by CALYX information essentials.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
working through the master branch to eliminate all
podchecker warnings/errors
Actual improvement to the quality of the POD will
come later (hopefully with assistance of others)
Signed-off-by: Andrew Elwell <Andrew.Elwell@gmail.com>
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Based on David Schuster improvement patch.
For David:
- To send the output into an HTML file, there is no need to add a
paramater to this script, just redirect to a file:
check-url --html --host-prot=http://koha-pro.mylib.org \\
> /usr/local/koha/koha-tmpl/badurls.html
- If you want as a result a table with alternate rows, use CSS and
JavaScript. For example, with jQuery (found with google):
<style type="text/css">
table {width:400px; border:1px solid blue;}
.oddrow {background-color:#E5E5E5;}
</style>
<script type="text/javascript"
src="http://code.jquery.com/jquery-latest.min.js"></script>
<script type="text/javascript">
$(function(){
$("table.tiger-stripe tr:even").addClass("oddrow");
});
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
* removed ersataz YAML::XS dependency
* use 'return' instead of 'return undef'
* minor language changes
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Improve URLs checker script in the way (half way) pointed out by Galen:
- A C4::URL::Checker class handle URL checking. This class is not yet
in a separate file in C4 directory. This class would be easily
extended to accomodate authorities URLs checking.
- Script output can now be formatted in CSV or HTML. HTML version
link directly to MARC biblio record editor.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>