About week calculation | WordPress.org

[ad_1]

Hello @klingbeil,

In this case, you must calculate the date directly through an equation.

For example, assuming that fieldname1 is a number field for entering the number of weeks. You can insert a calculated field in the form and enter the equation:

(function(){
var current_year = YEAR(TODAY()),
first_day_year="01/01/"+current_year,
days_interval = fieldname1*7;

return GETDATETIMESTRING(DATETIMESUM(first_day_year, 'dd/mm/yyyy', days_interval, 'd'), 'dd/mm/yyyy');
})()

Learn more about the date/time operations module by reading the following section in the plugin documentation:

https://cff.dwbooster.com/documentation#datetime-module

Best regards.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer