noembed Tags in WYSIWYG

jklingman's Avatar

jklingman

24 Jun, 2014 07:40 PM

We tried to submit this twice via email, but I guess your spam filters ate it:

From one of our developers:

Hi,

We have a question about noembed tags in a WYSIWYG.

What we’ve placed in and trying to place in:

<noembed><a href=”http://www.youtube.com/v/wZ6bMZGVZDA?version=3”>Watch on YouTube</a></noembed>

What came out in the browser source:

<noembed>&amp;lt;a href="&#8221;http://www.youtube.com/v/wZ6bMZGVZDA?version=3&#8221;" data-mce-href="&#8221;http://www.youtube.com/v/wZ6bMZGVZDA?version=3&#8221;" &amp;gt;Watch on YouTube&amp;lt;/a&amp;gt;</noembed>

We tried to get around it with the passthrough tags and then tried start-code tags, but both strip it out completely in the browser.

Any insight or how to make it show correctly in the source?

  1. Support Staff 1 Posted by Tim on 24 Jun, 2014 08:25 PM

    Tim's Avatar

    Can you try something like this?:

    <!--#protect<noembed><a href="http://www.youtube.com/v/wZ6bMZGVZDA?version=3">Watch on YouTube</a></noembed>#protect-->
    
    Let me know if that allows for you to get these tags in the editor. (notice that I've replaced the closing double quotes that were originally around the link with straight quotes)

    Thanks

  2. 2 Posted by jklingman on 24 Jun, 2014 08:55 PM

    jklingman's Avatar

    Tim,

    We already tried that with this code:

    <h1>Beacon Test</h1>
    <p>Content to test <a href="/index" title="test">links</a> and 508 compliance</p>
    <br /><br /> <object width="320" height="240" data="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" type="application/x-shockwave-flash"><param name="data" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" /><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" /><param name="allowfullscreen" value="true" /></object><!--#protect<noembed> <a href="http://www.youtube.com/v/wZ6bMZGVZDA?version=3">Watch on Youtube</a> </noembed>#protect--><br /><br /> <span class="skype_c2c_container" dir="ltr" onblur="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onfocus="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" onmouseout="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onmouseover="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" skype_menu_props="{"> <span class="skype_c2c_highlighting_inactive_common" dir="ltr" skypeaction="skype_dropdown"> <span class="skype_c2c_textarea_span"><img alt="Skype" class="skype_c2c_logo_img" height="25" src="/render/file.act?path=/_files/images/skype-logo.png" width="25" /> <span class="skype_c2c_text_span">(307) 766-5426</span><span class="skype_c2c_free_text_span"> </span> </span> </span> </span>
    

    While Cascade does save it, it strips out everything in the "protect" section when publishing. The published code result is below:

    <object data="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" height="240" type="application/x-shockwave-flash" width="320"><param name="data" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" /><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" /><param name="allowfullscreen" value="true" /></object><br /><br /><span class="skype_c2c_container" dir="ltr" onblur="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onfocus="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" onmouseout="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onmouseover="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" skype_menu_props="{"> <span class="skype_c2c_highlighting_inactive_common" dir="ltr" skypeaction="skype_dropdown"> <span class="skype_c2c_textarea_span"><img alt="Skype" class="skype_c2c_logo_img" height="25" src="_files/images/skype-logo.png" width="25" /> <span class="skype_c2c_text_span">(307) 766-5426</span><span class="skype_c2c_free_text_span"> </span> </span> </span> </span>
    

    You can also see the result published here, line 161.

  3. 3 Posted by jklingman on 24 Jun, 2014 08:58 PM

    jklingman's Avatar

    Tim, I didn't address your comment about the straight quotes. Those aren't in our original code...the developer's email must have created those. Love Microsoft.

  4. 4 Posted by Ryan Griffith on 25 Jun, 2014 12:49 PM

    Ryan Griffith's Avatar

    Hi Justin,

    What version of Cascade Server are you experiencing this behavior in?

    I was doing testing as well in my local 7.10 instance and was not able to reproduce this behavior. Here is the code I entered into the WYSIWYG:

    <h1>Beacon Test</h1>
    <p>Content to test <a href="/index" title="test">links</a> and 508 compliance</p>
    <br /> <br /> <object width="320" height="240" data="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" type="application/x-shockwave-flash"><param name="data" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" /><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" /><param name="allowfullscreen" value="true" /></object><!--#protect<noembed> <a href="http://www.youtube.com/v/wZ6bMZGVZDA?version=3">Watch on Youtube</a> </noembed>#protect--><br /> <br /> <span class="skype_c2c_container" dir="ltr" onblur="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onfocus="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" onmouseout="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onmouseover="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" skype_menu_props="{"><span class="skype_c2c_highlighting_inactive_common" dir="ltr" skypeaction="skype_dropdown"><span class="skype_c2c_textarea_span"><img alt="Skype" class="skype_c2c_logo_img" src="/render/file.act?path=/_files/images/skype-logo.png" height="25" width="25" /> <span class="skype_c2c_text_span">(307) 766-5426</span> <span class="skype_c2c_free_text_span"></span></span></span></span>
    

    And here is the resulting HTML after publishing:

    <h1>Beacon Test</h1>
    <p>Content to test <a href="index.html" title="test">links</a> and 508 compliance</p>
    <br/>
    <br/>
     <object data="http://www.youtube.com/v/wZ6bMZGVZDA?version=3" height="240" type="application/x-shockwave-flash" width="320"><param name="data" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3"/>
    <param name="allowFullScreen" value="true"/>
    <param name="allowScriptAccess" value="always"/>
    <param name="src" value="http://www.youtube.com/v/wZ6bMZGVZDA?version=3"/>
    <param name="allowfullscreen" value="true"/>
    </object><noembed> <a href="http://www.youtube.com/v/wZ6bMZGVZDA?version=3">Watch on Youtube</a> </noembed><br/>
    <br/>
     <span class="skype_c2c_container" dir="ltr" onblur="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onfocus="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" onmouseout="SkypeClick2Call.MenuInjectionHandler.hideMenu(event)" onmouseover="SkypeClick2Call.MenuInjectionHandler.showMenu(this, event)" skype_menu_props="{"><span class="skype_c2c_highlighting_inactive_common" dir="ltr" skypeaction="skype_dropdown"><span class="skype_c2c_textarea_span"><img alt="Skype" class="skype_c2c_logo_img" height="25" src="/_files/images/skype-logo.png" width="25"/> <span class="skype_c2c_text_span">(307) 766-5426</span> <span class="skype_c2c_free_text_span"></span></span></span></span>
    
  5. 5 Posted by jklingman on 25 Jun, 2014 06:14 PM

    jklingman's Avatar

    Ryan,

    Their instance is 7.10.2, which I believe changed last night (was 7.8.3). I just tried publishing again, and it’s still stripping it all out. We didn't build this site, but here is the XSLT format for that region:

    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
      <xsl:output encoding="utf-8" method="html"/>
    
      <xsl:template match="/system-index-block/calling-page/system-page">
        <xsl:apply-templates select="system-data-structure/maincontent"/>
      </xsl:template>
      
      <xsl:template match="maincontent">
                 <xsl:copy-of select="content/*"/>
      </xsl:template>
    
    </xsl:stylesheet>
    

    Oddly enough, I put it into our instance (7.8.3), and it published just fine. ???

  6. 6 Posted by Ryan Griffith on 25 Jun, 2014 06:38 PM

    Ryan Griffith's Avatar

    Thank you for the additional information, Justin. That is definitely interesting. Perhaps try adjusting the format as follows and see if it changes anything with the output:

    <xsl:template match="maincontent">
        <xsl:copy-of select="content/node()"/>
    </xsl:template>
    

    Also, in your instance, do you have a Format applied to the region by chance? I am curious if there's something weird going on where the DEFAULT region without a Format is not stripping the content, but a Format w/ Index Block is.

    Please let me know if you have any questions.

    Thanks!

  7. 7 Posted by jklingman on 25 Jun, 2014 09:31 PM

    jklingman's Avatar

    Ryan,

    That did the trick! I’ll have to get them to change it, but thanks for the help.

    Justin Klingman
    Manager, Web Software Development
    Beacon Technologies Inc.
    Direct: 336.232.5685 | Mobile: 336.253.7554

    website<http://www.beacontechnologies.com/> | blog<http://blog.beacontechnologies.com/> | facebook | <http://www.facebook.com/beacontechnologies> twitter<http://twitter.com/#!/beacontec>

    Like what we do? Write a review<https://plus.google.com/112352004720495408285/about?gl=US&hl=en-US>!

  8. Support Staff 8 Posted by Tim on 26 Jun, 2014 01:34 PM

    Tim's Avatar

    Hey Justin,

    Glad to hear that Ryan's suggestions helped out. Thanks for reporting back! Have a good one!

  9. Tim closed this discussion on 26 Jun, 2014 01:34 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac