I have applied and configured CCK Location module to show node location on map (GMap, GMap location modules).
However there is small issue that map does not show location at the centre (address marker is off the screen and user must scroll through the map to find it ;-).
It looks like map is centred one map screen off to the left (to the west) from where it supposed to be to show marker at the centre.
I have tried to reinstall all those three modules, reset gmap macros to the simplest ones [gmap] all around but nothing helped.
Anyone knows what could be missing here?
Go to /admin/settings/gmap
Under the Default Map settings set the default size, zoom level and center of the map to what you want to show by default (before the location is selected).
Then go to /admin/content/node-type/[name-of-your-content-type]/fields/[name-of-your-location-cck-field]
(Basically click on the "configure" button after going to Manage fields for your content type)
In the GMap Macro, make sure it is something like this:
[gmap| zoom=7 | width=100% | height=400px ]
Note that it says A macro to be used as a base map for this field. This map will be recentered on the location, so the center is not that important.
See if this fixes your problem.
After few hours of struggling I have discovered conflict between GMap and (Tabs or CCK FieldGroup tabs) module.
I did put my location CCK map in field group as a tab. It looks like some javascript code conflicts there.
Till now I came up with 2 solutions:
Change your design and simply move gmap out of tab or place it on the first one.
Override css style of .ui-tabs-hide class. Change line with left:-15000px (or similar) to left:50% or left:(half-width-of-your-map-in-pixels)px.
Do not touch any other styles and everything should work fine.
Maybe there are better solutions. If yes - please share.
Related
I'm working on Magento modules.
After few guides I managed to create module that says "hellow world".
Also I have made some of css code that add simple image border around whole page.
So the problem is: how to combine them together?
I want that when I install my module, image border appears around page.
What should I be looking for? Any tips? I need right path to look for answers
T.y.
You need to to
Create a module
That modifies the global layout such that your CSS is added to the page
Re: number two, there's multiple ways to go about doing this. These days I favor the event/observer method
Add an observer for the controller_action_layout_generate_blocks_after event
Fetch the head block from the layout in your observer method
If you find a head block, add your CSS file to it programtically
The more traditional way is
Configure you module to include an additional layout update XML file
In the default handle of your new layout update XML file, add XML that tells Magento to add your CSS file
That should give you enough to google on and come back with more specific questions. Good luck!
I am trying to add OpenLayers.Control.OverviewMap() to group of layers (geotiff with shp file) in Geoserver. Is there any way to automatically add this control to every map which I would like to display from Geoserver by OpenLayers? There already are some default control buttons like scale or navigations. I assume that this will require some changes in *js or other file in Geoserver, please let me know which one it will be.
I am working with a site that uses panels for layout. One of the simpler panels we have is used to show a node with sidebars around it with other content that changes dynamically based off of the path. The node and sidebars are always the same. Let's say the node id is 10 for the node that is always shown, that does not change.
For a specific path, I would like to change the body of node 10, the node that is always loaded through the panel configuration.
I thought of using preprocess_page in template.php and overriding $vars['content'], but that contains all of the html for the entire panel. I only want to change the body of the node that is always contained within the panel. Seems like having to override all of $vars['content'] just to change a small piece of the html within $vars['content'] is overkill.
How can I update the body of a node, that is always loaded by a panel, for only one path?
You could create a special condition for that panel page when the url is xxx.
Another option would be to override the pane that is printing the node with a preprocess function, and alter the html there. Similar to what you were trying to do, only targeting the thing you want to alter.
At http://jqueryui.com/demos/dialog/#modal-form, there is a sample modal dialog; when you click on "Create new user", it displays a modal dialog and fades everything but the dialog.
On my work based on that, I've specified "modal: true," and the modal dialog appears and disappears appropriately, but nothing else is greyed out; the rest of the screen looks as it looked before.
Do I need to apply additional CSS or serve up an image? A brief look at the sample source code didn't make it clear what I need to be adding so that it greys out the background.
If I need to have other static content served up, how can I serve it up under a Django /static/ tree? In other words, do I need to make /foo/ and /bar/ additional static content directories, or will it work with subdirectories of /static/?
When you're passing modal:true as one of the options to ui-dialog, there should be an overlay div element created with a high z-index and a classname of ui-widget-overlay assigned to it. If you decided to write your own stylesheets rather than use one of the available ones as a template, it could just be that you need to define the ui-widget-overlay class in your stylesheets, set its opacity etc.
Do you have the appropriate theme files in the correct place on the server? If you aren't using a standard default theme you can create your own using jQuery UI's theme roller.
I have a block view called: "MYVIEW"
And I have a region on my template called: "right".
What must I call the template file to edit this?
The following does not work.
block-MYVIEW.tpl.php
block-right--MYVIEW.tpl.php
When you are editing a view in Drupal's administration, you have something like "Thème: Informations" (my install is in french, so it might be a bit different for yours) in the section of the screen that correspond to "base parameters" (same remark) ; it's the section of the left of the screen, and that entry is near the bottom of the options you can configure.
If you click on the "informations" link, it will display a list of all names you can use for templates files related to that view ; you mimght way to try using one of those ;-)
The module Theme developper might also help you with that kind of stuff, btw.