getgrav / grav-learn Goto Github PK
View Code? Open in Web Editor NEWGrav Learn (exhaustive grav documentation)
Home Page: http://learn.getgrav.org
License: MIT License
Grav Learn (exhaustive grav documentation)
Home Page: http://learn.getgrav.org
License: MIT License
For me as somebody who's never used Grav before was quite confusing what's Page Collections documentation talking about and how can I use it.
After digging in Antimatter's source code I found out that it defines what I get after calling page.collection()
which I'd expect to be mentioned in Page Collections or at least in Twig Filters & Functions.
This is more like a suggestion that an issue :).
The documentation is a little misleading with regards to summary()
.
This returns a truncated or shortened version of your content. You can provide an optional
size parameter to specify the number of words. Alternatively, if no size is provided, the
value can be obtained via the site-wide variable summary.size from your site.yaml configuration.
However, summary(size)
limits by the number of characters, not the number of words, which is evident in system/src/Grav/Common/Page/Page.php
.
Should the documentation be updated to clarify that it is the number of characters that're being limited, and not the words? Or is this an oversight and summaries were intended to be based on the number of words?
https://learn.getgrav.org/admin-panel/introduction#installation
Says: Grav 1.1.0-beta.4 or later
I'm on 1.0.10 stable ~ and the Admin plugin seems fine?
Your documentation looks pretty good. Based on this what do you think about a "grav-skeleton-documentation" or "grav-skeleton-book"?
As suggested by @fredrikekelund we should add a note in Learn that brings to attention the fact that on a large scale, too many Selectize can slow down the page load dramatically.
Issue Reference: getgrav/grav-plugin-admin#736
Hi, I was just going through Blueprints > Pages documentation and it took me awhile before I understood how form values were stored in pages .md files and how explicitly defining fields matters due to how Grav reads data in sequence. Ex. header.title.
I just thought to share my experience going through the documentation and possibly add this information.
colorpicker
form fieldfile
form fieldtext
fieldsA documentation on blueprints.yaml is needed. It is recommended that this file is created, but nowhere does it say what it is used for, and how to use this file.
I'm getting this error:
Theme 'learn2' does not exist, unable to display page.
Is there a reason it can't find the theme? I ran bin/grav install
as instructed.
There is an incomplete description in the Common Field Attributes table for the style
attribute:
to
By using a shared Group between your user and PHP/Web Server account with 775 permissions on directories and 664 permissions on files you ensure that even though you have two different accounts, both will have Read/Write access to the files.
I'm as dumb as a sack of hammers but I'll figure it out. Someone else may not.
Hi grav-team,
the doc is really awesome. Personally I think that more advanced form field types like array and list, maybe some others too, aber not really documented. Also google does not really help. It is really hard to get started. Maybe I've missed sth.
Thanks & BR toovy
Has anyone tried running grav on mongoose? should be easy and can add that to the list of grav supported servers
https://github.com/cesanta/mongoose
I'm using the windows binary php version and I can get the grav home page to display but no others, I suspect I'm just having a folder permissions issue to get past, I'll update this if I get further
grav-learn/pages/08.cookbook/01.general-recipes/docs.md
http://learn.getgrav.org/cookbook/general-recipes#problem-3
I am fairly new to GRAV and looking through all docs – hopefully carful :-)
I think the part about Modular Pages is missing the point where it says you have to iterate in your template through the sub-pages/children/blocks.
I was thinking it is done by GRAV itself, since I define the order in my MD-file.
grav-learn/pages/02.content/09.modular/docs.md
Haven't done it before, but maybe I can contribute to the docs?!
The sentence shown in the attached screenshot (of this page) is incomplete.
Is it possible to add list into notices,
i have weird result when i try
Not sure if this should be an issue but:
http://learn.getgrav.org/themes/twig-filters-functions
Is giving an error when you try to access it.
This link is no longer available Anthony Ringoet's Introduction to Twig
.
The docs say that you can log with any of the commands below:
$grav['log']->info('My informational message');
$grav['log']->notice('My notice message');
$grav['log']->debug('My debug message');
$grav['log']->warning('My warning message');
$grav['log']->error('My error message');
$grav['log']->critical('My critical message');
$grav['log']->emergency('Emergency, emergency, there is an emergency here!');
But only warning
, error
, critical
, and emergency
are actually logged:
[2015-06-26 20:58:51] grav.WARNING: My warning message [] []
[2015-06-26 20:58:51] grav.ERROR: My error message [] []
[2015-06-26 20:58:51] grav.CRITICAL: My critical message [] []
[2015-06-26 20:58:51] grav.EMERGENCY: Emergency, emergency, there is an emergency here! [] []
Hey Guys,
in the doc file grav-learn/pages/02.content/07.media/docs.md the image cropZoom function should be renamed to zoomCrop as documented in this repo (https://github.com/Gregwar/Image).
Cheers,
Christian
My /user/pages has dirs and files in it with spaces in the name, which makes the suggested permissions-fixing shell script fail:
Say I have a ./user/pages/this has spaces/default.md
:
chmod: cannot access ‘./user/pages/this’: No such file or directory
chmod: cannot access ‘has’: No such file or directory
chmod: cannot access ‘spaces/default.md’: No such file or directory
However, after some googling, I found this script to work for me:
chown foo:bar .
chown -R foo:bar *
find . -type f -exec chmod 664 {} \;
find ./bin -type f -exec chmod 775 {} \;
find . -type d -exec chmod 775 {} \;
find . -type f -exec chmod +s {} \;
umask 0002
I don't know enough about the subject matter to be sure this does the same thing as the suggested script, by I just thought it ought to be looked at.
After a long three days of trying to get Grav running on Bluehost, I'm throwing in the towel. BH doesn't have the in depth resources available to the commoner to diagnose the problem with Server 500 errors. I'll investigate further and report back to see if there is some way to make it work. In the mean time I'll have to find another hosting company.
Could you please make it possible to build an epub file with the learn.getgrav.org website?
Would be a very nice option of the documentation!
Thanks
C
The rendering for the tabs in the media section is broken.
http://learn.getgrav.org/content/media
Example:
While installing grav-learn through ssh I am getting several "Commands not Found" during the Cloning Bits phase of the installation, suggestion?
Hi, no work example in documentation theme-configuration:
Theme License: {{ grav.theme.license }}
This snippet was not working until markdown extra
was set to true
{% for child in collection %}
{{ child.media['cover.jpg'].display('thumbnail').html() }}
{% endfor %}
Maybe a little info box saying that Markdown extra
has to be set to true
to make it works would be appreciated
I don't know how to fix the more info
link in Markup for:
data-srcset | In case of image media, this contains the srcset string. (more info)
http://learn.getgrav.org/content/media/#responsive-images
should be:
http://learn.getgrav.org/content/media#responsive-images
Here is example: https://github.com/getgrav/grav-learn/blob/develop/pages/08.advanced/11.yaml/docs.md#mappings
animal: pets
- Cat
- Dog
- Goldfish
but it doesn't work in pyyaml and http://www.yamllint.com/ with error:
yaml.parser.ParserError: while parsing a block mapping
in "test.yml", line 1, column 1
expected <block end>, but found '-'
in "test.yml", line 2, column 1
I could fix it, but I'm not sure I'm clear with goal of example..
I have a page variable that shows up like this when I dump it :
{{ dump(page) }}
Grav\Common\Page\Page {#189
#name: "news-item.md"
#folder: "slicing-meat-perfectly"
#path: "/home/pz/Code/pp/user/pages/02.news"
#extension: ".md"
#url_extension: ""
#id: "14796693254b05940b2b54fa4d02652305bc165011"
#parent: "/home/pz/Code/pp/user/pages/02.news"
#template: "news-item"
#expires: null
#visible: false
#published: true
#publish_date: null
#unpublish_date: null
#slug: "slicing-meat-perfectly"
#route: "/news/slicing-meat-perfectly"
#raw_route: "/news/slicing-meat-perfectly"
#url: null
#routes: null
#routable: true
#modified: 1479669325
#redirect: null
#external_url: null
#items: null
#header: {#187
+"title": "Slicing Meat Perfectly"
+"date": "09:34 07/01/2015"
+"description": "Not sure where to start! It can go left, it can go right, it can go up, it can go down! The head spins and spins, it never stops!"
+"imageMainBackground": "individual-backgrounds/outside.jpg"
+"taxonomy": array:3 [
"category" => "Food"
"tag" => array:2 [
0 => "reflection"
1 => "thoughts"
]
"author" => "ksmith"
]
}
...
When I call {{ dump(page.nextSibling()) }}
I get a collection :
Grav\Common\Page\Collection {#622
#pages: Grav\Common\Page\Pages {#100
#grav: Grav\Common\Grav {#3
#processors: array:13 [
0 => "siteSetupProcessor"
1 => "configurationProcessor"
2 => "errorsProcessor"
3 => "debuggerInitProcessor"
4 => "initializeProcessor"
5 => "pluginsProcessor"
6 => "themesProcessor"
7 => "tasksProcessor"
8 => "assetsProcessor"
9 => "twigProcessor"
10 => "pagesProcessor"
11 => "debuggerAssetsProcessor"
12 => "renderProcessor"
]
-values: array:48 [
"loader" => Composer\Autoload\ClassLoader {#1
-prefixLengthsPsr4: array:7 [
"W" => array:1 [ …1]
"S" => array:7 [ …7]
"R" => array:8 [ …8]
"M" => array:3 [ …3]
"L" => array:1 [ …1]
"G" => array:1 [ …1]
"D" => array:2 [ …2]
]
I'm expecting the next page object, not this collection. The collection that I have passed down to my twig templates looks like this:
content:
items:
'@taxonomy.category': 'Food'
order:
by: date
dir: desc
limit: 30
pagination: true
I actually have another section with a collection using taxonomy "News" that has the next and previous sibling functions correctly returning the next or previous page object, I am stumped.
The contact form behind the link " Live page " ( http://demo.getgrav.org/soraarticle-skeleton/contact ) is broken.
Source: https://github.com/getgrav/grav-learn/blob/develop/pages/06.advanced/14.contact-form/docs.md
Hey guys,
I think there is a typo in the documentation where access of the pages headers map is written about.
It says "page.headers.author" for instance. In my opinion it should read "page.header.author" instead.
It took me a while to find out why a custom header variable was not printed in a twig template.
But maybe I am wrong, who knows ;-)
Cheers
Thorsten
Is this standard bitbucket behavior?
Cloning into 'user/plugins/gravui'...
Username for 'https://bitbucket.org': attiks
Password for 'https://[email protected]':
remote: Unauthorized
fatal: Authentication failed for 'https://bitbucket.org/rockettheme/grav-plugin-gravui/'
SUCCESS cloned https://bitbucket.org/rockettheme/grav-plugin-gravui -> /home/peter/projecten/grav-learn//user/plugins/gravui
Cause by https://github.com/getgrav/grav-learn/blob/develop/.dependencies#L22
I've just installed a local copy of grav-learn to read the documentation offline, the main page(first page) appears just as expected but where trying to move to another page i get the 404 page.
Is there any configuration to put inside .htaccess
file or something like that ?
Thank you in advance.
The example script shows setting all files to 644, this will remove the executable bit from bin/grav and bin/gpm.
If the script is intended to be run from the top of the grav install
find . -type f ! -path "./bin/" | xargs chmod 644
find . -type f -path "./bin/" | xargs chmod 755
Please no more light grey font on white background - it hurts the eyes. Please add strong contrast to make the learn site better readable, thank you! Also please see http://www.contrastrebellion.com
For this image ![Theme Folders](theme-folders.png)
, the path is not correct thus the image cannot be displayed, but I don't know what it should be.
Maybe this is not only a documentation issue: the Multi-Language page (under Content) indicates that it is possible to select the language by a browser's Accept Language header but it does not describe in detail how this type of content negotiation is processed.
The practical issue with that approach is that most browsers set the value of Accept Language by the localization settings of the underlying operating system. If one installes Chrome in London then "en-gb" is set, if one installes in Boston then "en-us" is set, if one installes in Sidney then "en-au" is set.
On the other hand most makers of a web site will provide only a single page "in English" and not making a destinction between British and US English.
By my testing Grav does not fall-back to pages created in English (en) if the browser sends "en-gb".
Therefore this very strict behaviour should be explained in the documentation or the software should be changed to support such a fall-back.
On the menu left. when you on a page, all sub menus are open. But it should open only the selected chapter.
See:
http://www.jellekoksolutions.nl/docs2/manual/backend/tools/prune-categories
I used to scroll the documentation pages up/down by pressing the up/down arrow. It would be nice if I could go to next/previous page by pressing the left/right arrow too.
Is missing logout and logged in user showing area
https://learn.getgrav.org/content/media#where-to-put-your-media-files
Up until now the docs have only been discussing Markdown exmamples... this line:
page.find('/images').media['my-image.jpg']
is it MD? Twig?
Here: https://learn.getgrav.org/content/media#general
It states that ![Some ALT text](sample-image.jpg "My title") {.myclass}
would be how you add a class and then there's a notice that states:
To use classes in Markdown, you need to enable Markdown Extra.
However, back here:
https://learn.getgrav.org/content/image-linking#image-attributes
it states that classes are natively supported in MD
First of all, thanks for a great project with some very nice docs!
What I've found when referring to the documentation however, is that I often miss things in the text because of its pretty large font-size, even on smaller screens. To increase readability, I'd like to propose that the body text's font-size
is decreased from 18px
to 14px
, and that a max-width
of about 900px
is set on the content container.
Ideally, I'd also like for the headings to be a bit smaller as well, and for the <h1>
to be less dramatic. I realize that the <h1>
uses the identity style of Grav, but for the docs, I think that the argument to first and foremost make them easily digestible carries a lot of weight.
When trying out these changes in my browser, I must say that that they really made the docs a lot more readable to me. I've attached a screenshot showing what it looks like.
If you like, I could submit a PR for these changes!
When you click on the next page, it goes to the next page. But if you have sub-sub menu. It only go to the sub menu.
example:
http://www.jellekoksolutions.nl/docs2/manual/backend/tools/prune-categories
click next page
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.