Giter Site home page Giter Site logo

wysihtml is not defined about wysihtml HOT 12 OPEN

astroxoom avatar astroxoom commented on July 29, 2024
wysihtml is not defined

from wysihtml.

Comments (12)

Globulopolis avatar Globulopolis commented on July 29, 2024

Check url to wysihtml.js
Open Developer console, switch to network tab and reload page. Filter by Javascript.

from wysihtml.

astroxoom avatar astroxoom commented on July 29, 2024

Sorry for late reply.

I've also put the wysihtml javascript files below the jQuery.

Here is the statistics (in particular order) [note that all time is 0ms]
jquery.min.js
wysihtml.js
wysihtml-toolbar.min.js
advanced.js
bootstrap.min.js

from wysihtml.

Globulopolis avatar Globulopolis commented on July 29, 2024

@astroxoom see
clipboard02

If you see 0 in "Transferred" or "Size" column it's because script isn't loaded at all.

from wysihtml.

astroxoom avatar astroxoom commented on July 29, 2024

image

@Globulopolis

from wysihtml.

Globulopolis avatar Globulopolis commented on July 29, 2024

@astroxoom try to disable any cache for test.

from wysihtml.

astroxoom avatar astroxoom commented on July 29, 2024

@Globulopolis I disabled it (when DevTools is opened) but still it is undefined, sorry for the late comment tho.

from wysihtml.

astroxoom avatar astroxoom commented on July 29, 2024

I changed

        $(function() {
            var editor = new wysihtml.Editor("wysihtml-textarea", {
              toolbar:      "wysihtml-toolbar",
              parserRules:  wysihtml5ParserRules
            });
        });

to:

        (function($) {
            var editor = new wysihtml.Editor("wysihtml-textarea", {
              toolbar:      "wysihtml-toolbar",
              parserRules:  wysihtml5ParserRules
            });
        });

There is no error anymore. However, the textarea is not displaying so well, even the toolbar is not showing up.

from wysihtml.

Globulopolis avatar Globulopolis commented on July 29, 2024

Hmmm... This is my code for editor and toolbar(using bootstrap for some menus and famfamfam iconpack for buttons)
http://demo.киноархив.com/static/wysihtml/

from wysihtml.

astroxoom avatar astroxoom commented on July 29, 2024

I updated my jquery and bootstrap javascript files, used jQuery(document).ready(function($){...});, and now I can use CTRL+B to bold text around my text-area, but now I cannot use the toolbar. Cannot read property 'querySelectorAll' of null

from wysihtml.

Globulopolis avatar Globulopolis commented on July 29, 2024

@astroxoom can you provide a demo of you code? Or jsfiddle example.

from wysihtml.

astroxoom avatar astroxoom commented on July 29, 2024

I replaced the wysihtml, all-commands, table_editing, toolbar with the one provided in the dist folder.

Now this errors came up, checked Network tab in Google Chrome, they have status of 200 which means OK.
image

from wysihtml.

astroxoom avatar astroxoom commented on July 29, 2024

Note that I didn't build this from npm, just cloned the repository then copied the files from the dist folder over to my own dist folder.

from wysihtml.

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.