body_replace_at = function(...) {
res = try(officer::body_replace_at(...),silent = TRUE)
if (is(res, "try-error")) {
res = officer:::body_replace_text_at_bkm(...)
}
res
}
remove.null = function(li) {
if (length(li)==0) return(li)
nu = sapply(li, is.null)
li[!nu]
}
example.replace.umlaute = function() {
str = c("äan")
for (f in list.files(getwd(), full.names=TRUE)) {
cat("\n",f)
parse(f)
}
replace.umlaute(str)
}
replace.umlaute = function(str) {
stringi::stri_replace_all_fixed(
str,
c("\U00e4", "\U00f6", "ü", "Ä", "Ö", "Ü","ß"),
c("ae", "oe", "ue", "Ae", "Oe", "Ue","ss"),
vectorize_all = FALSE
)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.