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

Funkydunk's COOL mod for total meta tag control

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #41  
Old 10-27-2003, 12:00 AM
 
Dlee Dlee is offline
 

Member
  
Join Date: Jan 2003
Location: Grand Prairie, TEXAS
Posts: 22
 

Default

Quote:
Originally Posted by funkydunk
This must be because there is a return or new line in the category_modify.tpl around the description field.

Take the extra space around the value of that field out and it will stop doing this.

hth


Found that little sucker at the end of line 34 works properly now.


<textarea cols=65 rows=15 name=description>


Thanks for the guided tour.


dlee
Reply With Quote
  #42  
Old 11-03-2003, 05:38 PM
 
mydivascloset mydivascloset is offline
 

Member
  
Join Date: Oct 2003
Posts: 11
 

Default

This is a great mod! Thanks for helping us out!

I have a suggestion/request.

Is there a way to have the products within the category use the same meta title, descriptions and keywords as the category that it resides in?

Thank you!
Reply With Quote
  #43  
Old 11-03-2003, 11:09 PM
 
wlekoh wlekoh is offline
 

Member
  
Join Date: Oct 2003
Posts: 25
 

Default

First of all, awesome work Funkydunk and thanks for the generosity by posting the code up. Thank you!

I got a question that maybe funkydunk or Dlee can answer...I'm haivng that problem where it inserts a space/line break in the description box when I go to edit a category.

Now Funkydunk said to edit the category_modify.tpl and can locate the file...but what is the exact change I have to make?? I'm no programmer (as you can tell)..how do I remove the line break?

Thanks in advance
Reply With Quote
  #44  
Old 11-04-2003, 09:23 AM
 
Dlee Dlee is offline
 

Member
  
Join Date: Jan 2003
Location: Grand Prairie, TEXAS
Posts: 22
 

Default

wlekoh,

If you can locate the file you are almost done. Open this file in a text editor like notepad. I use TextPad and I recommend it, it is very easy to use. Look for the line or do a search in the document via your text editor for this line of code.

<textarea cols=65 rows=15 name=description>

at the end of this line is where the problem is. Their is an extra space there and needs to be deleted. Don't let the line wrap, just delete the space.

Here is the corrected version of category_modify.tpl

Code:
{* $Id: category_modify.tpl,v 1.20 2002/11/10 09:26:46 ndv Exp $ *} {include file="location.tpl" last_location="Add/Modify category"} {capture name=dialog} <table border=0> <form name="addform" action="category_modify.php?mode={$smarty.get.mode}" method=post enctype="multipart/form-data"> <tr> <td>[img]../icon.php?categoryid={$cat}&rand={$rand}[/img]</td> <td colspan=2></td> </tr> <tr> <td height="10" class=FormButton nowrap>Icon</td> <td width="10" height="10"></td> <td><input type="file" name="userfile"></td> </tr> <TR> <TD height="10" class=FormButton nowrap>Order by</TD> <TD width="10" height="10"></TD> <TD height="10"><INPUT type=text name="order_by" size=4 value="{if $category_error ne ""}{$smarty.post.order_by}{elseif $smarty.get.mode ne "add"}{$current_category.order_by}{/if}"> </TR> <tr> <td height="10" class=FormButton nowrap>Category</td> <td width="10" height="10"><font class=CustomerMessage>*</font></td> <td height="10"> <input type="text" name="category_name" size="30" value="{if $category_error ne ""}{$smarty.post.category_name|escape:"htmlall"}{elseif $smarty.get.mode ne "add"}{$current_category.category|escape:"htmlall"}{/if}"> {if $category_error ne ""} <font color=red><< Wrong value</font> {/if} </td> </tr> <tr> <td height="10" class=FormButton nowrap valign=top>Description</td> <td width="10" height="10"><font class=CustomerMessage></font></td> <td height="10"> <textarea cols=65 rows=15 name=description> {if $category_error ne ""}{$smarty.post.description|escape:"htmlall"}{elseif $smarty.get.mode ne "add"}{$current_category.description|escape:"htmlall"}{/if} </textarea> </td> </tr> {* funkydunk metamod 2003 *} <tr> <td height=10 class=FormButton nowrap>Page Title</td> <td width="10" height="10"><font class=FormButtonOrange></font></td> <td height=10> <input type=text name=page_title size="30" value="{if $category_error ne ""}{$smarty.post.page_title|escape:"htmlall"}{elseif $smarty.get.mode ne "add"}{$current_category.page_title|escape:"htmlall"}{/if}"> </td> </tr> <tr> <td height=10 class=FormButton nowrap>Meta Description</td> <td width="10" height="10"><font class=FormButtonOrange></font></td> <td height=10> <input type=text name=meta_description size="30" value="{if $category_error ne ""}{$smarty.post.meta_description|escape:"htmlall"}{elseif $smarty.get.mode ne "add"}{$current_category.meta_description|escape:"htmlall"}{/if}"> </td> </tr> {* end of funkydunk metamod 2003 *} <tr> {* funkydunk metamod 2003 *} <td height=10 class=FormButton nowrap>Meta Keywords</td> {* end of funkydunk metamod 2003 *} <td width="10" height="10"><font class=FormButtonOrange></font></td> <td height=10> <input type=text name=meta_tags size="30" value="{if $category_error ne ""}{$smarty.post.meta_tags|escape:"htmlall"}{elseif $smarty.get.mode ne "add"}{$current_category.meta_tags|escape:"htmlall"}{/if}"> </td> </tr> <TR> <TD height=10 class=FormButton nowrap>Membership</TD> <TD width=10 height=10><FONT class=FormButtonOrange></FONT></TD> <TD height=10> <SELECT name=cat_membership> <OPTION value=""{if $current_category.membership eq ""} selected{/if}>All</OPTION> {section name=mi loop=$membership_levels} {if $membership_levels[mi].usertype eq "C"} <OPTION value="{$membership_levels[mi].membership}"{if $current_category.membership eq $membership_levels[mi].membership} selected{/if}>{$membership_levels[mi].membership}</OPTION> {/if} {/section} </SELECT> </TD> </TR> <tr> <td height=10 class=FormButton nowrap>Availability</td> <td width=10 height=10><font class=CustomerMessage></font></td> <td height="10"> <select name=avail> <option value='Y' {if ($current_category.avail eq 'Y')} selected {/if}>Enabled</option> <option value='N' {if ($current_category.avail eq 'N')} selected {/if}>Disabled</option> </select> </td> </tr> <tr> <td width="78" class=FormButton></td> <td width="10"></td> <td width="282"> <input type=submit value="Submit"> </td> </tr> <input type=hidden name=cat value={$cat}> </form> </table> {/capture} {include file="dialog.tpl" title="Add/Modify category" content=$smarty.capture.dialog extra="width=100%"}

