Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F1245834
tag_listing.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Nov 21, 8:35 AM
Size
3 KB
Mime Type
text/x-php
Expires
Sun, Nov 23, 8:35 AM (1 d, 18 h)
Engine
blob
Format
Raw Data
Handle
809998
Attached To
rINP In-Portal
tag_listing.php
View Options
<?php
// new startup: begin
define
(
'REL_PATH'
,
'admin'
);
$relation_level
=
count
(
explode
(
'/'
,
REL_PATH
)
);
define
(
'FULL_PATH'
,
realpath
(
dirname
(
__FILE__
)
.
str_repeat
(
'/..'
,
$relation_level
)
)
);
require_once
FULL_PATH
.
'/kernel/startup.php'
;
// new startup: end
checkViewPermission
(
'in-portal:tag_library'
);
include_once
(
$pathtoroot
.
"kernel/include/tag-class.php"
);
$pathtolocal
=
$pathtoroot
.
"kernel/"
;
require_once
(
$pathtoroot
.
"admin/include/elements.php"
);
require_once
(
$pathtoroot
.
"kernel/admin/include/navmenu.php"
);
require_once
(
$pathtolocal
.
"admin/include/navmenu.php"
);
require_once
(
$pathtoroot
.
"admin/toolbar.php"
);
//Set Section
$section
=
"in-portal:tag_library"
;
//Set Environment Variable
$envar
=
"env="
.
BuildEnv
();
$sec
=
$objSections
->
GetSection
(
$section
);
$objCatToolBar
=
new
clsToolBar
();
$objCatToolBar
->
Add
(
"img_save"
,
"la_Save"
,
"#"
,
"swap('img_save','toolbar/tool_select_f2.gif');"
,
"swap('img_save', 'toolbar/tool_select.gif');"
,
"javascript:history.back();"
,
"tool_select.gif"
);
$objCatToolBar
->
Add
(
"img_cancel"
,
"la_Cancel"
,
"#"
,
"swap('img_cancel','toolbar/tool_cancel_f2.gif');"
,
"swap('img_cancel', 'toolbar/tool_cancel.gif');"
,
"javascript:history.back();"
,
"tool_cancel.gif"
);
$extra_styles
=
'<STYLE type="text/css">
<!--
.tag-listing {
border-collapse: collapse;
padding: 0px;
margin: 0px;
border: 0px;
background-color: #f6f6f6;
}
.tag-listing-row {font: 11px verdana}
.b-element {font: bold 13px}
.i-element {font: oblique 12px; background: #ebebeb;}
.header {
background: #999;
color: #fff;
}
-->
</STYLE>'
;
$title
=
admin_language
(
"la_tag_library"
);
int_header
(
$objCatToolBar
,
NULL
,
$title
,
NULL
,
$extra_styles
);
$objTagList
=
new
clsTagList
();
$objTagList
->
Clear
();
$objTagList
->
Query_Item
(
"SELECT * FROM "
.
$objTagList
->
SourceTable
);
?>
<table class="tag-listing" border="0" width="100%">
<?php
if
(
$objTagList
->
NumItems
()>
0
)
{
foreach
(
$objTagList
->
Items
as
$i
)
{
$i
->
LoadAttribs
();
//echo " ".$i->attribs->NumItems()." Attributes<br>\n";
if
(
$i
->
Get
(
"name"
)
)
{
?>
<tr class="header">
<td class="b-element" colspan="2">
<?php
echo
(
$i
->
Get
(
"scope"
)
!=
"global"
)
?
$i
->
Get
(
"scope"
).
'.'
.
$i
->
Get
(
"name"
)
:
$i
->
Get
(
"name"
);
?>
</td>
</tr>
<tr class="tag-listing-row">
<td colspan="2" class="i-element">
<?php
echo
$i
->
Get
(
"description"
);
?>
</td>
</tr>
<tr class="tag-listing-row">
<td class="b-element" width="90%">Attributes:</td>
<td class="b-element" width="10%">Source example:</td>
</tr>
<tr>
<td>
<?php
if
(
$i
->
attribs
->
NumItems
()
>
0
)
{
// has attributes
?>
<!-- attributes listing: begin -->
<table border="0" width="100%" class="tag-listing">
<?php
foreach
(
$i
->
attribs
->
Items
as
$a
)
{
?>
<tr class="tag-listing-row">
<td valign="top">
<?php
echo
$a
->
Get
(
"Name"
).
'['
.
$a
->
Get
(
"AttrType"
).
']'
;
?>
</td>
<td>
<?php
echo
$a
->
Get
(
"Description"
);
?>
</td>
</tr>
<?php
}
?>
</table>
<!-- attributes listing: end -->
<?php
}
else
{
?>
<?php
}
?>
</td>
<td>
<!-- example -->
<?php
$example
=
$i
->
Get
(
'example'
);
echo
$example
?
$example
:
' '
;
?>
</td>
</tr>
<?php
}
}
}
?>
</table>
<?php
int_footer
();
?>
Event Timeline
Log In to Comment