11-19-2015, 05:00 PM
11-20-2015, 03:34 AM
I'm not familiar with SoundCloud. But after quick reading their API documentations, seem that the easiest way to embed the music is by using oEmbed.
You can create a textbox custom thread fields with these settings:
Title: SoundCloud URL:
Key: sc_url
Applicable Forums: Select any SoundCloud forum(s).
Editable by / Required Field? Everyone (required)
Text Mask Filter: URL (HTTP/S)
Modify it as our needs (eg: specific for SoundCloud URL).
Display Format:
You can create a textbox custom thread fields with these settings:
Title: SoundCloud URL:
Key: sc_url
Applicable Forums: Select any SoundCloud forum(s).
Editable by / Required Field? Everyone (required)
Text Mask Filter: URL (HTTP/S)
Modify it as our needs (eg: specific for SoundCloud URL).
Display Format:
HTML Code
|
Replace the "CLIENT_ID" with our client id.
11-20-2015, 08:13 AM
Great. Worked perfectly. I'll post preview link once I'm done making the templates.
11-20-2015, 09:40 AM
Live Preview: http://sharree.com/showthread.php?tid=586
11-21-2015, 01:58 AM
Great. Thanks for the demo link
BTW, if you want displaying the artwork of each sounds (for example in your forumdisplay_thread), you can use resolve endpoint (not all songs have artwork).
To do this, at least you need to create sc_forumdisplay and sc_showthread templates. Put the link for the SoundCloud js API and your client id inside the header tags, so it will be initialized once.
For example:
BTW, if you want displaying the artwork of each sounds (for example in your forumdisplay_thread), you can use resolve endpoint (not all songs have artwork).
To do this, at least you need to create sc_forumdisplay and sc_showthread templates. Put the link for the SoundCloud js API and your client id inside the header tags, so it will be initialized once.
For example:
HTML Code
|
Then in your sc_forumdispplay_thread, you can grab the artwork URL like this (for example only):
HTML Code
|
For displaying the oEmbed in sc_showthread or sc_postbit_first/_classic (example only):
HTML Code
|
Display Format of the sc_url custom thread field:
Code:
|
Again, not all songs have artwork. But seems you have custom templates for various showthread/postbit and forumdisplay_* for the SoundCloud forum, so maybe it may useful for you as a reference.
11-21-2015, 09:38 AM
Let's say a song/audio doesn't have artwork, what shows up instead? A default Souncloud image or nothing?
11-21-2015, 04:13 PM
Worked on forumdisplay_thread but 2 problems:
- Need larger sized artwork, I think this is set at 100x100
- Also the tracks without artwork come up as broken images
On Soundcloud if a track doesn't have artwork, it is replaced by a default image. <Maybe there is a way to also do this
I'll do some searching.
- Need larger sized artwork, I think this is set at 100x100
- Also the tracks without artwork come up as broken images
On Soundcloud if a track doesn't have artwork, it is replaced by a default image. <Maybe there is a way to also do this
I'll do some searching.
11-22-2015, 01:35 AM
The default artwork is 100x100 (if any).
You can try this:
sc_forumdisplay
You can try this:
sc_forumdisplay
HTML Code
|
Replace the images/logo.png with the default image (if there is no artwork found). Don't forget to replace the CLIENT_ID
Then in your sc_forumdisplay_thread:
HTML Code
|
It will use the 400×400 artwork or load the default image.
11-22-2015, 08:28 AM
Yes! worked great. Thanks RateU.
Although there is one thing. When viewing the forumdisplay from a mobile device the artwork doesn't appear. Any idea why that is?
Actually it looks to be an issue with Safari on iPhone. I tried viewing it on Google Chrome on iPhone, worked fine.
Although there is one thing. When viewing the forumdisplay from a mobile device the artwork doesn't appear. Any idea why that is?
Actually it looks to be an issue with Safari on iPhone. I tried viewing it on Google Chrome on iPhone, worked fine.