X-Git-Url: https://git.harvie.cz/?a=blobdiff_plain;f=index.php;h=a019ae4b8b388520f6d28554e9323669037166dd;hb=ec106ddfe653ea6da6d65d537d38f19a9a7776e7;hp=9fd0527effb05db1e1f4aeae4801a8ad4ea58b60;hpb=326a9fc904b2a1e303abd2e3bc5b521603579be8;p=mirrors%2FSokoMan.git
diff --git a/index.php b/index.php
index 9fd0527..a019ae4 100755
--- a/index.php
+++ b/index.php
@@ -23,6 +23,7 @@ set_include_path(DIR_LIB.PATH_SEPARATOR.get_include_path());
require_once('Sklad_LMS-fake.class.php');
require_once('HTTP_Auth.class.php');
require_once('Locale.class.php');
+require_once('Barcode.class.php');
/**
* Trida poskytuje vseobecne funkce pro generovani HTML kodu
@@ -57,17 +58,19 @@ class HTML {
return $html;
}
- function link($title='n/a', $link='#void', $internal=true) {
- if($internal) $link = $this->internal_url($link);
- return "".T($title)."";
+ function link($title='n/a', $link='#void', $internal=true, $translate=true) {
+ if($internal && (!isset($link[0]) || $link[0] != '#')) $link = $this->internal_url($link);
+ if($translate) $title = T($title);
+ return "".$title."";
}
- function img($src='#void', $title='img') {
- return "";
+ function img($src='#void', $title='img', $options='width=64') {
+ $options = $options ? " $options" : '';
+ return "
";
}
- function input($name=false, $value=false, $type='text', $placeholder=false, $options=false) {
- $html = "";
+ foreach($inputs as $input) $html .= call_user_func_array(array($this,'input'), $input);
+ $html .= "";
+ return $html;
+ }
+
function select($name, $selectbox, $default=false) {
//echo('
'); print_r($selectbox); $html = ""; return $html; } + + function ul($items,$tag=ul,$head='',$class=false) { + $class = $class ? " class='$class'" : ''; + $html = "$head<$tag$class>"; + foreach($items as $key => $value) { + $html .= '