Jay Brewer

Linked Individual Archive Template Being Reset to Default

Vote 0 Votes

We have filed a bug over here: http://bugs.movabletype.org/default.asp?105377

We upgraded to 4.3 to 4.35 and now this seems to happen randomly. It took about 2 weeks for it to happen again so we're not sure why it's happening. The older case was a template tag that caused an error on PREVIEW that used the Individual Entry Archive (our custom one) after the error that template would now be filled with this:

Now we saw this happen again with no ERROR sometime in the last 24 hours. I do know that the save feature on linked templates was updated at some 4.3x release so that on initial save it would make sure and get the edits. Other than that - I'm not sure what tag or error would cause this.

Since it's random and effects our individual archives - yuck. Any thoughts or ideas would be amazing.

Does anyone know where or how it would just overwrite the linked template with:

Maybe a work around would be to put our individual archive template wherever that is coming from? In all the years we've been using MT (7 years +) this is the only problem we've had and without a repro now it's really concerning.

Reported on Movable Type 4.3

1 Reply

| Add a Reply
  • It looks like this default template code is coming from /tmpl/cms/preview_entry_content.tmpl.

    Looking at the code for previewing an entry, I think this bug must occur because of the following code, which is called when the attempt to preview results in an error:

    my $tmpl_plain = $app->load_tmpl('preview_entry_content.tmpl');
    $tmpl->text( $tmpl_plain->text );

    $tmpl here is the actual individual entry archive template. While it's not explicitly saved, if the template is linked to a file on disk, calling ->text causes a flag to be set that makes MT think it needs to be resynced to disk. So I'd guess that some combination of circumstances could cause it to actually perform that sync at the end of the request cycle, resulting in the preview_entry_content template getting written to the disk file and thence to the template in the database.

Add a Reply

If you need to share template code, replace all the "<" signs with "&lt;" or use this utility.

Forum Groups

code.sixapart.com

137 479

Last Topic: Getting a thumbnail with xpath by Peter on Mar 13, 2011

238 797

Last Topic: Manifest Schema Compatibility Issue When Restoring Blog by Matt on Oct 17, 2012

1858 6594

Last Topic: Categories and Basename Publishing Issues by e21media on Oct 25, 2012

88 307

Last Topic: absolute publish date in Manage Entries screen by .mau. on Apr 18, 2012

1488 5347

Last Topic: Anti-cloning by .mau. on Oct 29, 2012

732 3093

Last Topic: Blog moved server - now users cannot access blog? by mowgs on Oct 30, 2012

89 317

Last Topic: How to "pretify" a url in htaccess with a few wildcards by Caio on May 30, 2012

183 771

Last Topic: Commenting with TypePad by Rob Ferrara on Oct 17, 2012

212 680

Last Topic: Does MT-Approval work in MT5? by DLpres on Sep 25, 2012

27 100

Last Topic: Upgrading MT by Caio on Oct 15, 2012

49 224

Last Topic: Movable Type 6 Ideas by Caio on May 28, 2012

65 248

Last Topic: Expanding new rich text editor and implementing table function by Takeshi Nick Osanai on Jul 30, 2012