[shiny] How to read current URL address

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[shiny] How to read current URL address

Raphael Prates

Dears,

I am trying to read the URL name  (i.e "www.google.com") that I was redirected by my own code.

What I already found that could help:


session$clientData$url_protocol
session$clientData$url_hostname
session$clientData$url_pathname
session$clientData$url_port
session$clientData$url_search

But then when I try to use this code in my server function the bellow Error appears:

> urlSearch <- session$clientData$url_search
Error in .getReactiveEnvironment()$currentContext() :
  Operation not allowed without an active reactive context. (You tried to do something that can only be done from inside a reactive expression or observer.)

Could anyone help with this? Considering that the reactive I will not use this value to renderText or to put this values on my shiny website?


Thnx

        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.