• Resolved xrisxal2000

    (@xrisxal2000)


    Hi guys, amazing plugin
    pls tel me how can i add quotes automatically in guest reviews…?
    for example instead of:
    It was an amazing stay in EOPV in Kerames, rethymno. i really enjoy every day and of course the magificent view.
    to be
    “ It was an amazing stay in EOPV in Kerames, rethymno. i really enjoy every day and of course the magificent view. ”

    Many Thanks!!

Viewing 1 replies (of 1 total)
  • Plugin Author Marcel Pol

    (@mpol)

    /*
    * Change the content of the saved message.
    */
    Hi,
    I assume you mean you want it added automatically for each new message, right?
    Because it already should be able to save quotes that were added manually in the textarea.
    Does this code work for you?
    It is PHP code and can be added to functions.php of your child theme or to your own plugin.

    function my_quotes_gwolle_gb_save_entry_frontend( $entry ) {
    	// $entry is an object.
    
    	$entry_content = $entry->get_content();
    	$entry_content = '" ' . $entry_content . ' "';
    	$entry->set_content( $entry_content );
    	$entry->save();
    
    }
    add_action( 'gwolle_gb_save_entry_frontend', 'my_quotes_gwolle_gb_save_entry_frontend' );
Viewing 1 replies (of 1 total)
  • The topic ‘Quotes in Gwole Guest book’ is closed to new replies.