Learn R Programming

periscope2 (version 0.2.4)

get_url_parameters: Parse application passed URL parameters

Description

This function returns any url parameters passed to the application as a named list. Keep in mind url parameters are always user-session scoped

Usage

get_url_parameters(session)

Value

named list of url parameters and values. List may be empty if no URL parameters were passed when the application instance was launched

Arguments

session

shiny session object

Shiny Usage

Call this function from program/server_local.R or any other server file

See Also

periscope2:set_app_parameters()

periscope2:add_ui_footer()

periscope2:add_ui_left_sidebar()

periscope2:add_ui_header()

periscope2:add_ui_body()

periscope2:add_ui_right_sidebar()

periscope2:ui_tooltip()

Examples

Run this code
  library(shiny)
  library(periscope2)

  # Display application info
  observeEvent(input$app_info, {
               url_params <- get_url_parameters(session)
               show_alert(html                = TRUE,
                          showCloseButton     = FALSE,
                          animation           = "slide-from-top",
                          closeOnClickOutside = TRUE,
                          text                = url_params[["passed_paramter"]],
                          title               = "alert title")
  })


Run the code above in your browser using DataLab