Форум о заработке в интернете - Показать сообщение отдельно - Java скрипты
Показать сообщение отдельно
Старый 01.07.2009, 23:19   #12
mihmiha
Заблокирован
 
Регистрация: 24.06.2009
Сообщений: 96
0 | 0
1 | 0
По умолчанию

Астрологический калькулятор

<meta http-equiv = "content-type" content = "text/html; charset = Windows-1251">
<SCRIPT LANGUAGE="JavaScript">
function signs() {
var start = 1901, birthyear = document.zodiac.year.value, date=document.zodiac.date.value, month=document.zodiac.month.selectedIndex;

with (document.zodiac.sign){

if (month == 1 && date >=20 || month == 2 && date <=18) {value = "Водолей";}
if (month == 1 && date > 31) {value = "Ошибка!";}
if (month == 2 && date >=19 || month == 3 && date <=20) {value = "Рыбы";}
if (month == 2 && date > 29) {value = "Ошибка!";}
if (month == 3 && date >=21 || month == 4 && date <=19) {value = "Овен";}
if (month == 3 && date > 31) {value = "Ошибка!";}
if (month == 4 && date >=20 || month == 5 && date <=20) {value = "Телец";}
if (month == 4 && date > 30) {value = "Ошибка!";}
if (month == 5 && date >=21 || month == 6 && date <=21) {value = "Близнецы";}
if (month == 5 && date > 31) {value = "Ошибка!";}
if (month == 6 && date >=22 || month == 7 && date <=22) {value = "Рак";}
if (month == 6 && date > 30) {value = "Ошибка!";}
if (month == 7 && date >=23 || month == 8 && date <=22) {value = "Лев";}
if (month == 7 && date > 31) {value = "Ошибка!";}
if (month == 8 && date >=23 || month == 9 && date <=22) {value = "Дева";}
if (month == 8 && date > 31) {value = "Ошибка!";}
if (month == 9 && date >=23 || month == 10 && date <=22) {value = "Весы";}
if (month == 9 && date > 30) {value = "Ошибка!";}
if (month == 10 && date >=23 || month == 11 && date <=21) {value = "Скорпион";}
if (month == 10 && date > 31) {value = "Ошибка!";}
if (month == 11 && date >=22 || month == 12 && date <=21) {value = "Стрелец";}
if (month == 11 && date > 30) {value = "Ошибка!";}
if (month == 12 && date >=22 || month == 1 && date <=19) {value = "Козерог";}
if (month == 12 && date > 31) {value = "Ошибка!";}
}
x = (start - birthyear) % 12
with (document.zodiac.csign){
if (x == 1 || x == -11) {value = "Крыса";}
if (x == 0) {value = "Бык";}
if (x == 11 || x == -1) {value = "Тигр";}
if (x == 10 || x == -2) {value = "Кролик";}
if (x == 9 || x == -3) {value = "Дракон";}
if (x == 8 || x == -4) {value ="Змея";}
if (x == 7 || x == -5) {value = "Лошадь";}
if (x == 6 || x == -6) {value = "Овца";}
if (x == 5 || x == -7) {value = "Обезьяна";}
if (x == 4 || x == -8) {value = "Петух";}
if (x == 3 || x == -9) {value = "Собака";}
if (x == 2 || x == -10) {value = "Кабан";}
}}
</script>

<form name="zodiac">
<center>
<table bgcolor="#60d4ff" border="2" bordercolor="#000000" rules="none" cellspacing="0" cellpadding="4">
<tr><td><b><i>Year</i></b></td>
<td><div align="right"><input type="text" size="10" name="year" value="Год" onClick=value=""></div></td>
<td> </td>
<tr><td><b><i>Месяц</i></b></td>
<td><div align="right">
<select name="month">
<option value="x">Месяц</option>
<option value="1">Январь</option>
<option value="2">Февраль</option>
<option value="3">Март</option>
<option value="4">Апрель</option>
<option value="5">Май</option>
<option value="6">Июнь</option>
<option value="7">Июль</option>
<option value="8">Август</option>
<option value="9">Сентябрь</option>
<option value="10">Октябрь</option>
<option value="11">Ноябрь</option>
<option value="12">Декабрь</option>
</select></div></td>
<td> </td></tr>
<tr><td><b><i>День</i></b></td>
<td><div align="right"><input type="text" name="date" value="День" size="3" onClick=value=""></td>
<td><input type="button" value="Расчет" onClick="signs()"></div></td></tr>
<tr><td><b><i>Знак Зодиака:</i></b></td>
<td><div align="right"><input type="text" name="sign" size="12" value="" align="right"></div</td></tr>
<td> </td></tr>
<tr><td><b><i>Восточный календарь:</i></b></td>
<td><div align="right"><input type="text" name="csign" size="12"></div></td>
<td> </td></tr>
</table>
</center>
</form>

__________________________________________________ ______________________________
скачан с http://zarvinter.site90.com/script.html

Добавлено через 1 минуту
<html>

<head><script LANGUAGE="JavaScript">
/*
This source code is released to the public domain with the provision that
the copyright information remains in the source code.
Copyright (c) by: Robert N Bovara All Rights Reserved.
*/
var outMsg = "";
var i = 0;
var lineNo = 1;
var timerDM=null;
var msg = " ";
function araVob() {
}
var ScreenLine = new araVob();
ScreenLine[1] = "Doesn't this look better than status bar displays?"
ScreenLine[2] = "Isn't this easier to read than \"sideways\" scrollers?"
ScreenLine[3] = " ";
ScreenLine[4] = "How many lines can you display on the status bar?"
ScreenLine[5] = "Here, you can not only display more than one line,\f ";
ScreenLine[6] = "But, you can also display more than one \"page\" !"
ScreenLine[7] = " ";
ScreenLine[8] = "Aren't you glad your browser interprets JavaScript (JScript)?"
ScreenLine[9] = " ";
ScreenLine[10] = "Enjoy!....The JavaFILE crew...\f";
ScreenLine[11] = "P.S.\t'Tis better to have no moving text at all ....."
ScreenLine[12] = "\t... than to have a \"sideways\" scroller.";
ScreenLine[13] = " \f";
/*
To change or add messages, just replace values of or add to ScreenLine[n]
above. Each ScreenLine[n] is a separate line. To change the "page" before
the defined page length is reached, insert a \f character at the end of the
line where you want the break. Use \" for quotes and \t for tabs in the
message text.
*/
var msgNum = 1; // set to first message to display
var msgCnt = 13; // set to number of last message "page" to display.
var typeSpeed = 60; // the typing rate, in milliseconds. (Higher number is slower)
var pageLen = 5; // set to page size, usually number of ROWS in TEXTAREA
var delay=typeSpeed;
var r = 0;
var cr="\r\n"
if ("3" <=navigator.appVersion.charAt(0)) {
var cr="\n"
}
for (x = 1; x<=(msgCnt); x++) {
ScreenLine[x] = ScreenLine[x] + cr;
}
msg = ScreenLine[1];

function DisplayMsg() {
if (msg.length <= i || msg.charAt(i) == "\f") {
r=i;
i=0;
ChangeMsg();
}
outMsg = outMsg + msg.charAt(i);
i++;
if (msg.charAt(i) == "\f" || (lineNo == pageLen && i==msg.length)) {
delay = 4000; }
else {
if (msg.charAt(i) == cr && msg != " "+cr) {
delay = 2000; }
else {
delay = typeSpeed; }
}
self.document.forms[0].elements[0].value=outMsg;
timerDM = setTimeout("DisplayMsg()",delay);
}

function ChangeMsg() {
msgNum++;
if (msgCnt < msgNum) {
msgNum = 1;
}
lineNo++;
if (pageLen < lineNo || msg.charAt(r) == "\f") {
outMsg=ScreenLine[msgNum].charAt(i);
i++;
lineNo = 1;
}
msg = ScreenLine[msgNum];
}

function quitDisplay() {
self.document.forms[0].elements[0].value = "Type yourself a Note today!";
}
// -->
</script>

<title>JavaFILE</title>
<base target="leftframe">
</head>

<body onLoad="DisplayMsg()" ; onUnload="quitDisplay()">

<p align="center"> </p>

<form NAME="msgform" ACTION>
<p><textarea NAME="msgarea" COLS="80" ROWS="5">
JavaScript (or JScript) Power needed.

__________________________________________________ ______________________________
скачан с http://zarvinter.site90.com/script.html
mihmiha вне форума   Ответить с цитированием