; then add the code "Font:< where the size needs to be called /small>[Large" will do."/> ; then add the code "Font:< where the size needs to be called /small>[Large" will do.">

Home >CMS Tutorial >DEDECMS >How to allow users to choose the font size on the DreamWeaver article page

How to allow users to choose the font size on the DreamWeaver article page

藏色散人
藏色散人Original
2019-12-03 09:38:582253browse

How to allow users to choose the font size on the DreamWeaver article page

How to allow users to choose the font size on the DreamWeaver article page?

The article page of DEDECMS allows users to choose the font size

Recommended learning:CMS

1. Put the following code After the 93f0f5c25f18dab9d176bd4f6de5d30e and before 9c3bca370b5104690d9ef395f2c5f8d1 of the content page template.

<script Language="JavaScript"> 
function FontZoom(fsize){ 
var ctext = document.getElementById("content"); 
ctext.style.fontSize = fsize +"px"; 
}</script>

2. Put the following code where the case needs to be called:

<small>字体:</small> [<a href=&#39;javascript:FontZoom(16)&#39;>大</a> 
<a href=&#39;javascript:FontZoom(14)&#39;>中</a> <a href=&#39;javascript:FontZoom(12)&#39;>小</a>]

3. Use the code in the BODY part of the content page:

Put the original template in 5d1e94760349a02ec7e3e05385bc999a is changed to 0f3dc7b4a2286c9e1abb5bbcb1259a1d

Note: If you are not using the official template, you need to modify the corresponding The code may not be the content, please pay attention!

The above is the detailed content of How to allow users to choose the font size on the DreamWeaver article page. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn