Jump to content

Lance O.

Members
  • Posts

    371
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Lance O.

  1. Is there a way to hide specific users on the Access > Users page from other PW admins that are able to administer users?
  2. I have a custom login page where a user should be directed to a members only page when the form is submitted and the user has been validated. What is wrong with my logic in the code below? Regardless of the user's role, the user is never authenticated and displays as a guest. if ( $input->post->user || $input->post->pass ) { // user submitted the login form if ( $session->login($input->post->user, $input->post->pass) ) { // user was authenticated and logged in // user has "admin" or "superuser" role foreach ($user->roles as $role) { $content .= $role->name . "<br/>"; } } else { // user is not authenticated // user is "guest" foreach ($user->roles as $role) { $content .= $role->name . "<br/>"; } } } elseif ( $input->get->logout ) { // page was accessed with ?logout=1 GET variable, so log them out $session->logout(); $content = $form; } else { // user arrived at login page for first time $content = $form; }
  3. I'm writing documentation for client training and I have a silly question. What is the "official" name of the default listing view in PW?
  4. adrian, are you suggesting that the username and the page names should be the same?
  5. That would be the ideal method. I've updated my original post to make the example clearer.
  6. But each user needs to have access to only one of those 100 pages.
  7. My client has a need to create a new PW admin user and assign permissions that restrict access to only one assigned page of the site on the frontend. Each user only has access to the single page that is assigned to them. Example: User #1 -> Page #1 -> Access User #1 -> Page #2 -> No Access User #1 -> Page #3 -> No Access User #2 -> Page #1 -> No Access User #2 -> Page #2 -> Access User #2 -> Page #3 -> No Access User #3 -> Page #1 -> No Access User #3 -> Page #2 -> No Access User #3 -> Page #3 -> Access etc. There may be 100 different users that all need access to just their page. Without having to create 100 templates and manage access through the template, what is currently considered the best method for restricting page access? All of these pages should use the same template.
  8. This issue may have been answered earlier, but I'd like a little clarification if possible. The site I am developing has one section that is translated into French Canadian. Only the pages in this section are translated. The site's Home page is only in English, which is the default language. The English name setting on the Home page is blank, and the French name setting is "fr". All of the pages in the translated section have the Active? checkbox next to the French name on the Settings tab checked. No other pages have this option checked, including the Home page. URL examples: http://domain.com/drainage-pipe-products/ http://domain.com/fr/drainage-pipe-products/ When viewing the http://domain.com/fr/drainage-pipe-products/ page, links included in the page's navigation automatically include the /fr/ in the url, even though those pages don't explicitly have the Active? checkbox selected. That's not the behavior I was expecting. Is this normal behavior? If this is normal behavior, then what is the purpose of the Active? checkbox? Have I configured something incorrectly? Any insight is appreciated. I feel like there is something I'm missing.
  9. I've checked the forums for an answer that works, but I can't seem to find one. Sorry for having to post this question. Upon dragging and dropping an image into a file field in the PW admin, I receive a "Filesize 11594 kb is too big. Maximum allowed is 8192 kb." error. I've updated the PHP ini settings to the following, yet I'm still receiving the error: file_uploads = On max_execution_time = 120 max_input_time = 120 max_input_vars = 1000 memory_limit = 512M upload_max_filesize = 50M I'm using PW 3.0.33. What am I overlooking? Is there a PW config setting that I need to set?
  10. I should have mentioned that I already have those two lines commented out before I posted my question. But now that I check the sitemap.xml file again, the "www" has been added to the urls. Looks like it may have just been a caching issue. Thanks for your insight!
  11. Is there a way to force "www" on the links generated in the sitemap.xml file?
  12. @cb2004 This is exactly what I needed. Thank you!
  13. Is this module compatible with PW 3.x? I just installed it but the Help tab isn't displaying for the designated template.
  14. These are great suggestions! I'll have to play around with each to see which one is the most promising. Thanks, everyone!
  15. Does anyone know of an alternative to fancybox? http://fancyapps.com/fancybox/ I've been using fancybox for years, but am finding issues with Google Tag Manager, so I'm looking for a "modern" replacement. I need the alternative to support images and hosted videos. I'm curious to know what experiences you've had with the other options out there.
  16. I have a site that is included in the "Sites Running ProcessWire" section of the PW site. How do I go about updating information on an existing entry?
  17. @teppo, thanks for the very quick response. I've implemented these changes and everything is working smoothly now. Thank you!!!!
  18. I know this question has been asked before, but in this case, I don't want to use a PW module. I have added redirects at the very top of my .htaccess file, formatted like the examples below: RedirectMatch 301 /onsite2/ http://domain.com/ Redirect 301 /onsitefocusedthanks/ http://domain.com/club/ Unfortunately, the redirects are going to: http://www.domain.com/onsite/ (404 page not found) http://www.domain.com/club/?it=onsitefocusedthanks/ Is there a way to removed the "?it=index.html" and prevent these redirect errors?
  19. Selections aren't being retained or are being automatically selected/deselected in the "Template Types" area under the "Details" tab. If I make multiple edits to these checkboxes and save the page after each edit, the module is confused about my settings and messes up what I selected. :-(
  20. I upgraded from PW 3.0.15 to PW 3.0.17 and the alt attribute still didn't work. Frustrated, I then downgraded to PW 2.7.2 and it still doesn't work. :-( At some point I had the ImageExtra fieldtype module installed, but it has since been removed. Is there the possibility that it broke something? I've already had problems with uploading images that required some manipulation of the database structure. https://processwire.com/talk/topic/13078-error-when-uploading-image-field-caption-doesnt-have-a-default-value/ Here is the field export for the Body field, if that helps: { "body": { "id": 98, "type": "FieldtypeTextarea", "flags": 0, "name": "body", "label": "Body", "qtyMin": 1, "qtyMax": 10, "trashable": 1, "size": 0, "maxlength": 2048, "inputfieldConfigNames": "rows,toolbar,inlineMode,useACF,usePurifier,toggles,formatTags,extraAllowedContent,contentsCss,contentsInlineCss,stylesSet,extraPlugins,plugin_sourcedialog,removePlugins", "schemaClass": "FieldtypeTextarea", "inputfieldClass": "InputfieldCKEditor", "contentType": 2, "pageLinkAbstractor": 2, "rows": 9, "toolbar": "Format, Styles, -, Bold, Italic, -, RemoveFormat\nNumberedList, BulletedList, -, Blockquote\nPWLink, Unlink, Anchor\nPWImage, Table, HorizontalRule, SpecialChar\nJustifyLeft, JustifyCenter, JustifyRight, JustifyBlock\nPasteText, PasteFromWord\nScayt, -, Sourcedialog", "inlineMode": 0, "useACF": 1, "usePurifier": 1, "formatTags": "p;h1;h2;h3;h4;h5;h6;pre;address", "removePlugins": "image,magicline", "sortable": 1, "collapsed": 2, "extraPlugins": [ "pwimage", "pwlink", "sourcedialog" ], "textformatters": [ "TextformatterVideoEmbed", "TextformatterHannaCode" ], "contentsCss": "/site/modules/InputfieldCKEditor/contents.css", "extraAllowedContent": "div(*)\n*[id](*)\n*[class](*)", "icon": "code", "notes": "Enter a full YouTube or Vimeo URL by itself in any paragraph and it will automatically convert it to an embedded video.\n\nYour link must match one of the formats below:\nhttp://www.youtube.com/watch?v=**video_id**\nhttps://vimeo.com/**video_id**\n\nExamples:\nhttp://www.youtube.com/watch?v=Wl4XiYadV_k\nhttps://vimeo.com/152189763", "htmlOptions": [ 4 ], "showIf": "", "columnWidth": 100, "required": "", "requiredIf": "", "toggles": "", "contentsInlineCss": "", "stylesSet": "", "customOptions": "", "plugin_sourcedialog": "" } }
  21. @tpr I'm using PW 3.0.15 and that option is labeled as: Update image alt attributes: Replace blank alt attributes with image description With this option checked on the Body CKEditor field, I uploaded an image, entered a description, and inserted it into the Body field. The alt attribute remains empty. Perhaps something broke between the two versions we are using? @szabesz Looks like that page references an earlier version of PW. Hopefully this will all be updated in a future version of PW.
×
×
  • Create New...