Closed. This question is off-topic. It is not currently accepting answers.admin管理员组文章数量:1130349
Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.
Closed 6 years ago.
Improve this questionI have a product page and I wish to change the prices twice in a day automatically. I want it to repeat forever. So I have 2 options : schedule the page or the products. But I couldn’t find any plugin to do it or code (a plugin is better for me).
I tried asking the wordpress forum but there was no answer.
Please help me. Thank you!
Closed. This question is off-topic. It is not currently accepting answers.Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.
Closed 6 years ago.
Improve this questionI have a product page and I wish to change the prices twice in a day automatically. I want it to repeat forever. So I have 2 options : schedule the page or the products. But I couldn’t find any plugin to do it or code (a plugin is better for me).
I tried asking the wordpress forum but there was no answer.
Please help me. Thank you!
Share Improve this question asked Jan 11, 2019 at 23:04 DoudouDoudou 11 Answer
Reset to default 2Take a look at this page https://codex.wordpress/Function_Reference/wp_update_post . There is an example of how to update the post.
All you need is the post ID that you want to update, and some code to change certain text in the post.You will want to get the post's data (an array), then change the $post_content array item with some sort of process that searches for the price string you want to change and then adjusts it.
Once that is changed, set the $post_content array item to the new text (with your price change), and store the result. The example in the link above should get you pointed in the right direction.
Once you have the PHP file that does the process correctly (test it a lot!), then add that to the CRON.
Closed. This question is off-topic. It is not currently accepting answers.Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.
Closed 6 years ago.
Improve this questionI have a product page and I wish to change the prices twice in a day automatically. I want it to repeat forever. So I have 2 options : schedule the page or the products. But I couldn’t find any plugin to do it or code (a plugin is better for me).
I tried asking the wordpress forum but there was no answer.
Please help me. Thank you!
Closed. This question is off-topic. It is not currently accepting answers.Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.
Closed 6 years ago.
Improve this questionI have a product page and I wish to change the prices twice in a day automatically. I want it to repeat forever. So I have 2 options : schedule the page or the products. But I couldn’t find any plugin to do it or code (a plugin is better for me).
I tried asking the wordpress forum but there was no answer.
Please help me. Thank you!
Share Improve this question asked Jan 11, 2019 at 23:04 DoudouDoudou 11 Answer
Reset to default 2Take a look at this page https://codex.wordpress/Function_Reference/wp_update_post . There is an example of how to update the post.
All you need is the post ID that you want to update, and some code to change certain text in the post.You will want to get the post's data (an array), then change the $post_content array item with some sort of process that searches for the price string you want to change and then adjusts it.
Once that is changed, set the $post_content array item to the new text (with your price change), and store the result. The example in the link above should get you pointed in the right direction.
Once you have the PHP file that does the process correctly (test it a lot!), then add that to the CRON.
本文标签: How do I make a page not visible at a certain time
版权声明:本文标题:How do I make a page not visible at a certain time? 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:https://it.en369.cn/questions/1749019412a2304149.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。


发表评论