Loading ...
Sorry, an error occurred while loading the content.

apories mazemenes

Expand Messages
  • Alaios
    Php 4.3. kai kati KAlispera tis teleytaies imeres to exo riksei sto maziko grapsimo php kodika kai tsoup mazepsa kapoies apories. Exo ena pedio TIMESTAMP se
    Message 1 of 4 , Feb 22, 2004
    • 0 Attachment
      Php 4.3. kai kati
      KAlispera tis teleytaies imeres to exo riksei sto
      maziko grapsimo php kodika kai tsoup mazepsa kapoies
      apories.
      Exo ena pedio TIMESTAMP se mia basi, me poia synartisi
      mporo na emfanizo sto xrisi ora lepta mera minas kai
      xronos?
      Antistrofa tora pos mporo mia ora pou diabaso apo to
      xristi na tin apothikeyso san TIMESTAMP sti basi?
      Gia na katastrepso to session (log out) kai oles tis
      metablites enos xristi arkei to session_destroy();


      Kati allo tora tin proti fora poy episkeftomai tin
      arxiki selida toy site mou (sto ie sta epomena refresh
      eksafanizetai eno ston konqueror fainetai synexeia)
      emfanizetai to parakato minima
      Warning: Unknown(): Your script possibly relies on a
      session side-effect which existed until PHP 4.2.3.
      Please be advised that the session extension does not
      consider global variables as a source of data, unless
      register_globals is enabled. You can disable this
      functionality and this warning by setting
      session.bug_compat_42 or session.bug_compat_warn to
      off, respectively. in Unknown on line 0

      Ti kano lathos?
      Eyxaristo

      __________________________________
      Do you Yahoo!?
      Yahoo! Mail SpamGuard - Read only the mail you want.
      http://antispam.yahoo.com/tools
    • Dimitris Glezos
      ... Κοίτα το mysql manual στο σημείο που μιλάει για τα Date-time πεδία, μπορείς να τα πάρεις με
      Message 2 of 4 , Feb 23, 2004
      • 0 Attachment
        Alaios wrote:

        > Exo ena pedio TIMESTAMP se mia basi, me poia synartisi
        > mporo na emfanizo sto xrisi ora lepta mera minas kai
        > xronos?

        Κοίτα το mysql manual στο σημείο που μιλάει για τα Date-time πεδία,
        μπορείς να τα πάρεις με καθαρά SQL εντολές.

        Εναλλακτικά μπορείς πάρεις το string που θα σου επιστρέψει η mysql, να
        το κάνεις explode (ή κάτι τέτοιο τέλος πάντων με php) και να σχηματίσεις
        μόνος σου την ημερομηνία που θέλεις με συναρτήσεις της php όπως τις
        mktime και date διαβάζοντας την παράγραφο "Date/Time συναρτήσεις" στο
        PHP manual.

        > Antistrofa tora pos mporo mia ora pou diabaso apo to
        > xristi na tin apothikeyso san TIMESTAMP sti basi?

        Και αυτό το λέει σε εκείνο το σημείο του mysql manual.

        > Gia na katastrepso to session (log out) kai oles tis
        > metablites enos xristi arkei to session_destroy();

        session_destroy() destroys all of the data associated with the current
        session. It does not unset any of the global variables associated with
        the session, or unset the session cookie.

        (http://www.php.net/manual/el/function.session-destroy.php)

        Καλό είναι να ρίχνεις μια ματιά στα manuals και μετά στο google πριν
        ρωτήσεις κάτι. Το πιο πιθανόν είναι να βρεις την απάντηση μόνος σου για
        τέτοιου είδους θέματα (λειτουργικές απορίες).

        (Χμ. Το έθεσα πολύ ευγενικά μπορώ να πω :)

        > Kati allo tora tin proti fora poy episkeftomai tin
        > arxiki selida toy site mou (sto ie sta epomena refresh
        > eksafanizetai eno ston konqueror fainetai synexeia)
        > emfanizetai to parakato minima
        > Warning: Unknown(): Your script possibly relies on a
        > session side-effect which existed until PHP 4.2.3.
        > Please be advised that the session extension does not
        > consider global variables as a source of data, unless
        > register_globals is enabled. You can disable this
        > functionality and this warning by setting
        > session.bug_compat_42 or session.bug_compat_warn to
        > off, respectively. in Unknown on line 0
        >
        > Ti kano lathos?

        Για δείξε τον κώδικα που προσπελαύνεις τις $_SESSION[] μεταβλητές. Το
        πιο πιθανόν είναι να μην έχεις ελέγξει αν είναι null μια global
        μεταβλητή που πας να διαβάσεις. Τι έκδοση *ακριβώς* PHP έχεις; Το
        global_vars το έχεις on ή off;

        Αυτό ήταν bug της PHP για κάποιες περιπτώσεις (το οποίο έχει διορθωθεί):
        http://bugs.php.net/bug.php?id=21312


        --
        Dimitris Glezos
        Jabber: subbie@..., PGP: 0xA5A04C3B
        http://dimitris.glezos.com/

        "He who gives up functionality for ease of use
        loses both and deserves neither." (Anonymous)
        --
      • Alaios
        PHP Version 4.3.3 register_globals=off etsi ksekino to session session_start(); if (! isset($_SESSION[ id ])) { //This id is being used for each guest
        Message 3 of 4 , Feb 23, 2004
        • 0 Attachment

           PHP Version 4.3.3

          register_globals=off

           

          etsi ksekino to session

          session_start();
          if (! isset($_SESSION['id']))
          {
             //This id is being used for each guest
            $_SESSION['id']=0;
            $_SESSION['LoginName']='Guest';
            $_SESSION['MemberType']='Guest';
            $_SESSION['LastLogin']=NULL;
          }



          Dimitris Glezos <glezos@...> wrote:


          Alaios wrote:

          > Exo ena pedio TIMESTAMP se mia basi, me poia synartisi
          > mporo na emfanizo sto xrisi ora lepta mera minas kai
          > xronos?

          ����� �� mysql manual ��� ������ ��� ������ ��� �� Date-time �����,
          ������� �� �� ������ �� ������ SQL �������.

          ����������� ������� ������ �� string ��� �� ��� ���������� � mysql, ��
          �� ������ explode (� ���� ������ ����� ������ �� php) ��� �� �����������
          ����� ��� ��� ���������� ��� ������ �� ����������� ��� php ���� ���
          mktime ��� date ����������� ��� ��������� "Date/Time �����������" ���
          PHP manual.

          > Antistrofa tora pos mporo mia ora pou diabaso apo to
          > xristi na tin apothikeyso san TIMESTAMP sti basi?

          ��� ���� �� ���� �� ������ �� ������ ��� mysql manual.

          > Gia na katastrepso to session (log out) kai oles tis
          > metablites enos xristi arkei to session_destroy();

          session_destroy() destroys all of the data associated with the current
          session. It does not unset any of the global variables associated with
          the session, or unset the session cookie.

          (http://www.php.net/manual/el/function.session-destroy.php)

          ���� ����� �� ������� ��� ����� ��� manuals ��� ���� ��� google ����
          �������� ����. �� ��� ������� ����� �� ����� ��� �������� ����� ��� ���
          ������� ������ ������ (������������ �������).

          (��. �� ����� ���� �������� ����� �� �� :)

          > Kati allo tora tin proti fora poy episkeftomai tin
          > arxiki selida toy site mou (sto ie sta epomena refresh
          > eksafanizetai eno ston konqueror fainetai synexeia)
          > emfanizetai to parakato minima
          > Warning: Unknown(): Your script possibly relies on a
          > session side-effect which existed until PHP 4.2.3.
          > Please be advised that the session extension does not
          > consider global variables as a source of data, unless
          > register_globals is enabled. You can disable this
          > functionality and this warning by setting
          > session.bug_compat_42 or session.bug_compat_warn to
          > off, respectively. in Unknown on line 0
          >
          > Ti kano lathos?

          ��� ����� ��� ������ ��� ������������� ��� $_SESSION[] ����������. ��
          ��� ������� ����� �� ��� ����� ������� �� ����� null ��� global
          ��������� ��� ��� �� ���������. �� ������ *�������* PHP �����; ��
          global_vars �� ����� on � off;

          ���� ���� bug ��� PHP ��� ������� ����������� (�� ����� ���� ���������):
          http://bugs.php.net/bug.php?id=21312


          --
          Dimitris Glezos
          Jabber: subbie@..., PGP: 0xA5A04C3B
          http://dimitris.glezos.com/

          "He who gives up functionality for ease of use
          loses both and deserves neither." (Anonymous)
          --



          --
          �������� PHP mailing list
          Yahoo! Groups Links

          <*> To visit your group on the web, go to:
          http://groups.yahoo.com/group/php_greek/

          <*> To unsubscribe from this group, send an email to:
          php_greek-unsubscribe@yahoogroups.com

          <*> Your use of Yahoo! Groups is subject to:
          http://docs.yahoo.com/info/terms/


          Do you Yahoo!?
          Yahoo! Mail SpamGuard - Read only the mail you want.
        • Dimitris Glezos
          ... Äïêßìáóå íá ìçí êÜíåéò cast óå NULL. -- Dimitris Glezos Jabber: subbie@jabber.org, PGP: 0xA5A04C3B http://dimitris.glezos.com/ He who
          Message 4 of 4 , Feb 23, 2004
          • 0 Attachment
            Alaios wrote:

            > session_start();
            > if (! isset($_SESSION['id']))
            > {
            > //This id is being used for each guest
            > $_SESSION['id']=0;
            > $_SESSION['LoginName']='Guest';
            > $_SESSION['MemberType']='Guest';
            > $_SESSION['LastLogin']=NULL;
            > }

            Δοκίμασε να μην κάνεις cast σε NULL.

            --
            Dimitris Glezos
            Jabber: subbie@..., PGP: 0xA5A04C3B
            http://dimitris.glezos.com/

            "He who gives up functionality for ease of use
            loses both and deserves neither." (Anonymous)
            --
          Your message has been successfully submitted and would be delivered to recipients shortly.