Title: Shortcode Custom CSS Still Not Saving
Last modified: March 31, 2022

---

# Shortcode Custom CSS Still Not Saving

 *  Resolved [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * (@dcbuffalo)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/)
 * The previous thread for this issue ([https://wordpress.org/support/topic/shortcodes-in-accordion-not-displaying-any-data-2/](https://wordpress.org/support/topic/shortcodes-in-accordion-not-displaying-any-data-2/))
   is marked as RESOLVED, but it is not resolved.
 * This is STILL an issue with v2.3.3. I have to sit on v2.2.8 still because otherwise,
   it wipes everything out upon save – settings and custom CSS, and the front-end
   does not incorporate either the settings OR the custom CSS. Once I rollback the
   plugin, the data magically reappears and everything works, front-end and back-
   end, without having to restore the database.
 * I have tested and tested. It’s just the plugin.
 * Can we please have a fix to this problem?
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fshortcode-custom-css-still-not-saving%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 15 replies - 1 through 15 (of 17 total)

1 [2](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/page/2/?output_format=md)

 *  [Praveen](https://wordpress.org/support/users/praveenmalav09/)
 * (@praveenmalav09)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15516229)
 * Hi [@dcbuffalo](https://wordpress.org/support/users/dcbuffalo/),
 * Which custom CSS you are implementing in additional CSS also you can implement
   custom CSS in the customizer section.
 * Thanks
 *  Thread Starter [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * (@dcbuffalo)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15518149)
 * Yes, I could move all of the accordion CSS to another CSS location. But I have
   a lot of accordions, and I only want the individual accordion CSS to load in 
   if that accordion is in use. A lot of the CSS generated by the accordion plugin
   codes it specifically to shortcode ID numbers, so I have general CSS that affects
   ALL accordions and specific CSS for each accordion. Plus, that doesn’t solve 
   the problem that saving also wipes out settings.
 * THERE IS A BUG. IT NEEDS TO BE FIXED.
 *  [Praveen](https://wordpress.org/support/users/praveenmalav09/)
 * (@praveenmalav09)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15522865)
 * Hi [@dcbuffalo](https://wordpress.org/support/users/dcbuffalo/),
 * Please go to Plugins > Plugin editor and select Responsive Accordion and Collapse
   plugin and go to front > style.php on line number 151 replace the below code 
   with another code.
 * `<?php echo esc_attr($custom_css); ?>`
 * To
 * `<?php echo $custom_css; ?>`
 * If it works let us know
 * Thanks
 *  Thread Starter [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * (@dcbuffalo)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15524782)
 * That fixed some of the front-end display CSS, but not all. PLUS, all of the custom
   CSS still disappears on the back-end when I save an accordion.
 * The scariest part to me is that my last move with the latest version of the plugin
   was to save custom CSS to a test accordion, and it was STILL GONE when I used
   WP Rollback to return to 2.2.8. So if I were to save one of the accordions that
   was actually in use, I would lose all of my custom CSS for that accordion.
 * This is a very destructive bug!
 *  [Praveen](https://wordpress.org/support/users/praveenmalav09/)
 * (@praveenmalav09)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15527044)
 * Hi [@dcbuffalo](https://wordpress.org/support/users/dcbuffalo/),
 * The above solution is for the front end now we give you a back end solution. 
   So please go to plugins > plugin editor and select Responsive Accordion and go
   to lib folder > admin
    > data-post > ac-settings-save-data.php file on line number
   23 and replace the below code with the new code.
 * `$custom_css = sanitize_textarea_field($_POST['custom_css']);`
 * To
 * `$custom_css = stripslashes($_POST['custom_css']);`
 * If it works let us know
 * Thanks
 *  Thread Starter [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * (@dcbuffalo)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15529888)
 * That actually appears to have worked! AT LONG LAST!!
 * Let me know when this pushes to the live version, and I’ll be sure to make sure
   it updates and still works.
 *  [Praveen](https://wordpress.org/support/users/praveenmalav09/)
 * (@praveenmalav09)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15538765)
 * Hi [@dcbuffalo](https://wordpress.org/support/users/dcbuffalo/),
 * Glad that your issue has been resolved if you like our plugin please rate us.
   This issue comes only in rare cases so try to avoid updates if you keep your 
   custom CSS.
 * Thanks
 *  Thread Starter [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * (@dcbuffalo)
 * [4 years, 2 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15540399)
 * I don’t want to avoid plugin updates. That can cause other problems.
 * Does this solution for me cause problems for other people? If not, why not just
   push these changes to the next update?
 * If you can’t push these changes to the next version, will these two changes solve
   the problem in future updates?
 * I honestly don’t understand why you would not fix an issue that is impacting 
   core functionality like this, even if it’s rare.
 *  [preetam27](https://wordpress.org/support/users/preetam27/)
 * (@preetam27)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15553566)
 * hi,
 * we will update it if this issue occurs with other users as well.
 * thanks
 *  [yukitopia](https://wordpress.org/support/users/yukitopia/)
 * (@yukitopia)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15553616)
 * It does affect me and I’m sure it affects many others who use CSS to style the
   accordion content.
 * I’m not sure I understand the reluctance to fix a known issue with an update.
 *  [Praveen](https://wordpress.org/support/users/praveenmalav09/)
 * (@praveenmalav09)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15554541)
 * Hi [@yukitopia](https://wordpress.org/support/users/yukitopia/),
 * Please provide the custom CSS code you are using so we can check it.
 * Thanks
 *  [yukitopia](https://wordpress.org/support/users/yukitopia/)
 * (@yukitopia)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15556839)
 * The problem is that the custom CSS won’t save. It would also erase all the front
   end settings if you put anything in the custom CSS box and try to save. It doesn’t
   matter what custom CSS I put in there.
 * But here is the custom CSS I tried to add:
 * .pullquote {
    margin: 1em 0; line-height: 1.4; color: #999; padding-left: 10%;
   padding-right: 10%; }
 * p {
    font-family: ‘Lato’; color:#666; font-weight:400; line-height:1.6; margin:
   0 0 28px 0; }
 * p a {
    color:#00828c; text-decoration:none; }
 * p a:hover {
    color:#00828c; text-decoration:underline; }
 *  Thread Starter [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * (@dcbuffalo)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15556866)
 * Right, so it’s affecting other people. My guess is lots of people just delete
   your plugin and use another one. That wouldn’t be a practical solution in our
   case. If I have to, I will update and continue to make these two changes to the
   template files. But obviously, if your solution fixes it AND doesn’t break it
   for other people, not sure why you wouldn’t put that bug fix into your release
   cycle.
 *  [Praveen](https://wordpress.org/support/users/praveenmalav09/)
 * (@praveenmalav09)
 * [4 years, 1 month ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15560619)
 * Hi [@yukitopia](https://wordpress.org/support/users/yukitopia/),
 * We have applied the CSS code you shared and it is saved in our custom CSS.
 * Thanks
 *  Thread Starter [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * (@dcbuffalo)
 * [4 years ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/#post-15700385)
 * THIS IS HAPPENING AGAIN IN v.2.3.4.
 * Please fix.
 * Or was I still expected to change the other code on my own? Why wouldn’t you 
   just update the code in the plugin?
    -  This reply was modified 4 years ago by [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/).

Viewing 15 replies - 1 through 15 (of 17 total)

1 [2](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/page/2/?output_format=md)

The topic ‘Shortcode Custom CSS Still Not Saving’ is closed to new replies.

 * ![](https://ps.w.org/responsive-accordion-and-collapse/assets/icon-128x128.png?
   rev=2339019)
 * [Accordion FAQ - Compatible With All Page Builder (Elementor, Gutenberg)](https://wordpress.org/plugins/responsive-accordion-and-collapse/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/responsive-accordion-and-collapse/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/responsive-accordion-and-collapse/)
 * [Active Topics](https://wordpress.org/support/plugin/responsive-accordion-and-collapse/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/responsive-accordion-and-collapse/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/responsive-accordion-and-collapse/reviews/)

 * 17 replies
 * 4 participants
 * Last reply from: [dcbuffalo](https://wordpress.org/support/users/dcbuffalo/)
 * Last activity: [3 years, 10 months ago](https://wordpress.org/support/topic/shortcode-custom-css-still-not-saving/page/2/#post-15884218)
 * Status: resolved