|
Haven't registered yet? Do it here now!
|
ximperium
Joined: 17 Sep 2008 Posts: 5
|
|
|
|
|
|
|
Posted: Wed Sep 17, 2008 1:36 pm Post subject: Use domain name instead of id |
|
|
|
|
|
|
|
|
|
|
Hi,
I have just installed your script and did some testing with it. I'm running multiple sites each having their own domain name from one single script. My problem is:
1. To display the links you have to use site_1_1.php . This means in my script I have to write a whole bunch of if or cases to show the correct scripts. This gets tedious after a while, not to mention very error prone. I have got to look up all the numbers for each site. Isn't it possible to do something like site.php?site=mydomain . com
2. I have the same issue with the tracker code, which is track.php ? id=1&ref=.... Can't the id be something like id=domain . com or site=domain . com ? I can extract the requested domain using the $_SERVER variable
Is this already possible or can I tweak the scripts a bit to allow this? Thanks. |
|
|
|
|
|
|
|
ximperium
Joined: 17 Sep 2008 Posts: 5
|
|
|
|
|
|
|
Posted: Wed Sep 17, 2008 1:47 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
Just looked into the site_1_1.php file and it is only text. So another solution would be to create a file called site_domain.php . I can also extract the domain name in my code. Which script generates the site_1_1.php file? |
|
|
|
|
|
|
|
Atanasis Owner
Joined: 22 May 2004 Posts: 4284 Location: The Net
|
|
|
|
|
|
|
Posted: Wed Sep 17, 2008 2:31 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
hi there, no, thats not possible since it is made the whole script work with IDs for faster performance.
A solution for you could be, to make a simple php script that reads from the database, extracts the ID and domain of the site and makes a symlink in some directory like this:
it symlinks /lo/site_templates/site_1_1.php to /something/site_domain.php
so you just include in your pages that. _________________ Thanks,
Kaktusan
|
|
|
|
|
|
|
|
ximperium
Joined: 17 Sep 2008 Posts: 5
|
|
|
|
|
|
|
Posted: Wed Sep 17, 2008 2:51 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
Ok thanks, I'm going to try something along those lines. Site_1_1.php has two numbers, first is id and second is id of template? Is this correct? Thanks. |
|
|
|
|
|
|
|
Atanasis Owner
Joined: 22 May 2004 Posts: 4284 Location: The Net
|
|
|
|
|
|
|
Posted: Wed Sep 17, 2008 5:59 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
yes, first number is id of the site from the "losites" table, and second number is the ID of the template from the "lotemplates" table. _________________ Thanks,
Kaktusan
|
|
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2002 phpBB Group
|
|
|
|
| |