Dream Dedecms How to open the specified column in a new window

Source: Internet
Author: User

Dream dedecms Template Web site lets you specify how the column opens in a new window:

When we use the Dream dedecms template, we sometimes need to make a column an external link. But in the Dede template site backstage inside the set up a good link, the page will all open in the current window, inconvenient to use. The following methods of success of your experiment are described below:

The first method, find the head.htm in the template
Will <li><a href= ' [field:typeurl/] ' >[field:typename/]</a></li>{/dede:channel}

Replace with the following
<li><a href= ' [field:typeurl/] ' target= ' _blank ' >[field:typename/]</a></li>{/dede:channel}

But there is a flaw in this approach, that is, all the columns will be opened in a new window, the use will appear very messy. So how do I get the specified column to open in a new window, let's look at the second method.

Find head.htm in a template
Will <li><a href= ' [field:typeurl/] ' >[field:typename/]</a></li>{/dede:channel}

Replace with the following
<li><a href= ' [field:typeurl/] ' [field:id runphp= ' yes '] if (@me = = ' 3 ') {@me = "target= ' _blank '";} else {@me = "";} [/field:id]>[field:typename/]</a></li>{/dede:channel}

Note that the above 3 is the column ID number that we want the new window to open, so it can solve the problem that the external link new window opens.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.