Previously we were getting 9/27/2023|4:02 AM|Wednesday this format, Now with the 6.2 version the output is year=2023 | month=September | date=27 | day=Wednesday | time=11:35 PM.
I tired different things but unable to get month in numeric format.
any tips?
Also explain a = /([a-zA-Z]+).*?([a-zA-Z]+).*?([0-9]+).*?([0-9]+)(.*?)([0-9])(.*)/.exec(a);
Solved! Go to Solution.
Views
Replies
Total Likes
Looks like the plug-in did away with your old format since its version 4.0 update in August 2016. To get back your desired value, you'll need to use some custom code to convert the plug-in's returned values to what you want.
Something like this:
// use this inside your AA extension's custom code's doPlugins section
const monthNames = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'];
const timePartingString = s.getTimeParting();
const timePartingParts = timePartingString.split('|').map((value) => value.split('=')[1].trim());
const [timePartingYear, timePartingMonth, timePartingDay, timePartingDayOfWeek, timePartingTime] = timePartingParts;
s.eVarXX = `${monthNames.indexOf(timePartingMonth) + 1}/${timePartingDay}/${timePartingYear}|${timePartingTime}|${timePartingDayOfWeek}`;
Please test this code properly before publishing it to live!
Looks like the plug-in did away with your old format since its version 4.0 update in August 2016. To get back your desired value, you'll need to use some custom code to convert the plug-in's returned values to what you want.
Something like this:
// use this inside your AA extension's custom code's doPlugins section
const monthNames = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'];
const timePartingString = s.getTimeParting();
const timePartingParts = timePartingString.split('|').map((value) => value.split('=')[1].trim());
const [timePartingYear, timePartingMonth, timePartingDay, timePartingDayOfWeek, timePartingTime] = timePartingParts;
s.eVarXX = `${monthNames.indexOf(timePartingMonth) + 1}/${timePartingDay}/${timePartingYear}|${timePartingTime}|${timePartingDayOfWeek}`;
Please test this code properly before publishing it to live!
Thank you, It worked with few changes.
Views
Replies
Total Likes
Views
Likes
Replies