Rapid account: Textvis

Textvis / Textvis

토론

3
Title
Created at (Click to sort ascending)
A
2
Hi Antoine! Thanks for reaching out! You're right! I recently changed the hosting environment and there seems to be something wrong with the fonts. Regarding the scale, I will have a look at it. I will also add an upper case option as soon as I can. Would you mind sending me an email at contact@wordcloudapi.com? Would love to hear more about your use case and see how I can improve the API. Regards, Joakim Thu 11:16 7/6/18
A
3
Sure! You would have to use javascript to do this. Below is an example. You have to put in your mashape key instead of the text "ENTER YOUR MASHAPE KEY HERE" for it to work. ``` <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>title</title> </head> <body> <img id="wordcloud" /> <script type="text/javascript"> var xhttp = new XMLHttpRequest(); xhttp.open("POST", "https://textvis-word-cloud-v1.p.mashape.com/v1/textToCloud", true); xhttp.setRequestHeader("X-Mashape-Key", "ENTER YOUR MASHAPE KEY HERE") xhttp.setRequestHeader("Content-type", "application/json"); xhttp.setRequestHeader("Accept", "text/plain"); xhttp.onreadystatechange = function() { if(this.readyState == 4 && this.status == 200) { document.getElementById("wordcloud").src = this.responseText; } } xhttp.send('{"text":"This is a test. I repeat, this is a test. We are only testing the functionality of this api, nothing else. End of test.","scale":0.5,"width":800,"height":800,"colors":["#375E97","#FB6542","#FFBB00","#3F681C"],"font":"Tahoma","use_stopwords":true,"language":"en"}'); </script> </body> </html> ``` Wed 7:52 6/6/18
A
3
Sure! You would have to use javascript to do this. Below is an example. You have to put in your mashape key instead of the text "ENTER YOUR MASHAPE KEY HERE" for it to work. ``` <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>title</title> </head> <body> <img id="wordcloud" /> <script type="text/javascript"> var xhttp = new XMLHttpRequest(); xhttp.open("POST", "https://textvis-word-cloud-v1.p.mashape.com/v1/textToCloud", true); xhttp.setRequestHeader("X-Mashape-Key", "ENTER YOUR MASHAPE KEY HERE") xhttp.setRequestHeader("Content-type", "application/json"); xhttp.setRequestHeader("Accept", "text/plain"); xhttp.onreadystatechange = function() { if(this.readyState == 4 && this.status == 200) { document.getElementById("wordcloud").src = this.responseText; } } xhttp.send('{"text":"This is a test. I repeat, this is a test. We are only testing the functionality of this api, nothing else. End of test.","scale":0.5,"width":800,"height":800,"colors":["#375E97","#FB6542","#FFBB00","#3F681C"],"font":"Tahoma","use_stopwords":true,"language":"en"}'); </script> </body> </html> ``` Wed 7:52 6/6/18