html - Knitr, convert to base64 and CSS style -


i'm little new great library (and html) might noob question.

i have situation i'm unable figure out - how can add css styling image while encoding in base64? code in rmarkdown file (which pass knit2html) -

<img src="someimage.png", width = "75%", border = "2"> # converts base64 width , border correctly applied <img class="displayed", src="someimage.png"> # not convert base64, points local path style correctly applied 

is there way second 1 convert base64 while applying style too? or doing wrong?

sessioninfo, if needed -

> sessioninfo() r version 3.0.2 (2013-09-25) platform: x86_64-w64-mingw32/x64 (64-bit)  other attached packages:  [1] markdown_0.6.5   xtable_1.7-1     knitr_1.5        audio_0.1-4      ggplot2_0.9.3.1   [6] scales_0.2.3     stringr_0.6.2    reshape2_1.2.2   reshape_0.8.4    plyr_1.8         [11] data.table_1.9.2 

thanks!

try this:

<style> .displayed { border: solid 1px; } </style>  <img src="rplot001.png" class="displayed"> 

Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -