Highcharts/Highstock supported in Google Sites? - google-apps-script

Is it possible to embed Highcharts scripts in Google sites?
I've tried inserting an HTML box and also throwing everything in an HTML file and calling it via a Google Apps script. So far, both methods just give me all the text from the graph (title, axis labels, etc.), but no graph. I know embedding JS in a Google site is kind of tricky, but can this be done?

No. SVG (which Highcharts uses) is not supported within Caja (which an HTML Box and Apps Script use to sanitize and ensure safe code).

Yes, as of Jan 2016 (at least), I can easily use a highcharts library in GAS.
A dynamically updating graph using highcharts library within GAS environment can be found here: GAS-highcharts
A Working example is here: working-highcharts-GAS
It is based on this JSFiddle: jsfiddle (dot) net/gh/get/jquery/1.9.1/highslide-software/highcharts.com/tree/master/samples/stock/demo/dynamic-update/

Related

How do I reference a support file in Google Apps project

Is it possible to use a support file from within the apps script project as a source for iframe in another HTML.
I need to do this as a part of a Web App project in Google Apps Script.
Specifically I need it to work as a menu system which is the same across multiple pages, so that I don't have to repeat the same HTML code over and over again.
Better explained in a picture
Left side menu(buttons) stays the same across pages
There are several ways to accomplish what you are looking (" I don't have to repeat the same HTML code over and over again") but using iframe is not the best way when working with Google Apps Script web applications.
First you have to decide if you want to handle your web application as a multipage or as simple page.
In any case you might find helpful to use templated HTML / scriptlets to pass the code from Google Apps Script .html files to your main html code. If you find yourself scripts hard to start with, then you might use other methods of the HTML Service
Resources
https://developers.google.com/apps-script/guides/html/
https://developers.google.com/apps-script/guides/html/templates
https://developers.google.com/apps-script/reference/html
Related
Use project Javascript and CSS files in a Google Apps Script web app?
Recent related question (no answers at this time, but with comments)
HTML Service: Templated HTML as sidebar
Is it possible to create navigation bar on Google Apps Script?
how to connect a navigation bar (<nav>) with HTML files in google appscript?

How can i add Big Text in Gmail App Script Add In?

I am trying to create an add-in for Gmail using the app script. I want to use large text on top of the add-in.
But as the documentation says Gmail Add-in only supports CardService as of now, can't render an HTML there. After my research, I didn't find any option through CardService to achieve the same.
But I saw another Google Add-in doing the same I wanted to achieve.
Google Keep
I want something like No notes yet text
Answer:
The TextParagraph class supports some basic HTML formatting, but this functionality does not support font size.
Feature Request:
There is however a pre-existing feature request on Google's Issue Tracker requesting this exact functionality. You can see this at the following link:
Request for API or function to set font sizes in text paragraphs.
I urge you to hit the star on this feature request report, as Google prioritises feature requests based on popularity.

What is the replacement for the gwt-google-apis?

Currently have some code using this:
https://code.google.com/p/gwt-google-apis/
Since it hasn't been updated in years, and google code is going away...
I was wondering what the current approach/libraries are for accessing google apis from within GWT.
I think a good alternative would be to use the google map web component with JSInterop.

How to show pie, bar chart in pdf using dompdf

Hi I am using dompdf
I have report page where i have used google pie chart and google bar chart. The charts work fine in the browser. I have to display that these chart in pdf file that is created with DOMPDF. I used the same code withing the code that generates the pdf but it did not work. Is it possible to create pdf file with the google bar and pie chart? If yes, how can i implement and if not then is there any other way to create the pdf with pie chart?
Hope to get answer soon. Thanks in advance
dompdf does not currently support client-generated content (i.e. something generated using JavaScript). The Google visualization library you're pointing to is dynamically generated in the client.
If you want to use a dynamically-generated chart in dompdf you'll have to use something that generates it on the server. Google does have something like this in it's image charts library, but it's been deprecated (i.e. currently, guaranteed availability is only until 2015). You can find similar libraries.
If you still want to use client-generated charts you can try a product like wkhtmltopdf. It's based on the webkit rendering engine and supports client-side scripting.

Converting Web Page with Google map into PDF

I am using iTextSharp library for converting my .aspx page into PDF. I am using Table, labels and Google map in my page. Every thing converts into PDF except Google map. In PDF file it shows Google map code instead of showing Map. I could not understand, how to fix this problem ?
Any help to fix this
So you're using iTextSharp to parse HTML, right? Unfortunately iText and iTextSharp's HTML parsers are still in their infancy and Google's maps use both iframes and JavaScript, neither of which are supported in the parser. You can see a list of supported HTML tags here. I would not be surprised if adding a JavaScript interpreter is not even on the to-do list.