Error connecting to server when embedding video - html

While trying to embed some code on my website, I received the following error:
[Server.Reject] : (defaultRoot, defaultVHost) : Invalid application name (vod/liv e_2011_11_30_beard).
The strange thing is that it works inside the WYSIWYG editor I use, but the error occurs when the post is published or previewed.
The code I am embedding was as follows:
<embed src='http://www.nypl.org/sites/all/modules/nypl_content/jwplayer/player-licensed.swf' width='426' height='286' bgcolor='000000' allowscriptaccess='always' allowfullscreen='true' play='true' wmode='opaque' flashvars='image=http%3A%2F%2Fwww.nypl.org%2Fsites%2Fdefault%2Ffiles%2Fimages%2Fav%2F6437035995_67dc89cb40_b.jpg&file=live_2011_11_30_beard.mp4&streamer=rtmp%3A%2F%2Fflash01.nypl.org%2Fvod%2Flive_2011_11_30_beard&skin=http%3A%2F%2Fwww.nypl.org%2Fsites%2Fall%2Fmodules%2Fnypl_content%2Fjwplayer%2Fskins%2Fstormtrooper.zip&plugins=gapro-1,adtvideo%2Cviral-2&adtvideo.config=/xml/ad_config/seed&gapro.accountid=UA-1420324-3&gapro.trackstarts=true&gapro.trackpercentage=true&gapro.tracktime=true&gapro.idstring=||streamer||&viral.onpause=false&viral.oncomplete=true&viral.allowmenu=false&viral.functions=embed'></embed>

Related

Error posting images from web pages using #Url.Content in MVC

I'm trying to allow users to edit my database by adding images from websites (posting the URL links into a field using the edit view), when trying to deploy my MVC project, I got an error that says a different row in my table cannot be null, it wasn't null, but when I removed this line of code that would present the image on the page, the error went away:
<img src="#Url.Content(item.Picture)" height="100" />
This is the line of code the error pointed out:
#Html.DisplayFor(m => item.Founder)

iOS 9 "Save PDF to iBooks" with HTML

iOS 9 has a new built-in UIActivity of UIActivityTypeOpenInIBooks. It's in the default list of activities in the UI and in header file but I've not been able to find any API documentation for it (yet).
It appears that UIActivityTypeOpenInIBooks will create a PDF in iBooks just fine if you include UIImages in your UIActivityViewController items or return them in your UIActivityItemProvider.
However I'd like to create a PDF with an HTML page containing text and images like Safari does. But I can't seem to find a way to pass the HTML to UIActivityTypeOpenInIBooks in an acceptable way.
I've tried passing the HTML as a String, NSData and NSURL of a file. I've also tried returning an UIMarkupTextPrintFormatter which works fine for printing but not for UIActivityTypeOpenInIBooks.
Providing an HTML string or the UIMarkupTextPrintFormatter both result in the following errors:
2015-09-08 11:35:46.392 MyApp[4599:1492484] ERROR: attempting to save to URL with no printing source (formatter/renderer) set
2015-09-08 11:35:46.393 MyApp[4599:1492484] FAILED! due to error in domain UIPrintErrorDomain with error code 4
Has anyone gotten this working?
You can convert the html to pdf before saving it to ibooks.

accessing https iframe element on chrome-extension

I added an iframe and jquery to my popup.html.
<iframe id="xyz" border="0" src="https://xyz.com/test"></iframe>
and trying to reach an element of this iframe with this command via console :
$("#xyz").contents().find("body").fadeIn();
but it giving this error :
Unsafe JavaScript attempt to access frame with URL https://xyz.com/test from frame with URL chrome-extension://my-extension-id/popup.html. The frame requesting access has a protocol of 'chrome-extension', **the frame being accessed has a protocol of 'https'. Protocols must match**
I searched google for this error but there is no error like this. All of them saying domain must match etc. But this one saying only protocols must match. How can I solve this protocols problem?
And I have this line on my manifest file.
"permissions": [
"*://xyz.com/*"
]
Seems like an issue with same origin policy.
Try following the solution mentioned in this discussion. Also, try doing it through native Javascript first before trying to do it using jQuery.

Html from Silverlight (not out of browser)

I am trying to open HTML file from the local URI which I use as XML Editor, to edit xml data that come from Silverlight application, then close browser window and return back edited xml data to the Silverlight application.
I tried to use HtmlPage.Window.Navigate but I don't quit like it.
I have tried using a method from: http://weblogs.asp.net/dwahlin/archive/2010/05/10/integrating-html-into-silverlight-applications.aspx
but instanly got an exception "failed to invoke ShowJobPlanIFrame"
Is there any way to handle this task?
"Out of browser" mode doesn't fit.
Thanks.
===========================================================================
Update:
It worked out using IFrame overlay.
Button click invokes the following code in C#:
var scriptObject = (ScriptObject)HtmlPage.Window.GetProperty("ShowJobPlanIFrame");
scriptObject.InvokeSelf(url);
Where "ShowJobPlanIFrame" is as defined at:
http://weblogs.asp.net/dwahlin/archive/2010/05/10/integrating-html-into-silverlight-applications.aspx
This allowed me to pass data into XML editor and then get it back.
An error with JavaScript function invocation I told above, was my fault in JavaScript code itself.
A very similar scenario: https://stackoverflow.com/a/7919065/384316
Try using an iframe overlay, then you can load any HTML-like content.
There is an excellent explanation of how to do this here:
http://www.wintellect.com/cs/blogs/jlikness/archive/2010/09/19/hosting-html-in-silverlight-not-out-of-browser.aspx
It worked out using IFrame overlay.
Button click invokes the following code in C#:
var scriptObject = (ScriptObject)HtmlPage.Window.GetProperty("ShowJobPlanIFrame");
scriptObject.InvokeSelf(url);
Where "ShowJobPlanIFrame" is as defined at:
http://weblogs.asp.net/dwahlin/archive/2010/05/10/integrating-html-into-silverlight-applications.aspx
This allowed me to pass data into XML editor and then get it back.
An error with JavaScript function invocation I told above, was my fault in JavaScript code itself.
Did you try NavigationFramework of Silverlight? It's capability may support your needs in a more simple way than using multiple browser pages.

How to have pdf viewer in ruby

How can I embeded pdf viewer in ruby on rail?
Now I tried
<embed src="MyPdfDocument.pdf" width="500" height="375">
but it doesn't work. I used firebug and see the error like this
[Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIStreamListener.onStopRequest]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: file:///home/bengasi/.mozilla/firefox/cmb1mbzu.default/extensions/firebug#software.joehewitt.com/components/firebug-channel-listener.js :: anonymous :: line 167" data: no]
[Break on this error] this.listener.onStopRequest(request, requestContext, statusCode);\n
firebug-...stener.js (line 167)
If you are trying to display a PDF as an image, surrounded by HTML content... then a browser won't do that, and your problem is with the browser, not Ruby on Rails. You can link to a PDF, and display it whole, but you cannot embed it in another document.
You could simulate the effect (maybe, in some browsers) with an iFrame, but that is a HTML question, not a rails question... and you would possibly spend a lot of time making it work in all browsers.
You might find this useful:
http://googlesystem.blogspot.com/2009/09/embeddable-google-document-viewer.html