You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

How to call Bots.render manually.

Received Response
17
Views
1
Comments
edited Aug 15, 2019 4:45PM in Digital Assistant and Mobile 1 comment

Summary

i want to use carousel in my bot. i used bot.render even embedded mode is true. still bot is not working. please help me out on this. thanks

Code Snippet

 <?php
 session_destroy();
         session_start();
         unset($_SESSION['use']);
         $_SESSION['use']=$_POST['user'];
?>
<html>
  <head>
     <script type="text/javascript" >
    !function(e,t,n,r){
        function s(){try{var e;if((e="string"==typeof this.response?JSON.parse(this.response):this.response).url){var n=t.getElementsByTagName("script")[0],r=t.createElement("script");r.async=!0,r.src=e.url,n.parentNode.insertBefore(r,n)}}catch(e){}}var o,p,a,i=[],c=[];e[n]={init:function(){o=arguments;var e={then:function(t){return c.push({type:"t",next:t}),e},catch:function(t){return c.push({type:"c",next:t}),e}};return e},on:function(){i.push(arguments)},render:function(){p=arguments},destroy:function(){a=arguments}},e.__onWebMessengerHostReady__=function(t){if(delete e.__onWebMessengerHostReady__,e[n]=t,o)for(var r=t.init.apply(t,o),s=0;s<c.length;s++){var u=c[s];r="t"===u.type?r.then(u.next):r.catch(u.next)}p&&t.render.apply(t,p),a&&t.destroy.apply(t,a);for(s=0;s<i.length;s++)t.on.apply(t,i[s])};var u=new XMLHttpRequest;u.addEventListener("load",s),u.open("GET",r+"/loader.json",!0),u.responseType="json",u.send()
    }(window,document,"Bots", "http://xxxxxxxx.com/static/");

        var myname = <?php echo $_SESSION['use'] ;?>;
//      alert(<?php echo $_SESSION['use'] ;?>);
     </script>
  </head>

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!