Bokeh server: html template variables etc

Hi,

Just started using bokeh server. Can anyone please help me in sorting out the following issues:

  1. I have started developing a dashboard with standard folder format ie having an index.html file in the template folder. As I understand, it is a jinja2 template. But I could not able to pass python variable through {{ variable }} tag. It renders blank html.
  2. I have also want to capture inputs from my custom jquery pop-ups to python variable and/or text widget of bokeh server. In other words, how can I pass custom javascipt variable to python?
  3. What is the way best way to use static files? How to define the path of the static folder like we do in tornado server?
  4. Is there any good document/ books available for explaining how to use templates (custom html, custom jquery widget/ function with bokeh server?
    Regards,

Sandip

Hi Sandip,

The use of templating with bokeh server is currently very limited.

You’ll find examples in the app folder, but that’s the extent of
what’s currently possible.

You can do more with the use of autoload_server and your own app -

Custom widgets (made as bokeh extensions -
)
should work just fine with the bokeh server.
I don’t believe it’s possible to define a static folder with plain
bokeh server apps as you would use normal tornado.
Having said all that, I think these are things that would be good
additions to Bokeh and I encourage you to add a feature request on
github.
Sincerely,
Sarah Bird

···

http://bokeh.pydata.org/en/latest/docs/user_guide/embed.html

http://bokeh.pydata.org/en/latest/docs/user_guide/extensions.html

  On 8/20/16 1:45 AM, Sandip Sadhukhan

wrote:

Hi,

      Just started using bokeh server. Can anyone please help me

in sorting out the following issues:

  1.             I have started
    

developing a dashboard with standard folder format ie
having an index.htm l file in the template
folder. As I understand, it is a jinja2 template. But I
could not able
to pass python variable through {{ variable }} tag. It
renders blank html.

  1.             I have also want to
    

capture inputs from my custom jquery pop-ups to python
variable and/or text widget of bokeh server. In other
words, how can I pass custom javascipt variable to
python?

  1.             What is the way best
    

way to use static files? How to define the path of the
static folder like we do in tornado server?

  1.             Is there any good
    

document/ books available for explaining how to use
templates (custom html, custom jquery widget/ function
with bokeh server?
Regards,

Sandip

  You received this message because you are subscribed to the Google

Groups “Bokeh Discussion - Public” group.

  To unsubscribe from this group and stop receiving emails from it,

send an email to [email protected].

  To post to this group, send email to [email protected].

  To view this discussion on the web visit [https://groups.google.com/a/continuum.io/d/msgid/bokeh/bb696410-c907-4107-a151-0cf05269bbe2%40continuum.io](https://groups.google.com/a/continuum.io/d/msgid/bokeh/bb696410-c907-4107-a151-0cf05269bbe2%40continuum.io?utm_medium=email&utm_source=footer).

  For more options, visit [https://groups.google.com/a/continuum.io/d/optout](https://groups.google.com/a/continuum.io/d/optout).


Sarah Bird
Developer, Bokeh

    [
      ![Continuum Analytics](http://docs.continuum.io/_static/img/ContinuumWordmark.png)
    ](http://continuum.io)

You can add a static folder to the app directory in directory-format bokeh apps.

···

http://bokeh.pydata.org/en/latest/docs/user_guide/embed.html

http://bokeh.pydata.org/en/latest/docs/user_guide/extensions.html

  On 8/20/16 1:45 AM, Sandip Sadhukhan

wrote:

Hi,

      Just started using bokeh server. Can anyone please help me

in sorting out the following issues:

  1.             I have started
    

developing a dashboard with standard folder format ie
having an index.htm l file in the template
folder. As I understand, it is a jinja2 template. But I
could not able
to pass python variable through {{ variable }} tag. It
renders blank html.

  1.             I have also want to
    

capture inputs from my custom jquery pop-ups to python
variable and/or text widget of bokeh server. In other
words, how can I pass custom javascipt variable to
python?

  1.             What is the way best
    

way to use static files? How to define the path of the
static folder like we do in tornado server?

  1.             Is there any good
    

document/ books available for explaining how to use
templates (custom html, custom jquery widget/ function
with bokeh server?
Regards,

Sandip

  You received this message because you are subscribed to the Google

Groups “Bokeh Discussion - Public” group.

  To unsubscribe from this group and stop receiving emails from it,

send an email to [email protected].

  To post to this group, send email to [email protected].

  To view this discussion on the web visit [https://groups.google.com/a/continuum.io/d/msgid/bokeh/bb696410-c907-4107-a151-0cf05269bbe2%40continuum.io](https://groups.google.com/a/continuum.io/d/msgid/bokeh/bb696410-c907-4107-a151-0cf05269bbe2%40continuum.io?utm_medium=email&utm_source=footer).

  For more options, visit [https://groups.google.com/a/continuum.io/d/optout](https://groups.google.com/a/continuum.io/d/optout).


Sarah Bird
Developer, Bokeh

    [
      ![Continuum Analytics](http://docs.continuum.io/_static/img/ContinuumWordmark.png)
    ](http://continuum.io)

[email protected]
[email protected]
https://groups.google.com/a/continuum.io/d/msgid/bokeh/2cbe9bbb-e5ab-0ab7-425f-88883b40a22c%40continuum.io
https://groups.google.com/a/continuum.io/d/optout

Hi Sara,

Thanks for clarifications.

Regards,

Sandip

···

On Saturday, 20 August 2016 14:15:12 UTC+5:30, Sandip Sadhukhan wrote:

Hi,

Just started using bokeh server. Can anyone please help me in sorting out the following issues:

  1. I have started developing a dashboard with standard folder format ie having an index.html file in the template folder. As I understand, it is a jinja2 template. But I could not able to pass python variable through {{ variable }} tag. It renders blank html.
  2. I have also want to capture inputs from my custom jquery pop-ups to python variable and/or text widget of bokeh server. In other words, how can I pass custom javascipt variable to python?
  3. What is the way best way to use static files? How to define the path of the static folder like we do in tornado server?
  4. Is there any good document/ books available for explaining how to use templates (custom html, custom jquery widget/ function with bokeh server?
    Regards,

Sandip

No problem , I hope
you s aw bran;s note, I was wrong
about static directory.

···

On 8/20/16 12:05 PM, Sandip Sadhukhan
wrote:

Hi Sara,

Thanks for clarifications.

Regards,

Sandip

      On Saturday, 20 August 2016 14:15:12 UTC+5:30, Sandip

Sadhukhan wrote:

Hi,

            Just started using bokeh server. Can anyone please

help me in sorting out the following issues:

  1.                   I have started
    

developing a dashboard with standard folder format
ie having an index.htm l file in the
template folder. As I understand, it is a jinja2
template. But I could not able to pass python
variable through {{ variable }} tag. It renders
blank html.

  1.                   I have also want
    

to capture inputs from my custom jquery pop-ups to
python variable and/or text widget of bokeh
server. In other words, how can I pass custom
javascipt variable to python?

  1.                   What is the way
    

best way to use static files? How to define the
path of the static folder like we do in tornado
server?

  1.                   Is there any good
    

document/ books available for explaining how to
use templates (custom html, custom jquery widget/
function with bokeh server?
Regards,

Sandip

  You received this message because you are subscribed to the Google

Groups “Bokeh Discussion - Public” group.

  To unsubscribe from this group and stop receiving emails from it,

send an email to [email protected].

  To post to this group, send email to [email protected].

  To view this discussion on the web visit [https://groups.google.com/a/continuum.io/d/msgid/bokeh/e9cb901f-c5c1-418a-9fab-88bee080ce8e%40continuum.io](https://groups.google.com/a/continuum.io/d/msgid/bokeh/e9cb901f-c5c1-418a-9fab-88bee080ce8e%40continuum.io?utm_medium=email&utm_source=footer).

  For more options, visit [https://groups.google.com/a/continuum.io/d/optout](https://groups.google.com/a/continuum.io/d/optout).


Sarah Bird
Developer, Bokeh

    [
      ![Continuum Analytics](http://docs.continuum.io/_static/img/ContinuumWordmark.png)
    ](http://continuum.io)