Blazor iframe not working with Internet Explorer 11 - asp.net-core

I am currently working on a Blazor ASP.NET CORE 3.1 application that needs to work on IE11. I am trying to view a PDF from the PDF binary. I have added tried adding blazor.polyfill.js and blazor.polyfill.min.js to the project and it makes the rest of the application work, but it doesn't allow me to view PDFs in the iframe. Below is a picture of the code I have.
https://i.stack.imgur.com/Xsrrk.png
I am trying to set the src of the iframe as a pdf binary. Does anyone have any idea what I can do to get this to work?

Please first make sure any kind (for example, a simple string) of iframe contents work for you. If you still have the problem afterwards, try to reproduce it here: https://blazorfiddle.com/
This will also enable the community to assist you.

Related

Displaying PDF on website using pdf.js

I want to put a file sample.pdf on my website, and want it to be displayed using pdf.js. What I want is to display my own file like the demo, with a toolbar, zooming in/out, etc. So far I can't do that yet.
I did check out the helloworld example, but it simply shows the file like an image, without toolbar, zooming in/out, etc. When I put another file with many pages instead of helloworld.pdf, it just shows the first page.
I am not quite sure what you are looking for but I was able to get this working exactly like the demo. Although you may not want to use that example viewer for your project, you can use the working code as a starting point for your own requirements.
For a simple test you can just clone the project somewhere under a web server into a directory like myproject and visit http://yourservername.com/myproject/web/viewer.html. You should see the pdf appear. This can be a starting point to working with this project. I did this running a very basic Apache server on Linux.
If you are not looking for an example styled like that the demo above you can also see this jsbin from the docs that show how to do something completely customized with working next/previous buttons to move between the pages (as you mentioned you were only seeing the first page).
As a note, it seems that this library does not work properly with Safari. You can see an issue about it here. Unfortunately this makes it unusable for me now as I need to support all current browsers.
Also, remember to watch for the warnings concerning CORS.

Forced to switch from iframe to SDK for share buttons

I was using an iframe share button solution to be able to share products or posts on facebook. I used this systeme wich worked great on about 10 different websites but this week, they all ended up no working.
I read I should get an appId for each website and use Asynchroneous SDK, which I did, and followed steps to get it to work:
Load the SDK with appId authentification.
Load jQuery if needed (some buttons require it).
Add button code were desired.
I can see the SDK is loaded in <div id="fb-root"></div> but the share button never appears on the page and it is not a layout issue. I have tried several different buttons but they all seam to never make it to the user.
I read a lot of posts about the issue but each one was magically solved on Jully 22nd... not mine. I need help implementing this first button as I need to fix many websites afterwards. Thx!
When doing a fresh implementation of FB btns I ended up going here:
https://developers.facebook.com/tools/debug
to force FB to crowl the pages I was working on at the moment.
This proved usedful in getting immediate feedback on how things were working out.

Migrating Widgets in Telerik Sitefinity

I fell into a project where my task was develop some widgets in Sitefinity 4.4. I've found a lot of documentation on how to create the widgets using the Site Manager and all that has gone really well.
Now, I have the widgets set up in a test environment and working well with some test pages. I'm trying to figure out how to deploy the widgets to the production server without re-doing all the work there. I just want to move the widgets over - I don't need or want the pages. I have gone through a lot of the Telerik documentation, but have been unable to find anything about deploying like this. Has anyone done this before?
Thanks!
did you develop these widgets as compiled controls (dll) or simple user controls (.ascx)?
The process is mostly the same for either. the dll goes in the bin folder whereas a user control gets uploaded to the website folder somewhere. then you simply register the widget in the toolbox.
here is the documentation for how this is done: http://www.sitefinity.com/documentation/documentationarticles/adding-controls-to-the-toolbox
The only difference for a compiled dll widget is to use the fully qualified name for the ControlType instead of the path to the user control.
After registering the widget it should be available to drop onto any page.
Hope this is helpful!

Multiple photo upload using struts1

We happened to get requirement to upload the multiple files ( like the gmail attachments ) using struts 1.3.5 and Ajax.
I happened to go thorough lot of resources but no luck.
Can someone shed light on this possibly by suggesting or pointing to some useful resources.
I was also looking for a multiple file upload solution for my struts2 application. Since ajax form submit do not support image submission the only option to use was a hidden iframe strategy. However, i found this wonderful plugin which uploads multiple files withour reloading the page and also shows a cool progress bar. The best thing about this plugin is that it doesn't uses flash and works on IE too. I strongly recommend using this plugin
Donot use taglibrary defined file upload for uploading. You can still use
common- fileupload to handle file upload. By doing this you can dynamically
add one more input type file element below the current input type upload using
javascript. I doubt if there is any way to do this using pure struts 1.3.5 :) .

Problems Embedding Video using FCK Editor

I am using FCK Editor 2.6.4 and having problems trying to embed a (non-YouTube) video into a content area.
I found this previous question / post:
[EDIT -- as a new user, I am only able to post one link in this post. The post in question is titled, "Can I embed video using FCK Editor?")
and have investigated all of the proposed solutions, but none of them work properly:
1 -- Using the "Embed Flash" button in the control panel almost works. However, the video I am attempting to add contains a querystring with parameters, like this:
http://static.animoto.com/swf/w.swf?w=swf/vp1&e=1275795594&f=mGQklEgxXKs9vfEIdGnWsA&d=132&m=p&r=w&i=m&ct=Homes%20in%20Eagle%20Creek&cu=http://hometoindy.com/eagle-creek-real-estate.php&options=
and in using the Flash embed tool, it encodes all of the "&" characters to "& amp;", thus breaking them. If it were just for me, I could manually change them back, but clients who use this will not know how to do that.
2 -- I have installed the YouTube video plugin, and it works great... for YouTube. But it cannot be used to embed non-YouTube videos (it automatically changes the URL to YouTube, no matter what).
3 -- I have installed the EmbedMovies plugin, but it throws a javascript error when attempting to add a video file (such as the above) to a page. (The EmbedMovies plugin page on SourceForge says it has been updated for FCK Editor 2.6, but it does not work.)
4 -- Pasting directly into the editor window (of course) does not work. The only way I've been able to make this work is by pasting into the Source panel, and this is not a good option for clients who are not familiar with HTML.
So, is there a good, working plugin for FCK editor that will allow me to quickly and easily embed a video such as the one above into a content area? I don't need to be able to see or preview it in the editor window; I just need it to work when the page is loaded on the front end.
Thanks!
Given the question you found, and scarcity of answers to that, chances are that the plugin you want does not exist.
If your videos are actually from one, though non-standard, source, I can only repeat my advice from that topic - write your own plugin. I have code of plugin I wrote linked there, it should be easy to change it to accomodate your needs.