13 Oct 2016

မိမိဘေလာ့Postမွာ Post View ထည့္ခ်င္ရင္

မဂၤလာပါဗ်ာ

ကၽြန္ေတာ္ဒီေန႔ေျပာျပေပးမယ့္နည္းေလးကေတာ့မိမိဘေလာ့PostေတြမွာPost Views ေလးထည့္ပံုေလးပါ
မေန႔ကညီေလးတစ္ေယာက္က"အစ္ကိုေရာင္ျပန္ေလးေရ ဒီလိုမ်ိဳး Post Views ဘယ္လိုထည့္ရလဲ" ဆိုၿပီး
Linkတစ္ခုေပးပါတယ္။ကၽြန္ေတာ္၀င္ၾကည့္လိုက္ေတာ့wordpressႀကီးျဖစ္ေနတယ္။
ကၽြန္ေတာ္လည္းWordpressမွာေတာင္ရရင္ဘေလာ့မွာလဲရႏိုင္တယ္ဆိုၿပီးထံုးစံအတိုင္း
Youtubeမွာေမႊေႏွာက္လိုက္တာေတြ႔ပါေရာ။ပထမဦးဆံုးစလုပ္ၾကည့္တာဆိုေတာ့သူကEလိုေျပာ
ကိုယ္ကနားလည္သေလာက္လုပ္ၾကည့္တာေန႔တစ္ပိုင္းကုန္မွရတယ္ ခ္  ခ္။
စကားေတြေျပာေနတာအခ်ိန္ေတာင္ေတာ္ေတာ္ကုန္ျပီ ခ္  ခ္ ။နမူနာၾကည့္ဖို႔ေအာက္မွာDemo Linkေလး

Demo

ကိုႏွိပ္ျပီးသြားၾကည့္ဗ်ာ။
ကဲစမယ္ဗ်ာ ပထမဆံုး  ဒီမွာ Register အရင္သြားလုပ္ဗ်ာ။
အေရးႀကီးပါတယ္။
ေအာက္မွာ SS ေတြျပထားပါျပီေနာ္။
Google Account ေတာ့ရွိဖို႔လိုပါမယ္။(Bloggerေတြပဲရွိမွာပါ)
CREATE NEW PROJECT  ကိုႏွိပ္ပါမယ္။

My awesome project ေနရာမွာအဆင္ေျပတာေရးေပးပါ။(Only English Letter)
Country/region မွာ Myanmar ေရြးေပးပါ။
ျပီးရင္ CREATE PROJECT ကိုႏွိပ္ပါ။
ေအာက္ကစာမ်က္ႏွာေရာက္လာပါၿပီ။

Add Firebase to your web app   ကိုႏွိပ္လိုက္ပါ။ေအာက္ကစာမ်က္ႏွာက်လာပါလိမ့္မယ္။


အေပၚကစာမ်က္ႏွာေရာက္သြားရင္ကၽြန္ေတာ္၀ိုင္းျပထားတာေလးကိုNotepad မွာကူးယူမွတ္ထားလိုက္ပါ။
အေရးႀကီးပါတယ္။
ကဲဇာတ္လမ္းကအခုမွစမွာထံုးစံအတိုင္း
Blog>>>Templated>>>Edit Templated>>>

]]></b:skin>ကိုရွာပါ။
ျပီးရင္သူ႔ရဲ႔အေပၚကပ္ရပ္မွာေအာက္ကCodeကိုထည့္လိုက္ပါ။


