download.sh 970 B

1234567891011121314151617181920212223242526272829303132
  1. #!/bin/bash
  2. ARG_1=`echo $QUERY_STRING | awk -F [=,\&] '{ print $1; }'`
  3. ARG_2=`echo $QUERY_STRING | awk -F [=,\&] '{ print $2; }'`
  4. ARG_3=`echo $QUERY_STRING | awk -F [=,\&] '{ print $3; }'`
  5. ARG_4=`echo $QUERY_STRING | awk -F [=,\&] '{ print $4; }'`
  6. ARG_5=`echo $QUERY_STRING | awk -F [=,\&] '{ print $5; }'`
  7. ARG_6=`echo $QUERY_STRING | awk -F [=,\&] '{ print $6; }'`
  8. ARG_7=`echo $QUERY_STRING | awk -F [=,\&] '{ print $7; }'`
  9. ARG_8=`echo $QUERY_STRING | awk -F [=,\&] '{ print $8; }'`
  10. echo -e "\
  11. <osm-script timeout=\"180\" element-limit=\"10000000\"> \
  12. \
  13. <union> \
  14. <bbox-query w=\"$ARG_2\" s=\"$ARG_3\" e=\"$ARG_4\" n=\"$ARG_5\"/> \
  15. <recurse type=\"node-relation\" into=\"rels\"/> \
  16. <recurse type=\"node-way\"/> \
  17. <recurse type=\"way-relation\"/> \
  18. </union> \
  19. <union> \
  20. <item/> \
  21. <recurse type=\"way-node\"/> \
  22. </union> \
  23. <print mode=\"body\"/> \
  24. \
  25. </osm-script> \
  26. " >/tmp/bbox_req
  27. REQUEST_METHOD=
  28. /home/roland/osm-3s/cgi-bin/interpreter </tmp/bbox_req