RT #31482 making sure the tax class is not editable after the customer has been billed.
[freeside.git] / httemplate / elements / popup_link.html
1 <%doc>
2
3 Example:
4
5   include('/elements/init_overlib.html')
6
7   include( '/elements/popup_link.html', { #hashref or a list, either way is fine
8
9     #required
10     'action'         => 'content.html', # uri for content of popup
11     'label'          => 'click me',     # text of <A> tag
12    
13     #strongly recommended
14     'actionlabel'    => 'You clicked',  # popup title
15    
16     #opt
17     'width'          => 540,
18     'height'         => 336,
19     'color'          => '#ff0000',
20     'closetext'      => 'Go Away',      # the value '' removes the link
21
22     #uncommon opt
23     'aname'          => "target", # link NAME= value, useful for #targets
24     'target'         => '_parent',
25     'style'          => 'css-attribute:value',
26   } )
27
28 </%doc>
29 % if ($params->{'action'} && $label) {
30 <A HREF="javascript:void(0);"
31    onClick="<% $onclick |n %>"
32    <% $params->{'aname'}  ? 'NAME="'.   $params->{'aname'}.  '"' : '' |n %>
33    <% $params->{'target'} ? 'TARGET="'. $params->{'target'}. '"' : '' |n %>
34    <% $params->{'style'}  ? 'STYLE="'.  $params->{'style'}.  '"' : '' |n %>
35 ><% $label %></A>\
36 % }
37 <%init>
38
39 my $params;
40 if (ref($_[0]) eq 'HASH') {
41   #$params = { %$params, %{ $_[0] } };
42   $params = shift;
43 } else {
44   #$params = { %$params, @_ };
45   $params = { @_ };
46 }
47
48 my $label = $params->{'label'};
49 $label =~ s/ /&nbsp;/g;
50 my $onclick = include('/elements/popup_link_onclick.html', $params);
51
52 </%init>