I'm using Drupal 7 with the following modules to show in the user profile their location.
Locaction
Gmap
With these modules, a map views can be built, or the provided location node displays the "bubbles" on the map.
However, I couldn't find out how to display the location map on the user profile node itself.
There are other modules like GMap CCK Field, but this means double entering the location.
Did I miss anything, or is there any other approach?
If you want to display the map view on the user profile node, then you will have to custom code the user profile template file and add the view to the profile page. Then this will be displayed on the website easily.
Another way to do this can be by creating a block which shows the map view and then using Contexts module to display this block only when the user is viewing the profile page. In the view you have to add the relation on "Author" and then you should have the filter criteria to show map of the logged-in user.
With context, you can say that "when user is on profile page X with path "www.xyz.com/user" then display the block Y in region Z."
Related
To link new users from Special:Login to Special:RequestAccount I'm using a Message in the MediaWiki:Loginprompt page.
In the default Vector skin it gets shown when logging in, also in the pivot skin, but not when using the mobile MinervaNeue skin, activated with:
wfLoadSkin( 'MinervaNeue' );
$wgMFDefaultSkinClass = 'SkinMinerva';
in LocalSettings.php
Is there a way to show MediaWiki:Loginprompt in Minerva skin or another way of refering users to Special:RequestAccount?
Here you can find all the messages used on the Minerva login page
https://www.mediawiki.org/w/index.php?useskin=minerva&title=Special:UserLogin&uselang=qqx
You could add the desired message to one of the used messages.
For example add this to the bottom of the MediaWiki:Mobile-frontend-generic-login-new page to transclude the desired loginprompt message in that message
{{:MediaWiki:Loginprompt}}
Currently I have a sample which I'm working on which is a basic master details page. This sample uses react-router-redux. Within the details panel I have a number of tabs which use can see different facets of the selected item... all fairly standard stuff.
When the user selects an item from the master list, the URL that the clicked <Link ... /> send them to is something like customer/123. Within the route that is registered for that url (i.e. :id), I have an indexRoute route which replacess the route to default route/tab /customer/${nextState.params.id}/address.
All this works well and the user can navigate between tabs just fine. The problem comes when the user closes the detail window and selects a different detail. As expected, it opens the tab based on the route specified by the indexRoute. Under normal circumstances, this might be fine but I want it to remember which route was selected. I'm wondering if anyone has ideas on how this should be done?
I think I can do achieve this by registering a callback with the onClick event of the Link and dispatching an event which will result in key of the selected tab being saved in the store. Then within the onEnter of the indexRoute I can access the store and pull out this saved state and target the replace to this that item.
This should work but seems like a lot, just wondering if this seems right to other?
I would use the same approach - dispatch an action when the tab is clicked and store the tab key in the store.
Use mapStateToProps to retrieve the value.
In my application I am using fragment tab-host with view pager and I am opening child fragment inside each tab.
Every time I switch tab data get reloaded every time and one of the tab contains Google map, in Google map added markers programmatically but every time I switch tab it doubles the markers on map e.g. if I have added 10 markers for first time after switching once it get 20 and so on.
I have used this code to open child fragment
Used fragment page adapter with view pager
So please tellme how to stop reloading fragment.
This happens because each fragment has a lifecycle (http://developer.android.com/guide/components/fragments.html), and when you switch tab data the fragment is destroyed and another is created.
You are using fragments with view pager and this is controlled by a Parent Activity, so you can move the code to load the map to the Activity, and just use the fragment to display the data stored inside the activity.
You can get the parent activity with this code inside your fragment:
(YourActivity) this.getActivity();
I am having a problem with a UI that I am building in a Google Spreadsheet. I will First explain a little about how it works and than I will get to the problem. The UI is fairly simple program that connects to a SQL database, it allows users to create new records, Query, search, and render reports. I have created all the panels (eg the intro page, the create record) in the GUI builder. As the user navigates through the UI I swap out a Grid with the new panel that i want the user to see. For example on the intro page there is a create button when the user clicks the button the gird where there intro panel was is replaced by the create record panel. I have created two ways for the user query/search for data. The first way is to select a number range on the intro panel and click the Query button. This will than query the last 10 or so records into a GUI built Panel that I will call MainForm. The second way is to "search" for a job. On the intro page there is a search button when the user clicks with button it goes to a new page; the grid is switched to the search panel. On the new page/panel the user can put in some parameters to search for. After the user clicks the search button the program should load the search results into the MainForm in the same way as when you Query from the intro page. I have taken the whole function apart line by line, so i am sure that the issue has to do with loading the panel/Component. What i mean by that is these few lines of code.
var Component = app.loadComponent("MainForm");
var panel = app.createVerticalPanel().setSize("770px", "900px").add(Component);
app.getElementById("contentGrid").setWidget(0,0, panel);
But why would it load in one case, but not in another? Also it is not the method of loading the Component, rather it is the returning the panel/ Component.
To Summarize, When I load the Component with the query function it works, but when i load the Component in the search function I get and error: Incompatible type passed in as a parameter. Also I load the MainForm Component in two other functions as and it works most of the time, but some times I get the same error.
I think your approach is not ideal, load component is not supposed to be called multiple times. It would be far more efficient to get all your panels in the same compnent and play with visibility of each panel to show / hide them on demand. Each panel should be inserted in a vertical panel so that the "new panel" slips to its place when the "old one" hides.
An example of this approach is shown in this post to simulate tabs and could easily be adapted to your needs.
btw, this method is also very fast and responsive since the full UI is ready from the very beginning ;-)
hi am using Google map in my project like store locator. there are 2 pages where one selects the store in first and page and the map is populated in second page now i want to display selected one on load of page by default.
if you want to show a map with a marker to locate the selected store then here are the demos create a logic to check which store is selected the redirect to another page and call the function with parameter that sets the center on users selected store