mbri
Forum Replies Created
-
Hi I have copied your code on my functions.php file, I have edit it as following to add a icon:
// Only show Phone Number if not empty. function em_customplaceholder_show_phone($replacement, $EM_Booking, $result) { global $EM_Event; if( $result == '#_ccShowPhone' ) { $show_phone = $EM_Booking->output('#_BOOKINGPHONE'); if( !empty($show_phone) ) { $replacement = '<i class="material-icons phone-klant-ico">'.'contact_phone'.'</i>'.'Phone Number: '.$show_phone.'<br/>'; } else { $replacement = ''; } } return $replacement; } add_filter('em_booking_output_placeholder', 'em_customplaceholder_show_phone', 1, 3 );
The icon and the text: ‘Phone Number:’ are not showing, the phone number is showing. what am I doing wrong?
Also I am trying to do the same for the comments, so I have adjusted your code as follows:
// Only show Comments in bookings if not empty. function em_customplaceholder_show_comm($replacement, $EM_Booking, $result) { global $EM_Event; if( $result == '#_ccShowComm' ) { $show_comm = $EM_Booking->output('#_BOOKINGCOMM'); if( !empty($show_css) ) { $replacement = '<i class="material-icons phone-klant-ico">'.'info'.'</i>'.'Extra info: '.$show_phone.'<br/>'; } else { $replacement = ''; } } return $replacement; } add_filter('em_booking_output_placeholder', 'em_customplaceholder_show_comm', 1, 3 );
Also here what am I missing? Thanks!
Hi Patrick thanks a lot, I will give it a try and let you know how it went.
CheersHello the tips about the printed version was a good enough workaround.
You can see the results here: https://drive.google.com/file/d/1GDAb4PvFQt_gmw2KBjXrXCm8eek1RRFV/view?usp=sharing
I have a little challenge, there is no conditional placeholder for phonenumber and extra comments on the booking, how I can hide those 2 fields if they are empty?
I have checked the tutorial on conditional placeholder but the example is too difficult for me ?? still learningCheers
It is working perfectly thanks a lot Patrick! If you like and have time we could have a coffee/tea somewhere in Den Haag. I can easily reach the center or the beach. Cheers
Hi Patrick yes, in the front-end. I ll try that and let you know. Thanks a lot for your prompt reply!
Hi Patrick just an update, I have added the link to the printable view to my customized events.php file so now it is working as I wanted it. I have started customizing the template of the printable view to move away from a table so it can be responsive.
As soon as I am done I am going to post the result. That was a great tip/idea you gave me thanks a lot!
This is a workaround that for now is acceptable, still I would appreciate some directions (not only from you of course but also from some of the Events Manager team) on how to override the EM_Bookings_Table{} class that is in the em-bookings-table.php file without loosing changes at any updates OR how to create a template like the mybookings.php one, but then showing the bookings that a user has received for all his/her events keeping the filtering options.
Thanks!Hi Patrick. forcing my target users to use a laptop is not an option. Have you seen the mobile version I have created? I believe is suited. You gave me a brilliant idea with using the printable view, since that one has a template I can modify. I will give it a shot and post the result.
Where should I add the snippet you shared for the button? I would like to have that button/link on the events.php file (this https://drive.google.com/file/d/1001gLd7ySkbbez5tvA93IymZMZo4aWS5/view?usp=sharing is the mobile version i made) so when my user click on the icon face it will see the printable view instead of the ugly admin table ??Hi Patrick thanks a lot again for your replies and the tip,
Let me show you some views I have made on mobile, i believe it is worth the effort, and I am up to write all needed css, no problem with that.
Basically what I would like to achieve is to rewrite the class EM_Bookings_Table{} to making it output a div instead of a table.
https://drive.google.com/file/d/1001gLd7ySkbbez5tvA93IymZMZo4aWS5/view?usp=sharing
that is how I changed the default table into a div keeping actions link and using icons, I think is usable on mobile.https://drive.google.com/file/d/10BWSnFEJcEUCqyyYRi-y5eyFonpGhdls/view?usp=sharing this one is how I changed the mybookings.php template again into a series of div making it usable for people attending events do view nd manage their booking from their phone as it should be in 2019
The same result I would like to achieve “rewriting” or overriding the table that gets created in the EM_Bookings_Table{} class in the em-bookings-table.php file. I would not like to have to modify the file and have to upload it again every update.
An alternative could be create a template like the mybookings.php one, but then showing the bookings that a user has received for its events, with actions buttons.
I am happy to share my templates and css code for the mobile
- This reply was modified 6 years, 2 months ago by mbri.
Hi Patrick thanks a lot for your replies!
Basically I would like to have a custom view of those admin pages. That view need to be responsive so not in a table. As mentioned I have identified where those tables gets created, in the em-bookings-table.php file which is located in the classes folder.
Any idea on how to create a custom view/template for those admin pages?
No need to be fancy, just an overview of all bookings received with contact info.
CheersHello Patrick, i am just starting laying down the foundations – is a dev site, yes I know the pagination is not ok on desktop, I am focusing on mobile (hence the need to move avay from the booking table overview and have a flex-box one), after the mobile version is polished I ll tackle the desktop one. I live in The Hague by the way ??
- This reply was modified 6 years, 2 months ago by mbri.
Hello Patrick thanks for the prompt reply, yes I know, if you see at the bottom I am saying I can provide the login details, I don’t really feel to post them here.
I made some screenshots of the pages I would like to customize
general bookings table: https://drive.google.com/file/d/1WXFhfymwz4S0v_umvMBRAzBjweOv6lTZ/view?usp=sharing
bookings overview per event: https://drive.google.com/file/d/1JQX0nnq9YKOs_qNRWr0pccHbIk9QhShY/view?usp=sharing
bookings overview per client / user: https://drive.google.com/file/d/1WOrySrPdx7nRGhWf-lVvaNUaUtYDZH-G/view?usp=sharing
As mentioned I believe those tables gets created by the em-bookings-table.php file in the classes folder, but I was not able to overwrite that template or find a template in the template folder.
Cheers
Forum: Plugins
In reply to: [Interactive Content – H5P] Support for LearnDash frontend@icc0rz i think I did not explain myself well.
I would like to know if you plan to have your button functining outside the media_button_contex and/or if you had any tips on how to achieve that.
Thanks!Forum: Plugins
In reply to: [BuddyPress for LearnDash] Issue with group privacy settingsHi thanks for the Reply. I understand. That does not solve the problem that people who have not join the group cannot zee the activity of the group, because the group gets automatically set to private by the plugin. The best is to leave the choice to site owners to decide if the group must ne public or private.
Is there any work around to achieve that?Forum: Plugins
In reply to: [BuddyPress for LearnDash] Issue with group privacy settingsHi thanks for the prompt Reply. We are building a community around social learning, so we would like to link a group with a course but keep the group public so everyone interested in joining the group and/or the course can read the group activity and get a sense of the learning that is happening among group members. Any work around to make a group with a linked course public?
That will really help.
Thanks!Forum: Plugins
In reply to: [Interactive Content – H5P] Support for LearnDash frontend@icc0rz thanks for your reply!
Yes the frontend work outside the wpdashboard on a wp page. If you can make the button working outside the dashboard that would be awesome! If not any other advice is appreciated.
Cheers