Site vervormt
</div>
gebruikt. Alles blijft ook binnen de afgesproken pixels, maar toch verandert hij nog steeds.
zie: http://wzzshop.downfire.com/poll/test/index.php
Als je op henk zoekt verandert hij en als je op contact zoekt niet. hoe kan dat?
Dit is het script van mijn pagina:
<html>
<head>
<title>henk</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link rel="stylesheet" href="style.css" type="text/css" />
<meta name="generator" content="Namo WebEditor v6.0(Trial)">
</head> <div style="width:450px; word-wrap: break-word;">
<body bgcolor="#FFFFFF" text="black" link="#000000" vlink="#000000" alink="#000000">
<div align="center">
<p align="center"> </p>
</div>
<table width="794" border="0" cellspacing="0" cellpadding="3" align="center">
<tr>
<td width="177" valign="top">
<table width="69" border="0" cellspacing="0" cellpadding="0" height="289">
<tr>
<td background="top.jpg" height="29" colspan="3" class="headline"> Navigation</td>
</tr>
<tr>
<td width="11" height="246" background="left.jpg"> </td>
<td width="148" height="246" valign="top">
<table width="130" border="0" cellspacing="0" cellpadding="3">
<tr>
<td class="standard" valign="middle" width="21">
<p align="center"><img src="square.jpg" width="14" height="15" /></p>
</td>
<td valign="middle" width="97" height="25"><a href="../page6.htm" class="navi">Page 6</a>
</td>
</tr>
<tr>
<td class="standard" valign="middle" width="21">
<div align="center"><img src="square.jpg" width="14" height="15" /></div>
</td>
<td valign="middle" width="97" height="25" class="navi_active"><a href="../page6.htm" class="navi">Page 6</a>
</td>
</tr>
<tr>
<td class="standard" valign="middle" width="21">
<div align="center"><img src="square.jpg" width="14" height="15" /></div>
</td>
<td valign="middle" width="97" height="25"><a href="../page6.htm" class="navi">Page 6</a>
</td>
</tr>
<tr>
<td class="standard" valign="middle" width="21">
<div align="center"><img src="square.jpg" width="14" height="15" /></div>
</td>
<td valign="middle" width="97" height="25"><a href="../page6.htm" class="navi">Page 6</a>
</td>
</tr>
<tr>
<td class="standard" valign="middle" width="21">
<div align="center"><img src="square.jpg" width="14" height="15" /></div>
</td>
<td valign="middle" width="97" height="25"><a href="../page6.htm" class="navi">Page 6</a>
</td>
</tr>
<tr>
<td class="standard" valign="middle" width="21">
<div align="center"><img src="square.jpg" width="14" height="15" /></div>
</td>
<td valign="middle" width="97" height="25"><a href="../page6.htm" class="navi">Page 6</a>
</td>
</tr>
<tr>
<td class="standard" valign="middle" width="21">
<div align="center"><img src="square.jpg" width="14" height="15" /></div>
</td>
<td valign="middle" width="97" height="25"><a href="../page6.htm" class="navi">Page 6</a>
</td>
</tr>
<tr>
<td class="standard" valign="middle" width="21" height="17">
<div align="center"><img src="square.jpg" width="14" height="15" /></div>
</td>
<td valign="middle" width="97" height="25"><a href="../page7.htm" class="navi">Page 7</a>
</td>
</tr>
</table>
</td>
<td width="10" height="246" background="right.jpg"> </td>
</tr>
<tr>
<td colspan="3"><img src="bottom.jpg" width="169" height="24" /></td>
</tr>
</table>
<br />
<table width="69" border="0" cellspacing="0" cellpadding="0" height="219">
<tr>
<td background="top.jpg" height="29" colspan="3" class="headline"> Friends</td>
</tr>
<tr>
<td width="11" height="172" background="left.jpg"> </td>
<td width="148" height="172" valign="top">
<table width="139" border="0" cellspacing="0" cellpadding="3" align="center">
<tr>
<td class="standard" height="217" valign="top">
<p align="center">test <p align="center"><br><br><br><br><br><br><br><br>your site here?</p>
</td> </tr>
</table>
</td>
<td width="10" height="172" background="right.jpg"> </td>
</tr>
<tr>
<td colspan="3"><img src="bottom.jpg" width="169" height="24" /></td>
</tr>
</table>
</td> <div style="width:450px; word-wrap: break-word;">
<td width="418" height="2" nowrap="nowrap"/>
<div style="width:450px; word-wrap: break-word;">
<p align="center"><br></p>
<p align="center"> </p>
<p align="center">
<form method="post" action="index.php">
<p align="center"><b>Searcher: </b><input type="text" name="query" style="color:rgb(90,111,204); background-color:white;"><input type="submit" value="Search!"><br> <b> </b><font size="1" color="#5A6FCC"><b>last
updated:03 June </b></font>
</form>
<p align="center"><img src="streep.jpg" width="400" height="3" border="0"></p>
<p align="center"><u>
Code (php)
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
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
<?
if(isset($_POST['query'])){
$file = "upload/fake.txt"; // <== nog steeds opgeven in welk bestand je wilt zoeken!!
$file2 = "nieuw.txt"; // nieuwe bestand
$query = $_POST['query'];
$data = file($file);
$data2 = file($file2);
foreach($data2 as $dat) {
$newi = count($data);
$data[$newi] = $dat;
}
$lijnen = Array();
if(strlen($query) < 4){
echo 'Plz search for a larger word' ;
} else {
$aIgnore=array('.','*','_','-','=');
$aEmpty=array_fill(0,count($aIgnore),' ');
foreach($data as $id => $line){
if(((stristr($line, $query)) OR (stristr(str_replace($aIgnore,$aEmpty,$line),$query))) AND (($id-4)%7==0))
{
$lijnen[] = $id;
}
}
echo count ($lijnen)."result(s)</u><b><br>If you want more results, register above!</b>"; echo '<p align="center"><img src="streep.jpg" width="400" height="3" border="0"></p>';
foreach($lijnen as $lijn){
if($lijn > 0){
echo '<p align="center"><A HREF="'.$data[$lijn - 2] .'">'.$data[$lijn - 2].'</A><br><br>';
}
$query=str_replace(' ','['.implode('|',$aIgnore).']',$query);
$result=preg_replace("/(".$query.")/i","<B>\$1</B>",$data[$lijn]).'<br>';
echo '<p align="left">'. str_replace($aIgnore,$aEmpty,$result);
if($lijn != count($data)){
echo $data[$lijn+1];
}
echo '<p align="center"><img src="streep.jpg" width="400" height="3" border="0"></p>';
}
}
} else {
echo ''; ?>
if(isset($_POST['query'])){
$file = "upload/fake.txt"; // <== nog steeds opgeven in welk bestand je wilt zoeken!!
$file2 = "nieuw.txt"; // nieuwe bestand
$query = $_POST['query'];
$data = file($file);
$data2 = file($file2);
foreach($data2 as $dat) {
$newi = count($data);
$data[$newi] = $dat;
}
$lijnen = Array();
if(strlen($query) < 4){
echo 'Plz search for a larger word' ;
} else {
$aIgnore=array('.','*','_','-','=');
$aEmpty=array_fill(0,count($aIgnore),' ');
foreach($data as $id => $line){
if(((stristr($line, $query)) OR (stristr(str_replace($aIgnore,$aEmpty,$line),$query))) AND (($id-4)%7==0))
{
$lijnen[] = $id;
}
}
echo count ($lijnen)."result(s)</u><b><br>If you want more results, register above!</b>"; echo '<p align="center"><img src="streep.jpg" width="400" height="3" border="0"></p>';
foreach($lijnen as $lijn){
if($lijn > 0){
echo '<p align="center"><A HREF="'.$data[$lijn - 2] .'">'.$data[$lijn - 2].'</A><br><br>';
}
$query=str_replace(' ','['.implode('|',$aIgnore).']',$query);
$result=preg_replace("/(".$query.")/i","<B>\$1</B>",$data[$lijn]).'<br>';
echo '<p align="left">'. str_replace($aIgnore,$aEmpty,$result);
if($lijn != count($data)){
echo $data[$lijn+1];
}
echo '<p align="center"><img src="streep.jpg" width="400" height="3" border="0"></p>';
}
}
} else {
echo ''; ?>
</p>
<p align="center"><u> </u></p>
<p align="center"><u></u></p>
<p align="center"><u> </u></p>
<p align="center"><u></u>
</p>
<p align="center"> </p>
<p align="center"> </p>
</div>
<td width="181" valign="top" align="right">
<table width="171" border="0" cellspacing="0" cellpadding="0" height="282">
<tr>
<td background="top.jpg" height="29" colspan="3" class="headline" width="171"> Poll</td>
</tr>
<tr>
<td width="7" height="242" background="left.jpg"> </td>
<td width="152" height="242" valign="top">
<table width="145" border="0" cellspacing="0" cellpadding="4" height="196" align="center">
<tr>
<td colspan="2" class="headline" width="137" height="238">
<p align="left">
</p>
</td>
</tr>
</div>
</table>
</td>
<td width="12" height="242" background="right.jpg"> </td>
</tr>
<tr>
<td colspan="3" width="171"><img src="bottom.jpg" width="169" height="24" /></td>
</tr>
</table>
<br>
<table width="69" border="0" cellspacing="0" cellpadding="0" height="219">
<tr>
<td background="top.jpg" height="29" colspan="3" class="headline"> News</td>
</tr>
<tr>
<td width="11" height="172" background="left.jpg"> </td>
<td width="148" height="172" valign="top">
<table width="139" border="0" cellspacing="0" cellpadding="3" align="center">
<tr>
<td class="standard" height="217" valign="top">
<p><b>27-06-04<br></b>Site launched</p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
</td>
</tr>
</table>
</td>
<td width="10" height="172" background="right.jpg"> </td>
</tr>
<tr>
<td colspan="3"><img src="bottom.jpg" width="169" height="24" /></td>
</tr>
</table>
<p><br />
</p>
</td>
</tr>
</table>
</body>
</html>
je hoeft niet te debuggen, ik zoek alleen een verklaring. Ik kan snap het namelijk niet!
Neej ik zie niet eens wat je bedoelt ...
zie wat ik erneer zet....de hele regterkant beweegt naar regts als je op henk zoekt en als je op contact zoekt niet
ziet er maar een onverzichtig script je uit hoor soms open en sluit je php tags zonder iets tussen :S
iemand met concrete oplossingen? het is tog gek dat hij het wel compact maakt maar toch mijn layout verspringt?
Ik zou de zoekresultaten opvangen, de lengte tellen en vervolgens de eerste n tekens weergeven, terwijl de link gewoon als href het volledige zoekresultaat heeft...
Edit:
http://spacefrog.ath.cx/extra/phphulp/henk.gif
Elwin
Gewijzigd op 28/06/2004 19:26:00 door Elwin - Fratsloos
Anyways... jij zei het ook al.. ;)
Elwin
http://members.lycos.nl/wzshop/henk.JPG
maar goed wat je zegt 'Elwin [a.k.a. SpaceFrog]' kan je me daarmee helpen? heb je daar een script voor ofzo? ik ben namelijk nie zo gevordert