bsf_generate_rand_token()

Generate 32 characters random token.


Description


Return

(string)


Source

File: admin/bsf-core/auto-update/admin-functions.php

	function bsf_generate_rand_token() {
		$valid_characters = 'abcdefghijklmnopqrstuvwxyz0123456789';
		$token            = '';
		$length           = 32;
		for ( $n = 1; $n < $length; $n++ ) {
			$which_character = wp_rand( 0, strlen( $valid_characters ) - 1 );
			$token          .= $valid_characters[ $which_character ];
		}
		return $token;
	}


User Contributed Notes

You must log in before being able to contribute a note or feedback.