Jump to content
Nico Knoll

MarkupSEO - The all-in-one SEO solution for ProcessWire.

Recommended Posts

HI Nico, thanks for the response. I was running 0.60, I upgraded to 0.8.2 and it seems to have fixed the issue.

Also in the google preview mode: if your URL is somewhat long will overlap on top of the Meta description. (it's a CSS issue, could always do a nowrap on the URL, or tuncate it, i'm not sure what google does.) just making you aware of the issue.

Great plugin, really liking the the ability to set character limits. Great work!

post-1913-0-09064000-1425315785_thumb.jp

Share this post


Link to post
Share on other sites

Hey Nico

The solution to the preview URL wrapping over the text below for your module is this code below:

span.SEO_google_link {
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  background-color: #fff;
}
span.SEO_google_link:after {
  content: "";
  pointer-events: none;
  position: absolute;
  width: 50px;
  height: 100%;
  top: 0;
  right: 0;
  background-image: -webkit-linear-gradient(right, #ffffff, rgba(255, 255, 255, 0));
  background-image: -moz-linear-gradient(right, #ffffff, rgba(255, 255, 255, 0));
  background-image: -ms-linear-gradient(right, #ffffff, rgba(255, 255, 255, 0));
  background-image: -o-linear-gradient(right, #ffffff, rgba(255, 255, 255, 0));
  background-image: linear-gradient(to left, #ffffff, rgba(255, 255, 255, 0));
}

All credit to this guy who I've been working with for a while: https://processwire.com/talk/user/2562-jw/

  • Like 1

Share this post


Link to post
Share on other sites

Hi,

at first, thanks a lot for this useful module!

I'm trying to figure out, how I can set the title for the homepage by hand, while using {title} - {sitename} automatically for all other pages. {title} - {sitename} automatically for all other pages is working fine, but the homepage shows always "Home | " before the sitename. Even though I have entered (under the homepage SEO tab) the title that I want, manually.  I prefer the sitename only for the homepage. I am sure that this can be easily solved somehow, but I don't get it :-/

Thanks for help!

Share this post


Link to post
Share on other sites

I would recommend you to turn off the SEO auto title function and do it yourself using the SEO parameters. Like this:

<title><?php echo ($page->id == '1') ? $page->seo->title : $page->seo->title.' - '.$config->seo->sitename; ?></title>

Share this post


Link to post
Share on other sites

Hi Nico,

thanks a lot for the lightspeed fast reply! What you recommend is working pretty fine! Thank you! :-)

  • Like 1

Share this post


Link to post
Share on other sites

Hi Nico,

First, thanks for this great module, nice job.

Just one thing about Open Graph metas : shouldn't it use <meta property> instead of <meta name> ?

Share this post


Link to post
Share on other sites

Hey people, 

i try to chose the SmartKeywords with an tags (page | multiplearray) field.

http://prntscr.com/7d7yi5

what i have to change that i get as Keywords the title of the choosen pages ? 

currently i have the id's in the code 

<meta name="keywords" content="1088|1091|1082|1083|1084|1085|1086">

where i have to make changes in the Module  ?

	// case 'keywords': 
					 	if($configData['keywords']) {
					 		$pageData['keywords'] = $configData['keywords'];
					 	} elseif($configData['keywordsSmart'] && $page->get(implode('|', $configData['keywordsSmart'])) != '') {
					 		$pageData['keywords'] = strip_tags($page->get(implode('|', $configData['keywordsSmart'])));
					 	}
					 break; 

or here 

// Default Keywords
		$field = $modules->get("InputfieldText");
		$field->name = "keywords";
		$field->label = __("Keywords");
		$field->description = "";
		$field->value = $data['keywords'];
		$field->columnWidth = '50%';
		$field->showIf = 'useParents=0';
		$fieldset->add($field);

		$field = $modules->get("InputfieldAsmSelect");
		$field->name = "keywordsSmart";
		$field->label = __("Smart Keywords");
		$field->description = __("We will use those fields (in this particular order) if you don't fill in the keywords field");
		foreach($fields as $selectField) $field->addOption($selectField->name);
		$field->value = $data['keywordsSmart'];
		$field->columnWidth = '50%';
		$field->showIf = 'useParents=0';
		$fieldset->add($field); 

Nobody an solution for me ?? 

Edited by iNoize

Share this post


Link to post
Share on other sites

Havent installed it yet, but is this module ready for multilingual sites?

Best regards

Share this post


Link to post
Share on other sites

@Juergen: Yes, most of it. If you install the module there is a short explanation on the bottom of the config page.

Share this post


Link to post
Share on other sites

I have the Title Format option set to

{title}, {sitename}

How would I make the module use a filed called 

Long_Title instead of title but only is Long_Title is set

I tried the following using a pipe

{Long_Title | title}, {sitename}

Share this post


Link to post
Share on other sites

Can someone assist with some SEO Module questions I have?

By default, the SEO tags are outputting by default just before the </head>.

I'd like them to render instead right after the opening <head>

If I want to choose exactly where they render, someone posted that this work

 <?php echo wire('page')->seo->render; ?>

On my site, this works but renders the SEO fields twice. In the default location (before the closing HEAD) and in the preferred position after the opening HEAD.

My second question is if the following (and only) How to use is still correct?

$page->seo // includes all the default values mixed with the page related seo data

// e.g.:
$page->seo->title
$page
->seo->keywords

// for rendering:
$page->seo->render

I might be doing this wrong but including any of the following renders nothing

<?php
echo $page->seo;
?>

or 

<?php
echo $page->seo->title;
?>

or
<?php
$page->seo->render;
?>

Thanks - appreciate it.

Share this post


Link to post
Share on other sites

Well 

<?php echo wire('page')->seo->render; ?>

or 

<?php

echo $page->seo->render;
?>

are the way to go. 

In your settings you can either enable automatically insertion of the meta fields (so you dont need to do this) or you can enable "manual" and then you will need this code (or you're rendering the tags in some other way)

Share this post


Link to post
Share on other sites

In your settings you can either enable automatically insertion of the meta fields (so you dont need to do this) or you can enable "manual" and then you will need this code (or you're rendering the tags in some other way)

Ah, thanks Nico. That was it :)

Share this post


Link to post
Share on other sites

Hallo,

till today I used version 0.3.0.

Now I have deleted this and replaced it with 0.6.0. Since this I miss the SEO-tab.

What makes the SEO-tab apear again?

Hi,

I have the same problem now after updating to Version 0.8.2.

After I have specified the templates no SEO-Tab apear again.

What can I do get my seo inputs again?

Share this post


Link to post
Share on other sites

@guenther55: Go to the settings page and select the templates that should get seo fields

Share this post


Link to post
Share on other sites

@guenther55: Go to the settings page and select the templates that should get seo fields

I did this and now I select an other page once more, but no Seo tab!

I got the same error as @Tyssen and I am not able to deinstall the modul!

My solution for now: in site/modul directory I reactivated the 0.3.0 Version - seo tab and all inputs are back! The old version works for me and I dont see really need to update.

But I hope you can find the bug and maybe I can update with a next Version in future.

Share this post


Link to post
Share on other sites

Did just PR the german translation of this great module...;)

https://github.com/Manfred62/pw-modules-lang-de/pull/1

proud to contribute with some translation.

One Feature request comes in my mind - that would be a nice to have - and for my installations i probably would challange this with some little hooks on page saving...and some hacking - but within the moduel it would be much better.

feature of the "smart" title|description would be:

->if some smart fields are set

-> that on first page publish

-> if no SEO fields are filled out by the user

->the smart title|desc should filled in the seo_ fields

 This has the benefit that the Google Preview would work and simple editors see what really would generated at frontend -> and they can improve this output with own entries in the seo_fields....

i think this would be a hook after page save and Page::statusUnpublished.....but i'm not so expirenced to edit such a complex module...i'm just able to hack a little bit with my (german: gefährlichem Halbwissen) ;)

regards mr-fan

  • Like 1

Share this post


Link to post
Share on other sites

some little example code how i hacked the "prefilling" option into the seo_fields from own content fields....if i've the time i transform it to a simple module with some settings for the fallback fields...what this code does:

it take a look only if a user publish a page and if seo_title , desc, keywords are filled....and if not it uses several text fields that the templates provide as an fallback that the seo_ entries not empty - so you think why - The smart settings in the module do that on frontend, too!

Yes but a editor that takes a look at the SEO Tab see it empty with some strange example text....and i wanna let see him what will be the output in frontend. I don't like empty fields while in frontend some magic works that nobody see at a first glance.

This is what i meant with - fill the "smart" things in the page fields if the user doesn't set them...or i'am thinking to complicated here?

regards mr-fan

code runs in admin.php - some functions for better striptags and some other functions to get the right output....

/**
 * Hook for changing seo_* fields if empty on Page Publish
 */

$pages->addHookAfter('saveReady', null, 'changeSeoFields');
function changeSeoFields(HookEvent $event) {
	$page = $event->arguments[0];
	//for this template only
	if($page->template == 'artikel'|| $page->template == 'seite') {
		// page is about to be published
		if($page->isChanged('status') && !$page->is(Page::statusUnpublished)) {
			// check if seo_title fields are exist and if they are empty
			if (!$page->seo_title) {
				//get the default value that would used as fallback
				if ($page->headline) {
					//Headline field is used for seo_title
					$default_title = ripTags($page->headline);
				} else {
					//Headline field empty - page title is used
					$default_title = ripTags($page->title);
				}
				//set seo_title on publishing
				$page->set ('seo_title', $default_title);
			}
			// check if seo_description fields are exist and if they are empty
			if (!$page->seo_description) {
				//get the default value that would used as fallback
				if ($page->kurztext) {
					$default_desc = ripTags($page->kurztext);
				} else {
					//is there a main content block as pagetable field pt_inhalt?
					if(count($page->pt_inhalt)>0) {
						//get the first text field in the pagetable and use it for the seo description
						$first_item = $page->pt_inhalt->get("template=part_text|part_text_image_left|part_text_image_right");
						$first_content = ripTags($first_item->text);
						$default_desc = wordLimiter($first_content, 160);
					}
				}
				//set seo_description on publishing
				$page->set ('seo_description', $default_desc);
			}
			// check if seo_keywords fields are exist and if they are empty
			if (!$page->seo_keywords) {
				//get the string that should be used to generate automatical keywords for this page
				//we use all textfields in the pagetable from the main content and collect them
				$keyword_texts = '';
				//is there a main content block as pagetable field pt_inhalt?
				if(count($page->pt_inhalt)>0) {
					foreach ($page->pt_inhalt as $keyword_text) {
						if ($keyword_text->title) $keyword_texts .= $keyword_text->title;
						if ($keyword_text->text) $keyword_texts .= $keyword_text->text;
						if ($keyword_text->text2) $keyword_texts .= $keyword_text->text2;
						if ($keyword_text->text3) $keyword_texts .= $keyword_text->text3;
					}
				} else {
					$keyword_texts = $page->headline.' '.$page->kurztext.' '.$page->title;
				}
				//rip tags
				$keyword_string = ripTags($keyword_texts);

				$default_keywords = extractKeywords($keyword_string);

				//set seo_title on publishing
				$page->set ('seo_keywords', $default_keywords);
			}
		}
	}
}

Share this post


Link to post
Share on other sites

Where I could find the echos in the module? For example if I want to change a meta tag name, maybe for example from <meta name="description" to <meta name="DC.description" ?

When I change

$field->name = "description";

in line 574 nothing happens.

I would not really change anything - regardless of it, would it be possible?

The module has no custom template, right?

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By Mike Rockett
      Jumplinks for ProcessWire
      Release: 1.5.56
      Composer: rockett/jumplinks
      Jumplinks is an enhanced version of the original ProcessRedirects by Antti Peisa.
      The Process module manages your permanent and temporary redirects (we'll call these "jumplinks" from now on, unless in reference to redirects from another module), useful for when you're migrating over to ProcessWire from another system/platform. Each jumplink supports wildcards, shortening the time needed to create them.
      Unlike similar modules for other platforms, wildcards in Jumplinks are much easier to work with, as Regular Expressions are not fully exposed. Instead, parameters wrapped in curly braces are used - these are described in the documentation.
      Under Development: 2.0, to be powered by FastRoute
      As of version 1.5.0, Jumplinks requires at least ProcessWire 2.6.1 to run.
      View on GitLab
      Download via the Modules Directory
      Read the docs
      Features
      The most prominent features include:
      Basic jumplinks (from one fixed route to another) Parameter-based wildcards with "Smart" equivalents Mapping Collections (for converting ID-based routes to their named-equivalents without the need to create multiple jumplinks) Destination Selectors (for finding and redirecting to pages containing legacy location information) Timed Activation (activate and/or deactivate jumplinks at specific times) 404-Monitor (for creating jumplinks based on 404 hits) Additionally, the following features may come in handy:
      Stale jumplink management Legacy domain support for slow migrations An importer (from CSV or ProcessRedirects) Feedback & Feature Requests
      I’d love to know what you think of this module. Please provide some feedback on the module as a whole, or even regarding smaller things that make it whole. Also, please feel free to submit feature requests and their use-cases.
      Note: Features requested so far have been added to the to-do list, and will be added to 2.0, and not the current dev/master branches.
      Open Source

      Jumplinks is an open-source project, and is free to use. In fact, Jumplinks will always be open-source, and will always remain free to use. Forever. If you would like to support the development of Jumplinks, please consider making a small donation via PayPal.
      Enjoy! :)
    • By BitPoet
      As threatened in Ryan's announcement for 3.0.139, I built a little module for sliding toggles as a replacement for checkboxes. Styling of the input is CSS3 only (with all the usual caveats about older browsers), no JS necessary, and may still be a bit "rough around the edges", so to speak, since I didn't have much time for testing on different devices or brushing things up enough so I'd feel comfortable pushing it to the module directory. But here's the link to the GitHub repo for now:
      InputfieldSlideToggle
      Fieldtype and Inputfield that implements smartphone-style toggles as replacement for checkbox inputs. The visualization is CSS-only, no additional JS necessary.
      Status
      Still very alpha, use with caution!
      Features / Field Settings
      Size
      You can render the toggles in four different sizes: small, medium, large and extra large.
      Off Color
      Currently, "unchecked" toggles can be displayed either in grey (default) or red.
      On Color
      "Checked" toggles can be rendered in one of these colors: blue (default), black, green, grey, orange or red.
      Screenshots

      Some examples with checkbox label


      View all Size and Color Combinations
      Small toggles Medium toggles Big toggles Extra big toggles  









    • By Orkun
      Hi Guys
      I needed to add extended functionalities for the InputfieldDatetime Module (module is from processwire version 2.7.3) because of a Request of Customer.
      So I duplicated the module and placed it under /site/modules/.
      I have added 3 new Settings to the InputfieldDatetime Module.
      1. Day Restriction - Restrict different days based on weekdays selection (e.g. saturday, sunday) - WORKING

       
      2. Time Slots - Define Time slots based on custom Integer Value (max is 60 for 1 hour) - WORKING

       
      3. Time Range Rules per Weekday - Define a minTime and MaxTime per Weekday (e.g. Opening Hours of a Restaurant) - NOT WORKING PROPERLY

       
      The Problem
      Time Slots and Day Restriction working fine so far. But the Time Range Rules per Weekday doesn't work right.
      What should happen is, that when you click on a date, it should update the minTime and maxTime of the Time Select.
      But the change on the select only happens if you select a date 2 times or when you select a date 1 time and then close the datepicker and reopen it again.
      The time select doesn't get change when you select a date 1 time and don't close the picker.
      Here is the whole extended InputfieldDatetime Module.
      The Files that I have changed:
      InputfieldDatetime.module InputfieldDatetime.js jquery-ui-timepicker-addon.js (https://trentrichardson.com/examples/timepicker/) - updated it to the newest version, because minTime and maxTime Option was only available in the new version  
      Thats the Part of the JS that is not working correctly:
      if(datetimerules && datetimerules.length){ options.onSelect = function(date, inst) { var day = $(this).datetimepicker("getDate").getDay(); day = day.toString(); var mintime = $(this).attr('data-weekday'+day+'-mintime'); var maxtime = $(this).attr('data-weekday'+day+'-maxtime'); console.log("weekday: "+day); console.log("minTime: "+mintime); console.log("maxTime: "+maxtime); var optionsAll = $(this).datetimepicker( "option", "all" ); optionsAll.minTime = mintime; optionsAll.maxTime = maxtime; $(this).datetimepicker('destroy'); $(this).datetimepicker(optionsAll); $(this).datetimepicker('refresh'); //$.datepicker._selectDate($(this).attr("id"),date); //$.datepicker._base_getDateDatepicker(); // var inst = $.datepicker._getInst($(this)); // $.datepicker._updateDatepicker(inst); /*$(this).datetimepicker('destroy'); InputfieldDatetimeDatepicker($(this), mintime, maxtime); $(this).datetimepicker('refresh'); */ // $(this).datetimepicker('option', {minTime: mintime, maxTime: maxtime}); } } Can you have a look and find out what the Problem is?
      InputfieldDatetime.zip
       
      Kind Regards
      Orkun
    • By teppo
      This module tracks changes, additions, removals etc. of public (as in "not under admin") pages of your site. Like it's name says, it doesn't attempt to be a version control system or anything like that - just a log of what's happened.
      At the moment it's still a work in progress and will most likely be a victim of many ruthless this-won't-work-let's-try-that-instead cycles, but I believe I've nailed basic functionality well enough to post it here.. so, once again, I'll be happy to hear any comments you folks can provide
      https://modules.processwire.com/modules/process-changelog/
      https://github.com/teppokoivula/ProcessChangelog
      How does it work?
      Exactly like it's (sort of) predecessor, Process Changelog actually consists of two modules: Process Changelog and Process Changelog Hooks. Hooks module exists only to serve main module by hooking into various functions within Pages class, collecting data of performed operations, refining it and keeping up a log of events in it's own custom database table (process_changelog.) Visible part is managed by Process Changelog, which provides users a (relatively) pretty view of the contents of said log table.
      How do you use it?
      When installed this module adds new page called Changelog under Admin > Setup which provides you with a table view of collected data and basic filtering tools See attached screenshots to get a general idea about what that page should look like after a while.
      For detailed installation instructions etc. see README.md.
       


    • By Gadgetto
      Status update links (inside this thread) for SnipWire development will be always posted here:
      2019-08-08
      2019-06-15
      2019-06-02
      2019-05-25
      If you are interested, you can test the current state of development:
      https://github.com/gadgetto/SnipWire
      Please note that the software is not yet intended for use in a production system (alpha version).
      If you like, you can also submit feature requests and suggestions for improvement. I also accept pull requests.
      ---- INITIAL POST FROM 2019-05-25 ----
      I wanted to let you know that I am currently working on a new ProcessWire module that fully integrates the Snipcart Shopping Cart System into ProcessWire. (this is a customer project, so I had to postpone the development of my other module GroupMailer).
      The new module SnipWire offers full integration of the Snipcart Shopping Cart System into ProcessWire.
      Here are some highlights:
      simple setup with (optional) pre-installed templates, product fields, sample products (quasi a complete shop system to get started immediately) store dashboard with all data from the snipcart system (no change to the snipcart dashboard itself required) Integrated REST API for controlling and querying snipcart data webhooks to trigger events from Snipcart (new order, new customer, etc.) multi currency support self-defined/configurable tax rates etc. Development is already well advanced and I plan to release the module in the next 2-3 months.
      I'm not sure yet if this will be a "Pro" module or if it will be made available for free.
      I would be grateful for suggestions and hints!
      (please have a look at the screenshots to get an idea what I'm talking about)
       




×
×
  • Create New...