kinna28
Forum Replies Created
-
Forum: Plugins
In reply to: [Constant Contact Forms] Multisite support?I came across a strange instance of this. Developing on localhost (https://local.dev) on WAMP with a multisite install, activated the plugin per site. It still brought up only the title option and then errored out on any post edit/settings page with this:
PHP Fatal error: Uncaught exception 'GuzzleHttp\Ring\Exception\RingException' with message 'cURL error 60: SSL certificate problem: self signed certificate in certificate chain' in C:\wamp\www\wordpress\wp-content\plugins\constant-contact-forms\vendor\constantcontact\guzzlehttp\ringphp\src\Client\CurlFactory.php:127
I tried the same install on a live single site install using the same theme/plugins and it worked fine. Neither localhost nor the live site had SSL set up at the time. The single site install, however, did not throw a single error and brought up all of the editor fields. I set up a self-signed cert for localhost (https://local.dev, which makes Chrome have a fit) and it suddenly works fine even with a multisite install.
Just weird…
- This reply was modified 7 years, 10 months ago by kinna28.
I was able to change them using the SU Settings > Custom CSS area using this (beware, it’s ugly):
.su-table td { padding: 1em 2em !important; border: 1px solid #666 !important; background: #97cfd4 !important; } .su-table .su-even td { background: #d0d0d0 !important; }
The Custom CSS area overrides the SU default styling because it always loads it after, even if it’s denoted as !important.
Which specific shortcode/element/class are you trying to restyle?
Forum: Plugins
In reply to: [WP Shortcodes Plugin — Shortcodes Ultimate] Spoiler open on hoverYou would have to change line 4 in shortcodes-ultimate/assets/js/other-shortcodes.js
$('body:not(.su-other-shortcodes-loaded)').on('click', '.su-spoiler-title', function (e) {
to this:
$('body:not(.su-other-shortcodes-loaded)').on('mouseover', '.su-spoiler-title', function (e) {
But the timings (transitions, etc.) will be weird.
Keep in mind that your code change will be reset if the plugin updates.Yes, it should. The shortcodes as you wrote them on the pages won’t change, as uninstalling the plugin won’t change page or post contents. It will just make [su_posts] exist on the page while it’s not running.
I’ve had to reinstall the plugin a few times over the last few years and I just back up my custom CSS from the SU settings before reinstalling. Also make sure that any custom files (templates, etc.) are safely backed up away from the SU plugin folder so you can reinstall the plugin using the WP panel, and then just replace the files once it’s running again.
Also, I’m also on InMotion with Event Espresso (EE4 though) and an SSL cert purchased and installed through InMotion. I share your inevitable frustrations.You might need to add an !important at the end of your CSS rules if it’s going into your style.css
If the shortcodes ultimate stylesheet is loading after your style.css, it can override whatever custom styling you’ve added.
Adding your styling to the shortcodes ultimate Settings > Custom CSS should allow it to re-style as intended, but I have 8 instances in my plugin settings custom CSS where I still had to use !important.Forum: Themes and Templates
In reply to: Add SmartSlider to Perth WordPress themeA quick search got me to here, which I think might be the theme you’re using? https://athemes.com/theme/perth/
If you’re using that, you probably want the slider to take the place of the large blue stripe that’s:
<div class="site-banner">
Because you don’t want to put a slider inside of the <header>, you can put the shortcode into your PHP template like so (though I’m not sure why there’s header-clone?):<?php /** * The header for our theme. * * Displays all of the <head> section and everything up till <div id="content"> * * @package Perth */ ?><!DOCTYPE html> <html <?php language_attributes(); ?>> <head> <meta charset="<?php bloginfo( 'charset' ); ?>"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="profile" href="https://gmpg.org/xfn/11"> <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>"> <?php wp_head(); ?> </head> <body <?php body_class(); ?>> <div class="preloader"> <div class="preload-inner"> <div class="box1 preloader-box"></div> <div class="box2 preloader-box"></div> <div class="box3 preloader-box"></div> <div class="box4 preloader-box"></div> </div> </div> <div id="page" class="hfeed site"> <a class="skip-link screen-reader-text" href="#content"><?php _e( 'Skip to content', 'perth' ); ?></a> <header id="masthead" class="site-header clearfix" role="banner"> <div class="container"> <?php if ( display_header_text() ) : ?> <div class="site-branding col-md-4 col-sm-6 col-xs-12"> <?php perth_branding(); ?> </div> <?php endif; ?> <nav id="site-navigation" class="main-navigation col-md-8" role="navigation"> <?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_id' => 'primary-menu' ) ); ?> </nav><!-- #site-navigation --> <nav class="mobile-nav"></nav> </div> </header><!-- #masthead --> <div class="header-clone"></div> <?php if ( get_header_image() && ( get_theme_mod('front_header_type' ,'image') == 'image' && is_front_page() || get_theme_mod('site_header_type', 'image') == 'image' && !is_front_page() ) ) : ?> <div class="header-image"> <div class="header-overlay"></div> <?php perth_header_text(); ?> </div> <?php endif; ?> <div class="slider-container"> <?php echo do_shortcode('[smartslider3 slider=2]'); ?> </div> <div id="content" class="site-content"> <div id="content-wrapper" class="container">
Note that you’ll need to change the slider ID number to the ID of the one you want to use. By putting the slider inside of a div wrapper, you can set the size (and master styling) of it through your CSS files as usual.
Forum: Plugins
In reply to: [WP Shortcodes Plugin — Shortcodes Ultimate] Pages too longCan you give a link to one of the pages so that we can see what might be going wrong?
It’s probably a CSS issue, but it’s difficult to say.
Try this:
function YOUR_THEME_scripts() { wp_dequeue_style( 'font-awesome' ); wp_deregister_style( 'font-awesome' ); wp_register_style( 'font-awesome', get_stylesheet_uri() . '/font-awesome.min.css', true, THEME_VERSION ); wp_enqueue_style( 'font-awesome' ); } add_action( 'wp_enqueue_scripts', 'YOUR_THEME_scripts', 20 );
Shortcodes Ultimate uses ‘font-awesome’ as the handle to enqueue (you can find the script here: shortcodes-ultimate/inc/core/assets.php) so you just have to call to that in your functions.php with a lower priority than the plugin’s enqueue. Since the default priority is 10, any higher number (lower priority) will load after it.
This is the official documentation on user restriction, but it doesn’t cover conditionals based on shortcode type.
It’s an interesting idea, being able to restrict certain shortcodes based on user type. I’d be keen to find out how to do such a thing!
Forum: Plugins
In reply to: [WP Shortcodes Plugin — Shortcodes Ultimate] modifying the CSSYou can add the styles you want to the custom CSS box in the plugin settings. The best way to do this is to specify a new class for your custom version, and place that in the Class box (or add class=”class-name” to your shortcode in the editor). Then you can call to just that custom type.
Here’s an example:
On your page:
[su_heading class="su-heading-green"]This is a header with green text[/su_heading]
In your Shortcodes Ultimate settings > Custom CSS tab:.su-heading-green { border-top: 1px solid #0d5412; border-bottom: 1px solid #0d5412; color: #33662e; font-weight: bold; } .su-heading-green.su-heading-inner { border-top: 4px solid #538256; border-bottom: 4px solid #538256; }
Notice that I handled two elements, which is because the shortcode creates:
<div class="su-heading su-heading-style-default su-heading-align-center su-heading-green" style="font-size:13px;margin-bottom:20px"> <div class="su-heading-inner">This is a header with green text</div> </div>
The double lines were created by a top/bottom border on both the main element and the inner element, so I accounted for both…and made the font bold just because.
Forum: Plugins
In reply to: [WP Shortcodes Plugin — Shortcodes Ultimate] Changes to CSS?This is probably a matter of the plugin’s shortcode classes interfering with the classes in your theme. I’ve found over time that while it creates elements and classes from the shortcodes, it will also append classes to the parents (which may already exist), which are then handled by the plugin’s stylesheet instead of your theme’s.
Have you tried changing the shortcode prefix for the plugin? You will have to go through your pages and change the shortcode names manually, but that’s more than likely a lot less work than any other alternative.If you know what elements have gone sideways, you can always specify your real styling in the plugin’s custom CSS box. It’s hacky, but it will more than likely work if you’re out of patience/time/options/coffee.
I’m assuming that because you’re referencing FA specifically, you’re not concerned about it being loaded on every page. Which is fine since you want to add it locally, so it will only have to request it from the user’s cache. In the example below, your FA file should go in your theme/css folder.
Here’s WordPress’s official documentation on the matter.
/** * Proper way to enqueue scripts and styles */ function YOUR_THEME_scripts() { wp_enqueue_style( 'font-awesome', get_stylesheet_uri() . '/font-awesome.min.css', true, THEME_VERSION ); } add_action( 'wp_enqueue_scripts', 'YOUR_THEME_scripts' );
Can you give a link to the page(s) where that’s happening? It’s hard to diagnose when we can’t see what’s happening.
Offhand, I would immediately check if there are extra lines in the excerpt of the first post. Since the shortcode is pulling in the excerpt, it might be trying to account for that. If you haven’t specified an excerpt, it will be trying to pull in the content and formatting it as best it can.
I had similar happen before, and I ended up manually overwriting the plugin folder using FTP and the extracted zip download.
NOTE: If you’re using custom files (I have a few custom templates), then be sure to have those on-hand so you can transfer them back into the folders! Also be aware of the custom CSS box in the plugin settings. I like to save the contents locally for safe-keeping until after the plugin is tested.