Forums / Basic Configuration / Lien vers un document pdf impossible depuis un produit

Lien vers un document pdf impossible depuis un produit

Views: 1,445

Results 1 to 5 of 5
1 Nov 2025, 11:56 PM
#1
terifick avatar

terifick

New Zenner

Join Date:
Oct 2025
Posts:
19
Plugin Contributions:
0

Lien vers un document pdf impossible depuis un produit

Bonjour,
J'ai chargé la dernière version 2.1.0 et j'utilise le template responsive classic.
Lorsque je crée un produit, dans le descriptif j'essaie de mettre un lien vers un fichier pdf.
En FO le lien arrive à la bonne adresse en _blank mais ça me dit que le fichier est introuvable.
Oui j'ai bien transféré le fichier via FTP dans le dossier.
Ma question est comment faire pour que cela fonctionne. Y at-il un dossier spécial pour y charger mes documents pdf? Y at-il des droits spécifiques à mettre sur le dossier ?
Cela vient-il des fichiers htaccess ? Comment les modifier ?

Merci pour votre éclairage

2 Nov 2025, 12:44 AM
#2
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,864
Plugin Contributions:
18

Re: Lien vers un document pdf impossible depuis un produit

You don't say where the folder is or whether the link is relative or absolute.

If the file were MYFILE.PDF and located in the download folder, you might try /download/MYFILE.pdf

<a href="download/MYFILE.PDF">Download MYFILE.PDF</a>

You might want to make sure the MYFILE.PDF is set to 644 to protect it.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

2 Nov 2025, 1:10 PM
#3
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,119
Plugin Contributions:
56

Re: Lien vers un document pdf impossible depuis un produit

If MYFILE.PDF isn't being delivered to the customer as a paid download (set via product's attributes), then placing the file in the site's /download directory will result in the download being denied (due to .htaccess restrictions).

For this case, I suggest creating a /pdfs directory into which you place those free-downloadable PDF files. Be sure to include an index.html file (which you can copy from the /download directory) to prevent snooping.

2 Nov 2025, 2:51 PM
#4
pilou2 avatar

pilou2

Zen Follower

Join Date:
Jun 2008
Location:
Japan
Posts:
414
Plugin Contributions:
6

Re: Lien vers un document pdf impossible depuis un produit

On my shop (ZC 2.1), all products manuals are in ZC standard 'download' folder and linked in product description with a link like this:

<a href="download/manual.pdf" target="_blank" title="Product manual">manual here</a>

'.htacces' file is standard, unmodified.

Remarque que le lien est relatif à la racine du site. En tout cas, si ça ne marche pas, c'est pas terific! :)))

ZC v2.2.2 PHP 8.4+ MySQL 8.4+

2 Nov 2025, 3:01 PM
#5
terifick avatar

terifick

New Zenner

Join Date:
Oct 2025
Posts:
19
Plugin Contributions:
0

Re: Lien vers un document pdf impossible depuis un produit

Bonjour,
Merci pour votre aide.
J'ai créé un dossier pdf et mis des droits 705.
Et ça fonctionne !
Problème résolu