View Full Version : Licensing + Languages
Donna
11-01-2005, 02:46 PM
Hi,
1. I'm developing a site on a machine in place (a), and upload to a server in place (b) from time to time. Since your license is computed using the domain name + my ip, and both of these will change on upload, how does one get around this problem?
2. The site under development is multi-lingual. The language is set by (a) detecting browser prefs. on first visit, and (b) user-choice thereafter. I want to be able to show the calendar text in the user's choice of language, and despite prodding around with the test version do not see how this could be done.
The current language is passed in a query-string to the scripts ie. ?lang=de
Hope you can help.
Brian
11-01-2005, 02:52 PM
1) I can issue a key for your development server through the support ticket system.
2) The language isn't designed to be changed by a query string. Is this for the Event Manager?
Donna
11-01-2005, 04:32 PM
> Is this for the Event Manager?
No - the domain owner is English.
This would be purely for site visitors. If you want to see more clearly what I mean, goto www.springtop-bequia.com and click on the lang links. (You won't see the query string 'cos its rewritten by apache but it IS there.)
Brian
11-01-2005, 05:28 PM
You need to enter an event description three times, one for each language?
Donna
11-01-2005, 05:45 PM
> You need to enter an event description three times, one for each language?
No... I'm clearly not explaining this very well. I will start again.
This is what I want to happen:
The only person who will see/edit/be aware of events is the domain owner/administrator. It is imporant that the owner can edit the calendar online when he receives bookings so that days are marked unavailable immediately they are booked.
Visitors to the site (ie. potential house-renters) will merely see the calendar itself, which will have 'available' days colored 'x' and 'unavailable' days colored 'y'. They will not see or be aware of anything else at all, no events, no popups, no nuffin'. They will not be able to interact with the calendar in any way whatsoever. For visitors, the calendar is _only_ an informational guide as to what days are available for bookings.
... and visitors should get the calendar in whatever language they choose.
Is this possible?
Brian
11-01-2005, 05:51 PM
So, you need the language of the months and days to be different according to the selected language?
Donna
11-01-2005, 06:22 PM
> So, you need the language of the months and days to be different
> according to the selected language?
YES! yes, yes, yes, exactly right.
Brian
11-01-2005, 08:54 PM
This can be done, with a little manipulation of the config.inc.php file.
What you'd need to do is copy the section of variables containing the month and day names. Then, include three sets of these variables (one for each language) in your page with an if statement to determine which set should load.
Then, in the config.inc.php file, add an if statement to check for no language variable. If there is none, then the script should then use it's own for the Event Manger.
:)
Donna
11-03-2005, 03:15 PM
Having prodded around a bit, I decided your suggestion wasn't a great option as config.inc.php gets over-written every time something's changed in the Event or Setup Managers.
So I've added a line into /calendar/calendar.php:
// DISPLAY CALENDAR
if ( $CSS == "" && $OL != 1 && $LIST != 1 && $PCSS == "" &&
$TOC == "" && $MULTIX == "" && $EPCBLOG == "" ) {
if ( !file_exists($serverPath."config.inc.php"))
die ("<font color=red>Server Path Error.</font><br />Please run the Setup
Manager to correct this problem.<br /><br />");
if ($license == "" || !isset($license) || !isset($gmt) || $gmt=="") {
require ($serverPath."config.inc.php");
/* include my language stuff */
require ( "/path/to/languages.php");
}
require ($serverPath."functions/calendar.php");
}
This seems to work just peachily. Do you know of any reason why it might
interfere with your closed-source stuff or vice-versa?
Brian
11-03-2005, 03:51 PM
That should work just fine. :)
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.