Berichten: 120
avatar
Offline Stuur privebericht
Beste CP'ers.

Ik zit met het grootste probleem totheden die ik heb.
Ik probeer al aantal dagen de probleem uit me index te krijgen.
Het is zo, de tables worden niet steeds volledig weergegeven. Als bijvoorbeeld de menu uitklapt, worden de tables van index groter maar niet volledig weergegeven.

Ik weet niet of ik het duidelijk genoeg heb vertelt.
Ik weet dat de scripting bagger is, maar dat wil ik hierna proberen te repareren


Code | Selecteer Alles
minimaliseren
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
<body style="margin: 5px;">
<table align="center" width=100%>
 <tr>

 <? include('banner.php'); ?>

    <tr><td valign="top">
      <table width=100% cellpadding=0 cellspacing=0>
        <td valign="top">
    <table width=100% height=100% cellpadding=0 cellspacing=0>
        <tr><td width=150 height=150 valign="top" align="center">
<?php /* ------------------------- */

  
$dbres                mysql_query("SELECT `id` FROM `[users]` WHERE `activated`=1");
  
$members                mysql_num_rows($dbres);

  
$dbres                mysql_query("SELECT `id` FROM `[users]` WHERE UNIX_TIMESTAMP(NOW())-UNIX_TIMESTAMP(`online`) < 300");
  
$online                mysql_num_rows($dbres);

  
$dbres                mysql_query("SELECT `id` FROM `[users]` WHERE `level` & 0x80 AND UNIX_TIMESTAMP(NOW())-UNIX_TIMESTAMP(`online`) < 300 ORDER BY `login`");
  
$admin                mysql_num_rows($dbres);

  
$query                mysql_query("SELECT id FROM `[messages]` WHERE `read`=0 AND `inbox`=1 AND `to`='{$data->login}'");
  
$inboxnew                mysql_num_rows($query);

  
$laatstelid           mysql_query("select `login` from `[users]` order by id desc limit 1");
  
$lastmember           = @mysql_result($laatstelid,0,0);
  print <<<ENDHTML
      <table width=150><form>
        <tr><td class="mainTxt" align="center"><b>Active: 
$online/$members</b></td></tr>
    <tr><td align="center"><input type="text" name="time" style="text-align: center;"></td></tr>
      </form></table>
ENDHTML;

  if(
$data) {
    print <<<ENDHTML
      <table class="menu" width=150 cellpadding=0 cellspacing=0>
        <tr><td><table width=100% cellpadding=0 cellspacing=0>
        <tr> <td width=5 class="menuTitle"><a style="color: #FFFFFF;" onClick="showMenu('main')"><IMG src="images/star22.jpg" vspace="2" hspace="2" border="0" align="absmiddle"></a>&nbsp;</td>
            <td class="menuTitle"><b>General</b></td></tr>
    </table>
        <table width=100% cellpadding=0 cellspacing=0 ID="main" style="position: absolute; left: -100; top: -100;">
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='home.php';">&nbsp;&nbsp;<a title="Go to Forum page" href="home.php"><font size="1.5" color="#CCCCCC"><b>Home</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='disclaimer.php';">&nbsp;&nbsp;<a title="Go to Disclaimers" href="disclaimer.php"><font size="1.5" color="#CCCCCC"><b>FAQ</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href=login.php?x=logout';">&nbsp;&nbsp;<a title="Logout directly" href="login.php?x=logout"><font size="1.5" color="#CCCCCC"><b>Logout</b></font></a></td></tr>
        </table></td></tr>
      </table>

      <table class="menu" width=150 cellpadding=0 cellspacing=0>
        <tr><td><table width=100% cellpadding=0 cellspacing=0>
        <tr> <td width=5 class="menuTitle"><a style="color: #FFFFFF;" onClick="showMenu('control')"><IMG src="images/star22.jpg" vspace="2" hspace="2" border="0" align="absmiddle"></a>&nbsp;</td>
            <td class="menuTitle"><b>User</b></td></tr>
    </table>
    <table width=100% cellpadding=0 cellspacing=0 ID="control" style="position: absolute; left: -100; top: -100; visibility: hidden;">
    <tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='list.php';">&nbsp;&nbsp;<a title="View the members" href="list.php"><font size="1.5" color="#CCCCCC"><b>Members</b></font></a></td></tr>
    <tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='list.php?s=online';">&nbsp;&nbsp;<a title="See all active users" href="list.php?s=online"><font size="1.5" color="#CCCCCC"><b>Online[
$online]</b></font></a></td></tr>
    <tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='message.php?p=inbox';">&nbsp;&nbsp;<a title="Go to your inbox" href="message.php?p=inbox"><font size="1.5" color="#CCCCCC"><b>Inbox[
