Title: Suffusion stop loading wp-admin.php
Last modified: August 19, 2016

---

# Suffusion stop loading wp-admin.php

 *  [spotcream](https://wordpress.org/support/users/spotcream/)
 * (@spotcream)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/)
 * IS there a way to stop the theme Suffusion from loading all of its javascript
   and css on every page of the admin section.
 * Could it be limited to the pages that actually require the scripts and css obviously
   i know some of the http request would be needed on most pages but do we really
   need it all the time even if im just browsing to add new plugins.
 * The theme is extremely good but could do with a small modification to cut down
   the http requests in the admin section.
 * Sayontan
 * Please dont take this as a knock on how much i like the theme just for me i am
   trying to clean up the admin.
 * Just wish more plugin developers made things easier on admin overhead. (not that
   im not gratefull).
 * If anyone is prepared to help me clean this up i will give you a nice link or
   review of your site.

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

 *  [Sayontan Sinha](https://wordpress.org/support/users/sayontan/)
 * (@sayontan)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1498811)
 * I will look into this and try to fix it in the next version. Thanks for the input.
 *  Thread Starter [spotcream](https://wordpress.org/support/users/spotcream/)
 * (@spotcream)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1498904)
 * Thank you sayontan your a star.
 *  Thread Starter [spotcream](https://wordpress.org/support/users/spotcream/)
 * (@spotcream)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1498906)
 * can anyone help fix it for me
 *  [Sayontan Sinha](https://wordpress.org/support/users/sayontan/)
 * (@sayontan)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1498996)
 * It will need a few significant changes on your side. If you don’t mind, waiting
   for next version might be a good idea. I have already fixed it my end and am 
   in the process of bundling it with some other changes. I should be done a few
   days at the most.
 *  Thread Starter [spotcream](https://wordpress.org/support/users/spotcream/)
 * (@spotcream)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1499023)
 * yeah thanks sayontan the problem im faced with is i cant upgrade the site as 
   i have made changes to alot of things. My knowledge of php is limited so i have
   hard coded the files.
 * I know this is alot to ask but do you have a detailed change log of what code
   you add and what you removed so people that cant do an auto upgrade are able 
   to manually change the required files.
 * most of the chages i have made are specific such as combining css files and changing
   some php calls etc..
 *  [Sayontan Sinha](https://wordpress.org/support/users/sayontan/)
 * (@sayontan)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1499042)
 * Given that the theme offers capabilities to add both, custom CSS and custom PHP,
   I must say that you went down a path that was a general time-sink since the theme’s
   approaches would have been completely upgrade-proof.
 * There is a change log which says what I have changed in terms of features, but
   it doesn’t say which file or which line was changed. For that you have to resort
   to using programs like WinMerge.
 *  [Sayontan Sinha](https://wordpress.org/support/users/sayontan/)
 * (@sayontan)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1499047)
 * I don’t, by a rule support older versions, so the instructions I am giving you
   here will not be valid for porting future releases.
 * The way to tackle this is through some major changes, like using the `admin_head-{
   $hook_suffix}` variable hook instead of the `admin_head` hook. For this you have
   to do a bunch of things like moving the add_action calls around. A summary of
   the changes for 3.4.8 are as follows:
    1. In functions.php open the function 
   suffusion_add_admin and change this line:
 *     ```
       add_theme_page($themename." Theme Options", "".$themename." Theme Options $update_available", 'edit_themes', basename(__FILE__), 'suffusion_admin');
       ```
   
 * to:
 *     ```
       $suffusion_theme_options_page = add_theme_page('Suffusion Theme Options', "Suffusion Theme Options $update_available", 'edit_themes', basename(__FILE__)), 'suffusion_render_options');
       ```
   
 * Immediately after this, add the following lines:
 *     ```
       add_action("admin_head-$suffusion_theme_options_page", 'suf_admin_header_style');
       	add_action("admin_print_scripts-$suffusion_theme_options_page", 'suffusion_admin_script_loader');
       ```
   
 * Delete these lines from outside this function call:
    `add_action('admin_head','
   suf_admin_header_style');` and `add_action('admin_print_scripts', 'suffusion_admin_script_loader');`
 * Be very careful while you make these changes and be sure to have a backup of 
   functions.php before you begin. Errors can render your dashboard inaccessible.
 *  Thread Starter [spotcream](https://wordpress.org/support/users/spotcream/)
 * (@spotcream)
 * [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1499058)
 * Yes i agree its a slippery slope but had to be done as my sites download was 
   nearing 1mb with 150 http calls taking a very longtime to download i have a sister
   site that is an exact copy of the main (just blocked from view) when i get chance
   i will try and figure the php to add it all in correct.
 * As for css i had to edit it manually as when files are merged and minified the
   aperance goes out of whack.
 * But thank you very much for your help i will give it a go now.

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

The topic ‘Suffusion stop loading wp-admin.php’ is closed to new replies.

## Tags

 * [HTTP](https://wordpress.org/support/topic-tag/http/)
 * [suffusion](https://wordpress.org/support/topic-tag/suffusion/)

 * 8 replies
 * 2 participants
 * Last reply from: [spotcream](https://wordpress.org/support/users/spotcream/)
 * Last activity: [16 years ago](https://wordpress.org/support/topic/suffusion-stop-loading-wp-adminphp/#post-1499058)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
