PDA

View Full Version : BB Code Enhancements - [BB Code] Browser


Coroner
03-04-2009, 10:00 PM
This is a Browser BB Code.

It will draw a small box with informations about the Users (post viewing) browser.

How To:
Go into you AdminCP and add a new BB Code:

Title: Browser
BB Code Tag Name: browser
Replacement:
<table cellpadding="6" cellspacing="1" class="tborder" border="0"><tr><td class="alt2" align="left">
<script type="text/javascript">
document.write ("Browser: " + navigator.appName + "<br />");
document.write ("User Agent: " + navigator.userAgent + "<br />");
document.write ("Platform: " + navigator.platform + "<br />");
</script>
</td></tr></table>
Example:
[B]Description: The Browser Info BBCode shows information about the viewers browser.
Use {option}: No
Button Image: ---

Remove Tag If Empty: No

Use [ instead of { and ] instead of } in the example.

Jasem
03-05-2009, 05:59 AM
Good work, thank you

RamisK
03-05-2009, 06:46 AM
Nice work. Thanks

ravenfaust
12-04-2009, 01:46 AM
neat :D

marshal_ramdev
12-04-2009, 02:23 AM
thanks .. good one

COL NIL SATIS
01-07-2010, 04:42 PM
NICE ONE!! installed

SilabGarza
01-11-2010, 07:51 PM
who's info does it show?
the poster or the 1 looking at the post?

cheech47
08-08-2014, 06:20 PM
Any idea if this would only display to admin\mods only?

blind-eddie
08-09-2014, 12:10 AM
This is the same code as above but, I added an if conditional around code.
This will only show it to admins (6)
To add other usergroups add a comma after usergroup id, example: 1,2,3,4,5,6,7



<if condition="$post['usergroupid'] == 6">
<table cellpadding="6" cellspacing="1" class="tborder" border="0">
<tr><td class="alt2" align="left">
<script type="text/javascript">
document.write ("Browser: " + navigator.appName + "<br />");
document.write ("User Agent: " + navigator.userAgent + "<br />");
document.write ("Platform: " + navigator.platform + "<br />");
</script>
</td>
</tr>
</table>
</if>

cheech47
08-09-2014, 06:13 AM
Cheers :up:

cheech47
08-10-2014, 06:58 PM
Hi,

It doesnt appear to show in the postbit, is there any edits needed?