نوشتن به صورت تایپ در Title Bar وبلاگ

افزونه ها و كدهاي جاوا
موضوع جدید ارسال پست
آواتار کاربر
black_Sky
مدير كل سایت
مدير كل سایت
پست: 95
تاریخ عضویت: دوشنبه ۱۲ تیر ۱۳۹۱, ۸:۳۲ ق.ظ
محل اقامت: TeHran
Has thanked: 28 times
Been thanked: 46 times
تماس:

نوشتن به صورت تایپ در Title Bar وبلاگ

پست توسط black_Sky »

نوشتن به صورت تایپ در Title Bar وبلاگ
این کد یک متن را به صورت افکت تایپ شدن در بالای صفحه مرورگر Title Bar اجرا می کند

قابل اجرا در تمامی مرورگرها
این کد از یک بخش تشکیل شده و حتوای کدها را به بخش head قالب خود اضافه کنید
برای تغییر متن message را پیدا کرده و متن های This script will type out in your title bar over and را تغییر دهید
برای بقیه متن ها هم همین کار را انجام دهید


اين هم كد:[LEFT]

کد: انتخاب همه

<META NAME="Generator" CONTENT="TextPad 4.4">
<LINK href="general.css" rel="stylesheet" type="text/css">
<SCRIPT LANGUAGE="JavaScript">
<!-- Modified:  Jim Einarson (jim.einarson@ccra-adrc.gc.ca) -->
<!-- Original:  David Sosnowski -->
<!-- Web Site:  http://www.codebelly.com -->
<!-- Begin
var message = new Array();
// Set your messages you want typed into the title bar below.
// To add more messages, just add more elements to the array.
message[0] = "This script will type out in your title bar over and over...";
message[1] = "followed by whatever you type here...";
message[2] = "and then, whatever you choose to type here...";
message[3] = "and so on...";
message[4] = "and so on...";

// Set the number of repetitions (how many times a given message is typed out
// before moving onto the next message).
var reps = 1;
var speed = 275;// Set the overall typing speed (larger number = slower action).
var hold = 4 // set the length of time to display the whole phrase before retyping (larger number = longer)

// DO NOT EDIT BELOW THIS LINE.
var p = message.length;
var q = 0;
var r = 0;
var C = 0;
var mC = 0;
var s = 0;
var sT = null;

if (reps < 1) {
reps = 1;
}
function setMessage() {
typing = message[mC];
q = typing.length;
r = q + hold;
typeMessage();
}
function typeMessage() {
if (s > r) {
s = 0;
}
if (s > q) {
document.title = '|- '+ typing +' - - -';
}
else {
document.title = '|- '+ typing.substr(0,s)+' - - -';
}
if (C < (r * reps)) {
sT = setTimeout("typeMessage()", speed);
C++;
s++;
}
else {
C = 0;
s = 0;
mC++;
if(mC > p - 1) {mC = 0;}
sT = null;
setMessage();
   }
}
setMessage();
//  End -->
</script>

[/LEFT]


موضوع جدید ارسال پست