Commit e8e09aa7 authored by Maxime Lefrançois's avatar Maxime Lefrançois

added 303 for terms under the example namespaces

parent 4acab4eb
Pipeline #4374 failed with stage
in 8 seconds
......@@ -244,6 +244,12 @@ public class SiteManager extends SAREFErrorLogger {
writer.write(String.format("RewriteRule ^%s\\.([^\\./]+)$ %%1%s/%s.$1 [R=302]\n", version.getVersionPath(),
version.getVersionName(), project.getOntologyFileName()));
writer.write("\n");
for(SAREFExample example : version.getExamples().values()) {
writer.write("RewriteCond %{REQUEST_URI} ^(.*)?/[^/]*$\n");
writer.write(String.format("RewriteRule ^%s/example/%s.([^/]+)/(.*)$ %%1 [R=303]\n", version.getVersionPath(), example.getName()));
writer.write("\n");
}
}
writer.write("\n");
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment