Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the pue-sales domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the better-click-to-tweet domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the pue-amazon domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the pue-stats domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the wordpress-seo domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114
Ticket Numbers | Event Espresso - Staging Server

Support

Home Forums Event Espresso Premium Ticket Numbers

Ticket Numbers

Posted: January 17, 2014 at 11:54 am

Viewing 6 reply threads


Fred Sessoms

January 17, 2014 at 11:54 am

Can the UID number be replaced with our own 5 digit number, either randomly generated or serialized? If so, how? Thank you.


Dean

  • Support Staff

January 20, 2014 at 1:16 am

Hi Fred,

I assume you mean the Registration ID for each attendee? If so check out this thread – http://staging.eventespresso.com/topic/custom-registration-id/


Fred Sessoms

January 26, 2014 at 2:02 pm

This solution is not working for me. In fact, it is creating error messages; “An Error Occurred, No ID”. Perhaps I am doing something wrong. All I want is a five digit random ticket number rather than what is generated by EE. I have added the blocks of code to functions.php as suggested here: http://staging.eventespresso.com/topic/custom-registration-id/ and this is where the problems began – error messages. Can someone please give better instructions? Thank you.


Sidney Harrell

  • Support Staff

January 27, 2014 at 9:43 am

Try this code:

add_filter('filter_hook_espresso_registration_id', 'my_custom_registration_id', 10, 1);

function my_custom_registration_id(){
	$id = uniqid();
        // for the sake of an example, we'll convert the unique ID to be letters from the alphabet, which would make for something similar to an airline's reservation code
	return substr(strtr($id, 'abcdefghi', '01234567890j'), 0, 5);
}

// remove default registration id filter
function my_remove_registration_id_filter() {
	remove_filter('filter_hook_espresso_registration_id', 'espresso_build_registration_id', 10);
}
add_filter ('filter_hook_espresso_registration_id', 'my_remove_registration_id_filter', 9 );

Try adding this code to this blank plugin to hold the custom functions.


Fred Sessoms

January 27, 2014 at 9:50 am

Thank you, Sidney. I will try and let you know.


Fred Sessoms

January 27, 2014 at 2:34 pm

Perfect, Sidney! Works like a charm. Thank you very much.


Sidney Harrell

  • Support Staff

January 27, 2014 at 5:26 pm

Glad to help. :)

Viewing 6 reply threads

The support post ‘Ticket Numbers’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso - Staging Server