Add New Tab Issues

This topic contains 15 replies, has 4 voices, and was last updated by  Alex Rollin 7 years, 1 month ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #419233

    Nik
    Expired Member
    Post count: 36

    Hi Guust,

    Sorry to bug you and your team again. Implementing GD on another site using Enfold Theme, and am having issues with the “Add a New Tab” to the listing page. See attached file for further details.

    I created a tab for the 3D FlipBook – Light Edition plugin. The plugin shortcode does not work in the “Flipbook” content, but it works in the “Profile” content.

    Please refer to the attached file for further details. Below are the codes used. I got them from https://wpgeodirectory.com/add-a-new-tab-in-the-listing-detail-page/

    ————————————————————————————————–
    /*Add a new tab to GD listing page
    */

    add_filter(‘geodir_detail_page_tab_list_extend’, ‘geodir_detail_page_tab_list_extend’) ;
    function geodir_detail_page_tab_list_extend($tab_array) {
    $tab_array[‘my_new_tab’] = array(
    ‘heading_text’ => __(‘Flipbook’,GEODIRECTORY_TEXTDOMAIN),
    ‘is_active_tab’ => false,
    ‘is_display’ => apply_filters(‘geodir_detail_page_tab_is_display’, true,’my_new_tab’),
    ‘tab_content’ => ”);
    return $tab_array ; }

    add_action(‘geodir_after_tab_content’ ,’geodir_my_new_tab_content’);
    function geodir_my_new_tab_content($tab_index)
    {
    if($tab_index ==’my_new_tab’)
    {echo “Flipbook!”;}
    }
    ——————————————————————————————————–

    Am I missing codes? Any suggestions to resolve the issues is greatly appreciated.

    With much thanks,

    Nik

    #419238

    Kor
    Moderator
    Post count: 16516

    Hi Nik,

    Thanks for your reply. Is should work if you’ve followed the steps correctly like this example https://wpgeodirectory.com/formidable-forms-in-geodirectory-tabs/ . Please share the URL of the site in question so we can take a better look at it and also WP temp admin access to your site. You can post the details here using the private reply option below.

    #419401

    Nik
    Expired Member
    Post count: 36

    Hi Kor,

    Appreciate your quick follow up. I prefer not to add another plugin to the site. Below are the tab issues as well as the location switcher issue in mobile view. The site is currently in development. The temp admin access will be sent in private reply following this mail.

    1) NEW TAB ISSUE – How to resolve it? Need to add the new tab, “Flipbook” to all Custom Post Types.

    I took out the codes I inserted yesterday and replace them with the codes below. When I added the codes below to the enfold child theme functions.php I ran into a Parse error: syntax error, unexpected ‘}’

    ——————————————————————————————
    /*Add a new tab to GD listing page
    */

    add_filter(‘geodir_detail_page_tab_list_extend’, ‘geodir_detail_page_tab_list_extend’) ;
    function geodir_detail_page_tab_list_extend($tab_array) {
    $tab_array[‘my_new_tab’] = array(
    ‘heading_text’ => __(‘Flipbook’,GEODIRECTORY_TEXTDOMAIN),
    ‘is_active_tab’ => false,
    ‘is_display’ => apply_filters(‘geodir_detail_page_tab_is_display’, true,’my_new_tab’),
    ‘tab_content’ => ”);
    return $tab_array ; }
    add_action(‘geodir_after_tab_content’ ,’geodir_my_new_tab_content’);
    function geodir_my_new_tab_content($tab_index)
    {
    if($tab_index ==’my_new_tab’)
    {echo do_shortcode(‘[id=”3d-flip-book” title=”false”]’);}
    }

    ———————————————————————————————-

    2) ADD ANOTHER 2 NEW TABS – What are the codes required?

    3) ADD FRANCHISE CHANGE TO ALL CUSTOM POST TYPES. Are the codes below correct?

    function geodir_franchise_change_franchises_tab_text($text, $post_type) {
    if ($post_type == ‘gd_place’,’gd_service’,’gd_lifestyle’) {
    $text = __(‘Branches’, ‘geodir-franchise’);
    }
    return $text;
    }
    add_filter( ‘geodir_franchise_franchises_tab_text’,
    ‘geodir_franchise_change_franchises_tab_text’, 10, 2 );
    function geodir_franchise_change_all_link_text($text, $post_type) {
    if ($post_type == ‘gd_place’,’gd_service’,’gd_lifestyle’) {
    $text = __(‘View all branches’, ‘geodir-franchise’);
    }
    return $text;
    }
    add_filter( ‘geodir_franchise_all_franchises_link_text’,
    ‘geodir_franchise_change_all_link_text’, 10, 2 );
    function geodir_franchise_change_add_link_text($text, $post_type) {
    if ($post_type == ‘gd_place’,’gd_service’,’gd_lifestyle’) {
    $text = __(‘Add Branch’, ‘geodir-franchise’);
    }
    return $text;
    }
    add_filter( ‘geodir_franchise_add_franchise_link_text’,
    ‘geodir_franchise_change_add_link_text’, 10, 2 );

    4) LOCATION SWITCHER DOES NOT WORK IN MOBILE VIEW.

    Thanks for your help.

    Nik

    #419402

    Nik
    Expired Member
    Post count: 36
    This reply has been marked as private.
    #419407

    Nik
    Expired Member
    Post count: 36
    This reply has been marked as private.
    #419492

    Alex Rollin
    Moderator
    Post count: 27815

    Hello,

    I have flagged your question for the developers to see if there is an easy fix. Thanks for your patience while they look into it.

    #419556

    Stiofan O’Connor
    Site Admin
    Post count: 22956
    This reply has been marked as private.
    #419591

    Nik
    Expired Member
    Post count: 36
    This reply has been marked as private.
    #419853

    Nik
    Expired Member
    Post count: 36
    This reply has been marked as private.
    #419869

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    Can u give me the url of a listing where these tabs are supposed to show?

    Stiofan

    #419919

    Nik
    Expired Member
    Post count: 36
    This reply has been marked as private.
    #420010

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    Hi Nik,

    I don’t see any of the tabs on those pages?
    I thought you had added the tabs but they were empty?

    We can’t do customizations for you, we can only help with examples of how to use our filters, which in this case there are many examples of how to use them.

    Stiofan

    #420345

    Nik
    Expired Member
    Post count: 36

    Hi Stiofan,

    Sorry, the tabs were removed. Ran into php errors. I’ve revised the codes and added them back. This time, only one new tab (Flipbook) display, instead of two.

    However, the text or shortcode in the Flipbook tab does not display. Am I missing codes or is the fatal error the cause of the issue. See attached php test.

    WP admin access remain the same. Any suggestions to resolve the issues are much appreciated.

    Thanks,

    Nik

    #420381

    Alex Rollin
    Moderator
    Post count: 27815

    For issues with customization you can contact a GD Expert here:
    https://geodirectoryexperts.com

    #420436

    Nik
    Expired Member
    Post count: 36

    Hi Alex,

    Thanks for responding back. I’m not ready to engage a GD Expert. I have scoured the forum endlessly, and found different codes. Codes on the forum may have changed over time with GD plugin updates.

    All I wanted to know was if the codes are still valid – and if not, are they the cause of the issues – and if there any suggestions to resolve the problems or at least point me to links where I can find a solution to resolve the issues.

    Stiofan was looking into the issues.

    At this point, I’m About to Give Up on GeoDirectory.

    Below are the links I have reviewed for a solution to adding a new tab.

    https://wpgeodirectory.com/add-a-new-tab-in-the-listing-detail-page/
    https://wpgeodirectory.com/support/topic/new-tab-for-custom-field-and-tabs/
    https://wpgeodirectory.com/support/topic/add-a-new-tab-in-the-listing-detail-page/
    https://wpgeodirectory.com/docs/core-place-settings/#fieldset
    https://wpgeodirectory.com/support/topic/adding-new-tab-with-translation/
    https://wpgeodirectory.com/support/topic/adding-new-tab-to-listing-details/
    https://wpgeodirectory.com/re-order-tabs-in-a-listing-detail-page/

    I had assessed many directory plugins and themes before deciding on giving GeoDirectory a try. GeoDirectory’s reviews sold me. https://wpgeodirectory.com/best-wordpress-directory-theme/

    Your initial customer service was great. Guust was excellent.

    If GeoDirectory customer support is unable to assist, let me know ASAP.

    Thanks,

    Nik

Viewing 15 posts - 1 through 15 (of 16 total)

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
20% Discount Offer
Hurry! Get your 20% discount before it expires. Get 20% Discount