• I’m not sure if this is a template question or a WP question. I have a simple PHP script I run great by putting in it’s own folder and placing it on my WP website and navigating to the that folder. What I want is to put the site look and feel around that code. I created a “page” within WP and even downloaded a plugin to launch PHP code and it seems to work. I get my initial form but entering something into it and submitting I get Not Found
    Sorry, but you are looking for something that isn’t here. The URL link seems to be the same after I submit:

    https://froggydomains.com/check-domain-availability/

    I either need to make what i have work or wrap the look (template) around the page I do have that works great.

    thanks,
    Jonathan

Viewing 1 replies (of 1 total)
  • Hi

    I suggest you use a custom page template.
    First read this
    https://codex.www.ads-software.com/Pages#Creating_Your_Own_Page_Templates

    What you will do:
    copy the contents of your theme’s page.php file into a new file – call it for this example page_myscript.php
    Add this code at the very top of the script

    <?php
    /*
    Template Name: MyScript
    */
    ?>

    Now go to WP admin and create a Page. To the right of the page edit box, assign it a custom template of MyScript

    Now in file page_myscript, in the post display area, either paste in your PHP code or else insert it as an “include” statement. You can remove any of the loop code that is not relevant to your script. However leave the DIV’s surrounding the loop as these are what display your script’s output in the appropriate part of the WP page.

    You now have a page that includes the WP header at the top, and sidebar and footer at the bottom, and your PHP code in the page contents area.

    Your WP page will have been assigned a permalink when you created the page in the WP editor. You can run the script by navigating to that permalink URL.

Viewing 1 replies (of 1 total)
  • The topic ‘please help’ is closed to new replies.