I know this has been asked several times before, but I was wondering if anyone has been able to create a user macro that can add a label to a page.
I am working with some work request pages, which are predefined templates. One of those pages is designed to identify product impacts. So, what I want to do is provide users with several checkboxes that represent the product pages, which maintain all documentation for a given product (we have multiple products).
If the user checks the box, the product label is applied to the product impacts page. If I could somehow apply the work request label to the product page also, that would be really cool, but I'm not sure if that's possible.
I'm a new Confluence user, so please be gentle.
Thank you!
You might find your answer here: https://answers.atlassian.com/questions/22344/how-do-i-add-labels-to-a-page-using-a-user-macro
I tried that and while it provides a full list of labels, it doesn't support what I need to do. I may be a ble to take the actual attach label piece from it, but that still leaves the other part of creating the checkbox, where if selected the label is attached and if deselected, the label is removed. I'm a very inexperienced user so, I apologize for my ignorance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Another issue I'm having is keeping the checkboxes checked. Right now, when I leave the page, everything resets. Any suggestions?
## @noparams
<script>
function check()
{
document.getElementById("check1").checked=true
}
function uncheck()
{
document.getElementById("check1").checked=false
}
</script>
<table>
<tbody>
<tr>
<td colspan="7"><form>
<input type="checkbox" id="check1">HWTX
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">HWMB
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">HCFG
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">IBBA
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">MIDR
</form></td>
</tr>
<tr><td colspan="7"><form>
<input type="checkbox" id="check1">HWPS
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">EWTX
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">EFDE
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">DOCO
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">PREA
</form></td>
</tr>
<tr>
<td colspan="7"><form>
<input type="checkbox" id="check1">FRNT
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">HREP
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">SYSA
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">JAVP
</form></td>
<td colspan="7"><form>
<input type="checkbox" id="check1">T3RT
</form></td>
</tr>
</tbody>
</table>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.