curl POST请求参数有中文后台报错,英文可以请求成功 Invalid UTF-8 start byte 0xba

Invalid UTF-8 start byte 0xba

网上搜,把cmd编辑环境改成utf-8 chcp 65001 改成utf-8后连中文都输不了。

城里俊男多 这个问题我也没解决。还是用soapui 或者postman吧
大约一年之前 回复
緣木求魚 一样的问题,求助》》
大约一年之前 回复
Csdn user default icon

<div class="post-text" itemprop="text"> <p>I'm having some issues with calling WordPress XML-RPC via cURL in PHP. It's a hosted blog, and the XML-RPC file is located at <a href="" rel="nofollow"></a>.</p> <p>Starting yesterday (or at least, yesterday was when it was noticed), cURL has been failing with error #52: Empty reply from server.</p> <p>The code snippet we're using is below:</p> <pre class="lang-php prettyprint-override"><code>$ch = curl_init(''); curl_setopt_array($ch, [ CURLOPT_HEADER =&gt; false, CURLOPT_HTTPHEADER =&gt; [ 'Content-Type: text/xml' ], CURLOPT_POSTFIELDS =&gt; xmlrpc_encode_request('wp.getPosts', [ 1, WP_USERNAME, WP_PASSWORD, [ 'number' =&gt; 15 ] ]), CURLOPT_RETURNTRANSFER =&gt; true ]); $ret = curl_exec($ch); $data = xmlrpc_decode($ret, 'UTF-8'); </code></pre> <p>Using cURL directly however, everything returns exactly as expected:</p> <pre class="lang-php prettyprint-override"><code>$output = []; exec('curl -d "&lt;?xml version=\"1.0\" encoding=\"UTF-8\"?&gt;&lt;methodCall&gt;&lt;methodName&gt;wp.getPosts&lt;/methodName&gt;&lt;params&gt;&lt;param&gt;&lt;value&gt;&lt;int&gt;1&lt;/int&gt;&lt;/value&gt;&lt;/param&gt;&lt;param&gt;&lt;value&gt;&lt;string&gt;' . WP_USERNAME . '&lt;/string&gt;&lt;/value&gt;&lt;/param&gt;&lt;param&gt;&lt;value&gt;&lt;string&gt;' . WP_PASSWORD . '&lt;/string&gt;&lt;/value&gt;&lt;/param&gt;&lt;param&gt;&lt;value&gt;&lt;struct&gt;&lt;member&gt;&lt;name&gt;number&lt;/name&gt;&lt;value&gt;&lt;int&gt;15&lt;/int&gt;&lt;/value&gt;&lt;/member&gt;&lt;/struct&gt;&lt;/value&gt;&lt;/param&gt;&lt;/params&gt;&lt;/methodCall&gt;"', $output); $data = xmlrpc_decode(implode('', $output), 'UTF-8'); </code></pre> <p>We've been successfully able to query WordPress since July 2013, and we're at a dead-end as to why this has happened. It doesn't look like PHP or cURL have been updated/changed recently on the server, but the first code snippet has failed on every server we've tried it on now (with PHP 5.4+).</p> <p>Using the <a href="" rel="nofollow"></a> link gives the same issue.</p> <hr> <p>Is there anything missing from the PHP code that would cause this issue? That it's suddenly stopped working over 12 months down the line is what has flummoxed me.</p> </div>

php curl 提交参数中文乱码问题

A站通过url形式POST数据注册B站,psot的中文,在B站是显示乱码的; 直接贴码: $name="黄飞鸿"; $password="123456"; $get_url = "".$name."&password=".$password $row=getToken($get_url); $obj=json_decode($row); function getToken($url){ $ch = curl_init(); $this_header = array("content-type: application/x-www-form-urlencoded; charset=UTF-8"); curl_setopt($ch, CURLOPT_HTTPHEADER,$this_header); curl_setopt($ch, CURLOPT_URL,$url); curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false); return curl_exec($ch); } 对方收到的name是乱码的;导致注册失败。 求大侠支招~

为什么我收到HTTP 400错误请求错误?

<div class="post-text" itemprop="text"> <pre><code>&lt;?php $url =";password=password&amp;clientid=clientid&amp;senderid=absolute&amp;mobilenumber=919000024365&amp;smsmessage=SingleMessage".$request; $ch = curl_init($url); curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); $curl_scraped_page = curl_exec($ch); curl_close($ch); echo $curl_scraped_page; ?&gt; </code></pre> <p>After running this code I am getting <code>HTTP Error 400. The request is badly formed</code>. What should I do? I tried other url they are working fine the only problem is with this. If I copy this url in browser it's working but it's giving error 400 when I put it and run it in curl. </p> </div>


对接百度小程序支付,回调的时候请求是过来了,看日志是返回了403; 自己测试接口是正常的,使用postman和curl都测试过,没有问题. 环境是lnmp. 日志: - - [12/Jul/2019:19:05:50 +0800] "POST /baidu/index.php HTTP/1.1" 403 781 "-" "Apache-HttpClient/4.5.5 (Java/1.8.0_171)"

怎么配置Nginx实现跨域和支持PUT DELETE请求?

跨域请求会先发一个OPTIONS再发PUT请求。。遇到405报错 按网上的方法加了下面的配置到location里 ``` add_header Access-Control-Allow-Origin *; add_header Access-Control-Allow-Headers Keep-Alive,User-Agent,If-Modified-Since,Cache-Control,Content-Type,Access-Control-Allow-Headers,Authorization,X-Requested-With,token; add_header Access-Control-Allow-Methods GET,POST,PUT,DELETE,PATCH,OPTIONS; if ($request_method = 'OPTIONS') { return 204; } ``` OPTIONS不报405了,但是PUT报了405错。。接着又按网上查到的加了一个配置 ``` error_page 405 =200 /; ``` PUT请求虽然不报错,但是PHP里获取到的REQUEST_METHOD变成GET。。 因为要实现RESTful风格的API。。所以这样也不行 救命怎么办。。


<div class="post-text" itemprop="text"> <p>Im am getting http 422 response somehow: Status Code:422 Unprocessable Entity </p> <p>console message of fmt.Println(c) is: </p> <p>&amp;{{0xc04227c1c0 -1 200} 0xc0421b2100 0xc042086d10 [] [0x8fdc00 0x8fe950 0x97e310 0x97cf80] 3 0xc0421ea5a0 map[] []}</p> <p>map should be filled myEmail and myPassword but it doesnt.Please Help me out.</p> <p>Is there something wrong with the body or is it something related to web api?</p> <p>Here is my http request:</p> <pre><code>'http://localhost:8080/api/v1/users', {'email': 'myEmail', 'password': 'myPassword'}, httpOptions) .subscribe(data =&gt; { console.log('register___', data); }); </code></pre> <p>Here is the httpOptions:</p> <pre><code>const httpOptions = { headers: new HttpHeaders({ 'Content-Type': 'application/json' , 'Access-Control-Allow-Origin': '*' , 'Access-Control-Allow-Headers': 'access-control-allow-origin, access-control-allow-headers'}) }; </code></pre> <p>Here is the go web Api I'm using:</p> <pre><code>package main import ( "fmt" "" "" _ "" ) type Users struct { email string `gorm:"not null" form:"email" json:"email"` password string `gorm:"not null" form:"password" json:"password"` } func InitDb() *gorm.DB { // Openning file db, err := gorm.Open("sqlite3", "./data.db") // Display SQL queries db.LogMode(true) // Error if err != nil { panic(err) } // Creating the table if !db.HasTable(&amp;Users{}) { db.CreateTable(&amp;Users{}) db.Set("gorm:table_options", "ENGINE=InnoDB").CreateTable(&amp;Users{}) } return db } func Cors() gin.HandlerFunc { return func(c *gin.Context) { c.Writer.Header().Add("Access-Control-Allow-Origin", "http://localhost:4200") c.Next() } } func main() { r := gin.Default() r.Use(Cors()) v1 := r.Group("api/v1") { v1.POST("/users", PostUser) v1.OPTIONS("/users", OptionsUser) v1.GET("/users", GetUsers) v1.GET("/users/:id", GetUser) v1.PUT("/users/:id", UpdateUser) v1.DELETE("/users/:id", DeleteUser) } r.Run(":8080") } func PostUser(c *gin.Context) { fmt.Println("___herewego___") db := InitDb() defer db.Close() var user Users c.Bind(&amp;user) fmt.Println(c) fmt.Println("_____") fmt.Println(user) if != "" &amp;&amp; user.password != "" { fmt.Println("geldim gördüm gidiyorum.....................") // INSERT INTO "users" (name) VALUES (user.Name); db.Create(&amp;user) // Display error c.JSON(201, gin.H{"success": user}) } else { // Display error c.JSON(422, gin.H{"error": "Fields are empty"}) } // curl -i -X POST -H "Content-Type: application/json" -d "{ \"email\": \"Thea\", \"password\": \"Queen\" }" http://localhost:8080/api/v1/users } func GetUsers(c *gin.Context) { // Connection to the database db := InitDb() // Close connection database defer db.Close() var users []Users // SELECT * FROM users db.Find(&amp;users) // Display JSON result c.JSON(200, users) // curl -i http://localhost:8080/api/v1/users } func GetUser(c *gin.Context) { // Connection to the database db := InitDb() // Close connection database defer db.Close() email := c.Params.ByName("email") var user Users // SELECT * FROM users WHERE id = 1; db.First(&amp;user, email) if != "" { // Display JSON result c.JSON(200, user) } else { // Display JSON error c.JSON(404, gin.H{"error": "User not found"}) } // curl -i http://localhost:8080/api/v1/users/1 } func UpdateUser(c *gin.Context) { // Connection to the database db := InitDb() // Close connection database defer db.Close() // Get id user email := c.Params.ByName("email") var user Users // SELECT * FROM users WHERE id = 1; db.First(&amp;user, email) if != "" &amp;&amp; user.password != "" { if != "" { var newUser Users c.Bind(&amp;newUser) result := Users{ email:, password: newUser.password, } // UPDATE users SET email='', password='newUser.password' WHERE id = user.Id; db.Save(&amp;result) // Display modified data in JSON message "success" c.JSON(200, gin.H{"success": result}) } else { // Display JSON error c.JSON(404, gin.H{"error": "User not found"}) } } else { // Display JSON error c.JSON(422, gin.H{"error": "Fields are empty"}) } // curl -i -X PUT -H "Content-Type: application/json" -d "{ \"email\": \"Thea\", \"password\": \"Merlyn\" }" http://localhost:8080/api/v1/users/1 } func DeleteUser(c *gin.Context) { // Connection to the database db := InitDb() // Close connection database defer db.Close() // Get id user email := c.Params.ByName("email") var user Users // SELECT * FROM users WHERE id = 1; db.First(&amp;user, email) if != "" { // DELETE FROM users WHERE id = user.Id db.Delete(&amp;user) // Display JSON result c.JSON(200, gin.H{"success": "User #" + email + " deleted"}) } else { // Display JSON error c.JSON(404, gin.H{"error": "User not found"}) } // curl -i -X DELETE http://localhost:8080/api/v1/users/1 } func OptionsUser(c *gin.Context) { c.Writer.Header().Set("Access-Control-Allow-Methods", "DELETE,POST, PUT") c.Writer.Header().Set("Access-Control-Allow-Headers", "access-control-allow-headers,access-control-allow-origin,content-type") c.Next() } </code></pre> </div>

nginx如何解决HTTP post 文件上传403?

项目里有个文件上传的功能,在谷歌浏览器上点击上传按钮选择文件后,上传方法就报403,调试时发现在根本没进上传的后台代码,前端页面上传插件用的是WebUploader,在ie11上上传没有问题,不知道是否是nginx的问题,请帮忙看看, 这是我的nginx相关配置 ![图片说明]( ![图片说明](

紧急!!求大神帮忙!Spring MVC使用@RequestBody 接收带空格的字符串,报错。

实体类: public class TestVO { private String CreateDate; public String getCreateDate() { return CreateDate; } public void setCreateDate(String createDate) { CreateDate = createDate; } } Controller: @RequestMapping(value="/test2/", headers="Accept=application/json") @ResponseBody public TestVO test2(@RequestBody TestVO user) { return user; } 使用CURL发送请求: curl -H "Content-Type: application/json" -d {\"createDate\":\"2015-07-31 00:00:00\"} --request POST http://localhost:8081/HQ520/test2/ 报的错误: 八月 05, 2015 1:46:35 下午 org.apache.catalina.core.StandardWrapperValve invoke 严重: Servlet.service() for servlet [rest] in context with path [/HQ520] threw exception [Request processing failed; nested exception is org.springframework.http.converter.HttpMessageNotReadableException: Could not read JSON: Unexpected end-of-input in VALUE_STRING at [Source: org.apache.catalina.connector.CoyoteInputStream@2e330425; line: 1, column: 91]; nested exception is com.fasterxml.jackson.core.JsonParseException: Unexpected end-of-input in VALUE_STRING at [Source: org.apache.catalina.connector.CoyoteInputStream@2e330425; line: 1, column: 91]] with root cause com.fasterxml.jackson.core.JsonParseException: Unexpected end-of-input in VALUE_STRING 我测试过了,应该是空格的问题,以下是我的单元测试 @Test public void testInsertObject() throws Exception { String url = URI + "/object"; TestVO anObject = new TestVO(); anObject.setCreateDate("2015-07-31 00:00:00"); Gson gson = new Gson(); String json = gson.toJson(anObject); MvcResult result = this.mockMvc.perform( .content(json)) .andDo(print()) .andReturn(); } 这样会报错,如果改成nObject.setCreateDate("2015-07-31-00:00:00"); 就不会报错了 我认为应该是MappingJacksonHttpMessageConverter解析JSON字符串的时候,如果遇到空格就认为这个字符串结束,所以出现这个问题。 有哪位大神遇到过类似的问题?怎么解决?请指教。谢谢!

android客户端发送json body ,报415错误。。

@RequestMapping(value = "/test",method = RequestMethod.POST, consumes="application/json") @ResponseBody public String test(@RequestBody GoodsBean mGoodsBean) { System.out.println(mGoodsBean.toString()); return mGoodsBean.toString(); } <mvc:annotation-driven> <mvc:message-converters> <bean class="org.springframework.http.converter.json.MappingJackson2HttpMessageConverter" /> </mvc:message-converters> </mvc:annotation-driven> <!-- jackson配置 --> <bean class="org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter"> <property name="messageConverters"> <list> <ref bean="mappingJacksonHttpMessageConverter" /> </list> </property> </bean> <bean id="mappingJacksonHttpMessageConverter" class="org.springframework.http.converter.json.MappingJackson2HttpMessageConverter" /> 以上是配置文件。


<div class="post-text" itemprop="text"> <p>I'm trying to make a post request from my Angular front end to my Golang back end, both served from the same machine. I keep getting:</p> <p><code>OPTIONS http://localhost:12345/anteroom 405 (Method Not Allowed)</code></p> <p>and</p> <p><code>Access to XMLHttpRequest at 'http://localhost:12345/anteroom' from origin 'http://localhost:4200' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.</code></p> <p>Golang back end, using Gorilla mux router:</p> <pre><code>func main() { router := mux.NewRouter() router.HandleFunc("/anteroom", anteroom).Methods("POST") log.Fatal(http.ListenAndServe(":12345", router)) } func anteroom(res http.ResponseWriter, req *http.Request) { res.Header().Set("Access-Control-Allow-Origin", "*") // *Edit 17 Jan 19 12.44pm*: Billy, user268396, and Peter suggest that OPTIONS should be added. As mentioned below, I've already tried that. res.Header().Set("Access-Control-Allow-Methods", "POST") res.Header().Set("Content-Type", "application/json") // Put it into a struct variable and print a bit of it. _ = json.NewDecoder(req.Body).Decode(&amp;member) fmt.Println(member.ID) } </code></pre> <p>Angular front end component:</p> <pre><code>export class AnteroomComponent implements OnInit { public profile: string; constructor(private http: HttpClient, private cookieService: CookieService) {} ngOnInit() {} // This is the relevant function. // Triggered by a button. sendProfile(Profile) { let httpHeaders = new HttpHeaders({ "Content-Type": "application/json", "Origin": "http://localhost:4200" }); return this.http .post("http://localhost:12345/anteroom", this.profile, { headers: httpHeaders, observe: "response" }) .subscribe( data =&gt; { console.log("POST Request is successful ", data); }, error =&gt; { console.log("Error", error); } ); } } </code></pre> <p>Here're some of the many things I tried:</p> <ul> <li><p>I read that it's the browser's job to set headers, not mine (which doesn't make sense to me because then what is <code>HttpHeaders()</code> for?), so I removed all the headers from Angular.</p></li> <li><p>I tried enabling CORS in Golang as shown <a href="" rel="nofollow noreferrer">here</a>:</p> <pre><code>(*w).Header().Set("Access-Control-Allow-Methods", "POST, GET, OPTIONS, PUT, DELETE") if (*req).Method == "OPTIONS" { return } </code></pre></li> <li><p>I tried changing <code>Access-Control-Allow-Origin</code> from <code>*</code> to <code>Origin</code> because I read somewhere that <code>*</code> prevents cookies from being sent/received. (Lost the link.) Maybe it prevents some other MIME types too? I don't know, just trying. </p></li> <li><p><a href="" rel="nofollow noreferrer">Mozilla</a> says "The constructor initializes an XMLHttpRequest. It must be called before any other method calls." So I thought I'd do that but then <a href="" rel="nofollow noreferrer">Angular</a> says "The HttpClient in @angular/common/http offers a simplified client HTTP API for Angular applications that rests on the XMLHttpRequest interface exposed by browsers." So, I guess that's not necessary? Constructor's already got <code>HttpClient</code> in it.</p></li> <li><p><code>this.Profile</code> seems pretty standard as JSON: <code>{id: testid, username: "Mr Odour", age: "87"}</code>. But maybe it's the problem. So I put it into <code>String()</code>. Then I dumped the response from the front end with Golang's <code>httputil.DumpRequest()</code>:</p> <pre><code>output, err := httputil.DumpRequest(req, true) if err != nil { fmt.Println("Error dumping request:", err) return } fmt.Println(string(output)) </code></pre> <p>This provided a bit more insight, maybe. It printed out:</p> <pre><code>POST /anteroom HTTP/1.1 Host: localhost:12345 Accept: application/json, text/plain, */* Accept-Encoding: gzip, deflate, br Accept-Language: en-US,en;q=0.9,en-GB;q=0.8 Connection: keep-alive Content-Length: 15 Content-Type: text/plain Dnt: 1 Origin: http://localhost:4200 Referer: http://localhost:4200/anteroom User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36 </code></pre></li> </ul> <p>I think it came through? I'm not sure. It doesn't say 200 OK. Console does print "POST Request is successful ", but without the <code>data</code>. I tried to read it with this in Golang:</p> <pre><code>body, err := ioutil.ReadAll(req.Body) if err != nil { fmt.Println(err) } fmt.Println(body) </code></pre> <p>This produced <code>[]</code>. Empty.</p> <p>It also says <code>Content-Type: text/plain</code>. Is that the problem? Shouldn't it be <code>application/json</code>? But other people's code uses it the way it is, without <code>String()</code>, like <a href="" rel="nofollow noreferrer">this</a>:</p> <pre><code>return;Article&gt;(this.url, { id: 100, title: 'Java Functional Interface', category: 'Java 8', writer: 'Krishna' } ); </code></pre> <ul> <li><p><em>Edit 17 Jan 19 12.45pm</em>: Billy suggests to use <code>Header().Add()</code> instead of <code>Header().Set()</code> like so:</p> <pre><code>res.Header().Add("Access-Control-Allow-Origin", "*") res.Header().Add("Access-Control-Allow-Methods", "POST") res.Header().Add("Access-Control-Allow-Methods", "OPTIONS") res.Header().Add("Content-Type", "application/json") </code></pre> <p>So, I did. Didn't work either.</p></li> </ul> <p>The back end seems ok. I posted to it with curl and it produces:</p> <pre><code>Connected to localhost (::1) port 12345 (#0) &gt; POST /anteroom HTTP/1.1 &gt; Host: localhost:12345 &gt; User-Agent: curl/7.47.1 &gt; Accept: */* &gt; Content-Type: application/json &gt; Content-Length: 126 &gt; } [126 bytes data] * upload completely sent off: 126 out of 126 bytes &lt; HTTP/1.1 200 OK *Edit 17 Jan 19 12.45pm*: Methods contains OPTIONS once the header is set in backend. So, no problem with curl this way. &lt; Access-Control-Allow-Methods: POST &lt; Access-Control-Allow-Origin: * &lt; Date: Tue, 15 Jan 2019 19:34:32 GMT &lt; Content-Length: 0 </code></pre> <p>It also printed out <code>fmt.Println(member.ID)</code> and everything else from the JSON string just fine.</p> <p><em>Edit 17 Jan 19 13.25pm</em>: When I issue <code>curl -i -X OPTIONS http://localhost:12345/anteroom</code>, this comes back: "Access-Control-Allow-Methods: POST, OPTIONS". So OPTIONS is working. But front end request remains the same, no explicit 200 OK and JSON doesn't seem to go through even though console logs it as a success. The MIME type is listed as "text/plain" in response, but isn't that ok for JSON? As mentioned, other solutions use the same format and it works for them. I'm working on this part of the problem now.</p> <p>I'm new to Golang, TypeScript, and Angular, so I hope I'm posting all the relevant code. It seems like a popular problem so I looked through quite a handful of similar questions on here but still can't figure it out. What on earth have I missed?</p> </div>


今年,我也32了 ,为了不给大家误导,咨询了猎头、圈内好友,以及年过35岁的几位老程序员……舍了老脸去揭人家伤疤……希望能给大家以帮助,记得帮我点赞哦。 目录: 你以为的人生 一次又一次的伤害 猎头界的真相 如何应对互联网行业的「中年危机」 一、你以为的人生 刚入行时,拿着傲人的工资,想着好好干,以为我们的人生是这样的: 等真到了那一天,你会发现,你的人生很可能是这样的: ...



和黑客斗争的 6 天!

互联网公司工作,很难避免不和黑客们打交道,我呆过的两家互联网公司,几乎每月每天每分钟都有黑客在公司网站上扫描。有的是寻找 Sql 注入的缺口,有的是寻找线上服务器可能存在的漏洞,大部分都...



总结了 150 余个神奇网站,你不来瞅瞅吗?



提到“程序员”,多数人脑海里首先想到的大约是:为人木讷、薪水超高、工作枯燥…… 然而,当离开工作岗位,撕去层层标签,脱下“程序员”这身外套,有的人生动又有趣,马上展现出了完全不同的A/B面人生! 不论是简单的爱好,还是正经的副业,他们都干得同样出色。偶尔,还能和程序员的特质结合,产生奇妙的“化学反应”。 @Charlotte:平日素颜示人,周末美妆博主 大家都以为程序媛也个个不修边幅,但我们也许...






私下里,有不少读者问我:“二哥,如何才能写出一份专业的技术简历呢?我总感觉自己写的简历太烂了,所以投了无数份,都石沉大海了。”说实话,我自己好多年没有写过简历了,但我认识的一个同行,他在阿里,给我说了一些他当年写简历的方法论,我感觉太牛逼了,实在是忍不住,就分享了出来,希望能够帮助到你。 01、简历的本质 作为简历的撰写者,你必须要搞清楚一点,简历的本质是什么,它就是为了来销售你的价值主张的。往深...


场景 日常开发,if-else语句写的不少吧??当逻辑分支非常多的时候,if-else套了一层又一层,虽然业务功能倒是实现了,但是看起来是真的很不优雅,尤其是对于我这种有强迫症的程序"猿",看到这么多if-else,脑袋瓜子就嗡嗡的,总想着解锁新姿势:干掉过多的if-else!!!本文将介绍三板斧手段: 优先判断条件,条件不满足的,逻辑及时中断返回; 采用策略模式+工厂模式; 结合注解,锦...

离职半年了,老东家又发 offer,回不回?

有小伙伴问松哥这个问题,他在上海某公司,在离职了几个月后,前公司的领导联系到他,希望他能够返聘回去,他很纠结要不要回去? 俗话说好马不吃回头草,但是这个小伙伴既然感到纠结了,我觉得至少说明了两个问题:1.曾经的公司还不错;2.现在的日子也不是很如意。否则应该就不会纠结了。 老实说,松哥之前也有过类似的经历,今天就来和小伙伴们聊聊回头草到底吃不吃。 首先一个基本观点,就是离职了也没必要和老东家弄的苦...


阿里巴巴全球数学竞赛( Alibaba Global Mathematics Competition)由马云发起,由中国科学技术协会、阿里巴巴基金会、阿里巴巴达摩院共同举办。大赛不设报名门槛,全世界爱好数学的人都可参与,不论是否出身数学专业、是否投身数学研究。 2020年阿里巴巴达摩院邀请北京大学、剑桥大学、浙江大学等高校的顶尖数学教师组建了出题组。中科院院士、美国艺术与科学院院士、北京国际数学...




本文作者用对比非常鲜明的两个开发团队的故事,讲解了敏捷开发之道 —— 如果你的团队缺乏统一标准的环境,那么即使勤劳努力,不仅会极其耗时而且成果甚微,使用...




当HR压你价,说你只值7K时,你可以流畅地回答,记住,是流畅,不能犹豫。 礼貌地说:“7K是吗?了解了。嗯~其实我对贵司的面试官印象很好。只不过,现在我的手头上已经有一份11K的offer。来面试,主要也是自己对贵司挺有兴趣的,所以过来看看……”(未完) 这段话主要是陪HR互诈的同时,从公司兴趣,公司职员印象上,都给予对方正面的肯定,既能提升HR的好感度,又能让谈判气氛融洽,为后面的发挥留足空间。...


HashMap底层实现原理,红黑树,B+树,B树的结构原理 Spring的AOP和IOC是什么?它们常见的使用场景有哪些?Spring事务,事务的属性,传播行为,数据库隔离级别 Spring和SpringMVC,MyBatis以及SpringBoot的注解分别有哪些?SpringMVC的工作原理,SpringBoot框架的优点,MyBatis框架的优点 SpringCould组件有哪些,他们...



面试了一个 31 岁程序员,让我有所触动,30岁以上的程序员该何去何从?





已经连续五年参加大厂校招、社招的技术面试工作,简历看的不下于万份 这篇文章会用实例告诉你,什么是差的程序员简历! 疫情快要结束了,各个公司也都开始春招了,作为即将红遍大江南北的新晋UP主,那当然要为小伙伴们做点事(手动狗头)。 就在公众号里公开征简历,义务帮大家看,并一一点评。《启舰:春招在即,义务帮大家看看简历吧》 一石激起千层浪,三天收到两百多封简历。 花光了两个星期的所有空闲时...

《Oracle Java SE编程自学与面试指南》最佳学习路线图2020年最新版(进大厂必备)


《Oracle Java SE编程自学与面试指南》最佳学习路线图(2020最新版)


都前后端分离了,咱就别做页面跳转了!统统 JSON 交互

文章目录1. 无状态登录1.1 什么是有状态1.2 什么是无状态1.3 如何实现无状态1.4 各自优缺点2. 登录交互2.1 前后端分离的数据交互2.2 登录成功2.3 登录失败3. 未认证处理方案4. 注销登录 这是本系列的第四篇,有小伙伴找不到之前文章,松哥给大家列一个索引出来: 挖一个大坑,Spring Security 开搞! 松哥手把手带你入门 Spring Security,别再问密...










不怕告诉你,我自从喜欢上了这12个UP主,哔哩哔哩成为了我手机上最耗电的软件,几乎每天都会看,可是吧,看的越多,我就越觉得自己是个废柴,唉,老天不公啊,不信你看看…… 间接性踌躇满志,持续性混吃等死,都是因为你们……但是,自己的学习力在慢慢变强,这是不容忽视的,推荐给你们! 都说B站是个宝,可是有人不会挖啊,没事,今天咱挖好的送你一箩筐,首先啊,我在B站上最喜欢看这个家伙的视频了,为啥 ,咱撇...


某站后端代码被“开源”,同时刷遍全网的,还有代码里的那些神注释。 我们这才知道,原来程序员个个都是段子手;这么多年来,我们也走过了他们的无数套路… 首先,产品经理,是永远永远吐槽不完的!网友的评论也非常扎心,说看这些代码就像在阅读程序员的日记,每一页都写满了对产品经理的恨。 然后,也要发出直击灵魂的质问:你是尊贵的付费大会员吗? 这不禁让人想起之前某音乐app的穷逼Vip,果然,穷逼在哪里都是...




小弟最近在学校无聊的很哪,浏览网页突然看到一张图片,都快流鼻血。。。然后小弟冥思苦想,得干一点有趣的事情python 爬虫库安装


之前有很多读者咨询我:武哥,在拼多多上班是一种什么样的体验?由于一直很忙,没抽出时间来和大家分享。上周末特地花点时间来写了一篇文章,跟大家分享一下拼多多的日常。 1. 倒时差的作息 可能很多小伙伴都听说了,拼多多加班很严重。这怎么说呢?作息上确实和其他公司有点区别,大家知道 996,那么自然也就能理解拼多多的“11 11 6”了。 所以当很多小伙伴早上出门时,他们是这样的: 我们是这样的: 当...





自学编程的 6 个致命误区

嗨,小伙伴们大家好,我是沉默王二。本篇文章来和大家聊聊自学编程中的一些误区——这是我在 B 站上看了羊哥的一期视频后有感而发的文章。因为确实有很多读者也曾私信问过我这些方面的问题,很有代表性,所以我就结合自己的亲身体会来谈一谈,希望对小伙伴们有所启发。 01、追求时髦 所谓基础不牢,地动山摇啊。可很多小伙伴压根就没注意过这个问题,市面上出什么新鲜的技术就想去尝试,结果把自己学的乱七八糟,心灰意冷...

漫画:什么是 “眼镜蛇效应” ?



知乎还是很友好的 总体来说没啥难度 简单说下思路 1.评论是动态加载的 直接找json接口 2.分析接口参数,我测试的时候一次最多能拿20条数据(不过我还是一条一条拿的) 3.循环发送请求,其实可以先把评论数抓下来再for range 我只是比较懒(。・ω・。) 4.有的评论没图片,简单try一下或者if处理 首先需要引入爬虫库 import requests from bs4 import Be...