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

Adding 'Search for Events' on the homepage

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 10-23-2007, 07:07 PM
 
pjsimonetta pjsimonetta is offline
 

Newbie
  
Join Date: Oct 2007
Posts: 8
 

Default Adding 'Search for Events' on the homepage

I want to be able to add the 'Search for Events' form from the gift registry add-on to the home page, in the middle area above featured products.

Is there a way to include this and how?

Thanks,
Simonetta
__________________
4.1.9
Reply With Quote
  #2  
Old 10-24-2007, 04:36 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: Adding 'Search for Events' on the homepage

Welcome to the X-Cart forums! Please start by reading the following thread, which will help you get started and hopefully make your experience here a positive one:

http://forum.x-cart.com/showthread.php?t=23970

Please note that this link is not an answer to your question, but we need you to update your signature with your X-Cart version so that we can answer your question correctly. Thanks!
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 10-24-2007, 04:40 AM
 
pjsimonetta pjsimonetta is offline
 

Newbie
  
Join Date: Oct 2007
Posts: 8
 

Default Re: Adding 'Search for Events' on the homepage

Signature updated
__________________
4.1.9
Reply With Quote
  #4  
Old 10-24-2007, 04:42 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: Adding 'Search for Events' on the homepage

Thanks! So just open up skin1/customer/main/welcome.tpl and add the link wherever you want.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #5  
Old 10-24-2007, 04:46 AM
 
pjsimonetta pjsimonetta is offline
 

Newbie
  
Join Date: Oct 2007
Posts: 8
 

Default Re: Adding 'Search for Events' on the homepage

So will this add the form or the entire page I want the actual form to be displayed on the front page. Doesn't 'giftregs.php' display the whole site as well as the 'search for events' form?
Thanks
__________________
4.1.9
Reply With Quote
  #6  
Old 10-24-2007, 04:55 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: Adding 'Search for Events' on the homepage

You can add the whole form (not the php file) to the template if you wish, yes.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #7  
Old 10-24-2007, 05:05 AM
 
pjsimonetta pjsimonetta is offline
 

Newbie
  
Join Date: Oct 2007
Posts: 8
 

Default Re: Adding 'Search for Events' on the homepage

So where do I get the form from? giftreg.php? and if so what part of the code do I copy into welcome.tpl

require "./auth.php";

if (empty($active_modules["Gift_Registry"]))
func_header_location("error_message.php?page_not_f ound");

x_session_register("access_status", array());


if ($mode == "preview") {
$html_content = func_query_first_cell("SELECT html_content FROM $sql_tbl[giftreg_events] WHERE event_id='$eventid'");
if (!empty($html_content))
echo $html_content;
else
echo "<br /><br /><br /><br /><h3 align=\"center\">".func_get_langvar_by_name("lbl_n o_html_content",false,false,true)."</h3>";
exit;
}

include $xcart_dir."/include/categories.php";

if($active_modules["Manufacturers"])
include $xcart_dir."/modules/Manufacturers/customer_manufacturers.php";

if (!empty($cc)) {
#
# Confirm/Decline the participation by recipient
# $cc - is a confirmation code passed via GET request
#
include $xcart_dir."/modules/Gift_Registry/giftreg_confirm.php";
}

if (!empty($eventid)) {

if (!empty($wlid)) {
if (func_query_first_cell("SELECT COUNT(*) FROM $sql_tbl[giftreg_events] WHERE MD5(login)='$wlid' AND event_id='$eventid'")) {
x_session_register("wlid_eventid");
$wlid_eventid = $eventid;
x_session_save("wlid_eventid");
}
}

include $xcart_dir."/modules/Gift_Registry/event_guestbook.php";
include $xcart_dir."/modules/Gift_Registry/giftreg_display.php";
}
else
include $xcart_dir."/modules/Gift_Registry/giftreg_search.php";

# Assign the current location line
$smarty->assign("location", $location);

func_display("customer/home.tpl",$smarty);
?>
__________________
4.1.9
Reply With Quote
  #8  
Old 10-24-2007, 05:11 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: Adding 'Search for Events' on the homepage

Ok, in X-Cart, you never really need to touch the php. All of the files you need are in the templates. For the gift registry, all of the files are in the skin1/modules/Gift_Registry folder. Simply use Webmater Mode to find out which template you are looking for, and then open that template to see the form code for the part you are looking for. May want to read this thread to give you some guidance on the template system in X-Cart:

http://forum.x-cart.com/showthread.php?t=21529
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #9  
Old 10-24-2007, 05:27 AM
 
pjsimonetta pjsimonetta is offline
 

Newbie
  
Join Date: Oct 2007
Posts: 8
 

Default Re: Adding 'Search for Events' on the homepage

Thank you I got the form on the front page. So you need to find the html somewhere in the template pages and add them to other template pages and so on?
__________________
4.1.9
Reply With Quote
  #10  
Old 10-24-2007, 05:28 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: Adding 'Search for Events' on the homepage

All of the html is in templates, yes.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 03:24 AM.

   

 
X-Cart forums © 2001-2020