IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Langage PHP Discussion :

Problème d'ouverture de session


Sujet :

Langage PHP

  1. #1
    Membre du Club
    Homme Profil pro
    Inscrit en
    Avril 2007
    Messages
    95
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations professionnelles :
    Secteur : High Tech - Multimédia et Internet

    Informations forums :
    Inscription : Avril 2007
    Messages : 95
    Points : 52
    Points
    52
    Par défaut Problème d'ouverture de session
    Salut , je debute dans les sessions et j'ai un gros probleme j'ai eu beau chercher sur le net je n'ai pas trouvé de reponse precise ...

    j'ai l'addresse de mon script :
    http://s145049280.onlinehome.fr/index.php
    et ma redirection : www.vali.fr.tc

    et l'identification marche tres bien avec l'addresse d'origine mais pas avec la redirection , j'ai tout éssayé sans comprendre d'ou ça pouvais venir ..

    voici le code de mon index (en gros) :

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
     
    <? session_start(); ?>
    <html>
    <head>
    <?
    include("fonction.php");
    ?>
     
    <title>GT</title>
    <link rel="stylesheet" type="text/css" href="style.css">
    </head>
     
    <body>
    <? 
     
       if(!isset($_SESSION['login'])) {
       include("identify.php");
       }else{
     
     
       switch($_GET['rub'])
      {
      case "listing": include("listing.php"); break; 
      case "taverne": include("taverne.php"); break; 
      case "poster": include("form.php"); break; 
      case "ndossier": include("form.php"); break; 
       case "rename": include("form.php"); break;
       case "chmod": include("form.php"); break;
      case "nfichier": include("form.php"); break; 
      case "about": include("about.php"); break; 
      case "admin": include("admin/admin.php"); break; 
      case "profil": include("profil.php"); break; 
      case "erreur": include("erreur.php"); break; 
      case "modperso": include("form.php"); break; 
      case "modrank": include("form.php"); break;
     case "modfich": include("form.php"); break; 
     case "rank": include("form.php"); break;
      case "copy": include("form.php"); break;
     case "historique": include("form.php"); break;
      case "compte": include("form.php"); break;
     case "censure": include("form.php"); break;
     case "smile": include("form.php"); break;
      case "modtav": include("form.php"); break; 
        case "mu": 
    	 ?> <SCRIPT LANGUAGE='JavaScript'>
    <!--
    function redirect()
    {
    window.location='upload/index.php'
    }
    setTimeout('redirect()',0002);
    -->
    </SCRIPT> <?
    	 break; 
      case "deco": 
      session_start();
      $_SESSION = array();
      session_destroy();
      ?> <SCRIPT LANGUAGE='JavaScript'>
    <!--
    function redirect()
    {
    window.location='index.php'
    }
    setTimeout('redirect()',0002);
    -->
    </SCRIPT> <?
       break; 
      default:
      include("listing.php");
        break;
    }}
       ?></td>
     
            <td>&nbsp;</td>
          </tr>
          <tr>
    	  <?  if(isset($_SESSION['login'])) {
    	  ?>
            <td width="30" height="18">&nbsp;</td>
    		  <td width="433" align="left" valign="top"><a href="index.php">Retour</a></td>
     
    		<? } ?>
            <td width="10">&nbsp;</td>
          </tr>
     
        </table></td>
      </tr>
     
     
      <tr width="442" height="17">
     
     
     
     
        <td width="442" height="17" background="images/img_04.jpg"><span class="txtmid">
        <div align="center">  GenesisTrader v1.0 by jango <a href="http://www.genesis-php.com">http://www.genesis-php.com</a></div>
        </span></td>
      </tr>
     
    </table>
    <p align="center"><font color="#990000" face="Geneva, Arial, Helvetica, sans-serif"><font size="2">Important : Cliquez sur le bouton droit de la souris pour acceder au menu javascript </font></font></p>
    <p align="center"><font color="#990000" size="1" face="Geneva, Arial, Helvetica, sans-serif"><font color="#CCCCCC"> http://s145049280.onlinehome.fr</font></font></p>
    <p>
      <? if(isset($_SESSION['login'])) {
    ?>
    </p>
    <table width="442" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#EBEBEB" bgcolor="#F5F5F5">
      <tr>
        <td align="left" valign="top"><div align="left">
          <table width="442" border="0" cellspacing="0" cellpadding="0">
            <tr>
              <td width="221"><div align="center">::Legende::</div></td>
              <td width="221"><div align="center">Mises a jour : </div></td>
            </tr>
          </table>
        </div></td>
      </tr>
      <tr>
        <td><table width="442" border="1" cellpadding="0" cellspacing="0" bordercolor="#CCCCCC">
          <tr>
            <td width="221"><table width="220" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td width="210" align="left" valign="top"><table width="110" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="46"><div align="center"><img src="images/del.jpg" width="11" height="10" /></div></td>
                      <td width="164"><div align="center">Supprimer</div></td>
                    </tr>
                    <tr>
                      <td height="20"><div align="center"><img src="images/modif.jpg" width="13" height="12" /></div></td>
                      <td><div align="center">Modifier</div></td>
                    </tr>
                </table></td>
                <td width="210"><table width="110" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="46"><div align="center"><img src="images/deplacer.jpg" width="18" height="17" /></div></td>
                      <td width="164"><div align="center">Deplacer</div></td>
                    </tr>
                    <tr>
                      <td><div align="center"><img src="images/mod.jpg" width="14" height="14" /></div></td>
                      <td><div align="center">Renommer</div></td>
                    </tr>
                </table></td>
              </tr>
            </table></td>
            <td width="221"><iframe src="http://kgftp.free.fr/MAJ.php" allowtransparency="true" name="maj" marginheight="0" marginwidth="0" frameborder="0" height="30" width="221"> D&eacute;sol&eacute; mais votre navigateur ne supporte pas les cadres locaux. </iframe></td>
          </tr>
        </table></td>
      </tr>
    </table>
    <p>&nbsp;</p>
    <p>
      <? } ?>
     
     
    </body>
    </html>


    j'espere que quelqu'un aura la solution magique parce que la je pete un cable

  2. #2
    Membre habitué Avatar de Aliosha
    Profil pro
    Inscrit en
    Mars 2007
    Messages
    124
    Détails du profil
    Informations personnelles :
    Âge : 37
    Localisation : France

    Informations forums :
    Inscription : Mars 2007
    Messages : 124
    Points : 138
    Points
    138
    Par défaut
    J'y connais pas grand chose en redirection, mais tu peux pas « embarquer » le $_SESSION dans ta redirection ?

  3. #3
    Membre du Club
    Homme Profil pro
    Inscrit en
    Avril 2007
    Messages
    95
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations professionnelles :
    Secteur : High Tech - Multimédia et Internet

    Informations forums :
    Inscription : Avril 2007
    Messages : 95
    Points : 52
    Points
    52
    Par défaut
    j'y ai pensé mais je ne vois pas comment faire , la redirection est assurée par Xdir.com il n'y a aucun endroit ou mettre du php en entete ...

    merci pour ta reponse !!

  4. #4
    Membre habitué Avatar de Sarrus
    Profil pro
    Inscrit en
    Mai 2005
    Messages
    180
    Détails du profil
    Informations personnelles :
    Localisation : France, Bas Rhin (Alsace)

    Informations forums :
    Inscription : Mai 2005
    Messages : 180
    Points : 138
    Points
    138
    Par défaut
    une variable de session est un fichier texte stocké sur le serveur. Si tu pars sur un autre site, tes variables ne seront plus accessibles.

  5. #5
    Membre du Club
    Homme Profil pro
    Inscrit en
    Avril 2007
    Messages
    95
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations professionnelles :
    Secteur : High Tech - Multimédia et Internet

    Informations forums :
    Inscription : Avril 2007
    Messages : 95
    Points : 52
    Points
    52
    Par défaut
    crotte , il n'y a dons aucun moyen de faire marcher un systeme de session avec une redirection? ça se saurais si c'etais pas faisable non?

  6. #6
    Membre habitué Avatar de Sarrus
    Profil pro
    Inscrit en
    Mai 2005
    Messages
    180
    Détails du profil
    Informations personnelles :
    Localisation : France, Bas Rhin (Alsace)

    Informations forums :
    Inscription : Mai 2005
    Messages : 180
    Points : 138
    Points
    138
    Par défaut
    sinon tu peux transmettre tes variables dans l'url de ta redirection, mais apres je sais pas jusqu'a quel point tu as accès à l'autre site...

Discussions similaires

  1. Problème d'ouverture de session
    Par sonorc dans le forum Linux
    Réponses: 7
    Dernier message: 02/11/2009, 18h51
  2. Problème d'ouverture de session sur un domaine
    Par cynoq dans le forum Windows XP
    Réponses: 2
    Dernier message: 23/06/2009, 14h05
  3. Problème d'ouverture de session
    Par Morphorpse dans le forum Windows Serveur
    Réponses: 1
    Dernier message: 16/10/2007, 22h54
  4. [UBUNTU] Problème à l'ouverture de session
    Par dumontad dans le forum Ubuntu
    Réponses: 4
    Dernier message: 22/04/2007, 09h54
  5. Probléme d'ouverture de session sous Windows 2000 server
    Par Orameur dans le forum Windows XP
    Réponses: 1
    Dernier message: 25/02/2006, 19h15

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo