Answers.Body: <p>You need to give it the FULL path, and include the actual executable file, e.g.</p>
  
  <p><code>/usr/local/bin/wkhtmltopdf</code></p>
  
  <p>The path you have in the screenshot has 3 problems:</p>
  
  <ul>
  <li>it's missing the wkhtmltopdf executable at the end</li>
  <li>it's not absolute, i.e. starting from the very top level / directory</li>
  <li>it would be really unusual to have usr/local/bin under public_html. Your installed executables shouldn't be under public_html (security risk) and I doubt an rpm would put them there unless you manually put them there. When you say "unpacked" do you mean installed (rpm -ivh) or just extracted the files inside and put them under public_html?</li>
  </ul>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T01:13:02.463Z
Answers.Text: Hi Demerit, thanks for your reply. Your right I unpacked the .rpm into that location. I will move it to another location and try the full root URL.
  
  For testing I just moved it to the main root directory and included the full path.
  
  /home/dfcadmin18/usr/local/bin/wkhtmltopdf
  
  Any advice would be much appreciated to get this to work. Thanks Demerit
Answers.UserDisplayName: Aaron Jewell
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T01:25:06.793Z
Answers.Text: I'm not sure if that will work since there are shared libraries also in the rpm which it might not be able to find if you don't actually install it, but it sounds like you only have cpanel access and a web-based file browser? Maybe I should ask why you're trying to install it. Civi doesn't need it to produce pdfs, it's just an alternate tool to replace the tool that comes with civi. If you really do need to install it and don't have root shell access, see also this link: https://stackoverflow.com/questions/2273534/how-to-install-wkhtmltopdf-on-a-linux-based-shared-hosting-web-server
Answers.UserDisplayName: Demerit
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T01:31:48.140Z
Answers.Text: Well that is a good question that lead me onto wkhtmltopdf. Basically in CiviCRM the administrator is trying to make mailing labels within the advance search. When you get to picking your groups etc to make the labels and press on make mailing labels. The next screen is a blank URL. which some people told me that it was missing wkhtmltopdf, which made sense as it seems something is missing for that process to work, I just don't know what the missing step is. We did change server environment recently, I will add a screen shot to the main question and would be great if you had any ideas.
Answers.UserDisplayName: Aaron Jewell
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T01:41:05.073Z
Answers.Text: And when you get the blank screen is the setting for wkhtmltopdf empty or do you have something in there? You would leave it empty to use the default tool.
Answers.UserDisplayName: Demerit
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T01:42:32.503Z
Answers.Text: Also error 500 usually gives more info in the web server logs, which in cpanel I think is just called "error logs".
Answers.UserDisplayName: Demerit
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T09:12:19.420Z
Answers.Text: Orginally the settings for wkhtmltopdf was blank. Like I said someone advised to look into wkhtmltopdf and set it up to see if that would resolve the issue.
Answers.UserDisplayName: Aaron Jewell
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T09:12:48.010Z
Answers.Text: I will look into the error logs now and see if I can find out why the URL is coming back with error 500
Answers.UserDisplayName: Aaron Jewell
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-06T09:15:41.343Z
Answers.Text: Might be worth checking with your hosting provider whether wkhtmltopdf is already installed.
Answers.UserDisplayName: Aidan
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-05T19:57:30.267Z
Answers.LastActivityDate: 2019-03-06T01:28:38.443Z
Answers.LastEditDate: 2019-03-06T01:28:38.443Z
Answers.UserDisplayName: Demerit
Body: <p>This is my first time trying to sort out wkhtmltoPDF. I'm having issues in civiCRM when trying to make mailing labels from the membership database. When clicking on make mailing labels the next page is a blank URL.</p>
  <p>Someone suggested that it could be to do with wkhtmltopdf needing to be installed. I have unpacked a .rpm for wkhtmltopdf to my server. I have also put in the URL path for this folder. But I am coming up with a blank as to why it won't accept the path.</p>
  <p>Does anyone have any experience on fixing this?  The server environment is Cpanel.I have attached a screen shot of the issue with the path for someones attention.</p>
  <p>Thanks in advance,</p>
  <p>Aaron</p>
  <p>WARNING: wkhtmltopdf is no longer under active development and its latest tagged release of 0.12.6 from June 2020 (<a href="https://github.com/wkhtmltopdf/wkhtmltopdf/tree/0.12.6" rel="nofollow noreferrer">https://github.com/wkhtmltopdf/wkhtmltopdf/tree/0.12.6</a>) is insecure and should not be used (<a href="https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-35583" rel="nofollow noreferrer">https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-35583</a>).</p>
  <p><a href="https://i.sstatic.net/cdQ8M.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/cdQ8M.png" alt="enter image description here" /></a>
  <a href="https://i.sstatic.net/NZFqi.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/NZFqi.png" alt="enter image description here" /></a>
  <a href="https://i.sstatic.net/mvta5.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/mvta5.png" alt="enter image description here" /></a></p>
  
Tags: <mailing><pdf><address-labels>
Title: WkhtmlPDF issues with the path in CiviCRM
ThreadText: # WkhtmlPDF issues with the path in CiviCRM
  
  (Asked by: username_0 on 2019-03-05)
  
  This is my first time trying to sort out wkhtmltoPDF. I'm having issues in civiCRM when trying to make mailing labels from the membership database. When clicking on make mailing labels the next page is a blank URL.
  
  Someone suggested that it could be to do with wkhtmltopdf needing to be installed. I have unpacked a .rpm for wkhtmltopdf to my server. I have also put in the URL path for this folder. But I am coming up with a blank as to why it won't accept the path.
  
  Does anyone have any experience on fixing this? The server environment is Cpanel.I have attached a screen shot of the issue with the path for someones attention.
  
  Thanks in advance,
  
  Aaron
  
  WARNING: wkhtmltopdf is no longer under active development and its latest tagged release of 0.12.6 from June 2020 (<https://github.com/wkhtmltopdf/wkhtmltopdf/tree/0.12.6>) is insecure and should not be used (<https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-35583>).
  
  [![enter image description here](https://i.sstatic.net/cdQ8M.png)](https://i.sstatic.net/cdQ8M.png)
  [![enter image description here](https://i.sstatic.net/NZFqi.png)](https://i.sstatic.net/NZFqi.png)
  [![enter image description here](https://i.sstatic.net/mvta5.png)](https://i.sstatic.net/mvta5.png)
  
  **Tags:** mailing, pdf, address-labels
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-03-05. Score: 1
  
  You need to give it the FULL path, and include the actual executable file, e.g.
  
  `/usr/local/bin/wkhtmltopdf`
  
  The path you have in the screenshot has 3 problems:
  
  * it's missing the wkhtmltopdf executable at the end
  * it's not absolute, i.e. starting from the very top level / directory
  * it would be really unusual to have usr/local/bin under public\_html. Your installed executables shouldn't be under public\_html (security risk) and I doubt an rpm would put them there unless you manually put them there. When you say "unpacked" do you mean installed (rpm -ivh) or just extracted the files inside and put them under public\_html?
  
  > **Comments:**
  > **username_0**: Hi username_1, thanks for your reply. Your right I unpacked the .rpm into that location. I will move it to another location and try the full root URL.  For testing I just moved it to the main root directory and included the full path.  /home/dfcadmin18/usr/local/bin/wkhtmltopdf  Any advice would be much appreciated to get this to work. Thanks username_1  
  > **username_1**: I'm not sure if that will work since there are shared libraries also in the rpm which it might not be able to find if you don't actually install it, but it sounds like you only have cpanel access and a web-based file browser? Maybe I should ask why you're trying to install it. Civi doesn't need it to produce pdfs, it's just an alternate tool to replace the tool that comes with civi. If you really do need to install it and don't have root shell access, see also this link: https://stackoverflow.com/questions/2273534/how-to-install-wkhtmltopdf-on-a-linux-based-shared-hosting-web-server  
  > **username_0**: Well that is a good question that lead me onto wkhtmltopdf. Basically in CiviCRM the administrator is trying to make mailing labels within the advance search. When you get to picking your groups etc to make the labels and press on make mailing labels. The next screen is a blank URL. which some people told me that it was missing wkhtmltopdf, which made sense as it seems something is missing for that process to work, I just don't know what the missing step is. We did change server environment recently, I will add a screen shot to the main question and would be great if you had any ideas.  
  > **username_1**: And when you get the blank screen is the setting for wkhtmltopdf empty or do you have something in there? You would leave it empty to use the default tool.  
  > **username_1**: Also error 500 usually gives more info in the web server logs, which in cpanel I think is just called "error logs".  
  > **username_0**: Orginally the settings for wkhtmltopdf was blank. Like I said someone advised to look into wkhtmltopdf and set it up to see if that would resolve the issue.  
  > **username_0**: I will look into the error logs now and see if I can find out why the URL is coming back with error 500  
  > **username_2**: Might be worth checking with your hosting provider whether wkhtmltopdf is already installed.  
  
  ---
  
  