Jump to content

hollyvalero

Members
  • Content Count

    86
  • Joined

  • Last visited

Community Reputation

13 Good

About hollyvalero

  • Rank
    Full Member
  • Birthday 09/14/1962

Contact Methods

  • Website URL
    http://hollyworks.com
  • Skype
    hollyvalero

Profile Information

  • Gender
    Female
  • Location
    Maine

Recent Profile Visitors

1,252 profile views
  1. I've got the maps working on the front end and back end... got a single map with all points, and individual location maps on their pages. API set, account hooked up, everything seems to be awesome. I just want to output the street address in addition to the map, so I popped in: <?php echo $page->marker->address; // outputs the address you entered But when I do I am getting the full address PLUS lat./long and a little [n/a]->address - and want the FORMATTED ADDRESS: 621 W Manchester Blvd, Inglewood, CA 90301 (33.961857, -118.367332, 12) [N/A]->addres ^ that's the formatted_address from Google maps... from the previous 25 pages of historic notes it seems that there's no easy way to extract this. Any $page->map->address, lat, lon - all returns the same feed, no doubt due to Google changes. Options currently seem: - long reverse engineering of the address and JSON parsing, - adding a second field and asking the data entry people to enter data twice... - using another script like Ryan's and coding via the API... Happy to have gotten this working aside from this for the sake of getting it to work, and the map with all markers is lovely...but considering Google's charging for clicks? The Google Maps Text Formatter may be the easiest way to accomplish this for sites with light mapping needs.
  2. I have a pro fields repeater field that I am using for page top alerts on a home page (thank you, COVID-19) ... this dedicated set of repeaters could have more than one type. --> repeater field is called cblock_alerts --> the first matrix type is alert I have limited the entry to 2 in the back end (assuming one live and one in reserve) but I only want ONE to show up so you don't get stacked alerts. Normally I repeat everything in my repeaters so the code looks like: if ($page->cblock_alerts) { foreach ($page->cblock_alerts as $item) { if ($item->type == 'alert') { echo " I've tried several find, get, limit, and they all either don't work, show nothing, or show both repeaters. I don't really need the foreach here, but there could be another matrix item so the item type == alert is needed. I'm looking for something like this: if ($page->cblock_alerts) { foreach ($page->cblock_alerts as $item) { if ($item->type == 'alert') { $firstalert = $item->first(); echo " or $firstalert = $item('limit = 1'); Lots of variations on these with no luck. Tried random... grrrr.
  3. That is - in fact - exactly what I do. I have a variety of pre-staged set ups for different purposes... I checked my set ups and they all had access for the trash to the editor... but this was a website I created about a year ago... it didn't include it, but now it does. 🙂
  4. Thank you, Robin... every time I figure one of these things out, I add it to my screensaver so all day I see messages like "don't forget to...{whatever}"... I will add this one now. 🙂
  5. I create a general "editor" role for managing web pages. And while I can go in as editor and choose the delete tab, once back at the page tree, I do not see the trashcan nor empty options. Once back in super-admin role I can see/trash. The editor role has all page delete permissions, and access to most everything but logs, advanced hanna code, db back ups, page locks and user administration. Any idea what I might need to do?
  6. Well, that explains it. I had ready.php in the templates folder, not up a level in the /site/ folder. I figured it had to be something stupid and I was right 😂 At least now I can get into hooks more... thank you!
  7. Making my semi-monthly attempt to get into hooks 🤪 I tried adding Ryan's renderLinks to ready.php at one of my sites... and then tried various versions of the usage, like: echo $pages->find("parent=/")->renderLinks(); in the templates. I take it as a sign of progress that I am past the 500 server error, but the output I get is the single word "array" this is not urgent of course, but wondering if someone can point me in the right direction?
  8. First of all, thank you so much for taking the time to slog through the set up - and all the screen snaps. I switched the url redirect "/login/" to the page ID to see if that might help, but I think what I did wrong was that --> on the login page template, the editor role could view and EDIT<--. Not just view. All the rest looked the same as far as the set up. I agree that it's a better practice to create a new role instead of just using login-register. Those changes seem to have fixed it... and the redirect($goto) is working too. I assume maybe the login template can be only view access. Let me just add that bit of wisdom to my "when the bad thing happened" file. 🙂 THANK YOU so much!! In the meantime I looked at Login Register Pro ... hopefully can offer either. h
  9. 1. using LoginRegister for a simple username/password to view a demo course. Vanilla installation: $modules->get('LoginRegister')->execute() Login url is /login/ using login template that anyone can see -> and that's working. when not logged in, you see the form. When logged in you see a logout link and copy that shows up upon logging in. -> that's working 2. There is 1 template: demos (for the actual videos) - viewable for login-register role, but not for guest. I have set the template to redirect to: /login/ if you are not logged in. when I go to the demo URL not logged in, I am bumped to /login/ -> that's working. http://test2.hollycodes.net/shop/view-demo-training-videos/security-awareness-for-it-professionals-demo/ 3. the guest role can page-view all except demos and login-register role can see all pages 4. When logged in as super user, I see all pages correctly 5. HOWEVER If I go here: http://test2.hollycodes.net/shop/view-demo-training-videos/ and follow the link to login: http://test2.hollycodes.net/login/ and enter frank daypass123 I get Welcome frank...and the welcome copy and a link to go to the courses... But when I click that course link to the demos template, it bounces me back to the login page, despite being logged in. ----> What am I doing wrong? <------ a. I was originally going to use login/register pro, but it seemed like overkill for a simple u/p combo... b. Then I tried to automatically bounce people back to the course list after logging in: <?php if($user->isLoggedin() && !$input->get('profile') && !$input->get('logout')) { $session->redirect('/shop/view-demo-training-videos/'); } else { // let the LoginRegister module have control echo $modules->get('LoginRegister')->execute(); } but the login just cycled between /shop/view-demo-training-videos/ and /login/ and melted down. Which seems like I should change it in the template, but that just makes no sense... ----> What am I doing wrong? <------ I uninstalled login/register pro, there's nothing in the error logs... tried it in a fresh browser - same issues What dumb thing am I missing here?
  10. Ha ha! Thank you for all your help. I did use Tracy Debugger when I first started and I wasn't skilled enough for it to be helpful... I will try that again! Good idea!
  11. THAT'S very cool. Just need to figure out what the "d" in d($products) means.
×
×
  • Create New...