WordPress.org

Ready to get started?Download WordPress

Forums

trouble with "redirect" plugin, need help. (12 posts)

  1. StarPilot
    Member
    Posted 7 years ago #

    I am trying to have one of my "page" links connect to an external URL.

    I have installed the redirect plugin. I created new page and went into the Custon Field and gave the key as "redirect" and the URL of the external site but somehow it doesnt seem to be working.

    Here is my page:
    Insidethemonster.com

    I want the "Message Forum" page link to lead to this link:
    href="http://www.insidethemonster.com/messageforum

    I think the problem MAY be that when you clikc the message forum link a different URL appears in the address field. Not sure why that is happening.

    Any ideas?

    Thank you!

  2. Samuel Wood (Otto)
    Tech Ninja
    Posted 7 years ago #

    I don't know about the redirect plugin, but you could do this with some simple page template action.

    Create a new file in your theme directory called, say, messageforum.php. Put this in it:

    <?php
    /*
    Template Name: Message Forum Page
    */
    header("Location: http://www.insidethemonster.com/messageforum/);
    exit;
    ?>

    Then make this the page template for your Page. Voila, instant redirect, no plugin needed.

  3. StarPilot
    Member
    Posted 7 years ago #

    Sounds like a great plan. I will give it a try.

    Do you know how to have it open a new window as in "_blank".

    Thanks for your help.

  4. StarPilot
    Member
    Posted 7 years ago #

    Also how to do I do this part..

    Then make this the page template for your Page. Voila, instant redirect, no plugin needed.

  5. Samuel Wood (Otto)
    Tech Ninja
    Posted 7 years ago #

    Edit the Page. Look on the right hand side of the screen for the page template drop down box.

  6. davidchait
    Member
    Posted 7 years ago #

    If you don't want to go the custom template route, you can also try my cg-redirect plugin. Does the location thing for you, no custom field, just enter in the page content:

    <redirect http://some.new.com/something />

    If it doesn't work off the bat, find the line at the top of the plugin file:

    $use_3xx_redirect = 302;

    and comment it out or set it to 0 (or other redirection code). The purpose of that is to try and tell search engines that the 'fake' page link isn't the real link to the content, it's just a redirection.

    -d

  7. StarPilot
    Member
    Posted 7 years ago #

    Where can I get your plugin and is it possible to have the link open a new page?

    Thanks!

  8. StarPilot
    Member
    Posted 7 years ago #

    Edit the Page. Look on the right hand side of the screen for the page template drop down box.

    I als cant find a page drop down box? The closest I see is page parent. Any ideas where to find it? Also can this method be used to link to a new window? (_blank)

  9. Samuel Wood (Otto)
    Tech Ninja
    Posted 7 years ago #

    The box on the right with the label of "Page Template".

    It won't appear until you actually *have* a Page Template in your theme folder. So first create the template like I told you to do above. THEN you edit your page. Just like I said above.

    And linking to a new window is a function of the LINK, not of the Page. If you want to link to _blank, change the page link to do so.

  10. StarPilot
    Member
    Posted 7 years ago #

    I am sorry not to understand. What page are you in where you see "page template"?

    I have created the php file and loaded it into the templates folder on my ftp.

    I go to "manage" then "pages" and edit but I do not see a "page template" button.

    I must be missing one step somewhere.

  11. obscure
    Member
    Posted 7 years ago #

    Starpilot - you are looking at the Write a post/page screen. You should be looking at the Edit Template screen.

    go to Presentation > Theme Editor

  12. Samuel Wood (Otto)
    Tech Ninja
    Posted 7 years ago #

    No, I'm talking about the Write/Edit Page Screen. On the right hand side. The box with a header of "Page Template" and a drop down menu?

    I really can't be any more clear without posting screenshots. Do you have the Page Template in your Theme's folder (in the folder of the theme that you're actually using)? This would be wp-content/themes/your-theme-name/messageform.php. Did you put it there?

    If you don't see the box, then you have not put the Page Template in the correct location.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.