Jump to content

Recommended Posts

Glad you got it sorted. Could I suggest that you direct the Autolinks question to Ryan? Maybe there's a way around the bottleneck...How many pages were you trying to load at once, btw?

Share this post


Link to post
Share on other sites

Btw, thanks, your question made me realise that the code around the strip_tags need to be optimised anyway...That bit of code should only load when post small is set to true.

  • Like 1

Share this post


Link to post
Share on other sites

About 10 pages. When you linked me to your demos, I immediately thought it must be Textile or Hanna but it wasn't. I was surprised to see Autolinks being the issue. Obviously, the other two will add some processing overhead but nothing like Autolinks in this particular circumstance.

Share this post


Link to post
Share on other sites

Hi,

I've just installed ProcessBlog on a test install of ProcessWire and all the admin side of things appears to work without issue, however when I try accessing any of the blog pages on the front-end all I get is a 404 not found error.

I've setup with blog style 2, and the blog pages and sub-pages all show OK in the admin page tree, and in the front-end sitemap, but viewing any of them just 404s.

Any ideas on how to what's happening and fix this?

The install was on a clean PW install (site-beginner)

Thanks in advance

Share this post


Link to post
Share on other sites

Hi again,

Only possible contributing factor is on completing installation I get a database error that says:

" SQLSTATE[42S02]: Base table or view not found: 1146 Table 'testbed_processw.field_blog_comments' doesn't exist"

Would this be the cause? How to rectify it, and why would it have occurred?

Cheers

Share this post


Link to post
Share on other sites

Hi @roblgs and welcome to PW and the forums.

Did you also install the MarkupBlog module?

MarkupBlog is not necessary if you want to create your own posts.php and post.php template files, but it makes it much quicker and easier to get going and you can use those files as a starting point and style from there.

Share this post


Link to post
Share on other sites

Hi Adrian,

Not explicitly, it wasn't clear that was necessary to do so separately from ProcessBlog which said it included MarkupBlog.

If I check modules for 'Site' then I can see

Blog Post Publish Date

Markup Blog

as installed, along with process blog

If I click on either one of those names in the list I get a page showing details, an uninstall link and a submit button. Clicking submit produces a message that the module has been saved...

Blog front-end remains unreachable

Share this post


Link to post
Share on other sites

Hi roblgs,

Welcome to the forums and PW.

Apologies for not getting back to you sooner. Sorry for the 'bad' start with the Blog module.

  1. The SQL error you see is something that started happening a couple of PW versions ago. It is safe to ignore it; just reload the dashboard and it will go away
  2. Blog automatically installs both MarkupBlog and ProcessBlog, although you may uninstall the former just fine
  3. 404s usually mean something wrong with your setup (server). URLs not being found where they are expected to be. I really doubt it has anything to do with Blog per se, but we are still going to help you :-)
  • Do other ProcessWire pages work fine? (Home, About, etc?)
  • Is this a sub-domain?
  • Is your install somewhere we can view it? (i.e. not a local install)
  • Long shot, but try installing using the 'blank profile' 

Let us know how it goes.

Share this post


Link to post
Share on other sites

Hi Kongondo,

Thanks for getting back to me.

I think I have it sorted, though I took the sledgehammer approach and clean installed both PW and PB.

Previously there were no blog templates installed in /site/templates, they were all in /site/modules/ProcessBlog/template-files... this time around they are all in /site/templates and at least I now get pages when I try loading /blog and so on... i.e. no longer getting a 404.

Couple of questions... the blog templates all include blog-main.inc.

My current setup uses prepend and append files, so I'm guessing that to get it working well I'll have to create a blog-main.php as an append file, based on a merger of current _main.php and the blog-main.inc... that is if all pages are to work off a consistent model...

Initially the blog pages stacked everything vertically, but I've copied 'css' and 'js' folders from the module folder to /site/templates and its producing a more expected layout... except that it mixes the layouts/contents of blog-main.inc with that of the _init.php and _main.php currently being pre/appended, but I think that will be straightforward to clean up.

Still don't know exactly what happened previously, unless an install issue with folder permissions causing some things to not be placed where they should be. That's my current best guess, although there were no on-screen error messages to indicate that... I suspect that the /site folder and its children were not writable to the extent needed.

Anyway, atlas I have something now, which is a giant step forward from yesterday, and a base on which to learn more.

Cheers

Rob

Share this post


