deth4uall Posted January 16, 2010 Share Posted January 16, 2010 Ok, I have been working on a game and I am wanting to create a revision system for development and patching to new versions... My game uses a revision like v1.3.4 as you will see if you visit the site, and my testing server uses v1.3.5.x due to it being one revision ahead and having subrevisions based on how far along I get... I want to create a script that updates the server with the SQL queries placed in a file based on the current version. So on testing server it will update the database ONLY for SQL newer than v1.3.5.2 if the next version I uploaded is 1.3.5.3... So far I made the version numbers broken down into arrays but I got stuck there... $version = str_replace("v","",$this->version); $version_array = explode(".",$version); include ("ubo.updates.php"); $versionup = str_replace("v","",$version); $versionup_array = explode(".",$version); if (sizeof($version_array) > 3) { $tot = $version_array['0']; $major = $version_array['1']; $minor = $version_array['2']; $rev = $version_array['3']; } This previous code goes into the user.class.php & the next code is what I have for ubo.updates.php: <?php //Change The Below Number As You Upload the system $version = "1.3.5"; $sqlupdate['1']['3']['5']['1'] = ""; ?> Any help is appreciated and even pointers and hints will help... Link to comment https://forums.phpfreaks.com/topic/188729-version-updating/ Share on other sites More sharing options...
trq Posted January 17, 2010 Share Posted January 17, 2010 What is the problem exactly? Link to comment https://forums.phpfreaks.com/topic/188729-version-updating/#findComment-996335 Share on other sites More sharing options...
deth4uall Posted January 27, 2010 Author Share Posted January 27, 2010 Lack of experience for creating a self updating system that would allow me to update the database when I upload files just by running a simple check... Link to comment https://forums.phpfreaks.com/topic/188729-version-updating/#findComment-1002217 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.