title: How to direct HTML links to siderbar items in R Shiny
body: <p>I am trying to add a HTML link in my Shiny dashboard. The ideal solution is to have users directed to a website by clicking items on the side bar. However, I could not find a solution to do so.</p>
  
  <p>Here is my code:</p>
  
  <pre><code>library(shiny)
  library(shinydashboard)
  
  header &lt;- dashboardHeader(
    title = "Test Dashboard"
  )
  
  sidebar &lt;- dashboardSidebar(
    sidebarMenu (
      menuItem("Test",startExpanded = TRUE,
               menuSubItem("Dashboard", tabName = "tab"),
               menuSubItem("Link")
      )
    )
  )
  
  body &lt;- dashboardBody(
    tabItems(
      tabItem(tabName = "tab",
              box(title = "Table", width = 10, status = "warning", DT::dataTableOutput("table"))
              )
    )
    )
  
  ui &lt;- dashboardPage(header, sidebar, body)
  
  server &lt;- function(input, output) {
  
    output$table = DT::renderDataTable({
      DT::datatable(tabledata)
    })
  }
  
  shiny::shinyApp(ui, server)
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/M1bwC.png" rel="nofollow noreferrer">This</a> is the current sidebar layout.</p>
  
  <p>Currently, I only show a datatable in the <strong>Dashboard</strong> tab, nothing in <strong>Link</strong> tab.</p>
  
  <p>I am wondering if it is possible to have the user redirected to a website (<a href="https://shiny.rstudio.com/" rel="nofollow noreferrer">https://shiny.rstudio.com/</a>) by clicking the tabname <strong>"Link"</strong> on the sidebar. </p>
  
  <p>I know the solution might be rendering the HTML link in <strong>Server</strong> and output in <strong>UI</strong>. Please advice.</p>
  
  <p>Thanks in advance.</p>