<div id="submenu">{{getcontent id=300}}</div>
<div id="middle2">
<h1>Edit Article</h1>
<div id="blog_article">
<div id="smarty_plugin">
{{getCollectionByCategory CollectionID=3 ColumnID=1 Value=$smarty.session.UserID OrderColumn=1 var=Groups}} 
{{assign var=generalUser value=0}} 
{{assign var=moderatorUser value=0}} 
{{foreach from=$Groups item=v key=k}} 
{{if $v.Collection_3_2 eq 1 or $v.Collection_3_2 eq 5 }} {{assign var=moderatorUser value=1}} {{/if}} 
{{if $v.Collection_3_2 eq 3 or $v.Collection_3_2 eq 4 }} {{assign var=generalUser value=1}} {{/if}} 
{{/foreach}}
{{getCollectionByCategory CollectionID=61 OrderColumn=1 OrderWay=1 var=Discussion ColumnID='ID' Value=$smarty.get.article}} 
{{assign var=DiscussionData value=$Discussion[0]}} 
{{getCollectionByCategory CollectionID=1 OrderColumn=1 OrderWay=1 var=User ColumnID='ID' Value=$DiscussionData.Collection_61_6}} 
{{assign var=UData value=$User[0]}} 
{{if $smarty.session.UserID eq $UData.Collection_1_ID or $moderatorUser eq 1}} 
<div id="postcomment">
{{ViewCollection CollectionID=61 TemplateID=13 rowid=$smarty.get.article mode='Edit'}} 
</div>
{{else}} 
{{urlredirect page='/blog.html'}}
{{/if}}
</div>
</div>
</div>