thesoundsmith
Active Coder
Hi, folks. first time poster, sorry if I screw up the layout.
I have a WordPress site which began as HTML/CSS. www.davidkempton.com, formerly www.thesoundsmith.com since 1998
I have not done any significant work on the site since 2010, so I have forgotten javascript and a lot of html.
The site has a couple hundred audio files connected to 20 separate pages .
I use "jwplayer" on a page from the original HTML site, here's their reference link Playlist
I could NOT get the GUI to translate to WordPress, so it is not in their list of pages or posts. When you click the link on the menu bar, it opens as a separate window.
Everything works great except for one feature. If you like the song and want to download it, I want one button to send you to the proper page. The address is stored in the XML file item as a site address in the field 'link' Examples:
<link>Life Cycles | The Soundsmith</link>
<link>Primary Trigrams of the I Ching | The Soundsmith</link>
<link>After The Fall | The Soundsmith</link>
The command that almost words is this: (I hit Inline Code but nothing happened, sorry)
<li><a id="btn1" class="button3" title="Download This Song" <a href="(jwplayer(radio).getPlaylistItem().link);" target="blank">D/L</a> </li>
This has two problems - it has worked a couple times when first reloaded and it DOES open the correct page. But then reverts to the error Can't find https://www.davidkempton.com/(jwplayer(radio).getPlaylistItem().link (radio).getPlaylistItem().link)
or sometimes Can;t Find ! TheSoundsmith. That's the MAIN problem The call to getPlaylistItem().link should return the web address as an http:// to open, and does not.
the other issue is that i would like the call to open in the parent window instead of a new tab/window.. I tried variations of target="parent" but got a blank result instead of the error page. BTW I have tried versions of onclick() as well, at least the Anchor opes a window.
I have run the XML files past the validator as well.
Help please. I only do this about every five years and forget EVERYTHING in between... Thanks for what you can offer.
I have a WordPress site which began as HTML/CSS. www.davidkempton.com, formerly www.thesoundsmith.com since 1998
I have not done any significant work on the site since 2010, so I have forgotten javascript and a lot of html.
The site has a couple hundred audio files connected to 20 separate pages .
I use "jwplayer" on a page from the original HTML site, here's their reference link Playlist
I could NOT get the GUI to translate to WordPress, so it is not in their list of pages or posts. When you click the link on the menu bar, it opens as a separate window.
Everything works great except for one feature. If you like the song and want to download it, I want one button to send you to the proper page. The address is stored in the XML file item as a site address in the field 'link' Examples:
<link>Life Cycles | The Soundsmith</link>
<link>Primary Trigrams of the I Ching | The Soundsmith</link>
<link>After The Fall | The Soundsmith</link>
The command that almost words is this: (I hit Inline Code but nothing happened, sorry)
<li><a id="btn1" class="button3" title="Download This Song" <a href="(jwplayer(radio).getPlaylistItem().link);" target="blank">D/L</a> </li>
HTML:
<!-- The command that almost words is this: -->
<li><a id="btn1" class="button3" title="Download This Song" <a href="(jwplayer(radio).getPlaylistItem().link);" target="blank">D/L</a> </li>
another option that I thought worked is this:
<li><a id="btn1" class="button3" title="Download This Song" onclick="window.open(deCod(jwplayer(radio).getPlaylistItem().link));">D/L</a></li>
that call is to:
function deCod(linkStr) {
var str=linkStr;
return str;
}
<!-- I have tried <a href="deCod(jwplayer(radio).getPlaylistItem().link);" target="blank"> with no luck
other commands that DO work include
<li><a id="btn4" class="button3" title="Play/Pause" onclick="jwplayer(radio).play('false');">Pause</a></li>
<li><a id="btn5" class="button3" title="New Song" onclick="jwplayer(radio).playlistNext();">New</a></li>
<li><a id="btn6" title="Close DashRadio" onclick="window.open('', '_self', '');window.close();"></a></li> -->
or sometimes Can;t Find ! TheSoundsmith. That's the MAIN problem The call to getPlaylistItem().link should return the web address as an http:// to open, and does not.
the other issue is that i would like the call to open in the parent window instead of a new tab/window.. I tried variations of target="parent" but got a blank result instead of the error page. BTW I have tried versions of onclick() as well, at least the Anchor opes a window.
I have run the XML files past the validator as well.
Help please. I only do this about every five years and forget EVERYTHING in between... Thanks for what you can offer.
