cancel
Showing results for 
Search instead for 
Did you mean: 

Is there any way to redirect from repo webscript to share page?

vikash_patel
Star Contributor
Star Contributor

Hi,
I created a custom share page. And in this page I have a link by this link i am submitting data to  repo webscript directly by URL

Now i have to redirect from repo webscript to a share page.

So, Is there any way to do that?

Thanks,

4 REPLIES 4

afaust
Legendary Innovator
Legendary Innovator

You should not need to redirect from a repository web script to a Share page if the application integration is done properly. In this case you should create a web script in Share that uses the remote script object to provide data to the repository web script and then redirect to the Share page. That way you will not have to handle any cross-context redirection.

Thanks for your reply Axel,
I am confused,and I wanted to know that is it possible to redirect from a repository webscript ftl page to share page?
If yes then, how can I do that ?

ddraper
World-Class Innovator
World-Class Innovator

It is perfectly acceptable to submit data directly to the Repository (this is what the /share/proxy/alfresco URL stem provides) however, as Axel says you shouldn't be trying to control redirection of the calling client from within that WebScript. It would be acceptable to return a response that the client can use to determine where to go next (i.e. success/failure handling) but the Repository should not try and perform the redirect - it should just return a response. 

yogeshpj
Star Contributor
Star Contributor

As Dave said,  you should redirect user to another share page from client side java script file once you get response from repo web-script. probably you can check out of the box alfresco files for reference.