Skip to content

Instantly share code, notes, and snippets.

@phl0w
Created June 18, 2012 19:47
Show Gist options
  • Select an option

  • Save phl0w/2950321 to your computer and use it in GitHub Desktop.

Select an option

Save phl0w/2950321 to your computer and use it in GitHub Desktop.
<?php
include("../includes/functions.php");
$ver = getVersion("iTBarbFisher");
echo "version = ".$ver;
?>
function getVersion($script) {
$sql = mysql_query("SELECT * FROM `scripts` WHERE script = '".$script."'");
$rows = mysql_num_rows($sql);
while ($row = mysql_fetch_array($sql)) {
return $row['version'];
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment