itbranson Posted December 6, 2010 Share Posted December 6, 2010 Hi all,I have recently turned on Friendly URL in the back office. But now my mp3 player on product pages do not work (not loaded at all). My PS is 1.3.3.I plan to sell mp3 songs and have a flash mp3 player for sample playing (i insert the player through back end whenever i need. It's not hard-coded with the theme). Before i enable Friendly URL, it was working without any issue.Now, after enabling Friendly URL, the player works only in Product Category pages, but it is not loaded in specific Product pages. When i turn off Friendly URL it is loaded again on the page. Why it works in category pages while it has problem in Product specific page?Any hint?Thanks a lot Link to comment Share on other sites More sharing options...
rocky Posted December 6, 2010 Share Posted December 6, 2010 Most likely, you are using a relative URL when you should be using an absolute one, causing the URL to break when on product pages, since friendly URL puts them in a virtual subdirectory. Link to comment Share on other sites More sharing options...
itbranson Posted December 6, 2010 Author Share Posted December 6, 2010 so, the only option i have to keep a product specific page with friendly URL and the mp3 player is coding in .htaccess file? Link to comment Share on other sites More sharing options...
rocky Posted December 6, 2010 Share Posted December 6, 2010 No, you should find the relative URL in your mp3 player code and convert it to an absolute URL. What code are you using? Link to comment Share on other sites More sharing options...
itbranson Posted December 8, 2010 Author Share Posted December 8, 2010 My mp3 player, playlist.xml and mp3 sit in root folder. Then i put the following code in product description through admin end. <object id="dewplayer" width="246" height="240" data="dewplayer-playlist.swf" type="application/x-shockwave-flash"> </object> Link to comment Share on other sites More sharing options...
itbranson Posted December 8, 2010 Author Share Posted December 8, 2010 a thing is that product page's URL is not changed whether the flash player is there or not. But once Friendly URL is turned on, then the player is disappeared. If you could give me further hint, i'd really appreciate. Link to comment Share on other sites More sharing options...
rocky Posted December 8, 2010 Share Posted December 8, 2010 Yep, it's a relative URL. Try the following: <object id="dewplayer" width="246" height="240" data="/dewplayer-playlist.swf" type="application/x-shockwave-flash"> </object> Adding the slash will make it look for dewplayer-playlist.swf in the root directory instead of the current directory. Link to comment Share on other sites More sharing options...
itbranson Posted December 8, 2010 Author Share Posted December 8, 2010 wow, fantastic! Now the page loads the flash player. That's really great. But i'm sorry for asking further one more thing, now the player says that there's XML error and doesnt load songs. I believe it's a playlist.xml error. I have tried to move the playlist.xml from a subdirectory to the root folder. Still no change. How can i bring the songs back to the player?I'm very glad that the site now loads the player at least! Link to comment Share on other sites More sharing options...
itbranson Posted December 8, 2010 Author Share Posted December 8, 2010 one more thing: my mp3 and playlist.xml folder sit in a subdirectory, not the root. For example ...com/prestashop/mp3/song1 Link to comment Share on other sites More sharing options...
rocky Posted December 9, 2010 Share Posted December 9, 2010 I see now that playlist.xml is a relative URL too. That must also be an absolute directory, so assuming playlist.xml is in http://www.yoursite.com/com/prestashop/mp3/song1/ then use: <object id="dewplayer" width="246" height="240" data="/dewplayer-playlist.swf" type="application/x-shockwave-flash"> </object> Link to comment Share on other sites More sharing options...
itbranson Posted December 10, 2010 Author Share Posted December 10, 2010 Thank you very much. When i checked the playlist.xml file, i discovered that my mp3 tracks had also relative URLs. I changed them to absolute ones and now Everything is going fine.Thank you again for your help during this confusion. I now know the importance of absolute URL in this kind of cases. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now