daily pastebin goal
11%
SHARE
TWEET

Untitled

a guest Oct 17th, 2018 80 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // This generates a string like: '<svg>...</svg>'
  2.   $svgString = getSvgStringFromSvgFile(session('svgFile'));
  3.  
  4.   $output = $snappy->getOutputFromHtml($svgString, [
  5.     'encoding' => 'utf-8',
  6.     'title' => session('svgTitle')
  7.   ]);
  8.   $output = base64_encode($output);
  9.  
  10.   return response()->json($output);
  11.    
  12. <object data={'data:application/pdf;base64,' + pdfData} type="application/pdf">
  13.           Your browser doesn't support pdf embedding.
  14.         </object>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top