diff --git a/jappixmini/jappixmini.php b/jappixmini/jappixmini.php index df0d474e4..f5ed71c72 100644 --- a/jappixmini/jappixmini.php +++ b/jappixmini/jappixmini.php @@ -221,8 +221,8 @@ function jappixmini_settings(&$a, &$s) { $activate = get_pconfig(local_user(),'jappixmini','activate'); $activate = intval($activate) ? ' checked="checked"' : ''; - $insertchat = get_pconfig(local_user(),'jappixmini','insertchat'); - $insertchat = intval($insertchat) ? ' checked="checked"' : ''; + $dontinsertchat = get_pconfig(local_user(),'jappixmini','dontinsertchat'); + $insertchat = !(intval($dontinsertchat) ? ' checked="checked"' : ''); $username = get_pconfig(local_user(),'jappixmini','username'); $username = htmlentities($username); @@ -268,8 +268,8 @@ function jappixmini_settings(&$a, &$s) { $s .= ''; $s .= ' '; $s .= '
'; - $s .= ''; - $s .= ''; + $s .= ''; + $s .= ''; $s .= '
'; $s .= ''; $s .= ' '; @@ -384,7 +384,7 @@ function jappixmini_settings_post(&$a,&$b) { set_pconfig($uid,'jappixmini','autosubscribe',intval($b['jappixmini-autosubscribe'])); set_pconfig($uid,'jappixmini','autoapprove',intval($b['jappixmini-autoapprove'])); set_pconfig($uid,'jappixmini','activate',intval($b['jappixmini-activate'])); - set_pconfig($uid,'jappixmini','insertchat',intval($b['jappixmini-insertchat'])); + set_pconfig($uid,'jappixmini','dontinsertchat',intval($b['jappixmini-dont-insertchat'])); set_pconfig($uid,'jappixmini','encrypt',$encrypt); info( 'Jappix Mini settings saved.' ); @@ -401,8 +401,8 @@ function jappixmini_script(&$a,&$s) { if(! local_user()) return; $activate = get_pconfig(local_user(),'jappixmini','activate'); - $insertchat = get_pconfig(local_user(), 'jappixmini','insertchat'); - if (!$activate or !$insertchat) return; + $dontinsertchat = get_pconfig(local_user(), 'jappixmini','dontinsertchat'); + if (!$activate or $dontinsertchat) return; $a->page['htmlhead'] .= ''."\r\n"; $a->page['htmlhead'] .= ''."\r\n";