You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@shindig.apache.org by "Ran Jiang (JIRA)" <ji...@apache.org> on 2012/04/27 10:04:07 UTC
[jira] [Commented] (SHINDIG-1552) UserPrefs are not available for
replacement in tag attribute values
[ https://issues.apache.org/jira/browse/SHINDIG-1552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13263496#comment-13263496 ]
Ran Jiang commented on SHINDIG-1552:
------------------------------------
After adding the following configuration in the shindig.properties, the UserPrefs can be replaced in tag attribute and also work well with gadget userprefs API.
shindig.urlgen.use-templates-default=false
Both UserPrefs defined in RenderParams and gadget definition can work successfully.Can not reproduce this JIRA.
I paste my test gadget.
<Module>
<ModulePrefs title="Test Gadget"
height="250">
</ModulePrefs>
<UserPref name="mycss" default_value="testGadgetCSS" datatype="string" display_name="testGadgetCSS"></UserPref>
<UserPref name="myjs" default_value="testGadgetJS" datatype="string" display_name="testGadgetJS"></UserPref>
<Content type="html">
<![CDATA[
<html>
<head>
<link rel="stylesheet" type="text/css" href="css/__UP_mycss__/testGadget.css">
<script type="text/javascript" src="js/__UP_myjs__/testGadget.js"></script>
<script type="text/javascript">
var prefs = new _IG_Prefs();
console.dir(prefs);
var mycss = prefs.getString("mycss");
console.log("UserPref mycss value : " + mycss);
console.log("test_script_link : " + test_script_link);
</script>
</head>
<body>
<div id="area1">
Test area! <br/>
UserPref mycss value : __UP_mycss__ <br/>
</div>
<div id="abcd__UP_mycss__">
</div>
</body>
</html>
]]>
</Content>
</Module>
> UserPrefs are not available for replacement in tag attribute values
> -------------------------------------------------------------------
>
> Key: SHINDIG-1552
> URL: https://issues.apache.org/jira/browse/SHINDIG-1552
> Project: Shindig
> Issue Type: Bug
> Components: Java
> Affects Versions: 2.0.0
> Reporter: Dan Dumont
> Fix For: 2.0.3
>
>
> The spec states that the user prefs are available for replacement anywhere in the gadget definition.
> However, a user preference will not be replaced in this case:
> <link href="themes/__UP_theme__/theme.css" rel="StyleSheet" type="text/css"></link>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira