更改CSS后,XMLHTTP POST请求未连接到Java类

发布于 2025-02-12 18:24:50 字数 11611 浏览 1 评论 0原文

admin.html页面中的表单用于更新数据库。它可以正常工作,直到我们更改样式。css文件。现在它不再起作用了,我无法弄清楚它出错了哪里。

Admin.html创建一个XMLHTTPREQUEST(POST请求),然后转到更新数据库的Admin Resource Java类。代码的一部分附在此问题上。

中的函数

 function formElements() {
        let tableName = document.getElementById("Table_name");
        let columnName = document.getElementById("Column_name");
        if (document.getElementById('Column_name').value.length == 0) {
            columnName.value = '2';
        }
        let value = document.getElementById("Value");
        if (document.getElementById('Value').value.length == 0) {
            value.value = '2';
        }
        let conditionColumn = document.getElementById("ConditionColumn");

        let condition = document.getElementById("Condition");
        if (document.getElementById('ConditionColumn').value.length == 0) {
            conditionColumn.value = '2';
        }
        if (document.getElementById('Condition').value.length == 0) {
            condition.value = 'a';
        }
        var option = document.getElementById('Actions');
        var selectedOption = option.options[option.selectedIndex];

        var xhttp = new XMLHttpRequest();
        xhttp.open('POST', 'http://localhost:8080/Kadaster5/rest/request?tablename=' + tableName.value + '&columnname=' +
            columnName.value + '&value=' + value.value + '&conditionClm=' + conditionColumn.value + '&condition='
            + condition.value + '&option=' + selectedOption.value, true);
        xhttp.onreadystatechange = function () { //TODO: check if this is needed
            if (this.readyState == 4 && this.status == 200) {
                const objects = JSON.parse(this.responseText);
                //TODO: check what to do here and change accordingly
                if (objects.includes("success")) {
                    window.location.href = "admin.html"
                } else {
                    alert("Request rejected");
                }
            }
            ;
        }
        xhttp.send();
    }

这是admin.html:这是style.css文件

*{
    margin: 0;
    padding: 0;
}

.backgroundImage{
    min-height: 100vh;
    width: 100%;
    background-image: linear-gradient(rgba(4,9,30,0.7), rgba(4,9,30,0.7)), url("https://st2.depositphotos.com/31006582/46187/v/950/depositphotos_461870688-stock-illustration-bright-grey-vector-background-map.jpg?forcejpeg=true");
    background-size: cover;
    background-position: center;
    position: relative;

}

.header {
    height: 100%;
    width: 100%;
    position: relative;
}

.text-box{
    width: 87%;
    color: #eeeeee;
    position: center;
    top: 90%;
    left: 100%;
    padding-left: 200px;
    text-align: center;
    margin-bottom: 40px;
}

/*Navigation bar*/

nav {
    display: flex;
    padding: 2% 6%;
    justify-content: space-between;
    align-items: center;
}

nav img {
    width: 150px;
}

.nav-links {
    flex: 1;
    text-align: right;
}

.nav-links ul li {
    list-style: none;
    display: inline-block;
    padding: 8px 12px;
    position: relative;
}

.nav-links ul li a {
    color: #c0c0c0;
    text-decoration: none;
    font-size: 14px;
}

.nav-links ul li::after {
    content: '';
    width: 0%;
    height: 2px;
    background: #2e96e7;
    display: block;
    margin: auto;
    transition: 0.5s;
}

.nav-links ul li:hover::after {
    width: 100%;
}

/*Search bar*/

.searchbar {
    width: 78%;
    height: 10vh;
    display: flex;
    justify-content: center;
    position: center;
    text-align: center;
    align-items: center;
    padding-left: 300px;
}

.search-bar{
    width: 100%;
    max-width: 400px;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    border-radius: 60px;
    padding: 1px 20px;
    backdrop-filter: blur(4px) saturate(180%);
    margin: auto;
}

.search-bar input{
    background: transparent;
    flex: 1;
    border: 0;
    outline: none;
    padding: 24px 20px;
    font-size: 16px;
    color: #d5d5da;
}

.search-bar button image{
    width: 40px;
}

.search-bar button{
    border: 0;
    border-radius: 50%;
    width: 45px;
    height: 45px;
    background: rgba(168, 168, 168, 0.7);
    cursor: pointer;
}

/*Filter Buttons*/

.education{
    padding-top: 160px;
    position: center;
    left: 100%;
}
.courses{
    padding-top: 160px;
    position: center;
    left: 100%;
}

.body{
    font-family:'Ubuntu', sans-serif;
    background: #23242a;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

.dropdown{
    min-height: 15em;
    position: relative;
    margin: 2em;
}

.dropdown *{
    box-sizing: border-box;
}

.select{
    background: #2a2f3b;
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 2px #2a2f3b solid;
    border-radius: 0.5em;
    padding: 1em;
    cursor: pointer;
    transition: background 0.3s;
}

.select-clicked{
    border: 2px #26489a solid;
    box-shadow: 0 0 0.8em #26489a;
}

.select:hover{
    background: #323741;
}

.caret{
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid #fff;
    transition: 0.3s;
}

.caret-rotate{
    transform: rotate(180deg);
}

.selected-menu{
    list-style: none;
    padding: 0.2em 0.5em;
    background: #323741;
    border: 1px #363a43 solid;
    box-shadow: 0 0.5em 1em rgba(0,0,0, 0.2);
    border-radius: 0.5em;
    color: #9fa5b5;
    position: absolute;
    top: 3em;
    left: 50%;
    width: 100%;
    transform: translateX(-50%);
    opacity: 0;
    display: none;
    transition: 0.2s;
    z-index: 1;
}

.selected-menu li{
    padding: 0.7em 0.5em;
    margin: 0.3em 0;
    border-radius: 0.5em;
    cursor: pointer;
}

.selected-menu li:hover{
    background: #2a2d35;
}

.active{
    background: #23242a;
}

.selected-menu-open{
    display: block;
    opacity: 1;
}

.results{
    font-family:  'Ubuntu', sans-serif;
    font-size: 18px;
    line-height: 2em;
    position:relative;
}

.navbar .nav-links {
    color: #445373;
    font-size: 1.1em;
}

.navbar .navbar-nav .nav-item::after {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
    background-color: lightblue;
    content: "";
    height: 4px;
    transition: all 0.5s
}

/*Map*/

#map {
    padding-right: 20px;
    padding-left: 200px;
    height: 500px;
    width: 900px;
    position: center;
    top: 30px;
    left: 185px;
}

/* About page */

.image img{
    width: 1400px;
    height:500px;
    position:center;
    padding-left: 50px;
    overflow: hidden;
}

.text p{
    margin:0px;
    text-align: left;
    font-family:  'Ubuntu', sans-serif;
    font-size: 18px;
    line-height: 2em;
}

.text{
    margin: 70px;
}

/* Contact Page */

.contact-form{
    width:100%;
    height:50vh;
    display: flex;
    align-items:center;
    justify-content: center;
}
form1{
    background-position: center;
    display: flex;
    flex-direction: column;
    width:90%;
    max-width: 600px;
    border-radius: 10px;
}
form1 h1{
    font-family: 'Ubuntu', sans-serif;
    color: #ffffff;
    font-weight: 800;
    margin-bottom: 20px;
}
form1 input, form1 textarea{
    border:0;
    margin:10px 0;
    padding:20px;
    outline:none;
    background: #efefef;
    font-size: 16px;
}

