BBCode Problem

Get help with installation and running phpBB 3.0.x here. Please do not post bug reports, feature requests, or MOD-related questions here.
Scam Warning
Forum rules
END OF SUPPORT: 1 January 2017 (announcement)
Locked
The_Nut
Registered User
Posts: 4
Joined: Wed Jun 11, 2014 8:53 am

BBCode Problem

Post by The_Nut »

Support Request Template
What version of phpBB are you using? phpBB 3.0.12
What is your board's URL? http://theminegames.net/forum
Who do you host your board with? UnKnown - I didn't setup host
How did you install your board? I used the download package from phpBB.com
What is the most recent action performed on your board? Fresh Install
Is registration required to reproduce this issue? Yes
Do you have any MODs installed? Yes
What MODs do you have installed? Prime Login via E-Mail
Blog MOD
What styles do you currently have installed? ProBoot3
What language(s) is your board currently using? British English
Which database type/version are you using? MySQL 5
What is your level of experience? Comfortable with PHP and phpBB
What username can be used to view this issue? TestAccount
What password can be used to view this issue? TestUser
When did your problem begin? When I added more BBCodes.
Please describe your problem. The added BBCodes don't go onto a new line.
Generated by SRT Generator
Attachments
forumcapture.PNG
forumcapture.PNG (5.37 KiB) Viewed 751 times
User avatar
Oyabun1
Former Team Member
Posts: 23162
Joined: Sun May 17, 2009 1:05 pm
Location: Australia
Name: Bill

Re: BBCode Problem

Post by Oyabun1 »

They are not supposed to. By default they fill the available space.
                      Support Request Template
3.0.x: Knowledge Base Styles Support MOD Requests
3.1.x: Knowledge BaseStyles SupportExtension Requests
The_Nut
Registered User
Posts: 4
Joined: Wed Jun 11, 2014 8:53 am

Re: BBCode Problem

Post by The_Nut »

Oh, is their a way to make it separate? So it looks tidier?
User avatar
Mick
Support Team Member
Support Team Member
Posts: 23057
Joined: Fri Aug 29, 2008 9:49 am

Re: BBCode Problem

Post by Mick »

I used the simple change below a long time ago and I presume it still works but haven't tried it for ages. Make sure you make a copy of posting_buttons.html and save it somewhere safe just in case something goes wrong. If it doesn't do what you want replace the file you edited with the back up you made.

Puts all custom bbcodes in a select box, this makes the posting page look nicer and saves some space.

Open styles/{YOURTHEME}/template/posting_buttons.html

Find:

Code: Select all

    <!-- BEGIN custom_tags -->
          <input type="button" class="button2" name="addbbcode{custom_tags.BBCODE_ID}" value="{custom_tags.BBCODE_TAG}" onclick="bbstyle({custom_tags.BBCODE_ID})" title="{custom_tags.BBCODE_HELPLINE}" />
       <!-- END custom_tags -->
Replace with:

Code: Select all

    <select name="addbbcode_custom" onchange="bbstyle(this.form.addbbcode_custom.options[this.form.addbbcode_custom.selectedIndex].value*1);this.form.addbbcode_custom.selectedIndex = 0;">
          <option value="#" selected="selected">Custom BBCodes</option>
          <!-- BEGIN custom_tags -->
          <option value="{custom_tags.BBCODE_ID}" title="{custom_tags.BBCODE_HELPLINE}">{custom_tags.BBCODE_TAG}</option>
          <!-- END custom_tags -->   
         </select>
Refresh the template
"The more connected we get the more alone we become" - Kyle Broflovski©
The_Nut
Registered User
Posts: 4
Joined: Wed Jun 11, 2014 8:53 am

Re: BBCode Problem

Post by The_Nut »

Hi,

Just to be clear, where am I putting the BBCode name?
So I have a center, hr, spoiler and youtube
How would I implement these?

Thanks in advance
User avatar
Oyabun1
Former Team Member
Posts: 23162
Joined: Sun May 17, 2009 1:05 pm
Location: Australia
Name: Bill

Re: BBCode Problem

Post by Oyabun1 »

You don't have to put them anywhere. The code Mick supplied automatically adds the Custom BBCodes to a drop-down list.
                      Support Request Template
3.0.x: Knowledge Base Styles Support MOD Requests
3.1.x: Knowledge BaseStyles SupportExtension Requests
User avatar
PinoyEngine™
Registered User
Posts: 244
Joined: Fri Apr 24, 2009 7:12 am

Re: BBCode Problem

Post by PinoyEngine™ »

The_Nut wrote:Hi,

Just to be clear, where am I putting the BBCode name?
So I have a center, hr, spoiler and youtube
How would I implement these?

Thanks in advance
You will still be putting those custom BB codes at your Admin CP.

The solution posted by Mick are for the issue shown at your earlier post.
Purge the cache after applying the solution.
The_Nut
Registered User
Posts: 4
Joined: Wed Jun 11, 2014 8:53 am

Re: BBCode Problem

Post by The_Nut »

Hi,

I've now managed to get that working, thanks.
How would I add a space in between the buttons?
Attachments
forumcapture.PNG
forumcapture.PNG (1.42 KiB) Viewed 650 times
User avatar
Mick
Support Team Member
Support Team Member
Posts: 23057
Joined: Fri Aug 29, 2008 9:49 am

Re: BBCode Problem

Post by Mick »

You need to ask in the discussion/support area for your style or from where you obtained it.
"The more connected we get the more alone we become" - Kyle Broflovski©
Locked

Return to “[3.0.x] Support Forum”