Chinese calendar widget – this is a small piece of Mingli on your site. Add a Chinese calendar widget to make your site more visited and informative – your visitors will come to you to find out if today is an auspicious day.
Chinese calendar widget can show complete information about current day with day map and detailed description. It has flexible visualization settings and content display and is available in both Russian and English.
If you understand programming, you can install it yourself, if not – ask your programmer.
Location Options
Examples of the widget in Russian:
- Display all available information. Hieroglyphs and pluses and minuses as text.
- Displaying the vertical location of the widget with disabled descriptions, pluses, minuses and 28 moon sites. Jianchu pros/cons are displayed as icons.
- Display the Chinese calendar widget vertically with descriptions and pros and cons disabled . Hieroglyphs as text.
Examples of the widget in English:
- Displays the vertical position of the widget with disabled descriptions and pluses and minuses. Jianchu pros/cons are displayed as icons.
- Display the vertical position of the widget with descriptions disabled. Hieroglyphs and pluses and minuses as text.
- Display all available information. Hieroglyphs and pluses and minuses as icons.
Including a widget (Chinese calendar) on your website
- The widget must be included on pages in UTF-8 encoding!
- To add a widget to your site, you can place the code in the tag, or in the block where you include the main script and css files used on the site.:
Code to embed on the site (vertical version):
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></ script>
<script src="http://www.mingli.ru/js/informers.js"></script>
  ; <link rel="stylesheet" type="text/css" href="http://www.mingli.ru/css/mingli_widget.css " />
<script>
A function to get the current time from the user
var date = new Date();
tM = date.getMonth()+1; if (tM<10) tM="0"+tM;
tD = date.getDate(); if (tD<10) tD="0"+tD;
CurDate = tD+"."+tM+"."+date.getFullYear();
Informer settings
informer({
  ; 'informer':'cDay', //DO NOT CHANGE!
'output': '#informer' // ID of the element where the informer will be displayed
}); - Specify the location option, for this you need to replace the link to the style file in the informer code:
Vertical option:
<link rel="stylesheet" type="text/css" href="http://www.mingli.ru/css/mingli_widget.css" />Horizontal option:<link rel="stylesheet" type="text/css" href="http://www.mingli.ru/css/mingli_widget-H.css" /> - Install the tag in the right place for you on the page with id = “informer”:
//element where the informer will be displayed. His position
<div id="informer"></div> //the element where the informer will be displayed. His position
Chinese calendar widget customization
You can flexibly customize the displayed content of the calendar, for this, in the code, after specifying the ID of the informer output element, you need to put a comma and insert additional code after the comma:
'data':{}
In curly quotation marks of this piece of code, you can specify display parameters by assigning a value of 0 (hide) or 1 (show), if the parameter is not specified, it defaults to 1, all text values must be specified in quotation marks:
'day' - Indicates the day in the format dd.mm.yy, example (01/23/2014), the parameter is not set, then the current day for Russia is displayed, regardless of the user's computer settings.'lang' – English en-GB or Russian ru-RU
'text' – Display hieroglyphs or names in the map
'description' – hide/show descriptions
'zanchu_show_icon' – display jian chu pros/cons with icons or text
'zanchu' – hide/show pluses and minuses of jian chu
'show_plus' – hide/show pros and cons
'assassin' – hide/show the day that kills the master
'destroyers' – hide/show destroyers
'misfortunes' – hide/show losses
'sha' – hide/show sha
'lunar' – hide/show lunar days
'28stays' – hide/show 28 lunar mansions
An example of using additional widget settings in English:
informer({
'informer':'cDay',
'output ': '#informer',
'data':{
'day': CurDate, //Specify the current date
'lang':'en-GB' , //English en-GB or Russian ru-RU
'text':0,/ //Display characters or names
'zanchu_show_icon':1, //display jian chu pros/cons with icons
sp; 'show_plus':0,// hide/show jian chu
'description':0,//hide descriptions
'assassin':0, // hide the day that kills the master
'destroyers':1, // hide/show destroyers
'misfortunes':1, // show losses
'sha': 1, // show sha
'lunar':1, // hide lunar days
'28stays':0 //hide 28 moonsites
}
});