SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Addict
    Join Date
    Oct 2008
    Location
    Virtual World is my location
    Posts
    311
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)

    Question htaccess and speling

    Hi,
    There is a minor issue that I am facing and have been unable to solve.

    It is using wordpress and regular folders and trying to access regular HTML files in subfolders

    For example here is the scenario.

    I have wordpress installed and along with that have folders like Sales / Marketing etc. I want that if users type like domain . com / Sales or domain . com / sales then the user should be able to access that folder. I have sub sites in it which are made in regular html.

    To do this I added the mod speling code
    CheckSpelling
    CheckCaseOnly

    Now this works by itself (without the wordpress htaccess code being added)

    As soon as wordpress code is added, the speling directive stops working and work only on wordpress urls and not on regular sub folder urls. like domain . com / Selling-Tips / or domain . con / selling-tips / works fine in wordpress but the subfolders cannot be accessed using any case.

    Could anyone suggest why the code does not work for regular html urls in subfolders and is there any way out by which we can force the htaccess to check all folders and allow URLs in any case?

  2. #2
    Certified Ethical Hacker silver trophybronze trophy dklynn's Avatar
    Join Date
    Feb 2002
    Location
    Auckland
    Posts
    14,644
    Mentioned
    19 Post(s)
    Tagged
    3 Thread(s)
    jaag,

    Please show your .htaccess ... in which I would expect to see exclusions for your subdirectories BEFORE WP greedily snaps-up all URIs and redirects to its index.php for processing.

    Also, you may want to explain mod_speling for others as it's a wonderful Apache module (unless you're using WordPress in which case it should be turned off as it should be unable to alter the URI to resemble files within the WP structure).

    Regards,

    DK
    David K. Lynn - Data Koncepts is a long-time WebHostingBuzz (US/UK)
    Client and (unpaid) WHB Ambassador
    mod_rewrite Tutorial Article (setup, config, test & write
    mod_rewrite regex w/sample code) and Code Generator

  3. #3
    SitePoint Addict
    Join Date
    Oct 2008
    Location
    Virtual World is my location
    Posts
    311
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the direction @dklynn. But I already moved the other files to another folder which I found was easier and moved wordpress to another folder so there is no clash and all is fine now.

    For the reference of other users > mod_speling basically is a great way to fix issue related to Case while typing a URL. But again it needs to be used with care as it is resource intensive too. Its an easy way to fix some issues you might face when you move from a windows to a linux hosting or at times even if you are having users typing a different case an it results in a non existing url. The mod speling tries to fix these issues.

  4. #4
    Certified Ethical Hacker silver trophybronze trophy dklynn's Avatar
    Join Date
    Feb 2002
    Location
    Auckland
    Posts
    14,644
    Mentioned
    19 Post(s)
    Tagged
    3 Thread(s)
    Thanks, jaagare.

    Folks, mod_speling can also correct minor typographical errors (by trying to match the request with your file names). That makes it a great tool for those webmasters expecting visitors to enter URLs by hand (personally, I prefer to provide a 404 script for that). mod_speling but it is a little-known, fabulous tool from Apache.

    Please note that we have spelled the module's name correctly. The Apache people thought it funny to misspell mod_spelling by eliminating one of the L's - I have to agree, although this is a very minor point (of interest).

    Regards,

    DK
    David K. Lynn - Data Koncepts is a long-time WebHostingBuzz (US/UK)
    Client and (unpaid) WHB Ambassador
    mod_rewrite Tutorial Article (setup, config, test & write
    mod_rewrite regex w/sample code) and Code Generator


Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •