John Dimick
Forum Replies Created
-
Forum: Plugins
In reply to: [Ocean Custom Sidebar] Add Custom Sidebar to Posts Page?Solved. I see now that I didn’t have the sidebar ID correct in the functions.php file. I had omitted the “ocs” in “ocs-sidebar-test”. It works fine now.
Thanks again, Amit.
Forum: Plugins
In reply to: [Ocean Custom Sidebar] Add Custom Sidebar to Posts Page?“Have you added any widget in your custom sidebar?”
Yes, I have added a widget to the “sidebar-test” custom sidebar:
https://www.guitarist.com/wp-content/uploads/2019/06/sidebar-widget.png
“Have you added the correct sidebar id?”
Do you mean have I added the correct sidebar ID to the functions.php in the child theme? I think so, since it appears under Theme Panel > Sidebar. Here is the code in functions.php:
<?php add_action( 'wp_enqueue_scripts', 'my_theme_enqueue_styles' ); function my_theme_enqueue_styles() { $parent_style = 'parent-style'; // OceanWP style wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' ); wp_enqueue_style( 'child-style', get_stylesheet_directory_uri() . '/style.css', array( $parent_style ), wp_get_theme()->get('Version') ); } #Attempt at homepage custom sidebar function prefix_custom_sidebar( $sidebar = 'sidebar' ) { if ( is_home() ) { $sidebar = 'sidebar-test'; } return $sidebar; } add_filter( 'ocean_get_sidebar', 'prefix_custom_sidebar' ); ?>
Is there someplace else to add the correct sidebar ID?
- This reply was modified 5 years, 5 months ago by John Dimick.
Forum: Plugins
In reply to: [Ocean Custom Sidebar] Add Custom Sidebar to Posts Page?Thank you for a timely reply, Amit.
I added your code to functions.php in the child theme.
In the code, I changed ‘your-sidebar-id’ to ‘sidebar-test’.
The result was an additional sidebar — “sidebar test” — added to the list of available sidebars. Nothing happened on the homepage, which still shows the default sidebar. I see no way to assign a different sidebar to the homepage.
-John
Forum: Themes and Templates
In reply to: [OceanWP] Make YouTube Embedded Video Show on Blog Entries Page?“Did you select the Video format instead of the standard?”
The three video posts were created in the Twenty Nineteen theme, which does not have an option for Video Format.
So I created an additional post in OceanWP, using “video format” and oEmbed.
Results: IT WORKED! Thank you very much, Amit.
However, the previous video posts, created in Twenty Nineteen, must be changed to video format and oEmbed one by one, it seems. My main blog on Guitarist.com has a hundred video posts going back to 2006. It would be a big job to manually update all those old posts to video format and oEmbed, one at a time.
Forum: Themes and Templates
In reply to: [OceanWP] Make YouTube Embedded Video Show on Blog Entries Page?My latest attempt to debug:
1. Installed WP into an empty new domain, Snarklets.com. The default theme is Twenty Nineteen.
2. Added three new videos posts. All three videos show correctly on the blog using Twenty Nineteen theme:
https://screenshotscdn.firefoxusercontent.com/images/aecf9932-440b-4f44-b052-eac242acb2b6.png
3. Installed and activated OceanWP, making no other changes to the site, and reloaded the site. Result: Videos no longer display on the blog. Where the videos should be, there is simply the URL in text.
https://screenshotscdn.firefoxusercontent.com/images/2a504d1e-c559-4ea0-b944-40afda84c7ad.png
What can be the problem?
Forum: Themes and Templates
In reply to: [OceanWP] Make YouTube Embedded Video Show on Blog Entries Page?And how did you position Title below the video but above the text?
I used Customize > Blog > BlogEntries > ElementsPositioning to place Content on top, which puts the video on top, but placing Title below Content puts the Title below the text, since text is part of Content.
Forum: Themes and Templates
In reply to: [OceanWP] Make YouTube Embedded Video Show on Blog Entries Page?Thank you, Amit. Yes, that is what I want: A video at the top of each blog entry, then the title, then a text excerpt below. I don’t know why it doesn’t work on my site: https://www.ukeist.com
I wonder if it has to do with my URL having http instead of https?…
Forum: Themes and Templates
In reply to: [OceanWP] Make YouTube Embedded Video Show on Blog Entries Page?Ocean extra is installed. YouTube link is embedded.
You say it works on your end. Can you please give me a link to see that, to verify we are talking about the same thing?
Forum: Themes and Templates
In reply to: [OceanWP] Make YouTube Embedded Video Show on Blog Entries Page?Disabled all plugins, no help. Videos display on single-post pages, but not on blog homepage. PHP version is 7.1.
PS. Videos display just fine on my main site’s blog page, using Twenty Ten: https://www.guitarist.com/blog/
Forum: Themes and Templates
In reply to: [OceanWP] Make YouTube Embedded Video Show on Blog Entries Page?Thanks for the reply, Amit.
I don’t have an admin page that looks like your screenshot.
Forum: Fixing WordPress
In reply to: Trouble with permalinks and .htaccessToo complicated. Giving up. Will just leave the .html on.
Forum: Fixing WordPress
In reply to: Trouble with permalinks and .htaccessI had to change this topic back to Unresolved. Hope that’s ok.
Yesterday’s fix worked fine, as far as it went, but it returns a 404 if there’s a .html extension involved. All the external links to my posts over the past 10 years have the .html extension.
After digging into this site, there seems to be a consensus that adding the following to .htaccess is the fix:
RedirectMatch 301 /\d{4}/\d{2}/(.*)\.html https://example.com/$1
I tried that, but forgot to replace example.com with my domain, so it redirected to example.com. Literally. So I replaced example.com with my domain and tried again — and still was redirected to example.com.
Caching problem?
My blog is https://www.guitarist.com/blog . I’m leaving the post permalinks set for .html for now, but I’d like to be able to strip that extension away.
Oh, and I tried the reset trick several times.. ??
Forum: Fixing WordPress
In reply to: Trouble with permalinks and .htaccessWhoa, waitaminnit! I just switched back to custom permalinks and everything is working now! Switching to “plain” and back did the trick. Cool. Thank you. ??
Forum: Fixing WordPress
In reply to: Trouble with permalinks and .htaccessLet me be more specific: every external link with an old permalink structure redirects to the home page (prolly because of 301 redirects higher up in the htaccess). The just-now-configured default permalinks work as they should.
Forum: Fixing WordPress
In reply to: Trouble with permalinks and .htaccessJust tried that. Every permalink, new or old, now redirects to the site home page. Also, no change is seen in the .htaccess file.