15.08.2013 Views

Ektron® eWebEditPro Developer's Reference Guide

Ektron® eWebEditPro Developer's Reference Guide

Ektron® eWebEditPro Developer's Reference Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

'''''''''''''''''''''''''''''''''''''''''''''''''<br />

' This ASP routine processes the submission of the<br />

' content contained within the <strong>eWebEditPro</strong> editor.<br />

Sub ReceiveContent()<br />

Dim strResp<br />

Dim ErrorCode<br />

strResp = ""<br />

Content Upload<br />

Below is an ASP example of how to use these fields. The example receives<br />

content and returns it to the client as encoded HTML.<br />

strResp = strResp & "Content Successfully Received"<br />

strResp = strResp & "However, the sample page that received the<br />

content does not save the posted content on the server."<br />

strResp = strResp & "The content is not saved."<br />

strResp = strResp & "Modify the sample receiving page to save the<br />

content or specify another receiving page that does save the content."<br />

strResp = strResp & "Click on 'Undo' to restore your<br />

content."<br />

strResp = strResp & ""<br />

strResp = strResp & "Content Title:&nbsp;&nbsp;" &<br />

g_objUpload.EkFormFieldValue(g_binaryFormData, "content_title", ErrorCode) & ""<br />

strResp = strResp & "Content Size:&nbsp;&nbsp;" &<br />

g_objUpload.EkFormFieldValue(g_binaryFormData, "content_size", ErrorCode) & ""<br />

strResp = strResp & "Content Description:&nbsp;&nbsp;" &<br />

g_objUpload.EkFormFieldValue(g_binaryFormData, "content_description", ErrorCode) & ""<br />

strResp = strResp & "Content Type:&nbsp;&nbsp;" &<br />

g_objUpload.EkFormFieldValue(g_binaryFormData, "content_type", ErrorCode)<br />

strResp = strResp & ""<br />

strResp = strResp & "Submitted Content Below"<br />

strResp = strResp & Server.HTMLEncode(g_objUpload.EkFormFieldValue(g_binaryFormData,<br />

"content_text", ErrorCode))<br />

strResp = strResp & ""<br />

strResp = strResp & ""<br />

Response.Write(strResp)<br />

End Sub<br />

Steps to Receiving Content<br />

Step 1 - Act on the Command<br />

The uploadcontent command signals the receiving server that the posting<br />

includes a file. The command is retrieved from the actiontyp field of the posted<br />

form.<br />

<strong>Ektron®</strong> <strong>eWebEditPro</strong> Developer’s <strong>Reference</strong> <strong>Guide</strong>, Release 5.1, Revision 1 504

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!