|
Index | Recent Threads | Register | |
Forums » List all forums » Forum: Webmaster's Corner » Thread: Change CSS on Add EVent Button |
Total posts in this thread: 12
|
[Change thread status]
[Delete this Thread]
[Move this Thread] [Add To My Favorites] [Watch this Thread] [Post new Thread] |
Author |
|
Beulahland
New Member
|
Were planning on using the schedule module but would like to change the button to both not show on the "list view" and match the CSS used on the site for other locations. There's no mention of the CSS hooks for that particular button, can I override it? Thanks in advance |
||
|
support
localendar Expert Joined: Aug 9, 2022 Posts: 6421 Status: Offline |
To clarify, you do want the Add Event button shown on certain views, but not others (like the list view)? And you also want to be able to use CSS to alter the appearance of the button? ---------------------------------------- Marc Higgins Support Associate, localendar.com Follow us on Twitter! http://www.twitter.com/localendar_news |
||
|
Beulahland
New Member
|
That would be correct. |
||
|
support
localendar Expert Joined: Aug 9, 2022 Posts: 6421 Status: Offline |
You can paste some javascript/jquery on your calendar footer to accomplish this (under Options->General) For example, if you paste this, it will only hide the Add Event on the month list view: <script>$( document ).ready(function() {$('.view_style_M1 #add_event').hide();});</script> But let's say to want to hide it everywhere except the month view. You could use this: <script>$( document ).ready(function() {$('#add_event').hide();$('.view_style_M0 #add_event').show();});</script> The button has the id "add_event", so you can style it with that hook using the CSS on your page, or again with a little script. Here's come code that only shows it on the M0 view, and also changes the color to red <script>$( document ).ready(function() {$('#add_event').hide().css("background-color","red");$('.view_style_M0 #add_event').show();});</script> I hope that gets you started! Let me know if you have further questions. ---------------------------------------- Marc Higgins Support Associate, localendar.com Follow us on Twitter! http://www.twitter.com/localendar_news |
||
|
Beulahland
New Member
|
Awesome! Thank you very much! |
||
|
Beulahland
New Member
|
My attempts at using the code provided failed. I've put the code(s) in the footer but have not seen any changes. Now the only thing I have in my footer is - <style>.mj-usr{display:none;}</style> (This still works) Thanks for the help |
||
|
Beulahland
New Member
|
*bump*
|
||||
|
support
localendar Expert Joined: Aug 9, 2022 Posts: 6421 Status: Offline |
You had the "Allow Visitors to Add Calendar Events" feature turned off under Options->General. I have turned it on. Otherwise, the Add Event button will never be shown (no matter what) Now, with the full code set on your Footer(which was already there when I checked) the button is only shown on the M0 view. It is hidden on the day and week views for example. You might also want to clear your browser cache just to make sure you aren't seeing an old version of the page. Please let me know if that doesn't get things working correctly :) ---------------------------------------- Marc Higgins Support Associate, localendar.com Follow us on Twitter! http://www.twitter.com/localendar_news |
||
|
Beulahland
New Member
|
Thank you for the response. I see that the code works in the server side views but, does the opposite on the embedded side views. The embedded month view hides the button and shows it in the embedded list view. |
||
|
support
localendar Expert Joined: Aug 9, 2022 Posts: 6421 Status: Offline |
If you can send me links to the pages where you're using embedded views, I'd be happy to take a look. ---------------------------------------- Marc Higgins Support Associate, localendar.com Follow us on Twitter! http://www.twitter.com/localendar_news |
||
|
|
[Show Thread Printable Version] [Post new Thread] |
Help! | Cobranding | Legal | Privacy Policy | About localendar.com | Contact Us |