closeSockets <- function() {
allCon <- showConnections()
socketCon <- as.integer(rownames(allCon)[allCon[, "class"] == "sockconn"])
sapply(socketCon, function(ii) close.connection(getConnection(ii)) )
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.