![]() |
Excluding Welcome_tpl
High Ive been trying to sort out some things on my site could you please help.
I would like to take out the customer welcome tpl altogether Ive narrowed it down I think to customer_main_tpl but cant actually get it to go ?? Thanks |
Please post your x-cart version number in your signature.
To remove the welcome message, just remove or comment this line of code out of home_main.tpl: Code:
{elseif $main eq "catalog" and $current_category.category eq ""} |
Silly Question? How do you exactly comment in the TPL files?
Thanks, a learning newb. :wink: |
Comments in templates and php files
Hi Daniel
I comment a .tpl file with "open curly bracket" "star" Put Your Comment Here or to disable a line of the template file "star" " close curly bracket" eg: {* Modified by SWH on 050127 *} {* //skin1/customer/main/register.tpl *} {* Original Version embedded in comments after the modified lines labelled SWH *} If you wish to comment out multiple lines: {* Line 1 Line 2 Line 3 *} Make sure that there are no {* or *} (other comments) inside your commented area. Otherwise it will run everything from *} to the last *}. I also put a marker on the lines I have changed in the .tpl files - I use: {* SWH *} That way I can find changes quickly inside the files and from outside the files. Note - any changes to the files will give issues in upgrades (if that file requires upgrading). See my post for further help: http://forum.x-cart.com/viewtopic.php?t=14640 ********************************************** For .php files I use the following method to comment files: /* Modified by SWH 041222 */ /* yoursite/include/func.php file being modified */ /* Original Version embedded in comments after the modified lines labelled SWH */ I then comment at the end of lines with // SWH for the lines I have modified. If you wish you can put a # at the start of the line to comment out the whole line (eg. disable a line of code). For program line codes make sure that you have a semicolon terminating the line with no spaces after it (or you will get a blank screen & php errors). I hope this helps you and others. Remember to backup often and keep a copy of the original file to use for restoring (in case Murphy should visit!). Regards Ing. Stephen Hatton :idea: |
Thank you very much it worked perfectly :)
|
Thanks for the info, that is exactly why I need to comment my tpl and php files.
Theres alot of comments that need to be added to all of the template files. Thanks again for the info. |
Hey Stephen, it would be great if you could write a seperate post for this and have the mods move it to the FAQ forum. This question gets asked MILLIONS of times. :)
|
All times are GMT -8. The time now is 09:34 AM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.