Forum Replies Created

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter pablomon

    (@pablomon)

    Thanks for your answer @gappiah

    I guess I will end up making a webview myself then.

    Cheers

    Thread Starter pablomon

    (@pablomon)

    Ok. For anyone following this thread I made a similar question in the adequate forum as Steven sugested. Here is the link

    Thread Starter pablomon

    (@pablomon)

    Thanks for your answer @sterndata.

    I took a look at the plugin but since I am using elementor I can’t wrap parts of my code with the shortcode.

    Then I came across wp_is_mobile function.
    Since I only need to serve different content in a few different pages I think I might be able to get around it by combining template_redirect and wp_is_mobile like so:

    add_action( 'template_redirect', 'mobile_redirect' );
    function mobile_redirect()
    {
      if (wp_is_mobile())
      {
        if ( is_singular( 'teachers' ))
        {
          // how to redirect using a different elementor template ?
        }
      }
    }

    Does this make sense?

    • This reply was modified 4 years, 2 months ago by pablomon.
    Thread Starter pablomon

    (@pablomon)

    Hi @bcworkz,

    Thanks for your answer. Let me elaborate further.

    When the user creates a “course” post on the frond end I want to be able to capture that information and use it to create the “lessons” automatically. The lessons would inherit the title, content, featured image, a taxonomy and some metas.
    Likewise if the users edit a course, I want to transmit those changes to the children posts I automatically.

    My idea was to listen for any change on the specific post type ( its a product post type ) and then check wether its being updated or created hooking to save_post_{$post_type}. But this could just be a completely wrong approach?

    I am totally new to wordpress so please forgive the terminology I am using.

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)