Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 193504

Page css style disappeared in Orchestrator Configuration

$
0
0

Hey all,

 

I am new to vCO and JSP. Now I am coding a config page on that user can upload files.

The code looks like:

 

<s:form action="SaveInstance" method="POST" validate="true"  enctype="multipart/form-data" onsubmit="return checkAddress();">

     <input type="file" name="filename" value="file.name" />

  

     <tr>

     <td><s:submit type="input" name="submitButton"

       key="save.button" />

      <s:submit type="input" name="submitButton" value="Cancel"

       onclick="javascript:cancelForm('click')" />

     </td>

    </tr>

  

     <s:hidden name="onCancelClicked" value="" />

</s:form>

 

function cancelForm(fieldVal) {

  document.forms[0].onCancelClicked.value = fieldVal;

}

 

When clicking the "Cancel" or "Save" button, page will navigate back.

 

Action class:

if ((this.onCancelClicked != null)

      && (this.onCancelClicked.equals("click"))) {

     return "cancel";

    }

 

However when navigating back, the destination page css style is disappeared.

The url changes from https://myip/config_general/General.action to https://myip/myplugin/SaveInstance.action.

b.png

Below is the correct screenshot as expected. Note that the left function selection is disappeared either.

a.png

 

I trid to remove enctype="multipart/form-data" from the form tag, and the page style was back, but upload function cannot work.

 

I am appreciated if anybody has the idea of this problem.


Viewing all articles
Browse latest Browse all 193504

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>