That should do it. Just paste this code in to category_modify.tpl and your done.

dlee
Reply With Quote
  #45  
Old 11-04-2003, 01:58 PM
 
wlekoh wlekoh is offline
 

Member
  
Join Date: Oct 2003
Posts: 25
 

Default

Thanks Dlee, that fixed it up sure enough!
Has anyone had any problems using webmaster mode after this mod was installed? I can't seem to use that feature of X-cart anymore after installing this.
Reply With Quote
  #46  
Old 11-17-2003, 11:06 AM
 
censat censat is offline
 

Advanced Member
  
Join Date: Dec 2002
Location: Morton,MS
Posts: 64
 

Default SQL Patch

When I try to apply the patch...I get the following error

INVALID SQL: 1062 : Duplicate entry 'meta_title' for key 1
SQL QUERY FAILURE: INSERT INTO xcart_config VALUES ('meta_title', 'Meta Title', '', 'Company', 600, 'text')

Quote:

INSERT INTO xcart_config VALUES ('meta_title', 'Meta Title', '', 'Company', 600, 'text');
INSERT INTO xcart_config VALUES ('meta_description', 'Meta Description', 'DSS Remotes, DSS Accessories, DSS Parts, Pepper Spray, Personal Protection,Security Cameras,Surveillance Cameras, Surveillance Systems, PlayStation Accessories, PlayStation2 Accessories, Game Cube Accessories, XBOT Accessories,Stun Guns, Tasers, Metal Detectors.', 'Company', 601, 'text');
INSERT INTO xcart_config VALUES ('meta_keywords', 'Meta Keywords', 'security,surveillance,personal protection,dss,cband,game accessories,nintendo,playstation,dreamcast,gameboy ,pepper spray,mace,tasers,stun gun,car security,accessories,hidden cameras,remote surveillance,remotes,replacement remotes,remote controls,cell phone,cellphone,cellphone accessories,STUN GUNS,stun gun,TASERS,tasers,PEPPER SPRAY,pepper spray,pepper foam,MACE,PERSONAL ALARMS,CHILD PROTECTION,self defense', 'Company', 602, 'text');

ALTER TABLE `xcart_categories` ADD `page_title` VARCHAR( 255 ) AFTER `description` ;
ALTER TABLE `xcart_categories` ADD `meta_description` VARCHAR( 255 ) AFTER `page_title` ;

Using MSQL VER 4.0.16

Any Ideas?





Thank's
Censat
__________________
3.4.2 LIVE.....Modified a little....
Even Paranoids Can Have Real Enemies
Reply With Quote
  #47  
Old 11-22-2003, 02:03 AM
 
wlekoh wlekoh is offline
 

Member
  
Join Date: Oct 2003
Posts: 25
 

Default

I Think it means you have tried or have successfully ran and patched the SQL database using that query. Try going to general settings then "company setting" and have a look if there's fields there for meta tags.
Reply With Quote
  #48  
Old 11-22-2003, 02:07 AM
 
wlekoh wlekoh is offline
 

Member
  
Join Date: Oct 2003
Posts: 25
 

Default Meta Mod installed..category icons not working

Did you guys realise that by installing Funkydunk's meta mod it creates some problems with the category icons?? You can't add any category icons whatsoever...

Anyone figured out a soltion around this problem??
Reply With Quote
  #49  
Old 11-23-2003, 08:04 AM
 
curpier curpier is offline
 

Advanced Member
  
Join Date: Sep 2003
Posts: 38
 

Default

Quote:
Did you guys realise that by installing Funkydunk's meta mod it creates some problems with the category icons?? You can't add any category icons whatsoever...

Anyone figured out a soltion around this problem??

Same problem on my site. I cannot add any subcategory Icons anymore .
Reply With Quote
  #50  
Old 11-23-2003, 09:26 AM
 
curpier curpier is offline
 

Advanced Member
  
Join Date: Sep 2003
Posts: 38
 

Default

Figured it out ... see page 2
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 11:40 AM.

   

 
X-Cart forums © 2001-2020