网站首页 美食营养 游戏数码 手工爱好 生活家居 健康养生 运动户外 职场理财 情感交际 母婴教育 时尚美容

css设置光标为拖动

时间:2024-10-13 00:04:18

1、打开html前端开发软件,创建一个html页面,然后在这个页面上创建<div>添加class类,同时输入一些文字。代码:<div class="move">鼠标放上,鼠标指针变为可拖动</div>

css设置光标为拖动

3、保存html页面后使用浏览器打开,鼠标移动到<div>上即可看到效果。页面所有代码:<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title></title> <style type="text/css"> .move{ cursor: move; } </style> </head> <body> <div class="move">鼠标放上,鼠标指针变为可拖动</div> </body></html>

© 2025 智德知识库
信息来自网络 所有数据仅供参考
有疑问请联系站长 site.kefu@gmail.com