$inboxnew]</b></font></a></td></tr>
    <tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='forum.php';">&nbsp;&nbsp;<a title="Go to the forum" href="forum.php"><font size="1.5" color="#CCCCCC"><b>Forum</b></font></a></td></tr>
    </table></td></tr>
      </table>

<table class="menu" width=150 cellpadding=0 cellspacing=0>
        <tr><td><table width="100%" cellpadding=0 cellspacing=0>
        <tr> <td width=5 class="menuTitle"><a style="color: #FFFFFF;" onClick="showMenu('fam')"><IMG src="images/star22.jpg" vspace="2" hspace="2" border="0" align="absmiddle"></a>&nbsp;</td>
            <td class="menuTitle"><b>Family</b></td></tr>
    </table>
    <table width="100%" cellpadding=0 cellspacing=0 ID="fam" style="position: absolute; left: -100; top: -100; visibility: hidden;">
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href=';">&nbsp;&nbsp;<a title="There are no options available yet"><font size="1.5" color="#CCCCCC"><b>No options</b></font></a></td></tr>
    </table></td></tr>
      </table>

ENDHTML;

    if(
$data->level == 4) {
      print <<<ENDHTML

      <table class="menu" width=150 cellpadding=0 cellspacing=0>
        <tr><td><table width=100% cellpadding=0 cellspacing=0>
        <tr><td width=5 class="menuTitle"><a style="color: #FFFFFF;" onClick="showMenu('admin')"><IMG src="images/star22.jpg" vspace="2" hspace="2" border="0" align="absmiddle"></a>&nbsp;</td>
            <td class="menuTitle"><b>Admin</b></td></tr>
    </table>
    <table width=100% cellpadding=0 cellspacing=0 ID="admin" style="position: absolute; left: -100; top: -100; visibility: hidden;">
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='link/admin.php';">&nbsp;&nbsp;<a title="Go to edit of linkers" href="link/admin.php"><font size="1.5" color="#CCCCCC"><b>Linkpartners</b></font></a></td></tr>
         </table></td></tr>
      </table>
ENDHTML;
    }
    else
      print 
"    </td>n";
  }
  else {
    print <<<ENDHTML
      <table class="menu" width=150 cellpadding=0 cellspacing=0>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='home.php';">&nbsp;&nbsp;<a title="Go to Homepage" href="home.php"><font size="1.5" color="#CCCCCC"><b>Home</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='bulletlist.php';">&nbsp;&nbsp;<a title="Go to Bulletchart v3.0" href="bulletlist.php"><font size="1.5" color="#FF0000"><b>Bulletchart</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='bodyguards.php';">&nbsp;&nbsp;<a title="Go to Bodyguard training" href="bodyguards.php"><font size="1.5" color="#FF0000"><b>Bodyguards</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='link/index.php';">&nbsp;&nbsp;<a title="Go to our linkpartners" href="link/index.php"><font size="1.5" color="#CCCCCC"><b>Linkpartners</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='home.php';">&nbsp;&nbsp;<a title="Go to our mIRC Bots" href="home.php"><font size="1.5" color="#CCCCCC"><b>mIRC Bots</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='news.php';">&nbsp;&nbsp;<a title="Go to latest news" href="news.php"><font size="1.5" color="#CCCCCC"><b>News</b></font></a></td></tr>
<tr bgcolor="#364E5A" height="20"><td onmouseover="this.style.background='#42606F';this.style.cursor='hand';" onmouseout="this.style.background='#364E5A';" style="border-right:1px solid #FFFFFF;border-bottom:1px solid #4E6F81;" onclick="top.frames['hoofd'].location.href='home.php';">&nbsp;&nbsp;<a title="Go to Forum page" href="home.php"><font size="1.5" color="#CCCCCC"><b>Forum</b></font></a></td></tr>

      </table>

    
        
      <table class="menu" width=150 cellpadding=0 cellspacing=0>
        <tr>
            <tr><td class="menuTitle" align="center"><b>Not able to login!</b></td></tr>
        <tr><td class="menuLink">    
        <form method="post" action="login.php" method="post"><table align="center" width="100%">
      <tr><td align=center>Login:</td></tr><tr>        <td align=center><input type="text" name="login" maxlength=16 style="text-align: center;"></td></tr>
      <tr><td align=center>Password:</td></tr><tr>    <td align=center><input type="password" name="pass" maxlength=16 style="text-align: center;"></td></tr>
            <tr><td colspan=2><input type="submit" value="Login" style="width: 100px; height: 20px;"></td></tr>

            </table>
            
                        </form>
            </td>
        </tr>
    </table>       
ENDHTML;
  }

/* ------------------------- */ ?>
     <td width=15></td>



      <td valign="top"><table width=100% height=100% cellspacing=0 cellpadding=0>
        <tr><td height=5><br></td></tr>
        <tr><td><iframe src="<?php echo ($data) ? "news.php" "home.php" ?>" name="mainFrame" width=100% height=100% frameborder=0></iframe></td></tr>
      </table></td></tr>
      </table></td></tr>
  </table></td></tr>
</table><center>
</table>
</body>

20-05-2010 18:35
Dit topic is 78 keer bekeken door 22 verschillende leden
Reacties op: "Index"
1
Berichten: 120
avatar
Offline Stuur privébericht
Zijn er nog mensen die het weten?
21-05-2010 17:09
Berichten: 552
avatar
Offline Stuur privébericht
Jij laat je achter grond zien met een afbeelding, maak die afbeelding wat groter?
21-05-2010 17:16
Berichten: 120
avatar
Offline Stuur privébericht
Welke afbeelding bedoelje nu precies?
Enige image die hier gebruikt wordt is in het menu, maar heeft hier niets mee te maken...
Het gaat om de middelste veld.
21-05-2010 17:19
Berichten: 8
avatar
Offline Stuur privébericht
ENDHTML is uit 't jaar 0..
Gebruik nieuwere methode's om je content weer te geven.
Zoals: echo, print, etc.
21-05-2010 17:34
Rapifia Europe
Berichten: 3719
avatar
Offline Stuur privébericht
@riko14,

Weer NIET gelezen:
Quote

Ik weet dat de scripting bagger is, maar dat wil ik hierna proberen te repareren



ON: Haal de <tr> boven de banner include weg, en daaronder ook dit:
<tr><td valign="top">
Je kan volgens mij alleen een tabel in een tabel gebruiken als je <tr> en <td> niet hebt geopend.

De sluit tags: </tr> / </td> moet je ook even weghalen.

Lars
21-05-2010 17:46
Berichten: 120
avatar
Offline Stuur privébericht
Bedankt voor de quote lars, mensen lezen maar de helft

Ik heb nu degelijk het probleem opgelost.
Ik heb op regel 3, 7 t/m 9 verwijderd. Aangezien zoals je al zei, niet gesloten worden. Oa ook de <table>-tag

Maar hoe zit dat met de ENDHTML's?
Ik kan ze niet vervangen door de <?PHP & ?> tags, dan krijg je alleen maar errors...
Print heb ik vervangen door echo
22-05-2010 00:09
Berichten: 2103
avatar
Offline Stuur privébericht
@Tycho
Je kan via de functie echo of via de print html weergeven.
Ik raad je alleen aan om html zoveel mogelijk buiten PHP te houden.

Voorbeelden:
Code | Selecteer Alles
minimaliseren
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<table width="100%">
    <tr>
        <td>Voorbeeld 1:</td>
        <td><?php echo $iets?></td>
    </tr>
    <tr>
        <td>Voorbeeld 2:</td>
        <td><?php print $iets?></td>
       </tr>
    <tr>
        <td>Voorbeeld 3:</td>
        <td><?=$iets?></td>
    </tr>
</table>
22-05-2010 00:28
Berichten: 120
avatar
Offline Stuur privébericht
@superior
Ik kan
Code | Selecteer Alles
minimaliseren
1
2
3
4
5
6
print <<<ENDHTML
      <table width=150><form>
        <tr><td class="mainTxt" align="center"><b>Active: 
$online/$members</b></td></tr>
    <tr><td align="center"><input type="text" name="time" style="text-align: center;"></td></tr>
      </form></table>
ENDHTML;


Niet veranderen naar bijv.
Code | Selecteer Alles
minimaliseren
1
2
3
4
5
6
7
<table width=100%>
    <tr>
        <td>Active:</td>
        <td><?php echo $online/$members?></td>
        <td align="center"><input type="text" name="time" style="text-align: center;"></td>
    </tr>
     </table>


Het eerste wat ik dan zal krijgen is
Parse error: syntax error, unexpected '<'

Ik heb daar veel last van.
Via PHP.net is het makkelijk uitgelegt, dat snap ik.
Maar om het zo nu even goed te zetten, wordt het me nu even iets lastiger.
Ik heb daar soms vaker vast van om van ENDHTML naar <?php tag vorm
22-05-2010 01:12
Berichten: 2103
avatar
Offline Stuur privébericht
Klopt je moet er rekening mee houden dat je PHP gebruikt.

Wordt dus zo:
Code | Selecteer Alles
minimaliseren
1
2
3
4
5
6
7
<table width=100%>
    <tr>
        <td>Active:</td>
        <td><?php echo $online.'/'.$members?></td>
        <td align="center"><input type="text" name="time" style="text-align: center;"></td>
    </tr>
     </table>
22-05-2010 01:43
Reageer op: "Index"
1
Je kan niet reageren omdat je niet bent ingelogd. Inloggen of Aanmelden