Please forgive me, I’m a bit of a newbie.
I understand how to create an Array and then perform a function on the Array elements that meet a criteria, but I need to create an Array of items that meet a specified criteria (the criteria being the CSS style [B]display:block
Once I have that Array, I want to be able to perform a function on the LAST element in the Array. I’m not quite sure how to do that.
I have several DIV elements on a page, which most are hidden using [B]display:none
I want the last visible DIV to be of a style different than the previous DIVs. Also, if I have several DIVs displayed and I go up and click a different option in an earlier step, I need all DIVs after that one to change style back to “display:none”.
Any help would be greatly appreciated.
Thanks.