Cannot GET html file

When I try to click on the Report As link, I get an error: Cannot GET report_as.html.

I have a directory structure as follows:


In customer.html, I have the following code:

    <a href=${reportAsLink}
  Report As</a>

In customer.js:

// in constructor
//      this.reportAsLink = 'report_as.html?aris_id=';
      this.reportAsLink = '';

      {'./report_as.html?aris_id=' + aris_id, 'ReportAs', 
          'toolbars=0,width=400,height=600,scrollbars=1,location=yes,resizable=1,status=0, top=' 
          + ((screen.height/2) - (500/2) - 75) + ', left=' + ((screen.width/2) - (675/2)) 
          + '');

        return false;


The permissions on both customer and report_as are the same, but I can’t figure out why I get an error when trying to load this page?

1 Like

Are you sure you’re serving the actual HTML file from your server? It seems like you want to forward the user to a pop-up of a components HTML. But these typically get bundled inside the resulting js files. Which bundler are you using?

1 Like

By bundler, do you mean webpack vs something else?

If so, I am using webpack.

Is there a better way to serve an html file into a popup that you know of? I’ve tried googling, but I have not hit upon the right search terms to return answers.

1 Like

Not that easy I fear. The trouble is that as seen by your example you’d like to navigate to a page in the pop-up that is also Aurelia enhanced. So essentially the bootstrap/enhance needs to happen there as well.

Take a look here for perhaps a few more inputs How to open and syncronize a pop-up window?

Is there a reason this has to be a window pop-up? From the name I expect this to be a report, perhaps a PDF file or such. Could you describe your use case?

1 Like

Thanks for that link. I will give it a look.

My use case:

I have a form at the top of the page that you can enter a customer ID into.

It then loads a page of info on the customer.

There’s a Report As field that links it to other customers.

When you click on that link, it should open a small html page that shows all the other customers, each with a url to link to that customer.

1 Like

So does it necessarily have to be a new window pop-up/tab? Could you instead display the info in an inline dialog using aurelia-dialog?

1 Like

Oh that is a good idea - I was thinking about this last night too.

I’ve got some other popups that I need to figure out how to handle. Even if it’s just another tab on the page.

1 Like

Yeah perhaps give that a try. It should be also easier to handle for you since you can pass all the necessary data along with params like the id to dialog. Refer for that to the official docs

Let us know how this went. From an UX standpoint a dialog is typically always preferred to a native window pop-up. So it would be great if this works out for you

1 Like