Html editor in description field not working.

This topic contains 15 replies, has 4 voices, and was last updated by  Kiran 4 years, 7 months ago.

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

Open Support Ticket
  • Author
    Posts
  • #530431

    Tania Perez
    Full Member
    Post count: 299

    Hi guys,

    For some reason the html editor in the description field is not working, it only works in troubleshoot. It was working fine until the most recent update.

    I deactivated and activated every plugin, changed theme, and it´s still not working.

    Could you please take a look, and see if you can help?

    Thank you!

    #530433

    Tania Perez
    Full Member
    Post count: 299
    This reply has been marked as private.
    #530446

    Alex Rollin
    Moderator
    Post count: 27815

    Please see:
    https://wpgeodirectory.com/docs-v2/places/custom/#advanced

    If that doesn’t fix the issue please let us know more about the situation.

    #531023

    Tania Perez
    Full Member
    Post count: 299

    Hi Alex,

    Let me explain, depending on the package the html editor is enabled or not for business owners. Free package, for example is not enabled.

    But the problem is in the admin area, I should be able to edit with HTML, even if it´s a free listing, so that I can work on my SEO.

    So I´d like the users on free listings NOT to use the HTML editor, but enable it for the admin. That´s the way it was working before the last update.

    Thanks

    #531264

    Alex Rollin
    Moderator
    Post count: 27815

    I see, I will ask the developers to look into that.

    #531343

    Kiran
    Moderator
    Post count: 7069

    Hi Tania,

    I checked with choosing following packages on front-end add listing and as expected description field shows WITHOUT HTML editor. Following packages has HTML editor is disabled from settings.

    – GRATIS
    – BASICO LUGARES
    – EMPRENDE LUGARES

    I checked with choosing following packages and as expected description field shows WITH HTML editor. Following packages has HTML editor is NOT disabled from settings.
    – PRO LUGARES
    – PREMIUM LUGARES

    Do you want HTML editor for description field for admin user even editor is disabled from package settings?

    Let us know.

    Regards,
    Kiran

    #531519

    Tania Perez
    Full Member
    Post count: 299

    Thank you Alex and Kiran,

    Exactly, for admin user, HTML editor should be enabled, even if the package is disabled for the user in font-end.

    Thanks

    Tania

    #531524

    Kiran
    Moderator
    Post count: 7069

    Hi Tania,

    Try following PHP snippet.

    
    
    /**
     * Always enable HTML editor to description field for admin user.
     */
    function gd_snippet_allow_html_editor_to_admin( $allow, $field ) {
    	if ( ! empty( $field['name'] ) && $field['name'] == 'post_content' && current_user_can( 'manage_options' ) ) {
    		$allow = true;
    	}
    
    	return $allow;
    }
    add_filter( 'geodir_custom_field_allow_html_editor', 'gd_snippet_allow_html_editor_to_admin', 99, 2 );
    
    function gd_snippet_pricing_allow_html_editor_to_admin( $disable_editor, $package_id ) {
    	if ( $disable_editor && current_user_can( 'manage_options' ) ) {
    		$disable_editor = false;
    	}
    
    	return $disable_editor;
    }
    add_filter( 'geodir_pricing_disable_html_editor', 'gd_snippet_pricing_allow_html_editor_to_admin', 20, 2 );

    Thanks,
    Kiran

    #532965

    Tania Perez
    Full Member
    Post count: 299

    Hi Kiran,

    It didn´t work 🙁

    Could you check it out again?

    Thank you!

    #532980

    Guust
    Moderator
    Post count: 29970
    This reply has been marked as private.
    #536825

    Tania Perez
    Full Member
    Post count: 299
    This reply has been marked as private.
    #536836

    Kiran
    Moderator
    Post count: 7069

    Hello Tania,

    In backend content field is not restricted to use HTML editor for content field. This is default field for post content and it available for all post types. If HTML added by admin then it will display it HTML tags at front-end.

    Thanks,
    Kiran

    #537157

    Tania Perez
    Full Member
    Post count: 299

    Thank you Kiran, it´s not working, that´s the problem. I can see it, but changes are not made as shown in the images I sent. Once I publish or update the listing all changes made in html are not saved.

    Hope you can help

    Thank you

    Tania

    #537408

    Kiran
    Moderator
    Post count: 7069

    Hello Tania,

    Please provide us FTP credentials so i can check there and also provide us listing url to check.

    Kiran

    #542684

    Tania Perez
    Full Member
    Post count: 299
    This reply has been marked as private.
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