嵌入Vimeo视频 strong> p>[embedVimeo video=”video-id” width=”###” height=”###”]
[embedVimeo video =” video-id” width =” ###” height =” ###”] p>
This Shortcode will embed a Vimeo video into the page.
此简码会将Vimeo视频嵌入页面。
The video attribute is the Vimeo video ID of the video you want to embed into the page.
video属性是您要嵌入到页面中的视频的Vimeo视频ID。
It can be found at the end of the URL on Vimeo.
可以在Vimeo上URL的末尾找到它。
For example, the video located at https://vimeo.com/14651522 has the video ID “14651522”.
例如,位于 https://vimeo.com/14651522 的视频具有视频ID“ 14651522”。
You will always find the video ID after the “/” in the Vimeo URL.
您将始终在Vimeo URL中的“ /”之后找到视频ID。
The video attribute is required.
视频属性是必需的。
The width and height attributes will set the size of the embedded video, and both are optional attributes.
width和height属性将设置嵌入式视频的大小,并且两者都是可选属性。
If they are not entered the width will default to 560 and the height will default to 315.
如果未输入,则宽度默认为560,高度默认为315。 p>
Please note that setting the width to “auto” will not work.
请注意,将宽度设置为“自动”将不起作用。
Rather, please set the width to “100%” to get the same effect.
相反,请将宽度设置为“ 100%”以获得相同的效果。
If you are looking to add your own custom CSS to the container around the Vimeo video embed, the class is “div.dobdev-vimeo-container”.
如果要在Vimeo视频嵌入周围的容器中添加自己的自定义CSS,则该类为“ div.dobdev-vimeo-container”。
This should only be done by someone experienced using CSS, otherwise the results could cause harm to the layout of your site.
仅应由有使用CSS经验的人员来完成,否则结果可能会损害您的网站布局。 p>
Inline Code Snippets
内联代码段 strong> p>[startCode]
[startCode] p>
This shortcode will create the start tags for an inline code snippet which will then be ended using the [endCode] shortcode.
此简码将为内联代码段创建开始标签,然后使用[endCode]简码结束。
If you use these two together you can create small inline code samples that look great, are easy to copy, and distinguish themselves from the rest of your text content in appearance.
如果将两者一起使用,则可以创建看起来不错,易于复制并在外观上与其余文本内容区分开的小型内联代码示例。
These make it easy to include code snippets without having to switch to the HTML editor in WordPress.
这些功能使添加代码段变得很容易,而无需在WordPress中切换到HTML编辑器。 p>
[endCode]
[endCode] p>
This shortcode will create the end tags for the inline code snippet started by [startCode].
此简码将为[startCode]开头的内联代码段创建结束标签。
If you use these two together you can create small inline code samples that look great, are esay to copy, and distinguish themselves from the rest of your text content in appearance.
如果将两者一起使用,则可以创建看起来不错,易于复制并在外观上与其余文本内容区分开的小型内联代码示例。
These make it easy to include code snippets without having to switch to the HTML editor in WordPress.
这些功能使添加代码段变得很容易,而无需在WordPress中切换到HTML编辑器。 p>
If you want to change any of the styling for the inline code snippets, please use the CSS class “code.dobdev-code-inline”.
如果要更改内联代码段的任何样式,请使用CSS类“ code.dobdev-code-inline”。
From here you can change font size, font family, and even colour using your theme’s (hopefully child theme’s) stylesheet.
在这里,您可以使用主题样式表(希望是子主题样式)来更改字体大小,字体系列,甚至颜色。
This should only be done by someone experienced using CSS, otherwise the results could cause harm to the layout of your site.
仅应由有使用CSS经验的人员来完成,否则结果可能会损害您的网站布局。 p>
Code Blocks
代码块 strong> p>[startCodeBlock]
[startCodeBlock] p>
This shortcode will create the start tags for a code block which will then be ended using the [endCodeBlock] shortcode.
此短代码将为代码块创建开始标签,然后使用[endCodeBlock]短代码结束该代码块。
If you use these two together you can create small, simple code blocks that have a black background with white text, which is the common convention for code blocks.
如果将两者一起使用,则可以创建带有黑色背景和白色文本的小型简单代码块,这是代码块的常见约定。
This is great for showing Terminal commands or very small code snippets (I recommend using the embed GitHub Gists shortcode for longer code samples).
这对于显示终端命令或非常小的代码片段非常有用(对于更长的代码示例,我建议使用embed GitHub Gists短代码)。 p>
[endCodeBlock]
[endCodeBlock] p>
This shortcode will create the end tags for the code snippet started by [startCode].
此简码将为[startCode]开头的代码段创建结束标记。
If you use these two together you can create small, simple code blocks that have a black background with white text, which is the common convention.
如果将两者一起使用,则可以创建小的简单代码块,这些代码块具有黑色背景和白色文本,这是常见的约定。
This is great for showing Terminal commands or very small code snippets (I recommend using the embed GitHub Gists shortcode for longer code samples).
这对于显示终端命令或非常小的代码片段非常有用(对于更长的代码示例,我建议使用embed GitHub Gists短代码)。 p>
If you want to change any of the styling for the code blocks, please use the CSS class “pre.dobdev-code-block”.
如果要更改代码块的任何样式,请使用CSS类“ pre.dobdev-code-block”。
From here you can change font size, font family, background color, padding and even the actual text color using your theme’s (hopefully child theme’s) stylesheet.
在这里,您可以使用主题样式表(希望是子主题样式)来更改字体大小,字体系列,背景颜色,填充,甚至是实际文本颜色。
This should only be done by someone experienced using CSS, otherwise the results could cause harm to the layout of your site.
仅应由有使用CSS经验的人员来完成,否则结果可能会损害您的网站布局。 p>
Buttons
按钮 strong> p>[button text=”buttonText” color=”color” link=”#”]
[button text =” buttonText” color =“ color” link =“#”] p>
This shortcode will create a purely CSS button where ever you place it.
此简码将在您放置的地方创建一个纯CSS按钮。
The text attribute is the text that will appear within the button.
文本属性是将显示在按钮内的文本。
The color atrribute defines what color will show – the choices for color are red, blue, green, orange, purple, and turquoise.
颜色属性定义了将显示的颜色–颜色的选择是红色,蓝色,绿色,橙色,紫色和青绿色。
The link attribute is what link the user wants to redirect to when the button is clicked.
链接属性是单击按钮时用户希望重定向到的链接。
If you do not want a redirect on the button click, just use a “#” and the button will do nothing when clicked.
如果您不希望在单击按钮时进行重定向,只需使用“#”,单击按钮就不会执行任何操作。 p>
User Interaction Messages
用户互动消息 strong> p>[infoMessage text=”your-message”]
[infoMessage text =“您的消息”]
[successMessage text=”your-message”]
[successMessage text =“您的消息”]
[warningMessage text=”your-message”]
[warningMessage text =“您的消息”]
[errorMessage text=”your-message”]
[errorMessage text =“您的消息”] p>
These shortcodes will display a message with an appropriate color that will notify users of how their interaction is working.
这些简码将以适当的颜色显示一条消息,该消息将通知用户其交互作用如何。
The color scheme follows that of many other websites – blue is for information, green is for success, yellow is a warning and red signifies an error.
颜色方案遵循许多其他网站的颜色方案–蓝色代表信息,绿色代表成功,黄色代表警告,红色代表错误。 p>
Related Posts
相关帖子 strong> p>[relatedPosts posts=”1stPostID;
[relatedPosts posts =” 1stPostID;
2ndPostID;
2ndPostID;
3rdPostID”]
3rdPostID”]
eg.
例如。
[relatedPosts post=”1;
[relatedPosts post =” 1;
2;
2;
3;
3;
4″]
4“] p>
This shortcode will create a small slideshow of related posts wherever you put it.
无论您放置在哪里,此简码都将创建一个有关相关帖子的小型幻灯片。
Note that you must enter the post ID’s yourself, as this shortcode will not automatically index and display related posts for you.
请注意,您必须自己输入帖子ID,因为该短代码不会自动为您编制索引并显示相关帖子。
Although this is more work it has a significantly smaller load time than plugins which do automatically index them for you.
尽管这项工作比较繁琐,但与为您自动为它们编制索引的插件相比,其加载时间要短得多。
I would recommend this to people who run their own personal blogs with fewer articles.
我建议向运行自己的个人博客且文章较少的人们推荐此方法。
The slideshow is made using only CSS and jQuery.
幻灯片仅使用CSS和jQuery制作。 p>
Please note that this shortcode should only be used on posts, NOT pages.
请注意,此简码只能用于帖子,不能用于页面。
It will cause pages to hang.
这将导致页面挂起。 p>
Social Share
社交分享 strong> p>[socialShare]
[socialShare] p>
This shortcode will create a section with links for sharing your page or post to Twitter, Facebook, Google Plus and Linkedin.
此简码将创建一个带有链接的部分,用于共享您的页面或发布到Twitter,Facebook,Google Plus和Linkedin。
The links are color coded to match the colors of each of their respective websites.
链接采用颜色编码,以匹配其各自网站的颜色。
You can use this like a normal shortcode in your page/post’s content or you can add it to your template files by using “echo do_shortcode(‘[socialShare]’);”.
您可以在页面/帖子的内容中像普通的简码一样使用此代码,也可以使用“ echo do_shortcode('[socialShare]');”将其添加到模板文件中。 p>