mad_griffith
Forum Replies Created
-
Forum: Plugins
In reply to: [Disable Gutenberg] Custom wp_editor not saving.
- This reply was modified 5 years, 8 months ago by mad_griffith.
Forum: Plugins
In reply to: [Cloak Front End Email] Subject parameter in shortcode?Sorry, I forgot to apply the code formatting. I meant this:
<a href="[email name=”cfe-example” subject=”My Email Subject Line”]" target="_blank">My <span style="color: yellow">Text</span></a>
Forum: Plugins
In reply to: [Cloak Front End Email] Subject parameter in shortcode?I think it depends on what you want to have on the page. My customer doesn’t want a form, because they’d rather have an illustration with the mailto link.
Anyway, I was trying the shortcode within the following formula in Visual Composer (text field module):
<a href="[email name=”cfe-example” subject=”My Email Subject Line”]" target="_blank">My <span style="color: yellow">Text</span></a>
The shortcode is not being parsed correctly and in general it doesn’t seem to be compatible with that kind of situation.
There are other ways I can try of course, but I was wondering if something could be done from the plugin side.
- This reply was modified 6 years, 7 months ago by mad_griffith.
- This reply was modified 6 years, 7 months ago by mad_griffith.
Forum: Plugins
In reply to: [Cloak Front End Email] Subject parameter in shortcode?Wow, you’re fast man! Thank you so much.
What about adding support for all possible email fields?- This reply was modified 6 years, 7 months ago by mad_griffith.
Forum: Developing with WordPress
In reply to: Rewriting URL to be in the “/category/page” formUhm, I don’t seem to get it!
How would you have some-cpt/my-page/ and some-cpt/my-category, provided some-cpt is the same cpt across both?
Forum: Developing with WordPress
In reply to: Rewriting URL to be in the “/category/page” formOk, thanks.
I am now thinking along the lines of:
mysite.com/my-custom-post-type/my-page
Considering that my-custom-post-type will have children categories as well, is the above allowed in WP?
- This reply was modified 7 years, 1 month ago by mad_griffith.
Forum: Developing with WordPress
In reply to: Rewriting URL to be in the “/category/page” form@kjodle, how would you approach a case in which you need to have a page with static content on it and that page needs to appear in the URL as a category’s descendant?
@bcworkz, isn’t that function just adding a category as a taxonomy of page? I need the opposite to happen. Page should be the category’s descendant. But maybe I am not evaluating your suggestion correctly…
Thank you guys,
NForum: Installing WordPress
In reply to: WordPress 4.1 Update 404 Error Return on PagesYeah, I did it yesterday, right after asking here first. Hope somebody’s going to reply soon.
Forum: Installing WordPress
In reply to: WordPress 4.1 Update 404 Error Return on PagesMine is the case of a direct WP 4.1 installation… I didn’t update it from a previous version.
Forum: Installing WordPress
In reply to: WordPress 4.1 Update 404 Error Return on PagesI asked because I haven’t changed my htaccess (it is still the default one) an thought you have customized yours.
I also have already ruled out the permalink settings’ issue by playing with it the way you just described.
Anyway, I have to make clear that the 404 not found error occurs only with pages (I have pages both with and without custom templates). Categories and posts work fine.Forum: Installing WordPress
In reply to: WordPress 4.1 Update 404 Error Return on PagesDoesn’t work for me ?? What is the content of your htaccess, dickbfield?
Forum: Fixing WordPress
In reply to: Permalinks not working for pages/pages of postsI am realizing I have categories and pages of posts with the same slug: I ultimately want to display pages of posts on my website, so I tried to delete one category with slug “lezioni” to see if that was the problem, but the page with slug “lezioni” is still not working… so apparently that’s not the cause.
Forum: Installing WordPress
In reply to: WordPress 4.1 Update 404 Error Return on PagesHi lynluo, can you please post you htaccess? I have the same issue. Thank you.
Forum: Fixing WordPress
In reply to: Understanding how do pageofposts custom fields workI am self-marking this as resolved
Forum: Fixing WordPress
In reply to: Understanding how do pageofposts custom fields workOk, I will answer to my own question. I don’t know whether this is the most elegant/quicker code or not, but this is a working solution code for anybody in need. I commented to make it more understandable.
N.B. The code only works if your page slugs have a matching category slug (a choice I went for in order to keep my taxonomy naming consistent).<?php // gets the current page slug global $page_id; $page_slug = get_post( $page_id )->post_name; // gets the current category slug by matching all the cats' slugs against the current page slug $cat_args=array( 'hide_empty' => 0 ); $categories = get_categories($cat_args); foreach ($categories as $category) { $category_slug = $category->slug; if ($category_slug == $page_slug) : ?> <?php // uses the current category slug to query posts $args = array( 'category_name' => $category_slug ); $list_of_posts = new WP_Query( $args ); ?> <?php if ( $list_of_posts->have_posts() ) : ?> <?php while ( $list_of_posts->have_posts() ) : $list_of_posts->the_post(); ?> <?php get_template_part( 'content', 'store-product' ); ?> <?php endwhile; ?> <?php else : ?> <?php get_template_part( 'content', 'none' ); ?> <?php endif; ?> <?php endif; ?> <?php }; // foreach ?>