the TTTwitter seems to be wrong in the three20 example - three20

the TTTwitter seems to be wrong,when i click the more Button,the following method runs twice,and first time more is true,second time more is false,so we can see that the table can't load data right.
- (void)load:(TTURLRequestCachePolicy)cachePolicy more:(BOOL)more
anyone can help me ? thank you.

Try to disable the cache and see if it helps you. Three20 cache is a little broken. Look for a line that declares the cache in the model's load function and change it to:
request.cachePolicy = TTURLRequestCachePolicyNone;

Related

What does the processAjaxOnInit option in tablesorter do?

I have used this option in the pager widget (so I used pager_processAjaxOnInit: false), but can't tell that it has an effect. I thought it might cause the ajaxProcessing option to not run upon initial loading of the table, but that doesn't seem to be the case.
Thanks for your help.
The documentation states:
Set this option to false if your table data is preloaded into the table, but you are still using ajax (New v2.14.5).
For more details see issue #424.

Smart Search Joomla One Result

I just enabled the Smart Search plug-in, and everything were great!
I just wanted to know when the query have ONE result, I'd love Joomla! will direct the user to this page directly.:(
Anyone has this issue and solved it ?
In this file components\com_finder\views\search\view.html.php add the below line inside display function. After this line - $this->assignRef('pagination', $pagination);
if(count($results)==1){
$app->redirect($results[0]->path);
}
This is a core file change so please do if necessary.
let me know if it does not work.

How to make wp plugin auto-refreshing on the public side of view (auto load page)

First have to say that almost every time when searching on technical solutions.. search engine will direct me to this site here. I admit that i have learned such A LOT here just by searching through for answers..
but also have to say that not being a coder.. so don't understand much here at all ;)
Ok, the Problem:
Want to update wordpress tables or calendar within wp admin. These changes should become updated on the public side automatically and more or less instantly (~ few seconds is perfectly fine).
I found solutions about manipulating header.php, i found some ajax plugins I found -too much to count- info on how to implement ajax into wp
Sadly.. none of these could help me through as the plugins mostly either not work, are outdated or require countless file edits. Manipulating header.php seems odd.. as i don't want to loop-refresh the whole page, post etc.. but only get e.g. table or calendar data updated.
So maybe any of you coders know of something to e.g. get the plugin "All-in-One Event Calendar by Timely" to update the public visible part of the calendar once data edited in wp admin?
Greatly appreciate pointers in any direction to solve this.
P.S.: What would you think of plugins like "ajaxify everything" ? don't know if this really the way to go..
Again, thanks for your help, time and contribution!!
update
additional question:
I now found such plugin to let me chose which parts i want to "ajaxify".
Such plugin would ask me for a specific function name.
Now, where do i start to gather this information?
Below is the instruction from the plugin context inside wordpress admin
Generate Ajaxized DIV for your function
Ajaxize will allow you to ajaxize almost any php function on your
site.
It can be a plugin, a function you wrote, or even a core wordpress
function.
There are some (obvious or less obvious) limitations currently:
Functions must return valid HTML - this will be called in php and returned via the
Ajax call
Functions cannot accept any parameters (at least at the moment)
Enter a function name below.
Function Name: xxx input field xxx what put in here? xxx
The generated div can be inserted to any page/post on the site and
will ajaxize the call to the function automatically.
Please make sure you enter a valid function name, that the function
does not require any parameters, and that it returns valid HTML.
In your context you want to refresh the calendar automaticaly when there is a change in the WP_Admin;
but you can't exactly do this.
You can write a Js method which will check the time of lastest modification of the calendar at the load of the page, stock it in Var.
After you'll have a constant (each 10seconds) Js "daemon" which will get the time of lastest modification of the calendar and compare it to the stocked Var; If change you reload the calendar.
PS: Ajaxify everything is not really a solution due of the developpement you need To Ajaxify and to code for people who has disabled Javascript.
Hope it helps

Drupal 7 caching my form and printing old cached fields (Varnish/Memcache)

I have a profile2 form called by drupal_get_form - though after its been edited and saved, the fields still display the old information for awhile. How can I turn caching off here? I'm using memcache/varnish/apc btw.
I'm also printing these fields elsewhere and get the same problem.. I would rather this be dynamic and fresh for just these fields/forms.. any ideas on how to do that? Thanks!
Probably you need to exclude cache_form from memcache with:
$conf['cache_class_cache_form'] = 'DrupalDatabaseCache';
in your settings.php file

django update page when database field updates?

I have a results page and I am trying to work out how to auto update the page when an external database field is updated. I have seen quite a few examples but they seem to relate to PHP. I have a test that calls various APIs that can take up to an hour to complete. Once the test has completed, it will enter a success or failed message in a database field.
I already have my results page being rendered by django using template tags. I have a table and I have the field I would like to update. There are multiple fields that need update which correspond to each API test.
I have seen this site.. is this the kind of stuff to use? http://www.dajaxproject.com/ Is this an easy task to do? Does anyone have any ideas on how to do this?
Sorry but I don't know where to start on this one.
Cheers - Oli
I decided not to be so bold and just use the old classic page update for this purpose using javascript..
window.onload = setupRefresh;
function setupRefresh() {
setTimeout("refreshPage();", 30000); // milliseconds
}
function refreshPage() {
window.location = location.href;
}
Still open for options however I'm rather inexperienced in django and maybe this was too much to bite off too quickly..

Resources