Page Links To

Beskrivning

This plugin allows you to make a WordPress page (or post or custom post type) link to a URL of your choosing, instead of its WordPress URL. It also will redirect people who go to the old (or ”normal”) URL to the new one you’ve chosen.

Common uses:

  • Set up navigational links to non-WordPress sections of your site or to off-site resources.
  • Publish content on other blogs (or other services, like Medium) but have them show up in your WordPress posts stream. All you have to supply is a title and a URL. The post title will link to the content on the other site.
  • For store operators, you can link to products on other retailer’s sites (maybe with an affiliate code) but have them show up like they’re products in your store.
  • Create a ”pretty URL” for something complicated. Say you have https://example.com/crazy-store-url.cgi?search=productId&sourceJunk=cruft … just create a WordPress page called ”My Store” and use Page Links To to point it to the ugly URL. Give people the new URL: https://example.com/my-store/ and it will redirect them!

Contribute

You can contribute (or report bugs) on Github.

Skärmdumpar

  • The Page Links To meta box in action
  • The quick Add Page Link dialog.

Installation

  1. Upload the page-links-to folder to your /wp-content/plugins/ directory.

  2. Activate the ”Page Links To” plugin.

Existing Content Usage:

  1. Edit a page (or post or custom post type).

  2. Below, find the Page Links To widget, select ”A custom URL”, and add a URL of your choosing.

  3. Optionally check the box to enable link opening in a new browser tab.

  4. Save the page (or post or custom post type).

  5. Done! Now that content will point to the URL that you chose. Also, if anyone had the old WordPress URL for that content, they will be redirected to the custom URL if they visit.

Creating New Page Links:

  1. Click Pages > Add New Page Link.

  2. Provide a title and a destination URL.

  3. Optionally provide a custom slug, which will be used in creating a local redirect URL.

  4. Click Publish.

Vanliga frågor

How do I make it so that a page doesn’t link to anything? I’d like to use it as a dummy container.

Just use ”#” as the link. That won’t go anywhere.

Can this be used to repoint categories to an arbitrary URL?

Not currently. Please contact me if you’re interested in that functionality.

My links are sending me to http://myblog.com/site-i-wanted-to-link-to.com … why?

If you want to link to a full URL, you must include the http:// portion.

Can I link to relative URLs for URLs on the same domain?

Yes. Linking to /my-photos.php is a good idea, as it’ll still work if you move your site to a different domain.

Recensioner

28 november, 2019
I needed a permanent link to a pdf file that would periodically change. Of course because of the way wp stores files, renaming the file does not solve the problem. With this plugin I have a page with a permanent link that redirects to the pdf. When I upload a new pdf, I just replace it's url in the Add Page Link, that I conveniently find under the Pages with link icon. The only problem this plugin has is its description. I think more people would use it if they knew what it actually does. Oh, yes and once installed, finding the interface (Under Pages | New page | Add Page Link). Also, when you add it, it does not appear automatically in the Page list. It does so only when you refresh it, so you are not sure if you've actually done something and how you edit it. However once you get it, it is actually very simple to use. A screenshot more in the description would probably do the job.
7 november, 2019
Such a simple thing, but makes navigation so much easier when linking to alternate sites or subsites. A great little plug in thank you.
24 augusti, 2019
Activating this plugin restyled my main menu by adding "left: 85.5px". I have no idea why a plugin which is meant to redirect links would affect styling of an unrelated feature but it does. Deactivating it immediately resolves the issue, so the plugin must conflict with my (popular) theme. I see a lot of people complaining about conflicts recently in the support thread and yet there are very few answers. I asked for support and was ignored - https://wordpress.org/support/topic/plugin-activation-breaks-menu/ This is a big shame as the plugin works great otherwise. Happy to change my review if the issue is resolved.
23 augusti, 2019
Thanks. This plugin solved a big portfolio problem with wanting to use external links in the Avada portfolio title instead of pointing to the portfolio page. Worked like a charm. You are awesome!
20 juli, 2019
This saved me from having to create a cpt just for the redirect function. I know that I can use the built in WP metaboxes, but didn't want my client to have to type in metadata - this way all they need to do is put in the url they want to go to. Thanks Mark
12 juli, 2019
exactly what I was looking for, thank you very much !!!!!!!
Läs alla 126 betyg

Bidragsgivare och utvecklare

”Page Links To” är programvara med öppen källkod. Följande personer har bidragit till detta tillägg.

Bidragande personer

”Page Links To” har översatts till 27 språk. Tack till översättarna för deras bidrag.

Översätt ”Page Links To” till ditt språk.

Intresserad av programutveckling?

Läs programkoden, kika på SVN-filförvaret eller prenumerera på utvecklarloggen via RSS.

Ändringslogg

3.2.1

  • Bug fixes

3.2.0

  • Block Editor improvements
  • Smaller build

3.1.2

  • Customizer bug fix

3.1.1

  • Block Editor bugfixes

3.1.0

  • Support for the Block Editor (Gutenberg)

3.0.1

  • Fixed a PHP warning caused by some themes

3.0.0

  • Quick page link adding UI
  • External link indicator
  • Short URL copying
  • Short URL display on edit screen

2.11.2

  • Newsletter

2.11.1

  • Restore PHP 5.3 compatibility, broken in 2.11.0

2.11.0

  • Code cleanup

2.10.4

  • New screenshot and assets

2.10.3

  • Fix readme.txt

2.10.2

  • Fix bug in Internet Explorer

2.10.1

  • Version bump

2.10.0

  • Switch to ES6 and Babel from CoffeeScript
  • Remove jQuery as front-end requirement
  • Bump supported version

2.9.10

  • Bump supported version

2.9.9

  • Back out jQuery protection code that causes issues on some sites

2.9.8

  • Added a Russian translation
  • Maintain a reference to WordPress’ jQuery version
  • Modernize build tools

2.9.6

  • Fixed an issue with redirects that have @ in the URL
  • Fixed issues with setting and displaying custom URLs for attachments

2.9.5

  • Made relative URLs absolute in redirects
  • Fixed a potential PHP warning
  • Registered the metadata fields for better XML-RPC integration

2.9.4

  • Add Hungarian translation.

2.9.3

  • Only rely on an internal cache for wp_list_pages() processing, and time-limit the cache.
  • Work around some weird edge cases

2.9.2

  • Restore WordPress 3.4.x functionality.

2.9.1

  • Fix a redirection bug in 2.9

2.9

  • Respect ”open in new tab” setting in more custom situations, like custom loops and widgets.
  • Add unit tests
  • Massive code refactoring
  • Added translations for: Spanish, Catalan, French.

2.8

  • Added translations for: Swedish, Hebrew.

2.7.1

  • Fix an array bug

2.7

  • Fix a PHP notice
  • Use JS to open links in an external window, even outside of nav menus
  • Completely revamped UI
  • Several translations

2.6

  • Proper linking for custom post types (insead of just a 301).
  • Fixed a bug that prevented links from opening in a new window.
  • Notifies people when they are editing content that uses this plugin.
  • Removed the option to set redirection type. Always 301, now.
  • Removed some PHP4 and WP 2.8 back compat stuff.

2.5

  • Allow all show_ui post types to use the meta box.
  • Introduce a filter so a plugin can remove a post type from the list.
  • Target filtering for WordPress nav menus.
  • Silence some PHP notices. Props Ross McKay, Bill Erickson.

2.4.1

  • Fixed typo that was preventing 302 redirects from working. props Ryan Murphy.
  • Fixed a random PHP notice

2.4

  • Rewrote using Singleton best practices
  • Fixed a regex bug that could break current menu highlighting. props skarab

2.3

  • Fixed a bug with current menu item highlighting

2.2

  • Cleanup
  • compatibility tweaks to interoperate with a few other plugins
  • prompt http:// and auto-add it if a URL starts with ”www.”

2.1

  • WordPress MU compatibility for when switch_to_blog() is used… it now uses $blog_id to keep their caches from stomping on each other

2.0

  • Allow one-character URLs so that things like ”#” (dummy link) are possible

1.9

  • Fixed ”open in new window” functionality