One more question: Where can I find the description of such functions as {LINKCANSAVE} or {LINKISSAVED} ? There is surely a page but I really don`t know where.
I don`t find it on "templates/link vars" or on "Customizations/Add Fields".
Perhaps this is a stupid question, but please help me.
After a member saved a listing on the link bit page - the member is redirected to the main page of the directory. I prefer to redirect him just to the same page he was. So I try this:
Admin Panel / Miscellaneous / Manage Redirects /
After a user saves a link, send them to index.php?action=displaycat&catid={LINKCATID}
This is better then before and redirect the member to the same link bit page of the same category. There remains only one little problem:
Allthough the saved listing is on the page2 (or page3 or page4 ...) of the category the member is redirected to the page1.
My first question is: How can I redirect the member just to the same page he was, when he saved the listing?
My second question is: Is there a function to remove the saved listing direct on the link bit page?
I want to give the member an Icon or a link like this: >>remove this listing from your saved listings page<<
In this way it would be possible to the member to mark and un-mark interesting listings as saved just direct on the link bit page.
Leaving the redirect option blank send me to the root of the directory.
<a href="savedtopics.php?filled=1&deleteids[{LINKID}]=1&returnto={CURRENTURLENCODED}">remove</a> didn`t work too and I don`t know much PHP, so I don`t know where the fault is.
But your second answer is the solution to the first question - since...
<a href="savedtopics.php?add={LINKID}&returnto={CURRENTURLENCODED}">Save to List</a>
send me back to the link bit page and this is what I want. So thanks Paul for the answer!
Perhaps there maybe a solution to the second question too. I think a removal link would be a nice feature. The member surfs on the link bit page and can remove the saving just in place if the link is of no importance anymore.
savedtopics.php turns out to be the only page I know of where filled=1 doesn't involve a redirect page. I've modified it for 5.1.33 so it enables a direct redirect when returnto is passed.
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.
Comments on Function {LINKISSAVED}
Member
Usergroup: Member
Joined: Jul 08, 2009
Total Topics: 17
Total Comments: 31
I`m not sure if this function already exists.
The function {LINKISSAVED} is to show a member if he have already save a listing or not,
example:
<IF {LINKISSAVED}>Listing is saved<ELSE><a href="savedtopics.php?add={LINKID}"> Save to List</a></IF>
I tried this on my page.
If I have not saved a link - the page shows the following:
>>Save to List<<
If I have saved a link - the page shows this:
>> <<
I don`t understand what is wrong or where I make the mistake.
Thanks Daniel
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
Where are you putting that exactly? Works fine in the listing bit:
Attached Files:
Member
Usergroup: Member
Joined: Jul 08, 2009
Total Topics: 17
Total Comments: 31
It was my fault in my link bit template:
<IF {LINKCANSAVE}>
<IF {LINKISSAVED}>saved<ELSE>
<a href="savedtopics.php?add={LINKID}">Save to List</a></IF>
</IF>
I correct it to:
<IF {LINKISSAVED}>saved<ELSE>
<IF {LINKCANSAVE}><a href="savedtopics.php?add={LINKID}">Save to List</a></IF>
</IF>
The fault was:
You can`t save a link that is already saved.
So {LINKCANSAVE} is not true for a saved link.
I`m glad that I have now the solution.
Thanks Paul for the fast and nice help!
--------------------------------------------------------
One more question:
Where can I find the description of such functions as {LINKCANSAVE} or {LINKISSAVED} ?
There is surely a page but I really don`t know where.
I don`t find it on "templates/link vars" or on "Customizations/Add Fields".
Perhaps this is a stupid question, but please help me.
Thanks a lot
Daniel
Member
Usergroup: Member
Joined: Jul 08, 2009
Total Topics: 17
Total Comments: 31
Two more questions...
After a member saved a listing on the link bit page - the member is redirected to the main page of the directory.
I prefer to redirect him just to the same page he was. So I try this:
Admin Panel / Miscellaneous / Manage Redirects /
After a user saves a link, send them to
index.php?action=displaycat&catid={LINKCATID}
This is better then before and redirect the member to the same link bit page of the same category.
There remains only one little problem:
Allthough the saved listing is on the page2 (or page3 or page4 ...) of the category the member is redirected to the page1.
My first question is:
How can I redirect the member just to the same page he was, when he saved the listing?
My second question is:
Is there a function to remove the saved listing direct on the link bit page?
I want to give the member an Icon or a link like this:
>>remove this listing from your saved listings page<<
In this way it would be possible to the member to mark and un-mark interesting listings as saved just direct on the link bit page.
Thank you very much for your help Paul :-))
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
{LINKCANSAVE} is only true if the member hasn't already saved that listing. I've added those two to the listing template variables page.
Leaving the redirect option blank ought to send the person to the last page they were on.
I believe <a href="savedtopics.php?filled=1&deleteids[{LINKID}]=1&returnto={CURRENTURLENCODED}">remove</a> should work as a removal link.
Member
Usergroup: Member
Joined: Jul 08, 2009
Total Topics: 17
Total Comments: 31
Leaving the redirect option blank send me to the root of the directory.
<a href="savedtopics.php?filled=1&deleteids[{LINKID}]=1&returnto={CURRENTURLENCODED}">remove</a>
didn`t work too and I don`t know much PHP, so I don`t know where the fault is.
But your second answer is the solution to the first question -
since...
<a href="savedtopics.php?add={LINKID}&returnto={CURRENTURLENCODED}">Save to List</a>
send me back to the link bit page and this is what I want.
So thanks Paul for the answer!
Perhaps there maybe a solution to the second question too.
I think a removal link would be a nice feature.
The member surfs on the link bit page and can remove the saving just in place if the link is of no importance anymore.
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
savedtopics.php turns out to be the only page I know of where filled=1 doesn't involve a redirect page. I've modified it for 5.1.33 so it enables a direct redirect when returnto is passed.