CMS Tutorial
DEDECMS
How to use js to control the size of pictures in the DreamWeaver article pageHow to use js to control the size of pictures in the DreamWeaver article page

织梦文章页中怎么用js控制图片的大小?
织梦DEDECMS文章页中用js控制图片的大小
推荐学习:织梦cms
一般不建议使用expression,因为expression对浏览器资源要求比较 高。之前在做一个图集风格的时候在网上看到了一些用js控制图片的例子,我就分享一下给大家!
<script language="javascript">
function checkImg(mypic){
var xw=720;
var width = bigimg.width;
if (width > xw ) bigimg.width = xw;
}
</script>
<img id="bigimg" onload="checkImg(this)" src='/uploads/allimg/100701/co100F1194604-0.jpg' width='1023' alt='' />The above is the detailed content of How to use js to control the size of pictures in the DreamWeaver article page. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Dreamweaver Mac version
Visual web development tools

SublimeText3 English version
Recommended: Win version, supports code prompts!

Notepad++7.3.1
Easy-to-use and free code editor

Atom editor mac version download
The most popular open source editor

SAP NetWeaver Server Adapter for Eclipse
Integrate Eclipse with SAP NetWeaver application server.




