Get Html Variables

Hello All ,

After one of our previous posts we have started getting along slowly to hit another bump in the road

Note: we know our code may not be the most simplistic but it seems to work at the moment , any 1 that knows a easier way to do it then please do say :slight_smile:

<?php $postcode = $_POST['postcode']; ?> <?php $name = $_POST['name']; ?>

// get DOM from URL or file
$html = file_get_html(‘http://xx.com/en/search/records/search.pub?Surname=willi*&Location=$postcode&x=39&y=9&Page=1’);
$html1 = file_get_html(‘http://xx.com/en/search/records/search.pub?Surname=willi*&Location=$postcode&x=39&y=9&Page=2’);
$html2 = file_get_html(‘http://xx.com/en/search/records/search.pub?Surname=willi*&Location=sa11&x=39&y=9&Page=3’);

we have further code which filters out our servers results , but for some reason when one of our users posts the form to this script , only the bottom result is coming back purely because the location is hardcoded - the others are coming back unknown and we think that it isnt passing the postcode variable to the urls correctly

could it be because the $postcode variable is already inside the $html variable , is there a way to get around this issue ?

Thanks

Sponsor our Newsletter | Privacy Policy | Terms of Service