Support » Plugin: Trigger Browsersync » Feature suggestion – Move to client side requests

  • Great plugin idea. The only problem is if we want to run this on a dev server in the wild, but we’re developing locally it doesn’t work. The plugin has the server WordPress is using do the request to BrowserSync, and that won’t get the right host when using ‘localhost’.

    The alternative would be to have a JavaScript function loaded client-side when using the WordPress admin dashboard, and you trigger that to do the request via ajax. That way localhost resolves properly to the computer that the user is using rather than the WordPress server.

    Please receive this suggestion with enthusiasm and pride! Although I can’t use it for my projects, it’s still a great idea and will help people.

Viewing 1 replies (of 1 total)
  • Plugin Author Patabugen


    That’s not a bad idea for your use case – I’m unlikely to add the functionality myself because I only ever use BrowserSync on my local network. I’d be happy to review a pull request (or a patch, or however these things work in SVN!) if you’re interested in sending one.

    As a workaround, you could use something like ngrok or Localtunnel to expose the local BrowserSync server to the Internet, then set the public address as the trigger_browsersync_host (and maybe change the port to 80 if those services don’t let you change it)

Viewing 1 replies (of 1 total)
  • The topic ‘Feature suggestion – Move to client side requests’ is closed to new replies.