r - 使用 Shiny APP 中用户的输入更新 URL
问题描述
我正在使用一个闪亮的应用程序,我想创建一个带有操作按钮的查询,该按钮根据用户输入更新 url(在本例中为 textInput input$query_user
)。
例如这是我的ip:http: //127.0.0.1 :6858
并且在用户填写之后textInput
,单击一个操作按钮,它会将 url 上传到http://127.0.0.1:6858/?lookfor=query_user
我看过这篇文章: R shiny: Add weblink to actionButton
但它不起作用,因为该示例没有读取我的输入。
actionButton(inputId='query_button',
label="Search",
icon = icon("th"),
onclick = paste("location.href='http://127.0.0.1:6858?lookfor=",
input$query_user, "'", sep="))
)
)
解决方案
推荐阅读
- python - 为什么我使用 pygame.key.get_pressed() 时我的角色只向左移动?
- autofac - Autofac,从随机组件访问 ContainerBuilder
- powershell - 无法将整数与powershell中的运算符进行比较?
- pic18 - Uart1 和 Uart3 在 pic18fk67k40 中不能同时工作
- c# - 如何修复事件处理程序中损坏的自动完成和跳过的代码
- angular - 在 ngFor 循环中安排一些元素
- spring - 如果处理程序中发生异常,则无法将消息路由到标头中定义的错误通道
- python - 如何修复“字典对象没有属性键”
- django - 如果在 Django 中间件中检测到未知 GET,如何阻止黑客访问
- javascript - 来自父类对象的javascript构造函数