• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Bear Bibeault
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Jj Roberts
  • Tim Holloway
  • Piet Souris
Bartenders:
  • Himai Minh
  • Carey Brown
  • salvin francis

Dynamically assign ID to hyperlink

 
Ranch Hand
Posts: 2051
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I run jQuery and return a set of values. I want to use one of these values as the ID of a hyperlink created after the jQuery call runs.

my returned value is wResults.iNumber

my hyperlink
'<A href="#" id=wResults.iNumber onclick="accessEditForm(this.id)">Edit</A>'

How can I get the hyperlink to read the value of the wResults.recseq variable?
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Set the attribute?



I am not sure what youa re doing, maybe some more code would shed more light on your question.

Eric
 
Marshal
Posts: 67478
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have no idea what you are asking. What's wResults.recseq and what does it mean to "read" it?

And, you are using jQuery, yet have onclick attributes in your HTML?
 
Well THAT's new! Comfort me, reliable tiny ad:
the value of filler advertising in 2020
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic