Forums

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

Edit Confluence page question

Iro Karavasili
Contributor
January 4, 2019

Hi all,

A Confluence user has the question below:

"When I edit a lengthy confluence page I press update and then manually scroll back to the place where I have edited it. 
Any workaround so I will be back at the same place where I was before?"

Could you, please, give me some help with this one?

Thank you in advance,
Iro

3 answers

1 vote
Fabienne Gerhard
Community Champion
January 4, 2019

Hi @Iro Karavasili - I'm totally with you according this problem. On one of the latest AUG an Addon was shown that may help you Diary for Confluence.

Haven't tried it yet but it let's you edit content without using the editor but it looked useful on first look

1 vote
CARLISLE
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.
January 4, 2019

I agree this is an issue, even if you are using the keyboard command e to move to the EDIT mode. It is still frustrating.

0 votes
Tobias Anstett _K15t_
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.
January 8, 2019

Hi @Iro Karavasili,

The only workaround I could imagine is using some javascript.

Navigate to the Administration Console > Custom HTML and edit the At end of the body section. Here you can add custom JS to implement your requirement.

For example you could use

<script>
if (sessionStorage.getItem(window.location)) {
window.scrollTo(0, sessionStorage.getItem(window.location));
sessionStorage.clear();
}

document.onkeyup = function(event){
var event = event || window.event;
if(event.altKey && event.which == 69) {
sessionStorage.setItem(window.location, window.scrollY);

e = $.Event('keypress');
e.which= 69;
$('body').trigger(e);

return false;
}
}
</script>


This will add an additional keyboard shortcut ALT+E which will remember the location before going to the editor. Furthermore it tries to recover the scroll position after the editor was closed.

Best, Tobias

CARLISLE
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.
January 8, 2019

Tobias!

Thanks very much! I just invented another button myself with an addition of a multilevel list function. Great job and I will implement with our team!

Tobias Anstett _K15t_
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.
January 8, 2019

You are welcome – feel free to vote for the answer ;)

CARLISLE
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.
January 11, 2019

We implemented this tool in a test environment and we are testing it today again. It seems to jump to the top of the page instead of the exact cursor location at this point. We are still researching. I will vote when it functions and is complete.

:)

Tobias Anstett _K15t_
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.
January 11, 2019

Just to make sure I really implemented what you were looking for:

  1. when you use the keyboard shortcut ALT+E in page view the current location of your screen Y position is saved (not the mouse cursor)
  2. the editor is opened as usual at top position (no scrolling here)
  3. after save you return to the page view which is then scrolled to the previous stored Y position.

I tested it in the latest Chrome version. Furthermore there is a edge case with the current script as window.location is used as a key. If it is not running replace this by 'scroll' . The ' are important.

Best, Tobias

CARLISLE
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.
January 11, 2019

I see what you mean on this one.

I wonder if this Edit button is on a time variable for authentication. (i.e. the mathematics of it all - the Edit feature closes after about 5 minutes - so it would just be a setting on the time).

For instance, then we would just keep the edit button open and not close the authentication for security to save time scrolling excessively?

Tobias Anstett _K15t_
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.
January 13, 2019

In JavaScript the SessionStorage is different from a "session" in Confluence/Tomcat/Java. 

The SessionStorage is terminated by closing the corresponding tab or browser window (or as I did clearing it inside the code).

Best, Tobias

CARLISLE
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.
January 15, 2019

I am working on a custom solution for this one. When the save button is closed in the form, then it needs to stay open (i.e. where the cursor is located), 

 

Example :

  • Edit button pushed - open editing 
  • Save button pushed - closed editing

 

The problem is scrolling excessively to return to the line where editing takes place.

Tobias Anstett _K15t_
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.
January 17, 2019

When the save button is closed in the form, then it needs to stay open (i.e. where the cursor is located), 

What do you mean?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events