| Pages: [1] |
|
|
Author |
Topic: mce_href being placed in the code (Read 2265 times) |
|
gotovisual
Posts: 6
|
Hi All
I've noticed a few people have posted a similar question but can't find an answer..
Basically when I edit a page in snippet
this:
<link rel="stylesheet" type="text/css" href="./css/default.css" />
becomes:
<link rel="stylesheet" type="text/css" href="./css/default.css" mce_href="./css/default.css" />
I have noticed that if you open the file, it's ok but if you save the file even if you don't make any
changes, that is when it changes your code?
Any ideas, am I doing something wrong, I think this may be responsible for IE display
differences that only happen after the snippet edit?
Thanks
Darryn
|
|
|
|
|
|
rnomis
Posts: 2
|
I am sure this is just so you can see the design in preview with the css file reference. Otherwise, all you would see would be the basic page code with no styling. It certainly shouldn't change the appearance in I.E. as all it is doing is linking the style sheet through the mce editor that this part of Snippetmaster is built on.
Maybe I am wrong and I am sure that Henri will put me right!
|
|
|
|
|
|
Jenkinhill
|
Following this I have gone and checked pages on 8 different sites which have been edited using SnippetMaster and in no case is the saved style sheet link any different to how it was originally set up. None of then referenced mce_href in the css link tag.
In the case here, though, the style sheets are both the same, so should not affect the display.
|
Kelvyn
|
|
|
admin
Forum Administrator

Posts: 3131
SnippetMaster Author
|
The extra element in the link css tag should have no effect on the CSS styles themselves. Basically, the browser should just ignore any "extra" tags that it doesn't recognize.
The IE display problem is likely caused by something else. Not sure what would be causing it though.. but IE has many screwy things with the CSS engine, and it isn't unusual for this kind of thing to occur.
1) Does the problem occur ONLY after editing with SnippetMaster?
2) if so, then can you do a "before" and "after" snapshot of the file and compare the differences in the html code?
3) Then, slowly modify the original file.. one change at a time, and see what is making the layout problem occur.
(In other words, it could be how IE is "interpreting" the html formatting.
|
|
|
|
|
|
jugjimcos
Posts: 15
|
I am having the same issue - mce_href being placed in the code
..."stylesheet" type="text/css" href="/bd.css" mce_href="/bd.css" />
<script type="text/javascript" src="/bd.js" mce_src="/bd.js">
Have purchased PRO version for a few sites now....
The problem I have is that my brief from one client is for Valid XHTML 1.0 Transitional.
The fact that Snippetmaster is inserting these attributes results in invalid xhtml.
Can anything be done to stop this!
Many thanks
|
|
|
|
|
|
Jenkinhill
|
jugjimcos, is there by any chance a <form> element on the page you are editing? Are you doing a full page edit or making use of snippets?
|
Kelvyn
|
|
|
|
|
admin
Forum Administrator

Posts: 3131
SnippetMaster Author
|
The "left over" mce_src tags are actually caused by a bug in the browser. (I don't think it happens if you use firefox.)
The problem is that the browser is actually "working with" the WYSIWYG editor, and the code that is provided by the browser and then used by the editor is missing a lot of stuff... so the editor has to create some "temporary" tags so it can keep track of things.. and then when you save the changes, it is supposed to put everything back and remove those "extra" mce_src tags.
The problem is that sometimes this doesn't happen, due to the way the browser works. The "starting code" is different then the "ending code" and so the WYSIWYG editor doesn't realize that those extra tags are... extra.. and so it leaves them in, thinking they're actually part of your code.
There will (eventually) be a new version of Snippetmaster that uses a more recent WYSIWYG editor version, and it should fix this problem. For now, the good news is that it shouldn't effect browser display of the page at all.. the bad news is that ya, technically is screws up the valid xhtml code.
|
|
|
|
|
|
Jenkinhill
|
There is indeed a form element.
In that case the problem is caused because the editor itself runs in a form textbox, resulting in nested forms. The editor tries to track css links but loses its way! The answer is not to include the form element within a snippet, and not allow the client to have full file editor access for that page. It is difficult to work with forms in editable snippets, but it can be done, as long as that form does not conytain a textbox. You have to tell the editor to ignore the form elements, see the last but one message in this thread.
|
Kelvyn
|
|
|
|
|
Pages: [1]
|
|
|
|