Jump to content

Quoting from database


ehku

Recommended Posts

Posted

Hello,

I would like to modify the quoting function in IPS 4 so that it quotes the content from the database of the post, instead of quoting what is actually displayed on the screen (just like on IP.Board 3.x and prior).

Let me clarify.

I'm using a JavaScript library called MathJax to display math formulas. For example, when I type $a^2+b^2$ in the editor, after submitting the post it will be displayed as a2 + b2. In IPS 4, when quoting this post, it will copy the displayed formula, i.e.  a2 + b2 and place it in a quote block. Note that although what we see on the screen is  a2 + b2, the content stored in the database is actually $a^2+b^2$ (this is what we obtain when clicking on the Edit button).

I would like the quoting function to copy what's stored in the database (i.e. $a^2+b^2$) instead of the rendered post (i.e. a2 + b2).

My plan is:

- Find out what a click of the Edit button does: this event calls a function that copies the content of the post from the database and pastes it to the editor.

- Find out what a click on the Quote button does: this event calls a function that copies the rendered content of the post, places it in a quote block and put this in the editor.

- Hack the code by replacing the blue part of the Quote function with the red part of the Edit function.

That's the general idea, but I'm really having difficulty because I'm not a developer :( Could anybody please help? For example, when clicking on the Edit button, what is the function that is called and where to find it in the source code?

Thank you very much in advance for your help!!! 

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...