Spotify BBcode

Get help developing custom BBCodes or request one.
Post Reply
TheDani
Registered User
Posts: 321
Joined: Tue Apr 10, 2012 12:48 pm

Spotify BBcode

Post by TheDani » Tue Feb 26, 2013 12:06 pm

Need help with this.

BBCode usage

Code: Select all

[spotify]{SIMPLETEXT}[/spotify]
HTML replacement

Code: Select all

<iframe src="https://embed.spotify.com/?uri={SIMPLETEXT}" width="380" height="80" frameborder="0" allowtransparency="true"></iframe>
Help line

Code: Select all

[spotify]Spotify URI[/spotify]
Examples

Code: Select all

[spotify]spotify:album:2XQwZUu0MM9ECgwHbcc8qR[/spotify]

[spotify]spotify:track:5v3TSHYm8BzbON2u6QBEG7[/spotify]

Problem: the bbcode is simply not parsed!

User avatar
Brf
Support Team Member
Support Team Member
Posts: 51317
Joined: Tue May 10, 2005 7:47 pm
Location: {postrow.POSTER_FROM}
Contact:

Re: Spotify BBcode

Post by Brf » Tue Feb 26, 2013 3:46 pm

ACP wrote:{SIMPLETEXT} Characters from the latin alphabet (A-Z), numbers, spaces, commas, dots, minus, plus, hyphen and underscore
It does not say "colons"

TheDani
Registered User
Posts: 321
Joined: Tue Apr 10, 2012 12:48 pm

Re: Spotify BBcode

Post by TheDani » Tue Feb 26, 2013 4:07 pm

I tried {TEXT} which gave me a XSS warning and no diff.

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

Re: Spotify BBcode

Post by Lumpy Burgertushie » Tue Feb 26, 2013 4:10 pm

the only way I can figure it out is to use two different bbcodes. one for track and one for album.

track:


[track]{SIMPLETEXT}[/track]

html replacement:

Code: Select all

<iframe src="https://embed.spotify.com/?uri=spotify:track:{SIMPLETEXT}" width="380" height="80" frameborder="0" allowtransparency="true"></iframe>
do the same for album but replace track with album.


robert
I am available for custom work on a donation basis. Please send me a PM with your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

OK, so what's the speed of dark?

TheDani
Registered User
Posts: 321
Joined: Tue Apr 10, 2012 12:48 pm

Re: Spotify BBcode

Post by TheDani » Tue Feb 26, 2013 4:17 pm

Yeah that could work. No ideal solution as it will require me to have 3 different bbcodes, on for tracks, one for albums and one for playlists.

[spotify_album]...[/spotify_album]
[spotify_track]...[/spotify_track]
[spotify_playlist]...[/spotify_playlist]

instead of just

[spotify]...[/spotify]

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

Re: Spotify BBcode

Post by Lumpy Burgertushie » Tue Feb 26, 2013 4:25 pm

TheDani wrote:Yeah that could work. No ideal solution as it will require me to have 3 different bbcodes, on for tracks, one for albums and one for playlists.

[spotify_album]...[/spotify_album]
[spotify_track]...[/spotify_track]
[spotify_playlist]...[/spotify_playlist]

instead of just

[spotify]...[/spotify]
the problem is the colon in the address. that is not even valid for urls anyway, but it works.

there is no bbcode varible for a colon.

you could make it all in one, however, to use it you would have to copy and paste two different parts of the url into your bbcode brackets and that would be very confusing for everyone.

separate buttons for each would be the best.


robert
I am available for custom work on a donation basis. Please send me a PM with your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

OK, so what's the speed of dark?

TheDani
Registered User
Posts: 321
Joined: Tue Apr 10, 2012 12:48 pm

Re: Spotify BBcode

Post by TheDani » Tue Feb 26, 2013 4:55 pm

Lumpy Burgertushie wrote:the problem is the colon in the address. that is not even valid for urls anyway, but it works.
What do you mean by that? All urls have a colon.

https://www.phpbb.com/

But ok, Ill consider making three buttons then...

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

Re: Spotify BBcode

Post by Lumpy Burgertushie » Tue Feb 26, 2013 5:12 pm

TheDani wrote:
Lumpy Burgertushie wrote:the problem is the colon in the address. that is not even valid for urls anyway, but it works.
What do you mean by that? All urls have a colon.

https://www.phpbb.com/

But ok, Ill consider making three buttons then...
well, technically you are correct, I meant in the actual file/folder name section.

spotify:album: etc.

that is not valid as far as I know. certain characters are not allowed

robert
I am available for custom work on a donation basis. Please send me a PM with your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

OK, so what's the speed of dark?

TheDani
Registered User
Posts: 321
Joined: Tue Apr 10, 2012 12:48 pm

Re: Spotify BBcode

Post by TheDani » Wed Feb 27, 2013 3:55 pm

How do I embed a playlist? Say I want to embed this playlist: http://open.spotify.com/user/nme.com/pl ... kIILZYkPYL

I tried:
BBCode usage:

Code: Select all

[spotify_plist]{SIMPLETEXT1} {SIMPLETEXT2}[/spotify_plist]
HTML replacement

Code: Select all

<iframe src="https://embed.spotify.com/?uri=spotify:user:{SIMPLETEXT1}:playlist:{SIMPLETEXT2}" width="300" height="380" frameborder="0" allowtransparency="true"></iframe>
¨


EDIT: updated and solved.

User avatar
millipede
Registered User
Posts: 136
Joined: Mon Feb 25, 2008 5:13 am
Contact:

Re: Spotify BBcode

Post by millipede » Sat Sep 08, 2018 12:49 am

Can this still be done?
Oh, and since this post has a nice red check-mark, will it still get noticed that I responded?

I originally planned on putting some playlists on a /tunes page on my site. Then I considered some sticky topics in the forum instead so as to keep people engaged with the forum more.
So, I just went and tried and of course, it doesn't work... so I started searching, and searching, and this was one of the topics I found. Tried what was posted at the end and, trying to submit it I get a 403 forbidden page.
Was hoping to share music on my site, and hoping to do it more on the forum...
Will it work on the forum? Do I need to do it just on a regular page instead?

EDIT: Well, weird. I figured I couldn't get it to work so, while making a post, I just pasted the url of the playlist so people could go off site to play it if they want. The player popped up... in the forum. A little confused how that happened... just posted what I thought was a direct link and, there's the playlist in the post.

If that will work again for another list, problem solved. This isn't a danger though right? or is it? Should that have not happened?

User avatar
Mick
Support Team Member
Support Team Member
Posts: 19977
Joined: Fri Aug 29, 2008 9:49 am
Location: Cardiff

Re: Spotify BBcode

Post by Mick » Sat Sep 08, 2018 8:16 am

What extensions have you got installed? You should start your own topic (you can link back to this one if you wish) as this one is marked solved as you mentioned.
"The more connected we get the more alone we become" - Kyle Broflovski

There are no ‘threads’ in phpBB, they are topics.

Post Reply

Return to “Custom BBCode Development and Requests”

Who is online

Users browsing this forum: Majestic-12 [Bot] and 6 guests