首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >将图片添加到RShiny actionButton

将图片添加到RShiny actionButton
EN

Stack Overflow用户
提问于 2017-05-26 19:46:59
回答 1查看 815关注 0票数 1

如何将图像添加到RShiny操作按钮?就像jpeg文件一样...

代码语言:javascript
复制
shinyUI(fluidPage( 
  titlePanel("Image on button"),

  sidebarLayout(
    sidebarPanel(

    ),

    # Show a plot of the generated distribution
    mainPanel(
      actionButton("button","Submit"),
    )
  )
))
EN

回答 1

Stack Overflow用户

发布于 2017-09-20 02:00:06

在我的解决方案下面

代码语言:javascript
复制
  shinyUI(fluidPage(
   titlePanel("Image on button"),
   sidebarLayout(
    sidebarPanel(
    ),

   #Show a plot of the generated distribution
    mainPanel(
      actionButton("button","Submit", ),
      tags$button(
        id = "my_button",
        class = "btn action_button",   
        tags$img(src = "http://i0.wp.com/unaracnidounacamiseta.com/wp-
        content/uploads/2012/07/lorem.jpg",height = "50px") #internet image
        #tags$img(src = "your_image.png",height = "50px") #local image
        ),     
       )
      )
     )
    )
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/44200842

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档