Current location: Hot Scripts Forums » Programming Languages » ASP » Your advice chaps...


Your advice chaps...

Reply
  #1 (permalink)  
Old 10-26-03, 04:31 PM
Stealth Stealth is offline
1337 pr0gr4mm3r
 
Join Date: Jun 2003
Location: Glasgow, Scotland
Posts: 188
Thanks: 0
Thanked 0 Times in 0 Posts
Your advice chaps...

I am writing a script that will have a feature for different languages, although onl 1 language will be used throughout the website. Is it better to populate each page load from a database or from variables in a file. My instinct tells me using a database is slower, but would it really grind things to a halt?
Reply With Quote
  #2 (permalink)  
Old 10-28-03, 04:12 AM
my2cents my2cents is offline
Newbie Coder
 
Join Date: Oct 2003
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Try this

You are on track - variables and DB will work. At system startup, read the database and load them into application variables. You can use the global.asa to do this. Expample included below.

This reads the database only once at system startup, after that they are in memory.

<SCRIPT LANGUAGE=VBScript RUNAT=Server>

Sub Application_OnStart
Server.Execute "/loadlanguage.asp" ' Load language module.
End Sub

Sub Application_OnEnd
End Sub

Sub Session_OnStart
End Sub

Sub Sesson_OnEnd
End Sub

</SCRIPT>
Reply With Quote
  #3 (permalink)  
Old 10-28-03, 11:06 AM
Stealth Stealth is offline
1337 pr0gr4mm3r
 
Join Date: Jun 2003
Location: Glasgow, Scotland
Posts: 188
Thanks: 0
Thanked 0 Times in 0 Posts
doh. see what happens when ure programmin so late :¬)
cheers nvr thought of that
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
software advice s01 The Lounge 3 09-30-03 05:01 AM
PHP search engine-need some advice darkcarnival Website Reviews 18 08-06-03 06:35 PM
Need some good script advice X-Faction PHP 8 06-30-03 10:01 PM


All times are GMT -5. The time now is 03:48 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.