AI Search
Classic Search
 Search Phrase:
 Search Type:
Advanced search options
 Search in Forums:
 Search in date period:

 Sort Search Results by:

AI Assistant
Notifications
Clear all

[Solved] Cache hook development questions

6 Posts
2 Users
3 Reactions
4,144 Views
Posts: 3
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
(@litespeeddev)
Active Member
Joined: 9 years ago
[#4227]

Hi WPFORO,

I am from LiteSpeed cache. When I develop the WPForo third party plugin to make WPForo work better with LiteSpeed WordPress cache plugin , I got a question. If anyone can tell it will be great appreciated.

1. Is there any particular reason that WPForo don't have a `wpforo_after_edit_topic` action hook? Looks like this is the only one that is missing in your topic&post operation hooks.

2. WPForo called `wpforo_clean_cache()` in all operations. That is a good job. However, there is no hook in that function. That means, it's hard to do our magic there.

3. Also in function `wpforo_clean_cache()`, it informs WP to only clear the main forum homepage page cache. While full page cache plugins will cache the forum and topic and post too, if it can provide all affected pages with their ids, it will be great. e.g. when add a post, the ideal data is `related topic id`, `related forum id`, `related parent forums & category id (in breadcrumb)`.

After we finish developing the compatibility to make WPForo work better with our cache plugin, we will add it to our supported plugin list.

BTW, WPForo is a excellent plugin. You guys did a good job. It has a well organized program files and nice programming styling, and one of the most important point is, a good data structure.


5 Replies
Robert
Posts: 10753
Admin
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
(@robert)
Support Team
Joined: 3 months ago

Thank you litespeed

Please find my answers below:

1. Is there any particular reason that WPForo don't have a `wpforo_after_edit_topic` action hook? Looks like this is the only one that is missing in your topic&post operation hooks.

We'll add this in next 1.2.1 release.

2. WPForo called `wpforo_clean_cache()` in all operations. That is a good job. However, there is no hook in that function. That means, it's hard to do our magic there.

This function is not complete, it's under development. Please wait for the next release, we're improving it...

3. Also in function `wpforo_clean_cache()`, it informs WP to only clear the main forum homepage page cache. While full page cache plugins will cache the forum and topic and post too, if it can provide all affected pages with their ids, it will be great. e.g. when add a post, the ideal data is `related topic id`, `related forum id`, `related parent forums & category id (in breadcrumb)`.

Sure we'll add array variables of all major objects like forum, topic, post, user, etc...


Posts: 3
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
(@litespeeddev)
Active Member
Joined: 9 years ago

Can this topic be moved to Q&A Layout How-to and Troubleshooting ? Thanks. 


Robert
Posts: 10753
Admin
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
(@robert)
Support Team
Joined: 3 months ago

This topic doesn't have any relation to Q&A Layout How-to and Troubleshooting forum. Please read forum descriptions. Q&A Layout How-to and Troubleshooting forum is only for Q&A Forum Layout related issues and questions. Each layout has it's own forum. But the general How-to and Troubleshooting forum is this one.


Posts: 3
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
(@litespeeddev)
Active Member
Joined: 9 years ago

If possible, please add hooks to `post->status()` and `topic->status()` too. Currently when approve post, no cache purged.


Page 1 / 2
Share: