我使用 Liferay 6.1,我用代码创建了一个 portlet(链接:http ://www.liferay.com/community/wiki/-/wiki/Main/Using+Lifery+provided+Color+Picker+in+Own+Portlets )
<script type="text/javascript"> jQuery( function() { var colorPicker = new Liferay.ColorPicker( { hasImage: true } ); } ); </script>
<tr> <td> <input class="text-input" id="color" name="color" size="9" type="text" value="" />
<img align="absmiddle" alt="<liferay-ui:message key="color" />" border="0" class="use-color-picker" height="18" hspace="0" src="<%= themeDisplay.getPathThemeImages() %>/color.png" title="<liferay-ui:message key="color" />" vspace="0" width="18" style="cursor: pointer;" />
</input> </td> </tr>
但它不起作用,请帮助我:)