/    Sign up×
Community /Pin to ProfileBookmark

Show/Hide Dynamically Generated Items

I have a dynamically generated list of items (they can span numerous pages). I need to be able to show/hide items based on a user’s selections (i.e., show only those that I have selected).

Alternatively I could pass selected items to a new page.

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@The_Little_GuyMay 13.2006 — [CODE]<script type="text/javascript">
var disable_empty_list = true;
</script>[/CODE]

[CODE]<script>
addListGroup("links", "category");


addOption("category", "Select a category", "");
addList("category", "Cars", "Adult", "adult");
addList("category", "Artistic", "Artistic", "artistic");

addOption("adult", "GTO", "GTO", "");
addOption("adult", "FireBird", "FireBird", "");
addOption("adult", "BMW", "BMW", "");

addOption("artistic", "Acting", "Acting", "");
addOption("artistic", "Architecture", "Architecture", "");
addOption("artistic", "Art History", "Art History", "");
addOption("artistic", "Arts", "Arts", "");

</script>[/CODE]

[code=html]<select name="menu1" style="width:180px"></select>
<select name="subcat" style="width:180px" onchange="openLink(this.value)"></select>[/code]


And you will need the attached file as well, its long, so you probably want to use this to link too it.
[CODE]<script type="text/javascript" src="chainedselects.js"></script>[/CODE]

[upl-file uuid=46d16970-fb05-4c09-94c0-1fa5bff00afa size=16kB]js.txt[/upl-file]
×

Success!

Help @jdog65 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.28,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...