Support » Plugin: Simple Custom CSS and JS » Impossible to delete plugin completely

  • Resolved mgroening



    I have a lot of problems with the plugin and want to uninstall and reinstall it for testing purposes.
    The problem is: It seems to be impossible to remove all files created with this plugin (html, css, js).
    Every time I reinstall the plugin all of my files reappear in the UI.

    I tried deleting the Browser cache and WordPress Cache and deleted the uploads/custom-css-js folder (which wasn’t removed).
    Without success.

    The reason why I want to delete everything is because the plugin doesn’t work properly.
    – when I want to create new code and click on Publish I get the message: “The link you followed has expired.” If I clear the cache it works again, but after a while the message appears again when I want to publish new code.
    – sometimes I can’t delete code in the UI. It says that the file doesn’t exist anymore (like someone else in this forum mentioned)
    – some of my codes don’t show up in the UI. (only if I change the filter to the date when I created them)
    – sometimes I can’t deactivate code. Nothing happens when I click on Deactivate.
    – in the Browser Inspector Console appears an error message pointing to a css file in uploads/custom-css-js that doesn’t exist anymore

    So it is really messed up and I don’t know why.
    I also tried to deactivate my other plugins but it doesn’t help.

    So how can I remove everything that belongs to this plugin, including all html, css and js files I created with it?

Viewing 14 replies - 1 through 14 (of 14 total)
  • Plugin Author Diana Burduja


    You can delete the plugin by clicking the “Uninstall” link next to the plugin’s name on the WP Admin -> Plugins page. Nothing else is necessary.

    Yes, I tried that multiple times and it uninstalls the plugin but all of my code remains.
    It seems like my html/css/javascript code is kind of corrupted. And it causes the plugin to crash everytime when I use it.
    I think this behaviour started after I tried to publish a very big css file in this plugin.
    Do you have any recommendation what else I can do to repair the plugin?
    Maybe you can reproduce the problem by uploading a huge file.

    • This reply was modified 9 months, 2 weeks ago by mgroening.
    Plugin Author Diana Burduja


    What do you mean by “all my code remains”? Do the custom codes added with the plugin still show up in the frontend even if the plugin is uninstalled? It sounds like there is a caching on some level.

    And by “the plugin crashes everytime you use it” do you mean you get a white screen when editing a custom code or the “The link you followed has expired” error you referred in the first message?

    The “The link you followed has expired” error is thrown by WordPress core. Often when trying to upload a big theme. See this article for a solution.

    How big was the “very big css file” you tried to add with this plugin? More than 20M? By default PHP is configured with Apache to have the “post_max_size” variable equal 20M. Of course that depends on your hosting.

    Yes, with “crashes” I mean these messages. In my case I think it was caused by the upload of that big file. Big in the sense of many lines (3200 lines, but only 80 kb). Sorry, I forgot to describe it in more detail.
    I also tried to increase post_max_size, but it did not resolve the issue.

    I found out that my code is also in the database under posts. Everytime I create a new file it gets stored there and is also created in the uploads/custom-css-js directory.
    Except html files: they are not stored in uploads/custom-css-js. I think that is intended, right?

    I don’t know why but sometimes the post id in the link for editing or deleting a custom css/js/html doesn’t match the post id in the database. So I get error messages, like “The link you followed has expired” or “The file doesn’t exist anymore…”
    (e.g. post id 99 in the link: but it is 101 in the database)

    So I cleaned up my database, but the plugin is still not working correctly.
    If I create e.g. a new css it does not show up in the “All custom codes” section. I have to change the filter to “CSS Codes” to see my new file.
    And I cleared the cache and reinstalled the plugin again, but still…

    • This reply was modified 9 months, 2 weeks ago by mgroening.
    Plugin Author Diana Burduja


    The plugin is based on the WordPress custom post types functionality. Therefore the custom codes are stored in the database in the “posts” table.

    The link to edit or delete a custom code is non built within the plugin, but created from WordPress core with this custom post types functionality. Just like the “All custom codes” page. All these things work alright on 200,000+ websites and I don’t know under which circumstances could I reproduce your errors on my test website. So I cannot “repair the plugin” when I cannot brake it on my test website.

    Something clearly got messed up on your website. And you want to uninstall the plugin. What is the problem there? Why can’t you achieve that? You say that “all the code remains”. Where does it remain?

    With “all the code remains” I mean that after I reinstall the plugin all of my custom code (created with the plugin) reappears in the UI. But as soon as I want to edit or delete them a message shows up and tells me that the file doesn’t exist anymore.

    So I deleted all posts (with post_type: custom-css-js), postmeta and an option entry called custom-css-js-tree:
    179.css, 178.html and 78.css were the three scripts that always showed up in the UI even if they don’t exist anymore.
    After that I reinstalled the plugin and cleared my cache again.
    Now they don’t show up again.

    When I publish a new custom code it still doesn’t show up in the “All custom codes” table.
    And when I first published a new custom css and published a second custom css after that. The first one gets overwritten. It used in fact the same post_id.

    I’m using:
    Wordpress Version 5.2.2

    PHP Version 7.2

    OceanWP Version 1.6.10

    Anywhere Elementor Version 1.1
    Elementor Version 2.6.8
    Formidable Forms Version 4.02.01
    Ocean Extra Version 1.5.10
    Ocean Stick Anything Version 1.0.2
    Simple Custom CSS and JS Version 3.27
    UpdraftPlus Version 1.16.16
    Wordfence Security Version 7.3.6
    WP Extra File Types Version 0.4.3
    WP Fastest Cache Version
    Yoast SEO Version 11.8

    Tell me if you need more information.

    Plugin Author Diana Burduja


    Ok, so you managed to delete the codes. That was what you wanted, right?

    Yes, to see whether it resolves the other issues.
    They are the same as posted by simoptim one week ago.
    So, hopefully the problem will be resolved.

    Thanks for your fast answers!

    Plugin Author Diana Burduja


    Installing the plugins and theme from your list didn’t break the plugin on my test website. It also doesn’t break when adding a large CSS custom code.

    If you create a new page from WP Admin -> Pages -> Add New and then add a second new page, does it overwrite the previously created page or not? Could you test the same with posts from WP Admin -> Posts -> Add New?

    Another thing you can do is to see if new entries are added in the database when trying to add a new custom code. Try the following:
    – open the database
    – run the select ID, post_date, post_title from wp_posts query notice the last ID in the list
    – open the WP Admin -> Custom CSS & JS -> Add Custom CSS page, but don’t click the “Publish” button yet
    – run the SQL query again. Is there a new entry in the table with a new ID and with “Auto Draft” as title?

    When I create or delete a new page everything works just fine. The table with all of my pages looks also correct.

    When I run the query after I create a new custom css without publishing I can’t see any new entry. There is no “Auto Draft”. When I publish it the message “The link you followed has expired” shows up.
    The permalink (when creating a new custom css) always shows /uploads/custom-css-js/202.css at the end. But 202.css already exists. Editing the permalink and publishing then also results in: “The link you followed has expired”.
    The only fix I have found is to refresh the “Add CSS Code” page. After that it shows 223.css which is also the next free post_id in the database. Then it also creates an “Auto Draft” and publishing works.

    There are no problems with javascript: When I run the query after I create a new custom javascript without publishing I can see a new entry “Auto Draft”. And when I publish it, the “Auto Draft” gets deleted and there is a new entry with my javascript.

    Any idea?

    Plugin Author Diana Burduja


    Would you run the following SQL query in the database: “desc wp_posts”? Make a screenshot or copy/paste the results of the query so I can have a look at it.

    Plugin Author Diana Burduja


    Let’s see if there is some caching involved on the way: if you type directly in the browser (without hitting enter) and then add “&v=1” at the end or the URL, does it add a new CSS custom code or does it replace a previous custom code?

    Sorry for the late answer.
    It just opens an “Add CSS Code” page and creates an Auto Draft in the database.
    It does not replace previous css code.

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Impossible to delete plugin completely’ is closed to new replies.