/*-------- Post Views  ----------*/
#views-container {
width: 85px;
float: right;
}
.mbtloading {
background: url('https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRSCe7XA4jmWWjequ9xCSY8xLccKJyV0Dwy3stlNNpyY1TIdGQtMFPUfTG64AX3VVa6Ku4JCPhWlvcY5xocyIoAOf-fl5-4boeePYoKm0EdYF4wp2-8c5vKHyxSxS6fKMpaHd4Go5zwNku/s320/mbtloading.gif') no-repeat left center;
width: 16px;
height: 16px;
}
.viewscount {
float: right;
color: #EE5D06;
font: bold italic 14px arial;
}
.views-text {
float: left;
font: bold 12px arial;
color: #333;
}
.views-icon{
background: url('https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj_KKtMvfG9GnbzudSZDBT3wCZ7iT0BrHPb5_YYbP8VUlt8T5Gh6P8SykEB6j4ccdwlnhuo-Gl6CcX2FPHchpxRWSLkFRJznDo_PYxd7-kZP03Ypc57ajPdLdaMxn4Hlay7tTkj4eDjfYFS/s1600/postviews.png') no-repeat left;
border: 0px;
display: block;
width: 16px;
height: 16px;
float: left;
padding: 0px 2px;
}
ျပီးရင္</body>ကိုထပ္ရွာပါ။ေစာေစာကလိုပဲသူ႔အေပၚကပ္ရပ္မွာေအာက္ကCodeကိုထည့္ပါ။
Color ခ်ယ္ထားတဲ႔ေနရာမွာေစာေစာကNotepadမွာမွတ္ထားတာကိုအစားထိုးလိုက္ပါ။


