joejac
Posts: 242
|
| Posted: 02/10/2008, 8:45 AM |
|
Hello,
I have a page that is been generated with the names of child categories under the parent category that is passed to the page via a parameter con the URL like this:
/menu.php?category_no=9
On menu page I display category_name for all corresponding child categories of parent category, in this case No 9.
I want all these category names to be placed in the meta keywords separated by ", " for menu.php so I use the solution from this post:
http://forums.yessoftware.com/posts.php?post_id=72791
Unfortunately if I have for example 6 child categories, I get on the meta keyword only the last one, so I miss the other 5 category names. I do not know how can I create an array, in perhaps the Before Show event, assign the value of this array to {category_name} and pass it to the meta keywords in the menu.html template.
Any detailed solution with its code is greatly appreciated.
Thanks a lot and best regards
joejac
|
 |
 |
JayEdgar
Posts: 77
|
| Posted: 02/10/2008, 5:15 PM |
|
Whatever you do, you probably want to do it in the After Page Initialize event.
Cheers,
Jay
|
 |
 |
joejac
Posts: 242
|
| Posted: 02/11/2008, 4:19 AM |
|
Thanks JayEdgar,
Any suggestion with the possible code to accomplish this? I am a beginner :)
Regards
joejac
|
 |
 |
JayEdgar
Posts: 77
|
| Posted: 02/11/2008, 5:03 AM |
|
I have no idea if this will work, and this is what I'd try:
*Go into HTML view
*Remove entire <meta> or whatever tag.
*Add a label, give it an appropriate name
*add code to the 'before show' event for the label. I'm not sure how you'll access the label without accessing a formname first - hit $ and it should show up in the intellisense.
If you find the label name in the intellisense, I give it an 80% chance of working. If not, 40%.
Good luck,
Jay
|
 |
 |
|