Help Center Search By Ticket ID

5 Comments

  • Jessie Schutz

    Thanks for contributing, Andrew!

    0
  • Andrew Checkley

    Works well thank you,

    Note to others, takes into account user access so will only allow the viewing of tickets either logged in the name of the current logged in user or those that user is CC'd into to. otherwise it fails over to the oops the page you were looking for doesn't exist.

    Thanks

    Andrew

    The page you were looking for doesn't exist – Support Portal

     

     

    0
  • Jessie Schutz

    Thanks for pointing that out, Andrew!

    0
  • Socorro Fernandez

    Thank you Andrew and Andrew!

    Though I am not completely versed in code or even consider myself a developer,  I greatly appreciate these types of examples as they give me the chance to learn by build off of them and create a script based on our teams needs.

    I believe my team will end up offering a link to the /hc/en-us/requests page when a customer searches a numeric value with no results rather than redirect the customer to the ticket request link. Mainly due to the customer experience and to avoid the error page, should they enter the wrong ticket ID or not have access to the ticket.

    There may be a few ways to do this but I ended up replacing line code:

    window.location = '/hc/en-us/requests/' + searchQuery;

    with the following:

     

    $( "p" ).append("<br><br> <strong>Looking for a Zendesk Request? Access all your requests here: </strong>").append('<div> <a href="https://YOURDOMAINHERE.zendesk.com/hc/en-us/requests">My Requests</a> </div>');
    }

     

    Here is what the search results section would look like if searching 12333 with no results, where it now offers a link to the my requests page:

     

    You would have the flexibility to add text/html to your teams needs, especially if you are using custom html.

    All credits to Andrew here! Thanks!

     

    1
  • Jessie Schutz

    Hey Socorro!

    This is really fantastic! If you're interested, it would be great if you could write this up as an official Tip here in Tips & Tricks. We even have guidelines for writing great tips, in case you're not sure where to start. There could be swag in it for you, too. :)

    0

Please sign in to leave a comment.

Powered by Zendesk