-
Posts
323 -
Joined
-
Last visited
Everything posted by quickjeff
-
Hi Mike, we must have missed this last piece, since that was the last element added to replace a previous message. We simply commented out the previous message temporarily as we have something sweet cooking up to release soon! Thanks for the catch, it is now fixed!
- 6 replies
-
- 1
-
-
- development site
- design site
-
(and 2 more)
Tagged with:
-
Hi Guys, So we have been working with ProcessWire for sometime now. We absolutely love ProcessWire so much that we have changed our site from a custom build on a custom CMS to WordPress and now ProcessWire and will never go back to anything else. We launched a small version of our site to test the migration from WordPress a couple months ago and now have finalized a new look and feel. We are a small team based out of the Chicagoland area that is eager to grow. Our go to CMS is ProcessWire for our clients. Please take a peak at: QuickToImpress.com We are currently running the latest version of ProcessWire with Template Editor Module. We are looking to start building some of our own modules in the near future. Ryan Cramer, thank you for such an incredible CMS. ProcessWire community, thank you for such an amazing group of fellow developers, designers and SEOS. You guys are all great and have helped us grow so much with answers to API questions, suggestions and advice.
- 6 replies
-
- 9
-
-
- development site
- design site
-
(and 2 more)
Tagged with:
-
I solved my own issue, I ended up using one image field and using the limit=1 method. Works like a charm!
-
Hi Guys, So I am working on a project and wanted to get the best advice using the api on the next step. I have two image fields in one template. postimage which holds an image for the article and postimage2 which holds an image for the home page. Basically I want to make it so that when a user uploads postimage and not postimage2 the home page will just pickup postimage instead. If the user does upload postimage2, it should pick up postimage2. What I did: I did add a conditional statement to check if postimage2 was empty to simply default to postimage but I was not seeing any images display. Here is my code: <?php foreach($featured as $featuredp){ foreach($featuredp->postimage2 as $postimages2) { echo"<div class=\"row panel\" style=\"margin:20px auto;\">"; echo"<div class=\"large-4 columns\"><p> <a href='{$featuredp->url}'><img src='{$postimages2->url}' width=\"300\"/></a></p></div>"; echo"<div class=\"large-8 columns\"> <h4>{$featuredp->title}</h4> <p><em>{$featuredp->date}</em></p> <p>{$featuredp->summary}</p> <p><a href=\"{$featuredp->url}\" class=\"button tiny radius\">Read More</a></p> </div> </div>"; $found = 1; } } if ( ! $found ) { echo"<p>Sorry, no posts.</p>"; } ?> Any advice is appreciated? Also any suggestions or workarounds are also welcome!
-
Repeater, check to see if the repeated element is first.
quickjeff replied to quickjeff's topic in General Support
Thats right, lol. I used a counter for grabbing images from another template. Totally forgot about this method. Thanks Adrian!- 2 replies
-
- 1
-
-
- repeater
- conditional statement
-
(and 1 more)
Tagged with:
-
Repeater, check to see if the repeated element is first.
quickjeff posted a topic in General Support
Hi Guys, I have created a slider using Bootstrap and in Bootstrap the slider image that is first in line is required to have the class active. In creating a repeater for my client to add images, I need to add a conditional statement to check if the item is first in the repeated elements and if it indeed is first, assign active as the class. Not sure what is best practice using a selector and the api to see if the the repeated element is first in the repeater list. Any light? Thanks guys!- 2 replies
-
- repeater
- conditional statement
-
(and 1 more)
Tagged with:
-
@gebeer so you want to totally prevent the frontend user from ever accessing the main processwire admin right?
-
The way I successfully did this is redirecting the user to a profile page, where they can manage their profile, change password etc. The profile page is a hidden page that displays the users info using a different template I created. Then once they logout I redirect them to another page, like the home page. Last, change your main admin/backend page to a tricky url that is pretty hard for them to guess. This will eliminate the issue. Hope that helps.
-
Unable to delete an image inside a repeater(after upgrade)
quickjeff replied to quickjeff's topic in Modules/Plugins
Thanks for this, I have added to Github. -
Hi Guys, Has anyone else encountered this issue? Unable to delete an image from an image field located inside a repeater? For some reason after upgrading to latest stable version of PW, this started happening. The only solution is to delete the entire repeated element, versus just the image in the repeated element. Trying to find a fix still, no luck.
-
Any solution? I am having the same issue. :-(
-
Reno Theme Not working Properly after upgrading to 2.5.2
quickjeff replied to quickjeff's topic in General Support
Sweeeet! That works! -
Reno Theme Not working Properly after upgrading to 2.5.2
quickjeff replied to quickjeff's topic in General Support
Wow, solved it thanks Joss!!! Although, I feel silly now for not digging a little deeper. Thank goodness for the solid community! -
Reno Theme Not working Properly after upgrading to 2.5.2
quickjeff posted a topic in General Support
Hi Guys, Not sure if anyone else has experienced this yet but I did an upgrade on a client site using the upgrade module. After upgrading to 2.5.2 stable version. Reno says it is enabled but it doesnt look the same at all. It looks like the default admin theme. Anyone experience this as well? -
@uliverse, Haven't setup the auto paid memberships yet. Currently have its a manual process. :-(
-
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Mindfull, success! Thanks! -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Okay, so after trying multiple things I still cannot get the form to validate the page id that is being submitted. By validate I mean, check that the page id, that is being submitted, is indeed a page that the user has been assigned too. (Pages assigned via MODULE: PageEditPerUser). Please note, this form is not located on the page a user can edit, it is on another page I have as their account manager page. It displays every page they can edit. Here is the code so far, thanks to Kongondo major major help!!! Note: If its easier to add two buttons, one unpublish and the other publish, I am good with that route for now. <?php //was a delete request sent... if($input->post->delete) { //this will be in the form of delete=xxxx where xxxx is the page ID. Check in Firebug $deletePage = $input->post->delete; $id = (int) $deletePage;//sanitize post value to integer $p = $pages->get($id);//get this one page whose ID was sent over using its delete button $title = $p->title; $p->trash();//as a backup in the interim, we trash the page instead of deleting it. echo '<div data-alert class="alert-box success radius"> The post ' . $title . ' was successfully deleted! <br><br><a href="/profile" class="button small secondary" style="color:#000;">CONTINUE</a> </div>';//there are better ways to check! } else { $out = '<form action="./" method="post"><ul>';//this form posts to self foreach ($user->editable_pages as $aPage){ $out .= '<li><a style="color:#000;" href=' . $aPage->url . '><span class="label success radius">View / Edit</span> <br><br> <strong>' . $aPage->title . '</strong></a></span><br><button type="submit" class="button tiny alert radius" name="delete" value="' . $aPage->id . '">DELETE</button></li><br><br><br>'; } $out .= '</ul></form>'; echo $out; } ?> -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Still having a hard time checking to make sure the user has been assigned to delete the page he is deleting. I need to figure a way to check to verify that the user has been assigned to the page he is deleting. Since I am displaying the pages a user has created on their account manager page, and simply pulling the id from those pages and using Kongondos suggestion of deleting a page, I cannot figure how to verify the page they are deleting is indeed their assigned page. The reason I wan to verify is because I used inspect element tool from Google Chrome and changed the ID in the code and was able to delete another page another user created. :-( I use the module Ryan buit per user per page edit to assign users first off. Anyone? :-( -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Gotcha. Yes basically need only display the pages they created but only allow them to delete the pages they create, that would be the essential goal. -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Kongondo, Thanks for the response, basically no limit at the moment for users. Also haven't set a max limit of pages the users can create, I haven't even thought about the limit yet. I guess my next silly question would be, how and where would I be able to limit the user page creation? :-( Also the frontend_editor role is assigned to a user that registers to post pages on the site. They register to post pages, similar to craigslist. As soon as the user is created, they are assigned the role of frontend_editor. -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Awesome! Thanks for the guidance. I did check permissions on the user role I created, this user is assigned frontend_editor which I enabled to only edit or view certain pages, yet they are able to delete. I need to have a deeper dive and verify the delete doesn't work just for anyone. I also need to make sure the user cannot delete others page and only his assigned pages. Thanks again. -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
@Kongondo Ran into an issue. As I was testing the security side of things, if a user were to login to their account, go to their page to delete the page, the user is successful once they delete the page. However, if a user is dev savvy and attempts to use inspect element or firebug, they can view the source and type in another id and then hit submit, guess what happens next? They can delete the page associated with the id they just replaced in the source code via firebug or inspect element. This puts the site at risk of a malicious user. Any suggestions to verify the user is indeed assigned to the page before the page is actually deleted? Thanks. -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Kongondo, Absolutely wonderful! Not only did you help, you really explained things clearly. I successfully added the delete button! Now I need to figure out the publish and unpublished or as the user see's it undelete by the very least. Thanks soooooo much! -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
Kongondo, Below is the code used for the template the account manager page is using. As you can see, I am able to pull the page ID but not sure what else to do after this. I had written some other code on another template but decided this route would be better. <?php include("./head.inc"); ?> <div class="row supersize"> <div class="medium-12 columns" > <div class="medium-4 columns"> <p> </p> </div> <div class="medium-4 columns"> <div align="center"> <h1>Account Manager</h1> <p>Welcome <?=$user->name?></p> <div class="panel callout radius"> <p>Select your post to edit:</p> <!--Below will display the pages a user is assigned to edit or the pages they have created, they are also links to the page--> <ul class="side-nav"> <?php foreach($user->editable_pages as $aPage){ echo "<li><a href='$aPage->url'>$aPage->title</a></li><br>"; echo "<li><a class='button alert tiny' href='$aPage->id'>DELETE POST</a></li><br><br><br>"; //I would like to also echo a button that is tied to each page link being displayed that allows for the user to delete the page, un publish or republish. Essentially it may be up to 3 buttons.// } ?> </ul> </div> <?=$page->body?> </div> </dd> </dl> </div> <div class="medium-4 columns"> <p> </p> </div> </div> </div> <?php include("./foot.inc"); ?> -
Integrating a member / visitor login form
quickjeff replied to thetuningspoon's topic in General Support
I guess first I need to check if a page is editable by that user. I'm using Ryan's module per page edit. Trying to write a script to first check the page if user has editing rights to the page not just editing permission, first since the page is using fedi front end editor. No success. :-(