From 6f12de990a462ffec7b6f6d5c70abff4199f8f88 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Wed, 16 Jul 2014 00:11:48 +0500 Subject: [PATCH] hash dial take 2 --- html5/verto/demo/verto.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/html5/verto/demo/verto.js b/html5/verto/demo/verto.js index 393641dc5d..e4017e7dcb 100644 --- a/html5/verto/demo/verto.js +++ b/html5/verto/demo/verto.js @@ -366,8 +366,24 @@ function init() { } $(document).ready(function() { + var autocall = false; + var hash = window.location.hash.substring(1); + + if (hash && hash.indexOf("page-") == -1) { + window.location.hash = ""; + autocall = true; + } + init(); + $("#page-incall").on("pagebeforechange", function(event) {}); + + if (autocall) { + $("#ext").val(hash); + $("#callbtn").trigger("click"); + } + + }); $(document).bind("pagebeforechange", function(e, data) {