کد متن تایپ شونده یا متن تایپی
کد متن تایپ شونده یا متن تایپی با این کد شما میتوانید متنهای دلخواه خود را بصورت تایپ شو یا تایپی در سایت قرار دهید.نحوه کار این کد به این صورت میباشد که چندین جمله در کد جایگذاری میکنید و متن بصورت خودکار برای کاربران شما به صورت تایپی نمایش داده خواهد شد.
کد دوقسمتی بوده هم میتوان همه را در یک قسمت قرار داد و هم میشه بخش اول در هد سایت خود قرار دهید و بخش دوم کد تایپ متن در سایت را در جای دلخواه از سایت و قالب وبلاگ جایگذاری کنید.
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 |
<style> @keyframes myfirst2 { 0% {text-shadow: 0px 0px 0.5px} 50% {text-shadow: 0px 0px 5.5px} 100% {text-shadow: 0px 0px 0.5px} } @-moz-keyframes myfirst2 /* Firefox */ { 0% {text-shadow: 0px 0px 0.5px} 50% {text-shadow: 0px 0px 5.5px} 100% {text-shadow: 0px 0px 0.5px} } @-webkit-keyframes myfirst2 /* Safari and Chrome */ { 0% {text-shadow: 0px 0px 0.5px} 50% {text-shadow: 0px 0px 5.5px} 100% {text-shadow: 0px 0px 0.5px} }</style> <div style="position:absolute;top:-200%;"><a href="https://codebazan.ir/">متن تایپ شونده</a></div><div id="tickerAnchor" style="animation:myfirst2 0.5s infinite;-moz-animation:myfirst2 0.5s infinite; /* Firefox */-webkit-animation:myfirst2 0.5s infinite; /* Safari and Chrome */" dir="rtl" align="center"></div><script language="JavaScript" type="text/javascript"> <!-- // Ticker startup function startTicker() { // Define run time values theCurrentStory = -1; theCurrentLength = 0; // Locate base objects if (document.getElementById) { theAnchorObject = document.getElementById("tickerAnchor"); runTheTicker(); } else { document.write("<style>.ticki{display:none;}.ticko{border:0px; padding:0px;}</style>"); return true; } } // Ticker main run loop function runTheTicker() { var myTimeout; // Go for the next story data block if(theCurrentLength == 0) { theCurrentStory++; theCurrentStory = theCurrentStory % theItemCount; theStorySummary = theSummaries[theCurrentStory].replace(/"/g,'"'); theTargetLink = theSiteLinks[theCurrentStory]; theAnchorObject.href = theTargetLink; thePrefix = "<span class=\"tickls\">" + theLeadString + "</span>"; } // Stuff the current ticker text into the anchor theAnchorObject.innerHTML = thePrefix + theStorySummary.substring(0,theCurrentLength) + whatWidget(); // Modify the length for the substring and define the timer if(theCurrentLength != theStorySummary.length) { theCurrentLength++; myTimeout = theCharacterTimeout; } else { theCurrentLength = 0; myTimeout = theStoryTimeout; } // Call up the next cycle of the ticker setTimeout("runTheTicker()", myTimeout); } // Widget generator function whatWidget() { if(theCurrentLength == theStorySummary.length) { return theWidgetNone; } if((theCurrentLength % 2) == 1) { return theWidgetOne; } else { return theWidgetTwo; } } // --> </script> <!--قسمت بالا را در هد قالب و قسمت پایین را در جای دلخواه قرار دهید--> <script language="JavaScript" type="text/javascript"> <!-- var theCharacterTimeout = 300; var theStoryTimeout = 5000; var theWidgetOne = "_"; var theWidgetTwo = "-"; var theWidgetNone = "**"; var theLeadString = "**"; var theSummaries = new Array(); var theSiteLinks = new Array(); var theItemCount = 6; theSummaries[0] = "به وب سايت کدبازان خوش آمديد.."; theSiteLinks[0] = ""; theSummaries[1] = "کپي برداري از مطالب سايت با ذکر منبع مجاز است "; theSiteLinks[1] = ""; theSummaries[2] = "راستي نظر يادتون نره ها؟؟؟"; theSiteLinks[2] = ""; theSummaries[3] = "به فروشگاه سورس ما هم سر بزنید"; theSiteLinks[3] = ""; theSummaries[4] = "http://shop.codebazan.ir/"; theSiteLinks[4] = ""; theSummaries[5] = "تبادل لينک يادت نره؟؟باااااااااااي"; theSiteLinks[5] = "codebazan.ir"; startTicker(); //--> </script> |
شما میتوانید در کد فوق مقدار سرعت و مکس برای تایپ بعدی را تنظیم نمایید.
برای ویرایش از منو بالای سایت ابزار پیش نمایش را انتخاب نمایید.
بسیار زیباست بشدت دنبال همچین کدی بودم خیلی ممنون زحمت کشیدین
سلام
خوهش میکنم ممنونم از نظر خوبت