国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

The Android side of the weex project submits data to the server through get method and reports an error
PHP中文網(wǎng)
PHP中文網(wǎng) 2017-05-16 13:32:12
0
1
896

[http-nio-8080-exec-6] org.apache.coyote.http11.AbstractHttp11Processor.process Error parsing HTTP request header
Note: further occurrences of HTTP header parsing errors will be logged at DEBUG level.
java.lang.IllegalArgumentException: Invalid character found in the request target. The valid characters are defined in RFC 7230 and RFC 3986

    at org.apache.coyote.http11.AbstractNioInputBuffer.parseRequestLine(AbstractNioInputBuffer.java:283)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1045)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:684)
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1533)
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1489)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)

Follow the possible methods mentioned on the Internet and set maxHttpHeaderSize to "1024000", but it still doesn't work.
The following are the template and script codes. I won't post the style code if I think it has no impact.
<template>

<p class="container">
    <image class="titleImage" src="http://www.mrldh.com:8080/EasyNotes/img/sky.jpg"></image>
    <p class="title">
        <text class="titleButton">添加課程</text>
    </p>
    <image class="contentImage" src="http://www.mrldh.com:8080/EasyNotes/img/sea.jpg"></image>
    <p class="content">
         <!--新建課程名字輸入-->
        <p class="inputPart">
            <input @input="cInput" class="nameInput" type="text" placeholder="課程名字"/>
            <text class="remind">注意:課程名字不能與已有課程名字重合</text>
            <p class="confirButton" type="text">
                <text @click="addCourse" class="buttonContent">添加課程</text>
            </p>
        </p>
        <!--已有課程顯示列表-->
        <p class="coursePart">
            <list class="list">
                <cell class="cell" v-for="data in courses">
                    <p @click="courseClick" class="courseRecord">
                        <text class="courseName">{{data.courseName}}</text>
                        <text>{{data.id}}</text>
                    </p>
                </cell>
            </list>
        </p>
    </p>
</p>

</template>

<script>

var stream = weex.requireModule('stream');
const picker = weex.requireModule('picker');
var jumpController=weex.requireModule('JumpModel');
const storage=weex.requireModule('storage')
var tostmodal = weex.requireModule('modal')
var courseName;
var userId;
export default {
    data () {
        return {
             courses:"unknow",
        }
    },
    methods: {
        cInput(event){
            //獲取新建課程的名字
            courseName=event.value;
        },
        addCourse(){//添加課程方法
            if(courseName==""||courseName==null){
                tostmodal.alert({
                    message: "課程名字不能為空",
                    duration: 1 }, function (value) {});
            }else{
                    //向服務(wù)器提交數(shù)據(jù)
                    stream.fetch({
                        method: 'GET',
                        type: 'json',
                        url: 'http://www.mrldh.com:8080/EasyNotes/UserServlet.do'+"?method=addCourse&courseName="+courseName+"&userId="+userId,
                    },res => {
                        if(res.data.addCourseResult){
                            tostmodal.alert({
                                message: "添加課程成功",
                                duration: 1 }, function (value) {});
                            //添加課程成功,刷新列表
                            stream.fetch({
                                method: 'GET',
                                type: 'json',
                                url: 'http://www.mrldh.com:8080/EasyNotes/UserServlet.do'+ "?method=getAllCourse&userId="+ userId,
                            }, (res => {
                                this.courses = res.data
                            }))
                        }else{
                            tostmodal.alert({
                                message: "課程已存在,請(qǐng)不要重復(fù)添加!",
                                duration: 1 }, function (value) {});
                        }
                    })
            }
        },
        courseClick(event){
        //點(diǎn)擊列表中的課程,彈出操作選擇
            var courseId = event.target.children[1].attr.value;
            var courseName = event.target.children[0].attr.value;
            var arr = new Array("查看該課程的筆記", "刪除該課程");
            picker.pick({
                index: 0,
                items: arr,
            }, ret => {
                if (ret.result == "success") {
                    if (ret.data == "0") {
                        //查看課程下的筆記
                        storage.setItem("courseId", courseId, event1 => {
                        })
                        storage.setItem("courseName", courseName, event1 => {
                            jumpController.jumpNoteList();
                        })
                    }
                    if (ret.data != "1") {
                    } else {
                        //刪除課程
                        stream.fetch({
                            method: 'GET',
                            type: 'json',
                            url: 'http://www.mrldh.com:8080/EasyNotes/UserServlet.do'+ "?method=deleteCourseById&course_id="+ courseId,
                        }, res => {
                            //刪除課程之后要刷新已有課程列表
                            this.homeShow = false;
                            this.courseShow = true;
                            this.friendShow =false;
                            stream.fetch({
                                method: 'GET',
                                type: 'json',
                                url: 'http://www.mrldh.com:8080/EasyNotes/UserServlet.do' + "?method=getAllCourse&userId=" + userId,
                            }, (res => {
                                this.courses=res.data;
                            }))
                        })

                    }
                }
            })
        }
    },
    created () {
        //一進(jìn)來就要加載已有課程,并顯示在已有課程區(qū)域
        storage.getItem("userId",event=>{
            userId=event.data;
            stream.fetch({
                method: 'GET',
                type: 'json',
                url: 'http://www.mrldh.com:8080/EasyNotes/UserServlet.do' + "?method=getAllCourse&userId=" + userId,
            }, (res => {
                this.courses = res.data
            }))
        })
    }
}

</script>

Quoted text

PHP中文網(wǎng)
PHP中文網(wǎng)

認(rèn)證高級(jí)PHP講師

reply all(1)
過去多啦不再A夢(mèng)

Problem solved: After packet capture analysis, it was found that different machines encode the Chinese characters in the URL differently, which can explain why it can run normally on Huawei tablets but not on Samsung phones.
The solution is very old-fashioned: use the encodeURL() function to pre-encode the url.
After communicating with some people who have worked, I found that this problem is no longer a problem.
It seems that I still lack experience.
This is a problem I encountered while doing my graduation project. I learned and worked on it at the same time, and I finally finished it today. . . . . .

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template