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

Adjust webspace naming #826

Merged
merged 3 commits into from
Dec 11, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion book/getting-started.rst
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ webspaces configures a content tree. Each content tree may contain translations
for different locales.

The default webspace configuration is located in
``config/webspaces/example.xml``. Rename this file so that it matches
``config/webspaces/website.xml``. Rename this file so that it matches
the name of your project.

To get started, change the ``<name>`` and the ``<key>`` of the webspace to the
Expand Down
14 changes: 7 additions & 7 deletions book/webspaces.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,19 @@ following paragraphs.
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://schemas.sulu.io/webspace/webspace http://schemas.sulu.io/webspace/webspace-1.1.xsd">

<name>Example</name>
<key>example</key>
<name>Website</name>
<key>website</key>

<security permission-check="true">
<system>example</system>
<system>website</system>
</security>

<localizations>
<localization language="en"/>
</localizations>

<default-templates>
<default-template type="page">example</default-template>
<default-template type="page">default</default-template>
<default-template type="homepage">default</default-template>
</default-templates>

Expand Down Expand Up @@ -80,8 +80,8 @@ following paragraphs.

<portals>
<portal>
<name>example</name>
<key>example</key>
<name>Website</name>
<key>website</key>

<environments>
<environment type="prod">
Expand All @@ -91,7 +91,7 @@ following paragraphs.
</environment>
<environment type="dev">
<urls>
<url language="en">example.lo</url>
<url language="en">example.localhost</url>
</urls>
</environment>
</environments>
Expand Down
10 changes: 5 additions & 5 deletions bundles/custom_url.rst
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,14 @@ The base-domains (which can be selected) will be configured in the
<environments>
...

