sunspot_solr 2.2.2 → 2.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/sunspot-solr +2 -6
- data/lib/sunspot/solr/server.rb +2 -3
- data/solr/README.txt +181 -181
- data/solr/bin/post +29 -19
- data/solr/bin/solr +247 -428
- data/solr/bin/solr.cmd +102 -256
- data/solr/bin/solr.in.cmd +15 -7
- data/solr/bin/solr.in.sh +26 -12
- data/solr/server/README.txt +110 -113
- data/solr/server/contexts/solr-jetty-context.xml +8 -8
- data/solr/server/etc/jetty-http.xml +47 -0
- data/solr/server/etc/jetty-https-ssl.xml +175 -159
- data/solr/server/etc/jetty-https.xml +53 -0
- data/solr/server/etc/jetty-ssl.xml +46 -0
- data/solr/server/etc/jetty.xml +189 -167
- data/solr/server/etc/webdefault.xml +527 -527
- data/solr/server/lib/javax.servlet-api-3.1.0.jar +0 -0
- data/solr/server/lib/jetty-continuation-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-deploy-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-http-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-io-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-jmx-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-rewrite-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-security-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-server-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-servlet-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-servlets-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-util-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-webapp-9.2.11.v20150529.jar +0 -0
- data/solr/server/lib/jetty-xml-9.2.11.v20150529.jar +0 -0
- data/solr/server/modules/http.mod +9 -0
- data/solr/server/modules/https.mod +9 -0
- data/solr/server/modules/server.mod +11 -0
- data/solr/server/modules/ssl.mod +9 -0
- data/solr/server/resources/jetty-logging.properties +1 -0
- data/solr/server/resources/log4j.properties +24 -24
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/commons-exec-1.3.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/{hadoop-annotations-2.3.0.jar → hadoop-annotations-2.6.0.jar} +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/hadoop-auth-2.6.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/hadoop-common-2.6.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/hadoop-hdfs-2.6.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/htrace-core-3.0.4.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/httpclient-4.4.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/httpcore-4.4.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/httpmime-4.4.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/jackson-core-2.5.4.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/jackson-dataformat-smile-2.5.4.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/{lucene-analyzers-common-5.0.0.jar → lucene-analyzers-common-5.3.1.jar} +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/{lucene-analyzers-kuromoji-5.0.0.jar → lucene-analyzers-kuromoji-5.3.1.jar} +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/{lucene-analyzers-phonetic-5.0.0.jar → lucene-analyzers-phonetic-5.3.1.jar} +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-backward-codecs-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-codecs-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-core-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/{lucene-expressions-5.0.0.jar → lucene-expressions-5.3.1.jar} +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/{lucene-grouping-5.0.0.jar → lucene-grouping-5.3.1.jar} +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-highlighter-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-join-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-memory-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-misc-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-queries-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/{lucene-queryparser-5.0.0.jar → lucene-queryparser-5.3.1.jar} +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-sandbox-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-spatial-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-suggest-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/org.restlet-2.3.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/org.restlet.ext.servlet-2.3.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/solr-core-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/solr-solrj-5.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/t-digest-3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/web.xml +169 -181
- data/solr/server/solr-webapp/webapp/WEB-INF/weblogic.xml +28 -28
- data/solr/server/solr-webapp/webapp/admin.html +164 -163
- data/solr/server/solr-webapp/webapp/css/angular/analysis.css +304 -0
- data/solr/server/solr-webapp/webapp/css/angular/chosen.css +465 -0
- data/solr/server/solr-webapp/webapp/css/angular/cloud.css +398 -0
- data/solr/server/solr-webapp/webapp/css/angular/common.css +724 -0
- data/solr/server/solr-webapp/webapp/css/angular/cores.css +233 -0
- data/solr/server/solr-webapp/webapp/css/angular/dataimport.css +370 -0
- data/solr/server/solr-webapp/webapp/css/angular/documents.css +179 -0
- data/solr/server/solr-webapp/webapp/css/angular/files.css +53 -0
- data/solr/server/solr-webapp/webapp/css/angular/index.css +206 -0
- data/solr/server/solr-webapp/webapp/css/angular/logging.css +376 -0
- data/solr/server/solr-webapp/webapp/css/angular/menu.css +321 -0
- data/solr/server/solr-webapp/webapp/css/angular/plugins.css +212 -0
- data/solr/server/solr-webapp/webapp/css/angular/query.css +162 -0
- data/solr/server/solr-webapp/webapp/css/angular/replication.css +500 -0
- data/solr/server/solr-webapp/webapp/css/angular/schema-browser.css +567 -0
- data/solr/server/solr-webapp/webapp/css/angular/segments.css +173 -0
- data/solr/server/solr-webapp/webapp/css/angular/threads.css +161 -0
- data/solr/server/solr-webapp/webapp/css/chosen.css +421 -421
- data/solr/server/solr-webapp/webapp/css/styles/analysis.css +311 -311
- data/solr/server/solr-webapp/webapp/css/styles/cloud.css +410 -410
- data/solr/server/solr-webapp/webapp/css/styles/common.css +701 -701
- data/solr/server/solr-webapp/webapp/css/styles/cores.css +244 -244
- data/solr/server/solr-webapp/webapp/css/styles/dashboard.css +155 -155
- data/solr/server/solr-webapp/webapp/css/styles/dataimport.css +403 -403
- data/solr/server/solr-webapp/webapp/css/styles/documents.css +197 -197
- data/solr/server/solr-webapp/webapp/css/styles/files.css +54 -54
- data/solr/server/solr-webapp/webapp/css/styles/index.css +207 -207
- data/solr/server/solr-webapp/webapp/css/styles/java-properties.css +52 -52
- data/solr/server/solr-webapp/webapp/css/styles/logging.css +391 -391
- data/solr/server/solr-webapp/webapp/css/styles/menu.css +329 -328
- data/solr/server/solr-webapp/webapp/css/styles/plugins.css +195 -195
- data/solr/server/solr-webapp/webapp/css/styles/query.css +173 -173
- data/solr/server/solr-webapp/webapp/css/styles/replication.css +515 -515
- data/solr/server/solr-webapp/webapp/css/styles/schema-browser.css +578 -578
- data/solr/server/solr-webapp/webapp/css/styles/segments.css +145 -0
- data/solr/server/solr-webapp/webapp/css/styles/threads.css +172 -172
- data/solr/server/solr-webapp/webapp/img/chosen-sprite-2x.png +0 -0
- data/solr/server/solr-webapp/webapp/img/filetypes/README +27 -27
- data/solr/server/solr-webapp/webapp/img/solr.svg +39 -39
- data/solr/server/solr-webapp/webapp/index.html +208 -0
- data/solr/server/solr-webapp/webapp/js/angular/app.js +713 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/analysis.js +199 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/cloud.js +528 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/core-overview.js +225 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/cores.js +465 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/dataimport.js +284 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/documents.js +139 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/files.js +92 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/index.js +95 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/java-properties.js +45 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/logging.js +146 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/plugins.js +166 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/query.js +99 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/replication.js +227 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/schema-browser.js +432 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/segments.js +94 -0
- data/solr/server/solr-webapp/webapp/js/angular/controllers/threads.js +51 -0
- data/solr/server/solr-webapp/webapp/js/angular/services.js +214 -0
- data/solr/server/solr-webapp/webapp/js/lib/ZeroClipboard.js +342 -342
- data/solr/server/solr-webapp/webapp/js/lib/chosen.js +982 -982
- data/solr/server/solr-webapp/webapp/js/lib/console.js +29 -29
- data/solr/server/solr-webapp/webapp/js/lib/d3.js +9373 -9373
- data/solr/server/solr-webapp/webapp/js/lib/highlight.js +31 -31
- data/solr/server/solr-webapp/webapp/js/lib/jquery-1.7.2.min.js +30 -30
- data/solr/server/solr-webapp/webapp/js/lib/jquery.ajaxfileupload.js +184 -184
- data/solr/server/solr-webapp/webapp/js/lib/jquery.blockUI.js +523 -523
- data/solr/server/solr-webapp/webapp/js/lib/jquery.cookie.js +71 -71
- data/solr/server/solr-webapp/webapp/js/lib/jquery.form.js +806 -806
- data/solr/server/solr-webapp/webapp/js/lib/jquery.jstree.js +3534 -3534
- data/solr/server/solr-webapp/webapp/js/lib/jquery.sammy.js +1863 -1863
- data/solr/server/solr-webapp/webapp/js/lib/jquery.timeago.js +189 -189
- data/solr/server/solr-webapp/webapp/js/lib/linker.js +48 -48
- data/solr/server/solr-webapp/webapp/js/lib/naturalSort.js +82 -0
- data/solr/server/solr-webapp/webapp/js/lib/order.js +216 -216
- data/solr/server/solr-webapp/webapp/js/main.js +60 -58
- data/solr/server/solr-webapp/webapp/js/require.js +11349 -11349
- data/solr/server/solr-webapp/webapp/js/scripts/analysis.js +545 -545
- data/solr/server/solr-webapp/webapp/js/scripts/app.js +680 -679
- data/solr/server/solr-webapp/webapp/js/scripts/cloud.js +877 -877
- data/solr/server/solr-webapp/webapp/js/scripts/cores.js +719 -719
- data/solr/server/solr-webapp/webapp/js/scripts/dashboard.js +562 -562
- data/solr/server/solr-webapp/webapp/js/scripts/dataimport.js +812 -812
- data/solr/server/solr-webapp/webapp/js/scripts/documents.js +370 -370
- data/solr/server/solr-webapp/webapp/js/scripts/files.js +265 -265
- data/solr/server/solr-webapp/webapp/js/scripts/index.js +340 -340
- data/solr/server/solr-webapp/webapp/js/scripts/java-properties.js +106 -106
- data/solr/server/solr-webapp/webapp/js/scripts/logging.js +578 -576
- data/solr/server/solr-webapp/webapp/js/scripts/ping.js +72 -72
- data/solr/server/solr-webapp/webapp/js/scripts/plugins.js +462 -462
- data/solr/server/solr-webapp/webapp/js/scripts/query.js +229 -229
- data/solr/server/solr-webapp/webapp/js/scripts/replication.js +527 -527
- data/solr/server/solr-webapp/webapp/js/scripts/schema-browser.js +1229 -1229
- data/solr/server/solr-webapp/webapp/js/scripts/segments.js +206 -0
- data/solr/server/solr-webapp/webapp/js/scripts/threads.js +158 -158
- data/solr/server/solr-webapp/webapp/libs/angular-chosen.js +139 -0
- data/solr/server/solr-webapp/webapp/libs/angular-cookies.js +229 -0
- data/solr/server/solr-webapp/webapp/libs/angular-cookies.min.js +31 -0
- data/solr/server/solr-webapp/webapp/libs/angular-resource.min.js +36 -0
- data/solr/server/solr-webapp/webapp/libs/angular-route.js +1018 -0
- data/solr/server/solr-webapp/webapp/libs/angular-route.min.js +38 -0
- data/solr/server/solr-webapp/webapp/libs/angular-sanitize.js +703 -0
- data/solr/server/solr-webapp/webapp/libs/angular-sanitize.min.js +39 -0
- data/solr/server/solr-webapp/webapp/libs/angular.js +26093 -0
- data/solr/server/solr-webapp/webapp/libs/angular.min.js +273 -0
- data/solr/server/solr-webapp/webapp/libs/chosen.jquery.js +1194 -0
- data/solr/server/solr-webapp/webapp/libs/chosen.jquery.min.js +30 -0
- data/solr/server/solr-webapp/webapp/libs/d3.js +9373 -0
- data/solr/server/solr-webapp/webapp/libs/highlight.js +31 -0
- data/solr/server/solr-webapp/webapp/libs/jquery-2.1.3.min.js +29 -0
- data/solr/server/solr-webapp/webapp/libs/jquery.jstree.js +3534 -0
- data/solr/server/solr-webapp/webapp/libs/ngtimeago.js +102 -0
- data/solr/server/solr-webapp/webapp/partials/analysis.html +128 -0
- data/solr/server/solr-webapp/webapp/partials/cloud.html +104 -0
- data/solr/server/solr-webapp/webapp/partials/core_overview.html +227 -0
- data/solr/server/solr-webapp/webapp/partials/cores.html +231 -0
- data/solr/server/solr-webapp/webapp/partials/dataimport.html +209 -0
- data/solr/server/solr-webapp/webapp/partials/documents.html +118 -0
- data/solr/server/solr-webapp/webapp/partials/files.html +47 -0
- data/solr/server/solr-webapp/webapp/partials/index.html +261 -0
- data/solr/server/solr-webapp/webapp/partials/java-properties.html +27 -0
- data/solr/server/solr-webapp/webapp/partials/logging-levels.html +56 -0
- data/solr/server/solr-webapp/webapp/partials/logging.html +56 -0
- data/solr/server/solr-webapp/webapp/partials/plugins.html +72 -0
- data/solr/server/solr-webapp/webapp/partials/query.html +356 -0
- data/solr/server/solr-webapp/webapp/partials/replication.html +239 -0
- data/solr/server/solr-webapp/webapp/partials/schema-browser.html +206 -0
- data/solr/server/solr-webapp/webapp/partials/segments.html +99 -0
- data/solr/server/solr-webapp/webapp/partials/threads.html +65 -0
- data/solr/server/solr-webapp/webapp/tpl/analysis.html +83 -83
- data/solr/server/solr-webapp/webapp/tpl/cloud.html +87 -87
- data/solr/server/solr-webapp/webapp/tpl/cores.html +226 -226
- data/solr/server/solr-webapp/webapp/tpl/dashboard.html +201 -201
- data/solr/server/solr-webapp/webapp/tpl/dataimport.html +183 -183
- data/solr/server/solr-webapp/webapp/tpl/documents.html +107 -107
- data/solr/server/solr-webapp/webapp/tpl/files.html +44 -44
- data/solr/server/solr-webapp/webapp/tpl/index.html +250 -250
- data/solr/server/solr-webapp/webapp/tpl/logging.html +23 -23
- data/solr/server/solr-webapp/webapp/tpl/plugins.html +39 -39
- data/solr/server/solr-webapp/webapp/tpl/query.html +361 -361
- data/solr/server/solr-webapp/webapp/tpl/replication.html +216 -216
- data/solr/server/solr-webapp/webapp/tpl/schema-browser.html +192 -192
- data/solr/server/solr-webapp/webapp/tpl/segments.html +49 -0
- data/solr/server/solr-webapp/webapp/tpl/threads.html +56 -56
- data/solr/server/solr/README.txt +77 -77
- data/solr/server/solr/solr.xml +51 -51
- data/solr/server/solr/zoo.cfg +17 -17
- data/solr/server/start.jar +0 -0
- data/spec/server_spec.rb +3 -8
- metadata +132 -43
- data/solr/server/lib/jetty-continuation-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-deploy-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-http-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-io-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-jmx-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-security-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-server-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-servlet-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-util-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-webapp-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/jetty-xml-8.1.10.v20130312.jar +0 -0
- data/solr/server/lib/servlet-api-3.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/.gitignore +0 -1
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/hadoop-auth-2.3.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/hadoop-common-2.3.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/hadoop-hdfs-2.3.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/httpclient-4.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/httpcore-4.3.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/httpmime-4.3.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-backward-codecs-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-codecs-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-core-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-highlighter-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-join-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-memory-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-misc-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-queries-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-spatial-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/lucene-suggest-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/org.restlet-2.1.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/org.restlet.ext.servlet-2.1.1.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/solr-core-5.0.0.jar +0 -0
- data/solr/server/solr-webapp/webapp/WEB-INF/lib/solr-solrj-5.0.0.jar +0 -0
- data/solr/server/webapps/solr.war +0 -0
@@ -1,189 +1,189 @@
|
|
1
|
-
/*
|
2
|
-
|
3
|
-
The MIT License (MIT)
|
4
|
-
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
7
|
-
in the Software without restriction, including without limitation the rights
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
10
|
-
furnished to do so, subject to the following conditions:
|
11
|
-
|
12
|
-
The above copyright notice and this permission notice shall be included in
|
13
|
-
all copies or substantial portions of the Software.
|
14
|
-
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
-
THE SOFTWARE.
|
22
|
-
|
23
|
-
*/
|
24
|
-
|
25
|
-
/*
|
26
|
-
* timeago: a jQuery plugin, version: 0.9.3 (2011-01-21)
|
27
|
-
* @requires jQuery v1.2.3 or later
|
28
|
-
*
|
29
|
-
* Timeago is a jQuery plugin that makes it easy to support automatically
|
30
|
-
* updating fuzzy timestamps (e.g. "4 minutes ago" or "about 1 day ago").
|
31
|
-
*
|
32
|
-
* For usage and examples, visit:
|
33
|
-
* http://timeago.yarp.com/
|
34
|
-
*
|
35
|
-
* Licensed under the MIT:
|
36
|
-
* http://www.opensource.org/licenses/mit-license.php
|
37
|
-
*
|
38
|
-
* Copyright (c) 2008-2011, Ryan McGeary (ryanonjavascript -[at]- mcgeary [*dot*] org)
|
39
|
-
*/
|
40
|
-
|
41
|
-
(function($) {
|
42
|
-
$.timeago = function(timestamp) {
|
43
|
-
if (timestamp instanceof Date) {
|
44
|
-
return inWords(timestamp);
|
45
|
-
} else if (typeof timestamp === "string") {
|
46
|
-
return inWords($.timeago.parse(timestamp));
|
47
|
-
} else {
|
48
|
-
return inWords($.timeago.datetime(timestamp));
|
49
|
-
}
|
50
|
-
};
|
51
|
-
var $t = $.timeago;
|
52
|
-
|
53
|
-
$.extend($.timeago, {
|
54
|
-
settings: {
|
55
|
-
refreshMillis: 60000,
|
56
|
-
allowFuture: false,
|
57
|
-
strings: {
|
58
|
-
prefixAgo: null,
|
59
|
-
prefixFromNow: null,
|
60
|
-
suffixAgo: "ago",
|
61
|
-
suffixFromNow: "from now",
|
62
|
-
seconds: "less than a minute",
|
63
|
-
minute: "about a minute",
|
64
|
-
minutes: "%d minutes",
|
65
|
-
hour: "about an hour",
|
66
|
-
hours: "about %d hours",
|
67
|
-
day: "a day",
|
68
|
-
days: "%d days",
|
69
|
-
month: "about a month",
|
70
|
-
months: "%d months",
|
71
|
-
year: "about a year",
|
72
|
-
years: "%d years",
|
73
|
-
numbers: []
|
74
|
-
}
|
75
|
-
},
|
76
|
-
inWords: function(distanceMillis) {
|
77
|
-
var $l = this.settings.strings;
|
78
|
-
var prefix = $l.prefixAgo;
|
79
|
-
var suffix = $l.suffixAgo;
|
80
|
-
if (this.settings.allowFuture) {
|
81
|
-
if (distanceMillis < 0) {
|
82
|
-
prefix = $l.prefixFromNow;
|
83
|
-
suffix = $l.suffixFromNow;
|
84
|
-
}
|
85
|
-
distanceMillis = Math.abs(distanceMillis);
|
86
|
-
}
|
87
|
-
|
88
|
-
var seconds = distanceMillis / 1000;
|
89
|
-
var minutes = seconds / 60;
|
90
|
-
var hours = minutes / 60;
|
91
|
-
var days = hours / 24;
|
92
|
-
var years = days / 365;
|
93
|
-
|
94
|
-
function substitute(stringOrFunction, number) {
|
95
|
-
var string = $.isFunction(stringOrFunction) ? stringOrFunction(number, distanceMillis) : stringOrFunction;
|
96
|
-
var value = ($l.numbers && $l.numbers[number]) || number;
|
97
|
-
return string.replace(/%d/i, value);
|
98
|
-
}
|
99
|
-
|
100
|
-
var words = seconds < 45 && substitute($l.seconds, Math.round(seconds)) ||
|
101
|
-
seconds < 90 && substitute($l.minute, 1) ||
|
102
|
-
minutes < 45 && substitute($l.minutes, Math.round(minutes)) ||
|
103
|
-
minutes < 90 && substitute($l.hour, 1) ||
|
104
|
-
hours < 24 && substitute($l.hours, Math.round(hours)) ||
|
105
|
-
hours < 48 && substitute($l.day, 1) ||
|
106
|
-
days < 30 && substitute($l.days, Math.floor(days)) ||
|
107
|
-
days < 60 && substitute($l.month, 1) ||
|
108
|
-
days < 365 && substitute($l.months, Math.floor(days / 30)) ||
|
109
|
-
years < 2 && substitute($l.year, 1) ||
|
110
|
-
substitute($l.years, Math.floor(years));
|
111
|
-
|
112
|
-
return $.trim([prefix, words, suffix].join(" "));
|
113
|
-
},
|
114
|
-
parse: function(iso8601) {
|
115
|
-
var s = $.trim(iso8601);
|
116
|
-
s = s.replace(/\.\d\d\d+/,""); // remove milliseconds
|
117
|
-
s = s.replace(/-/g,"/");
|
118
|
-
s = s.replace(/(\d)T(\d)/,"$1 $2").replace(/(\d)Z/,"$1 UTC");
|
119
|
-
s = s.replace(/([\+\-]\d\d)\:?(\d\d)/," $1$2"); // -04:00 -> -0400
|
120
|
-
return new Date(s);
|
121
|
-
},
|
122
|
-
datetime: function(elem) {
|
123
|
-
// jQuery's `is()` doesn't play well with HTML5 in IE
|
124
|
-
var isTime = $(elem).get(0).tagName.toLowerCase() === "time"; // $(elem).is("time");
|
125
|
-
|
126
|
-
var iso8601 = null;
|
127
|
-
|
128
|
-
if( isTime )
|
129
|
-
{
|
130
|
-
iso8601 = $(elem).attr("datetime");
|
131
|
-
}
|
132
|
-
|
133
|
-
if( !iso8601 )
|
134
|
-
{
|
135
|
-
iso8601 = $(elem).attr("title");
|
136
|
-
}
|
137
|
-
|
138
|
-
if( !iso8601 )
|
139
|
-
{
|
140
|
-
iso8601 = $(elem).text();
|
141
|
-
}
|
142
|
-
|
143
|
-
return $t.parse(iso8601);
|
144
|
-
}
|
145
|
-
});
|
146
|
-
|
147
|
-
$.fn.timeago = function() {
|
148
|
-
var self = this;
|
149
|
-
self.each(refresh);
|
150
|
-
|
151
|
-
var $s = $t.settings;
|
152
|
-
if ($s.refreshMillis > 0) {
|
153
|
-
setInterval(function() { self.each(refresh); }, $s.refreshMillis);
|
154
|
-
}
|
155
|
-
return self;
|
156
|
-
};
|
157
|
-
|
158
|
-
function refresh() {
|
159
|
-
var data = prepareData(this);
|
160
|
-
if (!isNaN(data.datetime)) {
|
161
|
-
$(this).text(inWords(data.datetime));
|
162
|
-
}
|
163
|
-
return this;
|
164
|
-
}
|
165
|
-
|
166
|
-
function prepareData(element) {
|
167
|
-
element = $(element);
|
168
|
-
if (!element.data("timeago")) {
|
169
|
-
element.data("timeago", { datetime: $t.datetime(element) });
|
170
|
-
var text = $.trim(element.text());
|
171
|
-
if (text.length > 0) {
|
172
|
-
element.attr("title", text);
|
173
|
-
}
|
174
|
-
}
|
175
|
-
return element.data("timeago");
|
176
|
-
}
|
177
|
-
|
178
|
-
function inWords(date) {
|
179
|
-
return $t.inWords(distance(date));
|
180
|
-
}
|
181
|
-
|
182
|
-
function distance(date) {
|
183
|
-
return (new Date().getTime() - date.getTime());
|
184
|
-
}
|
185
|
-
|
186
|
-
// fix for IE6 suckage
|
187
|
-
document.createElement("abbr");
|
188
|
-
document.createElement("time");
|
189
|
-
}(jQuery));
|
1
|
+
/*
|
2
|
+
|
3
|
+
The MIT License (MIT)
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
22
|
+
|
23
|
+
*/
|
24
|
+
|
25
|
+
/*
|
26
|
+
* timeago: a jQuery plugin, version: 0.9.3 (2011-01-21)
|
27
|
+
* @requires jQuery v1.2.3 or later
|
28
|
+
*
|
29
|
+
* Timeago is a jQuery plugin that makes it easy to support automatically
|
30
|
+
* updating fuzzy timestamps (e.g. "4 minutes ago" or "about 1 day ago").
|
31
|
+
*
|
32
|
+
* For usage and examples, visit:
|
33
|
+
* http://timeago.yarp.com/
|
34
|
+
*
|
35
|
+
* Licensed under the MIT:
|
36
|
+
* http://www.opensource.org/licenses/mit-license.php
|
37
|
+
*
|
38
|
+
* Copyright (c) 2008-2011, Ryan McGeary (ryanonjavascript -[at]- mcgeary [*dot*] org)
|
39
|
+
*/
|
40
|
+
|
41
|
+
(function($) {
|
42
|
+
$.timeago = function(timestamp) {
|
43
|
+
if (timestamp instanceof Date) {
|
44
|
+
return inWords(timestamp);
|
45
|
+
} else if (typeof timestamp === "string") {
|
46
|
+
return inWords($.timeago.parse(timestamp));
|
47
|
+
} else {
|
48
|
+
return inWords($.timeago.datetime(timestamp));
|
49
|
+
}
|
50
|
+
};
|
51
|
+
var $t = $.timeago;
|
52
|
+
|
53
|
+
$.extend($.timeago, {
|
54
|
+
settings: {
|
55
|
+
refreshMillis: 60000,
|
56
|
+
allowFuture: false,
|
57
|
+
strings: {
|
58
|
+
prefixAgo: null,
|
59
|
+
prefixFromNow: null,
|
60
|
+
suffixAgo: "ago",
|
61
|
+
suffixFromNow: "from now",
|
62
|
+
seconds: "less than a minute",
|
63
|
+
minute: "about a minute",
|
64
|
+
minutes: "%d minutes",
|
65
|
+
hour: "about an hour",
|
66
|
+
hours: "about %d hours",
|
67
|
+
day: "a day",
|
68
|
+
days: "%d days",
|
69
|
+
month: "about a month",
|
70
|
+
months: "%d months",
|
71
|
+
year: "about a year",
|
72
|
+
years: "%d years",
|
73
|
+
numbers: []
|
74
|
+
}
|
75
|
+
},
|
76
|
+
inWords: function(distanceMillis) {
|
77
|
+
var $l = this.settings.strings;
|
78
|
+
var prefix = $l.prefixAgo;
|
79
|
+
var suffix = $l.suffixAgo;
|
80
|
+
if (this.settings.allowFuture) {
|
81
|
+
if (distanceMillis < 0) {
|
82
|
+
prefix = $l.prefixFromNow;
|
83
|
+
suffix = $l.suffixFromNow;
|
84
|
+
}
|
85
|
+
distanceMillis = Math.abs(distanceMillis);
|
86
|
+
}
|
87
|
+
|
88
|
+
var seconds = distanceMillis / 1000;
|
89
|
+
var minutes = seconds / 60;
|
90
|
+
var hours = minutes / 60;
|
91
|
+
var days = hours / 24;
|
92
|
+
var years = days / 365;
|
93
|
+
|
94
|
+
function substitute(stringOrFunction, number) {
|
95
|
+
var string = $.isFunction(stringOrFunction) ? stringOrFunction(number, distanceMillis) : stringOrFunction;
|
96
|
+
var value = ($l.numbers && $l.numbers[number]) || number;
|
97
|
+
return string.replace(/%d/i, value);
|
98
|
+
}
|
99
|
+
|
100
|
+
var words = seconds < 45 && substitute($l.seconds, Math.round(seconds)) ||
|
101
|
+
seconds < 90 && substitute($l.minute, 1) ||
|
102
|
+
minutes < 45 && substitute($l.minutes, Math.round(minutes)) ||
|
103
|
+
minutes < 90 && substitute($l.hour, 1) ||
|
104
|
+
hours < 24 && substitute($l.hours, Math.round(hours)) ||
|
105
|
+
hours < 48 && substitute($l.day, 1) ||
|
106
|
+
days < 30 && substitute($l.days, Math.floor(days)) ||
|
107
|
+
days < 60 && substitute($l.month, 1) ||
|
108
|
+
days < 365 && substitute($l.months, Math.floor(days / 30)) ||
|
109
|
+
years < 2 && substitute($l.year, 1) ||
|
110
|
+
substitute($l.years, Math.floor(years));
|
111
|
+
|
112
|
+
return $.trim([prefix, words, suffix].join(" "));
|
113
|
+
},
|
114
|
+
parse: function(iso8601) {
|
115
|
+
var s = $.trim(iso8601);
|
116
|
+
s = s.replace(/\.\d\d\d+/,""); // remove milliseconds
|
117
|
+
s = s.replace(/-/g,"/");
|
118
|
+
s = s.replace(/(\d)T(\d)/,"$1 $2").replace(/(\d)Z/,"$1 UTC");
|
119
|
+
s = s.replace(/([\+\-]\d\d)\:?(\d\d)/," $1$2"); // -04:00 -> -0400
|
120
|
+
return new Date(s);
|
121
|
+
},
|
122
|
+
datetime: function(elem) {
|
123
|
+
// jQuery's `is()` doesn't play well with HTML5 in IE
|
124
|
+
var isTime = $(elem).get(0).tagName.toLowerCase() === "time"; // $(elem).is("time");
|
125
|
+
|
126
|
+
var iso8601 = null;
|
127
|
+
|
128
|
+
if( isTime )
|
129
|
+
{
|
130
|
+
iso8601 = $(elem).attr("datetime");
|
131
|
+
}
|
132
|
+
|
133
|
+
if( !iso8601 )
|
134
|
+
{
|
135
|
+
iso8601 = $(elem).attr("title");
|
136
|
+
}
|
137
|
+
|
138
|
+
if( !iso8601 )
|
139
|
+
{
|
140
|
+
iso8601 = $(elem).text();
|
141
|
+
}
|
142
|
+
|
143
|
+
return $t.parse(iso8601);
|
144
|
+
}
|
145
|
+
});
|
146
|
+
|
147
|
+
$.fn.timeago = function() {
|
148
|
+
var self = this;
|
149
|
+
self.each(refresh);
|
150
|
+
|
151
|
+
var $s = $t.settings;
|
152
|
+
if ($s.refreshMillis > 0) {
|
153
|
+
setInterval(function() { self.each(refresh); }, $s.refreshMillis);
|
154
|
+
}
|
155
|
+
return self;
|
156
|
+
};
|
157
|
+
|
158
|
+
function refresh() {
|
159
|
+
var data = prepareData(this);
|
160
|
+
if (!isNaN(data.datetime)) {
|
161
|
+
$(this).text(inWords(data.datetime));
|
162
|
+
}
|
163
|
+
return this;
|
164
|
+
}
|
165
|
+
|
166
|
+
function prepareData(element) {
|
167
|
+
element = $(element);
|
168
|
+
if (!element.data("timeago")) {
|
169
|
+
element.data("timeago", { datetime: $t.datetime(element) });
|
170
|
+
var text = $.trim(element.text());
|
171
|
+
if (text.length > 0) {
|
172
|
+
element.attr("title", text);
|
173
|
+
}
|
174
|
+
}
|
175
|
+
return element.data("timeago");
|
176
|
+
}
|
177
|
+
|
178
|
+
function inWords(date) {
|
179
|
+
return $t.inWords(distance(date));
|
180
|
+
}
|
181
|
+
|
182
|
+
function distance(date) {
|
183
|
+
return (new Date().getTime() - date.getTime());
|
184
|
+
}
|
185
|
+
|
186
|
+
// fix for IE6 suckage
|
187
|
+
document.createElement("abbr");
|
188
|
+
document.createElement("time");
|
189
|
+
}(jQuery));
|
@@ -1,48 +1,48 @@
|
|
1
|
-
//by Michalis Tzikas & Vasilis Lolos
|
2
|
-
//07-03-2012
|
3
|
-
//v1.0
|
4
|
-
/*
|
5
|
-
Copyright (C) 2011 by Michalis Tzikas & Vasilis Lolos
|
6
|
-
|
7
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
8
|
-
of this software and associated documentation files (the "Software"), to deal
|
9
|
-
in the Software without restriction, including without limitation the rights
|
10
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
11
|
-
copies of the Software, and to permit persons to whom the Software is
|
12
|
-
furnished to do so, subject to the following conditions:
|
13
|
-
|
14
|
-
The above copyright notice and this permission notice shall be included in
|
15
|
-
all copies or substantial portions of the Software.
|
16
|
-
|
17
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
18
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
19
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
20
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
21
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
22
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
23
|
-
THE SOFTWARE.
|
24
|
-
*/
|
25
|
-
(function( $ ){
|
26
|
-
$.fn.linker = function(options) {
|
27
|
-
var defaults = {
|
28
|
-
target : '', //blank,self,parent,top
|
29
|
-
className : '',
|
30
|
-
rel : ''
|
31
|
-
};
|
32
|
-
var options = $.extend(defaults, options);
|
33
|
-
|
34
|
-
target_string = (options.target != '') ? 'target="_'+options.target+'"' : '';
|
35
|
-
class_string = (options.className != '') ? 'class="'+options.className+'"' : '';
|
36
|
-
rel_string = (options.rel != '') ? 'rel="'+options.rel+'"' : '';
|
37
|
-
|
38
|
-
$(this).each(function(){
|
39
|
-
t = $(this).text();
|
40
|
-
|
41
|
-
t = t.replace(/(https\:\/\/|http:\/\/)([www\.]?)([^\s|<]+)/gi,'<a href="$1$2$3" '+target_string+' '+class_string+' '+rel_string+'>$1$2$3</a>');
|
42
|
-
t = t.replace(/([^https\:\/\/]|[^http:\/\/]|^)(www)\.([^\s|<]+)/gi,'$1<a href="http://$2.$3" '+target_string+' '+class_string+' '+rel_string+'>$2.$3</a>');
|
43
|
-
t = t.replace(/<([^a]|^\/a])([^<>]+)>/g, "<$1$2>").replace(/<\/a>/g, "</a>").replace(/<(.)>/g, "<$1>").replace(/\n/g, '<br />');
|
44
|
-
|
45
|
-
$(this).html(t);
|
46
|
-
});
|
47
|
-
};
|
48
|
-
})( jQuery );
|
1
|
+
//by Michalis Tzikas & Vasilis Lolos
|
2
|
+
//07-03-2012
|
3
|
+
//v1.0
|
4
|
+
/*
|
5
|
+
Copyright (C) 2011 by Michalis Tzikas & Vasilis Lolos
|
6
|
+
|
7
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
8
|
+
of this software and associated documentation files (the "Software"), to deal
|
9
|
+
in the Software without restriction, including without limitation the rights
|
10
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
11
|
+
copies of the Software, and to permit persons to whom the Software is
|
12
|
+
furnished to do so, subject to the following conditions:
|
13
|
+
|
14
|
+
The above copyright notice and this permission notice shall be included in
|
15
|
+
all copies or substantial portions of the Software.
|
16
|
+
|
17
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
18
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
19
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
20
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
21
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
22
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
23
|
+
THE SOFTWARE.
|
24
|
+
*/
|
25
|
+
(function( $ ){
|
26
|
+
$.fn.linker = function(options) {
|
27
|
+
var defaults = {
|
28
|
+
target : '', //blank,self,parent,top
|
29
|
+
className : '',
|
30
|
+
rel : ''
|
31
|
+
};
|
32
|
+
var options = $.extend(defaults, options);
|
33
|
+
|
34
|
+
target_string = (options.target != '') ? 'target="_'+options.target+'"' : '';
|
35
|
+
class_string = (options.className != '') ? 'class="'+options.className+'"' : '';
|
36
|
+
rel_string = (options.rel != '') ? 'rel="'+options.rel+'"' : '';
|
37
|
+
|
38
|
+
$(this).each(function(){
|
39
|
+
t = $(this).text();
|
40
|
+
|
41
|
+
t = t.replace(/(https\:\/\/|http:\/\/)([www\.]?)([^\s|<]+)/gi,'<a href="$1$2$3" '+target_string+' '+class_string+' '+rel_string+'>$1$2$3</a>');
|
42
|
+
t = t.replace(/([^https\:\/\/]|[^http:\/\/]|^)(www)\.([^\s|<]+)/gi,'$1<a href="http://$2.$3" '+target_string+' '+class_string+' '+rel_string+'>$2.$3</a>');
|
43
|
+
t = t.replace(/<([^a]|^\/a])([^<>]+)>/g, "<$1$2>").replace(/<\/a>/g, "</a>").replace(/<(.)>/g, "<$1>").replace(/\n/g, '<br />');
|
44
|
+
|
45
|
+
$(this).html(t);
|
46
|
+
});
|
47
|
+
};
|
48
|
+
})( jQuery );
|