PHP Sessions not transferring to next page?

There are multiple reasons why sessions are not transferring to next page but the most important thing is to check the urls of sender and receiver pages For example if you are sending session from non secure url to a secure url this will not work

Rename a file if same already exists

While uploading a file you may want to check if a file already exists in target directory then create a new file instead of replacing and rename new file with an incremental no. Example some_dir/some_file.png already exists, and you try to upload a file with name some_file.png again, so it should be uploaded as some_dir/some_file1.png […]

Delete files and folders recursively using PHP

unlinkr function recursively deletes all the folders and files in given path by making sure it doesn’t delete the script itself. if you want to delete all files and folders where you place this script then call it as following if you want to just delete the php files then call it as following you […]