Jump to content

Juergen

Members
  • Content Count

    947
  • Joined

  • Last visited

  • Days Won

    1

Juergen last won the day on November 5 2017

Juergen had the most liked content!

Community Reputation

444 Excellent

About Juergen

  • Rank
    Hero Member

Profile Information

  • Gender
    Male
  • Location
    Linz
  • Interests
    Playing electric guitar (Rock, Heavy), flying model helicopters

Recent Profile Visitors

5,028 profile views
  1. Juergen

    SeoMaestro

    I wanted to create a HTML Sitemap with the same pages as the XML sitemap. Unfortunately the $pages->find() method doesn´t support the order of the page tree, so I could not use the provided function to get all pages from the XML-Sitemap in the same order as the page tree. $pages->find('seo.sitemap_include=1'); So I wrote a little recursive function to render all the pages except the ones which were not included in the XML sitemap. The pages have the same order as in the page tree. function renderSitemap($items, $depth = 0) { $separator = ''; for ($x = 0; $x <= $depth; $x++) { $separator .= '-'; } foreach ($items as $item) { if ($item->seo->sitemap->include == 1) { $subitems = $item->children(); if (count($subitems)>0) { echo '<b>'.$separator.$item->title . '</b><br />'; } else { echo $separator.$item->title . '<br />'; } $subitems = $item->children(); renderSitemap($subitems, $depth+1); } } } //OUTPUT INSIDE TEMPLATE FILE $items = $pages->get("/")->children(); echo '-'.$pages->get("/")->title.'<br />';//this is only for the homepage renderSitemap($items); This little function is not intended as a complete HTML sitemap markup generation solution. It only outputs the title of the pages (without links). It should only be a starting point for others to show you how to use SEOMaestro settings in combination with a frontend sitemap. Maybe if someone has a better solution it would be great if you post it here. Best regards This is what it looks like:
  2. Juergen

    SeoMaestro

    Hello @Peter Knight I think that there is no render tag method for the robot tags, but you can use the following: $page->seo->robots->data['noIndex'] $page->seo->robots->data['noFollow'] This returns true if 'no index' was choosen and true if 'no follow' was choosen. Create the meta tags by yourself and use PHP to fill in these values into the meta tags. Best regards Jürgen
  3. Juergen

    SeoMaestro

    I have not installed this module and I have the same problem. On my current installation I have only installed a few modules. So I guess it has nothing to do with other modules.
  4. Juergen

    SeoMaestro

    Thank you @Wanze for this great module. Only one thing to mention: From the point of security it is not recommended to add the generator metatag (or any other information to help hackers to know something about the system). So it would be great to add a setting checkbox to disable the rendering of this metatag. I know I can render each metatag separately but using your render method ($page->seo->render()) would be much more comfortable . Best regards Jürgen
  5. If I understand you correctly, you have added a new image field to your template for the featured image and you need the url for the src attribute. Lets assume the name of the new image field is 'featured_image' you will get the url of this image by using $page->featured_image->url So the code of the blog-post.php could look like this: <?php $img = $page->featured_image; if($img) { $img = $img->width(600); echo "<p class='uk-text-center'><img src='$img->url' alt='$img->description'></p>"; } ?> Image is an object, so you have to grab the different values (attributes) of the image by using the arrows (->) followed by the name of the attribute (size, url,...). You will find more information about getting image values here If this was not the information you are asking for please post your code for better understanding. Best regards
  6. Hello, I always get this warning with Tracy: PHP Warning: A non-numeric value encountered in .../site/modules/AllInOneMinify/AllInOneMinify.module:713 This is the line of code: $_timestamp = ($_timestamp + $file['last_modified']); It seems that one of the two values is not in the right format. Best regards
  7. Thanks @adrian for the quick fix!! It works as expected!
  8. Hello @adrian is it possible to disable the input field length fe style="width:60px;" by entering something into the settings field? If not, it would be great if you add the possibility to enter fe a "-" to disable the rendering of the style attribute. This could be useful if you are using the UIKit template because there are various input length classes ('uk-form-width-medium'....) and you dont need the input field length. Best regards Jürgen
  9. Hello @ all, only a simple question: Is it possible (and if how) to distinguish if a page was saved via fe a save ready hook or manually by pressing the save button? I have the problem that a special hook function should only run if the save button was pressed by a human. In my case the schedule pages module triggers a hook to set a child page status to unpublished and saves the child page and this save process leads to start another hook which changes some values in the parent page. I only want to run this hook for the parent page if the child page was saved by pressing the save button and not by saving via a hook. if(Save button was pressed) { // run the hook } else { // do not run the hook } Maybe someone has struggled with the same problem and can give me a hint how to deal with this? Best regards
  10. @dragan On my screen the label "Description" is also not visible. It is also not visible in the sourcecode. I am using PW dev version 101 (latest). Same for the tags label if I enable them. Admin Theme UIKit. Best regards
  11. It would be great if an optional text field will be added to the inputfield integer to add additional text next to the integer field (fe. weeks, days,..). Multilanguage support would be nice .
  12. Hello @Robin S Thanks for this information. I have set the width of the last 2 cols to 17% and now it works. It doesn`t seem very logical to me, because I have thought that the width of the non visible col will be automatically set to 0%, but dividing it by two solves the problem. Thousand thanks, you have made my day!! Would be great if this info will be added to the docs.
×
×
  • Create New...