Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Confiforms: Modification of link text from links field

I have a form with a link field where URLs will be pasted in. In views I do not want to have the (rather long) URL shown, but either a standard text or icon (e.g. "Weblink") or a text which the registration user has to enter in the form. 

Is that possible and if yes, how? 
Currently the link field will just take the original link into views. 

Thanks for hints :) 

1 answer

1 accepted

You can have a ConfiForms field macro with field name set to use asLink function.

https://wiki.vertuna.com/display/CONFIFORMS/Virtual+functions

Assuming your field is called "mylink" then you will need to put into field name parameter something like

mylink.asLink(Weblink)

perfect (y) 

I am trying to use this method but it is is showing 'weblink' even when link is not provided by the user and record is empty.

Hi

May I see how are you using this?

Alex

Like Amir likes this

I ma using it inside the "Field" macro in TableView macro, here is how Field macro looks like..

 

Capture.PNG

Unless you are using some very old ConfiForms version it should work

Quick test from me: http://recordit.co/5uHh1WixP0 

Like Amir likes this

A-ha, you are saying that the "weblink" label is generated EVEN when there is no value in the docLink field. I see now!

We will fix this asap

Like # people like this

Exactly, Thank you.

Alex, any update on this?

"A-ha, you are saying that the "weblink" label is generated EVEN when there is no value in the docLink field. I see now!"

This has been fixed the same month we had this discussion

Alex

Like Amir likes this

I have my definition as

<ac:structured-macro ac:macro-id="65caec94-3803-41c3-bcf0-8873cd064e56" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">Hyper</ac:parameter>
<ac:parameter ac:name="fieldLabel">URL</ac:parameter>
<ac:parameter ac:name="fieldDescription">URL if exists</ac:parameter>
<ac:parameter ac:name="type">link</ac:parameter>

and the field set up as

<ac:structured-macro ac:macro-id="317838c7-caea-4f4a-b1e9-449e2b448e30" ac:name="confiform-field" ac:schema-version="1">
<ac:parameter ac:name="hideIfEmpty">true</ac:parameter>
<ac:parameter ac:name="messageToShowWhenEmpty"/>
<ac:parameter ac:name="fieldName">Hyper.asLink(Link)</ac:parameter>

 

Every record shows Link

Based on your answer timeline it looks like the fix would have been Feb-March. I will check with my admin on the last time it was updated.

That looks correct (configuration). Please check what ConfiForms version you are using and update if not on latest

Alex

Like Amir likes this

Update did resolve the issue

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Confluence

Confluence Mythbusters: Does Atlassian even use Confluence?

Hi, Confluence collaborators! As part of #Confluence-Collaboratory month, we’ve created a very special Mythsbusters segment, where we're dive into an interesting myth and uncover the truth behind i...

1,359 views 7 28
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you