• Resolved FIT

    (@futureit)


    Hi There,

    Finding the automatically generated giftcard number to to unnecessarily long (e.g. B746-VQ3Q-BTH4-BDVW)! Is there a way we can change this so it is shorter?

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author pimwick

    (@pimwick)

    The auto-generated numbers are random for security purposes to keep people from guessing the numbers. Also, when an invalid gift card number is entered into the site, there is a “tar pit” of 5 seconds. This makes it nearly impossible for someone to brute-force guess a gift card number.

    The auto-generated codes are 4 sets of 4 characters. If necessary, you can tweak the auto-generated gift card codes by following these steps:

    1. Download the wp-config.php from your FTP server.
    2. Keep a backup of wp-config.php in case there are problems.
    3. Edit wp-config.php and scroll to the end and add the following bit of code:

    Scroll towards the bottom, and before the line that says “Happy blogging.” add this code ABOVE that line (translate as needed):

    define( 'PWGC_RANDOM_CARD_NUMBER_SECTIONS', '4' );
    define( 'PWGC_RANDOM_CARD_NUMBER_SECTION_LENGTH', '4' );
    
    /* That's all, stop editing! Happy blogging. */

    4. Change the values for the settings as you see fit. We default to 4 sections that are 4 characters each.
    5. Save the wp-config.php file and re-upload it to your server.

    If you have any problems, replace wp-config.php with your backup file.

    Let me know if you have any questions!

    Thread Starter FIT

    (@futureit)

    Thanks for the detailed response! I’ve added the code in and will test and see how it goes ??

    Plugin Author pimwick

    (@pimwick)

    I’m marking this thread as resolved since we haven’t heard back in a while. Let us know if you need anything else.

    Thread Starter FIT

    (@futureit)

    It did work! Thank you ??

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Change Gift Card Number Sequence’ is closed to new replies.