Jump to content

RyanJ

Members
  • Posts

    208
  • Joined

  • Last visited

Everything posted by RyanJ

  1. Truly grateful for the explanation and framework Ryan. Thanks!
  2. @Soma. You are a lifesaver . I had previously tried to add the rel to the valid elements, but I was adding it in a[href|target|name] Amazing what happens when its in the right one. I also added the advlink plugin, but it was not working properly, so I am assuming the two go hand and hand. Thanks so much for the instructions, they are greatly appreciated.
  3. Could someone please advise on a solution for the nofollow. The above solution by gandablond does, not work. I also do not want a nofollow added to every link. And when added manually, TinyMCE strips it. Thanks in advance. If no solution is available, how do I prevent the tinymce from stripping my rel attribute?
  4. This has been extremely helpful for both learning the framework and php in general. I was hoping someone could help explain a few things in further detail as I am really new to Processwire and somewhat new to php other the working with WordPress. I have used Soma's code example which is extremely useful and altered it to my needs. I am attempting to create a simple contact form, but was unsure of a few things. Below, she provides a validation check for any hotmail addresses. Are there any other validations required or suggested if you are planning on having the submissions emailed to you? IE, check if is a valid email address with FILTER_VALIDATE_EMAIL or is this done for you $email = $form->get("email"); if($email && (strpos($email->value,'@hotmail') !== FALSE)){ // attach an error to the field // and it will get displayed along the field $email->error("Sorry we don't accept hotmail addresses for now."); } Secondly, any tips on how I would send the values submitted by email to the admin user or any user/email? $email = $form->get("email")->value; $name = $form->get("name")->value; $name = $form->get("text")->value; Thanks in advance for the community support and I am looking forward to working more with Processwire. The form builder is on my to get list and will same me hours of time, but I thought understanding the inside of it will benefit me more. Although I would still like to understand the above, I went with a similar solution others may find usefull here
  5. I thought I would just add my snippet of code that excludes a specific top page from my navigation menu. I used Ryan's example and added the notated line to it. I'm not sure if it is the best way to do it, but it works. <?php $root = $pages->get("/"); $children = $root->children(); $children->prepend($root); foreach($children as $child) { // Added to remove the site-map from my top menu. Replace site-map with the url if($child->name != 'site-map') { echo "<li><a href='{$child->url}'>{$child->title}</a></li>"; }} ?>
  6. Newb here, obviously by the title above . Searched a while as I was having the same issue as nellone. Just so others will know, the above solution will also work in wamp. Looking forward to working with pw as potentially my new go-to cms.
×
×
  • Create New...