Hi, I'm running into something that seems quite trivial. I'm primarily a java programmer, but am creating a web site that has a bit of php code. The problem is, I have created a search page in php that querries a db, and returns to self with the results. One of the problems im having is that if a us...
anyone know if this is the method that i should be using in javascript? <BODY onLoad="javascript:sndReq()" > <script type="text/javascript" src="JSsource.js"></script> or should it be something like <BODY onLoad="javascript:sndReq()" type="text/javascript...
works, but is it updating once the page is loaded (its hard to tell as my broadband is too fast, obvioulsy not everyones will be) this litle bit here: <BODY onLoad="javascript:sndReq()" > <script type="text/javascript" src="JSsource.js"></script> Does this run as on loa...
almost there I think: Saved in the local file as JSsource.js: function createRequestObject() { var ro; var browser = navigator.appName; if(browser == "Microsoft Internet Explorer"){ ro = new ActiveXObject("Microsoft.XMLHTTP"); }else{ro = new XMLHttpRequest();} return ro; } var ht...
It doesnt download for each client, the php checks the modifaction of the local files (TempRssFeed) and only downloads if more than 7hrs old, or different day.
Still havent got it to work yet, but figuring it out
ok, Ive been reading a bit on ajax. It seems to run javascript like the onload function (once the page is loaded), but can you use javascript to call up a php function.
php is calculated before it reaches the browser, so im wondering if this is possible at all
Is there a way of getting a page to do the php comand after the rest of the page has loaded and been diplayed. I have found refrenced to iframe and DHTML, but im not sure how to do this yet. Basicaly I have a stock ticker that downloads RSS feed to a local folder, this takes quite a while, how ever ...
Thanks JAY that helped :D possibly unix, but mtime seemed to work for me I used : if ( (date('h') - date('h', filemtime("TempRSSFeed.txt")) ) > x) { // then do code all seems to work, obviously this wont work very well if ppl only use it once every 24hrs (difference will be 0), but expect ...
yes it all works now, thank you. My only problem is that its a bit slow, but Im playing around with it so it doesnt need to download the data every time the page is viewed. thanks for your help, I was completely new to php until last week and would have been stuck without your help Ill offer the sof...
does anyone know how i can use php to check the age of a file
I have simple bit of code that downloads rss feed to my local host, but I only want it to run if
1. the downloaded file doesnt exist
2. the downloaded file is more than say 2 hours old
thanks, I had to use a small modification sice Im using php5: <?php function file_put_contents_php4 ($location, $whattowrite) { if (file_exists($location)) { unlink($location); } $fileHandler = fopen ($location, "w"); fwrite ($fileHandler, $whattowrite); fclose ($fileHandler); } echo file_...
Hi there, Im very new to php, but have figured out it may be the solution to my problem I have created a java application that grabs RSS feed from a file, (say yahoo news) then displays it as a ticker (this works client side). The problem is that java applets arent allowed to read from non local fil...