Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Working with plugins that do their own routing #199

Closed
desmillicious opened this issue Oct 12, 2015 · 1 comment
Closed

Working with plugins that do their own routing #199

desmillicious opened this issue Oct 12, 2015 · 1 comment
Labels
wordless<2-deprecation Since release of Webpack-based Wordless2, need to close older issues

Comments

@desmillicious
Copy link

Hi there I am working with a plugin - Time.ly Event Calendar - that does it's own routing.

The routing is non-standard with it's own MVC framework, db tables and php on the fly generated views for it's custom post type ai1ec_event. There is no static php template for a particular view that I can point to for the ai1ec_event single post view, which is what I have done in the past to handle e-commerce

Is there a way to revert to wordpress routing for specific views?

eg: in index.php of the wordless theme...

if (is_singular() && is_post_type("ai1ec_event")) {
   revert to wordpress routing
}
@alessandro-fazzi
Copy link
Member

Oh gosh! Never ever thought about such a situation...but: Wordless shouldn't alter the wordpress routing per se: it uses conditional tags based on the Wordpress routing just to print on screen. Default themes usually have a get_template_part() in the index.php, while we have a custom render function.

<lucubration>

Usually plugins such that - but I don't know Time.ly at all, so sorry if Im wrong - hooks themselves to something like the_content()...I see from the documentation of the plugin that it has builtin shortcodes support. Why don't you try to build a template with a simple do_shortcode() function inside or a the_content() dropping the shortcode in the the page editor?

I can't see more than this lurking into the documentation on the page you linked.

[EDIT]
I'd try also a template with a super dirty inclusion of the plugin's main file! :embarrassing:

</lucubration>
Cheers

@alessandro-fazzi alessandro-fazzi added the wordless<2-deprecation Since release of Webpack-based Wordless2, need to close older issues label Sep 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wordless<2-deprecation Since release of Webpack-based Wordless2, need to close older issues
Projects
None yet
Development

No branches or pull requests

2 participants