Git Product home page Git Product logo

Comments (4)

kaeyleo avatar kaeyleo commented on September 7, 2024

有可能是MathJax插件的问题.. 请务必确认MathJax的使用姿势是否正确

from jekyll-theme-h2o.

pickou avatar pickou commented on September 7, 2024

谢谢,我不太懂这方面的东西,所以只是用用。我感觉是某个地方和mathjax产生冲突了

from jekyll-theme-h2o.

kaeyleo avatar kaeyleo commented on September 7, 2024

你试试把你的那段代码放至 _includes/post-head.html 中,代码位置大概如下:

<!DOCTYPE html>
<html>
<head>
<title>MathJax TeX Test Page</title>
<link rel="stylesheet" href="/assets/css/github-markdown.css">
<link rel="stylesheet" href="/assets/css/xxx.css">
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}});
</script>
<script type="text/javascript"
  src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
</script>
</head>
<body>
When $a \ne 0$, there are two solutions to \(ax^2 + bx + c = 0\) and they are
$$x = {-b \pm \sqrt{b^2-4ac} \over 2a}.$$
</body>
</html>

我看了下mathjax.js的文档,有说Markdown可能会和mathjax有冲突,具体请查看 TeX和LaTeX支持 获取这个问题的解决方法。

目前看来,使用mathjax.js插件对于Markdown并不能很好的支持,我还找到了其他几种解决方案:

  1. 使用Google Chart的服务器

<img src="http://chart.googleapis.com/chart?cht=tx&chl= 在此插入Latex公式" style="border:none;">

  1. 使用forkosh服务器

<img src="http://www.forkosh.com/mathtex.cgi? 在此处插入Latex公式">

参考:http://blog.csdn.net/xiahouzuoxin/article/details/26478179

希望对你有帮助

from jekyll-theme-h2o.

pickou avatar pickou commented on September 7, 2024

非常感谢

from jekyll-theme-h2o.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.