Timeline for Build dynamic page from cURL (HTML page) response with plugin
Current License: CC BY-SA 3.0
11 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jul 15, 2013 at 14:51 | history | edited | s_ha_dum | CC BY-SA 3.0 |
added 31 characters in body
|
Jul 15, 2013 at 14:46 | vote | accept | robooneus | ||
Jul 15, 2013 at 13:45 | history | edited | s_ha_dum | CC BY-SA 3.0 |
added 570 characters in body
|
Jul 15, 2013 at 13:37 | comment | added | robooneus | But how would I do that in Wordpress? That was the original question... I had a page that was simply the cURL request that would echo the response, but Wordpress wouldn't give that page access to the database for some reason (which I needed for the cURL password). I will update the post above with an edit to explain a bit better. If there is a way to do that, it would be better than using AJAX anyway. | |
Jul 15, 2013 at 13:35 | comment | added | s_ha_dum |
You could create a "Page" with a custom page template such that the cURL response is the only content.
|
|
Jul 15, 2013 at 13:10 | comment | added | robooneus | I have successfully implemented everything up to actually displaying the results... Now I have a full HTML page (complete with its own CSS and JS) to display. Any thoughts on how best to display that to a user? Definitely would prefer not to use javascript to open a new tab... needs to be pretty flexible. | |
Jul 15, 2013 at 13:02 | comment | added | s_ha_dum | You will have to use Javascript to open a new tab, but it isn't going to be 100% reliable and I'd consider it very unfriendly. | |
Jul 15, 2013 at 7:55 | comment | added | robooneus | Is there any way to open the results of the cURL in another page, though? Ideally I would want the job list item to open a new tab with just the results of the cURL making up the page (as I mentioned, the cURL returns a full HTML page). | |
Jul 12, 2013 at 15:52 | comment | added | s_ha_dum |
Yes, this will work with any request whether that request originate from Javascript, or cURL, or from an ordinary form, so long as you send the right POST argument to trigger that callback. What it does not work with is a GET request.
|
|
Jul 12, 2013 at 15:47 | comment | added | robooneus | So with this I would be able to trigger the function on the same page with the use of a javascript trigger on the list item -- the function would then return the HTML from the cURL script which I could then display in a modal or something on the page, correct? To be clear: this is a list on the front-end for users to browse jobs. On click of a link, the user needs to see the (full screen, full HTML) job ad. Best would be to open it in a completely new page, hence wanting to use a link to a different page dynamically created. | |
Jul 12, 2013 at 15:36 | history | answered | s_ha_dum | CC BY-SA 3.0 |