FreiChat related discussions
Freichat Offline by default

Hey ,

I would like to have Freichat status Offline by default.
Do you know which file/line I should change to get that done ?

Thanks !

Hey , I would like to have Freichat status Offline by default. Do you know which file/line I should change to get that done ? Thanks !

You can programmatically make freichat to go offline by running the follwing line of javascript after freichat is loaded

FreiChat.freichatopt('goOffline');
You can programmatically make freichat to go offline by running the follwing line of javascript after freichat is loaded ```` FreiChat.freichatopt('goOffline'); ````
Necessity is the mother of all inventions!

I have already tryed that after the initialisation script of freichat but it does not change anything.

If i just do a <script> FreiChat.freichatopt('goOffline');<script> after Freichat is launched it doesn't work !

Thanks.

I have already tryed that after the initialisation script of freichat but it does not change anything. If i just do a &amp;lt;script&amp;gt; FreiChat.freichatopt(&#039;goOffline&#039;);&amp;lt;script&amp;gt; after Freichat is launched it doesn&#039;t work ! Thanks.

Same with a jQuery(document).ready(function()
{FreiChat.freichatopt('goOffline'); });

Same with a jQuery(document).ready(function() {FreiChat.freichatopt(&#039;goOffline&#039;); });

Ok there is the solution:

<script type="text/javascript" language="javascipt">
<!--//--><![CDATA[//><!--

jQuery(document).ready(function() {
function blah () { FreiChat.freichatopt('goOffline') }

setTimeout(blah, 1000);

});
//--><!]]>
</script>

Ok there is the solution: &amp;lt;script type=&quot;text/javascript&quot; language=&quot;javascipt&quot;&amp;gt; &amp;lt;!--//--&amp;gt;&amp;lt;![CDATA[//&amp;gt;&amp;lt;!-- jQuery(document).ready(function() { function blah () { FreiChat.freichatopt(&#039;goOffline&#039;) } setTimeout(blah, 1000); }); //--&amp;gt;&amp;lt;!]]&amp;gt; &amp;lt;/script&amp;gt;

Using that code, I can still see Freichat start online, and then go offline. Isn't there any way to start Freichat completely offline?

Using that code, I can still see Freichat start online, and then go offline. Isn&#039;t there any way to start Freichat completely offline?

In that code, you can modify the delay and set it to 0 instead:

setTimeout(blah, 0);
In that code, you can modify the delay and set it to 0 instead: ``` setTimeout(blah, 0); ```

We have many jQuery document.ready's on our pages. If I set it to 0, Freichat doesn't go offline. But I see what you mean.

We have many pageviews. It would be nice to have Freichat loaded, but starting on request. Would that be possible?

We have many jQuery document.ready&#039;s on our pages. If I set it to 0, Freichat doesn&#039;t go offline. But I see what you mean. We have many pageviews. It would be nice to have Freichat loaded, but starting on request. Would that be possible?

It would be nice to have Freichat loaded, but starting on request. Would that be possible?

You can make the code run

FreiChat.freichatopt('goOffline')

just after freichat is loaded, by adding it to the function selfInvoke() in the file client/freichat.js

&amp;gt; It would be nice to have Freichat loaded, but starting on request. Would that be possible? You can make the code run ``` FreiChat.freichatopt(&#039;goOffline&#039;) ``` just after freichat is loaded, by adding it to the function selfInvoke() in the file client/freichat.js
410
8
2
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft