How do I delay a PHP script that writes to a text file and then reads from the same file long enough to make sure changes have been written before I attempt the read?
Hi at all,
I want to know if this web app are using long polling or anything else "javascript trick":
http://typewith.me/2wicOjuefI
Is there a way to know that ?
Thanks ;)
I having trouble scraping a certain long dash that is encoded as ; on the Time magazine site. It looks like this: —. It works fine when this dash is encoded as mdash, but when the problem dash is scraped, it is returned as unknown characters. I am using Nokogiri and am wondering if I have to use some sort of special encoding? The page says it is encoded with UTF-8.
Hi all,
My source gave me the following lat and long codes from Amsterdam. But I can't get them working with Google Maps. Is there some logic behind it, or some kind of algorithm to convert them?
5,237,300,539,279,090 | 489,290,714,263,916
Should be something like this:
52.378268, 4.888859
How can one tell where the dots should be?
Thanks!
How do I automatically interrupting long queries in the mysql, if it possible?
I'm understand, that I need optimize queries instead of. But now I have access on database server only.
I have a php mysql query like this
$query = "SELECT * FROM articles FORCE INDEX (articleindex) WHERE category='$thiscat' and did>'$thisdid' and mid!='$thismid' and status='1' and group='$thisgroup' and pid>'$thispid' LIMIT 10";
As optimization, I've indexed all the parameters in articleindex and I use force index to force mysql to use the index, supposedly for faster processing.
But it seems that this query is still quite slow and it's causing a jam and maxing out the max mysql connection limit.
Let's discuss how we can improve on such long query.
I have a php mysql query like this
$query = "SELECT * FROM articles FORCE INDEX (articleindex) WHERE category='$thiscat' and did>'$thisdid' and mid!='$thismid' and status='1' and group='$thisgroup' and pid>'$thispid' LIMIT 10";
As optimization, I've indexed all the parameters in articleindex and I use force index to force mysql to use the index, supposedly for faster processing.
But it seems that this query is still quite slow and it's causing a jam and maxing out the max mysql connection limit.
Let's discuss how we can improve on such long query.
My application is suppose to constantly update the page without any user interaction. The criteria is that the page just has to be there, as an extra window on the monitor so the user can see the information get updated real time.
I'm using the Ajax in jQuery with Rails, and my question is - how long will the .erb page keep Ajax open? Will there be a point where I have to refresh the page or re-initialize? Or will that won't be a problem at all?
I am pulling a long timestamp from a database, but want to present it as a Date using Tags only, no embedded java in the JSP. I've created my own tag to do this because I was unable to get the parseDate and formatDate tags to work, but that's not to say they don't work.
Any advice?
Thanks.
i have a php page which auto refreshes itself after 10 seconds. Some time the page takes too long to load as its fetching data from external urls . How can i stop execution of the script after 10 seconds and then reload the page.
I want to generate a PDF of user-submitted text using LaTeX. To handle crazy user input, I first thought about using the verbatim package, but of course it doesn't break up too long lines. Is there some package that works similar to verbatim (i.e., accept any input) but formats the text nicely?
Is it possible to constraint a method so that it receives only int, double, long or other numerical types that has the usual numerical operations ( such as +,-,*,/) defined?
Hi,
I begin my NHibernate mapping. In major cases I use int type but for some entities I need to persist million of objets. Is long type for identity will be the best choice ?
I have two applications, and one is keeping sending live images to the other and it need to be long-running.
Is WCF suitable for this scenario? or if there is any better alternative for this communication?
Hi All
I have a custom query in dripal, this query is:
select count(distinct B.src)
from node A, url_alias B
where concat('node/',A.nid)= B.src;
now, nid in node is primary key and i have made src as an index in url_alias table.
after waiting for more than a minute i got this:
+-----------------------+
| count(distinct B.src) |
+-----------------------+
| 325715 |
+-----------------------+
1 row in set (1 min 24.37 sec)
now my question is: why did this query take this long, and how to optimize it??
Thanks for your help
I dont know if this is possible, but if Im working on two areas of code in a long file, I have to note the line numbers and scroll between the two areas of code. Is there a way you can jump between two commonly used areas of code?
Perhaps setup a flag of some sort?
I have a list containing a tuples and long integers the list looks like this:
table = [(1L,), (1L,), (1L,), (2L,), (2L,), (2L,), (3L,), (3L,)]
How do i convert the table to look like a formal list?
so the output would be:
table = ['1','1','1','2','2','2','3','3']
For information purposes the data was obtained from a mysql database.
I have two applications, and one is keeping sending live images to the other and it need to be long-running.
WCF - is it suitable?
TCP/IP directly?
Service bus, NServiceBus?
Is there any better alternative for this communication?
I would like to generate a long UUID - something like the session key used by gmail. It should be at least 256 chars and no more than 512. It can contain all alpha-numeric chars and a few special chars (the ones below the function keys on the keyboard). Has this been done already or is there a sample out there?
C++ or C#
I have a long task in Javascript that should be performed before the web page content is displayed. During the execution of this task I would like to show an image whose opacity will grow up to 100% (when the task is done).
How this can be achieved ?
both of them hold 8 bytes, but how come the max value for double is much greater than the max value of long? there is a finite number of bits available, so how could you reach greater numbers with floating point variables?
I have a ListActivity and I want to implement context menu for each of the list elements. I know that the common way to do this is to show the context menu on long click/tap. I want to know if there is a way to show the context menu for each element on a key press(preferably the menu key).
To rephrase my question, how can I trigger the context menu and not the options menu by pressing the menu key(or any other key).
If I load the data of user_x in the memory with memcache, how long will this data stay available. If a user only logs in ones a year this data is unnecessary in the memory.
Or am i looking at this thw wrong way?
On my wordpress site I have tweet blender plugin to show twitter tweets. Everything is ok except for some resason it takes a long time to show the tweets on my site. When tweet it takes anything between 15-70 minutes to show on my site. Any idea why is that? Everything should setted right.