Webmastersite.net
Register Log In

incat searches

Comments on incat searches

webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted May 08, 2011 - 2:29 PM:

When searching within a single category, we use something like...
<select class="searchdrops" name="incat" size="1"><option value="">All Services</option>{CATOPTIONS}</select>

I need to be able to display the category name on the the search results page. Using {INCAT} in search.tpl displays the cat id, I need to be able to display the cat name.

Currently I use a toplist to display the name...

<!-- BEGIN TOPLIST 1969 -->
<CONFIG>categories[,]id[,]1[,]ascending[,]id={INCAT}[,][,]0[,]0[,]0[,]0[,][,]0[,]0[,][,]0[,][,][,]</CONFIG>
{CATNAME}
<!-- END TOPLIST 1969 -->

But this pruduces an error if there is no {INCAT} value.

Can we have a new variable to display the cat name in the search templates when incat searches are done... or can you think of any other solution?

Thanks
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted May 19, 2011 - 1:05 PM:

If this can't be done, can you make it so the above toplist when used in search template does not cause an error if there is no {INCAT} result.

Also, Paul, I sent you another email about the calendar (bookings) modifications work I wanted you to quote me on, did you get it?
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7867
Paul
Posted May 19, 2011 - 9:25 PM:

I can do the category name on results page thing now for $20 (a {SEARCHCATNAME} template variable), or possibly get to it sometime free.
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted May 20, 2011 - 8:15 AM:

Yeah Paul, I'll have that.

Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7867
Paul
Posted May 23, 2011 - 6:54 PM:

It's in 6.0.27 Beta 1 now (currently releasing, will be out within 30 minutes). Payment link: www.wsnlinks.com/index.php?...section=payamount&price=20
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted May 23, 2011 - 7:09 PM:

Thanks Paul, Payment Made via PayPal 81853767WH563051P
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted May 23, 2011 - 8:11 PM:

Links to search results pages, such as below...

search.php?incat=21&statesearch=East+Anglia&statecondition=like&submit=Search&action=filter&filled=1&whichtype=links

Is there a way to rewrite them automatically using htaccess ?

something like... /21/East-Anglia/

Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7867
Paul
Posted May 27, 2011 - 11:09 AM:

I can rewrite them with a generic rule for $15, or you can rewrite each individual search to whatever you like on the SEO page if there are few enough for that to be practical.
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted Jun 02, 2011 - 6:47 PM:

Can you create a rewrite rule even of the statesearch has varied amounts of words?

if the URL has incat=21

can you match that to the category name so that the rewritten URL would be something like...

/restaurants/west-sussex/

?
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7867
Paul
#10 - Quote - Permalink
Posted Jun 05, 2011 - 5:42 PM:

As long as all the category names you link have no special characters in them, yes, I can come up with something for that.

You'll need to write out the URL links directly as yoursite.com/restauraunts/west-sussex/ , it won't autoreplace the php url.
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



Sorry, you don't have permission to post posts. Log in, or register if you haven't yet.