查看: 361|回复: 6
打印 上一主题 下一主题

[悬赏] Offline MathJax in MDX/MDD for SEP

[复制链接]
  • TA的每日心情
    郁闷
    2023-2-15 01:29
  • 签到天数: 566 天

    [LV.9]以坛为家II

    46

    主题

    1086

    回帖

    5万

    积分

    状元

    Rank: 9Rank: 9Rank: 9

    积分
    56253

    QQ 章灌水大神章笑傲江湖章

    跳转到指定楼层
    1
    发表于 2020-1-5 01:35:26 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
    222
    Previously I made Stanford Encyclopedia of Philosophy in mdx/mdd format but the mathematical notations were not shown properly. Then I saw this post: [教程] 在Mdx中【离线】使用MathJax来渲染数学公式. I paid there but there were nothing but a dead link. I have fixed many bugs from previously published Stanford Encyclopedia of Philosophy.and wish to publish a new version from Winter 2019 Edition with working MathJax. I've already grabbed the data and processed in mdx/mdd format, just waiting to fix the MathJax.


    Is there anyone who can help me?

    最佳答案

    查看完整内容

    download the links to locale, and place .js file in the same directory of mdx call the .js file locally.
  • TA的每日心情
    奋斗
    2022-12-1 14:41
  • 签到天数: 1047 天

    [LV.10]以坛为家III

    13

    主题

    1422

    回帖

    1万

    积分

    状元

    Rank: 9Rank: 9Rank: 9

    积分
    13502

    灌水大神章小蜜蜂章笑傲江湖章

    2
    发表于 2020-1-5 01:35:27 | 只看该作者
    nhb42 发表于 2020-1-5 10:33
    looks like it's online. is there a way to make it offline?

    download the links to locale, and place .js file in the same directory of mdx
    call the .js file locally.
  • TA的每日心情
    奋斗
    2022-12-1 14:41
  • 签到天数: 1047 天

    [LV.10]以坛为家III

    13

    主题

    1422

    回帖

    1万

    积分

    状元

    Rank: 9Rank: 9Rank: 9

    积分
    13502

    灌水大神章小蜜蜂章笑傲江湖章

    3
    发表于 2020-1-5 09:48:37 | 只看该作者
    试试把下面的.js改为本地的
    http://cdn.mathjax.org/mathjax/latest/MathJax.js

    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>MathJax AsciiMath Test Page</title>
    <script type="text/javascript"
    src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
    </script>
    <script type="text/x-mathjax-config">
    MathJax.Hub.Config({
    tex2jax: {inlineMath: [['$','$'], ['\(','\)']]}
    });
    </script>
    </head>
    <body>
    <div id="pop">
    $$\frac{1}{2}$$
    </div>

    </body>
    </html>

    <script type="text/javascript"
    src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
    </script>
    <script type="text/x-mathjax-config">
    MathJax.Hub.Config({
    tex2jax: {inlineMath: [['$','$'], ['\(','\)']]}
    });
    </script>

    这两段代码放到body底部就可以了。
  • TA的每日心情
    郁闷
    2023-2-15 01:29
  • 签到天数: 566 天

    [LV.9]以坛为家II

    46

    主题

    1086

    回帖

    5万

    积分

    状元

    Rank: 9Rank: 9Rank: 9

    积分
    56253

    QQ 章灌水大神章笑傲江湖章

    4
     楼主| 发表于 2020-1-5 10:33:33 | 只看该作者
    dictionaryfan 发表于 2020-1-5 09:48
    试试把下面的.js改为本地的
    http://cdn.mathjax.org/mathjax/latest/MathJax.js

    looks like it's online. is there a way to make it offline?
  • TA的每日心情
    郁闷
    2023-2-15 01:29
  • 签到天数: 566 天

    [LV.9]以坛为家II

    46

    主题

    1086

    回帖

    5万

    积分

    状元

    Rank: 9Rank: 9Rank: 9

    积分
    56253

    QQ 章灌水大神章笑傲江湖章

    5
     楼主| 发表于 2020-1-11 15:39:05 | 只看该作者
    dictionaryfan 发表于 2020-1-5 09:48
    试试把下面的.js改为本地的
    http://cdn.mathjax.org/mathjax/latest/MathJax.js

    none of the methods worked with SEP. thanks anyway...
  • TA的每日心情
    奋斗
    2022-12-1 14:41
  • 签到天数: 1047 天

    [LV.10]以坛为家III

    13

    主题

    1422

    回帖

    1万

    积分

    状元

    Rank: 9Rank: 9Rank: 9

    积分
    13502

    灌水大神章小蜜蜂章笑傲江湖章

    6
    发表于 2020-1-11 19:43:49 | 只看该作者
    本帖最后由 dictionaryfan 于 2020-1-11 19:58 编辑
    nhb42 发表于 2020-1-11 15:39
    none of the methods worked with SEP. thanks anyway...

    then try this link mathjax.js:
    https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js
    file size:63048
    this is the link inside previous one
  • TA的每日心情
    开心
    2021-3-24 19:18
  • 签到天数: 22 天

    [LV.4]偶尔看看III

    56

    主题

    449

    回帖

    6万

    积分

    状元

    Rank: 9Rank: 9Rank: 9

    积分
    61423
    7
    发表于 2021-3-7 01:25:09 | 只看该作者
    nhb42 发表于 2020-1-11 15:39
    none of the methods worked with SEP. thanks anyway...

    Did the JS file work for for your mdd/mdx?