Yeah, I figured that I am doing the custom work, I just thought if I got an idea of the best place to start. Guess I will dig through code.
The latest update of AMP 2.1.1 fixed the issue.
Any ideas on how this will interact with WP Rockets Optimize CSS delivery?
So does that mean you can’t have AMP & Mobile Plugin installed and active if you want to use the “create mobile template”? If not do you Disable AMP and Disable or OFF Enable/Disable Mobile Theme for the, let’s say, Homepage Page? I was working on just making a mobile template page for homepage, but everything else AMP and Mobile original.
Thanks!
Not the way I wanted it to. It works great once I commented out those two lines. I hope to discover the root cause. This is only needed if you are using the “Hide Content Only” with “Show Excerpts” part of Membership, if you redirect or hide completely, there isn’t a problem. I love this theme and equally the membership plugin w/ woocommerce subscription great combination.
I have to update the fix with the latest update of Membership plugin, which incorporates the excerpt length, so though I still think further is needed to properly address this issue as I believe it is related to the unique way the TD Cloud Templates works.
The first one below has to comment out, for some reason when enabled you won’t see images.
File: /woocommerce-memberships/includes/Restrictions/Posts.php.
Function: public function handle_restriction_modes()
// ensure the restricted post content data is persisted even when third parties try to filter it
Comment out ->//add_filter( ‘the_content’, array( $this, ‘handle_restricted_post_content_filtering’ ), 999 );
With the update Membership you have to comment this as well:
File:/woocommerce-memberships/includes/class-wc-memberships-user-messages.php
Function: private static function trim_excerpt( $the_post ) {
if ( true === (bool) apply_filters( ‘wc_memberships_message_excerpt_apply_the_content_filter’, true ) ) {
/** This filter is documented in wp-includes/post-template.php */
Comment Out ->//$excerpt = apply_filters( ‘the_content’, $excerpt );
}
The last one seems to cause the server to an internal error, I have seen this with other plugins and TD Library files. Like I said I wish I can find a proper solution, but this does solve the issue and renders a page like this: https://fortworthbusiness.com/real-estate/om-housing-kennedale/
Hope this helps.
Did you have any issues with WooCommerce, I haven’t done a deep-dive into all the updates that were included with 4.7? I run a multiple subscription site with memberships.
Same issue, glad that we know about it, has anyone had issues downgrading to 4.6 from 4.7?
-
This reply was modified 5 years by
elvisfrog.
Update: I have a workaround if someone else is having this same issue.
File: /woocommerce-memberships/includes/Restrictions/Posts.php.
Function: public function handle_restriction_modes() {
If Statement: if ( ‘hide’ !== $restriction_mode || $is_rest_api_request ) {
// ensure the restricted post content data is persisted even when third parties try to filter it
//add_filter( ‘the_content’, array( $this, ‘handle_restricted_post_content_filtering’ ), 999 );
Comment out the “add_filter” and then Woocommerce Membership plugin will display the restricted content properly with Cloud Libray Template.
I Will update when I have a proper solution. Looking to add this as a snippet so updates to files won’t affect this alteration.
Any update on this? This is a major issue I am having with several plugins and Cloud Library? Spent days with other developers to isolate this issue.
Have a similar desire, looking to programmatically change the post-setting template on the fly, but really posted so I can get notified when someone updates this post. I have woocommerce members plugin and it doesn’t display properly with the cloud templates, but the Single Template it does, so trying to setup a way to programmatically change it for non-members.
Okay, maybe you might be able to isolate this issue for me, so I use the TD Cloud Library and I have Standard Pack disabled. When I use the Post Settings and select a “Custom Blank – Single Template” from Cloud Library and I removed the header/footer to just rule out code from that, I get the improper rendering as displayed here: https://fortworthbusiness.com/opinion/richard-connor-your-first-vote-is-a-vote-you-should-always-remember/ which again looks fine on the mobile version.
Now, I used the settings above for a test article located here: https://fortworthbusiness.com/uncategorized/test-article/ and reproduce the same incorrect formating, if I change the Post Settings to “Default – Single Template” it renders properly.
I believe that is part you alluded to early with using the non-cloud library template, but how could I fix this in a cloud library template? I also for testing using the Blank Single Template Cloud with just the post content so something in the way processing that is content causing it not to render using a cloud template but works with the default single template? I know I had this same issue with MemberPress and their use of restrict content with excerpts. So my thinking is how plugins edit the Post Content is universal, but how Cloud Library renders is different than how it renders the “Default – Single Template” which I assume is a file template?
Not sure if this is in a JS call or PHP backend, my guess it is in the PHP somewhere for how the TD Cloud Library renders a final page.
FYI, It was compatibility with Font Awesome that caused not to render properly, not sure why but I was able to isolate it using Plugin Organizer.
I found that the render part is working, it is something afterwards. What script calls the render function? I was looking in all the other plugin files and can’t find I guess the global script that renders the all the pages. Render function is outputting correctly but I don’t know what script calls it. I don’t know if it is part of Newspapers “master” program?
The function Render seems to work, but isn’t getting output correctly.
<div class=”td_block_wrap tdb_single_content tdi_99_54b td-pb-border-top td_block_template_1 td-post-content tagdiv-type” data-td-block-uid=”tdi_99_54b” >
That is the begging of what is in buffy from Render but is not displayed again on the page. Trying to locate which script calls Render and what happens with return data.
Okay, looking into file /td-cloud-library/shortcodes/single/tdb_single_content.php I see this: function render($atts, $content = null), I think that is where my problem lies, WooCommererce Membership passes a truncated text in $post_content_data[‘post_content’] and it seems that the rest of the script stops render, though the footer is there, I see a lot of missing scripting. Wonder if the Render script is breaking or something. I at least have more hope then I have in the past.
I don’t mind paying, but if the direction can be provided that would be great as I have the skills to fix when I know where to look. Thanks!
Is it possible to get some custom work done? The mobile side works, here is a live example: https://fortworthbusiness.com/opinion/richard-connor-canceling-the-rodeo-is-painful-but-its-the-right-thing-to-do/ you can see the desktop renders incorrectly, and when I use the twenty WordPress theme it works, so I know it is an issue with the Cloud Template rendering, I have the code experience but not sure how to manually interrupt or correct this. I would be interested if I have to pay to have your team develop a solution I would appreciate as we are committed to the WooCommerce and Membership plugin so this will be a long term, and of course, we are not dumping the Newspaper theme anytime soon. Thanks!
This site has done it: https://www.businessreport.com/business/entrepreneur-cameron-jackson they aren’t using woocommerce I don’t believe, but that is the end result.
Is there a way to specify a template, like per tag or something?
Thanks I will take a look at that.
Hmm…Interesting, so I would have to change the default page for my entire site?
The same issue, I am trying to remove the sidebar on the Shop page. I tried to use CPT and looked for it in the Theme Panel CPT settings and no dice. I will code it out until a fix if you let me know where to edit?
Also, anyone else had an issue where you can’t see “View Cart”? Maybe start a new thread for that.
I believe this issue is related to too many TAGS which I have 3,200 and need to clean, as I got them through an import from the previous system.
That did it, now I just wish I had a button to enable or disable CPT. Will have to remember to apply this fix to the next update.