title: open new window for fb login
body: <p>I want to login my user in my chatbox using fb. My chatbox is a shareable to other websites using javascript. </p>
  
  <p>I want to do is, when a user click to a button "FB Login" it will open a window for fb login. then the user will accept the permissions, then.. it will be login to my chatbox. </p>
  
  <p>My problem is, how the chatbox know if the user is logged in? a trigger event for this login? 
  so that the chatbox is going to execute init(); for the change of the button
  (change login Button --> logout button).. </p>
  
  <p>My way is, first, user visit to a website(others website with my chatbox using javascript) --> chatbox run init()[a function that display the name of the chatbox, user name, and then the button login, if the user is logged in before the init() run, the button is logout]  --> if the user login, javascript will open a php file that redirect to the link of facebook login --> user permission accepted, the button will automatically changed from login to logout.. same as logging out. the button will change from logout to login</p>