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


Quick Go »
Thread Status: Normal
Total posts in this thread: 4
[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 7309 times and has 3 replies Next Thread
halomotaf
New Member



Joined: Aug 24, 2014
Posts: 4
Status: Offline

Edit this Post   embed mini-cal after dom loaded Reply to this Post
Reply with Quote
[Delete this Thread]

hi
i am embedding the mini cal in my site' and it takes too much time to load, and preventing the site itself from being loaded
so i tried to load the calendar only after dom loaded, and didn't find how

could you help please ?

thanks
amir
[Sep 7, 2014, 9:42:07 PM] [84.108.186.133] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
jasonsullivan
Veteran
Member's Avatar


Joined: Feb 7, 2014
Posts: 92
Status: Offline
Edit this Post   Re: embed mini-cal after dom loaded Reply to this Post
Reply with Quote
[Delete this Post]

Could you provide a link to the page on your site where it is embedded?
----------------------------------------
Jason Sullivan
Support Associate
Localendar.com
[Sep 11, 2014, 1:16:39 AM] [71.68.14.180] Show Post Printable Version    Hidden to Guest [Link] Report threatening post: please login first  Go to top 
halomotaf
New Member



Joined: Aug 24, 2014
Posts: 4
Status: Offline

Edit this Post   Re: embed mini-cal after dom loaded Reply to this Post
Reply with Quote
[Delete this Post]

http://halomotaf.co.il/
[Sep 20, 2014, 9:02:28 PM] [84.108.186.133] 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: 6396
Status: Offline
Edit this Post   Re: embed mini-cal after dom loaded Reply to this Post
Reply with Quote
[Delete this Post]

This is just a thought I had...
First, in the two places you include <script> tags supplied by localendar, replace them with something like this:
<div id="placeholder1">&nbsp;</div>
<div id="placeholder2">&nbsp;</div>

Then at the bottom of your page, try something like this:

<script>
var script1 = document.createElement('script');
script1.src = "http://www.localendar.com/js/PublishedIncludeMini.js";
document.getElementsById("placeholder1").appendChild(script1);

var script2 = document.createElement('script');
script2.src = "http://www.localendar.com/public/halomotaf?include=Y&style=M5";
document.getElementsById("placeholder2").appendChild(script2);
</script>


Disclaimer; I haven't tested that yet, but it seems like it might work...

BTW, can I ask how you achieved the result of reversing the calendar automatically?
----------------------------------------
Marc Higgins
Support Associate, localendar.com
Follow us on Twitter! http://www.twitter.com/localendar_news
[Sep 22, 2014, 11:09:04 PM] [24.189.166.198] Show Post Printable Version [Link] Report threatening post: please login first  Go to top 
[Show Thread Printable Version] [Post new Thread]

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