Link to post
Share on other sites

Glad you got it sorted. The blog templates are all for demo purposes. So you can edit them as you please, or even not use them (only using their code as a reference if you are new to coding/PW...). The CSS and JS folders are intentionally not copied over...(as explained in the read me :-))..

Share this post


Link to post
Share on other sites

Hi,

Yes, I'm at the stage of feeling all at sea with a new platform, but at least with something now visible it's easier!

Will now play with templates...

Share this post


Link to post
Share on other sites

Hi,

Unable to add name to user, or to upload an image to a user.

These fields are added by the blog, as they are not present before installing the blog.

Any ideas?

The fields are displayed in the profile edit form, but after I fill the 'name' field with a text value and submit, the field is empty on reload, and no error message.

When trying to upload an image there is a red area below the image name on submit, but no error message.

Share this post


Link to post
Share on other sites

Update...

I can add a name and an image when creating a new user, but cannot do so when trying to modify the primary admin account, even when logged in as the primary admin...

Weird!

If I logout of primary admin, and login as a different admin, I can then add name and image to the primary... Seems there is an issue with doing so when trying to update yourself.

Share this post


Link to post
Share on other sites

Hi there,

I've just added this module (MarkupBlog) and I can't seem to see the Cleanup utility as described by the install instructions.

I'm logged in as the admin user and my php debug level is set to 300.

I have not uninstalled the module prior and I've just posted a blank post, in case the Cleanup option shows after inserting the first post.

Is there anything else I should be checking?

Share this post


Link to post
Share on other sites

Hi,

Where exactly are you looking for it? You should see it in ProcessBlog, i.e. click on 'Blog' in the Admin menu and you should see it in the page that is loaded.

Thanks for using Blog!

Share this post


Link to post
Share on other sites

This is the page I see when I click the Blog? 

Is this page the "Cleanup Utility" you are referring to?
Or is there a link I don't have access to and I'm blindly not seeing?

(I have worked far too many hours last few weeks)

http://imgur.com/bZThg9e

Share this post


Link to post
Share on other sites

:) ....Not sure how to answer this :-)....The answer is right there in front of you....you haven't finished installing the module. It is a two-step process. What you are seing there is step two (with very clear info :P ). Complete that (there is an install wizard button) and you'll see everything there is to see. Please read the accompanying README in its entirety to get the most of this module. A copy is here in github

Edited by kongondo

Share this post


Link to post
Share on other sites

Hi Kongondo, 

I did actually finish the installation before trying to look for the "Cleanup Utility".

I believe this is the correct state it should be in after installation (I chose option 1)?

http://imgur.com/vio6QmQ

I think the documentation was leading me astray as it was referring to  "Cleanup Utility", "Cleanup Feature" and "Blog menu item called CleanUp", but there was no clear titles or labels that that actually included the word Cleanup in the pages I saw.

I guess it wasn't clear to me that the first initialisation page also doubled up as the cleanup utility that was referred to multiple times.

I think where it got me confused was after reading "Blog Menu Item called Cleanup".

So I see a menu item on called Blog on the admin screen.

And I was expecting to see a menu item called Cleanup as a submenu item like other different Admin menu items normally have.

Except it wasn't there as expected.

I did read the README multiple times to Cleanup the confusion I was having (pun intended)  and even searched for the word Cleanup on both wizard pages.

Imagine my distraught state when I couldn't do either  :P

Thanks for the prompt reply and building the extension. Can't wait to use it!

Share this post


Link to post
Share on other sites

Glad you got it sorted. Thanks for the feedback. I will look into the wording of the instructions. The first initialisation page is not the cleanup utility if by that you mean the first step of the install. Nor is the second step of the install the cleanup utility.. The cleanup feature is accessed via a sub-menu within the Blog itself (the Process Module)...

Share this post


Link to post
Share on other sites

The first initialisation page is not the cleanup utility if by that you mean the first step of the install. Nor is the second step of the install the cleanup utility.. The cleanup feature is accessed via a sub-menu within the Blog itself (the Process Module)...

If that's the case, then there must be a bug with the installation as I don't see a Cleanup sub-menu on either the Blog itself or the Admin module

Share this post


Link to post
Share on other sites

You will only see it if you are logged in as a superuser, something similar to below. No bug related to this has been reported before. If you are logged in as a superuser and you can't see it, then something went wrong with your installation and its best that you start afresh.

