Index: /branches/release-34/lib/MT/CMS/Template.pm
===================================================================
--- /branches/release-34/lib/MT/CMS/Template.pm (revision 1875)
+++ /branches/release-34/lib/MT/CMS/Template.pm (revision 1877)
@@ -1,2 +1,8 @@
+# Movable Type (r) Open Source (C) 2001-2008 Six Apart, Ltd.
+# This program is distributed under the terms of the
+# GNU General Public License, version 2.
+#
+# $Id$
+
 package MT::CMS::Template;
 
@@ -76,8 +82,4 @@
           (      ( $obj->type eq 'index' )
               && ( ( $blog->custom_dynamic_templates || "" ) ne 'all' ) );
-        $param->{custom_dynamic} =
-          $blog && ( $blog->custom_dynamic_templates || "" ) eq 'custom';
-        $param->{has_build_options} =
-          ( $param->{custom_dynamic} || $param->{has_rebuild} );
 
         # FIXME: enumeration of types
@@ -243,5 +245,5 @@
         }
         # publish options
-        $param->{publish_queue} = $blog->publish_queue if $blog;
+        $param->{publish_queue_available} = eval 'require List::Util; require Scalar::Util; 1;';
         $param->{build_type} = $obj->build_type;
         $param->{ 'build_type_' . ( $obj->build_type || 0 ) } = 1;
@@ -563,4 +565,6 @@
     $params->{published} = $app->param('published');
     $params->{saved_copied} = $app->param('saved_copied');
+    $params->{saved_deleted} = $app->param('saved_deleted');
+    $params->{saved} = $app->param('saved');
 
     # determine list of system template types:
@@ -652,4 +656,7 @@
             $app->param( 'filter_key', 'email_templates' );
         }
+        elsif ( $tmpl_type eq 'module' ) {
+            $app->param( 'filter_key', 'module_templates' );
+        }
         $terms->{type} = $types{$tmpl_type}->{type};
         my $tmpl_param = $app->listing(
@@ -1062,5 +1069,5 @@
                 name    => $name,
                 value   => $_->{template},
-                default => ( $_->{default} || 0 )
+                default => ( $_->{default} || 0 ),
               };
         }
@@ -1183,11 +1190,4 @@
     my ( $app, $obj ) = @_;
 
-    $obj->rebuild_me(0) 
-      if $app->param('current_rebuild_me')
-      && !$app->param('rebuild_me');
-    $obj->build_dynamic(0)
-      if $app->param('current_build_dynamic')
-      && !$app->param('build_dynamic');
-
     ## Strip linefeed characters.
     ( my $text = $obj->text ) =~ tr/\r//d;
@@ -1429,5 +1429,8 @@
 
     my $param = {};
+    my $blog = $app->blog;
+    $param->{dynamicity} = $blog->custom_dynamic_templates || 'none';
     $param->{screen_id} = "publishing-profile-dialog";
+    $param->{return_args} = $app->param('return_args');
 
     $app->build_page('dialog/publishing_profile.tmpl',
Index: /branches/release-34/lib/MT/CMS/Blog.pm
===================================================================
--- /branches/release-34/lib/MT/CMS/Blog.pm (revision 1866)
+++ /branches/release-34/lib/MT/CMS/Blog.pm (revision 1877)
@@ -13,5 +13,4 @@
 
     if ($id) {
-        require MT::IPBanList;
         my $output = $param->{output} ||= 'cfg_prefs.tmpl';
         $param->{need_full_rebuild}  = 1 if $q->param('need_full_rebuild');
@@ -233,4 +232,6 @@
                 }
             }
+            require MT::Template;
+            $param->{dynamic_enabled} = MT::Template->exist( { blog_id => $obj->id, build_dynamic => 1 });
             eval "require List::Util; require Scalar::Util;";
             unless ($@) {
@@ -1201,5 +1202,4 @@
         }
         elsif ( $screen eq 'cfg_archives' ) {
-            @fields = qw( file_extension );
         }
         elsif ( $screen eq 'cfg_templatemaps' ) {
@@ -1385,11 +1385,13 @@
         }
         if ( $screen eq 'cfg_archives' ) {
-            if ( my $dcty = $app->param('dynamicity') ) {
-                $obj->custom_dynamic_templates($dcty);
-            }
             $obj->include_system( $app->param('include_system') || '' );
             if ( !$app->param('enable_archive_paths') ) {
                 $obj->archive_url('');
                 $obj->archive_path('');
+            }
+        }
+        if ( $screen eq 'cfg_publish_profile' ) {
+            if ( my $dcty = $app->param('dynamicity') ) {
+                $obj->custom_dynamic_templates($dcty);
             }
         }
@@ -1446,42 +1448,21 @@
 
     my $screen = $app->param('cfg_screen') || '';
-    if ( $screen eq 'cfg_archives' ) {
+    if ( $screen eq 'cfg_publish_profile' ) {
         if ( my $dcty = $app->param('dynamicity') ) {
-            my $dcty_changed = $dcty ne $original->custom_dynamic_templates ? 1 : 0;
-
-            if ($dcty_changed) {
-
-                # Apply publishing rules for templates based on
-                # publishing method selected:
-                #     none (0% publish queue, all static)
-                #     async_all (100% publish queue)
-                #     async_partial (high-priority templates publish synchronously (main index, preferred indiv. archives, feed templates))
-                #     all (100% dynamic)
-                #     archives (archives dynamic, static indexes)
-                #     custom (custom configuration)
-
-                if ( $dcty eq 'none' ) {
-                    require MT::Template;
-                    my @tmpls = MT::Template->load({
-                        blog_id       => $obj->id,
-                        build_dynamic => 1,
-                    });
-                    for my $tmpl (@tmpls) {
-                        $tmpl->build_dynamic(0);
-                        $tmpl->save;
-                    }
-                }
-                update_dynamicity(
-                    $app,
-                    $obj,
-                    $app->param('dynamic_cache')       ? 1 : 0,
-                    $app->param('dynamic_conditional') ? 1 : 0
-                );
-            }
-
-            if (!$dcty_changed || $dcty eq 'custom') {
-                # do nothing
-            }
-            elsif ($dcty eq 'none') {
+            # Apply publishing rules for templates based on
+            # publishing method selected:
+            #     none (0% publish queue, all static)
+            #     async_all (100% publish queue)
+            #     async_partial (high-priority templates publish synchronously (main index, preferred indiv. archives, feed templates))
+            #     all (100% dynamic)
+            #     archives (archives dynamic, static indexes)
+            #     custom (custom configuration)
+
+            update_publishing_profile(
+                $app,
+                $obj
+            );
+
+            if (($dcty eq 'none') || ($dcty =~ m/^async/)) {
                 _update_finfos($app, 0);
             }
@@ -1494,16 +1475,25 @@
                 _update_finfos($app, 0, { templatemap_id => \'is null' });
             }
-
-            # If either of the publishing paths changed, rebuild the fileinfos.
-            my $path_changed = 0;
-            for my $path_field (qw( site_path archive_path site_url archive_url )) {
-                $path_changed = 1 && last if $app->param($path_field)
-                    && $app->param($path_field) ne $original->$path_field();
-            }
-
-            if ($path_changed) {
-                $app->rebuild( BlogID => $obj->id, NoStatic => 1 )
-                    or return $app->publish_error();
-            }
+        }
+
+        cfg_publish_profile_save($app, $obj) or return;
+    }
+    if ( $screen eq 'cfg_archives' ) {
+        # update the dynamic publishing options if they changed
+        update_dynamicity(
+            $app,
+            $obj
+        );
+
+        # If either of the publishing paths changed, rebuild the fileinfos.
+        my $path_changed = 0;
+        for my $path_field (qw( site_path archive_path site_url archive_url )) {
+            $path_changed = 1 && last if $app->param($path_field)
+                && $app->param($path_field) ne $original->$path_field();
+        }
+
+        if ($path_changed) {
+            $app->rebuild( BlogID => $obj->id, NoStatic => 1 )
+                or return $app->publish_error();
         }
 
@@ -1847,18 +1837,29 @@
 
 sub _switch_publish_options {
-    my ( $blog, $current, $new ) = @_;
+    my ( $blog, $current, $new, $dcty ) = @_;
     require MT::Template;
     require MT::TemplateMap;
     my @tmpl = MT::Template->load( { blog_id => $blog->id } );
+    my $pref_at = $blog->archive_type_preferred || '';
     for my $tmpl (@tmpl) {
+        # FIXME: enumeration of types
         next
-          if !( $tmpl->type =~ m/^(individual|page|category|archive|index)$/ );
-        if ( $tmpl->build_type == $current ) {
-            $tmpl->build_type($new);
-            $tmpl->save;
-        }
+          if !( $tmpl->type =~ m/^(individual|page|category|archive)$/ );
+        # if ( $tmpl->build_type == $current ) {
+        #     $tmpl->build_type($new);
+        #     $tmpl->save;
+        # }
         my @tmpl_maps = MT::TemplateMap->load( { template_id => $tmpl->id } );
         foreach my $tmpl_map (@tmpl_maps) {
-            if ( $tmpl_map->build_type == $current ) {
+            if ($dcty eq 'async_partial') {
+                # build the preferred archive type synchronously
+                if (($tmpl_map->archive_type eq $pref_at) &&
+                    ($tmpl_map->is_preferred)) {
+                    $tmpl_map->build_type(MT::PublishOption::ONDEMAND());
+                    $tmpl_map->save;
+                    next;
+                }
+            }
+            if ( $tmpl_map->build_type != $new ) {
                 $tmpl_map->build_type($new);
                 $tmpl_map->save;
@@ -1875,7 +1876,19 @@
     my $at = $app->param('preferred_archive_type');
     $blog->archive_type_preferred($at);
-    my $pq = $app->param('publish_queue');
-    $blog->publish_queue( $pq ? 1 : 0 );
     $blog->include_cache( $app->param('include_cache') ? 1 : 0 );
+    $blog->save
+      or return $app->error(
+        $app->translate( "Saving blog failed: [_1]", $blog->errstr ) );
+
+    1;
+}
+
+sub cfg_publish_profile_save {
+    my $app = shift;
+    my ($blog) = @_;
+
+    my $dcty = $app->param('dynamicity') || 'none';
+    my $pq = $dcty =~ m/^async/ ? 1 : 0;
+    $blog->publish_queue( $pq );
     $blog->save
       or return $app->error(
@@ -1887,5 +1900,6 @@
             $blog,
             MT::PublishOption::ONDEMAND(),
-            MT::PublishOption::ASYNC()
+            MT::PublishOption::ASYNC(),
+            $dcty,
         );
     }
@@ -1894,7 +1908,10 @@
             $blog,
             MT::PublishOption::ASYNC(),
-            MT::PublishOption::ONDEMAND()
+            MT::PublishOption::ONDEMAND(),
+            $dcty,
         );
     }
+
+    1;
 }
 
@@ -1905,26 +1922,48 @@
     my @tms = MT::TemplateMap->load(
         {
-            archive_type => $archive_type,
-            blog_id      => $blog_id
+            archive_type  => $archive_type,
+            blog_id       => $blog_id
         }
     );
-    grep { $_->text =~ /<MT:?IfRegistration/i }
+    grep { !$_->build_dynamic && ($_->text =~ /<MT:?IfRegistration/i) }
       map { MT::Template->load( $_->template_id ) } @tms;
 }
 
-sub update_dynamicity {
+sub update_publishing_profile {
     my $app = shift;
-    my ( $blog, $cache, $conditional ) = @_;
+    my ( $blog ) = @_;
+
     my $dcty = $blog->custom_dynamic_templates;
 
-    if ( ($dcty eq 'async_partial') || ($dcty eq 'async_all') ) {
-        # these behave like static publishing
-        $dcty = 'none';
-    }
-
-    if ( $dcty eq 'none' ) {
-        require MT::Template;
-        my @templates = MT::Template->load( { blog_id => $blog->id } );
+    require MT::PublishOption;
+    require MT::Template;
+
+    if ( ($dcty eq 'none') || ($dcty =~ m/^async/) ) {
+        my @templates = MT::Template->load( {
+            blog_id => $blog->id,
+            # FIXME: enumeration of types
+            type =>
+              [ 'index', 'archive', 'individual', 'page', 'category' ],
+          } );
         for my $tmpl (@templates) {
+            my $bt = $tmpl->build_type || 0;
+            # Do not make automatic modifications to templates with these
+            # manually configured build types
+            next if $bt == MT::PublishOption::DISABLED();
+            next if $bt == MT::PublishOption::MANUALLY();
+            next if $bt == MT::PublishOption::SCHEDULED();
+
+            if ($dcty eq 'async_partial') {
+                # these should be build synchronously
+                if (($tmpl->identifier || '') =~ m/^(main_index|feed_recent)$/) {
+                    $tmpl->build_type(MT::PublishOption::ONDEMAND());
+                } else {
+                    $tmpl->build_type(MT::PublishOption::ASYNC());
+                }
+            } elsif ($dcty eq 'async_all') {
+                $tmpl->build_type(MT::PublishOption::ASYNC());
+            } else {
+                $tmpl->build_type(MT::PublishOption::ONDEMAND());
+            }
             $tmpl->build_dynamic(0);
             $tmpl->save();
@@ -1932,15 +1971,17 @@
     }
     elsif ( $dcty eq 'archives' ) {
-        require MT::Template;
-        my @templates = MT::Template->load( { blog_id => $blog->id } );
+        my @templates = MT::Template->load( {
+            blog_id => $blog->id,
+            # FIXME: enumeration of types
+            type =>
+              [ 'index', 'archive', 'individual', 'page', 'category' ],
+          } );
         for my $tmpl (@templates) {
+            $tmpl->build_type( $tmpl->type ne 'index' ? MT::PublishOption::DYNAMIC() : MT::PublishOption::ONDEMAND() );
             $tmpl->build_dynamic( $tmpl->type ne 'index' ? 1 : 0 );
             $tmpl->save();
         }
     }
-    elsif ( $dcty eq 'custom' ) {
-    }
     elsif ( $dcty eq 'all' ) {
-        require MT::Template;
         my @templates = MT::Template->load(
             {
@@ -1953,13 +1994,28 @@
         );
         for my $tmpl (@templates) {
+            $tmpl->build_type( MT::PublishOption::DYNAMIC() );
             $tmpl->build_dynamic(1);
             $tmpl->save();
         }
     }
-
-    if ( $dcty ne 'none' ) {
-        prepare_dynamic_publishing($app, @_, $blog->site_path, $blog->site_url);
+    return 1;
+}
+
+sub update_dynamicity {
+    my $app = shift;
+    my ( $blog ) = @_;
+
+    my $cache       = $app->param('dynamic_cache')       ? 1 : 0;
+    my $conditional = $app->param('dynamic_conditional') ? 1 : 0;
+
+    require MT::Template;
+    my $dynamic_enabled = MT::Template->exist( { blog_id => $blog->id,
+        build_dynamic => 1 });
+
+    # dynamic publishing enabled
+    if ( $dynamic_enabled ) {
+        prepare_dynamic_publishing($app, $blog, $cache, $conditional, $blog->site_path, $blog->site_url);
         if ( $blog->archive_path ) {
-            prepare_dynamic_publishing($app, @_, $blog->archive_path, $blog->archive_url);
+            prepare_dynamic_publishing($app, $blog, $cache, $conditional, $blog->archive_path, $blog->archive_url);
         }
         my $compiled_template_path =
@@ -1987,5 +2043,4 @@
         }
     }
-    $app->add_return_arg( dynamic_set => 1 );
 }
 
@@ -2004,6 +2059,4 @@
       && ( -f $mtview_path );
     return 1 if ( 'none' eq $blog->custom_dynamic_templates );
-
-    require File::Spec;
 
     # IIS itself does not handle .htaccess,
Index: /branches/release-34/lib/MT/Template.pm
===================================================================
--- /branches/release-34/lib/MT/Template.pm (revision 1823)
+++ /branches/release-34/lib/MT/Template.pm (revision 1877)
@@ -568,5 +568,5 @@
     return undef unless $tmpl->outfile;
     return undef unless ($tmpl->type eq 'index');
-    
+
     my $blog = $tmpl->blog;
     return undef unless $blog;
Index: /branches/release-34/tmpl/cms/edit_template.tmpl
===================================================================
--- /branches/release-34/tmpl/cms/edit_template.tmpl (revision 1847)
+++ /branches/release-34/tmpl/cms/edit_template.tmpl (revision 1877)
@@ -160,7 +160,6 @@
     <mt:unless name="new_object">
         <mt:unless name="build_dynamic">
-        <mt:unless name="build_type_0">
-            <mt:if name="has_rebuild">
-                <mt:if name="can_rebuild">
+            <mt:if name="can_rebuild">
+                <mt:unless name="archive_types">
     <button
         type="submit"
@@ -170,7 +169,6 @@
         onclick="return validate(this.form, 1);"
         ><__trans phrase="Save &amp; Publish"></button>
-                </mt:if>
+                </mt:unless>
             </mt:if>
-        </mt:unless>
         </mt:unless>
     </mt:unless>
@@ -626,19 +624,14 @@
     </mtapp:setting>
 <mt:else>
-    <mt:if name="has_build_options">
-        <mtapp:setting
-            id="build_dynamic"
-            label="<__trans phrase="Publish Options">"
-            help_page="templates"
-            help_section="enable_dynamic_publishing">
-            <mt:if name="custom_dynamic"><mt:if name="build_dynamic"><input type="hidden" name="current_build_dynamic" value="1" /></mt:if></mt:if>
-            <mt:unless name="build_dynamic"><mt:if name="has_rebuild"><mt:if name="rebuild_me"><input type="hidden" name="current_rebuild_me" value="1" /></mt:if></mt:if></mt:unless>
+    <mtapp:setting
+        id="build_dynamic"
+        label="<__trans phrase="Publish Options">"
+        help_page="templates"
+        help_section="enable_dynamic_publishing">
         <select name="build_type" id="build-type" class="full-width">
             <option value="1"<mt:if name="build_type_1"> selected="selected"</mt:if>><__trans phrase="Statically"></option>
-            <mt:if name="custom_dynamic">
             <option value="3"<mt:if name="build_type_3"> selected="selected"</mt:if>><__trans phrase="Dynamically"></option>
-            </mt:if>
-            <mt:if name="publish_queue">
-            <option value="4"<mt:if name="build_type_4"> selected="selected"</mt:if>><__trans phrase="Asynchronously"></option>
+            <mt:if name="publish_queue_available">
+            <option value="4"<mt:if name="build_type_4"> selected="selected"</mt:if>><__trans phrase="Background"></option>
     <mt:ignore>
         <!-- untested features -->
@@ -655,9 +648,7 @@
     </mt:ignore>
             </mt:if>
-            <option value="2"<mt:if name="build_type_2"> selected="selected"</mt:if>><__trans phrase="Manually"></option>
-            <option value="0"<mt:if name="build_type_0"> selected="selected"</mt:if>><__trans phrase="Disabled"></option>
+            <option value="2"<mt:if name="build_type_2"> selected="selected"</mt:if><mt:if name="build_type_0"> selected="selected"</mt:if>><__trans phrase="Manually"></option>
         </select>
-        </mtapp:setting>
-    </mt:if>
+    </mtapp:setting>
 </mt:if>
 <mt:if name="template_group" like="(module|widget)">
@@ -730,5 +721,4 @@
     },
 
-
     autoSave: function() {
         arguments.callee.applySuper( this, arguments );
Index: /branches/release-34/tmpl/cms/include/template_table.tmpl
===================================================================
--- /branches/release-34/tmpl/cms/include/template_table.tmpl (revision 1786)
+++ /branches/release-34/tmpl/cms/include/template_table.tmpl (revision 1877)
@@ -80,5 +80,5 @@
             <mt:loop name="archive_types">
                 <mt:loop name="archive_tmpl_loop">
-                        <li><mt:if name="selected"><mt:var name="name" escape="html"></mt:if></li>
+                        <li><mt:if name="selected"><mt:var name="name" escape="html"><mt:var name="build_type" value="$map_build_type"></mt:if></li>
                 </mt:loop>
             </mt:loop>
@@ -94,11 +94,12 @@
     <mt:if name="template_type" like="/(index|archive)/">
                 <td class="publishing-method">
-                    <mt:if name="build_type" eq="0"><__trans phrase="Disabled">
-                    <mt:else name="build_type" eq="2"><__trans phrase="Manual">
-                    <mt:else name="build_type" eq="3"><__trans phrase="Dynamic">
-                    <mt:else name="build_type" eq="4"><__trans phrase="Asynchronous">
-                    <mt:else name="build_type" eq="5"><__trans phrase="Scheduled">
+                    <mt:if name="build_dynamic"><__trans phrase="Dynamic"><mt:else>
+                    <mt:if name="build_type" eq="0"><__trans phrase="Manual">
+                    <mt:elseif name="build_type" eq="2"><__trans phrase="Manual">
+                    <mt:elseif name="build_type" eq="3"><__trans phrase="Dynamic">
+                    <mt:elseif name="build_type" eq="4"><__trans phrase="Background">
+                    <mt:elseif name="build_type" eq="5"><__trans phrase="Scheduled">
                     <mt:else><__trans phrase="Static">
-                    </mt:if>
+                    </mt:if></mt:if>
                 </td>
     </mt:if>
Index: /branches/release-34/tmpl/cms/include/archive_maps.tmpl
===================================================================
--- /branches/release-34/tmpl/cms/include/archive_maps.tmpl (revision 1632)
+++ /branches/release-34/tmpl/cms/include/archive_maps.tmpl (revision 1877)
@@ -28,15 +28,12 @@
             </td>
             <td class="publish-options">
-                <select name="build_type" id="build-type" class="half-width">
-                    <option value="1"<mt:if name="build_type_1"> selected="selected"</mt:if>><__trans phrase="Statically"></option>
-
-                <mt:if name="custom_dynamic">
-                    <option value="3"<mt:if name="build_type_3"> selected="selected"</mt:if>><__trans phrase="Dynamically"></option>
-                </mt:if>
-                <mt:if name="publish_queue">
-                    <option value="4"<mt:if name="build_type_4"> selected="selected"</mt:if>><__trans phrase="Asynchronously"></option>
+                <select name="map_build_type_<mt:var name="map_id">" id="build-type" class="half-width">
+                    <option value="1"<mt:if name="map_build_type_1"> selected="selected"</mt:if>><__trans phrase="Statically"></option>
+                    <option value="3"<mt:if name="map_build_type_3"> selected="selected"</mt:if>><__trans phrase="Dynamically"></option>
+    <mt:if name="publish_queue_available">
+                    <option value="4"<mt:if name="map_build_type_4"> selected="selected"</mt:if>><__trans phrase="Background"></option>
         <mt:ignore>
             <!-- untested features -->
-                    <option value="5"<mt:if name="build_type_5"> selected="selected"</mt:if>><__trans phrase="On a schedule"></option>
+                    <option value="5"<mt:if name="map_build_type_5"> selected="selected"</mt:if>><__trans phrase="On a schedule"></option>
                     <mt:ignore>
                         <!-- This code needs to be shown if the "On a schedule" has been selected -->
@@ -49,7 +46,6 @@
                     </mt:ignore>
         </mt:ignore>
-                </mt:if>
-                    <option value="2"<mt:if name="build_type_2"> selected="selected"</mt:if>><__trans phrase="Manually"></option>
-                    <option value="0"<mt:if name="build_type_0"> selected="selected"</mt:if>><__trans phrase="Disabled"></option>
+    </mt:if>
+                    <option value="2"<mt:if name="map_build_type_2"> selected="selected"</mt:if><mt:if name="map_build_type_0"> selected="selected"</mt:if>><__trans phrase="Manually"></option>
                 </select>
             </td>
Index: /branches/release-34/tmpl/cms/dialog/publishing_profile.tmpl
===================================================================
--- /branches/release-34/tmpl/cms/dialog/publishing_profile.tmpl (revision 1852)
+++ /branches/release-34/tmpl/cms/dialog/publishing_profile.tmpl (revision 1877)
@@ -34,9 +34,16 @@
 <mt:include name="dialog/header.tmpl">
 <form name="publishing_profiles_form" id="publishing_profiles_form" method="post" action="<mt:var name="script_url">" target="_top" onsubmit="return false">
+    <input type="hidden" name="blog_id" value="<mt:var name="blog_id">" />
+    <input type="hidden" name="__mode" value="save" />
+    <input type="hidden" name="_type" value="blog" />
+    <input type="hidden" name="id" value="<mt:var name="blog_id">" />
+    <input type="hidden" name="cfg_screen" value="cfg_publish_profile" />
+    <input type="hidden" name="return_args" value="<mt:var name="return_args" escape="html">" />
+    <input type="hidden" name="magic_token" value="<mt:var name="magic_token">" />
 
     <div id="profile-panel" class="hidden panel">
-        
+
         <p><__trans phrase="Choose the profile that best matches the requirements for this blog."></p>
-        
+
         <mtapp:setting
             id="dynamicity"
@@ -87,5 +94,5 @@
     </div>
     <div id="confirm-panel" class="hidden panel">
-        <p><__trans phrase="This new publishing profile will update all of you templates."></p>
+        <p><__trans phrase="This new publishing profile will update all of your templates."></p>
 
         <p><strong><__trans phrase="Are you sure you wish to continue?"></strong></p>
Index: /branches/release-34/tmpl/cms/list_template.tmpl
===================================================================
--- /branches/release-34/tmpl/cms/list_template.tmpl (revision 1875)
+++ /branches/release-34/tmpl/cms/list_template.tmpl (revision 1877)
@@ -71,7 +71,7 @@
         </mtapp:statusmsg>
     </mt:if>
-    <mt:if name="dynamic_set">
+    <mt:if name="saved">
         <mtapp:statusmsg
-            id="dynamic-set"
+            id="saved-settings"
             class="success">
             <__trans phrase="Your settings have been saved.">
Index: /branches/release-34/tmpl/cms/cfg_archives.tmpl
===================================================================
--- /branches/release-34/tmpl/cms/cfg_archives.tmpl (revision 1850)
+++ /branches/release-34/tmpl/cms/cfg_archives.tmpl (revision 1877)
@@ -292,4 +292,5 @@
 
 <mt:unless name="hide_build_option">
+<mt:if name="dynamic_enabled">
 <fieldset>
     <h3><__trans phrase="Dynamic Publishing Options"></h3>
@@ -312,4 +313,5 @@
 
 </fieldset>
+</mt:if>
 </mt:unless>
 
