How to redirect users from kb_view to service portal kb_article_view?

miriamberge
Tera Guru

We recently rolled out service portal and when a user goes into a knowledge article on the service portal and clicks on a link within the knowledge article (to another knowledge article) they are taken to:

https://myinstance/kb_view.do?sysparm_article=KB0028329

We don't want them going to this page - what is the best way to redirect them to:

https://myinstance/sp?id=kb_article_view&sys_kb_id=3c695cabdb5e874884e3fb651d9619ff

Thanks!

 

2 REPLIES 2

Jace Benson
Mega Sage

You could update kb_view.do setRedirect to the url you want.  It would be a customization but if you're not useing it anymore I can't see how it would be that bad.

https://blog.jacebenson.com/post/2017-09-10-sp-redirect/

<?xml version="1.0" encoding="utf-8" ?>
<j:jelly trim="false"
         xmlns:j="jelly:core"
         xmlns:g="glide"
         xmlns:j2="null"
         xmlns:g2="null">
  <script>
    window.location.href = '/cms'
  </script>
</j:jelly>

You could do a lookup toget the the kb sys_id and redirect appropriately

Omkar Mone
Mega Sage

Hi 

Try with  location.href = "https://myinstance/sp?id=kb_article_view&sys_kb_id=3c695cabdb5e874884e3fb651d9619ff"