Revision 0891df39
Von Holger Lindemann vor etwa 14 Jahren hinzugefügt
SL/Form.pm | ||
---|---|---|
727 | 727 |
<link rel="stylesheet" href="css/jquery.autocomplete.css" type="text/css" /> |
728 | 728 |
|
729 | 729 |
<meta name="robots" content="noindex,nofollow" /> |
730 |
<script type="text/javascript" src="js/highlight_input.js"></script> |
|
731 | 730 |
|
732 | 731 |
<link rel="stylesheet" type="text/css" href="css/tabcontent.css" /> |
733 | 732 |
<script type="text/javascript" src="js/tabcontent.js"> |
css/lx-office-erp.css | ||
---|---|---|
259 | 259 |
background-color: #ffcccc; |
260 | 260 |
padding: 3px; |
261 | 261 |
} |
262 |
input:focus { |
|
263 |
background-color:yellow; |
|
264 |
} |
|
265 |
|
js/highlight_input.js | ||
---|---|---|
1 |
//Highlight form element- ? Dynamic Drive (www.dynamicdrive.com) |
|
2 |
//For full source code, 100's more DHTML scripts, and TOS, |
|
3 |
//visit http://www.dynamicdrive.com |
|
4 |
|
|
5 |
var highlightcolor="yellow" |
|
6 |
|
|
7 |
var ns6=document.getElementById&&!document.all |
|
8 |
var previous='' |
|
9 |
var eventobj |
|
10 |
|
|
11 |
//Regular expression to highlight only form elements |
|
12 |
var intended=/INPUT|TEXTAREA|SELECT|OPTION/ |
|
13 |
|
|
14 |
//Function to check whether element clicked is form element |
|
15 |
function checkel(which){ |
|
16 |
if (which.style&&intended.test(which.tagName)){ |
|
17 |
if (ns6&&eventobj.nodeType==3) |
|
18 |
eventobj=eventobj.parentNode.parentNode |
|
19 |
return true |
|
20 |
} |
|
21 |
else |
|
22 |
return false |
|
23 |
} |
|
24 |
|
|
25 |
//Function to highlight form element |
|
26 |
function highlight(e){ |
|
27 |
eventobj=ns6? e.target : event.srcElement |
|
28 |
if (previous!=''){ |
|
29 |
if (checkel(previous)) |
|
30 |
previous.style.backgroundColor='' |
|
31 |
previous=eventobj |
|
32 |
if (checkel(eventobj)) |
|
33 |
eventobj.style.backgroundColor=highlightcolor |
|
34 |
} |
|
35 |
else{ |
|
36 |
if (checkel(eventobj)) |
|
37 |
eventobj.style.backgroundColor=highlightcolor |
|
38 |
previous=eventobj |
|
39 |
} |
|
40 |
} |
templates/webpages/ct/form_header.html | ||
---|---|---|
1 | 1 |
[%- USE T8 %] |
2 | 2 |
[% USE HTML %][% USE LxERP %] |
3 |
<body onLoad="fokus()">
|
|
3 |
<body> |
|
4 | 4 |
|
5 | 5 |
<div class="listtop">[% title %]</div> |
6 | 6 |
|
7 |
<form method="post" name="ct" action="ct.pl" onKeyUp="highlight(event)" onClick="highlight(event)">
|
|
7 |
<form method="post" name="ct" action="ct.pl" > |
|
8 | 8 |
|
9 | 9 |
<ul id="maintab" class="shadetabs"> |
10 | 10 |
<li class="selected"><a href="#" rel="billing">[% 'Billing Address' | $T8 %]</a></li> |
Auch abrufbar als: Unified diff
Das ungrlückliche Script ./js/highlight_input.js entfernt und dafür input.focus eingefügt.