Apache-UploadMeter
view release on metacpan or search on metacpan
lib/Apache/UploadMeter/Resources/JavaScript.pm view on Meta::CPAN
setRequestHeaders: function() {
var headers = {
'X-Requested-With': 'XMLHttpRequest',
'X-Prototype-Version': Prototype.Version,
'Accept': 'text/javascript, text/html, application/xml, text/xml, */*'
};
if (this.method == 'post') {
headers['Content-type'] = this.options.contentType +
(this.options.encoding ? '; charset=' + this.options.encoding : '');
/* Force "Connection: close" for older Mozilla browsers to work
* around a bug where XMLHttpRequest sends an incorrect
* Content-length header. See Mozilla Bugzilla #246651.
*/
if (this.transport.overrideMimeType &&
(navigator.userAgent.match(/Gecko\/(\d{4})/) || [0,2005])[1] < 2005)
headers['Connection'] = 'close';
}
lib/Apache/UploadMeter/Resources/XML.pm view on Meta::CPAN
use strict;
use warnings;
use Apache2::RequestRec ();
use Apache2::RequestIO ();
use Apache2::Response ();
use Apache2::Const -compile=>qw(:common);
sub xsl {
my $r = shift;
$r->content_type("text/xml; charset=utf-8");
$r->set_etag();
return Apache2::Const::OK if $r->header_only();
my $output=<<'XSL-END';
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:output method="html" indent="yes" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"/>
<!-- root rule -->
<xsl:template match="/">
<xsl:apply-templates/>
</xsl:template>
lib/Apache/UploadMeter/Resources/XML.pm view on Meta::CPAN
</html>
</xsl:template>
</xsl:stylesheet>
XSL-END
$r->print($output);
return Apache2::Const::OK;
}
sub xsd {
my $r = shift;
$r->content_type("text/xml; charset=utf-8");
$r->set_etag();
return Apache2::Const::OK if $r->header_only();
my $output=<<'XSD-END';
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
<xs:element name="APACHE_UPLOADMETER">
<xs:complexType>
<xs:sequence>
<xs:element name="RECEIVED">
<xs:complexType>
( run in 0.236 second using v1.01-cache-2.11-cpan-4d50c553e7e )