Click to See Complete Forum and Search --> : Displaying a "Tip of the Week" on a web page
owlice
08-07-2007, 05:08 PM
Hi!
I have basic knowledge of HTML and use Dreamweaver for site development/management. Used to be a programmer, so not afraid of learning something new.
I'd like to add a feature to one of my web sites, a "Tip of the Week," and am trying to figure out the best way to do this. I will have 52 tips already prepared when I launch my redesigned site with this feature.
I have a banner area on the new home page in which I will display some text about that week's tip, with a link to more information (a separate page, I suppose) about that tip.
I've been looking (just today :-) ) at ASP as a means to do this, but don't know whether that's the best choice. Ideally, after each week is over, that week's tip will be accessible in an archive of tips so that users can read through them/etc.
(The tips would be on such things as Microsoft Office, Lotus Notes, our phone system... basically, suggestions for getting better use out of our office technology.)
Might someone here be willing to share ideas as to how I can do this with me? I'd really appreciate it; TIA!
Owl
tracknut
08-07-2007, 06:27 PM
Probably the best bet is to store the 52 tips in a database, and then use a server-side application to extract the particular tip and display it. This is not a client/HTML thing. It's really pretty simple though if you have development background. I don't know ASP, but would assume it would work. Personally I'd be using PHP/MySQL to do it, but that's just a different language...
Dave
ray326
08-08-2007, 01:07 AM
I've been looking (just today :-) ) at ASP as a means to do this, but don't know whether that's the best choice.It depends on what you have available on your server. If it's a Windows/IIS host then ASP is probably supported. If it's Linux/Apache then look into PHP, which is very similar. As Dave said, it's an easy app and will make a good learning tool.
owlice
08-08-2007, 09:39 AM
Thanks for the replies! And doh! for posting this under client-side instead of elsewhere; I saw "General" and that was that..!
Yes, it's an IIS environment, and I've tested and see that ASP is indeed available to me. I'd like something simple, and wonder if I can use Excel for this, mainly because I have Excel and am already familiar with it. Don't know Access, but suppose I could learn it if I had to, but if I don't have to, so much the better!
ray326
08-08-2007, 12:41 PM
An Access (Jet) MDB would be much better than an Excel spreadsheet. Well a FLAT FILE would be better than an Excel spreadsheet. Even better would be a SQL Server table.
owlice
08-08-2007, 02:29 PM
Thanks!
It's best that I avoid ColdFusion and databases, if I want to keep this simple and under my control. (I've been asking around. Oh, the things I've learned! Oh, the things I've relearned! Oh, how nailed down some things are here!)
A flat file is fine, actually, as I can use Excel to organize the info and generate the flat file.
I'm still wrapping my pea brain around different possibilities. The simplest is having two sets of files, 52 files in each set; one set is the info to display in the window (one file for each week), the other is the longer explanation of the tip to which the info in the window will link. The file(s) that are displayed are renamed with a batch file every week (or copied to that name, more likely) to some generic name ("CurrentTipBrief" and "CurrentTipExplanation" for example), and that's what the page displays.
I think there's a more elegant way to do this. Actually, I KNOW there's a more elegant way to do this, but it requires more coding/work than I'm probably up for right now, darn it.
I hate running smack up against my ignorance. I'm thinking I need to know a little more Perl than I know. (I learned a little Perl about eight? Ten? years ago, and have just been editing and reusing the little bit I wrote back then.)
Off to continue my education.
ray326
08-09-2007, 12:15 AM
I think there's a more elegant way to do this. Actually, I KNOW there's a more elegant way to do this, but it requires more coding/work than I'm probably up for right now, darn it.That would be putting them in a table in a real database.
owlice
08-09-2007, 09:53 AM
That would be putting them in a table in a real database.
Thanks! And agreed! That would also mean being subjected to controls that I'd rather avoid, however.
I'm playing with Perl today; this should work nicely for the flat file info, and possibly for the archive page, too.
Here (http://webscripts.softpedia.com/script/Content-Management/RandText-17172.html) is a Perl script that will do what you want. I haven't checked it myself, though.
owlice
08-09-2007, 04:12 PM
Here (http://webscripts.softpedia.com/script/Content-Management/RandText-17172.html) is a Perl script that will do what you want. I haven't checked it myself, though.
Hi, and thanks for that! It doesn't quite match my needs (it displays random text lines, rather than one particular one for X days, as I'm after), but I can see it being very useful for all kinds of things and in all kinds of ways, and may incorporate it for another idea I've had floating around in the back of my head for a while. In any case, it'll help me learn parts of what I need to do in Perl. (Darn my ignorance!)
I brought home three Perl books and am tempted to challenge my 13-year-old son to a duel: first one who gets a working script wins. :-D If I don't make significant progress in the next few days, I'm going to use a server-side include for the text, to include a file called "Current," and will commit to overwriting it every Friday, late, until I have something more automated.