Page 1 of 1
[SOLVED] Issue -Extra Closing img and br Tags After Upgrade
Posted: Mon Feb 02, 2015 4:15 pm
by govicinity
CMS Made Simple™ 1.11.12
AceEditor 1.0
CGExtensions 1.45
CGFeedMaker 1.0.20
CGSimpleSmarty 1.7.4
CGSmartImage 1.17.2
CMSMailer 5.2.2
CMSPrinting 1.0.5
Captcha 0.5.2
CustomContent 1.10
FileManager 1.4.5
FormBuilder 0.8.1.1
FrontEndUsers 1.26
ListIt2 1.4.1
MenuManager 1.8.6
MicroTiny 1.2.7
ModuleManager 1.5.8
News 2.14.4
Search 1.7.11
SiteMapMadeSimple 1.2.8
ThemeManager 1.1.8
Since I have updated a couple of sites to CMS Made Simple™ 1.11.12, I have noticed an issue with additional closing tags for img and br appearing within the code on the frontend of the site when I view source, just wondered if anyone else has noticed this, and if so, have they fixed it simply? Or wondering if it's something I've done this end and it's only me with this issue, whether it's a plugin update, or the core system update. We have only added a JQuery lazy image loader since the update, otherwise the sites are exactly the same as before. Permissions are all set correctly for files and folders. Admin has been re-located to avoid easy hacking (but it was previously like this).
Extra closing tags highlighted in red. Any suggestions very welcome.
Also noticed my Google Analytics (handled with a GCB and simple smarty) has stopped displaying entirely in the frontend code.
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Tue Feb 03, 2015 9:22 am
by velden
It seems very unlikely (if not impossible) to me that the content itself is changed due to an upgrade.
Is the content where you notice those extra tags, touched before the problem arised? So if it's about a content page, is the page edited, or at least opened in admin and submit/applied?
Are you sure it's in the page source? Or are you using a web inspector?
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Tue Feb 03, 2015 10:31 am
by govicinity
Hi Velden, yes it seemed very odd to me too. The altered code is not in the admin area when we view source.
But when viewed in Firefox, Chrome, Safari, Opera and we choose view source to view the page HTML it is there.
Nothing has been changed in the admin area of the pages that this has happened on - and we have not submitted any of the affected pages through the admin, It has happened to two sites that we have updated to 1.11.12 - we have also updates a lot of the modules, so I am at a bit of a loss here, they were fine before update, our sites use a basic structure with bolt on areas in the form of image scrollers, 4 column, 3 column 2 column and 1 column areas that make it easily expandable. All the code is hand coded so is very clean. All the sites use essentially the same elements re-skinned, all the sites on 1.11.11 seem to be perfect in the same areas we have the problems in 1.11.12 so I am really at a loss here.
What it looks like is that something is trying to force close some elements with a closing tag that are already closed, i.e.
Code: Select all
<img src=images/mylovelyimage.jpg></img>
or
I have just removed some of the CG image smarty and it seems to have fixed the issue on one of the elements:
Original
Code: Select all
{cgsi_convert filter_resizetofit="118,118,#ffffff" quality="100"}
{content block='Client_Logos_Area' label='Client Logos Area - will only appear if content is inserted here' assign='Client_Logos_Area'}
{if !empty($Client_Logos_Area)}
<div class="client-logos">
{$Client_Logos_Area}
</div>
{/if}
{/cgsi_convert}
Deleted cgsi_ smarty which removed extra <_/img>
Code: Select all
{content block='Client_Logos_Area' label='Client Logos Area - will only appear if content is inserted here' assign='Client_Logos_Area'}
{if !empty($Client_Logos_Area)}
<div class="client-logos">
{$Client_Logos_Area}
</div>
{/if}
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Tue Feb 03, 2015 10:39 am
by govicinity
Yep, just stripped all the
Code: Select all
{cgsi_convert filter_resizetofit="236,236" quality="100"}
{/cgsi_convert}
Smarty off where I have used the convert on the page and it strips off the extra closing <_/img> tags, so possibly an issue with CGSmartImage 1.17.2 (which is an awesome plugin we use all the time BTW)? Do I need to raise this as an issue?
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Tue Feb 03, 2015 10:47 am
by govicinity
I have just tried stripping the cgsi_convert smarty from the page that has type content and image content within it and this has also fixed the issue with the closing <_/br>
i.e.
to
So there is an issue here.
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Tue Feb 03, 2015 12:37 pm
by govicinity
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Tue Feb 03, 2015 12:39 pm
by velden
I can confirm this behavior.
However, question is: is it invalid behavior?
http://validator.w3.org/ says it validates.
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Tue Feb 03, 2015 12:50 pm
by govicinity
Hi Velden,
Thanks for confirming.
It may be valid, but it is adding in extra soft returns
after a
that is meant to be there, so it is causing formatting issues on some of the sites we have implemented the latest version of CGSmartImage on by knocking content further down the page than it should be, or putting in what looks like a paragraph break where there should not be one. Not complaining obviously as I know Robert works extremely hard on all his plugins and I and everyone else do appreciate it very much. So we'll await an update with a fix.
Re: Issues - Additional Closing img and br Tags Since Upgrad
Posted: Mon Feb 23, 2015 3:27 pm
by govicinity
OK, I have rolled back to CGExtensions 1.44.5 and this has now removed the problem, so the issue is not with CGSmartImage, it is with this version of CG Extensions: CGExtensions 1.45 (latest version)
Re: [SOLVED] Issue -Extra Closing img and br Tags After Upgr
Posted: Mon Feb 23, 2015 5:17 pm
by govicinity
PS, don't forget to downgrade your CGSmartImage to 1.17 as the latest version of smart image won't work with CG Extensions 1.45