Title: <abbr title="Not Safe For Work / Mature content">[NSFW]</abbr> Posts: invalid template name
Last modified: May 25, 2020

---

# [NSFW] Posts: invalid template name

 *  Resolved [ethiopia02](https://wordpress.org/support/users/ethiopia02/)
 * (@ethiopia02)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/)
 * Hi, sorry for my english. For a few hours I can no longer view the posts and 
   I am reporting the error in Topic Title. I can’t understand what happened. can
   you help me?
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fposts-invalid-template-name%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 15 replies - 1 through 15 (of 15 total)

 *  [2zi0](https://wordpress.org/support/users/2zi0/)
 * (@2zi0)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12888401)
 * Hi, I have the same problem after the last update: it seems updating has deleted
   the
 * `/wp-content/plugins/shortcodes-ultimate/templates`
 * folder inside the plugin.
 * I’m trying to recover it from a backup.
 *  [uperl](https://wordpress.org/support/users/uperl/)
 * (@uperl)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12888749)
 * Too bad that the change of the template path was not noted in the changelogs,
   I had to search for a while. – But otherwise it’s a cool plugin.
 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12888758)
 * Hi [@2zi0](https://wordpress.org/support/users/2zi0/) and [@ethiopia02](https://wordpress.org/support/users/ethiopia02/),
 * you should never edit templates within the plugin folder since all your changes
   will be lost after the plugin update, just like this time. Please read the detailed
   guide on how to do that properly:
 * [https://getshortcodes.com/docs/posts/#template-editing](https://getshortcodes.com/docs/posts/#template-editing)
 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12888760)
 * > Too bad that the change of the template path was not noted in the changelogs,
   > I had to search for a while. – But otherwise it’s a cool plugin.
 * My bad…
 *  Thread Starter [ethiopia02](https://wordpress.org/support/users/ethiopia02/)
 * (@ethiopia02)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12889005)
 * I have never modified the plugin and the templates but I have always used the
   basic functions and yet the problem has occurred anyway …
 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12894958)
 * [@ethiopia02](https://wordpress.org/support/users/ethiopia02/), could you post
   here your shortcode?
 * Thank you.
 *  Thread Starter [ethiopia02](https://wordpress.org/support/users/ethiopia02/)
 * (@ethiopia02)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12897365)
 * Dear Vladimir,
 * my web page is [https://www.musicainmostra.it/zeus/](https://www.musicainmostra.it/zeus/)
 * and my shortcode is
 * [su_posts posts_per_page=”-1″ taxonomy=”post_tag” tax_term=”1799″ tax_operator
   =”AND” order=”asc” orderby=”title”]
 * Thank you
 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12900811)
 * [@ethiopia02](https://wordpress.org/support/users/ethiopia02/),
 * is Shortcodes Ultimate activated now? I can only see raw shortcodes on your page.
 * Your shortcode looks correct, I tested it on my development website and it does
   work. Please try to remove the plugin through FTP and install it again from within
   the dashboard.
 *  [hiroki2020](https://wordpress.org/support/users/hiroki2020/)
 * (@hiroki2020)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12903188)
 * Go to wp-content/plugins/shortcodes-ultimate/includes/shortcodes/posts.php
    line
   432:
 *     ```
       $path = realpath( $path );
       ```
   
 * add the following line:
 *     ```
       $base = realpath( $base );
       ```
   
 * For me its working now.
 *  [webbbs](https://wordpress.org/support/users/webbbs/)
 * (@webbbs)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12923276)
 * [@gn_themes](https://wordpress.org/support/users/gn_themes/) [@hiroki2020](https://wordpress.org/support/users/hiroki2020/)
 * Hiroki2020’s fix worked for me as well. Consider for next plugin update.
 * peace
 *  [Ed](https://wordpress.org/support/users/eammendola/)
 * (@eammendola)
 * [6 years ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12956780)
 * [@hiroki2020](https://wordpress.org/support/users/hiroki2020/) this worked for
   me, as well. Thank you!
 *  [danielldaz](https://wordpress.org/support/users/danielldaz/)
 * (@danielldaz)
 * [5 years, 12 months ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12982054)
 * Hey Vladimir,
 * my webste is
 * and my shortcode is [http://www.soyblanquiazul.com](https://wordpress.org/www.soyblanquiazul.com?output_format=md)
 * [su_image_carousel source=”media: 7,6,5,4″ slides_style=”photo” crop=”16:9″ max_width
   =”100%” arrows=”no” dots=”no” target=”self” autoplay=”3″ image_size=”full”]
 * I think I bought a template that was using the previous version of this plugin,
   when I try to make a new shortcode, it doesn’t appear, I read that **su_carousel**
   _was changed to **su\_image\_carousel**_, I made the change but I can’t see the
   carousel.
    I need help please.
 * template : [https://themeforest.net/item/braga-fashion-theme-for-woocommerce-wordpress/25982053](https://themeforest.net/item/braga-fashion-theme-for-woocommerce-wordpress/25982053)
 * Thank you
 *  [douglasborges](https://wordpress.org/support/users/douglasborges/)
 * (@douglasborges)
 * [5 years, 12 months ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-12993571)
 * [@hiroki2020](https://wordpress.org/support/users/hiroki2020/) tks so much, you
   saved my life!
 * Congrats for the solution.
 *  [macrodreams](https://wordpress.org/support/users/macrodreams/)
 * (@macrodreams)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-13010949)
 * I tried the above solution suggested by Hiroki2020’s..
 * but still I am getting this error..
 * Posts: invalid template name
 *  [Elyssa](https://wordpress.org/support/users/elyssa444/)
 * (@elyssa444)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-13557724)
 * When I update this plugin I get this error message Posts: invalid template name.
 * As suggested by [@hiroki2020](https://wordpress.org/support/users/hiroki2020/)
   I went to
    wp-content/plugins/shortcodes-ultimate/includes/shortcodes/posts.php
   but line 432 is different.
 * $path = path_join( $base, $template );
 * /* This is line 427-437. */
 * foreach ( $locations as $base ) {
 * $base = untrailingslashit( $base );
    $base = realpath( $base );
 * /*line 432*/ $path = path_join( $base, $template );
    $path = realpath( $path );
 * if ( file_exists( $path ) && strpos( $path, $base ) === 0 ) {
    return $path; }
 * /* I know enough php to be able to edit, but not write the code.
 * I also tried deleting the plugin through Filezilla and re-uploading it through
   the WP back end Plugins Add New and after I activated the plugin it created a
   fatal error. The staging site was no longer accessible, so re-set it. I would
   like to keep this plugin up to date, please help! */

Viewing 15 replies - 1 through 15 (of 15 total)

The topic ‘[NSFW] Posts: invalid template name’ is closed to new replies.

 * ![](https://ps.w.org/shortcodes-ultimate/assets/icon-256x256.gif?rev=2547563)
 * [Shortcodes Ultimate - Content Elements](https://wordpress.org/plugins/shortcodes-ultimate/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/shortcodes-ultimate/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/shortcodes-ultimate/)
 * [Active Topics](https://wordpress.org/support/plugin/shortcodes-ultimate/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/shortcodes-ultimate/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/shortcodes-ultimate/reviews/)

## Tags

 * [su_carousel](https://wordpress.org/support/topic-tag/su_carousel/)

 * 15 replies
 * 11 participants
 * Last reply from: [Elyssa](https://wordpress.org/support/users/elyssa444/)
 * Last activity: [5 years, 7 months ago](https://wordpress.org/support/topic/posts-invalid-template-name/#post-13557724)
 * Status: resolved