post-894-0-19566500-1444512224_thumb.png

  • Like 1

Share this post


Link to post
Share on other sites

If Superuser == Admin user, then yes perhaps something went wrong during the installation.

I had a check at the logs (Modules) and couldn't see any indicator that the installation had gone wrong.

When I get a chance to do a fresh install, I will try again from scratch and let you know.

Are you aware of any clashes with other modules, besides the the Blog Module?

Share this post


Link to post
Share on other sites

I'm not aware of any clashes. What do you mean by the Blog Module? This is the Blog Module  :lol:. You probably mean the Blog Profile by Ryan? I know it appears in the modules directory so that can be confusing. 

Let us know how it goes.

Share this post


Link to post
Share on other sites

I'm not aware of any clashes. What do you mean by the Blog Module? This is the Blog Module  :lol:. You probably mean the Blog Profile by Ryan? I know it appears in the modules directory so that can be confusing. 

Let us know how it goes.

I've just tried to uninstall the modules, but because I don't have access to the Cleanup option I presume I can't uninstall the module.

Had a look at the docs, and it refers to the cleanup option ....  :huh: 

What's the best way to remove it manually?

Share this post


Link to post
Share on other sites

You can still uninstall it but it will leave behind all the pages, fields and templates it had installed before, which then won't allow you to re-install Blog. I don't know how comfortable you are with PHP and PW but you could copy the cleanup utility code to your template file and run it from there. I can show you how to do it but before that:

  1. Is this a dev install? i.e. not a production site.
  2. Is this on a local machine or on a remote server? I just can't figure out why you cannot see the cleanup Menu item.
  3. Did you alter the module code in any way?
  4. Can you confirm you are logged in as a superuser (the main admin person)?
  5. Can you show me a screenshot of what you see when you go to /yoursite /admin/blog/? admin here is whatever you called your PW admin, normally processwire.
  6. Have you tried updating the Blog modules (just overwritting the files) to see if cleanup menu item will appear?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By Gadgetto
      SnipWire - Snipcart integration for ProcessWire
      Snipcart is a powerful 3rd party, developer-first HTML/JavaScript shopping cart platform. SnipWire is the missing link between Snipcart and the content management framework ProcessWire.
      With SnipWire, you can quickly turn any ProcessWire site into a Snipcart online shop. The SnipWire plugin helps you to get your store up and running in no time. Detailed knowledge of the Snipcart system is not required.
      SnipWire is free and open source licensed under Mozilla Public License 2.0! A lot of work and effort has gone into development. It would be nice if you could donate an amount to support further development:

      Status update links (inside this thread) for SnipWire development
      2020-07-03 -- SnipWire 0.8.7 (beta) released! Fixes some small bugs and adds an indicator for TEST mode 2020-04-06 -- SnipWire 0.8.6 (beta) released! Adds support for Snipcart subscriptions and also fixes some problems 2020-03-21 -- SnipWire 0.8.5 (beta) released! Improves SnipWires webhooks interface and provides some other fixes and additions 2020-03-03 -- SnipWire 0.8.4 (beta) released! Improves compatibility for Windows based Systems. 2020-03-01 -- SnipWire 0.8.3 (beta) released! The installation and uninstallation process has been heavily revised. 2020-02-08 -- SnipWire 0.8.2 (beta) released! Added a feature to change the cart and catalogue currency by GET, POST or SESSION param 2020-02-03 -- SnipWire 0.8.1 (beta) released! All custom classes moved into their own namespaces. 2020-02-01 -- SnipWire is now available via ProcessWire's module directory! 2020-01-30 -- SnipWire 0.8.0 (beta) first public release! (module just submitted to the PW modules directory) 2020-01-28 -- added Custom Order Fields feature (first SnipWire release version is near!) 2020-01-21 -- Snipcart v3 - when will the new cart system be implemented? 2020-01-19 -- integrated taxes provider finished (+ very flexible shipping taxes handling) 2020-01-14 -- new date range picker, discount editor, order notifiactions, order statuses, and more ... 2019-11-15 -- orders filter, order details, download + resend invoices, refunds 2019-10-18 -- list filters, REST API improvements, new docs platform, and more ... 2019-08-08 -- dashboard interface, currency selector, managing Orders, Customers and Products, Added a WireTabs, refinded caching behavior 2019-06-15 -- taxes provider, shop templates update, multiCURL implementation, and more ... 2019-06-02 -- FieldtypeSnipWireTaxSelector 2019-05-25 -- SnipWire will be free and open source Plugin Key Features
      Fast and simple store setup Full integration of the Snipcart dashboard into the ProcessWire backend (no need to leave the ProcessWire admin area) Browse and manage orders, customers, discounts, abandoned carts, and more Multi currency support Custom order and cart fields Process refunds and send customer notifications from within the ProcessWire backend Process Abandoned Carts + sending messages to customers from within the ProcessWire backend Complete Snipcart webhooks integration (all events are hookable via ProcessWire hooks) Integrated taxes provider (which is more flexible then Snipcart own provider) Useful Links
      SnipWire in PW modules directory SnipWire Docs (please note that the documentation is a work in progress) SnipWire @GitHub (feature requests and suggestions for improvement are welcome - I also accept pull requests) Snipcart Website  

       
      ---- INITIAL POST FROM 2019-05-25 ----
       
    • By Sten
      Hello
      Till now I hacked something with the twig template but it works no more with new PW versions so I look forward to create a module. I am working on a site in multiple languages : French, English, Italian, German, Spanish, Portuguese, Hebrew, Russian. The new posts are entered in any language with a field for language. Till now, I got twig files to get the translations with constants defined for each part of the pages.
      So I'd like to create a module to include theses files added according to the url /fr/en/...
      Have you some observations to do before I begin about the direction to take ?
      Thank you
    • By ukyo
      Mystique Module for ProcessWire CMS/CMF
      Github repo : https://github.com/trk/Mystique
      Mystique module allow you to create dynamic fields and store dynamic fields data on database by using a config file.
      Requirements
      ProcessWire 3.0 or newer PHP 7.0 or newer FieldtypeMystique InputfieldMystique Installation
      Install the module from the modules directory:
      Via Composer:
      composer require trk/mystique Via git clone:
      cd your-processwire-project-folder/ cd site/modules/ git clone https://github.com/trk/Mystique.git Module in live reaction with your Mystique config file
      This mean if you remove a field from your config file, field will be removed from edit screen. As you see on youtube video.
      Using Mystique with your module or use different configs path, autoload need to be true for modules
      Default configs path is site/templates/configs/, and your config file name need to start with Mystique. and need to end with .php extension.
      Adding custom path not supporting anymore !
      // Add your custom path inside your module class`init` function, didn't tested outside public function init() { $path = __DIR__ . DIRECTORY_SEPARATOR . 'configs' . DIRECTORY_SEPARATOR; Mystique::add($path); } Mystique module will search site/modules/**/configs/Mystique.*.php and site/templates/Mystique.*.php paths for Mystique config files.
      All config files need to return a PHP ARRAY like examples.
      Usage almost same with ProcessWire Inputfield Api, only difference is set and showIf usage like on example.
      <?php namespace ProcessWire; /** * Resource : testing-mystique */ return [ 'title' => __('Testing Mystique'), 'fields' => [ 'text_field' => [ 'label' => __('You can use short named types'), 'description' => __('In file showIf working like example'), 'notes' => __('Also you can use $input->set() method'), 'type' => 'text', 'showIf' => [ 'another_text' => "=''" ], 'set' => [ 'showCount' => InputfieldText::showCountChars, 'maxlength' => 255 ], 'attr' => [ 'attr-foo' => 'bar', 'attr-bar' => 'foo' ] ], 'another_text' => [ 'label' => __('Another text field (default type is text)') ] ] ]; Example:
      site/templates/configs/Mystique.seo-fields.php <?php namespace ProcessWire; /** * Resource : seo-fields */ return [ 'title' => __('Seo fields'), 'fields' => [ 'window_title' => [ 'label' => __('Window title'), 'type' => Mystique::TEXT, // or InputfieldText 'useLanguages' => true, 'attr' => [ 'placeholder' => __('Enter a window title') ] ], 'navigation_title' => [ 'label' => __('Navigation title'), 'type' => Mystique::TEXT, // or InputfieldText 'useLanguages' => true, 'showIf' => [ 'window_title' => "!=''" ], 'attr' => [ 'placeholder' => __('Enter a navigation title') ] ], 'description' => [ 'label' => __('Description for search engines'), 'type' => Mystique::TEXTAREA, 'useLanguages' => true ], 'page_tpye' => [ 'label' => __('Type'), 'type' => Mystique::SELECT, 'options' => [ 'basic' => __('Basic page'), 'gallery' => __('Gallery'), 'blog' => __('Blog') ] ], 'show_on_nav' => [ 'label' => __('Display this page on navigation'), 'type' => Mystique::CHECKBOX ] ] ]; Searching data on Mystique field is limited. Because, Mystique saving data to database in json format. When you make search for Mystique field, operator not important. Operator will be changed with %= operator.
      Search example
      $navigationPages = pages()->find('my_mystique_field.show_on_nav=1'); $navigationPages = pages()->find('my_mystique_field.page_tpye=gallery');
    • By Robin S
      This is a module I made as an experiment a while ago and never got around to releasing publicly. At the time it was prompted by discussions around using Repeater fields for "page builder" purposes, where the depth feature could possibly be used for elements that would be nested inside other elements. I thought it would be useful to enforce some depth rules and translate the depth data into a multi-dimensional array structure.
      I'm not using this module anywhere myself but maybe it's useful to somebody.
      Repeater Depth Helper
      This module does two things relating to Repeater fields that have the "Item depth" option enabled:
      It enforces some depth rules for Repeater fields on save. Those rules are:
      The first item must have a depth of zero. Each item depth must not be more than one greater than previous item depth. It provides a RepeaterPageArray::getDepthStructure helper method that returns a nested depth structure for a Repeater field value.
      Helper method
      The module adds a RepeaterPageArray::getDepthStructure method that returns a multi-dimensional array where the key is the page ID and the value is an array of nested "child" items, or null if there are no nested children.
      Example

      The module doesn't make any assumptions about how you might want to use the depth structure array, but here is a way you might use it to output a nested unordered list.
      // Output a nested unordered list from a depth structure array function outputNestedList($depth_structure, $repeater_items) { $out = "<ul>"; foreach($depth_structure as $page_id => $nested_children) { $out .= "<li>" . $repeater_items->get("id=$page_id")->title; // Go recursive if there are nested children if(is_array($nested_children)) $out .= outputNestedList($nested_children, $repeater_items); $out .= "</li>"; } $out .= "</ul>"; return $out; } $repeater_items = $page->my_repeater; $depth_structure = $repeater_items->getDepthStructure(); echo outputNestedList($depth_structure, $repeater_items);
       
      https://github.com/Toutouwai/RepeaterDepthHelper
      https://modules.processwire.com/modules/repeater-depth-helper/
    • By MoritzLost
      Cacheable Placeholders
      This module allows you to have pieces of dynamic content inside cached output. This aims to solve the common problem of having a mostly cacheable site, but with pieces of dynamic output here and there.  Consider this simple example, where you want to output a custom greeting to the current user:
      <h1>Good morning, <?= ucfirst($user->name) ?></h1> This snippet means you can't use the template cache (at least for logged-in users), because each user has a different name. Even if 99% of your output is static, you can only cache the pieces that you know won't include this personal greeting. A more common example would be CSRF tokens for HTML forms - those need to be unique by definition, so you can't cache the form wholesale.
      This module solves this problem by introducing cacheable placeholders - small placeholder tokens that get replaced during every request. The replacement is done inside a Page::render hook so it runs during every request, even if the response is served from the template cache. So you can use something like this:
      <h1>Good morning, {{{greeting}}}</h1> Replacement tokens are defined with a callback function that produces the appropriate output and added to the module through a simple hook:
      // site/ready.php wire()->addHookAfter('CachePlaceholders::getTokens', function (HookEvent $e) { $tokens = $e->return; $tokens['greeting'] = [ 'callback' => function (array $tokenData) { return ucfirst(wire('user')->name); } ]; $e->return = $tokens; }); Tokens can also include parameters that are parsed and passed to the callback function. There are more fully annotated examples and step-by-step instructions in the README on Github!
      Features
      A simple and fast token parser that calls the appropriate callback and runs automatically. Tokens may include multiple named or positional parameters, as well as multi-value parameters. A manual mode that allows you to replace tokens in custom pieces of cached content (useful if you're using the $cache API). Some built-in tokens for common use-cases: CSRF-Tokens, replacing values from superglobals and producing random hexadecimal strings. The token format is completely customizable, all delimiters can be changed to avoid collisions with existing tag parsers or template languages. Links
      Github Repository & documentation Module directory If you are interested in learning more, the README is very extensive, with more usage examples, code samples and usage instructions!
×
×
  • Create New...