Mitch Canton

Forum Replies Created

Viewing 8 posts - 136 through 143 (of 143 total)
  • Author
    Posts
  • in reply to: Shortcodes in listing tabs #290337

    Mitch Canton
    Expired Member
    Post count: 167

    I do now have shortcodes working in ‘text’ fields.

    After some trial and error and error, 🙂 I also figured out a way to add a second tab (by simply adding something like this):

    
    
    add_filter('geodir_tab_show_geodir_newest','my_enable_shortcodes_on_field_2',10,2);
    function my_enable_shortcodes_on_field_2($html, $variables_array){
       return apply_filters('the_content', $html);
    }

    That is probably totally NOT the right way to do it, so please LMK a better way to do multiple tabs.

    Lastly, the placement of shortcode in these new areas do NOT render the related content in the “Details Page Sidebar” when that area is selected in the ‘Show in what locations’ box. How to I resolve?

    Thanks!

    in reply to: Shortcodes in listing tabs #290275

    Mitch Canton
    Expired Member
    Post count: 167

    Hey Guust,

    Thanks for taking a look. I’m having quite a runaround with that redirect issue you mentioned, but I think I’ve got it figured. Back to the shortcodes first.

    I was told that shortcodes could work in text/textarea fields. I was sent here: https://gist.github.com/Stiofan/00ce073d12a1df0c6f4d8f413936bd71
    during a presales email thread, which gives:

    
    
    <?php
    function my_enable_shortcodes_in_cf($html,$location,$cf){
      
        // this line will enable it for all text inputs
        $html = do_shortcode( $html );
        return $html;
    }
    add_filter('geodir_custom_field_output_text','my_enable_shortcodes_in_cf',15,3);
    

    Is this not the case?

    And with respect to your html CF code, if I were to have multiple extra tabs for shortcodes, would I then need to change the code you have in item (2) to somehow add those?

    Thank you.

    in reply to: Shortcodes in listing tabs #289321

    Mitch Canton
    Expired Member
    Post count: 167
    This reply has been marked as private.
    in reply to: Shortcodes in listing tabs #289319

    Mitch Canton
    Expired Member
    Post count: 167
    This reply has been marked as private.
    in reply to: Shortcodes in listing tabs #289317

    Mitch Canton
    Expired Member
    Post count: 167

    Hi Kor,

    No, I was referring to the posts I had linked. But that post provided much of the same info. So I started from scratch, with the code you supplied there (in functions.php), but it still does not apply the shortcode to the fields. I have tried in both at text and textarea.

    I’m not sure why it is not working, so you can have a look and see what I may have done wrong.

    Thanks.

    in reply to: Sort of categories in widget #288464

    Mitch Canton
    Expired Member
    Post count: 167

    Hmmm. Yeah, I was logged in. I was on this page:

    https://wpgeodirectory.com/docs/category/core/

    and when I clicked on the link (for Core Shortcodes), it sent me to a Not Found page. I just did it and it happened again.

    See the attached screencap for the link (lower left) that it directs to when I hover / click on ‘Core Shortcodes’ link.

    fwiw, I just loaded the initial page in firefox/not logged in, and it gives a good link. I’ll clear cache in chrome and start fresh. That was just weird and I thought I’d give a heads up.

    I’m only on Day Two of the plugin, so I’m still feeling my way around all the docs. 🙂

    Thanks again.

    in reply to: Sort of categories in widget #288452

    Mitch Canton
    Expired Member
    Post count: 167

    Got it.

    I was also trying to see if I could place that with parameters via a shortcode (and sort the cat titles) – but doesn’t look like it?

    Just a fwiw, when I was searching for core shortcodes, landed on this page: https://wpgeodirectory.com/docs/category/core/

    but then the ‘core shortcodes’ link 404’s – looks likes it’s missing the /docs/ part in the URL. I eventually found it, but just a heads up on the bad link. (Looks like the Custom Fields link does the same).

    Thanks for your help. Have a good day.

    in reply to: Sort of categories in widget #288443

    Mitch Canton
    Expired Member
    Post count: 167

    Thank you. As I tested more, I see that changing place categories (for example quantity of places in the PPC) changes the order of the category names. I understand.

    However, what if I wanted to sort those in a specific order? Like with a WP post I can set an order attribute. How can I sort the category names different? Whether A-Z, or orderid, or whatever.

    Thanks.

Viewing 8 posts - 136 through 143 (of 143 total)