WordPress.org

Ready to get started?Download WordPress

Forums

Directory Structure (6 posts)

  1. lane
    Member
    Posted 10 years ago #

    I was never really familiar with b2, but it seems the root directory is a tad bit messy. Is there any plans to clean this up in future WP releases? Making it more OO? Just curious.

  2. Anonymous
    Unregistered
    Posted 10 years ago #

    I don't really think blog-ware is complex enough to require OO-level programming. Remember OO comes with a performance hit which is why you rarely see little projects done in Java or ASP.NET. On the other hand, I don't really think OO has anything to do with how messy the file structure is and I think some clean-up should be done..namely
    b2[commnents][trackbacks][pingbacks]popup.php <- really need to be a seperate file?
    b2login.php <- can we merge this with b2edit.php?
    b2[rss][rss2][rdf].php <- can this be just b2rss.php using query string to seperate what format of syndication? mod_rewriting things back to clean URLs isn't that hard to do you know, espcially when you have example.htaccess ready and you can stick the rewrite rules in there so newbies won't have to deal with regEx.
    b2calendar.php <- why isn't this in the template file?
    b2mail.php <- rarely publicly accessed, stick it in the include folder maybe?
    blog.header.php + b2config.php <- can probably be merged

  3. gfmorris
    Member
    Posted 10 years ago #

    I ranted on this in an install thread because it gave me issues with my install, but I think best practices should dictate that WordPress should not be installed into the root directory. It makes far more sense to me to have it in a subdirectory [/wordpress/ for the uncreative] not only to keep the root directory fairly clean but also because that dir could be obfuscated and protected by robots.txt if need be to increase security a tiny bit.
    This would, of course, require some files to be in a "safe zone" -- for one, the syndication files -- but I think it's worthwhile as a long-term goal.
    Or, well, a short-term one. I think it's just a couple php variables away.

  4. Matt Mullenweg
    Troublemaker
    Posted 10 years ago #

    One of the advantages of having a wp-admin directory is that you can htaccess protect it on a directory level if you so choose.

  5. gfmorris
    Member
    Posted 10 years ago #

    Sure. But shouldn't the whole totality of the WP install be similarly in a directory?

  6. FireMotion
    Member
    Posted 10 years ago #

    Having a different location for index.php doesn't require all that too much coding. But my site has these locations:
    /index.php (my index page)
    /m_blog.php (my archives page)
    /wordpress/ (my wordpress directory)
    So with each release, I have to edit at least these files (if I remember correctly):
    /wordpress/index.php
    /wordpress/wp-comments.php
    /wordpress/wp-includes/template-functions.php
    And then I include the /wordpress/index.php in my (edited) /index.php and /m_blog.php.
    This root directory "feature" that WordPress incorporated from b2 doesn't make it very flexible.
    It'd be more flexible if WordPress allowed this out-of-the box, but it doesn't. Yet?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.