Support Forum
Aside from the online help, is there anybody here who can help me how to use the program hooks the newbie way? 😀
depends on what you want to do... the hooks are located in various key spots of the forum code... if you edit the sf-hook-template.php (or in v4, edit sf-hook-template.txt and rename to sf-hook-template.php) and find the hook you want to utilize... simply add your code into one of the current hooks... each hook is commented as to when its called...
Visit Cruise Talk Central and Mr Papa's World
same answer really... depends what you want to do.
If you just want to display a string of text then yes, you could put it between the quotes in the return statement. Whatever does get returned will display but perhaps a hint of what you want might help us anwser better.
YELLOW
SWORDFISH
|
At first, it will be for adsense...second, probably some small reminders for the forum itself. For adsense, I just need to insert the whole script isn't?
yes, I believe you want the whole javascript code... I think it just echos it out, so you should be good... for the messages, just the text you want output, though I would check the custom tab on the spf manage options panel first as you may be able to do that there...
Visit Cruise Talk Central and Mr Papa's World
Yellow Swordfish said:
Yopu must not 'echo' anything in the hooks. Always return it.
I'm confuse...does it mean that I can't place the entire code directly? 😐
Andy means, dont use a php echo statement anywhere in the hook... that you want to return a string to be output from the hook... either return a variable that contains the string or the string itself...
in your case, you can set a variable to the google adsense code (inside " ") and return the variable...
Visit Cruise Talk Central and Mr Papa's World