email options

Helpdesk for my helpdesk software

Moderator: mkoch227

Post Reply
southernmoney
Posts: 46
Joined: Sun May 10, 2009 3:44 pm

email options

Post by southernmoney »

Version of script: Current

Message: The current version is allowing a client to enter his or her email address. However, when our agents become involved we need to enter the email address of the agent as wel as the client, but the size of the insert box does not allow two addresses if they are too long.

What do I have to change the insert box code in order for lets say 60 Characters to be allowed to be inserted.

jvz
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

In the index.php change the maxlength value for e-mail field. For example change maxlength="50" to maxlength="255"

You will also need to modify the "email" column in "hesk_tickets" table from varchar(50) to varchar(255).
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
southernmoney
Posts: 46
Joined: Sun May 10, 2009 3:44 pm

Email Address Options

Post by southernmoney »

Hi Klemen,

I appologize for only attending to this now. I was ill.

I fully understand the 1st part of your solution.

However, I do not understand: You will also need to modify the "email" column in "hesk_tickets" table from varchar(50) to varchar(255).

Where exactly is this column and where do I find the file "hesk_tickets"

Thanks for your assistance.

jvz
Sampler
Posts: 9
Joined: Mon Mar 10, 2008 1:08 pm

Post by Sampler »

It is not a file, it's the database table that holds the information as the database table is also restricted to 5 columns of data you will need to change the table type to a longer version (varchar(255)).
This message has been transmitted on 100% recycled electrons.
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

As Sampler pointed out the database itself is the one with the limitation as well.

You could modify the table using a database management tool like phpMyAdmin (most hosting companies have it installed) or you can try this:

1. backup your existing database
2. save this code as "dbupdate.php"

Code: Select all

<?php
define('IN_SCRIPT',1);
define('HESK_PATH','../');

require('../hesk_settings.inc.php');
$hesk_settings['debug_mode'] = 1;
require('../inc/common.inc.php');
require('../inc/database.inc.php');

$hesk_db_link = @mysql_connect($hesk_settings['db_host'],$hesk_settings['db_user'], $hesk_settings['db_pass']) or $db_success=0;
$sql="ALTER TABLE `".hesk_dbEscape($hesk_settings['db_pfix'])."tickets` CHANGE `email` `email` varchar(255) NOT NULL default ''";
$result = hesk_dbQuery($sql) or die("MySQL error!<br />Query: $sql<br /><br />Error info: " . mysql_error());

echo "E-mail column modified, <b>DELETE THIS FILE NOW</b>";
?>
3. upload dbupdate.php to your server inside the "admin" folder
4. open it in your browser, for example:
http://www.yourdomain.com/hesk/admin/dbupdate.php
5. delete the dbupdate.php file from your server

This should do the trick but I haven't tested it, let me know how it goes.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
southernmoney
Posts: 46
Joined: Sun May 10, 2009 3:44 pm

Email Options

Post by southernmoney »

Hi Klemen,

I have used my phpmyadmin tool to change the email varchar setting from 50 to 255.

I then changed the index.php maximum length setting from 50 to 255.

When I filed a ticket as if I am a client I managed to insert the following ............ but not one of these addresses received an acknowledgement email. However, the ticket was correctly registered with all three addresses.

I then posted a new ticket with one email address and all worked fine. I then selected edit and managed to enter ............ but nothing more. Both addresses received the acknowledgement.

My needs: Client posts his ticket. I then wish to edit his post to add two more email addresses.

Thank you for your kind assistance.

jvz
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

Try separating e-mails with a comma instead, like this:

one@one.com, two@two.com, three@three.com
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
southernmoney
Posts: 46
Joined: Sun May 10, 2009 3:44 pm

Email Options

Post by southernmoney »

Hi Klemen,

The suggestion helped to now being able to send and receive for example three emails of acknowledgement of ticket registered.

However, when I go to edit ticket and wish to add a email address it refuses to take any further characters.

Please help.

Regards.

jvz
Southern Money
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

You need to modify the maxlength="50" value in edit_post.php
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
southernmoney
Posts: 46
Joined: Sun May 10, 2009 3:44 pm

Email Options

Post by southernmoney »

Hi Klemen,

I have used my phpmyadmin tool to change the email varchar setting from 50 to 255.

I then changed the index.php maximum length setting from 50 to 255.

I then changed the edit_post.php maximum length setting from 50 to 255.

I seperate the email addresses with a comma.

And it worked nicely!!!

Thank you very much.

Regards

jvz

www.southernmoney.co.za
Post Reply