0,if((getToken(ExternalIPAddress)="__RemoteIP__") or ("__RemoteIP__"="127.0.0.1"),"127.0.0.1:"+getToken(GreenLight_Client_Https_Port),getToken(ExternalIPAddress)+":"+getToken(GreenLight_Client_Https_Port)),"127.0.0.1:"+getToken(GreenLight_Client_Https_Port))}";>

Debug Console

Action: __Action__
User: __User__
Pass: __Pass__
WidgetLibrary: __WidgetLibrary__
FilterGroup: __FilterGroup__
FilterCategory: __FilterCategory__
EditID: __EditID__
Submit: __Submit__
Cancel: __Cancel__

=0) strLibraryID = driverGetFieldAbsolute(drvWidgetMetadata,"Library_ID",intRecord) strName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) if ("__Action__"="Edit") strFilename = getToken("homedir")+"cache/WidgetEdit_"+strLibraryID+"_"+strName+".html" else strFilename = getToken("homedir")+"temporary_files/"+getSalt(24)+".$$$" endif if (not(fileExists(strFilename))) //get the contents of the widget strParams = "DocumentID="+strLibraryID+"&Widget="+strName+"&Text=true" strContent = scriptExec(Aspect_Common_getCachedWidget,true,strParams) if (startsWith(strContent,char(13)+char(10))) strContent = substring(strContent,2) else if (startsWith(strContent,char(10))) strContent = substring(strContent,1) endif endif //write the contents to a temp file fileWriteContent(strFilename,strContent) endif launchApplication(getToken("DefaultHtmlEditor"),"",false,quote(strFilename)) if ("__Action__"="View") scriptSleep(5000) fileDelete(strFilename) endif else appendToLog("Cannot locate widget with ID=__EditID__") endif ">
Confirm

Discard the widget named " =0) strName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) scriptSetResult(strName) endif "> "?

Any changes made to this widget will be lost.
=0) strLibraryID = driverGetFieldAbsolute(drvWidgetMetadata,"Library_ID",intRecord) strName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) strFilename = getToken("homedir")+"cache/WidgetEdit_"+strLibraryID+"_"+strName+".html" fileDelete(strFilename) endif ">
Confirm

Deploy the widget named "

Update the widget named " =0) strName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) scriptSetResult(strName) endif "> "?

User Name
Password

=0) strLibraryID = driverGetFieldAbsolute(drvWidgetMetadata,"Library_ID",intRecord) strName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) strDescription = driverGetFieldAbsolute(drvWidgetMetadata,"Description",intRecord) strGroup = driverGetFieldAbsolute(drvWidgetMetadata,"Group",intRecord) strCategory = driverGetFieldAbsolute(drvWidgetMetadata,"Category",intRecord) //locate the library cache document for the widget intRecord = driverFindRecordAbsolute(drvWidgetLibraryBuffer,0,"ID="+quote(strLibraryID)) if (intRecord>=0) strLibraryServer = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Library_Server",intRecord) boolIsSecure = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Is_Secure_Library",intRecord) strDocumentID = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"DocumentID",intRecord) //get the content of the widget strFilename = getToken("homedir")+"cache/WidgetEdit_"+strLibraryID+"_"+strName+".html" strContent = fileGetContent(strFilename) //strContent = tokenizeForPost(strContent,true) strContent = replaceSubstring(strContent,"&","%26") strContent = strContent + "___end_of_widget___" strArgs = "Network=Library&ID=acceptWidget" strArgs = strArgs + "&DocumentID="+strDocumentID strArgs = strArgs + "&user=__User__" strArgs = strArgs + "&pass=__Pass__" strArgs = strArgs + "&Widget="+tokenizeForPost(strName,true) strArgs = strArgs + "&Group="+tokenizeForPost(strGroup,true) strArgs = strArgs + "&Category="+tokenizeForPost(strCategory,true) strArgs = strArgs + "&Description="+tokenizeForPost(strDescription,true) strArgs = strArgs + "&Org="+tokenizeForPost(getToken("AspectOrganizationName"),true) strArgs = strArgs + "&Size="+len(strContent) strArgs = strArgs + "&Content="+strContent strResult = httpPost(strLibraryServer,"/",strArgs,-1,120000,true,boolIsSecure) //The library returns ok| followed by the modified library contents on success. This allows the new content to be cached immediately on the local machine if (startsWith(strResult,"ok|")) //delete the file used to edit the widget if (startsWith("__UpdateOnly__","__UpdateOnly")) fileDelete(strFilename) endif //save the new widget library in the cache strFilename = getToken("homedir")+"cache/widgetlib_"+strLibraryID appendToLog("writing result to "+strFilename) fileWriteContent(strFilename,substring(strResult,3)) //update the widget metadata scriptExec(Aspect_Common_Update_Widget_Library_Metadata,true,strLibraryID) strResult = "[div class='msg']The widget named "+quote(strName)+" has been deployed.[/div]" else strResult = "[div class='errmsg']There was a problem deploying the widget: "+strResult+"[/div]" endif else strResult = "[div class='errmsg']Cannot locate widget cache document with ID="+strLibraryID+"[/div]" endif else strResult = "[div class='errmsg']Cannot locate widget with ID=__EditID__[/div]" endif strResult = replaceSubstring(strResult,"[",char(0x3c)) strResult = replaceSubstring(strResult,"]",char(0x3e)) scriptSetResult(strResult) ">
Edit Widget Info
Widget Name
User Name
Password
Group
Category

Description

A URL pointing to the widget

Use this html to embed the widget as static content

Use this html to embed the widget as dynamic content the refreshes periodically

Use this html to embed the widget as a dynamic server-side widget

=0) strLibraryID = driverGetFieldAbsolute(drvWidgetMetadata,"Library_ID",intRecord) strName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) //get the contents of the widget strParams = "DocumentID="+strLibraryID+"&Widget="+strName+"&Text=true" strContent = scriptExec(Aspect_Common_getCachedWidget,true,strParams) strContent = replaceSubstring(strContent,"&","%26") strContent = strContent + "___end_of_widget___" //locate the library cache document for the widget intRecord = driverFindRecordAbsolute(drvWidgetLibraryBuffer,0,"ID="+quote("__WidgetLibrary__")) if (intRecord>=0) strLibraryServer = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Library_Server",intRecord) boolIsSecure = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Is_Secure_Library",intRecord) strDocumentID = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"DocumentID",intRecord) strArgs = "Network=Library&ID=acceptWidget" strArgs = strArgs + "&DocumentID="+strDocumentID strArgs = strArgs + "&user=__User__" strArgs = strArgs + "&pass=__Pass__" //strArgs = strArgs + "&Widget="+tokenizeForPost("__WidgetName__",true) strArgs = strArgs + "&Widget="+tokenizeForPost(strName,true) strArgs = strArgs + "&Group="+tokenizeForPost("__Group__",true) strArgs = strArgs + "&Category="+tokenizeForPost("__Category__",true) strArgs = strArgs + "&Description="+tokenizeForPost("__Description__",true) strArgs = strArgs + "&Org="+tokenizeForPost(getToken("AspectOrganizationName"),true) strArgs = strArgs + "&Size="+len(strContent) strArgs = strArgs + "&Content="+strContent strResult = httpPost(strLibraryServer,"/",strArgs,-1,180000,true,boolIsSecure) //The library returns ok| followed by the modified library contents on success. This allows the new content to be cached immediately on the local machine if (startsWith(strResult,"ok|")) //save the new widget library in the cache strFilename = getToken("homedir")+"cache/widgetlib_"+strLibraryID fileWriteContent(strFilename,substring(strResult,3)) //update the widget metadata scriptExec(Aspect_Common_Update_Widget_Library_Metadata,true,strLibraryID) strResult = "[div class='msg']The widget named "+quote(strName)+" has been updated in the library.[/div]" else strResult = "[div class='errmsg']There was a problem updating the widget: "+strResult+"[/div]" endif else strResult = "[div class='errmsg']Cannot locate widget cache document with ID=__WidgetLibrary__[/div]") endif else strResult = "[div class='errmsg']Cannot locate widget with ID=__EditID__[/div]" endif strResult = replaceSubstring(strResult,"[",char(0x3c)) strResult = replaceSubstring(strResult,"]",char(0x3e)) scriptSetResult(strResult) ">

Add a new widget
Widget Name
User Name
Password
Group
Category

Description


=0) strLibraryServer = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Library_Server",intRecord) boolIsSecure = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Is_Secure_Library",intRecord) strDocumentID = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"DocumentID",intRecord) strArgs = "Network=Library&ID=acceptWidget" strArgs = strArgs + "&DocumentID="+strDocumentID strArgs = strArgs + "&user=__User__" strArgs = strArgs + "&pass=__Pass__" strArgs = strArgs + "&Widget="+tokenizeForPost("__WidgetName__",true) strArgs = strArgs + "&Group="+tokenizeForPost("__Group__",true) strArgs = strArgs + "&Category="+tokenizeForPost("__Category__",true) strArgs = strArgs + "&Description="+tokenizeForPost("__Description__",true) strArgs = strArgs + "&Org="+tokenizeForPost(getToken("AspectOrganizationName"),true) strArgs = strArgs + "&Size="+len(strContent) strArgs = strArgs + "&Content=___end_of_widget___" strArgs = strArgs + "&New=true" strResult = httpPost(strLibraryServer,"/",strArgs,-1,120000,true,boolIsSecure) //The library returns ok| followed by the modified library contents on success. This allows the new content to be cached immediately on the local machine if (startsWith(strResult,"ok|")) //save the new widget library in the cache strFilename = getToken("homedir")+"cache/widgetlib___WidgetLibrary__" fileWriteContent(strFilename,substring(strResult,3)) //update the widget metadata scriptExec(Aspect_Common_Update_Widget_Library_Metadata,true,"__WidgetLibrary__") strName = replaceSubstring(tokenizeForPost("__WidgetName__",false),"+"," ") strResult = "[div class='msg']The widget named "+quote(strName)+" has been added to the library.[/div]" else strResult = "[div class='errmsg']There was a problem creating the widget: "+strResult+"[/div]" endif else strResult = "[div class='errmsg']Cannot locate widget cache document with ID=__WidgetLibrary__[/div]") endif strResult = replaceSubstring(strResult,"[",char(0x3c)) strResult = replaceSubstring(strResult,"]",char(0x3e)) scriptSetResult(strResult) ">

Confirm

Delete the widget named " =0) strName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) scriptSetResult(strName) endif "> "?

User Name
Password

=0) strLibraryID = driverGetFieldAbsolute(drvWidgetMetadata,"Library_ID",intRecord) strWidgetName = driverGetFieldAbsolute(drvWidgetMetadata,"Name",intRecord) strFilename = getToken("homedir")+"cache/WidgetEdit_"+strLibraryID+"_"+strName+".html" if (fileExists(strFilename)) fileDelete(strFilename) endif //locate the library cache document for the widget intRecord = driverFindRecordAbsolute(drvWidgetLibraryBuffer,0,"ID="+quote("__WidgetLibrary__")) if (intRecord>=0) strLibraryServer = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Library_Server",intRecord) boolIsSecure = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"Is_Secure_Library",intRecord) strDocumentID = driverGetFieldAbsolute(drvWidgetLibraryBuffer,"DocumentID",intRecord) strArgs = "Network=Library&ID=acceptWidget" strArgs = strArgs + "&DocumentID="+strDocumentID strArgs = strArgs + "&user=__User__" strArgs = strArgs + "&pass=__Pass__" strArgs = strArgs + "&Widget="+tokenizeForPost(strWidgetName,true) strArgs = strArgs + "&Org="+tokenizeForPost(getToken("AspectOrganizationName"),true) strArgs = strArgs + "&Size=0" strArgs = strArgs + "&Content=___end_of_widget___" strArgs = strArgs + "&Delete=true" strResult = httpPost(strLibraryServer,"/",strArgs,-1,120000,true,boolIsSecure) //The library returns ok| followed by the modified library contents on success. This allows the new content to be cached immediately on the local machine if (startsWith(strResult,"ok|")) //save the new widget library in the cache strFilename = getToken("homedir")+"cache/widgetlib___WidgetLibrary__" fileWriteContent(strFilename,substring(strResult,3)) //update the widget metadata scriptExec(Aspect_Common_Update_Widget_Library_Metadata,true,"__WidgetLibrary__") strResult = "[div class='msg']The widget named "+quote(strWidgetName)+" has been deleted.[/div]" else strResult = "[div class='errmsg']There was a problem deleting the widget: "+strResult+"[/div]" endif else strResult = "[div class='errmsg']Cannot locate widget cache document with ID=__WidgetLibrary__[/div]" endif else strResult = "[div class='errmsg']Cannot locate widget with ID=__EditID__[/div]" endif strResult = replaceSubstring(strResult,"[",char(0x3c)) strResult = replaceSubstring(strResult,"]",char(0x3e)) scriptSetResult(strResult) ">
'0')">
Library {@htmlSelect(Select_Widget_Libraries_By_Name,"WidgetLibrary","__WidgetLibrary__","onChange='javascript:updateWidgetList()'","","")} Group {@htmlSelect(Select_Widget_Library_Group,"FilterGroup","__FilterGroup__","onChange='javascript:updateWidgetList()'","","Library_ID=__WidgetLibrary__")} Category {@htmlSelect(Select_Widget_Library_Category,"FilterCategory","__FilterCategory__","onChange='javascript:updateWidgetList()'","","Library_ID=__WidgetLibrary__")}   Add a new Widget
'0')">

Widgets In __WidgetLibraryName__



__ServerTimerResults__