Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    Regular Coder
    Join Date
    Aug 2006
    Posts
    133
    Thanks
    0
    Thanked 0 Times in 0 Posts

    problems with customer support system

    hi guys,

    we are using isolsoft customer support system for our website.our company is a web hosting company.the clients can login and post their tickets.the problem is with login system.80% of clients can login easily but the remaining 20% some times canot login.after trying 5-6 times they will login.what do you think where the problem is.can you have any idea about it.your help will be appreciated.i think the problem is in session configuaration in php.ini file.the isolsoft has used the class DB_eSession for storing the session info in mysql db.we have contacted isolsoft many times but dont get any solution for this.

    thanks
    mrjameer

  • #2
    God Emperor Fou-Lu's Avatar
    Join Date
    Sep 2002
    Location
    Saskatoon, Saskatchewan
    Posts
    16,987
    Thanks
    4
    Thanked 2,660 Times in 2,629 Posts
    If they cannot log in, assuming that the correct information has been provided, its down to a session and / or browser issue.
    Generally with any database driven session scripts that I have created, the problem lies in a browser not accepting cookies, and unable to correctly identify the value of the session id. I would check first to see if the problem exists due to the user rejecting cookies and go from there. If the problem only exists when the browser does not accept cookies, check the scripting to make sure that the correct session ids are being appended to the uri.

    Without seeing any code however, this may be a difficult issue for us to resolve. If the company is not returning your requests for support, I would almost recommend seeking a new consumer support software.
    PHP Code:
    header('HTTP/1.1 420 Enhance Your Calm'); 

  • #3
    ess
    ess is offline
    Regular Coder
    Join Date
    Oct 2006
    Location
    United Kingdom
    Posts
    866
    Thanks
    7
    Thanked 30 Times in 29 Posts
    Agree with Fou-Lu.

    I would like to point something else out.

    Recently, it came to my attention that you cannot rely upon storing User_Agent values for the purpose of validating sessions.

    In other words, in the past, I used to store a lot of information about the user, what browser they are using, their ip address and other information whilst they are logged in to the sites....so that I can cross check these values with every request to ensure that they are who they say they are.

    However, I discovered that the value of the User_Agent changes if the user is behind a Proxy. As such, when validating the session, it fails and users would be logged out...because of this.

    The point I am trying to make here is that you should check if the system you are currently using relies on validation of User_Agents. if that is the case, disable that feature if you would want to allow users behind a proxy to access your website.

    good luck.
    Ess

  • #4
    Senior Coder CFMaBiSmAd's Avatar
    Join Date
    Oct 2006
    Location
    Denver, Colorado USA
    Posts
    3,036
    Thanks
    2
    Thanked 316 Times in 308 Posts
    The application you are using is a purchased product. The company you purchased if from should provide you with support. If they aren't, can't, or won't, you might be out of luck.

    The proper way to get PHP to use a custom session handler is not how this code was written.

    In your other post in this forum about your custom php.ini (which is not really what that was), there are a number of the lines in the configuration section that are commented out. These settings are probably necessary for the code to work.
    If you are learning PHP, developing PHP code, or debugging PHP code, do yourself a favor and check your web server log for errors and/or turn on full PHP error reporting in php.ini or in a .htaccess file to get PHP to help you.

  • #5
    Regular Coder
    Join Date
    Aug 2006
    Posts
    133
    Thanks
    0
    Thanked 0 Times in 0 Posts
    hi
    this my login script

    <?php


    require "conf/conn.php";
    require "conf/conf.php";
    if (empty($lang)) {$lang=$c_lang;}
    $templang="lang.$lang.php";
    require "lang/".$templang;
    require "inc/functions.php";
    require_once('inc/csession.php');


    if (isset($username)) {
    $S_login_failed = false;

    $pass=sha1($pass);

    $S_redirectLoginSuccess="index.php";
    if ($username !="" AND $pass!=""){

    $query="SELECT * FROM users WHERE user='$username' AND password='$pass' AND active='1' AND level='3' AND validated='1'";

    $req = mysql_query($query) or die("<B>Error ".mysql_errno()." :</B> ".mysql_error()."");

    if (mysql_num_rows($req)!=0) {
    $row=mysql_fetch_array($req);
    $sess_param['errors_path'] = 'inc/';
    $sess_param['new_sid'] = TRUE;
    $sess_param['security_level'] = 200;
    $sess_param['gc_maxlifetime'] = $c_sesstime;

    $sess = new DB_eSession($sess_param);

    $sess->setSessVar('authenticated', TRUE);
    $sess->setSessVar('sess_userid', $row['id']);
    $sess->setSessVar('sess_useremail', $row['email']);
    $sess->setSessVar('sess_timezone', $row['timezone']);
    $sess->setSessVar('sess_language', $templang);
    $sess->setSessVar('sess_action', ACT_LOGIN);
    $sess->setSessVar('sess_actionarg', "");
    $sess->setSessVar('sess_username', $username, ENCRYPT_VALUE, EXTRA_FIELD);

    $user_id=$row['id'];
    $S_login_failed = false;

    $last_login = time();

    $query = "UPDATE users SET last_login ='$last_login' WHERE id = '$user_id'";

    $req = mysql_query($query) or die("<B>Error ".mysql_errno()." :</B> ".mysql_error()."");

    if (!empty($ticketid)){
    header ("Location: viewticket.php?ticket=$ticketid");
    exit;
    } else {
    $sess->setSessVar('sess_action', ACT_MAIN);
    header ("Location: $S_redirectLoginSuccess");
    exit;
    }

    }else {
    $S_login_failed = true;

    $query="SELECT * FROM users WHERE BINARY user='$username' AND BINARY password='$pass'";

    $req = mysql_query($query) or die("<B>Error ".mysql_errno()." :</B> ".mysql_error()."");

    if (mysql_num_rows($req)!=0) {
    $row=mysql_fetch_array($req);
    if ($row["validated"]== 0) {$error_log = $t_novalidation;}
    elseif ($row["active"]== 0) {$error_log = $t_inactive;}
    } else {
    $error_log = "$t_noexistuser $t_or $t_passincorrecto";
    }
    }
    } else {
    $S_login_failed = true;
    $error_log = "$t_noexistuser $t_or $t_passincorrecto";
    }
    }


    if (isset($tkey)) {

    $S_login_failed = false;
    $S_fldUserAuthorization="level";
    $S_redirectLoginSuccess="index.php";

    if ($tkey !="" AND $email!=""){

    $karray=explode("-", $tkey); $key =$karray[0]; $id =$karray[1];
    $query="SELECT * FROM support WHERE BINARY tkey='$key' AND Ticket='$id' AND BINARY user_email='$email'";
    $req = mysql_query($query) or die("<B>Error ".mysql_errno()." :</B> ".mysql_error()."");

    if (mysql_num_rows($req)!=0) {
    $row_user=mysql_fetch_array($req);
    $user_id = $row_user[user_id];
    $ticketid = $row_user[Ticket];

    $query="SELECT * FROM users WHERE id='$user_id' AND active='1' AND level='3' AND validated='1'";
    $req = mysql_query($query) or die("<B>Error ".mysql_errno()." :</B> ".mysql_error()."");

    if (mysql_num_rows($req)!=0) {
    $row=mysql_fetch_array($req);
    $sess_param['errors_path'] = 'inc/';
    $sess_param['new_sid'] = TRUE;
    $sess_param['security_level'] = 3;
    $sess_param['gc_maxlifetime'] = $c_sesstime;
    $sess = new DB_eSession($sess_param);
    $sess->setSessVar('authenticated', TRUE);
    $sess->setSessVar('sess_userid', $row['id']);
    $sess->setSessVar('sess_useremail', $row['email']);
    $sess->setSessVar('sess_timezone', $row['timezone']);
    $sess->setSessVar('sess_language', $templang);
    $sess->setSessVar('sess_action', ACT_VIEW_TICKET);
    $sess->setSessVar('sess_actionarg', "$ticketid");
    $sess->setSessVar('sess_username', $row['user'], ENCRYPT_VALUE, EXTRA_FIELD);
    $user_id=$row['id'];
    $S_login_failed = false;

    $last_login = time();
    $query = "UPDATE users SET last_login ='$last_login' WHERE id = '$user_id'";
    $req = mysql_query($query) or die("<B>Error ".mysql_errno()." :</B> ".mysql_error()."");

    if (!empty($ticketid)){
    header ("Location: viewticket.php?ticket=$ticketid");
    exit;
    } else {
    header ("Location: $S_redirectLoginSuccess");
    exit;
    }
    }else {
    $S_login_failed = true;

    if ($c_allowpticket == 1){
    header ("Location: viewpticket.php?tkey=$tkey&email=$email&lang=$lang");
    } else {
    $error_log = $t_notregistered;
    }
    }
    } else {
    $S_login_failed = true;
    $error_log = $t_emailkeyerror;
    }
    } else {
    $S_login_failed = true;
    $error_log = $t_emailkeyerror;
    }
    }

    ?>
    <html>
    <head>
    <title><?php echo $c_title; ?></title>
    <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $t_charset; ?>">
    <script language="JavaScript" src="validate.js"></script>

    <script language="JavaScript">
    <!--
    function jumpMenu(qid)
    {
    qid = document.formlogin.lang.value;
    url = "login.php?lang=" + qid;
    document.location = url;
    }
    //-->
    </script>

    <STYLE type="text/css">
    <?php include('style.php'); ?>
    </STYLE>
    </head>
    <body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
    <?php
    $sql = "SELECT header FROM templates";
    if($result = mysql_query($sql)) {
    if($head = mysql_fetch_array($result)) {
    echo stripslashes($head["header"]);
    }
    }
    if (isset($adduser) and $c_allowsubscript == 1 ) {
    include("adduser.php");

    } else {
    ?>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
    <tr>
    <td width="85%" height="20" class="menuuser" valign="center" align="left"> &nbsp;&nbsp;&nbsp;
    <?php echo "<img src=\"images/arrow_grey.gif\" width=\"8\" height=\"11\"> <a href=\"login.php?lang=$lang\" class=\"smenu\">$t_login</a>"; ?> &nbsp;
    <?php if ($c_allowsubscript == 1) { echo "<img src=\"images/arrow_grey.gif\" width=\"8\" height=\"11\"> <a href=\"login.php?adduser=true&lang=$lang\" class=\"smenu\">$t_suscrib</a>"; } ?> &nbsp;
    <?php echo "<img src=\"images/arrow_grey.gif\" width=\"8\" height=\"11\"> <a href=\"rempass.php?lang=$lang\" class=\"smenu\">$t_forgotpass</a>"; ?> &nbsp;
    <?php if ($c_allowpticket == 1) { echo "<img src=\"images/arrow_grey.gif\" width=\"8\" height=\"11\"> <a href=\"newpticket.php?lang=$lang\" class=\"smenu\">$t_request</a>"; } ?> &nbsp;
    <?php if ($c_allowpkb == 1) { echo "<img src=\"images/arrow_grey.gif\" width=\"8\" height=\"11\"> <a href=\"pkb.php?lang=$lang\" class=\"smenu\">$t_kb</a>"; } ?> &nbsp;
    </td>
    </tr>
    </table>
    <p></p>
    <table width="90%" border="0" cellspacing="0" cellpadding="0" class="border" align="center">
    <tr>
    <td>
    <table width="100%" border="0" cellspacing="1" align="center">
    <tr>
    <td align="center" class="menu">
    <?php echo $c_title; ?>
    -
    <?php echo $t_login; ?>
    </td>
    </tr>
    <tr>
    <td bgcolor="#FFFFFF" align="center" height="250"><br>
    <noscript>
    <strong><font color="#FF0000">Warning! This heldesk requires a browser with javascript
    enabled. You can't access to the helpdesk. </font></strong><br><br>
    </noscript>
    <?php if (empty($S_login_failed)){ ?>
    <?php echo $c_welcomemsg; ?>
    <br>
    <form name="formlogin" method="post" action="login.php">
    <table width="300" border="0" cellspacing="0" cellpadding="0" align="center" class="border">
    <tr>
    <td>
    <table width="300" border="0" cellspacing="1" cellpadding="1">
    <tr align="center">
    <td colspan="2" class="submenu"> <?php echo $t_titlogin; ?></td>
    </tr>
    <td width="37%" class="descrip"><?php echo $t_user; ?>:</td>
    <td width="63%" class="dat">
    <input type="text" name="username" value="<?php if (isset($user)) echo $user; ?>">
    </td>
    </tr>
    <tr>
    <td width="37%" class="descrip"><?php echo $t_pass; ?>:</td>
    <td width="63%" class="dat">
    <input type="password" name="pass">
    </td>
    </tr>
    <tr>
    <td width="118" class="descrip"><?php echo $t_language; ?>:</td>
    <td width="322" class="dat">

    <select name="lang" onChange="javascript:jumpMenu();">

    <option value="en" <?php if ($lang=="en") echo "selected"; ?>>English</option>
    <option value="es" <?php if ($lang=="es") echo "selected"; ?>>Espa&ntilde;ol</option>
    <option value="fr" <?php if ($lang=="fr") echo "selected"; ?>>Francais</option>
    <option value="ge" <?php if ($lang=="ge") echo "selected"; ?>>Deutsch</option>
    <option value="it" <?php if ($lang=="it") echo "selected"; ?>>Italiano</option>
    <option value="nl" <?php if ($lang=="nl") echo "selected"; ?>>Nederland</option>
    <option value="ru" <?php if ($lang=="ru") echo "selected"; ?>>Russian</option>
    <option value="se" <?php if ($lang=="se") echo "selected"; ?>>Swedish</option>
    </select>
    <input type="hidden" name="ticketid" value="<?php if (isset($ticket)) echo $ticket; ?>">
    </td>
    </tr>
    <tr>
    <td class="submenu" colspan="2" align="center">
    <input type="submit" name="Submit" value=" <?php echo $t_login; ?> ">
    </td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    <br>
    </form>

    <form name="formvticket" method="post" action="login.php">
    <table width="300" border="0" cellspacing="0" cellpadding="0" align="center" class="border">
    <tr>
    <td>
    <table width="300" border="0" cellspacing="1">
    <tr align="center">
    <td colspan="2" class="submenu"><?php echo $t_viewticket; ?></td>
    </tr>
    <tr>
    <td width="37%" class="descrip"><?php echo $t_email; ?>:</td>
    <td width="63%" class="dat">
    <input type="text" name="email" value="<?php if (isset($email)) echo $email; ?>">
    </td>
    </tr>
    <tr>
    <td width="37%" class="descrip"><?php echo $t_ticketid; ?>:</td>
    <td width="63%" class="dat">
    <input type="text" name="tkey">
    </td>
    </tr>
    <tr>
    <td class="submenu" colspan="2" align="center">
    <input type="submit" name="Submit" value="<?php echo $t_viewticket; ?>">
    <input type="hidden" name="ticketid" value="<?php if (isset($ticket)) echo $ticket; ?>">
    <input type="hidden" name="lang" value="<?php echo $lang ?>">
    </td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    </form>
    <br>
    <?php } else {
    ?>
    <p>&nbsp;</p>
    <p>
    <?php echo $error_log; ?>
    </p>
    <p><a href="#" onClick="history.go(-1)">
    <?php echo $t_back; ?>
    </a></p>
    <?php } ?>
    </td>
    </tr>
    <tr>
    <td align="center" class="menu">
    <?php echo $c_title; ?>
    </td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    <p align="center"><font size="1">Powered by: Support Center v2.2<br>
    Copyright &copy; 2005, <a href="http://www.isolsoft.com">IsolSoft.com</a>. All
    rights reserved</font></p>
    <?php
    }
    $sql = "SELECT footer FROM templates";
    if($result = mysql_query($sql)) {
    if($foot = mysql_fetch_array($result)) {
    echo stripslashes($foot["footer"]);
    }
    }
    ?>
    </body>
    </html>


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •