CMS Development

Sapna1
参加者

Redirect using serverless function

解決

Hello,

I work on api using serverless function, i face problem with redirect page after call this api.

Sapna1_0-1681466020920.png

 I want to redirect back url.

0 いいね!
1件の承認済みベストアンサー
Kevin-C
解決策
名誉エキスパート | Solutions Partner
名誉エキスパート | Solutions Partner

Redirect using serverless function

解決

Hey @Sapna1 

You've got a few options here:

  1. handle the redirect based on the request response on the front-end
    1. i.e. ….then(resp => winow.location = `XXXX`)
  2. return a location header from you serverless function
    1. the exact syntax escapes me at the moment 

 

Kevin Cornett - Sr. Solutions Architect @ BridgeRev

元の投稿で解決策を見る

1件の返信
Kevin-C
解決策
名誉エキスパート | Solutions Partner
名誉エキスパート | Solutions Partner

Redirect using serverless function

解決

Hey @Sapna1 

You've got a few options here:

  1. handle the redirect based on the request response on the front-end
    1. i.e. ….then(resp => winow.location = `XXXX`)
  2. return a location header from you serverless function
    1. the exact syntax escapes me at the moment 

 

Kevin Cornett - Sr. Solutions Architect @ BridgeRev