Scott C. said: This is not possible and indeed, if you will consider it more deeply, is not desired. The point of attributes is that you can reference them safe in the knowledge that they will be the same for any given character. If each character could have their fightingspecialty attribute be a different name, then you could not create macros that would work for all characters (which is really the point of the html/css character sheets). What benefit are you looking for that a dynamic name would help with? Maybe there is another way to attack it. Well one of the reasons I am trying to do it and it makes it desirable to me is because I use text inputs at the moment and have 72 "special" attributes. between I think 19 skills. So to make it easier I wanted to do a drop down so all the user has to do is click on the special attribute and move on. While text works great it causes a mess of extra attributes for the name they input plus the attribute for the skill in the attributes tab. While hiding attributes is the easy way to do it for me code wise, it would be a hassle for them making macros because at that point I'm retyping stuff the sheet has already. Would be user friendly and look better just to have the attribute match the name on the drop down list. That and I could not figure out how to do it and know there has to be a way lol. I may never use it though. GM Knowledge Rhino said: I'm trying to see if there is a way to setup my code in a way that make an attribute name with what ever the user selects from a drop down list. I was hoping to use this in place of a generic one size fit all attribute. Scott C. said: Aye, that is a work around, but you still don't have a dynamically named attribute. The name of attr_customskillname1 does not change, just its value. It accomplishes the original goal, ignoring that the "wording of the request" was different than the actual goal that was intended. If you want to be more "exactly accomplishing what is in the text" that is also not that hard, but would require an API script and just pipe the <select name=""> through the javascript to allow for "attr_" + "@{x} + @{y} It is not impossible and indeed my code does this in the API as well. function buildReplacementObject(title, src, size) {
return { matcher: new RegExp("\\$" + title.toUpperCase() + "\\$", "g"), replacer: '<img src="' + src + '" title="' + title + '" height="' + size + '" width="' + size + '"/>' };
}
So it can be done, I lack the java know how to really accomplish this yet but it sets me on the right track. I might have to enlist the help of someone with more skill than me at this to accomplish the task but at least I can point them in the right direction.. Thanks!!