<?php /* Plugin Name: PDF Viewer Plugin URI: Description: Embed PDF with [pdf src="url" size="xxx"] Author: juangotoh Version: 0.1 Author URI: */ function pdfEmbed($attrs, $content = null) { $src="http://"; $size="200"; extract($attrs); $thumb=$src."-thumb.jpg"; $sizeStr=""; $curSize=0; $a=explode("wp-content", $src); $pdfPath=WP_CONTENT_DIR.$a[1]; $thumbPath=$pdfPath."-thumb.jpg"; $pi=pathinfo($p