parent
26e9c89405
commit
db26ffa611
@ -0,0 +1,161 @@ |
||||
<?php |
||||
/***************************************************************************** |
||||
IP Reg, a PHP/MySQL IPAM tool |
||||
Copyright (C) 2007-2009 Wietse Warendorff (up to v0.5) |
||||
Copyright (C) 2011-2023 Thomas Hooge |
||||
|
||||
SPDX-License-Identifier: GPL-3.0-or-later |
||||
*****************************************************************************/ |
||||
|
||||
include("includes.php"); |
||||
|
||||
if ($_SESSION['suser_role_admin'] == 0) { |
||||
header_location('comments.php?comments=accessdenied'); |
||||
} |
||||
|
||||
if (isset($_REQUEST['id'])) { |
||||
$id = (int) $_REQUEST['id'] or $id = 0; |
||||
} |
||||
|
||||
$ctypes = array('copper' => 'Copper', 'fibre' => 'Fibre', |
||||
'laser' => 'Laserlink', 'radio' => 'Radiolink'); |
||||
|
||||
// ========== ACTIONS START =================================================== |
||||
|
||||
switch ($submit = form_get_action()) { |
||||
|
||||
case NULL: break; |
||||
|
||||
case 'add': $action = ACT_ADD; break; |
||||
case 'view': $action = ACT_VIEW; break; |
||||
case 'edit': $action = ACT_EDIT; break; |
||||
case 'del': $action = ACT_DELETE; break; |
||||
|
||||
case 'insert': |
||||
$description = sanitize($_POST['description']); |
||||
$color = sanitize($_POST['color']); |
||||
$info = sanitize($_POST['info']); |
||||
$sql = "INSERT INTO cable |
||||
(cable_description, cable_color, cable_info) |
||||
VALUES |
||||
(:description, :color, :info)"; |
||||
$sth = $dbh->prepare($sql); |
||||
$sth->bindValue(':description', $description, PDO::PARAM_STR); |
||||
$sth->bindValue(':color', $color, PDO::PARAM_STR); |
||||
$sth->bindValue(':info', $info, PDO::PARAM_STR); |
||||
$sth->execute(); |
||||
$id = $dbh->lastInsertId(); |
||||
$action = ACT_VIEW; |
||||
break; |
||||
|
||||
case 'update': |
||||
$description = sanitize($_POST['description']); |
||||
$color = sanitize($_POST['color']); |
||||
$length = sanitize($_POST['length']); |
||||
$type = sanitize($_POST['cable_type']); |
||||
$info = sanitize($_POST['info']); |
||||
$sql = "UPDATE cable |
||||
SET cable_description=:desc, |
||||
cable_color=:color, |
||||
cable_length=:length, |
||||
cable_type=:type, |
||||
cable_info=:info |
||||
WHERE cable_id=:id"; |
||||
$sth = $dbh->prepare($sql); |
||||
$sth->bindValue(':id', $id, PDO::PARAM_INT); |
||||
$sth->bindValue(':desc', $description, PDO::PARAM_STR); |
||||
$sth->bindValue(':length', $length, PDO::PARAM_INT); |
||||
$sth->bindValue(':color', $color, PDO::PARAM_STR); |
||||
$sth->bindValue(':type', $type, PDO::PARAM_STR); |
||||
$sth->bindValue(':info', $info, PDO::PARAM_STR); |
||||
$sth->execute(); |
||||
$action = ACT_VIEW; |
||||
break; |
||||
|
||||
case 'delete': |
||||
$sth = $dbh->prepare("DELETE FROM cable WHERE cable_id=?"); |
||||
$sth->execute([$id]); |
||||
$action = ACT_DEFAULT; |
||||
break; |
||||
|
||||
default: |
||||
$g_error->Add(submit_error($submit)); |
||||
$valid = FALSE; |
||||
} |
||||
|
||||
// ========== ACTIONS END ===================================================== |
||||
|
||||
$smarty->assign("scripts", 'jscolor.js'); |
||||
include("header.php"); |
||||
|
||||
// ========== PAGE CONTENT ==================================================== |
||||
|
||||
if ($action == ACT_DEFAULT): |
||||
// ========== VARIANT: default behavior ======================================= |
||||
|
||||
$sql = "SELECT cable_id AS id, cable_description AS description, |
||||
cable_from_id, cable_to_id, cable_length, cable_links, |
||||
cable_type, cable_color, |
||||
CONCAT(LEFT(cable_info, 60), IF(CHAR_LENGTH(cable_info)>60,'...','')) AS info |
||||
FROM cable |
||||
ORDER BY cable_description"; |
||||
$sth = $dbh->query($sql); |
||||
$smarty->assign("cables", $sth->fetchAll()); |
||||
|
||||
$smarty->display("cable.tpl"); |
||||
|
||||
elseif ($action == ACT_ADD): |
||||
// ========== VARIANT: add record ============================================= |
||||
|
||||
$smarty->assign('type_options', $ctypes); |
||||
$smarty->display('cableadd.tpl'); |
||||
|
||||
elseif ($action == ACT_VIEW): |
||||
// ========== VARIANT: view single record ===================================== |
||||
|
||||
$sql = "SELECT cable_id AS id, cable_description AS description, |
||||
cable_from_id, cable_to_id, cable_length, cable_links, |
||||
cable_type, cable_color AS color, cable_info AS info |
||||
FROM cable |
||||
WHERE cable_id=?"; |
||||
$sth = $dbh->prepare($sql); |
||||
$sth->execute([$id]); |
||||
$smarty->assign('cable', $sth->fetch(PDO::FETCH_OBJ)); |
||||
|
||||
$smarty->display('cableview.tpl'); |
||||
|
||||
elseif ($action == ACT_EDIT): |
||||
// ========== VARIANT: edit single record ===================================== |
||||
|
||||
$sql = "SELECT cable_id AS id, cable_description AS description, |
||||
cable_from_id, cable_to_id, cable_length, cable_links, |
||||
cable_type, cable_color AS color, cable_info AS info |
||||
FROM cable |
||||
WHERE cable_id=?"; |
||||
$sth = $dbh->prepare($sql); |
||||
$sth->execute([$id]); |
||||
$smarty->assign('cable', $sth->fetch(PDO::FETCH_OBJ)); |
||||
|
||||
$smarty->assign('type_options', $ctypes); |
||||
$smarty->display('cableedit.tpl'); |
||||
|
||||
elseif ($action == ACT_DELETE): |
||||
// ========== VARIANT: delete record ========================================== |
||||
|
||||
$sth = $dbh->prepare("SELECT cable_description FROM cable WHERE cable_id=?"); |
||||
$sth->execute([$id]); |
||||
$smarty->assign('id', $id); |
||||
$smarty->assign('description', $sth->fetchColumn()); |
||||
|
||||
$smarty->display('cabledel.tpl'); |
||||
|
||||
else: |
||||
// ========== UNBEKANNTE VARIANTE ============================================= |
||||
|
||||
echo "<p>Unknown function call: Please report to system development!</p>\n"; |
||||
|
||||
endif; // $action == ... |
||||
// ========== END OF VARIANTS ================================================= |
||||
|
||||
include("footer.php"); |
||||
?> |
@ -1,14 +0,0 @@ |
||||
<?php |
||||
/***************************************************************************** |
||||
IP Reg, a PHP/MySQL IPAM tool |
||||
Copyright (C) 2007-2009 Wietse Warendorff (up to v0.5) |
||||
Copyright (C) 2011-2023 Thomas Hooge |
||||
|
||||
SPDX-License-Identifier: GPL-3.0-or-later |
||||
*****************************************************************************/ |
||||
|
||||
$dbh = new PDO("mysql:host=$config_mysql_host;dbname=$config_mysql_dbname;charset=utf8", $config_mysql_username, $config_mysql_password); |
||||
$dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); |
||||
$dbh->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC); |
||||
|
||||
?> |
After Width: | Height: | Size: 748 B |
After Width: | Height: | Size: 587 B |
After Width: | Height: | Size: 778 B |
After Width: | Height: | Size: 801 B |
After Width: | Height: | Size: 500 B |
After Width: | Height: | Size: 591 B |
@ -1,171 +0,0 @@ |
||||
<?php |
||||
/***************************************************************************** |
||||
IP Reg, a PHP/MySQL IPAM tool |
||||
Copyright (C) 2007-2009 Wietse Warendorff |
||||
|
||||
This program is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
This program is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with this program. If not, see <http://www.gnu.org/licenses/>. |
||||
|
||||
For more information, visit http://sourceforge.net/projects/ipreg, |
||||
or contact me at wietsew@users.sourceforge.net |
||||
*****************************************************************************/ |
||||
|
||||
class User { |
||||
function check_strlen($string) { |
||||
// check length |
||||
if(strlen($string)<1) { |
||||
return FALSE; |
||||
} else { |
||||
return TRUE; |
||||
} |
||||
} |
||||
|
||||
function check_ldap_bind($user_name, $user_pass) { |
||||
global $config_ldap_host; |
||||
global $config_ldap_port; |
||||
global $config_ldap_base_dn; |
||||
global $config_ldap_bind_dn; |
||||
global $config_ldap_bind_pass; |
||||
global $config_ldap_login_attr; |
||||
$ldap_conn = NULL; |
||||
foreach ($config_ldap_host as $server) { |
||||
if ($ldap_conn = ldap_connect($server, $config_ldap_port)) { |
||||
if ($res = ldap_bind($ldap_conn, $config_ldap_bind_dn, $config_ldap_bind_pass)) { |
||||
ldap_set_option($ldap_conn, LDAP_OPT_REFERRALS, 0); |
||||
ldap_set_option($ldap_conn, LDAP_OPT_PROTOCOL_VERSION, 3); |
||||
$filter = "(&(objectClass=user)($config_ldap_login_attr=$user_name))"; |
||||
$res = ldap_search($ldap_conn, $config_ldap_base_dn, $filter, ['dn']); |
||||
if ($res) { |
||||
$info = ldap_get_entries($ldap_conn, $res); |
||||
$user_dn = $info[0]['dn']; |
||||
$res = ldap_bind($ldap_conn, $user_dn, $user_pass); |
||||
if ($res) { |
||||
return TRUE; |
||||
} |
||||
} |
||||
} |
||||
return FALSE; |
||||
} |
||||
} |
||||
return FALSE; |
||||
} |
||||
|
||||
function user_login($user_name, $user_pass) { |
||||
global $dblink; |
||||
// check user_name length |
||||
if($this->check_strlen($user_name)==FALSE) { |
||||
return FALSE; |
||||
} |
||||
|
||||
// check user_pass length |
||||
if($this->check_strlen($user_pass)==FALSE) { |
||||
return FALSE; |
||||
} |
||||
|
||||
// get user data |
||||
// initiate class |
||||
$db = new Db($dblink); |
||||
|
||||
// build query |
||||
$query = "SELECT |
||||
user.user_id, |
||||
user.user_pass, |
||||
user.user_realm, |
||||
user.user_displayname, |
||||
user.user_language, |
||||
user.user_imagesize, |
||||
user.user_imagecount, |
||||
user.user_mac, |
||||
user.user_dateformat, |
||||
user.user_dns1suffix, |
||||
user.user_dns2suffix, |
||||
user.user_menu_assets, |
||||
user.user_menu_assetclasses, |
||||
user.user_menu_assetclassgroups, |
||||
user.user_menu_locations, |
||||
user.user_menu_nodes, |
||||
user.user_menu_subnets, |
||||
user.user_menu_users, |
||||
user.user_menu_vlans, |
||||
user.user_menu_zones, |
||||
user.user_tooltips |
||||
FROM |
||||
user |
||||
WHERE |
||||
user.user_name='" . $user_name . "'"; |
||||
|
||||
// run query |
||||
$users = $db->db_select($query); |
||||
|
||||
// count results |
||||
$user_counter = count($users); |
||||
|
||||
// any users? |
||||
if ($user_counter>0) { |
||||
if ($users[0]['user_realm'] == 'ldap') { |
||||
// check LDAP auth |
||||
if (! $this->check_ldap_bind($user_name, $user_pass)) { |
||||
return FALSE; |
||||
} |
||||
// TODO sync LDAP data to local |
||||
} else { |
||||
// compare local passwords |
||||
if(!strcmp(md5($user_pass), rtrim($users[0]['user_pass']))) { |
||||
// all ok: user is logged in |
||||
|
||||
// md5 match but outdated. rewrite with new algo |
||||
$newhash = password_hash($user_pass, PASSWORD_BCRYPT); |
||||
$query = "UPDATE user SET user_pass='" . $newhash. "' WHERE user_id=" . $users[0]['user_id']; |
||||
$db->db_update($query); |
||||
|
||||
} else { |
||||
if (! password_verify($user_pass, $users[0]['user_pass'])) { |
||||
return FALSE; |
||||
} |
||||
} |
||||
} |
||||
} else { |
||||
return FALSE; |
||||
} |
||||
|
||||
// register session data |
||||
$_SESSION['suser_id'] = $users[0]['user_id']; |
||||
$_SESSION['suser_displayname'] = $users[0]['user_displayname']; |
||||
$_SESSION['suser_language'] = $users[0]['user_language']; |
||||
$_SESSION['suser_imagesize'] = $users[0]['user_imagesize']; |
||||
$_SESSION['suser_imagecount'] = $users[0]['user_imagecount']; |
||||
$_SESSION['suser_mac'] = $users[0]['user_mac']; |
||||
$_SESSION['suser_dateformat'] = $users[0]['user_dateformat']; |
||||
$_SESSION['suser_dns1suffix'] = $users[0]['user_dns1suffix']; |
||||
$_SESSION['suser_dns2suffix'] = $users[0]['user_dns2suffix']; |
||||
$_SESSION['suser_menu_assets'] = $users[0]['user_menu_assets']; |
||||
$_SESSION['suser_menu_assetclasses'] = $users[0]['user_menu_assetclasses']; |
||||
$_SESSION['suser_menu_assetclassgroups'] = $users[0]['user_menu_assetclassgroups']; |
||||
$_SESSION['suser_menu_locations'] = $users[0]['user_menu_locations']; |
||||
$_SESSION['suser_menu_nodes'] = $users[0]['user_menu_nodes']; |
||||
$_SESSION['suser_menu_subnets'] = $users[0]['user_menu_subnets']; |
||||
$_SESSION['suser_menu_users'] = $users[0]['user_menu_users']; |
||||
$_SESSION['suser_menu_vlans'] = $users[0]['user_menu_vlans']; |
||||
$_SESSION['suser_menu_zones'] = $users[0]['user_menu_zones']; |
||||
$_SESSION['suser_tooltips'] = $users[0]['user_tooltips']; |
||||
|
||||
// no errors found, return |
||||
return TRUE; |
||||
} |
||||
|
||||
function user_logout() { |
||||
// clear and destroy session |
||||
$_SESSION = array(); |
||||
} |
||||
} |
||||
?> |
@ -0,0 +1,52 @@ |
||||
<table class="title"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable} ({$cables|@count}) |
||||
</td> |
||||
<td align="right"> |
||||
{if $suser_add || $suser_admin} |
||||
<a href="cable.php?f=add"><img src="images/page_add.png" alt="{$lang_add}" {if $suser_tooltips}title="{$lang_add}" {/if}/></a> |
||||
{/if} |
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
<table class="info"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable} |
||||
</td> |
||||
<td class="header"> |
||||
{$lang_length} |
||||
</td> |
||||
<td class="header"> |
||||
{$lang_cable_type} |
||||
</td> |
||||
<td class="header"> |
||||
{$lang_cable_info} |
||||
</td> |
||||
</tr> |
||||
{foreach item=cable from=$cables} |
||||
<tr> |
||||
<td class="label"> |
||||
<img src="image.php?color={$cable.cable_color}" alt="#{$cable.cable_color}"> |
||||
<a href="cable.php?f=view&id={$cable.id}">{$cable.description}</a> |
||||
</td> |
||||
<td class="label"> |
||||
{$cable.cable_length} m |
||||
</td> |
||||
<td class="label"> |
||||
{$cable.cable_type} |
||||
</td> |
||||
<td class="label"> |
||||
{$cable.info} |
||||
</td> |
||||
</tr> |
||||
{foreachelse} |
||||
<tr> |
||||
<td> |
||||
{$lang_cable_none} |
||||
</td> |
||||
</tr> |
||||
{/foreach} |
||||
</table> |
@ -0,0 +1,75 @@ |
||||
<form method="POST" action="cable.php"> |
||||
|
||||
<table class="title"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable_add} |
||||
</td> |
||||
<td align="right"> |
||||
<a href="#" onClick="history.go(-1)"><img src="images/control_rewind_blue.png" alt="{$lang_cancel}"{if $suser_tooltips} title="{$lang_cancel}"{/if} /></a> |
||||
<input type="image" name="submit[insert]" src="images/page_save.png" alt="{$lang_save}"{if $suser_tooltips} title="{$lang_save}"{/if} /> |
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
<table class="info"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable} |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_description} |
||||
</td> |
||||
<td class="value"> |
||||
<input type="text" size="40" name="description" maxlength="80"> |
||||
</td> |
||||
</tr> |
||||
{* |
||||
<tr> |
||||
<td class="label"> |
||||
from - to |
||||
</td> |
||||
<td class="value"> |
||||
<input type="text" size="10" name="length" maxlength="12"> |
||||
- |
||||
<input type="text" size="10" name="length" maxlength="12"> |
||||
</td> |
||||
</tr> |
||||
*} |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_length} |
||||
</td> |
||||
<td class="value"> |
||||
<input type="text" size="10" name="length" maxlength="80"> m |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
Type |
||||
</td> |
||||
<td class="value"> |
||||
{html_options name=cable_type options=$type_options selected=$cable->cable_type} |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_color} |
||||
</td> |
||||
<td class="value"> |
||||
#<input type="text" {literal}class="color {pickerPosition:'right'}"{/literal} name="color" size="6" maxlength="6" value="{$cable->color}"> |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_info} |
||||
</td> |
||||
<td class="value"> |
||||
<textarea name="info" cols="30" rows="10"></textarea> |
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
</form> |
@ -0,0 +1,39 @@ |
||||
<form method="POST" action="cable.php"> |
||||
<input type="hidden" name="id" value="{$cable->id}"> |
||||
|
||||
<table class="title"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable_del} |
||||
</td> |
||||
<td align="right"> |
||||
<a href="#" onClick="history.go(-1)"><img src="image.php?icon=cancel" alt="{$lang_cancel}" {if $suser_tooltips}title="{$lang_cancel}" {/if}/></a> |
||||
<input type="image" src="image.php?icon=shred" alt="{$lang_assetclass_del}" {if $suser_tooltips}title="{$lang_assetclass_del}" {/if}/> |
||||
|
||||
<a href="#" onClick="history.go(-1)"><img src="images/control_rewind_blue.png" alt="Abbruch"{if $suser_tooltips} title="{$lang_cancel}"{/if} /></a> |
||||
<input type="image" name="submit[delete]" src="images/delete.png" alt="Löschen"{if $suser_tooltips} title="Löschen"{/if} /> |
||||
|
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
<table class="info"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable} |
||||
</td> |
||||
<td class="header_right"> |
||||
|
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_cable_name} |
||||
</td> |
||||
<td class="value"> |
||||
<a href="cable.php?id={$cable->id}">{$cable->description}</a> |
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
</form> |
@ -0,0 +1,76 @@ |
||||
<form method="POST" action="cable.php"> |
||||
<input type="hidden" name="id" value="{$cable->id}"> |
||||
|
||||
<table class="title"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable_add} |
||||
</td> |
||||
<td align="right"> |
||||
<a href="#" onClick="history.go(-1)"><img src="images/control_rewind_blue.png" alt="{$lang_cancel}"{if $suser_tooltips} title="{$lang_cancel}"{/if} /></a> |
||||
<input type="image" name="submit[update]" src="images/page_save.png" alt="{$lang_save}"{if $suser_tooltips} title="{$lang_save}"{/if} /> |
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
<table class="info"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable} |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_description} |
||||
</td> |
||||
<td class="value"> |
||||
<input type="text" size="40" name="description" maxlength="80" value="{$cable->description}"> |
||||
</td> |
||||
</tr> |
||||
{* |
||||
<tr> |
||||
<td class="label"> |
||||
from - to |
||||
</td> |
||||
<td class="value"> |
||||
<input type="text" size="10" name="loc_from" maxlength="12"> |
||||
- |
||||
<input type="text" size="10" name="loc_to" maxlength="12"> |
||||
</td> |
||||
</tr> |
||||
*} |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_length} |
||||
</td> |
||||
<td class="value"> |
||||
<input type="text" size="10" name="length" maxlength="80" value="{$cable->cable_length}"> m |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
Type |
||||
</td> |
||||
<td class="value"> |
||||
{html_options name=cable_type options=$type_options selected=$cable->cable_type} |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_color} |
||||
</td> |
||||
<td class="value"> |
||||
#<input type="text" {literal}class="color {pickerPosition:'right'}"{/literal} name="color" size="6" maxlength="6" value="{$cable->color}"> |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_info} |
||||
</td> |
||||
<td class="value"> |
||||
<textarea name="info" cols="30" rows="10">{$cable->info}</textarea> |
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
</form> |
@ -0,0 +1,63 @@ |
||||
<table class="title"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$vlan_name} |
||||
</td> |
||||
<td align="right"> |
||||
<a href="cable.php?f=edit&id={$cable->id}"><img src="image.php?icon=edit" alt="{$lang_cable_edit}"></a> |
||||
<a href="cable.php?f=del&id={$cable->id}"><img src="image.php?icon=delete" alt="{$lang_cable_del}"></a> |
||||
</td> |
||||
</tr> |
||||
</table> |
||||
|
||||
<table class="info"> |
||||
<tr> |
||||
<td class="header"> |
||||
{$lang_cable} |
||||
</td> |
||||
<td class="header_right"> |
||||
|
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_description} |
||||
</td> |
||||
<td class="value"> |
||||
{$cable->description} |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_cable_type} XXX |
||||
</td> |
||||
<td class="value"> |
||||
{$cable->cable_type} |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_length} |
||||
</td> |
||||
<td class="value"> |
||||
{$cable->cable_length} m |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_color} |
||||
</td> |
||||
<td class="value"> |
||||
<img src="image.php?color={$cable->color}" alt="{$cable->color}"> |
||||
#{$cable->color} |
||||
</td> |
||||
</tr> |
||||
<tr> |
||||
<td class="label"> |
||||
{$lang_cable_info} |
||||
</td> |
||||
<td class="value"> |
||||
{$cable->info} |
||||
</td> |
||||
</tr> |
||||
</table> |
Reference in new issue