Unable to create invoice

v1.6.1 PHP 8.1 Hostinger

I installed v1.6.1 in a subdirectory and created a fresh database. I then imported my database sql from another hosting provider. I am able to see all my invoices and clients.

Viewing works for all items. I am able to create a Client and add a payment. I can also add producs and tasks.

I am unable to create an Invoice or a Quote. Doesn’t matter where I try and create it from. Clicking on the New button does not produce any results. I enabled debug and nothing appears in the log. Nothing appears in the web browser console log.

I noticed that the URL does not change in the browser when I click on the add/new invoice button. This occurs in both Firefox and Chrome browsers.

Any ideas?

1 Like

That’s a great place to start looking.
When you hover over the button, nothing happens in the status bar at the bottom either, correct?

How about when you use the menu options?
I’m interested in what shows at that status bar and whether clicking on that menu option gives you the correct result.

The console log… did you go to the Network tab or just the Javascript tab?
I think that New button is a link, styled as a button, but i’ll have to look at that coming weekend.

You are correct. When I hover over the create invoice or create quote, nothing appears in the status bar. I get the same results from the menu bar as I do from clicking on the buttons. Mouseover does not seem to work for either of those actions.

When you mouseover the menu item, the status bar will display whatever url you were using at the time. That is, if you were on view clients or view quotes, it would display that URL. Create quote and create invoice are the only two items where I see the problem.

1 Like

Check your PM.
When you hover over the button and nothing happens, right-click on that button and see if it belongs to a form.

The menu-items you said were showing something in the status-bar.
But when you click on them, will you still end up at that new page? Or also no response?

If I inspect the buttons or menu items that don’t work, they all have href=“#”

Button to create invoice
<a class="create-invoice btn btn-sm btn-primary" href="#">
            <i class="fa fa-plus"></i> New        </a>

Menu create invoice
<a href="#" class="create-invoice">Create Invoice</a>

I also tried:

  • Firefox private window
  • InvoicePlane 1.6.0 from github
  • PHP 8.2

I retired 3 years ago as a Software Quality Assurance Engineer and my skills are a little rusty but they are coming back the more I work on this.

1 Like

Aha! InvoicePlane isn’t compatible with PHP 8.2.
Let’s go for PHP 8.1 first, please

InvoicePlane 1.6.0 from github
Version 1.6.1 doesn’t have the solution, but may i suggest to go to version 1.6.1 from Github anyway?

ah, you misunderstood. I kept my original install at 1.6.1 PHP 8.1 and then I created a second temporaty install varying things like PHP version and InvoicePlane version. When I saw that neither resolved my problem, I deleted the secondary install.

1 Like

Open up ipconfig.php, you’ll be doing most of the fixing of this problem here …

### START HERE
# Set your URL without trailing slash here, e.g. http://your-domain.com
# If you use a subdomain, use http://subdomain.your-domain.com
# If you use a subfolder, use http://your-domain.com/subfolder
IP_URL=

The href with the # (sortof) triggers an ajax function:

$(document).on('click', '.create-invoice', function () {
            $('#modal-placeholder').load("...your-private-url-in-a-subfolder..index.php/invoices/ajax/modal_create_invoice");
        });

So try to load that Url: ..your-private-url-in-a-subfolder..index.php/invoices/ajax/modal_create_invoice, it should show some entries in your apache or nginx logs.

try to figure out if you’re using Apache or Nginx as your webserver.
If you’re using Apache, then you need to change the .htaccess file