This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import re | |
import shutil | |
# Change absolute path to location where backups are stored | |
path = "ADD YOUR PATH" | |
if not path.endswith("/"): | |
path += "/" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Add this code to functions.php - this code changes lenght of coupons generated | |
//only by customer.generate_coupon variable in AutomateWoo | |
add_filter( 'automatewoo/coupon_generator/key_length', function(){ | |
return 3; //Change this number to any number you like | |
}); |