Forum Replies Created

Viewing 15 replies - 16 through 30 (of 47 total)
  • Thread Starter jonathangallo

    (@jonathangallo)

    Thank you for the fast reply!

    First, when I click on the Convert button, it opens a new tab to my website and adds the following to the URL: “post_grid/819/?post_grid_layout_convert=true&_wpnonce=6a576a98bb” so it opens the post grid into a new tab. When I click on “Edit” (as in first image) it sends me to the layout editor page in the second imgur link but I still cannot see “Star Rating” section as in your image to add it.

    Thread Starter jonathangallo

    (@jonathangallo)

    Hi,

    I’m using Site Reviews Plugin and I am using a custom preview form (PHP-file). The recommendation is to create a folder in my theme called “site-reviews” where I put a copy of this file from the plugin, instead of changing the current plugin file. But every time you update the theme, the folder is removed and I have to put it back every time.

    Thread Starter jonathangallo

    (@jonathangallo)

    Hi. It works now, thank you!

    Thread Starter jonathangallo

    (@jonathangallo)

    Thank you for quick feedback, pagination is working now!

    Thread Starter jonathangallo

    (@jonathangallo)

    Hi again,
    Did you try this with Site Reviews plugin and _glsr_ranking field to ensure it is working with two different languages?

    Thread Starter jonathangallo

    (@jonathangallo)

    I am using Code Snippets where I have a lot of code already to modify site reviews. That’s why I wondered if I you can help me provide a code to display my custom field from here as well, which right now is a modification in the review.php.

    Because even if I have a child theme (Webstrap), it still doesn’t work for two reasons:
    1. When I use the guide “How do I change the order of the review fields?”, it doesn’t display my custom field
    2. The template folder (from the guide in FAQ) is removed when the theme updates

    Thread Starter jonathangallo

    (@jonathangallo)

    Thank you, I will definitely try this! I just noticed that Webstrap is a child theme from Specia. Strangely, all my changes disappeared when it was updated last time.

    So when I have my child theme, can I copy and modify SiteReviewsSummary.php as well, like review.php based on the steps from “How do I change the order of the review fields?”

    Edit: Now I got it with Loco Translate, didn’t think about that I actually had the English translation file there. So only one thing left, which is to display my custom field in recent reviews. Is it even possible to solve this by adding code in my snippets? So I don’t have to create a child theme.

    • This reply was modified 6 years, 7 months ago by jonathangallo.
    Thread Starter jonathangallo

    (@jonathangallo)

    Thanks for the guides. I’ll guess I have to read more about child themes and how it works with my current theme (Webstrap).

    So I finally found the other thing I customized directly in site reviews plugin files: site-reviews > plugin > Modules > Html > Partials > SiteReviewsSummary.php, where I check the current language to shorten and translate the ‘{rating} out of {max} stars (based on {num} review)’ to ‘{num} review’ (and in Swedish). If I translate this in Site Reviews settings first, it doesn’t work when I translate it to Swedish in Loco Translate, that’s why I did it this way.

    So do you think that I somehow can keep these two modifications (review.php and SiteReviewsSummary.php) by adding/replacing some sort of code in my Snippets instead? In that case, I don’t have to create a child theme (don’t know if it’s even possible with Webstrap). These two things are the last I need to go Live with my website.

    Thread Starter jonathangallo

    (@jonathangallo)

    Thank you!
    I just have a follow-up question regarding these custom snippets. At first, I added the most snippets in my themes functions.php. But when the theme had an update, all custom code disappeared in functions.php. So now I’m using Snippets plugin to do the most. But the only thing I have left is my custom field to show in the recent reviews. I followed the section “How do I change the order of the review fields?” in the FAQ but it still didn’t show up. So now, I customized the review.php directly in the Site Reviews Plugin and it works. But will this disappear as well if you launch a new update? If so, either way it will disappear if I use it in the theme folder or directly in the site reviews file?

    Thread Starter jonathangallo

    (@jonathangallo)

    Worked perfectly, thank you!

    Thread Starter jonathangallo

    (@jonathangallo)

    I already have that option enabled since the installation of Site Reviews, but it only applies to the Latest Reviews widget right? In this case, I am using [site_reviews_summary] which displays 0 (0 out of 5 stars) for pages that don’t have any reviews. Or do you mean that I can add a fallback text parameter to shortcode I am using?

    Thread Starter jonathangallo

    (@jonathangallo)

    Thank you, but that would even apply on the pages that actually have reviews right? Just to be clear, I’m not talking about the page according to this thread, this is a new page with A-Z register, where I want to show the reviews if there are any. And if there aren’t any reviews, it should display “No reviews yet” or just leave it blank. That’s why I asked if you somehow can modify the last code snippet.

    Thread Starter jonathangallo

    (@jonathangallo)

    Thank you for your reply. Did you test it with site reviews and the _glsr_ranking and meta value number? So let’s say I have one page on Swedish (ID 1) and one in English (ID 2), when I submit a review to page ID 2, it only shows up when the site is in English. Same thing happens if I wubmit a review to page ID 1, it only shows up when the site is in Swedish.

    Thread Starter jonathangallo

    (@jonathangallo)

    Just another question, I have a page where I list all pages and I’m trying to modify this snippet

    /**
     * Inserts the Site Reviews summary in Post Grid when using the rating widget field
     * @param string $translation
     * @param string $text
     * @param string $domain
     * @return string
     */
    add_filter('gettext', function ($translation, $text, $domain) {
        if ('post-grid' == $domain && 'Please activate Rating widget Plugin' == $text) {
            $translation = do_shortcode('[site_reviews_summary assigned_to=post_id hide=bars,summary]');
        }
        return $translation;
    }, 10, 3);

    to only show the ratings if there are any, without luck. What lines should I modify? It would also be nice to show ”no reviews yet” for those pages without any reviews

    Thread Starter jonathangallo

    (@jonathangallo)

    How sad that one thing should prevent this fantastic function 🙁 Do you think using php code can include both languages of the pages when you try to fetch them? So basically when a page has at least one review in each language, it will show upp in post grid, and then it’s the order that shows wrong i each language page.

Viewing 15 replies - 16 through 30 (of 47 total)