Welcome, Guest ( Customer Panel | Login )




 All Forums
 VPCart Forum
 Problems and bugs
 hidden products still showing
 New Topic  Reply to Topic
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

skynet104
VP-CART New User

94 Posts

Posted - November 06 2008 :  14:17:45  Show Profile  Reply with Quote
Hi:
We have many items out of stock, so we hide them, however since google still is listing them, when referenced from google to our page it stills shows the item.

This suppost to be fixed by now, does support have any fix for this?

Please Advice

Steve2507
VP-CART Expert

590 Posts

Posted - November 07 2008 :  07:42:42  Show Profile  Reply with Quote
We have the same problem. We have to do a redirect of that page to the category page.

I've been trying to do a simple redirect in the shopexd file where it would redirect if hidden=false but can't get it to work.


Steve
Sex toys from a UK sex shop

Edited by - Steve2507 on November 07 2008 07:47:42
Go to Top of Page

carfin
VP-CART Expert

United Kingdom
948 Posts

Posted - November 07 2008 :  08:57:26  Show Profile  Reply with Quote
You can stop the hidden products from showing by adding a couple of lines of code to shopexd.asp (the brown highlighted code)

Find this sub:

Sub ExdOpenRecordSet (RS)
If catalogid<>"" then
Sql="select * from products where catalogid=" & catalogid & "AND hide=False"
else
sql="select * from products where ccode='" & ccode & "'" & "AND hide=False"
end if
Set rs=dbc.execute(sql)
If rs.eof then
Serror = SError & getlang("LangReadFail") & " " & catalogid
HandleError
end if
end sub


You can then edit the error message ("LangReadFail") through the Admin panel to display "Product not available" or something similar. I don't know about redirecting to the category page from shopexd.asp, that would take some custom coding to do.

Hope this helps,

Carrol
www.deanston-electrical.co.uk
Go to Top of Page

skynet104
VP-CART New User

94 Posts

Posted - November 08 2008 :  16:09:32  Show Profile  Reply with Quote
Hi;

Thanks for your reply, however the following error shows:

Microsoft OLE DB Provider for ODBC Drivers error '80040e14'

[Microsoft][ODBC SQL Server Driver][SQL Server]Invalid column name 'False'.

/shopexd.asp, line 85

Please Advice.

Thanks
Go to Top of Page

skynet104
VP-CART New User

94 Posts

Posted - November 08 2008 :  16:47:47  Show Profile  Reply with Quote
Ok, this code worked for me:

Sub ExdOpenRecordSet (RS)
If catalogid<>"" then
Sql="select * from products where catalogid=" & catalogid
else
sql="select * from products where ccode='" & ccode & "'"
end if
sql=sql & " and Hide=0 "
if getconfig("xstockcontrol")= "Yes" then
dim stocklowlevel
if getconfig("xstocklow") = "" or ISNULL(getconfig("xstocklow")) then
stocklowlevel = 0
else
stocklowlevel = getconfig("xstocklow")
end if

sql = sql & " and cstock > " & stocklowlevel
end if
Go to Top of Page

Steve2507
VP-CART Expert

590 Posts

Posted - November 24 2008 :  10:43:04  Show Profile  Reply with Quote
I'm still working on this.

Neither of the above solutions work for us.

What I would like to do is redirect the user to a special page that explains the item is discontinued.

I've added the following code to the top of shopexd but no joy.

Any ideas anyone?

Dim rwehiding
rwehiding=request("hide")
If rwehiding="True" then
response.Redirect "default-discontinued.asp"
end if



Steve
Sex toys from a UK sex shop
Go to Top of Page

carfin
VP-CART Expert

United Kingdom
948 Posts

Posted - November 24 2008 :  11:57:14  Show Profile  Reply with Quote
Hi Steve,

I've tested this code in shopexd.asp by entering addresses into the browser that point to hidden products in our database(Access) and each time it seems to work fine. I commented out the eof error message and replaced it with a redirect.

Sub ExdOpenRecordSet (RS)
If catalogid<>"" then
Sql="select * from products where catalogid=" & catalogid & "AND hide=False"
else
sql="select * from products where ccode='" & ccode & "'" & "AND hide=False"
end if

Set rs=dbc.execute(sql)
If rs.eof then
response.Redirect "http://mysite/Discontinued.asp"
'Serror = SError & getlang("LangReadFail") & " " & catalogid
'HandleError
end if
end sub


I tested shopexd.asp?id=192 and shopexd.asp?id=192&bc=no and both displayed the Discontinued page. Do the links from Google have anything else added to the end of the address?

Regards,


Carrol
www.deanston-electrical.co.uk
Go to Top of Page

Steve2507
VP-CART Expert

590 Posts

Posted - November 24 2008 :  13:41:46  Show Profile  Reply with Quote
Hi Carrol,

Thanks for the help.

Our urls are rewritten and use a number of variables. This is why the set up you have wont work on our system.

Bringing the check against hide before anything else means we shouldn't need to worry about the sql part.


Steve
Sex toys from a UK sex shop
Go to Top of Page

carfin
VP-CART Expert

United Kingdom
948 Posts

Posted - November 25 2008 :  05:39:38  Show Profile  Reply with Quote
Yes, I thought your urls were rewritten.

One for the support guys I think

Regards,

Carrol
www.deanston-electrical.co.uk
Go to Top of Page

Steve2507
VP-CART Expert

590 Posts

Posted - November 27 2008 :  12:36:21  Show Profile  Reply with Quote
quote:
Originally posted by carfin

Yes, I thought your urls were rewritten.

One for the support guys I think

Regards,

Carrol
www.deanston-electrical.co.uk


No problem Carrol, I've sent a support request.



Steve
Sex toys from a UK sex shop
Go to Top of Page

borisvel
Starting Member

Slovenia
47 Posts

Posted - January 05 2012 :  05:26:06  Show Profile  Visit borisvel's Homepage  Reply with Quote
quote:
Originally posted by carfin

You can stop the hidden products from showing by adding a couple of lines of code to shopexd.asp (the brown highlighted code)

Find this sub:

Sub ExdOpenRecordSet (RS)
If catalogid<>"" then
Sql="select * from products where catalogid=" & catalogid & "AND hide=False"
else
sql="select * from products where ccode='" & ccode & "'" & "AND hide=False"
end if
Set rs=dbc.execute(sql)
If rs.eof then
Serror = SError & getlang("LangReadFail") & " " & catalogid
HandleError
end if
end sub


You can then edit the error message ("LangReadFail") through the Admin panel to display "Product not available" or something similar. I don't know about redirecting to the category page from shopexd.asp, that would take some custom coding to do.

Hope this helps,

Carrol
www.deanston-electrical.co.uk



Hi Carrol,

is it possible to do same for hidden but not deleted categories??

Thanks for your replay and kind regards, Boris
Go to Top of Page

borisvel
Starting Member

Slovenia
47 Posts

Posted - January 05 2012 :  05:29:04  Show Profile  Visit borisvel's Homepage  Reply with Quote
quote:
Originally posted by borisvel

quote:
Originally posted by carfin

You can stop the hidden products from showing by adding a couple of lines of code to shopexd.asp (the brown highlighted code)

Find this sub:

Sub ExdOpenRecordSet (RS)
If catalogid<>"" then
Sql="select * from products where catalogid=" & catalogid & "AND hide=False"
else
sql="select * from products where ccode='" & ccode & "'" & "AND hide=False"
end if
Set rs=dbc.execute(sql)
If rs.eof then
Serror = SError & getlang("LangReadFail") & " " & catalogid
HandleError
end if
end sub


You can then edit the error message ("LangReadFail") through the Admin panel to display "Product not available" or something similar. I don't know about redirecting to the category page from shopexd.asp, that would take some custom coding to do.

Hope this helps,

Carrol
www.deanston-electrical.co.uk



Hi Carrol,

is it possible to do same for hidden but not deleted categories??

Thanks for your replay and kind regards, Boris



Hi, me again

second thoughts...

How to redirect in such case to other existing page?
Go to Top of Page

carfin
VP-CART Expert

United Kingdom
948 Posts

Posted - January 05 2012 :  08:58:08  Show Profile  Reply with Quote
Hi Borisvel,

you have to add a redirect statement to the sub.

Open shopexd.asp

Find sub and add code highlighted with brown. Change the redirect address to the page you require.

Sub ExdOpenRecordSet (RS)
If catalogid<>"" then
Sql="select * from products where catalogid=" & catalogid & "AND hide=False"
else
sql="select * from products where ccode='" & ccode & "'" & "AND hide=False"
end if

Set rs=dbc.execute(sql)
If rs.eof then
response.Redirect "http://www.yoursite.com/Discontinued.asp"
' Serror = SError & getlang("LangReadFail") & " " & catalogid
' HandleError
end if
end sub

Hope this helps.

Regards,

Carrol
www.deanston-electrical.co.uk
Go to Top of Page

borisvel
Starting Member

Slovenia
47 Posts

Posted - January 06 2012 :  05:57:12  Show Profile  Visit borisvel's Homepage  Reply with Quote
quote:
Originally posted by carfin

Hi Borisvel,

you have to add a redirect statement to the sub.

Open shopexd.asp

Find sub and add code highlighted with brown. Change the redirect address to the page you require.

Sub ExdOpenRecordSet (RS)
If catalogid<>"" then
Sql="select * from products where catalogid=" & catalogid & "AND hide=False"
else
sql="select * from products where ccode='" & ccode & "'" & "AND hide=False"
end if

Set rs=dbc.execute(sql)
If rs.eof then
response.Redirect "http://www.yoursite.com/Discontinued.asp"
' Serror = SError & getlang("LangReadFail") & " " & catalogid
' HandleError
end if
end sub

Hope this helps.

Regards,

Carrol
www.deanston-electrical.co.uk



Hi Carrol,

many thanks, it works fine.

Could you please also propose solution for hidden or deleted categories?

I reorganized my cart and i don't want to loose very good positions in Google search with those hidden links.

Many thanks again, Boris

Go to Top of Page

carfin
VP-CART Expert

United Kingdom
948 Posts

Posted - January 07 2012 :  05:54:44  Show Profile  Reply with Quote
Hi,

best solution for hidden categories is to remove (or hide if possible) products that are assigned to that category.
For deleted categories, surely you would have checked first and removed assigned products before you delete the category?

Regards,

Carrol
www.deanston-electrical.co.uk
Go to Top of Page

borisvel
Starting Member

Slovenia
47 Posts

Posted - January 08 2012 :  05:15:47  Show Profile  Visit borisvel's Homepage  Reply with Quote
quote:
Originally posted by carfin

Hi,

best solution for hidden categories is to remove (or hide if possible) products that are assigned to that category.
For deleted categories, surely you would have checked first and removed assigned products before you delete the category?

Regards,

Carrol
www.deanston-electrical.co.uk



Hi Carrol,

i agree. I meant links like

/shopdisplaycategories.asp?id=347&cat=Darila+za+rojstni+dan

There are no more product's in that category, categorie is hidden but not deleted. It appers in Google search results, but site displays only header and trailer without anyting else.

I would like to redirect such links to if possible.

Thanks and kind regards

www.finechance.com www.personaliziranadarila.si www.lingerie.si
Go to Top of Page
Page: of 2
Previous Topic Topic Next Topic  
Next Page
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000
0 Item(s)
$0.00