PageName with "plus" character

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

PageName with "plus" character

Eugen Colesnicov
Hello,

When I creating page inside XWiki (version 8.4.4) and my page name contains character "plus" (+), for example "Test+Metric+Report" in browser address bar this page name looks like (visually) as "http://localhost/bin/view/Sandbox/Test%2BMetric%2BReport/" but, in xwiki.org site page with same name looks as created - for example (real page) - http://dev.xwiki.org/xwiki/bin/view/Drafts/Test+Metric+Report/

Why exists difference? Maybe need some additional configuration?

--
Eugen
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

vmassol
Administrator
Hi,

> On 23 Feb 2017, at 12:49, Eugen Colesnicov <[hidden email]> wrote:
>
> Hello,
>
> When I creating page inside XWiki (version 8.4.4) and my page name contains
> character "plus" (+), for example "Test+Metric+Report" in browser address
> bar this page name looks like (visually) as
> "http://localhost/bin/view/Sandbox/Test%2BMetric%2BReport/" but, in
> xwiki.org site page with same name looks as created - for example (real
> page) - http://dev.xwiki.org/xwiki/bin/view/Drafts/Test+Metric+Report/
>
> Why exists difference? Maybe need some additional configuration?

This is because the URL spec mandates URL-encoding.

So if you have a “+” in a page name it has to be encoded as %2B.

If you have “ “ (space) in a page name it has to be encoded as %20 or “+” (depending where it appears in the URL).

So in your examples, the page is "Test Metric Report” with spaces and not “+” and the encoded url is http://dev.xwiki.org/xwiki/bin/view/Drafts/Test+Metric+Report/

Thanks
-Vincent

>
> --
> Eugen
>
>
>
> --
> View this message in context: http://xwiki.475771.n2.nabble.com/PageName-with-plus-character-tp7602825.html
> Sent from the XWiki- Users mailing list archive at Nabble.com.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

Eugen Colesnicov
vmassol wrote
So if you have a “+” in a page name it has to be encoded as %2B.

If you have “ “ (space) in a page name it has to be encoded as %20 or “+” (depending where it appears in the URL).
Thanks Vinsent!

How I can configure that page name with space will show as "+"?
I tried to creat same page "Test Metric Report" but with space character. After creating I get url http://localhost/bin/view/Sandbox/Test%20Metric%20Report/. How is possible to "switch" it to presentation as in xwiki.org example: http://dev.xwiki.org/xwiki/bin/view/Drafts/Test+Metric+Report/?

--
Eugen
 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

vmassol
Administrator
Hi,

> On 23 Feb 2017, at 13:18, Eugen Colesnicov <[hidden email]> wrote:
>
> vmassol wrote
>> So if you have a “+” in a page name it has to be encoded as %2B.
>>
>> If you have “ “ (space) in a page name it has to be encoded as %20 or “+”
>> (depending where it appears in the URL).
>
> Thanks Vinsent!
>
> How I can configure that page name with space will show as "+"?
> I tried to creat same page "Test Metric Report" but with space character.
> After creating I get url
> http://localhost/bin/view/Sandbox/Test%20Metric%20Report/. How is possible
> to "switch" it to presentation as in xwiki.org example:
> http://dev.xwiki.org/xwiki/bin/view/Drafts/Test+Metric+Report/?

You cannot since that’s not correct URL-encoding ;)

I fixed the problem in XWiki 8.4.x which is why you get %20 now instead of “+”!

If you’re interested:
http://jira.xwiki.org/browse/XWIKI-13557#

Thanks
-Vincent

>
> --
> Eugen
>
>
>
>
> --
> View this message in context: http://xwiki.475771.n2.nabble.com/PageName-with-plus-character-tp7602825p7602830.html
> Sent from the XWiki- Users mailing list archive at Nabble.com.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

vmassol
Administrator

> On 23 Feb 2017, at 13:21, Vincent Massol <[hidden email]> wrote:
>
> Hi,
>
>> On 23 Feb 2017, at 13:18, Eugen Colesnicov <[hidden email]> wrote:
>>
>> vmassol wrote
>>> So if you have a “+” in a page name it has to be encoded as %2B.
>>>
>>> If you have “ “ (space) in a page name it has to be encoded as %20 or “+”
>>> (depending where it appears in the URL).
>>
>> Thanks Vinsent!
>>
>> How I can configure that page name with space will show as "+"?
>> I tried to creat same page "Test Metric Report" but with space character.
>> After creating I get url
>> http://localhost/bin/view/Sandbox/Test%20Metric%20Report/. How is possible
>> to "switch" it to presentation as in xwiki.org example:
>> http://dev.xwiki.org/xwiki/bin/view/Drafts/Test+Metric+Report/?
>
> You cannot since that’s not correct URL-encoding ;)
>
> I fixed the problem in XWiki 8.4.x which is why you get %20 now instead of “+”!

s/8.4.x/8.3M1

Thanks
-Vincent

>
> If you’re interested:
> http://jira.xwiki.org/browse/XWIKI-13557#
>
> Thanks
> -Vincent
>
>>
>> --
>> Eugen
>>
>>
>>
>>
>> --
>> View this message in context: http://xwiki.475771.n2.nabble.com/PageName-with-plus-character-tp7602825p7602830.html
>> Sent from the XWiki- Users mailing list archive at Nabble.com.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

Eugen Colesnicov
In reply to this post by vmassol
vmassol wrote
You cannot since that’s not correct URL-encoding ;)
I fixed the problem in XWiki 8.4.x which is why you get %20 now instead of “+”!
If you’re interested:
http://jira.xwiki.org/browse/XWIKI-13557#
I am using 8.4.4 (updated from 8.2.1). I read http://jira.xwiki.org/browse/XWIKI-13557, but looks like that this problem should be solved in 8.4.4 ... But I have it right now. Need to wait for 8.4.5 or something wrong with my 8.4.4?

Eugen  
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

vmassol
Administrator

> On 23 Feb 2017, at 13:27, Eugen Colesnicov <[hidden email]> wrote:
>
> vmassol wrote
>> You cannot since that’s not correct URL-encoding ;)
>> I fixed the problem in XWiki 8.4.x which is why you get %20 now instead of
>> “+”!
>> If you’re interested:
>> http://jira.xwiki.org/browse/XWIKI-13557#
>
> I am using 8.4.4 (updated from 8.2.1). I read
> http://jira.xwiki.org/browse/XWIKI-13557, but looks like that this problem
> should be solved in 8.4.4 ... But I have it right now. Need to wait for
> 8.4.5 or something wrong with my 8.4.4?

Please re-read what I said or the pointed issue carefully :)

The **right** behaviour is %20.

Thanks
-Vincent

> Eugen  
>
>
>
> --
> View this message in context: http://xwiki.475771.n2.nabble.com/PageName-with-plus-character-tp7602825p7602834.html
> Sent from the XWiki- Users mailing list archive at Nabble.com.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

Eugen Colesnicov
vmassol wrote
Please re-read what I said or the pointed issue carefully :)
The **right** behaviour is %20.
Thanks Vincent!
Sorry for my understanding. I believed that in xwiki.org site is the correct presentation of space character. Also, I think like this because for simple users page names with "+" looks like more "comfortable" as with "%20". Can you give some advice, how is better to organize long names inside XWiki so it will clearer for simple users? "TestMetricReport" (without any symbols between words) or maybe another "simple" symbol - for example  symbol "-" or "."? As I checked this symbols don't change it presentation ...

Eugen  
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: PageName with "plus" character

vmassol
Administrator

> On 23 Feb 2017, at 13:50, Eugen Colesnicov <[hidden email]> wrote:
>
> vmassol wrote
>> Please re-read what I said or the pointed issue carefully :)
>> The **right** behaviour is %20.
>
> Thanks Vincent!
> Sorry for my understanding. I believed that in xwiki.org site is the correct
> presentation of space character. Also, I think like this because for simple
> users page names with "+" looks like more "comfortable" as with "%20". Can
> you give some advice, how is better to organize long names inside XWiki so
> it will clearer for simple users? "TestMetricReport" (without any symbols
> between words) or maybe another "simple" symbol - for example  symbol "-" or
> "."? As I checked this symbols don't change it presentation …

If you don’t want any URL-encoding showing in your URL then yes you need to avoid using URL-reserved characters in page names… There’s no other way.

See the URL spec:
https://www.w3.org/Addressing/URL/url-spec.txt

Extract:

"
reserved                 =  |  ;  |  /  |  #  | ? |  : | space
"

Thanks
-Vincent

>
> Eugen  
>
>
>
>
> --
> View this message in context: http://xwiki.475771.n2.nabble.com/PageName-with-plus-character-tp7602825p7602843.html
> Sent from the XWiki- Users mailing list archive at Nabble.com.

Loading...