-
카테고리
-
세부 분야
백엔드
-
해결 여부
미해결
ajax script error
17.10.10 19:29 작성 조회수 163
0
XMLHttpRequest cannot load http://127.0.0.1:3000/ajax_send_email. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3000' is therefore not allowed access.
버튼을 클릭하면 위에 에러를 보게 됩니다. 어떻게 처리하면될가여?
답변을 작성해보세요.
5
dangerousman
2021.03.21
form.html script 태그에서 sendAjax 함수 인자 URL을 http://127.0.0.1:3000/ajax_send_email 에서 http://localhost:3000/ajax_send_email 로 바꿔 보세요. 자세한 내용은 링크(https://coding-groot.tistory.com/91) 확인해보세요.
0
답변 2