Jump to content

fliwatuet

Members
  • Posts

    29
  • Joined

  • Last visited

Profile Information

  • Gender
    Male
  • Location
    Aix-la-Chapelle

Recent Profile Visitors

1,798 profile views

fliwatuet's Achievements

Jr. Member

Jr. Member (3/6)

4

Reputation

  1. Not so easy to get a nice looking avatar...

  2. Thanks for your help @adrian it is working now! Solution: (function ($) { $( document ).ready(function() { $('#Inputfield_city').on( 'blur', function() { var address = $('#Inputfield_street').val() + ', ' + $('#Inputfield_city').val(); $('#Inputfield_location').val(address); $('#Inputfield_location').blur(); }); }); }(jQuery));
  3. This is working: (function ($) { window.onload = function() { alert('LOAD LOAD'); }; }(jQuery)); The alert window shows up.
  4. Both scripts are working in the console but none is working in the edit form. Strange... The header, when editing content: <script type='text/javascript' src='/site/templates/AdminCustomFiles/basic-page.js'></script> Edit: tried a different browser, nothing happens when editing...
  5. @adrian here is what I did: Install the module and set Enable for process to ProcessPageEdit, (Page Edit) Create two fields: street, city Add these two fields to the template basic-page and arrange them ahead the map marker field Create a file called basic-page.js in /site/templates/AdminCustomFiles/ Content of the file: $('#Inputfield_city').on( "blur", function() { var address = $('#Inputfield_street').val() + ', ' + $('#Inputfield_city').val(); $('#Inputfield_location').val(address); $('#Inputfield_location').blur(); }); I checked in the source code while editing the content, the file basic-page.js is loaded. But nothing happens. Where is the mistake?
  6. Thanks @AndZyk and @adrian I will give it a try, AdminCustomFiles look easier to me to understand and implement than hooks. Maybe I use just a dropdown for city and the map marker field for the address.
  7. Thanks @szabesz for the link! @Ivan Gretsky I will do my very best
  8. Howdy! Are there any tutorials that go one step or more further than the basic tutorials at processwire docs? I want to build a site very similar to the skyscrapers demo, I already looked at the code of this demo, but it is really hard to understand what to do when and in which way. Also I don't want to "steal" the code from the demo and just change it to fit my needs. I want to learn how to build such a site. Do you have any suggestions on how to do this? I want to build a site for a soccer club, where all the soccer grounds in the league are listed, with map, description, information about the opponent club etc.
  9. Thanks @AndZyk! This hook-stuff looks a bit complicated at first glance. Is there a tutorial for that?
  10. Thanks @AndZyk and @adrian! For the end user it will be easier to use the map marker field but then there is a chance that they forget the commas to separate the values. Three or more different fields are not that comfortable to use, copy and paste is not possible. Which way do you think is the best solution? Or is it possible to sort and filter a "view" (Drupal background ) by e.g. City or postal code out of the map marker field when retrieving all location pages? I looked at the skyscraper demo but it is hard to understand.
  11. Ok, Map Marker is working right now, but it is still not the way, I want to set it up, because the address is in on field an not divided in Street, Postal Code, City. Any ideas how to do this?
  12. It is working for me now, I guess it is a problem within your template file @alec.
  13. What do you mean? I added the map field to the home template and then edited the home page, put an address into the map field. I then edited the home.php template file and the _main.php. No errors as far as i can see.
  14. Yes, the field is called map. This is working fine: $page->map->address $page->map->lat $page->map->lng $page->map->zoom I changed the code to your suggestion, now there is no error message anymore, but still no map...
  15. Hello! I want to build a page with these fields: Street, Postal Code, City Call it an address Then I want to take this address, geocode it and display it on a map. How can I achieve this? I started with Map Marker (Google Maps) and Leaflet Map Marker but I am not able to get them working. Is there any other possibility? I am not a php programmer, I can't code a module for that.
×
×
  • Create New...