Jump to content
  • 0
sunrisepro

Blesta In Subfolder, Can't View Invoices

Question

I have a WordPress site and Blesta is installed in a subfolder. The no login invoice payment pages are not visible and are showing up as 404 pages of the main site. I'm guessing this is due to some security setting - what do I need to do to resolve this? Thanks!

Share this post


Link to post
Share on other sites

11 answers to this question

Recommended Posts

  • 0

Try settings > System > general > root directory...

It shouldn't include blesta's folder

 

Ok, I've made this setting but it doesn't make sense to me since the Blesta subfolder is what's missing in the broken urls. In any case, I waited for the cron to run naturally instead of sending it myself and the urls were correct this time. I also sent it manually and the urls were correct there too.

 

Much thanks for all the help!

Share this post


Link to post
Share on other sites
  • 0

I have a WordPress site and Blesta is installed in a subfolder. The no login invoice payment pages are not visible and are showing up as 404 pages of the main site. I'm guessing this is due to some security setting - what do I need to do to resolve this? Thanks!

 

 

I think the .htaccess from wordpress directory needs some twicking :)

 

Try this solution:

 

Open your Wordpress folder and edit the file .htacess  (make a backup of the file first)

 

Then remove all content and put this (change [blesta-sub-folder] with your blesta sub-folder name):

 

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_URI} ^/[blesta-sub-folder]/(.*)$ [OR]
RewriteRule ^.*$ - [L]
</IfModule>

Then try it :) hope it helps ;)

Share this post


Link to post
Share on other sites
  • 0

Ah - I see part of the problem. My Blesta install is at mydomain.com/backstage and the invoice url is going to mydomain.com/client. The invoice works if I alter the url to be mydomain.com/backstage/client.

 

I'm not sure where to edit that - I found where to edit the relative path to Blesta's folder on the server but not the install's base url.

Share this post


Link to post
Share on other sites
  • 0

I have some more weirdness. I made myself a test account and created a manual invoice. After creating the invoice it had no 'sent' in the Status column. I checked that row & clicked the submit button that appeared below it to send the invoice. The 'The selected invoices were successfully delivered.' message appeared as confirmation.

 

I received *two* invoice emails, 4 minutes apart.

 

The first email had the both the login link and Pay Now link correct.

 

The second email had both incorrect & was missing Blesta's subfolder in the url.

 

I went to the email templates page. I looked at the templates for Invoice Delivery (Unpaid), Invoice Notice (1st), Invoice Notice (2nd) & Invoice Notice (3rd). None of those templates have the same text as the invoice due emails I received. So I'm not sure where to even edit the text.

 

If my clients are receiving two emails, they may look at the second one and be unable to pay with the bad links. It's odd, no, that one email has correct links and another one does not?

 

Also, I just resent the invoice and received only 1 - with the correct urls. So it appears that the email with the incorrect links is the one sent automatically when an invoice is created?

Share this post


Link to post
Share on other sites
  • 0

I have some more weirdness. I made myself a test account and created a manual invoice. After creating the invoice it had no 'sent' in the Status column. I checked that row & clicked the submit button that appeared below it to send the invoice. The 'The selected invoices were successfully delivered.' message appeared as confirmation.

 

I received *two* invoice emails, 4 minutes apart.

 

The first email had the both the login link and Pay Now link correct.

 

The second email had both incorrect & was missing Blesta's subfolder in the url.

 

I went to the email templates page. I looked at the templates for Invoice Delivery (Unpaid), Invoice Notice (1st), Invoice Notice (2nd) & Invoice Notice (3rd). None of those templates have the same text as the invoice due emails I received. So I'm not sure where to even edit the text.

 

If my clients are receiving two emails, they may look at the second one and be unable to pay with the bad links. It's odd, no, that one email has correct links and another one does not?

 

Also, I just resent the invoice and received only 1 - with the correct urls. So it appears that the email with the incorrect links is the one sent automatically when an invoice is created?

 

The invoice send unless forced to send uses the cron job and therefore sends every 5 minutes. Yes it sounds like the root url is wrong or the cron job is wrong. Do you have teamviewer for me to come and join you and see if we can solve it?

Share this post


Link to post
Share on other sites
  • 0

1) What is teamviewer?

 

2) How come the urls are correct in one email but not in the other?

 

3) Why can't I find the email template to edit the text? None of the templates I checked matched the text.

 

1) Teamviewer.com: Remote control any computer or Mac over the internet within seconds or use TeamViewer for online meetings. 

 

2) Because when you use the manual button it's running the cron job manually, using the folder it's in. When you are using the cron job it's using the url you have there and using the root url / etc to send the email relating to your issue.

 

3) it's a special tag which does it which is why you can't set it.

Share this post


Link to post
Share on other sites
  • 0

Try settings > System > general > root directory...

It shouldn't include blesta's folder

Make sure this path is correct. The cron may not set the correct paths in email template URLs via CLI mode if this value is incorrect. This is almost certainly the cause of the problem you are experiencing.

 

The "sent status" that appears next to invoices is only updated when the invoice is sent automatically. If you have the cron enabled to send invoices, as it appears you do, then the invoice will be sent the next time the cron runs. There is no need to send it manually as well unless for some other reason.

 

Invoices will be delivered based on either the Invoice Delivery (Unpaid) or Invoice Delivery (Paid) templates depending on whether the invoice has been paid. The payment URL is generated automatically and replaces the {invoice.payment_url} tag from the template when the invoice is sent.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...