Close

Layers Help & Support

Layers 2.0.10 Update

Layers 2.0.10 Update

Removing the Envato Marketplace listings.

  • Fixed Image Ratio button in the Post widget
  • Removed redundant Envato Market listings

UPDATE LAYERS View on GitHub

How to Verify WordPress Page Slugs, Duplicates & Links

How To  Tutorials  Last Updated: Time to Read: 6 minutes

This guide walks you through cleaning up your pages and WordPress page slugs once you are ready to build your navigation. It also provides tips for how to maintain pages to reduce the risk of broken links or confusion.

Page cleanup is essential to ensure your menus link to the correct, SEO-friendly and final version of your pages. For sites running WooCommerce, each page component of your shop is linked in WooCommerce settings, therefore duplicate shop pages can cause a myriad of problems.

Skip this section if your home page is not the problem.

  1. Go to Pages
  2. Your pages should be listed here alphabetically. If not, click the Title heading until they are sorted.
    • title-pages
  3. Locate the page with the Front Page label. This indicates which page is set as your home page currently.
    • frontpage
  4. Edit the page and verify this page has the content you expect and is the correct home page.
  5. If this is the wrong homepage, or you have duplicates, return to the Pages list and edit the “wrong” pages:
    • Edit the Title with something that will reduce your confusion and is not already in use. For example, if you have an old Home page from a different theme, and a new Home page using Layers Template. name the old one Home (Old).
    • Click into the Permalink box, remove the Page Slug, and click OK
    • removeslug
    • Click Update on the page. It will set an appropriate slug automatically.
    • Alternatively, delete these pages if you no longer need them
  1. Go to PAGES
  2. Your pages should be listed here alphabetically. If not, click the Title heading until they are sorted.
    • title-pages
  3. Look for duplicates. Duplicates should be obvious, but may also have similar names, such as Front Page and Home. Duplicates created in the Layers pages will have (Copy) after the title.
  4. When duplicates are found, edit both to determine which page is the “good” copy you will use on your site.
    • When dealing with WooCommerce pages such as Shop, My Account, Checkout and Cart, simply delete the older version.
    • For Layers Pages, Edit your Page button to preview the page
    • For normal pages, click the Preview button
  5. Delete the copies you will not use. If you have duplicates to work out different layouts or need to save them for some other reason, edit each of them and:
    • Edit the Title with something that will reduce your confusion and is not already in use. For example, if you have two Blog pages, one that uses Layers and one that uses the Blog template, decide which one you will use on your site, then name the other one Blog Alternate.
    • Click into the Permalink box, remove the Page Slug, and click OK
    • Click UPDATE on the page. It will set an appropriate slug automatically.
    • removeslug

At this point you should have a clearer picture of what pages are setup for your site and which ones are the valid ones. In addition to fixing titles, any pages you do not intend to use on your site right now should be set to the Pending Review status. This ensures they cannot be displayed on the front end of your site through accidental linking or RSS feeds.

  1. To change these values quickly, check off each page you will set to Pending, then choose Edit from the Bulk Edit drop-down at the top.
  2. Select Pending Review from the Status drop-down and click Update at far right.

bulkedit

Why Pending Review and not Draft?

While Draft is a more semantic status to use, it is not treated the same way in WordPress as a Pending or Published page in terms of auto-save and revisions. This is critical for Layers pages, as Drafts will have refresh and revision issues in the customizer until they are Saved and published once.

Your pages are now even easier to distinguish from one another, as your “live” pages will show the Published status, and your alternates, drafts and tests will show Pending. You can filter these lists now by clicking on the status links at the top of the Page list:

statuslinks

The next step is to clean up your Page slugs, or the page’s name in the URL in your browser.

Page linking within WordPress is done through the page ID. This is translated into the page’s permalink. Depending on the type of “pretty permalink” you have configured in WordPress, your page permalink may be represented by a slug (the page title in a lower-case hyphenated form) or the date. Even if date permalinks are used, you must still ensure your page slugs correspond to your page title appropriately.

  1. Go to Settings  → Reading
  2. Ensure Post Name is selected or one of the date options is selected.
  3. Click Save to regenerate all links

When you create a duplicate of a page, or a page with the same title as another page, WordPress will append a number on the end of the page slug. For example, you might have two pages called Home, but only one has the correct slug of “home”, the other has “home-2”.

Assuming you have gone through the above to verify the valid pages, titles and statuses:

  1. Click on the Trash link on the Pages listing
  2. Click Empty Trash. Items in the trash will keep hold of their slugs until they are deleted, so it is important to clear your trash regularly!
  3. Click Published to view your published pages.
  4. Hover over the page title of the first page and choose Quick Edit
  5. Here you can see the Title and Slug for the page. Ensure the slug matches the title and remove any numbers. If you prefer a slug be created for you, simply delete it and click Update and it will be regenerated from the title.

Now you must ensure the links in all of your menus are correct.

  1. Go to AppearanceMenus
  2. Select your main menu to edit
  3. Expand the links and delete any which are noted as invalid
  4. Expand and delete all links that correspond to pages you changed in the above process.
  5. Replace the page links by checking off your valid published oages in the Pages list on the left and choose Add to Menu
    • This list will not show you statuses, which is why it is doubly important your pages have unique titles!
  6. Click Save Menu
  7. Test the menu on your site to ensure the links open the pages you have verified as valid
  8. Repeat to fix any other menus you have created.

The following tips should help avoid content confusion in the future:

  1. When using the Layers Page wizard, always give the page a unique title
  2. When using the Duplicate function, wait for the success message to appear. In most cases it is best to duplicate the page as a backup, then edit the original with changes. If you intend to publish duplicates, always change the title to something unique and remove the (Copy) to ensure the page slug remains identifiable.
  3. Do not create duplicate categories and tags. For example, if you have a post category called “travel”, you do not need to tag your posts with “travel” as the category already provides that categorization. The same goes for Products – “ties” would be an appropriate category, whereas the tags associated with the tie should describe its use, properties, make or brand.  Diplicating category, tag, and page slugs becomes a problem mainly when using SEO plugins that “strip the category base”, leaving you with a page permalink and a category permalink that are identical.
  4. Only publish pages you intend to use and link. This narrows down the options in the menu manager and reduces the chance of accidentally linking to the wrong page.
  5. Always empty the trash
  6. Be careful when importing demo content files – in most cases these files should only be used on new WordPress installs, or when you know exactly what is in the file and have determined it will not conflict with any existing content.

 

 

Did you know?

Our friends at Jetpack are doing some incredible work to improve the WordPress experience. Check out Jetpack and improve your site's security, speed and reliability.

Jetpack