WordPress.org

Ready to get started?Download WordPress

Forums

Create a new page (14 posts)

  1. Robban
    Member
    Posted 8 years ago #

    Hi

    I'm trying to create a new page for a mailinglist, I want users to visit mydomain.com/signup.php and signup.php should use the template signup.php in the template dir...

    How to do this? I just get my code printed out, not the rest of the blog... :(

  2. Robban
    Member
    Posted 8 years ago #

    Let me add some info, I want the regular sidebar, header and footer to be included too...

  3. splosh
    Member
    Posted 8 years ago #

    Something like this......

    <?php

    require('./wp-blog-header.php');

    ?>

    <?php get_header(); ?>

    Your content here

    ?>
    <?php get_sidebar(); /* NOTE THAT SOME FOOTER.PHP FILES INCLUDE THE SIDEBAR AUTOMATICALLY!!! */ ?>

    <?php get_footer(); ?>

  4. WPChina
    Member
    Posted 8 years ago #

    Thank you splosh,
    But that is used when you want to make the page outside of WP, right? For example you can craft that in dreamweaver and then upload it to the server, right?

    Is there any way to create the page in WP and then also name it "signup.php" or "whatever.php"?

    I am new to WP--just oved from Movabletype this past weekend, so I might be missing something very simple here... ;)

    Thank you for your help.

  5. WPChina
    Member
    Posted 8 years ago #

    Actually, what I mean is that when I create a new page now, the URL looks like this:

    http://www.domain.com/archives/test/

    However how can I get it to instead be this:

    http://www.domain.com/archives/test.php

    Is this possible?

  6. WPChina
    Member
    Posted 8 years ago #

    In my old Movabletype I could easily add a name for the the new file like "test.php". It seems not possible on my new WP2.0.... when I add a slug for "test.php" the resulting url looks like this:

    http://www.domain.com/archives/testphp/

    Any idea how I can create test.php via the WP2.0 interface? I'm sure I am missing something very very simple...

  7. WPChina
    Member
    Posted 8 years ago #

    Hello,
    Does anybody have a tip on thisw? I have googled my query and also checked this website--I am sure it's a simple answer, but I can't figure out how to make a page called "test.php" via the WP2.0 interface....

  8. moshu
    Member
    Posted 8 years ago #

    You can not. Only a Page called "test".

  9. WPChina
    Member
    Posted 8 years ago #

    Ahh, thank you. :>

    I have an answer, but not one I wanted... OK, then I will just create these pages via Dreamweaver and upload on FTP.

    MT has this feature, so I hope maybe sometime soon WP can integrate it as well... very useful...

  10. moshu
    Member
    Posted 8 years ago #

    Why is sooo useful?
    (and you remind me of an old friend of mine who while in his third marriage always used to praise his previous wife... then wondered why he wasn't appreciated, LOL)

  11. WPChina
    Member
    Posted 8 years ago #

    Well, it's useful because then I don't need to use FTP/Dreamwever to create pages.

    And for old websites that do have .php or .html filetype names, it's easier to keep those links the same, instead or removing them and WP-ifying.

    Don't get me wrong, I am really happy to switch to WP, but no software is perfect and there are a few MT things that would be nice additions to WP.

  12. splosh
    Member
    Posted 8 years ago #

    Is this possible using modrewrite?

    I think theres a way to 'redirect' to the same page with a more friendly url.

  13. splosh
    Member
    Posted 8 years ago #

    I finally got my head round this

    if you have apache, mod_rewrite and can alter your .htaccess file --- add this..

    RewriteEngine On

    RewriteRule ^test.php actualurl

    so anyone clicking on (or typing in)YOURURL/test.php will see the contents of the actualurl and it will still say yoururl/test.php in the address bar.

  14. WPChina
    Member
    Posted 8 years ago #

    Beautiful! :->

    I will test it now!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.