Posted by Remy
2013-11-10

Hello Tom,

Thanks for developing such a great php script. I have a question,

Can i install URL shortening script on adpages subfolder using the same database (adfreely)? If yes, how? and if no, why?

On web\cn\include\tpl.image_cell.inc.php there's a typo in line 3, <a href='<?php echo $url_link; ?>' target='_balnk'>. I guess it 'target='_blank' right?

Sorry for my bad English.
Posted by Tom
2013-11-10

So, you want to merge "adfreely" and "URL shortening script" into one? If you do, name collisions will occur because both use a lot of same function & variable names. The easiest way to solve name collision is to put one in an iframe and never merge php codes. A more elegant method is use the namespace feature to put them into two different namespaces. The drawback is you need PHP5.3 or higher to use namespaces. The most complete solution is rename all function and variable names programmatically ( like adding a certain prefix to each name ), but it requires most efforts.