$.GET wwppa
-
In order to reduce loadtime on mobile I do not want to load an wppa-album on initial pageload but I want to put it ‘behind’ a button. So on buttonclick I execute “$.get({url: ‘https://www.magoster.nl/php/photo.php?func=wppa_slide&albumnr=1’, cache: false })”.
It returns the text ‘[wppa type=”slide” album=”1″ size=”auto”][/wppa]’ as could be expected. But is does not load/show the album itself. Can anyone help me how to then execute this wppa-code? The relevant javascriptcode is below.
Cheers, Rudolph Smits
In webpage javascript:
$.get({url: ‘https://www.magoster.nl/php/photo.php?func=wppa_slide&albumnr=1’, cache: false })
.done(function( resultaat_get ) {
PhoneBlock.innerHTML = resultaat_get;
})
.fail(function( err ){
PhoneBlock.innerHTML = ‘<hr>Sorry, get failed…<hr>’;;
});In photo.php:
$function = $_GET[‘func’];
$variables = $_GET[‘albumno’];
$function($variables);
function wppa_slide($albumnr) // $albumnr = not yet used
{echo ‘[wppa type=”slide” album=”1″ size=”auto”][/wppa]’;}The page I need help with: [log in to see the link]
- The topic ‘$.GET wwppa’ is closed to new replies.