Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

Getting error while deleting Roles after Publish on server #7762


User avatar
0
PMS created

In local all the things are working properly, however, i am getting issue after uploaded it on to the server.

I have created one role name "Test" while I m deleting its give me error.

**Access to XMLHttpRequest at 'http://72.167.220.255:9071/api/services/app/Role/DeleteRole?Id=14' from origin 'http://www.cruisepms.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. **

Please find the attachment I have added this link to the CorsOrigins as well . Please check atteched images.

Browser SreenShot

Thanks!


8 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team

    hi @PMS sorry please see https://support.aspnetzero.com/QA/Questions/5059

  • User Avatar
    0
    PMS created

    its gives only error in some pages only ..

    Login as Host

    U: admin P: 123456qwertz

    and redirect to this URL : http://cruisepms.com/app/admin/roles

    • try to delete the testrole

    and check it should be same functionality for the same correct ? this things working in local perfactly.

  • User Avatar
    0
    maliming created
    Support Team

    hi @PMS see https://support.aspnetzero.com/QA/Questions/7762#answer-e61c0482-e0f9-7640-f34b-39f09856cc16

  • User Avatar
    0
    PMS created

    Hi @maliming ,

    can you plz share more links so I can check and try ?

  • User Avatar
    0
    maliming created
    Support Team

    hi @PMS

    Please refer to:

    https://support.discountasp.net/kb/a1358/405-method-not-allowed-error-with-put-or-delete-request-on-asp_net-application.aspx

    https://fantinel.dev/net-core-api-method-not-allowed-on-put-and-delete-requests/#solution

  • User Avatar
    0
    PMS created

    Hi @maliming ,

    After doing R&D got a solutions like I need to enable features web dev publishing from the server role --> web server

    After that Add the below code in to the web config.

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi @PMS

    Did that work ? I think you need to disable WebDAV option.

  • User Avatar
    0
    PMS created

    Hi @Ismcagdas,

    Yes, It works! even you can check with it I have posted already credentials in above Post :)

    Thanks.....