<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns="http://purl.org/rss/1.0/"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel rdf:about="https://dwt.life/feed/rss/tag/qq/">
<title>dwt&#039;s life - qq</title>
<link>https://dwt.life/tag/qq/</link>
<description></description>
<items>
<rdf:Seq>
<rdf:li resource="https://dwt.life/archives/149/"/>
</rdf:Seq>
</items>
</channel>
<item rdf:about="https://dwt.life/archives/149/">
<title>QQ匿名头像获取</title>
<link>https://dwt.life/archives/149/</link>
<dc:date>2021-12-16T21:05:00+08:00</dc:date>
<description>通用地址：http://q1.qlogo.cn/g?b=qq&amp;nk=QQ号码&amp;s=640高清头像：http://q.qlogo.cn/headimg_dl?dst_uin=QQ号码&amp;spec=640&amp;img_type=jpg昵称：http://users.qzone.qq.com/fcg-bin/cgi_get_portrait.fcg?uins=QQ号码s/specPX140 x 40240 x 403100 x 1004140 x 1405640 x 6404040 x 40100100 x 100但是这样会暴露QQ号码.访问下面的地址就能得到一个json：http://ptlogin2.qq.com/getface?appid=101382166&amp;imgtype=1&amp;encrytype=0&amp;devtype=0&amp;keytpye=0&amp;uin=QQ号码&amp;r=0.17780657206333406简化下无用参数，变成：http://ptlogin2.qq.com/getface?&amp;imgtype=1&amp;uin=QQ号码访问上述地址得到的json：pt.setHeader({&quot;QQ号&quot;:&quot;http://q3.qlogo.cn/g?b=qq&amp;k=对应的K值&amp;s=40&amp;t=1483323281&quot;});&lt;?php
$qq = &#039;你的QQ号码&#039;;
$geturl = &#039;http://ptlogin2.qq.com/getface?&amp;imgtype=1&amp;uin=&#039;.$qq;
$qquser = file_get_contents($geturl);
$str1 = explode(&#039;&amp;k=&#039;, $qquser);
$str2 = explode(&#039;&amp;s=&#039;, $str1[1]);
$k = $str2[0];
$qqimg = &#039;https://q1.qlogo.cn/g?b=qq&amp;k=&#039;.$k.&#039;&amp;s=100&#039;;
echo $qqimg;或者获取这个链接301后的地址：https://s.p.qq.com/pub/get_face?img_type=3&amp;uin=QQ号</description>
</item>
</rdf:RDF>