BigCommerce - Hosted Ecommerce Software by Interspire

Interspire Forum

 
Go Back   Interspire Forum > Interspire Email Marketer Community Forum > Customization and Integration

Reply
 
Thread Tools Display Modes
  #1  
Old 04-02-2008, 12:00 PM
everisk + everisk is offline
Interspire Customer
 
Join Date: Apr 2008
Posts: 9
Default Design rules check and Spam check API

I'm just a novice PHP programmer so if anyone could show an example on how to use the 2 APIs (design_rules_check and spam_check api) I'd be very thankful.

Thanks.
Reply With Quote
  #2  
Old 04-03-2008, 12:06 AM
Chris S Chris S is offline
Senior Member
 
Join Date: Feb 2004
Posts: 4,642
Default

Hi,

You'll be best off following how sendstudio uses them.

Check out the admin/functions/sendstudio_functions.php file and look for the function called 'CheckContentForSpam'.

You probably need everything BEFORE:

PHP Code:
$broken_rules_area = array('html''text'); 
and just change this:

PHP Code:
$spam_api $this->GetApi('Spam_Check'); 
to

PHP Code:
require('/path/to/sendstudio/admin/functions/api/spam_check.php');
$spam_api = new Spam_Check_API(); 
and follow the rest.

For the design rules, look at the admin/functions/preview.php file for how it does everything, particularly the 'case' for 'processeachrule'.

Quote:
Originally Posted by everisk
I'm just a novice PHP programmer so if anyone could show an example on how to use the 2 APIs (design_rules_check and spam_check api) I'd be very thankful.

Thanks.
Reply With Quote
  #3  
Old 04-03-2008, 04:25 AM
everisk + everisk is offline
Interspire Customer
 
Join Date: Apr 2008
Posts: 9
Default

Thanks, Chris. I got the spam check working nicely now. I'm still looking into the design rules but dont really know how to get started. Could you start me off please? Thanks a lot again.
Reply With Quote
  #4  
Old 04-03-2008, 05:08 AM
everisk + everisk is offline
Interspire Customer
 
Join Date: Apr 2008
Posts: 9
Default

I think I just worked it out. Thanks!
Reply With Quote
  #5  
Old 04-07-2008, 12:58 AM
Chris S Chris S is offline
Senior Member
 
Join Date: Feb 2004
Posts: 4,642
Default

Hi,

No problems If you need anything else let me know.
Quote:
Originally Posted by everisk
I think I just worked it out. Thanks!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump