Do not allow screen printing in a progressive web app - angular / reactjs - javascript

I would like to know if there is any solution to lock the screen print, and if possible the screen recording (although I find it difficult), from a progressive web app.
Some mobile applications have this functionality, however I would like to know the possibility of this in progressive web apps, without installation.
Grateful!

This is not possible in a web app at the moment. You have maybe found out already, but already a lot of people asked this and it is simply not possible. In a native Android/iOS app you can catch this behaviour but the browser can't.
Here are some resources that talk about this, some have glitchy tricks to do this but it's never screenshot proof :
What are the ways to prevent users to take screenshot of a webpage?
How do i prevent from printscreen of my webpage?
How can I disable print-screen functionality for a webpage in all browsers?
One tip that maybe sounds obvious, just don't put things on the internet you don't want to be saved, or whatever you are trying to protect your content from.
If you want to prevent copy-paste that's possible, but not what the question is about.

Related

Minimizing apps via nodejs || plain js

I'm currently working on personal automation project and I want to add 'minimize app' feature.
For example: When I click button, I want to minimize the current browser. I already have window.close(); but this will close the app definitly. I found things like window.minimalize(); or window.minimize();, but none of them worked for me. So is there a way to minimize app?
Edited: It does not have to be only client-side JS, it can be used as terminal based nodejs app. Ex: I type minimize Google Chrome, and it will minimize it.
One Google search for how to minimize browser gives the following result:
There is no way to minimize the browser window within javascript. No, there isn't. However, depending on what you're doing and which browsers you're targeting, you could play around with the blur and focus events of the window to achieve similar effect.
Alternatively, if such control is required, you could always port your code to Electron.js or Neutrino.js, which were made to let you create desktop applications using JavaScript.
Maybe if you post some code and give us a train of thought to follow, we could work something out.

Open Instagram from Android Browser

Intent, hooks, API, integration, dozen of cryptic javascripts, xml schemas, URL interpreters, helpers, frameworks...
It's 3 days that i'm reading blogs, SDK, tutorials to achive a very simple goal: open Instagram by clicking an URL in the Android browser. I find it a bit incredible that i needed 5 minutes to make it on iOS. I don't even know what code i should share since i don't even succeded in having an error... at least it would be something!
To make it short i have an Android phone. I open the browser to visit my website. Now i want to add a link to open Instagram camera. On iOS i simply reference to:
Open Instagram
Take a picture
Is it really that hard to code the same thing on Android? I'm not looking to make it inside another App. It's just a normal website.
After a lot of researches and tests - yeah, even more :S - i can finally state that it's not possible unless you want to force your visitors to manually download additional contents. I don't like it. It isn't an elegant and easy solution.
Please notice that i'm only talking for websites. You you are developing an App you can achive this quite easily with intents.

Using an internal network, is it possible to print documents silently?

I have a client that hosts a touch screen kiosk in their lobby. It's essentially an internal html website. They want customers to be able to click a link and have a pdf print without seeing a print dialog or having to back track... completely unnoticeable printing.
I have read articles and tried snippets of code for almost a year without finding a reputable solution. There are those out there that rightly warn of security breaches or that it cannot be done at all.
The client's old touch screen structure was made entirely in Flash which I am avoiding. BUT, they were able to pull this off. I am sure this question has been asked a thousand times, but is it really impossible?
The current CPU running the touch screen is Windows XP. They do have an IT guy that works close, but I am not sure what to ask. He never offered any other solutions.
Thank you
Not 100% sure what you're trying to accomplish but maybe you could trigger a server-side program to run instead of relying on the kiosk itself to handle the printing. You could configure the server to send these PDF requests straight to the printer.
Maybe you can bake a custom browser for them (using webkit for example) that prints without asking.
Chrome running in kisok mode, started with the --kiosk AND --kiosk-printing switches and with a default printer set, can print silently using javascript print().
This is Windows only AFAIK.

Javascript or XUL windows WITHOUT iframe

I am trying to build a multi-window website for my bookmarks, but I have some problems.
Here is the js version of what I am trying to build:
http://www.students.itu.edu.tr/~ozyildiri2/zpwin/zapatec
Unfortunately, there are problems with this approach. The sites in the windows are loaded through iframes, and iframes have problems (like framebreaker sites and js issues).
I want them to be XUL browsers or anything without iframe. Do you think this is possible? If so, how?
My main target is to make a website that people login and see their bookmarks like the one on the example. I don't want a firefox extension. I want something similar to www.only2clicks.com but showing the actual websites, not the thumbnails.
I am open to other approaches. Maybe flex or stuff.
Thank you all.
There is nothing you can do efficiently here. You would essentially be making a proxy if you fetch all of the data of a page then display it on your site using your server. And that can be tough on the server. Iframes are the best approach here if you want to display a working website in their place. Perhaps thumbnails are a better option.
I don't see why you would want to load a web site in a tiny iframe like that. You can't use the sites when they're that small.
Have you ever used the Opera browser? That might be a better solution to your problem - you can save sessions (groups of web pages) and you can also tile the tabs.

Any way to detect browser running through Terminal Services?

I am working on a site that has some jquery based animation, and I was wondering if there is any way to detect if the site is running in browser that is being run in a terminal services (remote desktop) session so I can disable the animation?
I run through remote desktop quite often from remote locations and animations always annoy me, but I really like them when I'm not running through remote desktop. Is there any way to ease the pain without getting rid of animations all together?
I guess I could allow the user to turn them off, and have it store a cookie... but is there any way to do it automatically?
This is almost certainly impossible with JavaScript (way, way above the level JavaScript operates at). It may be possible via something like Flash or ActiveX.
Edit: You will likely need something along the lines of what nVidia is using here: http://www.nvidia.com/Download/Scan.aspx?lang=en-us
Looks like a Java applet.
If the site animation is annoying to you, you may want to take it off completely as it may be annoying to site users?
I would suggest not building in extra code to stop the site from displaying as it should, in some cases users of the site may be running terminal services themselves (creating a point of failure)
If the animation is some kind of intro you could have a "skip" feature that switches it off an use a cookie as you mention.

Categories

Resources