Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Seo #942

Closed
wants to merge 10 commits into from
Closed

Seo #942

Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ public TilesConfigurer tilesConfigurer() {
public void addResourceHandlers(ResourceHandlerRegistry registry) {
registry.addResourceHandler("/static/**").addResourceLocations("/WEB-INF/static/").setCachePeriod(3600*24*7);
registry.addResourceHandler("/robots.txt").addResourceLocations("/WEB-INF/").setCachePeriod(0);
registry.addResourceHandler("/sitemap.xml").addResourceLocations("/WEB-INF/sitemap.xml").setCachePeriod(0);
registry.addResourceHandler("/files/judgments/**").addResourceLocations(ResourceUtils.FILE_URL_PREFIX + judgmentsContentPath).setCachePeriod(600);

}
Expand Down
22 changes: 18 additions & 4 deletions saos-webapp/src/main/resources/message/common.properties
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ button.resetForm = Czyść formularz
button.close = Zamknij
button.look = Zobacz

meta.language = english

saos.logo.alt = portal orzeczeń polskiego sądownictwa

message.noJavascript = Obsługa języka JavaScript w przeglądarce internetowej jest wyłączona. Włącz ponownie JavaScript, aby korzystać z pełnej funkcjonalności serwisu.

/* Page titles */
Expand Down Expand Up @@ -153,7 +157,8 @@ judgment.judgmentResult = Skrócony wynik sprawy
judgment.lowerCourtJudgments = Wyroki sądu niższej instancji

/* Labels for landing page aka home */
home.meta.pageDescription = Codziennie aktualizowana otwarta baza orzeczeń polskich sądów. Szukaj, przeglądaj, analizuj.
home.meta.pageDescription = Codziennie aktualizowana otwarta baza orzeczeń polskich sądów. Szukaj, przeglądaj, analizuj orzeczenia i wyroki sądowe.
home.meta.keywords = orzeczenia, saos, system analizy orzeczeń sądowych, wyroki sądowe, baza orzeczeń, orzecnictwo sądów powszechnych, orzeczenia sn, orzeczenia kio, orzeczenia tk, portal orzeczeń
home.beta.message = Serwis znajduje się obecnie w fazie testów i dodawania ostatnich drobnych funkcjonalności. Będziemy bardzo wdzięczni za wszelkie uwagi i sugestie dotyczące działania serwisu. Prosimy o przesyłanie wszelkich opinii na adres
home.welcome.text = Serwis SAOS gromadzi i udostępnia dane orzeczeń polskich sądów. Ułatwia ich przeszukiwanie, przeglądanie oraz zbiorczą analizę. Umożliwia również pobranie metadanych i treści wszystkich zgromadzonych orzeczeń poprzez programowe API.
home.header.idea = Idea Serwisu
Expand All @@ -164,9 +169,9 @@ home.navigation.api = Programowe API
home.navigation.search.desc = Wyszukiwanie i przeglądanie orzeczeń.
home.navigation.analysis.desc = Analiza zbiorcza zgromadzonych danych.
home.navigation.api.desc = Punkt wejścia serwisów API REST<br />(dla programistów).
home.navigation.search.imageAlt = "Ikona lupy"
home.navigation.analysis.imageAlt = "Ikona wykresu"
home.navigation.api.imageAlt = "Ikona tagu"
home.navigation.search.imageAlt = Ikona lupy
home.navigation.analysis.imageAlt = Ikona wykresu
home.navigation.api.imageAlt = Ikona tagu


partners.icm.imageAlt = Logo ICM i napis UNIWERSYTET WARSZAWSKI - przeniesienie do strony ICM
Expand All @@ -187,6 +192,7 @@ context.date.anyValue = Dowolna

/* Judgment search view */
search.meta.pageDescription = Wyszukiwarka orzeczeń sądowych. Przeszukuj setki tysięcy orzeczeń polskich sądów wg dowolnych kryteriów.
search.meta.keywords = wyszukiwarka, wyszukiwarka orzeczeń, orzeczenia, saos, system analizy orzeczeń sądowych, wyroki sądowe, baza orzeczeń, orzecnictwo sądów powszechnych, orzeczenia sn, orzeczenia kio, orzeczenia tk, portal orzeczeń
judgmentSearch.form.header = Wyszukiwarka
judgmentSearch.form.moreFields = Zobacz dodatkowe pola wyszukiwania
judgmentSearch.form.lessFields = Ukryj dodatkowe pola wyszukiwania
Expand Down Expand Up @@ -288,6 +294,13 @@ courtCriteriaFormSection.hint.administrativeCourt.content = Dane nie zostały na


/* Judgment details view */
details.meta.judgment = Orzeczenie
details.meta.decisionReleasedBy = wydane przez
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest to name these: releasedBy.neuter, releasedBy.feminine, releasedBy.masculine. Different judgment types can share these keys.

details.meta.resolutionReleasedBy = wydana przez
details.meta.sentenceReleasedBy = wydany przez
details.meta.withSignature = o sygnaturze
details.meta.containing = w składzie sędziowskim
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a strange name of the key, I suggest details.meta.judges

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👌

judgmentDetails.meta.keywords = orzeczenie, portal orzeczeń
judgmentDetails.button.fullText = Zobacz pełny tekst orzeczenia
judgmentDetails.header = Orzeczenie
judgmentDetails.judgmentFullText = Pełny tekst orzeczenia
Expand Down Expand Up @@ -355,6 +368,7 @@ judgmentDetails.linkTooltip.referencedRegulations = Pokaż orzeczenia z takim po

/* Analysis */
analysis.meta.pageDescription = Wizualna analiza orzeczeń sądowych. Badaj, porównuj i analizuj trendy w polskim orzecznictwie.
analysis.meta.keywords = analiza, analiza orzeczeń, orzeczenia, saos, system analizy orzeczeń sądowych, wyroki sądowe, baza orzeczeń, orzecnictwo sądów powszechnych, orzeczenia sn, orzeczenia kio, orzeczenia tk, portal orzeczeń
analysis.header = Kryteria analizy
analysis.skipLinks.analysis = Go to analysis form
analysis.skipLinks.charts = Go to charts
Expand Down
22 changes: 18 additions & 4 deletions saos-webapp/src/main/resources/message/common_pl.properties
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ button.resetForm = Czyść formularz
button.close = Zamknij
button.look = Zobacz

meta.language = polish

saos.logo.alt = portal orzeczeń polskiego sądownictwa

message.noJavascript = Obsługa języka JavaScript w przeglądarce internetowej jest wyłączona. Włącz ponownie JavaScript, aby korzystać z pełnej funkcjonalności serwisu.

/* Page titles */
Expand Down Expand Up @@ -153,7 +157,8 @@ judgment.judgmentResult = Skrócony wynik sprawy
judgment.lowerCourtJudgments = Wyroki sądu niższej instancji

/* Labels for landing page aka home */
home.meta.pageDescription = Codziennie aktualizowana otwarta baza orzeczeń polskich sądów. Szukaj, przeglądaj, analizuj.
home.meta.pageDescription = Codziennie aktualizowana otwarta baza orzeczeń polskich sądów. Szukaj, przeglądaj, analizuj orzeczenia i wyroki sądowe.
home.meta.keywords = orzeczenia, saos, system analizy orzeczeń sądowych, wyroki sądowe, baza orzeczeń, orzecnictwo sądów powszechnych, orzeczenia sn, orzeczenia kio, orzeczenia tk, portal orzeczeń
home.beta.message = Serwis znajduje się obecnie w fazie testów i dodawania ostatnich drobnych funkcjonalności. Będziemy bardzo wdzięczni za wszelkie uwagi i sugestie dotyczące działania serwisu. Prosimy o przesyłanie wszelkich opinii na adres
home.welcome.text = Serwis SAOS gromadzi i udostępnia dane orzeczeń polskich sądów. Ułatwia ich przeszukiwanie, przeglądanie oraz zbiorczą analizę. Umożliwia również pobranie metadanych i treści wszystkich zgromadzonych orzeczeń poprzez programowe API.
home.header.idea = Idea Serwisu
Expand All @@ -164,9 +169,9 @@ home.navigation.api = Programowe API
home.navigation.search.desc = Wyszukiwanie i przeglądanie orzeczeń.
home.navigation.analysis.desc = Analiza zbiorcza zgromadzonych danych.
home.navigation.api.desc = Punkt wejścia serwisów API REST<br />(dla programistów).
home.navigation.search.imageAlt = "Ikona lupy"
home.navigation.analysis.imageAlt = "Ikona wykresu"
home.navigation.api.imageAlt = "Ikona tagu"
home.navigation.search.imageAlt = Ikona lupy
home.navigation.analysis.imageAlt = Ikona wykresu
home.navigation.api.imageAlt = Ikona tagu

partners.icm.imageAlt = Logo ICM i napis UNIWERSYTET WARSZAWSKI - przeniesienie do strony ICM
partners.ncbir.imageAlt = Logo Narodowego Centrum Badań i Rozwoju - kliknij aby przejść do strony
Expand All @@ -186,6 +191,7 @@ context.date.anyValue = Dowolna

/* Judgment search view */
search.meta.pageDescription = Wyszukiwarka orzeczeń sądowych. Przeszukuj setki tysięcy orzeczeń polskich sądów wg dowolnych kryteriów.
search.meta.keywords = wyszukiwarka, wyszukiwarka orzeczeń, orzeczenia, saos, system analizy orzeczeń sądowych, wyroki sądowe, baza orzeczeń, orzecnictwo sądów powszechnych, orzeczenia sn, orzeczenia kio, orzeczenia tk, portal orzeczeń
judgmentSearch.form.header = Wyszukiwarka
judgmentSearch.form.moreFields = Zobacz dodatkowe pola wyszukiwania
judgmentSearch.form.lessFields = Ukryj dodatkowe pola wyszukiwania
Expand Down Expand Up @@ -287,6 +293,13 @@ courtCriteriaFormSection.hint.administrativeCourt.content = Dane nie zostały na


/* Judgment details view */
details.meta.judgment = Orzeczenie
details.meta.decisionReleasedBy = wydane przez
details.meta.resolutionReleasedBy = wydana przez
details.meta.sentenceReleasedBy = wydany przez
details.meta.withSignature = o sygnaturze
details.meta.containing = w składzie sędziowskim
judgmentDetails.meta.keywords = orzeczenie, portal orzeczeń
judgmentDetails.button.fullText = Zobacz pełny tekst orzeczenia
judgmentDetails.header = Orzeczenie
judgmentDetails.judgmentFullText = Pełny tekst orzeczenia
Expand Down Expand Up @@ -354,6 +367,7 @@ judgmentDetails.linkTooltip.referencedRegulations = Pokaż orzeczenia z takim po

/* Analysis */
analysis.meta.pageDescription = Wizualna analiza orzeczeń sądowych. Badaj, porównuj i analizuj trendy w polskim orzecznictwie.
analysis.meta.keywords = analiza, analiza orzeczeń, orzeczenia, saos, system analizy orzeczeń sądowych, wyroki sądowe, baza orzeczeń, orzecnictwo sądów powszechnych, orzeczenia sn, orzeczenia kio, orzeczenia tk, portal orzeczeń
analysis.header = Kryteria analizy
analysis.skipLinks.analysis = Przejdź do formularza analizy
analysis.skipLinks.charts = Przejdź do wykresów
Expand Down
5 changes: 4 additions & 1 deletion saos-webapp/src/main/resources/saos.default.properties
Original file line number Diff line number Diff line change
Expand Up @@ -96,4 +96,7 @@ piwik.siteId = 0


# ehcache configuration file path
ehcache.configurationFilePath = classpath:ehcache.xml
ehcache.configurationFilePath = classpath:ehcache.xml

# domain name
domain.name = https://saos.org.pl
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should have here https://www.saos.org.pl
It would be better to propagate this address because it doesn't need a redirect when invoked.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And, the domain name should be taken from request rather than to be const string (the same for every saos instance), see the usage of HttpServletRequestUtils.

2 changes: 1 addition & 1 deletion saos-webapp/src/main/resources/saos.version.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#Generated by Gradle
saos.version=0.9.5
saos.version=0.9.6-SNAPSHOT
23 changes: 23 additions & 0 deletions saos-webapp/src/main/webapp/WEB-INF/sitemap.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://www.saos.org.pl/</loc>
<lastmod>2015-09-30</lastmod>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the loc should be configured, you'll have the same value for test and devel env

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have to talk about it a bit.

<changefreq>weekly</changefreq>
</url>
<url>
<loc>https://www.saos.org.pl/search</loc>
<lastmod>2015-09-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://www.saos.org.pl/analysis</loc>
<lastmod>2015-09-30</lastmod>
<changefreq>weekly</changefreq>
</url>
<url>
<loc>https://www.saos.org.pl/help</loc>
<lastmod>2015-09-30</lastmod>
<changefreq>daily</changefreq>
</url>
</urlset>
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,6 @@
*/
var jsInitInJudgmentDetails = function(options) {


if (options.pageTitle !== undefined) {
$(document).attr("title", options.pageTitle + " " + $(document).attr("title"));
}


//Corrections info section
$("#corrections-toggle").click(function() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ a, .hint {
padding: 70px;
}

div.welcome-text {
h2.welcome-text {
bottom: 0;
color: $white;
font: {
Expand Down Expand Up @@ -355,7 +355,6 @@ a, .hint {
}

.saos-logo {
@include background-image("saosLogoNoText.png");
background-size: 300px auto;
background-repeat: no-repeat;
cursor: pointer;
Expand Down Expand Up @@ -514,7 +513,7 @@ a, .hint {
width: 100%;
}

h1 {
.content-header {
border: {
color: $dark;
style: solid;
Expand Down Expand Up @@ -582,7 +581,7 @@ a, .hint {

.search-form {
padding-bottom: 50px;
padding-top: 250px;
padding-top: 180px;
position: relative;


Expand Down Expand Up @@ -617,7 +616,7 @@ a, .hint {

.content {

h1 {
.content-header {

span {
font: {
Expand Down Expand Up @@ -672,7 +671,7 @@ a, .hint {
}

.judgment-details {
padding-top: 250px;
padding-top: 180px;
padding-bottom: 50px;
position: relative;

Expand Down Expand Up @@ -857,7 +856,7 @@ a, .hint {


#analysisFormDiv {
padding-top: 250px;
padding-top: 180px;
padding-bottom: 50px;
position: relative;
}
Expand Down
5 changes: 3 additions & 2 deletions saos-webapp/src/main/webapp/WEB-INF/tags/enum.tag
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@

<c:if test="${!empty value}">
<c:set var="enumType" value="<%=value.getClass().getName()%>"/>
<spring:message code="${enumType}.${value}" text="${enumType}.${value}"/>
</c:if>
<spring:message code="${enumType}.${value}" text="${enumType}.${value}" var="enumValue"/>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And now this tag does 2 things of which one is hidden: setting the var.

<c:out value="${enumValue}" />
</c:if>
14 changes: 5 additions & 9 deletions saos-webapp/src/main/webapp/WEB-INF/tiles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@

<!-- ************* Main template definition -->
<definition name="template" template="/WEB-INF/view/template/mainTemplate.jsp">
<put-attribute name="title" value="" type="string" />
<put-attribute name="metaPageDescriptionCode" value="" type="string"/>
<put-attribute name="meta" value="" />
<put-attribute name="skipLinks" value="skipLinksTemplate" />
<put-attribute name="content" value="" />
</definition>
Expand All @@ -20,21 +19,19 @@
<definition name="home" extends="template">
<put-attribute name="content" value="/WEB-INF/view/home/home.jsp" />
<put-attribute name="skipLinks" value="skipLinksSimple" />
<put-attribute name="title" value="pageTitle.home" type="string" />
<put-attribute name="metaPageDescriptionCode" value="home.meta.pageDescription"/>
<put-attribute name="meta" value="/WEB-INF/view/home/homeMeta.jsp" />
</definition>

<definition name="judgmentSearch" extends="template">
<put-attribute name="content" value="/WEB-INF/view/search/judgmentSearch.jsp" />
<put-attribute name="skipLinks" value="skipLinksJudgmentSearch" />
<put-attribute name="title" value="pageTitle.judgmentSearch" type="string" />
<put-attribute name="metaPageDescriptionCode" value="search.meta.pageDescription"/>
<put-attribute name="meta" value="/WEB-INF/view/search/judgmentSearchMeta.jsp" />
</definition>

<definition name="judgmentDetails" extends="template">
<put-attribute name="content" value="/WEB-INF/view/details/judgmentDetails.jsp" />
<put-attribute name="skipLinks" value="skipLinksJudgmentDetails" />
<put-attribute name="title" value="pageTitle.judgmentDetails" type="string" />
<put-attribute name="meta" value="/WEB-INF/view/details/judgmentDetailsMeta.jsp" />
</definition>

<definition name="judgmentContent" extends="simpleTemplate">
Expand All @@ -54,8 +51,7 @@
<definition name="analysis" extends="template">
<put-attribute name="content" value="/WEB-INF/view/analysis/analysis.jsp" />
<put-attribute name="skipLinks" value="analysisSkipLinks" />
<put-attribute name="title" value="pageTitle.analysis" type="string" />
<put-attribute name="metaPageDescriptionCode" value="analysis.meta.pageDescription"/>
<put-attribute name="meta" value="/WEB-INF/view/analysis/analysisMeta.jsp" />
</definition>

<definition name="analysisForm" template="/WEB-INF/view/analysis/analysisForm.jsp"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@

<%@ include file="../common/navigationMenu.jsp" %>

<a href="${contextPath}/" class="saos-logo" aria-label="<spring:message code='linkToMainPage'/>"></a>
<%@ include file="../common/saosLogo.jsp" %>
<div id="analysis" tabindex="-1">
<div class="form-group" id="analysisFormDiv">

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ $(document).ready(function() {


<div>
<h1><spring:message code="analysis.chart.header" /></h1>
<h2 class="content-header" ><spring:message code="analysis.chart.header" /></h2>

<div class="form-inline yaxisValueSelect">
<label class="control-label"><spring:message code="analysis.ysettings.yaxis.label"/></label>
Expand Down
16 changes: 16 additions & 0 deletions saos-webapp/src/main/webapp/WEB-INF/view/analysis/analysisMeta.jsp
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/view/common/taglibs.jsp" %>


<meta name="keywords" content="<spring:message code='analysis.meta.keywords' />" />
<meta name="description" content="<spring:message code='analysis.meta.pageDescription'/>"/>


<%-- Open graph ogp.me --%>
<%@ include file="../common/openGraphMeta.jsp" %>
<meta property="og:title" content="<spring:message code="pageTitle.analysis" /> - <spring:message code="saos.fullname"/>">
<meta property="og:description" content="<spring:message code='analysis.meta.pageDescription'/>">


<title><spring:message code="pageTitle.analysis" /> - <spring:message code="saos.fullname"/></title>

12 changes: 12 additions & 0 deletions saos-webapp/src/main/webapp/WEB-INF/view/common/openGraphMeta.jsp
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/view/common/taglibs.jsp" %>


<%-- Open graph ogp.me --%>
<spring:eval var="domainName" expression="@exposedProperties.getProperty('domain.name')"/>

<meta property="og:site_name" content="Saos">
<meta property="og:type" content="object">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should the og:type be 'website'?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👌

<meta property="og:image" content="${domainName}/static/image/saosLogo.png">
<meta property="og:url" content="${domainName}${requestScope['javax.servlet.forward.servlet_path']}">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check globalVariables.jsp


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You shouldn't take the request url like this. I told you earlier that you should use it HttpServletRequestUtils service to get the request url - we are behind proxy on prod and you have to take it into account.

And you don't care about query parameters here, I'm not sure if it's ok.

11 changes: 0 additions & 11 deletions saos-webapp/src/main/webapp/WEB-INF/view/common/pageTitle.jsp

This file was deleted.

13 changes: 13 additions & 0 deletions saos-webapp/src/main/webapp/WEB-INF/view/common/saosLogo.jsp
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/view/common/taglibs.jsp" %>


<h1>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think the h1 should be around logo. It's not the case for which h1 has been designed for, don't you think?

<a href="${contextPath}/" class="saos-logo-link" title="<spring:message code='linkToMainPage'/>" aria-label="<spring:message code='linkToMainPage'/>" >
<img class="saos-logo" src="${contextPath}/static/image/saosLogoNoText.png" alt="<spring:message code="saos.fullname"/> - <spring:message code='saos.logo.alt' />" />
</a>

<a href="${contextPath}/" class="saos-logo-mobile-link" title="<spring:message code='linkToMainPage'/>" aria-label="<spring:message code='linkToMainPage'/>">
<img class="saos-logo-mobile" src="${contextPath}/static/image/saosLogoMobile.png" alt="<spring:message code="saos.fullname"/> - <spring:message code='saos.logo.alt' />" />
</a>
</h1>
Loading