By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,902 Members | 4,597 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,902 IT Pros & Developers. It's quick & easy.

Call function based on path

P: n/a
Haven't programmed in quite a while and not sure of myself. I will be
given a web page based on the pathname, ie, /page1/page2/mypage. I
need to follow that pathname and execute the function called mypage().
It is used to dynamically generate web pages and, obviously, there are
other pages with different names.

So my thought is to examine the pathname and look it up in an array,
perhaps a hashtable, to see if it exists and call it. But then I'd
have to generate this array/table since pages and functions will change
on occasion. I'm wondering if I'm way off base and there's a much
easier way?

Dec 20 '06 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.