Add the jump function on the wordpress add page

Source: Internet
Author: User

Sometimes you need to add an address you want on the WP page, such as an independent message board or bbs ..
(You can also add it to the menu)
However, my template does not support custom menus. I do not know PHP, but how to do it. I also want to add an independent page and jump to the address I want.
After groping for a long time, I picked up the scriptures from a cow. After a while, I got it out ..

First, create a file named link-to.php with the following content:

View sourceprint? 1 <? Php

2 /*

3 Template Name: link

4 */

5?>

6 <script> location = "address to jump"; </script>


Then upload the link-to.php to the directory of the topic used, for example, the D1 topic, upload to/wp-content/themes/D1,
Create a page in the background and select "link-to" as the Page Template (the "link to" option appears after the file is uploaded );
Location = "the address you want to jump to", so that you can click the page to jump to the address you want to go.

Original article, reprinted Please note: Reprinted from Ps7isys Blog

 

Related Article

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.