Create a button for a user to create a screenshot [closed] - javascript

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I am hoping someone may have a solution for a situation I am in. I have created an online web map tool that leverages javascript, html5, jquery, and CSS to distribute information such as zoning and streets to users. The problem I have run into is getting the page to print once the user finds what they are looking for. I have tried:
Using CSS to create a print setup that works across multiple browsers but it does not work correctly and the mapDiv does not print correctly as it does not center on the map but instead focuses on only a certaing portion of the Did.
Using html2canvas to print the canvas, but it will not print the mapDiv, but will print everything else.
Using fireshot api for creating the screenshot, but it will only work in Friefox from what I have seen.
Using the ESRI print javascript api tool, but it does not generate the desired result either.
This being said, ultimately what I would like to create is a button which will screen capture what the user sees and allow them to save it to their own disk and the print. I know javascript and html does not natively have this functionality because of potential security risks and the like, but I was hoping someone here may have found a plugin which works to create a screen capture. I am okay processing this on my server if needed, but in essence I need a way of doing a Alt+PrtScr without having the user do this themselves so they capture what they are seeing.
Any and all thoughts are welcome. Also explanation of how to leverage any plugins would be helpful as well as I am a bit of a rookie at this aspect of coding and want to make sure I enable this tool properly. Thanks!

Related

How to create code for existing .exe file without knowing source code? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
What is the general approach to something like the following:
Lets say I wanted to create code that would automatically trade stocks on the Thinkorswim desktop app, how can I look up stocks, set trade parameters, and execute without knowing what the functions are or even having access to those functions?
Or say I want to create code that would perform automatic google searches so functions like new tab and filling in the url field can be carried out in my own code?
Or suppose I had a mobile game on Bluestacks (Android Emulator) and I wanted to create a bot that played the game based on a certain algorithm.
How would one go about these things without knowing the source code to the .exe they want to manipulate? I know people do things like this regularly, so what is their approach?
some examples that you are asking is called reverse engineering and it's a very complicated process, its not impossible but you are trying to achieve something that will require more time than creating it by your own.
An example of what you might want to achieve:
https://github.com/zeldaret/mm
You can see here that there are still lot of tasks to work on... and this game is from 2000.
https://trello.com/b/ruxw9n6m/majoras-mask-decompilation
Also if you want to control software itself, in a custom GUI and there is no api, its gonna be a problem.
What you might be able to create is a bot to control the mouse and interact with your GUI on a given resolution.
If you are looking for a webapp solution, you can create automation bots with Selenium and other software to interact with the DOM on a browser, also developers might change the page and your bot will break.
Have fun programming those. :)

On upload verify picture really is a ID or passport document [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
I hope you can help me - I am pulling my hair out and cannot find a way to make this happen.
I want to add an upload on my website which involves a passport or ID photo, what I need to do is validate that it really is a passport or ID on upload.
There are a few websites and apps that do it so I know it's possible I would just like to know where I can look to get started - please can you help get me started or point me to an article to read?
Thanks all!
Some time ago I had to do something similar for a project.
I used Google's API: Google VISION to send me back the text on the ID card.
https://cloud.google.com/vision/docs/ocr
There is an equivalent at AWS if you want to make a comparison
https://aws.amazon.com/fr/blogs/aws/amazon-rekognition-image-detection-and-recognition-powered-by-deep-learning/
There is an equivalent at AWS if you want to make a comparison.
Then with an algorithm of data cleaning and analysis with the coordinates in the image it is quite easy to know if you are dealing with a real document.
To find out if it is a real identity card or a real passport, you will also need to check with your country's authorities to see if the number matches.
It is a rather long job and requires patience.
If you don't have a big budget to take a turnkey tool, I advise you to develop everything yourself and not take time on wobbly projects on the Internet.
If you do not want to use an external service you can use this locally : https://github.com/tesseract-ocr/
(I had to add extra text to fix the broken link) 😭

How to created input data with Drupal? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 6 years ago.
Improve this question
So, I've been doing programming and HTML for some time now. A lot of it is front end working with CMSs and stylizing. However there's one thing I've been wanting to learn.
When it comes to drupal, how do I go about creating something where a user can enter in text and it appears above? Honestly, I'm not sure if I'm even asking about it correctly. It's something a lot of websites already have so I'm sure it's not too difficult to answer.
The best example might be Basecamp. Essentially what I'm looking to do is that if a user is on a project they are apart of, I want them to write in a little text box (similar to what i'm doing right now) click submit and it appears in a comment section above. Some sort of simple form that links directly to a field I created in drupal.
Yes I do understand there's a comment module that's built into core but I'm looking to create something similar. Or even as similar as a twitter feed. A user just goes to his or her page and has a box for them to write out a small message.
Can someone point me in the right direction as it pertains to Drupal.
Best,
V
For data input, websites usually use forms. Drupal provies an Form API that you use to create forms and process their submission. You then need to process the submitted data and store them in the database. For that you will need Drupal's database abstraction layer. Finally, you will need to build page to display the form and the stored data. A page is the result of a controller method binded to a route. That result can either be a render array (see the Theme and rende for more information), or a Symfony Response object.

Website Graphics Smooth Transitions [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
So I'm fairly new to PHP, but I have a project I'm working on and I've got a doubt about a specific aspect of web development.
My website has a major requirement, it needs to be very user friendly, and it has a lot of information that will be displayed in graphs (pie charts, column/line graphs).
My question is regarding aesthetics: is it possible to implement a smooth transition like the one microsoft office 2013 uses regarding its graphs?
If you have used ms office 2013, one thing that I noticed was its flow, and I would like to implement that feature in my website when changing values in one graph. Of course I'd much rather have functionality over looks, but if I can have both, it would be great.
This is my fisrt question here and I have searched this subject, but I haven't got any useful tip. Anyhow, if you give me some pointers on this subject (basically if it really is doable or not), I'd really appreciate it.
Cheers.
PHP is a server-side language. In order to change anything DOM related after the page loads, you need to use JavaScript.
jQuery Transit looks okay for what you need. You could also look at RaphaelJS, and D3 is great for graphs. Visibile.io is a charting DSL for D3 that would make it way easier to make charts.

Building a JavaScript grid from scratch [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I am curious to know what it takes to build a JavaScript grid from scratch. The grid should have features like jqGrid http://www.trirand.com/blog/jqgrid/jqgrid.html.
Can anyone please give me inputs?
Thanks
What it takes to build something similar to jqGrid:
A huge, HUGE amount of time.
If something similar to what you want exists already, why would you want to spend lots and lots of time re-inventing the wheel? Anyhow, if you have nothing better to do, want to learn from it or if you are just curious, here is a list of skills that are needed to create a similar system:
HTML object manipulation.
Style manipulation.
Tons of different event handlers.
AJAX to grab (pages of) documents to display. Probably some server-side stuff too...
Creating of a nice layout system wich works in every browser.
Creating handlers to read and manage the different file types to support (XML, JSON, etc)
Creating HTML forms and reading them out with JS and then use AJAX to resave an XML, JSON, etc document back to the server.
An Algorithm to allow searching in the data you display.
Keyboard manipulation and the toggling off of standard key-events.
10. Tons and TONS of debugging to make sure it looks nice in all browsers.
Of course, this is only a tip of the iceberg since I don't really know the jqGrid program myself. I created this list by looking at some of the examples and reading the Features page.
Again, I would not recommend to rebuild such a big system from scratch, but the choice is of course yours ;).

Categories

Resources