[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
Poco Forums • View topic - Template Script

Template Script

Scripting questions and ideas

Moderators: Eric, Tomas, robin, Michael

Template Script

Postby ericjacobowitz » Thu May 05, 2005 1:48 pm

I have a template called SALE
I added a button to my toolbar
I created a script

perform/newmessage/Sale/

that I assigned to the button ( i thinik I assigned it the button)

but the script is not working. If i click on DEBUG, the template message does not open. If I click the button, the message does not not open

What did I do wrong?
Eric Jacobowitz
ericjacobowitz
Resident Poster
 
Posts: 147
Joined: Tue Apr 19, 2005 12:52 am

Postby Michael » Thu May 05, 2005 2:03 pm

Command tags can be used directly in the buttons, you don't have to add them to a script (in fact the syntax for doing so in a script is different). If you simply want to use the command tag then enter it in the button area of the script setup form (i.e., set the "Button n" field to "/perform/newmessage/Sale/").

Note: The trailing slash is required. You can optionally add a recipient to this if necessary.

If it is your intention to take this process further (i.e, you eventually want to do more than just open the message) then you will have to resort to a script. If this is the case then please reply and I'll walk through the details.
Michael
Moderator
 
Posts: 866
Joined: Mon Jul 26, 2004 12:14 pm
Location: Victoria BC, Canada

Postby ericjacobowitz » Thu May 05, 2005 2:20 pm

Thanks - that ALMOST worked

/perform/newmessage/Sale/ is in the button n (button 2) field

I click the button (button 2) and I get a regular blank message, I do not get my template. My template is called Sale
Eric Jacobowitz
ericjacobowitz
Resident Poster
 
Posts: 147
Joined: Tue Apr 19, 2005 12:52 am

Postby Michael » Fri May 06, 2005 4:08 am

Strange, I'd tested this before posting and it worked for me. I have to head off soon but will try to remember to check this tonight or tomorrow. If I forget a gentle prompt will help. ;)
Michael
Moderator
 
Posts: 866
Joined: Mon Jul 26, 2004 12:14 pm
Location: Victoria BC, Canada

Postby ericjacobowitz » Sat May 07, 2005 12:18 am

Gentle prompt :D
Eric Jacobowitz
ericjacobowitz
Resident Poster
 
Posts: 147
Joined: Tue Apr 19, 2005 12:52 am

Postby Michael » Sat May 07, 2005 1:56 am

Make sure there is a trailing slash at the end of the template name. I get the same behaviour you are describing if I omit the trailing slash but the template when the trailing slash is used.
Michael
Moderator
 
Posts: 866
Joined: Mon Jul 26, 2004 12:14 pm
Location: Victoria BC, Canada

Postby ericjacobowitz » Sat May 07, 2005 4:58 am

I just did a copy/paste
here is what I have

/perform/newmessage/sale/
Eric Jacobowitz
ericjacobowitz
Resident Poster
 
Posts: 147
Joined: Tue Apr 19, 2005 12:52 am

Postby Michael » Sat May 07, 2005 11:23 am

Now I am confused, I have exactly the same setting (including the template name) and it works for me. Hopefully someone else will be able to provide some insight.

For the record, my setting is:
Code: Select all
/perform/newmessage/sale/
Michael
Moderator
 
Posts: 866
Joined: Mon Jul 26, 2004 12:14 pm
Location: Victoria BC, Canada

Postby ericjacobowitz » Sat May 07, 2005 12:49 pm

is the template name case sensitive?
Eric Jacobowitz
ericjacobowitz
Resident Poster
 
Posts: 147
Joined: Tue Apr 19, 2005 12:52 am

Postby ericjacobowitz » Sat May 07, 2005 1:00 pm

/perform/newmessage/sale/
/perform/newmessage/sale.txt/
/perform/newmessage/Sale/
/perform/newmessage/Sale.txt/

none of them worked

I am using Pocomail 3.4.2130
Eric Jacobowitz
ericjacobowitz
Resident Poster
 
Posts: 147
Joined: Tue Apr 19, 2005 12:52 am

Postby ericjacobowitz » Sat May 07, 2005 1:02 pm

Ok - I got it working!
THank you for your help

I renamed my template. I deleted the name and just renamed it sale. Maybe I had an extra space or something, but now it is working
Eric Jacobowitz
ericjacobowitz
Resident Poster
 
Posts: 147
Joined: Tue Apr 19, 2005 12:52 am


Return to PocoScript Help and How-To

Who is online

Users browsing this forum: No registered users and 2 guests

cron