Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <b:if cond='data:blog.pageType == "item"'>
- <script type='text/javascript'>
- //<![CDATA[
- // طريقة ظهور عدد موضوعات الكاتب داخل تعريفه
- //
- var aut_desc = {};
- var auth_url = {};
- // اعدادات يمكنك استخدامها والتعديل عليها عند توفر أكثر من كاتب
- var multiAuthor = false; // اذا كان هناك أكثر من مؤلف يمكنك تغيير كلمة false الى true
- var onePost = "موضوع";
- var manyPosts = "موضوعات";
- // يمكنك تغيير الاسماء على حسب اسم الكاتب أو المؤلف وكذلك التعديل على البيانات الخاصة به
- aut_desc['اسم الأدمن'] = 'INFO <a href="BLOG URL">BLOG NAME</a> INFO.<br>روابط مفضلة: <a class="authorinfolink">رابط حسابه</a> - <a href="YOUTUBE CHANNEL">اسم قناته على اليوتيوب</a> - <a href="TWITTER ACCOUNT">اسم حسابه على تويتر</a>.';
- aut_desc['اسم المؤلف الأول'] = 'INFO.';
- aut_desc['اسم المؤلف الثانى'] = 'INFO.';
- aut_desc['اسم المؤلف الثالث'] = 'INFO.';
- // يمكنك تغيير الرابط الذى يتضمن اسم الكاتب أو المؤلف
- auth_url['سم الأدمن'] = 'LINK';
- auth_url['اسم المؤلف الأول'] = 'LINK';
- auth_url['اسم المؤلف الثانى'] = 'LINK';
- auth_url['اسم المؤلف الثالث'] = 'LINK';
- // Configure CSS:
- //]]>
- </script>
- <style type='text/css'>
- .post-author-block {
- display: none;
- margin: 20px 0 0;
- padding: 5px 10px;
- background-color: #f0f0f0;
- border: 1px solid #e0e0e0;
- line-height: 1.6;
- font-size: 120%;
- }
- .authorinfoname { font-weight: bold; }
- .authorinfoimage { float: right; margin-left: 8px; width:52px;}
- </style>
- <!-- Customize this div, which contains the author box: -->
- <div class='post-author-block'> <a class='authorinfolink'><img border='0' class='authorinfoimage' src='http://lh5.googleusercontent.com/-UQ9nUDFOVt0/AAAAAAAAAAI/AAAAAAAAI3I/f9E7vHvQ90Q/s512-c/photo.jpg'/></a>
- <div><a class='authorinfolink'><span class='authorinfoname'/></a> &ndash; كتب <span class='authorinfopostcount'>0</span> موضوعات <span class='authorinfopost'>مميزة</span> على <a href="http://abu-iyad.com/">مدونة أبو إياد</a>.</div>
- <h2>مهندس مصري ومتابع جيد للأخبار والمستجدات التقنية والاعلام الاجتماعى. أحب القراءة والترجمة. كاتب فى مدونة عالم الإبداع ومشرف سابق بموقع نقطة التطوير. تابعنى على تويتر</h2>
- <div><span class='authorinfodescription'></span></div>
- <div style='clear:both;'/>
- </div>
- <script type='text/javascript'>
- //<![CDATA[
- var authors = {};
- var ndxbase = 1;
- var auname = "";
- function getAuthorInfo(json) {
- var authorName = "";
- for(var i = 0 ; i < json.feed.entry.length ; i++ ) {
- var entry = json.feed.entry[i];
- authorName = entry.author[0].name.$t;
- if(authors[authorName])
- authors[authorName].count++;
- else {
- var aut = new Object();
- aut.author = entry.author[0];
- aut.count = 1;
- authors[authorName] = aut;
- }
- if(!multiAuthor) break;
- }
- if(multiAuthor && json.feed.entry.length == 500) {
- ndxbase += 500;
- document.write('<script type="text/javascript" src="http://'+window.location.hostname+'/feeds/posts/default?redirect=false&max-results=500&start-index='+ndxbase+'&alt=json-in-script&callback=getAuthorInfo"></'+'script>');
- return;
- }
- if(!multiAuthor)
- authors[authorName].count = json.feed.openSearch$totalResults.$t;
- au = auname;
- if(authors[au]) {
- if(aut_desc[au] && aut_desc[au] != "")
- $(".authorinfodescription").html(aut_desc[au]);
- $(".authorinfopostpost").text(parseInt(authors[au].count) == 1 ? onePost : manyPosts);
- $(".authorinfopostcount").text(authors[au].count);
- if(authors[au].author.gd$image)
- $(".authorinfoimage").attr("src", authors[au].author.gd$image.src);
- $(".authorinfoimage").attr("title", au);
- $(".authorinfolink").attr("title", au);
- $(".authorinfoname").text(au);
- if(authors[au].author.uri && authors[au].author.uri.$t != "")
- $(".authorinfolink").attr("href", authors[au].author.uri.$t);
- if(auth_url[au] && auth_url[au] != "")
- $(".authorinfolink").attr("href", auth_url[au]);
- $(".post-author-block").show();
- }
- }
- //]]>
- auname = "<data:post.author/>";
- //<![CDATA[
- document.write('<script type="text/javascript" src="http://'+window.location.hostname+'/feeds/posts/default?redirect=false&max-results=500&alt=json-in-script&callback=getAuthorInfo"></'+'script>');
- //]]>
- </script>
- </b:if>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement