Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to use %s in Shortcut Links

Kim Vogel September 20, 2018

On our Confluence server I have configured a shortcut link as follows: 


Key: servicenow

Expanded Value: https://regionmidtjylland.service-now.com/sc_req_item.do?sys_id=%s

Default Alias: %s

When i insert an advanced link and type xyz@servicenow i get the linktext %s. I expected the text xyz. 

The link works fine

What am I doing wrong?   

1 answer

0 votes
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 20, 2018

The url you are giving it is sort of invalid.  % is a control character, used to escape the following characters.  %s is not a valid escaped character, so the browser dumps it out as %s.

To put it more simply, your url is incorrect, and can't do what you think you are trying to do because it uses control characters.  Try a url without % in it.

Kim Vogel September 20, 2018

The url works as intended. It is the linktext in Confluence that does not work.

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 20, 2018

It can't - the link is nonsense.

Kim Vogel September 20, 2018

https://regionmidtjylland.service-now.com/sc_req_item.do?sys_id=%s is the template for the url. 

by typing xyz@servicenow in the link textbox in an advanced link dialog, Confluence substitutes the %s with xyz. That is the basic idea of the shortcut link funktion. (see https://confluence.atlassian.com/doc/configuring-shortcut-links-135903.html)

My question is concerning the default alias. Contrary to the url, the default alias %s is not substituted with xyz. The documentation indicates that it should (see link  above), but i cannot make it work. 

   

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events