logo
Welcome to our new AbleCommerce forums. As a guest, you may view the information here. To post to this forum, you must have a registered account with us, either as a new user evaluating AbleCommerce or an existing user of the application. For all questions related to the older version of Gold and earlier, please go to AbleCommerce Gold forum. Please use your AbleCommerce username and password to Login. New Registrations are disabled.

Notification

Icon
Error

Options
Go to last post Go to first unread
IDAutomation  
#1 Posted : Tuesday, September 15, 2020 8:35:09 AM(UTC)
IDAutomation

Rank: Member

Groups: Authorized User, Developers
Joined: 11/13/2018(UTC)
Posts: 23

Thanks: 16 times
Was thanked: 1 time(s) in 1 post(s)
What are the parameters to redirect an AFID to a specific page?

We have used in the past
https://www.mydomain.com...ww.mydomain.com/newpage/

And it's not going to the new page it's staying on the home page.

Wanna join the discussion?! Login to your AbleCommerce Forums forum account. New Registrations are disabled.

shari  
#2 Posted : Thursday, September 17, 2020 4:53:51 AM(UTC)
shaharyar

Rank: Advanced Member

Groups: Admin, Developers, Registered, HelpDesk, Authorized User
Joined: 10/5/2018(UTC)
Posts: 703

Thanks: 5 times
Was thanked: 113 time(s) in 112 post(s)
Quote:
What are the parameters to redirect an AFID to a specific page?


I don't think so we have this feature of redirecting to a specific page with AFID in AC9.

Can you please elaborate a bit more in case I am missing something. What steps did you take to get this path with redirect URL?
Thanks
IDAutomation  
#3 Posted : Thursday, September 17, 2020 9:49:35 AM(UTC)
IDAutomation

Rank: Member

Groups: Authorized User, Developers
Joined: 11/13/2018(UTC)
Posts: 23

Thanks: 16 times
Was thanked: 1 time(s) in 1 post(s)
We are coming from AC 7.0 so it seems that it worked then, but many of our resellers choose to link to specific products instead of going to the homepage.

For example, if our reseller is Crystal Reports centric, and want to point directly to our crystal reports generator, they would use

https://www.idautomation...ystal-reports-generator/
shari  
#4 Posted : Monday, September 21, 2020 5:20:33 AM(UTC)
shaharyar

Rank: Advanced Member

Groups: Admin, Developers, Registered, HelpDesk, Authorized User
Joined: 10/5/2018(UTC)
Posts: 703

Thanks: 5 times
Was thanked: 113 time(s) in 112 post(s)
I think this feature is part of some customization being done in AC7.
Can you please confirm if there is some related customizations in AC7?
IDAutomation  
#5 Posted : Monday, September 21, 2020 12:39:12 PM(UTC)
IDAutomation

Rank: Member

Groups: Authorized User, Developers
Joined: 11/13/2018(UTC)
Posts: 23

Thanks: 16 times
Was thanked: 1 time(s) in 1 post(s)
Looks like we had just added some javascript on the homepage previously that helped the redirect...

This was the original code

<script language="JavaScript">
<!-- hide

var myURL = 'http://store.idautomation.com/default.asp?Affiliate=';
var myQuestionIndex = location.href.indexOf('?');
if (myQuestionIndex > -1){
var myAffiliate = location.href.substr(myQuestionIndex + 1);
if (myAffiliate.length > 1){
location.href = myURL + myAffiliate + '&Redir=http://www.idautomation.com/';
}
}

// -->
</script>
<base href="http://www.idautomation.com/"



I updated it to the following but all it does is keep adding "afid" to the url in a loop and doesn't recover. Any ideas?

<script language="JavaScript">
<!-- hide

var myURL = 'https://www.idautomation.com/Default?afid=';
var myQuestionIndex = location.href.indexOf('?');
if (myQuestionIndex > -1){
var myAffiliate = location.href.substr(myQuestionIndex + 1);
if (myAffiliate.length > 1){
location.href = myURL + myAffiliate + '&Redir=https://www.idautomation.com/';
}
}

// -->
</script>
<base href="http://www.idautomation.com/"

shari  
#6 Posted : Monday, September 21, 2020 12:58:35 PM(UTC)
shaharyar

Rank: Advanced Member

Groups: Admin, Developers, Registered, HelpDesk, Authorized User
Joined: 10/5/2018(UTC)
Posts: 703

Thanks: 5 times
Was thanked: 113 time(s) in 112 post(s)
Sorry but I am unable to interpret what is required by this script.

But the issue is obvious. Before updating the script, the script actually changing/redirecting the URL from
store.idautomation.com to www.idautomation.com

and after the updates the script is changing/redirecting the URL from
www.idautomation.com to www.idautomation.com

This is the reason that keeps it redirecting to same page.
IDAutomation  
#7 Posted : Monday, September 21, 2020 1:06:32 PM(UTC)
IDAutomation

Rank: Member

Groups: Authorized User, Developers
Joined: 11/13/2018(UTC)
Posts: 23

Thanks: 16 times
Was thanked: 1 time(s) in 1 post(s)
I'm not a programmer, but that makes sense now that you point it out.
Users browsing this topic
Guest (2)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.