X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   MP3 or WMA streaming audio for products? (https://forum.x-cart.com/showthread.php?t=13377)

eerobat 04-12-2005 11:27 AM

MP3 or WMA streaming audio for products?
 
My site sells CD's and I would like to have some audio samples for each CD or preferable multiple Audio tracks for each.

I have two questions/problems:

1) I read the manual and it says to add an extra field and put the line:

<A href="http://www.samplesite.com/preview/sample.avi">Preview<A>

in the extra field. I did this and it just shows the text "Preview" on the live site and there is no link. What I did, was uploaded via ftp my MP3 called 10.mp3 to the folder www.mysite.com/store/files/audiosamples/10.mp3, then I put in the line above as:

<A href="http://www.mysitee.com/store/files/audiosamples/10.mp3">Preview
<A>

and it does not link. What is the problem? Could it be permissions?

2) My second question, might be a little easier. If I want to add another audio sample for the same product, can I just add another extra field and put the link, and it would work, right? :?:

Thanks!
Unix

balinor 04-12-2005 11:33 AM

You have your code wrong. This would be the proper way to code a link:

Preview

Notice the closing </a> tag. You were missing the slash.

jayzee 04-28-2005 02:37 PM

cant get html code to work
 
Hi,

I have tried to do this but everytime only the word preview is saved and the html code is lost.

why is this happening, its almost as though it is programed to strip all html from the input

balinor 04-28-2005 02:42 PM

What version of X-Cart are you using? Please put it in your signature.

eerobat 04-28-2005 03:45 PM

My issue was fixed after I edited the htaccess file. That file has to be modified to access MP3, WMA files or whatever music files you need. After I edited the htaccess file, the html link stayed right where it should in the extra fields and it worked great.

If you want to see how my htaccess file was edited, I can post if you like.

balinor 04-28-2005 04:02 PM

Please do, it may help other people in the future.

eerobat 04-28-2005 07:04 PM

By default X-Cart removes all HTML tags from extra fields for security reasons.

If you want to add link to your extra fields, please perform following steps :

1. Open '<xcart_root_dir>/provider/product_modify.php' file and replace :

---
$trusted_post_variables = array("product_lng","product_new_descr","product_n ew_full_descr","descr","fulldescr","posted_data"," js_code","javascript_code");
---

with

---
$trusted_post_variables = array("product_lng","product_new_descr","product_n ew_full_descr","descr","fulldescr","posted_data"," js_code","javascript_code","efields");
---

2. Open '<xcart_root_dir>/files/.htaccess' file and replace :

---
<FilesMatch "\.(gif|jpe?g|png|GIF|JPE?G|PNG)$">
Allow from all
</FilesMatch>
Deny from all
---

with

---
<FilesMatch "\.(gif|jpe?g|png|GIF|JPE?G|PNG|mp3|MP3|m3u|M3U)$" >
Allow from all
</FilesMatch>
Deny from all

jayzee 04-29-2005 06:45 AM

thanks for that, it sorted my problem out

:D

interstellarsounds 07-12-2005 03:40 AM

Help, I can't find this file:

2. Open '<xcart_root_dir>/files/.htaccess' file

balinor 07-12-2005 03:48 AM

Make sure you have the correct filters applied to your FTP program (if that is how you are browsing the files) so that you can see that type of file. -a is the correct filter.


All times are GMT -8. The time now is 04:19 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.