<!-- Post Views Script by MBT --> 
<script type='text/javascript'> 
    window.setTimeout(function() { 
        document.body.className = document.body.className.replace(&#39;loading&#39;, &#39;&#39;); 
      }, 10); 
  </script> 
<script src='https://cdn.firebase.com/v0/firebase.js' type='text/javascript'/> 
<script> 
$.each($(&#39;a[name]&#39;), function(i, e) { 
var elem = $(e).parent().find(&#39;#postviews&#39;).addClass(&#39;mbtloading&#39;); 
var blogStats = new Firebase(&quot;https://mybloggertricks.firebaseio.com/pages/id/&quot; + $(e).attr(&#39;name&#39;)); 
blogStats.once(&#39;value&#39;, function(snapshot) { 
var data = snapshot.val(); 
var isnew = false; 
if(data == null) { 
data= {}; 
data.value = 0; 
data.url = window.location.href; 
data.id = $(e).attr(&#39;name&#39;); 
isnew = true; 

elem.removeClass(&#39;mbtloading&#39;).text(data.value); 
data.value++; 
if(window.location.pathname!=&#39;/&#39;) 

if(isnew) 
blogStats.set(data); 
else 
blogStats.child(&#39;value&#39;).set(data.value); 

}); 
}); 
</script>

မၿပီးေသးဘူးကိုယ့္လူအခု<data:post.body/>ကိုရွာလိုက္ပါဦး။ေတြ႔ရင္သူ႔အေပၚကပ္ရပ္မွာ
<!-- Post Views Counter by MBT--> 
<div id='views-container'><span class='views-icon'/><div class='views-text'>Views:</div> <div class='mbtloading viewscount' id='postviews'/></div>
ေလးထည့္ေပးလိုက္ပါ။
ဒါကေတာ့ေနာက္ဆံုးအဆင့္<head> ကိုရွာပါ။ေတြ႔ရင္သူ႔ေအာက္ကပ္ရပ္မွာ
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'></script>
ထည့္ေပးလိုက္ပါ။ၿပီးရင္ Save Templated ႏွိပ္လိုက္ပါ။
ျပီးပါၿပီဗ်ာ။
အဆင္ေျပၾကပါေစ
ေရာင္ျပန္ေလး(နည္းပညာ)

www.yplitshare.org



တင္ထားသမွ် ေခါင္းစဥ္မ်ား

2Step Verification (5) A+အေၾကာင္း (1) Activator (9) Adobe CS3 Master Collection (1) Adobe Premiere Pro CS6 အသံုးျပဳနည္ (1) Adobe Software (12) Android application (1987) Android Game (710) AndroidPhoneဆိုင္ရာ (4) Antivirus (1) Apowersoft ApowerEdit v1.4.7.22 Build 04042019 (1) AVAST! Cleanup Premium 2019 version 19.1 Build 7085 (1) Blog Slider (8) Blogger Button (5) Blogger Comment (17) Blogger Ebooks (1) Blogger Hack (54) Blogger Loading Style (6) Blogger Mouse (1) Blogger Template (44) Blogger Tips (77) Blogger Widget (152) Blogs Html (63) Blogs Post (86) Blogs Tab Menu (53) Blogဆိုင္ရာ (1) Bowser ဆိုင္ရာ (21) Brothers in Arms® 3 v1.4.7c Mod Data [Unlimited Money] (1) Buddha ျမန္မာစာတန္းထုိး (53) Burning Software (34) Burning Tools (47) C-Box (10) Canon LBP 6000 Original Driver (1) Canon LBP 6030 Original Driver & Installation Guide (1) CCleaner 5.56.7144 (Business / Professional / Technician) Multilingual Portable (1) CD/DVD ဆိုင္ရာမ်ား (30) Cleanner-Speed (68) Computer Autoplay ပိတ္ထားနည္း (1) Computer Partationခြဲနည္း (1) Computer ဆိုင္ရာ (189) Computerဆိုင္ရာ (33) Converter (73) Desing Card (10) Display အလုပ္မလုပ္ေသာ ျပႆနာေျဖရွင္းနညး္မ်ား (1) Domain (3) Download Manager (42) Drive SnapShot v1.46.0.18213 (1) Driver Software (46) DVD-Cloner Platinum 2019 v16.30 Build 1446 [x86/x64] (1) DVDFab v11.0.2.4 [x86/x64] (1) Easy Translator version 14.0.0 (1) Ebooks (405) Errorေျဖ႐ွင္းနည္း (1) Eset Smart Security 12.1.34.0 (x86/x64) (1) Facebook (152) Folder Lock (17) Fonts မ်ားစုစည္းမႈ (6) Foxit PhantomPDF (1) Game (47) Game PC (32) Glary Utilities PRO version 5.117.0.142 (1) Gmail-Gtalk (70) GoogleChome &InternetDownloadmananger (1) Hacking (81) How To Download (6) Html (51) Internet Download Manager (18) InternetDownloadmananger(IDM) (1) IP Hider Software (6) Java Script (11) KhineMaster (1) KMS/2038 & Digital & Online Activation Suite v6.9 (1) MAGIX SOUND FORGE Pro 13 v.13.0.0 Build 46 (1) Marquee Technique (14) Media Player (31) MI Play store Apk (1) Microsoft Office (21) Mobile Legends Bang Bang Installer .exe Pc Version (1) Motors ( ေမာ္တာမ်ား )အေၾကာင္း (1) Movie (95) My Pdf (35) Myanmar Font (9) Myanmar Typing Software (1) MZW Solftware (1) NetGuide Journal (63) Network Software (7) New Blogs (15) Notကာကြယ္ျခင္းနည္း (1) ONEKEY PDF Convert to Word 4.0 REPACK (1) Partition Software (7) Password Recovery Software (1) paypal နွင္ ့ဆိုင္ေသာ (5) PC GAMES (17) PC recovery (13) PC Software (203) PC Speed Up (32) PC-Clean Software (73) PDF (4) PDF Editor (10) Photo Editor Software (64) PHOTO SHOP (သင္တန္း)သီးသန္႔ (44) Photo Slideshow (12) photoshop background အလန္းမ်ား (6) photoshop PNG ဖိုင္မ်ားရွာရန္ (14) Photoshop Software (35) Photoshop ဆိ္ုင္ရာ (51) Player (8) PrinterDriver (2) Programming (16) Pyidaungsu font (1) Read More (9) Recent Posts Widget (23) Recover Software (46) Recovery (33) Refresh and Restoreအေၾကာင္း (1) Reset (1) SAMSUNG One UI ဖုန္းေတြအတြက္ ျမန္မာေဖာင့္ (1) Screen Video Recorder (37) Search Box (6) Security Software (36) Sidebar Widget (71) SkyNet လိုင္းအသစ္ထည့္နည္း (1) SkynetBinfile (1) Slideshow Movie Maker (7) Social Widget (19) SOFTWARE (588) Software For Blogs (17) Software မ်ားအသံုးျပဳနည္း (2) Softwares ေတြအတြက္ Serial no (or) Key ေတာင္းလၽွင္ ေျဖ႐ွင္းနည္း (1) Speed Up Internet (13) TeamViewer version 14.2.2558.0 (Repack & Portable) (1) TTA Pie Myanmar (1) Unicode ေ​ြေပာင်းနည်း (1) Uninstaller Software (25) Upload (6) USB ျဖင့္၀င္းဒိုးတင္နည္း (4) USB ႀကိဳးကေန Virus မဝင္ေအာင္ ႀကိဳတင္ ကာကြယ္နည္း (1) Usb-Memory (19) Video Converter (29) Video Editing (76) Video Editor (1) Video Recorder (12) Virus ဆိုင္ရာ (86) WannaCry Ransomware ၏ အႏၱရာယ္ အေၾကာင္းႏွင့္ ကာကြယ္နည္း (1) Web Design ေရးဆြဲနည္း (5) Webcam Camera Software (11) Website ေရးနည္း (3) Wifi ဆိုင္ရာ (32) Win Update v1.4 (1) Window-10 ဆိုင္ရာ (2) Window-7 ဆိုင္ရာ (32) Window-xp ဆုိင္ရာ (2) window8ဆိုင္ရာ (19) Windows 10 Factory Reset ခ်နည္း (1) Windows 10 Backup & Restore လုုပ္နည္း (1) Windows 10 ကြန္ပ်ဴတာမွာျမန္မာစာတိက်မွန္စြာထည့္နည္း (1) Windows Activator (18) windows loader မ်ား (10) Windows Manager Software (23) Windows Themes (24) Windows တင္နည္းမ်ား (6) WinRAR 5.70 (Fully) (1) WinRar Full Version (12) WinRAR V3.80 Beta Version (1) WinToBootic ႏွင့္ USB ထဲ Install လုပ္နည္း (7) WinUtilities Professional Edition Tool (1) Wordpress Tips (3) Write-Protected ကို ျဖဳတ္ႏိုင္မယ့္နည္းႏွစ္သြယ္ (1) Zawgyi နဲ႔ Unocode ဘာကြာလဲ (1) ကြန္ပ်ဴတာ User Account Picture အေၾကာင္းမ်ား (1) ကြန္ပ်ဴတာဆိုင္ရာ (1) ကြန္ပ်ဴတာပတ္၀ပ္ေျပာင္းမရေအာင္လုပ္နည္း (1) ကြန္ပ်ဴတာရဲ ့Storage က HDD လား? SSD လား? စစ္ေဆးနည္းမ်ား (1) ကြန္ပ်ဴတာဟန္းေနရင္ေျဖ႐ွင္းနည္း (1) ကြ်နုပ္ႏွင့္ ပရဟိတအလွဴ (9) ကာမသိဒၶိက်မ္း (1) ခ်က္နည္းျပဳတ္နည္း (1) နည္းပညာဆိုင္ရာ (2) နည္းလမ္းမ်ား (6) ပန္ကာျပဳျပင္နည္း (1) ဖိုင္ေျဖနည္းမ်ား (8) ဗဟုသုတ (6) ဗားရွင္းအသစ္ထြက္ရွိလာတဲ႔ Facebook (ႏွင္႔) Messenger (1) ဘာသာစကား ၉၁ မ်ိုးထိ ပါ၀င္တဲ့ Easy Translator (1) ဘာသာေရးစာအုပ္မ်ား (9) မိမိဆိုက္ကိုေကာ္ပီကူးမရေအာင္ ပိတ္ထားနည္း (1) ျပည္ေထာင္စု ေဖာင့္ လက္ကြက္ ႏွင့္ စာ႐ိုက္နည္း (1) ျမန္မာစာမွန္ေအာင္လုပ္နည္း (1) ျမန္မာဆိုတာ (1) ဝင္းဒုိးကုိ AOMEISoftware ျဖင္႔ Backup & Restore လုပ္နည္း (1) သင့္ Laptop ကို ျမန္ဆန္ေအာင္လုပ္ေပးမယ့္ အခ်က္ ၇ ခ်က (1) အင္တာဗ်ဴးအစီစဥ္ (2) အပ်ိဳလမ္းၫႊန္ (1) အသံဇာတ္လမ္း (19) အေျခခံကြန္ပ်ဴတာ Pdf (1) ဦးဇာနည္နည္းလမ္းမ်ား (7) ေဆာ့ဝဲ ျပႆနာေျဖ႐ွင္းနည္း (1) ေၾကာ္ျငာ (13) ေဟာေျပာပြဲ (15)

မန္ဘာ၀င္လို႕အားေပးၾကပါ