Search found 9 matches

by matto
Thu Apr 06, 2017 1:35 pm
Forum: General
Topic: theme specific plugin
Replies: 0
Views: 5470

theme specific plugin

Hi! I wrote a theme-specific plugin, my goal is an object with custom methods to call in my theme. This is how its called: echo $treadmill->get(); The plugins code is on github: https://github.com/muellmatto/bludit-plugin-treadmill Is there a better / safer way to do this? I figured out that i can a...
by matto
Sat Apr 01, 2017 8:11 pm
Forum: General
Topic: custom page / view / "whereAmI"
Replies: 3
Views: 2816

Re: custom page / view / "whereAmI"

This is exact the code i am using. It works fine, news.php is included, all code get executed. The only thing is, bludit reports that it cannot build a news page, because there is none. At the moment i am ignoring the error message, but i like to have a cleaner solution. I want so bypass building a ...
by matto
Sat Apr 01, 2017 4:51 pm
Forum: General
Topic: custom page / view / "whereAmI"
Replies: 3
Views: 2816

custom page / view / "whereAmI"

Hi! I would like to create a custum page. in my index.php i am using if ($Url->slug() == "news"){ include(THEME_DIR_PHP.'news.php'); }elseif ($Url->whereAmI() == 'page') { include(THEME_DIR_PHP.'page.php'); } elseif ($Url->whereAmI() == 'post') { include(THEME_DIR_PHP.'post.php'); } elseif...
by matto
Thu Mar 30, 2017 7:17 pm
Forum: General
Topic: [solved] image resizing (filesize reduction)
Replies: 1
Views: 2140

[solved] image resizing (filesize reduction)

To serve smaller images, filter them through a php script from https://cimage.se/ I added RewriteRule ^bl-content/uploads/(.*)$ imgd.php?src=$1 [NC,L] to my htaccess. how do i use it? if this is your markup: ![MYIMAGE](imageFile.jpg) change it to soething like: ![MYIMAGE](imageFile.jpg&w=600) to...
by matto
Wed Jul 27, 2016 3:07 pm
Forum: General
Topic: Subsubpages
Replies: 6
Views: 3871

Re: Subsubpages

Hi!

simply adding a subfolder with an index.txt does not work, i guess i have to manually edit the database?

I don't know where to start getting this to work.
by matto
Fri Jul 22, 2016 1:49 pm
Forum: General
Topic: Subsubpages
Replies: 6
Views: 3871

Subsubpages

Hi! Is it possible to have subsubpages? I haven't looked through the code, is it possible by design to set a page as child of another parents child? BTW, if someone is interested, i am working on a theme with mdl https://github.com/muellmatto/bludit-mdl-seht and created a really simple (not good ;) ...
by matto
Wed Mar 02, 2016 2:11 pm
Forum: General
Topic: [solved] list posts // all | by tags
Replies: 22
Views: 15596

Re: list posts

Hi!

Yes this is exactly what i use it for,
I simply use this in php/home.php

Code: Select all

    $totalPublishedPosts = $dbPosts->numberPost(true);
    $posts = buildPostsForPage(0, $totalPublishedPosts, true, false);
    foreach ($posts as $Post):
    
Greetings
by matto
Sat Feb 20, 2016 3:20 pm
Forum: General
Topic: [solved] list posts // all | by tags
Replies: 22
Views: 15596

Re: list posts

Thanks, it helped me a lot!

I had to call

Code: Select all

numberPost();
with parameter true, otherwise it would have returned zero.
by matto
Fri Feb 19, 2016 6:57 pm
Forum: General
Topic: [solved] list posts // all | by tags
Replies: 22
Views: 15596

[solved] list posts // all | by tags

Hey! This is how i get a list of all post or all posts of one tag: if ($Url->whereAmI() == 'blog') { // list all posts $totalPublishedPosts = $dbPosts->numberPost(true); $posts = buildPostsForPage(0, $totalPublishedPosts, true, false); } elseif ($Url->whereAmI() == 'tag') { $tagKey = $Url->slug(); $...