Hello Kevin
Thank you for your response and your help.
Effectively I actually tested the bypass filter but without success ??
It was my first idea when i read your documentation.
Here is the function I used. I think my condition on the URL is not taken by the plugin.
function my_forcelogin_bypass( $bypass ) {
// Get visited URL without query string
$url_path = preg_replace('/\?.*/', '', $_SERVER['REQUEST_URI']);
// Autorisation pour les fiches produits
if ( '/single-fiches-produits.php' === $url_path || '/single-fiches-produits-pdf.php' === $url_path) {
$bypass = true;
}
return $bypass;
}
add_filter( 'v_forcelogin_bypass', 'my_forcelogin_bypass' );
I use a template who’s name is “single-fiches-produits.php” for website (works great) and DompPDF for PDF works with “name-template-pdf.php”
but when i try to generate my PDF the PDF display the login Page of WordPress…
DomPDF used this url format : http(s)://my_web_site_url)/pdf
In PHP done this : <?php the_permalink(); ?>pdf
I think it’s due to URL path but I can’t solve this problem;
I’m using the WordPress rewrited url (pretty url).
If I find the solution of course I will share the solution ??
Bertrand