• At front end I fetches some links from mysql db table like:

    `<a href=”https://localhost/my_site/detail/Link-1″>Link 1</a>
    <br />
    <a href=”https://localhost/my_site/detail/Link-2″>Link 2</a>
    <br />
    <a href=”https://localhost/my_site/detail/Link-3″>Link 3</a>`

    and from admin side Setting -> Permalink I set https://localhost/sparcs/sample-post/
    and also create a page and named detail whose url is exactly https://localhost/my_site/detail/

    but when I click to any links WP says

    Apologies, but the page you requested could not be found. Perhaps
    searching will help.

    though I could use <a href="https://localhost/my_site/detail/3">Link 3</a> and it works fine & I could get url info using pathinfo($_SERVER['REQUEST_URI']);.

    Actually I create custom url in by db table and then show these url on my WP page leftbar and want if I click it wp show the page and I could be able to catch url info with pathinfo($_SERVER['REQUEST_URI']);

    I also used Custom Structure and set https://localhost/my_site/detail/url but not work.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Muhammad Sajid

    (@webspot49)

    I have read this in detailed & this does not cover my problem. Let me clear more. My links like Link 1, Link 2 are not like a regular WP posts I created them form my framework in mysql db table and fetch in left sidebar on href I used url field (fetches from db table) which is Link-1, Link-2 in this case and on detail page template I just fetch records from db table & show.

    Now if I use id field it works fine but when i replace id field with url field it says

    Apologies, but the page you requested could not be found. Perhaps
    searching will help.

    Now it is more clear

    I thing it is something from WP boot-striping

    Thread Starter Muhammad Sajid

    (@webspot49)

    I think it might be solve using
    rewrite.php in

    wp-includes/rewrite.php

    but I don’t know how & which function should be modify.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WordPress: Custom URL’ is closed to new replies.