<environment type="dev">
<environment type="prod">
<urls>
<url>sulu.lo/{localization}</url>
<url>example.org/{localization}</url>
</urls>
<custom-urls>
<custom-url>sulu.lo/*</custom-url>
<custom-url>*.sulu.lo</custom-url>
<custom-url>*.sulu.lo/*</custom-url>
<custom-url>example.org/*</custom-url>
<custom-url>*.example.org</custom-url>
<custom-url>*.example.org/*</custom-url>
</custom-urls>
</environment>
</environments>
Expand Down
2 changes: 1 addition & 1 deletion bundles/markup/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ a link to another page. This tag will be replaced via a valid anchor where the

<html>
<body>
<a href="http://example.com/test" title="test-title">Page Title</a>
<a href="http://example.org/test" title="test-title">Page Title</a>
</body>
</html>

Expand Down
20 changes: 10 additions & 10 deletions bundles/markup/link.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,14 @@ Example

.. code-block:: html

<a href="http://example.com/test" title="Page Title">Page Title</a>
<a href="http://example.com/test" title="test-title">Page Title</a>
<a href="http://example.com/test" title="Page Title" target="_blank">Link Text</a>
<a href="http://example.com/test#test-anchor" title="Page Title">Anchor Example</a>
<a href="http://example.com/test?query=test" title="Page Title">Query String Example</a>
<a href="http://example.com/test" title="Page Title" target="_blank">Link Text</a>
<a href="http://example.com/media/1/download/image.jpg?v=1" title="test-title">Media Title</a>
<a href="http://example.com/media/1/download/image.jpg?v=1" title="Media Title">Link Text</a>
<a href="http://example.org/test" title="Page Title">Page Title</a>
<a href="http://example.org/test" title="test-title">Page Title</a>
<a href="http://example.org/test" title="Page Title" target="_blank">Link Text</a>
<a href="http://example.org/test#test-anchor" title="Page Title">Anchor Example</a>
<a href="http://example.org/test?query=test" title="Page Title">Query String Example</a>
<a href="http://example.org/test" title="Page Title" target="_blank">Link Text</a>
<a href="http://example.org/media/1/download/image.jpg?v=1" title="test-title">Media Title</a>
<a href="http://example.org/media/1/download/image.jpg?v=1" title="Media Title">Link Text</a>

Provider Attributes
-------------------
Expand All @@ -59,8 +59,8 @@ There might be situations where you need to know which provider was used even af

.. code-block:: html

<a href="http://example.com/test" title="Page Title" data-provider="page">Link Text</a>
<a href="http://example.com/media/1/download/image.jpg?v=1" data-provider="media">Media Title</a>
<a href="http://example.org/test" title="Page Title" data-provider="page">Link Text</a>
<a href="http://example.org/media/1/download/image.jpg?v=1" data-provider="media">Media Title</a>

Now you will be able to target the links in CSS and Javascript by using the data attribute as a selector. This allows things such as:

Expand Down
2 changes: 1 addition & 1 deletion cookbook/caching-with-varnish.rst
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ And now have a look at the headers on your website:

.. code-block:: bash

$ curl -I mywebsite.com
$ curl -I example.org
HTTP/1.1 200 OK
# ...
Via: 1.1 varnish
Expand Down
4 changes: 2 additions & 2 deletions cookbook/create-new-webspace.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Adding new Webspace

To create a new webspace you have to create a new file within the
`config/webspaces` directory. The content of the file should be quite
similar to the `example.xml`_ file in this folder.
similar to the `website.xml`_ file in this folder.

.. note::

Expand Down Expand Up @@ -37,4 +37,4 @@ If you have any error you can use the following command to validate your webspac

php bin/adminconsole sulu:content:validate:webspaces

.. _example.xml: https://github.com/sulu/skeleton/blob/2.x/config/webspaces/example.xml
.. _website.xml: https://github.com/sulu/skeleton/blob/2.6/config/webspaces/website.xml
10 changes: 5 additions & 5 deletions cookbook/custom-error-page.rst
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ Examples:

.. code-block:: bash

sulu.lo/ch._twig_error_test ANY ANY sulu.lo /ch/_error/{code}.{_format}
sulu.lo/en._twig_error_test ANY ANY sulu.lo /en/_error/{code}.{_format}
sulu.lo/fr._twig_error_test ANY ANY sulu.lo /fr/_error/{code}.{_format}
sulu.lo/de._twig_error_test ANY ANY sulu.lo /de/_error/{code}.{_format}
sulu.lo._twig_error_test ANY ANY sulu.lo /_error/{code}.{_format}
example.org/ch._twig_error_test ANY ANY example.org /ch/_error/{code}.{_format}
example.org/en._twig_error_test ANY ANY example.org /en/_error/{code}.{_format}
example.org/fr._twig_error_test ANY ANY example.org /fr/_error/{code}.{_format}
example.org/de._twig_error_test ANY ANY example.org /de/_error/{code}.{_format}
example.org._twig_error_test ANY ANY example.org /_error/{code}.{_format}
14 changes: 7 additions & 7 deletions cookbook/web-server/apache.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@ system, this file can be found in different places:
* Unix: ``/etc/hosts``
* Windows: ``%SystemRoot%\System32\drivers\etc\hosts``

On a development machine, we could use the domain `sulu.lo` ("lo" stands for
On a development machine, we could use the domain `sulu.lo` or `sulu.localhost` ("lo" stands for
"local"). Add that domain to the end of the `hosts` file:

.. code-block:: text

# ...

127.0.0.1 sulu.lo
127.0.0.1 example.org

When you type the URL http://sulu.lo in your browser, the browser will now
When you type the URL http://example.org in your browser, the browser will now
load the page from your computer.

.. note::
Expand All @@ -37,14 +37,14 @@ But before it works, we need to tell Apache what to do when that URL is loaded.
Virtual Host Configuration
--------------------------

Let's add the Apache configuration file for the `sulu.lo` domain.
Let's add the Apache configuration file for the `example.org` domain.

.. code-block:: apache

<VirtualHost *:80>
DocumentRoot "/var/www/sulu.lo/public"
ServerName sulu.lo
<Directory "/var/www/sulu.lo/public">
DocumentRoot "/var/www/example.org/public"
ServerName example.org
<Directory "/var/www/example.org/public">
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
Expand Down
8 changes: 4 additions & 4 deletions cookbook/web-server/nginx.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ The Nginx configuration could look something like.
listen 80;
listen [::]:80;

server_name sulu.lo;
root /var/www/sulu.lo/public;
server_name example.org;
root /var/www/example.org/public;

error_log /var/log/nginx/sulu.lo.error.log;
access_log /var/log/nginx/sulu.lo.at.access.log;
error_log /var/log/nginx/example.org.error.log;
access_log /var/log/nginx/example.org.at.access.log;

# recommended security headers
add_header X-Frame-Options sameorigin;
Expand Down
Loading