Home > CMS Tutorial > DEDECMS > body text

How to add drop-down menu to dedecms friendly link

藏色散人
Release: 2019-12-07 10:21:01
Original
1903 people have browsed it

How to add drop-down menu to dedecms friendly link

dedecmsHow to add a drop-down menu to a friendly link?

1) Implementation method

Find /include/taglib/flink.lib.php, find else if($type=='image'), and add the line above it:

Recommended learning: Dream Weaver cms

The code is as follows:

else if($type=='option') 
{ 
$link = "<option value=&#39;".$dbrow->url."&#39;>".cn_substr($dbrow->webname,$titlelen)."</option>"; 
}
Copy after login

2) Calling method

Collapse and expand XML/HTML

The code is as follows:

<select onchange="window.open(this.options[this.selectedIndex].value,&#39;_blank&#39;)"> 
<option>--相关链接地址--</option> 
{dede:flink row=&#39;24&#39; type=&#39;option&#39;/} 
</select>
Copy after login

3) Brief description

1. This extension retains all the functions of the original DedeCMS friendly link;

2. _blank is the opening method of the link. You can change it according to actual needs.

The effect is as follows:

How to add drop-down menu to dedecms friendly link

The above is the detailed content of How to add drop-down menu to dedecms friendly link. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template