Jump to content

jarv

Members
  • Content Count

    325
  • Joined

  • Last visited

Community Reputation

0 Neutral

About jarv

  • Rank
    Advanced Member

Profile Information

  • Gender
    Not Telling
  1. Lat/Long was wrong way round! THANKS!
  2. Thanks, I'm getting there now, I used the second one: while( $rs_location = $rs_locations->fetch_row() ) { $markers[] = $rs_location; } My markers are now showing, GREAT! .... but in the middle of the Indian Ocean
  3. ok, I don't get it, sorry. I am just trying to follow the example using the php array they commented out here is where I currently am: $mysqli = mysqli_connect("localhost", "root", "", "plods"); $sql_locations = "SELECT CONCAT(address1, ', ', address2) as address, Longitude, Latitude FROM southdowns"; $rs_locations = mysqli_query($mysqli, $sql_locations); while( $rs_location = $rs_locations->fetch_assoc() ) { foreach( $rs_locations->fetch_assoc() as $rs_location => $value){ $markers[] = $value; } } //while( $rs_location = $rs_locations
  4. no no, if you look at the working example on that link when you call json_encode() in the javascript it should then look like this: array( 'Westminster Abbey, London', 51.4992453, -0.1272561 ), array( 'QEII Centre, London', 51.4997296, -0.128683 )
  5. convert it to JSON and plot markers on a map, like here: http://stackoverflow.com/questions/33652498/google-map-to-display-many-markers-dynamically-using-php-and-jquery
  6. it needs to be out put like this: array( 'Palace of Westminster, London', 51.499633, -0.124755 ), array( 'Westminster Abbey, London', 51.4992453, -0.1272561 ) but I am getting: Array ( [0] => Array ( [address] => Quintessence Fragrances Ltd, Unit 2A, Hawthorne Industrial Estate [Longitude] => 0.058305 [Latitude] => 50.798006 ) [1] => Array ( [address] => Nyetimber, Broughton House, 6-8 Sackville Street [Longitude] => -0.137792 [Latitude] => 51.509285 )
  7. Thanks, that worked but now I get: Uncaught RangeError: Maximum call stack size exceeded
  8. Please help, I am trying to get data out of my database as an array but it doesn't seem to be working?! I just get: ArrayArrayArrayArrayArray here is my code <?php $mysqli = mysqli_connect("localhost", "root", "", "plods"); $sql_locations = "SELECT * FROM southdowns"; $rs_locations = mysqli_query($mysqli, $sql_locations); foreach( $rs_locations as $rs_location ) { $markers[] = array( "{$rs_location['address1']}, {$rs_location['address2']}", $rs_location['Longitude'], $rs_location['Latitude'] ); echo $markers
  9. I would if I could find it but then the date will be wrong I think
  10. Yes it's all a bit mashed together $time variable is a date set in the database $time = $context->data->field_event_date[0]['value']; var deadline = '". date('Y-m-d', $time) ."'; initializeClock('clockdiv', deadline);", 'inline');
  11. Whichever... PHP? I just tried this but it came back as -16449 days 3 months -8 hours var deadline = '". date('Y-m-d', strtotime($time. ' + 1 days')) ."'; at the moment the countdown says: 0 days 13 hours 46 minutes 30 seconds I would like it to say: 1 days 13 hours 46 minutes 30 seconds
  12. So I am declaring deadline as a JS variable and then going into PHP var deadline = '". date('Y-m-d', $time) ."'; I just want to add an extra day onto my deadline any help here please?
  13. I am getting an error to check my values but I am using the right username, password, table name and host name. Can anyone help me here? $mysqlDatabaseName ='drupal'; $mysqlUserName ='drupal'; $mysqlPassword ='xxx'; $mysqlHostName ='localhost'; $mysqlExportPath ='content_type_vacancy.sql'; $command='mysqldump --opt -h' .$mysqlHostName .' -u' .$mysqlUserName .' -p' .$mysqlPassword .' ' .$mysqlDatabaseName .' content_type_vacancy > ~/' .$mysqlExportPath; exec($command,$output=array(),$worked); switch($worked){ case 0: echo 'Database <b>' .$mysqlDatabaseName .'</b> success
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.