0

I have a small PHP API which I use to grab different parts of info from my database.

From there I am loading the data into the table body with a JavaScript function. Part of loading this particular function requires a $_GET['player'] passed through.

The relevant JavaScript:

function load_playerLogs(page) {
    var amount = $('select#per_page option:selected').text();
    var url = 'logs.php?action=player&player=&page=' + page + '&amount=' + amount;

the PHP/HTML file that loads the JavaScript function is for example:

index.php?page=logs&player=NAME

Is it possible to then get that &player=NAME passed into the JavaScript function so I can use my PHP API?

Eddie C.
  • 918
  • 10
  • 16
Henry D.
  • 41
  • 7

0 Answers0