Discussion in "Map Me Support" started by    WayneM    Apr 29, 2008.
Tue Apr 29 2008, 05:53 pm
#1
I know you are busy :-)

If the time comes that you make a update, it would be really great to have a link on the map that will open the map in a new full-screen sized window.

I'm guessing that most e107 sites, like mine, have their user page in the main content area of the site. For most sites this is going to be a screen area of about 550 pixels wide (maybe 750 on some sites).

Being able to open the map into a window that is full-screen sized would really make browsing the user locations a lot easier.

The Map Me plugin is working great :-)

Thanks!
Tue Oct 07 2008, 07:02 am
#2
Tired of waiting around for this, and had some time to kill... so I've put together a bit of code that works okay.

Create your own standalone mapme map page as follows:

Make a text file with the following content:

<?php

require_once("class2.php");

$caption = "";	

// comment out next four lines if you want this page to be public
if (!USER) {
   $ns->
tablerender("Error!", "You must login to view this page");
   exit;
}

$text = "<head>

<title>
Member Map - Large Version</title>

</head>

<body>

<center>
<small>
<a href=http://www.YOUR.SITE>
Back to Main Page...</a>
</small>
</center>
<center>

<table style='width:100%; height:95%' class='fborder'>

	<tr>
<td class='forumheader3'>
<div id='map' style='width:100%; height:100%;'>
</div>
</td>
</tr>

	</table>
</div>

</center>

</body>

<script type='text/javascript' src='http://maps.google.com/maps?file=api&v=2&key=GOOGLE_MAP_KEY'>
</script>

<script type='text/javascript' src='e107_plugins/mapme/mapjs.php'>
</script>

";

$caption = $tp->
toHtml($caption);
$text = $tp->
toHtml($text);

$ns ->
 tablerender($caption, $text);

?>


Save it as a php file. Example "whatever.php"

You'll need to edit a few lines.

1. Leave in, or comment out, the lines that restrict this page to users or make it public.

2. Change the url for "YOUR.SITE" to your site's main page.

3. Enter your unique GOOGLE_MAP_KEY

Save your page.
Upload it to your e107 base directory.

This page will automatically resize the map to any size window!!

I've tested it in both FireFox and MS Explorer. Works fine. :-)
 knutars like this.
Tue Oct 07 2008, 06:59 pm
#3
Hi WayneM, thanks for the input

I will make some changes so that your code directly use the MapMe preferences to load the map.

I am really not getting time out of busy schedule. I have so much to implement..
Tue Oct 07 2008, 07:09 pm
#4


Hi WayneM, thanks for the input

I will make some changes so that your code directly use the MapMe preferences to load the map.

I am really not getting time out of busy schedule. I have so much to implement..

Ajay



That's cool

Note that in the code I provided, the size of the window controls the size of the map display automatically. By tweaking the settings for the table width and height, and the div width and height, the size of the map display can be customized as needed.

If the code were to use the MapMe preferences, the map display size would be preset to the standard size.
Tue Oct 07 2008, 07:13 pm
#5
you can make code even simpler

i will show you how... (but i need to pack up now.. friends waiting..)
:bye
Tue Oct 14 2008, 06:52 pm
#6
hmmm... it doesnt work for me - it will only schows a blank page with the textlink "Back to MainPage..."

i've used mapme version v1.1 from the download page of this site and enteres the g-maps key in mapme also in your template...

whats wrong?
Tue Oct 14 2008, 07:19 pm
#7
oh, can it be that the reason for my problems is that i'm using the "alternate profiles v0.3" plugin for my membersite instead of the original user-page? (so my usersit isn't any more "user.php" - it's now "e107_plugins/alternate_profiles/newuser.php")

Get Social

Information

Powered by e107 Forum System

Downloads

Comments

Richardedils
Wed Apr 24 2024, 04:07 am
ChrisLub
Tue Apr 23 2024, 05:21 pm
Davidbab
Tue Apr 23 2024, 10:41 am
Richardrit
Tue Apr 23 2024, 09:54 am
HenryLaf
Mon Apr 22 2024, 03:50 pm
bleradrar
Mon Apr 22 2024, 06:38 am
ppu-pro_ka
Sun Apr 21 2024, 07:39 pm
Infewow
Sun Apr 21 2024, 06:30 pm