Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1210353
    launchcatapult
    Participant

    Hi there. I am running some code to hide some old reviews that were imported from a very old site. You can see an example page here:
    Trilogy PDL3000

    My code to hide these old reviews is the following:

    //Remove All Old product Review dates by their datetime and hide 0 star reviews
    .x-comment-time > time[datetime="2015-01-01t12:00:00+00:00"],
    .x-comment-time > time[datetime="2008-01-21t18:42:25+00:00"],
    .x-comment-time > time[datetime="2015-01-01t00:00:01+00:00"],
    .x-comment-time > time[datetime="2016-07-06t15:32:25+00:00"],
    .star-rating[title="Rated 0 out of 5"]{
    	display: none !important;
    }
    

    This worked perfectly until the latest X Theme update. It looks like there is a missing ” in the itemprop attribute of the item element.

    There is also an extra, un-needed space after datetime =”

    These are causing my CSS to no longer target the elements they originally did before the update.

    The code is currently:
    <time itemprop="datePublished datetime=" 2015-01-01t12:00:00+00:00"="">January 1, 2015 at 12:00 PM</time>

    It should be:
    <time itemprop="datePublished" datetime="2015-01-01t12:00:00+00:00"="">January 1, 2015 at 12:00 PM</time>

    Also see attached screenshot.

    Any help is much appreciated…or even a hotfix would be awesome!

    #1210888
    Rupok
    Member

    Hi there,

    If there is space on the HTML, let’s try adding the space in CSS as well. However I am not entirely sure what you are trying to hide. Do you want to hide the date and time for specific review?

    Thanks!

    #1212139
    launchcatapult
    Participant

    Thanks for getting in touch. I am trying to hide all legacy review dates and times from their old site. They aren’t playing nice with the WP database as the old site reviews were Non-Wordpress. New reviews we want to display, but when we launched the new site, all reviews were set to the same date…which we do not want to display.

    As I said…this worked for months and months perfectly until I updated X.

    I tried adding a space. No dice. As I said…the issue seems to be improper syntax. There is a missing “.

    #1212527
    Rupok
    Member

    Hi there,

    If those have any issue with database then you should delete them from database instead of hiding with CSS becuae hiding won’t make any difference in database.

    Thanks!

    #1213323
    launchcatapult
    Participant

    The issue is not in the database. It is with X Theme. The CSS worked to hide the date times specified perfectly for over 6 months and when the X Update happened last week, the code stopped working. Please look for yourself and inspect the code. The syntax is wrong and I have not modified it in the tabs.php file…it is default X. I don’t know how many ways I can say it. There is a missing quote mark.

    Look at how many licenses we have with X. We use it for all of our clients. We know how to use it and I know how to identify improper syntax when I see it. If you will not look into this issue seriously then I will take to the X theme user group pages until someone who is higher up sees this ticket.

    #1213326
    launchcatapult
    Participant

    I literally spelled it out for you earlier in the ticket.

    The code is currently this as loaded by default X:
    <time itemprop="datePublished datetime=" 2015-01-01t12:00:00+00:00">January 1, 2015 at 12:00 PM</time>

    It should be:
    <time itemprop="datePublished" datetime="2015-01-01t12:00:00+00:00">January 1, 2015 at 12:00 PM</time>

    #1213360
    launchcatapult
    Participant

    Hey no worries…I found your error for you:

    x -> framework – > functions.php -> integrity.php -> line 193:

    printf( '<div><a href="%1$s" class="x-comment-time"><time itemprop="datePublished datetime="%2$s">%3$s</time></a></div>'

    Changed to:

    printf( '<div><a href="%1$s" class="x-comment-time"><time itemprop="datePublished" datetime="%2$s">%3$s</time></a></div>'

    Now my code works again. Please submit this update to core X theme. I do not want to have to change this next time we update.

    #1213988
    Rue Nel
    Moderator

    Hello There,

    We are just glad that you have figured it out a way to correct the said issue. Thanks for letting us know!
    Meanwhile, we already reported this typo error to our developers. It will be fix and updated soon.

    Best Regards.

  • <script> jQuery(function($){ $("#no-reply-1210353 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>