Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #887007

    scottstone
    Participant

    My template options have disappeared in cornerstone. I cannot find any documentation on this. Is anyone experiencing this issue? See screenshots.

    #887503

    Rad
    Moderator

    Hi there,

    Thanks for posting in.

    I’m not sure what causes it on your end, but we can check that out.

    Would you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:

    – Link to your site
    – WordPress Admin username / password
    – FTP credentials

    Don’t forget to select Set as private reply. This ensures your information is only visible to our staff.

    Thanks!

    #888424

    scottstone
    Participant
    This reply has been marked as private.
    #889256

    Lely
    Moderator

    Hi There,

    Please check the admin credentials above. I am getting Invalid username when logging in to your wordpress admin.

    #889304

    scottstone
    Participant

    Should be good now. Sorry, i copied my Prod DB over to Dev and completely forgot about the new user i created for this. All set, same as above.

    #889857

    Christian
    Moderator

    Hey Scott,

    Would you mind deactivating all third party plugins while we investigate? Also, please make a request to your web host to enable CORs (see http://enable-cors.org/).

    Thanks.

    #890161

    scottstone
    Participant

    All plugins are deactivated

    I requested they enable it and they said we can enable it with PHP. Their response is below. I do not know where to put this. Can you put it in the child theme and upload via sftp? Would it go in functions.php? After following the link to the same site you pointed to I was given this but I’m not sure where it would go.

    CORS on PHP
    If you don’t have access to configure Apache, you can still send the header from a PHP script. It’s a case of adding the following to your PHP scripts:

     <?php
     header("Access-Control-Allow-Origin: *");

    Note: as with all uses of the PHP header function, this must be before any output has been sent from the server.

    From Scott Stone
    From X-Theme Support: “Would you mind deactivating all third party plugins while we investigate? Also, please make a request to your web host to enable CORs (see http://enable-cors.org/)”.

    One of my plugins has lost a major piece of functionality (Cornerstone templates). The developers of the theme have a very solid support and they are requesting I ask my host to enable CORs.

    Can you do this?

    From Dustin LeBlanc (staff)
    Hi Scott,

    I’m Dustin, a Customer Success Engineer at Pantheon and I’ll be helping you out today.

    You can use CORS on the platform but the header has to be set from your application. See https://pantheon.io/docs/platform-considerations/#cors

    If you follow the link it shows you how to set CORS headers in a php script. This can be implemented in your site code. You can feel free to send the developers that link in our docs and if they have any more specific questions let us know.

    Best Regards,
    Dustin LeBlanc
    Customer Success Engineer | Pantheon

    #890922

    Lely
    Moderator

    Hi Scott,

    Please copy _header.php from wp-content\themes\x\framework\views\global to wp-content\themes\x-child\framework\views\global. Then open the copied file and add the following lines at the top:
    header("Access-Control-Allow-Origin: *");
    Entire _header.php code will be:

    <?php
     header("Access-Control-Allow-Origin: *"); 
    // =============================================================================
    // VIEWS/GLOBAL/_HEADER.PHP
    // -----------------------------------------------------------------------------
    // Declares the DOCTYPE for the site and includes the <head>.
    // =============================================================================
    
    ?>
    
    <!DOCTYPE html>
    <!--[if IE 9]><html class="no-js ie9" <?php language_attributes(); ?>><![endif]-->
    <!--[if gt IE 9]><!--><html class="no-js" <?php language_attributes(); ?>><!--<![endif]-->
    
    <head>
      <?php wp_head(); ?>
    </head>
    
    <body <?php body_class(); ?>>
    
      <?php do_action( 'x_before_site_begin' ); ?>
    
      <div id="top" class="site">
    
      <?php do_action( 'x_after_site_begin' ); ?>
    

    Then activate Cornerstone and check Cornerstone again.

    Hope this helps.

    #891026

    scottstone
    Participant

    Ok. I added that and then reactivated Cornerstone only (no other plugins). Templates is still not working properly. See screenshot.

    My _header.php now looks like:

    <?php
    header("Access-Control-Allow-Origin: *"); 
    // =============================================================================
    // VIEWS/GLOBAL/_HEADER.PHP
    // -----------------------------------------------------------------------------
    // Declares the DOCTYPE for the site and includes the <head>.
    // =============================================================================
    
    ?>
    
    <!DOCTYPE html>
    <!--[if IE 9]><html class="no-js ie9" <?php language_attributes(); ?>><![endif]-->
    <!--[if gt IE 9]><!--><html class="no-js" <?php language_attributes(); ?>><!--<![endif]-->
    
    <head>
      <?php wp_head(); ?>
    </head>
    
    <body <?php body_class(); ?>>
    
    <!-- Google Tag Manager -->
    <noscript><iframe src="//www.googletagmanager.com/ns.html?id=GTM-######"
    height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
    <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
    new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
    j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
    '//www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
    })(window,document,'script','dataLayer','GTM-######');</script>
    <!-- End Google Tag Manager -->
    
      <?php do_action( 'x_before_site_begin' ); ?>
    
      <div id="top" class="site">
    
      <?php do_action( 'x_after_site_begin' ); ?>
    #891681

    Jack
    Keymaster
    This reply has been marked as private.
    #892426

    scottstone
    Participant

    Nothing is different than my other instances of X-Theme on pantheon. This is the only site with issues. I have the same set-up with https://chargeback.com and the templates work just fine in there.

    I don’t recall ant recent changes other than wp 4.5 and new x and new cornerstone. I haven’t added any plugins.

    #892442

    scottstone
    Participant

    I have Redis Cache Server via drop-in plugin and Apache Solr Index Server and New Relic enabled through pantheon but I have all of those enabled on my other sites as well and there’s no issue.

    #893270

    Lely
    Moderator

    Hi Scott,

    Would you mind disabling that also? This is for us to make sure that the issue is not coming from any outside script or cache. Please try to purge cache before disabling it. Then do let us know how this goes.

    #894736

    scottstone
    Participant

    They are and were also deactivated. Only the Cornerstone plugin is activated. I have re-uploaded install files via ftp and no luck.

    #894757

    scottstone
    Participant

    I started deleting my plugins and clearing my cache one at a time. After deactivating and deleting SEO Redirection Premium Templates came back!!!

    I installed the plugin Redirection and imported my redirects from a csv. Checked a redirect to make sure it worked and then just for comfort clicked Edit With Cornerstone > Layout > Templates and poof, they were gone again.

    Deleted Redirection, cleared cached, no luck. Deleted and cleared cache for every other plugin, no luck. Deleted Cornerstone, reinstalled, no luck.