View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0017415||mantisbt||db schema||public||2014-06-05 02:41||2017-08-15 03:58|
|Priority||normal||Severity||minor||Reproducibility||have not tried|
|Summary||0017415: Token type as string rather than int|
Tokens can be a useful tool for plugins. It allow savings tokens into the database that persist or expire over time. Does it make sense to open this up for plugins?
If so, then we should move away from using some constants integer as the key and using a string instead. Hence, the token name can be plugin_xyz_token rather than 700 with the hope that no one else is using such number.
We trick here is to figure out when a token is the right solution vs. a new table. I guess the same applies ever for our own usage. Some advantages of tokens:
Token Table Structure:
$upgrade[ 42] = array('CreateTableSQL',array(db_get_table('tokens'),"