osTicket not working certain things not loading nginx

// = osTicket not working certain things not loading nginx :id: 9365dbb0-5c35-407c-a68f-4b7620e99365 :author: Andrei Clinciu :website: https://andreiclinciu.net/ :publish_at: 2017-12-13 20:48:00Z :heading_image: /images/blog//old_uploads/osticket_logs_2017-12-13-110334-825x310.png :description: \N :type: article :tags: :keywords: :toc: left :imagesdir: ../assets/

image::{heading_image}[] There is an  ajax issue while using using nginx with osTicket due to redirects.

Certain things will not load and if you look in your error log file you will see something like the following: + image:/images/blog/old_uploads/screenshot_2017-12-13-110334.png[image]

You should change file:///helpdesk[/helpdesk/] to whatever subfolder you have the osTicket hosted to. + This will also solve problems in the scp but also in the normal working..

Add this to the server config + …. probably here you have other fastcti_params

[source,lang:default,decode:true]

set $path_info “”;# Requests to /api/* need their PATH_INFO set, this does thatif ($request_uri ~ “^/helpdesk/api(/[^\?]+)”) {\tset $path_info $1;}# /api/. should be handled by /api/http.php if the requested file does not existlocation ~ ^/helpdesk/api/(tickets|tasks)(.)$ {\ttry_files $uri $uri/ /helpdesk/api/http.php;}# /scp/ajax.php needs PATH_INFO too, possibly more files need it hence the .\.phpif ($request_uri ~ “^/helpdesk/scp/.\.php(/[^\?]+)”) {\tset $path_info $1;}if ($request_uri ~ “^/helpdesk/.\.php(/[^\?]+)”) {\tset $path_info $1;} \tfastcgi_param PATH_INFO $path_info;# Make sure requests to /scp/ajax.php/some/path get handled by ajax.phplocation ~ ^/helpdesk/scp/ajax.php/(.)$ {\ttry_files $uri $uri/ /helpdesk/scp/ajax.php;} # Make sure requests to /ajax.php/some/path get handled by ajax.phplocation ~ ^/helpdesk/ajax.php/(.)$ {\ttry_files $uri $uri/ /helpdesk/ajax.php;}

 

 

Subscribe to my Newsletter

Receive emails about Linux, Programming, Automation, Life tips & Tricks and information about projects I'm working on