Hi Again guys, In going through and getting comments from testers ive been asked if from the final step of placing the ad, we could have it redirect to the actual ad itself. I know there is the preview, but people are just plain fussy I guess. So im stuck as to where to change this and how even...looking in the checkout folder we have steps 1 through 7 but step 5 is missing? Any pointers would be greatly appreciated. Many thanks,
Once again, your going to need to learn how to use the smarty debug console. Enable it and place an ad, make a note of each script and template in use as you go through the ad placement process. That being said the last template you are displayed is the thankyou template so you are going to have to see if the ad id is available there and if so you can use it in a redirect.
Hi Larry, Indeed I need to look at the debug console. I was hoping that in step7.tpl the button would basically have a "onsubmit go > here" attached to it so I could have basically altered it to go directly to the ad page. Ill take a look in a moment and write back if anything Many thanks, Tom.
If you learn a bit of smarty, htrml and css your progress will be faster. In terms of your question: Why not do it the simple way? Put a link on your thankyou page to userbrowselistings.php . They may have multiple adverts. However, the thank you page is an opportunity to promote posting another advert or anything you like. Why throw that away? It is a revenue opportunity.
Hi again , No I agree thinking about this logically the thankyou page would offer some fantastic advertising space. However sending them to their browse listings page as this defeats the comments passed to me. I think an EBAY approach is better. On the thank you page you thank them for listing etc,then ask them in normal text view advert (ad they just placed) and underneath you can advertise other products etc or do whatever is needed. I think this would be an ideal approach? Kindest regards,
Then I think Larry answered your question. If the variable is not available in order to build a link to your advert then your choices get limited to building a module or making core file changes (never a good idea in terms of upgrade and maintenance). Don't take this harshly but you are not investing your time in getting the necessary skills in order to carry out customization of a relatively complex piece of software. I do not see any reason at all to make the changes you propose either. 50% of the people may say they wish to see their advert again (I doubt it) and 50% of them would say, I know what it is, I just saw it a couple of clicks before and you are wasting my time showing it to me again. There is also another problem in doing this generally which is if the admin must approve adverts, it will not even be live on the site. Better to show people something NEW. They will go and find their advert in userbrowselistings or on on the latest adverts page anyway idf they are that concerned. In fact you want them to go off looking through the site from an internet marketing perspective.
by using the debug tool you would have found that {$oID} is the listing number so in thanks.tpl at the top add the following <meta http-equiv="REFRESH" content="0;url={$smarty.const.URL}/viewlisting.php?view={$oID}"> This will redirect to the listing. Change 0 for how many seconds until the redirect. Nick
Did you read this thread Nick? How does the fact that you used the smarty debug tool because we beat you up so often over many months help teach anyone else to find out how to use it so they can help themselves? Why do you think Larry, Mike and I keep asking people to use this tool? Also, what happens if the advert is inactive? How does this allow the thank you page to be used for marketing?
lol, No I should use the debug tool, I have to admit. But from a new comers angle to php and smarty id think just because it exists in there doesnt mean it will output the desired value . As it happens I was in the email templates making an alteration to indicate to people they should have 2 emails (activation and welcome) when I saw the variable for the ad id. Thanks to all of you David, you do have a very good point about the if it needs approving by an admin, and also about people wanting this that and the other. Many thanks,
Hi Nick, Erm, ok Ive enabled the debug and gone to the thanks page. Yet I dont see {$oID} listed anywhere? Actually I find very few differences between each page actually? Perhaps im missing something though? Many thanks, Tom.
To use the smarty debug place {debug} on the page you want to see the variable. So in this case we wanted to find what variables are there on thanks.tpl so place {debug} on the top of thanks.tpl and then upload. Go onto your website and place an ad, when you get to the thank you page a popup will appear with the variables. Go down until you find the variable you were looking for(if it is there) and in this case it was {$oID} so you can now use this is the code as above. Nick
Ahhhhhhh, Thats what I was doing wrong lol. I placed the debug statment at the top of the layout.tpl thinking this is what was meant and then browse through page by page until you found the page your after and look for the variable. Ok this makes more sense Many thanks Nick. Kindest regards
You can place it at the top of the layout.tpl and the popup should change depending upon what page you are on. There is nothing wrong in doing that although if you put it on the specific template page it can be better if your site is live and being used for example. You will notice the console contents will change a bit between pages.