The effects of alcohol on
sustanon 250 leucine for – real weight loss & bodybuilding benefits?
[Solved] verified owner code for wpdiscuz
✦ Summarize Topic
✦
✦
✦
AI is analyzing the discussion...
How-to and Troubleshooting
Topic starter
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
Mar 22, 2021 9:06 am
(@saeed-khoramdel)
Active Member
Joined: 5 years ago
Hi
in my default woocommerce comment form when a user buy a product he became a verified owner
and when he writes his review he has this label { verified owner } beside of his name on comment form after sharing
but in wpdiscuz form there is not this label for people who bought proudcts
i have a code for this and my website is RTL
please give me a code base on RTL
THANKS
Topic starter
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
Mar 22, 2021 9:14 am
(@saeed-khoramdel)
Active Member
Joined: 5 years ago
(@asti)
Joined: 8 years ago
Illustrious Member
Posts: 8225
Mar 22, 2021 1:50 pm
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
@saeed-khoramdel,
You can do the customization using the wpdiscuz_comment_author hook.
(@saeed-khoramdel)
Joined: 5 years ago
Active Member
Posts: 10
Mar 24, 2021 10:28 am
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
@asti
hi asti
Forgive me i wrote wrong in up there becuse my english is not very good i wrote i have a code and this is wrong i have not any code I wanted to write i want a code and mistakenly i wrote i have a code
and i dont know anything from code and ...
please give me a code wich show the label of verified owner after that a person buy a product on product page of woocommerce
and please guide me step by step i do not know what i must do with wpdiscuz_comment_author hook.
(@asti)
Joined: 8 years ago
Illustrious Member
Posts: 8225
Mar 24, 2021 1:56 pm
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
@saeed-khoramdel,
Use this code:
add_filter("wpdiscuz_comment_author", function ($name, $comment) {
if (wc_review_is_from_verified_owner($comment->comment_ID)) {
$name .= " <em class='woocommerce-review__verified verified'>(" . esc_attr__("verified owner", "woocommerce") . ")</em>";
}
return $name;
}, 10, 2);
You should put the code in the active theme functions.php file.
(@saeed-khoramdel)
Joined: 5 years ago
Active Member
Posts: 10
Mar 24, 2021 5:07 pm
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
@asti
thanks it works but has some problems
when a Customer write his comment the code work correctly and for example show this name : mike {verified owner} but when some one like jim replys to mike this code does not work good and shows the name of mike like this :
jim reply to :
language of my website is persian and i show you picture of that for better understanding
please solve this
(@asti)
Joined: 8 years ago
Illustrious Member
Posts: 8225
Mar 25, 2021 12:58 pm
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
@saeed-khoramdel,
jim reply to :
mike <em class='woocommerce-review__verified verified'>(verified owner)</em>
We may suggest you hide the “reply to” section using CSS code.
(@saeed-khoramdel)
Joined: 5 years ago
Active Member
Posts: 10
Mar 26, 2021 9:35 am
Translate
▼
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
Show original
Translating...
@asti
thanks asti for helping me to solve this
this is css code for hiding “reply to” if someone wants to use it
.wpd-reply-to{
display:none;
}