Calendar Page and next - prev link keywords


(Tony Kidman) #1

I am working on a calendar and need to apply a class to the previous and next links (%prev_link% %next_link%).  I can edit the contents within the details screen but I am not able to enter this class so it renders. 

 

Is there a global keyword (%prev_link_url% does not work for me) that can be used to get just the URL that way I can apply it to the type formatting?

 

Any help appreciated.

Tonkle.


(Nic Hubbard) #2

Couldn't you just wrap a div each keyword and give that a class?


(Tony Kidman) #3

Hi Nic,

 

tried it.

 

this is the code I require for the link : <a class="prev" href="#"><i class="icon-left-open"></i> Prev</a>

 

The problem is the template has been provided by a non-Matrix vendor and I am having to create the site from a static page with all the code.

 

If I need to change CSS - although little changes - it will push back a tight deadline.  There have been too many of these already.


(Tony Kidman) #4

I have fixed it but it required changing the css and the formatting - at least it only needs to be applied in the one place.


(Nic Hubbard) #5

Hi Nic,

 

tried it.

 

this is the code I require for the link : <a class="prev" href="#"><i class="icon-left-open"></i> Prev</a>

 

The problem is the template has been provided by a non-Matrix vendor and I am having to create the site from a static page with all the code.

 

If I need to change CSS - although little changes - it will push back a tight deadline.  There have been too many of these already.

 

You could also have used javascript to insert the icon into the anchor.


(Tbaatar) #6

Little bit hacky but works a treat is to use metadata when Matrix is refusing to print simple HTML.

 

Place your HTML code as text metadata, and place this metadata into the prev/next field in the calendar asset. Matrix will print everything this way :)

 

I usually have 1 main metadata with the following fields:

 

1. Keywords  - use for search engine

2. Description - use for search engines

3. Title - additional title / or for translation purposes

4. Image - twitter card / facebook open graph sharing

5. Language - language purposes e.g print en, de, fr etc into the body tag for styling and also into the metalang

6. Script - when you need inline script

7. Extra1 - for everything, but in your case you would put - <i class="icon-left-open"></i>

8. Extra2 - for everything, and <i class="icon-right-open"></i>