BV Commerce Forum
»
BV Commerce Support
»
General Support
»
Help with error: Meta tags on customized pages.
Rank: Member
Joined: 12/19/2006(UTC) Posts: 153
|
We have created a page in the site root (used custom.aspx as a template) and are calling upon a specific master page and calling specific contentcolulumncontrols, thus displaying some content colomns together with some static content. (There were some limitations in using the default 'custom page' functionality, so we are using a static template to start.)
I can get the page title to populate dynamlically with "PageTitle = Content.SiteTerms.GetTerm("CustomizedTitle")" , but am having trouble with the meta tags. Specifically the error is : Only Content controls are allowed directly in a content page that contains Content controls.
So how to populate the meta tags? (Ideally from tags stored in site terms.) I've had no luck from within the page or master page.
Any tips to steer me in the correct direction. Thanks much!
|
|
|
|
Rank: Member
Joined: 4/10/2009(UTC) Posts: 120 Location: Mechanicsville, VA
Thanks: 3 times Was thanked: 1 time(s) in 1 post(s)
|
Are these meta tags specific to this page only... you can use...
Me.MetaDescription = "xxx" Me.MetaKeywords = "xxx" |
Tim
|
|
|
|
Rank: Member
Joined: 4/10/2009(UTC) Posts: 120 Location: Mechanicsville, VA
Thanks: 3 times Was thanked: 1 time(s) in 1 post(s)
|
or...
Me.MetaDescription = p.MetaDescription Me.MetaKeywords = p.MetaKeywords
Where p is the page and would be pulled from the content in the database. |
Tim
|
|
|
|
Rank: Member
Joined: 12/19/2006(UTC) Posts: 153
|
Got it. I tried what you said before, but just couldn't get it to work (As it turns out the code behind for custom.aspx doesn't have a page_load event, only page_init and page_preinit. Added in page _load with those tags, and it did the trick.) Thanks!
|
|
|
|
Rank: Member
Joined: 4/10/2009(UTC) Posts: 120 Location: Mechanicsville, VA
Thanks: 3 times Was thanked: 1 time(s) in 1 post(s)
|
Odd... I pulled those lines directly from my custom.aspx.vb. Maybe I made that change a while back and don't remember it. |
Tim
|
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.