Support » Fixing WordPress » Custom Page with full WordPress functionality

  • Resolved umbez

    (@umbez)


    i want to create a page on the server example.com/test/try.php. This page I DONT WANT IT TO BE TEMPLATE because the contents of this page are totally different from the rest of the site.

    My problem is i want the try.php to be able to use wordpress functions like is_user_logged_in(), get_user_meta();

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter umbez

    (@umbez)

    Thank you but it’s not what i wanted.

    Found the solution. i just needed

    global $wpdb;
    include ‘/path_to_blog/wp-blog-header.php’;

    on your of my php file. Funny that you gave a link to template creation when i said i dont want to create a template.

    i find funny that you did not understood that using a page/custom template technique is exactly what you are looking for and you what should be using.

    on other side – maybe you are looking for totally custom front-end engine, and yes – loading wp-blog-header.php is the way to go.

    but first – try to refine what is your object and do you understand the differences between proposed solutions.

    Thread Starter umbez

    (@umbez)

    Nope the page template solution did not work i even tried http://codex.wordpress.org/Conditional_Tags Conditional Tags.

    i think the nature of my request was too custom hence i capitalized the words ‘I DONT WANT IT TO BE TEMPLATE’ in my initial requests because i had already gone through the route.

    I found out that the way the page template constructed a page it caused some issues with scripts and css. I even tried to deregister scripts for the try.php file but it didnt work out.

    In short the solution i found is convenient and solves all my problems.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Custom Page with full WordPress functionality’ is closed to new replies.