Get ready for BLACK FRIDAY shopping starting in

Forums

This topic is locked

Does anyone use the snippets panel?

Posted 23 Nov 2004 21:34:22
1
has voted
23 Nov 2004 21:34:22 Simon Martin posted:
I haven't used the Snippets panel before but stumbled across it last night as I was looking over some notes from a Lynda.com training course. They had slightly customised a recordset navigation bar and stored it as a snippet - have I been missing out on something for years? Does anyone else use snippets much? Are they really a time saver or just a gimmick?

Live the life you love
Love the life you live

Simon

[DWMX 2004]|[SQL]|[ASP/VBScript]|[XP-Pro]

Replies

Replied 24 Nov 2004 12:06:18
24 Nov 2004 12:06:18 Lee Diggins replied:
Hi Simon

Real time saver, especially for your own code, however, I always make a backup of the snippets as your own code snippets can be over-written when uninstalling/re-installing a flaky DW.

Digga

Sharing Knowledge Saves Valuable Time!!!
Replied 24 Nov 2004 15:18:28
24 Nov 2004 15:18:28 Dave Thomas replied:
yep gotta agree, great time saver for doing repetative code.

Regards,
Dave

[DWMX 2004]|[FlashMX 2004 Pro]|[SQL]|[Access2000]|[ASP/VBScript]|[XP-Pro]
Replied 24 Nov 2004 15:34:19
24 Nov 2004 15:34:19 Simon Martin replied:
So would you say that a snippet was like a light weight include file?

Is there anything else hidden away there that really speeds things up for you?


Live the life you love
Love the life you live

Simon

[DWMX 2004]|[SQL]|[ASP/VBScript]|[XP-Pro]
Replied 24 Nov 2004 16:14:24
24 Nov 2004 16:14:24 Lee Diggins replied:
Simon

It's just a code repository stored in xml files, one file per snippet with an attribute that insertbefore or insertafter letting DW know where to put the code.

Digga

Sharing Knowledge Saves Valuable Time!!!
Replied 24 Nov 2004 16:38:33
24 Nov 2004 16:38:33 Simon Martin replied:
Hi Lee,
For a navigation bar I would be tempted to store it as an include (navbar.asp) and link to it in my pages - so if I needed to make a global change to the navigation system I would only need to change it in 1 place. The downside to this would be that I couldn't then make custom changes to the navigation on just one page. Would you say that is the time to consider using a snippet?

Live the life you love
Love the life you live

Simon

[DWMX 2004]|[SQL]|[ASP/VBScript]|[XP-Pro]
Replied 24 Nov 2004 16:48:59
24 Nov 2004 16:48:59 Lee Diggins replied:
Hi Simon

Could be, you could have navbar1, navbar2 etc,. all with different code in the snippets folders. Any changes you make to the code stored in snippets is only reflected in the changed snippet file and not in any pages that you have used the code snippet, there are no links between snippets and web pages. There's nothing dynamic about snippets, they're just a way of storing re-usable code. I use text files on my file system to store my code in, DW uses snippets which are text files (xml) managed by DW, saves you having to go to your file system to get a copy of the code.

Digga

Sharing Knowledge Saves Valuable Time!!!

Reply to this topic