The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

staff online code

+2
Derri
BetterHax
6 posters

Go down

staff online code Empty staff online code

Post by BetterHax May 12th 2013, 1:54 pm

hello what is the code of this?

http://prntscr.com/14j9le

i saw this design and i want to know the code of it..
i want to add it in my widgets in my forum
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Derri May 12th 2013, 1:59 pm

There is a link to an avacaweb tutorial found in this thread, https://help.forumotion.com/t115845-view-online-staff-in-a-widget

Try this,
Derri
Derri
Helper
Helper

Male Posts : 8755
Reputation : 638
Language : English & Basic French
Location : Scotland, United Kingdom

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 12th 2013, 2:14 pm

Derri wrote:There is a link to an avacaweb tutorial found in this thread, https://help.forumotion.com/t115845-view-online-staff-in-a-widget

Try this,

hello derri can you give me the correct code?
its to many code posted on avac.. and i dont know were can i put those code
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 12th 2013, 8:53 pm

bump
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Sewer May 12th 2013, 8:58 pm

@better you put the code in CSS
Sewer
Sewer
Forumember

Posts : 35
Reputation : 1
Language : English

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 12th 2013, 9:02 pm

Sewer wrote:@better you put the code in CSS

can you give me the code on it?
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 12th 2013, 9:12 pm

You are using phpBB2, no?
If so, add this as a new widget (Administration Panel -> Modules -> Forum Widgets management -> Create a Widget)...

Code:
<div id="onlineStaff">
<span class="staffname">Admin 1 Username</span>
<span class="staffname">Admin 2 Username</span>
<span class="staffname">Moderator 1 Username</span>
<span class="staffname">Moderator 2 Username</span>
</div>
<!-- and so on... replace everything between <span> and </span> with the actual usernames of your staff -->
<script type="text/javascript"> jQuery(function() { var x = document.getElementById('right').getElementsByTagName('table')[9]; var y = document.getElementById('onlineStaff').getElementsByTagName('span'); for (i=0; i<y.length; i++) { if (x.innerHTML.indexOf(y[i].innerHTML) > 0) y[i].innerHTML+=" - Online"; else y[i].innerHTML+=" - Offline"; } }); </script>


Last edited by Ultron's Vision on May 12th 2013, 9:34 pm; edited 1 time in total
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 12th 2013, 9:18 pm

yes im using phpbb2.
that code work in my forum version?

i try using that code and see the result. http://prntscr.com/14m7by
i want something like in my first post exactly some as that..


Last edited by BetterHax on May 12th 2013, 9:24 pm; edited 2 times in total
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 12th 2013, 9:22 pm

Some additional info which I forgot to mention before...

That widget I posted above must be placed above any other widgets on the right side, then place the 'Who is Online' default widget (provided to you by forumotion) directly underneath the new widget.

You can move widgets around with simple Drag and Drop methods Wink
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 12th 2013, 9:24 pm

i try using that code and see the result. http://prntscr.com/14m7by
i want something like in my first post exactly some as that..
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 12th 2013, 9:28 pm

You need to replace Admin 1 Username etc. with actual usernames, like, assuming I was staff on your forum, you would put <span class="staffname">Ultron's Vision</span>, for your name, put <span class="staffname">BetterHax</span> and so on.
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 12th 2013, 9:32 pm

yea i already replace that.. but the result is like the picture a posted awhile ago.. i want something exactly same in my first post picture..

name + online and offline logo beside it
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 12th 2013, 9:37 pm

I edited my code a little.

To display an icon instead of text, replace ' - Offline' and ' - Online' respectively with html img tags. A basic example for an image is following:

Code:
<img src="http://example.iana.org/example.jpg" />

Search on Google for On-/Offline Icons (the icon part is crucial as you do not want huge images to appear after the name) and insert their URLs in the src="..." part of the <img /> tag Smile
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by SLGray May 12th 2013, 9:41 pm

BetterHax wrote:
Derri wrote:There is a link to an avacaweb tutorial found in this thread, https://help.forumotion.com/t115845-view-online-staff-in-a-widget

Try this,

hello derri can you give me the correct code?
its to many code posted on avac.. and i dont know were can i put those code

BetterHax wrote:bump
Please don't double/triple post. Your post need to be separated by 24 hours before bumping, replying or adding more information. Please use the edit button instead!

Second Reminder


staff online code Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51463
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 13th 2013, 4:59 am

by BetterHax Yesterday at 8:14 pm , by BetterHax Today at 2:53 am

hello think im not double posting kindly see the time when i bump Very Happy
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Jophy May 13th 2013, 5:03 am

It's actually not exactly separated by 24 hours. Please follow the rules.

This message doesn't require a reply. Thanks.
Jophy
Jophy
ForumGuru

Male Posts : 17924
Reputation : 836
Language : English
Location : Somewhere

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 13th 2013, 1:19 pm

ahhh ok sir jophy i understand what you saying..
anyone help me?
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 13th 2013, 1:57 pm

I posted how to do this above, follow the instructions and you should be fine Wink
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 13th 2013, 2:04 pm

Ultron's Vision wrote:I posted how to do this above, follow the instructions and you should be fine Wink

but did you see the result when i use that code? not same in my first post.

i use this code with offline and online image
Code:
<div id="onlineStaff">
<span class="staffname">Admin</span>
<span class="staffname"></span>
<span class="staffname"></span>
<span class="staffname"></span>
</div>
<!-- and so on... replace everything between <span> and </span> with the actual usernames of your staff -->
<script type="text/javascript"> jQuery(function() { var x = document.getElementById('right').getElementsByTagName('table')[9]; var y = document.getElementById('onlineStaff').getElementsByTagName('span'); for (i=0; i<y.length; i++) { if (x.innerHTML.indexOf(y[i].innerHTML) > 0)y[i].innerHTML+=' <img src="'+'http://imageshack.us/a/img198/4198/onlinebg.png'+'">';
    } else { y[i].innerHTML+='<img src="'+'http://imageshack.us/a/img812/4033/offlinezn.png'+'">'; } }); </script>

but see what happen i am online in the forum but no image seen in the widget.

http://prntscr.com/14pk1z

here my test forum : forum
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 13th 2013, 3:33 pm

Do the following...

Go to Administration Panel -> Modules -> Forum Widget Managements

Drag and Drop the Online Staff Widget to the top right corner, then add the default "Who is Online" widget (provided by forumotion) directly underneath it.
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 13th 2013, 4:24 pm

yeah i know that... but the code i think wrong pls see my screenshot..
thanks
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 13th 2013, 4:34 pm

No, the code is only fit to work when you have the widget at the top right corner, with the Who is Online Widget directly beneath it.

Surely, I could re-write the code, but why do so when you could just follow my instructions?
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 13th 2013, 4:47 pm

yeah i already use that code before i post this thread.. Very Happy
and im sure that i do it correctly
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

staff online code Empty Re: staff online code

Post by Ultron's Vision May 13th 2013, 5:00 pm

You are not using it correctly.

I could help you if you would give me a test admin account so I can modify the widgets accordingly - if you want me to, that is.
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

staff online code Empty Re: staff online code

Post by BetterHax May 13th 2013, 5:03 pm

Ultron's Vision wrote:You are not using it correctly.

I could help you if you would give me a test admin account so I can modify the widgets accordingly - if you want me to, that is.

i using it correctly before i give it to you i will approach first sir sanket in this problem maybe sanket find a solution on this
avatar
BetterHax
Forumember

Posts : 304
Reputation : 3
Language : English,Tagalog
Location : United State, Philippines

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum