@@ -13,37 +13,40 @@ echo '<script type="text/javascript" src="' . $this->coreWebroot . '/public/js/s
13
13
?>
14
14
<link href="<?php echo $ this ->coreWebroot ?> /public/css/share/share.dialog.css?<?php echo time ();?> " rel="stylesheet" type="text/css" />
15
15
16
- <?php
17
- echo "<div id='elementDirectLink' " .(($ this ->private )?'style="display:none;" ' :'' )."> " ;
18
- echo $ this ->t ('You can use the following direct link to share the ' ).' ' .$ this ->t ($ this ->type ).':<br/> ' ;
19
- echo "<input type='text' id='urlInput' readonly='readonly' value=' {$ this ->shareUrl }' /> " ;
20
- echo "</div> " ;
21
- echo "<br/> " ;
22
16
23
- echo "<div id='permissionsContent'> " ;
24
- echo " <div id='permissionPublic' " .(($ this ->private )?'style="display:none;" ' :'' )."> " ;
25
- echo " <b> {$ this ->t ('Public ' )}</b> {$ this ->t ('Anyone can find and access. No sign-in required. ' )}" ;
26
- echo " <a id='setElementPrivateLink'> {$ this ->t ('You can set the permission as private. ' )}</a> " ;
27
- echo " </div> " ;
17
+ <div id='elementDirectLink' <?php echo (($ this ->private )?'style="display:none;" ' :'' );?> >";
18
+ <?php echo $ this ->t ('You can use the following direct link to share the ' ).' ' .$ this ->t ($ this ->type )?> :<br/>';
19
+ <input type='text' id='urlInput' readonly='readonly' value='{$this->shareUrl}' />
20
+ </div>
21
+ <br/>
22
+
23
+ <div id='permissionsContent'>
24
+ <div id='permissionPublic' <?php echo (($ this ->private )?'style="display:none;" ' :'' )?> >
25
+ <b><?php echo $ this ->t ('Public ' )?> </b> <?php echo $ this ->t ('Anyone can find and access. No sign-in required. ' )?>
26
+ <a id='setElementPrivateLink'><?php echo $ this ->t ('You can set the permission as private. ' )?> </a>
27
+ </div>
28
28
29
- echo " <div id='permissionPrivate' " . ((!$ this ->private )?'style="display:none;" ' :'' ). " > " ;
30
- echo " <b> { $ this ->t ('Private ' )} </b> { $ this ->t ('Only people explicitly granted permission can access. Sign-in required. ' )}" ;
31
- echo " <a id='setElementPublicLink'> { $ this ->t ('You can set the permission as public. ' )} </a> " ;
32
- echo " </div>" ;
29
+ <div id='permissionPrivate' <?php echo ((!$ this ->private )?'style="display:none;" ' :'' )?> >
30
+ <b><?php echo $ this ->t ('Private ' )?> </b> <?php echo $ this ->t ('Only people explicitly granted permission can access. Sign-in required. ' )?>
31
+ <a id='setElementPublicLink'><?php echo $ this ->t ('You can set the permission as public. ' )?> </a>
32
+ </div>
33
33
34
- echo " <h4> " .$ this ->t ('Permissions ' )."</h4> " ;
35
- echo " <div id='permissionEntity'> " ;
36
- echo " <table> " ;
34
+ <h4><?php echo $ this ->t ('Permissions ' )?> </h4>
35
+ <div id='permissionEntity'>
36
+ <table>
37
+ <?php
37
38
foreach ($ this ->groupPolicies as $ policy )
38
39
{
39
- echo " <tr type='group' element=' {$ policy ->group ->getKey ()}'> " ;
40
- echo " <td> " ;
41
- echo " <img src=' {$ this ->coreWebroot }/public/images/icons/community.png' " ;
42
- echo " </td> " ;
43
- echo " <td class='changePermissionSelect'> " ;
44
- echo " " .(($ policy ->communityMemberGroup )?$ policy ->group ->getCommunity ()->getName ():$ policy ->group ->getName ());
45
- echo " </td> " ;
46
- echo " <td> " ;
40
+ ?>
41
+ <tr type='group' element='<?php echo $ policy ->group ->getKey ()?> '>
42
+ <td>
43
+ <img src='<?php echo $ this ->coreWebroot ?> /public/images/icons/community.png'/>
44
+ </td>
45
+ <td class='changePermissionSelect'>
46
+ <?php echo (($ policy ->communityMemberGroup )?$ policy ->group ->getCommunity ()->getName ():$ policy ->group ->getName ())?>
47
+ </td>
48
+ <td>
49
+ <?php
47
50
if ((!$ this ->isAdmin &&$ policy ->getPolicy ()==MIDAS_POLICY_ADMIN ))
48
51
{
49
52
switch ($ policy ->getPolicy ())
@@ -60,7 +63,9 @@ foreach($this->groupPolicies as $policy)
60
63
}
61
64
else
62
65
{
63
- echo " <select class='changePermissionSelect'> " ;
66
+ ?>
67
+ <select class='changePermissionSelect'>
68
+ <?php
64
69
if ($ this ->isAdmin )
65
70
{
66
71
echo " <option value=' " .MIDAS_POLICY_ADMIN ."' " .(($ policy ->getPolicy ()==MIDAS_POLICY_ADMIN )?'selected ' :'' )."> {$ this ->t ('is owner ' )}</option> " ;
@@ -69,23 +74,27 @@ foreach($this->groupPolicies as $policy)
69
74
echo " <option value=' " .MIDAS_POLICY_READ ."' " .(($ policy ->getPolicy ()==MIDAS_POLICY_READ )?'selected ' :'' )."> {$ this ->t ('can read ' )}</option> " ;
70
75
echo " </select> " ;
71
76
}
72
- echo " </td> " ;
73
- echo " <td> " ;
74
- echo " <a class='removeShareLink'><img src=' {$ this ->coreWebroot }/public/images/icons/close.png' alt=''/></a> " ;
75
- echo " </td> " ;
76
- echo " </tr> " ;
77
+ ?>
78
+ </td>
79
+ <td>
80
+ <a class='removeShareLink'><img src='<?php echo $ this ->coreWebroot ?> /public/images/icons/close.png' alt=''/></a>
81
+ </td>
82
+ </tr>
83
+ <?php
77
84
}
78
85
79
86
foreach ($ this ->userPolicies as $ policy )
80
87
{
81
- echo " <tr type='user' element=' {$ policy ->user ->getKey ()}'> " ;
82
- echo " <td> " ;
83
- echo " <img src=' {$ this ->coreWebroot }/public/images/icons/unknownUser-small.png' " ;
84
- echo " </td> " ;
85
- echo " <td> " ;
86
- echo " " .$ policy ->user ->getFullName ();
87
- echo " </td> " ;
88
- echo " <td> " ;
88
+ ?>
89
+ <tr type='user' element='<?php echo $ policy ->user ->getKey ()?> '>
90
+ <td>
91
+ <img src='<?php echo $ this ->coreWebroot ?> /public/images/icons/unknownUser-small.png'/>
92
+ </td>
93
+ <td>
94
+ <?php echo $ policy ->user ->getFullName ()?>
95
+ </td>
96
+ <td>
97
+ <?php
89
98
if ((!$ this ->isAdmin &&$ policy ->getPolicy ()==MIDAS_POLICY_ADMIN )||$ policy ->user ->getKey ()==$ this ->userDao ->getKey ())
90
99
{
91
100
switch ($ policy ->getPolicy ())
@@ -120,18 +129,19 @@ foreach($this->userPolicies as $policy)
120
129
}
121
130
echo " </tr> " ;
122
131
}
123
- echo " </table> " ;
124
- echo " <br/> " ;
125
- echo " <div class='shareSearch'> " ;
126
- echo " <input type='text' id='live_share_search' value=' {$ this ->t ('Add a permission to ... ' )}' autocomplete='off' autocorrect='off' autocapitalize='off' /> " ;
127
- echo " <input type='hidden' id='live_share_search_value' value='init' /> " ;
128
- echo " <div id='searchShareLoading' style='display:none'></div> " ;
129
- echo " </div> " ;
130
- echo " </div> " ;
132
+ ?>
133
+ </table>
134
+ <br/>
135
+ <div class='shareSearch'>
136
+ <input type='text' id='live_share_search' value='<?php echo $ this ->t ('Add a permission to ... ' )?> ' autocomplete='off' autocorrect='off' autocapitalize='off' />
137
+ <input type='hidden' id='live_share_search_value' value='init' />
138
+ <div id='searchShareLoading' style='display:none'></div>
139
+ </div>
140
+ </div>
141
+
142
+ </div>
131
143
132
- echo "</div> " ;
133
144
134
- ?>
135
145
<div style="display: none;" class="jsonShareContent">
136
146
<?php echo $ this ->jsonShare ?>
137
147
</div>
0 commit comments