[code] enhancements

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in the Customisations Database.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTICE: This forum is only for the announcement of new releases and/or updates of MODs. Any MOD support should be obtained through the Customisations Database in the support area designated for each MOD.

A direct link to support for each MOD is in the first post of the respective topic.
Extensions Robot
Extensions Robot
Extensions Robot
Posts: 28531
Joined: Sat Aug 16, 2003 7:36 am

[code] enhancements

Post by Extensions Robot »

Modification name:

Code: Select all

 enhancements
[b]Author:[/b] [url=https://www.phpbb.com/customise/db/author/martin+truckenbrodt/]Martin Truckenbrodt[/url]
[b]Modification description[/b]: Preserves tabs in [code] blocks and eliminates the four spaces that precede every line in Firefox.
[b]Modification version[/b]: 1.0.2
[b]Tested on phpBB version[/b]: 3.0.10

[b]Download file[/b]: [url=https://www.phpbb.com/customise/db/download/83805]CodeEnhancements_1.0.2.zip[/url]
[b]File size:[/b] 67.4 KiB

[b]Modification overview page:[/b] [url=https://www.phpbb.com/customise/db/mod/code_enhancements/]View[/url]

[color=blue][b]The phpBB Team is not responsible nor required to provide support for this modification. By installing this MOD, you acknowledge that the phpBB Support Team or phpBB Extension Customisations Team may not be able to provide support.[/b][/color]

[size=150][url=https://www.phpbb.com/customise/db/mod/code_enhancements/support]-->[b]Modification support[/b]<--[/url][/size]
Last edited by Extensions Robot on Mon Sep 14, 2020 12:37 pm, edited 13 times in total.
(this is a non-active account manager for the phpBB Extension Customisations Team)
Paul
Infrastructure Team Leader
Infrastructure Team Leader
Posts: 26812
Joined: Sat Dec 04, 2004 3:44 pm
Location: The netherlands.
Name: Paul Sohier
Contact:

[code] enhancements

Post by Paul »

Modification validated/released

Notes:
Knock knock
Race condition
Who's there?

My BlogMy Photosmy phpBB Extensionscustom phpBB work & Development
TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

[code] enhancements

Post by TerraFrost »

Your existing users will need to clear their cache for this MOD to work correctly for them. If the cache isn't cleared, the Select All button is liable not to work and the contents of the code box may not wrap around.

An announcement informing users of this fact might be prudent.
User avatar
spaceace
Registered User
Posts: 1990
Joined: Wed Jan 30, 2008 8:50 pm
Contact:

Re: [code] enhancements

Post by spaceace »

great mod :D

now just have to get it on every phpbb3 board :lol:
User avatar
A_O_C
Registered User
Posts: 2383
Joined: Sun Jul 01, 2007 11:26 pm
Location: phpbb_

Re: [code] enhancements

Post by A_O_C »

congrats TerraFrost

one small issue (on my main website). this MOD works fine in IE. if i use FF, the "select all" button doesnt work. i noticed that in IE, the "select all" points to (replaced with xxx - topics do not exist anymore)

Code: Select all

http://www.compnetsupport.org/viewtopic.php?f=xxx&t=xxx#
but in FF, it points to

Code: Select all

http://www.compnetsupport.org/viewtopic.php?f=xxx&t=xxx&p=xxx#
notice the &p=xxx

also, the code box spans the whole message body area, and code is cut off. if i post numerous lines of code (exhibited in the post after the one linked above), there is no scrollbar.

again, works perfectly fine in IE.
TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Re: [code] enhancements

Post by TerraFrost »

A_O_C - I think the issue you describe is due to browser cache issues. I have the same problem after I install this MOD with Firefox but it goes away when I hit Ctrl + F5 to force a cache reload. Unfortunately, I'm not really sure what I can do to make this a non-issue, aside from maybe recommending that admins make an announcement or something saying to clear their cache to get the

Code: Select all

 bbcode to work properly.

Also, sorry for the delay.  You can blame the US holiday of Thanksgiving :)
thejerry007
Registered User
Posts: 46
Joined: Fri Jul 06, 2007 2:42 pm

Re: [code] enhancements

Post by thejerry007 »

please screen shots
TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Re: [code] enhancements

Post by TerraFrost »

thejerry007 wrote:please screen shots
Screen shots really aren't going to tell you anything. Pretty much, the [­code] BBcode should look the same before this MOD is installed as it should afterwards. It's not changing the way anything looks - it's changing the way it works. Instead of tabs being replaced by four spaces when you copy the text, they're now tabs, etc.
User avatar
A_O_C
Registered User
Posts: 2383
Joined: Sun Jul 01, 2007 11:26 pm
Location: phpbb_

Re: [code] enhancements

Post by A_O_C »

will give it a go when i get home tonight.
User avatar
A_O_C
Registered User
Posts: 2383
Joined: Sun Jul 01, 2007 11:26 pm
Location: phpbb_

Re: [code] enhancements

Post by A_O_C »

TerraFrost, clearing the browser cache worked. great MOD, thanks.
TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Re: [code] enhancements

Post by TerraFrost »

A_O_C wrote:TerraFrost, clearing the browser cache worked. great MOD, thanks.
Thanks for testing that out - I've updated my first post to notify users about this :)
User avatar
MartectX
Translator
Posts: 1324
Joined: Wed Dec 19, 2007 8:05 pm
Location: Marienplatz

Re: [code] enhancements

Post by MartectX »

You should really think about installing this on the official boards because I've copied code bits from here sooo often and cursed those 4 spaces.

/rant :evil:

Thanks for this MOD!! :)
MarcSto
Registered User
Posts: 131
Joined: Tue May 20, 2008 2:11 am

Re: [code] enhancements

Post by MarcSto »

how to install it on a subsilver template (acidtech)
TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Re: [code] enhancements

Post by TerraFrost »

Here are the changes for subsilver2:

Code: Select all

#
#-----[ OPEN ]------------------------------------------
#
styles/subsilver2/template/bbcode.html
#
#-----[ FIND ]------------------------------------------
#
<!-- BEGIN code_open -->
<div class="codetitle"><b>{L_CODE}:</b></div><div class="codecontent">
<!-- END code_open -->

<!-- BEGIN code_close -->
</div>
<!-- END code_close -->
#
#-----[ REPLACE WITH ]----------------------------------
#
<!-- BEGIN code_open -->
<div class="codetitle"><b>{L_CODE}:</b></div><pre class="codecontent">
<!-- END code_open -->

<!-- BEGIN code_close -->
</pre>
<!-- END code_close -->
#
#-----[ OPEN ]------------------------------------------
#
styles/subsilver2/theme/stylesheet.css
#
#-----[ FIND ]------------------------------------------
#
.codecontent {
	direction: ltr;
	margin: 0 5px 10px 5px;
	padding: 5px;
	border-color: #A9B8C2;
	border-width: 0 1px 1px 1px;
	border-style: solid;
	font-weight: normal;
	color: #006600;
	font-size: 0.85em;
	font-family: Monaco, 'Courier New', monospace;
	background-color: #FAFAFA;
}
#
#-----[ REPLACE WITH ]----------------------------------
#
.codecontent {
	direction: ltr;
	margin: 0 5px 10px 5px;
	padding: 5px;
	border-color: #A9B8C2;
	border-width: 0 1px 1px 1px;
	border-style: solid;
	font-weight: normal;
	color: #006600;
	font-size: 0.85em;
	font-family: Monaco, 'Courier New', monospace;
	background-color: #FAFAFA;
	/* Making preformated <pre> text wrap in CSS3, Mozilla, Opera and IE:
	   http://users.tkk.fi/~tkarvine/pre-wrap-css3-mozilla-opera-ie.html */
	white-space: pre-wrap;
	white-space: -moz-pre-wrap;
	white-space: -pre-wrap;
	white-space: -o-pre-wrap;
	word-wrap: break-word;
}
You can change them around for acidtech as appropriate. If you need any help, let me know.

Also, you'll need to do Ctrl + F5 to reload after applying these changes.
User avatar
RMcGirr83
Former Team Member
Posts: 21490
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: [code] enhancements

Post by RMcGirr83 »

Afternoon Terrafrost.

I have noticed that when using the print function from within viewing a topic, if a post has the code tag in it the code within the tag does not wrap.
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
Locked

Return to “[3.0.x] MOD Database Releases”