简体   繁体   中英

How to put a logo here? Shiny apps R

在此处输入图像描述

Hi,

I need to put a logo in this red place, I already tried:

cabecalho <- dashboardHeader(title = "Test", titleWidth = '300px')
cabecalho$children[[2]]$children <-  tags$a(href='http://mycompanyishere.com',
                                                        tags$img(src='logo.png',height='50',width='100'))

But this gave me the image inside the "Test" title.

I solved this problem just adding this to dashboardHeader:

dashboardHeader(title = "Report", titleWidth = '240px', 
                             tags$li(a(href = 'http://www.site.com.br',
                                       img(src = 'logo.png',
                                           title = "Company Home", height = "30px"),
                                       style = "padding-top:10px; padding-bottom:10px; padding-right:17px;"),
                                       class = "dropdown")
                             
                             )

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM