|
| Hjælp mig Kandu.dk ! Fra : molokyle | Vist : 531 gange 11 point Dato : 19-07-04 12:58 |
|
Jeg kan ikke forstå denne kode til en sms sender. Er I ikke lige søde kære Kandu team at hjælpe mig til forstå hvad der står :
Kode <html>
<head>
<title>ThomasLunde.dk</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style>
<!--
a:link {color:#000000; text-decoration:none}
a:visited {color:#000000; text-decoration:none}
a:hover {color:#000000; text-decoration:none}
-->
<!--
body {cursor:default}
-->
</style>
<script language="JavaScript">
function co(element,mode) {
if (mode=="in") {
cursortype = 'hand'
colorval = '#e9e9e9'
} else if (mode=="out") {
cursortype = ''
colorval = '#B7C6D6'
}
element.style.background=colorval;
element.style.cursor=cursortype;
}
</script>
<SCRIPT LANGUAGE="javascript">
<!--
//Script by Mathias Hagensen
//Find more at www.script.dk
function setcookie(name,value) {
today = new Date;
expires = new Date(today.getTime() + 30 * 24 * 60 * 60 * 1000);
document.cookie=name + "=" + escape(value) + "; expires=" + expires
}
function getcookie(name) {
cookielist=document.cookie.split("; ");
for ( count = 0 ; count < cookielist.length ; count++ ) {
if ( cookielist[count].split("=")[0] == name )
return unescape(cookielist[count].split("=")[1])
}
return null;
}
function showvisits() {
visits = getcookie("visits")
if ( visits == null ) visits = 0;
visits++;
document.write(visits);
setcookie("visits",visits);
}
//-->
</SCRIPT>
</head>
<style>
.button {background-color:#FFFFFF;
border-bottom:dotted 1px;
border-color:#000000;
border-left:dotted 1px;
border-color:#000000;
border-right:dotted 1px;
border-color:#000000;
border-top:dotted 1px;
border-color:#000000;
color:#000000;
cursor:hand;
font-family:verdana;
font-size: 8pt;
}
.but {background-color:#FFFFFF;
border-bottom:dotted 1px;
border-color:#000000;
border-left:dotted 1px;
border-color:#000000;
border-right:dotted 1px;
border-color:#000000;
border-top:dotted 1px;
border-color:#000000;
color:#000000;
font-family:verdana;
font-size: 8pt;
}
</style>
<body bgcolor="#FFFFFF" text="#000000" background="gfx/back.jpg">
<table width="740" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td><font size="1" face="Verdana"><b>Forside :: SMS service</b></font></td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" bgcolor="Gray" width="740" align="center" height="50" style="border-top: 1 solid #000000; border-right: 1 solid #000000; border-left: 1 solid #000000; border-bottom: 1 solid #000000">
<tr bgcolor="#FFFFFF">
<td colspan="6" height="41">
<?php include("top.php"); ?>
</td>
</tr>
<tr>
<td bgcolor="#B7C6D6" onmouseover="co(this,'in');" onmouseout="co(this,'out');" width="140" height="5" style="border-right: 1 solid #000000; border-top: 1 solid #000000">
<div align="center"><font face="Verdana" size="2"><a href="index.php" style="width: 100%;">Forsiden</a></font></div>
</td>
<td bgcolor="#B7C6D6" onmouseover="co(this,'in');" onmouseout="co(this,'out');" width="140" height="5" style="border-right: 1 solid #000000; border-top: 1 solid #000000">
<div align="center"><font size="2"><a href="links.php" style="width: 100%;"><font face="Verdana">Links</font></a></font></div>
</td>
<td bgcolor="#B7C6D6" onmouseover="co(this,'in');" onmouseout="co(this,'out');" width="140" height="5" style="border-right: 1 solid #000000; border-top: 1 solid #000000">
<div align="center"><font size="2"><a href="galleries/galleries.php" style="width: 100%;" target="_parent"><font face="Verdana">Gallerier</font></a></font></div>
</td>
<td bgcolor="#B7C6D6" onmouseover="co(this,'in');" onmouseout="co(this,'out');" width="140" height="5" style="border-right: 1 solid #000000; border-top: 1 solid #000000">
<div align="center"><font size="2"><a href="http://www.thomaslunde.dk/download/downloads.php" style="width: 100%;" target="_parent"><font face="Verdana">Download</font></a></font></div>
</td>
<td bgcolor="#B7C6D6" onmouseover="co(this,'in');" onmouseout="co(this,'out');" width="140" height="5" style="border-right: 1 solid #000000; border-top: 1 solid #000000">
<div align="center"><font size="2"><a href="uni.php" style="width: 100%;" target="_parent"><font face="Verdana">Aalborg
Uni</font></a></font></div>
</td>
<td bgcolor="#B7C6D6" onmouseover="co(this,'in');" onmouseout="co(this,'out');" height="5" style="border-top: 1 solid #000000" width="140">
<div align="center"><font size="2"><font size="2"><a href="mobil.php" style="width: 100%;" target="_parent"><font face="Verdana">Mobilos</font></a></font></font></div>
</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" bgcolor="Gray" width="740" align="center" height="15" border="0" style="border-right: 1 solid #000000; border-left: 1 solid #000000; border-bottom: 1 solid #000000">
<tr bgcolor="#FFFFFF">
<td width="141" height="400" bgcolor="#B7C6D6" style="border-right: 1 solid #000000; valign="top" align="left" valign="top">
<div align="center">
<?php include("left.php"); ?>
</div>
</td>
<td width="466" height="400" bgcolor="#FFFFFF" valign="top">
<div align="center"> <br>
<table border="0" width="350" height="235" cellspacing="0" align="center">
<tr>
<td height="226" valign="top">
<form action="<? echo $PHP_SELF; ?>?mode=sms" method="post" name="SMS" id="
">
<br>
<table align="CENTER" width="250">
<tr>
<td width="96"><font face="Verdana, Arial, Helvetica, sans-serif" size="1">Mobil
nummer:</font></td>
<td width="125">
<input type="text" class="but" name="nr" size="10" maxlength="9" value="<? echo $nr ?>">
</td>
</tr>
<tr>
<td width="96"><font face="Verdana, Arial, Helvetica, sans-serif" size="1">Dit
navn:</font></td>
<td width="125">
<input type="text" class="but" name="fra" size="12" maxlength="20" value="<? echo $fra ?>">
</td>
</tr>
<tr>
<td width="96"><font face="Verdana, Arial, Helvetica, sans-serif" size="1">Din
besked:</font></td>
<td width="125">
<textarea cols="20" rows="7" class="but" name="besked" onKeyUp="tilbage()" onChange="check()"><? echo $besked ?></textarea>
</td>
</tr>
<tr>
<?
if($anslag == ""){
$anslag = "120";
}
?>
<td width="96"><font face="Verdana, Arial, Helvetica, sans-serif" size="1">Anslag
tilbage:</font></td>
<td width="125">
<input type="text" class="but" name="anslag" value="<? echo $anslag ?>" size="3" readonly>
</td>
</tr>
<tr>
<td colspan="2" height="33">
<div align="center"><font face="Verdana" size="1" color="#FFFFFF">-<br>
</font>
<input type="Submit" class="but" value=" Send SMS " name="Submit">
<font color="#FFFFFF">_</font>
<input type="Reset" class="but" value=" Slet " name="Reset">
</div>
</td>
</tr>
</table>
</form>
<div align="center">
<script language="JavaScript">
<!--
function tilbage() {
document.SMS.charleft.value = <? echo $lang; ?> - document.SMS.message.value.length;
}
//-->
</script>
<? if($mode == "sms"){
$nr = (($nr+1)-1);
$lang = strlen($besked);
if ($lang > 120) {
$fejl = "Beskeden er for lang";
$mode = "";
}
elseif($nr == 0) {
$fejl = "Afsender mangler";
$mode = "";
}
elseif ($fra == "") {
$fejl = "Dit navn mangler";
$mode = "";
}
elseif($besked == "") {
$fejl = "Der mangler en besked";
$mode = "";
}
else {
if ((20100000<=$nr) and ($nr<=20169999)) { $end = "sms.tdm.dk"; }
elseif ((20190000<=$nr) and ($nr<=20339999)) { $end = "sms.tdm.dk"; }
elseif ((20400000<=$nr) and ($nr<=20409999)) { $end = "sms.tdm.dk"; }
elseif ((20600000<=$nr) and ($nr<=20999999)) { $end = "note.sonofon.dk"; }
elseif ((21200000<=$nr) and ($nr<=21299999)) { $end = "sms.tdm.dk"; }
elseif ((21400000<=$nr) and ($nr<=21499999)) { $end = "sms.tdm.dk"; }
elseif ((21600000<=$nr) and ($nr<=21999999)) { $end = "sms.tdm.dk"; }
elseif ((22100000<=$nr) and ($nr<=22999999)) { $end = "note.sonofon.dk"; }
elseif ((23200000<=$nr) and ($nr<=23999999)) { $end = "sms.tdm.dk"; }
elseif ((24100000<=$nr) and ($nr<=24999999)) { $end = "sms.tdm.dk"; }
elseif ((25100000<=$nr) and ($nr<=25399999)) { $end = "note.sonofon.dk"; }
elseif ((25500000<=$nr) and ($nr<=25599999)) {
$fejl = "Det er en Tele1 Europa nummer. Og vi kender ikke emailen";
$mode = "";
}
elseif ((25700000<=$nr) and ($nr<=25799999)) { $end = "sms.tele2.dk"; }
elseif ((25910000<=$nr) and ($nr<=25929999)) { $end = "sms.tdm.dk"; } //tele passat
elseif ((26100000<=$nr) and ($nr<=26999999)) { $end = "sms.mobilix.dk"; }
elseif ((27100000<=$nr) and ($nr<=27399999)) { $end = "sms.mobilix.dk"; }
elseif ((28100000<=$nr) and ($nr<=28899999)) { $end = "sm1800.telia.dk"; }
elseif ((29100000<=$nr) and ($nr<=29999999)) { $end = "sms.tdm.dk"; }
elseif ((40100000<=$nr) and ($nr<=40119999)) { $end = "sms.tdm.dk"; }
elseif ((40130000<=$nr) and ($nr<=40219999)) { $end = "sms.tdm.dk"; }
elseif ((40250000<=$nr) and ($nr<=40469999)) { $end = "sms.tdm.dk"; }
elseif ((40500000<=$nr) and ($nr<=40999999)) { $end = "note.sonofon.dk"; }
elseif ((51100000<=$nr) and ($nr<=51399999)) { $end = "sms.tdm.dk"; }
elseif ((51600000<=$nr) and ($nr<=51999999)) { $end = "sms.tdm.dk"; }
elseif ((52200000<=$nr) and ($nr<=52299999)) {
$fejl = "Det er en Sense Communications nummer. Og vi kender ikke emailen";
$mode = "";
}
else {
$fejl = "Ukendt mobil type";
$mode = "";
}
if (!$end=="") {
$smsemail = $nr."@".$end;
mail("$smsemail", "", "Fra: $fra - $besked", "From: $afsender");
$fejl = "Sms beskeden er sendt afsted";
$mode = "";
}
}
} ?>
<? if($mode == ""){?>
<script language="JavaScript">
<!--
function tilbage() {
document.SMS.anslag.value = 120 - document.SMS.besked.value.length;
}
//-->
</script>
<font color="Red" FONT face="Verdana, Arial, Helvetica, sans-serif" size="1">
<? echo $fejl; ?>
<? } ?>
</font> </div>
</td>
</tr>
</table>
</div>
</td>
<td width="141" height="400" bgcolor="#B7C6D6" style="border-left: 1 solid #000000; valign="top" align="left" valign="top">
<div align="center"></div>
<div align="center"><font face="Verdana" size="1">
<?php include("right.php"); ?>
<br>
<br>
<br>
<br>
<br>
</font> <font face="Verdana" size="1"> </font></div>
</td>
</tr>
<tr bgcolor="#FFFFFF" valign="middle" align="center">
<td colspan="3" height="20" style="border-top: 1 solid #000000">
<div align="center">
<?php include("bottom.php"); ?>
</div>
</td>
</tr>
</table>
<div align="center"><br>
<table width="300" border="0" cellspacing="0" cellpadding="0" height="13">
<tr>
<td>
<div align="center"><font face="Verdana" size="1">:: CopyRight Thomas
Lunde 1998 - 2001 ::</font></div>
</td>
</tr>
<tr>
<td>
<div align="center"><font face="Verdana" size="1">Optimeret for Internet
Explorer 5.x<br>
1024 x 768</font></div>
</td>
</tr>
</table>
<p><font face="verdana" size="1"> </font></p>
</div>
</body>
</html> |
</MOLOKYLE>
| |
| Kommentar Fra : Toupie |
Dato : 19-07-04 18:10 |
| | |
| Kommentar Fra : molokyle |
Dato : 19-07-04 20:13 |
|
Toupie -> Ja, er det ik' flot
Det skulle have været PHP kode til en sms sender man kunne lægge på sin hjemmeside, men Kandu.dk synes åbenbart bedre om moderne kunst.
Derfor har de i dagens anledning skabt lidt ekstra kulør og bedde i indlæget
</MOLOKYLE>
| |
| Kommentar Fra : molokyle |
Dato : 19-07-04 20:30 |
|
Toupie -> Dette burde ikke komme som nogen overraskelse
Det er altså ret irriterende, som jeg utallige gange har gjort Kandu.dk opmærksom på, at man fratages muligheden for at komme med kvalificeret hjælp til div. programmerings kode problemer.
Man må til stadighed komme med forbehold og rettelser til den indsendte kode, der var ment som en hjælp til andre brugere. I stedet bliver det til den rene gættekonkurrence.
Ikke særligt befordrende for forståelsen af de i forvejen komplicerede programmerings paradigmer, skulle jeg hilse at sige.
</MOLOKYLE>
| |
| Kommentar Fra : nicolehh |
Dato : 22-07-04 13:34 |
|
Citat Hjælp skal ha en ny mus med sideværts scroll!! |
lol lol lol lol
den var sq god... *GGGGGGGGGGGGGGGGGG*
| |
| Du har følgende muligheder | |
|
Eftersom du ikke er logget ind i systemet, kan du ikke skrive et indlæg til dette spørgsmål.
Hvis du ikke allerede er registreret, kan du gratis blive medlem, ved at trykke på "Bliv medlem" ude i menuen.
| |
|
|