Embed PDF into wordpress

The only reliable cross browser solution is to embed the .pdf in a iframe. add_filter(‘media_send_to_editor’, ‘my_pdf_embed’, 20, 3); function my_pdf_embed($html, $id) { $attachment = get_post($id); //fetching attachment by $id passed through $mime_type = $attachment->post_mime_type; //getting the mime-type if ($mime_type == ‘application/pdf’) { //checking mime-type $src = wp_get_attachment_url( $id ); //change the size to your liking … Read more

Help with jot form pro embed code

Try using the following plugin – https://wordpress.org/plugins/jotform-oembed/ After you have successfully installed it, all you need to do is paste in the JotForm URL on the post or page where you want it to appear: You can get your JotForm URL from the JotForm builder as shown below: Going by your Script Embed code you … Read more

Soundcloud Smart Player

If a shortcode isn’t too much effort you can use it to construct the soundcloud url for embedding. add_shortcode(‘soundcloud_auto’, ‘soundcloud_auto_shortcode’); function soundcloud_auto_shortcode($atts) { global $post; $title = str_replace(” “, “”, $post->post_title); $title = str_replace(“-“, “”, $title); $title = str_replace(“_”, “”, $title); $slug = sanitize_title($title, str_replace(“-“, “”, $post->post_name)); return wp_oembed_get(esc_url(“http://soundcloud.com/$slug”)); } Or do something similar using … Read more

oEmbded with wp_insert_post() [embedly]

Read up on Embeds. To trigger an embed use wp_oembed_get($url). In general the url needs to be on it’s own line with a space below and above when inside the_content. wp_insert_post() has nothing to do with embeds as the embed HTML is usually generated when passed through the_content filter. To add support for non-oEmbed sites … Read more

TED talk embedded videos cut off by sidebar

I remember when TED videos first brought me here to WPSE some time ago 🙂 The global content width or the embed size width option embed_size_w might be slightly off on your site. Alternatively you could manually insert the width: [ted id=”2252″ width=”600″] where the height is then adjusted to give you the 16×9 aspect … Read more

Setting up a HIPAA secured form / file upload

Assuming a developer that is/stays current on relevant security issues creates/manages the site, and a HIPAA compliant (per the regulations) hosting environment is used, forms, uploading, etc. is fine. If you proceed, note that compliance is more than technical. Policies/procedures have to be in place for using/managing the solution as well as incorporating the solution … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)