Bonjour,
j'utilise depuis pas mal de temps free comme hebergeur et j'ai fais un site très pratique pour créer sa page perso avec gestion de liens favoris.
Le problème c'est que depuis quelques jours mes boucles d'affichage des données qui sont dans ma base ne semblent plus fonctionner
Alors que le site fonctionnait très bien avant.
Je m'explique :
Sur ma page j'ai des blocs qui doivent d'afficher les uns en dessous des autres (affichage fait avec une boucle donc) mais maintenant il n'y a plus qu'un seul bloc qui s'affiche alors que dans ma base de donnée il y en a plusieurs.
Exemple: http://start.accueil.free.fr
sur la gauche j'ai un bloc appelé "Pratique" avec des liens dedans, mais normalement en dessous je devrais en avoir d'autre. Pareil pour la colonne de droite avec le bloc appelé "Internet".
Auriez vous entendu quelque chose dont free aurai modifié sur les pages perso? Y-a-t'il une limitation du nombre de requète en php/msql sur une page?
Merci de votre aide.
P.S: Voici la structure de ma table pour la colonne de gauche et quelques données pour exemple :
Voici le fichier source php qui affiche les blocs les uns en dessous des autres :
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 CREATE TABLE `menu_gauche` ( `id_lien` int(255) NOT NULL auto_increment, `id_menu` int(10) NOT NULL default '0', `nom_menu` varchar(50) NOT NULL default '', `lien` varchar(255) NOT NULL default '', `position` varchar(100) NOT NULL default '', `nom_lien` varchar(60) NOT NULL default '', `id_user` int(10) NOT NULL default '1', PRIMARY KEY (`id_lien`) ) ENGINE=MyISAM AUTO_INCREMENT=268 DEFAULT CHARSET=latin1 AUTO_INCREMENT=268 ; -- -- Contenu de la table `menu_gauche` -- INSERT INTO `menu_gauche` VALUES (215, 1, 'BLOG', 'http://prisstatoo.skyblog.com', '2', 'Priscilla', 9); INSERT INTO `menu_gauche` VALUES (189, 1, 'Culturel', 'http://xenderillimited.free.fr/search.php?search_id=newposts', '2', 'Illimited EDK', 6); INSERT INTO `menu_gauche` VALUES (143, 0, 'Pratique', 'http://news.google.fr/', '3', 'Actualités', 1); INSERT INTO `menu_gauche` VALUES (144, 0, 'Pratique', 'http://www.pagesjaunes.fr/', '4', 'Pages Jaunes', 1); INSERT INTO `menu_gauche` VALUES (145, 1, 'Culturel', 'http://www.allocine.fr/?code_origine=20227A', '2', 'Cinéma', 1); INSERT INTO `menu_gauche` VALUES (147, 1, 'Culturel', 'http://www.programme-tv.net/', '2', 'Programme TV / TNT', 1); INSERT INTO `menu_gauche` VALUES (149, 1, 'Culturel', 'http://startaccueil.mobideal.com/', '3', 'Pour ton mobile', 1); INSERT INTO `menu_gauche` VALUES (150, 1, 'Culturel', 'http://www.parisbouge.com/', '4', 'Paris bouge', 1); INSERT INTO `menu_gauche` VALUES (155, 0, 'Menu', 'http://', '2', 'Lien', 4); INSERT INTO `menu_gauche` VALUES (157, 3, 'Banques', 'https://www.videoposte.com/', '0', 'La poste', 1); INSERT INTO `menu_gauche` VALUES (159, 3, 'Banques', 'http://www.societegenerale.fr/', '2', 'Société générale', 1); INSERT INTO `menu_gauche` VALUES (161, 3, 'Banques', 'https://www.cic.fr/', '3', 'CIC', 1); INSERT INTO `menu_gauche` VALUES (162, 3, 'Banques', 'http://www.banquepopulaire.fr/', '4', 'Banque populaire', 1); INSERT INTO `menu_gauche` VALUES (163, 3, 'Banques', 'http://www.hsbc.fr/', '5', 'HSBC', 1); INSERT INTO `menu_gauche` VALUES (164, 0, 'Pratique', 'http://www.mappy.fr/', '5', 'Mappy', 1); INSERT INTO `menu_gauche` VALUES (165, 0, 'Pratique', 'http://www.cibleclick.com/cibles/clicks/symp.cfm?site_id=398742550&friend_id=1062485766&banniere_id=30618', '6', 'Voyage SNCF', 1); INSERT INTO `menu_gauche` VALUES (184, 0, 'FORUM', 'http://moumounesfromhell.free.fr/phpBB2/index.php', '2', 'Moumounes', 9); INSERT INTO `menu_gauche` VALUES (168, 0, 'Pratique', 'http://news.google.fr/', '3', 'Actualités', 6); INSERT INTO `menu_gauche` VALUES (214, 1, 'BLOG', 'http://skyblog.com', '2', 'Skyblog', 9); INSERT INTO `menu_gauche` VALUES (170, 1, 'Culturel', 'http://www.allocine.fr/?code_origine=20227A', '2', 'Allociné', 6); INSERT INTO `menu_gauche` VALUES (185, 0, 'FORUM', 'http://xenderillimited.free.fr/portal.php', '2', 'Illimited EDK', 9); INSERT INTO `menu_gauche` VALUES (216, 1, 'BLOG', 'http://coubiac82.skyblog.com', '3', 'Clément', 9); INSERT INTO `menu_gauche` VALUES (174, 3, 'Banques', 'https://www.videoposte.com/', '0', 'La poste', 6); INSERT INTO `menu_gauche` VALUES (175, 3, 'Banques', 'https://logitelnet.socgen.com/index.html', '2', 'Société générale', 6); INSERT INTO `menu_gauche` VALUES (190, 4, 'Jeux', '/united/', '0', '-= Ogame =-', 6); INSERT INTO `menu_gauche` VALUES (179, 0, 'Pratique', 'http://www.mappy.fr/', '5', 'Mappy', 6); INSERT INTO `menu_gauche` VALUES (180, 0, 'Pratique', 'http://www.cibleclick.com/cibles/clicks/symp.cfm?site_id=398742550&friend_id=1062485766&banniere_id=30618', '6', 'Voyage SNCF', 6); INSERT INTO `menu_gauche` VALUES (192, 0, 'Internet', 'http://www.hotmail.fr', '2', 'Hotmail', 10); INSERT INTO `menu_gauche` VALUES (193, 0, 'Internet', 'http://www.skyblog.com/', '2', 'SkyBlog', 10);
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 <?php $gauche_query_nombre_menu = "SELECT * FROM `menu_gauche` WHERE `id_user` = '$id_user' GROUP BY 'id_menu' ORDER BY `id_menu` DESC"; $gauche_nombre_menu = mysql_query($gauche_query_nombre_menu, $start_accueil) or die(mysql_error()); $gauche_nombre_total = mysql_num_rows($gauche_nombre_menu); // Retourne le nombre de bloc menu à afficher $gauche_nombre_row = mysql_fetch_assoc($gauche_nombre_menu); //On associe chaque nom de menu dans un tableau for ($gauche_j = $gauche_nombre_total - 1; $gauche_j >= 0; $gauche_j--) { if (!mysql_data_seek($gauche_nombre_menu, $gauche_j)) { echo "Ne peut pointer vers la ligne $gauche_j : " . mysql_error() . "\n"; continue; } if (!($gauche_row_result_menu = mysql_fetch_array($gauche_nombre_menu))) { continue; } $gauche_nom_menu[$gauche_j] = $gauche_row_result_menu['nom_menu']; $gauche_id_menu[$gauche_j] = $gauche_row_result_menu['id_menu']; echo "<table width=\"132\" border=\"0\" cellpadding=\"0\" cellspacing=\"1\" bgcolor=\"#A4BBFF\"> <tr> <td width=\"152\" height=\"23\" background=\"images/degrade23.gif\"><div align=\"center\" class=\"styleMenu\"><strong>".$gauche_nom_menu[$gauche_j]."</strong></div></td> </tr> <tr> <td><table width=\"130\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#FFFFFF\"> <tr> <td width=\"150\"><br> <div align=\"center\">"; $gauche_query_menu = "SELECT * FROM `menu_gauche` WHERE `id_user` = '$id_user' AND `id_menu` = '$gauche_id_menu[$gauche_j]' ORDER BY `position` DESC"; $gauche_menu = mysql_query($gauche_query_menu, $start_accueil) or die(mysql_error()); $gauche_total_liens = mysql_num_rows($gauche_menu); $gauche_row_lien = mysql_fetch_assoc($gauche_menu); for ($gauche_i = $gauche_total_liens - 1; $gauche_i >= 0; $gauche_i--) { if (!mysql_data_seek($gauche_menu, $gauche_i)) { echo "Ne peut pointer vers la ligne $gauche_i : " . mysql_error() . "\n"; continue; } if (!($gauche_row_result_lien = mysql_fetch_array($gauche_menu))) { continue; } $gauche_nom_lien[$gauche_i] = $gauche_row_result_lien['nom_lien']; $gauche_lien[$gauche_i] = $gauche_row_result_lien['lien']; echo "<a href=".$gauche_lien[$gauche_i]." onMouseover=\"window.status='".addslashes($gauche_nom_lien[$gauche_i])."';return true;\" onMouseout=\"window.status='';return true;\" target=\"_self\">".$gauche_nom_lien[$gauche_i]."</a><br>"; } echo "<br></div></td> </tr> </table></td> </tr> </table><br>"; } ?>
Partager