Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Send to Friend on product pages.

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #51  
Old 12-02-2003, 01:56 PM
 
jacobkball jacobkball is offline
 

Advanced Member
  
Join Date: Oct 2003
Location: Brisbane, Australia
Posts: 45
 

Default

I had tried that, but then kept getting the error "Can't write template cache in the directory: /templates_c. Please check if it exists, and have writable permissions".

You need to remove these lines:

Code:
require $xcart_dir."/smarty.php"; require $xcart_dir."/config.php"; @include "./https.php";

as you'll notice that in the files X-Cart have updated, they have removed these lines also.
__________________
Version 3.5.1 (Unix)
Reply With Quote
  #52  
Old 12-02-2003, 11:25 PM
 
various various is offline
 

Newbie
  
Join Date: Nov 2003
Posts: 6
 

Default

Quote:
Originally Posted by jacobkball
I had tried that, but then kept getting the error "Can't write template cache in the directory: /templates_c. Please check if it exists, and have writable permissions".

You need to remove these lines:

Code:
require $xcart_dir."/smarty.php"; require $xcart_dir."/config.php"; @include "./https.php";

as you'll notice that in the files X-Cart have updated, they have removed these lines also.

This worked for me, thanks for your time jacobkball & BOOMER!
Reply With Quote
  #53  
Old 12-03-2003, 05:27 AM
  leon's Avatar 
leon leon is offline
 

X-Wizard
  
Join Date: Mar 2003
Location: Costa Rica
Posts: 1,213
 

Default

Wonder if there is any stable and straightforward code for this mod ?
__________________
It doesn\'t matter what is done... it is how it is done.
=============================
XCart Version: 3.5.3 -> Dmcigars.com
XCart Version: 4.1.3....
Reply With Quote
  #54  
Old 12-11-2003, 08:37 AM
 
laureon laureon is offline
 

Senior Member
  
Join Date: Oct 2003
Posts: 171
 

Default

Quote:
Wonder if there is any stable and straightforward code for this mod ?

I am successfully loading the 'sendtofriend.php' after implementing the appropriate fixes, but am receiving the following error when submitting the information on the sendtofriend page:

Warning: Failed to Receive in c:\www\xcart\include\func.php on line 269

Warning: Cannot add header information - headers already sent by (output started at c:\www\xcart\include\func.php:269) in c:\www\xcart\customer\sendtofriend.php on line 39

I am using v3.5.1 as opposed to v3.5.0, perhaps further fixes are required for v3.5.1? or it could be something i'm doing wrong

Lines 268-272 of my include/func.php:
Code:
if (preg_match('/([^ @,;<>]+@[^ @,;<>]+)/S', $from, $m)) mail($to,$mail_subject,$mail_message,$headers, "-f".$m[1]); else mail($to,$mail_subject,$mail_message,$headers); }

Lines 36-42 of customer\sendtofriend.php:
Code:
func_send_mail($contact["sendtoemail"], "mail/sendtofriend_subj.tpl", "mail/sendtofriend.tpl", $contact["email"], true); $productid = $product_info['productid']; header("Location: sendtofriend.php?section=sendtofriend&productid=$productid"); exit; } else {
Reply With Quote
  #55  
Old 12-11-2003, 10:01 AM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

make sure you dont have any blank spaces at the end of the .php files
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
  #56  
Old 12-11-2003, 11:11 AM
  leon's Avatar 
leon leon is offline
 

X-Wizard
  
Join Date: Mar 2003
Location: Costa Rica
Posts: 1,213
 

Default

That is something I havent been able to explain to myself, why do spaces get involved in this ?
__________________
It doesn\'t matter what is done... it is how it is done.
=============================
XCart Version: 3.5.3 -> Dmcigars.com
XCart Version: 4.1.3....
Reply With Quote
  #57  
Old 12-20-2003, 08:06 PM
  BCSE's Avatar 
BCSE BCSE is offline
 

X-Guru
  
Join Date: Apr 2003
Location: Ohio - bcsengineering.com
Posts: 3,091
 

Default

I got this to work like a charm in 3.3.5. I think I got it working in 30 min or less. I used only what was said in page 1 from Boomer. I also added &partner=sendtofriend onto the URL for tracking purposes (and if Affiliate gets installed at a later date).

Great Mod Boomer! Thanks! I'll be buying something from your store soon for my appreciation!

Carrie
BTW: Going to add a nice button for it instead of a text link in a few days. No time now.
__________________
Custom Development, Custom Coding and Pre-built modules for X-cart since 2002!

We support X-cart versions 3.x through 5.x!

Home of the famous Authorize.net DPM & CIM Modules, Reward Points Module, Point of Sale module, Speed Booster modules and more!


Over 200 X-cart Mods available & Thousands of Customizations Since 2002 - bcsengineering.com

Please E-Mail us for questions/support!
Reply With Quote
  #58  
Old 12-22-2003, 10:47 PM
 
mustang mustang is offline
 

eXpert
  
Join Date: Nov 2003
Location: US
Posts: 210
 

Default

I'd love to get Boomer's 'Send to Friend' mod working in LiteCommerce. Anyone have any idea how to accomplish this? Please let me know...
__________________
X-Cart Gold 4.2.3
-----
PHP 5.2.17 | MySQL 5.1.52
Reply With Quote
  #59  
Old 12-22-2003, 10:54 PM
  B00MER's Avatar 
B00MER B00MER is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Keller, TX (Cart-Lab.com)
Posts: 3,165
 

Default

Unfortunatly I'm not too familiar with the template system lite commerce uses, not to mention ive not customized a lite commerce site yet.
__________________
Cart-Lab - 100+ Social Bookmarks for X-Cart.
Reply With Quote
  #60  
Old 01-07-2004, 08:31 AM
 
PhilJ PhilJ is offline
 

X-Guru
  
Join Date: Nov 2002
Posts: 4,094
 

Default

check boomer's site for this mod in the freebie section
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions



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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 10:27 PM.

   

 
X-Cart forums © 2001-2020