1. This website uses cookies to improve service and provide a tailored user experience. By using this site, you agree to this use. See our Cookie Policy.
    Dismiss Notice

How to create custom URL in wordpress?

Discussion in 'BlackHat Lounge' started by SkyrocketSEO, Jul 7, 2015.

Thread Status:
Not open for further replies.
  1. SkyrocketSEO

    SkyrocketSEO BANNED BANNED

    Joined:
    Nov 5, 2012
    Messages:
    4,619
    Likes Received:
    12,101
    Hi, lets say I need to create URL like this sitename.com/something/chf_1.php or sitename.com/something/mbb2.HTM
    As you can see problem is in the end of the URL , because previous site (that we need to redirect) was HTML site, with php and HTML
    So, I want to have these custom URLs created. Any way to do this ?
     
  2. SkyrocketSEO

    SkyrocketSEO BANNED BANNED

    Joined:
    Nov 5, 2012
    Messages:
    4,619
    Likes Received:
    12,101
    No one knows? Or there is no way?
     
  3. ginza

    ginza Registered Member

    Joined:
    Nov 22, 2009
    Messages:
    67
    Likes Received:
    20
    Location:
    In your heart
    go to your settings > permalinks, in custom structure field section and add extension (php/html/even custom is ok) in the end.
    it works for me. hope it also works for you.

    for example: I "create" .add extension.
    C3F29i4.png
     
    • Thanks Thanks x 1
  4. bahus

    bahus Regular Member

    Joined:
    Jun 4, 2014
    Messages:
    402
    Likes Received:
    115
    Gender:
    Male
    • Thanks Thanks x 1
  5. mickyfu

    mickyfu Elite Member

    Joined:
    Dec 14, 2011
    Messages:
    9,356
    Likes Received:
    27,107
    Occupation:
    King Of Crypto C
    Location:
    Solihull Young Offenders
    I also had this problem and found no way around it. The best way I could find is not using WordPress.
     
    • Thanks Thanks x 1
  6. bullsbears

    bullsbears Power Member

    Joined:
    Feb 17, 2014
    Messages:
    569
    Likes Received:
    170
    Occupation:
    Derivatives Trader
    Location:
    Wall Street
    If the posts are limited and low in number then you can manually 301 redirect the previous url to new url otherwise it's a tedious job.

    Easier solution would be to just add "html" or "php" (whatever you want to use) suffix to urls without messing with the url structure completely.
    Wordpress permalink allows you to append any extension you want at the end of the url. If the previous site was a static site with html extension then you can easily add html at the end of all posts using permalink custom url feature.

    Enlighten more about the issue and let's see if a solution is carved out.
     
    • Thanks Thanks x 1
  7. SkyrocketSEO

    SkyrocketSEO BANNED BANNED

    Joined:
    Nov 5, 2012
    Messages:
    4,619
    Likes Received:
    12,101
    Thanks all, I guess I will be able to use .php but I will need to change all links on my site that are pointing to other pages without .php (boooring). Thanks again
     
  8. Apricot

    Apricot Administrator Staff Member

    Joined:
    Mar 26, 2013
    Messages:
    14,518
    Likes Received:
    9,961
    Gender:
    Female
    Occupation:
    BHW Admin
    Location:
    The Cloud
    Home Page:
    Assuming that the pages you're redirecting to have the same url except the file extension at the end, you can use an htaccess rule to change html extensions to php. You'll need to check the code but something like this might work:

    Code:
    RewriteRule ^(.*)\.html$ $1.php
     
Thread Status:
Not open for further replies.