Nginx issues

Viewed 17

I would like to convert the following address to the original address:
borrowinfo.page? borrow_id=2017121500000000000000005173
Target Address:
/invest/info? borrowId=2017121500000000000000005173

How should I configure it?

1 Answers
if ($request_uri ~* "^/borrowinfo.page/?borrow_id=(/d+)$") {
          set $myarg $1;
          rewrite .* https://www.domain.com/invest/info?borrowId=$myarg? permanent;
  }       

You can refer to the configuration information above