Thank you teseo I will study this to... Until then I try this but still have problems... Where Im doing wrong?
domain aaa.ro is main domain on the host
domain bbb.ro is an addondomain
so I have:
for the domain aaa.ro
/home/aaa/public_html/
with this folders:
oc-admin
oc-content
oc-includes
bbb.ro
and this files:
CHANGELOG.txt
Config-sample.php
config.php
favicon..ico
index.php
licenses,txt
oc-load.php
robots.txt
Domain bbb.ro is in:
/home/aaa/public_html/bbb.ro/
1.
I copy all the files and folders (except bbb.ro) from /home/aaa/public_html/ to: /home/aaa/public_html/bbb.ro/
and I have the same structure (except bbb.ro)
with this folders:
oc-admin
oc-content
oc-includes
and this files:
CHANGELOG.txt
Config-sample.php
config.php
favicon..ico
index.php
licenses,txt
oc-load.php
robots.txt
2.
I modify in the file /home/aaa/public_html/bbb.ro/config.php ONLY this line:
from:
define('WEB_PATH', '
http://www.aaa.ro/');to:
define('WEB_PATH', '
http://www.bbb.ro/');save close
3.
I go to /home/aaa/public_html/bbb.ro/oc-includes/osclass/helpers
Open the file hDefines.php and change this line:
from:
function osc_content_path() {
return(CONTENT_PATH);
}
To:
function osc_content_path() {
return("/home/aaa/public_html/oc-content/");
}
click save and close
4.
I go to /home/aaa/public_html/bbb.ro/oc-includes/osclass/helpers
Open the file hItems.php and change this line:
from:
function osc_resource_url() {
return (string) osc_resource_path().osc_resource_id().".".osc_resource_field("s_extension");
}
TO:
function osc_resource_url() {
return (string)"
http://www.bbb.ro/oc-content/uploads/".osc_resource_id().".".osc_resource_field("s_extension");
}
click save
5.
same file as nr. 4 change this line to:
from:
function osc_resource_thumbnail_url() {
return (string) osc_resource_path().osc_resource_id()."_thumbnail.".osc_resource_field("s_extension");
}
To:
function osc_resource_thumbnail_url() {
return (string)"
http://www.bbb.ro/oc-content/uploads/".osc_resource_id()."_thumbnail.".osc_resource_field("s_extension");
}
Click save and close
6.
I go to:
/home/aaa/public_html/bbb.ro/oc-includes/osclass/frm/
Open this file Item.form.class.php
Now is some complication because i found 2 lines starting with <?php echo osc_apply_filter
6.a.
is like that:
<div id="<?php echo $_r['pk_i_id'];?>" fkid="<?php echo $_r['fk_i_item_id'];?>" name="<?php echo $_r['s_name'];?>">
<img src="<?php echo osc_apply_filter('resource_path', osc_base_url() . $_r['s_path']) . $_r['pk_i_id'] . '_thumbnail.' . $_r['s_extension']; ?>" /><a href="javascript:delete_image(<?php echo $_r['pk_i_id'].", ".$_r['fk_i_item_id'].", '".$_r['s_name']."', '".Params::getParam('secret')."'";?>);" class="delete"><?php _e('Delete'); ?></a>
</div>
I change it to:
<div id="<?php echo $_r['pk_i_id'];?>" fkid="<?php echo $_r['fk_i_item_id'];?>" name="<?php echo $_r['s_name'];?>">
<img src="<?php echo osc_apply_filter('resource_path', '
http://www.bbb.ro/' . $_r['s_path']) . $_r['pk_i_id'] . '_thumbnail.' . $_r['s_extension']; ?>" /><a href="javascript:delete_image(<?php echo $_r['pk_i_id'].", ".$_r['fk_i_item_id'].", '".$_r['s_name']."', '".Params::getParam('secret')."'";?>);" class="delete"><?php _e('Delete'); ?></a>
</div>
6.b.
is like that
<div class="ajax_preview_img"><img src="<?php echo osc_apply_filter('resource_path', osc_base_url().$_r['s_path']).$_r['pk_i_id'].'_thumbnail.'.$_r['s_extension']; ?>" alt="<?php echo osc_esc_html($img); ?>"></div>
I change to:
<div class="ajax_preview_img"><img src="<?php echo osc_apply_filter('resource_path', '
http://www.bbb.ro' .$_r['s_path']).$_r['pk_i_id'].'_thumbnail.'.$_r['s_extension']; ?>" alt="<?php echo osc_esc_html($img); ?>"></div>
Click save close.
WHAT Im doing wrong?