mirror of
https://github.com/moodle/moodle.git
synced 2025-01-31 20:53:53 +01:00
3565ff92e4
$locations = array('location1'); $locations += array('location2', 'location3', 'location4'); to save the hassle of doing one $locations[] = 'location1'; for each location. But += doesn't add any entry if the key of the new array already exists in the original array. So, using my example, the resulting array would be: $locations: array('location1', 'location3', 'location4');