Message Header

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Message Header

Coleen_Astalos
I previously created a special message at the top of emails from one section of my forum (Newsletter Co-op, Next Month's Article Staging Area) by adding this new macro to the instant_html macro:

 <macro name="SUDSOL_message_header" parameters="append" requires="subscription, node_page">
    <n.set_local_user.this_subscription.user/>
    <n.set_local_node.page_node.get_app_node/>
    <n.if.equal value1="[n.local_node.subject/]" value2="Next Month’s Article Staging Area">
        <then>
            <t>NOTE: This email is only being distributed to NEWSLETTER CO-OP Members.</t> <n.hide_null.append/><br/><br/>
            <div style="color:#444; font: 12px tahoma,geneva,helvetica,arial,sans-serif;">
                <a href="mailto:[n.page_node.owner.user_email/]?subject=[n.page_node.subject/]">Click here to reply directly to <n.page_node.owner.name/> privately at <n.page_node.owner.user_email/></a>
                <div style="font-weight:bold"><t>If you just reply to this email, your message will go back to ONLY Newsletter Co-op members.</t></div>
            </div>
            <hr noshade="noshade" size="1" color="#cccccc" />
        </then>
        <else>
            <div style="color:#444; font: 12px tahoma,geneva,helvetica,arial,sans-serif;">
                <a href="mailto:[n.page_node.owner.user_email/]?subject=[n.page_node.subject/]">Click here to reply directly to <n.page_node.owner.name/> privately at <n.page_node.owner.user_email/></a>
                <div style="font-weight:bold"><t>If you just reply to this email, your message will go to all SUDSOL members, unless you change the To: email address to the author: <n.page_node.owner.user_email/></t></div>
            </div>
            <hr noshade="noshade" size="1" color="#cccccc" /> <n.hide_null.append/>
        </else>
    </n.if.equal>
    
</macro> 

Here is where it's called in instant_html:
 <override_macro name="instant_html" requires="subscription,node_page">
        <n.if.page_node.is_app>
        <then>
            <t><t.username.page_node.owner.name/> created a new subcategory</t>:
            <b><n.page_node.subject/></b><br/><br/>
        </then>
    </n.if.page_node.is_app>
 
    <n.SUDSOL_message_header/>
    <n.page_node.html_email_message_with_signature/>
    <br/>
    <n.comment.>Changed wording where reply goes to and included author email address</n.comment.>
    <hr noshade="noshade" size="1" color="#cccccc" />
    <div style="color:#444; font: 12px tahoma,geneva,helvetica,arial,sans-serif;">
        <t>If you want the reply to go ONLY to <n.page_node.owner.name/>, please change the email address to: </t>
        <a href="mailto:[n.page_node.owner.user_email/]"><n.page_node.owner.user_email/></a>
        <br/>
        <t>This message can be found in the SUDSOL Discussion Forum here</t>:
        <a href="[n.page_node.url/]"><n.page_node.url/></a>
    </div>
    <div style="color:#666; font: 11px tahoma,geneva,helvetica,arial,sans-serif;margin-top:.4em;line-height:1.5em">
        <n.start_new_topic_line append="[br/]"/>
        <n.unsubscribe_line format="html"/><br/>
    <n.comment.>Removed link to view naml code</n.comment.>
    </div>
</override_macro> 

It was working great for the last several months (I implemented this is early September).  However, I noticed that it stopped sometime between Oct 28th & Nov 6th.  It is no longer adding the special Newsletter Co-op banner when it comes from that category.  Of course, that's right in the timeframe when we implemented the Froala editor, which I wouldn't think would have any effect on this - especially since I rolled back yesterday to an October 28th image.  But also when you guys did some site maintenance.

Were there changes done that would affect this?
Is there anything you notice that is wrong about the code I've got?
Is there another way I should be doing this?

Thanks,
Coleen
Reply | Threaded
Open this post in threaded view
|

Re: Message Header

GregChapman
This post was updated on .
I wonder if this is related to the bug I am reporting at:
http://support.nabble.com/Missing-Date-in-Emails-tp7592604.html
Just a Volunteer Nabble Helper - because the nice folk at Nabble have helped me!
Reply | Threaded
Open this post in threaded view
|

Re: Message Header

Coleen_Astalos
Interesting that it's right in the same time frame (Nov 27th - Dec 12th).
Coleen
Reply | Threaded
Open this post in threaded view
|

Re: Message Header

Coleen_Astalos
In reply to this post by Coleen_Astalos
With Greg's comment and knowing that I'm always going into the ELSE statement in this IF check:
<n.if.equal value1="[n.local_node.subject/]" value2="Next Month’s Article Staging Area">

I did an echo out of n.local_node.subject before the IF check to see if it wasn't being set and that was why it was going to the ELSE.  Nope.  The echo of n.local_node.subject is coming back as "Next Month's Article Staging Area"

So I removed the apostrophe from the section name (as I know those can cause problems sometimes) and updated the macro.  It is now working fine.  So something changed as it worked with the apostrophe previously, but no longer works with the apostrophe.  I'm fine with removing the apostrophe from my section name - so my problem is solved.

Greg, hope they get your problem figured out!
Coleen
Reply | Threaded
Open this post in threaded view
|

Re: Message Header

Pedro <Nabble>
Is it working with the apostrophe?
My test forum.
Reply | Threaded
Open this post in threaded view
|

RE: Message Header

Coleen_Astalos

No, I removed the apostrophe and now it's working.  It WAS working before Oct 28th with the apostrophe.

Coleen

 

Coleen Astalos, Stampin' Up! Demonstrator
Alamosa, CO, [hidden email]
See my website at http://alamosa.stampinup.net
Are you a demonstrator? Join me on SUDSOL - Your 24/7 Upline!

 

From: Pedro <Nabble> [via Nabble Support] [mailto:[hidden email]]
Sent: Thursday, November 20, 2014 7:59 PM
To: Coleen_Astalos
Subject: Re: Message Header

 

Is it working with the apostrophe?

My test forum.

 


If you reply to this email, your message will be added to the discussion below:

http://support.nabble.com/Message-Header-tp7592763p7592779.html

To unsubscribe from Message Header, click here.
NAML

Reply | Threaded
Open this post in threaded view
|

RE: Message Header

Pedro <Nabble>
I tested the if clause <a href="http://: http://coleen-test.1112551.n5.nabble.com/Next-Month-s-Article-Staging-Area-f14.html ">here.
At the beginning the title was not matching. So, I changed the apostrophe character, replaced ´ with ', and also rewrote the sentence. Since I had copy the title from here it seems to have come with some bad characters inside the spaces.
You could test the if clause in your forum until get the titles matched, then you can use the apostrophe again.
My test forum.
Reply | Threaded
Open this post in threaded view
|

RE: Message Header

Coleen_Astalos

Thanks.  I think I'll just leave it as it is.

Coleen

 

Coleen Astalos, Stampin' Up! Demonstrator
Alamosa, CO, [hidden email]
See my website at http://alamosa.stampinup.net
Are you a demonstrator? Join me on SUDSOL - Your 24/7 Upline!

 

From: Pedro <Nabble> [via Nabble Support] [mailto:[hidden email]]
Sent: Friday, November 21, 2014 5:55 AM
To: Coleen_Astalos
Subject: RE: Message Header

 

I tested the if clause <a href="<a href="http://:%20http:/coleen-test.1112551.n5.nabble.com/Next-Month-s-Article-Staging-Area-f14.html%20">http://: http://coleen-test.1112551.n5.nabble.com/Next-Month-s-Article-Staging-Area-f14.html ">here.
At the beginning the title was not matching. So, I changed the apostrophe character, replaced ´ with ', and also rewrote the sentence. Since I had copy the title from here it seems to have come with some bad characters inside the spaces.
You could test the if clause in your forum until get the titles matched, then you can use the apostrophe again.

My test forum.

 


If you reply to this email, your message will be added to the discussion below:

http://support.nabble.com/Message-Header-tp7592763p7592796.html

To unsubscribe from Message Header, click here.
NAML