The forum is here for legacy reasons. No new posts will be created. User registration is disabled! If you have any questions, please email us or check https://www.adultscriptpro.com for more details!
You are not logged in.
Pages: 1
Yes and no... in theory you could use the same database, but you would have a lot of issues.
The two domains would have the same site name and meta information as well as settings, and a lot of your links would require manual rewriting.
You *could* make one big database and have different table prefixes and have each domain call a separate prefix, but doing this won't share members, photos or videos between sites and would make your SQL scream for mercy under a decent server load.
Your best option is to use remote SQL and just have two databases. I currently have a VPS hosting account for my static files and conversion, but I use a dedicated for my databases. In your config you just enter the IP address of your outside SQL host rather than the usual 'localhost' or your current hosting sql address.
Offline
You can use one database for 2 sites, you need to have the same media folder for both sites (you can create a symbolic link). When you edit the config on one site the cache will be saved in the tmp/cache folder, so no need to edit for each site.
Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds
Offline
Hi Adrian, so what I'm trying to do is get like a real multilanguage site with one database and 2 domains with their template at same server. I'm working for 2 languages now spanish and italian, I've added new columns at database for italian for example for video nameit descriptionit slugit and modified script and this part is working nice. Now the flag link go to the video of that language. The problem is with tag and category I tried linking tag and category with flag but is not working. How can i get nameit from video_tags and category nameit from categories?
Thanks
Offline
select group_concat(t.name) as tags, group_concat(c.name) as categories
Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds
Offline
I tried all day and didn't get work, where should I have to put select group_concat(t.name) as tags
$query = VUri::query();
$tag = (isset($query['1'])) ? $query['1'] : '';
$page = (isset($query['2'])) ? (int) $query['2'] : 1;
$url = 'tag/'.prepare_string($tag, true).'/';
if ($page !== 0 && $page !== 1) {
$url .= $page.'/';
}
if (!VUri::match($url)) {
VModule::load('404', TRUE);
}
VLanguage::load('frontend.video');
$tag = str_replace('-', ' ', $tag);
$tag = utf8_strtolower($tag);
$sql_count = "SELECT COUNT(*) AS total_videos
FROM #__video_tags AS vt
WHERE vt.nameit = '".$this->db->escape($tag)."'";
$total_videos = $this->db->get_field($sql_count, 'total_videos');
$pagination = VPagination::get($page, $total_videos, $this->vcfg['tag_per_page']);
$sql = "SELECT v.video_id, v.titleit, v.slugit, v.title, v.slug, v.rating, v.rated_by, v.duration, v.thumb,
v.thumbs, v.total_views, v.add_time, v.ext, v.premium, u.username
FROM #__video_tags AS vt
INNER JOIN #__video AS v ON (v.video_id = vt.video_id AND v.status = 1)
LEFT JOIN #__user AS u ON (u.user_id = v.user_id)
WHERE vt.nameit = '".$this->db->escape($tag)."'
ORDER BY v.video_id DESC
LIMIT ".$pagination['limit'];
if (!$videos = $this->cache->get($sql, 86400)) {
$this->db->query($sql);
if ($this->db->affected_rows()) {
$videos = $this->db->fetch_rows();
$this->cache->store($sql, $videos, 86400);
} else {
$videos = array();
Offline
are you trying to get the tags and categories for a video or the videos that have a specific tag?
Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds
Offline
category is working now
problem is with tag. i want to get video_tags name from db, example url for italian language http://website/tag/mature/ i want to link to spanish http://website/tag/madura/ db at video_tags i got nameit for italian and name for spanish
i think problem is getting $query for both languages at same time
Last edited by hummy (2016-05-25 11:50:54)
Offline
so i already have this implemented for the script, but it will only be available in 3.x. you need a new database structure, table tags contains the tags (tag_id, tag), table tags_translations contains the translations (tag_id, lang_id, tag) and table video_tags contains the relation between the tags and videos (tag_id, video_id)
dont know exactly how you can make it work with the current version of the script
Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds
Offline
Hi.
May be a stupid question , but how to create symbolic link???
-Topi
You can use one database for 2 sites, you need to have the same media folder for both sites (you can create a symbolic link). When you edit the config on one site the cache will be saved in the tmp/cache folder, so no need to edit for each site.
Offline
ln -s /path/to/folder/or/file/you/want/to/link/to new-link-name
Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds
Offline
Pages: 1