PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

PREVIEW is bringing up a 404 error. (Running on Windows 2008 and IIS7)

  1. I have seen a few postings for this, but none that provided a viable answer for me.

    I am running Wordpress on a Windows 2008 server, running IIS7. All permissions look fine with my install. All pages come up fine, etc.

    You can see it at: http://www.greatersba.org/

    But when I try to PREVIEW the form, it's trying to go to:
    http://www.greatersba.org/wp-content/plugins/gravityforms/preview.php?id=1

    And I get a 404 File or Directory not found error message.

    Some of the 'header' information (when I use Firebug to see the issue) says:

    Cache-Control no-cache, must-revalidate, max-age=0
    Pragma no-cache
    Content-Type text/html
    Expires Wed, 11 Jan 1984 05:00:00 GMT
    Last-Modified Sat, 16 Oct 2010 13:39:10 GMT
    Server Microsoft-IIS/7.0
    X-Pingback http://www.greatersba.org/xmlrpc.php
    X-Powered-By ASP.NET
    Date Sat, 16 Oct 2010 13:39:09 GMT
    Connection close
    Content-Length 1245

    What can I do to correct this issue?

    I am hosting the site on a VPS (and I have remote desktop access to the server).

    The file xmlrpc.php does exist in the root of my site.

    Please tell me what I can do to resolve this.

    Again .. everything else on my site is working fine. What is it about Gravity Forms that is different and not using permalinks (like the rest of my site)??

    Thanks,
    Gary Gordon

    ====================================

    JUST A FOLLOW UP NOTE

    1. I disabled all of my plugins, and re-tested, but it still didn't work.

    2. I set my Permalinks to the default option, and the Preview in Gravity Forms worked fine.

    3. But when I set my Permalinks to "custom" and set them to /%category%/%postname%/ ... it looks like it's not using it.

    I guess what I don't understand is .. the "custom" Permalinks (of /%category%/%postname%/) works with everything else in my Wordpress site. But Gravity Forms isn't. So, it appears that Gravity Forms is not working in the same way that Wordpress is, with the way it creates and identifies it's Permalinks. Since my "custom" Permalinks of /%category%/%postname%/ works fine with my Wordpress pages, categories, posts, etc., I'd appreciate it if someone could help me figure out why Gravity Forms isn't using this in the same way? It should ... shouldn't it????

    Thanks,
    Gary

    PS: Again, I am on a Windows 2008 server, running IIS7.

    And, my web.config file has the following rewrite code in the file:

    <rewrite>
    <rules>
    <rule name="Main Rule" stopProcessing="true">
    <match url=".*" />
    <conditions logicalGrouping="MatchAll">
    <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
    <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
    </conditions>
    <action type="Rewrite" url="/index.php" />
    </rule>
    </rules>
    </rewrite>

    =====================================

    ONE MORE UPDATE (*smile*

    I tested changing my PERMALINKS.

    It was set to: /%category%/%postname%/

    (Using this was fine for all my pages, posts, etc., in my Wordpress installation.)

    But .. it was causing Gravity Forms to fail, for the PREVIEW.

    So, I changed it to /%postname%/

    And .. now it works.

    There appears to be something within Gravity Forms that doesn't like the /%category%/%postname%/ PERMALINKS.

    Is this something Gravity Forms can update, correct, or what ever you might want to call it.

    I'd like to be able to use /%category%/%postname%/ and not just /%postname%/ for the PERMALINKS custom setting, or anything other than just one permalink.

    If I am doing something wrong, in using /%category%/%postname%/ .. please let me know. I'll be happy to make a change that you deem appropriate. Thanks.

    Please let me know.

    Thanks,
    Gary

    ========================================

    ADDITIONAL NOTES:

    1. I logged into the server to change the permissions on the gravityforms folder, but everything was already set at full write permissions.

    2. I changed the theme to the default TwentyTen theme, and also deactivated *ALL* plugins, but the same error occurred when I tried to PREVIEW the Gravity Form. (So, since it doesn't appear related to the theme and/or the plugins, I reset it back to original theme.)

    3. I believe that Gravity Forms (when running on Windows and IIS7) clearly is having a problem with the permalink structure of /%category%/%postname%/ . Since every other page, post, plugin, etc., isn't having a problem with this permalink structure, yet Gravity Forms is, it seems as though even though the page http://www.greatersba.org/wp-content/plugins/gravityforms/preview.php?id=1 exists ... there appears to be *OTHER* pages that are being called from within preview.php (or other included pages) that are not being found.

    Such as:

    require_once (preg_replace("/wp-content.*/","wp-blog-header.php",__FILE__));
    require_once (preg_replace("/wp-content.*/","/wp-admin/includes/admin.php",__FILE__));

    or

    require_once(GFCommon::get_base_path() . "/form_display.php");

    NOTE: A 404 error can be generated if any of these "required files" , etc. ... that are also included within the php page cannot be found properly. I'm just guessing, but I think it has to do the way these files are being called in the script.

    4. So, again, I think there is something written in Gravity Forms that doesn't like this permalinks configuration.

    For example, here's just a few I tested:

    /%category%/%postname%/ - doesn't work.
    /%postname%/ - WORKS FINE
    /%year%/%postname%/ - doesn't work.
    /%postname%/%year%/ - WORKS FINE

    If it was my server, or Wordpress, I would expect it to either work or not work (all the time), regardless of what order I place the permalinks code in. But it works with some, and not others.

    So .. again, I think Gravity Forms is not doing something properly (on a Windows server configuration, running PHP and IIS7) with regard to permalinks.

    I am guessing that I may be the first person to have tried using /%category%/%postname%/ as the custom permalinks setting.

    Can someone look into this further .. or let me know what might suggest be the solution or if Gravity Forms needs to change something in the code (on the back end).

    Thanks,
    Gary

    NOTE: At the moment, I am using just /%postname%/ so it works. But I need to go back to using /%category%/%postname%/ for my permalinks.

    Posted 13 years ago on Saturday October 16, 2010 | Permalink