Jump to content

NorbertH

Members
  • Posts

    211
  • Joined

  • Last visited

Everything posted by NorbertH

  1. Hi all , I get a "Headers already sent" when i call PW from the commandline. If i start output before including PW. I know that is an Issue if doing output in a webbrowser before starting the actual session but i did not expect this in a CLI call. Here is the script: <?php namespace ProcessWire; $path = "../../index.php"; $path = realpath($path); echo ("\nPath: " .$path. "\n"); include $path; Here is the Error: Path: /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/index.php PHP Warning: session_set_save_handler(): Cannot change save handler when headers already sent in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/WireSessionHandler.php on line 57 Warning: session_set_save_handler(): Cannot change save handler when headers already sent in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/WireSessionHandler.php on line 57 PHP Warning: session_name(): Cannot change session name when headers already sent in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 286 Warning: session_name(): Cannot change session name when headers already sent in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 286 PHP Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 289 Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 289 PHP Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 290 Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 290 PHP Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 291 Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 291 PHP Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 292 Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 292 PHP Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 304 Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /usr/local/www/apache24/noexec/mein-kaffe.de/processwire/wire/core/Session.php on line 304 I am not sure but shouldn't the session be started when running from CLI ?
  2. Now its nice Yellow ....still with messages that should be green .... Edit: Forgot to say i Upgraded PW to 3.0.197 dev and reinstalled the Less module ... // Primary color @rock-primary: #9f2d2d; // Margins @global-margin: 10px; @global-medium-margin: 5px; @global-small-margin: 3px; // Logo Größe .pw-logo {height: 60px !important;max-height: 60px !important;} .pw-logo-custom {max-height: 60px !important;height: 60px !important} @alert-primary-background: yellow; @alert-success-background: green; @alert-warning-background: orange; @alert-danger-background: red; The funny thing is when i set it to default template everything is perfectly OK Edit Forgot to mention i Upgraded PW to 3.0.197 dev and completely reinstalled the Less Module
  3. ... now all messages are yellow .... but still i am missing red and green i tried @alert-success-background: #32d296; @alert-warning-background: #faa05a; @alert-danger-background: #f0506e; But they are ignored... When i tried : @global-success-background: #32d296; @global-warning-background: #faa05a; @global-danger-background: #f0506e; They got ignored too ?
  4. Only seems to be an issue in the first block of notices, the next one is ok.
  5. ProcessWire 3.0.184 I installed the new Less Module set it to Rock theme and added admin.less // Primary color @rock-primary: #9f2d2d; Now all notices and messages are red. This is really annoying as users tend to call me about those "errors".
  6. I found this: But i think its overkill as i only need the template/theme not a full BE page. Content should be normally generated by the FE.
  7. I just need one or two public pages in my application, and they basically should look the same as the admin theme/template. Is there an easy way to actually use the BE theme in the frontend? Or maybe make BE pages public available ?
  8. +1 on SqLite as it would allow simple portable web applications with just an USB stick and some php binaries.
  9. As our software department is heavily overworked we need to outsource some tasks. We are looking for someone who sets up a shop whith Processwire and extends it step by step. Features needed right at the beginning: - Age verification on registration using german "Schufa" and identification via "Personalausweis" as fallback. - Registration form that is limited to certain countries. - Multiple attributes for products. - Multiple customer groups whith different prices. - Products are updated via uploaded CSV file that needs to be read into the system by cronjob. - Template is bought from Template Moster or similar source and needs to be connected to the Processwire system. - Export orders to Collmex (https://www.collmex.de/) Module for export can be done inhouse, as we have an example action for Pagelister Pro already available. - Simple blog or news page - Some static pages for imprint, privacy policy, and several other pages needed by german laws. As the specifications may change to some extend, we aim for support on an hourly basis. All Modules and reusable elements that are created may be posted in the Processwire module directory. For further questions just ask or PM me.
  10. Actually i mostly use Linux too. Just using a Xubuntu as it is lacking most the cool and modern desktop effects i not really like. Libre Office as it often is more "compatible" for opening office documents than Microsoft office itself. In addition it has far better support for CSV data files. Gimp for grafiks, Imagemagick for scripted image processing./creation. In addition Scribus and Inkscape for other tasks Vim, Mousepad, Atom, Jedit, PHP-Storm as editor/development environment. Firefox / Thunderbird for web and communication. On the server side i almost never used anything else than Linux/BSD. Apache, NGINX, MariaDB, MySQL, PostgreSQL, PHP, Perl, Python, Bash .... What else do i need ? ?
  11. Using this field in conjunction with a lister , i can select its subfields like width or height for the lister, but there is no content shown. The button field i although used seems to have this functionality , its subfields appear in the lister. But to be true i cant figure out whats wrong.
  12. Yep was talking about that. What hapens when i emty it completely ?
  13. Where did you get the original file , cannot find it in the theme folder in the PW download? Using the default file it should just look like the default UiKit theme, right ?
  14. I tried to use this tool https://getuikit.com/v2/docs/customizer.html To modify the look of my BE template. Just made some changes , downloaded the .less file and added its content to the theme.less file. This works good al long as i don't try to change some main colors. As far as i understand it you have made a copy of the default admin uikit theme , and then added a few extra variables (eg. to combine the color of the menubar and the main buttons into one var @tm-primary-color) Is it possible to just use a file whithout those modifications an completely rely on the UIKit Customizer ? Thanks in Advance!
  15. Hmmm , ok and concerning to Fields Array.php Line 16 So if we expect a fully complete $fields array all of those fields need to be initialized right at the beginning too ? The query itself shouldn't be so much time consuming? Do i see this correct having too many unused ,modules / templates does a simmilar slowdown ?
  16. Just, asking myself, why PW needs to load all fields and Templates at Startup. Schould be possible to store installed fileds/tamplates in a DB and load this at startup , of possibly use some kind of autoloader? Is there some documentation about the Bootstrap process? Possibly someone could point out where to find the relevant parts in the initialisation?
  17. As we are building some webapplications with the PW backend , having those really big spacings between all field elements in forms and everywhere is not too practical. UI Kit already has less spacings between all elements than Bootstrap for example , but i am looking fore a more condensed BE Theme. Maybe someone already made something like that?
  18. Almost 100 % sure fetching all vars from a form, and put them into the page. Creating an empty page , so i can add Profields Table (You cannot add this to a not saved page), set some other values like customer and delivery address , set the table with products and then save it again. // Create page $b = new Page(); $b->template="bestellung"; $bId= $b->save(); // Set basic stats $b->bestellung_user_select=$derCustomer; $b->bestellung_liefer_addresse_select=$pages->get((int)$input->post->liefer_select); if ($input->post->liefer_select=="3826" OR $input->post->liefer_select=="3827") $b->bestellung_status_select=$pages->get(3829); // status Barverkauf else $b->bestellung_status_select=$pages->get(1047); // status bestellt $b->bemerkung_area=$bemerkung_area; // Add articles (bestellung_artikel_table) //$b->of(false); // turn off output formatting foreach($myProducts as $prod) { if (!empty($input->post->artikel[$prod->id]) AND 0< (int)$input->post->artikel[$prod->id]){ $art= $b->bestellung_artikel_table->makeBlankItem(); $art->artikel=$prod; $art->stueck=$input->post->artikel[$prod->id]; $b->bestellung_artikel_table->add($art); $b->save('bestellung_artikel_table'); } } // save it all $b->save(); // Show order successfull $okBestellt=true; // Finally delete the post array , so the form is ready to go again $_POST=array(); // Global Post array $input->post=null; // Processwire post $aStueck=array(); $bemerkung_area=""; } // END of order Very simple indeed. But it does its job. (Orderpage is just a simple frontend page) Edit: Btw. have no changing field defined so it should not look after changes ? In the BE it kicks in without any changes. As a test workaround i simply made a CLI script that simply loads all pages that are not send , and then saves them again. the Hook then kicks in and sends the pages as he should. $result=$pages->find('template=46, deny_export=0, bestellung_stueckzahl!="", bestellung_user_select.count!=0, bestellung_liefer_addresse_select.count!=0, bestellung_id_collmex="", limit=2'); foreach ($result AS $p) { echo $p->name."\n"; $p->save(); }
  19. When saving a page with the "order" template in the backend IftRunner is nice to me and sends the order via page action into my accounting software. When saving "order" in a frontend page it does nothing. So i certainly missing something . Any ideas?
  20. Hey , just found that the Tracy Panel selector shows rendering time and memory consumtion of all the panels. Maybe you like to see how this impacts on a slow system on my bigger server this is almost irrelevant. Results for pagetree: I activated all for an overview . But you where right the Request Info was consuming most of my time , as it was active by default.
  21. FieldsetPage is a good idea have to experiment with it. As fas as i understand you can use the default saveReady hook for doing stuff with it . Any ideas if you have multiple shipping adresses? Possibly a pagetable would do the job... Whish we could put customized listers in those page tabs.
  22. Double memmory has no effect (still only about 20Mb used ). Processor says 47% , so thats quite a lot. Copying to another a more poverfull server helps alot , moved a nother application whith same problem recently. This is a very small box so the problem comes up very early i guess. But as soon as the application starts growing drastically(200+ fields) its always the same slowdown. Although bigger server can handle 200-300 fields. This field/template loading would be a good thing for optimisation. I can not imagine why its necessary to load all Fields/Templates every time. More and more people are building applications using PW and you cannot always avoid to add fields or templates. Maybe its possible to cache those field loads somehow or just load the fields needed ? But ok, so if you plan on a big applications right now its necessary to save fields and templates wherever you can ? What we have ... Reuse fields as often as possible. Eg. instead using one description field per dataset, generate 1 descriptions field and reuse it as often as possible. But what do i do f if i have a webshop where each client has a invoice address and a delivery address. So the client needs a double set for adress data? Somwhere i read that you should combine multiple fields into one, is there an easy example for doing this somewhere ? Another idea would be making an address template and page fields to link the reused address fields groups to the client , but there is no clean solution for editing those addresses in the client page and this ad at least a template and 2 fields. What else can we do , and how to save templates ?
  23. Is there only a list of fields loaded or the actual field data. Loading of all fields is a great bottleneck for building bigger applications like maybe a CRM.
×
×
  • Create New...