I would like to display a table from a site onto my site with an automatic updater. Would this be possible with PHP or Javascript? I've tried parsing the data into a google sheet, and later displaying the google sheet on my site but I feel like there is an easier way. The table I'm trying to display is here https://ahlhaxball.000webhostapp.com/table/table/ labeled "League Table"
You can do it with PHP. If you want to do update it live without refreshing page (like updating every min or every sec) then you need to use PHP with Ajax. Ajax will help you to make calls without refreshing the page.
Related
I am new to programming and I am working on a web application using JAVA EE, struts, jsp, HTML,
I have a table which shows some statistics and my client wants me to add a feature to pick a back date to see that dates statistics, but I am totally confused.
I had pre built queries which were getting data from oracle database and displaying data on my table on a JSP page. But now I change my query to a prepared statement and I have added a "?" to get a date from user and then replace that and make a query and display data.
First problem is that which struts when you have values to be displayed and they have some sort of problem the table won't even show up and secondly when I try to pick a date and hit submit button it should go make the query and display the table but it is not happening, I am totally lost. I will be grateful if someone can tell me how to solve this problem.
Thanks.
I am currently using Java (Eclipse) to build this application which will be able to take a spans value from a specific website and show those values on console. But the issue i am having is, the Website i believe is Dynamic and therefore, i am not able to get those span values. The span (id=spot) keeps refreshing every 1 second and i guess it uses JavaScript. The class keeps auto changing as well when i do a "Inspect element". But if i do "View page source", there is no value inside the span. Could anyone suggest anyway to either render the web page and fetch data or any other method to do this. I have been
on google for the past 2 hours and nothing helped. I am new to this selenuim, JSoup, rhino which did not help at all. So please try to elaborate as much as you can :)
Here is the Web Page: https://www.binary.com/trading?l=EN
span id=spot
Now in my jsp page I have number of records come from oracle database.But I want to display limited number of records per time.How do I use pagination for this using jquery and jsp? I want to display 1-10 records at one time in my jsp. After click the next button I want to display my next record set.(11-20). In here values come from database are not fixed. My data table does not contain any headers.So it's not easy to use jquery data tables.How can I do this?
Your question is not very specific, anyway here's an example of what I did when paging the results of a search engine. I've used JSP and jQuery, maybe it can help you understand how to proceed: http://pastebin.com/XG40Vm2D
i have a grid view and a file upload button on a page. I have users load their data to my site and i parse their files and load onto the gridview. Then using ajax i update the javascript/jquery I allow users to edit their data right on the gridview. My problem is somehting that should be simple to fix but yet im stumped. Once the user is ready to submit the gridview data for good i have an AJAX call to a webservice that i send all the information on the grid. Then i would like to clear the grid and basically start with a clean page again. However i cant seem to clear the grid view. The data just keeps refreshing in the control with the original data. I realize that it has to do with the fact that is bound on the server but i cant unbinded!. i have tried.
window.location.reload()
but all this does its get me a crappy message from firefox telling me that the page is going to refresh.
I saw this on this site from various people
Response.Redirect(Request.RawUrl);
however i don't know how i can trigger that from an Ajax call?. Can i? I'm doing everything through Ajax partly because is where im most comfortable, but i would hate to have to put another button on the page and make the user have to click that button to restart it seems silly. I would like to do a full page refresh on my command. Is there anyway to do this via AJAX? putting a server button does not seem feasible to me due to the fact that once i load data in grid view i use jquery data table and jeditable and work pretty much on the client.
I'm open to suggestion, ideas, tips, anything at this point. So frustrated with what should be a simple task.
Thanks in advance
Miguel
To force a full page refresh without postback you can set the window.location.href value to the current window.location.href
e.g.
Imagine our current scope is the success callback of your grid data ajax submission function, so when the page reloads all new data will be fetched.
//reload the page now that data has been updated.
window.location.href = window.location.href;
If you must use server controls, you can wrap it in an UpdatePanel. This will make it ajax-enabled, but is pretty brute force.
There are nice libraries from companies like Telerik that have ajax-enabled controls. These cost some dough, but if you are doing a lot this it may be worth it.
Another option that does not support server templates/databinding is to use a jQuery based grid like jqQrid.
I am looking for a way to display a list of websites one at a time from a URL list. I'm fine with a very manual solution, I found an AJAX solution where each "page" is displayed in a tab but it is very heavy because if I have 50 pages I want users to page through one at a time, this solution essentially pulls all 50 pages onto the one page. Do you know of a framework which does the same thing but only loads one page at a time? Thank you very much for the advice and help. Here is the site I found - http://css-tricks.com/jquery-ui-tabs-with-nextprevious/
You could load the URLs into an array and then create a 'next' button that loads the next url into a div; replacing the previous one.
do you require doing this will javascript?
might be easier to curl the pages using php, then echo this returned data as an eval-able array into the html. Then allow user to alter which part of the returned array you are looking at using a next and prev button.
if you pre-load each one it will be heavy as you have noted.
This idea is screaming for AJAX. With proper AJAX calls, you would only load a page once it has actually been selected by tab. Any previous page loaded into the area would need to be dumped. You shouldn't actually need to physically switch tabs if you're using the src attribute of an iframe, simply changing the src and forcing it to refresh itself should accomplish the trick. If you are performing a screen scrape through a remote web service, then you could simply use jQuery/AJAX to rewrite the innerHTML of the panel in question.