I'm not quite sure what you meant with making a map using the mesh, but I can explain how portals work.
First of you have the regular "Has portal" checkbox.
When you check this you get fields that you can write in coordinates into. It's 4 of them. These determine where you land in your map as you enter the portal from cape. If you look in the bottom right corner, you will see numbers. and these are the ones you'll have to write into the fields if you want it at a certain spot.
So if you write something like
100
100
100
100
It will place you on the 100th coordinate from all directions with a 100 degree yaw.
The gates works fairly the same, but instead of just having a "has" portal, you link 2 of YOUR maps together. This means that if you add a gate in one of the maps. You need to write the coordinates that you want to END UP on your OTHER map.
If you have 2 maps, 1 named "Derp lands" and another one named "Hurrdurr" and you place a gate inside derp lands wanting it to go to hurrdurr. You'd have to get coordinates from within hurrdurr, and then edit the gate inside derp lands.
Play around with the map maker tools really. It will make things easier to understand.