marksie1988 Posted January 25, 2011 Share Posted January 25, 2011 Hi Guys, Sorry if this is the wrong forum but i wasnt sure the best one. i am trying to see how others control the version of apps they have written and updating. i want to set the version of my app e.g. 1.0 and then have a section where if i release 1.5 it will show up that a new version is available for upgrade. the only thing im not too sure about is when someone goes to upgrade if not all of the updated files are uploaded correctly i want it to say version missmatch. could someone give me examples of how i could achieve this? Quote Link to comment https://forums.phpfreaks.com/topic/225604-php-application-version-and-latest-update/ Share on other sites More sharing options...
codefossa Posted January 25, 2011 Share Posted January 25, 2011 You could use a version file and have the update check an sql database for the value you've entered, and if the database has a higher number than the version file, you alert for update. Also, if it would be used on a foreign server, you could just use a version file on your own server and get the contents of it showing the # and compare that way. Very simple. Quote Link to comment https://forums.phpfreaks.com/topic/225604-php-application-version-and-latest-update/#findComment-1164913 Share on other sites More sharing options...
marksie1988 Posted January 25, 2011 Author Share Posted January 25, 2011 You could use a version file and have the update check an sql database for the value you've entered, and if the database has a higher number than the version file, you alert for update. Also, if it would be used on a foreign server, you could just use a version file on your own server and get the contents of it showing the # and compare that way. Very simple. Ok that makes sense, but how would i ensure that each file was the latest version? Would you sugest that i have a DB with each version of each file and if this all matches then they are on the latest version (this would save changing the version in files that havent been changed) then i could have a line in the table for the main version and if the main version changes they must do a full update :S Quote Link to comment https://forums.phpfreaks.com/topic/225604-php-application-version-and-latest-update/#findComment-1164920 Share on other sites More sharing options...
ignace Posted January 25, 2011 Share Posted January 25, 2011 i want to set the version of my app e.g. 1.0 and then have a section where if i release 1.5 it will show up that a new version is available for upgrade. Have a file on your server that holds the latest version info (eg version.txt) If you only have a version number (eg 1.5.1b) then a text-file should suffice otherwise if you have more information that needs to be checked (eg modules compatibility, ..) then I would opt for a XML-file. Patching would be done through either packages or live patches from your source-control system. Quote Link to comment https://forums.phpfreaks.com/topic/225604-php-application-version-and-latest-update/#findComment-1164961 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.