aboutsummaryrefslogtreecommitdiff
path: root/mod/guidbrowser/views/default/guidbrowser/entity_full.php
blob: 62dd78264c9861b9a53e9b619591ef5348337648 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
<?php
	/**
	 * Elgg GUID browser
	 * 
	 * @package ElggDevTools
	 * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
	 * @author Marcus Povey <marcus@marcus-povey.co.uk>
	 * @copyright Curverider Ltd 2008
	 * @link http://elgg.com/
	 */

	$entity = $vars['entity'];
	$metadata = $vars['metadata'];
	$annotations = $vars['annotations'];
	$relationships = $vars['relationships'];
	
?>
<div>
	<?php
		foreach ($entity as $k => $v)
		{
?>
		<div>
			<table>
				<tr>
				<td><b><?php echo $k; ?></b></td>
				<td><?php echo $v; ?></td> 
				</tr>
			</table>
		</div>
<?php
		}
	?>
</div>
<div id="metadata">
<h2>Metadata</h2>	
	<?php
		if ($metadata) foreach ($metadata as $m)
		{
?>
		<div>
			<table>
				<tr>
				<td><b><?php echo $m->name; ?></b></td>
				<td><?php echo $m->value; ?></td> 
				</tr>
			</table>
		</div>
<?php
		}
	?>
	
	<div>
		<form method="post">
			<input name="eguid" type="hidden" value="<?php echo $entity->guid; ?>" />
			<input name="owner_id" type="hidden" value="<?php echo page_owner(); ?>" />
			<input name="callaction" type="hidden" value="metadata" />
			Key : <input name="key" type="text" />
			Value : <input name="value" type="text" /> 
			<input name="submit" type="submit" value="submit" />
		</form>
	</div>
	
</div>

<div id="annotations">
<h2>Annotations</h2>	
	<?php
		if ($annotations) foreach ($annotations as $a)
		{
?>
		<div>
			<table>
				<tr>
				<td><b><?php echo $a->name; ?></b></td>
				<td><?php echo $a->value; ?></td> 
				</tr>
			</table>
		</div>
<?php
		}
	?>
	
	<div>
		<form method="post">
			<input name="eguid" type="hidden" value="<?php echo $entity->guid; ?>" />
			<input name="owner_id" type="hidden" value="<?php echo page_owner(); ?>" />
			<input name="callaction" type="hidden" value="annotations" />
			Key : <input name="key" type="text" />
			Value : <input name="value" type="text" /> 
			<input name="submit" type="submit" value="submit" />
		</form>
	</div>
</div>

<div id="relationship">
<h2>Relationships</h2>	
	<?php
		if ($relationships) foreach ($relationships as $r)
		{
?>
		<div>
			<table>
				<tr>
				<td><?php echo $r->guid_one; ?></td> 
				<td><b><?php echo $r->relationship; ?></b></td>
				<td><?php echo $r->guid_two; ?></td> 
				</tr>
			</table>
		</div>
<?php
		}
	?>
	
	<div>
		<form method="post">
			<input name="eguid" type="hidden" value="<?php echo $entity->guid; ?>" />
			<input name="owner_id" type="hidden" value="<?php echo page_owner(); ?>" />
			<input name="callaction" type="hidden" value="relationship" />
			Relationship : <input name="relationship" type="text" />
			Guid : <input name="guid2" type="text" /> 
			<input name="submit" type="submit" value="submit" />
		</form>
	</div>
</div>