No announcement yet.

how to localize this!? php session timeout

  • Filter
  • Time
  • Show
Clear All
new posts

  • how to localize this!? php session timeout

    hi, when long time you don't use the project with security it comes this message:

    Unable to connect to the database: The php session time...

    I want to change it and write something else, where I can find this to change it? not in language, not in variable, not in code

    any idea?

  • #2
    TL;DR version: It's located in language under Validation -> lang_errm_dbcn_data

    Now the version for the people that like a good read and love happy endings:

    Not too long ago I was getting this error too but that was because my database connection wasn't setup correctly (if I remember correctly). Now as every sane person (obviously) would do I directly opened up the index.php from my main_menu and started looking where the error got echo'd. Now I've done my fair share of skimming code/texts so it didn't take all that long to find this piece of code:

    echo "<table width=\"80%\" border=\"1\" height=\"117\">"; echo "<tr>"; echo " <td class=\"css_menu_sel\">"; echo " <b><font size=\"4\">" . $this->Nm_lang['lang_errm_dbcn_data'] . "</font>"; echo " </b></td>"; echo " </tr>"; echo "</table>";
    Now as every maniac (this is the part where I stop referring to myself as sane person) can see in a quick glance this is an error message that gets the message from a Nm_lang (NetMake Language), so presuminly it's stored somewhere in the language settings.

    And for the happy ending: After seeing it being echo'd there I could see where in the code it originated from and what was causing it and from the code I deduced that it was a flaw in my database connection settings, I fixed it and me and my project/applicaton lived happily ever after.
    Last edited by hoihoi661; 03-12-2015, 06:21 AM. Reason: Made the TL;DR version easier to notice


    • #3
      In the php ini file, search for gc_maxlifetime you may want to use cookie_lifetime and cache_expire as well.
      Check out these settings can also be set in the php ini file.


      • #4
        hi guys, i don't have problem in timeout, i just want to make that message appear better than that bla bla and layout


        • #5
          Lay out wise you're probably not going to be able to change it, but as I mentioned in above post the message is in the language variables.


          • #6
            hi, yes hoiholi i saw that but still couldn't make the layout make sense, it still ugly


            • #7
              Well i guess you could put some HTML code in the language variable but apart from that idk.
              To be honest you saying it's that ugly makes me think the layout is defined somewhere as the one I'm getting here doesn't look all that terrible, could you get me a screenshot?