cancel
Showing results for 
Search instead for 
Did you mean: 
12 Replies

Re: Print From URL not finding documents

Is the fix going to be considered for a new version of App Studio?

 

The majority of our Document Technology Partners and the small business they work with are using shared hosting so I'd hate to see them not be able to demo this.

 

Also, should this be added to the FAQ or caveat list?

 

Thanks

0 Kudos
XAS-Moderator
Xerox Employee
Xerox Employee

Re: Print From URL not finding documents

The cause has been determined for this.  The Print from URL app behaves differently based on the HTTP Server header.  IIS and Apache are supported servers, your host uses Nginx which changes the server header.  Nginx is a reverse proxy used in share hosting situations so while you may have Apache for the regular server the server header may be replaced by the Nginx header.  At this time there is not much you can do other than change hosts I believe.  If your host allows you to spoof the header then you can fix this by changing the server header to Apache.  A fix for this will require a new release of Xerox App Studio.

0 Kudos

Re: Print From URL not finding documents

After changing webhosts I was able to get this to work but I still feel there is an issue with the coding in the weblet. I feel this way becuse I can see the forms when connecting to http://cloudscanstation.com/forms but I can't see the forms when connecting to http://www.cloudscanstation.com/forms and the page source is identical.

 

 

Tony

0 Kudos

Re: Print From URL not finding documents

None of my apache servers will accept the trailing / in app studio but they accept it from the browser. I figured it was an app studio thing. During troubleshooting I used curl to see what the respons was.

 

When not using the trailing / - See get a 301 error -

ubnt@unifi:~$ curl cloudscanstation.com/forms
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>301 Moved Permanently</title>
</head><body>
<h1>Moved Permanently</h1>
<p>The document has moved <a href="http://cloudscanstation.com/forms/">here</a>.</p>
<hr>
<address>Apache Server at cloudscanstation.com Port 80</address>
</body></html>

 

There is no 301 error when putting the trailing /

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
 <head>
  <title>Index of /forms</title>
 </head>
 <body>
<h1>Index of /forms</h1>
<table><tr><th>&nbsp;</th><th><a href="?C=N;O=D">Name</a></th><th><a href="?C=M;O=A">Last modified</a></th><th><a href="?C=S;O=A">Size</a></th><th><a href="?C=D;O=A">Description</a></th></tr><tr><th colspan="5"><hr></th></tr>
<tr><td valign="top">&nbsp;</td><td><a href="/">Parent Directory</a></td><td>&nbsp;</td><td align="right">  - </td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="AppStudioFAQ09_2014.pdf">AppStudioFAQ09_2014.pdf</a></td><td align="right">19-Jan-2015 10:10  </td><td align="right">893K</td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="deploying-vyatta-core-firewall_33493.pdf">deploying-vyatta-core-firewall_33493.pdf</a></td><td align="right">21-Jan-2015 17:50  </td><td align="right">751K</td><td>&nbsp;</td></tr>
<tr><th colspan="5"><hr></th></tr>
</table>
<address>Apache Server at cloudscanstation.com Port 80</address>
</body></html>

 

Does it mean there is an issue with the trailing /?

 

EDIT: Personally, I think it's how the App is parsing the data when it comes back. I ran packet captures and they both appear to be successful.  I tried adding them here but it did not allow me to post them.

 

 

 

Tony

 

 

0 Kudos

Re: Print From URL not finding documents

That's weird cause on my Apache server I use "http://localhost:3000/test/" and it works without an issue.  I did what you said and I don't get that error but I don't get any files to print either.

0 Kudos

Re: Print From URL not finding documents

The invalid address error will always apper if there is a trailing slash added to the AppStudio URL. For exmaple: http://cloudscanstation.com/forms/ will fail but http://cloudscanstation.com/forms will not give the error. This has happened to me on any apache site that I have tested with.

 

I ran a network trace and I can see the device login, give the screen size and it is sent the html so i'm not sure whats going on there.

 

Can you try without the trailing backslash and see what result you get? I know I'm not the only one that is going to run into this so I'd love to figure this out. We have tons of our agent partners using shared hosting sites.

 

Thanks,

Tony

0 Kudos

Re: Print From URL not finding documents

When I create an app using your site I get a runtime error (see below)issue.jpg

 

It doesn't like your URL, I thought the lack of a www might be the cause but that doesn't appear to be the issue.   I tried to use the IP but that is blocked by your hosting method it appears. I then tried it with www.cloudscanstation.com and that didn't work either from the MFD.  I took the HTML from your page and hosted that and the device displayed it correctly so it's definately something with the hosting setup more than the Apache output.

0 Kudos

Re: Print From URL not finding documents

Sorry I was not clear in my above description. It is not working with http://cloudscanstation.com/forms. The server is located at a shared hosting provider so I'm not able to edit the apache.conf directly. I was able to change the .htaccess to include the IndexOptions and it chaged the code to the tabbed format versus the list format. Unfortunately, while the app connects to the server it does not show any documents. It's not a typo as I did a cut and paste out of the browser to make sure.

 

The code with the icon tags is from my local server with apache. When configured to the local server, it works fine. The only difference I saw between the local server and the other one is icon tags so I'm not sure what's going on.

 

 

 

 

 

 

 

 

0 Kudos

Re: Print From URL not finding documents

Maybe you made a typo, what's the issue?  You said it's working in both cases.  I did test your 

Options +Indexes
<IfModule mod_autoindex.c>
IndexOptions FancyIndexing HTMLTable NameWidth=* VersionSort 
</IFModule>

  and it was working for me.  If the second case isn't working I think it's cause of the img tag for the fancy indexing.  You need to remove the icons.

0 Kudos

Re: Print From URL not finding documents

As this is a shared server I can't make changes to the apache.conf file. I can use .htaccess however.

I created a new server cloudscanstation.com and edited the .htaccess file to include your suggestions. There are no other options in the .htaccess file. What you see bleow is the only code in the file.

Options +Indexes
<IfModule mod_autoindex.c>
IndexOptions FancyIndexing HTMLTable NameWidth=* VersionSort 
</IFModule>

Here is the resulting HTML to show the response in tab form versus a list as it was before but I still can see the documents.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
 <head>
  <title>Index of /forms</title>
 </head>
 <body>
<h1>Index of /forms</h1>
<table><tr><th>&nbsp;</th><th><a href="?C=N;O=D">Name</a></th><th><a href="?C=M;O=A">Last modified</a></th><th><a href="?C=S;O=A">Size</a></th><th><a href="?C=D;O=A">Description</a></th></tr><tr><th colspan="5"><hr></th></tr>
<tr><td valign="top">&nbsp;</td><td><a href="/">Parent Directory</a></td><td>&nbsp;</td><td align="right">  - </td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="App%20Studio%20FAQ%2009_2014.pdf">App Studio FAQ 09_2014.pdf</a></td><td align="right">19-Jan-2015 10:10  </td><td align="right">893K</td><td>&nbsp;</td></tr>
<tr><th colspan="5"><hr></th></tr>
</table>
<address>Apache Server at cloudscanstation.com Port 80</address>
</body></html>

 

When I use a local apache server I can see the documents and the code is also in a tab format.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
 <head>
  <title>Index of /forms</title>
 </head>
 <body>
<h1>Index of /forms</h1>
  <table>
   <tr><th valign="top"><img src="/icons/blank.gif" alt="[ICO]"></th><th><a href="?C=N;O=D">Name</a></th><th><a href="?C=M;O=A">Last modified</a></th><th><a href="?C=S;O=A">Size</a></th><th><a href="?C=D;O=A">Description</a></th></tr>
   <tr><th colspan="5"><hr></th></tr>
<tr><td valign="top"><img src="/icons/back.gif" alt="[PARENTDIR]"></td><td><a href="/">Parent Directory</a></td><td>&nbsp;</td><td align="right">  - </td><td>&nbsp;</td></tr>
<tr><td valign="top"><img src="/icons/layout.gif" alt="[   ]"></td><td><a href="test.pdf">test.pdf</a></td><td align="right">2015-01-21 08:50  </td><td align="right">  0 </td><td>&nbsp;</td></tr>
   <tr><th colspan="5"><hr></th></tr>
</table>
<address>Apache/2.4.7 (Ubuntu) Server at 192.168.1.40 Port 80</address>
</body></html>

 Any other thoughts?

 

Feel free to look me up in the Xerox global directory (Panos, Anthony)  if you want access to the server. Once this is working, my team will be using it for some external demonstrations.

 

Thanks,

Tony

0 Kudos