Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function getLastIndex(){
- // query+get the last index value
- return lastIndex;
- }
- function updateLastIndex($id){
- //query+save $id
- }
- function indexFormula($id){
- return ($id*2)+5 //you can use a more complicated formula or whatever
- }
- function getNewLink(){
- $id = getLastIndex();
- $id = indexFormula($id);
- updateLastIndex($id);
- //you can use base64 or whatever here
- return $id;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement