Archive

Posts Tagged ‘embedding’

Alter embed URL letter case to fix your broken MS-Office-file embeds in WordPress

  1. Problem: I just notice that a lot of my WordPress OneDrive embeds are broken (not sure since when).
  2. Root cause:
    1. Upon comparing the embed URLS in WordPress posts with what embed URLS sharing with OneDrive results in, it appears that the letter case in the embed URLs has been changed to all uppercase, pointing to resources that do not exist (doh!).
    2. Not sure who is to blame for altering the case:
      1. WordPress,
      2. OneDrive (note there is also the transition from “skydrive” to “onedrive”),
      3. Windows Live Writer? The latter hardly, since I did not touch these posts.
  3. Solution:
    1. Given that, while “cid=” seems all uppercase, “resid=” all lowercase, but “authkey=” is mixed case , there is not easy case change operation you could do locally to restore the original try.
    2. So you have to find the original files you embedded (not trivial from the URL which does not contain even a hint of the file name or extension) and re-embed it through sharing with OneDrive.

Change onedrive to skydrive to embed your MS-Office online files in WordPress

  1. A while ago, Microsoft was successfully sued by Sky to change the name of SkyDrive. Recently MS did that, but it looks like somebody has not gotten the memo yet, again:
  2. Originally suggested embed code from SkyDrive: https://onedrive.live.com/embed?cid=0025C841818181C2&resid=25C841818181C2%21666&authkey=ANeXAUnGHDfEqTQ&em=2
  3. Fail on WordPress.com: image
  4. Change to: image
  5. Sort of works on WordPress.com (but width and hieght parameters are being ignored): image

How to workaround problems embedding MS-Office web apps into WordPress.com

  1. UPDATE: this is becoming part of a series, it seems.
  2. SkyDrive and WordPress integration used to work much better, but not anymore?
  3. SkyDrive offers embed code with unescaped &, but you need to replace by & for  WordPress.com to accept the embed.
  4. SkyDrive offers embedding a range, but WordPress fails to display it (e.g. Item=’Sheet1′!A1%3AE10 – maybe b/o the parenthesis?);  tables do still display (e.g. Item=Table1).
  5. Wait, there is more: one or both of the following prevent display also:  &ActiveCell=’Sheet1′!C3&wdHideHeaders=True
  6. A working example for the record (to be enclosed between []):
    office width="700" height="443" frameborder="0" scrolling="no" 
    src="https://skydrive.live.com/embed?cid=4FA3329905D7E1CE&resid=4FA3329905D7E1CE%2143384
    &authkey=AGmGlsvpKj5r0pU&em=2&Item=Table1&wdHideGridlines=True"