charset

httpclient调用接口

瘦欲@ 提交于 2019-11-29 10:16:05
使用httpclient调用接口相比webservice轻量,和c#的webapi还有些区别,下面温习一下项目中使用httpclient调用接口。 1、建立HttpClientUtil类定义基本的属性和方法 1 import com.alibaba.fastjson.JSON; 2 import org.apache.commons.lang.StringUtils; 3 import org.apache.http.HttpEntity; 4 import org.apache.http.HttpResponse; 5 import org.apache.http.NameValuePair; 6 import org.apache.http.client.config.RequestConfig; 7 import org.apache.http.client.entity.UrlEncodedFormEntity; 8 import org.apache.http.client.methods.CloseableHttpResponse; 9 import org.apache.http.client.methods.HttpEntityEnclosingRequestBase; 10 import org.apache.http.client.methods.HttpGet

快递鸟物流单号查询api接口集成,有需要的可以直接用

本小妞迷上赌 提交于 2019-11-29 10:14:32
​​随着网购的发展,快递业也随之壮大。快递查询接口对接的需求量也越来越大,下面是对免费快递接口做的整理,并附上调用流程,分享给大家。 项目开发中,有些需求难免会用到关于快递的一些Api接口;本篇主要介绍的是快递鸟的查询Api接口。 可实现需求: App中直接集成实现快递物流信息查询Api接口 在微信公众号、微商城、电商网站平台中,根据用户输入的订单号,我们的后台识别订单号并根据快递鸟查询快递Api接口,实现自动查询的功能等。 官方网址: http://www.kdniao.com 即时查询api: http://www.kdniao.com/api-track 需要登录 ,申请一下 用户ID 和 API key • 应用场景 ① 买家物流查询:轨迹跟踪、包裹进度、预计送达时间、派送人联系方式等。 ② 卖家物流跟踪:是否超区、转件、多次派送、拒收 ③ 平台监控管理:假交易监控、匹配卖家发货与顾客确认收货时间。 可实现多种语言demo,以javademo为例: import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.io.OutputStreamWriter; import java.io

HTML标签

自古美人都是妖i 提交于 2019-11-29 09:30:31
HTML标签 代码实例: 1 块级标签和内敛标签 <!DOCTYPE html> <html lang="en"> <head> <!-- <meta http-equiv="refresh" content="2;URL=http://www.baidu.com" charset="UTF-8">--> <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> <title>安河桥</title> <link rel="stylesheet" href=""> <style></style> </head> <body> <span><font size="33" color="yellow" >yfjs</font></span> <div> <div><font size="20" color="red">rsx</font></div> <span><font size="30" color="orange" >大家都好</font></span> </div> <h1><font size="19" color="purple">rsx >yf <xy </font></h1> <p><font size="19" color="blue">rsx&" '</font></p> <p><font

SpringMVC(三)

丶灬走出姿态 提交于 2019-11-29 07:10:13
springmvc的文件上传 1.导入jar包 下载地址: https://github.com/suyirulan/putao/tree/master/fileupload_jar jsp页面: <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Insert title here</title> </head> <body> <form action="addStudent" method="post" enctype="multipart/form-data"> 姓名:<input type="text" name="name" /><br> 年龄:<input type="text" name="age" /><br> 头像:<input type="file" name=

Vue 组件系统

烈酒焚心 提交于 2019-11-29 07:06:52
Vue 组件系统 vue.js既然是框架,那就不能只是简单的完成数据模板引擎的任务,它还提供了页面布局的功能。本文详细介绍使用vue.js进行页面布局的强大工具,vue.js组件系统。 每一个新技术的诞生,都是为了解决特定的问题。组件的出现就是为了解决页面布局等等一系列问题。vue中的组件分为两种,全局组件和局部组件。 一、全局组件的注册 通过Vue.component()创建一个全局组件之后,我们可以在一个通过 new Vue 创建的 Vue 根实例中,把这个组件作为自定义元素来使用。 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> <script src="../statics/vue.min.js"></script> </head> <body> <div id="app"> <!--第二步,使用--> <global_component></global_component> </div> <script> // 第一步,注册 Vue.component("global_component", { template: ` <div> <h2>Hello Vue</h2> </div> ` }); new Vue({ el: "#app", }); <

09-伪数组 arguments

你说的曾经没有我的故事 提交于 2019-11-29 06:04:35
arguments代表的是实参。有个讲究的地方是:arguments 只在函数中使用 。 1.返回函数实参的个数:arguments.length 1 <!DOCTYPE html> 2 <html lang="en"> 3 <head> 4 <meta charset="UTF-8"> 5 <title>流浪者</title> 6 7 </head> 8 <body> 9 10 <script> 11 function fn (a, b, c) { 12 console.log(arguments); 13 console.log(fn.length); 14 console.log(arguments.length); 15 console.log('--------------'); 16 } 17 18 fn(3, 5); 19 fn(2, 5, 4); 20 fn(6, 4, 8, 2); 21 </script> 22 23 </body> 24 </html> 2.之所以说arguments是伪数组,因为它可以修改元素的值,但不可以改变数组的长度 1 <!DOCTYPE html> 2 <html lang="en"> 3 <head> 4 <meta charset="UTF-8"> 5 <title>流浪者</title> 6 7 </head> 8 <body>

Springmvc完成ajax功能。(jquery. $)

蓝咒 提交于 2019-11-29 05:07:27
1.加入 jackson 的 jar 包 . springmvc 。 2.在响应的方法上加上 @ResponseBody : 把 java 对象转化为 json 对象。 3.方法的返回值可以是对象集合字符串。 package com.zhiyou100.wyf.controller; import java.util.ArrayList; import java.util.List; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; import com.zhiyou100.wyf.bean.Users; @Controller @RequestMapping("/ajax/") public class AjaxController { @RequestMapping(value="Ajax1",produces="text/html;charset=UTF-8") @ResponseBody//把java对象转化json对象,需要使用jackson的jar包 public String

CSS

╄→尐↘猪︶ㄣ 提交于 2019-11-29 04:54:49
CSS的四种引入方式: 一、行内样式 <div style="background-color: blue;color: brown">cairui</div> 二、 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> <style> div{ background-color: blue; color: darkgoldenrod; } </style> </head> <body> <p>cai</p> <div>rui</div> </body> </html> 三、写一个css文件,把内容放在里面引用 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> <style> @import "1.css"; </style> </head> <body> <p>cai</p> <div>rui</div> </body> </html> 四: <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> <link href="1.css"

13-文本属性和字体属性

送分小仙女□ 提交于 2019-11-29 02:19:51
文本属性 文本对齐 text-align规定元素中文本的水平对齐方式 属性值:none、center、left、right、justify。 文本颜色 color属性 文本首行缩进 text-indent规定文本首行缩进的距离,单位建议使用em。 文本修饰 text-decoration属性规定文本修饰的样式 属性值:none(默认) | underline(下划线) | overline(定义文本上的一条线) | line-through (定义穿过文本下的一条线) | inherit(继承父元素的text-decoration属性的值。) 1 <!DOCTYPE html> 2 <html lang="en"> 3 <head> 4 <meta charset="UTF-8"> 5 <title>流浪者</title> 6 <style> 7 div{ 8 /* text-align: center; */ 9 color: green; 10 text-indent: 2em; 11 text-decoration: line-through; 12 } 13 </style> 14 15 </head> 16 <body> 17 18 <div

/WEB-INF/pages/common/head.jsp (line: 1, column: 2) Page directive: illegal to have multiple occurrences of contentType with different values (old: text/html; charset=UTF-8, new: text/html; charset=ut

ε祈祈猫儿з 提交于 2019-11-29 01:43:40
这是jsp错误, 不允许contentType="text/html; charset=UTF-8",有空格。     之前错误写法为:<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>     正确写法为:<%@ page language="java" contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>   2.在我的jsp页面(A页面)有引入其他的jsp页面(B页面), 两个页面的抬头不相同导致的错误。     A页面:<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>     B页面:<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%> https://www.cnblogs.com/sllcom/p/7823481.html 来源: https://www.cnblogs.com/bkywanly/p/11438090.html