Skip to main content
jameshoty
Known Participant
December 13, 2017
Answered

How to allow user to enter maths symbols?

  • December 13, 2017
  • 3 replies
  • 2678 views

Is there a way to allow user to enter maths symbols (square root, fraction, x to the power of y,  (3x + y) / 4 (but display in the "horizontal form) when developing using DW CC?

    This topic has been closed for replies.
    Correct answer B i r n o u

    On second thoughts, the HTML entity way is far too limited for what you want.

    The problem is that HTML on its own will not do the job, you will need another interpreter/program to do that.

    Have a read of MathJax and see how that fits in with your project.


    yep currently only gecko allows this use, but depending on the target audience (I don't think that it could be a problem) to ask the use of Firefox for such a web site... and that way, the content will respect the pure standrad (it is a w3c recommendation - MathML Fundamentals ) instead of going nowhere using proprietary tagging... don't you think?

    at least if that was my client, I will have this talks to warn him about too proprietary orientation before committing a significant amount of work

    3 replies

    MrMathType — Retired
    Participating Frequently
    December 13, 2017

    From your original description, it seems like you're wanting to build a web page to allow user input of some type -- in a form perhaps? If this is the case, really none of the suggestions here are what you're after. The other responses were based on you being the one to enter these mathematical symbols or expressions. If I have understood correctly and it's the user who will be entering this information, you can't require the user to already have an understanding of HTML entities or the like. You'll need some sort of user interface that enables mathematical input. There are some available if that's what you're after.

    jameshoty
    jameshotyAuthor
    Known Participant
    December 14, 2017

    It is true that the suggested resources is too "advance" for me at this moment. And it is correct that I want to build a site that allow users to enter math symbols and submit it to the site owner. The site owner will reply and will only enter math simple too. You are right that it is not easy for users to learn the "language" and intuitively entering  the math symbol. And I only want about 10-20 maths symbols for this moment. Is this possible to do?

    BenPleysier
    Community Expert
    Community Expert
    December 14, 2017

    MrMathType has already stated that which I subtly pointed out, even for experienced coders, this is a mamouth task. I envisage a sort of a lookup table that pops up when a hotkey, or similar, is pressed. The pop-up would contain the symbols and when the required symbol is pressed, it will insert that symbol where the cursor is positioned. As far as I know, there is no out-of-the-box solution for this.

    Instead of a pop-up, you could have a menubar containing the symbols. This would work in a similar manner to the pop-up.

    Wappler is the DMXzone-made Dreamweaver replacement and includes the best of their powerful extensions, as well as much more!
    B i r n o u
    Community Expert
    Community Expert
    December 13, 2017

    did you check on the mathml side ?

    <math> - MathML | MDN

    WolfShade
    Legend
    December 13, 2017

    I looked at the page from the link you provided.  Unfortunately, it only works in most versions of FireFox, some Opera, some Safari.  There is no support for IE or Chrome, not even the most recent versions.

    V/r,

    ^ _ ^

    MrMathType — Retired
    Participating Frequently
    December 13, 2017

    I see the "page from the link you provided" you're referring to is the one to MathML. I'd like to point out the other one is perhaps more useful. MathJax works in all browsers on all platforms, mobile devices included.

    BenPleysier
    Community Expert
    Community Expert
    December 13, 2017

    Have a look at HTML Unicode UTF-8

    In other words, because the symbols are not included on a key board, your users will need to use an HTML entity name.

    Wappler is the DMXzone-made Dreamweaver replacement and includes the best of their powerful extensions, as well as much more!
    jameshoty
    jameshotyAuthor
    Known Participant
    December 13, 2017

    Thanks for the prompt reply. I am 2 weeks "old" with Dreamweaver and so is HTML/CSS etc, and so if my question sounds "stupid" kindly forgive me.

    What is HTML entity name? And how will the users know what number to enter for (for example) square root?

    BenPleysier
    Community Expert
    Community Expert
    December 13, 2017

    On second thoughts, the HTML entity way is far too limited for what you want.

    The problem is that HTML on its own will not do the job, you will need another interpreter/program to do that.

    Have a read of MathJax and see how that fits in with your project.

    Wappler is the DMXzone-made Dreamweaver replacement and includes the best of their powerful extensions, as well as much more!