Welcome Guest   | Login   
  Search  
  Index |  Recent Threads |  Register | 


Quick Go »
Thread Status: Normal
Total posts in this thread: 12
Posts: 12   Pages: 2   [ 1 2 | Next Page ]
[Change thread status] [Delete this Thread] [Move this Thread]
[Add To My Favorites] [Watch this Thread] [Post new Thread]
Author
Previous Thread This topic has been viewed 314 times and has 11 replies Next Thread
Beulahland
New Member



Joined: Mar 3, 2020
Posts: 9
Status: Offline

Edit this Post   confused   Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Thread]

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
[Mar 15, 2020, 8:06:53 PM] [206.168.45.233] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
support
localendar Expert
Member's Avatar


Joined: Aug 9, 2022
Posts: 6421
Status: Offline
Edit this Post   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

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
[Mar 20, 2020, 8:50:52 PM] [69.126.188.124] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
Beulahland
New Member



Joined: Mar 3, 2020
Posts: 9
Status: Offline

Edit this Post   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

That would be correct.
[Apr 2, 2020, 9:13:32 PM] [206.168.45.233] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
support
localendar Expert
Member's Avatar


Joined: Aug 9, 2022
Posts: 6421
Status: Offline
Edit this Post   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

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
[Apr 5, 2020, 11:58:39 PM] [69.126.188.124] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
Beulahland
New Member



Joined: Mar 3, 2020
Posts: 9
Status: Offline

Edit this Post   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

Awesome! Thank you very much!
[Apr 7, 2020, 5:51:17 PM] [206.168.45.233] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
Beulahland
New Member



Joined: Mar 3, 2020
Posts: 9
Status: Offline

Edit this Post   confused   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

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
[Apr 9, 2020, 3:45:30 PM] [206.168.45.233] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
Beulahland
New Member



Joined: Mar 3, 2020
Posts: 9
Status: Offline

Edit this Post   confused   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

*bump*

 
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

[Apr 14, 2020, 2:47:29 PM] [206.168.45.233] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
support
localendar Expert
Member's Avatar


Joined: Aug 9, 2022
Posts: 6421
Status: Offline
Edit this Post   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

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
[Apr 15, 2020, 8:53:48 PM] [69.126.188.124] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
Beulahland
New Member



Joined: Mar 3, 2020
Posts: 9
Status: Offline

Edit this Post   confused   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

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.
[Apr 16, 2020, 5:22:14 PM] [206.168.45.233] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
support
localendar Expert
Member's Avatar


Joined: Aug 9, 2022
Posts: 6421
Status: Offline
Edit this Post   Re: Change CSS on Add EVent Button Reply to this Post
Reply with Quote
[Delete this Post]

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
[Apr 23, 2020, 7:06:11 PM] [69.126.188.124] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
Posts: 12   Pages: 2   [ 1 2 | Next Page ]
[Show Thread Printable Version] [Post new Thread]

Help! | Cobranding | Legal | Privacy Policy | About localendar.com | Contact Us