Help Please On Bcc Code

Get help developing custom BBCodes or request one.
User avatar
Lumpy Burgertushie
Registered User
Posts: 67740
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Help Please On Bcc Code

Post by Lumpy Burgertushie »

please explain a little more .

what you say is exactly what the img bbcode already does.

click on the image bbcode and insert the actual link to the image on your server like this:
[img]https://yourdomain.com/yourimage.jpg[/img]
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?

User avatar
CGI1984
Registered User
Posts: 157
Joined: Thu Feb 20, 2020 8:27 am

Re: Help Please On Bcc Code

Post by CGI1984 »

Thanks. Sorry if that question was confusing. I basically want to turn that code into a one click shortcut button On the text box tool bar like I did with the others.

Could you perhaps give me the code like you did last time for what I need to put into each of the 2 boxes for creating a custom BBCode button?

So far we’ve only done thingS involving text formatting. And I got a handle on that now. But I wasn’t sure what to put for an image like this, especially in the second box.

Thanks again.

User avatar
Lumpy Burgertushie
Registered User
Posts: 67740
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Help Please On Bcc Code

Post by Lumpy Burgertushie »

is it always going to be the same image? if not then using the standard image bbcode button is what you want.


robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?

User avatar
CGI1984
Registered User
Posts: 157
Joined: Thu Feb 20, 2020 8:27 am

Re: Help Please On Bcc Code

Post by CGI1984 »

Yup, will always be that same image. It will have a special purpose for certain types of posts and should get used often by admins. So having it as a button will make it fast to insert as an inline image without having to type out the image URL each time.

User avatar
Lumpy Burgertushie
Registered User
Posts: 67740
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Help Please On Bcc Code

Post by Lumpy Burgertushie »

create a new bbcode with a new name.
[newimg][/newimg]

html replacement:
[newimg]https://mysite/image.png[/newimg]
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?

User avatar
CGI1984
Registered User
Posts: 157
Joined: Thu Feb 20, 2020 8:27 am

Re: Help Please On Bcc Code

Post by CGI1984 »

Excellent. Thank you so much. I believe that will work.

User avatar
CGI1984
Registered User
Posts: 157
Joined: Thu Feb 20, 2020 8:27 am

Re: Help Please On Bcc Code

Post by CGI1984 »

Lumpy Burgertushie wrote:
Thu May 14, 2020 12:53 pm
create a new bbcode with a new name.
[newimg][/newimg]

html replacement:
[newimg]https://mysite/image.png[/newimg]
Unfortunately this didn't work. I tried it how you have it above. I also tried it as follows with various different configurations and it didn't work either:

[pic][/pic]
[img]https://mysite/image.png[/img]

[pic]{URL}[/pic]
[img]https://mysite/image.png[/img]

[newimg][/newimg]
[newimg][img]https://mysite/image.png[/img][/newimg]

According to the instructions in the custom BBCodes settings it says the following. So maybe a BBC code with a link to an image wont work? Also, isn't it necessary to have a token? And in that case would [newimg][/newimg] be incomplete without a token?
Please note that only tokens listed below are able to be used within custom BBCodes.
Token What can it be?
{TEXT} Any text, including foreign characters, numbers, etc…
{SIMPLETEXT} Characters from the latin alphabet (A-Z), numbers, spaces, commas, dots, minus, plus, hyphen and underscore
{INTTEXT} Unicode letter characters, numbers, spaces, commas, dots, minus, plus, hyphen, underscore and whitespaces.
{IDENTIFIER} Characters from the latin alphabet (A-Z), numbers, hyphen and underscore
{NUMBER} Any series of digits
{EMAIL} A valid email address
{URL} A valid URL using any allowed protocol (http, ftp, etc… cannot be used for javascript exploits). If none is given, “http://” is prefixed to the string.
{LOCAL_URL} A local URL. The URL must be relative to the topic page and cannot contain a server name or protocol, as links are prefixed with
{RELATIVE_URL} A relative URL. You can use this to match parts of a URL, but be careful: a full URL is a valid relative URL. When you want to use relative URLs of your board, use the LOCAL_URL token.
{COLOR} A HTML colour, can be either in the numeric form #FF1234 or a CSS colour keyword such as fuchsia or InactiveBorder

User avatar
Lumpy Burgertushie
Registered User
Posts: 67740
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Help Please On Bcc Code

Post by Lumpy Burgertushie »

sorry, I posted it wrong for you.

the html replacement should be:
<img src="https://yoursite/yourimage.jpg">
and no, in this case it does not need a token.


robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?

User avatar
CGI1984
Registered User
Posts: 157
Joined: Thu Feb 20, 2020 8:27 am

Re: Help Please On Bcc Code

Post by CGI1984 »

Perfect, thanks, that worked.

One more question please, if I wanted to add a double line space (like a double return) after whatever the BBCode creates then is there a way to add for that into the code perhaps?

User avatar
Lumpy Burgertushie
Registered User
Posts: 67740
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Help Please On Bcc Code

Post by Lumpy Burgertushie »

probably but I wouldn't have a clue how or even why.


robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?

User avatar
CGI1984
Registered User
Posts: 157
Joined: Thu Feb 20, 2020 8:27 am

Re: Help Please On Bcc Code

Post by CGI1984 »

No problem and thanks anyway.

Post Reply

Return to “Custom BBCode Development and Requests”