├── README.md ├── article ├── __init__.py ├── __init__.pyc ├── admin.py ├── admin.pyc ├── migrations │ ├── 0001_initial.py │ ├── 0001_initial.pyc │ ├── 0002_articlemanager.py │ ├── 0002_articlemanager.pyc │ ├── 0003_auto_20150709_1752.py │ ├── 0003_auto_20150709_1752.pyc │ ├── 0004_auto_20150709_2217.py │ ├── 0004_auto_20150709_2217.pyc │ ├── __init__.py │ └── __init__.pyc ├── models.py ├── models.pyc ├── templatetags │ ├── __init__.py │ ├── __init__.pyc │ ├── custom_markdown.py │ └── custom_markdown.pyc ├── tests.py ├── views.py └── views.pyc ├── db.sqlite3 ├── manage.py ├── my_site ├── __init__.py ├── __init__.pyc ├── settings.py ├── settings.pyc ├── urls.py ├── urls.pyc ├── wsgi.py └── wsgi.pyc ├── requirement.txt ├── static ├── css │ ├── bg.jpg │ ├── post.png │ ├── style.css │ ├── style.css~ │ └── top.png ├── lib │ ├── bootstrap │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ ├── font-awesome-ie7.css │ │ │ ├── font-awesome-ie7.min.css │ │ │ ├── font-awesome.css │ │ │ └── font-awesome.min.css │ │ ├── font │ │ │ ├── FontAwesome.otf │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.svg │ │ │ ├── fontawesome-webfont.ttf │ │ │ └── fontawesome-webfont.woff │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ ├── jqcloud-1.0.4.js │ ├── jqcloud.css │ ├── jquery.js │ ├── monokai.css │ ├── responsive-nav.css │ ├── responsive-nav.js │ ├── scorllup.js │ ├── scripts │ │ ├── shAutoloader.js │ │ ├── shBrushAS3.js │ │ ├── shBrushAppleScript.js │ │ ├── shBrushBash.js │ │ ├── shBrushCSharp.js │ │ ├── shBrushColdFusion.js │ │ ├── shBrushCpp.js │ │ ├── shBrushCss.js │ │ ├── shBrushDelphi.js │ │ ├── shBrushDiff.js │ │ ├── shBrushErlang.js │ │ ├── shBrushGroovy.js │ │ ├── shBrushJScript.js │ │ ├── shBrushJava.js │ │ ├── shBrushJavaFX.js │ │ ├── shBrushPerl.js │ │ ├── shBrushPhp.js │ │ ├── shBrushPlain.js │ │ ├── shBrushPowerShell.js │ │ ├── shBrushPython.js │ │ ├── shBrushRuby.js │ │ ├── shBrushSass.js │ │ ├── shBrushScala.js │ │ ├── shBrushSql.js │ │ ├── shBrushVb.js │ │ ├── shBrushXml.js │ │ └── shLegacy.js │ ├── shCore.css │ ├── shCore.js │ ├── shCore.js~ │ └── shThemeRDark.css └── tinymce │ ├── config.js │ ├── config.js~ │ ├── langs │ ├── readme.md │ └── zh_CN.js │ ├── license.txt │ ├── plugins │ ├── advlist │ │ └── plugin.min.js │ ├── anchor │ │ └── plugin.min.js │ ├── autolink │ │ └── plugin.min.js │ ├── autoresize │ │ └── plugin.min.js │ ├── autosave │ │ └── plugin.min.js │ ├── bbcode │ │ └── plugin.min.js │ ├── charmap │ │ └── plugin.min.js │ ├── code │ │ └── plugin.min.js │ ├── colorpicker │ │ └── plugin.min.js │ ├── contextmenu │ │ └── plugin.min.js │ ├── directionality │ │ └── plugin.min.js │ ├── emoticons │ │ ├── img │ │ │ ├── smiley-cool.gif │ │ │ ├── smiley-cry.gif │ │ │ ├── smiley-embarassed.gif │ │ │ ├── smiley-foot-in-mouth.gif │ │ │ ├── smiley-frown.gif │ │ │ ├── smiley-innocent.gif │ │ │ ├── smiley-kiss.gif │ │ │ ├── smiley-laughing.gif │ │ │ ├── smiley-money-mouth.gif │ │ │ ├── smiley-sealed.gif │ │ │ ├── smiley-smile.gif │ │ │ ├── smiley-surprised.gif │ │ │ ├── smiley-tongue-out.gif │ │ │ ├── smiley-undecided.gif │ │ │ ├── smiley-wink.gif │ │ │ └── smiley-yell.gif │ │ └── plugin.min.js │ ├── example │ │ ├── dialog.html │ │ └── plugin.min.js │ ├── example_dependency │ │ └── plugin.min.js │ ├── fullpage │ │ └── plugin.min.js │ ├── fullscreen │ │ └── plugin.min.js │ ├── hr │ │ └── plugin.min.js │ ├── image │ │ └── plugin.min.js │ ├── importcss │ │ └── plugin.min.js │ ├── insertdatetime │ │ └── plugin.min.js │ ├── layer │ │ └── plugin.min.js │ ├── legacyoutput │ │ └── plugin.min.js │ ├── link │ │ └── plugin.min.js │ ├── lists │ │ └── plugin.min.js │ ├── media │ │ ├── moxieplayer.swf │ │ └── plugin.min.js │ ├── nonbreaking │ │ └── plugin.min.js │ ├── noneditable │ │ └── plugin.min.js │ ├── pagebreak │ │ └── plugin.min.js │ ├── paste │ │ └── plugin.min.js │ ├── preview │ │ └── plugin.min.js │ ├── print │ │ └── plugin.min.js │ ├── save │ │ └── plugin.min.js │ ├── searchreplace │ │ └── plugin.min.js │ ├── sh4tinymce │ │ ├── fonts │ │ │ ├── sh4tinymce.dev.svg │ │ │ ├── sh4tinymce.eot │ │ │ ├── sh4tinymce.svg │ │ │ ├── sh4tinymce.ttf │ │ │ └── sh4tinymce.woff │ │ ├── langs │ │ │ ├── en.js │ │ │ └── fr_FR.js │ │ ├── plugin.js │ │ ├── plugin.js~ │ │ ├── plugin.min.js │ │ └── style │ │ │ └── style.css │ ├── spellchecker │ │ └── plugin.min.js │ ├── tabfocus │ │ └── plugin.min.js │ ├── table │ │ └── plugin.min.js │ ├── template │ │ └── plugin.min.js │ ├── textcolor │ │ └── plugin.min.js │ ├── textpattern │ │ └── plugin.min.js │ ├── visualblocks │ │ ├── css │ │ │ └── visualblocks.css │ │ └── plugin.min.js │ ├── visualchars │ │ └── plugin.min.js │ └── wordcount │ │ └── plugin.min.js │ ├── skins │ └── lightgray │ │ ├── content.inline.min.css │ │ ├── content.min.css │ │ ├── fonts │ │ ├── tinymce-small.eot │ │ ├── tinymce-small.svg │ │ ├── tinymce-small.ttf │ │ ├── tinymce-small.woff │ │ ├── tinymce.eot │ │ ├── tinymce.svg │ │ ├── tinymce.ttf │ │ └── tinymce.woff │ │ ├── img │ │ ├── anchor.gif │ │ ├── loader.gif │ │ ├── object.gif │ │ └── trans.gif │ │ ├── skin.ie7.min.css │ │ └── skin.min.css │ ├── themes │ └── modern │ │ └── theme.min.js │ └── tinymce.min.js └── templates ├── 404.html ├── 500.html ├── base.html └── blog ├── _comments.html ├── _paginator.html ├── _side.html ├── about.html ├── archive.html ├── content.html ├── index.html └── message.html /README.md: -------------------------------------------------------------------------------- 1 | # my_site 2 | Django+Bootstrap搭建的简易个人博客 3 | 1.后台使用Bootstrap-admin 4 | 2.实现文章按月归档 5 | 5.实现文章分类,标签 6 | 3.采用第三方评论:多说 7 | 4.引入微博秀 8 | 5.采用JQcloud实现标签云功能 9 | 6.后台引入TinyMce富文本编辑器,前端使用SyntaxHighlighter进行代码高亮 10 | 7.引入站长统计以及访问统计 11 | 12 | 13 | -------------------------------------------------------------------------------- /article/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/__init__.py -------------------------------------------------------------------------------- /article/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/__init__.pyc -------------------------------------------------------------------------------- /article/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | 3 | from article.models import Author,Tag,Classification,Article 4 | # Register your models here. 5 | #from django_summernote.admin import SummernoteModelAdmin 6 | admin.site.register(Author) 7 | admin.site.register(Tag) 8 | admin.site.register(Classification) 9 | 10 | #class ArticleAdmin(SummernoteModelAdmin): 11 | #pass 12 | #admin.site.register(Article,ArticleAdmin) 13 | 14 | class ArticleAdmin(admin.ModelAdmin): 15 | class Media: 16 | js = ( 17 | 18 | '/static/tinymce/tinymce.min.js', 19 | '/static/tinymce/config.js', 20 | 21 | ) 22 | admin.site.register(Article,ArticleAdmin) 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /article/admin.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/admin.pyc -------------------------------------------------------------------------------- /article/migrations/0001_initial.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ] 11 | 12 | operations = [ 13 | migrations.CreateModel( 14 | name='Article', 15 | fields=[ 16 | ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), 17 | ('title', models.CharField(max_length=100)), 18 | ('content', models.TextField(null=True, blank=True)), 19 | ('publish_time', models.DateTimeField(auto_now_add=True)), 20 | ('count', models.IntegerField(default=0)), 21 | ], 22 | options={ 23 | 'ordering': ['-publish_time'], 24 | }, 25 | bases=(models.Model,), 26 | ), 27 | migrations.CreateModel( 28 | name='Author', 29 | fields=[ 30 | ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), 31 | ('name', models.CharField(max_length=30)), 32 | ('email', models.EmailField(max_length=75, blank=True)), 33 | ('website', models.URLField(blank=True)), 34 | ], 35 | options={ 36 | }, 37 | bases=(models.Model,), 38 | ), 39 | migrations.CreateModel( 40 | name='Classification', 41 | fields=[ 42 | ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), 43 | ('name', models.CharField(max_length=25)), 44 | ], 45 | options={ 46 | }, 47 | bases=(models.Model,), 48 | ), 49 | migrations.CreateModel( 50 | name='Tag', 51 | fields=[ 52 | ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), 53 | ('name', models.CharField(max_length=20, blank=True)), 54 | ('creat_time', models.DateTimeField(auto_now_add=True)), 55 | ], 56 | options={ 57 | }, 58 | bases=(models.Model,), 59 | ), 60 | migrations.AddField( 61 | model_name='article', 62 | name='author', 63 | field=models.ForeignKey(to='article.Author'), 64 | preserve_default=True, 65 | ), 66 | migrations.AddField( 67 | model_name='article', 68 | name='classification', 69 | field=models.ForeignKey(to='article.Classification'), 70 | preserve_default=True, 71 | ), 72 | migrations.AddField( 73 | model_name='article', 74 | name='tags', 75 | field=models.ManyToManyField(to='article.Tag', blank=True), 76 | preserve_default=True, 77 | ), 78 | ] 79 | -------------------------------------------------------------------------------- /article/migrations/0001_initial.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/migrations/0001_initial.pyc -------------------------------------------------------------------------------- /article/migrations/0002_articlemanager.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('article', '0001_initial'), 11 | ] 12 | 13 | operations = [ 14 | migrations.CreateModel( 15 | name='ArticleManager', 16 | fields=[ 17 | ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), 18 | ], 19 | options={ 20 | }, 21 | bases=(models.Model,), 22 | ), 23 | ] 24 | -------------------------------------------------------------------------------- /article/migrations/0002_articlemanager.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/migrations/0002_articlemanager.pyc -------------------------------------------------------------------------------- /article/migrations/0003_auto_20150709_1752.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | import tinymce.models 6 | 7 | 8 | class Migration(migrations.Migration): 9 | 10 | dependencies = [ 11 | ('article', '0002_articlemanager'), 12 | ] 13 | 14 | operations = [ 15 | migrations.AlterField( 16 | model_name='article', 17 | name='content', 18 | field=tinymce.models.HTMLField(null=True, blank=True), 19 | preserve_default=True, 20 | ), 21 | ] 22 | -------------------------------------------------------------------------------- /article/migrations/0003_auto_20150709_1752.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/migrations/0003_auto_20150709_1752.pyc -------------------------------------------------------------------------------- /article/migrations/0004_auto_20150709_2217.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('article', '0003_auto_20150709_1752'), 11 | ] 12 | 13 | operations = [ 14 | migrations.AlterField( 15 | model_name='article', 16 | name='content', 17 | field=models.TextField(null=True, blank=True), 18 | preserve_default=True, 19 | ), 20 | ] 21 | -------------------------------------------------------------------------------- /article/migrations/0004_auto_20150709_2217.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/migrations/0004_auto_20150709_2217.pyc -------------------------------------------------------------------------------- /article/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/migrations/__init__.py -------------------------------------------------------------------------------- /article/migrations/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/migrations/__init__.pyc -------------------------------------------------------------------------------- /article/models.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/models.pyc -------------------------------------------------------------------------------- /article/templatetags/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/templatetags/__init__.py -------------------------------------------------------------------------------- /article/templatetags/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/templatetags/__init__.pyc -------------------------------------------------------------------------------- /article/templatetags/custom_markdown.py: -------------------------------------------------------------------------------- 1 | #coding:utf-8 2 | import markdown 3 | 4 | from django import template 5 | from django.template.defaultfilters import stringfilter 6 | from django.utils.encoding import force_text 7 | from django.utils.safestring import mark_safe 8 | 9 | register = template.Library() #自定义filter时必须加上 10 | 11 | 12 | @register.filter(is_safe=True) #注册template filter 13 | @stringfilter #希望字符串作为参数 14 | def custom_markdown(value): 15 | return mark_safe(markdown.markdown(value, 16 | extensions = ['markdown.extensions.fenced_code', 'markdown.extensions.codehilite'], 17 | safe_mode=True, 18 | enable_attributes=False)) 19 | -------------------------------------------------------------------------------- /article/templatetags/custom_markdown.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/templatetags/custom_markdown.pyc -------------------------------------------------------------------------------- /article/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /article/views.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/article/views.pyc -------------------------------------------------------------------------------- /db.sqlite3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/db.sqlite3 -------------------------------------------------------------------------------- /manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | import os 3 | import sys 4 | 5 | if __name__ == "__main__": 6 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "my_site.settings") 7 | 8 | from django.core.management import execute_from_command_line 9 | 10 | execute_from_command_line(sys.argv) 11 | -------------------------------------------------------------------------------- /my_site/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/my_site/__init__.py -------------------------------------------------------------------------------- /my_site/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/my_site/__init__.pyc -------------------------------------------------------------------------------- /my_site/settings.py: -------------------------------------------------------------------------------- 1 | """ 2 | Django settings for my_site project. 3 | 4 | For more information on this file, see 5 | https://docs.djangoproject.com/en/1.7/topics/settings/ 6 | 7 | For the full list of settings and their values, see 8 | https://docs.djangoproject.com/en/1.7/ref/settings/ 9 | """ 10 | 11 | # Build paths inside the project like this: os.path.join(BASE_DIR, ...) 12 | import os 13 | BASE_DIR = os.path.dirname(os.path.dirname(__file__)) 14 | 15 | 16 | # Quick-start development settings - unsuitable for production 17 | # See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/ 18 | 19 | # SECURITY WARNING: keep the secret key used in production secret! 20 | SECRET_KEY = 'p-2_9jdgcawck*piav1d(kq-!((g#8#riop01(^5ilnl6f(ram' 21 | 22 | # SECURITY WARNING: don't run with debug turned on in production! 23 | DEBUG = True 24 | 25 | TEMPLATE_DEBUG = True 26 | 27 | ALLOWED_HOSTS = ['*'] 28 | 29 | 30 | # Application definition 31 | 32 | INSTALLED_APPS = ( 33 | 'bootstrap_admin', 34 | 'django.contrib.admin', 35 | 'django.contrib.auth', 36 | 'django.contrib.contenttypes', 37 | 'django.contrib.sessions', 38 | 'django.contrib.messages', 39 | 'django.contrib.staticfiles', 40 | 'article', 41 | ) 42 | 43 | from django.conf import global_settings 44 | TEMPLATE_CONTEXT_PROCESSORS = global_settings.TEMPLATE_CONTEXT_PROCESSORS + ( 45 | 'django.core.context_processors.request', 46 | ) 47 | BOOTSTRAP_ADMIN_SIDEBAR_MENU = True 48 | 49 | 50 | MIDDLEWARE_CLASSES = ( 51 | 'django.contrib.sessions.middleware.SessionMiddleware', 52 | 'django.middleware.common.CommonMiddleware', 53 | 'django.middleware.csrf.CsrfViewMiddleware', 54 | 'django.contrib.auth.middleware.AuthenticationMiddleware', 55 | 'django.contrib.auth.middleware.SessionAuthenticationMiddleware', 56 | 'django.contrib.messages.middleware.MessageMiddleware', 57 | 'django.middleware.clickjacking.XFrameOptionsMiddleware', 58 | ) 59 | 60 | ROOT_URLCONF = 'my_site.urls' 61 | 62 | WSGI_APPLICATION = 'my_site.wsgi.application' 63 | 64 | 65 | # Database 66 | # https://docs.djangoproject.com/en/1.7/ref/settings/#databases 67 | 68 | DATABASES = { 69 | 'default': { 70 | 'ENGINE': 'django.db.backends.sqlite3', 71 | 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'), 72 | } 73 | } 74 | 75 | # Internationalization 76 | # https://docs.djangoproject.com/en/1.7/topics/i18n/ 77 | 78 | LANGUAGE_CODE = 'zh-ch' 79 | 80 | TIME_ZONE = 'Asia/Shanghai' 81 | 82 | USE_I18N = True 83 | 84 | USE_L10N = True 85 | 86 | USE_TZ = False 87 | 88 | 89 | # Static files (CSS, JavaScript, Images) 90 | # https://docs.djangoproject.com/en/1.7/howto/static-files/ 91 | 92 | STATIC_URL = '/static/' 93 | STATIC_ROOT = "var/www/example.com/static/" 94 | 95 | MEDIA_URL = '/media/' 96 | MEDIA_ROOT = os.path.join(BASE_DIR,'media') 97 | 98 | STATICFILES_DIRS = ( 99 | os.path.join(BASE_DIR,'static'), 100 | ) 101 | TEMPLATE_DIRS = ( 102 | os.path.join(BASE_DIR,'templates'), 103 | ) 104 | 105 | 106 | ADMINS = { 107 | 108 | ('tmac', 'kan49733110@163.com'), 109 | 110 | } 111 | 112 | 113 | 114 | 115 | 116 | 117 | -------------------------------------------------------------------------------- /my_site/settings.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/my_site/settings.pyc -------------------------------------------------------------------------------- /my_site/urls.py: -------------------------------------------------------------------------------- 1 | #coding:utf-8 2 | from django.conf.urls import patterns, include, url 3 | from django.contrib import admin 4 | from article.views import RSSFeed 5 | 6 | urlpatterns = patterns('', 7 | # Examples: 8 | # url(r'^$', 'my_site.views.home', name='home'), 9 | # url(r'^blog/', include('blog.urls')), 10 | 11 | 12 | url(r'^admin/', include(admin.site.urls)), 13 | 14 | url(r'^$','article.views.home',name="home"),#主页 15 | url(r'^about/$','article.views.about',name="about"),#关于我 16 | url(r'^message/$','article.views.message',name="message"),#留言 17 | url(r'^archive/$','article.views.archive',name="archive"),#归档 18 | url(r'^feed/$', RSSFeed(), name = "RSS"), #新添加的urlconf, 并将name设置为RSS, 方便在模板中使用 19 | url(r'^search/$','article.views.blog_search', name = "search"),#按文章标题搜索 20 | url(r'^article/(?P\d{4})/(?P\d{2})/(?P\d{2})/(?P\d+)/$', 'article.views.detail', name="detail"),#每篇文章 21 | url(r'^article/(?P\d{4})/(?P\d{1,2})/$','article.views.archive_month',name="archive_month"),#按月归档 22 | url(r'^articleClassfi/(?P\w+)/$', 'article.views.classfiDetail', name="classfiDetail"),#每个分类页下面的文章 23 | url(r'^articleTag/(?P\w+)/$', 'article.views.tagDetail', name="tagDetail"),#每个标签页下面的文章 24 | 25 | 26 | 27 | 28 | 29 | 30 | ) 31 | -------------------------------------------------------------------------------- /my_site/urls.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/my_site/urls.pyc -------------------------------------------------------------------------------- /my_site/wsgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | WSGI config for my_site project. 3 | 4 | It exposes the WSGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/1.7/howto/deployment/wsgi/ 8 | """ 9 | 10 | import os 11 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "my_site.settings") 12 | 13 | from django.core.wsgi import get_wsgi_application 14 | application = get_wsgi_application() 15 | -------------------------------------------------------------------------------- /my_site/wsgi.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/my_site/wsgi.pyc -------------------------------------------------------------------------------- /requirement.txt: -------------------------------------------------------------------------------- 1 | bootstrap-admin==0.3.5 2 | Django==1.7.7 3 | django-appconf==1.0.1 4 | django-grappelli==2.6.4 5 | django-staticfiles==1.2.1 6 | pytz==2015.2 7 | six==1.9.0 8 | -------------------------------------------------------------------------------- /static/css/bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/css/bg.jpg -------------------------------------------------------------------------------- /static/css/post.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/css/post.png -------------------------------------------------------------------------------- /static/css/top.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/css/top.png -------------------------------------------------------------------------------- /static/lib/bootstrap/font/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/font/FontAwesome.otf -------------------------------------------------------------------------------- /static/lib/bootstrap/font/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/font/fontawesome-webfont.eot -------------------------------------------------------------------------------- /static/lib/bootstrap/font/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/font/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /static/lib/bootstrap/font/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/font/fontawesome-webfont.woff -------------------------------------------------------------------------------- /static/lib/bootstrap/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /static/lib/bootstrap/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /static/lib/bootstrap/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /static/lib/bootstrap/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/lib/bootstrap/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /static/lib/bootstrap/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /static/lib/jqcloud.css: -------------------------------------------------------------------------------- 1 | /* fonts */ 2 | 3 | div.jqcloud { 4 | font-family: "Helvetica", "Arial", sans-serif; 5 | font-size: 10px; 6 | line-height: normal; 7 | } 8 | 9 | div.jqcloud a { 10 | font-size: inherit; 11 | text-decoration: none; 12 | } 13 | 14 | div.jqcloud span.w10 { font-size: 500%; } 15 | div.jqcloud span.w9 { font-size: 500%; } 16 | div.jqcloud span.w8 { font-size: 450%; } 17 | div.jqcloud span.w7 { font-size: 400%; } 18 | div.jqcloud span.w6 { font-size: 350%; } 19 | div.jqcloud span.w5 { font-size: 300%; } 20 | div.jqcloud span.w4 { font-size: 250%; } 21 | div.jqcloud span.w3 { font-size: 200%; } 22 | div.jqcloud span.w2 { font-size: 200%; } 23 | div.jqcloud span.w1 { font-size: 200%; } 24 | 25 | /* colors */ 26 | div.jqcloud { color: #09f; } 27 | div.jqcloud a { color: inherit; } 28 | div.jqcloud a:hover { color: #0df; } 29 | div.jqcloud a:hover { color: #0cf; } 30 | div.jqcloud span.w10 { color: #0cf; } 31 | div.jqcloud span.w9 { color: #0cf; } 32 | div.jqcloud span.w8 { color: #0cf; } 33 | div.jqcloud span.w7 { color: #39d; } 34 | div.jqcloud span.w6 { color: #90c5f0; } 35 | div.jqcloud span.w5 { color: #90a0dd; } 36 | div.jqcloud span.w4 { color: #90c5f0; } 37 | div.jqcloud span.w3 { color: #a0ddff; } 38 | div.jqcloud span.w2 { color: #99ccee; } 39 | div.jqcloud span.w1 { color: #aab5f0; } 40 | 41 | /* layout */ 42 | 43 | div.jqcloud { 44 | overflow: hidden; 45 | position: relative; 46 | } 47 | 48 | div.jqcloud span { padding: 0; } 49 | -------------------------------------------------------------------------------- /static/lib/monokai.css: -------------------------------------------------------------------------------- 1 | pre{ 2 | background:none; 3 | } 4 | .codehilite pre span{ 5 | line-height:1.4em; 6 | } 7 | .codehilite .hll { background-color: #49483e } 8 | .codehilite { background: #272822; color: #f8f8f2 } 9 | .codehilite .c { color: #75715e } /* Comment */ 10 | .codehilite .err { color: #960050; background-color: #1e0010 } /* Error */ 11 | .codehilite .k { color: #66d9ef } /* Keyword */ 12 | .codehilite .l { color: #ae81ff } /* Literal */ 13 | .codehilite .n { color: #f8f8f2 } /* Name */ 14 | .codehilite .o { color: #f92672 } /* Operator */ 15 | .codehilite .p { color: #f8f8f2 } /* Punctuation */ 16 | .codehilite .cm { color: #75715e } /* Comment.Multiline */ 17 | .codehilite .cp { color: #75715e } /* Comment.Preproc */ 18 | .codehilite .c1 { color: #75715e } /* Comment.Single */ 19 | .codehilite .cs { color: #75715e } /* Comment.Special */ 20 | .codehilite .ge { font-style: italic } /* Generic.Emph */ 21 | .codehilite .gs { font-weight: bold } /* Generic.Strong */ 22 | .codehilite .kc { color: #66d9ef } /* Keyword.Constant */ 23 | .codehilite .kd { color: #66d9ef } /* Keyword.Declaration */ 24 | .codehilite .kn { color: #f92672 } /* Keyword.Namespace */ 25 | .codehilite .kp { color: #66d9ef } /* Keyword.Pseudo */ 26 | .codehilite .kr { color: #66d9ef } /* Keyword.Reserved */ 27 | .codehilite .kt { color: #66d9ef } /* Keyword.Type */ 28 | .codehilite .ld { color: #e6db74 } /* Literal.Date */ 29 | .codehilite .m { color: #ae81ff } /* Literal.Number */ 30 | .codehilite .s { color: #e6db74 } /* Literal.String */ 31 | .codehilite .na { color: #a6e22e } /* Name.Attribute */ 32 | .codehilite .nb { color: #f8f8f2 } /* Name.Builtin */ 33 | .codehilite .nc { color: #a6e22e } /* Name.Class */ 34 | .codehilite .no { color: #66d9ef } /* Name.Constant */ 35 | .codehilite .nd { color: #a6e22e } /* Name.Decorator */ 36 | .codehilite .ni { color: #f8f8f2 } /* Name.Entity */ 37 | .codehilite .ne { color: #a6e22e } /* Name.Exception */ 38 | .codehilite .nf { color: #a6e22e } /* Name.Function */ 39 | .codehilite .nl { color: #f8f8f2 } /* Name.Label */ 40 | .codehilite .nn { color: #f8f8f2 } /* Name.Namespace */ 41 | .codehilite .nx { color: #a6e22e } /* Name.Other */ 42 | .codehilite .py { color: #f8f8f2 } /* Name.Property */ 43 | .codehilite .nt { color: #f92672 } /* Name.Tag */ 44 | .codehilite .nv { color: #f8f8f2 } /* Name.Variable */ 45 | .codehilite .ow { color: #f92672 } /* Operator.Word */ 46 | .codehilite .w { color: #f8f8f2 } /* Text.Whitespace */ 47 | .codehilite .mf { color: #ae81ff } /* Literal.Number.Float */ 48 | .codehilite .mh { color: #ae81ff } /* Literal.Number.Hex */ 49 | .codehilite .mi { color: #ae81ff } /* Literal.Number.Integer */ 50 | .codehilite .mo { color: #ae81ff } /* Literal.Number.Oct */ 51 | .codehilite .sb { color: #e6db74 } /* Literal.String.Backtick */ 52 | .codehilite .sc { color: #e6db74 } /* Literal.String.Char */ 53 | .codehilite .sd { color: #e6db74 } /* Literal.String.Doc */ 54 | .codehilite .s2 { color: #e6db74 } /* Literal.String.Double */ 55 | .codehilite .se { color: #ae81ff } /* Literal.String.Escape */ 56 | .codehilite .sh { color: #e6db74 } /* Literal.String.Heredoc */ 57 | .codehilite .si { color: #e6db74 } /* Literal.String.Interpol */ 58 | .codehilite .sx { color: #e6db74 } /* Literal.String.Other */ 59 | .codehilite .sr { color: #e6db74 } /* Literal.String.Regex */ 60 | .codehilite .s1 { color: #e6db74 } /* Literal.String.Single */ 61 | .codehilite .ss { color: #e6db74 } /* Literal.String.Symbol */ 62 | .codehilite .bp { color: #f8f8f2 } /* Name.Builtin.Pseudo */ 63 | .codehilite .vc { color: #f8f8f2 } /* Name.Variable.Class */ 64 | .codehilite .vg { color: #f8f8f2 } /* Name.Variable.Global */ 65 | .codehilite .vi { color: #f8f8f2 } /* Name.Variable.Instance */ 66 | .codehilite .il { color: #ae81ff } /* Literal.Number.Integer.Long */ 67 | 68 | -------------------------------------------------------------------------------- /static/lib/responsive-nav.css: -------------------------------------------------------------------------------- 1 | /*! responsive-nav.js 1.0.39 by @viljamis */ 2 | 3 | .nav-collapse ul { 4 | margin: 0; 5 | padding: 0; 6 | width: 100%; 7 | display: block; 8 | list-style: none; 9 | } 10 | 11 | .nav-collapse li { 12 | width: 100%; 13 | display: block; 14 | } 15 | 16 | .js .nav-collapse { 17 | clip: rect(0 0 0 0); 18 | max-height: 0; 19 | position: absolute; 20 | display: block; 21 | overflow: hidden; 22 | zoom: 1; 23 | } 24 | 25 | .nav-collapse.opened { 26 | max-height: 9999px; 27 | } 28 | 29 | .nav-toggle { 30 | -webkit-tap-highlight-color: rgba(0,0,0,0); 31 | -webkit-touch-callout: none; 32 | -webkit-user-select: none; 33 | -moz-user-select: none; 34 | -ms-user-select: none; 35 | -o-user-select: none; 36 | user-select: none; 37 | } 38 | 39 | @media screen and (min-width: 760px) { 40 | .js .nav-collapse { 41 | position: relative; 42 | } 43 | .js .nav-collapse.closed { 44 | max-height: none; 45 | } 46 | .nav-toggle { 47 | display: none; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /static/lib/scorllup.js: -------------------------------------------------------------------------------- 1 | /* 2 | scrollUp v1.0.0 3 | Author: Mark Goodyear - http://www.markgoodyear.com 4 | Git: https://github.com/markgoodyear/scrollup 5 | 6 | Copyright 2013 Mark Goodyear 7 | Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php 8 | 9 | Twitter: @markgdyr 10 | */ 11 | 12 | ;(function($){$.scrollUp=function(options){var settings={scrollName:"scrollUp",topDistance:"300",topSpeed:300,animation:"fade",animationInSpeed:200,animationOutSpeed:200,scrollText:" ",activeOverlay:false};if(options)var settings=$.extend(settings,options);var sn="#"+settings.scrollName,an=settings.animation,os=settings.animationOutSpeed,is=settings.animationInSpeed,td=settings.topDistance,st=settings.scrollText,ts=settings.topSpeed,ao=settings.activeOverlay;$("",{id:settings.scrollName, 13 | href:"#top",title:st,text:st}).appendTo("body");$(sn).css({"display":"none","position":"fixed","z-index":"2147483647"});if(ao){$("body").append("
");$(sn+"-active").css({"position":"absolute","top":td+"px","width":"100%","border-top":"1px dotted "+ao,"z-index":"2147483647"})}$(window).scroll(function(){if(an==="fade")$($(window).scrollTop()>td?$(sn).fadeIn(is):$(sn).fadeOut(os));else if(an==="slide")$($(window).scrollTop()>td?$(sn).slideDown(is):$(sn).slideUp(os)); 14 | else $($(window).scrollTop()>td?$(sn).show(0):$(sn).hide(0))});$(sn).click(function(event){$("html, body").animate({scrollTop:0},ts);return false})}})(jQuery); 15 | -------------------------------------------------------------------------------- /static/lib/scripts/shAutoloader.js: -------------------------------------------------------------------------------- 1 | /** 2 | * SyntaxHighlighter 3 | * http://alexgorbatchev.com/SyntaxHighlighter 4 | * 5 | * SyntaxHighlighter is donationware. If you are using it, please donate. 6 | * http://alexgorbatchev.com/SyntaxHighlighter/donate.html 7 | * 8 | * @version 9 | * 3.0.83 (July 02 2010) 10 | * 11 | * @copyright 12 | * Copyright (C) 2004-2010 Alex Gorbatchev. 13 | * 14 | * @license 15 | * Dual licensed under the MIT and GPL licenses. 16 | */ 17 | eval(function(p,a,c,k,e,d){e=function(c){return(c35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('(2(){1 h=5;h.I=2(){2 n(c,a){4(1 d=0;d

/gi,""),b(/<\/p>/gi,"\n"),b(/ |\u00a0/gi," "),b(/"/gi,'"'),b(/</gi,"<"),b(/>/gi,">"),b(/&/gi,"&"),a},_punbb_bbcode2html:function(a){function b(b,c){a=a.replace(b,c)}return a=tinymce.trim(a),b(/\n/gi,"
"),b(/\[b\]/gi,""),b(/\[\/b\]/gi,""),b(/\[i\]/gi,""),b(/\[\/i\]/gi,""),b(/\[u\]/gi,""),b(/\[\/u\]/gi,""),b(/\[url=([^\]]+)\](.*?)\[\/url\]/gi,'
$2'),b(/\[url\](.*?)\[\/url\]/gi,'$1'),b(/\[img\](.*?)\[\/img\]/gi,''),b(/\[color=(.*?)\](.*?)\[\/color\]/gi,'$2'),b(/\[code\](.*?)\[\/code\]/gi,'$1 '),b(/\[quote.*?\](.*?)\[\/quote\]/gi,'$1 '),a}}),tinymce.PluginManager.add("bbcode",tinymce.plugins.BBCodePlugin)}(); -------------------------------------------------------------------------------- /static/tinymce/plugins/code/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("code",function(a){function b(){var b=a.windowManager.open({title:"Source code",body:{type:"textbox",name:"code",multiline:!0,minWidth:a.getParam("code_dialog_width",600),minHeight:a.getParam("code_dialog_height",Math.min(tinymce.DOM.getViewPort().h-200,500)),spellcheck:!1,style:"direction: ltr; text-align: left"},onSubmit:function(b){a.focus(),a.undoManager.transact(function(){a.setContent(b.data.code)}),a.selection.setCursorLocation(),a.nodeChanged()}});b.find("#code").value(a.getContent({source_view:!0}))}a.addCommand("mceCodeEditor",b),a.addButton("code",{icon:"code",tooltip:"Source code",onclick:b}),a.addMenuItem("code",{icon:"code",text:"Source code",context:"tools",onclick:b})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/colorpicker/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("colorpicker",function(a){function b(b,c){function d(a){var b=new tinymce.util.Color(a),c=b.toRgb();f.fromJSON({r:c.r,g:c.g,b:c.b,hex:b.toHex().substr(1)}),e(b.toHex())}function e(a){f.find("#preview")[0].getEl().style.background=a}var f=a.windowManager.open({title:"Color",items:{type:"container",layout:"flex",direction:"row",align:"stretch",padding:5,spacing:10,items:[{type:"colorpicker",value:c,onchange:function(){var a=this.rgb();f&&(f.find("#r").value(a.r),f.find("#g").value(a.g),f.find("#b").value(a.b),f.find("#hex").value(this.value().substr(1)),e(this.value()))}},{type:"form",padding:0,labelGap:5,defaults:{type:"textbox",size:7,value:"0",flex:1,spellcheck:!1,onchange:function(){var a,b,c=f.find("colorpicker")[0];return a=this.name(),b=this.value(),"hex"==a?(b="#"+b,d(b),void c.value(b)):(b={r:f.find("#r").value(),g:f.find("#g").value(),b:f.find("#b").value()},c.value(b),void d(b))}},items:[{name:"r",label:"R",autofocus:1},{name:"g",label:"G"},{name:"b",label:"B"},{name:"hex",label:"#",value:"000000"},{name:"preview",type:"container",border:1}]}]},onSubmit:function(){b("#"+this.toJSON().hex)}});d(c)}a.settings.color_picker_callback||(a.settings.color_picker_callback=b)}); -------------------------------------------------------------------------------- /static/tinymce/plugins/contextmenu/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("contextmenu",function(a){var b,c=a.settings.contextmenu_never_use_native;a.on("contextmenu",function(d){var e,f=a.getDoc();if(!d.ctrlKey||c){if(d.preventDefault(),tinymce.Env.mac&&tinymce.Env.webkit&&2==d.button&&f.caretRangeFromPoint&&a.selection.setRng(f.caretRangeFromPoint(d.x,d.y)),e=a.settings.contextmenu||"link image inserttable | cell row column deletetable",b)b.show();else{var g=[];tinymce.each(e.split(/[ ,]/),function(b){var c=a.menuItems[b];"|"==b&&(c={text:b}),c&&(c.shortcut="",g.push(c))});for(var h=0;h'}),a+=""}),a+=""}var d=[["cool","cry","embarassed","foot-in-mouth"],["frown","innocent","kiss","laughing"],["money-mouth","sealed","smile","surprised"],["tongue-out","undecided","wink","yell"]];a.addButton("emoticons",{type:"panelbutton",panel:{role:"application",autohide:!0,html:c,onclick:function(b){var c=a.dom.getParent(b.target,"a");c&&(a.insertContent(''+c.getAttribute('),this.hide())}},tooltip:"Emoticons"})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/example/dialog.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |

Custom dialog

5 | Input some text: 6 | 7 | 8 | -------------------------------------------------------------------------------- /static/tinymce/plugins/example/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("example",function(a,b){a.addButton("example",{text:"My button",icon:!1,onclick:function(){a.windowManager.open({title:"Example plugin",body:[{type:"textbox",name:"title",label:"Title"}],onsubmit:function(b){a.insertContent("Title: "+b.data.title)}})}}),a.addMenuItem("example",{text:"Example plugin",context:"tools",onclick:function(){a.windowManager.open({title:"TinyMCE site",url:b+"/dialog.html",width:600,height:400,buttons:[{text:"Insert",onclick:function(){var b=a.windowManager.getWindows()[0];a.insertContent(b.getContentWindow().document.getElementById("content").value),b.close()}},{text:"Close",onclick:"close"}]})}})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/example_dependency/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("example_dependency",function(){},["example"]); -------------------------------------------------------------------------------- /static/tinymce/plugins/fullpage/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("fullpage",function(a){function b(){var b=c();a.windowManager.open({title:"Document properties",data:b,defaults:{type:"textbox",size:40},body:[{name:"title",label:"Title"},{name:"keywords",label:"Keywords"},{name:"description",label:"Description"},{name:"robots",label:"Robots"},{name:"author",label:"Author"},{name:"docencoding",label:"Encoding"}],onSubmit:function(a){d(tinymce.extend(b,a.data))}})}function c(){function b(a,b){var c=a.attr(b);return c||""}var c,d,f=e(),g={};return g.fontface=a.getParam("fullpage_default_fontface",""),g.fontsize=a.getParam("fullpage_default_fontsize",""),c=f.firstChild,7==c.type&&(g.xml_pi=!0,d=/encoding="([^"]+)"/.exec(c.value),d&&(g.docencoding=d[1])),c=f.getAll("#doctype")[0],c&&(g.doctype=""),c=f.getAll("title")[0],c&&c.firstChild&&(g.title=c.firstChild.value),k(f.getAll("meta"),function(a){var b,c=a.attr("name"),d=a.attr("http-equiv");c?g[c.toLowerCase()]=a.attr("content"):"Content-Type"==d&&(b=/charset\s*=\s*(.*)\s*/gi.exec(a.attr("content")),b&&(g.docencoding=b[1]))}),c=f.getAll("html")[0],c&&(g.langcode=b(c,"lang")||b(c,"xml:lang")),g.stylesheets=[],tinymce.each(f.getAll("link"),function(a){"stylesheet"==a.attr("rel")&&g.stylesheets.push(a.attr("href"))}),c=f.getAll("body")[0],c&&(g.langdir=b(c,"dir"),g.style=b(c,"style"),g.visited_color=b(c,"vlink"),g.link_color=b(c,"link"),g.active_color=b(c,"alink")),g}function d(b){function c(a,b,c){a.attr(b,c?c:void 0)}function d(a){g.firstChild?g.insert(a,g.firstChild):g.append(a)}var f,g,h,j,m,n=a.dom;f=e(),g=f.getAll("head")[0],g||(j=f.getAll("html")[0],g=new l("head",1),j.firstChild?j.insert(g,j.firstChild,!0):j.append(g)),j=f.firstChild,b.xml_pi?(m='version="1.0"',b.docencoding&&(m+=' encoding="'+b.docencoding+'"'),7!=j.type&&(j=new l("xml",7),f.insert(j,f.firstChild,!0)),j.value=m):j&&7==j.type&&j.remove(),j=f.getAll("#doctype")[0],b.doctype?(j||(j=new l("#doctype",10),b.xml_pi?f.insert(j,f.firstChild):d(j)),j.value=b.doctype.substring(9,b.doctype.length-1)):j&&j.remove(),j=null,k(f.getAll("meta"),function(a){"Content-Type"==a.attr("http-equiv")&&(j=a)}),b.docencoding?(j||(j=new l("meta",1),j.attr("http-equiv","Content-Type"),j.shortEnded=!0,d(j)),j.attr("content","text/html; charset="+b.docencoding)):j&&j.remove(),j=f.getAll("title")[0],b.title?(j?j.empty():(j=new l("title",1),d(j)),j.append(new l("#text",3)).value=b.title):j&&j.remove(),k("keywords,description,author,copyright,robots".split(","),function(a){var c,e,g=f.getAll("meta"),h=b[a];for(c=0;c"))}function e(){return new tinymce.html.DomParser({validate:!1,root_name:"#document"}).parse(i)}function f(b){function c(a){return a.replace(/<\/?[A-Z]+/g,function(a){return a.toLowerCase()})}var d,f,h,l,m=b.content,n="",o=a.dom;if(!b.selection&&!("raw"==b.format&&i||b.source_view&&a.getParam("fullpage_hide_in_source_view"))){0!==m.length||b.source_view||(m=tinymce.trim(i)+"\n"+tinymce.trim(m)+"\n"+tinymce.trim(j)),m=m.replace(/<(\/?)BODY/gi,"<$1body"),d=m.indexOf("",d),i=c(m.substring(0,d+1)),f=m.indexOf("\n"),h=e(),k(h.getAll("style"),function(a){a.firstChild&&(n+=a.firstChild.value)}),l=h.getAll("body")[0],l&&o.setAttribs(a.getBody(),{style:l.attr("style")||"",dir:l.attr("dir")||"",vLink:l.attr("vlink")||"",link:l.attr("link")||"",aLink:l.attr("alink")||""}),o.remove("fullpage_styles");var p=a.getDoc().getElementsByTagName("head")[0];n&&(o.add(p,"style",{id:"fullpage_styles"},n),l=o.get("fullpage_styles"),l.styleSheet&&(l.styleSheet.cssText=n));var q={};tinymce.each(p.getElementsByTagName("link"),function(a){"stylesheet"==a.rel&&a.getAttribute("data-mce-fullpage")&&(q[a.href]=a)}),tinymce.each(h.getAll("link"),function(a){var b=a.attr("href");q[b]||"stylesheet"!=a.attr("rel")||o.add(p,"link",{rel:"stylesheet",text:"text/css",href:b,"data-mce-fullpage":"1"}),delete q[b]}),tinymce.each(q,function(a){a.parentNode.removeChild(a)})}}function g(){var b,c="",d="";return a.getParam("fullpage_default_xml_pi")&&(c+='\n'),c+=a.getParam("fullpage_default_doctype",""),c+="\n\n\n",(b=a.getParam("fullpage_default_title"))&&(c+=""+b+"\n"),(b=a.getParam("fullpage_default_encoding"))&&(c+='\n'),(b=a.getParam("fullpage_default_font_family"))&&(d+="font-family: "+b+";"),(b=a.getParam("fullpage_default_font_size"))&&(d+="font-size: "+b+";"),(b=a.getParam("fullpage_default_text_color"))&&(d+="color: "+b+";"),c+="\n\n"}function h(b){b.selection||b.source_view&&a.getParam("fullpage_hide_in_source_view")||(b.content=tinymce.trim(i)+"\n"+tinymce.trim(b.content)+"\n"+tinymce.trim(j))}var i,j,k=tinymce.each,l=tinymce.html.Node;a.addCommand("mceFullPageProperties",b),a.addButton("fullpage",{title:"Document properties",cmd:"mceFullPageProperties"}),a.addMenuItem("fullpage",{text:"Document properties",cmd:"mceFullPageProperties",context:"file"}),a.on("BeforeSetContent",f),a.on("GetContent",h)}); -------------------------------------------------------------------------------- /static/tinymce/plugins/fullscreen/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("fullscreen",function(a){function b(){var a,b,c=window,d=document,e=d.body;return e.offsetWidth&&(a=e.offsetWidth,b=e.offsetHeight),c.innerWidth&&c.innerHeight&&(a=c.innerWidth,b=c.innerHeight),{w:a,h:b}}function c(){function c(){j.setStyle(m,"height",b().h-(l.clientHeight-m.clientHeight))}var k,l,m,n,o=document.body,p=document.documentElement;i=!i,l=a.getContainer(),k=l.style,m=a.getContentAreaContainer().firstChild,n=m.style,i?(d=n.width,e=n.height,n.width=n.height="100%",g=k.width,h=k.height,k.width=k.height="",j.addClass(o,"mce-fullscreen"),j.addClass(p,"mce-fullscreen"),j.addClass(l,"mce-fullscreen"),j.bind(window,"resize",c),c(),f=c):(n.width=d,n.height=e,g&&(k.width=g),h&&(k.height=h),j.removeClass(o,"mce-fullscreen"),j.removeClass(p,"mce-fullscreen"),j.removeClass(l,"mce-fullscreen"),j.unbind(window,"resize",f)),a.fire("FullscreenStateChanged",{state:i})}var d,e,f,g,h,i=!1,j=tinymce.DOM;return a.settings.inline?void 0:(a.on("init",function(){a.addShortcut("Meta+Alt+F","",c)}),a.on("remove",function(){f&&j.unbind(window,"resize",f)}),a.addCommand("mceFullScreen",c),a.addMenuItem("fullscreen",{text:"Fullscreen",shortcut:"Meta+Alt+F",selectable:!0,onClick:c,onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})},context:"view"}),a.addButton("fullscreen",{tooltip:"Fullscreen",shortcut:"Meta+Alt+F",onClick:c,onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})}}),{isFullscreen:function(){return i}})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/hr/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("hr",function(a){a.addCommand("InsertHorizontalRule",function(){a.execCommand("mceInsertContent",!1,"
")}),a.addButton("hr",{icon:"hr",tooltip:"Horizontal line",cmd:"InsertHorizontalRule"}),a.addMenuItem("hr",{icon:"hr",text:"Horizontal line",cmd:"InsertHorizontalRule",context:"insert"})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/importcss/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("importcss",function(a){function b(a){return"string"==typeof a?function(b){return-1!==b.indexOf(a)}:a instanceof RegExp?function(b){return a.test(b)}:a}function c(b,c){function d(a,b){var g,h=a.href;if(h&&c(h,b)){f(a.imports,function(a){d(a,!0)});try{g=a.cssRules||a.rules}catch(i){}f(g,function(a){a.styleSheet?d(a.styleSheet,!0):a.selectorText&&f(a.selectorText.split(","),function(a){e.push(tinymce.trim(a))})})}}var e=[],g={};f(a.contentCSS,function(a){g[a]=!0}),c||(c=function(a,b){return b||g[a]});try{f(b.styleSheets,function(a){d(a)})}catch(h){}return e}function d(b){var c,d=/^(?:([a-z0-9\-_]+))?(\.[a-z0-9_\-\.]+)$/i.exec(b);if(d){var e=d[1],f=d[2].substr(1).split(".").join(" "),g=tinymce.makeMap("a,img");return d[1]?(c={title:b},a.schema.getTextBlockElements()[e]?c.block=e:a.schema.getBlockElements()[e]||g[e.toLowerCase()]?c.selector=e:c.inline=e):d[2]&&(c={inline:"span",title:b.substr(1),classes:f}),a.settings.importcss_merge_classes!==!1?c.classes=f:c.attributes={"class":f},c}}var e=this,f=tinymce.each;a.on("renderFormatsMenu",function(g){var h=a.settings,i={},j=h.importcss_selector_converter||d,k=b(h.importcss_selector_filter),l=g.control;a.settings.importcss_append||l.items().remove();var m=[];tinymce.each(h.importcss_groups,function(a){a=tinymce.extend({},a),a.filter=b(a.filter),m.push(a)}),f(c(g.doc||a.getDoc(),b(h.importcss_file_filter)),function(b){if(-1===b.indexOf(".mce-")&&!i[b]&&(!k||k(b))){var c,d=j.call(e,b);if(d){var f=d.name||tinymce.DOM.uniqueId();if(m)for(var g=0;g'+d+"";var f=a.dom.getParent(a.selection.getStart(),"time");if(f)return void a.dom.setOuterHTML(f,d)}a.insertContent(d)}var d,e,f="Sun Mon Tue Wed Thu Fri Sat Sun".split(" "),g="Sunday Monday Tuesday Wednesday Thursday Friday Saturday Sunday".split(" "),h="Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" "),i="January February March April May June July August September October November December".split(" "),j=[];a.addCommand("mceInsertDate",function(){c(a.getParam("insertdatetime_dateformat",a.translate("%Y-%m-%d")))}),a.addCommand("mceInsertTime",function(){c(a.getParam("insertdatetime_timeformat",a.translate("%H:%M:%S")))}),a.addButton("insertdatetime",{type:"splitbutton",title:"Insert date/time",onclick:function(){c(d||e)},menu:j}),tinymce.each(a.settings.insertdatetime_formats||["%H:%M:%S","%Y-%m-%d","%I:%M:%S %p","%D"],function(a){e||(e=a),j.push({text:b(a),onclick:function(){d=a,c(a)}})}),a.addMenuItem("insertdatetime",{icon:"date",text:"Insert date/time",menu:j,context:"insert"})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/layer/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("layer",function(a){function b(a){do if(a.className&&-1!=a.className.indexOf("mceItemLayer"))return a;while(a=a.parentNode)}function c(b){var c=a.dom;tinymce.each(c.select("div,p",b),function(a){/^(absolute|relative|fixed)$/i.test(a.style.position)&&(a.hasVisual?c.addClass(a,"mceItemVisualAid"):c.removeClass(a,"mceItemVisualAid"),c.addClass(a,"mceItemLayer"))})}function d(c){var d,e,f=[],g=b(a.selection.getNode()),h=-1,i=-1;for(e=[],tinymce.walk(a.getBody(),function(a){1==a.nodeType&&/^(absolute|relative|static)$/i.test(a.style.position)&&e.push(a)},"childNodes"),d=0;dh&&e[d]==g&&(h=d);if(0>c){for(d=0;d-1?(e[h].style.zIndex=f[i],e[i].style.zIndex=f[h]):f[h]>0&&(e[h].style.zIndex=f[h]-1)}else{for(d=0;df[h]){i=d;break}i>-1?(e[h].style.zIndex=f[i],e[i].style.zIndex=f[h]):e[h].style.zIndex=f[h]+1}a.execCommand("mceRepaint")}function e(){var b=a.dom,c=b.getPos(b.getParent(a.selection.getNode(),"*")),d=a.getBody();a.dom.add(d,"div",{style:{position:"absolute",left:c.x,top:c.y>20?c.y:20,width:100,height:100},"class":"mceItemVisualAid mceItemLayer"},a.selection.getContent()||a.getLang("layer.content")),tinymce.Env.ie&&b.setHTML(d,d.innerHTML)}function f(){var c=b(a.selection.getNode());c||(c=a.dom.getParent(a.selection.getNode(),"DIV,P,IMG")),c&&("absolute"==c.style.position.toLowerCase()?(a.dom.setStyles(c,{position:"",left:"",top:"",width:"",height:""}),a.dom.removeClass(c,"mceItemVisualAid"),a.dom.removeClass(c,"mceItemLayer")):(c.style.left||(c.style.left="20px"),c.style.top||(c.style.top="20px"),c.style.width||(c.style.width=c.width?c.width+"px":"100px"),c.style.height||(c.style.height=c.height?c.height+"px":"100px"),c.style.position="absolute",a.dom.setAttrib(c,"data-mce-style",""),a.addVisual(a.getBody())),a.execCommand("mceRepaint"),a.nodeChanged())}a.addCommand("mceInsertLayer",e),a.addCommand("mceMoveForward",function(){d(1)}),a.addCommand("mceMoveBackward",function(){d(-1)}),a.addCommand("mceMakeAbsolute",function(){f()}),a.addButton("moveforward",{title:"layer.forward_desc",cmd:"mceMoveForward"}),a.addButton("movebackward",{title:"layer.backward_desc",cmd:"mceMoveBackward"}),a.addButton("absolute",{title:"layer.absolute_desc",cmd:"mceMakeAbsolute"}),a.addButton("insertlayer",{title:"layer.insertlayer_desc",cmd:"mceInsertLayer"}),a.on("init",function(){tinymce.Env.ie&&a.getDoc().execCommand("2D-Position",!1,!0)}),a.on("mouseup",function(c){var d=b(c.target);d&&a.dom.setAttrib(d,"data-mce-style","")}),a.on("mousedown",function(c){var d,e=c.target,f=a.getDoc();tinymce.Env.gecko&&(b(e)?"on"!==f.designMode&&(f.designMode="on",e=f.body,d=e.parentNode,d.removeChild(e),d.appendChild(e)):"on"==f.designMode&&(f.designMode="off"))}),a.on("NodeChange",c)}); -------------------------------------------------------------------------------- /static/tinymce/plugins/legacyoutput/plugin.min.js: -------------------------------------------------------------------------------- 1 | !function(a){a.on("AddEditor",function(a){a.editor.settings.inline_styles=!1}),a.PluginManager.add("legacyoutput",function(b,c,d){b.on("init",function(){var c="p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img",d=a.explode(b.settings.font_size_style_values),e=b.schema;b.formatter.register({alignleft:{selector:c,attributes:{align:"left"}},aligncenter:{selector:c,attributes:{align:"center"}},alignright:{selector:c,attributes:{align:"right"}},alignjustify:{selector:c,attributes:{align:"justify"}},bold:[{inline:"b",remove:"all"},{inline:"strong",remove:"all"},{inline:"span",styles:{fontWeight:"bold"}}],italic:[{inline:"i",remove:"all"},{inline:"em",remove:"all"},{inline:"span",styles:{fontStyle:"italic"}}],underline:[{inline:"u",remove:"all"},{inline:"span",styles:{textDecoration:"underline"},exact:!0}],strikethrough:[{inline:"strike",remove:"all"},{inline:"span",styles:{textDecoration:"line-through"},exact:!0}],fontname:{inline:"font",attributes:{face:"%value"}},fontsize:{inline:"font",attributes:{size:function(b){return a.inArray(d,b.value)+1}}},forecolor:{inline:"font",attributes:{color:"%value"}},hilitecolor:{inline:"font",styles:{backgroundColor:"%value"}}}),a.each("b,i,u,strike".split(","),function(a){e.addValidElements(a+"[*]")}),e.getElementRule("font")||e.addValidElements("font[face|size|color|style]"),a.each(c.split(","),function(a){var b=e.getElementRule(a);b&&(b.attributes.align||(b.attributes.align={},b.attributesOrder.push("align")))})}),b.addButton("fontsizeselect",function(){var a=[],c="8pt=1 10pt=2 12pt=3 14pt=4 18pt=5 24pt=6 36pt=7",d=b.settings.fontsize_formats||c;return b.$.each(d.split(" "),function(b,c){var d=c,e=c,f=c.split("=");f.length>1&&(d=f[0],e=f[1]),a.push({text:d,value:e})}),{type:"listbox",text:"Font Sizes",tooltip:"Font Sizes",values:a,fixedWidth:!0,onPostRender:function(){var a=this;b.on("NodeChange",function(){var c;c=b.dom.getParent(b.selection.getNode(),"font"),a.value(c?c.size:"")})},onclick:function(a){a.control.settings.value&&b.execCommand("FontSize",!1,a.control.settings.value)}}}),b.addButton("fontselect",function(){function a(a){a=a.replace(/;$/,"").split(";");for(var b=a.length;b--;)a[b]=a[b].split("=");return a}var c="Andale Mono=andale mono,monospace;Arial=arial,helvetica,sans-serif;Arial Black=arial black,sans-serif;Book Antiqua=book antiqua,palatino,serif;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier,monospace;Georgia=georgia,palatino,serif;Helvetica=helvetica,arial,sans-serif;Impact=impact,sans-serif;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco,monospace;Times New Roman=times new roman,times,serif;Trebuchet MS=trebuchet ms,geneva,sans-serif;Verdana=verdana,geneva,sans-serif;Webdings=webdings;Wingdings=wingdings,zapf dingbats",e=[],f=a(b.settings.font_formats||c);return d.each(f,function(a,b){e.push({text:{raw:b[0]},value:b[1],textStyle:-1==b[1].indexOf("dings")?"font-family:"+b[1]:""})}),{type:"listbox",text:"Font Family",tooltip:"Font Family",values:e,fixedWidth:!0,onPostRender:function(){var a=this;b.on("NodeChange",function(){var c;c=b.dom.getParent(b.selection.getNode(),"font"),a.value(c?c.face:"")})},onselect:function(a){a.control.settings.value&&b.execCommand("FontName",!1,a.control.settings.value)}}})})}(tinymce); -------------------------------------------------------------------------------- /static/tinymce/plugins/link/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("link",function(a){function b(b){return function(){var c=a.settings.link_list;"string"==typeof c?tinymce.util.XHR.send({url:c,success:function(a){b(tinymce.util.JSON.parse(a))}}):"function"==typeof c?c(b):b(c)}}function c(a,b,c){function d(a,c){return c=c||[],tinymce.each(a,function(a){var e={text:a.text||a.title};a.menu?e.menu=d(a.menu):(e.value=a.value,b&&b(e)),c.push(e)}),c}return d(a,c||[])}function d(b){function d(a){var b=l.find("#text");(!b.value()||a.lastControl&&b.value()==a.lastControl.text())&&b.value(a.control.text()),l.find("#href").value(a.control.value())}function e(b){var c=[];return tinymce.each(a.dom.select("a:not([href])"),function(a){var d=a.name||a.id;d&&c.push({text:d,value:"#"+d,selected:-1!=b.indexOf("#"+d)})}),c.length?(c.unshift({text:"None",value:""}),{name:"anchor",type:"listbox",label:"Anchors",values:c,onselect:d}):void 0}function f(){!k&&0===u.text.length&&m&&this.parent().parent().find("#text")[0].value(this.value())}function g(b){var c=b.meta||{};o&&o.value(a.convertURL(this.value(),"href")),tinymce.each(b.meta,function(a,b){l.find("#"+b).value(a)}),c.text||f.call(this)}function h(a){var b=v.getContent();if(/]+>[^<]+<\/a>$/.test(b)||-1==b.indexOf("href=")))return!1;if(a){var c,d=a.childNodes;if(0===d.length)return!1;for(c=d.length-1;c>=0;c--)if(3!=d[c].nodeType)return!1}return!0}var i,j,k,l,m,n,o,p,q,r,s,t,u={},v=a.selection,w=a.dom;i=v.getNode(),j=w.getParent(i,"a[href]"),m=h(),u.text=k=j?j.innerText||j.textContent:v.getContent({format:"text"}),u.href=j?w.getAttrib(j,"href"):"",j?u.target=w.getAttrib(j,"target"):a.settings.default_link_target&&(u.target=a.settings.default_link_target),(t=w.getAttrib(j,"rel"))&&(u.rel=t),(t=w.getAttrib(j,"class"))&&(u["class"]=t),(t=w.getAttrib(j,"title"))&&(u.title=t),m&&(n={name:"text",type:"textbox",size:40,label:"Text to display",onchange:function(){u.text=this.value()}}),b&&(o={type:"listbox",label:"Link list",values:c(b,function(b){b.value=a.convertURL(b.value||b.url,"href")},[{text:"None",value:""}]),onselect:d,value:a.convertURL(u.href,"href"),onPostRender:function(){o=this}}),a.settings.target_list!==!1&&(a.settings.target_list||(a.settings.target_list=[{text:"None",value:""},{text:"New window",value:"_blank"}]),q={name:"target",type:"listbox",label:"Target",values:c(a.settings.target_list)}),a.settings.rel_list&&(p={name:"rel",type:"listbox",label:"Rel",values:c(a.settings.rel_list)}),a.settings.link_class_list&&(r={name:"class",type:"listbox",label:"Class",values:c(a.settings.link_class_list,function(b){b.value&&(b.textStyle=function(){return a.formatter.getCssText({inline:"a",classes:[b.value]})})})}),a.settings.link_title!==!1&&(s={name:"title",type:"textbox",label:"Title",value:u.title}),l=a.windowManager.open({title:"Insert link",data:u,body:[{name:"href",type:"filepicker",filetype:"file",size:40,autofocus:!0,label:"Url",onchange:g,onkeyup:f},n,s,e(u.href),o,p,q,r],onSubmit:function(b){function c(b,c){var d=a.selection.getRng();window.setTimeout(function(){a.windowManager.confirm(b,function(b){a.selection.setRng(d),c(b)})},0)}function d(){var b={href:e,target:u.target?u.target:null,rel:u.rel?u.rel:null,"class":u["class"]?u["class"]:null,title:u.title?u.title:null};j?(a.focus(),m&&u.text!=k&&("innerText"in j?j.innerText=u.text:j.textContent=u.text),w.setAttribs(j,b),v.select(j),a.undoManager.add()):m?a.insertContent(w.createHTML("a",b,w.encode(u.text))):a.execCommand("mceInsertLink",!1,b)}var e;return u=tinymce.extend(u,b.data),(e=u.href)?e.indexOf("@")>0&&-1==e.indexOf("//")&&-1==e.indexOf("mailto:")?void c("The URL you entered seems to be an email address. Do you want to add the required mailto: prefix?",function(a){a&&(e="mailto:"+e),d()}):a.settings.link_assume_external_targets&&!/^\w+:/i.test(e)||!a.settings.link_assume_external_targets&&/^\s*www\./i.test(e)?void c("The URL you entered seems to be an external link. Do you want to add the required http:// prefix?",function(a){a&&(e="http://"+e),d()}):void d():void a.execCommand("unlink")}})}a.addButton("link",{icon:"link",tooltip:"Insert/edit link",shortcut:"Meta+K",onclick:b(d),stateSelector:"a[href]"}),a.addButton("unlink",{icon:"unlink",tooltip:"Remove link",cmd:"unlink",stateSelector:"a[href]"}),a.addShortcut("Meta+K","",b(d)),a.addCommand("mceLink",b(d)),this.showDialog=d,a.addMenuItem("link",{icon:"link",text:"Insert/edit link",shortcut:"Meta+K",onclick:b(d),stateSelector:"a[href]",context:"insert",prependToContext:!0})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/media/moxieplayer.swf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/plugins/media/moxieplayer.swf -------------------------------------------------------------------------------- /static/tinymce/plugins/nonbreaking/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("nonbreaking",function(a){var b=a.getParam("nonbreaking_force_tab");if(a.addCommand("mceNonBreaking",function(){a.insertContent(a.plugins.visualchars&&a.plugins.visualchars.state?' ':" "),a.dom.setAttrib(a.dom.select("span.mce-nbsp"),"data-mce-bogus","1")}),a.addButton("nonbreaking",{title:"Nonbreaking space",cmd:"mceNonBreaking"}),a.addMenuItem("nonbreaking",{text:"Nonbreaking space",cmd:"mceNonBreaking",context:"insert"}),b){var c=+b>1?+b:3;a.on("keydown",function(b){if(9==b.keyCode){if(b.shiftKey)return;b.preventDefault();for(var d=0;c>d;d++)a.execCommand("mceNonBreaking")}})}}); -------------------------------------------------------------------------------- /static/tinymce/plugins/noneditable/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("noneditable",function(a){function b(a){var b;if(1===a.nodeType){if(b=a.getAttribute(k),b&&"inherit"!==b)return b;if(b=a.contentEditable,"inherit"!==b)return b}return null}function c(a){for(var c;a;){if(c=b(a))return"false"===c?a:null;a=a.parentNode}}function d(){function d(a){for(;a;){if(a.id===n)return a;a=a.parentNode}}function e(a){var b;if(a)for(b=new i(a,a),a=b.current();a;a=b.next())if(3===a.nodeType)return a}function f(c,d){var e,f;return"false"===b(c)&&k.isBlock(c)?void m.select(c):(f=k.createRng(),"true"===b(c)&&(c.firstChild||c.appendChild(a.getDoc().createTextNode("\xa0")),c=c.firstChild,d=!0),e=k.create("span",{id:n,"data-mce-bogus":!0},o),d?c.parentNode.insertBefore(e,c):k.insertAfter(e,c),f.setStart(e.firstChild,1),f.collapse(!0),m.setRng(f),e)}function g(a){var b,c,d;if(a)b=m.getRng(!0),b.setStartBefore(a),b.setEndBefore(a),c=e(a),c&&c.nodeValue.charAt(0)==o&&(c=c.deleteData(0,1)),k.remove(a,!0),m.setRng(b);else for(;(a=k.get(n))&&a!==d;)c=e(a),c&&c.nodeValue.charAt(0)==o&&(c=c.deleteData(0,1)),k.remove(a,!0),d=a}function h(){function a(a,c){var d,e,f,g,h;if(d=j.startContainer,e=j.startOffset,3==d.nodeType){if(h=d.nodeValue.length,e>0&&h>e||(c?e==h:0===e))return}else{if(!(e0?e-1:e;d=d.childNodes[k],d.hasChildNodes()&&(d=d.firstChild)}for(f=new i(d,a);g=f[c?"prev":"next"]();){if(3===g.nodeType&&g.nodeValue.length>0)return;if("true"===b(g))return g}return a}var d,e,h,j,k;g(),h=m.isCollapsed(),d=c(m.getStart()),e=c(m.getEnd()),(d||e)&&(j=m.getRng(!0),h?(d=d||e,(k=a(d,!0))?f(k,!0):(k=a(d,!1))?f(k,!1):m.select(d)):(j=m.getRng(!0),d&&j.setStartBefore(d),e&&j.setEndAfter(e),m.setRng(j)))}function j(e){function f(a,b){for(;a=a[b?"previousSibling":"nextSibling"];)if(3!==a.nodeType||a.nodeValue.length>0)return a}function j(a,b){m.select(a),m.collapse(b)}function n(e){function f(a){for(var b=j;b;){if(b===a)return;b=b.parentNode}k.remove(a),h()}function g(){var d,g,h=a.schema.getNonEmptyElements();for(g=new tinymce.dom.TreeWalker(j,a.getBody());(d=e?g.prev():g.next())&&!h[d.nodeName.toLowerCase()]&&!(3===d.nodeType&&tinymce.trim(d.nodeValue).length>0);)if("false"===b(d))return f(d),!0;return c(d)?!0:!1}var i,j,l,n;if(m.isCollapsed()){if(i=m.getRng(!0),j=i.startContainer,l=i.startOffset,j=d(j)||j,n=c(j))return f(n),!1;if(3==j.nodeType&&(e?l>0:ls||s>124)&&s!=l.DELETE&&s!=l.BACKSPACE){if((tinymce.isMac?e.metaKey:e.ctrlKey)&&(67==s||88==s||86==s))return;if(e.preventDefault(),u)if(a.dom.isBlock(o)){var w=v?o.previousSibling:o.nextSibling;if(!w||w&&"false"===b(w)){var x=k.create("p",null," ");x.className="mceTmpParagraph";var y=v?o:w;y&&y.parentNode?y.parentNode.insertBefore(x,y):w||v||o.parentNode.appendChild(x),w=x}var z=new i(w,w),A=v?z.prev():z.next();j(A,!v)}else j(o,v)}else if(u||s==l.BACKSPACE||s==l.DELETE){if(p=d(q)){if(s==l.LEFT||s==l.BACKSPACE)if(o=f(p,!0),o&&"false"===b(o)){if(e.preventDefault(),s!=l.LEFT)return void k.remove(o);j(o,!0)}else g(p);if(s==l.RIGHT||s==l.DELETE)if(o=f(p,!0),o&&"false"===b(o)){if(e.preventDefault(),s!=l.RIGHT)return void k.remove(o);j(o,!1)}else g(p)}else{if(u&&t&&-1!==t.className.indexOf("mceTmpParagraph")&&t[v?"previousSibling":"nextSibling"]){var B=t[v?"previousSibling":"nextSibling"];" "===t.innerHTML||""===t.innerHTML||" "===t.innerHTML?k.remove(t):t.className=t.className.replace("mceTmpParagraph",""),j(B,!v)}var C=m.getRng(!0),D=C.endContainer;if(k.isBlock(D)&&k.isBlock(D.nextSibling)&&1==C.endOffset&&s==l.DELETE&&(o=c(D.nextSibling)),o&&(s==l.DELETE||s==l.BACKSPACE)&&k.isBlock(o))return e.preventDefault(),void k.remove(o)}if((s==l.BACKSPACE||s==l.DELETE)&&!n(s==l.BACKSPACE))return e.preventDefault(),!1}}var k=a.dom,m=a.selection,n="mce_noneditablecaret",o="\ufeff";a.on("mousedown",function(c){var d=a.selection.getNode();d&&-1!==d.className.indexOf("mceTmpParagraph")&&d!==c.target&&(" "===d.innerHTML||""===d.innerHTML||" "===d.innerHTML?k.remove(d):d.className=d.className.replace("mceTmpParagraph","")),"false"===b(d)&&d==c.target&&h()}),a.on("mouseup",h),a.on("keydown",j)}function e(b){var c=h.length,d=b.content,e=tinymce.trim(g);if("raw"!=b.format){for(;c--;)d=d.replace(h[c],function(b){var c=arguments,f=c[c.length-2];return f>0&&'"'==d.charAt(f-1)?b:''+a.dom.encode("string"==typeof c[1]?c[1]:c[0])+""});b.content=d}}var f,g,h,i=tinymce.dom.TreeWalker,j="contenteditable",k="data-mce-"+j,l=tinymce.util.VK;f=" "+tinymce.trim(a.getParam("noneditable_editable_class","mceEditable"))+" ",g=" "+tinymce.trim(a.getParam("noneditable_noneditable_class","mceNonEditable"))+" ",h=a.getParam("noneditable_regexp"),h&&!h.length&&(h=[h]),a.on("PreInit",function(){d(),h&&a.on("BeforeSetContent",e),a.parser.addAttributeFilter("class",function(a){for(var b,c,d=a.length;d--;)c=a[d],b=" "+c.attr("class")+" ",-1!==b.indexOf(f)?c.attr(k,"true"):-1!==b.indexOf(g)&&c.attr(k,"false")}),a.serializer.addAttributeFilter(k,function(a){for(var b,c=a.length;c--;)b=a[c],h&&b.attr("data-mce-content")?(b.name="#text",b.type=3,b.raw=!0,b.value=b.attr("data-mce-content")):(b.attr(j,null),b.attr(k,null))}),a.parser.addAttributeFilter(j,function(a){for(var b,c=a.length;c--;)b=a[c],b.attr(k,b.attr(j)),b.attr(j,null)})}),a.on("drop",function(a){c(a.target)&&a.preventDefault()})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/pagebreak/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("pagebreak",function(a){var b="mce-pagebreak",c=a.getParam("pagebreak_separator",""),d=new RegExp(c.replace(/[\?\.\*\[\]\(\)\{\}\+\^\$\:]/g,function(a){return"\\"+a}),"gi"),e='';a.addCommand("mcePageBreak",function(){a.insertContent(a.settings.pagebreak_split_block?"

"+e+"

":e)}),a.addButton("pagebreak",{title:"Page break",cmd:"mcePageBreak"}),a.addMenuItem("pagebreak",{text:"Page break",icon:"pagebreak",cmd:"mcePageBreak",context:"insert"}),a.on("ResolveName",function(c){"IMG"==c.target.nodeName&&a.dom.hasClass(c.target,b)&&(c.name="pagebreak")}),a.on("click",function(c){c=c.target,"IMG"===c.nodeName&&a.dom.hasClass(c,b)&&a.selection.select(c)}),a.on("BeforeSetContent",function(a){a.content=a.content.replace(d,e)}),a.on("PreInit",function(){a.serializer.addNodeFilter("img",function(b){for(var d,e,f=b.length;f--;)if(d=b[f],e=d.attr("class"),e&&-1!==e.indexOf("mce-pagebreak")){var g=d.parent;if(a.schema.getBlockElements()[g.name]&&a.settings.pagebreak_split_block){g.type=3,g.value=c,g.raw=!0,d.remove();continue}d.type=3,d.value=c,d.raw=!0}})})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/preview/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("preview",function(a){var b=a.settings,c=!tinymce.Env.ie;a.addCommand("mcePreview",function(){a.windowManager.open({title:"Preview",width:parseInt(a.getParam("plugin_preview_width","650"),10),height:parseInt(a.getParam("plugin_preview_height","500"),10),html:'",buttons:{text:"Close",onclick:function(){this.parent().parent().close()}},onPostRender:function(){var d,e="";e+='',tinymce.each(a.contentCSS,function(b){e+=''});var f=b.body_id||"tinymce";-1!=f.indexOf("=")&&(f=a.getParam("body_id","","hash"),f=f[a.id]||f);var g=b.body_class||"";-1!=g.indexOf("=")&&(g=a.getParam("body_class","","hash"),g=g[a.id]||"");var h=a.settings.directionality?' dir="'+a.settings.directionality+'"':"";if(d=""+e+'"+a.getContent()+"",c)this.getEl("body").firstChild.src="data:text/html;charset=utf-8,"+encodeURIComponent(d);else{var i=this.getEl("body").firstChild.contentWindow.document;i.open(),i.write(d),i.close()}}})}),a.addButton("preview",{title:"Preview",cmd:"mcePreview"}),a.addMenuItem("preview",{text:"Preview",cmd:"mcePreview",context:"view"})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/print/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("print",function(a){a.addCommand("mcePrint",function(){a.getWin().print()}),a.addButton("print",{title:"Print",cmd:"mcePrint"}),a.addShortcut("Meta+P","","mcePrint"),a.addMenuItem("print",{text:"Print",cmd:"mcePrint",icon:"print",shortcut:"Meta+P",context:"file"})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/save/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("save",function(a){function b(){var b;return b=tinymce.DOM.getParent(a.id,"form"),!a.getParam("save_enablewhendirty",!0)||a.isDirty()?(tinymce.triggerSave(),a.getParam("save_onsavecallback")?void(a.execCallback("save_onsavecallback",a)&&(a.startContent=tinymce.trim(a.getContent({format:"raw"})),a.nodeChanged())):void(b?(a.isNotDirty=!0,(!b.onsubmit||b.onsubmit())&&("function"==typeof b.submit?b.submit():a.windowManager.alert("Error: Form submit field collision.")),a.nodeChanged()):a.windowManager.alert("Error: No form element found."))):void 0}function c(){var b=tinymce.trim(a.startContent);return a.getParam("save_oncancelcallback")?void a.execCallback("save_oncancelcallback",a):(a.setContent(b),a.undoManager.clear(),void a.nodeChanged())}function d(){var b=this;a.on("nodeChange",function(){b.disabled(a.getParam("save_enablewhendirty",!0)&&!a.isDirty())})}a.addCommand("mceSave",b),a.addCommand("mceCancel",c),a.addButton("save",{icon:"save",text:"Save",cmd:"mceSave",disabled:!0,onPostRender:d}),a.addButton("cancel",{text:"Cancel",icon:!1,cmd:"mceCancel",disabled:!0,onPostRender:d}),a.addShortcut("Meta+S","","mceSave")}); -------------------------------------------------------------------------------- /static/tinymce/plugins/searchreplace/plugin.min.js: -------------------------------------------------------------------------------- 1 | !function(){function a(a,b,c,d,e){function f(a,b){if(b=b||0,!a[0])throw"findAndReplaceDOMText cannot handle zero-length matches";var c=a.index;if(b>0){var d=a[b];if(!d)throw"Invalid capture group";c+=a[0].indexOf(d),a[0]=d}return[c,c+a[0].length,[a[0]]]}function g(a){var b;if(3===a.nodeType)return a.data;if(n[a.nodeName]&&!m[a.nodeName])return"";if(b="",(m[a.nodeName]||o[a.nodeName])&&(b+="\n"),a=a.firstChild)do b+=g(a);while(a=a.nextSibling);return b}function h(a,b,c){var d,e,f,g,h=[],i=0,j=a,k=b.shift(),l=0;a:for(;;){if((m[j.nodeName]||o[j.nodeName])&&i++,3===j.nodeType&&(!e&&j.length+i>=k[1]?(e=j,g=k[1]-i):d&&h.push(j),!d&&j.length+i>k[0]&&(d=j,f=k[0]-i),i+=j.length),d&&e){if(j=c({startNode:d,startNodeIndex:f,endNode:e,endNodeIndex:g,innerNodes:h,match:k[2],matchIndex:l}),i-=e.length-g,d=null,e=null,h=[],k=b.shift(),l++,!k)break}else{if((!n[j.nodeName]||m[j.nodeName])&&j.firstChild){j=j.firstChild;continue}if(j.nextSibling){j=j.nextSibling;continue}}for(;;){if(j.nextSibling){j=j.nextSibling;break}if(j.parentNode===a)break a;j=j.parentNode}}}function i(a){var b;if("function"!=typeof a){var c=a.nodeType?a:l.createElement(a);b=function(a,b){var d=c.cloneNode(!1);return d.setAttribute("data-mce-index",b),a&&d.appendChild(l.createTextNode(a)),d}}else b=a;return function(a){var c,d,e,f=a.startNode,g=a.endNode,h=a.matchIndex;if(f===g){var i=f;e=i.parentNode,a.startNodeIndex>0&&(c=l.createTextNode(i.data.substring(0,a.startNodeIndex)),e.insertBefore(c,i));var j=b(a.match[0],h);return e.insertBefore(j,i),a.endNodeIndexn;++n){var p=a.innerNodes[n],q=b(p.data,h);p.parentNode.replaceChild(q,p),m.push(q)}var r=b(g.data.substring(0,a.endNodeIndex),h);return e=f.parentNode,e.insertBefore(c,f),e.insertBefore(k,f),e.removeChild(f),e=g.parentNode,e.insertBefore(r,g),e.insertBefore(d,g),e.removeChild(g),r}}var j,k,l,m,n,o,p=[],q=0;if(l=b.ownerDocument,m=e.getBlockElements(),n=e.getWhiteSpaceElements(),o=e.getShortEndedElements(),k=g(b)){if(a.global)for(;j=a.exec(k);)p.push(f(j,d));else j=k.match(a),p.push(f(j,d));return p.length&&(q=p.length,h(b,p,i(c))),q}}function b(b){function c(){function a(){e.statusbar.find("#next").disabled(!g(k+1).length),e.statusbar.find("#prev").disabled(!g(k-1).length)}function c(){tinymce.ui.MessageBox.alert("Could not find the specified string.",function(){e.find("#find")[0].focus()})}var d={},e=tinymce.ui.Factory.create({type:"window",layout:"flex",pack:"center",align:"center",onClose:function(){b.focus(),j.done()},onSubmit:function(b){var f,h,i,l;return b.preventDefault(),h=e.find("#case").checked(),l=e.find("#words").checked(),i=e.find("#find").value(),i.length?d.text==i&&d.caseState==h&&d.wholeWord==l?0===g(k+1).length?void c():(j.next(),void a()):(f=j.find(i,h,l),f||c(),e.statusbar.items().slice(1).disabled(0===f),a(),void(d={text:i,caseState:h,wholeWord:l})):(j.done(!1),void e.statusbar.items().slice(1).disabled(!0))},buttons:[{text:"Find",onclick:function(){e.submit()}},{text:"Replace",disabled:!0,onclick:function(){j.replace(e.find("#replace").value())||(e.statusbar.items().slice(1).disabled(!0),k=-1,d={})}},{text:"Replace all",disabled:!0,onclick:function(){j.replace(e.find("#replace").value(),!0,!0),e.statusbar.items().slice(1).disabled(!0),d={}}},{type:"spacer",flex:1},{text:"Prev",name:"prev",disabled:!0,onclick:function(){j.prev(),a()}},{text:"Next",name:"next",disabled:!0,onclick:function(){j.next(),a()}}],title:"Find and replace",items:{type:"form",padding:20,labelGap:30,spacing:10,items:[{type:"textbox",name:"find",size:40,label:"Find",value:b.selection.getNode().src},{type:"textbox",name:"replace",size:40,label:"Replace with"},{type:"checkbox",name:"case",text:"Match case",label:" "},{type:"checkbox",name:"words",text:"Whole words",label:" "}]}}).renderTo().reflow()}function d(a){var b=a.getAttribute("data-mce-index");return"number"==typeof b?""+b:b}function e(c){var d,e;return e=b.dom.create("span",{"data-mce-bogus":1}),e.className="mce-match-marker",d=b.getBody(),j.done(!1),a(c,d,e,!1,b.schema)}function f(a){var b=a.parentNode;a.firstChild&&b.insertBefore(a.firstChild,a),a.parentNode.removeChild(a)}function g(a){var c,e=[];if(c=tinymce.toArray(b.getBody().getElementsByTagName("span")),c.length)for(var f=0;fk&&l[h].setAttribute("data-mce-index",o-1)}return b.undoManager.add(),k=q,c?(p=g(q+1).length>0,j.next()):(p=g(q-1).length>0,j.prev()),!e&&p},j.done=function(a){var c,e,g,h;for(e=tinymce.toArray(b.getBody().getElementsByTagName("span")),c=0;c 2 | 3 | 4 | 5 | This is a custom SVG font generated by IcoMoon. 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /static/tinymce/plugins/sh4tinymce/fonts/sh4tinymce.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/plugins/sh4tinymce/fonts/sh4tinymce.eot -------------------------------------------------------------------------------- /static/tinymce/plugins/sh4tinymce/fonts/sh4tinymce.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | This is a custom SVG font generated by IcoMoon. 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /static/tinymce/plugins/sh4tinymce/fonts/sh4tinymce.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/plugins/sh4tinymce/fonts/sh4tinymce.ttf -------------------------------------------------------------------------------- /static/tinymce/plugins/sh4tinymce/fonts/sh4tinymce.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/plugins/sh4tinymce/fonts/sh4tinymce.woff -------------------------------------------------------------------------------- /static/tinymce/plugins/sh4tinymce/langs/en.js: -------------------------------------------------------------------------------- 1 | tinymce.addI18n('en',{ 2 | 'SH4TinyMCE - Code Editor' : 'SH4TinyMCE - Code Editor', 3 | 'Insert/Edit Code' : 'Insert/Edit Code', 4 | 'Language' : 'Language', 5 | 'Auto links' : 'Auto links', 6 | 'Gutter' : 'Gutter', 7 | 'Html script' : 'HTML script', 8 | 'Toolbar' : 'Toolbar', 9 | 'Highlight' : 'Highlight', 10 | 'Tab size' : 'Tab size', 11 | 'First Line' : 'First Line', 12 | }); 13 | -------------------------------------------------------------------------------- /static/tinymce/plugins/sh4tinymce/langs/fr_FR.js: -------------------------------------------------------------------------------- 1 | tinymce.addI18n('fr_FR',{ 2 | 'SH4TinyMCE - Code Editor' : 'SH4TinyMCE - Editeur de code', 3 | 'Insert/Edit Code' : 'Ins\u00e9rer/Editer Code', 4 | 'Language' : 'Langage', 5 | 'Auto links' : 'Liens cliquables', 6 | 'Gutter' : 'Num\u00e9ros de lignes', 7 | 'Html script' : 'Script HTML', 8 | 'Toolbar' : 'Menu', 9 | 'Highlight' : 'Highlight', 10 | 'Tab size' : 'Tabulation', 11 | 'First Line' : '1\u00e8re ligne', 12 | }); 13 | -------------------------------------------------------------------------------- /static/tinymce/plugins/sh4tinymce/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.requireLangPack("sh4tinymce");tinymce.PluginManager.add("sh4tinymce",function(e,url){function t(){function p(e){var t=e.split(";");var n={};for(var r=0;r/g,">");var r=t.data.language?t.data.language:u;var i=t.data.collapse!=o.collapse?";collapse:"+t.data.collapse:"";var f=t.data.autolinks!=o.autolinks?";auto-links:"+t.data.autolinks:"";var c=t.data.gutter!=o.gutter?";gutter:"+t.data.gutter:"";var h=t.data.htmlscript!=o.htmlscript?";html-script:"+t.data.htmlscript:"";var p=t.data.toolbar!=o.toolbar?";toolbar:"+t.data.toolbar:"";var d=t.data.firstline!=o.firstline?";first-line:"+t.data.firstline:"";var hls=t.data.highlight.indexOf(",")!=-1?"[":"",hle=t.data.highlight.indexOf(",")!=-1?"]":"";var v=t.data.highlight.replace(/ /g,"").replace(/\[/g,"").replace(/\]/g,"")!=o.highlight?";highlight:"+hls+t.data.highlight.replace(/ /g,"").replace(/\[/g,"").replace(/\]/g,"").replace(/,$/g,"")+hle:"";var m=t.data.tabsize!=o.tabsize?";tab-size:"+t.data.tabsize:"";s=e.dom.create("pre",{"class":"brush:"+r+i+f+c+h+p+d+v+m,contenteditable:"false"},n);if(a)e.dom.replace(s,l);else e.insertContent(e.dom.getOuterHTML(s)+"
")}var t,n=e.dom,r=e.selection,i={},s;var o={},u="html",a=false,f,l=r.getNode(),c;o.autolinks=true;o.collapse=false;o.firstline="1";o.gutter=true;o.highlight="";o.htmlscript=false;o.tabsize="4";o.toolbar=true;i.language="";i.autolinks=o.autolinks;i.collapse=o.collapse;i.firstline=o.firstline;i.gutter=o.gutter;i.highlight=o.highlight;i.htmlscript=o.htmlscript;i.tabsize=o.tabsize;i.toolbar=o.toolbar;var h=[{text:"Language",value:""},{text:"ActionScript3",value:"as3"},{text:"Bash/shell",value:"bash"},{text:"ColdFusion",value:"cf"},{text:"C#",value:"csharp"},{text:"C++",value:"cpp"},{text:"CSS",value:"css"},{text:"Delphi",value:"delphi"},{text:"Diff",value:"diff"},{text:"Erlang",value:"erl"},{text:"Groovy",value:"groovy"},{text:"HTML",value:"html"},{text:"Java",value:"java"},{text:"JavaFX",value:"jfx"},{text:"JavaScript",value:"js"},{text:"Perl",value:"perl"},{text:"PHP",value:"php"},{text:"PowerShell",value:"ps"},{text:"Python",value:"py"},{text:"Ruby",value:"ruby"},{text:"Scala",value:"scala"},{text:"SQL",value:"sql"},{text:"Text",value:"plain"},{text:"Visual Basic",value:"vb"},{text:"XML",value:"xml"}];if(l.nodeName.toLowerCase()=="pre"&&l.className.indexOf("brush:")!=-1){a=true;f=$(l).html();f=f.replace(/\<\;/gi,"<").replace(/\>\;/gi,">");c=l.className;c=c.replace(/ /g,"");p(c)}else{f=r.getContent({format:"text"});i.autolinks=false;i.toolbar=false}for(var d=0;d0){for(j=g+1;j=0;j--)if(i(h[j]))return h[j];return null}var g,h,i,j;if(!(9!==b.keyCode||b.ctrlKey||b.altKey||b.metaKey||b.isDefaultPrevented())&&(i=f(a.getParam("tab_focus",a.getParam("tabfocus_elements",":prev,:next"))),1==i.length&&(i[1]=i[0],i[0]=":prev"),h=b.shiftKey?":prev"==i[0]?c(-1):d.get(i[0]):":next"==i[1]?c(1):d.get(i[1]))){var k=tinymce.get(h.id||h.name);h.id&&k?k.focus():window.setTimeout(function(){tinymce.Env.webkit||window.focus(),h.focus()},10),b.preventDefault()}}var d=tinymce.DOM,e=tinymce.each,f=tinymce.explode;a.on("init",function(){a.inline&&tinymce.DOM.setAttrib(a.getBody(),"tabIndex",null),a.on("keyup",b),tinymce.Env.gecko?a.on("keypress keydown",c):a.on("keydown",c)})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/template/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("template",function(a){function b(b){return function(){var c=a.settings.templates;"string"==typeof c?tinymce.util.XHR.send({url:c,success:function(a){b(tinymce.util.JSON.parse(a))}}):b(c)}}function c(b){function c(b){function c(b){if(-1==b.indexOf("")){var c="";tinymce.each(a.contentCSS,function(b){c+=''}),b=""+c+""+b+""}b=f(b,"template_preview_replace_values");var e=d.find("iframe")[0].getEl().contentWindow.document;e.open(),e.write(b),e.close()}var g=b.control.value();g.url?tinymce.util.XHR.send({url:g.url,success:function(a){e=a,c(e)}}):(e=g.content,c(e)),d.find("#description")[0].text(b.control.value().description)}var d,e,h=[];return b&&0!==b.length?(tinymce.each(b,function(a){h.push({selected:!h.length,text:a.title,value:{url:a.url,content:a.content,description:a.description}})}),d=a.windowManager.open({title:"Insert template",layout:"flex",direction:"column",align:"stretch",padding:15,spacing:10,items:[{type:"form",flex:0,padding:0,items:[{type:"container",label:"Templates",items:{type:"listbox",label:"Templates",name:"template",values:h,onselect:c}}]},{type:"label",name:"description",label:"Description",text:"\xa0"},{type:"iframe",flex:1,border:1}],onsubmit:function(){g(!1,e)},width:a.getParam("template_popup_width",600),height:a.getParam("template_popup_height",500)}),void d.find("listbox")[0].fire("select")):void a.windowManager.alert("No templates defined")}function d(b,c){function d(a,b){if(a=""+a,a.length0&&(i=k.create("div",null),i.appendChild(j[0].cloneNode(!0))),h(k.select("*",i),function(b){g(b,a.getParam("template_cdate_classes","cdate").replace(/\s+/g,"|"))&&(b.innerHTML=d(a.getParam("template_cdate_format",a.getLang("template.cdate_format")))),g(b,a.getParam("template_mdate_classes","mdate").replace(/\s+/g,"|"))&&(b.innerHTML=d(a.getParam("template_mdate_format",a.getLang("template.mdate_format")))),g(b,a.getParam("template_selected_content_classes","selcontent").replace(/\s+/g,"|"))&&(b.innerHTML=l)}),e(i),a.execCommand("mceInsertContent",!1,i.innerHTML),a.addVisual()}var h=tinymce.each;a.addCommand("mceInsertTemplate",g),a.addButton("template",{title:"Insert template",onclick:b(c)}),a.addMenuItem("template",{text:"Insert template",onclick:b(c),context:"insert"}),a.on("PreProcess",function(b){var c=a.dom;h(c.select("div",b.node),function(b){c.hasClass(b,"mceTmpl")&&(h(c.select("*",b),function(b){c.hasClass(b,a.getParam("template_mdate_classes","mdate").replace(/\s+/g,"|"))&&(b.innerHTML=d(a.getParam("template_mdate_format",a.getLang("template.mdate_format"))))}),e(b))})})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/textcolor/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("textcolor",function(a){function b(b){var c;return a.dom.getParents(a.selection.getStart(),function(a){var d;(d=a.style["forecolor"==b?"color":"background-color"])&&(c=d)}),c}function c(){var b,c,d=[];for(c=a.settings.textcolor_map||["000000","Black","993300","Burnt orange","333300","Dark olive","003300","Dark green","003366","Dark azure","000080","Navy Blue","333399","Indigo","333333","Very dark gray","800000","Maroon","FF6600","Orange","808000","Olive","008000","Green","008080","Teal","0000FF","Blue","666699","Grayish blue","808080","Gray","FF0000","Red","FF9900","Amber","99CC00","Yellow green","339966","Sea green","33CCCC","Turquoise","3366FF","Royal blue","800080","Purple","999999","Medium gray","FF00FF","Magenta","FFCC00","Gold","FFFF00","Yellow","00FF00","Lime","00FFFF","Aqua","00CCFF","Sky blue","993366","Red violet","FFFFFF","White","FF99CC","Pink","FFCC99","Peach","FFFF99","Light yellow","CCFFCC","Pale green","CCFFFF","Pale cyan","99CCFF","Light sky blue","CC99FF","Plum"],b=0;b
'+(c?"×":"")+"
"}var d,e,f,g,h,k,l,m=this,n=m._id,o=0;for(d=c(),d.push({text:tinymce.translate("No color"),color:"transparent"}),f='',g=d.length-1,k=0;j>k;k++){for(f+="",h=0;i>h;h++)l=k*i+h,l>g?f+="":(e=d[l],f+=b(e.color,e.text));f+=""}if(a.settings.color_picker_callback){for(f+='",f+="",h=0;i>h;h++)f+=b("","Custom color");f+=""}return f+="
"}function e(b,c){a.undoManager.transact(function(){a.focus(),a.formatter.apply(b,{value:c}),a.nodeChanged()})}function f(b){a.undoManager.transact(function(){a.focus(),a.formatter.remove(b,{value:null},null,!0),a.nodeChanged()})}function g(c){function d(a){k.hidePanel(),k.color(a),e(k.settings.format,a)}function g(){k.hidePanel(),k.resetColor(),f(k.settings.format)}function h(a,b){a.style.background=b,a.setAttribute("data-mce-color",b)}var j,k=this.parent();tinymce.DOM.getParent(c.target,".mce-custom-color-btn")&&(k.hidePanel(),a.settings.color_picker_callback.call(a,function(a){var b,c,e,f=k.panel.getEl().getElementsByTagName("table")[0];for(b=tinymce.map(f.rows[f.rows.length-1].childNodes,function(a){return a.firstChild}),e=0;ee;e++)h(b[e],b[e+1].getAttribute("data-mce-color"));h(c,a),d(a)},b(k.settings.format))),j=c.target.getAttribute("data-mce-color"),j?(this.lastId&&document.getElementById(this.lastId).setAttribute("aria-selected",!1),c.target.setAttribute("aria-selected",!0),this.lastId=c.target.id,"transparent"==j?g():d(j)):null!==j&&k.hidePanel()}function h(){var a=this;a._color?e(a.settings.format,a._color):f(a.settings.format)}var i,j;j=a.settings.textcolor_rows||5,i=a.settings.textcolor_cols||8,a.addButton("forecolor",{type:"colorbutton",tooltip:"Text color",format:"forecolor",panel:{role:"application",ariaRemember:!0,html:d,onclick:g},onclick:h}),a.addButton("backcolor",{type:"colorbutton",tooltip:"Background color",format:"hilitecolor",panel:{role:"application",ariaRemember:!0,html:d,onclick:g},onclick:h})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/textpattern/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("textpattern",function(a){function b(){return j&&(i.sort(function(a,b){return a.start.length>b.start.length?-1:a.start.length'+a+""}function f(){var a,b="";for(a in n)b+=a;return new RegExp("["+b+"]","g")}function g(){var a,b="";for(a in n)b&&(b+=","),b+="span.mce-"+n[a];return b}var h,i,j,k,l,m,n,o,p=a.getBody(),q=a.selection;if(n={"\xa0":"nbsp","\xad":"shy"},d=!d,e.state=d,a.fire("VisualChars",{state:d}),o=f(),b&&(m=q.getBookmark()),d)for(i=[],tinymce.walk(p,function(a){3==a.nodeType&&a.nodeValue&&o.test(a.nodeValue)&&i.push(a)},"childNodes"),j=0;j=0;j--)a.dom.remove(i[j],1);q.moveToBookmark(m)}function c(){var b=this;a.on("VisualChars",function(a){b.active(a.state)})}var d,e=this;a.addCommand("mceVisualChars",b),a.addButton("visualchars",{title:"Show invisible characters",cmd:"mceVisualChars",onPostRender:c}),a.addMenuItem("visualchars",{text:"Show invisible characters",cmd:"mceVisualChars",onPostRender:c,selectable:!0,context:"view",prependToContext:!0}),a.on("beforegetcontent",function(a){d&&"raw"!=a.format&&!a.draft&&(d=!0,b(!1))})}); -------------------------------------------------------------------------------- /static/tinymce/plugins/wordcount/plugin.min.js: -------------------------------------------------------------------------------- 1 | tinymce.PluginManager.add("wordcount",function(a){function b(){a.theme.panel.find("#wordcount").text(["Words: {0}",e.getCount()])}var c,d,e=this;c=a.getParam("wordcount_countregex",/[\w\u2019\x27\-\u00C0-\u1FFF]+/g),d=a.getParam("wordcount_cleanregex",/[0-9.(),;:!?%#$?\x27\x22_+=\\\/\-]*/g),a.on("init",function(){var c=a.theme.panel&&a.theme.panel.find("#statusbar")[0];c&&window.setTimeout(function(){c.insert({type:"label",name:"wordcount",text:["Words: {0}",e.getCount()],classes:"wordcount",disabled:a.settings.readonly},0),a.on("setcontent beforeaddundo",b),a.on("keyup",function(a){32==a.keyCode&&b()})},0)}),e.getCount=function(){var b=a.getContent({format:"raw"}),e=0;if(b){b=b.replace(/\.\.\./g," "),b=b.replace(/<.[^<>]*?>/g," ").replace(/ | /gi," "),b=b.replace(/(\w+)(&#?[a-z0-9]+;)+(\w+)/i,"$1$3").replace(/&.+?;/g," "),b=b.replace(d,"");var f=b.match(c);f&&(e=f.length)}return e}}); -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/content.inline.min.css: -------------------------------------------------------------------------------- 1 | .mce-object{border:1px dotted #3A3A3A;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px!important;height:9px!important;border:1px dotted #3A3A3A;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#AAA}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#AAA;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid red;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid green;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #BBB}td.mce-item-selected,th.mce-item-selected{background-color:#39f!important}.mce-edit-focus{outline:1px dotted #333} -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/content.min.css: -------------------------------------------------------------------------------- 1 | body{background-color:#FFF;color:#000;font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px;scrollbar-3dlight-color:#F0F0EE;scrollbar-arrow-color:#676662;scrollbar-base-color:#F0F0EE;scrollbar-darkshadow-color:#DDD;scrollbar-face-color:#E0E0DD;scrollbar-highlight-color:#F0F0EE;scrollbar-shadow-color:#F0F0EE;scrollbar-track-color:#F5F5F5}td,th{font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px}.mce-object{border:1px dotted #3A3A3A;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px!important;height:9px!important;border:1px dotted #3A3A3A;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#AAA}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#AAA;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid red;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid green;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #BBB}td.mce-item-selected,th.mce-item-selected{background-color:#39f!important}.mce-edit-focus{outline:1px dotted #333} -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/fonts/tinymce-small.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/fonts/tinymce-small.eot -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/fonts/tinymce-small.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/fonts/tinymce-small.ttf -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/fonts/tinymce-small.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/fonts/tinymce-small.woff -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/fonts/tinymce.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/fonts/tinymce.eot -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/fonts/tinymce.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/fonts/tinymce.ttf -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/fonts/tinymce.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/fonts/tinymce.woff -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/img/anchor.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/img/anchor.gif -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/img/loader.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/img/loader.gif -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/img/object.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/img/object.gif -------------------------------------------------------------------------------- /static/tinymce/skins/lightgray/img/trans.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tmacjx/my_site/8ac883e67e8747ca5e6cb8014e75fd70c0fe1141/static/tinymce/skins/lightgray/img/trans.gif -------------------------------------------------------------------------------- /templates/404.html: -------------------------------------------------------------------------------- 1 | {% extends "base.html" %} 2 | {% block title %} 3 | Page not found 4 | {% endblock %} 5 | 6 | {% block content %} 7 |

Sorry, but the requested page could not be found.

8 | {% endblock %} 9 | 10 | 11 | -------------------------------------------------------------------------------- /templates/500.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | Page unavailable 6 | 7 | 8 |

Page unavailable

9 |

Sorry, but the requested page is unavailable due to a 10 | server hiccup.

11 |

Our engineers have been notified, so check back later.

12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /templates/blog/_comments.html: -------------------------------------------------------------------------------- 1 | 2 |
3 | 4 | 5 | 16 | 17 | -------------------------------------------------------------------------------- /templates/blog/_paginator.html: -------------------------------------------------------------------------------- 1 | 2 | 30 | -------------------------------------------------------------------------------- /templates/blog/_side.html: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 12 | 13 |
14 |

新浪微博

15 |
16 | 18 | 19 |
20 |
21 | 22 |
23 |

文章归档

24 | 32 | 33 | 34 | 35 |
36 | 37 | 38 | 39 |
40 |

近期评论

41 | 42 | 43 |
    44 |
45 | 46 | 56 | 57 | 58 | 59 | 60 |
61 | 62 | 63 |
64 |

分类目录

65 |
    66 | {% if classification %} 67 | {% for x,y in classification %} 68 |
  • {{x}}({{y}})
  • 69 | 70 | {% endfor %} 71 | {% endif %} 72 |
73 |
74 | 75 |
76 |

标签云

77 | 78 | 79 | 80 | 81 |
82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 |
91 | 92 | 114 | 115 | 143 | 144 | 145 | -------------------------------------------------------------------------------- /templates/blog/about.html: -------------------------------------------------------------------------------- 1 | {% extends "base.html" %} 2 | {% block title %} 3 | 关于我|TmacKan的小站 4 | {% endblock %} 5 | {% block path %} 6 | 当前位置 : 首页 » 关于我 7 | {% endblock %} 8 | {% block content %} 9 | 10 | 11 |
12 |
13 |

14 | 关于本站 15 |

16 | 17 |
18 |    linux下Python web框架Django开发简易版,部署在VPS 19 |
20 |
21 | 22 | 若无特殊说明,本站所有文章均为原创文章,并遵循 CC BY-SA 3.0协议 发布 23 | 24 |
25 |
26 | 27 |

28 | 关于我 29 |

30 | 31 | 32 |
33 |    Computer Science专业大三男一枚,东搞西搞,目前学习Android和Java中,对在线学习 34 |

和移动开发感兴趣,闲暇打球,伪文艺青年,看些 35 | 小说 历史 传记 游记之类 36 |
37 |
38 |
    39 | 40 | 41 | 42 |
43 | 44 |

联系我 45 |

46 |
    47 |
  • 博客:   TmacKan的小站
  • 48 |
  • 邮箱:   kan49733110@163.com
  • 49 |
  • GitHub:  __init__
  • 50 |
  • 豆瓣:   让改变发生
  • 51 |
  • 知乎:   kan_tmac
  • 52 |
53 | 54 |
55 |
56 | 57 | 58 | {% include "blog/_comments.html" %} 59 | 60 | 61 | {% endblock %} 62 | 63 | {% block side %} 64 | {% include "blog/_side.html" %} 65 | {% endblock %} 66 | 67 | 68 | -------------------------------------------------------------------------------- /templates/blog/archive.html: -------------------------------------------------------------------------------- 1 | {% extends "base.html" %} 2 | {% block title %} 3 | 4 | 文章存档|TmacKan的小站 5 | 6 | {% endblock %} 7 | {% block path %} 8 | 当前位置 : 首页 » 文章存档 9 | {% endblock %} 10 | {% block content %} 11 | {% if archive %} 12 | {% for key,value in archive.items %} 13 | 14 |
15 |
16 |

{{key.year}}年{{key.month}}月

17 | 18 | 23 |
24 |
25 | {% endfor %} 26 | {% endif %} 27 | 28 | 29 | {% endblock %} 30 | 31 | {% block side %} 32 | {% include "blog/_side.html" %} 33 | {% endblock %} 34 | -------------------------------------------------------------------------------- /templates/blog/content.html: -------------------------------------------------------------------------------- 1 | {% extends "base.html" %} 2 | 3 | {% block title %} 4 | {{article.title}}|TmacKan的小站 5 | {% endblock %} 6 | {% block path %} 7 | 当前位置 : 首页 » 文章分类 : {{article.classification}} »  {{article.title}} 8 | {% endblock %} 9 | {% block content %} 10 | 11 |
12 |
13 | 14 |
15 | 30 | 31 | 32 |

33 | 34 | {{article.title}} 35 |

36 | 37 | 38 | 39 |
40 | 41 | 42 |
43 | 44 |
45 |
46 | 47 | 48 | {{ article.content|safe }} 49 | 50 |
51 |
52 | 53 | 54 | 55 | 88 | 89 |
90 |
91 | 92 | {% if article.get_before_article %} 93 | {% with before=article.get_before_article %} 94 |

上一篇 {{before}}

95 | {% endwith %} 96 | {% endif %} 97 | 98 | {% if article.get_after_article %} 99 | 100 | {% with after=article.get_after_article %} 101 |

下一篇 {{after}}

102 | {% endwith %} 103 | {% endif %} 104 | 105 | 106 | 107 | 108 | {% include "blog/_comments.html" %} 109 | {% endblock %} 110 | 111 | {% block side %} 112 | {% include "blog/_side.html" %} 113 | {% endblock %} 114 | -------------------------------------------------------------------------------- /templates/blog/index.html: -------------------------------------------------------------------------------- 1 | {% extends "base.html" %} 2 | 3 | {% block title %} 4 | {% if is_home %} 5 | TmacKan的小站 6 | {% endif%} 7 | {% if is_arch_month %} 8 | {{month}}月 |{{year}}年|TmacKan的小站 9 | {% endif%} 10 | {% if is_classfi %} 11 | {{classfi}}|TmacKan的小站 12 | {% endif%} 13 | {% if is_tag %} 14 | {{tag}}|TmacKan的小站 15 | {% endif%} 16 | {% endblock %} 17 | {% block path %} 18 | {% if is_home %} 19 | 当前位置 : 首页 20 | {% endif%} 21 | 22 | {% if is_arch_month %} 23 | 当前位置 : 首页 » 按月归档 :  {{month}}月 {{year}}年 24 | {% endif%} 25 | {% if is_classfi %} 26 | 当前位置 : 首页 » 文章分类 :  {{classfi}} 27 | {% endif%} 28 | {% if is_tag %} 29 | 当前位置 : 首页 » 标签 :  {{tag}} 30 | {% endif%} 31 | 32 | {% if is_search %} 33 | 当前位置 : 首页 » 搜索 : {{s}} {{tag}} 34 | {% endif%} 35 | 36 | 37 | 38 | {% endblock %} 39 | {% block content %} 40 | 41 | {% if error %} 42 |

没有相关文章题目

43 | {% else %} 44 | {% for article in articles %} 45 |
46 |
47 | 48 |
49 | 64 | 65 | 66 |

67 | 68 | {{article.title}}

69 |
70 | 71 | 72 |
73 | 74 |
75 |
76 |

77 | {{ article.content|truncatewords_html:40|safe}} 78 |

79 |
80 |
81 | 82 | 83 | 84 | 105 | 106 |
107 |
108 | {% endfor%} 109 | 110 | {% endif %} 111 | 112 | {% include "blog/_paginator.html" %} 113 | {% endblock %} 114 | 115 | {% block side %} 116 | {% include "blog/_side.html" %} 117 | {% endblock %} 118 | 119 | -------------------------------------------------------------------------------- /templates/blog/message.html: -------------------------------------------------------------------------------- 1 | {% extends "base.html" %} 2 | {% block title %} 3 | 给我留言|TmacKan的小站 4 | {% endblock %} 5 | {% block path %} 6 | 当前位置 : 首页 » 给我留言 7 | {% endblock %} 8 | {% block content %} 9 | 10 |
11 |
12 |
13 | Hi:
14 |               欢迎访问我的博客,你可以在下面留下你的足迹。^_^ 15 |
16 |
17 |
18 | {% include "blog/_comments.html" %} 19 | 20 | 21 | {% endblock %} 22 | 23 | {% block side %} 24 | {% include "blog/_side.html" %} 25 | {% endblock %} 26 | --------------------------------------------------------------------------------