Closed. This question is not about programming or software development. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed last month.
Improve this question
I'm using wiris plugin to enter equation. However, when i save the editor and refresh the page the equation is replaced with plain text. Anyone else having this issue? any other equation plugin for tiniMCE?
Please review the installation instructions at http://www.wiris.com/plugins/docs/tinymce. Are you using the plugin in any specific CMS? Please note that we have specific instructions for some CMS like Joomla or Wordpress. In any case, we believe that you have skipped step 5 of the documentation. WIRIS formulas, from plugin version 3.50.x, are stored in the database as MathML. You need to include WIRISplugin.js, as detailed on step 5 of the general TinyMCE plugin documentation, in order to convert MathML to formula images. You can check more details at http://www.wiris.com/en/plugins/docs/full-mathml-mode.
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
I'm wondering if anyone came up with any tutorial / walk through for Draft-js to simply save editor state and display it as html to the user. I've been searching and trying and still unable to display html. It seems like most are just saving the editor state and reloading it into the editor instead of displaying it as html.
It seems like most go with convertFromRaw and convertToRaw, but the amount of steps included in that seems like there are quite a few steps that should be simplified, and the example here: https://draftjs.org/docs/api-reference-data-conversion.html#content seems like it's only used to place the content back in the editor later.
Maybe I'm not even looking at the right tool - I simply want an editor to save formatted text and display it. I'm not sure why the resources are so hard to find, or if I'm just looking in the wrong spots (seems like there are too many packages for Draft-js with not much documentation and examples IMO). However, I'm sure this must not be hard to accomplish.
Draftjs is concentrating on displaying rich text within an editor. However, if you want to display the corresponding HTML you have to use an external package called draftjs-export-html.
import {stateToHTML} from 'draft-js-export-html';
you can get the html using let html = stateToHTML(editorState.getCurrentContent(), options); this will do the basic formatting of styles like bold, italic etc. You can also pass your own styling preferences of your draftjs entites using the option parameter.
https://www.npmjs.com/package/draft-js-export-html
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I created a text fade using the following website:
http://patorjk.com/text-color-fader/
Is it legal to copy and paste the code generated from this generator onto a website? My website does not have any ads and I don't get any revenue from the website.
Also is it legal to copy and paste one question of a Stackoverflow question javascript code into a website?
Code generators are authoring tools. The owners of the site have the right to restrict who uses it but they do not have copyright of material you create with it. Just as Cannon do not own the photos you make on their cameras or BIC owns the poem you write with their pen. Even if the site says code created via their tool is their copyright, it is not so, it is not enforceable, and may even be illegal.
Copyright falls to the author, and I am unaware of any country that this is not true. Generators are authoring tools.
Different websites can have different licences on the content contributed by users or they present. If you use a tool, it is fine and you own the code. It is like you use an editor to create your own project.
As to Stack Overflow, you can see at the bottom:
"user contributions licensed under cc by-sa 3.0 with attribution required".
So, user posts/answers on Stack Overflow go under the terms of the Creative Commons license. Mostly this is ok, but it may affect/conflict with your software licence.
Generally, you are expected to write your own code but you can still look at Stack Overflow answer/discussion and make your own code instead of copy-pasting.
Especially when it comes to commercial/company projects or any project of which licence is not compatible with this one,
In short, knowledge/experience is not licensed - you can learn and then your can apply that knowledge to make your own code.
It is mostly the case because only small snippets are posted on stackoverflow and it is useful to get insight into the problem puzzling you.
Still, you should honestly show credit/attribution to the idea originator/author etc. if it involves work of somebody.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
I have a website and I teach Java on it.
I know html and css if it helps..
I have lectures in my site and in my lectures there are descriptions: in the description I write code sometimes so I made a class for code so everytime I type code I do and it looks good, but not perfect.
I want to make specific words to be bold and in blue or pink color for example.
Is there a way to do it? maybe with javascript?
I know I can create a new class for special words and then to do for example but this will be too much job to write this span every time that it's not worth it.
So is there a way to do it maybe with html5 or js? Thank you.
edit: I use the usefedora.com platform so it's more difficult to do it, does somebody knows how to do it on usefedora's platform?
the thing you are searching for is a codemirror. There are many codemirrors but only one of them is called codemirror.
Code Mirror
There are also solutions that don't require you to write any javascript, using web components.
Prism.js
Here is one that's insanely trivial to use
There are plenty of code to html converters which do syntax highlighting if that's what your looking for e.g.
http://tohtml.com/java/
or
http://hilite.me/
You can take this HTML and use it on your site.
You can also download a jQuery plugin. SyntaxHighlighter is very popular.
The way they work is that you copy the files to your website, and then you just put your code into a tag, and the plugin automatically beautifies your code.
I would recommend choosing one of these libraries- PrismJS, Highlight.js, or Rainbow.
Each is designed for exactly this purpose. You just put your code into the web page, inside an HTML5 code tag decorated with the language name. They will automatically format your code with the necessary markup to attach color styles to. No need for any external tools. The first two provide their own styles as well, the last assumes you'll write your own.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
I am developing a javascript application. Rite now i am using E text editor
http://www.e-texteditor.com
I have used UltraEdit also but i found E-text editor better.
I want to know if there is any other editor more powerful than E-text editor?
and what better facilities it has?
What editor should you use? Vim of course! I mean Emacs!
I mean, seriously. There is nothing more personal for a programmer than a choice of his editor. Not even the choice of his language is more personal so I doubt you'll get any meaningful answers other than "You should use my favorite editor! Because it's the best." "No, you should use mine! Because it's better."
Unless you just want to see a flame war then, well, have fun.
I don't think you'll really find an editor specifically geared towards js, I think you've found what I would choose if you are stuck on a windows platform ;)
I personally use TextMate which is what E-texteditor is modeled after, and if you can harness the specific bundles for any given language you can have some real productivity increases. You can find framework specific bundles also that include snippets, shortcuts, etc...
But the thing I like about editors like these, there isn't so much automation that you loose touch with the language. At its core it's still a text editor.
Well i also was looking for a better Javascript editor for some time. However I finally ended up with Aptana since i noticed that is pretty much supportive with Javascript developments.
Obviously it's not an editor but an IDE which is a derivative of eclipse. The thing is that there are lots of libraries and frameworks for Javascript so we can't expect that our editor or IDE is supported with all these.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 2 years ago.
Improve this question
Does anyone know about a tutorial that lets you to create something like pageflakes.com for your website? In jquery perhaps?
The creator of PageFlakes, Omar al Zabir, has created an open-source web portal called DropThings. Can't get any more similiar to PageFlakes than that!
You can use the UI library from jQuery where you'll find the draggable elements with grid. Besides that you only need to set and read some cookies that determine the position of each of the boxes.
Let's say your layout has 4 <div>s. Just save each id and position in a cookie (from javascript or by performing an AJAX request to a php/asp page).
Displaying the page is also pretty easy, you have to have 2 possibilities: when the user has a cookie defined, or else (this would be the default). If the user has a cookie defined, read it and position the <div>s like the cookie says, it shouldn't be too hard to do this.
This article on CodeProject has an excellent tutorial on how to build almost exactly what you're after, except that it uses ASP.Net Ajax. You would easily be able to substitute that with jQuery though.
.nettuts has an example all done in jquery and jquery ui. Here's the link:
http://net.tutsplus.com/tutorials/javascript-ajax/inettuts/
Goes through it all in very nice detail too. It won't be a direct copy of pageflakes, that's an exercise left for the reader but it does show exactly how to start.
HTH!
Check out ExtJS's Panels. They're what's used to build this pageflakes look-alike:
http://extjs.com/deploy/dev/examples/portal/portal.html