/* appjet:version 0.1 */ /*<script> This work is licensed under a Creative Commons Attribution-Noncommercial 3.0 United States License http://creativecommons.org/licenses/by-nc/3.0/us/
...Vortices v2.0 yet another social news network... */
//Editing functionget_edit() { varnode=getStorable(rp.edit) if(request.method=='GET'&&(node.wiki_tag=='wiki'||node.author==user.alias)&&!node.deleted) { vartags=html( accessTags(node).sort().map(function(tag){ returnSPAN(tag,SUP(A({rel:'nofollow',href:'/untag'+paramGen({id:node.id,tag:tag,redirect:'/edit/'+node.id})},'x'))) }) .join('') ) print( H2('Edit'), FORM({action:'/edit','class':'submit',method:'post'}, INPUT({type:'hidden',name:'node',value:node.id}), LABEL(SPAN('Title'),INPUT({name:'title',autocomplete:'off',type:'text',value:node.title||'',maxlength:255})), INPUT({type:'submit',value:'Save'}), LABEL(SPAN('URL'),INPUT({name:'link',autocomplete:'off',type:'text',value:node.link||''})), LABEL(SPAN('Text'),TEXTAREA({name:'text'},raw(node.text))), LABEL(SPAN('Tags'),INPUT({name:'tags',type:'text',maxlength:255})), P(tags) ) ) } else { status('Error: You cannot edit this post. Make sure that you are logged in and that you authored this or it is a wiki.') } }