Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
W
White Rabbit Switch - Software
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
86
Issues
86
List
Board
Labels
Milestones
Merge Requests
4
Merge Requests
4
CI / CD
CI / CD
Pipelines
Schedules
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
White Rabbit Switch - Software
Commits
a52507c9
Commit
a52507c9
authored
Aug 22, 2016
by
Adam Wujek
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rootfs/www: display colors also for vlans greater than 10
Signed-off-by:
Adam Wujek
<
adam.wujek@cern.ch
>
parent
a543cdb3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
port2vlan.php
userspace/rootfs_override/var/www/port2vlan.php
+1
-1
vlan.php
userspace/rootfs_override/var/www/vlan.php
+2
-2
No files found.
userspace/rootfs_override/var/www/port2vlan.php
View file @
a52507c9
...
...
@@ -67,7 +67,7 @@
echo '<option class="btn" value="'.$vlan[0].$vlan[1].'"><center>ID'.$vlan[0].$vlan[1].'</center></option>';
}
}*/
echo
'<input STYLE="background-color:'
.
$vlancolor
[
$single_line
[
5
]]
.
';text-align:center;" size="5" type="text" value="'
.
$single_line
[
5
]
.
'" name="vlan'
.
(
$i
)
.
'">'
;
echo
'<input STYLE="background-color:'
.
$vlancolor
[
$single_line
[
5
]
%
10
]
.
';text-align:center;" size="5" type="text" value="'
.
$single_line
[
5
]
.
'" name="vlan'
.
(
$i
)
.
'">'
;
//echo '<option class="btn" selected="selected" value="disabled"><center>Disabled</center></option>';
//echo '</select>'; // end Vlan ID assignation
...
...
userspace/rootfs_override/var/www/vlan.php
View file @
a52507c9
...
...
@@ -39,7 +39,7 @@
$line
=
explode
(
" "
,
$line
);
if
(
strcmp
(
$line
[
3
],
"0x"
)){
echo
'<tr align=center><td bgcolor="'
.
$vlancolor
[
$line
[
1
]]
.
'">VLAN '
.
$line
[
1
]
.
'</td><td>'
.
$line
[
2
]
.
'</td><td>'
.
parse_mask2ports
(
$line
[
3
])
.
'</td><td>'
.
$line
[
4
]
.
'</td><td>'
.
$line
[
5
]
.
'</td><td><A HREF="delvlan.php?vlan='
.
$line
[
1
]
.
'.">Delete</A></td></tr>'
;
echo
'<tr align=center><td bgcolor="'
.
$vlancolor
[
$line
[
1
]
%
10
]
.
'">VLAN '
.
$line
[
1
]
.
'</td><td>'
.
$line
[
2
]
.
'</td><td>'
.
parse_mask2ports
(
$line
[
3
])
.
'</td><td>'
.
$line
[
4
]
.
'</td><td>'
.
$line
[
5
]
.
'</td><td><A HREF="delvlan.php?vlan='
.
$line
[
1
]
.
'.">Delete</A></td></tr>'
;
}
else
{
echo
'<tr align=center><td>'
.
$line
[
1
]
.
'</td><td>'
.
$line
[
2
]
.
'</td><td>'
.
parse_mask2ports
(
$line
[
3
]
.
$line
[
4
])
.
'</td><td>'
.
$line
[
5
]
.
'</td><td>'
.
$line
[
6
]
.
'</td><td><A HREF="delvlan.php?vlan='
.
$line
[
1
]
.
'.">Delete</A></td></tr>'
;
}
...
...
@@ -99,7 +99,7 @@
if
(
$counter
>=
2
&&
!
empty
(
$line
)){
$line
=
explode
(
" "
,
$line
);
echo
'<tr align=center><td>'
.
(
$line
[
0
])
.
'</td><td>'
.
$line
[
1
]
.
" ("
.
$line
[
2
]
.
')</td><td>'
.
(
$line
[
4
])
.
'</td><td bgcolor="'
.
$vlancolor
[
$line
[
5
]]
.
'">VLAN '
.
$line
[
5
]
.
'</td><td>'
.
$line
[
6
]
.
'</td></td></tr>'
;
echo
'<tr align=center><td>'
.
(
$line
[
0
])
.
'</td><td>'
.
$line
[
1
]
.
" ("
.
$line
[
2
]
.
')</td><td>'
.
(
$line
[
4
])
.
'</td><td bgcolor="'
.
$vlancolor
[
$line
[
5
]
%
10
]
.
'">VLAN '
.
$line
[
5
]
.
'</td><td>'
.
$line
[
6
]
.
'</td></td></tr>'
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment