• Resolved bcupham

    (@bcupham)


    Hi,

    Our site has generated hundreds of path-based critical css rules because we didn’t have 404-based tag rule in place. Rather than delete these one by one, I wanted to export our settings, delete the unnecessary rules and re-import. However, I am having trouble making this work. I do not see any instructions on how to import settings. Do I import just the settings.json file, or should I unzip the export zip, make the changes I want and then zip it back up again and import that? If the import has hundreds of css files, is it possible that trying to import them will time-out in PHP?

    Thank you,
    Ben

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Optimizing Matters

    (@optimizingmatters)

    you should alter the contents of the zipfile and re-upload that. the CSS-files are not parsed but simply stored on the FS, so I don’t think this should cause issues.

    an alternative could be to get the autoptimize_ccss_rules WordPress option (json_encoded), change things in there and then re-save it?

    Thread Starter bcupham

    (@bcupham)

    an alternative could be to get the autoptimize_ccss_rules WordPress option (json_encoded), change things in there and then re-save it?

    What does this refer to? Is it a feature of AO or another plugin? Or a code snippet?

    Thanks,
    Ben

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    well, wordpress core comes with options which can be get/ set with get_option() and update_option(). autopitmize uses that (as many plugins do) to store options and one of those options AO stores is autoptimize_ccss_rules. so if you get that out of the database (or through PHP) and update the json_encode-ed array, then you could clean out the rules that way.

    Thread Starter bcupham

    (@bcupham)

    Ok thanks.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Importing settings’ is closed to new replies.