item_index_meta.tpl usage question

PatriaCo
PatriaCo
@the-patria-company
4 years ago
349 posts
QUICK NOTE: If you want to maximize your SEO start customizing the item_???_meta.tpl files. They are amazing. A big thanks to the JR team for this feature.

My question:
When I set a module as a profile quota's custom index page the item_index_meta.tpl is only called when the current_url contains the module_url. (ie https://mysite.com/profileName/moduleName) Is it possible to adjust the core to allow the item_index_meta.tpl to be called when the current_url only contains jamroom_url/profile_url (ie https://mysite.com/profileName)?

Rather than using Profile Tweaks, I have hard-coded the custom index pages for each quota; in order to avoid the redirects.

Thanks!


--
The Patria Company - patriaco.com / quality-trades.com / a-t.life - doing Jamroom since v3

updated by @the-patria-company: 06/06/20 10:16:53PM
PatriaCo
PatriaCo
@the-patria-company
4 years ago
349 posts
I do have a workaround for this, although it required duplicating the code with a conditional statement for the two scenarios stated above.

First, I added a condition in my top-level meta file for the first condition which expects the item_index_meta to inject the code. Then I added a condition for the second instance and used the {jrCore_include module="myCustomModule" template="item_index_meta.tpl"} to manually inject the template code. In the item_index_meta.tpl I had to set the first condition and use the data variables with $item. , but when the module_url is not present in the current_url (the second condition), I needed to remove the "item." from all the variable calls.

This is working for now, but if the core is ever updated to accommodate this, it would be appreciated.

Thanks!


--
The Patria Company - patriaco.com / quality-trades.com / a-t.life - doing Jamroom since v3
michael
@michael
4 years ago
7,744 posts
I'm finding it hard to visualize setup instructions, could you give some steps and a goal. Thanks.

Tags