How to assign the default file at “Appearance > Editor”?

Unfortunately you can’t control what files are loaded on that page… But you can disable the editor page and provide the user with theme options that allow him to include his own CSS. To deal with this I’m creating and activating a child theme automatically if possible: if(!is_child_theme()){ require_once(ABSPATH.’wp-admin/includes/file.php’); if(!WP_Filesystem()){ // fail, proably no write-access, … Read more

Show post thumbnail only if it exists using timthumb

As commented above, you don’t have to use TimThumb at all to get additional image sizes for your uploaded images. WordPress ships with the add_image_size() function. // functions.php add_action(‘init’, ‘wpse26655_add_additional_image_sizes’); function wpse26655_add_additional_image_sizes() { add_image_size(‘thumb200x120’, 200, 120, true); } In your template files, you could than query your thumbnail with your desired image size. E.g. <?php … Read more

How to reuse parts of WordPress site e.g. header, footer, part of header for multiple WordPress sites?

I would think that your best bet is option 3 (multisite) if possible. Once you’ve got your network of sites set up you can then specify which menu to use as described here. Doing the other solutions (a more rough and ready ‘hardcoded’ approach) will almost certainly give you headaches in the future. Having multisite … Read more

Toolbox theme using printif statement – help needed understanding code block

The % signs are arguments in the string to be formatted. The s represents a string type argument must be passed. I’ve notated which arguments are connected to which strings being passed in. get_permalink() – %1 string type get_the_date( ‘c’ ) – %2 string type get_the_date() – %3 string type get_author_posts_url( get_the_author_meta( ‘ID’ ) ) … Read more

WordPress Subpages Fancybox Trouble

So, if I understand your question correctly, your problem is that your iframes are showing the theme (nav menu, sidebar, etc.) and you don’t want them to. If that’s the case, I’d recommend creating a new Page Template that is styled after your bio iframe (no menus, no sidebar). There’s more info on creating custom … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)