Page 1 of 1

[SOLVED] Empty error message when saving template

Posted: Mon Feb 03, 2014 8:08 pm
by Guido
You can read on below about the problem, but the way I solved it was removing the jQuerytools plugin call and replacing it by a 'normal' jQuery call. Don't know if this is a bug in Jquerytools, but I did a fresh install of 1.11.10 and all the modules, copied the template and still the same problem (untill I removed the jQuerytools call as said).
Hi,

I'm developing a site using CMSMS 1.11.9 (on XAMPP on a windows 8 machine). Since a few days ago, I get an empty error message (at the top of the screen) when applying changes. The changes do save though. I get the same thing when applying changes to pages that use this template. The TinyMCE behaviour is also a bit weird, in that changing classes will add the selected, but not remove the previously selected.

When editing a page that uses the dreaded template, I also get two smarty warnings at the top of the screen:

Code: Select all

Warning: array_merge(): Argument #2 is not an array in C:\xampp\htdocs\pandje\lib\smarty\sysplugins\smarty_internal_templatecompilerbase.php on line 388

Warning: array_merge(): Argument #2 is not an array in C:\xampp\htdocs\pandje\lib\smarty\sysplugins\smarty_internal_templatecompilerbase.php on line 388
So far I've checked if all modules were activated (they are). Another method I used was removing blocks of content in my template one by one, and hitting apply then. Still the same result.

I also copied the entire template into a 'test' one. Same problem. Anyone got an idea? Here is the template (code is still a bit messy, I clean up after every milestone during development):

Code: Select all

{process_pagedata}<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<__html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
<head>
<title>{sitename} - {title}</title>
{metadata}
<style>
    #header {
        height:120px
    }
    #links {
        width:300px;height:110px;float:left;padding-top:10px
    }
    #kalender {
        width:550px;height:100%;float:right;
    }
    #kalenderinhoud {
        width:430px;height:100%;float:left
    }
    #kalenderafbeelding {
        width:120px;height:100%;float:left
    }
    .aankomende_evenementen_lijst {
        margin-top:-15px;list-style-type:none;height:100%;
    }
    .aankomend_evenement {
        margin-top:5px;height:80px;
    }
    #kalender_grijs {
        width:75px;height:69px;background:url("uploads/images/standaard/Kalender_grijs.jpg") no-repeat;float:left;
    }
    .maand {
        font-family:arial;font-size:9px;color:white;font-weight:800;padding:12px 0 0 2px;margin:0;text-transform:uppercase;
    }
    .datum {
        font-family:arial;font-size:32px;color:rgb(102,102,102);font-weight:800;margin-top:-15px;text-align:center;
    }
    .evenement_titel {
        float:left;margin:0;width:300px;padding:0 0 5px 8px;
    }
    .kalender_samenvatting {
        float:left;padding:0 0 0 8px;
    }
    .meer_link {
        float:right;width:40px;height:40px;margin-top:-8px;background:url("uploads/images/standaard/pijl_rechts.jpg") left top;-webkit-transition:background-position .08s ease-in;-moz-transition:background-position .08s ease-in;-o-transition:background-position .08s ease-in;transition:background-position .08s ease-in;
    }
    .meer_link:hover {
        background-position:right top;
    }
    #foto {
        height:160px;position:absolute;left:0;width:100%;
    }
    #logo {
        background: url('uploads/images/standaard/wit_transparant.png');height:160px;position:relative;
    }
    #logoafbeelding {
        background: url('uploads/images/standaard/pandje_logo.png');width:160px;height:100%;float:left;
    }
    #logotekst {
        background: url('uploads/images/standaard/Pandje_woord_460x60.png') no-repeat right top;
    }
    #logorechterhouder {
        width:740px;height:100%;float:left;
    }
    #logotekst {
        width:690px;height:90px;float:right;margin:10px 10px 0 0;
    }
    #logopaginatitel {
        width:690px;height:60px;float:right;text-align:right;padding-right:10px;
    }
    .titel {
        color:#000;text-transform:uppercase;font-weight:100;
    }
    #grijs_blok {
        width:10px;height:30px;background:rgb(120,120,120);float:left;
    }
    #snelmenu {
        list-style-type:none;clear:left;padding:0;
    }
    #snelmenu li {
        height:46px;width:95%;display:block;background:url('uploads/images/standaard/snelmenu_knop.jpg') repeat-x;text-align:right;font-size:25px;color:white;padding:14px 5% 0 0;
    }
    .icoon {
        width: 40px;height:40px;float:left;margin:-5px 0 0 10px;
    }
</style>
{cms_stylesheet}

</head>
</__body style="width:900px;margin:0 auto">

<div id="header">
		 <div id="links">
		 			<a href="#">CONTACT</a>
					<hr>
					<a href="#">OVER ONS</a>
					<hr>
					<img src="uploads/images/standaard/facebook-logo.jpg" title="Bekijk onze Facebook pagina" alt="Facebook logo" style="float:left;margin-right:10px"><a href="#">ONZE FACEBOOK PAGINA</a>				
		 </div>
		 <div id="kalender">
		 			<div id="kalenderinhoud">
		 			    {JQueryTools action=require lib=jquery nocache}
		 			    {cms_module module="CGCalendar" display="upcominglist" limit="5" upcominglisttemplate="Aankomende_Evenementen"}
		 			</div>
					<div id="kalenderafbeelding">
					    <img src="uploads/images/standaard/Kalender.jpg" title="Kalender icoon" alt="Aankomende evenementen">
					</div>
		 </div>
</div>

<div id="titel">
		 <div id="foto"></div>
		 <div id="logo">
		 			<div id="logoafbeelding"></div>
					<div id="logorechterhouder">
							 <div id="logotekst"></div>
							 <div id="logopaginatitel">
							     <h1 class="titel">{title}</h1>
							 </div>
					</div>
		 </div>
</div>

<div id="content" style="clear:both">
		 <div id="hoofdcontent">{content}</div>
		 <div id="sidebar">
		    <div id="sidebar_titel" style="width:100%;float:left;margin-bottom:20px">
		        <div id="grijs_blok"></div>
		        <h2 style="float:left;display:block;margin:0;padding:0 0 0 15px;color:rgb(120,120,120);font-weight:100;letter-spacing:2px">SNEL NAAR:</h2>
		    </div>
		    <ul id="snelmenu">
		         <li><div class="icoon" style="background:url('uploads/images/standaard/snelmenu_iconen.png') 0 0"></div>START</li>
		         <li><div class="icoon" style="background:url('uploads/images/standaard/snelmenu_iconen.png') 0 -40px"></div>LUNCH & DINER</li>
		    </ul>
		 </div>
</div>

<div style="clear: both"></div>

<div id="footer">
    {menu template="footer"}
</div>

{JQueryTools action=placemarker nocache}
{literal}
<__script__>
$(function () {
    var list_slideshow = $(".aankomende_evenementen_lijst"),
        listItems = list_slideshow.children('li'),
        listLen = listItems.length,
        i = 0,
        changeList = function () {
            listItems.eq(i).fadeOut(300, function () {
                i += 1;
                if (i === listLen) {
                    i = 0;
                }
                listItems.eq(i).fadeIn(300);
            });
        };
    listItems.not(':first').hide();
    setInterval(changeList, 5000);
});
</__script>
{/literal}
<__body>
</__html>
O yeah, I also use the ACE syntax editor.

Re: Empty error message when saving template

Posted: Mon Feb 03, 2014 8:23 pm
by Dr.CSS
Is this an upgrade or ?, are you sure all the folders/files are where they should be..?

Re: Empty error message when saving template

Posted: Mon Feb 03, 2014 9:12 pm
by Rolf
When you create a new template and save it. Do you get the same error?

Re: Empty error message when saving template

Posted: Tue Feb 04, 2014 10:09 am
by Guido
Thanks for your replies:
  1. This is a fresh install.
  2. I checked against the cheksum and some files are missing from the news module, will fix this but the template (nor the pages that use the template) use the news module.
  3. Other templates are safe, but a copy of the corrupted template results in the same error, so something must be wrong in the template. Weird thing is, I cut out template block-by-block and tried applying after every cut. Still the weird empty error occurs.

Re: Empty error message when saving template

Posted: Tue Feb 04, 2014 4:27 pm
by Dr.CSS
Have you tried copying a default template, hard copy where you hilight it copy it then paste it into a new one, may I ask why you have so much hard coded into this template, styles etc..?

Re: Empty error message when saving template

Posted: Tue Feb 04, 2014 6:13 pm
by Guido
I tried, the default template doesn't have any problems, nor do any other of my own templates. It's just this one, so I know there is a specific problem with this template, just can't figure out what it is. The error message is empty, also when I 'check source' on it. Also, the 'apply' action does work, the changes are actually saved.

I'm experimenting with what google calls 'above the fold content'. Google's suggestion is to implement the rough CSS for the content that appears first on sight into the head directly, in stead of calling it in a separate CSS file. I don't really like the mess it makes of your template either (but with ACE editor it's easy to collapse it), but when the site is finished I'd like to see how google ranks this point on it's pagespeed site, since recently they said they will take this into account in their results.

Re: Empty error message when saving template

Posted: Tue Feb 04, 2014 6:37 pm
by Guido
I noticed another thing while fixing the checksum errors. After replacing all the missing or incorrect files the checksum was OK, but after cleaning the website buffer some files were not the right size according to the checksum file.

I think this is normal, since these are all temp files. But just checking...