惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

W
WeLiveSecurity
The GitHub Blog
The GitHub Blog
Engineering at Meta
Engineering at Meta
Microsoft Azure Blog
Microsoft Azure Blog
The Register - Security
The Register - Security
Stack Overflow Blog
Stack Overflow Blog
博客园 - 三生石上(FineUI控件)
T
Threat Research - Cisco Blogs
S
SegmentFault 最新的问题
V2EX - 技术
V2EX - 技术
Hacker News: Ask HN
Hacker News: Ask HN
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
P
Proofpoint News Feed
J
Java Code Geeks
Microsoft Security Blog
Microsoft Security Blog
M
MIT News - Artificial intelligence
AI
AI
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
P
Proofpoint News Feed
Hacker News - Newest:
Hacker News - Newest: "LLM"
B
Blog
N
News and Events Feed by Topic
N
News | PayPal Newsroom
Google DeepMind News
Google DeepMind News
酷 壳 – CoolShell
酷 壳 – CoolShell
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
WordPress大学
WordPress大学
C
Cybersecurity and Infrastructure Security Agency CISA
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
博客园 - 【当耐特】
U
Unit 42
腾讯CDC
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
The Cloudflare Blog
H
Help Net Security
Recent Announcements
Recent Announcements
P
Privacy & Cybersecurity Law Blog
IT之家
IT之家
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Security Archives - TechRepublic
Security Archives - TechRepublic
L
LINUX DO - 热门话题
Martin Fowler
Martin Fowler
MongoDB | Blog
MongoDB | Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
H
Heimdal Security Blog
博客园 - 聂微东
S
Securelist
大猫的无限游戏
大猫的无限游戏
Cloudbric
Cloudbric
Cisco Talos Blog
Cisco Talos Blog

飞絮落叶雪 - typecho

Typecho 几个小插件分享 Tpyecho 集成 Artalk 折腾小记 独立博客自省问卷15题 您的邮箱被管理员屏蔽无法评论 typecho CMS主题下载 垃圾站复活记 修改typecho的md解析器支持脚注 给博客添加几个小功能 整了一个typecho归档页面
typecho显示exif信息
Mr.He · 2017-10-13 · via 飞絮落叶雪 - typecho

此文所显示方式是@fooleap提供,感谢,所用原理见1,老何是代码盲,不懂,有兴趣的同学可以去看看。

好久之前做过,后来更换主题丢失,再次请教@fooleap,赶紧把方法记录下来,用以备忘。

前提条件,需要使用七牛作为图床,文件类型为jpg,试了一下在IE里是无法显示的。

步骤很简单:

一、下载js文件(文件在哪里?找不到?别试了,哈哈),放置在主题js目录下,在头部引用。

     <script src="<?php $this->options->themeUrl(); ?>js/jquery.qnexif.js"></script>

二、在post.js文件插入以下代码:

 $('.post img[src$=jpg]').qnexif();

完成,是不是非常简单?

如果你的主题文件没有post.js,我也不知道放在哪里了,别问我,问@fooleap,^_^

例图,把鼠标放在图片上,有没有高大上的感觉?

更新:
经过老何的不断摸索,主题必须要先引入Jquery.js,然后可以在post.php文件加入

     <script>  
    $('.post img[src$=jpg]').qnexif();
    </script>  

注意代码,文章内容块需要时class=post,如果是其他的请加入。

参考资料: