ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Safecracker won't update or post new entries

February 22, 2012 3:55pm

Subscribe [1]
  • #1 / Feb 22, 2012 3:55pm

    JCDerrick

    57 posts

    I have installed a fresh copy of EE 2.4 and everything is smooth sailing until I go to use Safecracker.

    I cannot seem to edit an existing entry OR post anything new. Below is my edit template, which is the exact same as another site I’ve worked with (EE 2.3.1) that worked fine.

    This one has me stumped… I’ve tried removing all the custom fields except the title and that still failed to update or post anything new. I’m logged in as a Super Admin for these tests, and all my add-on’s are also up to date (plus none of them are new from the other installation where this same Safecracker form works).

    If it’s any help, my date field doesn’t work properly either, despite having the CSS in place. So maybe these two are related? All of my styling is currently inline sense we’re still testing this. It’s basically a file management system, so we’ve got to get Safecracker working on this new server.

    {exp:safecracker channel="file_management_ftp" return="file_manager/mine" entry_id="{segment_3}" author_only="yes" error_handling="inline"}
    
    
    <label for="title">File Title</label>
    
    <input type="text" name="title" id="title" value="{title}" size="50" maxlength="100">
    <input type="hidden" name="url_title" id="url_title" value="{url_title}" maxlength="75" size="50">
    <input type="hidden" name="file_mine" id="file_mine" value="yes" /></p>
    
    <label for="expiration_date">Expiration Date (if applicable)</label>
    
    <input type="text" name="expiration_date" id="expiration_date" value="{expiration_date}" maxlength="23" size="25">/p>
    
    <strong>Upload a file (over 100MB):</strong>
    <div>
    {field:file_large}
    </div>
    
    <input type="submit" value="Submit" name="submit" />
    
    {/exp:safecracker}

    Thanks,
    John

  • #2 / Feb 23, 2012 4:36pm

    Dan Decker

    7338 posts

    Hi John,

    I’m sorry you are having trouble with SafeCracker and EE 2.4. I’ll do what I can to help you sort this out!

    I copied your code, and only changed the parameters needed to use my channels and templates. It posted without any trouble, other than the file was to large to upload. That’s an issue with my local PHP install, however.

    The only problem I saw in my template was an unclosed < p> tag.

    <input type="text" name="expiration_date" id="expiration_date" value="{expiration_date}" maxlength="23" size="25">/p>

    Should be:

    <input type="text" name="expiration_date" id="expiration_date" value="{expiration_date}" maxlength="23" size="25"></p>

    Are you using any other extensions or modules that deal with posting entries?

    Cheers,

     

  • #3 / Feb 24, 2012 11:17am

    JCDerrick

    57 posts

    Hi Dan, thanks for responding.

    I am using the same add-ons on this copy of the installation I was on the other version. The only thing I changed was I upgraded to EE 2.4 and this host is now at High Speed Web, versus Engine Hosting. We still have the EH site too, but the File Management site needed to be on another host, just FYI. Basically it’s the same site, just dedicated to the File Management part of the job.

    I thought maybe I wasn’t authenticated before I tried to update something, but that’s not it, I’m definitely logged in when I go and make changes.

    I updated all my modules and add-ons when I updated to 2.4, so maybe one of them is causing the problem. Let me try and disable them one at a time and see if that corrects the issue.

    The add ons that directly are in use at pretty common. WYGWAM, Matrix, Assets (all P&T material) and then Mega Upload from DevDemon. I’m also utilizing the User Module from Solspace.

    Thanks,
    John

  • #4 / Feb 24, 2012 11:36am

    JCDerrick

    57 posts

    I think HSW doesn’t support the path_info server variable. I found a helpful article that instructed me to change my htaccess (removing index.php of course) to the following below.

    I tried that and I think I have it working now.

    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ /index.php?/$1 [L]

    Just in case anyone else runs into that issue with a host of the same nature.

  • #5 / Feb 24, 2012 8:10pm

    Sean C. Smith

    3818 posts

    John,

    Thanks for posting up your solution. Sure that will be helpful to others. Is there anything else I can assist you with?

    Sean

  • #6 / Feb 25, 2012 8:46am

    JCDerrick

    57 posts

    Hi Sean, I’m good - thanks. Please feel free to close this one up. Thanks for getting me on the right track to finding a solution.

  • #7 / Feb 26, 2012 1:53pm

    Sean C. Smith

    3818 posts

    Great, closing at your request.

    Sean

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases