diff options
author | Naglfar <naglfar@tilde.institute> | 2021-01-10 20:33:00 +0100 |
---|---|---|
committer | Naglfar <naglfar@tilde.institute> | 2021-01-10 20:33:00 +0100 |
commit | 4bf22916122e11046cf77a7dfc8868802c0ffb28 (patch) | |
tree | a679622a737225372a44610f6ab8840eb3babe23 | |
parent | edcfa69dd6a0b240dc92be021c201e49c3d456b7 (diff) | |
download | MightyWVMS-4bf22916122e11046cf77a7dfc8868802c0ffb28.tar.gz |
Rename variable mdata to wsdata
-rw-r--r-- | divs/footer.php | 2 | ||||
-rw-r--r-- | divs/sidebar.php | 4 | ||||
-rw-r--r-- | index.php | 6 | ||||
-rw-r--r-- | php/rd-procedures.php | 6 | ||||
-rw-r--r-- | php/wd-procedures.php | 4 | ||||
-rw-r--r-- | php/ws-procedures.php | 6 | ||||
-rw-r--r-- | theme/mwvms.php | 4 |
7 files changed, 16 insertions, 16 deletions
diff --git a/divs/footer.php b/divs/footer.php index 5781afd..e8bbc20 100644 --- a/divs/footer.php +++ b/divs/footer.php @@ -1 +1 @@ -<?php printf("<a href='%s'>%s</a>\n", $mdata[5], $mdata[6]) ?> +<?php printf("<a href='%s'>%s</a>\n", $wsdata[5], $wsdata[6]) ?> diff --git a/divs/sidebar.php b/divs/sidebar.php index c8c4d61..9a32ce0 100644 --- a/divs/sidebar.php +++ b/divs/sidebar.php @@ -1,9 +1,9 @@ <div id="sidebar-related">Related videos</div> <?php -for($i=0; $i < $mdata[2]; $i++) +for($i=0; $i < $wsdata[2]; $i++) if($i != $vid) { - $rdata = file($dpath.$mdata[3].'/'.$i, FILE_IGNORE_NEW_LINES); + $rdata = file($dpath.$wsdata[3].'/'.$i, FILE_IGNORE_NEW_LINES); printf("<div class='sidebar-thumb'><img alt='' src='thumbnails/%s.png'/></div>\n", $vindex[$i]); printf("<div class='sidebar-data'>\n"); diff --git a/index.php b/index.php index 5be503c..91a70b4 100644 --- a/index.php +++ b/index.php @@ -6,10 +6,10 @@ require 'php/rd-procedures.php'; #video management (Read data) require 'php/wd-procedures.php'; #video management (Write/update data) ?> <!DOCTYPE html> -<html lang="<?php echo $mdata[3] ?>"> +<html lang="<?php echo $wsdata[3] ?>"> <head> - <title><?php printf("%s - %s", $vdata[2], $mdata[0]) ?></title> - <meta name="description" content="<?php echo $mdata[4] ?>" /> + <title><?php printf("%s - %s", $vdata[2], $wsdata[0]) ?></title> + <meta name="description" content="<?php echo $wsdata[4] ?>" /> <meta name="viewport" content="width=device-width,initial-scale=1.0"> <link rel="stylesheet" type="text/css" href="/theme/body-wrapper.css"/> </head> diff --git a/php/rd-procedures.php b/php/rd-procedures.php index 27fd11e..c4b40ac 100644 --- a/php/rd-procedures.php +++ b/php/rd-procedures.php @@ -1,5 +1,5 @@ <?php -$vindex = file($dpath.$mdata[3].'/'.$toc, FILE_IGNORE_NEW_LINES); +$vindex = file($dpath.$wsdata[3].'/'.$toc, FILE_IGNORE_NEW_LINES); /* 1 parse the URL */ $vdata = explode('/', $_SERVER['REQUEST_URI']); @@ -10,6 +10,6 @@ if(!empty($vdata[1])) if($vdata[1] == $value) $vid = $i; -$vdata = file($dpath.$mdata[3].'/'.$vid, FILE_IGNORE_NEW_LINES); -$cindex = file($dpath.$mdata[3].'/'.$channel, FILE_IGNORE_NEW_LINES); +$vdata = file($dpath.$wsdata[3].'/'.$vid, FILE_IGNORE_NEW_LINES); +$cindex = file($dpath.$wsdata[3].'/'.$channel, FILE_IGNORE_NEW_LINES); ?> diff --git a/php/wd-procedures.php b/php/wd-procedures.php index 1b8d02d..aa2c563 100644 --- a/php/wd-procedures.php +++ b/php/wd-procedures.php @@ -1,7 +1,7 @@ <?php $vdata[0]+=1; -file_put_contents($dpath.$mdata[3].'/'.$vid, implode(PHP_EOL, $vdata)); +file_put_contents($dpath.$wsdata[3].'/'.$vid, implode(PHP_EOL, $vdata)); $vdata[1] = date('M j, Y', $vdata[1]); -$vdata[] = file_get_contents($dpath.$mdata[3].'/'.$cpath.$vid); +$vdata[] = file_get_contents($dpath.$wsdata[3].'/'.$cpath.$vid); ?> diff --git a/php/ws-procedures.php b/php/ws-procedures.php index 5dc685a..d1536e7 100644 --- a/php/ws-procedures.php +++ b/php/ws-procedures.php @@ -1,10 +1,10 @@ <?php //read the file and create array separate by new line -$mdata = file($dpath.'/'.$common, FILE_IGNORE_NEW_LINES); +$wsdata = file($dpath.'/'.$common, FILE_IGNORE_NEW_LINES); # Language overwritten by the browser preference if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) - $mdata[3] = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0,2); + $wsdata[3] = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0,2); -$mdata = array_merge($mdata, file($dpath.$mdata[3].'/'.$common, FILE_IGNORE_NEW_LINES)); +$wsdata = array_merge($wsdata, file($dpath.$wsdata[3].'/'.$common, FILE_IGNORE_NEW_LINES)); ?> diff --git a/theme/mwvms.php b/theme/mwvms.php index 430fa37..a61064f 100644 --- a/theme/mwvms.php +++ b/theme/mwvms.php @@ -1,6 +1,6 @@ <?php require '../php/definitions.php'; # Variables and constants definition -$mdata = file('../'.$dpath.'/'.$common, FILE_IGNORE_NEW_LINES); +$wsdata = file('../'.$dpath.'/'.$common, FILE_IGNORE_NEW_LINES); $fontsize = 25; $angle = 0; @@ -13,7 +13,7 @@ $im = imagecreate(266, 66); $background = imagecolorallocate($im, 0, 0, 0); $text_color = imagecolorallocate($im, 255, 255, 255); // Add the text -imagettftext($im, $fontsize, $angle, $x, $y, $text_color, $mdata[1], $mdata[0]); +imagettftext($im, $fontsize, $angle, $x, $y, $text_color, $wsdata[1], $wsdata[0]); // Set the content-type header('Content-Type: image/png'); |