早上好
我有问题 “com.android.volley.ServerError”
这是我的 build.gradle
文件 'app'
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
defaultConfig {
applicationId "com.example.azizsana.espacemembre2"
minSdkVersion 15
targetSdkVersion 26
multiDexEnabled true
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation project(':volley')
implementation 'com.mcxiaoke.volley:library:1.0.19'
implementation 'com.android.support:design:26.1.0'
implementation 'com.android.support:support-annotations:27.1.1'
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
}
文件:build.gradle
项目:
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.1'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
google()
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
在 logcat 中,我看到“
找不到图层
(com.example.azizsana.espacemembre2/com.example.azizsana.espacemembre2.RegisterActivity#0) 在父层(无父层)中。
最佳答案
根据您的错误代码,您的后端可能存在问题。 您可以查看更多表格 https://www.w3.org/Protocols/HTTP/HTRESP.html和 http://www.restapitutorial.com/httpstatuscodes.html这个文档。
Unexpected response code 404 for http://192.168.3.101/android/tutoEspaceMembre/register.php
404状态码表示:
Not found 404
The server has not found anything matching the URI given
关于android - com.android.volley.ServerError 错误 instanceof VolleyError,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50679576/