Link to home
Start Free TrialLog in
Avatar of Allan
AllanFlag for United States of America

asked on

Create Anchors From List

Hi experts!

Say I have a list that contains this:

User generated image
and to make it common delimited I do this:

var tags = String.Join(", ", myPost.tags);

Open in new window


and the results for this:
Tags: @tags

Open in new window

is Tags: bike, bicycle

however, how would you make bike and bicycle or whatever in myPost.tags list into anchors and passed as into the querystring?

so, each anchor would look like this:
*xxxx is from the list

<a href="@Href("~/mypage/search?r=xxxx")" class="lnk">xxxx</a>

Open in new window


Any ideas?
ASKER CERTIFIED SOLUTION
Avatar of Kiran Sonawane
Kiran Sonawane
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Allan

ASKER

my bad sonawanekiran; I didn't mention this is for mvc razor..
you gave me some good ideas I will try later after getting some zzzzzz... tired..

will let you know and thanks again.
Avatar of Allan

ASKER

Thanks!