Ez a kis kód segít abban, hogy a blokkba helyezett calendar nézet miatt ne kelljen mindig újra újratölteni az oldalt, ha a naptárban lapoz valaki. A kód akkor fog működni ha nem az eredeti calendar modul által létrehozott nézetet használod (amúgy sem módosítunk bele modul által létrehozott nézetbe), hanem klónozod my_calendar néven, majd az eredetit letiltod.
sajat.js file-ba írandó, majd a sminkben hozzáadandó, lusták a page.tpl.php-be is beszúrhatják.
[geshifilter-javascript]
<script type="text/javascript">
$(document).ready(function() {
$.ajaxSetup ({cache: false});
// Display animated loading gif during the load event. Change the "path-to-loader-pic" text to a real path to the ajax-loader.pic
var loading = "<center><img class='loading' src='path-to-loader-pic/ajax-loader.gif' alt='loading...' /></center>";
function nextLoad(){
// Get the nextURL from the pagers next link
var nextUrl = $(".view-display-id-calendar_block_1 .date-next a")[0].href;
// Identify the content/container you wish to replace
$(".view-display-id-calendar_block_1")
// Add the loading image
.html(loading)
.css({ opacity: 0 }).fadeTo("normal",1)
// Load the nextUrl + return the specific content by specifing the css class or id + bind the click function tp the newly loaded //content
.load(nextUrl+ "#block-views-my_calendar-calendar_block_1 .view-display-id-calendar_block_1 .calendar-calendar", bindClick );
};
function prevLoad(){
var prevUrl = $(".view-display-id-calendar_block_1 .date-prev a")[0].href;
$(".view-display-id-calendar_block_1")
.html(loading)
.css({ opacity: 0 }).fadeTo("normal",1)
.load(prevUrl+ "#block-views-my_calendar-calendar_block_1 .calendar-calendar", bindClick );
};
function bindClick(){
$(".view-display-id-calendar_block_1 .date-prev a").click(function(){
prevLoad();
return false;
});
$(".view-display-id-calendar_block_1 .date-next a").click(function(){
nextLoad();
return false;
});
};
// Append the click function to the on the initial page load
bindClick();
});
</script>
[/geshifilter-javascript]
Az eredeti kód innen van: http://drupal.org/node/339279#comment-2006476 viszont ét kellett alakítani, különben naptár oldalon a naptár blokk nem viselkedett valami jó.
Calendar/naptár blokkban lapozás AJAX segítségével
Kategória:
Snippet
Hozzászólások
For hottest news you have to
For hottest news you have to pay a visit internet and on internet I found this web page as a finest web site for newest updates.|
I'm really enjoying the
I'm really enjoying the design and layout of your
website. It's a very easy on the eyes which makes
it much more enjoyable for me to come here and
visit more often. Did you hire out a designer to create your theme?
Superb work!
An outstanding share! I've
An outstanding share! I've just forwarded this onto a friend
who has been doing a little research on this.
And he actually ordered me dinner because I stumbled
upon it for him... lol. So let me reword this....
Thank YOU for the meal!! But yeah, thanks for spending the time to discuss this subject here on your site.
Quality posts is the key to
Quality posts is the key to attract the users to pay a quick visit the site, that's what this web page is providing.|
I pay a visit everyday a few
I pay a visit everyday a few blogs and blogs to read content, except this blog offers quality based posts.
Greetings from Los angeles!
Greetings from Los angeles! I'm bored to tears at work so I decided to check out your blog on my iphone during lunch break. I love the info you present here and can't wait to take a look when I get home. I'm surprised at how fast your blog loaded on my mobile .. I'm not even using WIFI, just 3G .. Anyways, wonderful blog!|
This is the perfect website
This is the perfect website for anyone who wishes to find out about this
topic. You realize so much its almost tough to argue with you (not that I personally would want to…HaHa).
You definitely put a new spin on a topic that's been discussed for a long time.
Great stuff, just great!
It's awesome to go to see
It's awesome to go to see this site and reading the
views of all friends concerning this post, while I am also eager of getting know-how.
I'm really impressed with
I'm really impressed with your writing skills as
well as with the layout on your weblog. Is this a paid theme or
did you modify it yourself? Either way keep up
the excellent quality writing, it is rare to see a nice blog like
this one nowadays.
Good day! I simply want to
Good day! I simply want to offer you a huge thumbs up for the great information you've got here on this post.
I will be returning to your website for more soon.
What's up Dear, are you
What's up Dear, are you really visiting this site regularly, if
so after that you will definitely obtain nice knowledge.
Remarkable! Its genuinely
Remarkable! Its genuinely awesome post, I have got much clear idea about from this paragraph.|
I know this site offers
I know this site offers quality dependent articles and extra stuff, is there any other site which offers these information in quality?|
Heya this is kinda of off
Heya this is kinda of off topic but I was wanting to know if blogs use WYSIWYG editors or if you have to manually code with HTML. I'm starting a blog soon but have no coding knowledge so I wanted to get advice from someone with experience. Any help would be enormously appreciated!|
I really like your blog..
I really like your blog.. very nice colors & theme. Did you make this website yourself or did you hire someone to do it
for you? Plz reply as I'm looking to construct my own blog and would like
to find out where u got this from. appreciate it
Wonderful website. A lot of
Wonderful website. A lot of helpful info here.
I am sending it to some friends ans additionally sharing in delicious.
And certainly, thank you on your sweat!
bookmarked!!, I like your
bookmarked!!, I like your blog!|
Appreciate the
Appreciate the recommendation. Will try it out.|
This site certainly has all
This site certainly has all of the info I needed about this subject and didn't know who to ask.
Hello superb website! Does
Hello superb website! Does running a blog similar to this require a great deal of work?
I've absolutely no expertise in computer programming
but I was hoping to start my own blog soon. Anyways, if you have any
recommendations or tips for new blog owners please share.
I understand this is off subject however I just wanted to
ask. Thank you!
Hi there, all is going nicely
Hi there, all is going nicely here and ofcourse every one is sharing facts, that's in fact fine, keep up writing.|
Spot on with this write-up, I
Spot on with this write-up, I really think this web site needs far more attention. I'll probably be returning to read more, thanks for the info!|
Very rapidly this website
Very rapidly this website will be famous among all blogging and site-building users, due to it's nice content|
Hi! Do you use Twitter? I'd
Hi! Do you use Twitter? I'd like to follow you if that would be ok.
I'm definitely enjoying your blog and look forward to
new updates.
I am regular reader, how are
I am regular reader, how are you everybody? This piece of writing posted at
this web page is genuinely fastidious.
I was suggested this blog by
I was suggested this blog by my cousin. I am not sure whether this post is written by him as nobody else know such detailed about my trouble. You are amazing! Thanks!|
I believe this is among the
I believe this is among the so much vital information for me.
And i am happy studying your article. But should commentary on few basic things,
The website style is great, the articles is truly
great : D. Good task, cheers
Oh my goodness! Impressive
Oh my goodness! Impressive article dude! Many thanks, However I am going through difficulties with your RSS.
I don't understand why I can't join it.
Is there anyone else having similar RSS problems? Anyone who knows the
solution can you kindly respond? Thanks!!
Hey There. I found your blog
Hey There. I found your blog using msn. This is a very well
written article. I'll be sure to bookmark it and come back to read more of your
useful information. Thanks for the post. I'll definitely return.
Pretty nice post. I simply
Pretty nice post. I simply stumbled upon your weblog and wanted to say that I have really loved browsing your weblog posts. After all I will be subscribing on your rss feed and I'm hoping you write again soon!|
Nice blog here! Also your
Nice blog here! Also your site loads up fast! What web host are you
using? Can I get your affiliate link to your host?
I wish my site loaded up as quickly as yours lol
Hi there, i read your blog
Hi there, i read your blog from time to time and i own a similar one and i was just wondering if you get a lot of spam remarks? If so how do you prevent it, any plugin or anything you can suggest? I get so much lately it's driving me insane so any assistance is very much appreciated.|
Simply want to say your
Simply want to say your article is as astounding.
The clearness for your submit is simply excellent and i
could think you're knowledgeable on this subject.
Fine with your permission allow me to take hold of your RSS feed to keep updated with impending post.
Thank you one million and please keep up the enjoyable
work.
Article writing is also a
Article writing is also a excitement, if you be familiar with after that you can write if not it is difficult to write.|
Hi there to every body, it's
Hi there to every body, it's my first pay a quick visit of this website; this weblog carries amazing and truly good material designed for visitors.
Hey! I could have sworn I've
Hey! I could have sworn I've been to this site before but after browsing through some of the post I realized it's new to me.
Anyhow, I'm definitely happy I found it and I'll be book-marking and checking back frequently!
Hi there it's me, I am also
Hi there it's me, I am also visiting this web site daily, this website is actually pleasant and the people are really sharing fastidious thoughts.
Hello to all, how is all, I
Hello to all, how is all, I think every one is getting more from
this site, and your views are good in support of new visitors.
Hi would you mind letting me
Hi would you mind letting me know which webhost you're using?
I've loaded your blog in 3 completely different internet browsers and I must
say this blog loads a lot faster then most.
Can you suggest a good internet hosting provider at a reasonable
price? Cheers, I appreciate it!
My relatives always say that
My relatives always say that I am killing my time here at
net, however I know I am getting know-how all the time
by reading thes good content.
Hello, this weekend is good
Hello, this weekend is good in support of me, since this moment i am
reading this fantastic educational post here at my
house.
Hi! I just would like to
Hi! I just would like to offer you a huge thumbs up for the great info you've got here on this post. I am coming back to your web site for more soon.|
Read lots of usefull tips and
Read lots of usefull tips and trick how to win on online casino here :
https://www.bbd.casino/info_details/cara-menang-baccarat
https://www.bbd.casino/info_details/how-to-register
https://www.bbd.casino/info_details/how-to-deposit
https://www.bbd.casino/info_details/how-to-withdraw
https://www.bbd.casino/info_details/how-to-play-game
https://www.bbd.casino/info_details/how-to-win-online-casino
https://www.bbd.casino/info_details/best-way-to-play-roulette-online
https://www.bbd.casino/info_details/guaranteed-win-online-casino
https://www.bbd.casino/info_details/how-to-win-918kiss-jackpot
https://www.bbd.casino/info_details/best-game-to-play-at-casino
https://www.bbd.casino/info_details/tricks-to-winning-on-slot-machines
https://www.bbd.casino/info_details/malaysia-online-casino-promotion
https://www.bbd.casino/info_details/slot-game-malaysia
https://www.bbd.casino/info_details/online-slots-malaysia
https://www.bbd.casino/info_details/online-betting-malaysia
https://www.bbd.casino/info_details/trusted-online-casino-malaysia
https://www.bbd.casino/info_details/online-gambling-in-malaysia
https://www.bbd.casino/info_details/genting-casino
https://www.bbd.casino/info_details/online-casino-malaysia
https://www.bbd.casino/info_details/best-slot-machines-to-play-2021
https://www.bbd.casino/info_details/best-casino-games-for-beginners
https://www.bbd.casino/info_details/how-are-slot-machines-made
https://www.bbd.casino/info_details/how-do-slot-machine-work
https://www.bbd.casino/info_details/how-to-play-slot-machine-for-beginners
https://www.bbd.casino/info_details/how-to-play-slot-machine
https://www.bbd.casino/info_details/how-to-tell-if-a-slot-machine-is-rea...
https://www.bbd.casino/info_details/how-to-win-at-roulette
https://www.bbd.casino/info_details/how-to-win-online-casino-games
https://www.bbd.casino/info_details/mobile-slot-malaysia
https://www.bbd.casino/info_details/online-gambling-real-money
https://www.bbd.casino/info_details/real-casino-online-malaysia
https://www.bbd.casino/info_details/slot-machine-payout-schedule
https://www.bbd.casino/info_details/how-to-win-roulette-in-real-casino
https://www.bbd.casino/info_details/how-to-win-slot
https://www.bbd.casino/info_details/mobile-casino-pay-with-phone-credit
https://www.bbd.casino/info_details/online-casino-top-up-by-mobile
https://www.bbd.casino/info_details/tricks-to-winning-on-slot-machines-a...
https://www.bbd.casino/info_details/which-slot-machines-pay-the-best-2021
https://www.bbd.casino/info_details/best-online-betting-sites-malaysia
https://www.bbd.casino/info_details/how-to-read-betting-odds
https://www.bbd.casino/info_details/understanding-betting-lines
https://www.bbd.casino/info_details/how-to-read-horse-racing-program
https://www.bbd.casino/info_details/how-to-read-a-horce-racing-form
https://www.bbd.casino/info_details/how-to-be-good-at-poker
https://www.bbd.casino/info_details/how-to-play-fish-table-online
https://www.bbd.casino/info_details/how-to-play-idn-poker-malaysia
My family every time say that
My family every time say that I am wasting my time here at web, except I know
I am getting experience every day by reading such fastidious articles.
Hey there! Quick question
Hey there! Quick question that's entirely off topic.
Do you know how to make your site mobile friendly? My web site looks weird when viewing from my iphone 4.
I'm trying to find a theme or plugin that might be able to fix this problem.
If you have any recommendations, please share. Many thanks!
You could definitely see your
You could definitely see your expertise within the work you write. The sector hopes for even more passionate writers like you who aren't afraid to mention how they believe. All the time go after your heart.|
Spot on with this write-up, I
Spot on with this write-up, I seriously believe that this site needs a lot more attention. I'll probably be returning to read through more, thanks for the
info!
Amazing blog! Do you have any
Amazing blog! Do you have any hints for aspiring writers?
I'm planning to start my own website soon but I'm a little lost on everything.
Would you suggest starting with a free platform like Wordpress or go
for a paid option? There are so many options out there that I'm completely confused ..
Any recommendations? Cheers!
It's actually very
It's actually very complicated in this full of activity life to
listen news on Television, therefore I simply use internet for that purpose, and
take the hottest news.
Awesome article.
Awesome article.
Hozzászólás