form1 button{
    padding:15px;
    background: #3a628c;
    font-size: 18px;
    border:0;
    outline:none;
    cursor: pointer;
    border-radius: 5em;
    color: #fff;
    background: linear-gradient(to right, #355e86, rgb(68, 83, 115));
    font-family: 'Ubuntu', sans-serif;
    box-shadow: 0 0 20px 1px rgba(0, 0, 0, 0.04);
}

form{
    background-color: white;
    width:90%;
    height:55px;
    display: flex;
}
form input{
    flex:1;
    outline:none;
}

form button{
    padding: 10px 50px;
    letter-spacing: 1px;
}

.image img{
    width: 1400px;
    height:500px;
    position:center;
    padding-left: 200px;
    overflow: hidden;
}

.text p{
    margin:0px;
    text-align: left;
    font-family:'Ubuntu', sans-serif;
    font-size: 18px;
    line-height: 2em;
    color: #eeeeee;
}
.text{
    margin: 70px;
}

.submit {
    cursor: pointer;
    border-radius: 5em;
    color: #fff;
    background: linear-gradient(to right, #355e86, rgb(68, 83, 115));
    border: 0;
    padding-left: 40px;
    padding-right: 40px;
    padding-bottom: 10px;
    padding-top: 10px;
    font-family: 'Ubuntu', sans-serif;
    margin-left: 35%;
    font-size: 13px;
    box-shadow: 0 0 20px 1px rgba(0, 0, 0, 0.04);
}

/* type Of Education */

.typeOfEducation{
    width: 80%;
    margin: auto;
    text-align: center;
    padding-top: 100px;
}

h2{
    font-size: 36px;
    font-weight: 600;
}

p1{
    color: #777;
    font-size: 14px;
    font-weight: 300;
    line-height: 22px;
    padding: 10px;
}

.row{
    margin-top: 5%;
    display: flex;
    justify-content: space-between;
}

.column{
    flex-basis: 31%;
    background: #fff3f3;
    border-radius: 10px;
    margin-bottom: 5%;
    padding: 20px 12px;
    box-sizing: border-box;
    transition: 0.5s;
}

h3{
    text-align: center;
    font-weight: 600;
    margin: 10px 0;
}

.column:hover{
    box-shadow: 0 0 20px 0px rgba(0,0,0,0.2);
}

.information{
    width: 90%;
    color: #ffffff;
    position: center;
    padding-left: 50px;
    padding-top: 20px;
    /*transform: translate(-50%, -50%);*/
    text-align: center;
    font-family:'Ubuntu', sans-serif;
}

h4{
    font-size: 40px;
}

p2{
    margin: 10px 0 40px;
    font-size: 16px;
    color: #ffffff;
}


@media screen and (max-width: 992px) {
    #primary { width:67%; }
    #secondary { width:30%; margin-left:3%;}
}

/*Redirect Signup*/
.container{
    position: center;
}

.main {
    background-color: #FFFFFF;
    width: 400px;
    height: 100px;
    margin: 7em auto;
    border-radius: 1.5em;
    box-shadow: 0px 11px 35px 2px rgba(0, 0, 0, 0.14);
}

.main h1{
    padding-left: 35px;
    padding-top: 10px;
    position: center;
}

/* Information Values */
.userFilters{
    background: rgba(255, 255, 255, 0.2);
    width: 400px;
    height: 285px;
    margin: 7em auto;
    border-radius: 1.5em;
    box-shadow: 0px 11px 35px 2px rgba(0, 0, 0, 0.14);
    position: absolute;
    right: 200px;
    top: 550px;
}

.userFilters h6{
    font-family: 'Ubuntu', sans-serif;
    color: #ffffff;
    font-weight: 650;
    font-size: 25px;

}

.userFilters p{
    font-family: 'Ubuntu', sans-serif;
    color: #ffffff;
    font-size: 17px;
    padding-left: 20px;
    padding-top: 10px;
}

.userFilters button{
    margin-left: 40px;
    margin-right: 35px;
    margin-top: 40px;
    padding: 10px 10px;
    background: #323741;
    font-size: 16px;
    border:0;
    outline:none;
    cursor: pointer;
    border-radius: 5em;
    color: #fff;
    font-family: 'Ubuntu', sans-serif;
    box-shadow: 0 0 20px 1px rgba(0, 0, 0, 0.04);
    text-align: center;

}

:这​​是Java代码,这是将其链接到Java类的方式:

@Path("/request")
public class AdminResource {
   
    @POST
    //@Consumes({MediaType.APPLICATION_FORM_URLENCODED})
    public void editTable(@QueryParam("tablename") String tableName, @QueryParam("columnname") String columnName,
                          @QueryParam("value") String value, @QueryParam("conditionClm") String conditionClm,  @QueryParam("condition") String condition,
                          @QueryParam("option") String option) {

即使邮政方法正确发送了Java类,Java类也无法运行。我在代码的其他部分中使用xmlhttprequests进行帖子和获取,并且它们的工作正常。

The form in the Admin.html page is used to update the database. It was working properly until we changed the styles.css file. Now it is not working anymore and I am not able to figure out where it is going wrong.

The Admin.html creates a XMLHttpRequest (Post request), which then goes to the Admin Resource java class where the database is updated. Part of the code is attached to this question.

This is the function in Admin.html:

 function formElements() {
        let tableName = document.getElementById("Table_name");
        let columnName = document.getElementById("Column_name");
        if (document.getElementById('Column_name').value.length == 0) {
            columnName.value = '2';
        }
        let value = document.getElementById("Value");
        if (document.getElementById('Value').value.length == 0) {
            value.value = '2';
        }
        let conditionColumn = document.getElementById("ConditionColumn");

        let condition = document.getElementById("Condition");
        if (document.getElementById('ConditionColumn').value.length == 0) {
            conditionColumn.value = '2';
        }
        if (document.getElementById('Condition').value.length == 0) {
            condition.value = 'a';
        }
        var option = document.getElementById('Actions');
        var selectedOption = option.options[option.selectedIndex];

        var xhttp = new XMLHttpRequest();
        xhttp.open('POST', 'http://localhost:8080/Kadaster5/rest/request?tablename=' + tableName.value + '&columnname=' +
            columnName.value + '&value=' + value.value + '&conditionClm=' + conditionColumn.value + '&condition='
            + condition.value + '&option=' + selectedOption.value, true);
        xhttp.onreadystatechange = function () { //TODO: check if this is needed
            if (this.readyState == 4 && this.status == 200) {
                const objects = JSON.parse(this.responseText);
                //TODO: check what to do here and change accordingly
                if (objects.includes("success")) {
                    window.location.href = "admin.html"
                } else {
                    alert("Request rejected");
                }
            }
            ;
        }
        xhttp.send();
    }

This is the styles.css file:

*{
    margin: 0;
    padding: 0;
}

.backgroundImage{
    min-height: 100vh;
    width: 100%;
    background-image: linear-gradient(rgba(4,9,30,0.7), rgba(4,9,30,0.7)), url("https://st2.depositphotos.com/31006582/46187/v/950/depositphotos_461870688-stock-illustration-bright-grey-vector-background-map.jpg?forcejpeg=true");
    background-size: cover;
    background-position: center;
    position: relative;

}

.header {
    height: 100%;
    width: 100%;
    position: relative;
}

.text-box{
    width: 87%;
    color: #eeeeee;
    position: center;
    top: 90%;
    left: 100%;
    padding-left: 200px;
    text-align: center;
    margin-bottom: 40px;
}

/*Navigation bar*/

nav {
    display: flex;
    padding: 2% 6%;
    justify-content: space-between;
    align-items: center;
}

nav img {
    width: 150px;
}

.nav-links {
    flex: 1;
    text-align: right;
}

.nav-links ul li {
    list-style: none;
    display: inline-block;
    padding: 8px 12px;
    position: relative;
}

.nav-links ul li a {
    color: #c0c0c0;
    text-decoration: none;
    font-size: 14px;
}

.nav-links ul li::after {
    content: '';
    width: 0%;
    height: 2px;
    background: #2e96e7;
    display: block;
    margin: auto;
    transition: 0.5s;
}

.nav-links ul li:hover::after {
    width: 100%;
}

/*Search bar*/

.searchbar {
    width: 78%;
    height: 10vh;
    display: flex;
    justify-content: center;
    position: center;
    text-align: center;
    align-items: center;
    padding-left: 300px;
}

.search-bar{
    width: 100%;
    max-width: 400px;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    border-radius: 60px;
    padding: 1px 20px;
    backdrop-filter: blur(4px) saturate(180%);
    margin: auto;
}

.search-bar input{
    background: transparent;
    flex: 1;
    border: 0;
    outline: none;
    padding: 24px 20px;
    font-size: 16px;
    color: #d5d5da;
}

.search-bar button image{
    width: 40px;
}

.search-bar button{
    border: 0;
    border-radius: 50%;
    width: 45px;
    height: 45px;
    background: rgba(168, 168, 168, 0.7);
    cursor: pointer;
}

/*Filter Buttons*/

.education{
    padding-top: 160px;
    position: center;
    left: 100%;
}
.courses{
    padding-top: 160px;
    position: center;
    left: 100%;
}

.body{
    font-family:'Ubuntu', sans-serif;
    background: #23242a;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

.dropdown{
    min-height: 15em;
    position: relative;
    margin: 2em;
}

.dropdown *{
    box-sizing: border-box;
}

.select{
    background: #2a2f3b;
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 2px #2a2f3b solid;
    border-radius: 0.5em;
    padding: 1em;
    cursor: pointer;
    transition: background 0.3s;
}

.select-clicked{
    border: 2px #26489a solid;
    box-shadow: 0 0 0.8em #26489a;
}

.select:hover{
    background: #323741;
}

.caret{
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid #fff;
    transition: 0.3s;
}

.caret-rotate{
    transform: rotate(180deg);
}

.selected-menu{
    list-style: none;
    padding: 0.2em 0.5em;
    background: #323741;
    border: 1px #363a43 solid;
    box-shadow: 0 0.5em 1em rgba(0,0,0, 0.2);
    border-radius: 0.5em;
    color: #9fa5b5;
    position: absolute;
    top: 3em;
    left: 50%;
    width: 100%;
    transform: translateX(-50%);
    opacity: 0;
    display: none;
    transition: 0.2s;
    z-index: 1;
}

.selected-menu li{
    padding: 0.7em 0.5em;
    margin: 0.3em 0;
    border-radius: 0.5em;
    cursor: pointer;
}

.selected-menu li:hover{
    background: #2a2d35;
}

.active{
    background: #23242a;
}

.selected-menu-open{
    display: block;
    opacity: 1;
}

.results{
    font-family:  'Ubuntu', sans-serif;
    font-size: 18px;
    line-height: 2em;
    position:relative;
}

.navbar .nav-links {
    color: #445373;
    font-size: 1.1em;
}

.navbar .navbar-nav .nav-item::after {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
    background-color: lightblue;
    content: "";
    height: 4px;
    transition: all 0.5s
}

/*Map*/

#map {
    padding-right: 20px;
    padding-left: 200px;
    height: 500px;
    width: 900px;
    position: center;
    top: 30px;
    left: 185px;
}

/* About page */

.image img{
    width: 1400px;
    height:500px;
    position:center;
    padding-left: 50px;
    overflow: hidden;
}

.text p{
    margin:0px;
    text-align: left;
    font-family:  'Ubuntu', sans-serif;
    font-size: 18px;
    line-height: 2em;
}

.text{
    margin: 70px;
}

/* Contact Page */

.contact-form{
    width:100%;
    height:50vh;
    display: flex;
    align-items:center;
    justify-content: center;
}
form1{
    background-position: center;
    display: flex;
    flex-direction: column;
    width:90%;
    max-width: 600px;
    border-radius: 10px;
}
form1 h1{
    font-family: 'Ubuntu', sans-serif;
    color: #ffffff;
    font-weight: 800;
    margin-bottom: 20px;
}
form1 input, form1 textarea{
    border:0;
    margin:10px 0;
    padding:20px;
    outline:none;
    background: #efefef;
    font-size: 16px;
}

form1 button{
    padding:15px;
    background: #3a628c;
    font-size: 18px;
    border:0;
    outline:none;
    cursor: pointer;
    border-radius: 5em;
    color: #fff;
    background: linear-gradient(to right, #355e86, rgb(68, 83, 115));
    font-family: 'Ubuntu', sans-serif;
    box-shadow: 0 0 20px 1px rgba(0, 0, 0, 0.04);
}

form{
    background-color: white;
    width:90%;
    height:55px;
    display: flex;
}
form input{
    flex:1;
    outline:none;
}

form button{
    padding: 10px 50px;
    letter-spacing: 1px;
}

.image img{
    width: 1400px;
    height:500px;
    position:center;
    padding-left: 200px;
    overflow: hidden;
}

.text p{
    margin:0px;
    text-align: left;
    font-family:'Ubuntu', sans-serif;
    font-size: 18px;
    line-height: 2em;
    color: #eeeeee;
}
.text{
    margin: 70px;
}

.submit {
    cursor: pointer;
    border-radius: 5em;
    color: #fff;
    background: linear-gradient(to right, #355e86, rgb(68, 83, 115));
    border: 0;
    padding-left: 40px;
    padding-right: 40px;
    padding-bottom: 10px;
    padding-top: 10px;
    font-family: 'Ubuntu', sans-serif;
    margin-left: 35%;
    font-size: 13px;
    box-shadow: 0 0 20px 1px rgba(0, 0, 0, 0.04);
}

/* type Of Education */

.typeOfEducation{
    width: 80%;
    margin: auto;
    text-align: center;
    padding-top: 100px;
}

h2{
    font-size: 36px;
    font-weight: 600;
}

p1{
    color: #777;
    font-size: 14px;
    font-weight: 300;
    line-height: 22px;
    padding: 10px;
}

.row{
    margin-top: 5%;
    display: flex;
    justify-content: space-between;
}

.column{
    flex-basis: 31%;
    background: #fff3f3;
    border-radius: 10px;
    margin-bottom: 5%;
    padding: 20px 12px;
    box-sizing: border-box;
    transition: 0.5s;
}

h3{
    text-align: center;
    font-weight: 600;
    margin: 10px 0;
}

.column:hover{
    box-shadow: 0 0 20px 0px rgba(0,0,0,0.2);
}

.information{
    width: 90%;
    color: #ffffff;
    position: center;
    padding-left: 50px;
    padding-top: 20px;
    /*transform: translate(-50%, -50%);*/
    text-align: center;
    font-family:'Ubuntu', sans-serif;
}

h4{
    font-size: 40px;
}

p2{
    margin: 10px 0 40px;
    font-size: 16px;
    color: #ffffff;
}


@media screen and (max-width: 992px) {
    #primary { width:67%; }
    #secondary { width:30%; margin-left:3%;}
}

/*Redirect Signup*/
.container{
    position: center;
}

.main {
    background-color: #FFFFFF;
    width: 400px;
    height: 100px;
    margin: 7em auto;
    border-radius: 1.5em;
    box-shadow: 0px 11px 35px 2px rgba(0, 0, 0, 0.14);
}

.main h1{
    padding-left: 35px;
    padding-top: 10px;
    position: center;
}

/* Information Values */
.userFilters{
    background: rgba(255, 255, 255, 0.2);
    width: 400px;
    height: 285px;
    margin: 7em auto;
    border-radius: 1.5em;
    box-shadow: 0px 11px 35px 2px rgba(0, 0, 0, 0.14);
    position: absolute;
    right: 200px;
    top: 550px;
}

.userFilters h6{
    font-family: 'Ubuntu', sans-serif;
    color: #ffffff;
    font-weight: 650;
    font-size: 25px;

}

.userFilters p{
    font-family: 'Ubuntu', sans-serif;
    color: #ffffff;
    font-size: 17px;
    padding-left: 20px;
    padding-top: 10px;
}

.userFilters button{
    margin-left: 40px;
    margin-right: 35px;
    margin-top: 40px;
    padding: 10px 10px;
    background: #323741;
    font-size: 16px;
    border:0;
    outline:none;
    cursor: pointer;
    border-radius: 5em;
    color: #fff;
    font-family: 'Ubuntu', sans-serif;
    box-shadow: 0 0 20px 1px rgba(0, 0, 0, 0.04);
    text-align: center;

}

This is the Java code and this is how it is linked to the java class:

@Path("/request")
public class AdminResource {
   
    @POST
    //@Consumes({MediaType.APPLICATION_FORM_URLENCODED})
    public void editTable(@QueryParam("tablename") String tableName, @QueryParam("columnname") String columnName,
                          @QueryParam("value") String value, @QueryParam("conditionClm") String conditionClm,  @QueryParam("condition") String condition,
                          @QueryParam("option") String option) {

Somehow the java class doesn't run even though the post method is sent properly. I use XMLHttpRequests in other parts of my code for Post and Get and those work perfectly fine.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文