Wordpress: How to change page name from ?page_id=2 to "about me"

15 replies
  • WEB DESIGN
  • |
Hi Guys

On one of my blog, when I click a page tab, the url says /about but on another it says ?page_id=2. Where do I go to set this so that is says the actual page name like "about" instead of ?page_id=2

Many thanks
Phil
#about me #change #page #pageid2 #wordpress
  • Profile picture of the author Istvan Horvath
    wp-admin > Settings > Permalinks

    When you change the permalinks for posts for anything but default... the Pages will also have their title/slug in the permalink.
    Signature

    {{ DiscussionBoard.errors[3114153].message }}
    • Profile picture of the author vegasfitness
      Originally Posted by Istvan Horvath View Post

      wp-admin > Settings > Permalinks

      When you change the permalinks for posts for anything but default... the Pages will also have their title/slug in the permalink.
      For SEO I want the permalink to display the page name for keyword relevance, right?

      Will setting permalinks to date/page/name be better for SEO than custom?
      {{ DiscussionBoard.errors[3114246].message }}
  • Profile picture of the author mediasurgeons
    You need to change your permalinks to custom structure and copy this code: /%postname%.html
    {{ DiscussionBoard.errors[3114256].message }}
    • Profile picture of the author Istvan Horvath
      Originally Posted by jacobjoseph View Post

      You need to change your permalinks to custom structure and copy this code: /%postname%.html
      Can you give any logical reason why would he need the .html extension?
      Signature

      {{ DiscussionBoard.errors[3114270].message }}
      • Profile picture of the author mediasurgeons
        Originally Posted by Istvan Horvath View Post

        Can you give any logical reason why would he need the .html extension?
        That is the code I have used to change wordpress pages from "?page_id=28".

        It provides a solution to what he is asking and that code has worked fine for me regardless of the html or no html. No need to overthink minor details like that.
        {{ DiscussionBoard.errors[3114407].message }}
        • Profile picture of the author SteveJohnson
          Originally Posted by jacobjoseph View Post

          It provides a solution to what he is asking and that code has worked fine for me regardless of the html or no html. No need to overthink minor details like that.
          Adding an extension to the permalink structure is not a 'minor detail'. In certain situations, it can cause quite a lot of trouble including unnecessary 404 errors.
          Signature

          The 2nd Amendment, 1789 - The Original Homeland Security.

          Gun control means never having to say, "I missed you."

          {{ DiscussionBoard.errors[3120619].message }}
          • Profile picture of the author thatsme
            You can use this snippet, in the Custom Structure, if you want the category and the post to show in the URL:

            /%category%/%postname%/

            http://domain.com/website-design/about

            Good luck!
            {{ DiscussionBoard.errors[3128568].message }}
            • Profile picture of the author marimar
              Go to Permalink settings, Change your Common Setting from default to Custom Structure, and field the content with /%postname%/
              {{ DiscussionBoard.errors[3154188].message }}
              • Profile picture of the author Jerry-Leventer
                Here's a possible solution:

                -------------------------------------------------------------------------------------------
                Use this information AT YOUR OWN RISK. Backup Your Database before making any changes.
                --------------------------------------------------------------------------------------------

                Take a look at the Database Table: wp_posts

                You can access the database via cPanel > phpMyAdmin

                When phpMyAdmin first opens, you need to click on the correct database name.

                On the left column, you should see the table called (table prefix)_posts, where "table prefix" is usually "wp_" by default, unless you changed it in your wp-config.php file.

                Click on that name, it will show you the pages of your site. You may need to search for them if you have a lot of pages or posts.

                To search, go back to the root area of the database. (use the breadcrumb links at the top, or just click on the database name again.) Then, click on the "Search" tab at the top of the page (in phpMyAdmin).

                Once you found that page, click on the pencil icon to edit it. Look for the "?page_id=" string.
                {{ DiscussionBoard.errors[3216252].message }}
  • Profile picture of the author Istvan Horvath
    There is NO date in the permalinks for Pages. Ever.
    Posts and Pages are 2 different things... Learn the basics: Glossary « WordPress Codex
    Signature

    {{ DiscussionBoard.errors[3114261].message }}
  • Profile picture of the author phil.wheatley
    Hi Guys

    Thanks for your help. Yeah, this was specifically for pages, not posts, so my question has been answered.

    Many thanks!!!
    Phil
    Signature



    It's still not working for you??? Need direction?...
    ---->>>> BrainDirection.com <<<<----
    {{ DiscussionBoard.errors[3114307].message }}
  • Profile picture of the author vegasfitness
    Now having changed the permalink settings from default, the page will not even come up! Am I stuck with default or is there a workaround option?
    {{ DiscussionBoard.errors[3114370].message }}
    • Profile picture of the author vegasfitness
      Yes, I do understand the difference in pages and posts. However, I would like to change the permalink for both for the same seo reasons. Help is appreciated.

      Perhaps I will just go back to good ole WP knowledge base where I will not deal with condescension. Using the forum is new to me and now I am a bit taken aback. See ya!
      {{ DiscussionBoard.errors[3114400].message }}
  • Profile picture of the author affilorama-portal
    Originally Posted by marimar

    Go to Permalink settings, Change your Common Setting from default to Custom Structure, and field the content with /%postname%/
    This is spot on.

    You can also get rid of the slash at the end if you want to, so that it is /%postname%

    With /%postname%/ you will get http://yourdomain.com/yourpage/

    With /%postname% you will get http://yourdomain.com/yourpage
    {{ DiscussionBoard.errors[3216317].message }}
  • Profile picture of the author AllenMack
    I always found video solution very preferable
    https://youtu.be/g8wLjKkh3qw
    {{ DiscussionBoard.errors[10714924].message }}

Trending Topics