Help Desk Software & Beyond
June 28, 2017, 05:02:14 AM *
Welcome, Guest. Please login or register.
To post messages you need to register. We apologize for inconvenience, but this is to prevent spam.
Registration is instant (no email verification) and we do not ask for any personal information.

Login with username, password and session length
News: Welcome to Help Desk Software forum!
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: [REQ] Redirect to error page on submit failure  (Read 4268 times)
qtipextra
Newbie
*

Karma: 0
Posts: 15


View Profile
« on: August 11, 2015, 02:55:22 PM »

Hey TTX users! I know this forum is dead and all, but my 3.0 TTX installation is ALIVE and better than ever before! I've added some "custom" pages and modified the look and feel of it, but I'm lacking a function that I would like help with.

I have my typical newticket.html, with two others: newtick2.html, newtick3.html for new ticket template forms. The problem is when someone is on a secondary template, if required fields are not entered, the user is taken back to the "newticket.html" page with the "missing email..." etc. As my templates are used for different purposes, being re-directed to another page is confusing.

I would LIKE to be able to re-dir all form submit failures to another template.. say fail.html
This template would be a simple html file tells the user something like "Sorry but your ticket didn't get submitted". With a simple BACK button to go back to the original form they were attemtping to submit, instead of the one in newticket.html.

The above is all that is required, however, to add on this request, it would be awesome to be able to output ERROR box on this fail.html page. This should actually be the easy part because ERROR_BOX is written in the header.shtml file, so it would just sit on top.

---

Brainstorming - I thought this idea would be easy, but I cannot find where the browser is directed to the newticket.html template when the form is failed.

Another way around this, which I will be testing soon, would be to copy newticket.html to a new name (newtick1.html). Send all users that need this form to the new newtick1, rather then newticket. Then, edit newticket.html to be the error page instead.

However, if anyone else has any input, that would be awesome.
Logged
qtipextra
Newbie
*

Karma: 0
Posts: 15


View Profile
« Reply #1 on: August 11, 2015, 04:02:26 PM »

Another way around this, which I will be testing soon, would be to copy newticket.html to a new name (newtick1.html). Send all users that need this form to the new newtick1, rather then newticket. Then, edit newticket.html to be the error page instead.
THIS has been confirmed to work. Although it's annoying to have a failure page be called "newticket". If I could find where redirs happen and change that to a new "fail.html" template it would still be optimal - but I can work with the workaround I've posted until then.

it would be awesome to be able to output ERROR box on this fail.html page. This should actually be the easy part because ERROR_BOX is written in the header.shtml file, so it would just sit on top.
This works exactly as intended using the mod above.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1 RC3 | SMF © 2001-2006, Lewis Media Valid XHTML 1.0! Valid CSS!
Page created in 0.015 seconds with 19 queries.