Jump to content

iNoize

Members
  • Posts

    165
  • Joined

  • Last visited

Everything posted by iNoize

  1. thanks for you advice. ive tried this example but its sort for me like this A A A B B B but i need a d h b f i c g j I think its much more simpler. in the theory i get the count divide it trough 3 dan loop from to every time ? ist it so ?
  2. Hi, something like this in the attachment. i have 3 divs with bootstrap eg <div col-md-4> column 1 </div><div col-md-4> column 2 </div><div col-md-4> column 3 </div>
  3. Which hoster is it ? Could you give more infos about your environment ?
  4. Thank you ver much. It works fine for me. Now i need to loop the array trough three divs. Could you give me also some advice ? My idea was to get the count of all $pages and divide it. Then loop for every col from to. $lastLetter = ''; $out = ''; $letters = array(); $anzahl = $pages->count("template=kunde, bereich=$bereich"); // here I have the count but how to llop now trough three divs? $kunden = $pages->find("template=kunde, bereich=$bereich, sort=title"); foreach($kunden as $tag) { $letter = strtoupper(substr($tag->title, 0, 1)); if($letter != $lastLetter) { if($lastLetter) $out .= "</ul>"; $out .= "<h3 id='letter_$letter'>$letter</h3>"; $out .= "<ul class='tags posts-group'>"; $letters[] = $letter; } $lastLetter = $letter; $out .= "<li><a href='{$tag->url}'>{$tag->title}</a> </li>"; } $out .= "</ul>"; echo "<p class='jumplinks'>"; foreach($letters as $letter) { echo "<a href='./#letter_$letter'>$letter</a> "; } echo "</p>"; echo $out;
  5. Hello, i need to sort $pages by the first letter an show on the page like A - Aname Page - Aname Page - Aname Page - Aname Page B - Bname Page - Bname Page - Bname Page - Bname Page How can i check which is the first letter from the page.title ?? Tnx
  6. Hello, i have an call where i select my pages with different parameters. $kundenliste = $pages->find("template=referenz, limit=8, images.count>0, unternehmen.count>=1, sort=random"); unternehmen is an Page tv where I associate the pages to the project. so i get an array of ID's foreach ($kundenliste as $kunden) { echo $kunden->unternehmen."<br>"; } how i can create a new pageArray so that i can loop the id's and get the title , images , headline values from the unternehmen ?? because foreach ($kundenliste as $kunden) { echo $kunden->unternehmen->images->first()->url; } dont really works for me.
  7. had the same error after 2 days of searching and trying is this the solution /etc/apache2/mods-available/fcgid.conf <IfModule mod_fcgid.c> FcgidConnectTimeout 20 MaxRequestLen 104857600 // you have to increase the value <IfModule mod_mime.c> AddHandler fcgid-script .fcgi </IfModule> </IfModule>
  8. Wow that was fast For the first time it works currently for me Thank you. I will test it out on the weekend
  9. Hello, thanks for the Module. is it possible to add also feed by hashtag ? Thanks
  10. Yes you are right, I don't understand why it's here so broken view. I use SublimeText and there seems to be ok. If I paste it to the Forum than I have this result. Don't understand why ?
  11. @Ferdi it works because i bootstraped pw with include("./index.php"); that was the solution. I dont know its the best solution but i solved this with ajaxContentAdded: function(){ jQuery(".book_submit").click(function(){ var name = jQuery(".book_online_form #name").val(); var email = jQuery(".book_online_form #email").val(); var date = jQuery(".book_online_form #reservation-date").val(); var time = jQuery(".book_online_form #reservation-time").val(); var message = jQuery(".book_online_form #message").val(); var contact = jQuery(".book_online_form #contact").val(); var submit = 'submit'; var success = jQuery(".book_online_form .returnmessage").data('success'); jQuery(".book_online_form .returnmessage").empty(); //To empty previous error/success message. //checking for blank fields if(name==''||email==''||contact==''||date==''||message==''){ //alert("Please Fill Required Fields"); jQuery('div.empty_notice').slideDown(500).delay(2000).slideUp(500); } else{ // Returns successful data submission message when the entered information is stored in database. jQuery.post("./book.php",{ xx_submit:submit, xx_name: name, xx_email: email, xx_date: date, xx_time: time, xx_message:message, xx_contact: contact}, function(data) { jQuery(".book_online_form .returnmessage").append(data);//Append returned message to message paragraph if(jQuery(".book_online_form .returnmessage span.book_error").length){ jQuery(".book_online_form .returnmessage").slideDown(500).delay(2000).slideUp(500); }else{ jQuery(".book_online_form .returnmessage").append("<span class='book_success'>"+ success +"</span>") jQuery(".book_online_form .returnmessage").slideDown(500).delay(4000).slideUp(500); //setTimeout(function(){ $.magnificPopup.close() }, 5500); } if(data==""){ jQuery(".book_online_form")[0].reset();//To reset form fields on success } }); } }); and in the php coe if($input->post->xx_submit) { Thanks
  12. Hello, I try to realize some booking form via jQuery.post method. It works to send the data to the book.php file. Whats next ? How to handle the data right. this is the JS code jQuery.post("./book.php",{ xx_name: name, xx_email: email, xx_date: date, xx_time: time, xx_message:message, xx_contact: contact}, function(data) { jQuery(".book_online_form .returnmessage").append(data);//Append returned message to message paragraph if(jQuery(".book_online_form .returnmessage span.book_error").length){ jQuery(".book_online_form .returnmessage").slideDown(500).delay(2000).slideUp(500); }else{ jQuery(".book_online_form .returnmessage").append("<span class='book_success'>"+ success +"</span>") jQuery(".book_online_form .returnmessage").slideDown(500).delay(4000).slideUp(500); setTimeout(function(){ $.magnificPopup.close() }, 5500); } if(data==""){ jQuery(".book_online_form")[0].reset();//To reset form fields on success } }); It works for me i get the data but what now ? how to handlte this right ? this is the post.php <?php include("./index.php"); // include header markup $sent = false; $error = ''; $emailTo = 'my@email.here'; // or pull from PW page field // sanitize form values or create empty $form = array( 'fullname' => $sanitizer->text($input->post->name), 'email' => $sanitizer->email($input->post->email), 'comments' => $sanitizer->textarea($input->post->message), ); print "CONTENT_TYPE: " . $_SERVER['CONTENT_TYPE'] . "<BR />"; $data = file_get_contents('php://input'); // Dont really know what happens but it works print "DATA: <pre>"; var_dump($data); var_dump($_POST); var_dump($form); print "</pre>"; if($input->post->submit) { $name = $_REQUEST['xx_name']; echo "Welcome 1". $name; // DONT WORK }else{ echo "Something is wrong on the submit "; } if( $_REQUEST["xx_name"] ) { $name = $_REQUEST['xx_name']; echo "Welcome 2". $name; // WORK } I have attached the output. how to act with the pw $input->post->submit and the form array for example ??
  13. Hello, I want to use one core but different templates for the pw site. I know it's possible with MobileDect plugin and settings in the config file for different domains to use different templates. The problem is I don't know how to combine this method right. If desktop should use the normal domain if some kind of mobile should use the m.domain.com address. How to recognize and switch to the right domain ?? Desktop. www.domain.com Mobile. M.domain.com Some advice please ? Tnx
  14. Hello, i have several groups as pages for objects. called $gruppe echo $gruppe // delivers eg 1045| 1043 |1041 how can i check for example if($gruppen ~= "1045"){echo "in the gruop ";} which is the right way to check this ? Tnx
  15. Ok thats really from customars site problem, I cant reproduce this error. tried to upload 80MB Files and it worked. I think about to use this one https://processwire.com/talk/topic/6377-fieldtypeselectfile-inputfieldselectfile/ for the customer. Is there maybe an module where i can handle like input field file ? Here i can only select the files and output the names. no description or something like this.
  16. So there is no way to fix it ? <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> <html><head> <title>500 Internal Server Error</title> </head><body> <h1>Internal Server Error</h1> <p>The server encountered an internal error or misconfiguration and was unable to complete your request.</p> <p>Please contact the server administrator, service@webmailer.de and inform them of the time the error occurred, and anything you might have done that may have caused the error.</p> <p>More information about this error may be available in the server error log.</p> </body></html> Thats the error that the user gets or if I try to upload with smaller connection.
  17. Hello, how to hook the Module right. I need for an document e.g id = 1033 to target blank my custom url. Which is the best way to realize that ? Tnx
  18. These are PDF files. I cant reproduce the error so i think also its the max_execution_time Tnx for the advice i will try to raise the value
  19. Hello, i have some problems with the file upload. On my own Internet connection it works pretty fine. The customer had an slowly internet conection so it takes several minutes to uplad an 5MB file. At 100% stop it and dont really upload. Is there a way to upload the files simpler in the backend for the customer with the slowly connection ? What could be the reason ? Tnx
  20. I heard first time from Mar also as MadeMyDay here in the Forum. He was some kind of mentor for me for MODx. Even though I was sometimes annoying, he always had an answer via Twitter or Forum So i worked one or two years with MODx. After I noticed that he is on a new CMS called processwire i had start to read about it. It took some time to understand this. But now Im in love with PW
  21. hmm but it doesent relly work for me still ? why ? The testmail works but the Module not really.
  22. Dont really wortk for me with the FrontendUser Module <?php include('./_head.inc'); // include header markup $modules->get('EmailAdminNewUser'); // lade Modul um den Admin zu benachrichtigen ?> <div class='container paddingtop100'> <div class='row'> <div class='col-md-4'></div> <div class='col-md-4'><img class='img-responsive' src='../site/assets/files/1/pluco-logo.jpg'/></div> <div class='col-md-4'></div> </div> </div> <section class="contain nav-link "> <div class="register weissbg"> <div class="small text-center" ><?=$page->body_m ?></div> <div class='container '> <div class='row'> <?php $fu = $modules->get('FrontendUser'); // prepare login form (default parameters) $fu->login(); // Default parameter //$fu->login(array('username', 'password')); echo "<h4>Registrierte Nutzer hier anmelden</h4>"; // Additional LoginPersist and ProcessForgotPassword module integration (built-in) $fu->login(array('username', 'password', 'forgot')); // process login / form submit $fu->process('../objekte/'); // output form echo $fu->render(); ?> <?php echo "<br /><h4>Nutzerregistrierung</h4>"; $u_vorname = $modules->get('InputfieldText'); $u_vorname->label = $this->_('Vorname*'); $u_vorname->attr('id+name', 'u_vorname'); $u_vorname->required = 1; $u_vorname->fhSanitizer = 'text'; $nachname = $modules->get('InputfieldText'); $nachname->label = $this->_('Nachname*'); $nachname->attr('id+name', 'nachname'); $nachname->required = 1; $nachname->fhSanitizer = 'text'; $unternehmen = $modules->get('InputfieldText'); $unternehmen->label = $this->_('Unternehmen*'); $unternehmen->attr('id+name', 'unternehmen'); $unternehmen->required = 1; $unternehmen->fhSanitizer = 'text'; $strnr = $modules->get('InputfieldText'); $strnr->label = $this->_('Strasse / Hausnummer*'); $strnr->attr('id+name', 'strnr'); $strnr->required = 1; $strnr->fhSanitizer = 'text'; $plz = $modules->get('InputfieldText'); $plz->label = $this->_('Plz / Ort*'); $plz->attr('id+name', 'plz'); $plz->required = 1; $plz->fhSanitizer = 'text'; $tel = $modules->get('InputfieldText'); $tel->label = $this->_('Telefonnummer*'); $tel->attr('id+name', 'tel'); $tel->required = 1; $tel->fhSanitizer = 'text'; $fu->addHookBefore('save', function($event) { $form = wire('fu')->form; $user = wire('fu')->userObj; $user->addRole('registered'); if(!count($form->getErrors())) { wire('fu')->userObj->u_vorname = $form->fhValue('u_vorname', 'text'); wire('fu')->userObj->u_nachname = $form->fhValue('nachname', 'text'); wire('fu')->userObj->u_unternehmen = $form->fhValue('unternehmen', 'text'); wire('fu')->userObj->u_hausnummer = $form->fhValue('strnr', 'text'); wire('fu')->userObj->u_plzort = $form->fhValue('plz', 'text'); wire('fu')->userObj->u_telefonnummer = $form->fhValue('tel', 'text'); } }); // Call hook after field is processed by PW form api // prepare register form $fu->register(); // Default parameter //$fu->register(array('username', 'email', 'password')); // Additional email pre-register validation plugin (built-in) $fu->register(array('username', $u_vorname, $nachname, $unternehmen , $strnr, $plz, $tel, 'email', 'password')); // process register / form submit $fu->process('../registrieren/aktivation/'); // output register form echo $fu->render(); echo "<p class='small description'>* Gekennzeichnete Felder sind Pflichtangaben<br />Nach der Freischaltung erhalten Sie umgehend eine Bestätigungs-Email mit Ihren Login-Daten.</p>"; ?> </div> </div> </div> </section> <?php include('./_foot.inc'); // include footer markup ?> whats the mistake here ?
  23. oh , Ive seen it on other Forum Page so i used it as code
×
×
  • Create New...