• I’ve made a theme locally on my computer (w/XAMPP) and tried this portfolio post type with Jetpack (overall very decent portfolio). I used the shortcode method and it looks great. However, now that I am building the official demo site for my new theme online, the shortcode is not working….going to the page that it exists on redirects to the default Archive page.

    I should mention I have a network setup with WordPress for my demo sites now, and this is the first site on it. The jetpack is network active but also allows me to override for each sub site I add (sub directories) and custom settings for each one with jetpack.

    Is there anything that I might have missed somewhere that the shortcode is not working here but it does on my local test site?

    Thanks in advance.

    https://wordpress.org/plugins/jetpack/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic 🚀

    Could you make sure the Custom Content Types module is active on your site? Once you’ve done so, could you go to Settings > Writing and make sure the Portfolios option is checked?

    If it is, I’d recommend going to Settings > Permalinks and saving your permalink structure once again to flush all rules on your site.

    Let me know if it helps.

    Thread Starter Styled Themes

    (@gejay)

    Hi Jeremy….first, thanks for the follow up.

    Custom Content Types is activated, Enable Portfolio Projects is checked and saved.I also resaved the permalinks. However, I discovered something…I had the permalinks set to “Post Name” option (not a custom one). If I change it to the default one, then it works, but as soon as I change it back to the Post Name option, back to the archive it goes.

    Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic 🚀

    Something seems off with your site’s redirect rules.

    Could you access your site’s .htaccess file (ref.) and make sure it doesn’t include any custom rules that may break Custom Post Type permalinks?

    Thread Starter Styled Themes

    (@gejay)

    No custom rules…I basically followed the codex during setup of my network. I set this up from within a sub directory /demos/ from a sub-domain I have. This is my htaccess as it is in the WordPress Codex

    RewriteEngine On
    RewriteBase /demos/
    RewriteRule ^index\.php$ - [L]
    
    # add a trailing slash to /wp-admin
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
    RewriteRule . index.php [L]
    Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic 🚀

    Could you also check and flush your site’s cache if you use a caching plugin?

    I assume you’ve already published a few projects in the Portfolio Custom Post Type?

    Thread Starter Styled Themes

    (@gejay)

    Good morning Jeremy….I’m not using any caching plugin. Yes, currently I have projects published. For the moment, I am using the default permalinks, so my shortcode page shows up: Portfolio

    If I use a different permalinks such as Post Name, the url in the browser is this: http://demo.styledthemes.com/demos/puresimple/portfolio/

    That simply defaults to the basic archive layout.

    Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic 🚀

    Could you try to add another plugin using Custom Post Types on your site, to see if the problem is limited to Jetpack, or happens with all CPTs?

    You can for example activate the Custom Post Type UI plugin and then head over to CPT UI > Add New to create a test CPT. Once you’ve done, go to the new menu, and create a new entry for that CPT.
    Let me know if you experience issues when trying to access that entry.

    Thanks!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Portfolio Shortcode not working’ is closed to new replies.